mirror of
https://github.com/twbs/bootstrap.git
synced 2025-02-20 17:54:23 +01:00
Use -* vars for .bg-* and .text-* utilities
- Simplifies variables usage - Makes components and brand variable usage more consistent (dark bg and white text throughout instead of some mixed light and dark bgs) - Very likely means lower contrast and thus no more AA compliance (we'll want to fix that eventually obviously)
This commit is contained in:
parent
b2f9fe4a3e
commit
6a75d07e0c
@ -107,13 +107,13 @@
|
|||||||
|
|
||||||
@include text-emphasis-variant('.text-primary', $brand-primary);
|
@include text-emphasis-variant('.text-primary', $brand-primary);
|
||||||
|
|
||||||
@include text-emphasis-variant('.text-success', $state-success-text);
|
@include text-emphasis-variant('.text-success', $brand-success);
|
||||||
|
|
||||||
@include text-emphasis-variant('.text-info', $state-info-text);
|
@include text-emphasis-variant('.text-info', $brand-info);
|
||||||
|
|
||||||
@include text-emphasis-variant('.text-warning', $state-warning-text);
|
@include text-emphasis-variant('.text-warning', $brand-warning);
|
||||||
|
|
||||||
@include text-emphasis-variant('.text-danger', $state-danger-text);
|
@include text-emphasis-variant('.text-danger', $brand-danger);
|
||||||
|
|
||||||
|
|
||||||
// Contextual backgrounds
|
// Contextual backgrounds
|
||||||
@ -127,18 +127,12 @@
|
|||||||
background-color: $gray-dark;
|
background-color: $gray-dark;
|
||||||
}
|
}
|
||||||
|
|
||||||
.bg-primary {
|
|
||||||
// Given the contrast here, this is the only class to have its color inverted
|
|
||||||
// automatically.
|
|
||||||
color: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
@include bg-variant('.bg-primary', $brand-primary);
|
@include bg-variant('.bg-primary', $brand-primary);
|
||||||
|
|
||||||
@include bg-variant('.bg-success', $state-success-bg);
|
@include bg-variant('.bg-success', $brand-success);
|
||||||
|
|
||||||
@include bg-variant('.bg-info', $state-info-bg);
|
@include bg-variant('.bg-info', $brand-info);
|
||||||
|
|
||||||
@include bg-variant('.bg-warning', $state-warning-bg);
|
@include bg-variant('.bg-warning', $brand-warning);
|
||||||
|
|
||||||
@include bg-variant('.bg-danger', $state-danger-bg);
|
@include bg-variant('.bg-danger', $brand-danger);
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
// [converter] $parent hack
|
// [converter] $parent hack
|
||||||
@mixin bg-variant($parent, $color) {
|
@mixin bg-variant($parent, $color) {
|
||||||
#{$parent} {
|
#{$parent} {
|
||||||
|
color: #fff;
|
||||||
background-color: $color;
|
background-color: $color;
|
||||||
}
|
}
|
||||||
a#{$parent} {
|
a#{$parent} {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user