Last active
December 30, 2015 18:18
-
-
Save ryanburgess/7866203 to your computer and use it in GitHub Desktop.
Add opacity to a class in your SASS file using the Opacity SASS Mixin.
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
// ----------------------------------------- | |
// Opacity | |
// ------------------------------------------- | |
// example: @include opacity(0.8); | |
@mixin opacity($opacity) { | |
opacity: $opacity; | |
$opacity-ie: $opacity * 100; | |
filter: alpha(opacity=$opacity-ie); //IE8 | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment