@povio/ui 0.0.8 → 0.0.9
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/assets/icons/AlignCenter.js +21 -0
- package/dist/assets/icons/AlignLeft.js +21 -0
- package/dist/assets/icons/AlignLeftRight.js +21 -0
- package/dist/assets/icons/AlignRight.js +21 -0
- package/dist/assets/icons/ArrowDropDown.js +21 -0
- package/dist/assets/icons/ArrowDropUp.js +21 -0
- package/dist/assets/icons/ArrowLeft.js +21 -0
- package/dist/assets/icons/ArrowRight.js +21 -0
- package/dist/assets/icons/Bold.js +21 -0
- package/dist/assets/icons/BulletedList.js +21 -0
- package/dist/assets/icons/Calendar.js +23 -0
- package/dist/assets/icons/Check.js +23 -0
- package/dist/assets/icons/CheckCircle.js +21 -0
- package/dist/assets/icons/CheckboxCheckmark.js +24 -0
- package/dist/assets/icons/CheckboxIndeterminate.js +24 -0
- package/dist/assets/icons/ChevronDown.js +23 -0
- package/dist/assets/icons/ChevronLeft.js +23 -0
- package/dist/assets/icons/ChevronRight.js +23 -0
- package/dist/assets/icons/ChevronUp.js +23 -0
- package/dist/assets/icons/ChevronsLeft.js +23 -0
- package/dist/assets/icons/ChevronsRight.js +23 -0
- package/dist/assets/icons/Clock.js +21 -0
- package/dist/assets/icons/Close.js +21 -0
- package/dist/assets/icons/DateTime.js +32 -0
- package/dist/assets/icons/Drag.js +21 -0
- package/dist/assets/icons/File.js +23 -0
- package/dist/assets/icons/Highlight.js +21 -0
- package/dist/assets/icons/HighlightOn.js +30 -0
- package/dist/assets/icons/Info.js +32 -0
- package/dist/assets/icons/Italic.js +21 -0
- package/dist/assets/icons/Link.js +21 -0
- package/dist/assets/icons/Menu.js +21 -0
- package/dist/assets/icons/NumberedList.js +21 -0
- package/dist/assets/icons/PointerHorizontal.js +21 -0
- package/dist/assets/icons/PointerVertical.js +21 -0
- package/dist/assets/icons/Send.js +23 -0
- package/dist/assets/icons/Strikethrough.js +21 -0
- package/dist/assets/icons/TextColor.js +30 -0
- package/dist/assets/icons/Today.js +21 -0
- package/dist/assets/icons/Underlined.js +23 -0
- package/dist/assets/icons/Upload.js +30 -0
- package/dist/assets/icons/View.js +18 -0
- package/dist/assets/icons/ViewOff.js +18 -0
- package/dist/assets/icons/WarningFilled.js +23 -0
- package/dist/assets/locales/en/translation.json.js +14 -0
- package/dist/assets/locales/sl/translation.json.js +14 -0
- package/dist/components/Menu/Menu.js +14 -0
- package/{src → dist}/components/Menu/MenuDesktop.d.ts +1 -1
- package/dist/components/Menu/MenuDesktop.js +68 -0
- package/{src → dist}/components/Menu/MenuItem.d.ts +1 -1
- package/dist/components/Menu/MenuItem.js +33 -0
- package/{src → dist}/components/Menu/MenuMobile.d.ts +1 -1
- package/dist/components/Menu/MenuMobile.js +78 -0
- package/{src → dist}/components/Menu/MenuPopover.d.ts +1 -1
- package/dist/components/Menu/MenuPopover.js +38 -0
- package/{src → dist}/components/buttons/Button/Button.d.ts +1 -1
- package/dist/components/buttons/Button/Button.js +68 -0
- package/{src → dist}/components/buttons/Button/button.cva.d.ts +1 -1
- package/dist/components/buttons/Button/button.cva.js +672 -0
- package/{src → dist}/components/buttons/IconButton/IconButton.d.ts +1 -1
- package/dist/components/buttons/IconButton/IconButton.js +17 -0
- package/{src → dist}/components/buttons/InlineIconButton/InlineIconButton.d.ts +1 -1
- package/dist/components/buttons/InlineIconButton/InlineIconButton.js +18 -0
- package/{src → dist}/components/buttons/PillButton/PillButton.d.ts +2 -2
- package/dist/components/buttons/PillButton/PillButton.js +44 -0
- package/{src → dist}/components/buttons/PillButton/pillButton.cva.d.ts +1 -1
- package/dist/components/buttons/PillButton/pillButton.cva.js +86 -0
- package/{src → dist}/components/buttons/SplitButton/SplitButton.d.ts +2 -2
- package/dist/components/buttons/SplitButton/SplitButton.js +62 -0
- package/{src → dist}/components/buttons/TextButton/TextButton.d.ts +3 -3
- package/dist/components/buttons/TextButton/TextButton.js +18 -0
- package/{src → dist}/components/buttons/ToggleButton/ToggleButton.d.ts +3 -3
- package/dist/components/buttons/ToggleButton/ToggleButton.js +21 -0
- package/{src → dist}/components/buttons/shared/ButtonContent.d.ts +3 -3
- package/dist/components/buttons/shared/ButtonContent.js +53 -0
- package/dist/components/buttons/shared/buttonContent.cva.js +16 -0
- package/{src → dist}/components/inputs/Checkbox/Checkbox.d.ts +3 -3
- package/dist/components/inputs/Checkbox/Checkbox.js +81 -0
- package/{src → dist}/components/inputs/Checkbox/CheckboxCheckmark.d.ts +1 -1
- package/dist/components/inputs/Checkbox/CheckboxCheckmark.js +49 -0
- package/{src → dist}/components/inputs/Checkbox/checkbox.cva.d.ts +1 -1
- package/dist/components/inputs/Checkbox/checkbox.cva.js +47 -0
- package/{src → dist}/components/inputs/DateTime/DatePicker/DatePicker.d.ts +3 -3
- package/dist/components/inputs/DateTime/DatePicker/DatePicker.js +237 -0
- package/{src → dist}/components/inputs/DateTime/DateRangePicker/DateRangePicker.d.ts +3 -3
- package/dist/components/inputs/DateTime/DateRangePicker/DateRangePicker.js +674 -0
- package/{src → dist}/components/inputs/DateTime/DateTimePicker/DateTimePicker.d.ts +3 -3
- package/dist/components/inputs/DateTime/DateTimePicker/DateTimePicker.js +251 -0
- package/{src → dist}/components/inputs/DateTime/TimePicker/TimePicker.d.ts +3 -3
- package/dist/components/inputs/DateTime/TimePicker/TimePicker.js +224 -0
- package/dist/components/inputs/DateTime/shared/Calendar.js +85 -0
- package/dist/components/inputs/DateTime/shared/CalendarCell.js +160 -0
- package/dist/components/inputs/DateTime/shared/CalendarGrid.js +67 -0
- package/{src → dist}/components/inputs/DateTime/shared/CalendarHeader.d.ts +1 -1
- package/dist/components/inputs/DateTime/shared/CalendarHeader.js +89 -0
- package/dist/components/inputs/DateTime/shared/CalendarSelectHeader.js +203 -0
- package/dist/components/inputs/DateTime/shared/DateField.js +62 -0
- package/{src → dist}/components/inputs/DateTime/shared/DatePickerInput.d.ts +2 -2
- package/dist/components/inputs/DateTime/shared/DatePickerInput.js +174 -0
- package/dist/components/inputs/DateTime/shared/DateSegmentItem.js +55 -0
- package/dist/components/inputs/DateTime/shared/DateTimeDialog.js +76 -0
- package/dist/components/inputs/DateTime/shared/DateTimeDialogFooter.js +41 -0
- package/dist/components/inputs/DateTime/shared/MonthPicker.js +82 -0
- package/dist/components/inputs/DateTime/shared/RangeCalendar.js +131 -0
- package/dist/components/inputs/DateTime/shared/TimeField.js +26 -0
- package/dist/components/inputs/DateTime/shared/TimePickerForm.js +186 -0
- package/{src → dist}/components/inputs/DateTime/shared/TimePickerInput.d.ts +2 -2
- package/dist/components/inputs/DateTime/shared/TimePickerInput.js +114 -0
- package/dist/components/inputs/DateTime/shared/YearPicker.js +89 -0
- package/dist/components/inputs/File/FileUpload.js +254 -0
- package/dist/components/inputs/File/FileUploadContainer.js +17 -0
- package/dist/components/inputs/File/InputUpload.js +176 -0
- package/{src → dist}/components/inputs/File/fileUpload.types.d.ts +3 -3
- package/{src → dist}/components/inputs/File/inputUpload.types.d.ts +2 -2
- package/{src → dist}/components/inputs/File/shared/FileCard.d.ts +1 -1
- package/dist/components/inputs/File/shared/FileCard.js +67 -0
- package/{src → dist}/components/inputs/File/shared/FileCardList.d.ts +1 -1
- package/dist/components/inputs/File/shared/FileCardList.js +20 -0
- package/dist/components/inputs/File/shared/FileProgressBar.js +32 -0
- package/{src → dist}/components/inputs/File/shared/FileUploadContent.d.ts +1 -1
- package/dist/components/inputs/File/shared/FileUploadContent.js +92 -0
- package/{src → dist}/components/inputs/File/shared/FileUploadContentEmpty.d.ts +1 -1
- package/dist/components/inputs/File/shared/FileUploadContentEmpty.js +92 -0
- package/{src → dist}/components/inputs/File/shared/FileUploadContentError.d.ts +1 -1
- package/dist/components/inputs/File/shared/FileUploadContentError.js +167 -0
- package/{src → dist}/components/inputs/File/shared/FileUploadContentFilled.d.ts +1 -1
- package/dist/components/inputs/File/shared/FileUploadContentFilled.js +176 -0
- package/{src → dist}/components/inputs/File/shared/FileUploadContentLoading.d.ts +1 -1
- package/dist/components/inputs/File/shared/FileUploadContentLoading.js +128 -0
- package/{src → dist}/components/inputs/File/shared/InputUploadContent.d.ts +1 -1
- package/dist/components/inputs/File/shared/InputUploadContent.js +74 -0
- package/dist/components/inputs/File/shared/InputUploadFilled.js +45 -0
- package/dist/components/inputs/File/shared/fileUpload.cva.js +58 -0
- package/dist/components/inputs/File/shared/inputUploadButton.cva.js +49 -0
- package/{src → dist}/components/inputs/FormField/FormField.d.ts +3 -3
- package/dist/components/inputs/FormField/FormField.js +54 -0
- package/dist/components/inputs/FormField/FormFieldError.js +16 -0
- package/dist/components/inputs/FormField/FormFieldHeader.js +57 -0
- package/dist/components/inputs/FormField/FormFieldHeaderClose.js +20 -0
- package/{src → dist}/components/inputs/FormField/FormFieldLabel.d.ts +2 -2
- package/dist/components/inputs/FormField/FormFieldLabel.js +37 -0
- package/{src → dist}/components/inputs/Input/NumberInput/NumberInput.d.ts +4 -4
- package/dist/components/inputs/Input/NumberInput/NumberInput.js +157 -0
- package/{src → dist}/components/inputs/Input/PasswordInput/PasswordInput.d.ts +2 -2
- package/dist/components/inputs/Input/PasswordInput/PasswordInput.js +26 -0
- package/{src → dist}/components/inputs/Input/TextArea/TextArea.d.ts +3 -3
- package/dist/components/inputs/Input/TextArea/TextArea.js +146 -0
- package/{src → dist}/components/inputs/Input/TextInput/TextInput.d.ts +4 -4
- package/dist/components/inputs/Input/TextInput/TextInput.js +170 -0
- package/{src → dist}/components/inputs/Input/shared/InputContent.d.ts +3 -3
- package/dist/components/inputs/Input/shared/InputContent.js +114 -0
- package/{src → dist}/components/inputs/Inputs/Form.d.ts +2 -2
- package/dist/components/inputs/Inputs/Form.js +68 -0
- package/{src → dist}/components/inputs/Inputs/InputItem.d.ts +16 -16
- package/dist/components/inputs/Inputs/InputItem.js +63 -0
- package/dist/components/inputs/Inputs/Inputs.js +32 -0
- package/{src → dist}/components/inputs/RadioGroup/RadioGroup.d.ts +3 -3
- package/dist/components/inputs/RadioGroup/RadioGroup.js +113 -0
- package/{src → dist}/components/inputs/RadioGroup/radio.cva.d.ts +1 -1
- package/dist/components/inputs/RadioGroup/radio.cva.js +47 -0
- package/{src → dist}/components/inputs/Selection/Autocomplete/Autocomplete.d.ts +3 -3
- package/dist/components/inputs/Selection/Autocomplete/Autocomplete.js +39 -0
- package/{src → dist}/components/inputs/Selection/Autocomplete/QueryAutocomplete.d.ts +3 -3
- package/dist/components/inputs/Selection/Autocomplete/QueryAutocomplete.js +25 -0
- package/{src → dist}/components/inputs/Selection/Select/Select.d.ts +3 -3
- package/dist/components/inputs/Selection/Select/Select.js +32 -0
- package/{src → dist}/components/inputs/Selection/shared/SelectBase.d.ts +3 -3
- package/dist/components/inputs/Selection/shared/SelectBase.js +25 -0
- package/{src → dist}/components/inputs/Selection/shared/SelectDesktop.d.ts +1 -1
- package/dist/components/inputs/Selection/shared/SelectDesktop.js +211 -0
- package/{src → dist}/components/inputs/Selection/shared/SelectInput.d.ts +4 -4
- package/dist/components/inputs/Selection/shared/SelectInput.js +231 -0
- package/{src → dist}/components/inputs/Selection/shared/SelectInputTags.d.ts +2 -2
- package/dist/components/inputs/Selection/shared/SelectInputTags.js +22 -0
- package/{src → dist}/components/inputs/Selection/shared/SelectListBox.d.ts +2 -2
- package/dist/components/inputs/Selection/shared/SelectListBox.js +108 -0
- package/{src → dist}/components/inputs/Selection/shared/SelectListBoxItem.d.ts +2 -2
- package/dist/components/inputs/Selection/shared/SelectListBoxItem.js +78 -0
- package/{src → dist}/components/inputs/Selection/shared/SelectListBoxItemSelectAll.d.ts +1 -1
- package/dist/components/inputs/Selection/shared/SelectListBoxItemSelectAll.js +45 -0
- package/{src → dist}/components/inputs/Selection/shared/SelectListBoxLoadingItem.d.ts +1 -1
- package/dist/components/inputs/Selection/shared/SelectListBoxLoadingItem.js +47 -0
- package/dist/components/inputs/Selection/shared/SelectListBoxSelectionBar.js +42 -0
- package/{src → dist}/components/inputs/Selection/shared/SelectMobile.d.ts +1 -1
- package/dist/components/inputs/Selection/shared/SelectMobile.js +161 -0
- package/{src → dist}/components/inputs/Selection/shared/select.context.d.ts +2 -2
- package/dist/components/inputs/Selection/shared/select.context.js +244 -0
- package/{src → dist}/components/inputs/Selection/shared/select.types.d.ts +1 -1
- package/{src → dist}/components/inputs/Selection/shared/useSelectItems.d.ts +2 -2
- package/dist/components/inputs/Selection/shared/useSelectItems.js +94 -0
- package/{src → dist}/components/inputs/Slider/Slider.d.ts +2 -2
- package/dist/components/inputs/Slider/Slider.js +137 -0
- package/{src → dist}/components/inputs/TextEditor/TextEditor.d.ts +2 -2
- package/dist/components/inputs/TextEditor/TextEditor.js +223 -0
- package/dist/components/inputs/TextEditor/Toolbar/ColorPicker.js +34 -0
- package/dist/components/inputs/TextEditor/Toolbar/ColorPickerDropdown.js +80 -0
- package/{src → dist}/components/inputs/TextEditor/Toolbar/HyperlinkAction.d.ts +1 -1
- package/dist/components/inputs/TextEditor/Toolbar/HyperlinkAction.js +92 -0
- package/{src → dist}/components/inputs/TextEditor/Toolbar/TextAlignSelect.d.ts +1 -1
- package/dist/components/inputs/TextEditor/Toolbar/TextAlignSelect.js +56 -0
- package/{src → dist}/components/inputs/TextEditor/Toolbar/TextColorSelect.d.ts +1 -1
- package/dist/components/inputs/TextEditor/Toolbar/TextColorSelect.js +33 -0
- package/dist/components/inputs/TextEditor/Toolbar/TextEditorToolbar.js +31 -0
- package/{src → dist}/components/inputs/TextEditor/Toolbar/TextHighlightSelect.d.ts +1 -1
- package/dist/components/inputs/TextEditor/Toolbar/TextHighlightSelect.js +37 -0
- package/{src → dist}/components/inputs/TextEditor/Toolbar/TextListActions.d.ts +1 -1
- package/dist/components/inputs/TextEditor/Toolbar/TextListActions.js +51 -0
- package/{src → dist}/components/inputs/TextEditor/Toolbar/TextMarksActions.d.ts +1 -1
- package/dist/components/inputs/TextEditor/Toolbar/TextMarksActions.js +73 -0
- package/{src → dist}/components/inputs/TextEditor/Toolbar/TextStyleSelect.d.ts +1 -1
- package/dist/components/inputs/TextEditor/Toolbar/TextStyleSelect.js +61 -0
- package/dist/components/inputs/TextEditor/textEditor.types.js +40 -0
- package/{src → dist}/components/inputs/Toggle/Toggle.d.ts +3 -3
- package/dist/components/inputs/Toggle/Toggle.js +65 -0
- package/{src → dist}/components/inputs/Toggle/toggle.cva.d.ts +1 -1
- package/dist/components/inputs/Toggle/toggle.cva.js +44 -0
- package/{src → dist}/components/inputs/shared/CheckContent.d.ts +1 -1
- package/dist/components/inputs/shared/CheckContent.js +22 -0
- package/dist/components/inputs/shared/InputClear.js +27 -0
- package/dist/components/inputs/shared/input.cva.js +168 -0
- package/{src → dist}/components/inputs/shared/label.cva.d.ts +1 -1
- package/dist/components/inputs/shared/label.cva.js +133 -0
- package/dist/components/outline.clsx.js +11 -0
- package/{src → dist}/components/overlays/ActionModal/ActionModal.d.ts +2 -2
- package/dist/components/overlays/ActionModal/ActionModal.js +80 -0
- package/dist/components/overlays/BottomSheet/BottomSheet.js +261 -0
- package/dist/components/overlays/Drawer/Drawer.js +84 -0
- package/{src → dist}/components/overlays/Modal/Modal.d.ts +1 -1
- package/dist/components/overlays/Modal/Modal.js +53 -0
- package/dist/components/overlays/Modal/modal.cva.js +53 -0
- package/dist/components/overlays/ResponsivePopover/ResponsivePopover.js +71 -0
- package/{src → dist}/components/overlays/Tooltip/Tooltip.d.ts +1 -1
- package/dist/components/overlays/Tooltip/Tooltip.js +70 -0
- package/dist/components/overlays/Tooltip/TooltipEllipsis.js +27 -0
- package/dist/components/overlays/Tooltip/tooltip.cva.js +60 -0
- package/dist/components/segment/Segment.js +119 -0
- package/dist/components/segment/SegmentItem.js +43 -0
- package/{src → dist}/components/segment/segment.types.d.ts +1 -1
- package/dist/components/shared/pagination/Pagination.js +75 -0
- package/{src → dist}/components/shared/pagination/PaginationList.d.ts +1 -1
- package/dist/components/shared/pagination/PaginationList.js +145 -0
- package/dist/components/shared/pagination/minWidth.cva.js +15 -0
- package/{src → dist}/components/status/Alert/Alert.d.ts +1 -1
- package/dist/components/status/Alert/Alert.js +41 -0
- package/dist/components/status/Alert/alert.cva.js +64 -0
- package/{src → dist}/components/status/Loader/Loader.d.ts +1 -1
- package/dist/components/status/Loader/Loader.js +37 -0
- package/dist/components/status/Loader/loader.cva.js +27 -0
- package/{src → dist}/components/status/Toast/Toast.d.ts +1 -1
- package/dist/components/status/Toast/Toast.js +64 -0
- package/{src → dist}/components/status/Toast/toast.cva.d.ts +1 -1
- package/dist/components/status/Toast/toast.cva.js +150 -0
- package/dist/components/status/Toast/useToast.js +83 -0
- package/dist/components/status/shared/status.cva.js +62 -0
- package/dist/components/table/CellText.js +18 -0
- package/dist/components/table/ColumnConfig.js +124 -0
- package/dist/components/table/HeaderText.js +15 -0
- package/dist/components/table/InfiniteTable.js +40 -0
- package/dist/components/table/PaginatedTable.js +33 -0
- package/dist/components/table/Table.js +370 -0
- package/dist/components/table/table.cva.js +63 -0
- package/{src → dist}/components/text/Link/Link.d.ts +1 -1
- package/dist/components/text/Link/Link.js +18 -0
- package/dist/components/text/Link/link.cva.js +18 -0
- package/{src → dist}/components/text/Tag/Tag.d.ts +1 -1
- package/dist/components/text/Tag/Tag.js +49 -0
- package/dist/components/text/Tag/tag.cva.js +59 -0
- package/{src → dist}/components/text/Typography/Typography.d.ts +1 -1
- package/dist/components/text/Typography/Typography.js +22 -0
- package/dist/components/text/Typography/typography.cva.js +100 -0
- package/{src → dist}/config/confirmation.context.d.ts +1 -1
- package/dist/config/confirmation.context.js +107 -0
- package/dist/config/i18n.js +15 -0
- package/dist/config/router.context.js +43 -0
- package/{src → dist}/config/uiConfig.context.d.ts +8 -8
- package/dist/config/uiConfig.context.js +67 -0
- package/{src → dist}/config/uiStyle.context.d.ts +14 -14
- package/dist/config/uiStyle.context.js +16 -0
- package/dist/helpers/dynamicColumns.js +359 -0
- package/{src → dist}/helpers/dynamicInputs.d.ts +2 -2
- package/dist/helpers/dynamicInputs.js +216 -0
- package/dist/hooks/useAutosave.js +83 -0
- package/dist/hooks/useBreakpoint.js +20 -0
- package/dist/hooks/useDebounceCallback.js +29 -0
- package/dist/hooks/useDeepCompare.js +25 -0
- package/dist/hooks/useFilters.js +120 -0
- package/dist/hooks/useForm.js +22 -0
- package/{src → dist}/hooks/useFormAutosave.d.ts +2 -2
- package/dist/hooks/useFormAutosave.js +67 -0
- package/dist/hooks/useIntersectionObserver.js +27 -0
- package/dist/hooks/useLocalStorage.js +63 -0
- package/dist/hooks/useLongPressRepeat.js +33 -0
- package/dist/hooks/usePagination.js +35 -0
- package/dist/hooks/useScrollableListBox.js +30 -0
- package/dist/hooks/useSorting.js +30 -0
- package/dist/hooks/useStateAndRef.js +17 -0
- package/dist/hooks/useTableColumnConfig.js +63 -0
- package/dist/hooks/useTableNav.js +409 -0
- package/dist/hooks/useTranslationMemo.js +14 -0
- package/dist/index.js +284 -0
- package/{src → dist}/types/react-query.d.ts +1 -1
- package/dist/utils/array.utils.js +12 -0
- package/dist/utils/compoundMapper.js +14 -0
- package/dist/utils/date-time.utils.js +77 -0
- package/dist/utils/date.utils.js +12 -0
- package/dist/utils/dom.utils.js +13 -0
- package/dist/utils/file.utils.js +63 -0
- package/dist/utils/isEqual.js +95 -0
- package/dist/utils/logger.js +19 -0
- package/dist/utils/object.utils.js +53 -0
- package/dist/utils/queries.utils.js +9 -0
- package/dist/utils/rest.utils.js +51 -0
- package/dist/utils/routing.utils.js +15 -0
- package/dist/utils/string.utils.js +12 -0
- package/{src → dist}/utils/vendor/acl/AclGuard.d.ts +1 -1
- package/dist/utils/vendor/acl/AclGuard.js +15 -0
- package/dist/utils/vendor/acl/Can.js +18 -0
- package/dist/utils/vendor/acl/ability.context.js +37 -0
- package/dist/utils/vendor/auth/AuthGuard.js +26 -0
- package/dist/utils/vendor/auth/auth.context.js +36 -0
- package/{src → dist}/utils/vendor/auth/withPrivateAuthGuard.d.ts +1 -1
- package/dist/utils/vendor/auth/withPrivateAuthGuard.js +17 -0
- package/dist/utils/vendor/error-handling.js +119 -0
- package/dist/utils/vendor/rest-interceptor.js +21 -0
- package/dist/utils/zod.utils.js +25 -0
- package/package.json +57 -5
- package/index.js +0 -62585
- package/povio-ui-0.0.8.tgz +0 -0
- package/vite.config.d.ts +0 -2
- /package/{src → dist}/assets/icons/AlignCenter.d.ts +0 -0
- /package/{src → dist}/assets/icons/AlignLeft.d.ts +0 -0
- /package/{src → dist}/assets/icons/AlignLeftRight.d.ts +0 -0
- /package/{src → dist}/assets/icons/AlignRight.d.ts +0 -0
- /package/{src → dist}/assets/icons/ArrowDropDown.d.ts +0 -0
- /package/{src → dist}/assets/icons/ArrowDropUp.d.ts +0 -0
- /package/{src → dist}/assets/icons/ArrowLeft.d.ts +0 -0
- /package/{src → dist}/assets/icons/ArrowRight.d.ts +0 -0
- /package/{src → dist}/assets/icons/Bold.d.ts +0 -0
- /package/{src → dist}/assets/icons/BulletedList.d.ts +0 -0
- /package/{src → dist}/assets/icons/Calendar.d.ts +0 -0
- /package/{src → dist}/assets/icons/Check.d.ts +0 -0
- /package/{src → dist}/assets/icons/CheckCircle.d.ts +0 -0
- /package/{src → dist}/assets/icons/CheckboxCheckmark.d.ts +0 -0
- /package/{src → dist}/assets/icons/CheckboxIndeterminate.d.ts +0 -0
- /package/{src → dist}/assets/icons/ChevronDown.d.ts +0 -0
- /package/{src → dist}/assets/icons/ChevronLeft.d.ts +0 -0
- /package/{src → dist}/assets/icons/ChevronRight.d.ts +0 -0
- /package/{src → dist}/assets/icons/ChevronUp.d.ts +0 -0
- /package/{src → dist}/assets/icons/ChevronsLeft.d.ts +0 -0
- /package/{src → dist}/assets/icons/ChevronsRight.d.ts +0 -0
- /package/{src → dist}/assets/icons/Clock.d.ts +0 -0
- /package/{src → dist}/assets/icons/Close.d.ts +0 -0
- /package/{src → dist}/assets/icons/DateTime.d.ts +0 -0
- /package/{src → dist}/assets/icons/Drag.d.ts +0 -0
- /package/{src → dist}/assets/icons/File.d.ts +0 -0
- /package/{src → dist}/assets/icons/Highlight.d.ts +0 -0
- /package/{src → dist}/assets/icons/HighlightOn.d.ts +0 -0
- /package/{src → dist}/assets/icons/Info.d.ts +0 -0
- /package/{src → dist}/assets/icons/Italic.d.ts +0 -0
- /package/{src → dist}/assets/icons/Link.d.ts +0 -0
- /package/{src → dist}/assets/icons/Menu.d.ts +0 -0
- /package/{src → dist}/assets/icons/NumberedList.d.ts +0 -0
- /package/{src → dist}/assets/icons/PointerHorizontal.d.ts +0 -0
- /package/{src → dist}/assets/icons/PointerVertical.d.ts +0 -0
- /package/{src → dist}/assets/icons/Send.d.ts +0 -0
- /package/{src → dist}/assets/icons/Strikethrough.d.ts +0 -0
- /package/{src → dist}/assets/icons/TextColor.d.ts +0 -0
- /package/{src → dist}/assets/icons/Today.d.ts +0 -0
- /package/{src → dist}/assets/icons/Underlined.d.ts +0 -0
- /package/{src → dist}/assets/icons/Upload.d.ts +0 -0
- /package/{src → dist}/assets/icons/View.d.ts +0 -0
- /package/{src → dist}/assets/icons/ViewOff.d.ts +0 -0
- /package/{src → dist}/assets/icons/WarningFilled.d.ts +0 -0
- /package/{src → dist}/components/Menu/Menu.d.ts +0 -0
- /package/{src → dist}/components/buttons/shared/buttonContent.cva.d.ts +0 -0
- /package/{src → dist}/components/inputs/DateTime/shared/Calendar.d.ts +0 -0
- /package/{src → dist}/components/inputs/DateTime/shared/CalendarCell.d.ts +0 -0
- /package/{src → dist}/components/inputs/DateTime/shared/CalendarGrid.d.ts +0 -0
- /package/{src → dist}/components/inputs/DateTime/shared/CalendarSelectHeader.d.ts +0 -0
- /package/{src → dist}/components/inputs/DateTime/shared/DateField.d.ts +0 -0
- /package/{src → dist}/components/inputs/DateTime/shared/DateSegmentItem.d.ts +0 -0
- /package/{src → dist}/components/inputs/DateTime/shared/DateTimeDialog.d.ts +0 -0
- /package/{src → dist}/components/inputs/DateTime/shared/DateTimeDialogFooter.d.ts +0 -0
- /package/{src → dist}/components/inputs/DateTime/shared/MonthPicker.d.ts +0 -0
- /package/{src → dist}/components/inputs/DateTime/shared/RangeCalendar.d.ts +0 -0
- /package/{src → dist}/components/inputs/DateTime/shared/TimeField.d.ts +0 -0
- /package/{src → dist}/components/inputs/DateTime/shared/TimePickerForm.d.ts +0 -0
- /package/{src → dist}/components/inputs/DateTime/shared/YearPicker.d.ts +0 -0
- /package/{src → dist}/components/inputs/File/FileUpload.d.ts +0 -0
- /package/{src → dist}/components/inputs/File/FileUploadContainer.d.ts +0 -0
- /package/{src → dist}/components/inputs/File/InputUpload.d.ts +0 -0
- /package/{src → dist}/components/inputs/File/index.d.ts +0 -0
- /package/{src → dist}/components/inputs/File/shared/FileProgressBar.d.ts +0 -0
- /package/{src → dist}/components/inputs/File/shared/InputUploadFilled.d.ts +0 -0
- /package/{src → dist}/components/inputs/File/shared/fileUpload.cva.d.ts +0 -0
- /package/{src → dist}/components/inputs/File/shared/inputUploadButton.cva.d.ts +0 -0
- /package/{src → dist}/components/inputs/FormField/FormFieldError.d.ts +0 -0
- /package/{src → dist}/components/inputs/FormField/FormFieldHeader.d.ts +0 -0
- /package/{src → dist}/components/inputs/FormField/FormFieldHeaderClose.d.ts +0 -0
- /package/{src → dist}/components/inputs/Inputs/Inputs.d.ts +0 -0
- /package/{src → dist}/components/inputs/Selection/shared/SelectListBoxSelectionBar.d.ts +0 -0
- /package/{src → dist}/components/inputs/TextEditor/Toolbar/ColorPicker.d.ts +0 -0
- /package/{src → dist}/components/inputs/TextEditor/Toolbar/ColorPickerDropdown.d.ts +0 -0
- /package/{src → dist}/components/inputs/TextEditor/Toolbar/TextEditorToolbar.d.ts +0 -0
- /package/{src → dist}/components/inputs/TextEditor/textEditor.types.d.ts +0 -0
- /package/{src → dist}/components/inputs/shared/InputClear.d.ts +0 -0
- /package/{src → dist}/components/inputs/shared/form.types.d.ts +0 -0
- /package/{src → dist}/components/inputs/shared/input.cva.d.ts +0 -0
- /package/{src → dist}/components/outline.clsx.d.ts +0 -0
- /package/{src → dist}/components/overlays/BottomSheet/BottomSheet.d.ts +0 -0
- /package/{src → dist}/components/overlays/Drawer/Drawer.d.ts +0 -0
- /package/{src → dist}/components/overlays/Modal/modal.cva.d.ts +0 -0
- /package/{src → dist}/components/overlays/ResponsivePopover/ResponsivePopover.d.ts +0 -0
- /package/{src → dist}/components/overlays/Tooltip/TooltipEllipsis.d.ts +0 -0
- /package/{src → dist}/components/overlays/Tooltip/tooltip.cva.d.ts +0 -0
- /package/{src → dist}/components/segment/Segment.d.ts +0 -0
- /package/{src → dist}/components/segment/SegmentItem.d.ts +0 -0
- /package/{src → dist}/components/shared/pagination/Pagination.d.ts +0 -0
- /package/{src → dist}/components/shared/pagination/minWidth.cva.d.ts +0 -0
- /package/{src → dist}/components/status/Alert/alert.cva.d.ts +0 -0
- /package/{src → dist}/components/status/Loader/loader.cva.d.ts +0 -0
- /package/{src → dist}/components/status/Toast/useToast.d.ts +0 -0
- /package/{src → dist}/components/status/shared/status.cva.d.ts +0 -0
- /package/{src → dist}/components/table/CellText.d.ts +0 -0
- /package/{src → dist}/components/table/ColumnConfig.d.ts +0 -0
- /package/{src → dist}/components/table/HeaderText.d.ts +0 -0
- /package/{src → dist}/components/table/InfiniteTable.d.ts +0 -0
- /package/{src → dist}/components/table/PaginatedTable.d.ts +0 -0
- /package/{src → dist}/components/table/Table.d.ts +0 -0
- /package/{src → dist}/components/table/table.cva.d.ts +0 -0
- /package/{src → dist}/components/text/Link/link.cva.d.ts +0 -0
- /package/{src → dist}/components/text/Tag/tag.cva.d.ts +0 -0
- /package/{src → dist}/components/text/Typography/typography.cva.d.ts +0 -0
- /package/{src → dist}/config/i18n.d.ts +0 -0
- /package/{src → dist}/config/router.context.d.ts +0 -0
- /package/{src → dist}/helpers/dynamicColumns.d.ts +0 -0
- /package/{src → dist}/hooks/useAutosave.d.ts +0 -0
- /package/{src → dist}/hooks/useBreakpoint.d.ts +0 -0
- /package/{src → dist}/hooks/useDebounceCallback.d.ts +0 -0
- /package/{src → dist}/hooks/useDeepCompare.d.ts +0 -0
- /package/{src → dist}/hooks/useFilters.d.ts +0 -0
- /package/{src → dist}/hooks/useForm.d.ts +0 -0
- /package/{src → dist}/hooks/useIntersectionObserver.d.ts +0 -0
- /package/{src → dist}/hooks/useLocalStorage.d.ts +0 -0
- /package/{src → dist}/hooks/useLongPressRepeat.d.ts +0 -0
- /package/{src → dist}/hooks/usePagination.d.ts +0 -0
- /package/{src → dist}/hooks/useScrollableListBox.d.ts +0 -0
- /package/{src → dist}/hooks/useSorting.d.ts +0 -0
- /package/{src → dist}/hooks/useStateAndRef.d.ts +0 -0
- /package/{src → dist}/hooks/useTableColumnConfig.d.ts +0 -0
- /package/{src → dist}/hooks/useTableNav.d.ts +0 -0
- /package/{src → dist}/hooks/useTranslationMemo.d.ts +0 -0
- /package/{src → dist}/index.d.ts +0 -0
- /package/{styles → dist/styles}/editor.css +0 -0
- /package/{styles → dist/styles}/index.css +0 -0
- /package/{src → dist}/types/common.d.ts +0 -0
- /package/{src → dist}/utils/array.utils.d.ts +0 -0
- /package/{src → dist}/utils/array.utils.spec.d.ts +0 -0
- /package/{src → dist}/utils/compoundMapper.d.ts +0 -0
- /package/{src → dist}/utils/compoundMapper.spec.d.ts +0 -0
- /package/{src → dist}/utils/date-time.utils.d.ts +0 -0
- /package/{src → dist}/utils/date-time.utils.spec.d.ts +0 -0
- /package/{src → dist}/utils/date.utils.d.ts +0 -0
- /package/{src → dist}/utils/date.utils.spec.d.ts +0 -0
- /package/{src → dist}/utils/dom.utils.d.ts +0 -0
- /package/{src → dist}/utils/file.utils.d.ts +0 -0
- /package/{src → dist}/utils/isEqual.d.ts +0 -0
- /package/{src → dist}/utils/logger.d.ts +0 -0
- /package/{src → dist}/utils/object.utils.d.ts +0 -0
- /package/{src → dist}/utils/queries.utils.d.ts +0 -0
- /package/{src → dist}/utils/rest.utils.d.ts +0 -0
- /package/{src → dist}/utils/routing.utils.d.ts +0 -0
- /package/{src → dist}/utils/string.utils.d.ts +0 -0
- /package/{src → dist}/utils/vendor/acl/Can.d.ts +0 -0
- /package/{src → dist}/utils/vendor/acl/ability.context.d.ts +0 -0
- /package/{src → dist}/utils/vendor/acl/appAbility.types.d.ts +0 -0
- /package/{src → dist}/utils/vendor/auth/AuthGuard.d.ts +0 -0
- /package/{src → dist}/utils/vendor/auth/auth.context.d.ts +0 -0
- /package/{src → dist}/utils/vendor/error-handling.d.ts +0 -0
- /package/{src → dist}/utils/vendor/rest-client.types.d.ts +0 -0
- /package/{src → dist}/utils/vendor/rest-interceptor.d.ts +0 -0
- /package/{src → dist}/utils/zod.utils.d.ts +0 -0
package/dist/index.js
ADDED
|
@@ -0,0 +1,284 @@
|
|
|
1
|
+
import { AlignCenterIcon } from "./assets/icons/AlignCenter.js";
|
|
2
|
+
import { AlignLeftIcon } from "./assets/icons/AlignLeft.js";
|
|
3
|
+
import { AlignLeftRightIcon } from "./assets/icons/AlignLeftRight.js";
|
|
4
|
+
import { AlignRightIcon } from "./assets/icons/AlignRight.js";
|
|
5
|
+
import { ArrowDropDownIcon } from "./assets/icons/ArrowDropDown.js";
|
|
6
|
+
import { ArrowDropUpIcon } from "./assets/icons/ArrowDropUp.js";
|
|
7
|
+
import { ArrowLeftIcon } from "./assets/icons/ArrowLeft.js";
|
|
8
|
+
import { ArrowRightIcon } from "./assets/icons/ArrowRight.js";
|
|
9
|
+
import { BoldIcon } from "./assets/icons/Bold.js";
|
|
10
|
+
import { BulletedListIcon } from "./assets/icons/BulletedList.js";
|
|
11
|
+
import { CalendarIcon } from "./assets/icons/Calendar.js";
|
|
12
|
+
import { CheckIcon } from "./assets/icons/Check.js";
|
|
13
|
+
import { CheckboxCheckmarkIcon } from "./assets/icons/CheckboxCheckmark.js";
|
|
14
|
+
import { CheckboxIndeterminateIcon } from "./assets/icons/CheckboxIndeterminate.js";
|
|
15
|
+
import { ChevronDownIcon } from "./assets/icons/ChevronDown.js";
|
|
16
|
+
import { ChevronLeftIcon } from "./assets/icons/ChevronLeft.js";
|
|
17
|
+
import { ChevronRightIcon } from "./assets/icons/ChevronRight.js";
|
|
18
|
+
import { ChevronsLeftIcon } from "./assets/icons/ChevronsLeft.js";
|
|
19
|
+
import { ChevronsRightIcon } from "./assets/icons/ChevronsRight.js";
|
|
20
|
+
import { ChevronUpIcon } from "./assets/icons/ChevronUp.js";
|
|
21
|
+
import { ClockIcon } from "./assets/icons/Clock.js";
|
|
22
|
+
import { CloseIcon } from "./assets/icons/Close.js";
|
|
23
|
+
import { DateTimeIcon } from "./assets/icons/DateTime.js";
|
|
24
|
+
import { HighlightIcon } from "./assets/icons/Highlight.js";
|
|
25
|
+
import { HighlightOnIcon } from "./assets/icons/HighlightOn.js";
|
|
26
|
+
import { InfoIcon } from "./assets/icons/Info.js";
|
|
27
|
+
import { ItalicIcon } from "./assets/icons/Italic.js";
|
|
28
|
+
import { LinkIcon } from "./assets/icons/Link.js";
|
|
29
|
+
import { MenuIcon } from "./assets/icons/Menu.js";
|
|
30
|
+
import { NumberedListIcon } from "./assets/icons/NumberedList.js";
|
|
31
|
+
import { PointerHorizontalIcon } from "./assets/icons/PointerHorizontal.js";
|
|
32
|
+
import { PointerVerticalIcon } from "./assets/icons/PointerVertical.js";
|
|
33
|
+
import { SendIcon } from "./assets/icons/Send.js";
|
|
34
|
+
import { StrikethroughIcon } from "./assets/icons/Strikethrough.js";
|
|
35
|
+
import { TextColorIcon } from "./assets/icons/TextColor.js";
|
|
36
|
+
import { UnderlinedIcon } from "./assets/icons/Underlined.js";
|
|
37
|
+
import { ViewIcon } from "./assets/icons/View.js";
|
|
38
|
+
import { ViewOffIcon } from "./assets/icons/ViewOff.js";
|
|
39
|
+
import { Button } from "./components/buttons/Button/Button.js";
|
|
40
|
+
import { IconButton } from "./components/buttons/IconButton/IconButton.js";
|
|
41
|
+
import { InlineIconButton } from "./components/buttons/InlineIconButton/InlineIconButton.js";
|
|
42
|
+
import { PillButton } from "./components/buttons/PillButton/PillButton.js";
|
|
43
|
+
import { SplitButton } from "./components/buttons/SplitButton/SplitButton.js";
|
|
44
|
+
import { TextButton } from "./components/buttons/TextButton/TextButton.js";
|
|
45
|
+
import { ToggleButton } from "./components/buttons/ToggleButton/ToggleButton.js";
|
|
46
|
+
import { Checkbox } from "./components/inputs/Checkbox/Checkbox.js";
|
|
47
|
+
import { DatePicker } from "./components/inputs/DateTime/DatePicker/DatePicker.js";
|
|
48
|
+
import { DateRangePicker } from "./components/inputs/DateTime/DateRangePicker/DateRangePicker.js";
|
|
49
|
+
import { DateTimePicker } from "./components/inputs/DateTime/DateTimePicker/DateTimePicker.js";
|
|
50
|
+
import { TimePicker } from "./components/inputs/DateTime/TimePicker/TimePicker.js";
|
|
51
|
+
import { FileUpload } from "./components/inputs/File/FileUpload.js";
|
|
52
|
+
import { FileUploadContainer } from "./components/inputs/File/FileUploadContainer.js";
|
|
53
|
+
import { InputUpload } from "./components/inputs/File/InputUpload.js";
|
|
54
|
+
import { FormField } from "./components/inputs/FormField/FormField.js";
|
|
55
|
+
import { NumberInput } from "./components/inputs/Input/NumberInput/NumberInput.js";
|
|
56
|
+
import { PasswordInput } from "./components/inputs/Input/PasswordInput/PasswordInput.js";
|
|
57
|
+
import { TextArea } from "./components/inputs/Input/TextArea/TextArea.js";
|
|
58
|
+
import { TextInput } from "./components/inputs/Input/TextInput/TextInput.js";
|
|
59
|
+
import { Form } from "./components/inputs/Inputs/Form.js";
|
|
60
|
+
import { Inputs } from "./components/inputs/Inputs/Inputs.js";
|
|
61
|
+
import { RadioGroup } from "./components/inputs/RadioGroup/RadioGroup.js";
|
|
62
|
+
import { Autocomplete } from "./components/inputs/Selection/Autocomplete/Autocomplete.js";
|
|
63
|
+
import { QueryAutocomplete } from "./components/inputs/Selection/Autocomplete/QueryAutocomplete.js";
|
|
64
|
+
import { Select } from "./components/inputs/Selection/Select/Select.js";
|
|
65
|
+
import { Slider } from "./components/inputs/Slider/Slider.js";
|
|
66
|
+
import { TextEditor } from "./components/inputs/TextEditor/TextEditor.js";
|
|
67
|
+
import { Toggle } from "./components/inputs/Toggle/Toggle.js";
|
|
68
|
+
import { Menu } from "./components/Menu/Menu.js";
|
|
69
|
+
import { MenuPopover } from "./components/Menu/MenuPopover.js";
|
|
70
|
+
import { uiOutlineClass } from "./components/outline.clsx.js";
|
|
71
|
+
import { ActionModal } from "./components/overlays/ActionModal/ActionModal.js";
|
|
72
|
+
import { BottomSheet } from "./components/overlays/BottomSheet/BottomSheet.js";
|
|
73
|
+
import { Drawer } from "./components/overlays/Drawer/Drawer.js";
|
|
74
|
+
import { Modal } from "./components/overlays/Modal/Modal.js";
|
|
75
|
+
import { ResponsivePopover } from "./components/overlays/ResponsivePopover/ResponsivePopover.js";
|
|
76
|
+
import { Tooltip } from "./components/overlays/Tooltip/Tooltip.js";
|
|
77
|
+
import { TooltipEllipsis } from "./components/overlays/Tooltip/TooltipEllipsis.js";
|
|
78
|
+
import { Segment } from "./components/segment/Segment.js";
|
|
79
|
+
import { Pagination } from "./components/shared/pagination/Pagination.js";
|
|
80
|
+
import { PaginationList } from "./components/shared/pagination/PaginationList.js";
|
|
81
|
+
import { Alert } from "./components/status/Alert/Alert.js";
|
|
82
|
+
import { Loader } from "./components/status/Loader/Loader.js";
|
|
83
|
+
import { Toast, ToastContainer } from "./components/status/Toast/Toast.js";
|
|
84
|
+
import { useToast } from "./components/status/Toast/useToast.js";
|
|
85
|
+
import { CellText } from "./components/table/CellText.js";
|
|
86
|
+
import { ColumnConfigModal } from "./components/table/ColumnConfig.js";
|
|
87
|
+
import { HeaderText } from "./components/table/HeaderText.js";
|
|
88
|
+
import { InfiniteTable } from "./components/table/InfiniteTable.js";
|
|
89
|
+
import { PaginatedTable } from "./components/table/PaginatedTable.js";
|
|
90
|
+
import { Table } from "./components/table/Table.js";
|
|
91
|
+
import { Link } from "./components/text/Link/Link.js";
|
|
92
|
+
import { Tag } from "./components/text/Tag/Tag.js";
|
|
93
|
+
import { Typography } from "./components/text/Typography/Typography.js";
|
|
94
|
+
import { Confirmation } from "./config/confirmation.context.js";
|
|
95
|
+
import { ns, resources } from "./config/i18n.js";
|
|
96
|
+
import { UIRouter } from "./config/router.context.js";
|
|
97
|
+
import { UIConfig } from "./config/uiConfig.context.js";
|
|
98
|
+
import { UIStyle } from "./config/uiStyle.context.js";
|
|
99
|
+
import { dynamicColumns } from "./helpers/dynamicColumns.js";
|
|
100
|
+
import { dynamicInputs } from "./helpers/dynamicInputs.js";
|
|
101
|
+
import { useAutosave } from "./hooks/useAutosave.js";
|
|
102
|
+
import { useBreakpoint } from "./hooks/useBreakpoint.js";
|
|
103
|
+
import { useDebounceCallback } from "./hooks/useDebounceCallback.js";
|
|
104
|
+
import { useDeepCompareEffect, useDeepCompareLayoutEffect, useDeepCompareMemo } from "./hooks/useDeepCompare.js";
|
|
105
|
+
import { useFilters } from "./hooks/useFilters.js";
|
|
106
|
+
import { useForm } from "./hooks/useForm.js";
|
|
107
|
+
import { useFormAutosave } from "./hooks/useFormAutosave.js";
|
|
108
|
+
import { useIntersectionObserver } from "./hooks/useIntersectionObserver.js";
|
|
109
|
+
import { useLocalStorage } from "./hooks/useLocalStorage.js";
|
|
110
|
+
import { useLongPressRepeat } from "./hooks/useLongPressRepeat.js";
|
|
111
|
+
import { usePagination } from "./hooks/usePagination.js";
|
|
112
|
+
import { useScrollableListBox } from "./hooks/useScrollableListBox.js";
|
|
113
|
+
import { useSorting } from "./hooks/useSorting.js";
|
|
114
|
+
import { useStateAndRef } from "./hooks/useStateAndRef.js";
|
|
115
|
+
import { useTableColumnConfig } from "./hooks/useTableColumnConfig.js";
|
|
116
|
+
import { useTableNav } from "./hooks/useTableNav.js";
|
|
117
|
+
import { useTranslationMemo } from "./hooks/useTranslationMemo.js";
|
|
118
|
+
import { ArrayUtils } from "./utils/array.utils.js";
|
|
119
|
+
import { compoundMapper } from "./utils/compoundMapper.js";
|
|
120
|
+
import { DateUtils } from "./utils/date.utils.js";
|
|
121
|
+
import { DateTimeUtils } from "./utils/date-time.utils.js";
|
|
122
|
+
import { DomUtils } from "./utils/dom.utils.js";
|
|
123
|
+
import { FileUtils } from "./utils/file.utils.js";
|
|
124
|
+
import { isEqual } from "./utils/isEqual.js";
|
|
125
|
+
import { logger } from "./utils/logger.js";
|
|
126
|
+
import { ObjectUtils } from "./utils/object.utils.js";
|
|
127
|
+
import { QueriesUtils } from "./utils/queries.utils.js";
|
|
128
|
+
import { RestUtils } from "./utils/rest.utils.js";
|
|
129
|
+
import { RoutingUtils } from "./utils/routing.utils.js";
|
|
130
|
+
import { StringUtils } from "./utils/string.utils.js";
|
|
131
|
+
import { createAclGuard } from "./utils/vendor/acl/AclGuard.js";
|
|
132
|
+
import { AbilityContext } from "./utils/vendor/acl/ability.context.js";
|
|
133
|
+
import { Can } from "./utils/vendor/acl/Can.js";
|
|
134
|
+
import { AuthGuard } from "./utils/vendor/auth/AuthGuard.js";
|
|
135
|
+
import { AuthContext } from "./utils/vendor/auth/auth.context.js";
|
|
136
|
+
import { withPrivateAuthGuard } from "./utils/vendor/auth/withPrivateAuthGuard.js";
|
|
137
|
+
import { ApplicationException, ErrorHandler, SharedErrorHandler } from "./utils/vendor/error-handling.js";
|
|
138
|
+
import { RestInterceptor } from "./utils/vendor/rest-interceptor.js";
|
|
139
|
+
export {
|
|
140
|
+
AbilityContext,
|
|
141
|
+
ActionModal,
|
|
142
|
+
Alert,
|
|
143
|
+
AlignCenterIcon,
|
|
144
|
+
AlignLeftIcon,
|
|
145
|
+
AlignLeftRightIcon,
|
|
146
|
+
AlignRightIcon,
|
|
147
|
+
ApplicationException,
|
|
148
|
+
ArrayUtils,
|
|
149
|
+
ArrowDropDownIcon,
|
|
150
|
+
ArrowDropUpIcon,
|
|
151
|
+
ArrowLeftIcon,
|
|
152
|
+
ArrowRightIcon,
|
|
153
|
+
AuthContext,
|
|
154
|
+
AuthGuard,
|
|
155
|
+
Autocomplete,
|
|
156
|
+
BoldIcon,
|
|
157
|
+
BottomSheet,
|
|
158
|
+
BulletedListIcon,
|
|
159
|
+
Button,
|
|
160
|
+
CalendarIcon,
|
|
161
|
+
Can,
|
|
162
|
+
CellText,
|
|
163
|
+
CheckIcon,
|
|
164
|
+
Checkbox,
|
|
165
|
+
CheckboxCheckmarkIcon,
|
|
166
|
+
CheckboxIndeterminateIcon,
|
|
167
|
+
ChevronDownIcon,
|
|
168
|
+
ChevronLeftIcon,
|
|
169
|
+
ChevronRightIcon,
|
|
170
|
+
ChevronUpIcon,
|
|
171
|
+
ChevronsLeftIcon,
|
|
172
|
+
ChevronsRightIcon,
|
|
173
|
+
ClockIcon,
|
|
174
|
+
CloseIcon,
|
|
175
|
+
ColumnConfigModal,
|
|
176
|
+
Confirmation,
|
|
177
|
+
DatePicker,
|
|
178
|
+
DateRangePicker,
|
|
179
|
+
DateTimeIcon,
|
|
180
|
+
DateTimePicker,
|
|
181
|
+
DateTimeUtils,
|
|
182
|
+
DateUtils,
|
|
183
|
+
DomUtils,
|
|
184
|
+
Drawer,
|
|
185
|
+
ErrorHandler,
|
|
186
|
+
FileUpload,
|
|
187
|
+
FileUploadContainer,
|
|
188
|
+
FileUtils,
|
|
189
|
+
Form,
|
|
190
|
+
FormField,
|
|
191
|
+
HeaderText,
|
|
192
|
+
HighlightIcon,
|
|
193
|
+
HighlightOnIcon,
|
|
194
|
+
IconButton,
|
|
195
|
+
InfiniteTable,
|
|
196
|
+
InfoIcon,
|
|
197
|
+
InlineIconButton,
|
|
198
|
+
InputUpload,
|
|
199
|
+
Inputs,
|
|
200
|
+
ItalicIcon,
|
|
201
|
+
Link,
|
|
202
|
+
LinkIcon,
|
|
203
|
+
Loader,
|
|
204
|
+
Menu,
|
|
205
|
+
MenuIcon,
|
|
206
|
+
MenuPopover,
|
|
207
|
+
Modal,
|
|
208
|
+
NumberInput,
|
|
209
|
+
NumberedListIcon,
|
|
210
|
+
ObjectUtils,
|
|
211
|
+
PaginatedTable,
|
|
212
|
+
Pagination,
|
|
213
|
+
PaginationList,
|
|
214
|
+
PasswordInput,
|
|
215
|
+
PillButton,
|
|
216
|
+
PointerHorizontalIcon,
|
|
217
|
+
PointerVerticalIcon,
|
|
218
|
+
QueriesUtils,
|
|
219
|
+
QueryAutocomplete,
|
|
220
|
+
RadioGroup,
|
|
221
|
+
ResponsivePopover,
|
|
222
|
+
RestInterceptor,
|
|
223
|
+
RestUtils,
|
|
224
|
+
RoutingUtils,
|
|
225
|
+
Segment,
|
|
226
|
+
Select,
|
|
227
|
+
SendIcon,
|
|
228
|
+
SharedErrorHandler,
|
|
229
|
+
Slider,
|
|
230
|
+
SplitButton,
|
|
231
|
+
StrikethroughIcon,
|
|
232
|
+
StringUtils,
|
|
233
|
+
Table,
|
|
234
|
+
Tag,
|
|
235
|
+
TextArea,
|
|
236
|
+
TextButton,
|
|
237
|
+
TextColorIcon,
|
|
238
|
+
TextEditor,
|
|
239
|
+
TextInput,
|
|
240
|
+
TimePicker,
|
|
241
|
+
Toast,
|
|
242
|
+
ToastContainer,
|
|
243
|
+
Toggle,
|
|
244
|
+
ToggleButton,
|
|
245
|
+
Tooltip,
|
|
246
|
+
TooltipEllipsis,
|
|
247
|
+
Typography,
|
|
248
|
+
UIConfig,
|
|
249
|
+
UIRouter,
|
|
250
|
+
UIStyle,
|
|
251
|
+
UnderlinedIcon,
|
|
252
|
+
ViewIcon,
|
|
253
|
+
ViewOffIcon,
|
|
254
|
+
compoundMapper,
|
|
255
|
+
createAclGuard,
|
|
256
|
+
dynamicColumns,
|
|
257
|
+
dynamicInputs,
|
|
258
|
+
isEqual,
|
|
259
|
+
logger,
|
|
260
|
+
ns,
|
|
261
|
+
resources,
|
|
262
|
+
uiOutlineClass,
|
|
263
|
+
useAutosave,
|
|
264
|
+
useBreakpoint,
|
|
265
|
+
useDebounceCallback,
|
|
266
|
+
useDeepCompareEffect,
|
|
267
|
+
useDeepCompareLayoutEffect,
|
|
268
|
+
useDeepCompareMemo,
|
|
269
|
+
useFilters,
|
|
270
|
+
useForm,
|
|
271
|
+
useFormAutosave,
|
|
272
|
+
useIntersectionObserver,
|
|
273
|
+
useLocalStorage,
|
|
274
|
+
useLongPressRepeat,
|
|
275
|
+
usePagination,
|
|
276
|
+
useScrollableListBox,
|
|
277
|
+
useSorting,
|
|
278
|
+
useStateAndRef,
|
|
279
|
+
useTableColumnConfig,
|
|
280
|
+
useTableNav,
|
|
281
|
+
useToast,
|
|
282
|
+
useTranslationMemo,
|
|
283
|
+
withPrivateAuthGuard
|
|
284
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { InfiniteData, QueryKey, UseInfiniteQueryOptions, UseMutationOptions, UseQueryOptions } from '@tanstack/react-query';
|
|
2
|
-
import { ApplicationException, GeneralErrorCodes } from '
|
|
2
|
+
import { ApplicationException, GeneralErrorCodes } from '../utils/vendor/error-handling';
|
|
3
3
|
import { Function, IsUnknown } from './common';
|
|
4
4
|
export type AppQueryOptions<TFunction extends Function, TData = Awaited<ReturnType<TFunction>>, TErrorCodes = GeneralErrorCodes> = Omit<UseQueryOptions<Awaited<ReturnType<TFunction>>, ApplicationException<TErrorCodes>, IsUnknown<TData, Awaited<ReturnType<TFunction>>>>, "queryKey" | "queryFn">;
|
|
5
5
|
export type AppMutationOptions<TFunction extends Function, TVariables = void, TData = Awaited<ReturnType<TFunction>>, TErrorCodes = GeneralErrorCodes> = Omit<UseMutationOptions<TData, ApplicationException<TErrorCodes>, TVariables>, "mutationKey" | "mutationFn">;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
const compoundMapper = (config) => {
|
|
2
|
+
return (props) => {
|
|
3
|
+
const variant = config.compoundVariants?.find((v) => {
|
|
4
|
+
return Object.entries(v).filter(([key]) => key !== "value").every(([key, value]) => {
|
|
5
|
+
const prop = props[key] || config.defaultVariants?.[key];
|
|
6
|
+
return Array.isArray(value) ? value.includes(prop) : prop === value;
|
|
7
|
+
});
|
|
8
|
+
});
|
|
9
|
+
return variant?.value ?? config.default;
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
export {
|
|
13
|
+
compoundMapper
|
|
14
|
+
};
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import { parseAbsoluteToLocal, getLocalTimeZone, fromDate, CalendarDateTime, CalendarDate, parseAbsolute } from "@internationalized/date";
|
|
2
|
+
var DateTimeUtils;
|
|
3
|
+
((DateTimeUtils2) => {
|
|
4
|
+
function fromISOtoZonedDateTime(isoString) {
|
|
5
|
+
return parseAbsoluteToLocal(isoString);
|
|
6
|
+
}
|
|
7
|
+
DateTimeUtils2.fromISOtoZonedDateTime = fromISOtoZonedDateTime;
|
|
8
|
+
function fromDateValueToISO(dateValue) {
|
|
9
|
+
return dateValue.toDate(getLocalTimeZone()).toISOString();
|
|
10
|
+
}
|
|
11
|
+
DateTimeUtils2.fromDateValueToISO = fromDateValueToISO;
|
|
12
|
+
function fromLocalToZonedDateTime(date) {
|
|
13
|
+
return fromDate(date, getLocalTimeZone());
|
|
14
|
+
}
|
|
15
|
+
DateTimeUtils2.fromLocalToZonedDateTime = fromLocalToZonedDateTime;
|
|
16
|
+
function fromDateValueToLocal(dateValue) {
|
|
17
|
+
return dateValue.toDate(getLocalTimeZone());
|
|
18
|
+
}
|
|
19
|
+
DateTimeUtils2.fromDateValueToLocal = fromDateValueToLocal;
|
|
20
|
+
function fromCalendarDateToUTCISO(calendarDate, options = {}) {
|
|
21
|
+
if (options.endOfDay) {
|
|
22
|
+
const calendarDateTime = new CalendarDateTime(
|
|
23
|
+
calendarDate.year,
|
|
24
|
+
calendarDate.month,
|
|
25
|
+
calendarDate.day,
|
|
26
|
+
23,
|
|
27
|
+
59,
|
|
28
|
+
59,
|
|
29
|
+
999
|
|
30
|
+
);
|
|
31
|
+
return calendarDateTime.toDate("UTC").toISOString();
|
|
32
|
+
}
|
|
33
|
+
return calendarDate.toDate("UTC").toISOString();
|
|
34
|
+
}
|
|
35
|
+
DateTimeUtils2.fromCalendarDateToUTCISO = fromCalendarDateToUTCISO;
|
|
36
|
+
function fromUTCISOToCalendarDate(isoString) {
|
|
37
|
+
const date = new Date(isoString);
|
|
38
|
+
return new CalendarDate(date.getUTCFullYear(), date.getUTCMonth() + 1, date.getUTCDate());
|
|
39
|
+
}
|
|
40
|
+
DateTimeUtils2.fromUTCISOToCalendarDate = fromUTCISOToCalendarDate;
|
|
41
|
+
function fromCalendarDateTimeToUTCISO(calendarDateTime) {
|
|
42
|
+
return calendarDateTime.toDate("UTC").toISOString();
|
|
43
|
+
}
|
|
44
|
+
DateTimeUtils2.fromCalendarDateTimeToUTCISO = fromCalendarDateTimeToUTCISO;
|
|
45
|
+
function fromUTCISOToCalendarDateTime(isoString) {
|
|
46
|
+
const zonedDateTime = parseAbsolute(isoString, "UTC");
|
|
47
|
+
return new CalendarDateTime(
|
|
48
|
+
zonedDateTime.year,
|
|
49
|
+
zonedDateTime.month,
|
|
50
|
+
zonedDateTime.day,
|
|
51
|
+
zonedDateTime.hour,
|
|
52
|
+
zonedDateTime.minute,
|
|
53
|
+
zonedDateTime.second,
|
|
54
|
+
zonedDateTime.millisecond
|
|
55
|
+
);
|
|
56
|
+
}
|
|
57
|
+
DateTimeUtils2.fromUTCISOToCalendarDateTime = fromUTCISOToCalendarDateTime;
|
|
58
|
+
function formatTextDateToCalendarDateTime(textDate) {
|
|
59
|
+
if (!textDate?.includes("hh")) {
|
|
60
|
+
return null;
|
|
61
|
+
}
|
|
62
|
+
const datePart = textDate.split(",").at(0)?.trim();
|
|
63
|
+
if (!datePart) {
|
|
64
|
+
return null;
|
|
65
|
+
}
|
|
66
|
+
const date = new Date(datePart);
|
|
67
|
+
if (!date || date.toString() === "Invalid Date") {
|
|
68
|
+
return null;
|
|
69
|
+
}
|
|
70
|
+
const zonedDateTime = fromDate(date, getLocalTimeZone());
|
|
71
|
+
return new CalendarDateTime(zonedDateTime.year, zonedDateTime.month, zonedDateTime.day, 0, 0, 0, 0);
|
|
72
|
+
}
|
|
73
|
+
DateTimeUtils2.formatTextDateToCalendarDateTime = formatTextDateToCalendarDateTime;
|
|
74
|
+
})(DateTimeUtils || (DateTimeUtils = {}));
|
|
75
|
+
export {
|
|
76
|
+
DateTimeUtils
|
|
77
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { DateTime } from "luxon";
|
|
2
|
+
var DateUtils;
|
|
3
|
+
((DateUtils2) => {
|
|
4
|
+
const DATE_FORMAT = "dd/MM/yyyy";
|
|
5
|
+
function formatDate(date, format = DATE_FORMAT) {
|
|
6
|
+
return DateTime.fromJSDate(date).toFormat(format);
|
|
7
|
+
}
|
|
8
|
+
DateUtils2.formatDate = formatDate;
|
|
9
|
+
})(DateUtils || (DateUtils = {}));
|
|
10
|
+
export {
|
|
11
|
+
DateUtils
|
|
12
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
var DomUtils;
|
|
2
|
+
((DomUtils2) => {
|
|
3
|
+
const KEYBOARD_INPUTS = /* @__PURE__ */ new Set(["button", "submit", "checkbox", "file", "image"]);
|
|
4
|
+
DomUtils2.isKeyboardInput = (elem) => {
|
|
5
|
+
return elem.tagName === "INPUT" && !KEYBOARD_INPUTS.has(elem.type) || elem.hasAttribute("contenteditable");
|
|
6
|
+
};
|
|
7
|
+
DomUtils2.isKeyboardEvent = (event) => {
|
|
8
|
+
return event.nativeEvent instanceof KeyboardEvent;
|
|
9
|
+
};
|
|
10
|
+
})(DomUtils || (DomUtils = {}));
|
|
11
|
+
export {
|
|
12
|
+
DomUtils
|
|
13
|
+
};
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { RestUtils } from "./rest.utils.js";
|
|
2
|
+
var FileUtils;
|
|
3
|
+
((FileUtils2) => {
|
|
4
|
+
FileUtils2.getObjectUrl = (data, revokeTimeoutMs = 4e4) => {
|
|
5
|
+
const url = URL.createObjectURL(data instanceof Blob ? data : data.data);
|
|
6
|
+
setTimeout(() => URL.revokeObjectURL(url), revokeTimeoutMs);
|
|
7
|
+
return url;
|
|
8
|
+
};
|
|
9
|
+
FileUtils2.openFile = (data, target = "_blank", revokeTimeoutMs) => {
|
|
10
|
+
const url = (0, FileUtils2.getObjectUrl)(data, revokeTimeoutMs);
|
|
11
|
+
window.open(url, target);
|
|
12
|
+
};
|
|
13
|
+
FileUtils2.downloadFile = (data, fileName, revokeTimeoutMs) => {
|
|
14
|
+
const url = (0, FileUtils2.getObjectUrl)(data, revokeTimeoutMs);
|
|
15
|
+
const contentDispositionFileName = data instanceof Blob ? void 0 : RestUtils.extractContentDispositionFilename(data.headers);
|
|
16
|
+
const a = document.createElement("a");
|
|
17
|
+
a.download = fileName ?? contentDispositionFileName ?? "download";
|
|
18
|
+
a.rel = "noopener";
|
|
19
|
+
a.href = url;
|
|
20
|
+
setTimeout(() => a.dispatchEvent(new MouseEvent("click")));
|
|
21
|
+
};
|
|
22
|
+
FileUtils2.isFileTypeAccepted = (file, fileTypes) => {
|
|
23
|
+
if (!fileTypes || fileTypes.length === 0) {
|
|
24
|
+
return true;
|
|
25
|
+
}
|
|
26
|
+
return fileTypes.some((type) => {
|
|
27
|
+
if (type.includes("/")) {
|
|
28
|
+
return file.type === type || type.endsWith("/*") && file.type.startsWith(type.slice(0, -1));
|
|
29
|
+
}
|
|
30
|
+
return file.name.toLowerCase().endsWith(type.toLowerCase());
|
|
31
|
+
});
|
|
32
|
+
};
|
|
33
|
+
FileUtils2.getCalculatedFileSize = (file) => {
|
|
34
|
+
if (!file) {
|
|
35
|
+
return "";
|
|
36
|
+
}
|
|
37
|
+
if (file.size < 1024) {
|
|
38
|
+
return `${file.size} B`;
|
|
39
|
+
}
|
|
40
|
+
if (file.size < 1024 * 1024) {
|
|
41
|
+
return `${(file.size / 1024).toFixed(2)} KB`;
|
|
42
|
+
}
|
|
43
|
+
if (file.size < 1024 * 1024 * 1024) {
|
|
44
|
+
return `${(file.size / 1024 / 1024).toFixed(2)} MB`;
|
|
45
|
+
}
|
|
46
|
+
return `${(file.size / 1024 / 1024 / 1024).toFixed(2)} GB`;
|
|
47
|
+
};
|
|
48
|
+
FileUtils2.formatBytes = (size, decimals = 2) => {
|
|
49
|
+
if (size < 1024) {
|
|
50
|
+
return `${size} B`;
|
|
51
|
+
}
|
|
52
|
+
if (size < 1024 * 1024) {
|
|
53
|
+
return `${(size / 1024).toFixed(decimals)} KB`;
|
|
54
|
+
}
|
|
55
|
+
if (size < 1024 * 1024 * 1024) {
|
|
56
|
+
return `${(size / 1024 / 1024).toFixed(decimals)} MB`;
|
|
57
|
+
}
|
|
58
|
+
return `${(size / 1024 / 1024 / 1024).toFixed(decimals)} GB`;
|
|
59
|
+
};
|
|
60
|
+
})(FileUtils || (FileUtils = {}));
|
|
61
|
+
export {
|
|
62
|
+
FileUtils
|
|
63
|
+
};
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import { ObjectUtils } from "./object.utils.js";
|
|
2
|
+
const isEqual = (a, b) => {
|
|
3
|
+
return eq(a, b);
|
|
4
|
+
};
|
|
5
|
+
const eq = (a, b, aStack, bStack) => {
|
|
6
|
+
if (a === b) {
|
|
7
|
+
return a !== 0 || 1 / a === 1 / b;
|
|
8
|
+
}
|
|
9
|
+
if (a == null || b == null) {
|
|
10
|
+
return a === b;
|
|
11
|
+
}
|
|
12
|
+
if (a !== a) {
|
|
13
|
+
return b !== b;
|
|
14
|
+
}
|
|
15
|
+
const type = typeof a;
|
|
16
|
+
if (type !== "function" && type !== "object" && typeof b !== "object") {
|
|
17
|
+
return false;
|
|
18
|
+
}
|
|
19
|
+
return deepEq(a, b, aStack, bStack);
|
|
20
|
+
};
|
|
21
|
+
const deepEq = (a, b, aStack, bStack) => {
|
|
22
|
+
const className = toString.call(a);
|
|
23
|
+
if (className !== toString.call(b)) {
|
|
24
|
+
return false;
|
|
25
|
+
}
|
|
26
|
+
switch (className) {
|
|
27
|
+
// Strings, numbers, regular expressions, dates, and booleans are compared by value.
|
|
28
|
+
// RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i')
|
|
29
|
+
case "[object RegExp]":
|
|
30
|
+
case "[object String]":
|
|
31
|
+
return `${a}` === `${b}`;
|
|
32
|
+
case "[object Number]":
|
|
33
|
+
if (+a !== +a) {
|
|
34
|
+
return +b !== +b;
|
|
35
|
+
}
|
|
36
|
+
return +a === 0 ? 1 / +a === 1 / b : +a === +b;
|
|
37
|
+
case "[object Date]":
|
|
38
|
+
case "[object Boolean]":
|
|
39
|
+
return +a === +b;
|
|
40
|
+
case "[object Symbol]":
|
|
41
|
+
return Symbol.prototype.valueOf.call(a) === Symbol.prototype.valueOf.call(b);
|
|
42
|
+
}
|
|
43
|
+
const areArrays = className === "[object Array]";
|
|
44
|
+
if (!areArrays) {
|
|
45
|
+
if (typeof a !== "object" || typeof b !== "object") {
|
|
46
|
+
return false;
|
|
47
|
+
}
|
|
48
|
+
const aCtor = a.constructor;
|
|
49
|
+
const bCtor = b.constructor;
|
|
50
|
+
if (aCtor !== bCtor && !(ObjectUtils.isFunction(aCtor) && aCtor instanceof aCtor && ObjectUtils.isFunction(bCtor) && bCtor instanceof bCtor) && "constructor" in a && "constructor" in b) {
|
|
51
|
+
return false;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
aStack = aStack || [];
|
|
55
|
+
bStack = bStack || [];
|
|
56
|
+
let { length } = aStack;
|
|
57
|
+
while (length--) {
|
|
58
|
+
if (aStack[length] === a) {
|
|
59
|
+
return bStack[length] === b;
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
aStack.push(a);
|
|
63
|
+
bStack.push(b);
|
|
64
|
+
if (areArrays) {
|
|
65
|
+
length = a.length;
|
|
66
|
+
if (length !== b.length) {
|
|
67
|
+
return false;
|
|
68
|
+
}
|
|
69
|
+
while (length--) {
|
|
70
|
+
if (!eq(a[length], b[length], aStack, bStack)) {
|
|
71
|
+
return false;
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
} else {
|
|
75
|
+
const keys = Object.keys(a);
|
|
76
|
+
let key;
|
|
77
|
+
length = keys.length;
|
|
78
|
+
if (Object.keys(b).length !== length) {
|
|
79
|
+
return false;
|
|
80
|
+
}
|
|
81
|
+
while (length--) {
|
|
82
|
+
key = keys[length];
|
|
83
|
+
if (!(Object.prototype.hasOwnProperty.call(b, key) && // oxlint-disable-next-line no-explicit-any
|
|
84
|
+
eq(a[key], b[key], aStack, bStack))) {
|
|
85
|
+
return false;
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
aStack.pop();
|
|
90
|
+
bStack.pop();
|
|
91
|
+
return true;
|
|
92
|
+
};
|
|
93
|
+
export {
|
|
94
|
+
isEqual
|
|
95
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import log from "loglevel";
|
|
2
|
+
import prefix from "loglevel-plugin-prefix";
|
|
3
|
+
prefix.reg(log);
|
|
4
|
+
prefix.apply(log, {
|
|
5
|
+
template: "[%t] %l:",
|
|
6
|
+
timestampFormatter: (date) => {
|
|
7
|
+
return date.toISOString();
|
|
8
|
+
}
|
|
9
|
+
});
|
|
10
|
+
const logger = {
|
|
11
|
+
info: (...args) => log.info(...args),
|
|
12
|
+
debug: (...args) => log.debug(...args),
|
|
13
|
+
warn: (...args) => log.warn(...args),
|
|
14
|
+
error: (...args) => log.error(...args),
|
|
15
|
+
trace: (...args) => log.trace(...args)
|
|
16
|
+
};
|
|
17
|
+
export {
|
|
18
|
+
logger
|
|
19
|
+
};
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
var ObjectUtils;
|
|
2
|
+
((ObjectUtils2) => {
|
|
3
|
+
ObjectUtils2.isNil = (obj) => {
|
|
4
|
+
return obj === null || obj === void 0;
|
|
5
|
+
};
|
|
6
|
+
ObjectUtils2.isFunction = (obj) => {
|
|
7
|
+
return typeof obj === "function";
|
|
8
|
+
};
|
|
9
|
+
ObjectUtils2.isObject = (obj) => {
|
|
10
|
+
return typeof obj === "object" && !!obj;
|
|
11
|
+
};
|
|
12
|
+
ObjectUtils2.isString = (obj) => {
|
|
13
|
+
return Object.prototype.toString.call(obj) === "[object String]";
|
|
14
|
+
};
|
|
15
|
+
ObjectUtils2.isDate = (obj) => {
|
|
16
|
+
return Object.prototype.toString.call(obj) === "[object Date]";
|
|
17
|
+
};
|
|
18
|
+
ObjectUtils2.isRegExp = (obj) => {
|
|
19
|
+
return Object.prototype.toString.call(obj) === "[object RegExp]";
|
|
20
|
+
};
|
|
21
|
+
ObjectUtils2.isEmpty = (obj) => {
|
|
22
|
+
if (obj === null || obj === void 0) {
|
|
23
|
+
return true;
|
|
24
|
+
}
|
|
25
|
+
if (Array.isArray(obj) || (0, ObjectUtils2.isString)(obj)) {
|
|
26
|
+
return obj.length === 0;
|
|
27
|
+
}
|
|
28
|
+
return Object.keys(obj).length === 0;
|
|
29
|
+
};
|
|
30
|
+
ObjectUtils2.deepConditionalMerge = (target, source, condition) => {
|
|
31
|
+
const output = { ...target };
|
|
32
|
+
for (const key in source) {
|
|
33
|
+
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
34
|
+
const value = source[key];
|
|
35
|
+
if (condition(value, key)) {
|
|
36
|
+
if (typeof value === "object" && !Array.isArray(value)) {
|
|
37
|
+
output[key] = (0, ObjectUtils2.deepConditionalMerge)(
|
|
38
|
+
output[key],
|
|
39
|
+
value,
|
|
40
|
+
condition
|
|
41
|
+
);
|
|
42
|
+
} else {
|
|
43
|
+
output[key] = value;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
return output;
|
|
49
|
+
};
|
|
50
|
+
})(ObjectUtils || (ObjectUtils = {}));
|
|
51
|
+
export {
|
|
52
|
+
ObjectUtils
|
|
53
|
+
};
|