bootstrap 4.0.0.beta3 → 4.6.2

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.
Files changed (114) hide show
  1. checksums.yaml +5 -5
  2. data/.travis.yml +15 -1
  3. data/CHANGELOG.md +2 -2
  4. data/README.md +2 -2
  5. data/Rakefile +4 -2
  6. data/assets/javascripts/bootstrap/alert.js +79 -68
  7. data/assets/javascripts/bootstrap/button.js +140 -78
  8. data/assets/javascripts/bootstrap/carousel.js +294 -158
  9. data/assets/javascripts/bootstrap/collapse.js +157 -133
  10. data/assets/javascripts/bootstrap/dropdown.js +257 -167
  11. data/assets/javascripts/bootstrap/modal.js +285 -204
  12. data/assets/javascripts/bootstrap/popover.js +101 -60
  13. data/assets/javascripts/bootstrap/scrollspy.js +127 -106
  14. data/assets/javascripts/bootstrap/tab.js +113 -101
  15. data/assets/javascripts/bootstrap/toast.js +267 -0
  16. data/assets/javascripts/bootstrap/tooltip.js +406 -188
  17. data/assets/javascripts/bootstrap/util.js +106 -55
  18. data/assets/javascripts/bootstrap-sprockets.js +1 -0
  19. data/assets/javascripts/bootstrap.js +1946 -1482
  20. data/assets/javascripts/bootstrap.min.js +4 -4
  21. data/assets/stylesheets/_bootstrap-grid.scss +7 -12
  22. data/assets/stylesheets/_bootstrap-reboot.scss +4 -4
  23. data/assets/stylesheets/_bootstrap.scss +6 -4
  24. data/assets/stylesheets/bootstrap/_alert.scss +3 -2
  25. data/assets/stylesheets/bootstrap/_badge.scss +8 -1
  26. data/assets/stylesheets/bootstrap/_breadcrumb.scss +10 -6
  27. data/assets/stylesheets/bootstrap/_button-group.scss +17 -20
  28. data/assets/stylesheets/bootstrap/_buttons.scss +23 -28
  29. data/assets/stylesheets/bootstrap/_card.scss +77 -61
  30. data/assets/stylesheets/bootstrap/_carousel.scss +72 -63
  31. data/assets/stylesheets/bootstrap/_close.scss +15 -9
  32. data/assets/stylesheets/bootstrap/_code.scss +6 -14
  33. data/assets/stylesheets/bootstrap/_custom-forms.scss +287 -43
  34. data/assets/stylesheets/bootstrap/_dropdown.scss +70 -9
  35. data/assets/stylesheets/bootstrap/_forms.scss +56 -42
  36. data/assets/stylesheets/bootstrap/_functions.scss +117 -13
  37. data/assets/stylesheets/bootstrap/_grid.scss +32 -11
  38. data/assets/stylesheets/bootstrap/_images.scss +4 -4
  39. data/assets/stylesheets/bootstrap/_input-group.scss +80 -25
  40. data/assets/stylesheets/bootstrap/_jumbotron.scss +2 -1
  41. data/assets/stylesheets/bootstrap/_list-group.scss +63 -24
  42. data/assets/stylesheets/bootstrap/_mixins.scss +9 -4
  43. data/assets/stylesheets/bootstrap/_modal.scss +96 -24
  44. data/assets/stylesheets/bootstrap/_nav.scss +14 -7
  45. data/assets/stylesheets/bootstrap/_navbar.scss +66 -45
  46. data/assets/stylesheets/bootstrap/_pagination.scss +10 -8
  47. data/assets/stylesheets/bootstrap/_popover.scss +56 -69
  48. data/assets/stylesheets/bootstrap/_print.scss +41 -19
  49. data/assets/stylesheets/bootstrap/_progress.scss +20 -6
  50. data/assets/stylesheets/bootstrap/_reboot.scss +88 -109
  51. data/assets/stylesheets/bootstrap/_spinners.scss +65 -0
  52. data/assets/stylesheets/bootstrap/_tables.scss +19 -14
  53. data/assets/stylesheets/bootstrap/_toasts.scss +46 -0
  54. data/assets/stylesheets/bootstrap/_tooltip.scss +6 -6
  55. data/assets/stylesheets/bootstrap/_transitions.scss +10 -20
  56. data/assets/stylesheets/bootstrap/_type.scss +19 -19
  57. data/assets/stylesheets/bootstrap/_utilities.scss +4 -0
  58. data/assets/stylesheets/bootstrap/_variables.scss +492 -215
  59. data/assets/stylesheets/bootstrap/mixins/_background-variant.scss +5 -3
  60. data/assets/stylesheets/bootstrap/mixins/_badge.scss +8 -3
  61. data/assets/stylesheets/bootstrap/mixins/_border-radius.scss +51 -10
  62. data/assets/stylesheets/bootstrap/mixins/_box-shadow.scss +16 -1
  63. data/assets/stylesheets/bootstrap/mixins/_breakpoints.scss +11 -9
  64. data/assets/stylesheets/bootstrap/mixins/_buttons.scss +35 -26
  65. data/assets/stylesheets/bootstrap/mixins/_caret.scss +13 -16
  66. data/assets/stylesheets/bootstrap/mixins/_deprecate.scss +10 -0
  67. data/assets/stylesheets/bootstrap/mixins/_float.scss +6 -3
  68. data/assets/stylesheets/bootstrap/mixins/_forms.scss +102 -40
  69. data/assets/stylesheets/bootstrap/mixins/_gradients.scss +7 -7
  70. data/assets/stylesheets/bootstrap/mixins/_grid-framework.scss +36 -25
  71. data/assets/stylesheets/bootstrap/mixins/_grid.scss +34 -17
  72. data/assets/stylesheets/bootstrap/mixins/_hover.scss +27 -51
  73. data/assets/stylesheets/bootstrap/mixins/_image.scss +4 -4
  74. data/assets/stylesheets/bootstrap/mixins/_list-group.scss +10 -13
  75. data/assets/stylesheets/bootstrap/mixins/_lists.scss +1 -1
  76. data/assets/stylesheets/bootstrap/mixins/_nav-divider.scss +3 -2
  77. data/assets/stylesheets/bootstrap/mixins/_pagination.scss +1 -1
  78. data/assets/stylesheets/bootstrap/mixins/_reset-text.scss +3 -3
  79. data/assets/stylesheets/bootstrap/mixins/_screen-reader.scss +5 -6
  80. data/assets/stylesheets/bootstrap/mixins/_size.scss +1 -0
  81. data/assets/stylesheets/bootstrap/mixins/_table-row.scss +11 -2
  82. data/assets/stylesheets/bootstrap/mixins/_text-emphasis.scss +7 -4
  83. data/assets/stylesheets/bootstrap/mixins/_text-hide.scss +3 -1
  84. data/assets/stylesheets/bootstrap/mixins/_transition.scss +20 -3
  85. data/assets/stylesheets/bootstrap/mixins/_visibility.scss +1 -0
  86. data/assets/stylesheets/bootstrap/utilities/_background.scss +2 -2
  87. data/assets/stylesheets/bootstrap/utilities/_borders.scss +23 -2
  88. data/assets/stylesheets/bootstrap/utilities/_display.scss +6 -36
  89. data/assets/stylesheets/bootstrap/utilities/_embed.scss +7 -20
  90. data/assets/stylesheets/bootstrap/utilities/_flex.scss +5 -0
  91. data/assets/stylesheets/bootstrap/utilities/_float.scss +5 -3
  92. data/assets/stylesheets/bootstrap/utilities/_interactions.scss +5 -0
  93. data/assets/stylesheets/bootstrap/utilities/_overflow.scss +5 -0
  94. data/assets/stylesheets/bootstrap/utilities/_position.scss +0 -4
  95. data/assets/stylesheets/bootstrap/utilities/_shadows.scss +6 -0
  96. data/assets/stylesheets/bootstrap/utilities/_sizing.scss +8 -0
  97. data/assets/stylesheets/bootstrap/utilities/_spacing.scss +23 -1
  98. data/assets/stylesheets/bootstrap/utilities/_stretched-link.scss +19 -0
  99. data/assets/stylesheets/bootstrap/utilities/_text.scss +28 -8
  100. data/assets/stylesheets/bootstrap/utilities/_visibility.scss +4 -2
  101. data/assets/stylesheets/bootstrap/vendor/_rfs.scss +228 -0
  102. data/bootstrap.gemspec +7 -4
  103. data/lib/bootstrap/engine.rb +3 -0
  104. data/lib/bootstrap/version.rb +4 -2
  105. data/lib/bootstrap.rb +10 -7
  106. data/tasks/updater/js.rb +18 -6
  107. data/tasks/updater/network.rb +8 -2
  108. data/test/dummy_rails/app/assets/config/manifest.js +3 -0
  109. data/test/dummy_rails/app/assets/stylesheets/.browserslistrc +1 -0
  110. data/test/gemfiles/rails_6_0.gemfile +7 -0
  111. data/test/support/dummy_rails_integration.rb +3 -1
  112. data/test/test_helper.rb +21 -15
  113. metadata +29 -16
  114. data/assets/stylesheets/bootstrap/mixins/_navbar-align.scss +0 -10
@@ -24,14 +24,24 @@
24
24
  padding: $navbar-padding-y $navbar-padding-x;
25
25
 
26
26
  // Because flex properties aren't inherited, we need to redeclare these first
27
- // few properities so that content nested within behave properly.
28
- > .container,
29
- > .container-fluid {
27
+ // few properties so that content nested within behave properly.
28
+ %container-flex-properties {
30
29
  display: flex;
31
30
  flex-wrap: wrap;
32
31
  align-items: center;
33
32
  justify-content: space-between;
34
33
  }
34
+
35
+ .container,
36
+ .container-fluid {
37
+ @extend %container-flex-properties;
38
+ }
39
+
40
+ @each $breakpoint, $container-max-width in $container-max-widths {
41
+ > .container#{breakpoint-infix($breakpoint, $container-max-widths)} {
42
+ @extend %container-flex-properties;
43
+ }
44
+ }
35
45
  }
36
46
 
37
47
 
@@ -44,11 +54,11 @@
44
54
  padding-top: $navbar-brand-padding-y;
45
55
  padding-bottom: $navbar-brand-padding-y;
46
56
  margin-right: $navbar-padding-x;
47
- font-size: $navbar-brand-font-size;
57
+ @include font-size($navbar-brand-font-size);
48
58
  line-height: inherit;
49
59
  white-space: nowrap;
50
60
 
51
- @include hover-focus {
61
+ @include hover-focus() {
52
62
  text-decoration: none;
53
63
  }
54
64
  }
@@ -94,7 +104,7 @@
94
104
  // Powered by the collapse Bootstrap JavaScript plugin.
95
105
 
96
106
  // When collapsed, prevent the toggleable navbar contents from appearing in
97
- // the default flexbox row orienation. Requires the use of `flex-wrap: wrap`
107
+ // the default flexbox row orientation. Requires the use of `flex-wrap: wrap`
98
108
  // on the `.navbar` parent.
99
109
  .navbar-collapse {
100
110
  flex-basis: 100%;
@@ -107,20 +117,15 @@
107
117
  // Button for toggling the navbar when in its collapsed state
108
118
  .navbar-toggler {
109
119
  padding: $navbar-toggler-padding-y $navbar-toggler-padding-x;
110
- font-size: $navbar-toggler-font-size;
120
+ @include font-size($navbar-toggler-font-size);
111
121
  line-height: 1;
112
122
  background-color: transparent; // remove default button style
113
123
  border: $border-width solid transparent; // remove default button style
114
124
  @include border-radius($navbar-toggler-border-radius);
115
125
 
116
- @include hover-focus {
126
+ @include hover-focus() {
117
127
  text-decoration: none;
118
128
  }
119
-
120
- // Opinionated: add "hand" cursor to non-disabled .navbar-toggler elements
121
- &:not([disabled]):not(.disabled) {
122
- cursor: pointer;
123
- }
124
129
  }
125
130
 
126
131
  // Keep as a separate element so folks can easily override it with another icon
@@ -131,8 +136,12 @@
131
136
  height: 1.5em;
132
137
  vertical-align: middle;
133
138
  content: "";
134
- background: no-repeat center center;
135
- background-size: 100% 100%;
139
+ background: 50% / 100% 100% no-repeat;
140
+ }
141
+
142
+ .navbar-nav-scroll {
143
+ max-height: $navbar-nav-scroll-max-height;
144
+ overflow-y: auto;
136
145
  }
137
146
 
138
147
  // Generate series of `.navbar-expand-*` responsive classes for configuring
@@ -144,11 +153,21 @@
144
153
 
145
154
  &#{$infix} {
146
155
  @include media-breakpoint-down($breakpoint) {
147
- > .container,
148
- > .container-fluid {
156
+ %container-navbar-expand-#{$breakpoint} {
149
157
  padding-right: 0;
150
158
  padding-left: 0;
151
159
  }
160
+
161
+ > .container,
162
+ > .container-fluid {
163
+ @extend %container-navbar-expand-#{$breakpoint};
164
+ }
165
+
166
+ @each $size, $container-max-width in $container-max-widths {
167
+ > .container#{breakpoint-infix($size, $container-max-widths)} {
168
+ @extend %container-navbar-expand-#{$breakpoint};
169
+ }
170
+ }
152
171
  }
153
172
 
154
173
  @include media-breakpoint-up($next) {
@@ -162,25 +181,34 @@
162
181
  position: absolute;
163
182
  }
164
183
 
165
- .dropdown-menu-right {
166
- right: 0;
167
- left: auto; // Reset the default from `.dropdown-menu`
168
- }
169
-
170
184
  .nav-link {
171
- padding-right: .5rem;
172
- padding-left: .5rem;
185
+ padding-right: $navbar-nav-link-padding-x;
186
+ padding-left: $navbar-nav-link-padding-x;
173
187
  }
174
188
  }
175
189
 
176
190
  // For nesting containers, have to redeclare for alignment purposes
191
+ %container-nesting-#{$breakpoint} {
192
+ flex-wrap: nowrap;
193
+ }
194
+
177
195
  > .container,
178
196
  > .container-fluid {
179
- flex-wrap: nowrap;
197
+ @extend %container-nesting-#{$breakpoint};
198
+ }
199
+
200
+ @each $size, $container-max-width in $container-max-widths {
201
+ > .container#{breakpoint-infix($size, $container-max-widths)} {
202
+ @extend %container-nesting-#{$breakpoint};
203
+ }
204
+ }
205
+
206
+ .navbar-nav-scroll {
207
+ overflow: visible;
180
208
  }
181
209
 
182
210
  .navbar-collapse {
183
- display: flex !important; // stylelint-disable-line declaration-no-important
211
+ display: flex !important; // stylelint-disable-line declaration-no-important
184
212
 
185
213
  // Changes flex-bases to auto because of an IE10 bug
186
214
  flex-basis: auto;
@@ -189,13 +217,6 @@
189
217
  .navbar-toggler {
190
218
  display: none;
191
219
  }
192
-
193
- .dropup {
194
- .dropdown-menu {
195
- top: auto;
196
- bottom: 100%;
197
- }
198
- }
199
220
  }
200
221
  }
201
222
  }
@@ -209,10 +230,10 @@
209
230
  // Dark links against a light background
210
231
  .navbar-light {
211
232
  .navbar-brand {
212
- color: $navbar-light-active-color;
233
+ color: $navbar-light-brand-color;
213
234
 
214
- @include hover-focus {
215
- color: $navbar-light-active-color;
235
+ @include hover-focus() {
236
+ color: $navbar-light-brand-hover-color;
216
237
  }
217
238
  }
218
239
 
@@ -220,7 +241,7 @@
220
241
  .nav-link {
221
242
  color: $navbar-light-color;
222
243
 
223
- @include hover-focus {
244
+ @include hover-focus() {
224
245
  color: $navbar-light-hover-color;
225
246
  }
226
247
 
@@ -243,7 +264,7 @@
243
264
  }
244
265
 
245
266
  .navbar-toggler-icon {
246
- background-image: $navbar-light-toggler-icon-bg;
267
+ background-image: escape-svg($navbar-light-toggler-icon-bg);
247
268
  }
248
269
 
249
270
  .navbar-text {
@@ -251,7 +272,7 @@
251
272
  a {
252
273
  color: $navbar-light-active-color;
253
274
 
254
- @include hover-focus {
275
+ @include hover-focus() {
255
276
  color: $navbar-light-active-color;
256
277
  }
257
278
  }
@@ -261,10 +282,10 @@
261
282
  // White links against a dark background
262
283
  .navbar-dark {
263
284
  .navbar-brand {
264
- color: $navbar-dark-active-color;
285
+ color: $navbar-dark-brand-color;
265
286
 
266
- @include hover-focus {
267
- color: $navbar-dark-active-color;
287
+ @include hover-focus() {
288
+ color: $navbar-dark-brand-hover-color;
268
289
  }
269
290
  }
270
291
 
@@ -272,7 +293,7 @@
272
293
  .nav-link {
273
294
  color: $navbar-dark-color;
274
295
 
275
- @include hover-focus {
296
+ @include hover-focus() {
276
297
  color: $navbar-dark-hover-color;
277
298
  }
278
299
 
@@ -295,7 +316,7 @@
295
316
  }
296
317
 
297
318
  .navbar-toggler-icon {
298
- background-image: $navbar-dark-toggler-icon-bg;
319
+ background-image: escape-svg($navbar-dark-toggler-icon-bg);
299
320
  }
300
321
 
301
322
  .navbar-text {
@@ -303,7 +324,7 @@
303
324
  a {
304
325
  color: $navbar-dark-active-color;
305
326
 
306
- @include hover-focus {
327
+ @include hover-focus() {
307
328
  color: $navbar-dark-active-color;
308
329
  }
309
330
  }
@@ -11,20 +11,22 @@
11
11
  margin-left: -$pagination-border-width;
12
12
  line-height: $pagination-line-height;
13
13
  color: $pagination-color;
14
+ text-decoration: if($link-decoration == none, null, none);
14
15
  background-color: $pagination-bg;
15
16
  border: $pagination-border-width solid $pagination-border-color;
16
17
 
17
- @include hover-focus {
18
+ &:hover {
19
+ z-index: 2;
18
20
  color: $pagination-hover-color;
19
21
  text-decoration: none;
20
22
  background-color: $pagination-hover-bg;
21
23
  border-color: $pagination-hover-border-color;
22
24
  }
23
25
 
24
-
25
- // Opinionated: add "hand" cursor to non-disabled .page-link elements
26
- &:not([disabled]):not(.disabled) {
27
- cursor: pointer;
26
+ &:focus {
27
+ z-index: 3;
28
+ outline: $pagination-focus-outline;
29
+ box-shadow: $pagination-focus-box-shadow;
28
30
  }
29
31
  }
30
32
 
@@ -42,7 +44,7 @@
42
44
  }
43
45
 
44
46
  &.active .page-link {
45
- z-index: 1;
47
+ z-index: 3;
46
48
  color: $pagination-active-color;
47
49
  background-color: $pagination-active-bg;
48
50
  border-color: $pagination-active-border-color;
@@ -64,9 +66,9 @@
64
66
  //
65
67
 
66
68
  .pagination-lg {
67
- @include pagination-size($pagination-padding-y-lg, $pagination-padding-x-lg, $font-size-lg, $line-height-lg, $border-radius-lg);
69
+ @include pagination-size($pagination-padding-y-lg, $pagination-padding-x-lg, $font-size-lg, $line-height-lg, $pagination-border-radius-lg);
68
70
  }
69
71
 
70
72
  .pagination-sm {
71
- @include pagination-size($pagination-padding-y-sm, $pagination-padding-x-sm, $font-size-sm, $line-height-sm, $border-radius-sm);
73
+ @include pagination-size($pagination-padding-y-sm, $pagination-padding-x-sm, $font-size-sm, $line-height-sm, $pagination-border-radius-sm);
72
74
  }
@@ -8,13 +8,13 @@
8
8
  // Our parent element can be arbitrary since tooltips are by default inserted as a sibling of their target element.
9
9
  // So reset our font and text properties to avoid inheriting weird values.
10
10
  @include reset-text();
11
- font-size: $font-size-sm;
11
+ @include font-size($popover-font-size);
12
12
  // Allow breaking very long words so they don't overflow the popover's bounds
13
13
  word-wrap: break-word;
14
14
  background-color: $popover-bg;
15
15
  background-clip: padding-box;
16
16
  border: $popover-border-width solid $popover-border-color;
17
- @include border-radius($border-radius-lg);
17
+ @include border-radius($popover-border-radius);
18
18
  @include box-shadow($popover-box-shadow);
19
19
 
20
20
  .arrow {
@@ -22,7 +22,7 @@
22
22
  display: block;
23
23
  width: $popover-arrow-width;
24
24
  height: $popover-arrow-height;
25
- margin: 0 $border-radius-lg;
25
+ margin: 0 $popover-border-radius;
26
26
 
27
27
  &::before,
28
28
  &::after {
@@ -38,72 +38,63 @@
38
38
  .bs-popover-top {
39
39
  margin-bottom: $popover-arrow-height;
40
40
 
41
- .arrow {
42
- bottom: calc((#{$popover-arrow-height} + #{$popover-border-width}) * -1);
43
- }
41
+ > .arrow {
42
+ bottom: subtract(-$popover-arrow-height, $popover-border-width);
44
43
 
45
- .arrow::before,
46
- .arrow::after {
47
- border-width: $popover-arrow-height ($popover-arrow-width / 2) 0;
48
- }
49
-
50
- .arrow::before {
51
- bottom: 0;
52
- border-top-color: $popover-arrow-outer-color;
53
- }
44
+ &::before {
45
+ bottom: 0;
46
+ border-width: $popover-arrow-height ($popover-arrow-width * .5) 0;
47
+ border-top-color: $popover-arrow-outer-color;
48
+ }
54
49
 
55
- .arrow::after {
56
- bottom: $popover-border-width;
57
- border-top-color: $popover-arrow-color;
50
+ &::after {
51
+ bottom: $popover-border-width;
52
+ border-width: $popover-arrow-height ($popover-arrow-width * .5) 0;
53
+ border-top-color: $popover-arrow-color;
54
+ }
58
55
  }
59
56
  }
60
57
 
61
58
  .bs-popover-right {
62
59
  margin-left: $popover-arrow-height;
63
60
 
64
- .arrow {
65
- left: calc((#{$popover-arrow-height} + #{$popover-border-width}) * -1);
61
+ > .arrow {
62
+ left: subtract(-$popover-arrow-height, $popover-border-width);
66
63
  width: $popover-arrow-height;
67
64
  height: $popover-arrow-width;
68
- margin: $border-radius-lg 0; // make sure the arrow does not touch the popover's rounded corners
69
- }
70
-
71
- .arrow::before,
72
- .arrow::after {
73
- border-width: ($popover-arrow-width / 2) $popover-arrow-height ($popover-arrow-width / 2) 0;
74
- }
65
+ margin: $popover-border-radius 0; // make sure the arrow does not touch the popover's rounded corners
75
66
 
76
- .arrow::before {
77
- left: 0;
78
- border-right-color: $popover-arrow-outer-color;
79
- }
67
+ &::before {
68
+ left: 0;
69
+ border-width: ($popover-arrow-width * .5) $popover-arrow-height ($popover-arrow-width * .5) 0;
70
+ border-right-color: $popover-arrow-outer-color;
71
+ }
80
72
 
81
- .arrow::after {
82
- left: $popover-border-width;
83
- border-right-color: $popover-arrow-color;
73
+ &::after {
74
+ left: $popover-border-width;
75
+ border-width: ($popover-arrow-width * .5) $popover-arrow-height ($popover-arrow-width * .5) 0;
76
+ border-right-color: $popover-arrow-color;
77
+ }
84
78
  }
85
79
  }
86
80
 
87
81
  .bs-popover-bottom {
88
82
  margin-top: $popover-arrow-height;
89
83
 
90
- .arrow {
91
- top: calc((#{$popover-arrow-height} + #{$popover-border-width}) * -1);
92
- }
93
-
94
- .arrow::before,
95
- .arrow::after {
96
- border-width: 0 ($popover-arrow-width / 2) $popover-arrow-height ($popover-arrow-width / 2);
97
- }
84
+ > .arrow {
85
+ top: subtract(-$popover-arrow-height, $popover-border-width);
98
86
 
99
- .arrow::before {
100
- top: 0;
101
- border-bottom-color: $popover-arrow-outer-color;
102
- }
87
+ &::before {
88
+ top: 0;
89
+ border-width: 0 ($popover-arrow-width * .5) $popover-arrow-height ($popover-arrow-width * .5);
90
+ border-bottom-color: $popover-arrow-outer-color;
91
+ }
103
92
 
104
- .arrow::after {
105
- top: $popover-border-width;
106
- border-bottom-color: $popover-arrow-color;
93
+ &::after {
94
+ top: $popover-border-width;
95
+ border-width: 0 ($popover-arrow-width * .5) $popover-arrow-height ($popover-arrow-width * .5);
96
+ border-bottom-color: $popover-arrow-color;
97
+ }
107
98
  }
108
99
 
109
100
  // This will remove the popover-header's border just below the arrow
@@ -113,7 +104,7 @@
113
104
  left: 50%;
114
105
  display: block;
115
106
  width: $popover-arrow-width;
116
- margin-left: ($popover-arrow-width / -2);
107
+ margin-left: -$popover-arrow-width * .5;
117
108
  content: "";
118
109
  border-bottom: $popover-border-width solid $popover-header-bg;
119
110
  }
@@ -122,26 +113,23 @@
122
113
  .bs-popover-left {
123
114
  margin-right: $popover-arrow-height;
124
115
 
125
- .arrow {
126
- right: calc((#{$popover-arrow-height} + #{$popover-border-width}) * -1);
116
+ > .arrow {
117
+ right: subtract(-$popover-arrow-height, $popover-border-width);
127
118
  width: $popover-arrow-height;
128
119
  height: $popover-arrow-width;
129
- margin: $border-radius-lg 0; // make sure the arrow does not touch the popover's rounded corners
130
- }
131
-
132
- .arrow::before,
133
- .arrow::after {
134
- border-width: ($popover-arrow-width / 2) 0 ($popover-arrow-width / 2) $popover-arrow-height;
135
- }
120
+ margin: $popover-border-radius 0; // make sure the arrow does not touch the popover's rounded corners
136
121
 
137
- .arrow::before {
138
- right: 0;
139
- border-left-color: $popover-arrow-outer-color;
140
- }
122
+ &::before {
123
+ right: 0;
124
+ border-width: ($popover-arrow-width * .5) 0 ($popover-arrow-width * .5) $popover-arrow-height;
125
+ border-left-color: $popover-arrow-outer-color;
126
+ }
141
127
 
142
- .arrow::after {
143
- right: $popover-border-width;
144
- border-left-color: $popover-arrow-color;
128
+ &::after {
129
+ right: $popover-border-width;
130
+ border-width: ($popover-arrow-width * .5) 0 ($popover-arrow-width * .5) $popover-arrow-height;
131
+ border-left-color: $popover-arrow-color;
132
+ }
145
133
  }
146
134
  }
147
135
 
@@ -165,12 +153,11 @@
165
153
  .popover-header {
166
154
  padding: $popover-header-padding-y $popover-header-padding-x;
167
155
  margin-bottom: 0; // Reset the default from Reboot
168
- font-size: $font-size-base;
156
+ @include font-size($font-size-base);
169
157
  color: $popover-header-color;
170
158
  background-color: $popover-header-bg;
171
159
  border-bottom: $popover-border-width solid darken($popover-header-bg, 5%);
172
- $offset-border-width: calc(#{$border-radius-lg} - #{$popover-border-width});
173
- @include border-top-radius($offset-border-width);
160
+ @include border-top-radius($popover-inner-border-radius);
174
161
 
175
162
  &:empty {
176
163
  display: none;
@@ -1,11 +1,11 @@
1
1
  // stylelint-disable declaration-no-important, selector-no-qualifying-type
2
2
 
3
- // Source: https://github.com/h5bp/html5-boilerplate/blob/master/src/css/main.css
3
+ // Source: https://github.com/h5bp/main.css/blob/master/src/_print.css
4
4
 
5
5
  // ==========================================================================
6
6
  // Print styles.
7
7
  // Inlined to avoid the additional HTTP request:
8
- // http://www.phpied.com/delay-loading-your-print-css/
8
+ // https://www.phpied.com/delay-loading-your-print-css/
9
9
  // ==========================================================================
10
10
 
11
11
  @if $enable-print-styles {
@@ -14,15 +14,16 @@
14
14
  *::before,
15
15
  *::after {
16
16
  // Bootstrap specific; comment out `color` and `background`
17
- //color: #000 !important; // Black prints faster: http://www.sanbeiji.com/archives/953
17
+ //color: $black !important; // Black prints faster
18
18
  text-shadow: none !important;
19
19
  //background: transparent !important;
20
20
  box-shadow: none !important;
21
21
  }
22
22
 
23
- a,
24
- a:visited {
25
- text-decoration: underline;
23
+ a {
24
+ &:not(.btn) {
25
+ text-decoration: underline;
26
+ }
26
27
  }
27
28
 
28
29
  // Bootstrap specific; comment the following selector out
@@ -50,19 +51,10 @@
50
51
  }
51
52
  pre,
52
53
  blockquote {
53
- border: $border-width solid #999; // Bootstrap custom code; using `$border-width` instead of 1px
54
+ border: $border-width solid $gray-500; // Bootstrap custom code; using `$border-width` instead of 1px
54
55
  page-break-inside: avoid;
55
56
  }
56
57
 
57
- //
58
- // Printing Tables:
59
- // http://css-discuss.incutio.com/wiki/Printing_Tables
60
- //
61
-
62
- thead {
63
- display: table-header-group;
64
- }
65
-
66
58
  tr,
67
59
  img {
68
60
  page-break-inside: avoid;
@@ -82,12 +74,25 @@
82
74
 
83
75
  // Bootstrap specific changes start
84
76
 
77
+ // Specify a size and min-width to make printing closer across browsers.
78
+ // We don't set margin here because it breaks `size` in Chrome. We also
79
+ // don't use `!important` on `size` as it breaks in Chrome.
80
+ @page {
81
+ size: $print-page-size;
82
+ }
83
+ body {
84
+ min-width: $print-body-min-width !important;
85
+ }
86
+ .container {
87
+ min-width: $print-body-min-width !important;
88
+ }
89
+
85
90
  // Bootstrap components
86
91
  .navbar {
87
92
  display: none;
88
93
  }
89
94
  .badge {
90
- border: $border-width solid #000;
95
+ border: $border-width solid $black;
91
96
  }
92
97
 
93
98
  .table {
@@ -95,16 +100,33 @@
95
100
 
96
101
  td,
97
102
  th {
98
- background-color: #fff !important;
103
+ background-color: $white !important;
99
104
  }
100
105
  }
106
+
101
107
  .table-bordered {
102
108
  th,
103
109
  td {
104
- border: 1px solid #ddd !important;
110
+ border: 1px solid $gray-300 !important;
105
111
  }
106
112
  }
107
113
 
114
+ .table-dark {
115
+ color: inherit;
116
+
117
+ th,
118
+ td,
119
+ thead th,
120
+ tbody + tbody {
121
+ border-color: $table-border-color;
122
+ }
123
+ }
124
+
125
+ .table .thead-dark th {
126
+ color: inherit;
127
+ border-color: $table-border-color;
128
+ }
129
+
108
130
  // Bootstrap specific changes end
109
131
  }
110
132
  }
@@ -1,13 +1,17 @@
1
- @keyframes progress-bar-stripes {
2
- from { background-position: $progress-height 0; }
3
- to { background-position: 0 0; }
1
+ // Disable animation if transitions are disabled
2
+ @if $enable-transitions {
3
+ @keyframes progress-bar-stripes {
4
+ from { background-position: $progress-height 0; }
5
+ to { background-position: 0 0; }
6
+ }
4
7
  }
5
8
 
6
9
  .progress {
7
10
  display: flex;
8
11
  height: $progress-height;
9
12
  overflow: hidden; // force rounded corners by cropping it
10
- font-size: $progress-font-size;
13
+ line-height: 0;
14
+ @include font-size($progress-font-size);
11
15
  background-color: $progress-bg;
12
16
  @include border-radius($progress-border-radius);
13
17
  @include box-shadow($progress-box-shadow);
@@ -17,8 +21,10 @@
17
21
  display: flex;
18
22
  flex-direction: column;
19
23
  justify-content: center;
24
+ overflow: hidden;
20
25
  color: $progress-bar-color;
21
26
  text-align: center;
27
+ white-space: nowrap;
22
28
  background-color: $progress-bar-bg;
23
29
  @include transition($progress-bar-transition);
24
30
  }
@@ -28,6 +34,14 @@
28
34
  background-size: $progress-height $progress-height;
29
35
  }
30
36
 
31
- .progress-bar-animated {
32
- animation: progress-bar-stripes $progress-bar-animation-timing;
37
+ @if $enable-transitions {
38
+ .progress-bar-animated {
39
+ animation: $progress-bar-animation-timing progress-bar-stripes;
40
+
41
+ @if $enable-prefers-reduced-motion-media-query {
42
+ @media (prefers-reduced-motion: reduce) {
43
+ animation: none;
44
+ }
45
+ }
46
+ }
33
47
  }