_sass/bootstrap/_alert.scss in paraqeet-0.7.0 vs _sass/bootstrap/_alert.scss in paraqeet-0.8.0
- old
+ new
@@ -10,10 +10,11 @@
--#{$prefix}alert-margin-bottom: #{$alert-margin-bottom};
--#{$prefix}alert-color: inherit;
--#{$prefix}alert-border-color: transparent;
--#{$prefix}alert-border: #{$alert-border-width} solid var(--#{$prefix}alert-border-color);
--#{$prefix}alert-border-radius: #{$alert-border-radius};
+ --#{$prefix}alert-link-color: inherit;
// scss-docs-end alert-css-vars
position: relative;
padding: var(--#{$prefix}alert-padding-y) var(--#{$prefix}alert-padding-x);
margin-bottom: var(--#{$prefix}alert-margin-bottom);
@@ -30,10 +31,11 @@
}
// Provide class for links that match alerts
.alert-link {
font-weight: $alert-link-font-weight;
+ color: var(--#{$prefix}alert-link-color);
}
// Dismissible alerts
//
@@ -52,20 +54,15 @@
}
}
// scss-docs-start alert-modifiers
-// Generate contextual modifier classes for colorizing the alert.
-
-@each $state, $value in $theme-colors {
- $alert-background: shift-color($value, $alert-bg-scale);
- $alert-border: shift-color($value, $alert-border-scale);
- $alert-color: shift-color($value, $alert-color-scale);
-
- @if (contrast-ratio($alert-background, $alert-color) < $min-contrast-ratio) {
- $alert-color: mix($value, color-contrast($alert-background), abs($alert-color-scale));
- }
+// Generate contextual modifier classes for colorizing the alert
+@each $state in map-keys($theme-colors) {
.alert-#{$state} {
- @include alert-variant($alert-background, $alert-border, $alert-color);
+ --#{$prefix}alert-color: var(--#{$prefix}#{$state}-text);
+ --#{$prefix}alert-bg: var(--#{$prefix}#{$state}-bg-subtle);
+ --#{$prefix}alert-border-color: var(--#{$prefix}#{$state}-border-subtle);
+ --#{$prefix}alert-link-color: var(--#{$prefix}#{$state}-text);
}
}
// scss-docs-end alert-modifiers