@zovaris/sephiro 0.6.1 → 0.8.0

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.ts CHANGED
@@ -1,318 +1,1203 @@
1
- import * as react from 'react';
2
- import { HTMLAttributes, ButtonHTMLAttributes, InputHTMLAttributes, TextareaHTMLAttributes, TableHTMLAttributes } from 'react';
3
- import { ExternalToast, ToasterProps } from 'sonner';
4
- export { toast } from 'sonner';
5
-
1
+ import { ButtonHTMLAttributes, HTMLAttributes, InputHTMLAttributes, RefObject, TableHTMLAttributes, TextareaHTMLAttributes, TimeHTMLAttributes, useLayoutEffect } from "react";
2
+ import { ExternalToast, ToasterProps, toast } from "sonner";
3
+ //#region src/atoms/AnimatedNumber/index.d.ts
4
+ type AnimatedNumberProps = Omit<HTMLAttributes<HTMLSpanElement>, "children"> & {
5
+ value: number;
6
+ from?: number;
7
+ duration?: number;
8
+ format?: (value: number) => string;
9
+ };
10
+ export declare function AnimatedNumber({ value, from, duration, format, className, ...props }: AnimatedNumberProps): import("react").JSX.Element;
11
+ //#endregion
12
+ //#region src/lib/control.d.ts
13
+ type ControlSize = "sm" | "md" | "lg";
14
+ //#endregion
15
+ //#region src/atoms/Avatar/index.d.ts
16
+ type AvatarStatus = "online" | "offline" | "busy" | "away";
17
+ type AvatarProps = Omit<HTMLAttributes<HTMLSpanElement>, "children"> & {
18
+ /** Image URL. Falls back to `name` initials when it fails to load. */
19
+ src?: string;
20
+ name?: string;
21
+ size?: ControlSize;
22
+ status?: AvatarStatus;
23
+ };
24
+ export declare function Avatar({ src, name, size, status, className, ...props }: AvatarProps): import("react").JSX.Element;
25
+ //#endregion
26
+ //#region src/lib/node.d.ts
6
27
  type RenderableElement = {
7
- type: any;
8
- props: any;
9
- key?: any;
28
+ type: any;
29
+ props: any;
30
+ key?: any;
10
31
  };
11
32
  type Renderable = string | number | boolean | null | undefined | Iterable<Renderable> | RenderableElement;
12
-
13
- type ControlSize = "sm" | "md" | "lg";
14
-
33
+ //#endregion
34
+ //#region src/atoms/Badge/index.d.ts
15
35
  type BadgeProps = Omit<HTMLAttributes<HTMLSpanElement>, "children"> & {
16
- variant?: "neutral" | "accent" | "success" | "warning" | "danger";
17
- size?: ControlSize;
18
- children?: Renderable;
36
+ variant?: "neutral" | "accent" | "success" | "warning" | "danger";
37
+ size?: ControlSize;
38
+ children?: Renderable;
19
39
  };
20
- declare function Badge({ variant, size, className, children, ...props }: BadgeProps): react.JSX.Element;
21
-
40
+ export declare function Badge({ variant, size, className, children, ...props }: BadgeProps): import("react").JSX.Element;
41
+ //#endregion
42
+ //#region src/atoms/Button/index.d.ts
22
43
  type ButtonProps = Omit<ButtonHTMLAttributes<HTMLButtonElement>, "children"> & {
23
- variant?: "primary" | "secondary" | "quiet";
24
- size?: ControlSize;
25
- loading?: boolean;
26
- children?: Renderable;
44
+ variant?: "primary" | "secondary" | "quiet";
45
+ size?: ControlSize;
46
+ loading?: boolean;
47
+ children?: Renderable;
27
48
  };
28
- declare function Button({ variant, size, loading, disabled, className, type, children, "aria-busy": ariaBusy, ...props }: ButtonProps): react.JSX.Element;
29
-
49
+ export declare function Button({ variant, size, loading, disabled, className, type, children, onClick, "aria-busy": ariaBusy, "aria-disabled": ariaDisabled, ...props }: ButtonProps): import("react").JSX.Element;
50
+ //#endregion
51
+ //#region src/atoms/Checkbox/index.d.ts
30
52
  type CheckboxProps = Omit<InputHTMLAttributes<HTMLInputElement>, "size"> & {
31
- label?: Renderable;
32
- size?: ControlSize;
33
- invalid?: boolean;
53
+ label?: Renderable;
54
+ size?: ControlSize;
55
+ invalid?: boolean;
34
56
  };
35
- declare function Checkbox({ label, size, invalid, className, ...props }: CheckboxProps): react.JSX.Element;
36
-
57
+ export declare function Checkbox({ label, size, invalid, className, ...props }: CheckboxProps): import("react").JSX.Element;
58
+ //#endregion
59
+ //#region src/atoms/IconButton/index.d.ts
37
60
  type IconButtonProps = Omit<ButtonHTMLAttributes<HTMLButtonElement>, "children"> & {
38
- icon: Renderable;
39
- label: string;
40
- size?: ControlSize;
41
- variant?: "ghost" | "solid" | "outline";
42
- loading?: boolean;
43
- };
44
- declare function IconButton({ icon, label, size, variant, loading, disabled, className, type, ...props }: IconButtonProps): react.JSX.Element;
45
-
61
+ icon: Renderable;
62
+ label: string;
63
+ size?: ControlSize;
64
+ variant?: "ghost" | "solid" | "outline";
65
+ loading?: boolean;
66
+ };
67
+ export declare function IconButton({ icon, label, size, variant, loading, disabled, className, type, onClick, ...props }: IconButtonProps): import("react").JSX.Element;
68
+ //#endregion
69
+ //#region src/atoms/Input/index.d.ts
46
70
  type InputProps = Omit<InputHTMLAttributes<HTMLInputElement>, "size"> & {
47
- invalid?: boolean;
48
- size?: ControlSize;
71
+ invalid?: boolean;
72
+ size?: ControlSize;
73
+ };
74
+ export declare function Input({ invalid, size, className, "aria-invalid": ariaInvalid, ...props }: InputProps): import("react").JSX.Element;
75
+ //#endregion
76
+ //#region src/atoms/Kbd/index.d.ts
77
+ type KbdProps = {
78
+ /**
79
+ * Key caps to render. An array draws one cap per entry (`["⌘", "K"]`);
80
+ * a single value draws one cap (`"Esc"`).
81
+ */
82
+ keys: Renderable;
83
+ className?: string;
49
84
  };
50
- declare function Input({ invalid, size, className, "aria-invalid": ariaInvalid, ...props }: InputProps): react.JSX.Element;
51
-
85
+ export declare function Kbd({ keys, className }: KbdProps): import("react").JSX.Element;
86
+ //#endregion
87
+ //#region src/atoms/Progress/index.d.ts
88
+ type ProgressProps = Omit<HTMLAttributes<HTMLDivElement>, "children"> & {
89
+ /** Completion from 0 to 100. Omit it for the indeterminate sweep. */
90
+ value?: number;
91
+ label?: string;
92
+ size?: ControlSize;
93
+ };
94
+ export declare function Progress({ value, label, size, className, ...props }: ProgressProps): import("react").JSX.Element;
95
+ //#endregion
96
+ //#region src/atoms/ScrollArea/index.d.ts
97
+ type ScrollAreaProps = Omit<HTMLAttributes<HTMLDivElement>, "children"> & {
98
+ orientation?: "vertical" | "horizontal" | "both";
99
+ children?: Renderable;
100
+ };
101
+ export declare function ScrollArea({ orientation, className, children, ...props }: ScrollAreaProps): import("react").JSX.Element;
102
+ //#endregion
103
+ //#region src/atoms/Separator/index.d.ts
52
104
  type SeparatorProps = Omit<HTMLAttributes<HTMLHRElement>, "children"> & {
53
- orientation?: "horizontal" | "vertical";
54
- decorative?: boolean;
105
+ orientation?: "horizontal" | "vertical";
106
+ decorative?: boolean;
55
107
  };
56
- declare function Separator({ orientation, decorative, className, ...props }: SeparatorProps): react.JSX.Element;
57
-
108
+ export declare function Separator({ orientation, decorative, className, ...props }: SeparatorProps): import("react").JSX.Element;
109
+ //#endregion
110
+ //#region src/atoms/Skeleton/index.d.ts
58
111
  type SkeletonProps = HTMLAttributes<HTMLSpanElement> & {
59
- width?: string | number;
60
- height?: string | number;
112
+ width?: string | number;
113
+ height?: string | number;
61
114
  };
62
- declare function Skeleton({ width, height, className, style, "aria-label": ariaLabel, ...props }: SkeletonProps): react.JSX.Element;
63
-
115
+ export declare function Skeleton({ width, height, className, style, "aria-label": ariaLabel, ...props }: SkeletonProps): import("react").JSX.Element;
116
+ //#endregion
117
+ //#region src/atoms/Slider/index.d.ts
64
118
  type SliderProps = Omit<InputHTMLAttributes<HTMLInputElement>, "size" | "type" | "value" | "defaultValue" | "onChange" | "children" | "min" | "max" | "step"> & {
65
- value: number;
66
- onValueChange: (value: number) => void;
67
- label: Renderable;
68
- min?: number;
69
- max?: number;
70
- step?: number;
71
- size?: ControlSize;
72
- valueLabel?: Renderable;
73
- invalid?: boolean;
74
- };
75
- declare function Slider({ value, onValueChange, label, min, max, step, size, valueLabel, invalid, className, disabled, style, id, "aria-label": ariaLabel, "aria-valuetext": ariaValueText, "aria-invalid": ariaInvalid, ...props }: SliderProps): react.JSX.Element;
76
-
119
+ value: number;
120
+ onValueChange: (value: number) => void;
121
+ label: Renderable;
122
+ min?: number;
123
+ max?: number;
124
+ step?: number;
125
+ size?: ControlSize;
126
+ valueLabel?: Renderable;
127
+ invalid?: boolean;
128
+ };
129
+ export declare function Slider({ value, onValueChange, label, min, max, step, size, valueLabel, invalid, className, disabled, style, id, "aria-label": ariaLabel, "aria-valuetext": ariaValueText, "aria-invalid": ariaInvalid, ...props }: SliderProps): import("react").JSX.Element;
130
+ //#endregion
131
+ //#region src/atoms/Spinner/index.d.ts
77
132
  type SpinnerProps = HTMLAttributes<HTMLSpanElement> & {
78
- size?: ControlSize;
79
- label?: string;
133
+ size?: ControlSize;
134
+ label?: string;
80
135
  };
81
- declare function Spinner({ size, label, className, ...props }: SpinnerProps): react.JSX.Element;
82
-
136
+ export declare function Spinner({ size, label, className, ...props }: SpinnerProps): import("react").JSX.Element;
137
+ //#endregion
138
+ //#region src/atoms/Surface/index.d.ts
83
139
  type SurfaceProps = Omit<HTMLAttributes<HTMLDivElement>, "children"> & {
84
- children?: Renderable;
85
- tone?: "base" | "elevated" | "raised";
86
- padding?: "none" | "sm" | "md" | "lg";
140
+ children?: Renderable;
141
+ tone?: "base" | "elevated" | "raised";
142
+ padding?: "none" | "sm" | "md" | "lg";
87
143
  };
88
- declare function Surface({ tone, padding, className, children, ...props }: SurfaceProps): react.JSX.Element;
89
-
144
+ export declare function Surface({ tone, padding, className, children, ...props }: SurfaceProps): import("react").JSX.Element;
145
+ //#endregion
146
+ //#region src/atoms/Textarea/index.d.ts
90
147
  type TextareaProps = TextareaHTMLAttributes<HTMLTextAreaElement> & {
91
- invalid?: boolean;
92
- size?: ControlSize;
148
+ invalid?: boolean;
149
+ size?: ControlSize;
93
150
  };
94
- declare function Textarea({ invalid, size, className, "aria-invalid": ariaInvalid, ...props }: TextareaProps): react.JSX.Element;
95
-
151
+ export declare function Textarea({ invalid, size, className, "aria-invalid": ariaInvalid, ...props }: TextareaProps): import("react").JSX.Element;
152
+ //#endregion
153
+ //#region src/atoms/Toggle/index.d.ts
96
154
  type ToggleProps = Omit<ButtonHTMLAttributes<HTMLButtonElement>, "onChange" | "onClick"> & {
97
- checked: boolean;
98
- onCheckedChange: (checked: boolean) => void;
99
- label: string;
100
- size?: ControlSize;
101
- onClick?: (event: {
102
- preventDefault(): void;
103
- }) => void;
104
- };
105
- declare function Toggle({ checked, onCheckedChange, label, className, disabled, onClick, size, "aria-checked": ariaChecked, "aria-label": ariaLabel, ...props }: ToggleProps): react.JSX.Element;
106
-
155
+ checked: boolean;
156
+ onCheckedChange: (checked: boolean) => void;
157
+ label: string;
158
+ size?: ControlSize;
159
+ onClick?: (event: {
160
+ preventDefault(): void;
161
+ }) => void;
162
+ };
163
+ export declare function Toggle({ checked, onCheckedChange, label, className, disabled, onClick, size, "aria-checked": ariaChecked, "aria-label": ariaLabel, ...props }: ToggleProps): import("react").JSX.Element;
164
+ //#endregion
165
+ //#region src/lib/presence.d.ts
166
+ type MotionSpeed = "fast" | "normal" | "slow";
167
+ /** Parses a CSS time string ("180ms", "0.18s", "0ms") into milliseconds. */
168
+ export declare function parseDurationMs(value: string): number;
169
+ /**
170
+ * Reads the motion token in effect for an element, honouring theme
171
+ * overrides, `prefers-reduced-motion`, and `data-sephiro-motion="off"`.
172
+ * Returns 0 when there is nothing to wait for.
173
+ */
174
+ export declare function motionDurationMs(element: HTMLElement | null, speed: MotionSpeed): number;
175
+ type Presence<E extends HTMLElement = HTMLElement> = {
176
+ /** Keep rendering the overlay while its exit animation plays. */
177
+ present: boolean;
178
+ /** True once the overlay has begun leaving; drive exit styles with it. */
179
+ leaving: boolean;
180
+ /** `open` while settled, `closed` once leaving. */
181
+ state: "open" | "closed";
182
+ /** Attach to the overlay element so its exit duration can be measured. */
183
+ ref: RefObject<E | null>;
184
+ };
185
+ /**
186
+ * Holds an overlay mounted for exactly as long as its exit animation runs.
187
+ *
188
+ * Enter animations replay on mount, so the component only needs to render
189
+ * while `present` and style itself with `state`:
190
+ *
191
+ * ```tsx
192
+ * const { present, state, ref } = usePresence(open, "fast");
193
+ * return present ? <div ref={ref} data-state={state} /> : null;
194
+ * ```
195
+ */
196
+ export declare function usePresence<E extends HTMLElement = HTMLElement>(open: boolean, speed?: MotionSpeed): Presence<E>;
197
+ //#endregion
198
+ //#region src/molecules/Accordion/index.d.ts
199
+ type AccordionItem = {
200
+ /** Identifies the panel across `value` and `defaultValue`. */
201
+ value: string;
202
+ trigger: Renderable;
203
+ children?: Renderable;
204
+ disabled?: boolean;
205
+ };
206
+ type AccordionProps = Omit<HTMLAttributes<HTMLDivElement>, "children" | "value" | "defaultValue"> & {
207
+ items: AccordionItem[];
208
+ /** `single` (default) keeps one panel open; `multiple` allows many. */
209
+ type?: "single" | "multiple";
210
+ /** Controlled set of open panels. */
211
+ value?: string[];
212
+ /** Panels open on first render. */
213
+ defaultValue?: string[];
214
+ onValueChange?: (value: string[]) => void;
215
+ };
216
+ export declare function Accordion({ items, type, value, defaultValue, onValueChange, className, ...props }: AccordionProps): import("react").JSX.Element;
217
+ //#endregion
218
+ //#region src/molecules/Alert/index.d.ts
107
219
  type AlertProps = Omit<HTMLAttributes<HTMLDivElement>, "children" | "title"> & {
108
- variant?: "info" | "success" | "warning" | "danger";
109
- title?: Renderable;
110
- children?: Renderable;
111
- dismissible?: boolean;
112
- onDismiss?: () => void;
113
- };
114
- declare function Alert({ variant, title, children, dismissible, onDismiss, className, role, ...props }: AlertProps): react.JSX.Element | null;
115
- declare const Notice: typeof Alert;
220
+ variant?: "info" | "success" | "warning" | "danger";
221
+ title?: Renderable;
222
+ children?: Renderable;
223
+ dismissible?: boolean;
224
+ onDismiss?: () => void;
225
+ };
226
+ export declare function Alert({ variant, title, children, dismissible, onDismiss, className, role, ...props }: AlertProps): import("react").JSX.Element | null;
227
+ export declare const Notice: typeof Alert;
116
228
  type NoticeProps = AlertProps;
