@validol4ik/uikit 0.4.7 → 0.4.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{AppButtonCopy-DC3Dy-P9.cjs → AppButtonCopy-Brk4ZtiF.cjs} +1 -1
- package/dist/{AppButtonCopy-BAJDATwH.js → AppButtonCopy-CKJG9x84.js} +1 -1
- package/dist/{AppSelect-CnoOOUQ9.js → AppSelect-CLC9ncKt.js} +2 -2
- package/dist/{AppSelect-C4qbc8mB.cjs → AppSelect-D10eX6iO.cjs} +1 -1
- package/dist/{DropdownButton-BhopZ7Zq.js → DropdownButton-B1TfiIzK.js} +2 -2
- package/dist/{DropdownButton-CoPZFOIK.cjs → DropdownButton-CELFRZ9Z.cjs} +1 -1
- package/dist/{QMenu-QSoe-Mhv.cjs → QMenu-CUcASiv7.cjs} +1 -1
- package/dist/{QMenu-B0XjB-Ao.js → QMenu-DYJBr-eW.js} +1 -1
- package/dist/{index-BEAKbg3k.js → index-CCGzAkrR.js} +316 -312
- package/dist/index-xA0H_IQC.cjs +1 -0
- package/dist/style.css +1 -1
- package/dist/uikit.cjs +1 -1
- package/dist/uikit.es.js +1 -1
- package/package.json +1 -1
- package/dist/index-B_s6sq0L.cjs +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { computed as
|
|
1
|
+
import { computed as u, markRaw as ye, defineComponent as Q, h as p, withDirectives as ke, getCurrentInstance as X, unref as U, ref as te, onBeforeUnmount as Ae, Transition as ze, openBlock as S, createBlock as _e, normalizeClass as A, withCtx as Te, createElementBlock as B, createCommentVNode as z, renderSlot as $e, Fragment as qe, createTextVNode as Oe, toDisplayString as Y, createElementVNode as F, normalizeStyle as Se, useTemplateRef as De, watch as xe, onMounted as je, renderList as Ie, nextTick as ie, withKeys as Ne, defineAsyncComponent as le } from "vue";
|
|
2
2
|
const we = {
|
|
3
3
|
PRIMARY: "primary",
|
|
4
4
|
INFO: "info"
|
|
@@ -20,10 +20,10 @@ const we = {
|
|
|
20
20
|
size: String
|
|
21
21
|
};
|
|
22
22
|
function re(e, t = ne) {
|
|
23
|
-
return
|
|
23
|
+
return u(() => e.size !== void 0 ? { fontSize: e.size in t ? `${t[e.size]}px` : e.size } : null);
|
|
24
24
|
}
|
|
25
25
|
function W(e) {
|
|
26
|
-
return ye(
|
|
26
|
+
return ye(Q(e));
|
|
27
27
|
}
|
|
28
28
|
function Ve(e) {
|
|
29
29
|
return ye(e);
|
|
@@ -45,10 +45,10 @@ function N(e, t) {
|
|
|
45
45
|
function Vt(e, t) {
|
|
46
46
|
return e === void 0 ? t : t !== void 0 ? t.concat(e()) : e();
|
|
47
47
|
}
|
|
48
|
-
function Ft(e, t, n, a, o,
|
|
48
|
+
function Ft(e, t, n, a, o, s) {
|
|
49
49
|
t.key = a + o;
|
|
50
|
-
const
|
|
51
|
-
return o === !0 ? ke(
|
|
50
|
+
const r = p(e, t, n);
|
|
51
|
+
return o === !0 ? ke(r, s()) : r;
|
|
52
52
|
}
|
|
53
53
|
const se = "0 0 24 24", ue = (e) => e, ee = (e) => `ionicons ${e}`, Be = {
|
|
54
54
|
"mdi-": (e) => `mdi ${e}`,
|
|
@@ -84,91 +84,91 @@ const se = "0 0 24 24", ue = (e) => e, ee = (e) => `ionicons ${e}`, Be = {
|
|
|
84
84
|
right: Boolean
|
|
85
85
|
},
|
|
86
86
|
setup(e, { slots: t }) {
|
|
87
|
-
const { proxy: { $q: n } } = X(), a = re(e), o =
|
|
87
|
+
const { proxy: { $q: n } } = X(), a = re(e), o = u(
|
|
88
88
|
() => "q-icon" + (e.left === !0 ? " on-left" : "") + (e.right === !0 ? " on-right" : "") + (e.color !== void 0 ? ` text-${e.color}` : "")
|
|
89
|
-
),
|
|
90
|
-
let
|
|
91
|
-
if (
|
|
89
|
+
), s = u(() => {
|
|
90
|
+
let r, i = e.name;
|
|
91
|
+
if (i === "none" || !i)
|
|
92
92
|
return { none: !0 };
|
|
93
93
|
if (n.iconMapFn !== null) {
|
|
94
|
-
const
|
|
95
|
-
if (
|
|
96
|
-
if (
|
|
97
|
-
if (
|
|
94
|
+
const f = n.iconMapFn(i);
|
|
95
|
+
if (f !== void 0)
|
|
96
|
+
if (f.icon !== void 0) {
|
|
97
|
+
if (i = f.icon, i === "none" || !i)
|
|
98
98
|
return { none: !0 };
|
|
99
99
|
} else
|
|
100
100
|
return {
|
|
101
|
-
cls:
|
|
102
|
-
content:
|
|
101
|
+
cls: f.cls,
|
|
102
|
+
content: f.content !== void 0 ? f.content : " "
|
|
103
103
|
};
|
|
104
104
|
}
|
|
105
|
-
if (He.test(
|
|
106
|
-
const [
|
|
105
|
+
if (He.test(i) === !0) {
|
|
106
|
+
const [f, _ = se] = i.split("|");
|
|
107
107
|
return {
|
|
108
108
|
svg: !0,
|
|
109
109
|
viewBox: _,
|
|
110
|
-
nodes:
|
|
111
|
-
const [
|
|
112
|
-
return p("path", { style:
|
|
110
|
+
nodes: f.split("&&").map((l) => {
|
|
111
|
+
const [v, m, g] = l.split("@@");
|
|
112
|
+
return p("path", { style: m, d: v, transform: g });
|
|
113
113
|
})
|
|
114
114
|
};
|
|
115
115
|
}
|
|
116
|
-
if (Ue.test(
|
|
116
|
+
if (Ue.test(i) === !0)
|
|
117
117
|
return {
|
|
118
118
|
img: !0,
|
|
119
|
-
src:
|
|
119
|
+
src: i.substring(4)
|
|
120
120
|
};
|
|
121
|
-
if (Ye.test(
|
|
122
|
-
const [
|
|
121
|
+
if (Ye.test(i) === !0) {
|
|
122
|
+
const [f, _ = se] = i.split("|");
|
|
123
123
|
return {
|
|
124
124
|
svguse: !0,
|
|
125
|
-
src:
|
|
125
|
+
src: f.substring(7),
|
|
126
126
|
viewBox: _
|
|
127
127
|
};
|
|
128
128
|
}
|
|
129
129
|
let q = " ";
|
|
130
|
-
const k =
|
|
130
|
+
const k = i.match(Qe);
|
|
131
131
|
if (k !== null)
|
|
132
|
-
|
|
133
|
-
else if (We.test(
|
|
134
|
-
|
|
135
|
-
else if (Xe.test(
|
|
136
|
-
|
|
137
|
-
else if (ce.test(
|
|
138
|
-
|
|
139
|
-
const
|
|
140
|
-
|
|
132
|
+
r = Be[k[1]](i);
|
|
133
|
+
else if (We.test(i) === !0)
|
|
134
|
+
r = i;
|
|
135
|
+
else if (Xe.test(i) === !0)
|
|
136
|
+
r = `ionicons ion-${n.platform.is.ios === !0 ? "ios" : "md"}${i.substring(3)}`;
|
|
137
|
+
else if (ce.test(i) === !0) {
|
|
138
|
+
r = "notranslate material-symbols";
|
|
139
|
+
const f = i.match(ce);
|
|
140
|
+
f !== null && (i = i.substring(6), r += Le[f[1]]), q = i;
|
|
141
141
|
} else {
|
|
142
|
-
|
|
143
|
-
const
|
|
144
|
-
|
|
142
|
+
r = "notranslate material-icons";
|
|
143
|
+
const f = i.match(Ge);
|
|
144
|
+
f !== null && (i = i.substring(2), r += Ce[f[1]]), q = i;
|
|
145
145
|
}
|
|
146
146
|
return {
|
|
147
|
-
cls:
|
|
147
|
+
cls: r,
|
|
148
148
|
content: q
|
|
149
149
|
};
|
|
150
150
|
});
|
|
151
151
|
return () => {
|
|
152
|
-
const
|
|
152
|
+
const r = {
|
|
153
153
|
class: o.value,
|
|
154
154
|
style: a.value,
|
|
155
155
|
"aria-hidden": "true",
|
|
156
156
|
role: "presentation"
|
|
157
157
|
};
|
|
158
|
-
return
|
|
159
|
-
p("img", { src:
|
|
160
|
-
])) :
|
|
158
|
+
return s.value.none === !0 ? p(e.tag, r, Fe(t.default)) : s.value.img === !0 ? p(e.tag, r, N(t.default, [
|
|
159
|
+
p("img", { src: s.value.src })
|
|
160
|
+
])) : s.value.svg === !0 ? p(e.tag, r, N(t.default, [
|
|
161
161
|
p("svg", {
|
|
162
|
-
viewBox:
|
|
163
|
-
},
|
|
164
|
-
])) :
|
|
162
|
+
viewBox: s.value.viewBox || "0 0 24 24"
|
|
163
|
+
}, s.value.nodes)
|
|
164
|
+
])) : s.value.svguse === !0 ? p(e.tag, r, N(t.default, [
|
|
165
165
|
p("svg", {
|
|
166
|
-
viewBox:
|
|
166
|
+
viewBox: s.value.viewBox
|
|
167
167
|
}, [
|
|
168
|
-
p("use", { "xlink:href":
|
|
168
|
+
p("use", { "xlink:href": s.value.src })
|
|
169
169
|
])
|
|
170
|
-
])) : (
|
|
171
|
-
|
|
170
|
+
])) : (s.value.cls !== void 0 && (r.class += " " + s.value.cls), p(e.tag, r, N(t.default, [
|
|
171
|
+
s.value.content
|
|
172
172
|
])));
|
|
173
173
|
};
|
|
174
174
|
}
|
|
@@ -181,8 +181,8 @@ const se = "0 0 24 24", ue = (e) => e, ee = (e) => `ionicons ${e}`, Be = {
|
|
|
181
181
|
};
|
|
182
182
|
function Ze(e) {
|
|
183
183
|
return {
|
|
184
|
-
cSize:
|
|
185
|
-
classes:
|
|
184
|
+
cSize: u(() => e.size in ne ? `${ne[e.size]}px` : e.size),
|
|
185
|
+
classes: u(
|
|
186
186
|
() => "q-spinner" + (e.color ? ` text-${e.color}` : "")
|
|
187
187
|
)
|
|
188
188
|
};
|
|
@@ -231,7 +231,7 @@ function Qt(e) {
|
|
|
231
231
|
} catch {
|
|
232
232
|
return;
|
|
233
233
|
}
|
|
234
|
-
const t =
|
|
234
|
+
const t = U(e);
|
|
235
235
|
if (t)
|
|
236
236
|
return t.$el || t;
|
|
237
237
|
}
|
|
@@ -322,23 +322,23 @@ function it(e, t = 250) {
|
|
|
322
322
|
function fe(e, t, n, a) {
|
|
323
323
|
n.modifiers.stop === !0 && Ee(e);
|
|
324
324
|
const o = n.modifiers.color;
|
|
325
|
-
let
|
|
326
|
-
|
|
327
|
-
const
|
|
328
|
-
|
|
329
|
-
height: `${
|
|
330
|
-
width: `${
|
|
331
|
-
transform: `translate3d(${
|
|
325
|
+
let s = n.modifiers.center;
|
|
326
|
+
s = s === !0 || a === !0;
|
|
327
|
+
const r = document.createElement("span"), i = document.createElement("span"), q = nt(e), { left: k, top: f, width: _, height: l } = t.getBoundingClientRect(), v = Math.sqrt(_ * _ + l * l), m = v / 2, g = `${(_ - v) / 2}px`, d = s ? g : `${q.left - k - m}px`, h = `${(l - v) / 2}px`, w = s ? h : `${q.top - f - m}px`;
|
|
328
|
+
i.className = "q-ripple__inner", tt(i, {
|
|
329
|
+
height: `${v}px`,
|
|
330
|
+
width: `${v}px`,
|
|
331
|
+
transform: `translate3d(${d},${w},0) scale3d(.2,.2,1)`,
|
|
332
332
|
opacity: 0
|
|
333
|
-
}),
|
|
334
|
-
const
|
|
335
|
-
|
|
333
|
+
}), r.className = `q-ripple${o ? " text-" + o : ""}`, r.setAttribute("dir", "ltr"), r.appendChild(i), t.appendChild(r);
|
|
334
|
+
const M = () => {
|
|
335
|
+
r.remove(), clearTimeout(O);
|
|
336
336
|
};
|
|
337
|
-
n.abort.push(
|
|
338
|
-
let
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
337
|
+
n.abort.push(M);
|
|
338
|
+
let O = setTimeout(() => {
|
|
339
|
+
i.classList.add("q-ripple__inner--enter"), i.style.transform = `translate3d(${g},${h},0) scale3d(1,1,1)`, i.style.opacity = 0.2, O = setTimeout(() => {
|
|
340
|
+
i.classList.remove("q-ripple__inner--enter"), i.classList.add("q-ripple__inner--leave"), i.style.opacity = 0, O = setTimeout(() => {
|
|
341
|
+
r.remove(), n.abort.splice(n.abort.indexOf(M), 1);
|
|
342
342
|
}, 275);
|
|
343
343
|
}, 250);
|
|
344
344
|
}, 50);
|
|
@@ -407,7 +407,7 @@ const st = Ve(
|
|
|
407
407
|
}
|
|
408
408
|
};
|
|
409
409
|
function dt(e) {
|
|
410
|
-
return
|
|
410
|
+
return u(() => {
|
|
411
411
|
const t = e.align === void 0 ? e.vertical === !0 ? "stretch" : "left" : e.align;
|
|
412
412
|
return `${e.vertical === !0 ? "items" : "justify"}-${Re[t]}`;
|
|
413
413
|
});
|
|
@@ -440,7 +440,7 @@ function vt(e, t) {
|
|
|
440
440
|
if (typeof a == "string") {
|
|
441
441
|
if (a !== o)
|
|
442
442
|
return !1;
|
|
443
|
-
} else if (Array.isArray(o) === !1 || o.length !== a.length || a.some((
|
|
443
|
+
} else if (Array.isArray(o) === !1 || o.length !== a.length || a.some((s, r) => s !== o[r]))
|
|
444
444
|
return !1;
|
|
445
445
|
}
|
|
446
446
|
return !0;
|
|
@@ -482,42 +482,42 @@ const Me = {
|
|
|
482
482
|
}
|
|
483
483
|
};
|
|
484
484
|
function mt({ fallbackTag: e, useDisableForRouterLinkProps: t = !0 } = {}) {
|
|
485
|
-
const n = X(), { props: a, proxy: o, emit:
|
|
486
|
-
() =>
|
|
487
|
-
) :
|
|
488
|
-
() =>
|
|
489
|
-
), k =
|
|
485
|
+
const n = X(), { props: a, proxy: o, emit: s } = n, r = ft(n), i = u(() => a.disable !== !0 && a.href !== void 0), q = t === !0 ? u(
|
|
486
|
+
() => r === !0 && a.disable !== !0 && i.value !== !0 && a.to !== void 0 && a.to !== null && a.to !== ""
|
|
487
|
+
) : u(
|
|
488
|
+
() => r === !0 && i.value !== !0 && a.to !== void 0 && a.to !== null && a.to !== ""
|
|
489
|
+
), k = u(() => q.value === !0 ? w(a.to) : null), f = u(() => k.value !== null), _ = u(() => i.value === !0 || f.value === !0), l = u(() => a.type === "a" || _.value === !0 ? "a" : a.tag || e || "div"), v = u(() => i.value === !0 ? {
|
|
490
490
|
href: a.href,
|
|
491
491
|
target: a.target
|
|
492
|
-
} :
|
|
492
|
+
} : f.value === !0 ? {
|
|
493
493
|
href: k.value.href,
|
|
494
494
|
target: a.target
|
|
495
|
-
} : {}),
|
|
496
|
-
if (
|
|
495
|
+
} : {}), m = u(() => {
|
|
496
|
+
if (f.value === !1)
|
|
497
497
|
return -1;
|
|
498
|
-
const { matched: b } = k.value, { length:
|
|
499
|
-
if (
|
|
498
|
+
const { matched: b } = k.value, { length: C } = b, E = b[C - 1];
|
|
499
|
+
if (E === void 0)
|
|
500
500
|
return -1;
|
|
501
|
-
const
|
|
502
|
-
if (
|
|
501
|
+
const P = o.$route.matched;
|
|
502
|
+
if (P.length === 0)
|
|
503
503
|
return -1;
|
|
504
|
-
const
|
|
505
|
-
pe.bind(null,
|
|
504
|
+
const T = P.findIndex(
|
|
505
|
+
pe.bind(null, E)
|
|
506
506
|
);
|
|
507
|
-
if (
|
|
508
|
-
return
|
|
509
|
-
const
|
|
507
|
+
if (T !== -1)
|
|
508
|
+
return T;
|
|
509
|
+
const G = ge(b[C - 2]);
|
|
510
510
|
return (
|
|
511
511
|
// we are dealing with nested routes
|
|
512
|
-
|
|
513
|
-
pe.bind(null, b[
|
|
514
|
-
) :
|
|
512
|
+
C > 1 && ge(E) === G && P[P.length - 1].path !== G ? P.findIndex(
|
|
513
|
+
pe.bind(null, b[C - 2])
|
|
514
|
+
) : T
|
|
515
515
|
);
|
|
516
|
-
}),
|
|
517
|
-
() =>
|
|
518
|
-
),
|
|
519
|
-
() =>
|
|
520
|
-
),
|
|
516
|
+
}), g = u(
|
|
517
|
+
() => f.value === !0 && m.value !== -1 && vt(o.$route.params, k.value.params)
|
|
518
|
+
), d = u(
|
|
519
|
+
() => g.value === !0 && m.value === o.$route.matched.length - 1 && pt(o.$route.params, k.value.params)
|
|
520
|
+
), h = u(() => f.value === !0 ? d.value === !0 ? ` ${a.exactActiveClass} ${a.activeClass}` : a.exact === !0 ? "" : g.value === !0 ? ` ${a.activeClass}` : "" : "");
|
|
521
521
|
function w(b) {
|
|
522
522
|
try {
|
|
523
523
|
return o.$router.resolve(b);
|
|
@@ -525,7 +525,7 @@ function mt({ fallbackTag: e, useDisableForRouterLinkProps: t = !0 } = {}) {
|
|
|
525
525
|
}
|
|
526
526
|
return null;
|
|
527
527
|
}
|
|
528
|
-
function
|
|
528
|
+
function M(b, { returnRouterError: C, to: E = a.to, replace: P = a.replace } = {}) {
|
|
529
529
|
if (a.disable === !0)
|
|
530
530
|
return b.preventDefault(), Promise.resolve(!1);
|
|
531
531
|
if (
|
|
@@ -535,31 +535,31 @@ function mt({ fallbackTag: e, useDisableForRouterLinkProps: t = !0 } = {}) {
|
|
|
535
535
|
)
|
|
536
536
|
return Promise.resolve(!1);
|
|
537
537
|
b.preventDefault();
|
|
538
|
-
const
|
|
539
|
-
return
|
|
538
|
+
const T = o.$router[P === !0 ? "replace" : "push"](E);
|
|
539
|
+
return C === !0 ? T : T.then(() => {
|
|
540
540
|
}).catch(() => {
|
|
541
541
|
});
|
|
542
542
|
}
|
|
543
|
-
function
|
|
544
|
-
if (
|
|
545
|
-
const
|
|
546
|
-
|
|
543
|
+
function O(b) {
|
|
544
|
+
if (f.value === !0) {
|
|
545
|
+
const C = (E) => M(b, E);
|
|
546
|
+
s("click", b, C), b.defaultPrevented !== !0 && C();
|
|
547
547
|
} else
|
|
548
|
-
|
|
548
|
+
s("click", b);
|
|
549
549
|
}
|
|
550
550
|
return {
|
|
551
|
-
hasRouterLink:
|
|
552
|
-
hasHrefLink:
|
|
551
|
+
hasRouterLink: f,
|
|
552
|
+
hasHrefLink: i,
|
|
553
553
|
hasLink: _,
|
|
554
|
-
linkTag:
|
|
554
|
+
linkTag: l,
|
|
555
555
|
resolvedLink: k,
|
|
556
|
-
linkIsActive:
|
|
557
|
-
linkIsExactActive:
|
|
558
|
-
linkClass:
|
|
559
|
-
linkAttrs:
|
|
556
|
+
linkIsActive: g,
|
|
557
|
+
linkIsExactActive: d,
|
|
558
|
+
linkClass: h,
|
|
559
|
+
linkAttrs: v,
|
|
560
560
|
getLink: w,
|
|
561
|
-
navigateToRouterLink:
|
|
562
|
-
navigateOnClick:
|
|
561
|
+
navigateToRouterLink: M,
|
|
562
|
+
navigateOnClick: O
|
|
563
563
|
};
|
|
564
564
|
}
|
|
565
565
|
const he = {
|
|
@@ -630,47 +630,47 @@ const _t = {
|
|
|
630
630
|
round: Boolean
|
|
631
631
|
};
|
|
632
632
|
function qt(e) {
|
|
633
|
-
const t = re(e, ht), n = dt(e), { hasRouterLink: a, hasLink: o, linkTag:
|
|
633
|
+
const t = re(e, ht), n = dt(e), { hasRouterLink: a, hasLink: o, linkTag: s, linkAttrs: r, navigateOnClick: i } = mt({
|
|
634
634
|
fallbackTag: "button"
|
|
635
|
-
}), q =
|
|
636
|
-
const
|
|
637
|
-
return e.padding !== void 0 ? Object.assign({},
|
|
638
|
-
padding: e.padding.split(/\s+/).map((
|
|
635
|
+
}), q = u(() => {
|
|
636
|
+
const d = e.fab === !1 && e.fabMini === !1 ? t.value : {};
|
|
637
|
+
return e.padding !== void 0 ? Object.assign({}, d, {
|
|
638
|
+
padding: e.padding.split(/\s+/).map((h) => h in he ? he[h] + "px" : h).join(" "),
|
|
639
639
|
minWidth: "0",
|
|
640
640
|
minHeight: "0"
|
|
641
|
-
}) :
|
|
642
|
-
}), k =
|
|
641
|
+
}) : d;
|
|
642
|
+
}), k = u(
|
|
643
643
|
() => e.rounded === !0 || e.fab === !0 || e.fabMini === !0
|
|
644
|
-
),
|
|
644
|
+
), f = u(
|
|
645
645
|
() => e.disable !== !0 && e.loading !== !0
|
|
646
|
-
), _ =
|
|
647
|
-
const
|
|
648
|
-
return o.value === !0 ? Object.assign(
|
|
646
|
+
), _ = u(() => f.value === !0 ? e.tabindex || 0 : -1), l = u(() => Pe(e, "standard")), v = u(() => {
|
|
647
|
+
const d = { tabindex: _.value };
|
|
648
|
+
return o.value === !0 ? Object.assign(d, r.value) : bt.includes(e.type) === !0 && (d.type = e.type), s.value === "a" ? (e.disable === !0 ? d["aria-disabled"] = "true" : d.href === void 0 && (d.role = "button"), a.value !== !0 && yt.test(e.type) === !0 && (d.type = e.type)) : e.disable === !0 && (d.disabled = "", d["aria-disabled"] = "true"), e.loading === !0 && e.percentage !== void 0 && Object.assign(d, {
|
|
649
649
|
role: "progressbar",
|
|
650
650
|
"aria-valuemin": 0,
|
|
651
651
|
"aria-valuemax": 100,
|
|
652
652
|
"aria-valuenow": e.percentage
|
|
653
|
-
}),
|
|
654
|
-
}),
|
|
655
|
-
let
|
|
656
|
-
e.color !== void 0 ? e.flat === !0 || e.outline === !0 ?
|
|
657
|
-
const
|
|
658
|
-
return `q-btn--${
|
|
659
|
-
}),
|
|
653
|
+
}), d;
|
|
654
|
+
}), m = u(() => {
|
|
655
|
+
let d;
|
|
656
|
+
e.color !== void 0 ? e.flat === !0 || e.outline === !0 ? d = `text-${e.textColor || e.color}` : d = `bg-${e.color} text-${e.textColor || "white"}` : e.textColor && (d = `text-${e.textColor}`);
|
|
657
|
+
const h = e.round === !0 ? "round" : `rectangle${k.value === !0 ? " q-btn--rounded" : e.square === !0 ? " q-btn--square" : ""}`;
|
|
658
|
+
return `q-btn--${l.value} q-btn--${h}` + (d !== void 0 ? " " + d : "") + (f.value === !0 ? " q-btn--actionable q-focusable q-hoverable" : e.disable === !0 ? " disabled" : "") + (e.fab === !0 ? " q-btn--fab" : e.fabMini === !0 ? " q-btn--fab-mini" : "") + (e.noCaps === !0 ? " q-btn--no-uppercase" : "") + (e.dense === !0 ? " q-btn--dense" : "") + (e.stretch === !0 ? " no-border-radius self-stretch" : "") + (e.glossy === !0 ? " glossy" : "") + (e.square ? " q-btn--square" : "");
|
|
659
|
+
}), g = u(
|
|
660
660
|
() => n.value + (e.stack === !0 ? " column" : " row") + (e.noWrap === !0 ? " no-wrap text-no-wrap" : "") + (e.loading === !0 ? " q-btn__content--hidden" : "")
|
|
661
661
|
);
|
|
662
662
|
return {
|
|
663
|
-
classes:
|
|
663
|
+
classes: m,
|
|
664
664
|
style: q,
|
|
665
|
-
innerClasses:
|
|
666
|
-
attributes:
|
|
665
|
+
innerClasses: g,
|
|
666
|
+
attributes: v,
|
|
667
667
|
hasLink: o,
|
|
668
|
-
linkTag:
|
|
669
|
-
navigateOnClick:
|
|
670
|
-
isActionable:
|
|
668
|
+
linkTag: s,
|
|
669
|
+
navigateOnClick: i,
|
|
670
|
+
isActionable: f
|
|
671
671
|
};
|
|
672
672
|
}
|
|
673
|
-
const { passiveCapture:
|
|
673
|
+
const { passiveCapture: L } = J;
|
|
674
674
|
let x = null, j = null, I = null;
|
|
675
675
|
const St = W({
|
|
676
676
|
name: "QBtn",
|
|
@@ -684,24 +684,24 @@ const St = W({
|
|
|
684
684
|
setup(e, { slots: t, emit: n }) {
|
|
685
685
|
const { proxy: a } = X(), {
|
|
686
686
|
classes: o,
|
|
687
|
-
style:
|
|
688
|
-
innerClasses:
|
|
689
|
-
attributes:
|
|
687
|
+
style: s,
|
|
688
|
+
innerClasses: r,
|
|
689
|
+
attributes: i,
|
|
690
690
|
hasLink: q,
|
|
691
691
|
linkTag: k,
|
|
692
|
-
navigateOnClick:
|
|
692
|
+
navigateOnClick: f,
|
|
693
693
|
isActionable: _
|
|
694
|
-
} = qt(e),
|
|
695
|
-
let
|
|
696
|
-
const
|
|
694
|
+
} = qt(e), l = te(null), v = te(null);
|
|
695
|
+
let m = null, g, d = null;
|
|
696
|
+
const h = u(
|
|
697
697
|
() => e.label !== void 0 && e.label !== null && e.label !== ""
|
|
698
|
-
), w =
|
|
698
|
+
), w = u(() => e.disable === !0 || e.ripple === !1 ? !1 : {
|
|
699
699
|
keyCodes: q.value === !0 ? [13, 32] : [13],
|
|
700
700
|
...e.ripple === !0 ? {} : e.ripple
|
|
701
|
-
}),
|
|
702
|
-
const
|
|
703
|
-
return
|
|
704
|
-
}), b =
|
|
701
|
+
}), M = u(() => ({ center: e.round })), O = u(() => {
|
|
702
|
+
const c = Math.max(0, Math.min(100, e.percentage));
|
|
703
|
+
return c > 0 ? { transition: "transform 0.6s", transform: `translateX(${c - 100}%)` } : {};
|
|
704
|
+
}), b = u(() => {
|
|
705
705
|
if (e.loading === !0)
|
|
706
706
|
return {
|
|
707
707
|
onMousedown: V,
|
|
@@ -711,102 +711,102 @@ const St = W({
|
|
|
711
711
|
onKeyup: V
|
|
712
712
|
};
|
|
713
713
|
if (_.value === !0) {
|
|
714
|
-
const
|
|
715
|
-
onClick:
|
|
716
|
-
onKeydown:
|
|
717
|
-
onMousedown:
|
|
714
|
+
const c = {
|
|
715
|
+
onClick: E,
|
|
716
|
+
onKeydown: P,
|
|
717
|
+
onMousedown: G
|
|
718
718
|
};
|
|
719
719
|
if (a.$q.platform.has.touch === !0) {
|
|
720
720
|
const y = e.onTouchstart !== void 0 ? "" : "Passive";
|
|
721
|
-
|
|
721
|
+
c[`onTouchstart${y}`] = T;
|
|
722
722
|
}
|
|
723
|
-
return
|
|
723
|
+
return c;
|
|
724
724
|
}
|
|
725
725
|
return {
|
|
726
726
|
// needed; especially for disabled <a> tags
|
|
727
727
|
onClick: D
|
|
728
728
|
};
|
|
729
|
-
}),
|
|
730
|
-
ref:
|
|
729
|
+
}), C = u(() => ({
|
|
730
|
+
ref: l,
|
|
731
731
|
class: "q-btn q-btn-item non-selectable no-outline " + o.value,
|
|
732
|
-
style:
|
|
733
|
-
...
|
|
732
|
+
style: s.value,
|
|
733
|
+
...i.value,
|
|
734
734
|
...b.value
|
|
735
735
|
}));
|
|
736
|
-
function
|
|
737
|
-
if (
|
|
738
|
-
if (
|
|
739
|
-
if (
|
|
736
|
+
function E(c) {
|
|
737
|
+
if (l.value !== null) {
|
|
738
|
+
if (c !== void 0) {
|
|
739
|
+
if (c.defaultPrevented === !0)
|
|
740
740
|
return;
|
|
741
741
|
const y = document.activeElement;
|
|
742
|
-
if (e.type === "submit" && y !== document.body &&
|
|
743
|
-
|
|
744
|
-
const
|
|
745
|
-
document.removeEventListener("keydown", D, !0), document.removeEventListener("keyup",
|
|
742
|
+
if (e.type === "submit" && y !== document.body && l.value.contains(y) === !1 && y.contains(l.value) === !1) {
|
|
743
|
+
l.value.focus();
|
|
744
|
+
const H = () => {
|
|
745
|
+
document.removeEventListener("keydown", D, !0), document.removeEventListener("keyup", H, L), l.value !== null && l.value.removeEventListener("blur", H, L);
|
|
746
746
|
};
|
|
747
|
-
document.addEventListener("keydown", D, !0), document.addEventListener("keyup",
|
|
747
|
+
document.addEventListener("keydown", D, !0), document.addEventListener("keyup", H, L), l.value.addEventListener("blur", H, L);
|
|
748
748
|
}
|
|
749
749
|
}
|
|
750
|
-
|
|
750
|
+
f(c);
|
|
751
751
|
}
|
|
752
752
|
}
|
|
753
|
-
function
|
|
754
|
-
|
|
753
|
+
function P(c) {
|
|
754
|
+
l.value !== null && (n("keydown", c), ae(c, [13, 32]) === !0 && j !== l.value && (j !== null && K(), c.defaultPrevented !== !0 && (l.value.focus(), j = l.value, l.value.classList.add("q-btn--active"), document.addEventListener("keyup", R, !0), l.value.addEventListener("blur", R, L)), D(c)));
|
|
755
755
|
}
|
|
756
|
-
function
|
|
757
|
-
|
|
758
|
-
|
|
756
|
+
function T(c) {
|
|
757
|
+
l.value !== null && (n("touchstart", c), c.defaultPrevented !== !0 && (x !== l.value && (x !== null && K(), x = l.value, m = c.target, m.addEventListener("touchcancel", R, L), m.addEventListener("touchend", R, L)), g = !0, d !== null && clearTimeout(d), d = setTimeout(() => {
|
|
758
|
+
d = null, g = !1;
|
|
759
759
|
}, 200)));
|
|
760
760
|
}
|
|
761
|
-
function
|
|
762
|
-
|
|
761
|
+
function G(c) {
|
|
762
|
+
l.value !== null && (c.qSkipRipple = g === !0, n("mousedown", c), c.defaultPrevented !== !0 && I !== l.value && (I !== null && K(), I = l.value, l.value.classList.add("q-btn--active"), document.addEventListener("mouseup", R, L)));
|
|
763
763
|
}
|
|
764
|
-
function
|
|
765
|
-
if (
|
|
766
|
-
if (
|
|
767
|
-
if (j ===
|
|
768
|
-
const y = new MouseEvent("click",
|
|
769
|
-
y.qKeyEvent = !0,
|
|
764
|
+
function R(c) {
|
|
765
|
+
if (l.value !== null && !(c !== void 0 && c.type === "blur" && document.activeElement === l.value)) {
|
|
766
|
+
if (c !== void 0 && c.type === "keyup") {
|
|
767
|
+
if (j === l.value && ae(c, [13, 32]) === !0) {
|
|
768
|
+
const y = new MouseEvent("click", c);
|
|
769
|
+
y.qKeyEvent = !0, c.defaultPrevented === !0 && at(y), c.cancelBubble === !0 && Ee(y), l.value.dispatchEvent(y), D(c), c.qKeyEvent = !0;
|
|
770
770
|
}
|
|
771
|
-
n("keyup",
|
|
771
|
+
n("keyup", c);
|
|
772
772
|
}
|
|
773
773
|
K();
|
|
774
774
|
}
|
|
775
775
|
}
|
|
776
|
-
function K(
|
|
777
|
-
const y =
|
|
778
|
-
|
|
776
|
+
function K(c) {
|
|
777
|
+
const y = v.value;
|
|
778
|
+
c !== !0 && (x === l.value || I === l.value) && y !== null && y !== document.activeElement && (y.setAttribute("tabindex", -1), y.focus()), x === l.value && (m !== null && (m.removeEventListener("touchcancel", R, L), m.removeEventListener("touchend", R, L)), x = m = null), I === l.value && (document.removeEventListener("mouseup", R, L), I = null), j === l.value && (document.removeEventListener("keyup", R, !0), l.value !== null && l.value.removeEventListener("blur", R, L), j = null), l.value !== null && l.value.classList.remove("q-btn--active");
|
|
779
779
|
}
|
|
780
|
-
function V(
|
|
781
|
-
D(
|
|
780
|
+
function V(c) {
|
|
781
|
+
D(c), c.qSkipRipple = !0;
|
|
782
782
|
}
|
|
783
783
|
return Ae(() => {
|
|
784
784
|
K(!0);
|
|
785
785
|
}), Object.assign(a, {
|
|
786
|
-
click: (
|
|
787
|
-
_.value === !0 &&
|
|
786
|
+
click: (c) => {
|
|
787
|
+
_.value === !0 && E(c);
|
|
788
788
|
}
|
|
789
789
|
}), () => {
|
|
790
|
-
let
|
|
791
|
-
e.icon !== void 0 &&
|
|
790
|
+
let c = [];
|
|
791
|
+
e.icon !== void 0 && c.push(
|
|
792
792
|
p(de, {
|
|
793
793
|
name: e.icon,
|
|
794
|
-
left: e.stack !== !0 &&
|
|
794
|
+
left: e.stack !== !0 && h.value === !0,
|
|
795
795
|
role: "img"
|
|
796
796
|
})
|
|
797
|
-
),
|
|
797
|
+
), h.value === !0 && c.push(
|
|
798
798
|
p("span", { class: "block" }, [e.label])
|
|
799
|
-
),
|
|
799
|
+
), c = N(t.default, c), e.iconRight !== void 0 && e.round === !1 && c.push(
|
|
800
800
|
p(de, {
|
|
801
801
|
name: e.iconRight,
|
|
802
|
-
right: e.stack !== !0 &&
|
|
802
|
+
right: e.stack !== !0 && h.value === !0,
|
|
803
803
|
role: "img"
|
|
804
804
|
})
|
|
805
805
|
);
|
|
806
806
|
const y = [
|
|
807
807
|
p("span", {
|
|
808
808
|
class: "q-focus-helper",
|
|
809
|
-
ref:
|
|
809
|
+
ref: v
|
|
810
810
|
})
|
|
811
811
|
];
|
|
812
812
|
return e.loading === !0 && e.percentage !== void 0 && y.push(
|
|
@@ -815,13 +815,13 @@ const St = W({
|
|
|
815
815
|
}, [
|
|
816
816
|
p("span", {
|
|
817
817
|
class: "q-btn__progress-indicator fit block",
|
|
818
|
-
style:
|
|
818
|
+
style: O.value
|
|
819
819
|
})
|
|
820
820
|
])
|
|
821
821
|
), y.push(
|
|
822
822
|
p("span", {
|
|
823
|
-
class: "q-btn__content text-center col items-center q-anchor--skip " +
|
|
824
|
-
},
|
|
823
|
+
class: "q-btn__content text-center col items-center q-anchor--skip " + r.value
|
|
824
|
+
}, c)
|
|
825
825
|
), e.loading !== null && y.push(
|
|
826
826
|
p(ze, {
|
|
827
827
|
name: "q-transition--fade"
|
|
@@ -834,19 +834,19 @@ const St = W({
|
|
|
834
834
|
), ke(
|
|
835
835
|
p(
|
|
836
836
|
k.value,
|
|
837
|
-
|
|
837
|
+
C.value,
|
|
838
838
|
y
|
|
839
839
|
),
|
|
840
840
|
[[
|
|
841
841
|
st,
|
|
842
842
|
w.value,
|
|
843
843
|
void 0,
|
|
844
|
-
|
|
844
|
+
M.value
|
|
845
845
|
]]
|
|
846
846
|
);
|
|
847
847
|
};
|
|
848
848
|
}
|
|
849
|
-
}), wt = /* @__PURE__ */
|
|
849
|
+
}), wt = /* @__PURE__ */ Q({
|
|
850
850
|
__name: "AppButton",
|
|
851
851
|
props: {
|
|
852
852
|
size: { default: $.MD },
|
|
@@ -869,7 +869,7 @@ const St = W({
|
|
|
869
869
|
},
|
|
870
870
|
emits: ["click"],
|
|
871
871
|
setup(e) {
|
|
872
|
-
const t = e, n =
|
|
872
|
+
const t = e, n = u(() => [
|
|
873
873
|
"app-btn",
|
|
874
874
|
{
|
|
875
875
|
"app-btn_default": !t.transparent && !t.flat,
|
|
@@ -885,11 +885,11 @@ const St = W({
|
|
|
885
885
|
},
|
|
886
886
|
`app-btn_${t.color}`
|
|
887
887
|
]);
|
|
888
|
-
return (a, o) => (S(), _e(
|
|
888
|
+
return (a, o) => (S(), _e(U(St), {
|
|
889
889
|
"no-caps": "",
|
|
890
890
|
unelevated: "",
|
|
891
|
-
class:
|
|
892
|
-
padding:
|
|
891
|
+
class: A(n.value),
|
|
892
|
+
padding: U(Ke)[a.size || U($).MD],
|
|
893
893
|
loading: a.loading,
|
|
894
894
|
disable: a.disabled || void 0,
|
|
895
895
|
to: a.to,
|
|
@@ -898,31 +898,31 @@ const St = W({
|
|
|
898
898
|
type: a.submit ? "submit" : void 0,
|
|
899
899
|
"aria-label": a.ariaLabel,
|
|
900
900
|
download: a.download,
|
|
901
|
-
onClick: o[0] || (o[0] = (
|
|
901
|
+
onClick: o[0] || (o[0] = (s) => a.$emit("click", s))
|
|
902
902
|
}, {
|
|
903
903
|
default: Te(() => [
|
|
904
|
-
a.iconLeft || a.iconMiddle ? (S(),
|
|
904
|
+
a.iconLeft || a.iconMiddle ? (S(), B("i", {
|
|
905
905
|
key: 0,
|
|
906
|
-
class:
|
|
906
|
+
class: A([
|
|
907
907
|
"icon-kl",
|
|
908
908
|
a.iconLeft ? "icon-kl_left" : "icon-kl_middle",
|
|
909
909
|
`icon-kl-${a.iconLeft || a.iconMiddle}`,
|
|
910
910
|
a.transparent || a.flat ? `text-${a.color}` : "text-secondary"
|
|
911
911
|
])
|
|
912
|
-
}, null, 2)) :
|
|
912
|
+
}, null, 2)) : z("", !0),
|
|
913
913
|
$e(a.$slots, "default", {}, void 0, !0),
|
|
914
|
-
a.label ? (S(),
|
|
914
|
+
a.label ? (S(), B(qe, { key: 1 }, [
|
|
915
915
|
Oe(Y(a.label), 1)
|
|
916
|
-
], 64)) :
|
|
917
|
-
a.iconRight ? (S(),
|
|
916
|
+
], 64)) : z("", !0),
|
|
917
|
+
a.iconRight ? (S(), B("i", {
|
|
918
918
|
key: 2,
|
|
919
|
-
class:
|
|
919
|
+
class: A([
|
|
920
920
|
"icon-kl",
|
|
921
921
|
"icon-kl_right",
|
|
922
922
|
`icon-kl-${a.iconRight}`,
|
|
923
923
|
a.transparent ? `text-${a.color}` : "text-secondary"
|
|
924
924
|
])
|
|
925
|
-
}, null, 2)) :
|
|
925
|
+
}, null, 2)) : z("", !0)
|
|
926
926
|
]),
|
|
927
927
|
_: 3
|
|
928
928
|
}, 8, ["class", "padding", "loading", "disable", "to", "href", "target", "type", "aria-label", "download"]));
|
|
@@ -938,7 +938,7 @@ const St = W({
|
|
|
938
938
|
}, Ct = { class: "app-toggle__container" }, Lt = ["checked", "disabled"], Et = { class: "app-toggle__thumb" }, Rt = {
|
|
939
939
|
key: 1,
|
|
940
940
|
class: "app-toggle__label"
|
|
941
|
-
}, Mt = /* @__PURE__ */
|
|
941
|
+
}, Mt = /* @__PURE__ */ Q({
|
|
942
942
|
__name: "AppToggle",
|
|
943
943
|
props: {
|
|
944
944
|
modelValue: { type: Boolean },
|
|
@@ -953,12 +953,12 @@ const St = W({
|
|
|
953
953
|
},
|
|
954
954
|
emits: ["update:modelValue"],
|
|
955
955
|
setup(e, { emit: t }) {
|
|
956
|
-
const n = e, a = t, o =
|
|
956
|
+
const n = e, a = t, o = u({
|
|
957
957
|
get: () => n.modelValue,
|
|
958
|
-
set: (
|
|
959
|
-
a("update:modelValue",
|
|
958
|
+
set: (r) => {
|
|
959
|
+
a("update:modelValue", r);
|
|
960
960
|
}
|
|
961
|
-
}),
|
|
961
|
+
}), s = u(() => [
|
|
962
962
|
"app-toggle",
|
|
963
963
|
{
|
|
964
964
|
"app-toggle_sm": n.size === $.SM,
|
|
@@ -969,43 +969,43 @@ const St = W({
|
|
|
969
969
|
},
|
|
970
970
|
`app-toggle_${n.color}`
|
|
971
971
|
]);
|
|
972
|
-
return (
|
|
973
|
-
class:
|
|
972
|
+
return (r, i) => (S(), B("div", {
|
|
973
|
+
class: A(s.value)
|
|
974
974
|
}, [
|
|
975
|
-
|
|
975
|
+
r.label && r.labelLeft ? (S(), B("span", Bt, Y(r.label), 1)) : z("", !0),
|
|
976
976
|
F("label", Ct, [
|
|
977
977
|
F("input", {
|
|
978
978
|
type: "checkbox",
|
|
979
979
|
checked: o.value,
|
|
980
|
-
onChange:
|
|
981
|
-
disabled:
|
|
980
|
+
onChange: i[0] || (i[0] = (q) => o.value = !o.value),
|
|
981
|
+
disabled: r.disabled,
|
|
982
982
|
class: "app-toggle__input"
|
|
983
983
|
}, null, 40, Lt),
|
|
984
984
|
F("span", {
|
|
985
|
-
class:
|
|
985
|
+
class: A(["app-toggle__slider", o.value ? `bg-${r.color}` : ""])
|
|
986
986
|
}, [
|
|
987
987
|
F("span", Et, [
|
|
988
|
-
|
|
988
|
+
r.icon && !r.modelValue ? (S(), B("i", {
|
|
989
989
|
key: 0,
|
|
990
|
-
class:
|
|
991
|
-
}, null, 2)) :
|
|
992
|
-
|
|
990
|
+
class: A(["icon-kl", `icon-kl-${r.icon}`, "app-toggle__icon"])
|
|
991
|
+
}, null, 2)) : z("", !0),
|
|
992
|
+
r.modelValue && (r.iconActive || r.icon) ? (S(), B("i", {
|
|
993
993
|
key: 1,
|
|
994
|
-
class:
|
|
994
|
+
class: A([
|
|
995
995
|
"icon-kl",
|
|
996
|
-
`icon-kl-${
|
|
996
|
+
`icon-kl-${r.iconActive || r.icon}`,
|
|
997
997
|
"app-toggle__icon",
|
|
998
|
-
o.value ? `text-${
|
|
998
|
+
o.value ? `text-${r.iconColor}` : ""
|
|
999
999
|
])
|
|
1000
|
-
}, null, 2)) :
|
|
1000
|
+
}, null, 2)) : z("", !0)
|
|
1001
1001
|
])
|
|
1002
1002
|
], 2),
|
|
1003
|
-
$e(
|
|
1003
|
+
$e(r.$slots, "default", {}, void 0, !0)
|
|
1004
1004
|
]),
|
|
1005
|
-
|
|
1005
|
+
r.label && !r.labelLeft ? (S(), B("span", Rt, Y(r.label), 1)) : z("", !0)
|
|
1006
1006
|
], 2));
|
|
1007
1007
|
}
|
|
1008
|
-
}), en = /* @__PURE__ */ Z(Mt, [["__scopeId", "data-v-e0e56123"]]), Pt = /* @__PURE__ */
|
|
1008
|
+
}), en = /* @__PURE__ */ Z(Mt, [["__scopeId", "data-v-e0e56123"]]), Pt = /* @__PURE__ */ Q({
|
|
1009
1009
|
__name: "AppIcon",
|
|
1010
1010
|
props: {
|
|
1011
1011
|
name: {},
|
|
@@ -1013,8 +1013,8 @@ const St = W({
|
|
|
1013
1013
|
color: {}
|
|
1014
1014
|
},
|
|
1015
1015
|
setup(e) {
|
|
1016
|
-
return (t, n) => (S(),
|
|
1017
|
-
class:
|
|
1016
|
+
return (t, n) => (S(), B("i", {
|
|
1017
|
+
class: A(["icon-kl", `icon-kl-${t.name}`, t.color ? `text-${t.color}` : ""]),
|
|
1018
1018
|
style: Se(t.size ? `font-size: ${t.size}` : void 0)
|
|
1019
1019
|
}, null, 6));
|
|
1020
1020
|
}
|
|
@@ -1025,7 +1025,7 @@ const St = W({
|
|
|
1025
1025
|
}
|
|
1026
1026
|
};
|
|
1027
1027
|
function zt(e, t) {
|
|
1028
|
-
return
|
|
1028
|
+
return u(() => e.dark === null ? t.dark.isActive : e.dark);
|
|
1029
1029
|
}
|
|
1030
1030
|
const Tt = {
|
|
1031
1031
|
xs: 2,
|
|
@@ -1063,48 +1063,48 @@ const Ot = W({
|
|
|
1063
1063
|
instantFeedback: Boolean
|
|
1064
1064
|
},
|
|
1065
1065
|
setup(e, { slots: t }) {
|
|
1066
|
-
const { proxy: n } = X(), a = zt(e, n.$q), o = re(e, Tt),
|
|
1066
|
+
const { proxy: n } = X(), a = zt(e, n.$q), o = re(e, Tt), s = u(() => e.indeterminate === !0 || e.query === !0), r = u(() => e.reverse !== e.query), i = u(() => ({
|
|
1067
1067
|
...o.value !== null ? o.value : {},
|
|
1068
1068
|
"--q-linear-progress-speed": `${e.animationSpeed}ms`
|
|
1069
|
-
})), q =
|
|
1069
|
+
})), q = u(
|
|
1070
1070
|
() => "q-linear-progress" + (e.color !== void 0 ? ` text-${e.color}` : "") + (e.reverse === !0 || e.query === !0 ? " q-linear-progress--reverse" : "") + (e.rounded === !0 ? " rounded-borders" : "")
|
|
1071
|
-
), k =
|
|
1072
|
-
() => `q-linear-progress__track absolute-full q-linear-progress__track--${
|
|
1073
|
-
),
|
|
1074
|
-
() => `q-linear-progress__model absolute-full q-linear-progress__model--${
|
|
1075
|
-
),
|
|
1076
|
-
() => `q-linear-progress__stripe absolute-${e.reverse === !0 ? "right" : "left"} q-linear-progress__stripe--${
|
|
1071
|
+
), k = u(() => be(e.buffer !== void 0 ? e.buffer : 1, r.value, n.$q)), f = u(() => `with${e.instantFeedback === !0 ? "out" : ""}-transition`), _ = u(
|
|
1072
|
+
() => `q-linear-progress__track absolute-full q-linear-progress__track--${f.value} q-linear-progress__track--${a.value === !0 ? "dark" : "light"}` + (e.trackColor !== void 0 ? ` bg-${e.trackColor}` : "")
|
|
1073
|
+
), l = u(() => be(s.value === !0 ? 1 : e.value, r.value, n.$q)), v = u(
|
|
1074
|
+
() => `q-linear-progress__model absolute-full q-linear-progress__model--${f.value} q-linear-progress__model--${s.value === !0 ? "in" : ""}determinate`
|
|
1075
|
+
), m = u(() => ({ width: `${e.value * 100}%` })), g = u(
|
|
1076
|
+
() => `q-linear-progress__stripe absolute-${e.reverse === !0 ? "right" : "left"} q-linear-progress__stripe--${f.value}`
|
|
1077
1077
|
);
|
|
1078
1078
|
return () => {
|
|
1079
|
-
const
|
|
1079
|
+
const d = [
|
|
1080
1080
|
p("div", {
|
|
1081
1081
|
class: _.value,
|
|
1082
1082
|
style: k.value
|
|
1083
1083
|
}),
|
|
1084
1084
|
p("div", {
|
|
1085
|
-
class:
|
|
1086
|
-
style:
|
|
1085
|
+
class: v.value,
|
|
1086
|
+
style: l.value
|
|
1087
1087
|
})
|
|
1088
1088
|
];
|
|
1089
|
-
return e.stripe === !0 &&
|
|
1089
|
+
return e.stripe === !0 && s.value === !1 && d.push(
|
|
1090
1090
|
p("div", {
|
|
1091
|
-
class:
|
|
1092
|
-
style:
|
|
1091
|
+
class: g.value,
|
|
1092
|
+
style: m.value
|
|
1093
1093
|
})
|
|
1094
1094
|
), p("div", {
|
|
1095
1095
|
class: q.value,
|
|
1096
|
-
style:
|
|
1096
|
+
style: i.value,
|
|
1097
1097
|
role: "progressbar",
|
|
1098
1098
|
"aria-valuemin": 0,
|
|
1099
1099
|
"aria-valuemax": 1,
|
|
1100
1100
|
"aria-valuenow": e.indeterminate === !0 ? void 0 : e.value
|
|
1101
|
-
}, N(t.default,
|
|
1101
|
+
}, N(t.default, d));
|
|
1102
1102
|
};
|
|
1103
1103
|
}
|
|
1104
1104
|
}), Dt = {
|
|
1105
1105
|
key: 0,
|
|
1106
1106
|
class: "code-field__label"
|
|
1107
|
-
}, xt = { class: "code-field__inputs" }, jt = ["value", "disabled", "onInput", "onKeydown", "onPaste"], It = /* @__PURE__ */
|
|
1107
|
+
}, xt = { class: "code-field__inputs" }, jt = ["value", "disabled", "onInput", "onKeydown", "onPaste"], It = /* @__PURE__ */ Q({
|
|
1108
1108
|
__name: "AppCodeInput",
|
|
1109
1109
|
props: {
|
|
1110
1110
|
length: { default: 5 },
|
|
@@ -1117,7 +1117,7 @@ const Ot = W({
|
|
|
1117
1117
|
},
|
|
1118
1118
|
emits: ["update:modelValue", "completed"],
|
|
1119
1119
|
setup(e, { emit: t }) {
|
|
1120
|
-
const n = e, a = t, o =
|
|
1120
|
+
const n = e, a = t, o = te(Array(n.length).fill("")), s = De("inputRefs"), r = u(() => [
|
|
1121
1121
|
"code-field",
|
|
1122
1122
|
{
|
|
1123
1123
|
"code-field_sm": n.size === $.SM,
|
|
@@ -1126,84 +1126,88 @@ const Ot = W({
|
|
|
1126
1126
|
"code-field_disabled": n.disabled || n.loading
|
|
1127
1127
|
},
|
|
1128
1128
|
`code-field_${n.color}`
|
|
1129
|
-
]),
|
|
1130
|
-
let
|
|
1131
|
-
return n.size == $.SM && (
|
|
1132
|
-
}),
|
|
1133
|
-
var
|
|
1134
|
-
const
|
|
1135
|
-
if (
|
|
1136
|
-
|
|
1137
|
-
else if (
|
|
1138
|
-
const
|
|
1139
|
-
|
|
1140
|
-
|
|
1129
|
+
]), i = u(() => {
|
|
1130
|
+
let l = "";
|
|
1131
|
+
return n.size == $.SM && (l += `width: ${n.length * 26 + (n.length - 1) * 5}px`), n.size == $.MD && (l += `width: ${n.length * 32 + (n.length - 1) * 8}px`), n.size == $.LG && (l += `width: ${n.length * 44 + (n.length - 1) * 10}px`), l;
|
|
1132
|
+
}), q = (l, v) => {
|
|
1133
|
+
var d;
|
|
1134
|
+
const g = l.target.value;
|
|
1135
|
+
if (g.length === 1)
|
|
1136
|
+
o.value[v] = g, v < n.length - 1 && s.value && ((d = s.value[v + 1]) == null || d.focus());
|
|
1137
|
+
else if (g.length > 1) {
|
|
1138
|
+
const h = g.slice(0, n.length - v).split("");
|
|
1139
|
+
h.forEach((w, M) => {
|
|
1140
|
+
o.value[v + M] = w;
|
|
1141
1141
|
}), ie(() => {
|
|
1142
|
-
var
|
|
1143
|
-
|
|
1142
|
+
var w;
|
|
1143
|
+
s.value && ((w = s.value[Math.min(v + h.length, n.length - 1)]) == null || w.focus());
|
|
1144
1144
|
});
|
|
1145
1145
|
}
|
|
1146
|
-
},
|
|
1147
|
-
var h;
|
|
1148
|
-
d.value[g] === "" && l.value && g > 0 && l.value[g - 1] && ((h = l.value[g - 1]) == null || h.focus());
|
|
1149
|
-
}, _ = (f, g) => {
|
|
1146
|
+
}, k = (l, v) => {
|
|
1150
1147
|
var m;
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1148
|
+
o.value[v] === "" && s.value && v > 0 && s.value[v - 1] && ((m = s.value[v - 1]) == null || m.focus());
|
|
1149
|
+
}, f = (l, v) => {
|
|
1150
|
+
var d;
|
|
1151
|
+
l.preventDefault();
|
|
1152
|
+
const m = ((d = l.clipboardData) == null ? void 0 : d.getData("text")) ?? "";
|
|
1153
|
+
if (!m) return;
|
|
1154
|
+
const g = m.slice(0, n.length - v).split("");
|
|
1155
|
+
g.forEach((h, w) => {
|
|
1156
|
+
o.value[v + w] = h;
|
|
1157
1157
|
}), ie(() => {
|
|
1158
|
-
var
|
|
1159
|
-
|
|
1158
|
+
var h;
|
|
1159
|
+
s.value && ((h = s.value[Math.min(v + g.length, n.length - 1)]) == null || h.focus());
|
|
1160
1160
|
});
|
|
1161
1161
|
};
|
|
1162
|
-
xe(
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1162
|
+
xe(
|
|
1163
|
+
o,
|
|
1164
|
+
(l) => {
|
|
1165
|
+
const v = l.join("");
|
|
1166
|
+
_(v);
|
|
1167
|
+
},
|
|
1168
|
+
{ deep: !0 }
|
|
1169
|
+
);
|
|
1170
|
+
const _ = (l) => {
|
|
1171
|
+
a("update:modelValue", l), l.length === n.length && !l.includes(" ") && a("completed", l);
|
|
1168
1172
|
};
|
|
1169
1173
|
return je(() => {
|
|
1170
|
-
n.autofocus &&
|
|
1171
|
-
}), (
|
|
1172
|
-
class:
|
|
1173
|
-
style: Se(
|
|
1174
|
+
n.autofocus && s.value && s.value[0] && s.value[0].focus();
|
|
1175
|
+
}), (l, v) => (S(), B("div", {
|
|
1176
|
+
class: A(r.value),
|
|
1177
|
+
style: Se(i.value)
|
|
1174
1178
|
}, [
|
|
1175
|
-
|
|
1179
|
+
l.label ? (S(), B("label", Dt, Y(l.label), 1)) : z("", !0),
|
|
1176
1180
|
F("div", xt, [
|
|
1177
|
-
(S(!0),
|
|
1178
|
-
key:
|
|
1179
|
-
value:
|
|
1181
|
+
(S(!0), B(qe, null, Ie(l.length, (m, g) => (S(), B("input", {
|
|
1182
|
+
key: g,
|
|
1183
|
+
value: o.value[g],
|
|
1180
1184
|
ref_for: !0,
|
|
1181
1185
|
ref_key: "inputRefs",
|
|
1182
|
-
ref:
|
|
1186
|
+
ref: s,
|
|
1183
1187
|
type: "text",
|
|
1184
1188
|
maxlength: "1",
|
|
1185
1189
|
class: "code-field__input",
|
|
1186
|
-
disabled:
|
|
1187
|
-
onInput: (
|
|
1188
|
-
onKeydown: Ne((
|
|
1189
|
-
onPaste: (
|
|
1190
|
+
disabled: l.disabled || l.loading,
|
|
1191
|
+
onInput: (d) => q(d, g),
|
|
1192
|
+
onKeydown: Ne((d) => k(d, g), ["backspace"]),
|
|
1193
|
+
onPaste: (d) => f(d, g)
|
|
1190
1194
|
}, null, 40, jt))), 128))
|
|
1191
1195
|
]),
|
|
1192
|
-
|
|
1196
|
+
l.loading ? (S(), _e(Ot, {
|
|
1193
1197
|
key: 1,
|
|
1194
1198
|
indeterminate: "",
|
|
1195
1199
|
rounded: "",
|
|
1196
|
-
color:
|
|
1200
|
+
color: l.color,
|
|
1197
1201
|
class: "code-field__loading"
|
|
1198
|
-
}, null, 8, ["color"])) :
|
|
1202
|
+
}, null, 8, ["color"])) : z("", !0)
|
|
1199
1203
|
], 6));
|
|
1200
1204
|
}
|
|
1201
|
-
}), nn = /* @__PURE__ */ Z(It, [["__scopeId", "data-v-
|
|
1202
|
-
() => import("./AppButtonCopy-
|
|
1205
|
+
}), nn = /* @__PURE__ */ Z(It, [["__scopeId", "data-v-c6ed84b9"]]), an = le(
|
|
1206
|
+
() => import("./AppButtonCopy-CKJG9x84.js")
|
|
1203
1207
|
), ln = le(
|
|
1204
|
-
() => import("./AppSelect-
|
|
1208
|
+
() => import("./AppSelect-CLC9ncKt.js")
|
|
1205
1209
|
), on = le(
|
|
1206
|
-
() => import("./DropdownButton-
|
|
1210
|
+
() => import("./DropdownButton-B1TfiIzK.js")
|
|
1207
1211
|
);
|
|
1208
1212
|
export {
|
|
1209
1213
|
Zt as A,
|