2
0
mirror of https://github.com/tenrok/bootstrap.git synced 2026-05-21 13:24:08 +03:00

feat(utilitites): try to ensure decent contrasts

This commit is contained in:
Gaël Poupard
2021-05-20 15:38:24 +02:00
committed by GitHub
parent 79c3bf47bc
commit 9f59d556b4
+6
View File
@@ -50,6 +50,12 @@
.#{$property-class + $infix + $property-class-modifier} {
@each $property in $properties {
#{$property}: $value if($enable-important-utilities, !important, null);
// Ensures decent contrast where possible
@if "background-color" == $property and "transparent" != inspect($value) {
color: color-contrast($value);
} @else if "color" == $property and "inherit" != inspect($value) and $accessible-orange != $value {
background-color: color-contrast($value);
}
}
}