asheeui 0.6.8 → 0.6.10
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/components/autocomplete/Autocomplete.d.ts +34 -17
- package/dist/components/autocomplete/Autocomplete.d.ts.map +1 -1
- package/dist/components/autocomplete/Autocomplete.js +86 -102
- package/dist/components/autocomplete/autocomplete-config.d.ts +4 -22
- package/dist/components/autocomplete/autocomplete-config.d.ts.map +1 -1
- package/dist/components/autocomplete/autocomplete-config.js +8 -11
- package/dist/components/button/Button.d.ts +31 -5
- package/dist/components/button/Button.d.ts.map +1 -1
- package/dist/components/button/Button.js +68 -64
- package/dist/components/card/Card.d.ts +58 -54
- package/dist/components/card/Card.d.ts.map +1 -1
- package/dist/components/card/Card.js +152 -158
- package/dist/components/card/card-config.d.ts +66 -33
- package/dist/components/card/card-config.d.ts.map +1 -1
- package/dist/components/card/card-config.js +9 -9
- package/dist/components/date-picker/Calendar.d.ts +57 -0
- package/dist/components/date-picker/Calendar.d.ts.map +1 -0
- package/dist/components/date-picker/Calendar.js +224 -0
- package/dist/components/date-picker/DatePicker.d.ts +68 -155
- package/dist/components/date-picker/DatePicker.d.ts.map +1 -1
- package/dist/components/date-picker/DatePicker.js +194 -466
- package/dist/components/date-picker/TimeSpinner.d.ts +46 -0
- package/dist/components/date-picker/TimeSpinner.d.ts.map +1 -0
- package/dist/components/date-picker/TimeSpinner.js +84 -0
- package/dist/components/date-picker/date-picker-config.d.ts +24 -3
- package/dist/components/date-picker/date-picker-config.d.ts.map +1 -1
- package/dist/components/date-picker/date-picker-config.js +9 -12
- package/dist/components/date-picker/date-picker-styles.d.ts.map +1 -1
- package/dist/components/date-picker/date-picker-styles.js +4 -11
- package/dist/components/date-picker/date-picker.helpers.d.ts +111 -0
- package/dist/components/date-picker/date-picker.helpers.d.ts.map +1 -0
- package/dist/components/date-picker/date-picker.helpers.js +110 -0
- package/dist/components/date-picker/index.js +3 -0
- package/dist/components/input/Input.d.ts +13 -7
- package/dist/components/input/Input.d.ts.map +1 -1
- package/dist/components/input/Input.js +96 -91
- package/dist/components/keyboard/KeyboardContext.d.ts +130 -0
- package/dist/components/keyboard/KeyboardContext.d.ts.map +1 -0
- package/dist/components/keyboard/KeyboardContext.js +13 -0
- package/dist/components/keyboard/KeyboardProvider.d.ts +78 -0
- package/dist/components/keyboard/KeyboardProvider.d.ts.map +1 -0
- package/dist/components/keyboard/KeyboardProvider.js +183 -0
- package/dist/components/keyboard/OnScreenKeyboard.d.ts +65 -43
- package/dist/components/keyboard/OnScreenKeyboard.d.ts.map +1 -1
- package/dist/components/keyboard/OnScreenKeyboard.js +119 -113
- package/dist/components/keyboard/index.d.ts +2 -1
- package/dist/components/keyboard/index.d.ts.map +1 -1
- package/dist/components/keyboard/index.js +2 -1
- package/dist/components/keyboard/keyboard-config.d.ts +40 -36
- package/dist/components/keyboard/keyboard-config.d.ts.map +1 -1
- package/dist/components/keyboard/keyboard-config.js +15 -10
- package/dist/components/keyboard/use-keyboard-field.d.ts +6 -4
- package/dist/components/keyboard/use-keyboard-field.d.ts.map +1 -1
- package/dist/components/keyboard/use-keyboard-field.js +12 -12
- package/dist/components/multi-select/MultiSelect.d.ts +75 -40
- package/dist/components/multi-select/MultiSelect.d.ts.map +1 -1
- package/dist/components/multi-select/MultiSelect.js +188 -187
- package/dist/components/multi-select/multi-select-config.d.ts +4 -22
- package/dist/components/multi-select/multi-select-config.d.ts.map +1 -1
- package/dist/components/multi-select/multi-select-config.js +11 -14
- package/dist/components/radio/radio-config.d.ts +3 -2
- package/dist/components/radio/radio-config.d.ts.map +1 -1
- package/dist/components/radio/radio-config.js +9 -8
- package/dist/components/select/Select.d.ts +60 -45
- package/dist/components/select/Select.d.ts.map +1 -1
- package/dist/components/select/Select.js +147 -159
- package/dist/components/select/select-config.d.ts +5 -33
- package/dist/components/select/select-config.d.ts.map +1 -1
- package/dist/components/select/select-config.js +6 -13
- package/dist/components/select/select-styles.js +1 -6
- package/dist/components/select-menu/SelectMenu.d.ts +45 -30
- package/dist/components/select-menu/SelectMenu.d.ts.map +1 -1
- package/dist/components/select-menu/SelectMenu.js +125 -124
- package/dist/components/select-menu/select-menu-config.d.ts +25 -2
- package/dist/components/select-menu/select-menu-config.d.ts.map +1 -1
- package/dist/components/select-menu/select-menu-config.js +4 -3
- package/dist/components/switch/Switch.d.ts +9 -33
- package/dist/components/switch/Switch.d.ts.map +1 -1
- package/dist/components/switch/Switch.js +68 -74
- package/dist/components/switch/switch-config.d.ts +3 -2
- package/dist/components/switch/switch-config.d.ts.map +1 -1
- package/dist/components/switch/switch-config.js +6 -5
- package/dist/components/switch/switch-styles.d.ts +1 -6
- package/dist/components/switch/switch-styles.d.ts.map +1 -1
- package/dist/components/switch/switch-styles.js +6 -12
- package/dist/components/textarea/Textarea.d.ts +19 -1
- package/dist/components/textarea/Textarea.d.ts.map +1 -1
- package/dist/components/textarea/Textarea.js +95 -90
- package/dist/components/toast/ToastContext.d.ts +122 -0
- package/dist/components/toast/ToastContext.d.ts.map +1 -0
- package/dist/components/toast/ToastContext.js +28 -0
- package/dist/components/toast/ToastProvider.d.ts +98 -0
- package/dist/components/toast/ToastProvider.d.ts.map +1 -0
- package/dist/components/toast/ToastProvider.js +192 -0
- package/dist/components/toast/index.d.ts +2 -1
- package/dist/components/toast/index.d.ts.map +1 -1
- package/dist/components/toast/index.js +2 -1
- package/dist/components/toast/toast-config.d.ts +36 -0
- package/dist/components/toast/toast-config.d.ts.map +1 -1
- package/dist/components/toast/toast-styles.d.ts +8 -0
- package/dist/components/toast/toast-styles.d.ts.map +1 -1
- package/dist/components/toast/toast-styles.js +11 -3
- package/dist/icons/ChevronUpIcon.d.ts +3 -0
- package/dist/icons/ChevronUpIcon.d.ts.map +1 -0
- package/dist/icons/ChevronUpIcon.js +21 -0
- package/dist/icons/index.d.ts +2 -0
- package/dist/icons/index.d.ts.map +1 -1
- package/dist/index.js +62 -59
- package/dist/theme/color.js +2 -2
- package/package.json +1 -1
- package/dist/components/keyboard/keyboard-context.d.ts +0 -118
- package/dist/components/keyboard/keyboard-context.d.ts.map +0 -1
- package/dist/components/keyboard/keyboard-context.js +0 -90
- package/dist/components/toast/toast-context.d.ts +0 -163
- package/dist/components/toast/toast-context.d.ts.map +0 -1
- package/dist/components/toast/toast-context.js +0 -177
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { Radius, Size, Variant } from '../../shared';
|
|
3
|
+
import { ToastItemData, ToastPlacement, ToastShowOptions } from './toast-config';
|
|
4
|
+
/**
|
|
5
|
+
* Context type for the toast system.
|
|
6
|
+
* Provides methods for showing and managing toast notifications.
|
|
7
|
+
*/
|
|
8
|
+
export interface ToastContextType {
|
|
9
|
+
/**
|
|
10
|
+
* Array of currently active toast items.
|
|
11
|
+
*/
|
|
12
|
+
toasts: ToastItemData[];
|
|
13
|
+
/**
|
|
14
|
+
* Show a toast with the given options.
|
|
15
|
+
* Returns the toast ID.
|
|
16
|
+
*/
|
|
17
|
+
toast: (options: ToastShowOptions | string) => string;
|
|
18
|
+
/**
|
|
19
|
+
* Show a success toast.
|
|
20
|
+
* Returns the toast ID.
|
|
21
|
+
*/
|
|
22
|
+
success: (message: ReactNode, options?: Partial<ToastShowOptions>) => string;
|
|
23
|
+
/**
|
|
24
|
+
* Show an error toast.
|
|
25
|
+
* Returns the toast ID.
|
|
26
|
+
*/
|
|
27
|
+
error: (message: ReactNode, options?: Partial<ToastShowOptions>) => string;
|
|
28
|
+
/**
|
|
29
|
+
* Show an info toast.
|
|
30
|
+
* Returns the toast ID.
|
|
31
|
+
*/
|
|
32
|
+
info: (message: ReactNode, options?: Partial<ToastShowOptions>) => string;
|
|
33
|
+
/**
|
|
34
|
+
* Show a warning toast.
|
|
35
|
+
* Returns the toast ID.
|
|
36
|
+
*/
|
|
37
|
+
warning: (message: ReactNode, options?: Partial<ToastShowOptions>) => string;
|
|
38
|
+
/**
|
|
39
|
+
* Remove a toast by ID.
|
|
40
|
+
*/
|
|
41
|
+
removeToast: (id: string) => void;
|
|
42
|
+
/**
|
|
43
|
+
* Clear all active toasts.
|
|
44
|
+
*/
|
|
45
|
+
clearToasts: () => void;
|
|
46
|
+
/**
|
|
47
|
+
* The portal target element for toast rendering.
|
|
48
|
+
* When portal is enabled, toasts are rendered into this element.
|
|
49
|
+
* Defaults to document.body.
|
|
50
|
+
*/
|
|
51
|
+
portalTarget?: HTMLElement | null;
|
|
52
|
+
/**
|
|
53
|
+
* The default placement for toasts.
|
|
54
|
+
*/
|
|
55
|
+
defaultPlacement: ToastPlacement;
|
|
56
|
+
/**
|
|
57
|
+
* The default size for toasts.
|
|
58
|
+
*/
|
|
59
|
+
defaultSize: Size;
|
|
60
|
+
/**
|
|
61
|
+
* The default variant for toasts.
|
|
62
|
+
*/
|
|
63
|
+
defaultVariant: Variant;
|
|
64
|
+
/**
|
|
65
|
+
* The default radius for toasts.
|
|
66
|
+
*/
|
|
67
|
+
defaultRadius: Radius;
|
|
68
|
+
/**
|
|
69
|
+
* Whether toasts are animated by default.
|
|
70
|
+
*/
|
|
71
|
+
defaultAnimated: boolean;
|
|
72
|
+
}
|
|
73
|
+
export declare const ToastContext: import('react').Context<ToastContextType | null>;
|
|
74
|
+
/**
|
|
75
|
+
* Hook for accessing the toast system.
|
|
76
|
+
*
|
|
77
|
+
* useToast returns methods for showing toast notifications with
|
|
78
|
+
* different types (success, error, info, warning). Each toast can be
|
|
79
|
+
* customized with its own size, placement, variant, radius, and animation
|
|
80
|
+
* settings. Must be used within a ToastProvider component.
|
|
81
|
+
*
|
|
82
|
+
* @returns The toast context with methods for showing and managing toasts.
|
|
83
|
+
* If used outside a ToastProvider, returns safe fallback methods.
|
|
84
|
+
*
|
|
85
|
+
* @example
|
|
86
|
+
* ```tsx
|
|
87
|
+
* function MyComponent() {
|
|
88
|
+
* const toast = useToast();
|
|
89
|
+
*
|
|
90
|
+
* const handleClick = () => {
|
|
91
|
+
* toast.success("Saved successfully!");
|
|
92
|
+
* };
|
|
93
|
+
*
|
|
94
|
+
* return <button onClick={handleClick}>Save</button>;
|
|
95
|
+
* }
|
|
96
|
+
* ```
|
|
97
|
+
*
|
|
98
|
+
* @example
|
|
99
|
+
* ```tsx
|
|
100
|
+
* // Customize individual toast appearance
|
|
101
|
+
* function MyComponent() {
|
|
102
|
+
* const toast = useToast();
|
|
103
|
+
*
|
|
104
|
+
* const showCustomToast = () => {
|
|
105
|
+
* toast.info("Custom notification", {
|
|
106
|
+
* placement: "bottom-left",
|
|
107
|
+
* size: "lg",
|
|
108
|
+
* variant: "solid",
|
|
109
|
+
* radius: "full",
|
|
110
|
+
* animated: false,
|
|
111
|
+
* timeout: 5000,
|
|
112
|
+
* });
|
|
113
|
+
* };
|
|
114
|
+
*
|
|
115
|
+
* return <button onClick={showCustomToast}>Show Custom Toast</button>;
|
|
116
|
+
* }
|
|
117
|
+
* ```
|
|
118
|
+
*
|
|
119
|
+
* @see ToastProvider - The provider component that enables the toast system.
|
|
120
|
+
*/
|
|
121
|
+
export declare function useToast(): ToastContextType;
|
|
122
|
+
//# sourceMappingURL=ToastContext.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ToastContext.d.ts","sourceRoot":"","sources":["../../../src/components/toast/ToastContext.tsx"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAiB,KAAK,SAAS,EAAc,MAAM,OAAO,CAAC;AAClE,OAAO,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAC1D,OAAO,KAAK,EACV,aAAa,EACb,cAAc,EACd,gBAAgB,EACjB,MAAM,gBAAgB,CAAC;AAIxB;;;GAGG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;OAEG;IACH,MAAM,EAAE,aAAa,EAAE,CAAC;IAExB;;;OAGG;IACH,KAAK,EAAE,CAAC,OAAO,EAAE,gBAAgB,GAAG,MAAM,KAAK,MAAM,CAAC;IAEtD;;;OAGG;IACH,OAAO,EAAE,CAAC,OAAO,EAAE,SAAS,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,gBAAgB,CAAC,KAAK,MAAM,CAAC;IAE7E;;;OAGG;IACH,KAAK,EAAE,CAAC,OAAO,EAAE,SAAS,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,gBAAgB,CAAC,KAAK,MAAM,CAAC;IAE3E;;;OAGG;IACH,IAAI,EAAE,CAAC,OAAO,EAAE,SAAS,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,gBAAgB,CAAC,KAAK,MAAM,CAAC;IAE1E;;;OAGG;IACH,OAAO,EAAE,CAAC,OAAO,EAAE,SAAS,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,gBAAgB,CAAC,KAAK,MAAM,CAAC;IAE7E;;OAEG;IACH,WAAW,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;IAElC;;OAEG;IACH,WAAW,EAAE,MAAM,IAAI,CAAC;IAExB;;;;OAIG;IACH,YAAY,CAAC,EAAE,WAAW,GAAG,IAAI,CAAC;IAElC;;OAEG;IACH,gBAAgB,EAAE,cAAc,CAAC;IAEjC;;OAEG;IACH,WAAW,EAAE,IAAI,CAAC;IAElB;;OAEG;IACH,cAAc,EAAE,OAAO,CAAC;IAExB;;OAEG;IACH,aAAa,EAAE,MAAM,CAAC;IAEtB;;OAEG;IACH,eAAe,EAAE,OAAO,CAAC;CAC1B;AAID,eAAO,MAAM,YAAY,kDAA+C,CAAC;AAIzE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AACH,wBAAgB,QAAQ,qBAqBvB"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { createContext as e, useContext as o } from "react";
|
|
3
|
+
const a = e(null);
|
|
4
|
+
function n() {
|
|
5
|
+
const t = o(a);
|
|
6
|
+
return t || {
|
|
7
|
+
toasts: [],
|
|
8
|
+
toast: () => "",
|
|
9
|
+
success: () => "",
|
|
10
|
+
error: () => "",
|
|
11
|
+
info: () => "",
|
|
12
|
+
warning: () => "",
|
|
13
|
+
removeToast: () => {
|
|
14
|
+
},
|
|
15
|
+
clearToasts: () => {
|
|
16
|
+
},
|
|
17
|
+
portalTarget: null,
|
|
18
|
+
defaultPlacement: "top-right",
|
|
19
|
+
defaultSize: "md",
|
|
20
|
+
defaultVariant: "bordered",
|
|
21
|
+
defaultRadius: "md",
|
|
22
|
+
defaultAnimated: !0
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
export {
|
|
26
|
+
a as ToastContext,
|
|
27
|
+
n as useToast
|
|
28
|
+
};
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { ToastConfig } from './toast-config';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the ToastProvider component.
|
|
5
|
+
* Extends ToastConfig with children and className.
|
|
6
|
+
*/
|
|
7
|
+
export interface ToastProviderProps extends ToastConfig {
|
|
8
|
+
/**
|
|
9
|
+
* Child components to render.
|
|
10
|
+
*/
|
|
11
|
+
children: ReactNode;
|
|
12
|
+
/**
|
|
13
|
+
* Extra classes for the toast container.
|
|
14
|
+
*/
|
|
15
|
+
className?: string;
|
|
16
|
+
/**
|
|
17
|
+
* Custom portal target element.
|
|
18
|
+
* When portal is enabled, toasts are rendered into this element.
|
|
19
|
+
* Defaults to document.body.
|
|
20
|
+
*/
|
|
21
|
+
portalTarget?: HTMLElement | null;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Provider component for the toast notification system.
|
|
25
|
+
*
|
|
26
|
+
* ToastProvider wraps your application and provides toast notification
|
|
27
|
+
* functionality through the useToast hook. It manages the toast queue,
|
|
28
|
+
* rendering, and dismissal logic. Each toast can be customized with its
|
|
29
|
+
* own size, placement, variant, radius, and animation settings via the
|
|
30
|
+
* toast options.
|
|
31
|
+
*
|
|
32
|
+
* The provider uses React's createPortal to render toasts at the document
|
|
33
|
+
* body level by default. This ensures toasts escape CSS containment,
|
|
34
|
+
* stacking context, and overflow issues. Portaling can be disabled via
|
|
35
|
+
* the `portal` config option if the toasts need to stay within a specific
|
|
36
|
+
* parent container.
|
|
37
|
+
*
|
|
38
|
+
* @param props - ToastProvider configuration options.
|
|
39
|
+
* @param props.children - Child components.
|
|
40
|
+
* @param props.size - Default size scale of toasts. Defaults to "md".
|
|
41
|
+
* @param props.placement - Default placement of toasts. Defaults to "top-right".
|
|
42
|
+
* @param props.variant - Default visual style variant. Defaults to "bordered".
|
|
43
|
+
* @param props.radius - Default corner rounding. Defaults to "md".
|
|
44
|
+
* @param props.defaultTimeout - Default timeout in ms. Defaults to 3500.
|
|
45
|
+
* @param props.maxToasts - Maximum number of toasts. Defaults to 5.
|
|
46
|
+
* @param props.animated - Whether toasts have animations by default. Defaults to true.
|
|
47
|
+
* @param props.portal - Whether to render toasts in a portal. Defaults to true.
|
|
48
|
+
* @param props.portalTarget - Custom portal target element. Defaults to document.body.
|
|
49
|
+
* @param props.className - Extra classes for the toast container.
|
|
50
|
+
*
|
|
51
|
+
* @example
|
|
52
|
+
* ```tsx
|
|
53
|
+
* import { ToastProvider, useToast } from "asheeui";
|
|
54
|
+
*
|
|
55
|
+
* function App() {
|
|
56
|
+
* return (
|
|
57
|
+
* <ToastProvider>
|
|
58
|
+
* <MyComponent />
|
|
59
|
+
* </ToastProvider>
|
|
60
|
+
* );
|
|
61
|
+
* }
|
|
62
|
+
*
|
|
63
|
+
* function MyComponent() {
|
|
64
|
+
* const toast = useToast();
|
|
65
|
+
*
|
|
66
|
+
* return (
|
|
67
|
+
* <button onClick={() => toast.success("Operation successful!")}>
|
|
68
|
+
* Show Toast
|
|
69
|
+
* </button>
|
|
70
|
+
* );
|
|
71
|
+
* }
|
|
72
|
+
* ```
|
|
73
|
+
*
|
|
74
|
+
* @example
|
|
75
|
+
* ```tsx
|
|
76
|
+
* // Customizing individual toasts
|
|
77
|
+
* function MyComponent() {
|
|
78
|
+
* const toast = useToast();
|
|
79
|
+
*
|
|
80
|
+
* const showCustomToast = () => {
|
|
81
|
+
* toast.success("Custom toast!", {
|
|
82
|
+
* placement: "bottom-center",
|
|
83
|
+
* size: "lg",
|
|
84
|
+
* variant: "solid",
|
|
85
|
+
* radius: "full",
|
|
86
|
+
* animated: false,
|
|
87
|
+
* });
|
|
88
|
+
* };
|
|
89
|
+
*
|
|
90
|
+
* return <button onClick={showCustomToast}>Show Custom Toast</button>;
|
|
91
|
+
* }
|
|
92
|
+
* ```
|
|
93
|
+
*
|
|
94
|
+
* @see useToast - Hook for showing toast notifications.
|
|
95
|
+
* @see ToastConfig - The configuration type for the toast system.
|
|
96
|
+
*/
|
|
97
|
+
export declare function ToastProvider({ children, size, placement, variant, radius, defaultTimeout, maxToasts, animated, portal: portalProp, portalTarget: portalTargetProp, className, }: ToastProviderProps): import("react").JSX.Element;
|
|
98
|
+
//# sourceMappingURL=ToastProvider.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ToastProvider.d.ts","sourceRoot":"","sources":["../../../src/components/toast/ToastProvider.tsx"],"names":[],"mappings":"AAQA,OAAO,EAAE,KAAK,SAAS,EAAkC,MAAM,OAAO,CAAC;AAQvE,OAAO,EAEL,KAAK,WAAW,EAIjB,MAAM,gBAAgB,CAAC;AAKxB;;;GAGG;AACH,MAAM,WAAW,kBAAmB,SAAQ,WAAW;IACrD;;OAEG;IACH,QAAQ,EAAE,SAAS,CAAC;IAEpB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;;OAIG;IACH,YAAY,CAAC,EAAE,WAAW,GAAG,IAAI,CAAC;CACnC;AAID;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyEG;AACH,wBAAgB,aAAa,CAAC,EAC5B,QAAQ,EACR,IAAI,EACJ,SAAS,EACT,OAAO,EACP,MAAM,EACN,cAAc,EACd,SAAS,EACT,QAAQ,EACR,MAAM,EAAE,UAAU,EAClB,YAAY,EAAE,gBAAgB,EAC9B,SAAS,GACV,EAAE,kBAAkB,+BA6QpB"}
|
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as w, Fragment as g, jsxs as C } from "react/jsx-runtime";
|
|
3
|
+
import { useState as ee, useCallback as o, useMemo as E } from "react";
|
|
4
|
+
import { createPortal as ae } from "react-dom";
|
|
5
|
+
import { useAsheeConfig as te } from "../../libs/context.js";
|
|
6
|
+
import { resolveCascade as l, resolveRadiusKey as re } from "../../utils/resolve-token.js";
|
|
7
|
+
import { ToastContext as se } from "./ToastContext.js";
|
|
8
|
+
import { ToastItem as de } from "./ToastItem.js";
|
|
9
|
+
import { FALLBACK_TOAST_CONFIG as d } from "./toast-config.js";
|
|
10
|
+
import { PLACEMENT_CLASSES as oe } from "./toast-styles.js";
|
|
11
|
+
import { cn as le } from "../../utils/cn.js";
|
|
12
|
+
function ze({
|
|
13
|
+
children: F,
|
|
14
|
+
size: K,
|
|
15
|
+
placement: M,
|
|
16
|
+
variant: O,
|
|
17
|
+
radius: _,
|
|
18
|
+
defaultTimeout: B,
|
|
19
|
+
maxToasts: k,
|
|
20
|
+
animated: G,
|
|
21
|
+
portal: q,
|
|
22
|
+
portalTarget: H,
|
|
23
|
+
className: I
|
|
24
|
+
}) {
|
|
25
|
+
var R;
|
|
26
|
+
const [f, y] = ee([]), T = te(), a = (R = T.components) == null ? void 0 : R.toast, c = l(
|
|
27
|
+
K,
|
|
28
|
+
a == null ? void 0 : a.size,
|
|
29
|
+
void 0,
|
|
30
|
+
d.size
|
|
31
|
+
), n = l(
|
|
32
|
+
M,
|
|
33
|
+
a == null ? void 0 : a.placement,
|
|
34
|
+
void 0,
|
|
35
|
+
d.placement
|
|
36
|
+
), m = l(
|
|
37
|
+
O,
|
|
38
|
+
a == null ? void 0 : a.variant,
|
|
39
|
+
T.defaultVariant,
|
|
40
|
+
d.variant
|
|
41
|
+
), i = re(
|
|
42
|
+
_,
|
|
43
|
+
a == null ? void 0 : a.radius,
|
|
44
|
+
T.defaultRadius,
|
|
45
|
+
d.radius
|
|
46
|
+
), b = l(
|
|
47
|
+
k,
|
|
48
|
+
a == null ? void 0 : a.maxToasts,
|
|
49
|
+
void 0,
|
|
50
|
+
d.maxToasts
|
|
51
|
+
), z = l(
|
|
52
|
+
B,
|
|
53
|
+
a == null ? void 0 : a.defaultTimeout,
|
|
54
|
+
void 0,
|
|
55
|
+
d.defaultTimeout
|
|
56
|
+
), u = l(
|
|
57
|
+
G,
|
|
58
|
+
a == null ? void 0 : a.animated,
|
|
59
|
+
void 0,
|
|
60
|
+
d.animated
|
|
61
|
+
), J = l(
|
|
62
|
+
q,
|
|
63
|
+
a == null ? void 0 : a.portal,
|
|
64
|
+
void 0,
|
|
65
|
+
d.portal
|
|
66
|
+
), p = H ?? (typeof document < "u" ? document.body : null), x = o((e) => {
|
|
67
|
+
y((t) => t.filter((r) => r.id !== e));
|
|
68
|
+
}, []), j = o(() => {
|
|
69
|
+
y([]);
|
|
70
|
+
}, []), s = o(
|
|
71
|
+
(e) => {
|
|
72
|
+
var U;
|
|
73
|
+
const t = typeof e == "object" && e.id ? e.id : typeof window < "u" && ((U = window.crypto) != null && U.randomUUID) ? window.crypto.randomUUID() : String(Date.now()), r = typeof e == "object" && e.placement ? e.placement : n, v = typeof e == "object" && e.size ? e.size : c, V = typeof e == "object" && e.variant ? e.variant : m, L = typeof e == "object" && e.radius ? e.radius : i, N = typeof e == "object" && e.animated !== void 0 ? e.animated : u, X = typeof e == "string" ? {
|
|
74
|
+
id: t,
|
|
75
|
+
message: e,
|
|
76
|
+
timeout: z,
|
|
77
|
+
type: "info",
|
|
78
|
+
placement: r,
|
|
79
|
+
size: v,
|
|
80
|
+
variant: V,
|
|
81
|
+
radius: L,
|
|
82
|
+
animated: N
|
|
83
|
+
} : {
|
|
84
|
+
...e,
|
|
85
|
+
id: t,
|
|
86
|
+
timeout: e.timeout ?? z,
|
|
87
|
+
type: e.type ?? "info",
|
|
88
|
+
placement: e.placement ?? r,
|
|
89
|
+
size: e.size ?? v,
|
|
90
|
+
variant: e.variant ?? V,
|
|
91
|
+
radius: e.radius ?? L,
|
|
92
|
+
animated: e.animated !== void 0 ? e.animated : N
|
|
93
|
+
};
|
|
94
|
+
return y((Y) => {
|
|
95
|
+
const Z = Y.filter(($) => $.id !== t);
|
|
96
|
+
return [X, ...Z].slice(0, b);
|
|
97
|
+
}), t;
|
|
98
|
+
},
|
|
99
|
+
[
|
|
100
|
+
z,
|
|
101
|
+
b,
|
|
102
|
+
n,
|
|
103
|
+
c,
|
|
104
|
+
m,
|
|
105
|
+
i,
|
|
106
|
+
u
|
|
107
|
+
]
|
|
108
|
+
), A = o(
|
|
109
|
+
(e, t) => s({ ...t, message: e, type: "success" }),
|
|
110
|
+
[s]
|
|
111
|
+
), P = o(
|
|
112
|
+
(e, t) => s({ ...t, message: e, type: "error" }),
|
|
113
|
+
[s]
|
|
114
|
+
), S = o(
|
|
115
|
+
(e, t) => s({ ...t, message: e, type: "info" }),
|
|
116
|
+
[s]
|
|
117
|
+
), h = o(
|
|
118
|
+
(e, t) => s({ ...t, message: e, type: "warning" }),
|
|
119
|
+
[s]
|
|
120
|
+
), Q = E(
|
|
121
|
+
() => ({
|
|
122
|
+
toasts: f,
|
|
123
|
+
toast: s,
|
|
124
|
+
success: A,
|
|
125
|
+
error: P,
|
|
126
|
+
info: S,
|
|
127
|
+
warning: h,
|
|
128
|
+
removeToast: x,
|
|
129
|
+
clearToasts: j,
|
|
130
|
+
portalTarget: p,
|
|
131
|
+
defaultPlacement: n,
|
|
132
|
+
defaultSize: c,
|
|
133
|
+
defaultVariant: m,
|
|
134
|
+
defaultRadius: i,
|
|
135
|
+
defaultAnimated: u
|
|
136
|
+
}),
|
|
137
|
+
[
|
|
138
|
+
f,
|
|
139
|
+
s,
|
|
140
|
+
A,
|
|
141
|
+
P,
|
|
142
|
+
S,
|
|
143
|
+
h,
|
|
144
|
+
x,
|
|
145
|
+
j,
|
|
146
|
+
p,
|
|
147
|
+
n,
|
|
148
|
+
c,
|
|
149
|
+
m,
|
|
150
|
+
i,
|
|
151
|
+
u
|
|
152
|
+
]
|
|
153
|
+
), W = E(() => {
|
|
154
|
+
const e = {};
|
|
155
|
+
for (const t of f) {
|
|
156
|
+
const r = t.placement ?? n, v = e[r] ?? [];
|
|
157
|
+
e[r] = v, v.push(t);
|
|
158
|
+
}
|
|
159
|
+
return e;
|
|
160
|
+
}, [f, n]), D = /* @__PURE__ */ w(g, { children: Object.entries(W).map(([e, t]) => /* @__PURE__ */ w(
|
|
161
|
+
"section",
|
|
162
|
+
{
|
|
163
|
+
"aria-label": "Notifications",
|
|
164
|
+
className: le(
|
|
165
|
+
"fixed z-99999 flex flex-col gap-3 pointer-events-none p-4 max-h-screen overflow-clip",
|
|
166
|
+
oe[e],
|
|
167
|
+
I
|
|
168
|
+
),
|
|
169
|
+
children: t.map((r) => /* @__PURE__ */ w(
|
|
170
|
+
de,
|
|
171
|
+
{
|
|
172
|
+
...r,
|
|
173
|
+
onDismiss: x,
|
|
174
|
+
placement: e,
|
|
175
|
+
size: r.size ?? c,
|
|
176
|
+
variant: r.variant ?? m,
|
|
177
|
+
radius: r.radius ?? i,
|
|
178
|
+
animated: r.animated ?? u
|
|
179
|
+
},
|
|
180
|
+
r.id
|
|
181
|
+
))
|
|
182
|
+
},
|
|
183
|
+
e
|
|
184
|
+
)) });
|
|
185
|
+
return /* @__PURE__ */ C(se.Provider, { value: Q, children: [
|
|
186
|
+
F,
|
|
187
|
+
J && p ? ae(D, p) : D
|
|
188
|
+
] });
|
|
189
|
+
}
|
|
190
|
+
export {
|
|
191
|
+
ze as ToastProvider
|
|
192
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/toast/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/toast/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,aAAa,CAAC;AAC5B,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC"}
|
|
@@ -58,6 +58,31 @@ export interface ToastItemData {
|
|
|
58
58
|
* @default true
|
|
59
59
|
*/
|
|
60
60
|
dismissible?: boolean;
|
|
61
|
+
/**
|
|
62
|
+
* Placement for this specific toast.
|
|
63
|
+
* Overrides the provider's placement setting.
|
|
64
|
+
*/
|
|
65
|
+
placement?: ToastPlacement;
|
|
66
|
+
/**
|
|
67
|
+
* Size for this specific toast.
|
|
68
|
+
* Overrides the provider's size setting.
|
|
69
|
+
*/
|
|
70
|
+
size?: Size;
|
|
71
|
+
/**
|
|
72
|
+
* Variant for this specific toast.
|
|
73
|
+
* Overrides the provider's variant setting.
|
|
74
|
+
*/
|
|
75
|
+
variant?: Variant;
|
|
76
|
+
/**
|
|
77
|
+
* Radius for this specific toast.
|
|
78
|
+
* Overrides the provider's radius setting.
|
|
79
|
+
*/
|
|
80
|
+
radius?: Radius;
|
|
81
|
+
/**
|
|
82
|
+
* Animation setting for this specific toast.
|
|
83
|
+
* Overrides the provider's animated setting.
|
|
84
|
+
*/
|
|
85
|
+
animated?: boolean;
|
|
61
86
|
}
|
|
62
87
|
/**
|
|
63
88
|
* Theme configuration options for the Toast system.
|
|
@@ -124,6 +149,17 @@ export interface ToastConfig {
|
|
|
124
149
|
*/
|
|
125
150
|
portal?: boolean;
|
|
126
151
|
}
|
|
152
|
+
/**
|
|
153
|
+
* Options for showing a toast notification.
|
|
154
|
+
* Extends ToastItemData but makes id optional.
|
|
155
|
+
*/
|
|
156
|
+
export interface ToastShowOptions extends Omit<ToastItemData, "id"> {
|
|
157
|
+
/**
|
|
158
|
+
* Optional unique identifier for the toast.
|
|
159
|
+
* If not provided, a random ID is generated.
|
|
160
|
+
*/
|
|
161
|
+
id?: string;
|
|
162
|
+
}
|
|
127
163
|
/**
|
|
128
164
|
* Default config values registered for the Toast component.
|
|
129
165
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toast-config.d.ts","sourceRoot":"","sources":["../../../src/components/toast/toast-config.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,OAAO,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAE1D;;;GAGG;AACH,MAAM,MAAM,SAAS,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,GAAG,SAAS,CAAC;AAE7E;;;GAGG;AACH,MAAM,MAAM,cAAc,GACtB,WAAW,GACX,UAAU,GACV,cAAc,GACd,aAAa,GACb,YAAY,GACZ,eAAe,CAAC;AAEpB;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX;;;OAGG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC;IAElB;;OAEG;IACH,OAAO,EAAE,SAAS,CAAC;IAEnB;;;;;OAKG;IACH,IAAI,CAAC,EAAE,SAAS,CAAC;IAEjB;;;;;OAKG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;;OAGG;IACH,IAAI,CAAC,EAAE,SAAS,CAAC;IAEjB;;;OAGG;IACH,MAAM,CAAC,EAAE,SAAS,CAAC;IAEnB;;;;;OAKG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"toast-config.d.ts","sourceRoot":"","sources":["../../../src/components/toast/toast-config.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,OAAO,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAE1D;;;GAGG;AACH,MAAM,MAAM,SAAS,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,GAAG,SAAS,CAAC;AAE7E;;;GAGG;AACH,MAAM,MAAM,cAAc,GACtB,WAAW,GACX,UAAU,GACV,cAAc,GACd,aAAa,GACb,YAAY,GACZ,eAAe,CAAC;AAEpB;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX;;;OAGG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC;IAElB;;OAEG;IACH,OAAO,EAAE,SAAS,CAAC;IAEnB;;;;;OAKG;IACH,IAAI,CAAC,EAAE,SAAS,CAAC;IAEjB;;;;;OAKG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;;OAGG;IACH,IAAI,CAAC,EAAE,SAAS,CAAC;IAEjB;;;OAGG;IACH,MAAM,CAAC,EAAE,SAAS,CAAC;IAEnB;;;;;OAKG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IAEtB;;;OAGG;IACH,SAAS,CAAC,EAAE,cAAc,CAAC;IAE3B;;;OAGG;IACH,IAAI,CAAC,EAAE,IAAI,CAAC;IAEZ;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED;;;;;GAKG;AACH,MAAM,WAAW,WAAW;IAC1B;;;;;OAKG;IACH,IAAI,CAAC,EAAE,IAAI,CAAC;IAEZ;;;;;OAKG;IACH,SAAS,CAAC,EAAE,cAAc,CAAC;IAE3B;;;;;OAKG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;;OAIG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB;;;;;OAKG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB;;;;;OAKG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;;;;;;OAQG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AAED;;;GAGG;AACH,MAAM,WAAW,gBAAiB,SAAQ,IAAI,CAAC,aAAa,EAAE,IAAI,CAAC;IACjE;;;OAGG;IACH,EAAE,CAAC,EAAE,MAAM,CAAC;CACb;AAED;;GAEG;AACH,eAAO,MAAM,kBAAkB,EAAE,WAShC,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,qBAAqB;mBAClB,IAAI;wBACQ,cAAc;sBACpB,OAAO;qBACX,MAAM;;;;;CAKd,CAAC;AAEX,OAAO,QAAQ,qBAAqB,CAAC;IACnC,UAAU,2BAA2B;QACnC,KAAK,EAAE,WAAW,CAAC;KACpB;CACF"}
|
|
@@ -15,6 +15,14 @@ export declare const TOAST_PADDING_CLASS: Record<Size, string>;
|
|
|
15
15
|
* Maps size keys to Tailwind text size classes.
|
|
16
16
|
*/
|
|
17
17
|
export declare const TOAST_FONT_CLASS: Record<Size, string>;
|
|
18
|
+
/**
|
|
19
|
+
* CSS classes for toast container placement on screen.
|
|
20
|
+
* Maps each placement to its fixed-position corner/edge classes and
|
|
21
|
+
* flex alignment (items-*), which controls the stacking edge for
|
|
22
|
+
* multiple toasts at that placement. Used by ToastProvider to position
|
|
23
|
+
* the per-placement container sections.
|
|
24
|
+
*/
|
|
25
|
+
export declare const PLACEMENT_CLASSES: Record<ToastPlacement, string>;
|
|
18
26
|
/**
|
|
19
27
|
* CSS classes for toast title font size.
|
|
20
28
|
* Maps size keys to Tailwind text size and weight classes.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toast-styles.d.ts","sourceRoot":"","sources":["../../../src/components/toast/toast-styles.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAErD;;;GAGG;AACH,eAAO,MAAM,iBAAiB,EAAE,MAAM,CAAC,IAAI,EAAE,MAAM,CAIlD,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,mBAAmB,EAAE,MAAM,CAAC,IAAI,EAAE,MAAM,CAIpD,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,IAAI,EAAE,MAAM,CAIjD,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,sBAAsB,EAAE,MAAM,CAAC,IAAI,EAAE,MAAM,CAIvD,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,EAAE,MAAM,CACxC,cAAc,EACd;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CA0BhC,CAAC"}
|
|
1
|
+
{"version":3,"file":"toast-styles.d.ts","sourceRoot":"","sources":["../../../src/components/toast/toast-styles.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAErD;;;GAGG;AACH,eAAO,MAAM,iBAAiB,EAAE,MAAM,CAAC,IAAI,EAAE,MAAM,CAIlD,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,mBAAmB,EAAE,MAAM,CAAC,IAAI,EAAE,MAAM,CAIpD,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,IAAI,EAAE,MAAM,CAIjD,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,iBAAiB,EAAE,MAAM,CAAC,cAAc,EAAE,MAAM,CAO5D,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,sBAAsB,EAAE,MAAM,CAAC,IAAI,EAAE,MAAM,CAIvD,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,EAAE,MAAM,CACxC,cAAc,EACd;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CA0BhC,CAAC"}
|
|
@@ -12,10 +12,17 @@ const t = {
|
|
|
12
12
|
md: "text-sm",
|
|
13
13
|
lg: "text-base"
|
|
14
14
|
}, s = {
|
|
15
|
+
"top-right": "top-0 right-0 items-end",
|
|
16
|
+
"top-left": "top-0 left-0 items-start",
|
|
17
|
+
"bottom-right": "bottom-0 right-0 items-end",
|
|
18
|
+
"bottom-left": "bottom-0 left-0 items-start",
|
|
19
|
+
"top-center": "top-0 left-1/2 -translate-x-1/2 items-center",
|
|
20
|
+
"bottom-center": "bottom-0 left-1/2 -translate-x-1/2 items-center"
|
|
21
|
+
}, m = {
|
|
15
22
|
sm: "text-xs font-semibold",
|
|
16
23
|
md: "text-sm font-semibold",
|
|
17
24
|
lg: "text-base font-semibold"
|
|
18
|
-
},
|
|
25
|
+
}, r = {
|
|
19
26
|
"top-right": {
|
|
20
27
|
enter: "toast-enter-top-right",
|
|
21
28
|
exit: "toast-exit-top-right"
|
|
@@ -42,9 +49,10 @@ const t = {
|
|
|
42
49
|
}
|
|
43
50
|
};
|
|
44
51
|
export {
|
|
45
|
-
|
|
52
|
+
s as PLACEMENT_CLASSES,
|
|
53
|
+
r as TOAST_ANIMATION_STATE,
|
|
46
54
|
o as TOAST_FONT_CLASS,
|
|
47
55
|
e as TOAST_PADDING_CLASS,
|
|
48
|
-
|
|
56
|
+
m as TOAST_TITLE_FONT_CLASS,
|
|
49
57
|
t as TOAST_WIDTH_CLASS
|
|
50
58
|
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ChevronUpIcon.d.ts","sourceRoot":"","sources":["../../src/icons/ChevronUpIcon.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAEzC,wBAAgB,aAAa,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,SAAS,+BAa/D"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
3
|
+
import { cn as o } from "../utils/cn.js";
|
|
4
|
+
function s({ className: e, ...n }) {
|
|
5
|
+
return /* @__PURE__ */ r(
|
|
6
|
+
"svg",
|
|
7
|
+
{
|
|
8
|
+
"aria-hidden": "true",
|
|
9
|
+
className: o("w-4 h-4 fill-none stroke-current", e),
|
|
10
|
+
viewBox: "0 0 24 24",
|
|
11
|
+
strokeWidth: "2",
|
|
12
|
+
strokeLinecap: "round",
|
|
13
|
+
strokeLinejoin: "round",
|
|
14
|
+
...n,
|
|
15
|
+
children: /* @__PURE__ */ r("path", { d: "m18 15-6-6-6 6" })
|
|
16
|
+
}
|
|
17
|
+
);
|
|
18
|
+
}
|
|
19
|
+
export {
|
|
20
|
+
s as ChevronUpIcon
|
|
21
|
+
};
|
package/dist/icons/index.d.ts
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
export { ArrowLeftIcon } from './ArrowLeftIcon';
|
|
2
2
|
export { CalendarIcon } from './CalendarIcon';
|
|
3
3
|
export { CheckIcon } from './CheckIcon';
|
|
4
|
+
export { ChevronDownIcon } from './ChevronDownIcon';
|
|
4
5
|
export { ChevronLeftIcon } from './ChevronLeftIcon';
|
|
5
6
|
export { ChevronRightIcon } from './ChevronRightIcon';
|
|
7
|
+
export { ChevronUpIcon } from './ChevronUpIcon';
|
|
6
8
|
export { ClearIcon } from './ClearIcon';
|
|
7
9
|
export { ClockIcon } from './ClockIcon';
|
|
8
10
|
export { CloseIcon } from './CloseIcon';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/icons/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,YAAY,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/icons/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,YAAY,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC"}
|