@clasing/ui 0.1.83 → 0.1.91
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 +42 -41
- package/dist/index.es.js +1737 -1913
- package/dist/index.umd.js +16 -15
- package/dist/style.css +1 -1
- package/package.json +25 -25
- package/tailwind.config.js +16 -16
package/dist/index.d.ts
CHANGED
|
@@ -3,7 +3,8 @@ import { default as default_2 } from 'react';
|
|
|
3
3
|
import { Dispatch } from 'react';
|
|
4
4
|
import { ForwardRefExoticComponent } from 'react';
|
|
5
5
|
import { HTMLAttributes } from 'react';
|
|
6
|
-
import { JSX
|
|
6
|
+
import { JSX } from 'react/jsx-runtime';
|
|
7
|
+
import { JSX as JSX_2 } from 'react';
|
|
7
8
|
import { Matcher } from 'react-day-picker';
|
|
8
9
|
import { Placement } from '@floating-ui/react';
|
|
9
10
|
import { ReactNode } from 'react';
|
|
@@ -12,14 +13,11 @@ import { SetStateAction } from 'react';
|
|
|
12
13
|
import * as TablerIcons from '@tabler/icons-react';
|
|
13
14
|
import { VariantProps } from 'class-variance-authority';
|
|
14
15
|
|
|
15
|
-
declare
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
intent
|
|
19
|
-
|
|
20
|
-
canClose?: boolean;
|
|
21
|
-
duration?: number;
|
|
22
|
-
}
|
|
16
|
+
export declare const Alert: ForwardRefExoticComponent<IAlertProps & RefAttributes<HTMLDivElement>>;
|
|
17
|
+
|
|
18
|
+
declare const alertStyles: (props?: ({
|
|
19
|
+
intent?: "error" | "info" | "success" | "warning" | "neutral" | null | undefined;
|
|
20
|
+
} & ClassProp) | undefined) => string;
|
|
23
21
|
|
|
24
22
|
export declare const Avatar: ForwardRefExoticComponent<AvatarProps & RefAttributes<HTMLImageElement>>;
|
|
25
23
|
|
|
@@ -30,10 +28,10 @@ declare interface AvatarProps extends React.ImgHTMLAttributes<HTMLImageElement>
|
|
|
30
28
|
export declare const Badge: ForwardRefExoticComponent<IBadgeProps & RefAttributes<HTMLSpanElement>>;
|
|
31
29
|
|
|
32
30
|
declare const badgeStyles: (props?: ({
|
|
33
|
-
utility?: "error" | "
|
|
31
|
+
utility?: "error" | "info" | "success" | "warning" | null | undefined;
|
|
34
32
|
intent?: "neutral" | "brand" | "brand-subtle" | "brand-bolder" | "blue" | "blue-subtle" | "blue-bolder" | "yellow" | "yellow-subtle" | "yellow-bolder" | "violet-subtle" | "violet" | "violet-bolder" | null | undefined;
|
|
35
33
|
size?: "xs" | "sm" | "md" | "lg" | null | undefined;
|
|
36
|
-
weight?: "
|
|
34
|
+
weight?: "light" | "regular" | "semibold" | "bold" | null | undefined;
|
|
37
35
|
rounded?: "rectangle" | "full" | null | undefined;
|
|
38
36
|
} & ClassProp) | undefined) => string;
|
|
39
37
|
|
|
@@ -43,7 +41,7 @@ export declare const buttonActiveStyles: (props?: ({
|
|
|
43
41
|
intent?: "outline" | "primary-red" | "primary-blue" | "secondary" | "ghost" | "destructive" | null | undefined;
|
|
44
42
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
45
43
|
rounded?: "sm" | "full" | null | undefined;
|
|
46
|
-
weight?: "
|
|
44
|
+
weight?: "light" | "regular" | "semibold" | "bold" | null | undefined;
|
|
47
45
|
} & ClassProp) | undefined) => string;
|
|
48
46
|
|
|
49
47
|
export declare const ButtonIcon: default_2.ForwardRefExoticComponent<IButtonIconProps & default_2.RefAttributes<HTMLButtonElement>>;
|
|
@@ -71,21 +69,21 @@ export declare const ButtonLink: ForwardRefExoticComponent<IButtonLinkProps & Re
|
|
|
71
69
|
export declare const buttonLinkStyles: (props?: ({
|
|
72
70
|
intent?: "primary" | null | undefined;
|
|
73
71
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
74
|
-
weight?: "
|
|
72
|
+
weight?: "light" | "regular" | "semibold" | "bold" | null | undefined;
|
|
75
73
|
} & ClassProp) | undefined) => string;
|
|
76
74
|
|
|
77
75
|
export declare const buttonLoadingStyles: (props?: ({
|
|
78
76
|
intent?: "outline" | "primary-red" | "primary-blue" | "secondary" | "ghost" | "destructive" | null | undefined;
|
|
79
77
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
80
78
|
rounded?: "sm" | "full" | null | undefined;
|
|
81
|
-
weight?: "
|
|
79
|
+
weight?: "light" | "regular" | "semibold" | "bold" | null | undefined;
|
|
82
80
|
} & ClassProp) | undefined) => string;
|
|
83
81
|
|
|
84
82
|
export declare const buttonStyles: (props?: ({
|
|
85
83
|
intent?: "outline" | "primary-red" | "primary-blue" | "secondary" | "ghost" | "destructive" | null | undefined;
|
|
86
84
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
87
85
|
rounded?: "sm" | "full" | null | undefined;
|
|
88
|
-
weight?: "
|
|
86
|
+
weight?: "light" | "regular" | "semibold" | "bold" | null | undefined;
|
|
89
87
|
} & ClassProp) | undefined) => string;
|
|
90
88
|
|
|
91
89
|
export declare const Calendar: React.FC<ICalendarProps>;
|
|
@@ -111,14 +109,14 @@ export declare const Chip: ForwardRefExoticComponent<IChipProps & RefAttributes<
|
|
|
111
109
|
export declare const chipStyles: (props?: ({
|
|
112
110
|
intent?: "error" | "disabled" | "selected" | "unselected" | null | undefined;
|
|
113
111
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
114
|
-
weight?: "
|
|
112
|
+
weight?: "light" | "regular" | "semibold" | "bold" | null | undefined;
|
|
115
113
|
} & ClassProp) | undefined) => string;
|
|
116
114
|
|
|
117
115
|
export declare const Datepicker: ForwardRefExoticComponent<IDatepickerProps & RefAttributes<HTMLInputElement>>;
|
|
118
116
|
|
|
119
117
|
export declare const DateRangePicker: ForwardRefExoticComponent<IDateRangePickerProps & RefAttributes<HTMLInputElement>>;
|
|
120
118
|
|
|
121
|
-
export declare const DayTimePicker: ({ availableHours, availableTimes, onSelectionChange, locale, intervalMinutes, singleSelection, singleSelectionPerDay, disabledDays, }: DayTimePickerProps) =>
|
|
119
|
+
export declare const DayTimePicker: ({ availableHours, availableTimes, onSelectionChange, locale, intervalMinutes, singleSelection, singleSelectionPerDay, disabledDays, }: DayTimePickerProps) => JSX.Element;
|
|
122
120
|
|
|
123
121
|
declare interface DayTimePickerProps {
|
|
124
122
|
availableHours?: {
|
|
@@ -171,6 +169,13 @@ declare interface DropdownSelectProps<T extends string | number | readonly strin
|
|
|
171
169
|
disableSearchWhileLoading?: boolean;
|
|
172
170
|
}
|
|
173
171
|
|
|
172
|
+
declare interface IAlertProps extends React.HTMLAttributes<HTMLDivElement>, VariantProps<typeof alertStyles> {
|
|
173
|
+
title?: string;
|
|
174
|
+
content?: string;
|
|
175
|
+
showIcon?: boolean;
|
|
176
|
+
iconName?: TablerIconName;
|
|
177
|
+
}
|
|
178
|
+
|
|
174
179
|
declare interface IBadgeProps extends React.HTMLAttributes<HTMLSpanElement>, VariantProps<typeof badgeStyles> {
|
|
175
180
|
iconLeft?: {
|
|
176
181
|
name: TablerIconName;
|
|
@@ -346,7 +351,7 @@ declare const interactiveCardStyles: (props?: ({
|
|
|
346
351
|
|
|
347
352
|
declare interface IPopoverProps {
|
|
348
353
|
children: default_2.ReactNode;
|
|
349
|
-
trigger:
|
|
354
|
+
trigger: JSX_2.Element;
|
|
350
355
|
open?: boolean;
|
|
351
356
|
placement?: PopoverPlacement;
|
|
352
357
|
closeOnAction?: boolean;
|
|
@@ -403,7 +408,7 @@ declare interface ITooltipProps {
|
|
|
403
408
|
arrow?: boolean;
|
|
404
409
|
}
|
|
405
410
|
|
|
406
|
-
export declare const Modal: ({ className, children, isOpen, setIsOpen, canClose, intent, overlay, closeButtonAriaLabel, closeOnClickOutside, }: ModalProps) =>
|
|
411
|
+
export declare const Modal: ({ className, children, isOpen, setIsOpen, canClose, intent, overlay, closeButtonAriaLabel, closeOnClickOutside, }: ModalProps) => JSX.Element | null;
|
|
407
412
|
|
|
408
413
|
declare interface ModalProps {
|
|
409
414
|
className?: string;
|
|
@@ -425,7 +430,7 @@ declare type Option_2 = {
|
|
|
425
430
|
export { Option_2 as Option }
|
|
426
431
|
|
|
427
432
|
declare interface OutsideClickHandlerProps {
|
|
428
|
-
ref: React.RefObject<HTMLElement>;
|
|
433
|
+
ref: React.RefObject<HTMLElement | null>;
|
|
429
434
|
handler: () => void;
|
|
430
435
|
}
|
|
431
436
|
|
|
@@ -435,9 +440,9 @@ declare type PopoverPlacement = Placement;
|
|
|
435
440
|
|
|
436
441
|
declare type PopoverWidth = 'as-trigger' | 'auto';
|
|
437
442
|
|
|
438
|
-
declare type PositionProps = 'top-
|
|
443
|
+
declare type PositionProps = 'top-left' | 'top' | 'top-right' | 'bottom-left' | 'bottom' | 'bottom-right';
|
|
439
444
|
|
|
440
|
-
export declare const ProgressBar: ({ progress, className, intent, size, rounded, ...props }: IProgressBarProps) =>
|
|
445
|
+
export declare const ProgressBar: ({ progress, className, intent, size, rounded, ...props }: IProgressBarProps) => JSX.Element;
|
|
441
446
|
|
|
442
447
|
declare const progressBarStyles: (props?: ({
|
|
443
448
|
intent?: "brand" | "blue" | "yellow" | "green" | null | undefined;
|
|
@@ -445,11 +450,11 @@ declare const progressBarStyles: (props?: ({
|
|
|
445
450
|
rounded?: "sm" | "full" | null | undefined;
|
|
446
451
|
} & ClassProp) | undefined) => string;
|
|
447
452
|
|
|
448
|
-
export declare const SelectableChips: ({ id, label, options, multiple, selectedOptions, setSelectedOptions, className, disabled, helperText, error, touched, }: ISelectableChipsProps) =>
|
|
453
|
+
export declare const SelectableChips: ({ id, label, options, multiple, selectedOptions, setSelectedOptions, className, disabled, helperText, error, touched, }: ISelectableChipsProps) => JSX.Element | null;
|
|
449
454
|
|
|
450
|
-
export declare const Skeleton: ({ className, ...props }: ISkeletonProps) =>
|
|
455
|
+
export declare const Skeleton: ({ className, ...props }: ISkeletonProps) => JSX.Element;
|
|
451
456
|
|
|
452
|
-
export declare const Spinner: ({ className }: ISpinnerProps) =>
|
|
457
|
+
export declare const Spinner: ({ className }: ISpinnerProps) => JSX.Element;
|
|
453
458
|
|
|
454
459
|
export declare const Switch: ForwardRefExoticComponent<ISwitchProps & RefAttributes<HTMLButtonElement>>;
|
|
455
460
|
|
|
@@ -459,46 +464,42 @@ declare const switchRootStyles: (props?: ({
|
|
|
459
464
|
|
|
460
465
|
declare type TablerIconName = keyof typeof TablerIcons;
|
|
461
466
|
|
|
462
|
-
declare const Text_2: ({ as, intent, className, weight, ...props }: ITextProps) =>
|
|
467
|
+
declare const Text_2: ({ as, intent, className, weight, ...props }: ITextProps) => JSX.Element;
|
|
463
468
|
export { Text_2 as Text }
|
|
464
469
|
|
|
465
470
|
declare const textStyles: (props?: ({
|
|
466
471
|
intent?: "display-sm" | "display-lg" | "title-xs" | "title-sm" | "title-md" | "title-lg" | "title-xl" | "label-xs" | "label-sm" | "label-md" | "label-lg" | "label-xl" | "label-2xl" | "label-3xl" | "paragraph-xs" | "paragraph-sm" | "paragraph-md" | "paragraph-lg" | "overline-sm" | "overline-lg" | null | undefined;
|
|
467
|
-
weight?: "
|
|
472
|
+
weight?: "light" | "regular" | "semibold" | "bold" | null | undefined;
|
|
468
473
|
} & ClassProp) | undefined) => string;
|
|
469
474
|
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
declare type ToastContextType = (props: AddToastProps) => void;
|
|
473
|
-
|
|
474
|
-
declare interface ToastProps extends default_2.HTMLAttributes<HTMLDivElement>, VariantProps<typeof toastStyles> {
|
|
475
|
+
declare interface ToastProps {
|
|
476
|
+
id: string;
|
|
475
477
|
title?: string;
|
|
476
|
-
message
|
|
477
|
-
|
|
478
|
-
onClose?: () => void;
|
|
478
|
+
message?: string;
|
|
479
|
+
intent?: ToastVariant;
|
|
479
480
|
position?: PositionProps;
|
|
480
481
|
duration?: number;
|
|
482
|
+
children?: ReactNode;
|
|
483
|
+
canClose?: boolean;
|
|
484
|
+
showIcon?: boolean;
|
|
481
485
|
}
|
|
482
486
|
|
|
483
487
|
export declare const ToastProvider: default_2.FC<ToastProviderProps>;
|
|
484
488
|
|
|
485
489
|
declare type ToastProviderProps = {
|
|
486
490
|
children: ReactNode;
|
|
487
|
-
position?: PositionProps;
|
|
488
491
|
};
|
|
489
492
|
|
|
490
|
-
declare
|
|
491
|
-
intent?: "error" | "warning" | "success" | "info" | "neutral" | null | undefined;
|
|
492
|
-
} & ClassProp) | undefined) => string;
|
|
493
|
+
declare type ToastVariant = 'info' | 'success' | 'warning' | 'error' | 'neutral';
|
|
493
494
|
|
|
494
495
|
export declare const Tooltip: {
|
|
495
|
-
({ children, trigger, className, placement, iconName, arrow: isArrow, }: ITooltipProps):
|
|
496
|
+
({ children, trigger, className, placement, iconName, arrow: isArrow, }: ITooltipProps): JSX.Element;
|
|
496
497
|
displayName: string;
|
|
497
498
|
};
|
|
498
499
|
|
|
499
500
|
export declare const useOutsideClick: ({ ref, handler }: OutsideClickHandlerProps) => void;
|
|
500
501
|
|
|
501
|
-
export declare const useToast: () =>
|
|
502
|
+
export declare const useToast: () => (toast: Omit<ToastProps, "id">) => void;
|
|
502
503
|
|
|
503
504
|
declare type WeekDay = 'MONDAY' | 'TUESDAY' | 'WEDNESDAY' | 'THURSDAY' | 'FRIDAY' | 'SATURDAY' | 'SUNDAY';
|
|
504
505
|
|