-
-
Save weltenwort/69713bd0b626061cd4338bc694a904fa to your computer and use it in GitHub Desktop.
JS Bin // source https://jsbin.com/kiyebeqezu
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta charset="utf-8"> | |
| <meta name="viewport" content="width=device-width"> | |
| <title>JS Bin</title> | |
| <style id="jsbin-css"> | |
| * { | |
| box-sizing: border-box; | |
| } | |
| .container { | |
| display: flex; | |
| flex-direction: column; | |
| height: 500px; | |
| } | |
| .container__half { | |
| flex-direction: column; | |
| flex: 1 0 0; | |
| display: flex; | |
| flex-direction: column; | |
| } | |
| .container__half--top { | |
| background: #ff0000; | |
| justify-content: flex-end; | |
| } | |
| .container__half--bottom { | |
| background: #dd0000; | |
| justify-content: flex-start; | |
| } | |
| .item { | |
| flex: 0 0 auto; | |
| background: orange; | |
| //border-top: 1px solid white; | |
| //border-bottom: 1px solid black; | |
| } | |
| </style> | |
| </head> | |
| <body> | |
| <div class="container"> | |
| <div class="container__half container__half--top"> | |
| <div class="item">1</div> | |
| </div> | |
| <div class="container__half container__half--bottom"> | |
| <div class="item">1</div> | |
| </div> | |
| </div> | |
| <script id="jsbin-source-css" type="text/css">* { | |
| box-sizing: border-box; | |
| } | |
| .container { | |
| display: flex; | |
| flex-direction: column; | |
| height: 500px; | |
| } | |
| .container__half { | |
| flex-direction: column; | |
| flex: 1 0 0; | |
| display: flex; | |
| flex-direction: column; | |
| } | |
| .container__half--top { | |
| background: #ff0000; | |
| justify-content: flex-end; | |
| } | |
| .container__half--bottom { | |
| background: #dd0000; | |
| justify-content: flex-start; | |
| } | |
| .item { | |
| flex: 0 0 auto; | |
| background: orange; | |
| //border-top: 1px solid white; | |
| //border-bottom: 1px solid black; | |
| }</script> | |
| </body> | |
| </html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| * { | |
| box-sizing: border-box; | |
| } | |
| .container { | |
| display: flex; | |
| flex-direction: column; | |
| height: 500px; | |
| } | |
| .container__half { | |
| flex-direction: column; | |
| flex: 1 0 0; | |
| display: flex; | |
| flex-direction: column; | |
| } | |
| .container__half--top { | |
| background: #ff0000; | |
| justify-content: flex-end; | |
| } | |
| .container__half--bottom { | |
| background: #dd0000; | |
| justify-content: flex-start; | |
| } | |
| .item { | |
| flex: 0 0 auto; | |
| background: orange; | |
| //border-top: 1px solid white; | |
| //border-bottom: 1px solid black; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment