Skip to content

Instantly share code, notes, and snippets.

@oslego
Created December 13, 2011 18:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save oslego/1473169 to your computer and use it in GitHub Desktop.
Save oslego/1473169 to your computer and use it in GitHub Desktop.
CSS Regions and Grid Template
/* Region related style for redirecting content flows */
#article {
flow-into: article_flow;
}
#region1, #region2, #region3, #region4 {
flow-from: article_flow;
}
/* positioning and sizing of the region elements */
#page {
width: 800px;
height: 600px;
grid-template: "aaa.e"
"....e"
"bbb.e"
"....e"
"c.d.e";
grid-rows: 52% 4% 20% 4% 20%;
grid-columns: 30% 5% 30% 5% 30%;
}
#regionA { grid-cell: a; }
#region1 { grid-cell: b; }
#region2 { grid-cell: c; }
#region3 { grid-cell: d; }
#region4 { grid-cell: e; }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment