mirror of https://github.com/twbs/bootstrap.git
adds hover state to the `button` element for background color utilities (#24813)
* adds a hover state to the button element on the backrgound color utitility * Adjust z-index to fix hover/focus overlaps
This commit is contained in:
parent
5621c800aa
commit
aacfcc248d
|
@ -59,6 +59,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
@include hover-focus {
|
@include hover-focus {
|
||||||
|
z-index: 1; // Place hover/active items above their siblings for proper border styling
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -70,7 +71,7 @@
|
||||||
|
|
||||||
// Include both here for `<a>`s and `<button>`s
|
// Include both here for `<a>`s and `<button>`s
|
||||||
&.active {
|
&.active {
|
||||||
z-index: 1; // Place active items above their siblings for proper border styling
|
z-index: 2; // Place active items above their siblings for proper border styling
|
||||||
color: $list-group-active-color;
|
color: $list-group-active-color;
|
||||||
background-color: $list-group-active-bg;
|
background-color: $list-group-active-bg;
|
||||||
border-color: $list-group-active-border-color;
|
border-color: $list-group-active-border-color;
|
||||||
|
|
|
@ -6,7 +6,8 @@
|
||||||
#{$parent} {
|
#{$parent} {
|
||||||
background-color: $color !important;
|
background-color: $color !important;
|
||||||
}
|
}
|
||||||
a#{$parent} {
|
a#{$parent},
|
||||||
|
button#{$parent} {
|
||||||
@include hover-focus {
|
@include hover-focus {
|
||||||
background-color: darken($color, 10%) !important;
|
background-color: darken($color, 10%) !important;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue