@coreui/coreui 4.1.6 → 4.2.0

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 (208) hide show
  1. package/LICENSE +2 -2
  2. package/README.md +62 -10
  3. package/dist/css/bootstrap-reboot.css +488 -0
  4. package/dist/css/bootstrap-reboot.css.map +1 -0
  5. package/dist/css/bootstrap-reboot.min.css +8 -0
  6. package/dist/css/bootstrap-reboot.min.css.map +1 -0
  7. package/dist/css/coreui-grid.css +22 -4
  8. package/dist/css/coreui-grid.css.map +1 -1
  9. package/dist/css/coreui-grid.min.css +2 -2
  10. package/dist/css/coreui-grid.min.css.map +1 -1
  11. package/dist/css/coreui-grid.rtl.css +23 -5
  12. package/dist/css/coreui-grid.rtl.css.map +1 -1
  13. package/dist/css/coreui-grid.rtl.min.css +3 -3
  14. package/dist/css/coreui-grid.rtl.min.css.map +1 -1
  15. package/dist/css/coreui-reboot.css +34 -41
  16. package/dist/css/coreui-reboot.css.map +1 -1
  17. package/dist/css/coreui-reboot.min.css +2 -2
  18. package/dist/css/coreui-reboot.min.css.map +1 -1
  19. package/dist/css/coreui-reboot.rtl.css +34 -42
  20. package/dist/css/coreui-reboot.rtl.css.map +1 -1
  21. package/dist/css/coreui-reboot.rtl.min.css +3 -3
  22. package/dist/css/coreui-reboot.rtl.min.css.map +1 -1
  23. package/dist/css/coreui-utilities.css +278 -163
  24. package/dist/css/coreui-utilities.css.map +1 -1
  25. package/dist/css/coreui-utilities.min.css +2 -2
  26. package/dist/css/coreui-utilities.min.css.map +1 -1
  27. package/dist/css/coreui-utilities.rtl.css +273 -164
  28. package/dist/css/coreui-utilities.rtl.css.map +1 -1
  29. package/dist/css/coreui-utilities.rtl.min.css +3 -3
  30. package/dist/css/coreui-utilities.rtl.min.css.map +1 -1
  31. package/dist/css/coreui.css +2168 -1240
  32. package/dist/css/coreui.css.map +1 -1
  33. package/dist/css/coreui.min.css +2 -2
  34. package/dist/css/coreui.min.css.map +1 -1
  35. package/dist/css/coreui.rtl.css +2150 -1228
  36. package/dist/css/coreui.rtl.css.map +1 -1
  37. package/dist/css/coreui.rtl.min.css +3 -3
  38. package/dist/css/coreui.rtl.min.css.map +1 -1
  39. package/dist/js/coreui.bundle.js +2095 -1906
  40. package/dist/js/coreui.bundle.js.map +1 -1
  41. package/dist/js/coreui.bundle.min.js +2 -2
  42. package/dist/js/coreui.bundle.min.js.map +1 -1
  43. package/dist/js/coreui.esm.js +2098 -1909
  44. package/dist/js/coreui.esm.js.map +1 -1
  45. package/dist/js/coreui.esm.min.js +2 -2
  46. package/dist/js/coreui.esm.min.js.map +1 -1
  47. package/dist/js/coreui.js +2099 -1910
  48. package/dist/js/coreui.js.map +1 -1
  49. package/dist/js/coreui.min.js +2 -2
  50. package/dist/js/coreui.min.js.map +1 -1
  51. package/js/dist/alert.js +10 -148
  52. package/js/dist/alert.js.map +1 -1
  53. package/js/dist/base-component.js +36 -122
  54. package/js/dist/base-component.js.map +1 -1
  55. package/js/dist/button.js +9 -76
  56. package/js/dist/button.js.map +1 -1
  57. package/js/dist/carousel.js +212 -507
  58. package/js/dist/carousel.js.map +1 -1
  59. package/js/dist/collapse.js +64 -251
  60. package/js/dist/collapse.js.map +1 -1
  61. package/js/dist/dom/data.js +2 -4
  62. package/js/dist/dom/data.js.map +1 -1
  63. package/js/dist/dom/event-handler.js +82 -133
  64. package/js/dist/dom/event-handler.js.map +1 -1
  65. package/js/dist/dom/manipulator.js +22 -26
  66. package/js/dist/dom/manipulator.js.map +1 -1
  67. package/js/dist/dom/selector-engine.js +16 -81
  68. package/js/dist/dom/selector-engine.js.map +1 -1
  69. package/js/dist/dropdown.js +99 -338
  70. package/js/dist/dropdown.js.map +1 -1
  71. package/js/dist/modal.js +106 -774
  72. package/js/dist/modal.js.map +1 -1
  73. package/js/dist/navigation.js +309 -0
  74. package/js/dist/navigation.js.map +1 -0
  75. package/js/dist/offcanvas.js +88 -680
  76. package/js/dist/offcanvas.js.map +1 -1
  77. package/js/dist/popover.js +35 -120
  78. package/js/dist/popover.js.map +1 -1
  79. package/js/dist/scrollspy.js +178 -264
  80. package/js/dist/scrollspy.js.map +1 -1
  81. package/js/dist/sidebar.js +347 -0
  82. package/js/dist/sidebar.js.map +1 -0
  83. package/js/dist/tab.js +226 -216
  84. package/js/dist/tab.js.map +1 -1
  85. package/js/dist/toast.js +27 -216
  86. package/js/dist/toast.js.map +1 -1
  87. package/js/dist/tooltip.js +271 -618
  88. package/js/dist/tooltip.js.map +1 -1
  89. package/js/dist/util/backdrop.js +166 -0
  90. package/js/dist/util/backdrop.js.map +1 -0
  91. package/js/dist/util/component-functions.js +47 -0
  92. package/js/dist/util/component-functions.js.map +1 -0
  93. package/js/dist/util/config.js +80 -0
  94. package/js/dist/util/config.js.map +1 -0
  95. package/js/dist/util/focustrap.js +130 -0
  96. package/js/dist/util/focustrap.js.map +1 -0
  97. package/js/dist/util/index.js +354 -0
  98. package/js/dist/util/index.js.map +1 -0
  99. package/js/dist/util/sanitizer.js +126 -0
  100. package/js/dist/util/sanitizer.js.map +1 -0
  101. package/js/dist/util/scrollbar.js +139 -0
  102. package/js/dist/util/scrollbar.js.map +1 -0
  103. package/js/dist/util/swipe.js +156 -0
  104. package/js/dist/util/swipe.js.map +1 -0
  105. package/js/dist/util/template-factory.js +178 -0
  106. package/js/dist/util/template-factory.js.map +1 -0
  107. package/js/src/alert.js +3 -15
  108. package/js/src/base-component.js +28 -18
  109. package/js/src/button.js +3 -15
  110. package/js/src/carousel.js +203 -320
  111. package/js/src/collapse.js +61 -94
  112. package/js/src/dom/data.js +1 -3
  113. package/js/src/dom/event-handler.js +74 -107
  114. package/js/src/dom/manipulator.js +22 -31
  115. package/js/src/dom/selector-engine.js +10 -19
  116. package/js/src/dropdown.js +84 -138
  117. package/js/src/modal.js +94 -158
  118. package/js/src/navigation.js +12 -13
  119. package/js/src/offcanvas.js +71 -60
  120. package/js/src/popover.js +31 -62
  121. package/js/src/scrollspy.js +166 -171
  122. package/js/src/sidebar.js +5 -8
  123. package/js/src/tab.js +201 -110
  124. package/js/src/toast.js +19 -41
  125. package/js/src/tooltip.js +264 -374
  126. package/js/src/util/backdrop.js +55 -36
  127. package/js/src/util/component-functions.js +1 -1
  128. package/js/src/util/config.js +66 -0
  129. package/js/src/util/focustrap.js +38 -28
  130. package/js/src/util/index.js +41 -57
  131. package/js/src/util/sanitizer.js +9 -17
  132. package/js/src/util/scrollbar.js +47 -30
  133. package/js/src/util/swipe.js +146 -0
  134. package/js/src/util/template-factory.js +160 -0
  135. package/package.json +36 -36
  136. package/scss/_accordion.scss +53 -25
  137. package/scss/_alert.scss +29 -9
  138. package/scss/_badge.scss +15 -6
  139. package/scss/_breadcrumb.scss +23 -11
  140. package/scss/_button-group.scss +3 -0
  141. package/scss/_buttons.scss +71 -50
  142. package/scss/_callout.scss +18 -6
  143. package/scss/_card.scss +55 -37
  144. package/scss/_carousel.scss +6 -6
  145. package/scss/_close.scss +4 -4
  146. package/scss/_containers.scss +1 -1
  147. package/scss/_dropdown.scss +86 -64
  148. package/scss/_footer.scss +15 -5
  149. package/scss/_functions.scss +11 -24
  150. package/scss/_grid.scss +3 -3
  151. package/scss/_header.scss +59 -34
  152. package/scss/_helpers.scss +1 -0
  153. package/scss/_images.scss +3 -3
  154. package/scss/_list-group.scss +47 -29
  155. package/scss/_maps.scss +54 -0
  156. package/scss/_modal.scss +70 -43
  157. package/scss/_nav.scss +53 -20
  158. package/scss/_navbar.scss +84 -94
  159. package/scss/_offcanvas.scss +120 -60
  160. package/scss/_pagination.scss +66 -21
  161. package/scss/_popover.scss +90 -52
  162. package/scss/_progress.scss +20 -9
  163. package/scss/_reboot.scss +31 -58
  164. package/scss/_root.scss +41 -19
  165. package/scss/_spinners.scss +37 -21
  166. package/scss/_subheader.scss +9 -9
  167. package/scss/_tables.scss +34 -36
  168. package/scss/_toasts.scss +35 -19
  169. package/scss/_tooltip.scss +61 -56
  170. package/scss/_utilities.scss +42 -25
  171. package/scss/_variables.scss +169 -148
  172. package/scss/bootstrap-reboot.scss +14 -0
  173. package/scss/coreui-grid.rtl.scss +1 -1
  174. package/scss/coreui-grid.scss +2 -1
  175. package/scss/coreui-reboot.rtl.scss +1 -1
  176. package/scss/coreui-reboot.scss +1 -1
  177. package/scss/coreui-utilities.rtl.scss +1 -1
  178. package/scss/coreui-utilities.scss +2 -1
  179. package/scss/coreui.rtl.scss +1 -1
  180. package/scss/coreui.scss +2 -1
  181. package/scss/forms/_floating-labels.scss +14 -3
  182. package/scss/forms/_form-check.scss +41 -18
  183. package/scss/forms/_form-control.scss +25 -50
  184. package/scss/forms/_form-range.scss +8 -8
  185. package/scss/forms/_form-select.scss +8 -8
  186. package/scss/forms/_form-text.scss +1 -1
  187. package/scss/forms/_input-group.scss +3 -3
  188. package/scss/forms/_labels.scss +2 -2
  189. package/scss/helpers/_color-bg.scss +10 -0
  190. package/scss/helpers/_colored-links.scss +2 -2
  191. package/scss/helpers/_position.scss +7 -1
  192. package/scss/helpers/_ratio.scss +2 -2
  193. package/scss/helpers/_vr.scss +1 -0
  194. package/scss/mixins/_alert.scss +10 -10
  195. package/scss/mixins/_breakpoints.scss +8 -8
  196. package/scss/mixins/_buttons.scss +45 -47
  197. package/scss/mixins/_container.scss +4 -2
  198. package/scss/mixins/_css-vars.scss +47 -47
  199. package/scss/mixins/_forms.scss +8 -0
  200. package/scss/mixins/_gradients.scss +1 -1
  201. package/scss/mixins/_grid.scss +11 -11
  202. package/scss/mixins/_list-group.scss +7 -9
  203. package/scss/mixins/_pagination.scss +4 -25
  204. package/scss/mixins/_table-variants.scss +20 -12
  205. package/scss/mixins/_utilities.scss +8 -3
  206. package/scss/sidebar/_sidebar-narrow.scss +10 -10
  207. package/scss/sidebar/_sidebar-nav.scss +33 -32
  208. package/scss/sidebar/_sidebar.scss +110 -56
package/scss/_reboot.scss CHANGED
@@ -27,7 +27,7 @@
27
27
 
28
28
  :root {
29
29
  @if $font-size-root != null {
30
- font-size: var(--#{$variable-prefix}root-font-size);
30
+ @include font-size(var(--#{$prefix}root-font-size));
31
31
  }
32
32
 
33
33
  @if $enable-smooth-scroll {
@@ -48,13 +48,13 @@
48
48
  // scss-docs-start reboot-body-rules
49
49
  body {
50
50
  margin: 0; // 1
51
- font-family: var(--#{$variable-prefix}body-font-family);
52
- @include font-size(var(--#{$variable-prefix}body-font-size));
53
- font-weight: var(--#{$variable-prefix}body-font-weight);
54
- line-height: var(--#{$variable-prefix}body-line-height);
55
- color: var(--#{$variable-prefix}body-color);
56
- text-align: var(--#{$variable-prefix}body-text-align);
57
- background-color: var(--#{$variable-prefix}body-bg); // 2
51
+ font-family: var(--#{$prefix}body-font-family);
52
+ @include font-size(var(--#{$prefix}body-font-size));
53
+ font-weight: var(--#{$prefix}body-font-weight);
54
+ line-height: var(--#{$prefix}body-line-height);
55
+ color: var(--#{$prefix}body-color);
56
+ text-align: var(--#{$prefix}body-text-align);
57
+ background-color: var(--#{$prefix}body-bg); // 2
58
58
  -webkit-text-size-adjust: 100%; // 3
59
59
  -webkit-tap-highlight-color: rgba($black, 0); // 4
60
60
  }
@@ -64,32 +64,15 @@ body {
64
64
  // Content grouping
65
65
  //
66
66
  // 1. Reset Firefox's gray color
67
- // 2. Set correct height and prevent the `size` attribute to make the `hr` look like an input field
68
67
 
69
68
  hr {
70
69
  margin: $hr-margin-y 0;
71
- color: var(--#{$variable-prefix}hr-color, $hr-color); // 1
72
- background-color: currentColor;
70
+ color: $hr-color; // 1
73
71
  border: 0;
72
+ border-top: $hr-border-width solid $hr-border-color;
74
73
  opacity: $hr-opacity;
75
74
  }
76
75
 
77
- hr:not([size]) {
78
- height: $hr-height; // 2
79
- }
80
-
81
- .vr {
82
- display: flex;
83
- flex: 0 0 $vr-width;
84
- width: $vr-width;
85
- padding: 0 !important;
86
- margin: 0;
87
- color: var(--#{$variable-prefix}vr-color, $vr-color); // 1
88
- background-color: currentColor;
89
- border: 0;
90
- opacity: $vr-opacity;
91
- }
92
-
93
76
 
94
77
  // Typography
95
78
  //
@@ -104,7 +87,7 @@ hr:not([size]) {
104
87
  font-style: $headings-font-style;
105
88
  font-weight: $headings-font-weight;
106
89
  line-height: $headings-line-height;
107
- color: var(--#{$variable-prefix}headings-color, $headings-color);
90
+ color: var(--#{$prefix}heading-color);
108
91
  }
109
92
 
110
93
  h1 {
@@ -151,16 +134,14 @@ p {
151
134
 
152
135
  // Abbreviations
153
136
  //
154
- // 1. Duplicate behavior to the data-coreui-* attribute for our tooltip plugin
155
- // 2. Add the correct text decoration in Chrome, Edge, Opera, and Safari.
156
- // 3. Add explicit cursor to indicate changed behavior.
157
- // 4. Prevent the text-decoration to be skipped.
137
+ // 1. Add the correct text decoration in Chrome, Edge, Opera, and Safari.
138
+ // 2. Add explicit cursor to indicate changed behavior.
139
+ // 3. Prevent the text-decoration to be skipped.
158
140
 
159
- abbr[title],
160
- abbr[data-coreui-original-title] { // 1
161
- text-decoration: underline dotted; // 2
162
- cursor: help; // 3
163
- text-decoration-skip-ink: none; // 4
141
+ abbr[title] {
142
+ text-decoration: underline dotted; // 1
143
+ cursor: help; // 2
144
+ text-decoration-skip-ink: none; // 3
164
145
  }
165
146
 
166
147
 
@@ -236,7 +217,7 @@ small {
236
217
 
237
218
  mark {
238
219
  padding: $mark-padding;
239
- background-color: var(--#{$variable-prefix}mark-bg, $mark-bg);
220
+ background-color: var(--#{$prefix}highlight-bg);
240
221
  }
241
222
 
242
223
 
@@ -260,11 +241,11 @@ sup { top: -.5em; }
260
241
  // Links
261
242
 
262
243
  a {
263
- color: var(--#{$variable-prefix}link-color, $link-color);
244
+ color: var(--#{$prefix}link-color);
264
245
  text-decoration: $link-decoration;
265
246
 
266
247
  &:hover {
267
- color: var(--#{$variable-prefix}link-hover-color, $link-hover-color);
248
+ color: var(--#{$prefix}link-hover-color);
268
249
  text-decoration: $link-hover-decoration;
269
250
  }
270
251
  }
@@ -291,8 +272,6 @@ kbd,
291
272
  samp {
292
273
  font-family: $font-family-code;
293
274
  @include font-size(1em); // Correct the odd `em` font sizing in all browsers.
294
- direction: ltr #{"/* rtl:ignore */"};
295
- unicode-bidi: bidi-override;
296
275
  }
297
276
 
298
277
  // 1. Remove browser default top margin
@@ -305,7 +284,7 @@ pre {
305
284
  margin-bottom: 1rem; // 2
306
285
  overflow: auto; // 3
307
286
  @include font-size($code-font-size);
308
- color: var(--#{$variable-prefix}pre-color, $pre-color);
287
+ color: var(--#{$prefix}pre-color, $pre-color);
309
288
 
310
289
  // Account for some code outputs that place code tags in pre tags
311
290
  code {
@@ -317,7 +296,7 @@ pre {
317
296
 
318
297
  code {
319
298
  @include font-size($code-font-size);
320
- color: var(--#{$variable-prefix}code-color, $code-color);
299
+ color: var(--#{$prefix}code-color);
321
300
  word-wrap: break-word;
322
301
 
323
302
  // Streamline the style when inside anchors to avoid broken underline and more
@@ -329,8 +308,8 @@ code {
329
308
  kbd {
330
309
  padding: $kbd-padding-y $kbd-padding-x;
331
310
  @include font-size($kbd-font-size);
332
- color: var(--#{$variable-prefix}kbd-color, $kbd-color);
333
- background-color: var(--#{$variable-prefix}kbd-bg, $kbd-bg);
311
+ color: var(--#{$prefix}kbd-color, $kbd-color);
312
+ background-color: var(--#{$prefix}kbd-bg, $kbd-bg);
334
313
  @include border-radius($border-radius-sm);
335
314
 
336
315
  kbd {
@@ -370,7 +349,7 @@ table {
370
349
  caption {
371
350
  padding-top: $table-cell-padding-y;
372
351
  padding-bottom: $table-cell-padding-y;
373
- color: var(--#{$variable-prefix}table-caption-color, $table-caption-color);
352
+ color: var(--#{$prefix}table-caption-color, $table-caption-color);
374
353
  text-align: left;
375
354
  }
376
355
 
@@ -457,11 +436,11 @@ select {
457
436
  }
458
437
  }
459
438
 
460
- // Remove the dropdown arrow in Chrome from inputs built with datalists.
439
+ // Remove the dropdown arrow only from text type inputs built with datalists in Chrome.
461
440
  // See https://stackoverflow.com/a/54997118
462
441
 
463
- [list]::-webkit-calendar-picker-indicator {
464
- display: none;
442
+ [list]:not([type="date"]):not([type="datetime-local"]):not([type="month"]):not([type="week"]):not([type="time"])::-webkit-calendar-picker-indicator {
443
+ display: none !important;
465
444
  }
466
445
 
467
446
  // 1. Prevent a WebKit bug where (2) destroys native `audio` and `video`
@@ -582,16 +561,10 @@ legend {
582
561
  }
583
562
 
584
563
 
585
- // Inherit font family and line height for file input buttons
586
-
587
- ::file-selector-button {
588
- font: inherit;
589
- }
590
-
591
- // 1. Change font properties to `inherit`
564
+ // 1. Inherit font family and line height for file input buttons
592
565
  // 2. Correct the inability to style clickable types in iOS and Safari.
593
566
 
594
- ::-webkit-file-upload-button {
567
+ ::file-selector-button {
595
568
  font: inherit; // 1
596
569
  -webkit-appearance: button; // 2
597
570
  }
package/scss/_root.scss CHANGED
@@ -6,47 +6,69 @@
6
6
  // Generate palettes for full colors, grays, and theme colors.
7
7
 
8
8
  @each $color, $value in $colors {
9
- --#{$variable-prefix}#{$color}: #{$value};
9
+ --#{$prefix}#{$color}: #{$value};
10
10
  }
11
11
 
12
12
  @each $color, $value in $grays {
13
- --#{$variable-prefix}gray-#{$color}: #{$value};
13
+ --#{$prefix}gray-#{$color}: #{$value};
14
14
  }
15
15
 
16
16
  @each $color, $value in $theme-colors {
17
- --#{$variable-prefix}#{$color}: #{$value};
17
+ --#{$prefix}#{$color}: #{$value};
18
18
  }
19
19
 
20
20
  @each $color, $value in $theme-colors-rgb {
21
- --#{$variable-prefix}#{$color}-rgb: #{$value};
21
+ --#{$prefix}#{$color}-rgb: #{$value};
22
22
  }
23
23
 
24
- --#{$variable-prefix}white-rgb: #{to-rgb($white)};
25
- --#{$variable-prefix}black-rgb: #{to-rgb($black)};
26
- --#{$variable-prefix}body-color-rgb: #{to-rgb($body-color)};
27
- --#{$variable-prefix}body-bg-rgb: #{to-rgb($body-bg)};
24
+ --#{$prefix}white-rgb: #{to-rgb($white)};
25
+ --#{$prefix}black-rgb: #{to-rgb($black)};
26
+ --#{$prefix}body-color-rgb: #{to-rgb($body-color)};
27
+ --#{$prefix}body-bg-rgb: #{to-rgb($body-bg)};
28
28
 
29
29
  // Fonts
30
30
 
31
31
  // Note: Use `inspect` for lists so that quoted items keep the quotes.
32
32
  // See https://github.com/sass/sass/issues/2383#issuecomment-336349172
33
- --#{$variable-prefix}font-sans-serif: #{inspect($font-family-sans-serif)};
34
- --#{$variable-prefix}font-monospace: #{inspect($font-family-monospace)};
35
- --#{$variable-prefix}gradient: #{$gradient};
33
+ --#{$prefix}font-sans-serif: #{inspect($font-family-sans-serif)};
34
+ --#{$prefix}font-monospace: #{inspect($font-family-monospace)};
35
+ --#{$prefix}gradient: #{$gradient};
36
36
 
37
37
  // Root and body
38
38
  // scss-docs-start root-body-variables
39
39
  @if $font-size-root != null {
40
- --#{$variable-prefix}root-font-size: #{$font-size-root};
40
+ --#{$prefix}root-font-size: #{$font-size-root};
41
41
  }
42
- --#{$variable-prefix}body-font-family: #{$font-family-base};
43
- --#{$variable-prefix}body-font-size: #{$font-size-base};
44
- --#{$variable-prefix}body-font-weight: #{$font-weight-base};
45
- --#{$variable-prefix}body-line-height: #{$line-height-base};
46
- --#{$variable-prefix}body-color: #{$body-color};
42
+ --#{$prefix}body-font-family: #{$font-family-base};
43
+ @include rfs($font-size-base, --#{$prefix}body-font-size);
44
+ --#{$prefix}body-font-weight: #{$font-weight-base};
45
+ --#{$prefix}body-line-height: #{$line-height-base};
46
+ --#{$prefix}body-color: #{$body-color};
47
47
  @if $body-text-align != null {
48
- --#{$variable-prefix}body-text-align: #{$body-text-align};
48
+ --#{$prefix}body-text-align: #{$body-text-align};
49
49
  }
50
- --#{$variable-prefix}body-bg: #{$body-bg};
50
+ --#{$prefix}body-bg: #{$body-bg};
51
51
  // scss-docs-end root-body-variables
52
+
53
+ // scss-docs-start root-border-var
54
+ --#{$prefix}border-width: #{$border-width};
55
+ --#{$prefix}border-style: #{$border-style};
56
+ --#{$prefix}border-color: #{$border-color};
57
+ --#{$prefix}border-color-translucent: #{$border-color-translucent};
58
+
59
+ --#{$prefix}border-radius: #{$border-radius};
60
+ --#{$prefix}border-radius-sm: #{$border-radius-sm};
61
+ --#{$prefix}border-radius-lg: #{$border-radius-lg};
62
+ --#{$prefix}border-radius-xl: #{$border-radius-xl};
63
+ --#{$prefix}border-radius-2xl: #{$border-radius-2xl};
64
+ --#{$prefix}border-radius-pill: #{$border-radius-pill};
65
+ // scss-docs-end root-border-var
66
+
67
+ --#{$prefix}heading-color: #{$headings-color};
68
+ --#{$prefix}link-color: #{$link-color};
69
+ --#{$prefix}link-hover-color: #{$link-hover-color};
70
+
71
+ --#{$prefix}code-color: #{$code-color};
72
+
73
+ --#{$prefix}highlight-bg: #{$mark-bg};
52
74
  }
@@ -2,6 +2,17 @@
2
2
  // Rotating border
3
3
  //
4
4
 
5
+ .spinner-grow,
6
+ .spinner-border {
7
+ display: inline-block;
8
+ width: var(--#{$prefix}spinner-width);
9
+ height: var(--#{$prefix}spinner-height);
10
+ vertical-align: var(--#{$prefix}spinner-vertical-align);
11
+ // stylelint-disable-next-line property-disallowed-list
12
+ border-radius: 50%;
13
+ animation: var(--#{$prefix}spinner-animation-speed) linear infinite var(--#{$prefix}spinner-animation-name);
14
+ }
15
+
5
16
  // scss-docs-start spinner-border-keyframes
6
17
  @keyframes spinner-border {
7
18
  to { transform: rotate(360deg) #{"/* rtl:ignore */"}; }
@@ -9,21 +20,25 @@
9
20
  // scss-docs-end spinner-border-keyframes
10
21
 
11
22
  .spinner-border {
12
- display: inline-block;
13
- width: $spinner-width;
14
- height: $spinner-height;
15
- vertical-align: $spinner-vertical-align;
16
- border: $spinner-border-width solid currentColor;
23
+ // scss-docs-start spinner-border-css-vars
24
+ --#{$prefix}spinner-width: #{$spinner-width};
25
+ --#{$prefix}spinner-height: #{$spinner-height};
26
+ --#{$prefix}spinner-vertical-align: #{$spinner-vertical-align};
27
+ --#{$prefix}spinner-border-width: #{$spinner-border-width};
28
+ --#{$prefix}spinner-animation-speed: #{$spinner-animation-speed};
29
+ --#{$prefix}spinner-animation-name: spinner-border;
30
+ // scss-docs-end spinner-border-css-vars
31
+
32
+ border: var(--#{$prefix}spinner-border-width) solid currentColor;
17
33
  border-right-color: transparent;
18
- // stylelint-disable-next-line property-disallowed-list
19
- border-radius: 50%;
20
- animation: $spinner-animation-speed linear infinite spinner-border;
21
34
  }
22
35
 
23
36
  .spinner-border-sm {
24
- width: $spinner-width-sm;
25
- height: $spinner-height-sm;
26
- border-width: $spinner-border-width-sm;
37
+ // scss-docs-start spinner-border-sm-css-vars
38
+ --#{$prefix}spinner-width: #{$spinner-width-sm};
39
+ --#{$prefix}spinner-height: #{$spinner-height-sm};
40
+ --#{$prefix}spinner-border-width: #{$spinner-border-width-sm};
41
+ // scss-docs-end spinner-border-sm-css-vars
27
42
  }
28
43
 
29
44
  //
@@ -43,27 +58,28 @@
43
58
  // scss-docs-end spinner-grow-keyframes
44
59
 
45
60
  .spinner-grow {
46
- display: inline-block;
47
- width: $spinner-width;
48
- height: $spinner-height;
49
- vertical-align: $spinner-vertical-align;
61
+ // scss-docs-start spinner-grow-css-vars
62
+ --#{$prefix}spinner-width: #{$spinner-width};
63
+ --#{$prefix}spinner-height: #{$spinner-height};
64
+ --#{$prefix}spinner-vertical-align: #{$spinner-vertical-align};
65
+ --#{$prefix}spinner-animation-speed: #{$spinner-animation-speed};
66
+ --#{$prefix}spinner-animation-name: spinner-grow;
67
+ // scss-docs-end spinner-grow-css-vars
68
+
50
69
  background-color: currentColor;
51
- // stylelint-disable-next-line property-disallowed-list
52
- border-radius: 50%;
53
70
  opacity: 0;
54
- animation: $spinner-animation-speed linear infinite spinner-grow;
55
71
  }
56
72
 
57
73
  .spinner-grow-sm {
58
- width: $spinner-width-sm;
59
- height: $spinner-height-sm;
74
+ --#{$prefix}spinner-width: #{$spinner-width-sm};
75
+ --#{$prefix}spinner-height: #{$spinner-height-sm};
60
76
  }
61
77
 
62
78
  @if $enable-reduced-motion {
63
79
  @media (prefers-reduced-motion: reduce) {
64
80
  .spinner-border,
65
81
  .spinner-grow {
66
- animation-duration: $spinner-animation-speed * 2;
82
+ --#{$prefix}spinner-animation-speed: #{$spinner-animation-speed * 2};
67
83
  }
68
84
  }
69
85
  }
@@ -6,8 +6,8 @@
6
6
  justify-content: space-between; // space out brand from logo
7
7
  min-height: $subheader-min-height;
8
8
  padding: $subheader-padding-y $subheader-padding-x;
9
- background: var(--#{$variable-prefix}subheader-bg, $subheader-bg);
10
- border-bottom: var(--#{$variable-prefix}subheader-border-width, $subheader-border-width) solid var(--#{$variable-prefix}subheader-border-color, $subheader-border-color);
9
+ background: var(--#{$prefix}subheader-bg, $subheader-bg);
10
+ border-bottom: var(--#{$prefix}subheader-border-width, $subheader-border-width) solid var(--#{$prefix}subheader-border-color, $subheader-border-color);
11
11
  }
12
12
 
13
13
  .subheader-sticky {
@@ -30,21 +30,21 @@
30
30
  .nav-link {
31
31
  padding-right: $subheader-nav-link-padding-x;
32
32
  padding-left: $subheader-nav-link-padding-x;
33
- color: var(--#{$variable-prefix}subheader-color, $subheader-color);
33
+ color: var(--#{$prefix}subheader-color, $subheader-color);
34
34
 
35
35
  &:hover,
36
36
  &:focus {
37
- color: var(--#{$variable-prefix}subheader-hover-color, $subheader-hover-color);
37
+ color: var(--#{$prefix}subheader-hover-color, $subheader-hover-color);
38
38
  }
39
39
 
40
40
  &.disabled {
41
- color: var(--#{$variable-prefix}subheader-disabled-color, $subheader-disabled-color);
41
+ color: var(--#{$prefix}subheader-disabled-color, $subheader-disabled-color);
42
42
  }
43
43
  }
44
44
 
45
45
  .show > .nav-link,
46
46
  .nav-link.active {
47
- color: var(--#{$variable-prefix}subheader-active-color, $subheader-active-color);
47
+ color: var(--#{$prefix}subheader-active-color, $subheader-active-color);
48
48
  }
49
49
 
50
50
  .dropdown-menu {
@@ -59,14 +59,14 @@
59
59
  .subheader-text {
60
60
  padding-top: $nav-link-padding-y;
61
61
  padding-bottom: $nav-link-padding-y;
62
- color: var(--#{$variable-prefix}subheader-color, $subheader-color);
62
+ color: var(--#{$prefix}subheader-color, $subheader-color);
63
63
 
64
64
  a {
65
- color: var(--#{$variable-prefix}subheader-active-color, $subheader-active-color);
65
+ color: var(--#{$prefix}subheader-active-color, $subheader-active-color);
66
66
 
67
67
  &:hover,
68
68
  &:focus {
69
- color: var(--#{$variable-prefix}subheader-active-color, $subheader-active-color);
69
+ color: var(--#{$prefix}subheader-active-color, $subheader-active-color);
70
70
  }
71
71
  }
72
72
  }
package/scss/_tables.scss CHANGED
@@ -3,22 +3,22 @@
3
3
  //
4
4
 
5
5
  .table {
6
- --#{$variable-prefix}table-color: #{$table-color};
7
- --#{$variable-prefix}table-bg: #{$table-bg};
8
- --#{$variable-prefix}table-border-color: #{$table-border-color};
9
- --#{$variable-prefix}table-accent-bg: #{$table-accent-bg};
10
- --#{$variable-prefix}table-striped-color: #{$table-striped-color};
11
- --#{$variable-prefix}table-striped-bg: #{$table-striped-bg};
12
- --#{$variable-prefix}table-active-color: #{$table-active-color};
13
- --#{$variable-prefix}table-active-bg: #{$table-active-bg};
14
- --#{$variable-prefix}table-hover-color: #{$table-hover-color};
15
- --#{$variable-prefix}table-hover-bg: #{$table-hover-bg};
6
+ --#{$prefix}table-color: #{$table-color};
7
+ --#{$prefix}table-bg: #{$table-bg};
8
+ --#{$prefix}table-border-color: #{$table-border-color};
9
+ --#{$prefix}table-accent-bg: #{$table-accent-bg};
10
+ --#{$prefix}table-striped-color: #{$table-striped-color};
11
+ --#{$prefix}table-striped-bg: #{$table-striped-bg};
12
+ --#{$prefix}table-active-color: #{$table-active-color};
13
+ --#{$prefix}table-active-bg: #{$table-active-bg};
14
+ --#{$prefix}table-hover-color: #{$table-hover-color};
15
+ --#{$prefix}table-hover-bg: #{$table-hover-bg};
16
16
 
17
17
  width: 100%;
18
18
  margin-bottom: $spacer;
19
- color: var(--#{$variable-prefix}table-color);
19
+ color: var(--#{$prefix}table-color);
20
20
  vertical-align: $table-cell-vertical-align;
21
- border-color: var(--#{$variable-prefix}table-border-color);
21
+ border-color: var(--#{$prefix}table-border-color);
22
22
 
23
23
  // Target th & td
24
24
  // We need the child combinator to prevent styles leaking to nested tables which doesn't have a `.table` class.
@@ -27,11 +27,9 @@
27
27
  // stylelint-disable-next-line selector-max-universal
28
28
  > :not(caption) > * > * {
29
29
  padding: $table-cell-padding-y $table-cell-padding-x;
30
- color: var(--#{$variable-prefix}table-color);
31
- background-color: var(--#{$variable-prefix}table-bg);
32
- border-bottom-color: var(--#{$variable-prefix}table-border-color);
30
+ background-color: var(--#{$prefix}table-bg);
33
31
  border-bottom-width: $table-border-width;
34
- box-shadow: inset 0 0 0 9999px var(--#{$variable-prefix}table-accent-bg);
32
+ box-shadow: inset 0 0 0 9999px var(--#{$prefix}table-accent-bg);
35
33
  }
36
34
 
37
35
  > tbody {
@@ -41,13 +39,11 @@
41
39
  > thead {
42
40
  vertical-align: bottom;
43
41
  }
44
-
45
- // Highlight border color between thead, tbody and tfoot.
46
- // > :not(:first-child) {
47
- // border-top: (2 * $table-border-width) solid $table-group-separator-color;
48
- // }
49
42
  }
50
43
 
44
+ .table-group-divider {
45
+ border-top: ($table-border-width * 2) solid $table-group-separator-color;
46
+ }
51
47
 
52
48
  //
53
49
  // Change placement of captions with a class
@@ -105,10 +101,19 @@
105
101
  //
106
102
  // Default zebra-stripe styles (alternating gray and transparent backgrounds)
107
103
 
104
+ // For rows
108
105
  .table-striped {
109
106
  > tbody > tr:nth-of-type(#{$table-striped-order}) > * {
110
- --#{$variable-prefix}table-accent-bg: var(--#{$variable-prefix}table-striped-bg);
111
- color: var(--#{$variable-prefix}table-striped-color);
107
+ --#{$prefix}table-accent-bg: var(--#{$prefix}table-striped-bg);
108
+ color: var(--#{$prefix}table-striped-color);
109
+ }
110
+ }
111
+
112
+ // For columns
113
+ .table-striped-columns {
114
+ > :not(caption) > tr > :nth-child(#{$table-striped-columns-order}) {
115
+ --#{$prefix}table-accent-bg: var(--#{$prefix}table-striped-bg);
116
+ color: var(--#{$prefix}table-striped-color);
112
117
  }
113
118
  }
114
119
 
@@ -117,8 +122,8 @@
117
122
  // The `.table-active` class can be added to highlight rows or cells
118
123
 
119
124
  .table-active {
120
- --#{$variable-prefix}table-accent-bg: var(--#{$variable-prefix}table-active-bg);
121
- color: var(--#{$variable-prefix}table-active-color);
125
+ --#{$prefix}table-accent-bg: var(--#{$prefix}table-active-bg);
126
+ color: var(--#{$prefix}table-active-color);
122
127
  }
123
128
 
124
129
  // Hover effect
@@ -127,8 +132,8 @@
127
132
 
128
133
  .table-hover {
129
134
  > tbody > tr:hover > * {
130
- --#{$variable-prefix}table-accent-bg: var(--#{$variable-prefix}table-hover-bg);
131
- color: var(--#{$variable-prefix}table-hover-color);
135
+ --#{$prefix}table-accent-bg: var(--#{$prefix}table-hover-bg);
136
+ color: var(--#{$prefix}table-hover-color);
132
137
  }
133
138
  }
134
139
 
@@ -142,17 +147,10 @@
142
147
  // @include table-variant($color, $value);
143
148
  // }
144
149
 
145
- @each $color, $map in $table-variants {
146
- // @include table-variant($color, $value);
147
- .table-#{$color} {
148
- @include table-variant($map);
149
- }
150
+ @each $color, $value in $table-variants {
151
+ @include table-variant($color, $value);
150
152
  }
151
153
 
152
- // @each $state, $map in $list-group-variants {
153
-
154
- // }
155
-
156
154
  // Responsive tables
157
155
  //
158
156
  // Generate series of `.table-responsive-*` classes for configuring the screen
package/scss/_toasts.scss CHANGED
@@ -1,14 +1,31 @@
1
1
  .toast {
2
- width: $toast-max-width;
2
+ // scss-docs-start toast-css-vars
3
+ --#{$prefix}toast-padding-x: #{$toast-padding-x};
4
+ --#{$prefix}toast-padding-y: #{$toast-padding-y};
5
+ --#{$prefix}toast-spacing: #{$toast-spacing};
6
+ --#{$prefix}toast-max-width: #{$toast-max-width};
7
+ @include rfs($toast-font-size, --#{$prefix}toast-font-size);
8
+ --#{$prefix}toast-color: #{$toast-color};
9
+ --#{$prefix}toast-bg: #{$toast-background-color};
10
+ --#{$prefix}toast-border-width: #{$toast-border-width};
11
+ --#{$prefix}toast-border-color: #{$toast-border-color};
12
+ --#{$prefix}toast-border-radius: #{$toast-border-radius};
13
+ --#{$prefix}toast-box-shadow: #{$toast-box-shadow};
14
+ --#{$prefix}toast-header-color: #{$toast-header-color};
15
+ --#{$prefix}toast-header-bg: #{$toast-header-background-color};
16
+ --#{$prefix}toast-header-border-color: #{$toast-header-border-color};
17
+ // scss-docs-end toast-css-vars
18
+
19
+ width: var(--#{$prefix}toast-max-width);
3
20
  max-width: 100%;
4
- @include font-size($toast-font-size);
5
- color: var(--#{$variable-prefix}toast-color, $toast-color);
21
+ @include font-size(var(--#{$prefix}toast-font-size));
22
+ color: var(--#{$prefix}toast-color);
6
23
  pointer-events: auto;
7
- background-color: var(--#{$variable-prefix}toast-background-color, $toast-background-color);
24
+ background-color: var(--#{$prefix}toast-bg);
8
25
  background-clip: padding-box;
9
- border: $toast-border-width solid var(--#{$variable-prefix}toast-border-color, $toast-border-color);
10
- box-shadow: $toast-box-shadow;
11
- @include border-radius($toast-border-radius);
26
+ border: var(--#{$prefix}toast-border-width) solid var(--#{$prefix}toast-border-color);
27
+ box-shadow: var(--#{$prefix}toast-box-shadow);
28
+ @include border-radius(var(--#{$prefix}toast-border-radius));
12
29
 
13
30
  &.showing {
14
31
  opacity: 0;
@@ -20,35 +37,34 @@
20
37
  }
21
38
 
22
39
  .toast-container {
23
- z-index: $zindex-toaster;
40
+ position: absolute;
41
+ z-index: $zindex-toast;
24
42
  width: max-content;
25
43
  max-width: 100%;
26
44
  pointer-events: none;
27
45
 
28
46
  > :not(:last-child) {
29
- margin-bottom: $toast-spacing;
47
+ margin-bottom: var(--#{$prefix}toast-spacing);
30
48
  }
31
49
  }
32
50
 
33
51
  .toast-header {
34
52
  display: flex;
35
53
  align-items: center;
36
- padding: $toast-padding-y $toast-padding-x;
37
- color: var(--#{$variable-prefix}toast-header-color, $toast-header-color);
38
- background-color: var(--#{$variable-prefix}toast-header-background-color, $toast-header-background-color);
54
+ padding: var(--#{$prefix}toast-padding-y) var(--#{$prefix}toast-padding-x);
55
+ color: var(--#{$prefix}toast-header-color);
56
+ background-color: var(--#{$prefix}toast-header-bg);
39
57
  background-clip: padding-box;
40
- border-bottom: $toast-border-width solid var(--#{$variable-prefix}toast-header-border-color, $toast-header-border-color);
41
- @include border-top-radius(subtract($toast-border-radius, $toast-border-width));
58
+ border-bottom: var(--#{$prefix}toast-border-width) solid var(--#{$prefix}toast-header-border-color);
59
+ @include border-top-radius(calc(var(--#{$prefix}toast-border-radius) - var(--#{$prefix}toast-border-width)));
42
60
 
43
61
  .btn-close {
44
- @include ltr-rtl("margin-right", $toast-padding-x * -.5);
45
- @include ltr-rtl("margin-left", $toast-padding-x);
46
- // margin-right: $toast-padding-x * -.5;
47
- // margin-left: $toast-padding-x;
62
+ @include ltr-rtl("margin-right", calc(var(--#{$prefix}toast-padding-x) * -.5)); // stylelint-disable-line function-disallowed-list
63
+ @include ltr-rtl("margin-left", var(--#{$prefix}toast-padding-x));
48
64
  }
49
65
  }
50
66
 
51
67
  .toast-body {
52
- padding: $toast-padding-x; // apply to both vertical and horizontal
68
+ padding: var(--#{$prefix}toast-padding-x);
53
69
  word-wrap: break-word;
54
70
  }