Skip to content

Instantly share code, notes, and snippets.

View davidkaneda's full-sized avatar

David Kaneda davidkaneda

View GitHub Profile
@davidkaneda
davidkaneda / color-overlay.scss
Created February 20, 2012 20:59 — forked from nimbupani/color-overlay.scss
Sass Snippets
// Use @include colorize('image.png', red, 0.5)
@mixin colorize($image, $color, $opacity) {
background: $color;
$color: transparentize($color, 1 - $opacity);
background: -webkit-linear-gradient(left, $color, $color), url($image);
background: -moz-linear-gradient(left, $color, $color), url($image);
background: -ms-linear-gradient(left, $color, $color), url($image);
background: -o-linear-gradient(left, $color, $color), url($image);
}