Last active
January 18, 2020 21:47
-
-
Save okovalov/e03fb3ca4a82ee010eb4431eb13b8528 to your computer and use it in GitHub Desktop.
FlexBox sandbox
This file contains 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
<html> | |
<body> | |
<div class="screen"> | |
<div class="first box"> | |
1 | |
</div> | |
<div class="second box"> | |
2 | |
</div> | |
<div class="third box"> | |
3 | |
</div> | |
</div> | |
</body> | |
</html> |
This file contains 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
{ | |
"scripts": [], | |
"styles": [] | |
} |
This file contains 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
|
This file contains 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
.screen { | |
background-color: whitesmoke; | |
width: 80%; | |
height: 400px; | |
display: flex; | |
flex-direction: column; | |
justify-content: space-between; | |
/* align-items: center */ | |
} | |
.box { | |
display: flex; | |
flex: 1; | |
flex-direction: column; | |
justify-content: center; | |
align-items: center; | |
} | |
.first { | |
background-color: thistle; | |
} | |
.second { | |
background-color: orangered; | |
/* flex: 2 */ | |
} | |
.third { | |
background-color: palegreen; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment