Created
March 8, 2012 15:22
-
-
Save andrewrocco/2001481 to your computer and use it in GitHub Desktop.
Helpful Sass Mixins
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
@mixin border-radius ( $value: 3px ) { | |
-webkit-border-radius: $value; | |
-moz-border-radius: $value; | |
border-radius: $value; | |
// keeps background from busting out of border | |
-webkit-background-clip: padding-box; | |
-moz-background-clip: padding; | |
background-clip: padding-box; | |
} |
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
@mixin box-shadow( $horiz : .5em , $vert : .5em , $blur : 0px , $spread : 0px , $color : #000000 ){ | |
-webkit-box-shadow: $horiz $vert $blur $spread $color; | |
-moz-box-shadow: $horiz $vert $blur $spread $color; | |
box-shadow: $horiz $vert $blur $spread $color; | |
} |
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
@mixin facit { | |
font-family: “facitweb”, Verdana, Arial, sans-serif; | |
} |
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
@mixin font-size( $value: 12 ) { | |
font-size: value + px; | |
font − size: (value / 10) + rem; | |
} |
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
@mixin opacity ( $value: 0.5 ) { | |
opacity: $value; | |
-ms-filter: “progid:DXImageTransform.Microsoft.Alpha(Opacity=” $value * 100 “)”; | |
filter: alpha(opacity= $value * 100 ); | |
zoom: 1; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment