@validol4ik/uikit 0.6.6 → 0.6.7

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.
Files changed (27) hide show
  1. package/dist/{AppButtonCopy-4GxKBcWx.cjs → AppButtonCopy-BvczyeX-.cjs} +1 -1
  2. package/dist/{AppButtonCopy-CcsAzDik.js → AppButtonCopy-CT_lXO96.js} +5 -5
  3. package/dist/{AppSelect-BtUUK2ea.js → AppSelect-B0FVWo0o.js} +893 -900
  4. package/dist/AppSelect-BbPJo5N3.cjs +1 -0
  5. package/dist/DropdownButton-DF_WGSQl.cjs +1 -0
  6. package/dist/{DropdownButton-CZwBMGcA.js → DropdownButton-Ylu19LP3.js} +123 -113
  7. package/dist/QMenu-BAujF7Kn.cjs +1 -0
  8. package/dist/{QMenu-P1hqLpnc.js → QMenu-CrIbSuC4.js} +104 -109
  9. package/dist/index-CDsBnBqp.cjs +1 -0
  10. package/dist/index-DqEqQq1H.js +1265 -0
  11. package/dist/types/components/AppIcon/AppIcon.vue.d.ts +1 -1
  12. package/dist/types/components/buttons/AppButton/AppButton.vue.d.ts +2 -1
  13. package/dist/types/components/buttons/AppButton/types.d.ts +4 -1
  14. package/dist/types/components/buttons/DropdownButton/DropdownButton.vue.d.ts +2 -1
  15. package/dist/types/components/buttons/DropdownButton/types.d.ts +4 -1
  16. package/dist/types/components/form/AppCodeInput/AppCodeInput.vue.d.ts +3 -1
  17. package/dist/types/components/form/AppSelect/AppSelect.vue.d.ts +1 -1
  18. package/dist/types/components/form/AppToggle/AppToggle.vue.d.ts +3 -2
  19. package/dist/types/index.d.ts +1 -1
  20. package/dist/uikit.cjs +1 -1
  21. package/dist/uikit.es.js +1 -1
  22. package/package.json +2 -2
  23. package/dist/AppSelect-Tg7_Uj55.cjs +0 -1
  24. package/dist/DropdownButton-DXQzSYcl.cjs +0 -1
  25. package/dist/QMenu-cWjMyOHy.cjs +0 -1
  26. package/dist/index-CNCrt1w6.cjs +0 -1
  27. package/dist/index-CtoDgaeS.js +0 -1264
@@ -0,0 +1,1265 @@
1
+ import { computed as u, markRaw as $e, defineComponent as U, h, withDirectives as ie, getCurrentInstance as J, unref as Y, ref as X, onBeforeUnmount as Ae, Transition as ze, createBlock as qe, openBlock as B, normalizeClass as A, withCtx as Te, createElementBlock as L, createCommentVNode as z, renderSlot as xe, Fragment as Se, createTextVNode as Oe, toDisplayString as W, createElementVNode as G, normalizeStyle as we, watch as De, onMounted as je, renderList as Ie, withKeys as Ve, vModelText as Ne, nextTick as ce, defineAsyncComponent as re } from "vue";
2
+ const Be = {
3
+ PRIMARY: "primary",
4
+ INFO: "info"
5
+ }, q = {
6
+ SM: "sm",
7
+ MD: "md",
8
+ LG: "lg"
9
+ }, Ke = {
10
+ [q.SM]: "3px 9px",
11
+ [q.MD]: "5px 12px",
12
+ [q.LG]: "9px 20px"
13
+ }, le = {
14
+ xs: 18,
15
+ sm: 24,
16
+ md: 32,
17
+ lg: 38,
18
+ xl: 46
19
+ }, ue = {
20
+ size: String
21
+ };
22
+ function se(e, t = le) {
23
+ return u(() => e.size !== void 0 ? { fontSize: e.size in t ? `${t[e.size]}px` : e.size } : null);
24
+ }
25
+ function Z(e) {
26
+ return $e(U(e));
27
+ }
28
+ function Fe(e) {
29
+ return $e(e);
30
+ }
31
+ function Qe(e, t) {
32
+ return e !== void 0 && e() || t;
33
+ }
34
+ function Kt(e, t) {
35
+ if (e !== void 0) {
36
+ const a = e();
37
+ if (a != null)
38
+ return a.slice();
39
+ }
40
+ return t;
41
+ }
42
+ function N(e, t) {
43
+ return e !== void 0 ? t.concat(e()) : t;
44
+ }
45
+ function Ft(e, t) {
46
+ return e === void 0 ? t : t !== void 0 ? t.concat(e()) : e();
47
+ }
48
+ function Qt(e, t, a, n, l, s) {
49
+ t.key = n + l;
50
+ const o = h(e, t, a);
51
+ return l === !0 ? ie(o, s()) : o;
52
+ }
53
+ const de = "0 0 24 24", ne = (e) => e, ae = (e) => `ionicons ${e}`, Ce = {
54
+ "mdi-": (e) => `mdi ${e}`,
55
+ "icon-": ne,
56
+ // fontawesome equiv
57
+ "bt-": (e) => `bt ${e}`,
58
+ "eva-": (e) => `eva ${e}`,
59
+ "ion-md": ae,
60
+ "ion-ios": ae,
61
+ "ion-logo": ae,
62
+ "iconfont ": ne,
63
+ "ti-": (e) => `themify-icon ${e}`,
64
+ "bi-": (e) => `bootstrap-icons ${e}`,
65
+ "i-": ne
66
+ // UnoCSS pure icons
67
+ }, Le = {
68
+ o_: "-outlined",
69
+ r_: "-round",
70
+ s_: "-sharp"
71
+ }, Ee = {
72
+ sym_o_: "-outlined",
73
+ sym_r_: "-rounded",
74
+ sym_s_: "-sharp"
75
+ }, Ge = new RegExp("^(" + Object.keys(Ce).join("|") + ")"), Ue = new RegExp("^(" + Object.keys(Le).join("|") + ")"), fe = new RegExp("^(" + Object.keys(Ee).join("|") + ")"), He = /^[Mm]\s?[-+]?\.?\d/, Ye = /^img:/, Xe = /^svguse:/, We = /^ion-/, Je = /^(fa-(classic|sharp|solid|regular|light|brands|duotone|thin)|[lf]a[srlbdk]?) /, ve = Z({
76
+ name: "QIcon",
77
+ props: {
78
+ ...ue,
79
+ tag: {
80
+ type: String,
81
+ default: "i"
82
+ },
83
+ name: String,
84
+ color: String,
85
+ left: Boolean,
86
+ right: Boolean
87
+ },
88
+ setup(e, { slots: t }) {
89
+ const { proxy: { $q: a } } = J(), n = se(e), l = u(
90
+ () => "q-icon" + (e.left === !0 ? " on-left" : "") + (e.right === !0 ? " on-right" : "") + (e.color !== void 0 ? ` text-${e.color}` : "")
91
+ ), s = u(() => {
92
+ let o, i = e.name;
93
+ if (i === "none" || !i)
94
+ return { none: !0 };
95
+ if (a.iconMapFn !== null) {
96
+ const f = a.iconMapFn(i);
97
+ if (f !== void 0)
98
+ if (f.icon !== void 0) {
99
+ if (i = f.icon, i === "none" || !i)
100
+ return { none: !0 };
101
+ } else
102
+ return {
103
+ cls: f.cls,
104
+ content: f.content !== void 0 ? f.content : " "
105
+ };
106
+ }
107
+ if (He.test(i) === !0) {
108
+ const [f, k = de] = i.split("|");
109
+ return {
110
+ svg: !0,
111
+ viewBox: k,
112
+ nodes: f.split("&&").map((c) => {
113
+ const [x, d, g] = c.split("@@");
114
+ return h("path", { style: d, d: x, transform: g });
115
+ })
116
+ };
117
+ }
118
+ if (Ye.test(i) === !0)
119
+ return {
120
+ img: !0,
121
+ src: i.substring(4)
122
+ };
123
+ if (Xe.test(i) === !0) {
124
+ const [f, k = de] = i.split("|");
125
+ return {
126
+ svguse: !0,
127
+ src: f.substring(7),
128
+ viewBox: k
129
+ };
130
+ }
131
+ let S = " ";
132
+ const p = i.match(Ge);
133
+ if (p !== null)
134
+ o = Ce[p[1]](i);
135
+ else if (Je.test(i) === !0)
136
+ o = i;
137
+ else if (We.test(i) === !0)
138
+ o = `ionicons ion-${a.platform.is.ios === !0 ? "ios" : "md"}${i.substring(3)}`;
139
+ else if (fe.test(i) === !0) {
140
+ o = "notranslate material-symbols";
141
+ const f = i.match(fe);
142
+ f !== null && (i = i.substring(6), o += Ee[f[1]]), S = i;
143
+ } else {
144
+ o = "notranslate material-icons";
145
+ const f = i.match(Ue);
146
+ f !== null && (i = i.substring(2), o += Le[f[1]]), S = i;
147
+ }
148
+ return {
149
+ cls: o,
150
+ content: S
151
+ };
152
+ });
153
+ return () => {
154
+ const o = {
155
+ class: l.value,
156
+ style: n.value,
157
+ "aria-hidden": "true"
158
+ };
159
+ return s.value.none === !0 ? h(e.tag, o, Qe(t.default)) : s.value.img === !0 ? h(e.tag, o, N(t.default, [
160
+ h("img", { src: s.value.src })
161
+ ])) : s.value.svg === !0 ? h(e.tag, o, N(t.default, [
162
+ h("svg", {
163
+ viewBox: s.value.viewBox || "0 0 24 24"
164
+ }, s.value.nodes)
165
+ ])) : s.value.svguse === !0 ? h(e.tag, o, N(t.default, [
166
+ h("svg", {
167
+ viewBox: s.value.viewBox
168
+ }, [
169
+ h("use", { "xlink:href": s.value.src })
170
+ ])
171
+ ])) : (s.value.cls !== void 0 && (o.class += " " + s.value.cls), h(e.tag, o, N(t.default, [
172
+ s.value.content
173
+ ])));
174
+ };
175
+ }
176
+ }), Ze = {
177
+ size: {
178
+ type: [String, Number],
179
+ default: "1em"
180
+ },
181
+ color: String
182
+ };
183
+ function et(e) {
184
+ return {
185
+ cSize: u(() => e.size in le ? `${le[e.size]}px` : e.size),
186
+ classes: u(
187
+ () => "q-spinner" + (e.color ? ` text-${e.color}` : "")
188
+ )
189
+ };
190
+ }
191
+ const tt = Z({
192
+ name: "QSpinner",
193
+ props: {
194
+ ...Ze,
195
+ thickness: {
196
+ type: Number,
197
+ default: 5
198
+ }
199
+ },
200
+ setup(e) {
201
+ const { cSize: t, classes: a } = et(e);
202
+ return () => h("svg", {
203
+ class: a.value + " q-spinner-mat",
204
+ width: t.value,
205
+ height: t.value,
206
+ viewBox: "25 25 50 50"
207
+ }, [
208
+ h("circle", {
209
+ class: "path",
210
+ cx: "50",
211
+ cy: "50",
212
+ r: "20",
213
+ fill: "none",
214
+ stroke: "currentColor",
215
+ "stroke-width": e.thickness,
216
+ "stroke-miterlimit": "10"
217
+ })
218
+ ]);
219
+ }
220
+ });
221
+ function nt(e, t) {
222
+ const a = e.style;
223
+ for (const n in t)
224
+ a[n] = t[n];
225
+ }
226
+ function Gt(e) {
227
+ if (e == null)
228
+ return;
229
+ if (typeof e == "string")
230
+ try {
231
+ return document.querySelector(e) || void 0;
232
+ } catch {
233
+ return;
234
+ }
235
+ const t = Y(e);
236
+ if (t)
237
+ return t.$el || t;
238
+ }
239
+ function Ut(e, t) {
240
+ if (e == null || e.contains(t) === !0)
241
+ return !0;
242
+ for (let a = e.nextElementSibling; a !== null; a = a.nextElementSibling)
243
+ if (a.contains(t))
244
+ return !0;
245
+ return !1;
246
+ }
247
+ const ee = {
248
+ hasPassive: !1,
249
+ passiveCapture: !0,
250
+ notPassiveCapture: !0
251
+ };
252
+ try {
253
+ const e = Object.defineProperty({}, "passive", {
254
+ get() {
255
+ Object.assign(ee, {
256
+ hasPassive: !0,
257
+ passive: { passive: !0 },
258
+ notPassive: { passive: !1 },
259
+ passiveCapture: { passive: !0, capture: !0 },
260
+ notPassiveCapture: { passive: !1, capture: !0 }
261
+ });
262
+ }
263
+ });
264
+ window.addEventListener("qtest", null, e), window.removeEventListener("qtest", null, e);
265
+ } catch {
266
+ }
267
+ function Ht() {
268
+ }
269
+ function at(e) {
270
+ return e.touches && e.touches[0] ? e = e.touches[0] : e.changedTouches && e.changedTouches[0] ? e = e.changedTouches[0] : e.targetTouches && e.targetTouches[0] && (e = e.targetTouches[0]), {
271
+ top: e.clientY,
272
+ left: e.clientX
273
+ };
274
+ }
275
+ function Yt(e) {
276
+ if (e.path)
277
+ return e.path;
278
+ if (e.composedPath)
279
+ return e.composedPath();
280
+ const t = [];
281
+ let a = e.target;
282
+ for (; a; ) {
283
+ if (t.push(a), a.tagName === "HTML")
284
+ return t.push(document), t.push(window), t;
285
+ a = a.parentElement;
286
+ }
287
+ }
288
+ function _e(e) {
289
+ e.stopPropagation();
290
+ }
291
+ function lt(e) {
292
+ e.cancelable !== !1 && e.preventDefault();
293
+ }
294
+ function D(e) {
295
+ e.cancelable !== !1 && e.preventDefault(), e.stopPropagation();
296
+ }
297
+ function ot(e, t, a) {
298
+ const n = `__q_${t}_evt`;
299
+ e[n] = e[n] !== void 0 ? e[n].concat(a) : a, a.forEach((l) => {
300
+ l[0].addEventListener(l[1], e[l[2]], ee[l[3]]);
301
+ });
302
+ }
303
+ function it(e, t) {
304
+ const a = `__q_${t}_evt`;
305
+ e[a] !== void 0 && (e[a].forEach((n) => {
306
+ n[0].removeEventListener(n[1], e[n[2]], ee[n[3]]);
307
+ }), e[a] = void 0);
308
+ }
309
+ function rt(e) {
310
+ return e !== Object(e) || e.isComposing === !0 || e.qKeyEvent === !0;
311
+ }
312
+ function oe(e, t) {
313
+ return rt(e) === !0 ? !1 : [].concat(t).includes(e.keyCode);
314
+ }
315
+ function ut(e, t = 250) {
316
+ let a = !1, n;
317
+ return function() {
318
+ return a === !1 && (a = !0, setTimeout(() => {
319
+ a = !1;
320
+ }, t), n = e.apply(this, arguments)), n;
321
+ };
322
+ }
323
+ function ge(e, t, a, n) {
324
+ a.modifiers.stop === !0 && _e(e);
325
+ const l = a.modifiers.color;
326
+ let s = a.modifiers.center;
327
+ s = s === !0 || n === !0;
328
+ const o = document.createElement("span"), i = document.createElement("span"), S = at(e), { left: p, top: f, width: k, height: c } = t.getBoundingClientRect(), x = Math.sqrt(k * k + c * c), d = x / 2, g = `${(k - x) / 2}px`, v = s ? g : `${S.left - p - d}px`, m = `${(c - x) / 2}px`, $ = s ? m : `${S.top - f - d}px`;
329
+ i.className = "q-ripple__inner", nt(i, {
330
+ height: `${x}px`,
331
+ width: `${x}px`,
332
+ transform: `translate3d(${v},${$},0) scale3d(.2,.2,1)`,
333
+ opacity: 0
334
+ }), o.className = `q-ripple${l ? " text-" + l : ""}`, o.setAttribute("dir", "ltr"), o.appendChild(i), t.appendChild(o);
335
+ const w = () => {
336
+ o.remove(), clearTimeout(C);
337
+ };
338
+ a.abort.push(w);
339
+ let C = setTimeout(() => {
340
+ i.classList.add("q-ripple__inner--enter"), i.style.transform = `translate3d(${g},${m},0) scale3d(1,1,1)`, i.style.opacity = 0.2, C = setTimeout(() => {
341
+ i.classList.remove("q-ripple__inner--enter"), i.classList.add("q-ripple__inner--leave"), i.style.opacity = 0, C = setTimeout(() => {
342
+ o.remove(), a.abort.splice(a.abort.indexOf(w), 1);
343
+ }, 275);
344
+ }, 250);
345
+ }, 50);
346
+ }
347
+ function me(e, { modifiers: t, value: a, arg: n }) {
348
+ const l = Object.assign({}, e.cfg.ripple, t, a);
349
+ e.modifiers = {
350
+ early: l.early === !0,
351
+ stop: l.stop === !0,
352
+ center: l.center === !0,
353
+ color: l.color || n,
354
+ keyCodes: [].concat(l.keyCodes || 13)
355
+ };
356
+ }
357
+ const st = Fe(
358
+ {
359
+ name: "ripple",
360
+ beforeMount(e, t) {
361
+ const a = t.instance.$.appContext.config.globalProperties.$q.config || {};
362
+ if (a.ripple === !1) return;
363
+ const n = {
364
+ cfg: a,
365
+ enabled: t.value !== !1,
366
+ modifiers: {},
367
+ abort: [],
368
+ start(l) {
369
+ n.enabled === !0 && l.qSkipRipple !== !0 && l.type === (n.modifiers.early === !0 ? "pointerdown" : "click") && ge(l, e, n, l.qKeyEvent === !0);
370
+ },
371
+ keystart: ut((l) => {
372
+ n.enabled === !0 && l.qSkipRipple !== !0 && oe(l, n.modifiers.keyCodes) === !0 && l.type === `key${n.modifiers.early === !0 ? "down" : "up"}` && ge(l, e, n, !0);
373
+ }, 300)
374
+ };
375
+ me(n, t), e.__qripple = n, ot(n, "main", [
376
+ [e, "pointerdown", "start", "passive"],
377
+ [e, "click", "start", "passive"],
378
+ [e, "keydown", "keystart", "passive"],
379
+ [e, "keyup", "keystart", "passive"]
380
+ ]);
381
+ },
382
+ updated(e, t) {
383
+ if (t.oldValue !== t.value) {
384
+ const a = e.__qripple;
385
+ a !== void 0 && (a.enabled = t.value !== !1, a.enabled === !0 && Object(t.value) === t.value && me(a, t));
386
+ }
387
+ },
388
+ beforeUnmount(e) {
389
+ const t = e.__qripple;
390
+ t !== void 0 && (t.abort.forEach((a) => {
391
+ a();
392
+ }), it(t, "main"), delete e._qripple);
393
+ }
394
+ }
395
+ ), Re = {
396
+ left: "start",
397
+ center: "center",
398
+ right: "end",
399
+ between: "between",
400
+ around: "around",
401
+ evenly: "evenly",
402
+ stretch: "stretch"
403
+ }, ct = Object.keys(Re), dt = {
404
+ align: {
405
+ type: String,
406
+ validator: (e) => ct.includes(e)
407
+ }
408
+ };
409
+ function ft(e) {
410
+ return u(() => {
411
+ const t = e.align === void 0 ? e.vertical === !0 ? "stretch" : "left" : e.align;
412
+ return `${e.vertical === !0 ? "items" : "justify"}-${Re[t]}`;
413
+ });
414
+ }
415
+ function Xt(e) {
416
+ if (Object(e.$parent) === e.$parent)
417
+ return e.$parent;
418
+ let { parent: t } = e.$;
419
+ for (; Object(t) === t; ) {
420
+ if (Object(t.proxy) === t.proxy)
421
+ return t.proxy;
422
+ t = t.parent;
423
+ }
424
+ }
425
+ function vt(e) {
426
+ return e.appContext.config.globalProperties.$router !== void 0;
427
+ }
428
+ function Wt(e) {
429
+ return e.isUnmounted === !0 || e.isDeactivated === !0;
430
+ }
431
+ function he(e) {
432
+ return e ? e.aliasOf ? e.aliasOf.path : e.path : "";
433
+ }
434
+ function be(e, t) {
435
+ return (e.aliasOf || e) === (t.aliasOf || t);
436
+ }
437
+ function gt(e, t) {
438
+ for (const a in t) {
439
+ const n = t[a], l = e[a];
440
+ if (typeof n == "string") {
441
+ if (n !== l)
442
+ return !1;
443
+ } else if (Array.isArray(l) === !1 || l.length !== n.length || n.some((s, o) => s !== l[o]))
444
+ return !1;
445
+ }
446
+ return !0;
447
+ }
448
+ function ye(e, t) {
449
+ return Array.isArray(t) === !0 ? e.length === t.length && e.every((a, n) => a === t[n]) : e.length === 1 && e[0] === t;
450
+ }
451
+ function mt(e, t) {
452
+ return Array.isArray(e) === !0 ? ye(e, t) : Array.isArray(t) === !0 ? ye(t, e) : e === t;
453
+ }
454
+ function ht(e, t) {
455
+ if (Object.keys(e).length !== Object.keys(t).length)
456
+ return !1;
457
+ for (const a in e)
458
+ if (mt(e[a], t[a]) === !1)
459
+ return !1;
460
+ return !0;
461
+ }
462
+ const Me = {
463
+ // router-link
464
+ to: [String, Object],
465
+ replace: Boolean,
466
+ // regular <a> link
467
+ href: String,
468
+ target: String,
469
+ // state
470
+ disable: Boolean
471
+ }, Jt = {
472
+ ...Me,
473
+ // router-link
474
+ exact: Boolean,
475
+ activeClass: {
476
+ type: String,
477
+ default: "q-router-link--active"
478
+ },
479
+ exactActiveClass: {
480
+ type: String,
481
+ default: "q-router-link--exact-active"
482
+ }
483
+ };
484
+ function bt({ fallbackTag: e, useDisableForRouterLinkProps: t = !0 } = {}) {
485
+ const a = J(), { props: n, proxy: l, emit: s } = a, o = vt(a), i = u(() => n.disable !== !0 && n.href !== void 0), S = t === !0 ? u(
486
+ () => o === !0 && n.disable !== !0 && i.value !== !0 && n.to !== void 0 && n.to !== null && n.to !== ""
487
+ ) : u(
488
+ () => o === !0 && i.value !== !0 && n.to !== void 0 && n.to !== null && n.to !== ""
489
+ ), p = u(() => S.value === !0 ? $(n.to) : null), f = u(() => p.value !== null), k = u(() => i.value === !0 || f.value === !0), c = u(() => n.type === "a" || k.value === !0 ? "a" : n.tag || e || "div"), x = u(() => i.value === !0 ? {
490
+ href: n.href,
491
+ target: n.target
492
+ } : f.value === !0 ? {
493
+ href: p.value.href,
494
+ target: n.target
495
+ } : {}), d = u(() => {
496
+ if (f.value === !1)
497
+ return -1;
498
+ const { matched: b } = p.value, { length: E } = b, R = b[E - 1];
499
+ if (R === void 0)
500
+ return -1;
501
+ const P = l.$route.matched;
502
+ if (P.length === 0)
503
+ return -1;
504
+ const T = P.findIndex(
505
+ be.bind(null, R)
506
+ );
507
+ if (T !== -1)
508
+ return T;
509
+ const H = he(b[E - 2]);
510
+ return (
511
+ // we are dealing with nested routes
512
+ E > 1 && he(R) === H && P[P.length - 1].path !== H ? P.findIndex(
513
+ be.bind(null, b[E - 2])
514
+ ) : T
515
+ );
516
+ }), g = u(
517
+ () => f.value === !0 && d.value !== -1 && gt(l.$route.params, p.value.params)
518
+ ), v = u(
519
+ () => g.value === !0 && d.value === l.$route.matched.length - 1 && ht(l.$route.params, p.value.params)
520
+ ), m = u(() => f.value === !0 ? v.value === !0 ? ` ${n.exactActiveClass} ${n.activeClass}` : n.exact === !0 ? "" : g.value === !0 ? ` ${n.activeClass}` : "" : "");
521
+ function $(b) {
522
+ try {
523
+ return l.$router.resolve(b);
524
+ } catch {
525
+ }
526
+ return null;
527
+ }
528
+ function w(b, { returnRouterError: E, to: R = n.to, replace: P = n.replace } = {}) {
529
+ if (n.disable === !0)
530
+ return b.preventDefault(), Promise.resolve(!1);
531
+ if (
532
+ // don't redirect with control keys;
533
+ // should match RouterLink from Vue Router
534
+ b.metaKey || b.altKey || b.ctrlKey || b.shiftKey || b.button !== void 0 && b.button !== 0 || n.target === "_blank"
535
+ )
536
+ return Promise.resolve(!1);
537
+ b.preventDefault();
538
+ const T = l.$router[P === !0 ? "replace" : "push"](R);
539
+ return E === !0 ? T : T.then(() => {
540
+ }).catch(() => {
541
+ });
542
+ }
543
+ function C(b) {
544
+ if (f.value === !0) {
545
+ const E = (R) => w(b, R);
546
+ s("click", b, E), b.defaultPrevented !== !0 && E();
547
+ } else
548
+ s("click", b);
549
+ }
550
+ return {
551
+ hasRouterLink: f,
552
+ hasHrefLink: i,
553
+ hasLink: k,
554
+ linkTag: c,
555
+ resolvedLink: p,
556
+ linkIsActive: g,
557
+ linkIsExactActive: v,
558
+ linkClass: m,
559
+ linkAttrs: x,
560
+ getLink: $,
561
+ navigateToRouterLink: w,
562
+ navigateOnClick: C
563
+ };
564
+ }
565
+ const pe = {
566
+ none: 0,
567
+ xs: 4,
568
+ sm: 8,
569
+ md: 16,
570
+ lg: 24,
571
+ xl: 32
572
+ }, yt = {
573
+ xs: 8,
574
+ sm: 10,
575
+ md: 14,
576
+ lg: 20,
577
+ xl: 24
578
+ }, pt = ["button", "submit", "reset"], kt = /[^\s]\/[^\s]/, $t = ["flat", "outline", "push", "unelevated"];
579
+ function Pe(e, t) {
580
+ return e.flat === !0 ? "flat" : e.outline === !0 ? "outline" : e.push === !0 ? "push" : e.unelevated === !0 ? "unelevated" : t;
581
+ }
582
+ function Zt(e) {
583
+ const t = Pe(e);
584
+ return t !== void 0 ? { [t]: !0 } : {};
585
+ }
586
+ const qt = {
587
+ ...ue,
588
+ ...Me,
589
+ type: {
590
+ type: String,
591
+ default: "button"
592
+ },
593
+ label: [Number, String],
594
+ icon: String,
595
+ iconRight: String,
596
+ ...$t.reduce(
597
+ (e, t) => (e[t] = Boolean) && e,
598
+ {}
599
+ ),
600
+ square: Boolean,
601
+ rounded: Boolean,
602
+ glossy: Boolean,
603
+ size: String,
604
+ fab: Boolean,
605
+ fabMini: Boolean,
606
+ padding: String,
607
+ color: String,
608
+ textColor: String,
609
+ noCaps: Boolean,
610
+ noWrap: Boolean,
611
+ dense: Boolean,
612
+ tabindex: [Number, String],
613
+ ripple: {
614
+ type: [Boolean, Object],
615
+ default: !0
616
+ },
617
+ align: {
618
+ ...dt.align,
619
+ default: "center"
620
+ },
621
+ stack: Boolean,
622
+ stretch: Boolean,
623
+ loading: {
624
+ type: Boolean,
625
+ default: null
626
+ },
627
+ disable: Boolean
628
+ }, xt = {
629
+ ...qt,
630
+ round: Boolean
631
+ };
632
+ function St(e) {
633
+ const t = se(e, yt), a = ft(e), { hasRouterLink: n, hasLink: l, linkTag: s, linkAttrs: o, navigateOnClick: i } = bt({
634
+ fallbackTag: "button"
635
+ }), S = u(() => {
636
+ const v = e.fab === !1 && e.fabMini === !1 ? t.value : {};
637
+ return e.padding !== void 0 ? Object.assign({}, v, {
638
+ padding: e.padding.split(/\s+/).map((m) => m in pe ? pe[m] + "px" : m).join(" "),
639
+ minWidth: "0",
640
+ minHeight: "0"
641
+ }) : v;
642
+ }), p = u(
643
+ () => e.rounded === !0 || e.fab === !0 || e.fabMini === !0
644
+ ), f = u(
645
+ () => e.disable !== !0 && e.loading !== !0
646
+ ), k = u(() => f.value === !0 ? e.tabindex || 0 : -1), c = u(() => Pe(e, "standard")), x = u(() => {
647
+ const v = { tabindex: k.value };
648
+ return l.value === !0 ? Object.assign(v, o.value) : pt.includes(e.type) === !0 && (v.type = e.type), s.value === "a" ? (e.disable === !0 ? v["aria-disabled"] = "true" : v.href === void 0 && (v.role = "button"), n.value !== !0 && kt.test(e.type) === !0 && (v.type = e.type)) : e.disable === !0 && (v.disabled = "", v["aria-disabled"] = "true"), e.loading === !0 && e.percentage !== void 0 && Object.assign(v, {
649
+ role: "progressbar",
650
+ "aria-valuemin": 0,
651
+ "aria-valuemax": 100,
652
+ "aria-valuenow": e.percentage
653
+ }), v;
654
+ }), d = u(() => {
655
+ let v;
656
+ e.color !== void 0 ? e.flat === !0 || e.outline === !0 ? v = `text-${e.textColor || e.color}` : v = `bg-${e.color} text-${e.textColor || "white"}` : e.textColor && (v = `text-${e.textColor}`);
657
+ const m = e.round === !0 ? "round" : `rectangle${p.value === !0 ? " q-btn--rounded" : e.square === !0 ? " q-btn--square" : ""}`;
658
+ return `q-btn--${c.value} q-btn--${m}` + (v !== void 0 ? " " + v : "") + (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
+ () => a.value + (e.stack === !0 ? " column" : " row") + (e.noWrap === !0 ? " no-wrap text-no-wrap" : "") + (e.loading === !0 ? " q-btn__content--hidden" : "")
661
+ );
662
+ return {
663
+ classes: d,
664
+ style: S,
665
+ innerClasses: g,
666
+ attributes: x,
667
+ hasLink: l,
668
+ linkTag: s,
669
+ navigateOnClick: i,
670
+ isActionable: f
671
+ };
672
+ }
673
+ const { passiveCapture: _ } = ee;
674
+ let j = null, I = null, V = null;
675
+ const wt = Z({
676
+ name: "QBtn",
677
+ props: {
678
+ ...xt,
679
+ percentage: Number,
680
+ darkPercentage: Boolean,
681
+ onTouchstart: [Function, Array]
682
+ },
683
+ emits: ["click", "keydown", "mousedown", "keyup"],
684
+ setup(e, { slots: t, emit: a }) {
685
+ const { proxy: n } = J(), {
686
+ classes: l,
687
+ style: s,
688
+ innerClasses: o,
689
+ attributes: i,
690
+ hasLink: S,
691
+ linkTag: p,
692
+ navigateOnClick: f,
693
+ isActionable: k
694
+ } = St(e), c = X(null), x = X(null);
695
+ let d = null, g, v = null;
696
+ const m = u(
697
+ () => e.label !== void 0 && e.label !== null && e.label !== ""
698
+ ), $ = u(() => e.disable === !0 || e.ripple === !1 ? !1 : {
699
+ keyCodes: S.value === !0 ? [13, 32] : [13],
700
+ ...e.ripple === !0 ? {} : e.ripple
701
+ }), w = u(() => ({ center: e.round })), C = u(() => {
702
+ const r = Math.max(0, Math.min(100, e.percentage));
703
+ return r > 0 ? { transition: "transform 0.6s", transform: `translateX(${r - 100}%)` } : {};
704
+ }), b = u(() => {
705
+ if (e.loading === !0)
706
+ return {
707
+ onMousedown: F,
708
+ onTouchstart: F,
709
+ onClick: F,
710
+ onKeydown: F,
711
+ onKeyup: F
712
+ };
713
+ if (k.value === !0) {
714
+ const r = {
715
+ onClick: R,
716
+ onKeydown: P,
717
+ onMousedown: H
718
+ };
719
+ if (n.$q.platform.has.touch === !0) {
720
+ const y = e.onTouchstart !== void 0 ? "" : "Passive";
721
+ r[`onTouchstart${y}`] = T;
722
+ }
723
+ return r;
724
+ }
725
+ return {
726
+ // needed; especially for disabled <a> tags
727
+ onClick: D
728
+ };
729
+ }), E = u(() => ({
730
+ ref: c,
731
+ class: "q-btn q-btn-item non-selectable no-outline " + l.value,
732
+ style: s.value,
733
+ ...i.value,
734
+ ...b.value
735
+ }));
736
+ function R(r) {
737
+ if (c.value !== null) {
738
+ if (r !== void 0) {
739
+ if (r.defaultPrevented === !0) return;
740
+ const y = document.activeElement;
741
+ if (e.type === "submit" && y !== document.body && c.value.contains(y) === !1 && y.contains(c.value) === !1) {
742
+ r.qAvoidFocus !== !0 && c.value.focus();
743
+ const O = () => {
744
+ var Q;
745
+ document.removeEventListener("keydown", D, !0), document.removeEventListener("keyup", O, _), (Q = c.value) == null || Q.removeEventListener("blur", O, _);
746
+ };
747
+ document.addEventListener("keydown", D, !0), document.addEventListener("keyup", O, _), c.value.addEventListener("blur", O, _);
748
+ }
749
+ }
750
+ f(r);
751
+ }
752
+ }
753
+ function P(r) {
754
+ c.value !== null && (a("keydown", r), oe(r, [13, 32]) === !0 && I !== c.value && (I !== null && K(), r.defaultPrevented !== !0 && (r.qAvoidFocus !== !0 && c.value.focus(), I = c.value, c.value.classList.add("q-btn--active"), document.addEventListener("keyup", M, !0), c.value.addEventListener("blur", M, _)), D(r)));
755
+ }
756
+ function T(r) {
757
+ c.value !== null && (a("touchstart", r), r.defaultPrevented !== !0 && (j !== c.value && (j !== null && K(), j = c.value, d = r.target, d.addEventListener("touchcancel", M, _), d.addEventListener("touchend", M, _)), g = !0, v !== null && clearTimeout(v), v = setTimeout(() => {
758
+ v = null, g = !1;
759
+ }, 200)));
760
+ }
761
+ function H(r) {
762
+ c.value !== null && (r.qSkipRipple = g === !0, a("mousedown", r), r.defaultPrevented !== !0 && V !== c.value && (V !== null && K(), V = c.value, c.value.classList.add("q-btn--active"), document.addEventListener("mouseup", M, _)));
763
+ }
764
+ function M(r) {
765
+ if (c.value !== null && !((r == null ? void 0 : r.type) === "blur" && document.activeElement === c.value)) {
766
+ if ((r == null ? void 0 : r.type) === "keyup") {
767
+ if (I === c.value && oe(r, [13, 32]) === !0) {
768
+ const y = new MouseEvent("click", r);
769
+ y.qKeyEvent = !0, r.defaultPrevented === !0 && lt(y), r.cancelBubble === !0 && _e(y), c.value.dispatchEvent(y), D(r), r.qKeyEvent = !0;
770
+ }
771
+ a("keyup", r);
772
+ }
773
+ K();
774
+ }
775
+ }
776
+ function K(r) {
777
+ var O, Q;
778
+ const y = x.value;
779
+ r !== !0 && (j === c.value || V === c.value) && y !== null && y !== document.activeElement && (y.setAttribute("tabindex", -1), y.focus()), j === c.value && (d !== null && (d.removeEventListener("touchcancel", M, _), d.removeEventListener("touchend", M, _)), j = d = null), V === c.value && (document.removeEventListener("mouseup", M, _), V = null), I === c.value && (document.removeEventListener("keyup", M, !0), (O = c.value) == null || O.removeEventListener("blur", M, _), I = null), (Q = c.value) == null || Q.classList.remove("q-btn--active");
780
+ }
781
+ function F(r) {
782
+ D(r), r.qSkipRipple = !0;
783
+ }
784
+ return Ae(() => {
785
+ K(!0);
786
+ }), Object.assign(n, {
787
+ click: (r) => {
788
+ k.value === !0 && R(r);
789
+ }
790
+ }), () => {
791
+ let r = [];
792
+ e.icon !== void 0 && r.push(
793
+ h(ve, {
794
+ name: e.icon,
795
+ left: e.stack !== !0 && m.value === !0,
796
+ role: "img"
797
+ })
798
+ ), m.value === !0 && r.push(
799
+ h("span", { class: "block" }, [e.label])
800
+ ), r = N(t.default, r), e.iconRight !== void 0 && e.round === !1 && r.push(
801
+ h(ve, {
802
+ name: e.iconRight,
803
+ right: e.stack !== !0 && m.value === !0,
804
+ role: "img"
805
+ })
806
+ );
807
+ const y = [
808
+ h("span", {
809
+ class: "q-focus-helper",
810
+ ref: x
811
+ })
812
+ ];
813
+ return e.loading === !0 && e.percentage !== void 0 && y.push(
814
+ h("span", {
815
+ class: "q-btn__progress absolute-full overflow-hidden" + (e.darkPercentage === !0 ? " q-btn__progress--dark" : "")
816
+ }, [
817
+ h("span", {
818
+ class: "q-btn__progress-indicator fit block",
819
+ style: C.value
820
+ })
821
+ ])
822
+ ), y.push(
823
+ h("span", {
824
+ class: "q-btn__content text-center col items-center q-anchor--skip " + o.value
825
+ }, r)
826
+ ), e.loading !== null && y.push(
827
+ h(ze, {
828
+ name: "q-transition--fade"
829
+ }, () => e.loading === !0 ? [
830
+ h("span", {
831
+ key: "loading",
832
+ class: "absolute-full flex flex-center"
833
+ }, t.loading !== void 0 ? t.loading() : [h(tt)])
834
+ ] : null)
835
+ ), ie(
836
+ h(
837
+ p.value,
838
+ E.value,
839
+ y
840
+ ),
841
+ [[
842
+ st,
843
+ $.value,
844
+ void 0,
845
+ w.value
846
+ ]]
847
+ );
848
+ };
849
+ }
850
+ }), Bt = /* @__PURE__ */ U({
851
+ __name: "AppButton",
852
+ props: {
853
+ size: { default: q.MD },
854
+ transparent: { type: Boolean },
855
+ flat: { type: Boolean },
856
+ rounded: { type: Boolean },
857
+ color: { default: Be.PRIMARY },
858
+ iconLeft: {},
859
+ iconRight: {},
860
+ iconMiddle: {},
861
+ disabled: { type: Boolean },
862
+ loading: { type: Boolean },
863
+ to: {},
864
+ href: {},
865
+ target: {},
866
+ submit: { type: Boolean },
867
+ ariaLabel: {},
868
+ label: {},
869
+ download: {}
870
+ },
871
+ emits: ["click"],
872
+ setup(e) {
873
+ const t = e, a = u(() => [
874
+ "app-btn",
875
+ {
876
+ "app-btn_default": !t.transparent && !t.flat,
877
+ "app-btn_trans": t.transparent,
878
+ "app-btn_flat": t.flat,
879
+ "app-btn_rounded": t.rounded,
880
+ "app-btn_sm": t.size === q.SM,
881
+ "app-btn_md": t.size === q.MD,
882
+ "app-btn_lg": t.size === q.LG,
883
+ "app-btn_icon-left": t.iconLeft,
884
+ "app-btn_icon-right": t.iconRight,
885
+ "app-btn_icon-middle": t.iconMiddle
886
+ },
887
+ `app-btn_${t.color}`
888
+ ]);
889
+ return (n, l) => (B(), qe(Y(wt), {
890
+ "no-caps": "",
891
+ unelevated: "",
892
+ class: A(a.value),
893
+ padding: Y(Ke)[e.size || Y(q).MD],
894
+ loading: e.loading,
895
+ disable: e.disabled || void 0,
896
+ to: e.to,
897
+ href: e.href,
898
+ target: e.target,
899
+ type: e.submit ? "submit" : void 0,
900
+ "aria-label": e.ariaLabel,
901
+ download: e.download,
902
+ onClick: l[0] || (l[0] = (s) => n.$emit("click", s))
903
+ }, {
904
+ default: Te(() => [
905
+ e.iconLeft || e.iconMiddle ? (B(), L("i", {
906
+ key: 0,
907
+ class: A([
908
+ "icon-kl",
909
+ e.iconLeft ? "icon-kl_left" : "icon-kl_middle",
910
+ `icon-kl-${e.iconLeft || e.iconMiddle}`,
911
+ e.transparent || e.flat ? `text-${e.color}` : "text-secondary"
912
+ ])
913
+ }, null, 2)) : z("", !0),
914
+ xe(n.$slots, "default", {}, void 0, !0),
915
+ e.label ? (B(), L(Se, { key: 1 }, [
916
+ Oe(W(e.label), 1)
917
+ ], 64)) : z("", !0),
918
+ e.iconRight ? (B(), L("i", {
919
+ key: 2,
920
+ class: A([
921
+ "icon-kl",
922
+ "icon-kl_right",
923
+ `icon-kl-${e.iconRight}`,
924
+ e.transparent ? `text-${e.color}` : "text-secondary"
925
+ ])
926
+ }, null, 2)) : z("", !0)
927
+ ]),
928
+ _: 3
929
+ }, 8, ["class", "padding", "loading", "disable", "to", "href", "target", "type", "aria-label", "download"]));
930
+ }
931
+ }), te = (e, t) => {
932
+ const a = e.__vccOpts || e;
933
+ for (const [n, l] of t)
934
+ a[n] = l;
935
+ return a;
936
+ }, en = /* @__PURE__ */ te(Bt, [["__scopeId", "data-v-99788ad1"]]), Ct = {
937
+ key: 0,
938
+ class: "app-toggle__label app-toggle__label_left"
939
+ }, Lt = { class: "app-toggle__container" }, Et = ["checked", "disabled"], _t = { class: "app-toggle__thumb" }, Rt = {
940
+ key: 1,
941
+ class: "app-toggle__label"
942
+ }, Mt = /* @__PURE__ */ U({
943
+ __name: "AppToggle",
944
+ props: {
945
+ modelValue: { type: Boolean },
946
+ size: { default: q.MD },
947
+ label: {},
948
+ disabled: { type: Boolean },
949
+ color: { default: Be.PRIMARY },
950
+ iconColor: {},
951
+ icon: {},
952
+ iconActive: {},
953
+ labelLeft: { type: Boolean }
954
+ },
955
+ emits: ["update:modelValue"],
956
+ setup(e, { emit: t }) {
957
+ const a = e, n = t, l = u({
958
+ get: () => a.modelValue,
959
+ set: (o) => {
960
+ n("update:modelValue", o);
961
+ }
962
+ }), s = u(() => [
963
+ "app-toggle",
964
+ {
965
+ "app-toggle_sm": a.size === q.SM,
966
+ "app-toggle_md": a.size === q.MD,
967
+ "app-toggle_lg": a.size === q.LG,
968
+ "app-toggle_active": l.value,
969
+ "app-toggle_disabled": a.disabled
970
+ },
971
+ `app-toggle_${a.color}`
972
+ ]);
973
+ return (o, i) => (B(), L("div", {
974
+ class: A(s.value)
975
+ }, [
976
+ e.label && e.labelLeft ? (B(), L("span", Ct, W(e.label), 1)) : z("", !0),
977
+ G("label", Lt, [
978
+ G("input", {
979
+ type: "checkbox",
980
+ checked: l.value,
981
+ onChange: i[0] || (i[0] = (S) => l.value = !l.value),
982
+ disabled: e.disabled,
983
+ class: "app-toggle__input"
984
+ }, null, 40, Et),
985
+ G("span", {
986
+ class: A(["app-toggle__slider", l.value ? `bg-${e.color}` : ""])
987
+ }, [
988
+ G("span", _t, [
989
+ e.icon && !e.modelValue ? (B(), L("i", {
990
+ key: 0,
991
+ class: A(["icon-kl", `icon-kl-${e.icon}`, "app-toggle__icon"])
992
+ }, null, 2)) : z("", !0),
993
+ e.modelValue && (e.iconActive || e.icon) ? (B(), L("i", {
994
+ key: 1,
995
+ class: A([
996
+ "icon-kl",
997
+ `icon-kl-${e.iconActive || e.icon}`,
998
+ "app-toggle__icon",
999
+ l.value ? `text-${e.iconColor}` : ""
1000
+ ])
1001
+ }, null, 2)) : z("", !0)
1002
+ ])
1003
+ ], 2),
1004
+ xe(o.$slots, "default", {}, void 0, !0)
1005
+ ]),
1006
+ e.label && !e.labelLeft ? (B(), L("span", Rt, W(e.label), 1)) : z("", !0)
1007
+ ], 2));
1008
+ }
1009
+ }), tn = /* @__PURE__ */ te(Mt, [["__scopeId", "data-v-e0e56123"]]), Pt = /* @__PURE__ */ U({
1010
+ __name: "AppIcon",
1011
+ props: {
1012
+ name: {},
1013
+ size: {},
1014
+ color: {}
1015
+ },
1016
+ setup(e) {
1017
+ return (t, a) => (B(), L("i", {
1018
+ class: A(["icon-kl", `icon-kl-${e.name}`, e.color ? `text-${e.color}` : ""]),
1019
+ style: we(e.size ? `font-size: ${e.size}` : void 0)
1020
+ }, null, 6));
1021
+ }
1022
+ }), nn = /* @__PURE__ */ te(Pt, [["__scopeId", "data-v-941765ee"]]), At = {
1023
+ dark: {
1024
+ type: Boolean,
1025
+ default: null
1026
+ }
1027
+ };
1028
+ function zt(e, t) {
1029
+ return u(() => e.dark === null ? t.dark.isActive : e.dark);
1030
+ }
1031
+ const Tt = {
1032
+ xs: 2,
1033
+ sm: 4,
1034
+ md: 6,
1035
+ lg: 10,
1036
+ xl: 14
1037
+ };
1038
+ function ke(e, t, a) {
1039
+ return {
1040
+ transform: t === !0 ? `translateX(${a.lang.rtl === !0 ? "-" : ""}100%) scale3d(${-e},1,1)` : `scale3d(${e},1,1)`
1041
+ };
1042
+ }
1043
+ const Ot = Z({
1044
+ name: "QLinearProgress",
1045
+ props: {
1046
+ ...At,
1047
+ ...ue,
1048
+ value: {
1049
+ type: Number,
1050
+ default: 0
1051
+ },
1052
+ buffer: Number,
1053
+ color: String,
1054
+ trackColor: String,
1055
+ reverse: Boolean,
1056
+ stripe: Boolean,
1057
+ indeterminate: Boolean,
1058
+ query: Boolean,
1059
+ rounded: Boolean,
1060
+ animationSpeed: {
1061
+ type: [String, Number],
1062
+ default: 2100
1063
+ },
1064
+ instantFeedback: Boolean
1065
+ },
1066
+ setup(e, { slots: t }) {
1067
+ const { proxy: a } = J(), n = zt(e, a.$q), l = se(e, Tt), s = u(() => e.indeterminate === !0 || e.query === !0), o = u(() => e.reverse !== e.query), i = u(() => ({
1068
+ ...l.value !== null ? l.value : {},
1069
+ "--q-linear-progress-speed": `${e.animationSpeed}ms`
1070
+ })), S = u(
1071
+ () => "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" : "")
1072
+ ), p = u(() => ke(e.buffer !== void 0 ? e.buffer : 1, o.value, a.$q)), f = u(() => `with${e.instantFeedback === !0 ? "out" : ""}-transition`), k = u(
1073
+ () => `q-linear-progress__track absolute-full q-linear-progress__track--${f.value} q-linear-progress__track--${n.value === !0 ? "dark" : "light"}` + (e.trackColor !== void 0 ? ` bg-${e.trackColor}` : "")
1074
+ ), c = u(() => ke(s.value === !0 ? 1 : e.value, o.value, a.$q)), x = u(
1075
+ () => `q-linear-progress__model absolute-full q-linear-progress__model--${f.value} q-linear-progress__model--${s.value === !0 ? "in" : ""}determinate`
1076
+ ), d = u(() => ({ width: `${e.value * 100}%` })), g = u(
1077
+ () => `q-linear-progress__stripe absolute-${e.reverse === !0 ? "right" : "left"} q-linear-progress__stripe--${f.value}`
1078
+ );
1079
+ return () => {
1080
+ const v = [
1081
+ h("div", {
1082
+ class: k.value,
1083
+ style: p.value
1084
+ }),
1085
+ h("div", {
1086
+ class: x.value,
1087
+ style: c.value
1088
+ })
1089
+ ];
1090
+ return e.stripe === !0 && s.value === !1 && v.push(
1091
+ h("div", {
1092
+ class: g.value,
1093
+ style: d.value
1094
+ })
1095
+ ), h("div", {
1096
+ class: S.value,
1097
+ style: i.value,
1098
+ role: "progressbar",
1099
+ "aria-valuemin": 0,
1100
+ "aria-valuemax": 1,
1101
+ "aria-valuenow": e.indeterminate === !0 ? void 0 : e.value
1102
+ }, N(t.default, v));
1103
+ };
1104
+ }
1105
+ }), Dt = {
1106
+ key: 0,
1107
+ class: "code-field__label"
1108
+ }, jt = { class: "code-field__inputs" }, It = ["onUpdate:modelValue", "disabled", "onInput", "onKeydown", "onPaste"], Vt = /* @__PURE__ */ U({
1109
+ __name: "AppCodeInput",
1110
+ props: {
1111
+ length: { default: 5 },
1112
+ size: { default: q.MD },
1113
+ label: {},
1114
+ disabled: { type: Boolean },
1115
+ loading: { type: Boolean },
1116
+ autofocus: { type: Boolean },
1117
+ color: {}
1118
+ },
1119
+ emits: ["update:modelValue", "completed"],
1120
+ setup(e, { expose: t, emit: a }) {
1121
+ const n = e, l = a, s = X(Array(n.length).fill("")), o = X([]), i = u(() => [
1122
+ "code-field",
1123
+ {
1124
+ "code-field_sm": n.size === q.SM,
1125
+ "code-field_md": n.size === q.MD,
1126
+ "code-field_lg": n.size === q.LG,
1127
+ "code-field_disabled": n.disabled || n.loading
1128
+ },
1129
+ `code-field_${n.color}`
1130
+ ]), S = u(() => {
1131
+ let d = "";
1132
+ return n.size == q.SM && (d += `width: ${n.length * 26 + (n.length - 1) * 5}px`), n.size == q.MD && (d += `width: ${n.length * 32 + (n.length - 1) * 8}px`), n.size == q.LG && (d += `width: ${n.length * 44 + (n.length - 1) * 10}px`), d;
1133
+ }), p = (d, g) => {
1134
+ var $;
1135
+ const m = d.target.value;
1136
+ if (m.length === 1)
1137
+ g < n.length - 1 && o.value && (($ = o.value[g + 1]) == null || $.focus());
1138
+ else if (m.length > 1) {
1139
+ const w = m.slice(0, n.length - g).split("");
1140
+ w.forEach((C, b) => {
1141
+ s.value[g + b] = C;
1142
+ }), ce(() => {
1143
+ var C;
1144
+ o.value && ((C = o.value[Math.min(g + w.length, n.length - 1)]) == null || C.focus());
1145
+ });
1146
+ }
1147
+ }, f = (d) => {
1148
+ var g;
1149
+ s.value[d] === "" && o.value && d > 0 && ((g = o.value[d - 1]) == null || g.focus());
1150
+ }, k = (d, g) => {
1151
+ var $;
1152
+ d.preventDefault();
1153
+ const v = (($ = d.clipboardData) == null ? void 0 : $.getData("text")) ?? "";
1154
+ if (!v) return;
1155
+ const m = v.slice(0, n.length - g).split("");
1156
+ m.forEach((w, C) => {
1157
+ s.value[g + C] = w;
1158
+ }), ce(() => {
1159
+ var w;
1160
+ o.value && ((w = o.value[Math.min(g + m.length, n.length - 1)]) == null || w.focus());
1161
+ });
1162
+ };
1163
+ De(
1164
+ s,
1165
+ (d) => {
1166
+ const g = d.join("");
1167
+ c(g);
1168
+ },
1169
+ { deep: !0 }
1170
+ );
1171
+ const c = (d) => {
1172
+ l("update:modelValue", d), d.length === n.length && !d.includes(" ") && l("completed", d);
1173
+ }, x = (d) => {
1174
+ d && (s.value = d.split("").slice(0, n.length));
1175
+ };
1176
+ return je(() => {
1177
+ n.autofocus && o.value && o.value[0] && o.value[0].focus();
1178
+ }), t({
1179
+ injectCode: x
1180
+ }), (d, g) => (B(), L("div", {
1181
+ class: A(i.value),
1182
+ style: we(S.value)
1183
+ }, [
1184
+ e.label ? (B(), L("label", Dt, W(e.label), 1)) : z("", !0),
1185
+ G("div", jt, [
1186
+ (B(!0), L(Se, null, Ie(e.length, (v, m) => ie((B(), L("input", {
1187
+ key: m,
1188
+ "onUpdate:modelValue": ($) => s.value[m] = $,
1189
+ ref_for: !0,
1190
+ ref_key: "inputRefs",
1191
+ ref: o,
1192
+ type: "text",
1193
+ maxlength: "1",
1194
+ class: "code-field__input",
1195
+ disabled: e.disabled || e.loading,
1196
+ onInput: ($) => p($, m),
1197
+ onKeydown: Ve(($) => f(m), ["backspace"]),
1198
+ onPaste: ($) => k($, m)
1199
+ }, null, 40, It)), [
1200
+ [Ne, s.value[m]]
1201
+ ])), 128))
1202
+ ]),
1203
+ e.loading ? (B(), qe(Ot, {
1204
+ key: 1,
1205
+ indeterminate: "",
1206
+ rounded: "",
1207
+ color: e.color,
1208
+ class: "code-field__loading"
1209
+ }, null, 8, ["color"])) : z("", !0)
1210
+ ], 6));
1211
+ }
1212
+ }), an = /* @__PURE__ */ te(Vt, [["__scopeId", "data-v-44914130"]]), ln = re(
1213
+ () => import("./AppButtonCopy-CT_lXO96.js")
1214
+ ), on = re(
1215
+ () => import("./AppSelect-B0FVWo0o.js")
1216
+ ), rn = re(
1217
+ () => import("./DropdownButton-Ylu19LP3.js")
1218
+ );
1219
+ export {
1220
+ en as A,
1221
+ it as B,
1222
+ Be as C,
1223
+ vt as D,
1224
+ Xt as E,
1225
+ Wt as F,
1226
+ Gt as G,
1227
+ nt as H,
1228
+ at as I,
1229
+ rn as J,
1230
+ ln as K,
1231
+ on as L,
1232
+ an as M,
1233
+ tn as N,
1234
+ nn as O,
1235
+ ve as Q,
1236
+ st as R,
1237
+ q as S,
1238
+ te as _,
1239
+ At as a,
1240
+ zt as b,
1241
+ Z as c,
1242
+ se as d,
1243
+ N as e,
1244
+ Jt as f,
1245
+ bt as g,
1246
+ Qe as h,
1247
+ oe as i,
1248
+ Kt as j,
1249
+ tt as k,
1250
+ Qt as l,
1251
+ Ft as m,
1252
+ ee as n,
1253
+ Yt as o,
1254
+ lt as p,
1255
+ Ut as q,
1256
+ Ht as r,
1257
+ D as s,
1258
+ rt as t,
1259
+ ue as u,
1260
+ _e as v,
1261
+ qt as w,
1262
+ Zt as x,
1263
+ wt as y,
1264
+ ot as z
1265
+ };