maz-ui 3.49.0 → 3.49.2
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/components/MazAnimatedCounter.mjs +78 -73
- package/components/MazAnimatedElement.mjs +12 -12
- package/components/MazAnimatedText.mjs +5 -5
- package/components/MazBottomSheet.mjs +1 -1
- package/components/MazBtn.mjs +1 -1
- package/components/MazCard.mjs +1 -1
- package/components/MazCarousel.mjs +1 -1
- package/components/MazChecklist.mjs +1 -1
- package/components/MazCircularProgressBar.mjs +128 -123
- package/components/MazDialog.mjs +1 -1
- package/components/MazDialogPromise.mjs +1 -1
- package/components/MazDrawer.mjs +1 -1
- package/components/MazDropdown.mjs +1 -1
- package/components/MazInput.mjs +1 -1
- package/components/MazInputNumber.mjs +1 -1
- package/components/MazInputPrice.mjs +1 -1
- package/components/MazInputTags.mjs +1 -1
- package/components/MazPagination.mjs +1 -1
- package/components/MazPhoneNumberInput.mjs +1 -1
- package/components/MazPicker.mjs +1 -1
- package/components/MazSelect.mjs +1 -1
- package/components/MazTable.mjs +1 -1
- package/components/assets/MazAnimatedCounter.css +1 -1
- package/components/assets/MazAnimatedElement.css +1 -1
- package/components/assets/MazAnimatedText.css +1 -1
- package/components/assets/MazBtn.css +1 -1
- package/components/assets/MazCard.css +1 -1
- package/components/assets/MazCircularProgressBar.css +1 -1
- package/components/assets/MazInput.css +1 -1
- package/components/assets/MazInputNumber.css +1 -1
- package/components/assets/MazInputPrice.css +1 -1
- package/components/assets/MazInputTags.css +1 -1
- package/components/assets/MazPagination.css +1 -1
- package/components/assets/MazPhoneNumberInput.css +1 -1
- package/components/assets/MazPicker.css +1 -1
- package/components/chunks/{MazBottomSheet-CNFupuJS.mjs → MazBottomSheet-CIXEEUpN.mjs} +1 -1
- package/components/chunks/MazBtn-9Jk8ZkBq.mjs +103 -0
- package/components/chunks/{MazBtn-BJNzz7YT.mjs → MazBtn-BHD7Xbr_.mjs} +3 -3
- package/components/chunks/{MazBtn-CKDJOBcC.mjs → MazBtn-BT4o0zLa.mjs} +2 -2
- package/components/chunks/{MazBtn-D53RC3KP.mjs → MazBtn-Ba8ff2Nu.mjs} +3 -3
- package/components/chunks/{MazBtn-DYURBZtp.mjs → MazBtn-Bdhu8JTk.mjs} +2 -2
- package/components/chunks/{MazBtn-BO1U1gVG.mjs → MazBtn-CbTqLKv1.mjs} +3 -3
- package/components/chunks/MazBtn-DAzJbcTl.mjs +103 -0
- package/components/chunks/{MazBtn-CP-m-KDm.mjs → MazBtn-DCGXwqRM.mjs} +3 -3
- package/components/chunks/MazBtn-DGIjSCP2.mjs +103 -0
- package/components/chunks/{MazBtn-CUoFOAML.mjs → MazBtn-DXinft-p.mjs} +3 -3
- package/components/chunks/MazBtn-DnpSuILi.mjs +103 -0
- package/components/chunks/{MazBtn-BugQGoO-.mjs → MazBtn-GYr50Ap4.mjs} +3 -3
- package/components/chunks/{MazBtn-Cyn7ObTB.mjs → MazBtn-IBh1tCot.mjs} +3 -3
- package/components/chunks/{MazBtn-MvFibIXn.mjs → MazBtn-UDAwHekF.mjs} +3 -3
- package/components/chunks/{MazCard-D-q6vhWd.mjs → MazCard-CQBFy8r_.mjs} +4 -4
- package/components/chunks/{MazCarousel-Z4XypOn_.mjs → MazCarousel-Bcn7nKDo.mjs} +1 -1
- package/components/chunks/{MazCheckbox-DJi0g4uK.mjs → MazCheckbox-B8Rnqa6O.mjs} +1 -1
- package/components/chunks/{MazCheckbox-DafMJoEw.mjs → MazCheckbox-Br41Nrq7.mjs} +1 -1
- package/components/chunks/{MazCheckbox-BImOZ1aM.mjs → MazCheckbox-t4i9eR04.mjs} +1 -1
- package/components/chunks/{MazChecklist-DaEf6wix.mjs → MazChecklist-DLr57bfX.mjs} +1 -1
- package/components/chunks/{MazDialog-PVsds2Mw.mjs → MazDialog-ak7mSNff.mjs} +1 -1
- package/components/chunks/{MazDialogPromise-BdtiOZGU.mjs → MazDialogPromise-JvS9f5Of.mjs} +2 -2
- package/components/chunks/{MazDrawer-CMHe_JEh.mjs → MazDrawer-CTsb4x_4.mjs} +1 -1
- package/components/chunks/{MazDropdown-DpGSAqe0.mjs → MazDropdown-BxMokXYe.mjs} +1 -1
- package/components/chunks/{MazGallery-BtuCo-H0.mjs → MazGallery-C7Zp1iYc.mjs} +2 -2
- package/components/chunks/MazIcon-C47uJeFY.mjs +4 -0
- package/components/chunks/{MazIcon-Bnebkvf6.mjs → MazIcon-mGVzj6Xw.mjs} +1 -1
- package/components/chunks/{MazInput-C3QweR84.mjs → MazInput-BK2OXh6D.mjs} +73 -84
- package/components/chunks/{MazInput-DvaaM9Iq.mjs → MazInput-BWHAOFtO.mjs} +66 -77
- package/components/chunks/{MazInput-DjvBbUZl.mjs → MazInput-C2_KlBtJ.mjs} +67 -78
- package/components/chunks/{MazInputNumber-D904Pg1R.mjs → MazInputNumber-Bw6O0AGT.mjs} +104 -115
- package/components/chunks/{MazInputPrice-CQiJFPWB.mjs → MazInputPrice-BCM9ga_h.mjs} +104 -115
- package/components/chunks/{MazInputTags-BPSG1X1a.mjs → MazInputTags-B0B93sN-.mjs} +127 -138
- package/components/chunks/{MazLink-DnnBkVEE.mjs → MazLink-PEtIzV5x.mjs} +1 -1
- package/components/chunks/{MazLoadingBar-Dm14PSs6.mjs → MazLoadingBar-BjzRnYVR.mjs} +1 -1
- package/components/chunks/{MazPagination-CuCKS1Qr.mjs → MazPagination-DKseqKmF.mjs} +2 -2
- package/components/chunks/{MazPhoneNumberInput-CKpP3yWz.mjs → MazPhoneNumberInput-CPm6LjfT.mjs} +354 -365
- package/components/chunks/MazPicker-BHBE1cC_.mjs +2482 -0
- package/components/chunks/{MazPickerMonthSwitcher-BDxk_Msi.mjs → MazPickerMonthSwitcher-CXfxTBNH.mjs} +1 -1
- package/components/chunks/{MazPickerShortcuts-DtHvsdEW.mjs → MazPickerShortcuts-BLuYu65Q.mjs} +1 -1
- package/components/chunks/{MazPickerYearSwitcher-DXkaTXFw.mjs → MazPickerYearSwitcher-CpSOH48Y.mjs} +1 -1
- package/components/chunks/{MazSelect-VAPsGKXy.mjs → MazSelect-CdSRiSW9.mjs} +3 -3
- package/components/chunks/{MazSelect-cthYMQqx.mjs → MazSelect-uHsahxjj.mjs} +188 -199
- package/components/chunks/{MazSpinner-Ba5WXlbx.mjs → MazSpinner-B3mUm5mz.mjs} +1 -1
- package/components/chunks/MazSpinner-B698e0ut.mjs +34 -0
- package/components/chunks/{MazSpinner-B5j5EaKc.mjs → MazSpinner-BEW98Fow.mjs} +1 -1
- package/components/chunks/{MazSpinner-94rvbsAk.mjs → MazSpinner-BqMt92KT.mjs} +1 -1
- package/components/chunks/{MazSpinner-DtFpBxRT.mjs → MazSpinner-Bs8Z0Ewo.mjs} +1 -1
- package/components/chunks/MazSpinner-C2OD6LW3.mjs +34 -0
- package/components/chunks/MazSpinner-C3zQC9oz.mjs +34 -0
- package/components/chunks/MazSpinner-C5pIord0.mjs +34 -0
- package/components/chunks/MazSpinner-C8KOYxzi.mjs +34 -0
- package/components/chunks/{MazSpinner-DLR4lVAu.mjs → MazSpinner-C8zfJPRU.mjs} +1 -1
- package/components/chunks/{MazSpinner-BLh6PkZJ.mjs → MazSpinner-C_uLffb-.mjs} +1 -1
- package/components/chunks/{MazSpinner-C2mutMJX.mjs → MazSpinner-Cu7WoA4N.mjs} +1 -1
- package/components/chunks/MazSpinner-CyqPQ7SW.mjs +34 -0
- package/components/chunks/MazSpinner-DV634NYb.mjs +34 -0
- package/components/chunks/MazSpinner-DW_14RuN.mjs +34 -0
- package/components/chunks/{MazSpinner-SnOek826.mjs → MazSpinner-DwQiUPTZ.mjs} +1 -1
- package/components/chunks/MazSpinner-zV6qnXaD.mjs +34 -0
- package/components/chunks/{MazTable-BuFlCw1p.mjs → MazTable-B5BMpCK1.mjs} +1 -1
- package/components/chunks/{MazTableCell-C6oDOvNH.mjs → MazTableCell-7Ahz87mm.mjs} +1 -1
- package/components/chunks/{MazTableRow-BBS8sW7w.mjs → MazTableRow-B0JiP3mV.mjs} +1 -1
- package/components/chunks/{MazTableTitle-D7J-0k_j.mjs → MazTableTitle-BdajfMLo.mjs} +1 -1
- package/components/chunks/{MazTransitionExpand-BlcqxvGq.mjs → MazTransitionExpand-BO_9-l3g.mjs} +1 -1
- package/modules/assets/MazBtn.css +1 -1
- package/modules/chunks/{MazBtn-BjiQC2PC.mjs → MazBtn-CvuJewxV.mjs} +3 -3
- package/modules/chunks/{MazBtn-BnQrui8R.cjs → MazBtn-eZwyrxMU.cjs} +1 -1
- package/modules/chunks/{MazIcon-DwFVj44O.mjs → MazIcon-CeCRHfan.mjs} +1 -1
- package/modules/chunks/{MazIcon-D4oz63T8.cjs → MazIcon-u9VBpDx8.cjs} +1 -1
- package/modules/chunks/{MazSpinner-B18bQ49b.cjs → MazSpinner-BY5lnQ7u.cjs} +1 -1
- package/modules/chunks/{MazSpinner-7nqeVBxW.mjs → MazSpinner-DdDJ5vzJ.mjs} +1 -1
- package/modules/chunks/{index-D8S1X6Fy.mjs → index--62sMUK_.mjs} +4 -4
- package/modules/chunks/{index-IBifh-oY.cjs → index-Bq7zqUSE.cjs} +2 -2
- package/modules/index.cjs +1 -1
- package/modules/index.mjs +1 -1
- package/nuxt/index.json +1 -1
- package/package.json +1 -1
- package/components/chunks/MazBtn-DiYly5sp.mjs +0 -103
- package/components/chunks/MazBtn-Dlx6nLm2.mjs +0 -103
- package/components/chunks/MazBtn-MJYP-poo.mjs +0 -103
- package/components/chunks/MazBtn-tS9ACNLi.mjs +0 -103
- package/components/chunks/MazIcon-C7ZMosGw.mjs +0 -4
- package/components/chunks/MazPicker-g10_1sY_.mjs +0 -2493
- package/components/chunks/MazSpinner-C7TbmneX.mjs +0 -34
- package/components/chunks/MazSpinner-CcshuKK9.mjs +0 -34
- package/components/chunks/MazSpinner-D2J_jdkK.mjs +0 -34
- package/components/chunks/MazSpinner-DIzWfhcT.mjs +0 -34
- package/components/chunks/MazSpinner-DP019rLG.mjs +0 -34
- package/components/chunks/MazSpinner-DXCofnqs.mjs +0 -34
- package/components/chunks/MazSpinner-DmeOhZXm.mjs +0 -34
- package/components/chunks/MazSpinner-ZDRUpUqo.mjs +0 -34
- package/components/chunks/MazSpinner-qRqfN8k4.mjs +0 -34
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { openBlock as
|
|
2
|
-
import '../assets/MazInputPrice.css';const
|
|
1
|
+
import { openBlock as i, createElementBlock as y, createElementVNode as C, computed as s, useId as Q, defineComponent as L, defineAsyncComponent as z, ref as I, onMounted as O, useSlots as X, normalizeClass as w, normalizeStyle as Z, unref as m, toDisplayString as A, createCommentVNode as u, renderSlot as E, createBlock as p, resolveDynamicComponent as D, withDirectives as x, mergeProps as _, toHandlers as ee, vModelDynamic as te, withModifiers as oe, withCtx as P, createVNode as q, watch as re, withKeys as ne, nextTick as ae } from "vue";
|
|
2
|
+
import '../assets/MazInputPrice.css';const le = {
|
|
3
3
|
xmlns: "http://www.w3.org/2000/svg",
|
|
4
4
|
width: "1em",
|
|
5
5
|
height: "1em",
|
|
6
6
|
fill: "none",
|
|
7
7
|
viewBox: "0 0 24 24"
|
|
8
8
|
};
|
|
9
|
-
function
|
|
10
|
-
return
|
|
9
|
+
function ie(l, n) {
|
|
10
|
+
return i(), y("svg", le, n[0] || (n[0] = [
|
|
11
11
|
C(
|
|
12
12
|
"path",
|
|
13
13
|
{
|
|
@@ -23,16 +23,16 @@ function se(l, n) {
|
|
|
23
23
|
)
|
|
24
24
|
]));
|
|
25
25
|
}
|
|
26
|
-
const
|
|
26
|
+
const ue = { render: ie }, se = {
|
|
27
27
|
style: "currency",
|
|
28
28
|
minimumFractionDigits: 2,
|
|
29
29
|
round: !1
|
|
30
30
|
};
|
|
31
|
-
function
|
|
31
|
+
function de(l, n, t) {
|
|
32
32
|
let r = Number(l);
|
|
33
33
|
return t.round && (r = Math.floor(r), t.minimumFractionDigits = 0), new Intl.NumberFormat(n, t).format(r);
|
|
34
34
|
}
|
|
35
|
-
function
|
|
35
|
+
function ce(l, n, t) {
|
|
36
36
|
if (l === void 0)
|
|
37
37
|
throw new TypeError("[maz-ui](FilterCurrency) The `number` attribute is required.");
|
|
38
38
|
if (n === void 0)
|
|
@@ -42,25 +42,25 @@ function fe(l, n, t) {
|
|
|
42
42
|
if (t.currency === void 0)
|
|
43
43
|
throw new TypeError("[maz-ui](FilterCurrency) The `options.currency` attribute is required.");
|
|
44
44
|
}
|
|
45
|
-
function
|
|
45
|
+
function me(l, n, t) {
|
|
46
46
|
const r = {
|
|
47
|
-
...
|
|
47
|
+
...se,
|
|
48
48
|
...t
|
|
49
49
|
};
|
|
50
|
-
|
|
50
|
+
ce(l, n, r);
|
|
51
51
|
try {
|
|
52
|
-
return
|
|
52
|
+
return de(l, n, r);
|
|
53
53
|
} catch (d) {
|
|
54
54
|
throw new Error(`[maz-ui](FilterCurrency) ${d}`);
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
|
-
function
|
|
57
|
+
function fe({
|
|
58
58
|
componentName: l,
|
|
59
59
|
providedId: n
|
|
60
60
|
}) {
|
|
61
|
-
return s(() => n ?? `${l}-${
|
|
61
|
+
return s(() => n ?? `${l}-${Q().replace(/:/g, "")}`);
|
|
62
62
|
}
|
|
63
|
-
function
|
|
63
|
+
function pe(l, n) {
|
|
64
64
|
let t;
|
|
65
65
|
return function(...r) {
|
|
66
66
|
clearTimeout(t), t = setTimeout(() => {
|
|
@@ -68,13 +68,13 @@ function ye(l, n) {
|
|
|
68
68
|
}, n);
|
|
69
69
|
};
|
|
70
70
|
}
|
|
71
|
-
const
|
|
71
|
+
const ve = ["for"], ye = {
|
|
72
72
|
key: 0,
|
|
73
73
|
class: "m-input-wrapper-left"
|
|
74
|
-
},
|
|
74
|
+
}, be = ["id", "name", "placeholder", "aria-label", "type", "inputmode", "disabled", "readonly", "autocomplete", "required"], he = {
|
|
75
75
|
key: 1,
|
|
76
76
|
class: "m-input-wrapper-right"
|
|
77
|
-
},
|
|
77
|
+
}, ge = /* @__PURE__ */ L({
|
|
78
78
|
inheritAttrs: !1,
|
|
79
79
|
__name: "MazInput",
|
|
80
80
|
props: {
|
|
@@ -115,15 +115,15 @@ const be = ["for"], he = {
|
|
|
115
115
|
},
|
|
116
116
|
emits: ["update:model-value", "focus", "blur", "click", "change", "input"],
|
|
117
117
|
setup(l, { emit: n }) {
|
|
118
|
-
const t = l, r = n, d = z(() => import("./MazBtn-
|
|
118
|
+
const t = l, r = n, d = z(() => import("./MazBtn-DnpSuILi.mjs")), b = z(() => import("./MazIcon-Cq1v4J3r.mjs")), M = z(() => import("./eye-slash-BoO00xzs.mjs")), k = z(() => import("./eye-f8zAUc30.mjs")), B = z(() => import("./check-BmubdHc_.mjs")), f = I(!1), v = I(!1), h = I(), V = fe({
|
|
119
119
|
componentName: "MazInput",
|
|
120
120
|
providedId: t.id
|
|
121
121
|
});
|
|
122
122
|
O(() => {
|
|
123
123
|
var e;
|
|
124
|
-
t.autoFocus && ((e =
|
|
124
|
+
t.autoFocus && ((e = h.value) == null || e.focus());
|
|
125
125
|
});
|
|
126
|
-
const T = s(() => t.type === "password"), S = s(() =>
|
|
126
|
+
const T = s(() => t.type === "password"), S = s(() => f.value ? "text" : t.type), F = s(() => {
|
|
127
127
|
if (!t.noBorder) {
|
|
128
128
|
if (t.error)
|
|
129
129
|
return "maz-border-danger";
|
|
@@ -131,7 +131,7 @@ const be = ["for"], he = {
|
|
|
131
131
|
return "maz-border-success";
|
|
132
132
|
if (t.warning)
|
|
133
133
|
return "maz-border-warning";
|
|
134
|
-
if (
|
|
134
|
+
if (v.value || t.borderActive) {
|
|
135
135
|
if (t.color === "black")
|
|
136
136
|
return "maz-border-black";
|
|
137
137
|
if (t.color === "danger")
|
|
@@ -151,51 +151,47 @@ const be = ["for"], he = {
|
|
|
151
151
|
}
|
|
152
152
|
return "--default-border";
|
|
153
153
|
}
|
|
154
|
-
}), o =
|
|
155
|
-
const { required: e, placeholder: m } = t;
|
|
156
|
-
if (m)
|
|
157
|
-
return e ? `${m} *` : m;
|
|
158
|
-
}), a = s(() => N.value !== void 0 && N.value !== ""), H = ye(
|
|
154
|
+
}), o = X(), c = s(() => N.value !== void 0 && N.value !== ""), a = pe(
|
|
159
155
|
(e) => {
|
|
160
156
|
r("update:model-value", e);
|
|
161
157
|
},
|
|
162
158
|
typeof t.debounce == "number" ? t.debounce : t.debounceDelay ?? 500
|
|
163
159
|
);
|
|
164
|
-
function
|
|
160
|
+
function H(e) {
|
|
165
161
|
if (t.debounce)
|
|
166
|
-
return
|
|
162
|
+
return a(e);
|
|
167
163
|
r("update:model-value", e);
|
|
168
164
|
}
|
|
169
165
|
const N = s({
|
|
170
166
|
get: () => t.modelValue,
|
|
171
|
-
set: (e) =>
|
|
172
|
-
}),
|
|
173
|
-
function
|
|
167
|
+
set: (e) => H(e)
|
|
168
|
+
}), R = s(() => (!!t.label || !!t.hint) && (v.value || !!c.value || !!t.placeholder || ["date", "month", "week"].includes(t.type))), U = s(() => !!t.label || !!t.hint);
|
|
169
|
+
function j() {
|
|
174
170
|
return !!o["right-icon"] || T.value || !!o["valid-button"] || t.validButton || !!t.rightIcon;
|
|
175
171
|
}
|
|
176
|
-
function
|
|
172
|
+
function K() {
|
|
177
173
|
return !!o["left-icon"] || !!t.leftIcon;
|
|
178
174
|
}
|
|
175
|
+
function Y(e) {
|
|
176
|
+
r("focus", e), v.value = !0;
|
|
177
|
+
}
|
|
179
178
|
function G(e) {
|
|
180
|
-
r("
|
|
179
|
+
r("blur", e), v.value = !1;
|
|
181
180
|
}
|
|
182
181
|
function W(e) {
|
|
183
|
-
r("blur", e), b.value = !1;
|
|
184
|
-
}
|
|
185
|
-
function J(e) {
|
|
186
182
|
return r("change", e);
|
|
187
183
|
}
|
|
188
|
-
function
|
|
184
|
+
function J(e) {
|
|
189
185
|
return r("input", e);
|
|
190
186
|
}
|
|
191
|
-
return (e,
|
|
187
|
+
return (e, g) => (i(), y(
|
|
192
188
|
"div",
|
|
193
189
|
{
|
|
194
190
|
class: w(["m-input", [
|
|
195
191
|
{
|
|
196
|
-
"--is-focused":
|
|
197
|
-
"--should-up":
|
|
198
|
-
"--has-label":
|
|
192
|
+
"--is-focused": v.value || e.borderActive,
|
|
193
|
+
"--should-up": R.value,
|
|
194
|
+
"--has-label": U.value,
|
|
199
195
|
"--is-disabled": e.disabled,
|
|
200
196
|
"--is-readonly": e.readonly,
|
|
201
197
|
"--has-z-2": e.error || e.warning || e.success,
|
|
@@ -205,14 +201,14 @@ const be = ["for"], he = {
|
|
|
205
201
|
t.class,
|
|
206
202
|
`--${e.color}`
|
|
207
203
|
]]),
|
|
208
|
-
style:
|
|
204
|
+
style: Z(e.style)
|
|
209
205
|
},
|
|
210
206
|
[
|
|
211
|
-
e.topLabel ? (
|
|
207
|
+
e.topLabel ? (i(), y("label", {
|
|
212
208
|
key: 0,
|
|
213
|
-
for:
|
|
209
|
+
for: m(V),
|
|
214
210
|
class: "m-input-top-label"
|
|
215
|
-
}, A(e.topLabel), 9,
|
|
211
|
+
}, A(e.topLabel), 9, ve)) : u("v-if", !0),
|
|
216
212
|
C(
|
|
217
213
|
"div",
|
|
218
214
|
{
|
|
@@ -224,30 +220,30 @@ const be = ["for"], he = {
|
|
|
224
220
|
]])
|
|
225
221
|
},
|
|
226
222
|
[
|
|
227
|
-
|
|
223
|
+
K() ? (i(), y("div", ye, [
|
|
228
224
|
e.$slots["left-icon"] || e.leftIcon ? E(e.$slots, "left-icon", { key: 0 }, () => [
|
|
229
|
-
typeof e.leftIcon == "string" ? (
|
|
225
|
+
typeof e.leftIcon == "string" ? (i(), p(m(b), {
|
|
230
226
|
key: 0,
|
|
231
227
|
name: e.leftIcon,
|
|
232
228
|
class: "maz-text-xl maz-text-muted"
|
|
233
|
-
}, null, 8, ["name"])) : e.leftIcon ? (
|
|
229
|
+
}, null, 8, ["name"])) : e.leftIcon ? (i(), p(D(e.leftIcon), {
|
|
234
230
|
key: 1,
|
|
235
231
|
class: "maz-text-xl maz-text-muted"
|
|
236
|
-
})) :
|
|
237
|
-
], !0) :
|
|
238
|
-
])) :
|
|
232
|
+
})) : u("v-if", !0)
|
|
233
|
+
], !0) : u("v-if", !0)
|
|
234
|
+
])) : u("v-if", !0),
|
|
239
235
|
C(
|
|
240
236
|
"div",
|
|
241
237
|
{
|
|
242
238
|
class: w(["m-input-wrapper-input", [`--${e.size}`, { "--top-label": !!e.topLabel }]])
|
|
243
239
|
},
|
|
244
240
|
[
|
|
245
|
-
|
|
241
|
+
x(C("input", _({ id: m(V) }, e.$attrs, {
|
|
246
242
|
ref_key: "input",
|
|
247
|
-
ref:
|
|
248
|
-
"onUpdate:modelValue":
|
|
243
|
+
ref: h,
|
|
244
|
+
"onUpdate:modelValue": g[0] || (g[0] = ($) => N.value = $),
|
|
249
245
|
name: e.name,
|
|
250
|
-
placeholder:
|
|
246
|
+
placeholder: e.placeholder,
|
|
251
247
|
"aria-label": e.label || e.placeholder,
|
|
252
248
|
type: S.value,
|
|
253
249
|
inputmode: e.inputmode,
|
|
@@ -256,17 +252,17 @@ const be = ["for"], he = {
|
|
|
256
252
|
autocomplete: e.autocomplete,
|
|
257
253
|
required: e.required,
|
|
258
254
|
class: "m-input-input"
|
|
259
|
-
},
|
|
260
|
-
blur:
|
|
261
|
-
focus:
|
|
262
|
-
change:
|
|
263
|
-
input:
|
|
255
|
+
}, ee({
|
|
256
|
+
blur: G,
|
|
257
|
+
focus: Y,
|
|
258
|
+
change: W,
|
|
259
|
+
input: J
|
|
264
260
|
}, !0), {
|
|
265
|
-
onClick:
|
|
266
|
-
}), null, 16,
|
|
267
|
-
[
|
|
261
|
+
onClick: g[1] || (g[1] = ($) => e.$emit("click", $))
|
|
262
|
+
}), null, 16, be), [
|
|
263
|
+
[te, N.value]
|
|
268
264
|
]),
|
|
269
|
-
e.label || e.hint ? (
|
|
265
|
+
e.label || e.hint ? (i(), y(
|
|
270
266
|
"span",
|
|
271
267
|
{
|
|
272
268
|
key: 0,
|
|
@@ -278,53 +274,46 @@ const be = ["for"], he = {
|
|
|
278
274
|
}
|
|
279
275
|
]])
|
|
280
276
|
},
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
/* TEXT */
|
|
286
|
-
),
|
|
287
|
-
e.required ? (u(), v("sup", ze, "*")) : i("v-if", !0)
|
|
288
|
-
],
|
|
289
|
-
2
|
|
290
|
-
/* CLASS */
|
|
291
|
-
)) : i("v-if", !0)
|
|
277
|
+
A(e.hint || e.label),
|
|
278
|
+
3
|
|
279
|
+
/* TEXT, CLASS */
|
|
280
|
+
)) : u("v-if", !0)
|
|
292
281
|
],
|
|
293
282
|
2
|
|
294
283
|
/* CLASS */
|
|
295
284
|
),
|
|
296
|
-
|
|
285
|
+
j() ? (i(), y("div", he, [
|
|
297
286
|
e.$slots["right-icon"] || e.rightIcon ? E(e.$slots, "right-icon", { key: 0 }, () => [
|
|
298
|
-
typeof e.rightIcon == "string" ? (
|
|
287
|
+
typeof e.rightIcon == "string" ? (i(), p(m(b), {
|
|
299
288
|
key: 0,
|
|
300
289
|
name: e.rightIcon,
|
|
301
290
|
class: "maz-text-xl maz-text-muted"
|
|
302
|
-
}, null, 8, ["name"])) : e.rightIcon ? (
|
|
291
|
+
}, null, 8, ["name"])) : e.rightIcon ? (i(), p(D(e.rightIcon), {
|
|
303
292
|
key: 1,
|
|
304
293
|
class: "maz-text-xl maz-text-muted"
|
|
305
|
-
})) :
|
|
306
|
-
], !0) :
|
|
307
|
-
T.value ? (
|
|
294
|
+
})) : u("v-if", !0)
|
|
295
|
+
], !0) : u("v-if", !0),
|
|
296
|
+
T.value ? (i(), p(m(d), {
|
|
308
297
|
key: 1,
|
|
309
298
|
color: "transparent",
|
|
310
299
|
tabindex: "-1",
|
|
311
300
|
size: "mini",
|
|
312
|
-
onClick:
|
|
301
|
+
onClick: g[2] || (g[2] = oe(($) => f.value = !f.value, ["stop"]))
|
|
313
302
|
}, {
|
|
314
303
|
default: P(() => [
|
|
315
|
-
|
|
304
|
+
f.value ? (i(), p(m(M), {
|
|
316
305
|
key: 0,
|
|
317
306
|
class: "maz-text-xl maz-text-muted"
|
|
318
|
-
})) : (
|
|
307
|
+
})) : (i(), p(m(k), {
|
|
319
308
|
key: 1,
|
|
320
309
|
class: "maz-text-xl maz-text-muted"
|
|
321
310
|
}))
|
|
322
311
|
]),
|
|
323
312
|
_: 1
|
|
324
313
|
/* STABLE */
|
|
325
|
-
})) :
|
|
314
|
+
})) : u("v-if", !0),
|
|
326
315
|
e.$slots["valid-button"] || e.validButton ? E(e.$slots, "valid-button", { key: 2 }, () => [
|
|
327
|
-
q(
|
|
316
|
+
q(m(d), {
|
|
328
317
|
color: "transparent",
|
|
329
318
|
disabled: e.disabled,
|
|
330
319
|
tabindex: "-1",
|
|
@@ -334,18 +323,18 @@ const be = ["for"], he = {
|
|
|
334
323
|
type: "submit"
|
|
335
324
|
}, {
|
|
336
325
|
default: P(() => [
|
|
337
|
-
q(
|
|
326
|
+
q(m(B), { class: "maz-text-2xl maz-text-normal" })
|
|
338
327
|
]),
|
|
339
328
|
_: 1
|
|
340
329
|
/* STABLE */
|
|
341
330
|
}, 8, ["disabled", "loading"])
|
|
342
|
-
], !0) :
|
|
343
|
-
])) :
|
|
331
|
+
], !0) : u("v-if", !0)
|
|
332
|
+
])) : u("v-if", !0)
|
|
344
333
|
],
|
|
345
334
|
2
|
|
346
335
|
/* CLASS */
|
|
347
336
|
),
|
|
348
|
-
e.assistiveText ? (
|
|
337
|
+
e.assistiveText ? (i(), y(
|
|
349
338
|
"div",
|
|
350
339
|
{
|
|
351
340
|
key: 1,
|
|
@@ -361,18 +350,18 @@ const be = ["for"], he = {
|
|
|
361
350
|
A(e.assistiveText),
|
|
362
351
|
3
|
|
363
352
|
/* TEXT, CLASS */
|
|
364
|
-
)) :
|
|
353
|
+
)) : u("v-if", !0)
|
|
365
354
|
],
|
|
366
355
|
6
|
|
367
356
|
/* CLASS, STYLE */
|
|
368
357
|
));
|
|
369
358
|
}
|
|
370
|
-
}),
|
|
359
|
+
}), ze = (l, n) => {
|
|
371
360
|
const t = l.__vccOpts || l;
|
|
372
361
|
for (const [r, d] of n)
|
|
373
362
|
t[r] = d;
|
|
374
363
|
return t;
|
|
375
|
-
},
|
|
364
|
+
}, we = /* @__PURE__ */ ze(ge, [["__scopeId", "data-v-8def99c5"]]), ke = /* @__PURE__ */ L({
|
|
376
365
|
__name: "MazInputPrice",
|
|
377
366
|
props: {
|
|
378
367
|
modelValue: { default: void 0 },
|
|
@@ -390,46 +379,46 @@ const be = ["for"], he = {
|
|
|
390
379
|
},
|
|
391
380
|
emits: ["update:model-value", "input", "formatted", "blur", "focus"],
|
|
392
381
|
setup(l, { emit: n }) {
|
|
393
|
-
const t = l, r = n, d =
|
|
394
|
-
|
|
395
|
-
const
|
|
382
|
+
const t = l, r = n, d = I(f(t.modelValue));
|
|
383
|
+
re(() => t.modelValue, F);
|
|
384
|
+
const b = I(!1), M = s(() => {
|
|
396
385
|
var o;
|
|
397
386
|
return (o = t.modelValue) == null ? void 0 : o.toString();
|
|
398
|
-
}),
|
|
399
|
-
() => typeof
|
|
387
|
+
}), k = s(() => t.modelValue), B = s(
|
|
388
|
+
() => typeof k.value == "number" ? me(k.value, t.locale, { ...t.currencyOptions, currency: t.currency }) : void 0
|
|
400
389
|
);
|
|
401
|
-
function
|
|
390
|
+
function f(o) {
|
|
402
391
|
const c = typeof o == "string" && o.startsWith("-");
|
|
403
392
|
let a = typeof o == "string" ? Number.parseFloat(o.replace(",", ".").replaceAll(/[^\d.]/g, "")) : o;
|
|
404
393
|
return a = c && a ? -a : a, (typeof a != "number" || Number.isNaN(a)) && (a = void 0), a && a < t.min && (a = t.min), a && a > t.max && (a = t.max), a;
|
|
405
394
|
}
|
|
406
|
-
const
|
|
407
|
-
if (
|
|
395
|
+
const v = s(() => {
|
|
396
|
+
if (b.value)
|
|
408
397
|
return M.value;
|
|
409
398
|
if (typeof t.modelValue == "number")
|
|
410
399
|
return B.value;
|
|
411
400
|
});
|
|
412
|
-
async function
|
|
413
|
-
const c =
|
|
414
|
-
r("update:model-value", c), await
|
|
401
|
+
async function h(o) {
|
|
402
|
+
const c = f(o);
|
|
403
|
+
r("update:model-value", c), await ae(), r("formatted", B.value);
|
|
415
404
|
}
|
|
416
405
|
O(() => {
|
|
417
|
-
|
|
406
|
+
h(t.modelValue);
|
|
418
407
|
});
|
|
419
408
|
function V(o) {
|
|
420
|
-
|
|
409
|
+
b.value = !1, h(d.value), r("blur", o);
|
|
421
410
|
}
|
|
422
411
|
function T(o) {
|
|
423
|
-
|
|
412
|
+
b.value = !0, r("focus", o);
|
|
424
413
|
}
|
|
425
414
|
function S() {
|
|
426
415
|
r("input", d.value);
|
|
427
416
|
}
|
|
428
417
|
function F(o) {
|
|
429
|
-
d.value =
|
|
418
|
+
d.value = f(o);
|
|
430
419
|
}
|
|
431
|
-
return (o, c) => (
|
|
432
|
-
"model-value":
|
|
420
|
+
return (o, c) => (i(), p(we, {
|
|
421
|
+
"model-value": v.value,
|
|
433
422
|
class: "maz-input-price m-reset-css",
|
|
434
423
|
block: o.block,
|
|
435
424
|
error: o.error,
|
|
@@ -439,12 +428,12 @@ const be = ["for"], he = {
|
|
|
439
428
|
onFocus: T,
|
|
440
429
|
onBlur: V,
|
|
441
430
|
onInput: S,
|
|
442
|
-
onKeydown: c[0] || (c[0] =
|
|
431
|
+
onKeydown: c[0] || (c[0] = ne((a) => h(d.value), ["enter"])),
|
|
443
432
|
"onUpdate:modelValue": c[1] || (c[1] = (a) => F(a))
|
|
444
433
|
}, {
|
|
445
434
|
"left-icon": P(() => [
|
|
446
|
-
o.noIcon ?
|
|
447
|
-
q(
|
|
435
|
+
o.noIcon ? u("v-if", !0) : E(o.$slots, "left-icon", { key: 0 }, () => [
|
|
436
|
+
q(m(ue), { class: "maz-text-xl" })
|
|
448
437
|
])
|
|
449
438
|
]),
|
|
450
439
|
_: 3
|
|
@@ -453,6 +442,6 @@ const be = ["for"], he = {
|
|
|
453
442
|
}
|
|
454
443
|
});
|
|
455
444
|
export {
|
|
456
|
-
|
|
457
|
-
|
|
445
|
+
ze as _,
|
|
446
|
+
ke as a
|
|
458
447
|
};
|