maverick-wave 5.7.0 → 5.10.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/.claude/skills/mw-maverick-wave/SKILL.md +22 -12
- package/.claude/skills/mw-maverick-wave/examples/angular-services.md +10 -1
- package/.claude/skills/mw-maverick-wave/examples/static-landing-page.md +4 -3
- package/.claude/skills/mw-maverick-wave/references/components.md +23 -9
- package/.claude/skills/mw-maverick-wave/references/javascript.md +1 -1
- package/.claude/skills/mw-maverick-wave/references/layout.md +8 -3
- package/.claude/skills/mw-maverick-wave/references/theming.md +57 -29
- package/CHANGELOG.md +19 -0
- package/README.md +43 -22
- package/index.html +395 -62
- package/maverick-wave.min.css +61 -5
- package/maverick-wave.min.js +1 -1
- package/package.json +2 -2
- package/scripts/verify.js +18 -2
- package/src/js/main.js +24 -5
- package/src/partials/header-container.html +7 -5
- package/src/partials/palette-container.html +176 -66
- package/src/partials/preview-container.html +136 -0
- package/src/partials/utilities-container.html +55 -4
- package/src/scss/abstracts/_functions.scss +31 -3
- package/src/scss/abstracts/_mixins.scss +62 -12
- package/src/scss/abstracts/_variables.scss +47 -21
- package/src/scss/base/_base.scss +101 -8
- package/src/scss/base/_reset.scss +2 -0
- package/src/scss/components/_badge.scss +1 -1
- package/src/scss/components/_buttons.scss +1 -1
- package/src/scss/components/_cards.scss +23 -14
- package/src/scss/components/_dropdown.scss +58 -1
- package/src/scss/components/_kanban.scss +10 -9
- package/src/scss/components/_lang-switch.scss +1 -1
- package/src/scss/components/_localhost-indicator.scss +1 -1
- package/src/scss/components/_modals.scss +13 -1
- package/src/scss/components/_pricing.scss +1 -1
- package/src/scss/components/_progress.scss +9 -5
- package/src/scss/components/_skeleton.scss +1 -1
- package/src/scss/components/_spinners.scss +5 -5
- package/src/scss/components/_stepper.scss +4 -1
- package/src/scss/components/_tabs.scss +28 -8
- package/src/scss/components/_tiles.scss +41 -16
- package/src/scss/components/_timelines.scss +12 -5
- package/src/scss/layout/_main.scss +1 -1
- package/src/scss/layout/_parallax.scss +10 -5
- package/src/scss/utilities/_elevation.scss +23 -0
- package/src/scss/utilities/_touch-targets.scss +1 -1
- package/src/scss/utilities/_variants.scss +115 -6
package/src/scss/base/_base.scss
CHANGED
|
@@ -1,6 +1,17 @@
|
|
|
1
|
+
@use 'sass:list';
|
|
2
|
+
@use 'sass:map';
|
|
1
3
|
@use '../abstracts' as *;
|
|
2
4
|
|
|
3
5
|
@layer mw.base {
|
|
6
|
+
// Registered because it is multiplied into all six duration tokens below: a
|
|
7
|
+
// value that does not parse takes every one of them with it, and a page with
|
|
8
|
+
// no transitions at all is a hard failure for a typo in one line.
|
|
9
|
+
@property --mw-motion-scale {
|
|
10
|
+
syntax: '<number>';
|
|
11
|
+
inherits: true;
|
|
12
|
+
initial-value: 1;
|
|
13
|
+
}
|
|
14
|
+
|
|
4
15
|
// Active theme set and its token prefix, derived from $mw-theme-mode
|
|
5
16
|
$_active-theme: $dark-theme-colors;
|
|
6
17
|
$_active-prefix: 'dark';
|
|
@@ -10,6 +21,14 @@
|
|
|
10
21
|
$_active-prefix: 'light';
|
|
11
22
|
}
|
|
12
23
|
|
|
24
|
+
// Everything light-dark() can resolve on its own - see $theme-non-colors
|
|
25
|
+
$_theme-colors: ();
|
|
26
|
+
@each $name, $value in $dark-theme-colors {
|
|
27
|
+
@if not list.index($theme-non-colors, $name) {
|
|
28
|
+
$_theme-colors: map.set($_theme-colors, $name, $value);
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
13
32
|
// CSS Variables for theming and overriding
|
|
14
33
|
:root {
|
|
15
34
|
// Brand and neutral colors
|
|
@@ -37,13 +56,19 @@
|
|
|
37
56
|
--mw-light-#{$name}: #{$value};
|
|
38
57
|
}
|
|
39
58
|
|
|
40
|
-
// The scale lives in the variables file - these are the runtime knobs
|
|
41
|
-
--mw-
|
|
42
|
-
--mw-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
--mw-duration-
|
|
46
|
-
|
|
59
|
+
// The scale lives in the variables file - these are the runtime knobs.
|
|
60
|
+
// Multiplied through --mw-motion-scale so one number retunes the page's
|
|
61
|
+
// tempo, the way --mw-radius-scale does for its corners: the six stand in a
|
|
62
|
+
// fixed ratio to each other and have to move together. The reduced-motion
|
|
63
|
+
// block below writes plain 1ms over the top, untouched by any of this.
|
|
64
|
+
--mw-duration-instant: calc(
|
|
65
|
+
#{$duration-instant} * var(--mw-motion-scale, 1)
|
|
66
|
+
);
|
|
67
|
+
--mw-duration-fast: calc(#{$duration-fast} * var(--mw-motion-scale, 1));
|
|
68
|
+
--mw-duration-base: calc(#{$duration-base} * var(--mw-motion-scale, 1));
|
|
69
|
+
--mw-duration-slow: calc(#{$duration-slow} * var(--mw-motion-scale, 1));
|
|
70
|
+
--mw-duration-slower: calc(#{$duration-slower} * var(--mw-motion-scale, 1));
|
|
71
|
+
--mw-duration-zoom: calc(#{$duration-zoom} * var(--mw-motion-scale, 1));
|
|
47
72
|
--mw-ease-out: #{$ease-out};
|
|
48
73
|
--mw-ease-in-out: #{$ease-in-out};
|
|
49
74
|
--mw-ease-spring: #{$ease-spring};
|
|
@@ -54,6 +79,10 @@
|
|
|
54
79
|
// Same list, for a state that should feel instant rather than animated
|
|
55
80
|
--mw-transition-fast: #{transition-list('--mw-duration-fast')};
|
|
56
81
|
|
|
82
|
+
// The whole scale is rem, so this one percentage moves type, spacing and
|
|
83
|
+
// control heights together. Breakpoints are px and stay where they are.
|
|
84
|
+
--mw-root-font-size: 100%;
|
|
85
|
+
|
|
57
86
|
// Custom properties, so an application can tighten its forms without recompiling
|
|
58
87
|
--mw-control-height-sm: #{$control-height-sm};
|
|
59
88
|
--mw-control-height: #{$control-height};
|
|
@@ -63,6 +92,12 @@
|
|
|
63
92
|
--mw-control-font-lg: #{$control-font-lg};
|
|
64
93
|
--mw-control-line-height: #{$control-line-height};
|
|
65
94
|
|
|
95
|
+
// One ramp for both themes - the theme reaches it through the two shadow
|
|
96
|
+
// tokens the levels are built from
|
|
97
|
+
@each $name, $value in $elevations {
|
|
98
|
+
--mw-#{$name}: #{$value};
|
|
99
|
+
}
|
|
100
|
+
|
|
66
101
|
// Focus ring
|
|
67
102
|
--mw-focus-ring-width: #{$focus-ring-width};
|
|
68
103
|
--mw-focus-ring-offset: #{$focus-ring-offset};
|
|
@@ -71,7 +106,9 @@
|
|
|
71
106
|
--mw-focus-halo-opacity: #{$focus-halo-opacity};
|
|
72
107
|
|
|
73
108
|
// The only way the chrome the browser draws itself follows the theme:
|
|
74
|
-
// scrollbars, the select popup, the date picker panel, number spinners
|
|
109
|
+
// scrollbars, the select popup, the date picker panel, number spinners.
|
|
110
|
+
// Under `switchable` this is also what light-dark() reads, so the pair below
|
|
111
|
+
// does double duty and the @supports block widens it to `light dark`.
|
|
75
112
|
@if $mw-theme-mode == 'light' {
|
|
76
113
|
color-scheme: light;
|
|
77
114
|
} @else {
|
|
@@ -135,6 +172,62 @@
|
|
|
135
172
|
|
|
136
173
|
color-scheme: light;
|
|
137
174
|
}
|
|
175
|
+
|
|
176
|
+
// The same two themes, declared once instead of twice. A custom property
|
|
177
|
+
// holding light-dark() is resolved where it is *used*, against that
|
|
178
|
+
// element's color-scheme - so one declaration on :root serves both, and a
|
|
179
|
+
// class further down switches every token by changing nothing but the
|
|
180
|
+
// scheme. The page then also follows the OS out of the box, which the
|
|
181
|
+
// class-only route could never do: before the script had run, a machine set
|
|
182
|
+
// to light still got the dark theme for a frame.
|
|
183
|
+
//
|
|
184
|
+
// The block above stays as the fallback for Chrome 119-122 and Safari
|
|
185
|
+
// 16.4-17.4, which are inside the declared browserslist but predate
|
|
186
|
+
// light-dark(). Drop it, and the two class rules with it, once the support
|
|
187
|
+
// floor moves past Chrome 123 / Safari 17.5.
|
|
188
|
+
@supports (color: light-dark(#000, #fff)) {
|
|
189
|
+
:root,
|
|
190
|
+
.mw-theme-light {
|
|
191
|
+
@each $name, $value in $_theme-colors {
|
|
192
|
+
--mw-#{$name}: light-dark(
|
|
193
|
+
var(--mw-light-#{$name}),
|
|
194
|
+
var(--mw-dark-#{$name})
|
|
195
|
+
);
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
:root {
|
|
200
|
+
color-scheme: light dark;
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
// Not a color, so it cannot ride along above - it follows the OS here and
|
|
204
|
+
// is overridden by whichever class the toggle puts on the body
|
|
205
|
+
@media (prefers-color-scheme: light) {
|
|
206
|
+
:root {
|
|
207
|
+
@each $name in $theme-non-colors {
|
|
208
|
+
--mw-#{$name}: var(--mw-light-#{$name});
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
.mw-theme-light {
|
|
214
|
+
color-scheme: light;
|
|
215
|
+
|
|
216
|
+
@each $name in $theme-non-colors {
|
|
217
|
+
--mw-#{$name}: var(--mw-light-#{$name});
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
// Only reachable once the OS says light: the explicit counterpart to the
|
|
222
|
+
// class above, so a reader who wants dark on a light machine gets it
|
|
223
|
+
.mw-theme-dark {
|
|
224
|
+
color-scheme: dark;
|
|
225
|
+
|
|
226
|
+
@each $name in $theme-non-colors {
|
|
227
|
+
--mw-#{$name}: var(--mw-dark-#{$name});
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
}
|
|
138
231
|
}
|
|
139
232
|
|
|
140
233
|
// Form controls are deliberately light in both themes - see
|
|
@@ -58,14 +58,17 @@
|
|
|
58
58
|
overflow: hidden;
|
|
59
59
|
}
|
|
60
60
|
|
|
61
|
-
// Named, so the query cannot resolve to a container further up the tree.
|
|
62
|
-
//
|
|
63
|
-
//
|
|
64
|
-
//
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
61
|
+
// Named, so the query cannot resolve to a container further up the tree.
|
|
62
|
+
// Every card, not only the ones with a footer: the title, the padding and
|
|
63
|
+
// the image height all used to step on a *viewport* breakpoint, so a card in
|
|
64
|
+
// a three-column grid on a wide desktop took the same 1.5rem title as the
|
|
65
|
+
// full-width one on a phone while being a third of its width.
|
|
66
|
+
//
|
|
67
|
+
// `width: 100%` is what makes it safe: inline-size containment computes the
|
|
68
|
+
// width as if the card were empty, so a card that sized to its content would
|
|
69
|
+
// otherwise collapse to its border.
|
|
70
|
+
width: 100%;
|
|
71
|
+
container: mw-card / inline-size;
|
|
69
72
|
|
|
70
73
|
// The arc on the two round corners is the one mark that makes a card look
|
|
71
74
|
// like this framework and not like a rounded box, so it is what the hover
|
|
@@ -168,6 +171,9 @@
|
|
|
168
171
|
&-lg {
|
|
169
172
|
--mw-card-img-height: 260px;
|
|
170
173
|
|
|
174
|
+
// On the window and not on the card: this declaration sits on the card,
|
|
175
|
+
// which is the container, and a container cannot query itself. The height
|
|
176
|
+
// of a picture is a question of room on screen anyway.
|
|
171
177
|
@include media-up('sm') {
|
|
172
178
|
--mw-card-img-height: 340px;
|
|
173
179
|
}
|
|
@@ -176,6 +182,9 @@
|
|
|
176
182
|
&-xl {
|
|
177
183
|
--mw-card-img-height: 340px;
|
|
178
184
|
|
|
185
|
+
// On the window and not on the card: this declaration sits on the card,
|
|
186
|
+
// which is the container, and a container cannot query itself. The height
|
|
187
|
+
// of a picture is a question of room on screen anyway.
|
|
179
188
|
@include media-up('sm') {
|
|
180
189
|
--mw-card-img-height: 480px;
|
|
181
190
|
}
|
|
@@ -187,7 +196,7 @@
|
|
|
187
196
|
flex-grow: 1;
|
|
188
197
|
padding: spacing('6') spacing('4') spacing('5');
|
|
189
198
|
|
|
190
|
-
@
|
|
199
|
+
@container mw-card (width >= #{$mw-card-wide}) {
|
|
191
200
|
padding: spacing('7') spacing('5') spacing('6');
|
|
192
201
|
}
|
|
193
202
|
|
|
@@ -204,7 +213,7 @@
|
|
|
204
213
|
&-title {
|
|
205
214
|
margin-bottom: spacing('3');
|
|
206
215
|
font-size: font-size('lg');
|
|
207
|
-
@
|
|
216
|
+
@container mw-card (width >= #{$mw-card-wide}) {
|
|
208
217
|
font-size: font-size('xl');
|
|
209
218
|
}
|
|
210
219
|
|
|
@@ -245,7 +254,7 @@
|
|
|
245
254
|
line-height: 1.2;
|
|
246
255
|
font-style: italic;
|
|
247
256
|
color: var(--mw-text-muted-color);
|
|
248
|
-
@
|
|
257
|
+
@container mw-card (width >= #{$mw-card-wide}) {
|
|
249
258
|
margin-bottom: spacing('3');
|
|
250
259
|
}
|
|
251
260
|
}
|
|
@@ -253,7 +262,7 @@
|
|
|
253
262
|
&-text {
|
|
254
263
|
margin: spacing('2') spacing('0') spacing('4') spacing('0');
|
|
255
264
|
color: var(--mw-text-color);
|
|
256
|
-
@
|
|
265
|
+
@container mw-card (width <= #{$mw-card-narrow}) {
|
|
257
266
|
margin-bottom: spacing('2');
|
|
258
267
|
}
|
|
259
268
|
}
|
|
@@ -285,7 +294,7 @@
|
|
|
285
294
|
// Stacked once the card is narrow, not once the window is - a card in a
|
|
286
295
|
// three-column grid on a wide desktop is as narrow as the same card on a
|
|
287
296
|
// phone and used to keep its actions in a cramped row anyway.
|
|
288
|
-
@container mw-card (
|
|
297
|
+
@container mw-card (width <= #{$mw-card-narrow}) {
|
|
289
298
|
flex-direction: column;
|
|
290
299
|
align-items: stretch;
|
|
291
300
|
gap: spacing('2');
|
|
@@ -353,7 +362,7 @@
|
|
|
353
362
|
justify-content: center;
|
|
354
363
|
margin: spacing('0');
|
|
355
364
|
|
|
356
|
-
@
|
|
365
|
+
@container mw-card (width <= #{$mw-card-narrow}) {
|
|
357
366
|
font-size: font-size('sm');
|
|
358
367
|
}
|
|
359
368
|
}
|
|
@@ -197,10 +197,67 @@
|
|
|
197
197
|
overflow: visible;
|
|
198
198
|
}
|
|
199
199
|
|
|
200
|
+
// The clipping caveat at the top of this file, lifted where the browser can do
|
|
201
|
+
// it. `fixed` takes the menu out of every ancestor's containing block and
|
|
202
|
+
// anchor positioning keeps it attached to the trigger, so an actions menu in a
|
|
203
|
+
// scrolling table or a clipping card is no longer cut in half - and the
|
|
204
|
+
// `:has()` list above becomes belt and braces rather than the only thing
|
|
205
|
+
// holding it together.
|
|
206
|
+
//
|
|
207
|
+
// `anchor-scope` is what makes this safe and why it is in the @supports test:
|
|
208
|
+
// an anchor name is global, so without it every menu on the page would resolve
|
|
209
|
+
// to whichever trigger came last in the DOM. Scoped to the dropdown, each menu
|
|
210
|
+
// sees its own.
|
|
211
|
+
@supports (anchor-scope: all) and (position-area: block-end) {
|
|
212
|
+
.mw-dropdown {
|
|
213
|
+
anchor-scope: --mw-dropdown-trigger;
|
|
214
|
+
|
|
215
|
+
> summary {
|
|
216
|
+
anchor-name: --mw-dropdown-trigger;
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
.mw-dropdown-menu {
|
|
221
|
+
position: fixed;
|
|
222
|
+
position-anchor: --mw-dropdown-trigger;
|
|
223
|
+
// Below the trigger, left edges aligned - the same place the absolute
|
|
224
|
+
// version sits. The inset properties it used are cleared, or they fight
|
|
225
|
+
// the position-area, which resolves them itself.
|
|
226
|
+
position-area: block-end span-inline-end;
|
|
227
|
+
// Flip up when the trigger sits low, in when it sits near the right edge.
|
|
228
|
+
// The menu has no arrow to contradict a flip, so unlike the tooltip it can
|
|
229
|
+
// take all of them.
|
|
230
|
+
position-try-fallbacks:
|
|
231
|
+
flip-block,
|
|
232
|
+
flip-inline,
|
|
233
|
+
flip-block flip-inline;
|
|
234
|
+
// Never taller than the room the fallback landed in
|
|
235
|
+
position-try-order: most-block-size;
|
|
236
|
+
top: auto;
|
|
237
|
+
right: auto;
|
|
238
|
+
bottom: auto;
|
|
239
|
+
left: auto;
|
|
240
|
+
margin-block: spacing('2');
|
|
241
|
+
// The viewport cap no longer applies - what matters is the slot the anchor
|
|
242
|
+
// left, and 60dvh was measured against the window anyway
|
|
243
|
+
max-height: min(60dvh, 420px);
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
// Both variants are what position-try-fallbacks now does on its own, so they
|
|
247
|
+
// only have to stop pushing the menu around with insets
|
|
248
|
+
.mw-dropdown-end .mw-dropdown-menu {
|
|
249
|
+
position-area: block-end span-inline-start;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
.mw-dropdown-up .mw-dropdown-menu {
|
|
253
|
+
position-area: block-start span-inline-end;
|
|
254
|
+
}
|
|
255
|
+
}
|
|
256
|
+
|
|
200
257
|
// A menu opened by a thumb needs rows a thumb can hit, and the room to show
|
|
201
258
|
// them - so it takes the trigger's full width rather than a 200px column
|
|
202
259
|
// floating beside it.
|
|
203
|
-
@media (pointer: coarse), (
|
|
260
|
+
@media (pointer: coarse), (width <= #{breakpoint('sm')}) {
|
|
204
261
|
.mw-dropdown-menu {
|
|
205
262
|
min-width: max(100%, 240px);
|
|
206
263
|
}
|
|
@@ -7,6 +7,8 @@
|
|
|
7
7
|
// Room the ribbon needs in the top right corner of a ticket
|
|
8
8
|
$_mw-kanban-ribbon-clearance: 66px;
|
|
9
9
|
$_mw-kanban-ribbon-clearance-compact: 58px;
|
|
10
|
+
// Narrowest a lane may get before the board wraps it to the next row
|
|
11
|
+
$_mw-kanban-lane-min: 260px;
|
|
10
12
|
|
|
11
13
|
@keyframes mw-kanban-card-in {
|
|
12
14
|
from {
|
|
@@ -58,21 +60,20 @@
|
|
|
58
60
|
--mw-kanban-column-min-height: 120px;
|
|
59
61
|
|
|
60
62
|
display: grid;
|
|
61
|
-
|
|
62
|
-
|
|
63
|
+
// As many lanes as fit at a readable width, the rest wrap. The board asks
|
|
64
|
+
// its own width, so one inside a panel wraps on a desktop too. `min()`
|
|
65
|
+
// against 100% keeps a lane out of a container narrower than the minimum.
|
|
66
|
+
grid-template-columns: repeat(
|
|
67
|
+
auto-fit,
|
|
68
|
+
minmax(min(#{$_mw-kanban-lane-min}, 100%), 1fr)
|
|
69
|
+
);
|
|
63
70
|
gap: spacing('4');
|
|
64
71
|
padding: spacing('4');
|
|
65
72
|
background: var(--mw-kanban-background);
|
|
66
73
|
border-radius: radius('md');
|
|
67
74
|
|
|
68
|
-
//
|
|
69
|
-
@include media-down('lg') {
|
|
70
|
-
grid-auto-flow: row;
|
|
71
|
-
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
72
|
-
}
|
|
73
|
-
|
|
75
|
+
// Frame only - how tight the board sits on a phone is a viewport call
|
|
74
76
|
@include media-down('sm') {
|
|
75
|
-
grid-template-columns: minmax(0, 1fr);
|
|
76
77
|
gap: spacing('3');
|
|
77
78
|
padding: spacing('3');
|
|
78
79
|
}
|
|
@@ -16,12 +16,24 @@
|
|
|
16
16
|
justify-content: center;
|
|
17
17
|
padding: spacing('7');
|
|
18
18
|
opacity: 0;
|
|
19
|
-
|
|
19
|
+
// `display` in the list and `allow-discrete` behind it, or the overlay is
|
|
20
|
+
// taken off the page the frame the class comes off and the fade out never
|
|
21
|
+
// renders - the modal inside it would slide down over nothing. The dialog
|
|
22
|
+
// version below has had this; the div version was landing hard.
|
|
23
|
+
transition:
|
|
24
|
+
opacity var(--mw-duration-base) var(--mw-ease-out),
|
|
25
|
+
display var(--mw-duration-base) allow-discrete;
|
|
20
26
|
|
|
21
27
|
// Show modal when class is added
|
|
22
28
|
&.mw-modal-open {
|
|
23
29
|
display: flex;
|
|
24
30
|
opacity: 1;
|
|
31
|
+
|
|
32
|
+
// A box that goes from `display: none` starts at its end state otherwise,
|
|
33
|
+
// so there is nothing to fade from
|
|
34
|
+
@starting-style {
|
|
35
|
+
opacity: 0;
|
|
36
|
+
}
|
|
25
37
|
}
|
|
26
38
|
}
|
|
27
39
|
|
|
@@ -200,7 +200,7 @@
|
|
|
200
200
|
// row survives the narrow-card stack and the action takes half of it. Here and
|
|
201
201
|
// not in _cards.scss because the price is the guest - the footer's own rule is
|
|
202
202
|
// right for everything that is not one.
|
|
203
|
-
@container mw-card (
|
|
203
|
+
@container mw-card (width <= #{$mw-card-narrow}) {
|
|
204
204
|
.mw-card-footer:has(> .mw-price) {
|
|
205
205
|
flex-direction: row;
|
|
206
206
|
align-items: center;
|
|
@@ -1,6 +1,15 @@
|
|
|
1
1
|
@use '../abstracts' as *;
|
|
2
2
|
|
|
3
3
|
@layer mw.components {
|
|
4
|
+
// How far the bar is filled - written by the script, read by the keyframe at
|
|
5
|
+
// the bottom. Registered and not declared on the element: a `data-value` the
|
|
6
|
+
// script cannot parse lands on 0% instead of dropping `width` altogether.
|
|
7
|
+
@property --mw-progress-value {
|
|
8
|
+
syntax: '<length-percentage>';
|
|
9
|
+
inherits: true;
|
|
10
|
+
initial-value: 0%;
|
|
11
|
+
}
|
|
12
|
+
|
|
4
13
|
.mw-progress {
|
|
5
14
|
&-container {
|
|
6
15
|
margin: spacing('1');
|
|
@@ -61,11 +70,6 @@
|
|
|
61
70
|
// the variants at the bottom of the file
|
|
62
71
|
--mw-progress-ink: var(--mw-secondary-accent-text-color);
|
|
63
72
|
|
|
64
|
-
// How far the bar is filled. Written by the script from data-value or from
|
|
65
|
-
// an inline width, and read by the keyframe below. Declared here so it has
|
|
66
|
-
// a definition rather than only a fallback - an unset bar is an empty one.
|
|
67
|
-
--mw-progress-value: 0;
|
|
68
|
-
|
|
69
73
|
height: 100%;
|
|
70
74
|
background: var(--mw-secondary-color);
|
|
71
75
|
border-radius: radius('sm');
|
|
@@ -16,20 +16,20 @@
|
|
|
16
16
|
border: 0.5rem solid var(--mw-border);
|
|
17
17
|
border-radius: radius('full');
|
|
18
18
|
border-top-color: var(--mw-primary-text-color);
|
|
19
|
-
animation: mw-spin 1.2s linear infinite;
|
|
19
|
+
animation: mw-spin motion(1.2s) linear infinite;
|
|
20
20
|
|
|
21
21
|
&.mw-spinner-sm {
|
|
22
22
|
width: $_size-sm;
|
|
23
23
|
height: $_size-sm;
|
|
24
24
|
border-width: 0.3rem;
|
|
25
|
-
animation: mw-spin 1.4s linear infinite;
|
|
25
|
+
animation: mw-spin motion(1.4s) linear infinite;
|
|
26
26
|
}
|
|
27
27
|
|
|
28
28
|
&.mw-spinner-lg {
|
|
29
29
|
width: $_size-lg;
|
|
30
30
|
height: $_size-lg;
|
|
31
31
|
border-width: 0.7rem;
|
|
32
|
-
animation: mw-spin 1s linear infinite;
|
|
32
|
+
animation: mw-spin motion(1s) linear infinite;
|
|
33
33
|
}
|
|
34
34
|
|
|
35
35
|
&.mw-spinner-primary {
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
border-radius: radius('full');
|
|
55
55
|
display: inline-block;
|
|
56
56
|
margin: spacing('0') spacing('2');
|
|
57
|
-
animation: mw-bounce 1.4s infinite ease-in-out both;
|
|
57
|
+
animation: mw-bounce motion(1.4s) infinite ease-in-out both;
|
|
58
58
|
|
|
59
59
|
&:nth-child(1) {
|
|
60
60
|
animation-delay: -0.32s;
|
|
@@ -110,7 +110,7 @@
|
|
|
110
110
|
border: 0.5rem solid var(--mw-primary-text-color);
|
|
111
111
|
border-color: var(--mw-primary-text-color) transparent
|
|
112
112
|
var(--mw-primary-text-color) transparent;
|
|
113
|
-
animation: mw-spin 1.5s linear infinite;
|
|
113
|
+
animation: mw-spin motion(1.5s) linear infinite;
|
|
114
114
|
}
|
|
115
115
|
|
|
116
116
|
&.mw-spinner-sm {
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
display: flex;
|
|
7
7
|
align-items: flex-start;
|
|
8
8
|
width: 100%;
|
|
9
|
+
container: mw-stepper / inline-size;
|
|
9
10
|
|
|
10
11
|
&-step {
|
|
11
12
|
display: flex;
|
|
@@ -79,7 +80,9 @@
|
|
|
79
80
|
}
|
|
80
81
|
}
|
|
81
82
|
|
|
82
|
-
|
|
83
|
+
// The step labels follow the strip's own width, not the window's - a
|
|
84
|
+
// stepper in a narrow card keeps the small label on a wide desktop.
|
|
85
|
+
@container mw-stepper (width >= #{breakpoint('sm')}) {
|
|
83
86
|
&-label {
|
|
84
87
|
font-size: font-size('xs');
|
|
85
88
|
}
|
|
@@ -1,6 +1,34 @@
|
|
|
1
1
|
@use '../abstracts' as *;
|
|
2
2
|
|
|
3
3
|
@layer mw.components {
|
|
4
|
+
// Registered, so a half-written value from the script cannot invalidate the
|
|
5
|
+
// whole `transform` and leave the marker somewhere other than at rest.
|
|
6
|
+
// `inherits: true` because the bar is the nav's ::after, and a pseudo element
|
|
7
|
+
// only ever sees these through inheritance.
|
|
8
|
+
@property --mw-tabs-marker-x {
|
|
9
|
+
syntax: '<length>';
|
|
10
|
+
inherits: true;
|
|
11
|
+
initial-value: 0px;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
@property --mw-tabs-marker-y {
|
|
15
|
+
syntax: '<length>';
|
|
16
|
+
inherits: true;
|
|
17
|
+
initial-value: 0px;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
@property --mw-tabs-marker-w {
|
|
21
|
+
syntax: '<number>';
|
|
22
|
+
inherits: true;
|
|
23
|
+
initial-value: 0;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
@property --mw-tabs-marker-h {
|
|
27
|
+
syntax: '<number>';
|
|
28
|
+
inherits: true;
|
|
29
|
+
initial-value: 0;
|
|
30
|
+
}
|
|
31
|
+
|
|
4
32
|
.mw-tabs {
|
|
5
33
|
display: flex;
|
|
6
34
|
flex-direction: column;
|
|
@@ -71,14 +99,6 @@
|
|
|
71
99
|
// A 1px bar scaled to width, not a bar whose width is set: scaleX runs on the
|
|
72
100
|
// compositor, `width` relayouts the strip on every frame of the slide.
|
|
73
101
|
&-nav[data-mw-tabs-marker] {
|
|
74
|
-
// Declared with a zero length so the four are real tokens with a resting
|
|
75
|
-
// value rather than four names the stylesheet only ever reads. The script
|
|
76
|
-
// sets them on the element, which outranks this either way.
|
|
77
|
-
--mw-tabs-marker-x: 0;
|
|
78
|
-
--mw-tabs-marker-w: 0;
|
|
79
|
-
--mw-tabs-marker-y: 0;
|
|
80
|
-
--mw-tabs-marker-h: 0;
|
|
81
|
-
|
|
82
102
|
.mw-tabs-nav-item.mw-active,
|
|
83
103
|
.mw-tabs-nav-item.active {
|
|
84
104
|
border-bottom-color: transparent;
|