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