@slotted/react 0.1.0-beta.15 → 0.1.0-beta.16
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/dist/{action-sheet-Klu-YxIk.js → action-sheet-dNnB26br.js} +20 -20
- package/dist/action-sheet.js +1 -1
- package/dist/{attachment-DKKiNUKe.js → attachment-C1wBuup6.js} +2 -0
- package/dist/attachment.js +1 -1
- package/dist/calendar-wqDIW4Z8.js +469 -0
- package/dist/calendar.js +1 -1
- package/dist/{column-manager-e234Ey_u.js → column-manager-C8fN_mDy.js} +6 -6
- package/dist/column-manager.js +1 -1
- package/dist/dashboard-grid-ByThIV_n.js +1066 -0
- package/dist/dashboard-grid.js +1 -1
- package/dist/{data-grid-B5feiNsE.js → data-grid-aHlR2FHu.js} +4 -4
- package/dist/data-grid.js +1 -1
- package/dist/{data-list-CUvUS2AX.js → data-list-Cu6LtnDX.js} +1 -1
- package/dist/data-list.js +1 -1
- package/dist/{date-picker-Dys-z9mZ.js → date-picker-B5V8NZCT.js} +1 -1
- package/dist/date-picker.js +1 -1
- package/dist/{date-range-picker-Cu95hHyO.js → date-range-picker-B89Q973N.js} +1 -1
- package/dist/date-range-picker.js +1 -1
- package/dist/{datetime-picker-B7eWKoN3.js → datetime-picker-Cx6Z52Ka.js} +1 -1
- package/dist/datetime-picker.js +1 -1
- package/dist/{datetime-range-picker-Cm42pY3M.js → datetime-range-picker-DYshAlgq.js} +1 -1
- package/dist/datetime-range-picker.js +1 -1
- package/dist/docs/calendar.json +19 -1
- package/dist/docs/calendar.md +3 -1
- package/dist/docs/dashboard-grid.json +26 -4
- package/dist/docs/dashboard-grid.md +5 -2
- package/dist/docs/drawer.json +13 -4
- package/dist/docs/drawer.md +5 -4
- package/dist/docs/link.json +16 -0
- package/dist/docs/link.md +3 -1
- package/dist/docs/list-item.json +10 -2
- package/dist/docs/list-item.md +20 -13
- package/dist/docs/markdown.json +7 -0
- package/dist/docs/markdown.md +1 -0
- package/dist/docs/message-scroller.json +1 -1
- package/dist/docs/prompt-composer.json +9 -2
- package/dist/docs/prompt-composer.md +3 -1
- package/dist/{drawer-CFpBsLG6.js → drawer-Du1aC1px.js} +17 -4
- package/dist/drawer.js +2 -2
- package/dist/{event-calendar-liaKOKOH.js → event-calendar-CEIyV-fW.js} +520 -520
- package/dist/event-calendar.js +1 -1
- package/dist/{filter-bar-vJzwcDZj.js → filter-bar-BHzy0o7n.js} +8 -8
- package/dist/filter-bar.js +1 -1
- package/dist/{import-export-center-BIB7sRCl.js → import-export-center-BX1Bhj8c.js} +1 -1
- package/dist/import-export-center.js +1 -1
- package/dist/index.js +124 -124
- package/dist/{link-rGL3Lr2t.js → link-YvD_Wov8.js} +23 -22
- package/dist/link.js +1 -1
- package/dist/list-item-2z75VYyp.js +160 -0
- package/dist/list-item.js +1 -1
- package/dist/markdown-gfrgwq6-.js +311 -0
- package/dist/markdown.js +1 -1
- package/dist/{prompt-composer-BDOi4rVK.js → prompt-composer-C57BzYrn.js} +109 -77
- package/dist/prompt-composer.js +2 -2
- package/dist/styles/action-sheet.css +1 -1
- package/dist/styles/calendar.css +3 -1
- package/dist/styles/chart.css +1 -1
- package/dist/styles/column-manager.css +1 -1
- package/dist/styles/command-palette.css +1 -1
- package/dist/styles/dashboard-grid.css +3 -1
- package/dist/styles/data-grid.css +1 -1
- package/dist/styles/date-picker.css +3 -1
- package/dist/styles/date-range-picker.css +3 -1
- package/dist/styles/datetime-picker.css +3 -1
- package/dist/styles/datetime-range-picker.css +3 -1
- package/dist/styles/detail-panel.css +1 -1
- package/dist/styles/dialog.css +1 -1
- package/dist/styles/drawer.css +1 -1
- package/dist/styles/event-calendar.css +1 -1
- package/dist/styles/filter-bar.css +4 -2
- package/dist/styles/import-export-center.css +2 -2
- package/dist/styles/index.css +11 -11
- package/dist/styles/link.css +1 -1
- package/dist/styles/markdown.css +1 -1
- package/dist/styles/message.css +1 -1
- package/dist/styles/prompt-composer.css +1 -1
- package/dist/styles/section.css +1 -1
- package/dist/styles/stat-card.css +1 -1
- package/dist/styles/table.css +2 -2
- package/dist/styles/upload.css +1 -1
- package/dist/styles.css +1 -1
- package/dist/{table-_xX87qua.js → table-BHuKvsgJ.js} +4 -4
- package/dist/table.js +1 -1
- package/dist/types/calendar/calendar.d.ts +2 -1
- package/dist/types/calendar/calendar.d.ts.map +1 -1
- package/dist/types/calendar/calendar.types.d.ts +11 -0
- package/dist/types/calendar/calendar.types.d.ts.map +1 -1
- package/dist/types/calendar/index.d.ts +1 -1
- package/dist/types/calendar/index.d.ts.map +1 -1
- package/dist/types/dashboard-grid/dashboard-grid.d.ts +1 -1
- package/dist/types/dashboard-grid/dashboard-grid.d.ts.map +1 -1
- package/dist/types/dashboard-grid/dashboard-grid.types.d.ts +23 -3
- package/dist/types/dashboard-grid/dashboard-grid.types.d.ts.map +1 -1
- package/dist/types/dashboard-grid/dashboard-widget.d.ts +1 -1
- package/dist/types/dashboard-grid/dashboard-widget.d.ts.map +1 -1
- package/dist/types/dashboard-grid/index.d.ts +1 -1
- package/dist/types/dashboard-grid/index.d.ts.map +1 -1
- package/dist/types/drawer/drawer-parts.d.ts +3 -1
- package/dist/types/drawer/drawer-parts.d.ts.map +1 -1
- package/dist/types/drawer/drawer.types.d.ts +2 -0
- package/dist/types/drawer/drawer.types.d.ts.map +1 -1
- package/dist/types/drawer/index.d.ts +2 -2
- package/dist/types/drawer/index.d.ts.map +1 -1
- package/dist/types/link/index.d.ts +1 -1
- package/dist/types/link/index.d.ts.map +1 -1
- package/dist/types/link/link.d.ts +1 -1
- package/dist/types/link/link.d.ts.map +1 -1
- package/dist/types/link/link.types.d.ts +7 -0
- package/dist/types/link/link.types.d.ts.map +1 -1
- package/dist/types/list-item/list-item-content.d.ts +3 -3
- package/dist/types/list-item/list-item-content.d.ts.map +1 -1
- package/dist/types/list-item/list-item-nesting.d.ts +15 -0
- package/dist/types/list-item/list-item-nesting.d.ts.map +1 -0
- package/dist/types/list-item/list-item-parts.d.ts +3 -3
- package/dist/types/list-item/list-item-parts.d.ts.map +1 -1
- package/dist/types/markdown/markdown.d.ts +1 -1
- package/dist/types/markdown/markdown.d.ts.map +1 -1
- package/dist/types/markdown/markdown.types.d.ts +6 -1
- package/dist/types/markdown/markdown.types.d.ts.map +1 -1
- package/dist/types/prompt-composer/index.d.ts +2 -2
- package/dist/types/prompt-composer/index.d.ts.map +1 -1
- package/dist/types/prompt-composer/prompt-composer.d.ts +8 -1
- package/dist/types/prompt-composer/prompt-composer.d.ts.map +1 -1
- package/dist/types/prompt-composer/prompt-composer.types.d.ts +7 -1
- package/dist/types/prompt-composer/prompt-composer.types.d.ts.map +1 -1
- package/package.json +6 -6
- package/dist/calendar-DZx00W81.js +0 -457
- package/dist/dashboard-grid-B9-_lwn6.js +0 -1048
- package/dist/list-item-CHaJYl5r.js +0 -125
- package/dist/markdown-B_lMpWz0.js +0 -306
package/dist/dashboard-grid.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as e, i as t, n, o as r, r as i, t as a } from "./dashboard-grid-
|
|
1
|
+
import { a as e, i as t, n, o as r, r as i, t as a } from "./dashboard-grid-ByThIV_n.js";
|
|
2
2
|
export { t as DASHBOARD_GRID_FALLBACK, i as DashboardGrid, e as DashboardGridDefaultsProvider, n as DashboardWidget, r as useDashboardGridDefaults, a as usePersistedDashboardLayout };
|
|
@@ -9,12 +9,12 @@ import { t as g } from "./text-field-CHYoral_.js";
|
|
|
9
9
|
import { a as _, d as ee, f as te, l as ne, r as re, t as ie } from "./popover-BfEn2wdZ.js";
|
|
10
10
|
import { t as v } from "./visually-hidden-BUSrFZ1_.js";
|
|
11
11
|
import { i as ae, n as oe, o as se, r as ce, t as le } from "./result-state-BMYhelu1.js";
|
|
12
|
-
import { t as ue } from "./date-picker-
|
|
12
|
+
import { t as ue } from "./date-picker-B5V8NZCT.js";
|
|
13
13
|
import { t as de } from "./date-field-EBPrQL6A.js";
|
|
14
|
-
import { t as fe } from "./date-range-picker-
|
|
15
|
-
import { t as pe } from "./datetime-picker-
|
|
14
|
+
import { t as fe } from "./date-range-picker-B89Q973N.js";
|
|
15
|
+
import { t as pe } from "./datetime-picker-Cx6Z52Ka.js";
|
|
16
16
|
import { t as me } from "./datetime-field-DavJbR0H.js";
|
|
17
|
-
import { t as he } from "./datetime-range-picker-
|
|
17
|
+
import { t as he } from "./datetime-range-picker-DYshAlgq.js";
|
|
18
18
|
import { a as ge, i as _e, n as ve, s as ye } from "./multi-select-C1GNk4e0.js";
|
|
19
19
|
import { t as be } from "./number-field-BPYe9kLB.js";
|
|
20
20
|
import { a as xe, t as Se } from "./segmented-control-B1U-s58C.js";
|
package/dist/data-grid.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as e, i as t, n, o as r, r as i, s as a, t as o } from "./data-grid-
|
|
1
|
+
import { a as e, i as t, n, o as r, r as i, s as a, t as o } from "./data-grid-aHlR2FHu.js";
|
|
2
2
|
export { e as DRAG_COLUMN, n as DataGrid, i as DataGridDefaultsProvider, r as EXPANDER_COLUMN, a as SELECTION_COLUMN, t as useDataGridDefaults, o as usePersistedGridView };
|
|
@@ -7,7 +7,7 @@ import { i as d, n as f } from "./skeleton-DeEOmm1y.js";
|
|
|
7
7
|
import { t as p } from "./visually-hidden-BUSrFZ1_.js";
|
|
8
8
|
import { n as m, o as ne, r as h, t as re } from "./result-state-BMYhelu1.js";
|
|
9
9
|
import { n as ie, r as ae } from "./list-B7gaPH1U.js";
|
|
10
|
-
import { a as oe, c as se, i as ce, n as le, o as ue, r as de, t as fe, u as pe } from "./list-item-
|
|
10
|
+
import { a as oe, c as se, i as ce, n as le, o as ue, r as de, t as fe, u as pe } from "./list-item-2z75VYyp.js";
|
|
11
11
|
import { withSelectorKey as me } from "@slotted/core/selector-key";
|
|
12
12
|
import { Fragment as he, createContext as ge, useContext as _e, useEffect as ve, useId as ye, useImperativeHandle as be, useLayoutEffect as xe, useMemo as Se, useRef as g, useState as _ } from "react";
|
|
13
13
|
import { jsx as v, jsxs as y } from "react/jsx-runtime";
|
package/dist/data-list.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as e, r as t, t as n } from "./data-list-
|
|
1
|
+
import { n as e, r as t, t as n } from "./data-list-Cu6LtnDX.js";
|
|
2
2
|
export { n as DataList, e as DataListDefaultsProvider, t as useDataListDefaults };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as e, r as t } from "./i18n-D7xXDd8-.js";
|
|
2
2
|
import { n, t as r } from "./icon-D04-_QFA.js";
|
|
3
|
-
import { n as i, r as a, t as ee } from "./calendar-
|
|
3
|
+
import { n as i, r as a, t as ee } from "./calendar-wqDIW4Z8.js";
|
|
4
4
|
import { b as o } from "./field-CnSMUZw6.js";
|
|
5
5
|
import { t as te } from "./date-field-EBPrQL6A.js";
|
|
6
6
|
import { keyedProps as ne } from "@slotted/core/selector-key";
|
package/dist/date-picker.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as e, r as t, t as n } from "./date-picker-
|
|
1
|
+
import { n as e, r as t, t as n } from "./date-picker-B5V8NZCT.js";
|
|
2
2
|
export { n as DatePicker, e as DatePickerDefaultsProvider, t as useDatePickerDefaults };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as e, r as t } from "./i18n-D7xXDd8-.js";
|
|
2
2
|
import { n, t as r } from "./icon-D04-_QFA.js";
|
|
3
|
-
import { i, t as a } from "./calendar-
|
|
3
|
+
import { i, t as a } from "./calendar-wqDIW4Z8.js";
|
|
4
4
|
import { b as ee } from "./field-CnSMUZw6.js";
|
|
5
5
|
import { t as o } from "./date-field-EBPrQL6A.js";
|
|
6
6
|
import { keyedProps as te } from "@slotted/core/selector-key";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { i as e, n as t, r as n, t as r } from "./date-range-picker-
|
|
1
|
+
import { i as e, n as t, r as n, t as r } from "./date-range-picker-B89Q973N.js";
|
|
2
2
|
export { r as DateRangePicker, n as DateRangePickerDefaultsProvider, t as DateRangePickerPreset, e as useDateRangePickerDefaults };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as e, r as t } from "./i18n-D7xXDd8-.js";
|
|
2
2
|
import { n, t as r } from "./icon-D04-_QFA.js";
|
|
3
|
-
import { t as i } from "./calendar-
|
|
3
|
+
import { t as i } from "./calendar-wqDIW4Z8.js";
|
|
4
4
|
import { b as ee } from "./field-CnSMUZw6.js";
|
|
5
5
|
import { t as te } from "./datetime-field-DavJbR0H.js";
|
|
6
6
|
import { keyedProps as ne } from "@slotted/core/selector-key";
|
package/dist/datetime-picker.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { i as e, n as t, r as n, t as r } from "./datetime-picker-
|
|
1
|
+
import { i as e, n as t, r as n, t as r } from "./datetime-picker-Cx6Z52Ka.js";
|
|
2
2
|
export { t as DATE_TIME_PICKER_MAX_OPTIONS, r as DateTimePicker, n as DateTimePickerDefaultsProvider, e as useDateTimePickerDefaults };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as e, r as t } from "./i18n-D7xXDd8-.js";
|
|
2
2
|
import { n, t as r } from "./icon-D04-_QFA.js";
|
|
3
|
-
import { t as i } from "./calendar-
|
|
3
|
+
import { t as i } from "./calendar-wqDIW4Z8.js";
|
|
4
4
|
import { b as a } from "./field-CnSMUZw6.js";
|
|
5
5
|
import { t as o } from "./datetime-field-DavJbR0H.js";
|
|
6
6
|
import { keyedProps as s } from "@slotted/core/selector-key";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as e, c as t, i as n, l as r, n as i, o as a, r as o, s, t as c } from "./datetime-range-picker-
|
|
1
|
+
import { a as e, c as t, i as n, l as r, n as i, o as a, r as o, s, t as c } from "./datetime-range-picker-DYshAlgq.js";
|
|
2
2
|
export { n as DATETIME_RANGE_PICKER_MAX_OPTIONS, e as DATETIME_RANGE_PICKER_MONTHS, a as DATETIME_RANGE_PICKER_STEP, c as DateTimeRangePicker, s as DateTimeRangePickerDefaultsProvider, i as DateTimeRangePickerPreset, t as dateTimeRangePickerLengthLabel, o as isSameDateTimeRange, r as useDateTimeRangePickerDefaults };
|
package/dist/docs/calendar.json
CHANGED
|
@@ -86,6 +86,7 @@
|
|
|
86
86
|
"week-number",
|
|
87
87
|
"cell",
|
|
88
88
|
"day",
|
|
89
|
+
"mark",
|
|
89
90
|
"months",
|
|
90
91
|
"years",
|
|
91
92
|
"period"
|
|
@@ -182,6 +183,12 @@
|
|
|
182
183
|
"required": true,
|
|
183
184
|
"purpose": "The number the reader presses. It holds the roving tabindex, data-today, aria-selected and aria-disabled. It is the cell’s child rather than the cell itself because the range band runs edge to edge while the day stays a rounded box inside it."
|
|
184
185
|
},
|
|
186
|
+
{
|
|
187
|
+
"part": "mark",
|
|
188
|
+
"element": "span",
|
|
189
|
+
"required": false,
|
|
190
|
+
"purpose": "What falls on the day, drawn from marks: a dot in the row today’s dot reserves, in the mark’s tone, holding the visually hidden count that the day’s accessible name ends with."
|
|
191
|
+
},
|
|
185
192
|
{
|
|
186
193
|
"part": "months",
|
|
187
194
|
"element": "div",
|
|
@@ -307,6 +314,13 @@
|
|
|
307
314
|
"appliesTo": "Calendar",
|
|
308
315
|
"description": "What a day of the month either side does: drawn and not pressable, drawn and pressable, or not drawn."
|
|
309
316
|
},
|
|
317
|
+
{
|
|
318
|
+
"name": "marks",
|
|
319
|
+
"type": "ReadonlyMap<string, CalendarMark>",
|
|
320
|
+
"defaultValue": "—",
|
|
321
|
+
"appliesTo": "Calendar",
|
|
322
|
+
"description": "What falls on each day, keyed by its ISO date: a dot under the number in the mark’s tone, and its count in the day’s accessible name (“12, 2 items”). Composes with every selection mode, min, max and outsideDays."
|
|
323
|
+
},
|
|
310
324
|
{
|
|
311
325
|
"name": "locale",
|
|
312
326
|
"type": "string",
|
|
@@ -485,8 +499,12 @@
|
|
|
485
499
|
"--slotted-tone-accent-subtle-active",
|
|
486
500
|
"--slotted-tone-accent-subtle-hover",
|
|
487
501
|
"--slotted-tone-accent-text",
|
|
502
|
+
"--slotted-tone-danger-solid",
|
|
503
|
+
"--slotted-tone-info-solid",
|
|
488
504
|
"--slotted-tone-secondary-subtle-active",
|
|
489
|
-
"--slotted-tone-secondary-subtle-hover"
|
|
505
|
+
"--slotted-tone-secondary-subtle-hover",
|
|
506
|
+
"--slotted-tone-success-solid",
|
|
507
|
+
"--slotted-tone-warning-solid"
|
|
490
508
|
],
|
|
491
509
|
"examples": [
|
|
492
510
|
{
|
package/dist/docs/calendar.md
CHANGED
|
@@ -35,6 +35,7 @@ Excerpt — not a complete module
|
|
|
35
35
|
| `week-number` | th | no |
|
|
36
36
|
| `cell` | td | yes |
|
|
37
37
|
| `day` | span | yes |
|
|
38
|
+
| `mark` | span | no |
|
|
38
39
|
| `months` | div | no |
|
|
39
40
|
| `years` | div | no |
|
|
40
41
|
| `period` | button | no |
|
|
@@ -58,6 +59,7 @@ Excerpt — not a complete module
|
|
|
58
59
|
| `weekNumbers` | `boolean` | false | Calendar | Draws the ISO 8601 week number as a row header. |
|
|
59
60
|
| `fixedWeeks` | `boolean` | false | Calendar | Always six rows, so paging does not change the surface’s height. Worth setting inside a popover. |
|
|
60
61
|
| `outsideDays` | `'shown' \| 'selectable' \| 'hidden'` | shown | Calendar | What a day of the month either side does: drawn and not pressable, drawn and pressable, or not drawn. |
|
|
62
|
+
| `marks` | `ReadonlyMap<string, CalendarMark>` | — | Calendar | What falls on each day, keyed by its ISO date: a dot under the number in the mark’s tone, and its count in the day’s accessible name (“12, 2 items”). Composes with every selection mode, min, max and outsideDays. |
|
|
61
63
|
| `locale` | `string` | the language in force | Calendar | BCP 47. Decides the month names, the weekday names and the day a week starts on. |
|
|
62
64
|
| `timeZone` | `string` | the runtime’s | Calendar | Which zone answers "what is today". |
|
|
63
65
|
| `firstDayOfWeek` | `number` | the locale’s | Calendar | 0 is Sunday. Overrides what the locale says, for a product that fixes one. |
|
|
@@ -102,7 +104,7 @@ Excerpt — not a complete module
|
|
|
102
104
|
|
|
103
105
|
## Tokens
|
|
104
106
|
|
|
105
|
-
`--slotted-border-subtle`, `--slotted-border-width-thin`, `--slotted-calendar-active-background`, `--slotted-calendar-background`, `--slotted-calendar-cell-size`, `--slotted-calendar-color`, `--slotted-calendar-day-radius`, `--slotted-calendar-disabled-color`, `--slotted-calendar-hover-background`, `--slotted-calendar-in-range-color`, `--slotted-calendar-invalid-edge-width`, `--slotted-calendar-invalid-focus-ring-color`, `--slotted-calendar-outside-color`, `--slotted-calendar-preview-background`, `--slotted-calendar-preview-border-color`, `--slotted-calendar-radius`, `--slotted-calendar-range-active-background`, `--slotted-calendar-range-background`, `--slotted-calendar-range-border-color`, `--slotted-calendar-range-hover-background`, `--slotted-calendar-selected-background`, `--slotted-calendar-selected-color`, `--slotted-calendar-today-color`, `--slotted-calendar-trigger-color`, `--slotted-calendar-unavailable-color`, `--slotted-calendar-week-number-border-color`, `--slotted-calendar-week-number-color`, `--slotted-calendar-weekday-color`, `--slotted-control-font-family`, `--slotted-control-font-size-md`, `--slotted-control-gap-md`, `--slotted-control-height-md`, `--slotted-control-icon-size-md`, `--slotted-control-invalid-edge-width`, `--slotted-control-radius`, `--slotted-control-transition-duration`, `--slotted-control-transition-easing`, `--slotted-disabled-background`, `--slotted-disabled-foreground`, `--slotted-focus-ring-color`, `--slotted-focus-ring-color-invalid`, `--slotted-focus-ring-offset`, `--slotted-focus-ring-width`, `--slotted-font-size-xs`, `--slotted-font-weight-medium`, `--slotted-font-weight-regular`, `--slotted-font-weight-semibold`, `--slotted-highlight-tint-opacity`, `--slotted-radius-full`, `--slotted-radius-sm`, `--slotted-space-1`, `--slotted-space-2`, `--slotted-space-4`, `--slotted-space-6`, `--slotted-target-min`, `--slotted-text`, `--slotted-text-muted`, `--slotted-tone-accent-border`, `--slotted-tone-accent-on-solid`, `--slotted-tone-accent-solid`, `--slotted-tone-accent-subtle-active`, `--slotted-tone-accent-subtle-hover`, `--slotted-tone-accent-text`, `--slotted-tone-secondary-subtle-active`, `--slotted-tone-secondary-subtle-hover`
|
|
107
|
+
`--slotted-border-subtle`, `--slotted-border-width-thin`, `--slotted-calendar-active-background`, `--slotted-calendar-background`, `--slotted-calendar-cell-size`, `--slotted-calendar-color`, `--slotted-calendar-day-radius`, `--slotted-calendar-disabled-color`, `--slotted-calendar-hover-background`, `--slotted-calendar-in-range-color`, `--slotted-calendar-invalid-edge-width`, `--slotted-calendar-invalid-focus-ring-color`, `--slotted-calendar-outside-color`, `--slotted-calendar-preview-background`, `--slotted-calendar-preview-border-color`, `--slotted-calendar-radius`, `--slotted-calendar-range-active-background`, `--slotted-calendar-range-background`, `--slotted-calendar-range-border-color`, `--slotted-calendar-range-hover-background`, `--slotted-calendar-selected-background`, `--slotted-calendar-selected-color`, `--slotted-calendar-today-color`, `--slotted-calendar-trigger-color`, `--slotted-calendar-unavailable-color`, `--slotted-calendar-week-number-border-color`, `--slotted-calendar-week-number-color`, `--slotted-calendar-weekday-color`, `--slotted-control-font-family`, `--slotted-control-font-size-md`, `--slotted-control-gap-md`, `--slotted-control-height-md`, `--slotted-control-icon-size-md`, `--slotted-control-invalid-edge-width`, `--slotted-control-radius`, `--slotted-control-transition-duration`, `--slotted-control-transition-easing`, `--slotted-disabled-background`, `--slotted-disabled-foreground`, `--slotted-focus-ring-color`, `--slotted-focus-ring-color-invalid`, `--slotted-focus-ring-offset`, `--slotted-focus-ring-width`, `--slotted-font-size-xs`, `--slotted-font-weight-medium`, `--slotted-font-weight-regular`, `--slotted-font-weight-semibold`, `--slotted-highlight-tint-opacity`, `--slotted-radius-full`, `--slotted-radius-sm`, `--slotted-space-1`, `--slotted-space-2`, `--slotted-space-4`, `--slotted-space-6`, `--slotted-target-min`, `--slotted-text`, `--slotted-text-muted`, `--slotted-tone-accent-border`, `--slotted-tone-accent-on-solid`, `--slotted-tone-accent-solid`, `--slotted-tone-accent-subtle-active`, `--slotted-tone-accent-subtle-hover`, `--slotted-tone-accent-text`, `--slotted-tone-danger-solid`, `--slotted-tone-info-solid`, `--slotted-tone-secondary-subtle-active`, `--slotted-tone-secondary-subtle-hover`, `--slotted-tone-success-solid`, `--slotted-tone-warning-solid`
|
|
106
108
|
|
|
107
109
|
## Examples
|
|
108
110
|
|
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
false
|
|
13
13
|
],
|
|
14
14
|
"headingLevel": [
|
|
15
|
+
"auto",
|
|
15
16
|
"2",
|
|
16
17
|
"3",
|
|
17
18
|
"4",
|
|
@@ -30,7 +31,7 @@
|
|
|
30
31
|
"defaults": {
|
|
31
32
|
"columns": 12,
|
|
32
33
|
"editBar": true,
|
|
33
|
-
"headingLevel": "
|
|
34
|
+
"headingLevel": "auto",
|
|
34
35
|
"editing": false,
|
|
35
36
|
"status": "ready",
|
|
36
37
|
"loading": false,
|
|
@@ -272,10 +273,17 @@
|
|
|
272
273
|
},
|
|
273
274
|
{
|
|
274
275
|
"name": "headingLevel",
|
|
275
|
-
"type": "2 | 3 | 4 | 5 | 6",
|
|
276
|
-
"defaultValue": "
|
|
276
|
+
"type": "'auto' | 2 | 3 | 4 | 5 | 6",
|
|
277
|
+
"defaultValue": "auto",
|
|
277
278
|
"appliesTo": "DashboardGrid, DashboardWidget, DashboardGridDefaultsProvider",
|
|
278
|
-
"description": "The level of each widget’s title"
|
|
279
|
+
"description": "The level of each widget’s title; auto is one rank under the heading around the grid — h2 in a page body, one deeper inside a section — and never above h2"
|
|
280
|
+
},
|
|
281
|
+
{
|
|
282
|
+
"name": "expandedFrom",
|
|
283
|
+
"type": "number",
|
|
284
|
+
"defaultValue": "1024",
|
|
285
|
+
"appliesTo": "DashboardGrid",
|
|
286
|
+
"description": "The grid’s own width, in pixels, from which the expanded class applies; a grid beside a navigation rail keeps its layout with a lower value"
|
|
279
287
|
},
|
|
280
288
|
{
|
|
281
289
|
"name": "messages",
|
|
@@ -340,6 +348,13 @@
|
|
|
340
348
|
"appliesTo": "DashboardWidget",
|
|
341
349
|
"description": "Rows of a widget the layout does not name"
|
|
342
350
|
},
|
|
351
|
+
{
|
|
352
|
+
"name": "rows",
|
|
353
|
+
"type": "'auto'",
|
|
354
|
+
"defaultValue": "—",
|
|
355
|
+
"appliesTo": "DashboardWidget",
|
|
356
|
+
"description": "Draws the widget as many rows as its content measures, within minRows and maxRows, and moves the widgets below; the stored rows, which a resize sets, stay the minimum"
|
|
357
|
+
},
|
|
343
358
|
{
|
|
344
359
|
"name": "minColumns",
|
|
345
360
|
"type": "number",
|
|
@@ -438,6 +453,13 @@
|
|
|
438
453
|
"appliesTo": "DashboardWidget",
|
|
439
454
|
"description": "The widget’s own page, as a link in the corner"
|
|
440
455
|
},
|
|
456
|
+
{
|
|
457
|
+
"name": "renderDetail",
|
|
458
|
+
"type": "(props: DashboardDetailProps) => ReactElement",
|
|
459
|
+
"defaultValue": "—",
|
|
460
|
+
"appliesTo": "DashboardWidget",
|
|
461
|
+
"description": "Renders the detail link — a router’s link — from the props the family gives it, href included; spread them all on the element returned"
|
|
462
|
+
},
|
|
441
463
|
{
|
|
442
464
|
"name": "actions",
|
|
443
465
|
"type": "ReactNode",
|
|
@@ -75,7 +75,8 @@ const [editing, setEditing] = useState(false);
|
|
|
75
75
|
| `defaultEditing` | `boolean` | false | DashboardGrid | The uncontrolled mode, read once |
|
|
76
76
|
| `columns` | `number \| { expanded, medium, compact }` | 12 | DashboardGrid, DashboardGridDefaultsProvider | Columns from 1024 pixels of the grid’s width; below it the widgets flow in halves and wholes of half as many, and below 600 in one column |
|
|
77
77
|
| `editBar` | `boolean` | true | DashboardGrid, DashboardGridDefaultsProvider | Whether the family draws Add, Reset, Cancel and Done while editing |
|
|
78
|
-
| `headingLevel` | `2 \| 3 \| 4 \| 5 \| 6` |
|
|
78
|
+
| `headingLevel` | `'auto' \| 2 \| 3 \| 4 \| 5 \| 6` | auto | DashboardGrid, DashboardWidget, DashboardGridDefaultsProvider | The level of each widget’s title; auto is one rank under the heading around the grid — h2 in a page body, one deeper inside a section — and never above h2 |
|
|
79
|
+
| `expandedFrom` | `number` | 1024 | DashboardGrid | The grid’s own width, in pixels, from which the expanded class applies; a grid beside a navigation rail keeps its layout with a lower value |
|
|
79
80
|
| `messages` | `Partial<DashboardGridMessages>` | — | DashboardGrid | Words laid over the language in force, key by key: editBar, editStatus, add, reset, cancel, done, handle, detail, retry, emptyTitle, errorTitle, empty, emptyEditing, the eight menu items, hide, size, moved, movedInOrder, resized, hidden, shown, resetDone, cancelled |
|
|
80
81
|
| `ref` | `Ref<DashboardGridHandle>` | — | DashboardGrid | element, focusWidget(key), commitEditing(), cancelEditing() |
|
|
81
82
|
| `render` | `(props: DashboardGridRootProps) => ReactElement` | a div | DashboardGrid | Substitutes the root element |
|
|
@@ -85,6 +86,7 @@ const [editing, setEditing] = useState(false);
|
|
|
85
86
|
| `description` | `ReactNode` | — | DashboardWidget | The line under the title |
|
|
86
87
|
| `defaultColumns` | `number` | 4 | DashboardWidget | Expanded columns of a widget the layout does not name |
|
|
87
88
|
| `defaultRows` | `number` | 2 | DashboardWidget | Rows of a widget the layout does not name |
|
|
89
|
+
| `rows` | `'auto'` | — | DashboardWidget | Draws the widget as many rows as its content measures, within minRows and maxRows, and moves the widgets below; the stored rows, which a resize sets, stay the minimum |
|
|
88
90
|
| `minColumns` | `number` | 2 | DashboardWidget | The fewest expanded columns a resize leaves |
|
|
89
91
|
| `maxColumns` | `number` | columns | DashboardWidget | The most expanded columns a resize gives |
|
|
90
92
|
| `minRows` | `number` | 2 | DashboardWidget | The fewest rows a resize leaves |
|
|
@@ -99,6 +101,7 @@ const [editing, setEditing] = useState(false);
|
|
|
99
101
|
| `emptyTitle / emptyDescription / emptyAction` | `ReactNode` | messages.emptyTitle / — / — | DashboardWidget | The empty message and the action that creates the first entry |
|
|
100
102
|
| `errorTitle / errorDescription` | `ReactNode` | messages.errorTitle / — | DashboardWidget | The error message |
|
|
101
103
|
| `detailHref` | `string` | — | DashboardWidget | The widget’s own page, as a link in the corner |
|
|
104
|
+
| `renderDetail` | `(props: DashboardDetailProps) => ReactElement` | — | DashboardWidget | Renders the detail link — a router’s link — from the props the family gives it, href included; spread them all on the element returned |
|
|
102
105
|
| `actions` | `ReactNode` | — | DashboardWidget | The consumer’s controls in the header’s corner |
|
|
103
106
|
| `footer` | `ReactNode` | — | DashboardWidget | Content under the body |
|
|
104
107
|
| `fill / size` | `CardFill / CardSize` | outline / md | DashboardWidget | The card’s own axes |
|
|
@@ -121,7 +124,7 @@ const [editing, setEditing] = useState(false);
|
|
|
121
124
|
| Axis | Values | Default |
|
|
122
125
|
| --- | --- | --- |
|
|
123
126
|
| `editBar` | `true`, `false` | `true` |
|
|
124
|
-
| `headingLevel` | `2`, `3`, `4`, `5`, `6` | `
|
|
127
|
+
| `headingLevel` | `auto`, `2`, `3`, `4`, `5`, `6` | `auto` |
|
|
125
128
|
| `status` | `ready`, `empty`, `error` | `ready` |
|
|
126
129
|
|
|
127
130
|
## Rules
|
package/dist/docs/drawer.json
CHANGED
|
@@ -102,6 +102,7 @@
|
|
|
102
102
|
"grip",
|
|
103
103
|
"header",
|
|
104
104
|
"title",
|
|
105
|
+
"actions",
|
|
105
106
|
"description",
|
|
106
107
|
"body",
|
|
107
108
|
"footer",
|
|
@@ -112,7 +113,7 @@
|
|
|
112
113
|
"docs": {
|
|
113
114
|
"drawer": {
|
|
114
115
|
"imports": {
|
|
115
|
-
"source": "import { Drawer, DrawerBody, DrawerClose, DrawerDefaultsProvider, DrawerDescription, DrawerFooter, DrawerHeader, DrawerPanel, DrawerResizer, DrawerTitle, DrawerTrigger } from '@slotted/react';"
|
|
116
|
+
"source": "import { Drawer, DrawerActions, DrawerBody, DrawerClose, DrawerDefaultsProvider, DrawerDescription, DrawerFooter, DrawerHeader, DrawerPanel, DrawerResizer, DrawerTitle, DrawerTrigger } from '@slotted/react';"
|
|
116
117
|
},
|
|
117
118
|
"anatomy": [
|
|
118
119
|
{
|
|
@@ -161,7 +162,13 @@
|
|
|
161
162
|
"part": "header",
|
|
162
163
|
"element": "header, or the element render returns",
|
|
163
164
|
"required": false,
|
|
164
|
-
"purpose": "Lays out the title and the description in one column and the close button in
|
|
165
|
+
"purpose": "Lays out the title and the description in one column, the actions in a second when they are rendered, and the close button in the last, so a title that wraps grows the row instead of moving the buttons."
|
|
166
|
+
},
|
|
167
|
+
{
|
|
168
|
+
"part": "actions",
|
|
169
|
+
"element": "div, or the element render returns",
|
|
170
|
+
"required": false,
|
|
171
|
+
"purpose": "One or two actions beside the title, such as icon buttons for history and a new conversation, on the title’s row between the title and the close button. The buttons keep the size you give them."
|
|
165
172
|
},
|
|
166
173
|
{
|
|
167
174
|
"part": "title",
|
|
@@ -263,7 +270,7 @@
|
|
|
263
270
|
"type": "'sm' | 'md' | 'lg' | 'xl' | 'full' | 'content'",
|
|
264
271
|
"defaultValue": "content on top and bottom, md on start and end",
|
|
265
272
|
"appliesTo": "Drawer, DrawerDefaultsProvider",
|
|
266
|
-
"description": "The panel’s measure at rest: one of the steps sm (18rem), md (24rem), lg (30rem), xl (40rem) and full, or content, which fits what the panel holds, up to 4rem short of the screen. A step wider than the screen is held to it."
|
|
273
|
+
"description": "The panel’s measure at rest: one of the steps sm (18rem), md (24rem), lg (30rem), xl (40rem) and full, or content, which fits what the panel holds, up to 4rem short of the screen. A step wider than the screen is held to it. On a bottom sheet, full is the screen’s height and the footer rests at its bottom."
|
|
267
274
|
},
|
|
268
275
|
{
|
|
269
276
|
"name": "mount",
|
|
@@ -435,7 +442,7 @@
|
|
|
435
442
|
"Under mode=\"inline\" the panel has no role, because a navigation drawer is a navigation landmark and a filter panel is complementary; give it one with render. The trigger has no aria-haspopup there, because an inline drawer is a disclosure, not a popup.",
|
|
436
443
|
"aria-modal=\"true\" is written only while the drawer is modal, which is the only state in which the page behind is inert. modal is always false under mode=\"inline\".",
|
|
437
444
|
"The separator follows the WAI-ARIA window splitter pattern. The arrow keys move it in the direction they point, Home and End go to the limits, and Enter collapses the panel to its minimum and then restores it. Enter never closes the drawer; Escape does. The values are percentages, and there is no aria-valuetext, so a screen reader announces 40 rather than 40 per cent.",
|
|
438
|
-
"A bottom sheet moves under a touch on its body as well as on its separator, and every stop a finger reaches, the height of the content among them, is also reachable with the arrow keys on the separator. It is moved by the page’s own scroll, so a control whose touch-action takes vertical movement keeps its gesture, and a region
|
|
445
|
+
"A bottom sheet moves under a touch on its body as well as on its separator, and every stop a finger reaches, the height of the content among them, is also reachable with the arrow keys on the separator. It is moved by the page’s own scroll, so a control whose touch-action takes vertical movement keeps its gesture, and a scrolling region at its edge — a message list at its top — passes the pull on to the sheet, unless it sits inside data-drawer-drag=\"none\".",
|
|
439
446
|
"A closed panel is inert in both modes, so its controls are in neither the tab order nor the accessibility tree.",
|
|
440
447
|
"Focus moves into an overlay panel when it opens, to the first focusable element unless initialFocus names another, and returns on close to the element that had it before; if that element has left the document, focus goes to its nearest ancestor still in it. An inline drawer moves no focus when it opens, and on close restores focus only when focus is inside the panel or on the page body.",
|
|
441
448
|
"The ✕ button and the separator are each at least --slotted-target-min across, so both meet the WCAG 2.2 minimum target size of 24 by 24 pixels."
|
|
@@ -476,6 +483,8 @@
|
|
|
476
483
|
"--slotted-drawer-sheet-floor",
|
|
477
484
|
"--slotted-drawer-sheet-height",
|
|
478
485
|
"--slotted-drawer-sheet-inline-size",
|
|
486
|
+
"--slotted-drawer-slide-duration",
|
|
487
|
+
"--slotted-drawer-slide-exit-duration",
|
|
479
488
|
"--slotted-drawer-surface",
|
|
480
489
|
"--slotted-drawer-title-color",
|
|
481
490
|
"--slotted-drawer-title-font-family",
|
package/dist/docs/drawer.md
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
## Import
|
|
7
7
|
|
|
8
8
|
```tsx
|
|
9
|
-
import { Drawer, DrawerBody, DrawerClose, DrawerDefaultsProvider, DrawerDescription, DrawerFooter, DrawerHeader, DrawerPanel, DrawerResizer, DrawerTitle, DrawerTrigger } from '@slotted/react';
|
|
9
|
+
import { Drawer, DrawerActions, DrawerBody, DrawerClose, DrawerDefaultsProvider, DrawerDescription, DrawerFooter, DrawerHeader, DrawerPanel, DrawerResizer, DrawerTitle, DrawerTrigger } from '@slotted/react';
|
|
10
10
|
```
|
|
11
11
|
|
|
12
12
|
## Minimal example
|
|
@@ -103,6 +103,7 @@ export default function DrawerBasic() {
|
|
|
103
103
|
| `line` | span | yes |
|
|
104
104
|
| `grip` | span[aria-hidden] | yes |
|
|
105
105
|
| `header` | header, or the element render returns | no |
|
|
106
|
+
| `actions` | div, or the element render returns | no |
|
|
106
107
|
| `title` | h2, or the element render returns | no |
|
|
107
108
|
| `description` | p, or the element render returns | no |
|
|
108
109
|
| `body` | div, or the element render returns | no |
|
|
@@ -122,7 +123,7 @@ export default function DrawerBasic() {
|
|
|
122
123
|
| `snapPoints` | `readonly number[]` | — | Drawer | The stops the measure moves between, as fractions. With them an arrow key moves to the next stop, Home and End go to the first and the last, and a drag is released onto the nearest. |
|
|
123
124
|
| `mode` | `'overlay' \| 'inline'` | overlay | Drawer, DrawerDefaultsProvider | overlay puts the drawer over the page, in a portal; inline puts it in your own layout. The value can change while the drawer is open, and the panel’s content and the state of its fields are kept across the change. |
|
|
124
125
|
| `side` | `'start' \| 'end' \| 'top' \| 'bottom'` | end | Drawer, DrawerDefaultsProvider | The edge the panel comes from. start and end follow the writing direction, so the drawer changes sides in a right-to-left document. |
|
|
125
|
-
| `size` | `'sm' \| 'md' \| 'lg' \| 'xl' \| 'full' \| 'content'` | content on top and bottom, md on start and end | Drawer, DrawerDefaultsProvider | The panel’s measure at rest: one of the steps sm (18rem), md (24rem), lg (30rem), xl (40rem) and full, or content, which fits what the panel holds, up to 4rem short of the screen. A step wider than the screen is held to it. |
|
|
126
|
+
| `size` | `'sm' \| 'md' \| 'lg' \| 'xl' \| 'full' \| 'content'` | content on top and bottom, md on start and end | Drawer, DrawerDefaultsProvider | The panel’s measure at rest: one of the steps sm (18rem), md (24rem), lg (30rem), xl (40rem) and full, or content, which fits what the panel holds, up to 4rem short of the screen. A step wider than the screen is held to it. On a bottom sheet, full is the screen’s height and the footer rests at its bottom. |
|
|
126
127
|
| `mount` | `'active' \| 'lazy' \| 'eager'` | active | Drawer, DrawerDefaultsProvider | When an overlay layer is in the document: active only while it is open or closing, lazy from the first open on, and eager from the start, inert while closed. An inline drawer is always in the document. |
|
|
127
128
|
| `modal` | `boolean` | true | Drawer, DrawerDefaultsProvider | Whether the page behind is inert, its scroll is locked and focus is contained in the panel, and whether the panel carries aria-modal. The scrim is painted either way. Always false under mode="inline". |
|
|
128
129
|
| `escape` | `'close' \| 'none'` | close | Drawer, DrawerDefaultsProvider | Whether Escape asks to close the drawer. Escape reaches only the topmost layer, and a layer that refuses it does not pass it to the one below. |
|
|
@@ -173,14 +174,14 @@ export default function DrawerBasic() {
|
|
|
173
174
|
- Under mode="inline" the panel has no role, because a navigation drawer is a navigation landmark and a filter panel is complementary; give it one with render. The trigger has no aria-haspopup there, because an inline drawer is a disclosure, not a popup.
|
|
174
175
|
- aria-modal="true" is written only while the drawer is modal, which is the only state in which the page behind is inert. modal is always false under mode="inline".
|
|
175
176
|
- The separator follows the WAI-ARIA window splitter pattern. The arrow keys move it in the direction they point, Home and End go to the limits, and Enter collapses the panel to its minimum and then restores it. Enter never closes the drawer; Escape does. The values are percentages, and there is no aria-valuetext, so a screen reader announces 40 rather than 40 per cent.
|
|
176
|
-
- A bottom sheet moves under a touch on its body as well as on its separator, and every stop a finger reaches, the height of the content among them, is also reachable with the arrow keys on the separator. It is moved by the page’s own scroll, so a control whose touch-action takes vertical movement keeps its gesture, and a region
|
|
177
|
+
- A bottom sheet moves under a touch on its body as well as on its separator, and every stop a finger reaches, the height of the content among them, is also reachable with the arrow keys on the separator. It is moved by the page’s own scroll, so a control whose touch-action takes vertical movement keeps its gesture, and a scrolling region at its edge — a message list at its top — passes the pull on to the sheet, unless it sits inside data-drawer-drag="none".
|
|
177
178
|
- A closed panel is inert in both modes, so its controls are in neither the tab order nor the accessibility tree.
|
|
178
179
|
- Focus moves into an overlay panel when it opens, to the first focusable element unless initialFocus names another, and returns on close to the element that had it before; if that element has left the document, focus goes to its nearest ancestor still in it. An inline drawer moves no focus when it opens, and on close restores focus only when focus is inside the panel or on the page body.
|
|
179
180
|
- The ✕ button and the separator are each at least --slotted-target-min across, so both meet the WCAG 2.2 minimum target size of 24 by 24 pixels.
|
|
180
181
|
|
|
181
182
|
## Tokens
|
|
182
183
|
|
|
183
|
-
`--slotted-border-strong`, `--slotted-border-subtle`, `--slotted-border-width-thick`, `--slotted-border-width-thin`, `--slotted-control-font-family`, `--slotted-control-icon-size-md`, `--slotted-control-inner-size-md`, `--slotted-control-radius`, `--slotted-control-transition-duration`, `--slotted-control-transition-easing`, `--slotted-drawer-backdrop-filter`, `--slotted-drawer-body-color`, `--slotted-drawer-border-color`, `--slotted-drawer-close-active-background`, `--slotted-drawer-close-color`, `--slotted-drawer-close-hover-background`, `--slotted-drawer-color`, `--slotted-drawer-description-color`, `--slotted-drawer-extent`, `--slotted-drawer-extent-lg`, `--slotted-drawer-extent-md`, `--slotted-drawer-extent-sm`, `--slotted-drawer-extent-xl`, `--slotted-drawer-footer-surface`, `--slotted-drawer-radius`, `--slotted-drawer-radius-expanded`, `--slotted-drawer-resizer-line-active-color`, `--slotted-drawer-resizer-line-color`, `--slotted-drawer-rule-color`, `--slotted-drawer-scrim`, `--slotted-drawer-sheet-floor`, `--slotted-drawer-sheet-height`, `--slotted-drawer-sheet-inline-size`, `--slotted-drawer-surface`, `--slotted-drawer-title-color`, `--slotted-drawer-title-font-family`, `--slotted-duration-instant`, `--slotted-duration-long`, `--slotted-duration-medium`, `--slotted-duration-short`, `--slotted-easing-enter`, `--slotted-easing-exit`, `--slotted-easing-standard`, `--slotted-focus-ring-color`, `--slotted-focus-ring-offset`, `--slotted-focus-ring-width`, `--slotted-font-family-heading`, `--slotted-font-family-sans`, `--slotted-font-size-lg`, `--slotted-font-size-md`, `--slotted-font-size-xl`, `--slotted-font-weight-semibold`, `--slotted-line-height-lg`, `--slotted-line-height-md`, `--slotted-radius-full`, `--slotted-radius-lg`, `--slotted-radius-sm`, `--slotted-scrim`, `--slotted-shadow-lg`, `--slotted-space-11`, `--slotted-space-12`, `--slotted-space-2`, `--slotted-space-4`, `--slotted-space-5`, `--slotted-space-6`, `--slotted-space-7`, `--slotted-space-8`, `--slotted-space-9`, `--slotted-surface-raised`, `--slotted-surface-sunken`, `--slotted-target-comfortable`, `--slotted-target-min`, `--slotted-text`, `--slotted-text-muted`, `--slotted-tone-secondary-subtle-active`, `--slotted-tone-secondary-subtle-hover`, `--slotted-z-index-overlay`
|
|
184
|
+
`--slotted-border-strong`, `--slotted-border-subtle`, `--slotted-border-width-thick`, `--slotted-border-width-thin`, `--slotted-control-font-family`, `--slotted-control-icon-size-md`, `--slotted-control-inner-size-md`, `--slotted-control-radius`, `--slotted-control-transition-duration`, `--slotted-control-transition-easing`, `--slotted-drawer-backdrop-filter`, `--slotted-drawer-body-color`, `--slotted-drawer-border-color`, `--slotted-drawer-close-active-background`, `--slotted-drawer-close-color`, `--slotted-drawer-close-hover-background`, `--slotted-drawer-color`, `--slotted-drawer-description-color`, `--slotted-drawer-extent`, `--slotted-drawer-extent-lg`, `--slotted-drawer-extent-md`, `--slotted-drawer-extent-sm`, `--slotted-drawer-extent-xl`, `--slotted-drawer-footer-surface`, `--slotted-drawer-radius`, `--slotted-drawer-radius-expanded`, `--slotted-drawer-resizer-line-active-color`, `--slotted-drawer-resizer-line-color`, `--slotted-drawer-rule-color`, `--slotted-drawer-scrim`, `--slotted-drawer-sheet-floor`, `--slotted-drawer-sheet-height`, `--slotted-drawer-sheet-inline-size`, `--slotted-drawer-slide-duration`, `--slotted-drawer-slide-exit-duration`, `--slotted-drawer-surface`, `--slotted-drawer-title-color`, `--slotted-drawer-title-font-family`, `--slotted-duration-instant`, `--slotted-duration-long`, `--slotted-duration-medium`, `--slotted-duration-short`, `--slotted-easing-enter`, `--slotted-easing-exit`, `--slotted-easing-standard`, `--slotted-focus-ring-color`, `--slotted-focus-ring-offset`, `--slotted-focus-ring-width`, `--slotted-font-family-heading`, `--slotted-font-family-sans`, `--slotted-font-size-lg`, `--slotted-font-size-md`, `--slotted-font-size-xl`, `--slotted-font-weight-semibold`, `--slotted-line-height-lg`, `--slotted-line-height-md`, `--slotted-radius-full`, `--slotted-radius-lg`, `--slotted-radius-sm`, `--slotted-scrim`, `--slotted-shadow-lg`, `--slotted-space-11`, `--slotted-space-12`, `--slotted-space-2`, `--slotted-space-4`, `--slotted-space-5`, `--slotted-space-6`, `--slotted-space-7`, `--slotted-space-8`, `--slotted-space-9`, `--slotted-surface-raised`, `--slotted-surface-sunken`, `--slotted-target-comfortable`, `--slotted-target-min`, `--slotted-text`, `--slotted-text-muted`, `--slotted-tone-secondary-subtle-active`, `--slotted-tone-secondary-subtle-hover`, `--slotted-z-index-overlay`
|
|
184
185
|
|
|
185
186
|
## Examples
|
|
186
187
|
|
package/dist/docs/link.json
CHANGED
|
@@ -7,6 +7,11 @@
|
|
|
7
7
|
"summary": "Text link to another page or resource."
|
|
8
8
|
},
|
|
9
9
|
"axes": {
|
|
10
|
+
"size": [
|
|
11
|
+
"xs",
|
|
12
|
+
"sm",
|
|
13
|
+
"md"
|
|
14
|
+
],
|
|
10
15
|
"underline": [
|
|
11
16
|
"always",
|
|
12
17
|
"hover",
|
|
@@ -88,6 +93,13 @@
|
|
|
88
93
|
"appliesTo": "Link",
|
|
89
94
|
"description": "Accent, the colour of the surrounding text, or a solid surface"
|
|
90
95
|
},
|
|
96
|
+
{
|
|
97
|
+
"name": "size",
|
|
98
|
+
"type": "'xs' | 'sm' | 'md'",
|
|
99
|
+
"defaultValue": "—",
|
|
100
|
+
"appliesTo": "Link",
|
|
101
|
+
"description": "The text size: 12, 13 or 14 pixels on the type scale. Unset, the link takes the size its action slot states — a stat card’s action, a section’s or a chart’s actions state sm — or else its parent’s"
|
|
102
|
+
},
|
|
91
103
|
{
|
|
92
104
|
"name": "external",
|
|
93
105
|
"type": "boolean",
|
|
@@ -174,6 +186,9 @@
|
|
|
174
186
|
"--slotted-easing-standard",
|
|
175
187
|
"--slotted-focus-ring-color",
|
|
176
188
|
"--slotted-focus-ring-width",
|
|
189
|
+
"--slotted-font-size-md",
|
|
190
|
+
"--slotted-font-size-sm",
|
|
191
|
+
"--slotted-font-size-xs",
|
|
177
192
|
"--slotted-link-color",
|
|
178
193
|
"--slotted-link-color-active",
|
|
179
194
|
"--slotted-link-color-current",
|
|
@@ -183,6 +198,7 @@
|
|
|
183
198
|
"--slotted-link-external-icon-gap",
|
|
184
199
|
"--slotted-link-external-icon-size",
|
|
185
200
|
"--slotted-link-focus-ring-offset",
|
|
201
|
+
"--slotted-link-font-size",
|
|
186
202
|
"--slotted-link-radius",
|
|
187
203
|
"--slotted-link-underline-color",
|
|
188
204
|
"--slotted-link-underline-offset",
|
package/dist/docs/link.md
CHANGED
|
@@ -33,6 +33,7 @@ Excerpt — not a complete module
|
|
|
33
33
|
| --- | --- | --- | --- | --- |
|
|
34
34
|
| `underline` | `'always' \| 'hover' \| 'none'` | always | Link | When the underline is drawn |
|
|
35
35
|
| `variant` | `'accent' \| 'neutral' \| 'inverse'` | accent | Link | Accent, the colour of the surrounding text, or a solid surface |
|
|
36
|
+
| `size` | `'xs' \| 'sm' \| 'md'` | — | Link | The text size: 12, 13 or 14 pixels on the type scale. Unset, the link takes the size its action slot states — a stat card’s action, a section’s or a chart’s actions state sm — or else its parent’s |
|
|
36
37
|
| `external` | `boolean` | false | Link | Opens a new tab and warns that it does |
|
|
37
38
|
| `messages` | `Partial<LinkMessages>` | — | Link | Words laid over the language in force: the wording of that warning (externalHint) |
|
|
38
39
|
| `disabled` | `boolean` | false | Link | Withholds the destination, keeps the role, the state and the tab stop |
|
|
@@ -47,6 +48,7 @@ Excerpt — not a complete module
|
|
|
47
48
|
|
|
48
49
|
| Axis | Values | Default |
|
|
49
50
|
| --- | --- | --- |
|
|
51
|
+
| `size` | `xs`, `sm`, `md` | — |
|
|
50
52
|
| `underline` | `always`, `hover`, `none` | `always` |
|
|
51
53
|
| `variant` | `accent`, `neutral`, `inverse` | `accent` |
|
|
52
54
|
|
|
@@ -63,7 +65,7 @@ Excerpt — not a complete module
|
|
|
63
65
|
|
|
64
66
|
## Tokens
|
|
65
67
|
|
|
66
|
-
`--slotted-control-radius`, `--slotted-disabled-foreground`, `--slotted-duration-short`, `--slotted-easing-standard`, `--slotted-focus-ring-color`, `--slotted-focus-ring-width`, `--slotted-link-color`, `--slotted-link-color-active`, `--slotted-link-color-current`, `--slotted-link-color-disabled`, `--slotted-link-color-hover`, `--slotted-link-color-visited`, `--slotted-link-external-icon-gap`, `--slotted-link-external-icon-size`, `--slotted-link-focus-ring-offset`, `--slotted-link-radius`, `--slotted-link-underline-color`, `--slotted-link-underline-offset`, `--slotted-link-underline-thickness`, `--slotted-text`, `--slotted-text-inverse`, `--slotted-text-muted`, `--slotted-tone-accent-text`
|
|
68
|
+
`--slotted-control-radius`, `--slotted-disabled-foreground`, `--slotted-duration-short`, `--slotted-easing-standard`, `--slotted-focus-ring-color`, `--slotted-focus-ring-width`, `--slotted-font-size-md`, `--slotted-font-size-sm`, `--slotted-font-size-xs`, `--slotted-link-color`, `--slotted-link-color-active`, `--slotted-link-color-current`, `--slotted-link-color-disabled`, `--slotted-link-color-hover`, `--slotted-link-color-visited`, `--slotted-link-external-icon-gap`, `--slotted-link-external-icon-size`, `--slotted-link-focus-ring-offset`, `--slotted-link-font-size`, `--slotted-link-radius`, `--slotted-link-underline-color`, `--slotted-link-underline-offset`, `--slotted-link-underline-thickness`, `--slotted-text`, `--slotted-text-inverse`, `--slotted-text-muted`, `--slotted-tone-accent-text`
|
|
67
69
|
|
|
68
70
|
## Examples
|
|
69
71
|
|
package/dist/docs/list-item.json
CHANGED
|
@@ -83,48 +83,56 @@
|
|
|
83
83
|
},
|
|
84
84
|
{
|
|
85
85
|
"part": "marker",
|
|
86
|
+
"parent": "root",
|
|
86
87
|
"element": "span",
|
|
87
88
|
"required": false,
|
|
88
89
|
"purpose": "The bullet, rendered only when marker is bullet: the dot Glyph in the marker column, before content and hidden from assistive technology. A numbered marker is a counter the stylesheet writes, because it is text."
|
|
89
90
|
},
|
|
90
91
|
{
|
|
91
92
|
"part": "content",
|
|
93
|
+
"parent": "root",
|
|
92
94
|
"element": "div, button or a",
|
|
93
95
|
"required": true,
|
|
94
96
|
"purpose": "The box that is read, hovered, focused and — for two of the three — activated. Three elements rather than one as prop, because the three are three different accessibility trees."
|
|
95
97
|
},
|
|
96
98
|
{
|
|
97
99
|
"part": "start",
|
|
100
|
+
"parent": "content",
|
|
98
101
|
"element": "div",
|
|
99
102
|
"required": false,
|
|
100
103
|
"purpose": "The leading column: an icon, an avatar, a Checkbox. It is the slot and not the control, and the chooser here is also what announces a selection the row only paints."
|
|
101
104
|
},
|
|
102
105
|
{
|
|
103
106
|
"part": "body",
|
|
107
|
+
"parent": "content",
|
|
104
108
|
"element": "div",
|
|
105
109
|
"required": false,
|
|
106
110
|
"purpose": "The text column, and the one box in the row that may shrink — which is what lets an unbroken token break instead of pushing the metadata out of the row."
|
|
107
111
|
},
|
|
108
112
|
{
|
|
109
113
|
"part": "label",
|
|
114
|
+
"parent": "body",
|
|
110
115
|
"element": "div",
|
|
111
116
|
"required": false,
|
|
112
117
|
"purpose": "The title. It clips under truncate, isolates its own direction so another script does not reorder the row, and breaks a single unbroken token."
|
|
113
118
|
},
|
|
114
119
|
{
|
|
115
120
|
"part": "description",
|
|
121
|
+
"parent": "body",
|
|
116
122
|
"element": "div",
|
|
117
123
|
"required": false,
|
|
118
124
|
"purpose": "The lines under the title. They clip with it, never instead of it."
|
|
119
125
|
},
|
|
120
126
|
{
|
|
121
127
|
"part": "end",
|
|
128
|
+
"parent": "content",
|
|
122
129
|
"element": "div",
|
|
123
130
|
"required": false,
|
|
124
131
|
"purpose": "Trailing metadata that is part of what the row says — a timestamp, a count, a Badge. Below 22rem it leaves the inline axis and sits under the title."
|
|
125
132
|
},
|
|
126
133
|
{
|
|
127
134
|
"part": "actions",
|
|
135
|
+
"parent": "root",
|
|
128
136
|
"element": "div",
|
|
129
137
|
"required": false,
|
|
130
138
|
"purpose": "Independent targets, and a sibling of the box rather than its child: interactive content may not nest inside an a or a button."
|
|
@@ -410,9 +418,9 @@
|
|
|
410
418
|
{
|
|
411
419
|
"id": "anatomy",
|
|
412
420
|
"title": "Every part, and a row with almost none",
|
|
413
|
-
"note": "Every part but the box is optional, and an absent one leaves no column behind: each gap is a margin on the part rather than a track on the grid.",
|
|
421
|
+
"note": "Every part but the box is optional, and an absent one leaves no column behind: each gap is a margin on the part rather than a track on the grid. ListItemEnd takes metadata, inside the box; ListItemActions takes controls, beside it.",
|
|
414
422
|
"language": "tsx",
|
|
415
|
-
"source": "<ListItem>\n <ListItemContent>\n <ListItemStart>{icon}</ListItemStart>\n <ListItemBody>\n <ListItemLabel>Photos</ListItemLabel>\n <ListItemDescription>128 files</ListItemDescription>\n </ListItemBody>\n <ListItemEnd>Yesterday</ListItemEnd>\n </ListItemContent>\n <ListItemActions
|
|
423
|
+
"source": "<ListItem>\n <ListItemContent>\n <ListItemStart>{icon}</ListItemStart>\n <ListItemBody>\n <ListItemLabel>Photos</ListItemLabel>\n <ListItemDescription>128 files</ListItemDescription>\n </ListItemBody>\n <ListItemEnd>Yesterday</ListItemEnd>\n </ListItemContent>\n <ListItemActions>\n <Button size=\"sm\" variant=\"ghost\" onClick={rename}>\n Rename\n </Button>\n <Button size=\"sm\" variant=\"ghost\" onClick={remove}>\n Remove\n </Button>\n </ListItemActions>\n</ListItem>;\n",
|
|
416
424
|
"verdict": "excerpt"
|
|
417
425
|
},
|
|
418
426
|
{
|
package/dist/docs/list-item.md
CHANGED
|
@@ -26,17 +26,17 @@ Excerpt — not a complete module
|
|
|
26
26
|
|
|
27
27
|
## Anatomy
|
|
28
28
|
|
|
29
|
-
| Part | Element | Required |
|
|
30
|
-
| --- | --- | --- |
|
|
31
|
-
| `root` | li, or the element render returns | yes |
|
|
32
|
-
| `marker` | span | no |
|
|
33
|
-
| `content` | div, button or a | yes |
|
|
34
|
-
| `start` | div | no |
|
|
35
|
-
| `body` | div | no |
|
|
36
|
-
| `label` | div | no |
|
|
37
|
-
| `description` | div | no |
|
|
38
|
-
| `end` | div | no |
|
|
39
|
-
| `actions` | div | no |
|
|
29
|
+
| Part | Parent | Element | Required |
|
|
30
|
+
| --- | --- | --- | --- |
|
|
31
|
+
| `root` | — | li, or the element render returns | yes |
|
|
32
|
+
| `marker` | `root` | span | no |
|
|
33
|
+
| `content` | `root` | div, button or a | yes |
|
|
34
|
+
| `start` | `content` | div | no |
|
|
35
|
+
| `body` | `content` | div | no |
|
|
36
|
+
| `label` | `body` | div | no |
|
|
37
|
+
| `description` | `body` | div | no |
|
|
38
|
+
| `end` | `content` | div | no |
|
|
39
|
+
| `actions` | `root` | div | no |
|
|
40
40
|
|
|
41
41
|
## Props
|
|
42
42
|
|
|
@@ -103,7 +103,7 @@ Excerpt — not a complete module
|
|
|
103
103
|
|
|
104
104
|
### Every part, and a row with almost none
|
|
105
105
|
|
|
106
|
-
Every part but the box is optional, and an absent one leaves no column behind: each gap is a margin on the part rather than a track on the grid.
|
|
106
|
+
Every part but the box is optional, and an absent one leaves no column behind: each gap is a margin on the part rather than a track on the grid. ListItemEnd takes metadata, inside the box; ListItemActions takes controls, beside it.
|
|
107
107
|
|
|
108
108
|
Excerpt — not a complete module
|
|
109
109
|
|
|
@@ -117,7 +117,14 @@ Excerpt — not a complete module
|
|
|
117
117
|
</ListItemBody>
|
|
118
118
|
<ListItemEnd>Yesterday</ListItemEnd>
|
|
119
119
|
</ListItemContent>
|
|
120
|
-
<ListItemActions>
|
|
120
|
+
<ListItemActions>
|
|
121
|
+
<Button size="sm" variant="ghost" onClick={rename}>
|
|
122
|
+
Rename
|
|
123
|
+
</Button>
|
|
124
|
+
<Button size="sm" variant="ghost" onClick={remove}>
|
|
125
|
+
Remove
|
|
126
|
+
</Button>
|
|
127
|
+
</ListItemActions>
|
|
121
128
|
</ListItem>;
|
|
122
129
|
```
|
|
123
130
|
|
package/dist/docs/markdown.json
CHANGED
|
@@ -118,6 +118,13 @@
|
|
|
118
118
|
"appliesTo": "Markdown",
|
|
119
119
|
"description": "The document in mdast; never HTML"
|
|
120
120
|
},
|
|
121
|
+
{
|
|
122
|
+
"name": "source",
|
|
123
|
+
"type": "string",
|
|
124
|
+
"defaultValue": "—",
|
|
125
|
+
"appliesTo": "Markdown",
|
|
126
|
+
"description": "The document as CommonMark text, read by parseMarkdown in place of tree: the syntax of the types in allow is read and any other stays text. Paragraphs, ATX headings, fenced code, quotes, rules, nested lists, code spans, strong, emphasis, links, escapes and hard breaks; tables, images and HTML need an adapter"
|
|
127
|
+
},
|
|
121
128
|
{
|
|
122
129
|
"name": "size",
|
|
123
130
|
"type": "'md' | 'lg' | 'xl'",
|