117
-
229
+ //#endregion
230
+ //#region src/molecules/Attachment/index.d.ts
231
+ type AttachmentStatus = "uploading" | "done" | "error";
232
+ type AttachmentFile = {
233
+ id: string;
234
+ name: string;
235
+ size: string;
236
+ status?: AttachmentStatus;
237
+ progress?: number;
238
+ hint?: string;
239
+ href?: string;
240
+ };
241
+ type AttachmentProps = {
242
+ files: AttachmentFile[];
243
+ onRemove?: (id: string) => void;
244
+ ariaLabel?: string;
245
+ className?: string;
246
+ };
247
+ /** Exit delay that lets the leave transition run before the row unmounts. */
248
+ export declare function Attachment({ files, onRemove, ariaLabel, className }: AttachmentProps): import("react").JSX.Element;
249
+ //#endregion
250
+ //#region src/molecules/AvatarGroup/index.d.ts
251
+ type AvatarGroupItem = Pick<AvatarProps, "src" | "name" | "status">;
252
+ type AvatarGroupProps = Omit<HTMLAttributes<HTMLSpanElement>, "children"> & {
253
+ avatars: AvatarGroupItem[];
254
+ /** Avatars shown before collapsing the rest into a `+N` chip. */
255
+ max?: number;
256
+ size?: ControlSize;
257
+ };
258
+ export declare function AvatarGroup({ avatars, max, size, className, ...props }: AvatarGroupProps): import("react").JSX.Element;
259
+ //#endregion
260
+ //#region src/molecules/Breadcrumb/index.d.ts
261
+ type BreadcrumbItem = {
262
+ label: Renderable;
263
+ /** Renders the crumb as a link. Wins over `onClick`. */
264
+ href?: string;
265
+ /** Renders the crumb as a button when there is no `href`. */
266
+ onClick?: () => void;
267
+ /** Leading icon shown before the label. */
268
+ icon?: Renderable;
269
+ };
270
+ type BreadcrumbProps = Omit<HTMLAttributes<HTMLElement>, "children"> & {
271
+ items: BreadcrumbItem[];
272
+ /** Separator drawn between crumbs. Defaults to a caret. */
273
+ separator?: Renderable;
274
+ /** Accessible name for the navigation landmark. */
275
+ label?: string;
276
+ };
277
+ export declare function Breadcrumb({ items, separator, label, className, ...props }: BreadcrumbProps): import("react").JSX.Element;
278
+ //#endregion
279
+ //#region src/molecules/Calendar/index.d.ts
280
+ type CalendarRange = {
281
+ start: string | null;
282
+ end: string | null;
283
+ };
284
+ type CalendarProps = {
285
+ /** Selected day as `YYYY-MM-DD`. */
286
+ value?: string;
287
+ onValueChange?: (value: string) => void;
288
+ /** Displayed month as `YYYY-MM`. Uncontrolled pages keep their own state. */
289
+ month?: string;
290
+ onMonthChange?: (month: string) => void;
291
+ /** Earliest / latest selectable day (inclusive), as `YYYY-MM-DD`. */
292
+ min?: string;
293
+ max?: string;
294
+ /** First weekday: 0 = Sunday, 1 = Monday. Defaults to Monday. */
295
+ weekStartsOn?: 0 | 1;
296
+ mode?: "single" | "range";
297
+ range?: CalendarRange;
298
+ defaultRange?: CalendarRange;
299
+ onRangeChange?: (range: CalendarRange) => void;
300
+ months?: 1 | 2;
301
+ ariaLabel?: string;
302
+ className?: string;
303
+ };
304
+ export declare function Calendar({ value, onValueChange, month, onMonthChange, min, max, weekStartsOn, mode, range, defaultRange, onRangeChange, months, ariaLabel, className }: CalendarProps): import("react").JSX.Element;
305
+ //#endregion
306
+ //#region src/molecules/Card/index.d.ts
118
307
  type CardProps = Omit<HTMLAttributes<HTMLElement>, "children" | "title"> & {
119
- title?: Renderable;
120
- description?: Renderable;
121
- header?: Renderable;
122
- footer?: Renderable;
123
- children?: Renderable;
124
- interactive?: boolean;
125
- selected?: boolean;
126
- };
127
- declare function Card({ title, description, header, footer, children, interactive, selected, className, ...props }: CardProps): react.JSX.Element;
128
-
308
+ title?: Renderable;
309
+ description?: Renderable;
310
+ header?: Renderable;
311
+ footer?: Renderable;
312
+ children?: Renderable;
313
+ interactive?: boolean;
314
+ selected?: boolean;
315
+ };
316
+ export declare function Card({ title, description, header, footer, children, interactive, selected, className, ...props }: CardProps): import("react").JSX.Element;
317
+ //#endregion
318
+ //#region src/molecules/Collapsible/index.d.ts
319
+ type CollapsibleProps = Omit<HTMLAttributes<HTMLDivElement>, "children"> & {
320
+ trigger: Renderable;
321
+ children?: Renderable;
322
+ open?: boolean;
323
+ defaultOpen?: boolean;
324
+ onOpenChange?: (open: boolean) => void;
325
+ disabled?: boolean;
326
+ };
327
+ export declare function Collapsible({ trigger, children, open, defaultOpen, onOpenChange, disabled, className, ...props }: CollapsibleProps): import("react").JSX.Element;
328
+ //#endregion
329
+ //#region src/molecules/Combobox/index.d.ts
330
+ type ComboboxOption = {
331
+ value: string;
332
+ label: Renderable;
333
+ disabled?: boolean;
334
+ /** Groups options under a heading; ungrouped options come first. */
335
+ group?: string;
336
+ /** Extra terms matched by the filter but never highlighted. */
337
+ keywords?: string;
338
+ };
339
+ type ComboboxProps = {
340
+ options: ComboboxOption[];
341
+ /** Single-select value. Omit it and pass `values` for multi-select. */
342
+ value?: string;
343
+ /** Multi-select values; selecting keeps the popup open. */
344
+ values?: string[];
345
+ onValueChange?: (value: string) => void;
346
+ onValuesChange?: (values: string[]) => void;
347
+ placeholder?: Renderable;
348
+ searchPlaceholder?: string;
349
+ emptyMessage?: Renderable;
350
+ disabled?: boolean;
351
+ size?: ControlSize;
352
+ id?: string;
353
+ ariaLabel?: string;
354
+ className?: string;
355
+ };
356
+ export declare function Combobox({ options, value, values, onValueChange, onValuesChange, placeholder, searchPlaceholder, emptyMessage, disabled, size, id, ariaLabel, className }: ComboboxProps): import("react").JSX.Element;
357
+ //#endregion
358
+ //#region src/molecules/Menu/MenuContent.d.ts
359
+ type MenuItem = {
360
+ value?: string;
361
+ label?: Renderable;
362
+ icon?: Renderable;
363
+ shortcut?: Renderable;
364
+ disabled?: boolean;
365
+ danger?: boolean;
366
+ separator?: boolean;
367
+ };
368
+ //#endregion
369
+ //#region src/molecules/ContextMenu/index.d.ts
370
+ type ContextMenuProps = Omit<HTMLAttributes<HTMLDivElement>, "children" | "onContextMenu" | "onSelect"> & {
371
+ children: Renderable;
372
+ items: MenuItem[];
373
+ onSelect?: (value: string) => void;
374
+ disabled?: boolean;
375
+ label?: string;
376
+ };
377
+ /**
378
+ * A menu that opens under the pointer: right-click (or the ContextMenu key)
379
+ * on the surface, the popup clamps itself to the viewport and hands focus to
380
+ * its first item. Escape and selection return focus to the surface.
381
+ */
382
+ export declare function ContextMenu({ children, items, onSelect, disabled, label, className, ...props }: ContextMenuProps): import("react").JSX.Element;
383
+ //#endregion
384
+ //#region src/molecules/Dialog/index.d.ts
129
385
  type DialogProps = {
130
- open: boolean;
131
- onClose: () => void;
132
- title: Renderable;
133
- description?: Renderable;
134
- children?: Renderable;
135
- footer?: Renderable;
136
- closeLabel?: string;
137
- closeOnOverlayClick?: boolean;
138
- className?: string;
139
- };
140
- declare function Dialog({ open, onClose, title, description, children, footer, closeLabel, closeOnOverlayClick, className, }: DialogProps): react.JSX.Element | null;
141
-
386
+ open: boolean;
387
+ onClose: () => void;
388
+ title: Renderable;
389
+ description?: Renderable;
390
+ children?: Renderable;
391
+ footer?: Renderable;
392
+ closeLabel?: string;
393
+ closeOnOverlayClick?: boolean;
394
+ closeOnEscape?: boolean;
395
+ initialFocus?: () => HTMLElement | null;
396
+ returnFocus?: boolean | (() => HTMLElement | null);
397
+ className?: string;
398
+ };
399
+ export declare function Dialog({ open, onClose, title, description, children, footer, closeLabel, closeOnOverlayClick, closeOnEscape, initialFocus, returnFocus, className }: DialogProps): import("react").JSX.Element | null;
400
+ //#endregion
401
+ //#region src/molecules/Drawer/index.d.ts
402
+ type DrawerSide = "left" | "right" | "bottom";
403
+ type DrawerProps = {
404
+ open: boolean;
405
+ onClose: () => void;
406
+ title: Renderable;
407
+ description?: Renderable;
408
+ children?: Renderable;
409
+ footer?: Renderable;
410
+ side?: DrawerSide;
411
+ size?: "sm" | "md" | "lg";
412
+ closeLabel?: string;
413
+ closeOnOverlayClick?: boolean;
414
+ closeOnEscape?: boolean;
415
+ initialFocus?: () => HTMLElement | null;
416
+ returnFocus?: boolean | (() => HTMLElement | null);
417
+ className?: string;
418
+ };
419
+ export declare function Drawer({ open, onClose, title, description, children, footer, side, size, closeLabel, closeOnOverlayClick, closeOnEscape, initialFocus, returnFocus, className }: DrawerProps): import("react").JSX.Element | null;
420
+ //#endregion
421
+ //#region src/molecules/FieldMessage/index.d.ts
142
422
  type FieldMessageProps = Omit<HTMLAttributes<HTMLParagraphElement>, "children"> & {
143
- variant?: "hint" | "error" | "success";
144
- children?: Renderable;
423
+ variant?: "hint" | "error" | "success";
424
+ children?: Renderable;
145
425
  };
146
- declare function FieldMessage({ variant, className, children, ...props }: FieldMessageProps): react.JSX.Element | null;
147
-
426
+ export declare function FieldMessage({ variant, className, children, ...props }: FieldMessageProps): import("react").JSX.Element | null;
427
+ //#endregion
428
+ //#region src/molecules/Field/index.d.ts
148
429
  type FieldProps = {
149
- label?: Renderable;
150
- htmlFor?: string;
151
- description?: Renderable;
152
- message?: Renderable;
153
- messageType?: FieldMessageProps["variant"];
154
- required?: boolean;
155
- className?: string;
156
- children?: Renderable;
157
- };
158
- declare function Field({ label, htmlFor, description, message, messageType, required, className, children, }: FieldProps): react.JSX.Element;
159
-
160
- type MenuItem = {
161
- value?: string;
162
- label?: Renderable;
163
- icon?: Renderable;
164
- shortcut?: Renderable;
165
- disabled?: boolean;
166
- danger?: boolean;
167
- separator?: boolean;
430
+ label?: Renderable;
431
+ htmlFor?: string;
432
+ description?: Renderable;
433
+ message?: Renderable;
434
+ messageType?: FieldMessageProps["variant"];
435
+ required?: boolean;
436
+ className?: string;
437
+ children?: Renderable;
438
+ };
439
+ export declare function Field({ label, htmlFor, description, message, messageType, required, className, children }: FieldProps): import("react").JSX.Element;
440
+ //#endregion
441
+ //#region src/lib/overlay.d.ts
442
+ type OverlaySide = "top" | "bottom" | "left" | "right";
443
+ //#endregion
444
+ //#region src/molecules/HoverCard/index.d.ts
445
+ type HoverCardProps = {
446
+ trigger: Renderable;
447
+ children: Renderable;
448
+ /** Grace before opening, so passing the trigger never flickers. */
449
+ openDelay?: number;
450
+ /** Grace before closing, so the pointer can travel into the card. */
451
+ closeDelay?: number;
452
+ placement?: OverlaySide;
453
+ ariaLabel?: string;
454
+ asChild?: boolean;
455
+ className?: string;
168
456
  };
457
+ export declare function HoverCard({ trigger, children, openDelay, closeDelay, placement, ariaLabel, asChild, className }: HoverCardProps): import("react").JSX.Element;
458
+ //#endregion
459
+ //#region src/molecules/Menu/index.d.ts
169
460
  type MenuProps = {
170
- trigger: Renderable;
171
- items: MenuItem[];
172
- onSelect?: (value: string) => void;
173
- label?: string;
174
- align?: "start" | "end";
175
- disabled?: boolean;
176
- className?: string;
177
- };
178
- declare function Menu({ trigger, items, onSelect, label, align, disabled, className, }: MenuProps): react.JSX.Element;
179
-
461
+ trigger: Renderable;
462
+ items: MenuItem[];
463
+ onSelect?: (value: string) => void;
464
+ /** Controlled open state. */
465
+ open?: boolean;
466
+ /** Fires whenever the menu asks to open or close. */
467
+ onOpenChange?: (open: boolean) => void;
468
+ label?: string;
469
+ align?: "start" | "end";
470
+ disabled?: boolean;
471
+ asChild?: boolean;
472
+ className?: string;
473
+ };
474
+ export declare function Menu({ trigger, items, onSelect, label, align, open: openProp, onOpenChange, disabled, asChild, className }: MenuProps): import("react").JSX.Element;
475
+ //#endregion
476
+ //#region src/molecules/OTPInput/index.d.ts
477
+ type OTPPattern = "numeric" | "alphanumeric" | RegExp;
478
+ type OTPState = "idle" | "verifying" | "success" | "error";
479
+ type OTPInputProps = {
480
+ /** The full code, owned by the parent. */
481
+ value: string;
482
+ onChange?: (value: string) => void;
483
+ /** Fires once when the last cell fills. */
484
+ onComplete?: (value: string) => void;
485
+ /** Number of cells. Defaults to 6. */
486
+ length?: number;
487
+ groups?: number[];
488
+ pattern?: OTPPattern;
489
+ state?: OTPState;
490
+ placeholder?: string;
491
+ clearOnError?: boolean;
492
+ disabled?: boolean;
493
+ invalid?: boolean;
494
+ autoFocus?: boolean;
495
+ ariaLabel?: string;
496
+ id?: string;
497
+ name?: string;
498
+ "aria-describedby"?: string;
499
+ className?: string;
500
+ };
501
+ export declare function OTPInput({ value, onChange, onComplete, length, groups, pattern, state, placeholder, clearOnError, disabled, invalid, autoFocus, ariaLabel, id, name, "aria-describedby": describedBy, className }: OTPInputProps): import("react").JSX.Element;
502
+ //#endregion
503
+ //#region src/molecules/Pagination/index.d.ts
504
+ type PaginationProps = Omit<HTMLAttributes<HTMLElement>, "onChange"> & {
505
+ /** Current page, 1-based. */
506
+ page: number;
507
+ pageCount: number;
508
+ onPageChange?: (page: number) => void;
509
+ /** Numbers shown either side of the current page. Default 1. */
510
+ siblings?: number;
511
+ /** Readout drawn on the right: "1–20 of 340". */
512
+ status?: Renderable;
513
+ /** Accessible name for the nav landmark. */
514
+ label?: string;
515
+ };
516
+ export declare function Pagination({ page, pageCount, onPageChange, siblings, status, label, className, ...props }: PaginationProps): import("react").JSX.Element | null;
517
+ //#endregion
518
+ //#region src/molecules/Popover/index.d.ts
180
519
  type PopoverProps = {
181
- trigger: Renderable;
182
- children: Renderable;
183
- open?: boolean;
184
- defaultOpen?: boolean;
185
- onOpenChange?: (open: boolean) => void;
186
- ariaLabel?: string;
187
- placement?: "start" | "end";
188
- disabled?: boolean;
189
- className?: string;
190
- };
191
- declare function Popover({ trigger, children, open, defaultOpen, onOpenChange, ariaLabel, placement, disabled, className, }: PopoverProps): react.JSX.Element;
192
-
520
+ trigger: Renderable;
521
+ children: Renderable;
522
+ open?: boolean;
523
+ defaultOpen?: boolean;
524
+ onOpenChange?: (open: boolean) => void;
525
+ ariaLabel?: string;
526
+ placement?: "start" | "end";
527
+ disabled?: boolean;
528
+ asChild?: boolean;
529
+ className?: string;
530
+ };
531
+ export declare function Popover({ trigger, children, open, defaultOpen, onOpenChange, ariaLabel, placement, disabled, asChild, className }: PopoverProps): import("react").JSX.Element;
532
+ //#endregion
533
+ //#region src/molecules/QuestionCard/index.d.ts
534
+ type QuestionOption = {
535
+ value: string;
536
+ label: Renderable;
537
+ /** Secondary line under the label. */
538
+ hint?: Renderable;
539
+ disabled?: boolean;
540
+ };
541
+ type QuestionCardProps = Omit<HTMLAttributes<HTMLDivElement>, "children" | "value" | "defaultValue"> & {
542
+ question: Renderable;
543
+ /** Helper line under the question. */
544
+ description?: Renderable;
545
+ options: QuestionOption[];
546
+ /** Controlled selected option. */
547
+ value?: string;
548
+ /** Selected option on first render. */
549
+ defaultValue?: string;
550
+ onValueChange?: (value: string) => void;
551
+ /** Correct option. Setting it locks the card and shows the verdict. */
552
+ answer?: string;
553
+ /** Row under the options: submit buttons, hints, score. */
554
+ footer?: Renderable;
555
+ disabled?: boolean;
556
+ };
557
+ export declare function QuestionCard({ question, description, options, value, defaultValue, onValueChange, answer, footer, disabled, className, ...props }: QuestionCardProps): import("react").JSX.Element;
558
+ //#endregion
559
+ //#region src/molecules/RadioGroup/index.d.ts
193
560
  type RadioOption = {
194
- value: string;
195
- label: Renderable;
196
- description?: Renderable;
197
- disabled?: boolean;
561
+ value: string;
562
+ label: Renderable;
563
+ description?: Renderable;
564
+ disabled?: boolean;
198
565
  };
199
566
  type RadioGroupProps = {
200
- value: string;
201
- options: RadioOption[];
202
- onValueChange: (value: string) => void;
203
- name: string;
204
- label?: Renderable;
205
- description?: Renderable;
206
- size?: ControlSize;
207
- orientation?: "horizontal" | "vertical";
208
- disabled?: boolean;
209
- className?: string;
210
- };
211
- declare function RadioGroup({ value, options, onValueChange, name, label, description, size, orientation, disabled, className, }: RadioGroupProps): react.JSX.Element;
212
-
567
+ value: string;
568
+ options: RadioOption[];
569
+ onValueChange: (value: string) => void;
570
+ name: string;
571
+ label?: Renderable;
572
+ description?: Renderable;
573
+ size?: ControlSize;
574
+ orientation?: "horizontal" | "vertical";
575
+ disabled?: boolean;
576
+ className?: string;
577
+ };
578
+ export declare function RadioGroup({ value, options, onValueChange, name, label, description, size, orientation, disabled, className }: RadioGroupProps): import("react").JSX.Element;
579
+ //#endregion
580
+ //#region src/molecules/Reveal/index.d.ts
581
+ type RevealProps = Omit<HTMLAttributes<HTMLDivElement>, "children"> & {
582
+ children: Renderable;
583
+ trigger?: "mount" | "scroll";
584
+ direction?: "up" | "down" | "left" | "right" | "none";
585
+ distance?: number;
586
+ delay?: number;
587
+ speed?: MotionSpeed;
588
+ once?: boolean;
589
+ };
590
+ export declare function Reveal({ children, trigger, direction, distance, delay, speed, once, className, style, ...props }: RevealProps): import("react").JSX.Element;
591
+ //#endregion
592
+ //#region src/molecules/Select/index.d.ts
213
593
  type SelectOption = {
214
- value: string;
215
- label: Renderable;
216
- disabled?: boolean;
594
+ value: string;
595
+ label: Renderable;
596
+ disabled?: boolean;
217
597
  };
218
598
  type SelectProps = {
219
- value: string;
220
- options: SelectOption[];
221
- onValueChange: (value: string) => void;
222
- id?: string;
223
- className?: string;
224
- placeholder?: Renderable;
225
- ariaLabel?: string;
226
- ariaLabelledBy?: string;
227
- disabled?: boolean;
228
- size?: ControlSize;
229
- };
230
- declare function Select({ value, options, onValueChange, id, className, placeholder, ariaLabel, ariaLabelledBy, disabled, size, }: SelectProps): react.JSX.Element;
231
-
599
+ value: string;
600
+ options: SelectOption[];
601
+ onValueChange: (value: string) => void;
602
+ id?: string;
603
+ className?: string;
604
+ placeholder?: Renderable;
605
+ ariaLabel?: string;
606
+ ariaLabelledBy?: string;
607
+ disabled?: boolean;
608
+ size?: ControlSize;
609
+ };
610
+ export declare function Select({ value, options, onValueChange, id, className, placeholder, ariaLabel, ariaLabelledBy, disabled, size }: SelectProps): import("react").JSX.Element;
611
+ //#endregion
612
+ //#region src/molecules/Stat/index.d.ts
613
+ type StatProps = Omit<HTMLAttributes<HTMLDivElement>, "children"> & {
614
+ label: Renderable;
615
+ value: Renderable;
616
+ hint?: Renderable;
617
+ };
618
+ export declare function Stat({ label, value, hint, className, ...props }: StatProps): import("react").JSX.Element;
619
+ type StatGroupProps = Omit<HTMLAttributes<HTMLDivElement>, "children"> & {
620
+ children: Renderable;
621
+ columns?: number;
622
+ };
623
+ export declare function StatGroup({ children, columns, className, style, ...props }: StatGroupProps): import("react").JSX.Element;
624
+ type DeltaProps = Omit<HTMLAttributes<HTMLSpanElement>, "children" | "title"> & {
625
+ value: number;
626
+ format?: (value: number) => string;
627
+ };
628
+ export declare function Delta({ value, format, className, ...props }: DeltaProps): import("react").JSX.Element;
629
+ //#endregion
630
+ //#region src/molecules/Tabs/index.d.ts
232
631
  type TabItem = {
233
- value: string;
234
- label: Renderable;
235
- disabled?: boolean;
236
- content?: Renderable;
632
+ value: string;
633
+ label: Renderable;
634
+ disabled?: boolean;
635
+ content?: Renderable;
237
636
  };
238
637
  type TabsProps = {
239
- items: TabItem[];
240
- value?: string;
241
- defaultValue?: string;
242
- onValueChange?: (value: string) => void;
243
- children?: Renderable;
244
- ariaLabel?: string;
245
- orientation?: "horizontal" | "vertical";
246
- className?: string;
247
- };
248
- declare function Tabs({ items, value, defaultValue, onValueChange, children, ariaLabel, orientation, className, }: TabsProps): react.JSX.Element;
249
-
638
+ items: TabItem[];
639
+ value?: string;
640
+ defaultValue?: string;
641
+ onValueChange?: (value: string) => void;
642
+ children?: Renderable;
643
+ ariaLabel?: string;
644
+ orientation?: "horizontal" | "vertical";
645
+ className?: string;
646
+ };
647
+ export declare function Tabs({ items, value, defaultValue, onValueChange, children, ariaLabel, orientation, className }: TabsProps): import("react").JSX.Element;
648
+ //#endregion
649
+ //#region src/molecules/TaskList/index.d.ts
650
+ type TaskState = "todo" | "doing" | "done";
651
+ type TaskListItem = {
652
+ /** Stable id reported back through `onStateChange`. */
653
+ id: string;
654
+ label: Renderable;
655
+ state?: TaskState;
656
+ /** Trailing meta: due date, assignee, counters. */
657
+ meta?: Renderable;
658
+ disabled?: boolean;
659
+ };
660
+ type TaskListProps = Omit<HTMLAttributes<HTMLUListElement>, "children" | "onChange"> & {
661
+ items: TaskListItem[];
662
+ /**
663
+ * Fires with the next state when a row's check is pressed:
664
+ * todo → doing → done → todo.
665
+ */
666
+ onStateChange?: (id: string, state: TaskState) => void;
667
+ /** Accessible name for the list. */
668
+ label?: string;
669
+ };
670
+ export declare function TaskList({ items, onStateChange, label, className, ...props }: TaskListProps): import("react").JSX.Element;
671
+ //#endregion
672
+ //#region src/molecules/Timeline/index.d.ts
673
+ type TimelineItem = {
674
+ /** Event title. */
675
+ title: Renderable;
676
+ /** Body rendered under the head. */
677
+ children?: Renderable;
678
+ /** Right-aligned time or meta. */
679
+ timestamp?: Renderable;
680
+ /** Leading icon in place of the default dot. */
681
+ icon?: Renderable;
682
+ tone?: "default" | "accent" | "success" | "danger";
683
+ /** Marks the latest event: its marker keeps breathing. */
684
+ current?: boolean;
685
+ };
686
+ type TimelineProps = Omit<HTMLAttributes<HTMLElement>, "children"> & {
687
+ items: TimelineItem[];
688
+ /** Accessible name for the list. */
689
+ label?: string;
690
+ };
691
+ export declare function Timeline({ items, label, className, ...props }: TimelineProps): import("react").JSX.Element;
692
+ //#endregion
693
+ //#region src/molecules/Toast/index.d.ts
250
694
  type ToastProps = {
251
- open?: boolean;
252
- id?: string | number;
253
- title: Renderable;
254
- description?: Renderable;
255
- variant?: "neutral" | "success" | "warning" | "danger";
256
- action?: ExternalToast["action"];
257
- duration?: number;
258
- closeButton?: boolean;
259
- className?: string;
260
- };
261
- declare function Toast({ open, id, title, description, variant, action, duration, closeButton, className, }: ToastProps): null;
695
+ open?: boolean;
696
+ id?: string | number;
697
+ title: Renderable;
698
+ description?: Renderable;
699
+ variant?: "neutral" | "success" | "warning" | "danger";
700
+ action?: ExternalToast["action"];
701
+ duration?: number;
702
+ closeButton?: boolean;
703
+ className?: string;
704
+ };
705
+ export declare function Toast({ open, id, title, description, variant, action, duration, closeButton, className }: ToastProps): null;
262
706
  type ToastViewportProps = Omit<ToasterProps, "className" | "containerAriaLabel" | "icons" | "toastOptions"> & {
263
- label?: string;
264
- className?: string;
265
- toastOptions?: ToasterProps["toastOptions"];
707
+ label?: string;
708
+ className?: string;
709
+ toastOptions?: ToasterProps["toastOptions"];
266
710
  };
267
- declare function ToastViewport({ label, className, toastOptions, theme, position, closeButton, expand, ...props }: ToastViewportProps): react.JSX.Element;
268
-
711
+ export declare function ToastViewport({ label, className, toastOptions, theme, position, closeButton, expand, ...props }: ToastViewportProps): import("react").JSX.Element;
712
+ //#endregion
713
+ //#region src/molecules/Toolbar/index.d.ts
269
714
  type ToolbarProps = Omit<HTMLAttributes<HTMLDivElement>, "children"> & {
270
- label?: string;
271
- orientation?: "horizontal" | "vertical";
272
- size?: ControlSize;
273
- start?: Renderable;
274
- end?: Renderable;
275
- children?: Renderable;
276
- };
277
- declare function Toolbar({ label, orientation, size, start, end, children, className, ...props }: ToolbarProps): react.JSX.Element;
278
-
715
+ label?: string;
716
+ orientation?: "horizontal" | "vertical";
717
+ size?: ControlSize;
718
+ start?: Renderable;
719
+ end?: Renderable;
720
+ children?: Renderable;
721
+ };
722
+ export declare function Toolbar({ label, orientation, size, start, end, children, className, ...props }: ToolbarProps): import("react").JSX.Element;
723
+ //#endregion
724
+ //#region src/molecules/Tooltip/index.d.ts
279
725
  type TooltipProps = {
280
- content: Renderable;
281
- children: Renderable;
282
- side?: "top" | "right" | "bottom" | "left";
283
- delay?: number;
284
- disabled?: boolean;
285
- className?: string;
286
- };
287
- declare function Tooltip({ content, children, side, delay, disabled, className, }: TooltipProps): react.JSX.Element;
288
-
726
+ content: Renderable;
727
+ children: Renderable;
728
+ side?: "top" | "right" | "bottom" | "left";
729
+ delay?: number;
730
+ disabled?: boolean;
731
+ className?: string;
732
+ };
733
+ type TooltipGroupProps = {
734
+ delay?: number;
735
+ skipDelay?: number;
736
+ children?: Renderable;
737
+ };
738
+ export declare function TooltipGroup({ delay, skipDelay, children }: TooltipGroupProps): import("react").JSX.Element;
739
+ export declare function Tooltip({ content, children, side, delay, disabled, className }: TooltipProps): import("react").JSX.Element;
740
+ //#endregion
741
+ //#region src/organisms/Chart/index.d.ts
742
+ type ChartSeries = {
743
+ name: string;
744
+ /** One entry per category; `null` breaks the line into segments. */
745
+ values: (number | null)[];
746
+ tone?: "accent" | "success" | "danger" | "muted";
747
+ };
748
+ type ChartProps = Omit<HTMLAttributes<HTMLElement>, "children"> & {
749
+ /** Labels along the x-axis. */
750
+ categories: string[];
751
+ series: ChartSeries[];
752
+ /** Marks drawn on the plot. Default "line". */
753
+ variant?: "line" | "bar" | "area";
754
+ /** Plot height in pixels. Default 160. */
755
+ height?: number;
756
+ /** Curve the line (Catmull-Rom). Default false. */
757
+ smooth?: boolean;
758
+ /** Target y-axis ticks; nice numbers win. Default 4. */
759
+ ticks?: number;
760
+ /** Formats axis and tooltip values. Trims decimals by default. */
761
+ format?: (value: number) => string;
762
+ /** Show the legend. Defaults to shown for more than one series. */
763
+ legend?: boolean;
764
+ /** Accessible summary for the plot. */
765
+ label?: string;
766
+ };
767
+ export declare function Chart({ categories, series, variant, height, smooth, ticks, format, legend, label, className, ...props }: ChartProps): import("react").JSX.Element;
768
+ //#endregion
769
+ //#region src/organisms/CommandPalette/index.d.ts
770
+ type CommandItem = {
771
+ id?: string;
772
+ label: Renderable;
773
+ /** Value reported to `onSelect` when omitted (falls back to the label). */
774
+ value?: string;
775
+ icon?: Renderable;
776
+ /** Groups options under a heading; ungrouped options always come first. */
777
+ group?: string;
778
+ /** Muted text trailing the option (chevrons are drawn for parents). */
779
+ hint?: Renderable;
780
+ badge?: Renderable;
781
+ shortcut?: string[];
782
+ /** Extra terms matched by the filter but never highlighted. */
783
+ keywords?: string;
784
+ disabled?: boolean;
785
+ /** Sub-options: activating this option drills into a new level. */
786
+ children?: CommandItem[];
787
+ };
788
+ type CommandPaletteProps = {
789
+ open: boolean;
790
+ onOpenChange: (open: boolean) => void;
791
+ items: CommandItem[];
792
+ onSelect?: (item: CommandItem) => void;
793
+ placeholder?: string;
794
+ emptyMessage?: Renderable;
795
+ /** Label of the breadcrumb that returns to the root level. */
796
+ homeLabel?: string;
797
+ ariaLabel?: string;
798
+ /** Bind Cmd/Ctrl+K to toggle the palette. Default: false. */
799
+ hotkey?: boolean;
800
+ className?: string;
801
+ };
802
+ export declare function CommandPalette({ open, onOpenChange, items, onSelect, placeholder, emptyMessage, homeLabel, ariaLabel, hotkey, className }: CommandPaletteProps): import("react").ReactPortal | null;
803
+ //#endregion
804
+ //#region src/organisms/EmptyState/index.d.ts
289
805
  type EmptyStateProps = Omit<HTMLAttributes<HTMLElement>, "children" | "title"> & {
290
- title: Renderable;
291
- description?: Renderable;
292
- icon?: Renderable;
293
- action?: Renderable;
294
- compact?: boolean;
295
- };
296
- declare function EmptyState({ title, description, icon, action, compact, className, ...props }: EmptyStateProps): react.JSX.Element;
297
-
806
+ title: Renderable;
807
+ description?: Renderable;
808
+ icon?: Renderable;
809
+ action?: Renderable;
810
+ compact?: boolean;
811
+ };
812
+ export declare function EmptyState({ title, description, icon, action, compact, className, ...props }: EmptyStateProps): import("react").JSX.Element;
813
+ //#endregion
814
+ //#region src/organisms/MagneticDropzone/index.d.ts
815
+ type DropzoneRejectReason = "type" | "size" | "count";
816
+ type DropzoneFileLike = {
817
+ name: string;
818
+ type: string;
819
+ size: number;
820
+ };
821
+ type DropzoneValidation = {
822
+ accept?: string;
823
+ multiple?: boolean;
824
+ maxFiles?: number;
825
+ maxSize?: number;
826
+ };
827
+ type DropzoneValidationResult<T extends DropzoneFileLike> = {
828
+ accepted: T[];
829
+ rejected: {
830
+ reason: DropzoneRejectReason;
831
+ files: T[];
832
+ }[];
833
+ };
834
+ type MagneticDropzoneProps = Omit<React.HTMLAttributes<HTMLDivElement>, "onDrop" | "onDragOver" | "children"> & {
835
+ /** Idle content: an icon, instructions, a choose-file button. */
836
+ children?: Renderable;
837
+ /** Replaces `children` while files hover over the zone. */
838
+ activeContent?: Renderable;
839
+ onFiles?: (files: File[]) => void;
840
+ onReject?: (files: File[], reason: DropzoneRejectReason) => void;
841
+ /** Forwarded to the hidden file input, e.g. "image/*,.pdf". */
842
+ accept?: string;
843
+ multiple?: boolean;
844
+ maxFiles?: number;
845
+ maxSize?: number;
846
+ disabled?: boolean;
847
+ label?: string;
848
+ trigger?: "zone" | "children";
849
+ className?: string;
850
+ };
851
+ export declare function validateDropzoneFiles<T extends DropzoneFileLike>(files: readonly T[], { accept, multiple, maxFiles, maxSize }?: DropzoneValidation): DropzoneValidationResult<T>;
852
+ export declare function describeDropzoneResult(result: DropzoneValidationResult<DropzoneFileLike>): string;
853
+ /**
854
+ * A drop zone whose content leans toward the pointer while files hover —
855
+ * the pull is a CSS variable updated on dragover, so the attraction stays
856
+ * cheap and collapses with the motion tokens.
857
+ */
858
+ export declare function MagneticDropzone({ children, activeContent, onFiles, onReject, accept, multiple, maxFiles, maxSize, disabled, label, trigger, className, "aria-label": ariaLabel, "aria-describedby": ariaDescribedBy, onPaste, ...props }: MagneticDropzoneProps): import("react").JSX.Element;
859
+ //#endregion
860
+ //#region src/organisms/Menubar/index.d.ts
861
+ type MenubarMenu = {
862
+ /** Accessible name for the menu and its trigger. */
863
+ label: string;
864
+ /** Rich trigger content; falls back to the label. */
865
+ trigger?: Renderable;
866
+ items: MenuItem[];
867
+ disabled?: boolean;
868
+ };
869
+ type MenubarProps = Omit<HTMLAttributes<HTMLDivElement>, "children" | "onSelect"> & {
870
+ menus: MenubarMenu[];
871
+ onSelect?: (value: string) => void;
872
+ /** Accessible name for the bar itself. */
873
+ label?: string;
874
+ };
875
+ /**
876
+ * The classic application menu bar. Menus run controlled off a single
877
+ * `openIndex`: hovering a closed bar opens after a short intent delay, an
878
+ * already-open bar slides straight across, and the arrow keys walk the
879
+ * triggers with wrap-around.
880
+ */
881
+ export declare function Menubar({ menus, onSelect, label, className, ...props }: MenubarProps): import("react").JSX.Element;
882
+ //#endregion
883
+ //#region src/organisms/ReasoningSteps/index.d.ts
884
+ type ReasoningStep = {
885
+ id?: string;
886
+ title: Renderable;
887
+ detail?: Renderable;
888
+ status?: "pending" | "active" | "done";
889
+ };
890
+ type ReasoningStepsProps = {
891
+ steps: ReasoningStep[];
892
+ label?: Renderable;
893
+ open?: boolean;
894
+ defaultOpen?: boolean;
895
+ onOpenChange?: (open: boolean) => void;
896
+ className?: string;
897
+ };
898
+ export declare function ReasoningSteps({ steps, label, open, defaultOpen, onOpenChange, className }: ReasoningStepsProps): import("react").JSX.Element;
899
+ //#endregion
900
+ //#region src/organisms/Resizable/index.d.ts
901
+ type ResizableProps = Omit<HTMLAttributes<HTMLDivElement>, "children"> & {
902
+ /** The panes, in visual order. A handle is rendered between each pair. */
903
+ panes: Renderable[];
904
+ direction?: "horizontal" | "vertical";
905
+ /** Controlled pane sizes in percent; they should sum to 100. */
906
+ sizes?: number[];
907
+ defaultSizes?: number[];
908
+ onSizesChange?: (sizes: number[]) => void;
909
+ /** Smallest share a pane may keep, in percent. Default: 10. */
910
+ min?: number;
911
+ handleLabel?: string;
912
+ };
913
+ export declare function Resizable({ panes, direction, sizes, defaultSizes, onSizesChange, min, handleLabel, className, ...props }: ResizableProps): import("react").JSX.Element;
914
+ //#endregion
915
+ //#region src/organisms/Sidebar/index.d.ts
916
+ type SidebarItem = {
917
+ value: string;
918
+ label: Renderable;
919
+ icon?: Renderable;
920
+ badge?: Renderable;
921
+ disabled?: boolean;
922
+ };
923
+ type SidebarSection = {
924
+ title?: string;
925
+ items: SidebarItem[];
926
+ };
927
+ type SidebarProps = Omit<HTMLAttributes<HTMLElement>, "children" | "onSelect"> & {
928
+ sections: SidebarSection[];
929
+ /** Controlled active item. */
930
+ value?: string;
931
+ defaultValue?: string;
932
+ onSelect?: (value: string) => void;
933
+ header?: Renderable;
934
+ footer?: Renderable;
935
+ /** Show the collapse toggle. Default: false. */
936
+ collapsible?: boolean;
937
+ collapsed?: boolean;
938
+ defaultCollapsed?: boolean;
939
+ onCollapsedChange?: (collapsed: boolean) => void;
940
+ ariaLabel?: string;
941
+ };
942
+ export declare function Sidebar({ sections, value, defaultValue, onSelect, header, footer, collapsible, collapsed, defaultCollapsed, onCollapsedChange, ariaLabel, className, ...props }: SidebarProps): import("react").JSX.Element;
943
+ //#endregion
944
+ //#region src/organisms/StreamingText/index.d.ts
945
+ type StreamingTextProps = Omit<HTMLAttributes<HTMLDivElement>, "children"> & {
946
+ text: string;
947
+ /** Delay between word entrances, in ms. Default: 30. */
948
+ speed?: number;
949
+ /** Reveal words progressively. Default: true. */
950
+ animated?: boolean;
951
+ };
952
+ /**
953
+ * Words arrive one at a time — and because each word animates only when it
954
+ * mounts, appending to `text` streams naturally without any JS timing: the
955
+ * new words cascade in while finished ones stay put.
956
+ */
957
+ export declare function StreamingText({ text, speed, animated, className, ...props }: StreamingTextProps): import("react").JSX.Element;
958
+ //#endregion
959
+ //#region src/organisms/Table/rows.d.ts
960
+ type TableSortDirection = "asc" | "desc";
961
+ type TableSort = {
962
+ key: string;
963
+ direction: TableSortDirection;
964
+ };
965
+ //#endregion
966
+ //#region src/organisms/Table/index.d.ts
298
967
  type TableColumn<Row extends Record<string, unknown> = Record<string, unknown>> = {
299
- key: string;
300
- label: Renderable;
301
- align?: "start" | "center" | "end";
302
- width?: string;
303
- render?: (row: Row, index: number) => Renderable;
968
+ key: string;
969
+ label: Renderable;
970
+ align?: "start" | "center" | "end";
971
+ width?: string;
972
+ render?: (row: Row, index: number) => Renderable;
973
+ sortable?: boolean;
974
+ sortValue?: (row: Row) => unknown;
975
+ compare?: (a: Row, b: Row) => number;
304
976
  };
