r3ui-lib 1.3.20 → 1.3.21
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/login.es.js +14 -3148
- package/dist/modules/_virtual/___vite-browser-external.js +6 -0
- package/dist/modules/_virtual/__vite-browser-external.js +4 -0
- package/dist/modules/_virtual/_commonjsHelpers.js +33 -0
- package/dist/modules/_virtual/_plugin-vue_export-helper.js +9 -0
- package/dist/modules/_virtual/he.js +5 -0
- package/dist/modules/_virtual/he2.js +4 -0
- package/dist/modules/_virtual/index.js +7 -0
- package/dist/modules/_virtual/inputmask.js +7 -0
- package/dist/modules/_virtual/inputmask2.js +4 -0
- package/dist/modules/_virtual/ru.js +5 -0
- package/dist/modules/_virtual/ru2.js +4 -0
- package/dist/modules/assets/img/confirmation.png.js +4 -0
- package/dist/modules/assets/img/error.png.js +4 -0
- package/dist/modules/assets/img/preloader.gif.js +4 -0
- package/dist/modules/assets/img/regagro_logo.svg.js +4 -0
- package/dist/modules/assets/img/success.png.js +4 -0
- package/dist/modules/assets/img/warning.png.js +4 -0
- package/dist/modules/components/DefaultButton.vue.js +112 -0
- package/dist/modules/components/Divider.vue.js +33 -0
- package/dist/modules/components/Icon.vue.js +18 -0
- package/dist/modules/components/Slider.vue.js +7 -0
- package/dist/modules/components/Slider.vue2.js +127 -0
- package/dist/modules/components/Spinner.vue.js +19 -0
- package/dist/modules/components/SsoLoginPending.vue.js +7 -0
- package/dist/modules/components/SsoLoginPending.vue2.js +44 -0
- package/dist/modules/components/SsoLoginScreen.vue.js +57 -0
- package/dist/modules/components/SsoLoginScreen.vue2.js +4 -0
- package/dist/modules/components/accordions/DefaultAccordion.vue.js +7 -0
- package/dist/modules/components/accordions/DefaultAccordion.vue2.js +72 -0
- package/dist/modules/components/accordions/KindCheckboxesAccordion.vue.js +7 -0
- package/dist/modules/components/accordions/KindCheckboxesAccordion.vue2.js +152 -0
- package/dist/modules/components/buttons/AddButton.vue.js +7 -0
- package/dist/modules/components/buttons/AddButton.vue2.js +30 -0
- package/dist/modules/components/buttons/ClearFormButton.vue.js +7 -0
- package/dist/modules/components/buttons/ClearFormButton.vue2.js +28 -0
- package/dist/modules/components/buttons/CollapseButton.vue.js +7 -0
- package/dist/modules/components/buttons/CollapseButton.vue2.js +57 -0
- package/dist/modules/components/buttons/ExportButton.vue.js +7 -0
- package/dist/modules/components/buttons/ExportButton.vue2.js +28 -0
- package/dist/modules/components/buttons/PrintButton.vue.js +7 -0
- package/dist/modules/components/buttons/PrintButton.vue2.js +27 -0
- package/dist/modules/components/buttons/ToggleButtons.vue.js +7 -0
- package/dist/modules/components/buttons/ToggleButtons.vue2.js +30 -0
- package/dist/modules/components/cards/CardInfo.vue.js +7 -0
- package/dist/modules/components/cards/CardInfo.vue2.js +56 -0
- package/dist/modules/components/cards/PageCard.vue.js +7 -0
- package/dist/modules/components/cards/PageCard.vue2.js +117 -0
- package/dist/modules/components/dropdowns/DefaultDropDown.vue.js +102 -0
- package/dist/modules/components/export/ExportComponent.vue.js +7 -0
- package/dist/modules/components/export/ExportComponent.vue2.js +74 -0
- package/dist/modules/components/filters/MultipleQuickFilterComponent.vue.js +7 -0
- package/dist/modules/components/filters/MultipleQuickFilterComponent.vue2.js +34 -0
- package/dist/modules/components/form/Checkbox.vue.js +66 -0
- package/dist/modules/components/form/CustomInput.vue.js +161 -0
- package/dist/modules/components/form/FormError.vue.js +24 -0
- package/dist/modules/components/form/PasswordInput.vue.js +82 -0
- package/dist/modules/components/form/VSelect.vue.js +192 -0
- package/dist/modules/components/form/useWithPopper.js +29 -0
- package/dist/modules/components/forms/AddressForm.vue.js +7 -0
- package/dist/modules/components/forms/AddressForm.vue2.js +382 -0
- package/dist/modules/components/forms/AgeFromAgeTo.vue.js +7 -0
- package/dist/modules/components/forms/AgeFromAgeTo.vue2.js +207 -0
- package/dist/modules/components/forms/BooleanCheckbox.vue.js +7 -0
- package/dist/modules/components/forms/BooleanCheckbox.vue2.js +54 -0
- package/dist/modules/components/forms/Flatpickr.vue.js +7 -0
- package/dist/modules/components/forms/Flatpickr.vue2.js +273 -0
- package/dist/modules/components/forms/HeaderSearchForm.vue.js +7 -0
- package/dist/modules/components/forms/HeaderSearchForm.vue2.js +142 -0
- package/dist/modules/components/forms/MultiCheckbox.vue.js +7 -0
- package/dist/modules/components/forms/MultiCheckbox.vue2.js +64 -0
- package/dist/modules/components/forms/MultiInput.vue.js +7 -0
- package/dist/modules/components/forms/MultiInput.vue2.js +115 -0
- package/dist/modules/components/icons/QuestionIcon.vue.js +7 -0
- package/dist/modules/components/icons/QuestionIcon.vue2.js +56 -0
- package/dist/modules/components/layout/Breadcrumbs.vue.js +7 -0
- package/dist/modules/components/layout/Breadcrumbs.vue2.js +40 -0
- package/dist/modules/components/layout/Card.vue.js +31 -0
- package/dist/modules/components/layout/Footer.vue.js +15 -0
- package/dist/modules/components/layout/Footer.vue2.js +4 -0
- package/dist/modules/components/layout/Header.vue.js +7 -0
- package/dist/modules/components/layout/Header.vue2.js +68 -0
- package/dist/modules/components/layout/LanguageSelector.vue.js +32 -0
- package/dist/modules/components/layout/LanguageSelector.vue3.js +5 -0
- package/dist/modules/components/layout/LoginLayoutFrame.vue.js +48 -0
- package/dist/modules/components/layout/LoginLayoutFrame.vue2.js +4 -0
- package/dist/modules/components/layout/MainComponent.vue.js +50 -0
- package/dist/modules/components/layout/MainComponent.vue2.js +4 -0
- package/dist/modules/components/layout/PageTitle.vue.js +7 -0
- package/dist/modules/components/layout/PageTitle.vue2.js +40 -0
- package/dist/modules/components/logo/Logo.vue.js +7 -0
- package/dist/modules/components/logo/Logo.vue2.js +50 -0
- package/dist/modules/components/modals/ConfirmationModal.vue.js +7 -0
- package/dist/modules/components/modals/ConfirmationModal.vue2.js +154 -0
- package/dist/modules/components/modals/DefaultModal.vue.js +116 -0
- package/dist/modules/components/modals/DefaultModal.vue3.js +5 -0
- package/dist/modules/components/modals/EditTableColumnsModalComponent.vue.js +7 -0
- package/dist/modules/components/modals/EditTableColumnsModalComponent.vue2.js +41 -0
- package/dist/modules/components/modals/TableFilterModalComponent.vue.js +7 -0
- package/dist/modules/components/modals/TableFilterModalComponent.vue2.js +66 -0
- package/dist/modules/components/modals/TableFilterModalShell.vue.js +89 -0
- package/dist/modules/components/modals/TableFilterModalShell.vue2.js +4 -0
- package/dist/modules/components/notifications/ErrorMessageComponent.vue.js +7 -0
- package/dist/modules/components/notifications/ErrorMessageComponent.vue2.js +45 -0
- package/dist/modules/components/notifications/NotificationMessage.vue.js +55 -0
- package/dist/modules/components/notifications/NotificationMessage.vue2.js +4 -0
- package/dist/modules/components/notifications/Toast.vue.js +71 -0
- package/dist/modules/components/sidebar/CollapsedSidebarLink.vue.js +7 -0
- package/dist/modules/components/sidebar/CollapsedSidebarLink.vue2.js +90 -0
- package/dist/modules/components/sidebar/Sidebar.vue.js +59 -0
- package/dist/modules/components/sidebar/Sidebar.vue3.js +5 -0
- package/dist/modules/components/sidebar/SidebarLink.vue.js +7 -0
- package/dist/modules/components/sidebar/SidebarLink.vue2.js +93 -0
- package/dist/modules/components/tables/ColumnSubFilter.vue.js +7 -0
- package/dist/modules/components/tables/ColumnSubFilter.vue2.js +36 -0
- package/dist/modules/components/tables/EditTableColumns.vue.js +7 -0
- package/dist/modules/components/tables/EditTableColumns.vue2.js +125 -0
- package/dist/modules/components/tables/ManagedRemoteTable.vue.js +72 -0
- package/dist/modules/components/tables/ManagedRemoteTable.vue2.js +4 -0
- package/dist/modules/components/tables/SubFilterToggleBtn.vue.js +28 -0
- package/dist/modules/components/tables/Table.vue.js +416 -0
- package/dist/modules/components/tables/Table.vue3.js +5 -0
- package/dist/modules/components/tables/TableAppliedFiltersStorage.vue.js +7 -0
- package/dist/modules/components/tables/TableAppliedFiltersStorage.vue2.js +56 -0
- package/dist/modules/components/tables/TableColumnsButton.vue.js +27 -0
- package/dist/modules/components/tables/TableColumnsButton.vue2.js +4 -0
- package/dist/modules/components/tables/TableColumnsDialog.vue.js +67 -0
- package/dist/modules/components/tables/TableColumnsDialog.vue2.js +4 -0
- package/dist/modules/components/tables/TableColumnsModal.vue.js +27 -0
- package/dist/modules/components/tables/TableColumnsModal.vue2.js +4 -0
- package/dist/modules/components/tables/TableCount.vue.js +7 -0
- package/dist/modules/components/tables/TableCount.vue2.js +26 -0
- package/dist/modules/components/tables/TableQuickFilterComponent.vue.js +7 -0
- package/dist/modules/components/tables/TableQuickFilterComponent.vue2.js +29 -0
- package/dist/modules/components/tables/ToggleAllTableRowButtons.vue.js +7 -0
- package/dist/modules/components/tables/ToggleAllTableRowButtons.vue2.js +41 -0
- package/dist/modules/components/utilities/FilterValuesPanel.vue.js +7 -0
- package/dist/modules/components/utilities/FilterValuesPanel.vue2.js +95 -0
- package/dist/modules/composables/forms/useAddressForm.js +289 -0
- package/dist/modules/composables/forms/useFieldError.js +23 -0
- package/dist/modules/composables/forms/useSearchForm.js +52 -0
- package/dist/modules/composables/forms/useUnsavedChanges.js +84 -0
- package/dist/modules/composables/layout/useR3uiLayoutInject.js +32 -0
- package/dist/modules/composables/main/useBreadcrumbs.js +75 -0
- package/dist/modules/composables/main/useMain.js +38 -0
- package/dist/modules/composables/main/usePermissionChecker.js +15 -0
- package/dist/modules/composables/modals/useModalLayer.js +109 -0
- package/dist/modules/composables/sidebar/useSidebar.js +40 -0
- package/dist/modules/composables/table/createTableCommandScheduler.js +62 -0
- package/dist/modules/composables/table/createTableLifecycle.js +719 -0
- package/dist/modules/composables/table/createTableRebuildTransaction.js +61 -0
- package/dist/modules/composables/table/createTableSession.js +38 -0
- package/dist/modules/composables/table/createTableState.js +122 -0
- package/dist/modules/composables/table/createTabulatorAdapter.js +90 -0
- package/dist/modules/composables/table/tableQueryTransitions.js +82 -0
- package/dist/modules/composables/table/useManagedRemoteTable.js +179 -0
- package/dist/modules/composables/table/useR3uiTableDefaultInject.js +27 -0
- package/dist/modules/composables/table/useRemoteTable.js +96 -0
- package/dist/modules/composables/table/useTableColumnApply.js +38 -0
- package/dist/modules/composables/table/useTableColumns.js +70 -0
- package/dist/modules/composables/table/useTableColumnsEnhanced.js +155 -0
- package/dist/modules/composables/table/useTableColumnsIntegration.js +82 -0
- package/dist/modules/composables/table/useTableDefault.js +258 -0
- package/dist/modules/composables/table/useTableStorage.js +32 -0
- package/dist/modules/constants/authSidebar.js +36 -0
- package/dist/modules/services/AddressService.js +21 -0
- package/dist/modules/types/layoutInjectKeys.js +10 -0
- package/dist/modules/types/tableInjectKeys.js +21 -0
- package/dist/modules/types/tableInstance.js +32 -0
- package/dist/modules/utils/accordionLocalization.js +14 -0
- package/dist/modules/utils/addressFormTranslations.js +29 -0
- package/dist/modules/utils/auth/authUser.js +13 -0
- package/dist/modules/utils/auth/exchangePasswordToken.js +52 -0
- package/dist/modules/utils/auth/handlePkceCallback.js +88 -0
- package/dist/modules/utils/auth/logout.js +32 -0
- package/dist/modules/utils/auth/runLogoutHandler.js +60 -0
- package/dist/modules/utils/auth/sessionController.js +28 -0
- package/dist/modules/utils/auth/signInWithSSO.js +141 -0
- package/dist/modules/utils/authCookie.js +21 -0
- package/dist/modules/utils/constants.js +34 -0
- package/dist/modules/utils/createTabulatorLangsFromT.js +30 -0
- package/dist/modules/utils/createTabulatorTableProps.js +19 -0
- package/dist/modules/utils/helpers.js +537 -0
- package/dist/modules/utils/pkce.js +50 -0
- package/dist/modules/utils/table-columns-utils.js +59 -0
- package/dist/modules/utils/tableAdapter.js +156 -0
- package/dist/modules/utils/tableAjaxRequest.js +82 -0
- package/dist/modules/utils/tableCancellation.js +271 -0
- package/dist/modules/utils/tableColumnStorage.js +55 -0
- package/dist/modules/utils/tableData.js +118 -0
- package/dist/modules/utils/tableLoad.js +67 -0
- package/dist/modules/utils/tableLocalizations.js +6 -0
- package/dist/modules/utils/tableOperation.js +63 -0
- package/dist/modules/utils/tableProjection.js +137 -0
- package/dist/modules/utils/tableQueryParameters.js +46 -0
- package/dist/modules/utils/tableSnapshotValue.js +73 -0
- package/dist/modules/utils/tabulatorQueryAdapter.js +203 -0
- package/dist/modules/utils/tabulatorRuntime.js +131 -0
- package/dist/modules/utils/upstreamHttpStatus.js +32 -0
- package/dist/modules/vendor/@popperjs/core/lib/createPopper.js +122 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/contains.js +18 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getBoundingClientRect.js +23 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getClippingRect.js +37 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getCompositeRect.js +32 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getComputedStyle.js +7 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getDocumentElement.js +10 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getDocumentRect.js +17 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js +9 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getLayoutRect.js +13 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getNodeName.js +6 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getNodeScroll.js +10 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getOffsetParent.js +35 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getParentNode.js +18 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getScrollParent.js +10 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getViewportRect.js +21 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getWindow.js +12 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getWindowScroll.js +11 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js +9 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/instanceOf.js +20 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/isLayoutViewport.js +7 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/isScrollParent.js +8 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/isTableElement.js +7 -0
- package/dist/modules/vendor/@popperjs/core/lib/dom-utils/listScrollParents.js +16 -0
- package/dist/modules/vendor/@popperjs/core/lib/enums.js +31 -0
- package/dist/modules/vendor/@popperjs/core/lib/modifiers/applyStyles.js +47 -0
- package/dist/modules/vendor/@popperjs/core/lib/modifiers/arrow.js +37 -0
- package/dist/modules/vendor/@popperjs/core/lib/modifiers/computeStyles.js +99 -0
- package/dist/modules/vendor/@popperjs/core/lib/modifiers/eventListeners.js +26 -0
- package/dist/modules/vendor/@popperjs/core/lib/modifiers/flip.js +74 -0
- package/dist/modules/vendor/@popperjs/core/lib/modifiers/hide.js +44 -0
- package/dist/modules/vendor/@popperjs/core/lib/modifiers/offset.js +31 -0
- package/dist/modules/vendor/@popperjs/core/lib/modifiers/popperOffsets.js +19 -0
- package/dist/modules/vendor/@popperjs/core/lib/modifiers/preventOverflow.js +54 -0
- package/dist/modules/vendor/@popperjs/core/lib/popper.js +27 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/computeAutoPlacement.js +27 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/computeOffsets.js +54 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/debounce.js +13 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/detectOverflow.js +33 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/expandToHashMap.js +8 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/getAltAxis.js +6 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/getBasePlacement.js +6 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/getFreshSideObject.js +11 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/getMainAxisFromPlacement.js +6 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/getOppositePlacement.js +14 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/getOppositeVariationPlacement.js +12 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/getVariation.js +6 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/math.js +6 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/mergeByName.js +15 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/mergePaddingObject.js +7 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/orderModifiers.js +31 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/rectToClientRect.js +11 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/userAgent.js +9 -0
- package/dist/modules/vendor/@popperjs/core/lib/utils/within.js +12 -0
- package/dist/modules/vendor/call-bind-apply-helpers/actualApply.js +14 -0
- package/dist/modules/vendor/call-bind-apply-helpers/functionApply.js +7 -0
- package/dist/modules/vendor/call-bind-apply-helpers/functionCall.js +7 -0
- package/dist/modules/vendor/call-bind-apply-helpers/index.js +18 -0
- package/dist/modules/vendor/call-bind-apply-helpers/reflectApply.js +7 -0
- package/dist/modules/vendor/call-bound/index.js +21 -0
- package/dist/modules/vendor/dompurify/dist/purify.es.js +1522 -0
- package/dist/modules/vendor/dunder-proto/get.js +29 -0
- package/dist/modules/vendor/es-define-property/index.js +16 -0
- package/dist/modules/vendor/es-errors/eval.js +7 -0
- package/dist/modules/vendor/es-errors/index.js +7 -0
- package/dist/modules/vendor/es-errors/range.js +7 -0
- package/dist/modules/vendor/es-errors/ref.js +7 -0
- package/dist/modules/vendor/es-errors/syntax.js +7 -0
- package/dist/modules/vendor/es-errors/type.js +7 -0
- package/dist/modules/vendor/es-errors/uri.js +7 -0
- package/dist/modules/vendor/es-object-atoms/index.js +7 -0
- package/dist/modules/vendor/flatpickr/dist/esm/index.js +942 -0
- package/dist/modules/vendor/flatpickr/dist/esm/l10n/default.js +75 -0
- package/dist/modules/vendor/flatpickr/dist/esm/types/options.js +80 -0
- package/dist/modules/vendor/flatpickr/dist/esm/utils/dates.js +89 -0
- package/dist/modules/vendor/flatpickr/dist/esm/utils/dom.js +45 -0
- package/dist/modules/vendor/flatpickr/dist/esm/utils/formatting.js +170 -0
- package/dist/modules/vendor/flatpickr/dist/esm/utils/index.js +23 -0
- package/dist/modules/vendor/flatpickr/dist/esm/utils/polyfills.js +15 -0
- package/dist/modules/vendor/flatpickr/dist/l10n/he.js +56 -0
- package/dist/modules/vendor/flatpickr/dist/l10n/ru.js +73 -0
- package/dist/modules/vendor/function-bind/implementation.js +48 -0
- package/dist/modules/vendor/function-bind/index.js +11 -0
- package/dist/modules/vendor/get-intrinsic/index.js +265 -0
- package/dist/modules/vendor/get-proto/Object.getPrototypeOf.js +11 -0
- package/dist/modules/vendor/get-proto/Reflect.getPrototypeOf.js +7 -0
- package/dist/modules/vendor/get-proto/index.js +21 -0
- package/dist/modules/vendor/gopd/gOPD.js +7 -0
- package/dist/modules/vendor/gopd/index.js +17 -0
- package/dist/modules/vendor/has-symbols/index.js +13 -0
- package/dist/modules/vendor/has-symbols/shams.js +33 -0
- package/dist/modules/vendor/hasown/index.js +11 -0
- package/dist/modules/vendor/inputmask/dist/inputmask.js +3517 -0
- package/dist/modules/vendor/math-intrinsics/abs.js +7 -0
- package/dist/modules/vendor/math-intrinsics/floor.js +7 -0
- package/dist/modules/vendor/math-intrinsics/isNaN.js +9 -0
- package/dist/modules/vendor/math-intrinsics/max.js +7 -0
- package/dist/modules/vendor/math-intrinsics/min.js +7 -0
- package/dist/modules/vendor/math-intrinsics/pow.js +7 -0
- package/dist/modules/vendor/math-intrinsics/round.js +7 -0
- package/dist/modules/vendor/math-intrinsics/sign.js +13 -0
- package/dist/modules/vendor/moment/dist/moment.js +2589 -0
- package/dist/modules/vendor/nouislider/dist/nouislider.js +1064 -0
- package/dist/modules/vendor/object-inspect/index.js +376 -0
- package/dist/modules/vendor/qs/lib/formats.js +25 -0
- package/dist/modules/vendor/qs/lib/index.js +17 -0
- package/dist/modules/vendor/qs/lib/parse.js +161 -0
- package/dist/modules/vendor/qs/lib/stringify.js +197 -0
- package/dist/modules/vendor/qs/lib/utils.js +129 -0
- package/dist/modules/vendor/seamless-scroll-polyfill/lib/common.js +21 -0
- package/dist/modules/vendor/seamless-scroll-polyfill/lib/scroll-end-event.js +12 -0
- package/dist/modules/vendor/seamless-scroll-polyfill/lib/scroll-step.js +21 -0
- package/dist/modules/vendor/seamless-scroll-polyfill/lib/scroll.js +58 -0
- package/dist/modules/vendor/seamless-scroll-polyfill/lib/scrollIntoView.js +168 -0
- package/dist/modules/vendor/side-channel/index.js +35 -0
- package/dist/modules/vendor/side-channel-list/index.js +64 -0
- package/dist/modules/vendor/side-channel-map/index.js +40 -0
- package/dist/modules/vendor/side-channel-weakmap/index.js +43 -0
- package/dist/modules/vendor/tabulator-tables/dist/js/tabulator_esm.js +11127 -0
- package/dist/modules/vendor/vue-select/dist/vue-select.es.js +769 -0
- package/dist/r3ui-lib.es.js +334 -35120
- package/package.json +7 -3
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
import { defineComponent as Q, ref as S, computed as u, watch as b, onMounted as C, createElementBlock as v, openBlock as g, createElementVNode as n, createCommentVNode as h, createVNode as s, toDisplayString as T } from "vue";
|
|
2
|
+
import M from "../form/CustomInput.vue.js";
|
|
3
|
+
import B from "../form/VSelect.vue.js";
|
|
4
|
+
import D from "../form/FormError.vue.js";
|
|
5
|
+
const R = { class: "form-group" }, z = {
|
|
6
|
+
key: 0,
|
|
7
|
+
class: "form-label mb-2"
|
|
8
|
+
}, G = { class: "row align-items-center mb-2" }, J = {
|
|
9
|
+
key: 0,
|
|
10
|
+
class: "col-auto"
|
|
11
|
+
}, K = { class: "form-label mb-0" }, W = { class: "col" }, X = { class: "col" }, Y = { class: "row align-items-center mb-2" }, Z = {
|
|
12
|
+
key: 0,
|
|
13
|
+
class: "col-auto"
|
|
14
|
+
}, x = { class: "form-label mb-0" }, ee = { class: "col" }, le = { class: "col" }, ne = /* @__PURE__ */ Q({
|
|
15
|
+
__name: "AgeFromAgeTo",
|
|
16
|
+
props: {
|
|
17
|
+
invalidAgeMessage: {},
|
|
18
|
+
missingUnitMessage: {},
|
|
19
|
+
modelValue: { default: null },
|
|
20
|
+
title: { default: "" },
|
|
21
|
+
nameFrom: { default: "age_from" },
|
|
22
|
+
nameTo: { default: "age_to" },
|
|
23
|
+
placeholderFrom: { default: null },
|
|
24
|
+
placeholderTo: { default: null },
|
|
25
|
+
timeTypePlaceholder: { default: void 0 },
|
|
26
|
+
timeTypeOptions: { default: void 0 },
|
|
27
|
+
disabled: { type: Boolean, default: !1 },
|
|
28
|
+
onFilterUpdate: { type: Function, default: void 0 }
|
|
29
|
+
},
|
|
30
|
+
emits: ["update:modelValue", "change"],
|
|
31
|
+
setup(I, { expose: j, emit: q }) {
|
|
32
|
+
const H = [
|
|
33
|
+
{ id: 1, label: "Дней", value: "days" },
|
|
34
|
+
{ id: 2, label: "Недель", value: "weeks" },
|
|
35
|
+
{ id: 3, label: "Месяцев", value: "months" },
|
|
36
|
+
{ id: 4, label: "Лет", value: "years" }
|
|
37
|
+
], a = I, c = q, y = {
|
|
38
|
+
age_from: null,
|
|
39
|
+
age_to: null,
|
|
40
|
+
time_type_from: null,
|
|
41
|
+
time_type_to: null
|
|
42
|
+
}, l = S({ ...y }), d = u(() => a.timeTypeOptions !== void 0 && a.timeTypeOptions !== null ? a.timeTypeOptions : H), F = S();
|
|
43
|
+
function V(e, o) {
|
|
44
|
+
return m(e) ? !Number.isSafeInteger(Number(e)) || Number(e) < 0 ? a.invalidAgeMessage : d.value.some((t) => Number(t.id) === Number(o)) ? "" : a.missingUnitMessage : "";
|
|
45
|
+
}
|
|
46
|
+
const p = u(() => V(l.value.age_from, l.value.time_type_from)), f = u(() => V(l.value.age_to, l.value.time_type_to));
|
|
47
|
+
function N() {
|
|
48
|
+
for (const [e, o] of [[a.nameFrom, p.value], [a.nameTo, f.value]]) {
|
|
49
|
+
const t = Array.from(F.value?.querySelectorAll("input") || []).find((r) => r.name === e);
|
|
50
|
+
t?.setCustomValidity(o), o ? t?.setAttribute("aria-invalid", "true") : t?.removeAttribute("aria-invalid");
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
b([p, f], N, { flush: "post" }), C(N);
|
|
54
|
+
const $ = u(() => a.placeholderFrom ?? null), A = u(() => a.placeholderTo ?? null), P = u(() => {
|
|
55
|
+
if (a.timeTypePlaceholder === null || a.timeTypePlaceholder === void 0) {
|
|
56
|
+
console.log(
|
|
57
|
+
"[AgeFromAgeTo] timeTypePlaceholder is null/undefined, placeholder disabled"
|
|
58
|
+
);
|
|
59
|
+
return;
|
|
60
|
+
}
|
|
61
|
+
return console.log("[AgeFromAgeTo] timeTypePlaceholder:", a.timeTypePlaceholder), a.timeTypePlaceholder;
|
|
62
|
+
});
|
|
63
|
+
function m(e) {
|
|
64
|
+
return e != null && e !== "";
|
|
65
|
+
}
|
|
66
|
+
const U = u(() => {
|
|
67
|
+
const e = l.value.age_from;
|
|
68
|
+
if (!m(e)) return null;
|
|
69
|
+
const o = l.value.time_type_from, t = d.value.find(
|
|
70
|
+
({ id: r }) => Number(r) === Number(o)
|
|
71
|
+
)?.label;
|
|
72
|
+
return t ? `${e} ${t}` : null;
|
|
73
|
+
}), k = u(() => {
|
|
74
|
+
const e = l.value.age_to;
|
|
75
|
+
if (!m(e)) return null;
|
|
76
|
+
const o = l.value.time_type_to, t = d.value.find(
|
|
77
|
+
({ id: r }) => Number(r) === Number(o)
|
|
78
|
+
)?.label;
|
|
79
|
+
return t ? `${e} ${t}` : null;
|
|
80
|
+
}), w = () => {
|
|
81
|
+
l.value = { ...y };
|
|
82
|
+
}, E = () => {
|
|
83
|
+
a.onFilterUpdate && (a.onFilterUpdate(a.nameFrom, U.value), a.onFilterUpdate(a.nameTo, k.value));
|
|
84
|
+
}, L = (e) => {
|
|
85
|
+
if (!m(e.age_from) && !m(e.age_to) && !e.time_type_from && !e.time_type_to) {
|
|
86
|
+
c("update:modelValue", null), c("change", { ...y }), E();
|
|
87
|
+
return;
|
|
88
|
+
}
|
|
89
|
+
const t = [];
|
|
90
|
+
for (const i of ["age_from", "age_to"]) {
|
|
91
|
+
const _ = e[i === "age_from" ? "time_type_from" : "time_type_to"];
|
|
92
|
+
m(e[i]) && t.push(`${_ ? `${i}[time_type]=${_}&` : ""}${i}[value]=${e[i]}`);
|
|
93
|
+
}
|
|
94
|
+
const r = t.length > 0 ? t.join("&") + "&" : "";
|
|
95
|
+
c("update:modelValue", r || null), !(p.value || f.value) && (c("change", { ...e }), E());
|
|
96
|
+
}, O = (e) => {
|
|
97
|
+
if (e)
|
|
98
|
+
try {
|
|
99
|
+
const o = new URLSearchParams(e), t = o.get("age_from[value]"), r = o.get("age_from[time_type]"), i = o.get("age_to[value]"), _ = o.get("age_to[time_type]");
|
|
100
|
+
l.value = {
|
|
101
|
+
age_from: t ? Number(t) : null,
|
|
102
|
+
age_to: i ? Number(i) : null,
|
|
103
|
+
time_type_from: r ? Number(r) : null,
|
|
104
|
+
time_type_to: _ ? Number(_) : null
|
|
105
|
+
};
|
|
106
|
+
} catch (o) {
|
|
107
|
+
console.warn("Error parsing query string:", o);
|
|
108
|
+
}
|
|
109
|
+
};
|
|
110
|
+
return b(
|
|
111
|
+
() => a.modelValue,
|
|
112
|
+
(e, o) => {
|
|
113
|
+
e !== o && (e === null ? w() : O(e));
|
|
114
|
+
},
|
|
115
|
+
{ immediate: !0 }
|
|
116
|
+
), b(
|
|
117
|
+
() => l.value,
|
|
118
|
+
(e) => {
|
|
119
|
+
L(e);
|
|
120
|
+
},
|
|
121
|
+
{ deep: !0 }
|
|
122
|
+
), C(() => {
|
|
123
|
+
a.modelValue && O(a.modelValue);
|
|
124
|
+
}), j({
|
|
125
|
+
reset: w,
|
|
126
|
+
getFormData: () => ({
|
|
127
|
+
age_from: m(l.value.age_from) ? Number(l.value.age_from) : null,
|
|
128
|
+
age_to: m(l.value.age_to) ? Number(l.value.age_to) : null,
|
|
129
|
+
time_type_from: l.value.time_type_from ? Number(l.value.time_type_from) : null,
|
|
130
|
+
time_type_to: l.value.time_type_to ? Number(l.value.time_type_to) : null
|
|
131
|
+
}),
|
|
132
|
+
getFilterStrings: () => ({
|
|
133
|
+
from: U.value,
|
|
134
|
+
to: k.value
|
|
135
|
+
})
|
|
136
|
+
}), (e, o) => (g(), v("div", {
|
|
137
|
+
class: "age-from-to-form",
|
|
138
|
+
ref_key: "fields",
|
|
139
|
+
ref: F
|
|
140
|
+
}, [
|
|
141
|
+
n("div", R, [
|
|
142
|
+
e.title ? (g(), v("label", z, T(e.title), 1)) : h("", !0),
|
|
143
|
+
n("div", G, [
|
|
144
|
+
$.value ? (g(), v("div", J, [
|
|
145
|
+
n("label", K, T($.value), 1)
|
|
146
|
+
])) : h("", !0),
|
|
147
|
+
n("div", W, [
|
|
148
|
+
s(M, {
|
|
149
|
+
modelValue: l.value.age_from,
|
|
150
|
+
"onUpdate:modelValue": o[0] || (o[0] = (t) => l.value.age_from = t),
|
|
151
|
+
name: e.nameFrom,
|
|
152
|
+
maskOptions: { regex: "^[0-9]*$" },
|
|
153
|
+
disabled: e.disabled
|
|
154
|
+
}, null, 8, ["modelValue", "name", "disabled"])
|
|
155
|
+
]),
|
|
156
|
+
n("div", X, [
|
|
157
|
+
s(B, {
|
|
158
|
+
modelValue: l.value.time_type_from,
|
|
159
|
+
"onUpdate:modelValue": o[1] || (o[1] = (t) => l.value.time_type_from = t),
|
|
160
|
+
name: `${e.nameFrom}_type`,
|
|
161
|
+
multiple: !1,
|
|
162
|
+
options: d.value,
|
|
163
|
+
allowClear: !1,
|
|
164
|
+
disabled: e.disabled,
|
|
165
|
+
placeholder: P.value
|
|
166
|
+
}, null, 8, ["modelValue", "name", "options", "disabled", "placeholder"])
|
|
167
|
+
])
|
|
168
|
+
]),
|
|
169
|
+
s(D, {
|
|
170
|
+
errors: p.value ? [p.value] : []
|
|
171
|
+
}, null, 8, ["errors"]),
|
|
172
|
+
n("div", Y, [
|
|
173
|
+
A.value ? (g(), v("div", Z, [
|
|
174
|
+
n("label", x, T(A.value), 1)
|
|
175
|
+
])) : h("", !0),
|
|
176
|
+
n("div", ee, [
|
|
177
|
+
s(M, {
|
|
178
|
+
modelValue: l.value.age_to,
|
|
179
|
+
"onUpdate:modelValue": o[2] || (o[2] = (t) => l.value.age_to = t),
|
|
180
|
+
name: e.nameTo,
|
|
181
|
+
maskOptions: { regex: "^[0-9]*$" },
|
|
182
|
+
disabled: e.disabled
|
|
183
|
+
}, null, 8, ["modelValue", "name", "disabled"])
|
|
184
|
+
]),
|
|
185
|
+
n("div", le, [
|
|
186
|
+
s(B, {
|
|
187
|
+
modelValue: l.value.time_type_to,
|
|
188
|
+
"onUpdate:modelValue": o[3] || (o[3] = (t) => l.value.time_type_to = t),
|
|
189
|
+
name: `${e.nameTo}_type`,
|
|
190
|
+
multiple: !1,
|
|
191
|
+
options: d.value,
|
|
192
|
+
allowClear: !1,
|
|
193
|
+
disabled: e.disabled,
|
|
194
|
+
placeholder: P.value
|
|
195
|
+
}, null, 8, ["modelValue", "name", "options", "disabled", "placeholder"])
|
|
196
|
+
])
|
|
197
|
+
]),
|
|
198
|
+
s(D, {
|
|
199
|
+
errors: f.value ? [f.value] : []
|
|
200
|
+
}, null, 8, ["errors"])
|
|
201
|
+
])
|
|
202
|
+
], 512));
|
|
203
|
+
}
|
|
204
|
+
});
|
|
205
|
+
export {
|
|
206
|
+
ne as default
|
|
207
|
+
};
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { defineComponent as g, computed as a, watch as h, createElementBlock as k, openBlock as y, Fragment as V, createElementVNode as l, createVNode as _, normalizeClass as u, unref as s, toDisplayString as v } from "vue";
|
|
2
|
+
import b from "../form/FormError.vue.js";
|
|
3
|
+
import { getUniqueKey as S } from "../../utils/helpers.js";
|
|
4
|
+
const C = { class: "form-check" }, F = ["type", "id", "name", "checked"], B = ["for"], q = /* @__PURE__ */ g({
|
|
5
|
+
__name: "BooleanCheckbox",
|
|
6
|
+
props: {
|
|
7
|
+
defaultValue: { default: null },
|
|
8
|
+
trueValue: { default: "1" },
|
|
9
|
+
modelValue: { default: void 0 },
|
|
10
|
+
name: { default: "" },
|
|
11
|
+
group: { default: "" },
|
|
12
|
+
type: { default: "checkbox" },
|
|
13
|
+
label: { default: "" },
|
|
14
|
+
error: { default: "" },
|
|
15
|
+
setFilterParamsStringsHandler: { type: Function, default: void 0 }
|
|
16
|
+
},
|
|
17
|
+
emits: ["update:modelValue"],
|
|
18
|
+
setup(i, { emit: c }) {
|
|
19
|
+
const e = i, d = c, o = S(), m = a(() => e.group.length ? e.group : e.name), f = (r) => {
|
|
20
|
+
const n = r.target;
|
|
21
|
+
d(
|
|
22
|
+
"update:modelValue",
|
|
23
|
+
n.checked ? e.trueValue : e.defaultValue
|
|
24
|
+
);
|
|
25
|
+
}, t = a(() => e.modelValue === e.trueValue), p = a(() => Array.isArray(e.error) ? e.error?.filter(Boolean) || [] : typeof e.error == "string" && e.error ? [e.error] : []);
|
|
26
|
+
return h(
|
|
27
|
+
[t, () => e.name, () => e.setFilterParamsStringsHandler],
|
|
28
|
+
() => e.setFilterParamsStringsHandler?.(
|
|
29
|
+
e.name,
|
|
30
|
+
t.value ? "Да" : null
|
|
31
|
+
),
|
|
32
|
+
{ immediate: !0 }
|
|
33
|
+
), (r, n) => (y(), k(V, null, [
|
|
34
|
+
l("div", C, [
|
|
35
|
+
l("input", {
|
|
36
|
+
class: u(["form-check-input mb-1", [r.error ? "not-valid" : ""]]),
|
|
37
|
+
type: r.type,
|
|
38
|
+
id: String(s(o)),
|
|
39
|
+
name: m.value,
|
|
40
|
+
checked: t.value,
|
|
41
|
+
onChange: f
|
|
42
|
+
}, null, 42, F),
|
|
43
|
+
l("label", {
|
|
44
|
+
class: u(["form-check-label", [r.error ? "text-danger" : ""]]),
|
|
45
|
+
for: String(s(o))
|
|
46
|
+
}, v(r.label), 11, B)
|
|
47
|
+
]),
|
|
48
|
+
_(b, { errors: p.value }, null, 8, ["errors"])
|
|
49
|
+
], 64));
|
|
50
|
+
}
|
|
51
|
+
});
|
|
52
|
+
export {
|
|
53
|
+
q as default
|
|
54
|
+
};
|
|
@@ -0,0 +1,273 @@
|
|
|
1
|
+
import { defineComponent as J, ref as p, computed as E, watch as F, onMounted as Q, onBeforeUnmount as X, createElementBlock as q, openBlock as L, createElementVNode as S, createCommentVNode as Z, createVNode as ee, normalizeClass as te, withKeys as ae, nextTick as H } from "vue";
|
|
2
|
+
import M from "../../vendor/flatpickr/dist/esm/index.js";
|
|
3
|
+
/* empty css */
|
|
4
|
+
import { r as le } from "../../_virtual/ru.js";
|
|
5
|
+
import { h as oe } from "../../_virtual/he.js";
|
|
6
|
+
import re from "../form/FormError.vue.js";
|
|
7
|
+
const ne = ["value", "id", "name", "disabled", "required", "aria-invalid", "data-r3ui-date-invalid", "placeholder"], ie = ["title"], ue = ["title"], ge = /* @__PURE__ */ J({
|
|
8
|
+
__name: "Flatpickr",
|
|
9
|
+
props: {
|
|
10
|
+
invalidDateMessage: {},
|
|
11
|
+
modelValue: { default: "" },
|
|
12
|
+
id: { default: "flatpickr-input" },
|
|
13
|
+
error: { default: "" },
|
|
14
|
+
name: { default: "flatpickr" },
|
|
15
|
+
placeholder: { default: "Выберите дату" },
|
|
16
|
+
disabled: { type: Boolean, default: !1 },
|
|
17
|
+
required: { type: Boolean, default: !1 },
|
|
18
|
+
config: { default: () => ({}) },
|
|
19
|
+
format: { default: "DD.MM.YYYY" },
|
|
20
|
+
locale: { default: "ru" },
|
|
21
|
+
resetTitle: { default: "Очистить" },
|
|
22
|
+
calendarTitle: { default: "Выбрать дату" },
|
|
23
|
+
allowInput: { type: Boolean, default: !0 },
|
|
24
|
+
enableTime: { type: Boolean, default: !1 },
|
|
25
|
+
time_24hr: { type: Boolean, default: !0 },
|
|
26
|
+
dateFormat: { default: "d.m.Y" },
|
|
27
|
+
minDate: { default: void 0 },
|
|
28
|
+
maxDate: { default: void 0 },
|
|
29
|
+
defaultDate: { default: void 0 },
|
|
30
|
+
mode: { default: "single" }
|
|
31
|
+
},
|
|
32
|
+
emits: ["update:modelValue", "change", "open", "close", "ready"],
|
|
33
|
+
setup(j, { expose: R, emit: U }) {
|
|
34
|
+
const t = j, f = U, v = p(), u = p(null);
|
|
35
|
+
let Y;
|
|
36
|
+
const h = p(!1), s = p(""), y = p([]), k = p(!1), $ = p(!1), c = E(() => $.value ? t.invalidDateMessage : ""), T = p("");
|
|
37
|
+
F(c, (e) => {
|
|
38
|
+
v.value?.querySelector("input")?.setCustomValidity(e);
|
|
39
|
+
}, { flush: "post" });
|
|
40
|
+
const _ = E(() => Array.isArray(t.error) ? [c.value, ...t.error].filter(Boolean) : typeof t.error == "string" && t.error ? [c.value, t.error].filter(Boolean) : c.value ? [c.value] : []), B = (e) => {
|
|
41
|
+
if (!e) return null;
|
|
42
|
+
if (e instanceof Date && !isNaN(e.getTime())) return e;
|
|
43
|
+
const a = typeof e == "string" ? e.trim() : "";
|
|
44
|
+
if (a) {
|
|
45
|
+
const o = O(a);
|
|
46
|
+
if (o) {
|
|
47
|
+
const n = D(o, "Y-m-d");
|
|
48
|
+
if (n) return n;
|
|
49
|
+
}
|
|
50
|
+
const l = M.parseDate?.(
|
|
51
|
+
a,
|
|
52
|
+
t.dateFormat
|
|
53
|
+
);
|
|
54
|
+
if (l && !isNaN(l.getTime()))
|
|
55
|
+
return l;
|
|
56
|
+
const r = new Date(a);
|
|
57
|
+
if (!isNaN(r.getTime())) return r;
|
|
58
|
+
}
|
|
59
|
+
return null;
|
|
60
|
+
}, N = (e) => {
|
|
61
|
+
const a = e instanceof Date ? e : B(e);
|
|
62
|
+
if (!a) return "";
|
|
63
|
+
const o = String(a.getDate()).padStart(2, "0"), l = String(a.getMonth() + 1).padStart(2, "0"), r = a.getFullYear();
|
|
64
|
+
return t.format === "MM/DD/YYYY" ? `${l}/${o}/${r}` : t.format === "YYYY-MM-DD" ? `${r}-${l}-${o}` : `${o}.${l}.${r}`;
|
|
65
|
+
}, g = (e) => {
|
|
66
|
+
const a = e instanceof Date ? e : B(e);
|
|
67
|
+
if (!a) return "";
|
|
68
|
+
const o = String(a.getDate()).padStart(2, "0"), l = String(a.getMonth() + 1).padStart(2, "0");
|
|
69
|
+
return `${a.getFullYear()}-${l}-${o}`;
|
|
70
|
+
}, D = (e, a) => {
|
|
71
|
+
const o = M.parseDate(e, a);
|
|
72
|
+
if (!(!o || Number.isNaN(o.getTime())))
|
|
73
|
+
return M.formatDate(o, a) === e ? o : void 0;
|
|
74
|
+
}, O = (e) => {
|
|
75
|
+
if (!e) return "";
|
|
76
|
+
const a = e.trim(), o = /^\d{4}-\d{2}-\d{2}$/.test(a) ? "Y-m-d" : t.dateFormat, l = t.format === "MM/DD/YYYY" ? "m/d/Y" : o, r = D(a, o) || D(a, l);
|
|
77
|
+
return r ? g(r) : "";
|
|
78
|
+
}, b = (e) => {
|
|
79
|
+
const a = t.mode === "range" ? u.value?.l10n.rangeSeparator || " to " : ", ", o = t.mode === "single" ? [e] : e.split(a), l = !e || o.every((r) => !!D(r.trim(), t.dateFormat));
|
|
80
|
+
return $.value = !l, T.value = l ? "" : e, v.value?.querySelector("input")?.setCustomValidity(c.value), l;
|
|
81
|
+
}, K = (e) => e ? Array.isArray(e) ? e : [e] : [], C = (e, a) => {
|
|
82
|
+
const o = K(e), l = o.map((n) => N(n)).filter(Boolean);
|
|
83
|
+
if (s.value = l.join(t.mode === "range" ? a?.l10n?.rangeSeparator || " — " : ", "), h.value = l.length > 0, !a?._input) return;
|
|
84
|
+
if (!l.length) {
|
|
85
|
+
a.clear?.(), a._input.value = "";
|
|
86
|
+
return;
|
|
87
|
+
}
|
|
88
|
+
const r = o.map((n) => B(n)).filter((n) => !!n);
|
|
89
|
+
if (!r.length) {
|
|
90
|
+
a.clear?.(), a._input.value = s.value;
|
|
91
|
+
return;
|
|
92
|
+
}
|
|
93
|
+
a.setDate?.(r, !1), a._input.value = s.value, (t.mode === "range" || t.mode === "multiple") && (y.value = a.selectedDates || r);
|
|
94
|
+
}, P = () => {
|
|
95
|
+
if (!v.value) return;
|
|
96
|
+
const e = v.value.closest('[role="dialog"]'), a = e && !t.config.appendTo && !t.config.position && !t.config.static && !t.config.inline, o = {
|
|
97
|
+
locale: t.locale === "ru" ? le.Russian : t.locale === "he" ? oe.Hebrew : void 0,
|
|
98
|
+
allowInput: t.allowInput,
|
|
99
|
+
enableTime: t.enableTime,
|
|
100
|
+
time_24hr: t.time_24hr,
|
|
101
|
+
dateFormat: t.dateFormat,
|
|
102
|
+
mode: t.mode,
|
|
103
|
+
wrap: !0,
|
|
104
|
+
onClose: (l, r, n) => {
|
|
105
|
+
if (c.value) {
|
|
106
|
+
s.value = T.value, n._input.value = T.value;
|
|
107
|
+
return;
|
|
108
|
+
}
|
|
109
|
+
const m = l.length > 0;
|
|
110
|
+
if (y.value = l, !m)
|
|
111
|
+
return A({ instance: n }), !1;
|
|
112
|
+
if (t.mode === "range" || t.mode === "multiple") {
|
|
113
|
+
const i = l.map((V) => g(V)), d = Array.isArray(t.modelValue) ? t.modelValue : [];
|
|
114
|
+
if (d.length === i.length && d.every((V, w) => V === i[w]))
|
|
115
|
+
return !1;
|
|
116
|
+
} else {
|
|
117
|
+
const i = g(l[0]);
|
|
118
|
+
if (!(t.modelValue !== i)) return !1;
|
|
119
|
+
}
|
|
120
|
+
if (k.value = !0, t.mode === "range" || t.mode === "multiple") {
|
|
121
|
+
const i = l.map((d) => N(d));
|
|
122
|
+
s.value = i.join(t.mode === "range" ? n.l10n.rangeSeparator : ", "), h.value = i.length > 0;
|
|
123
|
+
} else
|
|
124
|
+
s.value = r, h.value = r.length > 0;
|
|
125
|
+
H(() => {
|
|
126
|
+
if (t.mode === "multiple") {
|
|
127
|
+
const i = l.map((d) => g(d));
|
|
128
|
+
f("update:modelValue", i);
|
|
129
|
+
} else if (t.mode === "range") {
|
|
130
|
+
const i = l.map((d) => g(d));
|
|
131
|
+
f("update:modelValue", i);
|
|
132
|
+
} else {
|
|
133
|
+
const i = g(l[0]);
|
|
134
|
+
f("update:modelValue", i);
|
|
135
|
+
}
|
|
136
|
+
f(
|
|
137
|
+
"change",
|
|
138
|
+
l.map((i) => i.toISOString()),
|
|
139
|
+
r,
|
|
140
|
+
n
|
|
141
|
+
), H(() => {
|
|
142
|
+
k.value = !1;
|
|
143
|
+
});
|
|
144
|
+
});
|
|
145
|
+
},
|
|
146
|
+
onOpen: (l) => {
|
|
147
|
+
f("open", l);
|
|
148
|
+
},
|
|
149
|
+
onReady: (l) => {
|
|
150
|
+
f("ready", l);
|
|
151
|
+
},
|
|
152
|
+
...t.config,
|
|
153
|
+
...a ? {
|
|
154
|
+
// Календарь принадлежит диалогу: фокус и Tab остаются в общем стеке окон.
|
|
155
|
+
appendTo: e,
|
|
156
|
+
position: (l, r) => {
|
|
157
|
+
const n = l.calendarContainer, m = (r ?? l._positionElement).getBoundingClientRect(), i = e.getBoundingClientRect(), d = e.ownerDocument.defaultView, I = d.innerHeight - m.bottom < n.offsetHeight && m.top > n.offsetHeight, V = Math.max(8, Math.min(m.left, d.innerWidth - n.offsetWidth - 8)), w = I ? m.top - n.offsetHeight - 2 : m.bottom + 2;
|
|
158
|
+
n.style.left = `${V - i.left - e.clientLeft + e.scrollLeft}px`, n.style.top = `${w - i.top - e.clientTop + e.scrollTop}px`, n.style.right = "auto", n.classList.toggle("arrowTop", !I), n.classList.toggle("arrowBottom", I), n.classList.add("arrowLeft");
|
|
159
|
+
}
|
|
160
|
+
} : {},
|
|
161
|
+
onChange: [
|
|
162
|
+
(l, r) => {
|
|
163
|
+
c.value && l.length && (b(""), s.value = r);
|
|
164
|
+
},
|
|
165
|
+
...Array.isArray(t.config.onChange) ? t.config.onChange : t.config.onChange ? [t.config.onChange] : []
|
|
166
|
+
],
|
|
167
|
+
// Проверка действует и на встроенную обработку blur/Enter в flatpickr.
|
|
168
|
+
parseDate: (l, r) => (c.value ? void 0 : D(l, r)) ?? /* @__PURE__ */ new Date(NaN)
|
|
169
|
+
};
|
|
170
|
+
if (t.minDate && t.minDate && (o.minDate = t.minDate), t.maxDate && (o.maxDate = t.maxDate), t.defaultDate && (o.defaultDate = t.defaultDate), u.value = M(v.value, o), A({ instance: u.value }), a) {
|
|
171
|
+
const l = u.value.calendarContainer;
|
|
172
|
+
if (l) {
|
|
173
|
+
const r = () => l.querySelectorAll(".flatpickr-monthDropdown-months, .cur-year").forEach((n) => {
|
|
174
|
+
n.tabIndex = 0;
|
|
175
|
+
});
|
|
176
|
+
r(), Y = new MutationObserver(r), Y.observe(l, { childList: !0, subtree: !0 });
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
}, A = ({ instance: e }) => {
|
|
180
|
+
C(t.modelValue, e);
|
|
181
|
+
}, W = () => {
|
|
182
|
+
if (t.disabled || !u.value) return;
|
|
183
|
+
b(""), u.value.clear(), u.value._input.value = "";
|
|
184
|
+
const e = t.mode === "range" || t.mode === "multiple" ? [] : "";
|
|
185
|
+
s.value = "", h.value = !1, y.value = [], f("update:modelValue", e), f("change", [], "", u.value), C(e, u.value);
|
|
186
|
+
}, z = (e) => {
|
|
187
|
+
const a = e.target;
|
|
188
|
+
s.value = a.value, b(a.value);
|
|
189
|
+
}, x = (e) => b(s.value) ? !1 : (e.preventDefault(), e.stopImmediatePropagation(), !0), G = (e) => {
|
|
190
|
+
if (!x(e)) {
|
|
191
|
+
if (t.mode === "range" || t.mode === "multiple") {
|
|
192
|
+
if (u.value?.isOpen)
|
|
193
|
+
return;
|
|
194
|
+
if ((u.value?.selectedDates || []).length === 0 && y.value.length > 0) {
|
|
195
|
+
const o = y.value.map((n) => g(n)), l = Array.isArray(t.modelValue) ? t.modelValue : [];
|
|
196
|
+
l.length === o.length && l.every((n, m) => n === o[m]) || f("update:modelValue", o);
|
|
197
|
+
}
|
|
198
|
+
return;
|
|
199
|
+
}
|
|
200
|
+
if (t.mode === "single" && s.value) {
|
|
201
|
+
const a = O(s.value);
|
|
202
|
+
a && f("update:modelValue", a);
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
};
|
|
206
|
+
return F(
|
|
207
|
+
() => t.modelValue,
|
|
208
|
+
(e) => {
|
|
209
|
+
k.value || (b(""), C(e, u.value));
|
|
210
|
+
},
|
|
211
|
+
{ deep: !0 }
|
|
212
|
+
), F(
|
|
213
|
+
() => t.disabled,
|
|
214
|
+
(e) => {
|
|
215
|
+
u.value?._input && (u.value._input.disabled = e);
|
|
216
|
+
}
|
|
217
|
+
), Q(() => {
|
|
218
|
+
P();
|
|
219
|
+
}), X(() => {
|
|
220
|
+
Y?.disconnect(), u.value && u.value.destroy();
|
|
221
|
+
}), R({
|
|
222
|
+
datapicker: u
|
|
223
|
+
}), (e, a) => (L(), q("div", {
|
|
224
|
+
style: { position: "relative" },
|
|
225
|
+
ref_key: "input",
|
|
226
|
+
ref: v
|
|
227
|
+
}, [
|
|
228
|
+
S("div", {
|
|
229
|
+
class: te({
|
|
230
|
+
"not-valid": _.value.length
|
|
231
|
+
})
|
|
232
|
+
}, [
|
|
233
|
+
S("input", {
|
|
234
|
+
type: "text",
|
|
235
|
+
class: "form-control flatpickr",
|
|
236
|
+
value: s.value,
|
|
237
|
+
id: e.id,
|
|
238
|
+
name: e.name,
|
|
239
|
+
disabled: e.disabled,
|
|
240
|
+
required: e.required,
|
|
241
|
+
"aria-invalid": c.value ? !0 : void 0,
|
|
242
|
+
"data-r3ui-date-invalid": c.value ? !0 : void 0,
|
|
243
|
+
placeholder: e.placeholder,
|
|
244
|
+
autocomplete: "off",
|
|
245
|
+
"data-input": "",
|
|
246
|
+
onInput: z,
|
|
247
|
+
onBlurCapture: G,
|
|
248
|
+
onKeydownCapture: ae(x, ["enter"])
|
|
249
|
+
}, null, 40, ne)
|
|
250
|
+
], 2),
|
|
251
|
+
h.value && !e.disabled ? (L(), q("a", {
|
|
252
|
+
key: 0,
|
|
253
|
+
class: "remove-button text-dark flatpickr-reset-btn",
|
|
254
|
+
onClick: W,
|
|
255
|
+
"data-toggle": "",
|
|
256
|
+
title: e.resetTitle
|
|
257
|
+
}, [...a[0] || (a[0] = [
|
|
258
|
+
S("i", { class: "bi bi-x-lg" }, null, -1)
|
|
259
|
+
])], 8, ie)) : Z("", !0),
|
|
260
|
+
S("a", {
|
|
261
|
+
class: "remove-button text-dark flatpickr-calendar-btn",
|
|
262
|
+
"data-toggle": "",
|
|
263
|
+
title: e.calendarTitle
|
|
264
|
+
}, [...a[1] || (a[1] = [
|
|
265
|
+
S("i", { class: "bi bi-calendar3" }, null, -1)
|
|
266
|
+
])], 8, ue),
|
|
267
|
+
ee(re, { errors: _.value }, null, 8, ["errors"])
|
|
268
|
+
], 512));
|
|
269
|
+
}
|
|
270
|
+
});
|
|
271
|
+
export {
|
|
272
|
+
ge as default
|
|
273
|
+
};
|