Slide 46
Slide 46 text
when - Less
.buttons(@color, @type) when (@type == ‘flat’) {
background-color: $color;
}
.buttons(@color, @type) when (@type == ‘gradient’) {
background: linear-gradient($color, darken($color, 20%));
}
.buttons(@color, @type) when (@type == ‘glossy’) {
background: linear-gradient($color, darken($color, 20%) 50%);
}
.button {
.buttons(green, glossy);
}