0
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-01-18 10:52:19 +01:00

Introduce posibility to disable !important suffix for utility classes (#29625)

This commit is contained in:
Martijn Cuppens 2020-02-10 15:05:07 +01:00 committed by GitHub
parent a0811af216
commit 6e8ea2722d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 1 deletions

View File

@ -227,6 +227,7 @@ $enable-pointer-cursor-for-buttons: true !default;
$enable-rfs: true !default;
$enable-validation-icons: true !default;
$enable-deprecation-messages: true !default;
$enable-important-utilities: true !default;
// Spacing

View File

@ -28,7 +28,7 @@
.#{$property-class + $infix + $property-class-modifier} {
@each $property in $properties {
// stylelint-disable-next-line declaration-no-important
#{$property}: $value !important;
#{$property}: $value if($enable-important-utilities, !important, null);
}
}
}

View File

@ -273,6 +273,7 @@ You can find and customize these variables for key global options in Bootstrap's
| `$enable-rfs` | `true` (default) or `false` | Globally enables [RFS]({{< docsref "/getting-started/rfs" >}}). |
| `$enable-validation-icons` | `true` (default) or `false` | Enables `background-image` icons within textual inputs and some custom forms for validation states. |
| `$enable-deprecation-messages` | `true` or `false` (default) | Set to `true` to show warnings when using any of the deprecated mixins and functions that are planned to be removed in `v5`. |
| `$enable-important-utilities` | `true` (default) or `false` | Enables the `!important` suffix in utility classes. |
## Color