Created
July 18, 2014 17:55
-
-
Save daneden/ec73794e23abc9ccb284 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
// Involves some hacky manually-coded pixel values, but a lifesaver for debugging grids | |
@if $debug { | |
.debug--cols { | |
@each $group in $col-groups { | |
.grid--debug-#{$group}-cols:before { | |
content: ''; | |
position: absolute; | |
margin: 0 auto; | |
top: 0; | |
right: 0; | |
bottom: 0; | |
left: 0; | |
$cols: $group; | |
$output: (); | |
@for $i from 1 to $cols { | |
$output: append($output, #{"#{transparentize($blue, .95)} #{percentage($i/$cols)},"}); | |
$output: append($output, #{"transparent #{percentage($i/$cols)},"}); | |
$output: append($output, #{"transparent calc( #{percentage($i/$cols)} + 30px ),"}); | |
$output: append($output, #{"#{transparentize($blue, .95)} calc( #{percentage($i/$cols)} + 30px ),"}); | |
} | |
background-image: linear-gradient(left, | |
transparent, | |
transparent 30px, | |
transparentize($blue, .95) 30px, | |
unquote($output) | |
transparentize($blue, .95) 100% | |
); | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment