@slotted/styles 0.1.0-beta.3 → 0.1.0-beta.30
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 +13 -1
- package/src/accordion/accordion.css +11 -11
- package/src/action-bar/action-bar.css +47 -44
- package/src/action-bar/action-bar.tokens.json +1 -0
- package/src/action-sheet/action-sheet.css +39 -39
- package/src/alert/alert.css +96 -96
- package/src/alert/alert.tokens.json +5 -0
- package/src/app-shell/app-shell.css +455 -328
- package/src/app-shell/app-shell.tokens.json +5 -2
- package/src/aspect-ratio/aspect-ratio.css +9 -9
- package/src/attachment/attachment.css +118 -114
- package/src/avatar/avatar.css +96 -66
- package/src/avatar/avatar.tokens.json +7 -0
- package/src/avatar-group/avatar-group.css +22 -23
- package/src/badge/badge.css +54 -46
- package/src/badge/badge.tokens.json +5 -0
- package/src/breadcrumb/breadcrumb.css +52 -52
- package/src/button/button.css +137 -89
- package/src/button/button.tokens.json +5 -0
- package/src/button-group/button-group.css +80 -79
- package/src/button-group/button-group.tokens.json +1 -0
- package/src/calendar/calendar.css +139 -109
- package/src/calendar/calendar.tokens.json +5 -1
- package/src/card/card.css +68 -65
- package/src/carousel/carousel.css +158 -169
- package/src/cascader/cascader.css +158 -157
- package/src/cascader/cascader.tokens.json +1 -0
- package/src/chart/chart.css +288 -267
- package/src/chart/chart.tokens.json +4 -0
- package/src/checkbox/checkbox.css +143 -148
- package/src/checkbox-group/checkbox-group.css +7 -7
- package/src/code-block/code-block.css +85 -89
- package/src/collapsible/collapsible.css +76 -80
- package/src/color-picker/color-picker.css +106 -114
- package/src/column-manager/column-manager.css +111 -119
- package/src/combobox/combobox.css +203 -130
- package/src/combobox/combobox.tokens.json +3 -0
- package/src/command-palette/command-palette.css +155 -102
- package/src/command-palette/command-palette.tokens.json +2 -0
- package/src/container/container.css +27 -27
- package/src/context-menu/context-menu.css +9 -9
- package/src/currency-field/currency-field.css +119 -119
- package/src/currency-field/currency-field.tokens.json +1 -0
- package/src/dashboard-grid/dashboard-grid.css +185 -115
- package/src/data-grid/data-grid.css +598 -496
- package/src/data-grid/data-grid.tokens.json +5 -1
- package/src/data-list/data-list.css +82 -71
- package/src/data-list/data-list.tokens.json +2 -1
- package/src/date-field/date-field.css +62 -57
- package/src/date-field/date-field.tokens.json +1 -0
- package/src/date-picker/date-picker.css +117 -58
- package/src/date-picker/date-picker.tokens.json +5 -0
- package/src/date-range-picker/date-range-picker.css +157 -127
- package/src/date-range-picker/date-range-picker.tokens.json +4 -0
- package/src/datetime-field/datetime-field.css +90 -90
- package/src/datetime-field/datetime-field.tokens.json +1 -0
- package/src/datetime-picker/datetime-picker.css +123 -70
- package/src/datetime-picker/datetime-picker.tokens.json +4 -1
- package/src/datetime-range-picker/datetime-range-picker.css +191 -163
- package/src/datetime-range-picker/datetime-range-picker.tokens.json +4 -0
- package/src/description-list/description-list.css +105 -75
- package/src/description-list/description-list.tokens.json +1 -0
- package/src/detail-panel/detail-panel.css +86 -71
- package/src/detail-panel/detail-panel.tokens.json +2 -0
- package/src/dialog/dialog.css +434 -198
- package/src/dialog/dialog.tokens.json +7 -0
- package/src/divider/divider.css +20 -20
- package/src/drawer/drawer.css +597 -236
- package/src/drawer/drawer.tokens.json +13 -0
- package/src/entity-picker/entity-picker.css +323 -270
- package/src/entity-picker/entity-picker.tokens.json +3 -0
- package/src/event-calendar/event-calendar.css +357 -399
- package/src/field/field.css +106 -93
- package/src/field/field.tokens.json +2 -0
- package/src/field-group/field-group.css +43 -33
- package/src/field-group/field-group.tokens.json +3 -0
- package/src/filter-bar/filter-bar.css +200 -216
- package/src/form/form.css +99 -25
- package/src/form/form.tokens.json +5 -0
- package/src/fullscreen/fullscreen.css +26 -27
- package/src/grid/grid.css +29 -29
- package/src/highlight/highlight.css +11 -11
- package/src/hover-card/hover-card.css +9 -9
- package/src/icon/icon.css +67 -20
- package/src/icon/icon.tokens.json +1 -0
- package/src/image/image.css +42 -42
- package/src/import-export-center/import-export-center.css +144 -165
- package/src/inline/inline.css +28 -28
- package/src/inline-message/inline-message.css +162 -86
- package/src/inline-message/inline-message.tokens.json +4 -0
- package/src/kbd/kbd.css +62 -50
- package/src/kbd/kbd.tokens.json +3 -0
- package/src/link/link.css +54 -33
- package/src/link/link.tokens.json +4 -0
- package/src/list/list.css +23 -23
- package/src/list-item/list-item.css +89 -75
- package/src/list-item/list-item.tokens.json +7 -0
- package/src/listbox/listbox.css +71 -70
- package/src/listbox/listbox.tokens.json +0 -1
- package/src/loading-overlay/loading-overlay.css +86 -103
- package/src/markdown/markdown.css +20 -20
- package/src/media-viewer/media-viewer.css +790 -0
- package/src/media-viewer/media-viewer.tokens.json +53 -0
- package/src/menu/menu.css +162 -82
- package/src/menu/menu.tokens.json +2 -1
- package/src/menubar/menubar.css +16 -16
- package/src/message/message.css +1250 -1253
- package/src/message/message.tokens.json +5 -0
- package/src/message-scroller/message-scroller.css +323 -320
- package/src/multi-select/multi-select.css +230 -172
- package/src/multi-select/multi-select.tokens.json +2 -0
- package/src/navigation-menu/navigation-menu.css +169 -190
- package/src/notification-center/notification-center.css +153 -161
- package/src/notification-center/notification-center.tokens.json +3 -0
- package/src/number-field/number-field.css +93 -93
- package/src/number-field/number-field.tokens.json +1 -0
- package/src/otp-input/otp-input.css +74 -64
- package/src/otp-input/otp-input.tokens.json +1 -0
- package/src/page/page.css +41 -27
- package/src/page/page.tokens.json +1 -0
- package/src/page-header/page-header.css +341 -286
- package/src/page-header/page-header.tokens.json +5 -0
- package/src/pagination/pagination.css +75 -79
- package/src/popover/popover.css +81 -64
- package/src/popover/popover.tokens.json +1 -0
- package/src/progress-indicator/progress-indicator.css +192 -136
- package/src/progress-indicator/progress-indicator.tokens.json +1 -0
- package/src/prompt-composer/prompt-composer.css +260 -113
- package/src/prompt-composer/prompt-composer.tokens.json +15 -0
- package/src/prose/prose.css +77 -82
- package/src/radio-group/radio-group.css +107 -112
- package/src/rating/rating.css +146 -142
- package/src/rating/rating.tokens.json +1 -0
- package/src/result-state/result-state.css +94 -101
- package/src/runtime-properties.mjs +19 -6
- package/src/saved-views/saved-views.css +43 -49
- package/src/scroll-area/scroll-area.css +44 -37
- package/src/section/section.css +178 -43
- package/src/section/section.tokens.json +8 -2
- package/src/segmented-control/segmented-control.css +210 -133
- package/src/segmented-control/segmented-control.tokens.json +7 -11
- package/src/select/select.css +210 -147
- package/src/select/select.tokens.json +3 -0
- package/src/side-navigation/side-navigation.css +193 -196
- package/src/side-navigation/side-navigation.tokens.json +1 -0
- package/src/skeleton/skeleton.css +57 -58
- package/src/slider/slider.css +101 -103
- package/src/sparkline/sparkline.css +75 -53
- 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 +34 -35
- package/src/split-button/split-button.tokens.json +1 -0
- package/src/splitter/splitter.css +47 -48
- package/src/stack/stack.css +25 -25
- package/src/stat-card/stat-card.css +415 -245
- package/src/stat-card/stat-card.tokens.json +8 -0
- package/src/status-indicator/status-indicator.css +124 -100
- package/src/status-indicator/status-indicator.tokens.json +0 -3
- package/src/stepper/stepper.css +78 -82
- package/src/switch/switch.css +100 -106
- package/src/table/table.css +270 -198
- package/src/table/table.tokens.json +2 -0
- package/src/table-of-contents/table-of-contents.css +60 -59
- package/src/table-of-contents/table-of-contents.tokens.json +1 -0
- package/src/tabs/tabs.css +327 -294
- package/src/tabs/tabs.tokens.json +7 -1
- package/src/tag/tag.css +109 -88
- package/src/tag/tag.tokens.json +10 -0
- package/src/tags-input/tags-input.css +152 -87
- package/src/tags-input/tags-input.tokens.json +7 -1
- package/src/text-field/text-field.css +146 -148
- package/src/text-field/text-field.tokens.json +1 -0
- package/src/textarea/textarea.css +38 -33
- package/src/textarea/textarea.tokens.json +1 -0
- package/src/time-field/time-field.css +82 -77
- package/src/time-field/time-field.tokens.json +1 -0
- package/src/time-picker/time-picker.css +116 -64
- package/src/time-picker/time-picker.tokens.json +4 -1
- package/src/time-range-picker/time-range-picker.css +168 -140
- package/src/time-range-picker/time-range-picker.tokens.json +4 -0
- package/src/timeline/timeline.css +280 -292
- package/src/timeline/timeline.tokens.json +5 -0
- package/src/toast/toast.css +138 -121
- package/src/toast/toast.tokens.json +6 -0
- package/src/toggle/toggle.css +34 -38
- package/src/toggle-group/toggle-group.css +73 -77
- package/src/toolbar/toolbar.css +33 -38
- package/src/tooltip/tooltip.css +65 -39
- package/src/tooltip/tooltip.tokens.json +1 -0
- package/src/top-navigation/top-navigation.css +252 -268
- package/src/tour/tour.css +64 -73
- package/src/transfer/transfer.css +164 -168
- package/src/tree/tree.css +113 -121
- package/src/typography/typography.css +42 -38
- package/src/typography/typography.tokens.json +1 -0
- package/src/upload/upload.css +256 -257
- package/src/visually-hidden/visually-hidden.css +1 -1
- package/src/wizard/wizard.css +187 -199
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
* one thing a placeholder means: a surface that is not available yet. It
|
|
10
10
|
* carries a cost, and the rim is what pays it — in the `high-contrast`
|
|
11
11
|
* scheme that token is the page's own white, so a fill alone would be an
|
|
12
|
-
* invisible box. `--slotted-border-subtle` is the fill's own
|
|
12
|
+
* invisible box. `--slotted-border-subtle` is the fill's own color in
|
|
13
13
|
* light, a faint step in dark, and black in high contrast: a rim that
|
|
14
14
|
* appears exactly where the fill stops working and adds no noise where it
|
|
15
15
|
* does.
|
|
@@ -23,15 +23,15 @@
|
|
|
23
23
|
* Geometry is left unguarded because a loaded placeholder is
|
|
24
24
|
* `display: contents` and has no box for it to describe.
|
|
25
25
|
*/
|
|
26
|
-
[data-ui
|
|
27
|
-
[data-ui
|
|
26
|
+
[data-ui-skeleton][data-part-root][data-loading],
|
|
27
|
+
[data-ui-skeleton][data-part-text][data-loading] [data-part-line] {
|
|
28
28
|
/**
|
|
29
|
-
* The unavailable surface, pushed a little toward the text
|
|
29
|
+
* The unavailable surface, pushed a little toward the text color. The
|
|
30
30
|
* token alone is not enough and the first dark capture is why: in the dark
|
|
31
31
|
* scheme `--slotted-disabled-background` is `#18181b` over a `#131316`
|
|
32
32
|
* ground, one step apart, and a page of placeholders read as an empty
|
|
33
33
|
* page. Mixing toward `--slotted-text` moves away from the ground in every
|
|
34
|
-
* scheme, because the text
|
|
34
|
+
* scheme, because the text color is the far end of each scheme's own
|
|
35
35
|
* range — darker in light, lighter in dark, black in high contrast.
|
|
36
36
|
*
|
|
37
37
|
* Eight per cent, measured rather than chosen. In oklab lightness the
|
|
@@ -51,7 +51,7 @@
|
|
|
51
51
|
);
|
|
52
52
|
--_edge: var(--slotted-skeleton-border-color, var(--slotted-border-subtle, ButtonBorder));
|
|
53
53
|
/**
|
|
54
|
-
* A shimmer needs a second
|
|
54
|
+
* A shimmer needs a second color, and in August this family declined to
|
|
55
55
|
* have one on the grounds that the theme did not own it. It does: the band
|
|
56
56
|
* is the fill carried further along the same axis the fill was derived on,
|
|
57
57
|
* so it separates from the fill in every scheme without a token of its own.
|
|
@@ -71,7 +71,7 @@
|
|
|
71
71
|
* because the two are the same white in light and a full step apart in
|
|
72
72
|
* dark, which is where the pulse was too quiet to see.
|
|
73
73
|
*
|
|
74
|
-
* A
|
|
74
|
+
* A color rather than an opacity, and that is a correction rather than a
|
|
75
75
|
* preference. The pulse used to fade the whole box, which flickered in the
|
|
76
76
|
* dark scheme: the rim faded with the fill, so once every cycle the shape
|
|
77
77
|
* came within a hair of the ground and then came back. Painting the
|
|
@@ -100,7 +100,7 @@
|
|
|
100
100
|
* can be.
|
|
101
101
|
*/
|
|
102
102
|
|
|
103
|
-
[data-ui
|
|
103
|
+
[data-ui-skeleton][data-part-root] {
|
|
104
104
|
display: inline-block;
|
|
105
105
|
/* Never a negative or zero box, whatever the consumer's value resolves
|
|
106
106
|
to. A placeholder that cannot be seen cannot be corrected. */
|
|
@@ -109,9 +109,9 @@
|
|
|
109
109
|
|
|
110
110
|
/**
|
|
111
111
|
* A bar the height of the type it is placed in, sitting on that type's
|
|
112
|
-
* optical
|
|
112
|
+
* optical center rather than on its baseline — the correction `link` derives
|
|
113
113
|
* for the marker it draws beside a word, for the same reason: an inline box
|
|
114
|
-
* is aligned by its bottom edge, and
|
|
114
|
+
* is aligned by its bottom edge, and centering it on the cap line is what
|
|
115
115
|
* puts it where the reader expects the word to be.
|
|
116
116
|
*
|
|
117
117
|
* There is no size axis here on purpose. `1em` is the size of whatever type
|
|
@@ -119,7 +119,7 @@
|
|
|
119
119
|
* own — an axis would have been a coarser second copy of the type scale that
|
|
120
120
|
* a consumer could set to the wrong value.
|
|
121
121
|
*/
|
|
122
|
-
[data-ui
|
|
122
|
+
[data-ui-skeleton][data-part-root][data-shape='text'] {
|
|
123
123
|
--_line: var(--slotted-skeleton-line-size, 1cap);
|
|
124
124
|
|
|
125
125
|
block-size: var(--slotted-skeleton-block-size, var(--_line));
|
|
@@ -129,7 +129,7 @@
|
|
|
129
129
|
* Zero for the default bar, and that is the point rather than an accident:
|
|
130
130
|
* a box one cap tall, aligned on the baseline, occupies exactly the band a
|
|
131
131
|
* capital letter occupies. The expression stays because a consumer who
|
|
132
|
-
* overrides the height still wants it
|
|
132
|
+
* overrides the height still wants it centerd on the same band.
|
|
133
133
|
*/
|
|
134
134
|
vertical-align: calc(0.5cap - 0.5 * var(--_line));
|
|
135
135
|
}
|
|
@@ -140,7 +140,7 @@
|
|
|
140
140
|
* placeholder that resolved to nothing would be a hole in the page that no
|
|
141
141
|
* capture and no reader could point at.
|
|
142
142
|
*/
|
|
143
|
-
[data-ui
|
|
143
|
+
[data-ui-skeleton][data-part-root][data-shape='block'] {
|
|
144
144
|
block-size: var(--slotted-skeleton-block-size, auto);
|
|
145
145
|
border-radius: var(--slotted-skeleton-radius, var(--slotted-radius-md, 6px));
|
|
146
146
|
display: block;
|
|
@@ -155,15 +155,15 @@
|
|
|
155
155
|
* `--slotted-avatar-size`: setting it on a container must not resize the real
|
|
156
156
|
* avatars standing beside the placeholders.
|
|
157
157
|
*/
|
|
158
|
-
[data-ui
|
|
159
|
-
[data-ui
|
|
158
|
+
[data-ui-skeleton][data-part-root][data-shape='circle'],
|
|
159
|
+
[data-ui-skeleton][data-part-root][data-shape='square'] {
|
|
160
160
|
--_size: var(--slotted-skeleton-size, var(--slotted-avatar-size-md, 36px));
|
|
161
161
|
|
|
162
162
|
block-size: var(--slotted-skeleton-block-size, var(--_size));
|
|
163
163
|
inline-size: var(--slotted-skeleton-inline-size, var(--_size));
|
|
164
164
|
}
|
|
165
165
|
|
|
166
|
-
[data-ui
|
|
166
|
+
[data-ui-skeleton][data-part-root][data-shape='circle'] {
|
|
167
167
|
border-radius: var(--slotted-radius-full, 9999px);
|
|
168
168
|
}
|
|
169
169
|
|
|
@@ -172,34 +172,34 @@
|
|
|
172
172
|
* step of the radius scale: six pixels is a gentle round on a 64-pixel square
|
|
173
173
|
* and a quarter-circle on a 20-pixel one.
|
|
174
174
|
*/
|
|
175
|
-
[data-ui
|
|
175
|
+
[data-ui-skeleton][data-part-root][data-shape='square'] {
|
|
176
176
|
border-radius: var(--slotted-skeleton-radius, calc(var(--_size) / 6));
|
|
177
177
|
}
|
|
178
178
|
|
|
179
179
|
/* ── The size steps, which mean something only for the two round shapes ── */
|
|
180
180
|
|
|
181
|
-
[data-ui
|
|
182
|
-
[data-ui
|
|
181
|
+
[data-ui-skeleton][data-part-root][data-shape='circle'][data-size='xs'],
|
|
182
|
+
[data-ui-skeleton][data-part-root][data-shape='square'][data-size='xs'] {
|
|
183
183
|
--_size: var(--slotted-skeleton-size, var(--slotted-avatar-size-xs, 24px));
|
|
184
184
|
}
|
|
185
185
|
|
|
186
|
-
[data-ui
|
|
187
|
-
[data-ui
|
|
186
|
+
[data-ui-skeleton][data-part-root][data-shape='circle'][data-size='sm'],
|
|
187
|
+
[data-ui-skeleton][data-part-root][data-shape='square'][data-size='sm'] {
|
|
188
188
|
--_size: var(--slotted-skeleton-size, var(--slotted-avatar-size-sm, 28px));
|
|
189
189
|
}
|
|
190
190
|
|
|
191
|
-
[data-ui
|
|
192
|
-
[data-ui
|
|
191
|
+
[data-ui-skeleton][data-part-root][data-shape='circle'][data-size='md'],
|
|
192
|
+
[data-ui-skeleton][data-part-root][data-shape='square'][data-size='md'] {
|
|
193
193
|
--_size: var(--slotted-skeleton-size, var(--slotted-avatar-size-md, 36px));
|
|
194
194
|
}
|
|
195
195
|
|
|
196
|
-
[data-ui
|
|
197
|
-
[data-ui
|
|
196
|
+
[data-ui-skeleton][data-part-root][data-shape='circle'][data-size='lg'],
|
|
197
|
+
[data-ui-skeleton][data-part-root][data-shape='square'][data-size='lg'] {
|
|
198
198
|
--_size: var(--slotted-skeleton-size, var(--slotted-avatar-size-lg, 48px));
|
|
199
199
|
}
|
|
200
200
|
|
|
201
|
-
[data-ui
|
|
202
|
-
[data-ui
|
|
201
|
+
[data-ui-skeleton][data-part-root][data-shape='circle'][data-size='xl'],
|
|
202
|
+
[data-ui-skeleton][data-part-root][data-shape='square'][data-size='xl'] {
|
|
203
203
|
--_size: var(--slotted-skeleton-size, var(--slotted-avatar-size-xl, 64px));
|
|
204
204
|
}
|
|
205
205
|
|
|
@@ -215,15 +215,15 @@
|
|
|
215
215
|
* available: a consumer covering a paragraph that has not been measured
|
|
216
216
|
* still sets one.
|
|
217
217
|
*/
|
|
218
|
-
[data-ui
|
|
218
|
+
[data-ui-skeleton][data-part-root][data-loading]:not(:empty) {
|
|
219
219
|
block-size: var(--slotted-skeleton-block-size, auto);
|
|
220
220
|
/* An element child is hidden by `visibility`; a bare text node is not an
|
|
221
|
-
element and can only be hidden by taking the
|
|
221
|
+
element and can only be hidden by taking the color away. */
|
|
222
222
|
color: transparent;
|
|
223
223
|
inline-size: var(--slotted-skeleton-inline-size, auto);
|
|
224
224
|
}
|
|
225
225
|
|
|
226
|
-
[data-ui
|
|
226
|
+
[data-ui-skeleton][data-part-root][data-loading]:not(:empty) > * {
|
|
227
227
|
visibility: hidden;
|
|
228
228
|
}
|
|
229
229
|
|
|
@@ -240,14 +240,14 @@
|
|
|
240
240
|
* paragraph of them read as a barcode because real prose fills a little over
|
|
241
241
|
* half its leading. A capital's height is where the ink actually is.
|
|
242
242
|
*/
|
|
243
|
-
[data-ui
|
|
243
|
+
[data-ui-skeleton][data-part-text] {
|
|
244
244
|
align-items: center;
|
|
245
245
|
display: grid;
|
|
246
246
|
grid-auto-rows: var(--slotted-skeleton-row-size, 1lh);
|
|
247
247
|
inline-size: var(--slotted-skeleton-inline-size, 100%);
|
|
248
248
|
}
|
|
249
249
|
|
|
250
|
-
[data-ui
|
|
250
|
+
[data-ui-skeleton] [data-part-line] {
|
|
251
251
|
block-size: var(--slotted-skeleton-line-size, 1cap);
|
|
252
252
|
border-radius: var(--slotted-radius-full, 9999px);
|
|
253
253
|
inline-size: 100%;
|
|
@@ -259,7 +259,7 @@
|
|
|
259
259
|
* TypeScript and Carbon does not guard at all: one line shortened by itself
|
|
260
260
|
* stands for a sentence that was never there.
|
|
261
261
|
*/
|
|
262
|
-
[data-ui
|
|
262
|
+
[data-ui-skeleton] [data-part-line]:last-child:not(:only-child) {
|
|
263
263
|
inline-size: var(--slotted-skeleton-last-line-size, 62%);
|
|
264
264
|
}
|
|
265
265
|
|
|
@@ -271,8 +271,8 @@
|
|
|
271
271
|
* nothing. One declaration answers both, and neither answer remounts the
|
|
272
272
|
* consumer's content on the way through.
|
|
273
273
|
*/
|
|
274
|
-
[data-ui
|
|
275
|
-
[data-ui
|
|
274
|
+
[data-ui-skeleton][data-part-root]:not([data-loading]),
|
|
275
|
+
[data-ui-skeleton][data-part-text]:not([data-loading]) {
|
|
276
276
|
display: contents;
|
|
277
277
|
}
|
|
278
278
|
|
|
@@ -285,7 +285,7 @@
|
|
|
285
285
|
* pixels inside a 599-pixel column, every placeholder in it two pixels wide.
|
|
286
286
|
* The token is the way out for a region that really is inline.
|
|
287
287
|
*/
|
|
288
|
-
[data-ui
|
|
288
|
+
[data-ui-skeleton][data-part-region] {
|
|
289
289
|
inline-size: var(--slotted-skeleton-inline-size, 100%);
|
|
290
290
|
min-inline-size: 0;
|
|
291
291
|
}
|
|
@@ -308,17 +308,16 @@
|
|
|
308
308
|
* (0 to 1, a point in the cycle) is where a box starts, so a consumer that
|
|
309
309
|
* needs a late box in step, and a capture that needs one moment, can name it.
|
|
310
310
|
*/
|
|
311
|
-
[data-ui
|
|
312
|
-
[data-ui
|
|
313
|
-
[data-part='line'] {
|
|
311
|
+
[data-ui-skeleton][data-part-root][data-loading]:not([data-animation='none']),
|
|
312
|
+
[data-ui-skeleton][data-part-text][data-loading]:not([data-animation='none']) [data-part-line] {
|
|
314
313
|
overflow: clip;
|
|
315
314
|
position: relative;
|
|
316
315
|
}
|
|
317
316
|
|
|
318
|
-
[data-ui
|
|
319
|
-
[data-ui
|
|
320
|
-
[data-ui
|
|
321
|
-
[data-ui
|
|
317
|
+
[data-ui-skeleton][data-part-root][data-animation='pulse'][data-loading]::after,
|
|
318
|
+
[data-ui-skeleton][data-part-root][data-animation='shimmer'][data-loading]::after,
|
|
319
|
+
[data-ui-skeleton][data-animation='pulse'][data-loading] [data-part-line]::after,
|
|
320
|
+
[data-ui-skeleton][data-animation='shimmer'][data-loading] [data-part-line]::after {
|
|
322
321
|
animation-delay: calc(
|
|
323
322
|
var(--slotted-skeleton-phase, 0) * var(--slotted-duration-loop-slow) * -1
|
|
324
323
|
);
|
|
@@ -337,8 +336,8 @@
|
|
|
337
336
|
* at full strength and the shape never leaves the page. Zero at both ends of
|
|
338
337
|
* the cycle, so the seam where it wraps carries nothing to see.
|
|
339
338
|
*/
|
|
340
|
-
[data-ui
|
|
341
|
-
[data-ui
|
|
339
|
+
[data-ui-skeleton][data-part-root][data-animation='pulse'][data-loading]::after,
|
|
340
|
+
[data-ui-skeleton][data-animation='pulse'][data-loading] [data-part-line]::after {
|
|
342
341
|
animation-timing-function: ease-in-out;
|
|
343
342
|
background-color: var(--_trough);
|
|
344
343
|
opacity: 0;
|
|
@@ -355,8 +354,8 @@
|
|
|
355
354
|
* The travel is symmetric about the box, so a right-to-left box runs the same
|
|
356
355
|
* travel backwards; `transform` and the gradient have no logical form.
|
|
357
356
|
*/
|
|
358
|
-
[data-ui
|
|
359
|
-
[data-ui
|
|
357
|
+
[data-ui-skeleton][data-part-root][data-animation='shimmer'][data-loading]::after,
|
|
358
|
+
[data-ui-skeleton][data-animation='shimmer'][data-loading] [data-part-line]::after {
|
|
360
359
|
animation-timing-function: linear;
|
|
361
360
|
background-image: linear-gradient(
|
|
362
361
|
90deg,
|
|
@@ -366,21 +365,21 @@
|
|
|
366
365
|
);
|
|
367
366
|
}
|
|
368
367
|
|
|
369
|
-
[data-ui
|
|
370
|
-
[data-ui
|
|
368
|
+
[data-ui-skeleton][data-part-root][data-animation='shimmer'][data-loading]:dir(rtl)::after,
|
|
369
|
+
[data-ui-skeleton][data-animation='shimmer'][data-loading]:dir(rtl) [data-part-line]::after {
|
|
371
370
|
animation-direction: reverse;
|
|
372
371
|
}
|
|
373
372
|
|
|
374
373
|
/* Started only here: a reset under `reduce` is one attribute against the
|
|
375
374
|
four that select a layer, and lost, so the loop ran under reduced motion. */
|
|
376
375
|
@media (prefers-reduced-motion: no-preference) {
|
|
377
|
-
[data-ui
|
|
378
|
-
[data-ui
|
|
376
|
+
[data-ui-skeleton][data-part-root][data-animation='pulse'][data-loading]::after,
|
|
377
|
+
[data-ui-skeleton][data-animation='pulse'][data-loading] [data-part-line]::after {
|
|
379
378
|
animation-name: slotted-skeleton-pulse;
|
|
380
379
|
}
|
|
381
380
|
|
|
382
|
-
[data-ui
|
|
383
|
-
[data-ui
|
|
381
|
+
[data-ui-skeleton][data-part-root][data-animation='shimmer'][data-loading]::after,
|
|
382
|
+
[data-ui-skeleton][data-animation='shimmer'][data-loading] [data-part-line]::after {
|
|
384
383
|
animation-name: slotted-skeleton-sweep;
|
|
385
384
|
}
|
|
386
385
|
}
|
|
@@ -410,8 +409,8 @@
|
|
|
410
409
|
* stands outside the box, so the reader sees the fill alone.
|
|
411
410
|
*/
|
|
412
411
|
@media (prefers-reduced-motion: reduce) {
|
|
413
|
-
[data-ui
|
|
414
|
-
[data-ui
|
|
412
|
+
[data-ui-skeleton]::after,
|
|
413
|
+
[data-ui-skeleton] [data-part-line]::after {
|
|
415
414
|
animation: none;
|
|
416
415
|
}
|
|
417
416
|
}
|
|
@@ -420,11 +419,11 @@
|
|
|
420
419
|
* The theme remaps the fill to `Canvas` and the rim to `ButtonBorder`, so
|
|
421
420
|
* the box survives on its own. What does not survive is the gradient: a
|
|
422
421
|
* `background-image` is not replaced by the system palette, so a shimmer
|
|
423
|
-
* would go on painting a mixed
|
|
422
|
+
* would go on painting a mixed color over a forced one.
|
|
424
423
|
*/
|
|
425
424
|
@media (forced-colors: active) {
|
|
426
|
-
[data-ui
|
|
427
|
-
[data-ui
|
|
425
|
+
[data-ui-skeleton][data-part-root][data-loading]::after,
|
|
426
|
+
[data-ui-skeleton][data-part-text][data-loading] [data-part-line]::after {
|
|
428
427
|
background-image: none;
|
|
429
428
|
}
|
|
430
429
|
}
|