@helpwave/hightide 0.1.11 → 0.1.13
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/date/DatePicker.js +37 -7
- package/dist/components/date/DatePicker.js.map +1 -1
- package/dist/components/date/DatePicker.mjs +37 -7
- package/dist/components/date/DatePicker.mjs.map +1 -1
- package/dist/components/date/DayPicker.js.map +1 -1
- package/dist/components/date/DayPicker.mjs.map +1 -1
- package/dist/components/date/TimePicker.js +27 -6
- package/dist/components/date/TimePicker.js.map +1 -1
- package/dist/components/date/TimePicker.mjs +27 -6
- package/dist/components/date/TimePicker.mjs.map +1 -1
- package/dist/components/date/YearMonthPicker.js +36 -6
- package/dist/components/date/YearMonthPicker.js.map +1 -1
- package/dist/components/date/YearMonthPicker.mjs +36 -6
- package/dist/components/date/YearMonthPicker.mjs.map +1 -1
- package/dist/components/dialogs/ConfirmDialog.js +16 -2
- package/dist/components/dialogs/ConfirmDialog.js.map +1 -1
- package/dist/components/dialogs/ConfirmDialog.mjs +16 -2
- package/dist/components/dialogs/ConfirmDialog.mjs.map +1 -1
- package/dist/components/layout-and-navigation/Carousel.js +42 -9
- package/dist/components/layout-and-navigation/Carousel.js.map +1 -1
- package/dist/components/layout-and-navigation/Carousel.mjs +42 -9
- package/dist/components/layout-and-navigation/Carousel.mjs.map +1 -1
- package/dist/components/layout-and-navigation/Expandable.js +1 -1
- package/dist/components/layout-and-navigation/Expandable.js.map +1 -1
- package/dist/components/layout-and-navigation/Expandable.mjs +1 -1
- package/dist/components/layout-and-navigation/Expandable.mjs.map +1 -1
- package/dist/components/layout-and-navigation/FAQSection.js +1 -1
- package/dist/components/layout-and-navigation/FAQSection.js.map +1 -1
- package/dist/components/layout-and-navigation/FAQSection.mjs +1 -1
- package/dist/components/layout-and-navigation/FAQSection.mjs.map +1 -1
- package/dist/components/layout-and-navigation/Overlay.js +16 -2
- package/dist/components/layout-and-navigation/Overlay.js.map +1 -1
- package/dist/components/layout-and-navigation/Overlay.mjs +16 -2
- package/dist/components/layout-and-navigation/Overlay.mjs.map +1 -1
- package/dist/components/layout-and-navigation/Pagination.d.mts +6 -3
- package/dist/components/layout-and-navigation/Pagination.d.ts +6 -3
- package/dist/components/layout-and-navigation/Pagination.js +404 -19
- package/dist/components/layout-and-navigation/Pagination.js.map +1 -1
- package/dist/components/layout-and-navigation/Pagination.mjs +404 -19
- package/dist/components/layout-and-navigation/Pagination.mjs.map +1 -1
- package/dist/components/layout-and-navigation/SearchableList.js +187 -67
- package/dist/components/layout-and-navigation/SearchableList.js.map +1 -1
- package/dist/components/layout-and-navigation/SearchableList.mjs +183 -63
- package/dist/components/layout-and-navigation/SearchableList.mjs.map +1 -1
- package/dist/components/layout-and-navigation/StepperBar.js +37 -5
- package/dist/components/layout-and-navigation/StepperBar.js.map +1 -1
- package/dist/components/layout-and-navigation/StepperBar.mjs +37 -5
- package/dist/components/layout-and-navigation/StepperBar.mjs.map +1 -1
- package/dist/components/layout-and-navigation/TextImage.js +2 -0
- package/dist/components/layout-and-navigation/TextImage.js.map +1 -1
- package/dist/components/layout-and-navigation/TextImage.mjs +2 -0
- package/dist/components/layout-and-navigation/TextImage.mjs.map +1 -1
- package/dist/components/loading-states/LoadingAndErrorComponent.js +2 -0
- package/dist/components/loading-states/LoadingAndErrorComponent.js.map +1 -1
- package/dist/components/loading-states/LoadingAndErrorComponent.mjs +2 -0
- package/dist/components/loading-states/LoadingAndErrorComponent.mjs.map +1 -1
- package/dist/components/loading-states/LoadingAnimation.js +2 -0
- package/dist/components/loading-states/LoadingAnimation.js.map +1 -1
- package/dist/components/loading-states/LoadingAnimation.mjs +2 -0
- package/dist/components/loading-states/LoadingAnimation.mjs.map +1 -1
- package/dist/components/loading-states/LoadingButton.js +9 -0
- package/dist/components/loading-states/LoadingButton.js.map +1 -1
- package/dist/components/loading-states/LoadingButton.mjs +9 -0
- package/dist/components/loading-states/LoadingButton.mjs.map +1 -1
- package/dist/components/modals/ConfirmModal.js +16 -2
- package/dist/components/modals/ConfirmModal.js.map +1 -1
- package/dist/components/modals/ConfirmModal.mjs +16 -2
- package/dist/components/modals/ConfirmModal.mjs.map +1 -1
- package/dist/components/modals/DiscardChangesModal.js +16 -2
- package/dist/components/modals/DiscardChangesModal.js.map +1 -1
- package/dist/components/modals/DiscardChangesModal.mjs +16 -2
- package/dist/components/modals/DiscardChangesModal.mjs.map +1 -1
- package/dist/components/modals/InputModal.d.mts +1 -0
- package/dist/components/modals/InputModal.d.ts +1 -0
- package/dist/components/modals/InputModal.js +196 -76
- package/dist/components/modals/InputModal.js.map +1 -1
- package/dist/components/modals/InputModal.mjs +189 -69
- package/dist/components/modals/InputModal.mjs.map +1 -1
- package/dist/components/modals/LanguageModal.js +203 -83
- package/dist/components/modals/LanguageModal.js.map +1 -1
- package/dist/components/modals/LanguageModal.mjs +192 -72
- package/dist/components/modals/LanguageModal.mjs.map +1 -1
- package/dist/components/modals/ThemeModal.js +206 -86
- package/dist/components/modals/ThemeModal.js.map +1 -1
- package/dist/components/modals/ThemeModal.mjs +193 -73
- package/dist/components/modals/ThemeModal.mjs.map +1 -1
- package/dist/components/properties/CheckboxProperty.js +17 -5
- package/dist/components/properties/CheckboxProperty.js.map +1 -1
- package/dist/components/properties/CheckboxProperty.mjs +17 -5
- package/dist/components/properties/CheckboxProperty.mjs.map +1 -1
- package/dist/components/properties/DateProperty.js +182 -65
- package/dist/components/properties/DateProperty.js.map +1 -1
- package/dist/components/properties/DateProperty.mjs +179 -62
- package/dist/components/properties/DateProperty.mjs.map +1 -1
- package/dist/components/properties/MultiSelectProperty.js +194 -74
- package/dist/components/properties/MultiSelectProperty.js.map +1 -1
- package/dist/components/properties/MultiSelectProperty.mjs +187 -67
- package/dist/components/properties/MultiSelectProperty.mjs.map +1 -1
- package/dist/components/properties/NumberProperty.js +182 -65
- package/dist/components/properties/NumberProperty.js.map +1 -1
- package/dist/components/properties/NumberProperty.mjs +179 -62
- package/dist/components/properties/NumberProperty.mjs.map +1 -1
- package/dist/components/properties/PropertyBase.js +12 -1
- package/dist/components/properties/PropertyBase.js.map +1 -1
- package/dist/components/properties/PropertyBase.mjs +12 -1
- package/dist/components/properties/PropertyBase.mjs.map +1 -1
- package/dist/components/properties/SelectProperty.js +194 -74
- package/dist/components/properties/SelectProperty.js.map +1 -1
- package/dist/components/properties/SelectProperty.mjs +187 -67
- package/dist/components/properties/SelectProperty.mjs.map +1 -1
- package/dist/components/properties/TextProperty.js +43 -34
- package/dist/components/properties/TextProperty.js.map +1 -1
- package/dist/components/properties/TextProperty.mjs +43 -34
- package/dist/components/properties/TextProperty.mjs.map +1 -1
- package/dist/components/table/FillerRowElement.d.mts +8 -0
- package/dist/components/table/FillerRowElement.d.ts +8 -0
- package/dist/components/table/FillerRowElement.js +36 -0
- package/dist/components/table/FillerRowElement.js.map +1 -0
- package/dist/components/table/FillerRowElement.mjs +12 -0
- package/dist/components/table/FillerRowElement.mjs.map +1 -0
- package/dist/components/table/Filter.d.mts +5 -0
- package/dist/components/table/Filter.d.ts +5 -0
- package/dist/components/table/Filter.js +41 -0
- package/dist/components/table/Filter.js.map +1 -0
- package/dist/components/table/Filter.mjs +17 -0
- package/dist/components/table/Filter.mjs.map +1 -0
- package/dist/components/table/Table.d.mts +41 -0
- package/dist/components/table/Table.d.ts +41 -0
- package/dist/components/table/Table.js +1549 -0
- package/dist/components/table/Table.js.map +1 -0
- package/dist/components/table/Table.mjs +1520 -0
- package/dist/components/table/Table.mjs.map +1 -0
- package/dist/components/table/TableCell.d.mts +9 -0
- package/dist/components/table/TableCell.d.ts +9 -0
- package/dist/components/table/TableCell.js +37 -0
- package/dist/components/table/TableCell.js.map +1 -0
- package/dist/components/table/TableCell.mjs +13 -0
- package/dist/components/table/TableCell.mjs.map +1 -0
- package/dist/components/table/TableFilterButton.d.mts +11 -0
- package/dist/components/table/TableFilterButton.d.ts +11 -0
- package/dist/components/table/TableFilterButton.js +888 -0
- package/dist/components/table/TableFilterButton.js.map +1 -0
- package/dist/components/table/TableFilterButton.mjs +852 -0
- package/dist/components/table/TableFilterButton.mjs.map +1 -0
- package/dist/components/table/TableSortButton.d.mts +15 -0
- package/dist/components/table/TableSortButton.d.ts +15 -0
- package/dist/components/table/TableSortButton.js +136 -0
- package/dist/components/table/TableSortButton.js.map +1 -0
- package/dist/components/table/TableSortButton.mjs +102 -0
- package/dist/components/table/TableSortButton.mjs.map +1 -0
- package/dist/components/user-action/Button.d.mts +20 -5
- package/dist/components/user-action/Button.d.ts +20 -5
- package/dist/components/user-action/Button.js +12 -3
- package/dist/components/user-action/Button.js.map +1 -1
- package/dist/components/user-action/Button.mjs +11 -3
- package/dist/components/user-action/Button.mjs.map +1 -1
- package/dist/components/user-action/Checkbox.js +5 -4
- package/dist/components/user-action/Checkbox.js.map +1 -1
- package/dist/components/user-action/Checkbox.mjs +5 -4
- package/dist/components/user-action/Checkbox.mjs.map +1 -1
- package/dist/components/user-action/DateAndTimePicker.js +41 -9
- package/dist/components/user-action/DateAndTimePicker.js.map +1 -1
- package/dist/components/user-action/DateAndTimePicker.mjs +41 -9
- package/dist/components/user-action/DateAndTimePicker.mjs.map +1 -1
- package/dist/components/user-action/Input.d.mts +27 -7
- package/dist/components/user-action/Input.d.ts +27 -7
- package/dist/components/user-action/Input.js +173 -64
- package/dist/components/user-action/Input.js.map +1 -1
- package/dist/components/user-action/Input.mjs +172 -63
- package/dist/components/user-action/Input.mjs.map +1 -1
- package/dist/components/user-action/MultiSelect.js +195 -75
- package/dist/components/user-action/MultiSelect.js.map +1 -1
- package/dist/components/user-action/MultiSelect.mjs +187 -67
- package/dist/components/user-action/MultiSelect.mjs.map +1 -1
- package/dist/components/user-action/ScrollPicker.js +26 -5
- package/dist/components/user-action/ScrollPicker.js.map +1 -1
- package/dist/components/user-action/ScrollPicker.mjs +26 -5
- package/dist/components/user-action/ScrollPicker.mjs.map +1 -1
- package/dist/components/user-action/Select.js +195 -75
- package/dist/components/user-action/Select.js.map +1 -1
- package/dist/components/user-action/Select.mjs +187 -67
- package/dist/components/user-action/Select.mjs.map +1 -1
- package/dist/components/user-action/Textarea.d.mts +3 -1
- package/dist/components/user-action/Textarea.d.ts +3 -1
- package/dist/components/user-action/Textarea.js +31 -33
- package/dist/components/user-action/Textarea.js.map +1 -1
- package/dist/components/user-action/Textarea.mjs +31 -33
- package/dist/components/user-action/Textarea.mjs.map +1 -1
- package/dist/components/user-action/ToggleableInput.d.mts +3 -1
- package/dist/components/user-action/ToggleableInput.d.ts +3 -1
- package/dist/components/user-action/ToggleableInput.js +31 -33
- package/dist/components/user-action/ToggleableInput.js.map +1 -1
- package/dist/components/user-action/ToggleableInput.mjs +31 -33
- package/dist/components/user-action/ToggleableInput.mjs.map +1 -1
- package/dist/css/globals.css +431 -186
- package/dist/css/uncompiled/globals.css +36 -493
- package/dist/css/uncompiled/textstyles.css +69 -0
- package/dist/css/uncompiled/theme/colors-basic.css +72 -0
- package/dist/css/uncompiled/theme/colors-component.css +143 -0
- package/dist/css/uncompiled/theme/colors-semantic.css +99 -0
- package/dist/css/uncompiled/theme/index.css +5 -0
- package/dist/css/uncompiled/theme/theme.css +0 -0
- package/dist/css/uncompiled/theme/variants.css +3 -0
- package/dist/css/uncompiled/utitlity/animation.css +111 -0
- package/dist/css/uncompiled/utitlity/borderradius.css +23 -0
- package/dist/css/uncompiled/utitlity/general.css +11 -0
- package/dist/css/uncompiled/utitlity/index.css +4 -0
- package/dist/css/uncompiled/utitlity/shadow.css +29 -0
- package/dist/hooks/useDelay.d.mts +11 -0
- package/dist/hooks/useDelay.d.ts +11 -0
- package/dist/hooks/useDelay.js +64 -0
- package/dist/hooks/useDelay.js.map +1 -0
- package/dist/hooks/useDelay.mjs +40 -0
- package/dist/hooks/useDelay.mjs.map +1 -0
- package/dist/hooks/useFocusManagement.d.mts +9 -0
- package/dist/hooks/useFocusManagement.d.ts +9 -0
- package/dist/hooks/useFocusManagement.js +84 -0
- package/dist/hooks/useFocusManagement.js.map +1 -0
- package/dist/hooks/useFocusManagement.mjs +60 -0
- package/dist/hooks/useFocusManagement.mjs.map +1 -0
- package/dist/hooks/useFocusOnceVisible.d.mts +5 -0
- package/dist/hooks/useFocusOnceVisible.d.ts +5 -0
- package/dist/hooks/useFocusOnceVisible.js +60 -0
- package/dist/hooks/useFocusOnceVisible.js.map +1 -0
- package/dist/hooks/useFocusOnceVisible.mjs +26 -0
- package/dist/hooks/useFocusOnceVisible.mjs.map +1 -0
- package/dist/hooks/useRerender.d.mts +5 -0
- package/dist/hooks/useRerender.d.ts +5 -0
- package/dist/hooks/useRerender.js +33 -0
- package/dist/hooks/useRerender.js.map +1 -0
- package/dist/hooks/useRerender.mjs +9 -0
- package/dist/hooks/useRerender.mjs.map +1 -0
- package/dist/hooks/useResizeCallbackWrapper.d.mts +11 -0
- package/dist/hooks/useResizeCallbackWrapper.d.ts +11 -0
- package/dist/hooks/useResizeCallbackWrapper.js +38 -0
- package/dist/hooks/useResizeCallbackWrapper.js.map +1 -0
- package/dist/hooks/useResizeCallbackWrapper.mjs +14 -0
- package/dist/hooks/useResizeCallbackWrapper.mjs.map +1 -0
- package/dist/index.d.mts +16 -5
- package/dist/index.d.ts +16 -5
- package/dist/index.js +1428 -860
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1370 -799
- package/dist/index.mjs.map +1 -1
- package/dist/localization/defaults/form.d.mts +1 -0
- package/dist/localization/defaults/form.d.ts +1 -0
- package/dist/localization/defaults/form.js +2 -0
- package/dist/localization/defaults/form.js.map +1 -1
- package/dist/localization/defaults/form.mjs +2 -0
- package/dist/localization/defaults/form.mjs.map +1 -1
- package/dist/util/array.d.mts +11 -5
- package/dist/util/array.d.ts +11 -5
- package/dist/util/array.js +25 -4
- package/dist/util/array.js.map +1 -1
- package/dist/util/array.mjs +25 -4
- package/dist/util/array.mjs.map +1 -1
- package/dist/util/date.js.map +1 -1
- package/dist/util/date.mjs.map +1 -1
- package/dist/util/resolveSetState.d.mts +5 -0
- package/dist/util/resolveSetState.d.ts +5 -0
- package/dist/util/resolveSetState.js +32 -0
- package/dist/util/resolveSetState.js.map +1 -0
- package/dist/util/resolveSetState.mjs +8 -0
- package/dist/util/resolveSetState.mjs.map +1 -0
- package/package.json +4 -2
- package/dist/components/layout-and-navigation/Table.d.mts +0 -99
- package/dist/components/layout-and-navigation/Table.d.ts +0 -99
- package/dist/components/layout-and-navigation/Table.js +0 -688
- package/dist/components/layout-and-navigation/Table.js.map +0 -1
- package/dist/components/layout-and-navigation/Table.mjs +0 -645
- package/dist/components/layout-and-navigation/Table.mjs.map +0 -1
- package/dist/hooks/useSaveDelay.d.mts +0 -6
- package/dist/hooks/useSaveDelay.d.ts +0 -6
- package/dist/hooks/useSaveDelay.js +0 -67
- package/dist/hooks/useSaveDelay.js.map +0 -1
- package/dist/hooks/useSaveDelay.mjs +0 -43
- package/dist/hooks/useSaveDelay.mjs.map +0 -1
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
@import './variants.css';
|
|
2
|
+
|
|
3
|
+
/*
|
|
4
|
+
* default light-theme basic colors
|
|
5
|
+
*/
|
|
6
|
+
@theme {
|
|
7
|
+
--color-white: #FFFFFF;
|
|
8
|
+
--color-black: #000000;
|
|
9
|
+
--color-gray-25: #F8F8F8;
|
|
10
|
+
--color-gray-50: #F2F2F2;
|
|
11
|
+
--color-gray-100: #E6E6E6;
|
|
12
|
+
--color-gray-200: #CCCCCC;
|
|
13
|
+
--color-gray-300: #B3B3B3;
|
|
14
|
+
--color-gray-400: #999999;
|
|
15
|
+
--color-gray-500: #888888;
|
|
16
|
+
--color-gray-600: #666666;
|
|
17
|
+
--color-gray-700: #4D4D4D;
|
|
18
|
+
--color-gray-800: #333333;
|
|
19
|
+
--color-gray-900: #1A1A1A;
|
|
20
|
+
--color-gray-950: #0D0D0D;
|
|
21
|
+
|
|
22
|
+
--color-green-100: #D1EFD8;
|
|
23
|
+
--color-green-500: #69CB81;
|
|
24
|
+
--color-green-700: #53a567;
|
|
25
|
+
--color-green-900: #2C5536;
|
|
26
|
+
|
|
27
|
+
--color-orange-100: #FBECD9;
|
|
28
|
+
--color-orange-200: #F7D8B3;
|
|
29
|
+
--color-orange-500: #EA9E40;
|
|
30
|
+
|
|
31
|
+
--color-purple-50: #EFE6FD;
|
|
32
|
+
--color-purple-100: #CEB0FA;
|
|
33
|
+
--color-purple-200: #B892F3;
|
|
34
|
+
--color-purple-300: #9B7CDD;
|
|
35
|
+
--color-purple-400: #8470C5;
|
|
36
|
+
--color-purple-500: #694BB4;
|
|
37
|
+
--color-purple-600: #56389B;
|
|
38
|
+
--color-purple-700: #462C83;
|
|
39
|
+
--color-purple-800: #362165;
|
|
40
|
+
--color-purple-900: #27144A;
|
|
41
|
+
--color-purple-950: #1B0D33;
|
|
42
|
+
|
|
43
|
+
--color-blue-50: #F6FAFF;
|
|
44
|
+
--color-blue-100: #D6E3F9;
|
|
45
|
+
--color-blue-200: #99B9EF;
|
|
46
|
+
--color-blue-500: #3272DF;
|
|
47
|
+
--color-blue-600: #285BB2;
|
|
48
|
+
--color-blue-800: #1A4080;
|
|
49
|
+
|
|
50
|
+
--color-red-50: #FFF9F9;
|
|
51
|
+
--color-red-100: #FBE0E2;
|
|
52
|
+
--color-red-200: #F7C2C5;
|
|
53
|
+
--color-red-300: #F4A3A7;
|
|
54
|
+
--color-red-400: #E3798A;
|
|
55
|
+
--color-red-500: #DC576D;
|
|
56
|
+
--color-red-600: #D53550;
|
|
57
|
+
--color-red-700: #BB273F;
|
|
58
|
+
--color-red-900: #5C252E;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
/* non light-theme overrides */
|
|
62
|
+
@layer base {
|
|
63
|
+
/* dark theme */
|
|
64
|
+
@variant dark {
|
|
65
|
+
--color-primary: var(--color-purple-400);
|
|
66
|
+
--color-positive: var(--color-green-700);
|
|
67
|
+
--color-negative: var(--color-red-700);
|
|
68
|
+
--color-negative-border-hover: var(--color-red-600);
|
|
69
|
+
|
|
70
|
+
--color-focus: var(--color-purple-500);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
@import './variants.css';
|
|
2
|
+
@import './colors-semantic.css';
|
|
3
|
+
|
|
4
|
+
/*
|
|
5
|
+
* default light-theme component colors
|
|
6
|
+
*/
|
|
7
|
+
@theme {
|
|
8
|
+
/* Button Outline */
|
|
9
|
+
--color-button-outline-primary-outline: var(--color-primary);
|
|
10
|
+
--color-button-outline-primary-icon: var(--color-primary);
|
|
11
|
+
--color-button-outline-primary-text: var(--color-primary);
|
|
12
|
+
|
|
13
|
+
/* Button Solid */
|
|
14
|
+
--color-button-solid-primary-background: var(--color-primary);
|
|
15
|
+
--color-button-solid-primary-text: var(--color-on-primary);
|
|
16
|
+
--color-button-solid-primary-icon: var(--color-on-primary);
|
|
17
|
+
--color-button-solid-secondary-background: var(--color-purple-50);
|
|
18
|
+
--color-button-solid-secondary-text: var(--color-primary);
|
|
19
|
+
--color-button-solid-secondary-icon: var(--color-primary);
|
|
20
|
+
--color-button-solid-tertiary-background: #F2F2F2;
|
|
21
|
+
--color-button-solid-tertiary-icon: #888888;
|
|
22
|
+
--color-button-solid-tertiary-text: #888888;
|
|
23
|
+
--color-button-solid-neutral-background: #D6D6D6;
|
|
24
|
+
--color-button-solid-neutral-icon: #1A1A1A;
|
|
25
|
+
--color-button-solid-neutral-text: #1A1A1A;
|
|
26
|
+
--color-button-solid-positive-background: var(--color-positive);
|
|
27
|
+
--color-button-solid-positive-icon: var(--color-on-positive);
|
|
28
|
+
--color-button-solid-positive-text: var(--color-on-positive);
|
|
29
|
+
--color-button-solid-warning-background: var(--color-warning);
|
|
30
|
+
--color-button-solid-warning-icon: var(--color-on-warning);
|
|
31
|
+
--color-button-solid-warning-text: var(--color-on-warning);
|
|
32
|
+
--color-button-solid-negative-background: var(--color-negative);
|
|
33
|
+
--color-button-solid-negative-icon: var(--color-on-negative);
|
|
34
|
+
--color-button-solid-negative-text: var(--color-on-negative);
|
|
35
|
+
|
|
36
|
+
/* Button Text */
|
|
37
|
+
--color-button-text-hover-background: #77777733;
|
|
38
|
+
--color-button-text-neutral-text: #333333;
|
|
39
|
+
--color-button-text-neutral-icon: #333333;
|
|
40
|
+
--color-button-text-negative-text: var(--color-negative);
|
|
41
|
+
--color-button-text-negative-icon: var(--color-negative);
|
|
42
|
+
--color-button-text-primary-text: var(--color-primary);
|
|
43
|
+
--color-button-text-primary-icon: var(--color-primary);
|
|
44
|
+
|
|
45
|
+
/* Carousel */
|
|
46
|
+
--color-carousel-dot-active: var(--color-primary);
|
|
47
|
+
--color-carousel-dot-disabled: var(--color-disabled-background);
|
|
48
|
+
|
|
49
|
+
/* Menu */
|
|
50
|
+
--color-menu-background: var(--color-surface);
|
|
51
|
+
--color-menu-text: var(--color-on-surface);
|
|
52
|
+
--color-menu-border: var(--color-border);
|
|
53
|
+
|
|
54
|
+
/* Overlay */
|
|
55
|
+
--color-overlay-background: #FFFFFF;
|
|
56
|
+
--color-overlay-text: var(--color-text-dark);
|
|
57
|
+
|
|
58
|
+
/* ProgressIndicator */
|
|
59
|
+
--color-progress-indicator-fill: var(--color-primary);
|
|
60
|
+
--color-progress-indicator-background: var(--color-gray-300);
|
|
61
|
+
|
|
62
|
+
/* Property */
|
|
63
|
+
--color-property-title-background: #E6E6E6;
|
|
64
|
+
--color-property-title-text: var(--color-text-default);
|
|
65
|
+
|
|
66
|
+
/* Stepper Bar */
|
|
67
|
+
--color-stepperbar-dot-active: var(--color-primary);
|
|
68
|
+
--color-stepperbar-dot-normal: var(--color-purple-100);
|
|
69
|
+
--color-stepperbar-dot-disabled: var(--color-disabled-background);
|
|
70
|
+
|
|
71
|
+
/* Table */
|
|
72
|
+
--color-tabel-header-background: #F6FAFF;
|
|
73
|
+
--color-table-row-hover-background: var(--color-purple-50);
|
|
74
|
+
--color-table-row-hover-text: var(--color-text-default);
|
|
75
|
+
|
|
76
|
+
/* Tag */
|
|
77
|
+
--color-tag-dark-background: #333333;
|
|
78
|
+
--color-tag-dark-text: var(--color-text-light);
|
|
79
|
+
--color-tag-dark-icon: var(--color-text-light);
|
|
80
|
+
--color-tag-green-background: #E2E9DB;
|
|
81
|
+
--color-tag-green-text: #7A977E;
|
|
82
|
+
--color-tag-green-icon: #7A977E;
|
|
83
|
+
--color-tag-yellow-background: #FEEACB;
|
|
84
|
+
--color-tag-yellow-text: #C79345;
|
|
85
|
+
--color-tag-yellow-icon: #C79345;
|
|
86
|
+
--color-tag-red-background: #FEE0DD;
|
|
87
|
+
--color-tag-red-text: #D67268;
|
|
88
|
+
--color-tag-red-icon: #D67268;
|
|
89
|
+
--color-tag-blue-background: var(--color-blue-50);
|
|
90
|
+
--color-tag-blue-text: var(--color-blue-800);
|
|
91
|
+
--color-tag-blue-icon: var(--color-blue-800);
|
|
92
|
+
--color-tag-pink-background: #CEA3B8;
|
|
93
|
+
--color-tag-pink-text: #CE75A0;
|
|
94
|
+
--color-tag-pink-icon: #CE75A0;
|
|
95
|
+
|
|
96
|
+
/* TextImage */
|
|
97
|
+
--color-text-image-primary-background: var(--color-primary);
|
|
98
|
+
--color-text-image-primary-text: var(--color-white);
|
|
99
|
+
--color-text-image-secondary-background: #3171DE;
|
|
100
|
+
--color-text-image-secondary-text: var(--color-white);
|
|
101
|
+
--color-text-image-dark-background: #11243E;
|
|
102
|
+
--color-text-image-dark-text: var(--color-white);
|
|
103
|
+
|
|
104
|
+
/* Tooltip */
|
|
105
|
+
--color-tooltip-background: var(--color-overlay-background);
|
|
106
|
+
--color-tooltip-text: var(--color-description);
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
/* non light-theme overrides */
|
|
110
|
+
@layer base {
|
|
111
|
+
/* dark theme */
|
|
112
|
+
@variant dark {
|
|
113
|
+
/* Button Solid */
|
|
114
|
+
--color-button-solid-neutral-background: #424242;
|
|
115
|
+
--color-button-solid-neutral-icon: var(--color-text-light);
|
|
116
|
+
--color-button-solid-neutral-text: var(--color-text-light);
|
|
117
|
+
|
|
118
|
+
/* Button Text */
|
|
119
|
+
--color-button-text-hover-background: #3F3F3F;
|
|
120
|
+
--color-button-text-neutral-text: var(--color-text-light);
|
|
121
|
+
--color-button-text-neutral-icon: var(--color-text-light);
|
|
122
|
+
|
|
123
|
+
/* Menu */
|
|
124
|
+
--color-menu-background: #333333;
|
|
125
|
+
--color-menu-text: var(--color-text-light);
|
|
126
|
+
--color-menu-border: var(--color-border);
|
|
127
|
+
|
|
128
|
+
/* Property */
|
|
129
|
+
--color-property-title-background: #393939;
|
|
130
|
+
--color-property-title-text: var(--color-on-surface);
|
|
131
|
+
|
|
132
|
+
/* ProgressIndicator */
|
|
133
|
+
--color-progress-indicator-background: var(--color-gray-700);
|
|
134
|
+
|
|
135
|
+
/* Overlay */
|
|
136
|
+
--color-overlay-background: #2A2A2A;
|
|
137
|
+
--color-overlay-text: var(--color-text-light);
|
|
138
|
+
|
|
139
|
+
/* Table */
|
|
140
|
+
--color-tabel-header-background: #2F2F2F;
|
|
141
|
+
--color-table-row-hover-background: #2f2841;
|
|
142
|
+
}
|
|
143
|
+
}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
@import './variants.css';
|
|
2
|
+
@import './colors-basic.css';
|
|
3
|
+
|
|
4
|
+
/*
|
|
5
|
+
* default light-theme sematic colors
|
|
6
|
+
*/
|
|
7
|
+
@theme {
|
|
8
|
+
--color-text-dark: #1A1A1A;
|
|
9
|
+
--color-text-light: #E6E6E6;
|
|
10
|
+
--color-text-default: var(--color-text-dark);
|
|
11
|
+
|
|
12
|
+
--color-primary: var(--color-purple-500);
|
|
13
|
+
--color-on-primary: var(--color-text-light);
|
|
14
|
+
--color-secondary: #11243E;
|
|
15
|
+
--color-on-secondary: var(--color-text-light);
|
|
16
|
+
--color-warning: var(--color-yellow-500);
|
|
17
|
+
--color-on-warning: var(--color-text-light);
|
|
18
|
+
--color-positive: var(--color-green-500);
|
|
19
|
+
--color-on-positive: var(--color-text-light);
|
|
20
|
+
--color-negative: var(--color-red-500);
|
|
21
|
+
--color-on-negative: var(--color-text-light);
|
|
22
|
+
--color-negative-border: var(--color-negative);
|
|
23
|
+
--color-negative-border-hover: var(--color-red-700);
|
|
24
|
+
--color-surface: #FFFFFF;
|
|
25
|
+
--color-on-surface: var(--color-text-dark);
|
|
26
|
+
--color-surface-variant: #F8F8F8;
|
|
27
|
+
--color-surface-warning: #FBECD9;
|
|
28
|
+
--color-highlight: #3272DF;
|
|
29
|
+
--color-background: #EEEEEE;
|
|
30
|
+
--color-on-background: var(--color-text-dark);
|
|
31
|
+
|
|
32
|
+
--color-female: var(--color-red-400);
|
|
33
|
+
--color-female-outline: var(--color-red-300);
|
|
34
|
+
--color-female-surface: var(--color-red-100);
|
|
35
|
+
--color-female-background: var(--color-red-50);
|
|
36
|
+
|
|
37
|
+
--color-male: var(--color-blue-400);
|
|
38
|
+
--color-male-outline: var(--color-blue-300);
|
|
39
|
+
--color-male-surface: var(--color-blue-100);
|
|
40
|
+
--color-male-background: var(--color-blue-50);
|
|
41
|
+
|
|
42
|
+
--color-neutral: #4D4D4D;
|
|
43
|
+
--color-neutral-outline: #B3B3B3;
|
|
44
|
+
--color-neutral-surface: #E6E6E6;
|
|
45
|
+
--color-neutral-background: #F8F8F8;
|
|
46
|
+
|
|
47
|
+
--color-text-primary: var(--color-text-default);
|
|
48
|
+
--color-text-secondary: #666666;
|
|
49
|
+
--color-text-tertiary: #B3B3B3;
|
|
50
|
+
--color-text-highlight: #3272DF;
|
|
51
|
+
--color-text-label: #4D4D4D;
|
|
52
|
+
--color-icon-primary: var(--color-text-primary);
|
|
53
|
+
--color-icon-secondary: var(--color-text-secondary);
|
|
54
|
+
--color-icon-highlight: var(--color-text-highlight);
|
|
55
|
+
--color-divider: #E6E6E6;
|
|
56
|
+
--color-description: #555555;
|
|
57
|
+
--color-outline: #E6E6E6;
|
|
58
|
+
--color-outline-variant: #CCCCCC;
|
|
59
|
+
--color-disabled-background: #BBBBBB;
|
|
60
|
+
--color-disabled-text: #555555;
|
|
61
|
+
--color-disabled-icon: #555555;
|
|
62
|
+
--color-disabled-border: #999999;
|
|
63
|
+
--color-disabled-outline: #999999;
|
|
64
|
+
--color-border: #CCCCCC;
|
|
65
|
+
|
|
66
|
+
--color-focus: var(--color-purple-400);
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
/* non light-theme overrides */
|
|
70
|
+
@layer base {
|
|
71
|
+
/* dark theme */
|
|
72
|
+
@variant dark {
|
|
73
|
+
--color-text-default: var(--color-text-light);
|
|
74
|
+
|
|
75
|
+
--color-surface: #333333;
|
|
76
|
+
--color-on-surface: var(--color-text-light);
|
|
77
|
+
--color-surface-variant: #494949;
|
|
78
|
+
--color-surface-warning: #FBECD9;
|
|
79
|
+
--color-text-label: #CFCFCF;
|
|
80
|
+
--color-highlight: #3272DF;
|
|
81
|
+
--color-background: #222222;
|
|
82
|
+
--color-on-background: var(--color-text-light);
|
|
83
|
+
--color-border: #444444;
|
|
84
|
+
|
|
85
|
+
--color-neutral: #4D4D4D;
|
|
86
|
+
--color-neutral-outline: #B3B3B3;
|
|
87
|
+
--color-neutral-surface: #E6E6E6;
|
|
88
|
+
--color-neutral-background: #F8F8F8;
|
|
89
|
+
|
|
90
|
+
--color-text-primary: var(--color-text-light);
|
|
91
|
+
--color-text-secondary: #666666;
|
|
92
|
+
--color-text-tertiary: #B3B3B3;
|
|
93
|
+
--color-text-highlight: #3272DF;
|
|
94
|
+
--color-description: #999999;
|
|
95
|
+
|
|
96
|
+
--color-disabled-background: #555555;
|
|
97
|
+
--color-disabled-text: #999999;
|
|
98
|
+
}
|
|
99
|
+
}
|
|
File without changes
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
@layer utilities {
|
|
2
|
+
.animation-delay-0 {
|
|
3
|
+
animation-delay: 0ms;
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
.animation-delay-100 {
|
|
7
|
+
animation-delay: 100ms;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.animation-delay-200 {
|
|
11
|
+
animation-delay: 200ms;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.animation-delay-300 {
|
|
15
|
+
animation-delay: 300ms;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.animation-delay-400 {
|
|
19
|
+
animation-delay: 400ms;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.animation-delay-500 {
|
|
23
|
+
animation-delay: 500ms;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.animation-delay-1000 {
|
|
27
|
+
animation-delay: 1000ms;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
@keyframes fade-in {
|
|
31
|
+
0% {
|
|
32
|
+
opacity: 0;
|
|
33
|
+
}
|
|
34
|
+
100% {
|
|
35
|
+
opacity: 1;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
@keyframes fade-out {
|
|
40
|
+
0% {
|
|
41
|
+
opacity: 1;
|
|
42
|
+
}
|
|
43
|
+
100% {
|
|
44
|
+
opacity: 0;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
@keyframes bigLeftUp {
|
|
49
|
+
0%, 25% {
|
|
50
|
+
stroke-dashoffset: 1000;
|
|
51
|
+
}
|
|
52
|
+
50%, 75%, 100% {
|
|
53
|
+
stroke-dashoffset: 0;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
@keyframes bigRightDown {
|
|
58
|
+
0%, 25%, 50% {
|
|
59
|
+
stroke-dashoffset: 0;
|
|
60
|
+
}
|
|
61
|
+
75%, 100% {
|
|
62
|
+
stroke-dashoffset: -1000;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
@keyframes smallLeftUp {
|
|
67
|
+
0%, 25%, 50% {
|
|
68
|
+
stroke-dashoffset: 1000;
|
|
69
|
+
}
|
|
70
|
+
75%, 100% {
|
|
71
|
+
stroke-dashoffset: 0;
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
@keyframes smallRightDown {
|
|
76
|
+
0%, 25% {
|
|
77
|
+
stroke-dashoffset: 0;
|
|
78
|
+
}
|
|
79
|
+
50%, 75%, 100% {
|
|
80
|
+
stroke-dashoffset: -1000;
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.animate-fade {
|
|
85
|
+
animation: fade-out 3s ease-in-out;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.animate-wave-big-left-up {
|
|
89
|
+
animation: bigLeftUp 1.7s ease-in infinite normal;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.animate-wave-big-right-down {
|
|
93
|
+
animation: bigRightDown 1.7s ease-in infinite reverse;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.animate-wave-small-left-up {
|
|
97
|
+
animation: smallLeftUp 1.7s ease-in infinite normal;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.animate-wave-small-right-down {
|
|
101
|
+
animation: smallRightDown 1.7s ease-in infinite reverse;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.animate-tooltip-fade-in {
|
|
105
|
+
animation: fade-in 0.2s ease-in-out forwards;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.animate-tooltip-fade-out {
|
|
109
|
+
animation: fade-in 0.2s ease-in-out forwards;
|
|
110
|
+
}
|
|
111
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
@utility rounded-* {
|
|
2
|
+
border-radius: calc(var(--spacing) * --value(number));
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
@utility rounded-t-* {
|
|
6
|
+
border-top-left-radius: calc(var(--spacing) * --value(number));
|
|
7
|
+
border-top-right-radius: calc(var(--spacing) * --value(number));
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
@utility rounded-r-* {
|
|
11
|
+
border-top-right-radius: calc(var(--spacing) * --value(number));
|
|
12
|
+
border-bottom-left-radius: calc(var(--spacing) * --value(number));
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
@utility rounded-b-* {
|
|
16
|
+
border-bottom-left-radius: calc(var(--spacing) * --value(number));
|
|
17
|
+
border-bottom-right-radius: calc(var(--spacing) * --value(number));
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
@utility rounded-l-* {
|
|
21
|
+
border-top-left-radius: calc(var(--spacing) * --value(number));
|
|
22
|
+
border-bottom-left-radius: calc(var(--spacing) * --value(number));
|
|
23
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
@utility col {
|
|
2
|
+
@apply flex flex-col gap-y-2;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
@utility row {
|
|
6
|
+
@apply flex flex-row gap-x-2;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
@utility input-indicator-hidden {
|
|
10
|
+
@apply appearance-none [&::-webkit-inner-spin-button]:appearance-none [&::-webkit-outer-spin-button]:appearance-none [-moz-appearance:textfield];
|
|
11
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
@layer utilities {
|
|
2
|
+
.shadow-around {
|
|
3
|
+
box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.02),
|
|
4
|
+
0 -2px 2px 0 rgba(0, 0, 0, 0.02),
|
|
5
|
+
2px 0 2px 0 rgba(0, 0, 0, 0.02),
|
|
6
|
+
-2px 0 2px 0 rgba(0, 0, 0, 0.02);
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.shadow-around-md {
|
|
10
|
+
box-shadow: 0 5px 5px 0 rgba(0, 0, 0, 0.02),
|
|
11
|
+
0 -5px 5px 0 rgba(0, 0, 0, 0.02),
|
|
12
|
+
5px 0 5px 0 rgba(0, 0, 0, 0.02),
|
|
13
|
+
-5px 0 5px 0 rgba(0, 0, 0, 0.02);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.shadow-around-lg {
|
|
17
|
+
box-shadow: 0 10px 10px 0 rgba(0, 0, 0, 0.02),
|
|
18
|
+
0 -10px 10px 0 rgba(0, 0, 0, 0.02),
|
|
19
|
+
10px 0 10px 0 rgba(0, 0, 0, 0.02),
|
|
20
|
+
-10px 0 10px 0 rgba(0, 0, 0, 0.02);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.shadow-around-xl {
|
|
24
|
+
box-shadow: 0 20px 20px 0 rgba(0, 0, 0, 0.02),
|
|
25
|
+
0 -20px 20px 0 rgba(0, 0, 0, 0.02),
|
|
26
|
+
20px 0 20px 0 rgba(0, 0, 0, 0.02),
|
|
27
|
+
-20px 0 20px 0 rgba(0, 0, 0, 0.02);
|
|
28
|
+
}
|
|
29
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
type UseDelayOptionsResolved = {
|
|
2
|
+
delay: number;
|
|
3
|
+
disabled: boolean;
|
|
4
|
+
};
|
|
5
|
+
type UseDelayOptions = Partial<UseDelayOptionsResolved>;
|
|
6
|
+
declare function useDelay(options?: UseDelayOptions): {
|
|
7
|
+
restartTimer: (onDelayFinish: () => void) => void;
|
|
8
|
+
clearTimer: () => void;
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export { type UseDelayOptions, type UseDelayOptionsResolved, useDelay };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
type UseDelayOptionsResolved = {
|
|
2
|
+
delay: number;
|
|
3
|
+
disabled: boolean;
|
|
4
|
+
};
|
|
5
|
+
type UseDelayOptions = Partial<UseDelayOptionsResolved>;
|
|
6
|
+
declare function useDelay(options?: UseDelayOptions): {
|
|
7
|
+
restartTimer: (onDelayFinish: () => void) => void;
|
|
8
|
+
clearTimer: () => void;
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export { type UseDelayOptions, type UseDelayOptionsResolved, useDelay };
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
|
|
19
|
+
// src/hooks/useDelay.ts
|
|
20
|
+
var useDelay_exports = {};
|
|
21
|
+
__export(useDelay_exports, {
|
|
22
|
+
useDelay: () => useDelay
|
|
23
|
+
});
|
|
24
|
+
module.exports = __toCommonJS(useDelay_exports);
|
|
25
|
+
var import_react = require("react");
|
|
26
|
+
var defaultOptions = {
|
|
27
|
+
delay: 3e3,
|
|
28
|
+
disabled: false
|
|
29
|
+
};
|
|
30
|
+
function useDelay(options) {
|
|
31
|
+
const [timer, setTimer] = (0, import_react.useState)(void 0);
|
|
32
|
+
const { delay, disabled } = {
|
|
33
|
+
...defaultOptions,
|
|
34
|
+
...options
|
|
35
|
+
};
|
|
36
|
+
const restartTimer = (onDelayFinish) => {
|
|
37
|
+
if (disabled) {
|
|
38
|
+
return;
|
|
39
|
+
}
|
|
40
|
+
clearTimeout(timer);
|
|
41
|
+
setTimer(setTimeout(() => {
|
|
42
|
+
onDelayFinish();
|
|
43
|
+
}, delay));
|
|
44
|
+
};
|
|
45
|
+
const clearTimer = () => {
|
|
46
|
+
clearTimeout(timer);
|
|
47
|
+
};
|
|
48
|
+
(0, import_react.useEffect)(() => {
|
|
49
|
+
return () => {
|
|
50
|
+
clearTimeout(timer);
|
|
51
|
+
};
|
|
52
|
+
}, [timer]);
|
|
53
|
+
(0, import_react.useEffect)(() => {
|
|
54
|
+
if (disabled) {
|
|
55
|
+
clearTimeout(timer);
|
|
56
|
+
}
|
|
57
|
+
}, [disabled, timer]);
|
|
58
|
+
return { restartTimer, clearTimer };
|
|
59
|
+
}
|
|
60
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
61
|
+
0 && (module.exports = {
|
|
62
|
+
useDelay
|
|
63
|
+
});
|
|
64
|
+
//# sourceMappingURL=useDelay.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/hooks/useDelay.ts"],"sourcesContent":["import { useEffect, useState } from 'react'\n\nexport type UseDelayOptionsResolved = {\n delay: number,\n disabled: boolean,\n}\n\nexport type UseDelayOptions = Partial<UseDelayOptionsResolved>\n\nconst defaultOptions: UseDelayOptionsResolved = {\n delay: 3000,\n disabled: false,\n}\n\nexport function useDelay(options?: UseDelayOptions) {\n const [timer, setTimer] = useState<NodeJS.Timeout | undefined>(undefined)\n const { delay, disabled }: UseDelayOptionsResolved = {\n ...defaultOptions,\n ...options\n }\n\n const restartTimer = (onDelayFinish: () => void) => {\n if(disabled) {\n return\n }\n clearTimeout(timer)\n setTimer(setTimeout(() => {\n onDelayFinish()\n }, delay))\n }\n\n const clearTimer = () => {\n clearTimeout(timer)\n }\n\n useEffect(() => {\n return () => {\n clearTimeout(timer)\n }\n }, [timer])\n\n useEffect(() => {\n if(disabled){\n clearTimeout(timer)\n }\n }, [disabled, timer])\n\n return { restartTimer, clearTimer }\n}"],"mappings":";;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAAoC;AASpC,IAAM,iBAA0C;AAAA,EAC9C,OAAO;AAAA,EACP,UAAU;AACZ;AAEO,SAAS,SAAS,SAA2B;AAClD,QAAM,CAAC,OAAO,QAAQ,QAAI,uBAAqC,MAAS;AACxE,QAAM,EAAE,OAAO,SAAS,IAA6B;AAAA,IACnD,GAAG;AAAA,IACH,GAAG;AAAA,EACL;AAEA,QAAM,eAAe,CAAC,kBAA8B;AAClD,QAAG,UAAU;AACX;AAAA,IACF;AACA,iBAAa,KAAK;AAClB,aAAS,WAAW,MAAM;AACxB,oBAAc;AAAA,IAChB,GAAG,KAAK,CAAC;AAAA,EACX;AAEA,QAAM,aAAa,MAAM;AACvB,iBAAa,KAAK;AAAA,EACpB;AAEA,8BAAU,MAAM;AACd,WAAO,MAAM;AACX,mBAAa,KAAK;AAAA,IACpB;AAAA,EACF,GAAG,CAAC,KAAK,CAAC;AAEV,8BAAU,MAAM;AACd,QAAG,UAAS;AACV,mBAAa,KAAK;AAAA,IACpB;AAAA,EACF,GAAG,CAAC,UAAU,KAAK,CAAC;AAEpB,SAAO,EAAE,cAAc,WAAW;AACpC;","names":[]}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
// src/hooks/useDelay.ts
|
|
2
|
+
import { useEffect, useState } from "react";
|
|
3
|
+
var defaultOptions = {
|
|
4
|
+
delay: 3e3,
|
|
5
|
+
disabled: false
|
|
6
|
+
};
|
|
7
|
+
function useDelay(options) {
|
|
8
|
+
const [timer, setTimer] = useState(void 0);
|
|
9
|
+
const { delay, disabled } = {
|
|
10
|
+
...defaultOptions,
|
|
11
|
+
...options
|
|
12
|
+
};
|
|
13
|
+
const restartTimer = (onDelayFinish) => {
|
|
14
|
+
if (disabled) {
|
|
15
|
+
return;
|
|
16
|
+
}
|
|
17
|
+
clearTimeout(timer);
|
|
18
|
+
setTimer(setTimeout(() => {
|
|
19
|
+
onDelayFinish();
|
|
20
|
+
}, delay));
|
|
21
|
+
};
|
|
22
|
+
const clearTimer = () => {
|
|
23
|
+
clearTimeout(timer);
|
|
24
|
+
};
|
|
25
|
+
useEffect(() => {
|
|
26
|
+
return () => {
|
|
27
|
+
clearTimeout(timer);
|
|
28
|
+
};
|
|
29
|
+
}, [timer]);
|
|
30
|
+
useEffect(() => {
|
|
31
|
+
if (disabled) {
|
|
32
|
+
clearTimeout(timer);
|
|
33
|
+
}
|
|
34
|
+
}, [disabled, timer]);
|
|
35
|
+
return { restartTimer, clearTimer };
|
|
36
|
+
}
|
|
37
|
+
export {
|
|
38
|
+
useDelay
|
|
39
|
+
};
|
|
40
|
+
//# sourceMappingURL=useDelay.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/hooks/useDelay.ts"],"sourcesContent":["import { useEffect, useState } from 'react'\n\nexport type UseDelayOptionsResolved = {\n delay: number,\n disabled: boolean,\n}\n\nexport type UseDelayOptions = Partial<UseDelayOptionsResolved>\n\nconst defaultOptions: UseDelayOptionsResolved = {\n delay: 3000,\n disabled: false,\n}\n\nexport function useDelay(options?: UseDelayOptions) {\n const [timer, setTimer] = useState<NodeJS.Timeout | undefined>(undefined)\n const { delay, disabled }: UseDelayOptionsResolved = {\n ...defaultOptions,\n ...options\n }\n\n const restartTimer = (onDelayFinish: () => void) => {\n if(disabled) {\n return\n }\n clearTimeout(timer)\n setTimer(setTimeout(() => {\n onDelayFinish()\n }, delay))\n }\n\n const clearTimer = () => {\n clearTimeout(timer)\n }\n\n useEffect(() => {\n return () => {\n clearTimeout(timer)\n }\n }, [timer])\n\n useEffect(() => {\n if(disabled){\n clearTimeout(timer)\n }\n }, [disabled, timer])\n\n return { restartTimer, clearTimer }\n}"],"mappings":";AAAA,SAAS,WAAW,gBAAgB;AASpC,IAAM,iBAA0C;AAAA,EAC9C,OAAO;AAAA,EACP,UAAU;AACZ;AAEO,SAAS,SAAS,SAA2B;AAClD,QAAM,CAAC,OAAO,QAAQ,IAAI,SAAqC,MAAS;AACxE,QAAM,EAAE,OAAO,SAAS,IAA6B;AAAA,IACnD,GAAG;AAAA,IACH,GAAG;AAAA,EACL;AAEA,QAAM,eAAe,CAAC,kBAA8B;AAClD,QAAG,UAAU;AACX;AAAA,IACF;AACA,iBAAa,KAAK;AAClB,aAAS,WAAW,MAAM;AACxB,oBAAc;AAAA,IAChB,GAAG,KAAK,CAAC;AAAA,EACX;AAEA,QAAM,aAAa,MAAM;AACvB,iBAAa,KAAK;AAAA,EACpB;AAEA,YAAU,MAAM;AACd,WAAO,MAAM;AACX,mBAAa,KAAK;AAAA,IACpB;AAAA,EACF,GAAG,CAAC,KAAK,CAAC;AAEV,YAAU,MAAM;AACd,QAAG,UAAS;AACV,mBAAa,KAAK;AAAA,IACpB;AAAA,EACF,GAAG,CAAC,UAAU,KAAK,CAAC;AAEpB,SAAO,EAAE,cAAc,WAAW;AACpC;","names":[]}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
declare function useFocusManagement(): {
|
|
2
|
+
getFocusableElements: () => HTMLElement[];
|
|
3
|
+
getNextFocusElement: () => HTMLElement | undefined;
|
|
4
|
+
getPreviousFocusElement: () => HTMLElement | undefined;
|
|
5
|
+
focusNext: () => void;
|
|
6
|
+
focusPrevious: () => void;
|
|
7
|
+
};
|
|
8
|
+
|
|
9
|
+
export { useFocusManagement };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
declare function useFocusManagement(): {
|
|
2
|
+
getFocusableElements: () => HTMLElement[];
|
|
3
|
+
getNextFocusElement: () => HTMLElement | undefined;
|
|
4
|
+
getPreviousFocusElement: () => HTMLElement | undefined;
|
|
5
|
+
focusNext: () => void;
|
|
6
|
+
focusPrevious: () => void;
|
|
7
|
+
};
|
|
8
|
+
|
|
9
|
+
export { useFocusManagement };
|