@causw/core 0.0.14 → 0.0.16
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/Avatar/Avatar.d.cts +3 -2
- package/dist/components/Avatar/Avatar.d.cts.map +1 -1
- package/dist/components/Avatar/Avatar.d.mts +2 -2
- package/dist/components/Avatar/Avatar.styles.d.cts +3 -3
- package/dist/components/Avatar/Avatar.styles.d.mts +3 -3
- package/dist/components/Avatar/index.d.cts +2 -0
- package/dist/components/BottomNavigation/BottomNavigation.d.cts +6 -5
- package/dist/components/BottomNavigation/BottomNavigation.d.cts.map +1 -1
- package/dist/components/BottomNavigation/BottomNavigation.d.mts +5 -5
- package/dist/components/BottomNavigation/BottomNavigation.styles.d.mts +3 -3
- package/dist/components/BottomNavigation/index.d.cts +1 -0
- package/dist/components/BottomSheet/BottomSheet.d.cts +6 -6
- package/dist/components/BottomSheet/BottomSheet.d.mts +6 -6
- package/dist/components/BottomSheet/BottomSheet.styles.d.cts +3 -3
- package/dist/components/BottomSheet/BottomSheet.styles.d.mts +3 -3
- package/dist/components/BottomSheet/index.d.cts +1 -0
- package/dist/components/Box/Box.d.cts +1 -0
- package/dist/components/Box/Box.d.cts.map +1 -1
- package/dist/components/Box/Box.styles.d.mts +3 -3
- package/dist/components/Box/index.d.cts +2 -0
- package/dist/components/Button/Button.d.cts +3 -2
- package/dist/components/Button/Button.d.cts.map +1 -1
- package/dist/components/Button/Button.d.mts +2 -2
- package/dist/components/Button/Button.d.mts.map +1 -1
- package/dist/components/Button/Button.styles.cjs +1 -1
- package/dist/components/Button/Button.styles.d.cts +5 -5
- package/dist/components/Button/Button.styles.d.mts +5 -5
- package/dist/components/Button/Button.styles.mjs +1 -1
- package/dist/components/Button/Button.styles.mjs.map +1 -1
- package/dist/components/Button/index.d.cts +1 -0
- package/dist/components/CTAButton/CTAButton.d.cts +3 -2
- package/dist/components/CTAButton/CTAButton.d.cts.map +1 -1
- package/dist/components/CTAButton/CTAButton.d.mts +2 -2
- package/dist/components/CTAButton/CTAButton.styles.cjs +1 -1
- package/dist/components/CTAButton/CTAButton.styles.d.cts +5 -5
- package/dist/components/CTAButton/CTAButton.styles.d.mts +5 -5
- package/dist/components/CTAButton/CTAButton.styles.mjs +1 -1
- package/dist/components/CTAButton/CTAButton.styles.mjs.map +1 -1
- package/dist/components/CTAButton/index.d.cts +1 -0
- package/dist/components/Calendar/Calendar.d.cts +2 -2
- package/dist/components/Calendar/Calendar.d.mts +2 -2
- package/dist/components/Calendar/Calendar.styles.d.cts +3 -3
- package/dist/components/Calendar/Calendar.styles.d.mts +3 -3
- package/dist/components/Checkbox/Checkbox.d.cts +6 -4
- package/dist/components/Checkbox/Checkbox.d.cts.map +1 -1
- package/dist/components/Checkbox/Checkbox.d.mts +4 -4
- package/dist/components/Checkbox/Checkbox.d.mts.map +1 -1
- package/dist/components/Checkbox/Checkbox.styles.d.cts +3 -3
- package/dist/components/Checkbox/Checkbox.styles.d.mts +3 -3
- package/dist/components/Checkbox/index.d.cts +1 -0
- package/dist/components/Chip/Chip.d.cts +3 -2
- package/dist/components/Chip/Chip.d.cts.map +1 -1
- package/dist/components/Chip/Chip.styles.cjs +1 -1
- package/dist/components/Chip/Chip.styles.d.cts +3 -3
- package/dist/components/Chip/Chip.styles.mjs +1 -1
- package/dist/components/Chip/Chip.styles.mjs.map +1 -1
- package/dist/components/Chip/index.d.cts +2 -0
- package/dist/components/Dialog/Dialog.d.cts +1 -0
- package/dist/components/Dialog/Dialog.d.cts.map +1 -1
- package/dist/components/Dialog/index.d.cts +2 -0
- package/dist/components/Drawer/Drawer.d.cts +11 -11
- package/dist/components/Drawer/Drawer.d.mts +3 -3
- package/dist/components/Drawer/Drawer.styles.d.cts +3 -3
- package/dist/components/Drawer/Drawer.styles.d.mts +3 -3
- package/dist/components/Drawer/index.d.cts +1 -0
- package/dist/components/Dropdown/index.d.cts +2 -0
- package/dist/components/Field/Field.d.cts +6 -5
- package/dist/components/Field/Field.d.cts.map +1 -1
- package/dist/components/Field/index.d.cts +1 -0
- package/dist/components/Flex/Flex.d.cts +1 -0
- package/dist/components/Flex/Flex.d.cts.map +1 -1
- package/dist/components/Flex/index.d.cts +2 -0
- package/dist/components/Float/Float.d.cts +1 -0
- package/dist/components/Float/Float.d.cts.map +1 -1
- package/dist/components/Float/index.d.cts +1 -0
- package/dist/components/FloatingActionButton/FloatingActionButton.d.cts +3 -2
- package/dist/components/FloatingActionButton/FloatingActionButton.d.cts.map +1 -1
- package/dist/components/FloatingActionButton/FloatingActionButton.d.mts +2 -2
- package/dist/components/FloatingActionButton/index.d.cts +1 -0
- package/dist/components/Grid/Grid.d.cts +1 -0
- package/dist/components/Grid/Grid.d.cts.map +1 -1
- package/dist/components/Grid/index.d.cts +1 -0
- package/dist/components/HStack/HStack.d.cts +1 -0
- package/dist/components/HStack/HStack.d.cts.map +1 -1
- package/dist/components/HStack/HStack.d.mts +2 -2
- package/dist/components/HStack/index.d.cts +1 -0
- package/dist/components/Modal/Modal.cjs +4 -7
- package/dist/components/Modal/Modal.d.cts +14 -15
- package/dist/components/Modal/Modal.d.cts.map +1 -1
- package/dist/components/Modal/Modal.d.mts +4 -6
- package/dist/components/Modal/Modal.d.mts.map +1 -1
- package/dist/components/Modal/Modal.mjs +4 -7
- package/dist/components/Modal/Modal.mjs.map +1 -1
- package/dist/components/Modal/Modal.styles.cjs +15 -26
- package/dist/components/Modal/Modal.styles.d.cts +3 -39
- package/dist/components/Modal/Modal.styles.d.cts.map +1 -1
- package/dist/components/Modal/Modal.styles.d.mts +0 -36
- package/dist/components/Modal/Modal.styles.d.mts.map +1 -1
- package/dist/components/Modal/Modal.styles.mjs +15 -26
- package/dist/components/Modal/Modal.styles.mjs.map +1 -1
- package/dist/components/Modal/index.d.cts +2 -0
- package/dist/components/Primitive/Primitive.d.cts +16 -16
- package/dist/components/Primitive/index.d.cts +1 -0
- package/dist/components/PullToRefresh/PullToRefresh.cjs +79 -0
- package/dist/components/PullToRefresh/PullToRefresh.d.cts +20 -0
- package/dist/components/PullToRefresh/PullToRefresh.d.cts.map +1 -0
- package/dist/components/PullToRefresh/PullToRefresh.d.mts +20 -0
- package/dist/components/PullToRefresh/PullToRefresh.d.mts.map +1 -0
- package/dist/components/PullToRefresh/PullToRefresh.mjs +78 -0
- package/dist/components/PullToRefresh/PullToRefresh.mjs.map +1 -0
- package/dist/components/PullToRefresh/PullToRefresh.styles.cjs +12 -0
- package/dist/components/PullToRefresh/PullToRefresh.styles.d.cts +46 -0
- package/dist/components/PullToRefresh/PullToRefresh.styles.d.cts.map +1 -0
- package/dist/components/PullToRefresh/PullToRefresh.styles.d.mts +46 -0
- package/dist/components/PullToRefresh/PullToRefresh.styles.d.mts.map +1 -0
- package/dist/components/PullToRefresh/PullToRefresh.styles.mjs +12 -0
- package/dist/components/PullToRefresh/PullToRefresh.styles.mjs.map +1 -0
- package/dist/components/PullToRefresh/index.d.cts +1 -0
- package/dist/components/PullToRefresh/index.d.mts +1 -0
- package/dist/components/Radio/Radio.d.cts +4 -3
- package/dist/components/Radio/Radio.d.cts.map +1 -1
- package/dist/components/Radio/Radio.d.mts +3 -3
- package/dist/components/Radio/index.d.cts +1 -0
- package/dist/components/RatioChart/RatioChart.d.mts +5 -5
- package/dist/components/RatioChart/RatioChartEditor.d.mts +2 -2
- package/dist/components/RatioChart/index.d.cts +2 -0
- package/dist/components/Select/Select.d.mts +5 -5
- package/dist/components/Select/index.d.cts +2 -0
- package/dist/components/Separator/Separator.d.cts +1 -0
- package/dist/components/Separator/Separator.d.cts.map +1 -1
- package/dist/components/Separator/Separator.styles.d.mts +3 -3
- package/dist/components/Separator/index.d.cts +2 -0
- package/dist/components/Sidebar/Sidebar.d.cts +9 -8
- package/dist/components/Sidebar/Sidebar.d.cts.map +1 -1
- package/dist/components/Sidebar/Sidebar.d.mts +8 -8
- package/dist/components/Sidebar/Sidebar.styles.d.cts +3 -3
- package/dist/components/Sidebar/hooks/useSidebarContext.d.cts +2 -0
- package/dist/components/Sidebar/hooks/useSidebarContext.d.cts.map +1 -1
- package/dist/components/Sidebar/index.d.cts +2 -0
- package/dist/components/Skeleton/Skeleton.cjs +34 -0
- package/dist/components/Skeleton/Skeleton.d.cts +25 -0
- package/dist/components/Skeleton/Skeleton.d.cts.map +1 -0
- package/dist/components/Skeleton/Skeleton.d.mts +25 -0
- package/dist/components/Skeleton/Skeleton.d.mts.map +1 -0
- package/dist/components/Skeleton/Skeleton.mjs +33 -0
- package/dist/components/Skeleton/Skeleton.mjs.map +1 -0
- package/dist/components/Skeleton/Skeleton.styles.cjs +40 -0
- package/dist/components/Skeleton/Skeleton.styles.d.cts +50 -0
- package/dist/components/Skeleton/Skeleton.styles.d.cts.map +1 -0
- package/dist/components/Skeleton/Skeleton.styles.d.mts +50 -0
- package/dist/components/Skeleton/Skeleton.styles.d.mts.map +1 -0
- package/dist/components/Skeleton/Skeleton.styles.mjs +39 -0
- package/dist/components/Skeleton/Skeleton.styles.mjs.map +1 -0
- package/dist/components/Skeleton/index.d.cts +1 -0
- package/dist/components/Skeleton/index.d.mts +1 -0
- package/dist/components/Spacer/Spacer.d.cts +1 -0
- package/dist/components/Spacer/Spacer.d.cts.map +1 -1
- package/dist/components/Spacer/Spacer.styles.d.mts +3 -3
- package/dist/components/Spacer/index.d.cts +2 -0
- package/dist/components/Spinner/Spinner.cjs +38 -0
- package/dist/components/Spinner/Spinner.d.cts +17 -0
- package/dist/components/Spinner/Spinner.d.cts.map +1 -0
- package/dist/components/Spinner/Spinner.d.mts +17 -0
- package/dist/components/Spinner/Spinner.d.mts.map +1 -0
- package/dist/components/Spinner/Spinner.mjs +37 -0
- package/dist/components/Spinner/Spinner.mjs.map +1 -0
- package/dist/components/Spinner/Spinner.styles.cjs +34 -0
- package/dist/components/Spinner/Spinner.styles.d.cts +63 -0
- package/dist/components/Spinner/Spinner.styles.d.cts.map +1 -0
- package/dist/components/Spinner/Spinner.styles.d.mts +63 -0
- package/dist/components/Spinner/Spinner.styles.d.mts.map +1 -0
- package/dist/components/Spinner/Spinner.styles.mjs +34 -0
- package/dist/components/Spinner/Spinner.styles.mjs.map +1 -0
- package/dist/components/Spinner/index.d.mts +1 -0
- package/dist/components/Stack/Stack.d.cts +1 -0
- package/dist/components/Stack/Stack.d.cts.map +1 -1
- package/dist/components/Stack/Stack.styles.d.mts +3 -3
- package/dist/components/Stack/index.d.cts +2 -0
- package/dist/components/Tab/Tab.d.cts +7 -6
- package/dist/components/Tab/Tab.d.cts.map +1 -1
- package/dist/components/Tab/Tab.d.mts +6 -6
- package/dist/components/Tab/Tab.styles.d.cts +3 -3
- package/dist/components/Tab/Tab.styles.d.mts +3 -3
- package/dist/components/Tab/index.d.cts +2 -0
- package/dist/components/Text/Text.d.cts +2 -1
- package/dist/components/Text/Text.d.cts.map +1 -1
- package/dist/components/Text/Text.d.mts +1 -1
- package/dist/components/Text/Text.styles.d.mts +3 -3
- package/dist/components/Text/index.d.cts +2 -0
- package/dist/components/TextArea/TextArea.d.cts +5 -4
- package/dist/components/TextArea/TextArea.d.cts.map +1 -1
- package/dist/components/TextArea/TextArea.d.mts +4 -4
- package/dist/components/TextArea/TextArea.d.mts.map +1 -1
- package/dist/components/TextArea/TextArea.styles.d.mts +3 -3
- package/dist/components/TextArea/index.d.cts +1 -0
- package/dist/components/TextInput/TextInput.d.cts +3 -2
- package/dist/components/TextInput/TextInput.d.cts.map +1 -1
- package/dist/components/TextInput/TextInput.styles.d.mts +3 -3
- package/dist/components/TextInput/index.d.cts +2 -0
- package/dist/components/Toast/Toast.d.cts +3 -3
- package/dist/components/Toast/Toast.d.mts +3 -3
- package/dist/components/Toast/Toast.styles.d.cts +3 -3
- package/dist/components/Toast/Toast.styles.d.mts +3 -3
- package/dist/components/Toast/index.d.cts +3 -0
- package/dist/components/Toast/index.d.mts +2 -1
- package/dist/components/Toast/toastStore.cjs +38 -0
- package/dist/components/Toast/toastStore.d.cts +19 -0
- package/dist/components/Toast/toastStore.d.cts.map +1 -0
- package/dist/components/Toast/toastStore.d.mts +19 -0
- package/dist/components/Toast/toastStore.d.mts.map +1 -0
- package/dist/components/Toast/toastStore.mjs +39 -0
- package/dist/components/Toast/toastStore.mjs.map +1 -0
- package/dist/components/Toggle/Toggle.d.cts +6 -4
- package/dist/components/Toggle/Toggle.d.cts.map +1 -1
- package/dist/components/Toggle/Toggle.d.mts +4 -4
- package/dist/components/Toggle/Toggle.styles.d.cts +3 -3
- package/dist/components/Toggle/Toggle.styles.d.mts +3 -3
- package/dist/components/Toggle/index.d.cts +1 -0
- package/dist/components/VStack/VStack.d.cts +1 -0
- package/dist/components/VStack/VStack.d.cts.map +1 -1
- package/dist/components/VStack/VStack.d.mts +2 -2
- package/dist/components/VStack/index.d.cts +1 -0
- package/dist/components/index.d.cts +90 -0
- package/dist/components/index.d.mts +8 -1
- package/dist/index.cjs +8 -0
- package/dist/index.d.cts +7 -1
- package/dist/index.d.mts +5 -1
- package/dist/index.mjs +5 -1
- package/dist/utils/index.d.cts +5 -0
- package/dist/utils/polymorphic/index.d.cts +1 -0
- package/package.json +2 -2
- package/src/styles/global.css +32 -0
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as tailwind_variants19 from "tailwind-variants";
|
|
2
2
|
import { VariantProps } from "tailwind-variants";
|
|
3
3
|
|
|
4
4
|
//#region src/components/Toast/Toast.styles.d.ts
|
|
5
|
-
declare const toast:
|
|
5
|
+
declare const toast: tailwind_variants19.TVReturnType<{
|
|
6
6
|
variant: {
|
|
7
7
|
default: {
|
|
8
8
|
root: string;
|
|
@@ -20,7 +20,7 @@ declare const toast: tailwind_variants23.TVReturnType<{
|
|
|
20
20
|
}, {
|
|
21
21
|
root: string[];
|
|
22
22
|
viewport: string[];
|
|
23
|
-
},
|
|
23
|
+
}, tailwind_variants19.TVReturnType<{
|
|
24
24
|
variant: {
|
|
25
25
|
default: {
|
|
26
26
|
root: string;
|
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
import { ToastVariants } from "./Toast.styles.mjs";
|
|
2
|
-
import { Toast, ToastProps, ToastProvider, ToastViewport, ToastViewportProps } from "./Toast.mjs";
|
|
2
|
+
import { Toast, ToastProps, ToastProvider, ToastViewport, ToastViewportProps } from "./Toast.mjs";
|
|
3
|
+
import { toast } from "./toastStore.mjs";
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
let react = require("react");
|
|
2
|
+
|
|
3
|
+
//#region src/components/Toast/toastStore.ts
|
|
4
|
+
let memoryState = [];
|
|
5
|
+
let listeners = [];
|
|
6
|
+
const notify = () => listeners.forEach((l) => l());
|
|
7
|
+
let count = 0;
|
|
8
|
+
const genId = () => {
|
|
9
|
+
count = (count + 1) % Number.MAX_SAFE_INTEGER;
|
|
10
|
+
return count.toString();
|
|
11
|
+
};
|
|
12
|
+
const dispatch = (message, type, options) => {
|
|
13
|
+
const id = genId();
|
|
14
|
+
memoryState = [{
|
|
15
|
+
id,
|
|
16
|
+
message,
|
|
17
|
+
type,
|
|
18
|
+
...options
|
|
19
|
+
}];
|
|
20
|
+
notify();
|
|
21
|
+
return id;
|
|
22
|
+
};
|
|
23
|
+
const toastRoot = (message, options) => dispatch(message, "default", options);
|
|
24
|
+
const toast = Object.assign(toastRoot, {
|
|
25
|
+
success: (message, options) => dispatch(message, "success", options),
|
|
26
|
+
error: (message, options) => dispatch(message, "error", options),
|
|
27
|
+
loading: (message, options) => dispatch(message, "loading", {
|
|
28
|
+
...options,
|
|
29
|
+
duration: options?.duration ?? 1e5
|
|
30
|
+
}),
|
|
31
|
+
dismiss: (id) => {
|
|
32
|
+
memoryState = memoryState.filter((t) => t.id !== id);
|
|
33
|
+
notify();
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
|
|
37
|
+
//#endregion
|
|
38
|
+
exports.toast = toast;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
//#region src/components/Toast/toastStore.d.ts
|
|
2
|
+
type ToastType = 'default' | 'success' | 'error' | 'loading';
|
|
3
|
+
interface ToastData {
|
|
4
|
+
id: string;
|
|
5
|
+
message: string;
|
|
6
|
+
type: ToastType;
|
|
7
|
+
duration?: number;
|
|
8
|
+
icon?: React.ReactNode;
|
|
9
|
+
}
|
|
10
|
+
type ToastOptions = Omit<ToastData, 'id' | 'message' | 'type'>;
|
|
11
|
+
declare const toast: ((message: string, options?: ToastOptions) => string) & {
|
|
12
|
+
success: (message: string, options?: ToastOptions) => string;
|
|
13
|
+
error: (message: string, options?: ToastOptions) => string;
|
|
14
|
+
loading: (message: string, options?: ToastOptions) => string;
|
|
15
|
+
dismiss: (id: string) => void;
|
|
16
|
+
};
|
|
17
|
+
//#endregion
|
|
18
|
+
export { toast };
|
|
19
|
+
//# sourceMappingURL=toastStore.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toastStore.d.cts","names":[],"sources":["../../../src/components/Toast/toastStore.ts"],"mappings":";KAEY,SAAA;AAAA,UAEK,SAAA;EACf,EAAA;EACA,OAAA;EACA,IAAA,EAAM,SAAA;EACN,QAAA;EACA,IAAA,GAAO,KAAA,CAAM,SAAA;AAAA;AAAA,KAGV,YAAA,GAAe,IAAA,CAAK,SAAA;AAAA,cAoCZ,KAAA,IAAK,OAAA,UAHgB,OAAA,GAAY,YAAA;6BAInB,OAAA,GAAY,YAAA;2BAEd,OAAA,GAAY,YAAA;6BAEV,OAAA,GAAY,YAAA"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
//#region src/components/Toast/toastStore.d.ts
|
|
2
|
+
type ToastType = 'default' | 'success' | 'error' | 'loading';
|
|
3
|
+
interface ToastData {
|
|
4
|
+
id: string;
|
|
5
|
+
message: string;
|
|
6
|
+
type: ToastType;
|
|
7
|
+
duration?: number;
|
|
8
|
+
icon?: React.ReactNode;
|
|
9
|
+
}
|
|
10
|
+
type ToastOptions = Omit<ToastData, 'id' | 'message' | 'type'>;
|
|
11
|
+
declare const toast: ((message: string, options?: ToastOptions) => string) & {
|
|
12
|
+
success: (message: string, options?: ToastOptions) => string;
|
|
13
|
+
error: (message: string, options?: ToastOptions) => string;
|
|
14
|
+
loading: (message: string, options?: ToastOptions) => string;
|
|
15
|
+
dismiss: (id: string) => void;
|
|
16
|
+
};
|
|
17
|
+
//#endregion
|
|
18
|
+
export { toast };
|
|
19
|
+
//# sourceMappingURL=toastStore.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toastStore.d.mts","names":[],"sources":["../../../src/components/Toast/toastStore.ts"],"mappings":";KAEY,SAAA;AAAA,UAEK,SAAA;EACf,EAAA;EACA,OAAA;EACA,IAAA,EAAM,SAAA;EACN,QAAA;EACA,IAAA,GAAO,KAAA,CAAM,SAAA;AAAA;AAAA,KAGV,YAAA,GAAe,IAAA,CAAK,SAAA;AAAA,cAoCZ,KAAA,IAAK,OAAA,UAHgB,OAAA,GAAY,YAAA;6BAInB,OAAA,GAAY,YAAA;2BAEd,OAAA,GAAY,YAAA;6BAEV,OAAA,GAAY,YAAA"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import "react";
|
|
2
|
+
|
|
3
|
+
//#region src/components/Toast/toastStore.ts
|
|
4
|
+
let memoryState = [];
|
|
5
|
+
let listeners = [];
|
|
6
|
+
const notify = () => listeners.forEach((l) => l());
|
|
7
|
+
let count = 0;
|
|
8
|
+
const genId = () => {
|
|
9
|
+
count = (count + 1) % Number.MAX_SAFE_INTEGER;
|
|
10
|
+
return count.toString();
|
|
11
|
+
};
|
|
12
|
+
const dispatch = (message, type, options) => {
|
|
13
|
+
const id = genId();
|
|
14
|
+
memoryState = [{
|
|
15
|
+
id,
|
|
16
|
+
message,
|
|
17
|
+
type,
|
|
18
|
+
...options
|
|
19
|
+
}];
|
|
20
|
+
notify();
|
|
21
|
+
return id;
|
|
22
|
+
};
|
|
23
|
+
const toastRoot = (message, options) => dispatch(message, "default", options);
|
|
24
|
+
const toast = Object.assign(toastRoot, {
|
|
25
|
+
success: (message, options) => dispatch(message, "success", options),
|
|
26
|
+
error: (message, options) => dispatch(message, "error", options),
|
|
27
|
+
loading: (message, options) => dispatch(message, "loading", {
|
|
28
|
+
...options,
|
|
29
|
+
duration: options?.duration ?? 1e5
|
|
30
|
+
}),
|
|
31
|
+
dismiss: (id) => {
|
|
32
|
+
memoryState = memoryState.filter((t) => t.id !== id);
|
|
33
|
+
notify();
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
|
|
37
|
+
//#endregion
|
|
38
|
+
export { toast };
|
|
39
|
+
//# sourceMappingURL=toastStore.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toastStore.mjs","names":[],"sources":["../../../src/components/Toast/toastStore.ts"],"sourcesContent":["import { useSyncExternalStore } from 'react';\n\nexport type ToastType = 'default' | 'success' | 'error' | 'loading';\n\nexport interface ToastData {\n id: string;\n message: string;\n type: ToastType;\n duration?: number;\n icon?: React.ReactNode;\n}\n\ntype ToastOptions = Omit<ToastData, 'id' | 'message' | 'type'>;\n\nlet memoryState: ToastData[] = [];\nlet listeners: Array<() => void> = [];\nconst notify = () => listeners.forEach((l) => l());\n\nlet count = 0;\nconst genId = () => {\n count = (count + 1) % Number.MAX_SAFE_INTEGER;\n return count.toString();\n};\n\nconst dispatch = (message: string, type: ToastType, options?: ToastOptions) => {\n const id = genId();\n const newToast = { id, message, type, ...options };\n\n memoryState = [newToast];\n notify();\n return id;\n};\n\nexport const useToastStore = () => {\n return useSyncExternalStore(\n (listener) => {\n listeners.push(listener);\n return () => {\n listeners = listeners.filter((l) => l !== listener);\n };\n },\n () => memoryState,\n );\n};\n\nconst toastRoot = (message: string, options?: ToastOptions) =>\n dispatch(message, 'default', options);\n\nexport const toast = Object.assign(toastRoot, {\n success: (message: string, options?: ToastOptions) =>\n dispatch(message, 'success', options),\n error: (message: string, options?: ToastOptions) =>\n dispatch(message, 'error', options),\n loading: (message: string, options?: ToastOptions) =>\n dispatch(message, 'loading', {\n ...options,\n duration: options?.duration ?? 100000,\n }),\n dismiss: (id: string) => {\n memoryState = memoryState.filter((t) => t.id !== id);\n notify();\n },\n});\n"],"mappings":";;;AAcA,IAAI,cAA2B,EAAE;AACjC,IAAI,YAA+B,EAAE;AACrC,MAAM,eAAe,UAAU,SAAS,MAAM,GAAG,CAAC;AAElD,IAAI,QAAQ;AACZ,MAAM,cAAc;AAClB,UAAS,QAAQ,KAAK,OAAO;AAC7B,QAAO,MAAM,UAAU;;AAGzB,MAAM,YAAY,SAAiB,MAAiB,YAA2B;CAC7E,MAAM,KAAK,OAAO;AAGlB,eAAc,CAFG;EAAE;EAAI;EAAS;EAAM,GAAG;EAAS,CAE1B;AACxB,SAAQ;AACR,QAAO;;AAeT,MAAM,aAAa,SAAiB,YAClC,SAAS,SAAS,WAAW,QAAQ;AAEvC,MAAa,QAAQ,OAAO,OAAO,WAAW;CAC5C,UAAU,SAAiB,YACzB,SAAS,SAAS,WAAW,QAAQ;CACvC,QAAQ,SAAiB,YACvB,SAAS,SAAS,SAAS,QAAQ;CACrC,UAAU,SAAiB,YACzB,SAAS,SAAS,WAAW;EAC3B,GAAG;EACH,UAAU,SAAS,YAAY;EAChC,CAAC;CACJ,UAAU,OAAe;AACvB,gBAAc,YAAY,QAAQ,MAAM,EAAE,OAAO,GAAG;AACpD,UAAQ;;CAEX,CAAC"}
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { TextVariants } from "../Text/Text.styles.cjs";
|
|
2
2
|
import { PolymorphicProps } from "../../utils/polymorphic/polymorphic.cjs";
|
|
3
3
|
import { TextElement } from "../Text/Text.cjs";
|
|
4
|
+
import "../Text/index.cjs";
|
|
5
|
+
import "../../utils/index.cjs";
|
|
4
6
|
import { ToggleVariants } from "./Toggle.styles.cjs";
|
|
5
7
|
import React from "react";
|
|
6
|
-
import * as
|
|
8
|
+
import * as react_jsx_runtime15 from "react/jsx-runtime";
|
|
7
9
|
|
|
8
10
|
//#region src/components/Toggle/Toggle.d.ts
|
|
9
11
|
interface ToggleRootProps extends Omit<React.ComponentProps<'label'>, 'onChange'>, ToggleVariants {
|
|
@@ -21,11 +23,11 @@ declare const Toggle: {
|
|
|
21
23
|
children,
|
|
22
24
|
className,
|
|
23
25
|
...props
|
|
24
|
-
}: ToggleRootProps):
|
|
26
|
+
}: ToggleRootProps): react_jsx_runtime15.JSX.Element;
|
|
25
27
|
displayName: string;
|
|
26
28
|
} & {
|
|
27
29
|
Switch: {
|
|
28
|
-
():
|
|
30
|
+
(): react_jsx_runtime15.JSX.Element;
|
|
29
31
|
displayName: string;
|
|
30
32
|
};
|
|
31
33
|
Label: {
|
|
@@ -35,7 +37,7 @@ declare const Toggle: {
|
|
|
35
37
|
textColor,
|
|
36
38
|
className,
|
|
37
39
|
...props
|
|
38
|
-
}: ToggleLabelProps<E>):
|
|
40
|
+
}: ToggleLabelProps<E>): react_jsx_runtime15.JSX.Element;
|
|
39
41
|
displayName: string;
|
|
40
42
|
};
|
|
41
43
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Toggle.d.cts","names":[],"sources":["../../../src/components/Toggle/Toggle.tsx"],"mappings":"
|
|
1
|
+
{"version":3,"file":"Toggle.d.cts","names":[],"sources":["../../../src/components/Toggle/Toggle.tsx"],"mappings":";;;;;;;;;;UAyBiB,eAAA,SACP,IAAA,CAAK,KAAA,CAAM,cAAA,wBAAsC,cAAA;EACzD,cAAA;EACA,eAAA,IAAmB,OAAA;EACnB,QAAA,GAAW,KAAA,CAAM,SAAA;AAAA;AAAA,KAwDP,gBAAA,WAA2B,WAAA,aAAwB,gBAAA,CAC7D,CAAA,EACA,YAAA;AAAA,cA8BW,MAAA;EAAA;;;;;;;;KA7EV,eAAA,GAAe,mBAAA,CAAA,GAAA,CAAA,OAAA;;;;;;;;eAkDa,WAAA;MAAW,QAAA;MAAA,UAAA;MAAA,SAAA;MAAA,SAAA;MAAA,GAAA;IAAA,GAMvC,gBAAA,CAAiB,CAAA,IAAE,mBAAA,CAAA,GAAA,CAAA,OAAA"}
|
|
@@ -5,7 +5,7 @@ import "../Text/index.mjs";
|
|
|
5
5
|
import "../../utils/index.mjs";
|
|
6
6
|
import { ToggleVariants } from "./Toggle.styles.mjs";
|
|
7
7
|
import React from "react";
|
|
8
|
-
import * as
|
|
8
|
+
import * as react_jsx_runtime4 from "react/jsx-runtime";
|
|
9
9
|
|
|
10
10
|
//#region src/components/Toggle/Toggle.d.ts
|
|
11
11
|
interface ToggleRootProps extends Omit<React.ComponentProps<'label'>, 'onChange'>, ToggleVariants {
|
|
@@ -23,11 +23,11 @@ declare const Toggle: {
|
|
|
23
23
|
children,
|
|
24
24
|
className,
|
|
25
25
|
...props
|
|
26
|
-
}: ToggleRootProps):
|
|
26
|
+
}: ToggleRootProps): react_jsx_runtime4.JSX.Element;
|
|
27
27
|
displayName: string;
|
|
28
28
|
} & {
|
|
29
29
|
Switch: {
|
|
30
|
-
():
|
|
30
|
+
(): react_jsx_runtime4.JSX.Element;
|
|
31
31
|
displayName: string;
|
|
32
32
|
};
|
|
33
33
|
Label: {
|
|
@@ -37,7 +37,7 @@ declare const Toggle: {
|
|
|
37
37
|
textColor,
|
|
38
38
|
className,
|
|
39
39
|
...props
|
|
40
|
-
}: ToggleLabelProps<E>):
|
|
40
|
+
}: ToggleLabelProps<E>): react_jsx_runtime4.JSX.Element;
|
|
41
41
|
displayName: string;
|
|
42
42
|
};
|
|
43
43
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as tailwind_variants39 from "tailwind-variants";
|
|
2
2
|
import { VariantProps } from "tailwind-variants";
|
|
3
3
|
|
|
4
4
|
//#region src/components/Toggle/Toggle.styles.d.ts
|
|
5
|
-
declare const toggle:
|
|
5
|
+
declare const toggle: tailwind_variants39.TVReturnType<{
|
|
6
6
|
checked: {
|
|
7
7
|
true: {
|
|
8
8
|
switch: string;
|
|
@@ -46,7 +46,7 @@ declare const toggle: tailwind_variants31.TVReturnType<{
|
|
|
46
46
|
switch: string;
|
|
47
47
|
switchThumb: string;
|
|
48
48
|
label: string;
|
|
49
|
-
},
|
|
49
|
+
}, tailwind_variants39.TVReturnType<{
|
|
50
50
|
checked: {
|
|
51
51
|
true: {
|
|
52
52
|
switch: string;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as tailwind_variants29 from "tailwind-variants";
|
|
2
2
|
import { VariantProps } from "tailwind-variants";
|
|
3
3
|
|
|
4
4
|
//#region src/components/Toggle/Toggle.styles.d.ts
|
|
5
|
-
declare const toggle:
|
|
5
|
+
declare const toggle: tailwind_variants29.TVReturnType<{
|
|
6
6
|
checked: {
|
|
7
7
|
true: {
|
|
8
8
|
switch: string;
|
|
@@ -46,7 +46,7 @@ declare const toggle: tailwind_variants31.TVReturnType<{
|
|
|
46
46
|
switch: string;
|
|
47
47
|
switchThumb: string;
|
|
48
48
|
label: string;
|
|
49
|
-
},
|
|
49
|
+
}, tailwind_variants29.TVReturnType<{
|
|
50
50
|
checked: {
|
|
51
51
|
true: {
|
|
52
52
|
switch: string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import { Toggle, ToggleLabelProps, ToggleRootProps } from "./Toggle.cjs";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"VStack.d.cts","names":[],"sources":["../../../src/components/VStack/VStack.tsx"],"mappings":"
|
|
1
|
+
{"version":3,"file":"VStack.d.cts","names":[],"sources":["../../../src/components/VStack/VStack.tsx"],"mappings":";;;;;;KAGY,WAAA,WAAsB,WAAA,YAAuB,IAAA,CACvD,UAAA,CAAW,CAAA;AAAA,cAIA,MAAA;EAAA,WAAoB,WAAA;IAAA,GAAW;EAAA,GAEzC,WAAA,CAAY,CAAA,IAAE,mBAAA,CAAA,GAAA,CAAA,OAAA"}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { StackProps } from "../Stack/Stack.mjs";
|
|
2
2
|
import "../Stack/index.mjs";
|
|
3
3
|
import { ElementType } from "react";
|
|
4
|
-
import * as
|
|
4
|
+
import * as react_jsx_runtime19 from "react/jsx-runtime";
|
|
5
5
|
|
|
6
6
|
//#region src/components/VStack/VStack.d.ts
|
|
7
7
|
type VStackProps<E extends ElementType = 'div'> = Omit<StackProps<E>, 'direction'>;
|
|
8
8
|
declare const VStack: {
|
|
9
9
|
<E extends ElementType = "div">({
|
|
10
10
|
...props
|
|
11
|
-
}: VStackProps<E>):
|
|
11
|
+
}: VStackProps<E>): react_jsx_runtime19.JSX.Element;
|
|
12
12
|
displayName: string;
|
|
13
13
|
};
|
|
14
14
|
//#endregion
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import { VStack, VStackProps } from "./VStack.cjs";
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import { TextVariants } from "./Text/Text.styles.cjs";
|
|
2
|
+
import { Text, TextElement, TextProps } from "./Text/Text.cjs";
|
|
3
|
+
import "./Text/index.cjs";
|
|
4
|
+
import { Field, FieldDescriptionProps, FieldErrorDescriptionProps, FieldLabelProps, FieldProps } from "./Field/Field.cjs";
|
|
5
|
+
import "./Field/index.cjs";
|
|
6
|
+
import { TextInputVariants } from "./TextInput/TextInput.styles.cjs";
|
|
7
|
+
import { TextInput, TextInputProps } from "./TextInput/TextInput.cjs";
|
|
8
|
+
import "./TextInput/index.cjs";
|
|
9
|
+
import { Primitive, PrimitiveProps } from "./Primitive/Primitive.cjs";
|
|
10
|
+
import "./Primitive/index.cjs";
|
|
11
|
+
import { TextArea, TextAreaFooterProps, TextAreaInputProps, TextAreaProps } from "./TextArea/TextArea.cjs";
|
|
12
|
+
import "./TextArea/index.cjs";
|
|
13
|
+
import { Radio, RadioGroup, RadioGroupProps, RadioProps, useRadioGroupContext } from "./Radio/Radio.cjs";
|
|
14
|
+
import "./Radio/index.cjs";
|
|
15
|
+
import { Toggle, ToggleLabelProps, ToggleRootProps } from "./Toggle/Toggle.cjs";
|
|
16
|
+
import "./Toggle/index.cjs";
|
|
17
|
+
import { Checkbox, CheckboxLabelProps, CheckboxRootProps } from "./Checkbox/Checkbox.cjs";
|
|
18
|
+
import "./Checkbox/index.cjs";
|
|
19
|
+
import { Button, ButtonProps } from "./Button/Button.cjs";
|
|
20
|
+
import "./Button/index.cjs";
|
|
21
|
+
import { CTAButton, CTAButtonProps } from "./CTAButton/CTAButton.cjs";
|
|
22
|
+
import "./CTAButton/index.cjs";
|
|
23
|
+
import { FloatingActionButton, FloatingActionButtonProps } from "./FloatingActionButton/FloatingActionButton.cjs";
|
|
24
|
+
import "./FloatingActionButton/index.cjs";
|
|
25
|
+
import { BoxVariants, box } from "./Box/Box.styles.cjs";
|
|
26
|
+
import { Box, BoxProps } from "./Box/Box.cjs";
|
|
27
|
+
import "./Box/index.cjs";
|
|
28
|
+
import { StackVariants } from "./Stack/Stack.styles.cjs";
|
|
29
|
+
import { Stack, StackProps } from "./Stack/Stack.cjs";
|
|
30
|
+
import "./Stack/index.cjs";
|
|
31
|
+
import { VStack, VStackProps } from "./VStack/VStack.cjs";
|
|
32
|
+
import "./VStack/index.cjs";
|
|
33
|
+
import { HStack, HStackProps } from "./HStack/HStack.cjs";
|
|
34
|
+
import "./HStack/index.cjs";
|
|
35
|
+
import { FlexAlign, FlexDirection, FlexGap, FlexJustify } from "./Flex/Flex.styles.cjs";
|
|
36
|
+
import { Flex, FlexProps } from "./Flex/Flex.cjs";
|
|
37
|
+
import "./Flex/index.cjs";
|
|
38
|
+
import { Grid, GridProps } from "./Grid/Grid.cjs";
|
|
39
|
+
import "./Grid/index.cjs";
|
|
40
|
+
import { SeparatorVariants } from "./Separator/Separator.styles.cjs";
|
|
41
|
+
import { Separator, SeparatorProps } from "./Separator/Separator.cjs";
|
|
42
|
+
import "./Separator/index.cjs";
|
|
43
|
+
import { SpacerVariants } from "./Spacer/Spacer.styles.cjs";
|
|
44
|
+
import { Spacer, SpacerProps } from "./Spacer/Spacer.cjs";
|
|
45
|
+
import "./Spacer/index.cjs";
|
|
46
|
+
import { RatioChart, RatioChartFooterProps, RatioChartItemProps, RatioChartRootProps } from "./RatioChart/RatioChart.cjs";
|
|
47
|
+
import { RatioChartEditor, RatioChartEditorOption, RatioChartEditorProps } from "./RatioChart/RatioChartEditor.cjs";
|
|
48
|
+
import "./RatioChart/index.cjs";
|
|
49
|
+
import { SelectVariants } from "./Select/Select.styles.cjs";
|
|
50
|
+
import { Select, SelectContentProps, SelectGroupProps, SelectItemProps, SelectLabelProps, SelectProps, SelectTriggerProps, SelectValueProps } from "./Select/Select.cjs";
|
|
51
|
+
import "./Select/index.cjs";
|
|
52
|
+
import { DialogVariants } from "./Dialog/Dialog.styles.cjs";
|
|
53
|
+
import { Dialog, DialogCloseProps, DialogContentProps, DialogDescriptionProps, DialogFooterProps, DialogOverlayProps, DialogPortalProps, DialogProps, DialogTitleProps, DialogTriggerProps } from "./Dialog/Dialog.cjs";
|
|
54
|
+
import "./Dialog/index.cjs";
|
|
55
|
+
import { DropdownVariants } from "./Dropdown/Dropdown.styles.cjs";
|
|
56
|
+
import { Dropdown, DropdownContentProps, DropdownItemProps, DropdownProps, DropdownTriggerProps } from "./Dropdown/Dropdown.cjs";
|
|
57
|
+
import "./Dropdown/index.cjs";
|
|
58
|
+
import { Float, FloatProps } from "./Float/Float.cjs";
|
|
59
|
+
import "./Float/index.cjs";
|
|
60
|
+
import { ChipVariants } from "./Chip/Chip.styles.cjs";
|
|
61
|
+
import { Chip, ChipProps } from "./Chip/Chip.cjs";
|
|
62
|
+
import "./Chip/index.cjs";
|
|
63
|
+
import { AvatarVariants } from "./Avatar/Avatar.styles.cjs";
|
|
64
|
+
import { Avatar, AvatarProps } from "./Avatar/Avatar.cjs";
|
|
65
|
+
import "./Avatar/index.cjs";
|
|
66
|
+
import { TabVariants } from "./Tab/Tab.styles.cjs";
|
|
67
|
+
import { Tab, TabContentProps, TabListProps, TabRootProps, TabTabItemProps } from "./Tab/Tab.cjs";
|
|
68
|
+
import "./Tab/index.cjs";
|
|
69
|
+
import { ToastVariants } from "./Toast/Toast.styles.cjs";
|
|
70
|
+
import { Toast, ToastProps, ToastProvider, ToastViewport, ToastViewportProps } from "./Toast/Toast.cjs";
|
|
71
|
+
import { toast } from "./Toast/toastStore.cjs";
|
|
72
|
+
import "./Toast/index.cjs";
|
|
73
|
+
import { ModalVariants } from "./Modal/Modal.styles.cjs";
|
|
74
|
+
import { Modal, ModalActionProps, ModalContentProps, ModalDescriptionProps, ModalFooterProps, ModalOverlayProps, ModalTitleProps } from "./Modal/Modal.cjs";
|
|
75
|
+
import "./Modal/index.cjs";
|
|
76
|
+
import { SidebarVariants } from "./Sidebar/Sidebar.styles.cjs";
|
|
77
|
+
import { Sidebar } from "./Sidebar/Sidebar.cjs";
|
|
78
|
+
import "./Sidebar/index.cjs";
|
|
79
|
+
import { BottomNavigation } from "./BottomNavigation/BottomNavigation.cjs";
|
|
80
|
+
import "./BottomNavigation/index.cjs";
|
|
81
|
+
import { Calendar, CalendarEvent, CalendarProps } from "./Calendar/Calendar.cjs";
|
|
82
|
+
import { Drawer } from "./Drawer/Drawer.cjs";
|
|
83
|
+
import { BottomSheet } from "./BottomSheet/BottomSheet.cjs";
|
|
84
|
+
import "./BottomSheet/index.cjs";
|
|
85
|
+
import "./Drawer/index.cjs";
|
|
86
|
+
import { Skeleton, SkeletonProps } from "./Skeleton/Skeleton.cjs";
|
|
87
|
+
import "./Skeleton/index.cjs";
|
|
88
|
+
import { Spinner, SpinnerProps } from "./Spinner/Spinner.cjs";
|
|
89
|
+
import { PullToRefresh, PullToRefreshProps } from "./PullToRefresh/PullToRefresh.cjs";
|
|
90
|
+
import "./PullToRefresh/index.cjs";
|
|
@@ -68,6 +68,7 @@ import { Tab, TabContentProps, TabListProps, TabRootProps, TabTabItemProps } fro
|
|
|
68
68
|
import "./Tab/index.mjs";
|
|
69
69
|
import { ToastVariants } from "./Toast/Toast.styles.mjs";
|
|
70
70
|
import { Toast, ToastProps, ToastProvider, ToastViewport, ToastViewportProps } from "./Toast/Toast.mjs";
|
|
71
|
+
import { toast } from "./Toast/toastStore.mjs";
|
|
71
72
|
import "./Toast/index.mjs";
|
|
72
73
|
import { ModalVariants } from "./Modal/Modal.styles.mjs";
|
|
73
74
|
import { Modal, ModalActionProps, ModalContentProps, ModalDescriptionProps, ModalFooterProps, ModalOverlayProps, ModalTitleProps } from "./Modal/Modal.mjs";
|
|
@@ -82,4 +83,10 @@ import "./Calendar/index.mjs";
|
|
|
82
83
|
import { Drawer } from "./Drawer/Drawer.mjs";
|
|
83
84
|
import { BottomSheet } from "./BottomSheet/BottomSheet.mjs";
|
|
84
85
|
import "./BottomSheet/index.mjs";
|
|
85
|
-
import "./Drawer/index.mjs";
|
|
86
|
+
import "./Drawer/index.mjs";
|
|
87
|
+
import { Skeleton, SkeletonProps } from "./Skeleton/Skeleton.mjs";
|
|
88
|
+
import "./Skeleton/index.mjs";
|
|
89
|
+
import { Spinner, SpinnerProps } from "./Spinner/Spinner.mjs";
|
|
90
|
+
import "./Spinner/index.mjs";
|
|
91
|
+
import { PullToRefresh, PullToRefreshProps } from "./PullToRefresh/PullToRefresh.mjs";
|
|
92
|
+
import "./PullToRefresh/index.mjs";
|
package/dist/index.cjs
CHANGED
|
@@ -31,12 +31,16 @@ const require_Chip = require('./components/Chip/Chip.cjs');
|
|
|
31
31
|
const require_Avatar = require('./components/Avatar/Avatar.cjs');
|
|
32
32
|
const require_Tab = require('./components/Tab/Tab.cjs');
|
|
33
33
|
const require_Toast = require('./components/Toast/Toast.cjs');
|
|
34
|
+
const require_toastStore = require('./components/Toast/toastStore.cjs');
|
|
34
35
|
const require_Modal = require('./components/Modal/Modal.cjs');
|
|
35
36
|
const require_Sidebar = require('./components/Sidebar/Sidebar.cjs');
|
|
36
37
|
const require_BottomNavigation = require('./components/BottomNavigation/BottomNavigation.cjs');
|
|
37
38
|
const require_Calendar = require('./components/Calendar/Calendar.cjs');
|
|
38
39
|
const require_Drawer = require('./components/Drawer/Drawer.cjs');
|
|
39
40
|
const require_BottomSheet = require('./components/BottomSheet/BottomSheet.cjs');
|
|
41
|
+
const require_Skeleton = require('./components/Skeleton/Skeleton.cjs');
|
|
42
|
+
const require_Spinner = require('./components/Spinner/Spinner.cjs');
|
|
43
|
+
const require_PullToRefresh = require('./components/PullToRefresh/PullToRefresh.cjs');
|
|
40
44
|
|
|
41
45
|
exports.Avatar = require_Avatar.Avatar;
|
|
42
46
|
exports.BottomNavigation = require_BottomNavigation.BottomNavigation;
|
|
@@ -58,6 +62,7 @@ exports.Grid = require_Grid.Grid;
|
|
|
58
62
|
exports.HStack = require_HStack.HStack;
|
|
59
63
|
exports.Modal = require_Modal.Modal;
|
|
60
64
|
exports.Primitive = require_Primitive.Primitive;
|
|
65
|
+
exports.PullToRefresh = require_PullToRefresh.PullToRefresh;
|
|
61
66
|
exports.Radio = require_Radio.Radio;
|
|
62
67
|
exports.RadioGroup = require_Radio.RadioGroup;
|
|
63
68
|
exports.RatioChart = require_RatioChart.RatioChart;
|
|
@@ -65,7 +70,9 @@ exports.RatioChartEditor = require_RatioChartEditor.RatioChartEditor;
|
|
|
65
70
|
exports.Select = require_Select.Select;
|
|
66
71
|
exports.Separator = require_Separator.Separator;
|
|
67
72
|
exports.Sidebar = require_Sidebar.Sidebar;
|
|
73
|
+
exports.Skeleton = require_Skeleton.Skeleton;
|
|
68
74
|
exports.Spacer = require_Spacer.Spacer;
|
|
75
|
+
exports.Spinner = require_Spinner.Spinner;
|
|
69
76
|
exports.Stack = require_Stack.Stack;
|
|
70
77
|
exports.Tab = require_Tab.Tab;
|
|
71
78
|
exports.Text = require_Text.Text;
|
|
@@ -80,4 +87,5 @@ exports.box = require_Box_styles.box;
|
|
|
80
87
|
exports.convertPxToRem = require_converter.convertPxToRem;
|
|
81
88
|
exports.mergeStyles = require_mergeStyles.mergeStyles;
|
|
82
89
|
exports.splitVariantProps = require_splitter.splitVariantProps;
|
|
90
|
+
exports.toast = require_toastStore.toast;
|
|
83
91
|
exports.useRadioGroupContext = require_Radio.useRadioGroupContext;
|
package/dist/index.d.cts
CHANGED
|
@@ -10,6 +10,7 @@ import { Radio, RadioGroup, RadioGroupProps, RadioProps, useRadioGroupContext }
|
|
|
10
10
|
import { mergeStyles } from "./utils/mergeStyles/mergeStyles.cjs";
|
|
11
11
|
import { convertPxToRem } from "./utils/converter/converter.cjs";
|
|
12
12
|
import { splitVariantProps } from "./utils/splitter/splitter.cjs";
|
|
13
|
+
import "./utils/index.cjs";
|
|
13
14
|
import { Toggle, ToggleLabelProps, ToggleRootProps } from "./components/Toggle/Toggle.cjs";
|
|
14
15
|
import { Checkbox, CheckboxLabelProps, CheckboxRootProps } from "./components/Checkbox/Checkbox.cjs";
|
|
15
16
|
import { Button, ButtonProps } from "./components/Button/Button.cjs";
|
|
@@ -45,6 +46,7 @@ import { TabVariants } from "./components/Tab/Tab.styles.cjs";
|
|
|
45
46
|
import { Tab, TabContentProps, TabListProps, TabRootProps, TabTabItemProps } from "./components/Tab/Tab.cjs";
|
|
46
47
|
import { ToastVariants } from "./components/Toast/Toast.styles.cjs";
|
|
47
48
|
import { Toast, ToastProps, ToastProvider, ToastViewport, ToastViewportProps } from "./components/Toast/Toast.cjs";
|
|
49
|
+
import { toast } from "./components/Toast/toastStore.cjs";
|
|
48
50
|
import { ModalVariants } from "./components/Modal/Modal.styles.cjs";
|
|
49
51
|
import { Modal, ModalActionProps, ModalContentProps, ModalDescriptionProps, ModalFooterProps, ModalOverlayProps, ModalTitleProps } from "./components/Modal/Modal.cjs";
|
|
50
52
|
import { SidebarVariants } from "./components/Sidebar/Sidebar.styles.cjs";
|
|
@@ -53,4 +55,8 @@ import { BottomNavigation } from "./components/BottomNavigation/BottomNavigation
|
|
|
53
55
|
import { Calendar, CalendarEvent, CalendarProps } from "./components/Calendar/Calendar.cjs";
|
|
54
56
|
import { Drawer } from "./components/Drawer/Drawer.cjs";
|
|
55
57
|
import { BottomSheet } from "./components/BottomSheet/BottomSheet.cjs";
|
|
56
|
-
|
|
58
|
+
import { Skeleton, SkeletonProps } from "./components/Skeleton/Skeleton.cjs";
|
|
59
|
+
import { Spinner, SpinnerProps } from "./components/Spinner/Spinner.cjs";
|
|
60
|
+
import { PullToRefresh, PullToRefreshProps } from "./components/PullToRefresh/PullToRefresh.cjs";
|
|
61
|
+
import "./components/index.cjs";
|
|
62
|
+
export { Avatar, AvatarProps, AvatarVariants, BottomNavigation, BottomSheet, Box, BoxProps, BoxVariants, Button, ButtonProps, CTAButton, CTAButtonProps, Calendar, CalendarEvent, CalendarProps, Checkbox, CheckboxLabelProps, CheckboxRootProps, Chip, ChipProps, ChipVariants, Dialog, DialogCloseProps, DialogContentProps, DialogDescriptionProps, DialogFooterProps, DialogOverlayProps, DialogPortalProps, DialogProps, DialogTitleProps, DialogTriggerProps, DialogVariants, Drawer, Dropdown, DropdownContentProps, DropdownItemProps, DropdownProps, DropdownTriggerProps, DropdownVariants, Field, FieldDescriptionProps, FieldErrorDescriptionProps, FieldLabelProps, FieldProps, Flex, FlexAlign, FlexDirection, FlexGap, FlexJustify, FlexProps, Float, FloatProps, FloatingActionButton, FloatingActionButtonProps, Grid, GridProps, HStack, HStackProps, Modal, ModalActionProps, ModalContentProps, ModalDescriptionProps, ModalFooterProps, ModalOverlayProps, ModalTitleProps, ModalVariants, PolymorphicProps, PolymorphicPropsWithoutRef, Primitive, PrimitiveProps, PullToRefresh, PullToRefreshProps, Radio, RadioGroup, RadioGroupProps, RadioProps, RatioChart, RatioChartEditor, RatioChartEditorOption, RatioChartEditorProps, RatioChartFooterProps, RatioChartItemProps, RatioChartRootProps, Select, SelectContentProps, SelectGroupProps, SelectItemProps, SelectLabelProps, SelectProps, SelectTriggerProps, SelectValueProps, SelectVariants, Separator, SeparatorProps, SeparatorVariants, Sidebar, SidebarVariants, Skeleton, SkeletonProps, Spacer, SpacerProps, SpacerVariants, Spinner, SpinnerProps, Stack, StackProps, StackVariants, Tab, TabContentProps, TabListProps, TabRootProps, TabTabItemProps, TabVariants, Text, TextArea, TextAreaFooterProps, TextAreaInputProps, TextAreaProps, TextElement, TextInput, TextInputProps, TextInputVariants, TextProps, TextVariants, Toast, ToastProps, ToastProvider, ToastVariants, ToastViewport, ToastViewportProps, Toggle, ToggleLabelProps, ToggleRootProps, VStack, VStackProps, box, convertPxToRem, mergeStyles, splitVariantProps, toast, useRadioGroupContext };
|
package/dist/index.d.mts
CHANGED
|
@@ -46,6 +46,7 @@ import { TabVariants } from "./components/Tab/Tab.styles.mjs";
|
|
|
46
46
|
import { Tab, TabContentProps, TabListProps, TabRootProps, TabTabItemProps } from "./components/Tab/Tab.mjs";
|
|
47
47
|
import { ToastVariants } from "./components/Toast/Toast.styles.mjs";
|
|
48
48
|
import { Toast, ToastProps, ToastProvider, ToastViewport, ToastViewportProps } from "./components/Toast/Toast.mjs";
|
|
49
|
+
import { toast } from "./components/Toast/toastStore.mjs";
|
|
49
50
|
import { ModalVariants } from "./components/Modal/Modal.styles.mjs";
|
|
50
51
|
import { Modal, ModalActionProps, ModalContentProps, ModalDescriptionProps, ModalFooterProps, ModalOverlayProps, ModalTitleProps } from "./components/Modal/Modal.mjs";
|
|
51
52
|
import { SidebarVariants } from "./components/Sidebar/Sidebar.styles.mjs";
|
|
@@ -54,5 +55,8 @@ import { BottomNavigation } from "./components/BottomNavigation/BottomNavigation
|
|
|
54
55
|
import { Calendar, CalendarEvent, CalendarProps } from "./components/Calendar/Calendar.mjs";
|
|
55
56
|
import { Drawer } from "./components/Drawer/Drawer.mjs";
|
|
56
57
|
import { BottomSheet } from "./components/BottomSheet/BottomSheet.mjs";
|
|
58
|
+
import { Skeleton, SkeletonProps } from "./components/Skeleton/Skeleton.mjs";
|
|
59
|
+
import { Spinner, SpinnerProps } from "./components/Spinner/Spinner.mjs";
|
|
60
|
+
import { PullToRefresh, PullToRefreshProps } from "./components/PullToRefresh/PullToRefresh.mjs";
|
|
57
61
|
import "./components/index.mjs";
|
|
58
|
-
export { Avatar, AvatarProps, AvatarVariants, BottomNavigation, BottomSheet, Box, BoxProps, BoxVariants, Button, ButtonProps, CTAButton, CTAButtonProps, Calendar, CalendarEvent, CalendarProps, Checkbox, CheckboxLabelProps, CheckboxRootProps, Chip, ChipProps, ChipVariants, Dialog, DialogCloseProps, DialogContentProps, DialogDescriptionProps, DialogFooterProps, DialogOverlayProps, DialogPortalProps, DialogProps, DialogTitleProps, DialogTriggerProps, DialogVariants, Drawer, Dropdown, DropdownContentProps, DropdownItemProps, DropdownProps, DropdownTriggerProps, DropdownVariants, Field, FieldDescriptionProps, FieldErrorDescriptionProps, FieldLabelProps, FieldProps, Flex, FlexAlign, FlexDirection, FlexGap, FlexJustify, FlexProps, Float, FloatProps, FloatingActionButton, FloatingActionButtonProps, Grid, GridProps, HStack, HStackProps, Modal, ModalActionProps, ModalContentProps, ModalDescriptionProps, ModalFooterProps, ModalOverlayProps, ModalTitleProps, ModalVariants, PolymorphicProps, PolymorphicPropsWithoutRef, Primitive, PrimitiveProps, Radio, RadioGroup, RadioGroupProps, RadioProps, RatioChart, RatioChartEditor, RatioChartEditorOption, RatioChartEditorProps, RatioChartFooterProps, RatioChartItemProps, RatioChartRootProps, Select, SelectContentProps, SelectGroupProps, SelectItemProps, SelectLabelProps, SelectProps, SelectTriggerProps, SelectValueProps, SelectVariants, Separator, SeparatorProps, SeparatorVariants, Sidebar, SidebarVariants, Spacer, SpacerProps, SpacerVariants, Stack, StackProps, StackVariants, Tab, TabContentProps, TabListProps, TabRootProps, TabTabItemProps, TabVariants, Text, TextArea, TextAreaFooterProps, TextAreaInputProps, TextAreaProps, TextElement, TextInput, TextInputProps, TextInputVariants, TextProps, TextVariants, Toast, ToastProps, ToastProvider, ToastVariants, ToastViewport, ToastViewportProps, Toggle, ToggleLabelProps, ToggleRootProps, VStack, VStackProps, box, convertPxToRem, mergeStyles, splitVariantProps, useRadioGroupContext };
|
|
62
|
+
export { Avatar, AvatarProps, AvatarVariants, BottomNavigation, BottomSheet, Box, BoxProps, BoxVariants, Button, ButtonProps, CTAButton, CTAButtonProps, Calendar, CalendarEvent, CalendarProps, Checkbox, CheckboxLabelProps, CheckboxRootProps, Chip, ChipProps, ChipVariants, Dialog, DialogCloseProps, DialogContentProps, DialogDescriptionProps, DialogFooterProps, DialogOverlayProps, DialogPortalProps, DialogProps, DialogTitleProps, DialogTriggerProps, DialogVariants, Drawer, Dropdown, DropdownContentProps, DropdownItemProps, DropdownProps, DropdownTriggerProps, DropdownVariants, Field, FieldDescriptionProps, FieldErrorDescriptionProps, FieldLabelProps, FieldProps, Flex, FlexAlign, FlexDirection, FlexGap, FlexJustify, FlexProps, Float, FloatProps, FloatingActionButton, FloatingActionButtonProps, Grid, GridProps, HStack, HStackProps, Modal, ModalActionProps, ModalContentProps, ModalDescriptionProps, ModalFooterProps, ModalOverlayProps, ModalTitleProps, ModalVariants, PolymorphicProps, PolymorphicPropsWithoutRef, Primitive, PrimitiveProps, PullToRefresh, PullToRefreshProps, Radio, RadioGroup, RadioGroupProps, RadioProps, RatioChart, RatioChartEditor, RatioChartEditorOption, RatioChartEditorProps, RatioChartFooterProps, RatioChartItemProps, RatioChartRootProps, Select, SelectContentProps, SelectGroupProps, SelectItemProps, SelectLabelProps, SelectProps, SelectTriggerProps, SelectValueProps, SelectVariants, Separator, SeparatorProps, SeparatorVariants, Sidebar, SidebarVariants, Skeleton, SkeletonProps, Spacer, SpacerProps, SpacerVariants, Spinner, SpinnerProps, Stack, StackProps, StackVariants, Tab, TabContentProps, TabListProps, TabRootProps, TabTabItemProps, TabVariants, Text, TextArea, TextAreaFooterProps, TextAreaInputProps, TextAreaProps, TextElement, TextInput, TextInputProps, TextInputVariants, TextProps, TextVariants, Toast, ToastProps, ToastProvider, ToastVariants, ToastViewport, ToastViewportProps, Toggle, ToggleLabelProps, ToggleRootProps, VStack, VStackProps, box, convertPxToRem, mergeStyles, splitVariantProps, toast, useRadioGroupContext };
|
package/dist/index.mjs
CHANGED
|
@@ -31,11 +31,15 @@ import { Chip } from "./components/Chip/Chip.mjs";
|
|
|
31
31
|
import { Avatar } from "./components/Avatar/Avatar.mjs";
|
|
32
32
|
import { Tab } from "./components/Tab/Tab.mjs";
|
|
33
33
|
import { Toast, ToastProvider, ToastViewport } from "./components/Toast/Toast.mjs";
|
|
34
|
+
import { toast } from "./components/Toast/toastStore.mjs";
|
|
34
35
|
import { Modal } from "./components/Modal/Modal.mjs";
|
|
35
36
|
import { Sidebar } from "./components/Sidebar/Sidebar.mjs";
|
|
36
37
|
import { BottomNavigation } from "./components/BottomNavigation/BottomNavigation.mjs";
|
|
37
38
|
import { Calendar } from "./components/Calendar/Calendar.mjs";
|
|
38
39
|
import { Drawer } from "./components/Drawer/Drawer.mjs";
|
|
39
40
|
import { BottomSheet } from "./components/BottomSheet/BottomSheet.mjs";
|
|
41
|
+
import { Skeleton } from "./components/Skeleton/Skeleton.mjs";
|
|
42
|
+
import { Spinner } from "./components/Spinner/Spinner.mjs";
|
|
43
|
+
import { PullToRefresh } from "./components/PullToRefresh/PullToRefresh.mjs";
|
|
40
44
|
|
|
41
|
-
export { Avatar, BottomNavigation, BottomSheet, Box, Button, CTAButton, Calendar, Checkbox, Chip, Dialog, Drawer, Dropdown, Field, Flex, Float, FloatingActionButton, Grid, HStack, Modal, Primitive, Radio, RadioGroup, RatioChart, RatioChartEditor, Select, Separator, Sidebar, Spacer, Stack, Tab, Text, TextArea, TextInput, Toast, ToastProvider, ToastViewport, Toggle, VStack, box, convertPxToRem, mergeStyles, splitVariantProps, useRadioGroupContext };
|
|
45
|
+
export { Avatar, BottomNavigation, BottomSheet, Box, Button, CTAButton, Calendar, Checkbox, Chip, Dialog, Drawer, Dropdown, Field, Flex, Float, FloatingActionButton, Grid, HStack, Modal, Primitive, PullToRefresh, Radio, RadioGroup, RatioChart, RatioChartEditor, Select, Separator, Sidebar, Skeleton, Spacer, Spinner, Stack, Tab, Text, TextArea, TextInput, Toast, ToastProvider, ToastViewport, Toggle, VStack, box, convertPxToRem, mergeStyles, splitVariantProps, toast, useRadioGroupContext };
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { PolymorphicProps, PolymorphicPropsWithoutRef } from "./polymorphic/polymorphic.cjs";
|
|
2
|
+
import "./polymorphic/index.cjs";
|
|
3
|
+
import { mergeStyles } from "./mergeStyles/mergeStyles.cjs";
|
|
4
|
+
import { convertPxToRem } from "./converter/converter.cjs";
|
|
5
|
+
import { splitVariantProps } from "./splitter/splitter.cjs";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import { PolymorphicProps, PolymorphicPropsWithoutRef } from "./polymorphic.cjs";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@causw/core",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.16",
|
|
4
4
|
"description": "Core components and utilities for CAUSW Design System - CAU Software Community Service",
|
|
5
5
|
"main": "dist/index.cjs",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"date-fns": "^4.1.0",
|
|
37
37
|
"tailwind-merge": "^3.4.0",
|
|
38
38
|
"tailwind-variants": "^3.2.2",
|
|
39
|
-
"@causw/icons": "0.0
|
|
39
|
+
"@causw/icons": "1.0.0",
|
|
40
40
|
"@causw/tokens": "0.0.12"
|
|
41
41
|
},
|
|
42
42
|
"peerDependencies": {
|
package/src/styles/global.css
CHANGED
|
@@ -2,6 +2,22 @@
|
|
|
2
2
|
@import 'tailwindcss';
|
|
3
3
|
@config '@causw/tokens/config';
|
|
4
4
|
|
|
5
|
+
@layer base {
|
|
6
|
+
button:focus,
|
|
7
|
+
[role="button"]:focus,
|
|
8
|
+
button:focus-visible,
|
|
9
|
+
[role="button"]:focus-visible {
|
|
10
|
+
outline: none;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
button:focus-visible,
|
|
14
|
+
[role="button"]:focus-visible {
|
|
15
|
+
outline: 2px solid black;
|
|
16
|
+
outline-offset: 1px;
|
|
17
|
+
border-radius: 10px;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
5
21
|
* {
|
|
6
22
|
letter-spacing: -0.02rem;
|
|
7
23
|
-webkit-font-smoothing: antialiased;
|
|
@@ -206,3 +222,19 @@
|
|
|
206
222
|
}
|
|
207
223
|
}
|
|
208
224
|
}
|
|
225
|
+
|
|
226
|
+
@keyframes skeleton-pulse {
|
|
227
|
+
0% {
|
|
228
|
+
opacity: 0.4;
|
|
229
|
+
}
|
|
230
|
+
50% {
|
|
231
|
+
opacity: 0.7;
|
|
232
|
+
}
|
|
233
|
+
100% {
|
|
234
|
+
opacity: 0.4;
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
.animate-skeleton-pulse {
|
|
239
|
+
animation: skeleton-pulse 1.5s ease-in-out infinite;
|
|
240
|
+
}
|