wave-ui 3.28.0 → 4.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/.nojekyll +0 -0
- package/dist/types/types/$waveui.d.ts +15 -1
- package/dist/types/types/colors.d.ts +2 -0
- package/dist/types/types/components/WAccordion.d.ts +92 -6
- package/dist/types/types/components/WAutocomplete.d.ts +437 -0
- package/dist/types/types/components/WCheckbox.d.ts +34 -0
- package/dist/types/types/components/WCheckboxes.d.ts +30 -0
- package/dist/types/types/components/WInput.d.ts +34 -0
- package/dist/types/types/components/WMenu.d.ts +14 -7
- package/dist/types/types/components/WRadio.d.ts +34 -0
- package/dist/types/types/components/WRadios.d.ts +30 -0
- package/dist/types/types/components/WSelect.d.ts +34 -0
- package/dist/types/types/components/WSwitch.d.ts +34 -0
- package/dist/types/types/components/WTable.d.ts +7 -0
- package/dist/types/types/components/WTooltip.d.ts +22 -8
- package/dist/types/types/components/WTransitions.d.ts +104 -0
- package/dist/types/types/components/WTransitions.js +2 -0
- package/dist/types/types/components/WTree.d.ts +7 -0
- package/dist/types/types/components/index.d.ts +2 -1
- package/dist/types/types/index.d.ts +1 -0
- package/dist/types/types/mixins/detachable.d.ts +7 -0
- package/dist/types/types/mixins/detachable.js +2 -0
- package/dist/wave-ui.cjs.js +3 -3
- package/dist/wave-ui.css +1 -1
- package/dist/wave-ui.esm.js +1743 -1365
- package/dist/wave-ui.umd.js +3 -3
- package/package.json +1 -1
- package/src/wave-ui/components/index.js +0 -1
- package/src/wave-ui/components/transitions/w-transition-bounce.vue +2 -1
- package/src/wave-ui/components/transitions/w-transition-expand.vue +3 -2
- package/src/wave-ui/components/transitions/w-transition-fade.vue +2 -1
- package/src/wave-ui/components/transitions/w-transition-scale-fade.vue +2 -1
- package/src/wave-ui/components/transitions/w-transition-scale.vue +2 -1
- package/src/wave-ui/components/transitions/w-transition-slide-fade.vue +2 -1
- package/src/wave-ui/components/transitions/w-transition-slide.vue +2 -1
- package/src/wave-ui/components/transitions/w-transition-twist.vue +2 -1
- package/src/wave-ui/components/w-accordion/index.vue +10 -5
- package/src/wave-ui/components/w-accordion/item.vue +29 -14
- package/src/wave-ui/components/w-alert.vue +27 -29
- package/src/wave-ui/components/w-autocomplete.vue +626 -192
- package/src/wave-ui/components/w-badge.vue +54 -53
- package/src/wave-ui/components/w-breadcrumbs.vue +7 -9
- package/src/wave-ui/components/w-button/button.vue +21 -23
- package/src/wave-ui/components/w-button/index.vue +4 -4
- package/src/wave-ui/components/w-card.vue +8 -7
- package/src/wave-ui/components/w-checkbox.vue +31 -11
- package/src/wave-ui/components/w-checkboxes.vue +21 -3
- package/src/wave-ui/components/w-confirm.vue +22 -22
- package/src/wave-ui/components/w-dialog.vue +1 -1
- package/src/wave-ui/components/w-divider.vue +5 -5
- package/src/wave-ui/components/w-drawer.vue +3 -3
- package/src/wave-ui/components/w-form-element.vue +2 -2
- package/src/wave-ui/components/w-icon.vue +12 -14
- package/src/wave-ui/components/w-image.vue +1 -1
- package/src/wave-ui/components/w-input.vue +43 -25
- package/src/wave-ui/components/w-list.vue +11 -12
- package/src/wave-ui/components/w-menu.vue +57 -55
- package/src/wave-ui/components/w-notification.vue +4 -4
- package/src/wave-ui/components/w-progress.vue +6 -7
- package/src/wave-ui/components/w-radio.vue +32 -7
- package/src/wave-ui/components/w-radios.vue +28 -3
- package/src/wave-ui/components/w-rating.vue +7 -9
- package/src/wave-ui/components/w-scrollable.vue +4 -4
- package/src/wave-ui/components/w-select.vue +119 -101
- package/src/wave-ui/components/w-slider.vue +26 -26
- package/src/wave-ui/components/w-spinner.vue +5 -7
- package/src/wave-ui/components/w-switch.vue +71 -47
- package/src/wave-ui/components/w-table.vue +69 -36
- package/src/wave-ui/components/w-tabs/index.vue +21 -24
- package/src/wave-ui/components/w-tag.vue +35 -38
- package/src/wave-ui/components/w-textarea.vue +22 -22
- package/src/wave-ui/components/w-timeline.vue +6 -6
- package/src/wave-ui/components/w-toolbar.vue +8 -8
- package/src/wave-ui/components/w-tooltip.vue +30 -25
- package/src/wave-ui/components/w-tree.vue +35 -16
- package/src/wave-ui/core.js +9 -1
- package/src/wave-ui/mixins/detachable.js +118 -55
- package/src/wave-ui/mixins/ripple.js +2 -2
- package/src/wave-ui/scss/_base.scss +82 -17
- package/src/wave-ui/scss/_colors.scss +6 -75
- package/src/wave-ui/scss/_layout.scss +39 -47
- package/src/wave-ui/scss/_ripple.scss +2 -2
- package/src/wave-ui/scss/_transitions.scss +19 -19
- package/src/wave-ui/scss/_typography.scss +8 -9
- package/src/wave-ui/scss/variables/_mixins.scss +24 -25
- package/src/wave-ui/scss/variables/_variables.scss +4 -149
- package/src/wave-ui/utils/colors.js +7 -4
- package/src/wave-ui/utils/config.js +3 -4
- package/src/wave-ui/utils/dynamic-css.js +42 -20
- package/src/wave-ui/utils/ripple.js +3 -2
- package/dist/types/types/components/WApp.d.ts +0 -83
- package/src/wave-ui/components/w-app.vue +0 -24
- /package/dist/types/types/components/{WApp.js → WAutocomplete.js} +0 -0
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
@use "sass:math";
|
|
2
1
|
@use 'variables' as *;
|
|
3
2
|
|
|
4
3
|
// All these CSS classes will not be generated if the $use-layout-classes is set to false.
|
|
@@ -73,18 +72,18 @@
|
|
|
73
72
|
// Borders (from 0 to 6), radii (from 0 to 6 + `m` for max).
|
|
74
73
|
// ----------------------------------------------
|
|
75
74
|
@for $i from 1 through 6 {
|
|
76
|
-
.bd#{$i} {border: $i
|
|
75
|
+
.bd#{$i} {border: #{$i}px solid var(--w-border-color);}
|
|
77
76
|
}
|
|
78
|
-
.bdx1 {border-left:
|
|
79
|
-
.bdy1 {border-top:
|
|
80
|
-
.bdl1 {border-left:
|
|
81
|
-
.bdr1 {border-right:
|
|
82
|
-
.bdt1 {border-top:
|
|
83
|
-
.bdb1 {border-bottom:
|
|
77
|
+
.bdx1 {border-left: var(--w-border);border-right: var(--w-border);}
|
|
78
|
+
.bdy1 {border-top: var(--w-border);border-bottom: var(--w-border);}
|
|
79
|
+
.bdl1 {border-left: var(--w-border);}
|
|
80
|
+
.bdr1 {border-right: var(--w-border);}
|
|
81
|
+
.bdt1 {border-top: var(--w-border);}
|
|
82
|
+
.bdb1 {border-bottom: var(--w-border);}
|
|
84
83
|
.bd0 {border: none;}
|
|
85
84
|
|
|
86
85
|
@for $i from 1 through 6 {
|
|
87
|
-
.bdrs#{$i} {border-radius:
|
|
86
|
+
.bdrs#{$i} {border-radius: calc(#{$i} * var(--w-base-increment));}
|
|
88
87
|
}
|
|
89
88
|
.bdrsr {border-radius: 999em;}
|
|
90
89
|
.bdrsm {border-radius: 100%;}
|
|
@@ -95,36 +94,33 @@
|
|
|
95
94
|
// ----------------------------------------------
|
|
96
95
|
@for $i from -6 through -1 {
|
|
97
96
|
.sh#{$i} {
|
|
98
|
-
box-shadow:
|
|
97
|
+
box-shadow: var(--w-shadow-n#{-1 * $i});
|
|
99
98
|
}
|
|
100
99
|
}
|
|
101
100
|
@for $i from 1 through 6 {
|
|
102
101
|
.sh#{$i} {
|
|
103
|
-
box-shadow:
|
|
104
|
-
math.round($base-increment * divide($i, 4)) math.round($base-increment * divide($i, 4)) math.round($i * $base-increment) rgba(#000, max(0.15 * divide($i, 2), 0.15));
|
|
102
|
+
box-shadow: var(--w-shadow-#{$i});
|
|
105
103
|
}
|
|
106
104
|
}
|
|
107
|
-
.sh0 {box-shadow:
|
|
105
|
+
.sh0 {box-shadow: var(--w-shadow-0);}
|
|
108
106
|
// ----------------------------------------------
|
|
109
107
|
|
|
110
108
|
// Spaces.
|
|
111
109
|
// ----------------------------------------------
|
|
112
110
|
// Margin.
|
|
113
111
|
@for $i from 0 through 12 {
|
|
114
|
-
$
|
|
115
|
-
.ma
|
|
116
|
-
@if ($i > 0) {.ma-#{$i} {margin: -$number;}}
|
|
112
|
+
.ma#{$i} {margin: calc(#{$i} * var(--w-base-increment));}
|
|
113
|
+
@if ($i > 0) {.ma-#{$i} {margin: calc(-#{$i} * var(--w-base-increment));}}
|
|
117
114
|
}
|
|
118
115
|
.maa {margin: auto;}
|
|
119
116
|
.ma0 {margin: 0;}
|
|
120
117
|
|
|
121
118
|
@for $i from 0 through 12 {
|
|
122
|
-
$
|
|
123
|
-
.
|
|
124
|
-
.my#{$i} {margin-top: $number;margin-bottom: $number;}
|
|
119
|
+
.mx#{$i} {margin-left: calc(#{$i} * var(--w-base-increment));margin-right: calc(#{$i} * var(--w-base-increment));}
|
|
120
|
+
.my#{$i} {margin-top: calc(#{$i} * var(--w-base-increment));margin-bottom: calc(#{$i} * var(--w-base-increment));}
|
|
125
121
|
@if ($i > 0) {
|
|
126
|
-
.mx-#{$i} {margin-left:
|
|
127
|
-
.my-#{$i} {margin-top:
|
|
122
|
+
.mx-#{$i} {margin-left: calc(-#{$i} * var(--w-base-increment));margin-right: calc(-#{$i} * var(--w-base-increment));}
|
|
123
|
+
.my-#{$i} {margin-top: calc(-#{$i} * var(--w-base-increment));margin-bottom: calc(-#{$i} * var(--w-base-increment));}
|
|
128
124
|
}
|
|
129
125
|
}
|
|
130
126
|
.mxa {margin-left: auto;margin-right: auto;}
|
|
@@ -133,16 +129,15 @@
|
|
|
133
129
|
.my0 {margin-top: 0;margin-bottom: 0;}
|
|
134
130
|
|
|
135
131
|
@for $i from 0 through 12 {
|
|
136
|
-
$
|
|
137
|
-
.
|
|
138
|
-
.
|
|
139
|
-
.
|
|
140
|
-
.ml#{$i} {margin-left: $number;}
|
|
132
|
+
.mt#{$i} {margin-top: calc(#{$i} * var(--w-base-increment));}
|
|
133
|
+
.mr#{$i} {margin-right: calc(#{$i} * var(--w-base-increment));}
|
|
134
|
+
.mb#{$i} {margin-bottom: calc(#{$i} * var(--w-base-increment));}
|
|
135
|
+
.ml#{$i} {margin-left: calc(#{$i} * var(--w-base-increment));}
|
|
141
136
|
@if ($i > 0) {
|
|
142
|
-
.mt-#{$i} {margin-top:
|
|
143
|
-
.mr-#{$i} {margin-right:
|
|
144
|
-
.mb-#{$i} {margin-bottom:
|
|
145
|
-
.ml-#{$i} {margin-left:
|
|
137
|
+
.mt-#{$i} {margin-top: calc(-#{$i} * var(--w-base-increment));}
|
|
138
|
+
.mr-#{$i} {margin-right: calc(-#{$i} * var(--w-base-increment));}
|
|
139
|
+
.mb-#{$i} {margin-bottom: calc(-#{$i} * var(--w-base-increment));}
|
|
140
|
+
.ml-#{$i} {margin-left: calc(-#{$i} * var(--w-base-increment));}
|
|
146
141
|
}
|
|
147
142
|
}
|
|
148
143
|
.mta {margin-top: auto;}
|
|
@@ -156,25 +151,22 @@
|
|
|
156
151
|
|
|
157
152
|
// Padding.
|
|
158
153
|
@for $i from 1 through 12 {
|
|
159
|
-
$
|
|
160
|
-
.pa#{$i} {padding: $number;}
|
|
154
|
+
.pa#{$i} {padding: calc(#{$i} * var(--w-base-increment));}
|
|
161
155
|
}
|
|
162
156
|
.pa0 {padding: 0;}
|
|
163
157
|
|
|
164
158
|
@for $i from 0 through 12 {
|
|
165
|
-
$
|
|
166
|
-
.
|
|
167
|
-
.py#{$i} {padding-top: $number;padding-bottom: $number;}
|
|
159
|
+
.px#{$i} {padding-left: calc(#{$i} * var(--w-base-increment));padding-right: calc(#{$i} * var(--w-base-increment));}
|
|
160
|
+
.py#{$i} {padding-top: calc(#{$i} * var(--w-base-increment));padding-bottom: calc(#{$i} * var(--w-base-increment));}
|
|
168
161
|
}
|
|
169
162
|
.px0 {padding-left: 0;padding-right: 0;}
|
|
170
163
|
.py0 {padding-top: 0;padding-bottom: 0;}
|
|
171
164
|
|
|
172
165
|
@for $i from 0 through 12 {
|
|
173
|
-
$
|
|
174
|
-
.
|
|
175
|
-
.
|
|
176
|
-
.
|
|
177
|
-
.pl#{$i} {padding-left: $number;}
|
|
166
|
+
.pt#{$i} {padding-top: calc(#{$i} * var(--w-base-increment));}
|
|
167
|
+
.pr#{$i} {padding-right: calc(#{$i} * var(--w-base-increment));}
|
|
168
|
+
.pb#{$i} {padding-bottom: calc(#{$i} * var(--w-base-increment));}
|
|
169
|
+
.pl#{$i} {padding-left: calc(#{$i} * var(--w-base-increment));}
|
|
178
170
|
}
|
|
179
171
|
.pt0 {padding-top: 0;}
|
|
180
172
|
.pr0 {padding-right: 0;}
|
|
@@ -184,14 +176,14 @@
|
|
|
184
176
|
|
|
185
177
|
// Sizes.
|
|
186
178
|
// ----------------------------------------------
|
|
187
|
-
// In all the sizes below,
|
|
179
|
+
// In all the sizes below, round(nearest, …, 1px) matches former Sass rounding for px base sizes.
|
|
188
180
|
// Different heights with a mix of odd and even numbers will misalign
|
|
189
181
|
// when vertically centering (vertical-align or align-items center).
|
|
190
|
-
.size--xs {font-size:
|
|
191
|
-
.size--sm {font-size:
|
|
192
|
-
.size--md {font-size:
|
|
193
|
-
.size--lg {font-size:
|
|
194
|
-
.size--xl {font-size:
|
|
182
|
+
.size--xs {font-size: round(nearest, calc(0.8 * var(--w-base-font-size)), 1px);}
|
|
183
|
+
.size--sm {font-size: round(nearest, calc(0.9 * var(--w-base-font-size)), 1px);}
|
|
184
|
+
.size--md {font-size: round(nearest, calc(1 * var(--w-base-font-size)), 1px);}
|
|
185
|
+
.size--lg {font-size: round(nearest, calc(1.2 * var(--w-base-font-size)), 1px);}
|
|
186
|
+
.size--xl {font-size: round(nearest, calc(1.4 * var(--w-base-font-size)), 1px);}
|
|
195
187
|
// ----------------------------------------------
|
|
196
188
|
|
|
197
189
|
// Grid system.
|
|
@@ -228,6 +220,6 @@
|
|
|
228
220
|
}
|
|
229
221
|
|
|
230
222
|
@for $i from 1 through 12 {
|
|
231
|
-
.w-flex.gap#{$i}, .w-grid.gap#{$i} {gap:
|
|
223
|
+
.w-flex.gap#{$i}, .w-grid.gap#{$i} {gap: calc(#{$i} * var(--w-base-increment));}
|
|
232
224
|
}
|
|
233
225
|
.w-flex.gap0, .w-grid.gap0 {gap: 0;}
|
|
@@ -20,13 +20,13 @@
|
|
|
20
20
|
transform: scale(0);
|
|
21
21
|
opacity: 0.5;
|
|
22
22
|
// currentColor is often invisible on filled buttons (e.g. white on white); use a neutral ink.
|
|
23
|
-
background-color:
|
|
23
|
+
background-color: color-mix(in srgb, #000 22%, transparent);
|
|
24
24
|
will-change: transform, opacity;
|
|
25
25
|
animation: w-ripple-ink-expand 0.65s ease-out forwards;
|
|
26
26
|
}
|
|
27
27
|
|
|
28
28
|
html[data-theme='dark'] .w-ripple__ink {
|
|
29
|
-
background-color:
|
|
29
|
+
background-color: color-mix(in srgb, #fff 20%, transparent);
|
|
30
30
|
}
|
|
31
31
|
|
|
32
32
|
@keyframes w-ripple-ink-expand {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
@use 'variables' as *;
|
|
2
2
|
|
|
3
|
-
$fast-out-slow-in:
|
|
3
|
+
$fast-out-slow-in: var(--w-transition-timing-fast-out-slow-in);
|
|
4
4
|
|
|
5
5
|
// Fade.
|
|
6
6
|
// --------------------------------------------------------
|
|
7
|
-
.fade-enter-active {animation: w-fade
|
|
8
|
-
.fade-leave-active {animation: w-fade
|
|
7
|
+
.fade-enter-active {animation: w-fade var(--w-transition-duration);}
|
|
8
|
+
.fade-leave-active {animation: w-fade var(--w-transition-duration) reverse;}
|
|
9
9
|
@keyframes w-fade {
|
|
10
10
|
0% {opacity: 0;}
|
|
11
11
|
100% {opacity: 1;}
|
|
@@ -15,7 +15,7 @@ $fast-out-slow-in: cubic-bezier(0.4, 0, 0.2, 1);
|
|
|
15
15
|
// Slide-right: translate x from left to right.
|
|
16
16
|
// --------------------------------------------------------
|
|
17
17
|
.slide-right-enter-active, .slide-right-leave-active {
|
|
18
|
-
transition:
|
|
18
|
+
transition: var(--w-transition-duration) $fast-out-slow-in;
|
|
19
19
|
transition-property: transform, left, margin-left;
|
|
20
20
|
transform: translateX(0%);
|
|
21
21
|
}
|
|
@@ -29,7 +29,7 @@ $fast-out-slow-in: cubic-bezier(0.4, 0, 0.2, 1);
|
|
|
29
29
|
// Slide-left: translate x from right to left.
|
|
30
30
|
// --------------------------------------------------------
|
|
31
31
|
.slide-left-enter-active, .slide-left-leave-active {
|
|
32
|
-
transition:
|
|
32
|
+
transition: var(--w-transition-duration);
|
|
33
33
|
transition-property: transform, right, margin-right;
|
|
34
34
|
transform: translateX(0%);
|
|
35
35
|
}
|
|
@@ -43,7 +43,7 @@ $fast-out-slow-in: cubic-bezier(0.4, 0, 0.2, 1);
|
|
|
43
43
|
// Slide-down: translate y from top to bottom.
|
|
44
44
|
// --------------------------------------------------------
|
|
45
45
|
.slide-down-enter-active, .slide-down-leave-active {
|
|
46
|
-
transition: transform
|
|
46
|
+
transition: transform var(--w-transition-duration) $fast-out-slow-in;
|
|
47
47
|
transition-property: transform, top, margin-top;
|
|
48
48
|
transform: translateY(0%);
|
|
49
49
|
}
|
|
@@ -57,7 +57,7 @@ $fast-out-slow-in: cubic-bezier(0.4, 0, 0.2, 1);
|
|
|
57
57
|
// Slide-up: translate y from bottom to top.
|
|
58
58
|
// --------------------------------------------------------
|
|
59
59
|
.slide-up-enter-active, .slide-up-leave-active {
|
|
60
|
-
transition: transform
|
|
60
|
+
transition: transform var(--w-transition-duration) $fast-out-slow-in;
|
|
61
61
|
transition-property: transform, bottom, margin-bottom;
|
|
62
62
|
transform: translateY(0%);
|
|
63
63
|
}
|
|
@@ -71,7 +71,7 @@ $fast-out-slow-in: cubic-bezier(0.4, 0, 0.2, 1);
|
|
|
71
71
|
// Slide-fade-left.
|
|
72
72
|
// --------------------------------------------------------
|
|
73
73
|
.slide-fade-left-enter-active, .slide-fade-left-leave-active {
|
|
74
|
-
transition: all
|
|
74
|
+
transition: all var(--w-transition-duration) $fast-out-slow-in;
|
|
75
75
|
}
|
|
76
76
|
.slide-fade-left-enter-from, .slide-fade-left-leave-to {
|
|
77
77
|
transform: translateX(12px);
|
|
@@ -81,7 +81,7 @@ $fast-out-slow-in: cubic-bezier(0.4, 0, 0.2, 1);
|
|
|
81
81
|
// Slide-fade-right.
|
|
82
82
|
// --------------------------------------------------------
|
|
83
83
|
.slide-fade-right-enter-active, .slide-fade-right-leave-active {
|
|
84
|
-
transition: all
|
|
84
|
+
transition: all var(--w-transition-duration) $fast-out-slow-in;
|
|
85
85
|
}
|
|
86
86
|
.slide-fade-right-enter-from, .slide-fade-right-leave-to {
|
|
87
87
|
transform: translateX(-12px);
|
|
@@ -92,7 +92,7 @@ $fast-out-slow-in: cubic-bezier(0.4, 0, 0.2, 1);
|
|
|
92
92
|
// Slide-fade-up.
|
|
93
93
|
// --------------------------------------------------------
|
|
94
94
|
.slide-fade-up-enter-active, .slide-fade-up-leave-active {
|
|
95
|
-
transition: all
|
|
95
|
+
transition: all var(--w-transition-duration) $fast-out-slow-in;
|
|
96
96
|
}
|
|
97
97
|
.slide-fade-up-enter-from, .slide-fade-up-leave-to {
|
|
98
98
|
transform: translateY(12px);
|
|
@@ -103,7 +103,7 @@ $fast-out-slow-in: cubic-bezier(0.4, 0, 0.2, 1);
|
|
|
103
103
|
// Slide-fade-down.
|
|
104
104
|
// --------------------------------------------------------
|
|
105
105
|
.slide-fade-down-enter-active, .slide-fade-down-leave-active {
|
|
106
|
-
transition: all
|
|
106
|
+
transition: all var(--w-transition-duration) $fast-out-slow-in;
|
|
107
107
|
}
|
|
108
108
|
.slide-fade-down-enter-from, .slide-fade-down-leave-to {
|
|
109
109
|
transform: translateY(-12px);
|
|
@@ -113,8 +113,8 @@ $fast-out-slow-in: cubic-bezier(0.4, 0, 0.2, 1);
|
|
|
113
113
|
|
|
114
114
|
// Scale.
|
|
115
115
|
// --------------------------------------------------------
|
|
116
|
-
.scale-enter-active {animation: w-scale
|
|
117
|
-
.scale-leave-active {animation: w-scale
|
|
116
|
+
.scale-enter-active {animation: w-scale var(--w-transition-duration);}
|
|
117
|
+
.scale-leave-active {animation: w-scale var(--w-transition-duration) reverse;}
|
|
118
118
|
@keyframes w-scale {
|
|
119
119
|
0% {transform: scale(0);}
|
|
120
120
|
100% {transform: scale(1);}
|
|
@@ -123,8 +123,8 @@ $fast-out-slow-in: cubic-bezier(0.4, 0, 0.2, 1);
|
|
|
123
123
|
|
|
124
124
|
// Scale-fade.
|
|
125
125
|
// --------------------------------------------------------
|
|
126
|
-
.scale-fade-enter-active {animation: w-scale-fade
|
|
127
|
-
.scale-fade-leave-active {animation: w-scale-fade
|
|
126
|
+
.scale-fade-enter-active {animation: w-scale-fade var(--w-transition-duration);}
|
|
127
|
+
.scale-fade-leave-active {animation: w-scale-fade var(--w-transition-duration) reverse;}
|
|
128
128
|
@keyframes w-scale-fade {
|
|
129
129
|
0% {transform: scale(0.8);opacity: 0;}
|
|
130
130
|
100% {transform: scale(1);opacity: 1;}
|
|
@@ -133,8 +133,8 @@ $fast-out-slow-in: cubic-bezier(0.4, 0, 0.2, 1);
|
|
|
133
133
|
|
|
134
134
|
// Bounce.
|
|
135
135
|
// --------------------------------------------------------
|
|
136
|
-
.bounce-enter-active {animation: w-bounce (
|
|
137
|
-
.bounce-leave-active {animation: w-bounce (
|
|
136
|
+
.bounce-enter-active {animation: w-bounce calc(var(--w-transition-duration) + 0.05s);}
|
|
137
|
+
.bounce-leave-active {animation: w-bounce calc(var(--w-transition-duration) + 0.05s) reverse;}
|
|
138
138
|
@keyframes w-bounce {
|
|
139
139
|
0% {transform: scale(0.7);opacity: 0;}
|
|
140
140
|
60% {transform: scale(1.1);opacity: 1;}
|
|
@@ -144,8 +144,8 @@ $fast-out-slow-in: cubic-bezier(0.4, 0, 0.2, 1);
|
|
|
144
144
|
|
|
145
145
|
// Twist.
|
|
146
146
|
// --------------------------------------------------------
|
|
147
|
-
.twist-enter-active {animation: w-twist (
|
|
148
|
-
.twist-leave-active {animation: w-twist (
|
|
147
|
+
.twist-enter-active {animation: w-twist calc(var(--w-transition-duration) + 0.25s);}
|
|
148
|
+
.twist-leave-active {animation: w-twist calc(var(--w-transition-duration) + 0.25s) reverse;}
|
|
149
149
|
@keyframes w-twist {
|
|
150
150
|
0% {transform: scale(0) rotate(-70deg);}
|
|
151
151
|
60% {transform: scale(1.03) rotate(6deg);}
|
|
@@ -1,41 +1,40 @@
|
|
|
1
|
-
@use "sass:math";
|
|
2
1
|
@use 'variables' as *;
|
|
3
2
|
|
|
4
3
|
#{$css-scope} {
|
|
5
4
|
.headline, .title1 {
|
|
6
|
-
font-size:
|
|
5
|
+
font-size: calc(2.2 * var(--w-base-font-size));
|
|
7
6
|
font-weight: 100;
|
|
8
7
|
}
|
|
9
8
|
|
|
10
9
|
.title2 {
|
|
11
|
-
font-size:
|
|
10
|
+
font-size: calc(1.7 * var(--w-base-font-size));
|
|
12
11
|
font-weight: 400;
|
|
13
12
|
}
|
|
14
13
|
|
|
15
14
|
.title3 {
|
|
16
|
-
font-size:
|
|
15
|
+
font-size: calc(1.4 * var(--w-base-font-size));
|
|
17
16
|
font-weight: 400;
|
|
18
17
|
}
|
|
19
18
|
|
|
20
19
|
.title4 {
|
|
21
|
-
font-size:
|
|
20
|
+
font-size: calc(1.25 * var(--w-base-font-size));
|
|
22
21
|
font-weight: 400;
|
|
23
22
|
}
|
|
24
23
|
|
|
25
24
|
.title5 {
|
|
26
|
-
font-size:
|
|
25
|
+
font-size: calc(1.1 * var(--w-base-font-size));
|
|
27
26
|
font-weight: 600;
|
|
28
27
|
}
|
|
29
28
|
|
|
30
29
|
.body {
|
|
31
|
-
font-size:
|
|
30
|
+
font-size: var(--w-base-font-size);
|
|
32
31
|
font-weight: normal;
|
|
33
32
|
}
|
|
34
33
|
|
|
35
34
|
.caption {
|
|
36
|
-
font-size:
|
|
35
|
+
font-size: calc(0.85 * var(--w-base-font-size));
|
|
37
36
|
font-style: italic;
|
|
38
|
-
color:
|
|
37
|
+
color: var(--w-caption-color);
|
|
39
38
|
}
|
|
40
39
|
|
|
41
40
|
.text-upper {text-transform: uppercase;}
|
|
@@ -1,33 +1,32 @@
|
|
|
1
|
-
@use "sass:map";
|
|
2
|
-
@use "variables" as *;
|
|
3
|
-
|
|
4
1
|
// This allows each UI component to be used in dark or light theme regardless of the global theme.
|
|
5
2
|
@mixin themeable {
|
|
6
3
|
// Will force the light style on this component.
|
|
7
4
|
&--light {
|
|
8
|
-
--w-base-bg-color: #
|
|
9
|
-
--w-base-color: #
|
|
10
|
-
--w-contrast-bg-color: #
|
|
11
|
-
--w-contrast-color: #
|
|
12
|
-
--w-
|
|
13
|
-
|
|
5
|
+
--w-base-bg-color: #fff;
|
|
6
|
+
--w-base-color: #000;
|
|
7
|
+
--w-contrast-bg-color: #000;
|
|
8
|
+
--w-contrast-color: #fff;
|
|
9
|
+
--w-caption-color: #a0a0a0;
|
|
10
|
+
--w-disabled-color: #ccc;
|
|
11
|
+
color: var(--w-base-color-muted);
|
|
14
12
|
}
|
|
15
13
|
// Will force the dark style on this component.
|
|
16
14
|
&--dark {
|
|
17
|
-
--w-base-bg-color: #
|
|
18
|
-
--w-base-color: #
|
|
19
|
-
--w-contrast-bg-color: #
|
|
20
|
-
--w-contrast-color: #
|
|
21
|
-
--w-
|
|
22
|
-
|
|
15
|
+
--w-base-bg-color: #222;
|
|
16
|
+
--w-base-color: #fff;
|
|
17
|
+
--w-contrast-bg-color: #fff;
|
|
18
|
+
--w-contrast-color: #000;
|
|
19
|
+
--w-caption-color: #6e6e6e;
|
|
20
|
+
--w-disabled-color: #4a4a4a;
|
|
21
|
+
color: var(--w-base-color-muted);
|
|
23
22
|
}
|
|
24
23
|
}
|
|
25
24
|
|
|
26
|
-
@mixin default-transition($duration:
|
|
25
|
+
@mixin default-transition($duration: var(--w-transition-duration), $delay: 0s) {
|
|
27
26
|
transition: $duration $delay ease-in-out;
|
|
28
27
|
}
|
|
29
28
|
|
|
30
|
-
@mixin out-back-transition($duration:
|
|
29
|
+
@mixin out-back-transition($duration: var(--w-transition-duration), $delay: 0s) {
|
|
31
30
|
transition: $duration $delay cubic-bezier(0.18, 0.89, 0.32, 1.28);
|
|
32
31
|
}
|
|
33
32
|
|
|
@@ -78,21 +77,21 @@
|
|
|
78
77
|
|
|
79
78
|
&#{$selector}--align-top:before {
|
|
80
79
|
transform: none;
|
|
81
|
-
top: (2 *
|
|
80
|
+
top: calc(2 * var(--w-base-increment) - 1px);
|
|
82
81
|
}
|
|
83
82
|
&#{$selector}--align-bottom:before {
|
|
84
83
|
transform: none;
|
|
85
84
|
top: auto;
|
|
86
|
-
bottom: (2 *
|
|
85
|
+
bottom: calc(2 * var(--w-base-increment) - 1px);
|
|
87
86
|
}
|
|
88
87
|
&#{$selector}--align-left:before {
|
|
89
88
|
transform: none;
|
|
90
|
-
left: (2 *
|
|
89
|
+
left: calc(2 * var(--w-base-increment) - 1px);
|
|
91
90
|
}
|
|
92
91
|
&#{$selector}--align-right:before {
|
|
93
92
|
transform: none;
|
|
94
93
|
left: auto;
|
|
95
|
-
right: (2 *
|
|
94
|
+
right: calc(2 * var(--w-base-increment) - 1px);
|
|
96
95
|
}
|
|
97
96
|
}
|
|
98
97
|
|
|
@@ -129,8 +128,8 @@
|
|
|
129
128
|
transform: translateY(-50%);
|
|
130
129
|
}
|
|
131
130
|
|
|
132
|
-
&#{$selector}--align-top:after {transform: none;top: 2 *
|
|
133
|
-
&#{$selector}--align-bottom:after {transform: none;top: auto;bottom: 2 *
|
|
134
|
-
&#{$selector}--align-left:after {transform: none;left: 2 *
|
|
135
|
-
&#{$selector}--align-right:after {transform: none;left: auto;right: 2 *
|
|
131
|
+
&#{$selector}--align-top:after {transform: none;top: calc(2 * var(--w-base-increment));}
|
|
132
|
+
&#{$selector}--align-bottom:after {transform: none;top: auto;bottom: calc(2 * var(--w-base-increment));}
|
|
133
|
+
&#{$selector}--align-left:after {transform: none;left: calc(2 * var(--w-base-increment));}
|
|
134
|
+
&#{$selector}--align-right:after {transform: none;left: auto;right: calc(2 * var(--w-base-increment));}
|
|
136
135
|
}
|
|
@@ -1,155 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
@return math.div($a, $b);
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
// THEME COLORS.
|
|
9
|
-
// ========================================================
|
|
10
|
-
// If you don't need themes, you can leave this as is and override the global defaults.
|
|
11
|
-
$theme-light: (
|
|
12
|
-
base-bg-color: #fff,
|
|
13
|
-
base-color: #000,
|
|
14
|
-
contrast-bg-color: #000,
|
|
15
|
-
contrast-color: #fff,
|
|
16
|
-
caption-color: #a0a0a0,
|
|
17
|
-
disabled-color: #ccc
|
|
18
|
-
) !default;
|
|
19
|
-
|
|
20
|
-
$theme-dark: (
|
|
21
|
-
base-bg-color: #222,
|
|
22
|
-
base-color: #fff,
|
|
23
|
-
contrast-bg-color: #fff,
|
|
24
|
-
contrast-color: #000,
|
|
25
|
-
caption-color: #6e6e6e,
|
|
26
|
-
disabled-color: #4a4a4a
|
|
27
|
-
) !default;
|
|
28
|
-
|
|
29
|
-
// These variables are filled up with the current theme colors for you to use.
|
|
30
|
-
$primary: var(--w-primary-color);
|
|
31
|
-
$secondary: var(--w-secondary-color);
|
|
32
|
-
$base-bg-color: var(--w-base-bg-color);
|
|
33
|
-
$base-color: var(--w-base-color);
|
|
34
|
-
$contrast-bg-color: var(--w-contrast-bg-color);
|
|
35
|
-
$contrast-color: var(--w-contrast-color);
|
|
36
|
-
$caption-color: var(--w-caption-color);
|
|
37
|
-
// When a form element is disabled (checkbox, radio, input, select list).
|
|
38
|
-
$disabled-color: var(--w-disabled-color);
|
|
1
|
+
// Theme palette defaults live as plain CSS on :root[data-theme] in _base.scss
|
|
2
|
+
// and in the themeable mixin (_mixins.scss). Override with CSS, e.g.
|
|
3
|
+
// :root { --w-base-font-size: 16px; } (also drives --w-base-increment on :root)
|
|
4
|
+
// :root[data-theme="light"] { --w-base-bg-color: #fafafa; }
|
|
39
5
|
|
|
40
6
|
// GLOBAL DEFAULTS.
|
|
41
7
|
// ========================================================
|
|
42
8
|
$css-scope: '.w-app' !default; // Allows control on CSS rules priority.
|
|
43
9
|
// True by default. False allows you to use an external CSS library (like Tailwind).
|
|
44
10
|
$use-layout-classes: true !default;
|
|
45
|
-
|
|
46
|
-
$base-font-size: 14px !default; // Must be a px unit.
|
|
47
|
-
$base-increment: math.round(divide($base-font-size, 4)) !default;
|
|
48
|
-
$layout-padding: $base-increment * 4 !default; // Applied on the .content-wrap tag.
|
|
49
|
-
$border-radius: 4px !default;
|
|
50
|
-
$border-color: color-mix(in srgb, var(--w-contrast-bg-color) 12%, transparent) !default;
|
|
51
|
-
$border: 1px solid $border-color !default;
|
|
52
|
-
$transition-duration: 0.25s !default;
|
|
53
|
-
$fast-transition-duration: 0.15s !default;
|
|
54
|
-
$box-shadow: 0 3px 1px -2px rgba(0, 0, 0, 0.2),
|
|
55
|
-
0 2px 2px 0 rgba(0, 0, 0, 0.15),
|
|
56
|
-
0 1px 5px 0 rgba(0, 0, 0, 0.15) !default;
|
|
57
|
-
$form-field-height: math.round(2 * $base-font-size) !default;
|
|
58
|
-
// Always an even number for better vertical alignment. (Used in checkbox, radio, switch)
|
|
59
|
-
$small-form-el-size: math.round(divide(1.3 * $base-font-size, 2)) * 2 !default;
|
|
60
|
-
|
|
61
|
-
// Detachable elements are: w-tooltip, w-menu, w-confirm.
|
|
62
|
-
$detachable-bg-color: $base-bg-color !default;
|
|
63
|
-
$detachable-color: $base-color !default;
|
|
64
|
-
|
|
65
|
-
// COMPONENTS DEFAULTS.
|
|
66
|
-
// ========================================================
|
|
67
|
-
// w-confirm.
|
|
68
|
-
// --------------------------------------------------------
|
|
69
|
-
$confirm-bg-color: $detachable-bg-color !default;
|
|
70
|
-
$confirm-color: $detachable-color !default;
|
|
71
|
-
// --------------------------------------------------------
|
|
72
|
-
|
|
73
|
-
// w-dialog.
|
|
74
|
-
// --------------------------------------------------------
|
|
75
|
-
$dialog-bg-color: $base-bg-color !default;
|
|
76
|
-
// --------------------------------------------------------
|
|
77
|
-
|
|
78
|
-
// w-divider.
|
|
79
|
-
// --------------------------------------------------------
|
|
80
|
-
$divider-color: $border-color !default;
|
|
81
|
-
// --------------------------------------------------------
|
|
82
|
-
|
|
83
|
-
// w-drawer.
|
|
84
|
-
// --------------------------------------------------------
|
|
85
|
-
$drawer-max-size: 380px !default;
|
|
86
|
-
$drawer-bg-color: $base-bg-color !default;
|
|
87
|
-
// --------------------------------------------------------
|
|
88
|
-
|
|
89
|
-
// w-menu.
|
|
90
|
-
// --------------------------------------------------------
|
|
91
|
-
$menu-bg-color: $detachable-bg-color !default;
|
|
92
|
-
$menu-color: $detachable-color !default;
|
|
93
|
-
// --------------------------------------------------------
|
|
94
|
-
|
|
95
|
-
// w-progress.
|
|
96
|
-
// --------------------------------------------------------
|
|
97
|
-
$progress-bg-color: color-mix(in srgb, var(--w-contrast-bg-color) 15%, transparent) !default;
|
|
98
|
-
// --------------------------------------------------------
|
|
99
|
-
|
|
100
|
-
// w-rating.
|
|
101
|
-
// --------------------------------------------------------
|
|
102
|
-
$rating-bg-color: color-mix(in srgb, var(--w-contrast-bg-color) 25%, transparent) !default;
|
|
103
|
-
// --------------------------------------------------------
|
|
104
|
-
|
|
105
|
-
// w-slider.
|
|
106
|
-
// --------------------------------------------------------
|
|
107
|
-
$slider-height: $base-increment !default;
|
|
108
|
-
$slider-track-color: color-mix(in srgb, var(--w-contrast-bg-color) 15%, transparent) !default;
|
|
109
|
-
$slider-thumb-button-bg-color: $base-bg-color !default;
|
|
110
|
-
$slider-thumb-label-bg-color: $base-bg-color !default;
|
|
111
|
-
$slider-thumb-label-color: color-mix(in srgb, var(--w-base-color) 75%, transparent) !default;
|
|
112
|
-
$slider-step-label-bg-color: color-mix(in srgb, var(--w-contrast-bg-color) 20%, transparent) !default;
|
|
113
|
-
$slider-step-label-color: color-mix(in srgb, var(--w-base-color) 50%, transparent) !default;
|
|
114
|
-
|
|
115
|
-
// w-switch.
|
|
116
|
-
// --------------------------------------------------------
|
|
117
|
-
$switch-inactive-color: color-mix(in srgb, var(--w-contrast-bg-color) 25%, transparent) !default;
|
|
118
|
-
$switch-thumb-color: $base-bg-color !default;
|
|
119
|
-
// --------------------------------------------------------
|
|
120
|
-
|
|
121
|
-
// w-table.
|
|
122
|
-
// --------------------------------------------------------
|
|
123
|
-
$table-tr-odd-color: color-mix(in srgb, var(--w-contrast-bg-color) 2%, transparent) !default;
|
|
124
|
-
$table-tr-hover-color: color-mix(in srgb, var(--w-contrast-bg-color) 5%, transparent) !default;
|
|
125
|
-
$table-color: color-mix(in srgb, var(--w-contrast-color) 70%, transparent) !default;
|
|
126
|
-
// --------------------------------------------------------
|
|
127
|
-
|
|
128
|
-
// w-textarea.
|
|
129
|
-
// --------------------------------------------------------
|
|
130
|
-
$textarea-line-height: 1.2 !default;
|
|
131
|
-
// --------------------------------------------------------
|
|
132
|
-
|
|
133
|
-
// w-timeline.
|
|
134
|
-
// --------------------------------------------------------
|
|
135
|
-
$timeline-bullet-color: $base-bg-color !default;
|
|
136
|
-
$timeline-bg-color: color-mix(in srgb, var(--w-contrast-bg-color) 25%, transparent) !default;
|
|
137
|
-
// --------------------------------------------------------
|
|
138
|
-
|
|
139
|
-
// w-toolbar.
|
|
140
|
-
// --------------------------------------------------------
|
|
141
|
-
$toolbar-max-size: 380px !default;
|
|
142
|
-
$toolbar-bg-color: $base-bg-color !default;
|
|
143
|
-
// --------------------------------------------------------
|
|
144
|
-
|
|
145
|
-
// w-tooltip.
|
|
146
|
-
// --------------------------------------------------------
|
|
147
|
-
$tooltip-bg-color: $detachable-bg-color !default;
|
|
148
|
-
$tooltip-color: $detachable-color !default;
|
|
149
|
-
$tooltip-border-color: $border-color !default;
|
|
150
|
-
// --------------------------------------------------------
|
|
151
|
-
|
|
152
|
-
// w-scrollable.
|
|
153
|
-
// --------------------------------------------------------
|
|
154
|
-
$scrollbar-size: 8px !default;
|
|
155
|
-
// --------------------------------------------------------
|
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
import { consoleError } from './console'
|
|
2
2
|
|
|
3
|
+
// The built-in palette remains the single source for exact legacy shade values.
|
|
4
|
+
// dynamic-css.js exposes these colors as --w-*-color variables; SCSS color
|
|
5
|
+
// utility classes only reference those variables.
|
|
6
|
+
|
|
3
7
|
/**
|
|
4
8
|
* Generates the color shades for each custom color and status colors for the current theme (only),
|
|
5
9
|
* and save it in the config object.
|
|
@@ -37,11 +41,10 @@ export const flattenColors = (themeColors, colorPalette) => {
|
|
|
37
41
|
const colors = {
|
|
38
42
|
...colorPalette.reduce((obj, color) => {
|
|
39
43
|
obj[color.label] = color.color
|
|
40
|
-
|
|
44
|
+
;(color.shades || []).forEach(color => {
|
|
41
45
|
obj[color.label] = color.color
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
return { ...obj, ...shades }
|
|
46
|
+
})
|
|
47
|
+
return obj
|
|
45
48
|
}, { ...themeColors, ...themeColors.shades })
|
|
46
49
|
}
|
|
47
50
|
delete colors.shades
|
|
@@ -19,15 +19,14 @@ const config = reactive({
|
|
|
19
19
|
// Note: colorShades must be enabled for this to work.
|
|
20
20
|
colorShadeCssVariables: false,
|
|
21
21
|
|
|
22
|
-
//
|
|
23
|
-
// Can't have this option: color palette is generated via SCSS in colors.scss.
|
|
24
|
-
// colorPalette: true,
|
|
22
|
+
// Built-in palette colors and shades always generate CSS variables.
|
|
25
23
|
|
|
26
24
|
breakpointSpaces: false, // Generate margin & padding classes for each breakpoint. E.g. `sm-ma2`.
|
|
27
25
|
// Generate helper classes for each breakpoint.
|
|
28
26
|
// E.g. `sm-text-left`, `xs-hide`.
|
|
29
27
|
breakpointLayoutClasses: true,
|
|
30
|
-
grid: 12
|
|
28
|
+
grid: 12,
|
|
29
|
+
appClasses: '' // Custom CSS classes to add to the .w-app element.
|
|
31
30
|
},
|
|
32
31
|
colors: {
|
|
33
32
|
// Default colors of Wave UI. Can be overridden from the Wave UI user config on init.
|