@slotted/styles 0.1.0-beta.1 โ 0.1.0-beta.11
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/package.json +1 -1
- package/src/accordion/accordion.css +10 -10
- package/src/action-bar/action-bar.css +35 -42
- package/src/action-sheet/action-sheet.css +36 -36
- package/src/alert/alert.css +43 -35
- package/src/alert/alert.tokens.json +5 -0
- package/src/app-shell/app-shell.css +356 -301
- package/src/aspect-ratio/aspect-ratio.css +9 -9
- package/src/attachment/attachment.css +91 -99
- package/src/avatar/avatar.css +71 -41
- package/src/avatar/avatar.tokens.json +7 -0
- package/src/avatar-group/avatar-group.css +21 -22
- package/src/badge/badge.css +45 -37
- package/src/badge/badge.tokens.json +5 -0
- package/src/breadcrumb/breadcrumb.css +37 -37
- package/src/button/button.css +149 -68
- package/src/button/button.tokens.json +10 -0
- package/src/button-group/button-group.css +79 -74
- package/src/button-group/button-group.tokens.json +2 -0
- package/src/calendar/calendar.css +93 -103
- package/src/card/card.css +54 -61
- package/src/carousel/carousel.css +150 -161
- package/src/cascader/cascader.css +152 -153
- package/src/cascader/cascader.tokens.json +1 -0
- package/src/chart/chart.css +242 -239
- package/src/chart/chart.tokens.json +1 -0
- package/src/checkbox/checkbox.css +119 -124
- package/src/checkbox-group/checkbox-group.css +7 -7
- package/src/code-block/code-block.css +81 -85
- package/src/collapsible/collapsible.css +69 -76
- package/src/color-picker/color-picker.css +83 -91
- package/src/column-manager/column-manager.css +106 -114
- package/src/combobox/combobox.css +132 -107
- package/src/combobox/combobox.tokens.json +1 -0
- package/src/command-palette/command-palette.css +103 -90
- package/src/command-palette/command-palette.tokens.json +1 -0
- package/src/container/container.css +24 -24
- package/src/context-menu/context-menu.css +8 -8
- package/src/currency-field/currency-field.css +210 -88
- package/src/currency-field/currency-field.tokens.json +13 -0
- package/src/dashboard-grid/dashboard-grid.css +148 -116
- package/src/data-grid/data-grid.css +535 -470
- package/src/data-grid/data-grid.tokens.json +4 -0
- package/src/data-list/data-list.css +81 -70
- package/src/data-list/data-list.tokens.json +2 -1
- package/src/date-field/date-field.css +55 -52
- package/src/date-field/date-field.tokens.json +1 -0
- package/src/date-picker/date-picker.css +40 -42
- package/src/date-range-picker/date-range-picker.css +114 -118
- package/src/datetime-field/datetime-field.css +78 -80
- package/src/datetime-field/datetime-field.tokens.json +1 -0
- package/src/datetime-picker/datetime-picker.css +61 -63
- package/src/datetime-range-picker/datetime-range-picker.css +149 -156
- package/src/description-list/description-list.css +61 -64
- package/src/detail-panel/detail-panel.css +86 -71
- package/src/detail-panel/detail-panel.tokens.json +2 -0
- package/src/dialog/dialog.css +372 -153
- package/src/dialog/dialog.tokens.json +6 -0
- package/src/divider/divider.css +18 -18
- package/src/drawer/drawer.css +205 -210
- package/src/drawer/drawer.tokens.json +1 -0
- package/src/entity-picker/entity-picker.css +238 -241
- package/src/entity-picker/entity-picker.tokens.json +1 -0
- package/src/event-calendar/event-calendar.css +343 -385
- package/src/field/field.css +74 -78
- package/src/field-group/field-group.css +22 -25
- package/src/filter-bar/filter-bar.css +193 -209
- package/src/form/form.css +34 -24
- package/src/form/form.tokens.json +1 -0
- package/src/fullscreen/fullscreen.css +24 -25
- package/src/grid/grid.css +28 -28
- package/src/highlight/highlight.css +6 -6
- package/src/hover-card/hover-card.css +6 -6
- package/src/icon/icon.css +19 -15
- package/src/icon/icon.tokens.json +1 -0
- package/src/image/image.css +39 -39
- package/src/import-export-center/import-export-center.css +135 -156
- package/src/inline/inline.css +27 -27
- package/src/inline-message/inline-message.css +52 -28
- package/src/inline-message/inline-message.tokens.json +4 -0
- package/src/kbd/kbd.css +30 -26
- package/src/link/link.css +15 -15
- package/src/list/list.css +44 -17
- package/src/list/list.tokens.json +4 -0
- package/src/list-item/list-item.css +80 -66
- package/src/list-item/list-item.tokens.json +7 -0
- package/src/listbox/listbox.css +56 -59
- package/src/loading-overlay/loading-overlay.css +75 -92
- package/src/markdown/markdown.css +17 -17
- package/src/menu/menu.css +83 -63
- package/src/menubar/menubar.css +13 -13
- package/src/message/message.css +182 -202
- package/src/message/message.tokens.json +5 -0
- package/src/message-scroller/message-scroller.css +41 -42
- package/src/multi-select/multi-select.css +152 -145
- package/src/multi-select/multi-select.tokens.json +1 -0
- package/src/navigation-menu/navigation-menu.css +167 -188
- package/src/notification-center/notification-center.css +140 -148
- package/src/notification-center/notification-center.tokens.json +3 -0
- package/src/number-field/number-field.css +84 -83
- package/src/number-field/number-field.tokens.json +1 -0
- package/src/otp-input/otp-input.css +67 -57
- package/src/otp-input/otp-input.tokens.json +1 -0
- package/src/page/page.css +39 -23
- package/src/page/page.tokens.json +1 -0
- package/src/page-header/page-header.css +323 -283
- package/src/page-header/page-header.tokens.json +5 -0
- package/src/pagination/pagination.css +68 -72
- package/src/popover/popover.css +40 -49
- package/src/progress-indicator/progress-indicator.css +177 -120
- package/src/progress-indicator/progress-indicator.tokens.json +1 -1
- package/src/prompt-composer/prompt-composer.css +221 -102
- package/src/prompt-composer/prompt-composer.tokens.json +15 -0
- package/src/prose/prose.css +71 -75
- package/src/radio-group/radio-group.css +98 -103
- package/src/rating/rating.css +136 -132
- package/src/rating/rating.tokens.json +1 -0
- package/src/result-state/result-state.css +74 -77
- package/src/runtime-properties.mjs +2 -0
- package/src/saved-views/saved-views.css +41 -47
- package/src/scroll-area/scroll-area.css +39 -32
- package/src/section/section.css +161 -41
- package/src/section/section.tokens.json +7 -2
- package/src/segmented-control/segmented-control.css +254 -97
- package/src/segmented-control/segmented-control.tokens.json +15 -11
- package/src/select/select.css +118 -117
- package/src/select/select.tokens.json +1 -0
- package/src/side-navigation/side-navigation.css +179 -182
- package/src/side-navigation/side-navigation.tokens.json +1 -0
- package/src/skeleton/skeleton.css +47 -48
- package/src/slider/slider.css +86 -88
- package/src/sparkline/sparkline.css +62 -40
- package/src/sparkline/sparkline.tokens.json +2 -0
- package/src/spinner/spinner.css +83 -180
- package/src/spinner/spinner.tokens.json +0 -1
- package/src/split-button/split-button.css +30 -31
- package/src/split-button/split-button.tokens.json +1 -0
- package/src/splitter/splitter.css +35 -35
- package/src/stack/stack.css +24 -24
- package/src/stat-card/stat-card.css +341 -224
- package/src/stat-card/stat-card.tokens.json +3 -0
- package/src/status-indicator/status-indicator.css +28 -28
- package/src/stepper/stepper.css +58 -62
- package/src/switch/switch.css +86 -92
- package/src/table/table.css +310 -165
- package/src/table/table.tokens.json +6 -0
- package/src/table-of-contents/table-of-contents.css +51 -54
- package/src/tabs/tabs.css +337 -302
- package/src/tabs/tabs.tokens.json +8 -5
- package/src/tag/tag.css +79 -71
- package/src/tag/tag.tokens.json +9 -0
- package/src/tags-input/tags-input.css +145 -82
- package/src/tags-input/tags-input.tokens.json +7 -1
- package/src/text-field/text-field.css +132 -136
- package/src/text-field/text-field.tokens.json +1 -0
- package/src/textarea/textarea.css +31 -28
- package/src/textarea/textarea.tokens.json +1 -0
- package/src/time-field/time-field.css +72 -69
- package/src/time-field/time-field.tokens.json +1 -0
- package/src/time-picker/time-picker.css +56 -58
- package/src/time-range-picker/time-range-picker.css +126 -133
- package/src/timeline/timeline.css +254 -266
- package/src/timeline/timeline.tokens.json +5 -0
- package/src/toast/toast.css +108 -90
- package/src/toast/toast.tokens.json +6 -0
- package/src/toggle/toggle.css +62 -25
- package/src/toggle/toggle.tokens.json +8 -0
- package/src/toggle-group/toggle-group.css +106 -60
- package/src/toggle-group/toggle-group.tokens.json +10 -0
- package/src/toolbar/toolbar.css +30 -35
- package/src/tooltip/tooltip.css +26 -26
- package/src/top-navigation/top-navigation.css +243 -259
- package/src/tour/tour.css +51 -60
- package/src/transfer/transfer.css +160 -164
- package/src/tree/tree.css +103 -111
- package/src/typography/typography.css +40 -36
- package/src/typography/typography.tokens.json +1 -0
- package/src/upload/upload.css +224 -224
- package/src/visually-hidden/visually-hidden.css +1 -1
- package/src/wizard/wizard.css +185 -197
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* mirrors its state onto the root rather than styling through, so a control
|
|
14
14
|
* used outside a field looks the same as one inside it.
|
|
15
15
|
*/
|
|
16
|
-
[data-ui
|
|
16
|
+
[data-ui-otp-input][data-part-root] {
|
|
17
17
|
/**
|
|
18
18
|
* A box is a square on the control's height at this density, so a code
|
|
19
19
|
* beside a text field in the same form sits on the same row height. Its
|
|
@@ -71,7 +71,7 @@
|
|
|
71
71
|
* native attribute a consumer wrote. `opacity: 1` rather than 0, because iOS
|
|
72
72
|
* shows no paste menu on an invisible control (input-otp, `input.tsx`).
|
|
73
73
|
*/
|
|
74
|
-
[data-ui
|
|
74
|
+
[data-ui-otp-input] > [data-part-input] {
|
|
75
75
|
appearance: none;
|
|
76
76
|
background-color: transparent;
|
|
77
77
|
block-size: 100%;
|
|
@@ -104,7 +104,7 @@
|
|
|
104
104
|
* selected at every press, so the drag is refused โ here for the engines
|
|
105
105
|
* that read the property, and in both bindings on `dragstart`.
|
|
106
106
|
*/
|
|
107
|
-
[data-ui
|
|
107
|
+
[data-ui-otp-input] > [data-part-input]::selection {
|
|
108
108
|
/**
|
|
109
109
|
* `!important`, the only one in the library. An application that styles
|
|
110
110
|
* its own `::selection` โ and the workbench does, unlayered โ outranks a
|
|
@@ -119,37 +119,44 @@
|
|
|
119
119
|
-webkit-text-fill-color: transparent !important;
|
|
120
120
|
}
|
|
121
121
|
|
|
122
|
-
[data-ui
|
|
122
|
+
[data-ui-otp-input] > [data-part-input] {
|
|
123
123
|
-webkit-user-drag: none;
|
|
124
124
|
}
|
|
125
125
|
|
|
126
126
|
/**
|
|
127
|
-
* Autofill.
|
|
128
|
-
*
|
|
129
|
-
*
|
|
130
|
-
*
|
|
131
|
-
*
|
|
127
|
+
* Autofill. The input lies over the boxes, so the classic repair โ a
|
|
128
|
+
* hundred-pixel inset shadow in the tint โ painted over every box, its edge
|
|
129
|
+
* and the gaps between them. The browser's own ground is held back instead,
|
|
130
|
+
* by a transition that never starts, and the boxes take the tint: an
|
|
131
|
+
* autofilled code is a fact worth seeing, on the accent surface the theme
|
|
132
|
+
* owns rather than on the browser's yellow.
|
|
132
133
|
*/
|
|
133
|
-
[data-ui
|
|
134
|
-
|
|
135
|
-
var(--slotted-otp-input-autofill-background, var(--slotted-tone-accent-surface));
|
|
134
|
+
[data-ui-otp-input] > [data-part-input]:autofill {
|
|
135
|
+
transition: background-color 0s 600000s;
|
|
136
136
|
-webkit-text-fill-color: transparent;
|
|
137
137
|
}
|
|
138
138
|
|
|
139
|
+
[data-ui-otp-input][data-part-root]:has(> [data-part-input]:autofill) [data-part-slot] {
|
|
140
|
+
background-color: var(
|
|
141
|
+
--slotted-otp-input-autofill-background,
|
|
142
|
+
var(--slotted-tone-accent-surface)
|
|
143
|
+
);
|
|
144
|
+
}
|
|
145
|
+
|
|
139
146
|
/* โโ Groups and the separator โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
|
|
140
147
|
*
|
|
141
148
|
* `groups` partitions the boxes; `123-456` is how the SMS arrives. Each
|
|
142
149
|
* group is a row of boxes, and between two groups a short rule is drawn โ
|
|
143
150
|
* never a character, which would be read by nothing and mirrored by nothing.
|
|
144
151
|
*/
|
|
145
|
-
[data-ui
|
|
152
|
+
[data-ui-otp-input] > [data-part-group] {
|
|
146
153
|
align-items: center;
|
|
147
154
|
display: flex;
|
|
148
155
|
gap: var(--_gap);
|
|
149
156
|
min-inline-size: 0;
|
|
150
157
|
}
|
|
151
158
|
|
|
152
|
-
[data-ui
|
|
159
|
+
[data-ui-otp-input] > [data-part-separator] {
|
|
153
160
|
background-color: var(
|
|
154
161
|
--slotted-otp-input-separator-color,
|
|
155
162
|
var(--slotted-control-border-color, ButtonBorder)
|
|
@@ -167,7 +174,7 @@
|
|
|
167
174
|
* framed control carries. It shrinks before the row overflows โ a code in a
|
|
168
175
|
* 240-pixel column loses width, not boxes.
|
|
169
176
|
*/
|
|
170
|
-
[data-ui
|
|
177
|
+
[data-ui-otp-input] [data-part-slot] {
|
|
171
178
|
align-items: center;
|
|
172
179
|
background-color: var(--slotted-otp-input-background, var(--slotted-control-surface, Field));
|
|
173
180
|
block-size: var(--_height);
|
|
@@ -205,7 +212,7 @@
|
|
|
205
212
|
* so the caret and the filled state keep reading the DOM rather than the
|
|
206
213
|
* paint.
|
|
207
214
|
*/
|
|
208
|
-
[data-ui
|
|
215
|
+
[data-ui-otp-input] [data-part-slot]:empty::before {
|
|
209
216
|
color: var(--slotted-otp-input-placeholder-color, var(--slotted-text-muted));
|
|
210
217
|
content: attr(data-placeholder);
|
|
211
218
|
}
|
|
@@ -218,7 +225,7 @@
|
|
|
218
225
|
* four-pixel speck in a thirty-four-pixel box, and a PIN pad draws its dots
|
|
219
226
|
* larger than its digits.
|
|
220
227
|
*/
|
|
221
|
-
[data-ui
|
|
228
|
+
[data-ui-otp-input][data-mask] [data-part-slot]:not(:empty) {
|
|
222
229
|
font-size: var(--slotted-otp-input-mask-size, var(--slotted-font-size-2xl, 1.25rem));
|
|
223
230
|
}
|
|
224
231
|
|
|
@@ -230,29 +237,29 @@
|
|
|
230
237
|
* rather than two, and the raised box โ hovered, current, focused โ comes
|
|
231
238
|
* forward so its whole edge is seen.
|
|
232
239
|
*/
|
|
233
|
-
[data-ui
|
|
240
|
+
[data-ui-otp-input][data-attached] > [data-part-group] {
|
|
234
241
|
gap: 0;
|
|
235
242
|
}
|
|
236
243
|
|
|
237
|
-
[data-ui
|
|
244
|
+
[data-ui-otp-input][data-attached] [data-part-slot] {
|
|
238
245
|
border-radius: 0;
|
|
239
246
|
}
|
|
240
247
|
|
|
241
|
-
[data-ui
|
|
248
|
+
[data-ui-otp-input][data-attached] [data-part-slot]:not(:first-child) {
|
|
242
249
|
margin-inline-start: calc(var(--slotted-control-border-width, 1px) * -1);
|
|
243
250
|
}
|
|
244
251
|
|
|
245
|
-
[data-ui
|
|
252
|
+
[data-ui-otp-input][data-attached] [data-part-slot]:first-child {
|
|
246
253
|
border-start-start-radius: var(--_radius);
|
|
247
254
|
border-end-start-radius: var(--_radius);
|
|
248
255
|
}
|
|
249
256
|
|
|
250
|
-
[data-ui
|
|
257
|
+
[data-ui-otp-input][data-attached] [data-part-slot]:last-child {
|
|
251
258
|
border-start-end-radius: var(--_radius);
|
|
252
259
|
border-end-end-radius: var(--_radius);
|
|
253
260
|
}
|
|
254
261
|
|
|
255
|
-
[data-ui
|
|
262
|
+
[data-ui-otp-input][data-attached] [data-part-slot][data-current] {
|
|
256
263
|
z-index: 1;
|
|
257
264
|
}
|
|
258
265
|
|
|
@@ -263,19 +270,19 @@
|
|
|
263
270
|
* same name, so a `lg` code is a `lg` word's size and one step larger than
|
|
264
271
|
* a `lg` field's text.
|
|
265
272
|
*/
|
|
266
|
-
[data-ui
|
|
273
|
+
[data-ui-otp-input][data-part-root][data-size='sm'] {
|
|
267
274
|
--_height: var(--slotted-control-height-sm, 30px);
|
|
268
275
|
--_font-size: var(--slotted-font-size-sm, 0.8125rem);
|
|
269
276
|
--_gap: var(--slotted-control-gap-sm, 6px);
|
|
270
277
|
}
|
|
271
278
|
|
|
272
|
-
[data-ui
|
|
279
|
+
[data-ui-otp-input][data-part-root][data-size='md'] {
|
|
273
280
|
--_height: var(--slotted-control-height-md, 34px);
|
|
274
281
|
--_font-size: var(--slotted-font-size-md, 0.875rem);
|
|
275
282
|
--_gap: var(--slotted-control-gap-md, 8px);
|
|
276
283
|
}
|
|
277
284
|
|
|
278
|
-
[data-ui
|
|
285
|
+
[data-ui-otp-input][data-part-root][data-size='lg'] {
|
|
279
286
|
--_height: var(--slotted-control-height-lg, 38px);
|
|
280
287
|
--_font-size: var(--slotted-font-size-lg, 1rem);
|
|
281
288
|
--_gap: var(--slotted-control-gap-lg, 8px);
|
|
@@ -287,7 +294,7 @@
|
|
|
287
294
|
* The same two steps `text-field` draws, with the same tokens behind them,
|
|
288
295
|
* so a code under a text field in one form is one form.
|
|
289
296
|
*/
|
|
290
|
-
[data-ui
|
|
297
|
+
[data-ui-otp-input][data-variant='subtle'] [data-part-slot] {
|
|
291
298
|
background-color: var(
|
|
292
299
|
--slotted-otp-input-subtle-background,
|
|
293
300
|
var(--slotted-surface-sunken, Canvas)
|
|
@@ -309,8 +316,8 @@
|
|
|
309
316
|
* rather than blinking faster: an endless animation stops, it does not
|
|
310
317
|
* hurry.
|
|
311
318
|
*/
|
|
312
|
-
[data-ui
|
|
313
|
-
[data-part
|
|
319
|
+
[data-ui-otp-input][data-part-root]:has(> [data-part-input]:focus)
|
|
320
|
+
[data-part-slot][data-current]:empty::after {
|
|
314
321
|
animation: slotted-otp-input-blink var(--slotted-duration-loop) step-end infinite;
|
|
315
322
|
background-color: currentcolor;
|
|
316
323
|
block-size: 1em;
|
|
@@ -332,8 +339,8 @@
|
|
|
332
339
|
}
|
|
333
340
|
|
|
334
341
|
@media (prefers-reduced-motion: reduce) {
|
|
335
|
-
[data-ui
|
|
336
|
-
[data-part
|
|
342
|
+
[data-ui-otp-input][data-part-root]:has(> [data-part-input]:focus)
|
|
343
|
+
[data-part-slot][data-current]:empty::after {
|
|
337
344
|
animation: none;
|
|
338
345
|
}
|
|
339
346
|
}
|
|
@@ -345,17 +352,17 @@
|
|
|
345
352
|
* is always over the input, never over a box, so hover is the root's and it
|
|
346
353
|
* lights the whole row: the row is one control.
|
|
347
354
|
*/
|
|
348
|
-
[data-ui
|
|
355
|
+
[data-ui-otp-input][data-part-root]:hover:not([data-disabled]):not([data-readonly]):not(
|
|
349
356
|
[data-invalid]
|
|
350
357
|
)
|
|
351
|
-
[data-part
|
|
358
|
+
[data-part-slot] {
|
|
352
359
|
border-color: var(--slotted-otp-input-hover-border-color, var(--slotted-tone-accent-border));
|
|
353
360
|
}
|
|
354
361
|
|
|
355
|
-
[data-ui
|
|
362
|
+
[data-ui-otp-input][data-part-root][data-variant='subtle']:hover:not([data-disabled]):not(
|
|
356
363
|
[data-readonly]
|
|
357
364
|
):not([data-invalid])
|
|
358
|
-
[data-part
|
|
365
|
+
[data-part-slot] {
|
|
359
366
|
background-color: var(
|
|
360
367
|
--slotted-otp-input-subtle-hover-background,
|
|
361
368
|
var(--slotted-tone-secondary-subtle-hover)
|
|
@@ -372,13 +379,13 @@
|
|
|
372
379
|
* keeps its danger edge on every box, and the ring says where the cursor
|
|
373
380
|
* is โ while the tint survives, because it says what the next key does.
|
|
374
381
|
*/
|
|
375
|
-
[data-ui
|
|
376
|
-
[data-part
|
|
382
|
+
[data-ui-otp-input][data-part-root]:not([data-invalid]):has(> [data-part-input]:focus)
|
|
383
|
+
[data-part-slot][data-current] {
|
|
377
384
|
border-color: var(--slotted-otp-input-current-border-color, var(--slotted-tone-accent-border));
|
|
378
385
|
}
|
|
379
386
|
|
|
380
|
-
[data-ui
|
|
381
|
-
[data-part
|
|
387
|
+
[data-ui-otp-input][data-part-root]:has(> [data-part-input]:focus)
|
|
388
|
+
[data-part-slot][data-current]:not(:empty) {
|
|
382
389
|
background-color: var(
|
|
383
390
|
--slotted-otp-input-selection-background,
|
|
384
391
|
var(--slotted-tone-accent-surface)
|
|
@@ -392,8 +399,8 @@
|
|
|
392
399
|
* whose caret is the thing that moved. A ring around the whole row would sit
|
|
393
400
|
* still while the cursor moved inside it.
|
|
394
401
|
*/
|
|
395
|
-
[data-ui
|
|
396
|
-
[data-part
|
|
402
|
+
[data-ui-otp-input][data-part-root]:has(> [data-part-input]:focus-visible)
|
|
403
|
+
[data-part-slot][data-current] {
|
|
397
404
|
/**
|
|
398
405
|
* The resting shadow, recoloured. The geometry is the foundation's and the
|
|
399
406
|
* ink is the focus ring's, so the lift under the box and the ring around
|
|
@@ -402,7 +409,7 @@
|
|
|
402
409
|
box-shadow: var(--slotted-control-shadow-focus-geometry, 0 1px 4px -1px)
|
|
403
410
|
var(--slotted-focus-ring-color, Highlight);
|
|
404
411
|
outline: var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);
|
|
405
|
-
outline-offset: var(--slotted-focus-ring-offset, 2px);
|
|
412
|
+
outline-offset: var(--slotted-control-focus-ring-offset, var(--slotted-focus-ring-offset, 2px));
|
|
406
413
|
}
|
|
407
414
|
|
|
408
415
|
/**
|
|
@@ -412,14 +419,14 @@
|
|
|
412
419
|
* colour on the root moves all of them at once โ the rule `text-field`
|
|
413
420
|
* wrote and every field family inherits.
|
|
414
421
|
*/
|
|
415
|
-
[data-ui
|
|
422
|
+
[data-ui-otp-input][data-part-root][data-invalid] {
|
|
416
423
|
--slotted-focus-ring-color: var(
|
|
417
424
|
--slotted-otp-input-invalid-focus-ring-color,
|
|
418
425
|
var(--slotted-focus-ring-color-invalid, Highlight)
|
|
419
426
|
);
|
|
420
427
|
}
|
|
421
428
|
|
|
422
|
-
[data-ui
|
|
429
|
+
[data-ui-otp-input][data-part-root][data-invalid] [data-part-slot] {
|
|
423
430
|
--_invalid-edge-width: var(
|
|
424
431
|
--slotted-otp-input-invalid-edge-width,
|
|
425
432
|
var(--slotted-control-invalid-edge-width, 1px)
|
|
@@ -440,8 +447,8 @@
|
|
|
440
447
|
box-shadow: var(--_invalid-edge);
|
|
441
448
|
}
|
|
442
449
|
|
|
443
|
-
[data-ui
|
|
444
|
-
[data-part
|
|
450
|
+
[data-ui-otp-input][data-part-root][data-invalid]:has(> [data-part-input]:focus-visible)
|
|
451
|
+
[data-part-slot][data-current] {
|
|
445
452
|
box-shadow:
|
|
446
453
|
var(--_invalid-edge),
|
|
447
454
|
var(--slotted-control-shadow-focus-geometry, 0 1px 4px -1px)
|
|
@@ -454,18 +461,21 @@
|
|
|
454
461
|
* control draws its ring double, which a valid ring is not.
|
|
455
462
|
*/
|
|
456
463
|
@media (forced-colors: active) {
|
|
457
|
-
[data-ui
|
|
464
|
+
[data-ui-otp-input][data-part-root][data-invalid] [data-part-slot] {
|
|
458
465
|
outline: var(--_invalid-edge-width) solid CanvasText;
|
|
459
466
|
outline-offset: calc(
|
|
460
467
|
-1 * (var(--slotted-control-border-width, 1px) + var(--_invalid-edge-width))
|
|
461
468
|
);
|
|
462
469
|
}
|
|
463
470
|
|
|
464
|
-
[data-ui
|
|
465
|
-
[data-part
|
|
471
|
+
[data-ui-otp-input][data-part-root][data-invalid]:has(> [data-part-input]:focus-visible)
|
|
472
|
+
[data-part-slot][data-current] {
|
|
466
473
|
outline: calc(var(--slotted-focus-ring-width, 2px) + var(--_invalid-edge-width)) double
|
|
467
474
|
var(--slotted-focus-ring-color, Highlight);
|
|
468
|
-
outline-offset: var(
|
|
475
|
+
outline-offset: var(
|
|
476
|
+
--slotted-control-focus-ring-offset,
|
|
477
|
+
var(--slotted-focus-ring-offset, 2px)
|
|
478
|
+
);
|
|
469
479
|
}
|
|
470
480
|
}
|
|
471
481
|
|
|
@@ -475,7 +485,7 @@
|
|
|
475
485
|
* ground says "not yours to change" and the ink says nothing at all. No
|
|
476
486
|
* caret either โ there is nothing to type.
|
|
477
487
|
*/
|
|
478
|
-
[data-ui
|
|
488
|
+
[data-ui-otp-input][data-part-root][data-readonly] [data-part-slot] {
|
|
479
489
|
background-color: var(
|
|
480
490
|
--slotted-otp-input-readonly-background,
|
|
481
491
|
var(--slotted-tone-secondary-subtle-hover)
|
|
@@ -483,7 +493,7 @@
|
|
|
483
493
|
cursor: default;
|
|
484
494
|
}
|
|
485
495
|
|
|
486
|
-
[data-ui
|
|
496
|
+
[data-ui-otp-input][data-part-root][data-readonly] [data-part-slot]::after {
|
|
487
497
|
content: none;
|
|
488
498
|
}
|
|
489
499
|
|
|
@@ -493,14 +503,14 @@
|
|
|
493
503
|
* disabled `fieldset` disables every control inside it, and the control has
|
|
494
504
|
* no way to know.
|
|
495
505
|
*/
|
|
496
|
-
[data-ui
|
|
497
|
-
[data-ui
|
|
506
|
+
[data-ui-otp-input][data-part-root][data-disabled],
|
|
507
|
+
[data-ui-otp-input][data-part-root]:has(> [data-part-input]:disabled) {
|
|
498
508
|
color: var(--slotted-otp-input-disabled-color, var(--slotted-disabled-foreground));
|
|
499
509
|
cursor: not-allowed;
|
|
500
510
|
}
|
|
501
511
|
|
|
502
|
-
[data-ui
|
|
503
|
-
[data-ui
|
|
512
|
+
[data-ui-otp-input][data-part-root][data-disabled] [data-part-slot],
|
|
513
|
+
[data-ui-otp-input][data-part-root]:has(> [data-part-input]:disabled) [data-part-slot] {
|
|
504
514
|
background-color: var(
|
|
505
515
|
--slotted-otp-input-disabled-background,
|
|
506
516
|
var(--slotted-disabled-background)
|
|
@@ -518,7 +528,7 @@
|
|
|
518
528
|
* theme already remaps.
|
|
519
529
|
*/
|
|
520
530
|
@media (forced-colors: active) {
|
|
521
|
-
[data-ui
|
|
531
|
+
[data-ui-otp-input] > [data-part-input] {
|
|
522
532
|
forced-color-adjust: none;
|
|
523
533
|
}
|
|
524
534
|
}
|
package/src/page/page.css
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* The column of a screen: who scrolls, how wide the content is, where the
|
|
4
4
|
* footer stays, how much air the body has.
|
|
5
5
|
*
|
|
6
|
-
* main[data-ui
|
|
6
|
+
* main[data-ui-page]
|
|
7
7
|
* โโ scroll โธ page-header ยท body โธ container โธ โฆ
|
|
8
8
|
* โโ footer โธ container โธ actions
|
|
9
9
|
*
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* `self` the scroll part is the scroller, the page is exactly as tall as its
|
|
14
14
|
* parent lets it be, and the footer sits below the scroller in the flow.
|
|
15
15
|
*/
|
|
16
|
-
[data-ui
|
|
16
|
+
[data-ui-page] {
|
|
17
17
|
--_ground: var(--slotted-page-background-sunken, var(--slotted-surface-sunken, Canvas));
|
|
18
18
|
--_padding-block: var(--slotted-page-padding-block, var(--slotted-space-8, 1.5rem));
|
|
19
19
|
--_footer-ground: var(--slotted-page-footer-background, var(--slotted-surface, Canvas));
|
|
@@ -54,11 +54,11 @@
|
|
|
54
54
|
min-inline-size: 0;
|
|
55
55
|
}
|
|
56
56
|
|
|
57
|
-
[data-ui
|
|
57
|
+
[data-ui-page][data-ground='surface'] {
|
|
58
58
|
--_ground: var(--slotted-page-background-surface, var(--slotted-surface, Canvas));
|
|
59
59
|
}
|
|
60
60
|
|
|
61
|
-
[data-ui
|
|
61
|
+
[data-ui-page] > [data-part-scroll] {
|
|
62
62
|
display: flex;
|
|
63
63
|
flex: 1 0 auto;
|
|
64
64
|
flex-direction: column;
|
|
@@ -72,11 +72,11 @@
|
|
|
72
72
|
overflow-anchor: none;
|
|
73
73
|
}
|
|
74
74
|
|
|
75
|
-
[data-ui
|
|
75
|
+
[data-ui-page][data-scroll='self'] {
|
|
76
76
|
block-size: 100%;
|
|
77
77
|
min-block-size: 0;
|
|
78
78
|
}
|
|
79
|
-
[data-ui
|
|
79
|
+
[data-ui-page][data-scroll='self'] > [data-part-scroll] {
|
|
80
80
|
flex: 1 1 auto;
|
|
81
81
|
min-block-size: 0;
|
|
82
82
|
overflow: auto;
|
|
@@ -85,7 +85,7 @@
|
|
|
85
85
|
|
|
86
86
|
/* โโ The body โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ */
|
|
87
87
|
|
|
88
|
-
[data-ui
|
|
88
|
+
[data-ui-page] > [data-part-scroll] > [data-part-body] {
|
|
89
89
|
flex: 1 0 auto;
|
|
90
90
|
min-inline-size: 0;
|
|
91
91
|
padding-block: var(--_padding-block);
|
|
@@ -102,19 +102,19 @@
|
|
|
102
102
|
* chrome above a filled list left its rows 155 of 667 pixels.
|
|
103
103
|
*/
|
|
104
104
|
@container slotted-page (width >= 600px) {
|
|
105
|
-
[data-ui
|
|
105
|
+
[data-ui-page][data-fill] > [data-part-scroll] > [data-part-body] {
|
|
106
106
|
display: flex;
|
|
107
107
|
flex: 1 1 auto;
|
|
108
108
|
flex-direction: column;
|
|
109
109
|
min-block-size: 0;
|
|
110
110
|
}
|
|
111
|
-
[data-ui
|
|
111
|
+
[data-ui-page][data-fill] > [data-part-scroll] > [data-part-body] > * {
|
|
112
112
|
flex: 1 1 auto;
|
|
113
113
|
min-block-size: 0;
|
|
114
114
|
}
|
|
115
115
|
}
|
|
116
116
|
|
|
117
|
-
[data-ui
|
|
117
|
+
[data-ui-page][data-loading] > [data-part-scroll] > [data-part-body] {
|
|
118
118
|
cursor: progress;
|
|
119
119
|
}
|
|
120
120
|
|
|
@@ -126,7 +126,7 @@
|
|
|
126
126
|
* under it. It enters from below and leaves the same way; presence holds
|
|
127
127
|
* it through the exit.
|
|
128
128
|
*/
|
|
129
|
-
[data-ui
|
|
129
|
+
[data-ui-page] > [data-part-footer] {
|
|
130
130
|
background-color: var(--_footer-ground);
|
|
131
131
|
border-block-start: var(--slotted-border-width-thin, 1px) solid var(--_footer-rule);
|
|
132
132
|
inset-block-end: 0;
|
|
@@ -138,16 +138,32 @@
|
|
|
138
138
|
opacity var(--_duration) var(--_easing);
|
|
139
139
|
z-index: var(--slotted-z-index-sticky, 100);
|
|
140
140
|
}
|
|
141
|
-
[data-ui
|
|
141
|
+
[data-ui-page][data-scroll='self'] > [data-part-footer] {
|
|
142
142
|
position: static;
|
|
143
143
|
}
|
|
144
|
-
[data-ui
|
|
145
|
-
[data-ui
|
|
144
|
+
[data-ui-page] > [data-part-footer][data-status='entering'],
|
|
145
|
+
[data-ui-page] > [data-part-footer][data-status='exiting'] {
|
|
146
146
|
opacity: 0;
|
|
147
147
|
translate: 0 100%;
|
|
148
148
|
}
|
|
149
149
|
|
|
150
|
-
|
|
150
|
+
/**
|
|
151
|
+
* A theme draws the footer as a material with a ground that has alpha and
|
|
152
|
+
* `--slotted-page-footer-backdrop-filter`, `none` unless set. The footer's
|
|
153
|
+
* own fade keeps the filter drawn: only an ancestor's opacity removes it.
|
|
154
|
+
*/
|
|
155
|
+
[data-ui-page] > [data-part-footer] {
|
|
156
|
+
-webkit-backdrop-filter: var(--slotted-page-footer-backdrop-filter, none);
|
|
157
|
+
backdrop-filter: var(--slotted-page-footer-backdrop-filter, none);
|
|
158
|
+
}
|
|
159
|
+
@media (prefers-reduced-transparency: reduce), (forced-colors: active) {
|
|
160
|
+
[data-ui-page] > [data-part-footer] {
|
|
161
|
+
-webkit-backdrop-filter: none;
|
|
162
|
+
backdrop-filter: none;
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
[data-ui-page] > [data-part-footer] > * > [data-part-actions] {
|
|
151
167
|
align-items: center;
|
|
152
168
|
display: flex;
|
|
153
169
|
flex-wrap: wrap;
|
|
@@ -165,14 +181,14 @@
|
|
|
165
181
|
* they take 16. The steps under 4 keep their own value.
|
|
166
182
|
*/
|
|
167
183
|
@container slotted-page (width < 600px) {
|
|
168
|
-
[data-ui
|
|
169
|
-
[data-ui
|
|
170
|
-
[data-ui
|
|
171
|
-
[data-ui
|
|
172
|
-
[data-ui
|
|
173
|
-
[data-ui
|
|
174
|
-
[data-ui
|
|
175
|
-
[data-ui
|
|
184
|
+
[data-ui-page] [data-ui-container][data-inset='5'],
|
|
185
|
+
[data-ui-page] [data-ui-container][data-inset='6'],
|
|
186
|
+
[data-ui-page] [data-ui-container][data-inset='7'],
|
|
187
|
+
[data-ui-page] [data-ui-container][data-inset='8'],
|
|
188
|
+
[data-ui-page] [data-ui-container][data-inset='9'],
|
|
189
|
+
[data-ui-page] [data-ui-container][data-inset='10'],
|
|
190
|
+
[data-ui-page] [data-ui-container][data-inset='11'],
|
|
191
|
+
[data-ui-page] [data-ui-container][data-inset='12'] {
|
|
176
192
|
--_inset: var(--slotted-space-4, 0.5rem);
|
|
177
193
|
}
|
|
178
194
|
}
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
"--slotted-font-family-sans",
|
|
8
8
|
"--slotted-page-background-sunken",
|
|
9
9
|
"--slotted-page-background-surface",
|
|
10
|
+
"--slotted-page-footer-backdrop-filter",
|
|
10
11
|
"--slotted-page-footer-background",
|
|
11
12
|
"--slotted-page-footer-border",
|
|
12
13
|
"--slotted-page-footer-padding-block",
|