Skip to content

Instantly share code, notes, and snippets.

@goddamnyouryan
Created September 2, 2014 04:08
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 goddamnyouryan/ce581b000929708aa245 to your computer and use it in GitHub Desktop.
Save goddamnyouryan/ce581b000929708aa245 to your computer and use it in GitHub Desktop.
Sass For Salvattore 1-9 columns
@each $columns in (1, 2, 3, 4, 5, 6, 7, 8, 9) {
&[data-columns="#{$columns}"]::before { content: "#{$columns} .column.size-#{$columns}"; }
.size-#{$columns} {
$width: (100% - ($gutter * ($columns - 1))) / $columns;
width: $width;
&:nth-child(#{$columns}) {
margin-right: 0;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment