@clasing/ui 0.1.37 → 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 +29 -3
- package/dist/index.es.js +1625 -1536
- package/dist/index.umd.js +10 -10
- package/dist/style.css +1 -1
- package/package.json +2 -2
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
|
|
|
@@ -169,7 +174,9 @@ declare interface IDatepickerProps extends React.InputHTMLAttributes<HTMLInputEl
|
|
|
169
174
|
touched?: boolean;
|
|
170
175
|
value: string;
|
|
171
176
|
locale?: 'enGB' | 'enUS' | 'es';
|
|
177
|
+
placement?: PopoverPlacement;
|
|
172
178
|
placeholder?: string;
|
|
179
|
+
disabledDates?: Matcher | Matcher[] | undefined;
|
|
173
180
|
minDate?: Date;
|
|
174
181
|
maxDate?: Date;
|
|
175
182
|
}
|
|
@@ -181,6 +188,7 @@ declare interface IDateRangePickerProps extends React.InputHTMLAttributes<HTMLIn
|
|
|
181
188
|
touched?: boolean;
|
|
182
189
|
startDate: string;
|
|
183
190
|
endDate: string;
|
|
191
|
+
disabledDates?: Matcher | Matcher[] | undefined;
|
|
184
192
|
locale?: 'enGB' | 'enUS' | 'es';
|
|
185
193
|
placeholder?: string;
|
|
186
194
|
minDate?: Date;
|
|
@@ -196,14 +204,14 @@ declare interface IIconComponentProps {
|
|
|
196
204
|
onClick?: () => void;
|
|
197
205
|
}
|
|
198
206
|
|
|
199
|
-
export declare const Input: ForwardRefExoticComponent<InputProps & RefAttributes<HTMLInputElement>>;
|
|
207
|
+
export declare const Input: ForwardRefExoticComponent<InputProps & RefAttributes<HTMLInputElement | HTMLTextAreaElement>>;
|
|
200
208
|
|
|
201
|
-
declare interface InputProps extends React.InputHTMLAttributes<HTMLInputElement> {
|
|
209
|
+
declare interface InputProps extends React.InputHTMLAttributes<HTMLInputElement | HTMLTextAreaElement> {
|
|
202
210
|
label?: string;
|
|
203
211
|
helperText?: string;
|
|
204
212
|
error?: string;
|
|
205
213
|
touched?: boolean;
|
|
206
|
-
type?: 'text' | 'password' | 'email' | 'number' | 'tel' | 'url';
|
|
214
|
+
type?: 'text' | 'textarea' | 'password' | 'email' | 'number' | 'tel' | 'url';
|
|
207
215
|
iconName?: {
|
|
208
216
|
name: TablerIconName;
|
|
209
217
|
stroke?: number;
|
|
@@ -223,6 +231,13 @@ declare interface IProgressBarProps extends Omit<React.HTMLAttributes<HTMLDivEle
|
|
|
223
231
|
progress: number;
|
|
224
232
|
}
|
|
225
233
|
|
|
234
|
+
declare interface ISelectableChipsProps {
|
|
235
|
+
options: Option_2[];
|
|
236
|
+
multiple?: boolean;
|
|
237
|
+
selectedOptions: Option_2[];
|
|
238
|
+
setSelectedOptions: Dispatch<SetStateAction<Option_2[]>>;
|
|
239
|
+
}
|
|
240
|
+
|
|
226
241
|
declare interface ISpinnerProps {
|
|
227
242
|
className?: string;
|
|
228
243
|
}
|
|
@@ -246,6 +261,13 @@ declare interface ModalProps {
|
|
|
246
261
|
canClose?: boolean;
|
|
247
262
|
}
|
|
248
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
|
+
|
|
249
271
|
declare interface OutsideClickHandlerProps {
|
|
250
272
|
ref: React.RefObject<HTMLElement>;
|
|
251
273
|
handler: () => void;
|
|
@@ -265,6 +287,8 @@ declare const progressBarStyles: (props?: ({
|
|
|
265
287
|
rounded?: "sm" | "full" | null | undefined;
|
|
266
288
|
} & ClassProp) | undefined) => string;
|
|
267
289
|
|
|
290
|
+
export declare const SelectableChips: ({ options, multiple, selectedOptions, setSelectedOptions, }: ISelectableChipsProps) => JSX_2.Element;
|
|
291
|
+
|
|
268
292
|
export declare const Spinner: ({ className }: ISpinnerProps) => JSX_2.Element;
|
|
269
293
|
|
|
270
294
|
declare type TablerIconName = keyof typeof TablerIcons;
|
|
@@ -282,7 +306,9 @@ export declare const Toast: default_2.ForwardRefExoticComponent<ToastProps & def
|
|
|
282
306
|
declare type ToastContextType = (props: AddToastProps) => void;
|
|
283
307
|
|
|
284
308
|
declare interface ToastProps extends default_2.HTMLAttributes<HTMLDivElement>, VariantProps<typeof toastStyles> {
|
|
309
|
+
title?: string;
|
|
285
310
|
message: string;
|
|
311
|
+
canClose?: boolean;
|
|
286
312
|
onClose: () => void;
|
|
287
313
|
position?: PositionProps;
|
|
288
314
|
duration?: number;
|