@wearenotch/ui-react 0.2.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.cjs.js +95 -0
- package/dist/index.css +1 -0
- package/dist/index.d.ts +902 -0
- package/dist/index.esm.js +28855 -0
- package/package.json +65 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,902 @@
|
|
|
1
|
+
import { ChartData } from 'chart.js';
|
|
2
|
+
import { ChartOptions } from 'chart.js';
|
|
3
|
+
import { default as default_2 } from 'react';
|
|
4
|
+
import { ForwardRefExoticComponent } from 'react';
|
|
5
|
+
import { JSX } from 'react/jsx-runtime';
|
|
6
|
+
import { MouseEventHandler } from 'react';
|
|
7
|
+
import { ReactNode } from 'react';
|
|
8
|
+
import { RefAttributes } from 'react';
|
|
9
|
+
|
|
10
|
+
export declare function Accordion({ multiple, defaultValue, value: controlledValue, onValueChange, children, className, }: AccordionProps): JSX.Element;
|
|
11
|
+
|
|
12
|
+
export declare namespace Accordion {
|
|
13
|
+
var displayName: string;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
export declare function AccordionContent({ children, className }: AccordionContentProps): JSX.Element;
|
|
17
|
+
|
|
18
|
+
export declare namespace AccordionContent {
|
|
19
|
+
var displayName: string;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export declare interface AccordionContentProps {
|
|
23
|
+
children: default_2.ReactNode;
|
|
24
|
+
className?: string;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export declare function AccordionItem({ value, children, className }: AccordionItemProps): JSX.Element;
|
|
28
|
+
|
|
29
|
+
export declare namespace AccordionItem {
|
|
30
|
+
var displayName: string;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export declare interface AccordionItemProps {
|
|
34
|
+
/** Unique value for this item */
|
|
35
|
+
value: string;
|
|
36
|
+
children: default_2.ReactNode;
|
|
37
|
+
className?: string;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export declare interface AccordionProps {
|
|
41
|
+
/** Allow multiple panels open at once */
|
|
42
|
+
multiple?: boolean;
|
|
43
|
+
/** Default open panel value(s) */
|
|
44
|
+
defaultValue?: string | string[];
|
|
45
|
+
/** Controlled open value(s) */
|
|
46
|
+
value?: string | string[];
|
|
47
|
+
onValueChange?: (value: string | string[]) => void;
|
|
48
|
+
children: default_2.ReactNode;
|
|
49
|
+
className?: string;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export declare function AccordionTrigger({ children, className }: AccordionTriggerProps): JSX.Element;
|
|
53
|
+
|
|
54
|
+
export declare namespace AccordionTrigger {
|
|
55
|
+
var displayName: string;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export declare interface AccordionTriggerProps {
|
|
59
|
+
children: default_2.ReactNode;
|
|
60
|
+
className?: string;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export declare function Alert({ variant, title, children, icon, dismissible, onDismiss, className, }: AlertProps): JSX.Element;
|
|
64
|
+
|
|
65
|
+
export declare namespace Alert {
|
|
66
|
+
var displayName: string;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
export declare interface AlertProps {
|
|
70
|
+
variant?: AlertVariant;
|
|
71
|
+
/** Alert title — bold heading */
|
|
72
|
+
title?: string;
|
|
73
|
+
/** Alert body content */
|
|
74
|
+
children: default_2.ReactNode;
|
|
75
|
+
/** Icon override — defaults to variant icon */
|
|
76
|
+
icon?: default_2.ReactNode;
|
|
77
|
+
/** Show close button */
|
|
78
|
+
dismissible?: boolean;
|
|
79
|
+
/** Called when close button is clicked */
|
|
80
|
+
onDismiss?: () => void;
|
|
81
|
+
className?: string;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
export declare type AlertVariant = 'info' | 'success' | 'warning' | 'error';
|
|
85
|
+
|
|
86
|
+
export declare const Avatar: ForwardRefExoticComponent<AvatarProps & RefAttributes<HTMLSpanElement>>;
|
|
87
|
+
|
|
88
|
+
export declare function AvatarGroup({ children, max, size, className, }: AvatarGroupProps): JSX.Element;
|
|
89
|
+
|
|
90
|
+
export declare namespace AvatarGroup {
|
|
91
|
+
var displayName: string;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
export declare interface AvatarGroupProps {
|
|
95
|
+
children: default_2.ReactNode;
|
|
96
|
+
/** Max avatars to show before showing +N */
|
|
97
|
+
max?: number;
|
|
98
|
+
size?: AvatarSize;
|
|
99
|
+
className?: string;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
export declare interface AvatarProps {
|
|
103
|
+
/** Image URL */
|
|
104
|
+
src?: string;
|
|
105
|
+
/** Alt text for image */
|
|
106
|
+
alt?: string;
|
|
107
|
+
/** Initials shown when no image (max 2 chars) */
|
|
108
|
+
initials?: string;
|
|
109
|
+
size?: AvatarSize;
|
|
110
|
+
className?: string;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
export declare type AvatarSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl';
|
|
114
|
+
|
|
115
|
+
export declare function Badge({ children, variant, size, dot, className, }: BadgeProps): JSX.Element;
|
|
116
|
+
|
|
117
|
+
export declare namespace Badge {
|
|
118
|
+
var displayName: string;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
export declare interface BadgeProps {
|
|
122
|
+
children: default_2.ReactNode;
|
|
123
|
+
variant?: BadgeVariant;
|
|
124
|
+
size?: BadgeSize;
|
|
125
|
+
/** Shows a dot indicator before the label */
|
|
126
|
+
dot?: boolean;
|
|
127
|
+
className?: string;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
export declare type BadgeSize = 'sm' | 'md' | 'lg';
|
|
131
|
+
|
|
132
|
+
export declare type BadgeVariant = 'default' | 'primary' | 'success' | 'warning' | 'error' | 'info' | 'neutral';
|
|
133
|
+
|
|
134
|
+
export declare interface BreadcrumbItem {
|
|
135
|
+
label: string;
|
|
136
|
+
href?: string;
|
|
137
|
+
onClick?: (e: default_2.MouseEvent) => void;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
export declare const Breadcrumbs: default_2.ForwardRefExoticComponent<BreadcrumbsProps & default_2.RefAttributes<HTMLElement>>;
|
|
141
|
+
|
|
142
|
+
export declare interface BreadcrumbsProps {
|
|
143
|
+
items: BreadcrumbItem[];
|
|
144
|
+
separator?: default_2.ReactNode;
|
|
145
|
+
/** Collapse middle items when count exceeds this value */
|
|
146
|
+
maxItems?: number;
|
|
147
|
+
className?: string;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
export declare const Button: ForwardRefExoticComponent<ButtonProps & RefAttributes<HTMLButtonElement>>;
|
|
151
|
+
|
|
152
|
+
export declare interface ButtonProps {
|
|
153
|
+
/** Button label */
|
|
154
|
+
children: ReactNode;
|
|
155
|
+
/** Visual style — matches Figma "Type" property */
|
|
156
|
+
variant?: ButtonType;
|
|
157
|
+
/** Size — matches Figma "Size" property (Small→sm, Medium→md, Large→lg) */
|
|
158
|
+
size?: ButtonSize;
|
|
159
|
+
/** Disables the button */
|
|
160
|
+
disabled?: boolean;
|
|
161
|
+
/** Shows loading spinner, disables interaction */
|
|
162
|
+
loading?: boolean;
|
|
163
|
+
/** HTML button type */
|
|
164
|
+
type?: 'button' | 'submit' | 'reset';
|
|
165
|
+
/** Icon before label */
|
|
166
|
+
leftIcon?: ReactNode;
|
|
167
|
+
/** Icon after label */
|
|
168
|
+
rightIcon?: ReactNode;
|
|
169
|
+
/** Full width */
|
|
170
|
+
fullWidth?: boolean;
|
|
171
|
+
onClick?: MouseEventHandler<HTMLButtonElement>;
|
|
172
|
+
/** Accessible label (use when no visible text) */
|
|
173
|
+
'aria-label'?: string;
|
|
174
|
+
className?: string;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
export declare type ButtonSize = 'sm' | 'md' | 'lg';
|
|
178
|
+
|
|
179
|
+
export declare type ButtonType = 'primary' | 'secondary' | 'tertiary' | 'link' | 'destructive';
|
|
180
|
+
|
|
181
|
+
export declare const Card: default_2.ForwardRefExoticComponent<CardProps & default_2.RefAttributes<HTMLElement>>;
|
|
182
|
+
|
|
183
|
+
export declare function CardBody({ children, className }: CardBodyProps): JSX.Element;
|
|
184
|
+
|
|
185
|
+
export declare namespace CardBody {
|
|
186
|
+
var displayName: string;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
export declare interface CardBodyProps {
|
|
190
|
+
children: default_2.ReactNode;
|
|
191
|
+
className?: string;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
export declare function CardFooter({ children, className }: CardFooterProps): JSX.Element;
|
|
195
|
+
|
|
196
|
+
export declare namespace CardFooter {
|
|
197
|
+
var displayName: string;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
export declare interface CardFooterProps {
|
|
201
|
+
children: default_2.ReactNode;
|
|
202
|
+
className?: string;
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
export declare function CardHeader({ children, className }: CardHeaderProps): JSX.Element;
|
|
206
|
+
|
|
207
|
+
export declare namespace CardHeader {
|
|
208
|
+
var displayName: string;
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
export declare interface CardHeaderProps {
|
|
212
|
+
children: default_2.ReactNode;
|
|
213
|
+
className?: string;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
export declare function CardImage({ aspectRatio, className, alt, ...props }: CardImageProps): JSX.Element;
|
|
217
|
+
|
|
218
|
+
export declare namespace CardImage {
|
|
219
|
+
var displayName: string;
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
export declare interface CardImageProps extends default_2.ImgHTMLAttributes<HTMLImageElement> {
|
|
223
|
+
/** Aspect ratio of image container e.g. '16/9' '4/3' '1/1' */
|
|
224
|
+
aspectRatio?: string;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
export declare interface CardProps {
|
|
228
|
+
variant?: CardVariant;
|
|
229
|
+
/** Make card clickable (adds hover/focus styles) */
|
|
230
|
+
clickable?: boolean;
|
|
231
|
+
/** Pass href to render as <a> */
|
|
232
|
+
href?: string;
|
|
233
|
+
children: default_2.ReactNode;
|
|
234
|
+
className?: string;
|
|
235
|
+
onClick?: default_2.MouseEventHandler;
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
export declare type CardVariant = 'elevated' | 'outlined' | 'filled';
|
|
239
|
+
|
|
240
|
+
export declare const Carousel: default_2.ForwardRefExoticComponent<CarouselProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
241
|
+
|
|
242
|
+
export declare interface CarouselProps extends default_2.HTMLAttributes<HTMLDivElement> {
|
|
243
|
+
slides: default_2.ReactNode[];
|
|
244
|
+
size?: CarouselSize;
|
|
245
|
+
showArrows?: boolean;
|
|
246
|
+
showDots?: boolean;
|
|
247
|
+
autoPlay?: boolean;
|
|
248
|
+
autoPlayInterval?: number;
|
|
249
|
+
loop?: boolean;
|
|
250
|
+
defaultIndex?: number;
|
|
251
|
+
onSlideChange?: (index: number) => void;
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
export declare type CarouselSize = 'sm' | 'md' | 'lg';
|
|
255
|
+
|
|
256
|
+
export declare const Chart: default_2.ForwardRefExoticComponent<ChartProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
257
|
+
|
|
258
|
+
export declare interface ChartProps {
|
|
259
|
+
type: ChartVariant;
|
|
260
|
+
data: ChartData;
|
|
261
|
+
options?: ChartOptions;
|
|
262
|
+
title?: string;
|
|
263
|
+
description?: string;
|
|
264
|
+
height?: number;
|
|
265
|
+
width?: number;
|
|
266
|
+
className?: string;
|
|
267
|
+
id?: string;
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
export declare type ChartVariant = 'line' | 'bar' | 'pie' | 'doughnut';
|
|
271
|
+
|
|
272
|
+
export declare const Checkbox: ForwardRefExoticComponent<CheckboxProps & RefAttributes<HTMLInputElement>>;
|
|
273
|
+
|
|
274
|
+
export declare interface CheckboxProps {
|
|
275
|
+
id?: string;
|
|
276
|
+
name?: string;
|
|
277
|
+
checked?: boolean;
|
|
278
|
+
defaultChecked?: boolean;
|
|
279
|
+
/** Indeterminate state — Figma shows this as a dash/minus */
|
|
280
|
+
indeterminate?: boolean;
|
|
281
|
+
disabled?: boolean;
|
|
282
|
+
required?: boolean;
|
|
283
|
+
/** Label shown next to the checkbox */
|
|
284
|
+
label?: string;
|
|
285
|
+
/** Helper text below */
|
|
286
|
+
helperText?: string;
|
|
287
|
+
/** Error message */
|
|
288
|
+
errorMessage?: string;
|
|
289
|
+
onChange?: default_2.ChangeEventHandler<HTMLInputElement>;
|
|
290
|
+
className?: string;
|
|
291
|
+
}
|
|
292
|
+
|
|
293
|
+
export declare const DatePicker: default_2.ForwardRefExoticComponent<DatePickerProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
294
|
+
|
|
295
|
+
export declare interface DatePickerProps {
|
|
296
|
+
value?: Date | null;
|
|
297
|
+
defaultValue?: Date | null;
|
|
298
|
+
placeholder?: string;
|
|
299
|
+
size?: DatePickerSize;
|
|
300
|
+
disabled?: boolean;
|
|
301
|
+
label?: string;
|
|
302
|
+
error?: string;
|
|
303
|
+
dateFormat?: string;
|
|
304
|
+
minDate?: Date;
|
|
305
|
+
maxDate?: Date;
|
|
306
|
+
onChange?: (date: Date | null) => void;
|
|
307
|
+
className?: string;
|
|
308
|
+
id?: string;
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
export declare type DatePickerSize = 'sm' | 'md' | 'lg';
|
|
312
|
+
|
|
313
|
+
export declare const EmptyState: default_2.ForwardRefExoticComponent<EmptyStateProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
314
|
+
|
|
315
|
+
export declare interface EmptyStateProps extends default_2.HTMLAttributes<HTMLDivElement> {
|
|
316
|
+
icon?: default_2.ReactNode;
|
|
317
|
+
title: string;
|
|
318
|
+
description?: string;
|
|
319
|
+
action?: default_2.ReactNode;
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
export declare const FileUpload: default_2.ForwardRefExoticComponent<FileUploadProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
323
|
+
|
|
324
|
+
export declare interface FileUploadProps {
|
|
325
|
+
accept?: string;
|
|
326
|
+
multiple?: boolean;
|
|
327
|
+
maxSize?: number;
|
|
328
|
+
disabled?: boolean;
|
|
329
|
+
size?: FileUploadSize;
|
|
330
|
+
label?: string;
|
|
331
|
+
hint?: string;
|
|
332
|
+
error?: string;
|
|
333
|
+
onFiles?: (files: File[]) => void;
|
|
334
|
+
className?: string;
|
|
335
|
+
id?: string;
|
|
336
|
+
}
|
|
337
|
+
|
|
338
|
+
export declare type FileUploadSize = 'sm' | 'md' | 'lg';
|
|
339
|
+
|
|
340
|
+
export declare function FormField({ label, helperText, errorMessage, required, disabled, children, className, }: FormFieldProps): JSX.Element;
|
|
341
|
+
|
|
342
|
+
export declare namespace FormField {
|
|
343
|
+
var displayName: string;
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
export declare interface FormFieldProps {
|
|
347
|
+
label?: string;
|
|
348
|
+
helperText?: string;
|
|
349
|
+
errorMessage?: string;
|
|
350
|
+
required?: boolean;
|
|
351
|
+
disabled?: boolean;
|
|
352
|
+
/** The form control — receives id, aria-describedby, aria-invalid automatically */
|
|
353
|
+
children: default_2.ReactElement;
|
|
354
|
+
className?: string;
|
|
355
|
+
}
|
|
356
|
+
|
|
357
|
+
export declare const IconButton: ForwardRefExoticComponent<IconButtonProps & RefAttributes<HTMLButtonElement>>;
|
|
358
|
+
|
|
359
|
+
export declare interface IconButtonProps {
|
|
360
|
+
/** The icon to display — required */
|
|
361
|
+
icon: ReactNode;
|
|
362
|
+
/** Accessible label — required for icon-only buttons */
|
|
363
|
+
'aria-label': string;
|
|
364
|
+
variant?: ButtonType;
|
|
365
|
+
size?: ButtonSize;
|
|
366
|
+
disabled?: boolean;
|
|
367
|
+
loading?: boolean;
|
|
368
|
+
type?: 'button' | 'submit' | 'reset';
|
|
369
|
+
onClick?: MouseEventHandler<HTMLButtonElement>;
|
|
370
|
+
className?: string;
|
|
371
|
+
}
|
|
372
|
+
|
|
373
|
+
export declare const Input: ForwardRefExoticComponent<InputProps & RefAttributes<HTMLInputElement>>;
|
|
374
|
+
|
|
375
|
+
export declare interface InputProps {
|
|
376
|
+
/** Input id — links label to input */
|
|
377
|
+
id?: string;
|
|
378
|
+
/** Input name for forms */
|
|
379
|
+
name?: string;
|
|
380
|
+
/** Input type */
|
|
381
|
+
type?: 'text' | 'email' | 'password' | 'number' | 'search' | 'tel' | 'url';
|
|
382
|
+
/** Current value */
|
|
383
|
+
value?: string;
|
|
384
|
+
/** Default value (uncontrolled) */
|
|
385
|
+
defaultValue?: string;
|
|
386
|
+
/** Placeholder text */
|
|
387
|
+
placeholder?: string;
|
|
388
|
+
/** Label displayed above the input */
|
|
389
|
+
label?: string;
|
|
390
|
+
/** Helper text below the input */
|
|
391
|
+
helperText?: string;
|
|
392
|
+
/** Error message — activates destructive/error state when set */
|
|
393
|
+
errorMessage?: string;
|
|
394
|
+
/** Size — maps from Figma Size property */
|
|
395
|
+
size?: InputSize;
|
|
396
|
+
/** Disabled state */
|
|
397
|
+
disabled?: boolean;
|
|
398
|
+
/** Required field */
|
|
399
|
+
required?: boolean;
|
|
400
|
+
/** Read only */
|
|
401
|
+
readOnly?: boolean;
|
|
402
|
+
/** Icon or text shown before the input value (Figma: Leading icon / Leading text) */
|
|
403
|
+
leadingContent?: default_2.ReactNode;
|
|
404
|
+
/** Icon or text shown after the input value (Figma: Trailing icon / Trailing text) */
|
|
405
|
+
trailingContent?: default_2.ReactNode;
|
|
406
|
+
/** Max character count */
|
|
407
|
+
maxLength?: number;
|
|
408
|
+
onChange?: default_2.ChangeEventHandler<HTMLInputElement>;
|
|
409
|
+
onBlur?: default_2.FocusEventHandler<HTMLInputElement>;
|
|
410
|
+
onFocus?: default_2.FocusEventHandler<HTMLInputElement>;
|
|
411
|
+
className?: string;
|
|
412
|
+
'aria-describedby'?: string;
|
|
413
|
+
}
|
|
414
|
+
|
|
415
|
+
export declare type InputSize = 'sm' | 'md' | 'lg';
|
|
416
|
+
|
|
417
|
+
export declare const List: default_2.ForwardRefExoticComponent<ListProps & default_2.RefAttributes<HTMLElement>>;
|
|
418
|
+
|
|
419
|
+
export declare const ListItem: default_2.ForwardRefExoticComponent<ListItemProps & default_2.RefAttributes<HTMLLIElement>>;
|
|
420
|
+
|
|
421
|
+
export declare interface ListItemProps extends default_2.LiHTMLAttributes<HTMLLIElement> {
|
|
422
|
+
disabled?: boolean;
|
|
423
|
+
selected?: boolean;
|
|
424
|
+
leading?: default_2.ReactNode;
|
|
425
|
+
trailing?: default_2.ReactNode;
|
|
426
|
+
}
|
|
427
|
+
|
|
428
|
+
export declare interface ListProps extends default_2.HTMLAttributes<HTMLElement> {
|
|
429
|
+
variant?: ListVariant;
|
|
430
|
+
size?: ListSize;
|
|
431
|
+
divided?: boolean;
|
|
432
|
+
}
|
|
433
|
+
|
|
434
|
+
export declare type ListSize = 'sm' | 'md' | 'lg';
|
|
435
|
+
|
|
436
|
+
export declare type ListVariant = 'unordered' | 'ordered' | 'none';
|
|
437
|
+
|
|
438
|
+
export declare const Modal: default_2.ForwardRefExoticComponent<ModalProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
439
|
+
|
|
440
|
+
export declare function ModalActions({ leading, children, className }: ModalActionsProps): JSX.Element;
|
|
441
|
+
|
|
442
|
+
export declare namespace ModalActions {
|
|
443
|
+
var displayName: string;
|
|
444
|
+
}
|
|
445
|
+
|
|
446
|
+
export declare interface ModalActionsProps {
|
|
447
|
+
/** Left-side content e.g. "Don't show again" checkbox */
|
|
448
|
+
leading?: default_2.ReactNode;
|
|
449
|
+
children: default_2.ReactNode;
|
|
450
|
+
className?: string;
|
|
451
|
+
}
|
|
452
|
+
|
|
453
|
+
export declare interface ModalProps {
|
|
454
|
+
open: boolean;
|
|
455
|
+
onClose: () => void;
|
|
456
|
+
/** Modal dialog title */
|
|
457
|
+
title?: default_2.ReactNode;
|
|
458
|
+
/** Subtitle / description below title */
|
|
459
|
+
description?: default_2.ReactNode;
|
|
460
|
+
/** Footer actions — use ModalActions */
|
|
461
|
+
footer?: default_2.ReactNode;
|
|
462
|
+
size?: ModalSize;
|
|
463
|
+
/** Prevent closing on backdrop click */
|
|
464
|
+
preventBackdropClose?: boolean;
|
|
465
|
+
/** Hide the × close button */
|
|
466
|
+
hideCloseButton?: boolean;
|
|
467
|
+
children?: default_2.ReactNode;
|
|
468
|
+
className?: string;
|
|
469
|
+
}
|
|
470
|
+
|
|
471
|
+
export declare type ModalSize = 'sm' | 'md' | 'lg' | 'xl' | 'full';
|
|
472
|
+
|
|
473
|
+
export declare const MultiSelect: default_2.ForwardRefExoticComponent<MultiSelectProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
474
|
+
|
|
475
|
+
export declare interface MultiSelectProps {
|
|
476
|
+
options: SelectOption[];
|
|
477
|
+
value?: string[];
|
|
478
|
+
defaultValue?: string[];
|
|
479
|
+
placeholder?: string;
|
|
480
|
+
size?: SelectSize;
|
|
481
|
+
disabled?: boolean;
|
|
482
|
+
searchable?: boolean;
|
|
483
|
+
label?: string;
|
|
484
|
+
error?: string;
|
|
485
|
+
maxSelected?: number;
|
|
486
|
+
onChange?: (values: string[]) => void;
|
|
487
|
+
className?: string;
|
|
488
|
+
id?: string;
|
|
489
|
+
}
|
|
490
|
+
|
|
491
|
+
declare const Notification_2: default_2.ForwardRefExoticComponent<NotificationProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
492
|
+
export { Notification_2 as Notification }
|
|
493
|
+
|
|
494
|
+
declare interface NotificationContextValue {
|
|
495
|
+
notify: (props: Omit<NotificationProps, 'id'>) => string;
|
|
496
|
+
dismiss: (id: string) => void;
|
|
497
|
+
dismissAll: () => void;
|
|
498
|
+
}
|
|
499
|
+
|
|
500
|
+
export declare type NotificationPosition = 'top-right' | 'top-left' | 'top-center' | 'bottom-right' | 'bottom-left' | 'bottom-center';
|
|
501
|
+
|
|
502
|
+
export declare interface NotificationProps {
|
|
503
|
+
id?: string;
|
|
504
|
+
variant?: NotificationVariant;
|
|
505
|
+
title?: string;
|
|
506
|
+
message: default_2.ReactNode;
|
|
507
|
+
/** Auto-dismiss duration in ms. 0 = never */
|
|
508
|
+
duration?: number;
|
|
509
|
+
dismissible?: boolean;
|
|
510
|
+
onDismiss?: () => void;
|
|
511
|
+
className?: string;
|
|
512
|
+
}
|
|
513
|
+
|
|
514
|
+
export declare function NotificationProvider({ children, position, }: {
|
|
515
|
+
children: default_2.ReactNode;
|
|
516
|
+
position?: NotificationPosition;
|
|
517
|
+
}): JSX.Element;
|
|
518
|
+
|
|
519
|
+
export declare type NotificationVariant = 'info' | 'success' | 'warning' | 'error';
|
|
520
|
+
|
|
521
|
+
export declare const Pagination: default_2.ForwardRefExoticComponent<PaginationProps & default_2.RefAttributes<HTMLElement>>;
|
|
522
|
+
|
|
523
|
+
export declare interface PaginationProps {
|
|
524
|
+
/** Total number of items */
|
|
525
|
+
total: number;
|
|
526
|
+
/** Current page (1-based) */
|
|
527
|
+
page: number;
|
|
528
|
+
/** Items per page */
|
|
529
|
+
pageSize?: number;
|
|
530
|
+
/** Available page size options */
|
|
531
|
+
pageSizeOptions?: number[];
|
|
532
|
+
onPageChange: (page: number) => void;
|
|
533
|
+
onPageSizeChange?: (size: number) => void;
|
|
534
|
+
size?: PaginationSize;
|
|
535
|
+
/** Show first/last page jump buttons */
|
|
536
|
+
showFirstLast?: boolean;
|
|
537
|
+
/** Show the page number buttons */
|
|
538
|
+
showPageNumbers?: boolean;
|
|
539
|
+
/** Show items per page selector */
|
|
540
|
+
showPageSize?: boolean;
|
|
541
|
+
/** Show go-to-page input */
|
|
542
|
+
showGoToPage?: boolean;
|
|
543
|
+
/** Max page buttons shown before ellipsis kicks in */
|
|
544
|
+
siblingCount?: number;
|
|
545
|
+
className?: string;
|
|
546
|
+
}
|
|
547
|
+
|
|
548
|
+
export declare type PaginationSize = 'sm' | 'md';
|
|
549
|
+
|
|
550
|
+
export declare const ProgressBar: default_2.ForwardRefExoticComponent<ProgressBarProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
551
|
+
|
|
552
|
+
export declare interface ProgressBarProps {
|
|
553
|
+
/** Current value (0 – max) */
|
|
554
|
+
value: number;
|
|
555
|
+
max?: number;
|
|
556
|
+
size?: ProgressBarSize;
|
|
557
|
+
variant?: ProgressBarVariant;
|
|
558
|
+
/** Accessible label */
|
|
559
|
+
label?: string;
|
|
560
|
+
/** Show percentage text */
|
|
561
|
+
showValue?: boolean;
|
|
562
|
+
/** Animated stripe overlay */
|
|
563
|
+
animated?: boolean;
|
|
564
|
+
/** Indeterminate / unknown progress */
|
|
565
|
+
indeterminate?: boolean;
|
|
566
|
+
className?: string;
|
|
567
|
+
}
|
|
568
|
+
|
|
569
|
+
export declare type ProgressBarSize = 'sm' | 'md' | 'lg';
|
|
570
|
+
|
|
571
|
+
export declare type ProgressBarVariant = 'default' | 'success' | 'warning' | 'error';
|
|
572
|
+
|
|
573
|
+
export declare const RichTextEditor: default_2.ForwardRefExoticComponent<RichTextEditorProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
574
|
+
|
|
575
|
+
export declare interface RichTextEditorProps {
|
|
576
|
+
value?: string;
|
|
577
|
+
defaultValue?: string;
|
|
578
|
+
placeholder?: string;
|
|
579
|
+
size?: RichTextEditorSize;
|
|
580
|
+
disabled?: boolean;
|
|
581
|
+
label?: string;
|
|
582
|
+
error?: string;
|
|
583
|
+
minHeight?: string;
|
|
584
|
+
onChange?: (html: string) => void;
|
|
585
|
+
className?: string;
|
|
586
|
+
id?: string;
|
|
587
|
+
}
|
|
588
|
+
|
|
589
|
+
export declare type RichTextEditorSize = 'sm' | 'md' | 'lg';
|
|
590
|
+
|
|
591
|
+
export declare const Select: default_2.ForwardRefExoticComponent<SelectProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
592
|
+
|
|
593
|
+
export declare interface SelectOption {
|
|
594
|
+
value: string;
|
|
595
|
+
label: string;
|
|
596
|
+
disabled?: boolean;
|
|
597
|
+
}
|
|
598
|
+
|
|
599
|
+
export declare interface SelectProps {
|
|
600
|
+
options: SelectOption[];
|
|
601
|
+
value?: string;
|
|
602
|
+
defaultValue?: string;
|
|
603
|
+
placeholder?: string;
|
|
604
|
+
size?: SelectSize;
|
|
605
|
+
disabled?: boolean;
|
|
606
|
+
searchable?: boolean;
|
|
607
|
+
clearable?: boolean;
|
|
608
|
+
label?: string;
|
|
609
|
+
error?: string;
|
|
610
|
+
onChange?: (value: string | null) => void;
|
|
611
|
+
className?: string;
|
|
612
|
+
id?: string;
|
|
613
|
+
}
|
|
614
|
+
|
|
615
|
+
export declare type SelectSize = 'sm' | 'md' | 'lg';
|
|
616
|
+
|
|
617
|
+
export declare function Skeleton({ variant, width, height, borderRadius, className, }: SkeletonProps): JSX.Element;
|
|
618
|
+
|
|
619
|
+
export declare namespace Skeleton {
|
|
620
|
+
var displayName: string;
|
|
621
|
+
}
|
|
622
|
+
|
|
623
|
+
export declare interface SkeletonProps {
|
|
624
|
+
variant?: SkeletonVariant;
|
|
625
|
+
/** Width — defaults to 100% for text/rect, fixed for circle */
|
|
626
|
+
width?: string | number;
|
|
627
|
+
/** Height */
|
|
628
|
+
height?: string | number;
|
|
629
|
+
/** Border radius override */
|
|
630
|
+
borderRadius?: string;
|
|
631
|
+
className?: string;
|
|
632
|
+
}
|
|
633
|
+
|
|
634
|
+
export declare type SkeletonVariant = 'text' | 'circle' | 'rect';
|
|
635
|
+
|
|
636
|
+
export declare const Slider: default_2.ForwardRefExoticComponent<SliderProps & default_2.RefAttributes<HTMLInputElement>>;
|
|
637
|
+
|
|
638
|
+
export declare interface SliderProps {
|
|
639
|
+
value?: number;
|
|
640
|
+
defaultValue?: number;
|
|
641
|
+
min?: number;
|
|
642
|
+
max?: number;
|
|
643
|
+
step?: number;
|
|
644
|
+
disabled?: boolean;
|
|
645
|
+
label?: string;
|
|
646
|
+
/** Show current value beside the label */
|
|
647
|
+
showValue?: boolean;
|
|
648
|
+
/** Show tick marks below the track */
|
|
649
|
+
showTicks?: boolean;
|
|
650
|
+
size?: SliderSize;
|
|
651
|
+
onChange?: (value: number) => void;
|
|
652
|
+
/** Custom display format for the value */
|
|
653
|
+
formatValue?: (value: number) => string;
|
|
654
|
+
className?: string;
|
|
655
|
+
}
|
|
656
|
+
|
|
657
|
+
export declare type SliderSize = 'sm' | 'md' | 'lg';
|
|
658
|
+
|
|
659
|
+
export declare type SortDirection = 'asc' | 'desc' | false;
|
|
660
|
+
|
|
661
|
+
export declare function Spinner({ size, variant, label, className, }: SpinnerProps): JSX.Element;
|
|
662
|
+
|
|
663
|
+
export declare namespace Spinner {
|
|
664
|
+
var displayName: string;
|
|
665
|
+
}
|
|
666
|
+
|
|
667
|
+
export declare interface SpinnerProps {
|
|
668
|
+
size?: SpinnerSize;
|
|
669
|
+
variant?: SpinnerVariant;
|
|
670
|
+
/** Screen reader label */
|
|
671
|
+
label?: string;
|
|
672
|
+
className?: string;
|
|
673
|
+
}
|
|
674
|
+
|
|
675
|
+
export declare type SpinnerSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
676
|
+
|
|
677
|
+
export declare type SpinnerVariant = 'primary' | 'white' | 'current';
|
|
678
|
+
|
|
679
|
+
export declare const Stepper: default_2.ForwardRefExoticComponent<StepperProps & default_2.RefAttributes<HTMLElement>>;
|
|
680
|
+
|
|
681
|
+
export declare type StepperOrientation = 'horizontal' | 'vertical';
|
|
682
|
+
|
|
683
|
+
export declare interface StepperProps {
|
|
684
|
+
steps: StepperStep[];
|
|
685
|
+
/** Zero-based index of the current active step */
|
|
686
|
+
activeStep: number;
|
|
687
|
+
orientation?: StepperOrientation;
|
|
688
|
+
/** Allow clicking completed steps to navigate back */
|
|
689
|
+
onStepClick?: (index: number) => void;
|
|
690
|
+
className?: string;
|
|
691
|
+
}
|
|
692
|
+
|
|
693
|
+
export declare interface StepperStep {
|
|
694
|
+
label: string;
|
|
695
|
+
description?: string;
|
|
696
|
+
optional?: boolean;
|
|
697
|
+
}
|
|
698
|
+
|
|
699
|
+
export declare const Switch: ForwardRefExoticComponent<SwitchProps & RefAttributes<HTMLInputElement>>;
|
|
700
|
+
|
|
701
|
+
export declare interface SwitchProps {
|
|
702
|
+
id?: string;
|
|
703
|
+
name?: string;
|
|
704
|
+
checked?: boolean;
|
|
705
|
+
defaultChecked?: boolean;
|
|
706
|
+
disabled?: boolean;
|
|
707
|
+
/** Label shown beside the toggle */
|
|
708
|
+
label?: string;
|
|
709
|
+
/** Label position */
|
|
710
|
+
labelPosition?: 'left' | 'right';
|
|
711
|
+
size?: SwitchSize;
|
|
712
|
+
onChange?: default_2.ChangeEventHandler<HTMLInputElement>;
|
|
713
|
+
className?: string;
|
|
714
|
+
'aria-label'?: string;
|
|
715
|
+
}
|
|
716
|
+
|
|
717
|
+
export declare type SwitchSize = 'sm' | 'md';
|
|
718
|
+
|
|
719
|
+
export declare function Tab({ value, disabled, badge, children, className }: TabProps): JSX.Element;
|
|
720
|
+
|
|
721
|
+
export declare namespace Tab {
|
|
722
|
+
var displayName: string;
|
|
723
|
+
}
|
|
724
|
+
|
|
725
|
+
export declare const Table: <T extends Record<string, unknown>>(props: TableProps<T> & {
|
|
726
|
+
ref?: default_2.Ref<HTMLDivElement>;
|
|
727
|
+
}) => default_2.ReactElement;
|
|
728
|
+
|
|
729
|
+
export declare interface TableColumn<T = Record<string, unknown>> {
|
|
730
|
+
/** Unique key matching a property of T, or a custom id */
|
|
731
|
+
key: string;
|
|
732
|
+
/** Header label */
|
|
733
|
+
header: default_2.ReactNode;
|
|
734
|
+
/** Optional tooltip shown on the ? icon in the header */
|
|
735
|
+
headerTooltip?: string;
|
|
736
|
+
/** Custom cell renderer. Falls back to String(row[key]) */
|
|
737
|
+
cell?: (value: unknown, row: T, index: number) => default_2.ReactNode;
|
|
738
|
+
/** Whether this column is sortable */
|
|
739
|
+
sortable?: boolean;
|
|
740
|
+
/** Column width e.g. '200px' '1fr' '10%' */
|
|
741
|
+
width?: string;
|
|
742
|
+
/** Text alignment within cells */
|
|
743
|
+
align?: 'left' | 'center' | 'right';
|
|
744
|
+
}
|
|
745
|
+
|
|
746
|
+
export declare interface TableProps<T = Record<string, unknown>> {
|
|
747
|
+
columns: TableColumn<T>[];
|
|
748
|
+
data: T[];
|
|
749
|
+
/** Row key accessor — defaults to index */
|
|
750
|
+
rowKey?: (row: T, index: number) => string | number;
|
|
751
|
+
/** Currently sorted column key */
|
|
752
|
+
sortKey?: string;
|
|
753
|
+
/** Current sort direction */
|
|
754
|
+
sortDirection?: SortDirection;
|
|
755
|
+
/** Called when a sortable header is clicked */
|
|
756
|
+
onSort?: (key: string, direction: SortDirection) => void;
|
|
757
|
+
/** Enable row checkboxes */
|
|
758
|
+
selectable?: boolean;
|
|
759
|
+
/** Controlled selected row keys */
|
|
760
|
+
selectedKeys?: Set<string | number>;
|
|
761
|
+
/** Called when selection changes */
|
|
762
|
+
onSelectionChange?: (keys: Set<string | number>) => void;
|
|
763
|
+
/** Alternating row background */
|
|
764
|
+
striped?: boolean;
|
|
765
|
+
/** Highlight row on hover */
|
|
766
|
+
hoverable?: boolean;
|
|
767
|
+
/** Show border around each cell */
|
|
768
|
+
bordered?: boolean;
|
|
769
|
+
/** Compact row padding */
|
|
770
|
+
size?: 'sm' | 'md' | 'lg';
|
|
771
|
+
/** Empty state content */
|
|
772
|
+
emptyState?: default_2.ReactNode;
|
|
773
|
+
/** Loading state — renders skeleton rows */
|
|
774
|
+
loading?: boolean;
|
|
775
|
+
/** Number of skeleton rows shown when loading */
|
|
776
|
+
loadingRows?: number;
|
|
777
|
+
className?: string;
|
|
778
|
+
/** Applied to the grid table element */
|
|
779
|
+
tableClassName?: string;
|
|
780
|
+
}
|
|
781
|
+
|
|
782
|
+
export declare function TabList({ children, className }: TabListProps): JSX.Element;
|
|
783
|
+
|
|
784
|
+
export declare namespace TabList {
|
|
785
|
+
var displayName: string;
|
|
786
|
+
}
|
|
787
|
+
|
|
788
|
+
export declare interface TabListProps {
|
|
789
|
+
children: default_2.ReactNode;
|
|
790
|
+
className?: string;
|
|
791
|
+
}
|
|
792
|
+
|
|
793
|
+
export declare function TabPanel({ value, children, className }: TabPanelProps): JSX.Element | null;
|
|
794
|
+
|
|
795
|
+
export declare namespace TabPanel {
|
|
796
|
+
var displayName: string;
|
|
797
|
+
}
|
|
798
|
+
|
|
799
|
+
export declare interface TabPanelProps {
|
|
800
|
+
value: string;
|
|
801
|
+
children: default_2.ReactNode;
|
|
802
|
+
className?: string;
|
|
803
|
+
}
|
|
804
|
+
|
|
805
|
+
export declare interface TabProps {
|
|
806
|
+
/** Must match the value of the corresponding TabPanel */
|
|
807
|
+
value: string;
|
|
808
|
+
disabled?: boolean;
|
|
809
|
+
/** Optional badge count shown after label */
|
|
810
|
+
badge?: number | string;
|
|
811
|
+
children: default_2.ReactNode;
|
|
812
|
+
className?: string;
|
|
813
|
+
}
|
|
814
|
+
|
|
815
|
+
export declare function Tabs({ value, defaultValue, onValueChange, variant, orientation, size, fullWidth, children, className, }: TabsProps): JSX.Element;
|
|
816
|
+
|
|
817
|
+
export declare namespace Tabs {
|
|
818
|
+
var displayName: string;
|
|
819
|
+
}
|
|
820
|
+
|
|
821
|
+
export declare type TabsOrientation = 'horizontal' | 'vertical';
|
|
822
|
+
|
|
823
|
+
export declare interface TabsProps {
|
|
824
|
+
/** Controlled active tab value */
|
|
825
|
+
value?: string;
|
|
826
|
+
/** Default active tab (uncontrolled) */
|
|
827
|
+
defaultValue?: string;
|
|
828
|
+
onValueChange?: (value: string) => void;
|
|
829
|
+
variant?: TabsVariant;
|
|
830
|
+
orientation?: TabsOrientation;
|
|
831
|
+
size?: TabsSize;
|
|
832
|
+
/** Stretch tabs to fill container width */
|
|
833
|
+
fullWidth?: boolean;
|
|
834
|
+
children: default_2.ReactNode;
|
|
835
|
+
className?: string;
|
|
836
|
+
}
|
|
837
|
+
|
|
838
|
+
export declare type TabsSize = 'sm' | 'md';
|
|
839
|
+
|
|
840
|
+
export declare type TabsVariant = 'underline' | 'button';
|
|
841
|
+
|
|
842
|
+
export declare const Tag: default_2.ForwardRefExoticComponent<TagProps & default_2.RefAttributes<HTMLSpanElement>>;
|
|
843
|
+
|
|
844
|
+
export declare interface TagProps extends default_2.HTMLAttributes<HTMLSpanElement> {
|
|
845
|
+
size?: TagSize;
|
|
846
|
+
variant?: TagVariant;
|
|
847
|
+
dismissible?: boolean;
|
|
848
|
+
onDismiss?: () => void;
|
|
849
|
+
disabled?: boolean;
|
|
850
|
+
}
|
|
851
|
+
|
|
852
|
+
export declare type TagSize = 'sm' | 'md' | 'lg';
|
|
853
|
+
|
|
854
|
+
export declare type TagVariant = 'default' | 'primary' | 'success' | 'warning' | 'error';
|
|
855
|
+
|
|
856
|
+
export declare const Textarea: ForwardRefExoticComponent<TextareaProps & RefAttributes<HTMLTextAreaElement>>;
|
|
857
|
+
|
|
858
|
+
export declare interface TextareaProps {
|
|
859
|
+
id?: string;
|
|
860
|
+
name?: string;
|
|
861
|
+
value?: string;
|
|
862
|
+
defaultValue?: string;
|
|
863
|
+
placeholder?: string;
|
|
864
|
+
label?: string;
|
|
865
|
+
helperText?: string;
|
|
866
|
+
errorMessage?: string;
|
|
867
|
+
disabled?: boolean;
|
|
868
|
+
required?: boolean;
|
|
869
|
+
readOnly?: boolean;
|
|
870
|
+
/** Auto-grows to fit content */
|
|
871
|
+
autoResize?: boolean;
|
|
872
|
+
rows?: number;
|
|
873
|
+
maxLength?: number;
|
|
874
|
+
/** Shows character count when maxLength is set */
|
|
875
|
+
showCount?: boolean;
|
|
876
|
+
onChange?: default_2.ChangeEventHandler<HTMLTextAreaElement>;
|
|
877
|
+
onBlur?: default_2.FocusEventHandler<HTMLTextAreaElement>;
|
|
878
|
+
className?: string;
|
|
879
|
+
}
|
|
880
|
+
|
|
881
|
+
export declare function Tooltip({ content, children, position, delay, className, }: TooltipProps): JSX.Element;
|
|
882
|
+
|
|
883
|
+
export declare namespace Tooltip {
|
|
884
|
+
var displayName: string;
|
|
885
|
+
}
|
|
886
|
+
|
|
887
|
+
export declare type TooltipPosition = 'top' | 'right' | 'bottom' | 'left';
|
|
888
|
+
|
|
889
|
+
export declare interface TooltipProps {
|
|
890
|
+
/** The tooltip content */
|
|
891
|
+
content: default_2.ReactNode;
|
|
892
|
+
/** The element that triggers the tooltip */
|
|
893
|
+
children: default_2.ReactElement;
|
|
894
|
+
position?: TooltipPosition;
|
|
895
|
+
/** Delay in ms before showing */
|
|
896
|
+
delay?: number;
|
|
897
|
+
className?: string;
|
|
898
|
+
}
|
|
899
|
+
|
|
900
|
+
export declare function useNotification(): NotificationContextValue;
|
|
901
|
+
|
|
902
|
+
export { }
|