@helpwave/hightide 0.1.25 → 0.1.26
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/README.md +1 -1
- package/dist/components/branding/HelpwaveBadge.d.mts +4 -5
- package/dist/components/branding/HelpwaveBadge.d.ts +4 -5
- package/dist/components/branding/HelpwaveBadge.js +46 -87
- package/dist/components/branding/HelpwaveBadge.js.map +1 -1
- package/dist/components/branding/HelpwaveBadge.mjs +46 -89
- package/dist/components/branding/HelpwaveBadge.mjs.map +1 -1
- package/dist/components/date/DatePicker.d.mts +1 -1
- package/dist/components/date/DatePicker.d.ts +1 -1
- package/dist/components/date/DatePicker.js +64 -13
- package/dist/components/date/DatePicker.js.map +1 -1
- package/dist/components/date/DatePicker.mjs +65 -14
- package/dist/components/date/DatePicker.mjs.map +1 -1
- package/dist/components/date/DayPicker.d.mts +1 -1
- package/dist/components/date/DayPicker.d.ts +1 -1
- package/dist/components/date/DayPicker.js +3 -3
- package/dist/components/date/DayPicker.js.map +1 -1
- package/dist/components/date/DayPicker.mjs +3 -3
- package/dist/components/date/DayPicker.mjs.map +1 -1
- package/dist/components/date/TimeDisplay.js.map +1 -1
- package/dist/components/date/TimeDisplay.mjs.map +1 -1
- package/dist/components/date/TimePicker.js +2 -2
- package/dist/components/date/TimePicker.js.map +1 -1
- package/dist/components/date/TimePicker.mjs +2 -2
- package/dist/components/date/TimePicker.mjs.map +1 -1
- package/dist/components/date/YearMonthPicker.js +58 -7
- package/dist/components/date/YearMonthPicker.js.map +1 -1
- package/dist/components/date/YearMonthPicker.mjs +59 -8
- package/dist/components/date/YearMonthPicker.mjs.map +1 -1
- package/dist/components/{dialogs → dialog}/ConfirmDialog.d.mts +9 -8
- package/dist/components/{dialogs → dialog}/ConfirmDialog.d.ts +9 -8
- package/dist/components/dialog/ConfirmDialog.js +938 -0
- package/dist/components/dialog/ConfirmDialog.js.map +1 -0
- package/dist/components/dialog/ConfirmDialog.mjs +902 -0
- package/dist/components/dialog/ConfirmDialog.mjs.map +1 -0
- package/dist/components/dialog/Dialog.d.mts +27 -0
- package/dist/components/dialog/Dialog.d.ts +27 -0
- package/dist/components/dialog/Dialog.js +879 -0
- package/dist/components/dialog/Dialog.js.map +1 -0
- package/dist/components/dialog/Dialog.mjs +845 -0
- package/dist/components/dialog/Dialog.mjs.map +1 -0
- package/dist/components/dialog/DiscardChangesDialog.d.mts +24 -0
- package/dist/components/dialog/DiscardChangesDialog.d.ts +24 -0
- package/dist/components/dialog/DiscardChangesDialog.js +966 -0
- package/dist/components/dialog/DiscardChangesDialog.js.map +1 -0
- package/dist/components/dialog/DiscardChangesDialog.mjs +930 -0
- package/dist/components/dialog/DiscardChangesDialog.mjs.map +1 -0
- package/dist/components/dialog/InputDialog.d.mts +22 -0
- package/dist/components/dialog/InputDialog.d.ts +22 -0
- package/dist/components/dialog/InputDialog.js +1139 -0
- package/dist/components/dialog/InputDialog.js.map +1 -0
- package/dist/components/dialog/InputDialog.mjs +1103 -0
- package/dist/components/dialog/InputDialog.mjs.map +1 -0
- package/dist/components/dialog/LanguageDialog.d.mts +25 -0
- package/dist/components/dialog/LanguageDialog.d.ts +25 -0
- package/dist/components/dialog/LanguageDialog.js +1684 -0
- package/dist/components/dialog/LanguageDialog.js.map +1 -0
- package/dist/components/dialog/LanguageDialog.mjs +1658 -0
- package/dist/components/dialog/LanguageDialog.mjs.map +1 -0
- package/dist/components/dialog/ThemeDialog.d.mts +26 -0
- package/dist/components/dialog/ThemeDialog.d.ts +26 -0
- package/dist/components/dialog/ThemeDialog.js +1715 -0
- package/dist/components/dialog/ThemeDialog.js.map +1 -0
- package/dist/components/dialog/ThemeDialog.mjs +1689 -0
- package/dist/components/dialog/ThemeDialog.mjs.map +1 -0
- package/dist/components/dialog/index.d.mts +17 -0
- package/dist/components/dialog/index.d.ts +17 -0
- package/dist/components/dialog/index.js +2062 -0
- package/dist/components/dialog/index.js.map +1 -0
- package/dist/components/dialog/index.mjs +2031 -0
- package/dist/components/dialog/index.mjs.map +1 -0
- package/dist/components/form/FormElementWrapper.d.mts +29 -0
- package/dist/components/form/FormElementWrapper.d.ts +29 -0
- package/dist/components/form/FormElementWrapper.js +98 -0
- package/dist/components/form/FormElementWrapper.js.map +1 -0
- package/dist/components/form/FormElementWrapper.mjs +64 -0
- package/dist/components/form/FormElementWrapper.mjs.map +1 -0
- package/dist/components/icons-and-geometry/Avatar.js +498 -2886
- package/dist/components/icons-and-geometry/Avatar.js.map +1 -1
- package/dist/components/icons-and-geometry/Avatar.mjs +490 -2878
- package/dist/components/icons-and-geometry/Avatar.mjs.map +1 -1
- package/dist/components/icons-and-geometry/{Helpwave.d.mts → HelpwaveLogo.d.mts} +3 -3
- package/dist/components/icons-and-geometry/{Helpwave.d.ts → HelpwaveLogo.d.ts} +3 -3
- package/dist/components/icons-and-geometry/{Helpwave.js → HelpwaveLogo.js} +21 -22
- package/dist/components/icons-and-geometry/HelpwaveLogo.js.map +1 -0
- package/dist/components/icons-and-geometry/{Helpwave.mjs → HelpwaveLogo.mjs} +17 -18
- package/dist/components/icons-and-geometry/HelpwaveLogo.mjs.map +1 -0
- package/dist/components/icons-and-geometry/Ring.js +1 -1
- package/dist/components/icons-and-geometry/Ring.js.map +1 -1
- package/dist/components/icons-and-geometry/Ring.mjs +1 -1
- package/dist/components/icons-and-geometry/Ring.mjs.map +1 -1
- package/dist/components/icons-and-geometry/Tag.js +8 -20
- package/dist/components/icons-and-geometry/Tag.js.map +1 -1
- package/dist/components/icons-and-geometry/Tag.mjs +8 -20
- package/dist/components/icons-and-geometry/Tag.mjs.map +1 -1
- package/dist/components/layout-and-navigation/BreadCrumb.js +667 -22
- package/dist/components/layout-and-navigation/BreadCrumb.js.map +1 -1
- package/dist/components/layout-and-navigation/BreadCrumb.mjs +667 -22
- package/dist/components/layout-and-navigation/BreadCrumb.mjs.map +1 -1
- package/dist/components/layout-and-navigation/Carousel.js +12 -10
- package/dist/components/layout-and-navigation/Carousel.js.map +1 -1
- package/dist/components/layout-and-navigation/Carousel.mjs +12 -10
- package/dist/components/layout-and-navigation/Carousel.mjs.map +1 -1
- package/dist/components/layout-and-navigation/Chip.d.mts +8 -5
- package/dist/components/layout-and-navigation/Chip.d.ts +8 -5
- package/dist/components/layout-and-navigation/Chip.js +17 -4
- package/dist/components/layout-and-navigation/Chip.js.map +1 -1
- package/dist/components/layout-and-navigation/Chip.mjs +17 -4
- package/dist/components/layout-and-navigation/Chip.mjs.map +1 -1
- package/dist/components/layout-and-navigation/Expandable.d.mts +13 -10
- package/dist/components/layout-and-navigation/Expandable.d.ts +13 -10
- package/dist/components/layout-and-navigation/Expandable.js +18 -5
- package/dist/components/layout-and-navigation/Expandable.js.map +1 -1
- package/dist/components/layout-and-navigation/Expandable.mjs +19 -6
- package/dist/components/layout-and-navigation/Expandable.mjs.map +1 -1
- package/dist/components/layout-and-navigation/FAQSection.js +21 -8
- package/dist/components/layout-and-navigation/FAQSection.js.map +1 -1
- package/dist/components/layout-and-navigation/FAQSection.mjs +22 -9
- package/dist/components/layout-and-navigation/FAQSection.mjs.map +1 -1
- package/dist/components/layout-and-navigation/FloatingContainer.d.mts +38 -0
- package/dist/components/layout-and-navigation/FloatingContainer.d.ts +38 -0
- package/dist/components/layout-and-navigation/FloatingContainer.js +219 -0
- package/dist/components/layout-and-navigation/FloatingContainer.js.map +1 -0
- package/dist/components/layout-and-navigation/FloatingContainer.mjs +195 -0
- package/dist/components/layout-and-navigation/FloatingContainer.mjs.map +1 -0
- package/dist/components/layout-and-navigation/ListBox.d.mts +44 -0
- package/dist/components/layout-and-navigation/ListBox.d.ts +44 -0
- package/dist/components/layout-and-navigation/ListBox.js +329 -0
- package/dist/components/layout-and-navigation/ListBox.js.map +1 -0
- package/dist/components/layout-and-navigation/ListBox.mjs +290 -0
- package/dist/components/layout-and-navigation/ListBox.mjs.map +1 -0
- package/dist/components/layout-and-navigation/Pagination.js +104 -189
- package/dist/components/layout-and-navigation/Pagination.js.map +1 -1
- package/dist/components/layout-and-navigation/Pagination.mjs +99 -184
- package/dist/components/layout-and-navigation/Pagination.mjs.map +1 -1
- package/dist/components/layout-and-navigation/ScrollArea.d.mts +15 -0
- package/dist/components/layout-and-navigation/ScrollArea.d.ts +15 -0
- package/dist/components/layout-and-navigation/ScrollArea.js +1252 -0
- package/dist/components/layout-and-navigation/ScrollArea.js.map +1 -0
- package/dist/components/layout-and-navigation/ScrollArea.mjs +1216 -0
- package/dist/components/layout-and-navigation/ScrollArea.mjs.map +1 -0
- package/dist/components/layout-and-navigation/StepperBar.js +41 -1
- package/dist/components/layout-and-navigation/StepperBar.js.map +1 -1
- package/dist/components/layout-and-navigation/StepperBar.mjs +41 -1
- package/dist/components/layout-and-navigation/StepperBar.mjs.map +1 -1
- package/dist/components/layout-and-navigation/TextImage.js +3 -1
- package/dist/components/layout-and-navigation/TextImage.js.map +1 -1
- package/dist/components/layout-and-navigation/TextImage.mjs +3 -1
- package/dist/components/layout-and-navigation/TextImage.mjs.map +1 -1
- package/dist/components/loading-states/ErrorComponent.js.map +1 -1
- package/dist/components/loading-states/ErrorComponent.mjs.map +1 -1
- package/dist/components/loading-states/LoadingAndErrorComponent.d.mts +1 -1
- package/dist/components/loading-states/LoadingAndErrorComponent.d.ts +1 -1
- package/dist/components/loading-states/LoadingAnimation.js +18 -17
- package/dist/components/loading-states/LoadingAnimation.js.map +1 -1
- package/dist/components/loading-states/LoadingAnimation.mjs +18 -17
- package/dist/components/loading-states/LoadingAnimation.mjs.map +1 -1
- package/dist/components/loading-states/LoadingButton.js +55 -18
- package/dist/components/loading-states/LoadingButton.js.map +1 -1
- package/dist/components/loading-states/LoadingButton.mjs +55 -18
- package/dist/components/loading-states/LoadingButton.mjs.map +1 -1
- package/dist/components/properties/CheckboxProperty.js +890 -135
- package/dist/components/properties/CheckboxProperty.js.map +1 -1
- package/dist/components/properties/CheckboxProperty.mjs +897 -142
- package/dist/components/properties/CheckboxProperty.mjs.map +1 -1
- package/dist/components/properties/DateProperty.js +153 -198
- package/dist/components/properties/DateProperty.js.map +1 -1
- package/dist/components/properties/DateProperty.mjs +146 -191
- package/dist/components/properties/DateProperty.mjs.map +1 -1
- package/dist/components/properties/MultiSelectProperty.d.mts +5 -10
- package/dist/components/properties/MultiSelectProperty.d.ts +5 -10
- package/dist/components/properties/MultiSelectProperty.js +1143 -1160
- package/dist/components/properties/MultiSelectProperty.js.map +1 -1
- package/dist/components/properties/MultiSelectProperty.mjs +1156 -1163
- package/dist/components/properties/MultiSelectProperty.mjs.map +1 -1
- package/dist/components/properties/NumberProperty.js +155 -201
- package/dist/components/properties/NumberProperty.js.map +1 -1
- package/dist/components/properties/NumberProperty.mjs +148 -194
- package/dist/components/properties/NumberProperty.mjs.map +1 -1
- package/dist/components/properties/PropertyBase.js +49 -9
- package/dist/components/properties/PropertyBase.js.map +1 -1
- package/dist/components/properties/PropertyBase.mjs +49 -9
- package/dist/components/properties/PropertyBase.mjs.map +1 -1
- package/dist/components/properties/SelectProperty.d.mts +5 -8
- package/dist/components/properties/SelectProperty.d.ts +5 -8
- package/dist/components/properties/SelectProperty.js +1047 -834
- package/dist/components/properties/SelectProperty.js.map +1 -1
- package/dist/components/properties/SelectProperty.mjs +1063 -840
- package/dist/components/properties/SelectProperty.mjs.map +1 -1
- package/dist/components/properties/TextProperty.js +97 -100
- package/dist/components/properties/TextProperty.js.map +1 -1
- package/dist/components/properties/TextProperty.mjs +100 -103
- package/dist/components/properties/TextProperty.mjs.map +1 -1
- package/dist/components/table/Table.js +1618 -993
- package/dist/components/table/Table.js.map +1 -1
- package/dist/components/table/Table.mjs +1625 -1000
- package/dist/components/table/Table.mjs.map +1 -1
- package/dist/components/table/TableFilterButton.js +116 -201
- package/dist/components/table/TableFilterButton.js.map +1 -1
- package/dist/components/table/TableFilterButton.mjs +105 -190
- package/dist/components/table/TableFilterButton.mjs.map +1 -1
- package/dist/components/table/TableSortButton.js +4 -3
- package/dist/components/table/TableSortButton.js.map +1 -1
- package/dist/components/table/TableSortButton.mjs +4 -3
- package/dist/components/table/TableSortButton.mjs.map +1 -1
- package/dist/components/user-action/Button.d.mts +15 -11
- package/dist/components/user-action/Button.d.ts +15 -11
- package/dist/components/user-action/Button.js +10 -9
- package/dist/components/user-action/Button.js.map +1 -1
- package/dist/components/user-action/Button.mjs +10 -9
- package/dist/components/user-action/Button.mjs.map +1 -1
- package/dist/components/user-action/Checkbox.d.mts +9 -25
- package/dist/components/user-action/Checkbox.d.ts +9 -25
- package/dist/components/user-action/Checkbox.js +793 -103
- package/dist/components/user-action/Checkbox.js.map +1 -1
- package/dist/components/user-action/Checkbox.mjs +794 -104
- package/dist/components/user-action/Checkbox.mjs.map +1 -1
- package/dist/components/user-action/CopyToClipboardWrapper.js +3 -1
- package/dist/components/user-action/CopyToClipboardWrapper.js.map +1 -1
- package/dist/components/user-action/CopyToClipboardWrapper.mjs +3 -1
- package/dist/components/user-action/CopyToClipboardWrapper.mjs.map +1 -1
- package/dist/components/user-action/DateAndTimePicker.d.mts +1 -1
- package/dist/components/user-action/DateAndTimePicker.d.ts +1 -1
- package/dist/components/user-action/DateAndTimePicker.js +66 -13
- package/dist/components/user-action/DateAndTimePicker.js.map +1 -1
- package/dist/components/user-action/DateAndTimePicker.mjs +67 -14
- package/dist/components/user-action/DateAndTimePicker.mjs.map +1 -1
- package/dist/components/user-action/Label.d.mts +6 -8
- package/dist/components/user-action/Label.d.ts +6 -8
- package/dist/components/user-action/Label.js +4 -6
- package/dist/components/user-action/Label.js.map +1 -1
- package/dist/components/user-action/Label.mjs +4 -6
- package/dist/components/user-action/Label.mjs.map +1 -1
- package/dist/components/user-action/Menu.d.mts +2 -2
- package/dist/components/user-action/Menu.d.ts +2 -2
- package/dist/components/user-action/Menu.js +1 -1
- package/dist/components/user-action/Menu.js.map +1 -1
- package/dist/components/user-action/Menu.mjs +1 -1
- package/dist/components/user-action/Menu.mjs.map +1 -1
- package/dist/components/user-action/ScrollPicker.js +8 -6
- package/dist/components/user-action/ScrollPicker.js.map +1 -1
- package/dist/components/user-action/ScrollPicker.mjs +8 -6
- package/dist/components/user-action/ScrollPicker.mjs.map +1 -1
- package/dist/components/user-action/SearchBar.d.mts +1 -2
- package/dist/components/user-action/SearchBar.d.ts +1 -2
- package/dist/components/user-action/SearchBar.js +93 -178
- package/dist/components/user-action/SearchBar.js.map +1 -1
- package/dist/components/user-action/SearchBar.mjs +86 -171
- package/dist/components/user-action/SearchBar.mjs.map +1 -1
- package/dist/components/user-action/Textarea.d.mts +22 -11
- package/dist/components/user-action/Textarea.d.ts +22 -11
- package/dist/components/user-action/Textarea.js +101 -92
- package/dist/components/user-action/Textarea.js.map +1 -1
- package/dist/components/user-action/Textarea.mjs +100 -92
- package/dist/components/user-action/Textarea.mjs.map +1 -1
- package/dist/components/user-action/input/Input.d.mts +37 -0
- package/dist/components/user-action/input/Input.d.ts +37 -0
- package/dist/components/user-action/input/Input.js +244 -0
- package/dist/components/user-action/input/Input.js.map +1 -0
- package/dist/components/user-action/input/Input.mjs +209 -0
- package/dist/components/user-action/input/Input.mjs.map +1 -0
- package/dist/components/user-action/input/InsideLabelInput.d.mts +20 -0
- package/dist/components/user-action/input/InsideLabelInput.d.ts +20 -0
- package/dist/components/user-action/input/InsideLabelInput.js +295 -0
- package/dist/components/user-action/input/InsideLabelInput.js.map +1 -0
- package/dist/components/user-action/input/InsideLabelInput.mjs +260 -0
- package/dist/components/user-action/input/InsideLabelInput.mjs.map +1 -0
- package/dist/components/user-action/input/ToggleableInput.d.mts +22 -0
- package/dist/components/user-action/input/ToggleableInput.d.ts +22 -0
- package/dist/components/user-action/{Input.js → input/ToggleableInput.js} +136 -171
- package/dist/components/user-action/input/ToggleableInput.js.map +1 -0
- package/dist/components/user-action/input/ToggleableInput.mjs +264 -0
- package/dist/components/user-action/input/ToggleableInput.mjs.map +1 -0
- package/dist/components/user-action/select/Select.d.mts +98 -0
- package/dist/components/user-action/select/Select.d.ts +98 -0
- package/dist/components/user-action/select/Select.js +1354 -0
- package/dist/components/user-action/select/Select.js.map +1 -0
- package/dist/components/user-action/select/Select.mjs +1320 -0
- package/dist/components/user-action/select/Select.mjs.map +1 -0
- package/dist/components/utils/FocusTrap.d.mts +28 -0
- package/dist/components/utils/FocusTrap.d.ts +28 -0
- package/dist/components/utils/FocusTrap.js +252 -0
- package/dist/components/utils/FocusTrap.js.map +1 -0
- package/dist/components/utils/FocusTrap.mjs +229 -0
- package/dist/components/utils/FocusTrap.mjs.map +1 -0
- package/dist/components/utils/Transition.d.mts +26 -0
- package/dist/components/utils/Transition.d.ts +26 -0
- package/dist/components/utils/Transition.js +74 -0
- package/dist/components/utils/Transition.js.map +1 -0
- package/dist/components/utils/Transition.mjs +50 -0
- package/dist/components/utils/Transition.mjs.map +1 -0
- package/dist/hooks/focus/useFocusGuards.d.mts +3 -0
- package/dist/hooks/focus/useFocusGuards.d.ts +3 -0
- package/dist/hooks/focus/useFocusGuards.js +74 -0
- package/dist/hooks/focus/useFocusGuards.js.map +1 -0
- package/dist/hooks/focus/useFocusGuards.mjs +50 -0
- package/dist/hooks/focus/useFocusGuards.mjs.map +1 -0
- package/dist/hooks/{useFocusManagement.js → focus/useFocusManagement.js} +1 -1
- package/dist/hooks/focus/useFocusManagement.js.map +1 -0
- package/dist/hooks/{useFocusManagement.mjs → focus/useFocusManagement.mjs} +1 -1
- package/dist/hooks/focus/useFocusManagement.mjs.map +1 -0
- package/dist/hooks/{useFocusOnceVisible.js → focus/useFocusOnceVisible.js} +1 -1
- package/dist/hooks/focus/useFocusOnceVisible.js.map +1 -0
- package/dist/hooks/{useFocusOnceVisible.mjs → focus/useFocusOnceVisible.mjs} +1 -1
- package/dist/hooks/focus/useFocusOnceVisible.mjs.map +1 -0
- package/dist/hooks/focus/useFocusTrap.d.mts +16 -0
- package/dist/hooks/focus/useFocusTrap.d.ts +16 -0
- package/dist/hooks/focus/useFocusTrap.js +233 -0
- package/dist/hooks/focus/useFocusTrap.js.map +1 -0
- package/dist/hooks/focus/useFocusTrap.mjs +210 -0
- package/dist/hooks/focus/useFocusTrap.mjs.map +1 -0
- package/dist/hooks/focus/useIsMounted.d.mts +3 -0
- package/dist/hooks/focus/useIsMounted.d.ts +3 -0
- package/dist/hooks/focus/useIsMounted.js +43 -0
- package/dist/hooks/focus/useIsMounted.js.map +1 -0
- package/dist/hooks/focus/useIsMounted.mjs +20 -0
- package/dist/hooks/focus/useIsMounted.mjs.map +1 -0
- package/dist/hooks/useFloatingElement.d.mts +22 -0
- package/dist/hooks/useFloatingElement.d.ts +22 -0
- package/dist/hooks/useFloatingElement.js +162 -0
- package/dist/hooks/useFloatingElement.js.map +1 -0
- package/dist/hooks/useFloatingElement.mjs +139 -0
- package/dist/hooks/useFloatingElement.mjs.map +1 -0
- package/dist/hooks/useLocalStorage.js +2 -2
- package/dist/hooks/useLocalStorage.js.map +1 -1
- package/dist/hooks/useLocalStorage.mjs +2 -2
- package/dist/hooks/useLocalStorage.mjs.map +1 -1
- package/dist/hooks/useLogOnce.d.mts +3 -4
- package/dist/hooks/useLogOnce.d.ts +3 -4
- package/dist/hooks/useLogOnce.js +5 -5
- package/dist/hooks/useLogOnce.js.map +1 -1
- package/dist/hooks/useLogOnce.mjs +5 -5
- package/dist/hooks/useLogOnce.mjs.map +1 -1
- package/dist/hooks/useRerender.d.mts +2 -2
- package/dist/hooks/useRerender.d.ts +2 -2
- package/dist/hooks/useSearch.d.mts +2 -2
- package/dist/hooks/useSearch.d.ts +2 -2
- package/dist/hooks/useSearch.js +1 -1
- package/dist/hooks/useSearch.js.map +1 -1
- package/dist/hooks/useSearch.mjs +1 -1
- package/dist/hooks/useSearch.mjs.map +1 -1
- package/dist/localization/LanguageProvider.d.mts +2 -2
- package/dist/localization/LanguageProvider.d.ts +2 -2
- package/dist/localization/LanguageProvider.js +2 -2
- package/dist/localization/LanguageProvider.js.map +1 -1
- package/dist/localization/LanguageProvider.mjs +2 -2
- package/dist/localization/LanguageProvider.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/localization/useTranslation.js.map +1 -1
- package/dist/localization/useTranslation.mjs.map +1 -1
- package/dist/storybook/helper.d.mts +17 -0
- package/dist/storybook/helper.d.ts +17 -0
- package/dist/storybook/helper.js +61 -0
- package/dist/storybook/helper.js.map +1 -0
- package/dist/storybook/helper.mjs +37 -0
- package/dist/storybook/helper.mjs.map +1 -0
- package/dist/{css → style}/globals.css +779 -374
- package/dist/{css → style}/uncompiled/globals.css +75 -13
- package/dist/{css → style}/uncompiled/theme/colors-component.css +18 -4
- package/dist/{css → style}/uncompiled/theme/colors-semantic.css +2 -9
- package/dist/style/uncompiled/typography.css +171 -0
- package/dist/{css → style}/uncompiled/utitlity/animation.css +54 -42
- package/dist/{css → style}/uncompiled/utitlity/index.css +2 -1
- package/dist/{css → style}/uncompiled/utitlity/shadow.css +5 -1
- package/dist/style/uncompiled/utitlity/sizing.css +29 -0
- package/dist/theming/useTheme.d.mts +2 -2
- package/dist/theming/useTheme.d.ts +2 -2
- package/dist/theming/useTheme.js +3 -3
- package/dist/theming/useTheme.js.map +1 -1
- package/dist/theming/useTheme.mjs +3 -3
- package/dist/theming/useTheme.mjs.map +1 -1
- package/dist/{util → utils}/array.d.mts +1 -0
- package/dist/{util → utils}/array.d.ts +1 -0
- package/dist/{util → utils}/array.js +15 -2
- package/dist/utils/array.js.map +1 -0
- package/dist/{util → utils}/array.mjs +15 -2
- package/dist/utils/array.mjs.map +1 -0
- package/dist/utils/bagFunctions.d.mts +15 -0
- package/dist/utils/bagFunctions.d.ts +15 -0
- package/dist/{util/PropsWithFunctionChildren.js → utils/bagFunctions.js} +5 -5
- package/dist/utils/bagFunctions.js.map +1 -0
- package/dist/{util/PropsWithFunctionChildren.mjs → utils/bagFunctions.mjs} +2 -2
- package/dist/utils/bagFunctions.mjs.map +1 -0
- package/dist/{util → utils}/builder.js +1 -1
- package/dist/utils/builder.js.map +1 -0
- package/dist/{util → utils}/builder.mjs +1 -1
- package/dist/utils/builder.mjs.map +1 -0
- package/dist/{util → utils}/date.js +3 -3
- package/dist/utils/date.js.map +1 -0
- package/dist/{util → utils}/date.mjs +2 -2
- package/dist/utils/date.mjs.map +1 -0
- package/dist/{util → utils}/easeFunctions.js +5 -4
- package/dist/utils/easeFunctions.js.map +1 -0
- package/dist/{util → utils}/easeFunctions.mjs +4 -3
- package/dist/utils/easeFunctions.mjs.map +1 -0
- package/dist/{util → utils}/emailValidation.js +1 -1
- package/dist/utils/emailValidation.js.map +1 -0
- package/dist/{util → utils}/emailValidation.mjs +1 -1
- package/dist/utils/emailValidation.mjs.map +1 -0
- package/dist/{util → utils}/loopingArray.js +1 -1
- package/dist/utils/loopingArray.js.map +1 -0
- package/dist/{util → utils}/loopingArray.mjs +1 -1
- package/dist/utils/loopingArray.mjs.map +1 -0
- package/dist/utils/match.d.mts +3 -0
- package/dist/utils/match.d.ts +3 -0
- package/dist/utils/match.js +32 -0
- package/dist/utils/match.js.map +1 -0
- package/dist/utils/match.mjs +8 -0
- package/dist/utils/match.mjs.map +1 -0
- package/dist/utils/math.d.mts +3 -0
- package/dist/utils/math.d.ts +3 -0
- package/dist/{util → utils}/math.js +3 -2
- package/dist/utils/math.js.map +1 -0
- package/dist/utils/math.mjs +9 -0
- package/dist/utils/math.mjs.map +1 -0
- package/dist/{util → utils}/noop.js +1 -1
- package/dist/utils/noop.js.map +1 -0
- package/dist/utils/noop.mjs +6 -0
- package/dist/utils/noop.mjs.map +1 -0
- package/dist/{util → utils}/resolveSetState.js +1 -1
- package/dist/utils/resolveSetState.js.map +1 -0
- package/dist/{util → utils}/resolveSetState.mjs +1 -1
- package/dist/utils/resolveSetState.mjs.map +1 -0
- package/dist/{util → utils}/simpleSearch.js +1 -1
- package/dist/utils/simpleSearch.js.map +1 -0
- package/dist/{util → utils}/simpleSearch.mjs +1 -1
- package/dist/utils/simpleSearch.mjs.map +1 -0
- package/dist/{util → utils}/storage.js +1 -1
- package/dist/utils/storage.js.map +1 -0
- package/dist/{util → utils}/storage.mjs +1 -1
- package/dist/utils/storage.mjs.map +1 -0
- package/dist/{util → utils}/writeToClipboard.js +2 -1
- package/dist/utils/writeToClipboard.js.map +1 -0
- package/dist/{util → utils}/writeToClipboard.mjs +3 -1
- package/dist/utils/writeToClipboard.mjs.map +1 -0
- package/package.json +8 -8
- package/dist/components/dialogs/ConfirmDialog.js +0 -674
- package/dist/components/dialogs/ConfirmDialog.js.map +0 -1
- package/dist/components/dialogs/ConfirmDialog.mjs +0 -638
- package/dist/components/dialogs/ConfirmDialog.mjs.map +0 -1
- package/dist/components/icons-and-geometry/Helpwave.js.map +0 -1
- package/dist/components/icons-and-geometry/Helpwave.mjs.map +0 -1
- package/dist/components/layout-and-navigation/Overlay.d.mts +0 -67
- package/dist/components/layout-and-navigation/Overlay.d.ts +0 -67
- package/dist/components/layout-and-navigation/Overlay.js +0 -702
- package/dist/components/layout-and-navigation/Overlay.js.map +0 -1
- package/dist/components/layout-and-navigation/Overlay.mjs +0 -665
- package/dist/components/layout-and-navigation/Overlay.mjs.map +0 -1
- package/dist/components/layout-and-navigation/SearchableList.d.mts +0 -24
- package/dist/components/layout-and-navigation/SearchableList.d.ts +0 -24
- package/dist/components/layout-and-navigation/SearchableList.js +0 -758
- package/dist/components/layout-and-navigation/SearchableList.js.map +0 -1
- package/dist/components/layout-and-navigation/SearchableList.mjs +0 -724
- package/dist/components/layout-and-navigation/SearchableList.mjs.map +0 -1
- package/dist/components/layout-and-navigation/Tile.d.mts +0 -27
- package/dist/components/layout-and-navigation/Tile.d.ts +0 -27
- package/dist/components/layout-and-navigation/Tile.js +0 -96
- package/dist/components/layout-and-navigation/Tile.js.map +0 -1
- package/dist/components/layout-and-navigation/Tile.mjs +0 -61
- package/dist/components/layout-and-navigation/Tile.mjs.map +0 -1
- package/dist/components/modals/ConfirmModal.d.mts +0 -33
- package/dist/components/modals/ConfirmModal.d.ts +0 -33
- package/dist/components/modals/ConfirmModal.js +0 -687
- package/dist/components/modals/ConfirmModal.js.map +0 -1
- package/dist/components/modals/ConfirmModal.mjs +0 -651
- package/dist/components/modals/ConfirmModal.mjs.map +0 -1
- package/dist/components/modals/DiscardChangesModal.d.mts +0 -20
- package/dist/components/modals/DiscardChangesModal.d.ts +0 -20
- package/dist/components/modals/DiscardChangesModal.js +0 -717
- package/dist/components/modals/DiscardChangesModal.js.map +0 -1
- package/dist/components/modals/DiscardChangesModal.mjs +0 -681
- package/dist/components/modals/DiscardChangesModal.mjs.map +0 -1
- package/dist/components/modals/InputModal.d.mts +0 -21
- package/dist/components/modals/InputModal.d.ts +0 -21
- package/dist/components/modals/InputModal.js +0 -976
- package/dist/components/modals/InputModal.js.map +0 -1
- package/dist/components/modals/InputModal.mjs +0 -940
- package/dist/components/modals/InputModal.mjs.map +0 -1
- package/dist/components/modals/LanguageModal.d.mts +0 -21
- package/dist/components/modals/LanguageModal.d.ts +0 -21
- package/dist/components/modals/LanguageModal.js +0 -1468
- package/dist/components/modals/LanguageModal.js.map +0 -1
- package/dist/components/modals/LanguageModal.mjs +0 -1432
- package/dist/components/modals/LanguageModal.mjs.map +0 -1
- package/dist/components/modals/ThemeModal.d.mts +0 -21
- package/dist/components/modals/ThemeModal.d.ts +0 -21
- package/dist/components/modals/ThemeModal.js +0 -1497
- package/dist/components/modals/ThemeModal.js.map +0 -1
- package/dist/components/modals/ThemeModal.mjs +0 -1461
- package/dist/components/modals/ThemeModal.mjs.map +0 -1
- package/dist/components/user-action/Input.d.mts +0 -77
- package/dist/components/user-action/Input.d.ts +0 -77
- package/dist/components/user-action/Input.js.map +0 -1
- package/dist/components/user-action/Input.mjs +0 -298
- package/dist/components/user-action/Input.mjs.map +0 -1
- package/dist/components/user-action/MultiSelect.d.mts +0 -42
- package/dist/components/user-action/MultiSelect.d.ts +0 -42
- package/dist/components/user-action/MultiSelect.js +0 -1468
- package/dist/components/user-action/MultiSelect.js.map +0 -1
- package/dist/components/user-action/MultiSelect.mjs +0 -1433
- package/dist/components/user-action/MultiSelect.mjs.map +0 -1
- package/dist/components/user-action/Select.d.mts +0 -41
- package/dist/components/user-action/Select.d.ts +0 -41
- package/dist/components/user-action/Select.js +0 -1236
- package/dist/components/user-action/Select.js.map +0 -1
- package/dist/components/user-action/Select.mjs +0 -1201
- package/dist/components/user-action/Select.mjs.map +0 -1
- package/dist/components/user-action/ToggleableInput.d.mts +0 -37
- package/dist/components/user-action/ToggleableInput.d.ts +0 -37
- package/dist/components/user-action/ToggleableInput.js +0 -192
- package/dist/components/user-action/ToggleableInput.js.map +0 -1
- package/dist/components/user-action/ToggleableInput.mjs +0 -157
- package/dist/components/user-action/ToggleableInput.mjs.map +0 -1
- package/dist/css/uncompiled/textstyles.css +0 -69
- package/dist/hooks/useFocusManagement.js.map +0 -1
- package/dist/hooks/useFocusManagement.mjs.map +0 -1
- package/dist/hooks/useFocusOnceVisible.js.map +0 -1
- package/dist/hooks/useFocusOnceVisible.mjs.map +0 -1
- package/dist/index.d.mts +0 -103
- package/dist/index.d.ts +0 -103
- package/dist/index.js +0 -12610
- package/dist/index.js.map +0 -1
- package/dist/index.mjs +0 -12447
- package/dist/index.mjs.map +0 -1
- package/dist/util/PropsWithFunctionChildren.d.mts +0 -14
- package/dist/util/PropsWithFunctionChildren.d.ts +0 -14
- package/dist/util/PropsWithFunctionChildren.js.map +0 -1
- package/dist/util/PropsWithFunctionChildren.mjs.map +0 -1
- package/dist/util/array.js.map +0 -1
- package/dist/util/array.mjs.map +0 -1
- package/dist/util/builder.js.map +0 -1
- package/dist/util/builder.mjs.map +0 -1
- package/dist/util/date.js.map +0 -1
- package/dist/util/date.mjs.map +0 -1
- package/dist/util/easeFunctions.js.map +0 -1
- package/dist/util/easeFunctions.mjs.map +0 -1
- package/dist/util/emailValidation.js.map +0 -1
- package/dist/util/emailValidation.mjs.map +0 -1
- package/dist/util/loopingArray.js.map +0 -1
- package/dist/util/loopingArray.mjs.map +0 -1
- package/dist/util/math.d.mts +0 -3
- package/dist/util/math.d.ts +0 -3
- package/dist/util/math.js.map +0 -1
- package/dist/util/math.mjs +0 -8
- package/dist/util/math.mjs.map +0 -1
- package/dist/util/news.d.mts +0 -101
- package/dist/util/news.d.ts +0 -101
- package/dist/util/news.js +0 -76
- package/dist/util/news.js.map +0 -1
- package/dist/util/news.mjs +0 -49
- package/dist/util/news.mjs.map +0 -1
- package/dist/util/noop.js.map +0 -1
- package/dist/util/noop.mjs +0 -6
- package/dist/util/noop.mjs.map +0 -1
- package/dist/util/resolveSetState.js.map +0 -1
- package/dist/util/resolveSetState.mjs.map +0 -1
- package/dist/util/simpleSearch.js.map +0 -1
- package/dist/util/simpleSearch.mjs.map +0 -1
- package/dist/util/storage.js.map +0 -1
- package/dist/util/storage.mjs.map +0 -1
- package/dist/util/types.d.mts +0 -3
- package/dist/util/types.d.ts +0 -3
- package/dist/util/types.js +0 -18
- package/dist/util/types.js.map +0 -1
- package/dist/util/types.mjs +0 -1
- package/dist/util/types.mjs.map +0 -1
- package/dist/util/writeToClipboard.js.map +0 -1
- package/dist/util/writeToClipboard.mjs.map +0 -1
- /package/dist/hooks/{useFocusManagement.d.mts → focus/useFocusManagement.d.mts} +0 -0
- /package/dist/hooks/{useFocusManagement.d.ts → focus/useFocusManagement.d.ts} +0 -0
- /package/dist/hooks/{useFocusOnceVisible.d.mts → focus/useFocusOnceVisible.d.mts} +0 -0
- /package/dist/hooks/{useFocusOnceVisible.d.ts → focus/useFocusOnceVisible.d.ts} +0 -0
- /package/dist/{css → style}/uncompiled/theme/colors-basic.css +0 -0
- /package/dist/{css → style}/uncompiled/theme/index.css +0 -0
- /package/dist/{css → style}/uncompiled/theme/variants.css +0 -0
- /package/dist/{css → style}/uncompiled/utitlity/borderradius.css +0 -0
- /package/dist/{css → style}/uncompiled/utitlity/general.css +0 -0
- /package/dist/{util → utils}/builder.d.mts +0 -0
- /package/dist/{util → utils}/builder.d.ts +0 -0
- /package/dist/{util → utils}/date.d.mts +0 -0
- /package/dist/{util → utils}/date.d.ts +0 -0
- /package/dist/{util → utils}/easeFunctions.d.mts +0 -0
- /package/dist/{util → utils}/easeFunctions.d.ts +0 -0
- /package/dist/{util → utils}/emailValidation.d.mts +0 -0
- /package/dist/{util → utils}/emailValidation.d.ts +0 -0
- /package/dist/{util → utils}/loopingArray.d.mts +0 -0
- /package/dist/{util → utils}/loopingArray.d.ts +0 -0
- /package/dist/{util → utils}/noop.d.mts +0 -0
- /package/dist/{util → utils}/noop.d.ts +0 -0
- /package/dist/{util → utils}/resolveSetState.d.mts +0 -0
- /package/dist/{util → utils}/resolveSetState.d.ts +0 -0
- /package/dist/{util → utils}/simpleSearch.d.mts +0 -0
- /package/dist/{util → utils}/simpleSearch.d.ts +0 -0
- /package/dist/{util → utils}/storage.d.mts +0 -0
- /package/dist/{util → utils}/storage.d.ts +0 -0
- /package/dist/{util → utils}/writeToClipboard.d.mts +0 -0
- /package/dist/{util → utils}/writeToClipboard.d.ts +0 -0
|
@@ -34,116 +34,808 @@ __export(CheckboxProperty_exports, {
|
|
|
34
34
|
module.exports = __toCommonJS(CheckboxProperty_exports);
|
|
35
35
|
var import_lucide_react3 = require("lucide-react");
|
|
36
36
|
|
|
37
|
-
// src/
|
|
37
|
+
// src/utils/noop.ts
|
|
38
38
|
var noop = () => void 0;
|
|
39
39
|
|
|
40
40
|
// src/components/user-action/Checkbox.tsx
|
|
41
41
|
var import_react = require("react");
|
|
42
|
-
var CheckboxPrimitive = __toESM(require("@radix-ui/react-checkbox"));
|
|
43
42
|
var import_lucide_react = require("lucide-react");
|
|
44
|
-
var import_clsx2 = __toESM(require("clsx"));
|
|
45
|
-
|
|
46
|
-
// src/components/user-action/Label.tsx
|
|
47
43
|
var import_clsx = __toESM(require("clsx"));
|
|
44
|
+
|
|
45
|
+
// node_modules/@radix-ui/react-checkbox/dist/index.mjs
|
|
46
|
+
var React10 = __toESM(require("react"), 1);
|
|
47
|
+
|
|
48
|
+
// node_modules/@radix-ui/react-compose-refs/dist/index.mjs
|
|
49
|
+
var React = __toESM(require("react"), 1);
|
|
50
|
+
function setRef(ref, value) {
|
|
51
|
+
if (typeof ref === "function") {
|
|
52
|
+
return ref(value);
|
|
53
|
+
} else if (ref !== null && ref !== void 0) {
|
|
54
|
+
ref.current = value;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
function composeRefs(...refs) {
|
|
58
|
+
return (node) => {
|
|
59
|
+
let hasCleanup = false;
|
|
60
|
+
const cleanups = refs.map((ref) => {
|
|
61
|
+
const cleanup = setRef(ref, node);
|
|
62
|
+
if (!hasCleanup && typeof cleanup == "function") {
|
|
63
|
+
hasCleanup = true;
|
|
64
|
+
}
|
|
65
|
+
return cleanup;
|
|
66
|
+
});
|
|
67
|
+
if (hasCleanup) {
|
|
68
|
+
return () => {
|
|
69
|
+
for (let i = 0; i < cleanups.length; i++) {
|
|
70
|
+
const cleanup = cleanups[i];
|
|
71
|
+
if (typeof cleanup == "function") {
|
|
72
|
+
cleanup();
|
|
73
|
+
} else {
|
|
74
|
+
setRef(refs[i], null);
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
};
|
|
80
|
+
}
|
|
81
|
+
function useComposedRefs(...refs) {
|
|
82
|
+
return React.useCallback(composeRefs(...refs), refs);
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
// node_modules/@radix-ui/react-context/dist/index.mjs
|
|
86
|
+
var React2 = __toESM(require("react"), 1);
|
|
48
87
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
88
|
+
function createContextScope(scopeName, createContextScopeDeps = []) {
|
|
89
|
+
let defaultContexts = [];
|
|
90
|
+
function createContext3(rootComponentName, defaultContext) {
|
|
91
|
+
const BaseContext = React2.createContext(defaultContext);
|
|
92
|
+
const index = defaultContexts.length;
|
|
93
|
+
defaultContexts = [...defaultContexts, defaultContext];
|
|
94
|
+
const Provider = (props) => {
|
|
95
|
+
const { scope, children, ...context } = props;
|
|
96
|
+
const Context = scope?.[scopeName]?.[index] || BaseContext;
|
|
97
|
+
const value = React2.useMemo(() => context, Object.values(context));
|
|
98
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Context.Provider, { value, children });
|
|
99
|
+
};
|
|
100
|
+
Provider.displayName = rootComponentName + "Provider";
|
|
101
|
+
function useContext22(consumerName, scope) {
|
|
102
|
+
const Context = scope?.[scopeName]?.[index] || BaseContext;
|
|
103
|
+
const context = React2.useContext(Context);
|
|
104
|
+
if (context) return context;
|
|
105
|
+
if (defaultContext !== void 0) return defaultContext;
|
|
106
|
+
throw new Error(`\`${consumerName}\` must be used within \`${rootComponentName}\``);
|
|
107
|
+
}
|
|
108
|
+
return [Provider, useContext22];
|
|
109
|
+
}
|
|
110
|
+
const createScope = () => {
|
|
111
|
+
const scopeContexts = defaultContexts.map((defaultContext) => {
|
|
112
|
+
return React2.createContext(defaultContext);
|
|
113
|
+
});
|
|
114
|
+
return function useScope(scope) {
|
|
115
|
+
const contexts = scope?.[scopeName] || scopeContexts;
|
|
116
|
+
return React2.useMemo(
|
|
117
|
+
() => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),
|
|
118
|
+
[scope, contexts]
|
|
119
|
+
);
|
|
120
|
+
};
|
|
121
|
+
};
|
|
122
|
+
createScope.scopeName = scopeName;
|
|
123
|
+
return [createContext3, composeContextScopes(createScope, ...createContextScopeDeps)];
|
|
124
|
+
}
|
|
125
|
+
function composeContextScopes(...scopes) {
|
|
126
|
+
const baseScope = scopes[0];
|
|
127
|
+
if (scopes.length === 1) return baseScope;
|
|
128
|
+
const createScope = () => {
|
|
129
|
+
const scopeHooks = scopes.map((createScope2) => ({
|
|
130
|
+
useScope: createScope2(),
|
|
131
|
+
scopeName: createScope2.scopeName
|
|
132
|
+
}));
|
|
133
|
+
return function useComposedScopes(overrideScopes) {
|
|
134
|
+
const nextScopes = scopeHooks.reduce((nextScopes2, { useScope, scopeName }) => {
|
|
135
|
+
const scopeProps = useScope(overrideScopes);
|
|
136
|
+
const currentScope = scopeProps[`__scope${scopeName}`];
|
|
137
|
+
return { ...nextScopes2, ...currentScope };
|
|
138
|
+
}, {});
|
|
139
|
+
return React2.useMemo(() => ({ [`__scope${baseScope.scopeName}`]: nextScopes }), [nextScopes]);
|
|
140
|
+
};
|
|
141
|
+
};
|
|
142
|
+
createScope.scopeName = baseScope.scopeName;
|
|
143
|
+
return createScope;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
// node_modules/@radix-ui/primitive/dist/index.mjs
|
|
147
|
+
function composeEventHandlers(originalEventHandler, ourEventHandler, { checkForDefaultPrevented = true } = {}) {
|
|
148
|
+
return function handleEvent(event) {
|
|
149
|
+
originalEventHandler?.(event);
|
|
150
|
+
if (checkForDefaultPrevented === false || !event.defaultPrevented) {
|
|
151
|
+
return ourEventHandler?.(event);
|
|
152
|
+
}
|
|
153
|
+
};
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
// node_modules/@radix-ui/react-use-controllable-state/dist/index.mjs
|
|
157
|
+
var React4 = __toESM(require("react"), 1);
|
|
158
|
+
|
|
159
|
+
// node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs
|
|
160
|
+
var React3 = __toESM(require("react"), 1);
|
|
161
|
+
var useLayoutEffect2 = globalThis?.document ? React3.useLayoutEffect : () => {
|
|
53
162
|
};
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
163
|
+
|
|
164
|
+
// node_modules/@radix-ui/react-use-controllable-state/dist/index.mjs
|
|
165
|
+
var React22 = __toESM(require("react"), 1);
|
|
166
|
+
var useInsertionEffect = React4[" useInsertionEffect ".trim().toString()] || useLayoutEffect2;
|
|
167
|
+
function useControllableState({
|
|
168
|
+
prop,
|
|
169
|
+
defaultProp,
|
|
170
|
+
onChange = () => {
|
|
171
|
+
},
|
|
172
|
+
caller
|
|
173
|
+
}) {
|
|
174
|
+
const [uncontrolledProp, setUncontrolledProp, onChangeRef] = useUncontrolledState({
|
|
175
|
+
defaultProp,
|
|
176
|
+
onChange
|
|
177
|
+
});
|
|
178
|
+
const isControlled = prop !== void 0;
|
|
179
|
+
const value = isControlled ? prop : uncontrolledProp;
|
|
180
|
+
if (true) {
|
|
181
|
+
const isControlledRef = React4.useRef(prop !== void 0);
|
|
182
|
+
React4.useEffect(() => {
|
|
183
|
+
const wasControlled = isControlledRef.current;
|
|
184
|
+
if (wasControlled !== isControlled) {
|
|
185
|
+
const from = wasControlled ? "controlled" : "uncontrolled";
|
|
186
|
+
const to = isControlled ? "controlled" : "uncontrolled";
|
|
187
|
+
console.warn(
|
|
188
|
+
`${caller} is changing from ${from} to ${to}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`
|
|
189
|
+
);
|
|
190
|
+
}
|
|
191
|
+
isControlledRef.current = isControlled;
|
|
192
|
+
}, [isControlled, caller]);
|
|
193
|
+
}
|
|
194
|
+
const setValue = React4.useCallback(
|
|
195
|
+
(nextValue) => {
|
|
196
|
+
if (isControlled) {
|
|
197
|
+
const value2 = isFunction(nextValue) ? nextValue(prop) : nextValue;
|
|
198
|
+
if (value2 !== prop) {
|
|
199
|
+
onChangeRef.current?.(value2);
|
|
200
|
+
}
|
|
201
|
+
} else {
|
|
202
|
+
setUncontrolledProp(nextValue);
|
|
203
|
+
}
|
|
204
|
+
},
|
|
205
|
+
[isControlled, prop, setUncontrolledProp, onChangeRef]
|
|
206
|
+
);
|
|
207
|
+
return [value, setValue];
|
|
208
|
+
}
|
|
209
|
+
function useUncontrolledState({
|
|
210
|
+
defaultProp,
|
|
211
|
+
onChange
|
|
212
|
+
}) {
|
|
213
|
+
const [value, setValue] = React4.useState(defaultProp);
|
|
214
|
+
const prevValueRef = React4.useRef(value);
|
|
215
|
+
const onChangeRef = React4.useRef(onChange);
|
|
216
|
+
useInsertionEffect(() => {
|
|
217
|
+
onChangeRef.current = onChange;
|
|
218
|
+
}, [onChange]);
|
|
219
|
+
React4.useEffect(() => {
|
|
220
|
+
if (prevValueRef.current !== value) {
|
|
221
|
+
onChangeRef.current?.(value);
|
|
222
|
+
prevValueRef.current = value;
|
|
223
|
+
}
|
|
224
|
+
}, [value, prevValueRef]);
|
|
225
|
+
return [value, setValue, onChangeRef];
|
|
226
|
+
}
|
|
227
|
+
function isFunction(value) {
|
|
228
|
+
return typeof value === "function";
|
|
229
|
+
}
|
|
230
|
+
var SYNC_STATE = Symbol("RADIX:SYNC_STATE");
|
|
231
|
+
|
|
232
|
+
// node_modules/@radix-ui/react-use-previous/dist/index.mjs
|
|
233
|
+
var React5 = __toESM(require("react"), 1);
|
|
234
|
+
function usePrevious(value) {
|
|
235
|
+
const ref = React5.useRef({ value, previous: value });
|
|
236
|
+
return React5.useMemo(() => {
|
|
237
|
+
if (ref.current.value !== value) {
|
|
238
|
+
ref.current.previous = ref.current.value;
|
|
239
|
+
ref.current.value = value;
|
|
240
|
+
}
|
|
241
|
+
return ref.current.previous;
|
|
242
|
+
}, [value]);
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
// node_modules/@radix-ui/react-use-size/dist/index.mjs
|
|
246
|
+
var React6 = __toESM(require("react"), 1);
|
|
247
|
+
function useSize(element) {
|
|
248
|
+
const [size, setSize] = React6.useState(void 0);
|
|
249
|
+
useLayoutEffect2(() => {
|
|
250
|
+
if (element) {
|
|
251
|
+
setSize({ width: element.offsetWidth, height: element.offsetHeight });
|
|
252
|
+
const resizeObserver = new ResizeObserver((entries) => {
|
|
253
|
+
if (!Array.isArray(entries)) {
|
|
254
|
+
return;
|
|
255
|
+
}
|
|
256
|
+
if (!entries.length) {
|
|
257
|
+
return;
|
|
258
|
+
}
|
|
259
|
+
const entry = entries[0];
|
|
260
|
+
let width;
|
|
261
|
+
let height;
|
|
262
|
+
if ("borderBoxSize" in entry) {
|
|
263
|
+
const borderSizeEntry = entry["borderBoxSize"];
|
|
264
|
+
const borderSize = Array.isArray(borderSizeEntry) ? borderSizeEntry[0] : borderSizeEntry;
|
|
265
|
+
width = borderSize["inlineSize"];
|
|
266
|
+
height = borderSize["blockSize"];
|
|
267
|
+
} else {
|
|
268
|
+
width = element.offsetWidth;
|
|
269
|
+
height = element.offsetHeight;
|
|
270
|
+
}
|
|
271
|
+
setSize({ width, height });
|
|
272
|
+
});
|
|
273
|
+
resizeObserver.observe(element, { box: "border-box" });
|
|
274
|
+
return () => resizeObserver.unobserve(element);
|
|
275
|
+
} else {
|
|
276
|
+
setSize(void 0);
|
|
277
|
+
}
|
|
278
|
+
}, [element]);
|
|
279
|
+
return size;
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
// node_modules/@radix-ui/react-presence/dist/index.mjs
|
|
283
|
+
var React23 = __toESM(require("react"), 1);
|
|
284
|
+
var React7 = __toESM(require("react"), 1);
|
|
285
|
+
function useStateMachine(initialState, machine) {
|
|
286
|
+
return React7.useReducer((state, event) => {
|
|
287
|
+
const nextState = machine[state][event];
|
|
288
|
+
return nextState ?? state;
|
|
289
|
+
}, initialState);
|
|
290
|
+
}
|
|
291
|
+
var Presence = (props) => {
|
|
292
|
+
const { present, children } = props;
|
|
293
|
+
const presence = usePresence(present);
|
|
294
|
+
const child = typeof children === "function" ? children({ present: presence.isPresent }) : React23.Children.only(children);
|
|
295
|
+
const ref = useComposedRefs(presence.ref, getElementRef(child));
|
|
296
|
+
const forceMount = typeof children === "function";
|
|
297
|
+
return forceMount || presence.isPresent ? React23.cloneElement(child, { ref }) : null;
|
|
62
298
|
};
|
|
299
|
+
Presence.displayName = "Presence";
|
|
300
|
+
function usePresence(present) {
|
|
301
|
+
const [node, setNode] = React23.useState();
|
|
302
|
+
const stylesRef = React23.useRef(null);
|
|
303
|
+
const prevPresentRef = React23.useRef(present);
|
|
304
|
+
const prevAnimationNameRef = React23.useRef("none");
|
|
305
|
+
const initialState = present ? "mounted" : "unmounted";
|
|
306
|
+
const [state, send] = useStateMachine(initialState, {
|
|
307
|
+
mounted: {
|
|
308
|
+
UNMOUNT: "unmounted",
|
|
309
|
+
ANIMATION_OUT: "unmountSuspended"
|
|
310
|
+
},
|
|
311
|
+
unmountSuspended: {
|
|
312
|
+
MOUNT: "mounted",
|
|
313
|
+
ANIMATION_END: "unmounted"
|
|
314
|
+
},
|
|
315
|
+
unmounted: {
|
|
316
|
+
MOUNT: "mounted"
|
|
317
|
+
}
|
|
318
|
+
});
|
|
319
|
+
React23.useEffect(() => {
|
|
320
|
+
const currentAnimationName = getAnimationName(stylesRef.current);
|
|
321
|
+
prevAnimationNameRef.current = state === "mounted" ? currentAnimationName : "none";
|
|
322
|
+
}, [state]);
|
|
323
|
+
useLayoutEffect2(() => {
|
|
324
|
+
const styles = stylesRef.current;
|
|
325
|
+
const wasPresent = prevPresentRef.current;
|
|
326
|
+
const hasPresentChanged = wasPresent !== present;
|
|
327
|
+
if (hasPresentChanged) {
|
|
328
|
+
const prevAnimationName = prevAnimationNameRef.current;
|
|
329
|
+
const currentAnimationName = getAnimationName(styles);
|
|
330
|
+
if (present) {
|
|
331
|
+
send("MOUNT");
|
|
332
|
+
} else if (currentAnimationName === "none" || styles?.display === "none") {
|
|
333
|
+
send("UNMOUNT");
|
|
334
|
+
} else {
|
|
335
|
+
const isAnimating = prevAnimationName !== currentAnimationName;
|
|
336
|
+
if (wasPresent && isAnimating) {
|
|
337
|
+
send("ANIMATION_OUT");
|
|
338
|
+
} else {
|
|
339
|
+
send("UNMOUNT");
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
prevPresentRef.current = present;
|
|
343
|
+
}
|
|
344
|
+
}, [present, send]);
|
|
345
|
+
useLayoutEffect2(() => {
|
|
346
|
+
if (node) {
|
|
347
|
+
let timeoutId;
|
|
348
|
+
const ownerWindow = node.ownerDocument.defaultView ?? window;
|
|
349
|
+
const handleAnimationEnd = (event) => {
|
|
350
|
+
const currentAnimationName = getAnimationName(stylesRef.current);
|
|
351
|
+
const isCurrentAnimation = currentAnimationName.includes(event.animationName);
|
|
352
|
+
if (event.target === node && isCurrentAnimation) {
|
|
353
|
+
send("ANIMATION_END");
|
|
354
|
+
if (!prevPresentRef.current) {
|
|
355
|
+
const currentFillMode = node.style.animationFillMode;
|
|
356
|
+
node.style.animationFillMode = "forwards";
|
|
357
|
+
timeoutId = ownerWindow.setTimeout(() => {
|
|
358
|
+
if (node.style.animationFillMode === "forwards") {
|
|
359
|
+
node.style.animationFillMode = currentFillMode;
|
|
360
|
+
}
|
|
361
|
+
});
|
|
362
|
+
}
|
|
363
|
+
}
|
|
364
|
+
};
|
|
365
|
+
const handleAnimationStart = (event) => {
|
|
366
|
+
if (event.target === node) {
|
|
367
|
+
prevAnimationNameRef.current = getAnimationName(stylesRef.current);
|
|
368
|
+
}
|
|
369
|
+
};
|
|
370
|
+
node.addEventListener("animationstart", handleAnimationStart);
|
|
371
|
+
node.addEventListener("animationcancel", handleAnimationEnd);
|
|
372
|
+
node.addEventListener("animationend", handleAnimationEnd);
|
|
373
|
+
return () => {
|
|
374
|
+
ownerWindow.clearTimeout(timeoutId);
|
|
375
|
+
node.removeEventListener("animationstart", handleAnimationStart);
|
|
376
|
+
node.removeEventListener("animationcancel", handleAnimationEnd);
|
|
377
|
+
node.removeEventListener("animationend", handleAnimationEnd);
|
|
378
|
+
};
|
|
379
|
+
} else {
|
|
380
|
+
send("ANIMATION_END");
|
|
381
|
+
}
|
|
382
|
+
}, [node, send]);
|
|
383
|
+
return {
|
|
384
|
+
isPresent: ["mounted", "unmountSuspended"].includes(state),
|
|
385
|
+
ref: React23.useCallback((node2) => {
|
|
386
|
+
stylesRef.current = node2 ? getComputedStyle(node2) : null;
|
|
387
|
+
setNode(node2);
|
|
388
|
+
}, [])
|
|
389
|
+
};
|
|
390
|
+
}
|
|
391
|
+
function getAnimationName(styles) {
|
|
392
|
+
return styles?.animationName || "none";
|
|
393
|
+
}
|
|
394
|
+
function getElementRef(element) {
|
|
395
|
+
let getter = Object.getOwnPropertyDescriptor(element.props, "ref")?.get;
|
|
396
|
+
let mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
|
|
397
|
+
if (mayWarn) {
|
|
398
|
+
return element.ref;
|
|
399
|
+
}
|
|
400
|
+
getter = Object.getOwnPropertyDescriptor(element, "ref")?.get;
|
|
401
|
+
mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
|
|
402
|
+
if (mayWarn) {
|
|
403
|
+
return element.props.ref;
|
|
404
|
+
}
|
|
405
|
+
return element.props.ref || element.ref;
|
|
406
|
+
}
|
|
63
407
|
|
|
64
|
-
//
|
|
408
|
+
// node_modules/@radix-ui/react-primitive/dist/index.mjs
|
|
409
|
+
var React9 = __toESM(require("react"), 1);
|
|
410
|
+
var ReactDOM = __toESM(require("react-dom"), 1);
|
|
411
|
+
|
|
412
|
+
// node_modules/@radix-ui/react-slot/dist/index.mjs
|
|
413
|
+
var React8 = __toESM(require("react"), 1);
|
|
65
414
|
var import_jsx_runtime2 = require("react/jsx-runtime");
|
|
415
|
+
// @__NO_SIDE_EFFECTS__
|
|
416
|
+
function createSlot(ownerName) {
|
|
417
|
+
const SlotClone = /* @__PURE__ */ createSlotClone(ownerName);
|
|
418
|
+
const Slot2 = React8.forwardRef((props, forwardedRef) => {
|
|
419
|
+
const { children, ...slotProps } = props;
|
|
420
|
+
const childrenArray = React8.Children.toArray(children);
|
|
421
|
+
const slottable = childrenArray.find(isSlottable);
|
|
422
|
+
if (slottable) {
|
|
423
|
+
const newElement = slottable.props.children;
|
|
424
|
+
const newChildren = childrenArray.map((child) => {
|
|
425
|
+
if (child === slottable) {
|
|
426
|
+
if (React8.Children.count(newElement) > 1) return React8.Children.only(null);
|
|
427
|
+
return React8.isValidElement(newElement) ? newElement.props.children : null;
|
|
428
|
+
} else {
|
|
429
|
+
return child;
|
|
430
|
+
}
|
|
431
|
+
});
|
|
432
|
+
return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(SlotClone, { ...slotProps, ref: forwardedRef, children: React8.isValidElement(newElement) ? React8.cloneElement(newElement, void 0, newChildren) : null });
|
|
433
|
+
}
|
|
434
|
+
return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(SlotClone, { ...slotProps, ref: forwardedRef, children });
|
|
435
|
+
});
|
|
436
|
+
Slot2.displayName = `${ownerName}.Slot`;
|
|
437
|
+
return Slot2;
|
|
438
|
+
}
|
|
439
|
+
// @__NO_SIDE_EFFECTS__
|
|
440
|
+
function createSlotClone(ownerName) {
|
|
441
|
+
const SlotClone = React8.forwardRef((props, forwardedRef) => {
|
|
442
|
+
const { children, ...slotProps } = props;
|
|
443
|
+
if (React8.isValidElement(children)) {
|
|
444
|
+
const childrenRef = getElementRef2(children);
|
|
445
|
+
const props2 = mergeProps(slotProps, children.props);
|
|
446
|
+
if (children.type !== React8.Fragment) {
|
|
447
|
+
props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;
|
|
448
|
+
}
|
|
449
|
+
return React8.cloneElement(children, props2);
|
|
450
|
+
}
|
|
451
|
+
return React8.Children.count(children) > 1 ? React8.Children.only(null) : null;
|
|
452
|
+
});
|
|
453
|
+
SlotClone.displayName = `${ownerName}.SlotClone`;
|
|
454
|
+
return SlotClone;
|
|
455
|
+
}
|
|
456
|
+
var SLOTTABLE_IDENTIFIER = Symbol("radix.slottable");
|
|
457
|
+
function isSlottable(child) {
|
|
458
|
+
return React8.isValidElement(child) && typeof child.type === "function" && "__radixId" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER;
|
|
459
|
+
}
|
|
460
|
+
function mergeProps(slotProps, childProps) {
|
|
461
|
+
const overrideProps = { ...childProps };
|
|
462
|
+
for (const propName in childProps) {
|
|
463
|
+
const slotPropValue = slotProps[propName];
|
|
464
|
+
const childPropValue = childProps[propName];
|
|
465
|
+
const isHandler = /^on[A-Z]/.test(propName);
|
|
466
|
+
if (isHandler) {
|
|
467
|
+
if (slotPropValue && childPropValue) {
|
|
468
|
+
overrideProps[propName] = (...args) => {
|
|
469
|
+
const result = childPropValue(...args);
|
|
470
|
+
slotPropValue(...args);
|
|
471
|
+
return result;
|
|
472
|
+
};
|
|
473
|
+
} else if (slotPropValue) {
|
|
474
|
+
overrideProps[propName] = slotPropValue;
|
|
475
|
+
}
|
|
476
|
+
} else if (propName === "style") {
|
|
477
|
+
overrideProps[propName] = { ...slotPropValue, ...childPropValue };
|
|
478
|
+
} else if (propName === "className") {
|
|
479
|
+
overrideProps[propName] = [slotPropValue, childPropValue].filter(Boolean).join(" ");
|
|
480
|
+
}
|
|
481
|
+
}
|
|
482
|
+
return { ...slotProps, ...overrideProps };
|
|
483
|
+
}
|
|
484
|
+
function getElementRef2(element) {
|
|
485
|
+
let getter = Object.getOwnPropertyDescriptor(element.props, "ref")?.get;
|
|
486
|
+
let mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
|
|
487
|
+
if (mayWarn) {
|
|
488
|
+
return element.ref;
|
|
489
|
+
}
|
|
490
|
+
getter = Object.getOwnPropertyDescriptor(element, "ref")?.get;
|
|
491
|
+
mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
|
|
492
|
+
if (mayWarn) {
|
|
493
|
+
return element.props.ref;
|
|
494
|
+
}
|
|
495
|
+
return element.props.ref || element.ref;
|
|
496
|
+
}
|
|
497
|
+
|
|
498
|
+
// node_modules/@radix-ui/react-primitive/dist/index.mjs
|
|
499
|
+
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
500
|
+
var NODES = [
|
|
501
|
+
"a",
|
|
502
|
+
"button",
|
|
503
|
+
"div",
|
|
504
|
+
"form",
|
|
505
|
+
"h2",
|
|
506
|
+
"h3",
|
|
507
|
+
"img",
|
|
508
|
+
"input",
|
|
509
|
+
"label",
|
|
510
|
+
"li",
|
|
511
|
+
"nav",
|
|
512
|
+
"ol",
|
|
513
|
+
"p",
|
|
514
|
+
"select",
|
|
515
|
+
"span",
|
|
516
|
+
"svg",
|
|
517
|
+
"ul"
|
|
518
|
+
];
|
|
519
|
+
var Primitive = NODES.reduce((primitive, node) => {
|
|
520
|
+
const Slot = createSlot(`Primitive.${node}`);
|
|
521
|
+
const Node = React9.forwardRef((props, forwardedRef) => {
|
|
522
|
+
const { asChild, ...primitiveProps } = props;
|
|
523
|
+
const Comp = asChild ? Slot : node;
|
|
524
|
+
if (typeof window !== "undefined") {
|
|
525
|
+
window[Symbol.for("radix-ui")] = true;
|
|
526
|
+
}
|
|
527
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Comp, { ...primitiveProps, ref: forwardedRef });
|
|
528
|
+
});
|
|
529
|
+
Node.displayName = `Primitive.${node}`;
|
|
530
|
+
return { ...primitive, [node]: Node };
|
|
531
|
+
}, {});
|
|
532
|
+
|
|
533
|
+
// node_modules/@radix-ui/react-checkbox/dist/index.mjs
|
|
534
|
+
var import_jsx_runtime4 = require("react/jsx-runtime");
|
|
535
|
+
var CHECKBOX_NAME = "Checkbox";
|
|
536
|
+
var [createCheckboxContext, createCheckboxScope] = createContextScope(CHECKBOX_NAME);
|
|
537
|
+
var [CheckboxProviderImpl, useCheckboxContext] = createCheckboxContext(CHECKBOX_NAME);
|
|
538
|
+
function CheckboxProvider(props) {
|
|
539
|
+
const {
|
|
540
|
+
__scopeCheckbox,
|
|
541
|
+
checked: checkedProp,
|
|
542
|
+
children,
|
|
543
|
+
defaultChecked,
|
|
544
|
+
disabled,
|
|
545
|
+
form,
|
|
546
|
+
name,
|
|
547
|
+
onCheckedChange,
|
|
548
|
+
required,
|
|
549
|
+
value = "on",
|
|
550
|
+
// @ts-expect-error
|
|
551
|
+
internal_do_not_use_render
|
|
552
|
+
} = props;
|
|
553
|
+
const [checked, setChecked] = useControllableState({
|
|
554
|
+
prop: checkedProp,
|
|
555
|
+
defaultProp: defaultChecked ?? false,
|
|
556
|
+
onChange: onCheckedChange,
|
|
557
|
+
caller: CHECKBOX_NAME
|
|
558
|
+
});
|
|
559
|
+
const [control, setControl] = React10.useState(null);
|
|
560
|
+
const [bubbleInput, setBubbleInput] = React10.useState(null);
|
|
561
|
+
const hasConsumerStoppedPropagationRef = React10.useRef(false);
|
|
562
|
+
const isFormControl = control ? !!form || !!control.closest("form") : (
|
|
563
|
+
// We set this to true by default so that events bubble to forms without JS (SSR)
|
|
564
|
+
true
|
|
565
|
+
);
|
|
566
|
+
const context = {
|
|
567
|
+
checked,
|
|
568
|
+
disabled,
|
|
569
|
+
setChecked,
|
|
570
|
+
control,
|
|
571
|
+
setControl,
|
|
572
|
+
name,
|
|
573
|
+
form,
|
|
574
|
+
value,
|
|
575
|
+
hasConsumerStoppedPropagationRef,
|
|
576
|
+
required,
|
|
577
|
+
defaultChecked: isIndeterminate(defaultChecked) ? false : defaultChecked,
|
|
578
|
+
isFormControl,
|
|
579
|
+
bubbleInput,
|
|
580
|
+
setBubbleInput
|
|
581
|
+
};
|
|
582
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
583
|
+
CheckboxProviderImpl,
|
|
584
|
+
{
|
|
585
|
+
scope: __scopeCheckbox,
|
|
586
|
+
...context,
|
|
587
|
+
children: isFunction2(internal_do_not_use_render) ? internal_do_not_use_render(context) : children
|
|
588
|
+
}
|
|
589
|
+
);
|
|
590
|
+
}
|
|
591
|
+
var TRIGGER_NAME = "CheckboxTrigger";
|
|
592
|
+
var CheckboxTrigger = React10.forwardRef(
|
|
593
|
+
({ __scopeCheckbox, onKeyDown, onClick, ...checkboxProps }, forwardedRef) => {
|
|
594
|
+
const {
|
|
595
|
+
control,
|
|
596
|
+
value,
|
|
597
|
+
disabled,
|
|
598
|
+
checked,
|
|
599
|
+
required,
|
|
600
|
+
setControl,
|
|
601
|
+
setChecked,
|
|
602
|
+
hasConsumerStoppedPropagationRef,
|
|
603
|
+
isFormControl,
|
|
604
|
+
bubbleInput
|
|
605
|
+
} = useCheckboxContext(TRIGGER_NAME, __scopeCheckbox);
|
|
606
|
+
const composedRefs = useComposedRefs(forwardedRef, setControl);
|
|
607
|
+
const initialCheckedStateRef = React10.useRef(checked);
|
|
608
|
+
React10.useEffect(() => {
|
|
609
|
+
const form = control?.form;
|
|
610
|
+
if (form) {
|
|
611
|
+
const reset = () => setChecked(initialCheckedStateRef.current);
|
|
612
|
+
form.addEventListener("reset", reset);
|
|
613
|
+
return () => form.removeEventListener("reset", reset);
|
|
614
|
+
}
|
|
615
|
+
}, [control, setChecked]);
|
|
616
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
617
|
+
Primitive.button,
|
|
618
|
+
{
|
|
619
|
+
type: "button",
|
|
620
|
+
role: "checkbox",
|
|
621
|
+
"aria-checked": isIndeterminate(checked) ? "mixed" : checked,
|
|
622
|
+
"aria-required": required,
|
|
623
|
+
"data-state": getState(checked),
|
|
624
|
+
"data-disabled": disabled ? "" : void 0,
|
|
625
|
+
disabled,
|
|
626
|
+
value,
|
|
627
|
+
...checkboxProps,
|
|
628
|
+
ref: composedRefs,
|
|
629
|
+
onKeyDown: composeEventHandlers(onKeyDown, (event) => {
|
|
630
|
+
if (event.key === "Enter") event.preventDefault();
|
|
631
|
+
}),
|
|
632
|
+
onClick: composeEventHandlers(onClick, (event) => {
|
|
633
|
+
setChecked((prevChecked) => isIndeterminate(prevChecked) ? true : !prevChecked);
|
|
634
|
+
if (bubbleInput && isFormControl) {
|
|
635
|
+
hasConsumerStoppedPropagationRef.current = event.isPropagationStopped();
|
|
636
|
+
if (!hasConsumerStoppedPropagationRef.current) event.stopPropagation();
|
|
637
|
+
}
|
|
638
|
+
})
|
|
639
|
+
}
|
|
640
|
+
);
|
|
641
|
+
}
|
|
642
|
+
);
|
|
643
|
+
CheckboxTrigger.displayName = TRIGGER_NAME;
|
|
644
|
+
var Checkbox = React10.forwardRef(
|
|
645
|
+
(props, forwardedRef) => {
|
|
646
|
+
const {
|
|
647
|
+
__scopeCheckbox,
|
|
648
|
+
name,
|
|
649
|
+
checked,
|
|
650
|
+
defaultChecked,
|
|
651
|
+
required,
|
|
652
|
+
disabled,
|
|
653
|
+
value,
|
|
654
|
+
onCheckedChange,
|
|
655
|
+
form,
|
|
656
|
+
...checkboxProps
|
|
657
|
+
} = props;
|
|
658
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
659
|
+
CheckboxProvider,
|
|
660
|
+
{
|
|
661
|
+
__scopeCheckbox,
|
|
662
|
+
checked,
|
|
663
|
+
defaultChecked,
|
|
664
|
+
disabled,
|
|
665
|
+
required,
|
|
666
|
+
onCheckedChange,
|
|
667
|
+
name,
|
|
668
|
+
form,
|
|
669
|
+
value,
|
|
670
|
+
internal_do_not_use_render: ({ isFormControl }) => /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
|
|
671
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
672
|
+
CheckboxTrigger,
|
|
673
|
+
{
|
|
674
|
+
...checkboxProps,
|
|
675
|
+
ref: forwardedRef,
|
|
676
|
+
__scopeCheckbox
|
|
677
|
+
}
|
|
678
|
+
),
|
|
679
|
+
isFormControl && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
680
|
+
CheckboxBubbleInput,
|
|
681
|
+
{
|
|
682
|
+
__scopeCheckbox
|
|
683
|
+
}
|
|
684
|
+
)
|
|
685
|
+
] })
|
|
686
|
+
}
|
|
687
|
+
);
|
|
688
|
+
}
|
|
689
|
+
);
|
|
690
|
+
Checkbox.displayName = CHECKBOX_NAME;
|
|
691
|
+
var INDICATOR_NAME = "CheckboxIndicator";
|
|
692
|
+
var CheckboxIndicator = React10.forwardRef(
|
|
693
|
+
(props, forwardedRef) => {
|
|
694
|
+
const { __scopeCheckbox, forceMount, ...indicatorProps } = props;
|
|
695
|
+
const context = useCheckboxContext(INDICATOR_NAME, __scopeCheckbox);
|
|
696
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
697
|
+
Presence,
|
|
698
|
+
{
|
|
699
|
+
present: forceMount || isIndeterminate(context.checked) || context.checked === true,
|
|
700
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
701
|
+
Primitive.span,
|
|
702
|
+
{
|
|
703
|
+
"data-state": getState(context.checked),
|
|
704
|
+
"data-disabled": context.disabled ? "" : void 0,
|
|
705
|
+
...indicatorProps,
|
|
706
|
+
ref: forwardedRef,
|
|
707
|
+
style: { pointerEvents: "none", ...props.style }
|
|
708
|
+
}
|
|
709
|
+
)
|
|
710
|
+
}
|
|
711
|
+
);
|
|
712
|
+
}
|
|
713
|
+
);
|
|
714
|
+
CheckboxIndicator.displayName = INDICATOR_NAME;
|
|
715
|
+
var BUBBLE_INPUT_NAME = "CheckboxBubbleInput";
|
|
716
|
+
var CheckboxBubbleInput = React10.forwardRef(
|
|
717
|
+
({ __scopeCheckbox, ...props }, forwardedRef) => {
|
|
718
|
+
const {
|
|
719
|
+
control,
|
|
720
|
+
hasConsumerStoppedPropagationRef,
|
|
721
|
+
checked,
|
|
722
|
+
defaultChecked,
|
|
723
|
+
required,
|
|
724
|
+
disabled,
|
|
725
|
+
name,
|
|
726
|
+
value,
|
|
727
|
+
form,
|
|
728
|
+
bubbleInput,
|
|
729
|
+
setBubbleInput
|
|
730
|
+
} = useCheckboxContext(BUBBLE_INPUT_NAME, __scopeCheckbox);
|
|
731
|
+
const composedRefs = useComposedRefs(forwardedRef, setBubbleInput);
|
|
732
|
+
const prevChecked = usePrevious(checked);
|
|
733
|
+
const controlSize = useSize(control);
|
|
734
|
+
React10.useEffect(() => {
|
|
735
|
+
const input = bubbleInput;
|
|
736
|
+
if (!input) return;
|
|
737
|
+
const inputProto = window.HTMLInputElement.prototype;
|
|
738
|
+
const descriptor = Object.getOwnPropertyDescriptor(
|
|
739
|
+
inputProto,
|
|
740
|
+
"checked"
|
|
741
|
+
);
|
|
742
|
+
const setChecked = descriptor.set;
|
|
743
|
+
const bubbles = !hasConsumerStoppedPropagationRef.current;
|
|
744
|
+
if (prevChecked !== checked && setChecked) {
|
|
745
|
+
const event = new Event("click", { bubbles });
|
|
746
|
+
input.indeterminate = isIndeterminate(checked);
|
|
747
|
+
setChecked.call(input, isIndeterminate(checked) ? false : checked);
|
|
748
|
+
input.dispatchEvent(event);
|
|
749
|
+
}
|
|
750
|
+
}, [bubbleInput, prevChecked, checked, hasConsumerStoppedPropagationRef]);
|
|
751
|
+
const defaultCheckedRef = React10.useRef(isIndeterminate(checked) ? false : checked);
|
|
752
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
753
|
+
Primitive.input,
|
|
754
|
+
{
|
|
755
|
+
type: "checkbox",
|
|
756
|
+
"aria-hidden": true,
|
|
757
|
+
defaultChecked: defaultChecked ?? defaultCheckedRef.current,
|
|
758
|
+
required,
|
|
759
|
+
disabled,
|
|
760
|
+
name,
|
|
761
|
+
value,
|
|
762
|
+
form,
|
|
763
|
+
...props,
|
|
764
|
+
tabIndex: -1,
|
|
765
|
+
ref: composedRefs,
|
|
766
|
+
style: {
|
|
767
|
+
...props.style,
|
|
768
|
+
...controlSize,
|
|
769
|
+
position: "absolute",
|
|
770
|
+
pointerEvents: "none",
|
|
771
|
+
opacity: 0,
|
|
772
|
+
margin: 0,
|
|
773
|
+
// We transform because the input is absolutely positioned but we have
|
|
774
|
+
// rendered it **after** the button. This pulls it back to sit on top
|
|
775
|
+
// of the button.
|
|
776
|
+
transform: "translateX(-100%)"
|
|
777
|
+
}
|
|
778
|
+
}
|
|
779
|
+
);
|
|
780
|
+
}
|
|
781
|
+
);
|
|
782
|
+
CheckboxBubbleInput.displayName = BUBBLE_INPUT_NAME;
|
|
783
|
+
function isFunction2(value) {
|
|
784
|
+
return typeof value === "function";
|
|
785
|
+
}
|
|
786
|
+
function isIndeterminate(checked) {
|
|
787
|
+
return checked === "indeterminate";
|
|
788
|
+
}
|
|
789
|
+
function getState(checked) {
|
|
790
|
+
return isIndeterminate(checked) ? "indeterminate" : checked ? "checked" : "unchecked";
|
|
791
|
+
}
|
|
792
|
+
|
|
793
|
+
// src/components/user-action/Checkbox.tsx
|
|
794
|
+
var import_jsx_runtime5 = require("react/jsx-runtime");
|
|
66
795
|
var checkboxSizeMapping = {
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
796
|
+
sm: "size-5 border-1",
|
|
797
|
+
md: "size-6 border-1",
|
|
798
|
+
lg: "size-8 border-2"
|
|
70
799
|
};
|
|
71
800
|
var checkboxIconSizeMapping = {
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
801
|
+
sm: "size-4 stroke-3",
|
|
802
|
+
md: "size-5 stroke-3",
|
|
803
|
+
lg: "size-7 stroke-3"
|
|
75
804
|
};
|
|
76
|
-
var
|
|
77
|
-
id,
|
|
78
|
-
label,
|
|
79
|
-
checked,
|
|
805
|
+
var Checkbox2 = ({
|
|
80
806
|
disabled,
|
|
807
|
+
checked = false,
|
|
808
|
+
indeterminate = false,
|
|
81
809
|
onChange,
|
|
82
|
-
|
|
83
|
-
size = "medium",
|
|
810
|
+
size = "md",
|
|
84
811
|
className = "",
|
|
85
|
-
|
|
812
|
+
...props
|
|
86
813
|
}) => {
|
|
87
814
|
const usedSizeClass = checkboxSizeMapping[size];
|
|
88
815
|
const innerIconSize = checkboxIconSizeMapping[size];
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
onChangeTristate(checked2);
|
|
92
|
-
}
|
|
93
|
-
if (onChange) {
|
|
94
|
-
onChange(checked2 === "indeterminate" ? false : checked2);
|
|
95
|
-
}
|
|
96
|
-
};
|
|
97
|
-
const changeValue = () => {
|
|
98
|
-
if (disabled) {
|
|
99
|
-
return;
|
|
100
|
-
}
|
|
101
|
-
const newValue = checked === "indeterminate" ? false : !checked;
|
|
102
|
-
propagateChange(newValue);
|
|
103
|
-
};
|
|
104
|
-
return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
|
|
105
|
-
"div",
|
|
816
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
817
|
+
Checkbox,
|
|
106
818
|
{
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
checked === true && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_lucide_react.Check, { className: innerIconSize }),
|
|
128
|
-
checked === "indeterminate" && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_lucide_react.Minus, { className: innerIconSize })
|
|
129
|
-
] })
|
|
130
|
-
}
|
|
131
|
-
),
|
|
132
|
-
label && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
133
|
-
Label,
|
|
134
|
-
{
|
|
135
|
-
...label,
|
|
136
|
-
className: (0, import_clsx2.default)(
|
|
137
|
-
label.className,
|
|
138
|
-
{
|
|
139
|
-
"cursor-pointer": !disabled,
|
|
140
|
-
"cursor-not-allowed": disabled
|
|
141
|
-
}
|
|
142
|
-
),
|
|
143
|
-
htmlFor: id
|
|
144
|
-
}
|
|
145
|
-
)
|
|
146
|
-
]
|
|
819
|
+
...props,
|
|
820
|
+
disabled,
|
|
821
|
+
checked: indeterminate ? "indeterminate" : checked,
|
|
822
|
+
onCheckedChange: onChange,
|
|
823
|
+
className: (0, import_clsx.default)(
|
|
824
|
+
usedSizeClass,
|
|
825
|
+
`flex-col-0 items-center justify-center rounded outline-none`,
|
|
826
|
+
{
|
|
827
|
+
"text-disabled-text border-disabled-outline bg-disabled-background cursor-not-allowed": disabled,
|
|
828
|
+
"hover:border-primary": !disabled,
|
|
829
|
+
"bg-input-background": !disabled && !checked,
|
|
830
|
+
"bg-primary/30 border-primary text-primary": !disabled && (checked || indeterminate)
|
|
831
|
+
},
|
|
832
|
+
className
|
|
833
|
+
),
|
|
834
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(CheckboxIndicator, { children: [
|
|
835
|
+
!checked && !indeterminate && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: (0, import_clsx.default)("bg-input-background", innerIconSize) }),
|
|
836
|
+
checked && !indeterminate && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_lucide_react.Check, { className: innerIconSize }),
|
|
837
|
+
indeterminate && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_lucide_react.Minus, { className: innerIconSize })
|
|
838
|
+
] })
|
|
147
839
|
}
|
|
148
840
|
);
|
|
149
841
|
};
|
|
@@ -168,7 +860,7 @@ var LanguageUtil = {
|
|
|
168
860
|
};
|
|
169
861
|
|
|
170
862
|
// src/localization/LanguageProvider.tsx
|
|
171
|
-
var
|
|
863
|
+
var import_jsx_runtime6 = require("react/jsx-runtime");
|
|
172
864
|
var LanguageContext = (0, import_react3.createContext)({
|
|
173
865
|
language: LanguageUtil.DEFAULT_LANGUAGE,
|
|
174
866
|
setLanguage: (v) => v
|
|
@@ -237,12 +929,12 @@ var useTranslation = (translations, overwriteTranslation = {}) => {
|
|
|
237
929
|
|
|
238
930
|
// src/components/properties/PropertyBase.tsx
|
|
239
931
|
var import_lucide_react2 = require("lucide-react");
|
|
240
|
-
var
|
|
932
|
+
var import_clsx3 = __toESM(require("clsx"));
|
|
241
933
|
|
|
242
934
|
// src/components/user-action/Button.tsx
|
|
243
935
|
var import_react4 = require("react");
|
|
244
|
-
var
|
|
245
|
-
var
|
|
936
|
+
var import_clsx2 = __toESM(require("clsx"));
|
|
937
|
+
var import_jsx_runtime7 = require("react/jsx-runtime");
|
|
246
938
|
var ButtonColorUtil = {
|
|
247
939
|
solid: ["primary", "secondary", "tertiary", "positive", "warning", "negative", "neutral"],
|
|
248
940
|
text: ["primary", "negative", "neutral"],
|
|
@@ -294,12 +986,12 @@ var SolidButton = (0, import_react4.forwardRef)(function SolidButton2({
|
|
|
294
986
|
negative: "not-group-disabled:text-button-solid-negative-icon",
|
|
295
987
|
neutral: "not-group-disabled:text-button-solid-neutral-icon"
|
|
296
988
|
}[color];
|
|
297
|
-
return /* @__PURE__ */ (0,
|
|
989
|
+
return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
|
|
298
990
|
"button",
|
|
299
991
|
{
|
|
300
992
|
ref,
|
|
301
993
|
onClick,
|
|
302
|
-
className: (0,
|
|
994
|
+
className: (0, import_clsx2.default)(
|
|
303
995
|
"group font-semibold",
|
|
304
996
|
colorClasses,
|
|
305
997
|
"not-disabled:hover:brightness-90",
|
|
@@ -309,10 +1001,10 @@ var SolidButton = (0, import_react4.forwardRef)(function SolidButton2({
|
|
|
309
1001
|
),
|
|
310
1002
|
...restProps,
|
|
311
1003
|
children: [
|
|
312
|
-
startIcon && /* @__PURE__ */ (0,
|
|
1004
|
+
startIcon && /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
|
|
313
1005
|
"span",
|
|
314
1006
|
{
|
|
315
|
-
className: (0,
|
|
1007
|
+
className: (0, import_clsx2.default)(
|
|
316
1008
|
iconColorClasses,
|
|
317
1009
|
"group-disabled:text-disabled-icon"
|
|
318
1010
|
),
|
|
@@ -320,10 +1012,10 @@ var SolidButton = (0, import_react4.forwardRef)(function SolidButton2({
|
|
|
320
1012
|
}
|
|
321
1013
|
),
|
|
322
1014
|
children,
|
|
323
|
-
endIcon && /* @__PURE__ */ (0,
|
|
1015
|
+
endIcon && /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
|
|
324
1016
|
"span",
|
|
325
1017
|
{
|
|
326
|
-
className: (0,
|
|
1018
|
+
className: (0, import_clsx2.default)(
|
|
327
1019
|
iconColorClasses,
|
|
328
1020
|
"group-disabled:text-disabled-icon"
|
|
329
1021
|
),
|
|
@@ -346,25 +1038,25 @@ var TextButton = ({
|
|
|
346
1038
|
...restProps
|
|
347
1039
|
}) => {
|
|
348
1040
|
const colorClasses = {
|
|
349
|
-
primary: "not-disabled:bg-transparent not-disabled:text-button-text-primary-text",
|
|
350
|
-
negative: "not-disabled:bg-transparent not-disabled:text-button-text-negative-text",
|
|
351
|
-
neutral: "not-disabled:bg-transparent not-disabled:text-button-text-neutral-text"
|
|
1041
|
+
primary: "not-disabled:bg-transparent not-disabled:text-button-text-primary-text focus-style-none focus-visible:ring-2 not-disabled:focus-visible:ring-button-text-primary-text",
|
|
1042
|
+
negative: "not-disabled:bg-transparent not-disabled:text-button-text-negative-text focus-style-none focus-visible:ring-2 not-disabled:focus-visible:ring-button-text-negative-text",
|
|
1043
|
+
neutral: "not-disabled:bg-transparent not-disabled:text-button-text-neutral-text focus-style-none focus-visible:ring-2 not-disabled:focus-visible:ring-button-text-neutral-text"
|
|
352
1044
|
}[color];
|
|
353
1045
|
const backgroundColor = {
|
|
354
|
-
primary: "not-disabled:hover:bg-button-text-primary-text/20",
|
|
355
|
-
negative: "not-disabled:hover:bg-button-text-negative-text/20",
|
|
356
|
-
neutral: "not-disabled:hover:bg-button-text-neutral-text/20"
|
|
1046
|
+
primary: "not-disabled:hover:bg-button-text-primary-text/20 not-disabled:focus-visible:bg-button-text-primary-text/20",
|
|
1047
|
+
negative: "not-disabled:hover:bg-button-text-negative-text/20 not-disabled:focus-visible:bg-button-text-negative-text/20",
|
|
1048
|
+
neutral: "not-disabled:hover:bg-button-text-neutral-text/20 not-disabled:focus-visible:bg-button-text-neutral-text/20"
|
|
357
1049
|
}[color];
|
|
358
1050
|
const iconColorClasses = {
|
|
359
1051
|
primary: "not-group-disabled:text-button-text-primary-icon",
|
|
360
1052
|
negative: "not-group-disabled:text-button-text-negative-icon",
|
|
361
1053
|
neutral: "not-group-disabled:text-button-text-neutral-icon"
|
|
362
1054
|
}[color];
|
|
363
|
-
return /* @__PURE__ */ (0,
|
|
1055
|
+
return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
|
|
364
1056
|
"button",
|
|
365
1057
|
{
|
|
366
1058
|
onClick,
|
|
367
|
-
className: (0,
|
|
1059
|
+
className: (0, import_clsx2.default)(
|
|
368
1060
|
"group font-semibold",
|
|
369
1061
|
"disabled:text-disabled-text",
|
|
370
1062
|
colorClasses,
|
|
@@ -377,10 +1069,10 @@ var TextButton = ({
|
|
|
377
1069
|
),
|
|
378
1070
|
...restProps,
|
|
379
1071
|
children: [
|
|
380
|
-
startIcon && /* @__PURE__ */ (0,
|
|
1072
|
+
startIcon && /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
|
|
381
1073
|
"span",
|
|
382
1074
|
{
|
|
383
|
-
className: (0,
|
|
1075
|
+
className: (0, import_clsx2.default)(
|
|
384
1076
|
iconColorClasses,
|
|
385
1077
|
"group-disabled:text-disabled-icon"
|
|
386
1078
|
),
|
|
@@ -388,10 +1080,10 @@ var TextButton = ({
|
|
|
388
1080
|
}
|
|
389
1081
|
),
|
|
390
1082
|
children,
|
|
391
|
-
endIcon && /* @__PURE__ */ (0,
|
|
1083
|
+
endIcon && /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
|
|
392
1084
|
"span",
|
|
393
1085
|
{
|
|
394
|
-
className: (0,
|
|
1086
|
+
className: (0, import_clsx2.default)(
|
|
395
1087
|
iconColorClasses,
|
|
396
1088
|
"group-disabled:text-disabled-icon"
|
|
397
1089
|
),
|
|
@@ -402,6 +1094,44 @@ var TextButton = ({
|
|
|
402
1094
|
}
|
|
403
1095
|
);
|
|
404
1096
|
};
|
|
1097
|
+
var IconButton = (0, import_react4.forwardRef)(function IconButton2({
|
|
1098
|
+
children,
|
|
1099
|
+
color = "primary",
|
|
1100
|
+
size = "medium",
|
|
1101
|
+
className,
|
|
1102
|
+
...restProps
|
|
1103
|
+
}, ref) {
|
|
1104
|
+
const colorClasses = {
|
|
1105
|
+
primary: "not-disabled:bg-button-solid-primary-background not-disabled:text-button-solid-primary-text",
|
|
1106
|
+
secondary: "not-disabled:bg-button-solid-secondary-background not-disabled:text-button-solid-secondary-text",
|
|
1107
|
+
tertiary: "not-disabled:bg-button-solid-tertiary-background not-disabled:text-button-solid-tertiary-text",
|
|
1108
|
+
positive: "not-disabled:bg-button-solid-positive-background not-disabled:text-button-solid-positive-text",
|
|
1109
|
+
warning: "not-disabled:bg-button-solid-warning-background not-disabled:text-button-solid-warning-text",
|
|
1110
|
+
negative: "not-disabled:bg-button-solid-negative-background not-disabled:text-button-solid-negative-text",
|
|
1111
|
+
neutral: "not-disabled:bg-button-solid-neutral-background not-disabled:text-button-solid-neutral-text",
|
|
1112
|
+
transparent: "not-disabled:bg-transparent"
|
|
1113
|
+
}[color];
|
|
1114
|
+
return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
|
|
1115
|
+
"button",
|
|
1116
|
+
{
|
|
1117
|
+
ref,
|
|
1118
|
+
className: (0, import_clsx2.default)(
|
|
1119
|
+
colorClasses,
|
|
1120
|
+
"not-disabled:hover:brightness-90",
|
|
1121
|
+
"disabled:text-disabled-text",
|
|
1122
|
+
{
|
|
1123
|
+
"disabled:bg-disabled-background": color !== "transparent",
|
|
1124
|
+
"disabled:opacity-70": color === "transparent",
|
|
1125
|
+
"not-disabled:hover:bg-button-text-hover-background": color === "transparent"
|
|
1126
|
+
},
|
|
1127
|
+
ButtonUtil.iconPaddingMapping[size],
|
|
1128
|
+
className
|
|
1129
|
+
),
|
|
1130
|
+
...restProps,
|
|
1131
|
+
children
|
|
1132
|
+
}
|
|
1133
|
+
);
|
|
1134
|
+
});
|
|
405
1135
|
|
|
406
1136
|
// src/localization/defaults/form.ts
|
|
407
1137
|
var formTranslation = {
|
|
@@ -439,6 +1169,7 @@ var formTranslation = {
|
|
|
439
1169
|
next: "Next",
|
|
440
1170
|
no: "No",
|
|
441
1171
|
none: "None",
|
|
1172
|
+
nothingFound: "Nothing found",
|
|
442
1173
|
of: "of",
|
|
443
1174
|
optional: "Optional",
|
|
444
1175
|
pleaseWait: "Please wait...",
|
|
@@ -495,6 +1226,7 @@ var formTranslation = {
|
|
|
495
1226
|
next: "Weiter",
|
|
496
1227
|
no: "Nein",
|
|
497
1228
|
none: "Nichts",
|
|
1229
|
+
nothingFound: "Nichts gefunden",
|
|
498
1230
|
of: "von",
|
|
499
1231
|
optional: "Optional",
|
|
500
1232
|
pleaseWait: "Bitte warten...",
|
|
@@ -520,7 +1252,7 @@ var formTranslation = {
|
|
|
520
1252
|
};
|
|
521
1253
|
|
|
522
1254
|
// src/components/properties/PropertyBase.tsx
|
|
523
|
-
var
|
|
1255
|
+
var import_jsx_runtime8 = require("react/jsx-runtime");
|
|
524
1256
|
var PropertyBase = ({
|
|
525
1257
|
overwriteTranslation,
|
|
526
1258
|
name,
|
|
@@ -534,11 +1266,11 @@ var PropertyBase = ({
|
|
|
534
1266
|
}) => {
|
|
535
1267
|
const translation = useTranslation([formTranslation], overwriteTranslation);
|
|
536
1268
|
const requiredAndNoValue = softRequired && !hasValue;
|
|
537
|
-
return /* @__PURE__ */ (0,
|
|
538
|
-
/* @__PURE__ */ (0,
|
|
1269
|
+
return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: (0, import_clsx3.default)("flex-row-0 group", className), children: [
|
|
1270
|
+
/* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
|
|
539
1271
|
"div",
|
|
540
1272
|
{
|
|
541
|
-
className: (0,
|
|
1273
|
+
className: (0, import_clsx3.default)(
|
|
542
1274
|
"flex-row-2 max-w-48 min-w-48 px-3 py-2 items-center rounded-l-xl border-2 border-r-0",
|
|
543
1275
|
{
|
|
544
1276
|
"bg-property-title-background text-property-title-text group-hover:border-primary": !requiredAndNoValue,
|
|
@@ -547,15 +1279,15 @@ var PropertyBase = ({
|
|
|
547
1279
|
className
|
|
548
1280
|
),
|
|
549
1281
|
children: [
|
|
550
|
-
/* @__PURE__ */ (0,
|
|
551
|
-
/* @__PURE__ */ (0,
|
|
1282
|
+
/* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "max-w-6 min-w-6 text-text-primary", children: icon }),
|
|
1283
|
+
/* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { className: "font-semibold", children: name })
|
|
552
1284
|
]
|
|
553
1285
|
}
|
|
554
1286
|
),
|
|
555
|
-
/* @__PURE__ */ (0,
|
|
1287
|
+
/* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
|
|
556
1288
|
"div",
|
|
557
1289
|
{
|
|
558
|
-
className: (0,
|
|
1290
|
+
className: (0, import_clsx3.default)(
|
|
559
1291
|
"flex-row-2 grow px-3 py-2 justify-between items-center rounded-r-xl border-2 border-l-0 min-h-15",
|
|
560
1292
|
{
|
|
561
1293
|
"bg-input-background text-input-text group-hover:border-primary": !requiredAndNoValue,
|
|
@@ -565,14 +1297,14 @@ var PropertyBase = ({
|
|
|
565
1297
|
),
|
|
566
1298
|
children: [
|
|
567
1299
|
input({ softRequired, hasValue }),
|
|
568
|
-
requiredAndNoValue && /* @__PURE__ */ (0,
|
|
569
|
-
onRemove &&
|
|
1300
|
+
requiredAndNoValue && /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "text-warning", children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_lucide_react2.AlertTriangle, { size: 24 }) }),
|
|
1301
|
+
onRemove && !readOnly && /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
|
|
570
1302
|
TextButton,
|
|
571
1303
|
{
|
|
572
1304
|
onClick: onRemove,
|
|
573
1305
|
color: "negative",
|
|
574
|
-
className: (0,
|
|
575
|
-
disabled: !hasValue
|
|
1306
|
+
className: (0, import_clsx3.default)("items-center"),
|
|
1307
|
+
disabled: !hasValue,
|
|
576
1308
|
children: translation("remove")
|
|
577
1309
|
}
|
|
578
1310
|
)
|
|
@@ -583,7 +1315,26 @@ var PropertyBase = ({
|
|
|
583
1315
|
};
|
|
584
1316
|
|
|
585
1317
|
// src/components/properties/CheckboxProperty.tsx
|
|
586
|
-
var
|
|
1318
|
+
var import_react5 = require("react");
|
|
1319
|
+
|
|
1320
|
+
// src/components/user-action/Label.tsx
|
|
1321
|
+
var import_clsx4 = __toESM(require("clsx"));
|
|
1322
|
+
var import_jsx_runtime9 = require("react/jsx-runtime");
|
|
1323
|
+
var styleMapping = {
|
|
1324
|
+
sm: "typography-label-xs color-label-text",
|
|
1325
|
+
md: "typography-label-md color-label-text"
|
|
1326
|
+
};
|
|
1327
|
+
var Label = ({
|
|
1328
|
+
children,
|
|
1329
|
+
size = "md",
|
|
1330
|
+
className,
|
|
1331
|
+
...props
|
|
1332
|
+
}) => {
|
|
1333
|
+
return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("label", { ...props, className: (0, import_clsx4.default)(styleMapping[size], className), children });
|
|
1334
|
+
};
|
|
1335
|
+
|
|
1336
|
+
// src/components/properties/CheckboxProperty.tsx
|
|
1337
|
+
var import_jsx_runtime10 = require("react/jsx-runtime");
|
|
587
1338
|
var CheckboxProperty = ({
|
|
588
1339
|
overwriteTranslation,
|
|
589
1340
|
value,
|
|
@@ -592,23 +1343,27 @@ var CheckboxProperty = ({
|
|
|
592
1343
|
...baseProps
|
|
593
1344
|
}) => {
|
|
594
1345
|
const translation = useTranslation([formTranslation], overwriteTranslation);
|
|
595
|
-
|
|
1346
|
+
const id = (0, import_react5.useId)();
|
|
1347
|
+
return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
|
|
596
1348
|
PropertyBase,
|
|
597
1349
|
{
|
|
598
1350
|
...baseProps,
|
|
599
1351
|
hasValue: true,
|
|
600
1352
|
readOnly,
|
|
601
|
-
icon: /* @__PURE__ */ (0,
|
|
602
|
-
input: () => /* @__PURE__ */ (0,
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
1353
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_lucide_react3.Check, { size: 24 }),
|
|
1354
|
+
input: () => /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "flex-row-2 items-center", children: [
|
|
1355
|
+
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
|
|
1356
|
+
Checkbox2,
|
|
1357
|
+
{
|
|
1358
|
+
id,
|
|
1359
|
+
checked: value ?? true,
|
|
1360
|
+
disabled: readOnly,
|
|
1361
|
+
onChange,
|
|
1362
|
+
"aria-labelledby": id + "label"
|
|
1363
|
+
}
|
|
1364
|
+
),
|
|
1365
|
+
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Label, { id: id + "label", children: `${translation("yes")}/${translation("no")}` })
|
|
1366
|
+
] })
|
|
612
1367
|
}
|
|
613
1368
|
);
|
|
614
1369
|
};
|