Created
February 10, 2014 12:25
-
-
Save lunelson/8914969 to your computer and use it in GitHub Desktop.
Ref for libsass issue
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
// ---- | |
// Sass (v3.3.0.rc.3) | |
// Compass (v1.0.0.alpha.18) | |
// ---- | |
@mixin hidpi($num, $denom: 1) { | |
@media | |
(-webkit-min-device-pixel-ratio: $num/$denom), | |
(min--moz-device-pixel-ratio: $num/$denom), | |
(-o-min-device-pixel-ratio: #{$num}/#{$denom}), | |
(min-device-pixel-ratio: $num/$denom), | |
(min-resolution: $num/$denom * 96dpi), | |
(min-resolution: $num/$denom * 1dppx) { | |
@content; | |
} | |
} | |
.test { | |
@media only screen and (min-width: 700px) { | |
@include hidpi(3,2) { | |
color: red; | |
} | |
} | |
} |
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
@media only screen and (min-width: 700px) and (-webkit-min-device-pixel-ratio: 1.5), only screen and (min-width: 700px) and (min--moz-device-pixel-ratio: 1.5), only screen and (min-width: 700px) and (-o-min-device-pixel-ratio: 3 / 2), only screen and (min-width: 700px) and (min-device-pixel-ratio: 1.5), only screen and (min-width: 700px) and (min-resolution: 144dpi), only screen and (min-width: 700px) and (min-resolution: 1.5dppx) { | |
.test { | |
color: red; } } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
written as reference for a libsass issue