305
977
  type TableProps<Row extends Record<string, unknown> = Record<string, unknown>> = Omit<TableHTMLAttributes<HTMLTableElement>, "children" | "rows" | "className" | "cellPadding" | "cellSpacing"> & {
306
- columns: TableColumn<Row>[];
307
- rows: Row[];
308
- caption?: Renderable;
309
- emptyMessage?: Renderable;
310
- rowKey?: keyof Row & string;
311
- density?: "compact" | "comfortable";
312
- striped?: boolean;
313
- stickyHeader?: boolean;
314
- className?: string;
315
- };
316
- declare function Table<Row extends Record<string, unknown> = Record<string, unknown>>({ columns, rows, caption, emptyMessage, rowKey, density, striped, stickyHeader, className, ...props }: TableProps<Row>): react.JSX.Element;
317
-
318
- export { Alert, type AlertProps, Badge, type BadgeProps, Button, type ButtonProps, Card, type CardProps, Checkbox, type CheckboxProps, type ControlSize, Dialog, type DialogProps, EmptyState, type EmptyStateProps, Field, FieldMessage, type FieldMessageProps, type FieldProps, IconButton, type IconButtonProps, Input, type InputProps, Menu, type MenuItem, type MenuProps, Notice, type NoticeProps, Popover, type PopoverProps, RadioGroup, type RadioGroupProps, type RadioOption, type Renderable, type RenderableElement, Select, type SelectOption, type SelectProps, Separator, type SeparatorProps, Skeleton, type SkeletonProps, Slider, type SliderProps, Spinner, type SpinnerProps, Surface, type SurfaceProps, type TabItem, Table, type TableColumn, type TableProps, Tabs, type TabsProps, Textarea, type TextareaProps, Toast, type ToastProps, ToastViewport, type ToastViewportProps, Toggle, type ToggleProps, Toolbar, type ToolbarProps, Tooltip, type TooltipProps };
978
+ columns: TableColumn<Row>[];
979
+ rows: Row[];
980
+ caption?: Renderable;
981
+ emptyMessage?: Renderable;
982
+ rowKey?: keyof Row & string;
983
+ getRowId?: (row: Row, index: number) => string;
984
+ density?: "compact" | "comfortable";
985
+ striped?: boolean;
986
+ stickyHeader?: boolean;
987
+ stickyFirstColumn?: boolean;
988
+ sort?: TableSort[];
989
+ defaultSort?: TableSort[];
990
+ onSortChange?: (sort: TableSort[]) => void;
991
+ multiSort?: boolean;
992
+ manualSort?: boolean;
993
+ selectable?: boolean;
994
+ selected?: ReadonlySet<string> | readonly string[];
995
+ defaultSelected?: ReadonlySet<string> | readonly string[];
996
+ onSelectedChange?: (selected: string[]) => void;
997
+ rowLabel?: (row: Row, index: number) => string;
998
+ selectAllLabel?: string;
999
+ className?: string;
1000
+ };
1001
+ export declare function Table<Row extends Record<string, unknown> = Record<string, unknown>>({ columns, rows, caption, emptyMessage, rowKey, getRowId, density, striped, stickyHeader, stickyFirstColumn, sort, defaultSort, onSortChange, multiSort, manualSort, selectable, selected, defaultSelected, onSelectedChange, rowLabel, selectAllLabel, className, ...props }: TableProps<Row>): import("react").JSX.Element;
1002
+ //#endregion
1003
+ //#region src/atoms/StatusMark/index.d.ts
1004
+ type StatusMarkState = "idle" | "running" | "progress" | "success" | "error";
1005
+ type StatusMarkProps = Omit<HTMLAttributes<HTMLSpanElement>, "children" | "role" | "aria-label"> & {
1006
+ state?: StatusMarkState;
1007
+ value?: number;
1008
+ label: string;
1009
+ size?: ControlSize;
1010
+ className?: string;
1011
+ };
1012
+ export declare function StatusMark({ state, value, label, size, className, style, ...props }: StatusMarkProps): import("react").JSX.Element;
1013
+ //#endregion
1014
+ //#region src/atoms/Timestamp/index.d.ts
1015
+ type TimestampFormat = "relative" | "absolute" | "auto";
1016
+ type TimestampProps = Omit<TimeHTMLAttributes<HTMLTimeElement>, "children" | "dateTime"> & {
1017
+ date: Date | string | number;
1018
+ format?: TimestampFormat;
1019
+ locale?: string | string[];
1020
+ absoluteOptions?: Intl.DateTimeFormatOptions;
1021
+ live?: boolean;
1022
+ now?: Date | number;
1023
+ };
1024
+ export declare function Timestamp({ date, format, locale, absoluteOptions, live, now, className, ...props }: TimestampProps): import("react").JSX.Element;
1025
+ //#endregion
1026
+ //#region src/atoms/NumberInput/index.d.ts
1027
+ type NumberInputProps = Omit<InputHTMLAttributes<HTMLInputElement>, "size" | "type" | "value" | "defaultValue" | "onChange" | "min" | "max" | "step" | "children"> & {
1028
+ value?: number | null;
1029
+ defaultValue?: number | null;
1030
+ onValueChange?: (value: number | null) => void;
1031
+ min?: number;
1032
+ max?: number;
1033
+ step?: number;
1034
+ largeStep?: number;
1035
+ precision?: number;
1036
+ format?: Intl.NumberFormatOptions;
1037
+ locale?: string;
1038
+ size?: ControlSize;
1039
+ invalid?: boolean;
1040
+ scrub?: boolean;
1041
+ label?: string;
1042
+ decrementLabel?: string;
1043
+ incrementLabel?: string;
1044
+ };
1045
+ export declare function NumberInput({ value, defaultValue, onValueChange, min, max, step, largeStep, precision, format, locale, size, invalid, disabled, readOnly, scrub, label, decrementLabel, incrementLabel, className, style, name, onKeyDown, onBlur, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, "aria-invalid": ariaInvalid, ...props }: NumberInputProps): import("react").JSX.Element;
1046
+ //#endregion
1047
+ //#region src/atoms/HoldButton/index.d.ts
1048
+ type HoldButtonProps = Omit<ButtonHTMLAttributes<HTMLButtonElement>, "children" | "type"> & {
1049
+ onConfirm: () => void;
1050
+ children?: Renderable;
1051
+ holdLabel?: Renderable;
1052
+ confirmedLabel?: Renderable;
1053
+ hint?: string;
1054
+ duration?: number;
1055
+ variant?: "danger" | "primary" | "secondary";
1056
+ size?: ControlSize;
1057
+ };
1058
+ export declare function HoldButton({ onConfirm, children, holdLabel, confirmedLabel, hint, duration, variant, size, disabled, className, style, onPointerDown, onPointerUp, onPointerCancel, onPointerMove, onKeyDown, onKeyUp, onBlur, onContextMenu, onClick, "aria-describedby": ariaDescribedBy, ...props }: HoldButtonProps): import("react").JSX.Element;
1059
+ //#endregion
1060
+ //#region src/molecules/SegmentedControl/index.d.ts
1061
+ type SegmentedOption = {
1062
+ value: string;
1063
+ label: Renderable;
1064
+ icon?: Renderable;
1065
+ disabled?: boolean;
1066
+ };
1067
+ type SegmentedControlProps = {
1068
+ options: SegmentedOption[];
1069
+ ariaLabel: string;
1070
+ value?: string;
1071
+ defaultValue?: string;
1072
+ onValueChange?: (value: string) => void;
1073
+ size?: ControlSize;
1074
+ fullWidth?: boolean;
1075
+ disabled?: boolean;
1076
+ className?: string;
1077
+ };
1078
+ export declare function SegmentedControl({ options, ariaLabel, value, defaultValue, onValueChange, size, fullWidth, disabled, className }: SegmentedControlProps): import("react").JSX.Element;
1079
+ //#endregion
1080
+ //#region src/molecules/Stepper/index.d.ts
1081
+ type StepperStep = {
1082
+ id?: string;
1083
+ label: Renderable;
1084
+ description?: Renderable;
1085
+ };
1086
+ type StepperProps = {
1087
+ steps: StepperStep[];
1088
+ current: number;
1089
+ orientation?: "horizontal" | "vertical";
1090
+ size?: ControlSize;
1091
+ onStepSelect?: (index: number) => void;
1092
+ ariaLabel?: string;
1093
+ completedLabel?: string;
1094
+ className?: string;
1095
+ };
1096
+ export declare function Stepper({ steps, current, orientation, size, onStepSelect, ariaLabel, completedLabel, className }: StepperProps): import("react").JSX.Element;
1097
+ //#endregion
1098
+ //#region src/molecules/MetadataList/index.d.ts
1099
+ type MetadataEntry = {
1100
+ label: Renderable;
1101
+ value: Renderable;
1102
+ hint?: Renderable;
1103
+ id?: string;
1104
+ };
1105
+ type MetadataListLayout = "columns" | "stacked" | "inline";
1106
+ type MetadataListProps = Omit<HTMLAttributes<HTMLDListElement>, "children"> & {
1107
+ items: MetadataEntry[];
1108
+ layout?: MetadataListLayout;
1109
+ size?: ControlSize;
1110
+ dividers?: boolean;
1111
+ };
1112
+ export declare function MetadataList({ items, layout, size, dividers, className, ...props }: MetadataListProps): import("react").JSX.Element;
1113
+ //#endregion
1114
+ //#region src/molecules/OverflowList/index.d.ts
1115
+ type OverflowCollapse = "end" | "start";
1116
+ type OverflowListProps<T = unknown> = Omit<HTMLAttributes<HTMLUListElement>, "children"> & {
1117
+ items: T[];
1118
+ renderItem: (item: T, index: number) => Renderable;
1119
+ renderOverflow?: (hidden: T[]) => Renderable;
1120
+ renderOverflowItem?: (item: T, index: number) => Renderable;
1121
+ getKey?: (item: T, index: number) => string | number;
1122
+ minVisible?: number;
1123
+ collapseFrom?: OverflowCollapse;
1124
+ overflowLabel?: (count: number) => string;
1125
+ };
1126
+ export declare function OverflowList<T>({ items, renderItem, renderOverflow, renderOverflowItem, getKey, minVisible, collapseFrom, overflowLabel, className, ...props }: OverflowListProps<T>): import("react").JSX.Element;
1127
+ //#endregion
1128
+ //#region src/molecules/Citation/index.d.ts
1129
+ type CitationSource = {
1130
+ title: string;
1131
+ url?: string;
1132
+ site?: string;
1133
+ snippet?: string;
1134
+ favicon?: string;
1135
+ };
1136
+ type CitationProps = {
1137
+ sources: CitationSource[];
1138
+ index?: number;
1139
+ max?: number;
1140
+ placement?: OverlaySide;
1141
+ openDelay?: number;
1142
+ closeDelay?: number;
1143
+ className?: string;
1144
+ };
1145
+ export declare function Citation({ sources, index, max, placement, openDelay, closeDelay, className }: CitationProps): import("react").JSX.Element | null;
1146
+ //#endregion
1147
+ //#region src/molecules/ToolCalls/index.d.ts
1148
+ type ToolCall = {
1149
+ id: string;
1150
+ name: string;
1151
+ title?: Renderable;
1152
+ state: StatusMarkState;
1153
+ input?: Renderable;
1154
+ output?: Renderable;
1155
+ duration?: number;
1156
+ };
1157
+ type ToolCallsProps = Omit<HTMLAttributes<HTMLDivElement>, "children"> & {
1158
+ calls: ToolCall[];
1159
+ open?: boolean;
1160
+ defaultOpen?: boolean;
1161
+ onOpenChange?: (open: boolean) => void;
1162
+ label?: Renderable;
1163
+ };
1164
+ export declare function ToolCalls({ calls, open, defaultOpen, onOpenChange, label, className, ...props }: ToolCallsProps): import("react").JSX.Element;
1165
+ //#endregion
1166
+ //#region src/molecules/PlanCard/index.d.ts
1167
+ type PlanStep = {
1168
+ id: string;
1169
+ label: Renderable;
1170
+ detail?: Renderable;
1171
+ state?: StatusMarkState;
1172
+ };
1173
+ type PlanCardState = "pending" | "approved" | "rejected" | "running";
1174
+ type PlanCardProps = Omit<HTMLAttributes<HTMLDivElement>, "children" | "title"> & {
1175
+ title: Renderable;
1176
+ description?: Renderable;
1177
+ steps: PlanStep[];
1178
+ editable?: boolean;
1179
+ onApprove: (steps: PlanStep[]) => void;
1180
+ onReject?: () => void;
1181
+ approveLabel?: Renderable;
1182
+ rejectLabel?: Renderable;
1183
+ state?: PlanCardState;
1184
+ hotkey?: boolean;
1185
+ autoFocus?: boolean;
1186
+ };
1187
+ export declare function PlanCard({ title, description, steps, editable, onApprove, onReject, approveLabel, rejectLabel, state, hotkey, autoFocus, className, ...props }: PlanCardProps): import("react").JSX.Element;
1188
+ //#endregion
1189
+ //#region src/organisms/ChatScroller/index.d.ts
1190
+ type ChatScrollerProps = Omit<HTMLAttributes<HTMLDivElement>, "children"> & {
1191
+ children?: Renderable;
1192
+ itemCount?: number;
1193
+ newCount?: number;
1194
+ threshold?: number;
1195
+ ariaLabel?: string;
1196
+ jumpLabel?: string;
1197
+ contentClassName?: string;
1198
+ onPinnedChange?: (pinned: boolean) => void;
1199
+ };
1200
+ export declare function ChatScroller({ children, itemCount, newCount, threshold, ariaLabel, jumpLabel, contentClassName, onPinnedChange, className, ...props }: ChatScrollerProps): import("react").JSX.Element;
1201
+ //#endregion
1202
+ export { type AccordionItem, type AccordionProps, type AlertProps, type AnimatedNumberProps, type AttachmentFile, type AttachmentProps, type AvatarGroupItem, type AvatarGroupProps, type AvatarProps, type AvatarStatus, type BadgeProps, type BreadcrumbItem, type BreadcrumbProps, type ButtonProps, type CalendarProps, type CalendarRange, type CardProps, type ChartProps, type ChartSeries, type ChatScrollerProps, type CheckboxProps, type CitationProps, type CitationSource, type CollapsibleProps, type ComboboxOption, type ComboboxProps, type CommandItem, type CommandPaletteProps, type ContextMenuProps, type ControlSize, type DeltaProps, type DialogProps, type DrawerProps, type DrawerSide, type DropzoneRejectReason, type DropzoneValidation, type DropzoneValidationResult, type EmptyStateProps, type FieldMessageProps, type FieldProps, type HoldButtonProps, type HoverCardProps, type IconButtonProps, type InputProps, type KbdProps, type MagneticDropzoneProps, type MenuItem, type MenuProps, type MenubarMenu, type MenubarProps, type MetadataEntry, type MetadataListLayout, type MetadataListProps, type MotionSpeed, type NoticeProps, type NumberInputProps, type OTPInputProps, type OTPPattern, type OTPState, type OverflowListProps, type PaginationProps, type PlanCardProps, type PlanCardState, type PlanStep, type PopoverProps, type Presence, type ProgressProps, type QuestionCardProps, type QuestionOption, type RadioGroupProps, type RadioOption, type ReasoningStep, type ReasoningStepsProps, type Renderable, type RenderableElement, type ResizableProps, type RevealProps, type ScrollAreaProps, type SegmentedControlProps, type SegmentedOption, type SelectOption, type SelectProps, type SeparatorProps, type SidebarItem, type SidebarProps, type SidebarSection, type SkeletonProps, type SliderProps, type SpinnerProps, type StatGroupProps, type StatProps, type StatusMarkProps, type StatusMarkState, type StepperProps, type StepperStep, type StreamingTextProps, type SurfaceProps, type TabItem, type TableColumn, type TableProps, type TableSort, type TableSortDirection, type TabsProps, type TaskListItem, type TaskListProps, type TaskState, type TextareaProps, type TimelineItem, type TimelineProps, type TimestampFormat, type TimestampProps, type ToastProps, type ToastViewportProps, type ToggleProps, type ToolCall, type ToolCallsProps, type ToolbarProps, type TooltipGroupProps, type TooltipProps, toast };
1203
+ //# sourceMappingURL=index.d.ts.map