Skip to content

Instantly share code, notes, and snippets.

@scrooloose
Created December 14, 2009 00:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save scrooloose/255694 to your computer and use it in GitHub Desktop.
Save scrooloose/255694 to your computer and use it in GitHub Desktop.
/* the sass file */
/*===============*/
=ultimate-hippie-border(!thickness)
border-top = !thickness "dotted" "magenta"
border-left = !thickness "solid" "orange"
border-right = !thickness "dashed" "green"
border-bottom = !thickness "groove" "blue"
background-color: cyan
div.foo
+ultimate-hippie-border(2px)
height: 100px
div.bar
+ultimate-hippie-border(20px)
width: 200px
/* the resulting css file */
/*========================*/
div.foo {
border-top: 2px dotted magenta;
border-left: 2px solid orange;
border-right: 2px dashed green;
border-bottom: 2px groove blue;
background-color: cyan;
height: 100px;
}
div.bar {
border-top: 20px dotted magenta;
border-left: 20px solid orange;
border-right: 20px dashed green;
border-bottom: 20px groove blue;
background-color: cyan;
width: 200px;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment