maz-ui 3.47.2-beta.0 → 3.47.2-beta.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/MazAccordion.mjs +36 -37
- package/components/MazAnimatedCounter.mjs +14 -16
- 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/MazChart.mjs +23 -32
- package/components/MazChecklist.mjs +1 -1
- package/components/MazCircularProgressBar.mjs +66 -71
- package/components/MazDialog.mjs +1 -1
- package/components/MazDialogPromise.mjs +1 -1
- package/components/MazDrawer.mjs +1 -1
- package/components/MazDropdown.mjs +162 -185
- package/components/MazExpandAnimation.mjs +20 -21
- package/components/MazGallery.mjs +1 -1
- package/components/MazInput.mjs +1 -1
- package/components/MazInputCode.mjs +30 -31
- package/components/MazInputNumber.mjs +1 -1
- package/components/MazInputPrice.mjs +1 -1
- package/components/MazInputTags.mjs +1 -1
- package/components/MazLink.mjs +18 -30
- package/components/MazPagination.mjs +1 -1
- package/components/MazPhoneNumberInput.mjs +1 -1
- package/components/MazPicker.mjs +1 -1
- package/components/MazRadio.mjs +37 -42
- package/components/MazRadioButtons.mjs +61 -66
- package/components/MazSelect.mjs +1 -1
- package/components/MazSlider.mjs +107 -116
- package/components/MazStepper.mjs +1 -1
- package/components/MazSwitch.mjs +24 -28
- package/components/MazTable.d.ts +6 -6
- package/components/MazTable.mjs +1 -1
- package/components/MazTabsBar.mjs +1 -1
- package/components/MazTextarea.mjs +32 -34
- package/components/assets/MazLink.css +1 -1
- package/components/assets/MazTable.css +1 -1
- package/components/chunks/{MazBadge-CvIiiTdM.mjs → MazBadge-CqppWg2j.mjs} +1 -1
- package/components/chunks/{MazBottomSheet-DqK0EOsq.mjs → MazBottomSheet-CGRvZmGd.mjs} +28 -29
- package/{modules/chunks/MazBtn-BSnVxud6.mjs → components/chunks/MazBtn-2VKM1wZu.mjs} +37 -49
- package/components/chunks/{MazBtn-DVkwISlp.mjs → MazBtn-40lm8-AL.mjs} +37 -49
- package/components/chunks/{MazBtn-DzBXfedt.mjs → MazBtn-BB1FyYWv.mjs} +35 -44
- package/components/chunks/{MazBtn-BO3G90L3.mjs → MazBtn-BMYXMZuX.mjs} +37 -49
- package/components/chunks/{MazBtn-DJOUeES7.mjs → MazBtn-BijEMn4r.mjs} +37 -49
- package/components/chunks/MazBtn-BmrcK2af.mjs +106 -0
- package/components/chunks/MazBtn-C72_1uvu.mjs +106 -0
- package/components/chunks/MazBtn-CWloP6MI.mjs +111 -0
- package/components/chunks/MazBtn-CcyV4DCc.mjs +106 -0
- package/components/chunks/MazBtn-DENEMy-c.mjs +106 -0
- package/components/chunks/MazBtn-DfqRZvbB.mjs +106 -0
- package/components/chunks/MazBtn-UnZQuu6P.mjs +106 -0
- package/components/chunks/MazBtn-cDJlUVVY.mjs +106 -0
- package/components/chunks/MazBtn-hUslV7wO.mjs +106 -0
- package/components/chunks/{MazCard-FSXmHyhj.mjs → MazCard-BYB8y1_u.mjs} +18 -19
- package/components/chunks/{MazCarousel-BEl86YGW.mjs → MazCarousel-DccWVW8H.mjs} +20 -21
- package/components/chunks/{MazCheckbox-2G4VkxDz.mjs → MazCheckbox-B22OcHt8.mjs} +1 -1
- package/components/chunks/{MazCheckbox-Cq9gpTEw.mjs → MazCheckbox-DMogZVHl.mjs} +1 -1
- package/components/chunks/{MazCheckbox-BmnqBHaY.mjs → MazCheckbox-Db6sPUbV.mjs} +1 -1
- package/components/chunks/{MazChecklist-CY1Cv70T.mjs → MazChecklist-C95Y4Hb-.mjs} +112 -118
- package/components/chunks/{MazDialog-CPgFpAlq.mjs → MazDialog-khofH-7I.mjs} +66 -81
- package/components/chunks/MazDialogPromise-ZRA2ZrO4.mjs +488 -0
- package/components/chunks/{MazExpandAnimation-Bkw_wFTi.mjs → MazExpandAnimation-MDimlZGj.mjs} +7 -8
- package/components/chunks/{MazGallery-BknvUeo1.mjs → MazGallery-CXQiXWFr.mjs} +32 -33
- package/components/chunks/{MazGallery-CZOokGAt.mjs → MazGallery-VTZUhBKC.mjs} +33 -34
- package/components/chunks/{MazIcon-z-jTiuyI.mjs → MazIcon-BF5TFzse.mjs} +1 -1
- package/components/chunks/{MazInput-oOA7gdLO.mjs → MazInput-DC3S-CVu.mjs} +44 -53
- package/components/chunks/{MazInput-BQoQSRyL.mjs → MazInput-DzWkS-g8.mjs} +40 -49
- package/components/chunks/{MazInput-CJQB68c-.mjs → MazInput-NE6H-10w.mjs} +42 -51
- package/components/chunks/{MazInputNumber-B4mQJcVB.mjs → MazInputNumber-DRXQXHRv.mjs} +168 -189
- package/components/chunks/{MazInputPrice-BrxE5WVf.mjs → MazInputPrice-DoTnDDIN.mjs} +49 -58
- package/components/chunks/{MazInputTags-BVCej_gW.mjs → MazInputTags-Dj3sW-e5.mjs} +181 -202
- package/components/chunks/{MazLink-Dl9ePCGm.mjs → MazLink-C_3Wya94.mjs} +19 -31
- package/components/chunks/{MazLoadingBar-Dwf55oHy.mjs → MazLoadingBar-DdjHRC7g.mjs} +1 -1
- package/components/chunks/MazPagination-BkT4_LLW.mjs +330 -0
- package/components/chunks/{MazPhoneNumberInput-Cd25AzXc.mjs → MazPhoneNumberInput-BbssOUzo.mjs} +500 -544
- package/components/chunks/{MazPicker-C78yxilJ.mjs → MazPicker-DwWiIYAR.mjs} +243 -264
- package/components/chunks/{MazPickerMonthSwitcher-CyHYx8TT.mjs → MazPickerMonthSwitcher-CmFFQoPA.mjs} +1 -1
- package/components/chunks/{MazPickerShortcuts-Bsi8cnox.mjs → MazPickerShortcuts-DaELz7aq.mjs} +1 -1
- package/components/chunks/{MazPickerYearSwitcher-DLUSMAtz.mjs → MazPickerYearSwitcher-m1_KXnpA.mjs} +1 -1
- package/components/chunks/{MazSelect-CQDoUpgp.mjs → MazSelect-BJ07NVXQ.mjs} +149 -170
- package/components/chunks/{MazSelect-uCJPMXF-.mjs → MazSelect-CDV9Fx6m.mjs} +124 -136
- package/components/chunks/{MazSpinner-Bvb-lKER.mjs → MazSpinner-Bb3f2t6w.mjs} +1 -1
- package/components/chunks/{MazSpinner-Cqp-BMvL.mjs → MazSpinner-BcB0szZB.mjs} +1 -1
- package/components/chunks/{MazSpinner-BT_717pD.mjs → MazSpinner-BpkPcfCt.mjs} +1 -1
- package/components/chunks/{MazSpinner-CAbYLlEZ.mjs → MazSpinner-BsYJDmi9.mjs} +1 -1
- package/components/chunks/{MazSpinner-B9OwpEP_.mjs → MazSpinner-BymqEMBk.mjs} +1 -1
- package/components/chunks/MazSpinner-C-64WJje.mjs +34 -0
- package/components/chunks/MazSpinner-CEFbkZkM.mjs +34 -0
- package/components/chunks/{MazSpinner-EFo8dM46.mjs → MazSpinner-CfiIXW8y.mjs} +1 -1
- package/components/chunks/MazSpinner-CykRbNHD.mjs +34 -0
- package/components/chunks/{MazSpinner-C-z3-68w.mjs → MazSpinner-D3-pqOh3.mjs} +1 -1
- package/components/chunks/MazSpinner-DS58mtzm.mjs +34 -0
- package/components/chunks/{MazSpinner-2D0ZmAQz.mjs → MazSpinner-DmiLBQgR.mjs} +1 -1
- package/components/chunks/{MazSpinner-C1Ip-Dwh.mjs → MazSpinner-Dmkr_r9u.mjs} +1 -1
- package/components/chunks/MazSpinner-DoRGA1RI.mjs +34 -0
- package/components/chunks/MazSpinner-eC03bFP5.mjs +34 -0
- package/components/chunks/{MazSpinner-Cb3_S0zT.mjs → MazSpinner-edxn0ncQ.mjs} +1 -1
- package/components/chunks/MazSpinner-f2Mc2eRO.mjs +34 -0
- package/components/chunks/MazSpinner-n4Dp5ZsH.mjs +34 -0
- package/components/chunks/MazStepper-BREfkpUb.mjs +213 -0
- package/components/chunks/{MazTable-Cuz5QI08.mjs → MazTable-BJDPdIJB.mjs} +183 -227
- package/components/chunks/{MazTableCell-D_OTOJiy.mjs → MazTableCell-DILuUCTe.mjs} +1 -1
- package/components/chunks/{MazTableRow-BTcVAyOy.mjs → MazTableRow-D6H6-c8J.mjs} +1 -1
- package/components/chunks/{MazTableTitle-BDA9G6Zw.mjs → MazTableTitle-Ch-nyY1E.mjs} +1 -1
- package/components/chunks/MazTabsBar-CM-w7V97.mjs +193 -0
- package/components/chunks/{MazTransitionExpand-C-FHhOGB.mjs → MazTransitionExpand-PmUDa51_.mjs} +1 -1
- package/modules/chunks/MazBtn-B_Xlvgbg.cjs +1 -0
- package/modules/chunks/MazBtn-Dsr06Zgg.mjs +106 -0
- package/modules/chunks/{MazIcon-dhyR9Q8a.cjs → MazIcon-CkuzyufF.cjs} +1 -1
- package/modules/chunks/{MazIcon-DllGg8tw.mjs → MazIcon-DEgoQbMj.mjs} +1 -1
- package/modules/chunks/{MazSpinner-bdGjxsu6.mjs → MazSpinner-BurN-1pb.mjs} +1 -1
- package/modules/chunks/{MazSpinner-CiIyZ8gs.cjs → MazSpinner-jP4QsCNE.cjs} +1 -1
- package/modules/chunks/index-CUNN0eIB.cjs +124 -0
- package/modules/chunks/{index-x2F1l5sr.mjs → index-CxFUggmu.mjs} +257 -292
- package/modules/index.cjs +1 -1
- package/modules/index.mjs +1 -1
- package/nuxt/index.json +1 -1
- package/package.json +1 -1
- package/types/components/MazTable.vue.d.ts +6 -6
- package/types/modules/composables/useFormValidator/types.d.ts +5 -1
- package/types/modules/composables/useFormValidator/useFormField.d.ts +3 -3
- package/types/modules/composables/useFormValidator/useFormValidator.d.ts +2 -2
- package/types/modules/composables/useFormValidator/utils.d.ts +12 -12
- package/components/chunks/MazBtn-BRUaoP8j.mjs +0 -126
- package/components/chunks/MazBtn-BhnOApJu.mjs +0 -118
- package/components/chunks/MazBtn-C28vKP_v.mjs +0 -118
- package/components/chunks/MazBtn-C87UEsVs.mjs +0 -118
- package/components/chunks/MazBtn-C_l3xuAh.mjs +0 -118
- package/components/chunks/MazBtn-CweCwE_4.mjs +0 -118
- package/components/chunks/MazBtn-D7IKoL2c.mjs +0 -118
- package/components/chunks/MazBtn-DadFupkY.mjs +0 -118
- package/components/chunks/MazBtn-GGcGrIH4.mjs +0 -118
- package/components/chunks/MazBtn-Mu18egu5.mjs +0 -118
- package/components/chunks/MazDialogPromise-BCCdkrea.mjs +0 -522
- package/components/chunks/MazPagination-CHTMRRqE.mjs +0 -362
- package/components/chunks/MazSpinner-C23CZ_Za.mjs +0 -34
- package/components/chunks/MazSpinner-CViChjTw.mjs +0 -34
- package/components/chunks/MazSpinner-CZMBhCOJ.mjs +0 -34
- package/components/chunks/MazSpinner-D4C84xZe.mjs +0 -34
- package/components/chunks/MazSpinner-Dyf9yb51.mjs +0 -34
- package/components/chunks/MazSpinner-QHjOczon.mjs +0 -34
- package/components/chunks/MazSpinner-u8WQTgUR.mjs +0 -34
- package/components/chunks/MazSpinner-w-S5uCxg.mjs +0 -34
- package/components/chunks/MazStepper-DRWtYHZR.mjs +0 -232
- package/components/chunks/MazTabsBar-JkRzMDM6.mjs +0 -203
- package/modules/chunks/MazBtn-Bf9Cq5M7.cjs +0 -9
- package/modules/chunks/index-BPqjUr5e.cjs +0 -149
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { useId as Q, computed as r, defineComponent as W, defineAsyncComponent as f, ref as z, onMounted as X, useSlots as Y, openBlock as
|
|
1
|
+
import { useId as Q, computed as r, defineComponent as W, defineAsyncComponent as f, ref as z, onMounted as X, useSlots as Y, openBlock as o, createElementBlock as p, normalizeClass as g, normalizeStyle as Z, createElementVNode as k, renderSlot as I, createBlock as d, unref as s, resolveDynamicComponent as C, createCommentVNode as l, withDirectives as x, mergeProps as _, toHandlers as ee, vModelDynamic as te, createTextVNode as oe, toDisplayString as ae, withModifiers as ne, withCtx as V, createVNode as S } from "vue";
|
|
2
2
|
import '../assets/MazInput.css';function le({
|
|
3
3
|
componentName: i,
|
|
4
4
|
providedId: u
|
|
@@ -58,7 +58,7 @@ const ie = {
|
|
|
58
58
|
},
|
|
59
59
|
emits: ["update:model-value", "focus", "blur", "click", "change", "input"],
|
|
60
60
|
setup(i, { emit: u }) {
|
|
61
|
-
const t = i, a = u, m = f(() => import("./MazBtn-
|
|
61
|
+
const t = i, a = u, m = f(() => import("./MazBtn-hUslV7wO.mjs")), B = f(() => import("./MazIcon-BbvBov5G.mjs")), M = f(() => import("./eye-slash-BoO00xzs.mjs")), q = f(() => import("./eye-f8zAUc30.mjs")), D = f(() => import("./check-BmubdHc_.mjs")), v = z(!1), c = z(!1), w = z(), E = le({
|
|
62
62
|
componentName: "MazInput",
|
|
63
63
|
providedId: t.id
|
|
64
64
|
});
|
|
@@ -66,7 +66,7 @@ const ie = {
|
|
|
66
66
|
var e;
|
|
67
67
|
t.autoFocus && ((e = w.value) == null || e.focus());
|
|
68
68
|
});
|
|
69
|
-
const $ = r(() => t.type === "password"),
|
|
69
|
+
const $ = r(() => t.type === "password"), N = r(() => v.value ? "text" : t.type), P = r(() => {
|
|
70
70
|
if (!t.noBorder) {
|
|
71
71
|
if (t.error)
|
|
72
72
|
return "maz-border-danger";
|
|
@@ -94,11 +94,11 @@ const ie = {
|
|
|
94
94
|
}
|
|
95
95
|
return "--default-border";
|
|
96
96
|
}
|
|
97
|
-
}), h = Y(),
|
|
98
|
-
const { required: e, placeholder:
|
|
99
|
-
if (
|
|
100
|
-
return e ? `${
|
|
101
|
-
}),
|
|
97
|
+
}), h = Y(), A = r(() => {
|
|
98
|
+
const { required: e, placeholder: n } = t;
|
|
99
|
+
if (n)
|
|
100
|
+
return e ? `${n} *` : n;
|
|
101
|
+
}), F = r(() => y.value !== void 0 && y.value !== ""), T = re(
|
|
102
102
|
(e) => {
|
|
103
103
|
a("update:model-value", e);
|
|
104
104
|
},
|
|
@@ -106,13 +106,13 @@ const ie = {
|
|
|
106
106
|
);
|
|
107
107
|
function L(e) {
|
|
108
108
|
if (t.debounce)
|
|
109
|
-
return
|
|
109
|
+
return T(e);
|
|
110
110
|
a("update:model-value", e);
|
|
111
111
|
}
|
|
112
112
|
const y = r({
|
|
113
113
|
get: () => t.modelValue,
|
|
114
114
|
set: (e) => L(e)
|
|
115
|
-
}), O = r(() => (!!t.label || !!t.hint) && (c.value || !!
|
|
115
|
+
}), O = r(() => (!!t.label || !!t.hint) && (c.value || !!F.value || !!t.placeholder || ["date", "month", "week"].includes(t.type))), R = r(() => !!t.label || !!t.hint);
|
|
116
116
|
function U() {
|
|
117
117
|
return !!h["right-icon"] || $.value || !!h["valid-button"] || t.validButton || !!t.rightIcon;
|
|
118
118
|
}
|
|
@@ -131,7 +131,7 @@ const ie = {
|
|
|
131
131
|
function K(e) {
|
|
132
132
|
return a("input", e);
|
|
133
133
|
}
|
|
134
|
-
return (e,
|
|
134
|
+
return (e, n) => (o(), p(
|
|
135
135
|
"div",
|
|
136
136
|
{
|
|
137
137
|
class: g(["m-input", [
|
|
@@ -157,37 +157,34 @@ const ie = {
|
|
|
157
157
|
{
|
|
158
158
|
class: g(["m-input-wrapper", [
|
|
159
159
|
e.inputClasses,
|
|
160
|
-
|
|
160
|
+
P.value,
|
|
161
161
|
e.roundedSize ? `--rounded-${e.roundedSize}` : { "maz-rounded": !e.noRadius }
|
|
162
162
|
]])
|
|
163
163
|
},
|
|
164
164
|
[
|
|
165
|
-
j() ? (
|
|
166
|
-
o(`
|
|
167
|
-
@slot left-icon - The icon to display on the left of the input
|
|
168
|
-
`),
|
|
165
|
+
j() ? (o(), p("div", ie, [
|
|
169
166
|
e.$slots["left-icon"] || e.leftIcon ? I(e.$slots, "left-icon", { key: 0 }, () => [
|
|
170
|
-
typeof e.leftIcon == "string" ? (
|
|
167
|
+
typeof e.leftIcon == "string" ? (o(), d(s(B), {
|
|
171
168
|
key: 0,
|
|
172
169
|
name: e.leftIcon,
|
|
173
170
|
class: "maz-text-xl maz-text-muted"
|
|
174
|
-
}, null, 8, ["name"])) : e.leftIcon ? (
|
|
171
|
+
}, null, 8, ["name"])) : e.leftIcon ? (o(), d(C(e.leftIcon), {
|
|
175
172
|
key: 1,
|
|
176
173
|
class: "maz-text-xl maz-text-muted"
|
|
177
|
-
})) :
|
|
178
|
-
], !0) :
|
|
179
|
-
])) :
|
|
174
|
+
})) : l("v-if", !0)
|
|
175
|
+
], !0) : l("v-if", !0)
|
|
176
|
+
])) : l("v-if", !0),
|
|
180
177
|
k("div", se, [
|
|
181
178
|
x(k("input", _({
|
|
182
|
-
id: s(
|
|
179
|
+
id: s(E),
|
|
183
180
|
ref_key: "input",
|
|
184
181
|
ref: w,
|
|
185
|
-
"onUpdate:modelValue":
|
|
186
|
-
type:
|
|
182
|
+
"onUpdate:modelValue": n[0] || (n[0] = (b) => y.value = b),
|
|
183
|
+
type: N.value,
|
|
187
184
|
name: e.name
|
|
188
185
|
}, e.$attrs, {
|
|
189
186
|
inputmode: e.inputmode,
|
|
190
|
-
placeholder:
|
|
187
|
+
placeholder: A.value,
|
|
191
188
|
"aria-label": e.label || e.placeholder,
|
|
192
189
|
disabled: e.disabled,
|
|
193
190
|
readonly: e.readonly,
|
|
@@ -199,11 +196,11 @@ const ie = {
|
|
|
199
196
|
change: J,
|
|
200
197
|
input: K
|
|
201
198
|
}, !0), {
|
|
202
|
-
onClick:
|
|
199
|
+
onClick: n[1] || (n[1] = (b) => e.$emit("click", b))
|
|
203
200
|
}), null, 16, ue), [
|
|
204
201
|
[te, y.value]
|
|
205
202
|
]),
|
|
206
|
-
e.label || e.hint ? (
|
|
203
|
+
e.label || e.hint ? (o(), p(
|
|
207
204
|
"span",
|
|
208
205
|
{
|
|
209
206
|
key: 0,
|
|
@@ -217,52 +214,46 @@ const ie = {
|
|
|
217
214
|
},
|
|
218
215
|
[
|
|
219
216
|
oe(
|
|
220
|
-
|
|
217
|
+
ae(e.hint || e.label) + " ",
|
|
221
218
|
1
|
|
222
219
|
/* TEXT */
|
|
223
220
|
),
|
|
224
|
-
e.required ? (
|
|
221
|
+
e.required ? (o(), p("sup", de, "*")) : l("v-if", !0)
|
|
225
222
|
],
|
|
226
223
|
2
|
|
227
224
|
/* CLASS */
|
|
228
|
-
)) :
|
|
225
|
+
)) : l("v-if", !0)
|
|
229
226
|
]),
|
|
230
|
-
U() ? (
|
|
231
|
-
o(`
|
|
232
|
-
@slot right-icon - The icon to display on the right of the input
|
|
233
|
-
`),
|
|
227
|
+
U() ? (o(), p("div", ce, [
|
|
234
228
|
e.$slots["right-icon"] || e.rightIcon ? I(e.$slots, "right-icon", { key: 0 }, () => [
|
|
235
|
-
typeof e.rightIcon == "string" ? (
|
|
229
|
+
typeof e.rightIcon == "string" ? (o(), d(s(B), {
|
|
236
230
|
key: 0,
|
|
237
231
|
name: e.rightIcon,
|
|
238
232
|
class: "maz-text-xl maz-text-muted"
|
|
239
|
-
}, null, 8, ["name"])) : e.rightIcon ? (
|
|
233
|
+
}, null, 8, ["name"])) : e.rightIcon ? (o(), d(C(e.rightIcon), {
|
|
240
234
|
key: 1,
|
|
241
235
|
class: "maz-text-xl maz-text-muted"
|
|
242
|
-
})) :
|
|
243
|
-
], !0) :
|
|
244
|
-
$.value ? (
|
|
236
|
+
})) : l("v-if", !0)
|
|
237
|
+
], !0) : l("v-if", !0),
|
|
238
|
+
$.value ? (o(), d(s(m), {
|
|
245
239
|
key: 1,
|
|
246
240
|
color: "transparent",
|
|
247
241
|
tabindex: "-1",
|
|
248
242
|
size: "mini",
|
|
249
|
-
onClick:
|
|
243
|
+
onClick: n[2] || (n[2] = ne((b) => v.value = !v.value, ["stop"]))
|
|
250
244
|
}, {
|
|
251
245
|
default: V(() => [
|
|
252
|
-
v.value ? (
|
|
246
|
+
v.value ? (o(), d(s(M), {
|
|
253
247
|
key: 0,
|
|
254
248
|
class: "maz-text-xl maz-text-muted"
|
|
255
|
-
})) : (
|
|
249
|
+
})) : (o(), d(s(q), {
|
|
256
250
|
key: 1,
|
|
257
251
|
class: "maz-text-xl maz-text-muted"
|
|
258
252
|
}))
|
|
259
253
|
]),
|
|
260
254
|
_: 1
|
|
261
255
|
/* STABLE */
|
|
262
|
-
})) :
|
|
263
|
-
o(`
|
|
264
|
-
@slot valid-button - Replace the valid button by your own
|
|
265
|
-
`),
|
|
256
|
+
})) : l("v-if", !0),
|
|
266
257
|
e.$slots["valid-button"] || e.validButton ? I(e.$slots, "valid-button", { key: 2 }, () => [
|
|
267
258
|
S(s(m), {
|
|
268
259
|
color: "transparent",
|
|
@@ -274,13 +265,13 @@ const ie = {
|
|
|
274
265
|
type: "submit"
|
|
275
266
|
}, {
|
|
276
267
|
default: V(() => [
|
|
277
|
-
S(s(
|
|
268
|
+
S(s(D), { class: "maz-text-2xl maz-text-normal" })
|
|
278
269
|
]),
|
|
279
270
|
_: 1
|
|
280
271
|
/* STABLE */
|
|
281
272
|
}, 8, ["disabled", "loading"])
|
|
282
|
-
], !0) :
|
|
283
|
-
])) :
|
|
273
|
+
], !0) : l("v-if", !0)
|
|
274
|
+
])) : l("v-if", !0)
|
|
284
275
|
],
|
|
285
276
|
2
|
|
286
277
|
/* CLASS */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { defineComponent as Q, defineAsyncComponent as d, ref as h, onMounted as W, computed as r, useSlots as X, openBlock as
|
|
2
|
-
import { u as ne, _ as le } from "./MazChecklist-
|
|
1
|
+
import { defineComponent as Q, defineAsyncComponent as d, ref as h, onMounted as W, computed as r, useSlots as X, openBlock as o, createElementBlock as f, normalizeClass as z, normalizeStyle as Y, createElementVNode as g, renderSlot as k, createBlock as u, unref as i, resolveDynamicComponent as C, createCommentVNode as n, withDirectives as Z, mergeProps as x, toHandlers as _, vModelDynamic as ee, createTextVNode as te, toDisplayString as oe, withModifiers as ae, withCtx as V, createVNode as S } from "vue";
|
|
2
|
+
import { u as ne, _ as le } from "./MazChecklist-C95Y4Hb-.mjs";
|
|
3
3
|
import '../assets/MazInput.css';function re(v, y) {
|
|
4
4
|
let t;
|
|
5
5
|
return function(...l) {
|
|
@@ -52,7 +52,7 @@ const ie = {
|
|
|
52
52
|
},
|
|
53
53
|
emits: ["update:model-value", "focus", "blur", "click", "change", "input"],
|
|
54
54
|
setup(v, { emit: y }) {
|
|
55
|
-
const t = v, l = y, I = d(() => import("./MazBtn-
|
|
55
|
+
const t = v, l = y, I = d(() => import("./MazBtn-DfqRZvbB.mjs")), B = d(() => import("./MazIcon-BbvBov5G.mjs")), M = d(() => import("./eye-slash-BoO00xzs.mjs")), q = d(() => import("./eye-f8zAUc30.mjs")), D = d(() => import("./MazChecklist-C95Y4Hb-.mjs").then((e) => e.c)), c = h(!1), s = h(!1), w = h(), E = ne({
|
|
56
56
|
componentName: "MazInput",
|
|
57
57
|
providedId: t.id
|
|
58
58
|
});
|
|
@@ -60,7 +60,7 @@ const ie = {
|
|
|
60
60
|
var e;
|
|
61
61
|
t.autoFocus && ((e = w.value) == null || e.focus());
|
|
62
62
|
});
|
|
63
|
-
const $ = r(() => t.type === "password"),
|
|
63
|
+
const $ = r(() => t.type === "password"), N = r(() => c.value ? "text" : t.type), P = r(() => {
|
|
64
64
|
if (!t.noBorder) {
|
|
65
65
|
if (t.error)
|
|
66
66
|
return "maz-border-danger";
|
|
@@ -88,11 +88,11 @@ const ie = {
|
|
|
88
88
|
}
|
|
89
89
|
return "--default-border";
|
|
90
90
|
}
|
|
91
|
-
}), b = X(),
|
|
92
|
-
const { required: e, placeholder:
|
|
93
|
-
if (
|
|
94
|
-
return e ? `${
|
|
95
|
-
}),
|
|
91
|
+
}), b = X(), A = r(() => {
|
|
92
|
+
const { required: e, placeholder: a } = t;
|
|
93
|
+
if (a)
|
|
94
|
+
return e ? `${a} *` : a;
|
|
95
|
+
}), F = r(() => p.value !== void 0 && p.value !== ""), T = re(
|
|
96
96
|
(e) => {
|
|
97
97
|
l("update:model-value", e);
|
|
98
98
|
},
|
|
@@ -100,13 +100,13 @@ const ie = {
|
|
|
100
100
|
);
|
|
101
101
|
function L(e) {
|
|
102
102
|
if (t.debounce)
|
|
103
|
-
return
|
|
103
|
+
return T(e);
|
|
104
104
|
l("update:model-value", e);
|
|
105
105
|
}
|
|
106
106
|
const p = r({
|
|
107
107
|
get: () => t.modelValue,
|
|
108
108
|
set: (e) => L(e)
|
|
109
|
-
}),
|
|
109
|
+
}), O = r(() => (!!t.label || !!t.hint) && (s.value || !!F.value || !!t.placeholder || ["date", "month", "week"].includes(t.type))), R = r(() => !!t.label || !!t.hint);
|
|
110
110
|
function U() {
|
|
111
111
|
return !!b["right-icon"] || $.value || !!b["valid-button"] || t.validButton || !!t.rightIcon;
|
|
112
112
|
}
|
|
@@ -125,14 +125,14 @@ const ie = {
|
|
|
125
125
|
function K(e) {
|
|
126
126
|
return l("input", e);
|
|
127
127
|
}
|
|
128
|
-
return (e,
|
|
128
|
+
return (e, a) => (o(), f(
|
|
129
129
|
"div",
|
|
130
130
|
{
|
|
131
131
|
class: z(["m-input", [
|
|
132
132
|
{
|
|
133
133
|
"--is-focused": s.value || e.borderActive,
|
|
134
|
-
"--should-up":
|
|
135
|
-
"--has-label":
|
|
134
|
+
"--should-up": O.value,
|
|
135
|
+
"--has-label": R.value,
|
|
136
136
|
"--is-disabled": e.disabled,
|
|
137
137
|
"--is-readonly": e.readonly,
|
|
138
138
|
"--has-z-2": e.error || e.warning || e.success,
|
|
@@ -151,37 +151,34 @@ const ie = {
|
|
|
151
151
|
{
|
|
152
152
|
class: z(["m-input-wrapper", [
|
|
153
153
|
e.inputClasses,
|
|
154
|
-
|
|
154
|
+
P.value,
|
|
155
155
|
e.roundedSize ? `--rounded-${e.roundedSize}` : { "maz-rounded": !e.noRadius }
|
|
156
156
|
]])
|
|
157
157
|
},
|
|
158
158
|
[
|
|
159
|
-
j() ? (
|
|
160
|
-
o(`
|
|
161
|
-
@slot left-icon - The icon to display on the left of the input
|
|
162
|
-
`),
|
|
159
|
+
j() ? (o(), f("div", ie, [
|
|
163
160
|
e.$slots["left-icon"] || e.leftIcon ? k(e.$slots, "left-icon", { key: 0 }, () => [
|
|
164
|
-
typeof e.leftIcon == "string" ? (
|
|
161
|
+
typeof e.leftIcon == "string" ? (o(), u(i(B), {
|
|
165
162
|
key: 0,
|
|
166
163
|
name: e.leftIcon,
|
|
167
164
|
class: "maz-text-xl maz-text-muted"
|
|
168
|
-
}, null, 8, ["name"])) : e.leftIcon ? (
|
|
165
|
+
}, null, 8, ["name"])) : e.leftIcon ? (o(), u(C(e.leftIcon), {
|
|
169
166
|
key: 1,
|
|
170
167
|
class: "maz-text-xl maz-text-muted"
|
|
171
|
-
})) :
|
|
172
|
-
], !0) :
|
|
173
|
-
])) :
|
|
168
|
+
})) : n("v-if", !0)
|
|
169
|
+
], !0) : n("v-if", !0)
|
|
170
|
+
])) : n("v-if", !0),
|
|
174
171
|
g("div", ue, [
|
|
175
172
|
Z(g("input", x({
|
|
176
|
-
id: i(
|
|
173
|
+
id: i(E),
|
|
177
174
|
ref_key: "input",
|
|
178
175
|
ref: w,
|
|
179
|
-
"onUpdate:modelValue":
|
|
180
|
-
type:
|
|
176
|
+
"onUpdate:modelValue": a[0] || (a[0] = (m) => p.value = m),
|
|
177
|
+
type: N.value,
|
|
181
178
|
name: e.name
|
|
182
179
|
}, e.$attrs, {
|
|
183
180
|
inputmode: e.inputmode,
|
|
184
|
-
placeholder:
|
|
181
|
+
placeholder: A.value,
|
|
185
182
|
"aria-label": e.label || e.placeholder,
|
|
186
183
|
disabled: e.disabled,
|
|
187
184
|
readonly: e.readonly,
|
|
@@ -193,11 +190,11 @@ const ie = {
|
|
|
193
190
|
change: J,
|
|
194
191
|
input: K
|
|
195
192
|
}, !0), {
|
|
196
|
-
onClick:
|
|
193
|
+
onClick: a[1] || (a[1] = (m) => e.$emit("click", m))
|
|
197
194
|
}), null, 16, se), [
|
|
198
195
|
[ee, p.value]
|
|
199
196
|
]),
|
|
200
|
-
e.label || e.hint ? (
|
|
197
|
+
e.label || e.hint ? (o(), f(
|
|
201
198
|
"span",
|
|
202
199
|
{
|
|
203
200
|
key: 0,
|
|
@@ -215,48 +212,42 @@ const ie = {
|
|
|
215
212
|
1
|
|
216
213
|
/* TEXT */
|
|
217
214
|
),
|
|
218
|
-
e.required ? (
|
|
215
|
+
e.required ? (o(), f("sup", de, "*")) : n("v-if", !0)
|
|
219
216
|
],
|
|
220
217
|
2
|
|
221
218
|
/* CLASS */
|
|
222
|
-
)) :
|
|
219
|
+
)) : n("v-if", !0)
|
|
223
220
|
]),
|
|
224
|
-
U() ? (
|
|
225
|
-
o(`
|
|
226
|
-
@slot right-icon - The icon to display on the right of the input
|
|
227
|
-
`),
|
|
221
|
+
U() ? (o(), f("div", fe, [
|
|
228
222
|
e.$slots["right-icon"] || e.rightIcon ? k(e.$slots, "right-icon", { key: 0 }, () => [
|
|
229
|
-
typeof e.rightIcon == "string" ? (
|
|
223
|
+
typeof e.rightIcon == "string" ? (o(), u(i(B), {
|
|
230
224
|
key: 0,
|
|
231
225
|
name: e.rightIcon,
|
|
232
226
|
class: "maz-text-xl maz-text-muted"
|
|
233
|
-
}, null, 8, ["name"])) : e.rightIcon ? (
|
|
227
|
+
}, null, 8, ["name"])) : e.rightIcon ? (o(), u(C(e.rightIcon), {
|
|
234
228
|
key: 1,
|
|
235
229
|
class: "maz-text-xl maz-text-muted"
|
|
236
|
-
})) :
|
|
237
|
-
], !0) :
|
|
238
|
-
$.value ? (
|
|
230
|
+
})) : n("v-if", !0)
|
|
231
|
+
], !0) : n("v-if", !0),
|
|
232
|
+
$.value ? (o(), u(i(I), {
|
|
239
233
|
key: 1,
|
|
240
234
|
color: "transparent",
|
|
241
235
|
tabindex: "-1",
|
|
242
236
|
size: "mini",
|
|
243
|
-
onClick:
|
|
237
|
+
onClick: a[2] || (a[2] = ae((m) => c.value = !c.value, ["stop"]))
|
|
244
238
|
}, {
|
|
245
239
|
default: V(() => [
|
|
246
|
-
c.value ? (
|
|
240
|
+
c.value ? (o(), u(i(M), {
|
|
247
241
|
key: 0,
|
|
248
242
|
class: "maz-text-xl maz-text-muted"
|
|
249
|
-
})) : (
|
|
243
|
+
})) : (o(), u(i(q), {
|
|
250
244
|
key: 1,
|
|
251
245
|
class: "maz-text-xl maz-text-muted"
|
|
252
246
|
}))
|
|
253
247
|
]),
|
|
254
248
|
_: 1
|
|
255
249
|
/* STABLE */
|
|
256
|
-
})) :
|
|
257
|
-
o(`
|
|
258
|
-
@slot valid-button - Replace the valid button by your own
|
|
259
|
-
`),
|
|
250
|
+
})) : n("v-if", !0),
|
|
260
251
|
e.$slots["valid-button"] || e.validButton ? k(e.$slots, "valid-button", { key: 2 }, () => [
|
|
261
252
|
S(i(I), {
|
|
262
253
|
color: "transparent",
|
|
@@ -268,13 +259,13 @@ const ie = {
|
|
|
268
259
|
type: "submit"
|
|
269
260
|
}, {
|
|
270
261
|
default: V(() => [
|
|
271
|
-
S(i(
|
|
262
|
+
S(i(D), { class: "maz-text-2xl maz-text-normal" })
|
|
272
263
|
]),
|
|
273
264
|
_: 1
|
|
274
265
|
/* STABLE */
|
|
275
266
|
}, 8, ["disabled", "loading"])
|
|
276
|
-
], !0) :
|
|
277
|
-
])) :
|
|
267
|
+
], !0) : n("v-if", !0)
|
|
268
|
+
])) : n("v-if", !0)
|
|
278
269
|
],
|
|
279
270
|
2
|
|
280
271
|
/* CLASS */
|