-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Labels
Description
Thanks for these awesome mixins!
I noticed that the Trapezoid doesn't work if you have the global rule for box-sizing: border-box;
So, for good measure in case someone has it declared in their stylesheet, I suggest you add box-sizing: content-box; to the Trapezoid's mixin.
Like this:
@mixin trapezoid($width, $color) {
width: $width;
height: 0;
border-right: $width / 2 solid transparent;
border-bottom: $width solid $color;
border-left: $width / 2 solid transparent;
box-sizing: content-box;
}
See a demo of this issue here: http://jsfiddle.net/rzea/f3ELf/1/
Just uncomment the line with box-sizing: content-box; to see the Trapezoid work.
Disclaimer: I am not a Sass expert by any means so I'm not 100% sure this is the best way to solve this issue. If it is, awesome, if not and you have a better solution, great too.
Thanks,