@quidgest/ui 0.12.1 → 0.12.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ui.esm.js +461 -477
- package/dist/ui.js +5 -5
- package/dist/ui.min.js +95 -106
- package/dist/ui.scss +1 -1
- package/esm/components/QButton/QButton.vue.js +14 -15
- package/esm/components/QButton/index.d.ts +196 -2
- package/esm/components/QButton/index.d.ts.map +1 -1
- package/esm/components/QButton/index.js +6 -0
- package/esm/components/QButtonGroup/index.d.ts +79 -2
- package/esm/components/QButtonGroup/index.d.ts.map +1 -1
- package/esm/components/QButtonGroup/index.js +6 -0
- package/esm/components/QButtonToggle/QButtonToggle.vue.js +17 -17
- package/esm/components/QButtonToggle/index.d.ts +115 -2
- package/esm/components/QButtonToggle/index.d.ts.map +1 -1
- package/esm/components/QButtonToggle/index.js +6 -0
- package/esm/components/QCombobox/QCombobox.vue.js +106 -111
- package/esm/components/QCombobox/index.d.ts +1083 -2
- package/esm/components/QCombobox/index.d.ts.map +1 -1
- package/esm/components/QCombobox/index.js +6 -0
- package/esm/components/QField/index.d.ts +168 -1
- package/esm/components/QField/index.d.ts.map +1 -1
- package/esm/components/QField/index.js +2 -2
- package/esm/components/QIcon/QIcon.vue.js +9 -12
- package/esm/components/QIcon/index.d.ts +156 -4
- package/esm/components/QIcon/index.d.ts.map +1 -1
- package/esm/components/QIcon/index.js +8 -11
- package/esm/components/QInputGroup/QInputGroup.vue.js +25 -27
- package/esm/components/QInputGroup/index.d.ts +153 -2
- package/esm/components/QInputGroup/index.d.ts.map +1 -1
- package/esm/components/QInputGroup/index.js +6 -0
- package/esm/components/QLineLoader/index.d.ts +13 -2
- package/esm/components/QLineLoader/index.d.ts.map +1 -1
- package/esm/components/QLineLoader/index.js +6 -0
- package/esm/components/QList/QList.vue.js +43 -45
- package/esm/components/QList/QListItem.vue.js +9 -10
- package/esm/components/QList/index.d.ts +418 -3
- package/esm/components/QList/index.d.ts.map +1 -1
- package/esm/components/QList/index.js +8 -10
- package/esm/components/QOverlay/index.d.ts +320 -2
- package/esm/components/QOverlay/index.d.ts.map +1 -1
- package/esm/components/QOverlay/index.js +4 -4
- package/esm/components/QPopover/QPopover.vue.js +11 -12
- package/esm/components/QPopover/index.d.ts +180 -2
- package/esm/components/QPopover/index.d.ts.map +1 -1
- package/esm/components/QPopover/index.js +6 -0
- package/esm/components/QSelect/QSelect.vue.js +68 -73
- package/esm/components/QSelect/index.d.ts +377 -2
- package/esm/components/QSelect/index.d.ts.map +1 -1
- package/esm/components/QSelect/index.js +6 -0
- package/esm/components/QSkeletonLoader/index.d.ts +31 -2
- package/esm/components/QSkeletonLoader/index.d.ts.map +1 -1
- package/esm/components/QSkeletonLoader/index.js +6 -0
- package/esm/components/QSpinnerLoader/index.d.ts +22 -2
- package/esm/components/QSpinnerLoader/index.d.ts.map +1 -1
- package/esm/components/QSpinnerLoader/index.js +4 -4
- package/esm/components/QTextField/QTextField.vue.js +7 -8
- package/esm/components/QTextField/index.d.ts +229 -2
- package/esm/components/QTextField/index.d.ts.map +1 -1
- package/esm/components/QTextField/index.js +2 -2
- package/esm/components/QThemeProvider/index.d.ts +37 -2
- package/esm/components/QThemeProvider/index.d.ts.map +1 -1
- package/esm/components/QThemeProvider/index.js +6 -0
- package/esm/components/QTooltip/QTooltip.vue.js +8 -9
- package/esm/components/QTooltip/index.d.ts +259 -2
- package/esm/components/QTooltip/index.d.ts.map +1 -1
- package/esm/components/QTooltip/index.js +6 -0
- package/esm/components/index.js +39 -44
- package/esm/composables/defaults.js +5 -5
- package/package.json +1 -1
package/dist/ui.esm.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { defineComponent as L, computed as k, openBlock as u, createElementBlock as m, normalizeClass as
|
|
1
|
+
import { defineComponent as L, computed as k, openBlock as u, createElementBlock as m, normalizeClass as C, normalizeStyle as ie, getCurrentInstance as Ue, ref as V, provide as Ne, inject as He, withModifiers as ce, createVNode as Q, unref as y, createCommentVNode as q, createElementVNode as K, Fragment as se, createTextVNode as ve, toDisplayString as j, renderSlot as h, toRef as Ae, mergeModels as Z, useModel as ne, createBlock as D, withCtx as w, renderList as xe, resolveDynamicComponent as Ke, h as ze, normalizeProps as ae, mergeProps as fe, guardReactiveProps as re, reactive as Qe, watch as R, nextTick as X, onMounted as je, onBeforeUnmount as lt, Teleport as at, Transition as st, withKeys as it, createSlots as $e, withDirectives as rt, vModelDynamic as dt } from "vue";
|
|
2
2
|
/*!
|
|
3
|
-
* Quidgest UI v0.12.
|
|
3
|
+
* Quidgest UI v0.12.2
|
|
4
4
|
* (c) 2024 Quidgest - Consultores de Gestão, S.A.
|
|
5
5
|
* Released under the MIT License.
|
|
6
6
|
*/
|
|
7
|
-
const
|
|
7
|
+
const Le = {
|
|
8
8
|
primary: "#008ad2",
|
|
9
9
|
primaryLight: "#cde5ff",
|
|
10
10
|
primaryDark: "#006398",
|
|
@@ -35,7 +35,7 @@ const Se = {
|
|
|
35
35
|
onWarning: "#fff",
|
|
36
36
|
onDanger: "#fff",
|
|
37
37
|
onInfo: "#fff"
|
|
38
|
-
},
|
|
38
|
+
}, Ge = {
|
|
39
39
|
primary: "#009ff5",
|
|
40
40
|
primaryLight: "#ade2ff",
|
|
41
41
|
primaryDark: "#164965",
|
|
@@ -66,11 +66,11 @@ const Se = {
|
|
|
66
66
|
onWarning: "#fff",
|
|
67
67
|
onDanger: "#fff",
|
|
68
68
|
onInfo: "#fff"
|
|
69
|
-
},
|
|
69
|
+
}, nn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
70
70
|
__proto__: null,
|
|
71
|
-
defaultDarkColorScheme:
|
|
72
|
-
defaultLightColorScheme:
|
|
73
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
71
|
+
defaultDarkColorScheme: Ge,
|
|
72
|
+
defaultLightColorScheme: Le
|
|
73
|
+
}, Symbol.toStringTag, { value: "Module" })), ut = /* @__PURE__ */ L({
|
|
74
74
|
__name: "QSpinnerLoader",
|
|
75
75
|
props: {
|
|
76
76
|
size: { default: 48 },
|
|
@@ -81,25 +81,25 @@ const Se = {
|
|
|
81
81
|
"font-size": o.size !== 48 ? `${o.size}px` : void 0
|
|
82
82
|
}));
|
|
83
83
|
return (n, l) => (u(), m("div", {
|
|
84
|
-
class:
|
|
84
|
+
class: C(["q-spinner-loader", o.class]),
|
|
85
85
|
style: ie(e.value)
|
|
86
86
|
}, null, 6));
|
|
87
87
|
}
|
|
88
88
|
});
|
|
89
|
-
function
|
|
89
|
+
function Se(t) {
|
|
90
90
|
return t == null ? !0 : typeof t == "string" || Array.isArray(t) ? t.length === 0 : typeof t == "object" ? Object.keys(t).length === 0 : !1;
|
|
91
91
|
}
|
|
92
|
-
function
|
|
92
|
+
function Me(t) {
|
|
93
93
|
return t !== null && typeof t == "object" && !Array.isArray(t);
|
|
94
94
|
}
|
|
95
|
-
function
|
|
95
|
+
function Be(t = {}, o = {}) {
|
|
96
96
|
const e = {};
|
|
97
97
|
for (const n in t)
|
|
98
98
|
e[n] = t[n];
|
|
99
99
|
for (const n in o) {
|
|
100
100
|
const l = t[n], s = o[n];
|
|
101
|
-
if (
|
|
102
|
-
e[n] =
|
|
101
|
+
if (Me(l) && Me(s)) {
|
|
102
|
+
e[n] = Be(
|
|
103
103
|
l,
|
|
104
104
|
s
|
|
105
105
|
);
|
|
@@ -109,62 +109,61 @@ function Ve(t = {}, o = {}) {
|
|
|
109
109
|
}
|
|
110
110
|
return e;
|
|
111
111
|
}
|
|
112
|
-
const
|
|
113
|
-
function
|
|
112
|
+
const Ve = "q-defaults";
|
|
113
|
+
function ct() {
|
|
114
114
|
var s, i;
|
|
115
|
-
const t =
|
|
115
|
+
const t = Ue();
|
|
116
116
|
if (!t)
|
|
117
117
|
throw new Error("[Quidgest UI] useDefaults must be called from inside a setup function");
|
|
118
118
|
const o = t.type.name ?? t.type.__name;
|
|
119
119
|
if (!o)
|
|
120
120
|
throw new Error("[Quidgest UI] Could not determine component name");
|
|
121
|
-
const e =
|
|
122
|
-
return k(() =>
|
|
121
|
+
const e = Re(), n = (s = e.value) == null ? void 0 : s.Global, l = (i = e.value) == null ? void 0 : i[o];
|
|
122
|
+
return k(() => Be(n, l));
|
|
123
123
|
}
|
|
124
|
-
function
|
|
125
|
-
if (
|
|
124
|
+
function We(t) {
|
|
125
|
+
if (Se(t))
|
|
126
126
|
return;
|
|
127
|
-
const o =
|
|
128
|
-
|
|
127
|
+
const o = Re(), e = V(t), n = k(() => Se(e.value) ? o.value : Be(o.value, e.value));
|
|
128
|
+
Ne(Ve, n);
|
|
129
129
|
}
|
|
130
|
-
function
|
|
131
|
-
const t =
|
|
130
|
+
function Re() {
|
|
131
|
+
const t = He(Ve, void 0);
|
|
132
132
|
if (!t)
|
|
133
133
|
throw new Error("[Quidgest UI] Could not find defaults instance");
|
|
134
134
|
return t;
|
|
135
135
|
}
|
|
136
|
-
function
|
|
136
|
+
function Xe(t) {
|
|
137
137
|
return t.replace(/([a-z])([A-Z])/g, "$1-$2").replace(/([0-9])([A-Za-z])/g, "$1-$2").replace(/([A-Za-z])([0-9])/g, "$1-$2").toLowerCase();
|
|
138
138
|
}
|
|
139
|
-
function
|
|
139
|
+
function ft(t, o) {
|
|
140
140
|
var n;
|
|
141
|
-
const e =
|
|
141
|
+
const e = Xe(o);
|
|
142
142
|
return e ? typeof ((n = t.props) == null ? void 0 : n[e]) < "u" : !1;
|
|
143
143
|
}
|
|
144
|
-
function
|
|
144
|
+
function S(t) {
|
|
145
145
|
const o = t.setup;
|
|
146
146
|
return o && (t.setup = (e, n) => {
|
|
147
|
-
const l =
|
|
148
|
-
if (
|
|
147
|
+
const l = ct();
|
|
148
|
+
if (Se(l.value))
|
|
149
149
|
return o(e, n);
|
|
150
|
-
const s =
|
|
150
|
+
const s = Ue();
|
|
151
151
|
if (s === null)
|
|
152
152
|
return o(e, n);
|
|
153
153
|
const i = new Proxy(e, {
|
|
154
154
|
get(a, c) {
|
|
155
155
|
var x;
|
|
156
156
|
const v = Reflect.get(a, c), $ = (x = l.value) == null ? void 0 : x[c];
|
|
157
|
-
return typeof c == "string" && !
|
|
157
|
+
return typeof c == "string" && !ft(s.vnode, c) ? $ ?? v : v;
|
|
158
158
|
}
|
|
159
159
|
});
|
|
160
160
|
return o(i, n);
|
|
161
161
|
}), t;
|
|
162
162
|
}
|
|
163
|
-
|
|
164
|
-
const ft = ["disabled"], pt = {
|
|
163
|
+
const qe = S(ut), pt = ["disabled"], mt = {
|
|
165
164
|
key: 0,
|
|
166
165
|
class: "q-btn__spinner"
|
|
167
|
-
},
|
|
166
|
+
}, vt = { class: "q-btn__content" }, ht = /* @__PURE__ */ L({
|
|
168
167
|
__name: "QButton",
|
|
169
168
|
props: {
|
|
170
169
|
active: { type: Boolean },
|
|
@@ -203,25 +202,25 @@ const ft = ["disabled"], pt = {
|
|
|
203
202
|
});
|
|
204
203
|
return (a, c) => (u(), m("button", {
|
|
205
204
|
type: "button",
|
|
206
|
-
class:
|
|
205
|
+
class: C(i.value),
|
|
207
206
|
disabled: l.value,
|
|
208
207
|
onClick: ce(s, ["stop", "prevent"])
|
|
209
208
|
}, [
|
|
210
|
-
a.loading ? (u(), m("div",
|
|
211
|
-
|
|
209
|
+
a.loading ? (u(), m("div", mt, [
|
|
210
|
+
Q(y(qe), { size: 20 })
|
|
212
211
|
])) : q("", !0),
|
|
213
|
-
|
|
212
|
+
K("span", vt, [
|
|
214
213
|
a.iconOnRight ? (u(), m(se, { key: 0 }, [
|
|
215
|
-
|
|
214
|
+
ve(j(e.label), 1)
|
|
216
215
|
], 64)) : q("", !0),
|
|
217
216
|
h(a.$slots, "default"),
|
|
218
217
|
a.iconOnRight ? q("", !0) : (u(), m(se, { key: 1 }, [
|
|
219
|
-
|
|
218
|
+
ve(j(e.label), 1)
|
|
220
219
|
], 64))
|
|
221
220
|
])
|
|
222
|
-
], 10,
|
|
221
|
+
], 10, pt));
|
|
223
222
|
}
|
|
224
|
-
}),
|
|
223
|
+
}), pe = S(ht), yt = /* @__PURE__ */ L({
|
|
225
224
|
__name: "QButtonGroup",
|
|
226
225
|
props: {
|
|
227
226
|
disabled: { type: Boolean },
|
|
@@ -231,15 +230,15 @@ const ft = ["disabled"], pt = {
|
|
|
231
230
|
},
|
|
232
231
|
setup(t) {
|
|
233
232
|
const o = t;
|
|
234
|
-
return
|
|
233
|
+
return We({
|
|
235
234
|
QButton: {
|
|
236
235
|
bStyle: "secondary",
|
|
237
|
-
disabled:
|
|
238
|
-
borderless:
|
|
236
|
+
disabled: Ae(o, "disabled"),
|
|
237
|
+
borderless: Ae(o, "borderless"),
|
|
239
238
|
elevated: !1
|
|
240
239
|
}
|
|
241
240
|
}), (e, n) => (u(), m("div", {
|
|
242
|
-
class:
|
|
241
|
+
class: C([
|
|
243
242
|
"q-btn-group",
|
|
244
243
|
{
|
|
245
244
|
"q-btn-group--elevated": o.elevated
|
|
@@ -250,9 +249,9 @@ const ft = ["disabled"], pt = {
|
|
|
250
249
|
h(e.$slots, "default")
|
|
251
250
|
], 2));
|
|
252
251
|
}
|
|
253
|
-
}),
|
|
252
|
+
}), Ye = S(yt), bt = /* @__PURE__ */ L({
|
|
254
253
|
__name: "QButtonToggle",
|
|
255
|
-
props: /* @__PURE__ */
|
|
254
|
+
props: /* @__PURE__ */ Z({
|
|
256
255
|
options: {},
|
|
257
256
|
disabled: { type: Boolean },
|
|
258
257
|
borderless: { type: Boolean },
|
|
@@ -269,15 +268,15 @@ const ft = ["disabled"], pt = {
|
|
|
269
268
|
function n(l) {
|
|
270
269
|
e.value === l.key && !o.required ? e.value = void 0 : e.value = l.key;
|
|
271
270
|
}
|
|
272
|
-
return (l, s) => (u(),
|
|
271
|
+
return (l, s) => (u(), D(y(Ye), {
|
|
273
272
|
"b-style": "secondary",
|
|
274
|
-
class:
|
|
273
|
+
class: C(o.class),
|
|
275
274
|
disabled: o.disabled,
|
|
276
275
|
borderless: o.borderless,
|
|
277
276
|
elevated: o.elevated
|
|
278
277
|
}, {
|
|
279
278
|
default: w(() => [
|
|
280
|
-
(u(!0), m(se, null,
|
|
279
|
+
(u(!0), m(se, null, xe(o.options, (i) => (u(), D(y(pe), {
|
|
281
280
|
key: i.key,
|
|
282
281
|
title: i.title,
|
|
283
282
|
label: i.label,
|
|
@@ -293,7 +292,7 @@ const ft = ["disabled"], pt = {
|
|
|
293
292
|
_: 3
|
|
294
293
|
}, 8, ["class", "disabled", "borderless", "elevated"]));
|
|
295
294
|
}
|
|
296
|
-
}),
|
|
295
|
+
}), gt = S(bt), _t = /* @__PURE__ */ L({
|
|
297
296
|
__name: "QIcon",
|
|
298
297
|
props: {
|
|
299
298
|
icon: {},
|
|
@@ -305,22 +304,22 @@ const ft = ["disabled"], pt = {
|
|
|
305
304
|
const o = t, e = k(() => {
|
|
306
305
|
switch (o.type) {
|
|
307
306
|
case "svg":
|
|
308
|
-
return
|
|
307
|
+
return et;
|
|
309
308
|
case "font":
|
|
310
|
-
return
|
|
309
|
+
return Ze;
|
|
311
310
|
case "img":
|
|
312
|
-
return
|
|
311
|
+
return Je;
|
|
313
312
|
default:
|
|
314
313
|
return;
|
|
315
314
|
}
|
|
316
315
|
});
|
|
317
|
-
return (n, l) => (u(),
|
|
318
|
-
class:
|
|
316
|
+
return (n, l) => (u(), D(Ke(e.value), {
|
|
317
|
+
class: C(o.class),
|
|
319
318
|
icon: o.icon,
|
|
320
319
|
size: o.size
|
|
321
320
|
}, null, 8, ["class", "icon", "size"]));
|
|
322
321
|
}
|
|
323
|
-
}),
|
|
322
|
+
}), kt = /* @__PURE__ */ L({
|
|
324
323
|
__name: "QIconFont",
|
|
325
324
|
props: {
|
|
326
325
|
icon: {},
|
|
@@ -334,11 +333,11 @@ const ft = ["disabled"], pt = {
|
|
|
334
333
|
"font-size": o.size !== void 0 ? `${o.size}px` : void 0
|
|
335
334
|
}));
|
|
336
335
|
return (s, i) => (u(), m("i", {
|
|
337
|
-
class:
|
|
336
|
+
class: C(["q-icon", "q-icon__font", e.value, n.value, o.class]),
|
|
338
337
|
style: ie(l.value)
|
|
339
338
|
}, null, 6));
|
|
340
339
|
}
|
|
341
|
-
}),
|
|
340
|
+
}), wt = ["src"], $t = /* @__PURE__ */ L({
|
|
342
341
|
__name: "QIconImg",
|
|
343
342
|
props: {
|
|
344
343
|
icon: {},
|
|
@@ -351,11 +350,11 @@ const ft = ["disabled"], pt = {
|
|
|
351
350
|
}));
|
|
352
351
|
return (n, l) => (u(), m("img", {
|
|
353
352
|
src: o.icon,
|
|
354
|
-
class:
|
|
353
|
+
class: C(["q-icon", "q-icon__img", o.class]),
|
|
355
354
|
style: ie(e.value)
|
|
356
|
-
}, null, 14,
|
|
355
|
+
}, null, 14, wt));
|
|
357
356
|
}
|
|
358
|
-
}),
|
|
357
|
+
}), me = {}, qt = L({
|
|
359
358
|
name: "InlineSvg",
|
|
360
359
|
emits: {
|
|
361
360
|
loaded: (t) => typeof t == "object",
|
|
@@ -368,9 +367,9 @@ const ft = ["disabled"], pt = {
|
|
|
368
367
|
return null;
|
|
369
368
|
const t = this.getSvgContent(this.svgElSource);
|
|
370
369
|
if (!t)
|
|
371
|
-
return
|
|
370
|
+
return ze("div", this.$attrs);
|
|
372
371
|
const o = {};
|
|
373
|
-
return this.copySvgAttrs(o, this.svgElSource), this.copySvgAttrs(o, t), this.copyComponentAttrs(o, this.$attrs), o.innerHTML = t.innerHTML,
|
|
372
|
+
return this.copySvgAttrs(o, this.svgElSource), this.copySvgAttrs(o, t), this.copyComponentAttrs(o, this.$attrs), o.innerHTML = t.innerHTML, ze("svg", o);
|
|
374
373
|
},
|
|
375
374
|
props: {
|
|
376
375
|
/**
|
|
@@ -432,7 +431,7 @@ const ft = ["disabled"], pt = {
|
|
|
432
431
|
n !== !1 && n !== null && n !== void 0 && (t[e] = n);
|
|
433
432
|
},
|
|
434
433
|
getSvgContent(t) {
|
|
435
|
-
return this.symbol && (t = t.getElementById(this.symbol), !t) ? null : (this.transformSource && (t = t.cloneNode(!0), t = this.transformSource(t)), this.title && (this.transformSource || (t = t.cloneNode(!0)),
|
|
434
|
+
return this.symbol && (t = t.getElementById(this.symbol), !t) ? null : (this.transformSource && (t = t.cloneNode(!0), t = this.transformSource(t)), this.title && (this.transformSource || (t = t.cloneNode(!0)), It(t, this.title)), t);
|
|
436
435
|
},
|
|
437
436
|
/**
|
|
438
437
|
* Get svgElSource
|
|
@@ -440,11 +439,11 @@ const ft = ["disabled"], pt = {
|
|
|
440
439
|
*/
|
|
441
440
|
async getSource(t) {
|
|
442
441
|
try {
|
|
443
|
-
|
|
444
|
-
const o = await
|
|
442
|
+
me[t] || (me[t] = xt(this.download(t))), this.svgElSource && me[t].getIsPending() && !this.keepDuringLoading && (this.svgElSource = null, this.$emit("unloaded"));
|
|
443
|
+
const o = await me[t];
|
|
445
444
|
this.svgElSource = o, await this.$nextTick(), this.$emit("loaded", this.$el);
|
|
446
445
|
} catch (o) {
|
|
447
|
-
this.svgElSource && (this.svgElSource = null, this.$emit("unloaded")), delete
|
|
446
|
+
this.svgElSource && (this.svgElSource = null, this.$emit("unloaded")), delete me[t], this.$emit("error", o);
|
|
448
447
|
}
|
|
449
448
|
},
|
|
450
449
|
/**
|
|
@@ -469,7 +468,7 @@ const ft = ["disabled"], pt = {
|
|
|
469
468
|
},
|
|
470
469
|
expose: []
|
|
471
470
|
});
|
|
472
|
-
function
|
|
471
|
+
function It(t, o) {
|
|
473
472
|
const e = t.getElementsByTagName("title");
|
|
474
473
|
if (e.length)
|
|
475
474
|
e[0].textContent = o;
|
|
@@ -478,7 +477,7 @@ function bt(t, o) {
|
|
|
478
477
|
n.textContent = o, t.insertBefore(n, t.firstChild);
|
|
479
478
|
}
|
|
480
479
|
}
|
|
481
|
-
function
|
|
480
|
+
function xt(t) {
|
|
482
481
|
if (t.getIsPending)
|
|
483
482
|
return t;
|
|
484
483
|
let o = !0;
|
|
@@ -490,7 +489,7 @@ function gt(t) {
|
|
|
490
489
|
);
|
|
491
490
|
return e.getIsPending = () => o, e;
|
|
492
491
|
}
|
|
493
|
-
const
|
|
492
|
+
const Lt = /* @__PURE__ */ L({
|
|
494
493
|
__name: "QIconSvg",
|
|
495
494
|
props: {
|
|
496
495
|
icon: {},
|
|
@@ -509,8 +508,8 @@ const De = /* @__PURE__ */ L({
|
|
|
509
508
|
function i() {
|
|
510
509
|
n("unloaded");
|
|
511
510
|
}
|
|
512
|
-
return (a, c) => (u(),
|
|
513
|
-
class:
|
|
511
|
+
return (a, c) => (u(), D(y(qt), {
|
|
512
|
+
class: C(["q-icon", "q-icon__svg", e.class]),
|
|
514
513
|
src: e.bundle,
|
|
515
514
|
symbol: e.icon,
|
|
516
515
|
style: ie(l.value),
|
|
@@ -518,14 +517,9 @@ const De = /* @__PURE__ */ L({
|
|
|
518
517
|
onUnloaded: i
|
|
519
518
|
}, null, 8, ["class", "src", "symbol", "style"]));
|
|
520
519
|
}
|
|
521
|
-
})
|
|
522
|
-
Z(K);
|
|
523
|
-
Z(Te);
|
|
524
|
-
Z(Ee);
|
|
525
|
-
Z(De);
|
|
526
|
-
const xe = /* @__PURE__ */ L({
|
|
520
|
+
}), Y = S(_t), Ze = S(kt), Je = S($t), et = S(Lt), St = /* @__PURE__ */ L({
|
|
527
521
|
__name: "QList",
|
|
528
|
-
props: /* @__PURE__ */
|
|
522
|
+
props: /* @__PURE__ */ Z({
|
|
529
523
|
highlighted: { type: [String, Number, Boolean, Symbol], default: void 0 },
|
|
530
524
|
items: {},
|
|
531
525
|
groups: { default: () => [] },
|
|
@@ -541,9 +535,9 @@ const xe = /* @__PURE__ */ L({
|
|
|
541
535
|
}),
|
|
542
536
|
emits: ["update:modelValue"],
|
|
543
537
|
setup(t, { expose: o }) {
|
|
544
|
-
const e = t, n = ne(t, "modelValue"), l =
|
|
538
|
+
const e = t, n = ne(t, "modelValue"), l = V(!1), s = k(() => i.value.length > 1 ? "div" : "ul"), i = k(() => e.groups.length ? e.groups.filter(
|
|
545
539
|
(f) => e.items.some((g) => g.group === f.id)
|
|
546
|
-
) : [{ id: "", title: "" }]), a =
|
|
540
|
+
) : [{ id: "", title: "" }]), a = V(null);
|
|
547
541
|
function c(f) {
|
|
548
542
|
n.value = f;
|
|
549
543
|
}
|
|
@@ -558,83 +552,83 @@ const xe = /* @__PURE__ */ L({
|
|
|
558
552
|
if ((p = a.value) != null && p.contains(f.relatedTarget))
|
|
559
553
|
return;
|
|
560
554
|
let g;
|
|
561
|
-
n.value ? g = e.items.findIndex((
|
|
555
|
+
n.value ? g = e.items.findIndex((F) => F[e.itemValue] === n.value) : g = H();
|
|
562
556
|
const d = l.value;
|
|
563
557
|
I(g, d);
|
|
564
558
|
}
|
|
565
|
-
function
|
|
559
|
+
function z(f) {
|
|
566
560
|
switch (["ArrowDown", "ArrowUp", "Home", "End"].includes(f.key) && f.preventDefault(), f.key) {
|
|
567
561
|
case "ArrowDown":
|
|
568
|
-
|
|
562
|
+
T("next");
|
|
569
563
|
break;
|
|
570
564
|
case "ArrowUp":
|
|
571
|
-
|
|
565
|
+
T("prev");
|
|
572
566
|
break;
|
|
573
567
|
case "Home":
|
|
574
|
-
|
|
568
|
+
T("first");
|
|
575
569
|
break;
|
|
576
570
|
case "End":
|
|
577
|
-
|
|
571
|
+
T("last");
|
|
578
572
|
break;
|
|
579
573
|
}
|
|
580
574
|
}
|
|
581
|
-
function
|
|
575
|
+
function T(f) {
|
|
582
576
|
switch (f) {
|
|
583
577
|
case "next":
|
|
584
578
|
case "prev":
|
|
585
|
-
I(
|
|
579
|
+
I(P(f));
|
|
586
580
|
break;
|
|
587
581
|
case "first":
|
|
588
|
-
I(
|
|
582
|
+
I(H());
|
|
589
583
|
break;
|
|
590
584
|
case "last":
|
|
591
|
-
I(
|
|
585
|
+
I(M());
|
|
592
586
|
break;
|
|
593
587
|
}
|
|
594
588
|
}
|
|
595
589
|
function I(f, g = !1) {
|
|
596
590
|
var p;
|
|
597
|
-
(p =
|
|
591
|
+
(p = B()[f]) == null || p.focus({ preventScroll: g });
|
|
598
592
|
}
|
|
599
|
-
function
|
|
593
|
+
function B() {
|
|
600
594
|
var g;
|
|
601
595
|
const f = (g = a.value) == null ? void 0 : g.querySelectorAll("li");
|
|
602
596
|
return f ? Array.from(f) : [];
|
|
603
597
|
}
|
|
604
598
|
function G(f) {
|
|
605
|
-
return
|
|
599
|
+
return B()[f];
|
|
606
600
|
}
|
|
607
601
|
function J() {
|
|
608
|
-
return
|
|
602
|
+
return B().indexOf(document.activeElement);
|
|
609
603
|
}
|
|
610
|
-
function
|
|
611
|
-
const f =
|
|
604
|
+
function H() {
|
|
605
|
+
const f = B(), g = f.find((d) => A(d));
|
|
612
606
|
return g ? f.indexOf(g) : -1;
|
|
613
607
|
}
|
|
614
|
-
function
|
|
615
|
-
const f =
|
|
608
|
+
function M() {
|
|
609
|
+
const f = B(), g = [...f].reverse().find((d) => A(d));
|
|
616
610
|
return g ? f.indexOf(g) : -1;
|
|
617
611
|
}
|
|
618
612
|
function ee(f, g, d) {
|
|
619
613
|
return g === "prev" && f === 0 || g === "next" && f === d.length - 1;
|
|
620
614
|
}
|
|
621
|
-
function
|
|
615
|
+
function P(f) {
|
|
622
616
|
const g = J();
|
|
623
617
|
return te(g, f);
|
|
624
618
|
}
|
|
625
619
|
function te(f, g) {
|
|
626
|
-
const d =
|
|
620
|
+
const d = B();
|
|
627
621
|
if (ee(f, g, d))
|
|
628
622
|
return f;
|
|
629
623
|
let p = f + (g === "next" ? 1 : -1);
|
|
630
|
-
for (; !
|
|
624
|
+
for (; !A(d[p]); ) {
|
|
631
625
|
if (ee(p, g, d))
|
|
632
626
|
return f;
|
|
633
627
|
p += g === "next" ? 1 : -1;
|
|
634
628
|
}
|
|
635
629
|
return p;
|
|
636
630
|
}
|
|
637
|
-
function
|
|
631
|
+
function A(f) {
|
|
638
632
|
return f.tabIndex === -2;
|
|
639
633
|
}
|
|
640
634
|
function W(f) {
|
|
@@ -644,27 +638,27 @@ const xe = /* @__PURE__ */ L({
|
|
|
644
638
|
focusItem: I,
|
|
645
639
|
getItem: G,
|
|
646
640
|
getAdjacentItemIndex: te,
|
|
647
|
-
getFirstFocusableItemIndex:
|
|
648
|
-
getLastFocusableItemIndex:
|
|
649
|
-
}), (f, g) => (u(),
|
|
641
|
+
getFirstFocusableItemIndex: H,
|
|
642
|
+
getLastFocusableItemIndex: M
|
|
643
|
+
}), (f, g) => (u(), D(Ke(s.value), {
|
|
650
644
|
ref_key: "listRef",
|
|
651
645
|
ref: a,
|
|
652
|
-
class:
|
|
646
|
+
class: C(["q-list", { "q-list--disabled": e.disabled }, e.class]),
|
|
653
647
|
role: "listbox",
|
|
654
648
|
tabindex: e.disabled ? -1 : 0,
|
|
655
649
|
onFocus: x,
|
|
656
650
|
onMousedown: v,
|
|
657
651
|
onMouseup: $,
|
|
658
|
-
onKeydown:
|
|
652
|
+
onKeydown: z
|
|
659
653
|
}, {
|
|
660
654
|
default: w(() => [
|
|
661
|
-
(u(!0), m(se, null,
|
|
655
|
+
(u(!0), m(se, null, xe(i.value, (d) => (u(), D(y(ot), {
|
|
662
656
|
key: d.id,
|
|
663
657
|
id: d.id,
|
|
664
658
|
title: i.value.length === 1 ? void 0 : d.title
|
|
665
659
|
}, {
|
|
666
660
|
default: w(() => [
|
|
667
|
-
(u(!0), m(se, null,
|
|
661
|
+
(u(!0), m(se, null, xe(W(d.id), (p) => (u(), D(y(tt), {
|
|
668
662
|
key: p[e.itemValue],
|
|
669
663
|
value: p[e.itemValue],
|
|
670
664
|
label: p[e.itemLabel],
|
|
@@ -688,21 +682,21 @@ const xe = /* @__PURE__ */ L({
|
|
|
688
682
|
}, 40, ["class", "tabindex"]));
|
|
689
683
|
}
|
|
690
684
|
});
|
|
691
|
-
let
|
|
692
|
-
function
|
|
693
|
-
return t || `uid-${++
|
|
685
|
+
let Bt = 0;
|
|
686
|
+
function ye(t) {
|
|
687
|
+
return t || `uid-${++Bt}`;
|
|
694
688
|
}
|
|
695
|
-
const
|
|
689
|
+
const Vt = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], Ct = { class: "q-list-item__container" }, Tt = { class: "q-list-item__content" }, Et = {
|
|
696
690
|
key: 0,
|
|
697
691
|
class: "q-list-item__description"
|
|
698
|
-
},
|
|
692
|
+
}, Dt = { class: "q-list-item__check-container" }, At = {
|
|
699
693
|
check: {
|
|
700
694
|
icon: "check"
|
|
701
695
|
},
|
|
702
696
|
description: {
|
|
703
697
|
icon: "information-outline"
|
|
704
698
|
}
|
|
705
|
-
},
|
|
699
|
+
}, zt = /* @__PURE__ */ L({
|
|
706
700
|
__name: "QListItem",
|
|
707
701
|
props: {
|
|
708
702
|
value: { type: [String, Number, Boolean, Symbol] },
|
|
@@ -710,13 +704,13 @@ const kt = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], wt = {
|
|
|
710
704
|
icon: { default: void 0 },
|
|
711
705
|
selected: { type: Boolean },
|
|
712
706
|
highlighted: { type: Boolean },
|
|
713
|
-
icons: { default: () =>
|
|
707
|
+
icons: { default: () => At },
|
|
714
708
|
disabled: { type: Boolean },
|
|
715
709
|
description: { default: void 0 }
|
|
716
710
|
},
|
|
717
711
|
emits: ["select"],
|
|
718
712
|
setup(t, { emit: o }) {
|
|
719
|
-
const e = t, n = o, l =
|
|
713
|
+
const e = t, n = o, l = ye();
|
|
720
714
|
function s() {
|
|
721
715
|
e.disabled || n("select", e.value);
|
|
722
716
|
}
|
|
@@ -728,7 +722,7 @@ const kt = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], wt = {
|
|
|
728
722
|
"data-key": e.value,
|
|
729
723
|
role: "option",
|
|
730
724
|
tabindex: e.disabled ? void 0 : -2,
|
|
731
|
-
class:
|
|
725
|
+
class: C([
|
|
732
726
|
"q-list-item",
|
|
733
727
|
{
|
|
734
728
|
"q-list-item--disabled": e.disabled,
|
|
@@ -741,31 +735,31 @@ const kt = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], wt = {
|
|
|
741
735
|
onKeydown: i,
|
|
742
736
|
onClick: ce(s, ["stop", "prevent"])
|
|
743
737
|
}, [
|
|
744
|
-
|
|
745
|
-
|
|
738
|
+
K("div", Ct, [
|
|
739
|
+
K("div", Tt, [
|
|
746
740
|
h(a.$slots, "default", {}, () => [
|
|
747
|
-
e.icon ? (u(),
|
|
748
|
-
|
|
741
|
+
e.icon ? (u(), D(y(Y), ae(fe({ key: 0 }, e.icon)), null, 16)) : q("", !0),
|
|
742
|
+
ve(" " + j(e.label), 1)
|
|
749
743
|
])
|
|
750
744
|
]),
|
|
751
|
-
e.description ? (u(), m("div",
|
|
752
|
-
|
|
753
|
-
|
|
745
|
+
e.description ? (u(), m("div", Et, [
|
|
746
|
+
Q(y(Y), ae(re(e.icons.description)), null, 16),
|
|
747
|
+
K("span", null, j(e.description), 1)
|
|
754
748
|
])) : q("", !0)
|
|
755
749
|
]),
|
|
756
|
-
|
|
757
|
-
e.selected ? (u(),
|
|
750
|
+
K("div", Dt, [
|
|
751
|
+
e.selected ? (u(), D(y(Y), fe({ key: 0 }, e.icons.check, { class: "q-list-item__check" }), null, 16)) : q("", !0)
|
|
758
752
|
])
|
|
759
|
-
], 42,
|
|
753
|
+
], 42, Vt));
|
|
760
754
|
}
|
|
761
|
-
}),
|
|
755
|
+
}), Qt = ["data-key", "aria-labelledby"], Mt = ["id"], Ft = /* @__PURE__ */ L({
|
|
762
756
|
__name: "QListItemGroup",
|
|
763
757
|
props: {
|
|
764
758
|
id: {},
|
|
765
759
|
title: { default: "" }
|
|
766
760
|
},
|
|
767
761
|
setup(t) {
|
|
768
|
-
const o = t, e =
|
|
762
|
+
const o = t, e = ye();
|
|
769
763
|
return (n, l) => (u(), m("ul", {
|
|
770
764
|
class: "q-list-item-group",
|
|
771
765
|
role: "group",
|
|
@@ -777,59 +771,55 @@ const kt = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], wt = {
|
|
|
777
771
|
id: y(e),
|
|
778
772
|
class: "q-list-item-group__title",
|
|
779
773
|
role: "presentation"
|
|
780
|
-
}, j(o.title), 9,
|
|
774
|
+
}, j(o.title), 9, Mt)) : q("", !0),
|
|
781
775
|
h(n.$slots, "default")
|
|
782
|
-
], 8,
|
|
776
|
+
], 8, Qt));
|
|
783
777
|
}
|
|
784
|
-
});
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
const $e = 8;
|
|
789
|
-
function Bt(t, o, e, n) {
|
|
790
|
-
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 = Vt(i, a, s, l), $ = Dt(i, a, v), x = Tt($, v, l), A = Ct(x, a, v);
|
|
791
|
-
let C;
|
|
778
|
+
}), Ce = S(St), tt = S(zt), ot = S(Ft), ke = 8;
|
|
779
|
+
function Ot(t, o, e, n) {
|
|
780
|
+
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 = Pt(i, a, s, l), $ = Kt(i, a, v), x = Nt($, v, l), z = Ut(x, a, v);
|
|
781
|
+
let T;
|
|
792
782
|
if (n != null && n.arrow) {
|
|
793
783
|
if (!c)
|
|
794
784
|
throw new Error("[Quidgest UI] The arrow element must exist to compute its position");
|
|
795
|
-
|
|
785
|
+
T = Ht(z, i, a, c, v);
|
|
796
786
|
}
|
|
797
|
-
return { overlayCoords:
|
|
787
|
+
return { overlayCoords: z, arrowCoords: T, placement: v };
|
|
798
788
|
}
|
|
799
|
-
function
|
|
800
|
-
const l =
|
|
801
|
-
if (
|
|
802
|
-
const s =
|
|
789
|
+
function Pt(t, o, e, n) {
|
|
790
|
+
const l = Fe(t, o, e, n);
|
|
791
|
+
if (Oe(l)) {
|
|
792
|
+
const s = be(e), a = {
|
|
803
793
|
top: "bottom",
|
|
804
794
|
bottom: "top",
|
|
805
795
|
left: "right",
|
|
806
796
|
right: "left"
|
|
807
|
-
}[s], c =
|
|
797
|
+
}[s], c = Fe(
|
|
808
798
|
t,
|
|
809
799
|
o,
|
|
810
800
|
a,
|
|
811
801
|
n
|
|
812
802
|
);
|
|
813
|
-
if (
|
|
803
|
+
if (Oe(c))
|
|
814
804
|
return e;
|
|
815
|
-
const v =
|
|
805
|
+
const v = Wt(e);
|
|
816
806
|
return v ? `${a}-${v}` : a;
|
|
817
807
|
}
|
|
818
808
|
return e;
|
|
819
809
|
}
|
|
820
|
-
function
|
|
821
|
-
const n =
|
|
822
|
-
return n === "x" ? s.x = l(t.x,
|
|
810
|
+
function Ut(t, o, e) {
|
|
811
|
+
const n = we(e), l = (i, a, c) => Math.min(Math.max(i, a), c), s = { ...t };
|
|
812
|
+
return n === "x" ? s.x = l(t.x, ke, window.innerWidth - o.width - ke) : s.y = l(t.y, ke, window.innerHeight - o.height - ke), s;
|
|
823
813
|
}
|
|
824
|
-
function
|
|
825
|
-
const n =
|
|
814
|
+
function Nt(t, o, e) {
|
|
815
|
+
const n = be(o);
|
|
826
816
|
return {
|
|
827
817
|
x: t.x + (n === "left" ? -e : n === "right" ? e : 0),
|
|
828
818
|
y: t.y + (n === "top" ? -e : n === "bottom" ? e : 0)
|
|
829
819
|
};
|
|
830
820
|
}
|
|
831
|
-
function
|
|
832
|
-
if (
|
|
821
|
+
function Ht(t, o, e, n, l) {
|
|
822
|
+
if (we(l) === "y") {
|
|
833
823
|
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;
|
|
834
824
|
if (v > 0 && v < e.height - n.height)
|
|
835
825
|
return {
|
|
@@ -843,7 +833,7 @@ function Et(t, o, e, n, l) {
|
|
|
843
833
|
};
|
|
844
834
|
}
|
|
845
835
|
}
|
|
846
|
-
function
|
|
836
|
+
function Kt(t, o, e) {
|
|
847
837
|
const [n, l] = e.split("-"), s = t.x + t.width / 2 - o.width / 2, i = t.y + t.height / 2 - o.height / 2;
|
|
848
838
|
let a;
|
|
849
839
|
switch (n) {
|
|
@@ -864,7 +854,7 @@ function Dt(t, o, e) {
|
|
|
864
854
|
}
|
|
865
855
|
if (!l)
|
|
866
856
|
return a;
|
|
867
|
-
const v =
|
|
857
|
+
const v = we(e) === "y" ? "height" : "width", $ = we(e), x = t[v] / 2 - o[v] / 2;
|
|
868
858
|
switch (l) {
|
|
869
859
|
case "start":
|
|
870
860
|
a[$] -= x;
|
|
@@ -877,8 +867,8 @@ function Dt(t, o, e) {
|
|
|
877
867
|
}
|
|
878
868
|
return a;
|
|
879
869
|
}
|
|
880
|
-
function
|
|
881
|
-
const l =
|
|
870
|
+
function Fe(t, o, e, n) {
|
|
871
|
+
const l = be(e);
|
|
882
872
|
let s = 0;
|
|
883
873
|
switch (l) {
|
|
884
874
|
case "top":
|
|
@@ -898,34 +888,34 @@ function Ke(t, o, e, n) {
|
|
|
898
888
|
}
|
|
899
889
|
return s;
|
|
900
890
|
}
|
|
901
|
-
function
|
|
891
|
+
function jt(t) {
|
|
902
892
|
return t === "x" ? "y" : "x";
|
|
903
893
|
}
|
|
904
|
-
function
|
|
905
|
-
const o =
|
|
894
|
+
function Gt(t) {
|
|
895
|
+
const o = be(t);
|
|
906
896
|
return ["left", "right"].includes(o) ? "x" : "y";
|
|
907
897
|
}
|
|
908
|
-
function
|
|
909
|
-
return
|
|
898
|
+
function we(t) {
|
|
899
|
+
return jt(Gt(t));
|
|
910
900
|
}
|
|
911
|
-
function
|
|
901
|
+
function be(t) {
|
|
912
902
|
const [o] = t.split("-");
|
|
913
903
|
return o;
|
|
914
904
|
}
|
|
915
|
-
function
|
|
905
|
+
function Wt(t) {
|
|
916
906
|
const [, o] = t.split("-");
|
|
917
907
|
return o;
|
|
918
908
|
}
|
|
919
|
-
function
|
|
909
|
+
function Oe(t) {
|
|
920
910
|
return t < 0;
|
|
921
911
|
}
|
|
922
|
-
function
|
|
912
|
+
function Rt(t) {
|
|
923
913
|
return typeof t == "string" ? document.querySelector(t) : t;
|
|
924
914
|
}
|
|
925
|
-
const
|
|
915
|
+
const Xt = ["role"], Yt = /* @__PURE__ */ L({
|
|
926
916
|
inheritAttrs: !1,
|
|
927
917
|
__name: "QOverlay",
|
|
928
|
-
props: /* @__PURE__ */
|
|
918
|
+
props: /* @__PURE__ */ Z({
|
|
929
919
|
anchor: { default: void 0 },
|
|
930
920
|
appearance: { default: "regular" },
|
|
931
921
|
arrow: { type: Boolean },
|
|
@@ -947,23 +937,23 @@ const Ft = ["role"], me = /* @__PURE__ */ L({
|
|
|
947
937
|
modelValue: { type: Boolean },
|
|
948
938
|
modelModifiers: {}
|
|
949
939
|
}),
|
|
950
|
-
emits: /* @__PURE__ */
|
|
940
|
+
emits: /* @__PURE__ */ Z(["enter", "leave"], ["update:modelValue"]),
|
|
951
941
|
setup(t, { emit: o }) {
|
|
952
942
|
const e = t, n = o, l = ne(t, "modelValue"), s = k(() => [
|
|
953
943
|
"q-overlay",
|
|
954
|
-
`q-overlay--${
|
|
944
|
+
`q-overlay--${be(a.placement)}`,
|
|
955
945
|
{
|
|
956
946
|
"q-overlay--independent": e.anchor === void 0,
|
|
957
947
|
"q-overlay--inverted": e.appearance === "inverted"
|
|
958
948
|
},
|
|
959
949
|
e.class
|
|
960
|
-
]), i = k(() => (l.value || a.animating) && !e.nonModal), a =
|
|
950
|
+
]), i = k(() => (l.value || a.animating) && !e.nonModal), a = Qe({
|
|
961
951
|
animating: !1,
|
|
962
952
|
top: 0,
|
|
963
953
|
left: 0,
|
|
964
954
|
width: 0,
|
|
965
955
|
placement: e.placement
|
|
966
|
-
}), c =
|
|
956
|
+
}), c = Qe({
|
|
967
957
|
top: void 0,
|
|
968
958
|
left: void 0,
|
|
969
959
|
hidden: !0
|
|
@@ -972,11 +962,11 @@ const Ft = ["role"], me = /* @__PURE__ */ L({
|
|
|
972
962
|
const $ = k(() => {
|
|
973
963
|
if (e.anchor === void 0)
|
|
974
964
|
return;
|
|
975
|
-
const b =
|
|
965
|
+
const b = A(), de = e.width === "anchor", N = de ? b == null ? void 0 : b.getBoundingClientRect().width : void 0;
|
|
976
966
|
return {
|
|
977
967
|
top: `${a.top}px`,
|
|
978
968
|
left: `${a.left}px`,
|
|
979
|
-
width:
|
|
969
|
+
width: N !== void 0 ? `${N}px` : void 0
|
|
980
970
|
};
|
|
981
971
|
}), x = k(() => {
|
|
982
972
|
if (e.arrow)
|
|
@@ -985,43 +975,43 @@ const Ft = ["role"], me = /* @__PURE__ */ L({
|
|
|
985
975
|
left: c.left !== void 0 ? `${c.left}px` : void 0,
|
|
986
976
|
opacity: c.hidden ? 0 : 1
|
|
987
977
|
};
|
|
988
|
-
}),
|
|
978
|
+
}), z = V(null), T = V(null);
|
|
989
979
|
function I() {
|
|
990
|
-
const b =
|
|
991
|
-
if (!b || !
|
|
980
|
+
const b = A();
|
|
981
|
+
if (!b || !T.value)
|
|
992
982
|
return;
|
|
993
983
|
const de = {
|
|
994
984
|
placement: e.placement,
|
|
995
985
|
width: e.width,
|
|
996
986
|
offset: e.offset,
|
|
997
987
|
arrow: e.arrow
|
|
998
|
-
},
|
|
988
|
+
}, N = Ot(
|
|
999
989
|
b,
|
|
1000
|
-
|
|
1001
|
-
(
|
|
990
|
+
T.value,
|
|
991
|
+
(z == null ? void 0 : z.value) ?? void 0,
|
|
1002
992
|
de
|
|
1003
993
|
);
|
|
1004
|
-
a.left =
|
|
994
|
+
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);
|
|
1005
995
|
}
|
|
1006
996
|
R(
|
|
1007
997
|
() => e.placement,
|
|
1008
998
|
() => X(I)
|
|
1009
999
|
);
|
|
1010
|
-
let
|
|
1000
|
+
let B;
|
|
1011
1001
|
function G() {
|
|
1012
|
-
|
|
1002
|
+
H(0);
|
|
1013
1003
|
}
|
|
1014
1004
|
function J() {
|
|
1015
|
-
|
|
1005
|
+
H(e.delay);
|
|
1016
1006
|
}
|
|
1017
|
-
function
|
|
1018
|
-
|
|
1007
|
+
function H(b) {
|
|
1008
|
+
B || (B = window.setTimeout(() => {
|
|
1019
1009
|
l.value = !0;
|
|
1020
1010
|
}, b));
|
|
1021
1011
|
}
|
|
1022
|
-
function
|
|
1023
|
-
if (clearTimeout(
|
|
1024
|
-
const b =
|
|
1012
|
+
function M() {
|
|
1013
|
+
if (clearTimeout(B), B = void 0, l.value = !1, e.anchor && e.trigger === "click") {
|
|
1014
|
+
const b = A();
|
|
1025
1015
|
b == null || b.focus();
|
|
1026
1016
|
}
|
|
1027
1017
|
}
|
|
@@ -1029,16 +1019,16 @@ const Ft = ["role"], me = /* @__PURE__ */ L({
|
|
|
1029
1019
|
function ee() {
|
|
1030
1020
|
n("enter");
|
|
1031
1021
|
}
|
|
1032
|
-
let
|
|
1022
|
+
let P;
|
|
1033
1023
|
function te() {
|
|
1034
|
-
window.clearTimeout(
|
|
1024
|
+
window.clearTimeout(P), P = window.setTimeout(() => a.animating = !1, 200), n("leave");
|
|
1035
1025
|
}
|
|
1036
|
-
function
|
|
1037
|
-
return e.anchor ?
|
|
1026
|
+
function A() {
|
|
1027
|
+
return e.anchor ? Rt(e.anchor) : null;
|
|
1038
1028
|
}
|
|
1039
1029
|
let W;
|
|
1040
1030
|
function f() {
|
|
1041
|
-
const b =
|
|
1031
|
+
const b = A();
|
|
1042
1032
|
if (b)
|
|
1043
1033
|
switch (W = new MutationObserver(I), W.observe(b, {
|
|
1044
1034
|
attributes: !1,
|
|
@@ -1050,19 +1040,19 @@ const Ft = ["role"], me = /* @__PURE__ */ L({
|
|
|
1050
1040
|
b.addEventListener("click", G);
|
|
1051
1041
|
break;
|
|
1052
1042
|
case "hover":
|
|
1053
|
-
b.addEventListener("mouseenter", J), b.addEventListener("mouseleave",
|
|
1043
|
+
b.addEventListener("mouseenter", J), b.addEventListener("mouseleave", M), b.addEventListener("focusin", G), b.addEventListener("focusout", M);
|
|
1054
1044
|
break;
|
|
1055
1045
|
}
|
|
1056
1046
|
}
|
|
1057
1047
|
function g() {
|
|
1058
|
-
const b =
|
|
1048
|
+
const b = A();
|
|
1059
1049
|
if (b)
|
|
1060
1050
|
switch (W == null || W.disconnect(), e.trigger) {
|
|
1061
1051
|
case "click":
|
|
1062
1052
|
b.removeEventListener("click", G);
|
|
1063
1053
|
break;
|
|
1064
1054
|
case "hover":
|
|
1065
|
-
b.removeEventListener("mouseenter", J), b.removeEventListener("mouseleave",
|
|
1055
|
+
b.removeEventListener("mouseenter", J), b.removeEventListener("mouseleave", M), b.removeEventListener("focusin", G), b.removeEventListener("focusout", M);
|
|
1066
1056
|
break;
|
|
1067
1057
|
}
|
|
1068
1058
|
}
|
|
@@ -1072,44 +1062,44 @@ const Ft = ["role"], me = /* @__PURE__ */ L({
|
|
|
1072
1062
|
function p() {
|
|
1073
1063
|
window.removeEventListener("resize", I), e.scrollLock || window.removeEventListener("scroll", I);
|
|
1074
1064
|
}
|
|
1075
|
-
let
|
|
1065
|
+
let F;
|
|
1076
1066
|
function oe() {
|
|
1077
|
-
|
|
1067
|
+
A() ? (I(), F = window.setTimeout(oe, 100)) : M();
|
|
1078
1068
|
}
|
|
1079
|
-
function
|
|
1069
|
+
function U() {
|
|
1080
1070
|
d(), e.spy ? oe() : I(), e.scrollLock && document.body.classList.add("no-scroll"), (e.anchor === void 0 || e.trigger === "click") && X(() => {
|
|
1081
1071
|
var b;
|
|
1082
|
-
return (b =
|
|
1072
|
+
return (b = T.value) == null ? void 0 : b.focus();
|
|
1083
1073
|
});
|
|
1084
1074
|
}
|
|
1085
1075
|
function le() {
|
|
1086
|
-
p(), e.spy && (clearTimeout(
|
|
1076
|
+
p(), e.spy && (clearTimeout(F), F = void 0), e.scrollLock && document.body.classList.remove("no-scroll"), a.top = 0, a.left = 0;
|
|
1087
1077
|
}
|
|
1088
|
-
function
|
|
1089
|
-
e.persistent ||
|
|
1078
|
+
function _e() {
|
|
1079
|
+
e.persistent || M();
|
|
1090
1080
|
}
|
|
1091
|
-
return
|
|
1081
|
+
return je(() => {
|
|
1092
1082
|
X(f);
|
|
1093
1083
|
}), lt(() => {
|
|
1094
1084
|
g(), le();
|
|
1095
1085
|
}), R(
|
|
1096
1086
|
l,
|
|
1097
1087
|
(b) => {
|
|
1098
|
-
X(() => b ?
|
|
1088
|
+
X(() => b ? U() : le());
|
|
1099
1089
|
},
|
|
1100
1090
|
{ immediate: !0 }
|
|
1101
|
-
), (b, de) => (u(),
|
|
1091
|
+
), (b, de) => (u(), D(at, {
|
|
1102
1092
|
disabled: !l.value && !a.animating || e.inline,
|
|
1103
1093
|
to: e.attach
|
|
1104
1094
|
}, [
|
|
1105
1095
|
i.value ? (u(), m("div", {
|
|
1106
1096
|
key: 0,
|
|
1107
|
-
class:
|
|
1097
|
+
class: C([
|
|
1108
1098
|
"q-overlay__underlay",
|
|
1109
1099
|
{ "q-overlay__underlay--blur": e.backdropBlur }
|
|
1110
1100
|
])
|
|
1111
1101
|
}, null, 2)) : q("", !0),
|
|
1112
|
-
|
|
1102
|
+
Q(st, {
|
|
1113
1103
|
name: e.transition,
|
|
1114
1104
|
appear: "",
|
|
1115
1105
|
onLeave: te
|
|
@@ -1117,50 +1107,48 @@ const Ft = ["role"], me = /* @__PURE__ */ L({
|
|
|
1117
1107
|
default: w(() => [
|
|
1118
1108
|
l.value ? (u(), m("div", {
|
|
1119
1109
|
key: 0,
|
|
1120
|
-
class:
|
|
1110
|
+
class: C(s.value),
|
|
1121
1111
|
style: ie($.value)
|
|
1122
1112
|
}, [
|
|
1123
|
-
|
|
1113
|
+
K("div", fe({
|
|
1124
1114
|
class: "q-overlay__content",
|
|
1125
1115
|
ref_key: "overlayRef",
|
|
1126
|
-
ref:
|
|
1116
|
+
ref: T,
|
|
1127
1117
|
tabindex: "-1",
|
|
1128
1118
|
role: i.value ? "dialog" : void 0
|
|
1129
1119
|
}, b.$attrs, {
|
|
1130
|
-
onKeydown: it(
|
|
1131
|
-
onBlur:
|
|
1120
|
+
onKeydown: it(_e, ["escape"]),
|
|
1121
|
+
onBlur: _e
|
|
1132
1122
|
}), [
|
|
1133
1123
|
e.arrow ? (u(), m("div", {
|
|
1134
1124
|
key: 0,
|
|
1135
1125
|
ref_key: "arrowRef",
|
|
1136
|
-
ref:
|
|
1126
|
+
ref: z,
|
|
1137
1127
|
role: "presentation",
|
|
1138
1128
|
class: "q-overlay__arrow",
|
|
1139
1129
|
style: ie(x.value)
|
|
1140
1130
|
}, null, 4)) : q("", !0),
|
|
1141
1131
|
h(b.$slots, "default")
|
|
1142
|
-
], 16,
|
|
1132
|
+
], 16, Xt)
|
|
1143
1133
|
], 6)) : q("", !0)
|
|
1144
1134
|
]),
|
|
1145
1135
|
_: 3
|
|
1146
1136
|
}, 8, ["name"])
|
|
1147
1137
|
], 8, ["disabled", "to"]));
|
|
1148
1138
|
}
|
|
1149
|
-
})
|
|
1150
|
-
Z(me);
|
|
1151
|
-
const Ot = ["id"], Pt = {
|
|
1139
|
+
}), ge = S(Yt), Zt = ["id"], Jt = {
|
|
1152
1140
|
key: 0,
|
|
1153
1141
|
class: "q-field__label"
|
|
1154
|
-
},
|
|
1142
|
+
}, eo = ["for"], to = {
|
|
1155
1143
|
key: 0,
|
|
1156
1144
|
class: "q-field__prepend"
|
|
1157
|
-
},
|
|
1145
|
+
}, oo = {
|
|
1158
1146
|
key: 1,
|
|
1159
1147
|
class: "q-field__append"
|
|
1160
|
-
},
|
|
1148
|
+
}, no = {
|
|
1161
1149
|
key: 1,
|
|
1162
1150
|
class: "q-field__extras"
|
|
1163
|
-
},
|
|
1151
|
+
}, lo = /* @__PURE__ */ L({
|
|
1164
1152
|
inheritAttrs: !1,
|
|
1165
1153
|
__name: "QField",
|
|
1166
1154
|
props: {
|
|
@@ -1174,12 +1162,12 @@ const Ot = ["id"], Pt = {
|
|
|
1174
1162
|
class: { default: void 0 }
|
|
1175
1163
|
},
|
|
1176
1164
|
setup(t, { expose: o }) {
|
|
1177
|
-
const e = t, n =
|
|
1165
|
+
const e = t, n = ye(e.id), l = V(null), s = k(() => e.required && !e.readonly && !e.disabled);
|
|
1178
1166
|
return o({
|
|
1179
1167
|
fieldRef: l
|
|
1180
1168
|
}), (i, a) => (u(), m("div", {
|
|
1181
1169
|
id: y(n),
|
|
1182
|
-
class:
|
|
1170
|
+
class: C([
|
|
1183
1171
|
"q-field",
|
|
1184
1172
|
`q-field--${e.size}`,
|
|
1185
1173
|
{
|
|
@@ -1190,39 +1178,37 @@ const Ot = ["id"], Pt = {
|
|
|
1190
1178
|
e.class
|
|
1191
1179
|
])
|
|
1192
1180
|
}, [
|
|
1193
|
-
e.label ? (u(), m("div",
|
|
1181
|
+
e.label ? (u(), m("div", Jt, [
|
|
1194
1182
|
h(i.$slots, "label.prepend"),
|
|
1195
|
-
|
|
1183
|
+
K("label", {
|
|
1196
1184
|
for: e.for
|
|
1197
|
-
}, j(e.label), 9,
|
|
1185
|
+
}, j(e.label), 9, eo),
|
|
1198
1186
|
h(i.$slots, "label.append")
|
|
1199
1187
|
])) : q("", !0),
|
|
1200
1188
|
h(i.$slots, "control", {}, () => [
|
|
1201
|
-
|
|
1189
|
+
K("div", fe({
|
|
1202
1190
|
class: "q-field__control",
|
|
1203
1191
|
ref_key: "fieldRef",
|
|
1204
1192
|
ref: l
|
|
1205
1193
|
}, i.$attrs), [
|
|
1206
|
-
i.$slots.prepend ? (u(), m("div",
|
|
1194
|
+
i.$slots.prepend ? (u(), m("div", to, [
|
|
1207
1195
|
h(i.$slots, "prepend")
|
|
1208
1196
|
])) : q("", !0),
|
|
1209
1197
|
h(i.$slots, "default"),
|
|
1210
|
-
i.$slots.append ? (u(), m("div",
|
|
1198
|
+
i.$slots.append ? (u(), m("div", oo, [
|
|
1211
1199
|
h(i.$slots, "append")
|
|
1212
1200
|
])) : q("", !0)
|
|
1213
1201
|
], 16)
|
|
1214
1202
|
]),
|
|
1215
|
-
i.$slots.extras ? (u(), m("div",
|
|
1203
|
+
i.$slots.extras ? (u(), m("div", no, [
|
|
1216
1204
|
h(i.$slots, "extras")
|
|
1217
1205
|
])) : q("", !0)
|
|
1218
|
-
], 10,
|
|
1206
|
+
], 10, Zt));
|
|
1219
1207
|
}
|
|
1220
|
-
})
|
|
1221
|
-
Z(ke);
|
|
1222
|
-
const jt = ["id", "type", "role", "required", "placeholder", "readonly", "disabled", "maxlength"], Qe = /* @__PURE__ */ L({
|
|
1208
|
+
}), Ie = S(lo), ao = ["id", "type", "role", "required", "placeholder", "readonly", "disabled", "maxlength"], so = /* @__PURE__ */ L({
|
|
1223
1209
|
inheritAttrs: !1,
|
|
1224
1210
|
__name: "QTextField",
|
|
1225
|
-
props: /* @__PURE__ */
|
|
1211
|
+
props: /* @__PURE__ */ Z({
|
|
1226
1212
|
id: { default: void 0 },
|
|
1227
1213
|
placeholder: { default: "" },
|
|
1228
1214
|
label: { default: "" },
|
|
@@ -1240,7 +1226,7 @@ const jt = ["id", "type", "role", "required", "placeholder", "readonly", "disabl
|
|
|
1240
1226
|
}),
|
|
1241
1227
|
emits: ["update:modelValue"],
|
|
1242
1228
|
setup(t, { expose: o }) {
|
|
1243
|
-
const e = t, n = ne(t, "modelValue"), l =
|
|
1229
|
+
const e = t, n = ne(t, "modelValue"), l = ye(e.id), s = V(null), i = V(null), a = k(
|
|
1244
1230
|
() => e.readonly || e.disabled ? "" : e.placeholder
|
|
1245
1231
|
);
|
|
1246
1232
|
return o({
|
|
@@ -1249,17 +1235,17 @@ const jt = ["id", "type", "role", "required", "placeholder", "readonly", "disabl
|
|
|
1249
1235
|
return (c = s.value) == null ? void 0 : c.fieldRef;
|
|
1250
1236
|
}),
|
|
1251
1237
|
inputRef: i
|
|
1252
|
-
}), (c, v) => (u(),
|
|
1238
|
+
}), (c, v) => (u(), D(y(Ie), {
|
|
1253
1239
|
ref_key: "fieldRef",
|
|
1254
1240
|
ref: s,
|
|
1255
|
-
class:
|
|
1241
|
+
class: C(["q-text-field", e.class]),
|
|
1256
1242
|
for: y(l),
|
|
1257
1243
|
label: e.label,
|
|
1258
1244
|
size: e.size,
|
|
1259
1245
|
readonly: e.readonly,
|
|
1260
1246
|
disabled: e.disabled,
|
|
1261
1247
|
required: e.required
|
|
1262
|
-
},
|
|
1248
|
+
}, $e({
|
|
1263
1249
|
"label.prepend": w(() => [
|
|
1264
1250
|
h(c.$slots, "label.prepend")
|
|
1265
1251
|
]),
|
|
@@ -1267,7 +1253,7 @@ const jt = ["id", "type", "role", "required", "placeholder", "readonly", "disabl
|
|
|
1267
1253
|
h(c.$slots, "label.append")
|
|
1268
1254
|
]),
|
|
1269
1255
|
default: w(() => [
|
|
1270
|
-
rt(
|
|
1256
|
+
rt(K("input", fe({
|
|
1271
1257
|
"onUpdate:modelValue": v[0] || (v[0] = ($) => n.value = $),
|
|
1272
1258
|
ref_key: "inputRef",
|
|
1273
1259
|
ref: i,
|
|
@@ -1280,7 +1266,7 @@ const jt = ["id", "type", "role", "required", "placeholder", "readonly", "disabl
|
|
|
1280
1266
|
readonly: e.readonly,
|
|
1281
1267
|
disabled: e.disabled,
|
|
1282
1268
|
maxlength: e.maxLength
|
|
1283
|
-
}, c.$attrs), null, 16,
|
|
1269
|
+
}, c.$attrs), null, 16, ao), [
|
|
1284
1270
|
[dt, n.value]
|
|
1285
1271
|
])
|
|
1286
1272
|
]),
|
|
@@ -1309,26 +1295,24 @@ const jt = ["id", "type", "role", "required", "placeholder", "readonly", "disabl
|
|
|
1309
1295
|
} : void 0
|
|
1310
1296
|
]), 1032, ["class", "for", "label", "size", "readonly", "disabled", "required"]));
|
|
1311
1297
|
}
|
|
1312
|
-
})
|
|
1313
|
-
Z(Qe);
|
|
1314
|
-
const Gt = ["data-key"], Wt = {
|
|
1298
|
+
}), nt = S(so), io = ["data-key"], ro = {
|
|
1315
1299
|
key: 0,
|
|
1316
1300
|
class: "q-select__loader"
|
|
1317
|
-
},
|
|
1301
|
+
}, uo = {
|
|
1318
1302
|
key: 2,
|
|
1319
1303
|
class: "q-select__loader"
|
|
1320
|
-
},
|
|
1304
|
+
}, co = {
|
|
1321
1305
|
noData: "No data available"
|
|
1322
|
-
},
|
|
1306
|
+
}, fo = {
|
|
1323
1307
|
chevron: {
|
|
1324
1308
|
icon: "chevron-down"
|
|
1325
1309
|
},
|
|
1326
1310
|
clear: {
|
|
1327
1311
|
icon: "close"
|
|
1328
1312
|
}
|
|
1329
|
-
},
|
|
1313
|
+
}, po = /* @__PURE__ */ L({
|
|
1330
1314
|
__name: "QCombobox",
|
|
1331
|
-
props: /* @__PURE__ */
|
|
1315
|
+
props: /* @__PURE__ */ Z({
|
|
1332
1316
|
id: { default: void 0 },
|
|
1333
1317
|
placeholder: { default: "" },
|
|
1334
1318
|
selectionMode: { default: "automatic" },
|
|
@@ -1345,8 +1329,8 @@ const Gt = ["data-key"], Wt = {
|
|
|
1345
1329
|
itemLabel: { default: "label" },
|
|
1346
1330
|
emptyValue: { type: [String, Number, Boolean, Symbol], default: void 0 },
|
|
1347
1331
|
size: { default: void 0 },
|
|
1348
|
-
texts: { default: () =>
|
|
1349
|
-
icons: { default: () =>
|
|
1332
|
+
texts: { default: () => co },
|
|
1333
|
+
icons: { default: () => fo },
|
|
1350
1334
|
class: { default: void 0 }
|
|
1351
1335
|
}, {
|
|
1352
1336
|
modelValue: {
|
|
@@ -1358,114 +1342,114 @@ const Gt = ["data-key"], Wt = {
|
|
|
1358
1342
|
search: { default: "" },
|
|
1359
1343
|
searchModifiers: {}
|
|
1360
1344
|
}),
|
|
1361
|
-
emits: /* @__PURE__ */
|
|
1345
|
+
emits: /* @__PURE__ */ Z(["before-show", "before-hide", "show", "hide"], ["update:modelValue", "update:open", "update:search"]),
|
|
1362
1346
|
setup(t, { expose: o, emit: e }) {
|
|
1363
|
-
const n = t, l = e, s = ne(t, "modelValue"), i = ne(t, "open"), a = ne(t, "search"), c =
|
|
1364
|
-
|
|
1365
|
-
const
|
|
1347
|
+
const n = t, l = e, s = ne(t, "modelValue"), i = ne(t, "open"), a = ne(t, "search"), c = V(void 0), v = V(null), $ = V(null), x = V(null), z = V(null);
|
|
1348
|
+
je(P);
|
|
1349
|
+
const T = k(() => n.clearable && !n.readonly && !n.disabled), I = k(() => {
|
|
1366
1350
|
var r;
|
|
1367
|
-
return n.filterMode === "manual" || !
|
|
1351
|
+
return n.filterMode === "manual" || !M.value ? n.items : (r = n.items) == null ? void 0 : r.filter(
|
|
1368
1352
|
(_) => _[n.itemLabel].toLowerCase().startsWith(a.value.toLowerCase())
|
|
1369
1353
|
);
|
|
1370
|
-
}),
|
|
1354
|
+
}), B = k(() => {
|
|
1371
1355
|
var r;
|
|
1372
1356
|
return (r = n.items) == null ? void 0 : r.find((_) => _[n.itemValue] === s.value);
|
|
1373
|
-
}), G = k(() =>
|
|
1357
|
+
}), G = k(() => B.value === void 0), J = k(() => {
|
|
1374
1358
|
const r = c.value;
|
|
1375
1359
|
if (r !== void 0 && I.value[r])
|
|
1376
1360
|
return I.value[r];
|
|
1377
|
-
}),
|
|
1361
|
+
}), H = k(() => {
|
|
1378
1362
|
var _;
|
|
1379
1363
|
if (c.value === void 0)
|
|
1380
1364
|
return;
|
|
1381
1365
|
const r = (_ = $.value) == null ? void 0 : _.getItem(c.value);
|
|
1382
1366
|
return r == null ? void 0 : r.id;
|
|
1383
|
-
}),
|
|
1367
|
+
}), M = k(() => {
|
|
1384
1368
|
var r;
|
|
1385
|
-
return a.value.length > 0 && a.value !== ((r =
|
|
1369
|
+
return a.value.length > 0 && a.value !== ((r = B.value) == null ? void 0 : r[n.itemLabel]);
|
|
1386
1370
|
});
|
|
1387
1371
|
function ee(r) {
|
|
1388
|
-
s.value = r,
|
|
1372
|
+
s.value = r, A();
|
|
1389
1373
|
}
|
|
1390
|
-
function
|
|
1374
|
+
function P() {
|
|
1391
1375
|
var _;
|
|
1392
|
-
const r = ((_ =
|
|
1376
|
+
const r = ((_ = B.value) == null ? void 0 : _[n.itemLabel]) || "";
|
|
1393
1377
|
a.value !== r && (a.value = r);
|
|
1394
1378
|
}
|
|
1395
1379
|
function te() {
|
|
1396
1380
|
i.value || n.readonly || n.disabled || (l("before-show"), i.value = !0, le());
|
|
1397
1381
|
}
|
|
1398
|
-
function
|
|
1382
|
+
function A() {
|
|
1399
1383
|
i.value && (l("before-hide"), i.value = !1, c.value = void 0);
|
|
1400
1384
|
}
|
|
1401
1385
|
function W() {
|
|
1402
|
-
i.value ?
|
|
1386
|
+
i.value ? A() : g();
|
|
1403
1387
|
}
|
|
1404
1388
|
function f() {
|
|
1405
|
-
|
|
1389
|
+
T.value && (s.value = n.emptyValue, c.value = void 0, le());
|
|
1406
1390
|
}
|
|
1407
1391
|
function g() {
|
|
1408
|
-
if (te(),
|
|
1409
|
-
const r = I.value.indexOf(
|
|
1410
|
-
r !== -1 && X(() =>
|
|
1392
|
+
if (te(), B.value !== void 0) {
|
|
1393
|
+
const r = I.value.indexOf(B.value);
|
|
1394
|
+
r !== -1 && X(() => N(r));
|
|
1411
1395
|
}
|
|
1412
1396
|
}
|
|
1413
1397
|
function d(r) {
|
|
1414
|
-
var _,
|
|
1398
|
+
var _, E;
|
|
1415
1399
|
if (!(!r.key || n.readonly || n.disabled))
|
|
1416
1400
|
if (["ArrowDown", "ArrowUp", "Home", "End"].includes(r.key) && (r.preventDefault(), r.stopPropagation()), r.key === "Escape")
|
|
1417
|
-
|
|
1401
|
+
P(), i.value && A();
|
|
1418
1402
|
else if (["ArrowDown", "ArrowUp"].includes(r.key))
|
|
1419
1403
|
i.value ? X(() => {
|
|
1420
1404
|
if (c.value === void 0)
|
|
1421
1405
|
p();
|
|
1422
1406
|
else {
|
|
1423
|
-
const
|
|
1424
|
-
oe(c.value,
|
|
1407
|
+
const O = r.key === "ArrowDown" ? "next" : "prev";
|
|
1408
|
+
oe(c.value, O);
|
|
1425
1409
|
}
|
|
1426
1410
|
}) : (te(), X(() => {
|
|
1427
|
-
r.key === "ArrowDown" ? p() :
|
|
1411
|
+
r.key === "ArrowDown" ? p() : F();
|
|
1428
1412
|
}));
|
|
1429
1413
|
else if (r.key === "Enter") {
|
|
1430
1414
|
if (J.value === void 0)
|
|
1431
1415
|
return;
|
|
1432
1416
|
ee(J.value[n.itemValue]);
|
|
1433
1417
|
} else
|
|
1434
|
-
r.key === "Home" ? c.value = (_ = $.value) == null ? void 0 : _.getFirstFocusableItemIndex() : r.key === "End" ? c.value = (
|
|
1418
|
+
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") && te();
|
|
1435
1419
|
}
|
|
1436
1420
|
function p() {
|
|
1437
1421
|
var r, _;
|
|
1438
1422
|
if (G.value)
|
|
1439
1423
|
c.value = (_ = $.value) == null ? void 0 : _.getFirstFocusableItemIndex();
|
|
1440
1424
|
else {
|
|
1441
|
-
const
|
|
1442
|
-
(
|
|
1425
|
+
const E = I.value.findIndex(
|
|
1426
|
+
(O) => O[n.itemValue] === s.value
|
|
1443
1427
|
);
|
|
1444
|
-
|
|
1428
|
+
E === -1 ? c.value = (r = $.value) == null ? void 0 : r.getFirstFocusableItemIndex() : c.value = E;
|
|
1445
1429
|
}
|
|
1446
1430
|
}
|
|
1447
|
-
function
|
|
1431
|
+
function F() {
|
|
1448
1432
|
var r;
|
|
1449
1433
|
c.value = (r = $.value) == null ? void 0 : r.getLastFocusableItemIndex();
|
|
1450
1434
|
}
|
|
1451
1435
|
function oe(r, _) {
|
|
1452
|
-
var
|
|
1453
|
-
c.value = (
|
|
1436
|
+
var E;
|
|
1437
|
+
c.value = (E = $.value) == null ? void 0 : E.getAdjacentItemIndex(r, _);
|
|
1454
1438
|
}
|
|
1455
|
-
function
|
|
1456
|
-
var ue,
|
|
1457
|
-
const _ = ((ue = x == null ? void 0 : x.value) == null ? void 0 : ue.$el) === r.relatedTarget,
|
|
1458
|
-
if (_ ||
|
|
1439
|
+
function U(r) {
|
|
1440
|
+
var ue, Te, Ee, De;
|
|
1441
|
+
const _ = ((ue = x == null ? void 0 : x.value) == null ? void 0 : ue.$el) === r.relatedTarget, E = (Ee = (Te = v == null ? void 0 : v.value) == null ? void 0 : Te.$el) == null ? void 0 : Ee.contains(r.relatedTarget), O = (De = z == null ? void 0 : z.value) == null ? void 0 : De.contains(r.relatedTarget);
|
|
1442
|
+
if (_ || O || E) {
|
|
1459
1443
|
r.preventDefault(), r.stopPropagation();
|
|
1460
1444
|
return;
|
|
1461
1445
|
}
|
|
1462
|
-
|
|
1446
|
+
A(), T.value && !a.value && (s.value = n.emptyValue), P();
|
|
1463
1447
|
}
|
|
1464
1448
|
function le() {
|
|
1465
1449
|
var r, _;
|
|
1466
1450
|
(_ = (r = v.value) == null ? void 0 : r.inputRef) == null || _.focus();
|
|
1467
1451
|
}
|
|
1468
|
-
function
|
|
1452
|
+
function _e() {
|
|
1469
1453
|
le();
|
|
1470
1454
|
}
|
|
1471
1455
|
function b() {
|
|
@@ -1474,22 +1458,22 @@ const Gt = ["data-key"], Wt = {
|
|
|
1474
1458
|
function de() {
|
|
1475
1459
|
l("hide");
|
|
1476
1460
|
}
|
|
1477
|
-
function
|
|
1478
|
-
var
|
|
1479
|
-
const _ = (
|
|
1461
|
+
function N(r) {
|
|
1462
|
+
var E;
|
|
1463
|
+
const _ = (E = $.value) == null ? void 0 : E.getItem(r);
|
|
1480
1464
|
$.value && ($.value.$el.scrollTop = _ == null ? void 0 : _.offsetTop);
|
|
1481
1465
|
}
|
|
1482
|
-
return R(s,
|
|
1466
|
+
return R(s, P), R(
|
|
1483
1467
|
() => n.items,
|
|
1484
1468
|
(r, _) => {
|
|
1485
1469
|
if (!G.value) {
|
|
1486
|
-
const
|
|
1487
|
-
a.value === (
|
|
1470
|
+
const E = _.find((O) => O[n.itemValue] === s.value);
|
|
1471
|
+
a.value === (E == null ? void 0 : E[n.itemLabel]) && P();
|
|
1488
1472
|
}
|
|
1489
1473
|
},
|
|
1490
1474
|
{ deep: !0 }
|
|
1491
1475
|
), R(c, (r) => {
|
|
1492
|
-
r !== void 0 &&
|
|
1476
|
+
r !== void 0 && N(r);
|
|
1493
1477
|
}), R(a, (r) => {
|
|
1494
1478
|
r && i.value && n.selectionMode === "automatic" && X(p);
|
|
1495
1479
|
}), R(
|
|
@@ -1500,11 +1484,11 @@ const Gt = ["data-key"], Wt = {
|
|
|
1500
1484
|
), o({
|
|
1501
1485
|
triggerEl: v
|
|
1502
1486
|
}), (r, _) => {
|
|
1503
|
-
var
|
|
1487
|
+
var E;
|
|
1504
1488
|
return u(), m(se, null, [
|
|
1505
|
-
|
|
1489
|
+
Q(y(nt), {
|
|
1506
1490
|
modelValue: a.value,
|
|
1507
|
-
"onUpdate:modelValue": _[0] || (_[0] = (
|
|
1491
|
+
"onUpdate:modelValue": _[0] || (_[0] = (O) => a.value = O),
|
|
1508
1492
|
id: n.id,
|
|
1509
1493
|
label: n.label,
|
|
1510
1494
|
required: n.required,
|
|
@@ -1512,7 +1496,7 @@ const Gt = ["data-key"], Wt = {
|
|
|
1512
1496
|
ref: v,
|
|
1513
1497
|
role: "combobox",
|
|
1514
1498
|
placeholder: n.placeholder,
|
|
1515
|
-
class:
|
|
1499
|
+
class: C([
|
|
1516
1500
|
"q-combobox",
|
|
1517
1501
|
{
|
|
1518
1502
|
"q-combobox--readonly": n.readonly,
|
|
@@ -1528,12 +1512,12 @@ const Gt = ["data-key"], Wt = {
|
|
|
1528
1512
|
"aria-expanded": i.value,
|
|
1529
1513
|
"aria-haspopup": "listbox",
|
|
1530
1514
|
"aria-autocomplete": "list",
|
|
1531
|
-
"aria-activedescendant":
|
|
1515
|
+
"aria-activedescendant": H.value,
|
|
1532
1516
|
size: n.size,
|
|
1533
1517
|
onClick: g,
|
|
1534
|
-
onFocusout:
|
|
1518
|
+
onFocusout: U,
|
|
1535
1519
|
onKeydown: ce(d, ["stop"])
|
|
1536
|
-
},
|
|
1520
|
+
}, $e({
|
|
1537
1521
|
"label.prepend": w(() => [
|
|
1538
1522
|
h(r.$slots, "label.prepend")
|
|
1539
1523
|
]),
|
|
@@ -1542,7 +1526,7 @@ const Gt = ["data-key"], Wt = {
|
|
|
1542
1526
|
]),
|
|
1543
1527
|
append: w(() => [
|
|
1544
1528
|
h(r.$slots, "append"),
|
|
1545
|
-
|
|
1529
|
+
T.value && a.value ? (u(), D(y(pe), {
|
|
1546
1530
|
key: 0,
|
|
1547
1531
|
class: "q-combobox__clear",
|
|
1548
1532
|
"b-style": "plain",
|
|
@@ -1551,11 +1535,11 @@ const Gt = ["data-key"], Wt = {
|
|
|
1551
1535
|
onClick: f
|
|
1552
1536
|
}, {
|
|
1553
1537
|
default: w(() => [
|
|
1554
|
-
|
|
1538
|
+
Q(y(Y), ae(re(n.icons.clear)), null, 16)
|
|
1555
1539
|
]),
|
|
1556
1540
|
_: 1
|
|
1557
1541
|
})) : q("", !0),
|
|
1558
|
-
n.readonly ? q("", !0) : (u(),
|
|
1542
|
+
n.readonly ? q("", !0) : (u(), D(y(pe), {
|
|
1559
1543
|
key: 1,
|
|
1560
1544
|
ref_key: "toggleRef",
|
|
1561
1545
|
ref: x,
|
|
@@ -1567,7 +1551,7 @@ const Gt = ["data-key"], Wt = {
|
|
|
1567
1551
|
onMousedown: ce(W, ["stop", "prevent"])
|
|
1568
1552
|
}, {
|
|
1569
1553
|
default: w(() => [
|
|
1570
|
-
|
|
1554
|
+
Q(y(Y), ae(re(n.icons.chevron)), null, 16)
|
|
1571
1555
|
]),
|
|
1572
1556
|
_: 1
|
|
1573
1557
|
}, 8, ["disabled"]))
|
|
@@ -1589,34 +1573,34 @@ const Gt = ["data-key"], Wt = {
|
|
|
1589
1573
|
key: "1"
|
|
1590
1574
|
} : void 0
|
|
1591
1575
|
]), 1032, ["modelValue", "id", "label", "required", "placeholder", "class", "readonly", "disabled", "data-loading", "aria-expanded", "aria-activedescendant", "size"]),
|
|
1592
|
-
|
|
1576
|
+
Q(y(ge), {
|
|
1593
1577
|
modelValue: i.value,
|
|
1594
|
-
"onUpdate:modelValue": _[2] || (_[2] = (
|
|
1578
|
+
"onUpdate:modelValue": _[2] || (_[2] = (O) => i.value = O),
|
|
1595
1579
|
spy: "",
|
|
1596
1580
|
"non-modal": "",
|
|
1597
1581
|
trigger: "manual",
|
|
1598
1582
|
placement: "bottom-start",
|
|
1599
1583
|
width: "anchor",
|
|
1600
1584
|
offset: 4,
|
|
1601
|
-
anchor: (
|
|
1585
|
+
anchor: (E = v.value) == null ? void 0 : E.$el,
|
|
1602
1586
|
onEnter: b,
|
|
1603
1587
|
onLeave: de
|
|
1604
1588
|
}, {
|
|
1605
1589
|
default: w(() => {
|
|
1606
|
-
var
|
|
1590
|
+
var O;
|
|
1607
1591
|
return [
|
|
1608
|
-
|
|
1592
|
+
K("div", {
|
|
1609
1593
|
ref_key: "contentRef",
|
|
1610
|
-
ref:
|
|
1594
|
+
ref: z,
|
|
1611
1595
|
class: "q-select__body",
|
|
1612
1596
|
"data-testid": "combobox-dropdown",
|
|
1613
1597
|
"data-key": n.id,
|
|
1614
|
-
onFocusout:
|
|
1598
|
+
onFocusout: U
|
|
1615
1599
|
}, [
|
|
1616
1600
|
h(r.$slots, "body.prepend"),
|
|
1617
|
-
n.loading ? (u(), m("div",
|
|
1618
|
-
|
|
1619
|
-
])) : I.value.length ? (u(),
|
|
1601
|
+
n.loading ? (u(), m("div", ro, [
|
|
1602
|
+
Q(y(qe), { size: 24 })
|
|
1603
|
+
])) : I.value.length ? (u(), D(y(Ce), {
|
|
1620
1604
|
key: 1,
|
|
1621
1605
|
ref_key: "listRef",
|
|
1622
1606
|
ref: $,
|
|
@@ -1626,20 +1610,20 @@ const Gt = ["data-key"], Wt = {
|
|
|
1626
1610
|
_[1] || (_[1] = (ue) => s.value = ue),
|
|
1627
1611
|
ee
|
|
1628
1612
|
],
|
|
1629
|
-
highlighted: (
|
|
1613
|
+
highlighted: (O = J.value) == null ? void 0 : O[n.itemValue],
|
|
1630
1614
|
items: I.value,
|
|
1631
1615
|
groups: r.groups,
|
|
1632
1616
|
"item-label": n.itemLabel,
|
|
1633
1617
|
"item-value": n.itemValue,
|
|
1634
|
-
onMouseup:
|
|
1618
|
+
onMouseup: _e
|
|
1635
1619
|
}, {
|
|
1636
1620
|
item: w(({ item: ue }) => [
|
|
1637
1621
|
h(r.$slots, "item", { item: ue })
|
|
1638
1622
|
]),
|
|
1639
1623
|
_: 3
|
|
1640
|
-
}, 8, ["modelValue", "highlighted", "items", "groups", "item-label", "item-value"])) : (u(), m("div",
|
|
1624
|
+
}, 8, ["modelValue", "highlighted", "items", "groups", "item-label", "item-value"])) : (u(), m("div", uo, j(r.texts.noData), 1)),
|
|
1641
1625
|
h(r.$slots, "body.append")
|
|
1642
|
-
], 40,
|
|
1626
|
+
], 40, io)
|
|
1643
1627
|
];
|
|
1644
1628
|
}),
|
|
1645
1629
|
_: 3
|
|
@@ -1647,13 +1631,13 @@ const Gt = ["data-key"], Wt = {
|
|
|
1647
1631
|
], 64);
|
|
1648
1632
|
};
|
|
1649
1633
|
}
|
|
1650
|
-
}),
|
|
1634
|
+
}), mo = S(po), vo = {
|
|
1651
1635
|
key: 0,
|
|
1652
1636
|
class: "q-input-group__prepend"
|
|
1653
|
-
},
|
|
1637
|
+
}, ho = { key: 0 }, yo = {
|
|
1654
1638
|
key: 1,
|
|
1655
1639
|
class: "q-input-group__append"
|
|
1656
|
-
},
|
|
1640
|
+
}, bo = { key: 0 }, go = /* @__PURE__ */ L({
|
|
1657
1641
|
__name: "QInputGroup",
|
|
1658
1642
|
props: {
|
|
1659
1643
|
id: { default: void 0 },
|
|
@@ -1666,28 +1650,28 @@ const Gt = ["data-key"], Wt = {
|
|
|
1666
1650
|
},
|
|
1667
1651
|
setup(t) {
|
|
1668
1652
|
const o = t;
|
|
1669
|
-
return
|
|
1653
|
+
return We({
|
|
1670
1654
|
QField: {
|
|
1671
1655
|
size: "block"
|
|
1672
1656
|
}
|
|
1673
|
-
}), (e, n) => (u(),
|
|
1657
|
+
}), (e, n) => (u(), D(y(Ie), {
|
|
1674
1658
|
id: o.id,
|
|
1675
|
-
class:
|
|
1659
|
+
class: C(["q-input-group", o.class]),
|
|
1676
1660
|
label: o.label,
|
|
1677
1661
|
required: o.required,
|
|
1678
1662
|
size: o.size
|
|
1679
|
-
},
|
|
1663
|
+
}, $e({
|
|
1680
1664
|
default: w(() => [
|
|
1681
|
-
e.$slots.prepend || o.prependIcon ? (u(), m("div",
|
|
1682
|
-
o.prependIcon ? (u(), m("span",
|
|
1683
|
-
|
|
1665
|
+
e.$slots.prepend || o.prependIcon ? (u(), m("div", vo, [
|
|
1666
|
+
o.prependIcon ? (u(), m("span", ho, [
|
|
1667
|
+
Q(y(Y), ae(re(o.prependIcon)), null, 16)
|
|
1684
1668
|
])) : q("", !0),
|
|
1685
1669
|
h(e.$slots, "prepend")
|
|
1686
1670
|
])) : q("", !0),
|
|
1687
1671
|
h(e.$slots, "default"),
|
|
1688
|
-
e.$slots.append || o.appendIcon ? (u(), m("div",
|
|
1689
|
-
o.appendIcon ? (u(), m("span",
|
|
1690
|
-
|
|
1672
|
+
e.$slots.append || o.appendIcon ? (u(), m("div", yo, [
|
|
1673
|
+
o.appendIcon ? (u(), m("span", bo, [
|
|
1674
|
+
Q(y(Y), ae(re(o.appendIcon)), null, 16)
|
|
1691
1675
|
])) : q("", !0),
|
|
1692
1676
|
h(e.$slots, "append")
|
|
1693
1677
|
])) : q("", !0)
|
|
@@ -1703,7 +1687,7 @@ const Gt = ["data-key"], Wt = {
|
|
|
1703
1687
|
} : void 0
|
|
1704
1688
|
]), 1032, ["id", "class", "label", "required", "size"]));
|
|
1705
1689
|
}
|
|
1706
|
-
}),
|
|
1690
|
+
}), _o = S(go), ko = /* @__PURE__ */ L({
|
|
1707
1691
|
__name: "QLineLoader",
|
|
1708
1692
|
props: {
|
|
1709
1693
|
class: { default: void 0 }
|
|
@@ -1711,19 +1695,19 @@ const Gt = ["data-key"], Wt = {
|
|
|
1711
1695
|
setup(t) {
|
|
1712
1696
|
const o = t;
|
|
1713
1697
|
return (e, n) => (u(), m("div", {
|
|
1714
|
-
class:
|
|
1698
|
+
class: C(["q-line-loader", o.class])
|
|
1715
1699
|
}, null, 2));
|
|
1716
1700
|
}
|
|
1717
|
-
}),
|
|
1701
|
+
}), wo = S(ko), $o = {
|
|
1718
1702
|
key: 0,
|
|
1719
1703
|
class: "q-popover__header"
|
|
1720
|
-
},
|
|
1704
|
+
}, qo = {
|
|
1721
1705
|
key: 1,
|
|
1722
1706
|
class: "q-popover__body"
|
|
1723
|
-
},
|
|
1707
|
+
}, Io = ["innerHTML"], xo = { key: 1 }, Lo = /* @__PURE__ */ L({
|
|
1724
1708
|
inheritAttrs: !1,
|
|
1725
1709
|
__name: "QPopover",
|
|
1726
|
-
props: /* @__PURE__ */
|
|
1710
|
+
props: /* @__PURE__ */ Z({
|
|
1727
1711
|
anchor: {},
|
|
1728
1712
|
arrow: { type: Boolean, default: !0 },
|
|
1729
1713
|
attach: { default: "body" },
|
|
@@ -1740,7 +1724,7 @@ const Gt = ["data-key"], Wt = {
|
|
|
1740
1724
|
emits: ["update:modelValue"],
|
|
1741
1725
|
setup(t) {
|
|
1742
1726
|
const o = t, e = ne(t, "modelValue");
|
|
1743
|
-
return (n, l) => (u(),
|
|
1727
|
+
return (n, l) => (u(), D(y(ge), {
|
|
1744
1728
|
"model-value": e.value,
|
|
1745
1729
|
class: "q-popover",
|
|
1746
1730
|
trigger: "click",
|
|
@@ -1752,42 +1736,42 @@ const Gt = ["data-key"], Wt = {
|
|
|
1752
1736
|
placement: o.placement
|
|
1753
1737
|
}, {
|
|
1754
1738
|
default: w(() => [
|
|
1755
|
-
o.title || n.$slots.header ? (u(), m("h3",
|
|
1756
|
-
|
|
1739
|
+
o.title || n.$slots.header ? (u(), m("h3", $o, [
|
|
1740
|
+
ve(j(o.title) + " ", 1),
|
|
1757
1741
|
h(n.$slots, "header")
|
|
1758
1742
|
])) : q("", !0),
|
|
1759
|
-
o.text || n.$slots.body ? (u(), m("div",
|
|
1743
|
+
o.text || n.$slots.body ? (u(), m("div", qo, [
|
|
1760
1744
|
o.html ? (u(), m("span", {
|
|
1761
1745
|
key: 0,
|
|
1762
1746
|
innerHTML: o.text
|
|
1763
|
-
}, null, 8,
|
|
1747
|
+
}, null, 8, Io)) : (u(), m("span", xo, j(o.text), 1)),
|
|
1764
1748
|
h(n.$slots, "body")
|
|
1765
1749
|
])) : q("", !0)
|
|
1766
1750
|
]),
|
|
1767
1751
|
_: 3
|
|
1768
1752
|
}, 8, ["model-value", "anchor", "arrow", "attach", "inline", "disabled", "placement"]));
|
|
1769
1753
|
}
|
|
1770
|
-
}),
|
|
1754
|
+
}), So = S(Lo), Bo = {
|
|
1771
1755
|
key: 0,
|
|
1772
1756
|
class: "q-select__value"
|
|
1773
|
-
},
|
|
1757
|
+
}, Vo = {
|
|
1774
1758
|
key: 1,
|
|
1775
1759
|
class: "q-select__placeholder"
|
|
1776
|
-
},
|
|
1760
|
+
}, Co = ["data-key"], To = {
|
|
1777
1761
|
key: 0,
|
|
1778
1762
|
class: "q-select__loader"
|
|
1779
|
-
},
|
|
1763
|
+
}, Eo = {
|
|
1780
1764
|
placeholder: "Choose..."
|
|
1781
|
-
},
|
|
1765
|
+
}, Do = {
|
|
1782
1766
|
chevron: {
|
|
1783
1767
|
icon: "chevron-down"
|
|
1784
1768
|
},
|
|
1785
1769
|
clear: {
|
|
1786
1770
|
icon: "close"
|
|
1787
1771
|
}
|
|
1788
|
-
},
|
|
1772
|
+
}, Ao = /* @__PURE__ */ L({
|
|
1789
1773
|
__name: "QSelect",
|
|
1790
|
-
props: /* @__PURE__ */
|
|
1774
|
+
props: /* @__PURE__ */ Z({
|
|
1791
1775
|
id: { default: void 0 },
|
|
1792
1776
|
label: { default: "" },
|
|
1793
1777
|
clearable: { type: Boolean },
|
|
@@ -1795,14 +1779,14 @@ const Gt = ["data-key"], Wt = {
|
|
|
1795
1779
|
disabled: { type: Boolean },
|
|
1796
1780
|
required: { type: Boolean },
|
|
1797
1781
|
loading: { type: Boolean },
|
|
1798
|
-
icons: { default: () =>
|
|
1782
|
+
icons: { default: () => Do },
|
|
1799
1783
|
items: {},
|
|
1800
1784
|
groups: { default: () => [] },
|
|
1801
1785
|
itemValue: { default: "key" },
|
|
1802
1786
|
itemLabel: { default: "label" },
|
|
1803
1787
|
emptyValue: { type: [String, Number, Boolean, Symbol], default: void 0 },
|
|
1804
1788
|
size: { default: void 0 },
|
|
1805
|
-
texts: { default: () =>
|
|
1789
|
+
texts: { default: () => Eo },
|
|
1806
1790
|
class: { default: "" }
|
|
1807
1791
|
}, {
|
|
1808
1792
|
modelValue: {
|
|
@@ -1810,41 +1794,41 @@ const Gt = ["data-key"], Wt = {
|
|
|
1810
1794
|
},
|
|
1811
1795
|
modelModifiers: {}
|
|
1812
1796
|
}),
|
|
1813
|
-
emits: /* @__PURE__ */
|
|
1797
|
+
emits: /* @__PURE__ */ Z(["before-show", "before-hide", "show", "hide"], ["update:modelValue"]),
|
|
1814
1798
|
setup(t, { emit: o }) {
|
|
1815
|
-
const e = t, n = o, l = ne(t, "modelValue"), s =
|
|
1799
|
+
const e = t, n = o, l = ne(t, "modelValue"), s = V(!1), i = V(""), a = V(null), c = V(null), v = V(null), $ = k(() => x.value === void 0), x = k(
|
|
1816
1800
|
() => {
|
|
1817
1801
|
var d;
|
|
1818
1802
|
return (d = e.items) == null ? void 0 : d.find((p) => p[e.itemValue] === l.value);
|
|
1819
1803
|
}
|
|
1820
|
-
),
|
|
1804
|
+
), z = k(
|
|
1821
1805
|
() => x.value ? x.value[e.itemLabel] : ""
|
|
1822
|
-
),
|
|
1806
|
+
), T = k(
|
|
1823
1807
|
() => e.clearable && !e.readonly && !e.disabled && !e.loading
|
|
1824
1808
|
);
|
|
1825
1809
|
function I(d) {
|
|
1826
|
-
l.value = d,
|
|
1810
|
+
l.value = d, H();
|
|
1827
1811
|
}
|
|
1828
|
-
function
|
|
1829
|
-
|
|
1812
|
+
function B() {
|
|
1813
|
+
T.value && I(e.emptyValue);
|
|
1830
1814
|
}
|
|
1831
1815
|
function G(d) {
|
|
1832
|
-
var p,
|
|
1833
|
-
!((p = v.value) != null && p.contains(d.relatedTarget)) && !((oe = (
|
|
1816
|
+
var p, F, oe;
|
|
1817
|
+
!((p = v.value) != null && p.contains(d.relatedTarget)) && !((oe = (F = a.value) == null ? void 0 : F.fieldRef) != null && oe.contains(d.relatedTarget)) && H();
|
|
1834
1818
|
}
|
|
1835
1819
|
function J() {
|
|
1836
1820
|
s.value || (n("before-show"), s.value = !0);
|
|
1837
1821
|
}
|
|
1838
|
-
function
|
|
1822
|
+
function H() {
|
|
1839
1823
|
s.value && (n("before-hide"), s.value = !1);
|
|
1840
1824
|
}
|
|
1841
|
-
function
|
|
1842
|
-
e.readonly || e.disabled || (s.value ?
|
|
1825
|
+
function M() {
|
|
1826
|
+
e.readonly || e.disabled || (s.value ? H() : J());
|
|
1843
1827
|
}
|
|
1844
1828
|
let ee;
|
|
1845
|
-
function
|
|
1829
|
+
function P(d) {
|
|
1846
1830
|
if (!(!d.key || e.readonly || e.disabled)) {
|
|
1847
|
-
if (window.clearTimeout(ee), ["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 :
|
|
1831
|
+
if (window.clearTimeout(ee), ["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)) {
|
|
1848
1832
|
i.value += d.key.toLowerCase();
|
|
1849
1833
|
for (let p = 0; p < e.items.length; p++)
|
|
1850
1834
|
if (e.items[p][e.itemLabel].toLowerCase().startsWith(i.value)) {
|
|
@@ -1861,7 +1845,7 @@ const Gt = ["data-key"], Wt = {
|
|
|
1861
1845
|
var d;
|
|
1862
1846
|
e.loading ? (d = v.value) == null || d.focus() : f(), n("show");
|
|
1863
1847
|
}
|
|
1864
|
-
function
|
|
1848
|
+
function A() {
|
|
1865
1849
|
W(), n("hide");
|
|
1866
1850
|
}
|
|
1867
1851
|
function W() {
|
|
@@ -1882,9 +1866,9 @@ const Gt = ["data-key"], Wt = {
|
|
|
1882
1866
|
!d && s.value && X(f);
|
|
1883
1867
|
}
|
|
1884
1868
|
), (d, p) => {
|
|
1885
|
-
var
|
|
1869
|
+
var F, oe;
|
|
1886
1870
|
return u(), m(se, null, [
|
|
1887
|
-
|
|
1871
|
+
Q(y(Ie), {
|
|
1888
1872
|
id: e.id,
|
|
1889
1873
|
label: e.label,
|
|
1890
1874
|
required: e.required,
|
|
@@ -1892,7 +1876,7 @@ const Gt = ["data-key"], Wt = {
|
|
|
1892
1876
|
ref: a,
|
|
1893
1877
|
role: "combobox",
|
|
1894
1878
|
tabindex: e.disabled ? -1 : 0,
|
|
1895
|
-
class:
|
|
1879
|
+
class: C([
|
|
1896
1880
|
"q-select",
|
|
1897
1881
|
{
|
|
1898
1882
|
"q-select--readonly": e.readonly,
|
|
@@ -1907,55 +1891,55 @@ const Gt = ["data-key"], Wt = {
|
|
|
1907
1891
|
"aria-expanded": s.value,
|
|
1908
1892
|
"aria-haspopup": "listbox",
|
|
1909
1893
|
size: e.size,
|
|
1910
|
-
onClick:
|
|
1911
|
-
onKeydown: ce(
|
|
1912
|
-
},
|
|
1894
|
+
onClick: M,
|
|
1895
|
+
onKeydown: ce(P, ["stop"])
|
|
1896
|
+
}, $e({
|
|
1913
1897
|
append: w(() => [
|
|
1914
1898
|
h(d.$slots, "append"),
|
|
1915
|
-
|
|
1899
|
+
T.value && l.value ? (u(), D(y(pe), {
|
|
1916
1900
|
key: 0,
|
|
1917
1901
|
class: "q-select__clear",
|
|
1918
1902
|
"b-style": "plain",
|
|
1919
1903
|
borderless: "",
|
|
1920
1904
|
tabindex: "-1",
|
|
1921
|
-
onClick:
|
|
1905
|
+
onClick: B
|
|
1922
1906
|
}, {
|
|
1923
1907
|
default: w(() => [
|
|
1924
|
-
|
|
1908
|
+
Q(y(Y), ae(re(e.icons.clear)), null, 16)
|
|
1925
1909
|
]),
|
|
1926
1910
|
_: 1
|
|
1927
1911
|
})) : q("", !0),
|
|
1928
|
-
e.readonly ? q("", !0) : (u(),
|
|
1912
|
+
e.readonly ? q("", !0) : (u(), D(y(pe), {
|
|
1929
1913
|
key: 1,
|
|
1930
1914
|
class: "q-select__chevron",
|
|
1931
1915
|
"b-style": "plain",
|
|
1932
1916
|
borderless: "",
|
|
1933
1917
|
tabindex: "-1",
|
|
1934
1918
|
disabled: e.disabled,
|
|
1935
|
-
onClick:
|
|
1919
|
+
onClick: M
|
|
1936
1920
|
}, {
|
|
1937
1921
|
default: w(() => [
|
|
1938
|
-
|
|
1922
|
+
Q(y(Y), ae(re(e.icons.chevron)), null, 16)
|
|
1939
1923
|
]),
|
|
1940
1924
|
_: 1
|
|
1941
1925
|
}, 8, ["disabled"]))
|
|
1942
1926
|
]),
|
|
1943
1927
|
default: w(() => [
|
|
1944
|
-
$.value ? (u(), m("span",
|
|
1928
|
+
$.value ? (u(), m("span", Vo, [
|
|
1945
1929
|
!e.readonly && !e.disabled ? (u(), m(se, { key: 0 }, [
|
|
1946
|
-
|
|
1930
|
+
ve(j(d.texts.placeholder), 1)
|
|
1947
1931
|
], 64)) : q("", !0)
|
|
1948
|
-
])) : (u(), m("span",
|
|
1932
|
+
])) : (u(), m("span", Bo, j(z.value), 1))
|
|
1949
1933
|
]),
|
|
1950
1934
|
_: 2
|
|
1951
1935
|
}, [
|
|
1952
|
-
(
|
|
1936
|
+
(F = x.value) != null && F.icon || d.$slots.prepend ? {
|
|
1953
1937
|
name: "prepend",
|
|
1954
1938
|
fn: w(() => {
|
|
1955
|
-
var
|
|
1939
|
+
var U, le;
|
|
1956
1940
|
return [
|
|
1957
1941
|
h(d.$slots, "prepend"),
|
|
1958
|
-
(
|
|
1942
|
+
(U = x.value) != null && U.icon ? (u(), D(y(Y), ae(fe({ key: 0 }, (le = x.value) == null ? void 0 : le.icon)), null, 16)) : q("", !0)
|
|
1959
1943
|
];
|
|
1960
1944
|
}),
|
|
1961
1945
|
key: "0"
|
|
@@ -1968,9 +1952,9 @@ const Gt = ["data-key"], Wt = {
|
|
|
1968
1952
|
key: "1"
|
|
1969
1953
|
} : void 0
|
|
1970
1954
|
]), 1032, ["id", "label", "required", "tabindex", "class", "readonly", "disabled", "data-loading", "aria-expanded", "size"]),
|
|
1971
|
-
|
|
1955
|
+
Q(y(ge), {
|
|
1972
1956
|
modelValue: s.value,
|
|
1973
|
-
"onUpdate:modelValue": p[1] || (p[1] = (
|
|
1957
|
+
"onUpdate:modelValue": p[1] || (p[1] = (U) => s.value = U),
|
|
1974
1958
|
spy: "",
|
|
1975
1959
|
trigger: "manual",
|
|
1976
1960
|
placement: "bottom-start",
|
|
@@ -1979,10 +1963,10 @@ const Gt = ["data-key"], Wt = {
|
|
|
1979
1963
|
anchor: (oe = a.value) == null ? void 0 : oe.$el,
|
|
1980
1964
|
offset: 2,
|
|
1981
1965
|
onEnter: te,
|
|
1982
|
-
onLeave:
|
|
1966
|
+
onLeave: A
|
|
1983
1967
|
}, {
|
|
1984
1968
|
default: w(() => [
|
|
1985
|
-
|
|
1969
|
+
K("div", {
|
|
1986
1970
|
ref_key: "contentRef",
|
|
1987
1971
|
ref: v,
|
|
1988
1972
|
"data-testid": "combobox-dropdown",
|
|
@@ -1990,19 +1974,19 @@ const Gt = ["data-key"], Wt = {
|
|
|
1990
1974
|
class: "q-select__body",
|
|
1991
1975
|
tabindex: "-1",
|
|
1992
1976
|
onFocusout: G,
|
|
1993
|
-
onKeydown: ce(
|
|
1977
|
+
onKeydown: ce(P, ["stop"])
|
|
1994
1978
|
}, [
|
|
1995
1979
|
h(d.$slots, "body.prepend"),
|
|
1996
|
-
e.loading ? (u(), m("div",
|
|
1997
|
-
|
|
1998
|
-
])) : (u(),
|
|
1980
|
+
e.loading ? (u(), m("div", To, [
|
|
1981
|
+
Q(y(qe), { size: 24 })
|
|
1982
|
+
])) : (u(), D(y(Ce), {
|
|
1999
1983
|
key: 1,
|
|
2000
1984
|
ref_key: "listRef",
|
|
2001
1985
|
ref: c,
|
|
2002
1986
|
class: "q-select__items",
|
|
2003
1987
|
modelValue: l.value,
|
|
2004
1988
|
"onUpdate:modelValue": [
|
|
2005
|
-
p[0] || (p[0] = (
|
|
1989
|
+
p[0] || (p[0] = (U) => l.value = U),
|
|
2006
1990
|
I
|
|
2007
1991
|
],
|
|
2008
1992
|
items: e.items,
|
|
@@ -2010,22 +1994,22 @@ const Gt = ["data-key"], Wt = {
|
|
|
2010
1994
|
"item-label": e.itemLabel,
|
|
2011
1995
|
"item-value": e.itemValue
|
|
2012
1996
|
}, {
|
|
2013
|
-
item: w(({ item:
|
|
2014
|
-
h(d.$slots, "item", { item:
|
|
1997
|
+
item: w(({ item: U }) => [
|
|
1998
|
+
h(d.$slots, "item", { item: U })
|
|
2015
1999
|
]),
|
|
2016
2000
|
_: 3
|
|
2017
2001
|
}, 8, ["modelValue", "items", "groups", "item-label", "item-value"])),
|
|
2018
2002
|
h(d.$slots, "body.append")
|
|
2019
|
-
], 40,
|
|
2003
|
+
], 40, Co)
|
|
2020
2004
|
]),
|
|
2021
2005
|
_: 3
|
|
2022
2006
|
}, 8, ["modelValue", "anchor"])
|
|
2023
2007
|
], 64);
|
|
2024
2008
|
};
|
|
2025
2009
|
}
|
|
2026
|
-
}),
|
|
2027
|
-
|
|
2028
|
-
],
|
|
2010
|
+
}), zo = S(Ao), Qo = /* @__PURE__ */ K("div", { class: "q-skeleton-loader__bone" }, null, -1), Mo = [
|
|
2011
|
+
Qo
|
|
2012
|
+
], Fo = /* @__PURE__ */ L({
|
|
2029
2013
|
__name: "QSkeletonLoader",
|
|
2030
2014
|
props: {
|
|
2031
2015
|
type: { default: void 0 },
|
|
@@ -2041,11 +2025,11 @@ const Gt = ["data-key"], Wt = {
|
|
|
2041
2025
|
};
|
|
2042
2026
|
});
|
|
2043
2027
|
return (l, s) => (u(), m("div", {
|
|
2044
|
-
class:
|
|
2028
|
+
class: C(["q-skeleton-loader", e.value]),
|
|
2045
2029
|
style: ie(n.value)
|
|
2046
|
-
},
|
|
2030
|
+
}, Mo, 6));
|
|
2047
2031
|
}
|
|
2048
|
-
}),
|
|
2032
|
+
}), Oo = S(Fo), Po = /* @__PURE__ */ L({
|
|
2049
2033
|
__name: "QThemeProvider",
|
|
2050
2034
|
props: {
|
|
2051
2035
|
theme: {}
|
|
@@ -2053,14 +2037,14 @@ const Gt = ["data-key"], Wt = {
|
|
|
2053
2037
|
setup(t) {
|
|
2054
2038
|
const o = t;
|
|
2055
2039
|
return (e, n) => (u(), m("div", {
|
|
2056
|
-
class:
|
|
2040
|
+
class: C(["q-theme-provider", `q-theme--${o.theme}`])
|
|
2057
2041
|
}, [
|
|
2058
2042
|
h(e.$slots, "default")
|
|
2059
2043
|
], 2));
|
|
2060
2044
|
}
|
|
2061
|
-
}),
|
|
2045
|
+
}), Uo = S(Po), No = ["innerHTML"], Ho = { key: 1 }, Ko = /* @__PURE__ */ L({
|
|
2062
2046
|
__name: "QTooltip",
|
|
2063
|
-
props: /* @__PURE__ */
|
|
2047
|
+
props: /* @__PURE__ */ Z({
|
|
2064
2048
|
id: { default: void 0 },
|
|
2065
2049
|
anchor: {},
|
|
2066
2050
|
appearance: { default: "inverted" },
|
|
@@ -2080,12 +2064,12 @@ const Gt = ["data-key"], Wt = {
|
|
|
2080
2064
|
}),
|
|
2081
2065
|
emits: ["update:modelValue"],
|
|
2082
2066
|
setup(t) {
|
|
2083
|
-
const o = t, e = ne(t, "modelValue"), n =
|
|
2067
|
+
const o = t, e = ne(t, "modelValue"), n = ye(o.id);
|
|
2084
2068
|
return (l, s) => (u(), m(se, null, [
|
|
2085
2069
|
h(l.$slots, "anchor", {
|
|
2086
2070
|
props: { "aria-describedby": y(n) }
|
|
2087
2071
|
}),
|
|
2088
|
-
|
|
2072
|
+
Q(y(ge), {
|
|
2089
2073
|
"model-value": e.value,
|
|
2090
2074
|
anchor: o.anchor,
|
|
2091
2075
|
role: "tooltip",
|
|
@@ -2095,7 +2079,7 @@ const Gt = ["data-key"], Wt = {
|
|
|
2095
2079
|
arrow: o.arrow,
|
|
2096
2080
|
attach: o.attach,
|
|
2097
2081
|
inline: o.inline,
|
|
2098
|
-
class:
|
|
2082
|
+
class: C(["q-tooltip", o.class]),
|
|
2099
2083
|
delay: o.delay,
|
|
2100
2084
|
disabled: o.disabled,
|
|
2101
2085
|
placement: o.placement,
|
|
@@ -2105,67 +2089,67 @@ const Gt = ["data-key"], Wt = {
|
|
|
2105
2089
|
o.html ? (u(), m("span", {
|
|
2106
2090
|
key: 0,
|
|
2107
2091
|
innerHTML: o.text
|
|
2108
|
-
}, null, 8,
|
|
2092
|
+
}, null, 8, No)) : (u(), m("span", Ho, j(o.text), 1))
|
|
2109
2093
|
]),
|
|
2110
2094
|
_: 1
|
|
2111
2095
|
}, 8, ["model-value", "anchor", "id", "appearance", "arrow", "attach", "inline", "class", "delay", "disabled", "placement", "trigger"])
|
|
2112
2096
|
], 64));
|
|
2113
2097
|
}
|
|
2114
|
-
}),
|
|
2098
|
+
}), jo = S(Ko), Go = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2115
2099
|
__proto__: null,
|
|
2116
2100
|
QButton: pe,
|
|
2117
|
-
QButtonGroup:
|
|
2118
|
-
QButtonToggle:
|
|
2119
|
-
QCombobox:
|
|
2120
|
-
QField:
|
|
2121
|
-
QIcon:
|
|
2122
|
-
QIconFont:
|
|
2123
|
-
QIconImg:
|
|
2124
|
-
QIconSvg:
|
|
2125
|
-
QInputGroup:
|
|
2126
|
-
QLineLoader:
|
|
2127
|
-
QList:
|
|
2128
|
-
QListItem:
|
|
2129
|
-
QListItemGroup:
|
|
2130
|
-
QOverlay:
|
|
2131
|
-
QPopover:
|
|
2132
|
-
QSelect:
|
|
2133
|
-
QSkeletonLoader:
|
|
2134
|
-
QSpinnerLoader:
|
|
2135
|
-
QTextField:
|
|
2136
|
-
QThemeProvider:
|
|
2137
|
-
QTooltip:
|
|
2138
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
2139
|
-
function
|
|
2140
|
-
const t =
|
|
2101
|
+
QButtonGroup: Ye,
|
|
2102
|
+
QButtonToggle: gt,
|
|
2103
|
+
QCombobox: mo,
|
|
2104
|
+
QField: Ie,
|
|
2105
|
+
QIcon: Y,
|
|
2106
|
+
QIconFont: Ze,
|
|
2107
|
+
QIconImg: Je,
|
|
2108
|
+
QIconSvg: et,
|
|
2109
|
+
QInputGroup: _o,
|
|
2110
|
+
QLineLoader: wo,
|
|
2111
|
+
QList: Ce,
|
|
2112
|
+
QListItem: tt,
|
|
2113
|
+
QListItemGroup: ot,
|
|
2114
|
+
QOverlay: ge,
|
|
2115
|
+
QPopover: So,
|
|
2116
|
+
QSelect: zo,
|
|
2117
|
+
QSkeletonLoader: Oo,
|
|
2118
|
+
QSpinnerLoader: qe,
|
|
2119
|
+
QTextField: nt,
|
|
2120
|
+
QThemeProvider: Uo,
|
|
2121
|
+
QTooltip: jo
|
|
2122
|
+
}, Symbol.toStringTag, { value: "Module" })), he = "q-theme";
|
|
2123
|
+
function Wo() {
|
|
2124
|
+
const t = He(he);
|
|
2141
2125
|
if (!t)
|
|
2142
2126
|
throw new Error("[Quidgest UI] Could not find theme instance");
|
|
2143
2127
|
return t;
|
|
2144
2128
|
}
|
|
2145
|
-
function
|
|
2146
|
-
const o =
|
|
2147
|
-
activeTheme:
|
|
2129
|
+
function ln(t) {
|
|
2130
|
+
const o = Wo(), e = {
|
|
2131
|
+
activeTheme: V(t),
|
|
2148
2132
|
themes: o.themes
|
|
2149
2133
|
};
|
|
2150
|
-
return
|
|
2134
|
+
return Ne(he, e), e;
|
|
2151
2135
|
}
|
|
2152
|
-
function
|
|
2136
|
+
function Ro(t) {
|
|
2153
2137
|
return /^#([a-fA-F0-9]{6}|[a-fA-F0-9]{3})$/.test(t);
|
|
2154
2138
|
}
|
|
2155
|
-
function
|
|
2156
|
-
if (!
|
|
2139
|
+
function Xo(t) {
|
|
2140
|
+
if (!Ro(t))
|
|
2157
2141
|
throw new Error("Invalid color format");
|
|
2158
2142
|
t.length === 4 && (t = "#" + t[1] + t[1] + t[2] + t[2] + t[3] + t[3]);
|
|
2159
2143
|
const o = parseInt(t.slice(1, 3), 16), e = parseInt(t.slice(3, 5), 16), n = parseInt(t.slice(5, 7), 16);
|
|
2160
2144
|
return { r: o, g: e, b: n };
|
|
2161
2145
|
}
|
|
2162
|
-
function
|
|
2146
|
+
function Yo() {
|
|
2163
2147
|
let t = document.getElementById(
|
|
2164
|
-
|
|
2148
|
+
he
|
|
2165
2149
|
);
|
|
2166
|
-
return t || (t = document.createElement("style"), t.id =
|
|
2150
|
+
return t || (t = document.createElement("style"), t.id = he, document.head.appendChild(t)), t;
|
|
2167
2151
|
}
|
|
2168
|
-
function
|
|
2152
|
+
function Zo(t) {
|
|
2169
2153
|
let o = "";
|
|
2170
2154
|
for (const n of t) {
|
|
2171
2155
|
o += `.q-theme--${n.name} {
|
|
@@ -2175,43 +2159,43 @@ function Vo(t) {
|
|
|
2175
2159
|
for (s in l) {
|
|
2176
2160
|
const i = l[s];
|
|
2177
2161
|
if (i) {
|
|
2178
|
-
o += ` ${
|
|
2162
|
+
o += ` ${Pe(s)}: ${i};
|
|
2179
2163
|
`;
|
|
2180
|
-
const a =
|
|
2181
|
-
o += ` ${
|
|
2164
|
+
const a = Xo(i);
|
|
2165
|
+
o += ` ${Pe(s)}-rgb: ${a.r} ${a.g} ${a.b};
|
|
2182
2166
|
`;
|
|
2183
2167
|
}
|
|
2184
2168
|
}
|
|
2185
2169
|
o += `}
|
|
2186
2170
|
`;
|
|
2187
2171
|
}
|
|
2188
|
-
const e =
|
|
2172
|
+
const e = Yo();
|
|
2189
2173
|
e.textContent = o;
|
|
2190
2174
|
}
|
|
2191
|
-
function
|
|
2192
|
-
return t ? `--q-theme-${
|
|
2175
|
+
function Pe(t) {
|
|
2176
|
+
return t ? `--q-theme-${Xe(t)}` : "";
|
|
2193
2177
|
}
|
|
2194
|
-
function
|
|
2178
|
+
function Jo(t = {}) {
|
|
2195
2179
|
return { install: (e) => {
|
|
2196
2180
|
const n = t.components || {};
|
|
2197
2181
|
for (const s in n)
|
|
2198
2182
|
e.component(s, n[s]);
|
|
2199
2183
|
const l = t.defaults || {};
|
|
2200
|
-
e.provide(
|
|
2184
|
+
e.provide(Ve, V(l)), en(e, t.themes);
|
|
2201
2185
|
} };
|
|
2202
2186
|
}
|
|
2203
|
-
function
|
|
2187
|
+
function en(t, o) {
|
|
2204
2188
|
const e = [];
|
|
2205
2189
|
let n;
|
|
2206
2190
|
if (!o)
|
|
2207
2191
|
n = "default", e.push({
|
|
2208
2192
|
name: n,
|
|
2209
2193
|
mode: "light",
|
|
2210
|
-
scheme:
|
|
2194
|
+
scheme: Le
|
|
2211
2195
|
});
|
|
2212
2196
|
else
|
|
2213
2197
|
for (const l of o.themes) {
|
|
2214
|
-
const i = { ...l.mode === "light" ?
|
|
2198
|
+
const i = { ...l.mode === "light" ? Le : Ge, ...l.colors };
|
|
2215
2199
|
e.push({
|
|
2216
2200
|
name: l.name,
|
|
2217
2201
|
mode: l.mode,
|
|
@@ -2220,21 +2204,21 @@ function To(t, o) {
|
|
|
2220
2204
|
}
|
|
2221
2205
|
if (n) {
|
|
2222
2206
|
const l = {
|
|
2223
|
-
activeTheme:
|
|
2207
|
+
activeTheme: V(n),
|
|
2224
2208
|
themes: e
|
|
2225
2209
|
};
|
|
2226
|
-
|
|
2210
|
+
Zo(e), R(l.activeTheme, tn, { immediate: !0 }), t.provide(he, l);
|
|
2227
2211
|
}
|
|
2228
2212
|
}
|
|
2229
|
-
function
|
|
2213
|
+
function tn(t) {
|
|
2230
2214
|
const o = document.documentElement, n = Array.from(o.classList).filter((l) => !l.startsWith("q-theme"));
|
|
2231
2215
|
o.className = n.join(" "), o.classList.add(`q-theme--${t}`);
|
|
2232
2216
|
}
|
|
2233
|
-
const
|
|
2217
|
+
const an = (t = {}) => Jo({ components: Go, ...t });
|
|
2234
2218
|
export {
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
|
|
2239
|
-
|
|
2219
|
+
Go as components,
|
|
2220
|
+
an as createFramework,
|
|
2221
|
+
ln as provideTheme,
|
|
2222
|
+
nn as templates,
|
|
2223
|
+
Wo as useTheme
|
|
2240
2224
|
};
|