bootstrap 5.2.0 → 5.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +55 -0
- data/README.md +25 -5
- data/assets/javascripts/bootstrap/alert.js +22 -32
- data/assets/javascripts/bootstrap/base-component.js +22 -38
- data/assets/javascripts/bootstrap/button.js +19 -22
- data/assets/javascripts/bootstrap/carousel.js +52 -135
- data/assets/javascripts/bootstrap/collapse.js +40 -102
- data/assets/javascripts/bootstrap/dom/data.js +8 -12
- data/assets/javascripts/bootstrap/dom/event-handler.js +19 -66
- data/assets/javascripts/bootstrap/dom/manipulator.js +4 -17
- data/assets/javascripts/bootstrap/dom/selector-engine.js +42 -24
- data/assets/javascripts/bootstrap/dropdown.js +74 -143
- data/assets/javascripts/bootstrap/modal.js +66 -143
- data/assets/javascripts/bootstrap/offcanvas.js +50 -102
- data/assets/javascripts/bootstrap/popover.js +23 -29
- data/assets/javascripts/bootstrap/scrollspy.js +64 -97
- data/assets/javascripts/bootstrap/tab.js +55 -112
- data/assets/javascripts/bootstrap/toast.js +39 -77
- data/assets/javascripts/bootstrap/tooltip.js +99 -216
- data/assets/javascripts/bootstrap/util/backdrop.js +28 -54
- data/assets/javascripts/bootstrap/util/component-functions.js +13 -18
- data/assets/javascripts/bootstrap/util/config.js +15 -27
- data/assets/javascripts/bootstrap/util/focustrap.js +20 -36
- data/assets/javascripts/bootstrap/util/index.js +42 -111
- data/assets/javascripts/bootstrap/util/sanitizer.js +30 -42
- data/assets/javascripts/bootstrap/util/scrollbar.js +24 -50
- data/assets/javascripts/bootstrap/util/swipe.js +27 -48
- data/assets/javascripts/bootstrap/util/template-factory.js +25 -52
- data/assets/javascripts/bootstrap-sprockets.js +12 -12
- data/assets/javascripts/bootstrap.js +764 -1529
- data/assets/javascripts/bootstrap.min.js +3 -3
- data/assets/stylesheets/_bootstrap-grid.scss +1 -3
- data/assets/stylesheets/_bootstrap-reboot.scss +1 -0
- data/assets/stylesheets/_bootstrap.scss +1 -0
- data/assets/stylesheets/bootstrap/_accordion.scss +16 -4
- data/assets/stylesheets/bootstrap/_alert.scss +8 -11
- data/assets/stylesheets/bootstrap/_button-group.scss +3 -3
- data/assets/stylesheets/bootstrap/_buttons.scss +31 -10
- data/assets/stylesheets/bootstrap/_card.scss +5 -0
- data/assets/stylesheets/bootstrap/_carousel.scss +20 -5
- data/assets/stylesheets/bootstrap/_close.scss +32 -9
- data/assets/stylesheets/bootstrap/_dropdown.scss +3 -1
- data/assets/stylesheets/bootstrap/_functions.scss +3 -3
- data/assets/stylesheets/bootstrap/_grid.scss +6 -0
- data/assets/stylesheets/bootstrap/_helpers.scss +2 -0
- data/assets/stylesheets/bootstrap/_list-group.scss +18 -12
- data/assets/stylesheets/bootstrap/_maps.scss +120 -0
- data/assets/stylesheets/bootstrap/_mixins.scss +1 -2
- data/assets/stylesheets/bootstrap/_modal.scss +1 -1
- data/assets/stylesheets/bootstrap/_nav.scss +42 -5
- data/assets/stylesheets/bootstrap/_navbar.scss +17 -4
- data/assets/stylesheets/bootstrap/_offcanvas.scss +9 -6
- data/assets/stylesheets/bootstrap/_pagination.scss +1 -1
- data/assets/stylesheets/bootstrap/_popover.scss +5 -5
- data/assets/stylesheets/bootstrap/_progress.scss +10 -1
- data/assets/stylesheets/bootstrap/_reboot.scss +3 -3
- data/assets/stylesheets/bootstrap/_root.scss +121 -10
- data/assets/stylesheets/bootstrap/_tables.scss +18 -11
- data/assets/stylesheets/bootstrap/_toasts.scss +5 -2
- data/assets/stylesheets/bootstrap/_tooltip.scss +4 -5
- data/assets/stylesheets/bootstrap/_utilities.scss +172 -13
- data/assets/stylesheets/bootstrap/_variables-dark.scss +85 -0
- data/assets/stylesheets/bootstrap/_variables.scss +272 -162
- data/assets/stylesheets/bootstrap/bootstrap-utilities.scss +4 -0
- data/assets/stylesheets/bootstrap/forms/_floating-labels.scss +23 -3
- data/assets/stylesheets/bootstrap/forms/_form-check.scss +24 -11
- data/assets/stylesheets/bootstrap/forms/_form-control.scss +23 -3
- data/assets/stylesheets/bootstrap/forms/_form-select.scss +11 -2
- data/assets/stylesheets/bootstrap/forms/_input-group.scss +7 -4
- data/assets/stylesheets/bootstrap/helpers/_color-bg.scss +0 -2
- data/assets/stylesheets/bootstrap/helpers/_colored-links.scss +20 -2
- data/assets/stylesheets/bootstrap/helpers/_focus-ring.scss +5 -0
- data/assets/stylesheets/bootstrap/helpers/_icon-link.scss +25 -0
- data/assets/stylesheets/bootstrap/mixins/_alert.scss +4 -1
- data/assets/stylesheets/bootstrap/mixins/_banner.scss +3 -5
- data/assets/stylesheets/bootstrap/mixins/_caret.scss +30 -25
- data/assets/stylesheets/bootstrap/mixins/_color-mode.scss +21 -0
- data/assets/stylesheets/bootstrap/mixins/_forms.scss +18 -17
- data/assets/stylesheets/bootstrap/mixins/_list-group.scss +2 -0
- data/assets/stylesheets/bootstrap/mixins/_table-variants.scss +2 -2
- data/assets/stylesheets/bootstrap/mixins/_utilities.scss +2 -2
- data/assets/stylesheets/bootstrap/mixins/_visually-hidden.scss +5 -1
- data/assets/stylesheets/bootstrap/vendor/_rfs.scss +23 -29
- data/bootstrap.gemspec +1 -1
- data/lib/bootstrap/version.rb +2 -2
- data/tasks/updater/js.rb +2 -2
- data/tasks/updater/network.rb +2 -2
- data/tasks/updater/scss.rb +1 -1
- data/tasks/updater.rb +2 -2
- data/test/gemfiles/rails_5_2.gemfile +8 -0
- data/test/gemfiles/rails_7_0.gemfile +7 -0
- data/test/test_helper.rb +3 -2
- metadata +17 -9
- data/.travis.yml +0 -32
@@ -42,7 +42,6 @@
|
|
42
42
|
display: block;
|
43
43
|
}
|
44
44
|
|
45
|
-
/* rtl:begin:ignore */
|
46
45
|
.carousel-item-next:not(.carousel-item-start),
|
47
46
|
.active.carousel-item-end {
|
48
47
|
transform: translateX(100%);
|
@@ -53,8 +52,6 @@
|
|
53
52
|
transform: translateX(-100%);
|
54
53
|
}
|
55
54
|
|
56
|
-
/* rtl:end:ignore */
|
57
|
-
|
58
55
|
|
59
56
|
//
|
60
57
|
// Alternate transitions
|
@@ -168,7 +165,6 @@
|
|
168
165
|
margin-right: $carousel-control-width;
|
169
166
|
margin-bottom: 1rem;
|
170
167
|
margin-left: $carousel-control-width;
|
171
|
-
list-style: none;
|
172
168
|
|
173
169
|
[data-bs-target] {
|
174
170
|
box-sizing: content-box;
|
@@ -213,7 +209,7 @@
|
|
213
209
|
|
214
210
|
// Dark mode carousel
|
215
211
|
|
216
|
-
|
212
|
+
@mixin carousel-dark() {
|
217
213
|
.carousel-control-prev-icon,
|
218
214
|
.carousel-control-next-icon {
|
219
215
|
filter: $carousel-dark-control-icon-filter;
|
@@ -227,3 +223,22 @@
|
|
227
223
|
color: $carousel-dark-caption-color;
|
228
224
|
}
|
229
225
|
}
|
226
|
+
|
227
|
+
.carousel-dark {
|
228
|
+
@include carousel-dark();
|
229
|
+
}
|
230
|
+
|
231
|
+
@if $enable-dark-mode {
|
232
|
+
@include color-mode(dark) {
|
233
|
+
@if $color-mode-type == "media-query" {
|
234
|
+
.carousel {
|
235
|
+
@include carousel-dark();
|
236
|
+
}
|
237
|
+
} @else {
|
238
|
+
.carousel,
|
239
|
+
&.carousel {
|
240
|
+
@include carousel-dark();
|
241
|
+
}
|
242
|
+
}
|
243
|
+
}
|
244
|
+
}
|
@@ -4,37 +4,60 @@
|
|
4
4
|
// See https://developer.mozilla.org/en-US/docs/Web/Events/click#Safari_Mobile
|
5
5
|
|
6
6
|
.btn-close {
|
7
|
+
// scss-docs-start close-css-vars
|
8
|
+
--#{$prefix}btn-close-color: #{$btn-close-color};
|
9
|
+
--#{$prefix}btn-close-bg: #{ escape-svg($btn-close-bg) };
|
10
|
+
--#{$prefix}btn-close-opacity: #{$btn-close-opacity};
|
11
|
+
--#{$prefix}btn-close-hover-opacity: #{$btn-close-hover-opacity};
|
12
|
+
--#{$prefix}btn-close-focus-shadow: #{$btn-close-focus-shadow};
|
13
|
+
--#{$prefix}btn-close-focus-opacity: #{$btn-close-focus-opacity};
|
14
|
+
--#{$prefix}btn-close-disabled-opacity: #{$btn-close-disabled-opacity};
|
15
|
+
--#{$prefix}btn-close-white-filter: #{$btn-close-white-filter};
|
16
|
+
// scss-docs-end close-css-vars
|
17
|
+
|
7
18
|
box-sizing: content-box;
|
8
19
|
width: $btn-close-width;
|
9
20
|
height: $btn-close-height;
|
10
21
|
padding: $btn-close-padding-y $btn-close-padding-x;
|
11
|
-
color: $btn-close-color;
|
12
|
-
background: transparent
|
22
|
+
color: var(--#{$prefix}btn-close-color);
|
23
|
+
background: transparent var(--#{$prefix}btn-close-bg) center / $btn-close-width auto no-repeat; // include transparent for button elements
|
13
24
|
border: 0; // for button elements
|
14
25
|
@include border-radius();
|
15
|
-
opacity: $btn-close-opacity;
|
26
|
+
opacity: var(--#{$prefix}btn-close-opacity);
|
16
27
|
|
17
28
|
// Override <a>'s hover style
|
18
29
|
&:hover {
|
19
|
-
color: $btn-close-color;
|
30
|
+
color: var(--#{$prefix}btn-close-color);
|
20
31
|
text-decoration: none;
|
21
|
-
opacity: $btn-close-hover-opacity;
|
32
|
+
opacity: var(--#{$prefix}btn-close-hover-opacity);
|
22
33
|
}
|
23
34
|
|
24
35
|
&:focus {
|
25
36
|
outline: 0;
|
26
|
-
box-shadow: $btn-close-focus-shadow;
|
27
|
-
opacity: $btn-close-focus-opacity;
|
37
|
+
box-shadow: var(--#{$prefix}btn-close-focus-shadow);
|
38
|
+
opacity: var(--#{$prefix}btn-close-focus-opacity);
|
28
39
|
}
|
29
40
|
|
30
41
|
&:disabled,
|
31
42
|
&.disabled {
|
32
43
|
pointer-events: none;
|
33
44
|
user-select: none;
|
34
|
-
opacity: $btn-close-disabled-opacity;
|
45
|
+
opacity: var(--#{$prefix}btn-close-disabled-opacity);
|
35
46
|
}
|
36
47
|
}
|
37
48
|
|
49
|
+
@mixin btn-close-white() {
|
50
|
+
filter: var(--#{$prefix}btn-close-white-filter);
|
51
|
+
}
|
52
|
+
|
38
53
|
.btn-close-white {
|
39
|
-
|
54
|
+
@include btn-close-white();
|
55
|
+
}
|
56
|
+
|
57
|
+
@if $enable-dark-mode {
|
58
|
+
@include color-mode(dark) {
|
59
|
+
.btn-close {
|
60
|
+
@include btn-close-white();
|
61
|
+
}
|
62
|
+
}
|
40
63
|
}
|
@@ -18,6 +18,7 @@
|
|
18
18
|
// The dropdown menu
|
19
19
|
.dropdown-menu {
|
20
20
|
// scss-docs-start dropdown-css-vars
|
21
|
+
--#{$prefix}dropdown-zindex: #{$zindex-dropdown};
|
21
22
|
--#{$prefix}dropdown-min-width: #{$dropdown-min-width};
|
22
23
|
--#{$prefix}dropdown-padding-x: #{$dropdown-padding-x};
|
23
24
|
--#{$prefix}dropdown-padding-y: #{$dropdown-padding-y};
|
@@ -46,7 +47,7 @@
|
|
46
47
|
// scss-docs-end dropdown-css-vars
|
47
48
|
|
48
49
|
position: absolute;
|
49
|
-
z-index: $zindex
|
50
|
+
z-index: var(--#{$prefix}dropdown-zindex);
|
50
51
|
display: none; // none by default, but block on "open" of the menu
|
51
52
|
min-width: var(--#{$prefix}dropdown-min-width);
|
52
53
|
padding: var(--#{$prefix}dropdown-padding-y) var(--#{$prefix}dropdown-padding-x);
|
@@ -183,6 +184,7 @@
|
|
183
184
|
white-space: nowrap; // prevent links from randomly breaking onto new lines
|
184
185
|
background-color: transparent; // For `<button>`s
|
185
186
|
border: 0; // For `<button>`s
|
187
|
+
@include border-radius(var(--#{$prefix}dropdown-item-border-radius, 0));
|
186
188
|
|
187
189
|
&:hover,
|
188
190
|
&:focus {
|
@@ -109,7 +109,7 @@
|
|
109
109
|
// Replace `$search` with `$replace` in `$string`
|
110
110
|
// Used on our SVG icon backgrounds for custom forms.
|
111
111
|
//
|
112
|
-
// @author
|
112
|
+
// @author Kitty Giraudel
|
113
113
|
// @param {String} $string - Initial string
|
114
114
|
// @param {String} $search - Substring to replace
|
115
115
|
// @param {String} $replace ('') - New value
|
@@ -188,7 +188,7 @@ $_luminance-list: .0008 .001 .0011 .0013 .0015 .0017 .002 .0022 .0025 .0027 .003
|
|
188
188
|
);
|
189
189
|
|
190
190
|
@each $name, $value in $rgb {
|
191
|
-
$value: if(divide($value, 255) < .
|
191
|
+
$value: if(divide($value, 255) < .04045, divide(divide($value, 255), 12.92), nth($_luminance-list, $value + 1));
|
192
192
|
$rgb: map-merge($rgb, ($name: $value));
|
193
193
|
}
|
194
194
|
|
@@ -198,7 +198,7 @@ $_luminance-list: .0008 .001 .0011 .0013 .0015 .0017 .002 .0022 .0025 .0027 .003
|
|
198
198
|
// Return opaque color
|
199
199
|
// opaque(#fff, rgba(0, 0, 0, .5)) => #808080
|
200
200
|
@function opaque($background, $foreground) {
|
201
|
-
@return mix(rgba($foreground, 1), $background, opacity($foreground) * 100);
|
201
|
+
@return mix(rgba($foreground, 1), $background, opacity($foreground) * 100%);
|
202
202
|
}
|
203
203
|
|
204
204
|
// scss-docs-start color-functions
|
@@ -104,11 +104,12 @@
|
|
104
104
|
border-color: var(--#{$prefix}list-group-active-border-color);
|
105
105
|
}
|
106
106
|
|
107
|
-
|
107
|
+
// stylelint-disable-next-line scss/selector-no-redundant-nesting-selector
|
108
|
+
& + .list-group-item {
|
108
109
|
border-top-width: 0;
|
109
110
|
|
110
111
|
&.active {
|
111
|
-
margin-top: calc(var(--#{$prefix}list-group-border-width)
|
112
|
+
margin-top: calc(-1 * var(--#{$prefix}list-group-border-width)); // stylelint-disable-line function-disallowed-list
|
112
113
|
border-top-width: var(--#{$prefix}list-group-border-width);
|
113
114
|
}
|
114
115
|
}
|
@@ -126,12 +127,12 @@
|
|
126
127
|
flex-direction: row;
|
127
128
|
|
128
129
|
> .list-group-item {
|
129
|
-
&:first-child {
|
130
|
+
&:first-child:not(:last-child) {
|
130
131
|
@include border-bottom-start-radius(var(--#{$prefix}list-group-border-radius));
|
131
132
|
@include border-top-end-radius(0);
|
132
133
|
}
|
133
134
|
|
134
|
-
&:last-child {
|
135
|
+
&:last-child:not(:first-child) {
|
135
136
|
@include border-top-end-radius(var(--#{$prefix}list-group-border-radius));
|
136
137
|
@include border-bottom-start-radius(0);
|
137
138
|
}
|
@@ -145,7 +146,7 @@
|
|
145
146
|
border-left-width: 0;
|
146
147
|
|
147
148
|
&.active {
|
148
|
-
margin-left: calc(var(--#{$prefix}list-group-border-width)
|
149
|
+
margin-left: calc(-1 * var(--#{$prefix}list-group-border-width)); // stylelint-disable-line function-disallowed-list
|
149
150
|
border-left-width: var(--#{$prefix}list-group-border-width);
|
150
151
|
}
|
151
152
|
}
|
@@ -179,13 +180,18 @@
|
|
179
180
|
// Add modifier classes to change text and background color on individual items.
|
180
181
|
// Organizationally, this must come after the `:hover` states.
|
181
182
|
|
182
|
-
@each $state
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
$list-group-
|
183
|
+
@each $state in map-keys($theme-colors) {
|
184
|
+
.list-group-item-#{$state} {
|
185
|
+
--#{$prefix}list-group-color: var(--#{$prefix}#{$state}-text-emphasis);
|
186
|
+
--#{$prefix}list-group-bg: var(--#{$prefix}#{$state}-bg-subtle);
|
187
|
+
--#{$prefix}list-group-border-color: var(--#{$prefix}#{$state}-border-subtle);
|
188
|
+
--#{$prefix}list-group-action-hover-color: var(--#{$prefix}emphasis-color);
|
189
|
+
--#{$prefix}list-group-action-hover-bg: var(--#{$prefix}#{$state}-border-subtle);
|
190
|
+
--#{$prefix}list-group-action-active-color: var(--#{$prefix}emphasis-color);
|
191
|
+
--#{$prefix}list-group-action-active-bg: var(--#{$prefix}#{$state}-border-subtle);
|
192
|
+
--#{$prefix}list-group-active-color: var(--#{$prefix}#{$state}-bg-subtle);
|
193
|
+
--#{$prefix}list-group-active-bg: var(--#{$prefix}#{$state}-text-emphasis);
|
194
|
+
--#{$prefix}list-group-active-border-color: var(--#{$prefix}#{$state}-text-emphasis);
|
187
195
|
}
|
188
|
-
|
189
|
-
@include list-group-item-variant($state, $list-group-variant-bg, $list-group-variant-color);
|
190
196
|
}
|
191
197
|
// scss-docs-end list-group-modifiers
|
@@ -6,6 +6,90 @@
|
|
6
6
|
$theme-colors-rgb: map-loop($theme-colors, to-rgb, "$value") !default;
|
7
7
|
// scss-docs-end theme-colors-rgb
|
8
8
|
|
9
|
+
// scss-docs-start theme-text-map
|
10
|
+
$theme-colors-text: (
|
11
|
+
"primary": $primary-text-emphasis,
|
12
|
+
"secondary": $secondary-text-emphasis,
|
13
|
+
"success": $success-text-emphasis,
|
14
|
+
"info": $info-text-emphasis,
|
15
|
+
"warning": $warning-text-emphasis,
|
16
|
+
"danger": $danger-text-emphasis,
|
17
|
+
"light": $light-text-emphasis,
|
18
|
+
"dark": $dark-text-emphasis,
|
19
|
+
) !default;
|
20
|
+
// scss-docs-end theme-text-map
|
21
|
+
|
22
|
+
// scss-docs-start theme-bg-subtle-map
|
23
|
+
$theme-colors-bg-subtle: (
|
24
|
+
"primary": $primary-bg-subtle,
|
25
|
+
"secondary": $secondary-bg-subtle,
|
26
|
+
"success": $success-bg-subtle,
|
27
|
+
"info": $info-bg-subtle,
|
28
|
+
"warning": $warning-bg-subtle,
|
29
|
+
"danger": $danger-bg-subtle,
|
30
|
+
"light": $light-bg-subtle,
|
31
|
+
"dark": $dark-bg-subtle,
|
32
|
+
) !default;
|
33
|
+
// scss-docs-end theme-bg-subtle-map
|
34
|
+
|
35
|
+
// scss-docs-start theme-border-subtle-map
|
36
|
+
$theme-colors-border-subtle: (
|
37
|
+
"primary": $primary-border-subtle,
|
38
|
+
"secondary": $secondary-border-subtle,
|
39
|
+
"success": $success-border-subtle,
|
40
|
+
"info": $info-border-subtle,
|
41
|
+
"warning": $warning-border-subtle,
|
42
|
+
"danger": $danger-border-subtle,
|
43
|
+
"light": $light-border-subtle,
|
44
|
+
"dark": $dark-border-subtle,
|
45
|
+
) !default;
|
46
|
+
// scss-docs-end theme-border-subtle-map
|
47
|
+
|
48
|
+
$theme-colors-text-dark: null !default;
|
49
|
+
$theme-colors-bg-subtle-dark: null !default;
|
50
|
+
$theme-colors-border-subtle-dark: null !default;
|
51
|
+
|
52
|
+
@if $enable-dark-mode {
|
53
|
+
// scss-docs-start theme-text-dark-map
|
54
|
+
$theme-colors-text-dark: (
|
55
|
+
"primary": $primary-text-emphasis-dark,
|
56
|
+
"secondary": $secondary-text-emphasis-dark,
|
57
|
+
"success": $success-text-emphasis-dark,
|
58
|
+
"info": $info-text-emphasis-dark,
|
59
|
+
"warning": $warning-text-emphasis-dark,
|
60
|
+
"danger": $danger-text-emphasis-dark,
|
61
|
+
"light": $light-text-emphasis-dark,
|
62
|
+
"dark": $dark-text-emphasis-dark,
|
63
|
+
) !default;
|
64
|
+
// scss-docs-end theme-text-dark-map
|
65
|
+
|
66
|
+
// scss-docs-start theme-bg-subtle-dark-map
|
67
|
+
$theme-colors-bg-subtle-dark: (
|
68
|
+
"primary": $primary-bg-subtle-dark,
|
69
|
+
"secondary": $secondary-bg-subtle-dark,
|
70
|
+
"success": $success-bg-subtle-dark,
|
71
|
+
"info": $info-bg-subtle-dark,
|
72
|
+
"warning": $warning-bg-subtle-dark,
|
73
|
+
"danger": $danger-bg-subtle-dark,
|
74
|
+
"light": $light-bg-subtle-dark,
|
75
|
+
"dark": $dark-bg-subtle-dark,
|
76
|
+
) !default;
|
77
|
+
// scss-docs-end theme-bg-subtle-dark-map
|
78
|
+
|
79
|
+
// scss-docs-start theme-border-subtle-dark-map
|
80
|
+
$theme-colors-border-subtle-dark: (
|
81
|
+
"primary": $primary-border-subtle-dark,
|
82
|
+
"secondary": $secondary-border-subtle-dark,
|
83
|
+
"success": $success-border-subtle-dark,
|
84
|
+
"info": $info-border-subtle-dark,
|
85
|
+
"warning": $warning-border-subtle-dark,
|
86
|
+
"danger": $danger-border-subtle-dark,
|
87
|
+
"light": $light-border-subtle-dark,
|
88
|
+
"dark": $dark-border-subtle-dark,
|
89
|
+
) !default;
|
90
|
+
// scss-docs-end theme-border-subtle-dark-map
|
91
|
+
}
|
92
|
+
|
9
93
|
// Utilities maps
|
10
94
|
//
|
11
95
|
// Extends the default `$theme-colors` maps to help create our utilities.
|
@@ -25,6 +109,17 @@ $utilities-text: map-merge(
|
|
25
109
|
)
|
26
110
|
) !default;
|
27
111
|
$utilities-text-colors: map-loop($utilities-text, rgba-css-var, "$key", "text") !default;
|
112
|
+
|
113
|
+
$utilities-text-emphasis-colors: (
|
114
|
+
"primary-emphasis": var(--#{$prefix}primary-text-emphasis),
|
115
|
+
"secondary-emphasis": var(--#{$prefix}secondary-text-emphasis),
|
116
|
+
"success-emphasis": var(--#{$prefix}success-text-emphasis),
|
117
|
+
"info-emphasis": var(--#{$prefix}info-text-emphasis),
|
118
|
+
"warning-emphasis": var(--#{$prefix}warning-text-emphasis),
|
119
|
+
"danger-emphasis": var(--#{$prefix}danger-text-emphasis),
|
120
|
+
"light-emphasis": var(--#{$prefix}light-text-emphasis),
|
121
|
+
"dark-emphasis": var(--#{$prefix}dark-text-emphasis)
|
122
|
+
) !default;
|
28
123
|
// scss-docs-end utilities-text-colors
|
29
124
|
|
30
125
|
// scss-docs-start utilities-bg-colors
|
@@ -37,18 +132,43 @@ $utilities-bg: map-merge(
|
|
37
132
|
)
|
38
133
|
) !default;
|
39
134
|
$utilities-bg-colors: map-loop($utilities-bg, rgba-css-var, "$key", "bg") !default;
|
135
|
+
|
136
|
+
$utilities-bg-subtle: (
|
137
|
+
"primary-subtle": var(--#{$prefix}primary-bg-subtle),
|
138
|
+
"secondary-subtle": var(--#{$prefix}secondary-bg-subtle),
|
139
|
+
"success-subtle": var(--#{$prefix}success-bg-subtle),
|
140
|
+
"info-subtle": var(--#{$prefix}info-bg-subtle),
|
141
|
+
"warning-subtle": var(--#{$prefix}warning-bg-subtle),
|
142
|
+
"danger-subtle": var(--#{$prefix}danger-bg-subtle),
|
143
|
+
"light-subtle": var(--#{$prefix}light-bg-subtle),
|
144
|
+
"dark-subtle": var(--#{$prefix}dark-bg-subtle)
|
145
|
+
) !default;
|
40
146
|
// scss-docs-end utilities-bg-colors
|
41
147
|
|
42
148
|
// scss-docs-start utilities-border-colors
|
43
149
|
$utilities-border: map-merge(
|
44
150
|
$utilities-colors,
|
45
151
|
(
|
152
|
+
"black": to-rgb($black),
|
46
153
|
"white": to-rgb($white)
|
47
154
|
)
|
48
155
|
) !default;
|
49
156
|
$utilities-border-colors: map-loop($utilities-border, rgba-css-var, "$key", "border") !default;
|
157
|
+
|
158
|
+
$utilities-border-subtle: (
|
159
|
+
"primary-subtle": var(--#{$prefix}primary-border-subtle),
|
160
|
+
"secondary-subtle": var(--#{$prefix}secondary-border-subtle),
|
161
|
+
"success-subtle": var(--#{$prefix}success-border-subtle),
|
162
|
+
"info-subtle": var(--#{$prefix}info-border-subtle),
|
163
|
+
"warning-subtle": var(--#{$prefix}warning-border-subtle),
|
164
|
+
"danger-subtle": var(--#{$prefix}danger-border-subtle),
|
165
|
+
"light-subtle": var(--#{$prefix}light-border-subtle),
|
166
|
+
"dark-subtle": var(--#{$prefix}dark-border-subtle)
|
167
|
+
) !default;
|
50
168
|
// scss-docs-end utilities-border-colors
|
51
169
|
|
170
|
+
$utilities-links-underline: map-loop($utilities-colors, rgba-css-var, "$key", "link-underline") !default;
|
171
|
+
|
52
172
|
$negative-spacers: if($enable-negative-margins, negativify-map($spacers), null) !default;
|
53
173
|
|
54
174
|
$gutters: $spacers !default;
|
@@ -10,6 +10,7 @@
|
|
10
10
|
|
11
11
|
// Helpers
|
12
12
|
@import "mixins/breakpoints";
|
13
|
+
@import "mixins/color-mode";
|
13
14
|
@import "mixins/color-scheme";
|
14
15
|
@import "mixins/image";
|
15
16
|
@import "mixins/resize";
|
@@ -21,13 +22,11 @@
|
|
21
22
|
@import "mixins/utilities";
|
22
23
|
|
23
24
|
// Components
|
24
|
-
@import "mixins/alert";
|
25
25
|
@import "mixins/backdrop";
|
26
26
|
@import "mixins/buttons";
|
27
27
|
@import "mixins/caret";
|
28
28
|
@import "mixins/pagination";
|
29
29
|
@import "mixins/lists";
|
30
|
-
@import "mixins/list-group";
|
31
30
|
@import "mixins/forms";
|
32
31
|
@import "mixins/table-variants";
|
33
32
|
|
@@ -133,7 +133,7 @@
|
|
133
133
|
|
134
134
|
.btn-close {
|
135
135
|
padding: calc(var(--#{$prefix}modal-header-padding-y) * .5) calc(var(--#{$prefix}modal-header-padding-x) * .5);
|
136
|
-
margin: calc(var(--#{$prefix}modal-header-padding-y)
|
136
|
+
margin: calc(-.5 * var(--#{$prefix}modal-header-padding-y)) calc(-.5 * var(--#{$prefix}modal-header-padding-x)) calc(-.5 * var(--#{$prefix}modal-header-padding-y)) auto;
|
137
137
|
}
|
138
138
|
}
|
139
139
|
|
@@ -28,6 +28,8 @@
|
|
28
28
|
font-weight: var(--#{$prefix}nav-link-font-weight);
|
29
29
|
color: var(--#{$prefix}nav-link-color);
|
30
30
|
text-decoration: if($link-decoration == none, null, none);
|
31
|
+
background: none;
|
32
|
+
border: 0;
|
31
33
|
@include transition($nav-link-transition);
|
32
34
|
|
33
35
|
&:hover,
|
@@ -36,6 +38,11 @@
|
|
36
38
|
text-decoration: if($link-hover-decoration == underline, none, null);
|
37
39
|
}
|
38
40
|
|
41
|
+
&:focus-visible {
|
42
|
+
outline: 0;
|
43
|
+
box-shadow: $nav-link-focus-box-shadow;
|
44
|
+
}
|
45
|
+
|
39
46
|
// Disabled state lightens text
|
40
47
|
&.disabled {
|
41
48
|
color: var(--#{$prefix}nav-link-disabled-color);
|
@@ -62,8 +69,7 @@
|
|
62
69
|
border-bottom: var(--#{$prefix}nav-tabs-border-width) solid var(--#{$prefix}nav-tabs-border-color);
|
63
70
|
|
64
71
|
.nav-link {
|
65
|
-
margin-bottom: calc(var(--#{$prefix}nav-tabs-border-width)
|
66
|
-
background: none;
|
72
|
+
margin-bottom: calc(-1 * var(--#{$prefix}nav-tabs-border-width)); // stylelint-disable-line function-disallowed-list
|
67
73
|
border: var(--#{$prefix}nav-tabs-border-width) solid transparent;
|
68
74
|
@include border-top-radius(var(--#{$prefix}nav-tabs-border-radius));
|
69
75
|
|
@@ -91,7 +97,7 @@
|
|
91
97
|
|
92
98
|
.dropdown-menu {
|
93
99
|
// Make dropdown border overlap tab border
|
94
|
-
margin-top: calc(var(--#{$prefix}nav-tabs-border-width)
|
100
|
+
margin-top: calc(-1 * var(--#{$prefix}nav-tabs-border-width)); // stylelint-disable-line function-disallowed-list
|
95
101
|
// Remove the top rounded corners here since there is a hard edge above the menu
|
96
102
|
@include border-top-radius(0);
|
97
103
|
}
|
@@ -110,8 +116,6 @@
|
|
110
116
|
// scss-docs-end nav-pills-css-vars
|
111
117
|
|
112
118
|
.nav-link {
|
113
|
-
background: none;
|
114
|
-
border: 0;
|
115
119
|
@include border-radius(var(--#{$prefix}nav-pills-border-radius));
|
116
120
|
|
117
121
|
&:disabled {
|
@@ -129,6 +133,39 @@
|
|
129
133
|
}
|
130
134
|
|
131
135
|
|
136
|
+
//
|
137
|
+
// Underline
|
138
|
+
//
|
139
|
+
|
140
|
+
.nav-underline {
|
141
|
+
// scss-docs-start nav-underline-css-vars
|
142
|
+
--#{$prefix}nav-underline-gap: #{$nav-underline-gap};
|
143
|
+
--#{$prefix}nav-underline-border-width: #{$nav-underline-border-width};
|
144
|
+
--#{$prefix}nav-underline-link-active-color: #{$nav-underline-link-active-color};
|
145
|
+
// scss-docs-end nav-underline-css-vars
|
146
|
+
|
147
|
+
gap: var(--#{$prefix}nav-underline-gap);
|
148
|
+
|
149
|
+
.nav-link {
|
150
|
+
padding-right: 0;
|
151
|
+
padding-left: 0;
|
152
|
+
border-bottom: var(--#{$prefix}nav-underline-border-width) solid transparent;
|
153
|
+
|
154
|
+
&:hover,
|
155
|
+
&:focus {
|
156
|
+
border-bottom-color: currentcolor;
|
157
|
+
}
|
158
|
+
}
|
159
|
+
|
160
|
+
.nav-link.active,
|
161
|
+
.show > .nav-link {
|
162
|
+
font-weight: $font-weight-bold;
|
163
|
+
color: var(--#{$prefix}nav-underline-link-active-color);
|
164
|
+
border-bottom-color: currentcolor;
|
165
|
+
}
|
166
|
+
}
|
167
|
+
|
168
|
+
|
132
169
|
//
|
133
170
|
// Justified variants
|
134
171
|
//
|
@@ -100,9 +100,11 @@
|
|
100
100
|
margin-bottom: 0;
|
101
101
|
list-style: none;
|
102
102
|
|
103
|
-
.
|
104
|
-
|
105
|
-
|
103
|
+
.nav-link {
|
104
|
+
&.active,
|
105
|
+
&.show {
|
106
|
+
color: var(--#{$prefix}navbar-active-color);
|
107
|
+
}
|
106
108
|
}
|
107
109
|
|
108
110
|
.dropdown-menu {
|
@@ -264,7 +266,9 @@
|
|
264
266
|
@include deprecate("`.navbar-light`", "v5.2.0", "v6.0.0", true);
|
265
267
|
}
|
266
268
|
|
267
|
-
.navbar-dark
|
269
|
+
.navbar-dark,
|
270
|
+
.navbar[data-bs-theme="dark"] {
|
271
|
+
// scss-docs-start navbar-dark-css-vars
|
268
272
|
--#{$prefix}navbar-color: #{$navbar-dark-color};
|
269
273
|
--#{$prefix}navbar-hover-color: #{$navbar-dark-hover-color};
|
270
274
|
--#{$prefix}navbar-disabled-color: #{$navbar-dark-disabled-color};
|
@@ -273,4 +277,13 @@
|
|
273
277
|
--#{$prefix}navbar-brand-hover-color: #{$navbar-dark-brand-hover-color};
|
274
278
|
--#{$prefix}navbar-toggler-border-color: #{$navbar-dark-toggler-border-color};
|
275
279
|
--#{$prefix}navbar-toggler-icon-bg: #{escape-svg($navbar-dark-toggler-icon-bg)};
|
280
|
+
// scss-docs-end navbar-dark-css-vars
|
281
|
+
}
|
282
|
+
|
283
|
+
@if $enable-dark-mode {
|
284
|
+
@include color-mode(dark) {
|
285
|
+
.navbar-toggler-icon {
|
286
|
+
--#{$prefix}navbar-toggler-icon-bg: #{escape-svg($navbar-dark-toggler-icon-bg)};
|
287
|
+
}
|
288
|
+
}
|
276
289
|
}
|
@@ -2,6 +2,7 @@
|
|
2
2
|
|
3
3
|
%offcanvas-css-vars {
|
4
4
|
// scss-docs-start offcanvas-css-vars
|
5
|
+
--#{$prefix}offcanvas-zindex: #{$zindex-offcanvas};
|
5
6
|
--#{$prefix}offcanvas-width: #{$offcanvas-horizontal-width};
|
6
7
|
--#{$prefix}offcanvas-height: #{$offcanvas-vertical-height};
|
7
8
|
--#{$prefix}offcanvas-padding-x: #{$offcanvas-padding-x};
|
@@ -11,6 +12,8 @@
|
|
11
12
|
--#{$prefix}offcanvas-border-width: #{$offcanvas-border-width};
|
12
13
|
--#{$prefix}offcanvas-border-color: #{$offcanvas-border-color};
|
13
14
|
--#{$prefix}offcanvas-box-shadow: #{$offcanvas-box-shadow};
|
15
|
+
--#{$prefix}offcanvas-transition: #{transform $offcanvas-transition-duration ease-in-out};
|
16
|
+
--#{$prefix}offcanvas-title-line-height: #{$offcanvas-title-line-height};
|
14
17
|
// scss-docs-end offcanvas-css-vars
|
15
18
|
}
|
16
19
|
|
@@ -31,7 +34,7 @@
|
|
31
34
|
@include media-breakpoint-down($next) {
|
32
35
|
position: fixed;
|
33
36
|
bottom: 0;
|
34
|
-
z-index: $zindex
|
37
|
+
z-index: var(--#{$prefix}offcanvas-zindex);
|
35
38
|
display: flex;
|
36
39
|
flex-direction: column;
|
37
40
|
max-width: 100%;
|
@@ -41,7 +44,7 @@
|
|
41
44
|
background-clip: padding-box;
|
42
45
|
outline: 0;
|
43
46
|
@include box-shadow(var(--#{$prefix}offcanvas-box-shadow));
|
44
|
-
@include transition(
|
47
|
+
@include transition(var(--#{$prefix}offcanvas-transition));
|
45
48
|
|
46
49
|
&.offcanvas-start {
|
47
50
|
top: 0;
|
@@ -125,15 +128,15 @@
|
|
125
128
|
|
126
129
|
.btn-close {
|
127
130
|
padding: calc(var(--#{$prefix}offcanvas-padding-y) * .5) calc(var(--#{$prefix}offcanvas-padding-x) * .5);
|
128
|
-
margin-top: calc(var(--#{$prefix}offcanvas-padding-y)
|
129
|
-
margin-right: calc(var(--#{$prefix}offcanvas-padding-x)
|
130
|
-
margin-bottom: calc(var(--#{$prefix}offcanvas-padding-y)
|
131
|
+
margin-top: calc(-.5 * var(--#{$prefix}offcanvas-padding-y));
|
132
|
+
margin-right: calc(-.5 * var(--#{$prefix}offcanvas-padding-x));
|
133
|
+
margin-bottom: calc(-.5 * var(--#{$prefix}offcanvas-padding-y));
|
131
134
|
}
|
132
135
|
}
|
133
136
|
|
134
137
|
.offcanvas-title {
|
135
138
|
margin-bottom: 0;
|
136
|
-
line-height: $offcanvas-title-line-height;
|
139
|
+
line-height: var(--#{$prefix}offcanvas-title-line-height);
|
137
140
|
}
|
138
141
|
|
139
142
|
.offcanvas-body {
|
@@ -75,7 +75,7 @@
|
|
75
75
|
margin-left: $pagination-margin-start;
|
76
76
|
}
|
77
77
|
|
78
|
-
@if $pagination-margin-start ==
|
78
|
+
@if $pagination-margin-start == calc(#{$pagination-border-width} * -1) {
|
79
79
|
&:first-child {
|
80
80
|
.page-link {
|
81
81
|
@include border-start-radius(var(--#{$prefix}pagination-border-radius));
|