Skip to content

Instantly share code, notes, and snippets.

@mehulkar
Created July 26, 2012 01:16
Show Gist options
  • Save mehulkar/3179710 to your computer and use it in GitHub Desktop.
Save mehulkar/3179710 to your computer and use it in GitHub Desktop.
Example of Webkit Flex Box
<html>
<head>
<style type="text/css">
html, body, .container {width: 100%; height: 100%;}
.container {display: -webkit-box; -webkit-box-orient: vertical; -webkit-box-align: stretch; -webkit-box-pack: start;}
.container div {-webkit-box-flex: 1;}
</style>
</head>
<body style="width: 100%;height: 100%;">
<div class="container">
<div style="background: yellow; -webkit-box-ordinal-group: 2;"> 1 </div>
<div style="background: purple; -webkit-box-ordinal-group: 3;"> 2 </div>
<div style="background: salmon; -webkit-box-ordinal-group: 1;"> 3 </div>
</div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment