Last active
February 5, 2016 18:56
-
-
Save mallendeo/6275778 to your computer and use it in GitHub Desktop.
SCSS mixin for make long shadows easier
This file contains hidden or 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
@function makelongshadow($color) { | |
$val: (); | |
@for $i from 1 through 100 { | |
$val: append($val, append(#{$i}px #{($i)}px 0, darken($color, 15%)), comma); | |
/* Uncomment the following two lines for expanded shadow */ | |
/* $val: append($val, append(#{$i}px #{($i * 2)}px 0, darken($color, 15%)), comma); | |
$val: append($val, append(#{$i * 2}px #{$i}px 0, darken($color, 15%)), comma); */ | |
} | |
@return $val; | |
} | |
@mixin long-shadow($color) { | |
text-shadow: makelongshadow($color); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment