@platned/ui 0.6.1 → 0.7.1

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/index.d.cts CHANGED
@@ -1,6 +1,8 @@
1
1
  import * as react from 'react';
2
- import { ButtonHTMLAttributes, ReactNode, InputHTMLAttributes, HTMLAttributes, LabelHTMLAttributes, TextareaHTMLAttributes, ReactElement, RefObject, AnchorHTMLAttributes, TdHTMLAttributes, ThHTMLAttributes, Key } from 'react';
2
+ import { ButtonHTMLAttributes, ReactNode, InputHTMLAttributes, HTMLAttributes, LabelHTMLAttributes, TextareaHTMLAttributes, ChangeEventHandler, RefObject, ReactElement, Ref, AnchorHTMLAttributes, TdHTMLAttributes, ThHTMLAttributes, Component, ErrorInfo } from 'react';
3
3
  import { ClassValue } from 'clsx';
4
+ import { Column, Table as Table$1, ColumnDef, RowData, SortingState, ColumnFiltersState, PaginationState, VisibilityState, RowSelectionState, TableOptions } from '@tanstack/react-table';
5
+ export { CellContext, ColumnDef, ColumnFiltersState, Column as DataTableColumn, Table as DataTableInstance, HeaderContext, PaginationState, Row, RowSelectionState, SortingState, VisibilityState, createColumnHelper } from '@tanstack/react-table';
4
6
 
5
7
  type ButtonVariant = 'primary' | 'neutral' | 'subtle' | 'danger' | 'danger-subtle';
6
8
  type ButtonSize = 'lg' | 'md' | 'sm';
@@ -15,8 +17,13 @@ interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
15
17
  */
16
18
  asChild?: boolean;
17
19
  /**
18
- * Swaps the leading icon for a spinner and disables the button. `aria-busy` is set so
19
- * assistive tech reports the pending state rather than only the disabled one.
20
+ * Swaps the leading icon for a spinner and stops the button acting on a press.
21
+ * `aria-busy` is set so assistive tech reports the pending state.
22
+ *
23
+ * From 0.7.0 this uses `aria-disabled`, not the native `disabled` attribute. A natively
24
+ * disabled button loses focus, so pressing "Save" dropped keyboard focus to <body> the
25
+ * moment the request started. Now focus stays on the button and moves on normally when it
26
+ * finishes.
20
27
  */
21
28
  loading?: boolean;
22
29
  /** Announced while `loading`. Defaults to the button's own content. */
@@ -227,7 +234,7 @@ interface FieldSetProps extends HTMLAttributes<HTMLFieldSetElement> {
227
234
  * A real `<fieldset>`. Required for radio groups and checkbox groups: the group needs a
228
235
  * name of its own, and only `<legend>` gives it one that is announced before each option.
229
236
  */
230
- declare function FieldSet({ children, className, ...rest }: FieldSetProps): react.JSX.Element;
237
+ declare const FieldSet: react.ForwardRefExoticComponent<FieldSetProps & react.RefAttributes<HTMLFieldSetElement>>;
231
238
  interface FieldLegendProps extends HTMLAttributes<HTMLLegendElement> {
232
239
  children: ReactNode;
233
240
  /** `label` matches a field label's weight; `legend` is the larger section heading. */
@@ -283,9 +290,9 @@ interface SelectControlProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement
283
290
  defaultValue?: string | null;
284
291
  onValueChange?: (value: string) => void;
285
292
  /**
286
- * Submits with a surrounding form, through a hidden input. Note that hidden inputs are
287
- * exempt from constraint validation, so `required` no longer blocks submit — see the
288
- * note on `Select`.
293
+ * Submits with a surrounding form. With `required`, the value posts through a visually
294
+ * hidden real input, so an empty required select blocks submit like a native one (from
295
+ * 0.7.0) — see the note on `Select`.
289
296
  */
290
297
  name?: string;
291
298
  size?: InputSize;
@@ -318,32 +325,68 @@ interface SelectProps extends SelectControlProps {
318
325
  * Two consequences of dropping the native element, neither papered over:
319
326
  *
320
327
  * - **No OS picker on mobile.** The wheel/sheet a native select opens is gone.
321
- * - **`required` no longer blocks submit.** The value posts through a hidden input, and
322
- * hidden inputs are exempt from constraint validation. `required` remains semantic and
323
- * visual — `aria-required` on the control and the `*` on its label — which is already
324
- * true of `Combobox`, `RadioGroup` and `MultiSelectCard`. In react-hook-form, register
325
- * it with `Controller` rather than `register`.
328
+ * - **`required` blocks submit again from 0.7.0**, for a select with a `name`. 0.5 and 0.6
329
+ * posted through a hidden input, which constraint validation ignores. A required select
330
+ * now posts through an invisible real input that the browser validates. In
331
+ * react-hook-form, register it with `Controller` rather than `register`.
332
+ *
333
+ * Kept as our own component rather than Radix Select in 0.7.0, deliberately. Radix Select is
334
+ * modal (it locks page scroll and hides the page while open), which is wrong for a form field,
335
+ * and it needs pointer-capture polyfills to run in jsdom, so adopting it would have broken
336
+ * every consumer's test suite.
326
337
  *
327
338
  * For a list long enough to need filtering, use `Combobox`.
328
339
  */
329
340
  declare const Select: react.ForwardRefExoticComponent<SelectProps & react.RefAttributes<HTMLButtonElement>>;
330
341
 
331
- interface DatePickerProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'type'> {
342
+ interface DatePickerProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'type' | 'value' | 'defaultValue'> {
332
343
  label?: string;
333
344
  description?: string;
334
345
  /** Red border + message shown below the control. Also sets `aria-invalid`. */
335
346
  error?: string;
336
347
  hint?: string;
337
348
  size?: InputSize;
349
+ /** The selected date as an ISO `YYYY-MM-DD` string, `''` for none. Controlled. */
350
+ value?: string;
351
+ /** Initial ISO date when uncontrolled. */
352
+ defaultValue?: string;
353
+ /**
354
+ * Called with a real change event from the underlying date input, so
355
+ * `onChange={(e) => set(e.target.value)}` keeps working; `e.target.value` is the ISO date.
356
+ */
357
+ onChange?: ChangeEventHandler<HTMLInputElement>;
358
+ /** The new ISO date. New in 0.7.1; an alternative to reading `onChange`'s event. */
359
+ onValueChange?: (value: string) => void;
360
+ /** Shown when there is no date. Default "Pick a date". */
361
+ placeholder?: string;
362
+ /** BCP 47 tag for the shown date and the calendar. Default: the browser's. */
363
+ locale?: string;
364
+ /** 0 = Sunday, 1 = Monday. Default `1`. */
365
+ weekStartsOn?: 0 | 1;
366
+ /** `dropdown` (default) puts month and year selects in the calendar header. */
367
+ captionLayout?: 'label' | 'dropdown';
368
+ /** First year in the year select. Default `min`'s year, else 100 years ago. */
369
+ startYear?: number;
370
+ /** Last year in the year select. Default `max`'s year, else 10 years ahead. */
371
+ endYear?: number;
338
372
  }
339
373
  /**
340
- * A native `<input type="date">`.
341
- *
342
- * The `::-webkit-calendar-picker-indicator` styling below is Chromium-only — on Firefox
343
- * and Safari the native affordance differs, so the drawn `LuCalendar` sits alongside
344
- * whatever the platform renders rather than replacing it. That is a known limitation of
345
- * this component, not a bug to paper over: for a real month grid, range selection, locale
346
- * control or min/max navigation, use `Calendar` and `DateField` instead.
374
+ * A date field that opens the library's `Calendar` in a `Popover`, the shape of shadcn/ui's
375
+ * Date Picker. Rebuilt in 0.7.1: through 0.7.0 it was a native `<input type="date">`, whose
376
+ * picker is the browser's own and differs in Chromium, Firefox and Safari (Firefox draws its
377
+ * own button inside the field and cannot be restyled), so it never matched `Calendar`.
378
+ *
379
+ * - The trigger is a `role="combobox"` button with `aria-haspopup="dialog"`, named by the label
380
+ * and then the date ("Start date 22 Oct 2026"); unlike a plain button, that role carries the
381
+ * `aria-required` and `aria-invalid` that `Field` supplies.
382
+ * - Opening moves focus into the calendar grid, on the selected date or today. Picking a date
383
+ * closes the popover and returns focus to the trigger; Escape closes it without a change.
384
+ * - The month and year selects (`captionLayout="dropdown"`, the default) reach a far-away date
385
+ * in two choices instead of a PageUp per month.
386
+ * - A real, invisible `<input type="date">` keeps the old contract: it carries `name`, `value`,
387
+ * `min`, `max` and `required` for forms and native validation, the forwarded ref points at
388
+ * it, and `onChange` receives its genuine change event. When validation focuses it, focus is
389
+ * handed to the trigger.
347
390
  */
348
391
  declare const DatePicker: react.ForwardRefExoticComponent<DatePickerProps & react.RefAttributes<HTMLInputElement>>;
349
392
 
@@ -394,6 +437,14 @@ interface SwitchProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'onC
394
437
  description?: ReactNode;
395
438
  /** Track size. `sm` is 36×20, `md` is 44×24. */
396
439
  size?: SwitchSize;
440
+ /**
441
+ * Submits with a surrounding form, as `name=value` while on. New in 0.7.0: through 0.6 a
442
+ * Switch posted nothing, so it could not take part in a plain form.
443
+ */
444
+ name?: string;
445
+ /** The value posted while on. Default `"on"`, as for a native checkbox. */
446
+ value?: string;
447
+ required?: boolean;
397
448
  }
398
449
  /**
399
450
  * An on/off switch — a setting that takes effect immediately, with no save step.
@@ -519,8 +570,81 @@ interface FileDropZoneProps {
519
570
  onFileSelected?: (file: File) => void;
520
571
  disabled?: boolean;
521
572
  }
573
+ /** Human-readable byte count: "820 KB", "1.4 MB". New in 0.7.0, from SCIC. */
574
+ declare function formatFileSize(bytes: number): string;
575
+ interface UseFilePickerOptions {
576
+ accept?: string;
577
+ maxSizeBytes?: number;
578
+ onFileSelected?: (file: File) => void;
579
+ }
580
+ interface UseFilePicker {
581
+ /** Spread onto a hidden `<input type="file">`, which must be rendered. */
582
+ inputProps: InputHTMLAttributes<HTMLInputElement> & {
583
+ ref: RefObject<HTMLInputElement>;
584
+ };
585
+ /** Opens the native picker. */
586
+ open: () => void;
587
+ /** Runs the same accept and size checks on dropped files. */
588
+ handleFiles: (files: FileList | null) => void;
589
+ /** Validation message for the last rejected file, if any. */
590
+ error: string | null;
591
+ }
592
+ /**
593
+ * The accept-list and size validation behind every way into a file upload: the drop zone, and
594
+ * any "Replace" button that skips it. One implementation, so the checks cannot drift apart.
595
+ * New in 0.7.0, from SCIC.
596
+ */
597
+ declare function useFilePicker({ accept, maxSizeBytes, onFileSelected, }?: UseFilePickerOptions): UseFilePicker;
522
598
  declare function FileDropZone({ className, description, accept, maxSizeBytes, onFileSelected, disabled, }: FileDropZoneProps): react.JSX.Element;
523
599
 
600
+ type TagInputParseResult = {
601
+ value: string;
602
+ } | {
603
+ error: string;
604
+ };
605
+ interface TagInputProps {
606
+ label?: string;
607
+ hint?: string;
608
+ /** An error from outside (e.g. the server). Takes precedence over a parse error. */
609
+ error?: string;
610
+ placeholder?: string;
611
+ disabled?: boolean;
612
+ required?: boolean;
613
+ /** The committed chips, controlled. */
614
+ value?: string[];
615
+ /** The initial chips, uncontrolled. Default none. */
616
+ defaultValue?: string[];
617
+ /** Receives the whole next array when a chip is added or removed. */
618
+ onValueChange?: (value: string[]) => void;
619
+ /** Posts each chip with a surrounding form, as repeated fields of this name. */
620
+ name?: string;
621
+ /** Validates and normalises each token, e.g. lower-case an email or reject a bad one. */
622
+ parse?: (raw: string) => TagInputParseResult;
623
+ /** What separates tokens when typed or pasted. Default whitespace. A `g` or `y` flag is safe. */
624
+ delimiter?: RegExp;
625
+ maxTags?: number;
626
+ /** Told whenever rejected text is sitting in the field, so a form can block saving. */
627
+ onInvalidChange?: (invalid: boolean) => void;
628
+ id?: string;
629
+ className?: string;
630
+ }
631
+ /**
632
+ * A multi-value text field: type or paste values, and each becomes a removable chip. Emails,
633
+ * domains, tags. New in 0.7.0, from SCIC (whose `onChange` is `onValueChange` here, matching
634
+ * every other DS control).
635
+ *
636
+ * Controlled with `value`, or uncontrolled with `defaultValue`. With `name` it posts each chip
637
+ * with a form, and `required` then blocks submit while there are none.
638
+ *
639
+ * Enter, the delimiter, blur and a delimited paste all commit. Backspace in an empty field removes
640
+ * the last chip. Duplicates are ignored. A token `parse` rejects stays in the field with its error
641
+ * rather than being dropped, so nothing the user typed silently disappears.
642
+ *
643
+ * Wired through `Field` like the other text fields: the label names the input, and the error or
644
+ * hint describes it.
645
+ */
646
+ declare function TagInput({ label, hint, error, required, disabled, id, className, ...rest }: TagInputProps): react.JSX.Element;
647
+
524
648
  declare function FormCard({ children, className, }: {
525
649
  children: ReactNode;
526
650
  className?: string;
@@ -535,10 +659,14 @@ interface FormCardFooterProps {
535
659
  onBack?: () => void;
536
660
  onContinue?: () => void;
537
661
  continueLabel?: string;
662
+ /** The continue button's trailing glyph. Default an arrow; `null` for none (e.g. "Submit"). */
663
+ continueIcon?: ReactNode | null;
538
664
  backDisabled?: boolean;
539
665
  continueDisabled?: boolean;
666
+ /** Disable "Save as draft" while keeping it visible, e.g. while a draft save is in flight. */
667
+ saveDraftDisabled?: boolean;
540
668
  }
541
- declare function FormCardFooter({ onSaveDraft, onBack, onContinue, continueLabel, backDisabled, continueDisabled, }: FormCardFooterProps): react.JSX.Element;
669
+ declare function FormCardFooter({ onSaveDraft, onBack, onContinue, continueLabel, continueIcon, backDisabled, continueDisabled, saveDraftDisabled, }: FormCardFooterProps): react.JSX.Element;
542
670
 
543
671
  type BadgeColor = 'gray' | 'red' | 'yellow' | 'lime' | 'green' | 'teal' | 'blue' | 'pink' | 'slate';
544
672
  type BadgeSize = 'sm' | 'lg';
@@ -777,7 +905,7 @@ interface StatusBadgeProps {
777
905
  /** Leading dot. On by default — the Figma status pills all carry one. */
778
906
  dot?: boolean;
779
907
  /**
780
- * Leading glyph, replacing the dot — e.g. `<LuCheck className="size-3" />`.
908
+ * Leading glyph, replacing the dot — e.g. `<CheckIcon className="size-3" />`.
781
909
  * Use for states a colour alone under-states, like verified or rejected.
782
910
  */
783
911
  icon?: ReactNode;
@@ -977,6 +1105,84 @@ interface RadioProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size'
977
1105
  }
978
1106
  declare const Radio: react.ForwardRefExoticComponent<RadioProps & react.RefAttributes<HTMLInputElement>>;
979
1107
 
1108
+ /** Matches `MultiSelectCard`'s sizes, so the single- and multi-select cards line up. */
1109
+ type RadioCardsSize = 'default' | 'sm';
1110
+ interface RadioCardsProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange' | 'defaultValue'> {
1111
+ children: ReactNode;
1112
+ value?: string;
1113
+ defaultValue?: string;
1114
+ onValueChange?: (value: string) => void;
1115
+ /** Shared `name` for the underlying radios, which also submit with a form. Generated when omitted. */
1116
+ name?: string;
1117
+ /** Names the group. Prefer a visible `FieldLegend` in a `FieldSet` when there is one. */
1118
+ label?: string;
1119
+ size?: RadioCardsSize;
1120
+ disabled?: boolean;
1121
+ required?: boolean;
1122
+ }
1123
+ /**
1124
+ * Choose one of a few options shown as cards: a plan, a workspace type, an import source. The
1125
+ * single-select sibling of `MultiSelectCard`, new in 0.7.0 (Radix Themes' `Radio Cards`).
1126
+ *
1127
+ * Each card is a `<label>` around a real `<input type="radio">`, for the same reason
1128
+ * `RadioGroup` uses native radios: arrows move *and* select, only the checked card is a tab
1129
+ * stop, and the group announces "2 of 3", with nothing reimplemented. The card's selected look
1130
+ * is styled from the input's own `:checked` state (`peer-checked:`), so the visual and the
1131
+ * semantics cannot disagree.
1132
+ *
1133
+ * The grid is the caller's: pass layout classes, e.g. `className="sm:grid-cols-3"`.
1134
+ */
1135
+ declare const RadioCards: react.ForwardRefExoticComponent<RadioCardsProps & react.RefAttributes<HTMLDivElement>>;
1136
+ interface RadioCardsItemProps {
1137
+ value: string;
1138
+ title: ReactNode;
1139
+ description?: ReactNode;
1140
+ /** Leading glyph in a tinted box, as on `MultiSelectCard`. */
1141
+ icon?: ReactNode;
1142
+ disabled?: boolean;
1143
+ className?: string;
1144
+ }
1145
+ declare const RadioCardsItem: react.ForwardRefExoticComponent<RadioCardsItemProps & react.RefAttributes<HTMLInputElement>>;
1146
+
1147
+ interface CheckboxGroupProps {
1148
+ children: ReactNode;
1149
+ /** The group's visible name, rendered as the fieldset's `<legend>`. */
1150
+ legend: ReactNode;
1151
+ /** Checked values. Controlled; omit and pass `defaultValue` for uncontrolled. */
1152
+ value?: string[];
1153
+ defaultValue?: string[];
1154
+ onValueChange?: (value: string[]) => void;
1155
+ /** Shared `name`, so every checked value posts with a form. Generated when omitted. */
1156
+ name?: string;
1157
+ size?: CheckboxSize;
1158
+ orientation?: 'vertical' | 'horizontal';
1159
+ disabled?: boolean;
1160
+ /**
1161
+ * At least one option must be checked. While none is, every checkbox carries the native
1162
+ * `required`, so the form will not submit and the browser points at the first one. Checking
1163
+ * any of them lifts it from all. The legend gets
1164
+ * the same marker as a required field label.
1165
+ */
1166
+ required?: boolean;
1167
+ className?: string;
1168
+ }
1169
+ /**
1170
+ * A named set of checkboxes sharing one value array, new in 0.7.0 (Radix Themes'
1171
+ * `Checkbox Group`).
1172
+ *
1173
+ * A real `<fieldset>` and `<legend>`, which is the only markup that announces the group's name
1174
+ * before each option. Each item is the library's native `Checkbox`, so keyboard, form and
1175
+ * validation behaviour are the browser's.
1176
+ */
1177
+ declare const CheckboxGroup: react.ForwardRefExoticComponent<CheckboxGroupProps & react.RefAttributes<HTMLFieldSetElement>>;
1178
+ interface CheckboxGroupItemProps {
1179
+ value: string;
1180
+ label: ReactNode;
1181
+ description?: ReactNode;
1182
+ disabled?: boolean;
1183
+ }
1184
+ declare const CheckboxGroupItem: react.ForwardRefExoticComponent<CheckboxGroupItemProps & react.RefAttributes<HTMLInputElement>>;
1185
+
980
1186
  interface SegmentedControlOption {
981
1187
  value: string;
982
1188
  label: string;
@@ -1079,6 +1285,17 @@ interface CalendarProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onSelect'>
1079
1285
  locale?: string;
1080
1286
  /** Names the grid. Default `Calendar`. */
1081
1287
  label?: string;
1288
+ /**
1289
+ * `label` (default) shows the month as text between the arrows. `dropdown` replaces it with
1290
+ * month and year selects, for dates far from today (a date of birth, a start date years ago),
1291
+ * which would otherwise take a dozen PageUp presses a year to reach. Same name and behaviour
1292
+ * as shadcn/react-day-picker's `captionLayout="dropdown"`. New in 0.7.1.
1293
+ */
1294
+ captionLayout?: 'label' | 'dropdown';
1295
+ /** First year in the year select. Default `min`'s year, else 100 years ago. */
1296
+ startYear?: number;
1297
+ /** Last year in the year select. Default `max`'s year, else 10 years ahead. */
1298
+ endYear?: number;
1082
1299
  }
1083
1300
  /**
1084
1301
  * Month grid. Matches Figma's `Calendar`, `Calendar Button`
@@ -1096,11 +1313,12 @@ interface CalendarProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onSelect'>
1096
1313
  * 42 individually tabbable buttons takes 42 presses to get past.
1097
1314
  * - **Arrows cross month boundaries.** Pressing Left on the 1st moves to the previous
1098
1315
  * month's last day and pages the view, rather than dead-ending.
1099
- * - **PageUp/PageDown** move by month, **Home/End** to the start/end of the week.
1316
+ * - **PageUp/PageDown** move by month, **Shift+PageUp/PageDown** by year, **Home/End** to the
1317
+ * start/end of the week.
1100
1318
  * - Each day's accessible name is the full date, not the number — "14" tells a screen
1101
1319
  * reader user nothing.
1102
1320
  */
1103
- declare function Calendar({ mode, value, range, onSelect, onRangeChange, defaultMonth, min, max, isDateDisabled, weekStartsOn, locale, label, className, ...rest }: CalendarProps): react.JSX.Element;
1321
+ declare function Calendar({ mode, value, range, onSelect, onRangeChange, defaultMonth, min, max, isDateDisabled, weekStartsOn, locale, label, captionLayout, startYear, endYear, className, ...rest }: CalendarProps): react.JSX.Element;
1104
1322
 
1105
1323
  type InputGroupAlign = 'inline-start' | 'inline-end' | 'block-start' | 'block-end';
1106
1324
  interface InputGroupProps extends HTMLAttributes<HTMLDivElement> {
@@ -1174,9 +1392,12 @@ type ModalSize = 'sm' | 'md' | 'lg' | 'xl';
1174
1392
  type ModalTone = 'default' | 'info' | 'positive' | 'warning' | 'danger';
1175
1393
  type ModalFooterAlign = 'start' | 'between' | 'end';
1176
1394
  interface ModalProps {
1177
- open: boolean;
1395
+ /** Controlled open state. Omit it, with `ModalTrigger`, for an uncontrolled dialog. */
1396
+ open?: boolean;
1397
+ /** Initial state when uncontrolled. */
1398
+ defaultOpen?: boolean;
1178
1399
  /** Fired with `false` on Escape, an outside press, or the close button. */
1179
- onOpenChange: (open: boolean) => void;
1400
+ onOpenChange?: (open: boolean) => void;
1180
1401
  /**
1181
1402
  * Accessible name. Only needed when the dialog renders no `ModalTitle` — with one, the
1182
1403
  * name comes from the heading itself via `aria-labelledby`, so it cannot drift.
@@ -1200,6 +1421,11 @@ interface ModalProps {
1200
1421
  onInteractOutside?: (event: PointerEvent) => void;
1201
1422
  /** Focus this on open instead of the first tabbable element. */
1202
1423
  initialFocus?: React.RefObject<HTMLElement | null>;
1424
+ /**
1425
+ * Where to portal the dialog. Defaults to `document.body`. Pass the element the design
1426
+ * tokens are declared on when the app renders inside a shadow root or a scoped theme.
1427
+ */
1428
+ container?: HTMLElement | null;
1203
1429
  }
1204
1430
  /**
1205
1431
  * A centred dialog above `sm`, a bottom sheet below it.
@@ -1208,34 +1434,54 @@ interface ModalProps {
1208
1434
  * parts — so a modal can take any layout a card can, including headerless. Tone lives
1209
1435
  * on `ModalHeader` (the part that draws the glyph); `ConfirmDialog` and
1210
1436
  * `NoteConfirmModal` accept `tone` at their top level and forward it.
1437
+ *
1438
+ * Built on Radix Dialog from 0.7.0. Radix supplies the focus trap, focus return, Escape and
1439
+ * outside-press handling scoped to the topmost layer, scroll lock, and hiding the page behind
1440
+ * the dialog from assistive tech. The 0.6 overlay stack got the last of those wrong when
1441
+ * modals were stacked. Toasts stay reachable: their region is `aria-live`, which Radix leaves
1442
+ * exposed, and pressing one is not treated as an outside press.
1211
1443
  */
1212
- declare function Modal(props: ModalProps): react.JSX.Element | null;
1444
+ declare const Modal: react.ForwardRefExoticComponent<ModalProps & react.RefAttributes<HTMLDivElement>>;
1445
+ interface ModalTriggerProps extends HTMLAttributes<HTMLButtonElement> {
1446
+ /** Render onto the single child (e.g. a `Button`) instead of a bare `<button>`. */
1447
+ asChild?: boolean;
1448
+ }
1449
+ /**
1450
+ * Opens an uncontrolled `Modal`. Place it as a direct child of `Modal`; it renders in place,
1451
+ * not in the dialog. New in 0.7.0. Controlled modals (`open` + `onOpenChange`) do not need it.
1452
+ */
1453
+ declare const ModalTrigger: react.ForwardRefExoticComponent<ModalTriggerProps & react.RefAttributes<HTMLButtonElement>>;
1454
+ interface ModalCloseProps extends HTMLAttributes<HTMLButtonElement> {
1455
+ asChild?: boolean;
1456
+ }
1457
+ /** Closes the enclosing `Modal`, e.g. a footer "Cancel" button. New in 0.7.0. */
1458
+ declare const ModalClose: react.ForwardRefExoticComponent<ModalCloseProps & react.RefAttributes<HTMLButtonElement>>;
1213
1459
  interface ModalHeaderProps extends HTMLAttributes<HTMLDivElement> {
1214
1460
  children: ReactNode;
1215
1461
  /** Adds a tinted glyph circle. `default` renders none. */
1216
1462
  tone?: ModalTone;
1217
1463
  divider?: boolean;
1218
1464
  }
1219
- declare function ModalHeader({ children, tone, divider, className, ...rest }: ModalHeaderProps): react.JSX.Element;
1465
+ declare const ModalHeader: react.ForwardRefExoticComponent<ModalHeaderProps & react.RefAttributes<HTMLDivElement>>;
1220
1466
  interface ModalTitleProps extends HTMLAttributes<HTMLHeadingElement> {
1221
1467
  children: ReactNode;
1222
1468
  }
1223
- declare function ModalTitle({ children, className, id, ...rest }: ModalTitleProps): react.JSX.Element;
1469
+ declare const ModalTitle: react.ForwardRefExoticComponent<ModalTitleProps & react.RefAttributes<HTMLHeadingElement>>;
1224
1470
  interface ModalDescriptionProps extends HTMLAttributes<HTMLParagraphElement> {
1225
1471
  children: ReactNode;
1226
1472
  }
1227
- declare function ModalDescription({ children, className, id, ...rest }: ModalDescriptionProps): react.JSX.Element;
1473
+ declare const ModalDescription: react.ForwardRefExoticComponent<ModalDescriptionProps & react.RefAttributes<HTMLParagraphElement>>;
1228
1474
  interface ModalBodyProps extends HTMLAttributes<HTMLDivElement> {
1229
1475
  children: ReactNode;
1230
1476
  }
1231
1477
  /** Must not carry its own `overflow` — the panel is the scroll container. */
1232
- declare function ModalBody({ children, className, ...rest }: ModalBodyProps): react.JSX.Element;
1478
+ declare const ModalBody: react.ForwardRefExoticComponent<ModalBodyProps & react.RefAttributes<HTMLDivElement>>;
1233
1479
  interface ModalFooterProps extends HTMLAttributes<HTMLDivElement> {
1234
1480
  children: ReactNode;
1235
1481
  align?: ModalFooterAlign;
1236
1482
  divider?: boolean;
1237
1483
  }
1238
- declare function ModalFooter({ children, align, divider, className, ...rest }: ModalFooterProps): react.JSX.Element;
1484
+ declare const ModalFooter: react.ForwardRefExoticComponent<ModalFooterProps & react.RefAttributes<HTMLDivElement>>;
1239
1485
 
1240
1486
  type FloatingSide = 'top' | 'right' | 'bottom' | 'left';
1241
1487
  type FloatingAlign = 'start' | 'center' | 'end';
@@ -1253,9 +1499,13 @@ interface TooltipProps {
1253
1499
  body?: ReactNode;
1254
1500
  side?: FloatingSide;
1255
1501
  align?: FloatingAlign;
1256
- /** Delay before opening, in ms. Default `150`. */
1502
+ /** Delay before opening on hover, in ms. Default `150`. Keyboard focus opens at once. */
1257
1503
  openDelay?: number;
1258
- /** Delay before closing, in ms. Default `0`. */
1504
+ /**
1505
+ * @deprecated Ignored from 0.7.0. The tooltip now stays open while the pointer travels
1506
+ * from the trigger onto it and while it is hovered, as WCAG 1.4.13 requires, which is what
1507
+ * a close delay used to approximate. Remove it from call sites; it will be dropped in 0.8.
1508
+ */
1259
1509
  closeDelay?: number;
1260
1510
  open?: boolean;
1261
1511
  defaultOpen?: boolean;
@@ -1276,18 +1526,21 @@ interface TooltipProps {
1276
1526
  * Tooltip. Matches Figma's `Tooltip` set — `Placement: Top | Left | Right | Bottom`, with
1277
1527
  * a title and an optional body.
1278
1528
  *
1279
- * Things this gets right that a naive tooltip does not:
1529
+ * Built on Radix Tooltip from 0.7.0, which gets right what a naive tooltip does not:
1530
+ *
1531
+ * - **Keyboard and touch reachable.** Opens on keyboard focus as well as hover, and closes
1532
+ * on Escape. A hover-only tooltip is inaccessible to half the people using it.
1533
+ * - **Hoverable (WCAG 1.4.13).** It stays open while the pointer moves onto it, so a
1534
+ * magnifier user can read it. 0.6 closed it the moment the pointer left the trigger.
1535
+ * - **Escape closes only the tooltip.** It goes through the same layer stack as `Modal`, so
1536
+ * dismissing a tooltip inside a dialog no longer closes the dialog too.
1537
+ * - **Referenced, not floating text.** The trigger is `aria-describedby` the tooltip (or
1538
+ * `aria-labelledby` it), so it is announced *with* the control.
1539
+ * - **`role="tooltip"` and no interactive content.** Use `Popover` for anything a user acts on.
1280
1540
  *
1281
- * - **Keyboard and touch reachable.** Opens on `focus` as well as hover, and closes on
1282
- * Escape. A hover-only tooltip is inaccessible to half the people using it.
1283
- * - **Referenced, not floating text.** The panel is wired to the trigger with
1284
- * `aria-describedby` (or `aria-labelledby`), so it is announced *with* the control
1285
- * rather than being an orphan region a screen reader may never reach.
1286
- * - **`role="tooltip"` and no interactive content.** A tooltip cannot be hovered into or
1287
- * focused, so anything interactive inside it is unreachable — use `Popover` for that.
1288
- * - Not modal: no focus trap, no scroll lock, no inert background.
1541
+ * Each tooltip carries its own Radix provider, so there is nothing to mount at the app root.
1289
1542
  */
1290
- declare function Tooltip({ children, title, body, side, align, openDelay, closeDelay, open: openProp, defaultOpen, onOpenChange, association, className, }: TooltipProps): react.JSX.Element | null;
1543
+ declare function Tooltip({ children, title, body, side, align, openDelay, open, defaultOpen, onOpenChange, association, className, }: TooltipProps): react.JSX.Element;
1291
1544
 
1292
1545
  interface PopoverProps {
1293
1546
  children: ReactNode;
@@ -1295,7 +1548,8 @@ interface PopoverProps {
1295
1548
  defaultOpen?: boolean;
1296
1549
  onOpenChange?: (open: boolean) => void;
1297
1550
  /**
1298
- * Trap focus, lock scroll and mark the rest of the page inert. Default `false`.
1551
+ * Trap focus, lock scroll and hide the rest of the page from assistive tech. Default
1552
+ * `false`.
1299
1553
  *
1300
1554
  * A popover is normally non-modal: the page behind stays usable, and Tab moves out of the
1301
1555
  * panel and on through the document. Set `modal` when the panel is a small form whose
@@ -1310,14 +1564,24 @@ interface PopoverProps {
1310
1564
  * into or focused, so anything interactive inside one is unreachable. If the panel holds a
1311
1565
  * link, a button or a field, it has to be a popover — which means a real trigger with
1312
1566
  * `aria-expanded`/`aria-controls`, focus moving into the panel on open, and focus returning
1313
- * to the trigger on close. All of that is here; none of it is in `Tooltip`, by design.
1567
+ * to the trigger on close.
1568
+ *
1569
+ * Built on Radix Popover from 0.7.0. Escape and outside press act on the topmost layer only,
1570
+ * so a popover inside a `Modal` closes without taking the modal with it, and focus leaving a
1571
+ * non-modal panel dismisses it rather than stranding it open.
1314
1572
  */
1315
- declare function Popover({ children, open: openProp, defaultOpen, onOpenChange, modal, }: PopoverProps): react.JSX.Element;
1316
- interface PopoverTriggerProps extends HTMLAttributes<HTMLElement> {
1573
+ declare function Popover({ children, open, defaultOpen, onOpenChange, modal }: PopoverProps): react.JSX.Element;
1574
+ interface PopoverTriggerProps extends HTMLAttributes<HTMLButtonElement> {
1317
1575
  children: ReactNode;
1576
+ /** Render onto the single child (e.g. a `Button`) instead of a bare `<button>`. */
1318
1577
  asChild?: boolean;
1319
1578
  }
1320
- declare function PopoverTrigger({ children, asChild, className, ...rest }: PopoverTriggerProps): react.JSX.Element;
1579
+ /**
1580
+ * Toggles the popover. Radix sets `aria-haspopup="dialog"`, `aria-expanded`,
1581
+ * `aria-controls` and `data-state`, and composes your handlers with its own rather than
1582
+ * replacing them (0.6's `onClick` overrode the toggle).
1583
+ */
1584
+ declare const PopoverTrigger: react.ForwardRefExoticComponent<PopoverTriggerProps & react.RefAttributes<HTMLButtonElement>>;
1321
1585
  interface PopoverContentProps extends HTMLAttributes<HTMLDivElement> {
1322
1586
  children: ReactNode;
1323
1587
  side?: FloatingSide;
@@ -1325,8 +1589,20 @@ interface PopoverContentProps extends HTMLAttributes<HTMLDivElement> {
1325
1589
  sideOffset?: number;
1326
1590
  /** Accessible name for the panel. Falls back to being labelled by the trigger. */
1327
1591
  label?: string;
1592
+ /** Where to portal the panel. Defaults to the enclosing dialog, else `document.body`. */
1593
+ container?: HTMLElement | null;
1594
+ /** Radix's open auto-focus hook: `preventDefault()` and focus something else, e.g. a calendar's selected day. */
1595
+ onOpenAutoFocus?: (event: Event) => void;
1328
1596
  }
1329
- declare function PopoverContent({ children, side, align, sideOffset, label, className, ...rest }: PopoverContentProps): react.JSX.Element | null;
1597
+ declare const PopoverContent: react.ForwardRefExoticComponent<PopoverContentProps & react.RefAttributes<HTMLDivElement>>;
1598
+ /** Closes the enclosing popover, e.g. an "Apply" or "Cancel" button. New in 0.7.0. */
1599
+ declare const PopoverClose: react.ForwardRefExoticComponent<HTMLAttributes<HTMLButtonElement> & {
1600
+ asChild?: boolean;
1601
+ } & react.RefAttributes<HTMLButtonElement>>;
1602
+ /** Positions the panel against an element other than the trigger. New in 0.7.0. */
1603
+ declare const PopoverAnchor: react.ForwardRefExoticComponent<HTMLAttributes<HTMLDivElement> & {
1604
+ asChild?: boolean;
1605
+ } & react.RefAttributes<HTMLDivElement>>;
1330
1606
 
1331
1607
  interface HoverCardProps {
1332
1608
  /** The trigger. Must be a single focusable element — normally a link. */
@@ -1362,17 +1638,20 @@ interface HoverCardProps {
1362
1638
  * reachable here is unreachable on a phone. The panel is `aria-labelledby` the trigger and
1363
1639
  * exposed as a group; the trigger keeps its own name and destination.
1364
1640
  *
1365
- * The close delay is what makes the panel usable: without it, moving the pointer from the
1366
- * trigger to the panel crosses a gap and dismisses the thing you were reaching for.
1641
+ * Built on Radix HoverCard from 0.7.0: the open and close delays, the pointer grace area
1642
+ * between trigger and panel, and Escape through the shared layer stack (so it closes only
1643
+ * the card, not a dialog behind it) come from Radix. The `group` role and the
1644
+ * `aria-describedby` wiring are ours; Radix gives the panel no role at all.
1367
1645
  */
1368
- declare function HoverCard({ children, content, side, align, openDelay, closeDelay, open: openProp, defaultOpen, onOpenChange, className, }: HoverCardProps): react.JSX.Element | null;
1646
+ declare function HoverCard({ children, content, side, align, openDelay, closeDelay, open: openProp, defaultOpen, onOpenChange, className, }: HoverCardProps): react.JSX.Element;
1369
1647
 
1370
1648
  type OverlayItemTone = 'default' | 'danger';
1371
1649
 
1372
1650
  type MenuItemTone = OverlayItemTone;
1373
1651
  interface MenuItemProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onSelect'> {
1374
1652
  children: ReactNode;
1375
- onSelect?: () => void;
1653
+ /** Called on activation. Call `event.preventDefault()` to keep the menu open. */
1654
+ onSelect?: (event: Event) => void;
1376
1655
  tone?: MenuItemTone;
1377
1656
  disabled?: boolean;
1378
1657
  /** Leading glyph. Marked decorative automatically. Matches Figma's `Icon` / `Has Icon`. */
@@ -1384,42 +1663,46 @@ interface MenuItemProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onSelect'>
1384
1663
  /** Typeahead match text, when `children` is not a plain string. */
1385
1664
  textValue?: string;
1386
1665
  }
1387
- declare function MenuItem({ children, onSelect, tone, disabled, icon, description, shortcut, textValue, className, ...rest }: MenuItemProps): react.JSX.Element;
1388
1666
  interface MenuCheckboxItemProps extends Omit<MenuItemProps, 'onSelect' | 'icon'> {
1389
1667
  checked: boolean;
1390
1668
  onCheckedChange?: (checked: boolean) => void;
1391
1669
  }
1392
- declare function MenuCheckboxItem({ children, checked, onCheckedChange, disabled, tone, shortcut, textValue, className, ...rest }: MenuCheckboxItemProps): react.JSX.Element;
1393
1670
  interface MenuRadioGroupProps {
1394
1671
  children: ReactNode;
1395
1672
  value?: string;
1396
1673
  onValueChange?: (value: string) => void;
1397
1674
  }
1398
- declare function MenuRadioGroup({ children, value, onValueChange }: MenuRadioGroupProps): react.JSX.Element;
1399
1675
  interface MenuRadioItemProps extends Omit<MenuItemProps, 'onSelect' | 'icon'> {
1400
1676
  value: string;
1401
1677
  }
1402
- declare function MenuRadioItem({ children, value, disabled, tone, textValue, className, ...rest }: MenuRadioItemProps): react.JSX.Element;
1403
1678
  interface MenuGroupProps extends HTMLAttributes<HTMLDivElement> {
1404
1679
  children: ReactNode;
1405
1680
  /** Names the group. Rendered as a heading when set. */
1406
1681
  label?: string;
1407
1682
  }
1408
- declare function MenuGroup({ children, label, className, ...rest }: MenuGroupProps): react.JSX.Element;
1409
1683
  interface MenuLabelProps extends HTMLAttributes<HTMLDivElement> {
1410
1684
  children: ReactNode;
1411
1685
  }
1412
- /** A non-interactive heading inside the menu. Matches Figma's `Menu Heading`. */
1413
- declare function MenuLabel({ children, className, ...rest }: MenuLabelProps): react.JSX.Element;
1414
1686
  interface MenuSeparatorProps extends HTMLAttributes<HTMLDivElement> {
1415
1687
  }
1416
- /** Matches Figma's `Menu Separator`. Was a bare unlabelled `div` before 0.4.0. */
1417
- declare function MenuSeparator({ className, ...rest }: MenuSeparatorProps): react.JSX.Element;
1418
1688
  interface MenuShortcutProps extends HTMLAttributes<HTMLSpanElement> {
1419
1689
  children: ReactNode;
1420
1690
  }
1421
- /** Trailing keyboard hint, for use outside an item's `shortcut` prop. */
1422
- declare function MenuShortcut({ children, className, ...rest }: MenuShortcutProps): react.JSX.Element;
1691
+ interface MenuSubProps {
1692
+ children: ReactNode;
1693
+ open?: boolean;
1694
+ defaultOpen?: boolean;
1695
+ onOpenChange?: (open: boolean) => void;
1696
+ }
1697
+ interface MenuSubTriggerProps extends HTMLAttributes<HTMLDivElement> {
1698
+ children: ReactNode;
1699
+ icon?: ReactNode;
1700
+ disabled?: boolean;
1701
+ textValue?: string;
1702
+ }
1703
+ interface MenuSubContentProps extends HTMLAttributes<HTMLDivElement> {
1704
+ children: ReactNode;
1705
+ }
1423
1706
 
1424
1707
  interface ContextMenuProps {
1425
1708
  children: ReactNode;
@@ -1428,93 +1711,136 @@ interface ContextMenuProps {
1428
1711
  onOpenChange?: (open: boolean) => void;
1429
1712
  }
1430
1713
  /**
1431
- * Right-click menu.
1714
+ * Right-click menu, built on Radix ContextMenu from 0.7.0.
1432
1715
  *
1433
- * Shares every item and the whole keyboard contract with `DropdownMenu` via `menu-core`;
1716
+ * Shares every item and the whole keyboard contract with `DropdownMenu` (see `menu-core`);
1434
1717
  * the only difference is how it opens — at the pointer, with no trigger element to anchor
1435
- * to, so it is positioned from coordinates rather than by Floating UI's reference/floating
1436
- * pair.
1718
+ * to.
1437
1719
  *
1438
1720
  * **A context menu must never be the only way to reach an action.** `contextmenu` fires on
1439
1721
  * right-click and on the Windows Menu / Shift+F10 keys, but not on touch, and plenty of
1440
1722
  * users never right-click at all. `ContextMenuTrigger` therefore also opens on Shift+F10 and
1441
- * the ContextMenu key, and anything in here should have a visible equivalent elsewhere —
1442
- * usually a `DropdownMenu` on the same row.
1723
+ * the ContextMenu key even where the browser would not, and anything in here should have a
1724
+ * visible equivalent elsewhere — usually a `DropdownMenu` on the same row.
1725
+ *
1726
+ * Radix ContextMenu has no `open` prop (it is opened by the pointer only), so a controlled
1727
+ * `open={false}` closes it, but `open={true}` cannot open it without a position.
1443
1728
  */
1444
- declare function ContextMenu({ children, open: openProp, defaultOpen, onOpenChange, }: ContextMenuProps): react.JSX.Element;
1729
+ declare function ContextMenu({ children, open: openProp, defaultOpen, onOpenChange }: ContextMenuProps): react.JSX.Element;
1445
1730
  interface ContextMenuTriggerProps extends HTMLAttributes<HTMLDivElement> {
1446
1731
  children: ReactNode;
1447
1732
  disabled?: boolean;
1448
1733
  }
1449
- declare function ContextMenuTrigger({ children, disabled, className, ...rest }: ContextMenuTriggerProps): react.JSX.Element;
1734
+ /**
1735
+ * The area that responds to right-click. A wrapper with no tab stop of its own: the keyboard
1736
+ * path is Shift+F10 or the ContextMenu key from whatever inside it has focus.
1737
+ */
1738
+ declare const ContextMenuTrigger: react.ForwardRefExoticComponent<ContextMenuTriggerProps & react.RefAttributes<HTMLDivElement>>;
1450
1739
  interface ContextMenuContentProps extends HTMLAttributes<HTMLDivElement> {
1451
1740
  children: ReactNode;
1452
1741
  /** Minimum gap from the viewport edge, in px. Default `8`. */
1453
1742
  collisionPadding?: number;
1743
+ /** Where to portal the menu. Defaults to the enclosing dialog, else `document.body`. */
1744
+ container?: HTMLElement | null;
1454
1745
  }
1455
- declare function ContextMenuContent({ children, collisionPadding, className, ...rest }: ContextMenuContentProps): react.JSX.Element | null;
1746
+ declare const ContextMenuContent: react.ForwardRefExoticComponent<ContextMenuContentProps & react.RefAttributes<HTMLDivElement>>;
1747
+ declare const ContextMenuItem: react.ForwardRefExoticComponent<MenuItemProps & react.RefAttributes<HTMLDivElement>>;
1748
+ declare const ContextMenuCheckboxItem: react.ForwardRefExoticComponent<MenuCheckboxItemProps & react.RefAttributes<HTMLDivElement>>;
1749
+ declare const ContextMenuRadioGroup: ({ children, value, onValueChange }: MenuRadioGroupProps) => react.JSX.Element;
1750
+ declare const ContextMenuRadioItem: react.ForwardRefExoticComponent<MenuRadioItemProps & react.RefAttributes<HTMLDivElement>>;
1751
+ declare const ContextMenuGroup: react.ForwardRefExoticComponent<MenuGroupProps & react.RefAttributes<HTMLDivElement>>;
1752
+ declare const ContextMenuLabel: react.ForwardRefExoticComponent<MenuLabelProps & react.RefAttributes<HTMLDivElement>>;
1753
+ declare const ContextMenuSeparator: react.ForwardRefExoticComponent<MenuSeparatorProps & react.RefAttributes<HTMLDivElement>>;
1754
+ declare const ContextMenuShortcut: react.ForwardRefExoticComponent<MenuShortcutProps & react.RefAttributes<HTMLSpanElement>>;
1755
+ declare const ContextMenuSub: ({ children, open, defaultOpen, onOpenChange }: MenuSubProps) => react.JSX.Element;
1756
+ declare const ContextMenuSubTrigger: react.ForwardRefExoticComponent<MenuSubTriggerProps & react.RefAttributes<HTMLDivElement>>;
1757
+ declare const ContextMenuSubContent: react.ForwardRefExoticComponent<MenuSubContentProps & react.RefAttributes<HTMLDivElement>>;
1456
1758
 
1457
- interface MenubarProps extends HTMLAttributes<HTMLDivElement> {
1759
+ interface MenubarProps extends Omit<HTMLAttributes<HTMLDivElement>, 'dir' | 'defaultValue'> {
1458
1760
  children: ReactNode;
1459
- /** Names the menubar. Required by the APG. */
1761
+ /** Reading direction, which flips Left/Right along the bar. */
1762
+ dir?: 'ltr' | 'rtl';
1763
+ /** Accessible name for the bar, e.g. "Editor". Required: a menubar is a landmark-like group. */
1460
1764
  label: string;
1765
+ /** The open menu's `value`, controlled. New in 0.7.0. */
1766
+ value?: string;
1767
+ defaultValue?: string;
1768
+ onValueChange?: (value: string) => void;
1461
1769
  }
1462
1770
  /**
1463
- * An application menu bar — a horizontal row of menus, as in a desktop app.
1464
- *
1465
- * Two things distinguish it from a row of `DropdownMenu`s, and both are in the APG:
1466
- *
1467
- * - **The bar is one tab stop.** Left/Right move between the top-level menus; Tab leaves the
1468
- * bar entirely. A row of independent dropdowns is N tab stops.
1469
- * - **Only one menu is open at a time**, and once any is open, moving along the bar switches
1470
- * directly to the next menu rather than closing and reopening.
1771
+ * A persistent horizontal bar of menus, as in a desktop application's File / Edit / View.
1471
1772
  *
1472
- * Items and the vertical keyboard contract come from `menu-core`, shared with
1473
- * `DropdownMenu` and `ContextMenu`.
1773
+ * Built on Radix Menubar from 0.7.0, which supplies the contract: one tab stop for the whole
1774
+ * bar, Left/Right along it, Down/Up into a menu, Left/Right from inside an open menu to its
1775
+ * sibling, and moving the pointer across the bar switching menus once one is open. Items are
1776
+ * the same parts as `DropdownMenu` (see `menu-core`).
1474
1777
  */
1475
- declare function Menubar({ children, label, className, ...rest }: MenubarProps): react.JSX.Element;
1778
+ declare const Menubar: react.ForwardRefExoticComponent<MenubarProps & react.RefAttributes<HTMLDivElement>>;
1476
1779
  interface MenubarMenuProps {
1477
1780
  children: ReactNode;
1478
- /** Identifies this menu within the bar. */
1781
+ /** Identifies the menu within the bar. */
1479
1782
  value: string;
1480
1783
  }
1481
- /** One menu in the bar. Wraps a `MenubarTrigger` and a `MenubarContent`. */
1482
1784
  declare function MenubarMenu({ children, value }: MenubarMenuProps): react.JSX.Element;
1483
1785
  interface MenubarTriggerProps extends HTMLAttributes<HTMLButtonElement> {
1484
1786
  children: ReactNode;
1485
1787
  }
1486
- declare function MenubarTrigger({ children, className, ...rest }: MenubarTriggerProps): react.JSX.Element;
1788
+ declare const MenubarTrigger: react.ForwardRefExoticComponent<MenubarTriggerProps & react.RefAttributes<HTMLButtonElement>>;
1487
1789
  interface MenubarContentProps extends HTMLAttributes<HTMLDivElement> {
1488
1790
  children: ReactNode;
1791
+ /** Where to portal the menu. Defaults to the enclosing dialog, else `document.body`. */
1792
+ container?: HTMLElement | null;
1489
1793
  }
1490
- declare function MenubarContent({ children, className, ...rest }: MenubarContentProps): react.JSX.Element | null;
1794
+ declare const MenubarContent: react.ForwardRefExoticComponent<MenubarContentProps & react.RefAttributes<HTMLDivElement>>;
1795
+ declare const MenubarItem: react.ForwardRefExoticComponent<MenuItemProps & react.RefAttributes<HTMLDivElement>>;
1796
+ declare const MenubarCheckboxItem: react.ForwardRefExoticComponent<MenuCheckboxItemProps & react.RefAttributes<HTMLDivElement>>;
1797
+ declare const MenubarRadioGroup: ({ children, value, onValueChange }: MenuRadioGroupProps) => react.JSX.Element;
1798
+ declare const MenubarRadioItem: react.ForwardRefExoticComponent<MenuRadioItemProps & react.RefAttributes<HTMLDivElement>>;
1799
+ declare const MenubarGroup: react.ForwardRefExoticComponent<MenuGroupProps & react.RefAttributes<HTMLDivElement>>;
1800
+ declare const MenubarLabel: react.ForwardRefExoticComponent<MenuLabelProps & react.RefAttributes<HTMLDivElement>>;
1801
+ declare const MenubarSeparator: react.ForwardRefExoticComponent<MenuSeparatorProps & react.RefAttributes<HTMLDivElement>>;
1802
+ declare const MenubarShortcut: react.ForwardRefExoticComponent<MenuShortcutProps & react.RefAttributes<HTMLSpanElement>>;
1803
+ declare const MenubarSub: ({ children, open, defaultOpen, onOpenChange }: MenuSubProps) => react.JSX.Element;
1804
+ declare const MenubarSubTrigger: react.ForwardRefExoticComponent<MenuSubTriggerProps & react.RefAttributes<HTMLDivElement>>;
1805
+ declare const MenubarSubContent: react.ForwardRefExoticComponent<MenuSubContentProps & react.RefAttributes<HTMLDivElement>>;
1491
1806
 
1492
1807
  type DrawerSide = 'right' | 'left';
1808
+ type DrawerFooterAlign = 'end' | 'between';
1493
1809
  interface DrawerProps {
1494
- open: boolean;
1810
+ /** Controlled open state. Omit it, with `DrawerTrigger`, for an uncontrolled drawer. */
1811
+ open?: boolean;
1812
+ defaultOpen?: boolean;
1495
1813
  /** Fired with `false` on Escape, an outside press, or the close button. */
1496
- onOpenChange: (open: boolean) => void;
1497
- /** Header content (left side). The copies this replaces differ only here — a status badge +
1498
- * title in one, an avatar + title + category in another — so it is a slot, not props. */
1499
- header: ReactNode;
1814
+ onOpenChange?: (open: boolean) => void;
1815
+ /**
1816
+ * Header content (left side). The copies this replaces differ only here — a status badge +
1817
+ * title in one, an avatar + title + category in another — so it is a slot, not props.
1818
+ *
1819
+ * Put a `DrawerTitle` in it and the drawer is named by that heading. Leave `header` out
1820
+ * altogether to compose the panel from `DrawerHeader` / `DrawerBody` / `DrawerFooter`.
1821
+ */
1822
+ header?: ReactNode;
1500
1823
  children: ReactNode;
1824
+ /** Footer content, with the `header` layout. Composed drawers use `DrawerFooter`. */
1501
1825
  footer?: ReactNode;
1502
1826
  /** `between` when the footer has a left-aligned secondary action. */
1503
- footerAlign?: 'end' | 'between';
1504
- /** Panel width. Defaults to the `w-[440px] max-w-[90vw]` shared by every existing drawer. */
1827
+ footerAlign?: DrawerFooterAlign;
1828
+ /**
1829
+ * Panel width. Defaults to the `w-[440px] max-w-[90vw]` shared by every existing drawer.
1830
+ * `className` is merged with `cn` from 0.7.0, so a width there works too.
1831
+ */
1505
1832
  width?: string;
1506
1833
  /** Which edge the panel slides in from. Default `right`. */
1507
1834
  side?: DrawerSide;
1508
1835
  /**
1509
- * Accessible name for the dialog. **Required** as of 0.4.0.
1836
+ * Accessible name, for a drawer that renders no `DrawerTitle`.
1510
1837
  *
1511
- * It was optional through 0.3.0 while `Modal.label` was required, which meant the
1512
- * public API allowed a `role="dialog" aria-modal="true"` element with no accessible
1513
- * name at all — a screen reader announced "dialog" and nothing else. Unlike `Modal`
1514
- * there is no `DrawerTitle` part to infer a name from, because `header` is a free
1515
- * slot, so the string is the only place it can come from.
1838
+ * Required from 0.4.0 to 0.6, because a free `header` slot gave the name nowhere else
1839
+ * to come from. From 0.7.0 a `DrawerTitle` anywhere in the drawer names it by reference,
1840
+ * the way `ModalTitle` names a `Modal`, so `label` is only needed without one. With
1841
+ * neither, Radix warns in development.
1516
1842
  */
1517
- label: string;
1843
+ label?: string;
1518
1844
  className?: string;
1519
1845
  /** Call `preventDefault()` to keep the drawer open — e.g. unsaved input. */
1520
1846
  onEscapeKeyDown?: (event: KeyboardEvent) => void;
@@ -1522,12 +1848,66 @@ interface DrawerProps {
1522
1848
  onInteractOutside?: (event: PointerEvent) => void;
1523
1849
  /** Focus this on open instead of the first tabbable element. */
1524
1850
  initialFocus?: RefObject<HTMLElement | null>;
1851
+ /** Where to portal the drawer. Defaults to `document.body`. */
1852
+ container?: HTMLElement | null;
1525
1853
  }
1526
1854
  /**
1527
- * Side panel. Handles Esc, traps Tab focus, locks background scroll, marks the rest of
1528
- * the page inert, and restores focus to the trigger on close.
1855
+ * Side panel, built on Radix Dialog from 0.7.0. Radix handles Escape, the focus trap,
1856
+ * scroll lock, hiding the page from assistive tech, and returning focus on close.
1857
+ *
1858
+ * Two ways to fill it:
1859
+ *
1860
+ * // Slots: the layout every 0.6 drawer used.
1861
+ * <Drawer open={open} onOpenChange={setOpen}
1862
+ * header={<DrawerTitle>Supplier</DrawerTitle>} footer={<Button>Save</Button>}>
1863
+ * …body…
1864
+ * </Drawer>
1865
+ *
1866
+ * // Parts: for a header with a description, or a body that is not one scroll region.
1867
+ * <Drawer open={open} onOpenChange={setOpen}>
1868
+ * <DrawerHeader><DrawerTitle>Supplier</DrawerTitle><DrawerDescription>…</DrawerDescription></DrawerHeader>
1869
+ * <DrawerBody>…</DrawerBody>
1870
+ * <DrawerFooter><Button>Save</Button></DrawerFooter>
1871
+ * </Drawer>
1529
1872
  */
1530
- declare function Drawer(props: DrawerProps): react.JSX.Element | null;
1873
+ declare const Drawer: react.ForwardRefExoticComponent<DrawerProps & react.RefAttributes<HTMLDivElement>>;
1874
+ interface DrawerTriggerProps extends HTMLAttributes<HTMLButtonElement> {
1875
+ asChild?: boolean;
1876
+ }
1877
+ /** Opens an uncontrolled `Drawer`. A direct child of `Drawer`; it renders in place. */
1878
+ declare const DrawerTrigger: react.ForwardRefExoticComponent<DrawerTriggerProps & react.RefAttributes<HTMLButtonElement>>;
1879
+ interface DrawerCloseProps extends HTMLAttributes<HTMLButtonElement> {
1880
+ asChild?: boolean;
1881
+ }
1882
+ /** Closes the enclosing `Drawer`, e.g. a footer "Cancel" button. */
1883
+ declare const DrawerClose: react.ForwardRefExoticComponent<DrawerCloseProps & react.RefAttributes<HTMLButtonElement>>;
1884
+ interface DrawerHeaderProps extends HTMLAttributes<HTMLDivElement> {
1885
+ /** Renders the close button at the end of the header row. Default `true`. */
1886
+ showClose?: boolean;
1887
+ }
1888
+ /** The header row, with the close button. The `header` slot renders inside one of these. */
1889
+ declare const DrawerHeader: react.ForwardRefExoticComponent<DrawerHeaderProps & react.RefAttributes<HTMLDivElement>>;
1890
+ interface DrawerTitleProps extends HTMLAttributes<HTMLHeadingElement> {
1891
+ }
1892
+ /** Names the drawer (`aria-labelledby`). Use it inside the `header` slot or `DrawerHeader`. */
1893
+ declare const DrawerTitle: react.ForwardRefExoticComponent<DrawerTitleProps & react.RefAttributes<HTMLHeadingElement>>;
1894
+ interface DrawerDescriptionProps extends HTMLAttributes<HTMLParagraphElement> {
1895
+ }
1896
+ /** Describes the drawer (`aria-describedby`). */
1897
+ declare const DrawerDescription: react.ForwardRefExoticComponent<DrawerDescriptionProps & react.RefAttributes<HTMLParagraphElement>>;
1898
+ interface DrawerBodyProps extends HTMLAttributes<HTMLDivElement> {
1899
+ /**
1900
+ * Accessible name for the scroll region, which becomes focusable when it overflows.
1901
+ * Defaults to "Content". It is not the drawer's own name, which would be announced twice.
1902
+ */
1903
+ label?: string;
1904
+ }
1905
+ /** The scrolling body. It fills the space between header and footer. */
1906
+ declare const DrawerBody: react.ForwardRefExoticComponent<DrawerBodyProps & react.RefAttributes<HTMLDivElement>>;
1907
+ interface DrawerFooterProps extends HTMLAttributes<HTMLDivElement> {
1908
+ align?: DrawerFooterAlign;
1909
+ }
1910
+ declare const DrawerFooter: react.ForwardRefExoticComponent<DrawerFooterProps & react.RefAttributes<HTMLDivElement>>;
1531
1911
 
1532
1912
  interface ConfirmDialogProps {
1533
1913
  open: boolean;
@@ -1543,7 +1923,12 @@ interface ConfirmDialogProps {
1543
1923
  confirmLabel?: string;
1544
1924
  cancelLabel?: string;
1545
1925
  confirmVariant?: 'primary' | 'danger';
1546
- /** Disables the confirm button and swaps its label — the double-submit guard. */
1926
+ /**
1927
+ * The double-submit guard. While true, the confirm button shows a spinner and its
1928
+ * `confirmingLabel`, and ignores presses while keeping focus. The dialog also cannot be
1929
+ * dismissed (Escape, outside press, Cancel, the close button), so a request in flight
1930
+ * cannot lose the dialog that is waiting on it.
1931
+ */
1547
1932
  isConfirming?: boolean;
1548
1933
  /** Label shown on the confirm button while `isConfirming`. */
1549
1934
  confirmingLabel?: string;
@@ -1562,6 +1947,10 @@ interface ConfirmDialogProps {
1562
1947
  * just layout — the `isConfirming` guard that disables the button and swaps its label
1563
1948
  * is the thing call sites get wrong when they hand-roll a confirm. For any other
1564
1949
  * shape, compose `Modal` and its parts directly.
1950
+ *
1951
+ * Focus opens on **Cancel**, the least destructive action, as the WAI-ARIA alert dialog
1952
+ * pattern recommends. Through 0.6 it opened on the close button, one Tab away from
1953
+ * "Delete".
1565
1954
  */
1566
1955
  declare function ConfirmDialog({ open, title, subtitle, tone, size, confirmLabel, cancelLabel, confirmVariant, isConfirming, confirmingLabel, children, className, onConfirm, onOpenChange, }: ConfirmDialogProps): react.JSX.Element;
1567
1956
 
@@ -1577,7 +1966,10 @@ interface NoteConfirmModalProps {
1577
1966
  /** Block confirmation until the note has content. */
1578
1967
  requireNote?: boolean;
1579
1968
  notePlaceholder?: string;
1969
+ /** Accessible name of the note field. The placeholder is not a label. Defaults to "Note". */
1970
+ noteLabel?: string;
1580
1971
  submittingLabel?: string;
1972
+ /** Shows a spinner on confirm and keeps the dialog from being dismissed mid-request. */
1581
1973
  isSubmitting?: boolean;
1582
1974
  className?: string;
1583
1975
  /** Fired with `false` on cancel, Escape, or an outside press. */
@@ -1598,24 +1990,19 @@ interface NoteConfirmModalProps {
1598
1990
  declare function NoteConfirmModal({ open, ...rest }: NoteConfirmModalProps): react.JSX.Element | null;
1599
1991
 
1600
1992
  /**
1601
- * Overflow / row-actions menu, rebuilt in 0.4.0.
1602
- *
1603
- * The previous version declared `role="menu"` and `role="menuitem"` and implemented none of
1604
- * the WAI-ARIA menu contract. Announcing a pattern you do not implement is worse than
1605
- * announcing nothing, because a screen reader tells the user which keys should work. Fixed:
1606
- * arrow keys, Home/End and typeahead; a roving tabindex (every item used to be a natively
1607
- * tabbable `<button>`, so Tab walked all of them); focus moving into the menu on open and
1608
- * back to the trigger on close; a portal, so the panel is no longer clipped by `Card`'s
1609
- * `overflow-hidden` or `DataTable`'s `overflow-x-auto` — both named in its own doc comment
1610
- * as the reason it exists; collision handling instead of a static `left`/`right`; correct
1611
- * ARIA ownership; and `open`/`onOpenChange`, where open state used to be unreachable.
1612
- *
1613
- * The items and keyboard model now live in `menu-core`, shared with `ContextMenu` and
1614
- * `Menubar`.
1615
- *
1616
- * Not implemented: submenus. Doing them properly needs hover intent and a safe-travel
1617
- * polygon between trigger and panel, and a half-built version is worse than none — nest a
1618
- * second `DropdownMenu` in the meantime.
1993
+ * Overflow / row-actions menu.
1994
+ *
1995
+ * 0.4.0 rebuilt it to the WAI-ARIA menu contract after a version that declared the roles
1996
+ * and implemented none of the keys. 0.7.0 moves that contract onto Radix DropdownMenu, which
1997
+ * also brings submenus (`DropdownMenuSub`), the one thing 0.4.0 deliberately left out because
1998
+ * a half-built safe-travel path is worse than none.
1999
+ *
2000
+ * Kept from ours, on top of Radix:
2001
+ * - **ArrowUp on the trigger opens on the last item**, as the APG describes.
2002
+ * - **Tab closes the menu** so focus moves on through the page; Radix keeps Tab inside.
2003
+ * - **It works inside a clickable table row.** Presses on the trigger and in the panel stop
2004
+ * short of the row, the behaviour 0.2.0's `RowMenu` existed for.
2005
+ * - **Non-modal by default.** The page behind stays readable and interactive.
1619
2006
  */
1620
2007
  interface DropdownMenuProps {
1621
2008
  children: ReactNode;
@@ -1623,28 +2010,104 @@ interface DropdownMenuProps {
1623
2010
  open?: boolean;
1624
2011
  defaultOpen?: boolean;
1625
2012
  onOpenChange?: (open: boolean) => void;
2013
+ /**
2014
+ * Block the page while open (Radix's default). Default `false`, matching 0.6: a menu is
2015
+ * not a dialog, and the page behind it stays usable.
2016
+ */
2017
+ modal?: boolean;
1626
2018
  }
1627
- declare function DropdownMenu({ children, open: openProp, defaultOpen, onOpenChange, }: DropdownMenuProps): react.JSX.Element;
1628
- interface DropdownMenuTriggerProps extends HTMLAttributes<HTMLElement> {
2019
+ declare function DropdownMenu({ children, open: openProp, defaultOpen, onOpenChange, modal, }: DropdownMenuProps): react.JSX.Element;
2020
+ interface DropdownMenuTriggerProps extends HTMLAttributes<HTMLButtonElement> {
1629
2021
  children?: ReactNode;
1630
2022
  /** Render the child element instead of the default overflow button. */
1631
2023
  asChild?: boolean;
1632
2024
  /** Accessible name for the default `⋯` button. Ignored when `asChild` is set. */
1633
2025
  label?: string;
1634
2026
  }
1635
- declare function DropdownMenuTrigger({ children, asChild, label, ...rest }: DropdownMenuTriggerProps): react.JSX.Element;
2027
+ declare const DropdownMenuTrigger: react.ForwardRefExoticComponent<DropdownMenuTriggerProps & react.RefAttributes<HTMLButtonElement>>;
1636
2028
  interface DropdownMenuContentProps extends HTMLAttributes<HTMLDivElement> {
1637
2029
  children: ReactNode;
1638
2030
  side?: FloatingSide;
1639
2031
  align?: FloatingAlign;
1640
2032
  sideOffset?: number;
2033
+ /** Where to portal the menu. Defaults to the enclosing dialog, else `document.body`. */
2034
+ container?: HTMLElement | null;
2035
+ /** Called when focus returns on close. Call `preventDefault()` to stop it moving to the trigger. */
2036
+ onCloseAutoFocus?: (event: Event) => void;
2037
+ }
2038
+ declare const DropdownMenuContent: react.ForwardRefExoticComponent<DropdownMenuContentProps & react.RefAttributes<HTMLDivElement>>;
2039
+ declare const DropdownMenuItem: react.ForwardRefExoticComponent<MenuItemProps & react.RefAttributes<HTMLDivElement>>;
2040
+ declare const DropdownMenuCheckboxItem: react.ForwardRefExoticComponent<MenuCheckboxItemProps & react.RefAttributes<HTMLDivElement>>;
2041
+ declare const DropdownMenuRadioGroup: ({ children, value, onValueChange }: MenuRadioGroupProps) => react.JSX.Element;
2042
+ declare const DropdownMenuRadioItem: react.ForwardRefExoticComponent<MenuRadioItemProps & react.RefAttributes<HTMLDivElement>>;
2043
+ declare const DropdownMenuGroup: react.ForwardRefExoticComponent<MenuGroupProps & react.RefAttributes<HTMLDivElement>>;
2044
+ declare const DropdownMenuLabel: react.ForwardRefExoticComponent<MenuLabelProps & react.RefAttributes<HTMLDivElement>>;
2045
+ declare const DropdownMenuSeparator: react.ForwardRefExoticComponent<MenuSeparatorProps & react.RefAttributes<HTMLDivElement>>;
2046
+ declare const DropdownMenuShortcut: react.ForwardRefExoticComponent<MenuShortcutProps & react.RefAttributes<HTMLSpanElement>>;
2047
+ declare const DropdownMenuSub: ({ children, open, defaultOpen, onOpenChange }: MenuSubProps) => react.JSX.Element;
2048
+ declare const DropdownMenuSubTrigger: react.ForwardRefExoticComponent<MenuSubTriggerProps & react.RefAttributes<HTMLDivElement>>;
2049
+ declare const DropdownMenuSubContent: react.ForwardRefExoticComponent<MenuSubContentProps & react.RefAttributes<HTMLDivElement>>;
2050
+
2051
+ interface ScrimProps {
2052
+ /** Dismiss the overlay this scrim sits behind. */
2053
+ onClose?: () => void;
2054
+ /**
2055
+ * Accessible name. With one, the scrim is a real `<button>`, which it must be when clicking it
2056
+ * is the *only* pointer route out. Without one it is `aria-hidden` decoration, and the overlay
2057
+ * must offer another exit (a close button, Escape).
2058
+ */
2059
+ label?: string;
2060
+ /** `absolute` when the scrim sits inside a wrapper that is already positioned. */
2061
+ position?: 'fixed' | 'absolute';
2062
+ /**
2063
+ * Fade instead of mounting and unmounting, for a panel that slides in and out. While closed
2064
+ * the scrim stops taking pointer events; an always-mounted scrim that kept them would silently
2065
+ * eat every click on the page. Set as `data-state`.
2066
+ */
2067
+ open?: boolean;
2068
+ /** Stacking and breakpoint gating, e.g. `z-overlay lg:hidden`. */
2069
+ className?: string;
2070
+ }
2071
+ /**
2072
+ * The dimming layer behind an overlay, for overlays `Modal` and `Drawer` do not cover (a
2073
+ * non-modal side panel, a mobile nav). New in 0.7.0, from SCIC. It exists so "I need a scrim"
2074
+ * never again means hand-writing `fixed inset-0 bg-black/40`, which is how SCIC ended up with
2075
+ * three scrim colours. The colour comes from `OVERLAY_SCRIM`.
2076
+ */
2077
+ declare function Scrim({ onClose, label, position, open, className }: ScrimProps): react.JSX.Element;
2078
+
2079
+ /**
2080
+ * `base` (the default) sits on the overlay layer, so a dialog opened from inside it appears above
2081
+ * it. `elevated` sits above another surface, e.g. a widget preview opened from a full-screen
2082
+ * dashboard. SCIC defaulted to `elevated`.
2083
+ */
2084
+ type FullscreenStacking = 'base' | 'elevated';
2085
+ interface FullscreenSurfaceProps {
2086
+ /** Called on Escape and on the close button. The surface renders while mounted. */
2087
+ onClose: () => void;
2088
+ /** Accessible name of the surface, e.g. "Supply risk dashboard". */
2089
+ label: string;
2090
+ /** Text on the close button. Default "Close". */
2091
+ closeLabel?: string;
2092
+ stacking?: FullscreenStacking;
2093
+ children: ReactNode;
2094
+ className?: string;
1641
2095
  }
1642
- declare function DropdownMenuContent({ children, side, align, sideOffset, className, ...rest }: DropdownMenuContentProps): react.JSX.Element | null;
2096
+ /**
2097
+ * An opaque, scrollable surface that fills the viewport, with a close button: "full screen" and
2098
+ * "expand this widget". New in 0.7.0, from SCIC.
2099
+ *
2100
+ * No scrim, because nothing behind it is visible. But it *is* modal: SCIC's version left the page
2101
+ * underneath in the tab order, so Tab walked into content covered by the surface. Built on Radix
2102
+ * Dialog, it traps focus, hides the page from assistive tech, returns focus on close, and takes
2103
+ * Escape through the shared layer stack, so a dialog opened on top closes first.
2104
+ */
2105
+ declare function FullscreenSurface({ onClose, label, closeLabel, stacking, children, className, }: FullscreenSurfaceProps): react.JSX.Element;
1643
2106
 
1644
2107
  interface PortalProps {
1645
2108
  children: ReactNode;
1646
2109
  /**
1647
- * Where to mount. Defaults to `document.body`.
2110
+ * Where to mount. Defaults to the nearest `PortalContainerProvider`, else `document.body`.
1648
2111
  *
1649
2112
  * Pass a container when the app renders inside a shadow root or a scoped theme
1650
2113
  * wrapper — the portal must stay inside whatever element the design tokens are
@@ -1652,6 +2115,12 @@ interface PortalProps {
1652
2115
  */
1653
2116
  container?: HTMLElement | null;
1654
2117
  }
2118
+ declare function PortalContainerProvider({ container, children, }: {
2119
+ container: HTMLElement | null;
2120
+ children: ReactNode;
2121
+ }): react.JSX.Element;
2122
+ /** The container a `Portal` here would mount into, for Radix parts that take `container`. */
2123
+ declare function usePortalContainer(): HTMLElement | null;
1655
2124
  /**
1656
2125
  * Renders `children` outside the parent DOM hierarchy.
1657
2126
  *
@@ -1770,6 +2239,99 @@ declare function useOverlayDismiss({ onDismiss, panelRef, active, closeOnEscape,
1770
2239
  */
1771
2240
  declare function cn(...inputs: ClassValue[]): string;
1772
2241
 
2242
+ /**
2243
+ * `Slot` renders its own props onto its single child element instead of emitting a
2244
+ * wrapper of its own. It is what makes `asChild` work.
2245
+ *
2246
+ * Why the library needs it: before 0.4.0 there was no way to render a `Button` as a
2247
+ * router `<Link>`, or to use any component as a tooltip/popover anchor, because every
2248
+ * component hardcoded its host element. The usual workaround — a `component`/`as` prop —
2249
+ * multiplies generics across the whole surface and still cannot forward a ref through
2250
+ * two levels. Delegating to the child instead keeps the type surface flat.
2251
+ *
2252
+ * <Button asChild><Link to="/x">Go</Link></Button>
2253
+ *
2254
+ * Merge rules, in order of who wins:
2255
+ * - `className` — concatenated, slot first, so the child's classes come last
2256
+ * - `style` — shallow-merged, child wins on conflicting keys
2257
+ * - `on*` — both run, slot's handler first; the child's runs even if the slot's
2258
+ * called `preventDefault`, matching normal DOM listener behaviour
2259
+ * - everything else — child wins, so a child's explicit `type` or `role` is never
2260
+ * clobbered by a default the slot happens to carry
2261
+ */
2262
+ interface SlotProps extends HTMLAttributes<HTMLElement> {
2263
+ /** The single element to merge into. */
2264
+ children?: ReactNode;
2265
+ /**
2266
+ * Rebuilds the child's children, so a component that decorates its content can keep
2267
+ * doing so through `asChild`.
2268
+ *
2269
+ * `Button` renders `leadingIcon`, a padded label span and `trailingIcon` around whatever
2270
+ * it is given. Without this, `<Button asChild><Link>Go</Link></Button>` would either drop
2271
+ * the icons (cloning the Link untouched) or drop "Go" (replacing the Link's children
2272
+ * outright). It receives the child's own children — "Go" — and returns the decorated
2273
+ * tree to place inside the child.
2274
+ */
2275
+ wrapChildren?: (childChildren: ReactNode) => ReactNode;
2276
+ }
2277
+ declare const Slot: react.ForwardRefExoticComponent<SlotProps & react.RefAttributes<HTMLElement>>;
2278
+ /** Fan one node out to several refs, callback or object. */
2279
+ declare function composeRefs<T>(...refs: (Ref<T> | undefined)[]): (node: T | null) => void;
2280
+
2281
+ /**
2282
+ * The keyboard focus ring, as one string, so every control draws the same one.
2283
+ *
2284
+ * Before 0.7.0 this exact class list was written out by hand in 18 places, with six
2285
+ * near-misses beside it (a missing offset colour, `ring-offset-2`). Use it in new and migrated
2286
+ * components rather than re-typing it.
2287
+ *
2288
+ * `FOCUS_RING` sits outside the element and needs room around it. Inside a scrolling or
2289
+ * `overflow-hidden` panel, such as a menu, a listbox or a table cell, the offset ring is clipped,
2290
+ * so items there use `FOCUS_RING_INSET`, which draws inside the element's own box.
2291
+ *
2292
+ * Highlight is not focus: menu and option items also tint their background when highlighted
2293
+ * (by pointer or by keyboard), but the tint alone does not meet WCAG 2.4.7 next to a hovered
2294
+ * sibling with the same tint. The ring is what marks the keyboard position.
2295
+ */
2296
+ declare const FOCUS_RING = "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-brand focus-visible:ring-offset-1 focus-visible:ring-offset-default";
2297
+ declare const FOCUS_RING_INSET = "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-brand";
2298
+
2299
+ interface VisuallyHiddenProps extends HTMLAttributes<HTMLSpanElement> {
2300
+ /** Render the hiding styles onto the single child element instead of a `<span>`. */
2301
+ asChild?: boolean;
2302
+ }
2303
+ /**
2304
+ * Content that screen readers announce and nobody sees: a dialog title the design does
2305
+ * not show, a "(opens in new tab)" suffix, the label of an icon-only control.
2306
+ *
2307
+ * Tailwind's `sr-only` does the same job in markup the library owns, and nine components still
2308
+ * use it. This is for the call site, where a component is clearer than a utility class and
2309
+ * survives a `className` override that would otherwise drop `sr-only` along with the rest.
2310
+ */
2311
+ declare const VisuallyHidden: react.ForwardRefExoticComponent<VisuallyHiddenProps & react.RefAttributes<HTMLSpanElement>>;
2312
+
2313
+ interface AccessibleIconProps {
2314
+ /** The icon. A single element; it is hidden from assistive technology. */
2315
+ children: ReactElement;
2316
+ /** What the icon means. It is announced in place of the icon. */
2317
+ label: string;
2318
+ }
2319
+ /**
2320
+ * An icon that carries meaning on its own, with no visible text beside it: a "verified" tick
2321
+ * in a table cell, a warning glyph standing in for a status word.
2322
+ *
2323
+ * Icons are decorative by default (`lucide-react` hides them, and so does the library wherever
2324
+ * it renders one for you). That is right beside a label and wrong here, where the icon *is*
2325
+ * the information. This hides the SVG and adds the label as visually hidden text, which reads
2326
+ * reliably in every screen reader, unlike `aria-label` on an `<svg>`.
2327
+ *
2328
+ * Inside a button, use `IconButton` with `aria-label` instead: the name belongs to the control,
2329
+ * not to the glyph.
2330
+ *
2331
+ * <AccessibleIcon label="Verified"><CircleCheckBigIcon className="size-4" /></AccessibleIcon>
2332
+ */
2333
+ declare function AccessibleIcon({ children, label }: AccessibleIconProps): react.JSX.Element;
2334
+
1773
2335
  type CardSize = 'sm' | 'md' | 'lg';
1774
2336
  type CardRadius = 'lg' | 'xl' | '2xl';
1775
2337
  type CardTone = 'default' | 'brand' | 'positive' | 'warning' | 'danger';
@@ -1850,7 +2412,7 @@ interface CardFooterProps extends HTMLAttributes<HTMLDivElement> {
1850
2412
  declare function CardFooter({ children, size, divider, align, className, ...rest }: CardFooterProps): react.JSX.Element;
1851
2413
 
1852
2414
  type AccordionType = 'single' | 'multiple';
1853
- interface AccordionProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange'> {
2415
+ interface AccordionProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange' | 'defaultValue' | 'dir'> {
1854
2416
  children: ReactNode;
1855
2417
  /** `single` closes the open item when another opens. Default `single`. */
1856
2418
  type?: AccordionType;
@@ -1868,6 +2430,7 @@ interface AccordionProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange'
1868
2430
  * right level depends on what surrounds it, which only the caller knows.
1869
2431
  */
1870
2432
  headingLevel?: 2 | 3 | 4;
2433
+ disabled?: boolean;
1871
2434
  }
1872
2435
  /**
1873
2436
  * Accordion. Matches Figma's `Accordion` / `Accordion Item` (`State: Closed | Open`).
@@ -1875,24 +2438,34 @@ interface AccordionProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange'
1875
2438
  * Width is deliberately not set — Figma's own note on `Accordion Item` says the 640px in
1876
2439
  * the component set is a container artefact and the parent should own width, so this is
1877
2440
  * `w-full` and nothing more.
2441
+ *
2442
+ * Built on Radix Accordion from 0.7.0. The contract is unchanged: real headings, triggers with
2443
+ * `aria-expanded` / `aria-controls`, labelled `region` panels, Up/Down/Home/End between
2444
+ * triggers, and closed panels unmounted so they are not tabbable. New: your handlers on the
2445
+ * trigger compose with the toggle, every part forwards its ref, each part carries
2446
+ * `data-state`, and open content exposes `--radix-accordion-content-height` for animation.
1878
2447
  */
1879
- declare function Accordion({ children, type, value: valueProp, defaultValue, onValueChange, collapsible, headingLevel, className, ...rest }: AccordionProps): react.JSX.Element;
2448
+ declare const Accordion: react.ForwardRefExoticComponent<AccordionProps & react.RefAttributes<HTMLDivElement>>;
1880
2449
  interface AccordionItemProps extends HTMLAttributes<HTMLDivElement> {
1881
2450
  children: ReactNode;
1882
2451
  value: string;
1883
2452
  disabled?: boolean;
1884
2453
  }
1885
- declare function AccordionItem({ children, value, disabled, className, ...rest }: AccordionItemProps): react.JSX.Element;
2454
+ declare const AccordionItem: react.ForwardRefExoticComponent<AccordionItemProps & react.RefAttributes<HTMLDivElement>>;
1886
2455
  interface AccordionTriggerProps extends HTMLAttributes<HTMLButtonElement> {
1887
2456
  children: ReactNode;
1888
2457
  /** Hide the chevron — for a trigger that supplies its own affordance. */
1889
2458
  hideIndicator?: boolean;
1890
2459
  }
1891
- declare function AccordionTrigger({ children, hideIndicator, className, ...rest }: AccordionTriggerProps): react.JSX.Element;
2460
+ declare const AccordionTrigger: react.ForwardRefExoticComponent<AccordionTriggerProps & react.RefAttributes<HTMLButtonElement>>;
1892
2461
  interface AccordionContentProps extends HTMLAttributes<HTMLDivElement> {
1893
2462
  children: ReactNode;
1894
2463
  }
1895
- declare function AccordionContent({ children, className, ...rest }: AccordionContentProps): react.JSX.Element | null;
2464
+ /**
2465
+ * Unmounted while closed rather than height-collapsed: a `height: 0` panel keeps its content
2466
+ * focusable and announceable, so keyboard users would tab into a closed section.
2467
+ */
2468
+ declare const AccordionContent: react.ForwardRefExoticComponent<AccordionContentProps & react.RefAttributes<HTMLDivElement>>;
1896
2469
 
1897
2470
  interface CollapsibleProps extends HTMLAttributes<HTMLDivElement> {
1898
2471
  children: ReactNode;
@@ -1909,13 +2482,18 @@ interface CollapsibleProps extends HTMLAttributes<HTMLDivElement> {
1909
2482
  * `aria-labelledby`, and the panel must be genuinely removed from the accessibility tree
1910
2483
  * when closed — `height: 0` with `overflow: hidden` leaves its content focusable and
1911
2484
  * announceable, so a keyboard user tabs into a collapsed section.
2485
+ *
2486
+ * Built on Radix Collapsible from 0.7.0: your `onClick` on the trigger now runs alongside the
2487
+ * toggle instead of replacing it, every part forwards its ref, and the open content exposes
2488
+ * `--radix-collapsible-content-height` for a height animation. Each part carries
2489
+ * `data-state="open" | "closed"`.
1912
2490
  */
1913
- declare function Collapsible({ children, open: openProp, defaultOpen, onOpenChange, disabled, className, ...rest }: CollapsibleProps): react.JSX.Element;
2491
+ declare const Collapsible: react.ForwardRefExoticComponent<CollapsibleProps & react.RefAttributes<HTMLDivElement>>;
1914
2492
  interface CollapsibleTriggerProps extends HTMLAttributes<HTMLButtonElement> {
1915
2493
  children?: ReactNode;
1916
2494
  asChild?: boolean;
1917
2495
  }
1918
- declare function CollapsibleTrigger({ children, asChild, className, ...rest }: CollapsibleTriggerProps): react.JSX.Element;
2496
+ declare const CollapsibleTrigger: react.ForwardRefExoticComponent<CollapsibleTriggerProps & react.RefAttributes<HTMLButtonElement>>;
1919
2497
  interface CollapsibleContentProps extends HTMLAttributes<HTMLDivElement> {
1920
2498
  children: ReactNode;
1921
2499
  /**
@@ -1927,7 +2505,92 @@ interface CollapsibleContentProps extends HTMLAttributes<HTMLDivElement> {
1927
2505
  */
1928
2506
  keepMounted?: boolean;
1929
2507
  }
1930
- declare function CollapsibleContent({ children, keepMounted, className, ...rest }: CollapsibleContentProps): react.JSX.Element | null;
2508
+ declare const CollapsibleContent: react.ForwardRefExoticComponent<CollapsibleContentProps & react.RefAttributes<HTMLDivElement>>;
2509
+
2510
+ /**
2511
+ * Layout primitives, new in 0.7.0: `Box`, `Flex`, `Grid`, `Container` and `Section`, the Radix
2512
+ * Themes layout set.
2513
+ *
2514
+ * Each is a thin, typed wrapper over the Tailwind utilities a page would otherwise hand-write.
2515
+ * Spacing props take the Figma spacing tokens by name (`gap="400"` is 16px), so layout uses the
2516
+ * same scale as the components inside it and an arbitrary `gap-[13px]` has nowhere to go. All of
2517
+ * them take `asChild` to lay out an element of your own (a `<ul>`, a `<form>`, a `<main>`) and
2518
+ * merge `className` with `cn`, so a class you pass wins.
2519
+ *
2520
+ * The class maps below are written out literally on purpose: Tailwind only generates classes
2521
+ * that appear verbatim in source, so building them with template strings would emit no CSS.
2522
+ */
2523
+ /** A Figma spacing step, by name: `100` is 4px, `400` is 16px, `1600` is 64px. */
2524
+ type SpaceToken = '0' | '100' | '200' | '300' | '400' | '500' | '600' | '700' | '800' | '1000' | '1200' | '1600';
2525
+ interface LayoutBaseProps extends HTMLAttributes<HTMLElement> {
2526
+ children?: ReactNode;
2527
+ /** Lay out your own single child element instead of a `<div>`. */
2528
+ asChild?: boolean;
2529
+ /** Padding on every side, as a spacing token. */
2530
+ p?: SpaceToken;
2531
+ /** Horizontal padding, as a spacing token. */
2532
+ px?: SpaceToken;
2533
+ /** Vertical padding, as a spacing token. */
2534
+ py?: SpaceToken;
2535
+ }
2536
+ type BoxProps = LayoutBaseProps;
2537
+ /** A plain block with token padding. The base the others build on. */
2538
+ declare const Box: react.ForwardRefExoticComponent<LayoutBaseProps & react.RefAttributes<HTMLDivElement>>;
2539
+ type FlexDirection = 'row' | 'column' | 'row-reverse' | 'column-reverse';
2540
+ type FlexAlign = 'start' | 'center' | 'end' | 'baseline' | 'stretch';
2541
+ type FlexJustify = 'start' | 'center' | 'end' | 'between' | 'around';
2542
+ interface FlexProps extends LayoutBaseProps {
2543
+ /** Default `row`. */
2544
+ direction?: FlexDirection;
2545
+ align?: FlexAlign;
2546
+ justify?: FlexJustify;
2547
+ gap?: SpaceToken;
2548
+ /** Let items wrap onto new lines. */
2549
+ wrap?: boolean;
2550
+ /** `inline-flex` instead of `flex`. */
2551
+ inline?: boolean;
2552
+ }
2553
+ /** A flex row or column with token gaps. */
2554
+ declare const Flex: react.ForwardRefExoticComponent<FlexProps & react.RefAttributes<HTMLDivElement>>;
2555
+ type GridColumnCount = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
2556
+ type GridBreakpoint = 'base' | 'sm' | 'md' | 'lg' | 'xl';
2557
+ interface GridProps extends LayoutBaseProps {
2558
+ /**
2559
+ * Column count, fixed or per breakpoint: `columns={3}` or
2560
+ * `columns={{ base: 1, md: 2, lg: 4 }}`.
2561
+ */
2562
+ columns?: GridColumnCount | Partial<Record<GridBreakpoint, GridColumnCount>>;
2563
+ /**
2564
+ * As many columns as fit, each at least this wide, e.g. `"16rem"`. Responds to the grid's own
2565
+ * width, not the viewport's, so it suits form fields and card lists inside panels of any size
2566
+ * (what SCIC's `FormGrid` did). Ignored when `columns` is set.
2567
+ */
2568
+ minColumnWidth?: string;
2569
+ gap?: SpaceToken;
2570
+ gapX?: SpaceToken;
2571
+ gapY?: SpaceToken;
2572
+ align?: FlexAlign;
2573
+ }
2574
+ /** A CSS grid with token gaps: fixed, responsive or auto-fitting columns. */
2575
+ declare const Grid: react.ForwardRefExoticComponent<GridProps & react.RefAttributes<HTMLDivElement>>;
2576
+ type ContainerSize = 'sm' | 'md' | 'lg' | 'xl' | 'full';
2577
+ interface ContainerProps extends LayoutBaseProps {
2578
+ /** Maximum content width. Default `lg` (1136px). */
2579
+ size?: ContainerSize;
2580
+ }
2581
+ /** Centres content at a maximum width, with a 16px side gutter by default. */
2582
+ declare const Container: react.ForwardRefExoticComponent<ContainerProps & react.RefAttributes<HTMLDivElement>>;
2583
+ type SectionSize = 'sm' | 'md' | 'lg';
2584
+ interface SectionProps extends LayoutBaseProps {
2585
+ /** Vertical rhythm: 24, 40 or 64px above and below. Default `md`. */
2586
+ size?: SectionSize;
2587
+ }
2588
+ /**
2589
+ * A page band with vertical rhythm, rendered as a `<section>`. Give it a heading (or an
2590
+ * `aria-label`) when it should be a landmark; an unnamed `<section>` is announced as nothing at
2591
+ * all, which is the right default for a purely visual band.
2592
+ */
2593
+ declare const Section: react.ForwardRefExoticComponent<SectionProps & react.RefAttributes<HTMLElement>>;
1931
2594
 
1932
2595
  interface AspectRatioProps extends HTMLAttributes<HTMLDivElement> {
1933
2596
  children: ReactNode;
@@ -2123,6 +2786,13 @@ declare function PageHeading({ title, subtitle, size, as, actions, truncateTitle
2123
2786
  type PageToolbarSize = 'sm' | 'md';
2124
2787
  interface PageToolbarProps {
2125
2788
  children: ReactNode;
2789
+ /**
2790
+ * Renders an icon-only back control at the far left, ahead of the heading: the Page Header's
2791
+ * `backButton` in Figma (node 3473:16837). New in 0.7.0, from SCIC. Omit for no back control.
2792
+ */
2793
+ onBack?: () => void;
2794
+ /** Accessible name for the back control. Default "Go back". */
2795
+ backLabel?: string;
2126
2796
  /** Allow the row to wrap when the action cluster is wide (entity-detail has seven buttons). */
2127
2797
  wrap?: boolean;
2128
2798
  /**
@@ -2144,7 +2814,7 @@ interface PageToolbarProps {
2144
2814
  * variant is adopted here, which is a deliberate improvement below `md` where the
2145
2815
  * fixed 28px padding was cramped.
2146
2816
  */
2147
- declare function PageToolbar({ children, wrap, size, className }: PageToolbarProps): react.JSX.Element;
2817
+ declare function PageToolbar({ children, onBack, backLabel, wrap, size, className, }: PageToolbarProps): react.JSX.Element;
2148
2818
 
2149
2819
  type FilterBarSize = 'sm' | 'md';
2150
2820
  interface FilterBarProps {
@@ -2189,6 +2859,7 @@ interface TabItem<K extends string = string> {
2189
2859
  count?: number;
2190
2860
  disabled?: boolean;
2191
2861
  }
2862
+ /** The `items` form: a tab strip only, with `TabsPanel`s placed wherever the page needs them. */
2192
2863
  interface TabsProps<K extends string = string> {
2193
2864
  items: TabItem<K>[];
2194
2865
  /** Controlled selection. Omit and pass `defaultValue` for uncontrolled. */
@@ -2205,30 +2876,53 @@ interface TabsProps<K extends string = string> {
2205
2876
  orientation?: TabsOrientation;
2206
2877
  activation?: TabsActivation;
2207
2878
  /**
2208
- * Shared prefix for the generated tab and panel ids. Pass the same value to `TabsPanel`
2209
- * to wire `aria-controls` / `aria-labelledby`. Generated when omitted.
2879
+ * Shared prefix for the tab and panel ids. Pass the same value to each `TabsPanel` and the
2880
+ * tabs point `aria-controls` at their panels. Without it, `aria-controls` is left off: a
2881
+ * generated prefix would point it at ids no panel has. The composable form needs neither.
2210
2882
  */
2211
2883
  idPrefix?: string;
2212
2884
  /** Names the tab strip. Required by the APG when there is more than one on a page. */
2213
2885
  label?: string;
2214
2886
  className?: string;
2215
2887
  }
2888
+ /**
2889
+ * The composable form, new in 0.7.0 and built on Radix Tabs: `Tabs` wraps a `TabsList` of
2890
+ * `TabsTrigger`s and the `TabsContent` panels, and wires every id itself.
2891
+ */
2892
+ interface TabsRootProps {
2893
+ children: ReactNode;
2894
+ value?: string;
2895
+ defaultValue?: string;
2896
+ onValueChange?: (value: string) => void;
2897
+ variant?: TabsVariant;
2898
+ size?: TabsSize;
2899
+ orientation?: TabsOrientation;
2900
+ activation?: TabsActivation;
2901
+ /** Reading direction, which flips Left/Right in a horizontal strip. */
2902
+ dir?: 'ltr' | 'rtl';
2903
+ className?: string;
2904
+ }
2216
2905
  declare const tabId: (prefix: string, key: string) => string;
2217
2906
  declare const tabPanelId: (prefix: string, key: string) => string;
2218
2907
  /**
2219
- * Tab strip.
2908
+ * Tabs, in two forms.
2220
2909
  *
2221
- * Reworked in 0.4.0. It previously carried `role="tablist"`, `role="tab"` and
2222
- * `aria-selected` with **no `onKeyDown` at all** — no Arrow keys, no Home/End, no roving
2223
- * tabindex, no `aria-controls`, and no `role="tabpanel"` counterpart anywhere in the
2224
- * library. That combination is worse than shipping no ARIA: a screen reader announces
2225
- * "tab 3 of 5", the user presses the arrow keys it implies, and nothing happens. Every
2226
- * tab was also individually tabbable, so Tab walked the strip instead of leaving it.
2910
+ * // items: a strip; panels live anywhere, linked by idPrefix.
2911
+ * <Tabs items={items} value={tab} onValueChange={setTab} idPrefix="entity" />
2912
+ * <TabsPanel tabKey="overview" idPrefix="entity" active={tab === 'overview'}>…</TabsPanel>
2227
2913
  *
2228
- * The `underline` active colour is `background-brand` (#0C2D58), which is what Figma
2229
- * specifies.
2914
+ * // composable (0.7.0, Radix): strip and panels in one tree, ids wired for you.
2915
+ * <Tabs defaultValue="overview">
2916
+ * <TabsList label="Sections"><TabsTrigger value="overview">Overview</TabsTrigger></TabsList>
2917
+ * <TabsContent value="overview">…</TabsContent>
2918
+ * </Tabs>
2919
+ *
2920
+ * Both implement the WAI-ARIA tabs pattern: one tab stop on the selected tab, arrows along the
2921
+ * strip (wrapping), Home/End, disabled tabs skipped, automatic or manual activation, and
2922
+ * `role="tabpanel"` regions labelled by their tabs. 0.3.0 had the roles and none of the keys.
2230
2923
  */
2231
- declare function Tabs<K extends string = string>({ items, value: valueProp, defaultValue, onValueChange, variant, size, orientation, activation, idPrefix, label, className, }: TabsProps<K>): react.JSX.Element;
2924
+ declare function Tabs<K extends string = string>(props: TabsProps<K>): ReactElement;
2925
+ declare function Tabs(props: TabsRootProps): ReactElement;
2232
2926
  interface TabsPanelProps extends HTMLAttributes<HTMLDivElement> {
2233
2927
  /** The `key` of the tab this panel belongs to. */
2234
2928
  tabKey: string;
@@ -2244,15 +2938,31 @@ interface TabsPanelProps extends HTMLAttributes<HTMLDivElement> {
2244
2938
  keepMounted?: boolean;
2245
2939
  }
2246
2940
  /**
2247
- * The `role="tabpanel"` half of the pattern, which the library had no equivalent of —
2248
- * so `aria-controls` on a tab pointed at nothing and there was no labelled region for a
2249
- * screen reader to move into.
2941
+ * The `role="tabpanel"` half of the `items` form.
2250
2942
  *
2251
2943
  * `tabIndex={0}` is deliberate and required: when a panel contains no focusable element,
2252
2944
  * it must be reachable itself, otherwise Tab from the selected tab skips the content
2253
- * entirely.
2945
+ * entirely. So it also needs a visible focus ring, which 0.6 suppressed (WCAG 2.4.7).
2254
2946
  */
2255
2947
  declare function TabsPanel({ tabKey, idPrefix, active, children, keepMounted, className, ...rest }: TabsPanelProps): react.JSX.Element | null;
2948
+ interface TabsListProps extends HTMLAttributes<HTMLDivElement> {
2949
+ /** Names the tab strip. Required by the APG when there is more than one on a page. */
2950
+ label?: string;
2951
+ }
2952
+ declare const TabsList: react.ForwardRefExoticComponent<TabsListProps & react.RefAttributes<HTMLDivElement>>;
2953
+ interface TabsTriggerProps extends HTMLAttributes<HTMLButtonElement> {
2954
+ value: string;
2955
+ disabled?: boolean;
2956
+ /** Renders a count chip after the label. */
2957
+ count?: number;
2958
+ }
2959
+ declare const TabsTrigger: react.ForwardRefExoticComponent<TabsTriggerProps & react.RefAttributes<HTMLButtonElement>>;
2960
+ interface TabsContentProps extends HTMLAttributes<HTMLDivElement> {
2961
+ value: string;
2962
+ /** Keep the panel mounted while hidden, preserving its state. Default `false`. */
2963
+ keepMounted?: boolean;
2964
+ }
2965
+ declare const TabsContent: react.ForwardRefExoticComponent<TabsContentProps & react.RefAttributes<HTMLDivElement>>;
2256
2966
 
2257
2967
  type NavItemSize = 'sm' | 'md';
2258
2968
  type NavItemVariant = 'card' | 'plain';
@@ -2263,6 +2973,12 @@ interface NavItemProps extends Omit<HTMLAttributes<HTMLElement>, 'children'> {
2263
2973
  */
2264
2974
  icon?: ReactNode;
2265
2975
  label: string;
2976
+ /**
2977
+ * A destination that exists but cannot be opened right now (no permission, coming soon).
2978
+ * Dimmed, out of the tab order and inert under `asChild`, with `aria-disabled` so it is
2979
+ * still announced. New in 0.7.0; replaces `pointer-events-none opacity-40` at the call site.
2980
+ */
2981
+ disabled?: boolean;
2266
2982
  /**
2267
2983
  * The row you are on — the current route. Paints the brand fill and, under `asChild`, sets
2268
2984
  * `aria-current="page"`; it also reflects to `data-state="active"`.
@@ -2300,7 +3016,7 @@ interface NavItemProps extends Omit<HTMLAttributes<HTMLElement>, 'children'> {
2300
3016
  * nav row that looks interactive and cannot be focused or activated. `asChild` is the
2301
3017
  * fix for anyone using it outside that wrapper:
2302
3018
  *
2303
- * <NavItem asChild icon={<LuHouse />} label="Home">
3019
+ * <NavItem asChild icon={<HouseIcon />} label="Home">
2304
3020
  * <NavLink to="/" />
2305
3021
  * </NavItem>
2306
3022
  */
@@ -2308,7 +3024,7 @@ interface NavItemProps extends Omit<HTMLAttributes<HTMLElement>, 'children'> {
2308
3024
  children?: ReactNode;
2309
3025
  className?: string;
2310
3026
  }
2311
- declare function NavItem({ icon, label, isActive, indicator, collapsed, size, variant, asChild, children, className, ...rest }: NavItemProps): react.JSX.Element;
3027
+ declare function NavItem({ icon, label, isActive, indicator, collapsed, size, variant, asChild, disabled, children, className, onClick, ...rest }: NavItemProps): react.JSX.Element;
2312
3028
 
2313
3029
  type EyebrowLabelVariant = 'uppercase' | 'plain';
2314
3030
  interface EyebrowLabelProps {
@@ -2454,6 +3170,33 @@ declare function paginationRange(page: number, pageCount: number, siblingCount?:
2454
3170
  * announced as an unavailable control.
2455
3171
  */
2456
3172
  declare const Pagination: react.ForwardRefExoticComponent<PaginationProps & react.RefAttributes<HTMLElement>>;
3173
+ interface PaginationBarProps {
3174
+ /** 1-based. */
3175
+ page: number;
3176
+ /** Rows per page. */
3177
+ pageSize: number;
3178
+ /** Total rows across every page. */
3179
+ total: number;
3180
+ onPageChange: (page: number) => void;
3181
+ /** Offer a page-size selector. Omit it, or pass `[]` as `pageSizeOptions`, to hide one. */
3182
+ onPageSizeChange?: (pageSize: number) => void;
3183
+ /** Page sizes on offer. Default `[10, 20, 50]`. */
3184
+ pageSizeOptions?: number[];
3185
+ /** Replaces the "Showing 1–10 of 57" summary. */
3186
+ summary?: ReactNode;
3187
+ /** Names the page-button landmark. Default "Pages". */
3188
+ label?: string;
3189
+ className?: string;
3190
+ }
3191
+ /**
3192
+ * A full pager row: a range summary, an optional page-size selector, and the page buttons.
3193
+ * New in 0.7.0, from SCIC's `Pagination` (whose `limit` is `pageSize` here). `DataTable` renders
3194
+ * one; use it directly for a list that pages without a table.
3195
+ *
3196
+ * Only the page buttons are the `<nav>` landmark. The summary and the size selector sit beside
3197
+ * it, because a landmark should hold navigation and nothing else.
3198
+ */
3199
+ declare function PaginationBar({ page, pageSize, total, onPageChange, onPageSizeChange, pageSizeOptions, summary, label, className, }: PaginationBarProps): react.JSX.Element;
2457
3200
 
2458
3201
  type NavigationMenuOrientation = 'horizontal' | 'vertical';
2459
3202
  type NavigationMenuVariant = 'pill' | 'link';
@@ -2507,66 +3250,115 @@ declare const NavigationMenuItem: react.ForwardRefExoticComponent<NavigationMenu
2507
3250
  * All of them take `asChild`, because the right element is contextual — a `Heading` is an
2508
3251
  * `<h2>` on a page and an `<h3>` inside a card, and only the caller knows the outline.
2509
3252
  */
3253
+ /**
3254
+ * The text colour as a meaning, new in 0.7.0. `muted` and `subtle` are the secondary and
3255
+ * tertiary steps; the rest are the status tones. It replaces the
3256
+ * `className={denied ? 'text-danger' : 'text-positive'}` that consumers were writing, so state
3257
+ * is a prop and the colour stays a token. Omit it to keep each component's own colour.
3258
+ */
3259
+ type TextTone = 'default' | 'muted' | 'subtle' | 'brand' | 'positive' | 'warning' | 'danger';
2510
3260
  type BaseProps = HTMLAttributes<HTMLElement> & {
2511
3261
  children?: ReactNode;
2512
3262
  asChild?: boolean;
3263
+ /** Text colour as a meaning. See `TextTone`. */
3264
+ tone?: TextTone;
2513
3265
  };
2514
3266
  type TextProps = BaseProps;
2515
3267
  /** `Text` — the default body paragraph. */
2516
3268
  declare const Text: react.ForwardRefExoticComponent<HTMLAttributes<HTMLElement> & {
2517
3269
  children?: ReactNode;
2518
3270
  asChild?: boolean;
3271
+ /** Text colour as a meaning. See `TextTone`. */
3272
+ tone?: TextTone;
2519
3273
  } & react.RefAttributes<HTMLElement>>;
2520
3274
  /** `Text Small` — secondary body copy. */
2521
3275
  declare const TextSmall: react.ForwardRefExoticComponent<HTMLAttributes<HTMLElement> & {
2522
3276
  children?: ReactNode;
2523
3277
  asChild?: boolean;
3278
+ /** Text colour as a meaning. See `TextTone`. */
3279
+ tone?: TextTone;
2524
3280
  } & react.RefAttributes<HTMLElement>>;
2525
3281
  /** `Text Tiny` — the smallest readable step; captions and table meta. */
2526
3282
  declare const TextTiny: react.ForwardRefExoticComponent<HTMLAttributes<HTMLElement> & {
2527
3283
  children?: ReactNode;
2528
3284
  asChild?: boolean;
3285
+ /** Text colour as a meaning. See `TextTone`. */
3286
+ tone?: TextTone;
2529
3287
  } & react.RefAttributes<HTMLElement>>;
2530
3288
  /** `Text Strong` — emphasis by weight, in a real `<strong>`. */
2531
3289
  declare const TextStrong: react.ForwardRefExoticComponent<HTMLAttributes<HTMLElement> & {
2532
3290
  children?: ReactNode;
2533
3291
  asChild?: boolean;
3292
+ /** Text colour as a meaning. See `TextTone`. */
3293
+ tone?: TextTone;
2534
3294
  } & react.RefAttributes<HTMLElement>>;
2535
3295
  /** `Text Emphasis` — emphasis by slant, in a real `<em>`. */
2536
3296
  declare const TextEmphasis: react.ForwardRefExoticComponent<HTMLAttributes<HTMLElement> & {
2537
3297
  children?: ReactNode;
2538
3298
  asChild?: boolean;
3299
+ /** Text colour as a meaning. See `TextTone`. */
3300
+ tone?: TextTone;
3301
+ } & react.RefAttributes<HTMLElement>>;
3302
+ /** An inline quotation, in a real `<q>` so the browser adds locale-correct quote marks. New in 0.7.0. */
3303
+ declare const Quote: react.ForwardRefExoticComponent<HTMLAttributes<HTMLElement> & {
3304
+ children?: ReactNode;
3305
+ asChild?: boolean;
3306
+ /** Text colour as a meaning. See `TextTone`. */
3307
+ tone?: TextTone;
2539
3308
  } & react.RefAttributes<HTMLElement>>;
2540
3309
  /** `Text Code` — inline monospace. */
2541
3310
  declare const TextCode: react.ForwardRefExoticComponent<HTMLAttributes<HTMLElement> & {
2542
3311
  children?: ReactNode;
2543
3312
  asChild?: boolean;
3313
+ /** Text colour as a meaning. See `TextTone`. */
3314
+ tone?: TextTone;
2544
3315
  } & react.RefAttributes<HTMLElement>>;
2545
3316
  /** `Text Title Hero` — the largest step, one per page at most. */
2546
3317
  declare const TitleHero: react.ForwardRefExoticComponent<HTMLAttributes<HTMLElement> & {
2547
3318
  children?: ReactNode;
2548
3319
  asChild?: boolean;
3320
+ /** Text colour as a meaning. See `TextTone`. */
3321
+ tone?: TextTone;
2549
3322
  } & react.RefAttributes<HTMLElement>>;
2550
3323
  /** `Text Title Page` — page title. */
2551
3324
  declare const TitlePage: react.ForwardRefExoticComponent<HTMLAttributes<HTMLElement> & {
2552
3325
  children?: ReactNode;
2553
3326
  asChild?: boolean;
3327
+ /** Text colour as a meaning. See `TextTone`. */
3328
+ tone?: TextTone;
2554
3329
  } & react.RefAttributes<HTMLElement>>;
2555
3330
  /** `Text Subtitle` — a lead paragraph under a title; regular weight by design. */
2556
3331
  declare const Subtitle: react.ForwardRefExoticComponent<HTMLAttributes<HTMLElement> & {
2557
3332
  children?: ReactNode;
2558
3333
  asChild?: boolean;
3334
+ /** Text colour as a meaning. See `TextTone`. */
3335
+ tone?: TextTone;
2559
3336
  } & react.RefAttributes<HTMLElement>>;
2560
3337
  /** `Text Heading` — section heading. */
2561
3338
  declare const Heading: react.ForwardRefExoticComponent<HTMLAttributes<HTMLElement> & {
2562
3339
  children?: ReactNode;
2563
3340
  asChild?: boolean;
3341
+ /** Text colour as a meaning. See `TextTone`. */
3342
+ tone?: TextTone;
2564
3343
  } & react.RefAttributes<HTMLElement>>;
2565
3344
  /** `Text Subheading` — subsection heading; regular weight, matching Figma. */
2566
3345
  declare const Subheading: react.ForwardRefExoticComponent<HTMLAttributes<HTMLElement> & {
2567
3346
  children?: ReactNode;
2568
3347
  asChild?: boolean;
3348
+ /** Text colour as a meaning. See `TextTone`. */
3349
+ tone?: TextTone;
2569
3350
  } & react.RefAttributes<HTMLElement>>;
3351
+ interface BlockquoteProps extends HTMLAttributes<HTMLQuoteElement> {
3352
+ children?: ReactNode;
3353
+ /** URL of the source, set as the `cite` attribute. Not shown; pair with a visible credit. */
3354
+ cite?: string;
3355
+ tone?: TextTone;
3356
+ }
3357
+ /**
3358
+ * A block quotation, new in 0.7.0, matching Radix Themes' `Blockquote`. A real
3359
+ * `<blockquote>`, so assistive tech announces where the quotation starts and ends.
3360
+ */
3361
+ declare const Blockquote: react.ForwardRefExoticComponent<BlockquoteProps & react.RefAttributes<HTMLQuoteElement>>;
2570
3362
  interface TextLinkProps extends AnchorHTMLAttributes<HTMLAnchorElement> {
2571
3363
  children?: ReactNode;
2572
3364
  asChild?: boolean;
@@ -2623,6 +3415,91 @@ interface WidgetFooterProps {
2623
3415
  }
2624
3416
  declare function WidgetFooter({ caption, subcaption, action, className }: WidgetFooterProps): react.JSX.Element;
2625
3417
 
3418
+ /**
3419
+ * The dashboard grid vocabulary, ported from SCIC in 0.7.0: a 12-column row, five widget widths
3420
+ * and three canonical card heights. The heights are modular (364 = 170·2 + 24, 752 = 170·4 +
3421
+ * 24·3), so two stacked `medium` cards bottom-align with one `large`.
3422
+ *
3423
+ * Not included: SCIC's drag-and-drop masonry dashboard, which needs `@dnd-kit` and stays in the
3424
+ * app until it earns a subpath of its own.
3425
+ */
3426
+ /** Column span within the 12-column grid. */
3427
+ type ColSize = 'tiny' | 'small' | 'medium' | 'large' | 'full';
3428
+ /** Canonical widget card heights. */
3429
+ type WidgetHeight = 'small' | 'medium' | 'large';
3430
+ /**
3431
+ * Viewport-driven spans: everything stacks (tiny tiles pair up 2×2) below `lg`, then the
3432
+ * 12-column spans apply. Right when the grid gets the whole viewport. For a grid that shares
3433
+ * its row with a rail or drawer, size by its own width: see `useWidthTier` and
3434
+ * `COL_SPAN_BY_TIER`.
3435
+ */
3436
+ declare const COL_SPAN: Record<ColSize, string>;
3437
+ declare const HEIGHT_CLASS: Record<WidgetHeight, string>;
3438
+ /** The same heights in px, for layout maths. Keep in step with `HEIGHT_CLASS`. */
3439
+ declare const HEIGHT_PX: Record<WidgetHeight, number>;
3440
+ interface WidgetGridProps {
3441
+ children: ReactNode;
3442
+ className?: string;
3443
+ }
3444
+ /** A vertical stack of `WidgetGridRow`s with the dashboard gutters. */
3445
+ declare function WidgetGrid({ children, className }: WidgetGridProps): react.JSX.Element;
3446
+ interface WidgetGridRowProps {
3447
+ children: ReactNode;
3448
+ className?: string;
3449
+ }
3450
+ /** A 12-column row. Place `WidgetGridItem`s in it. */
3451
+ declare function WidgetGridRow({ children, className }: WidgetGridRowProps): react.JSX.Element;
3452
+ interface WidgetGridItemProps extends HTMLAttributes<HTMLDivElement> {
3453
+ /** How many columns the widget claims. */
3454
+ size: ColSize;
3455
+ /** Fixes the card height to the canonical scale. Omit for content height. */
3456
+ height?: WidgetHeight;
3457
+ }
3458
+ /**
3459
+ * One widget's cell. Takes `size` and `height` as props, so a dashboard never composes span
3460
+ * classes itself. They are also set as `data-size` / `data-height`.
3461
+ */
3462
+ declare function WidgetGridItem({ size, height, className, ...rest }: WidgetGridItemProps): react.JSX.Element;
3463
+
3464
+ /**
3465
+ * Container-width tiers for grids that cannot use viewport breakpoints, because they share their
3466
+ * row with a nav rail or a docked drawer. Pure functions, ported from SCIC in 0.7.0. The hook that
3467
+ * measures and debounces is `useWidthTier`.
3468
+ */
3469
+ type GridTier = 'stacked' | 'narrow' | 'standard' | 'wide';
3470
+ declare const GRID_TIERS: readonly GridTier[];
3471
+ /** The narrowest width, in px, at which each tier applies. */
3472
+ declare const TIER_MIN_PX: Record<GridTier, number>;
3473
+ declare function quantizeWidth(px: number): number;
3474
+ /** The tier for a width, with no hysteresis. */
3475
+ declare function tierForWidth(px: number): GridTier;
3476
+ /** The next tier from `current`, holding still inside the hysteresis band. */
3477
+ declare function nextTier(current: GridTier, px: number): GridTier;
3478
+ /** Columns (of 12) each widget width claims, per tier. */
3479
+ declare const TIER_COLS: Record<GridTier, Record<ColSize, number>>;
3480
+ /** `TIER_COLS` as literal classes (Tailwind only emits classes it finds verbatim). */
3481
+ declare const COL_SPAN_BY_TIER: Record<GridTier, Record<ColSize, string>>;
3482
+ declare function colsFor(tier: GridTier, size: ColSize): number;
3483
+ /** The pixel width of a cell spanning `cols` of 12, given the grid width and column gap. */
3484
+ declare function slotWidthPx(gridWidthPx: number, columnGapPx: number, cols: number): number;
3485
+
3486
+ interface UseWidthTierOptions {
3487
+ /** Stop committing new widths, e.g. while a drawer animates. Unfreezing flushes the latest. */
3488
+ frozen?: boolean;
3489
+ }
3490
+ interface UseWidthTierResult {
3491
+ ref: (node: HTMLElement | null) => void;
3492
+ /** The quantised width, or `null` before the first measurement. */
3493
+ widthPx: number | null;
3494
+ tier: GridTier;
3495
+ }
3496
+ /**
3497
+ * Measures an element and reports its `GridTier`, debounced and with hysteresis. Ported from
3498
+ * SCIC in 0.7.0. Without `ResizeObserver` (jsdom, very old browsers) it measures once on mount
3499
+ * rather than throwing.
3500
+ */
3501
+ declare function useWidthTier({ frozen }?: UseWidthTierOptions): UseWidthTierResult;
3502
+
2626
3503
  interface StatTileProps {
2627
3504
  label: string;
2628
3505
  value: string | number;
@@ -2633,9 +3510,34 @@ interface StatTileProps {
2633
3510
  * which is how competing status palettes drift apart.
2634
3511
  */
2635
3512
  dotColor?: string;
3513
+ /** A muted line under the value: a comparison, a unit, "of 240". New in 0.7.0, from SCIC. */
3514
+ hint?: ReactNode;
3515
+ /**
3516
+ * Makes the tile a toggle button, for a row of tiles that filter a list below. New in 0.7.0.
3517
+ * Pair with `selected`.
3518
+ */
3519
+ onClick?: () => void;
3520
+ /**
3521
+ * The tile's filter is the active one. Sets `aria-pressed` (with `onClick`) or `aria-current`
3522
+ * (with `asChild`), and `data-state="selected"`, which the tile styles: no conditional border
3523
+ * classes needed.
3524
+ */
3525
+ selected?: boolean;
3526
+ /** Render onto the single child instead, e.g. a router `<Link>` to a filtered page. */
3527
+ asChild?: boolean;
3528
+ /** The element to render onto, with `asChild`. Its own children are replaced by the tile. */
3529
+ children?: ReactElement;
2636
3530
  className?: string;
2637
3531
  }
2638
- declare function StatTile({ label, value, tone, dotColor, className }: StatTileProps): react.JSX.Element;
3532
+ /**
3533
+ * A labelled figure: "Open cases 42".
3534
+ *
3535
+ * From 0.7.0 a tile can also be the filter for the list beneath it, which is what Cleo's
3536
+ * Companies, Employees and Users screens hand-built with
3537
+ * `className={filter === t.f ? 'border-brand …' : ''}`. Give it `onClick` and `selected` and it
3538
+ * is a real toggle button (`aria-pressed`), styled from its own state.
3539
+ */
3540
+ declare function StatTile({ label, value, tone, dotColor, hint, onClick, selected, asChild, children, className, }: StatTileProps): react.JSX.Element;
2639
3541
 
2640
3542
  type StatNumberSize = 'sm' | 'md' | 'lg';
2641
3543
  type StatNumberWeight = 'medium' | 'bold';
@@ -3038,6 +3940,28 @@ interface ListRowProps {
3038
3940
  /** Render an `<li>` instead of a `<div>` — use inside a `<ul>`/`<ol>`. */
3039
3941
  as?: 'div' | 'li';
3040
3942
  onClick?: () => void;
3943
+ /**
3944
+ * Render onto the single child instead, e.g. a router `<Link>` for a row that navigates.
3945
+ * The child is the interactive element and the slots render inside it. New in 0.7.0.
3946
+ *
3947
+ * <ListRow asChild title="Acme" description="Supplier"><Link to="/acme" /></ListRow>
3948
+ */
3949
+ asChild?: boolean;
3950
+ /** The element to render onto, with `asChild`. Its own children are replaced by the slots. */
3951
+ children?: ReactElement;
3952
+ /**
3953
+ * The row is chosen, in a set where rows toggle on and off (a picker, a multi-select list).
3954
+ * Sets `aria-pressed` on a clickable row and `data-state="selected"`, which the row styles.
3955
+ * New in 0.7.0; it replaces conditional `bg-brand-tertiary` classes at the call site.
3956
+ */
3957
+ selected?: boolean;
3958
+ /**
3959
+ * The row is the current one in a navigation-like list (the open section, this page). Sets
3960
+ * `aria-current` and is styled like `selected`. New in 0.7.0.
3961
+ */
3962
+ current?: boolean | 'page' | 'step' | 'location';
3963
+ /** A clickable row that cannot be activated right now. Sets `aria-disabled`. New in 0.7.0. */
3964
+ disabled?: boolean;
3041
3965
  /**
3042
3966
  * Accessible name for a clickable row. Strongly recommended whenever `onClick` is set:
3043
3967
  * without it the name is the concatenation of every slot's text.
@@ -3052,8 +3976,12 @@ interface ListRowProps {
3052
3976
  * document-upload flow — its status vocabulary, its five raw-hex pills and its
3053
3977
  * unicode-glyph labels — into the library. Every feature of those rows is reachable by
3054
3978
  * composing this with `FileRow`, `FileDropZone` and `StatusBadge`; see the docs.
3979
+ *
3980
+ * State is a prop, not a class: `selected`, `current` and `disabled` set the attributes that
3981
+ * announce them (`aria-pressed`, `aria-current`, `aria-disabled`, `data-state`) and the row
3982
+ * styles itself from those.
3055
3983
  */
3056
- declare function ListRow({ leading, title, titleMeta, description, meta, trailing, footer, density, divider, as: Tag, onClick, 'aria-label': ariaLabel, className, }: ListRowProps): react.JSX.Element;
3984
+ declare function ListRow({ leading, title, titleMeta, description, meta, trailing, footer, density, divider, as: Tag, onClick, asChild, children, selected, current, disabled, 'aria-label': ariaLabel, className, }: ListRowProps): react.JSX.Element;
3057
3985
 
3058
3986
  interface FileRowProps {
3059
3987
  name: string;
@@ -3130,6 +4058,16 @@ interface ProgressBarProps {
3130
4058
  radius?: string;
3131
4059
  /** Accessible name when there is no visible `label`. */
3132
4060
  'aria-label'?: string;
4061
+ /**
4062
+ * Draw the bar as this many equal steps, filled in whole steps, e.g. a password-strength
4063
+ * meter. New in 0.7.0; replaces hand-built rows of tinted bars.
4064
+ */
4065
+ segments?: number;
4066
+ /**
4067
+ * What the value means, announced instead of the number (`aria-valuetext`), e.g. "Strong".
4068
+ * A strength meter at 75 means nothing as "75 percent".
4069
+ */
4070
+ valueText?: string;
3133
4071
  /**
3134
4072
  * Applied to the track. This is how you set a fixed width — `className="w-16"`.
3135
4073
  * It genuinely overrides the base `w-full` because this file uses `cn`.
@@ -3143,7 +4081,7 @@ interface ProgressBarProps {
3143
4081
  * `widgets/` despite being a general-purpose primitive — so `TableCellProgress`
3144
4082
  * hand-rolled a second copy rather than reuse it. It also had no ARIA at all.
3145
4083
  */
3146
- declare function ProgressBar({ value, tone, size, label, showValue, radius, 'aria-label': ariaLabel, className, }: ProgressBarProps): react.JSX.Element;
4084
+ declare function ProgressBar({ value, tone, size, label, showValue, radius, 'aria-label': ariaLabel, segments, valueText, className, }: ProgressBarProps): react.JSX.Element;
3147
4085
 
3148
4086
  interface NumberedListItem {
3149
4087
  title: string;
@@ -3283,6 +4221,58 @@ interface DetailGridProps {
3283
4221
  */
3284
4222
  declare function DetailGrid({ children, columns, className }: DetailGridProps): react.JSX.Element;
3285
4223
 
4224
+ /**
4225
+ * Label/value rows for a detail page, as a real `<dl>`. New in 0.7.0, from SCIC.
4226
+ *
4227
+ * Use it for a profile or account summary read top to bottom. `DetailGrid` / `DetailItem`
4228
+ * are for a multi-column summary card. The rows here are width-aware without a breakpoint: the
4229
+ * label has a fixed basis and the value a minimum one, and the row wraps, so in a narrow panel
4230
+ * (a one-third column, a 320px phone, 200% zoom) the value drops below its label instead of
4231
+ * being squeezed into a sliver beside it.
4232
+ */
4233
+ interface DescriptionListProps {
4234
+ children: ReactNode;
4235
+ className?: string;
4236
+ }
4237
+ declare function DescriptionList({ children, className }: DescriptionListProps): react.JSX.Element;
4238
+ interface DescriptionItemProps {
4239
+ label: string;
4240
+ /** An empty value renders an em dash. */
4241
+ value: ReactNode;
4242
+ /**
4243
+ * Adds a copy-to-clipboard button. Pass the plain string to copy: emails and ids are long,
4244
+ * unbroken and commonly pasted elsewhere.
4245
+ */
4246
+ copyValue?: string;
4247
+ className?: string;
4248
+ }
4249
+ declare function DescriptionItem({ label, value, copyValue, className }: DescriptionItemProps): react.JSX.Element;
4250
+ interface CopyButtonProps {
4251
+ /** The text to copy. */
4252
+ value: string;
4253
+ /** The button's accessible name, e.g. "Copy email". */
4254
+ label: string;
4255
+ /** Announced after a copy. Default "Copied". */
4256
+ copiedLabel?: string;
4257
+ className?: string;
4258
+ }
4259
+ /**
4260
+ * An icon button that copies `value` to the clipboard, shows a tick for two seconds, and
4261
+ * announces the copy in a polite live region. Exported for ids and codes outside a
4262
+ * `DescriptionList`.
4263
+ */
4264
+ declare function CopyButton({ value, label, copiedLabel, className }: CopyButtonProps): react.JSX.Element;
4265
+ /**
4266
+ * A one-line email that truncates the local part and keeps the domain:
4267
+ * `alexandra.konstan…@example.com`. The full address stays in the DOM (screen readers and copy
4268
+ * get all of it) and in `title`. Pair it with `copyValue`, so touch users, who cannot hover, can
4269
+ * still get the address.
4270
+ */
4271
+ declare function EmailText({ email, className }: {
4272
+ email: string;
4273
+ className?: string;
4274
+ }): react.JSX.Element;
4275
+
3286
4276
  type CheckedGroupListColumns = 1 | 2 | 3;
3287
4277
  /** One labelled group of ticked items. */
3288
4278
  interface CheckedGroup {
@@ -3381,6 +4371,12 @@ interface TableProps extends HTMLAttributes<HTMLTableElement> {
3381
4371
  density?: TableDensity;
3382
4372
  /** Equal-width columns driven by `<colgroup>`, matching `DataTable`. Default `false`. */
3383
4373
  fixed?: boolean;
4374
+ /**
4375
+ * Cap the height (px number or CSS length) and scroll the body inside it. Pair with
4376
+ * `<TableHead sticky>` to keep the header row in view. The wrapper becomes a focusable region
4377
+ * named by `label`, so the keyboard can scroll it. New in 0.7.1.
4378
+ */
4379
+ maxHeight?: number | string;
3384
4380
  }
3385
4381
  declare const Table: react.ForwardRefExoticComponent<TableProps & react.RefAttributes<HTMLTableElement>>;
3386
4382
  interface TableCaptionProps extends HTMLAttributes<HTMLTableCaptionElement> {
@@ -3393,8 +4389,18 @@ declare const TableCaption: react.ForwardRefExoticComponent<TableCaptionProps &
3393
4389
  declare const TableHeader: react.ForwardRefExoticComponent<HTMLAttributes<HTMLTableSectionElement> & react.RefAttributes<HTMLTableSectionElement>>;
3394
4390
  declare const TableBody: react.ForwardRefExoticComponent<HTMLAttributes<HTMLTableSectionElement> & react.RefAttributes<HTMLTableSectionElement>>;
3395
4391
  declare const TableFooter: react.ForwardRefExoticComponent<HTMLAttributes<HTMLTableSectionElement> & react.RefAttributes<HTMLTableSectionElement>>;
4392
+ /**
4393
+ * A row's state tint. Each is a meaning, not a colour: `muted` for an inactive or ended
4394
+ * record, `danger` for a denied or failed one, and so on. New in 0.7.0, to replace the
4395
+ * `className={active ? '' : 'bg-default-secondary'}` consumers were writing on every row.
4396
+ */
4397
+ type TableRowTone = 'default' | 'muted' | 'brand' | 'positive' | 'warning' | 'danger';
3396
4398
  interface TableRowProps extends HTMLAttributes<HTMLTableRowElement> {
3397
4399
  selected?: boolean;
4400
+ /** State tint; see `TableRowTone`. Selection wins over tone. */
4401
+ tone?: TableRowTone;
4402
+ /** De-emphasises the row (an expired or archived record) without hiding it. */
4403
+ dimmed?: boolean;
3398
4404
  }
3399
4405
  declare const TableRow: react.ForwardRefExoticComponent<TableRowProps & react.RefAttributes<HTMLTableRowElement>>;
3400
4406
  interface TableHeadProps extends ThHTMLAttributes<HTMLTableCellElement> {
@@ -3420,50 +4426,67 @@ interface TableCellProps extends TdHTMLAttributes<HTMLTableCellElement> {
3420
4426
  }
3421
4427
  declare const TableCell: react.ForwardRefExoticComponent<TableCellProps & react.RefAttributes<HTMLTableCellElement>>;
3422
4428
 
3423
- interface ColumnDef<T> {
3424
- key: string;
3425
- header: string;
3426
- /**
3427
- * CSS width value — e.g. `"320px"`, `"10rem"`. When `grow` is true this becomes the
3428
- * column's floor: it counts toward the table's min-width, below which the wrapper
3429
- * scrolls sideways rather than crushing the columns.
3430
- */
3431
- width: string;
3432
- /**
3433
- * When true the column absorbs the remaining table width.
3434
- *
3435
- * With no `grow` column, `table-fixed` distributes surplus width proportionally
3436
- * across every column — the old flex layout left it blank on the right instead. Mark
3437
- * whichever column should soak it up.
3438
- */
3439
- grow?: boolean;
3440
- render: (row: T) => ReactNode;
3441
- }
3442
- type DataTableDensity = 'default' | 'compact';
3443
- type DataTableAlign = 'center' | 'top';
3444
- interface DataTableProps<T> {
3445
- columns: ColumnDef<T>[];
3446
- rows: T[];
3447
- getRowKey: (row: T, index: number) => Key;
3448
- /** Row and header padding. `compact` also steps the header and cell type down. */
3449
- density?: DataTableDensity;
3450
- /** Vertical alignment of every body cell. Use `top` for multi-line or ragged cells. */
3451
- align?: DataTableAlign;
3452
- onRowClick?: (row: T) => void;
3453
- /** Rendered as one full-width row when `rows` is empty. Omit to render nothing. */
3454
- emptyLabel?: string;
4429
+ /** How a column appears in card mode. */
4430
+ type ColumnMobileRole = 'title' | 'status' | 'actions' | 'field' | 'hidden';
4431
+
4432
+ /**
4433
+ * The composable parts of `DataTable`. `DataTable` renders all of them for you; they are
4434
+ * exported for a table that needs its own layout around them (a toolbar elsewhere on the
4435
+ * page, a pager in a sticky footer) or a custom header renderer.
4436
+ */
4437
+ /** The id `createSelectColumn` gives its column, so `DataTable` can find and place it. */
4438
+ declare const SELECT_COLUMN_ID = "select";
4439
+ interface DataTableColumnHeaderProps<TData, TValue> {
4440
+ column: Column<TData, TValue>;
4441
+ /** Header text. Defaults to the column's label. */
4442
+ title?: string;
3455
4443
  className?: string;
3456
4444
  }
3457
4445
  /**
3458
- * A real `<table>` with `table-fixed` and a `<colgroup>`.
4446
+ * A header that sorts its column when the column can sort, and plain text when it cannot.
4447
+ * `DataTable` uses it for every string `header`. Use it yourself inside a `header` render
4448
+ * function to keep the sort control while adding something next to it.
3459
4449
  *
3460
- * 0.2.0 laid each row out as its own flex container sized `w-max`, so a `grow` column
3461
- * sized itself per row and one long cell shunted that row's remaining columns out of
3462
- * line with its neighbours. `table-fixed` resolves column widths once for the whole
3463
- * table, which is the property the consuming app hand-rolled a separate audit table
3464
- * to get.
4450
+ * A click cycles the sort (ascending → descending → off). Shift-click adds the column to a
4451
+ * multi-column sort. The direction is announced through `aria-sort` on the `<th>`, which
4452
+ * `DataTable` sets, so this button carries only the visible chevron.
4453
+ */
4454
+ declare function DataTableColumnHeader<TData, TValue>({ column, title, className, }: DataTableColumnHeaderProps<TData, TValue>): react.JSX.Element;
4455
+ interface CreateSelectColumnOptions<TData> {
4456
+ /** Names each row's checkbox, e.g. `(row) => \`Select ${row.name}\``. Default "Select row". */
4457
+ getRowLabel?: (row: TData) => string;
4458
+ /** Names the header checkbox. Default "Select all rows on this page". */
4459
+ selectAllLabel?: string;
4460
+ }
4461
+ /**
4462
+ * A leading checkbox column. `DataTable` adds one automatically when `enableRowSelection` is
4463
+ * set and the columns have none, so call this only to place it yourself or to name the rows.
4464
+ *
4465
+ * The header checkbox selects the current *page*, which is what a user can see, and shows
4466
+ * indeterminate while some of the page is selected.
4467
+ */
4468
+ declare function createSelectColumn<TData>(options?: CreateSelectColumnOptions<TData>): ColumnDef<TData, unknown>;
4469
+ interface DataTableViewOptionsProps<TData> {
4470
+ table: Table$1<TData>;
4471
+ /** Trigger text. Default "Columns". */
4472
+ label?: string;
4473
+ }
4474
+ /** A "Columns" menu that shows and hides every column whose `enableHiding` is not false. */
4475
+ declare function DataTableViewOptions<TData>({ table, label }: DataTableViewOptionsProps<TData>): react.JSX.Element | null;
4476
+ interface DataTablePaginationProps<TData> {
4477
+ table: Table$1<TData>;
4478
+ /** Page sizes on offer. An empty array hides the selector. Default `[10, 20, 50]`. */
4479
+ pageSizeOptions?: number[];
4480
+ /** Replaces the "Showing 1–10 of 57" summary. */
4481
+ summary?: ReactNode;
4482
+ }
4483
+ /** The pager row: a range summary, a page-size selector, and page buttons. */
4484
+ declare function DataTablePagination<TData>({ table, pageSizeOptions, summary, }: DataTablePaginationProps<TData>): react.JSX.Element;
4485
+
4486
+ /**
4487
+ * Cell renderers for `DataTable` (and the `Table` parts). Unchanged in 0.7.0; moved out of
4488
+ * `data-table.tsx` when the table itself was rebuilt on TanStack Table.
3465
4489
  */
3466
- declare function DataTable<T>({ columns, rows, getRowKey, density, align, onRowClick, emptyLabel, className, }: DataTableProps<T>): react.JSX.Element;
3467
4490
  /**
3468
4491
  * Cell type scale.
3469
4492
  *
@@ -3508,9 +4531,221 @@ interface TableCellProgressProps {
3508
4531
  size?: TableCellSize;
3509
4532
  className?: string;
3510
4533
  }
3511
- /** Mini progress bar with a percentage label below. */
4534
+ /**
4535
+ * Mini progress bar with its percentage at the end. The bar fills whatever width the cell gives
4536
+ * it, as shadcn's Progress (`w-full`), Ant Design's line Progress and MUI's LinearProgress do:
4537
+ * through 0.7.0 it was a fixed 48 / 64px, which left most of a wide column, or of a card field in
4538
+ * the responsive layout, empty. `size` now sets the bar's thickness (4 / 6px).
4539
+ */
3512
4540
  declare function TableCellProgress({ percent, tone, size, className, }: TableCellProgressProps): react.JSX.Element;
3513
4541
 
4542
+ type DataTableColumnAlign = 'start' | 'center' | 'end';
4543
+ /**
4544
+ * Per-column layout options, carried on TanStack's `meta`. Declared by augmenting TanStack's
4545
+ * own `ColumnMeta`, so `meta` on your `ColumnDef` is typed with no extra import:
4546
+ *
4547
+ * const columns: ColumnDef<Supplier>[] = [
4548
+ * { accessorKey: 'name', header: 'Supplier', meta: { width: '280px', grow: true, mobile: 'title' } },
4549
+ * ];
4550
+ */
4551
+ declare module '@tanstack/react-table' {
4552
+ interface ColumnMeta<TData extends RowData, TValue> {
4553
+ /**
4554
+ * CSS width for the column's `<col>`, e.g. `"320px"` or `"10rem"`. A column is never
4555
+ * narrower than its header text. With `grow`, this is the floor instead.
4556
+ */
4557
+ width?: string;
4558
+ /** Absorbs the table's remaining width, with `width` as its floor. Usually one column. */
4559
+ grow?: boolean;
4560
+ /** Horizontal alignment of the header and cells. Default `start`. */
4561
+ align?: DataTableColumnAlign;
4562
+ /**
4563
+ * The cell renders its own controls (a button, a toggle, a menu). Presses inside it stop
4564
+ * before reaching the row's `onRowClick`, and the cell stops clipping its overflow, so
4565
+ * focus rings are not cut off.
4566
+ */
4567
+ interactive?: boolean;
4568
+ /** Keep the header for screen readers but hide it visually, e.g. an actions column. */
4569
+ hideHeader?: boolean;
4570
+ /** The column's part in card mode. See `ColumnMobileRole`. Default `field`. */
4571
+ mobile?: ColumnMobileRole;
4572
+ /** Pin the first (`start`) or last (`end`) visible column while the table scrolls sideways. */
4573
+ sticky?: 'start' | 'end';
4574
+ /** The column's name where its header cannot be shown as text: menus, card labels. */
4575
+ label?: string;
4576
+ /** Extra classes on the header cell. An escape hatch; prefer `align`. */
4577
+ headerClassName?: string;
4578
+ /** Extra classes on each body cell. An escape hatch; prefer `align`. */
4579
+ cellClassName?: string;
4580
+ }
4581
+ }
4582
+ type DataTableDensity = 'default' | 'compact';
4583
+ type DataTableAlign = 'center' | 'top';
4584
+ /** The table state you can control. Every key is optional and independently controlled. */
4585
+ interface DataTableState {
4586
+ sorting: SortingState;
4587
+ globalFilter: string;
4588
+ columnFilters: ColumnFiltersState;
4589
+ pagination: PaginationState;
4590
+ columnVisibility: VisibilityState;
4591
+ rowSelection: RowSelectionState;
4592
+ }
4593
+ /** Hand an operation to the server. The table then shows `data` as given for that operation. */
4594
+ interface DataTableManual {
4595
+ sorting?: boolean;
4596
+ filtering?: boolean;
4597
+ pagination?: boolean;
4598
+ /** Total rows on the server. Needed with `pagination`, so the pager knows the page count. */
4599
+ rowCount?: number;
4600
+ }
4601
+ interface DataTableSearchOptions {
4602
+ /** Filter one column instead of every column. */
4603
+ columnId?: string;
4604
+ placeholder?: string;
4605
+ /** Accessible name. Default "Search". */
4606
+ label?: string;
4607
+ }
4608
+ interface DataTableRowLinkProps {
4609
+ href: string;
4610
+ className: string;
4611
+ children: ReactNode;
4612
+ 'data-row-link': '';
4613
+ }
4614
+ interface DataTableProps<TData, TValue = unknown> {
4615
+ /** TanStack column definitions. Layout options go in each column's `meta`. */
4616
+ columns: ColumnDef<TData, TValue>[];
4617
+ data: TData[];
4618
+ /** A stable id per row. Defaults to the row index, which breaks selection across re-sorts. */
4619
+ getRowId?: (row: TData, index: number) => string;
4620
+ /**
4621
+ * Accessible name, rendered as a visually hidden `<caption>`. Give the table either this or
4622
+ * `caption`: an unnamed table is announced as just "table".
4623
+ */
4624
+ label?: string;
4625
+ /** A visible caption above the table, which also names it. */
4626
+ caption?: ReactNode;
4627
+ /** A search box. `true` filters across every column; pass options to filter one column. */
4628
+ searchable?: boolean | DataTableSearchOptions;
4629
+ /** A "Columns" menu to show and hide columns. */
4630
+ columnVisibility?: boolean;
4631
+ /** Page the rows. Default `true`. */
4632
+ pagination?: boolean;
4633
+ /** Rows per page to start with. Default `10`. */
4634
+ pageSize?: number;
4635
+ /** Page sizes to offer. Default `[10, 20, 50]`; `[]` hides the selector. */
4636
+ pageSizeOptions?: number[];
4637
+ /**
4638
+ * Adds a leading checkbox column (unless the columns already include `createSelectColumn()`).
4639
+ * Pass a function to make only some rows selectable.
4640
+ */
4641
+ enableRowSelection?: boolean | ((row: TData) => boolean);
4642
+ /** The selected rows, every time the selection changes. */
4643
+ onSelectionChange?: (rows: TData[]) => void;
4644
+ /** Names a row for its selection checkbox and its card, e.g. `(s) => s.name`. */
4645
+ getRowLabel?: (row: TData) => string;
4646
+ /**
4647
+ * Whole-row activation for rows that open something in place (a drawer, a modal). Keyboard
4648
+ * users focus the row and press Enter or Space. Rows that navigate should use `getRowHref`.
4649
+ */
4650
+ onRowClick?: (row: TData) => void;
4651
+ /**
4652
+ * The row's destination. The title cell renders as a real link (so middle-click, open in a
4653
+ * new tab and screen-reader link lists all work) and a click anywhere else on the row follows
4654
+ * it. Takes precedence over `onRowClick`.
4655
+ */
4656
+ getRowHref?: (row: TData) => string;
4657
+ /** Renders the row link, e.g. through your router's `Link`. Default: a plain `<a>`. */
4658
+ renderRowLink?: (props: DataTableRowLinkProps) => ReactElement;
4659
+ /** A state tint per row, e.g. `(u) => (u.active ? undefined : 'muted')`. */
4660
+ getRowTone?: (row: TData) => TableRowTone | undefined;
4661
+ /** De-emphasise some rows, e.g. expired ones. */
4662
+ getRowDimmed?: (row: TData) => boolean;
4663
+ /** Shows skeleton rows in place of `data`. */
4664
+ loading?: boolean;
4665
+ /** How many skeleton rows. Default `5`. */
4666
+ loadingRows?: number;
4667
+ /** A load failure, shown in place of the rows. Takes precedence over loading and empty. */
4668
+ error?: ReactNode;
4669
+ /** Adds a Retry button to the error state. */
4670
+ onRetry?: () => void;
4671
+ /** Shown when there are no rows. A string, or your own node. Default "No results found." */
4672
+ empty?: ReactNode;
4673
+ /** Extra toolbar content beside the search box: filters, a primary action. */
4674
+ toolbar?: ReactNode;
4675
+ /** Extra content below the pager, e.g. a "refreshed 2 min ago" note. */
4676
+ footer?: ReactNode;
4677
+ density?: DataTableDensity;
4678
+ /** Vertical alignment of body cells. Use `top` for multi-line or ragged cells. */
4679
+ align?: DataTableAlign;
4680
+ /**
4681
+ * Render rows as cards when the table's own width is below the breakpoint. Default `true`
4682
+ * at 560px. `false` always renders a table.
4683
+ */
4684
+ responsive?: boolean | {
4685
+ breakpoint?: number;
4686
+ };
4687
+ /**
4688
+ * Cap the table's height (px number or any CSS length) and scroll the body inside it, with the
4689
+ * header row pinned. Works with horizontal scrolling and sticky columns, and caps the card list
4690
+ * in the responsive layout. The pattern of MUI's `TableContainer` + `stickyHeader` and Ant
4691
+ * Design's `scroll.y`. New in 0.7.1.
4692
+ */
4693
+ maxHeight?: number | string;
4694
+ manual?: DataTableManual;
4695
+ /** Controlled state. Any key you pass is controlled; the rest stay internal. */
4696
+ state?: Partial<DataTableState>;
4697
+ onSortingChange?: (sorting: SortingState) => void;
4698
+ onGlobalFilterChange?: (value: string) => void;
4699
+ onColumnFiltersChange?: (filters: ColumnFiltersState) => void;
4700
+ onPaginationChange?: (pagination: PaginationState) => void;
4701
+ onColumnVisibilityChange?: (visibility: VisibilityState) => void;
4702
+ onRowSelectionChange?: (selection: RowSelectionState) => void;
4703
+ /** Passed to `useReactTable` last, for anything this API does not cover. */
4704
+ tableOptions?: Partial<TableOptions<TData>>;
4705
+ /** Classes on the bordered wrapper. Layout only, e.g. margins. */
4706
+ className?: string;
4707
+ }
4708
+ /**
4709
+ * A data table on TanStack Table: sorting, search, pagination, column visibility and row
4710
+ * selection built in, client-side by default and server-driven through `manual`.
4711
+ *
4712
+ * <DataTable label="Suppliers" columns={columns} data={suppliers} searchable columnVisibility />
4713
+ *
4714
+ * `TData` and `TValue` are inferred from `columns`, so `cell: ({ row }) => row.original.name`
4715
+ * is typed. Layout options (width, alignment, card-mode role, sticky) go in each column's `meta`.
4716
+ *
4717
+ * Layout, from SCIC's table:
4718
+ * - `table-fixed` plus one `<colgroup>`, so one set of widths governs every row and cells can
4719
+ * ellipsise. A column is never narrower than its header.
4720
+ * - Whatever does not fit scrolls inside a focusable, named region with edge shadows and
4721
+ * optional sticky first or last columns.
4722
+ * - Below 560px of its own width (not the viewport's) each row becomes a card: the title column
4723
+ * leads, `status` and `actions` sit at the top, the rest become labelled values.
4724
+ *
4725
+ * Accessibility: a real `<table>` with a caption, `aria-sort` on sortable headers, `aria-busy`
4726
+ * while loading, a polite announcement of the result count after a search, keyboard row
4727
+ * activation, and named selection checkboxes.
4728
+ */
4729
+ declare function DataTable<TData, TValue = unknown>({ columns, data, getRowId, label, caption, searchable, columnVisibility: showColumnMenu, pagination: paginated, pageSize, pageSizeOptions, enableRowSelection, onSelectionChange, getRowLabel, onRowClick, getRowHref, renderRowLink, getRowTone, getRowDimmed, loading, loadingRows, error, onRetry, empty, toolbar, footer, density, align, responsive, maxHeight, manual, state, onSortingChange, onGlobalFilterChange, onColumnFiltersChange, onPaginationChange, onColumnVisibilityChange, onRowSelectionChange, tableOptions, className, }: DataTableProps<TData, TValue>): react.JSX.Element;
4730
+
4731
+ /**
4732
+ * Tracks an element's rendered content-box width. New in 0.7.0, from SCIC.
4733
+ *
4734
+ * Use this when a component must switch *structure*, not just styling, based on the space it
4735
+ * actually has, e.g. `DataTable` swapping table rows for cards. Viewport breakpoints lie there:
4736
+ * a docked drawer or a one-third-width detail panel shrinks a component without the viewport
4737
+ * changing.
4738
+ *
4739
+ * Returns `[ref, width]`. `width` is `undefined` until the first measurement, which happens in
4740
+ * a layout effect so the first paint already uses it. Attach `ref` to a node whose width does
4741
+ * NOT depend on the structure you switch (typically the component's outer wrapper), or the
4742
+ * switch becomes a feedback loop.
4743
+ */
4744
+ declare function useElementWidth<T extends HTMLElement = HTMLElement>(): [
4745
+ (node: T | null) => void,
4746
+ number | undefined
4747
+ ];
4748
+
3514
4749
  type InlineAlertTone = 'info' | 'warning' | 'danger' | 'positive';
3515
4750
  interface InlineAlertProps {
3516
4751
  tone: InlineAlertTone;
@@ -3571,6 +4806,35 @@ interface SpinnerProps extends HTMLAttributes<HTMLSpanElement> {
3571
4806
  */
3572
4807
  declare const Spinner: react.ForwardRefExoticComponent<SpinnerProps & react.RefAttributes<HTMLSpanElement>>;
3573
4808
 
4809
+ interface ErrorBoundaryProps {
4810
+ children: ReactNode;
4811
+ /** Shown in place of the children when they throw. Default a quiet "Something went wrong". */
4812
+ fallback?: ReactNode;
4813
+ /** Changing this resets the boundary. Use the identity of whatever is being rendered. */
4814
+ resetKey?: string;
4815
+ onError?: (error: Error, info: ErrorInfo) => void;
4816
+ }
4817
+ interface ErrorBoundaryState {
4818
+ error: Error | null;
4819
+ }
4820
+ /**
4821
+ * Stops one broken subtree from taking down the whole app. New in 0.7.0, from SCIC.
4822
+ *
4823
+ * React unmounts the entire root when a render throws with no boundary above it, so one widget
4824
+ * that trips over an unexpected API shape blanks the screen instead of one card. This is the
4825
+ * floor under that: everything outside the boundary keeps working.
4826
+ *
4827
+ * A class, because error boundaries can only be classes. The error is still logged: the
4828
+ * fallback deliberately says nothing technical, so the console is how the cause is found.
4829
+ */
4830
+ declare class ErrorBoundary extends Component<ErrorBoundaryProps, ErrorBoundaryState> {
4831
+ state: ErrorBoundaryState;
4832
+ static getDerivedStateFromError(error: Error): ErrorBoundaryState;
4833
+ componentDidUpdate(previous: ErrorBoundaryProps): void;
4834
+ componentDidCatch(error: Error, info: ErrorInfo): void;
4835
+ render(): string | number | boolean | Iterable<ReactNode> | react.JSX.Element | null | undefined;
4836
+ }
4837
+
3574
4838
  type SkeletonShape = 'line' | 'block' | 'circle';
3575
4839
  interface SkeletonProps extends HTMLAttributes<HTMLDivElement> {
3576
4840
  shape?: SkeletonShape;
@@ -3702,6 +4966,44 @@ interface QuickActionsBarProps {
3702
4966
  }
3703
4967
  declare function QuickActionsBar({ actions, active, onSelect, className }: QuickActionsBarProps): react.JSX.Element;
3704
4968
 
4969
+ /**
4970
+ * Presentational pieces of an AI chat transcript, ported from SCIC in 0.7.0. Markup only: the
4971
+ * conversation state and streaming stay in the app. SCIC's hard-coded hex colours are replaced
4972
+ * by tokens, so the bubbles follow dark mode.
4973
+ */
4974
+ interface AiAvatarProps {
4975
+ className?: string;
4976
+ /** The glyph. Default a chip, SCIC's assistant mark. */
4977
+ icon?: ReactNode;
4978
+ }
4979
+ /** The assistant's round mark, decorative. */
4980
+ declare function AiAvatar({ className, icon }: AiAvatarProps): react.JSX.Element;
4981
+ interface TypingIndicatorProps {
4982
+ /** What the assistant is doing, read aloud. Default "Assistant is typing". */
4983
+ label?: string;
4984
+ className?: string;
4985
+ }
4986
+ /**
4987
+ * "The assistant is working": an avatar, the label and three pulsing dots. A polite live region,
4988
+ * so a screen reader hears the label once rather than nothing. The dots stop under
4989
+ * `prefers-reduced-motion`.
4990
+ */
4991
+ declare function TypingIndicator({ label, className }: TypingIndicatorProps): react.JSX.Element;
4992
+ type ChatBubbleSender = 'user' | 'assistant';
4993
+ interface ChatBubbleProps {
4994
+ /**
4995
+ * Who wrote the message. Called `role` in SCIC; renamed so it cannot be mistaken for (or
4996
+ * linted as) an ARIA role.
4997
+ */
4998
+ sender: ChatBubbleSender;
4999
+ children: ReactNode;
5000
+ /** `assistant` only: the failed-turn palette, set as `data-state="failed"`. */
5001
+ failed?: boolean;
5002
+ className?: string;
5003
+ }
5004
+ /** One message. The user's sits right in a dark bubble; the assistant's spans the column. */
5005
+ declare function ChatBubble({ sender, children, failed, className }: ChatBubbleProps): react.JSX.Element;
5006
+
3705
5007
  /** Soft aurora atmosphere used by the public-facing screens (auth, event
3706
5008
  * onboarding) — mirrors AuroraBackground in pages/intelligence. Blobs are
3707
5009
  * corner-anchored so the effect scales from phones to kiosk displays.
@@ -3709,4 +5011,4 @@ declare function QuickActionsBar({ actions, active, onSelect, className }: Quick
3709
5011
  * with `relative`. */
3710
5012
  declare function AuroraBackdrop(): react.JSX.Element;
3711
5013
 
3712
- export { AIChatBar, type AIChatBarProps, AISuggestionChip, type AISuggestionChipProps, Accordion, AccordionContent, type AccordionContentProps, AccordionItem, type AccordionItemProps, type AccordionProps, AccordionTrigger, type AccordionTriggerProps, type AccordionType, AspectRatio, type AspectRatioProps, AuroraBackdrop, Avatar, AvatarBlock, type AvatarBlockProps, AvatarGroup, type AvatarGroupProps, type AvatarGroupSpacing, type AvatarImageProps, type AvatarInitialProps, type AvatarProps, type AvatarShape, type AvatarSize, Badge, type BadgeColor, type BadgeProps, type BadgeSize, type BadgeVariant, Banner, type BannerProps, type BannerVariant, BarChart, type BarChartOrientation, type BarChartProps, type BarChartSeries, type BarChartSize, Breadcrumb, BreadcrumbEllipsis, type BreadcrumbEllipsisProps, BreadcrumbItem, type BreadcrumbItemProps, type BreadcrumbProps, Button, ButtonGroup, type ButtonGroupAlign, type ButtonGroupItem, type ButtonGroupProps, type ButtonGroupVariant, type ButtonProps, type ButtonSize, type ButtonVariant, CHART_SEQUENCE, CHART_TONE, CHART_TRACK, COUNTRY_CODES, Calendar, type CalendarMode, type CalendarProps, Card, CardAction, type CardActionProps, CardBody, type CardBodyProps, CardDescription, type CardDescriptionProps, CardFooter, type CardFooterAlign, type CardFooterProps, CardHeader, type CardHeaderProps, type CardProps, type CardRadius, type CardSize, CardTitle, type CardTitleProps, type CardTone, Carousel, CarouselControls, type CarouselControlsProps, type CarouselProps, CarouselSlide, type CarouselSlideProps, CarouselViewport, type CarouselViewportProps, ChartLegend, type ChartLegendItem, type ChartLegendOrientation, type ChartLegendProps, type ChartTone, CheckIndicator, type CheckIndicatorProps, type CheckIndicatorStatus, Checkbox, type CheckboxProps, type CheckboxSize, type CheckedGroup, CheckedGroupList, type CheckedGroupListColumns, type CheckedGroupListProps, ChecklistRow, type ChecklistRowProps, type ChecklistRowState, Collapsible, CollapsibleContent, type CollapsibleContentProps, type CollapsibleProps, CollapsibleTrigger, type CollapsibleTriggerProps, type ColumnDef, Combobox, type ComboboxOption, type ComboboxProps, Command, type CommandItem, type CommandProps, ConfirmDialog, type ConfirmDialogProps, ContextMenu, MenuCheckboxItem as ContextMenuCheckboxItem, ContextMenuContent, type ContextMenuContentProps, MenuGroup as ContextMenuGroup, MenuItem as ContextMenuItem, MenuLabel as ContextMenuLabel, type ContextMenuProps, MenuRadioGroup as ContextMenuRadioGroup, MenuRadioItem as ContextMenuRadioItem, MenuSeparator as ContextMenuSeparator, MenuShortcut as ContextMenuShortcut, ContextMenuTrigger, type ContextMenuTriggerProps, ControlSizeProvider, type ControlSizeProviderProps, CountBadge, type CountBadgeProps, CountrySelect, type CountrySelectProps, DEFAULT_SCORE_THRESHOLDS, DataTable, type DataTableAlign, type DataTableDensity, type DataTableProps, DatePicker, type DatePickerProps, type DateRange, DetailGrid, type DetailGridColumns, type DetailGridProps, DetailItem, type DetailItemLayout, type DetailItemProps, type DetailItemSpan, DonutChart, type DonutChartProps, type DonutChartSize, type DonutSegment, Drawer, type DrawerProps, DropdownMenu, MenuCheckboxItem as DropdownMenuCheckboxItem, type MenuCheckboxItemProps as DropdownMenuCheckboxItemProps, DropdownMenuContent, type DropdownMenuContentProps, MenuGroup as DropdownMenuGroup, type MenuGroupProps as DropdownMenuGroupProps, MenuItem as DropdownMenuItem, type MenuItemProps as DropdownMenuItemProps, type MenuItemTone as DropdownMenuItemTone, MenuLabel as DropdownMenuLabel, type MenuLabelProps as DropdownMenuLabelProps, type DropdownMenuProps, MenuRadioGroup as DropdownMenuRadioGroup, type MenuRadioGroupProps as DropdownMenuRadioGroupProps, MenuRadioItem as DropdownMenuRadioItem, type MenuRadioItemProps as DropdownMenuRadioItemProps, MenuSeparator as DropdownMenuSeparator, type MenuSeparatorProps as DropdownMenuSeparatorProps, MenuShortcut as DropdownMenuShortcut, type MenuShortcutProps as DropdownMenuShortcutProps, DropdownMenuTrigger, type DropdownMenuTriggerProps, EmptyState, type EmptyStateProps, type EmptyStateSize, type EmptyStateVariant, EntityIconBadge, type EntityIconBadgeProps, type EntityIconBadgeSize, type EntityIconBadgeTone, EyebrowLabel, type EyebrowLabelProps, type EyebrowLabelVariant, Field, type FieldContextValue, FieldDescription, FieldError, FieldGroup, type FieldGroupProps, FieldHint, FieldLabel, type FieldLabelProps, FieldLegend, type FieldLegendProps, type FieldOrientation, type FieldProps, FieldSeparator, type FieldSeparatorProps, FieldSet, type FieldSetProps, type FieldTextProps, FileDropZone, type FileDropZoneProps, FileRow, type FileRowProps, FilterBar, type FilterBarProps, type FilterBarSize, FormCard, FormCardFooter, type FormCardFooterProps, FormCardHeader, type FormCardHeaderProps, Heading, HoverCard, type HoverCardProps, IconButton, type IconButtonProps, type IconButtonVariant, IconTextRow, type IconTextRowProps, InlineAlert, type InlineAlertProps, type InlineAlertTone, Input, InputControl, type InputControlProps, InputGroup, InputGroupAddon, type InputGroupAddonProps, type InputGroupAlign, InputGroupInput, type InputGroupInputProps, type InputGroupProps, InputGroupText, type InputGroupTextProps, InputOTP, type InputOTPMode, type InputOTPProps, type InputProps, type InputSize, Kbd, type KbdProps, type KbdSize, Label, type LabelProps, LegendDot, type LegendDotProps, type LegendDotShape, type LegendDotSize, ListRow, type ListRowDensity, type ListRowDivider, type ListRowProps, Menubar, MenuCheckboxItem as MenubarCheckboxItem, MenubarContent, type MenubarContentProps, MenuGroup as MenubarGroup, MenuItem as MenubarItem, MenuLabel as MenubarLabel, MenubarMenu, type MenubarMenuProps, type MenubarProps, MenuRadioGroup as MenubarRadioGroup, MenuRadioItem as MenubarRadioItem, MenuSeparator as MenubarSeparator, MenuShortcut as MenubarShortcut, MenubarTrigger, type MenubarTriggerProps, MiniBarChart, type MiniBarChartOrientation, type MiniBarChartProps, type MiniBarChartSize, Modal, ModalBody, type ModalBodyProps, ModalDescription, type ModalDescriptionProps, ModalFooter, type ModalFooterAlign, type ModalFooterProps, ModalHeader, type ModalHeaderProps, type ModalProps, type ModalSize, ModalTitle, type ModalTitleProps, type ModalTone, MultiSelectCard, type MultiSelectCardProps, type MultiSelectCardSize, NavItem, type NavItemProps, type NavItemSize, type NavItemVariant, NavigationMenu, NavigationMenuItem, type NavigationMenuItemProps, type NavigationMenuOrientation, type NavigationMenuProps, type NavigationMenuVariant, NoteConfirmModal, type NoteConfirmModalProps, NumberedList, type NumberedListGap, type NumberedListItem, type NumberedListProps, OVERLAY_SCRIM, PageHeading, type PageHeadingProps, type PageHeadingSize, PageToolbar, type PageToolbarProps, type PageToolbarSize, Pagination, type PaginationProps, type PaginationType, PasswordInput, type PasswordInputProps, Popover, PopoverContent, type PopoverContentProps, type PopoverProps, PopoverTrigger, type PopoverTriggerProps, Portal, type PortalProps, ProgressBar, type ProgressBarProps, type ProgressBarSize, type ProgressBarTone, type QuickAction, QuickActionsBar, type QuickActionsBarProps, ROLE_COMBO_OPTIONS, RadialGauge, type RadialGaugeProps, type RadialGaugeSize, Radio, RadioGroup, type RadioGroupOrientation, type RadioGroupProps, type RadioProps, Resizable, type ResizableDirection, ResizableHandle, type ResizableHandleProps, ResizablePanel, type ResizablePanelProps, type ResizableProps, RoleBadge, type RoleBadgeProps, type RoleBadgeTone, RoleComboBox, type RoleComboBoxProps, type RoleOption, SCROLLBAR_CLASSES, type ScoreDirection, type ScoreRampTone, type ScoreThresholds, type ScoreTone, ScoreValue, type ScoreValueProps, type ScoreValueSize, type ScoreValueTone, type ScoreValueWeight, ScoredRow, type ScoredRowAlign, type ScoredRowGap, type ScoredRowProps, ScrollArea, type ScrollAreaAxis, type ScrollAreaProps, SearchInput, type SearchInputProps, SegmentedControl, type SegmentedControlOption, type SegmentedControlProps, Select, SelectControl, type SelectControlProps, type SelectOption, type SelectOptionGroup, type SelectProps, Separator, type SeparatorOrientation, type SeparatorProps, Skeleton, type SkeletonProps, type SkeletonShape, Slider, type SliderProps, Sparkline, type SparklineProps, type SparklineSize, type SparklineVariant, Spinner, type SpinnerProps, type SpinnerSize, StatNumber, type StatNumberProps, type StatNumberSize, type StatNumberWeight, StatTile, type StatTileProps, StatusBadge, type StatusBadgeProps, type StatusBadgeSize, StatusChip, type StatusChipProps, StatusDot, type StatusDotProps, type StatusDotTone, type StatusTone, type StepItem, type StepStatus, Stepper, type StepperProps, type StepperSize, StepsList, type StepsListProps, Subheading, Subtitle, Switch, type SwitchProps, type SwitchSize, type TabItem, Table, TableBody, TableCaption, type TableCaptionProps, TableCell, TableCellBadge, type TableCellBadgeProps, TableCellLeadText, type TableCellLeadTextProps, TableCellProgress, type TableCellProgressProps, type TableCellProps, type TableCellSize, TableCellText, type TableCellTextProps, type TableDensity, TableFooter, TableHead, type TableHeadProps, TableHeader, type TableProps, TableRow, type TableRowProps, type TableSortDirection, Tabs, type TabsActivation, type TabsOrientation, TabsPanel, type TabsPanelProps, type TabsProps, type TabsSize, type TabsVariant, TagPill, type TagPillProps, type TagPillTone, Text, TextCode, TextEmphasis, TextLink, type TextLinkProps, TextList, type TextListDensity, TextListItem, type TextListItemProps, type TextListProps, type TextListVariant, type TextProps, TextSmall, TextStrong, TextTiny, Textarea, TextareaControl, type TextareaControlProps, type TextareaProps, TileGrid, type TileGridBreakpoint, type TileGridColumns, type TileGridProps, TimeZoneSelect, type TimeZoneSelectProps, TitleHero, TitlePage, type ToastOptions, type ToastRecord, type ToastTone, Toaster, type ToasterPosition, type ToasterProps, Toggle, ToggleGroup, ToggleGroupItem, type ToggleGroupItemProps, type ToggleGroupProps, type ToggleGroupType, type ToggleProps, type ToggleSize, type ToggleVariant, Tooltip, type TooltipProps, TrailChip, type TrailChipProps, type TreeItemState, TreeView, type TreeViewProps, type TreeViewSize, type TrendDirection, TrendLabel, type TrendLabelProps, type TrendLabelSize, type TrendLabelWeight, type UserAccountStatus, UserStatusPill, type UserStatusPillProps, WidgetFooter, type WidgetFooterProps, WidgetHeader, type WidgetHeaderEyebrowVariant, type WidgetHeaderProps, WidgetTitle, type WidgetTitleProps, type WidgetTitleSize, cn, countryOptions, currentZoneName, getScoreTone, paginationRange, resolveChartColor, tabId, tabPanelId, timeZoneOffset, timeZoneOptions, useControlSize, useFieldContext, useFieldControl, useOverlayDismiss, useToast };
5014
+ export { AIChatBar, type AIChatBarProps, AISuggestionChip, type AISuggestionChipProps, AccessibleIcon, type AccessibleIconProps, Accordion, AccordionContent, type AccordionContentProps, AccordionItem, type AccordionItemProps, type AccordionProps, AccordionTrigger, type AccordionTriggerProps, type AccordionType, AiAvatar, type AiAvatarProps, AspectRatio, type AspectRatioProps, AuroraBackdrop, Avatar, AvatarBlock, type AvatarBlockProps, AvatarGroup, type AvatarGroupProps, type AvatarGroupSpacing, type AvatarImageProps, type AvatarInitialProps, type AvatarProps, type AvatarShape, type AvatarSize, Badge, type BadgeColor, type BadgeProps, type BadgeSize, type BadgeVariant, Banner, type BannerProps, type BannerVariant, BarChart, type BarChartOrientation, type BarChartProps, type BarChartSeries, type BarChartSize, Blockquote, type BlockquoteProps, Box, type BoxProps, Breadcrumb, BreadcrumbEllipsis, type BreadcrumbEllipsisProps, BreadcrumbItem, type BreadcrumbItemProps, type BreadcrumbProps, Button, ButtonGroup, type ButtonGroupAlign, type ButtonGroupItem, type ButtonGroupProps, type ButtonGroupVariant, type ButtonProps, type ButtonSize, type ButtonVariant, CHART_SEQUENCE, CHART_TONE, CHART_TRACK, COL_SPAN, COL_SPAN_BY_TIER, COUNTRY_CODES, Calendar, type CalendarMode, type CalendarProps, Card, CardAction, type CardActionProps, CardBody, type CardBodyProps, CardDescription, type CardDescriptionProps, CardFooter, type CardFooterAlign, type CardFooterProps, CardHeader, type CardHeaderProps, type CardProps, type CardRadius, type CardSize, CardTitle, type CardTitleProps, type CardTone, Carousel, CarouselControls, type CarouselControlsProps, type CarouselProps, CarouselSlide, type CarouselSlideProps, CarouselViewport, type CarouselViewportProps, ChartLegend, type ChartLegendItem, type ChartLegendOrientation, type ChartLegendProps, type ChartTone, ChatBubble, type ChatBubbleProps, type ChatBubbleSender, CheckIndicator, type CheckIndicatorProps, type CheckIndicatorStatus, Checkbox, CheckboxGroup, CheckboxGroupItem, type CheckboxGroupItemProps, type CheckboxGroupProps, type CheckboxProps, type CheckboxSize, type CheckedGroup, CheckedGroupList, type CheckedGroupListColumns, type CheckedGroupListProps, ChecklistRow, type ChecklistRowProps, type ChecklistRowState, type ColSize, Collapsible, CollapsibleContent, type CollapsibleContentProps, type CollapsibleProps, CollapsibleTrigger, type CollapsibleTriggerProps, type ColumnMobileRole, Combobox, type ComboboxOption, type ComboboxProps, Command, type CommandItem, type CommandProps, ConfirmDialog, type ConfirmDialogProps, Container, type ContainerProps, type ContainerSize, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, type ContextMenuContentProps, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, type ContextMenuProps, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, type ContextMenuTriggerProps, ControlSizeProvider, type ControlSizeProviderProps, CopyButton, type CopyButtonProps, CountBadge, type CountBadgeProps, CountrySelect, type CountrySelectProps, type CreateSelectColumnOptions, DEFAULT_SCORE_THRESHOLDS, DataTable, type DataTableAlign, type DataTableColumnAlign, DataTableColumnHeader, type DataTableColumnHeaderProps, type DataTableDensity, type DataTableManual, DataTablePagination, type DataTablePaginationProps, type DataTableProps, type DataTableRowLinkProps, type DataTableSearchOptions, type DataTableState, DataTableViewOptions, type DataTableViewOptionsProps, DatePicker, type DatePickerProps, type DateRange, DescriptionItem, type DescriptionItemProps, DescriptionList, type DescriptionListProps, DetailGrid, type DetailGridColumns, type DetailGridProps, DetailItem, type DetailItemLayout, type DetailItemProps, type DetailItemSpan, DonutChart, type DonutChartProps, type DonutChartSize, type DonutSegment, Drawer, DrawerBody, type DrawerBodyProps, DrawerClose, type DrawerCloseProps, DrawerDescription, type DrawerDescriptionProps, DrawerFooter, type DrawerFooterAlign, type DrawerFooterProps, DrawerHeader, type DrawerHeaderProps, type DrawerProps, type DrawerSide, DrawerTitle, type DrawerTitleProps, DrawerTrigger, type DrawerTriggerProps, DropdownMenu, DropdownMenuCheckboxItem, type MenuCheckboxItemProps as DropdownMenuCheckboxItemProps, DropdownMenuContent, type DropdownMenuContentProps, DropdownMenuGroup, type MenuGroupProps as DropdownMenuGroupProps, DropdownMenuItem, type MenuItemProps as DropdownMenuItemProps, type MenuItemTone as DropdownMenuItemTone, DropdownMenuLabel, type MenuLabelProps as DropdownMenuLabelProps, type DropdownMenuProps, DropdownMenuRadioGroup, type MenuRadioGroupProps as DropdownMenuRadioGroupProps, DropdownMenuRadioItem, type MenuRadioItemProps as DropdownMenuRadioItemProps, DropdownMenuSeparator, type MenuSeparatorProps as DropdownMenuSeparatorProps, DropdownMenuShortcut, type MenuShortcutProps as DropdownMenuShortcutProps, DropdownMenuSub, DropdownMenuSubContent, type MenuSubContentProps as DropdownMenuSubContentProps, type MenuSubProps as DropdownMenuSubProps, DropdownMenuSubTrigger, type MenuSubTriggerProps as DropdownMenuSubTriggerProps, DropdownMenuTrigger, type DropdownMenuTriggerProps, EmailText, EmptyState, type EmptyStateProps, type EmptyStateSize, type EmptyStateVariant, EntityIconBadge, type EntityIconBadgeProps, type EntityIconBadgeSize, type EntityIconBadgeTone, ErrorBoundary, type ErrorBoundaryProps, EyebrowLabel, type EyebrowLabelProps, type EyebrowLabelVariant, FOCUS_RING, FOCUS_RING_INSET, Field, type FieldContextValue, FieldDescription, FieldError, FieldGroup, type FieldGroupProps, FieldHint, FieldLabel, type FieldLabelProps, FieldLegend, type FieldLegendProps, type FieldOrientation, type FieldProps, FieldSeparator, type FieldSeparatorProps, FieldSet, type FieldSetProps, type FieldTextProps, FileDropZone, type FileDropZoneProps, FileRow, type FileRowProps, FilterBar, type FilterBarProps, type FilterBarSize, Flex, type FlexAlign, type FlexDirection, type FlexJustify, type FlexProps, FormCard, FormCardFooter, type FormCardFooterProps, FormCardHeader, type FormCardHeaderProps, type FullscreenStacking, FullscreenSurface, type FullscreenSurfaceProps, GRID_TIERS, Grid, type GridBreakpoint, type GridColumnCount, type GridProps, type GridTier, HEIGHT_CLASS, HEIGHT_PX, Heading, HoverCard, type HoverCardProps, IconButton, type IconButtonProps, type IconButtonVariant, IconTextRow, type IconTextRowProps, InlineAlert, type InlineAlertProps, type InlineAlertTone, Input, InputControl, type InputControlProps, InputGroup, InputGroupAddon, type InputGroupAddonProps, type InputGroupAlign, InputGroupInput, type InputGroupInputProps, type InputGroupProps, InputGroupText, type InputGroupTextProps, InputOTP, type InputOTPMode, type InputOTPProps, type InputProps, type InputSize, Kbd, type KbdProps, type KbdSize, Label, type LabelProps, LegendDot, type LegendDotProps, type LegendDotShape, type LegendDotSize, ListRow, type ListRowDensity, type ListRowDivider, type ListRowProps, Menubar, MenubarCheckboxItem, MenubarContent, type MenubarContentProps, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, type MenubarMenuProps, type MenubarProps, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, type MenubarTriggerProps, MiniBarChart, type MiniBarChartOrientation, type MiniBarChartProps, type MiniBarChartSize, Modal, ModalBody, type ModalBodyProps, ModalClose, type ModalCloseProps, ModalDescription, type ModalDescriptionProps, ModalFooter, type ModalFooterAlign, type ModalFooterProps, ModalHeader, type ModalHeaderProps, type ModalProps, type ModalSize, ModalTitle, type ModalTitleProps, type ModalTone, ModalTrigger, type ModalTriggerProps, MultiSelectCard, type MultiSelectCardProps, type MultiSelectCardSize, NavItem, type NavItemProps, type NavItemSize, type NavItemVariant, NavigationMenu, NavigationMenuItem, type NavigationMenuItemProps, type NavigationMenuOrientation, type NavigationMenuProps, type NavigationMenuVariant, NoteConfirmModal, type NoteConfirmModalProps, NumberedList, type NumberedListGap, type NumberedListItem, type NumberedListProps, OVERLAY_SCRIM, PageHeading, type PageHeadingProps, type PageHeadingSize, PageToolbar, type PageToolbarProps, type PageToolbarSize, Pagination, PaginationBar, type PaginationBarProps, type PaginationProps, type PaginationType, PasswordInput, type PasswordInputProps, Popover, PopoverAnchor, PopoverClose, PopoverContent, type PopoverContentProps, type PopoverProps, PopoverTrigger, type PopoverTriggerProps, Portal, PortalContainerProvider, type PortalProps, ProgressBar, type ProgressBarProps, type ProgressBarSize, type ProgressBarTone, type QuickAction, QuickActionsBar, type QuickActionsBarProps, Quote, ROLE_COMBO_OPTIONS, RadialGauge, type RadialGaugeProps, type RadialGaugeSize, Radio, RadioCards, RadioCardsItem, type RadioCardsItemProps, type RadioCardsProps, type RadioCardsSize, RadioGroup, type RadioGroupOrientation, type RadioGroupProps, type RadioProps, Resizable, type ResizableDirection, ResizableHandle, type ResizableHandleProps, ResizablePanel, type ResizablePanelProps, type ResizableProps, RoleBadge, type RoleBadgeProps, type RoleBadgeTone, RoleComboBox, type RoleComboBoxProps, type RoleOption, SCROLLBAR_CLASSES, SELECT_COLUMN_ID, type ScoreDirection, type ScoreRampTone, type ScoreThresholds, type ScoreTone, ScoreValue, type ScoreValueProps, type ScoreValueSize, type ScoreValueTone, type ScoreValueWeight, ScoredRow, type ScoredRowAlign, type ScoredRowGap, type ScoredRowProps, Scrim, type ScrimProps, ScrollArea, type ScrollAreaAxis, type ScrollAreaProps, SearchInput, type SearchInputProps, Section, type SectionProps, type SectionSize, SegmentedControl, type SegmentedControlOption, type SegmentedControlProps, Select, SelectControl, type SelectControlProps, type SelectOption, type SelectOptionGroup, type SelectProps, Separator, type SeparatorOrientation, type SeparatorProps, Skeleton, type SkeletonProps, type SkeletonShape, Slider, type SliderProps, Slot, type SlotProps, type SpaceToken, Sparkline, type SparklineProps, type SparklineSize, type SparklineVariant, Spinner, type SpinnerProps, type SpinnerSize, StatNumber, type StatNumberProps, type StatNumberSize, type StatNumberWeight, StatTile, type StatTileProps, StatusBadge, type StatusBadgeProps, type StatusBadgeSize, StatusChip, type StatusChipProps, StatusDot, type StatusDotProps, type StatusDotTone, type StatusTone, type StepItem, type StepStatus, Stepper, type StepperProps, type StepperSize, StepsList, type StepsListProps, Subheading, Subtitle, Switch, type SwitchProps, type SwitchSize, TIER_COLS, TIER_MIN_PX, type TabItem, Table, TableBody, TableCaption, type TableCaptionProps, TableCell, TableCellBadge, type TableCellBadgeProps, TableCellLeadText, type TableCellLeadTextProps, TableCellProgress, type TableCellProgressProps, type TableCellProps, type TableCellSize, TableCellText, type TableCellTextProps, type TableDensity, TableFooter, TableHead, type TableHeadProps, TableHeader, type TableProps, TableRow, type TableRowProps, type TableRowTone, type TableSortDirection, Tabs, type TabsActivation, TabsContent, type TabsContentProps, TabsList, type TabsListProps, type TabsOrientation, TabsPanel, type TabsPanelProps, type TabsProps, type TabsRootProps, type TabsSize, TabsTrigger, type TabsTriggerProps, type TabsVariant, TagInput, type TagInputParseResult, type TagInputProps, TagPill, type TagPillProps, type TagPillTone, Text, TextCode, TextEmphasis, TextLink, type TextLinkProps, TextList, type TextListDensity, TextListItem, type TextListItemProps, type TextListProps, type TextListVariant, type TextProps, TextSmall, TextStrong, TextTiny, type TextTone, Textarea, TextareaControl, type TextareaControlProps, type TextareaProps, TileGrid, type TileGridBreakpoint, type TileGridColumns, type TileGridProps, TimeZoneSelect, type TimeZoneSelectProps, TitleHero, TitlePage, type ToastOptions, type ToastRecord, type ToastTone, Toaster, type ToasterPosition, type ToasterProps, Toggle, ToggleGroup, ToggleGroupItem, type ToggleGroupItemProps, type ToggleGroupProps, type ToggleGroupType, type ToggleProps, type ToggleSize, type ToggleVariant, Tooltip, type TooltipProps, TrailChip, type TrailChipProps, type TreeItemState, TreeView, type TreeViewProps, type TreeViewSize, type TrendDirection, TrendLabel, type TrendLabelProps, type TrendLabelSize, type TrendLabelWeight, TypingIndicator, type TypingIndicatorProps, type UseFilePicker, type UseFilePickerOptions, type UseWidthTierOptions, type UseWidthTierResult, type UserAccountStatus, UserStatusPill, type UserStatusPillProps, VisuallyHidden, type VisuallyHiddenProps, WidgetFooter, type WidgetFooterProps, WidgetGrid, WidgetGridItem, type WidgetGridItemProps, type WidgetGridProps, WidgetGridRow, type WidgetGridRowProps, WidgetHeader, type WidgetHeaderEyebrowVariant, type WidgetHeaderProps, type WidgetHeight, WidgetTitle, type WidgetTitleProps, type WidgetTitleSize, cn, colsFor, composeRefs, countryOptions, createSelectColumn, currentZoneName, formatFileSize, getScoreTone, nextTier, paginationRange, quantizeWidth, resolveChartColor, slotWidthPx, tabId, tabPanelId, tierForWidth, timeZoneOffset, timeZoneOptions, useControlSize, useElementWidth, useFieldContext, useFieldControl, useFilePicker, useOverlayDismiss, usePortalContainer, useToast, useWidthTier };