@coreui/coreui 5.2.0 → 5.3.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.
- package/LICENSE +1 -1
- package/README.md +4 -4
- package/dist/css/coreui-grid.css +456 -229
- package/dist/css/coreui-grid.css.map +1 -1
- package/dist/css/coreui-grid.min.css +3 -3
- package/dist/css/coreui-grid.min.css.map +1 -1
- package/dist/css/coreui-grid.rtl.css +229 -229
- package/dist/css/coreui-grid.rtl.css.map +1 -1
- package/dist/css/coreui-grid.rtl.min.css +3 -3
- package/dist/css/coreui-grid.rtl.min.css.map +1 -1
- package/dist/css/coreui-reboot.css +56 -49
- package/dist/css/coreui-reboot.css.map +1 -1
- package/dist/css/coreui-reboot.min.css +3 -3
- package/dist/css/coreui-reboot.min.css.map +1 -1
- package/dist/css/coreui-reboot.rtl.css +54 -49
- package/dist/css/coreui-reboot.rtl.css.map +1 -1
- package/dist/css/coreui-reboot.rtl.min.css +3 -3
- package/dist/css/coreui-reboot.rtl.min.css.map +1 -1
- package/dist/css/coreui-utilities.css +531 -371
- package/dist/css/coreui-utilities.css.map +1 -1
- package/dist/css/coreui-utilities.min.css +3 -3
- package/dist/css/coreui-utilities.min.css.map +1 -1
- package/dist/css/coreui-utilities.rtl.css +353 -353
- package/dist/css/coreui-utilities.rtl.css.map +1 -1
- package/dist/css/coreui-utilities.rtl.min.css +3 -3
- package/dist/css/coreui-utilities.rtl.min.css.map +1 -1
- package/dist/css/coreui.css +1457 -1020
- package/dist/css/coreui.css.map +1 -1
- package/dist/css/coreui.min.css +3 -3
- package/dist/css/coreui.min.css.map +1 -1
- package/dist/css/coreui.rtl.css +1115 -1002
- package/dist/css/coreui.rtl.css.map +1 -1
- package/dist/css/coreui.rtl.min.css +3 -3
- package/dist/css/coreui.rtl.min.css.map +1 -1
- package/dist/css/themes/bootstrap/bootstrap.css +5195 -4350
- package/dist/css/themes/bootstrap/bootstrap.css.map +1 -1
- package/dist/css/themes/bootstrap/bootstrap.min.css +3 -7
- package/dist/css/themes/bootstrap/bootstrap.min.css.map +1 -1
- package/dist/css/themes/bootstrap/bootstrap.rtl.css +4971 -4625
- package/dist/css/themes/bootstrap/bootstrap.rtl.css.map +1 -1
- package/dist/css/themes/bootstrap/bootstrap.rtl.min.css +3 -7
- package/dist/css/themes/bootstrap/bootstrap.rtl.min.css.map +1 -1
- package/dist/js/bootstrap.bundle.js +4 -7
- package/dist/js/bootstrap.bundle.js.map +1 -1
- package/dist/js/bootstrap.bundle.min.js +3 -3
- package/dist/js/bootstrap.bundle.min.js.map +1 -1
- package/dist/js/bootstrap.esm.js +4 -5
- package/dist/js/bootstrap.esm.js.map +1 -1
- package/dist/js/bootstrap.esm.min.js +3 -3
- package/dist/js/bootstrap.esm.min.js.map +1 -1
- package/dist/js/bootstrap.js +4 -5
- package/dist/js/bootstrap.js.map +1 -1
- package/dist/js/bootstrap.min.js +3 -3
- package/dist/js/bootstrap.min.js.map +1 -1
- package/dist/js/coreui.bundle.js +4 -7
- package/dist/js/coreui.bundle.js.map +1 -1
- package/dist/js/coreui.bundle.min.js +3 -3
- package/dist/js/coreui.bundle.min.js.map +1 -1
- package/dist/js/coreui.esm.js +4 -5
- package/dist/js/coreui.esm.js.map +1 -1
- package/dist/js/coreui.esm.min.js +3 -3
- package/dist/js/coreui.esm.min.js.map +1 -1
- package/dist/js/coreui.js +4 -5
- package/dist/js/coreui.js.map +1 -1
- package/dist/js/coreui.min.js +3 -3
- package/dist/js/coreui.min.js.map +1 -1
- package/js/dist/alert.js +2 -2
- package/js/dist/base-component.js +3 -3
- package/js/dist/base-component.js.map +1 -1
- package/js/dist/button.js +2 -2
- package/js/dist/carousel.js +2 -2
- package/js/dist/collapse.js +2 -2
- package/js/dist/dom/data.js +2 -2
- package/js/dist/dom/event-handler.js +2 -2
- package/js/dist/dom/manipulator.js +2 -2
- package/js/dist/dom/selector-engine.js +2 -2
- package/js/dist/dropdown.js +2 -2
- package/js/dist/modal.js +2 -2
- package/js/dist/navigation.js +3 -3
- package/js/dist/navigation.js.map +1 -1
- package/js/dist/offcanvas.js +2 -2
- package/js/dist/popover.js +2 -2
- package/js/dist/scrollspy.js +2 -2
- package/js/dist/sidebar.js +2 -2
- package/js/dist/tab.js +2 -2
- package/js/dist/toast.js +2 -2
- package/js/dist/tooltip.js +2 -2
- package/js/dist/util/backdrop.js +2 -2
- package/js/dist/util/component-functions.js +2 -2
- package/js/dist/util/config.js +2 -2
- package/js/dist/util/focustrap.js +2 -2
- package/js/dist/util/index.js +2 -2
- package/js/dist/util/index.js.map +1 -1
- package/js/dist/util/sanitizer.js +2 -3
- package/js/dist/util/sanitizer.js.map +1 -1
- package/js/dist/util/scrollbar.js +2 -2
- package/js/dist/util/swipe.js +2 -2
- package/js/dist/util/template-factory.js +2 -2
- package/js/src/base-component.js +1 -1
- package/js/src/navigation.js +1 -1
- package/js/src/util/sanitizer.js +0 -1
- package/package.json +26 -29
- package/scss/_accordion.import.scss +1 -0
- package/scss/_accordion.scss +10 -2
- package/scss/_alert.import.scss +1 -0
- package/scss/_alert.scss +7 -3
- package/scss/_avatar.import.scss +1 -0
- package/scss/_avatar.scss +13 -8
- package/scss/_badge.import.scss +1 -0
- package/scss/_badge.scss +4 -0
- package/scss/_banner.scss +7 -0
- package/scss/_breadcrumb.import.scss +1 -0
- package/scss/_breadcrumb.scss +9 -3
- package/scss/_button-group.import.scss +1 -0
- package/scss/_button-group.scss +7 -3
- package/scss/_buttons.import.scss +1 -0
- package/scss/_buttons.scss +49 -18
- package/scss/_callout.import.scss +1 -0
- package/scss/_callout.scss +5 -2
- package/scss/_card.import.scss +1 -0
- package/scss/_card.scss +8 -3
- package/scss/_carousel.import.scss +1 -0
- package/scss/_carousel.scss +9 -3
- package/scss/_close.import.scss +1 -0
- package/scss/_close.scss +6 -1
- package/scss/_containers.import.scss +1 -0
- package/scss/_containers.scss +4 -0
- package/scss/_dropdown.import.scss +1 -0
- package/scss/_dropdown.scss +30 -21
- package/scss/_footer.import.scss +1 -0
- package/scss/_footer.scss +2 -0
- package/scss/_forms.import.scss +9 -0
- package/scss/_forms.scss +9 -9
- package/scss/_functions.import.scss +1 -0
- package/scss/_functions.scss +11 -366
- package/scss/_grid.import.scss +1 -0
- package/scss/_grid.scss +23 -1
- package/scss/_header.import.scss +1 -0
- package/scss/_header.scss +9 -2
- package/scss/_helpers.import.scss +1 -0
- package/scss/_helpers.scss +12 -12
- package/scss/_icon.import.scss +1 -0
- package/scss/_icon.scss +3 -0
- package/scss/_images.import.scss +1 -0
- package/scss/_images.scss +6 -0
- package/scss/_list-group.import.scss +1 -0
- package/scss/_list-group.scss +11 -6
- package/scss/_maps.import.scss +1 -0
- package/scss/_maps.scss +14 -7
- package/scss/_mixins.import.scss +1 -0
- package/scss/_mixins.scss +29 -29
- package/scss/_modal.import.scss +1 -0
- package/scss/_modal.scss +12 -3
- package/scss/_nav.import.scss +1 -0
- package/scss/_nav.scss +7 -1
- package/scss/_navbar.import.scss +1 -0
- package/scss/_navbar.scss +16 -4
- package/scss/_offcanvas.import.scss +1 -0
- package/scss/_offcanvas.scss +14 -7
- package/scss/_pagination.import.scss +1 -0
- package/scss/_pagination.scss +9 -1
- package/scss/_placeholders.import.scss +1 -0
- package/scss/_placeholders.scss +2 -0
- package/scss/_popover.import.scss +1 -0
- package/scss/_popover.scss +6 -0
- package/scss/_progress.import.scss +1 -0
- package/scss/_progress.scss +7 -0
- package/scss/_reboot.import.scss +1 -0
- package/scss/_reboot.scss +11 -7
- package/scss/_root.import.scss +1 -0
- package/scss/_root.scss +14 -5
- package/scss/_sidebar.import.scss +3 -0
- package/scss/_sidebar.scss +3 -3
- package/scss/_spinners.import.scss +1 -0
- package/scss/_spinners.scss +2 -0
- package/scss/_tables.import.scss +1 -0
- package/scss/_tables.scss +6 -1
- package/scss/_toasts.import.scss +1 -0
- package/scss/_toasts.scss +5 -2
- package/scss/_tooltip.import.scss +1 -0
- package/scss/_tooltip.scss +6 -0
- package/scss/_transitions.import.scss +1 -0
- package/scss/_transitions.scss +3 -0
- package/scss/_type.import.scss +1 -0
- package/scss/_type.scss +6 -1
- package/scss/_utilities.import.scss +1 -0
- package/scss/_utilities.scss +50 -63
- package/scss/_variables-dark.import.scss +1 -0
- package/scss/_variables-dark.scss +17 -36
- package/scss/_variables.import.scss +1 -0
- package/scss/_variables.scss +36 -34
- package/scss/coreui-grid.rtl.scss +4 -4
- package/scss/coreui-grid.scss +12 -21
- package/scss/coreui-reboot.rtl.scss +4 -4
- package/scss/coreui-reboot.scss +8 -9
- package/scss/coreui-utilities.rtl.scss +4 -4
- package/scss/coreui-utilities.scss +8 -11
- package/scss/coreui.rtl.scss +4 -4
- package/scss/coreui.scss +44 -47
- package/scss/forms/_floating-labels.import.scss +1 -0
- package/scss/forms/_floating-labels.scss +5 -1
- package/scss/forms/_form-check.import.scss +1 -0
- package/scss/forms/_form-check.scss +24 -20
- package/scss/forms/_form-control.import.scss +1 -0
- package/scss/forms/_form-control.scss +9 -1
- package/scss/forms/_form-range.import.scss +1 -0
- package/scss/forms/_form-range.scss +7 -0
- package/scss/forms/_form-select.import.scss +1 -0
- package/scss/forms/_form-select.scss +18 -5
- package/scss/forms/_form-text.import.scss +1 -0
- package/scss/forms/_form-text.scss +3 -0
- package/scss/forms/_input-group.import.scss +1 -0
- package/scss/forms/_input-group.scss +10 -4
- package/scss/forms/_labels.import.scss +1 -0
- package/scss/forms/_labels.scss +4 -0
- package/scss/forms/_validation.import.scss +1 -0
- package/scss/forms/_validation.scss +3 -0
- package/scss/functions/_assert-ascending.scss +19 -0
- package/scss/functions/_assert-starts-at-zero.scss +14 -0
- package/scss/functions/_color-contrast-variables.scss +24 -0
- package/scss/functions/_color-contrast.scss +27 -0
- package/scss/functions/_color.scss +18 -0
- package/scss/functions/_contrast-ratio.scss +35 -0
- package/scss/functions/_escape-svg.scss +22 -0
- package/scss/functions/_maps.scss +57 -0
- package/scss/functions/_math.scss +87 -0
- package/scss/functions/_rgba-css-var.scss +9 -0
- package/scss/functions/_str-replace.scss +19 -0
- package/scss/functions/_to-rgb.scss +5 -0
- package/scss/helpers/_clearfix.scss +2 -0
- package/scss/helpers/_color-bg.scss +9 -3
- package/scss/helpers/_colored-links.scss +13 -9
- package/scss/helpers/_focus-ring.scss +2 -0
- package/scss/helpers/_icon-link.scss +3 -0
- package/scss/helpers/_position.scss +5 -1
- package/scss/helpers/_ratio.scss +3 -1
- package/scss/helpers/_stretched-link.scss +2 -0
- package/scss/helpers/_text-truncation.scss +2 -0
- package/scss/helpers/_visually-hidden.scss +2 -0
- package/scss/helpers/_vr.scss +2 -0
- package/scss/mixins/_alert.scss +3 -0
- package/scss/mixins/_avatar.scss +3 -0
- package/scss/mixins/_backdrop.scss +2 -0
- package/scss/mixins/_border-radius.scss +15 -11
- package/scss/mixins/_box-shadow.scss +5 -2
- package/scss/mixins/_breakpoints.scss +82 -5
- package/scss/mixins/_buttons.scss +54 -50
- package/scss/mixins/_caret.scss +5 -3
- package/scss/mixins/_color-mode.scss +3 -1
- package/scss/mixins/_container.scss +2 -0
- package/scss/mixins/_deprecate.scss +2 -0
- package/scss/mixins/_forms.scss +12 -5
- package/scss/mixins/_gradients.scss +2 -0
- package/scss/mixins/_grid.scss +76 -7
- package/scss/mixins/_list-group.scss +6 -3
- package/scss/mixins/_lists.scss +1 -1
- package/scss/mixins/_ltr-rtl.scss +48 -17
- package/scss/mixins/_pagination.scss +3 -0
- package/scss/mixins/_reset-text.scss +2 -1
- package/scss/mixins/_table-variants.scss +10 -4
- package/scss/mixins/_transition.scss +7 -4
- package/scss/mixins/_utilities.import.scss +1 -0
- package/scss/mixins/_utilities.scss +30 -17
- package/scss/sidebar/_sidebar-narrow.scss +5 -0
- package/scss/sidebar/_sidebar-nav.scss +8 -4
- package/scss/sidebar/_sidebar.scss +24 -15
- package/scss/themes/bootstrap/bootstrap.rtl.scss +4 -22
- package/scss/themes/bootstrap/bootstrap.scss +121 -15
- package/scss/utilities/_api.import.scss +1 -0
- package/scss/utilities/_api.scss +14 -6
- package/scss/vendor/_rfs.scss +33 -27
- package/scss/mixins/_banner.scss +0 -7
- package/scss/themes/bootstrap/mixins/_banner.scss +0 -7
|
@@ -1,37 +1,50 @@
|
|
|
1
|
+
@use "sass:list";
|
|
2
|
+
@use "sass:map";
|
|
3
|
+
@use "sass:meta";
|
|
4
|
+
@use "sass:string";
|
|
5
|
+
@use "../variables" as *;
|
|
6
|
+
@use "../vendor/rfs" as *;
|
|
7
|
+
@use "ltr-rtl" as *;
|
|
8
|
+
|
|
9
|
+
// Generate selectors for theme variants
|
|
10
|
+
@function theme-prefix($theme, $selector) {
|
|
11
|
+
@return #{"[data" + $data-infix + "theme="$theme + "] ." + $theme + "\\:" + $selector + ", [data" + $data-infix + "theme="$theme + "] ." + $theme + "\\:" + $selector + ":not([class*='#{$theme}:'])"};
|
|
12
|
+
}
|
|
13
|
+
|
|
1
14
|
// Utility generator
|
|
2
15
|
// Used to generate utilities & print utilities
|
|
3
16
|
@mixin generate-utility($utility, $infix: "", $is-rfs-media-query: false) {
|
|
4
|
-
$values: map
|
|
17
|
+
$values: map.get($utility, values);
|
|
5
18
|
|
|
6
19
|
// If the values are a list or string, convert it into a map
|
|
7
|
-
@if type-of($values) == "string" or type-of(nth($values, 1)) != "list" {
|
|
8
|
-
$values: zip($values, $values);
|
|
20
|
+
@if meta.type-of($values) == "string" or meta.type-of(list.nth($values, 1)) != "list" {
|
|
21
|
+
$values: list.zip($values, $values);
|
|
9
22
|
}
|
|
10
23
|
|
|
11
24
|
@each $key, $value in $values {
|
|
12
|
-
$properties: map
|
|
25
|
+
$properties: map.get($utility, property);
|
|
13
26
|
|
|
14
27
|
// Multiple properties are possible, for example with vertical or horizontal margins or paddings
|
|
15
|
-
@if type-of($properties) == "string" {
|
|
16
|
-
$properties: append((), $properties);
|
|
28
|
+
@if meta.type-of($properties) == "string" {
|
|
29
|
+
$properties: list.append((), $properties);
|
|
17
30
|
}
|
|
18
31
|
|
|
19
32
|
// Use custom class if present
|
|
20
|
-
$property-class: if(map
|
|
33
|
+
$property-class: if(map.has-key($utility, class), map.get($utility, class), list.nth($properties, 1));
|
|
21
34
|
$property-class: if($property-class == null, "", $property-class);
|
|
22
35
|
|
|
23
36
|
// Use custom CSS variable name if present, otherwise default to `class`
|
|
24
|
-
$css-variable-name: if(map
|
|
37
|
+
$css-variable-name: if(map.has-key($utility, css-variable-name), map.get($utility, css-variable-name), map.get($utility, class));
|
|
25
38
|
|
|
26
39
|
// State params to generate pseudo-classes
|
|
27
|
-
$state: if(map
|
|
40
|
+
$state: if(map.has-key($utility, state), map.get($utility, state), ());
|
|
28
41
|
|
|
29
|
-
$infix: if($property-class == "" and
|
|
42
|
+
$infix: if($property-class == "" and string.slice($infix, 1, 1) == "-", string.slice($infix, 2), $infix);
|
|
30
43
|
|
|
31
44
|
// Don't prefix if value key is null (e.g. with shadow class)
|
|
32
45
|
$property-class-modifier: if($key, if($property-class == "" and $infix == "", "", "-") + $key, "");
|
|
33
46
|
|
|
34
|
-
@if map
|
|
47
|
+
@if map.get($utility, rfs) {
|
|
35
48
|
// Inside the media query
|
|
36
49
|
@if $is-rfs-media-query {
|
|
37
50
|
$val: rfs-value($value);
|
|
@@ -44,10 +57,10 @@
|
|
|
44
57
|
}
|
|
45
58
|
}
|
|
46
59
|
|
|
47
|
-
$is-css-var: map
|
|
48
|
-
$is-dark-mode: map
|
|
49
|
-
$is-local-vars: map
|
|
50
|
-
$is-rtl: map
|
|
60
|
+
$is-css-var: map.get($utility, css-var);
|
|
61
|
+
$is-dark-mode: map.get($utility, dark-mode);
|
|
62
|
+
$is-local-vars: map.get($utility, local-vars);
|
|
63
|
+
$is-rtl: map.get($utility, rtl);
|
|
51
64
|
|
|
52
65
|
@if $value != null {
|
|
53
66
|
@if $is-rtl == false {
|
|
@@ -93,8 +106,8 @@
|
|
|
93
106
|
}
|
|
94
107
|
}
|
|
95
108
|
@if $is-rtl == true {
|
|
96
|
-
@if (type-of($value) == "map") {
|
|
97
|
-
@include ltr-rtl($property, map
|
|
109
|
+
@if (meta.type-of($value) == "map") {
|
|
110
|
+
@include ltr-rtl($property, map.get($value, "ltr"), null, map.get($value, "rtl"), if($enable-important-utilities, !important, null));
|
|
98
111
|
} @else {
|
|
99
112
|
@include ltr-rtl($property, $value, null, null, if($enable-important-utilities, !important, null));
|
|
100
113
|
}
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
// Sidebar navigation
|
|
2
|
+
@use "../functions/escape-svg" as *;
|
|
3
|
+
@use "../mixins/border-radius" as *;
|
|
4
|
+
@use "../mixins/transition" as *;
|
|
5
|
+
@use "../variables" as *;
|
|
2
6
|
|
|
3
7
|
.sidebar-nav {
|
|
4
8
|
// scss-docs-start sidebar-nav-css-vars
|
|
@@ -175,7 +179,7 @@
|
|
|
175
179
|
align-items: center;
|
|
176
180
|
justify-content: center;
|
|
177
181
|
height: var(--#{$prefix}sidebar-nav-link-icon-height);
|
|
178
|
-
|
|
182
|
+
margin-inline-end: var(--#{$prefix}sidebar-nav-link-icon-margin);
|
|
179
183
|
font-size: var(--#{$prefix}sidebar-nav-link-icon-font-size);
|
|
180
184
|
color: var(--#{$prefix}sidebar-nav-link-icon-color);
|
|
181
185
|
text-align: center;
|
|
@@ -238,7 +242,7 @@
|
|
|
238
242
|
display: block;
|
|
239
243
|
flex: 0 12px;
|
|
240
244
|
height: 12px;
|
|
241
|
-
|
|
245
|
+
margin-inline-start: auto;
|
|
242
246
|
content: "";
|
|
243
247
|
background-color: var(--#{$prefix}sidebar-nav-group-indicator-color);
|
|
244
248
|
mask-image: var(--#{$prefix}sidebar-nav-group-indicator-icon);
|
|
@@ -251,11 +255,11 @@
|
|
|
251
255
|
list-style: none;
|
|
252
256
|
|
|
253
257
|
.nav-link {
|
|
254
|
-
|
|
258
|
+
padding-inline-start: calc(var(--#{$prefix}sidebar-nav-link-padding-x) + var(--#{$prefix}sidebar-nav-link-icon-width) + var(--#{$prefix}sidebar-nav-link-icon-margin)); // stylelint-disable-line function-disallowed-list
|
|
255
259
|
}
|
|
256
260
|
|
|
257
261
|
.nav-icon {
|
|
258
|
-
|
|
262
|
+
margin-inline-start: calc((var(--#{$prefix}sidebar-nav-link-icon-width) + var(--#{$prefix}sidebar-nav-link-icon-margin)) * -1); // stylelint-disable-line function-disallowed-list
|
|
259
263
|
}
|
|
260
264
|
}
|
|
261
265
|
|
|
@@ -1,4 +1,13 @@
|
|
|
1
1
|
// stylelint-disable function-disallowed-list
|
|
2
|
+
@use "../functions/escape-svg" as *;
|
|
3
|
+
@use "../mixins/backdrop" as *;
|
|
4
|
+
@use "../mixins/border-radius" as *;
|
|
5
|
+
@use "../mixins/breakpoints" as *;
|
|
6
|
+
@use "../mixins/ltr-rtl" as *;
|
|
7
|
+
@use "../mixins/transition" as *;
|
|
8
|
+
@use "../variables" as *;
|
|
9
|
+
@use "../variables-dark" as *;
|
|
10
|
+
|
|
2
11
|
.sidebar {
|
|
3
12
|
// scss-docs-start sidebar-css-vars
|
|
4
13
|
--#{$prefix}sidebar-zindex: #{$zindex-sidebar};
|
|
@@ -24,12 +33,12 @@
|
|
|
24
33
|
@include transition($sidebar-transition);
|
|
25
34
|
|
|
26
35
|
&:not(.sidebar-end){
|
|
27
|
-
|
|
36
|
+
margin-inline-start: 0;
|
|
28
37
|
}
|
|
29
38
|
|
|
30
39
|
&.sidebar-end {
|
|
31
40
|
order: 99;
|
|
32
|
-
|
|
41
|
+
margin-inline-end: 0;
|
|
33
42
|
}
|
|
34
43
|
|
|
35
44
|
@include media-breakpoint-up($mobile-breakpoint) {
|
|
@@ -44,10 +53,10 @@
|
|
|
44
53
|
|
|
45
54
|
&.hide {
|
|
46
55
|
&:not(.sidebar-end) {
|
|
47
|
-
|
|
56
|
+
margin-inline-start: calc(-1 * var(--#{$prefix}sidebar-width));
|
|
48
57
|
}
|
|
49
58
|
&.sidebar-end {
|
|
50
|
-
|
|
59
|
+
margin-inline-end: calc(-1 * var(--#{$prefix}sidebar-width));
|
|
51
60
|
|
|
52
61
|
}
|
|
53
62
|
}
|
|
@@ -63,18 +72,18 @@
|
|
|
63
72
|
z-index: var(--#{$prefix}sidebar-zindex);
|
|
64
73
|
|
|
65
74
|
&:not(.sidebar-end) {
|
|
66
|
-
|
|
75
|
+
inset-inline-start: 0;
|
|
67
76
|
|
|
68
77
|
&:not(.show) {
|
|
69
|
-
|
|
78
|
+
margin-inline-start: calc(-1 * var(--#{$prefix}sidebar-width));
|
|
70
79
|
}
|
|
71
80
|
}
|
|
72
81
|
|
|
73
82
|
&.sidebar-end {
|
|
74
|
-
|
|
83
|
+
inset-inline-end: 0;
|
|
75
84
|
|
|
76
85
|
&:not(.show) {
|
|
77
|
-
|
|
86
|
+
margin-inline-end: calc(-1 * var(--#{$prefix}sidebar-width));
|
|
78
87
|
}
|
|
79
88
|
}
|
|
80
89
|
}
|
|
@@ -87,11 +96,11 @@
|
|
|
87
96
|
z-index: var(--#{$prefix}sidebar-zindex);
|
|
88
97
|
|
|
89
98
|
&:not(.sidebar-end) {
|
|
90
|
-
|
|
99
|
+
inset-inline-start: 0;
|
|
91
100
|
}
|
|
92
101
|
|
|
93
102
|
&.sidebar-end {
|
|
94
|
-
|
|
103
|
+
inset-inline-end: 0;
|
|
95
104
|
}
|
|
96
105
|
}
|
|
97
106
|
|
|
@@ -103,22 +112,22 @@
|
|
|
103
112
|
@extend .sidebar-fixed;
|
|
104
113
|
|
|
105
114
|
&:not(.sidebar-end){
|
|
106
|
-
|
|
115
|
+
margin-inline-start: calc(-1 * var(--#{$prefix}sidebar-width));
|
|
107
116
|
}
|
|
108
117
|
|
|
109
118
|
&.sidebar-end {
|
|
110
|
-
|
|
119
|
+
margin-inline-end: calc(-1 * var(--#{$prefix}sidebar-width));
|
|
111
120
|
}
|
|
112
121
|
|
|
113
122
|
&.show {
|
|
114
123
|
box-shadow: var(--#{$prefix}sidebar-overlaid-box-shadow);
|
|
115
124
|
|
|
116
125
|
&:not(.sidebar-end) {
|
|
117
|
-
|
|
126
|
+
margin-inline-start: 0;
|
|
118
127
|
}
|
|
119
128
|
|
|
120
129
|
&.sidebar-end {
|
|
121
|
-
|
|
130
|
+
margin-inline-end: 0;
|
|
122
131
|
}
|
|
123
132
|
}
|
|
124
133
|
}
|
|
@@ -157,8 +166,8 @@
|
|
|
157
166
|
|
|
158
167
|
.btn-close {
|
|
159
168
|
padding: calc(var(--#{$prefix}sidebar-padding-y) * .5) calc(var(--#{$prefix}sidebar-padding-x) * .5);
|
|
169
|
+
margin-inline-end: calc(-.5 * var(--#{$prefix}sidebar-padding-x));
|
|
160
170
|
margin-top: calc(-.5 * var(--#{$prefix}sidebar-padding-y));
|
|
161
|
-
@include ltr-rtl("margin-right", calc(-.5 * var(--#{$prefix}sidebar-padding-x)));
|
|
162
171
|
margin-bottom: calc(-.5 * var(--#{$prefix}sidebar-padding-y));
|
|
163
172
|
}
|
|
164
173
|
}
|
|
@@ -1,22 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
$enable-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
@include bsBanner("");
|
|
6
|
-
|
|
7
|
-
@import "../../../node_modules/bootstrap/scss/bootstrap";
|
|
8
|
-
@import "../../variables";
|
|
9
|
-
|
|
10
|
-
/* rtl:begin:ignore */
|
|
11
|
-
@import "../../mixins/avatar";
|
|
12
|
-
@import "../../mixins/icon";
|
|
13
|
-
@import "../../mixins/ltr-rtl";
|
|
14
|
-
|
|
15
|
-
@import "../../avatar";
|
|
16
|
-
@import "../../callout";
|
|
17
|
-
@import "../../footer";
|
|
18
|
-
@import "../../header";
|
|
19
|
-
@import "../../icon";
|
|
20
|
-
@import "../../sidebar";
|
|
21
|
-
|
|
22
|
-
/* rtl:end:ignore */
|
|
1
|
+
@use "bootstrap" with (
|
|
2
|
+
$enable-ltr: false,
|
|
3
|
+
$enable-rtl: true
|
|
4
|
+
);
|
|
@@ -1,19 +1,125 @@
|
|
|
1
|
-
@
|
|
2
|
-
@
|
|
1
|
+
@use "sass:color";
|
|
2
|
+
@use "../../banner" with (
|
|
3
|
+
$file: "Bootstrap Theme"
|
|
4
|
+
);
|
|
5
|
+
@use "../../functions/color" as *;
|
|
3
6
|
|
|
4
|
-
|
|
5
|
-
|
|
7
|
+
// scss-docs-start gray-color-variables
|
|
8
|
+
$white: #fff !default;
|
|
9
|
+
$gray-100: #f8f9fa !default;
|
|
10
|
+
$gray-200: #e9ecef !default;
|
|
11
|
+
$gray-300: #dee2e6 !default;
|
|
12
|
+
$gray-400: #ced4da !default;
|
|
13
|
+
$gray-500: #adb5bd !default;
|
|
14
|
+
$gray-600: #6c757d !default;
|
|
15
|
+
$gray-700: #495057 !default;
|
|
16
|
+
$gray-800: #343a40 !default;
|
|
17
|
+
$gray-900: #212529 !default;
|
|
18
|
+
$black: #000 !default;
|
|
19
|
+
// scss-docs-end gray-color-variables
|
|
6
20
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
21
|
+
// scss-docs-start color-variables
|
|
22
|
+
$blue: #0d6efd !default;
|
|
23
|
+
$indigo: #6610f2 !default;
|
|
24
|
+
$purple: #6f42c1 !default;
|
|
25
|
+
$pink: #d63384 !default;
|
|
26
|
+
$red: #dc3545 !default;
|
|
27
|
+
$orange: #fd7e14 !default;
|
|
28
|
+
$yellow: #ffc107 !default;
|
|
29
|
+
$green: #198754 !default;
|
|
30
|
+
$teal: #20c997 !default;
|
|
31
|
+
$cyan: #0dcaf0 !default;
|
|
32
|
+
// scss-docs-end color-variables
|
|
11
33
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
34
|
+
// scss-docs-start theme-color-variables
|
|
35
|
+
$primary: $blue !default;
|
|
36
|
+
$secondary: $gray-600 !default;
|
|
37
|
+
$success: $green !default;
|
|
38
|
+
$info: $cyan !default;
|
|
39
|
+
$warning: $yellow !default;
|
|
40
|
+
$danger: $red !default;
|
|
41
|
+
$light: $gray-100 !default;
|
|
42
|
+
$dark: $gray-900 !default;
|
|
43
|
+
// scss-docs-end theme-color-variables
|
|
18
44
|
|
|
19
|
-
|
|
45
|
+
// scss-docs-start theme-text-dark-variables
|
|
46
|
+
$primary-text-emphasis-dark: tint-color($primary, 40%) !default;
|
|
47
|
+
$secondary-text-emphasis-dark: tint-color($secondary, 40%) !default;
|
|
48
|
+
$success-text-emphasis-dark: tint-color($success, 40%) !default;
|
|
49
|
+
$info-text-emphasis-dark: tint-color($info, 40%) !default;
|
|
50
|
+
$warning-text-emphasis-dark: tint-color($warning, 40%) !default;
|
|
51
|
+
$danger-text-emphasis-dark: tint-color($danger, 40%) !default;
|
|
52
|
+
// scss-docs-end theme-text-dark-variables
|
|
53
|
+
|
|
54
|
+
// scss-docs-start theme-bg-subtle-dark-variables
|
|
55
|
+
$primary-bg-subtle-dark: shade-color($primary, 80%) !default;
|
|
56
|
+
$secondary-bg-subtle-dark: shade-color($secondary, 80%) !default;
|
|
57
|
+
$success-bg-subtle-dark: shade-color($success, 80%) !default;
|
|
58
|
+
$info-bg-subtle-dark: shade-color($info, 80%) !default;
|
|
59
|
+
$warning-bg-subtle-dark: shade-color($warning, 80%) !default;
|
|
60
|
+
$danger-bg-subtle-dark: shade-color($danger, 80%) !default;
|
|
61
|
+
// scss-docs-end theme-bg-subtle-dark-variables
|
|
62
|
+
|
|
63
|
+
// scss-docs-start theme-border-subtle-dark-variables
|
|
64
|
+
$primary-border-subtle-dark: shade-color($primary, 40%) !default;
|
|
65
|
+
$secondary-border-subtle-dark: shade-color($secondary, 40%) !default;
|
|
66
|
+
$success-border-subtle-dark: shade-color($success, 40%) !default;
|
|
67
|
+
$info-border-subtle-dark: shade-color($info, 40%) !default;
|
|
68
|
+
$warning-border-subtle-dark: shade-color($warning, 40%) !default;
|
|
69
|
+
$danger-border-subtle-dark: shade-color($danger, 40%) !default;
|
|
70
|
+
// scss-docs-end theme-border-subtle-dark-variables
|
|
71
|
+
|
|
72
|
+
@forward "../../coreui" with (
|
|
73
|
+
$prefix: bs- !default,
|
|
74
|
+
$data-infix: -bs- !default,
|
|
75
|
+
$white: $white !default,
|
|
76
|
+
$gray-100: $gray-100 !default,
|
|
77
|
+
$gray-200: $gray-200 !default,
|
|
78
|
+
$gray-300: $gray-300 !default,
|
|
79
|
+
$gray-400: $gray-400 !default,
|
|
80
|
+
$gray-500: $gray-500 !default,
|
|
81
|
+
$gray-600: $gray-600 !default,
|
|
82
|
+
$gray-700: $gray-700 !default,
|
|
83
|
+
$gray-800: $gray-800 !default,
|
|
84
|
+
$gray-900: $gray-900 !default,
|
|
85
|
+
$black: $black !default,
|
|
86
|
+
$primary: $primary !default,
|
|
87
|
+
$secondary: $secondary !default,
|
|
88
|
+
$success: $success !default,
|
|
89
|
+
$info: $info !default,
|
|
90
|
+
$warning: $warning !default,
|
|
91
|
+
$danger: $danger !default,
|
|
92
|
+
$light: $light !default,
|
|
93
|
+
$dark: $dark !default,
|
|
94
|
+
$body-color: $gray-900 !default,
|
|
95
|
+
$body-secondary-color: rgba($gray-900, .75) !default,
|
|
96
|
+
$body-tertiary-bg: rgba($gray-900, .75) !default,
|
|
97
|
+
$component-active-color: $white !default,
|
|
98
|
+
$component-active-bg: $primary !default,
|
|
99
|
+
$body-color-dark: $gray-300 !default,
|
|
100
|
+
$body-bg-dark: $gray-900 !default,
|
|
101
|
+
$body-secondary-color-dark: rgba($gray-300, .75) !default,
|
|
102
|
+
$body-secondary-bg-dark: $gray-800 !default,
|
|
103
|
+
$body-tertiary-color-dark: rgba($gray-300, .5) !default,
|
|
104
|
+
$body-tertiary-bg-dark: color.mix($gray-800, $gray-900, 50%) !default,
|
|
105
|
+
$primary-text-emphasis-dark: $primary-text-emphasis-dark !default,
|
|
106
|
+
$secondary-text-emphasis-dark: $secondary-text-emphasis-dark !default,
|
|
107
|
+
$success-text-emphasis-dark: $success-text-emphasis-dark !default,
|
|
108
|
+
$info-text-emphasis-dark: $info-text-emphasis-dark !default,
|
|
109
|
+
$warning-text-emphasis-dark: $warning-text-emphasis-dark !default,
|
|
110
|
+
$danger-text-emphasis-dark: $danger-text-emphasis-dark !default,
|
|
111
|
+
$primary-bg-subtle-dark: $primary-bg-subtle-dark !default,
|
|
112
|
+
$secondary-bg-subtle-dark: $secondary-bg-subtle-dark !default,
|
|
113
|
+
$success-bg-subtle-dark: $success-bg-subtle-dark !default,
|
|
114
|
+
$info-bg-subtle-dark: $info-bg-subtle-dark !default,
|
|
115
|
+
$warning-bg-subtle-dark: $warning-bg-subtle-dark !default,
|
|
116
|
+
$danger-bg-subtle-dark: $danger-bg-subtle-dark !default,
|
|
117
|
+
$primary-border-subtle-dark: $primary-border-subtle-dark !default,
|
|
118
|
+
$secondary-border-subtle-dark: $secondary-border-subtle-dark !default,
|
|
119
|
+
$success-border-subtle-dark: $success-border-subtle-dark !default,
|
|
120
|
+
$info-border-subtle-dark: $info-border-subtle-dark !default,
|
|
121
|
+
$warning-border-subtle-dark: $warning-border-subtle-dark !default,
|
|
122
|
+
$danger-border-subtle-dark: $danger-border-subtle-dark !default,
|
|
123
|
+
$theme-colors-dark: () !default,
|
|
124
|
+
$grays-dark: () !default,
|
|
125
|
+
);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@forward "api";
|
package/scss/utilities/_api.scss
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
|
+
@use "sass:map";
|
|
2
|
+
@use "sass:meta";
|
|
3
|
+
@use "../utilities" as *;
|
|
4
|
+
@use "../mixins/breakpoints" as *;
|
|
5
|
+
@use "../mixins/utilities" as *;
|
|
6
|
+
@use "../vendor/rfs" as *;
|
|
7
|
+
@use "../variables" as *;
|
|
8
|
+
|
|
1
9
|
// Loop over each breakpoint
|
|
2
|
-
@each $breakpoint in map
|
|
10
|
+
@each $breakpoint in map.keys($grid-breakpoints) {
|
|
3
11
|
|
|
4
12
|
// Generate media query if needed
|
|
5
13
|
@include media-breakpoint-up($breakpoint) {
|
|
@@ -9,7 +17,7 @@
|
|
|
9
17
|
@each $key, $utility in $utilities {
|
|
10
18
|
// The utility can be disabled with `false`, thus check if the utility is a map first
|
|
11
19
|
// Only proceed if responsive media queries are enabled or if it's the base media query
|
|
12
|
-
@if type-of($utility) == "map" and (map
|
|
20
|
+
@if meta.type-of($utility) == "map" and (map.get($utility, responsive) or $infix == "") {
|
|
13
21
|
@include generate-utility($utility, $infix);
|
|
14
22
|
}
|
|
15
23
|
}
|
|
@@ -18,15 +26,15 @@
|
|
|
18
26
|
|
|
19
27
|
// RFS rescaling
|
|
20
28
|
@media (min-width: $rfs-mq-value) {
|
|
21
|
-
@each $breakpoint in map
|
|
29
|
+
@each $breakpoint in map.keys($grid-breakpoints) {
|
|
22
30
|
$infix: breakpoint-infix($breakpoint, $grid-breakpoints);
|
|
23
31
|
|
|
24
|
-
@if (map
|
|
32
|
+
@if (map.get($grid-breakpoints, $breakpoint) < $rfs-breakpoint) {
|
|
25
33
|
// Loop over each utility property
|
|
26
34
|
@each $key, $utility in $utilities {
|
|
27
35
|
// The utility can be disabled with `false`, thus check if the utility is a map first
|
|
28
36
|
// Only proceed if responsive media queries are enabled or if it's the base media query
|
|
29
|
-
@if type-of($utility) == "map" and map
|
|
37
|
+
@if meta.type-of($utility) == "map" and map.get($utility, rfs) and (map.get($utility, responsive) or $infix == "") {
|
|
30
38
|
@include generate-utility($utility, $infix, true);
|
|
31
39
|
}
|
|
32
40
|
}
|
|
@@ -40,7 +48,7 @@
|
|
|
40
48
|
@each $key, $utility in $utilities {
|
|
41
49
|
// The utility can be disabled with `false`, thus check if the utility is a map first
|
|
42
50
|
// Then check if the utility needs print styles
|
|
43
|
-
@if type-of($utility) == "map" and map
|
|
51
|
+
@if meta.type-of($utility) == "map" and map.get($utility, print) == true {
|
|
44
52
|
@include generate-utility($utility, "-print");
|
|
45
53
|
}
|
|
46
54
|
}
|
package/scss/vendor/_rfs.scss
CHANGED
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
// stylelint-disable scss/dimension-no-non-numeric-values
|
|
2
|
+
@use "sass:map";
|
|
3
|
+
@use "sass:math";
|
|
4
|
+
@use "sass:meta";
|
|
5
|
+
@use "sass:string";
|
|
6
|
+
|
|
7
|
+
@use "../variables" as *;
|
|
2
8
|
|
|
3
9
|
// SCSS RFS mixin
|
|
4
10
|
//
|
|
@@ -30,7 +36,7 @@ $rfs-two-dimensional: false !default;
|
|
|
30
36
|
// Factor of decrease
|
|
31
37
|
$rfs-factor: 10 !default;
|
|
32
38
|
|
|
33
|
-
@if type-of($rfs-factor) != number or $rfs-factor <= 1 {
|
|
39
|
+
@if meta.type-of($rfs-factor) != number or $rfs-factor <= 1 {
|
|
34
40
|
@error "`#{$rfs-factor}` is not a valid $rfs-factor, it must be greater than 1.";
|
|
35
41
|
}
|
|
36
42
|
|
|
@@ -47,12 +53,12 @@ $rfs-rem-value: 16 !default;
|
|
|
47
53
|
$rfs-safari-iframe-resize-bug-fix: false !default;
|
|
48
54
|
|
|
49
55
|
// Disable RFS by setting $enable-rfs to false
|
|
50
|
-
$enable-rfs:
|
|
56
|
+
$enable-rfs: $enable-rfs !default;
|
|
51
57
|
|
|
52
58
|
// Cache $rfs-base-value unit
|
|
53
|
-
$rfs-base-value-unit: unit($rfs-base-value);
|
|
59
|
+
$rfs-base-value-unit: math.unit($rfs-base-value);
|
|
54
60
|
|
|
55
|
-
@function divide($dividend, $divisor, $precision: 10) {
|
|
61
|
+
@function rfs-divide($dividend, $divisor, $precision: 10) {
|
|
56
62
|
$sign: if($dividend > 0 and $divisor > 0 or $dividend < 0 and $divisor < 0, 1, -1);
|
|
57
63
|
$dividend: abs($dividend);
|
|
58
64
|
$divisor: abs($divisor);
|
|
@@ -80,41 +86,41 @@ $rfs-base-value-unit: unit($rfs-base-value);
|
|
|
80
86
|
}
|
|
81
87
|
}
|
|
82
88
|
$result: $result * $factor * $sign;
|
|
83
|
-
$dividend-unit: unit($dividend);
|
|
84
|
-
$divisor-unit: unit($divisor);
|
|
89
|
+
$dividend-unit: math.unit($dividend);
|
|
90
|
+
$divisor-unit: math.unit($divisor);
|
|
85
91
|
$unit-map: (
|
|
86
92
|
"px": 1px,
|
|
87
93
|
"rem": 1rem,
|
|
88
94
|
"em": 1em,
|
|
89
95
|
"%": 1%
|
|
90
96
|
);
|
|
91
|
-
@if ($dividend-unit != $divisor-unit and map
|
|
92
|
-
$result: $result * map
|
|
97
|
+
@if ($dividend-unit != $divisor-unit and map.has-key($unit-map, $dividend-unit)) {
|
|
98
|
+
$result: $result * map.get($unit-map, $dividend-unit);
|
|
93
99
|
}
|
|
94
100
|
@return $result;
|
|
95
101
|
}
|
|
96
102
|
|
|
97
103
|
// Remove px-unit from $rfs-base-value for calculations
|
|
98
104
|
@if $rfs-base-value-unit == px {
|
|
99
|
-
$rfs-base-value: divide($rfs-base-value, $rfs-base-value * 0 + 1);
|
|
105
|
+
$rfs-base-value: rfs-divide($rfs-base-value, $rfs-base-value * 0 + 1);
|
|
100
106
|
}
|
|
101
107
|
@else if $rfs-base-value-unit == rem {
|
|
102
|
-
$rfs-base-value: divide($rfs-base-value, divide($rfs-base-value * 0 + 1, $rfs-rem-value));
|
|
108
|
+
$rfs-base-value: rfs-divide($rfs-base-value, rfs-divide($rfs-base-value * 0 + 1, $rfs-rem-value));
|
|
103
109
|
}
|
|
104
110
|
|
|
105
111
|
// Cache $rfs-breakpoint unit to prevent multiple calls
|
|
106
|
-
$rfs-breakpoint-unit-cache: unit($rfs-breakpoint);
|
|
112
|
+
$rfs-breakpoint-unit-cache: math.unit($rfs-breakpoint);
|
|
107
113
|
|
|
108
114
|
// Remove unit from $rfs-breakpoint for calculations
|
|
109
115
|
@if $rfs-breakpoint-unit-cache == px {
|
|
110
|
-
$rfs-breakpoint: divide($rfs-breakpoint, $rfs-breakpoint * 0 + 1);
|
|
116
|
+
$rfs-breakpoint: rfs-divide($rfs-breakpoint, $rfs-breakpoint * 0 + 1);
|
|
111
117
|
}
|
|
112
118
|
@else if $rfs-breakpoint-unit-cache == rem or $rfs-breakpoint-unit-cache == "em" {
|
|
113
|
-
$rfs-breakpoint: divide($rfs-breakpoint, divide($rfs-breakpoint * 0 + 1, $rfs-rem-value));
|
|
119
|
+
$rfs-breakpoint: rfs-divide($rfs-breakpoint, rfs-divide($rfs-breakpoint * 0 + 1, $rfs-rem-value));
|
|
114
120
|
}
|
|
115
121
|
|
|
116
122
|
// Calculate the media query value
|
|
117
|
-
$rfs-mq-value: if($rfs-breakpoint-unit == px, #{$rfs-breakpoint}px, #{divide($rfs-breakpoint, $rfs-rem-value)}#{$rfs-breakpoint-unit});
|
|
123
|
+
$rfs-mq-value: if($rfs-breakpoint-unit == px, #{$rfs-breakpoint}px, #{rfs-divide($rfs-breakpoint, $rfs-rem-value)}#{$rfs-breakpoint-unit});
|
|
118
124
|
$rfs-mq-property-width: if($rfs-mode == max-media-query, max-width, min-width);
|
|
119
125
|
$rfs-mq-property-height: if($rfs-mode == max-media-query, max-height, min-height);
|
|
120
126
|
|
|
@@ -190,7 +196,7 @@ $rfs-mq-property-height: if($rfs-mode == max-media-query, max-height, min-height
|
|
|
190
196
|
// Helper function to get the formatted non-responsive value
|
|
191
197
|
@function rfs-value($values) {
|
|
192
198
|
// Convert to list
|
|
193
|
-
$values: if(type-of($values) != list, ($values,), $values);
|
|
199
|
+
$values: if(meta.type-of($values) != list, ($values,), $values);
|
|
194
200
|
|
|
195
201
|
$val: "";
|
|
196
202
|
|
|
@@ -201,15 +207,15 @@ $rfs-mq-property-height: if($rfs-mode == max-media-query, max-height, min-height
|
|
|
201
207
|
}
|
|
202
208
|
@else {
|
|
203
209
|
// Cache $value unit
|
|
204
|
-
$unit: if(type-of($value) == "number", unit($value), false);
|
|
210
|
+
$unit: if(meta.type-of($value) == "number", math.unit($value), false);
|
|
205
211
|
|
|
206
212
|
@if $unit == px {
|
|
207
213
|
// Convert to rem if needed
|
|
208
|
-
$val: $val + " " + if($rfs-unit == rem, #{divide($value, $value * 0 + $rfs-rem-value)}rem, $value);
|
|
214
|
+
$val: $val + " " + if($rfs-unit == rem, #{rfs-divide($value, $value * 0 + $rfs-rem-value)}rem, $value);
|
|
209
215
|
}
|
|
210
216
|
@else if $unit == rem {
|
|
211
217
|
// Convert to px if needed
|
|
212
|
-
$val: $val + " " + if($rfs-unit == px, #{divide($value, $value * 0 + 1) * $rfs-rem-value}px, $value);
|
|
218
|
+
$val: $val + " " + if($rfs-unit == px, #{rfs-divide($value, $value * 0 + 1) * $rfs-rem-value}px, $value);
|
|
213
219
|
} @else {
|
|
214
220
|
// If $value isn't a number (like inherit) or $value has a unit (not px or rem, like 1.5em) or $ is 0, just print the value
|
|
215
221
|
$val: $val + " " + $value;
|
|
@@ -218,13 +224,13 @@ $rfs-mq-property-height: if($rfs-mode == max-media-query, max-height, min-height
|
|
|
218
224
|
}
|
|
219
225
|
|
|
220
226
|
// Remove first space
|
|
221
|
-
@return unquote(
|
|
227
|
+
@return string.unquote(string.slice($val, 2));
|
|
222
228
|
}
|
|
223
229
|
|
|
224
230
|
// Helper function to get the responsive value calculated by RFS
|
|
225
231
|
@function rfs-fluid-value($values) {
|
|
226
232
|
// Convert to list
|
|
227
|
-
$values: if(type-of($values) != list, ($values,), $values);
|
|
233
|
+
$values: if(meta.type-of($values) != list, ($values,), $values);
|
|
228
234
|
|
|
229
235
|
$val: "";
|
|
230
236
|
|
|
@@ -234,28 +240,28 @@ $rfs-mq-property-height: if($rfs-mode == max-media-query, max-height, min-height
|
|
|
234
240
|
$val: $val + " 0";
|
|
235
241
|
} @else {
|
|
236
242
|
// Cache $value unit
|
|
237
|
-
$unit: if(type-of($value) == "number", unit($value), false);
|
|
243
|
+
$unit: if(meta.type-of($value) == "number", math.unit($value), false);
|
|
238
244
|
|
|
239
245
|
// If $value isn't a number (like inherit) or $value has a unit (not px or rem, like 1.5em) or $ is 0, just print the value
|
|
240
246
|
@if not $unit or $unit != px and $unit != rem {
|
|
241
247
|
$val: $val + " " + $value;
|
|
242
248
|
} @else {
|
|
243
249
|
// Remove unit from $value for calculations
|
|
244
|
-
$value: divide($value, $value * 0 + if($unit == px, 1, divide(1, $rfs-rem-value)));
|
|
250
|
+
$value: rfs-divide($value, $value * 0 + if($unit == px, 1, rfs-divide(1, $rfs-rem-value)));
|
|
245
251
|
|
|
246
252
|
// Only add the media query if the value is greater than the minimum value
|
|
247
253
|
@if abs($value) <= $rfs-base-value or not $enable-rfs {
|
|
248
|
-
$val: $val + " " + if($rfs-unit == rem, #{divide($value, $rfs-rem-value)}rem, #{$value}px);
|
|
254
|
+
$val: $val + " " + if($rfs-unit == rem, #{rfs-divide($value, $rfs-rem-value)}rem, #{$value}px);
|
|
249
255
|
}
|
|
250
256
|
@else {
|
|
251
257
|
// Calculate the minimum value
|
|
252
|
-
$value-min: $rfs-base-value + divide(abs($value) - $rfs-base-value, $rfs-factor);
|
|
258
|
+
$value-min: $rfs-base-value + rfs-divide(abs($value) - $rfs-base-value, $rfs-factor);
|
|
253
259
|
|
|
254
260
|
// Calculate difference between $value and the minimum value
|
|
255
261
|
$value-diff: abs($value) - $value-min;
|
|
256
262
|
|
|
257
263
|
// Base value formatting
|
|
258
|
-
$min-width: if($rfs-unit == rem, #{divide($value-min, $rfs-rem-value)}rem, #{$value-min}px);
|
|
264
|
+
$min-width: if($rfs-unit == rem, #{rfs-divide($value-min, $rfs-rem-value)}rem, #{$value-min}px);
|
|
259
265
|
|
|
260
266
|
// Use negative value if needed
|
|
261
267
|
$min-width: if($value < 0, -$min-width, $min-width);
|
|
@@ -264,7 +270,7 @@ $rfs-mq-property-height: if($rfs-mode == max-media-query, max-height, min-height
|
|
|
264
270
|
$variable-unit: if($rfs-two-dimensional, vmin, vw);
|
|
265
271
|
|
|
266
272
|
// Calculate the variable width between 0 and $rfs-breakpoint
|
|
267
|
-
$variable-width: #{divide($value-diff * 100, $rfs-breakpoint)}#{$variable-unit};
|
|
273
|
+
$variable-width: #{rfs-divide($value-diff * 100, $rfs-breakpoint)}#{$variable-unit};
|
|
268
274
|
|
|
269
275
|
// Return the calculated value
|
|
270
276
|
$val: $val + " calc(" + $min-width + if($value < 0, " - ", " + ") + $variable-width + ")";
|
|
@@ -274,7 +280,7 @@ $rfs-mq-property-height: if($rfs-mode == max-media-query, max-height, min-height
|
|
|
274
280
|
}
|
|
275
281
|
|
|
276
282
|
// Remove first space
|
|
277
|
-
@return unquote(
|
|
283
|
+
@return string.unquote(string.slice($val, 2));
|
|
278
284
|
}
|
|
279
285
|
|
|
280
286
|
// RFS mixin
|