@boxcustodia/library 2.0.0-alpha.13 → 2.0.0-alpha.14
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 +1 -138
- package/dist/index.d.ts +1083 -715
- package/dist/index.es.js +7077 -56175
- package/dist/theme.css +1 -1
- package/package.json +34 -26
- package/src/__doc__/Examples.tsx +1 -1
- package/src/__doc__/Intro.mdx +3 -3
- package/src/__doc__/Tabs.mdx +112 -0
- package/src/__doc__/V2.mdx +1246 -0
- package/src/components/accordion/accordion.stories.tsx +143 -0
- package/src/components/accordion/accordion.tsx +135 -0
- package/src/components/accordion/index.ts +1 -0
- package/src/components/alert/alert.stories.tsx +24 -4
- package/src/components/alert/alert.tsx +17 -9
- package/src/components/alert-dialog/alert-dialog.stories.tsx +24 -0
- package/src/components/alert-dialog/alert-dialog.test.tsx +1 -1
- package/src/components/alert-dialog/alert-dialog.tsx +58 -10
- package/src/components/auto-complete/auto-complete.stories.tsx +616 -200
- package/src/components/auto-complete/auto-complete.tsx +420 -68
- package/src/components/auto-complete/index.ts +0 -1
- package/src/components/avatar/avatar.stories.tsx +162 -21
- package/src/components/avatar/avatar.tsx +79 -20
- package/src/components/button/button.stories.tsx +219 -294
- package/src/components/button/button.test.tsx +10 -17
- package/src/components/button/button.tsx +78 -19
- package/src/components/button/components/base-button.tsx +30 -53
- package/src/components/button/index.ts +0 -1
- package/src/components/calendar/calendar.stories.tsx +1 -1
- package/src/components/calendar/calendar.tsx +4 -4
- package/src/components/card/card.stories.tsx +141 -69
- package/src/components/card/card.tsx +155 -54
- package/src/components/center/center.stories.tsx +22 -39
- package/src/components/checkbox/checkbox.stories.tsx +25 -5
- package/src/components/checkbox/checkbox.tsx +76 -15
- package/src/components/checkbox-group/checkbox-group.stories.tsx +116 -28
- package/src/components/checkbox-group/checkbox-group.tsx +84 -3
- package/src/components/combobox/combobox.stories.tsx +33 -23
- package/src/components/combobox/combobox.tsx +119 -103
- package/src/components/date-picker/date-input.stories.tsx +14 -6
- package/src/components/date-picker/date-input.tsx +2 -2
- package/src/components/date-picker/date-picker.model.ts +13 -4
- package/src/components/date-picker/date-picker.stories.tsx +38 -12
- package/src/components/date-picker/date-picker.tsx +28 -14
- package/src/components/dialog/dialog.stories.tsx +18 -0
- package/src/components/dialog/dialog.test.tsx +1 -1
- package/src/components/dialog/dialog.tsx +51 -20
- package/src/components/divider/divider.stories.tsx +6 -0
- package/src/components/dropzone/dropzone.stories.tsx +71 -90
- package/src/components/dropzone/dropzone.tsx +383 -105
- package/src/components/dropzone/index.ts +0 -1
- package/src/components/empty/empty.stories.tsx +165 -0
- package/src/components/empty/empty.tsx +156 -0
- package/src/components/empty/index.ts +1 -0
- package/src/components/field/field.stories.tsx +226 -3
- package/src/components/field/field.tsx +77 -42
- package/src/components/form/form.stories.tsx +320 -197
- package/src/components/form/form.tsx +3 -23
- package/src/components/index.ts +2 -6
- package/src/components/input/input.stories.tsx +5 -5
- package/src/components/input/input.tsx +4 -4
- package/src/components/kbd/kbd.stories.tsx +1 -0
- package/src/components/label/label.stories.tsx +16 -0
- package/src/components/label/label.tsx +13 -2
- package/src/components/loader/loader.stories.tsx +7 -5
- package/src/components/loader/loader.tsx +8 -3
- package/src/components/menu/menu-primitives.tsx +207 -196
- package/src/components/menu/menu.stories.tsx +276 -146
- package/src/components/menu/menu.tsx +146 -54
- package/src/components/number-input/number-input.stories.tsx +27 -4
- package/src/components/number-input/number-input.test.tsx +2 -2
- package/src/components/number-input/number-input.tsx +25 -29
- package/src/components/otp/index.ts +1 -0
- package/src/components/otp/otp.stories.tsx +209 -0
- package/src/components/otp/otp.tsx +100 -0
- package/src/components/pagination/index.ts +1 -0
- package/src/components/pagination/pagination.model.ts +2 -0
- package/src/components/pagination/pagination.stories.tsx +154 -59
- package/src/components/pagination/pagination.test.tsx +122 -57
- package/src/components/pagination/pagination.tsx +575 -77
- package/src/components/password/password.stories.tsx +18 -3
- package/src/components/password/password.tsx +26 -10
- package/src/components/popover/popover.stories.tsx +26 -5
- package/src/components/popover/popover.tsx +15 -23
- package/src/components/progress/progress.stories.tsx +1 -0
- package/src/components/radio-group/index.ts +1 -0
- package/src/components/radio-group/radio-group.stories.tsx +251 -0
- package/src/components/radio-group/radio-group.tsx +212 -0
- package/src/components/scroll-area/scroll-area.stories.tsx +1 -0
- package/src/components/select/select.stories.tsx +118 -19
- package/src/components/select/select.tsx +67 -62
- package/src/components/skeleton/skeleton.stories.tsx +1 -0
- package/src/components/stack/stack.stories.tsx +179 -89
- package/src/components/stack/stack.tsx +2 -2
- package/src/components/stepper/index.ts +1 -1
- package/src/components/stepper/stepper.stories.tsx +767 -83
- package/src/components/stepper/stepper.test.tsx +18 -18
- package/src/components/stepper/stepper.tsx +554 -0
- package/src/components/switch/switch.stories.tsx +15 -1
- package/src/components/switch/switch.tsx +17 -4
- package/src/components/table/index.ts +0 -2
- package/src/components/table/table.stories.tsx +131 -18
- package/src/components/table/table.test.tsx +1 -1
- package/src/components/table/table.tsx +183 -77
- package/src/components/tabs/tabs.stories.tsx +373 -155
- package/src/components/tabs/tabs.test.tsx +12 -12
- package/src/components/tabs/tabs.tsx +72 -149
- package/src/components/tag/index.ts +0 -1
- package/src/components/tag/tag.stories.tsx +155 -120
- package/src/components/tag/tag.tsx +47 -95
- package/src/components/textarea/textarea.stories.tsx +8 -22
- package/src/components/textarea/textarea.tsx +17 -79
- package/src/components/timeline/timeline.stories.tsx +323 -42
- package/src/components/timeline/timeline.tsx +359 -132
- package/src/components/toast/toast.stories.tsx +1 -0
- package/src/components/tooltip/tooltip.tsx +11 -9
- package/src/components/tree/index.ts +0 -1
- package/src/components/tree/tree.stories.tsx +365 -408
- package/src/components/tree/tree.test.tsx +163 -0
- package/src/components/tree/tree.tsx +212 -36
- package/src/hooks/useAsync/__doc__/useAsync.stories.tsx +5 -5
- package/src/hooks/useClipboard/__doc__/useClipboard.stories.tsx +1 -3
- package/src/hooks/useDebounceCallback/__doc__/useDebouncedCallback.stories.tsx +6 -6
- package/src/hooks/useDocumentTitle/__doc__/useDocumentTitle.stories.tsx +1 -1
- package/src/hooks/useEventListener/__test__/useEventListener.test.tsx +1 -1
- package/src/hooks/useLocalStorage/__doc__/useLocalStorage.stories.tsx +1 -1
- package/src/hooks/usePagination/usePagination.tsx +36 -24
- package/src/styles/theme.css +1 -1
- package/src/utils/form.tsx +67 -37
- package/src/utils/index.ts +1 -1
- package/src/__doc__/Migration.mdx +0 -451
- package/src/components/auto-complete/auto-complete-primitives.tsx +0 -155
- package/src/components/background-image/background-image.stories.tsx +0 -21
- package/src/components/background-image/background-image.test.tsx +0 -29
- package/src/components/background-image/background-image.tsx +0 -23
- package/src/components/background-image/index.ts +0 -1
- package/src/components/button/button.variants.ts +0 -44
- package/src/components/button/components/loader-overlay.tsx +0 -21
- package/src/components/button/components/loading-icon.tsx +0 -47
- package/src/components/dropzone/upload-primitives.tsx +0 -310
- package/src/components/dropzone/use-dropzone.ts +0 -122
- package/src/components/empty-state/empty-state.stories.tsx +0 -56
- package/src/components/empty-state/empty-state.tsx +0 -39
- package/src/components/empty-state/index.ts +0 -1
- package/src/components/heading/heading.stories.tsx +0 -74
- package/src/components/heading/heading.tsx +0 -28
- package/src/components/heading/heading.variants.ts +0 -27
- package/src/components/heading/index.ts +0 -1
- package/src/components/kbd/kbd.variants.ts +0 -26
- package/src/components/menu/util/render-menu-item.tsx +0 -54
- package/src/components/multi-select/hooks/use-multi-select.ts +0 -66
- package/src/components/multi-select/index.ts +0 -1
- package/src/components/multi-select/multi-select.stories.tsx +0 -294
- package/src/components/multi-select/multi-select.tsx +0 -300
- package/src/components/multi-select/multi-select.variants.ts +0 -22
- package/src/components/pagination/components/pagination-option.tsx +0 -27
- package/src/components/show/index.ts +0 -1
- package/src/components/show/show.stories.tsx +0 -197
- package/src/components/show/show.test.tsx +0 -41
- package/src/components/show/show.tsx +0 -16
- package/src/components/stepper/Stepper.tsx +0 -190
- package/src/components/stepper/context/stepper-context.tsx +0 -11
- package/src/components/table/table-primitives.tsx +0 -122
- package/src/components/table/table.model.ts +0 -20
- package/src/components/table-pagination/index.ts +0 -2
- package/src/components/table-pagination/table-pagination.model.ts +0 -2
- package/src/components/table-pagination/table-pagination.stories.tsx +0 -23
- package/src/components/table-pagination/table-pagination.test.tsx +0 -32
- package/src/components/table-pagination/table-pagination.tsx +0 -108
- package/src/components/tabs/context/tabs-context.tsx +0 -14
- package/src/components/tag/tag.variants.ts +0 -31
- package/src/components/timeline/timeline-status.ts +0 -5
- package/src/components/tree/hooks/use-controllable-tree-state.ts +0 -80
- package/src/components/tree/tree-primitives.tsx +0 -126
package/dist/index.d.ts
CHANGED
|
@@ -1,52 +1,59 @@
|
|
|
1
|
+
import { Accordion as AccordionPrimitive } from '@base-ui/react/accordion';
|
|
1
2
|
import { AlertDialog as AlertDialogPrimitive } from '@base-ui/react/alert-dialog';
|
|
3
|
+
import { Autocomplete as AutocompletePrimitive } from '@base-ui/react/autocomplete';
|
|
2
4
|
import { Avatar as AvatarPrimitive } from '@base-ui/react/avatar';
|
|
3
|
-
import {
|
|
5
|
+
import { Button as Button_2 } from '@base-ui/react/button';
|
|
4
6
|
import { ChangeEvent } from 'react';
|
|
5
7
|
import { CheckboxGroup as CheckboxGroup_3 } from '@base-ui/react/checkbox-group';
|
|
6
8
|
import { Checkbox as CheckboxPrimitive } from '@base-ui/react/checkbox';
|
|
7
9
|
import { ClassNameValue } from 'tailwind-merge';
|
|
8
10
|
import { ClassProp } from 'class-variance-authority/types';
|
|
9
11
|
import { ClassValue } from 'clsx';
|
|
10
|
-
import { Collection } from 'react-aria-components';
|
|
11
12
|
import { Combobox as ComboboxPrimitive } from '@base-ui/react/combobox';
|
|
12
|
-
import { Command } from 'cmdk';
|
|
13
13
|
import { ComponentProps } from 'react';
|
|
14
14
|
import { ComponentPropsWithoutRef } from 'react';
|
|
15
|
+
import { ComponentType } from 'react';
|
|
16
|
+
import { ControllerRenderProps } from 'react-hook-form';
|
|
15
17
|
import { CSSProperties } from 'react';
|
|
16
18
|
import { DayPicker } from 'react-day-picker';
|
|
17
19
|
import { default as default_2 } from 'react';
|
|
18
20
|
import { DependencyList } from 'react';
|
|
19
21
|
import { Dialog as DialogPrimitive } from '@base-ui/react/dialog';
|
|
20
|
-
import { DialogProps as DialogProps_2 } from '@radix-ui/react-dialog';
|
|
21
22
|
import { Dispatch } from 'react';
|
|
22
|
-
import * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';
|
|
23
23
|
import { ElementType } from 'react';
|
|
24
|
+
import { FieldPath } from 'react-hook-form';
|
|
24
25
|
import { Field as FieldPrimitive } from '@base-ui/react/field';
|
|
26
|
+
import { Fieldset as FieldsetPrimitive } from '@base-ui/react/fieldset';
|
|
27
|
+
import { FieldValues } from 'react-hook-form';
|
|
25
28
|
import { FormEvent } from 'react';
|
|
26
29
|
import { Form as FormPrimitive } from '@base-ui/react/form';
|
|
27
30
|
import { HTMLAttributes } from 'react';
|
|
28
31
|
import { HTMLProps } from 'react';
|
|
29
32
|
import { Input as InputPrimitive } from '@base-ui/react/input';
|
|
33
|
+
import { ItemInstance } from '@headless-tree/core';
|
|
30
34
|
import { JSX } from 'react/jsx-runtime';
|
|
35
|
+
import { JSXElementConstructor } from 'react';
|
|
31
36
|
import { ListIterateeCustom } from 'lodash';
|
|
32
37
|
import { LucideIcon } from 'lucide-react';
|
|
33
38
|
import { LucideProps } from 'lucide-react';
|
|
39
|
+
import { Menu as Menu_2 } from '@base-ui/react/menu';
|
|
34
40
|
import { MutableRefObject } from 'react';
|
|
35
41
|
import { NumberField as NumberInputPrimitive } from '@base-ui/react/number-field';
|
|
36
42
|
import { Popover as PopoverPrimitive } from '@base-ui/react/popover';
|
|
37
|
-
import { Presence } from '@radix-ui/react-presence';
|
|
38
43
|
import { Progress as Progress_2 } from '@base-ui/react/progress';
|
|
39
44
|
import * as React_2 from 'react';
|
|
40
45
|
import { ReactElement } from 'react';
|
|
41
46
|
import { ReactNode } from 'react';
|
|
42
47
|
import { ReactPortal } from 'react';
|
|
43
48
|
import { RefObject } from 'react';
|
|
49
|
+
import { RegisterOptions } from 'react-hook-form';
|
|
44
50
|
import { ScrollArea as ScrollAreaPrimitive } from '@base-ui/react/scroll-area';
|
|
45
51
|
import { Select as SelectPrimitive } from '@base-ui/react/select';
|
|
46
52
|
import { Separator as SeparatorPrimitive } from '@base-ui/react/separator';
|
|
47
53
|
import { SetStateAction } from 'react';
|
|
48
|
-
import {
|
|
54
|
+
import { SubmitHandler } from 'react-hook-form';
|
|
49
55
|
import { Switch as Switch_2 } from '@base-ui/react/switch';
|
|
56
|
+
import { Tabs as TabsPrimitive } from '@base-ui/react/tabs';
|
|
50
57
|
import { ToastManager } from '@base-ui/react';
|
|
51
58
|
import { ToastManagerAddOptions as ToastManagerAddOptions_2 } from '@base-ui/react/toast';
|
|
52
59
|
import { ToastManagerPromiseOptions } from '@base-ui/react';
|
|
@@ -54,12 +61,49 @@ import { ToastManagerUpdateOptions } from '@base-ui/react';
|
|
|
54
61
|
import { ToastObject } from '@base-ui/react/toast';
|
|
55
62
|
import { Toast as ToastPrimitive } from '@base-ui/react/toast';
|
|
56
63
|
import { Tooltip as TooltipPrimitive } from '@base-ui/react/tooltip';
|
|
57
|
-
import {
|
|
58
|
-
import { TreeItemProps } from 'react-aria-components';
|
|
59
|
-
import { TreeProps } from 'react-aria-components';
|
|
64
|
+
import { TreeInstance } from '@headless-tree/core';
|
|
60
65
|
import { useControllableState } from '@radix-ui/react-use-controllable-state';
|
|
66
|
+
import { UseFormProps } from 'react-hook-form';
|
|
67
|
+
import { UseFormReturn } from 'react-hook-form';
|
|
61
68
|
import { useRender } from '@base-ui/react/use-render';
|
|
62
69
|
import { VariantProps } from 'class-variance-authority';
|
|
70
|
+
import { z } from 'zod';
|
|
71
|
+
|
|
72
|
+
export declare function Accordion({ items, className, classNames, ...props }: AccordionProps): JSX.Element;
|
|
73
|
+
|
|
74
|
+
export declare function AccordionContent({ className, children, ...props }: AccordionPrimitive.Panel.Props): JSX.Element;
|
|
75
|
+
|
|
76
|
+
export declare function AccordionItem({ className, ...props }: AccordionPrimitive.Item.Props): JSX.Element;
|
|
77
|
+
|
|
78
|
+
declare function AccordionItem({ className, ...props }: AccordionPrimitive.Item.Props): JSX.Element;
|
|
79
|
+
|
|
80
|
+
declare interface AccordionItem_2 {
|
|
81
|
+
value: string;
|
|
82
|
+
trigger: ReactNode;
|
|
83
|
+
content: ReactNode;
|
|
84
|
+
disabled?: boolean;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
export { AccordionPrimitive }
|
|
88
|
+
|
|
89
|
+
declare interface AccordionProps extends Omit<AccordionPrimitive.Root.Props, "children" | "className"> {
|
|
90
|
+
items: AccordionItem_2[];
|
|
91
|
+
/** Styles the accordion root container. */
|
|
92
|
+
className?: string;
|
|
93
|
+
/** Styles applied to each internal slot. */
|
|
94
|
+
classNames?: {
|
|
95
|
+
/** Each collapsible item wrapper. */
|
|
96
|
+
item?: string;
|
|
97
|
+
/** Trigger button that toggles the item. */
|
|
98
|
+
trigger?: string;
|
|
99
|
+
/** Panel that contains the item content. */
|
|
100
|
+
content?: string;
|
|
101
|
+
};
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
export declare function AccordionRoot({ className, ...props }: AccordionPrimitive.Root.Props): JSX.Element;
|
|
105
|
+
|
|
106
|
+
export declare function AccordionTrigger({ className, children, ...props }: AccordionPrimitive.Trigger.Props): JSX.Element;
|
|
63
107
|
|
|
64
108
|
/**
|
|
65
109
|
* Accessible confirmation dialog with cancel and action buttons.
|
|
@@ -68,6 +112,10 @@ import { VariantProps } from 'class-variance-authority';
|
|
|
68
112
|
* making it composable with `<Tooltip>` at the primitive level.
|
|
69
113
|
* For full structural control, use the exported primitives directly.
|
|
70
114
|
*
|
|
115
|
+
* `className` styles the popup panel. `classNames` exposes the `backdrop`,
|
|
116
|
+
* `header`, `title`, `description`, `footer`, `closeButton`, and `actionButton`
|
|
117
|
+
* slots for fine-grained tweaks without dropping to primitives.
|
|
118
|
+
*
|
|
71
119
|
* @example
|
|
72
120
|
* ```tsx
|
|
73
121
|
* <AlertDialog
|
|
@@ -80,7 +128,7 @@ import { VariantProps } from 'class-variance-authority';
|
|
|
80
128
|
* />
|
|
81
129
|
* ```
|
|
82
130
|
*/
|
|
83
|
-
export declare function AlertDialog({ trigger, title, description, children, onClose, onAction, variant, closeText, actionText, className, ...props }: AlertDialogProps): JSX.Element;
|
|
131
|
+
export declare function AlertDialog({ trigger, title, description, children, onClose, onAction, variant, closeText, actionText, className, classNames, ...props }: AlertDialogProps): JSX.Element;
|
|
84
132
|
|
|
85
133
|
/** Semi-transparent overlay rendered behind the popup. */
|
|
86
134
|
export declare function AlertDialogBackdrop({ className, ...props }: AlertDialogPrimitive.Backdrop.Props): JSX.Element;
|
|
@@ -100,9 +148,16 @@ export declare function AlertDialogHeader({ className, ...props }: HTMLAttribute
|
|
|
100
148
|
/**
|
|
101
149
|
* Dialog content container. Includes Portal, Backdrop and Viewport internally.
|
|
102
150
|
* Pass `portalProps` to configure the portal (e.g. a custom `container`).
|
|
151
|
+
* `classNames` styles the internal `backdrop` and `viewport` slots.
|
|
103
152
|
*/
|
|
104
|
-
export declare function AlertDialogPopup({ className, portalProps, ...props }: AlertDialogPrimitive.Popup.Props & {
|
|
153
|
+
export declare function AlertDialogPopup({ className, classNames, portalProps, ...props }: AlertDialogPrimitive.Popup.Props & {
|
|
105
154
|
portalProps?: AlertDialogPrimitive.Portal.Props;
|
|
155
|
+
classNames?: {
|
|
156
|
+
/** Overlay rendered behind the dialog. */
|
|
157
|
+
backdrop?: string;
|
|
158
|
+
/** Full-screen container that centers the popup. */
|
|
159
|
+
viewport?: string;
|
|
160
|
+
};
|
|
106
161
|
}): JSX.Element;
|
|
107
162
|
|
|
108
163
|
export { AlertDialogPrimitive }
|
|
@@ -126,8 +181,25 @@ export declare type AlertDialogProps = Omit<AlertDialogPrimitive.Root.Props, "ch
|
|
|
126
181
|
closeText?: ReactNode;
|
|
127
182
|
/** Label for the action button. @default "Confirm" */
|
|
128
183
|
actionText?: ReactNode;
|
|
129
|
-
/**
|
|
184
|
+
/** Styles the dialog popup panel. */
|
|
130
185
|
className?: string;
|
|
186
|
+
/** Styles applied to each internal slot. */
|
|
187
|
+
classNames?: {
|
|
188
|
+
/** Overlay rendered behind the dialog. */
|
|
189
|
+
backdrop?: string;
|
|
190
|
+
/** Layout wrapper for title and description. */
|
|
191
|
+
header?: string;
|
|
192
|
+
/** Dialog heading. */
|
|
193
|
+
title?: string;
|
|
194
|
+
/** Supporting text below the title. */
|
|
195
|
+
description?: string;
|
|
196
|
+
/** Layout wrapper for action buttons. */
|
|
197
|
+
footer?: string;
|
|
198
|
+
/** Cancel button. */
|
|
199
|
+
closeButton?: string;
|
|
200
|
+
/** Action button. */
|
|
201
|
+
actionButton?: string;
|
|
202
|
+
};
|
|
131
203
|
};
|
|
132
204
|
|
|
133
205
|
/** Context root. Holds open state and wraps all dialog parts. */
|
|
@@ -159,33 +231,127 @@ declare interface AsyncState<T> {
|
|
|
159
231
|
|
|
160
232
|
export declare type AtLeastOne<T> = [T, ...T[]];
|
|
161
233
|
|
|
162
|
-
export declare
|
|
234
|
+
export declare function Autocomplete<TOption extends AutocompleteOption = AutocompleteOption>({ items, value, defaultValue, onValueChange, disabled, readOnly, isLoading, filter, autoHighlight, placeholder, emptyMessage, loadingMessage, renderOption, adornment, startAddon, className, classNames, }: AutocompleteProps<TOption>): default_2.ReactElement;
|
|
235
|
+
|
|
236
|
+
export declare function AutocompleteClear({ className, children, ...props }: AutocompletePrimitive.Clear.Props): default_2.ReactElement;
|
|
237
|
+
|
|
238
|
+
export declare function AutocompleteCollection({ ...props }: AutocompletePrimitive.Collection.Props): default_2.ReactElement;
|
|
239
|
+
|
|
240
|
+
export declare function AutocompleteEmpty({ className, ...props }: AutocompletePrimitive.Empty.Props): default_2.ReactElement;
|
|
241
|
+
|
|
242
|
+
export declare function AutocompleteGroup({ className, ...props }: AutocompletePrimitive.Group.Props): default_2.ReactElement;
|
|
243
|
+
|
|
244
|
+
export declare function AutocompleteGroupLabel({ className, ...props }: AutocompletePrimitive.GroupLabel.Props): default_2.ReactElement;
|
|
163
245
|
|
|
164
|
-
export declare
|
|
246
|
+
export declare function AutocompleteInput({ className, adornment, startAddon, triggerProps, clearProps, ...props }: AutocompletePrimitive.Input.Props & {
|
|
247
|
+
adornment?: "trigger" | "clear";
|
|
248
|
+
startAddon?: default_2.ReactNode;
|
|
249
|
+
ref?: default_2.Ref<HTMLInputElement>;
|
|
250
|
+
triggerProps?: AutocompletePrimitive.Trigger.Props;
|
|
251
|
+
clearProps?: AutocompletePrimitive.Clear.Props;
|
|
252
|
+
}): default_2.ReactElement;
|
|
253
|
+
|
|
254
|
+
export declare function AutocompleteItem({ className, children, ...props }: AutocompletePrimitive.Item.Props): default_2.ReactElement;
|
|
165
255
|
|
|
166
|
-
declare
|
|
256
|
+
export declare function AutocompleteList({ className, ...props }: AutocompletePrimitive.List.Props): default_2.ReactElement;
|
|
257
|
+
|
|
258
|
+
export declare interface AutocompleteOption {
|
|
259
|
+
value: string;
|
|
260
|
+
label: string;
|
|
167
261
|
}
|
|
168
262
|
|
|
169
|
-
export declare
|
|
263
|
+
export declare function AutocompletePopup({ className, children, side, sideOffset, alignOffset, align, anchor, portalProps, ...props }: AutocompletePrimitive.Popup.Props & {
|
|
264
|
+
align?: AutocompletePrimitive.Positioner.Props["align"];
|
|
265
|
+
sideOffset?: AutocompletePrimitive.Positioner.Props["sideOffset"];
|
|
266
|
+
alignOffset?: AutocompletePrimitive.Positioner.Props["alignOffset"];
|
|
267
|
+
side?: AutocompletePrimitive.Positioner.Props["side"];
|
|
268
|
+
anchor?: AutocompletePrimitive.Positioner.Props["anchor"];
|
|
269
|
+
portalProps?: AutocompletePrimitive.Portal.Props;
|
|
270
|
+
}): default_2.ReactElement;
|
|
271
|
+
|
|
272
|
+
export { AutocompletePrimitive }
|
|
273
|
+
|
|
274
|
+
declare interface AutocompleteProps<TOption extends AutocompleteOption = AutocompleteOption> {
|
|
275
|
+
items: TOption[];
|
|
276
|
+
value?: TOption | null;
|
|
277
|
+
defaultValue?: TOption | null;
|
|
278
|
+
onValueChange?: (value: TOption | null) => void;
|
|
279
|
+
disabled?: boolean;
|
|
280
|
+
readOnly?: boolean;
|
|
281
|
+
isLoading?: boolean;
|
|
282
|
+
filter?: AutocompletePrimitive.Root.Props<TOption>["filter"];
|
|
283
|
+
autoHighlight?: boolean | "always";
|
|
284
|
+
placeholder?: string;
|
|
285
|
+
emptyMessage?: string;
|
|
286
|
+
loadingMessage?: string;
|
|
287
|
+
renderOption?: (option: TOption) => default_2.ReactNode;
|
|
288
|
+
adornment?: "trigger" | "clear";
|
|
289
|
+
startAddon?: default_2.ReactNode;
|
|
290
|
+
/** Styles the input field. */
|
|
291
|
+
className?: string;
|
|
292
|
+
/** Styles applied to each internal slot. */
|
|
293
|
+
classNames?: {
|
|
294
|
+
/** Dropdown popup container. */
|
|
295
|
+
popup?: string;
|
|
296
|
+
/** Scrollable list inside the popup. */
|
|
297
|
+
list?: string;
|
|
298
|
+
/** Each option item. */
|
|
299
|
+
item?: string;
|
|
300
|
+
/** Empty state message. */
|
|
301
|
+
empty?: string;
|
|
302
|
+
/** Status row (e.g. loading message). */
|
|
303
|
+
status?: string;
|
|
304
|
+
};
|
|
305
|
+
}
|
|
170
306
|
|
|
171
|
-
export declare const
|
|
307
|
+
export declare const AutocompleteRoot: typeof AutocompletePrimitive.Root;
|
|
172
308
|
|
|
173
|
-
|
|
309
|
+
/**
|
|
310
|
+
* Groups items into a horizontal row within the list.
|
|
311
|
+
* Use to create multi-column grid layouts (color swatches, icon grids, emoji pickers).
|
|
312
|
+
* Each `AutocompleteItem` inside the row remains fully keyboard-navigable.
|
|
313
|
+
*
|
|
314
|
+
* ```tsx
|
|
315
|
+
* <AutocompleteList>
|
|
316
|
+
* {(row) => (
|
|
317
|
+
* <AutocompleteRow key={row.id}>
|
|
318
|
+
* {row.items.map((item) => (
|
|
319
|
+
* <AutocompleteItem key={item.value} value={item}>
|
|
320
|
+
* {item.label}
|
|
321
|
+
* </AutocompleteItem>
|
|
322
|
+
* ))}
|
|
323
|
+
* </AutocompleteRow>
|
|
324
|
+
* )}
|
|
325
|
+
* </AutocompleteList>
|
|
326
|
+
* ```
|
|
327
|
+
*/
|
|
328
|
+
export declare function AutocompleteRow({ className, ...props }: AutocompletePrimitive.Row.Props): default_2.ReactElement;
|
|
174
329
|
|
|
175
|
-
export declare
|
|
330
|
+
export declare function AutocompleteSeparator({ className, ...props }: AutocompletePrimitive.Separator.Props): default_2.ReactElement;
|
|
176
331
|
|
|
177
|
-
export declare
|
|
332
|
+
export declare function AutocompleteStatus({ className, ...props }: AutocompletePrimitive.Status.Props): default_2.ReactElement;
|
|
178
333
|
|
|
179
|
-
export declare
|
|
334
|
+
export declare function AutocompleteTrigger({ className, children, ...props }: AutocompletePrimitive.Trigger.Props): default_2.ReactElement;
|
|
180
335
|
|
|
181
|
-
|
|
336
|
+
/**
|
|
337
|
+
* Renders the selected value's label outside the input element.
|
|
338
|
+
* Useful when building custom trigger-style layouts where the selected item
|
|
339
|
+
* must be displayed independently — e.g., inside a badge, a button, or a custom
|
|
340
|
+
* trigger that replaces the input entirely.
|
|
341
|
+
* Renders nothing when no item is selected.
|
|
342
|
+
*/
|
|
343
|
+
export declare function AutocompleteValue({ ...props }: AutocompletePrimitive.Value.Props): default_2.ReactElement;
|
|
182
344
|
|
|
183
|
-
export declare
|
|
345
|
+
export declare function Avatar({ src, alt, fallback, badge, delay, size, className, classNames, ...props }: AvatarProps): JSX.Element;
|
|
184
346
|
|
|
185
|
-
export declare function
|
|
347
|
+
export declare function AvatarBadge({ className, ...props }: ComponentProps<"span">): JSX.Element;
|
|
186
348
|
|
|
187
349
|
export declare function AvatarFallback({ className, ...props }: AvatarPrimitive.Fallback.Props): JSX.Element;
|
|
188
350
|
|
|
351
|
+
export declare function AvatarGroup({ className, ...props }: ComponentProps<"div">): JSX.Element;
|
|
352
|
+
|
|
353
|
+
export declare function AvatarGroupCount({ className, size, ...props }: ComponentProps<"div"> & VariantProps<typeof avatarVariants>): JSX.Element;
|
|
354
|
+
|
|
189
355
|
export declare function AvatarImage({ className, ...props }: AvatarPrimitive.Image.Props): JSX.Element;
|
|
190
356
|
|
|
191
357
|
export { AvatarPrimitive }
|
|
@@ -194,23 +360,27 @@ declare interface AvatarProps extends Omit<AvatarPrimitive.Root.Props, "children
|
|
|
194
360
|
src?: string;
|
|
195
361
|
alt: string;
|
|
196
362
|
fallback?: ReactNode;
|
|
363
|
+
badge?: ReactNode;
|
|
197
364
|
delay?: AvatarPrimitive.Fallback.Props["delay"];
|
|
198
|
-
shape?: VariantProps<typeof avatarVariants>["shape"];
|
|
199
365
|
size?: VariantProps<typeof avatarVariants>["size"];
|
|
200
|
-
|
|
201
|
-
|
|
366
|
+
/** Styles applied to each internal slot. */
|
|
367
|
+
classNames?: {
|
|
368
|
+
/** Image element rendered when `src` loads successfully. */
|
|
369
|
+
image?: string;
|
|
370
|
+
/** Fallback rendered when no image is available. */
|
|
371
|
+
fallback?: string;
|
|
372
|
+
/** Status/notification badge rendered over the avatar. */
|
|
373
|
+
badge?: string;
|
|
374
|
+
};
|
|
202
375
|
}
|
|
203
376
|
|
|
204
|
-
export declare function AvatarRoot({ className,
|
|
377
|
+
export declare function AvatarRoot({ className, size, ...props }: AvatarPrimitive.Root.Props & VariantProps<typeof avatarVariants>): JSX.Element;
|
|
205
378
|
|
|
206
379
|
declare const avatarVariants: (props?: ({
|
|
207
|
-
|
|
208
|
-
size?: "sm" | "lg" | "xs" | "md" | "xl" | null | undefined;
|
|
380
|
+
size?: "xs" | "sm" | "lg" | "md" | "xl" | null | undefined;
|
|
209
381
|
} & ClassProp) | undefined) => string;
|
|
210
382
|
|
|
211
|
-
export declare const
|
|
212
|
-
|
|
213
|
-
export declare const BaseButton: ({ asChild, onClick, loading: prop, showLoader, icon, iconPosition, loaderReplace, style, ...props }: Props_4) => JSX.Element;
|
|
383
|
+
export declare const BaseButton: ({ onClick, loading: prop, style, children, ...props }: Props_2) => JSX.Element;
|
|
214
384
|
|
|
215
385
|
declare type BaseButtonProps = ComponentProps<typeof BaseButton>;
|
|
216
386
|
|
|
@@ -219,36 +389,60 @@ export declare type BaseEntity = {
|
|
|
219
389
|
createdAt: Date;
|
|
220
390
|
};
|
|
221
391
|
|
|
222
|
-
declare
|
|
223
|
-
|
|
224
|
-
declare type BaseProps_2 = {
|
|
225
|
-
icon?: React.ReactNode;
|
|
226
|
-
rounded?: TagVariant["rounded"];
|
|
227
|
-
} & StyleProps & React.HTMLAttributes<HTMLDivElement>;
|
|
392
|
+
export declare const Button: ({ variant, size, className, icon, children, ...rest }: Props) => JSX.Element;
|
|
228
393
|
|
|
229
|
-
|
|
394
|
+
declare type ButtonOverrides = Omit<ComponentProps<typeof Button>, "onClick" | "disabled" | "render" | "children" | "nativeButton">;
|
|
230
395
|
|
|
231
396
|
declare type ButtonProps = ComponentProps<typeof Button>;
|
|
232
397
|
|
|
233
398
|
export declare const buttonVariants: (props?: ({
|
|
234
|
-
variant?: "default" | "link" | "
|
|
235
|
-
size?: "default" | "icon" | "sm" | "lg" | null | undefined;
|
|
236
|
-
shape?: "rounded" | "circle" | "square" | null | undefined;
|
|
399
|
+
variant?: "default" | "link" | "outline" | "secondary" | "ghost" | "error" | "success" | "warning" | null | undefined;
|
|
400
|
+
size?: "default" | "xs" | "sm" | "lg" | "icon" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
|
|
237
401
|
} & ClassProp) | undefined) => string;
|
|
238
402
|
|
|
239
403
|
export declare function Calendar({ className, classNames, showOutsideDays, components: userComponents, mode, captionLayout, startMonth, endMonth, ...props }: React_2.ComponentProps<typeof DayPicker>): React_2.ReactElement;
|
|
240
404
|
|
|
241
|
-
export declare
|
|
242
|
-
|
|
243
|
-
export declare
|
|
244
|
-
|
|
245
|
-
export declare
|
|
246
|
-
|
|
247
|
-
export declare
|
|
405
|
+
export declare function Card({ title, description, action, footer, children, size, className, classNames, ...props }: CardProps): JSX.Element;
|
|
406
|
+
|
|
407
|
+
export declare function CardAction({ className, ...props }: default_2.ComponentProps<"div">): JSX.Element;
|
|
408
|
+
|
|
409
|
+
export declare function CardContent({ className, ...props }: default_2.ComponentProps<"div">): JSX.Element;
|
|
410
|
+
|
|
411
|
+
export declare function CardDescription({ className, ...props }: default_2.ComponentProps<"div">): JSX.Element;
|
|
412
|
+
|
|
413
|
+
export declare function CardFooter({ className, ...props }: default_2.ComponentProps<"div">): JSX.Element;
|
|
414
|
+
|
|
415
|
+
export declare function CardHeader({ className, ...props }: default_2.ComponentProps<"div">): JSX.Element;
|
|
416
|
+
|
|
417
|
+
declare interface CardProps extends Omit<default_2.ComponentProps<"div">, "children" | "title"> {
|
|
418
|
+
title?: default_2.ReactNode;
|
|
419
|
+
description?: default_2.ReactNode;
|
|
420
|
+
action?: default_2.ReactNode;
|
|
421
|
+
footer?: default_2.ReactNode;
|
|
422
|
+
children?: default_2.ReactNode;
|
|
423
|
+
size?: "default" | "sm";
|
|
424
|
+
/** Styles applied to each internal slot. */
|
|
425
|
+
classNames?: {
|
|
426
|
+
/** Header wrapper holding title, description, and action. */
|
|
427
|
+
header?: string;
|
|
428
|
+
/** Card title text. */
|
|
429
|
+
title?: string;
|
|
430
|
+
/** Supporting description below the title. */
|
|
431
|
+
description?: string;
|
|
432
|
+
/** Action area on the right of the header. */
|
|
433
|
+
action?: string;
|
|
434
|
+
/** Body content rendered between the header and the footer. */
|
|
435
|
+
content?: string;
|
|
436
|
+
/** Footer area below the content. */
|
|
437
|
+
footer?: string;
|
|
438
|
+
};
|
|
439
|
+
}
|
|
248
440
|
|
|
249
|
-
export declare
|
|
441
|
+
export declare function CardRoot({ className, size, ...props }: default_2.ComponentProps<"div"> & {
|
|
442
|
+
size?: "default" | "sm";
|
|
443
|
+
}): JSX.Element;
|
|
250
444
|
|
|
251
|
-
export declare
|
|
445
|
+
export declare function CardTitle({ className, ...props }: default_2.ComponentProps<"div">): JSX.Element;
|
|
252
446
|
|
|
253
447
|
export declare const Center: ({ as: Tag, inline, className, ...props }: CenterProps) => JSX.Element;
|
|
254
448
|
|
|
@@ -263,30 +457,70 @@ export declare const Checkbox: typeof CheckboxSingle & {
|
|
|
263
457
|
Legend: typeof CheckboxLegend;
|
|
264
458
|
};
|
|
265
459
|
|
|
266
|
-
export declare function CheckboxGroup({ className,
|
|
460
|
+
export declare function CheckboxGroup({ legend, children, items, defaultValue, value, onValueChange, allValues, disabled, controlFirst, className, }: CheckboxGroupProps): JSX.Element;
|
|
267
461
|
|
|
268
|
-
declare function CheckboxGroup_2({ legend, children, error, description, defaultValue, value,
|
|
462
|
+
declare function CheckboxGroup_2({ legend, children, error, description, defaultValue, value, onValueChange, allValues, disabled, controlFirst, className, classNames, }: CheckboxGroupProps_2): React_2.ReactElement;
|
|
463
|
+
|
|
464
|
+
export declare const CheckboxGroupContext: React_2.Context<{
|
|
465
|
+
controlFirst: boolean;
|
|
466
|
+
invalid: boolean;
|
|
467
|
+
}>;
|
|
269
468
|
|
|
270
469
|
export declare interface CheckboxGroupProps {
|
|
470
|
+
legend?: ReactNode;
|
|
471
|
+
children?: ReactNode;
|
|
472
|
+
items?: CheckboxOption[];
|
|
473
|
+
defaultValue?: string[];
|
|
474
|
+
value?: string[];
|
|
475
|
+
onValueChange?: (value: string[]) => void;
|
|
476
|
+
allValues?: string[];
|
|
477
|
+
disabled?: boolean;
|
|
478
|
+
controlFirst?: boolean;
|
|
479
|
+
className?: string;
|
|
480
|
+
}
|
|
481
|
+
|
|
482
|
+
declare interface CheckboxGroupProps_2 {
|
|
271
483
|
legend?: ReactNode;
|
|
272
484
|
children: ReactNode;
|
|
273
485
|
error?: string;
|
|
274
486
|
description?: ReactNode;
|
|
275
487
|
defaultValue?: string[];
|
|
276
488
|
value?: string[];
|
|
277
|
-
|
|
489
|
+
onValueChange?: (value: string[]) => void;
|
|
278
490
|
allValues?: string[];
|
|
279
491
|
disabled?: boolean;
|
|
280
492
|
controlFirst?: boolean;
|
|
281
493
|
className?: string;
|
|
494
|
+
/** Styles applied to each internal slot. */
|
|
495
|
+
classNames?: {
|
|
496
|
+
/** Legend element above the items. */
|
|
497
|
+
legend?: string;
|
|
498
|
+
/** Wrapper around the rendered children (items). */
|
|
499
|
+
items?: string;
|
|
500
|
+
/** Description shown below the items when there is no error. */
|
|
501
|
+
description?: string;
|
|
502
|
+
/** Error message shown below the items. */
|
|
503
|
+
error?: string;
|
|
504
|
+
};
|
|
282
505
|
}
|
|
283
506
|
|
|
507
|
+
export declare function CheckboxGroupRoot({ className, ...props }: CheckboxGroup_3.Props): JSX.Element;
|
|
508
|
+
|
|
284
509
|
export declare function CheckboxIndicator({ className, ...props }: CheckboxPrimitive.Indicator.Props): React_2.ReactElement;
|
|
285
510
|
|
|
286
|
-
declare function CheckboxItem({ className, label, id, ...props }: CheckboxItemProps): React_2.ReactElement;
|
|
511
|
+
declare function CheckboxItem({ className, classNames, label, id, ...props }: CheckboxItemProps): React_2.ReactElement;
|
|
287
512
|
|
|
288
513
|
export declare interface CheckboxItemProps extends Omit<CheckboxPrimitive.Root.Props, "children"> {
|
|
289
514
|
label: ReactNode;
|
|
515
|
+
/** Styles applied to each internal slot. */
|
|
516
|
+
classNames?: {
|
|
517
|
+
/** Flex wrapper around checkbox and label. */
|
|
518
|
+
wrapper?: string;
|
|
519
|
+
/** Checkmark indicator inside the checkbox. */
|
|
520
|
+
indicator?: string;
|
|
521
|
+
/** Label element next to the checkbox. */
|
|
522
|
+
label?: string;
|
|
523
|
+
};
|
|
290
524
|
}
|
|
291
525
|
|
|
292
526
|
declare function CheckboxLegend({ children, className, }: CheckboxLegendProps): React_2.ReactElement;
|
|
@@ -296,64 +530,52 @@ export declare interface CheckboxLegendProps {
|
|
|
296
530
|
className?: string;
|
|
297
531
|
}
|
|
298
532
|
|
|
533
|
+
export declare interface CheckboxOption {
|
|
534
|
+
value: string;
|
|
535
|
+
label: ReactNode;
|
|
536
|
+
disabled?: boolean;
|
|
537
|
+
}
|
|
538
|
+
|
|
299
539
|
export { CheckboxPrimitive }
|
|
300
540
|
|
|
301
541
|
declare interface CheckboxProps extends Omit<CheckboxPrimitive.Root.Props, "children"> {
|
|
302
542
|
children?: ReactNode;
|
|
303
543
|
label?: ReactNode;
|
|
304
544
|
tooltip?: ReactNode;
|
|
305
|
-
indicatorProps?: CheckboxPrimitive.Indicator.Props;
|
|
306
545
|
controlFirst?: boolean;
|
|
546
|
+
/** Styles applied to each internal slot. */
|
|
547
|
+
classNames?: {
|
|
548
|
+
/** Flex wrapper around checkbox and label (only rendered when a label is provided). */
|
|
549
|
+
wrapper?: string;
|
|
550
|
+
/** Checkmark indicator inside the checkbox. */
|
|
551
|
+
indicator?: string;
|
|
552
|
+
/** Label element next to the checkbox. */
|
|
553
|
+
label?: string;
|
|
554
|
+
};
|
|
307
555
|
}
|
|
308
556
|
|
|
309
557
|
export declare function CheckboxRoot({ className, ...props }: CheckboxPrimitive.Root.Props): React_2.ReactElement;
|
|
310
558
|
|
|
311
|
-
declare function CheckboxSingle({ className,
|
|
559
|
+
declare function CheckboxSingle({ className, classNames, label, children, tooltip, controlFirst, required, id, ...props }: CheckboxProps): React_2.ReactElement;
|
|
312
560
|
|
|
313
561
|
export declare type ClassName = string | undefined;
|
|
314
562
|
|
|
315
|
-
export declare const click: (element: HTMLElement) => void;
|
|
316
|
-
|
|
317
563
|
export declare type ClickEvent = React.MouseEvent<HTMLButtonElement, MouseEvent>;
|
|
318
564
|
|
|
319
|
-
declare type ClosableProps = BaseProps_2 & {
|
|
320
|
-
closable: true;
|
|
321
|
-
onClose: () => void;
|
|
322
|
-
};
|
|
323
|
-
|
|
324
565
|
export declare function cn(...args: ClassValue[]): string;
|
|
325
566
|
|
|
326
|
-
export { Collection }
|
|
327
|
-
|
|
328
|
-
declare type ColorProps = {
|
|
329
|
-
color: string;
|
|
330
|
-
variant?: "outline" | "borderless";
|
|
331
|
-
};
|
|
332
|
-
|
|
333
567
|
export declare type ColumnDef<T> = {
|
|
334
|
-
/**
|
|
335
|
-
* Header de la columna
|
|
336
|
-
*/
|
|
337
568
|
header: string | (() => ReactNode);
|
|
338
|
-
/**
|
|
339
|
-
* Clave que identifica la columna
|
|
340
|
-
*/
|
|
341
569
|
key: keyof T;
|
|
342
|
-
/**
|
|
343
|
-
* Elemento que se renderiza en la celda
|
|
344
|
-
*/
|
|
345
570
|
cell?: (row: T, index: number) => ReactNode;
|
|
346
|
-
/**
|
|
347
|
-
* Ancho de la columna
|
|
348
|
-
*/
|
|
349
571
|
width?: string | number;
|
|
350
572
|
};
|
|
351
573
|
|
|
352
574
|
/**
|
|
353
575
|
* Composite combobox for single and multiple selection.
|
|
354
576
|
*
|
|
355
|
-
* Items shaped as `{ label, value }
|
|
356
|
-
* extra props. For other shapes, provide `getLabel` and/or `
|
|
577
|
+
* Items shaped as `{ id, name }`, `{ label, value }`, or plain strings/numbers
|
|
578
|
+
* work with no extra props. For other shapes, provide `getLabel` and/or `getId`.
|
|
357
579
|
*
|
|
358
580
|
* In multiple mode, chips are fit dynamically based on the container width —
|
|
359
581
|
* overflowing items show as "+N más". The popup anchors to the chips container automatically.
|
|
@@ -366,20 +588,35 @@ export declare type ColumnDef<T> = {
|
|
|
366
588
|
*/
|
|
367
589
|
export declare function Combobox<TItem = unknown>(allProps: ComboboxProps<TItem>): React_2.ReactElement;
|
|
368
590
|
|
|
369
|
-
declare type ComboboxBaseProps<TItem = unknown> = Omit<
|
|
591
|
+
declare type ComboboxBaseProps<TItem = unknown> = Omit<ComboboxPrimitive.Root.Props<TItem, boolean>, "items" | "itemToStringLabel" | "itemToStringValue" | "children" | "multiple" | "onValueChange" | "value" | "defaultValue"> & {
|
|
370
592
|
items: readonly TItem[];
|
|
593
|
+
/** Returns the display text for an item. Used for filter matching, ARIA, and the trigger input. Defaults to `item.label`, `item.name`, `item.title`, or the stringified primitive. */
|
|
371
594
|
getLabel?: (item: TItem) => string;
|
|
372
|
-
|
|
595
|
+
/** Returns a stable string identifier for an item. Used as the React key and as the hidden form value when `name` is set. Defaults to `item.id`, `item.value`, or the stringified primitive. */
|
|
596
|
+
getId?: (item: TItem) => string;
|
|
373
597
|
renderItem?: (item: TItem) => React_2.ReactNode;
|
|
374
598
|
placeholder?: string;
|
|
375
599
|
emptyText?: string;
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
chipsInputProps?: React_2.ComponentProps<typeof ComboboxChipsInput>;
|
|
379
|
-
popupProps?: React_2.ComponentProps<typeof ComboboxPopup>;
|
|
380
|
-
itemProps?: ComboboxPrimitive.Item.Props;
|
|
381
|
-
listProps?: Omit<ComboboxPrimitive.List.Props, "children">;
|
|
600
|
+
/** Icon or element displayed before the input text (single mode) or chips (multiple mode). */
|
|
601
|
+
startAddon?: React_2.ReactNode;
|
|
382
602
|
showClear?: boolean;
|
|
603
|
+
/** Styles applied to each internal slot. */
|
|
604
|
+
classNames?: {
|
|
605
|
+
/** Text input field in single-select mode. */
|
|
606
|
+
input?: string;
|
|
607
|
+
/** Chips container in multiple-select mode. */
|
|
608
|
+
chips?: string;
|
|
609
|
+
/** Search input inside the popup in multiple-select mode. */
|
|
610
|
+
chipsInput?: string;
|
|
611
|
+
/** Popup panel containing the item list. */
|
|
612
|
+
popup?: string;
|
|
613
|
+
/** Scrollable item list inside the popup. */
|
|
614
|
+
list?: string;
|
|
615
|
+
/** Individual item row. */
|
|
616
|
+
item?: string;
|
|
617
|
+
/** Rendered when no items match the search. */
|
|
618
|
+
empty?: string;
|
|
619
|
+
};
|
|
383
620
|
};
|
|
384
621
|
|
|
385
622
|
export declare function ComboboxChip({ children, removeProps, ...props }: ComboboxPrimitive.Chip.Props & {
|
|
@@ -439,21 +676,15 @@ export declare type ComboboxProps<TItem = unknown> = (ComboboxBaseProps<TItem> &
|
|
|
439
676
|
multiple?: false;
|
|
440
677
|
value?: TItem | null;
|
|
441
678
|
defaultValue?: TItem | null;
|
|
442
|
-
|
|
679
|
+
onValueChange?: (value: TItem | null) => void;
|
|
443
680
|
}) | (ComboboxBaseProps<TItem> & {
|
|
444
681
|
multiple: true;
|
|
445
682
|
value?: TItem[];
|
|
446
683
|
defaultValue?: TItem[];
|
|
447
|
-
|
|
684
|
+
onValueChange?: (value: TItem[]) => void;
|
|
448
685
|
});
|
|
449
686
|
|
|
450
|
-
export declare function ComboboxRoot<Value, Multiple extends boolean | undefined = false>({
|
|
451
|
-
onChange?: ComboboxPrimitive.Root.Props<Value, Multiple>["onValueChange"];
|
|
452
|
-
}): React_2.ReactElement;
|
|
453
|
-
|
|
454
|
-
declare type ComboboxRootPropsAlias<V, M extends boolean | undefined = false> = Omit<ComboboxPrimitive.Root.Props<V, M>, "onValueChange"> & {
|
|
455
|
-
onChange?: ComboboxPrimitive.Root.Props<V, M>["onValueChange"];
|
|
456
|
-
};
|
|
687
|
+
export declare function ComboboxRoot<Value, Multiple extends boolean | undefined = false>({ ...props }: ComboboxPrimitive.Root.Props<Value, Multiple>): React_2.ReactElement;
|
|
457
688
|
|
|
458
689
|
export declare function ComboboxRow({ className, ...props }: ComboboxPrimitive.Row.Props): React_2.ReactElement;
|
|
459
690
|
|
|
@@ -475,8 +706,6 @@ export declare function ComboboxTrigger({ className, children, ...props }: Combo
|
|
|
475
706
|
|
|
476
707
|
export declare function ComboboxValue({ ...props }: ComboboxPrimitive.Value.Props): React_2.ReactElement;
|
|
477
708
|
|
|
478
|
-
declare type ContainerProps = React_2.ComponentProps<"div">;
|
|
479
|
-
|
|
480
709
|
export declare type Controllable<C, T extends NonNullable<unknown>> = OverrideProps<HTMLProps<C>, ControllableState<T>>;
|
|
481
710
|
|
|
482
711
|
export declare type ControllableState<T> = {
|
|
@@ -514,12 +743,16 @@ export declare type DateInputFooterProps = {
|
|
|
514
743
|
export declare type DateInputProps = Omit<ComponentProps<"input">, "value" | "onChange" | "defaultValue"> & {
|
|
515
744
|
value?: Date | null;
|
|
516
745
|
defaultValue?: Date | null;
|
|
517
|
-
|
|
746
|
+
onValueChange?: (value: Date | null) => void;
|
|
518
747
|
disabledDate?: (date: Date) => boolean;
|
|
519
748
|
renderFooter?: (props: DateInputFooterProps) => ReactNode;
|
|
520
749
|
};
|
|
521
750
|
|
|
522
|
-
export declare
|
|
751
|
+
export declare function DatePicker(props: SingleDatePickerProps): ReactElement;
|
|
752
|
+
|
|
753
|
+
export declare function DatePicker(props: RangeDatePickerProps): ReactElement;
|
|
754
|
+
|
|
755
|
+
export declare function DatePicker(props: MultipleDatePickerProps): ReactElement;
|
|
523
756
|
|
|
524
757
|
declare type DatePickerBaseProps = {
|
|
525
758
|
disabled?: boolean;
|
|
@@ -527,6 +760,15 @@ declare type DatePickerBaseProps = {
|
|
|
527
760
|
renderFooter?: (props: DatePickerFooterProps) => ReactNode;
|
|
528
761
|
className?: string;
|
|
529
762
|
required?: boolean;
|
|
763
|
+
/** Styles applied to each internal slot. */
|
|
764
|
+
classNames?: {
|
|
765
|
+
/** Popup panel that opens below the trigger. */
|
|
766
|
+
popup?: string;
|
|
767
|
+
/** Calendar grid inside the popup. */
|
|
768
|
+
calendar?: string;
|
|
769
|
+
/** Footer wrapper rendered below the calendar when `renderFooter` is provided. */
|
|
770
|
+
footer?: string;
|
|
771
|
+
};
|
|
530
772
|
};
|
|
531
773
|
|
|
532
774
|
export declare type DatePickerFooterProps = SingleFooterProps | RangeFooterProps | MultipleFooterProps;
|
|
@@ -547,6 +789,10 @@ export declare type DateRange = {
|
|
|
547
789
|
* making it composable with `<Tooltip>` at the primitive level.
|
|
548
790
|
* For full structural control, use the exported primitives directly.
|
|
549
791
|
*
|
|
792
|
+
* `className` styles the popup panel. `classNames` exposes the `backdrop`,
|
|
793
|
+
* `viewport`, `header`, `title`, `description`, `footer`, and `closeButton`
|
|
794
|
+
* slots for fine-grained tweaks without dropping to primitives.
|
|
795
|
+
*
|
|
550
796
|
* @example
|
|
551
797
|
* ```tsx
|
|
552
798
|
* <Dialog
|
|
@@ -559,7 +805,7 @@ export declare type DateRange = {
|
|
|
559
805
|
* </Dialog>
|
|
560
806
|
* ```
|
|
561
807
|
*/
|
|
562
|
-
export declare function Dialog({ trigger, title, description, children, footer, onClose, hideClose,
|
|
808
|
+
export declare function Dialog({ trigger, title, description, children, footer, onClose, hideClose, className, classNames, onOpenChange, ...props }: DialogProps): JSX.Element;
|
|
563
809
|
|
|
564
810
|
/** Semi-transparent overlay rendered behind the popup. */
|
|
565
811
|
export declare function DialogBackdrop({ className, ...props }: DialogPrimitive.Backdrop.Props): JSX.Element;
|
|
@@ -579,12 +825,19 @@ export declare function DialogHeader({ className, ...props }: HTMLAttributes<HTM
|
|
|
579
825
|
/**
|
|
580
826
|
* Dialog content container. Includes Portal, Backdrop and Viewport internally.
|
|
581
827
|
* Pass `portalProps` to configure the portal (e.g. a custom `container`).
|
|
582
|
-
*
|
|
828
|
+
* `classNames` styles the internal `backdrop`, `viewport` and `closeButton` slots.
|
|
583
829
|
*/
|
|
584
|
-
export declare function DialogPopup({ className, children, hideClose,
|
|
830
|
+
export declare function DialogPopup({ className, classNames, children, hideClose, portalProps, ...props }: DialogPrimitive.Popup.Props & {
|
|
585
831
|
hideClose?: boolean;
|
|
586
|
-
closeProps?: DialogPrimitive.Close.Props;
|
|
587
832
|
portalProps?: DialogPrimitive.Portal.Props;
|
|
833
|
+
classNames?: {
|
|
834
|
+
/** Overlay rendered behind the dialog. */
|
|
835
|
+
backdrop?: string;
|
|
836
|
+
/** Full-screen container that centers the popup. */
|
|
837
|
+
viewport?: string;
|
|
838
|
+
/** Close (×) button rendered inside the popup. */
|
|
839
|
+
closeButton?: string;
|
|
840
|
+
};
|
|
588
841
|
}): JSX.Element;
|
|
589
842
|
|
|
590
843
|
export { DialogPrimitive }
|
|
@@ -604,12 +857,25 @@ export declare type DialogProps = Omit<DialogPrimitive.Root.Props, "children"> &
|
|
|
604
857
|
onClose?: () => void;
|
|
605
858
|
/** Hides the close (×) button inside the popup. */
|
|
606
859
|
hideClose?: boolean;
|
|
607
|
-
/**
|
|
608
|
-
closeProps?: DialogPrimitive.Close.Props;
|
|
609
|
-
/** Props forwarded to the portal. */
|
|
610
|
-
portalProps?: DialogPrimitive.Portal.Props;
|
|
611
|
-
/** Additional className forwarded to the popup panel. */
|
|
860
|
+
/** Styles the dialog popup panel. */
|
|
612
861
|
className?: string;
|
|
862
|
+
/** Styles applied to each internal slot. */
|
|
863
|
+
classNames?: {
|
|
864
|
+
/** Overlay rendered behind the dialog. */
|
|
865
|
+
backdrop?: string;
|
|
866
|
+
/** Full-screen container that centers the popup. */
|
|
867
|
+
viewport?: string;
|
|
868
|
+
/** Layout wrapper for title and description. */
|
|
869
|
+
header?: string;
|
|
870
|
+
/** Dialog heading. */
|
|
871
|
+
title?: string;
|
|
872
|
+
/** Supporting text below the title. */
|
|
873
|
+
description?: string;
|
|
874
|
+
/** Layout wrapper for footer content. */
|
|
875
|
+
footer?: string;
|
|
876
|
+
/** Close (×) button rendered inside the popup. */
|
|
877
|
+
closeButton?: string;
|
|
878
|
+
};
|
|
613
879
|
};
|
|
614
880
|
|
|
615
881
|
/** Context root. Holds open state and wraps all dialog parts. */
|
|
@@ -631,80 +897,113 @@ export declare function Divider({ className, orientation, ...props }: SeparatorP
|
|
|
631
897
|
|
|
632
898
|
export declare const DOTS = "...";
|
|
633
899
|
|
|
634
|
-
export declare
|
|
900
|
+
export declare function Dropzone({ onFileAdd, onFileRemove, onFilesChange, files, maxFiles, allowedExtensions, maxFileSize, multiple, renderAcceptedFile, renderRejectedFile, showRejected, className, classNames, icon: Icon, iconSize, onError, label, ...props }: DropzoneProps): JSX.Element;
|
|
901
|
+
|
|
902
|
+
export declare function DropzoneAcceptedFiles(props: DropzoneFilesProps): JSX.Element;
|
|
903
|
+
|
|
904
|
+
export declare function DropzoneContent({ className, ...props }: ComponentPropsWithoutRef<"div">): JSX.Element;
|
|
905
|
+
|
|
906
|
+
export declare type DropzoneFilesProps = {
|
|
907
|
+
renderFile?: (file: File, remove: () => void) => ReactNode;
|
|
908
|
+
};
|
|
909
|
+
|
|
910
|
+
export declare function DropzoneItem({ file, onRemove, className, renderIcon, ...props }: DropzoneItemProps): JSX.Element;
|
|
911
|
+
|
|
912
|
+
export declare type DropzoneItemProps = ComponentPropsWithoutRef<"div"> & {
|
|
913
|
+
file: File;
|
|
914
|
+
onRemove: () => void;
|
|
915
|
+
renderIcon?: (file: File) => ReactNode;
|
|
916
|
+
};
|
|
635
917
|
|
|
636
918
|
export declare type DropzoneProps = {
|
|
637
|
-
/**
|
|
638
|
-
* Función que se ejecuta cuando se agregan archivos
|
|
639
|
-
*/
|
|
640
919
|
onFileAdd?: (files: File[]) => void;
|
|
641
|
-
/**
|
|
642
|
-
* Función que se ejecuta cuando se elimina un archivo
|
|
643
|
-
*/
|
|
644
920
|
onFileRemove?: (index: number, type: "accepted" | "rejected") => void;
|
|
645
|
-
|
|
646
|
-
* Evento que captura cambios en lista de archivos
|
|
647
|
-
* @default () => {}
|
|
648
|
-
*/
|
|
649
|
-
onChangeFiles?: (files: File[]) => void;
|
|
650
|
-
/**
|
|
651
|
-
* Lista de archivos
|
|
652
|
-
* @default []
|
|
653
|
-
*/
|
|
921
|
+
onFilesChange?: (files: File[]) => void;
|
|
654
922
|
files?: File[];
|
|
655
|
-
/**
|
|
656
|
-
* Número máximo de archivos permitidos
|
|
657
|
-
* @default 1
|
|
658
|
-
*/
|
|
659
923
|
maxFiles?: number;
|
|
660
|
-
/**
|
|
661
|
-
* Lista de extensiones permitidas (e.j. ["image/jpeg", "image/png"])
|
|
662
|
-
* @default []
|
|
663
|
-
*/
|
|
664
924
|
allowedExtensions?: FileTypeValue[];
|
|
665
|
-
/**
|
|
666
|
-
* Tamaño máximo de archivo en bytes
|
|
667
|
-
* @default 5MB
|
|
668
|
-
*/
|
|
669
925
|
maxFileSize?: number;
|
|
670
|
-
/**
|
|
671
|
-
* Permite seleccionar múltiples archivos
|
|
672
|
-
*/
|
|
673
926
|
multiple?: boolean;
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
*/
|
|
677
|
-
renderAcceptedFile?: (file: File, removeItem: () => void) => React.ReactNode;
|
|
678
|
-
/**
|
|
679
|
-
* Función para renderizar cada archivo rechazado
|
|
680
|
-
*/
|
|
681
|
-
renderRejectedFile?: (file: File, removeItem: () => void) => React.ReactNode;
|
|
682
|
-
/**
|
|
683
|
-
* Mostrar archivos rechazados
|
|
684
|
-
* @default false
|
|
685
|
-
*/
|
|
927
|
+
renderAcceptedFile?: (file: File, removeItem: () => void) => ReactNode;
|
|
928
|
+
renderRejectedFile?: (file: File, removeItem: () => void) => ReactNode;
|
|
686
929
|
showRejected?: boolean;
|
|
687
|
-
/**
|
|
688
|
-
* Clase CSS para el contenedor
|
|
689
|
-
*/
|
|
690
930
|
className?: string;
|
|
691
|
-
/**
|
|
692
|
-
* Icono personalizado para el dropzone
|
|
693
|
-
* @default UploadCloud
|
|
694
|
-
*/
|
|
695
931
|
icon?: LucideIcon;
|
|
696
|
-
/**
|
|
697
|
-
* Tamaño del icono
|
|
698
|
-
* @default 40
|
|
699
|
-
*/
|
|
700
932
|
iconSize?: number;
|
|
701
|
-
/**
|
|
702
|
-
* Función que se ejecuta cuando se rechazan archivos
|
|
703
|
-
*/
|
|
704
933
|
onError?: (fileErrors: FileError[]) => void;
|
|
934
|
+
label?: string;
|
|
935
|
+
/** Styles applied to each internal slot. */
|
|
936
|
+
classNames?: {
|
|
937
|
+
/** Dashed drop area that contains the icon and label. */
|
|
938
|
+
trigger?: string;
|
|
939
|
+
/** Upload icon rendered inside the trigger. */
|
|
940
|
+
icon?: string;
|
|
941
|
+
/** Text container below the icon (label + meta lines). */
|
|
942
|
+
label?: string;
|
|
943
|
+
/** Wrapper around the accepted/rejected file lists. */
|
|
944
|
+
content?: string;
|
|
945
|
+
};
|
|
946
|
+
} & Omit<ComponentPropsWithoutRef<"div">, "onDrop" | "onError">;
|
|
947
|
+
|
|
948
|
+
export declare function DropzoneRejectedFiles(props: DropzoneFilesProps): JSX.Element;
|
|
949
|
+
|
|
950
|
+
export declare function DropzoneRoot({ onFileAdd, onFileRemove, onFilesChange, files: controlledFiles, maxFiles, allowedExtensions, maxFileSize, multiple, onError, children, className, ...props }: DropzoneRootProps): JSX.Element;
|
|
951
|
+
|
|
952
|
+
export declare type DropzoneRootProps = {
|
|
953
|
+
onFileAdd?: (files: File[]) => void;
|
|
954
|
+
onFileRemove?: (index: number, type: "accepted" | "rejected") => void;
|
|
955
|
+
onFilesChange?: (files: File[]) => void;
|
|
956
|
+
files?: File[];
|
|
957
|
+
maxFiles?: number;
|
|
958
|
+
allowedExtensions?: FileTypeValue[];
|
|
959
|
+
maxFileSize?: number;
|
|
960
|
+
multiple?: boolean;
|
|
961
|
+
onError?: (errors: FileError[]) => void;
|
|
962
|
+
children?: ReactNode;
|
|
705
963
|
} & Omit<ComponentPropsWithoutRef<"div">, "onDrop" | "onError">;
|
|
706
964
|
|
|
707
|
-
export declare
|
|
965
|
+
export declare function DropzoneTrigger({ render, className, onClick, children, ...props }: DropzoneTriggerProps): JSX.Element;
|
|
966
|
+
|
|
967
|
+
export declare type DropzoneTriggerProps = useRender.ComponentProps<"div">;
|
|
968
|
+
|
|
969
|
+
export declare function Empty({ icon, iconVariant, title, description, action, children, classNames, ...props }: EmptyProps): JSX.Element;
|
|
970
|
+
|
|
971
|
+
export declare function EmptyContent({ className, ...props }: ComponentProps<"div">): JSX.Element;
|
|
972
|
+
|
|
973
|
+
export declare function EmptyDescription({ className, ...props }: ComponentProps<"div">): JSX.Element;
|
|
974
|
+
|
|
975
|
+
export declare function EmptyHeader({ className, ...props }: ComponentProps<"div">): JSX.Element;
|
|
976
|
+
|
|
977
|
+
export declare function EmptyMedia({ className, variant, ...props }: ComponentProps<"div"> & VariantProps<typeof emptyMediaVariants>): JSX.Element;
|
|
978
|
+
|
|
979
|
+
declare const emptyMediaVariants: (props?: ({
|
|
980
|
+
variant?: "default" | "icon" | null | undefined;
|
|
981
|
+
} & ClassProp) | undefined) => string;
|
|
982
|
+
|
|
983
|
+
declare interface EmptyProps extends Omit<ComponentProps<typeof EmptyRoot>, "title"> {
|
|
984
|
+
icon?: ReactNode;
|
|
985
|
+
iconVariant?: VariantProps<typeof emptyMediaVariants>["variant"];
|
|
986
|
+
title?: ReactNode;
|
|
987
|
+
description?: ReactNode;
|
|
988
|
+
action?: ReactNode;
|
|
989
|
+
/** Styles applied to each internal slot. */
|
|
990
|
+
classNames?: {
|
|
991
|
+
/** Wrapper around media, title and description. */
|
|
992
|
+
header?: string;
|
|
993
|
+
/** Box that frames the icon (chip when `iconVariant="icon"`). */
|
|
994
|
+
media?: string;
|
|
995
|
+
/** Title text. */
|
|
996
|
+
title?: string;
|
|
997
|
+
/** Description text below the title. */
|
|
998
|
+
description?: string;
|
|
999
|
+
/** Wrapper around the `action` slot. */
|
|
1000
|
+
content?: string;
|
|
1001
|
+
};
|
|
1002
|
+
}
|
|
1003
|
+
|
|
1004
|
+
export declare function EmptyRoot({ className, ...props }: ComponentProps<"div">): JSX.Element;
|
|
1005
|
+
|
|
1006
|
+
export declare function EmptyTitle({ className, ...props }: ComponentProps<"div">): JSX.Element;
|
|
708
1007
|
|
|
709
1008
|
export declare const ensureReactElement: <P>({ children, as: Wrapper, props, }: EnsureReactElementProps<P>) => ReactElement;
|
|
710
1009
|
|
|
@@ -718,32 +1017,6 @@ export declare type Entity<T> = {
|
|
|
718
1017
|
[K in keyof T]: T[K];
|
|
719
1018
|
} & BaseEntity;
|
|
720
1019
|
|
|
721
|
-
declare interface ExtendedProps {
|
|
722
|
-
containerClassName: ClassName;
|
|
723
|
-
inputClassName: ClassName;
|
|
724
|
-
listClassName: ClassName;
|
|
725
|
-
itemClassName: ClassName;
|
|
726
|
-
emptyClassName: ClassName;
|
|
727
|
-
containerProps: ComponentProps<typeof AutoCompleteRoot>;
|
|
728
|
-
inputProps: ComponentProps<typeof AutoCompleteInput>;
|
|
729
|
-
listProps: ComponentProps<typeof AutoCompleteList>;
|
|
730
|
-
itemProps: ComponentProps<typeof AutoCompleteItem>;
|
|
731
|
-
emptyProps: ComponentProps<typeof AutoCompleteEmpty>;
|
|
732
|
-
}
|
|
733
|
-
|
|
734
|
-
declare interface ExtendedProps_2 {
|
|
735
|
-
theadClassName?: ClassName;
|
|
736
|
-
theadProps?: HTMLProps<HTMLTableSectionElement>;
|
|
737
|
-
tbodyClassName?: ClassName;
|
|
738
|
-
tbodyProps?: HTMLProps<HTMLTableSectionElement>;
|
|
739
|
-
trClassName?: ClassName;
|
|
740
|
-
trProps?: HTMLProps<HTMLTableRowElement>;
|
|
741
|
-
thClassName?: ClassName;
|
|
742
|
-
thProps?: HTMLProps<HTMLTableCellElement>;
|
|
743
|
-
tdClassName?: ClassName;
|
|
744
|
-
tdProps?: Omit<HTMLProps<HTMLTableCellElement>, "onDoubleClick">;
|
|
745
|
-
}
|
|
746
|
-
|
|
747
1020
|
/**
|
|
748
1021
|
* Extracts the initials from a string.
|
|
749
1022
|
* @param {string} string - The input string.
|
|
@@ -751,7 +1024,7 @@ declare interface ExtendedProps_2 {
|
|
|
751
1024
|
*/
|
|
752
1025
|
export declare const extractInitials: (string: string) => string;
|
|
753
1026
|
|
|
754
|
-
export declare function Field({ label, description, error, required, tooltip, inline, children, className,
|
|
1027
|
+
export declare function Field({ label, description, error, required, tooltip, inline, children, className, classNames, invalid, ...rootProps }: FieldProps): JSX.Element;
|
|
755
1028
|
|
|
756
1029
|
export declare const FieldControl: typeof FieldPrimitive.Control;
|
|
757
1030
|
|
|
@@ -772,6 +1045,8 @@ export declare function FieldItem({ className, ...props }: FieldPrimitive.Item.P
|
|
|
772
1045
|
|
|
773
1046
|
export declare function FieldLabel({ className, ...props }: FieldPrimitive.Label.Props): JSX.Element;
|
|
774
1047
|
|
|
1048
|
+
export declare function FieldLegend({ className, ...props }: FieldsetPrimitive.Legend.Props): JSX.Element;
|
|
1049
|
+
|
|
775
1050
|
export { FieldPrimitive }
|
|
776
1051
|
|
|
777
1052
|
export declare interface FieldProps extends Omit<FieldPrimitive.Root.Props, "children"> {
|
|
@@ -796,27 +1071,34 @@ export declare interface FieldProps extends Omit<FieldPrimitive.Root.Props, "chi
|
|
|
796
1071
|
*/
|
|
797
1072
|
inline?: boolean;
|
|
798
1073
|
children?: ReactNode;
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
1074
|
+
/** Styles applied to each internal slot. */
|
|
1075
|
+
classNames?: {
|
|
1076
|
+
/** Label rendered above (or beside, when `inline`) the control. */
|
|
1077
|
+
label?: string;
|
|
1078
|
+
/** Helper text below the control. */
|
|
1079
|
+
description?: string;
|
|
1080
|
+
/** Error message rendered when the field is invalid. */
|
|
1081
|
+
error?: string;
|
|
1082
|
+
};
|
|
805
1083
|
}
|
|
806
1084
|
|
|
807
|
-
export declare function FieldRoot({ className, required, ...props }: FieldPrimitive.Root.Props & {
|
|
1085
|
+
export declare function FieldRoot({ className, required, name, ...props }: FieldPrimitive.Root.Props & {
|
|
808
1086
|
required?: boolean;
|
|
809
1087
|
}): JSX.Element;
|
|
810
1088
|
|
|
1089
|
+
export declare function FieldSet({ className, ...props }: FieldsetPrimitive.Root.Props): JSX.Element;
|
|
1090
|
+
|
|
1091
|
+
export { FieldsetPrimitive }
|
|
1092
|
+
|
|
811
1093
|
export declare const FieldValidity: typeof FieldPrimitive.Validity;
|
|
812
1094
|
|
|
813
|
-
declare type FileError = {
|
|
1095
|
+
export declare type FileError = {
|
|
814
1096
|
file: File;
|
|
815
1097
|
errorMessage: string;
|
|
816
1098
|
errorCode: FileErrorCode;
|
|
817
1099
|
};
|
|
818
1100
|
|
|
819
|
-
declare type FileErrorCode = "INVALID_EXTENSION" | "FILE_TOO_LARGE" | "MAX_FILES_EXCEEDED";
|
|
1101
|
+
export declare type FileErrorCode = "INVALID_EXTENSION" | "FILE_TOO_LARGE" | "MAX_FILES_EXCEEDED";
|
|
820
1102
|
|
|
821
1103
|
export declare const FileType: {
|
|
822
1104
|
readonly JPEG: "image/jpeg";
|
|
@@ -848,22 +1130,11 @@ export declare const FileTypeGroups: Record<string, FileTypeValue[]>;
|
|
|
848
1130
|
|
|
849
1131
|
export declare type FileTypeValue = (typeof FileType)[keyof typeof FileType];
|
|
850
1132
|
|
|
851
|
-
export declare function Form(
|
|
1133
|
+
export declare function Form(props: FormProps): default_2.ReactElement;
|
|
852
1134
|
|
|
853
1135
|
export { FormPrimitive }
|
|
854
1136
|
|
|
855
|
-
export declare
|
|
856
|
-
onSubmit?: BaseProps["onFormSubmit"];
|
|
857
|
-
onFormSubmit?: BaseProps["onFormSubmit"];
|
|
858
|
-
}
|
|
859
|
-
|
|
860
|
-
export declare interface GenericMenuProps {
|
|
861
|
-
trigger: default_2.ReactNode;
|
|
862
|
-
items: MenuItemType[];
|
|
863
|
-
side?: "top" | "right" | "bottom" | "left";
|
|
864
|
-
offset?: ComponentPropsWithoutRef<typeof MenuContent>["sideOffset"];
|
|
865
|
-
contentProps?: ComponentPropsWithoutRef<typeof MenuContent>;
|
|
866
|
-
}
|
|
1137
|
+
export declare type FormProps = FormPrimitive.Props;
|
|
867
1138
|
|
|
868
1139
|
export declare type GenericObject<T = any> = {
|
|
869
1140
|
[key: string]: T;
|
|
@@ -873,12 +1144,30 @@ declare type GenericObject_2 = Record<string, any>;
|
|
|
873
1144
|
|
|
874
1145
|
export declare const getFormData: (event: FormEvent<HTMLFormElement>) => Record<string, string>;
|
|
875
1146
|
|
|
876
|
-
export declare
|
|
1147
|
+
export declare type GetPageHref = (state: {
|
|
1148
|
+
page: number;
|
|
1149
|
+
pageSize: number;
|
|
1150
|
+
}) => string;
|
|
1151
|
+
|
|
1152
|
+
export declare function HookField<T extends FieldValues = FieldValues, TName extends FieldPath<T> = FieldPath<T>>({ name, rules, render, ...fieldProps }: HookFieldProps<T, TName>): JSX.Element;
|
|
877
1153
|
|
|
878
|
-
declare
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
1154
|
+
declare type HookFieldProps<T extends FieldValues = FieldValues, TName extends FieldPath<T> = FieldPath<T>> = Omit<FieldProps, "children" | "error" | "render" | "name"> & {
|
|
1155
|
+
name: TName;
|
|
1156
|
+
rules?: RegisterOptions<T, TName>;
|
|
1157
|
+
render: (field: HookFieldRenderProps<T, TName>) => ReactNode;
|
|
1158
|
+
};
|
|
1159
|
+
|
|
1160
|
+
export declare type HookFieldRenderProps<T extends FieldValues = FieldValues, TName extends FieldPath<T> = FieldPath<T>> = ControllerRenderProps<T, TName> & {
|
|
1161
|
+
invalid: boolean;
|
|
1162
|
+
};
|
|
1163
|
+
|
|
1164
|
+
export declare function HookForm<T extends FieldValues>({ form, onFormSubmit, children, ...props }: HookFormProps<T>): JSX.Element;
|
|
1165
|
+
|
|
1166
|
+
declare type HookFormProps<T extends FieldValues> = Omit<ComponentProps<typeof Form>, "onSubmit" | "onFormSubmit" | "children"> & {
|
|
1167
|
+
form: UseFormReturn<T>;
|
|
1168
|
+
onFormSubmit: SubmitHandler<T>;
|
|
1169
|
+
children: ReactNode;
|
|
1170
|
+
};
|
|
882
1171
|
|
|
883
1172
|
declare type HotkeyEventName = "keydown" | "keypress" | "keyup";
|
|
884
1173
|
|
|
@@ -891,35 +1180,33 @@ declare type HotkeyOptions = {
|
|
|
891
1180
|
|
|
892
1181
|
export declare type ID = string | number;
|
|
893
1182
|
|
|
894
|
-
export declare function Input({ className, nativeInput,
|
|
1183
|
+
export declare function Input({ className, nativeInput, onValueChange, ...props }: InputProps): JSX.Element;
|
|
895
1184
|
|
|
896
1185
|
export declare const inputBaseClasses = "h-10 w-full px-3 py-2 rounded-md border border-input bg-background text-sm outline-none transition-shadow placeholder:text-muted-foreground";
|
|
897
1186
|
|
|
898
1187
|
export { InputPrimitive }
|
|
899
1188
|
|
|
900
1189
|
export declare type InputProps = Omit<InputPrimitive.Props, "size" | "onChange"> & {
|
|
901
|
-
|
|
1190
|
+
onValueChange?: (value: string, event: ChangeEvent<HTMLInputElement>) => void;
|
|
902
1191
|
nativeInput?: boolean;
|
|
903
1192
|
};
|
|
904
1193
|
|
|
905
|
-
declare interface ItemTimeline {
|
|
906
|
-
content?: ReactNode;
|
|
907
|
-
icon?: ReactNode;
|
|
908
|
-
status?: "done" | "pending" | "error";
|
|
909
|
-
color?: string;
|
|
910
|
-
}
|
|
911
|
-
|
|
912
1194
|
export declare function Kbd({ className, ...props }: React_2.ComponentProps<"kbd">): React_2.ReactElement;
|
|
913
1195
|
|
|
914
1196
|
export declare function KbdGroup({ className, ...props }: React_2.ComponentProps<"kbd">): React_2.ReactElement;
|
|
915
1197
|
|
|
916
|
-
declare
|
|
917
|
-
|
|
918
|
-
export declare function Label({ className, render, required, tooltip, children, ...props }: LabelProps): default_2.ReactElement;
|
|
1198
|
+
export declare function Label({ className, render, required, tooltip, classNames, children, ...props }: LabelProps): default_2.ReactElement;
|
|
919
1199
|
|
|
920
1200
|
declare interface LabelProps extends useRender.ComponentProps<"label"> {
|
|
921
1201
|
required?: boolean;
|
|
922
1202
|
tooltip?: ReactNode;
|
|
1203
|
+
/** Styles applied to each internal slot. */
|
|
1204
|
+
classNames?: {
|
|
1205
|
+
/** Red asterisk rendered when `required` is true. */
|
|
1206
|
+
asterisk?: string;
|
|
1207
|
+
/** Info-icon button rendered when `tooltip` is set. */
|
|
1208
|
+
tooltip?: string;
|
|
1209
|
+
};
|
|
923
1210
|
}
|
|
924
1211
|
|
|
925
1212
|
/**
|
|
@@ -949,13 +1236,22 @@ export declare type LibraryProviderProps = {
|
|
|
949
1236
|
tooltipDelay?: ComponentPropsWithoutRef<typeof TooltipPrimitive.Provider>["delay"];
|
|
950
1237
|
} & Omit<ToastProviderProps, "children">;
|
|
951
1238
|
|
|
952
|
-
export declare
|
|
1239
|
+
export declare type LinkComponent = ElementType<LinkRenderProps> | ComponentType<LinkRenderProps>;
|
|
1240
|
+
|
|
1241
|
+
export declare type LinkRenderProps = {
|
|
1242
|
+
href: string;
|
|
1243
|
+
children?: ReactNode;
|
|
1244
|
+
className?: string;
|
|
1245
|
+
onClick?: (event: React.MouseEvent) => void;
|
|
1246
|
+
};
|
|
1247
|
+
|
|
1248
|
+
export declare const Loader: ({ center, classNames, variant, size, ...props }: Props_3) => JSX.Element;
|
|
953
1249
|
|
|
954
1250
|
declare type LoaderVariants = VariantProps<typeof loaderVariants>;
|
|
955
1251
|
|
|
956
1252
|
declare const loaderVariants: (props?: ({
|
|
957
|
-
variant?: "
|
|
958
|
-
size?: "default" | "
|
|
1253
|
+
variant?: "secondary" | "ghost" | "error" | "success" | "warning" | "primary" | "info" | null | undefined;
|
|
1254
|
+
size?: "default" | "xs" | "sm" | "lg" | "xl" | null | undefined;
|
|
959
1255
|
} & ClassProp) | undefined) => string;
|
|
960
1256
|
|
|
961
1257
|
export declare type Loose<T> = T | (string & {});
|
|
@@ -966,99 +1262,111 @@ export declare type MaybeRef<T> = T | MutableRefObject<T>;
|
|
|
966
1262
|
|
|
967
1263
|
declare type MaybeReturn<TState> = Return<TState | undefined, ((state: TState | undefined) => Partial<TState>) | Partial<TState>>;
|
|
968
1264
|
|
|
969
|
-
export declare const Menu: ({ trigger, items,
|
|
970
|
-
|
|
971
|
-
export declare const MenuCheckboxItem: ({ className, children, checked, ...props }: MenuCheckboxItemProps) => JSX.Element;
|
|
972
|
-
|
|
973
|
-
declare type MenuCheckboxItemProps = React_2.ComponentProps<typeof DropdownMenuPrimitive.CheckboxItem>;
|
|
1265
|
+
export declare const Menu: ({ trigger, items, className, side, align, offset, alignOffset, classNames, }: MenuProps) => JSX.Element;
|
|
974
1266
|
|
|
975
|
-
export declare
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
export declare const MenuGroup: (props: React_2.ComponentProps<typeof DropdownMenuPrimitive.Group>) => JSX.Element;
|
|
1267
|
+
export declare function MenuCheckboxItem({ className, children, checked, inset, ...props }: Menu_2.CheckboxItem.Props & {
|
|
1268
|
+
inset?: boolean;
|
|
1269
|
+
}): JSX.Element;
|
|
980
1270
|
|
|
981
|
-
export declare
|
|
1271
|
+
export declare function MenuGroup({ ...props }: Menu_2.Group.Props): JSX.Element;
|
|
982
1272
|
|
|
983
|
-
declare
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
}
|
|
1273
|
+
export declare function MenuItem({ className, inset, variant, ...props }: Menu_2.Item.Props & {
|
|
1274
|
+
inset?: boolean;
|
|
1275
|
+
variant?: "default" | "error";
|
|
1276
|
+
}): JSX.Element;
|
|
987
1277
|
|
|
988
|
-
declare type MenuItemCheckbox =
|
|
1278
|
+
declare type MenuItemCheckbox = {
|
|
989
1279
|
type: "checkbox";
|
|
1280
|
+
label: React_2.ReactNode;
|
|
1281
|
+
shortcut?: string;
|
|
1282
|
+
} & Omit<React_2.ComponentProps<typeof MenuCheckboxItem>, "children">;
|
|
1283
|
+
|
|
1284
|
+
declare type MenuItemGroup = {
|
|
1285
|
+
type: "group";
|
|
1286
|
+
label?: React_2.ReactNode;
|
|
1287
|
+
items: MenuItemType[];
|
|
990
1288
|
};
|
|
991
1289
|
|
|
992
|
-
declare type MenuItemItem =
|
|
1290
|
+
declare type MenuItemItem = {
|
|
993
1291
|
type: "item";
|
|
994
|
-
|
|
1292
|
+
label: React_2.ReactNode;
|
|
1293
|
+
shortcut?: string;
|
|
1294
|
+
} & Omit<React_2.ComponentProps<typeof MenuItem>, "children">;
|
|
995
1295
|
|
|
996
|
-
declare type MenuItemLabel =
|
|
1296
|
+
declare type MenuItemLabel = {
|
|
997
1297
|
type: "label";
|
|
998
|
-
|
|
1298
|
+
label: React_2.ReactNode;
|
|
1299
|
+
} & Omit<React_2.ComponentProps<typeof MenuLabel>, "children">;
|
|
999
1300
|
|
|
1000
|
-
declare type
|
|
1001
|
-
inset?: boolean;
|
|
1002
|
-
};
|
|
1003
|
-
|
|
1004
|
-
declare type MenuItemRadio = MenuItemBase<typeof MenuRadioItem> & {
|
|
1301
|
+
declare type MenuItemRadio = {
|
|
1005
1302
|
type: "radio";
|
|
1303
|
+
label: React_2.ReactNode;
|
|
1304
|
+
shortcut?: string;
|
|
1305
|
+
} & Omit<React_2.ComponentProps<typeof MenuRadioItem>, "children">;
|
|
1306
|
+
|
|
1307
|
+
declare type MenuItemRadioGroup = {
|
|
1308
|
+
type: "radio-group";
|
|
1309
|
+
value?: string;
|
|
1310
|
+
onValueChange?: (value: string) => void;
|
|
1311
|
+
items: MenuItemRadio[];
|
|
1006
1312
|
};
|
|
1007
1313
|
|
|
1008
|
-
declare type MenuItemSeparator =
|
|
1314
|
+
declare type MenuItemSeparator = {
|
|
1009
1315
|
type: "separator";
|
|
1010
|
-
}
|
|
1316
|
+
} & React_2.ComponentProps<typeof MenuSeparator>;
|
|
1011
1317
|
|
|
1012
|
-
declare type MenuItemSubmenu =
|
|
1318
|
+
declare type MenuItemSubmenu = {
|
|
1013
1319
|
type: "submenu";
|
|
1320
|
+
label: React_2.ReactNode;
|
|
1014
1321
|
items: MenuItemType[];
|
|
1015
|
-
}
|
|
1016
|
-
|
|
1017
|
-
export declare type MenuItemType = MenuItemItem | MenuItemCheckbox | MenuItemRadio | MenuItemLabel | MenuItemSeparator | MenuItemSubmenu;
|
|
1322
|
+
} & Omit<React_2.ComponentProps<typeof MenuSubTrigger>, "children">;
|
|
1018
1323
|
|
|
1019
|
-
export declare
|
|
1324
|
+
export declare type MenuItemType = MenuItemItem | MenuItemCheckbox | MenuItemRadio | MenuItemRadioGroup | MenuItemLabel | MenuItemSeparator | MenuItemGroup | MenuItemSubmenu;
|
|
1020
1325
|
|
|
1021
|
-
declare
|
|
1326
|
+
export declare function MenuLabel({ className, inset, ...props }: Menu_2.GroupLabel.Props & {
|
|
1022
1327
|
inset?: boolean;
|
|
1023
|
-
};
|
|
1024
|
-
|
|
1025
|
-
export declare const MenuPortal: (props: React_2.ComponentProps<typeof DropdownMenuPrimitive.Portal>) => JSX.Element;
|
|
1026
|
-
|
|
1027
|
-
export declare const MenuRadioGroup: (props: React_2.ComponentProps<typeof DropdownMenuPrimitive.RadioGroup>) => JSX.Element;
|
|
1028
|
-
|
|
1029
|
-
export declare const MenuRadioItem: ({ className, children, ...props }: MenuRadioItemProps) => JSX.Element;
|
|
1328
|
+
}): JSX.Element;
|
|
1030
1329
|
|
|
1031
|
-
declare
|
|
1330
|
+
export declare function MenuPopup({ align, alignOffset, side, sideOffset, className, ...props }: Menu_2.Popup.Props & Pick<Menu_2.Positioner.Props, "align" | "alignOffset" | "side" | "sideOffset">): JSX.Element;
|
|
1032
1331
|
|
|
1033
|
-
export declare
|
|
1332
|
+
export declare function MenuPortal({ ...props }: Menu_2.Portal.Props): JSX.Element;
|
|
1034
1333
|
|
|
1035
|
-
export declare
|
|
1334
|
+
export declare interface MenuProps {
|
|
1335
|
+
trigger: React_2.ReactElement;
|
|
1336
|
+
items: MenuItemType[];
|
|
1337
|
+
className?: string;
|
|
1338
|
+
side?: React_2.ComponentProps<typeof MenuPopup>["side"];
|
|
1339
|
+
align?: React_2.ComponentProps<typeof MenuPopup>["align"];
|
|
1340
|
+
offset?: React_2.ComponentProps<typeof MenuPopup>["sideOffset"];
|
|
1341
|
+
alignOffset?: React_2.ComponentProps<typeof MenuPopup>["alignOffset"];
|
|
1342
|
+
/** Styles applied to each internal slot. */
|
|
1343
|
+
classNames?: {
|
|
1344
|
+
/** Popup panel that opens below the trigger. */
|
|
1345
|
+
popup?: string;
|
|
1346
|
+
};
|
|
1347
|
+
}
|
|
1036
1348
|
|
|
1037
|
-
declare
|
|
1349
|
+
export declare function MenuRadioGroup({ ...props }: Menu_2.RadioGroup.Props): JSX.Element;
|
|
1038
1350
|
|
|
1039
|
-
export declare
|
|
1351
|
+
export declare function MenuRadioItem({ className, children, inset, ...props }: Menu_2.RadioItem.Props & {
|
|
1352
|
+
inset?: boolean;
|
|
1353
|
+
}): JSX.Element;
|
|
1040
1354
|
|
|
1041
|
-
declare
|
|
1355
|
+
export declare function MenuRoot({ ...props }: Menu_2.Root.Props): JSX.Element;
|
|
1042
1356
|
|
|
1043
|
-
declare
|
|
1044
|
-
keys: Keys;
|
|
1045
|
-
handler: (event: KeyboardEvent) => any;
|
|
1046
|
-
options?: HotkeyOptions;
|
|
1047
|
-
};
|
|
1357
|
+
export declare function MenuSeparator({ className, ...props }: Menu_2.Separator.Props): JSX.Element;
|
|
1048
1358
|
|
|
1049
|
-
export declare
|
|
1359
|
+
export declare function MenuShortcut({ className, ...props }: React_2.ComponentProps<"span">): JSX.Element;
|
|
1050
1360
|
|
|
1051
|
-
export declare
|
|
1361
|
+
export declare function MenuSub({ ...props }: Menu_2.SubmenuRoot.Props): JSX.Element;
|
|
1052
1362
|
|
|
1053
|
-
declare
|
|
1363
|
+
export declare function MenuSubContent({ align, alignOffset, side, sideOffset, className, ...props }: React_2.ComponentProps<typeof MenuPopup>): JSX.Element;
|
|
1054
1364
|
|
|
1055
|
-
export declare
|
|
1056
|
-
|
|
1057
|
-
declare type MenuSubTriggerProps = React_2.ComponentProps<typeof DropdownMenuPrimitive.SubTrigger> & {
|
|
1365
|
+
export declare function MenuSubTrigger({ className, inset, children, ...props }: Menu_2.SubmenuTrigger.Props & {
|
|
1058
1366
|
inset?: boolean;
|
|
1059
|
-
};
|
|
1367
|
+
}): JSX.Element;
|
|
1060
1368
|
|
|
1061
|
-
export declare
|
|
1369
|
+
export declare function MenuTrigger({ ...props }: Menu_2.Trigger.Props): JSX.Element;
|
|
1062
1370
|
|
|
1063
1371
|
export declare function mergeRefs<T = any>(refs: Array<React_2.MutableRefObject<T> | React_2.LegacyRef<T> | undefined | null>): React_2.RefCallback<T>;
|
|
1064
1372
|
|
|
@@ -1066,7 +1374,7 @@ export declare type MultipleDatePickerProps = DatePickerBaseProps & {
|
|
|
1066
1374
|
mode: "multiple";
|
|
1067
1375
|
value?: Date[];
|
|
1068
1376
|
defaultValue?: Date[];
|
|
1069
|
-
|
|
1377
|
+
onValueChange?: (value: Date[]) => void;
|
|
1070
1378
|
placeholder?: string;
|
|
1071
1379
|
};
|
|
1072
1380
|
|
|
@@ -1077,64 +1385,15 @@ declare type MultipleFooterProps = {
|
|
|
1077
1385
|
setValue: (value: Date[]) => void;
|
|
1078
1386
|
};
|
|
1079
1387
|
|
|
1080
|
-
export declare const MultiSelect: <TItem extends Record<string, any> = Option_2>({ items, value, valueKey, labelKey, onChange, variant, defaultValue, placeholder, maxCount, className, renderOption, withCheckbox, showSearch, showSelectAll, rootProps, ...props }: MultiSelectProps<TItem>) => JSX.Element;
|
|
1081
|
-
|
|
1082
|
-
declare type MultiSelectProps<TItem extends Record<string, any>> = OverrideProps<React_2.ButtonHTMLAttributes<HTMLButtonElement> & OpenProps & VariantProps<typeof multiSelectVariants>, {
|
|
1083
|
-
items: TItem[];
|
|
1084
|
-
/**
|
|
1085
|
-
* Identificador del valor del elemento
|
|
1086
|
-
* @default "value"
|
|
1087
|
-
*/
|
|
1088
|
-
valueKey?: keyof TItem;
|
|
1089
|
-
/**
|
|
1090
|
-
* Identificador del label del elemento
|
|
1091
|
-
* @default "label"
|
|
1092
|
-
*/
|
|
1093
|
-
value?: string[];
|
|
1094
|
-
onChange?: (value: string[]) => void;
|
|
1095
|
-
defaultValue?: string[];
|
|
1096
|
-
labelKey?: keyof TItem;
|
|
1097
|
-
placeholder?: string;
|
|
1098
|
-
/**
|
|
1099
|
-
* Cantidad máxima de elementos que se van a visualizar
|
|
1100
|
-
* @default 3
|
|
1101
|
-
*/
|
|
1102
|
-
maxCount?: number;
|
|
1103
|
-
className?: string;
|
|
1104
|
-
renderOption?: (item: TItem) => React_2.ReactNode;
|
|
1105
|
-
withCheckbox?: boolean;
|
|
1106
|
-
/**
|
|
1107
|
-
* Para mostrar o no la barra de búsqueda
|
|
1108
|
-
* @default true
|
|
1109
|
-
*/
|
|
1110
|
-
showSearch?: boolean;
|
|
1111
|
-
/**
|
|
1112
|
-
* Para mostrar o no el "Seleccionar todos"
|
|
1113
|
-
* @default true
|
|
1114
|
-
*/
|
|
1115
|
-
showSelectAll?: boolean;
|
|
1116
|
-
/**
|
|
1117
|
-
* Props del PopoverRoot
|
|
1118
|
-
*/
|
|
1119
|
-
rootProps?: React_2.ComponentPropsWithoutRef<typeof PopoverRoot>;
|
|
1120
|
-
}>;
|
|
1121
|
-
|
|
1122
|
-
declare const multiSelectVariants: (props?: ({
|
|
1123
|
-
variant?: "default" | "error" | "secondary" | "primary" | null | undefined;
|
|
1124
|
-
} & ClassProp) | undefined) => string;
|
|
1125
|
-
|
|
1126
1388
|
declare type Mutation<TArgs extends any[], TReturn> = (...args: TArgs) => Promise<TReturn>;
|
|
1127
1389
|
|
|
1128
|
-
declare type NonClosableProps = BaseProps_2 & {
|
|
1129
|
-
closable?: false;
|
|
1130
|
-
onClose?: never;
|
|
1131
|
-
};
|
|
1132
|
-
|
|
1133
1390
|
declare type noop = (this: any, ...args: any[]) => any;
|
|
1134
1391
|
|
|
1392
|
+
export declare function normalizeError(error: FieldErrorProp | undefined): FieldErrorItem[];
|
|
1393
|
+
|
|
1135
1394
|
export declare type Nullable<T> = T | null;
|
|
1136
1395
|
|
|
1137
|
-
export declare function NumberInput({ className, hideControls,
|
|
1396
|
+
export declare function NumberInput({ className, hideControls, onValueChange, invalid, placeholder, classNames, ...props }: NumberInputProps): JSX.Element;
|
|
1138
1397
|
|
|
1139
1398
|
export declare function NumberInputCursorIcon(props: ComponentProps<"svg">): JSX.Element;
|
|
1140
1399
|
|
|
@@ -1151,16 +1410,21 @@ export { NumberInputPrimitive }
|
|
|
1151
1410
|
export declare interface NumberInputProps extends NumberInputPrimitive.Root.Props {
|
|
1152
1411
|
/** Hides the increment/decrement buttons. */
|
|
1153
1412
|
hideControls?: boolean;
|
|
1154
|
-
/** Shorthand for `onValueChange` — receives only the value, without event details. */
|
|
1155
|
-
onChange?: (value: number | null) => void;
|
|
1156
1413
|
/** Marks the field as invalid, adding the error border to the group. */
|
|
1157
1414
|
invalid?: boolean;
|
|
1158
1415
|
/** Forwarded to the underlying input element. */
|
|
1159
1416
|
placeholder?: string;
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1417
|
+
/** Styles applied to each internal slot. */
|
|
1418
|
+
classNames?: {
|
|
1419
|
+
/** Native `<input>` element. */
|
|
1420
|
+
input?: string;
|
|
1421
|
+
/** Column wrapper around the increment/decrement buttons. */
|
|
1422
|
+
controls?: string;
|
|
1423
|
+
/** Increment button (Chevron up). */
|
|
1424
|
+
increment?: string;
|
|
1425
|
+
/** Decrement button (Chevron down). */
|
|
1426
|
+
decrement?: string;
|
|
1427
|
+
};
|
|
1164
1428
|
}
|
|
1165
1429
|
|
|
1166
1430
|
export declare function NumberInputRoot({ className, ...props }: NumberInputPrimitive.Root.Props): JSX.Element;
|
|
@@ -1169,12 +1433,6 @@ export declare function NumberInputScrubArea({ className, ...props }: NumberInpu
|
|
|
1169
1433
|
|
|
1170
1434
|
export declare function NumberInputScrubAreaCursor({ className, ...props }: NumberInputPrimitive.ScrubAreaCursor.Props): JSX.Element;
|
|
1171
1435
|
|
|
1172
|
-
declare type OpenProps = {
|
|
1173
|
-
open?: boolean;
|
|
1174
|
-
onOpenChange?: (open: boolean) => void;
|
|
1175
|
-
defaultOpen?: boolean;
|
|
1176
|
-
};
|
|
1177
|
-
|
|
1178
1436
|
declare interface Option_2<TValue = string> {
|
|
1179
1437
|
label: string;
|
|
1180
1438
|
value: TValue;
|
|
@@ -1184,15 +1442,164 @@ export { Option_2 as Option }
|
|
|
1184
1442
|
|
|
1185
1443
|
export declare type OverrideProps<T, TOverridden> = Omit<T, keyof TOverridden> & TOverridden;
|
|
1186
1444
|
|
|
1187
|
-
export declare type PageSize = (typeof
|
|
1445
|
+
export declare type PageSize = (typeof PAGINATION_SIZES)[number] | number;
|
|
1446
|
+
|
|
1447
|
+
export declare function Pagination({ sizes, selectClassName, rangeClassName, previousClassName, nextClassName, className, ...rootProps }: PaginationProps): JSX.Element;
|
|
1448
|
+
|
|
1449
|
+
export declare const PAGINATION_SIZES: readonly [10, 25, 50];
|
|
1450
|
+
|
|
1451
|
+
export declare interface PaginationContextValue {
|
|
1452
|
+
currentPage: number;
|
|
1453
|
+
maxPage: number;
|
|
1454
|
+
pageSize: PageSize;
|
|
1455
|
+
totalItems: number;
|
|
1456
|
+
paginationRange: (string | number)[];
|
|
1457
|
+
range: {
|
|
1458
|
+
start: number;
|
|
1459
|
+
end: number;
|
|
1460
|
+
};
|
|
1461
|
+
isFirstPage: boolean;
|
|
1462
|
+
isLastPage: boolean;
|
|
1463
|
+
goTo: (page: number) => void;
|
|
1464
|
+
next: () => void;
|
|
1465
|
+
prev: () => void;
|
|
1466
|
+
setPageSize: (size: PageSize) => void;
|
|
1467
|
+
getPageHref?: GetPageHref;
|
|
1468
|
+
linkComponent: LinkComponent;
|
|
1469
|
+
texts: PaginationTexts;
|
|
1470
|
+
}
|
|
1471
|
+
|
|
1472
|
+
export declare function PaginationEllipsis({ className, ...props }: ComponentProps<"span">): JSX.Element;
|
|
1473
|
+
|
|
1474
|
+
export declare function PaginationFirst({ className, buttonProps, children, }: PaginationNavProps): JSX.Element;
|
|
1188
1475
|
|
|
1189
|
-
export declare
|
|
1476
|
+
export declare function PaginationLast({ className, buttonProps, children, }: PaginationNavProps): JSX.Element;
|
|
1190
1477
|
|
|
1191
|
-
declare
|
|
1478
|
+
export declare function PaginationLink({ page, isActive: isActiveProp, className, children, buttonProps, }: PaginationLinkProps): JSX.Element;
|
|
1479
|
+
|
|
1480
|
+
declare interface PaginationLinkProps {
|
|
1481
|
+
page: number;
|
|
1192
1482
|
isActive?: boolean;
|
|
1483
|
+
className?: string;
|
|
1484
|
+
children?: ReactNode;
|
|
1485
|
+
buttonProps?: ButtonOverrides;
|
|
1486
|
+
}
|
|
1487
|
+
|
|
1488
|
+
declare interface PaginationNavProps {
|
|
1489
|
+
className?: string;
|
|
1490
|
+
buttonProps?: ButtonOverrides;
|
|
1491
|
+
children?: ReactNode;
|
|
1492
|
+
}
|
|
1493
|
+
|
|
1494
|
+
export declare function PaginationNext({ className, buttonProps, children, }: PaginationNavProps): JSX.Element;
|
|
1495
|
+
|
|
1496
|
+
export declare function PaginationPageInfo({ children, className, ...props }: PaginationPageInfoProps): JSX.Element;
|
|
1497
|
+
|
|
1498
|
+
declare interface PaginationPageInfoProps {
|
|
1499
|
+
className?: string;
|
|
1500
|
+
/**
|
|
1501
|
+
* Custom content. Receives `{ page, max }`, or pass a static ReactNode.
|
|
1502
|
+
* @default `Página ${page} de ${max}`
|
|
1503
|
+
*/
|
|
1504
|
+
children?: ReactNode | ((state: {
|
|
1505
|
+
page: number;
|
|
1506
|
+
max: number;
|
|
1507
|
+
}) => ReactNode);
|
|
1193
1508
|
}
|
|
1194
1509
|
|
|
1195
|
-
declare function
|
|
1510
|
+
export declare function PaginationPages({ className, linkClassName, ellipsisClassName, }: PaginationPagesProps): JSX.Element;
|
|
1511
|
+
|
|
1512
|
+
declare interface PaginationPagesProps {
|
|
1513
|
+
className?: string;
|
|
1514
|
+
linkClassName?: string;
|
|
1515
|
+
ellipsisClassName?: string;
|
|
1516
|
+
}
|
|
1517
|
+
|
|
1518
|
+
export declare function PaginationPrevious({ className, buttonProps, children, }: PaginationNavProps): JSX.Element;
|
|
1519
|
+
|
|
1520
|
+
export declare interface PaginationProps extends Omit<PaginationRootProps, "children"> {
|
|
1521
|
+
sizes?: readonly PageSize[] | PageSize[] | false;
|
|
1522
|
+
selectClassName?: string;
|
|
1523
|
+
rangeClassName?: string;
|
|
1524
|
+
previousClassName?: string;
|
|
1525
|
+
nextClassName?: string;
|
|
1526
|
+
}
|
|
1527
|
+
|
|
1528
|
+
export declare function PaginationRange({ children, className, ...props }: PaginationRangeProps): JSX.Element;
|
|
1529
|
+
|
|
1530
|
+
declare interface PaginationRangeProps {
|
|
1531
|
+
className?: string;
|
|
1532
|
+
/**
|
|
1533
|
+
* Custom content. Receives `{ start, end, total }`, or pass a static ReactNode.
|
|
1534
|
+
* @default `${start} - ${end} de ${total}`
|
|
1535
|
+
*/
|
|
1536
|
+
children?: ReactNode | ((state: {
|
|
1537
|
+
start: number;
|
|
1538
|
+
end: number;
|
|
1539
|
+
total: number;
|
|
1540
|
+
}) => ReactNode);
|
|
1541
|
+
}
|
|
1542
|
+
|
|
1543
|
+
export declare function PaginationRoot({ totalItems, pageSize: pageSizeProp, defaultPageSize, onPageSizeChange, currentPage, defaultCurrentPage, onCurrentPageChange, siblingCount, getPageHref, linkComponent, texts: textsProp, className, children, ...props }: PaginationRootProps): JSX.Element;
|
|
1544
|
+
|
|
1545
|
+
export declare interface PaginationRootProps extends Omit<ComponentProps<"nav">, "onChange"> {
|
|
1546
|
+
totalItems: number;
|
|
1547
|
+
pageSize?: PageSize;
|
|
1548
|
+
defaultPageSize?: PageSize;
|
|
1549
|
+
onPageSizeChange?: (size: PageSize) => void;
|
|
1550
|
+
currentPage?: number;
|
|
1551
|
+
defaultCurrentPage?: number;
|
|
1552
|
+
onCurrentPageChange?: (page: number) => void;
|
|
1553
|
+
siblingCount?: number;
|
|
1554
|
+
getPageHref?: GetPageHref;
|
|
1555
|
+
linkComponent?: LinkComponent;
|
|
1556
|
+
texts?: Partial<PaginationTexts>;
|
|
1557
|
+
}
|
|
1558
|
+
|
|
1559
|
+
export declare function PaginationSizeSelect({ sizes, className, ...props }: PaginationSizeSelectProps): JSX.Element;
|
|
1560
|
+
|
|
1561
|
+
declare interface PaginationSizeSelectProps extends Omit<ComponentProps<"select">, "value" | "onChange"> {
|
|
1562
|
+
sizes?: readonly PageSize[] | PageSize[];
|
|
1563
|
+
}
|
|
1564
|
+
|
|
1565
|
+
export declare interface PaginationTexts {
|
|
1566
|
+
goToFirst: string;
|
|
1567
|
+
goToPrevious: string;
|
|
1568
|
+
goToNext: string;
|
|
1569
|
+
goToLast: string;
|
|
1570
|
+
goToPage: (page: number) => string;
|
|
1571
|
+
total: (n: number) => string;
|
|
1572
|
+
pageInfo: (page: number, max: number) => string;
|
|
1573
|
+
range: (start: number, end: number, total: number) => string;
|
|
1574
|
+
morePages: string;
|
|
1575
|
+
}
|
|
1576
|
+
|
|
1577
|
+
export declare function PaginationTotal({ children, className, ...props }: PaginationTotalProps): JSX.Element;
|
|
1578
|
+
|
|
1579
|
+
declare interface PaginationTotalProps {
|
|
1580
|
+
className?: string;
|
|
1581
|
+
/**
|
|
1582
|
+
* Custom content. Receives the total number of items, or pass a static ReactNode.
|
|
1583
|
+
* @default `${total} resultados`
|
|
1584
|
+
*/
|
|
1585
|
+
children?: ReactNode | ((total: number) => ReactNode);
|
|
1586
|
+
}
|
|
1587
|
+
|
|
1588
|
+
declare type ParentIcon = ReactNode | ((isExpanded: boolean) => ReactNode);
|
|
1589
|
+
|
|
1590
|
+
/**
|
|
1591
|
+
* Validates `formValues` from `Form.onFormSubmit` against a Zod schema and
|
|
1592
|
+
* returns `{ data, errors }` ready to wire back into `Form`'s `errors` prop.
|
|
1593
|
+
*
|
|
1594
|
+
* - `data` is the typed, parsed value, or `null` when validation fails.
|
|
1595
|
+
* - `errors` is the flattened `fieldErrors` object (empty on success).
|
|
1596
|
+
*/
|
|
1597
|
+
export declare function parseFormValues<T extends z.ZodType>(schema: T, values: Record<string, unknown>): {
|
|
1598
|
+
data: z.infer<T> | null;
|
|
1599
|
+
errors: Record<string, string[]>;
|
|
1600
|
+
};
|
|
1601
|
+
|
|
1602
|
+
declare function Password({ className, showIcon, hideIcon, onShow, onHide, toggleable, onValueChange, classNames, ...rest }: PasswordProps): JSX.Element;
|
|
1196
1603
|
export { Password }
|
|
1197
1604
|
export { Password as PasswordRoot }
|
|
1198
1605
|
|
|
@@ -1202,11 +1609,18 @@ declare type PasswordProps = Omit<InputProps, "unstyled" | "nativeInput"> & {
|
|
|
1202
1609
|
onShow?: () => void;
|
|
1203
1610
|
onHide?: () => void;
|
|
1204
1611
|
toggleable?: boolean;
|
|
1612
|
+
/** Styles applied to each internal slot. */
|
|
1613
|
+
classNames?: {
|
|
1614
|
+
/** Native `<input>` element (transparent inside the wrapper). */
|
|
1615
|
+
input?: string;
|
|
1616
|
+
/** Show/hide toggle button on the right. */
|
|
1617
|
+
toggle?: string;
|
|
1618
|
+
};
|
|
1205
1619
|
};
|
|
1206
1620
|
export { PasswordProps }
|
|
1207
1621
|
export { PasswordProps as PasswordRootProps }
|
|
1208
1622
|
|
|
1209
|
-
export declare function Popover({ trigger, children, title, description, side, align, sideOffset, alignOffset, tooltipStyle, matchTriggerWidth, anchor,
|
|
1623
|
+
export declare function Popover({ trigger, children, title, description, side, align, sideOffset, alignOffset, tooltipStyle, matchTriggerWidth, anchor, className, classNames, ...rootProps }: PopoverProps): default_2.ReactElement;
|
|
1210
1624
|
|
|
1211
1625
|
export declare function PopoverClose({ ...props }: PopoverPrimitive.Close.Props): default_2.ReactElement;
|
|
1212
1626
|
|
|
@@ -1214,8 +1628,9 @@ export declare const PopoverCreateHandle: typeof PopoverPrimitive.createHandle;
|
|
|
1214
1628
|
|
|
1215
1629
|
export declare function PopoverDescription({ className, ...props }: PopoverPrimitive.Description.Props): default_2.ReactElement;
|
|
1216
1630
|
|
|
1217
|
-
declare function PopoverPopup({ children, className, side, align, sideOffset, alignOffset, tooltipStyle, matchTriggerWidth, anchor, portalProps, ...props }: PopoverPrimitive.Popup.Props & {
|
|
1631
|
+
declare function PopoverPopup({ children, className, side, align, sideOffset, alignOffset, tooltipStyle, matchTriggerWidth, anchor, portalProps, viewportClassName, ...props }: PopoverPrimitive.Popup.Props & {
|
|
1218
1632
|
portalProps?: PopoverPrimitive.Portal.Props;
|
|
1633
|
+
viewportClassName?: string;
|
|
1219
1634
|
side?: PopoverPrimitive.Positioner.Props["side"];
|
|
1220
1635
|
align?: PopoverPrimitive.Positioner.Props["align"];
|
|
1221
1636
|
sideOffset?: PopoverPrimitive.Positioner.Props["sideOffset"];
|
|
@@ -1227,8 +1642,6 @@ declare function PopoverPopup({ children, className, side, align, sideOffset, al
|
|
|
1227
1642
|
export { PopoverPopup as PopoverContent }
|
|
1228
1643
|
export { PopoverPopup }
|
|
1229
1644
|
|
|
1230
|
-
declare type PopoverPopupOverrideProps = Omit<default_2.ComponentPropsWithoutRef<typeof PopoverPopup>, "children" | "side" | "align" | "sideOffset" | "alignOffset" | "tooltipStyle" | "matchTriggerWidth" | "anchor">;
|
|
1231
|
-
|
|
1232
1645
|
export { PopoverPrimitive }
|
|
1233
1646
|
|
|
1234
1647
|
declare interface PopoverProps extends Omit<PopoverPrimitive.Root.Props, "children"> {
|
|
@@ -1243,9 +1656,13 @@ declare interface PopoverProps extends Omit<PopoverPrimitive.Root.Props, "childr
|
|
|
1243
1656
|
tooltipStyle?: boolean;
|
|
1244
1657
|
matchTriggerWidth?: boolean;
|
|
1245
1658
|
anchor?: PopoverPrimitive.Positioner.Props["anchor"];
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1659
|
+
/** Styles the popup (visual root). */
|
|
1660
|
+
className?: string;
|
|
1661
|
+
/** Styles applied to each internal slot. */
|
|
1662
|
+
classNames?: {
|
|
1663
|
+
/** Inner viewport that holds the popup content (padding, overflow). */
|
|
1664
|
+
viewport?: string;
|
|
1665
|
+
};
|
|
1249
1666
|
}
|
|
1250
1667
|
|
|
1251
1668
|
export declare const PopoverRoot: typeof PopoverPrimitive.Root;
|
|
@@ -1283,79 +1700,27 @@ declare const progressTrackVariants: (props?: ({
|
|
|
1283
1700
|
|
|
1284
1701
|
export declare function ProgressValue({ className, ...props }: Progress_2.Value.Props): React_2.ReactElement;
|
|
1285
1702
|
|
|
1286
|
-
declare
|
|
1287
|
-
|
|
1288
|
-
placeholder?: string;
|
|
1289
|
-
emptyMessage?: string;
|
|
1290
|
-
onSelect?: (value: AutoCompleteItem["value"], item: AutoCompleteItem) => any;
|
|
1291
|
-
}
|
|
1292
|
-
|
|
1293
|
-
declare type Props_10<T> = {
|
|
1294
|
-
data: T[];
|
|
1295
|
-
columns: ColumnDef<T>[];
|
|
1296
|
-
onRowClick?: (row: T) => void;
|
|
1297
|
-
onDoubleClick?: (row: T) => void;
|
|
1298
|
-
selected?: (row: T) => boolean;
|
|
1299
|
-
} & ExtendedProps_2 & Omit<ComponentPropsWithoutRef<typeof TableRoot>, "data" | "selected" | "onDoubleClick">;
|
|
1300
|
-
|
|
1301
|
-
declare type Props_11 = {
|
|
1302
|
-
setPageSize?: (value: PageSize) => void;
|
|
1303
|
-
pageSize?: PageSize;
|
|
1304
|
-
} & Omit<usePaginationProps, "pageSize"> & TablePaginationExtendedProps;
|
|
1305
|
-
|
|
1306
|
-
declare type Props_12 = ClosableProps | NonClosableProps;
|
|
1307
|
-
|
|
1308
|
-
declare type Props_13<T extends TreeNode> = TreeRootProps & {
|
|
1309
|
-
items: T[];
|
|
1703
|
+
declare type Props = BaseButtonProps & VariantProps<typeof buttonVariants> & {
|
|
1704
|
+
icon?: ReactElement;
|
|
1310
1705
|
};
|
|
1311
1706
|
|
|
1312
|
-
declare interface
|
|
1313
|
-
fn: () => Promise<T>;
|
|
1314
|
-
dependencies?: DependencyList;
|
|
1315
|
-
}
|
|
1316
|
-
|
|
1317
|
-
declare interface Props_2 extends HTMLProps<HTMLDivElement> {
|
|
1318
|
-
/**
|
|
1319
|
-
* La URL de la imagen
|
|
1320
|
-
*/
|
|
1321
|
-
src: string;
|
|
1322
|
-
}
|
|
1323
|
-
|
|
1324
|
-
declare type Props_3 = BaseButtonProps & VariantProps<typeof buttonVariants>;
|
|
1325
|
-
|
|
1326
|
-
declare interface Props_4 extends ComponentProps<"button"> {
|
|
1327
|
-
asChild?: boolean;
|
|
1707
|
+
declare interface Props_2 extends ComponentProps<typeof Button_2> {
|
|
1328
1708
|
loading?: boolean;
|
|
1329
|
-
showLoader?: boolean;
|
|
1330
|
-
icon?: ReactNode;
|
|
1331
|
-
iconPosition?: "start" | "end";
|
|
1332
|
-
loaderReplace?: true;
|
|
1333
1709
|
}
|
|
1334
1710
|
|
|
1335
|
-
declare type
|
|
1336
|
-
|
|
1337
|
-
title?: ReactNode;
|
|
1338
|
-
description?: ReactNode;
|
|
1339
|
-
};
|
|
1340
|
-
|
|
1341
|
-
declare type Props_6<C extends React.ElementType> = VariantProps<typeof HeadingVariants> & {
|
|
1342
|
-
as?: C;
|
|
1343
|
-
} & Omit<React.ComponentPropsWithoutRef<C>, "as">;
|
|
1344
|
-
|
|
1345
|
-
declare type Props_7 = LucideProps & LoaderVariants & {
|
|
1711
|
+
declare type Props_3 = LucideProps & LoaderVariants & {
|
|
1712
|
+
/** Renders the loader fixed at the viewport center via `fixed inset-0`. */
|
|
1346
1713
|
center?: boolean;
|
|
1347
|
-
|
|
1714
|
+
/** Styles applied to each internal slot. */
|
|
1715
|
+
classNames?: {
|
|
1716
|
+
/** Wrapper around the spinner (used for `center` overlay). */
|
|
1717
|
+
container?: string;
|
|
1718
|
+
};
|
|
1348
1719
|
};
|
|
1349
1720
|
|
|
1350
|
-
declare interface
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
containerProps?: HTMLProps<HTMLDivElement>;
|
|
1354
|
-
}
|
|
1355
|
-
|
|
1356
|
-
declare interface Props_9 extends ComponentPropsWithoutRef<typeof Slot> {
|
|
1357
|
-
/** Si el componente está presente o no */
|
|
1358
|
-
when: ComponentProps<typeof Presence>["present"];
|
|
1721
|
+
declare interface Props_4<T> extends UseAsyncOptions<T> {
|
|
1722
|
+
fn: () => Promise<T>;
|
|
1723
|
+
dependencies?: DependencyList;
|
|
1359
1724
|
}
|
|
1360
1725
|
|
|
1361
1726
|
declare type PropsWithoutValue<T> = Omit<T, "value" | "onChange" | "defaultValue">;
|
|
@@ -1366,7 +1731,7 @@ export declare type RangeDatePickerProps = DatePickerBaseProps & {
|
|
|
1366
1731
|
mode: "range";
|
|
1367
1732
|
value?: DateRange;
|
|
1368
1733
|
defaultValue?: DateRange;
|
|
1369
|
-
|
|
1734
|
+
onValueChange?: (value: DateRange) => void;
|
|
1370
1735
|
placeholder?: string;
|
|
1371
1736
|
};
|
|
1372
1737
|
|
|
@@ -1462,30 +1827,37 @@ export { ScrollAreaPrimitive }
|
|
|
1462
1827
|
export declare function ScrollBar({ className, orientation, ...props }: ScrollAreaPrimitive.Scrollbar.Props): default_2.ReactElement;
|
|
1463
1828
|
|
|
1464
1829
|
/**
|
|
1465
|
-
* Composite select for single and multiple selection.
|
|
1466
|
-
*
|
|
1467
|
-
*
|
|
1830
|
+
* Composite select for single and multiple selection.
|
|
1831
|
+
*
|
|
1832
|
+
* Items shaped as `{ id, name }`, `{ label, value }`, or plain strings/numbers
|
|
1833
|
+
* work with no extra props. For other shapes, provide `getLabel` and/or `getId`.
|
|
1468
1834
|
*
|
|
1469
1835
|
* `renderItem` customizes the content **inside** each `SelectItem` (the
|
|
1470
1836
|
* checkmark indicator is always rendered by the item wrapper).
|
|
1471
1837
|
*
|
|
1472
1838
|
* Use `SelectRoot` + primitives directly when you need full structural
|
|
1473
|
-
* control beyond what
|
|
1839
|
+
* control beyond what `className` + `classNames` slots offer.
|
|
1474
1840
|
*/
|
|
1475
1841
|
export declare function Select<TItem = unknown>(allProps: SelectProps<TItem>): React_2.ReactElement;
|
|
1476
1842
|
|
|
1477
|
-
declare type SelectBaseProps<TItem = unknown> = Omit<
|
|
1843
|
+
declare type SelectBaseProps<TItem = unknown> = Omit<SelectPrimitive.Root.Props<string, false>, "children" | "onValueChange" | "value" | "defaultValue" | "items" | "multiple"> & {
|
|
1478
1844
|
items: readonly TItem[];
|
|
1845
|
+
/** Returns the display text for an item. Used for the trigger value and ARIA. Defaults to `item.label`, `item.name`, `item.title`, or the stringified primitive. */
|
|
1479
1846
|
getLabel?: (item: TItem) => string;
|
|
1480
|
-
|
|
1847
|
+
/** Returns a stable string identifier for an item. Used as the React key and the underlying option value. Defaults to `item.id`, `item.value`, or the stringified primitive. */
|
|
1848
|
+
getId?: (item: TItem) => string;
|
|
1849
|
+
/** Returns whether an item should be disabled. Defaults to `item.disabled === true`. */
|
|
1850
|
+
getDisabled?: (item: TItem) => boolean;
|
|
1481
1851
|
renderItem?: (item: TItem) => React_2.ReactNode;
|
|
1482
1852
|
placeholder?: string;
|
|
1483
|
-
triggerProps?: React_2.ComponentProps<typeof SelectTrigger>;
|
|
1484
|
-
popupProps?: React_2.ComponentProps<typeof SelectPopup>;
|
|
1485
|
-
popupClassName?: string;
|
|
1486
|
-
itemProps?: SelectPrimitive.Item.Props;
|
|
1487
|
-
itemClassName?: string;
|
|
1488
1853
|
className?: string;
|
|
1854
|
+
/** Styles applied to each internal slot. */
|
|
1855
|
+
classNames?: {
|
|
1856
|
+
/** Popup panel containing the item list. */
|
|
1857
|
+
popup?: string;
|
|
1858
|
+
/** Individual item row. */
|
|
1859
|
+
item?: string;
|
|
1860
|
+
};
|
|
1489
1861
|
};
|
|
1490
1862
|
|
|
1491
1863
|
export declare function SelectButton({ className, render, children, ...props }: SelectButtonProps): React_2.ReactElement;
|
|
@@ -1520,21 +1892,15 @@ export declare type SelectProps<TItem = unknown> = (SelectBaseProps<TItem> & {
|
|
|
1520
1892
|
multiple?: false;
|
|
1521
1893
|
value?: TItem | null;
|
|
1522
1894
|
defaultValue?: TItem | null;
|
|
1523
|
-
|
|
1895
|
+
onValueChange?: (value: TItem | null) => void;
|
|
1524
1896
|
}) | (SelectBaseProps<TItem> & {
|
|
1525
1897
|
multiple: true;
|
|
1526
1898
|
value?: TItem[];
|
|
1527
1899
|
defaultValue?: TItem[];
|
|
1528
|
-
|
|
1900
|
+
onValueChange?: (value: TItem[]) => void;
|
|
1529
1901
|
});
|
|
1530
1902
|
|
|
1531
|
-
export declare function SelectRoot<Value = string, Multiple extends boolean | undefined = false>({
|
|
1532
|
-
onChange?: SelectPrimitive.Root.Props<Value, Multiple>["onValueChange"];
|
|
1533
|
-
}): React_2.ReactElement;
|
|
1534
|
-
|
|
1535
|
-
declare type SelectRootPropsAlias<V = string> = Omit<SelectPrimitive.Root.Props<V, false>, "onValueChange"> & {
|
|
1536
|
-
onChange?: SelectPrimitive.Root.Props<V, false>["onValueChange"];
|
|
1537
|
-
};
|
|
1903
|
+
export declare function SelectRoot<Value = string, Multiple extends boolean | undefined = false>({ ...props }: SelectPrimitive.Root.Props<Value, Multiple>): React_2.ReactElement;
|
|
1538
1904
|
|
|
1539
1905
|
export declare function SelectSeparator({ className, ...props }: SelectPrimitive.Separator.Props): React_2.ReactElement;
|
|
1540
1906
|
|
|
@@ -1550,19 +1916,11 @@ export { SeparatorPrimitive }
|
|
|
1550
1916
|
|
|
1551
1917
|
export declare type SetState<T> = Dispatch<SetStateAction<T>>;
|
|
1552
1918
|
|
|
1553
|
-
declare type Shortcut = Partial<{
|
|
1554
|
-
shortcut: MenuShortcutProps["keys"];
|
|
1555
|
-
onShortcut: MenuShortcutProps["handler"];
|
|
1556
|
-
shortcutOptions: MenuShortcutProps["options"];
|
|
1557
|
-
}>;
|
|
1558
|
-
|
|
1559
|
-
export declare const Show: ({ when, ...props }: Props_9) => JSX.Element;
|
|
1560
|
-
|
|
1561
1919
|
export declare type SingleDatePickerProps = DatePickerBaseProps & {
|
|
1562
1920
|
mode: "single";
|
|
1563
1921
|
value?: Date | null;
|
|
1564
1922
|
defaultValue?: Date | null;
|
|
1565
|
-
|
|
1923
|
+
onValueChange?: (value: Date | null) => void;
|
|
1566
1924
|
placeholder?: string;
|
|
1567
1925
|
};
|
|
1568
1926
|
|
|
@@ -1586,193 +1944,216 @@ declare interface StackProps extends ComponentProps<"div"> {
|
|
|
1586
1944
|
justify?: CSSProperties["justifyContent"];
|
|
1587
1945
|
align?: CSSProperties["alignItems"];
|
|
1588
1946
|
gap?: CSSProperties["gap"];
|
|
1589
|
-
wrap?: CSSProperties["flexWrap"];
|
|
1947
|
+
wrap?: CSSProperties["flexWrap"] | boolean;
|
|
1590
1948
|
grow?: boolean;
|
|
1591
1949
|
}
|
|
1592
1950
|
|
|
1593
1951
|
export declare type State<T> = [T, SetState<T>];
|
|
1594
1952
|
|
|
1595
|
-
export declare
|
|
1953
|
+
export declare type StepIndicators = Partial<Record<StepState, ReactNode>>;
|
|
1596
1954
|
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
className?: ClassName;
|
|
1955
|
+
declare interface StepItemContextValue {
|
|
1956
|
+
step: number;
|
|
1957
|
+
state: StepState;
|
|
1958
|
+
isDisabled: boolean;
|
|
1959
|
+
isLoading: boolean;
|
|
1603
1960
|
}
|
|
1604
1961
|
|
|
1605
|
-
export declare function
|
|
1962
|
+
export declare function Stepper({ items, classNames, ...props }: StepperProps): JSX.Element;
|
|
1963
|
+
|
|
1964
|
+
export declare function StepperContent({ value, forceMount, className, render, children, ...props }: StepperContentProps): ReactElement<unknown, string | JSXElementConstructor<any>> | null;
|
|
1606
1965
|
|
|
1607
|
-
declare interface StepperContentProps extends
|
|
1966
|
+
export declare interface StepperContentProps extends useRender.ComponentProps<"div"> {
|
|
1608
1967
|
value: number;
|
|
1968
|
+
forceMount?: boolean;
|
|
1609
1969
|
}
|
|
1610
1970
|
|
|
1611
|
-
declare interface
|
|
1971
|
+
declare interface StepperContextValue {
|
|
1972
|
+
activeStep: number;
|
|
1973
|
+
setActiveStep: (step: number) => void;
|
|
1974
|
+
orientation: StepperOrientation;
|
|
1975
|
+
indicators: StepIndicators;
|
|
1976
|
+
triggerMode: StepperTriggerMode;
|
|
1977
|
+
}
|
|
1978
|
+
|
|
1979
|
+
export declare function StepperDescription({ className, render, children, ...props }: useRender.ComponentProps<"p">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
1980
|
+
|
|
1981
|
+
export declare function StepperIndicator({ className, render, children, ...props }: useRender.ComponentProps<"div">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
1982
|
+
|
|
1983
|
+
export declare function StepperItem({ step, disabled, loading, className, render, children, ...props }: StepperItemProps): JSX.Element;
|
|
1984
|
+
|
|
1985
|
+
export declare interface StepperItemData {
|
|
1986
|
+
title?: ReactNode;
|
|
1987
|
+
description?: ReactNode;
|
|
1612
1988
|
indicator?: ReactNode;
|
|
1613
|
-
title: ReactNode;
|
|
1614
1989
|
content?: ReactNode;
|
|
1615
1990
|
disabled?: boolean;
|
|
1991
|
+
loading?: boolean;
|
|
1616
1992
|
}
|
|
1617
1993
|
|
|
1618
|
-
export declare
|
|
1619
|
-
|
|
1620
|
-
|
|
1994
|
+
export declare interface StepperItemProps extends useRender.ComponentProps<"div"> {
|
|
1995
|
+
step: number;
|
|
1996
|
+
disabled?: boolean;
|
|
1997
|
+
loading?: boolean;
|
|
1621
1998
|
}
|
|
1622
1999
|
|
|
1623
|
-
declare
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
2000
|
+
export declare function StepperNav({ className, render, children, ...props }: useRender.ComponentProps<"nav">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
2001
|
+
|
|
2002
|
+
export declare type StepperOrientation = "horizontal" | "vertical";
|
|
2003
|
+
|
|
2004
|
+
export declare function StepperPanel({ className, render, children, ...props }: useRender.ComponentProps<"div">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
2005
|
+
|
|
2006
|
+
export declare interface StepperProps extends Omit<StepperRootProps, "children"> {
|
|
2007
|
+
items: StepperItemData[];
|
|
2008
|
+
/** Styles applied to each internal slot. */
|
|
2009
|
+
classNames?: {
|
|
2010
|
+
/** Navigation list that holds every step. */
|
|
2011
|
+
nav?: string;
|
|
2012
|
+
/** Single step container (indicator + label + separator). */
|
|
2013
|
+
item?: string;
|
|
2014
|
+
/** Clickable step button. */
|
|
2015
|
+
trigger?: string;
|
|
2016
|
+
/** Round indicator (number, icon, or check). */
|
|
2017
|
+
indicator?: string;
|
|
2018
|
+
/** Step title above the description. */
|
|
2019
|
+
title?: string;
|
|
2020
|
+
/** Step description below the title. */
|
|
2021
|
+
description?: string;
|
|
2022
|
+
/** Line between steps. */
|
|
2023
|
+
separator?: string;
|
|
2024
|
+
/** Panel below the nav that holds the active step's content. */
|
|
2025
|
+
panel?: string;
|
|
2026
|
+
/** Single step content rendered when the step is active. */
|
|
2027
|
+
content?: string;
|
|
2028
|
+
};
|
|
1633
2029
|
}
|
|
1634
2030
|
|
|
1635
|
-
export declare function
|
|
2031
|
+
export declare function StepperRoot({ defaultValue, value, onValueChange, orientation, indicators, triggerMode, className, render, children, ...props }: StepperRootProps): JSX.Element;
|
|
1636
2032
|
|
|
1637
|
-
declare interface
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
value: number;
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
classNameIndicator?: ClassNameValue;
|
|
2033
|
+
export declare interface StepperRootProps extends useRender.ComponentProps<"div"> {
|
|
2034
|
+
defaultValue?: number;
|
|
2035
|
+
value?: number;
|
|
2036
|
+
onValueChange?: (value: number) => void;
|
|
2037
|
+
orientation?: StepperOrientation;
|
|
2038
|
+
indicators?: StepIndicators;
|
|
2039
|
+
triggerMode?: StepperTriggerMode;
|
|
1645
2040
|
}
|
|
1646
2041
|
|
|
1647
|
-
declare
|
|
2042
|
+
export declare function StepperSeparator({ className, render, children, ...props }: useRender.ComponentProps<"div">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
2043
|
+
|
|
2044
|
+
export declare function StepperTitle({ className, render, children, ...props }: useRender.ComponentProps<"h3">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
1648
2045
|
|
|
1649
|
-
export declare function
|
|
2046
|
+
export declare function StepperTrigger({ className, render, children, ...props }: useRender.ComponentProps<"button">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
2047
|
+
|
|
2048
|
+
export declare type StepperTriggerMode = "both" | "forward-only" | "backward-only" | "none";
|
|
2049
|
+
|
|
2050
|
+
export declare type StepState = "active" | "completed" | "inactive" | "loading";
|
|
2051
|
+
|
|
2052
|
+
export declare function Switch({ children, label, className, id, controlFirst, tooltip, classNames, ...props }: SwitchProps): React_2.ReactElement;
|
|
1650
2053
|
|
|
1651
2054
|
declare interface SwitchProps extends Omit<Switch_2.Root.Props, "children"> {
|
|
1652
2055
|
children?: React_2.ReactNode;
|
|
1653
2056
|
label?: React_2.ReactNode;
|
|
1654
2057
|
tooltip?: string;
|
|
1655
|
-
thumbProps?: Switch_2.Thumb.Props;
|
|
1656
2058
|
controlFirst?: boolean;
|
|
2059
|
+
/** Styles applied to each internal slot. */
|
|
2060
|
+
classNames?: {
|
|
2061
|
+
/** Outer flex wrapper that holds the switch and label. */
|
|
2062
|
+
wrapper?: string;
|
|
2063
|
+
/** Sliding thumb (knob) inside the switch. */
|
|
2064
|
+
thumb?: string;
|
|
2065
|
+
/** Label rendered next to the switch. */
|
|
2066
|
+
label?: string;
|
|
2067
|
+
};
|
|
1657
2068
|
}
|
|
1658
2069
|
|
|
1659
2070
|
export declare function SwitchRoot({ className, ...props }: Switch_2.Root.Props): React_2.ReactElement;
|
|
1660
2071
|
|
|
1661
2072
|
export declare function SwitchThumb({ className, ...props }: Switch_2.Thumb.Props): React_2.ReactElement;
|
|
1662
2073
|
|
|
1663
|
-
export declare
|
|
1664
|
-
|
|
1665
|
-
export declare interface TabContentProps extends HTMLProps<HTMLDivElement> {
|
|
1666
|
-
value: string;
|
|
1667
|
-
}
|
|
1668
|
-
|
|
1669
|
-
export declare const Table: <T>({ data, columns, onRowClick, onDoubleClick, selected, theadClassName, theadProps, tbodyClassName, tbodyProps, trClassName, trProps, thClassName, thProps, tdClassName, tdProps, ...tableProps }: Props_10<T>) => JSX.Element;
|
|
2074
|
+
export declare function Table<T>({ data, columns, getRowKey, onRowClick, onRowDoubleClick, selected, classNames, ...tableProps }: TableProps<T>): JSX.Element;
|
|
1670
2075
|
|
|
1671
|
-
export declare
|
|
2076
|
+
export declare function TableBody({ className, ...props }: React_2.ComponentProps<"tbody">): JSX.Element;
|
|
1672
2077
|
|
|
1673
|
-
export declare
|
|
2078
|
+
export declare function TableCaption({ className, ...props }: React_2.ComponentProps<"caption">): JSX.Element;
|
|
1674
2079
|
|
|
1675
|
-
declare
|
|
2080
|
+
export declare function TableCell({ className, ...props }: React_2.ComponentProps<"td">): JSX.Element;
|
|
1676
2081
|
|
|
1677
|
-
export declare
|
|
2082
|
+
export declare function TableFooter({ className, ...props }: React_2.ComponentProps<"tfoot">): JSX.Element;
|
|
1678
2083
|
|
|
1679
|
-
declare
|
|
2084
|
+
export declare function TableHead({ className, ...props }: React_2.ComponentProps<"th">): JSX.Element;
|
|
1680
2085
|
|
|
1681
|
-
export declare
|
|
2086
|
+
export declare function TableHeader({ className, ...props }: React_2.ComponentProps<"thead">): JSX.Element;
|
|
1682
2087
|
|
|
1683
|
-
declare type
|
|
1684
|
-
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
2088
|
+
declare type TableProps<T> = {
|
|
2089
|
+
data: T[];
|
|
2090
|
+
columns: ColumnDef<T>[];
|
|
2091
|
+
getRowKey?: (row: T, index: number) => string | number;
|
|
2092
|
+
onRowClick?: (row: T) => void;
|
|
2093
|
+
onRowDoubleClick?: (row: T) => void;
|
|
2094
|
+
selected?: (row: T) => boolean;
|
|
2095
|
+
/** Styles applied to each internal slot. */
|
|
2096
|
+
classNames?: {
|
|
2097
|
+
/** Outer wrapper div with overflow handling. */
|
|
2098
|
+
container?: string;
|
|
2099
|
+
/** `<thead>` element. */
|
|
2100
|
+
thead?: string;
|
|
2101
|
+
/** `<tbody>` element. */
|
|
2102
|
+
tbody?: string;
|
|
2103
|
+
/** `<tr>` inside `<thead>` (the single header row). */
|
|
2104
|
+
headerRow?: string;
|
|
2105
|
+
/** Each `<tr>` inside `<tbody>` (the repeating body rows). */
|
|
2106
|
+
tr?: string;
|
|
2107
|
+
/** Header cell `<th>`. */
|
|
2108
|
+
th?: string;
|
|
2109
|
+
/** Body cell `<td>`. */
|
|
2110
|
+
td?: string;
|
|
2111
|
+
};
|
|
2112
|
+
} & Omit<React_2.ComponentProps<"table">, "onDoubleClick">;
|
|
1708
2113
|
|
|
1709
|
-
export declare
|
|
2114
|
+
export declare function TableRoot({ className, classNames, ...props }: TableRootProps): JSX.Element;
|
|
1710
2115
|
|
|
1711
|
-
declare type TableRootProps =
|
|
1712
|
-
|
|
1713
|
-
|
|
2116
|
+
declare type TableRootProps = React_2.ComponentProps<"table"> & {
|
|
2117
|
+
/** Styles applied to each internal slot. */
|
|
2118
|
+
classNames?: {
|
|
2119
|
+
/** Outer wrapper div with overflow handling. */
|
|
2120
|
+
container?: string;
|
|
2121
|
+
};
|
|
1714
2122
|
};
|
|
1715
2123
|
|
|
1716
|
-
export declare
|
|
2124
|
+
export declare function TableRow({ className, ...props }: React_2.ComponentProps<"tr">): JSX.Element;
|
|
1717
2125
|
|
|
1718
|
-
declare
|
|
2126
|
+
export declare function Tabs({ className, ...props }: TabsPrimitive.Root.Props): default_2.ReactElement;
|
|
1719
2127
|
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
}
|
|
1727
|
-
|
|
1728
|
-
export declare const Tabs: ({ children, value: prop, onChange, defaultValue, variant, ...props }: TabsProps) => JSX.Element;
|
|
1729
|
-
|
|
1730
|
-
export declare interface TabsExtendedProps extends TabsProps {
|
|
1731
|
-
listClassName: TabListProps["className"];
|
|
1732
|
-
listProps: TabListProps;
|
|
1733
|
-
triggerClassName: TabTriggerProps["className"];
|
|
1734
|
-
triggerProps: TabTriggerProps;
|
|
1735
|
-
contentClassName: TabContentProps["className"];
|
|
1736
|
-
contentProps: TabContentProps;
|
|
1737
|
-
}
|
|
2128
|
+
declare function TabsList({ variant, centered, className, children, ...props }: TabsPrimitive.List.Props & {
|
|
2129
|
+
variant?: TabsVariant;
|
|
2130
|
+
centered?: boolean;
|
|
2131
|
+
}): default_2.ReactElement;
|
|
2132
|
+
export { TabsList as TabList }
|
|
2133
|
+
export { TabsList }
|
|
1738
2134
|
|
|
1739
|
-
|
|
1740
|
-
|
|
1741
|
-
|
|
1742
|
-
defaultValue?: string;
|
|
1743
|
-
variant?: "default" | "background";
|
|
1744
|
-
}
|
|
2135
|
+
declare function TabsPanel({ className, ...props }: TabsPrimitive.Panel.Props): default_2.ReactElement;
|
|
2136
|
+
export { TabsPanel as TabsContent }
|
|
2137
|
+
export { TabsPanel }
|
|
1745
2138
|
|
|
1746
|
-
export
|
|
2139
|
+
export { TabsPrimitive }
|
|
1747
2140
|
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
}
|
|
2141
|
+
declare function TabsTab({ className, ...props }: TabsPrimitive.Tab.Props): default_2.ReactElement;
|
|
2142
|
+
export { TabsTab }
|
|
2143
|
+
export { TabsTab as TabsTrigger }
|
|
1751
2144
|
|
|
1752
|
-
export declare
|
|
2145
|
+
export declare type TabsVariant = "underline" | "background";
|
|
1753
2146
|
|
|
1754
|
-
export declare
|
|
2147
|
+
export declare function Tag({ className, variant, render, ...props }: useRender.ComponentProps<"span"> & VariantProps<typeof tagVariants>): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
1755
2148
|
|
|
1756
2149
|
export declare const tagVariants: (props?: ({
|
|
1757
|
-
|
|
1758
|
-
variant?: "error" | "success" | "outline" | "secondary" | "primary" | "borderless" | null | undefined;
|
|
2150
|
+
variant?: "default" | "link" | "outline" | "secondary" | "ghost" | "error" | null | undefined;
|
|
1759
2151
|
} & ClassProp) | undefined) => string;
|
|
1760
2152
|
|
|
1761
|
-
export declare function Textarea({ className,
|
|
1762
|
-
|
|
1763
|
-
export declare function TextareaControl({ className, unstyled, children, ...props }: ComponentProps<"span"> & {
|
|
1764
|
-
unstyled?: boolean;
|
|
1765
|
-
}): ReactElement;
|
|
1766
|
-
|
|
1767
|
-
export declare function TextareaField({ className, ref, onChange, ...props }: TextareaFieldProps): ReactElement;
|
|
1768
|
-
|
|
1769
|
-
export declare type TextareaFieldProps = Omit<ComponentProps<"textarea">, "onChange"> & {
|
|
1770
|
-
onChange?: (value: string, event: ChangeEvent<HTMLTextAreaElement>) => void;
|
|
1771
|
-
};
|
|
2153
|
+
export declare function Textarea({ className, onValueChange, ...props }: TextareaProps): ReactElement;
|
|
1772
2154
|
|
|
1773
|
-
export declare type TextareaProps =
|
|
1774
|
-
|
|
1775
|
-
controlProps?: ComponentProps<typeof TextareaControl>;
|
|
2155
|
+
export declare type TextareaProps = Omit<ComponentProps<"textarea">, "onChange"> & {
|
|
2156
|
+
onValueChange?: (value: string, event: ChangeEvent<HTMLTextAreaElement>) => void;
|
|
1776
2157
|
};
|
|
1777
2158
|
|
|
1778
2159
|
export declare type Theme = {
|
|
@@ -1789,45 +2170,67 @@ declare type ThemeProviderProps = {
|
|
|
1789
2170
|
theme?: Theme;
|
|
1790
2171
|
};
|
|
1791
2172
|
|
|
1792
|
-
export declare
|
|
2173
|
+
export declare function Timeline({ items, variant, classNames, ...props }: TimelineProps): JSX.Element;
|
|
1793
2174
|
|
|
1794
|
-
export declare
|
|
2175
|
+
export declare function TimelineContent({ className, render, children, ...props }: useRender.ComponentProps<"div">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
1795
2176
|
|
|
1796
|
-
export declare
|
|
2177
|
+
export declare function TimelineDate({ className, render, children, ...props }: useRender.ComponentProps<"time">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
1797
2178
|
|
|
1798
|
-
declare
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
2179
|
+
export declare function TimelineHeader({ className, render, children, ...props }: useRender.ComponentProps<"div">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
2180
|
+
|
|
2181
|
+
export declare function TimelineIndicator({ className, render, children, ...props }: useRender.ComponentProps<"div">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
2182
|
+
|
|
2183
|
+
export declare function TimelineItem({ step, className, render, children, ...props }: TimelineItemProps): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
2184
|
+
|
|
2185
|
+
declare interface TimelineItemData {
|
|
2186
|
+
title?: ReactNode;
|
|
2187
|
+
content?: ReactNode;
|
|
2188
|
+
date?: ReactNode;
|
|
2189
|
+
indicator?: ReactNode;
|
|
1804
2190
|
}
|
|
1805
2191
|
|
|
1806
|
-
|
|
2192
|
+
declare interface TimelineItemProps extends useRender.ComponentProps<"div"> {
|
|
2193
|
+
step: number;
|
|
2194
|
+
}
|
|
1807
2195
|
|
|
1808
|
-
declare
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
2196
|
+
declare type TimelineOrientation = "horizontal" | "vertical";
|
|
2197
|
+
|
|
2198
|
+
declare interface TimelineProps extends Omit<TimelineRootProps, "children"> {
|
|
2199
|
+
items: TimelineItemData[];
|
|
2200
|
+
variant?: TimelineVariant;
|
|
2201
|
+
/** Styles applied to each internal slot. */
|
|
2202
|
+
classNames?: {
|
|
2203
|
+
/** Single timeline entry wrapper. */
|
|
2204
|
+
item?: string;
|
|
2205
|
+
/** Row that holds the indicator, date, and title. */
|
|
2206
|
+
header?: string;
|
|
2207
|
+
/** Title text inside the header. */
|
|
2208
|
+
title?: string;
|
|
2209
|
+
/** Date label inside the header. */
|
|
2210
|
+
date?: string;
|
|
2211
|
+
/** Body text below the header. */
|
|
2212
|
+
content?: string;
|
|
2213
|
+
/** Round dot marking the step. */
|
|
2214
|
+
indicator?: string;
|
|
2215
|
+
/** Line connecting consecutive items. */
|
|
2216
|
+
separator?: string;
|
|
2217
|
+
};
|
|
1817
2218
|
}
|
|
1818
2219
|
|
|
1819
|
-
declare
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
classNameItemContainerDot?: string;
|
|
1827
|
-
classNameItemContent?: string;
|
|
2220
|
+
export declare function TimelineRoot({ defaultValue, value, onValueChange, orientation, className, render, children, ...props }: TimelineRootProps): JSX.Element;
|
|
2221
|
+
|
|
2222
|
+
declare interface TimelineRootProps extends useRender.ComponentProps<"div"> {
|
|
2223
|
+
defaultValue?: number;
|
|
2224
|
+
value?: number;
|
|
2225
|
+
onValueChange?: (value: number) => void;
|
|
2226
|
+
orientation?: TimelineOrientation;
|
|
1828
2227
|
}
|
|
1829
2228
|
|
|
1830
|
-
export declare
|
|
2229
|
+
export declare function TimelineSeparator({ className, render, children, ...props }: useRender.ComponentProps<"div">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
2230
|
+
|
|
2231
|
+
export declare function TimelineTitle({ className, render, children, ...props }: useRender.ComponentProps<"h3">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
2232
|
+
|
|
2233
|
+
declare type TimelineVariant = "default" | "alternate" | "date-left";
|
|
1831
2234
|
|
|
1832
2235
|
/**
|
|
1833
2236
|
* Imperative toast API. Works anywhere — no hook needed.
|
|
@@ -1926,7 +2329,7 @@ export declare function toastVariants({ variant, }?: {
|
|
|
1926
2329
|
* </Tooltip>
|
|
1927
2330
|
* ```
|
|
1928
2331
|
*/
|
|
1929
|
-
export declare function Tooltip({ content, children, open, defaultOpen, onOpenChange, side, align, offset, delay, closeDelay, className,
|
|
2332
|
+
export declare function Tooltip({ content, children, open, defaultOpen, onOpenChange, side, align, offset, delay, closeDelay, className, classNames, ...triggerProps }: TooltipProps): JSX.Element;
|
|
1930
2333
|
|
|
1931
2334
|
export declare function TooltipArrow({ className, ...props }: ArrowProps): JSX.Element;
|
|
1932
2335
|
|
|
@@ -1949,14 +2352,16 @@ export declare type TooltipProps = Omit<RootProps, "children"> & Omit<TriggerPro
|
|
|
1949
2352
|
delay?: TriggerProps["delay"];
|
|
1950
2353
|
/** Delay in ms before the tooltip closes. @default 0 */
|
|
1951
2354
|
closeDelay?: TriggerProps["closeDelay"];
|
|
1952
|
-
/** Additional classes applied to the tooltip popup. */
|
|
2355
|
+
/** Additional classes applied to the tooltip popup (visual root). */
|
|
1953
2356
|
className?: string;
|
|
1954
|
-
/**
|
|
1955
|
-
|
|
1956
|
-
|
|
1957
|
-
|
|
1958
|
-
|
|
1959
|
-
|
|
2357
|
+
/** Styles applied to each internal slot. */
|
|
2358
|
+
classNames?: {
|
|
2359
|
+
/**
|
|
2360
|
+
* Arrow that points at the trigger. Pass a `text-*` class to change the
|
|
2361
|
+
* arrow color when overriding the popup background.
|
|
2362
|
+
*/
|
|
2363
|
+
arrow?: string;
|
|
2364
|
+
};
|
|
1960
2365
|
};
|
|
1961
2366
|
|
|
1962
2367
|
/** Enables shared hover intent and delay grouping across multiple tooltips. */
|
|
@@ -1966,84 +2371,29 @@ export declare function TooltipRoot(props: RootProps): JSX.Element;
|
|
|
1966
2371
|
|
|
1967
2372
|
export declare function TooltipTrigger({ className, ...props }: TriggerProps): JSX.Element;
|
|
1968
2373
|
|
|
1969
|
-
export declare function
|
|
2374
|
+
export declare function TreeDragLine({ className, render, style, ...props }: useRender.ComponentProps<"div">): ReactElement<unknown, string | JSXElementConstructor<any>> | null;
|
|
1970
2375
|
|
|
1971
|
-
export declare
|
|
1972
|
-
id: string | number;
|
|
1973
|
-
}>) => JSX.Element;
|
|
2376
|
+
export declare function TreeItem<T>({ item, leafIcon, parentIcon, className, render, children, style, ...props }: TreeItemProps<T>): JSX.Element;
|
|
1974
2377
|
|
|
1975
|
-
export declare
|
|
2378
|
+
export declare function TreeItemLabel({ className, render, children, ...props }: useRender.ComponentProps<"span">): ReactElement<unknown, string | JSXElementConstructor<any>>;
|
|
1976
2379
|
|
|
1977
|
-
export declare
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
export declare interface TreeNode {
|
|
1982
|
-
id: string | number;
|
|
1983
|
-
title: string;
|
|
1984
|
-
children: TreeNode[];
|
|
2380
|
+
export declare interface TreeItemProps<T> extends useRender.ComponentProps<"button"> {
|
|
2381
|
+
item: ItemInstance<T>;
|
|
2382
|
+
leafIcon?: ReactNode;
|
|
2383
|
+
parentIcon?: ParentIcon;
|
|
1985
2384
|
}
|
|
1986
2385
|
|
|
1987
|
-
export declare
|
|
2386
|
+
export declare function TreeRoot<T>({ tree, indent, className, render, style, ...props }: TreeRootProps<T>): JSX.Element;
|
|
1988
2387
|
|
|
1989
|
-
declare
|
|
2388
|
+
export declare interface TreeRootProps<T> extends useRender.ComponentProps<"div"> {
|
|
2389
|
+
tree: TreeInstance<T>;
|
|
2390
|
+
indent?: number;
|
|
2391
|
+
}
|
|
1990
2392
|
|
|
1991
2393
|
declare type TriggerProps = ComponentPropsWithoutRef<typeof TooltipPrimitive.Trigger>;
|
|
1992
2394
|
|
|
1993
2395
|
export declare const twMerge: (...classLists: ClassNameValue[]) => string;
|
|
1994
2396
|
|
|
1995
|
-
export declare const type: (element: HTMLElement, value: string) => void;
|
|
1996
|
-
|
|
1997
|
-
export declare const UploadAcceptedFiles: (props: UploadFilesProps) => JSX.Element;
|
|
1998
|
-
|
|
1999
|
-
export declare const UploadContent: ({ className, ...props }: UploadContentProps) => JSX.Element;
|
|
2000
|
-
|
|
2001
|
-
declare type UploadContentProps = ComponentPropsWithoutRef<"div"> & {
|
|
2002
|
-
renderRejectedFile?: (file: File) => ReactNode;
|
|
2003
|
-
};
|
|
2004
|
-
|
|
2005
|
-
declare type UploadFilesListProps = {
|
|
2006
|
-
files: File[];
|
|
2007
|
-
handleFileRemove: (index: number, type: "accepted" | "rejected") => void;
|
|
2008
|
-
fileType: "accepted" | "rejected";
|
|
2009
|
-
children?: ReactNode;
|
|
2010
|
-
renderFile?: (file: File, removeItem: () => void) => ReactNode;
|
|
2011
|
-
};
|
|
2012
|
-
|
|
2013
|
-
declare type UploadFilesProps = Omit<UploadFilesListProps, "fileType" | "handleFileRemove" | "files">;
|
|
2014
|
-
|
|
2015
|
-
export declare const UploadItem: ({ file, onRemove, className, renderIcon, ...props }: UploadItemProps) => JSX.Element;
|
|
2016
|
-
|
|
2017
|
-
declare type UploadItemProps = ComponentPropsWithoutRef<"div"> & {
|
|
2018
|
-
file: File;
|
|
2019
|
-
onRemove: () => void;
|
|
2020
|
-
renderIcon?: (file: File) => ReactNode;
|
|
2021
|
-
};
|
|
2022
|
-
|
|
2023
|
-
export declare const UploadRejectedFiles: (props: UploadFilesProps) => JSX.Element;
|
|
2024
|
-
|
|
2025
|
-
export declare const UploadRoot: ({ onFileAdd, onFileRemove, onChangeFiles, files: prop, maxFiles, allowedExtensions, maxFileSize, multiple, children, onError, ...props }: UploadRootProps) => JSX.Element;
|
|
2026
|
-
|
|
2027
|
-
declare type UploadRootProps = {
|
|
2028
|
-
onFileAdd?: (files: File[]) => void;
|
|
2029
|
-
onFileRemove?: (index: number, type: "accepted" | "rejected") => void;
|
|
2030
|
-
onChangeFiles?: (files: File[]) => void;
|
|
2031
|
-
files?: File[];
|
|
2032
|
-
maxFiles?: number;
|
|
2033
|
-
allowedExtensions?: string[];
|
|
2034
|
-
maxFileSize?: number;
|
|
2035
|
-
multiple?: true;
|
|
2036
|
-
className?: string;
|
|
2037
|
-
children?: ReactNode;
|
|
2038
|
-
onError?: (fileErrors: FileError[]) => void;
|
|
2039
|
-
};
|
|
2040
|
-
|
|
2041
|
-
export declare const UploadTrigger: ({ asChild, ...props }: UploadTriggerProps) => JSX.Element;
|
|
2042
|
-
|
|
2043
|
-
declare type UploadTriggerProps = {
|
|
2044
|
-
asChild?: boolean;
|
|
2045
|
-
} & ComponentPropsWithoutRef<"button">;
|
|
2046
|
-
|
|
2047
2397
|
export declare function useArray<T>(defaultProp: T[]): readonly [T[], {
|
|
2048
2398
|
readonly insertAt: (index: number, item: T) => void;
|
|
2049
2399
|
readonly removeAt: (index: number) => void;
|
|
@@ -2056,7 +2406,7 @@ export declare function useArray<T>(defaultProp: T[]): readonly [T[], {
|
|
|
2056
2406
|
readonly update: (predicate: ListIterateeCustom<T, boolean>, newItem: T | ((item: T) => T)) => void;
|
|
2057
2407
|
}];
|
|
2058
2408
|
|
|
2059
|
-
export declare function useAsync<T>({ fn, dependencies, onError, onSuccess, onFinish, }:
|
|
2409
|
+
export declare function useAsync<T>({ fn, dependencies, onError, onSuccess, onFinish, }: Props_4<T>): AsyncState<T>;
|
|
2060
2410
|
|
|
2061
2411
|
declare interface UseAsyncOptions<T> {
|
|
2062
2412
|
onError?: (error: Error) => void;
|
|
@@ -2064,6 +2414,8 @@ declare interface UseAsyncOptions<T> {
|
|
|
2064
2414
|
onFinish?: () => void;
|
|
2065
2415
|
}
|
|
2066
2416
|
|
|
2417
|
+
export declare const useAutocompleteFilter: typeof AutocompletePrimitive.useFilter;
|
|
2418
|
+
|
|
2067
2419
|
export declare const useClickOutside: <T extends HTMLElement = HTMLElement>(callback: () => void, watch?: boolean) => RefObject<T | null>;
|
|
2068
2420
|
|
|
2069
2421
|
export declare function useClipboard(): [CopiedValue, CopyFunction];
|
|
@@ -2089,8 +2441,12 @@ export declare function useDocumentTitle(title: string): void;
|
|
|
2089
2441
|
|
|
2090
2442
|
export declare function useEventListener<K extends keyof HTMLElementEventMap, T extends HTMLElement = any>(type: K, listener: (this: HTMLDivElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): RefObject<T | null>;
|
|
2091
2443
|
|
|
2444
|
+
export declare function useFieldName(): string | undefined;
|
|
2445
|
+
|
|
2092
2446
|
export declare function useFocusTrap(active?: boolean): (instance: HTMLElement | null) => void;
|
|
2093
2447
|
|
|
2448
|
+
export declare function useHookForm<T extends FieldValues = FieldValues>(schema: z.ZodType<T>, options?: Partial<UseFormProps<T>>): UseFormReturn<T>;
|
|
2449
|
+
|
|
2094
2450
|
export declare function useHotkey(keys: string | string[], handler: (event: KeyboardEvent) => void, options?: HotkeyOptions): RefObject<any>;
|
|
2095
2451
|
|
|
2096
2452
|
export declare function useHover<T extends HTMLElement>(options?: UseHoverOptions): {
|
|
@@ -2103,6 +2459,8 @@ declare type UseHoverOptions = {
|
|
|
2103
2459
|
onHoverEnd?: (event: MouseEvent) => void;
|
|
2104
2460
|
};
|
|
2105
2461
|
|
|
2462
|
+
export declare function useIsInsideFieldRoot(): boolean;
|
|
2463
|
+
|
|
2106
2464
|
export declare function useIsVisible<T extends HTMLElement>({ onVisible, root, rootMargin, threshold, }?: UseIsVisibleProps): UseIsVisibleReturn<T>;
|
|
2107
2465
|
|
|
2108
2466
|
declare interface UseIsVisibleProps extends IntersectionObserverInit {
|
|
@@ -2142,7 +2500,7 @@ export declare function useObject<T extends GenericObject_2>(): MaybeReturn<T>;
|
|
|
2142
2500
|
|
|
2143
2501
|
export declare function useObject<T extends GenericObject_2>(initialValue: T): Return<T>;
|
|
2144
2502
|
|
|
2145
|
-
export declare function usePagination({ totalItems, pageSize, initialCurrentPage, onChange, }: usePaginationProps): {
|
|
2503
|
+
export declare function usePagination({ totalItems, pageSize, currentPage: currentPageProp, defaultCurrentPage, onCurrentPageChange, initialCurrentPage, onChange, }: usePaginationProps): {
|
|
2146
2504
|
next: () => void;
|
|
2147
2505
|
prev: () => void;
|
|
2148
2506
|
goTo: (page: number) => void;
|
|
@@ -2166,17 +2524,28 @@ export declare type usePaginationProps = {
|
|
|
2166
2524
|
*/
|
|
2167
2525
|
pageSize: number;
|
|
2168
2526
|
/**
|
|
2169
|
-
*
|
|
2527
|
+
* Página controlada
|
|
2528
|
+
*/
|
|
2529
|
+
currentPage?: number;
|
|
2530
|
+
/**
|
|
2531
|
+
* Página inicial (uncontrolled)
|
|
2532
|
+
*/
|
|
2533
|
+
defaultCurrentPage?: number;
|
|
2534
|
+
/**
|
|
2535
|
+
* Callback cuando cambia la página
|
|
2536
|
+
*/
|
|
2537
|
+
onCurrentPageChange?: (page: number) => void;
|
|
2538
|
+
/**
|
|
2539
|
+
* @deprecated Usá `defaultCurrentPage`
|
|
2170
2540
|
*/
|
|
2171
2541
|
initialCurrentPage?: number;
|
|
2172
2542
|
/**
|
|
2173
|
-
*
|
|
2543
|
+
* @deprecated Usá `onCurrentPageChange`
|
|
2174
2544
|
*/
|
|
2175
2545
|
onChange?: (value: {
|
|
2176
2546
|
currentPage: number;
|
|
2177
2547
|
pageSize: number;
|
|
2178
2548
|
}) => void;
|
|
2179
|
-
siblingCount?: number;
|
|
2180
2549
|
};
|
|
2181
2550
|
|
|
2182
2551
|
export declare function usePortal(id: string): {
|
|
@@ -2223,6 +2592,10 @@ export declare function useSelection<T>(items: T[]): Return_2<T>;
|
|
|
2223
2592
|
|
|
2224
2593
|
export declare function useStep<T = ReactNode>(steps: T[], amountSteps?: number): Return_3<T>;
|
|
2225
2594
|
|
|
2595
|
+
export declare function useStepItem(): StepItemContextValue;
|
|
2596
|
+
|
|
2597
|
+
export declare function useStepper(): StepperContextValue;
|
|
2598
|
+
|
|
2226
2599
|
export declare const useTheme: () => {
|
|
2227
2600
|
theme: Theme;
|
|
2228
2601
|
};
|
|
@@ -2253,9 +2626,4 @@ export declare function useToggle(initialValue?: boolean): Return_4;
|
|
|
2253
2626
|
|
|
2254
2627
|
export declare type ValuesUnion<T extends Record<string, any>> = T[keyof T];
|
|
2255
2628
|
|
|
2256
|
-
declare type VariantProps_2 = {
|
|
2257
|
-
color?: never;
|
|
2258
|
-
variant?: TagVariant["variant"];
|
|
2259
|
-
};
|
|
2260
|
-
|
|
2261
2629
|
export { }
|