diff --git a/docs/card.html b/docs/card.html index 26a9687..7480e60 100644 --- a/docs/card.html +++ b/docs/card.html @@ -63,7 +63,7 @@ Basic syntax Stacked tabs
Contextual Text highlighting Toasts - Tooltips + Tooltips Modals
Progress Basic progress bar Progress bar variants Donut spinner Donut spinner variants diff --git a/docs/contextual.html b/docs/contextual.html index d0547aa..f39441e 100644 --- a/docs/contextual.html +++ b/docs/contextual.html @@ -66,7 +66,7 @@ Basic syntax Stacked tabs
Contextual Text highlighting Toasts - Tooltips + Tooltips Modals
Progress Basic progress bar Progress bar variants Donut spinner Donut spinner variants @@ -84,7 +84,7 @@

Contextual

-

The contextual module provides you with simple tags, marks and highlights for your pages, allowing you to easily emphasize parts of your text. Contextual toasts and tooltips are also provided, aiming to help deliver important information to users. HTML5 elements and simple rules are used in order to make important messages and pieces of content stand out easily.

+

The contextual module provides you with simple tags, marks and highlights for your pages, allowing you to easily emphasize parts of your text. Contextual toasts, tooltips and modals are also provided, aiming to help deliver important information to users. HTML5 elements and simple rules are used in order to make important messages and pieces of content stand out easily.

All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.


@@ -93,7 +93,7 @@

Quick overview

-

Almost every website present on the web has some sort of content that needs highlighting in one way or another. The contextual module provides you with simple semantic text highlighting that utilises the <mark> HTML element. Apart from that, this module contains styles and definitions for a simple .toast container, that you can use to display toast messages on your websites and web apps. Toasts mimic the native application notifications of certain devices, making them mobile friendly. Finally, a simple accessible .tooltip implementation is included. All components in this module are fully accessible, so that's another thing not to worry about.


+

Almost every website present on the web has some sort of content that needs highlighting in one way or another. The contextual module provides you with simple semantic text highlighting that utilises the <mark> HTML element. Apart from that, this module contains styles and definitions for a simple .toast container, that you can use to display toast messages on your websites and web apps. Toasts mimic the native application notifications of certain devices, making them mobile friendly. Finally, a simple accessible .tooltip implementation is included along with an implementation for .modal dialogs. All components in this module are fully accessible, so that's another thing not to worry about.


Quick start

@@ -227,6 +227,66 @@
+
+
+
+

Modals

+
+
+

+

+ + +
+
+
+

Modal dialogs are pretty ease to make. Simply create an <input type="checkbox"> element, immediately followed by a <div> element with the .modal class. Inside this element, you can add a .card element with your modal dialog's contents. Remember to add a <label> element linked to your modal dialog's <input type="checkbox"> to let users close the dialog. You can also apply the .close class to a <label> element to display a close icon at the top right of the modal dialog.

+

Sample code

+
<label for="modal-toggle">Show modal</label>
+
+<input id="modal-toggle" type="checkbox"/>
+<div class="modal">
+  <div class="card">
+    <label for="modal-toggle" class="close"></label>
+    <h3 class="section">Modal</h3>
+    <p class="section">This is a modal window!</p>
+  </div>
+</div>
+
+
+
+

Notes

+
    +
  • You can use any styles you want from the card module to create different dialogs based on context (e.g. alerts, warnings etc.).
  • +
  • Remember to add a <label> linked to your modal dialog's <input type="checkbox"> or use Javascript to alter its state, otherwise users will not be able to close the dialog.
  • +
  • You can place your modal dialog anywhere on your page, as long as the structure is not altered. You can also toggle it from anywhere on a page.
  • +

+
+
+
<input id="modal-toggle" type="checkbox"/>
+<label for="modal-toggle">Show modal</label>
+<div class="modal">
+  <div class="card">
+    <label for="modal-toggle" class="close"></label>
+    <h3 class="section">Bad Modal</h3>
+  </div>
+</div>
+

Don't: The syntax and structure of the modal dialog's container is very strict. Try to follow it exactly as described in this section.

+
+
+
+
+
+

If you want to learn more about mini.css's modules, go back to the modules page and choose another module to see its documentation.

diff --git a/docs/core.html b/docs/core.html index cbe871c..edc8a35 100644 --- a/docs/core.html +++ b/docs/core.html @@ -63,7 +63,7 @@ Basic syntax Stacked tabs
Contextual Text highlighting Toasts - Tooltips + Tooltips Modals
Progress Basic progress bar Progress bar variants Donut spinner Donut spinner variants diff --git a/docs/customization/card.html b/docs/customization/card.html index f31eea5..89d954c 100644 --- a/docs/customization/card.html +++ b/docs/customization/card.html @@ -63,7 +63,8 @@ Tab styling
Contextual Text highlighting Toasts - Tooltips Text highlighting mixins + Tooltips Modals + Text highlighting mixins Toast mixins Tooltip mixins
Progress Progress bar Donut spinner diff --git a/docs/customization/contextual.html b/docs/customization/contextual.html index e16e03e..87ff0dd 100644 --- a/docs/customization/contextual.html +++ b/docs/customization/contextual.html @@ -62,7 +62,8 @@ Tab styling
Contextual Text highlighting Toasts - Tooltips Text highlighting mixins + Tooltips Modals + Text highlighting mixins Toast mixins Tooltip mixins
Progress Progress bar Donut spinner @@ -79,7 +80,7 @@

Contextual

-

The contextual module provides you with simple tags, marks and highlights for your pages, allowing you to easily emphasize parts of your text. Contextual toasts and tooltips are also provided, aiming to help deliver important information to users. HTML5 elements and simple rules are used in order to make important messages and pieces of content stand out easily.


+

The contextual module provides you with simple tags, marks and highlights for your pages, allowing you to easily emphasize parts of your text. Contextual toasts, tooltips and modals are also provided, aiming to help deliver important information to users. HTML5 elements and simple rules are used in order to make important messages and pieces of content stand out easily.


@@ -212,7 +213,7 @@

Tooltips

-

The contextual module's contains a flag to enable or disable tooltips, custom classes for creating them and other variables for style customization.


+

The contextual module contains a flag to enable or disable tooltips, custom classes for creating them and other variables for style customization.


@@ -268,6 +269,59 @@ +
+
+
+

Modals

+
+

The contextual module contains a flag to enable or disable modals, a custom class for creating them and other variables for style customization.


+
Variables
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Variables
VariableTypeDescriptionSample value
$include-modalLogicalEnables modal components1true
$modal-nameStringClass name for modal components1'modal'
$modal-back-colorColorBackground color for modal components1black
$modal-back-opacityOpacityBackground opacity for modal components10.4
$modal-close-nameStringClass name of the close button of the modal component1'close'
$modal-close-topPosition topTop position of the close button of the modal component112px
$modal-close-rightPosition rightRight position of the close button of the modal component14px

+
+
+

Notes:

+
    + +
+
+
+
+
+
diff --git a/docs/customization/core.html b/docs/customization/core.html index f9bcc86..ea03a46 100644 --- a/docs/customization/core.html +++ b/docs/customization/core.html @@ -62,7 +62,8 @@ Tab styling
Contextual Text highlighting Toasts - Tooltips Text highlighting mixins + Tooltips Modals + Text highlighting mixins Toast mixins Tooltip mixins
Progress Progress bar Donut spinner diff --git a/docs/customization/grid.html b/docs/customization/grid.html index 9a92618..fb5f45b 100644 --- a/docs/customization/grid.html +++ b/docs/customization/grid.html @@ -64,7 +64,8 @@ Tab styling
Contextual Text highlighting Toasts - Tooltips Text highlighting mixins + Tooltips Modals + Text highlighting mixins Toast mixins Tooltip mixins
Progress Progress bar Donut spinner diff --git a/docs/customization/index.html b/docs/customization/index.html index b5a5c05..df1888b 100644 --- a/docs/customization/index.html +++ b/docs/customization/index.html @@ -61,7 +61,8 @@ Tab styling
Contextual Text highlighting Toasts - Tooltips Text highlighting mixins + Tooltips Modals + Text highlighting mixins Toast mixins Tooltip mixins
Progress Progress bar Donut spinner diff --git a/docs/customization/input_control.html b/docs/customization/input_control.html index 9e751f4..3f32ad8 100644 --- a/docs/customization/input_control.html +++ b/docs/customization/input_control.html @@ -63,7 +63,8 @@ Tab styling
Contextual Text highlighting Toasts - Tooltips Text highlighting mixins + Tooltips Modals + Text highlighting mixins Toast mixins Tooltip mixins
Progress Progress bar Donut spinner diff --git a/docs/customization/navigation.html b/docs/customization/navigation.html index 8bc0109..ce4fa5e 100644 --- a/docs/customization/navigation.html +++ b/docs/customization/navigation.html @@ -62,7 +62,8 @@ Tab styling
Contextual Text highlighting Toasts - Tooltips Text highlighting mixins + Tooltips Modals + Text highlighting mixins Toast mixins Tooltip mixins
Progress Progress bar Donut spinner diff --git a/docs/customization/progress.html b/docs/customization/progress.html index 2c4c8fc..a5d92e6 100644 --- a/docs/customization/progress.html +++ b/docs/customization/progress.html @@ -64,7 +64,8 @@ Tab styling
Contextual Text highlighting Toasts - Tooltips Text highlighting mixins + Tooltips Modals + Text highlighting mixins Toast mixins Tooltip mixins
Progress Progress bar Donut spinner diff --git a/docs/customization/tab.html b/docs/customization/tab.html index b3e442e..9af8750 100644 --- a/docs/customization/tab.html +++ b/docs/customization/tab.html @@ -62,7 +62,8 @@ Tab styling
Contextual Text highlighting Toasts - Tooltips Text highlighting mixins + Tooltips Modals + Text highlighting mixins Toast mixins Tooltip mixins
Progress Progress bar Donut spinner diff --git a/docs/customization/table.html b/docs/customization/table.html index 2cadd04..bb7de4f 100644 --- a/docs/customization/table.html +++ b/docs/customization/table.html @@ -62,7 +62,8 @@ Tab styling
Contextual Text highlighting Toasts - Tooltips Text highlighting mixins + Tooltips Modals + Text highlighting mixins Toast mixins Tooltip mixins
Progress Progress bar Donut spinner diff --git a/docs/customization/utility.html b/docs/customization/utility.html index 8b60f2c..93a7a4b 100644 --- a/docs/customization/utility.html +++ b/docs/customization/utility.html @@ -62,7 +62,8 @@ Tab styling
Contextual Text highlighting Toasts - Tooltips Text highlighting mixins + Tooltips Modals + Text highlighting mixins Toast mixins Tooltip mixins
Progress Progress bar Donut spinner diff --git a/docs/grid.html b/docs/grid.html index 40cccbb..3c98aa0 100644 --- a/docs/grid.html +++ b/docs/grid.html @@ -65,7 +65,7 @@ Basic syntax Stacked tabs
Contextual Text highlighting Toasts - Tooltips + Tooltips Modals
Progress Basic progress bar Progress bar variants Donut spinner Donut spinner variants diff --git a/docs/input_control.html b/docs/input_control.html index e86b953..c89d123 100644 --- a/docs/input_control.html +++ b/docs/input_control.html @@ -65,7 +65,7 @@ Basic syntax Stacked tabs
Contextual Text highlighting Toasts - Tooltips + Tooltips Modals
Progress Basic progress bar Progress bar variants Donut spinner Donut spinner variants diff --git a/docs/modules.html b/docs/modules.html index eb40038..8bdce77 100644 --- a/docs/modules.html +++ b/docs/modules.html @@ -58,7 +58,7 @@ Basic syntax Stacked tabs
Contextual Text highlighting Toasts - Tooltips + Tooltips Modals
Progress Basic progress bar Progress bar variants Donut spinner Donut spinner variants @@ -167,10 +167,11 @@

 Contextual

-

The contextual module provides you with simple tags, marks and highlights for your pages, allowing you to easily emphasize parts of your text. Contextual toasts and tooltips are also provided, aiming to help deliver important information to users. HTML5 elements and simple rules are used in order to make important messages and pieces of content stand out easily. More specifically, the contextual module contains:

diff --git a/docs/navigation.html b/docs/navigation.html index 8bf8971..e962544 100644 --- a/docs/navigation.html +++ b/docs/navigation.html @@ -67,7 +67,7 @@ Basic syntax Stacked tabs
Contextual Text highlighting Toasts - Tooltips + Tooltips Modals
Progress Basic progress bar Progress bar variants Donut spinner Donut spinner variants diff --git a/docs/progress.html b/docs/progress.html index 3e98fe9..4ce7144 100644 --- a/docs/progress.html +++ b/docs/progress.html @@ -63,7 +63,7 @@ Basic syntax Stacked tabs
Contextual Text highlighting Toasts - Tooltips + Tooltips Modals
Progress Basic progress bar Progress bar variants Donut spinner Donut spinner variants diff --git a/docs/quick_reference.html b/docs/quick_reference.html index abbf267..2eb9296 100644 --- a/docs/quick_reference.html +++ b/docs/quick_reference.html @@ -1025,6 +1025,30 @@
+
+
+

Modals  View on Codepen

+
<label for="modal-toggle">Show modal</label>
+
+<input id="modal-toggle" type="checkbox"/>
+<div class="modal">
+  <div class="card">
+    <label for="modal-toggle" class="close"></label>
+    <h3 class="section">Modal</h3>
+    <p class="section">This is a modal window!</p>
+  </div>
+</div>
+
+
+

Notes

+
    +
  • Create an <input type="checkbox"> element, immediately followed by a <div> element with the .modal class
  • +
  • Use a .card inside the .modal to display contents
  • +
  • Remember to use a <label> or some Javascript to allow users to close the dialog
  • +
  • Modal dialogs can be placed and toggled from anywhere, although the structure must be kept intact
  • +
+
+
diff --git a/docs/tab.html b/docs/tab.html index e8abe09..f263565 100644 --- a/docs/tab.html +++ b/docs/tab.html @@ -63,7 +63,7 @@ Basic syntax Stacked tabs
Contextual Text highlighting Toasts - Tooltips + Tooltips Modals
Progress Basic progress bar Progress bar variants Donut spinner Donut spinner variants diff --git a/docs/table.html b/docs/table.html index 74d1756..0a89043 100644 --- a/docs/table.html +++ b/docs/table.html @@ -69,7 +69,7 @@ Basic syntax Stacked tabs
Contextual Text highlighting Toasts - Tooltips + Tooltips Modals
Progress Basic progress bar Progress bar variants Donut spinner Donut spinner variants diff --git a/docs/utility.html b/docs/utility.html index fe2b9c6..5a0dbd1 100644 --- a/docs/utility.html +++ b/docs/utility.html @@ -64,7 +64,7 @@ Basic syntax Stacked tabs
Contextual Text highlighting Toasts - Tooltips + Tooltips Modals
Progress Basic progress bar Progress bar variants Donut spinner Donut spinner variants diff --git a/docs/v2/DEVLOG.md b/docs/v2/DEVLOG.md index 88cd43b..fa5c86b 100644 --- a/docs/v2/DEVLOG.md +++ b/docs/v2/DEVLOG.md @@ -1220,3 +1220,9 @@ - All changes have been tested and no errors were found (as far as I can tell). - Created the `.modal` component, added to the `default` flavor, documenting and adding to other flavors pending. - Updated all flavors for the new `.modal` component to be included (or not) as needed. + +## 20170606 + +- Fully documented `modal` component. +- Added navigation for `modal` component. +- Documented customization of `modal` component.