bootstrap 5.1.1 → 5.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/assets/javascripts/bootstrap/alert.js +18 -153
- data/assets/javascripts/bootstrap/base-component.js +44 -127
- data/assets/javascripts/bootstrap/button.js +16 -80
- data/assets/javascripts/bootstrap/carousel.js +225 -497
- data/assets/javascripts/bootstrap/collapse.js +79 -262
- data/assets/javascripts/bootstrap/dom/data.js +6 -8
- data/assets/javascripts/bootstrap/dom/event-handler.js +95 -133
- data/assets/javascripts/bootstrap/dom/manipulator.js +25 -29
- data/assets/javascripts/bootstrap/dom/selector-engine.js +17 -59
- data/assets/javascripts/bootstrap/dropdown.js +124 -342
- data/assets/javascripts/bootstrap/modal.js +122 -767
- data/assets/javascripts/bootstrap/offcanvas.js +102 -671
- data/assets/javascripts/bootstrap/popover.js +42 -124
- data/assets/javascripts/bootstrap/scrollspy.js +186 -269
- data/assets/javascripts/bootstrap/tab.js +222 -221
- data/assets/javascripts/bootstrap/toast.js +41 -227
- data/assets/javascripts/bootstrap/tooltip.js +283 -629
- data/assets/javascripts/bootstrap/util/backdrop.js +165 -0
- data/assets/javascripts/bootstrap/util/component-functions.js +46 -0
- data/assets/javascripts/bootstrap/util/config.js +79 -0
- data/assets/javascripts/bootstrap/util/focustrap.js +129 -0
- data/assets/javascripts/bootstrap/util/index.js +350 -0
- data/assets/javascripts/bootstrap/util/sanitizer.js +122 -0
- data/assets/javascripts/bootstrap/util/scrollbar.js +138 -0
- data/assets/javascripts/bootstrap/util/swipe.js +155 -0
- data/assets/javascripts/bootstrap/util/template-factory.js +177 -0
- data/assets/javascripts/bootstrap-global-this-define.js +1 -1
- data/assets/javascripts/bootstrap-sprockets.js +16 -7
- data/assets/javascripts/bootstrap.js +2094 -1891
- data/assets/javascripts/bootstrap.min.js +3 -3
- data/assets/stylesheets/_bootstrap-grid.scss +3 -6
- data/assets/stylesheets/_bootstrap-reboot.scss +3 -7
- data/assets/stylesheets/_bootstrap.scss +4 -6
- data/assets/stylesheets/bootstrap/_accordion.scss +52 -24
- data/assets/stylesheets/bootstrap/_alert.scss +18 -4
- data/assets/stylesheets/bootstrap/_badge.scss +14 -5
- data/assets/stylesheets/bootstrap/_breadcrumb.scss +22 -10
- data/assets/stylesheets/bootstrap/_button-group.scss +3 -0
- data/assets/stylesheets/bootstrap/_buttons.scss +97 -22
- data/assets/stylesheets/bootstrap/_card.scss +55 -37
- data/assets/stylesheets/bootstrap/_close.scss +1 -1
- data/assets/stylesheets/bootstrap/_containers.scss +1 -1
- data/assets/stylesheets/bootstrap/_dropdown.scss +83 -75
- data/assets/stylesheets/bootstrap/_functions.scss +7 -7
- data/assets/stylesheets/bootstrap/_grid.scss +3 -3
- data/assets/stylesheets/bootstrap/_helpers.scss +1 -0
- data/assets/stylesheets/bootstrap/_list-group.scss +44 -27
- data/assets/stylesheets/bootstrap/_maps.scss +54 -0
- data/assets/stylesheets/bootstrap/_modal.scss +71 -43
- data/assets/stylesheets/bootstrap/_nav.scss +53 -20
- data/assets/stylesheets/bootstrap/_navbar.scss +91 -150
- data/assets/stylesheets/bootstrap/_offcanvas.scss +119 -59
- data/assets/stylesheets/bootstrap/_pagination.scss +66 -21
- data/assets/stylesheets/bootstrap/_placeholders.scss +1 -1
- data/assets/stylesheets/bootstrap/_popover.scss +90 -52
- data/assets/stylesheets/bootstrap/_progress.scss +20 -9
- data/assets/stylesheets/bootstrap/_reboot.scss +25 -40
- data/assets/stylesheets/bootstrap/_root.scss +40 -21
- data/assets/stylesheets/bootstrap/_spinners.scss +38 -22
- data/assets/stylesheets/bootstrap/_tables.scss +38 -25
- data/assets/stylesheets/bootstrap/_toasts.scss +35 -16
- data/assets/stylesheets/bootstrap/_tooltip.scss +61 -56
- data/assets/stylesheets/bootstrap/_type.scss +2 -0
- data/assets/stylesheets/bootstrap/_utilities.scss +43 -26
- data/assets/stylesheets/bootstrap/_variables.scss +118 -124
- data/assets/stylesheets/bootstrap/bootstrap-utilities.scss +3 -6
- data/assets/stylesheets/bootstrap/forms/_floating-labels.scss +14 -3
- data/assets/stylesheets/bootstrap/forms/_form-check.scss +28 -5
- data/assets/stylesheets/bootstrap/forms/_form-control.scss +12 -37
- data/assets/stylesheets/bootstrap/forms/_form-select.scss +2 -1
- data/assets/stylesheets/bootstrap/forms/_input-group.scss +15 -7
- data/assets/stylesheets/bootstrap/helpers/_color-bg.scss +10 -0
- data/assets/stylesheets/bootstrap/helpers/_colored-links.scss +2 -2
- data/assets/stylesheets/bootstrap/helpers/_position.scss +7 -1
- data/assets/stylesheets/bootstrap/helpers/_ratio.scss +2 -2
- data/assets/stylesheets/bootstrap/helpers/_vr.scss +1 -1
- data/assets/stylesheets/bootstrap/mixins/_alert.scss +7 -3
- data/assets/stylesheets/bootstrap/mixins/_banner.scss +9 -0
- data/assets/stylesheets/bootstrap/mixins/_breakpoints.scss +8 -8
- data/assets/stylesheets/bootstrap/mixins/_buttons.scss +32 -95
- data/assets/stylesheets/bootstrap/mixins/_container.scss +4 -2
- data/assets/stylesheets/bootstrap/mixins/_forms.scss +8 -0
- data/assets/stylesheets/bootstrap/mixins/_gradients.scss +1 -1
- data/assets/stylesheets/bootstrap/mixins/_grid.scss +13 -12
- data/assets/stylesheets/bootstrap/mixins/_pagination.scss +4 -25
- data/assets/stylesheets/bootstrap/mixins/_reset-text.scss +1 -1
- data/assets/stylesheets/bootstrap/mixins/_table-variants.scss +12 -9
- data/assets/stylesheets/bootstrap/mixins/_utilities.scss +12 -4
- data/assets/stylesheets/bootstrap/mixins/_visually-hidden.scss +1 -1
- data/bootstrap.gemspec +1 -1
- data/lib/bootstrap/version.rb +2 -2
- data/tasks/updater/js.rb +9 -4
- metadata +16 -4
@@ -14,6 +14,18 @@
|
|
14
14
|
}
|
15
15
|
}
|
16
16
|
|
17
|
+
.form-check-reverse {
|
18
|
+
padding-right: $form-check-padding-start;
|
19
|
+
padding-left: 0;
|
20
|
+
text-align: right;
|
21
|
+
|
22
|
+
.form-check-input {
|
23
|
+
float: right;
|
24
|
+
margin-right: $form-check-padding-start * -1;
|
25
|
+
margin-left: 0;
|
26
|
+
}
|
27
|
+
}
|
28
|
+
|
17
29
|
.form-check-input {
|
18
30
|
width: $form-check-input-width;
|
19
31
|
height: $form-check-input-width;
|
@@ -25,7 +37,7 @@
|
|
25
37
|
background-size: contain;
|
26
38
|
border: $form-check-input-border;
|
27
39
|
appearance: none;
|
28
|
-
color-adjust: exact; // Keep themed appearance for print
|
40
|
+
print-color-adjust: exact; // Keep themed appearance for print
|
29
41
|
@include transition($form-check-transition);
|
30
42
|
|
31
43
|
&[type="checkbox"] {
|
@@ -53,7 +65,7 @@
|
|
53
65
|
|
54
66
|
&[type="checkbox"] {
|
55
67
|
@if $enable-gradients {
|
56
|
-
background-image: escape-svg($form-check-input-checked-bg-image), var(--#{$
|
68
|
+
background-image: escape-svg($form-check-input-checked-bg-image), var(--#{$prefix}gradient);
|
57
69
|
} @else {
|
58
70
|
background-image: escape-svg($form-check-input-checked-bg-image);
|
59
71
|
}
|
@@ -61,7 +73,7 @@
|
|
61
73
|
|
62
74
|
&[type="radio"] {
|
63
75
|
@if $enable-gradients {
|
64
|
-
background-image: escape-svg($form-check-radio-checked-bg-image), var(--#{$
|
76
|
+
background-image: escape-svg($form-check-radio-checked-bg-image), var(--#{$prefix}gradient);
|
65
77
|
} @else {
|
66
78
|
background-image: escape-svg($form-check-radio-checked-bg-image);
|
67
79
|
}
|
@@ -73,7 +85,7 @@
|
|
73
85
|
border-color: $form-check-input-indeterminate-border-color;
|
74
86
|
|
75
87
|
@if $enable-gradients {
|
76
|
-
background-image: escape-svg($form-check-input-indeterminate-bg-image), var(--#{$
|
88
|
+
background-image: escape-svg($form-check-input-indeterminate-bg-image), var(--#{$prefix}gradient);
|
77
89
|
} @else {
|
78
90
|
background-image: escape-svg($form-check-input-indeterminate-bg-image);
|
79
91
|
}
|
@@ -90,6 +102,7 @@
|
|
90
102
|
&[disabled],
|
91
103
|
&:disabled {
|
92
104
|
~ .form-check-label {
|
105
|
+
cursor: default;
|
93
106
|
opacity: $form-check-label-disabled-opacity;
|
94
107
|
}
|
95
108
|
}
|
@@ -123,12 +136,22 @@
|
|
123
136
|
background-position: $form-switch-checked-bg-position;
|
124
137
|
|
125
138
|
@if $enable-gradients {
|
126
|
-
background-image: escape-svg($form-switch-checked-bg-image), var(--#{$
|
139
|
+
background-image: escape-svg($form-switch-checked-bg-image), var(--#{$prefix}gradient);
|
127
140
|
} @else {
|
128
141
|
background-image: escape-svg($form-switch-checked-bg-image);
|
129
142
|
}
|
130
143
|
}
|
131
144
|
}
|
145
|
+
|
146
|
+
&.form-check-reverse {
|
147
|
+
padding-right: $form-switch-padding-start;
|
148
|
+
padding-left: 0;
|
149
|
+
|
150
|
+
.form-check-input {
|
151
|
+
margin-right: $form-switch-padding-start * -1;
|
152
|
+
margin-left: 0;
|
153
|
+
}
|
154
|
+
}
|
132
155
|
}
|
133
156
|
|
134
157
|
.form-check-inline {
|
@@ -59,13 +59,13 @@
|
|
59
59
|
opacity: 1;
|
60
60
|
}
|
61
61
|
|
62
|
-
// Disabled
|
62
|
+
// Disabled inputs
|
63
63
|
//
|
64
64
|
// HTML5 says that controls under a fieldset > legend:first-child won't be
|
65
65
|
// disabled if the fieldset is disabled. Due to implementation difficulty, we
|
66
66
|
// don't honor that edge case; we style them as disabled anyway.
|
67
|
-
&:disabled
|
68
|
-
|
67
|
+
&:disabled {
|
68
|
+
color: $input-disabled-color;
|
69
69
|
background-color: $input-disabled-bg;
|
70
70
|
border-color: $input-disabled-border-color;
|
71
71
|
// iOS fix for unreadable disabled content; see https://github.com/twbs/bootstrap/issues/11655.
|
@@ -91,25 +91,6 @@
|
|
91
91
|
&:hover:not(:disabled):not([readonly])::file-selector-button {
|
92
92
|
background-color: $form-file-button-hover-bg;
|
93
93
|
}
|
94
|
-
|
95
|
-
&::-webkit-file-upload-button {
|
96
|
-
padding: $input-padding-y $input-padding-x;
|
97
|
-
margin: (-$input-padding-y) (-$input-padding-x);
|
98
|
-
margin-inline-end: $input-padding-x;
|
99
|
-
color: $form-file-button-color;
|
100
|
-
@include gradient-bg($form-file-button-bg);
|
101
|
-
pointer-events: none;
|
102
|
-
border-color: inherit;
|
103
|
-
border-style: solid;
|
104
|
-
border-width: 0;
|
105
|
-
border-inline-end-width: $input-border-width;
|
106
|
-
border-radius: 0; // stylelint-disable-line property-disallowed-list
|
107
|
-
@include transition($btn-transition);
|
108
|
-
}
|
109
|
-
|
110
|
-
&:hover:not(:disabled):not([readonly])::-webkit-file-upload-button {
|
111
|
-
background-color: $form-file-button-hover-bg;
|
112
|
-
}
|
113
94
|
}
|
114
95
|
|
115
96
|
// Readonly controls as plain text
|
@@ -128,6 +109,10 @@
|
|
128
109
|
border: solid transparent;
|
129
110
|
border-width: $input-border-width 0;
|
130
111
|
|
112
|
+
&:focus {
|
113
|
+
outline: 0;
|
114
|
+
}
|
115
|
+
|
131
116
|
&.form-control-sm,
|
132
117
|
&.form-control-lg {
|
133
118
|
padding-right: 0;
|
@@ -153,12 +138,6 @@
|
|
153
138
|
margin: (-$input-padding-y-sm) (-$input-padding-x-sm);
|
154
139
|
margin-inline-end: $input-padding-x-sm;
|
155
140
|
}
|
156
|
-
|
157
|
-
&::-webkit-file-upload-button {
|
158
|
-
padding: $input-padding-y-sm $input-padding-x-sm;
|
159
|
-
margin: (-$input-padding-y-sm) (-$input-padding-x-sm);
|
160
|
-
margin-inline-end: $input-padding-x-sm;
|
161
|
-
}
|
162
141
|
}
|
163
142
|
|
164
143
|
.form-control-lg {
|
@@ -172,12 +151,6 @@
|
|
172
151
|
margin: (-$input-padding-y-lg) (-$input-padding-x-lg);
|
173
152
|
margin-inline-end: $input-padding-x-lg;
|
174
153
|
}
|
175
|
-
|
176
|
-
&::-webkit-file-upload-button {
|
177
|
-
padding: $input-padding-y-lg $input-padding-x-lg;
|
178
|
-
margin: (-$input-padding-y-lg) (-$input-padding-x-lg);
|
179
|
-
margin-inline-end: $input-padding-x-lg;
|
180
|
-
}
|
181
154
|
}
|
182
155
|
|
183
156
|
// Make sure textareas don't shrink too much when resized
|
@@ -200,7 +173,7 @@ textarea {
|
|
200
173
|
|
201
174
|
.form-control-color {
|
202
175
|
width: $form-color-width;
|
203
|
-
height:
|
176
|
+
height: $input-height;
|
204
177
|
padding: $input-padding-y;
|
205
178
|
|
206
179
|
&:not(:disabled):not([readonly]) {
|
@@ -208,12 +181,14 @@ textarea {
|
|
208
181
|
}
|
209
182
|
|
210
183
|
&::-moz-color-swatch {
|
211
|
-
|
184
|
+
border: 0 !important; // stylelint-disable-line declaration-no-important
|
212
185
|
@include border-radius($input-border-radius);
|
213
186
|
}
|
214
187
|
|
215
188
|
&::-webkit-color-swatch {
|
216
|
-
height: if(unit($input-line-height) == "", $input-line-height * 1em, $input-line-height);
|
217
189
|
@include border-radius($input-border-radius);
|
218
190
|
}
|
191
|
+
|
192
|
+
&.form-control-sm { height: $input-height-sm; }
|
193
|
+
&.form-control-lg { height: $input-height-lg; }
|
219
194
|
}
|
@@ -7,7 +7,6 @@
|
|
7
7
|
display: block;
|
8
8
|
width: 100%;
|
9
9
|
padding: $form-select-padding-y $form-select-indicator-padding $form-select-padding-y $form-select-padding-x;
|
10
|
-
// stylelint-disable-next-line property-no-vendor-prefix
|
11
10
|
-moz-padding-start: subtract($form-select-padding-x, 3px); // See https://github.com/twbs/bootstrap/issues/32636
|
12
11
|
font-family: $form-select-font-family;
|
13
12
|
@include font-size($form-select-font-size);
|
@@ -60,6 +59,7 @@
|
|
60
59
|
padding-bottom: $form-select-padding-y-sm;
|
61
60
|
padding-left: $form-select-padding-x-sm;
|
62
61
|
@include font-size($form-select-font-size-sm);
|
62
|
+
@include border-radius($form-select-border-radius-sm);
|
63
63
|
}
|
64
64
|
|
65
65
|
.form-select-lg {
|
@@ -67,4 +67,5 @@
|
|
67
67
|
padding-bottom: $form-select-padding-y-lg;
|
68
68
|
padding-left: $form-select-padding-x-lg;
|
69
69
|
@include font-size($form-select-font-size-lg);
|
70
|
+
@include border-radius($form-select-border-radius-lg);
|
70
71
|
}
|
@@ -10,7 +10,8 @@
|
|
10
10
|
width: 100%;
|
11
11
|
|
12
12
|
> .form-control,
|
13
|
-
> .form-select
|
13
|
+
> .form-select,
|
14
|
+
> .form-floating {
|
14
15
|
position: relative; // For focus state's z-index
|
15
16
|
flex: 1 1 auto;
|
16
17
|
width: 1%;
|
@@ -19,7 +20,8 @@
|
|
19
20
|
|
20
21
|
// Bring the "active" form control to the top of surrounding elements
|
21
22
|
> .form-control:focus,
|
22
|
-
> .form-select:focus
|
23
|
+
> .form-select:focus,
|
24
|
+
> .form-floating:focus-within {
|
23
25
|
z-index: 3;
|
24
26
|
}
|
25
27
|
|
@@ -96,15 +98,19 @@
|
|
96
98
|
// stylelint-disable-next-line no-duplicate-selectors
|
97
99
|
.input-group {
|
98
100
|
&:not(.has-validation) {
|
99
|
-
> :not(:last-child):not(.dropdown-toggle):not(.dropdown-menu),
|
100
|
-
> .dropdown-toggle:nth-last-child(n + 3)
|
101
|
+
> :not(:last-child):not(.dropdown-toggle):not(.dropdown-menu):not(.form-floating),
|
102
|
+
> .dropdown-toggle:nth-last-child(n + 3),
|
103
|
+
> .form-floating:not(:last-child) > .form-control,
|
104
|
+
> .form-floating:not(:last-child) > .form-select {
|
101
105
|
@include border-end-radius(0);
|
102
106
|
}
|
103
107
|
}
|
104
108
|
|
105
109
|
&.has-validation {
|
106
|
-
> :nth-last-child(n + 3):not(.dropdown-toggle):not(.dropdown-menu),
|
107
|
-
> .dropdown-toggle:nth-last-child(n + 4)
|
110
|
+
> :nth-last-child(n + 3):not(.dropdown-toggle):not(.dropdown-menu):not(.form-floating),
|
111
|
+
> .dropdown-toggle:nth-last-child(n + 4),
|
112
|
+
> .form-floating:nth-last-child(n + 3) > .form-control,
|
113
|
+
> .form-floating:nth-last-child(n + 3) > .form-select {
|
108
114
|
@include border-end-radius(0);
|
109
115
|
}
|
110
116
|
}
|
@@ -114,7 +120,9 @@
|
|
114
120
|
$validation-messages: $validation-messages + ":not(." + unquote($state) + "-tooltip)" + ":not(." + unquote($state) + "-feedback)";
|
115
121
|
}
|
116
122
|
|
117
|
-
> :not(:first-child):not(.dropdown-menu)#{$validation-messages}
|
123
|
+
> :not(:first-child):not(.dropdown-menu):not(.form-floating)#{$validation-messages},
|
124
|
+
> .form-floating:not(:first-child) > .form-control,
|
125
|
+
> .form-floating:not(:first-child) > .form-select {
|
118
126
|
margin-left: -$input-border-width;
|
119
127
|
@include border-start-radius(0);
|
120
128
|
}
|
@@ -0,0 +1,10 @@
|
|
1
|
+
// stylelint-disable function-name-case
|
2
|
+
|
3
|
+
// All-caps `RGBA()` function used because of this Sass bug: https://github.com/sass/node-sass/issues/2251
|
4
|
+
@each $color, $value in $theme-colors {
|
5
|
+
$color-rgb: to-rgb($value);
|
6
|
+
.text-bg-#{$color} {
|
7
|
+
color: color-contrast($value) if($enable-important-utilities, !important, null);
|
8
|
+
background-color: RGBA($color-rgb, var(--#{$prefix}bg-opacity, 1)) if($enable-important-utilities, !important, null);
|
9
|
+
}
|
10
|
+
}
|
@@ -1,11 +1,11 @@
|
|
1
1
|
@each $color, $value in $theme-colors {
|
2
2
|
.link-#{$color} {
|
3
|
-
color: $value;
|
3
|
+
color: $value !important; // stylelint-disable-line declaration-no-important
|
4
4
|
|
5
5
|
@if $link-shade-percentage != 0 {
|
6
6
|
&:hover,
|
7
7
|
&:focus {
|
8
|
-
color: if(color-contrast($value) == $color-contrast-light, shade-color($value, $link-shade-percentage), tint-color($value, $link-shade-percentage));
|
8
|
+
color: if(color-contrast($value) == $color-contrast-light, shade-color($value, $link-shade-percentage), tint-color($value, $link-shade-percentage)) !important; // stylelint-disable-line declaration-no-important
|
9
9
|
}
|
10
10
|
}
|
11
11
|
}
|
@@ -16,7 +16,7 @@
|
|
16
16
|
z-index: $zindex-fixed;
|
17
17
|
}
|
18
18
|
|
19
|
-
// Responsive sticky top
|
19
|
+
// Responsive sticky top and bottom
|
20
20
|
@each $breakpoint in map-keys($grid-breakpoints) {
|
21
21
|
@include media-breakpoint-up($breakpoint) {
|
22
22
|
$infix: breakpoint-infix($breakpoint, $grid-breakpoints);
|
@@ -26,5 +26,11 @@
|
|
26
26
|
top: 0;
|
27
27
|
z-index: $zindex-sticky;
|
28
28
|
}
|
29
|
+
|
30
|
+
.sticky#{$infix}-bottom {
|
31
|
+
position: sticky;
|
32
|
+
bottom: 0;
|
33
|
+
z-index: $zindex-sticky;
|
34
|
+
}
|
29
35
|
}
|
30
36
|
}
|
@@ -6,7 +6,7 @@
|
|
6
6
|
|
7
7
|
&::before {
|
8
8
|
display: block;
|
9
|
-
padding-top: var(--#{$
|
9
|
+
padding-top: var(--#{$prefix}aspect-ratio);
|
10
10
|
content: "";
|
11
11
|
}
|
12
12
|
|
@@ -21,6 +21,6 @@
|
|
21
21
|
|
22
22
|
@each $key, $ratio in $aspect-ratios {
|
23
23
|
.ratio-#{$key} {
|
24
|
-
--#{$
|
24
|
+
--#{$prefix}aspect-ratio: #{$ratio};
|
25
25
|
}
|
26
26
|
}
|
@@ -1,8 +1,12 @@
|
|
1
1
|
// scss-docs-start alert-variant-mixin
|
2
2
|
@mixin alert-variant($background, $border, $color) {
|
3
|
-
color: $color;
|
4
|
-
|
5
|
-
border-color: $border;
|
3
|
+
--#{$prefix}alert-color: #{$color};
|
4
|
+
--#{$prefix}alert-bg: #{$background};
|
5
|
+
--#{$prefix}alert-border-color: #{$border};
|
6
|
+
|
7
|
+
@if $enable-gradients {
|
8
|
+
background-image: var(--#{$prefix}gradient);
|
9
|
+
}
|
6
10
|
|
7
11
|
.alert-link {
|
8
12
|
color: shade-color($color, 20%);
|
@@ -0,0 +1,9 @@
|
|
1
|
+
@mixin bsBanner($file, $suffix:"") {
|
2
|
+
/*!
|
3
|
+
* Bootstrap #{$file} v5.2.0 (https://getbootstrap.com/)
|
4
|
+
* Copyright 2011-2022 The Bootstrap Authors
|
5
|
+
* Copyright 2011-2022 Twitter, Inc.
|
6
|
+
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
7
|
+
*/
|
8
|
+
}
|
9
|
+
|
@@ -2,7 +2,7 @@
|
|
2
2
|
//
|
3
3
|
// Breakpoints are defined as a map of (name: minimum width), order from small to large:
|
4
4
|
//
|
5
|
-
// (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px)
|
5
|
+
// (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px, xxl: 1400px)
|
6
6
|
//
|
7
7
|
// The map defined in the `$grid-breakpoints` global variable is used as the `$breakpoints` argument by default.
|
8
8
|
|
@@ -10,9 +10,9 @@
|
|
10
10
|
//
|
11
11
|
// >> breakpoint-next(sm)
|
12
12
|
// md
|
13
|
-
// >> breakpoint-next(sm, (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px))
|
13
|
+
// >> breakpoint-next(sm, (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px, xxl: 1400px))
|
14
14
|
// md
|
15
|
-
// >> breakpoint-next(sm, $breakpoint-names: (xs sm md lg xl))
|
15
|
+
// >> breakpoint-next(sm, $breakpoint-names: (xs sm md lg xl xxl))
|
16
16
|
// md
|
17
17
|
@function breakpoint-next($name, $breakpoints: $grid-breakpoints, $breakpoint-names: map-keys($breakpoints)) {
|
18
18
|
$n: index($breakpoint-names, $name);
|
@@ -24,7 +24,7 @@
|
|
24
24
|
|
25
25
|
// Minimum breakpoint width. Null for the smallest (first) breakpoint.
|
26
26
|
//
|
27
|
-
// >> breakpoint-min(sm, (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px))
|
27
|
+
// >> breakpoint-min(sm, (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px, xxl: 1400px))
|
28
28
|
// 576px
|
29
29
|
@function breakpoint-min($name, $breakpoints: $grid-breakpoints) {
|
30
30
|
$min: map-get($breakpoints, $name);
|
@@ -38,7 +38,7 @@
|
|
38
38
|
// Uses 0.02px rather than 0.01px to work around a current rounding bug in Safari.
|
39
39
|
// See https://bugs.webkit.org/show_bug.cgi?id=178261
|
40
40
|
//
|
41
|
-
// >> breakpoint-max(md, (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px))
|
41
|
+
// >> breakpoint-max(md, (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px, xxl: 1400px))
|
42
42
|
// 767.98px
|
43
43
|
@function breakpoint-max($name, $breakpoints: $grid-breakpoints) {
|
44
44
|
$max: map-get($breakpoints, $name);
|
@@ -48,9 +48,9 @@
|
|
48
48
|
// Returns a blank string if smallest breakpoint, otherwise returns the name with a dash in front.
|
49
49
|
// Useful for making responsive utilities.
|
50
50
|
//
|
51
|
-
// >> breakpoint-infix(xs, (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px))
|
51
|
+
// >> breakpoint-infix(xs, (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px, xxl: 1400px))
|
52
52
|
// "" (Returns a blank string)
|
53
|
-
// >> breakpoint-infix(sm, (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px))
|
53
|
+
// >> breakpoint-infix(sm, (xs: 0, sm: 576px, md: 768px, lg: 992px, xl: 1200px, xxl: 1400px))
|
54
54
|
// "-sm"
|
55
55
|
@function breakpoint-infix($name, $breakpoints: $grid-breakpoints) {
|
56
56
|
@return if(breakpoint-min($name, $breakpoints) == null, "", "-#{$name}");
|
@@ -109,7 +109,7 @@
|
|
109
109
|
@mixin media-breakpoint-only($name, $breakpoints: $grid-breakpoints) {
|
110
110
|
$min: breakpoint-min($name, $breakpoints);
|
111
111
|
$next: breakpoint-next($name, $breakpoints);
|
112
|
-
$max: breakpoint-max($next);
|
112
|
+
$max: breakpoint-max($next, $breakpoints);
|
113
113
|
|
114
114
|
@if $min != null and $max != null {
|
115
115
|
@media (min-width: $min) and (max-width: $max) {
|
@@ -18,59 +18,20 @@
|
|
18
18
|
$disabled-border: $border,
|
19
19
|
$disabled-color: color-contrast($disabled-background)
|
20
20
|
) {
|
21
|
-
color: $color;
|
22
|
-
|
23
|
-
border-color: $border;
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
}
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
@include gradient-bg($hover-background);
|
36
|
-
border-color: $hover-border;
|
37
|
-
@if $enable-shadows {
|
38
|
-
@include box-shadow($btn-box-shadow, 0 0 0 $btn-focus-width rgba(mix($color, $border, 15%), .5));
|
39
|
-
} @else {
|
40
|
-
// Avoid using mixin so we can pass custom focus shadow properly
|
41
|
-
box-shadow: 0 0 0 $btn-focus-width rgba(mix($color, $border, 15%), .5);
|
42
|
-
}
|
43
|
-
}
|
44
|
-
|
45
|
-
.btn-check:checked + &,
|
46
|
-
.btn-check:active + &,
|
47
|
-
&:active,
|
48
|
-
&.active,
|
49
|
-
.show > &.dropdown-toggle {
|
50
|
-
color: $active-color;
|
51
|
-
background-color: $active-background;
|
52
|
-
// Remove CSS gradients if they're enabled
|
53
|
-
background-image: if($enable-gradients, none, null);
|
54
|
-
border-color: $active-border;
|
55
|
-
|
56
|
-
&:focus {
|
57
|
-
@if $enable-shadows {
|
58
|
-
@include box-shadow($btn-active-box-shadow, 0 0 0 $btn-focus-width rgba(mix($color, $border, 15%), .5));
|
59
|
-
} @else {
|
60
|
-
// Avoid using mixin so we can pass custom focus shadow properly
|
61
|
-
box-shadow: 0 0 0 $btn-focus-width rgba(mix($color, $border, 15%), .5);
|
62
|
-
}
|
63
|
-
}
|
64
|
-
}
|
65
|
-
|
66
|
-
&:disabled,
|
67
|
-
&.disabled {
|
68
|
-
color: $disabled-color;
|
69
|
-
background-color: $disabled-background;
|
70
|
-
// Remove CSS gradients if they're enabled
|
71
|
-
background-image: if($enable-gradients, none, null);
|
72
|
-
border-color: $disabled-border;
|
73
|
-
}
|
21
|
+
--#{$prefix}btn-color: #{$color};
|
22
|
+
--#{$prefix}btn-bg: #{$background};
|
23
|
+
--#{$prefix}btn-border-color: #{$border};
|
24
|
+
--#{$prefix}btn-hover-color: #{$hover-color};
|
25
|
+
--#{$prefix}btn-hover-bg: #{$hover-background};
|
26
|
+
--#{$prefix}btn-hover-border-color: #{$hover-border};
|
27
|
+
--#{$prefix}btn-focus-shadow-rgb: #{to-rgb(mix($color, $border, 15%))};
|
28
|
+
--#{$prefix}btn-active-color: #{$active-color};
|
29
|
+
--#{$prefix}btn-active-bg: #{$active-background};
|
30
|
+
--#{$prefix}btn-active-border-color: #{$active-border};
|
31
|
+
--#{$prefix}btn-active-shadow: #{$btn-active-box-shadow};
|
32
|
+
--#{$prefix}btn-disabled-color: #{$disabled-color};
|
33
|
+
--#{$prefix}btn-disabled-bg: #{$disabled-background};
|
34
|
+
--#{$prefix}btn-disabled-border-color: #{$disabled-border};
|
74
35
|
}
|
75
36
|
// scss-docs-end btn-variant-mixin
|
76
37
|
|
@@ -82,52 +43,28 @@
|
|
82
43
|
$active-border: $color,
|
83
44
|
$active-color: color-contrast($active-background)
|
84
45
|
) {
|
85
|
-
color: $color;
|
86
|
-
border-color: $color;
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
}
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
}
|
98
|
-
|
99
|
-
.btn-check:checked + &,
|
100
|
-
.btn-check:active + &,
|
101
|
-
&:active,
|
102
|
-
&.active,
|
103
|
-
&.dropdown-toggle.show {
|
104
|
-
color: $active-color;
|
105
|
-
background-color: $active-background;
|
106
|
-
border-color: $active-border;
|
107
|
-
|
108
|
-
&:focus {
|
109
|
-
@if $enable-shadows {
|
110
|
-
@include box-shadow($btn-active-box-shadow, 0 0 0 $btn-focus-width rgba($color, .5));
|
111
|
-
} @else {
|
112
|
-
// Avoid using mixin so we can pass custom focus shadow properly
|
113
|
-
box-shadow: 0 0 0 $btn-focus-width rgba($color, .5);
|
114
|
-
}
|
115
|
-
}
|
116
|
-
}
|
117
|
-
|
118
|
-
&:disabled,
|
119
|
-
&.disabled {
|
120
|
-
color: $color;
|
121
|
-
background-color: transparent;
|
122
|
-
}
|
46
|
+
--#{$prefix}btn-color: #{$color};
|
47
|
+
--#{$prefix}btn-border-color: #{$color};
|
48
|
+
--#{$prefix}btn-hover-color: #{$color-hover};
|
49
|
+
--#{$prefix}btn-hover-bg: #{$active-background};
|
50
|
+
--#{$prefix}btn-hover-border-color: #{$active-border};
|
51
|
+
--#{$prefix}btn-focus-shadow-rgb: #{to-rgb($color)};
|
52
|
+
--#{$prefix}btn-active-color: #{$active-color};
|
53
|
+
--#{$prefix}btn-active-bg: #{$active-background};
|
54
|
+
--#{$prefix}btn-active-border-color: #{$active-border};
|
55
|
+
--#{$prefix}btn-active-shadow: #{$btn-active-box-shadow};
|
56
|
+
--#{$prefix}btn-disabled-color: #{$color};
|
57
|
+
--#{$prefix}btn-disabled-bg: transparent;
|
58
|
+
--#{$prefix}btn-disabled-border-color: #{$color};
|
59
|
+
--#{$prefix}gradient: none;
|
123
60
|
}
|
124
61
|
// scss-docs-end btn-outline-variant-mixin
|
125
62
|
|
126
63
|
// scss-docs-start btn-size-mixin
|
127
64
|
@mixin button-size($padding-y, $padding-x, $font-size, $border-radius) {
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
65
|
+
--#{$prefix}btn-padding-y: #{$padding-y};
|
66
|
+
--#{$prefix}btn-padding-x: #{$padding-x};
|
67
|
+
@include rfs($font-size, --#{$prefix}btn-font-size);
|
68
|
+
--#{$prefix}btn-border-radius: #{$border-radius};
|
132
69
|
}
|
133
70
|
// scss-docs-end btn-size-mixin
|
@@ -1,9 +1,11 @@
|
|
1
1
|
// Container mixins
|
2
2
|
|
3
3
|
@mixin make-container($gutter: $container-padding-x) {
|
4
|
+
--#{$prefix}gutter-x: #{$gutter};
|
5
|
+
--#{$prefix}gutter-y: 0;
|
4
6
|
width: 100%;
|
5
|
-
padding-right: var(--#{$
|
6
|
-
padding-left: var(--#{$
|
7
|
+
padding-right: calc(var(--#{$prefix}gutter-x) * .5); // stylelint-disable-line function-disallowed-list
|
8
|
+
padding-left: calc(var(--#{$prefix}gutter-x) * .5); // stylelint-disable-line function-disallowed-list
|
7
9
|
margin-right: auto;
|
8
10
|
margin-left: auto;
|
9
11
|
}
|
@@ -104,6 +104,14 @@
|
|
104
104
|
}
|
105
105
|
}
|
106
106
|
|
107
|
+
.form-control-color {
|
108
|
+
@include form-validation-state-selector($state) {
|
109
|
+
@if $enable-validation-icons {
|
110
|
+
width: add($form-color-width, $input-height-inner);
|
111
|
+
}
|
112
|
+
}
|
113
|
+
}
|
114
|
+
|
107
115
|
.form-check-input {
|
108
116
|
@include form-validation-state-selector($state) {
|
109
117
|
border-color: $color;
|
@@ -3,16 +3,17 @@
|
|
3
3
|
// Generate semantic grid columns with these mixins.
|
4
4
|
|
5
5
|
@mixin make-row($gutter: $grid-gutter-width) {
|
6
|
-
--#{$
|
7
|
-
--#{$
|
6
|
+
--#{$prefix}gutter-x: #{$gutter};
|
7
|
+
--#{$prefix}gutter-y: 0;
|
8
8
|
display: flex;
|
9
9
|
flex-wrap: wrap;
|
10
|
-
|
11
|
-
margin-
|
12
|
-
margin-
|
10
|
+
// TODO: Revisit calc order after https://github.com/react-bootstrap/react-bootstrap/issues/6039 is fixed
|
11
|
+
margin-top: calc(-1 * var(--#{$prefix}gutter-y)); // stylelint-disable-line function-disallowed-list
|
12
|
+
margin-right: calc(-.5 * var(--#{$prefix}gutter-x)); // stylelint-disable-line function-disallowed-list
|
13
|
+
margin-left: calc(-.5 * var(--#{$prefix}gutter-x)); // stylelint-disable-line function-disallowed-list
|
13
14
|
}
|
14
15
|
|
15
|
-
@mixin make-col-ready(
|
16
|
+
@mixin make-col-ready() {
|
16
17
|
// Add box sizing if only the grid is loaded
|
17
18
|
box-sizing: if(variable-exists(include-column-box-sizing) and $include-column-box-sizing, border-box, null);
|
18
19
|
// Prevent columns from becoming too narrow when at smaller grid tiers by
|
@@ -21,9 +22,9 @@
|
|
21
22
|
flex-shrink: 0;
|
22
23
|
width: 100%;
|
23
24
|
max-width: 100%; // Prevent `.col-auto`, `.col` (& responsive variants) from breaking out the grid
|
24
|
-
padding-right: calc(var(--#{$
|
25
|
-
padding-left: calc(var(--#{$
|
26
|
-
margin-top: var(--#{$
|
25
|
+
padding-right: calc(var(--#{$prefix}gutter-x) * .5); // stylelint-disable-line function-disallowed-list
|
26
|
+
padding-left: calc(var(--#{$prefix}gutter-x) * .5); // stylelint-disable-line function-disallowed-list
|
27
|
+
margin-top: var(--#{$prefix}gutter-y);
|
27
28
|
}
|
28
29
|
|
29
30
|
@mixin make-col($size: false, $columns: $grid-columns) {
|
@@ -50,7 +51,7 @@
|
|
50
51
|
// Row columns
|
51
52
|
//
|
52
53
|
// Specify on a parent element(e.g., .row) to force immediate children into NN
|
53
|
-
//
|
54
|
+
// number of columns. Supports wrapping to new lines, but does not do a Masonry
|
54
55
|
// style grid.
|
55
56
|
@mixin row-cols($count) {
|
56
57
|
> * {
|
@@ -113,12 +114,12 @@
|
|
113
114
|
@each $key, $value in $gutters {
|
114
115
|
.g#{$infix}-#{$key},
|
115
116
|
.gx#{$infix}-#{$key} {
|
116
|
-
--#{$
|
117
|
+
--#{$prefix}gutter-x: #{$value};
|
117
118
|
}
|
118
119
|
|
119
120
|
.g#{$infix}-#{$key},
|
120
121
|
.gy#{$infix}-#{$key} {
|
121
|
-
--#{$
|
122
|
+
--#{$prefix}gutter-y: #{$value};
|
122
123
|
}
|
123
124
|
}
|
124
125
|
}
|