Last active
August 29, 2015 14:07
-
-
Save stephanpavlovic/c7ab9fcb56fbeb29e6fb to your computer and use it in GitHub Desktop.
With Flexbox
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
<div class='wrapper'> | |
<div class='box'> | |
Hi | |
</div> | |
<div class='box'>Hi</div> | |
<div class='box'>Hi</div> | |
<div class='box'>Hi</div> | |
</div> |
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
// ---- | |
// Sass (v3.4.5) | |
// Compass (v1.0.1) | |
// ---- | |
.box | |
min-width: 200px | |
height: 100px | |
background: #006FBB | |
border: 1px solid white | |
padding: 10px | |
color: white | |
.wrapper | |
border: 4px solid #00933D | |
height: 200px | |
display: flex | |
flex-flow: row wrap | |
align-items: center | |
justify-content: space-around | |
.box | |
flex: none |
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 { | |
min-width: 200px; | |
height: 100px; | |
background: #006FBB; | |
border: 1px solid white; | |
padding: 10px; | |
color: white; | |
} | |
.wrapper { | |
border: 4px solid #00933D; | |
height: 200px; | |
display: flex; | |
flex-flow: row wrap; | |
align-items: center; | |
justify-content: space-around; | |
} | |
.wrapper .box { | |
flex: none; | |
} |
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
<div class='wrapper'> | |
<div class='box'> | |
Hi | |
</div> | |
<div class='box'>Hi</div> | |
<div class='box'>Hi</div> | |
<div class='box'>Hi</div> | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment