Skip to content

Instantly share code, notes, and snippets.

@chriswrightdesign
Created November 6, 2013 21:55
Show Gist options
  • Save chriswrightdesign/7344768 to your computer and use it in GitHub Desktop.
Save chriswrightdesign/7344768 to your computer and use it in GitHub Desktop.
An experiment with a tinted background and IE8 flag similar to the Guardian's media queries one. In the case of not using Modernizr and having a seperate IE8 and below stylesheet.
$IE8:false;
@mixin tinted-black(image) {
@if ($IE8 == false) {
background:
/* top, transparent red, faked with gradient */
linear-gradient(
rgba(0, 0, 0, 0.45),
rgba(0, 0, 0, 0.45)
),
}
else {
background: url(image);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment