@slotted/styles 0.1.0-beta.8 → 0.1.0-beta.9
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 +31 -32
- package/src/action-sheet/action-sheet.css +36 -36
- package/src/alert/alert.css +35 -35
- package/src/app-shell/app-shell.css +280 -299
- package/src/aspect-ratio/aspect-ratio.css +9 -9
- package/src/attachment/attachment.css +91 -99
- package/src/avatar/avatar.css +41 -41
- package/src/avatar-group/avatar-group.css +21 -22
- package/src/badge/badge.css +37 -37
- package/src/breadcrumb/breadcrumb.css +37 -37
- package/src/button/button.css +88 -69
- package/src/button-group/button-group.css +69 -73
- 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 +147 -151
- package/src/chart/chart.css +225 -240
- 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 +99 -101
- package/src/command-palette/command-palette.css +84 -90
- package/src/container/container.css +24 -24
- package/src/context-menu/context-menu.css +8 -8
- package/src/currency-field/currency-field.css +99 -104
- package/src/dashboard-grid/dashboard-grid.css +104 -107
- package/src/data-grid/data-grid.css +458 -456
- package/src/data-grid/data-grid.tokens.json +2 -0
- package/src/data-list/data-list.css +67 -69
- package/src/date-field/date-field.css +50 -50
- 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 +73 -78
- 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 +70 -70
- package/src/dialog/dialog.css +300 -148
- package/src/divider/divider.css +18 -18
- package/src/drawer/drawer.css +186 -209
- package/src/entity-picker/entity-picker.css +220 -239
- 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 +21 -24
- 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 +15 -15
- 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 +28 -28
- package/src/kbd/kbd.css +26 -26
- package/src/link/link.css +15 -15
- package/src/list/list.css +20 -20
- package/src/list-item/list-item.css +66 -66
- 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 +63 -65
- package/src/menubar/menubar.css +13 -13
- package/src/message/message.css +174 -202
- package/src/message-scroller/message-scroller.css +41 -42
- package/src/multi-select/multi-select.css +131 -137
- package/src/navigation-menu/navigation-menu.css +167 -188
- package/src/notification-center/notification-center.css +134 -148
- package/src/number-field/number-field.css +76 -81
- package/src/otp-input/otp-input.css +48 -48
- package/src/page/page.css +23 -23
- package/src/page-header/page-header.css +219 -280
- package/src/pagination/pagination.css +68 -72
- package/src/popover/popover.css +40 -49
- package/src/progress-indicator/progress-indicator.css +85 -90
- package/src/prompt-composer/prompt-composer.css +94 -99
- package/src/prose/prose.css +71 -75
- package/src/radio-group/radio-group.css +98 -103
- package/src/rating/rating.css +132 -132
- package/src/result-state/result-state.css +74 -77
- package/src/saved-views/saved-views.css +41 -47
- package/src/scroll-area/scroll-area.css +32 -35
- package/src/section/section.css +16 -16
- package/src/segmented-control/segmented-control.css +77 -79
- package/src/select/select.css +113 -115
- package/src/side-navigation/side-navigation.css +170 -180
- package/src/skeleton/skeleton.css +47 -48
- package/src/slider/slider.css +86 -88
- package/src/sparkline/sparkline.css +32 -32
- package/src/spinner/spinner.css +4 -4
- package/src/split-button/split-button.css +26 -31
- package/src/splitter/splitter.css +35 -35
- package/src/stack/stack.css +24 -24
- package/src/stat-card/stat-card.css +102 -103
- 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 +189 -198
- package/src/table-of-contents/table-of-contents.css +51 -54
- package/src/tabs/tabs.css +143 -162
- package/src/tag/tag.css +67 -71
- package/src/tags-input/tags-input.css +124 -74
- package/src/tags-input/tags-input.tokens.json +6 -1
- package/src/text-field/text-field.css +108 -126
- package/src/textarea/textarea.css +26 -26
- package/src/time-field/time-field.css +67 -67
- 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 +244 -266
- package/src/toast/toast.css +81 -90
- package/src/toggle/toggle.css +29 -33
- package/src/toggle-group/toggle-group.css +67 -71
- 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 +36 -36
- package/src/upload/upload.css +224 -224
- package/src/visually-hidden/visually-hidden.css +1 -1
- package/src/wizard/wizard.css +185 -197
|
@@ -2,9 +2,10 @@
|
|
|
2
2
|
/**
|
|
3
3
|
* ── A frame of typed values, with a field that adds more ────────────────
|
|
4
4
|
*
|
|
5
|
-
* One subtree, where the consumer wrote it. Nothing is portalled
|
|
6
|
-
*
|
|
7
|
-
*
|
|
5
|
+
* One subtree, where the consumer wrote it. Nothing is portalled: the
|
|
6
|
+
* input is a text box, and the values beside it are the texts the reader
|
|
7
|
+
* typed. With `suggestions` the one thing that opens is the listbox of
|
|
8
|
+
* them, placed under the frame by the positioner with a fixed position.
|
|
8
9
|
*
|
|
9
10
|
* ┌─ root ─ the frame ─────────────────────────────────────────┐
|
|
10
11
|
* │ ┌─ control ─ role="grid" ───────────────┐ │
|
|
@@ -53,7 +54,7 @@
|
|
|
53
54
|
|
|
54
55
|
/* ── The frame ────────────────────────────────────────────────────────── */
|
|
55
56
|
|
|
56
|
-
[data-ui
|
|
57
|
+
[data-ui-tags-input][data-part-root] {
|
|
57
58
|
--_font-size: var(--slotted-control-font-size-md, 13px);
|
|
58
59
|
--_height: var(--slotted-control-height-md, 34px);
|
|
59
60
|
--_padding-inline: var(--slotted-control-padding-inline-md, 13px);
|
|
@@ -123,7 +124,7 @@
|
|
|
123
124
|
box-shadow var(--slotted-control-transition-duration) var(--slotted-control-transition-easing);
|
|
124
125
|
}
|
|
125
126
|
|
|
126
|
-
[data-ui
|
|
127
|
+
[data-ui-tags-input][data-part-root]:not([data-full-width]) {
|
|
127
128
|
inline-size: auto;
|
|
128
129
|
}
|
|
129
130
|
|
|
@@ -132,7 +133,7 @@
|
|
|
132
133
|
* role is what the layout-grid pattern asks for, and the geometry belongs to
|
|
133
134
|
* the row that wraps.
|
|
134
135
|
*/
|
|
135
|
-
[data-ui
|
|
136
|
+
[data-ui-tags-input] > [data-part-control] {
|
|
136
137
|
display: flex;
|
|
137
138
|
flex: 1 1 auto;
|
|
138
139
|
min-inline-size: 0;
|
|
@@ -145,7 +146,7 @@
|
|
|
145
146
|
* what is typed and what acts on it is never narrower than the rhythm inside
|
|
146
147
|
* it. `multi-select` measured the two-pixel version of this and rejected it.
|
|
147
148
|
*/
|
|
148
|
-
[data-ui
|
|
149
|
+
[data-ui-tags-input] > [data-part-control] + * {
|
|
149
150
|
margin-inline-start: var(--_row-gap);
|
|
150
151
|
}
|
|
151
152
|
|
|
@@ -154,7 +155,7 @@
|
|
|
154
155
|
* the reading order stays linear and "previous" and "next" have one meaning
|
|
155
156
|
* each — which is why the grid answers neither `ArrowDown` nor `ArrowUp`.
|
|
156
157
|
*/
|
|
157
|
-
[data-ui
|
|
158
|
+
[data-ui-tags-input] [data-part-chips] {
|
|
158
159
|
/* `safe`, because this box scrolls: centring a scroll container's content
|
|
159
160
|
pushes the first line above the scrollport when there is more than fits,
|
|
160
161
|
and nothing can scroll back to it. `multi-select` found the first three
|
|
@@ -193,7 +194,7 @@
|
|
|
193
194
|
scrollbar-width: none;
|
|
194
195
|
}
|
|
195
196
|
|
|
196
|
-
[data-ui
|
|
197
|
+
[data-ui-tags-input] [data-part-chips]::-webkit-scrollbar {
|
|
197
198
|
display: none;
|
|
198
199
|
}
|
|
199
200
|
|
|
@@ -203,7 +204,7 @@
|
|
|
203
204
|
* hold the rest, so the row itself opens — the rule after this one — while
|
|
204
205
|
* the control has focus within.
|
|
205
206
|
*/
|
|
206
|
-
[data-ui
|
|
207
|
+
[data-ui-tags-input][data-overflow='collapse']:not([data-expanded]) [data-part-chips] {
|
|
207
208
|
flex-wrap: nowrap;
|
|
208
209
|
max-block-size: none;
|
|
209
210
|
overflow: hidden;
|
|
@@ -218,9 +219,7 @@
|
|
|
218
219
|
* No transition. The row's height changes as focus arrives, and a transition
|
|
219
220
|
* would make the reader wait for the chip they are about to reach.
|
|
220
221
|
*/
|
|
221
|
-
[data-ui
|
|
222
|
-
[data-part='chips']
|
|
223
|
-
> [data-count] {
|
|
222
|
+
[data-ui-tags-input][data-overflow='collapse'][data-expanded] [data-part-chips] > [data-count] {
|
|
224
223
|
display: none;
|
|
225
224
|
}
|
|
226
225
|
|
|
@@ -232,7 +231,7 @@
|
|
|
232
231
|
* belongs to the chip, and the query's own input is told apart by the part it
|
|
233
232
|
* does have.
|
|
234
233
|
*/
|
|
235
|
-
[data-ui
|
|
234
|
+
[data-ui-tags-input] [data-part-chips] input:not([data-part-input]) {
|
|
236
235
|
background-color: transparent;
|
|
237
236
|
border: 0;
|
|
238
237
|
color: inherit;
|
|
@@ -249,7 +248,7 @@
|
|
|
249
248
|
* target minimum — so three of them plus their gaps divide the cap above
|
|
250
249
|
* exactly, and no fourth row shows as a sliver under the third.
|
|
251
250
|
*/
|
|
252
|
-
[data-ui
|
|
251
|
+
[data-ui-tags-input] [data-part-chips] > :not([data-part-field]) {
|
|
253
252
|
flex: 0 0 auto;
|
|
254
253
|
max-inline-size: 100%;
|
|
255
254
|
min-block-size: var(--_row-size);
|
|
@@ -259,10 +258,10 @@
|
|
|
259
258
|
/**
|
|
260
259
|
* The chip takes the height the inside of this control has, through the
|
|
261
260
|
* property `tag` reads for it. Set on the row, inherited by every chip, and
|
|
262
|
-
* no rule of this sheet names `[data-ui
|
|
261
|
+
* no rule of this sheet names `[data-ui-tag]`: the host stands beside the
|
|
263
262
|
* tag sheet and never reaches into it.
|
|
264
263
|
*/
|
|
265
|
-
[data-ui
|
|
264
|
+
[data-ui-tags-input] [data-part-chips] {
|
|
266
265
|
--slotted-control-inner-size: var(--_inner-size);
|
|
267
266
|
}
|
|
268
267
|
|
|
@@ -273,7 +272,7 @@
|
|
|
273
272
|
* has somewhere to type and a 240-pixel control holding two values does not
|
|
274
273
|
* stand two rows tall with one row empty.
|
|
275
274
|
*/
|
|
276
|
-
[data-ui
|
|
275
|
+
[data-ui-tags-input] [data-part-field] {
|
|
277
276
|
align-items: center;
|
|
278
277
|
display: flex;
|
|
279
278
|
flex: 1 1 var(--slotted-tags-input-field-basis, 4rem);
|
|
@@ -287,7 +286,7 @@
|
|
|
287
286
|
* composition, autofill, the browser's own completion from a `datalist`, and
|
|
288
287
|
* every native attribute the consumer wrote.
|
|
289
288
|
*/
|
|
290
|
-
[data-ui
|
|
289
|
+
[data-ui-tags-input] [data-part-input] {
|
|
291
290
|
background-color: transparent;
|
|
292
291
|
border: 0;
|
|
293
292
|
color: inherit;
|
|
@@ -302,7 +301,7 @@
|
|
|
302
301
|
text-overflow: ellipsis;
|
|
303
302
|
}
|
|
304
303
|
|
|
305
|
-
[data-ui
|
|
304
|
+
[data-ui-tags-input] [data-part-input]::placeholder {
|
|
306
305
|
color: var(--slotted-tags-input-placeholder-color, var(--slotted-text-muted, GrayText));
|
|
307
306
|
text-overflow: ellipsis;
|
|
308
307
|
}
|
|
@@ -313,7 +312,7 @@
|
|
|
313
312
|
* rather than erased, in the accent surface the theme owns — the repair
|
|
314
313
|
* `text-field` makes, for the same reason.
|
|
315
314
|
*/
|
|
316
|
-
[data-ui
|
|
315
|
+
[data-ui-tags-input] [data-part-input]:autofill {
|
|
317
316
|
box-shadow: inset 0 0 0 100px
|
|
318
317
|
var(--slotted-tags-input-autofill-background, var(--slotted-tone-accent-surface));
|
|
319
318
|
-webkit-text-fill-color: var(--slotted-tags-input-color, var(--slotted-text, CanvasText));
|
|
@@ -337,7 +336,7 @@
|
|
|
337
336
|
* its own inner ring two widths in to keep a sliver of ground outside it;
|
|
338
337
|
* here that sliver would cost the text its leading.
|
|
339
338
|
*/
|
|
340
|
-
[data-ui
|
|
339
|
+
[data-ui-tags-input] [data-part-chips] > :not([data-part-field]):focus-visible {
|
|
341
340
|
outline: var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);
|
|
342
341
|
outline-offset: calc(-1 * var(--slotted-focus-ring-width, 2px));
|
|
343
342
|
}
|
|
@@ -347,9 +346,9 @@
|
|
|
347
346
|
* takes focus, and for one long step of the motion scale its edge is the
|
|
348
347
|
* accent's, so a reader who looked away from the ring still sees which chip
|
|
349
348
|
* answered — through the edge token `tag` reads, so this sheet names
|
|
350
|
-
* `[data-ui
|
|
349
|
+
* `[data-ui-tag]` nowhere.
|
|
351
350
|
*/
|
|
352
|
-
[data-ui
|
|
351
|
+
[data-ui-tags-input] [data-part-chips] > [data-current] {
|
|
353
352
|
--slotted-tag-border-color: var(
|
|
354
353
|
--slotted-tags-input-current-border-color,
|
|
355
354
|
var(--slotted-tone-accent-border)
|
|
@@ -362,7 +361,7 @@
|
|
|
362
361
|
* whose last one happens to be a count, and `createCollapse` measures it the
|
|
363
362
|
* way it measures every other unit.
|
|
364
363
|
*/
|
|
365
|
-
[data-ui
|
|
364
|
+
[data-ui-tags-input] [data-part-chips] > [data-count] {
|
|
366
365
|
cursor: pointer;
|
|
367
366
|
flex: none;
|
|
368
367
|
}
|
|
@@ -373,7 +372,7 @@
|
|
|
373
372
|
* too narrow for a chip — because a counter with nothing to count against is
|
|
374
373
|
* furniture.
|
|
375
374
|
*/
|
|
376
|
-
[data-ui
|
|
375
|
+
[data-ui-tags-input] > [data-part-counter] {
|
|
377
376
|
align-self: center;
|
|
378
377
|
color: var(--slotted-tags-input-counter-color, var(--slotted-text-muted, GrayText));
|
|
379
378
|
flex: none;
|
|
@@ -393,13 +392,13 @@
|
|
|
393
392
|
* uses for a chosen value. Not a warning tone: reaching the limit is the
|
|
394
393
|
* reader arriving somewhere, not going wrong.
|
|
395
394
|
*/
|
|
396
|
-
[data-ui
|
|
395
|
+
[data-ui-tags-input][data-complete] > [data-part-counter] {
|
|
397
396
|
color: var(--slotted-tags-input-counter-complete-color, var(--slotted-tone-accent-text));
|
|
398
397
|
font-weight: var(--slotted-font-weight-medium, 500);
|
|
399
398
|
}
|
|
400
399
|
|
|
401
400
|
/* Too narrow for a chip: the count is the whole answer. */
|
|
402
|
-
[data-ui
|
|
401
|
+
[data-ui-tags-input][data-narrow] [data-part-chips] > :not([data-part-field]) {
|
|
403
402
|
display: none;
|
|
404
403
|
}
|
|
405
404
|
|
|
@@ -412,7 +411,7 @@
|
|
|
412
411
|
* The `message` lives inside the chip and the `hint` beside the row; both
|
|
413
412
|
* are positioned against the frame, which is the nearest containing block.
|
|
414
413
|
*/
|
|
415
|
-
[data-ui
|
|
414
|
+
[data-ui-tags-input] :is([data-part-message], [data-part-hint]) {
|
|
416
415
|
block-size: 1px;
|
|
417
416
|
border: 0;
|
|
418
417
|
clip-path: inset(50%);
|
|
@@ -426,7 +425,7 @@
|
|
|
426
425
|
|
|
427
426
|
/* ── The button inside the frame ──────────────────────────────────────── */
|
|
428
427
|
|
|
429
|
-
[data-ui
|
|
428
|
+
[data-ui-tags-input] > [data-part-clear] {
|
|
430
429
|
align-items: center;
|
|
431
430
|
align-self: center;
|
|
432
431
|
appearance: none;
|
|
@@ -458,7 +457,7 @@
|
|
|
458
457
|
* control is 24 pixels tall — the WCAG 2.2 minimum — so nothing drawn inside
|
|
459
458
|
* it can also be 24.
|
|
460
459
|
*/
|
|
461
|
-
[data-ui
|
|
460
|
+
[data-ui-tags-input] > [data-part-clear]::after {
|
|
462
461
|
content: '';
|
|
463
462
|
inset: min(0px, calc((100% - var(--slotted-target-min, 24px)) / 2));
|
|
464
463
|
position: absolute;
|
|
@@ -469,7 +468,7 @@
|
|
|
469
468
|
the hit area above grows to 44 pixels around them. It does not reach back
|
|
470
469
|
over the chips, where the last chip's remove stands a few pixels away. */
|
|
471
470
|
@media (pointer: coarse) {
|
|
472
|
-
[data-ui
|
|
471
|
+
[data-ui-tags-input] > [data-part-clear]::after {
|
|
473
472
|
inset: min(0px, calc((100% - var(--slotted-target-comfortable, 44px)) / 2));
|
|
474
473
|
inset-inline-start: 0;
|
|
475
474
|
}
|
|
@@ -477,13 +476,13 @@
|
|
|
477
476
|
|
|
478
477
|
/* The cross is the `Glyph` element the binding renders inside the button,
|
|
479
478
|
drawn at the control's own icon step. */
|
|
480
|
-
[data-ui
|
|
479
|
+
[data-ui-tags-input] > [data-part-clear] {
|
|
481
480
|
--slotted-icon-size: var(--_icon-size);
|
|
482
481
|
}
|
|
483
482
|
|
|
484
483
|
/* ── Size ─────────────────────────────────────────────────────────────── */
|
|
485
484
|
|
|
486
|
-
[data-ui
|
|
485
|
+
[data-ui-tags-input][data-part-root][data-size='sm'] {
|
|
487
486
|
--_font-size: var(--slotted-control-font-size-sm, 12px);
|
|
488
487
|
--_height: var(--slotted-control-height-sm, 30px);
|
|
489
488
|
--_inner-size: var(--slotted-control-inner-size-sm, 22px);
|
|
@@ -492,7 +491,7 @@
|
|
|
492
491
|
--_icon-size: max(var(--_icon-floor), var(--slotted-control-icon-size-sm, 14px));
|
|
493
492
|
}
|
|
494
493
|
|
|
495
|
-
[data-ui
|
|
494
|
+
[data-ui-tags-input][data-part-root][data-size='md'] {
|
|
496
495
|
--_font-size: var(--slotted-control-font-size-md, 13px);
|
|
497
496
|
--_height: var(--slotted-control-height-md, 34px);
|
|
498
497
|
--_padding-inline: var(--slotted-control-padding-inline-md, 13px);
|
|
@@ -501,7 +500,7 @@
|
|
|
501
500
|
--_inner-size: var(--slotted-control-inner-size-md, 24px);
|
|
502
501
|
}
|
|
503
502
|
|
|
504
|
-
[data-ui
|
|
503
|
+
[data-ui-tags-input][data-part-root][data-size='lg'] {
|
|
505
504
|
--_font-size: var(--slotted-control-font-size-lg, 14px);
|
|
506
505
|
--_height: var(--slotted-control-height-lg, 38px);
|
|
507
506
|
--_inner-size: var(--slotted-control-inner-size-lg, 28px);
|
|
@@ -512,7 +511,7 @@
|
|
|
512
511
|
|
|
513
512
|
/* ── Variant ──────────────────────────────────────────────────────────── */
|
|
514
513
|
|
|
515
|
-
[data-ui
|
|
514
|
+
[data-ui-tags-input][data-part-root][data-variant='subtle'] {
|
|
516
515
|
background-color: var(
|
|
517
516
|
--slotted-tags-input-subtle-background,
|
|
518
517
|
var(--slotted-surface-sunken, Canvas)
|
|
@@ -526,7 +525,7 @@
|
|
|
526
525
|
/* No edge, no lift, no ground and no corner of its own: the cell it sits in
|
|
527
526
|
is the box, the row is the ground, a cell has no corner, and the resting
|
|
528
527
|
shadow would draw the cell where there is none. */
|
|
529
|
-
[data-ui
|
|
528
|
+
[data-ui-tags-input][data-part-root][data-variant='plain'] {
|
|
530
529
|
background-color: transparent;
|
|
531
530
|
border-color: transparent;
|
|
532
531
|
border-radius: var(--slotted-radius-none, 0px);
|
|
@@ -534,20 +533,20 @@
|
|
|
534
533
|
}
|
|
535
534
|
|
|
536
535
|
@media (forced-colors: active) {
|
|
537
|
-
[data-ui
|
|
536
|
+
[data-ui-tags-input][data-part-root][data-variant='plain'] {
|
|
538
537
|
border-color: ButtonBorder;
|
|
539
538
|
}
|
|
540
539
|
}
|
|
541
540
|
|
|
542
541
|
/* ── States on the control ────────────────────────────────────────────── */
|
|
543
542
|
|
|
544
|
-
[data-ui
|
|
543
|
+
[data-ui-tags-input][data-part-root]:hover:not([data-disabled]):not([data-readonly]):not(
|
|
545
544
|
[data-invalid]
|
|
546
545
|
) {
|
|
547
546
|
border-color: var(--slotted-tags-input-hover-border-color, var(--slotted-tone-accent-border));
|
|
548
547
|
}
|
|
549
548
|
|
|
550
|
-
[data-ui
|
|
549
|
+
[data-ui-tags-input][data-part-root][data-variant='subtle']:hover:not([data-disabled]):not(
|
|
551
550
|
[data-readonly]
|
|
552
551
|
):not([data-invalid]) {
|
|
553
552
|
background-color: var(
|
|
@@ -556,7 +555,7 @@
|
|
|
556
555
|
);
|
|
557
556
|
}
|
|
558
557
|
|
|
559
|
-
[data-ui
|
|
558
|
+
[data-ui-tags-input][data-part-root][data-variant='plain']:hover:not([data-disabled]):not(
|
|
560
559
|
[data-readonly]
|
|
561
560
|
):not([data-invalid]) {
|
|
562
561
|
background-color: var(
|
|
@@ -571,9 +570,9 @@
|
|
|
571
570
|
* The frame carries the ring for whatever inside it holds focus — the input
|
|
572
571
|
* or a chip — because the frame is the control a reader is operating.
|
|
573
572
|
*/
|
|
574
|
-
[data-ui
|
|
575
|
-
[data-ui
|
|
576
|
-
[data-part
|
|
573
|
+
[data-ui-tags-input][data-part-root]:has([data-part-input]:focus-visible),
|
|
574
|
+
[data-ui-tags-input][data-part-root]:has(
|
|
575
|
+
[data-part-chips] > :not([data-part-field]):focus-visible
|
|
577
576
|
) {
|
|
578
577
|
box-shadow: var(--slotted-control-shadow-focus-geometry, 0 1px 4px -1px)
|
|
579
578
|
var(--slotted-focus-ring-color, Highlight);
|
|
@@ -588,11 +587,9 @@
|
|
|
588
587
|
* shadow that appears only under focus is a cell that changes size when it
|
|
589
588
|
* is used.
|
|
590
589
|
*/
|
|
591
|
-
[data-ui
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
[data-ui='tags-input'][data-part='root'][data-variant='plain']:has(
|
|
595
|
-
[data-part='chips'] > :not([data-part='field']):focus-visible
|
|
590
|
+
[data-ui-tags-input][data-part-root][data-variant='plain']:has([data-part-input]:focus-visible),
|
|
591
|
+
[data-ui-tags-input][data-part-root][data-variant='plain']:has(
|
|
592
|
+
[data-part-chips] > :not([data-part-field]):focus-visible
|
|
596
593
|
) {
|
|
597
594
|
box-shadow: none;
|
|
598
595
|
outline-offset: calc(var(--slotted-focus-ring-offset, 2px) * -1);
|
|
@@ -603,13 +600,13 @@
|
|
|
603
600
|
* is two rings for one focus. The frame keeps its lift and gives up the
|
|
604
601
|
* outline while the ring is inside it.
|
|
605
602
|
*/
|
|
606
|
-
[data-ui
|
|
607
|
-
[data-part
|
|
603
|
+
[data-ui-tags-input][data-part-root]:has(
|
|
604
|
+
[data-part-chips] > :not([data-part-field]):focus-visible
|
|
608
605
|
) {
|
|
609
606
|
outline: none;
|
|
610
607
|
}
|
|
611
608
|
|
|
612
|
-
[data-ui
|
|
609
|
+
[data-ui-tags-input][data-part-root][data-invalid] {
|
|
613
610
|
--slotted-focus-ring-color: var(
|
|
614
611
|
--slotted-tags-input-invalid-focus-ring-color,
|
|
615
612
|
var(--slotted-focus-ring-color-invalid, Highlight)
|
|
@@ -634,9 +631,9 @@
|
|
|
634
631
|
box-shadow: var(--_invalid-edge);
|
|
635
632
|
}
|
|
636
633
|
|
|
637
|
-
[data-ui
|
|
638
|
-
[data-ui
|
|
639
|
-
[data-part
|
|
634
|
+
[data-ui-tags-input][data-part-root][data-invalid]:has([data-part-input]:focus-visible),
|
|
635
|
+
[data-ui-tags-input][data-part-root][data-invalid]:has(
|
|
636
|
+
[data-part-chips] > :not([data-part-field]):focus-visible
|
|
640
637
|
) {
|
|
641
638
|
box-shadow:
|
|
642
639
|
var(--_invalid-edge),
|
|
@@ -644,11 +641,11 @@
|
|
|
644
641
|
var(--slotted-focus-ring-color, Highlight);
|
|
645
642
|
}
|
|
646
643
|
|
|
647
|
-
[data-ui
|
|
648
|
-
[data-part
|
|
644
|
+
[data-ui-tags-input][data-part-root][data-variant='plain'][data-invalid]:has(
|
|
645
|
+
[data-part-input]:focus-visible
|
|
649
646
|
),
|
|
650
|
-
[data-ui
|
|
651
|
-
[data-part
|
|
647
|
+
[data-ui-tags-input][data-part-root][data-variant='plain'][data-invalid]:has(
|
|
648
|
+
[data-part-chips] > :not([data-part-field]):focus-visible
|
|
652
649
|
) {
|
|
653
650
|
/* The ring lies inside the box here, over the border and an edge as wide as
|
|
654
651
|
it; the edge reaches past the ring. */
|
|
@@ -666,21 +663,21 @@
|
|
|
666
663
|
* control draws its ring double, which a valid ring is not.
|
|
667
664
|
*/
|
|
668
665
|
@media (forced-colors: active) {
|
|
669
|
-
[data-ui
|
|
666
|
+
[data-ui-tags-input][data-part-root][data-invalid] {
|
|
670
667
|
outline: var(--_invalid-edge-width) solid CanvasText;
|
|
671
668
|
outline-offset: calc(
|
|
672
669
|
-1 * (var(--slotted-control-border-width, 1px) + var(--_invalid-edge-width))
|
|
673
670
|
);
|
|
674
671
|
}
|
|
675
672
|
|
|
676
|
-
[data-ui
|
|
673
|
+
[data-ui-tags-input][data-part-root][data-invalid]:has([data-part-input]:focus-visible) {
|
|
677
674
|
outline: calc(var(--slotted-focus-ring-width, 2px) + var(--_invalid-edge-width)) double
|
|
678
675
|
var(--slotted-focus-ring-color, Highlight);
|
|
679
676
|
outline-offset: var(--slotted-focus-ring-offset, 2px);
|
|
680
677
|
}
|
|
681
678
|
|
|
682
|
-
[data-ui
|
|
683
|
-
[data-part
|
|
679
|
+
[data-ui-tags-input][data-part-root][data-variant='plain'][data-invalid]:has(
|
|
680
|
+
[data-part-input]:focus-visible
|
|
684
681
|
) {
|
|
685
682
|
outline: calc(var(--slotted-focus-ring-width, 2px) + var(--_invalid-edge-width)) double
|
|
686
683
|
var(--slotted-focus-ring-color, Highlight);
|
|
@@ -689,11 +686,11 @@
|
|
|
689
686
|
);
|
|
690
687
|
}
|
|
691
688
|
|
|
692
|
-
[data-ui
|
|
693
|
-
[data-part
|
|
689
|
+
[data-ui-tags-input][data-part-root][data-invalid]:has(
|
|
690
|
+
[data-part-chips] > :not([data-part-field]):focus-visible
|
|
694
691
|
),
|
|
695
|
-
[data-ui
|
|
696
|
-
[data-part
|
|
692
|
+
[data-ui-tags-input][data-part-root][data-variant='plain'][data-invalid]:has(
|
|
693
|
+
[data-part-chips] > :not([data-part-field]):focus-visible
|
|
697
694
|
) {
|
|
698
695
|
outline: var(--_invalid-edge-width) solid CanvasText;
|
|
699
696
|
outline-offset: calc(
|
|
@@ -707,7 +704,7 @@
|
|
|
707
704
|
* withholds every remove control. The native `readonly` gives the text half;
|
|
708
705
|
* the rest is the family's.
|
|
709
706
|
*/
|
|
710
|
-
[data-ui
|
|
707
|
+
[data-ui-tags-input][data-part-root][data-readonly] {
|
|
711
708
|
background-color: var(
|
|
712
709
|
--slotted-tags-input-readonly-background,
|
|
713
710
|
var(--slotted-tone-secondary-subtle-hover)
|
|
@@ -719,8 +716,8 @@
|
|
|
719
716
|
* because a disabled `fieldset` disables every control inside it and the
|
|
720
717
|
* control has no way to say so.
|
|
721
718
|
*/
|
|
722
|
-
[data-ui
|
|
723
|
-
[data-ui
|
|
719
|
+
[data-ui-tags-input][data-part-root][data-disabled],
|
|
720
|
+
[data-ui-tags-input][data-part-root]:has([data-part-input]:disabled) {
|
|
724
721
|
background-color: var(
|
|
725
722
|
--slotted-tags-input-disabled-background,
|
|
726
723
|
var(--slotted-disabled-background)
|
|
@@ -731,14 +728,14 @@
|
|
|
731
728
|
cursor: not-allowed;
|
|
732
729
|
}
|
|
733
730
|
|
|
734
|
-
[data-ui
|
|
731
|
+
[data-ui-tags-input] > [data-part-clear]:hover:not(:disabled):not([data-disabled]) {
|
|
735
732
|
background-color: var(
|
|
736
733
|
--slotted-tags-input-action-hover-background,
|
|
737
734
|
var(--slotted-tone-secondary-subtle-hover)
|
|
738
735
|
);
|
|
739
736
|
}
|
|
740
737
|
|
|
741
|
-
[data-ui
|
|
738
|
+
[data-ui-tags-input] > [data-part-clear]:active:not(:disabled):not([data-disabled]) {
|
|
742
739
|
background-color: var(
|
|
743
740
|
--slotted-tags-input-action-active-background,
|
|
744
741
|
var(--slotted-tone-secondary-subtle-active)
|
|
@@ -750,8 +747,61 @@
|
|
|
750
747
|
* from the input to it has to move something visible, and a ring around the
|
|
751
748
|
* whole frame would sit still while focus moved inside it.
|
|
752
749
|
*/
|
|
753
|
-
[data-ui
|
|
750
|
+
[data-ui-tags-input] > [data-part-clear]:focus-visible {
|
|
754
751
|
outline: var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);
|
|
755
752
|
outline-offset: calc(var(--slotted-focus-ring-offset, 2px) * -1);
|
|
756
753
|
}
|
|
754
|
+
|
|
755
|
+
/* ── The suggestions ──────────────────────────────────────────────────── */
|
|
756
|
+
|
|
757
|
+
/**
|
|
758
|
+
* A raised surface as wide as the frame, written where the positioner puts
|
|
759
|
+
* it: `left` and `top` are its, and the width is the anchor's, which it
|
|
760
|
+
* publishes. Ten options are seen before the list scrolls.
|
|
761
|
+
*/
|
|
762
|
+
[data-ui-tags-input] > [data-part-suggestions] {
|
|
763
|
+
background-color: var(--slotted-surface-raised, Canvas);
|
|
764
|
+
border: var(--slotted-border-width-thin, 1px) solid var(--slotted-border-subtle, GrayText);
|
|
765
|
+
border-radius: var(--slotted-radius-lg, 8px);
|
|
766
|
+
box-shadow: var(--slotted-shadow-md);
|
|
767
|
+
box-sizing: border-box;
|
|
768
|
+
color: var(--slotted-text, CanvasText);
|
|
769
|
+
font-size: var(--_font-size);
|
|
770
|
+
/* No inset of its own: the positioner writes `left` and `top`, and an
|
|
771
|
+
inline inset would resolve to `right` in a right-to-left document. */
|
|
772
|
+
inline-size: var(--slotted-positioner-anchor-width, 100%);
|
|
773
|
+
max-block-size: calc(10 * var(--_height) + 2 * var(--slotted-space-2, 0.25rem));
|
|
774
|
+
overflow-y: auto;
|
|
775
|
+
overscroll-behavior: contain;
|
|
776
|
+
padding: var(--slotted-space-2, 0.25rem);
|
|
777
|
+
position: fixed;
|
|
778
|
+
z-index: calc(var(--slotted-z-index-popover, 1100) + var(--slotted-layer-depth, 0));
|
|
779
|
+
}
|
|
780
|
+
|
|
781
|
+
/* One option is one control row, so the list reads at the frame's own step. */
|
|
782
|
+
[data-ui-tags-input] > [data-part-suggestions] > [data-part-suggestion] {
|
|
783
|
+
align-items: center;
|
|
784
|
+
border-radius: var(--slotted-control-radius, 4px);
|
|
785
|
+
cursor: default;
|
|
786
|
+
display: flex;
|
|
787
|
+
min-block-size: var(--_height);
|
|
788
|
+
overflow-wrap: anywhere;
|
|
789
|
+
padding-inline: var(--_padding-inline);
|
|
790
|
+
}
|
|
791
|
+
|
|
792
|
+
/**
|
|
793
|
+
* The highlight follows the arrow keys and the pointer alike. The `-active`
|
|
794
|
+
* step of the neutral tone, the one that lifts off a raised surface in every
|
|
795
|
+
* scheme, as `combobox.css` explains.
|
|
796
|
+
*/
|
|
797
|
+
[data-ui-tags-input] > [data-part-suggestions] > [data-highlighted] {
|
|
798
|
+
background-color: var(--slotted-tone-secondary-subtle-active);
|
|
799
|
+
}
|
|
800
|
+
|
|
801
|
+
@media (forced-colors: active) {
|
|
802
|
+
[data-ui-tags-input] > [data-part-suggestions] > [data-highlighted] {
|
|
803
|
+
background-color: Highlight;
|
|
804
|
+
color: HighlightText;
|
|
805
|
+
}
|
|
806
|
+
}
|
|
757
807
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
[
|
|
2
2
|
"--slotted-border-subtle",
|
|
3
|
+
"--slotted-border-width-thin",
|
|
3
4
|
"--slotted-control-border-color",
|
|
4
5
|
"--slotted-control-border-width",
|
|
5
6
|
"--slotted-control-font-family",
|
|
@@ -38,9 +39,12 @@
|
|
|
38
39
|
"--slotted-font-size-xs",
|
|
39
40
|
"--slotted-font-weight-medium",
|
|
40
41
|
"--slotted-line-height-sm",
|
|
42
|
+
"--slotted-radius-lg",
|
|
41
43
|
"--slotted-radius-none",
|
|
44
|
+
"--slotted-shadow-md",
|
|
42
45
|
"--slotted-space-1",
|
|
43
46
|
"--slotted-space-2",
|
|
47
|
+
"--slotted-surface-raised",
|
|
44
48
|
"--slotted-surface-sunken",
|
|
45
49
|
"--slotted-tags-input-action-active-background",
|
|
46
50
|
"--slotted-tags-input-action-color",
|
|
@@ -80,5 +84,6 @@
|
|
|
80
84
|
"--slotted-tone-accent-text",
|
|
81
85
|
"--slotted-tone-danger-border",
|
|
82
86
|
"--slotted-tone-secondary-subtle-active",
|
|
83
|
-
"--slotted-tone-secondary-subtle-hover"
|
|
87
|
+
"--slotted-tone-secondary-subtle-hover",
|
|
88
|
+
"--slotted-z-index-popover"
|
|
84
89
|
]
|