maz-ui 4.0.0-beta.2 → 4.0.0-beta.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/README.md +1 -1
- package/dist/assets/MazAccordion.DUQCf8vy.css +1 -0
- package/dist/assets/{MazAnimatedCounter.CTG-PC5W.css → MazAnimatedCounter.DkZNPRLp.css} +1 -1
- package/dist/assets/MazAnimatedText.DDqCxrFX.css +1 -0
- package/dist/assets/MazBackdrop.BnhcmjbP.css +1 -0
- package/dist/assets/{MazBadge.DN8tdE8_.css → MazBadge.ChI2DaTU.css} +1 -1
- package/dist/assets/MazBtn.BFhP-9HO.css +1 -0
- package/dist/assets/MazCard.DBuQhXtl.css +1 -0
- package/dist/assets/{MazCardSpotlight.Dy-wuLQq.css → MazCardSpotlight.IbPp_y0j.css} +1 -1
- package/dist/assets/MazCheckbox.aH1IKnrR.css +1 -0
- package/dist/assets/MazChecklist.BzF5KtZ3.css +1 -0
- package/dist/assets/MazDatePicker.8GyrtM-j.css +1 -0
- package/dist/assets/MazDropzone.CXu1QtnY.css +1 -0
- package/dist/assets/MazInput.ByolKDfx.css +1 -0
- package/dist/assets/MazInputCode.FA2z4HQd.css +1 -0
- package/dist/assets/MazInputPhoneNumber.CrXS7DOY.css +1 -0
- package/dist/assets/MazInputTags.KNTpDHof.css +1 -0
- package/dist/assets/MazLazyImg.NlPRN3Nk.css +1 -0
- package/dist/assets/MazLink.CFscNMFr.css +1 -0
- package/dist/assets/MazPickerCalendarMonth.Boe_8k4x.css +1 -0
- package/dist/assets/MazPickerMonthSwitcher.CszcpCcY.css +1 -0
- package/dist/assets/{MazPickerYearSwitcher.Dl30Dwor.css → MazPickerYearSwitcher.Cn-nS-Vv.css} +1 -1
- package/dist/assets/MazPopover.rBpotMKW.css +1 -0
- package/dist/assets/MazPullToRefresh.BQ64UvzA.css +1 -0
- package/dist/assets/MazRadio.aTHM-mpx.css +1 -0
- package/dist/assets/MazRadioButtons.SGytq4d7.css +1 -0
- package/dist/assets/MazReadingProgressBar.CwBVXE3g.css +1 -0
- package/dist/assets/MazSelect.CwjnAZiu.css +1 -0
- package/dist/assets/{MazSelectCountry.D2Qudf0K.css → MazSelectCountry.t3GsKyqw.css} +1 -1
- package/dist/assets/{MazSlider.D5SgmZLH.css → MazSlider.y4qpnD0N.css} +1 -1
- package/dist/assets/MazStepper.BD2gDGAX.css +1 -0
- package/dist/assets/MazSwitch.Bxmh2iFj.css +1 -0
- package/dist/assets/{MazTable.B1tkeUfE.css → MazTable.DMlQdImb.css} +1 -1
- package/dist/assets/MazTableRow.DgBXpK9J.css +1 -0
- package/dist/assets/{MazTabsBar.B9N_jdqU.css → MazTabsBar.gcS2Fc-B.css} +1 -1
- package/dist/assets/{MazTabsContentItem.CHfy19ZF.css → MazTabsContentItem.C84SDmj0.css} +1 -1
- package/dist/assets/MazTextarea.li9dWBax.css +1 -0
- package/dist/assets/{PhoneInput.CyWO76iq.css → PhoneInput.BJiKqOF6.css} +1 -1
- package/dist/assets/{fullscreen-img.pvt6196l.css → fullscreen-img.Bkuz1GOX.css} +1 -1
- package/dist/assets/{toast.kunueRvo.css → toast.CC2VQab8.css} +1 -1
- package/dist/chunks/{MazDatePicker.CT5yJhSN.js → MazDatePicker.De3Ltb2F.js} +29 -31
- package/dist/chunks/{MazDialogPromise.vue_vue_type_script_setup_true_lang.BQvDEofz.js → MazDialogConfirm.vue_vue_type_script_setup_true_lang.Grn2kB3x.js} +78 -18
- package/dist/chunks/{MazDropdown.vue_vue_type_style_index_0_lang.abk1IbMX.js → MazDropdown.vue_vue_type_style_index_0_lang.BES3jpuw.js} +12 -22
- package/dist/chunks/{MazInputPhoneNumber.Uwhn1Q9j.js → MazInputPhoneNumber.Ch-PCGiv.js} +14 -12
- package/dist/chunks/{MazInputPrice.vue_vue_type_script_setup_true_lang.GMKzSu7R.js → MazInputPrice.vue_vue_type_script_setup_true_lang.BA6TDX-T.js} +31 -1
- package/dist/chunks/{MazPickerCalendar.RS6ZMdDK.js → MazPickerCalendar.DKXNI8O4.js} +1 -1
- package/dist/chunks/{MazPickerCalendarMonth.hQBSVkc9.js → MazPickerCalendarMonth.DKBqgrNp.js} +5 -5
- package/dist/chunks/{MazPickerCalendarSwitcher.Cp2ux3E4.js → MazPickerCalendarSwitcher.CzIZol3Z.js} +1 -1
- package/dist/chunks/{MazPickerContainer.DnfB3Dqg.js → MazPickerContainer.Mrh-Q52I.js} +1 -1
- package/dist/chunks/{MazPickerHeader.Dlz2yJ1D.js → MazPickerHeader.Bm9vIrtB.js} +1 -1
- package/dist/chunks/{MazPickerMonthSwitcher.BpfCGGxQ.js → MazPickerMonthSwitcher.BSD2GtY6.js} +5 -6
- package/dist/chunks/{MazPickerTime.EuWWNfid.js → MazPickerTime.D0hilq5b.js} +1 -1
- package/dist/chunks/{MazPickerYearSwitcher.D4aO09D3.js → MazPickerYearSwitcher.BIUYJMvj.js} +8 -27
- package/dist/chunks/{MazSwitch.vue_vue_type_style_index_0_lang.DnCjlD6D.js → MazSwitch.vue_vue_type_style_index_0_lang.CU43Y1ky.js} +2 -2
- package/dist/chunks/{MazTable.vue_vue_type_script_setup_true_lang.bm7ng8fK.js → MazTable.vue_vue_type_script_setup_true_lang.BcTw9Tyh.js} +3 -3
- package/dist/chunks/{PhoneInput.CPjyZ8Sq.js → PhoneInput.BzL1_XS5.js} +5 -4
- package/dist/chunks/{utils.BBuYjMbK.js → dom-events.Bbe7wDQl.js} +221 -115
- package/dist/chunks/{en.BzBlrE0C.js → en.Q_4-KljL.js} +12 -0
- package/dist/chunks/{fullscreen-img.directive.CyOHexcO.js → fullscreen-img.directive.Be383en8.js} +2 -2
- package/dist/chunks/{lazy-img.directive.D5zCo3Zi.js → lazy-img.directive.BLFnGqQa.js} +1 -1
- package/dist/chunks/types.D0Bp_UhS.js +6 -0
- package/dist/chunks/{normalizeString.CFe2M8S_.js → useStringMatching.Ba1yCuA4.js} +40 -1
- package/dist/chunks/{useTranslations.BXuww4ux.js → useTranslations.D5aoYwD7.js} +1 -1
- package/dist/chunks/vClickOutside.DIOiluy0.js +107 -0
- package/dist/components/MazAccordion.js +2 -2
- package/dist/components/MazAnimatedCounter.js +3 -3
- package/dist/components/MazAnimatedText.js +2 -2
- package/dist/components/MazBackdrop.js +3 -3
- package/dist/components/MazBadge.js +5 -4
- package/dist/components/MazBtn.js +9 -7
- package/dist/components/MazCard.js +2 -2
- package/dist/components/MazCardSpotlight.js +4 -4
- package/dist/components/MazCarousel.js +1 -1
- package/dist/components/MazCheckbox.js +10 -12
- package/dist/components/MazChecklist.js +4 -5
- package/dist/components/MazDatePicker.js +1 -1
- package/dist/components/MazDialogConfirm.js +6 -0
- package/dist/components/MazDropdown.js +1 -1
- package/dist/components/MazDropzone.js +5 -5
- package/dist/components/MazGallery.js +2 -2
- package/dist/components/MazInput.js +21 -16
- package/dist/components/MazInputCode.js +2 -2
- package/dist/components/MazInputPhoneNumber.js +1 -1
- package/dist/components/MazInputPrice.js +1 -1
- package/dist/components/MazInputTags.js +2 -2
- package/dist/components/MazLazyImg.js +9 -9
- package/dist/components/MazLink.js +9 -5
- package/dist/components/MazPagination.js +1 -1
- package/dist/components/MazPopover.js +177 -89
- package/dist/components/MazPullToRefresh.js +8 -3
- package/dist/components/MazRadio.js +8 -16
- package/dist/components/MazRadioButtons.js +7 -6
- package/dist/components/MazReadingProgressBar.js +10 -3
- package/dist/components/MazSelect.js +24 -14
- package/dist/components/MazSelectCountry.js +15 -9
- package/dist/components/MazSlider.js +2 -2
- package/dist/components/MazStepper.js +2 -2
- package/dist/components/MazSwitch.js +1 -1
- package/dist/components/MazTable.js +3 -3
- package/dist/components/MazTableCell.js +1 -1
- package/dist/components/MazTableRow.js +3 -3
- package/dist/components/MazTableTitle.js +1 -1
- package/dist/components/MazTabsBar.js +6 -6
- package/dist/components/MazTabsContentItem.js +6 -7
- package/dist/components/MazTextarea.js +24 -3
- package/dist/components/index.js +8 -8
- package/dist/composables/index.js +4 -2
- package/dist/composables/useAos.js +1 -1
- package/dist/composables/useDialog.js +1 -1
- package/dist/composables/useDisplayNames.js +7 -1
- package/dist/composables/useDropzone.js +7 -7
- package/dist/composables/useFormField.js +15 -19
- package/dist/composables/useFormValidator.js +58 -29
- package/dist/composables/useIdleTimeout.js +108 -1
- package/dist/composables/useInjectStrict.js +2 -2
- package/dist/composables/useStringMatching.js +3 -40
- package/dist/composables/useSwipe.js +77 -1
- package/dist/composables/useToast.js +1 -1
- package/dist/composables/useUserVisibility.js +47 -1
- package/dist/composables/useWait.js +1 -1
- package/dist/composables/useWindowSize.js +1 -1
- package/dist/css/main.css +1 -1
- package/dist/directives/index.js +7 -7
- package/dist/directives/vClickOutside.js +4 -102
- package/dist/directives/vFullscreenImg.js +1 -1
- package/dist/directives/vLazyImg.js +2 -2
- package/dist/directives/vTooltip.js +97 -60
- package/dist/index.js +1 -114
- package/dist/plugins/dialog.js +3 -3
- package/dist/plugins/maz-ui.js +150 -143
- package/dist/plugins/toast.js +8 -11
- package/dist/resolvers/MazComponentsResolver.js +7 -1
- package/dist/resolvers/MazDirectivesResolver.js +1 -1
- package/dist/resolvers/MazModulesResolver.js +3 -1
- package/dist/tailwindcss/tailwind.config.js +5 -2
- package/dist/tailwindcss/variables/design-tokens.js +3 -0
- package/dist/types/components/MazAccordion.vue.d.ts +15 -2
- package/dist/types/components/MazBtn.vue.d.ts +1 -0
- package/dist/types/components/MazCard.vue.d.ts +1 -1
- package/dist/types/components/MazCheckbox.vue.d.ts +0 -6
- package/dist/types/components/MazChecklist.vue.d.ts +1 -1
- package/dist/types/components/MazDatePicker.vue.d.ts +15 -23
- package/dist/types/components/MazDialogConfirm/useMazDialogConfirm.d.ts +47 -0
- package/dist/types/components/{MazDialogPromise.vue.d.ts → MazDialogConfirm.vue.d.ts} +43 -10
- package/dist/types/components/MazDropdown.vue.d.ts +12 -12
- package/dist/types/components/MazInput.vue.d.ts +7 -0
- package/dist/types/components/MazInputNumber.vue.d.ts +2 -2
- package/dist/types/components/MazInputPhoneNumber/useLibphonenumber.d.ts +2 -2
- package/dist/types/components/MazInputPhoneNumber/useMazInputPhoneNumber.d.ts +6 -2
- package/dist/types/components/MazInputPhoneNumber.vue.d.ts +38 -15
- package/dist/types/components/MazInputTags.vue.d.ts +1 -1
- package/dist/types/components/MazLazyImg.vue.d.ts +8 -8
- package/dist/types/components/MazLink.vue.d.ts +11 -0
- package/dist/types/components/MazPopover.vue.d.ts +18 -15
- package/dist/types/components/MazRadioButtons.vue.d.ts +1 -1
- package/dist/types/components/MazSelect.vue.d.ts +2 -2
- package/dist/types/components/MazSelectCountry.vue.d.ts +13 -4
- package/dist/types/components/MazStepper.vue.d.ts +13 -2
- package/dist/types/components/MazTable.vue.d.ts +63 -2
- package/dist/types/components/index.d.ts +4 -4
- package/dist/types/components/types.d.ts +1 -0
- package/dist/types/composables/index.d.ts +2 -1
- package/dist/types/composables/useDisplayNames.d.ts +2 -2
- package/dist/types/composables/useDropzone.d.ts +3 -3
- package/dist/types/composables/useFormField.d.ts +16 -56
- package/dist/types/composables/useFormValidator/config.d.ts +2 -2
- package/dist/types/composables/useFormValidator/dom-events.d.ts +19 -0
- package/dist/types/composables/useFormValidator/state-management.d.ts +72 -0
- package/dist/types/composables/useFormValidator/types.d.ts +20 -32
- package/dist/types/composables/useFormValidator/validation.d.ts +37 -0
- package/dist/types/composables/useFormValidator.d.ts +16 -10
- package/dist/types/composables/useIdleTimeout.d.ts +1 -1
- package/dist/types/composables/useInjectStrict.d.ts +1 -1
- package/dist/types/composables/useSwipe.d.ts +1 -1
- package/dist/types/composables/useUserVisibility.d.ts +1 -1
- package/dist/types/directives/vClickOutside.d.ts +11 -18
- package/dist/types/directives/vFullscreenImg/fullscreen-img.directive.d.ts +3 -5
- package/dist/types/directives/vFullscreenImg.d.ts +9 -4
- package/dist/types/directives/vLazyImg/lazy-img.directive.d.ts +3 -5
- package/dist/types/directives/vLazyImg.d.ts +11 -6
- package/dist/types/directives/vTooltip.d.ts +14 -14
- package/dist/types/directives/vZoomImg/zoom-img.directive.d.ts +2 -0
- package/dist/types/directives/vZoomImg.d.ts +9 -5
- package/dist/types/index.d.ts +1 -1
- package/dist/types/plugins/aos.d.ts +30 -4
- package/dist/types/plugins/dialog/DialogHandler.d.ts +2 -2
- package/dist/types/plugins/dialog.d.ts +2 -4
- package/dist/types/plugins/maz-ui.d.ts +2 -63
- package/dist/types/plugins/toast.d.ts +2 -4
- package/dist/types/plugins/wait.d.ts +2 -3
- package/dist/types/tailwindcss/tailwind.config.d.ts +5 -0
- package/dist/types/tailwindcss/variables/design-tokens.d.ts +3 -0
- package/package.json +42 -39
- package/dist/assets/MazAccordion.esK3rR4p.css +0 -1
- package/dist/assets/MazAnimatedText.BrOwWuqf.css +0 -1
- package/dist/assets/MazBackdrop.DNpnLh63.css +0 -1
- package/dist/assets/MazBtn.BnRxVlqS.css +0 -1
- package/dist/assets/MazCard.C6nDaeIC.css +0 -1
- package/dist/assets/MazCheckbox.C_qIngLy.css +0 -1
- package/dist/assets/MazChecklist.CWK_Gl-t.css +0 -1
- package/dist/assets/MazDatePicker.V5JwKPrQ.css +0 -1
- package/dist/assets/MazDropzone.DafxQwbq.css +0 -1
- package/dist/assets/MazInput.DW2KOJHY.css +0 -1
- package/dist/assets/MazInputCode.CG6EJBEk.css +0 -1
- package/dist/assets/MazInputPhoneNumber.vpA2mrZn.css +0 -1
- package/dist/assets/MazInputTags.B_s9J3sw.css +0 -1
- package/dist/assets/MazLazyImg.BNaVtpfX.css +0 -1
- package/dist/assets/MazLink.CCfbrUs0.css +0 -1
- package/dist/assets/MazPickerCalendarMonth.zkrPVHDv.css +0 -1
- package/dist/assets/MazPickerMonthSwitcher.168v7Hs1.css +0 -1
- package/dist/assets/MazPopover.Bth9NWia.css +0 -1
- package/dist/assets/MazPullToRefresh.DABqbGtK.css +0 -1
- package/dist/assets/MazRadio.DKMFWwy_.css +0 -1
- package/dist/assets/MazRadioButtons.BA4rjgK9.css +0 -1
- package/dist/assets/MazReadingProgressBar.n1Is8_Y3.css +0 -1
- package/dist/assets/MazSelect.DZZpDg8z.css +0 -1
- package/dist/assets/MazStepper.DYMde9uq.css +0 -1
- package/dist/assets/MazSwitch.Z1ZMm7tx.css +0 -1
- package/dist/assets/MazTableRow.B78Bd4Kv.css +0 -1
- package/dist/assets/MazTextarea.Dz11mUeK.css +0 -1
- package/dist/chunks/TextareaAutogrow.C22LQx0k.js +0 -25
- package/dist/chunks/debounceCallback.B69vn57Q.js +0 -7
- package/dist/chunks/formatCurrency.C8NzW9Ii.js +0 -34
- package/dist/chunks/formatDate.DZ_OzdnV.js +0 -21
- package/dist/chunks/getCountryFlagUrl.dQjriBXx.js +0 -9
- package/dist/chunks/idleTimeout.-ICpdeGV.js +0 -111
- package/dist/chunks/isServer.BokzeB-Q.js +0 -6
- package/dist/chunks/isStandaloneMode.BpUpOTbA.js +0 -10
- package/dist/chunks/pascalCase.D_nuQ66I.js +0 -11
- package/dist/chunks/swipeHandler.8emelhOL.js +0 -80
- package/dist/chunks/throttle.DN8ARw0a.js +0 -11
- package/dist/chunks/throttleId.7PhWZjcS.js +0 -62
- package/dist/chunks/userVisibility.BbQSJASv.js +0 -50
- package/dist/chunks/x-mark.CTalOvvY.js +0 -23
- package/dist/components/MazDialogPromise.js +0 -6
- package/dist/types/components/MazDialogPromise/useMazDialogPromise.d.ts +0 -54
- package/dist/types/components/MazInputPhoneNumber/types.d.ts +0 -22
- package/dist/types/composables/useFormValidator/utils.d.ts +0 -116
|
@@ -1,15 +1,17 @@
|
|
|
1
|
-
import { defineComponent, mergeModels, defineAsyncComponent, useTemplateRef, computed, useModel, ref, watch, createBlock, openBlock, normalizeStyle, normalizeClass, withCtx, createElementVNode, unref, createCommentVNode, renderSlot, createElementBlock, createVNode, Fragment, renderList, toDisplayString, withModifiers, mergeProps, nextTick } from "vue";
|
|
1
|
+
import { defineComponent, mergeModels, defineAsyncComponent, useTemplateRef, computed, useModel, ref, watch, createBlock, openBlock, normalizeStyle, normalizeClass, withCtx, createElementVNode, unref, createCommentVNode, renderSlot, createElementBlock, createVNode, Fragment, renderList, toDisplayString, withModifiers, mergeProps, createSlots, nextTick } from "vue";
|
|
2
2
|
import { MazMagnifyingGlass, MazNoSymbol, MazChevronDown } from "@maz-ui/icons";
|
|
3
|
-
import { u as useTranslations } from "../chunks/useTranslations.
|
|
4
|
-
import { d as debounceCallback } from "../chunks/debounceCallback.B69vn57Q.js";
|
|
3
|
+
import { u as useTranslations } from "../chunks/useTranslations.D5aoYwD7.js";
|
|
5
4
|
import { i as isClient } from "../chunks/isClient.WI4oSt66.js";
|
|
6
|
-
import { n as normalizeString } from "../chunks/
|
|
5
|
+
import { u as useStringMatching, n as normalizeString } from "../chunks/useStringMatching.Ba1yCuA4.js";
|
|
7
6
|
import { useInstanceUniqId } from "../composables/useInstanceUniqId.js";
|
|
8
|
-
import { useStringMatching } from "../composables/useStringMatching.js";
|
|
9
7
|
import MazInput from "./MazInput.js";
|
|
10
8
|
import MazPopover from "./MazPopover.js";
|
|
11
9
|
import { _ as _export_sfc } from "../chunks/_plugin-vue_export-helper.B--vMWp3.js";
|
|
12
|
-
import '../assets/MazSelect.
|
|
10
|
+
import '../assets/MazSelect.CwjnAZiu.css';let timeout = null;
|
|
11
|
+
function debounceCallback(callback, delay) {
|
|
12
|
+
timeout && clearTimeout(timeout), timeout = setTimeout(callback, delay);
|
|
13
|
+
}
|
|
14
|
+
const _hoisted_1 = ["aria-label"], _hoisted_2 = ["id"], _hoisted_3 = { class: "m-select-list__no-results" }, _hoisted_4 = { class: "m-select-list-optgroup" }, _hoisted_5 = ["tabindex", "onClick"], _sfc_main = /* @__PURE__ */ defineComponent({
|
|
13
15
|
inheritAttrs: !1,
|
|
14
16
|
__name: "MazSelect",
|
|
15
17
|
props: /* @__PURE__ */ mergeModels({
|
|
@@ -149,6 +151,8 @@ import '../assets/MazSelect.DZZpDg8z.css';const _hoisted_1 = ["aria-label"], _ho
|
|
|
149
151
|
}, 1e3));
|
|
150
152
|
}
|
|
151
153
|
function mainInputKeyboardHandler(event) {
|
|
154
|
+
if (event.ctrlKey || event.metaKey || event.altKey)
|
|
155
|
+
return;
|
|
152
156
|
const keyPressed = event.key;
|
|
153
157
|
(keyPressed === "ArrowDown" || keyPressed === "ArrowUp" || /^[\dA-Za-z\u0400-\u04FF]$/.test(keyPressed)) && !isOpen.value && (event.preventDefault(), popoverComponent.value?.open()), /^[\dA-Za-z\u0400-\u04FF]$/.test(keyPressed) && props.search && focusSearchInputAndSetQuery(keyPressed);
|
|
154
158
|
}
|
|
@@ -158,7 +162,7 @@ import '../assets/MazSelect.DZZpDg8z.css';const _hoisted_1 = ["aria-label"], _ho
|
|
|
158
162
|
const item = optionListElement.value?.querySelector(`.m-select-list-item:nth-child(${index + 1})`);
|
|
159
163
|
if (item && optionListScrollWrapper.value) {
|
|
160
164
|
const wrapperRect = optionListScrollWrapper.value.getBoundingClientRect(), itemRect = item.getBoundingClientRect(), scrollTop = item.offsetTop - wrapperRect.height / 2 + itemRect.height / 2;
|
|
161
|
-
optionListScrollWrapper.value.scrollTo({
|
|
165
|
+
optionListScrollWrapper.value.scrollTo?.({
|
|
162
166
|
top: scrollTop,
|
|
163
167
|
behavior: "auto"
|
|
164
168
|
}), nextTick(() => {
|
|
@@ -238,6 +242,7 @@ import '../assets/MazSelect.DZZpDg8z.css';const _hoisted_1 = ["aria-label"], _ho
|
|
|
238
242
|
offset: 0,
|
|
239
243
|
"prefer-position": _ctx.listPosition,
|
|
240
244
|
"fallback-position": "top-start",
|
|
245
|
+
"position-reference": ".m-input-wrapper",
|
|
241
246
|
onClose: onCloseList,
|
|
242
247
|
onOpen: onOpenList
|
|
243
248
|
}, {
|
|
@@ -264,10 +269,7 @@ import '../assets/MazSelect.DZZpDg8z.css';const _hoisted_1 = ["aria-label"], _ho
|
|
|
264
269
|
onFocus: _cache[2] || (_cache[2] = ($event) => emits("focus", $event)),
|
|
265
270
|
onBlur: _cache[3] || (_cache[3] = ($event) => emits("blur", $event)),
|
|
266
271
|
onKeydown: mainInputKeyboardHandler
|
|
267
|
-
}), {
|
|
268
|
-
"left-icon": withCtx(() => [
|
|
269
|
-
renderSlot(_ctx.$slots, "left-icon", {}, void 0, !0)
|
|
270
|
-
]),
|
|
272
|
+
}), createSlots({
|
|
271
273
|
"right-icon": withCtx(() => [
|
|
272
274
|
renderSlot(_ctx.$slots, "right-icon", {}, () => [
|
|
273
275
|
createElementVNode("button", {
|
|
@@ -280,8 +282,16 @@ import '../assets/MazSelect.DZZpDg8z.css';const _hoisted_1 = ["aria-label"], _ho
|
|
|
280
282
|
], 8, _hoisted_1)
|
|
281
283
|
], !0)
|
|
282
284
|
]),
|
|
283
|
-
_:
|
|
284
|
-
},
|
|
285
|
+
_: 2
|
|
286
|
+
}, [
|
|
287
|
+
_ctx.$slots["left-icon"] ? {
|
|
288
|
+
name: "left-icon",
|
|
289
|
+
fn: withCtx(() => [
|
|
290
|
+
renderSlot(_ctx.$slots, "left-icon", {}, void 0, !0)
|
|
291
|
+
]),
|
|
292
|
+
key: "0"
|
|
293
|
+
} : void 0
|
|
294
|
+
]), 1040, ["id", "required", "border-active", "color", "model-value", "size", "block", "placeholder", "label", "autocomplete", "disabled"])
|
|
285
295
|
]),
|
|
286
296
|
default: withCtx(() => [
|
|
287
297
|
createElementVNode("div", {
|
|
@@ -368,7 +378,7 @@ import '../assets/MazSelect.DZZpDg8z.css';const _hoisted_1 = ["aria-label"], _ho
|
|
|
368
378
|
_: 3
|
|
369
379
|
}, 8, ["modelValue", "class", "style", "block", "prefer-position"]));
|
|
370
380
|
}
|
|
371
|
-
}), MazSelect = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
381
|
+
}), MazSelect = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-3679d743"]]);
|
|
372
382
|
export {
|
|
373
383
|
MazSelect as default
|
|
374
384
|
};
|
|
@@ -1,18 +1,23 @@
|
|
|
1
1
|
import { defineComponent, computed, defineAsyncComponent, createElementBlock, openBlock, normalizeStyle, normalizeClass, createVNode, mergeProps, unref, withCtx, createElementVNode, createCommentVNode, renderSlot, createBlock, toDisplayString } from "vue";
|
|
2
|
-
import { u as useTranslations } from "../chunks/useTranslations.
|
|
3
|
-
import { i as isServer } from "../chunks/
|
|
4
|
-
import { g as getCountryFlagUrl } from "../chunks/getCountryFlagUrl.dQjriBXx.js";
|
|
2
|
+
import { u as useTranslations } from "../chunks/useTranslations.D5aoYwD7.js";
|
|
3
|
+
import { i as isServer } from "../chunks/vClickOutside.DIOiluy0.js";
|
|
5
4
|
import { useDisplayNames } from "../composables/useDisplayNames.js";
|
|
6
5
|
import { useInstanceUniqId } from "../composables/useInstanceUniqId.js";
|
|
7
6
|
import MazSelect from "./MazSelect.js";
|
|
8
7
|
import { _ as _export_sfc } from "../chunks/_plugin-vue_export-helper.B--vMWp3.js";
|
|
9
|
-
import '../assets/MazSelectCountry.
|
|
8
|
+
import '../assets/MazSelectCountry.t3GsKyqw.css';function getBrowserLocale() {
|
|
10
9
|
try {
|
|
11
|
-
return isServer() ? void 0 :
|
|
10
|
+
return isServer() ? void 0 : globalThis.navigator.language;
|
|
12
11
|
} catch (error) {
|
|
13
12
|
throw new Error(`[MazInputPhoneNumber] (browserLocale) ${error}`);
|
|
14
13
|
}
|
|
15
14
|
}
|
|
15
|
+
const _supportedCodes = ["ad", "ae", "af", "ag", "ai", "al", "am", "ao", "aq", "ar", "as", "at", "au", "aw", "ax", "az", "ba", "bb", "bd", "be", "bf", "bg", "bh", "bi", "bj", "bl", "bm", "bn", "bo", "bq", "br", "bs", "bt", "bv", "bw", "by", "bz", "ca", "cc", "cd", "cf", "cg", "ch", "ci", "ck", "cl", "cm", "cn", "co", "cr", "cu", "cv", "cw", "cx", "cy", "cz", "de", "dj", "dk", "dm", "do", "dz", "ec", "ee", "eg", "eh", "er", "es", "et", "eu", "fi", "fj", "fk", "fm", "fo", "fr", "ga", "gb", "gb-eng", "gb-nir", "gb-sct", "gb-wls", "gd", "ge", "gf", "gg", "gh", "gi", "gl", "gm", "gn", "gp", "gq", "gr", "gs", "gt", "gu", "gw", "gy", "hk", "hm", "hn", "hr", "ht", "hu", "id", "ie", "il", "im", "in", "io", "iq", "ir", "is", "it", "je", "jm", "jo", "jp", "ke", "kg", "kh", "ki", "km", "kn", "kp", "kr", "kw", "ky", "kz", "la", "lb", "lc", "li", "lk", "lr", "ls", "lt", "lu", "lv", "ly", "ma", "mc", "md", "me", "mf", "mg", "mh", "mk", "ml", "mm", "mn", "mo", "mp", "mq", "mr", "ms", "mt", "mu", "mv", "mw", "mx", "my", "mz", "na", "nc", "ne", "nf", "ng", "ni", "nl", "no", "np", "nr", "nu", "nz", "om", "pa", "pe", "pf", "pg", "ph", "pk", "pl", "pm", "pn", "pr", "ps", "pt", "pw", "py", "qa", "re", "ro", "rs", "ru", "rw", "sa", "sb", "sc", "sd", "se", "sg", "sh", "si", "sj", "sk", "sl", "sm", "sn", "so", "sr", "ss", "st", "sv", "sx", "sy", "sz", "tc", "td", "tf", "tg", "th", "tj", "tk", "tl", "tm", "tn", "to", "tr", "tt", "tv", "tw", "tz", "ua", "ug", "um", "un", "us", "us-ak", "us-al", "us-ar", "us-az", "us-ca", "us-co", "us-ct", "us-de", "us-fl", "us-ga", "us-hi", "us-ia", "us-id", "us-il", "us-in", "us-ks", "us-ky", "us-la", "us-ma", "us-md", "us-me", "us-mi", "us-mn", "us-mo", "us-ms", "us-mt", "us-nc", "us-nd", "us-ne", "us-nh", "us-nj", "us-nm", "us-nv", "us-ny", "us-oh", "us-ok", "us-or", "us-pa", "us-ri", "us-sc", "us-sd", "us-tn", "us-tx", "us-ut", "us-va", "us-vt", "us-wa", "us-wi", "us-wv", "us-wy", "uy", "uz", "va", "vc", "ve", "vg", "vi", "vn", "vu", "wf", "ws", "xk", "ye", "yt", "za", "zm", "zw"];
|
|
16
|
+
function getCountryFlagUrl(countryIsoCode, size) {
|
|
17
|
+
const code = countryIsoCode.toLowerCase();
|
|
18
|
+
if (_supportedCodes.includes(code))
|
|
19
|
+
return size ? `https://flagcdn.com/${size}/${code}.png` : `https://flagcdn.com/${code}.svg`;
|
|
20
|
+
}
|
|
16
21
|
const _hoisted_1 = {
|
|
17
22
|
key: 0,
|
|
18
23
|
class: "m-select-country__select__item__flag-container"
|
|
@@ -45,6 +50,7 @@ const _hoisted_1 = {
|
|
|
45
50
|
options: {},
|
|
46
51
|
displayNamesOptions: { default: () => ({ type: "region", languageDisplay: "standard", fallback: "code", style: "long" }) },
|
|
47
52
|
codesType: {},
|
|
53
|
+
open: { type: Boolean },
|
|
48
54
|
label: {},
|
|
49
55
|
placeholder: {},
|
|
50
56
|
modelValue: {},
|
|
@@ -77,7 +83,7 @@ const _hoisted_1 = {
|
|
|
77
83
|
excludedCodes: () => __props.ignoredCodes,
|
|
78
84
|
preferredCodes: () => __props.preferredCodes,
|
|
79
85
|
codesType: _codesType
|
|
80
|
-
}), countriesOptions = computed(() => __props.options
|
|
86
|
+
}), countriesOptions = computed(() => __props.options ? __props.options : displayNames?.value ?? []), messages = computed(() => ({
|
|
81
87
|
searchPlaceholder: __props.translations?.searchPlaceholder ?? t("selectCountry.searchPlaceholder")
|
|
82
88
|
}));
|
|
83
89
|
function getFlagUrl(code, size = "h20") {
|
|
@@ -120,11 +126,11 @@ const _hoisted_1 = {
|
|
|
120
126
|
required: _ctx.required,
|
|
121
127
|
"search-function": _ctx.searchFunction,
|
|
122
128
|
"format-input-value": _ctx.formatInputValue,
|
|
123
|
-
"display-code": _ctx.displayCode,
|
|
124
129
|
"search-placeholder": messages.value.searchPlaceholder,
|
|
125
130
|
"search-threshold": _ctx.searchThreshold,
|
|
126
131
|
options: countriesOptions.value,
|
|
127
132
|
hint: _ctx.hint,
|
|
133
|
+
open: _ctx.open,
|
|
128
134
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.$emit("update:model-value", $event))
|
|
129
135
|
}), {
|
|
130
136
|
"left-icon": withCtx(() => [
|
|
@@ -185,10 +191,10 @@ const _hoisted_1 = {
|
|
|
185
191
|
], 2)
|
|
186
192
|
]),
|
|
187
193
|
_: 3
|
|
188
|
-
}, 16, ["id", "model-value", "option-value-key", "option-label-key", "option-input-value-key", "max-list-width", "min-list-width", "disabled", "color", "placeholder", "label", "size", "list-position", "error", "warning", "success", "search", "block", "autocomplete", "item-height", "max-list-height", "min-list-height", "required", "search-function", "format-input-value", "
|
|
194
|
+
}, 16, ["id", "model-value", "option-value-key", "option-label-key", "option-input-value-key", "max-list-width", "min-list-width", "disabled", "color", "placeholder", "label", "size", "list-position", "error", "warning", "success", "search", "block", "autocomplete", "item-height", "max-list-height", "min-list-height", "required", "search-function", "format-input-value", "search-placeholder", "search-threshold", "options", "hint", "open"])
|
|
189
195
|
], 6));
|
|
190
196
|
}
|
|
191
|
-
}), MazSelectCountry = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
197
|
+
}), MazSelectCountry = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-c9c7de71"]]);
|
|
192
198
|
export {
|
|
193
199
|
MazSelectCountry as default
|
|
194
200
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineComponent, ref, computed, watch, onMounted, onBeforeUnmount, nextTick, createElementBlock, openBlock, normalizeClass, normalizeStyle, createElementVNode, Fragment, renderList, toDisplayString } from "vue";
|
|
2
2
|
import { d as debounce } from "../chunks/debounce.Brzkn9pm.js";
|
|
3
3
|
import { _ as _export_sfc } from "../chunks/_plugin-vue_export-helper.B--vMWp3.js";
|
|
4
|
-
import '../assets/MazSlider.
|
|
4
|
+
import '../assets/MazSlider.y4qpnD0N.css';function getOffset(elem) {
|
|
5
5
|
const doc = document.documentElement, body = document.body, rect = elem.getBoundingClientRect();
|
|
6
6
|
return {
|
|
7
7
|
y: rect.top + (window.pageYOffset || doc.scrollTop) - (doc.clientTop || body.clientTop || 0),
|
|
@@ -199,7 +199,7 @@ const _hoisted_1 = ["aria-valuenow", "aria-valuemin", "aria-valuemax"], _hoisted
|
|
|
199
199
|
], 8, _hoisted_1)
|
|
200
200
|
], 38));
|
|
201
201
|
}
|
|
202
|
-
}), MazSlider = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
202
|
+
}), MazSlider = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-b7aacef4"]]);
|
|
203
203
|
export {
|
|
204
204
|
MazSlider as default
|
|
205
205
|
};
|
|
@@ -3,7 +3,7 @@ import { MazCheckCircle, MazExclamationTriangle, MazExclamationCircle } from "@m
|
|
|
3
3
|
import MazExpandAnimation from "./MazExpandAnimation.js";
|
|
4
4
|
import MazIcon from "./MazIcon.js";
|
|
5
5
|
import { _ as _export_sfc } from "../chunks/_plugin-vue_export-helper.B--vMWp3.js";
|
|
6
|
-
import '../assets/MazStepper.
|
|
6
|
+
import '../assets/MazStepper.BD2gDGAX.css';const _hoisted_1 = ["id", "disabled", "onClick"], _hoisted_2 = { class: "m-stepper__header__wrapper" }, _hoisted_3 = { class: "m-stepper__count --primary" }, _hoisted_4 = { class: "m-stepper__count__circle" }, _hoisted_5 = { class: "m-stepper__header__content" }, _hoisted_6 = { class: "m-stepper__title" }, _hoisted_7 = {
|
|
7
7
|
key: 0,
|
|
8
8
|
class: "m-stepper__subtitle"
|
|
9
9
|
}, _hoisted_8 = {
|
|
@@ -148,7 +148,7 @@ import '../assets/MazStepper.DYMde9uq.css';const _hoisted_1 = ["id", "disabled",
|
|
|
148
148
|
], 64))), 128))
|
|
149
149
|
], 4));
|
|
150
150
|
}
|
|
151
|
-
}), MazStepper = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
151
|
+
}), MazStepper = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-12289a67"]]);
|
|
152
152
|
export {
|
|
153
153
|
MazStepper as default
|
|
154
154
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { _ as _sfc_main } from "../chunks/MazTable.vue_vue_type_script_setup_true_lang.
|
|
2
|
-
import { m } from "../chunks/MazTable.vue_vue_type_script_setup_true_lang.
|
|
1
|
+
import { _ as _sfc_main } from "../chunks/MazTable.vue_vue_type_script_setup_true_lang.BcTw9Tyh.js";
|
|
2
|
+
import { m } from "../chunks/MazTable.vue_vue_type_script_setup_true_lang.BcTw9Tyh.js";
|
|
3
3
|
import { _ as _export_sfc } from "../chunks/_plugin-vue_export-helper.B--vMWp3.js";
|
|
4
|
-
import '../assets/MazTable.
|
|
4
|
+
import '../assets/MazTable.DMlQdImb.css';const MazTable = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-3f352ade"]]);
|
|
5
5
|
export {
|
|
6
6
|
MazTable as default,
|
|
7
7
|
m as mazTableKey
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineComponent, createElementBlock, openBlock, normalizeClass, unref, renderSlot } from "vue";
|
|
2
2
|
import { useInjectStrict } from "../composables/useInjectStrict.js";
|
|
3
|
-
import { m as mazTableKey } from "../chunks/MazTable.vue_vue_type_script_setup_true_lang.
|
|
3
|
+
import { m as mazTableKey } from "../chunks/MazTable.vue_vue_type_script_setup_true_lang.BcTw9Tyh.js";
|
|
4
4
|
import { _ as _export_sfc } from "../chunks/_plugin-vue_export-helper.B--vMWp3.js";
|
|
5
5
|
import '../assets/MazTableCell.BPgmqAMD.css';const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
6
6
|
__name: "MazTableCell",
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { defineComponent, createElementBlock, openBlock, normalizeClass, unref, renderSlot } from "vue";
|
|
2
2
|
import { useInjectStrict } from "../composables/useInjectStrict.js";
|
|
3
|
-
import { m as mazTableKey } from "../chunks/MazTable.vue_vue_type_script_setup_true_lang.
|
|
3
|
+
import { m as mazTableKey } from "../chunks/MazTable.vue_vue_type_script_setup_true_lang.BcTw9Tyh.js";
|
|
4
4
|
import { _ as _export_sfc } from "../chunks/_plugin-vue_export-helper.B--vMWp3.js";
|
|
5
|
-
import '../assets/MazTableRow.
|
|
5
|
+
import '../assets/MazTableRow.DgBXpK9J.css';const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
6
6
|
__name: "MazTableRow",
|
|
7
7
|
props: {
|
|
8
8
|
hoverable: { type: Boolean, default: !0 }
|
|
@@ -19,7 +19,7 @@ import '../assets/MazTableRow.B78Bd4Kv.css';const _sfc_main = /* @__PURE__ */ de
|
|
|
19
19
|
renderSlot(_ctx.$slots, "default", {}, void 0, !0)
|
|
20
20
|
], 2));
|
|
21
21
|
}
|
|
22
|
-
}), MazTableRow = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
22
|
+
}), MazTableRow = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-e2e08e77"]]);
|
|
23
23
|
export {
|
|
24
24
|
MazTableRow as default
|
|
25
25
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineComponent, createElementBlock, openBlock, normalizeClass, unref, renderSlot } from "vue";
|
|
2
2
|
import { useInjectStrict } from "../composables/useInjectStrict.js";
|
|
3
|
-
import { m as mazTableKey } from "../chunks/MazTable.vue_vue_type_script_setup_true_lang.
|
|
3
|
+
import { m as mazTableKey } from "../chunks/MazTable.vue_vue_type_script_setup_true_lang.BcTw9Tyh.js";
|
|
4
4
|
import { _ as _export_sfc } from "../chunks/_plugin-vue_export-helper.B--vMWp3.js";
|
|
5
5
|
import '../assets/MazTableTitle.BjJMgQFY.css';const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
6
6
|
__name: "MazTableTitle",
|
|
@@ -2,7 +2,7 @@ import { defineComponent, defineAsyncComponent, ref, computed, onBeforeMount, on
|
|
|
2
2
|
import { s as sleep } from "../chunks/sleep.BLRH1qZG.js";
|
|
3
3
|
import { useInjectStrict } from "../composables/useInjectStrict.js";
|
|
4
4
|
import { _ as _export_sfc } from "../chunks/_plugin-vue_export-helper.B--vMWp3.js";
|
|
5
|
-
import '../assets/MazTabsBar.
|
|
5
|
+
import '../assets/MazTabsBar.gcS2Fc-B.css';const _hoisted_1 = ["disabled", "onClick"], _sfc_main = /* @__PURE__ */ defineComponent({
|
|
6
6
|
__name: "MazTabsBar",
|
|
7
7
|
props: {
|
|
8
8
|
items: {},
|
|
@@ -44,7 +44,7 @@ import '../assets/MazTabsBar.B9N_jdqU.css';const _hoisted_1 = ["disabled", "onCl
|
|
|
44
44
|
return;
|
|
45
45
|
const scrollOffset = 50;
|
|
46
46
|
if (activeTab.offsetLeft - scrollOffset < tabsBar.scrollLeft || activeTab.offsetLeft + activeTab.offsetWidth > tabsBar.scrollLeft + tabsBar.clientWidth) {
|
|
47
|
-
const tabBarPaddingLeft =
|
|
47
|
+
const tabBarPaddingLeft = globalThis.getComputedStyle(tabsBar, "padding-left").paddingLeft, tabsBarPaddingOffset = Number(tabBarPaddingLeft.slice(0, -2));
|
|
48
48
|
tabsBar.scrollTo({
|
|
49
49
|
left: activeTab.offsetLeft - tabsBarPaddingOffset - scrollOffset,
|
|
50
50
|
behavior: tabsBarHasScrollAnimation.value ? "smooth" : "instant"
|
|
@@ -75,12 +75,12 @@ import '../assets/MazTabsBar.B9N_jdqU.css';const _hoisted_1 = ["disabled", "onCl
|
|
|
75
75
|
}
|
|
76
76
|
);
|
|
77
77
|
function getQueryParamTab() {
|
|
78
|
-
const urlActuelle = new URL(
|
|
78
|
+
const urlActuelle = new URL(globalThis.location.href);
|
|
79
79
|
return Number(urlActuelle.searchParams.get(__props.queryParam));
|
|
80
80
|
}
|
|
81
81
|
function addOrUpdateQueryParamTab(tab) {
|
|
82
|
-
const urlActuelle = new URL(
|
|
83
|
-
urlActuelle.searchParams.set(__props.queryParam, String(tab)),
|
|
82
|
+
const urlActuelle = new URL(globalThis.location.href);
|
|
83
|
+
urlActuelle.searchParams.set(__props.queryParam, String(tab)), globalThis.history.replaceState({}, document.title, urlActuelle.toString());
|
|
84
84
|
}
|
|
85
85
|
return onMounted(() => {
|
|
86
86
|
__props.persistent && updateCurrentTab(getQueryParamTab() || currentTab.value || 1);
|
|
@@ -132,7 +132,7 @@ import '../assets/MazTabsBar.B9N_jdqU.css';const _hoisted_1 = ["disabled", "onCl
|
|
|
132
132
|
], 14, _hoisted_1))), 128))
|
|
133
133
|
], 2));
|
|
134
134
|
}
|
|
135
|
-
}), MazTabsBar = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
135
|
+
}), MazTabsBar = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-318a382c"]]);
|
|
136
136
|
export {
|
|
137
137
|
MazTabsBar as default
|
|
138
138
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent, ref, watch, computed, createBlock, openBlock, Transition, withCtx,
|
|
1
|
+
import { defineComponent, ref, watch, computed, createBlock, openBlock, Transition, withCtx, createElementBlock, createCommentVNode, renderSlot } from "vue";
|
|
2
2
|
import { useInjectStrict } from "../composables/useInjectStrict.js";
|
|
3
3
|
import { _ as _export_sfc } from "../chunks/_plugin-vue_export-helper.B--vMWp3.js";
|
|
4
|
-
import '../assets/MazTabsContentItem.
|
|
4
|
+
import '../assets/MazTabsContentItem.C84SDmj0.css';const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
5
5
|
__name: "MazTabsContentItem",
|
|
6
6
|
props: {
|
|
7
7
|
tab: { type: Number, required: !0 }
|
|
@@ -21,20 +21,19 @@ import '../assets/MazTabsContentItem.CHfy19ZF.css';const _sfc_main = /* @__PURE_
|
|
|
21
21
|
const itemTabNumber = computed(() => props.tab - 1), isCurrentTab = computed(() => currentTab.value - 1 === itemTabNumber.value);
|
|
22
22
|
return (_ctx, _cache) => (openBlock(), createBlock(Transition, { name: transitionName.value }, {
|
|
23
23
|
default: withCtx(() => [
|
|
24
|
-
|
|
24
|
+
isCurrentTab.value ? (openBlock(), createElementBlock("div", {
|
|
25
|
+
key: 0,
|
|
25
26
|
ref_key: "MazTabsContentItem",
|
|
26
27
|
ref: MazTabsContentItem2,
|
|
27
28
|
class: "m-tabs-content-item m-reset-css"
|
|
28
29
|
}, [
|
|
29
30
|
renderSlot(_ctx.$slots, "default", {}, void 0, !0)
|
|
30
|
-
], 512),
|
|
31
|
-
[vShow, isCurrentTab.value]
|
|
32
|
-
])
|
|
31
|
+
], 512)) : createCommentVNode("", !0)
|
|
33
32
|
]),
|
|
34
33
|
_: 3
|
|
35
34
|
}, 8, ["name"]));
|
|
36
35
|
}
|
|
37
|
-
}), MazTabsContentItem = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
36
|
+
}), MazTabsContentItem = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-36798058"]]);
|
|
38
37
|
export {
|
|
39
38
|
MazTabsContentItem as default
|
|
40
39
|
};
|
|
@@ -1,8 +1,29 @@
|
|
|
1
1
|
import { defineComponent, ref, computed, onMounted, onBeforeUnmount, useSlots, createElementBlock, openBlock, normalizeStyle, unref, normalizeClass, createCommentVNode, withDirectives, renderSlot, createTextVNode, toDisplayString, createElementVNode, mergeProps, toHandlers, vModelText } from "vue";
|
|
2
|
-
import {
|
|
2
|
+
import { d as debounce } from "../chunks/debounce.Brzkn9pm.js";
|
|
3
3
|
import { useInstanceUniqId } from "../composables/useInstanceUniqId.js";
|
|
4
4
|
import { _ as _export_sfc } from "../chunks/_plugin-vue_export-helper.B--vMWp3.js";
|
|
5
|
-
import '../assets/MazTextarea.
|
|
5
|
+
import '../assets/MazTextarea.li9dWBax.css';class TextareaAutogrow {
|
|
6
|
+
element;
|
|
7
|
+
constructor(element) {
|
|
8
|
+
this.element = element, this.onFocus = this.onFocus.bind(this), this.autogrow = this.autogrow.bind(this), this.onResize = debounce(this.onResize.bind(this), 200), this.connect();
|
|
9
|
+
}
|
|
10
|
+
connect() {
|
|
11
|
+
this.element.addEventListener("focus", this.onFocus), this.element.style.resize = "none", this.element.style.boxSizing = "border-box";
|
|
12
|
+
}
|
|
13
|
+
disconnect() {
|
|
14
|
+
window.removeEventListener("resize", this.onResize), this.element.removeEventListener("input", this.autogrow);
|
|
15
|
+
}
|
|
16
|
+
onFocus() {
|
|
17
|
+
this.autogrow(), this.element.addEventListener("input", this.autogrow), window.addEventListener("resize", this.onResize), this.element.removeEventListener("focus", this.onFocus);
|
|
18
|
+
}
|
|
19
|
+
onResize() {
|
|
20
|
+
this.autogrow();
|
|
21
|
+
}
|
|
22
|
+
autogrow() {
|
|
23
|
+
this.element.style.height = "auto", this.element.style.overflow = "hidden", this.element.style.height = `${this.element.scrollHeight}px`;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
const _hoisted_1 = ["for"], _hoisted_2 = ["for"], _hoisted_3 = { key: 1 }, _hoisted_4 = { key: 2 }, _hoisted_5 = ["id", "placeholder", "name", "disabled", "required"], _hoisted_6 = {
|
|
6
27
|
key: 1,
|
|
7
28
|
class: "m-textarea__append"
|
|
8
29
|
}, _sfc_main = /* @__PURE__ */ defineComponent({
|
|
@@ -141,7 +162,7 @@ import '../assets/MazTextarea.Dz11mUeK.css';const _hoisted_1 = ["for"], _hoisted
|
|
|
141
162
|
])) : createCommentVNode("", !0)
|
|
142
163
|
], 14, _hoisted_1));
|
|
143
164
|
}
|
|
144
|
-
}), MazTextarea = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
165
|
+
}), MazTextarea = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-6648fe59"]]);
|
|
145
166
|
export {
|
|
146
167
|
MazTextarea as default
|
|
147
168
|
};
|
package/dist/components/index.js
CHANGED
|
@@ -14,11 +14,11 @@ import { _ } from "../chunks/MazChart.vue_vue_type_script_setup_true_lang.JSYXGy
|
|
|
14
14
|
import { default as default14 } from "./MazCheckbox.js";
|
|
15
15
|
import { default as default15 } from "./MazChecklist.js";
|
|
16
16
|
import { default as default16 } from "./MazCircularProgressBar.js";
|
|
17
|
-
import { M } from "../chunks/MazDatePicker.
|
|
17
|
+
import { M } from "../chunks/MazDatePicker.De3Ltb2F.js";
|
|
18
18
|
import { default as default17 } from "./MazDialog.js";
|
|
19
|
-
import { _ as _2, u } from "../chunks/
|
|
19
|
+
import { _ as _2, u } from "../chunks/MazDialogConfirm.vue_vue_type_script_setup_true_lang.Grn2kB3x.js";
|
|
20
20
|
import { default as default18 } from "./MazDrawer.js";
|
|
21
|
-
import { _ as _3 } from "../chunks/MazDropdown.vue_vue_type_style_index_0_lang.
|
|
21
|
+
import { _ as _3 } from "../chunks/MazDropdown.vue_vue_type_style_index_0_lang.BES3jpuw.js";
|
|
22
22
|
import { default as default19 } from "./MazDropzone.js";
|
|
23
23
|
import { default as default20 } from "./MazExpandAnimation.js";
|
|
24
24
|
import { default as default21 } from "./MazFullscreenLoader.js";
|
|
@@ -27,8 +27,8 @@ import { default as default23 } from "./MazIcon.js";
|
|
|
27
27
|
import { default as default24 } from "./MazInput.js";
|
|
28
28
|
import { default as default25 } from "./MazInputCode.js";
|
|
29
29
|
import { _ as _4 } from "../chunks/MazInputNumber.vue_vue_type_style_index_0_lang.B6DYpHfi.js";
|
|
30
|
-
import { M as M2 } from "../chunks/MazInputPhoneNumber.
|
|
31
|
-
import { _ as _5 } from "../chunks/MazInputPrice.vue_vue_type_script_setup_true_lang.
|
|
30
|
+
import { M as M2 } from "../chunks/MazInputPhoneNumber.Ch-PCGiv.js";
|
|
31
|
+
import { _ as _5 } from "../chunks/MazInputPrice.vue_vue_type_script_setup_true_lang.BA6TDX-T.js";
|
|
32
32
|
import { default as default26 } from "./MazInputTags.js";
|
|
33
33
|
import { default as default27 } from "./MazLazyImg.js";
|
|
34
34
|
import { default as default28 } from "./MazLink.js";
|
|
@@ -44,7 +44,7 @@ import { default as default37 } from "./MazSelectCountry.js";
|
|
|
44
44
|
import { default as default38 } from "./MazSlider.js";
|
|
45
45
|
import { default as default39 } from "./MazSpinner.js";
|
|
46
46
|
import { default as default40 } from "./MazStepper.js";
|
|
47
|
-
import { _ as _6 } from "../chunks/MazSwitch.vue_vue_type_style_index_0_lang.
|
|
47
|
+
import { _ as _6 } from "../chunks/MazSwitch.vue_vue_type_style_index_0_lang.CU43Y1ky.js";
|
|
48
48
|
import { default as default41 } from "./MazTable.js";
|
|
49
49
|
import { default as default42 } from "./MazTableCell.js";
|
|
50
50
|
import { default as default43 } from "./MazTableRow.js";
|
|
@@ -73,7 +73,7 @@ export {
|
|
|
73
73
|
default16 as MazCircularProgressBar,
|
|
74
74
|
M as MazDatePicker,
|
|
75
75
|
default17 as MazDialog,
|
|
76
|
-
_2 as
|
|
76
|
+
_2 as MazDialogConfirm,
|
|
77
77
|
default18 as MazDrawer,
|
|
78
78
|
_3 as MazDropdown,
|
|
79
79
|
default19 as MazDropzone,
|
|
@@ -111,5 +111,5 @@ export {
|
|
|
111
111
|
_8 as MazTabsContent,
|
|
112
112
|
default46 as MazTabsContentItem,
|
|
113
113
|
default47 as MazTextarea,
|
|
114
|
-
u as
|
|
114
|
+
u as useMazDialogConfirm
|
|
115
115
|
};
|
|
@@ -2,6 +2,7 @@ import { useAos } from "./useAos.js";
|
|
|
2
2
|
import { useBreakpoints } from "./useBreakpoints.js";
|
|
3
3
|
import { useDialog } from "./useDialog.js";
|
|
4
4
|
import { useDisplayNames } from "./useDisplayNames.js";
|
|
5
|
+
import { useDropzone } from "./useDropzone.js";
|
|
5
6
|
import { useFormField } from "./useFormField.js";
|
|
6
7
|
import { useFormValidator } from "./useFormValidator.js";
|
|
7
8
|
import { useFreezeValue } from "./useFreezeValue.js";
|
|
@@ -10,7 +11,7 @@ import { useInjectStrict } from "./useInjectStrict.js";
|
|
|
10
11
|
import { useInstanceUniqId } from "./useInstanceUniqId.js";
|
|
11
12
|
import { useMountComponent } from "./useMountComponent.js";
|
|
12
13
|
import { useReadingTime } from "./useReadingTime.js";
|
|
13
|
-
import {
|
|
14
|
+
import { u } from "../chunks/useStringMatching.Ba1yCuA4.js";
|
|
14
15
|
import { useSwipe } from "./useSwipe.js";
|
|
15
16
|
import { useTimer } from "./useTimer.js";
|
|
16
17
|
import { useToast } from "./useToast.js";
|
|
@@ -22,6 +23,7 @@ export {
|
|
|
22
23
|
useBreakpoints,
|
|
23
24
|
useDialog,
|
|
24
25
|
useDisplayNames,
|
|
26
|
+
useDropzone,
|
|
25
27
|
useFormField,
|
|
26
28
|
useFormValidator,
|
|
27
29
|
useFreezeValue,
|
|
@@ -30,7 +32,7 @@ export {
|
|
|
30
32
|
useInstanceUniqId,
|
|
31
33
|
useMountComponent,
|
|
32
34
|
useReadingTime,
|
|
33
|
-
useStringMatching,
|
|
35
|
+
u as useStringMatching,
|
|
34
36
|
useSwipe,
|
|
35
37
|
useTimer,
|
|
36
38
|
useToast,
|
|
@@ -7,6 +7,12 @@ const bcp47Codes = ["af-ZA", "sq-AL", "ar-DZ", "ar-BH", "ar-EG", "ar-IQ", "ar-JO
|
|
|
7
7
|
style: "long",
|
|
8
8
|
localeMatcher: "lookup"
|
|
9
9
|
}, displayNamesCache = /* @__PURE__ */ new Map();
|
|
10
|
+
let cacheCleanupTimer = null;
|
|
11
|
+
function scheduleCacheCleanup() {
|
|
12
|
+
cacheCleanupTimer && clearTimeout(cacheCleanupTimer), cacheCleanupTimer = setTimeout(() => {
|
|
13
|
+
displayNamesCache.size > 50 && displayNamesCache.clear(), cacheCleanupTimer = null;
|
|
14
|
+
}, 300 * 1e3);
|
|
15
|
+
}
|
|
10
16
|
function isSameLanguageThanCode(language, code) {
|
|
11
17
|
return !language || language?.toLocaleLowerCase() === code.toLocaleLowerCase();
|
|
12
18
|
}
|
|
@@ -21,7 +27,7 @@ function getDisplayNamesInstance(locale, options = DEFAULT_DISPLAY_NAMES_OPTIONS
|
|
|
21
27
|
...options,
|
|
22
28
|
type: options.type ?? DEFAULT_DISPLAY_NAMES_OPTIONS.type
|
|
23
29
|
});
|
|
24
|
-
displayNamesCache.set(cacheKey, instance);
|
|
30
|
+
displayNamesCache.set(cacheKey, instance), scheduleCacheCleanup();
|
|
25
31
|
} catch (error) {
|
|
26
32
|
return console.warn(`[maz-ui] (useDisplayNames) Failed to create DisplayNames instance for locale ${locale}:`, error), null;
|
|
27
33
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { i as isClient } from "../chunks/isClient.WI4oSt66.js";
|
|
2
2
|
import { ref, shallowRef, watch, toValue, onBeforeUnmount, unref } from "vue";
|
|
3
|
-
function
|
|
3
|
+
function useDropzone(target, options = {}) {
|
|
4
4
|
const isOverDropZone = ref(!1), isOverError = ref(!1), files = shallowRef(null);
|
|
5
5
|
let counter = 0, isValid = !0;
|
|
6
6
|
if (isClient()) {
|
|
@@ -16,7 +16,7 @@ function useDropZone(target, options = {}) {
|
|
|
16
16
|
const types = Array.from(items ?? []).map((item) => item.type), dataTypesValid = checkDataTypes(types), multipleFilesValid = multiple || items.length <= 1;
|
|
17
17
|
return dataTypesValid && multipleFilesValid;
|
|
18
18
|
}, isSafari = function() {
|
|
19
|
-
return /^(?:(?!chrome|android).)*safari/i.test(navigator.userAgent) && !("chrome" in
|
|
19
|
+
return /^(?:(?!chrome|android).)*safari/i.test(navigator.userAgent) && !("chrome" in globalThis);
|
|
20
20
|
}, handleDragEvent = function(event, eventType) {
|
|
21
21
|
const dataTransferItemList = event.dataTransfer?.items;
|
|
22
22
|
isValid = (dataTransferItemList && checkValidity(dataTransferItemList)) ?? !1, preventDefaultForUnhandled && event.preventDefault();
|
|
@@ -37,11 +37,11 @@ function useDropZone(target, options = {}) {
|
|
|
37
37
|
}
|
|
38
38
|
}, removeEventListeners = function() {
|
|
39
39
|
const targetElement = toValue(target);
|
|
40
|
-
targetElement && (targetElement.removeEventListener("dragenter",
|
|
40
|
+
targetElement && (targetElement.removeEventListener("dragenter", dragEnterHandler), targetElement.removeEventListener("dragover", dragOverHandler), targetElement.removeEventListener("dragleave", dragLeaveHandler), targetElement.removeEventListener("drop", dropHandler));
|
|
41
41
|
};
|
|
42
|
-
const _options = typeof options == "function" ? { onDrop: options } : options, multiple = _options.multiple ?? !0, preventDefaultForUnhandled = _options.preventDefaultForUnhandled ?? !1;
|
|
43
|
-
watch(() => toValue(target), (element) => {
|
|
44
|
-
|
|
42
|
+
const _options = typeof options == "function" ? { onDrop: options } : options, multiple = _options.multiple ?? !0, preventDefaultForUnhandled = _options.preventDefaultForUnhandled ?? !1, dragEnterHandler = (event) => handleDragEvent(event, "enter"), dragOverHandler = (event) => handleDragEvent(event, "over"), dragLeaveHandler = (event) => handleDragEvent(event, "leave"), dropHandler = (event) => handleDragEvent(event, "drop");
|
|
43
|
+
watch(() => toValue(target), (element, oldElement) => {
|
|
44
|
+
oldElement && (oldElement.removeEventListener("dragenter", dragEnterHandler), oldElement.removeEventListener("dragover", dragOverHandler), oldElement.removeEventListener("dragleave", dragLeaveHandler), oldElement.removeEventListener("drop", dropHandler)), element && (element.addEventListener("dragenter", dragEnterHandler), element.addEventListener("dragover", dragOverHandler), element.addEventListener("dragleave", dragLeaveHandler), element.addEventListener("drop", dropHandler));
|
|
45
45
|
}, { immediate: !0 }), onBeforeUnmount(() => {
|
|
46
46
|
removeEventListeners();
|
|
47
47
|
});
|
|
@@ -53,5 +53,5 @@ function useDropZone(target, options = {}) {
|
|
|
53
53
|
};
|
|
54
54
|
}
|
|
55
55
|
export {
|
|
56
|
-
|
|
56
|
+
useDropzone
|
|
57
57
|
};
|