@boxcustodia/library 2.0.0-alpha.1 → 2.0.0-alpha.10
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 +80 -83
- package/dist/index.d.ts +360 -220
- package/dist/index.es.js +42582 -40571
- package/dist/theme.css +232 -224
- package/package.json +125 -124
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
import { AlertDialog as AlertDialogPrimitive } from '@base-ui/react/alert-dialog';
|
|
1
2
|
import { Avatar as AvatarPrimitive } from '@base-ui/react/avatar';
|
|
2
3
|
import { ButtonHTMLAttributes } from 'react';
|
|
3
|
-
import {
|
|
4
|
+
import { ChangeEvent } from 'react';
|
|
5
|
+
import { CheckboxGroup as CheckboxGroup_3 } from '@base-ui/react/checkbox-group';
|
|
4
6
|
import { Checkbox as CheckboxPrimitive } from '@base-ui/react/checkbox';
|
|
5
7
|
import { ClassNameValue } from 'tailwind-merge';
|
|
6
8
|
import { ClassProp } from 'class-variance-authority/types';
|
|
@@ -9,20 +11,20 @@ import { Collection } from 'react-aria-components';
|
|
|
9
11
|
import { Command } from 'cmdk';
|
|
10
12
|
import { ComponentProps } from 'react';
|
|
11
13
|
import { ComponentPropsWithoutRef } from 'react';
|
|
12
|
-
import { ControllerRenderProps } from 'react-hook-form';
|
|
13
14
|
import { CSSProperties } from 'react';
|
|
14
15
|
import { default as default_2 } from 'react';
|
|
15
16
|
import { DependencyList } from 'react';
|
|
16
|
-
import
|
|
17
|
-
import { DialogProps } from '@radix-ui/react-dialog';
|
|
17
|
+
import { Dialog as DialogPrimitive } from '@base-ui/react/dialog';
|
|
18
|
+
import { DialogProps as DialogProps_2 } from '@radix-ui/react-dialog';
|
|
18
19
|
import { Dispatch } from 'react';
|
|
19
20
|
import * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';
|
|
20
21
|
import { ElementType } from 'react';
|
|
21
|
-
import {
|
|
22
|
-
import { FieldPath } from 'react-hook-form';
|
|
23
|
-
import { FieldValues } from 'react-hook-form';
|
|
22
|
+
import { Field as FieldPrimitive } from '@base-ui/react/field';
|
|
24
23
|
import { FormEvent } from 'react';
|
|
24
|
+
import { Form as FormPrimitive } from '@base-ui/react/form';
|
|
25
|
+
import { HTMLAttributes } from 'react';
|
|
25
26
|
import { HTMLProps } from 'react';
|
|
27
|
+
import { Input as InputPrimitive } from '@base-ui/react/input';
|
|
26
28
|
import { JSX } from 'react/jsx-runtime';
|
|
27
29
|
import { ListIterateeCustom } from 'lodash';
|
|
28
30
|
import { LucideIcon } from 'lucide-react';
|
|
@@ -51,34 +53,94 @@ import { TreeItemContent as TreeItemContent_2 } from 'react-aria-components';
|
|
|
51
53
|
import { TreeItemProps } from 'react-aria-components';
|
|
52
54
|
import { TreeProps } from 'react-aria-components';
|
|
53
55
|
import { useControllableState } from '@radix-ui/react-use-controllable-state';
|
|
54
|
-
import { UseFormProps } from 'react-hook-form';
|
|
55
|
-
import { UseFormReturn } from 'react-hook-form';
|
|
56
56
|
import { useRender } from '@base-ui/react/use-render';
|
|
57
57
|
import { VariantProps } from 'class-variance-authority';
|
|
58
|
-
import { z } from 'zod';
|
|
59
58
|
|
|
60
|
-
|
|
59
|
+
/**
|
|
60
|
+
* Accessible confirmation dialog with cancel and action buttons.
|
|
61
|
+
*
|
|
62
|
+
* The `trigger` prop uses Base UI's `render` prop — no wrapper element is added —
|
|
63
|
+
* making it composable with `<Tooltip>` at the primitive level.
|
|
64
|
+
* For full structural control, use the exported primitives directly.
|
|
65
|
+
*
|
|
66
|
+
* @example
|
|
67
|
+
* ```tsx
|
|
68
|
+
* <AlertDialog
|
|
69
|
+
* trigger={<Button variant="error">Delete account</Button>}
|
|
70
|
+
* title="Delete account?"
|
|
71
|
+
* description="This action cannot be undone."
|
|
72
|
+
* variant="error"
|
|
73
|
+
* actionText="Delete"
|
|
74
|
+
* onAction={handleDelete}
|
|
75
|
+
* />
|
|
76
|
+
* ```
|
|
77
|
+
*/
|
|
78
|
+
export declare function AlertDialog({ trigger, title, description, children, onClose, onAction, variant, closeText, actionText, className, ...props }: AlertDialogProps): JSX.Element;
|
|
61
79
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
80
|
+
/** Semi-transparent overlay rendered behind the popup. */
|
|
81
|
+
export declare function AlertDialogBackdrop({ className, ...props }: AlertDialogPrimitive.Backdrop.Props): JSX.Element;
|
|
82
|
+
|
|
83
|
+
/** Closes the dialog and merges an optional `onClick` into the `render` element. */
|
|
84
|
+
export declare function AlertDialogClose({ className, ...props }: AlertDialogPrimitive.Close.Props): JSX.Element;
|
|
85
|
+
|
|
86
|
+
/** Supplementary description rendered below the title. */
|
|
87
|
+
export declare function AlertDialogDescription({ className, ...props }: AlertDialogPrimitive.Description.Props): JSX.Element;
|
|
88
|
+
|
|
89
|
+
/** Layout wrapper for action buttons. */
|
|
90
|
+
export declare function AlertDialogFooter({ className, ...props }: HTMLAttributes<HTMLDivElement>): JSX.Element;
|
|
91
|
+
|
|
92
|
+
/** Layout wrapper for title and description. */
|
|
93
|
+
export declare function AlertDialogHeader({ className, ...props }: HTMLAttributes<HTMLDivElement>): JSX.Element;
|
|
94
|
+
|
|
95
|
+
/**
|
|
96
|
+
* Dialog content container. Includes Portal, Backdrop and Viewport internally.
|
|
97
|
+
* Pass `portalProps` to configure the portal (e.g. a custom `container`).
|
|
98
|
+
*/
|
|
99
|
+
export declare function AlertDialogPopup({ className, portalProps, ...props }: AlertDialogPrimitive.Popup.Props & {
|
|
100
|
+
portalProps?: AlertDialogPrimitive.Portal.Props;
|
|
101
|
+
}): JSX.Element;
|
|
102
|
+
|
|
103
|
+
export { AlertDialogPrimitive }
|
|
104
|
+
|
|
105
|
+
export declare type AlertDialogProps = Omit<AlertDialogPrimitive.Root.Props, "children"> & {
|
|
106
|
+
/** Element that opens the dialog on click. Passed as Base UI `render` prop — no DOM wrapper added. */
|
|
107
|
+
trigger?: ReactElement;
|
|
108
|
+
/** Dialog heading. */
|
|
109
|
+
title?: ReactNode;
|
|
110
|
+
/** Supporting text rendered below the title. */
|
|
111
|
+
description?: ReactNode;
|
|
112
|
+
/** Custom content rendered between the description and the footer buttons. */
|
|
113
|
+
children?: ReactNode;
|
|
114
|
+
/** Called when the cancel button is clicked. */
|
|
66
115
|
onClose?: () => void;
|
|
116
|
+
/** Called when the action button is clicked. */
|
|
67
117
|
onAction?: () => void;
|
|
68
|
-
variant
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
actionProps?: ComponentProps<typeof DialogClose> & VariantProps<typeof Button>;
|
|
77
|
-
closeText?: React.ReactNode;
|
|
78
|
-
actionText?: React.ReactNode;
|
|
79
|
-
asChild?: boolean;
|
|
118
|
+
/** Visual variant for the action button. @default "default" */
|
|
119
|
+
variant?: VariantProps<typeof buttonVariants>["variant"];
|
|
120
|
+
/** Label for the cancel button. @default "Cancel" */
|
|
121
|
+
closeText?: ReactNode;
|
|
122
|
+
/** Label for the action button. @default "Confirm" */
|
|
123
|
+
actionText?: ReactNode;
|
|
124
|
+
/** Additional className forwarded to the popup panel. */
|
|
125
|
+
className?: string;
|
|
80
126
|
};
|
|
81
127
|
|
|
128
|
+
/** Context root. Holds open state and wraps all dialog parts. */
|
|
129
|
+
export declare function AlertDialogRoot(props: AlertDialogPrimitive.Root.Props): JSX.Element;
|
|
130
|
+
|
|
131
|
+
/** Accessible title rendered as `<h2>`. Required for a11y. */
|
|
132
|
+
export declare function AlertDialogTitle({ className, ...props }: AlertDialogPrimitive.Title.Props): JSX.Element;
|
|
133
|
+
|
|
134
|
+
/**
|
|
135
|
+
* Renders as its `render` element (defaults to `<button>`).
|
|
136
|
+
* Because it uses Base UI's render prop — not Radix Slot — it composes cleanly
|
|
137
|
+
* with `<Tooltip>` and other Base UI triggers on the same DOM element.
|
|
138
|
+
*/
|
|
139
|
+
export declare function AlertDialogTrigger({ className, ...props }: AlertDialogPrimitive.Trigger.Props): JSX.Element;
|
|
140
|
+
|
|
141
|
+
/** Full-screen container that centers the popup. */
|
|
142
|
+
export declare function AlertDialogViewport({ className, ...props }: AlertDialogPrimitive.Viewport.Props): JSX.Element;
|
|
143
|
+
|
|
82
144
|
export declare type ArrayUnion<V, T extends ReadonlyArray<V>> = T[number];
|
|
83
145
|
|
|
84
146
|
declare type ArrowProps = ComponentPropsWithoutRef<typeof TooltipPrimitive.Arrow>;
|
|
@@ -92,11 +154,11 @@ declare interface AsyncState<T> {
|
|
|
92
154
|
|
|
93
155
|
export declare type AtLeastOne<T> = [T, ...T[]];
|
|
94
156
|
|
|
95
|
-
export declare const AutoComplete: ({ items, placeholder, emptyMessage, onSelect, containerClassName, containerProps, inputClassName, inputProps, listClassName, listProps, itemClassName, itemProps, emptyClassName, emptyProps, }:
|
|
157
|
+
export declare const AutoComplete: ({ items, placeholder, emptyMessage, onSelect, containerClassName, containerProps, inputClassName, inputProps, listClassName, listProps, itemClassName, itemProps, emptyClassName, emptyProps, }: Props) => JSX.Element;
|
|
96
158
|
|
|
97
159
|
export declare const AutoCompleteDialog: ({ children, ...props }: AutoCompleteDialogProps) => JSX.Element;
|
|
98
160
|
|
|
99
|
-
declare interface AutoCompleteDialogProps extends
|
|
161
|
+
declare interface AutoCompleteDialogProps extends DialogProps_2 {
|
|
100
162
|
}
|
|
101
163
|
|
|
102
164
|
export declare const AutoCompleteEmpty: (props: React_2.ComponentProps<typeof Command.Empty>) => JSX.Element;
|
|
@@ -141,9 +203,9 @@ declare const avatarVariants: (props?: ({
|
|
|
141
203
|
size?: "sm" | "lg" | "xs" | "md" | "xl" | null | undefined;
|
|
142
204
|
} & ClassProp) | undefined) => string;
|
|
143
205
|
|
|
144
|
-
export declare const BackgroundImage: ({ src, ...props }:
|
|
206
|
+
export declare const BackgroundImage: ({ src, ...props }: Props_2) => JSX.Element;
|
|
145
207
|
|
|
146
|
-
export declare const BaseButton: ({ asChild, onClick, loading: prop, showLoader, icon, iconPosition, loaderReplace, style, ...props }:
|
|
208
|
+
export declare const BaseButton: ({ asChild, onClick, loading: prop, showLoader, icon, iconPosition, loaderReplace, style, ...props }: Props_4) => JSX.Element;
|
|
147
209
|
|
|
148
210
|
declare type BaseButtonProps = ComponentProps<typeof BaseButton>;
|
|
149
211
|
|
|
@@ -152,19 +214,21 @@ export declare type BaseEntity = {
|
|
|
152
214
|
createdAt: Date;
|
|
153
215
|
};
|
|
154
216
|
|
|
155
|
-
declare type BaseProps =
|
|
217
|
+
declare type BaseProps = FormPrimitive.Props;
|
|
218
|
+
|
|
219
|
+
declare type BaseProps_2 = {
|
|
156
220
|
icon?: React.ReactNode;
|
|
157
221
|
rounded?: TagVariant["rounded"];
|
|
158
222
|
} & StyleProps & React.HTMLAttributes<HTMLDivElement>;
|
|
159
223
|
|
|
160
|
-
export declare const Button: (props:
|
|
224
|
+
export declare const Button: (props: Props_3) => JSX.Element;
|
|
161
225
|
|
|
162
226
|
declare type ButtonProps = ComponentProps<typeof Button>;
|
|
163
227
|
|
|
164
228
|
declare type ButtonProps_2 = ComponentProps<typeof Button>;
|
|
165
229
|
|
|
166
|
-
declare const buttonVariants: (props?: ({
|
|
167
|
-
variant?: "default" | "link" | "
|
|
230
|
+
export declare const buttonVariants: (props?: ({
|
|
231
|
+
variant?: "default" | "link" | "error" | "success" | "outline" | "secondary" | "ghost" | null | undefined;
|
|
168
232
|
size?: "default" | "icon" | "sm" | "lg" | null | undefined;
|
|
169
233
|
shape?: "rounded" | "circle" | "square" | null | undefined;
|
|
170
234
|
} & ClassProp) | undefined) => string;
|
|
@@ -242,28 +306,66 @@ declare interface CenterProps extends ComponentProps<"div"> {
|
|
|
242
306
|
inline?: boolean;
|
|
243
307
|
}
|
|
244
308
|
|
|
245
|
-
export declare
|
|
309
|
+
export declare const Checkbox: typeof CheckboxSingle & {
|
|
310
|
+
Item: typeof CheckboxItem;
|
|
311
|
+
Group: typeof CheckboxGroup_2;
|
|
312
|
+
Legend: typeof CheckboxLegend;
|
|
313
|
+
};
|
|
314
|
+
|
|
315
|
+
export declare function CheckboxGroup({ className, ...props }: CheckboxGroup_3.Props): React_2.ReactElement;
|
|
316
|
+
|
|
317
|
+
declare function CheckboxGroup_2({ legend, children, error, description, defaultValue, value, onChange, allValues, disabled, controlFirst, className, }: CheckboxGroupProps): React_2.ReactElement;
|
|
246
318
|
|
|
247
|
-
export declare
|
|
319
|
+
export declare interface CheckboxGroupProps {
|
|
320
|
+
legend?: ReactNode;
|
|
321
|
+
children: ReactNode;
|
|
322
|
+
error?: string;
|
|
323
|
+
description?: ReactNode;
|
|
324
|
+
defaultValue?: string[];
|
|
325
|
+
value?: string[];
|
|
326
|
+
onChange?: (value: string[]) => void;
|
|
327
|
+
allValues?: string[];
|
|
328
|
+
disabled?: boolean;
|
|
329
|
+
controlFirst?: boolean;
|
|
330
|
+
className?: string;
|
|
331
|
+
}
|
|
248
332
|
|
|
249
333
|
export declare function CheckboxIndicator({ className, ...props }: CheckboxPrimitive.Indicator.Props): React_2.ReactElement;
|
|
250
334
|
|
|
335
|
+
declare function CheckboxItem({ className, label, id, ...props }: CheckboxItemProps): React_2.ReactElement;
|
|
336
|
+
|
|
337
|
+
export declare interface CheckboxItemProps extends Omit<CheckboxPrimitive.Root.Props, "children"> {
|
|
338
|
+
label: ReactNode;
|
|
339
|
+
}
|
|
340
|
+
|
|
341
|
+
declare function CheckboxLegend({ children, className }: CheckboxLegendProps): React_2.ReactElement;
|
|
342
|
+
|
|
343
|
+
export declare interface CheckboxLegendProps {
|
|
344
|
+
children: ReactNode;
|
|
345
|
+
className?: string;
|
|
346
|
+
}
|
|
347
|
+
|
|
251
348
|
export { CheckboxPrimitive }
|
|
252
349
|
|
|
253
350
|
declare interface CheckboxProps extends Omit<CheckboxPrimitive.Root.Props, "children"> {
|
|
254
|
-
children?:
|
|
351
|
+
children?: ReactNode;
|
|
352
|
+
label?: ReactNode;
|
|
353
|
+
tooltip?: ReactNode;
|
|
255
354
|
indicatorProps?: CheckboxPrimitive.Indicator.Props;
|
|
355
|
+
controlFirst?: boolean;
|
|
256
356
|
}
|
|
257
357
|
|
|
258
358
|
export declare function CheckboxRoot({ className, ...props }: CheckboxPrimitive.Root.Props): React_2.ReactElement;
|
|
259
359
|
|
|
360
|
+
declare function CheckboxSingle({ className, indicatorProps, label, children, tooltip, controlFirst, required, id, ...props }: CheckboxProps): React_2.ReactElement;
|
|
361
|
+
|
|
260
362
|
export declare type ClassName = string | undefined;
|
|
261
363
|
|
|
262
364
|
export declare const click: (element: HTMLElement) => void;
|
|
263
365
|
|
|
264
366
|
export declare type ClickEvent = React.MouseEvent<HTMLButtonElement, MouseEvent>;
|
|
265
367
|
|
|
266
|
-
declare type ClosableProps =
|
|
368
|
+
declare type ClosableProps = BaseProps_2 & {
|
|
267
369
|
closable: true;
|
|
268
370
|
onClose: () => void;
|
|
269
371
|
};
|
|
@@ -351,34 +453,94 @@ declare type DayProps = {
|
|
|
351
453
|
navigationDate: Date;
|
|
352
454
|
} & HTMLProps<HTMLButtonElement>;
|
|
353
455
|
|
|
354
|
-
|
|
456
|
+
/**
|
|
457
|
+
* General-purpose dialog with optional trigger, title, description, body, and footer.
|
|
458
|
+
*
|
|
459
|
+
* The `trigger` prop uses Base UI's `render` prop — no wrapper element is added —
|
|
460
|
+
* making it composable with `<Tooltip>` at the primitive level.
|
|
461
|
+
* For full structural control, use the exported primitives directly.
|
|
462
|
+
*
|
|
463
|
+
* @example
|
|
464
|
+
* ```tsx
|
|
465
|
+
* <Dialog
|
|
466
|
+
* trigger={<Button>Open settings</Button>}
|
|
467
|
+
* title="Settings"
|
|
468
|
+
* description="Manage your account preferences."
|
|
469
|
+
* footer={<Button onClick={handleSave}>Save</Button>}
|
|
470
|
+
* >
|
|
471
|
+
* <SettingsForm />
|
|
472
|
+
* </Dialog>
|
|
473
|
+
* ```
|
|
474
|
+
*/
|
|
475
|
+
export declare function Dialog({ trigger, title, description, children, footer, onClose, hideClose, closeProps, portalProps, className, onOpenChange, ...props }: DialogProps): JSX.Element;
|
|
476
|
+
|
|
477
|
+
/** Semi-transparent overlay rendered behind the popup. */
|
|
478
|
+
export declare function DialogBackdrop({ className, ...props }: DialogPrimitive.Backdrop.Props): JSX.Element;
|
|
355
479
|
|
|
356
|
-
|
|
480
|
+
/** Closes the dialog and merges an optional `onClick` into the `render` element. */
|
|
481
|
+
export declare function DialogClose({ className, ...props }: DialogPrimitive.Close.Props): JSX.Element;
|
|
357
482
|
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
hideClose?: boolean;
|
|
361
|
-
}) => JSX.Element;
|
|
483
|
+
/** Supplementary description rendered below the title. */
|
|
484
|
+
export declare function DialogDescription({ className, ...props }: DialogPrimitive.Description.Props): JSX.Element;
|
|
362
485
|
|
|
363
|
-
|
|
486
|
+
/** Layout wrapper for action buttons. */
|
|
487
|
+
export declare function DialogFooter({ className, ...props }: HTMLAttributes<HTMLDivElement>): JSX.Element;
|
|
364
488
|
|
|
365
|
-
|
|
489
|
+
/** Layout wrapper for title and description. */
|
|
490
|
+
export declare function DialogHeader({ className, ...props }: HTMLAttributes<HTMLDivElement>): JSX.Element;
|
|
366
491
|
|
|
367
|
-
|
|
492
|
+
/**
|
|
493
|
+
* Dialog content container. Includes Portal, Backdrop and Viewport internally.
|
|
494
|
+
* Pass `portalProps` to configure the portal (e.g. a custom `container`).
|
|
495
|
+
* Pass `closeProps` to customise the close button.
|
|
496
|
+
*/
|
|
497
|
+
export declare function DialogPopup({ className, children, hideClose, closeProps, portalProps, ...props }: DialogPrimitive.Popup.Props & {
|
|
498
|
+
hideClose?: boolean;
|
|
499
|
+
closeProps?: DialogPrimitive.Close.Props;
|
|
500
|
+
portalProps?: DialogPrimitive.Portal.Props;
|
|
501
|
+
}): JSX.Element;
|
|
368
502
|
|
|
369
|
-
export
|
|
503
|
+
export { DialogPrimitive }
|
|
504
|
+
|
|
505
|
+
export declare type DialogProps = Omit<DialogPrimitive.Root.Props, "children"> & {
|
|
506
|
+
/** Element that opens the dialog on click. Passed as Base UI `render` prop — no DOM wrapper added. */
|
|
507
|
+
trigger?: ReactElement;
|
|
508
|
+
/** Dialog heading. */
|
|
509
|
+
title?: ReactNode;
|
|
510
|
+
/** Supporting text rendered below the title. */
|
|
511
|
+
description?: ReactNode;
|
|
512
|
+
/** Body content rendered between the description and the footer. */
|
|
513
|
+
children?: ReactNode;
|
|
514
|
+
/** Content rendered inside the footer wrapper. */
|
|
515
|
+
footer?: ReactNode;
|
|
516
|
+
/** Called when the dialog closes. */
|
|
517
|
+
onClose?: () => void;
|
|
518
|
+
/** Hides the close (×) button inside the popup. */
|
|
519
|
+
hideClose?: boolean;
|
|
520
|
+
/** Props forwarded to the close button primitive. */
|
|
521
|
+
closeProps?: DialogPrimitive.Close.Props;
|
|
522
|
+
/** Props forwarded to the portal. */
|
|
523
|
+
portalProps?: DialogPrimitive.Portal.Props;
|
|
524
|
+
/** Additional className forwarded to the popup panel. */
|
|
525
|
+
className?: string;
|
|
526
|
+
};
|
|
370
527
|
|
|
371
|
-
|
|
528
|
+
/** Context root. Holds open state and wraps all dialog parts. */
|
|
529
|
+
export declare function DialogRoot(props: DialogPrimitive.Root.Props): JSX.Element;
|
|
372
530
|
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
}) => JSX.Element;
|
|
531
|
+
/** Accessible title rendered as `<h2>`. Required for a11y. */
|
|
532
|
+
export declare function DialogTitle({ className, ...props }: DialogPrimitive.Title.Props): JSX.Element;
|
|
376
533
|
|
|
377
|
-
|
|
534
|
+
/**
|
|
535
|
+
* Renders as its `render` element (defaults to `<button>`).
|
|
536
|
+
* Composes cleanly with `<Tooltip>` and other Base UI triggers on the same DOM element.
|
|
537
|
+
*/
|
|
538
|
+
export declare function DialogTrigger({ className, ...props }: DialogPrimitive.Trigger.Props): JSX.Element;
|
|
378
539
|
|
|
379
|
-
|
|
540
|
+
/** Full-screen container that centers the popup. */
|
|
541
|
+
export declare function DialogViewport({ className, ...props }: DialogPrimitive.Viewport.Props): JSX.Element;
|
|
380
542
|
|
|
381
|
-
export declare const Divider: (props:
|
|
543
|
+
export declare const Divider: (props: Props_8) => JSX.Element;
|
|
382
544
|
|
|
383
545
|
export declare const DOTS = "...";
|
|
384
546
|
|
|
@@ -455,7 +617,7 @@ export declare type DropzoneProps = {
|
|
|
455
617
|
onError?: (fileErrors: FileError[]) => void;
|
|
456
618
|
} & Omit<ComponentPropsWithoutRef<"div">, "onDrop" | "onError">;
|
|
457
619
|
|
|
458
|
-
export declare const EmptyState: ({ icon, title, description, className, children, ...props }:
|
|
620
|
+
export declare const EmptyState: ({ icon, title, description, className, children, ...props }: Props_9) => JSX.Element;
|
|
459
621
|
|
|
460
622
|
export declare const ensureReactElement: <P>({ children, as: Wrapper, props, }: EnsureReactElementProps<P>) => ReactElement;
|
|
461
623
|
|
|
@@ -483,20 +645,6 @@ declare interface ExtendedProps {
|
|
|
483
645
|
}
|
|
484
646
|
|
|
485
647
|
declare interface ExtendedProps_2 {
|
|
486
|
-
triggerProps?: ComponentPropsWithoutRef<typeof DialogTrigger>;
|
|
487
|
-
headerProps?: ComponentPropsWithoutRef<typeof DialogHeader>;
|
|
488
|
-
headerClassName?: ClassName;
|
|
489
|
-
titleProps?: ComponentPropsWithoutRef<typeof DialogTitle>;
|
|
490
|
-
titleClassName?: ClassName;
|
|
491
|
-
descriptionProps?: ComponentPropsWithoutRef<typeof DialogDescription>;
|
|
492
|
-
descriptionClassName?: ClassName;
|
|
493
|
-
contentProps?: ComponentPropsWithoutRef<typeof DialogContent>;
|
|
494
|
-
contentClassName?: ClassName;
|
|
495
|
-
footerProps?: ComponentPropsWithoutRef<typeof DialogFooter>;
|
|
496
|
-
footerClassName?: ClassName;
|
|
497
|
-
}
|
|
498
|
-
|
|
499
|
-
declare interface ExtendedProps_3 {
|
|
500
648
|
theadClassName?: ClassName;
|
|
501
649
|
theadProps?: HTMLProps<HTMLTableSectionElement>;
|
|
502
650
|
tbodyClassName?: ClassName;
|
|
@@ -516,7 +664,61 @@ declare interface ExtendedProps_3 {
|
|
|
516
664
|
*/
|
|
517
665
|
export declare const extractInitials: (string: string) => string;
|
|
518
666
|
|
|
519
|
-
export declare
|
|
667
|
+
export declare function Field({ label, description, error, required, tooltip, inline, children, className, labelProps, descriptionProps, errorProps, ...rootProps }: FieldProps): JSX.Element;
|
|
668
|
+
|
|
669
|
+
export declare const FieldControl: typeof FieldPrimitive.Control;
|
|
670
|
+
|
|
671
|
+
export declare function FieldDescription({ className, ...props }: FieldPrimitive.Description.Props): JSX.Element;
|
|
672
|
+
|
|
673
|
+
export declare function FieldError({ className, ...props }: FieldPrimitive.Error.Props): JSX.Element;
|
|
674
|
+
|
|
675
|
+
export declare type FieldErrorItem = {
|
|
676
|
+
message: ReactNode;
|
|
677
|
+
match?: NonNullable<FieldErrorMatch>;
|
|
678
|
+
};
|
|
679
|
+
|
|
680
|
+
export declare type FieldErrorMatch = FieldPrimitive.Error.Props["match"];
|
|
681
|
+
|
|
682
|
+
export declare type FieldErrorProp = string | FieldErrorItem | FieldErrorItem[];
|
|
683
|
+
|
|
684
|
+
export declare function FieldItem({ className, ...props }: FieldPrimitive.Item.Props): JSX.Element;
|
|
685
|
+
|
|
686
|
+
export declare function FieldLabel({ className, ...props }: FieldPrimitive.Label.Props): JSX.Element;
|
|
687
|
+
|
|
688
|
+
export { FieldPrimitive }
|
|
689
|
+
|
|
690
|
+
export declare interface FieldProps extends Omit<FieldPrimitive.Root.Props, "children"> {
|
|
691
|
+
/** Text rendered inside `FieldLabel`. */
|
|
692
|
+
label?: ReactNode;
|
|
693
|
+
/** Helper text rendered below the control. */
|
|
694
|
+
description?: ReactNode;
|
|
695
|
+
/**
|
|
696
|
+
* Error message(s) rendered below the control:
|
|
697
|
+
* - `string` → always renders once the field is invalid.
|
|
698
|
+
* - `{ message, match }` → renders only when the `ValidityState` key matches.
|
|
699
|
+
* - `FieldErrorItem[]` → multiple errors with individual matches.
|
|
700
|
+
*/
|
|
701
|
+
error?: FieldErrorProp;
|
|
702
|
+
/** Shows a red asterisk after the label text. */
|
|
703
|
+
required?: boolean;
|
|
704
|
+
/** Renders an info icon with a tooltip next to the label. */
|
|
705
|
+
tooltip?: ReactNode;
|
|
706
|
+
/**
|
|
707
|
+
* Renders the control before the label on the same row.
|
|
708
|
+
* Use for single checkboxes and switches.
|
|
709
|
+
*/
|
|
710
|
+
inline?: boolean;
|
|
711
|
+
children?: ReactNode;
|
|
712
|
+
labelProps?: FieldPrimitive.Label.Props;
|
|
713
|
+
descriptionProps?: FieldPrimitive.Description.Props;
|
|
714
|
+
errorProps?: Omit<FieldPrimitive.Error.Props, "match" | "children">;
|
|
715
|
+
}
|
|
716
|
+
|
|
717
|
+
export declare function FieldRoot({ className, required, ...props }: FieldPrimitive.Root.Props & {
|
|
718
|
+
required?: boolean;
|
|
719
|
+
}): JSX.Element;
|
|
720
|
+
|
|
721
|
+
export declare const FieldValidity: typeof FieldPrimitive.Validity;
|
|
520
722
|
|
|
521
723
|
declare type FileError = {
|
|
522
724
|
file: File;
|
|
@@ -556,32 +758,14 @@ export declare const FileTypeGroups: Record<string, FileTypeValue[]>;
|
|
|
556
758
|
|
|
557
759
|
export declare type FileTypeValue = (typeof FileType)[keyof typeof FileType];
|
|
558
760
|
|
|
559
|
-
export declare
|
|
560
|
-
|
|
561
|
-
export declare const FormControl: ({ className, ...props }: React_2.ComponentProps<typeof Slot>) => JSX.Element;
|
|
562
|
-
|
|
563
|
-
export declare const FormDescription: ({ className, ...props }: React_2.ComponentProps<"p">) => JSX.Element;
|
|
761
|
+
export declare function Form({ onSubmit, onFormSubmit, className, ...props }: FormProps): default_2.ReactElement;
|
|
564
762
|
|
|
565
|
-
export
|
|
763
|
+
export { FormPrimitive }
|
|
566
764
|
|
|
567
|
-
declare
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
render: (field: ControllerRenderProps<TFieldValues, TName>) => React_2.ReactNode;
|
|
572
|
-
className?: string;
|
|
573
|
-
itemProps?: React_2.ComponentProps<typeof FormItem>;
|
|
574
|
-
labelProps?: React_2.ComponentProps<typeof FormLabel>;
|
|
575
|
-
controlProps?: React_2.ComponentProps<typeof FormControl>;
|
|
576
|
-
descriptionProps?: React_2.ComponentProps<typeof FormDescription>;
|
|
577
|
-
messageProps?: React_2.ComponentProps<typeof FormMessage>;
|
|
578
|
-
};
|
|
579
|
-
|
|
580
|
-
export declare const FormItem: ({ className, ...props }: React_2.ComponentProps<"div">) => JSX.Element;
|
|
581
|
-
|
|
582
|
-
export declare const FormLabel: ({ className, ...props }: React_2.ComponentProps<"label">) => JSX.Element;
|
|
583
|
-
|
|
584
|
-
export declare const FormMessage: ({ className, children, ...props }: React_2.ComponentProps<"p">) => JSX.Element | null;
|
|
765
|
+
export declare interface FormProps extends Omit<BaseProps, "onSubmit" | "onFormSubmit"> {
|
|
766
|
+
onSubmit?: BaseProps["onFormSubmit"];
|
|
767
|
+
onFormSubmit?: BaseProps["onFormSubmit"];
|
|
768
|
+
}
|
|
585
769
|
|
|
586
770
|
export declare interface GenericMenuProps {
|
|
587
771
|
trigger: default_2.ReactNode;
|
|
@@ -599,7 +783,7 @@ declare type GenericObject_2 = Record<string, any>;
|
|
|
599
783
|
|
|
600
784
|
export declare const getFormData: (event: FormEvent<HTMLFormElement>) => Record<string, string>;
|
|
601
785
|
|
|
602
|
-
export declare const Heading: <C extends React.ElementType = "h2">({ className, size, weight, as, ...props }:
|
|
786
|
+
export declare const Heading: <C extends React.ElementType = "h2">({ className, size, weight, as, ...props }: Props_10<C>) => JSX.Element;
|
|
603
787
|
|
|
604
788
|
declare const HeadingVariants: (props?: ({
|
|
605
789
|
size?: "sm" | "lg" | "md" | "xl" | "2xl" | "3xl" | "4xl" | "5xl" | "6xl" | null | undefined;
|
|
@@ -617,7 +801,14 @@ declare type HotkeyOptions = {
|
|
|
617
801
|
|
|
618
802
|
export declare type ID = string | number;
|
|
619
803
|
|
|
620
|
-
export declare
|
|
804
|
+
export declare function Input({ className, nativeInput, onChange, ...props }: InputProps): JSX.Element;
|
|
805
|
+
|
|
806
|
+
export { InputPrimitive }
|
|
807
|
+
|
|
808
|
+
export declare type InputProps = Omit<InputPrimitive.Props, "size" | "onChange"> & {
|
|
809
|
+
onChange?: (value: string, event: ChangeEvent<HTMLInputElement>) => void;
|
|
810
|
+
nativeInput?: boolean;
|
|
811
|
+
};
|
|
621
812
|
|
|
622
813
|
declare interface ItemTimeline {
|
|
623
814
|
content?: ReactNode;
|
|
@@ -636,7 +827,7 @@ export declare function Label({ className, render, required, tooltip, children,
|
|
|
636
827
|
|
|
637
828
|
declare interface LabelProps extends useRender.ComponentProps<"label"> {
|
|
638
829
|
required?: boolean;
|
|
639
|
-
tooltip?:
|
|
830
|
+
tooltip?: ReactNode;
|
|
640
831
|
}
|
|
641
832
|
|
|
642
833
|
/**
|
|
@@ -666,12 +857,12 @@ export declare type LibraryProviderProps = {
|
|
|
666
857
|
tooltipDelay?: ComponentPropsWithoutRef<typeof TooltipPrimitive.Provider>["delay"];
|
|
667
858
|
} & Omit<ToastProviderProps, "children">;
|
|
668
859
|
|
|
669
|
-
export declare const Loader: ({ center, containerClassName, variant, size, ...props }:
|
|
860
|
+
export declare const Loader: ({ center, containerClassName, variant, size, ...props }: Props_11) => JSX.Element;
|
|
670
861
|
|
|
671
862
|
declare type LoaderVariants = VariantProps<typeof loaderVariants>;
|
|
672
863
|
|
|
673
864
|
declare const loaderVariants: (props?: ({
|
|
674
|
-
variant?: "
|
|
865
|
+
variant?: "error" | "success" | "secondary" | "ghost" | "primary" | "warning" | "info" | null | undefined;
|
|
675
866
|
size?: "default" | "sm" | "lg" | "xs" | "xl" | null | undefined;
|
|
676
867
|
} & ClassProp) | undefined) => string;
|
|
677
868
|
|
|
@@ -848,7 +1039,7 @@ declare type Mutation<TArgs extends any[], TReturn> = (...args: TArgs) => Promis
|
|
|
848
1039
|
|
|
849
1040
|
declare type NavigationProps = Pick<CalendarNavigationProps, "goNextProps" | "goBackProps" | "changeViewProps">;
|
|
850
1041
|
|
|
851
|
-
declare type NonClosableProps =
|
|
1042
|
+
declare type NonClosableProps = BaseProps_2 & {
|
|
852
1043
|
closable?: false;
|
|
853
1044
|
onClose?: never;
|
|
854
1045
|
};
|
|
@@ -857,7 +1048,7 @@ declare type noop = (this: any, ...args: any[]) => any;
|
|
|
857
1048
|
|
|
858
1049
|
export declare type Nullable<T> = T | null;
|
|
859
1050
|
|
|
860
|
-
export declare const NumberInput: ({ value: prop, onChange, defaultValue: defaultProp, className, min, max, ...props }:
|
|
1051
|
+
export declare const NumberInput: ({ value: prop, onChange, defaultValue: defaultProp, className, min, max, ...props }: Props_12) => JSX.Element;
|
|
861
1052
|
|
|
862
1053
|
declare type OpenProps = {
|
|
863
1054
|
open?: boolean;
|
|
@@ -876,15 +1067,27 @@ export declare type OverrideProps<T, TOverridden> = Omit<T, keyof TOverridden> &
|
|
|
876
1067
|
|
|
877
1068
|
export declare type PageSize = (typeof TABLE_PAGE_SIZES)[number];
|
|
878
1069
|
|
|
879
|
-
export declare const Pagination: ({ optionProps, className, containerProps, ...rangeProps }:
|
|
1070
|
+
export declare const Pagination: ({ optionProps, className, containerProps, ...rangeProps }: Props_13) => JSX.Element;
|
|
880
1071
|
|
|
881
1072
|
declare interface PaginationOptionProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
882
1073
|
isActive?: boolean;
|
|
883
1074
|
}
|
|
884
1075
|
|
|
885
|
-
|
|
1076
|
+
declare function Password({ className, showIcon, hideIcon, onShow, onHide, toggleable, onChange, ...rest }: PasswordProps): JSX.Element;
|
|
1077
|
+
export { Password }
|
|
1078
|
+
export { Password as PasswordRoot }
|
|
1079
|
+
|
|
1080
|
+
declare type PasswordProps = Omit<InputProps, "unstyled" | "nativeInput"> & {
|
|
1081
|
+
showIcon?: ReactNode;
|
|
1082
|
+
hideIcon?: ReactNode;
|
|
1083
|
+
onShow?: () => void;
|
|
1084
|
+
onHide?: () => void;
|
|
1085
|
+
toggleable?: boolean;
|
|
1086
|
+
};
|
|
1087
|
+
export { PasswordProps }
|
|
1088
|
+
export { PasswordProps as PasswordRootProps }
|
|
886
1089
|
|
|
887
|
-
export declare const Popover: (props:
|
|
1090
|
+
export declare const Popover: (props: Props_14) => JSX.Element;
|
|
888
1091
|
|
|
889
1092
|
export declare const PopoverContent: ({ className, align, sideOffset, matchTriggerWidth, style, focus, ...props }: PopoverContentProps) => JSX.Element;
|
|
890
1093
|
|
|
@@ -904,7 +1107,7 @@ export declare function Progress({ size, variant, className, trackProps, indicat
|
|
|
904
1107
|
export declare function ProgressIndicator({ className, variant, ...props }: Progress_2.Indicator.Props & VariantProps<typeof progressIndicatorVariants>): React_2.ReactElement;
|
|
905
1108
|
|
|
906
1109
|
declare const progressIndicatorVariants: (props?: ({
|
|
907
|
-
variant?: "default" | "
|
|
1110
|
+
variant?: "default" | "error" | "success" | "warning" | "info" | null | undefined;
|
|
908
1111
|
} & ClassProp) | undefined) => string;
|
|
909
1112
|
|
|
910
1113
|
export declare function ProgressLabel({ className, ...props }: Progress_2.Label.Props): React_2.ReactElement;
|
|
@@ -926,50 +1129,23 @@ declare const progressTrackVariants: (props?: ({
|
|
|
926
1129
|
|
|
927
1130
|
export declare function ProgressValue({ className, ...props }: Progress_2.Value.Props): React_2.ReactElement;
|
|
928
1131
|
|
|
929
|
-
declare
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
description?: ReactNode;
|
|
935
|
-
};
|
|
936
|
-
|
|
937
|
-
declare interface Props_11 extends ComponentProps<"div"> {
|
|
938
|
-
label?: ReactNode;
|
|
939
|
-
labelClassName?: string;
|
|
940
|
-
labelProps?: ComponentPropsWithoutRef<"label">;
|
|
941
|
-
error?: ReactNode;
|
|
942
|
-
errorClassName?: string;
|
|
943
|
-
errorProps?: ComponentPropsWithoutRef<"p">;
|
|
1132
|
+
declare interface Props extends ExtendedProps {
|
|
1133
|
+
items: AutoCompleteItem[];
|
|
1134
|
+
placeholder?: string;
|
|
1135
|
+
emptyMessage?: string;
|
|
1136
|
+
onSelect?: (value: AutoCompleteItem["value"], item: AutoCompleteItem) => any;
|
|
944
1137
|
}
|
|
945
1138
|
|
|
946
|
-
declare type
|
|
947
|
-
onSubmit: (data: TFieldValues) => void;
|
|
948
|
-
form: UseFormReturn<TFieldValues, any, any>;
|
|
949
|
-
children: React_2.ReactNode;
|
|
950
|
-
className?: string;
|
|
951
|
-
id?: string;
|
|
952
|
-
};
|
|
953
|
-
|
|
954
|
-
declare type Props_13<C extends React.ElementType> = VariantProps<typeof HeadingVariants> & {
|
|
1139
|
+
declare type Props_10<C extends React.ElementType> = VariantProps<typeof HeadingVariants> & {
|
|
955
1140
|
as?: C;
|
|
956
1141
|
} & Omit<React.ComponentPropsWithoutRef<C>, "as">;
|
|
957
1142
|
|
|
958
|
-
declare type
|
|
959
|
-
/** valor del input */
|
|
960
|
-
value?: string;
|
|
961
|
-
/** functión a ejecutar cuando el valor cambia */
|
|
962
|
-
onChange?: (value: string) => void;
|
|
963
|
-
/** valor por defecto del input */
|
|
964
|
-
defaultValue?: string;
|
|
965
|
-
}>;
|
|
966
|
-
|
|
967
|
-
declare type Props_15 = LucideProps & LoaderVariants & {
|
|
1143
|
+
declare type Props_11 = LucideProps & LoaderVariants & {
|
|
968
1144
|
center?: boolean;
|
|
969
1145
|
containerClassName?: string;
|
|
970
1146
|
};
|
|
971
1147
|
|
|
972
|
-
declare type
|
|
1148
|
+
declare type Props_12 = OverrideProps<ComponentProps<"input">, {
|
|
973
1149
|
/** valor del input */
|
|
974
1150
|
value?: number;
|
|
975
1151
|
/** functión a ejecutar cuando el valor cambia */
|
|
@@ -982,28 +1158,13 @@ declare type Props_16 = OverrideProps<ComponentProps<"input">, {
|
|
|
982
1158
|
max?: number;
|
|
983
1159
|
}>;
|
|
984
1160
|
|
|
985
|
-
declare interface
|
|
1161
|
+
declare interface Props_13 extends useRangePaginationProps {
|
|
986
1162
|
optionProps?: PaginationOptionProps;
|
|
987
1163
|
className?: string;
|
|
988
1164
|
containerProps?: HTMLProps<HTMLDivElement>;
|
|
989
1165
|
}
|
|
990
1166
|
|
|
991
|
-
declare
|
|
992
|
-
/** Clase CSS para el contenedor */
|
|
993
|
-
containerClassName?: string;
|
|
994
|
-
/** Ícono para mostrar la contraseña */
|
|
995
|
-
showIcon?: ReactNode;
|
|
996
|
-
/** Ícono para ocultar la contraseña */
|
|
997
|
-
hideIcon?: ReactNode;
|
|
998
|
-
/** Callback cuando se muestra la contraseña */
|
|
999
|
-
onShow?: () => void;
|
|
1000
|
-
/** Callback cuando se oculta la contraseña */
|
|
1001
|
-
onHide?: () => void;
|
|
1002
|
-
/** Habilita/deshabilita el botón de mostrar/ocultar contraseña */
|
|
1003
|
-
toggleable?: boolean;
|
|
1004
|
-
}>;
|
|
1005
|
-
|
|
1006
|
-
declare interface Props_19 {
|
|
1167
|
+
declare interface Props_14 {
|
|
1007
1168
|
trigger?: ReactNode;
|
|
1008
1169
|
children: ReactNode;
|
|
1009
1170
|
rootProps?: ComponentPropsWithoutRef<typeof PopoverRoot>;
|
|
@@ -1017,56 +1178,51 @@ declare interface Props_19 {
|
|
|
1017
1178
|
offset?: ComponentPropsWithoutRef<typeof PopoverContent>["sideOffset"];
|
|
1018
1179
|
}
|
|
1019
1180
|
|
|
1020
|
-
declare interface
|
|
1021
|
-
asChild?: boolean;
|
|
1022
|
-
loading?: boolean;
|
|
1023
|
-
showLoader?: boolean;
|
|
1024
|
-
icon?: ReactNode;
|
|
1025
|
-
iconPosition?: "start" | "end";
|
|
1026
|
-
loaderReplace?: true;
|
|
1027
|
-
}
|
|
1028
|
-
|
|
1029
|
-
declare interface Props_20 extends ComponentPropsWithoutRef<typeof Slot> {
|
|
1181
|
+
declare interface Props_15 extends ComponentPropsWithoutRef<typeof Slot> {
|
|
1030
1182
|
/** Si el componente está presente o no */
|
|
1031
1183
|
when: ComponentProps<typeof Presence>["present"];
|
|
1032
1184
|
}
|
|
1033
1185
|
|
|
1034
|
-
declare type
|
|
1186
|
+
declare type Props_16<T> = {
|
|
1035
1187
|
data: T[];
|
|
1036
1188
|
columns: ColumnDef<T>[];
|
|
1037
1189
|
onRowClick?: (row: T) => void;
|
|
1038
1190
|
onDoubleClick?: (row: T) => void;
|
|
1039
1191
|
selected?: (row: T) => boolean;
|
|
1040
|
-
} &
|
|
1192
|
+
} & ExtendedProps_2 & Omit<ComponentPropsWithoutRef<typeof TableRoot>, "data" | "selected" | "onDoubleClick">;
|
|
1041
1193
|
|
|
1042
|
-
declare type
|
|
1194
|
+
declare type Props_17 = {
|
|
1043
1195
|
setPageSize?: (value: PageSize) => void;
|
|
1044
1196
|
pageSize?: PageSize;
|
|
1045
1197
|
} & Omit<usePaginationProps, "pageSize"> & TablePaginationExtendedProps;
|
|
1046
1198
|
|
|
1047
|
-
declare type
|
|
1199
|
+
declare type Props_18 = ClosableProps | NonClosableProps;
|
|
1048
1200
|
|
|
1049
|
-
declare type
|
|
1201
|
+
declare type Props_19<T extends TreeNode> = TreeRootProps & {
|
|
1050
1202
|
items: T[];
|
|
1051
1203
|
};
|
|
1052
1204
|
|
|
1053
|
-
declare interface
|
|
1205
|
+
declare interface Props_2 extends HTMLProps<HTMLDivElement> {
|
|
1206
|
+
/**
|
|
1207
|
+
* La URL de la imagen
|
|
1208
|
+
*/
|
|
1209
|
+
src: string;
|
|
1210
|
+
}
|
|
1211
|
+
|
|
1212
|
+
declare interface Props_20<T> extends UseAsyncOptions<T> {
|
|
1054
1213
|
fn: () => Promise<T>;
|
|
1055
1214
|
dependencies?: DependencyList;
|
|
1056
1215
|
}
|
|
1057
1216
|
|
|
1058
|
-
declare
|
|
1059
|
-
items: AutoCompleteItem[];
|
|
1060
|
-
placeholder?: string;
|
|
1061
|
-
emptyMessage?: string;
|
|
1062
|
-
onSelect?: (value: AutoCompleteItem["value"], item: AutoCompleteItem) => any;
|
|
1063
|
-
}
|
|
1217
|
+
declare type Props_3 = BaseButtonProps & VariantProps<typeof buttonVariants>;
|
|
1064
1218
|
|
|
1065
|
-
declare interface Props_4 extends
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1219
|
+
declare interface Props_4 extends ComponentProps<"button"> {
|
|
1220
|
+
asChild?: boolean;
|
|
1221
|
+
loading?: boolean;
|
|
1222
|
+
showLoader?: boolean;
|
|
1223
|
+
icon?: ReactNode;
|
|
1224
|
+
iconPosition?: "start" | "end";
|
|
1225
|
+
loaderReplace?: true;
|
|
1070
1226
|
}
|
|
1071
1227
|
|
|
1072
1228
|
declare type Props_5<TItem extends Record<string, any>> = {
|
|
@@ -1114,19 +1270,16 @@ declare type Props_7 = ComponentProps<"input"> & {
|
|
|
1114
1270
|
renderFooter?: (props: DatePickerFooterProps) => ReactNode;
|
|
1115
1271
|
};
|
|
1116
1272
|
|
|
1117
|
-
declare type Props_8 =
|
|
1118
|
-
|
|
1273
|
+
declare type Props_8 = {
|
|
1274
|
+
orientation?: "horizontal" | "vertical";
|
|
1275
|
+
} & HTMLProps<HTMLHRElement>;
|
|
1276
|
+
|
|
1277
|
+
declare type Props_9 = ComponentPropsWithoutRef<"div"> & {
|
|
1278
|
+
icon?: ReactNode;
|
|
1119
1279
|
title?: ReactNode;
|
|
1120
1280
|
description?: ReactNode;
|
|
1121
|
-
children: ReactNode;
|
|
1122
|
-
footer?: ReactNode;
|
|
1123
|
-
focus?: boolean;
|
|
1124
1281
|
};
|
|
1125
1282
|
|
|
1126
|
-
declare type Props_9 = {
|
|
1127
|
-
orientation?: "horizontal" | "vertical";
|
|
1128
|
-
} & HTMLProps<HTMLHRElement>;
|
|
1129
|
-
|
|
1130
1283
|
declare type PropsWithoutValue<T> = Omit<T, "value" | "onChange" | "defaultValue">;
|
|
1131
1284
|
|
|
1132
1285
|
declare type ProviderProps = ComponentPropsWithoutRef<typeof TooltipPrimitive.Provider>;
|
|
@@ -1270,7 +1423,7 @@ declare type Shortcut = Partial<{
|
|
|
1270
1423
|
shortcutOptions: MenuShortcutProps_2["options"];
|
|
1271
1424
|
}>;
|
|
1272
1425
|
|
|
1273
|
-
export declare const Show: ({ when, ...props }:
|
|
1426
|
+
export declare const Show: ({ when, ...props }: Props_15) => JSX.Element;
|
|
1274
1427
|
|
|
1275
1428
|
export declare type SingleDateValue = {
|
|
1276
1429
|
value?: DateSingle;
|
|
@@ -1350,11 +1503,13 @@ declare interface StepperTriggerProps {
|
|
|
1350
1503
|
|
|
1351
1504
|
declare type StyleProps = ColorProps | VariantProps_2;
|
|
1352
1505
|
|
|
1353
|
-
export declare function Switch({ children, className, id, thumbProps, ...props }: SwitchProps): React_2.ReactElement;
|
|
1506
|
+
export declare function Switch({ children, label, className, id, thumbProps, controlFirst, ...props }: SwitchProps): React_2.ReactElement;
|
|
1354
1507
|
|
|
1355
1508
|
declare interface SwitchProps extends Omit<Switch_2.Root.Props, "children"> {
|
|
1356
1509
|
children?: React_2.ReactNode;
|
|
1510
|
+
label?: React_2.ReactNode;
|
|
1357
1511
|
thumbProps?: Switch_2.Thumb.Props;
|
|
1512
|
+
controlFirst?: boolean;
|
|
1358
1513
|
}
|
|
1359
1514
|
|
|
1360
1515
|
export declare function SwitchRoot({ className, ...props }: Switch_2.Root.Props): React_2.ReactElement;
|
|
@@ -1367,7 +1522,7 @@ export declare interface TabContentProps extends HTMLProps<HTMLDivElement> {
|
|
|
1367
1522
|
value: string;
|
|
1368
1523
|
}
|
|
1369
1524
|
|
|
1370
|
-
export declare const Table: <T>({ data, columns, onRowClick, onDoubleClick, selected, theadClassName, theadProps, tbodyClassName, tbodyProps, trClassName, trProps, thClassName, thProps, tdClassName, tdProps, ...tableProps }:
|
|
1525
|
+
export declare const Table: <T>({ data, columns, onRowClick, onDoubleClick, selected, theadClassName, theadProps, tbodyClassName, tbodyProps, trClassName, trProps, thClassName, thProps, tdClassName, tdProps, ...tableProps }: Props_16<T>) => JSX.Element;
|
|
1371
1526
|
|
|
1372
1527
|
export declare const TABLE_PAGE_SIZES: number[];
|
|
1373
1528
|
|
|
@@ -1395,7 +1550,7 @@ declare type TableHeaderProps = React_2.ComponentProps<"thead">;
|
|
|
1395
1550
|
|
|
1396
1551
|
declare type TableHeadProps = React_2.ComponentProps<"th">;
|
|
1397
1552
|
|
|
1398
|
-
export declare const TablePagination: ({ containerClassName, containerProps, selectClassName, selectProps, sizes, ...props }:
|
|
1553
|
+
export declare const TablePagination: ({ containerClassName, containerProps, selectClassName, selectProps, sizes, ...props }: Props_17) => JSX.Element;
|
|
1399
1554
|
|
|
1400
1555
|
declare interface TablePaginationExtendedProps {
|
|
1401
1556
|
containerClassName?: ClassName;
|
|
@@ -1450,13 +1605,13 @@ export declare interface TabTriggerProps extends Omit<HTMLProps<HTMLButtonElemen
|
|
|
1450
1605
|
value: string;
|
|
1451
1606
|
}
|
|
1452
1607
|
|
|
1453
|
-
export declare const Tag: ({ className, color, variant, rounded, icon, closable, onClose, children, ...props }:
|
|
1608
|
+
export declare const Tag: ({ className, color, variant, rounded, icon, closable, onClose, children, ...props }: Props_18) => JSX.Element;
|
|
1454
1609
|
|
|
1455
1610
|
export declare type TagVariant = VariantProps<typeof tagVariants>;
|
|
1456
1611
|
|
|
1457
1612
|
export declare const tagVariants: (props?: ({
|
|
1458
1613
|
rounded?: "default" | "square" | "full" | null | undefined;
|
|
1459
|
-
variant?: "
|
|
1614
|
+
variant?: "error" | "success" | "outline" | "secondary" | "primary" | "borderless" | null | undefined;
|
|
1460
1615
|
} & ClassProp) | undefined) => string;
|
|
1461
1616
|
|
|
1462
1617
|
export declare const Textarea: ({ className, ...props }: TextAreaProps) => JSX.Element;
|
|
@@ -1617,7 +1772,7 @@ export declare function toastVariants({ variant }?: {
|
|
|
1617
1772
|
* </Tooltip>
|
|
1618
1773
|
* ```
|
|
1619
1774
|
*/
|
|
1620
|
-
export declare function Tooltip({ content, children, open, defaultOpen, onOpenChange, side, align, offset, delay, closeDelay, className, arrowClassName, }: TooltipProps): JSX.Element;
|
|
1775
|
+
export declare function Tooltip({ content, children, open, defaultOpen, onOpenChange, side, align, offset, delay, closeDelay, className, arrowClassName, ...triggerProps }: TooltipProps): JSX.Element;
|
|
1621
1776
|
|
|
1622
1777
|
export declare function TooltipArrow({ className, ...props }: ArrowProps): JSX.Element;
|
|
1623
1778
|
|
|
@@ -1625,7 +1780,7 @@ export declare function TooltipPopup({ className, ...props }: PopupProps): JSX.E
|
|
|
1625
1780
|
|
|
1626
1781
|
export { TooltipPrimitive }
|
|
1627
1782
|
|
|
1628
|
-
export declare type TooltipProps = Omit<RootProps, "children"> & {
|
|
1783
|
+
export declare type TooltipProps = Omit<RootProps, "children"> & Omit<TriggerProps, "render" | "delay" | "closeDelay" | "className" | "content"> & {
|
|
1629
1784
|
/** The element that triggers the tooltip on hover/focus. */
|
|
1630
1785
|
children: ReactElement;
|
|
1631
1786
|
/** Content displayed inside the tooltip popup. */
|
|
@@ -1657,7 +1812,7 @@ export declare function TooltipRoot(props: RootProps): JSX.Element;
|
|
|
1657
1812
|
|
|
1658
1813
|
export declare function TooltipTrigger({ className, ...props }: TriggerProps): JSX.Element;
|
|
1659
1814
|
|
|
1660
|
-
export declare function Tree<T extends TreeNode>({ items, ...props }:
|
|
1815
|
+
export declare function Tree<T extends TreeNode>({ items, ...props }: Props_19<T>): JSX.Element;
|
|
1661
1816
|
|
|
1662
1817
|
export declare const TreeItem: <T extends object>({ className, ...props }: OverrideProps<TreeItemProps<T>, {
|
|
1663
1818
|
id: string | number;
|
|
@@ -1747,7 +1902,7 @@ export declare function useArray<T>(defaultProp: T[]): readonly [T[], {
|
|
|
1747
1902
|
readonly update: (predicate: ListIterateeCustom<T, boolean>, newItem: T | ((item: T) => T)) => void;
|
|
1748
1903
|
}];
|
|
1749
1904
|
|
|
1750
|
-
export declare function useAsync<T>({ fn, dependencies, onError, onSuccess, onFinish, }:
|
|
1905
|
+
export declare function useAsync<T>({ fn, dependencies, onError, onSuccess, onFinish, }: Props_20<T>): AsyncState<T>;
|
|
1751
1906
|
|
|
1752
1907
|
declare interface UseAsyncOptions<T> {
|
|
1753
1908
|
onError?: (error: Error) => void;
|
|
@@ -1780,21 +1935,6 @@ export declare function useEventListener<K extends keyof HTMLElementEventMap, T
|
|
|
1780
1935
|
|
|
1781
1936
|
export declare function useFocusTrap(active?: boolean): (instance: HTMLElement | null) => void;
|
|
1782
1937
|
|
|
1783
|
-
export declare function useForm<T extends FieldValues = FieldValues>(schema: z.ZodType<T>, options?: Partial<UseFormProps<T>>): UseFormReturn<T, any, T>;
|
|
1784
|
-
|
|
1785
|
-
export declare const useFormField: () => {
|
|
1786
|
-
invalid: boolean;
|
|
1787
|
-
isDirty: boolean;
|
|
1788
|
-
isTouched: boolean;
|
|
1789
|
-
isValidating: boolean;
|
|
1790
|
-
error?: FieldError;
|
|
1791
|
-
id: string;
|
|
1792
|
-
name: string;
|
|
1793
|
-
formItemId: string;
|
|
1794
|
-
formDescriptionId: string;
|
|
1795
|
-
formMessageId: string;
|
|
1796
|
-
};
|
|
1797
|
-
|
|
1798
1938
|
export declare function useHotkey(keys: string | string[], handler: (event: KeyboardEvent) => void, options?: HotkeyOptions): RefObject<any>;
|
|
1799
1939
|
|
|
1800
1940
|
export declare function useHover<T extends HTMLElement>(options?: UseHoverOptions): {
|