@quidgest/ui 0.10.1 → 0.11.0
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/index.d.ts +32 -0
- package/dist/ui.css +45 -0
- package/dist/ui.esm.js +312 -289
- package/dist/ui.esm.js.map +1 -1
- package/dist/ui.js +1 -1
- package/dist/ui.js.map +1 -1
- package/dist/ui.min.css +1 -1
- package/dist/ui.min.js +24 -23
- package/dist/ui.min.js.map +1 -1
- package/dist/ui.scss +54 -1
- package/package.json +1 -1
package/dist/ui.esm.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { getCurrentInstance as Ue, computed as
|
|
1
|
+
import { getCurrentInstance as Ue, computed as k, ref as V, provide as Pe, inject as Ne, watch as W, defineComponent as L, openBlock as u, createElementBlock as m, normalizeClass as C, normalizeStyle as ie, withModifiers as ue, createVNode as Q, unref as b, createCommentVNode as q, createElementVNode as le, Fragment as ae, createTextVNode as me, toDisplayString as R, renderSlot as h, toRef as Ee, mergeModels as X, useModel as te, createBlock as D, withCtx as w, renderList as qe, resolveDynamicComponent as He, h as De, normalizeProps as se, mergeProps as ce, reactive as Ae, nextTick as j, onMounted as Ke, onBeforeUnmount as Xe, Teleport as Ye, Transition as Ze, withKeys as Je, createSlots as we, withDirectives as et, vModelDynamic as tt, guardReactiveProps as fe } from "vue";
|
|
2
2
|
function Ie(t) {
|
|
3
3
|
return t == null ? !0 : typeof t == "string" || Array.isArray(t) ? t.length === 0 : typeof t == "object" ? Object.keys(t).length === 0 : !1;
|
|
4
4
|
}
|
|
@@ -32,12 +32,12 @@ function ot() {
|
|
|
32
32
|
if (!o)
|
|
33
33
|
throw new Error("[Quidgest UI] Could not determine component name");
|
|
34
34
|
const e = We(), n = (s = e.value) == null ? void 0 : s.Global, l = (i = e.value) == null ? void 0 : i[o];
|
|
35
|
-
return
|
|
35
|
+
return k(() => xe(n, l));
|
|
36
36
|
}
|
|
37
37
|
function Ge(t) {
|
|
38
38
|
if (Ie(t))
|
|
39
39
|
return;
|
|
40
|
-
const o = We(), e =
|
|
40
|
+
const o = We(), e = V(t), n = k(() => Ie(e.value) ? o.value : xe(o.value, e.value));
|
|
41
41
|
Pe(Le, n);
|
|
42
42
|
}
|
|
43
43
|
function We() {
|
|
@@ -53,9 +53,9 @@ function nt() {
|
|
|
53
53
|
throw new Error("[Quidgest UI] Could not find theme instance");
|
|
54
54
|
return t;
|
|
55
55
|
}
|
|
56
|
-
function
|
|
56
|
+
function No(t) {
|
|
57
57
|
const o = nt(), e = {
|
|
58
|
-
activeTheme:
|
|
58
|
+
activeTheme: V(t),
|
|
59
59
|
themes: o.themes
|
|
60
60
|
};
|
|
61
61
|
return Pe(ve, e), e;
|
|
@@ -168,13 +168,13 @@ function rt(t) {
|
|
|
168
168
|
function Me(t) {
|
|
169
169
|
return t ? `--q-theme-${je(t)}` : "";
|
|
170
170
|
}
|
|
171
|
-
function
|
|
171
|
+
function Ho(t = {}) {
|
|
172
172
|
return { install: (e) => {
|
|
173
173
|
const n = t.components || {};
|
|
174
174
|
for (const s in n)
|
|
175
175
|
e.component(s, n[s]);
|
|
176
176
|
const l = t.defaults || {};
|
|
177
|
-
e.provide(Le,
|
|
177
|
+
e.provide(Le, V(l)), dt(e, t.themes);
|
|
178
178
|
} };
|
|
179
179
|
}
|
|
180
180
|
function dt(t, o) {
|
|
@@ -197,7 +197,7 @@ function dt(t, o) {
|
|
|
197
197
|
}
|
|
198
198
|
if (n) {
|
|
199
199
|
const l = {
|
|
200
|
-
activeTheme:
|
|
200
|
+
activeTheme: V(n),
|
|
201
201
|
themes: e
|
|
202
202
|
};
|
|
203
203
|
rt(e), W(l.activeTheme, ut, { immediate: !0 }), t.provide(ve, l);
|
|
@@ -214,12 +214,12 @@ const ct = /* @__PURE__ */ L({
|
|
|
214
214
|
class: { default: void 0 }
|
|
215
215
|
},
|
|
216
216
|
setup(t) {
|
|
217
|
-
const o = t, e =
|
|
217
|
+
const o = t, e = k(() => ({
|
|
218
218
|
"font-size": o.size !== 48 ? `${o.size}px` : void 0
|
|
219
219
|
}));
|
|
220
|
-
return (n, l) => (
|
|
221
|
-
class:
|
|
222
|
-
style:
|
|
220
|
+
return (n, l) => (u(), m("div", {
|
|
221
|
+
class: C(["q-spinner-loader", o.class]),
|
|
222
|
+
style: ie(e.value)
|
|
223
223
|
}, null, 6));
|
|
224
224
|
}
|
|
225
225
|
});
|
|
@@ -228,7 +228,7 @@ function ft(t, o) {
|
|
|
228
228
|
const e = je(o);
|
|
229
229
|
return e ? typeof ((n = t.props) == null ? void 0 : n[e]) < "u" : !1;
|
|
230
230
|
}
|
|
231
|
-
function
|
|
231
|
+
function S(t) {
|
|
232
232
|
const o = t.setup;
|
|
233
233
|
return o && (t.setup = (e, n) => {
|
|
234
234
|
const l = ot();
|
|
@@ -238,16 +238,16 @@ function V(t) {
|
|
|
238
238
|
if (s === null)
|
|
239
239
|
return o(e, n);
|
|
240
240
|
const i = new Proxy(e, {
|
|
241
|
-
get(a,
|
|
241
|
+
get(a, c) {
|
|
242
242
|
var x;
|
|
243
|
-
const v = Reflect.get(a,
|
|
244
|
-
return typeof
|
|
243
|
+
const v = Reflect.get(a, c), $ = (x = l.value) == null ? void 0 : x[c];
|
|
244
|
+
return typeof c == "string" && !ft(s.vnode, c) ? $ ?? v : v;
|
|
245
245
|
}
|
|
246
246
|
});
|
|
247
247
|
return o(i, n);
|
|
248
248
|
}), t;
|
|
249
249
|
}
|
|
250
|
-
const Se =
|
|
250
|
+
const Se = S(ct), pt = ["disabled"], mt = {
|
|
251
251
|
key: 0,
|
|
252
252
|
class: "q-btn__spinner"
|
|
253
253
|
}, vt = { class: "q-btn__content" }, ht = /* @__PURE__ */ L({
|
|
@@ -267,11 +267,11 @@ const Se = V(ct), pt = ["disabled"], mt = {
|
|
|
267
267
|
},
|
|
268
268
|
emits: ["click"],
|
|
269
269
|
setup(t, { emit: o }) {
|
|
270
|
-
const e = t, n = o, l =
|
|
270
|
+
const e = t, n = o, l = k(() => e.disabled || e.loading);
|
|
271
271
|
function s(a) {
|
|
272
272
|
l.value || n("click", a);
|
|
273
273
|
}
|
|
274
|
-
const i =
|
|
274
|
+
const i = k(() => {
|
|
275
275
|
const a = e.size !== "regular" ? `q-btn--${e.size}` : void 0;
|
|
276
276
|
return [
|
|
277
277
|
"q-btn",
|
|
@@ -287,27 +287,27 @@ const Se = V(ct), pt = ["disabled"], mt = {
|
|
|
287
287
|
e.class
|
|
288
288
|
];
|
|
289
289
|
});
|
|
290
|
-
return (a,
|
|
290
|
+
return (a, c) => (u(), m("button", {
|
|
291
291
|
type: "button",
|
|
292
|
-
class:
|
|
292
|
+
class: C(i.value),
|
|
293
293
|
disabled: l.value,
|
|
294
294
|
onClick: ue(s, ["stop", "prevent"])
|
|
295
295
|
}, [
|
|
296
|
-
a.loading ? (
|
|
296
|
+
a.loading ? (u(), m("div", mt, [
|
|
297
297
|
Q(b(Se), { size: 20 })
|
|
298
298
|
])) : q("", !0),
|
|
299
|
-
|
|
300
|
-
a.iconOnRight ? (
|
|
299
|
+
le("span", vt, [
|
|
300
|
+
a.iconOnRight ? (u(), m(ae, { key: 0 }, [
|
|
301
301
|
me(R(e.label), 1)
|
|
302
302
|
], 64)) : q("", !0),
|
|
303
303
|
h(a.$slots, "default"),
|
|
304
|
-
a.iconOnRight ? q("", !0) : (
|
|
304
|
+
a.iconOnRight ? q("", !0) : (u(), m(ae, { key: 1 }, [
|
|
305
305
|
me(R(e.label), 1)
|
|
306
306
|
], 64))
|
|
307
307
|
])
|
|
308
308
|
], 10, pt));
|
|
309
309
|
}
|
|
310
|
-
}), he =
|
|
310
|
+
}), he = S(ht), yt = /* @__PURE__ */ L({
|
|
311
311
|
__name: "QButtonGroup",
|
|
312
312
|
props: {
|
|
313
313
|
disabled: { type: Boolean },
|
|
@@ -324,8 +324,8 @@ const Se = V(ct), pt = ["disabled"], mt = {
|
|
|
324
324
|
borderless: Ee(o, "borderless"),
|
|
325
325
|
elevated: !1
|
|
326
326
|
}
|
|
327
|
-
}), (e, n) => (
|
|
328
|
-
class:
|
|
327
|
+
}), (e, n) => (u(), m("div", {
|
|
328
|
+
class: C([
|
|
329
329
|
"q-btn-group",
|
|
330
330
|
{
|
|
331
331
|
"q-btn-group--elevated": o.elevated
|
|
@@ -336,7 +336,7 @@ const Se = V(ct), pt = ["disabled"], mt = {
|
|
|
336
336
|
h(e.$slots, "default")
|
|
337
337
|
], 2));
|
|
338
338
|
}
|
|
339
|
-
}), bt =
|
|
339
|
+
}), bt = S(yt), gt = /* @__PURE__ */ L({
|
|
340
340
|
__name: "QButtonToggle",
|
|
341
341
|
props: /* @__PURE__ */ X({
|
|
342
342
|
options: {},
|
|
@@ -355,22 +355,22 @@ const Se = V(ct), pt = ["disabled"], mt = {
|
|
|
355
355
|
function n(l) {
|
|
356
356
|
e.value === l.key && !o.required ? e.value = void 0 : e.value = l.key;
|
|
357
357
|
}
|
|
358
|
-
return (l, s) => (
|
|
358
|
+
return (l, s) => (u(), D(b(bt), {
|
|
359
359
|
"b-style": "secondary",
|
|
360
|
-
class:
|
|
360
|
+
class: C(o.class),
|
|
361
361
|
disabled: o.disabled,
|
|
362
362
|
borderless: o.borderless,
|
|
363
363
|
elevated: o.elevated
|
|
364
364
|
}, {
|
|
365
|
-
default:
|
|
366
|
-
(
|
|
365
|
+
default: w(() => [
|
|
366
|
+
(u(!0), m(ae, null, qe(o.options, (i) => (u(), D(b(he), {
|
|
367
367
|
key: i.key,
|
|
368
368
|
title: i.title,
|
|
369
369
|
label: i.label,
|
|
370
370
|
active: e.value === i.key,
|
|
371
371
|
onClick: () => n(i)
|
|
372
372
|
}, {
|
|
373
|
-
default:
|
|
373
|
+
default: w(() => [
|
|
374
374
|
h(l.$slots, i.key)
|
|
375
375
|
]),
|
|
376
376
|
_: 2
|
|
@@ -379,7 +379,7 @@ const Se = V(ct), pt = ["disabled"], mt = {
|
|
|
379
379
|
_: 3
|
|
380
380
|
}, 8, ["class", "disabled", "borderless", "elevated"]));
|
|
381
381
|
}
|
|
382
|
-
}),
|
|
382
|
+
}), Ko = S(gt), _t = /* @__PURE__ */ L({
|
|
383
383
|
__name: "QIcon",
|
|
384
384
|
props: {
|
|
385
385
|
icon: {},
|
|
@@ -388,7 +388,7 @@ const Se = V(ct), pt = ["disabled"], mt = {
|
|
|
388
388
|
class: { default: void 0 }
|
|
389
389
|
},
|
|
390
390
|
setup(t) {
|
|
391
|
-
const o = t, e =
|
|
391
|
+
const o = t, e = k(() => {
|
|
392
392
|
switch (o.type) {
|
|
393
393
|
case "svg":
|
|
394
394
|
return Vt;
|
|
@@ -400,8 +400,8 @@ const Se = V(ct), pt = ["disabled"], mt = {
|
|
|
400
400
|
return;
|
|
401
401
|
}
|
|
402
402
|
});
|
|
403
|
-
return (n, l) => (
|
|
404
|
-
class:
|
|
403
|
+
return (n, l) => (u(), D(He(e.value), {
|
|
404
|
+
class: C(o.class),
|
|
405
405
|
icon: o.icon,
|
|
406
406
|
size: o.size
|
|
407
407
|
}, null, 8, ["class", "icon", "size"]));
|
|
@@ -416,12 +416,12 @@ const Se = V(ct), pt = ["disabled"], mt = {
|
|
|
416
416
|
class: { default: void 0 }
|
|
417
417
|
},
|
|
418
418
|
setup(t) {
|
|
419
|
-
const o = t, e =
|
|
419
|
+
const o = t, e = k(() => o.variant ? `${o.library}-${o.variant}` : o.library), n = k(() => o.library && o.icon ? `${o.library}-${o.icon}` : o.icon), l = k(() => ({
|
|
420
420
|
"font-size": o.size !== void 0 ? `${o.size}px` : void 0
|
|
421
421
|
}));
|
|
422
|
-
return (s, i) => (
|
|
423
|
-
class:
|
|
424
|
-
style:
|
|
422
|
+
return (s, i) => (u(), m("i", {
|
|
423
|
+
class: C(["q-icon", "q-icon__font", e.value, n.value, o.class]),
|
|
424
|
+
style: ie(l.value)
|
|
425
425
|
}, null, 6));
|
|
426
426
|
}
|
|
427
427
|
}), wt = ["src"], $t = /* @__PURE__ */ L({
|
|
@@ -432,13 +432,13 @@ const Se = V(ct), pt = ["disabled"], mt = {
|
|
|
432
432
|
class: {}
|
|
433
433
|
},
|
|
434
434
|
setup(t) {
|
|
435
|
-
const o = t, e =
|
|
435
|
+
const o = t, e = k(() => ({
|
|
436
436
|
"font-size": o.size !== void 0 ? `${o.size}px` : void 0
|
|
437
437
|
}));
|
|
438
|
-
return (n, l) => (
|
|
438
|
+
return (n, l) => (u(), m("img", {
|
|
439
439
|
src: o.icon,
|
|
440
|
-
class:
|
|
441
|
-
style:
|
|
440
|
+
class: C(["q-icon", "q-icon__img", o.class]),
|
|
441
|
+
style: ie(e.value)
|
|
442
442
|
}, null, 14, wt));
|
|
443
443
|
}
|
|
444
444
|
}), pe = {}, qt = L({
|
|
@@ -586,7 +586,7 @@ const Lt = /* @__PURE__ */ L({
|
|
|
586
586
|
},
|
|
587
587
|
emits: ["loaded", "unloaded"],
|
|
588
588
|
setup(t, { emit: o }) {
|
|
589
|
-
const e = t, n = o, l =
|
|
589
|
+
const e = t, n = o, l = k(() => ({
|
|
590
590
|
"font-size": e.size !== void 0 ? `${e.size}px` : void 0
|
|
591
591
|
}));
|
|
592
592
|
function s(a) {
|
|
@@ -595,16 +595,16 @@ const Lt = /* @__PURE__ */ L({
|
|
|
595
595
|
function i() {
|
|
596
596
|
n("unloaded");
|
|
597
597
|
}
|
|
598
|
-
return (a,
|
|
599
|
-
class:
|
|
598
|
+
return (a, c) => (u(), D(b(qt), {
|
|
599
|
+
class: C(["q-icon", "q-icon__svg", e.class]),
|
|
600
600
|
src: e.bundle,
|
|
601
601
|
symbol: e.icon,
|
|
602
|
-
style:
|
|
602
|
+
style: ie(l.value),
|
|
603
603
|
onLoaded: s,
|
|
604
604
|
onUnloaded: i
|
|
605
605
|
}, null, 8, ["class", "src", "symbol", "style"]));
|
|
606
606
|
}
|
|
607
|
-
}), ne =
|
|
607
|
+
}), ne = S(_t), St = S(kt), Bt = S($t), Vt = S(Lt), Ct = /* @__PURE__ */ L({
|
|
608
608
|
__name: "QList",
|
|
609
609
|
props: /* @__PURE__ */ X({
|
|
610
610
|
highlighted: { type: [String, Number, Boolean, Symbol], default: void 0 },
|
|
@@ -622,10 +622,10 @@ const Lt = /* @__PURE__ */ L({
|
|
|
622
622
|
}),
|
|
623
623
|
emits: ["update:modelValue"],
|
|
624
624
|
setup(t, { expose: o }) {
|
|
625
|
-
const e = t, n = te(t, "modelValue"), l =
|
|
625
|
+
const e = t, n = te(t, "modelValue"), l = V(!1), s = k(() => i.value.length > 1 ? "div" : "ul"), i = k(() => e.groups.length ? e.groups.filter(
|
|
626
626
|
(f) => e.items.some((g) => g.group === f.id)
|
|
627
|
-
) : [{ id: "", title: "" }]), a =
|
|
628
|
-
function
|
|
627
|
+
) : [{ id: "", title: "" }]), a = V(null);
|
|
628
|
+
function c(f) {
|
|
629
629
|
n.value = f;
|
|
630
630
|
}
|
|
631
631
|
function v() {
|
|
@@ -646,20 +646,20 @@ const Lt = /* @__PURE__ */ L({
|
|
|
646
646
|
function z(f) {
|
|
647
647
|
switch (["ArrowDown", "ArrowUp", "Home", "End"].includes(f.key) && f.preventDefault(), f.key) {
|
|
648
648
|
case "ArrowDown":
|
|
649
|
-
|
|
649
|
+
T("next");
|
|
650
650
|
break;
|
|
651
651
|
case "ArrowUp":
|
|
652
|
-
|
|
652
|
+
T("prev");
|
|
653
653
|
break;
|
|
654
654
|
case "Home":
|
|
655
|
-
|
|
655
|
+
T("first");
|
|
656
656
|
break;
|
|
657
657
|
case "End":
|
|
658
|
-
|
|
658
|
+
T("last");
|
|
659
659
|
break;
|
|
660
660
|
}
|
|
661
661
|
}
|
|
662
|
-
function
|
|
662
|
+
function T(f) {
|
|
663
663
|
switch (f) {
|
|
664
664
|
case "next":
|
|
665
665
|
case "prev":
|
|
@@ -675,25 +675,25 @@ const Lt = /* @__PURE__ */ L({
|
|
|
675
675
|
}
|
|
676
676
|
function I(f, g = !1) {
|
|
677
677
|
var p;
|
|
678
|
-
(p =
|
|
678
|
+
(p = B()[f]) == null || p.focus({ preventScroll: g });
|
|
679
679
|
}
|
|
680
|
-
function
|
|
680
|
+
function B() {
|
|
681
681
|
var g;
|
|
682
682
|
const f = (g = a.value) == null ? void 0 : g.querySelectorAll("li");
|
|
683
683
|
return f ? Array.from(f) : [];
|
|
684
684
|
}
|
|
685
685
|
function K(f) {
|
|
686
|
-
return
|
|
686
|
+
return B()[f];
|
|
687
687
|
}
|
|
688
688
|
function Y() {
|
|
689
|
-
return
|
|
689
|
+
return B().indexOf(document.activeElement);
|
|
690
690
|
}
|
|
691
691
|
function H() {
|
|
692
|
-
const f =
|
|
692
|
+
const f = B(), g = f.find((d) => A(d));
|
|
693
693
|
return g ? f.indexOf(g) : -1;
|
|
694
694
|
}
|
|
695
695
|
function M() {
|
|
696
|
-
const f =
|
|
696
|
+
const f = B(), g = [...f].reverse().find((d) => A(d));
|
|
697
697
|
return g ? f.indexOf(g) : -1;
|
|
698
698
|
}
|
|
699
699
|
function Z(f, g, d) {
|
|
@@ -704,7 +704,7 @@ const Lt = /* @__PURE__ */ L({
|
|
|
704
704
|
return J(g, f);
|
|
705
705
|
}
|
|
706
706
|
function J(f, g) {
|
|
707
|
-
const d =
|
|
707
|
+
const d = B();
|
|
708
708
|
if (Z(f, g, d))
|
|
709
709
|
return f;
|
|
710
710
|
let p = f + (g === "next" ? 1 : -1);
|
|
@@ -727,10 +727,10 @@ const Lt = /* @__PURE__ */ L({
|
|
|
727
727
|
getAdjacentItemIndex: J,
|
|
728
728
|
getFirstFocusableItemIndex: H,
|
|
729
729
|
getLastFocusableItemIndex: M
|
|
730
|
-
}), (f, g) => (
|
|
730
|
+
}), (f, g) => (u(), D(He(s.value), {
|
|
731
731
|
ref_key: "listRef",
|
|
732
732
|
ref: a,
|
|
733
|
-
class:
|
|
733
|
+
class: C(["q-list", { "q-list--disabled": e.disabled }, e.class]),
|
|
734
734
|
role: "listbox",
|
|
735
735
|
tabindex: e.disabled ? -1 : 0,
|
|
736
736
|
onFocus: x,
|
|
@@ -738,14 +738,14 @@ const Lt = /* @__PURE__ */ L({
|
|
|
738
738
|
onMouseup: $,
|
|
739
739
|
onKeydown: z
|
|
740
740
|
}, {
|
|
741
|
-
default:
|
|
742
|
-
(
|
|
741
|
+
default: w(() => [
|
|
742
|
+
(u(!0), m(ae, null, qe(i.value, (d) => (u(), D(b(Ut), {
|
|
743
743
|
key: d.id,
|
|
744
744
|
id: d.id,
|
|
745
745
|
title: i.value.length === 1 ? void 0 : d.title
|
|
746
746
|
}, {
|
|
747
|
-
default:
|
|
748
|
-
(
|
|
747
|
+
default: w(() => [
|
|
748
|
+
(u(!0), m(ae, null, qe(G(d.id), (p) => (u(), D(b(Ot), {
|
|
749
749
|
key: p[e.itemValue],
|
|
750
750
|
value: p[e.itemValue],
|
|
751
751
|
label: p[e.itemLabel],
|
|
@@ -753,9 +753,9 @@ const Lt = /* @__PURE__ */ L({
|
|
|
753
753
|
disabled: e.disabled || d.disabled || p.disabled,
|
|
754
754
|
highlighted: e.highlighted === p[e.itemValue],
|
|
755
755
|
selected: n.value === p[e.itemValue],
|
|
756
|
-
onSelect:
|
|
756
|
+
onSelect: c
|
|
757
757
|
}, {
|
|
758
|
-
default:
|
|
758
|
+
default: w(() => [
|
|
759
759
|
h(f.$slots, "item", { item: p })
|
|
760
760
|
]),
|
|
761
761
|
_: 2
|
|
@@ -796,12 +796,12 @@ const Et = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], Dt = {
|
|
|
796
796
|
function i(a) {
|
|
797
797
|
a.key === "Tab" && s(), (a.key === "Enter" || a.key === " ") && (a.preventDefault(), a.stopPropagation(), s());
|
|
798
798
|
}
|
|
799
|
-
return (a,
|
|
799
|
+
return (a, c) => (u(), m("li", {
|
|
800
800
|
id: b(l),
|
|
801
801
|
"data-key": e.value,
|
|
802
802
|
role: "option",
|
|
803
803
|
tabindex: e.disabled ? void 0 : -2,
|
|
804
|
-
class:
|
|
804
|
+
class: C([
|
|
805
805
|
"q-list-item",
|
|
806
806
|
{
|
|
807
807
|
"q-list-item--disabled": e.disabled,
|
|
@@ -815,11 +815,11 @@ const Et = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], Dt = {
|
|
|
815
815
|
onClick: ue(s, ["stop", "prevent"])
|
|
816
816
|
}, [
|
|
817
817
|
h(a.$slots, "default", {}, () => [
|
|
818
|
-
e.icon ? (
|
|
818
|
+
e.icon ? (u(), D(b(ne), se(ce({ key: 0 }, e.icon)), null, 16)) : q("", !0),
|
|
819
819
|
me(" " + R(e.label), 1)
|
|
820
820
|
]),
|
|
821
|
-
|
|
822
|
-
e.selected ? (
|
|
821
|
+
le("div", Dt, [
|
|
822
|
+
e.selected ? (u(), D(b(ne), ce({ key: 0 }, e.icons.check, { class: "q-list-item__check" }), null, 16)) : q("", !0)
|
|
823
823
|
])
|
|
824
824
|
], 42, Et));
|
|
825
825
|
}
|
|
@@ -831,13 +831,13 @@ const Et = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], Dt = {
|
|
|
831
831
|
},
|
|
832
832
|
setup(t) {
|
|
833
833
|
const o = t, e = ye();
|
|
834
|
-
return (n, l) => (
|
|
834
|
+
return (n, l) => (u(), m("ul", {
|
|
835
835
|
class: "q-list-item-group",
|
|
836
836
|
role: "group",
|
|
837
837
|
"data-key": o.id,
|
|
838
838
|
"aria-labelledby": o.title ? b(e) : void 0
|
|
839
839
|
}, [
|
|
840
|
-
o.title ? (
|
|
840
|
+
o.title ? (u(), m("li", {
|
|
841
841
|
key: 0,
|
|
842
842
|
id: b(e),
|
|
843
843
|
class: "q-list-item-group__title",
|
|
@@ -846,16 +846,16 @@ const Et = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], Dt = {
|
|
|
846
846
|
h(n.$slots, "default")
|
|
847
847
|
], 8, Qt));
|
|
848
848
|
}
|
|
849
|
-
}), Re =
|
|
849
|
+
}), Re = S(Ct), Ot = S(zt), Ut = S(Ft), _e = 8;
|
|
850
850
|
function Pt(t, o, e, n) {
|
|
851
|
-
const l = (n == null ? void 0 : n.offset) ?? 0, s = (n == null ? void 0 : n.placement) ?? "bottom", i = t.getBoundingClientRect(), a = o.getBoundingClientRect(),
|
|
852
|
-
let
|
|
851
|
+
const l = (n == null ? void 0 : n.offset) ?? 0, s = (n == null ? void 0 : n.placement) ?? "bottom", i = t.getBoundingClientRect(), a = o.getBoundingClientRect(), c = e == null ? void 0 : e.getBoundingClientRect(), v = Nt(i, a, s, l), $ = Wt(i, a, v), x = Kt($, v, l), z = Ht(x, a, v);
|
|
852
|
+
let T;
|
|
853
853
|
if (n != null && n.arrow) {
|
|
854
|
-
if (!
|
|
854
|
+
if (!c)
|
|
855
855
|
throw new Error("[Quidgest UI] The arrow element must exist to compute its position");
|
|
856
|
-
|
|
856
|
+
T = Gt(z, i, a, c, v);
|
|
857
857
|
}
|
|
858
|
-
return { overlayCoords: z, arrowCoords:
|
|
858
|
+
return { overlayCoords: z, arrowCoords: T, placement: v };
|
|
859
859
|
}
|
|
860
860
|
function Nt(t, o, e, n) {
|
|
861
861
|
const l = Fe(t, o, e, n);
|
|
@@ -865,13 +865,13 @@ function Nt(t, o, e, n) {
|
|
|
865
865
|
bottom: "top",
|
|
866
866
|
left: "right",
|
|
867
867
|
right: "left"
|
|
868
|
-
}[s],
|
|
868
|
+
}[s], c = Fe(
|
|
869
869
|
t,
|
|
870
870
|
o,
|
|
871
871
|
a,
|
|
872
872
|
n
|
|
873
873
|
);
|
|
874
|
-
if (Oe(
|
|
874
|
+
if (Oe(c))
|
|
875
875
|
return e;
|
|
876
876
|
const v = Xt(e);
|
|
877
877
|
return v ? `${a}-${v}` : a;
|
|
@@ -879,7 +879,7 @@ function Nt(t, o, e, n) {
|
|
|
879
879
|
return e;
|
|
880
880
|
}
|
|
881
881
|
function Ht(t, o, e) {
|
|
882
|
-
const n = ke(e), l = (i, a,
|
|
882
|
+
const n = ke(e), l = (i, a, c) => Math.min(Math.max(i, a), c), s = { ...t };
|
|
883
883
|
return n === "x" ? s.x = l(t.x, _e, window.innerWidth - o.width - _e) : s.y = l(t.y, _e, window.innerHeight - o.height - _e), s;
|
|
884
884
|
}
|
|
885
885
|
function Kt(t, o, e) {
|
|
@@ -891,13 +891,13 @@ function Kt(t, o, e) {
|
|
|
891
891
|
}
|
|
892
892
|
function Gt(t, o, e, n, l) {
|
|
893
893
|
if (ke(l) === "y") {
|
|
894
|
-
const i = o.top + o.height / 2, a = t.y + e.height / 2,
|
|
894
|
+
const i = o.top + o.height / 2, a = t.y + e.height / 2, c = a - i, v = e.height / 2 - c - n.height / 2 + 2;
|
|
895
895
|
if (v > 0 && v < e.height - n.height)
|
|
896
896
|
return {
|
|
897
897
|
y: v
|
|
898
898
|
};
|
|
899
899
|
} else {
|
|
900
|
-
const i = o.left + o.width / 2, a = t.x + e.width / 2,
|
|
900
|
+
const i = o.left + o.width / 2, a = t.x + e.width / 2, c = a - i, v = e.width / 2 - c - n.width / 2 + 2;
|
|
901
901
|
if (v > 0 && v < e.width - n.width)
|
|
902
902
|
return {
|
|
903
903
|
x: v
|
|
@@ -1009,7 +1009,7 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1009
1009
|
}),
|
|
1010
1010
|
emits: /* @__PURE__ */ X(["enter", "leave"], ["update:modelValue"]),
|
|
1011
1011
|
setup(t, { emit: o }) {
|
|
1012
|
-
const e = t, n = o, l = te(t, "modelValue"), s =
|
|
1012
|
+
const e = t, n = o, l = te(t, "modelValue"), s = k(() => [
|
|
1013
1013
|
"q-overlay",
|
|
1014
1014
|
`q-overlay--${be(a.placement)}`,
|
|
1015
1015
|
{
|
|
@@ -1017,57 +1017,57 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1017
1017
|
"q-overlay--inverted": e.appearance === "inverted"
|
|
1018
1018
|
},
|
|
1019
1019
|
e.class
|
|
1020
|
-
]), i =
|
|
1020
|
+
]), i = k(() => (l.value || a.animating) && !e.nonModal), a = Ae({
|
|
1021
1021
|
animating: !1,
|
|
1022
1022
|
top: 0,
|
|
1023
1023
|
left: 0,
|
|
1024
1024
|
width: 0,
|
|
1025
1025
|
placement: e.placement
|
|
1026
|
-
}),
|
|
1026
|
+
}), c = Ae({
|
|
1027
1027
|
top: void 0,
|
|
1028
1028
|
left: void 0,
|
|
1029
1029
|
hidden: !0
|
|
1030
|
-
}), v =
|
|
1030
|
+
}), v = k(() => a.top !== 0 && a.left !== 0);
|
|
1031
1031
|
W(l, () => a.animating = !0);
|
|
1032
|
-
const $ =
|
|
1032
|
+
const $ = k(() => {
|
|
1033
1033
|
if (e.anchor === void 0)
|
|
1034
1034
|
return;
|
|
1035
|
-
const y = A(),
|
|
1035
|
+
const y = A(), re = e.width === "anchor", N = re ? y == null ? void 0 : y.getBoundingClientRect().width : void 0;
|
|
1036
1036
|
return {
|
|
1037
1037
|
top: `${a.top}px`,
|
|
1038
1038
|
left: `${a.left}px`,
|
|
1039
1039
|
width: N !== void 0 ? `${N}px` : void 0
|
|
1040
1040
|
};
|
|
1041
|
-
}), x =
|
|
1041
|
+
}), x = k(() => {
|
|
1042
1042
|
if (e.arrow)
|
|
1043
1043
|
return {
|
|
1044
|
-
top:
|
|
1045
|
-
left:
|
|
1046
|
-
opacity:
|
|
1044
|
+
top: c.top !== void 0 ? `${c.top}px` : void 0,
|
|
1045
|
+
left: c.left !== void 0 ? `${c.left}px` : void 0,
|
|
1046
|
+
opacity: c.hidden ? 0 : 1
|
|
1047
1047
|
};
|
|
1048
|
-
}), z =
|
|
1048
|
+
}), z = V(null), T = V(null);
|
|
1049
1049
|
function I() {
|
|
1050
1050
|
const y = A();
|
|
1051
|
-
if (!y || !
|
|
1051
|
+
if (!y || !T.value)
|
|
1052
1052
|
return;
|
|
1053
|
-
const
|
|
1053
|
+
const re = {
|
|
1054
1054
|
placement: e.placement,
|
|
1055
1055
|
width: e.width,
|
|
1056
1056
|
offset: e.offset,
|
|
1057
1057
|
arrow: e.arrow
|
|
1058
1058
|
}, N = Pt(
|
|
1059
1059
|
y,
|
|
1060
|
-
|
|
1060
|
+
T.value,
|
|
1061
1061
|
(z == null ? void 0 : z.value) ?? void 0,
|
|
1062
|
-
|
|
1062
|
+
re
|
|
1063
1063
|
);
|
|
1064
|
-
a.left = N.overlayCoords.x, a.top = N.overlayCoords.y, a.placement = N.placement,
|
|
1064
|
+
a.left = N.overlayCoords.x, a.top = N.overlayCoords.y, a.placement = N.placement, c.hidden = N.arrowCoords === void 0, N.arrowCoords && (c.top = N.arrowCoords.y, c.left = N.arrowCoords.x);
|
|
1065
1065
|
}
|
|
1066
1066
|
W(
|
|
1067
1067
|
() => e.placement,
|
|
1068
1068
|
() => j(I)
|
|
1069
1069
|
);
|
|
1070
|
-
let
|
|
1070
|
+
let B;
|
|
1071
1071
|
function K() {
|
|
1072
1072
|
H(0);
|
|
1073
1073
|
}
|
|
@@ -1075,12 +1075,12 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1075
1075
|
H(e.delay);
|
|
1076
1076
|
}
|
|
1077
1077
|
function H(y) {
|
|
1078
|
-
|
|
1078
|
+
B || (B = window.setTimeout(() => {
|
|
1079
1079
|
l.value = !0;
|
|
1080
1080
|
}, y));
|
|
1081
1081
|
}
|
|
1082
1082
|
function M() {
|
|
1083
|
-
if (clearTimeout(
|
|
1083
|
+
if (clearTimeout(B), B = void 0, l.value = !1, e.anchor && e.trigger === "click") {
|
|
1084
1084
|
const y = A();
|
|
1085
1085
|
y == null || y.focus();
|
|
1086
1086
|
}
|
|
@@ -1139,7 +1139,7 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1139
1139
|
function P() {
|
|
1140
1140
|
d(), e.spy ? ee() : I(), e.scrollLock && document.body.classList.add("no-scroll"), (e.anchor === void 0 || e.trigger === "click") && j(() => {
|
|
1141
1141
|
var y;
|
|
1142
|
-
return (y =
|
|
1142
|
+
return (y = T.value) == null ? void 0 : y.focus();
|
|
1143
1143
|
});
|
|
1144
1144
|
}
|
|
1145
1145
|
function oe() {
|
|
@@ -1158,13 +1158,13 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1158
1158
|
j(() => y ? P() : oe());
|
|
1159
1159
|
},
|
|
1160
1160
|
{ immediate: !0 }
|
|
1161
|
-
), (y,
|
|
1161
|
+
), (y, re) => (u(), D(Ye, {
|
|
1162
1162
|
disabled: !l.value && !a.animating || !e.attach,
|
|
1163
1163
|
to: e.attach
|
|
1164
1164
|
}, [
|
|
1165
|
-
i.value ? (
|
|
1165
|
+
i.value ? (u(), m("div", {
|
|
1166
1166
|
key: 0,
|
|
1167
|
-
class:
|
|
1167
|
+
class: C([
|
|
1168
1168
|
"q-overlay__underlay",
|
|
1169
1169
|
{ "q-overlay__underlay--blur": e.backdropBlur }
|
|
1170
1170
|
])
|
|
@@ -1174,29 +1174,29 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1174
1174
|
appear: "",
|
|
1175
1175
|
onLeave: J
|
|
1176
1176
|
}, {
|
|
1177
|
-
default:
|
|
1178
|
-
l.value ? (
|
|
1177
|
+
default: w(() => [
|
|
1178
|
+
l.value ? (u(), m("div", {
|
|
1179
1179
|
key: 0,
|
|
1180
|
-
class:
|
|
1181
|
-
style:
|
|
1180
|
+
class: C(s.value),
|
|
1181
|
+
style: ie($.value)
|
|
1182
1182
|
}, [
|
|
1183
|
-
|
|
1183
|
+
le("div", ce({
|
|
1184
1184
|
class: "q-overlay__content",
|
|
1185
1185
|
ref_key: "overlayRef",
|
|
1186
|
-
ref:
|
|
1186
|
+
ref: T,
|
|
1187
1187
|
tabindex: "-1",
|
|
1188
1188
|
role: i.value ? "dialog" : void 0
|
|
1189
1189
|
}, y.$attrs, {
|
|
1190
1190
|
onKeydown: Je(ge, ["escape"]),
|
|
1191
1191
|
onBlur: ge
|
|
1192
1192
|
}), [
|
|
1193
|
-
e.arrow ? (
|
|
1193
|
+
e.arrow ? (u(), m("div", {
|
|
1194
1194
|
key: 0,
|
|
1195
1195
|
ref_key: "arrowRef",
|
|
1196
1196
|
ref: z,
|
|
1197
1197
|
role: "presentation",
|
|
1198
1198
|
class: "q-overlay__arrow",
|
|
1199
|
-
style:
|
|
1199
|
+
style: ie(x.value)
|
|
1200
1200
|
}, null, 4)) : q("", !0),
|
|
1201
1201
|
h(y.$slots, "default")
|
|
1202
1202
|
], 16, Zt)
|
|
@@ -1206,7 +1206,7 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1206
1206
|
}, 8, ["name"])
|
|
1207
1207
|
], 8, ["disabled", "to"]));
|
|
1208
1208
|
}
|
|
1209
|
-
}), $e =
|
|
1209
|
+
}), $e = S(Jt), eo = ["id"], to = {
|
|
1210
1210
|
key: 0,
|
|
1211
1211
|
class: "q-field__label"
|
|
1212
1212
|
}, oo = ["for"], no = {
|
|
@@ -1232,12 +1232,12 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1232
1232
|
class: { default: void 0 }
|
|
1233
1233
|
},
|
|
1234
1234
|
setup(t, { expose: o }) {
|
|
1235
|
-
const e = t, n = ye(e.id), l =
|
|
1235
|
+
const e = t, n = ye(e.id), l = V(null), s = k(() => e.required && !e.readonly && !e.disabled);
|
|
1236
1236
|
return o({
|
|
1237
1237
|
fieldRef: l
|
|
1238
|
-
}), (i, a) => (
|
|
1238
|
+
}), (i, a) => (u(), m("div", {
|
|
1239
1239
|
id: b(n),
|
|
1240
|
-
class:
|
|
1240
|
+
class: C([
|
|
1241
1241
|
"q-field",
|
|
1242
1242
|
`q-field--${e.size}`,
|
|
1243
1243
|
{
|
|
@@ -1248,34 +1248,34 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1248
1248
|
e.class
|
|
1249
1249
|
])
|
|
1250
1250
|
}, [
|
|
1251
|
-
e.label ? (
|
|
1251
|
+
e.label ? (u(), m("div", to, [
|
|
1252
1252
|
h(i.$slots, "label.prepend"),
|
|
1253
|
-
|
|
1253
|
+
le("label", {
|
|
1254
1254
|
for: e.for
|
|
1255
1255
|
}, R(e.label), 9, oo),
|
|
1256
1256
|
h(i.$slots, "label.append")
|
|
1257
1257
|
])) : q("", !0),
|
|
1258
1258
|
h(i.$slots, "control", {}, () => [
|
|
1259
|
-
|
|
1259
|
+
le("div", ce({
|
|
1260
1260
|
class: "q-field__control",
|
|
1261
1261
|
ref_key: "fieldRef",
|
|
1262
1262
|
ref: l
|
|
1263
1263
|
}, i.$attrs), [
|
|
1264
|
-
i.$slots.prepend ? (
|
|
1264
|
+
i.$slots.prepend ? (u(), m("div", no, [
|
|
1265
1265
|
h(i.$slots, "prepend")
|
|
1266
1266
|
])) : q("", !0),
|
|
1267
1267
|
h(i.$slots, "default"),
|
|
1268
|
-
i.$slots.append ? (
|
|
1268
|
+
i.$slots.append ? (u(), m("div", lo, [
|
|
1269
1269
|
h(i.$slots, "append")
|
|
1270
1270
|
])) : q("", !0)
|
|
1271
1271
|
], 16)
|
|
1272
1272
|
]),
|
|
1273
|
-
i.$slots.extras ? (
|
|
1273
|
+
i.$slots.extras ? (u(), m("div", ao, [
|
|
1274
1274
|
h(i.$slots, "extras")
|
|
1275
1275
|
])) : q("", !0)
|
|
1276
1276
|
], 10, eo));
|
|
1277
1277
|
}
|
|
1278
|
-
}), Be =
|
|
1278
|
+
}), Be = S(so), io = ["id", "type", "role", "required", "placeholder", "readonly", "disabled", "maxlength"], ro = /* @__PURE__ */ L({
|
|
1279
1279
|
inheritAttrs: !1,
|
|
1280
1280
|
__name: "QTextField",
|
|
1281
1281
|
props: /* @__PURE__ */ X({
|
|
@@ -1296,19 +1296,19 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1296
1296
|
}),
|
|
1297
1297
|
emits: ["update:modelValue"],
|
|
1298
1298
|
setup(t, { expose: o }) {
|
|
1299
|
-
const e = t, n = te(t, "modelValue"), l = ye(e.id), s =
|
|
1299
|
+
const e = t, n = te(t, "modelValue"), l = ye(e.id), s = V(null), i = V(null), a = k(
|
|
1300
1300
|
() => e.readonly || e.disabled ? "" : e.placeholder
|
|
1301
1301
|
);
|
|
1302
1302
|
return o({
|
|
1303
|
-
fieldRef:
|
|
1304
|
-
var
|
|
1305
|
-
return (
|
|
1303
|
+
fieldRef: k(() => {
|
|
1304
|
+
var c;
|
|
1305
|
+
return (c = s.value) == null ? void 0 : c.fieldRef;
|
|
1306
1306
|
}),
|
|
1307
1307
|
inputRef: i
|
|
1308
|
-
}), (
|
|
1308
|
+
}), (c, v) => (u(), D(b(Be), {
|
|
1309
1309
|
ref_key: "fieldRef",
|
|
1310
1310
|
ref: s,
|
|
1311
|
-
class:
|
|
1311
|
+
class: C(["q-text-field", e.class]),
|
|
1312
1312
|
for: b(l),
|
|
1313
1313
|
label: e.label,
|
|
1314
1314
|
size: e.size,
|
|
@@ -1316,14 +1316,14 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1316
1316
|
disabled: e.disabled,
|
|
1317
1317
|
required: e.required
|
|
1318
1318
|
}, we({
|
|
1319
|
-
"label.prepend":
|
|
1320
|
-
h(
|
|
1319
|
+
"label.prepend": w(() => [
|
|
1320
|
+
h(c.$slots, "label.prepend")
|
|
1321
1321
|
]),
|
|
1322
|
-
"label.append":
|
|
1323
|
-
h(
|
|
1322
|
+
"label.append": w(() => [
|
|
1323
|
+
h(c.$slots, "label.append")
|
|
1324
1324
|
]),
|
|
1325
|
-
default:
|
|
1326
|
-
et(
|
|
1325
|
+
default: w(() => [
|
|
1326
|
+
et(le("input", ce({
|
|
1327
1327
|
"onUpdate:modelValue": v[0] || (v[0] = ($) => n.value = $),
|
|
1328
1328
|
ref_key: "inputRef",
|
|
1329
1329
|
ref: i,
|
|
@@ -1336,36 +1336,36 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1336
1336
|
readonly: e.readonly,
|
|
1337
1337
|
disabled: e.disabled,
|
|
1338
1338
|
maxlength: e.maxLength
|
|
1339
|
-
},
|
|
1339
|
+
}, c.$attrs), null, 16, io), [
|
|
1340
1340
|
[tt, n.value]
|
|
1341
1341
|
])
|
|
1342
1342
|
]),
|
|
1343
1343
|
_: 2
|
|
1344
1344
|
}, [
|
|
1345
|
-
|
|
1345
|
+
c.$slots.prepend ? {
|
|
1346
1346
|
name: "prepend",
|
|
1347
|
-
fn:
|
|
1348
|
-
h(
|
|
1347
|
+
fn: w(() => [
|
|
1348
|
+
h(c.$slots, "prepend")
|
|
1349
1349
|
]),
|
|
1350
1350
|
key: "0"
|
|
1351
1351
|
} : void 0,
|
|
1352
|
-
|
|
1352
|
+
c.$slots.append ? {
|
|
1353
1353
|
name: "append",
|
|
1354
|
-
fn:
|
|
1355
|
-
h(
|
|
1354
|
+
fn: w(() => [
|
|
1355
|
+
h(c.$slots, "append")
|
|
1356
1356
|
]),
|
|
1357
1357
|
key: "1"
|
|
1358
1358
|
} : void 0,
|
|
1359
|
-
|
|
1359
|
+
c.$slots.extras ? {
|
|
1360
1360
|
name: "extras",
|
|
1361
|
-
fn:
|
|
1362
|
-
h(
|
|
1361
|
+
fn: w(() => [
|
|
1362
|
+
h(c.$slots, "extras")
|
|
1363
1363
|
]),
|
|
1364
1364
|
key: "2"
|
|
1365
1365
|
} : void 0
|
|
1366
1366
|
]), 1032, ["class", "for", "label", "size", "readonly", "disabled", "required"]));
|
|
1367
1367
|
}
|
|
1368
|
-
}), uo =
|
|
1368
|
+
}), uo = S(ro), co = ["data-key"], fo = {
|
|
1369
1369
|
key: 0,
|
|
1370
1370
|
class: "q-select__loader"
|
|
1371
1371
|
}, po = {
|
|
@@ -1414,68 +1414,68 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1414
1414
|
}),
|
|
1415
1415
|
emits: /* @__PURE__ */ X(["before-show", "before-hide", "show", "hide"], ["update:modelValue", "update:open", "update:search"]),
|
|
1416
1416
|
setup(t, { expose: o, emit: e }) {
|
|
1417
|
-
const n = t, l = e, s = te(t, "modelValue"), i = te(t, "open"), a = te(t, "search"),
|
|
1417
|
+
const n = t, l = e, s = te(t, "modelValue"), i = te(t, "open"), a = te(t, "search"), c = V(void 0), v = V(null), $ = V(null), x = V(null), z = V(null);
|
|
1418
1418
|
Ke(U);
|
|
1419
|
-
const
|
|
1419
|
+
const T = k(() => n.clearable && !n.readonly && !n.disabled), I = k(() => {
|
|
1420
1420
|
var r;
|
|
1421
1421
|
return n.filterMode === "manual" || !M.value ? n.items : (r = n.items) == null ? void 0 : r.filter(
|
|
1422
1422
|
(_) => _[n.itemLabel].toLowerCase().startsWith(a.value.toLowerCase())
|
|
1423
1423
|
);
|
|
1424
|
-
}),
|
|
1424
|
+
}), B = k(() => {
|
|
1425
1425
|
var r;
|
|
1426
1426
|
return (r = n.items) == null ? void 0 : r.find((_) => _[n.itemValue] === s.value);
|
|
1427
|
-
}), K =
|
|
1428
|
-
const r =
|
|
1427
|
+
}), K = k(() => B.value === void 0), Y = k(() => {
|
|
1428
|
+
const r = c.value;
|
|
1429
1429
|
if (r !== void 0 && I.value[r])
|
|
1430
1430
|
return I.value[r];
|
|
1431
|
-
}), H =
|
|
1431
|
+
}), H = k(() => {
|
|
1432
1432
|
var _;
|
|
1433
|
-
if (
|
|
1433
|
+
if (c.value === void 0)
|
|
1434
1434
|
return;
|
|
1435
|
-
const r = (_ = $.value) == null ? void 0 : _.getItem(
|
|
1435
|
+
const r = (_ = $.value) == null ? void 0 : _.getItem(c.value);
|
|
1436
1436
|
return r == null ? void 0 : r.id;
|
|
1437
|
-
}), M =
|
|
1437
|
+
}), M = k(() => {
|
|
1438
1438
|
var r;
|
|
1439
|
-
return a.value.length > 0 && a.value !== ((r =
|
|
1439
|
+
return a.value.length > 0 && a.value !== ((r = B.value) == null ? void 0 : r[n.itemLabel]);
|
|
1440
1440
|
});
|
|
1441
1441
|
function Z(r) {
|
|
1442
1442
|
s.value = r, A();
|
|
1443
1443
|
}
|
|
1444
1444
|
function U() {
|
|
1445
1445
|
var _;
|
|
1446
|
-
const r = ((_ =
|
|
1446
|
+
const r = ((_ = B.value) == null ? void 0 : _[n.itemLabel]) || "";
|
|
1447
1447
|
a.value !== r && (a.value = r);
|
|
1448
1448
|
}
|
|
1449
1449
|
function J() {
|
|
1450
1450
|
i.value || n.readonly || n.disabled || (l("before-show"), i.value = !0, oe());
|
|
1451
1451
|
}
|
|
1452
1452
|
function A() {
|
|
1453
|
-
i.value && (l("before-hide"), i.value = !1,
|
|
1453
|
+
i.value && (l("before-hide"), i.value = !1, c.value = void 0);
|
|
1454
1454
|
}
|
|
1455
1455
|
function G() {
|
|
1456
1456
|
i.value ? A() : g();
|
|
1457
1457
|
}
|
|
1458
1458
|
function f() {
|
|
1459
|
-
|
|
1459
|
+
T.value && (s.value = n.emptyValue, c.value = void 0, oe());
|
|
1460
1460
|
}
|
|
1461
1461
|
function g() {
|
|
1462
|
-
if (J(),
|
|
1463
|
-
const r = I.value.indexOf(
|
|
1462
|
+
if (J(), B.value !== void 0) {
|
|
1463
|
+
const r = I.value.indexOf(B.value);
|
|
1464
1464
|
r !== -1 && j(() => N(r));
|
|
1465
1465
|
}
|
|
1466
1466
|
}
|
|
1467
1467
|
function d(r) {
|
|
1468
|
-
var _,
|
|
1468
|
+
var _, E;
|
|
1469
1469
|
if (!(!r.key || n.readonly || n.disabled))
|
|
1470
1470
|
if (["ArrowDown", "ArrowUp", "Home", "End"].includes(r.key) && (r.preventDefault(), r.stopPropagation()), r.key === "Escape")
|
|
1471
1471
|
U(), i.value && A();
|
|
1472
1472
|
else if (["ArrowDown", "ArrowUp"].includes(r.key))
|
|
1473
1473
|
i.value ? j(() => {
|
|
1474
|
-
if (
|
|
1474
|
+
if (c.value === void 0)
|
|
1475
1475
|
p();
|
|
1476
1476
|
else {
|
|
1477
1477
|
const O = r.key === "ArrowDown" ? "next" : "prev";
|
|
1478
|
-
ee(
|
|
1478
|
+
ee(c.value, O);
|
|
1479
1479
|
}
|
|
1480
1480
|
}) : (J(), j(() => {
|
|
1481
1481
|
r.key === "ArrowDown" ? p() : F();
|
|
@@ -1485,35 +1485,35 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1485
1485
|
return;
|
|
1486
1486
|
Z(Y.value[n.itemValue]);
|
|
1487
1487
|
} else
|
|
1488
|
-
r.key === "Home" ?
|
|
1488
|
+
r.key === "Home" ? c.value = (_ = $.value) == null ? void 0 : _.getFirstFocusableItemIndex() : r.key === "End" ? c.value = (E = $.value) == null ? void 0 : E.getLastFocusableItemIndex() : (/^[a-z]$/i.test(r.key) || r.key === "Backspace") && J();
|
|
1489
1489
|
}
|
|
1490
1490
|
function p() {
|
|
1491
1491
|
var r, _;
|
|
1492
1492
|
if (K.value)
|
|
1493
|
-
|
|
1493
|
+
c.value = (_ = $.value) == null ? void 0 : _.getFirstFocusableItemIndex();
|
|
1494
1494
|
else {
|
|
1495
|
-
const
|
|
1495
|
+
const E = I.value.findIndex(
|
|
1496
1496
|
(O) => O[n.itemValue] === s.value
|
|
1497
1497
|
);
|
|
1498
|
-
|
|
1498
|
+
E === -1 ? c.value = (r = $.value) == null ? void 0 : r.getFirstFocusableItemIndex() : c.value = E;
|
|
1499
1499
|
}
|
|
1500
1500
|
}
|
|
1501
1501
|
function F() {
|
|
1502
1502
|
var r;
|
|
1503
|
-
|
|
1503
|
+
c.value = (r = $.value) == null ? void 0 : r.getLastFocusableItemIndex();
|
|
1504
1504
|
}
|
|
1505
1505
|
function ee(r, _) {
|
|
1506
|
-
var
|
|
1507
|
-
|
|
1506
|
+
var E;
|
|
1507
|
+
c.value = (E = $.value) == null ? void 0 : E.getAdjacentItemIndex(r, _);
|
|
1508
1508
|
}
|
|
1509
1509
|
function P(r) {
|
|
1510
|
-
var
|
|
1511
|
-
const _ = ((
|
|
1512
|
-
if (_ || O ||
|
|
1510
|
+
var de, Ve, Ce, Te;
|
|
1511
|
+
const _ = ((de = x == null ? void 0 : x.value) == null ? void 0 : de.$el) === r.relatedTarget, E = (Ce = (Ve = v == null ? void 0 : v.value) == null ? void 0 : Ve.$el) == null ? void 0 : Ce.contains(r.relatedTarget), O = (Te = z == null ? void 0 : z.value) == null ? void 0 : Te.contains(r.relatedTarget);
|
|
1512
|
+
if (_ || O || E) {
|
|
1513
1513
|
r.preventDefault(), r.stopPropagation();
|
|
1514
1514
|
return;
|
|
1515
1515
|
}
|
|
1516
|
-
A(),
|
|
1516
|
+
A(), T.value && !a.value && (s.value = n.emptyValue), U();
|
|
1517
1517
|
}
|
|
1518
1518
|
function oe() {
|
|
1519
1519
|
var r, _;
|
|
@@ -1525,24 +1525,24 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1525
1525
|
function y() {
|
|
1526
1526
|
l("show");
|
|
1527
1527
|
}
|
|
1528
|
-
function
|
|
1528
|
+
function re() {
|
|
1529
1529
|
l("hide");
|
|
1530
1530
|
}
|
|
1531
1531
|
function N(r) {
|
|
1532
|
-
var
|
|
1533
|
-
const _ = (
|
|
1532
|
+
var E;
|
|
1533
|
+
const _ = (E = $.value) == null ? void 0 : E.getItem(r);
|
|
1534
1534
|
$.value && ($.value.$el.scrollTop = _ == null ? void 0 : _.offsetTop);
|
|
1535
1535
|
}
|
|
1536
1536
|
return W(s, U), W(
|
|
1537
1537
|
() => n.items,
|
|
1538
1538
|
(r, _) => {
|
|
1539
1539
|
if (!K.value) {
|
|
1540
|
-
const
|
|
1541
|
-
a.value === (
|
|
1540
|
+
const E = _.find((O) => O[n.itemValue] === s.value);
|
|
1541
|
+
a.value === (E == null ? void 0 : E[n.itemLabel]) && U();
|
|
1542
1542
|
}
|
|
1543
1543
|
},
|
|
1544
1544
|
{ deep: !0 }
|
|
1545
|
-
), W(
|
|
1545
|
+
), W(c, (r) => {
|
|
1546
1546
|
r !== void 0 && N(r);
|
|
1547
1547
|
}), W(a, (r) => {
|
|
1548
1548
|
r && i.value && n.selectionMode === "automatic" && j(p);
|
|
@@ -1554,8 +1554,8 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1554
1554
|
), o({
|
|
1555
1555
|
triggerEl: v
|
|
1556
1556
|
}), (r, _) => {
|
|
1557
|
-
var
|
|
1558
|
-
return
|
|
1557
|
+
var E;
|
|
1558
|
+
return u(), m(ae, null, [
|
|
1559
1559
|
Q(b(uo), {
|
|
1560
1560
|
modelValue: a.value,
|
|
1561
1561
|
"onUpdate:modelValue": _[0] || (_[0] = (O) => a.value = O),
|
|
@@ -1566,7 +1566,7 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1566
1566
|
ref: v,
|
|
1567
1567
|
role: "combobox",
|
|
1568
1568
|
placeholder: n.placeholder,
|
|
1569
|
-
class:
|
|
1569
|
+
class: C([
|
|
1570
1570
|
"q-combobox",
|
|
1571
1571
|
{
|
|
1572
1572
|
"q-combobox--readonly": n.readonly,
|
|
@@ -1588,15 +1588,15 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1588
1588
|
onFocusout: P,
|
|
1589
1589
|
onKeydown: ue(d, ["stop"])
|
|
1590
1590
|
}, we({
|
|
1591
|
-
"label.prepend":
|
|
1591
|
+
"label.prepend": w(() => [
|
|
1592
1592
|
h(r.$slots, "label.prepend")
|
|
1593
1593
|
]),
|
|
1594
|
-
"label.append":
|
|
1594
|
+
"label.append": w(() => [
|
|
1595
1595
|
h(r.$slots, "label.append")
|
|
1596
1596
|
]),
|
|
1597
|
-
append:
|
|
1597
|
+
append: w(() => [
|
|
1598
1598
|
h(r.$slots, "append"),
|
|
1599
|
-
|
|
1599
|
+
T.value && a.value ? (u(), D(b(he), {
|
|
1600
1600
|
key: 0,
|
|
1601
1601
|
class: "q-combobox__clear",
|
|
1602
1602
|
"b-style": "plain",
|
|
@@ -1604,12 +1604,12 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1604
1604
|
tabindex: "-1",
|
|
1605
1605
|
onClick: f
|
|
1606
1606
|
}, {
|
|
1607
|
-
default:
|
|
1608
|
-
Q(b(ne),
|
|
1607
|
+
default: w(() => [
|
|
1608
|
+
Q(b(ne), se(fe(n.icons.clear)), null, 16)
|
|
1609
1609
|
]),
|
|
1610
1610
|
_: 1
|
|
1611
1611
|
})) : q("", !0),
|
|
1612
|
-
n.readonly ? q("", !0) : (
|
|
1612
|
+
n.readonly ? q("", !0) : (u(), D(b(he), {
|
|
1613
1613
|
key: 1,
|
|
1614
1614
|
ref_key: "toggleRef",
|
|
1615
1615
|
ref: x,
|
|
@@ -1620,8 +1620,8 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1620
1620
|
disabled: n.disabled,
|
|
1621
1621
|
onMousedown: ue(G, ["stop", "prevent"])
|
|
1622
1622
|
}, {
|
|
1623
|
-
default:
|
|
1624
|
-
Q(b(ne),
|
|
1623
|
+
default: w(() => [
|
|
1624
|
+
Q(b(ne), se(fe(n.icons.chevron)), null, 16)
|
|
1625
1625
|
]),
|
|
1626
1626
|
_: 1
|
|
1627
1627
|
}, 8, ["disabled"]))
|
|
@@ -1630,14 +1630,14 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1630
1630
|
}, [
|
|
1631
1631
|
r.$slots.prepend ? {
|
|
1632
1632
|
name: "prepend",
|
|
1633
|
-
fn:
|
|
1633
|
+
fn: w(() => [
|
|
1634
1634
|
h(r.$slots, "prepend")
|
|
1635
1635
|
]),
|
|
1636
1636
|
key: "0"
|
|
1637
1637
|
} : void 0,
|
|
1638
1638
|
r.$slots.extras ? {
|
|
1639
1639
|
name: "extras",
|
|
1640
|
-
fn:
|
|
1640
|
+
fn: w(() => [
|
|
1641
1641
|
h(r.$slots, "extras")
|
|
1642
1642
|
]),
|
|
1643
1643
|
key: "1"
|
|
@@ -1652,14 +1652,14 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1652
1652
|
placement: "bottom-start",
|
|
1653
1653
|
width: "anchor",
|
|
1654
1654
|
offset: 4,
|
|
1655
|
-
anchor: (
|
|
1655
|
+
anchor: (E = v.value) == null ? void 0 : E.$el,
|
|
1656
1656
|
onEnter: y,
|
|
1657
|
-
onLeave:
|
|
1657
|
+
onLeave: re
|
|
1658
1658
|
}, {
|
|
1659
|
-
default:
|
|
1659
|
+
default: w(() => {
|
|
1660
1660
|
var O;
|
|
1661
1661
|
return [
|
|
1662
|
-
|
|
1662
|
+
le("div", {
|
|
1663
1663
|
ref_key: "contentRef",
|
|
1664
1664
|
ref: z,
|
|
1665
1665
|
class: "q-select__body",
|
|
@@ -1668,16 +1668,16 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1668
1668
|
onFocusout: P
|
|
1669
1669
|
}, [
|
|
1670
1670
|
h(r.$slots, "body.prepend"),
|
|
1671
|
-
n.loading ? (
|
|
1671
|
+
n.loading ? (u(), m("div", fo, [
|
|
1672
1672
|
Q(b(Se), { size: 24 })
|
|
1673
|
-
])) : I.value.length ? (
|
|
1673
|
+
])) : I.value.length ? (u(), D(b(Re), {
|
|
1674
1674
|
key: 1,
|
|
1675
1675
|
ref_key: "listRef",
|
|
1676
1676
|
ref: $,
|
|
1677
1677
|
class: "q-select__items",
|
|
1678
1678
|
modelValue: s.value,
|
|
1679
1679
|
"onUpdate:modelValue": [
|
|
1680
|
-
_[1] || (_[1] = (
|
|
1680
|
+
_[1] || (_[1] = (de) => s.value = de),
|
|
1681
1681
|
Z
|
|
1682
1682
|
],
|
|
1683
1683
|
highlighted: (O = Y.value) == null ? void 0 : O[n.itemValue],
|
|
@@ -1687,11 +1687,11 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1687
1687
|
"item-value": n.itemValue,
|
|
1688
1688
|
onMouseup: ge
|
|
1689
1689
|
}, {
|
|
1690
|
-
item:
|
|
1691
|
-
h(r.$slots, "item", { item:
|
|
1690
|
+
item: w(({ item: de }) => [
|
|
1691
|
+
h(r.$slots, "item", { item: de })
|
|
1692
1692
|
]),
|
|
1693
1693
|
_: 3
|
|
1694
|
-
}, 8, ["modelValue", "highlighted", "items", "groups", "item-label", "item-value"])) : (
|
|
1694
|
+
}, 8, ["modelValue", "highlighted", "items", "groups", "item-label", "item-value"])) : (u(), m("div", po, R(r.texts.noData), 1)),
|
|
1695
1695
|
h(r.$slots, "body.append")
|
|
1696
1696
|
], 40, co)
|
|
1697
1697
|
];
|
|
@@ -1701,7 +1701,7 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1701
1701
|
], 64);
|
|
1702
1702
|
};
|
|
1703
1703
|
}
|
|
1704
|
-
}),
|
|
1704
|
+
}), Go = S(ho), yo = {
|
|
1705
1705
|
key: 0,
|
|
1706
1706
|
class: "q-input-group__prepend"
|
|
1707
1707
|
}, bo = { key: 0 }, go = {
|
|
@@ -1724,24 +1724,24 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1724
1724
|
QField: {
|
|
1725
1725
|
size: "block"
|
|
1726
1726
|
}
|
|
1727
|
-
}), (e, n) => (
|
|
1727
|
+
}), (e, n) => (u(), D(b(Be), {
|
|
1728
1728
|
id: o.id,
|
|
1729
|
-
class:
|
|
1729
|
+
class: C(["q-input-group", o.class]),
|
|
1730
1730
|
label: o.label,
|
|
1731
1731
|
required: o.required,
|
|
1732
1732
|
size: o.size
|
|
1733
1733
|
}, we({
|
|
1734
|
-
default:
|
|
1735
|
-
e.$slots.prepend || o.prependIcon ? (
|
|
1736
|
-
o.prependIcon ? (
|
|
1737
|
-
Q(b(ne),
|
|
1734
|
+
default: w(() => [
|
|
1735
|
+
e.$slots.prepend || o.prependIcon ? (u(), m("div", yo, [
|
|
1736
|
+
o.prependIcon ? (u(), m("span", bo, [
|
|
1737
|
+
Q(b(ne), se(fe(o.prependIcon)), null, 16)
|
|
1738
1738
|
])) : q("", !0),
|
|
1739
1739
|
h(e.$slots, "prepend")
|
|
1740
1740
|
])) : q("", !0),
|
|
1741
1741
|
h(e.$slots, "default"),
|
|
1742
|
-
e.$slots.append || o.appendIcon ? (
|
|
1743
|
-
o.appendIcon ? (
|
|
1744
|
-
Q(b(ne),
|
|
1742
|
+
e.$slots.append || o.appendIcon ? (u(), m("div", go, [
|
|
1743
|
+
o.appendIcon ? (u(), m("span", _o, [
|
|
1744
|
+
Q(b(ne), se(fe(o.appendIcon)), null, 16)
|
|
1745
1745
|
])) : q("", !0),
|
|
1746
1746
|
h(e.$slots, "append")
|
|
1747
1747
|
])) : q("", !0)
|
|
@@ -1750,25 +1750,25 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1750
1750
|
}, [
|
|
1751
1751
|
e.$slots.extras ? {
|
|
1752
1752
|
name: "extras",
|
|
1753
|
-
fn:
|
|
1753
|
+
fn: w(() => [
|
|
1754
1754
|
h(e.$slots, "extras")
|
|
1755
1755
|
]),
|
|
1756
1756
|
key: "0"
|
|
1757
1757
|
} : void 0
|
|
1758
1758
|
]), 1032, ["id", "class", "label", "required", "size"]));
|
|
1759
1759
|
}
|
|
1760
|
-
}),
|
|
1760
|
+
}), Wo = S(ko), wo = /* @__PURE__ */ L({
|
|
1761
1761
|
__name: "QLineLoader",
|
|
1762
1762
|
props: {
|
|
1763
1763
|
class: { default: void 0 }
|
|
1764
1764
|
},
|
|
1765
1765
|
setup(t) {
|
|
1766
1766
|
const o = t;
|
|
1767
|
-
return (e, n) => (
|
|
1768
|
-
class:
|
|
1767
|
+
return (e, n) => (u(), m("div", {
|
|
1768
|
+
class: C(["q-line-loader", o.class])
|
|
1769
1769
|
}, null, 2));
|
|
1770
1770
|
}
|
|
1771
|
-
}),
|
|
1771
|
+
}), jo = S(wo), $o = {
|
|
1772
1772
|
key: 0,
|
|
1773
1773
|
class: "q-popover__header"
|
|
1774
1774
|
}, qo = {
|
|
@@ -1793,7 +1793,7 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1793
1793
|
emits: ["update:modelValue"],
|
|
1794
1794
|
setup(t) {
|
|
1795
1795
|
const o = t, e = te(t, "modelValue");
|
|
1796
|
-
return (n, l) => (
|
|
1796
|
+
return (n, l) => (u(), D(b($e), {
|
|
1797
1797
|
"model-value": e.value,
|
|
1798
1798
|
class: "q-popover",
|
|
1799
1799
|
trigger: "click",
|
|
@@ -1803,23 +1803,23 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1803
1803
|
disabled: o.disabled,
|
|
1804
1804
|
placement: o.placement
|
|
1805
1805
|
}, {
|
|
1806
|
-
default:
|
|
1807
|
-
o.title || n.$slots.header ? (
|
|
1806
|
+
default: w(() => [
|
|
1807
|
+
o.title || n.$slots.header ? (u(), m("h3", $o, [
|
|
1808
1808
|
me(R(o.title) + " ", 1),
|
|
1809
1809
|
h(n.$slots, "header")
|
|
1810
1810
|
])) : q("", !0),
|
|
1811
|
-
o.text || n.$slots.body ? (
|
|
1812
|
-
o.html ? (
|
|
1811
|
+
o.text || n.$slots.body ? (u(), m("div", qo, [
|
|
1812
|
+
o.html ? (u(), m("span", {
|
|
1813
1813
|
key: 0,
|
|
1814
1814
|
innerHTML: o.text
|
|
1815
|
-
}, null, 8, Io)) : (
|
|
1815
|
+
}, null, 8, Io)) : (u(), m("span", xo, R(o.text), 1)),
|
|
1816
1816
|
h(n.$slots, "body")
|
|
1817
1817
|
])) : q("", !0)
|
|
1818
1818
|
]),
|
|
1819
1819
|
_: 3
|
|
1820
1820
|
}, 8, ["model-value", "anchor", "arrow", "attach", "disabled", "placement"]));
|
|
1821
1821
|
}
|
|
1822
|
-
}),
|
|
1822
|
+
}), Ro = S(Lo), So = {
|
|
1823
1823
|
key: 0,
|
|
1824
1824
|
class: "q-select__value"
|
|
1825
1825
|
}, Bo = {
|
|
@@ -1864,21 +1864,21 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1864
1864
|
}),
|
|
1865
1865
|
emits: /* @__PURE__ */ X(["before-show", "before-hide", "show", "hide"], ["update:modelValue"]),
|
|
1866
1866
|
setup(t, { emit: o }) {
|
|
1867
|
-
const e = t, n = o, l = te(t, "modelValue"), s =
|
|
1867
|
+
const e = t, n = o, l = te(t, "modelValue"), s = V(!1), i = V(""), a = V(null), c = V(null), v = V(null), $ = k(() => x.value === void 0), x = k(
|
|
1868
1868
|
() => {
|
|
1869
1869
|
var d;
|
|
1870
1870
|
return (d = e.items) == null ? void 0 : d.find((p) => p[e.itemValue] === l.value);
|
|
1871
1871
|
}
|
|
1872
|
-
), z =
|
|
1872
|
+
), z = k(
|
|
1873
1873
|
() => x.value ? x.value[e.itemLabel] : ""
|
|
1874
|
-
),
|
|
1874
|
+
), T = k(
|
|
1875
1875
|
() => e.clearable && !e.readonly && !e.disabled && !e.loading
|
|
1876
1876
|
);
|
|
1877
1877
|
function I(d) {
|
|
1878
1878
|
l.value = d, H();
|
|
1879
1879
|
}
|
|
1880
|
-
function
|
|
1881
|
-
|
|
1880
|
+
function B() {
|
|
1881
|
+
T.value && I(e.emptyValue);
|
|
1882
1882
|
}
|
|
1883
1883
|
function K(d) {
|
|
1884
1884
|
var p, F, ee;
|
|
@@ -1896,7 +1896,7 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1896
1896
|
let Z;
|
|
1897
1897
|
function U(d) {
|
|
1898
1898
|
if (!(!d.key || e.readonly || e.disabled)) {
|
|
1899
|
-
if (window.clearTimeout(Z), ["Enter", " ", "ArrowDown", "ArrowUp", "Home", "End"].includes(d.key) && (d.preventDefault(), d.stopPropagation()), ["Enter", " "].includes(d.key) && (s.value = !0), ["Escape", "Tab"].includes(d.key) && (s.value ? s.value = !1 :
|
|
1899
|
+
if (window.clearTimeout(Z), ["Enter", " ", "ArrowDown", "ArrowUp", "Home", "End"].includes(d.key) && (d.preventDefault(), d.stopPropagation()), ["Enter", " "].includes(d.key) && (s.value = !0), ["Escape", "Tab"].includes(d.key) && (s.value ? s.value = !1 : T.value && d.key === "Escape" && B()), d.key === "Delete" && e.clearable && B(), /^[a-z]$/i.test(d.key)) {
|
|
1900
1900
|
i.value += d.key.toLowerCase();
|
|
1901
1901
|
for (let p = 0; p < e.items.length; p++)
|
|
1902
1902
|
if (e.items[p][e.itemLabel].toLowerCase().startsWith(i.value)) {
|
|
@@ -1922,11 +1922,11 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1922
1922
|
}
|
|
1923
1923
|
function f() {
|
|
1924
1924
|
var d;
|
|
1925
|
-
(d =
|
|
1925
|
+
(d = c.value) == null || d.$el.focus();
|
|
1926
1926
|
}
|
|
1927
1927
|
function g(d) {
|
|
1928
1928
|
var p;
|
|
1929
|
-
(p =
|
|
1929
|
+
(p = c.value) == null || p.focusItem(d);
|
|
1930
1930
|
}
|
|
1931
1931
|
return W(
|
|
1932
1932
|
() => e.loading,
|
|
@@ -1935,7 +1935,7 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1935
1935
|
}
|
|
1936
1936
|
), (d, p) => {
|
|
1937
1937
|
var F, ee;
|
|
1938
|
-
return
|
|
1938
|
+
return u(), m(ae, null, [
|
|
1939
1939
|
Q(b(Be), {
|
|
1940
1940
|
id: e.id,
|
|
1941
1941
|
label: e.label,
|
|
@@ -1944,7 +1944,7 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1944
1944
|
ref: a,
|
|
1945
1945
|
role: "combobox",
|
|
1946
1946
|
tabindex: e.disabled ? -1 : 0,
|
|
1947
|
-
class:
|
|
1947
|
+
class: C([
|
|
1948
1948
|
"q-select",
|
|
1949
1949
|
{
|
|
1950
1950
|
"q-select--readonly": e.readonly,
|
|
@@ -1962,22 +1962,22 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1962
1962
|
onClick: M,
|
|
1963
1963
|
onKeydown: ue(U, ["stop"])
|
|
1964
1964
|
}, we({
|
|
1965
|
-
append:
|
|
1965
|
+
append: w(() => [
|
|
1966
1966
|
h(d.$slots, "append"),
|
|
1967
|
-
|
|
1967
|
+
T.value && l.value ? (u(), D(b(he), {
|
|
1968
1968
|
key: 0,
|
|
1969
1969
|
class: "q-select__clear",
|
|
1970
1970
|
"b-style": "plain",
|
|
1971
1971
|
borderless: "",
|
|
1972
1972
|
tabindex: "-1",
|
|
1973
|
-
onClick:
|
|
1973
|
+
onClick: B
|
|
1974
1974
|
}, {
|
|
1975
|
-
default:
|
|
1976
|
-
Q(b(ne),
|
|
1975
|
+
default: w(() => [
|
|
1976
|
+
Q(b(ne), se(fe(e.icons.clear)), null, 16)
|
|
1977
1977
|
]),
|
|
1978
1978
|
_: 1
|
|
1979
1979
|
})) : q("", !0),
|
|
1980
|
-
e.readonly ? q("", !0) : (
|
|
1980
|
+
e.readonly ? q("", !0) : (u(), D(b(he), {
|
|
1981
1981
|
key: 1,
|
|
1982
1982
|
class: "q-select__chevron",
|
|
1983
1983
|
"b-style": "plain",
|
|
@@ -1986,35 +1986,35 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
1986
1986
|
disabled: e.disabled,
|
|
1987
1987
|
onClick: M
|
|
1988
1988
|
}, {
|
|
1989
|
-
default:
|
|
1990
|
-
Q(b(ne),
|
|
1989
|
+
default: w(() => [
|
|
1990
|
+
Q(b(ne), se(fe(e.icons.chevron)), null, 16)
|
|
1991
1991
|
]),
|
|
1992
1992
|
_: 1
|
|
1993
1993
|
}, 8, ["disabled"]))
|
|
1994
1994
|
]),
|
|
1995
|
-
default:
|
|
1996
|
-
$.value ? (
|
|
1997
|
-
!e.readonly && !e.disabled ? (
|
|
1995
|
+
default: w(() => [
|
|
1996
|
+
$.value ? (u(), m("span", Bo, [
|
|
1997
|
+
!e.readonly && !e.disabled ? (u(), m(ae, { key: 0 }, [
|
|
1998
1998
|
me(R(d.texts.placeholder), 1)
|
|
1999
1999
|
], 64)) : q("", !0)
|
|
2000
|
-
])) : (
|
|
2000
|
+
])) : (u(), m("span", So, R(z.value), 1))
|
|
2001
2001
|
]),
|
|
2002
2002
|
_: 2
|
|
2003
2003
|
}, [
|
|
2004
2004
|
(F = x.value) != null && F.icon || d.$slots.prepend ? {
|
|
2005
2005
|
name: "prepend",
|
|
2006
|
-
fn:
|
|
2006
|
+
fn: w(() => {
|
|
2007
2007
|
var P, oe;
|
|
2008
2008
|
return [
|
|
2009
2009
|
h(d.$slots, "prepend"),
|
|
2010
|
-
(P = x.value) != null && P.icon ? (
|
|
2010
|
+
(P = x.value) != null && P.icon ? (u(), D(b(ne), se(ce({ key: 0 }, (oe = x.value) == null ? void 0 : oe.icon)), null, 16)) : q("", !0)
|
|
2011
2011
|
];
|
|
2012
2012
|
}),
|
|
2013
2013
|
key: "0"
|
|
2014
2014
|
} : void 0,
|
|
2015
2015
|
d.$slots.extras ? {
|
|
2016
2016
|
name: "extras",
|
|
2017
|
-
fn:
|
|
2017
|
+
fn: w(() => [
|
|
2018
2018
|
h(d.$slots, "extras")
|
|
2019
2019
|
]),
|
|
2020
2020
|
key: "1"
|
|
@@ -2033,8 +2033,8 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
2033
2033
|
onEnter: J,
|
|
2034
2034
|
onLeave: A
|
|
2035
2035
|
}, {
|
|
2036
|
-
default:
|
|
2037
|
-
|
|
2036
|
+
default: w(() => [
|
|
2037
|
+
le("div", {
|
|
2038
2038
|
ref_key: "contentRef",
|
|
2039
2039
|
ref: v,
|
|
2040
2040
|
"data-testid": "combobox-dropdown",
|
|
@@ -2045,12 +2045,12 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
2045
2045
|
onKeydown: ue(U, ["stop"])
|
|
2046
2046
|
}, [
|
|
2047
2047
|
h(d.$slots, "body.prepend"),
|
|
2048
|
-
e.loading ? (
|
|
2048
|
+
e.loading ? (u(), m("div", Co, [
|
|
2049
2049
|
Q(b(Se), { size: 24 })
|
|
2050
|
-
])) : (
|
|
2050
|
+
])) : (u(), D(b(Re), {
|
|
2051
2051
|
key: 1,
|
|
2052
2052
|
ref_key: "listRef",
|
|
2053
|
-
ref:
|
|
2053
|
+
ref: c,
|
|
2054
2054
|
class: "q-select__items",
|
|
2055
2055
|
modelValue: l.value,
|
|
2056
2056
|
"onUpdate:modelValue": [
|
|
@@ -2062,7 +2062,7 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
2062
2062
|
"item-label": e.itemLabel,
|
|
2063
2063
|
"item-value": e.itemValue
|
|
2064
2064
|
}, {
|
|
2065
|
-
item:
|
|
2065
|
+
item: w(({ item: P }) => [
|
|
2066
2066
|
h(d.$slots, "item", { item: P })
|
|
2067
2067
|
]),
|
|
2068
2068
|
_: 3
|
|
@@ -2075,20 +2075,42 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
2075
2075
|
], 64);
|
|
2076
2076
|
};
|
|
2077
2077
|
}
|
|
2078
|
-
}),
|
|
2078
|
+
}), Xo = S(Do), Ao = /* @__PURE__ */ le("div", { class: "q-skeleton-loader__bone" }, null, -1), zo = [
|
|
2079
|
+
Ao
|
|
2080
|
+
], Qo = /* @__PURE__ */ L({
|
|
2081
|
+
__name: "QSkeletonLoader",
|
|
2082
|
+
props: {
|
|
2083
|
+
type: { default: void 0 },
|
|
2084
|
+
width: { default: void 0 },
|
|
2085
|
+
height: { default: void 0 }
|
|
2086
|
+
},
|
|
2087
|
+
setup(t) {
|
|
2088
|
+
const o = t, e = k(() => o.type ? `q-skeleton-loader--${o.type}` : void 0), n = k(() => {
|
|
2089
|
+
const l = typeof o.width == "number" ? `${o.width}px` : o.width, s = typeof o.height == "number" ? `${o.height}px` : o.height;
|
|
2090
|
+
return {
|
|
2091
|
+
width: l,
|
|
2092
|
+
height: s
|
|
2093
|
+
};
|
|
2094
|
+
});
|
|
2095
|
+
return (l, s) => (u(), m("div", {
|
|
2096
|
+
class: C(["q-skeleton-loader", e.value]),
|
|
2097
|
+
style: ie(n.value)
|
|
2098
|
+
}, zo, 6));
|
|
2099
|
+
}
|
|
2100
|
+
}), Yo = S(Qo), Mo = /* @__PURE__ */ L({
|
|
2079
2101
|
__name: "QThemeProvider",
|
|
2080
2102
|
props: {
|
|
2081
2103
|
theme: {}
|
|
2082
2104
|
},
|
|
2083
2105
|
setup(t) {
|
|
2084
2106
|
const o = t;
|
|
2085
|
-
return (e, n) => (
|
|
2086
|
-
class:
|
|
2107
|
+
return (e, n) => (u(), m("div", {
|
|
2108
|
+
class: C(["q-theme-provider", `q-theme--${o.theme}`])
|
|
2087
2109
|
}, [
|
|
2088
2110
|
h(e.$slots, "default")
|
|
2089
2111
|
], 2));
|
|
2090
2112
|
}
|
|
2091
|
-
}),
|
|
2113
|
+
}), Zo = S(Mo), Fo = ["innerHTML"], Oo = { key: 1 }, Uo = /* @__PURE__ */ L({
|
|
2092
2114
|
__name: "QTooltip",
|
|
2093
2115
|
props: /* @__PURE__ */ X({
|
|
2094
2116
|
id: { default: void 0 },
|
|
@@ -2110,7 +2132,7 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
2110
2132
|
emits: ["update:modelValue"],
|
|
2111
2133
|
setup(t) {
|
|
2112
2134
|
const o = t, e = te(t, "modelValue"), n = ye(o.id);
|
|
2113
|
-
return (l, s) => (
|
|
2135
|
+
return (l, s) => (u(), m(ae, null, [
|
|
2114
2136
|
h(l.$slots, "anchor", {
|
|
2115
2137
|
props: { "aria-describedby": b(n) }
|
|
2116
2138
|
}),
|
|
@@ -2123,49 +2145,50 @@ const Zt = ["role"], Jt = /* @__PURE__ */ L({
|
|
|
2123
2145
|
appearance: o.appearance,
|
|
2124
2146
|
arrow: o.arrow,
|
|
2125
2147
|
attach: o.attach,
|
|
2126
|
-
class:
|
|
2148
|
+
class: C(["q-tooltip", o.class]),
|
|
2127
2149
|
delay: o.delay,
|
|
2128
2150
|
disabled: o.disabled,
|
|
2129
2151
|
placement: o.placement,
|
|
2130
2152
|
trigger: o.trigger
|
|
2131
2153
|
}, {
|
|
2132
|
-
default:
|
|
2133
|
-
o.html ? (
|
|
2154
|
+
default: w(() => [
|
|
2155
|
+
o.html ? (u(), m("span", {
|
|
2134
2156
|
key: 0,
|
|
2135
2157
|
innerHTML: o.text
|
|
2136
|
-
}, null, 8,
|
|
2158
|
+
}, null, 8, Fo)) : (u(), m("span", Oo, R(o.text), 1))
|
|
2137
2159
|
]),
|
|
2138
2160
|
_: 1
|
|
2139
2161
|
}, 8, ["model-value", "anchor", "id", "appearance", "arrow", "attach", "class", "delay", "disabled", "placement", "trigger"])
|
|
2140
2162
|
], 64));
|
|
2141
2163
|
}
|
|
2142
|
-
}),
|
|
2164
|
+
}), Jo = S(Uo);
|
|
2143
2165
|
export {
|
|
2144
2166
|
he as QButton,
|
|
2145
2167
|
bt as QButtonGroup,
|
|
2146
|
-
|
|
2147
|
-
|
|
2168
|
+
Ko as QButtonToggle,
|
|
2169
|
+
Go as QCombobox,
|
|
2148
2170
|
Be as QField,
|
|
2149
2171
|
ne as QIcon,
|
|
2150
2172
|
St as QIconFont,
|
|
2151
2173
|
Bt as QIconImg,
|
|
2152
2174
|
Vt as QIconSvg,
|
|
2153
|
-
|
|
2154
|
-
|
|
2175
|
+
Wo as QInputGroup,
|
|
2176
|
+
jo as QLineLoader,
|
|
2155
2177
|
Re as QList,
|
|
2156
2178
|
Ot as QListItem,
|
|
2157
2179
|
Ut as QListItemGroup,
|
|
2158
2180
|
$e as QOverlay,
|
|
2159
|
-
|
|
2160
|
-
|
|
2181
|
+
Ro as QPopover,
|
|
2182
|
+
Xo as QSelect,
|
|
2183
|
+
Yo as QSkeletonLoader,
|
|
2161
2184
|
Se as QSpinnerLoader,
|
|
2162
2185
|
uo as QTextField,
|
|
2163
|
-
|
|
2164
|
-
|
|
2165
|
-
|
|
2186
|
+
Zo as QThemeProvider,
|
|
2187
|
+
Jo as QTooltip,
|
|
2188
|
+
Ho as createFramework,
|
|
2166
2189
|
lt as defaultDarkColorScheme,
|
|
2167
2190
|
Qe as defaultLightColorScheme,
|
|
2168
|
-
|
|
2191
|
+
No as provideTheme,
|
|
2169
2192
|
nt as useTheme
|
|
2170
2193
|
};
|
|
2171
2194
|
//# sourceMappingURL=ui.esm.js.map
|