@clasing/ui 0.1.35 → 0.1.38
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 +52 -5
- package/dist/index.es.js +1744 -1569
- package/dist/index.umd.js +10 -10
- package/dist/style.css +1 -1
- package/package.json +2 -2
- package/tailwind.config.js +26 -0
package/dist/index.d.ts
CHANGED
|
@@ -1,16 +1,21 @@
|
|
|
1
1
|
import { ClassProp } from 'class-variance-authority/types';
|
|
2
2
|
import { default as default_2 } from 'react';
|
|
3
|
+
import { Dispatch } from 'react';
|
|
3
4
|
import { ForwardRefExoticComponent } from 'react';
|
|
4
5
|
import { JSX as JSX_2 } from 'react/jsx-runtime';
|
|
6
|
+
import { Matcher } from 'react-day-picker';
|
|
5
7
|
import { ReactNode } from 'react';
|
|
6
8
|
import { RefAttributes } from 'react';
|
|
9
|
+
import { SetStateAction } from 'react';
|
|
7
10
|
import * as TablerIcons from '@tabler/icons-react';
|
|
8
11
|
import { VariantProps } from 'class-variance-authority';
|
|
9
12
|
|
|
10
13
|
declare interface AddToastProps {
|
|
14
|
+
title?: ToastProps['title'];
|
|
11
15
|
message: ToastProps['message'];
|
|
12
16
|
intent: ToastProps['intent'];
|
|
13
17
|
position?: PositionProps;
|
|
18
|
+
canClose?: boolean;
|
|
14
19
|
duration?: number;
|
|
15
20
|
}
|
|
16
21
|
|
|
@@ -34,8 +39,26 @@ export declare const Button: ForwardRefExoticComponent<IButtonProps & RefAttribu
|
|
|
34
39
|
|
|
35
40
|
export declare const ButtonIcon: default_2.ForwardRefExoticComponent<IButtonIconProps & default_2.RefAttributes<HTMLButtonElement>>;
|
|
36
41
|
|
|
37
|
-
declare const
|
|
38
|
-
intent?: "outline" | "fill" | "ghost" | "destructive" | null | undefined;
|
|
42
|
+
export declare const buttonIconActiveStyles: (props?: ({
|
|
43
|
+
intent?: "outline" | "fill" | "blue-subtle" | "ghost" | "destructive" | null | undefined;
|
|
44
|
+
size?: "sm" | "md" | "lg" | null | undefined;
|
|
45
|
+
rounded?: "sm" | "full" | null | undefined;
|
|
46
|
+
} & ClassProp) | undefined) => string;
|
|
47
|
+
|
|
48
|
+
export declare const buttonIconDisabledStyles: (props?: ({
|
|
49
|
+
intent?: "outline" | "fill" | "blue-subtle" | "ghost" | "destructive" | null | undefined;
|
|
50
|
+
size?: "sm" | "md" | "lg" | null | undefined;
|
|
51
|
+
rounded?: "sm" | "full" | null | undefined;
|
|
52
|
+
} & ClassProp) | undefined) => string;
|
|
53
|
+
|
|
54
|
+
export declare const buttonIconLoadingStyles: (props?: ({
|
|
55
|
+
intent?: "outline" | "fill" | "blue-subtle" | "ghost" | "destructive" | null | undefined;
|
|
56
|
+
size?: "sm" | "md" | "lg" | null | undefined;
|
|
57
|
+
rounded?: "sm" | "full" | null | undefined;
|
|
58
|
+
} & ClassProp) | undefined) => string;
|
|
59
|
+
|
|
60
|
+
export declare const buttonIconStyles: (props?: ({
|
|
61
|
+
intent?: "outline" | "fill" | "blue-subtle" | "ghost" | "destructive" | null | undefined;
|
|
39
62
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
40
63
|
rounded?: "sm" | "full" | null | undefined;
|
|
41
64
|
} & ClassProp) | undefined) => string;
|
|
@@ -111,6 +134,7 @@ declare interface IButtonIconProps extends Omit<default_2.ButtonHTMLAttributes<H
|
|
|
111
134
|
stroke?: number;
|
|
112
135
|
} | TablerIconName;
|
|
113
136
|
isLoading?: boolean;
|
|
137
|
+
isActive?: boolean;
|
|
114
138
|
notification?: boolean;
|
|
115
139
|
}
|
|
116
140
|
|
|
@@ -150,7 +174,9 @@ declare interface IDatepickerProps extends React.InputHTMLAttributes<HTMLInputEl
|
|
|
150
174
|
touched?: boolean;
|
|
151
175
|
value: string;
|
|
152
176
|
locale?: 'enGB' | 'enUS' | 'es';
|
|
177
|
+
placement?: PopoverPlacement;
|
|
153
178
|
placeholder?: string;
|
|
179
|
+
disabledDates?: Matcher | Matcher[] | undefined;
|
|
154
180
|
minDate?: Date;
|
|
155
181
|
maxDate?: Date;
|
|
156
182
|
}
|
|
@@ -162,6 +188,7 @@ declare interface IDateRangePickerProps extends React.InputHTMLAttributes<HTMLIn
|
|
|
162
188
|
touched?: boolean;
|
|
163
189
|
startDate: string;
|
|
164
190
|
endDate: string;
|
|
191
|
+
disabledDates?: Matcher | Matcher[] | undefined;
|
|
165
192
|
locale?: 'enGB' | 'enUS' | 'es';
|
|
166
193
|
placeholder?: string;
|
|
167
194
|
minDate?: Date;
|
|
@@ -177,14 +204,14 @@ declare interface IIconComponentProps {
|
|
|
177
204
|
onClick?: () => void;
|
|
178
205
|
}
|
|
179
206
|
|
|
180
|
-
export declare const Input: ForwardRefExoticComponent<InputProps & RefAttributes<HTMLInputElement>>;
|
|
207
|
+
export declare const Input: ForwardRefExoticComponent<InputProps & RefAttributes<HTMLInputElement | HTMLTextAreaElement>>;
|
|
181
208
|
|
|
182
|
-
declare interface InputProps extends React.InputHTMLAttributes<HTMLInputElement> {
|
|
209
|
+
declare interface InputProps extends React.InputHTMLAttributes<HTMLInputElement | HTMLTextAreaElement> {
|
|
183
210
|
label?: string;
|
|
184
211
|
helperText?: string;
|
|
185
212
|
error?: string;
|
|
186
213
|
touched?: boolean;
|
|
187
|
-
type?: 'text' | 'password' | 'email' | 'number' | 'tel' | 'url';
|
|
214
|
+
type?: 'text' | 'textarea' | 'password' | 'email' | 'number' | 'tel' | 'url';
|
|
188
215
|
iconName?: {
|
|
189
216
|
name: TablerIconName;
|
|
190
217
|
stroke?: number;
|
|
@@ -204,6 +231,13 @@ declare interface IProgressBarProps extends Omit<React.HTMLAttributes<HTMLDivEle
|
|
|
204
231
|
progress: number;
|
|
205
232
|
}
|
|
206
233
|
|
|
234
|
+
declare interface ISelectableChipsProps {
|
|
235
|
+
options: Option_2[];
|
|
236
|
+
multiple?: boolean;
|
|
237
|
+
selectedOptions: Option_2[];
|
|
238
|
+
setSelectedOptions: Dispatch<SetStateAction<Option_2[]>>;
|
|
239
|
+
}
|
|
240
|
+
|
|
207
241
|
declare interface ISpinnerProps {
|
|
208
242
|
className?: string;
|
|
209
243
|
}
|
|
@@ -227,6 +261,13 @@ declare interface ModalProps {
|
|
|
227
261
|
canClose?: boolean;
|
|
228
262
|
}
|
|
229
263
|
|
|
264
|
+
declare type Option_2 = {
|
|
265
|
+
value: string | number | boolean | undefined | null;
|
|
266
|
+
label: string;
|
|
267
|
+
notification?: boolean;
|
|
268
|
+
};
|
|
269
|
+
export { Option_2 as Option }
|
|
270
|
+
|
|
230
271
|
declare interface OutsideClickHandlerProps {
|
|
231
272
|
ref: React.RefObject<HTMLElement>;
|
|
232
273
|
handler: () => void;
|
|
@@ -246,6 +287,8 @@ declare const progressBarStyles: (props?: ({
|
|
|
246
287
|
rounded?: "sm" | "full" | null | undefined;
|
|
247
288
|
} & ClassProp) | undefined) => string;
|
|
248
289
|
|
|
290
|
+
export declare const SelectableChips: ({ options, multiple, selectedOptions, setSelectedOptions, }: ISelectableChipsProps) => JSX_2.Element;
|
|
291
|
+
|
|
249
292
|
export declare const Spinner: ({ className }: ISpinnerProps) => JSX_2.Element;
|
|
250
293
|
|
|
251
294
|
declare type TablerIconName = keyof typeof TablerIcons;
|
|
@@ -263,7 +306,9 @@ export declare const Toast: default_2.ForwardRefExoticComponent<ToastProps & def
|
|
|
263
306
|
declare type ToastContextType = (props: AddToastProps) => void;
|
|
264
307
|
|
|
265
308
|
declare interface ToastProps extends default_2.HTMLAttributes<HTMLDivElement>, VariantProps<typeof toastStyles> {
|
|
309
|
+
title?: string;
|
|
266
310
|
message: string;
|
|
311
|
+
canClose?: boolean;
|
|
267
312
|
onClose: () => void;
|
|
268
313
|
position?: PositionProps;
|
|
269
314
|
duration?: number;
|
|
@@ -284,6 +329,8 @@ export declare const Tooltip: ForwardRefExoticComponent<ITooltipProps & RefAttri
|
|
|
284
329
|
|
|
285
330
|
declare const tooltipStyles: (props?: ({
|
|
286
331
|
shadow?: "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl" | null | undefined;
|
|
332
|
+
intent?: "light" | "dark" | null | undefined;
|
|
333
|
+
weight?: "bold" | "light" | "regular" | "semibold" | null | undefined;
|
|
287
334
|
placement?: "top" | "bottom" | "left" | "right" | null | undefined;
|
|
288
335
|
delay?: 0 | 200 | 75 | 100 | 150 | 300 | 500 | null | undefined;
|
|
289
336
|
closeDelay?: 0 | 200 | 75 | 100 | 150 | 300 | 500 | null | undefined;
|