Skip to content

Instantly share code, notes, and snippets.

@Androguide
Created January 29, 2014 09:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Androguide/8684421 to your computer and use it in GitHub Desktop.
Save Androguide/8684421 to your computer and use it in GitHub Desktop.
Sass mixin for prefixing the opacity propery
@mixin setOpacity($amount) {
-moz-opacity: $amount / 100;
-khtml-opacity: $amount / 100;
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=" + $amount + ")";
filter: alpha(opacity=$amount);
opacity: $amount / 100;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment