Skip to content

Instantly share code, notes, and snippets.

@smbriones
Created August 11, 2011 18:47
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 smbriones/1140412 to your computer and use it in GitHub Desktop.
Save smbriones/1140412 to your computer and use it in GitHub Desktop.
Columns in CSS3
/* To have the Title of the article reach accross the full
width of the article, as opposed to inline */
h2 {
-webkit-column-span: all;
}
/* To give the article 2 columns with a width of 250px */
article {
-webkit-column-count: 2;
-webkit-column-width: 250px;
}
/* To place the green box in the same place within the
column as in the original article. Tricky! */
div .slug {
height: 50px;
background: green;
-webkit-column-break-before: avoid;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment