Skip to content
This repository has been archived by the owner on Feb 8, 2018. It is now read-only.

Commit

Permalink
Add notes about modal component
Browse files Browse the repository at this point in the history
  • Loading branch information
rohitpaulk committed Jun 20, 2017
1 parent 892e7a4 commit a0cb411
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions scss/components/modal.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,42 @@
/*
* ======= MARKUP =======
*
* <div class="modal-wrapper">
* <div class="modal">
* <header>
* <h2>Title!</h2>
* <button class="close-modal">
* X
* </button>
* </header>
* <section>
* Your content here.
* </section>
* </div>
* </div>
*
* ======= VISUAL EXPLANATION =======
*
* div.modal-wrapper (full-screen)
*
* div.modal (horizontally centered)
* ----------------------------
* | header (button) [x] |
* |____________________________|
* | section |
* | |
* | |
* | |
* | |
* ----------------------------
*
* ======= NOTES =======
*
* - The modal width is not fixed. Set width on .modal directly, or it'll
* be decided by child content
* - To open/close, show/hide the .modal-wrapper div. Hidden by default.
*/

.modal-wrapper {
width: 100vw;
height: 100vh;
Expand Down

0 comments on commit a0cb411

Please sign in to comment.