Skip to content

Instantly share code, notes, and snippets.

@mixin cssSprite( $spriteVals ) {
width: nth( $spriteVals, 1 );
height: nth( $spriteVals, 2 );
background-repeat: no-repeat;
background-image: url( #{ nth( $spriteVals, 3 ) } );
background-position: nth( $spriteVals, 4 ) nth( $spriteVals, 5 );
@media only screen and ( -webkit-min-device-pixel-ratio: 2 ), only screen and ( min-device-pixel-ratio: 2 ) {
background-image: url( #{ nth( $spriteVals, 6 ) } );
background-size: $bgiSizeW $bgiSizeH;
}