my-animated-components 1.5.4 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +401 -141
- package/dist/index.js +1266 -537
- package/package.json +13 -3
- package/readme.md +91 -38
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React$1, { ReactNode } from 'react';
|
|
2
|
-
import { Variants, HTMLMotionProps, Transition,
|
|
2
|
+
import { Variants, HTMLMotionProps, Transition, MotionProps } from 'framer-motion';
|
|
3
3
|
|
|
4
4
|
declare const motionVariants: Record<string, Variants>;
|
|
5
5
|
|
|
@@ -7,37 +7,54 @@ interface BaseProps {
|
|
|
7
7
|
className?: string;
|
|
8
8
|
}
|
|
9
9
|
interface WithChildren {
|
|
10
|
-
children
|
|
10
|
+
children?: React.ReactNode;
|
|
11
11
|
}
|
|
12
|
-
type Color$
|
|
13
|
-
type Size$
|
|
12
|
+
type Color$h = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info';
|
|
13
|
+
type Size$3 = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' | 'full';
|
|
14
|
+
type Radius = 'none' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' | 'full';
|
|
15
|
+
type Variant = 'solid' | 'outline' | 'ghost' | 'glass' | 'gradient' | 'flat' | 'elevated';
|
|
14
16
|
interface ColorProps {
|
|
15
|
-
color?: Color$
|
|
17
|
+
color?: Color$h;
|
|
16
18
|
}
|
|
17
19
|
interface SizeProps {
|
|
18
|
-
size?: Size$
|
|
20
|
+
size?: Size$3;
|
|
21
|
+
}
|
|
22
|
+
interface RadiusProps {
|
|
23
|
+
radius?: Radius;
|
|
24
|
+
}
|
|
25
|
+
interface VariantProps {
|
|
26
|
+
variant?: Variant;
|
|
19
27
|
}
|
|
20
28
|
|
|
21
|
-
type Color$
|
|
22
|
-
type ButtonVariant = 'solid' | 'outline' | 'ghost' | string;
|
|
23
|
-
type Size$
|
|
24
|
-
type MotionVariantKey$
|
|
25
|
-
interface ButtonProps extends BaseProps, SizeProps, HTMLMotionProps<'button'> {
|
|
29
|
+
type Color$g = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | string;
|
|
30
|
+
type ButtonVariant = 'solid' | 'outline' | 'ghost' | 'glass' | 'gradient' | string;
|
|
31
|
+
type Size$2 = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' | 'full' | string;
|
|
32
|
+
type MotionVariantKey$5 = keyof typeof motionVariants;
|
|
33
|
+
interface ButtonProps extends BaseProps, SizeProps, RadiusProps, Omit<HTMLMotionProps<'button'>, 'children'> {
|
|
34
|
+
/**
|
|
35
|
+
* Button content
|
|
36
|
+
*/
|
|
37
|
+
children?: React$1.ReactNode;
|
|
26
38
|
/**
|
|
27
39
|
* Visual style of the button
|
|
28
40
|
* @default 'solid'
|
|
29
41
|
*/
|
|
30
42
|
variant?: ButtonVariant;
|
|
43
|
+
/**
|
|
44
|
+
* Border radius
|
|
45
|
+
* @default 'xl'
|
|
46
|
+
*/
|
|
47
|
+
radius?: Radius;
|
|
31
48
|
/**
|
|
32
49
|
* Color theme of the button
|
|
33
50
|
* @default 'primary'
|
|
34
51
|
*/
|
|
35
|
-
color?: Color$
|
|
52
|
+
color?: Color$g;
|
|
36
53
|
/**
|
|
37
54
|
* Predefined motion variant from motionVariants for initial animation
|
|
38
55
|
* @default 'fadeIn'
|
|
39
56
|
*/
|
|
40
|
-
motionVariant?: MotionVariantKey$
|
|
57
|
+
motionVariant?: MotionVariantKey$5;
|
|
41
58
|
/**
|
|
42
59
|
* Custom animation variants to override default motionVariants
|
|
43
60
|
*/
|
|
@@ -45,15 +62,15 @@ interface ButtonProps extends BaseProps, SizeProps, HTMLMotionProps<'button'> {
|
|
|
45
62
|
/**
|
|
46
63
|
* Predefined motion variant for hover animation
|
|
47
64
|
*/
|
|
48
|
-
whileHoverAnimation?: MotionVariantKey$
|
|
65
|
+
whileHoverAnimation?: MotionVariantKey$5;
|
|
49
66
|
/**
|
|
50
67
|
* Predefined motion variant for tap animation
|
|
51
68
|
*/
|
|
52
|
-
whileTapAnimation?: MotionVariantKey$
|
|
69
|
+
whileTapAnimation?: MotionVariantKey$5;
|
|
53
70
|
/**
|
|
54
71
|
* Predefined motion variant for focus animation
|
|
55
72
|
*/
|
|
56
|
-
whileFocusAnimation?: MotionVariantKey$
|
|
73
|
+
whileFocusAnimation?: MotionVariantKey$5;
|
|
57
74
|
/**
|
|
58
75
|
* Custom transition for initial animation
|
|
59
76
|
*/
|
|
@@ -84,13 +101,13 @@ interface ButtonProps extends BaseProps, SizeProps, HTMLMotionProps<'button'> {
|
|
|
84
101
|
*/
|
|
85
102
|
customClasses?: {
|
|
86
103
|
[variant in ButtonVariant]?: {
|
|
87
|
-
[color in Color$
|
|
104
|
+
[color in Color$g]?: string;
|
|
88
105
|
};
|
|
89
106
|
};
|
|
90
107
|
/**
|
|
91
108
|
* Custom size class mapping
|
|
92
109
|
*/
|
|
93
|
-
customSizeClasses?: Record<Size$
|
|
110
|
+
customSizeClasses?: Record<Size$2, string>;
|
|
94
111
|
/**
|
|
95
112
|
* Whether to use animation on initial render
|
|
96
113
|
* @default true
|
|
@@ -110,37 +127,52 @@ interface ButtonProps extends BaseProps, SizeProps, HTMLMotionProps<'button'> {
|
|
|
110
127
|
* @default 'button'
|
|
111
128
|
*/
|
|
112
129
|
type?: 'button' | 'submit' | 'reset';
|
|
130
|
+
/**
|
|
131
|
+
* Show loading spinner and disable the button
|
|
132
|
+
* @default false
|
|
133
|
+
*/
|
|
134
|
+
loading?: boolean;
|
|
135
|
+
/**
|
|
136
|
+
* Icon to display before the button text
|
|
137
|
+
*/
|
|
138
|
+
leftIcon?: React$1.ReactNode;
|
|
139
|
+
/**
|
|
140
|
+
* Icon to display after the button text
|
|
141
|
+
*/
|
|
142
|
+
rightIcon?: React$1.ReactNode;
|
|
143
|
+
/**
|
|
144
|
+
* Make the button full width
|
|
145
|
+
* @default false
|
|
146
|
+
*/
|
|
147
|
+
fullWidth?: boolean;
|
|
113
148
|
}
|
|
114
149
|
declare const Button: React$1.FC<ButtonProps>;
|
|
115
150
|
|
|
116
|
-
type Color$
|
|
117
|
-
|
|
151
|
+
type Color$f = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | string;
|
|
152
|
+
type IconButtonVariant = 'solid' | 'outline' | 'ghost' | 'glass' | 'gradient' | string;
|
|
153
|
+
type MotionVariantKey$4 = keyof typeof motionVariants;
|
|
154
|
+
interface IconButtonProps extends BaseProps, SizeProps, RadiusProps, Omit<HTMLMotionProps<'button'>, 'children'> {
|
|
118
155
|
icon: React$1.ReactNode;
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
whileTap?: React$1.ComponentProps<typeof motion.button>['whileTap'];
|
|
126
|
-
whileFocus?: React$1.ComponentProps<typeof motion.button>['whileFocus'];
|
|
127
|
-
whileHoverAnimation?: keyof typeof motionVariants;
|
|
128
|
-
whileTapAnimation?: keyof typeof motionVariants;
|
|
129
|
-
whileFocusAnimation?: keyof typeof motionVariants;
|
|
156
|
+
variant?: IconButtonVariant;
|
|
157
|
+
color?: Color$f;
|
|
158
|
+
motionVariant?: MotionVariantKey$4;
|
|
159
|
+
whileHoverAnimation?: MotionVariantKey$4;
|
|
160
|
+
whileTapAnimation?: MotionVariantKey$4;
|
|
161
|
+
whileFocusAnimation?: MotionVariantKey$4;
|
|
130
162
|
}
|
|
131
163
|
declare const IconButton: React$1.FC<IconButtonProps>;
|
|
132
164
|
|
|
133
|
-
type Color$
|
|
134
|
-
type
|
|
165
|
+
type Color$e = 'primary' | 'secondary' | 'danger' | 'success' | 'info' | 'warning' | string;
|
|
166
|
+
type AccordionVariant = 'solid' | 'outline' | 'ghost' | 'glass' | 'elevated' | string;
|
|
135
167
|
interface AccordionItem {
|
|
136
168
|
title: string;
|
|
137
169
|
content: React$1.ReactNode;
|
|
138
170
|
disabled?: boolean;
|
|
139
171
|
}
|
|
140
|
-
interface AccordionProps extends BaseProps,
|
|
172
|
+
interface AccordionProps extends BaseProps, RadiusProps {
|
|
141
173
|
items: AccordionItem[];
|
|
142
|
-
color?: Color$
|
|
143
|
-
variant?:
|
|
174
|
+
color?: Color$e;
|
|
175
|
+
variant?: AccordionVariant;
|
|
144
176
|
motionVariant?: keyof typeof motionVariants;
|
|
145
177
|
allowMultipleOpen?: boolean;
|
|
146
178
|
defaultOpenIndex?: number[];
|
|
@@ -152,142 +184,336 @@ interface AccordionProps extends BaseProps, WithChildren {
|
|
|
152
184
|
}
|
|
153
185
|
declare const Accordion: React$1.FC<AccordionProps>;
|
|
154
186
|
|
|
155
|
-
|
|
187
|
+
type Color$d = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | string;
|
|
188
|
+
type AlertVariant = 'flat' | 'solid' | 'glass' | string;
|
|
189
|
+
interface AlertProps extends BaseProps, RadiusProps, Omit<HTMLMotionProps<"div">, "children"> {
|
|
190
|
+
children?: React$1.ReactNode;
|
|
156
191
|
onClose?: () => void;
|
|
157
192
|
motionVariant?: keyof typeof motionVariants;
|
|
193
|
+
color?: Color$d;
|
|
194
|
+
variant?: AlertVariant;
|
|
158
195
|
}
|
|
159
196
|
declare const Alert: React$1.FC<AlertProps>;
|
|
160
197
|
|
|
161
|
-
interface AvatarProps extends BaseProps, SizeProps, HTMLMotionProps<'div'> {
|
|
198
|
+
interface AvatarProps extends BaseProps, SizeProps, RadiusProps, Omit<HTMLMotionProps<'div'>, 'children'> {
|
|
162
199
|
src?: string;
|
|
163
200
|
alt?: string;
|
|
164
201
|
initials?: string;
|
|
202
|
+
fallbackIcon?: React$1.ReactNode;
|
|
165
203
|
}
|
|
166
204
|
declare const Avatar: React$1.FC<AvatarProps>;
|
|
167
205
|
|
|
168
|
-
|
|
206
|
+
type Color$c = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | string;
|
|
207
|
+
type Size$1 = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' | 'full' | string;
|
|
208
|
+
interface BadgeProps extends BaseProps, RadiusProps, VariantProps, Omit<HTMLMotionProps<"span">, "children"> {
|
|
209
|
+
children?: React$1.ReactNode;
|
|
169
210
|
motionVariant?: keyof typeof motionVariants;
|
|
211
|
+
color?: Color$c;
|
|
212
|
+
size?: Size$1;
|
|
170
213
|
}
|
|
171
214
|
declare const Badge: React$1.FC<BadgeProps>;
|
|
172
215
|
|
|
173
|
-
type Color$
|
|
174
|
-
interface BreadcrumbProps extends BaseProps {
|
|
216
|
+
type Color$b = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | string;
|
|
217
|
+
interface BreadcrumbProps extends BaseProps, Omit<HTMLMotionProps<"nav">, "children"> {
|
|
175
218
|
items: {
|
|
176
219
|
label: string;
|
|
177
220
|
href: string;
|
|
178
221
|
}[];
|
|
179
222
|
motionVariant?: keyof typeof motionVariants;
|
|
180
|
-
color?: Color$
|
|
223
|
+
color?: Color$b;
|
|
181
224
|
}
|
|
182
225
|
declare const Breadcrumb: React$1.FC<BreadcrumbProps>;
|
|
183
226
|
|
|
184
|
-
interface CardProps extends BaseProps,
|
|
227
|
+
interface CardProps extends BaseProps, RadiusProps, VariantProps, Omit<HTMLMotionProps<"div">, "children"> {
|
|
228
|
+
children?: React$1.ReactNode;
|
|
185
229
|
motionVariant?: keyof typeof motionVariants;
|
|
230
|
+
hoverable?: boolean;
|
|
186
231
|
}
|
|
187
232
|
declare const Card: React$1.FC<CardProps>;
|
|
188
233
|
|
|
189
|
-
interface CardBodyProps extends BaseProps,
|
|
234
|
+
interface CardBodyProps extends BaseProps, Omit<HTMLMotionProps<"div">, "children"> {
|
|
235
|
+
children?: React$1.ReactNode;
|
|
190
236
|
motionVariant?: keyof typeof motionVariants;
|
|
191
237
|
}
|
|
192
238
|
declare const CardBody: React$1.FC<CardBodyProps>;
|
|
193
239
|
|
|
194
|
-
interface CardFooterProps extends BaseProps,
|
|
240
|
+
interface CardFooterProps extends BaseProps, Omit<HTMLMotionProps<"div">, "children"> {
|
|
241
|
+
children?: React$1.ReactNode;
|
|
195
242
|
motionVariant?: keyof typeof motionVariants;
|
|
196
243
|
}
|
|
197
244
|
declare const CardFooter: React$1.FC<CardFooterProps>;
|
|
198
245
|
|
|
199
|
-
interface CardHeaderProps extends BaseProps,
|
|
246
|
+
interface CardHeaderProps extends BaseProps, Omit<HTMLMotionProps<"div">, "children"> {
|
|
247
|
+
children?: React$1.ReactNode;
|
|
200
248
|
motionVariant?: keyof typeof motionVariants;
|
|
201
249
|
}
|
|
202
250
|
declare const CardHeader: React$1.FC<CardHeaderProps>;
|
|
203
251
|
|
|
204
|
-
interface DropdownProps extends BaseProps,
|
|
252
|
+
interface DropdownProps extends BaseProps, RadiusProps {
|
|
253
|
+
/** The element that triggers the dropdown */
|
|
205
254
|
trigger: React$1.ReactNode;
|
|
255
|
+
/** Dropdown content */
|
|
256
|
+
children?: React$1.ReactNode;
|
|
257
|
+
/** Predefined motion variant name */
|
|
206
258
|
motionVariant?: keyof typeof motionVariants;
|
|
259
|
+
/** Callback when dropdown opens */
|
|
260
|
+
onOpen?: () => void;
|
|
261
|
+
/** Callback when dropdown closes */
|
|
262
|
+
onClose?: () => void;
|
|
263
|
+
/** Whether the dropdown is disabled */
|
|
264
|
+
disabled?: boolean;
|
|
207
265
|
}
|
|
208
266
|
declare const Dropdown: React$1.FC<DropdownProps>;
|
|
209
267
|
|
|
210
|
-
|
|
268
|
+
interface DropdownItemProps extends BaseProps, WithChildren {
|
|
269
|
+
/** Click handler */
|
|
270
|
+
onClick?: (e: React$1.MouseEvent) => void;
|
|
271
|
+
/** Link destination */
|
|
272
|
+
href?: string;
|
|
273
|
+
/** Whether the item is disabled */
|
|
274
|
+
disabled?: boolean;
|
|
275
|
+
/** Render as a different element */
|
|
276
|
+
as?: 'a' | 'button' | 'div';
|
|
277
|
+
}
|
|
278
|
+
declare const DropdownItem: React$1.FC<DropdownItemProps>;
|
|
211
279
|
|
|
212
280
|
type CheckboxColor = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info';
|
|
213
281
|
interface CheckboxProps extends BaseProps {
|
|
282
|
+
/** Label text */
|
|
214
283
|
label: string;
|
|
284
|
+
/** Whether the checkbox is checked */
|
|
215
285
|
checked?: boolean;
|
|
286
|
+
/** Default checked state for uncontrolled usage */
|
|
287
|
+
defaultChecked?: boolean;
|
|
288
|
+
/** Change handler */
|
|
216
289
|
onChange?: (e: React$1.ChangeEvent<HTMLInputElement>) => void;
|
|
290
|
+
/** Color theme */
|
|
217
291
|
color?: CheckboxColor;
|
|
292
|
+
/** Predefined motion variant */
|
|
218
293
|
motionVariant?: keyof typeof motionVariants;
|
|
294
|
+
/** Whether the checkbox is disabled */
|
|
295
|
+
disabled?: boolean;
|
|
296
|
+
/** Checkbox id */
|
|
297
|
+
id?: string;
|
|
298
|
+
/** Checkbox name */
|
|
299
|
+
name?: string;
|
|
300
|
+
/** Error state */
|
|
301
|
+
error?: boolean | string;
|
|
302
|
+
/** Helper text */
|
|
303
|
+
helperText?: string;
|
|
304
|
+
/** Whether to animate on mount */
|
|
305
|
+
useAnimation?: boolean;
|
|
219
306
|
}
|
|
220
|
-
declare const Checkbox: React$1.
|
|
307
|
+
declare const Checkbox: React$1.ForwardRefExoticComponent<CheckboxProps & React$1.RefAttributes<HTMLInputElement>>;
|
|
221
308
|
|
|
222
309
|
type ButtonColor = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info';
|
|
223
310
|
interface FileUploadProps extends BaseProps {
|
|
311
|
+
/** File change handler */
|
|
224
312
|
onChange: (file: File | null) => void;
|
|
313
|
+
/** Multiple files change handler */
|
|
314
|
+
onMultipleChange?: (files: FileList | null) => void;
|
|
315
|
+
/** Accepted file types */
|
|
225
316
|
accept?: string;
|
|
317
|
+
/** Allow multiple files */
|
|
226
318
|
multiple?: boolean;
|
|
319
|
+
/** Button color theme */
|
|
227
320
|
buttonColor?: ButtonColor;
|
|
321
|
+
/** Predefined motion variant */
|
|
228
322
|
motionVariant?: keyof typeof motionVariants;
|
|
323
|
+
/** Custom button text */
|
|
324
|
+
buttonText?: string;
|
|
325
|
+
/** Whether the upload is disabled */
|
|
326
|
+
disabled?: boolean;
|
|
327
|
+
/** Whether to animate on mount */
|
|
328
|
+
useAnimation?: boolean;
|
|
329
|
+
/** Max file size in bytes */
|
|
330
|
+
maxSize?: number;
|
|
331
|
+
/** Error callback when file exceeds max size */
|
|
332
|
+
onError?: (error: string) => void;
|
|
229
333
|
}
|
|
230
334
|
declare const FileUpload: React$1.FC<FileUploadProps>;
|
|
231
335
|
|
|
232
336
|
type InputColor = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info';
|
|
233
337
|
type TextColor = 'black' | 'gray' | 'white' | 'blue' | 'green' | 'red';
|
|
234
|
-
interface InputProps extends BaseProps, SizeProps {
|
|
235
|
-
|
|
338
|
+
interface InputProps extends BaseProps, SizeProps, RadiusProps {
|
|
339
|
+
/** Input type */
|
|
340
|
+
type?: 'text' | 'password' | 'email' | 'number' | 'tel' | 'url' | 'search';
|
|
341
|
+
/** Placeholder text */
|
|
236
342
|
placeholder?: string;
|
|
343
|
+
/** Current value */
|
|
237
344
|
value?: string;
|
|
345
|
+
/** Default value for uncontrolled usage */
|
|
346
|
+
defaultValue?: string;
|
|
347
|
+
/** Change handler */
|
|
238
348
|
onChange?: (e: React$1.ChangeEvent<HTMLInputElement>) => void;
|
|
349
|
+
/** Color theme */
|
|
239
350
|
color?: InputColor;
|
|
351
|
+
/** Text color */
|
|
240
352
|
textColor?: TextColor;
|
|
353
|
+
/** Predefined motion variant */
|
|
354
|
+
motionVariant?: keyof typeof motionVariants;
|
|
355
|
+
/** Label text */
|
|
356
|
+
label?: string;
|
|
357
|
+
/** Error state - shows red border and error text */
|
|
358
|
+
error?: boolean | string;
|
|
359
|
+
/** Helper text below the input */
|
|
360
|
+
helperText?: string;
|
|
361
|
+
/** Whether the input is disabled */
|
|
362
|
+
disabled?: boolean;
|
|
363
|
+
/** Whether the input is required */
|
|
364
|
+
required?: boolean;
|
|
365
|
+
/** Whether the input is read-only */
|
|
366
|
+
readOnly?: boolean;
|
|
367
|
+
/** Input id */
|
|
368
|
+
id?: string;
|
|
369
|
+
/** Input name */
|
|
370
|
+
name?: string;
|
|
371
|
+
/** Whether to animate on mount */
|
|
372
|
+
useAnimation?: boolean;
|
|
241
373
|
}
|
|
242
|
-
declare const Input: React$1.
|
|
374
|
+
declare const Input: React$1.ForwardRefExoticComponent<InputProps & React$1.RefAttributes<HTMLInputElement>>;
|
|
243
375
|
|
|
244
|
-
type Color$
|
|
376
|
+
type Color$a = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info';
|
|
245
377
|
interface RadioProps extends BaseProps, SizeProps {
|
|
378
|
+
/** Label text */
|
|
246
379
|
label: string;
|
|
380
|
+
/** Radio group name */
|
|
247
381
|
name: string;
|
|
382
|
+
/** Radio value */
|
|
248
383
|
value: string;
|
|
384
|
+
/** Whether the radio is checked */
|
|
249
385
|
checked?: boolean;
|
|
386
|
+
/** Default checked state for uncontrolled usage */
|
|
387
|
+
defaultChecked?: boolean;
|
|
388
|
+
/** Change handler */
|
|
250
389
|
onChange?: (e: React$1.ChangeEvent<HTMLInputElement>) => void;
|
|
251
|
-
|
|
390
|
+
/** Color theme */
|
|
391
|
+
color?: Color$a;
|
|
392
|
+
/** Predefined motion variant */
|
|
252
393
|
motionVariant?: keyof typeof motionVariants;
|
|
394
|
+
/** Whether the radio is disabled */
|
|
395
|
+
disabled?: boolean;
|
|
396
|
+
/** Radio id */
|
|
397
|
+
id?: string;
|
|
398
|
+
/** Error state */
|
|
399
|
+
error?: boolean | string;
|
|
400
|
+
/** Helper text */
|
|
401
|
+
helperText?: string;
|
|
402
|
+
/** Whether to animate on mount */
|
|
403
|
+
useAnimation?: boolean;
|
|
253
404
|
}
|
|
254
|
-
declare const Radio: React$1.
|
|
405
|
+
declare const Radio: React$1.ForwardRefExoticComponent<RadioProps & React$1.RefAttributes<HTMLInputElement>>;
|
|
255
406
|
|
|
256
|
-
type Color$
|
|
257
|
-
interface
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
407
|
+
type Color$9 = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info';
|
|
408
|
+
interface SelectOption {
|
|
409
|
+
value: string;
|
|
410
|
+
label: string;
|
|
411
|
+
disabled?: boolean;
|
|
412
|
+
}
|
|
413
|
+
interface SelectProps extends BaseProps, SizeProps, RadiusProps {
|
|
414
|
+
/** Options to display */
|
|
415
|
+
options: SelectOption[];
|
|
416
|
+
/** Current value */
|
|
262
417
|
value?: string;
|
|
418
|
+
/** Default value for uncontrolled usage */
|
|
419
|
+
defaultValue?: string;
|
|
420
|
+
/** Change handler */
|
|
263
421
|
onChange?: (e: React$1.ChangeEvent<HTMLSelectElement>) => void;
|
|
264
|
-
|
|
422
|
+
/** Color theme */
|
|
423
|
+
color?: Color$9;
|
|
424
|
+
/** Predefined motion variant */
|
|
265
425
|
motionVariant?: keyof typeof motionVariants;
|
|
426
|
+
/** Label text */
|
|
427
|
+
label?: string;
|
|
428
|
+
/** Placeholder option text */
|
|
429
|
+
placeholder?: string;
|
|
430
|
+
/** Error state */
|
|
431
|
+
error?: boolean | string;
|
|
432
|
+
/** Helper text below the select */
|
|
433
|
+
helperText?: string;
|
|
434
|
+
/** Whether the select is disabled */
|
|
435
|
+
disabled?: boolean;
|
|
436
|
+
/** Whether the select is required */
|
|
437
|
+
required?: boolean;
|
|
438
|
+
/** Select id */
|
|
439
|
+
id?: string;
|
|
440
|
+
/** Select name */
|
|
441
|
+
name?: string;
|
|
442
|
+
/** Whether to animate on mount */
|
|
443
|
+
useAnimation?: boolean;
|
|
266
444
|
}
|
|
267
|
-
declare const Select: React$1.
|
|
445
|
+
declare const Select: React$1.ForwardRefExoticComponent<SelectProps & React$1.RefAttributes<HTMLSelectElement>>;
|
|
268
446
|
|
|
269
|
-
type Color$
|
|
447
|
+
type Color$8 = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info';
|
|
270
448
|
interface SwitchProps extends BaseProps {
|
|
449
|
+
/** Whether the switch is on */
|
|
271
450
|
checked: boolean;
|
|
451
|
+
/** Change handler */
|
|
272
452
|
onChange: (checked: boolean) => void;
|
|
453
|
+
/** Label text */
|
|
273
454
|
label?: string;
|
|
274
|
-
|
|
455
|
+
/** Color theme */
|
|
456
|
+
color?: Color$8;
|
|
457
|
+
/** Predefined motion variant */
|
|
275
458
|
motionVariant?: keyof typeof motionVariants;
|
|
459
|
+
/** Whether the switch is disabled */
|
|
460
|
+
disabled?: boolean;
|
|
461
|
+
/** Switch id */
|
|
462
|
+
id?: string;
|
|
463
|
+
/** Switch name */
|
|
464
|
+
name?: string;
|
|
465
|
+
/** Size of the switch */
|
|
466
|
+
size?: 'sm' | 'md' | 'lg';
|
|
467
|
+
/** Whether to animate on mount */
|
|
468
|
+
useAnimation?: boolean;
|
|
276
469
|
}
|
|
277
470
|
declare const Switch: React$1.FC<SwitchProps>;
|
|
278
471
|
|
|
279
|
-
type Color$
|
|
280
|
-
interface TextareaProps extends BaseProps, SizeProps {
|
|
472
|
+
type Color$7 = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info';
|
|
473
|
+
interface TextareaProps extends BaseProps, SizeProps, RadiusProps {
|
|
474
|
+
/** Placeholder text */
|
|
281
475
|
placeholder?: string;
|
|
476
|
+
/** Current value */
|
|
282
477
|
value?: string;
|
|
478
|
+
/** Default value for uncontrolled usage */
|
|
479
|
+
defaultValue?: string;
|
|
480
|
+
/** Change handler */
|
|
283
481
|
onChange?: (e: React$1.ChangeEvent<HTMLTextAreaElement>) => void;
|
|
482
|
+
/** Number of rows */
|
|
284
483
|
rows?: number;
|
|
285
|
-
|
|
484
|
+
/** Color theme */
|
|
485
|
+
color?: Color$7;
|
|
486
|
+
/** Predefined motion variant */
|
|
286
487
|
motionVariant?: keyof typeof motionVariants;
|
|
488
|
+
/** Label text */
|
|
489
|
+
label?: string;
|
|
490
|
+
/** Error state */
|
|
491
|
+
error?: boolean | string;
|
|
492
|
+
/** Helper text below the textarea */
|
|
493
|
+
helperText?: string;
|
|
494
|
+
/** Whether the textarea is disabled */
|
|
495
|
+
disabled?: boolean;
|
|
496
|
+
/** Whether the textarea is required */
|
|
497
|
+
required?: boolean;
|
|
498
|
+
/** Whether the textarea is read-only */
|
|
499
|
+
readOnly?: boolean;
|
|
500
|
+
/** Textarea id */
|
|
501
|
+
id?: string;
|
|
502
|
+
/** Textarea name */
|
|
503
|
+
name?: string;
|
|
504
|
+
/** Whether to animate on mount */
|
|
505
|
+
useAnimation?: boolean;
|
|
506
|
+
/** Allow resize */
|
|
507
|
+
resize?: 'none' | 'vertical' | 'horizontal' | 'both';
|
|
508
|
+
/** Max length */
|
|
509
|
+
maxLength?: number;
|
|
510
|
+
/** Show character count */
|
|
511
|
+
showCharCount?: boolean;
|
|
287
512
|
}
|
|
288
|
-
declare const Textarea: React$1.
|
|
513
|
+
declare const Textarea: React$1.ForwardRefExoticComponent<TextareaProps & React$1.RefAttributes<HTMLTextAreaElement>>;
|
|
289
514
|
|
|
290
|
-
interface ContainerProps extends BaseProps,
|
|
515
|
+
interface ContainerProps extends BaseProps, Omit<HTMLMotionProps<"div">, "children"> {
|
|
516
|
+
children?: React$1.ReactNode;
|
|
291
517
|
fluid?: boolean;
|
|
292
518
|
motionVariant?: keyof typeof motionVariants;
|
|
293
519
|
duration?: number;
|
|
@@ -295,7 +521,8 @@ interface ContainerProps extends BaseProps, WithChildren {
|
|
|
295
521
|
}
|
|
296
522
|
declare const Container: React$1.FC<ContainerProps>;
|
|
297
523
|
|
|
298
|
-
interface FlexProps extends BaseProps,
|
|
524
|
+
interface FlexProps extends BaseProps, Omit<HTMLMotionProps<"div">, "children" | "direction"> {
|
|
525
|
+
children?: React$1.ReactNode;
|
|
299
526
|
direction?: 'row' | 'col';
|
|
300
527
|
justify?: 'start' | 'center' | 'end' | 'between' | 'around';
|
|
301
528
|
align?: 'start' | 'center' | 'end' | 'stretch';
|
|
@@ -306,37 +533,49 @@ interface FlexProps extends BaseProps, WithChildren {
|
|
|
306
533
|
}
|
|
307
534
|
declare const Flex: React$1.FC<FlexProps>;
|
|
308
535
|
|
|
309
|
-
interface GridProps extends BaseProps,
|
|
310
|
-
|
|
311
|
-
|
|
536
|
+
interface GridProps extends BaseProps, Omit<HTMLMotionProps<"div">, "children"> {
|
|
537
|
+
children?: React$1.ReactNode;
|
|
538
|
+
cols?: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
|
|
539
|
+
gap?: number | string;
|
|
312
540
|
motionVariant?: keyof typeof motionVariants;
|
|
313
541
|
duration?: number;
|
|
314
542
|
loop?: boolean;
|
|
315
543
|
}
|
|
316
544
|
declare const Grid: React$1.FC<GridProps>;
|
|
317
545
|
|
|
318
|
-
|
|
546
|
+
type ListVariant = 'flat' | 'elevated' | 'glass' | 'ghost' | string;
|
|
547
|
+
interface ListProps extends BaseProps, RadiusProps, Omit<HTMLMotionProps<"ul">, "children" | "variant"> {
|
|
548
|
+
children?: React$1.ReactNode;
|
|
319
549
|
as?: 'ul' | 'ol';
|
|
320
550
|
motionVariant?: keyof typeof motionVariants;
|
|
321
|
-
|
|
322
|
-
loop?: boolean;
|
|
551
|
+
variant?: ListVariant;
|
|
323
552
|
}
|
|
324
553
|
declare const List: React$1.FC<ListProps>;
|
|
325
554
|
|
|
326
555
|
type MotionVariantKey$3 = keyof typeof motionVariants;
|
|
327
|
-
interface ListItemProps extends BaseProps,
|
|
556
|
+
interface ListItemProps extends BaseProps, Omit<HTMLMotionProps<"li">, "children"> {
|
|
557
|
+
children?: React$1.ReactNode;
|
|
328
558
|
motionVariant?: MotionVariantKey$3;
|
|
329
|
-
duration?: number;
|
|
330
|
-
loop?: boolean;
|
|
331
559
|
}
|
|
332
560
|
declare const ListItem: React$1.FC<ListItemProps>;
|
|
333
561
|
|
|
334
|
-
interface ModalProps extends BaseProps,
|
|
562
|
+
interface ModalProps extends BaseProps, RadiusProps, Omit<HTMLMotionProps<"div">, "children"> {
|
|
563
|
+
/** Controls visibility of the modal */
|
|
335
564
|
isOpen: boolean;
|
|
565
|
+
/** Callback when modal should close */
|
|
336
566
|
onClose: () => void;
|
|
567
|
+
/** Modal content */
|
|
568
|
+
children?: React$1.ReactNode;
|
|
569
|
+
/** Predefined motion variant name */
|
|
337
570
|
motionVariant?: keyof typeof motionVariants;
|
|
571
|
+
/** Animation duration in seconds */
|
|
338
572
|
duration?: number;
|
|
573
|
+
/** Loop the animation */
|
|
339
574
|
loop?: boolean;
|
|
575
|
+
/** Close modal on Escape key */
|
|
576
|
+
closeOnEscape?: boolean;
|
|
577
|
+
/** Close modal on overlay click */
|
|
578
|
+
closeOnOverlayClick?: boolean;
|
|
340
579
|
}
|
|
341
580
|
declare const Modal: React$1.FC<ModalProps>;
|
|
342
581
|
|
|
@@ -346,12 +585,8 @@ declare const ModalFooter: React$1.FC<BaseProps & WithChildren>;
|
|
|
346
585
|
|
|
347
586
|
declare const ModalHeader: React$1.FC<BaseProps & WithChildren>;
|
|
348
587
|
|
|
349
|
-
/**
|
|
350
|
-
* A fully customizable navigation link with motion and style props.
|
|
351
|
-
*/
|
|
352
588
|
type MotionVariantKey$2 = keyof typeof motionVariants;
|
|
353
|
-
interface NavItemProps extends BaseProps,
|
|
354
|
-
/** Link destination */
|
|
589
|
+
interface NavItemProps extends BaseProps, RadiusProps, Omit<HTMLMotionProps<"a">, "children" | "href" | "className"> {
|
|
355
590
|
href: string;
|
|
356
591
|
/** Whether this item is active */
|
|
357
592
|
active?: boolean;
|
|
@@ -359,11 +594,8 @@ interface NavItemProps extends BaseProps, WithChildren {
|
|
|
359
594
|
size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
360
595
|
/** Customize size classes */
|
|
361
596
|
sizeClasses?: Partial<Record<'xs' | 'sm' | 'md' | 'lg' | 'xl', string>>;
|
|
362
|
-
/** Motion variant key */
|
|
363
597
|
motionVariant?: MotionVariantKey$2;
|
|
364
|
-
/** Animation duration override (seconds) */
|
|
365
598
|
duration?: number;
|
|
366
|
-
/** Loop the animation */
|
|
367
599
|
loop?: boolean;
|
|
368
600
|
/** Text color classes when inactive */
|
|
369
601
|
textColorClass?: string;
|
|
@@ -371,38 +603,29 @@ interface NavItemProps extends BaseProps, WithChildren {
|
|
|
371
603
|
hoverTextColorClass?: string;
|
|
372
604
|
/** Text color classes when active */
|
|
373
605
|
activeTextColorClass?: string;
|
|
374
|
-
/** Border classes when active */
|
|
375
|
-
activeBorderClass?: string;
|
|
376
606
|
/** Scale on hover */
|
|
377
607
|
hoverScale?: number;
|
|
378
608
|
/** Scale on tap */
|
|
379
609
|
tapScale?: number;
|
|
610
|
+
/** Custom children rendering */
|
|
611
|
+
children?: React$1.ReactNode;
|
|
380
612
|
}
|
|
381
613
|
declare const NavItem: React$1.FC<NavItemProps>;
|
|
382
614
|
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
* All styling and behavior can be overridden via props.
|
|
386
|
-
*/
|
|
387
|
-
interface NavbarProps extends BaseProps, WithChildren {
|
|
615
|
+
type NavbarVariant = 'flat' | 'solid' | 'glass' | 'elevated' | string;
|
|
616
|
+
interface NavbarProps extends BaseProps, RadiusProps, Omit<HTMLMotionProps<"nav">, "children" | "className" | "variant"> {
|
|
388
617
|
/** Brand/logo element */
|
|
389
618
|
brand?: React$1.ReactNode;
|
|
390
|
-
/**
|
|
391
|
-
|
|
392
|
-
/**
|
|
393
|
-
|
|
394
|
-
/** Tailwind class for hover state on menu items */
|
|
395
|
-
hoverTextColorClass?: string;
|
|
396
|
-
/** Tailwind class for navbar shadow */
|
|
397
|
-
shadowClass?: string;
|
|
619
|
+
/** Variant of the navbar */
|
|
620
|
+
variant?: NavbarVariant;
|
|
621
|
+
/** Whether the navbar should stick to the top */
|
|
622
|
+
sticky?: boolean;
|
|
398
623
|
/** Container max-width wrapper class */
|
|
399
624
|
containerClassName?: string;
|
|
400
625
|
/** Class for desktop menu wrapper */
|
|
401
626
|
desktopMenuClassName?: string;
|
|
402
627
|
/** Class for mobile menu wrapper */
|
|
403
628
|
mobileMenuWrapperClassName?: string;
|
|
404
|
-
/** Class for individual mobile menu item */
|
|
405
|
-
mobileMenuItemClassName?: string;
|
|
406
629
|
/** Custom hamburger icon */
|
|
407
630
|
menuIcon?: React$1.ReactNode;
|
|
408
631
|
/** Custom close icon */
|
|
@@ -411,15 +634,15 @@ interface NavbarProps extends BaseProps, WithChildren {
|
|
|
411
634
|
navMotion?: Partial<MotionProps>;
|
|
412
635
|
/** Framer Motion props for mobile menu */
|
|
413
636
|
mobileMotion?: Partial<MotionProps>;
|
|
414
|
-
|
|
415
|
-
|
|
637
|
+
/** Optional children */
|
|
638
|
+
children?: React$1.ReactNode;
|
|
416
639
|
}
|
|
417
640
|
declare const Navbar: React$1.FC<NavbarProps>;
|
|
418
641
|
|
|
419
642
|
/**
|
|
420
643
|
* A fully customizable offcanvas panel component.
|
|
421
644
|
*/
|
|
422
|
-
interface OffcanvasProps extends BaseProps,
|
|
645
|
+
interface OffcanvasProps extends BaseProps, RadiusProps, Omit<React$1.HTMLAttributes<HTMLDivElement>, "children" | "className"> {
|
|
423
646
|
/** Controls visibility of the panel */
|
|
424
647
|
isOpen: boolean;
|
|
425
648
|
/** Callback when panel should close */
|
|
@@ -438,15 +661,10 @@ interface OffcanvasProps extends BaseProps, WithChildren {
|
|
|
438
661
|
zIndex?: string;
|
|
439
662
|
/** If true, clicking the overlay closes the panel */
|
|
440
663
|
closeOnOverlayClick?: boolean;
|
|
441
|
-
/** Duration of open/close animations in seconds */
|
|
442
|
-
duration?: number;
|
|
443
664
|
/** Custom close icon placed inside the panel */
|
|
444
665
|
customCloseIcon?: ReactNode;
|
|
445
|
-
/**
|
|
446
|
-
|
|
447
|
-
/** Override motion props on the panel */
|
|
448
|
-
panelMotion?: Partial<MotionProps>;
|
|
449
|
-
loop?: boolean;
|
|
666
|
+
/** Optional children rendering */
|
|
667
|
+
children?: ReactNode;
|
|
450
668
|
}
|
|
451
669
|
declare const Offcanvas: React$1.FC<OffcanvasProps>;
|
|
452
670
|
|
|
@@ -457,25 +675,30 @@ interface OffcanvasHeaderProps extends BaseProps, WithChildren {
|
|
|
457
675
|
}
|
|
458
676
|
declare const OffcanvasHeader: React$1.FC<OffcanvasHeaderProps>;
|
|
459
677
|
|
|
460
|
-
type Color$
|
|
461
|
-
|
|
678
|
+
type Color$6 = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | string;
|
|
679
|
+
type PaginationVariant = 'flat' | 'solid' | 'glass' | string;
|
|
680
|
+
interface PaginationProps extends BaseProps, RadiusProps, Omit<HTMLMotionProps<"nav">, "children" | "color" | "className" | "variant"> {
|
|
462
681
|
currentPage: number;
|
|
463
682
|
totalPages: number;
|
|
464
683
|
onPageChange: (page: number) => void;
|
|
465
|
-
color?: Color$
|
|
684
|
+
color?: Color$6;
|
|
685
|
+
variant?: PaginationVariant;
|
|
466
686
|
motionVariant?: keyof typeof motionVariants;
|
|
467
687
|
}
|
|
468
688
|
declare const Pagination: React$1.FC<PaginationProps>;
|
|
469
689
|
|
|
470
690
|
type MotionVariantKey$1 = keyof typeof motionVariants;
|
|
471
|
-
type Color$
|
|
472
|
-
|
|
691
|
+
type Color$5 = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | string;
|
|
692
|
+
type ProgressVariant = 'flat' | 'glow' | 'gradient' | string;
|
|
693
|
+
interface ProgressBarProps extends BaseProps, RadiusProps, Omit<HTMLMotionProps<"div">, "children" | "variant"> {
|
|
473
694
|
/** Current value */
|
|
474
695
|
value: number;
|
|
475
696
|
/** Maximum value */
|
|
476
697
|
max?: number;
|
|
477
698
|
/** Semantic color key */
|
|
478
|
-
color?: Color$
|
|
699
|
+
color?: Color$5;
|
|
700
|
+
/** Variant style */
|
|
701
|
+
variant?: ProgressVariant;
|
|
479
702
|
/** Override height utility class */
|
|
480
703
|
heightClass?: string;
|
|
481
704
|
/** Container background class */
|
|
@@ -495,22 +718,27 @@ interface ProgressBarProps extends BaseProps, ColorProps, MotionProps {
|
|
|
495
718
|
}
|
|
496
719
|
declare const ProgressBar: React$1.FC<ProgressBarProps>;
|
|
497
720
|
|
|
498
|
-
type Color$
|
|
499
|
-
|
|
721
|
+
type Color$4 = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | 'default' | string;
|
|
722
|
+
type SkeletonVariant = 'pulse' | 'shimmer' | string;
|
|
723
|
+
interface SkeletonProps extends BaseProps, RadiusProps, Omit<HTMLMotionProps<"div">, "children" | "variant"> {
|
|
500
724
|
width?: string;
|
|
501
725
|
height?: string;
|
|
502
|
-
color?: Color$
|
|
726
|
+
color?: Color$4;
|
|
727
|
+
variant?: SkeletonVariant;
|
|
503
728
|
motionVariant?: keyof typeof motionVariants;
|
|
504
729
|
}
|
|
505
730
|
declare const Skeleton: React$1.FC<SkeletonProps>;
|
|
506
731
|
|
|
507
|
-
|
|
732
|
+
type Color$3 = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | string;
|
|
733
|
+
type SliderVariant = 'flat' | 'glow' | string;
|
|
734
|
+
interface SliderProps extends BaseProps, RadiusProps, Omit<HTMLMotionProps<"div">, "children" | "onChange" | "color" | "variant"> {
|
|
508
735
|
min: number;
|
|
509
736
|
max: number;
|
|
510
737
|
value: number;
|
|
511
738
|
onChange: (value: number) => void;
|
|
512
739
|
step?: number;
|
|
513
|
-
color?:
|
|
740
|
+
color?: Color$3;
|
|
741
|
+
variant?: SliderVariant;
|
|
514
742
|
motionVariant?: keyof typeof motionVariants;
|
|
515
743
|
}
|
|
516
744
|
declare const Slider: React$1.FC<SliderProps>;
|
|
@@ -540,48 +768,82 @@ interface StepperProps extends BaseProps {
|
|
|
540
768
|
}
|
|
541
769
|
declare const Stepper: React$1.FC<StepperProps>;
|
|
542
770
|
|
|
543
|
-
type Color$1 = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info';
|
|
544
|
-
|
|
771
|
+
type Color$1 = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | string;
|
|
772
|
+
type TableVariant = 'flat' | 'elevated' | 'glass' | string;
|
|
773
|
+
interface TableProps extends BaseProps, SizeProps, RadiusProps, Omit<HTMLMotionProps<"div">, "children" | "color" | "variant"> {
|
|
774
|
+
children?: React$1.ReactNode;
|
|
775
|
+
/** Predefined motion variant */
|
|
545
776
|
motionVariant?: keyof typeof motionVariants;
|
|
777
|
+
/** Color theme */
|
|
546
778
|
color?: Color$1;
|
|
779
|
+
/** Visual variant */
|
|
780
|
+
variant?: TableVariant;
|
|
781
|
+
/** Striped rows */
|
|
782
|
+
striped?: boolean;
|
|
783
|
+
/** Hoverable rows */
|
|
784
|
+
hoverable?: boolean;
|
|
785
|
+
/** Show borders */
|
|
786
|
+
bordered?: boolean;
|
|
787
|
+
/** Whether to animate on mount */
|
|
788
|
+
useAnimation?: boolean;
|
|
547
789
|
}
|
|
548
790
|
declare const Table: React$1.FC<TableProps>;
|
|
549
791
|
|
|
550
792
|
declare const TableBody: React$1.FC<BaseProps & WithChildren>;
|
|
551
793
|
|
|
552
|
-
interface TableCellProps extends BaseProps,
|
|
794
|
+
interface TableCellProps extends BaseProps, React$1.TdHTMLAttributes<HTMLTableCellElement> {
|
|
553
795
|
as?: 'td' | 'th';
|
|
796
|
+
children?: React$1.ReactNode;
|
|
554
797
|
}
|
|
555
798
|
declare const TableCell: React$1.FC<TableCellProps>;
|
|
556
799
|
|
|
557
800
|
declare const TableHead: React$1.FC<BaseProps & WithChildren>;
|
|
558
801
|
|
|
559
|
-
|
|
802
|
+
interface TableRowProps extends BaseProps, Omit<HTMLMotionProps<"tr">, "children"> {
|
|
803
|
+
children?: React$1.ReactNode;
|
|
804
|
+
motionVariant?: keyof typeof motionVariants;
|
|
805
|
+
isHeader?: boolean;
|
|
806
|
+
}
|
|
807
|
+
declare const TableRow: React$1.FC<TableRowProps>;
|
|
560
808
|
|
|
561
|
-
type Color = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info';
|
|
562
|
-
type
|
|
809
|
+
type Color = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | string;
|
|
810
|
+
type TabsVariant = 'underlined' | 'pills' | 'solid' | string;
|
|
563
811
|
interface TabItem {
|
|
564
812
|
label: string;
|
|
565
813
|
content: React$1.ReactNode;
|
|
566
814
|
disabled?: boolean;
|
|
567
815
|
}
|
|
568
|
-
interface TabsProps extends BaseProps,
|
|
816
|
+
interface TabsProps extends BaseProps, RadiusProps {
|
|
817
|
+
/** Array of tab items */
|
|
569
818
|
tabs: TabItem[];
|
|
570
819
|
motionVariant?: keyof typeof motionVariants;
|
|
571
820
|
color?: Color;
|
|
572
|
-
variant?:
|
|
821
|
+
variant?: TabsVariant;
|
|
573
822
|
fullWidth?: boolean;
|
|
574
823
|
tabClassName?: string;
|
|
575
824
|
panelClassName?: string;
|
|
576
825
|
}
|
|
577
826
|
declare const Tabs: React$1.FC<TabsProps>;
|
|
578
827
|
|
|
579
|
-
type TooltipColor = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info';
|
|
580
|
-
|
|
581
|
-
|
|
828
|
+
type TooltipColor = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | string;
|
|
829
|
+
type TooltipVariant = 'flat' | 'solid' | 'glass' | string;
|
|
830
|
+
interface TooltipProps extends BaseProps, RadiusProps, Omit<HTMLMotionProps<"div">, "children" | "content" | "color" | "className" | "variant"> {
|
|
831
|
+
/** The element the tooltip wraps */
|
|
832
|
+
children: React$1.ReactNode;
|
|
833
|
+
/** Tooltip content text */
|
|
834
|
+
content: string | React$1.ReactNode;
|
|
835
|
+
/** Position of the tooltip */
|
|
582
836
|
position?: 'top' | 'right' | 'bottom' | 'left';
|
|
837
|
+
/** Color theme */
|
|
583
838
|
color?: TooltipColor;
|
|
839
|
+
/** Visual Variant */
|
|
840
|
+
variant?: TooltipVariant;
|
|
841
|
+
/** Predefined motion variant */
|
|
584
842
|
motionVariant?: keyof typeof motionVariants;
|
|
843
|
+
/** Delay before showing tooltip (ms) */
|
|
844
|
+
delay?: number;
|
|
845
|
+
/** Whether the tooltip is disabled */
|
|
846
|
+
disabled?: boolean;
|
|
585
847
|
}
|
|
586
848
|
declare const Tooltip: React$1.FC<TooltipProps>;
|
|
587
849
|
|
|
@@ -662,8 +924,6 @@ interface CarouselProps extends BaseProps {
|
|
|
662
924
|
initialSlide?: number;
|
|
663
925
|
baseClassName?: string;
|
|
664
926
|
unstyled?: boolean;
|
|
665
|
-
lazyLoad?: boolean;
|
|
666
|
-
preloadImages?: number;
|
|
667
927
|
customIcons?: CustomIcons;
|
|
668
928
|
thumbnailSize?: 'sm' | 'md' | 'lg';
|
|
669
929
|
arrowPosition?: 'inside' | 'outside';
|
|
@@ -676,4 +936,4 @@ interface CarouselProps extends BaseProps {
|
|
|
676
936
|
}
|
|
677
937
|
declare const Carousel: React$1.FC<CarouselProps>;
|
|
678
938
|
|
|
679
|
-
export { Accordion, Alert, Avatar, Badge, Breadcrumb, Button, Card, CardBody, CardFooter, CardHeader, Carousel, Checkbox, Container, Dropdown, DropdownItem, FileUpload, Flex, Grid, Heading, IconButton, ImageEditor, Imageeditor, Input, List, ListItem, Modal, ModalBody, ModalFooter, ModalHeader, NavItem, Navbar, Offcanvas, OffcanvasBody, OffcanvasHeader, Pagination, ProgressBar, Radio, RangeSlider, Select, Skeleton, Slider, Stepper, Switch, Table, TableBody, TableCell, TableHead, TableRow, Tabs, Text, Textarea, Tooltip, motionVariants };
|
|
939
|
+
export { Accordion, Alert, Avatar, Badge, type BaseProps, Breadcrumb, Button, type ButtonProps, Card, CardBody, CardFooter, CardHeader, Carousel, type CarouselImage, type CarouselProps, Checkbox, type CheckboxProps, type Color$h as Color, type ColorProps, Container, Dropdown, DropdownItem, type DropdownItemProps, type DropdownProps, FileUpload, type FileUploadProps, Flex, Grid, Heading, IconButton, ImageEditor, Imageeditor, Input, type InputProps, List, ListItem, Modal, ModalBody, ModalFooter, ModalHeader, type ModalProps, NavItem, type NavItemProps, Navbar, type NavbarProps, Offcanvas, OffcanvasBody, OffcanvasHeader, type OffcanvasProps, Pagination, ProgressBar, type ProgressBarProps, Radio, type RadioProps, RangeSlider, Select, type SelectOption, type SelectProps, type Size$3 as Size, type SizeProps, Skeleton, Slider, Stepper, Switch, type SwitchProps, Table, TableBody, TableCell, TableHead, type TableProps, TableRow, Tabs, Text, Textarea, type TextareaProps, Tooltip, type TooltipProps, type WithChildren, motionVariants };
|