Skip to content

Instantly share code, notes, and snippets.

@avand
Created October 2, 2010 00:12
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 avand/607088 to your computer and use it in GitHub Desktop.
Save avand/607088 to your computer and use it in GitHub Desktop.
$column_width: 60px;
$gutter_width: 10px;
@mixin container($number_of_columns: 12) {
margin-left: auto;
margin-right: auto;
width: $number_of_columns * $column_width;
}
@mixin grid($number_of_columns) {
display: inline;
float: left;
position: relative;
margin: {
left: $gutter_width / 2;
right: $gutter_width / 2;
}
width: ($column_width * $number_of_columns) - $gutter_width;
}
@mixin prefix($number_of_columns) {
padding-left: $column_width * $number_of_columns;
}
@mixin suffix($number_of_columns) {
padding-right: $column_width * $number_of_columns;
}
@mixin push($number_of_columns) {
left: $column_width * $number_of_columns;
}
@mixin pull($number_of_columns) {
right: $column_width * $number_of_columns;
}
@mixin alpha {
margin-left: 0 !important;
}
@mixin omega {
margin-right: 0 !important;
}
.clearfix:after {
clear: both;
content: ' ';
display: block;
font-size: 0;
line-height: 0;
visibility: hidden;
width: 0;
height: 0; }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment