Last active
December 15, 2015 16:49
-
-
Save jmak/5291473 to your computer and use it in GitHub Desktop.
SASS triangle
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
=triangle($direction: right, $size: 10px, $color: #999) | |
width: 0 | |
height: 0 | |
line-height: 0 | |
border: $size solid transparent | |
@if $direction == top | |
border-bottom-color: $color | |
@else if $direction == right | |
border-left-color: $color | |
@else if $direction == bottom | |
border-top-color: $color | |
@else if $direction == left | |
border-right-color: $color | |
.triangle | |
+triangle(bottom, 30px, red) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment