@slotted/styles 0.1.0-beta.3 → 0.1.0-beta.31
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 +97 -97
- package/src/alert/alert.tokens.json +6 -1
- package/src/app-shell/app-shell.css +456 -329
- package/src/app-shell/app-shell.tokens.json +6 -3
- 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 +70 -67
- package/src/card/card.tokens.json +1 -0
- package/src/carousel/carousel.css +158 -169
- package/src/cascader/cascader.css +161 -159
- package/src/cascader/cascader.tokens.json +2 -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 +81 -80
- package/src/collapsible/collapsible.tokens.json +1 -0
- package/src/color-picker/color-picker.css +106 -114
- package/src/column-manager/column-manager.css +111 -119
- package/src/combobox/combobox.css +206 -132
- package/src/combobox/combobox.tokens.json +4 -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 +204 -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 +435 -199
- package/src/dialog/dialog.tokens.json +9 -0
- package/src/divider/divider.css +20 -20
- package/src/drawer/drawer.css +598 -237
- package/src/drawer/drawer.tokens.json +14 -0
- package/src/entity-picker/entity-picker.css +326 -272
- package/src/entity-picker/entity-picker.tokens.json +4 -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 +100 -26
- package/src/form/form.tokens.json +6 -1
- 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 +147 -168
- package/src/import-export-center/import-export-center.tokens.json +1 -0
- 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 +166 -83
- package/src/menu/menu.tokens.json +3 -1
- package/src/menubar/menubar.css +16 -16
- package/src/message/message.css +1253 -1246
- package/src/message/message.tokens.json +5 -0
- package/src/message-scroller/message-scroller.css +323 -320
- package/src/multi-select/multi-select.css +233 -174
- package/src/multi-select/multi-select.tokens.json +3 -0
- package/src/navigation-menu/navigation-menu.css +170 -191
- package/src/navigation-menu/navigation-menu.tokens.json +1 -0
- package/src/notification-center/notification-center.css +155 -163
- package/src/notification-center/notification-center.tokens.json +4 -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 +342 -287
- package/src/page-header/page-header.tokens.json +6 -1
- package/src/pagination/pagination.css +75 -79
- package/src/popover/popover.css +85 -65
- package/src/popover/popover.tokens.json +2 -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 +95 -102
- package/src/result-state/result-state.tokens.json +1 -0
- package/src/runtime-properties.mjs +19 -6
- package/src/saved-views/saved-views.css +43 -49
- package/src/scroll-area/scroll-area.css +50 -37
- package/src/section/section.css +179 -44
- package/src/section/section.tokens.json +9 -3
- package/src/segmented-control/segmented-control.css +210 -133
- package/src/segmented-control/segmented-control.tokens.json +7 -11
- package/src/select/select.css +213 -149
- package/src/select/select.tokens.json +4 -0
- package/src/side-navigation/side-navigation.css +201 -198
- 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 +139 -122
- package/src/toast/toast.tokens.json +7 -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 +68 -74
- package/src/tour/tour.tokens.json +1 -0
- 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
|
@@ -4,368 +4,371 @@
|
|
|
4
4
|
*
|
|
5
5
|
* The frame fills a parent whose height is bounded, the viewport scrolls
|
|
6
6
|
* inside it, and the jump control stands over the viewport as a sibling so
|
|
7
|
-
* it does not scroll away with the rows. The
|
|
7
|
+
* it does not scroll away with the rows. The behavior is
|
|
8
8
|
* `@slotted/core/message-scroller`; this sheet reads what it writes —
|
|
9
9
|
* `data-scrollable`, `data-following`, `data-pending` and
|
|
10
10
|
* `--slotted-message-scroller-room` — and draws nothing the engine decides.
|
|
11
|
+
*
|
|
12
|
+
* Every rule is scoped to the family and stops at the parts of any other
|
|
13
|
+
* family nested in a row: an alert in a message keeps its own `content`.
|
|
11
14
|
*/
|
|
12
|
-
[data-ui
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
15
|
+
@scope ([data-ui-message-scroller]) to (:scope [data-ui]:not([data-ui-message-scroller]) > *) {
|
|
16
|
+
:scope[data-part-root] {
|
|
17
|
+
--_inset: var(--slotted-message-scroller-padding, var(--slotted-space-6, 1rem));
|
|
18
|
+
/**
|
|
19
|
+
* The gap between two runs of a conversation. Twenty at comfortable, the
|
|
20
|
+
* ReUI thread gap (`c-message-scroller-4`), fifteen and ten at the two
|
|
21
|
+
* tighter densities: the control gap the theme restates, two and a half
|
|
22
|
+
* times. The rows of one run are two pixels apart (`message` › group),
|
|
23
|
+
* and the difference between the two gaps is the whole grouping signal.
|
|
24
|
+
*/
|
|
25
|
+
--_gap: var(--slotted-message-scroller-gap, calc(var(--slotted-control-gap-md, 8px) * 2.5));
|
|
26
|
+
--_fade: var(--slotted-message-scroller-fade, var(--slotted-space-6, 1rem));
|
|
27
|
+
|
|
28
|
+
display: flex;
|
|
29
|
+
flex-direction: column;
|
|
30
|
+
position: relative;
|
|
31
|
+
box-sizing: border-box;
|
|
32
|
+
block-size: 100%;
|
|
33
|
+
min-block-size: 0;
|
|
34
|
+
min-inline-size: 0;
|
|
35
|
+
overflow: hidden;
|
|
36
|
+
color: var(--slotted-text);
|
|
37
|
+
font-family: var(--slotted-font-family-sans, sans-serif);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
:scope [data-part-viewport] {
|
|
41
|
+
/* The rows' offset parent, so the engine reads their layout offset rather than a rectangle an entrance has moved. */
|
|
42
|
+
position: relative;
|
|
43
|
+
flex: 1 1 auto;
|
|
44
|
+
box-sizing: border-box;
|
|
45
|
+
min-block-size: 0;
|
|
46
|
+
overflow-x: hidden;
|
|
47
|
+
overflow-y: auto;
|
|
48
|
+
/**
|
|
49
|
+
* The engine keeps the reader's row in place itself; a native correction
|
|
50
|
+
* added to its own would move the reader twice, and Safari has none to
|
|
51
|
+
* rely on (`contract.json` › `engine.overflowAnchorReason`).
|
|
52
|
+
*/
|
|
53
|
+
overflow-anchor: none;
|
|
54
|
+
overscroll-behavior: contain;
|
|
55
|
+
scrollbar-color: var(--slotted-border-strong) transparent;
|
|
56
|
+
scrollbar-gutter: stable;
|
|
57
|
+
scrollbar-width: thin;
|
|
58
|
+
}
|
|
35
59
|
|
|
36
|
-
[data-ui='message-scroller'] [data-part='viewport'] {
|
|
37
|
-
/* The rows' offset parent, so the engine reads their layout offset rather than a rectangle an entrance has moved. */
|
|
38
|
-
position: relative;
|
|
39
|
-
flex: 1 1 auto;
|
|
40
|
-
box-sizing: border-box;
|
|
41
|
-
min-block-size: 0;
|
|
42
|
-
overflow-x: hidden;
|
|
43
|
-
overflow-y: auto;
|
|
44
60
|
/**
|
|
45
|
-
*
|
|
46
|
-
*
|
|
47
|
-
* rely on (`contract.json` › `engine.overflowAnchorReason`).
|
|
61
|
+
* An edge the reader can still scroll toward fades the rows into it, so a
|
|
62
|
+
* row cut by the frame reads as continuing rather than as ending there.
|
|
48
63
|
*/
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
scrollbar-gutter: stable;
|
|
53
|
-
scrollbar-width: thin;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
/**
|
|
57
|
-
* An edge the reader can still scroll toward fades the rows into it, so a
|
|
58
|
-
* row cut by the frame reads as continuing rather than as ending there.
|
|
59
|
-
*/
|
|
60
|
-
[data-ui='message-scroller'] [data-part='viewport'][data-scrollable~='start'] {
|
|
61
|
-
mask-image: linear-gradient(to bottom, transparent, #000 var(--_fade));
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
[data-ui='message-scroller'] [data-part='viewport'][data-scrollable~='end'] {
|
|
65
|
-
mask-image: linear-gradient(to top, transparent, #000 var(--_fade));
|
|
66
|
-
}
|
|
64
|
+
:scope [data-part-viewport][data-scrollable~='start'] {
|
|
65
|
+
mask-image: linear-gradient(to bottom, transparent, #000 var(--_fade));
|
|
66
|
+
}
|
|
67
67
|
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
to bottom,
|
|
72
|
-
transparent,
|
|
73
|
-
#000 var(--_fade),
|
|
74
|
-
#000 calc(100% - var(--_fade)),
|
|
75
|
-
transparent
|
|
76
|
-
);
|
|
77
|
-
}
|
|
68
|
+
:scope [data-part-viewport][data-scrollable~='end'] {
|
|
69
|
+
mask-image: linear-gradient(to top, transparent, #000 var(--_fade));
|
|
70
|
+
}
|
|
78
71
|
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
72
|
+
:scope [data-part-viewport][data-scrollable~='start'][data-scrollable~='end'] {
|
|
73
|
+
mask-image: linear-gradient(
|
|
74
|
+
to bottom,
|
|
75
|
+
transparent,
|
|
76
|
+
#000 var(--_fade),
|
|
77
|
+
#000 calc(100% - var(--_fade)),
|
|
78
|
+
transparent
|
|
79
|
+
);
|
|
80
|
+
}
|
|
87
81
|
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
82
|
+
/**
|
|
83
|
+
* A conversation opened at its end is at its top until script runs, and
|
|
84
|
+
* shows its oldest rows first. The frame stays and the rows wait, laid out,
|
|
85
|
+
* so the engine measures them before the reader sees them.
|
|
86
|
+
*/
|
|
87
|
+
:scope [data-part-viewport][data-pending] {
|
|
88
|
+
visibility: hidden;
|
|
89
|
+
}
|
|
92
90
|
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
*/
|
|
98
|
-
[data-ui='message-scroller'] [data-part='content'] {
|
|
99
|
-
display: flex;
|
|
100
|
-
flex-direction: column;
|
|
101
|
-
justify-content: flex-end;
|
|
102
|
-
gap: var(--_gap);
|
|
103
|
-
box-sizing: border-box;
|
|
104
|
-
min-block-size: 100%;
|
|
105
|
-
padding: var(--_inset);
|
|
106
|
-
padding-block-end: calc(var(--_inset) + var(--slotted-message-scroller-room, 0px));
|
|
107
|
-
}
|
|
91
|
+
:scope [data-part-viewport]:focus-visible {
|
|
92
|
+
outline: var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color);
|
|
93
|
+
outline-offset: calc(var(--slotted-focus-ring-offset, 2px) * -1);
|
|
94
|
+
}
|
|
108
95
|
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
transition:
|
|
124
|
-
opacity var(--slotted-duration-medium) var(--slotted-easing-enter, ease-out),
|
|
125
|
-
translate var(--slotted-duration-medium) var(--slotted-easing-enter, ease-out),
|
|
126
|
-
background-color var(--slotted-duration-long) var(--slotted-easing-standard, ease),
|
|
127
|
-
box-shadow var(--slotted-duration-long) var(--slotted-easing-standard, ease);
|
|
128
|
-
|
|
129
|
-
@starting-style {
|
|
130
|
-
opacity: 0;
|
|
131
|
-
translate: 0 var(--slotted-space-4, 0.5rem);
|
|
96
|
+
/**
|
|
97
|
+
* The rows stand at the foot of the frame while they are fewer than it
|
|
98
|
+
* holds, where a conversation is read from; the room an anchored turn needs
|
|
99
|
+
* is added under the last one.
|
|
100
|
+
*/
|
|
101
|
+
:scope [data-part-content] {
|
|
102
|
+
display: flex;
|
|
103
|
+
flex-direction: column;
|
|
104
|
+
justify-content: flex-end;
|
|
105
|
+
gap: var(--_gap);
|
|
106
|
+
box-sizing: border-box;
|
|
107
|
+
min-block-size: 100%;
|
|
108
|
+
padding: var(--_inset);
|
|
109
|
+
padding-block-end: calc(var(--_inset) + var(--slotted-message-scroller-room, 0px));
|
|
132
110
|
}
|
|
133
|
-
}
|
|
134
111
|
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
112
|
+
/**
|
|
113
|
+
* ── A row ──────────────────────────────────────────────────────────────
|
|
114
|
+
*
|
|
115
|
+
* A row far from view is not painted (`content-visibility: auto`) and stays
|
|
116
|
+
* in the DOM for selection, finding in the page and assistive technology.
|
|
117
|
+
* A row that arrives rises by a step and fades in; a row the engine lands a
|
|
118
|
+
* jump on glows in the accent's pointer tint and loses it slowly, so the
|
|
119
|
+
* reader sees where the jump ended.
|
|
120
|
+
*/
|
|
121
|
+
:scope [data-part-item] {
|
|
122
|
+
min-inline-size: 0;
|
|
123
|
+
border-radius: var(--slotted-radius-md, 6px);
|
|
124
|
+
content-visibility: auto;
|
|
125
|
+
contain-intrinsic-size: auto 6rem;
|
|
126
|
+
transition:
|
|
127
|
+
opacity var(--slotted-duration-medium) var(--slotted-easing-enter, ease-out),
|
|
128
|
+
translate var(--slotted-duration-medium) var(--slotted-easing-enter, ease-out),
|
|
129
|
+
background-color var(--slotted-duration-long) var(--slotted-easing-standard, ease),
|
|
130
|
+
box-shadow var(--slotted-duration-long) var(--slotted-easing-standard, ease);
|
|
131
|
+
|
|
132
|
+
@starting-style {
|
|
133
|
+
opacity: 0;
|
|
134
|
+
translate: 0 var(--slotted-space-4, 0.5rem);
|
|
135
|
+
}
|
|
136
|
+
}
|
|
139
137
|
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
* does not leave with its first message; its label carries a ground of its
|
|
145
|
-
* own for the rows passing under it.
|
|
146
|
-
*/
|
|
147
|
-
[data-ui='message-scroller'] :is([data-part='separator'], [data-part='unread']) {
|
|
148
|
-
display: flex;
|
|
149
|
-
align-items: center;
|
|
150
|
-
gap: var(--slotted-space-4, 0.5rem);
|
|
151
|
-
color: var(--slotted-text-muted);
|
|
152
|
-
font-size: var(--slotted-font-size-xs, 0.75rem);
|
|
153
|
-
font-weight: var(--slotted-font-weight-medium, 500);
|
|
154
|
-
line-height: round(
|
|
155
|
-
up,
|
|
156
|
-
calc(var(--slotted-font-size-xs, 0.75rem) * var(--slotted-line-height-xs, 1.4)),
|
|
157
|
-
1px
|
|
158
|
-
);
|
|
159
|
-
}
|
|
138
|
+
:scope [data-part-item][data-current] {
|
|
139
|
+
background-color: var(--slotted-tone-accent-subtle-hover);
|
|
140
|
+
box-shadow: 0 0 0 var(--slotted-space-3, 0.375rem) var(--slotted-tone-accent-subtle-hover);
|
|
141
|
+
}
|
|
160
142
|
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
143
|
+
/* ── Separator and unread line ─────────────────────────────────────────
|
|
144
|
+
*
|
|
145
|
+
* A day, or a line the system writes, between two rules. `sticky` keeps it
|
|
146
|
+
* at the top of the frame while the rows after it are in view, so the day
|
|
147
|
+
* does not leave with its first message; its label carries a ground of its
|
|
148
|
+
* own for the rows passing under it.
|
|
149
|
+
*/
|
|
150
|
+
:scope :is([data-part-separator], [data-part-unread]) {
|
|
151
|
+
display: flex;
|
|
152
|
+
align-items: center;
|
|
153
|
+
gap: var(--slotted-space-4, 0.5rem);
|
|
154
|
+
color: var(--slotted-text-muted);
|
|
155
|
+
font-size: var(--slotted-font-size-xs, 0.75rem);
|
|
156
|
+
font-weight: var(--slotted-font-weight-medium, 500);
|
|
157
|
+
line-height: round(
|
|
158
|
+
up,
|
|
159
|
+
calc(var(--slotted-font-size-xs, 0.75rem) * var(--slotted-line-height-xs, 1.4)),
|
|
160
|
+
1px
|
|
161
|
+
);
|
|
162
|
+
}
|
|
168
163
|
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
position: sticky;
|
|
177
|
-
inset-block-start: var(--_fade);
|
|
178
|
-
z-index: 1;
|
|
179
|
-
content-visibility: visible;
|
|
180
|
-
}
|
|
164
|
+
:scope :is([data-part-separator], [data-part-unread])::before,
|
|
165
|
+
:scope :is([data-part-separator], [data-part-unread])::after {
|
|
166
|
+
content: '';
|
|
167
|
+
flex: 1 1 0;
|
|
168
|
+
min-inline-size: var(--slotted-space-6, 1rem);
|
|
169
|
+
border-block-start: var(--slotted-border-width-thin, 1px) solid var(--slotted-border-subtle);
|
|
170
|
+
}
|
|
181
171
|
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
172
|
+
/**
|
|
173
|
+
* A sticky box sticks inside its containing block, so it is the row that
|
|
174
|
+
* holds the separator that sticks, not the separator inside it. Each later
|
|
175
|
+
* day stacks over the one before it as it arrives at the top.
|
|
176
|
+
*/
|
|
177
|
+
:scope [data-part-item]:has(> [data-part-separator][data-sticky]),
|
|
178
|
+
:scope [data-part-separator][data-sticky]:not([data-part-item] > *) {
|
|
179
|
+
position: sticky;
|
|
180
|
+
inset-block-start: var(--_fade);
|
|
181
|
+
z-index: 1;
|
|
182
|
+
content-visibility: visible;
|
|
183
|
+
}
|
|
192
184
|
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
185
|
+
/**
|
|
186
|
+
* A day that travels over the rows is its label alone: rules stretched
|
|
187
|
+
* across the frame would strike through the message under them, and the
|
|
188
|
+
* label stands below the faded edge so it is read whole. WhatsApp and
|
|
189
|
+
* Telegram float the same pill.
|
|
190
|
+
*/
|
|
191
|
+
:scope [data-part-separator][data-sticky]::before,
|
|
192
|
+
:scope [data-part-separator][data-sticky]::after {
|
|
193
|
+
content: none;
|
|
194
|
+
}
|
|
196
195
|
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
196
|
+
:scope [data-part-separator][data-sticky] {
|
|
197
|
+
justify-content: center;
|
|
198
|
+
}
|
|
200
199
|
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
border: var(--slotted-border-width-thin, 1px) solid var(--slotted-border-subtle);
|
|
205
|
-
border-radius: var(--slotted-radius-full, 9999px);
|
|
206
|
-
background-color: var(--slotted-surface);
|
|
207
|
-
}
|
|
200
|
+
:scope [data-part-separator][data-sticky] > * {
|
|
201
|
+
box-shadow: var(--slotted-shadow-xs);
|
|
202
|
+
}
|
|
208
203
|
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
204
|
+
:scope [data-part-separator] > * {
|
|
205
|
+
padding-block: var(--slotted-space-1, 0.125rem);
|
|
206
|
+
padding-inline: var(--slotted-space-4, 0.5rem);
|
|
207
|
+
border: var(--slotted-border-width-thin, 1px) solid var(--slotted-border-subtle);
|
|
208
|
+
border-radius: var(--slotted-radius-full, 9999px);
|
|
209
|
+
background-color: var(--slotted-surface);
|
|
210
|
+
}
|
|
212
211
|
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
}
|
|
212
|
+
:scope [data-part-unread] {
|
|
213
|
+
color: var(--slotted-tone-accent-text);
|
|
214
|
+
}
|
|
217
215
|
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
*/
|
|
223
|
-
[data-ui='message-scroller'] [data-part='loader'] {
|
|
224
|
-
display: flex;
|
|
225
|
-
align-items: center;
|
|
226
|
-
justify-content: center;
|
|
227
|
-
gap: var(--slotted-space-3, 0.375rem);
|
|
228
|
-
padding-block: var(--slotted-space-2, 0.25rem);
|
|
229
|
-
color: var(--slotted-text-muted);
|
|
230
|
-
font-size: var(--slotted-control-font-size-md, 13px);
|
|
231
|
-
}
|
|
216
|
+
:scope [data-part-unread]::before,
|
|
217
|
+
:scope [data-part-unread]::after {
|
|
218
|
+
border-block-start-color: var(--slotted-tone-accent-border);
|
|
219
|
+
}
|
|
232
220
|
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
221
|
+
/* ── Loader ─────────────────────────────────────────────────────────────
|
|
222
|
+
*
|
|
223
|
+
* Older rows on their way: the shared ring and a line of muted text, at the
|
|
224
|
+
* head of the rows. The ring is `spinner`'s.
|
|
225
|
+
*/
|
|
226
|
+
:scope [data-part-loader] {
|
|
227
|
+
display: flex;
|
|
228
|
+
align-items: center;
|
|
229
|
+
justify-content: center;
|
|
230
|
+
gap: var(--slotted-space-3, 0.375rem);
|
|
231
|
+
padding-block: var(--slotted-space-2, 0.25rem);
|
|
232
|
+
color: var(--slotted-text-muted);
|
|
233
|
+
font-size: var(--slotted-control-font-size-md, 13px);
|
|
234
|
+
}
|
|
236
235
|
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
* A raised round control over the foot of the frame, the arrow pointing to
|
|
241
|
-
* where it goes. When rows arrived out of view it widens into a pill that
|
|
242
|
-
* says how many, the answer shadcn's own documentation asks for (its eighth
|
|
243
|
-
* principle) and its control does not give.
|
|
244
|
-
*
|
|
245
|
-
* With nowhere to go it leaves: `inert`, out of the tab order, and drawn
|
|
246
|
-
* out by opacity and a step toward its edge. It arrives on the enter curve
|
|
247
|
-
* in the medium step and leaves on the exit curve in the short one, where
|
|
248
|
-
* ReUI's leaves in twice the time it arrives (dossier §5). It does not
|
|
249
|
-
* scale: it holds text.
|
|
250
|
-
*/
|
|
251
|
-
[data-ui='message-scroller'] [data-part='jump'] {
|
|
252
|
-
--_size: var(--slotted-message-scroller-jump-size, var(--slotted-control-height-md, 34px));
|
|
253
|
-
--_ground: var(--slotted-surface-raised);
|
|
254
|
-
--_ink: var(--slotted-text);
|
|
255
|
-
--_shift: var(--slotted-space-4, 0.5rem);
|
|
256
|
-
|
|
257
|
-
display: inline-flex;
|
|
258
|
-
align-items: center;
|
|
259
|
-
justify-content: center;
|
|
260
|
-
gap: var(--slotted-space-2, 0.25rem);
|
|
261
|
-
position: absolute;
|
|
262
|
-
inset-block-end: var(--_inset);
|
|
263
|
-
inset-inline-start: 50%;
|
|
264
|
-
z-index: 2;
|
|
265
|
-
box-sizing: border-box;
|
|
266
|
-
min-inline-size: var(--_size);
|
|
267
|
-
block-size: var(--_size);
|
|
268
|
-
margin: 0;
|
|
269
|
-
padding: 0;
|
|
270
|
-
/* A raised surface over the rows, not a field: the rule inside a surface and the lift say so. */
|
|
271
|
-
border: var(--slotted-border-width-thin, 1px) solid var(--slotted-border-subtle);
|
|
272
|
-
border-radius: var(--slotted-radius-full, 9999px);
|
|
273
|
-
background-color: var(--_ground);
|
|
274
|
-
box-shadow: var(--slotted-shadow-md);
|
|
275
|
-
color: var(--_ink);
|
|
276
|
-
font: inherit;
|
|
277
|
-
font-size: var(--slotted-control-font-size-md, 13px);
|
|
278
|
-
font-weight: var(--slotted-font-weight-medium, 500);
|
|
279
|
-
line-height: 1;
|
|
280
|
-
white-space: nowrap;
|
|
281
|
-
cursor: pointer;
|
|
282
|
-
translate: -50% 0;
|
|
283
|
-
transition:
|
|
284
|
-
opacity var(--slotted-duration-medium) var(--slotted-easing-enter, ease-out),
|
|
285
|
-
translate var(--slotted-duration-medium) var(--slotted-easing-enter, ease-out),
|
|
286
|
-
background-color var(--slotted-duration-short) var(--slotted-easing-standard, ease);
|
|
287
|
-
}
|
|
236
|
+
:scope [data-part-loader] > [data-ui-spinner] {
|
|
237
|
+
--slotted-spinner-size: var(--slotted-control-icon-size-sm, 14px);
|
|
238
|
+
}
|
|
288
239
|
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
240
|
+
/**
|
|
241
|
+
* ── Jump ───────────────────────────────────────────────────────────────
|
|
242
|
+
*
|
|
243
|
+
* A raised round control over the foot of the frame, the arrow pointing to
|
|
244
|
+
* where it goes. When rows arrived out of view it widens into a pill that
|
|
245
|
+
* says how many, the answer shadcn's own documentation asks for (its eighth
|
|
246
|
+
* principle) and its control does not give.
|
|
247
|
+
*
|
|
248
|
+
* With nowhere to go it leaves: `inert`, out of the tab order, and drawn
|
|
249
|
+
* out by opacity and a step toward its edge. It arrives on the enter curve
|
|
250
|
+
* in the medium step and leaves on the exit curve in the short one, where
|
|
251
|
+
* ReUI's leaves in twice the time it arrives (dossier §5). It does not
|
|
252
|
+
* scale: it holds text.
|
|
253
|
+
*/
|
|
254
|
+
:scope [data-part-jump] {
|
|
255
|
+
--_size: var(--slotted-message-scroller-jump-size, var(--slotted-control-height-md, 34px));
|
|
256
|
+
--_ground: var(--slotted-surface-raised);
|
|
257
|
+
--_ink: var(--slotted-text);
|
|
258
|
+
--_shift: var(--slotted-space-4, 0.5rem);
|
|
259
|
+
|
|
260
|
+
display: inline-flex;
|
|
261
|
+
align-items: center;
|
|
262
|
+
justify-content: center;
|
|
263
|
+
gap: var(--slotted-space-2, 0.25rem);
|
|
264
|
+
position: absolute;
|
|
265
|
+
inset-block-end: var(--_inset);
|
|
266
|
+
inset-inline-start: 50%;
|
|
267
|
+
z-index: 2;
|
|
268
|
+
box-sizing: border-box;
|
|
269
|
+
min-inline-size: var(--_size);
|
|
270
|
+
block-size: var(--_size);
|
|
271
|
+
margin: 0;
|
|
272
|
+
padding: 0;
|
|
273
|
+
/* A raised surface over the rows, not a field: the rule inside a surface and the lift say so. */
|
|
274
|
+
border: var(--slotted-border-width-thin, 1px) solid var(--slotted-border-subtle);
|
|
275
|
+
border-radius: var(--slotted-radius-full, 9999px);
|
|
276
|
+
background-color: var(--_ground);
|
|
277
|
+
box-shadow: var(--slotted-shadow-md);
|
|
278
|
+
color: var(--_ink);
|
|
279
|
+
font: inherit;
|
|
280
|
+
font-size: var(--slotted-control-font-size-md, 13px);
|
|
281
|
+
font-weight: var(--slotted-font-weight-medium, 500);
|
|
282
|
+
line-height: 1;
|
|
283
|
+
white-space: nowrap;
|
|
284
|
+
cursor: pointer;
|
|
285
|
+
translate: -50% 0;
|
|
286
|
+
transition:
|
|
287
|
+
opacity var(--slotted-duration-medium) var(--slotted-easing-enter, ease-out),
|
|
288
|
+
translate var(--slotted-duration-medium) var(--slotted-easing-enter, ease-out),
|
|
289
|
+
background-color var(--slotted-duration-short) var(--slotted-easing-standard, ease);
|
|
290
|
+
}
|
|
292
291
|
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
}
|
|
292
|
+
:scope [data-part-jump]:dir(rtl) {
|
|
293
|
+
translate: 50% 0;
|
|
294
|
+
}
|
|
297
295
|
|
|
298
|
-
|
|
299
|
-
|
|
296
|
+
:scope [data-part-jump][data-direction='start'] {
|
|
297
|
+
inset-block: var(--_inset) auto;
|
|
298
|
+
--_shift: calc(var(--slotted-space-4, 0.5rem) * -1);
|
|
299
|
+
}
|
|
300
300
|
|
|
301
|
-
|
|
302
|
-
|
|
301
|
+
:scope [data-part-jump] > [data-ui-icon] {
|
|
302
|
+
--slotted-icon-size: var(--slotted-control-icon-size-md, 16px);
|
|
303
303
|
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
}
|
|
304
|
+
rotate: -90deg;
|
|
305
|
+
}
|
|
307
306
|
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
307
|
+
:scope [data-part-jump][data-direction='start'] > [data-ui-icon] {
|
|
308
|
+
rotate: 90deg;
|
|
309
|
+
}
|
|
311
310
|
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
311
|
+
:scope [data-part-jump]:has(> [data-part-jump-count]) {
|
|
312
|
+
padding-inline: var(--slotted-space-4, 0.5rem) var(--slotted-space-5, 0.75rem);
|
|
313
|
+
}
|
|
315
314
|
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
translate: -50% var(--_shift);
|
|
320
|
-
transition:
|
|
321
|
-
opacity var(--slotted-duration-short) var(--slotted-easing-exit, ease-in),
|
|
322
|
-
translate var(--slotted-duration-short) var(--slotted-easing-exit, ease-in);
|
|
323
|
-
}
|
|
315
|
+
:scope [data-part-jump-count] {
|
|
316
|
+
font-variant-numeric: tabular-nums;
|
|
317
|
+
}
|
|
324
318
|
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
319
|
+
:scope [data-part-jump][data-active='false'] {
|
|
320
|
+
opacity: 0;
|
|
321
|
+
pointer-events: none;
|
|
322
|
+
translate: -50% var(--_shift);
|
|
323
|
+
transition:
|
|
324
|
+
opacity var(--slotted-duration-short) var(--slotted-easing-exit, ease-in),
|
|
325
|
+
translate var(--slotted-duration-short) var(--slotted-easing-exit, ease-in);
|
|
326
|
+
}
|
|
328
327
|
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
var(--_ink) var(--slotted-message-scroller-state-layer-hover, 6%),
|
|
333
|
-
var(--_ground)
|
|
334
|
-
);
|
|
335
|
-
}
|
|
328
|
+
:scope [data-part-jump][data-active='false']:dir(rtl) {
|
|
329
|
+
translate: 50% var(--_shift);
|
|
330
|
+
}
|
|
336
331
|
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
in oklab,
|
|
345
|
-
var(--_ink) var(--slotted-message-scroller-state-layer-active, 12%),
|
|
346
|
-
var(--_ground)
|
|
347
|
-
);
|
|
348
|
-
translate: -50% var(--slotted-space-1, 0.125rem);
|
|
349
|
-
}
|
|
332
|
+
:scope [data-part-jump]:hover:not(:disabled):not([data-disabled]) {
|
|
333
|
+
background-color: color-mix(
|
|
334
|
+
in oklab,
|
|
335
|
+
var(--_ink) var(--slotted-message-scroller-state-layer-hover, 6%),
|
|
336
|
+
var(--_ground)
|
|
337
|
+
);
|
|
338
|
+
}
|
|
350
339
|
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
340
|
+
/**
|
|
341
|
+
* The press answers by the ground and by a pixel toward the edge the
|
|
342
|
+
* control points to, the way a key goes down; a scale would resample the
|
|
343
|
+
* count it carries (R7, `text-scale.test.mjs`).
|
|
344
|
+
*/
|
|
345
|
+
:scope [data-part-jump]:active:not(:disabled):not([data-disabled]) {
|
|
346
|
+
background-color: color-mix(
|
|
347
|
+
in oklab,
|
|
348
|
+
var(--_ink) var(--slotted-message-scroller-state-layer-active, 12%),
|
|
349
|
+
var(--_ground)
|
|
350
|
+
);
|
|
351
|
+
translate: -50% var(--slotted-space-1, 0.125rem);
|
|
352
|
+
}
|
|
355
353
|
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
}
|
|
354
|
+
:scope [data-part-jump]:active:not(:disabled):not([data-disabled]):dir(rtl) {
|
|
355
|
+
translate: 50% var(--slotted-space-1, 0.125rem);
|
|
356
|
+
}
|
|
360
357
|
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
outline: var(--slotted-
|
|
364
|
-
outline-offset: var(--slotted-space-2, 0.25rem);
|
|
358
|
+
:scope [data-part-jump]:focus-visible {
|
|
359
|
+
outline: var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color);
|
|
360
|
+
outline-offset: var(--slotted-focus-ring-offset, 2px);
|
|
365
361
|
}
|
|
366
362
|
|
|
367
|
-
|
|
368
|
-
|
|
363
|
+
@media (forced-colors: active) {
|
|
364
|
+
:scope [data-part-item][data-current] {
|
|
365
|
+
outline: var(--slotted-border-width-thick, 2px) solid Highlight;
|
|
366
|
+
outline-offset: var(--slotted-space-2, 0.25rem);
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
:scope [data-part-viewport][data-scrollable] {
|
|
370
|
+
mask-image: none;
|
|
371
|
+
}
|
|
369
372
|
}
|
|
370
373
|
}
|
|
371
374
|
}
|