bootstrap 4.6.0 → 5.0.0.alpha1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/assets/javascripts/bootstrap-sprockets.js +12 -8
- data/assets/javascripts/bootstrap.js +1889 -1255
- data/assets/javascripts/bootstrap.min.js +3 -3
- data/assets/javascripts/bootstrap/alert.js +136 -66
- data/assets/javascripts/bootstrap/button.js +59 -147
- data/assets/javascripts/bootstrap/carousel.js +276 -180
- data/assets/javascripts/bootstrap/collapse.js +284 -136
- data/assets/javascripts/bootstrap/dom/data.js +81 -0
- data/assets/javascripts/bootstrap/dom/event-handler.js +311 -0
- data/assets/javascripts/bootstrap/dom/manipulator.js +100 -0
- data/assets/javascripts/bootstrap/dom/polyfill.js +110 -0
- data/assets/javascripts/bootstrap/dom/selector-engine.js +98 -0
- data/assets/javascripts/bootstrap/dropdown.js +238 -195
- data/assets/javascripts/bootstrap/modal.js +321 -223
- data/assets/javascripts/bootstrap/popover.js +75 -79
- data/assets/javascripts/bootstrap/scrollspy.js +150 -86
- data/assets/javascripts/bootstrap/tab.js +154 -82
- data/assets/javascripts/bootstrap/toast.js +162 -95
- data/assets/javascripts/bootstrap/tooltip.js +337 -191
- data/assets/stylesheets/_bootstrap-grid.scss +53 -18
- data/assets/stylesheets/_bootstrap-reboot.scss +6 -3
- data/assets/stylesheets/_bootstrap.scss +16 -10
- data/assets/stylesheets/bootstrap/_alert.scss +3 -4
- data/assets/stylesheets/bootstrap/_badge.scss +2 -27
- data/assets/stylesheets/bootstrap/_breadcrumb.scss +5 -17
- data/assets/stylesheets/bootstrap/_button-group.scss +16 -38
- data/assets/stylesheets/bootstrap/_buttons.scss +27 -45
- data/assets/stylesheets/bootstrap/_card.scss +22 -68
- data/assets/stylesheets/bootstrap/_carousel.scss +13 -15
- data/assets/stylesheets/bootstrap/_close.scss +9 -13
- data/assets/stylesheets/bootstrap/_containers.scss +41 -0
- data/assets/stylesheets/bootstrap/_dropdown.scss +12 -9
- data/assets/stylesheets/bootstrap/_forms.scss +9 -347
- data/assets/stylesheets/bootstrap/_functions.scss +82 -23
- data/assets/stylesheets/bootstrap/_grid.scss +3 -54
- data/assets/stylesheets/bootstrap/_helpers.scss +7 -0
- data/assets/stylesheets/bootstrap/_list-group.scss +7 -4
- data/assets/stylesheets/bootstrap/_mixins.scss +6 -12
- data/assets/stylesheets/bootstrap/_modal.scss +34 -39
- data/assets/stylesheets/bootstrap/_nav.scss +7 -4
- data/assets/stylesheets/bootstrap/_navbar.scss +42 -82
- data/assets/stylesheets/bootstrap/_pagination.scss +7 -20
- data/assets/stylesheets/bootstrap/_popover.scss +5 -5
- data/assets/stylesheets/bootstrap/_progress.scss +3 -5
- data/assets/stylesheets/bootstrap/_reboot.scss +304 -172
- data/assets/stylesheets/bootstrap/_root.scss +5 -8
- data/assets/stylesheets/bootstrap/_spinners.scss +4 -13
- data/assets/stylesheets/bootstrap/_tables.scss +80 -114
- data/assets/stylesheets/bootstrap/_toasts.scss +2 -4
- data/assets/stylesheets/bootstrap/_tooltip.scss +5 -5
- data/assets/stylesheets/bootstrap/_transitions.scss +0 -1
- data/assets/stylesheets/bootstrap/_type.scss +38 -59
- data/assets/stylesheets/bootstrap/_utilities.scss +503 -18
- data/assets/stylesheets/bootstrap/_variables.scss +546 -432
- data/assets/stylesheets/bootstrap/bootstrap-utilities.scss +18 -0
- data/assets/stylesheets/bootstrap/forms/_form-check.scss +142 -0
- data/assets/stylesheets/bootstrap/forms/_form-control.scss +116 -0
- data/assets/stylesheets/bootstrap/forms/_form-file.scss +91 -0
- data/assets/stylesheets/bootstrap/forms/_form-range.scss +136 -0
- data/assets/stylesheets/bootstrap/forms/_form-select.scss +82 -0
- data/assets/stylesheets/bootstrap/forms/_form-text.scss +11 -0
- data/assets/stylesheets/bootstrap/forms/_input-group.scss +140 -0
- data/assets/stylesheets/bootstrap/forms/_labels.scss +36 -0
- data/assets/stylesheets/bootstrap/forms/_validation.scss +12 -0
- data/assets/stylesheets/bootstrap/{utilities → helpers}/_clearfix.scss +0 -0
- data/assets/stylesheets/bootstrap/helpers/_colored-links.scss +12 -0
- data/assets/stylesheets/bootstrap/helpers/_embed.scss +31 -0
- data/assets/stylesheets/bootstrap/helpers/_position.scss +30 -0
- data/assets/stylesheets/bootstrap/helpers/_screenreaders.scss +8 -0
- data/assets/stylesheets/bootstrap/helpers/_stretched-link.scss +15 -0
- data/assets/stylesheets/bootstrap/helpers/_text-truncation.scss +7 -0
- data/assets/stylesheets/bootstrap/mixins/_alert.scss +0 -4
- data/assets/stylesheets/bootstrap/mixins/_border-radius.scss +1 -1
- data/assets/stylesheets/bootstrap/mixins/_breakpoints.scss +11 -8
- data/assets/stylesheets/bootstrap/mixins/_buttons.scss +62 -47
- data/assets/stylesheets/bootstrap/mixins/_caret.scss +4 -4
- data/assets/stylesheets/bootstrap/mixins/_clearfix.scss +2 -0
- data/assets/stylesheets/bootstrap/mixins/_container.scss +9 -0
- data/assets/stylesheets/bootstrap/mixins/_forms.scss +22 -74
- data/assets/stylesheets/bootstrap/mixins/_gradients.scss +9 -11
- data/assets/stylesheets/bootstrap/mixins/_grid.scss +85 -33
- data/assets/stylesheets/bootstrap/mixins/_image.scss +1 -21
- data/assets/stylesheets/bootstrap/mixins/_list-group.scss +2 -1
- data/assets/stylesheets/bootstrap/mixins/_lists.scss +1 -1
- data/assets/stylesheets/bootstrap/mixins/_pagination.scss +15 -8
- data/assets/stylesheets/bootstrap/mixins/_reset-text.scss +2 -2
- data/assets/stylesheets/bootstrap/mixins/_screen-reader.scss +17 -23
- data/assets/stylesheets/bootstrap/mixins/_table-variants.scss +21 -0
- data/assets/stylesheets/bootstrap/mixins/_transition.scss +2 -2
- data/assets/stylesheets/bootstrap/mixins/_utilities.scss +49 -0
- data/assets/stylesheets/bootstrap/utilities/_api.scss +47 -0
- data/assets/stylesheets/bootstrap/vendor/_rfs.scss +234 -126
- data/lib/bootstrap/version.rb +2 -2
- data/tasks/updater/js.rb +3 -3
- metadata +32 -40
- data/assets/javascripts/bootstrap/util.js +0 -192
- data/assets/stylesheets/bootstrap/_code.scss +0 -48
- data/assets/stylesheets/bootstrap/_custom-forms.scss +0 -526
- data/assets/stylesheets/bootstrap/_input-group.scss +0 -208
- data/assets/stylesheets/bootstrap/_jumbotron.scss +0 -17
- data/assets/stylesheets/bootstrap/_media.scss +0 -8
- data/assets/stylesheets/bootstrap/_print.scss +0 -141
- data/assets/stylesheets/bootstrap/mixins/_background-variant.scss +0 -23
- data/assets/stylesheets/bootstrap/mixins/_badge.scss +0 -17
- data/assets/stylesheets/bootstrap/mixins/_float.scss +0 -14
- data/assets/stylesheets/bootstrap/mixins/_grid-framework.scss +0 -80
- data/assets/stylesheets/bootstrap/mixins/_hover.scss +0 -37
- data/assets/stylesheets/bootstrap/mixins/_nav-divider.scss +0 -11
- data/assets/stylesheets/bootstrap/mixins/_size.scss +0 -7
- data/assets/stylesheets/bootstrap/mixins/_table-row.scss +0 -39
- data/assets/stylesheets/bootstrap/mixins/_text-emphasis.scss +0 -17
- data/assets/stylesheets/bootstrap/mixins/_text-hide.scss +0 -11
- data/assets/stylesheets/bootstrap/mixins/_visibility.scss +0 -8
- data/assets/stylesheets/bootstrap/utilities/_align.scss +0 -8
- data/assets/stylesheets/bootstrap/utilities/_background.scss +0 -19
- data/assets/stylesheets/bootstrap/utilities/_borders.scss +0 -75
- data/assets/stylesheets/bootstrap/utilities/_display.scss +0 -26
- data/assets/stylesheets/bootstrap/utilities/_embed.scss +0 -39
- data/assets/stylesheets/bootstrap/utilities/_flex.scss +0 -51
- data/assets/stylesheets/bootstrap/utilities/_float.scss +0 -11
- data/assets/stylesheets/bootstrap/utilities/_interactions.scss +0 -5
- data/assets/stylesheets/bootstrap/utilities/_overflow.scss +0 -5
- data/assets/stylesheets/bootstrap/utilities/_position.scss +0 -32
- data/assets/stylesheets/bootstrap/utilities/_screenreaders.scss +0 -11
- data/assets/stylesheets/bootstrap/utilities/_shadows.scss +0 -6
- data/assets/stylesheets/bootstrap/utilities/_sizing.scss +0 -20
- data/assets/stylesheets/bootstrap/utilities/_spacing.scss +0 -73
- data/assets/stylesheets/bootstrap/utilities/_stretched-link.scss +0 -19
- data/assets/stylesheets/bootstrap/utilities/_text.scss +0 -72
- data/assets/stylesheets/bootstrap/utilities/_visibility.scss +0 -13
|
@@ -3,94 +3,104 @@
|
|
|
3
3
|
// Easily pump out default styles, as well as :hover, :focus, :active,
|
|
4
4
|
// and disabled options for all buttons
|
|
5
5
|
|
|
6
|
-
@mixin button-variant(
|
|
7
|
-
|
|
6
|
+
@mixin button-variant(
|
|
7
|
+
$background,
|
|
8
|
+
$border,
|
|
9
|
+
$color: color-contrast($background),
|
|
10
|
+
$hover-background: darken($background, 7.5%),
|
|
11
|
+
$hover-border: darken($border, 10%),
|
|
12
|
+
$hover-color: color-contrast($hover-background),
|
|
13
|
+
$active-background: darken($background, 10%),
|
|
14
|
+
$active-border: darken($border, 12.5%),
|
|
15
|
+
$active-color: color-contrast($active-background)
|
|
16
|
+
) {
|
|
17
|
+
color: $color;
|
|
8
18
|
@include gradient-bg($background);
|
|
9
19
|
border-color: $border;
|
|
10
20
|
@include box-shadow($btn-box-shadow);
|
|
11
21
|
|
|
12
|
-
|
|
13
|
-
color:
|
|
22
|
+
&:hover {
|
|
23
|
+
color: $hover-color;
|
|
14
24
|
@include gradient-bg($hover-background);
|
|
15
25
|
border-color: $hover-border;
|
|
16
26
|
}
|
|
17
27
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
color:
|
|
28
|
+
.btn-check:focus + &,
|
|
29
|
+
&:focus {
|
|
30
|
+
color: $hover-color;
|
|
21
31
|
@include gradient-bg($hover-background);
|
|
22
32
|
border-color: $hover-border;
|
|
23
33
|
@if $enable-shadows {
|
|
24
|
-
@include box-shadow($btn-box-shadow, 0 0 0 $btn-focus-width rgba(mix(color
|
|
34
|
+
@include box-shadow($btn-box-shadow, 0 0 0 $btn-focus-width rgba(mix($color, $border, 15%), .5));
|
|
25
35
|
} @else {
|
|
26
36
|
// Avoid using mixin so we can pass custom focus shadow properly
|
|
27
|
-
box-shadow: 0 0 0 $btn-focus-width rgba(mix(color
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
// Disabled comes first so active can properly restyle
|
|
32
|
-
&.disabled,
|
|
33
|
-
&:disabled {
|
|
34
|
-
color: color-yiq($background);
|
|
35
|
-
background-color: $background;
|
|
36
|
-
border-color: $border;
|
|
37
|
-
// Remove CSS gradients if they're enabled
|
|
38
|
-
@if $enable-gradients {
|
|
39
|
-
background-image: none;
|
|
37
|
+
box-shadow: 0 0 0 $btn-focus-width rgba(mix($color, $border, 15%), .5);
|
|
40
38
|
}
|
|
41
39
|
}
|
|
42
40
|
|
|
43
|
-
|
|
44
|
-
|
|
41
|
+
.btn-check:checked + &,
|
|
42
|
+
.btn-check:active + &,
|
|
43
|
+
&:active,
|
|
44
|
+
&.active,
|
|
45
45
|
.show > &.dropdown-toggle {
|
|
46
|
-
color:
|
|
46
|
+
color: $active-color;
|
|
47
47
|
background-color: $active-background;
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
}
|
|
48
|
+
// Remove CSS gradients if they're enabled
|
|
49
|
+
background-image: if($enable-gradients, none, null);
|
|
51
50
|
border-color: $active-border;
|
|
52
51
|
|
|
53
52
|
&:focus {
|
|
54
|
-
@if $enable-shadows
|
|
55
|
-
@include box-shadow($btn-active-box-shadow, 0 0 0 $btn-focus-width rgba(mix(color
|
|
53
|
+
@if $enable-shadows {
|
|
54
|
+
@include box-shadow($btn-active-box-shadow, 0 0 0 $btn-focus-width rgba(mix($color, $border, 15%), .5));
|
|
56
55
|
} @else {
|
|
57
56
|
// Avoid using mixin so we can pass custom focus shadow properly
|
|
58
|
-
box-shadow: 0 0 0 $btn-focus-width rgba(mix(color
|
|
57
|
+
box-shadow: 0 0 0 $btn-focus-width rgba(mix($color, $border, 15%), .5);
|
|
59
58
|
}
|
|
60
59
|
}
|
|
61
60
|
}
|
|
61
|
+
|
|
62
|
+
&:disabled,
|
|
63
|
+
&.disabled {
|
|
64
|
+
color: $color;
|
|
65
|
+
background-color: $background;
|
|
66
|
+
// Remove CSS gradients if they're enabled
|
|
67
|
+
background-image: if($enable-gradients, none, null);
|
|
68
|
+
border-color: $border;
|
|
69
|
+
}
|
|
62
70
|
}
|
|
63
71
|
|
|
64
|
-
@mixin button-outline-variant(
|
|
72
|
+
@mixin button-outline-variant(
|
|
73
|
+
$color,
|
|
74
|
+
$color-hover: color-contrast($color),
|
|
75
|
+
$active-background: $color,
|
|
76
|
+
$active-border: $color,
|
|
77
|
+
$active-color: color-contrast($active-background)
|
|
78
|
+
) {
|
|
65
79
|
color: $color;
|
|
66
80
|
border-color: $color;
|
|
67
81
|
|
|
68
|
-
|
|
82
|
+
&:hover {
|
|
69
83
|
color: $color-hover;
|
|
70
84
|
background-color: $active-background;
|
|
71
85
|
border-color: $active-border;
|
|
72
86
|
}
|
|
73
87
|
|
|
74
|
-
|
|
75
|
-
|
|
88
|
+
.btn-check:focus + &,
|
|
89
|
+
&:focus {
|
|
76
90
|
box-shadow: 0 0 0 $btn-focus-width rgba($color, .5);
|
|
77
91
|
}
|
|
78
92
|
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
&:not(:disabled):not(.disabled):active,
|
|
86
|
-
&:not(:disabled):not(.disabled).active,
|
|
87
|
-
.show > &.dropdown-toggle {
|
|
88
|
-
color: color-yiq($active-background);
|
|
93
|
+
.btn-check:checked + &,
|
|
94
|
+
.btn-check:active + &,
|
|
95
|
+
&:active,
|
|
96
|
+
&.active,
|
|
97
|
+
&.dropdown-toggle.show {
|
|
98
|
+
color: $active-color;
|
|
89
99
|
background-color: $active-background;
|
|
90
100
|
border-color: $active-border;
|
|
91
101
|
|
|
92
102
|
&:focus {
|
|
93
|
-
@if $enable-shadows
|
|
103
|
+
@if $enable-shadows {
|
|
94
104
|
@include box-shadow($btn-active-box-shadow, 0 0 0 $btn-focus-width rgba($color, .5));
|
|
95
105
|
} @else {
|
|
96
106
|
// Avoid using mixin so we can pass custom focus shadow properly
|
|
@@ -98,13 +108,18 @@
|
|
|
98
108
|
}
|
|
99
109
|
}
|
|
100
110
|
}
|
|
111
|
+
|
|
112
|
+
&:disabled,
|
|
113
|
+
&.disabled {
|
|
114
|
+
color: $color;
|
|
115
|
+
background-color: transparent;
|
|
116
|
+
}
|
|
101
117
|
}
|
|
102
118
|
|
|
103
119
|
// Button sizes
|
|
104
|
-
@mixin button-size($padding-y, $padding-x, $font-size, $
|
|
120
|
+
@mixin button-size($padding-y, $padding-x, $font-size, $border-radius) {
|
|
105
121
|
padding: $padding-y $padding-x;
|
|
106
122
|
@include font-size($font-size);
|
|
107
|
-
line-height: $line-height;
|
|
108
123
|
// Manually declare to provide an override to the browser default
|
|
109
124
|
@include border-radius($border-radius, 0);
|
|
110
125
|
}
|
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
@mixin caret-down
|
|
1
|
+
@mixin caret-down {
|
|
2
2
|
border-top: $caret-width solid;
|
|
3
3
|
border-right: $caret-width solid transparent;
|
|
4
4
|
border-bottom: 0;
|
|
5
5
|
border-left: $caret-width solid transparent;
|
|
6
6
|
}
|
|
7
7
|
|
|
8
|
-
@mixin caret-up
|
|
8
|
+
@mixin caret-up {
|
|
9
9
|
border-top: 0;
|
|
10
10
|
border-right: $caret-width solid transparent;
|
|
11
11
|
border-bottom: $caret-width solid;
|
|
12
12
|
border-left: $caret-width solid transparent;
|
|
13
13
|
}
|
|
14
14
|
|
|
15
|
-
@mixin caret-right
|
|
15
|
+
@mixin caret-right {
|
|
16
16
|
border-top: $caret-width solid transparent;
|
|
17
17
|
border-right: 0;
|
|
18
18
|
border-bottom: $caret-width solid transparent;
|
|
19
19
|
border-left: $caret-width solid;
|
|
20
20
|
}
|
|
21
21
|
|
|
22
|
-
@mixin caret-left
|
|
22
|
+
@mixin caret-left {
|
|
23
23
|
border-top: $caret-width solid transparent;
|
|
24
24
|
border-right: $caret-width solid;
|
|
25
25
|
border-bottom: $caret-width solid transparent;
|
|
@@ -1,31 +1,3 @@
|
|
|
1
|
-
// Form control focus state
|
|
2
|
-
//
|
|
3
|
-
// Generate a customized focus state and for any input with the specified color,
|
|
4
|
-
// which defaults to the `$input-focus-border-color` variable.
|
|
5
|
-
//
|
|
6
|
-
// We highly encourage you to not customize the default value, but instead use
|
|
7
|
-
// this to tweak colors on an as-needed basis. This aesthetic change is based on
|
|
8
|
-
// WebKit's default styles, but applicable to a wider range of browsers. Its
|
|
9
|
-
// usability and accessibility should be taken into account with any change.
|
|
10
|
-
//
|
|
11
|
-
// Example usage: change the default blue border and shadow to white for better
|
|
12
|
-
// contrast against a dark gray background.
|
|
13
|
-
@mixin form-control-focus($ignore-warning: false) {
|
|
14
|
-
&:focus {
|
|
15
|
-
color: $input-focus-color;
|
|
16
|
-
background-color: $input-focus-bg;
|
|
17
|
-
border-color: $input-focus-border-color;
|
|
18
|
-
outline: 0;
|
|
19
|
-
@if $enable-shadows {
|
|
20
|
-
@include box-shadow($input-box-shadow, $input-focus-box-shadow);
|
|
21
|
-
} @else {
|
|
22
|
-
// Avoid using mixin so we can pass custom focus shadow properly
|
|
23
|
-
box-shadow: $input-focus-box-shadow;
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
@include deprecate("The `form-control-focus()` mixin", "v4.4.0", "v5", $ignore-warning);
|
|
27
|
-
}
|
|
28
|
-
|
|
29
1
|
// This mixin uses an `if()` technique to be compatible with Dart Sass
|
|
30
2
|
// See https://github.com/sass/sass/issues/1873#issuecomment-152293725 for more details
|
|
31
3
|
@mixin form-validation-state-selector($state) {
|
|
@@ -47,13 +19,13 @@
|
|
|
47
19
|
width: 100%;
|
|
48
20
|
margin-top: $form-feedback-margin-top;
|
|
49
21
|
@include font-size($form-feedback-font-size);
|
|
22
|
+
font-style: $form-feedback-font-style;
|
|
50
23
|
color: $color;
|
|
51
24
|
}
|
|
52
25
|
|
|
53
26
|
.#{$state}-tooltip {
|
|
54
27
|
position: absolute;
|
|
55
28
|
top: 100%;
|
|
56
|
-
left: 0;
|
|
57
29
|
z-index: 5;
|
|
58
30
|
display: none;
|
|
59
31
|
max-width: 100%; // Contain to parent when possible
|
|
@@ -61,16 +33,9 @@
|
|
|
61
33
|
margin-top: .1rem;
|
|
62
34
|
@include font-size($form-feedback-tooltip-font-size);
|
|
63
35
|
line-height: $form-feedback-tooltip-line-height;
|
|
64
|
-
color: color-
|
|
36
|
+
color: color-contrast($color);
|
|
65
37
|
background-color: rgba($color, $form-feedback-tooltip-opacity);
|
|
66
38
|
@include border-radius($form-feedback-tooltip-border-radius);
|
|
67
|
-
|
|
68
|
-
// See https://github.com/twbs/bootstrap/pull/31557
|
|
69
|
-
// Align tooltip to form elements
|
|
70
|
-
.form-row > .col > &,
|
|
71
|
-
.form-row > [class*="col-"] > & {
|
|
72
|
-
left: $form-grid-gutter-width / 2;
|
|
73
|
-
}
|
|
74
39
|
}
|
|
75
40
|
|
|
76
41
|
@include form-validation-state-selector($state) {
|
|
@@ -94,7 +59,7 @@
|
|
|
94
59
|
|
|
95
60
|
&:focus {
|
|
96
61
|
border-color: $color;
|
|
97
|
-
box-shadow: 0 0 0 $input-focus-width rgba($color,
|
|
62
|
+
box-shadow: 0 0 0 $input-focus-width rgba($color, $input-btn-focus-color-opacity);
|
|
98
63
|
}
|
|
99
64
|
}
|
|
100
65
|
}
|
|
@@ -109,13 +74,15 @@
|
|
|
109
74
|
}
|
|
110
75
|
}
|
|
111
76
|
|
|
112
|
-
.
|
|
77
|
+
.form-select {
|
|
113
78
|
@include form-validation-state-selector($state) {
|
|
114
79
|
border-color: $color;
|
|
115
80
|
|
|
116
81
|
@if $enable-validation-icons {
|
|
117
|
-
padding-right: $
|
|
118
|
-
background: $
|
|
82
|
+
padding-right: $form-select-feedback-icon-padding-right;
|
|
83
|
+
background-image: escape-svg($form-select-indicator), escape-svg($icon);
|
|
84
|
+
background-position: $form-select-bg-position, $form-select-feedback-icon-position;
|
|
85
|
+
background-size: $form-select-bg-size, $form-select-feedback-icon-size;
|
|
119
86
|
}
|
|
120
87
|
|
|
121
88
|
&:focus {
|
|
@@ -127,55 +94,36 @@
|
|
|
127
94
|
|
|
128
95
|
.form-check-input {
|
|
129
96
|
@include form-validation-state-selector($state) {
|
|
130
|
-
|
|
131
|
-
color: $color;
|
|
132
|
-
}
|
|
133
|
-
|
|
134
|
-
~ .#{$state}-feedback,
|
|
135
|
-
~ .#{$state}-tooltip {
|
|
136
|
-
display: block;
|
|
137
|
-
}
|
|
138
|
-
}
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
.custom-control-input {
|
|
142
|
-
@include form-validation-state-selector($state) {
|
|
143
|
-
~ .custom-control-label {
|
|
144
|
-
color: $color;
|
|
145
|
-
|
|
146
|
-
&::before {
|
|
147
|
-
border-color: $color;
|
|
148
|
-
}
|
|
149
|
-
}
|
|
97
|
+
border-color: $color;
|
|
150
98
|
|
|
151
99
|
&:checked {
|
|
152
|
-
|
|
153
|
-
border-color: lighten($color, 10%);
|
|
154
|
-
@include gradient-bg(lighten($color, 10%));
|
|
155
|
-
}
|
|
100
|
+
background-color: $color;
|
|
156
101
|
}
|
|
157
102
|
|
|
158
103
|
&:focus {
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
}
|
|
104
|
+
box-shadow: 0 0 0 $input-focus-width rgba($color, .25);
|
|
105
|
+
}
|
|
162
106
|
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
}
|
|
107
|
+
~ .form-check-label {
|
|
108
|
+
color: $color;
|
|
166
109
|
}
|
|
167
110
|
}
|
|
168
111
|
}
|
|
112
|
+
.form-check-inline .form-check-input {
|
|
113
|
+
~ .#{$state}-feedback {
|
|
114
|
+
margin-left: .5em;
|
|
115
|
+
}
|
|
116
|
+
}
|
|
169
117
|
|
|
170
118
|
// custom file
|
|
171
|
-
.
|
|
119
|
+
.form-file-input {
|
|
172
120
|
@include form-validation-state-selector($state) {
|
|
173
|
-
~ .
|
|
121
|
+
~ .form-file-label {
|
|
174
122
|
border-color: $color;
|
|
175
123
|
}
|
|
176
124
|
|
|
177
125
|
&:focus {
|
|
178
|
-
~ .
|
|
126
|
+
~ .form-file-label {
|
|
179
127
|
border-color: $color;
|
|
180
128
|
box-shadow: 0 0 0 $input-focus-width rgba($color, .25);
|
|
181
129
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// Gradients
|
|
2
2
|
|
|
3
|
-
@mixin gradient-bg($color) {
|
|
3
|
+
@mixin gradient-bg($color: null) {
|
|
4
|
+
background-color: $color;
|
|
5
|
+
|
|
4
6
|
@if $enable-gradients {
|
|
5
|
-
background:
|
|
6
|
-
} @else {
|
|
7
|
-
background-color: $color;
|
|
7
|
+
background-image: var(--bs-gradient);
|
|
8
8
|
}
|
|
9
9
|
}
|
|
10
10
|
|
|
@@ -13,33 +13,31 @@
|
|
|
13
13
|
// Creates two color stops, start and end, by specifying a color and position for each color stop.
|
|
14
14
|
@mixin gradient-x($start-color: $gray-700, $end-color: $gray-800, $start-percent: 0%, $end-percent: 100%) {
|
|
15
15
|
background-image: linear-gradient(to right, $start-color $start-percent, $end-color $end-percent);
|
|
16
|
-
background-repeat: repeat-x;
|
|
17
16
|
}
|
|
18
17
|
|
|
19
18
|
// Vertical gradient, from top to bottom
|
|
20
19
|
//
|
|
21
20
|
// Creates two color stops, start and end, by specifying a color and position for each color stop.
|
|
22
|
-
@mixin gradient-y($start-color: $gray-700, $end-color: $gray-800, $start-percent:
|
|
21
|
+
@mixin gradient-y($start-color: $gray-700, $end-color: $gray-800, $start-percent: null, $end-percent: null) {
|
|
23
22
|
background-image: linear-gradient(to bottom, $start-color $start-percent, $end-color $end-percent);
|
|
24
|
-
background-repeat: repeat-x;
|
|
25
23
|
}
|
|
26
24
|
|
|
27
25
|
@mixin gradient-directional($start-color: $gray-700, $end-color: $gray-800, $deg: 45deg) {
|
|
28
26
|
background-image: linear-gradient($deg, $start-color, $end-color);
|
|
29
|
-
background-repeat: repeat-x;
|
|
30
27
|
}
|
|
28
|
+
|
|
31
29
|
@mixin gradient-x-three-colors($start-color: $blue, $mid-color: $purple, $color-stop: 50%, $end-color: $red) {
|
|
32
30
|
background-image: linear-gradient(to right, $start-color, $mid-color $color-stop, $end-color);
|
|
33
|
-
background-repeat: no-repeat;
|
|
34
31
|
}
|
|
32
|
+
|
|
35
33
|
@mixin gradient-y-three-colors($start-color: $blue, $mid-color: $purple, $color-stop: 50%, $end-color: $red) {
|
|
36
34
|
background-image: linear-gradient($start-color, $mid-color $color-stop, $end-color);
|
|
37
|
-
background-repeat: no-repeat;
|
|
38
35
|
}
|
|
36
|
+
|
|
39
37
|
@mixin gradient-radial($inner-color: $gray-700, $outer-color: $gray-800) {
|
|
40
38
|
background-image: radial-gradient(circle, $inner-color, $outer-color);
|
|
41
|
-
background-repeat: no-repeat;
|
|
42
39
|
}
|
|
40
|
+
|
|
43
41
|
@mixin gradient-striped($color: rgba($white, .15), $angle: 45deg) {
|
|
44
42
|
background-image: linear-gradient($angle, $color 25%, transparent 25%, transparent 50%, $color 50%, $color 75%, transparent 75%, transparent);
|
|
45
43
|
}
|
|
@@ -2,53 +2,39 @@
|
|
|
2
2
|
//
|
|
3
3
|
// Generate semantic grid columns with these mixins.
|
|
4
4
|
|
|
5
|
-
@mixin make-container($gutter: $grid-gutter-width) {
|
|
6
|
-
width: 100%;
|
|
7
|
-
padding-right: $gutter / 2;
|
|
8
|
-
padding-left: $gutter / 2;
|
|
9
|
-
margin-right: auto;
|
|
10
|
-
margin-left: auto;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
5
|
@mixin make-row($gutter: $grid-gutter-width) {
|
|
6
|
+
--bs-gutter-x: #{$gutter};
|
|
7
|
+
--bs-gutter-y: 0;
|
|
14
8
|
display: flex;
|
|
9
|
+
flex: 1 0 100%;
|
|
15
10
|
flex-wrap: wrap;
|
|
16
|
-
margin-
|
|
17
|
-
margin-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
// For each breakpoint, define the maximum width of the container in a media query
|
|
21
|
-
@mixin make-container-max-widths($max-widths: $container-max-widths, $breakpoints: $grid-breakpoints) {
|
|
22
|
-
@each $breakpoint, $container-max-width in $max-widths {
|
|
23
|
-
@include media-breakpoint-up($breakpoint, $breakpoints) {
|
|
24
|
-
max-width: $container-max-width;
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
@include deprecate("The `make-container-max-widths` mixin", "v4.5.2", "v5");
|
|
11
|
+
margin-top: calc(var(--bs-gutter-y) * -1); // stylelint-disable-line function-blacklist
|
|
12
|
+
margin-right: calc(var(--bs-gutter-x) / -2); // stylelint-disable-line function-blacklist
|
|
13
|
+
margin-left: calc(var(--bs-gutter-x) / -2); // stylelint-disable-line function-blacklist
|
|
28
14
|
}
|
|
29
15
|
|
|
30
16
|
@mixin make-col-ready($gutter: $grid-gutter-width) {
|
|
31
|
-
|
|
17
|
+
// Add box sizing if only the grid is loaded
|
|
18
|
+
box-sizing: if(variable-exists(include-column-box-sizing) and $include-column-box-sizing, border-box, null);
|
|
32
19
|
// Prevent columns from becoming too narrow when at smaller grid tiers by
|
|
33
|
-
// always setting `width: 100%;`. This works because we
|
|
20
|
+
// always setting `width: 100%;`. This works because we set the width
|
|
34
21
|
// later on to override this initial width.
|
|
22
|
+
flex-shrink: 0;
|
|
35
23
|
width: 100%;
|
|
36
|
-
|
|
37
|
-
padding-
|
|
24
|
+
max-width: 100%; // Prevent `.col-auto`, `.col` (& responsive variants) from breaking out the grid
|
|
25
|
+
padding-right: calc(var(--bs-gutter-x) / 2); // stylelint-disable-line function-blacklist
|
|
26
|
+
padding-left: calc(var(--bs-gutter-x) / 2); // stylelint-disable-line function-blacklist
|
|
27
|
+
margin-top: var(--bs-gutter-y);
|
|
38
28
|
}
|
|
39
29
|
|
|
40
30
|
@mixin make-col($size, $columns: $grid-columns) {
|
|
41
|
-
flex: 0 0
|
|
42
|
-
|
|
43
|
-
// the width of the column. Applies to IE10+ and Firefox. Chrome and Safari
|
|
44
|
-
// do not appear to require this.
|
|
45
|
-
max-width: percentage($size / $columns);
|
|
31
|
+
flex: 0 0 auto;
|
|
32
|
+
width: percentage($size / $columns);
|
|
46
33
|
}
|
|
47
34
|
|
|
48
35
|
@mixin make-col-auto() {
|
|
49
36
|
flex: 0 0 auto;
|
|
50
37
|
width: auto;
|
|
51
|
-
max-width: 100%; // Reset earlier grid tiers
|
|
52
38
|
}
|
|
53
39
|
|
|
54
40
|
@mixin make-col-offset($size, $columns: $grid-columns) {
|
|
@@ -62,8 +48,74 @@
|
|
|
62
48
|
// numberof columns. Supports wrapping to new lines, but does not do a Masonry
|
|
63
49
|
// style grid.
|
|
64
50
|
@mixin row-cols($count) {
|
|
65
|
-
> * {
|
|
66
|
-
flex: 0 0
|
|
67
|
-
|
|
51
|
+
& > * {
|
|
52
|
+
flex: 0 0 auto;
|
|
53
|
+
width: 100% / $count;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
// Framework grid generation
|
|
58
|
+
//
|
|
59
|
+
// Used only by Bootstrap to generate the correct number of grid classes given
|
|
60
|
+
// any value of `$grid-columns`.
|
|
61
|
+
|
|
62
|
+
@mixin make-grid-columns($columns: $grid-columns, $gutter: $grid-gutter-width, $breakpoints: $grid-breakpoints) {
|
|
63
|
+
@each $breakpoint in map-keys($breakpoints) {
|
|
64
|
+
$infix: breakpoint-infix($breakpoint, $breakpoints);
|
|
65
|
+
|
|
66
|
+
@include media-breakpoint-up($breakpoint, $breakpoints) {
|
|
67
|
+
// Provide basic `.col-{bp}` classes for equal-width flexbox columns
|
|
68
|
+
.col#{$infix} {
|
|
69
|
+
flex: 1 0 0%; // Flexbugs #4: https://github.com/philipwalton/flexbugs#flexbug-4
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.row-cols#{$infix}-auto > * {
|
|
73
|
+
@include make-col-auto();
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
@if $grid-row-columns > 0 {
|
|
77
|
+
@for $i from 1 through $grid-row-columns {
|
|
78
|
+
.row-cols#{$infix}-#{$i} {
|
|
79
|
+
@include row-cols($i);
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.col#{$infix}-auto {
|
|
85
|
+
@include make-col-auto();
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
@if $columns > 0 {
|
|
89
|
+
@for $i from 1 through $columns {
|
|
90
|
+
.col#{$infix}-#{$i} {
|
|
91
|
+
@include make-col($i, $columns);
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
// `$columns - 1` because offsetting by the width of an entire row isn't possible
|
|
96
|
+
@for $i from 0 through ($columns - 1) {
|
|
97
|
+
@if not ($infix == "" and $i == 0) { // Avoid emitting useless .offset-0
|
|
98
|
+
.offset#{$infix}-#{$i} {
|
|
99
|
+
@include make-col-offset($i, $columns);
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
// Gutters
|
|
106
|
+
//
|
|
107
|
+
// Make use of `.g-*`, `.gx-*` or `.gy-*` utilities to change spacing between the columns.
|
|
108
|
+
@each $key, $value in $gutters {
|
|
109
|
+
.g#{$infix}-#{$key},
|
|
110
|
+
.gx#{$infix}-#{$key} {
|
|
111
|
+
--bs-gutter-x: #{$value};
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.g#{$infix}-#{$key},
|
|
115
|
+
.gy#{$infix}-#{$key} {
|
|
116
|
+
--bs-gutter-y: #{$value};
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
}
|
|
68
120
|
}
|
|
69
121
|
}
|