Skip to content

Instantly share code, notes, and snippets.

@geedmo
Last active December 15, 2015 18:49
Show Gist options
  • Save geedmo/5306214 to your computer and use it in GitHub Desktop.
Save geedmo/5306214 to your computer and use it in GitHub Desktop.
Kickstrap Flush Grid - with fluid grid support
// FLUSH GRIDS
// -------------------------
.row-fluid [class*="span"].flush, // increase specifity
[class*="span"].flush, {
margin-left: 0;
}
.spanXflush (@index) when (@index > 0) {
(~".span@{index}.flush") {
width: ((@gridColumnWidth + @gridGutterWidth) * @index);
}
.spanXflush(@index - 1);
}
.spanXflush (0) {}
.spanXflush (@gridColumns);
// FLUSH FLUID GRIDS
// -------------------------
.spanXfluidflush (@index) when (@index > 0) {
(~".span@{index}.flush") {
width: (((@fluidGridColumnWidth + @fluidGridGutterWidth) - 0.2) * @index); // a small decrease to properly align
}
.spanXfluidflush(@index - 1);
}
.spanXfluidflush (0) {}
.row-fluid {
.spanXfluidflush (@gridColumns);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment