2016-02-15 08:27:41 -06:00
|
|
|
|
|
|
|
// Button backgrounds
|
|
|
|
// ------------------
|
2017-08-21 04:08:58 -05:00
|
|
|
@mixin buttonBackground($startColor, $endColor, $text-color: #fff, $textShadow: 0px 1px 0 rgba(0,0,0,.1)) {
|
2016-02-15 08:27:41 -06:00
|
|
|
// gradientBar will set the background to a pleasing blend of these, to support IE<=9
|
2016-02-16 02:42:46 -06:00
|
|
|
@include gradientBar($startColor, $endColor, $text-color, $textShadow);
|
2016-02-15 08:27:41 -06:00
|
|
|
|
|
|
|
// in these cases the gradient won't cover the background, so we override
|
|
|
|
&:hover, &:focus, &:active, &.active, &.disabled, &[disabled] {
|
2016-02-16 02:42:46 -06:00
|
|
|
color: $text-color;
|
2016-02-15 08:27:41 -06:00
|
|
|
background-image: none;
|
2016-02-18 13:41:23 -06:00
|
|
|
background-color: $startColor;
|
2016-02-15 08:27:41 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2016-02-18 05:16:47 -06:00
|
|
|
// Button sizes
|
|
|
|
@mixin button-size($padding-y, $padding-x, $font-size, $border-radius) {
|
|
|
|
padding: $padding-y $padding-x;
|
|
|
|
font-size: $font-size;
|
2016-02-18 13:41:23 -06:00
|
|
|
//box-shadow: inset 0 (-$padding-y/3) rgba(0,0,0,0.15);
|
2016-02-18 08:22:20 -06:00
|
|
|
|
2016-02-18 05:16:47 -06:00
|
|
|
@include border-radius($border-radius);
|
|
|
|
}
|
2016-02-18 07:44:36 -06:00
|
|
|
|
|
|
|
@mixin button-outline-variant($color) {
|
|
|
|
color: $color;
|
|
|
|
background-image: none;
|
|
|
|
background-color: transparent;
|
|
|
|
border-color: $color;
|
|
|
|
|
|
|
|
@include hover {
|
|
|
|
color: #fff;
|
|
|
|
background-color: $color;
|
|
|
|
border-color: $color;
|
|
|
|
}
|
|
|
|
|
|
|
|
&:focus,
|
|
|
|
&.focus {
|
|
|
|
color: #fff;
|
|
|
|
background-color: $color;
|
|
|
|
border-color: $color;
|
|
|
|
}
|
|
|
|
|
|
|
|
&:active,
|
|
|
|
&.active,
|
|
|
|
.open > &.dropdown-toggle {
|
|
|
|
color: #fff;
|
|
|
|
background-color: $color;
|
|
|
|
border-color: $color;
|
|
|
|
|
|
|
|
&:hover,
|
|
|
|
&:focus,
|
|
|
|
&.focus {
|
|
|
|
color: #fff;
|
|
|
|
background-color: darken($color, 17%);
|
|
|
|
border-color: darken($color, 25%);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&.disabled,
|
|
|
|
&:disabled {
|
|
|
|
&:focus,
|
|
|
|
&.focus {
|
|
|
|
border-color: lighten($color, 20%);
|
|
|
|
}
|
|
|
|
@include hover {
|
|
|
|
border-color: lighten($color, 20%);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|