@slotted/styles 0.1.0-beta.2 → 0.1.0-beta.20
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 +45 -42
- package/src/action-bar/action-bar.tokens.json +1 -0
- package/src/action-sheet/action-sheet.css +36 -36
- package/src/alert/alert.css +68 -67
- package/src/alert/alert.tokens.json +5 -0
- package/src/app-shell/app-shell.css +452 -314
- package/src/app-shell/app-shell.tokens.json +5 -2
- 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 +133 -103
- package/src/calendar/calendar.tokens.json +5 -1
- 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 +258 -248
- 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 +72 -76
- package/src/color-picker/color-picker.css +83 -91
- package/src/column-manager/column-manager.css +106 -114
- package/src/combobox/combobox.css +155 -124
- package/src/combobox/combobox.tokens.json +2 -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 +184 -114
- 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 +75 -59
- package/src/date-picker/date-picker.tokens.json +1 -0
- 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 +80 -65
- package/src/detail-panel/detail-panel.css +86 -71
- package/src/detail-panel/detail-panel.tokens.json +2 -0
- package/src/dialog/dialog.css +376 -153
- package/src/dialog/dialog.tokens.json +6 -0
- package/src/divider/divider.css +18 -18
- package/src/drawer/drawer.css +513 -217
- package/src/drawer/drawer.tokens.json +6 -0
- package/src/entity-picker/entity-picker.css +271 -256
- package/src/entity-picker/entity-picker.tokens.json +2 -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 +62 -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 +153 -77
- package/src/inline-message/inline-message.tokens.json +4 -0
- package/src/kbd/kbd.css +48 -36
- package/src/kbd/kbd.tokens.json +3 -0
- package/src/link/link.css +36 -15
- package/src/link/link.tokens.json +4 -0
- 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 +117 -74
- package/src/menu/menu.tokens.json +1 -0
- package/src/menubar/menubar.css +13 -13
- package/src/message/message.css +192 -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 +175 -160
- 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 +81 -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 +339 -284
- package/src/page-header/page-header.tokens.json +5 -0
- package/src/pagination/pagination.css +68 -72
- package/src/popover/popover.css +73 -61
- package/src/popover/popover.tokens.json +1 -0
- package/src/progress-indicator/progress-indicator.css +169 -113
- package/src/progress-indicator/progress-indicator.tokens.json +1 -0
- package/src/prompt-composer/prompt-composer.css +251 -104
- 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 +178 -43
- package/src/section/section.tokens.json +8 -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 +154 -133
- package/src/select/select.tokens.json +2 -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 +380 -241
- package/src/stat-card/stat-card.tokens.json +5 -0
- package/src/status-indicator/status-indicator.css +107 -82
- package/src/status-indicator/status-indicator.tokens.json +0 -3
- package/src/stepper/stepper.css +58 -62
- package/src/switch/switch.css +86 -92
- package/src/table/table.css +340 -175
- package/src/table/table.tokens.json +6 -0
- package/src/table-of-contents/table-of-contents.css +57 -56
- package/src/table-of-contents/table-of-contents.tokens.json +1 -0
- package/src/tabs/tabs.css +322 -289
- package/src/tabs/tabs.tokens.json +7 -1
- 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 +115 -98
- 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 +59 -38
- package/src/tooltip/tooltip.tokens.json +1 -0
- 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
|
@@ -19,11 +19,11 @@
|
|
|
19
19
|
* trigger, and the layer the calendar stands on. A family that reached into
|
|
20
20
|
* another family's parts would be a second place to fix one defect.
|
|
21
21
|
*/
|
|
22
|
-
[data-ui
|
|
22
|
+
[data-ui-date-picker][data-part-root] {
|
|
23
23
|
display: block;
|
|
24
24
|
/* The anchor the positioner measures is the control, and a block root
|
|
25
|
-
|
|
26
|
-
|
|
25
|
+
takes the width the form gave it without `inline-size: 100%`, which in a
|
|
26
|
+
flex row made the whole row this item's basis and clipped the date. */
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
/**
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
* would then have to reach into another family's parts to suppress the first
|
|
36
36
|
* — which is the rule the whole family is built to keep.
|
|
37
37
|
*/
|
|
38
|
-
[data-ui
|
|
38
|
+
[data-ui-date-picker] [data-part-control] {
|
|
39
39
|
--_icon-size: var(--slotted-control-icon-size-md, 16px);
|
|
40
40
|
--_height: var(--slotted-control-height-md, 34px);
|
|
41
41
|
|
|
@@ -46,12 +46,12 @@
|
|
|
46
46
|
position: relative;
|
|
47
47
|
}
|
|
48
48
|
|
|
49
|
-
[data-ui
|
|
49
|
+
[data-ui-date-picker][data-part-root][data-size='sm'] [data-part-control] {
|
|
50
50
|
--_icon-size: var(--slotted-control-icon-size-sm, 14px);
|
|
51
51
|
--_height: var(--slotted-control-height-sm, 30px);
|
|
52
52
|
}
|
|
53
53
|
|
|
54
|
-
[data-ui
|
|
54
|
+
[data-ui-date-picker][data-part-root][data-size='lg'] [data-part-control] {
|
|
55
55
|
--_icon-size: var(--slotted-control-icon-size-lg, 18px);
|
|
56
56
|
--_height: var(--slotted-control-height-lg, 38px);
|
|
57
57
|
}
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
* `Alt`+`ArrowDown` into `PageDown` before the browser sees it, so the chord
|
|
66
66
|
* cannot be the only way in.
|
|
67
67
|
*/
|
|
68
|
-
[data-ui
|
|
68
|
+
[data-ui-date-picker] [data-part-trigger] {
|
|
69
69
|
--slotted-icon-size: var(--_icon-size);
|
|
70
70
|
|
|
71
71
|
align-items: center;
|
|
@@ -110,7 +110,7 @@
|
|
|
110
110
|
|
|
111
111
|
/* The hit area, recovered outside the paint, exactly as every other inner
|
|
112
112
|
control in the library recovers it. */
|
|
113
|
-
[data-ui
|
|
113
|
+
[data-ui-date-picker] [data-part-trigger]::after {
|
|
114
114
|
content: '';
|
|
115
115
|
inset: min(0px, calc((100% - var(--slotted-target-min, 24px)) / 2));
|
|
116
116
|
position: absolute;
|
|
@@ -121,13 +121,13 @@
|
|
|
121
121
|
the hit area above grows to 44 pixels around them. Before the field's
|
|
122
122
|
clear it does not reach across it. */
|
|
123
123
|
@media (pointer: coarse) {
|
|
124
|
-
[data-ui
|
|
124
|
+
[data-ui-date-picker] [data-part-trigger]::after {
|
|
125
125
|
inset: min(0px, calc((100% - var(--slotted-target-comfortable, 44px)) / 2));
|
|
126
126
|
}
|
|
127
127
|
|
|
128
|
-
[data-ui
|
|
129
|
-
[data-part
|
|
130
|
-
> [data-part
|
|
128
|
+
[data-ui-date-picker]
|
|
129
|
+
[data-part-end]:has(+ [data-part-clear]:not([hidden]))
|
|
130
|
+
> [data-part-trigger]::after {
|
|
131
131
|
inset-inline-end: 0;
|
|
132
132
|
}
|
|
133
133
|
}
|
|
@@ -142,14 +142,14 @@
|
|
|
142
142
|
* that never changes.
|
|
143
143
|
*/
|
|
144
144
|
|
|
145
|
-
[data-ui
|
|
145
|
+
[data-ui-date-picker] [data-part-trigger]:hover:not(:disabled):not([data-disabled]) {
|
|
146
146
|
background-color: var(
|
|
147
147
|
--slotted-date-picker-trigger-hover-background,
|
|
148
148
|
var(--slotted-tone-secondary-subtle-hover)
|
|
149
149
|
);
|
|
150
150
|
}
|
|
151
151
|
|
|
152
|
-
[data-ui
|
|
152
|
+
[data-ui-date-picker] [data-part-trigger]:active:not(:disabled):not([data-disabled]) {
|
|
153
153
|
background-color: var(
|
|
154
154
|
--slotted-date-picker-trigger-active-background,
|
|
155
155
|
var(--slotted-tone-secondary-subtle-active)
|
|
@@ -158,19 +158,19 @@
|
|
|
158
158
|
|
|
159
159
|
/* Its own ring: tabbing from the last segment to the trigger has to move
|
|
160
160
|
something visible, and the frame's ring would sit still. */
|
|
161
|
-
[data-ui
|
|
161
|
+
[data-ui-date-picker] [data-part-trigger]:focus-visible {
|
|
162
162
|
outline: var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);
|
|
163
163
|
outline-offset: calc(var(--slotted-focus-ring-offset, 2px) * -1);
|
|
164
164
|
}
|
|
165
165
|
|
|
166
|
-
[data-ui
|
|
166
|
+
[data-ui-date-picker][data-part-root][data-invalid] {
|
|
167
167
|
--slotted-focus-ring-color: var(
|
|
168
168
|
--slotted-date-picker-invalid-focus-ring-color,
|
|
169
169
|
var(--slotted-focus-ring-color-invalid, Highlight)
|
|
170
170
|
);
|
|
171
171
|
}
|
|
172
172
|
|
|
173
|
-
[data-ui
|
|
173
|
+
[data-ui-date-picker] [data-part-trigger]:disabled {
|
|
174
174
|
color: var(--slotted-disabled-foreground);
|
|
175
175
|
cursor: not-allowed;
|
|
176
176
|
}
|
|
@@ -181,7 +181,7 @@
|
|
|
181
181
|
* onto. The painted surface is one element in, as `tooltip`, `popover`,
|
|
182
182
|
* `menu` and `select` are all built.
|
|
183
183
|
*/
|
|
184
|
-
[data-ui
|
|
184
|
+
[data-ui-date-picker][data-part-positioner] {
|
|
185
185
|
/* Only the block inset: the positioner writes `left` and never `right`,
|
|
186
186
|
and `inset-inline-start` would resolve to `right` in a right-to-left
|
|
187
187
|
document and win over the measured value. */
|
|
@@ -200,24 +200,20 @@
|
|
|
200
200
|
positioner named as origin moved the far edge and read as an entrance
|
|
201
201
|
from the side. */
|
|
202
202
|
--_enter-distance: var(--slotted-space-2, 0.25rem);
|
|
203
|
-
opacity: 0;
|
|
204
203
|
translate: 0 calc(-1 * var(--_enter-distance));
|
|
205
|
-
transition:
|
|
206
|
-
opacity var(--slotted-duration-short) var(--slotted-easing-exit),
|
|
207
|
-
translate var(--slotted-duration-short) var(--slotted-easing-exit);
|
|
204
|
+
transition: translate var(--slotted-duration-short) var(--slotted-easing-exit);
|
|
208
205
|
}
|
|
209
206
|
|
|
210
|
-
[data-ui
|
|
207
|
+
[data-ui-date-picker][data-part-positioner][data-side='top'] {
|
|
211
208
|
translate: 0 var(--_enter-distance);
|
|
212
209
|
}
|
|
213
210
|
|
|
214
211
|
/* A lateral side has no block direction to arrive from, so it only fades. */
|
|
215
|
-
[data-ui
|
|
212
|
+
[data-ui-date-picker][data-part-positioner]:is([data-side='left'], [data-side='right']) {
|
|
216
213
|
translate: 0 0;
|
|
217
214
|
}
|
|
218
215
|
|
|
219
|
-
[data-ui
|
|
220
|
-
opacity: 1;
|
|
216
|
+
[data-ui-date-picker][data-part-positioner][data-open] {
|
|
221
217
|
translate: 0 0;
|
|
222
218
|
transition: none;
|
|
223
219
|
}
|
|
@@ -232,32 +228,23 @@
|
|
|
232
228
|
* markup — the harness, a docs snippet — is simply there, and is
|
|
233
229
|
* photographed where it stands.
|
|
234
230
|
*/
|
|
235
|
-
[data-ui
|
|
231
|
+
[data-ui-date-picker][data-part-positioner][data-open][data-positioned] {
|
|
236
232
|
animation: slotted-date-picker-enter-down var(--slotted-duration-medium)
|
|
237
233
|
var(--slotted-easing-enter);
|
|
238
234
|
}
|
|
239
235
|
|
|
240
|
-
[data-ui
|
|
236
|
+
[data-ui-date-picker][data-part-positioner][data-open][data-positioned][data-side='top'] {
|
|
241
237
|
animation-name: slotted-date-picker-enter-up;
|
|
242
238
|
}
|
|
243
239
|
|
|
244
|
-
[data-ui='date-picker'][data-part='positioner'][data-open][data-positioned]:is(
|
|
245
|
-
[data-side='left'],
|
|
246
|
-
[data-side='right']
|
|
247
|
-
) {
|
|
248
|
-
animation-name: slotted-date-picker-fade;
|
|
249
|
-
}
|
|
250
|
-
|
|
251
240
|
@keyframes slotted-date-picker-enter-down {
|
|
252
241
|
from {
|
|
253
|
-
opacity: 0;
|
|
254
242
|
translate: 0 calc(-1 * var(--_enter-distance));
|
|
255
243
|
}
|
|
256
244
|
}
|
|
257
245
|
|
|
258
246
|
@keyframes slotted-date-picker-enter-up {
|
|
259
247
|
from {
|
|
260
|
-
opacity: 0;
|
|
261
248
|
translate: 0 var(--_enter-distance);
|
|
262
249
|
}
|
|
263
250
|
}
|
|
@@ -268,27 +255,48 @@
|
|
|
268
255
|
}
|
|
269
256
|
}
|
|
270
257
|
|
|
258
|
+
/**
|
|
259
|
+
* The fade belongs to the part that paints the surface, and the layer only
|
|
260
|
+
* moves. In Chromium an ancestor with `opacity` below one is the Backdrop Root
|
|
261
|
+
* of what it holds, so a `backdrop-filter` on the content blurs nothing until
|
|
262
|
+
* the layer is opaque and then appears at once. The content's own opacity
|
|
263
|
+
* leaves its own filter drawn on every frame of the motion.
|
|
264
|
+
*/
|
|
265
|
+
[data-ui-date-picker][data-part-positioner] > [data-part-content] {
|
|
266
|
+
opacity: 0;
|
|
267
|
+
transition: opacity var(--slotted-duration-short) var(--slotted-easing-exit);
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
[data-ui-date-picker][data-part-positioner][data-open] > [data-part-content] {
|
|
271
|
+
opacity: 1;
|
|
272
|
+
transition: none;
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
[data-ui-date-picker][data-part-positioner][data-open][data-positioned] > [data-part-content] {
|
|
276
|
+
animation: slotted-date-picker-fade var(--slotted-duration-medium) var(--slotted-easing-enter);
|
|
277
|
+
}
|
|
278
|
+
|
|
271
279
|
/* Stillness keeps the fade and drops the movement. */
|
|
272
280
|
@media (prefers-reduced-motion: reduce) {
|
|
273
|
-
[data-ui
|
|
274
|
-
[data-ui
|
|
275
|
-
[data-ui
|
|
276
|
-
[data-ui
|
|
281
|
+
[data-ui-date-picker][data-part-positioner],
|
|
282
|
+
[data-ui-date-picker][data-part-positioner][data-side='top'],
|
|
283
|
+
[data-ui-date-picker][data-part-positioner][data-side='left'],
|
|
284
|
+
[data-ui-date-picker][data-part-positioner][data-side='right'] {
|
|
277
285
|
translate: 0 0;
|
|
278
|
-
transition:
|
|
286
|
+
transition: translate var(--slotted-duration-short) var(--slotted-easing-exit);
|
|
279
287
|
}
|
|
280
288
|
|
|
281
|
-
[data-ui
|
|
282
|
-
[data-ui
|
|
283
|
-
[data-ui
|
|
284
|
-
[data-ui
|
|
285
|
-
animation-name:
|
|
289
|
+
[data-ui-date-picker][data-part-positioner][data-open][data-positioned],
|
|
290
|
+
[data-ui-date-picker][data-part-positioner][data-open][data-positioned][data-side='top'],
|
|
291
|
+
[data-ui-date-picker][data-part-positioner][data-open][data-positioned][data-side='left'],
|
|
292
|
+
[data-ui-date-picker][data-part-positioner][data-open][data-positioned][data-side='right'] {
|
|
293
|
+
animation-name: none;
|
|
286
294
|
}
|
|
287
295
|
}
|
|
288
296
|
|
|
289
297
|
/* The anchor scrolled out of its own clipper. The calendar is still open and
|
|
290
298
|
still belongs to a control the reader can no longer see. */
|
|
291
|
-
[data-ui
|
|
299
|
+
[data-ui-date-picker][data-part-positioner][data-detached] {
|
|
292
300
|
visibility: hidden;
|
|
293
301
|
}
|
|
294
302
|
|
|
@@ -298,7 +306,7 @@
|
|
|
298
306
|
* wide as the form, and forcing one to the other would either crush the grid
|
|
299
307
|
* or stretch it.
|
|
300
308
|
*/
|
|
301
|
-
[data-ui
|
|
309
|
+
[data-ui-date-picker] [data-part-content] {
|
|
302
310
|
background-color: var(--slotted-date-picker-surface, var(--slotted-surface-raised, Canvas));
|
|
303
311
|
border: var(--slotted-border-width-thin, 1px) solid
|
|
304
312
|
var(--slotted-date-picker-content-border-color, var(--slotted-border-subtle, ButtonBorder));
|
|
@@ -324,15 +332,25 @@
|
|
|
324
332
|
padding: var(--slotted-date-picker-content-padding, var(--slotted-space-5, 0.75rem));
|
|
325
333
|
/* The layer above gave up the pointer; the surface takes it back. */
|
|
326
334
|
pointer-events: auto;
|
|
335
|
+
/* A theme that paints this surface as a translucent material blurs what moves behind it. */
|
|
336
|
+
-webkit-backdrop-filter: var(--slotted-date-picker-content-backdrop-filter, none);
|
|
337
|
+
backdrop-filter: var(--slotted-date-picker-content-backdrop-filter, none);
|
|
338
|
+
}
|
|
339
|
+
|
|
340
|
+
@media (prefers-reduced-transparency: reduce), (forced-colors: active) {
|
|
341
|
+
[data-ui-date-picker] [data-part-content] {
|
|
342
|
+
-webkit-backdrop-filter: none;
|
|
343
|
+
backdrop-filter: none;
|
|
344
|
+
}
|
|
327
345
|
}
|
|
328
346
|
|
|
329
347
|
/* The shortcuts take a column of their own only when there are any. */
|
|
330
|
-
[data-ui
|
|
348
|
+
[data-ui-date-picker] [data-part-content]:has([data-part-presets]) {
|
|
331
349
|
grid-template-areas: 'presets calendar' 'footer footer';
|
|
332
350
|
grid-template-columns: auto auto;
|
|
333
351
|
}
|
|
334
352
|
|
|
335
|
-
[data-ui
|
|
353
|
+
[data-ui-date-picker] [data-part-content] > [data-ui-calendar] {
|
|
336
354
|
grid-area: calendar;
|
|
337
355
|
}
|
|
338
356
|
|
|
@@ -341,7 +359,7 @@
|
|
|
341
359
|
* days" is a business calendar and a library that guessed at one would be
|
|
342
360
|
* guessing at a fiscal year. What it ships is the column they stand in.
|
|
343
361
|
*/
|
|
344
|
-
[data-ui
|
|
362
|
+
[data-ui-date-picker] [data-part-presets] {
|
|
345
363
|
/* A list of shortcuts reads from the start edge. Stretched, each button
|
|
346
364
|
centred its own label and the four labels formed a ragged column with
|
|
347
365
|
no left edge to run down. */
|
|
@@ -355,7 +373,7 @@
|
|
|
355
373
|
padding-inline-end: var(--slotted-space-5, 0.75rem);
|
|
356
374
|
}
|
|
357
375
|
|
|
358
|
-
[data-ui
|
|
376
|
+
[data-ui-date-picker] [data-part-footer] {
|
|
359
377
|
align-items: center;
|
|
360
378
|
border-block-start: var(--slotted-border-width-thin, 1px) solid
|
|
361
379
|
var(--slotted-date-picker-content-border-color, var(--slotted-border-subtle, ButtonBorder));
|
|
@@ -377,7 +395,7 @@
|
|
|
377
395
|
* ask, and the question really is how much screen there is.
|
|
378
396
|
*/
|
|
379
397
|
@media (max-width: 480px) and (pointer: coarse) {
|
|
380
|
-
[data-ui
|
|
398
|
+
[data-ui-date-picker][data-part-positioner][data-presentation='sheet'] {
|
|
381
399
|
/* The positioner's own measurement is overridden here on purpose: a
|
|
382
400
|
sheet is not placed against an anchor, it is placed against the
|
|
383
401
|
screen. */
|
|
@@ -388,12 +406,11 @@
|
|
|
388
406
|
translate: 0 var(--slotted-space-9, 2rem);
|
|
389
407
|
}
|
|
390
408
|
|
|
391
|
-
[data-ui
|
|
409
|
+
[data-ui-date-picker][data-part-positioner][data-presentation='sheet'][data-open] {
|
|
392
410
|
translate: 0 0;
|
|
393
411
|
}
|
|
394
412
|
|
|
395
|
-
[data-ui
|
|
396
|
-
[data-part='content'] {
|
|
413
|
+
[data-ui-date-picker][data-part-positioner][data-presentation='sheet'] [data-part-content] {
|
|
397
414
|
border-end-end-radius: 0;
|
|
398
415
|
border-end-start-radius: 0;
|
|
399
416
|
border-inline: 0;
|
|
@@ -404,8 +421,7 @@
|
|
|
404
421
|
justify-content: center;
|
|
405
422
|
}
|
|
406
423
|
|
|
407
|
-
[data-ui
|
|
408
|
-
[data-part='presets'] {
|
|
424
|
+
[data-ui-date-picker][data-part-positioner][data-presentation='sheet'] [data-part-presets] {
|
|
409
425
|
/* Beside the grid there is no room for a column of shortcuts, so they
|
|
410
426
|
become a row above it and keep their labels. */
|
|
411
427
|
border-inline-end: 0;
|
|
@@ -11,6 +11,7 @@
|
|
|
11
11
|
"--slotted-control-radius",
|
|
12
12
|
"--slotted-control-transition-duration",
|
|
13
13
|
"--slotted-control-transition-easing",
|
|
14
|
+
"--slotted-date-picker-content-backdrop-filter",
|
|
14
15
|
"--slotted-date-picker-content-border-color",
|
|
15
16
|
"--slotted-date-picker-content-color",
|
|
16
17
|
"--slotted-date-picker-content-padding",
|