Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View renekoch's full-sized avatar

Rene Koch renekoch

  • First Edition ApS
  • Denmark
View GitHub Profile
@renekoch
renekoch / _rounded-corner.scss
Created April 10, 2013 13:01
Sass file for rounded-cormers
@mixin round-corner($vert, $horz, $radius: 4px) {
-webkit-border-#{$vert}-#{$horz}-radius: $radius;
-moz-border-radius-#{$vert}#{$horz}: $radius;
border-#{$vert}-#{$horz}-radius: $radius;
}
@mixin rounded-corners($radius:4px){
-webkit-border-radius: $radius;
-moz-border-radius: $radius;
-o-border-radius: $radius;
@renekoch
renekoch / _gradient.scss
Last active December 16, 2015 01:19
Sass file to set cross browser background gradient
@mixin gradient($color1, $color2, $dir : "h", $height: 100){
$webkit: right top;
$others: left;
$repeat: repeat-y;
@if ($dir == "horz") or ($dir == "h") or ($dir == "horizontal") {
$webkit: left bottom;
$others: top;
$repeat: repeat-x;
@renekoch
renekoch / _inline-block.scss
Created April 10, 2013 13:10
Sass file for cross-browser inline-block (NOTE: this does not work on native block elements in IE6/IE7)
@mixin inline-block($vert-align: top) {
display:inline;
display:-moz-inline-stack;
display:inline-block;
vertical-align: $vert-align;
zoom:1;
min-height:0px;
}
@renekoch
renekoch / _font-face.scss
Created April 10, 2013 14:22
Sass file, make a font face
@mixin font-face($font-family, $url, $weight: normal, $style: normal, $svgadd: "Regular") {
@font-face {
font-family: $font-family;
src: url($url + ".eot");
src: url($url + ".eot?#iefix") format("embedded-opentype"),
url($url + ".woff") format("woff"),
url($url + ".ttf") format("truetype"),
url($url + ".svg#" + $font-family + $svgadd) format("svg");
font-weight: $weight;
font-style: $style;