Skip to content

Instantly share code, notes, and snippets.

@mlmorg
Forked from anonymous/FEqnv.markdown
Created May 31, 2014 17:28
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save mlmorg/5826495dd287b1c7bea9 to your computer and use it in GitHub Desktop.
<div class="table">
<div class="table-row">Header</div>
<div class="table-row table-row--expanded">
<div class="table">
<div class="table-cell">
<div class="content">Content</div>
</div>
</div>
</div>
<div class="table-row">Footer</div>
</div>
body, html {
margin:0;
padding:0;
height:100%;
}
.table {
display:table;
width:100%;
height:100%;
}
.table-row {
display: table-row;
height: 1px;
}
.table-row--expanded {
height: auto;
}
.table-cell {
display:table-cell;
}
.content {
height: 100%;
max-width: 500px;
margin: 0 auto;
background: #000;
color:#fff;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment