Created
January 30, 2014 17:25
-
-
Save EdCharbeneau/8713896 to your computer and use it in GitHub Desktop.
A super simple, and minimal grid system.
This file contains 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
/* | |
A simple grid system | |
*/ | |
$layout-width: 980px; | |
$gutter:24px; | |
$small-device-width: 767px; | |
$vertical-whitespace: 20px; | |
// Predefined column widths | |
//golden ratio | |
$golden-small: 38.2%; | |
$golden-large: 61.8%; | |
//thirds | |
$one-third: 33.33%; | |
$two-thirds: 66.66%; | |
//quaters | |
$one-quarter: 25%; | |
$one-half: 50%; | |
$three-quarters: 75%; | |
@import "compass"; | |
* { | |
@include box-sizing(border-box); | |
} | |
// Grid Mixins | |
@mixin row() { | |
margin: 0 auto; | |
max-width: $layout-width; | |
*zoom: 1; | |
padding: $vertical-whitespace 0; | |
&:after { | |
content: ""; | |
display: table; | |
clear: both; | |
} | |
} | |
@mixin column($column-width:100%) { | |
float: left; | |
padding: 0 $gutter; | |
width: $column-width; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment