Created
January 23, 2014 12:42
-
-
Save seven-phases-max/8577903 to your computer and use it in GitHub Desktop.
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
// ............... | |
@grid-columns: 5; | |
@grid-gutter-width: 33px; | |
// ............... | |
.col-xs-1, | |
.col-sm-1, | |
.col-md-1, | |
.col-lg-1 { | |
position: relative; | |
// Prevent columns from collapsing when empty | |
min-height: 1px; | |
// Inner gutter via padding | |
padding-left: (@grid-gutter-width / 2); | |
padding-right: (@grid-gutter-width / 2); | |
} | |
.make-grid-columns() { | |
.col(); // kickstart it | |
.col(@index: @grid-columns) when (@index > 1) { | |
.col((@index - 1)); | |
.col-xs-@{index}, | |
.col-sm-@{index}, | |
.col-md-@{index}, | |
.col-lg-@{index} { | |
&:extend(.col-xs-1); | |
} | |
} | |
} | |
// ............... | |
.make-grid-columns(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment