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