ingeniuscliq-core 0.4.13 → 0.4.15
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 +417 -0
- package/dist/_virtual/index.js +5 -0
- package/dist/_virtual/index2.js +3 -0
- package/dist/_virtual/use-sync-external-store-shim.development.js +3 -0
- package/dist/_virtual/use-sync-external-store-shim.production.js +3 -0
- package/dist/assets/logo.svg.js +3 -0
- package/dist/classes/CoreBuilder.d.ts +1 -0
- package/dist/classes/CoreBuilder.d.ts.map +1 -0
- package/dist/classes/CoreBuilder.js +4 -0
- package/dist/classes/index.d.ts +1 -0
- package/dist/classes/index.d.ts.map +1 -0
- package/dist/components/common/carousel/CustomCarousel.d.ts +2 -1
- package/dist/components/common/carousel/CustomCarousel.d.ts.map +1 -0
- package/dist/components/common/carousel/CustomCarousel.tsx +26 -0
- package/dist/components/common/carousel/CustomCarouselSection.d.ts +2 -1
- package/dist/components/common/carousel/CustomCarouselSection.d.ts.map +1 -0
- package/dist/components/common/carousel/CustomCarouselSection.tsx +41 -0
- package/dist/components/common/carousel/index.d.ts +3 -2
- package/dist/components/common/carousel/index.d.ts.map +1 -0
- package/dist/components/common/form/CustomFormField.d.ts +4 -2
- package/dist/components/common/form/CustomFormField.d.ts.map +1 -0
- package/dist/components/common/form/CustomFormField.tsx +29 -0
- package/dist/components/common/form/FormCheckbox.d.ts +5 -1
- package/dist/components/common/form/FormCheckbox.d.ts.map +1 -0
- package/dist/components/common/form/FormCheckbox.tsx +57 -0
- package/dist/components/common/form/FormInput.d.ts +4 -1
- package/dist/components/common/form/FormInput.d.ts.map +1 -0
- package/dist/components/common/form/FormInput.tsx +60 -0
- package/dist/components/common/form/FormSelect.d.ts +8 -2
- package/dist/components/common/form/FormSelect.d.ts.map +1 -0
- package/dist/components/common/form/FormSelect.tsx +78 -0
- package/dist/components/common/form/FormTextArea.d.ts +6 -4
- package/dist/components/common/form/FormTextArea.d.ts.map +1 -0
- package/dist/components/common/form/FormTextArea.tsx +57 -0
- package/dist/components/common/form/FormWrapper.d.ts +2 -1
- package/dist/components/common/form/FormWrapper.d.ts.map +1 -0
- package/dist/components/common/form/FormWrapper.tsx +21 -0
- package/dist/components/common/form/index.d.ts +4 -3
- package/dist/components/common/form/index.d.ts.map +1 -0
- package/dist/components/common/index.d.ts +2 -0
- package/dist/components/common/index.d.ts.map +1 -0
- package/dist/components/common/logo/Logo.d.ts +2 -1
- package/dist/components/common/logo/Logo.d.ts.map +1 -0
- package/dist/components/common/logo/Logo.tsx +40 -0
- package/dist/components/common/logo/index.d.ts +1 -0
- package/dist/components/common/logo/index.d.ts.map +1 -0
- package/dist/components/common/pagination/CustomPagination.d.ts +2 -1
- package/dist/components/common/pagination/CustomPagination.d.ts.map +1 -0
- package/dist/components/common/pagination/CustomPagination.tsx +64 -0
- package/dist/components/common/pagination/index.d.ts +1 -0
- package/dist/components/common/pagination/index.d.ts.map +1 -0
- package/dist/components/common/select/CustomSelect.d.ts +2 -1
- package/dist/components/common/select/CustomSelect.d.ts.map +1 -0
- package/dist/components/common/select/CustomSelect.tsx +27 -0
- package/dist/components/common/select/index.d.ts +1 -0
- package/dist/components/common/select/index.d.ts.map +1 -0
- package/dist/components/common/spinner/Spinner.d.ts +1 -0
- package/dist/components/common/spinner/Spinner.d.ts.map +1 -0
- package/dist/components/common/spinner/Spinner.tsx +32 -0
- package/dist/components/common/spinner/index.d.ts +1 -0
- package/dist/components/common/spinner/index.d.ts.map +1 -0
- package/dist/components/common/stepper/Stepper.d.ts +18 -0
- package/dist/components/common/stepper/Stepper.d.ts.map +1 -0
- package/dist/components/common/stepper/Stepper.tsx +59 -0
- package/dist/components/common/stepper/index.d.ts +2 -0
- package/dist/components/common/stepper/index.d.ts.map +1 -0
- package/dist/components/index.d.ts +5 -4
- package/dist/components/index.d.ts.map +1 -0
- package/dist/components/layouts/CoreBaseLayout.d.ts +3 -1
- package/dist/components/layouts/CoreBaseLayout.d.ts.map +1 -0
- package/dist/components/layouts/CoreBaseLayout.tsx +19 -0
- package/dist/components/layouts/index.d.ts +1 -0
- package/dist/components/layouts/index.d.ts.map +1 -0
- package/dist/components/templates/CoreHomeLayout.d.ts +1 -0
- package/dist/components/templates/CoreHomeLayout.d.ts.map +1 -0
- package/dist/components/templates/CoreHomeLayout.tsx +8 -0
- package/dist/components/templates/CorePreviewLayout.d.ts +2 -1
- package/dist/components/templates/CorePreviewLayout.d.ts.map +1 -0
- package/dist/components/templates/CorePreviewLayout.tsx +27 -0
- package/dist/components/templates/index.d.ts +1 -0
- package/dist/components/templates/index.d.ts.map +1 -0
- package/dist/components/ui/accordion.d.ts +5 -4
- package/dist/components/ui/accordion.d.ts.map +1 -0
- package/dist/components/ui/accordion.tsx +44 -0
- package/dist/components/ui/alert-dialog.d.ts +18 -11
- package/dist/components/ui/alert-dialog.d.ts.map +1 -0
- package/dist/components/ui/alert-dialog.tsx +106 -0
- package/dist/components/ui/alert.d.ts +5 -5
- package/dist/components/ui/alert.d.ts.map +1 -0
- package/dist/components/ui/alert.tsx +49 -0
- package/dist/components/ui/avatar.d.ts +4 -3
- package/dist/components/ui/avatar.d.ts.map +1 -0
- package/dist/components/ui/avatar.tsx +40 -0
- package/dist/components/ui/badge.d.ts +5 -3
- package/dist/components/ui/badge.d.ts.map +1 -0
- package/dist/components/ui/badge.tsx +26 -0
- package/dist/components/ui/breadcrumb.d.ts +17 -8
- package/dist/components/ui/breadcrumb.d.ts.map +1 -0
- package/dist/components/ui/breadcrumb.tsx +88 -0
- package/dist/components/ui/button.d.ts +5 -3
- package/dist/components/ui/button.d.ts.map +1 -0
- package/dist/components/ui/button.tsx +47 -0
- package/dist/components/ui/card.d.ts +9 -8
- package/dist/components/ui/card.d.ts.map +1 -0
- package/dist/components/ui/card.tsx +68 -0
- package/dist/components/ui/carousel.d.ts +6 -6
- package/dist/components/ui/carousel.d.ts.map +1 -0
- package/dist/components/ui/carousel.tsx +191 -0
- package/dist/components/ui/checkbox.d.ts +2 -1
- package/dist/components/ui/checkbox.d.ts.map +1 -0
- package/dist/components/ui/checkbox.tsx +28 -0
- package/dist/components/ui/dialog.d.ts +19 -12
- package/dist/components/ui/dialog.d.ts.map +1 -0
- package/dist/components/ui/dialog.tsx +95 -0
- package/dist/components/ui/dropdown-menu.d.ts +24 -20
- package/dist/components/ui/dropdown-menu.d.ts.map +1 -0
- package/dist/components/ui/dropdown-menu.tsx +140 -0
- package/dist/components/ui/form.d.ts +6 -6
- package/dist/components/ui/form.d.ts.map +1 -0
- package/dist/components/ui/form.tsx +102 -0
- package/dist/components/ui/index.d.ts +2 -6
- package/dist/components/ui/index.d.ts.map +1 -0
- package/dist/components/ui/input.d.ts +3 -3
- package/dist/components/ui/input.d.ts.map +1 -0
- package/dist/components/ui/input.tsx +25 -0
- package/dist/components/ui/label.d.ts +3 -1
- package/dist/components/ui/label.d.ts.map +1 -0
- package/dist/components/ui/label.tsx +20 -0
- package/dist/components/ui/pagination.d.ts +27 -12
- package/dist/components/ui/pagination.d.ts.map +1 -0
- package/dist/components/ui/pagination.tsx +122 -0
- package/dist/components/ui/popover.d.ts +5 -4
- package/dist/components/ui/popover.d.ts.map +1 -0
- package/dist/components/ui/popover.tsx +24 -0
- package/dist/components/ui/radio-group.d.ts +3 -2
- package/dist/components/ui/radio-group.d.ts.map +1 -0
- package/dist/components/ui/radio-group.tsx +34 -0
- package/dist/components/ui/select.d.ts +13 -12
- package/dist/components/ui/select.d.ts.map +1 -0
- package/dist/components/ui/select.tsx +128 -0
- package/dist/components/ui/separator.d.ts +2 -1
- package/dist/components/ui/separator.d.ts.map +1 -0
- package/dist/components/ui/separator.tsx +24 -0
- package/dist/components/ui/sheet.d.ts +26 -11
- package/dist/components/ui/sheet.d.ts.map +1 -0
- package/dist/components/ui/sheet.tsx +106 -0
- package/dist/components/ui/skeleton.d.ts +3 -1
- package/dist/components/ui/skeleton.d.ts.map +1 -0
- package/dist/components/ui/skeleton.tsx +17 -0
- package/dist/components/ui/slider.d.ts +2 -1
- package/dist/components/ui/slider.d.ts.map +1 -0
- package/dist/components/ui/slider.tsx +31 -0
- package/dist/components/ui/stepper.d.ts +40 -32
- package/dist/components/ui/stepper.d.ts.map +1 -0
- package/dist/components/ui/stepper.tsx +452 -0
- package/dist/components/ui/switch.d.ts +2 -1
- package/dist/components/ui/switch.d.ts.map +1 -0
- package/dist/components/ui/switch.tsx +27 -0
- package/dist/components/ui/table.d.ts +9 -8
- package/dist/components/ui/table.d.ts.map +1 -0
- package/dist/components/ui/table.tsx +80 -0
- package/dist/components/ui/tabs.d.ts +5 -4
- package/dist/components/ui/tabs.d.ts.map +1 -0
- package/dist/components/ui/tabs.tsx +45 -0
- package/dist/components/ui/textarea.d.ts +2 -1
- package/dist/components/ui/textarea.d.ts.map +1 -0
- package/dist/components/ui/textarea.tsx +22 -0
- package/dist/components/ui/tooltip.d.ts +5 -4
- package/dist/components/ui/tooltip.d.ts.map +1 -0
- package/dist/components/ui/tooltip.tsx +23 -0
- package/dist/constants/index.d.ts +2 -1
- package/dist/constants/index.d.ts.map +1 -0
- package/dist/helpers/axiosGlobal.d.ts +7 -5
- package/dist/helpers/axiosGlobal.d.ts.map +1 -0
- package/dist/helpers/axiosGlobal.js +66 -0
- package/dist/helpers/image.d.ts +1 -0
- package/dist/helpers/image.d.ts.map +1 -0
- package/dist/helpers/image.js +11 -0
- package/dist/helpers/index.d.ts +1 -2
- package/dist/helpers/index.d.ts.map +1 -0
- package/dist/helpers/numbers.d.ts +1 -0
- package/dist/helpers/numbers.d.ts.map +1 -0
- package/dist/helpers/numbers.js +8 -0
- package/dist/helpers/strings.d.ts +1 -0
- package/dist/helpers/strings.d.ts.map +1 -0
- package/dist/helpers/strings.js +6 -0
- package/dist/hooks/index.d.ts +1 -0
- package/dist/hooks/index.d.ts.map +1 -0
- package/dist/hooks/use-mobile.d.ts +1 -0
- package/dist/hooks/use-mobile.d.ts.map +1 -0
- package/dist/hooks/use-mobile.js +16 -0
- package/dist/hooks/useLanguage.d.ts +5 -0
- package/dist/hooks/useLanguage.d.ts.map +1 -0
- package/dist/hooks/useLanguage.js +32 -0
- package/dist/hooks/useNotification.d.ts +1 -0
- package/dist/hooks/useNotification.d.ts.map +1 -0
- package/dist/hooks/useNotification.js +17 -0
- package/dist/i18n/config.d.ts +82 -68
- package/dist/i18n/config.d.ts.map +1 -0
- package/dist/i18n/config.js +58 -0
- package/dist/i18n/index.d.ts +3 -0
- package/dist/i18n/index.d.ts.map +1 -0
- package/dist/i18n/locales/en.json.js +12 -0
- package/dist/i18n/locales/es.json.js +12 -0
- package/dist/i18n/locales/fields/en.json.js +52 -0
- package/dist/i18n/locales/fields/es.json.js +52 -0
- package/dist/i18n/locales/messages/en.json.js +14 -0
- package/dist/i18n/locales/messages/es.json.js +14 -0
- package/dist/i18n/utils/getModuleNamespace.d.ts +16 -0
- package/dist/i18n/utils/getModuleNamespace.d.ts.map +1 -0
- package/dist/i18n/utils/getModuleNamespace.js +10 -0
- package/dist/i18n/utils/loadModuleTranslations.d.ts +5 -0
- package/dist/i18n/utils/loadModuleTranslations.d.ts.map +1 -0
- package/dist/i18n/utils/loadModuleTranslations.js +21 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +87 -20192
- package/dist/ingeniuscliq-core.css +1240 -0
- package/dist/lib/utils.d.ts +1 -0
- package/dist/lib/utils.d.ts.map +1 -0
- package/dist/lib/utils.js +8 -0
- package/dist/modules/CoreAuth/classes/CoreAuthBuilder.d.ts +5 -3
- package/dist/modules/CoreAuth/classes/CoreAuthBuilder.d.ts.map +1 -0
- package/dist/modules/CoreAuth/classes/CoreAuthBuilder.js +185 -0
- package/dist/modules/CoreAuth/classes/index.d.ts +1 -0
- package/dist/modules/CoreAuth/classes/index.d.ts.map +1 -0
- package/dist/modules/CoreAuth/constants/auth.d.ts +1 -0
- package/dist/modules/CoreAuth/constants/auth.d.ts.map +1 -0
- package/dist/modules/CoreAuth/constants/auth.js +6 -0
- package/dist/modules/CoreAuth/constants/index.d.ts +1 -0
- package/dist/modules/CoreAuth/constants/index.d.ts.map +1 -0
- package/dist/modules/CoreAuth/context/AuthContext.d.ts +12 -0
- package/dist/modules/CoreAuth/context/AuthContext.d.ts.map +1 -0
- package/dist/modules/CoreAuth/context/AuthContext.tsx +4 -0
- package/dist/modules/CoreAuth/context/index.d.ts +2 -0
- package/dist/modules/CoreAuth/context/index.d.ts.map +1 -0
- package/dist/modules/CoreAuth/hooks/index.d.ts +1 -0
- package/dist/modules/CoreAuth/hooks/index.d.ts.map +1 -0
- package/dist/modules/CoreAuth/hooks/useAuth.d.ts +10 -9
- package/dist/modules/CoreAuth/hooks/useAuth.d.ts.map +1 -0
- package/dist/modules/CoreAuth/hooks/useAuth.js +38 -0
- package/dist/modules/CoreAuth/index.d.ts +8 -1
- package/dist/modules/CoreAuth/index.d.ts.map +1 -0
- package/dist/modules/CoreAuth/index.js +11 -0
- package/dist/modules/CoreAuth/locale/en.json.js +4 -0
- package/dist/modules/CoreAuth/locale/es.json.js +4 -0
- package/dist/modules/CoreAuth/registry/hooks/index.d.ts +1 -0
- package/dist/modules/CoreAuth/registry/hooks/index.d.ts.map +1 -0
- package/dist/modules/CoreAuth/registry/index.d.ts +1 -0
- package/dist/modules/CoreAuth/registry/index.d.ts.map +1 -0
- package/dist/modules/CoreAuth/registry/types/index.d.ts +1 -0
- package/dist/modules/CoreAuth/registry/types/index.d.ts.map +1 -0
- package/dist/modules/CoreAuth/services/base.d.ts +24 -5
- package/dist/modules/CoreAuth/services/base.d.ts.map +1 -0
- package/dist/modules/CoreAuth/services/base.js +53 -0
- package/dist/modules/CoreAuth/services/index.d.ts +1 -0
- package/dist/modules/CoreAuth/services/index.d.ts.map +1 -0
- package/dist/modules/CoreAuth/stores/authStore.d.ts +15 -8
- package/dist/modules/CoreAuth/stores/authStore.d.ts.map +1 -0
- package/dist/modules/CoreAuth/stores/authStore.js +13 -0
- package/dist/modules/CoreAuth/stores/index.d.ts +1 -0
- package/dist/modules/CoreAuth/stores/index.d.ts.map +1 -0
- package/dist/modules/CoreAuth/types/CoreAuth.d.ts +10 -6
- package/dist/modules/CoreAuth/types/CoreAuth.d.ts.map +1 -0
- package/dist/modules/CoreAuth/types/index.d.ts +1 -0
- package/dist/modules/CoreAuth/types/index.d.ts.map +1 -0
- package/dist/modules/CoreCustomization/classes/CoreCustomizationBuilder.d.ts +8 -8
- package/dist/modules/CoreCustomization/classes/CoreCustomizationBuilder.d.ts.map +1 -0
- package/dist/modules/CoreCustomization/classes/CoreCustomizationBuilder.js +82 -0
- package/dist/modules/CoreCustomization/classes/index.d.ts +1 -0
- package/dist/modules/CoreCustomization/classes/index.d.ts.map +1 -0
- package/dist/modules/CoreCustomization/index.d.ts +4 -1
- package/dist/modules/CoreCustomization/index.d.ts.map +1 -0
- package/dist/modules/CoreCustomization/index.js +9 -0
- package/dist/modules/CoreCustomization/locale/en.json.js +4 -0
- package/dist/modules/CoreCustomization/locale/es.json.js +4 -0
- package/dist/modules/CoreCustomization/registry/index.d.ts +1 -0
- package/dist/modules/CoreCustomization/registry/index.d.ts.map +1 -0
- package/dist/modules/CoreCustomization/registry/types/index.d.ts +1 -0
- package/dist/modules/CoreCustomization/registry/types/index.d.ts.map +1 -0
- package/dist/modules/CoreCustomization/services/base.d.ts +8 -1
- package/dist/modules/CoreCustomization/services/base.d.ts.map +1 -0
- package/dist/modules/CoreCustomization/services/base.js +21 -0
- package/dist/modules/CoreCustomization/services/index.d.ts +1 -0
- package/dist/modules/CoreCustomization/services/index.d.ts.map +1 -0
- package/dist/modules/CoreCustomization/types/CoreCustomization.d.ts +1 -0
- package/dist/modules/CoreCustomization/types/CoreCustomization.d.ts.map +1 -0
- package/dist/modules/CoreCustomization/types/index.d.ts +1 -0
- package/dist/modules/CoreCustomization/types/index.d.ts.map +1 -0
- package/dist/modules/CoreOrder/classes/CoreOrderBuilder.d.ts +4 -3
- package/dist/modules/CoreOrder/classes/CoreOrderBuilder.d.ts.map +1 -0
- package/dist/modules/CoreOrder/classes/CoreOrderBuilder.js +113 -0
- package/dist/modules/CoreOrder/classes/index.d.ts +1 -0
- package/dist/modules/CoreOrder/classes/index.d.ts.map +1 -0
- package/dist/modules/CoreOrder/index.d.ts +4 -1
- package/dist/modules/CoreOrder/index.d.ts.map +1 -0
- package/dist/modules/CoreOrder/index.js +9 -0
- package/dist/modules/CoreOrder/locale/en.json.js +4 -0
- package/dist/modules/CoreOrder/locale/es.json.js +4 -0
- package/dist/modules/CoreOrder/registry/hooks/index.d.ts +1 -0
- package/dist/modules/CoreOrder/registry/hooks/index.d.ts.map +1 -0
- package/dist/modules/CoreOrder/registry/index.d.ts +1 -0
- package/dist/modules/CoreOrder/registry/index.d.ts.map +1 -0
- package/dist/modules/CoreOrder/registry/types/index.d.ts +1 -0
- package/dist/modules/CoreOrder/registry/types/index.d.ts.map +1 -0
- package/dist/modules/CoreOrder/services/base.d.ts +17 -1
- package/dist/modules/CoreOrder/services/base.d.ts.map +1 -0
- package/dist/modules/CoreOrder/services/base.js +27 -0
- package/dist/modules/CoreOrder/services/index.d.ts +1 -0
- package/dist/modules/CoreOrder/services/index.d.ts.map +1 -0
- package/dist/modules/CoreOrder/types/CoreOrder.d.ts +1 -0
- package/dist/modules/CoreOrder/types/CoreOrder.d.ts.map +1 -0
- package/dist/modules/CoreOrder/types/index.d.ts +1 -0
- package/dist/modules/CoreOrder/types/index.d.ts.map +1 -0
- package/dist/modules/CoreOrder/types/interfaces/OrderActions.d.ts +1 -0
- package/dist/modules/CoreOrder/types/interfaces/OrderActions.d.ts.map +1 -0
- package/dist/modules/CoreOrder/types/interfaces/index.d.ts +1 -0
- package/dist/modules/CoreOrder/types/interfaces/index.d.ts.map +1 -0
- package/dist/modules/CorePayForm/classes/CorePayFormBuilder.d.ts +12 -11
- package/dist/modules/CorePayForm/classes/CorePayFormBuilder.d.ts.map +1 -0
- package/dist/modules/CorePayForm/classes/CorePayFormBuilder.js +67 -0
- package/dist/modules/CorePayForm/classes/index.d.ts +1 -0
- package/dist/modules/CorePayForm/classes/index.d.ts.map +1 -0
- package/dist/modules/CorePayForm/index.d.ts +4 -1
- package/dist/modules/CorePayForm/index.d.ts.map +1 -0
- package/dist/modules/CorePayForm/index.js +9 -0
- package/dist/modules/CorePayForm/locale/en.json.js +4 -0
- package/dist/modules/CorePayForm/locale/es.json.js +4 -0
- package/dist/modules/CorePayForm/registry/hooks/index.d.ts +1 -0
- package/dist/modules/CorePayForm/registry/hooks/index.d.ts.map +1 -0
- package/dist/modules/CorePayForm/registry/index.d.ts +1 -0
- package/dist/modules/CorePayForm/registry/index.d.ts.map +1 -0
- package/dist/modules/CorePayForm/registry/types/index.d.ts +1 -0
- package/dist/modules/CorePayForm/registry/types/index.d.ts.map +1 -0
- package/dist/modules/CorePayForm/services/base.d.ts +12 -1
- package/dist/modules/CorePayForm/services/base.d.ts.map +1 -0
- package/dist/modules/CorePayForm/services/base.js +21 -0
- package/dist/modules/CorePayForm/services/index.d.ts +1 -0
- package/dist/modules/CorePayForm/services/index.d.ts.map +1 -0
- package/dist/modules/CorePayForm/types/CorePayForm.d.ts +1 -0
- package/dist/modules/CorePayForm/types/CorePayForm.d.ts.map +1 -0
- package/dist/modules/CorePayForm/types/index.d.ts +1 -0
- package/dist/modules/CorePayForm/types/index.d.ts.map +1 -0
- package/dist/modules/CoreProduct/classes/CoreProductBuilder.d.ts +5 -4
- package/dist/modules/CoreProduct/classes/CoreProductBuilder.d.ts.map +1 -0
- package/dist/modules/CoreProduct/classes/CoreProductBuilder.js +120 -0
- package/dist/modules/CoreProduct/classes/index.d.ts +1 -0
- package/dist/modules/CoreProduct/classes/index.d.ts.map +1 -0
- package/dist/modules/CoreProduct/index.d.ts +4 -1
- package/dist/modules/CoreProduct/index.d.ts.map +1 -0
- package/dist/modules/CoreProduct/index.js +9 -0
- package/dist/modules/CoreProduct/locale/en.json.js +14 -0
- package/dist/modules/CoreProduct/locale/es.json.js +14 -0
- package/dist/modules/CoreProduct/registry/index.d.ts +1 -0
- package/dist/modules/CoreProduct/registry/index.d.ts.map +1 -0
- package/dist/modules/CoreProduct/registry/types/index.d.ts +1 -0
- package/dist/modules/CoreProduct/registry/types/index.d.ts.map +1 -0
- package/dist/modules/CoreProduct/services/base.d.ts +20 -7
- package/dist/modules/CoreProduct/services/base.d.ts.map +1 -0
- package/dist/modules/CoreProduct/services/base.js +35 -0
- package/dist/modules/CoreProduct/services/index.d.ts +1 -0
- package/dist/modules/CoreProduct/services/index.d.ts.map +1 -0
- package/dist/modules/CoreProduct/types/CoreProduct.d.ts +1 -0
- package/dist/modules/CoreProduct/types/CoreProduct.d.ts.map +1 -0
- package/dist/modules/CoreProduct/types/CoreProductCategory.d.ts +1 -0
- package/dist/modules/CoreProduct/types/CoreProductCategory.d.ts.map +1 -0
- package/dist/modules/CoreProduct/types/index.d.ts +1 -0
- package/dist/modules/CoreProduct/types/index.d.ts.map +1 -0
- package/dist/modules/CoreShipment/classes/CoreShipmentBuilder.d.ts +6 -5
- package/dist/modules/CoreShipment/classes/CoreShipmentBuilder.d.ts.map +1 -0
- package/dist/modules/CoreShipment/classes/CoreShipmentBuilder.js +172 -0
- package/dist/modules/CoreShipment/classes/index.d.ts +1 -0
- package/dist/modules/CoreShipment/classes/index.d.ts.map +1 -0
- package/dist/modules/CoreShipment/index.d.ts +4 -1
- package/dist/modules/CoreShipment/index.d.ts.map +1 -0
- package/dist/modules/CoreShipment/index.js +9 -0
- package/dist/modules/CoreShipment/locale/en.json.js +14 -0
- package/dist/modules/CoreShipment/locale/es.json.js +14 -0
- package/dist/modules/CoreShipment/registry/classes/index.d.ts +1 -0
- package/dist/modules/CoreShipment/registry/classes/index.d.ts.map +1 -0
- package/dist/modules/CoreShipment/registry/index.d.ts +1 -0
- package/dist/modules/CoreShipment/registry/index.d.ts.map +1 -0
- package/dist/modules/CoreShipment/registry/services/index.d.ts +1 -0
- package/dist/modules/CoreShipment/registry/services/index.d.ts.map +1 -0
- package/dist/modules/CoreShipment/registry/types/index.d.ts +1 -0
- package/dist/modules/CoreShipment/registry/types/index.d.ts.map +1 -0
- package/dist/modules/CoreShipment/services/base.d.ts +30 -2
- package/dist/modules/CoreShipment/services/base.d.ts.map +1 -0
- package/dist/modules/CoreShipment/services/base.js +63 -0
- package/dist/modules/CoreShipment/services/index.d.ts +1 -0
- package/dist/modules/CoreShipment/services/index.d.ts.map +1 -0
- package/dist/modules/CoreShipment/types/CoreShipment.d.ts +1 -0
- package/dist/modules/CoreShipment/types/CoreShipment.d.ts.map +1 -0
- package/dist/modules/CoreShipment/types/CoreShipment.js +7 -0
- package/dist/modules/CoreShipment/types/index.d.ts +1 -0
- package/dist/modules/CoreShipment/types/index.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/classes/CoreShopCartBuilder.d.ts +16 -5
- package/dist/modules/CoreShopCart/classes/CoreShopCartBuilder.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/classes/CoreShopCartBuilder.js +166 -0
- package/dist/modules/CoreShopCart/classes/index.d.ts +1 -0
- package/dist/modules/CoreShopCart/classes/index.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/constants/index.d.ts +1 -0
- package/dist/modules/CoreShopCart/constants/index.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/constants/shopCart.d.ts +1 -0
- package/dist/modules/CoreShopCart/constants/shopCart.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/constants/shopCart.js +8 -0
- package/dist/modules/CoreShopCart/index.d.ts +1 -0
- package/dist/modules/CoreShopCart/index.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/index.js +8 -0
- package/dist/modules/CoreShopCart/locale/en.json.js +4 -0
- package/dist/modules/CoreShopCart/locale/es.json.js +4 -0
- package/dist/modules/CoreShopCart/registry/hooks/index.d.ts +1 -0
- package/dist/modules/CoreShopCart/registry/hooks/index.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/registry/index.d.ts +1 -0
- package/dist/modules/CoreShopCart/registry/index.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/registry/types/index.d.ts +1 -0
- package/dist/modules/CoreShopCart/registry/types/index.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/services/base.d.ts +23 -4
- package/dist/modules/CoreShopCart/services/base.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/services/base.js +53 -0
- package/dist/modules/CoreShopCart/services/index.d.ts +1 -0
- package/dist/modules/CoreShopCart/services/index.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/types/CoreShopCart.d.ts +1 -0
- package/dist/modules/CoreShopCart/types/CoreShopCart.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/types/index.d.ts +1 -0
- package/dist/modules/CoreShopCart/types/index.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/types/interfaces/CartActions.d.ts +1 -0
- package/dist/modules/CoreShopCart/types/interfaces/CartActions.d.ts.map +1 -0
- package/dist/modules/CoreShopCart/types/interfaces/index.d.ts +1 -0
- package/dist/modules/CoreShopCart/types/interfaces/index.d.ts.map +1 -0
- package/dist/modules/index.d.ts +1 -0
- package/dist/modules/index.d.ts.map +1 -0
- package/dist/modules/registry/hooks/index.d.ts +1 -0
- package/dist/modules/registry/hooks/index.d.ts.map +1 -0
- package/dist/modules/registry/index.d.ts +1 -0
- package/dist/modules/registry/index.d.ts.map +1 -0
- package/dist/modules/registry/types/index.d.ts +1 -0
- package/dist/modules/registry/types/index.d.ts.map +1 -0
- package/dist/node_modules/@floating-ui/core/dist/floating-ui.core.js +814 -0
- package/dist/node_modules/@floating-ui/dom/dist/floating-ui.dom.js +751 -0
- package/dist/node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.js +350 -0
- package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.js +161 -0
- package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.js +137 -0
- package/dist/node_modules/@radix-ui/number/dist/index.js +6 -0
- package/dist/node_modules/@radix-ui/primitive/dist/index.js +11 -0
- package/dist/node_modules/@radix-ui/react-accordion/dist/index.js +305 -0
- package/dist/node_modules/@radix-ui/react-accordion/node_modules/@radix-ui/react-collapsible/dist/index.js +145 -0
- package/dist/node_modules/@radix-ui/react-accordion/node_modules/@radix-ui/react-collapsible/node_modules/@radix-ui/react-presence/dist/index.js +130 -0
- package/dist/node_modules/@radix-ui/react-accordion/node_modules/@radix-ui/react-collection/dist/index.js +70 -0
- package/dist/node_modules/@radix-ui/react-accordion/node_modules/@radix-ui/react-primitive/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-alert-dialog/dist/index.js +147 -0
- package/dist/node_modules/@radix-ui/react-avatar/dist/index.js +118 -0
- package/dist/node_modules/@radix-ui/react-avatar/node_modules/@radix-ui/react-primitive/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-checkbox/dist/index.js +270 -0
- package/dist/node_modules/@radix-ui/react-checkbox/node_modules/@radix-ui/react-presence/dist/index.js +130 -0
- package/dist/node_modules/@radix-ui/react-checkbox/node_modules/@radix-ui/react-primitive/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-compose-refs/dist/index.js +39 -0
- package/dist/node_modules/@radix-ui/react-context/dist/index.js +79 -0
- package/dist/node_modules/@radix-ui/react-dialog/dist/index.js +321 -0
- package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-dismissable-layer/dist/index.js +211 -0
- package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-focus-scope/dist/index.js +207 -0
- package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-portal/dist/index.js +17 -0
- package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-presence/dist/index.js +130 -0
- package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-primitive/dist/index.js +43 -0
- package/dist/node_modules/@radix-ui/react-direction/dist/index.js +11 -0
- package/dist/node_modules/@radix-ui/react-dropdown-menu/dist/index.js +267 -0
- package/dist/node_modules/@radix-ui/react-dropdown-menu/node_modules/@radix-ui/react-menu/dist/index.js +834 -0
- package/dist/node_modules/@radix-ui/react-dropdown-menu/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-collection/dist/index.js +70 -0
- package/dist/node_modules/@radix-ui/react-dropdown-menu/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-dismissable-layer/dist/index.js +211 -0
- package/dist/node_modules/@radix-ui/react-dropdown-menu/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-focus-scope/dist/index.js +207 -0
- package/dist/node_modules/@radix-ui/react-dropdown-menu/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-popper/dist/index.js +283 -0
- package/dist/node_modules/@radix-ui/react-dropdown-menu/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-popper/node_modules/@radix-ui/react-arrow/dist/index.js +25 -0
- package/dist/node_modules/@radix-ui/react-dropdown-menu/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-portal/dist/index.js +17 -0
- package/dist/node_modules/@radix-ui/react-dropdown-menu/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-presence/dist/index.js +130 -0
- package/dist/node_modules/@radix-ui/react-dropdown-menu/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-roving-focus/dist/index.js +223 -0
- package/dist/node_modules/@radix-ui/react-dropdown-menu/node_modules/@radix-ui/react-primitive/dist/index.js +43 -0
- package/dist/node_modules/@radix-ui/react-focus-guards/dist/index.js +29 -0
- package/dist/node_modules/@radix-ui/react-id/dist/index.js +15 -0
- package/dist/node_modules/@radix-ui/react-label/dist/index.js +24 -0
- package/dist/node_modules/@radix-ui/react-label/node_modules/@radix-ui/react-primitive/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-popover/dist/index.js +299 -0
- package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-dismissable-layer/dist/index.js +211 -0
- package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-focus-scope/dist/index.js +207 -0
- package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-popper/dist/index.js +283 -0
- package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-popper/node_modules/@radix-ui/react-arrow/dist/index.js +25 -0
- package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-portal/dist/index.js +17 -0
- package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-presence/dist/index.js +130 -0
- package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-primitive/dist/index.js +43 -0
- package/dist/node_modules/@radix-ui/react-radio-group/dist/index.js +282 -0
- package/dist/node_modules/@radix-ui/react-radio-group/node_modules/@radix-ui/react-presence/dist/index.js +130 -0
- package/dist/node_modules/@radix-ui/react-radio-group/node_modules/@radix-ui/react-primitive/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-radio-group/node_modules/@radix-ui/react-roving-focus/dist/index.js +223 -0
- package/dist/node_modules/@radix-ui/react-radio-group/node_modules/@radix-ui/react-roving-focus/node_modules/@radix-ui/react-collection/dist/index.js +70 -0
- package/dist/node_modules/@radix-ui/react-select/dist/index.js +1156 -0
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-collection/dist/index.js +70 -0
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-dismissable-layer/dist/index.js +211 -0
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-focus-scope/dist/index.js +207 -0
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-popper/dist/index.js +283 -0
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-popper/node_modules/@radix-ui/react-arrow/dist/index.js +25 -0
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-portal/dist/index.js +17 -0
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-primitive/dist/index.js +43 -0
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-visually-hidden/dist/index.js +34 -0
- package/dist/node_modules/@radix-ui/react-separator/dist/index.js +30 -0
- package/dist/node_modules/@radix-ui/react-separator/node_modules/@radix-ui/react-primitive/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-slider/dist/index.js +554 -0
- package/dist/node_modules/@radix-ui/react-slider/node_modules/@radix-ui/react-collection/dist/index.js +70 -0
- package/dist/node_modules/@radix-ui/react-slider/node_modules/@radix-ui/react-primitive/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-slot/dist/index.js +99 -0
- package/dist/node_modules/@radix-ui/react-switch/dist/index.js +152 -0
- package/dist/node_modules/@radix-ui/react-switch/node_modules/@radix-ui/react-primitive/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-tabs/dist/index.js +187 -0
- package/dist/node_modules/@radix-ui/react-tabs/node_modules/@radix-ui/react-presence/dist/index.js +130 -0
- package/dist/node_modules/@radix-ui/react-tabs/node_modules/@radix-ui/react-primitive/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-tabs/node_modules/@radix-ui/react-roving-focus/dist/index.js +223 -0
- package/dist/node_modules/@radix-ui/react-tabs/node_modules/@radix-ui/react-roving-focus/node_modules/@radix-ui/react-collection/dist/index.js +70 -0
- package/dist/node_modules/@radix-ui/react-tooltip/dist/index.js +482 -0
- package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-dismissable-layer/dist/index.js +211 -0
- package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-popper/dist/index.js +283 -0
- package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-popper/node_modules/@radix-ui/react-arrow/dist/index.js +25 -0
- package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-presence/dist/index.js +130 -0
- package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-primitive/dist/index.js +43 -0
- package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-visually-hidden/dist/index.js +35 -0
- package/dist/node_modules/@radix-ui/react-use-callback-ref/dist/index.js +12 -0
- package/dist/node_modules/@radix-ui/react-use-controllable-state/dist/index.js +70 -0
- package/dist/node_modules/@radix-ui/react-use-escape-keydown/dist/index.js +18 -0
- package/dist/node_modules/@radix-ui/react-use-is-hydrated/dist/index.js +16 -0
- package/dist/node_modules/@radix-ui/react-use-layout-effect/dist/index.js +7 -0
- package/dist/node_modules/@radix-ui/react-use-previous/dist/index.js +15 -0
- package/dist/node_modules/@radix-ui/react-use-size/dist/index.js +40 -0
- package/dist/node_modules/@stepperize/core/dist/index.js +3 -0
- package/dist/node_modules/@stepperize/react/dist/index.js +6 -0
- package/dist/node_modules/aria-hidden/dist/es2015/index.js +137 -0
- package/dist/node_modules/axios/index.js +25 -0
- package/dist/node_modules/axios/lib/adapters/adapters.js +81 -0
- package/dist/node_modules/axios/lib/adapters/fetch.js +229 -0
- package/dist/node_modules/axios/lib/adapters/xhr.js +199 -0
- package/dist/node_modules/axios/lib/axios.js +86 -0
- package/dist/node_modules/axios/lib/cancel/CancelToken.js +133 -0
- package/dist/node_modules/axios/lib/cancel/CanceledError.js +23 -0
- package/dist/node_modules/axios/lib/cancel/isCancel.js +5 -0
- package/dist/node_modules/axios/lib/core/Axios.js +238 -0
- package/dist/node_modules/axios/lib/core/AxiosError.js +101 -0
- package/dist/node_modules/axios/lib/core/AxiosHeaders.js +312 -0
- package/dist/node_modules/axios/lib/core/InterceptorManager.js +69 -0
- package/dist/node_modules/axios/lib/core/buildFullPath.js +22 -0
- package/dist/node_modules/axios/lib/core/dispatchRequest.js +81 -0
- package/dist/node_modules/axios/lib/core/mergeConfig.js +106 -0
- package/dist/node_modules/axios/lib/core/settle.js +27 -0
- package/dist/node_modules/axios/lib/core/transformData.js +28 -0
- package/dist/node_modules/axios/lib/defaults/index.js +159 -0
- package/dist/node_modules/axios/lib/defaults/transitional.js +7 -0
- package/dist/node_modules/axios/lib/env/data.js +3 -0
- package/dist/node_modules/axios/lib/helpers/AxiosURLSearchParams.js +56 -0
- package/dist/node_modules/axios/lib/helpers/HttpStatusCode.js +71 -0
- package/dist/node_modules/axios/lib/helpers/bind.js +7 -0
- package/dist/node_modules/axios/lib/helpers/buildURL.js +69 -0
- package/dist/node_modules/axios/lib/helpers/combineURLs.js +15 -0
- package/dist/node_modules/axios/lib/helpers/composeSignals.js +48 -0
- package/dist/node_modules/axios/lib/helpers/cookies.js +43 -0
- package/dist/node_modules/axios/lib/helpers/formDataToJSON.js +93 -0
- package/dist/node_modules/axios/lib/helpers/isAbsoluteURL.js +15 -0
- package/dist/node_modules/axios/lib/helpers/isAxiosError.js +14 -0
- package/dist/node_modules/axios/lib/helpers/isURLSameOrigin.js +16 -0
- package/dist/node_modules/axios/lib/helpers/null.js +4 -0
- package/dist/node_modules/axios/lib/helpers/parseHeaders.js +55 -0
- package/dist/node_modules/axios/lib/helpers/parseProtocol.js +6 -0
- package/dist/node_modules/axios/lib/helpers/progressEventReducer.js +46 -0
- package/dist/node_modules/axios/lib/helpers/resolveConfig.js +58 -0
- package/dist/node_modules/axios/lib/helpers/speedometer.js +53 -0
- package/dist/node_modules/axios/lib/helpers/spread.js +28 -0
- package/dist/node_modules/axios/lib/helpers/throttle.js +44 -0
- package/dist/node_modules/axios/lib/helpers/toFormData.js +219 -0
- package/dist/node_modules/axios/lib/helpers/toURLEncodedForm.js +19 -0
- package/dist/node_modules/axios/lib/helpers/trackStream.js +88 -0
- package/dist/node_modules/axios/lib/helpers/validator.js +99 -0
- package/dist/node_modules/axios/lib/platform/browser/classes/Blob.js +3 -0
- package/dist/node_modules/axios/lib/platform/browser/classes/FormData.js +3 -0
- package/dist/node_modules/axios/lib/platform/browser/classes/URLSearchParams.js +5 -0
- package/dist/node_modules/axios/lib/platform/browser/index.js +15 -0
- package/dist/node_modules/axios/lib/platform/common/utils.js +45 -0
- package/dist/node_modules/axios/lib/platform/index.js +9 -0
- package/dist/node_modules/axios/lib/utils.js +780 -0
- package/dist/node_modules/class-variance-authority/dist/index.js +44 -0
- package/dist/node_modules/clsx/dist/clsx.js +3 -0
- package/dist/node_modules/embla-carousel/esm/embla-carousel.esm.js +1669 -0
- package/dist/node_modules/embla-carousel-react/esm/embla-carousel-react.esm.js +37 -0
- package/dist/node_modules/embla-carousel-reactive-utils/esm/embla-carousel-reactive-utils.esm.js +38 -0
- package/dist/node_modules/get-nonce/dist/es2015/index.js +8 -0
- package/dist/node_modules/lucide-react/dist/esm/Icon.js +43 -0
- package/dist/node_modules/lucide-react/dist/esm/createLucideIcon.js +30 -0
- package/dist/node_modules/lucide-react/dist/esm/defaultAttributes.js +20 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/arrow-left.js +17 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/arrow-right.js +17 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/check.js +14 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/chevron-down.js +14 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/chevron-left.js +14 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/chevron-right.js +14 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/chevron-up.js +14 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle.js +14 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/ellipsis.js +18 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/x.js +17 -0
- package/dist/node_modules/lucide-react/dist/esm/shared/src/utils.js +28 -0
- package/dist/node_modules/react-hook-form/dist/index.esm.js +560 -0
- package/dist/node_modules/react-i18next/dist/es/IcuTransUtils/htmlEntityDecoder.js +210 -0
- package/dist/node_modules/react-i18next/dist/es/context.js +18 -0
- package/dist/node_modules/react-i18next/dist/es/defaults.js +21 -0
- package/dist/node_modules/react-i18next/dist/es/i18nInstance.js +7 -0
- package/dist/node_modules/react-i18next/dist/es/initReactI18next.js +12 -0
- package/dist/node_modules/react-i18next/dist/es/unescape.js +27 -0
- package/dist/node_modules/react-i18next/dist/es/useTranslation.js +157 -0
- package/dist/node_modules/react-i18next/dist/es/utils.js +63 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/Combination.js +9 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/SideEffect.js +167 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/UI.js +38 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js +21 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/handleScroll.js +110 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/medium.js +5 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/sidecar.js +7 -0
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/component.js +56 -0
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/constants.js +10 -0
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/utils.js +31 -0
- package/dist/node_modules/react-style-singleton/dist/es2015/component.js +19 -0
- package/dist/node_modules/react-style-singleton/dist/es2015/hook.js +25 -0
- package/dist/node_modules/react-style-singleton/dist/es2015/singleton.js +51 -0
- package/dist/node_modules/sonner/dist/index.js +299 -0
- package/dist/node_modules/tslib/tslib.es6.js +56 -0
- package/dist/node_modules/use-callback-ref/dist/es2015/assignRef.js +24 -0
- package/dist/node_modules/use-callback-ref/dist/es2015/useMergeRef.js +48 -0
- package/dist/node_modules/use-callback-ref/dist/es2015/useRef.js +42 -0
- package/dist/node_modules/use-sidecar/dist/es2015/exports.js +21 -0
- package/dist/node_modules/use-sidecar/dist/es2015/medium.js +77 -0
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js +106 -0
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js +77 -0
- package/dist/node_modules/use-sync-external-store/shim/index.js +19 -0
- package/dist/node_modules/zustand/esm/middleware.js +188 -0
- package/dist/node_modules/zustand/esm/react.js +22 -0
- package/dist/node_modules/zustand/esm/vanilla.js +24 -0
- package/dist/services/base.d.ts +1 -0
- package/dist/services/base.d.ts.map +1 -0
- package/dist/services/base.js +67 -0
- package/dist/services/factory.d.ts +14 -0
- package/dist/services/factory.d.ts.map +1 -0
- package/dist/services/factory.js +39 -0
- package/dist/services/index.d.ts +2 -0
- package/dist/services/index.d.ts.map +1 -0
- package/dist/stores/customizationStore.d.ts +5 -27
- package/dist/stores/customizationStore.d.ts.map +1 -0
- package/dist/stores/customizationStore.js +7 -0
- package/dist/stores/index.d.ts +1 -0
- package/dist/stores/index.d.ts.map +1 -0
- package/dist/styles/index.d.ts +1 -0
- package/dist/styles/index.d.ts.map +1 -0
- package/dist/types/BaseResponseActions.d.ts +1 -0
- package/dist/types/BaseResponseActions.d.ts.map +1 -0
- package/dist/types/BaseStore.d.ts +1 -0
- package/dist/types/BaseStore.d.ts.map +1 -0
- package/dist/types/BaseType.d.ts +1 -0
- package/dist/types/BaseType.d.ts.map +1 -0
- package/dist/types/CoreImage.d.ts +1 -0
- package/dist/types/CoreImage.d.ts.map +1 -0
- package/dist/types/CoreMenu.d.ts +1 -0
- package/dist/types/CoreMenu.d.ts.map +1 -0
- package/dist/types/contracts/BaseApiResponse.d.ts +1 -0
- package/dist/types/contracts/BaseApiResponse.d.ts.map +1 -0
- package/dist/types/contracts/BasePagination.d.ts +1 -0
- package/dist/types/contracts/BasePagination.d.ts.map +1 -0
- package/dist/types/contracts/index.d.ts +1 -0
- package/dist/types/contracts/index.d.ts.map +1 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/interfaces/BaseImageType.d.ts +1 -0
- package/dist/types/interfaces/BaseImageType.d.ts.map +1 -0
- package/dist/types/interfaces/BaseSlugType.d.ts +1 -0
- package/dist/types/interfaces/BaseSlugType.d.ts.map +1 -0
- package/dist/types/interfaces/BaseVisibleType.d.ts +1 -0
- package/dist/types/interfaces/BaseVisibleType.d.ts.map +1 -0
- package/dist/types/interfaces/index.d.ts +1 -0
- package/dist/types/interfaces/index.d.ts.map +1 -0
- package/dist/types/ui/carousel.d.ts +1 -0
- package/dist/types/ui/carousel.d.ts.map +1 -0
- package/dist/types/ui/index.d.ts +1 -0
- package/dist/types/ui/index.d.ts.map +1 -0
- package/dist/types/ui/main.d.ts +1 -0
- package/dist/types/ui/main.d.ts.map +1 -0
- package/dist/types/ui/template.d.ts +1 -0
- package/dist/types/ui/template.d.ts.map +1 -0
- package/dist/ui/index.d.ts +1 -0
- package/dist/ui/index.d.ts.map +1 -0
- package/dist/vite-env.d.ts +11 -0
- package/package.json +18 -11
- package/core/commands/common/constants.js +0 -10
- package/core/commands/create-core-module.js +0 -288
- package/core/commands/create-module.js +0 -288
- package/core/commands/create-template.js +0 -169
- package/core/commands/helpers/index.js +0 -15
- package/core/commands/helpers/strings.js +0 -4
- package/core/commands/rollback-core-module.js +0 -195
- package/core/commands/rollback-module.js +0 -208
- package/core/commands/templates/locale.js +0 -14
- package/core/commands/templates/service.js +0 -12
- package/core/commands/templates/type.js +0 -10
- package/dist/assets/index.d.ts +0 -8
- package/dist/components/ui/calendar.d.ts +0 -4
- package/dist/components/ui/drawer.d.ts +0 -13
- package/dist/components/ui/navigation-menu.d.ts +0 -14
- package/dist/components/ui/sidebar.d.ts +0 -69
- package/dist/components/ui/sonner.d.ts +0 -3
- package/dist/constants/menu.d.ts +0 -2
- package/dist/helpers/template.d.ts +0 -2
- package/dist/helpers/tenant.d.ts +0 -2
- package/dist/index.css +0 -1
- package/dist/modules/CoreCustomization/registry/hooks/index.d.ts +0 -0
- package/dist/modules/CoreProduct/registry/hooks/index.d.ts +0 -0
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import React__default from 'react';
|
|
2
|
+
import { createContextScope } from '../../../../../react-context/dist/index.js';
|
|
3
|
+
import { useComposedRefs } from '../../../../../react-compose-refs/dist/index.js';
|
|
4
|
+
import { createSlot } from '../../../../../react-slot/dist/index.js';
|
|
5
|
+
import { jsx } from 'react/jsx-runtime';
|
|
6
|
+
|
|
7
|
+
function createCollection(name) {
|
|
8
|
+
const PROVIDER_NAME = name + "CollectionProvider";
|
|
9
|
+
const [createCollectionContext, createCollectionScope] = createContextScope(PROVIDER_NAME);
|
|
10
|
+
const [CollectionProviderImpl, useCollectionContext] = createCollectionContext(
|
|
11
|
+
PROVIDER_NAME,
|
|
12
|
+
{ collectionRef: { current: null }, itemMap: /* @__PURE__ */ new Map() }
|
|
13
|
+
);
|
|
14
|
+
const CollectionProvider = (props) => {
|
|
15
|
+
const { scope, children } = props;
|
|
16
|
+
const ref = React__default.useRef(null);
|
|
17
|
+
const itemMap = React__default.useRef(/* @__PURE__ */ new Map()).current;
|
|
18
|
+
return /* @__PURE__ */ jsx(CollectionProviderImpl, { scope, itemMap, collectionRef: ref, children });
|
|
19
|
+
};
|
|
20
|
+
CollectionProvider.displayName = PROVIDER_NAME;
|
|
21
|
+
const COLLECTION_SLOT_NAME = name + "CollectionSlot";
|
|
22
|
+
const CollectionSlotImpl = createSlot(COLLECTION_SLOT_NAME);
|
|
23
|
+
const CollectionSlot = React__default.forwardRef(
|
|
24
|
+
(props, forwardedRef) => {
|
|
25
|
+
const { scope, children } = props;
|
|
26
|
+
const context = useCollectionContext(COLLECTION_SLOT_NAME, scope);
|
|
27
|
+
const composedRefs = useComposedRefs(forwardedRef, context.collectionRef);
|
|
28
|
+
return /* @__PURE__ */ jsx(CollectionSlotImpl, { ref: composedRefs, children });
|
|
29
|
+
}
|
|
30
|
+
);
|
|
31
|
+
CollectionSlot.displayName = COLLECTION_SLOT_NAME;
|
|
32
|
+
const ITEM_SLOT_NAME = name + "CollectionItemSlot";
|
|
33
|
+
const ITEM_DATA_ATTR = "data-radix-collection-item";
|
|
34
|
+
const CollectionItemSlotImpl = createSlot(ITEM_SLOT_NAME);
|
|
35
|
+
const CollectionItemSlot = React__default.forwardRef(
|
|
36
|
+
(props, forwardedRef) => {
|
|
37
|
+
const { scope, children, ...itemData } = props;
|
|
38
|
+
const ref = React__default.useRef(null);
|
|
39
|
+
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
40
|
+
const context = useCollectionContext(ITEM_SLOT_NAME, scope);
|
|
41
|
+
React__default.useEffect(() => {
|
|
42
|
+
context.itemMap.set(ref, { ref, ...itemData });
|
|
43
|
+
return () => void context.itemMap.delete(ref);
|
|
44
|
+
});
|
|
45
|
+
return /* @__PURE__ */ jsx(CollectionItemSlotImpl, { ...{ [ITEM_DATA_ATTR]: "" }, ref: composedRefs, children });
|
|
46
|
+
}
|
|
47
|
+
);
|
|
48
|
+
CollectionItemSlot.displayName = ITEM_SLOT_NAME;
|
|
49
|
+
function useCollection(scope) {
|
|
50
|
+
const context = useCollectionContext(name + "CollectionConsumer", scope);
|
|
51
|
+
const getItems = React__default.useCallback(() => {
|
|
52
|
+
const collectionNode = context.collectionRef.current;
|
|
53
|
+
if (!collectionNode) return [];
|
|
54
|
+
const orderedNodes = Array.from(collectionNode.querySelectorAll(`[${ITEM_DATA_ATTR}]`));
|
|
55
|
+
const items = Array.from(context.itemMap.values());
|
|
56
|
+
const orderedItems = items.sort(
|
|
57
|
+
(a, b) => orderedNodes.indexOf(a.ref.current) - orderedNodes.indexOf(b.ref.current)
|
|
58
|
+
);
|
|
59
|
+
return orderedItems;
|
|
60
|
+
}, [context.collectionRef, context.itemMap]);
|
|
61
|
+
return getItems;
|
|
62
|
+
}
|
|
63
|
+
return [
|
|
64
|
+
{ Provider: CollectionProvider, Slot: CollectionSlot, ItemSlot: CollectionItemSlot },
|
|
65
|
+
useCollection,
|
|
66
|
+
createCollectionScope
|
|
67
|
+
];
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
export { createCollection };
|
|
@@ -0,0 +1,211 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { composeEventHandlers } from '../../../../../primitive/dist/index.js';
|
|
3
|
+
import { Primitive, dispatchDiscreteCustomEvent } from '../../react-primitive/dist/index.js';
|
|
4
|
+
import { useComposedRefs } from '../../../../../react-compose-refs/dist/index.js';
|
|
5
|
+
import { useCallbackRef } from '../../../../../react-use-callback-ref/dist/index.js';
|
|
6
|
+
import { useEscapeKeydown } from '../../../../../react-use-escape-keydown/dist/index.js';
|
|
7
|
+
import { jsx } from 'react/jsx-runtime';
|
|
8
|
+
|
|
9
|
+
var DISMISSABLE_LAYER_NAME = "DismissableLayer";
|
|
10
|
+
var CONTEXT_UPDATE = "dismissableLayer.update";
|
|
11
|
+
var POINTER_DOWN_OUTSIDE = "dismissableLayer.pointerDownOutside";
|
|
12
|
+
var FOCUS_OUTSIDE = "dismissableLayer.focusOutside";
|
|
13
|
+
var originalBodyPointerEvents;
|
|
14
|
+
var DismissableLayerContext = React.createContext({
|
|
15
|
+
layers: /* @__PURE__ */ new Set(),
|
|
16
|
+
layersWithOutsidePointerEventsDisabled: /* @__PURE__ */ new Set(),
|
|
17
|
+
branches: /* @__PURE__ */ new Set()
|
|
18
|
+
});
|
|
19
|
+
var DismissableLayer = React.forwardRef(
|
|
20
|
+
(props, forwardedRef) => {
|
|
21
|
+
const {
|
|
22
|
+
disableOutsidePointerEvents = false,
|
|
23
|
+
onEscapeKeyDown,
|
|
24
|
+
onPointerDownOutside,
|
|
25
|
+
onFocusOutside,
|
|
26
|
+
onInteractOutside,
|
|
27
|
+
onDismiss,
|
|
28
|
+
...layerProps
|
|
29
|
+
} = props;
|
|
30
|
+
const context = React.useContext(DismissableLayerContext);
|
|
31
|
+
const [node, setNode] = React.useState(null);
|
|
32
|
+
const ownerDocument = node?.ownerDocument ?? globalThis?.document;
|
|
33
|
+
const [, force] = React.useState({});
|
|
34
|
+
const composedRefs = useComposedRefs(forwardedRef, (node2) => setNode(node2));
|
|
35
|
+
const layers = Array.from(context.layers);
|
|
36
|
+
const [highestLayerWithOutsidePointerEventsDisabled] = [...context.layersWithOutsidePointerEventsDisabled].slice(-1);
|
|
37
|
+
const highestLayerWithOutsidePointerEventsDisabledIndex = layers.indexOf(highestLayerWithOutsidePointerEventsDisabled);
|
|
38
|
+
const index = node ? layers.indexOf(node) : -1;
|
|
39
|
+
const isBodyPointerEventsDisabled = context.layersWithOutsidePointerEventsDisabled.size > 0;
|
|
40
|
+
const isPointerEventsEnabled = index >= highestLayerWithOutsidePointerEventsDisabledIndex;
|
|
41
|
+
const pointerDownOutside = usePointerDownOutside((event) => {
|
|
42
|
+
const target = event.target;
|
|
43
|
+
const isPointerDownOnBranch = [...context.branches].some((branch) => branch.contains(target));
|
|
44
|
+
if (!isPointerEventsEnabled || isPointerDownOnBranch) return;
|
|
45
|
+
onPointerDownOutside?.(event);
|
|
46
|
+
onInteractOutside?.(event);
|
|
47
|
+
if (!event.defaultPrevented) onDismiss?.();
|
|
48
|
+
}, ownerDocument);
|
|
49
|
+
const focusOutside = useFocusOutside((event) => {
|
|
50
|
+
const target = event.target;
|
|
51
|
+
const isFocusInBranch = [...context.branches].some((branch) => branch.contains(target));
|
|
52
|
+
if (isFocusInBranch) return;
|
|
53
|
+
onFocusOutside?.(event);
|
|
54
|
+
onInteractOutside?.(event);
|
|
55
|
+
if (!event.defaultPrevented) onDismiss?.();
|
|
56
|
+
}, ownerDocument);
|
|
57
|
+
useEscapeKeydown((event) => {
|
|
58
|
+
const isHighestLayer = index === context.layers.size - 1;
|
|
59
|
+
if (!isHighestLayer) return;
|
|
60
|
+
onEscapeKeyDown?.(event);
|
|
61
|
+
if (!event.defaultPrevented && onDismiss) {
|
|
62
|
+
event.preventDefault();
|
|
63
|
+
onDismiss();
|
|
64
|
+
}
|
|
65
|
+
}, ownerDocument);
|
|
66
|
+
React.useEffect(() => {
|
|
67
|
+
if (!node) return;
|
|
68
|
+
if (disableOutsidePointerEvents) {
|
|
69
|
+
if (context.layersWithOutsidePointerEventsDisabled.size === 0) {
|
|
70
|
+
originalBodyPointerEvents = ownerDocument.body.style.pointerEvents;
|
|
71
|
+
ownerDocument.body.style.pointerEvents = "none";
|
|
72
|
+
}
|
|
73
|
+
context.layersWithOutsidePointerEventsDisabled.add(node);
|
|
74
|
+
}
|
|
75
|
+
context.layers.add(node);
|
|
76
|
+
dispatchUpdate();
|
|
77
|
+
return () => {
|
|
78
|
+
if (disableOutsidePointerEvents && context.layersWithOutsidePointerEventsDisabled.size === 1) {
|
|
79
|
+
ownerDocument.body.style.pointerEvents = originalBodyPointerEvents;
|
|
80
|
+
}
|
|
81
|
+
};
|
|
82
|
+
}, [node, ownerDocument, disableOutsidePointerEvents, context]);
|
|
83
|
+
React.useEffect(() => {
|
|
84
|
+
return () => {
|
|
85
|
+
if (!node) return;
|
|
86
|
+
context.layers.delete(node);
|
|
87
|
+
context.layersWithOutsidePointerEventsDisabled.delete(node);
|
|
88
|
+
dispatchUpdate();
|
|
89
|
+
};
|
|
90
|
+
}, [node, context]);
|
|
91
|
+
React.useEffect(() => {
|
|
92
|
+
const handleUpdate = () => force({});
|
|
93
|
+
document.addEventListener(CONTEXT_UPDATE, handleUpdate);
|
|
94
|
+
return () => document.removeEventListener(CONTEXT_UPDATE, handleUpdate);
|
|
95
|
+
}, []);
|
|
96
|
+
return /* @__PURE__ */ jsx(
|
|
97
|
+
Primitive.div,
|
|
98
|
+
{
|
|
99
|
+
...layerProps,
|
|
100
|
+
ref: composedRefs,
|
|
101
|
+
style: {
|
|
102
|
+
pointerEvents: isBodyPointerEventsDisabled ? isPointerEventsEnabled ? "auto" : "none" : void 0,
|
|
103
|
+
...props.style
|
|
104
|
+
},
|
|
105
|
+
onFocusCapture: composeEventHandlers(props.onFocusCapture, focusOutside.onFocusCapture),
|
|
106
|
+
onBlurCapture: composeEventHandlers(props.onBlurCapture, focusOutside.onBlurCapture),
|
|
107
|
+
onPointerDownCapture: composeEventHandlers(
|
|
108
|
+
props.onPointerDownCapture,
|
|
109
|
+
pointerDownOutside.onPointerDownCapture
|
|
110
|
+
)
|
|
111
|
+
}
|
|
112
|
+
);
|
|
113
|
+
}
|
|
114
|
+
);
|
|
115
|
+
DismissableLayer.displayName = DISMISSABLE_LAYER_NAME;
|
|
116
|
+
var BRANCH_NAME = "DismissableLayerBranch";
|
|
117
|
+
var DismissableLayerBranch = React.forwardRef((props, forwardedRef) => {
|
|
118
|
+
const context = React.useContext(DismissableLayerContext);
|
|
119
|
+
const ref = React.useRef(null);
|
|
120
|
+
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
121
|
+
React.useEffect(() => {
|
|
122
|
+
const node = ref.current;
|
|
123
|
+
if (node) {
|
|
124
|
+
context.branches.add(node);
|
|
125
|
+
return () => {
|
|
126
|
+
context.branches.delete(node);
|
|
127
|
+
};
|
|
128
|
+
}
|
|
129
|
+
}, [context.branches]);
|
|
130
|
+
return /* @__PURE__ */ jsx(Primitive.div, { ...props, ref: composedRefs });
|
|
131
|
+
});
|
|
132
|
+
DismissableLayerBranch.displayName = BRANCH_NAME;
|
|
133
|
+
function usePointerDownOutside(onPointerDownOutside, ownerDocument = globalThis?.document) {
|
|
134
|
+
const handlePointerDownOutside = useCallbackRef(onPointerDownOutside);
|
|
135
|
+
const isPointerInsideReactTreeRef = React.useRef(false);
|
|
136
|
+
const handleClickRef = React.useRef(() => {
|
|
137
|
+
});
|
|
138
|
+
React.useEffect(() => {
|
|
139
|
+
const handlePointerDown = (event) => {
|
|
140
|
+
if (event.target && !isPointerInsideReactTreeRef.current) {
|
|
141
|
+
let handleAndDispatchPointerDownOutsideEvent2 = function() {
|
|
142
|
+
handleAndDispatchCustomEvent(
|
|
143
|
+
POINTER_DOWN_OUTSIDE,
|
|
144
|
+
handlePointerDownOutside,
|
|
145
|
+
eventDetail,
|
|
146
|
+
{ discrete: true }
|
|
147
|
+
);
|
|
148
|
+
};
|
|
149
|
+
const eventDetail = { originalEvent: event };
|
|
150
|
+
if (event.pointerType === "touch") {
|
|
151
|
+
ownerDocument.removeEventListener("click", handleClickRef.current);
|
|
152
|
+
handleClickRef.current = handleAndDispatchPointerDownOutsideEvent2;
|
|
153
|
+
ownerDocument.addEventListener("click", handleClickRef.current, { once: true });
|
|
154
|
+
} else {
|
|
155
|
+
handleAndDispatchPointerDownOutsideEvent2();
|
|
156
|
+
}
|
|
157
|
+
} else {
|
|
158
|
+
ownerDocument.removeEventListener("click", handleClickRef.current);
|
|
159
|
+
}
|
|
160
|
+
isPointerInsideReactTreeRef.current = false;
|
|
161
|
+
};
|
|
162
|
+
const timerId = window.setTimeout(() => {
|
|
163
|
+
ownerDocument.addEventListener("pointerdown", handlePointerDown);
|
|
164
|
+
}, 0);
|
|
165
|
+
return () => {
|
|
166
|
+
window.clearTimeout(timerId);
|
|
167
|
+
ownerDocument.removeEventListener("pointerdown", handlePointerDown);
|
|
168
|
+
ownerDocument.removeEventListener("click", handleClickRef.current);
|
|
169
|
+
};
|
|
170
|
+
}, [ownerDocument, handlePointerDownOutside]);
|
|
171
|
+
return {
|
|
172
|
+
// ensures we check React component tree (not just DOM tree)
|
|
173
|
+
onPointerDownCapture: () => isPointerInsideReactTreeRef.current = true
|
|
174
|
+
};
|
|
175
|
+
}
|
|
176
|
+
function useFocusOutside(onFocusOutside, ownerDocument = globalThis?.document) {
|
|
177
|
+
const handleFocusOutside = useCallbackRef(onFocusOutside);
|
|
178
|
+
const isFocusInsideReactTreeRef = React.useRef(false);
|
|
179
|
+
React.useEffect(() => {
|
|
180
|
+
const handleFocus = (event) => {
|
|
181
|
+
if (event.target && !isFocusInsideReactTreeRef.current) {
|
|
182
|
+
const eventDetail = { originalEvent: event };
|
|
183
|
+
handleAndDispatchCustomEvent(FOCUS_OUTSIDE, handleFocusOutside, eventDetail, {
|
|
184
|
+
discrete: false
|
|
185
|
+
});
|
|
186
|
+
}
|
|
187
|
+
};
|
|
188
|
+
ownerDocument.addEventListener("focusin", handleFocus);
|
|
189
|
+
return () => ownerDocument.removeEventListener("focusin", handleFocus);
|
|
190
|
+
}, [ownerDocument, handleFocusOutside]);
|
|
191
|
+
return {
|
|
192
|
+
onFocusCapture: () => isFocusInsideReactTreeRef.current = true,
|
|
193
|
+
onBlurCapture: () => isFocusInsideReactTreeRef.current = false
|
|
194
|
+
};
|
|
195
|
+
}
|
|
196
|
+
function dispatchUpdate() {
|
|
197
|
+
const event = new CustomEvent(CONTEXT_UPDATE);
|
|
198
|
+
document.dispatchEvent(event);
|
|
199
|
+
}
|
|
200
|
+
function handleAndDispatchCustomEvent(name, handler, detail, { discrete }) {
|
|
201
|
+
const target = detail.originalEvent.target;
|
|
202
|
+
const event = new CustomEvent(name, { bubbles: false, cancelable: true, detail });
|
|
203
|
+
if (handler) target.addEventListener(name, handler, { once: true });
|
|
204
|
+
if (discrete) {
|
|
205
|
+
dispatchDiscreteCustomEvent(target, event);
|
|
206
|
+
} else {
|
|
207
|
+
target.dispatchEvent(event);
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
export { DismissableLayer, DismissableLayerBranch };
|
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { useComposedRefs } from '../../../../../react-compose-refs/dist/index.js';
|
|
3
|
+
import { Primitive } from '../../react-primitive/dist/index.js';
|
|
4
|
+
import { useCallbackRef } from '../../../../../react-use-callback-ref/dist/index.js';
|
|
5
|
+
import { jsx } from 'react/jsx-runtime';
|
|
6
|
+
|
|
7
|
+
var AUTOFOCUS_ON_MOUNT = "focusScope.autoFocusOnMount";
|
|
8
|
+
var AUTOFOCUS_ON_UNMOUNT = "focusScope.autoFocusOnUnmount";
|
|
9
|
+
var EVENT_OPTIONS = { bubbles: false, cancelable: true };
|
|
10
|
+
var FOCUS_SCOPE_NAME = "FocusScope";
|
|
11
|
+
var FocusScope = React.forwardRef((props, forwardedRef) => {
|
|
12
|
+
const {
|
|
13
|
+
loop = false,
|
|
14
|
+
trapped = false,
|
|
15
|
+
onMountAutoFocus: onMountAutoFocusProp,
|
|
16
|
+
onUnmountAutoFocus: onUnmountAutoFocusProp,
|
|
17
|
+
...scopeProps
|
|
18
|
+
} = props;
|
|
19
|
+
const [container, setContainer] = React.useState(null);
|
|
20
|
+
const onMountAutoFocus = useCallbackRef(onMountAutoFocusProp);
|
|
21
|
+
const onUnmountAutoFocus = useCallbackRef(onUnmountAutoFocusProp);
|
|
22
|
+
const lastFocusedElementRef = React.useRef(null);
|
|
23
|
+
const composedRefs = useComposedRefs(forwardedRef, (node) => setContainer(node));
|
|
24
|
+
const focusScope = React.useRef({
|
|
25
|
+
paused: false,
|
|
26
|
+
pause() {
|
|
27
|
+
this.paused = true;
|
|
28
|
+
},
|
|
29
|
+
resume() {
|
|
30
|
+
this.paused = false;
|
|
31
|
+
}
|
|
32
|
+
}).current;
|
|
33
|
+
React.useEffect(() => {
|
|
34
|
+
if (trapped) {
|
|
35
|
+
let handleFocusIn2 = function(event) {
|
|
36
|
+
if (focusScope.paused || !container) return;
|
|
37
|
+
const target = event.target;
|
|
38
|
+
if (container.contains(target)) {
|
|
39
|
+
lastFocusedElementRef.current = target;
|
|
40
|
+
} else {
|
|
41
|
+
focus(lastFocusedElementRef.current, { select: true });
|
|
42
|
+
}
|
|
43
|
+
}, handleFocusOut2 = function(event) {
|
|
44
|
+
if (focusScope.paused || !container) return;
|
|
45
|
+
const relatedTarget = event.relatedTarget;
|
|
46
|
+
if (relatedTarget === null) return;
|
|
47
|
+
if (!container.contains(relatedTarget)) {
|
|
48
|
+
focus(lastFocusedElementRef.current, { select: true });
|
|
49
|
+
}
|
|
50
|
+
}, handleMutations2 = function(mutations) {
|
|
51
|
+
const focusedElement = document.activeElement;
|
|
52
|
+
if (focusedElement !== document.body) return;
|
|
53
|
+
for (const mutation of mutations) {
|
|
54
|
+
if (mutation.removedNodes.length > 0) focus(container);
|
|
55
|
+
}
|
|
56
|
+
};
|
|
57
|
+
document.addEventListener("focusin", handleFocusIn2);
|
|
58
|
+
document.addEventListener("focusout", handleFocusOut2);
|
|
59
|
+
const mutationObserver = new MutationObserver(handleMutations2);
|
|
60
|
+
if (container) mutationObserver.observe(container, { childList: true, subtree: true });
|
|
61
|
+
return () => {
|
|
62
|
+
document.removeEventListener("focusin", handleFocusIn2);
|
|
63
|
+
document.removeEventListener("focusout", handleFocusOut2);
|
|
64
|
+
mutationObserver.disconnect();
|
|
65
|
+
};
|
|
66
|
+
}
|
|
67
|
+
}, [trapped, container, focusScope.paused]);
|
|
68
|
+
React.useEffect(() => {
|
|
69
|
+
if (container) {
|
|
70
|
+
focusScopesStack.add(focusScope);
|
|
71
|
+
const previouslyFocusedElement = document.activeElement;
|
|
72
|
+
const hasFocusedCandidate = container.contains(previouslyFocusedElement);
|
|
73
|
+
if (!hasFocusedCandidate) {
|
|
74
|
+
const mountEvent = new CustomEvent(AUTOFOCUS_ON_MOUNT, EVENT_OPTIONS);
|
|
75
|
+
container.addEventListener(AUTOFOCUS_ON_MOUNT, onMountAutoFocus);
|
|
76
|
+
container.dispatchEvent(mountEvent);
|
|
77
|
+
if (!mountEvent.defaultPrevented) {
|
|
78
|
+
focusFirst(removeLinks(getTabbableCandidates(container)), { select: true });
|
|
79
|
+
if (document.activeElement === previouslyFocusedElement) {
|
|
80
|
+
focus(container);
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
return () => {
|
|
85
|
+
container.removeEventListener(AUTOFOCUS_ON_MOUNT, onMountAutoFocus);
|
|
86
|
+
setTimeout(() => {
|
|
87
|
+
const unmountEvent = new CustomEvent(AUTOFOCUS_ON_UNMOUNT, EVENT_OPTIONS);
|
|
88
|
+
container.addEventListener(AUTOFOCUS_ON_UNMOUNT, onUnmountAutoFocus);
|
|
89
|
+
container.dispatchEvent(unmountEvent);
|
|
90
|
+
if (!unmountEvent.defaultPrevented) {
|
|
91
|
+
focus(previouslyFocusedElement ?? document.body, { select: true });
|
|
92
|
+
}
|
|
93
|
+
container.removeEventListener(AUTOFOCUS_ON_UNMOUNT, onUnmountAutoFocus);
|
|
94
|
+
focusScopesStack.remove(focusScope);
|
|
95
|
+
}, 0);
|
|
96
|
+
};
|
|
97
|
+
}
|
|
98
|
+
}, [container, onMountAutoFocus, onUnmountAutoFocus, focusScope]);
|
|
99
|
+
const handleKeyDown = React.useCallback(
|
|
100
|
+
(event) => {
|
|
101
|
+
if (!loop && !trapped) return;
|
|
102
|
+
if (focusScope.paused) return;
|
|
103
|
+
const isTabKey = event.key === "Tab" && !event.altKey && !event.ctrlKey && !event.metaKey;
|
|
104
|
+
const focusedElement = document.activeElement;
|
|
105
|
+
if (isTabKey && focusedElement) {
|
|
106
|
+
const container2 = event.currentTarget;
|
|
107
|
+
const [first, last] = getTabbableEdges(container2);
|
|
108
|
+
const hasTabbableElementsInside = first && last;
|
|
109
|
+
if (!hasTabbableElementsInside) {
|
|
110
|
+
if (focusedElement === container2) event.preventDefault();
|
|
111
|
+
} else {
|
|
112
|
+
if (!event.shiftKey && focusedElement === last) {
|
|
113
|
+
event.preventDefault();
|
|
114
|
+
if (loop) focus(first, { select: true });
|
|
115
|
+
} else if (event.shiftKey && focusedElement === first) {
|
|
116
|
+
event.preventDefault();
|
|
117
|
+
if (loop) focus(last, { select: true });
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
},
|
|
122
|
+
[loop, trapped, focusScope.paused]
|
|
123
|
+
);
|
|
124
|
+
return /* @__PURE__ */ jsx(Primitive.div, { tabIndex: -1, ...scopeProps, ref: composedRefs, onKeyDown: handleKeyDown });
|
|
125
|
+
});
|
|
126
|
+
FocusScope.displayName = FOCUS_SCOPE_NAME;
|
|
127
|
+
function focusFirst(candidates, { select = false } = {}) {
|
|
128
|
+
const previouslyFocusedElement = document.activeElement;
|
|
129
|
+
for (const candidate of candidates) {
|
|
130
|
+
focus(candidate, { select });
|
|
131
|
+
if (document.activeElement !== previouslyFocusedElement) return;
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
function getTabbableEdges(container) {
|
|
135
|
+
const candidates = getTabbableCandidates(container);
|
|
136
|
+
const first = findVisible(candidates, container);
|
|
137
|
+
const last = findVisible(candidates.reverse(), container);
|
|
138
|
+
return [first, last];
|
|
139
|
+
}
|
|
140
|
+
function getTabbableCandidates(container) {
|
|
141
|
+
const nodes = [];
|
|
142
|
+
const walker = document.createTreeWalker(container, NodeFilter.SHOW_ELEMENT, {
|
|
143
|
+
acceptNode: (node) => {
|
|
144
|
+
const isHiddenInput = node.tagName === "INPUT" && node.type === "hidden";
|
|
145
|
+
if (node.disabled || node.hidden || isHiddenInput) return NodeFilter.FILTER_SKIP;
|
|
146
|
+
return node.tabIndex >= 0 ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP;
|
|
147
|
+
}
|
|
148
|
+
});
|
|
149
|
+
while (walker.nextNode()) nodes.push(walker.currentNode);
|
|
150
|
+
return nodes;
|
|
151
|
+
}
|
|
152
|
+
function findVisible(elements, container) {
|
|
153
|
+
for (const element of elements) {
|
|
154
|
+
if (!isHidden(element, { upTo: container })) return element;
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
function isHidden(node, { upTo }) {
|
|
158
|
+
if (getComputedStyle(node).visibility === "hidden") return true;
|
|
159
|
+
while (node) {
|
|
160
|
+
if (upTo !== void 0 && node === upTo) return false;
|
|
161
|
+
if (getComputedStyle(node).display === "none") return true;
|
|
162
|
+
node = node.parentElement;
|
|
163
|
+
}
|
|
164
|
+
return false;
|
|
165
|
+
}
|
|
166
|
+
function isSelectableInput(element) {
|
|
167
|
+
return element instanceof HTMLInputElement && "select" in element;
|
|
168
|
+
}
|
|
169
|
+
function focus(element, { select = false } = {}) {
|
|
170
|
+
if (element && element.focus) {
|
|
171
|
+
const previouslyFocusedElement = document.activeElement;
|
|
172
|
+
element.focus({ preventScroll: true });
|
|
173
|
+
if (element !== previouslyFocusedElement && isSelectableInput(element) && select)
|
|
174
|
+
element.select();
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
var focusScopesStack = createFocusScopesStack();
|
|
178
|
+
function createFocusScopesStack() {
|
|
179
|
+
let stack = [];
|
|
180
|
+
return {
|
|
181
|
+
add(focusScope) {
|
|
182
|
+
const activeFocusScope = stack[0];
|
|
183
|
+
if (focusScope !== activeFocusScope) {
|
|
184
|
+
activeFocusScope?.pause();
|
|
185
|
+
}
|
|
186
|
+
stack = arrayRemove(stack, focusScope);
|
|
187
|
+
stack.unshift(focusScope);
|
|
188
|
+
},
|
|
189
|
+
remove(focusScope) {
|
|
190
|
+
stack = arrayRemove(stack, focusScope);
|
|
191
|
+
stack[0]?.resume();
|
|
192
|
+
}
|
|
193
|
+
};
|
|
194
|
+
}
|
|
195
|
+
function arrayRemove(array, item) {
|
|
196
|
+
const updatedArray = [...array];
|
|
197
|
+
const index = updatedArray.indexOf(item);
|
|
198
|
+
if (index !== -1) {
|
|
199
|
+
updatedArray.splice(index, 1);
|
|
200
|
+
}
|
|
201
|
+
return updatedArray;
|
|
202
|
+
}
|
|
203
|
+
function removeLinks(items) {
|
|
204
|
+
return items.filter((item) => item.tagName !== "A");
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
export { FocusScope };
|