bootstrap 4.4.1 → 5.0.1
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/.travis.yml +13 -2
- data/README.md +7 -4
- data/assets/javascripts/bootstrap-global-this-define.js +6 -0
- data/assets/javascripts/bootstrap-global-this-undefine.js +2 -0
- data/assets/javascripts/bootstrap-sprockets.js +15 -8
- data/assets/javascripts/bootstrap.js +3244 -2770
- data/assets/javascripts/bootstrap.min.js +4 -4
- data/assets/javascripts/bootstrap/alert.js +130 -124
- data/assets/javascripts/bootstrap/base-component.js +168 -0
- data/assets/javascripts/bootstrap/button.js +85 -179
- data/assets/javascripts/bootstrap/carousel.js +430 -405
- data/assets/javascripts/bootstrap/collapse.js +325 -264
- data/assets/javascripts/bootstrap/dom/data.js +68 -0
- data/assets/javascripts/bootstrap/dom/event-handler.js +315 -0
- data/assets/javascripts/bootstrap/dom/manipulator.js +88 -0
- data/assets/javascripts/bootstrap/dom/selector-engine.js +85 -0
- data/assets/javascripts/bootstrap/dropdown.js +464 -400
- data/assets/javascripts/bootstrap/modal.js +604 -464
- data/assets/javascripts/bootstrap/offcanvas.js +671 -0
- data/assets/javascripts/bootstrap/popover.js +119 -192
- data/assets/javascripts/bootstrap/scrollspy.js +250 -238
- data/assets/javascripts/bootstrap/tab.js +189 -151
- data/assets/javascripts/bootstrap/toast.js +215 -192
- data/assets/javascripts/bootstrap/tooltip.js +604 -544
- data/assets/stylesheets/_bootstrap-grid.scss +54 -18
- data/assets/stylesheets/_bootstrap-reboot.scss +7 -4
- data/assets/stylesheets/_bootstrap.scss +19 -11
- data/assets/stylesheets/bootstrap/_accordion.scss +118 -0
- data/assets/stylesheets/bootstrap/_alert.scss +15 -9
- data/assets/stylesheets/bootstrap/_badge.scss +2 -27
- data/assets/stylesheets/bootstrap/_breadcrumb.scss +4 -18
- data/assets/stylesheets/bootstrap/_button-group.scss +21 -45
- data/assets/stylesheets/bootstrap/_buttons.scss +27 -55
- data/assets/stylesheets/bootstrap/_card.scss +43 -106
- data/assets/stylesheets/bootstrap/_carousel.scss +65 -33
- data/assets/stylesheets/bootstrap/_close.scss +30 -31
- data/assets/stylesheets/bootstrap/_containers.scss +41 -0
- data/assets/stylesheets/bootstrap/_dropdown.scss +87 -38
- data/assets/stylesheets/bootstrap/_forms.scss +9 -338
- data/assets/stylesheets/bootstrap/_functions.scss +99 -28
- data/assets/stylesheets/bootstrap/_grid.scss +3 -50
- data/assets/stylesheets/bootstrap/_helpers.scss +7 -0
- data/assets/stylesheets/bootstrap/_list-group.scss +38 -22
- data/assets/stylesheets/bootstrap/_mixins.scss +8 -13
- data/assets/stylesheets/bootstrap/_modal.scss +45 -65
- data/assets/stylesheets/bootstrap/_nav.scss +28 -9
- data/assets/stylesheets/bootstrap/_navbar.scss +51 -69
- data/assets/stylesheets/bootstrap/_offcanvas.scss +77 -0
- data/assets/stylesheets/bootstrap/_pagination.scss +11 -20
- data/assets/stylesheets/bootstrap/_popover.scss +15 -27
- data/assets/stylesheets/bootstrap/_progress.scss +6 -4
- data/assets/stylesheets/bootstrap/_reboot.scss +339 -200
- data/assets/stylesheets/bootstrap/_root.scss +5 -9
- data/assets/stylesheets/bootstrap/_spinners.scss +21 -7
- data/assets/stylesheets/bootstrap/_tables.scss +80 -114
- data/assets/stylesheets/bootstrap/_toasts.scss +21 -14
- data/assets/stylesheets/bootstrap/_tooltip.scss +17 -17
- data/assets/stylesheets/bootstrap/_transitions.scss +2 -1
- data/assets/stylesheets/bootstrap/_type.scss +38 -59
- data/assets/stylesheets/bootstrap/_utilities.scss +594 -17
- data/assets/stylesheets/bootstrap/_variables.scss +810 -489
- data/assets/stylesheets/bootstrap/bootstrap-utilities.scss +18 -0
- data/assets/stylesheets/bootstrap/forms/_floating-labels.scss +61 -0
- data/assets/stylesheets/bootstrap/forms/_form-check.scss +152 -0
- data/assets/stylesheets/bootstrap/forms/_form-control.scss +219 -0
- data/assets/stylesheets/bootstrap/forms/_form-range.scss +91 -0
- data/assets/stylesheets/bootstrap/forms/_form-select.scss +67 -0
- data/assets/stylesheets/bootstrap/forms/_form-text.scss +11 -0
- data/assets/stylesheets/bootstrap/forms/_input-group.scss +121 -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/_position.scss +30 -0
- data/assets/stylesheets/bootstrap/helpers/_ratio.scss +26 -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/helpers/_visually-hidden.scss +8 -0
- data/assets/stylesheets/bootstrap/mixins/_alert.scss +3 -5
- data/assets/stylesheets/bootstrap/mixins/_border-radius.scss +37 -22
- data/assets/stylesheets/bootstrap/mixins/_box-shadow.scss +7 -9
- data/assets/stylesheets/bootstrap/mixins/_breakpoints.scss +14 -10
- data/assets/stylesheets/bootstrap/mixins/_buttons.scss +75 -52
- data/assets/stylesheets/bootstrap/mixins/_caret.scss +10 -8
- data/assets/stylesheets/bootstrap/mixins/_clearfix.scss +2 -0
- data/assets/stylesheets/bootstrap/mixins/_color-scheme.scss +7 -0
- data/assets/stylesheets/bootstrap/mixins/_container.scss +9 -0
- data/assets/stylesheets/bootstrap/mixins/_forms.scss +42 -75
- data/assets/stylesheets/bootstrap/mixins/_gradients.scss +13 -11
- data/assets/stylesheets/bootstrap/mixins/_grid.scss +90 -34
- data/assets/stylesheets/bootstrap/mixins/_image.scss +1 -21
- data/assets/stylesheets/bootstrap/mixins/_list-group.scss +5 -2
- data/assets/stylesheets/bootstrap/mixins/_lists.scss +1 -1
- data/assets/stylesheets/bootstrap/mixins/_pagination.scss +17 -8
- data/assets/stylesheets/bootstrap/mixins/_reset-text.scss +2 -2
- data/assets/stylesheets/bootstrap/mixins/_table-variants.scss +21 -0
- data/assets/stylesheets/bootstrap/mixins/_transition.scss +18 -8
- data/assets/stylesheets/bootstrap/mixins/_utilities.scss +68 -0
- data/assets/stylesheets/bootstrap/mixins/_visually-hidden.scss +29 -0
- data/assets/stylesheets/bootstrap/utilities/_api.scss +47 -0
- data/assets/stylesheets/bootstrap/vendor/_rfs.scss +234 -126
- data/bootstrap.gemspec +1 -3
- data/lib/bootstrap/version.rb +2 -2
- data/tasks/updater/js.rb +20 -5
- data/tasks/updater/network.rb +8 -2
- data/test/dummy_rails/app/assets/javascripts/application.js +4 -3
- data/test/dummy_rails/app/views/layouts/application.html.erb +3 -1
- data/test/dummy_rails/app/views/pages/root.html +89 -0
- data/test/dummy_rails/config/application.rb +0 -3
- data/test/gemfiles/rails_6_0.gemfile +7 -0
- data/test/gemfiles/rails_6_1.gemfile +7 -0
- metadata +48 -73
- data/assets/javascripts/bootstrap/util.js +0 -188
- data/assets/stylesheets/bootstrap/_code.scss +0 -48
- data/assets/stylesheets/bootstrap/_custom-forms.scss +0 -521
- data/assets/stylesheets/bootstrap/_input-group.scss +0 -191
- 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 -22
- 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 -71
- data/assets/stylesheets/bootstrap/mixins/_hover.scss +0 -37
- data/assets/stylesheets/bootstrap/mixins/_nav-divider.scss +0 -11
- data/assets/stylesheets/bootstrap/mixins/_screen-reader.scss +0 -34
- 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/_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
- data/test/dummy_rails/app/views/pages/root.html.slim +0 -58
|
@@ -1,41 +1,40 @@
|
|
|
1
|
-
.
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
1
|
+
// transparent background and border properties included for button version.
|
|
2
|
+
// iOS requires the button element instead of an anchor tag.
|
|
3
|
+
// If you want the anchor version, it requires `href="#"`.
|
|
4
|
+
// See https://developer.mozilla.org/en-US/docs/Web/Events/click#Safari_Mobile
|
|
5
|
+
|
|
6
|
+
.btn-close {
|
|
7
|
+
box-sizing: content-box;
|
|
8
|
+
width: $btn-close-width;
|
|
9
|
+
height: $btn-close-height;
|
|
10
|
+
padding: $btn-close-padding-y $btn-close-padding-x;
|
|
11
|
+
color: $btn-close-color;
|
|
12
|
+
background: transparent escape-svg($btn-close-bg) center / $btn-close-width auto no-repeat; // include transparent for button elements
|
|
13
|
+
border: 0; // for button elements
|
|
14
|
+
@include border-radius();
|
|
15
|
+
opacity: $btn-close-opacity;
|
|
9
16
|
|
|
10
17
|
// Override <a>'s hover style
|
|
11
|
-
|
|
12
|
-
color: $close-color;
|
|
18
|
+
&:hover {
|
|
19
|
+
color: $btn-close-color;
|
|
13
20
|
text-decoration: none;
|
|
21
|
+
opacity: $btn-close-hover-opacity;
|
|
14
22
|
}
|
|
15
23
|
|
|
16
|
-
&:
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
24
|
+
&:focus {
|
|
25
|
+
outline: 0;
|
|
26
|
+
box-shadow: $btn-close-focus-shadow;
|
|
27
|
+
opacity: $btn-close-focus-opacity;
|
|
20
28
|
}
|
|
21
|
-
}
|
|
22
29
|
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
button.close {
|
|
30
|
-
padding: 0;
|
|
31
|
-
background-color: transparent;
|
|
32
|
-
border: 0;
|
|
33
|
-
appearance: none;
|
|
30
|
+
&:disabled,
|
|
31
|
+
&.disabled {
|
|
32
|
+
pointer-events: none;
|
|
33
|
+
user-select: none;
|
|
34
|
+
opacity: $btn-close-disabled-opacity;
|
|
35
|
+
}
|
|
34
36
|
}
|
|
35
37
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
// stylelint-disable-next-line selector-no-qualifying-type
|
|
39
|
-
a.close.disabled {
|
|
40
|
-
pointer-events: none;
|
|
38
|
+
.btn-close-white {
|
|
39
|
+
filter: $btn-close-white-filter;
|
|
41
40
|
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
// Container widths
|
|
2
|
+
//
|
|
3
|
+
// Set the container width, and override it for fixed navbars in media queries.
|
|
4
|
+
|
|
5
|
+
@if $enable-grid-classes {
|
|
6
|
+
// Single container class with breakpoint max-widths
|
|
7
|
+
.container,
|
|
8
|
+
// 100% wide container at all breakpoints
|
|
9
|
+
.container-fluid {
|
|
10
|
+
@include make-container();
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
// Responsive containers that are 100% wide until a breakpoint
|
|
14
|
+
@each $breakpoint, $container-max-width in $container-max-widths {
|
|
15
|
+
.container-#{$breakpoint} {
|
|
16
|
+
@extend .container-fluid;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
@include media-breakpoint-up($breakpoint, $grid-breakpoints) {
|
|
20
|
+
%responsive-container-#{$breakpoint} {
|
|
21
|
+
max-width: $container-max-width;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
// Extend each breakpoint which is smaller or equal to the current breakpoint
|
|
25
|
+
$extend-breakpoint: true;
|
|
26
|
+
|
|
27
|
+
@each $name, $width in $grid-breakpoints {
|
|
28
|
+
@if ($extend-breakpoint) {
|
|
29
|
+
.container#{breakpoint-infix($name, $grid-breakpoints)} {
|
|
30
|
+
@extend %responsive-container-#{$breakpoint};
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
// Once the current breakpoint is reached, stop extending
|
|
34
|
+
@if ($breakpoint == $name) {
|
|
35
|
+
$extend-breakpoint: false;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
// The dropdown wrapper (`<div>`)
|
|
2
2
|
.dropup,
|
|
3
|
-
.
|
|
3
|
+
.dropend,
|
|
4
4
|
.dropdown,
|
|
5
|
-
.
|
|
5
|
+
.dropstart {
|
|
6
6
|
position: relative;
|
|
7
7
|
}
|
|
8
8
|
|
|
@@ -16,14 +16,11 @@
|
|
|
16
16
|
// The dropdown menu
|
|
17
17
|
.dropdown-menu {
|
|
18
18
|
position: absolute;
|
|
19
|
-
top: 100%;
|
|
20
|
-
left: 0;
|
|
21
19
|
z-index: $zindex-dropdown;
|
|
22
20
|
display: none; // none by default, but block on "open" of the menu
|
|
23
|
-
float: left;
|
|
24
21
|
min-width: $dropdown-min-width;
|
|
25
|
-
padding: $dropdown-padding-y
|
|
26
|
-
margin:
|
|
22
|
+
padding: $dropdown-padding-y $dropdown-padding-x;
|
|
23
|
+
margin: 0; // Override default margin of ul
|
|
27
24
|
@include font-size($dropdown-font-size);
|
|
28
25
|
color: $dropdown-color;
|
|
29
26
|
text-align: left; // Ensures proper alignment if parent has it changed (e.g., modal footer)
|
|
@@ -33,28 +30,47 @@
|
|
|
33
30
|
border: $dropdown-border-width solid $dropdown-border-color;
|
|
34
31
|
@include border-radius($dropdown-border-radius);
|
|
35
32
|
@include box-shadow($dropdown-box-shadow);
|
|
33
|
+
|
|
34
|
+
&[data-bs-popper] {
|
|
35
|
+
top: 100%;
|
|
36
|
+
left: 0;
|
|
37
|
+
margin-top: $dropdown-spacer;
|
|
38
|
+
}
|
|
36
39
|
}
|
|
37
40
|
|
|
41
|
+
// scss-docs-start responsive-breakpoints
|
|
42
|
+
// We deliberately hardcode the `bs-` prefix because we check
|
|
43
|
+
// this custom property in JS to determine Popper's positioning
|
|
44
|
+
|
|
38
45
|
@each $breakpoint in map-keys($grid-breakpoints) {
|
|
39
46
|
@include media-breakpoint-up($breakpoint) {
|
|
40
47
|
$infix: breakpoint-infix($breakpoint, $grid-breakpoints);
|
|
41
48
|
|
|
42
|
-
.dropdown-menu#{$infix}-
|
|
43
|
-
|
|
44
|
-
|
|
49
|
+
.dropdown-menu#{$infix}-start {
|
|
50
|
+
--bs-position: start;
|
|
51
|
+
|
|
52
|
+
&[data-bs-popper] {
|
|
53
|
+
right: auto #{"/* rtl:ignore */"};
|
|
54
|
+
left: 0 #{"/* rtl:ignore */"};
|
|
55
|
+
}
|
|
45
56
|
}
|
|
46
57
|
|
|
47
|
-
.dropdown-menu#{$infix}-
|
|
48
|
-
|
|
49
|
-
|
|
58
|
+
.dropdown-menu#{$infix}-end {
|
|
59
|
+
--bs-position: end;
|
|
60
|
+
|
|
61
|
+
&[data-bs-popper] {
|
|
62
|
+
right: 0 #{"/* rtl:ignore */"};
|
|
63
|
+
left: auto #{"/* rtl:ignore */"};
|
|
64
|
+
}
|
|
50
65
|
}
|
|
51
66
|
}
|
|
52
67
|
}
|
|
68
|
+
// scss-docs-end responsive-breakpoints
|
|
53
69
|
|
|
54
70
|
// Allow for dropdowns to go bottom up (aka, dropup-menu)
|
|
55
71
|
// Just add .dropup after the standard .dropdown class and you're set.
|
|
56
72
|
.dropup {
|
|
57
|
-
.dropdown-menu {
|
|
73
|
+
.dropdown-menu[data-bs-popper] {
|
|
58
74
|
top: auto;
|
|
59
75
|
bottom: 100%;
|
|
60
76
|
margin-top: 0;
|
|
@@ -66,8 +82,8 @@
|
|
|
66
82
|
}
|
|
67
83
|
}
|
|
68
84
|
|
|
69
|
-
.
|
|
70
|
-
.dropdown-menu {
|
|
85
|
+
.dropend {
|
|
86
|
+
.dropdown-menu[data-bs-popper] {
|
|
71
87
|
top: 0;
|
|
72
88
|
right: auto;
|
|
73
89
|
left: 100%;
|
|
@@ -76,15 +92,15 @@
|
|
|
76
92
|
}
|
|
77
93
|
|
|
78
94
|
.dropdown-toggle {
|
|
79
|
-
@include caret(
|
|
95
|
+
@include caret(end);
|
|
80
96
|
&::after {
|
|
81
97
|
vertical-align: 0;
|
|
82
98
|
}
|
|
83
99
|
}
|
|
84
100
|
}
|
|
85
101
|
|
|
86
|
-
.
|
|
87
|
-
.dropdown-menu {
|
|
102
|
+
.dropstart {
|
|
103
|
+
.dropdown-menu[data-bs-popper] {
|
|
88
104
|
top: 0;
|
|
89
105
|
right: 100%;
|
|
90
106
|
left: auto;
|
|
@@ -93,28 +109,20 @@
|
|
|
93
109
|
}
|
|
94
110
|
|
|
95
111
|
.dropdown-toggle {
|
|
96
|
-
@include caret(
|
|
112
|
+
@include caret(start);
|
|
97
113
|
&::before {
|
|
98
114
|
vertical-align: 0;
|
|
99
115
|
}
|
|
100
116
|
}
|
|
101
117
|
}
|
|
102
118
|
|
|
103
|
-
// When enabled Popper.js, reset basic dropdown position
|
|
104
|
-
// stylelint-disable-next-line no-duplicate-selectors
|
|
105
|
-
.dropdown-menu {
|
|
106
|
-
&[x-placement^="top"],
|
|
107
|
-
&[x-placement^="right"],
|
|
108
|
-
&[x-placement^="bottom"],
|
|
109
|
-
&[x-placement^="left"] {
|
|
110
|
-
right: auto;
|
|
111
|
-
bottom: auto;
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
119
|
|
|
115
120
|
// Dividers (basically an `<hr>`) within the dropdown
|
|
116
121
|
.dropdown-divider {
|
|
117
|
-
|
|
122
|
+
height: 0;
|
|
123
|
+
margin: $dropdown-divider-margin-y 0;
|
|
124
|
+
overflow: hidden;
|
|
125
|
+
border-top: 1px solid $dropdown-divider-bg;
|
|
118
126
|
}
|
|
119
127
|
|
|
120
128
|
// Links, buttons, and more within the dropdown menu
|
|
@@ -128,6 +136,7 @@
|
|
|
128
136
|
font-weight: $font-weight-normal;
|
|
129
137
|
color: $dropdown-link-color;
|
|
130
138
|
text-align: inherit; // For `<button>`s
|
|
139
|
+
text-decoration: if($link-decoration == none, null, none);
|
|
131
140
|
white-space: nowrap; // prevent links from randomly breaking onto new lines
|
|
132
141
|
background-color: transparent; // For `<button>`s
|
|
133
142
|
border: 0; // For `<button>`s
|
|
@@ -144,9 +153,10 @@
|
|
|
144
153
|
}
|
|
145
154
|
}
|
|
146
155
|
|
|
147
|
-
|
|
156
|
+
&:hover,
|
|
157
|
+
&:focus {
|
|
148
158
|
color: $dropdown-link-hover-color;
|
|
149
|
-
text-decoration: none;
|
|
159
|
+
text-decoration: if($link-hover-decoration == underline, none, null);
|
|
150
160
|
@include gradient-bg($dropdown-link-hover-bg);
|
|
151
161
|
}
|
|
152
162
|
|
|
@@ -163,9 +173,7 @@
|
|
|
163
173
|
pointer-events: none;
|
|
164
174
|
background-color: transparent;
|
|
165
175
|
// Remove CSS gradients if they're enabled
|
|
166
|
-
|
|
167
|
-
background-image: none;
|
|
168
|
-
}
|
|
176
|
+
background-image: if($enable-gradients, none, null);
|
|
169
177
|
}
|
|
170
178
|
}
|
|
171
179
|
|
|
@@ -176,7 +184,7 @@
|
|
|
176
184
|
// Dropdown section headers
|
|
177
185
|
.dropdown-header {
|
|
178
186
|
display: block;
|
|
179
|
-
padding: $dropdown-
|
|
187
|
+
padding: $dropdown-header-padding;
|
|
180
188
|
margin-bottom: 0; // for use with heading elements
|
|
181
189
|
@include font-size($font-size-sm);
|
|
182
190
|
color: $dropdown-header-color;
|
|
@@ -189,3 +197,44 @@
|
|
|
189
197
|
padding: $dropdown-item-padding-y $dropdown-item-padding-x;
|
|
190
198
|
color: $dropdown-link-color;
|
|
191
199
|
}
|
|
200
|
+
|
|
201
|
+
// Dark dropdowns
|
|
202
|
+
.dropdown-menu-dark {
|
|
203
|
+
color: $dropdown-dark-color;
|
|
204
|
+
background-color: $dropdown-dark-bg;
|
|
205
|
+
border-color: $dropdown-dark-border-color;
|
|
206
|
+
@include box-shadow($dropdown-dark-box-shadow);
|
|
207
|
+
|
|
208
|
+
.dropdown-item {
|
|
209
|
+
color: $dropdown-dark-link-color;
|
|
210
|
+
|
|
211
|
+
&:hover,
|
|
212
|
+
&:focus {
|
|
213
|
+
color: $dropdown-dark-link-hover-color;
|
|
214
|
+
@include gradient-bg($dropdown-dark-link-hover-bg);
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
&.active,
|
|
218
|
+
&:active {
|
|
219
|
+
color: $dropdown-dark-link-active-color;
|
|
220
|
+
@include gradient-bg($dropdown-dark-link-active-bg);
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
&.disabled,
|
|
224
|
+
&:disabled {
|
|
225
|
+
color: $dropdown-dark-link-disabled-color;
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
.dropdown-divider {
|
|
230
|
+
border-color: $dropdown-dark-divider-bg;
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
.dropdown-item-text {
|
|
234
|
+
color: $dropdown-dark-link-color;
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
.dropdown-header {
|
|
238
|
+
color: $dropdown-dark-header-color;
|
|
239
|
+
}
|
|
240
|
+
}
|
|
@@ -1,338 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
height: $input-height;
|
|
11
|
-
padding: $input-padding-y $input-padding-x;
|
|
12
|
-
font-family: $input-font-family;
|
|
13
|
-
@include font-size($input-font-size);
|
|
14
|
-
font-weight: $input-font-weight;
|
|
15
|
-
line-height: $input-line-height;
|
|
16
|
-
color: $input-color;
|
|
17
|
-
background-color: $input-bg;
|
|
18
|
-
background-clip: padding-box;
|
|
19
|
-
border: $input-border-width solid $input-border-color;
|
|
20
|
-
|
|
21
|
-
// Note: This has no effect on <select>s in some browsers, due to the limited stylability of `<select>`s in CSS.
|
|
22
|
-
@include border-radius($input-border-radius, 0);
|
|
23
|
-
|
|
24
|
-
@include box-shadow($input-box-shadow);
|
|
25
|
-
@include transition($input-transition);
|
|
26
|
-
|
|
27
|
-
// Unstyle the caret on `<select>`s in IE10+.
|
|
28
|
-
&::-ms-expand {
|
|
29
|
-
background-color: transparent;
|
|
30
|
-
border: 0;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
// Remove select outline from select box in FF
|
|
34
|
-
&:-moz-focusring {
|
|
35
|
-
color: transparent;
|
|
36
|
-
text-shadow: 0 0 0 $input-color;
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
// Customize the `:focus` state to imitate native WebKit styles.
|
|
40
|
-
@include form-control-focus($ignore-warning: true);
|
|
41
|
-
|
|
42
|
-
// Placeholder
|
|
43
|
-
&::placeholder {
|
|
44
|
-
color: $input-placeholder-color;
|
|
45
|
-
// Override Firefox's unusual default opacity; see https://github.com/twbs/bootstrap/pull/11526.
|
|
46
|
-
opacity: 1;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
// Disabled and read-only inputs
|
|
50
|
-
//
|
|
51
|
-
// HTML5 says that controls under a fieldset > legend:first-child won't be
|
|
52
|
-
// disabled if the fieldset is disabled. Due to implementation difficulty, we
|
|
53
|
-
// don't honor that edge case; we style them as disabled anyway.
|
|
54
|
-
&:disabled,
|
|
55
|
-
&[readonly] {
|
|
56
|
-
background-color: $input-disabled-bg;
|
|
57
|
-
// iOS fix for unreadable disabled content; see https://github.com/twbs/bootstrap/issues/11655.
|
|
58
|
-
opacity: 1;
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
select.form-control {
|
|
63
|
-
&:focus::-ms-value {
|
|
64
|
-
// Suppress the nested default white text on blue background highlight given to
|
|
65
|
-
// the selected option text when the (still closed) <select> receives focus
|
|
66
|
-
// in IE and (under certain conditions) Edge, as it looks bad and cannot be made to
|
|
67
|
-
// match the appearance of the native widget.
|
|
68
|
-
// See https://github.com/twbs/bootstrap/issues/19398.
|
|
69
|
-
color: $input-color;
|
|
70
|
-
background-color: $input-bg;
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
// Make file inputs better match text inputs by forcing them to new lines.
|
|
75
|
-
.form-control-file,
|
|
76
|
-
.form-control-range {
|
|
77
|
-
display: block;
|
|
78
|
-
width: 100%;
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
//
|
|
83
|
-
// Labels
|
|
84
|
-
//
|
|
85
|
-
|
|
86
|
-
// For use with horizontal and inline forms, when you need the label (or legend)
|
|
87
|
-
// text to align with the form controls.
|
|
88
|
-
.col-form-label {
|
|
89
|
-
padding-top: add($input-padding-y, $input-border-width);
|
|
90
|
-
padding-bottom: add($input-padding-y, $input-border-width);
|
|
91
|
-
margin-bottom: 0; // Override the `<label>/<legend>` default
|
|
92
|
-
@include font-size(inherit); // Override the `<legend>` default
|
|
93
|
-
line-height: $input-line-height;
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
.col-form-label-lg {
|
|
97
|
-
padding-top: add($input-padding-y-lg, $input-border-width);
|
|
98
|
-
padding-bottom: add($input-padding-y-lg, $input-border-width);
|
|
99
|
-
@include font-size($input-font-size-lg);
|
|
100
|
-
line-height: $input-line-height-lg;
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
.col-form-label-sm {
|
|
104
|
-
padding-top: add($input-padding-y-sm, $input-border-width);
|
|
105
|
-
padding-bottom: add($input-padding-y-sm, $input-border-width);
|
|
106
|
-
@include font-size($input-font-size-sm);
|
|
107
|
-
line-height: $input-line-height-sm;
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
// Readonly controls as plain text
|
|
112
|
-
//
|
|
113
|
-
// Apply class to a readonly input to make it appear like regular plain
|
|
114
|
-
// text (without any border, background color, focus indicator)
|
|
115
|
-
|
|
116
|
-
.form-control-plaintext {
|
|
117
|
-
display: block;
|
|
118
|
-
width: 100%;
|
|
119
|
-
padding: $input-padding-y 0;
|
|
120
|
-
margin-bottom: 0; // match inputs if this class comes on inputs with default margins
|
|
121
|
-
@include font-size($input-font-size);
|
|
122
|
-
line-height: $input-line-height;
|
|
123
|
-
color: $input-plaintext-color;
|
|
124
|
-
background-color: transparent;
|
|
125
|
-
border: solid transparent;
|
|
126
|
-
border-width: $input-border-width 0;
|
|
127
|
-
|
|
128
|
-
&.form-control-sm,
|
|
129
|
-
&.form-control-lg {
|
|
130
|
-
padding-right: 0;
|
|
131
|
-
padding-left: 0;
|
|
132
|
-
}
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
// Form control sizing
|
|
137
|
-
//
|
|
138
|
-
// Build on `.form-control` with modifier classes to decrease or increase the
|
|
139
|
-
// height and font-size of form controls.
|
|
140
|
-
//
|
|
141
|
-
// Repeated in `_input_group.scss` to avoid Sass extend issues.
|
|
142
|
-
|
|
143
|
-
.form-control-sm {
|
|
144
|
-
height: $input-height-sm;
|
|
145
|
-
padding: $input-padding-y-sm $input-padding-x-sm;
|
|
146
|
-
@include font-size($input-font-size-sm);
|
|
147
|
-
line-height: $input-line-height-sm;
|
|
148
|
-
@include border-radius($input-border-radius-sm);
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
.form-control-lg {
|
|
152
|
-
height: $input-height-lg;
|
|
153
|
-
padding: $input-padding-y-lg $input-padding-x-lg;
|
|
154
|
-
@include font-size($input-font-size-lg);
|
|
155
|
-
line-height: $input-line-height-lg;
|
|
156
|
-
@include border-radius($input-border-radius-lg);
|
|
157
|
-
}
|
|
158
|
-
|
|
159
|
-
// stylelint-disable-next-line no-duplicate-selectors
|
|
160
|
-
select.form-control {
|
|
161
|
-
&[size],
|
|
162
|
-
&[multiple] {
|
|
163
|
-
height: auto;
|
|
164
|
-
}
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
textarea.form-control {
|
|
168
|
-
height: auto;
|
|
169
|
-
}
|
|
170
|
-
|
|
171
|
-
// Form groups
|
|
172
|
-
//
|
|
173
|
-
// Designed to help with the organization and spacing of vertical forms. For
|
|
174
|
-
// horizontal forms, use the predefined grid classes.
|
|
175
|
-
|
|
176
|
-
.form-group {
|
|
177
|
-
margin-bottom: $form-group-margin-bottom;
|
|
178
|
-
}
|
|
179
|
-
|
|
180
|
-
.form-text {
|
|
181
|
-
display: block;
|
|
182
|
-
margin-top: $form-text-margin-top;
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
// Form grid
|
|
187
|
-
//
|
|
188
|
-
// Special replacement for our grid system's `.row` for tighter form layouts.
|
|
189
|
-
|
|
190
|
-
.form-row {
|
|
191
|
-
display: flex;
|
|
192
|
-
flex-wrap: wrap;
|
|
193
|
-
margin-right: -$form-grid-gutter-width / 2;
|
|
194
|
-
margin-left: -$form-grid-gutter-width / 2;
|
|
195
|
-
|
|
196
|
-
> .col,
|
|
197
|
-
> [class*="col-"] {
|
|
198
|
-
padding-right: $form-grid-gutter-width / 2;
|
|
199
|
-
padding-left: $form-grid-gutter-width / 2;
|
|
200
|
-
}
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
// Checkboxes and radios
|
|
205
|
-
//
|
|
206
|
-
// Indent the labels to position radios/checkboxes as hanging controls.
|
|
207
|
-
|
|
208
|
-
.form-check {
|
|
209
|
-
position: relative;
|
|
210
|
-
display: block;
|
|
211
|
-
padding-left: $form-check-input-gutter;
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
.form-check-input {
|
|
215
|
-
position: absolute;
|
|
216
|
-
margin-top: $form-check-input-margin-y;
|
|
217
|
-
margin-left: -$form-check-input-gutter;
|
|
218
|
-
|
|
219
|
-
// Use [disabled] and :disabled for workaround https://github.com/twbs/bootstrap/issues/28247
|
|
220
|
-
&[disabled] ~ .form-check-label,
|
|
221
|
-
&:disabled ~ .form-check-label {
|
|
222
|
-
color: $text-muted;
|
|
223
|
-
}
|
|
224
|
-
}
|
|
225
|
-
|
|
226
|
-
.form-check-label {
|
|
227
|
-
margin-bottom: 0; // Override default `<label>` bottom margin
|
|
228
|
-
}
|
|
229
|
-
|
|
230
|
-
.form-check-inline {
|
|
231
|
-
display: inline-flex;
|
|
232
|
-
align-items: center;
|
|
233
|
-
padding-left: 0; // Override base .form-check
|
|
234
|
-
margin-right: $form-check-inline-margin-x;
|
|
235
|
-
|
|
236
|
-
// Undo .form-check-input defaults and add some `margin-right`.
|
|
237
|
-
.form-check-input {
|
|
238
|
-
position: static;
|
|
239
|
-
margin-top: 0;
|
|
240
|
-
margin-right: $form-check-inline-input-margin-x;
|
|
241
|
-
margin-left: 0;
|
|
242
|
-
}
|
|
243
|
-
}
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
// Form validation
|
|
247
|
-
//
|
|
248
|
-
// Provide feedback to users when form field values are valid or invalid. Works
|
|
249
|
-
// primarily for client-side validation via scoped `:invalid` and `:valid`
|
|
250
|
-
// pseudo-classes but also includes `.is-invalid` and `.is-valid` classes for
|
|
251
|
-
// server side validation.
|
|
252
|
-
|
|
253
|
-
@each $state, $data in $form-validation-states {
|
|
254
|
-
@include form-validation-state($state, map-get($data, color), map-get($data, icon));
|
|
255
|
-
}
|
|
256
|
-
|
|
257
|
-
// Inline forms
|
|
258
|
-
//
|
|
259
|
-
// Make forms appear inline(-block) by adding the `.form-inline` class. Inline
|
|
260
|
-
// forms begin stacked on extra small (mobile) devices and then go inline when
|
|
261
|
-
// viewports reach <768px.
|
|
262
|
-
//
|
|
263
|
-
// Requires wrapping inputs and labels with `.form-group` for proper display of
|
|
264
|
-
// default HTML form controls and our custom form controls (e.g., input groups).
|
|
265
|
-
|
|
266
|
-
.form-inline {
|
|
267
|
-
display: flex;
|
|
268
|
-
flex-flow: row wrap;
|
|
269
|
-
align-items: center; // Prevent shorter elements from growing to same height as others (e.g., small buttons growing to normal sized button height)
|
|
270
|
-
|
|
271
|
-
// Because we use flex, the initial sizing of checkboxes is collapsed and
|
|
272
|
-
// doesn't occupy the full-width (which is what we want for xs grid tier),
|
|
273
|
-
// so we force that here.
|
|
274
|
-
.form-check {
|
|
275
|
-
width: 100%;
|
|
276
|
-
}
|
|
277
|
-
|
|
278
|
-
// Kick in the inline
|
|
279
|
-
@include media-breakpoint-up(sm) {
|
|
280
|
-
label {
|
|
281
|
-
display: flex;
|
|
282
|
-
align-items: center;
|
|
283
|
-
justify-content: center;
|
|
284
|
-
margin-bottom: 0;
|
|
285
|
-
}
|
|
286
|
-
|
|
287
|
-
// Inline-block all the things for "inline"
|
|
288
|
-
.form-group {
|
|
289
|
-
display: flex;
|
|
290
|
-
flex: 0 0 auto;
|
|
291
|
-
flex-flow: row wrap;
|
|
292
|
-
align-items: center;
|
|
293
|
-
margin-bottom: 0;
|
|
294
|
-
}
|
|
295
|
-
|
|
296
|
-
// Allow folks to *not* use `.form-group`
|
|
297
|
-
.form-control {
|
|
298
|
-
display: inline-block;
|
|
299
|
-
width: auto; // Prevent labels from stacking above inputs in `.form-group`
|
|
300
|
-
vertical-align: middle;
|
|
301
|
-
}
|
|
302
|
-
|
|
303
|
-
// Make static controls behave like regular ones
|
|
304
|
-
.form-control-plaintext {
|
|
305
|
-
display: inline-block;
|
|
306
|
-
}
|
|
307
|
-
|
|
308
|
-
.input-group,
|
|
309
|
-
.custom-select {
|
|
310
|
-
width: auto;
|
|
311
|
-
}
|
|
312
|
-
|
|
313
|
-
// Remove default margin on radios/checkboxes that were used for stacking, and
|
|
314
|
-
// then undo the floating of radios and checkboxes to match.
|
|
315
|
-
.form-check {
|
|
316
|
-
display: flex;
|
|
317
|
-
align-items: center;
|
|
318
|
-
justify-content: center;
|
|
319
|
-
width: auto;
|
|
320
|
-
padding-left: 0;
|
|
321
|
-
}
|
|
322
|
-
.form-check-input {
|
|
323
|
-
position: relative;
|
|
324
|
-
flex-shrink: 0;
|
|
325
|
-
margin-top: 0;
|
|
326
|
-
margin-right: $form-check-input-margin-x;
|
|
327
|
-
margin-left: 0;
|
|
328
|
-
}
|
|
329
|
-
|
|
330
|
-
.custom-control {
|
|
331
|
-
align-items: center;
|
|
332
|
-
justify-content: center;
|
|
333
|
-
}
|
|
334
|
-
.custom-control-label {
|
|
335
|
-
margin-bottom: 0;
|
|
336
|
-
}
|
|
337
|
-
}
|
|
338
|
-
}
|
|
1
|
+
@import "forms/labels";
|
|
2
|
+
@import "forms/form-text";
|
|
3
|
+
@import "forms/form-control";
|
|
4
|
+
@import "forms/form-select";
|
|
5
|
+
@import "forms/form-check";
|
|
6
|
+
@import "forms/form-range";
|
|
7
|
+
@import "forms/floating-labels";
|
|
8
|
+
@import "forms/input-group";
|
|
9
|
+
@import "forms/validation";
|