@validol4ik/uikit 0.9.5 → 0.9.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{AppButtonCopy-CBOiSOFe.js → AppButtonCopy-CyAsc8Wj.js} +1 -1
- package/dist/{AppButtonCopy-CJq8F3gr.cjs → AppButtonCopy-qd0ScaQa.cjs} +1 -1
- package/dist/AppSelect-Caztniat.cjs +1 -0
- package/dist/AppSelect-De8uYZsG.js +1985 -0
- package/dist/BottomSheet-CVMFMVIY.cjs +1 -0
- package/dist/BottomSheet-DgjCj1MF.js +103 -0
- package/dist/{DropdownButton-C37a5e17.js → DropdownButton-GVvCXcoz.js} +8 -7
- package/dist/DropdownButton-InnZiB3p.cjs +1 -0
- package/dist/QDialog-BNpd5bKf.js +264 -0
- package/dist/QDialog-D2ko_yRk.cjs +1 -0
- package/dist/QMenu-DBYwgcG3.js +536 -0
- package/dist/QMenu-oXcQNM8M.cjs +1 -0
- package/dist/escape-key-BI7VXtq3.js +281 -0
- package/dist/escape-key-D57uOwZp.cjs +1 -0
- package/dist/index-BrzD2JEm.cjs +1 -0
- package/dist/index-DLmO1BOx.js +1838 -0
- package/dist/style.css +1 -1
- package/dist/types/components/buttons/CloseButton/CloseButton.vue.d.ts +5 -0
- package/dist/types/components/buttons/CloseButton/types.d.ts +4 -0
- package/dist/types/components/menu/BottomSheet/BottomSheet.vue.d.ts +38 -0
- package/dist/types/components/menu/BottomSheet/types.d.ts +11 -0
- package/dist/types/components/menu/MenuItem/MenuItem.vue.d.ts +29 -0
- package/dist/types/components/menu/MenuItem/types.d.ts +21 -0
- package/dist/types/components/menu/SystemMenu.vue.d.ts +17 -0
- package/dist/types/index.d.ts +58 -1
- package/dist/uikit.cjs +1 -1
- package/dist/uikit.es.js +10 -6
- package/package.json +1 -1
- package/dist/AppSelect-BOROROsn.cjs +0 -1
- package/dist/AppSelect-CZfoTaTG.js +0 -2304
- package/dist/DropdownButton-BQrXTfDg.cjs +0 -1
- package/dist/QMenu-Ci2SWpGp.js +0 -808
- package/dist/QMenu-DGfnSFI-.cjs +0 -1
- package/dist/index-CTeqfCv_.js +0 -1674
- package/dist/index-Cekw313Q.cjs +0 -1
|
@@ -0,0 +1,1838 @@
|
|
|
1
|
+
import { computed as u, markRaw as Ve, defineComponent as F, h as m, withDirectives as se, getCurrentInstance as te, unref as D, ref as Q, onBeforeUnmount as Ge, Transition as Ze, openBlock as b, createBlock as K, normalizeClass as L, withCtx as Ie, createElementBlock as C, createCommentVNode as P, renderSlot as X, Fragment as ie, createTextVNode as ke, toDisplayString as Y, createElementVNode as M, withModifiers as Ae, toRaw as G, createVNode as Je, normalizeStyle as ue, watch as et, onMounted as tt, renderList as Te, withKeys as nt, vModelText as lt, nextTick as $e, useModel as ze, mergeModels as pe, defineAsyncComponent as re } from "vue";
|
|
2
|
+
const Vn = ({ app: e }) => {
|
|
3
|
+
const t = e.config.globalProperties.$q;
|
|
4
|
+
t.iconMapFn = (n) => {
|
|
5
|
+
if (n.startsWith("icon-kl:"))
|
|
6
|
+
return {
|
|
7
|
+
cls: `icon-kl icon-kl-${n.slice(8)}`
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
}, Oe = {
|
|
11
|
+
PRIMARY: "primary",
|
|
12
|
+
INFO: "info"
|
|
13
|
+
}, A = {
|
|
14
|
+
SM: "sm",
|
|
15
|
+
MD: "md",
|
|
16
|
+
LG: "lg",
|
|
17
|
+
XL: "xl"
|
|
18
|
+
}, at = {
|
|
19
|
+
[A.SM]: "3px 9px",
|
|
20
|
+
[A.MD]: "5px 12px",
|
|
21
|
+
[A.LG]: "6px 15px",
|
|
22
|
+
[A.XL]: "9px 20px"
|
|
23
|
+
}, be = {
|
|
24
|
+
xs: 18,
|
|
25
|
+
sm: 24,
|
|
26
|
+
md: 32,
|
|
27
|
+
lg: 38,
|
|
28
|
+
xl: 46
|
|
29
|
+
}, ce = {
|
|
30
|
+
size: String
|
|
31
|
+
};
|
|
32
|
+
function de(e, t = be) {
|
|
33
|
+
return u(() => e.size !== void 0 ? { fontSize: e.size in t ? `${t[e.size]}px` : e.size } : null);
|
|
34
|
+
}
|
|
35
|
+
function ne(e) {
|
|
36
|
+
return Ve(F(e));
|
|
37
|
+
}
|
|
38
|
+
function je(e) {
|
|
39
|
+
return Ve(e);
|
|
40
|
+
}
|
|
41
|
+
function De(e, t) {
|
|
42
|
+
return e !== void 0 && e() || t;
|
|
43
|
+
}
|
|
44
|
+
function ot(e, t) {
|
|
45
|
+
if (e !== void 0) {
|
|
46
|
+
const n = e();
|
|
47
|
+
if (n != null)
|
|
48
|
+
return n.slice();
|
|
49
|
+
}
|
|
50
|
+
return t;
|
|
51
|
+
}
|
|
52
|
+
function H(e, t) {
|
|
53
|
+
return e !== void 0 ? t.concat(e()) : t;
|
|
54
|
+
}
|
|
55
|
+
function In(e, t) {
|
|
56
|
+
return e === void 0 ? t : t !== void 0 ? t.concat(e()) : e();
|
|
57
|
+
}
|
|
58
|
+
function An(e, t, n, l, s, o) {
|
|
59
|
+
t.key = l + s;
|
|
60
|
+
const a = m(e, t, n);
|
|
61
|
+
return s === !0 ? se(a, o()) : a;
|
|
62
|
+
}
|
|
63
|
+
const qe = "0 0 24 24", ve = (e) => e, me = (e) => `ionicons ${e}`, Ne = {
|
|
64
|
+
"mdi-": (e) => `mdi ${e}`,
|
|
65
|
+
"icon-": ve,
|
|
66
|
+
// fontawesome equiv
|
|
67
|
+
"bt-": (e) => `bt ${e}`,
|
|
68
|
+
"eva-": (e) => `eva ${e}`,
|
|
69
|
+
"ion-md": me,
|
|
70
|
+
"ion-ios": me,
|
|
71
|
+
"ion-logo": me,
|
|
72
|
+
"iconfont ": ve,
|
|
73
|
+
"ti-": (e) => `themify-icon ${e}`,
|
|
74
|
+
"bi-": (e) => `bootstrap-icons ${e}`,
|
|
75
|
+
"i-": ve
|
|
76
|
+
// UnoCSS pure icons
|
|
77
|
+
}, Ke = {
|
|
78
|
+
o_: "-outlined",
|
|
79
|
+
r_: "-round",
|
|
80
|
+
s_: "-sharp"
|
|
81
|
+
}, Fe = {
|
|
82
|
+
sym_o_: "-outlined",
|
|
83
|
+
sym_r_: "-rounded",
|
|
84
|
+
sym_s_: "-sharp"
|
|
85
|
+
}, st = new RegExp("^(" + Object.keys(Ne).join("|") + ")"), it = new RegExp("^(" + Object.keys(Ke).join("|") + ")"), Ce = new RegExp("^(" + Object.keys(Fe).join("|") + ")"), ut = /^[Mm]\s?[-+]?\.?\d/, rt = /^img:/, ct = /^svguse:/, dt = /^ion-/, ft = /^(fa-(classic|sharp|solid|regular|light|brands|duotone|thin)|[lf]a[srlbdk]?) /, he = ne({
|
|
86
|
+
name: "QIcon",
|
|
87
|
+
props: {
|
|
88
|
+
...ce,
|
|
89
|
+
tag: {
|
|
90
|
+
type: String,
|
|
91
|
+
default: "i"
|
|
92
|
+
},
|
|
93
|
+
name: String,
|
|
94
|
+
color: String,
|
|
95
|
+
left: Boolean,
|
|
96
|
+
right: Boolean
|
|
97
|
+
},
|
|
98
|
+
setup(e, { slots: t }) {
|
|
99
|
+
const { proxy: { $q: n } } = te(), l = de(e), s = u(
|
|
100
|
+
() => "q-icon" + (e.left === !0 ? " on-left" : "") + (e.right === !0 ? " on-right" : "") + (e.color !== void 0 ? ` text-${e.color}` : "")
|
|
101
|
+
), o = u(() => {
|
|
102
|
+
let a, i = e.name;
|
|
103
|
+
if (i === "none" || !i)
|
|
104
|
+
return { none: !0 };
|
|
105
|
+
if (n.iconMapFn !== null) {
|
|
106
|
+
const f = n.iconMapFn(i);
|
|
107
|
+
if (f !== void 0)
|
|
108
|
+
if (f.icon !== void 0) {
|
|
109
|
+
if (i = f.icon, i === "none" || !i)
|
|
110
|
+
return { none: !0 };
|
|
111
|
+
} else
|
|
112
|
+
return {
|
|
113
|
+
cls: f.cls,
|
|
114
|
+
content: f.content !== void 0 ? f.content : " "
|
|
115
|
+
};
|
|
116
|
+
}
|
|
117
|
+
if (ut.test(i) === !0) {
|
|
118
|
+
const [f, $ = qe] = i.split("|");
|
|
119
|
+
return {
|
|
120
|
+
svg: !0,
|
|
121
|
+
viewBox: $,
|
|
122
|
+
nodes: f.split("&&").map((d) => {
|
|
123
|
+
const [y, r, g] = d.split("@@");
|
|
124
|
+
return m("path", { style: r, d: y, transform: g });
|
|
125
|
+
})
|
|
126
|
+
};
|
|
127
|
+
}
|
|
128
|
+
if (rt.test(i) === !0)
|
|
129
|
+
return {
|
|
130
|
+
img: !0,
|
|
131
|
+
src: i.substring(4)
|
|
132
|
+
};
|
|
133
|
+
if (ct.test(i) === !0) {
|
|
134
|
+
const [f, $ = qe] = i.split("|");
|
|
135
|
+
return {
|
|
136
|
+
svguse: !0,
|
|
137
|
+
src: f.substring(7),
|
|
138
|
+
viewBox: $
|
|
139
|
+
};
|
|
140
|
+
}
|
|
141
|
+
let _ = " ";
|
|
142
|
+
const B = i.match(st);
|
|
143
|
+
if (B !== null)
|
|
144
|
+
a = Ne[B[1]](i);
|
|
145
|
+
else if (ft.test(i) === !0)
|
|
146
|
+
a = i;
|
|
147
|
+
else if (dt.test(i) === !0)
|
|
148
|
+
a = `ionicons ion-${n.platform.is.ios === !0 ? "ios" : "md"}${i.substring(3)}`;
|
|
149
|
+
else if (Ce.test(i) === !0) {
|
|
150
|
+
a = "notranslate material-symbols";
|
|
151
|
+
const f = i.match(Ce);
|
|
152
|
+
f !== null && (i = i.substring(6), a += Fe[f[1]]), _ = i;
|
|
153
|
+
} else {
|
|
154
|
+
a = "notranslate material-icons";
|
|
155
|
+
const f = i.match(it);
|
|
156
|
+
f !== null && (i = i.substring(2), a += Ke[f[1]]), _ = i;
|
|
157
|
+
}
|
|
158
|
+
return {
|
|
159
|
+
cls: a,
|
|
160
|
+
content: _
|
|
161
|
+
};
|
|
162
|
+
});
|
|
163
|
+
return () => {
|
|
164
|
+
const a = {
|
|
165
|
+
class: s.value,
|
|
166
|
+
style: l.value,
|
|
167
|
+
"aria-hidden": "true"
|
|
168
|
+
};
|
|
169
|
+
return o.value.none === !0 ? m(e.tag, a, De(t.default)) : o.value.img === !0 ? m(e.tag, a, H(t.default, [
|
|
170
|
+
m("img", { src: o.value.src })
|
|
171
|
+
])) : o.value.svg === !0 ? m(e.tag, a, H(t.default, [
|
|
172
|
+
m("svg", {
|
|
173
|
+
viewBox: o.value.viewBox || "0 0 24 24"
|
|
174
|
+
}, o.value.nodes)
|
|
175
|
+
])) : o.value.svguse === !0 ? m(e.tag, a, H(t.default, [
|
|
176
|
+
m("svg", {
|
|
177
|
+
viewBox: o.value.viewBox
|
|
178
|
+
}, [
|
|
179
|
+
m("use", { "xlink:href": o.value.src })
|
|
180
|
+
])
|
|
181
|
+
])) : (o.value.cls !== void 0 && (a.class += " " + o.value.cls), m(e.tag, a, H(t.default, [
|
|
182
|
+
o.value.content
|
|
183
|
+
])));
|
|
184
|
+
};
|
|
185
|
+
}
|
|
186
|
+
}), vt = {
|
|
187
|
+
size: {
|
|
188
|
+
type: [String, Number],
|
|
189
|
+
default: "1em"
|
|
190
|
+
},
|
|
191
|
+
color: String
|
|
192
|
+
};
|
|
193
|
+
function mt(e) {
|
|
194
|
+
return {
|
|
195
|
+
cSize: u(() => e.size in be ? `${be[e.size]}px` : e.size),
|
|
196
|
+
classes: u(
|
|
197
|
+
() => "q-spinner" + (e.color ? ` text-${e.color}` : "")
|
|
198
|
+
)
|
|
199
|
+
};
|
|
200
|
+
}
|
|
201
|
+
const xe = ne({
|
|
202
|
+
name: "QSpinner",
|
|
203
|
+
props: {
|
|
204
|
+
...vt,
|
|
205
|
+
thickness: {
|
|
206
|
+
type: Number,
|
|
207
|
+
default: 5
|
|
208
|
+
}
|
|
209
|
+
},
|
|
210
|
+
setup(e) {
|
|
211
|
+
const { cSize: t, classes: n } = mt(e);
|
|
212
|
+
return () => m("svg", {
|
|
213
|
+
class: n.value + " q-spinner-mat",
|
|
214
|
+
width: t.value,
|
|
215
|
+
height: t.value,
|
|
216
|
+
viewBox: "25 25 50 50"
|
|
217
|
+
}, [
|
|
218
|
+
m("circle", {
|
|
219
|
+
class: "path",
|
|
220
|
+
cx: "50",
|
|
221
|
+
cy: "50",
|
|
222
|
+
r: "20",
|
|
223
|
+
fill: "none",
|
|
224
|
+
stroke: "currentColor",
|
|
225
|
+
"stroke-width": e.thickness,
|
|
226
|
+
"stroke-miterlimit": "10"
|
|
227
|
+
})
|
|
228
|
+
]);
|
|
229
|
+
}
|
|
230
|
+
});
|
|
231
|
+
function gt(e, t) {
|
|
232
|
+
const n = e.style;
|
|
233
|
+
for (const l in t)
|
|
234
|
+
n[l] = t[l];
|
|
235
|
+
}
|
|
236
|
+
function Tn(e) {
|
|
237
|
+
if (e == null)
|
|
238
|
+
return;
|
|
239
|
+
if (typeof e == "string")
|
|
240
|
+
try {
|
|
241
|
+
return document.querySelector(e) || void 0;
|
|
242
|
+
} catch {
|
|
243
|
+
return;
|
|
244
|
+
}
|
|
245
|
+
const t = D(e);
|
|
246
|
+
if (t)
|
|
247
|
+
return t.$el || t;
|
|
248
|
+
}
|
|
249
|
+
function zn(e, t) {
|
|
250
|
+
if (e == null || e.contains(t) === !0)
|
|
251
|
+
return !0;
|
|
252
|
+
for (let n = e.nextElementSibling; n !== null; n = n.nextElementSibling)
|
|
253
|
+
if (n.contains(t))
|
|
254
|
+
return !0;
|
|
255
|
+
return !1;
|
|
256
|
+
}
|
|
257
|
+
const fe = {
|
|
258
|
+
hasPassive: !1,
|
|
259
|
+
passiveCapture: !0,
|
|
260
|
+
notPassiveCapture: !0
|
|
261
|
+
};
|
|
262
|
+
try {
|
|
263
|
+
const e = Object.defineProperty({}, "passive", {
|
|
264
|
+
get() {
|
|
265
|
+
Object.assign(fe, {
|
|
266
|
+
hasPassive: !0,
|
|
267
|
+
passive: { passive: !0 },
|
|
268
|
+
notPassive: { passive: !1 },
|
|
269
|
+
passiveCapture: { passive: !0, capture: !0 },
|
|
270
|
+
notPassiveCapture: { passive: !1, capture: !0 }
|
|
271
|
+
});
|
|
272
|
+
}
|
|
273
|
+
});
|
|
274
|
+
window.addEventListener("qtest", null, e), window.removeEventListener("qtest", null, e);
|
|
275
|
+
} catch {
|
|
276
|
+
}
|
|
277
|
+
function On() {
|
|
278
|
+
}
|
|
279
|
+
function pt(e) {
|
|
280
|
+
return e.touches && e.touches[0] ? e = e.touches[0] : e.changedTouches && e.changedTouches[0] ? e = e.changedTouches[0] : e.targetTouches && e.targetTouches[0] && (e = e.targetTouches[0]), {
|
|
281
|
+
top: e.clientY,
|
|
282
|
+
left: e.clientX
|
|
283
|
+
};
|
|
284
|
+
}
|
|
285
|
+
function jn(e) {
|
|
286
|
+
if (e.path)
|
|
287
|
+
return e.path;
|
|
288
|
+
if (e.composedPath)
|
|
289
|
+
return e.composedPath();
|
|
290
|
+
const t = [];
|
|
291
|
+
let n = e.target;
|
|
292
|
+
for (; n; ) {
|
|
293
|
+
if (t.push(n), n.tagName === "HTML")
|
|
294
|
+
return t.push(document), t.push(window), t;
|
|
295
|
+
n = n.parentElement;
|
|
296
|
+
}
|
|
297
|
+
}
|
|
298
|
+
function Qe(e) {
|
|
299
|
+
e.stopPropagation();
|
|
300
|
+
}
|
|
301
|
+
function bt(e) {
|
|
302
|
+
e.cancelable !== !1 && e.preventDefault();
|
|
303
|
+
}
|
|
304
|
+
function N(e) {
|
|
305
|
+
e.cancelable !== !1 && e.preventDefault(), e.stopPropagation();
|
|
306
|
+
}
|
|
307
|
+
function ht(e, t, n) {
|
|
308
|
+
const l = `__q_${t}_evt`;
|
|
309
|
+
e[l] = e[l] !== void 0 ? e[l].concat(n) : n, n.forEach((s) => {
|
|
310
|
+
s[0].addEventListener(s[1], e[s[2]], fe[s[3]]);
|
|
311
|
+
});
|
|
312
|
+
}
|
|
313
|
+
function kt(e, t) {
|
|
314
|
+
const n = `__q_${t}_evt`;
|
|
315
|
+
e[n] !== void 0 && (e[n].forEach((l) => {
|
|
316
|
+
l[0].removeEventListener(l[1], e[l[2]], fe[l[3]]);
|
|
317
|
+
}), e[n] = void 0);
|
|
318
|
+
}
|
|
319
|
+
function yt(e) {
|
|
320
|
+
return e !== Object(e) || e.isComposing === !0 || e.qKeyEvent === !0;
|
|
321
|
+
}
|
|
322
|
+
function ae(e, t) {
|
|
323
|
+
return yt(e) === !0 ? !1 : [].concat(t).includes(e.keyCode);
|
|
324
|
+
}
|
|
325
|
+
function _t(e, t = 250) {
|
|
326
|
+
let n = !1, l;
|
|
327
|
+
return function() {
|
|
328
|
+
return n === !1 && (n = !0, setTimeout(() => {
|
|
329
|
+
n = !1;
|
|
330
|
+
}, t), l = e.apply(this, arguments)), l;
|
|
331
|
+
};
|
|
332
|
+
}
|
|
333
|
+
function Be(e, t, n, l) {
|
|
334
|
+
n.modifiers.stop === !0 && Qe(e);
|
|
335
|
+
const s = n.modifiers.color;
|
|
336
|
+
let o = n.modifiers.center;
|
|
337
|
+
o = o === !0 || l === !0;
|
|
338
|
+
const a = document.createElement("span"), i = document.createElement("span"), _ = pt(e), { left: B, top: f, width: $, height: d } = t.getBoundingClientRect(), y = Math.sqrt($ * $ + d * d), r = y / 2, g = `${($ - y) / 2}px`, v = o ? g : `${_.left - B - r}px`, k = `${(d - y) / 2}px`, S = o ? k : `${_.top - f - r}px`;
|
|
339
|
+
i.className = "q-ripple__inner", gt(i, {
|
|
340
|
+
height: `${y}px`,
|
|
341
|
+
width: `${y}px`,
|
|
342
|
+
transform: `translate3d(${v},${S},0) scale3d(.2,.2,1)`,
|
|
343
|
+
opacity: 0
|
|
344
|
+
}), a.className = `q-ripple${s ? " text-" + s : ""}`, a.setAttribute("dir", "ltr"), a.appendChild(i), t.appendChild(a);
|
|
345
|
+
const p = () => {
|
|
346
|
+
a.remove(), clearTimeout(E);
|
|
347
|
+
};
|
|
348
|
+
n.abort.push(p);
|
|
349
|
+
let E = setTimeout(() => {
|
|
350
|
+
i.classList.add("q-ripple__inner--enter"), i.style.transform = `translate3d(${g},${k},0) scale3d(1,1,1)`, i.style.opacity = 0.2, E = setTimeout(() => {
|
|
351
|
+
i.classList.remove("q-ripple__inner--enter"), i.classList.add("q-ripple__inner--leave"), i.style.opacity = 0, E = setTimeout(() => {
|
|
352
|
+
a.remove(), n.abort.splice(n.abort.indexOf(p), 1);
|
|
353
|
+
}, 275);
|
|
354
|
+
}, 250);
|
|
355
|
+
}, 50);
|
|
356
|
+
}
|
|
357
|
+
function Se(e, { modifiers: t, value: n, arg: l }) {
|
|
358
|
+
const s = Object.assign({}, e.cfg.ripple, t, n);
|
|
359
|
+
e.modifiers = {
|
|
360
|
+
early: s.early === !0,
|
|
361
|
+
stop: s.stop === !0,
|
|
362
|
+
center: s.center === !0,
|
|
363
|
+
color: s.color || l,
|
|
364
|
+
keyCodes: [].concat(s.keyCodes || 13)
|
|
365
|
+
};
|
|
366
|
+
}
|
|
367
|
+
const $t = je(
|
|
368
|
+
{
|
|
369
|
+
name: "ripple",
|
|
370
|
+
beforeMount(e, t) {
|
|
371
|
+
const n = t.instance.$.appContext.config.globalProperties.$q.config || {};
|
|
372
|
+
if (n.ripple === !1) return;
|
|
373
|
+
const l = {
|
|
374
|
+
cfg: n,
|
|
375
|
+
enabled: t.value !== !1,
|
|
376
|
+
modifiers: {},
|
|
377
|
+
abort: [],
|
|
378
|
+
start(s) {
|
|
379
|
+
l.enabled === !0 && s.qSkipRipple !== !0 && s.type === (l.modifiers.early === !0 ? "pointerdown" : "click") && Be(s, e, l, s.qKeyEvent === !0);
|
|
380
|
+
},
|
|
381
|
+
keystart: _t((s) => {
|
|
382
|
+
l.enabled === !0 && s.qSkipRipple !== !0 && ae(s, l.modifiers.keyCodes) === !0 && s.type === `key${l.modifiers.early === !0 ? "down" : "up"}` && Be(s, e, l, !0);
|
|
383
|
+
}, 300)
|
|
384
|
+
};
|
|
385
|
+
Se(l, t), e.__qripple = l, ht(l, "main", [
|
|
386
|
+
[e, "pointerdown", "start", "passive"],
|
|
387
|
+
[e, "click", "start", "passive"],
|
|
388
|
+
[e, "keydown", "keystart", "passive"],
|
|
389
|
+
[e, "keyup", "keystart", "passive"]
|
|
390
|
+
]);
|
|
391
|
+
},
|
|
392
|
+
updated(e, t) {
|
|
393
|
+
if (t.oldValue !== t.value) {
|
|
394
|
+
const n = e.__qripple;
|
|
395
|
+
n !== void 0 && (n.enabled = t.value !== !1, n.enabled === !0 && Object(t.value) === t.value && Se(n, t));
|
|
396
|
+
}
|
|
397
|
+
},
|
|
398
|
+
beforeUnmount(e) {
|
|
399
|
+
const t = e.__qripple;
|
|
400
|
+
t !== void 0 && (t.abort.forEach((n) => {
|
|
401
|
+
n();
|
|
402
|
+
}), kt(t, "main"), delete e._qripple);
|
|
403
|
+
}
|
|
404
|
+
}
|
|
405
|
+
), Ue = {
|
|
406
|
+
left: "start",
|
|
407
|
+
center: "center",
|
|
408
|
+
right: "end",
|
|
409
|
+
between: "between",
|
|
410
|
+
around: "around",
|
|
411
|
+
evenly: "evenly",
|
|
412
|
+
stretch: "stretch"
|
|
413
|
+
}, qt = Object.keys(Ue), Ct = {
|
|
414
|
+
align: {
|
|
415
|
+
type: String,
|
|
416
|
+
validator: (e) => qt.includes(e)
|
|
417
|
+
}
|
|
418
|
+
};
|
|
419
|
+
function Bt(e) {
|
|
420
|
+
return u(() => {
|
|
421
|
+
const t = e.align === void 0 ? e.vertical === !0 ? "stretch" : "left" : e.align;
|
|
422
|
+
return `${e.vertical === !0 ? "items" : "justify"}-${Ue[t]}`;
|
|
423
|
+
});
|
|
424
|
+
}
|
|
425
|
+
function oe(e) {
|
|
426
|
+
if (Object(e.$parent) === e.$parent)
|
|
427
|
+
return e.$parent;
|
|
428
|
+
let { parent: t } = e.$;
|
|
429
|
+
for (; Object(t) === t; ) {
|
|
430
|
+
if (Object(t.proxy) === t.proxy)
|
|
431
|
+
return t.proxy;
|
|
432
|
+
t = t.parent;
|
|
433
|
+
}
|
|
434
|
+
}
|
|
435
|
+
function St(e) {
|
|
436
|
+
return e.appContext.config.globalProperties.$router !== void 0;
|
|
437
|
+
}
|
|
438
|
+
function Dn(e) {
|
|
439
|
+
return e.isUnmounted === !0 || e.isDeactivated === !0;
|
|
440
|
+
}
|
|
441
|
+
function we(e) {
|
|
442
|
+
return e ? e.aliasOf ? e.aliasOf.path : e.path : "";
|
|
443
|
+
}
|
|
444
|
+
function Ee(e, t) {
|
|
445
|
+
return (e.aliasOf || e) === (t.aliasOf || t);
|
|
446
|
+
}
|
|
447
|
+
function wt(e, t) {
|
|
448
|
+
for (const n in t) {
|
|
449
|
+
const l = t[n], s = e[n];
|
|
450
|
+
if (typeof l == "string") {
|
|
451
|
+
if (l !== s)
|
|
452
|
+
return !1;
|
|
453
|
+
} else if (Array.isArray(s) === !1 || s.length !== l.length || l.some((o, a) => o !== s[a]))
|
|
454
|
+
return !1;
|
|
455
|
+
}
|
|
456
|
+
return !0;
|
|
457
|
+
}
|
|
458
|
+
function Le(e, t) {
|
|
459
|
+
return Array.isArray(t) === !0 ? e.length === t.length && e.every((n, l) => n === t[l]) : e.length === 1 && e[0] === t;
|
|
460
|
+
}
|
|
461
|
+
function Et(e, t) {
|
|
462
|
+
return Array.isArray(e) === !0 ? Le(e, t) : Array.isArray(t) === !0 ? Le(t, e) : e === t;
|
|
463
|
+
}
|
|
464
|
+
function Lt(e, t) {
|
|
465
|
+
if (Object.keys(e).length !== Object.keys(t).length)
|
|
466
|
+
return !1;
|
|
467
|
+
for (const n in e)
|
|
468
|
+
if (Et(e[n], t[n]) === !1)
|
|
469
|
+
return !1;
|
|
470
|
+
return !0;
|
|
471
|
+
}
|
|
472
|
+
const He = {
|
|
473
|
+
// router-link
|
|
474
|
+
to: [String, Object],
|
|
475
|
+
replace: Boolean,
|
|
476
|
+
// regular <a> link
|
|
477
|
+
href: String,
|
|
478
|
+
target: String,
|
|
479
|
+
// state
|
|
480
|
+
disable: Boolean
|
|
481
|
+
}, Pt = {
|
|
482
|
+
...He,
|
|
483
|
+
// router-link
|
|
484
|
+
exact: Boolean,
|
|
485
|
+
activeClass: {
|
|
486
|
+
type: String,
|
|
487
|
+
default: "q-router-link--active"
|
|
488
|
+
},
|
|
489
|
+
exactActiveClass: {
|
|
490
|
+
type: String,
|
|
491
|
+
default: "q-router-link--exact-active"
|
|
492
|
+
}
|
|
493
|
+
};
|
|
494
|
+
function Xe({ fallbackTag: e, useDisableForRouterLinkProps: t = !0 } = {}) {
|
|
495
|
+
const n = te(), { props: l, proxy: s, emit: o } = n, a = St(n), i = u(() => l.disable !== !0 && l.href !== void 0), _ = t === !0 ? u(
|
|
496
|
+
() => a === !0 && l.disable !== !0 && i.value !== !0 && l.to !== void 0 && l.to !== null && l.to !== ""
|
|
497
|
+
) : u(
|
|
498
|
+
() => a === !0 && i.value !== !0 && l.to !== void 0 && l.to !== null && l.to !== ""
|
|
499
|
+
), B = u(() => _.value === !0 ? S(l.to) : null), f = u(() => B.value !== null), $ = u(() => i.value === !0 || f.value === !0), d = u(() => l.type === "a" || $.value === !0 ? "a" : l.tag || e || "div"), y = u(() => i.value === !0 ? {
|
|
500
|
+
href: l.href,
|
|
501
|
+
target: l.target
|
|
502
|
+
} : f.value === !0 ? {
|
|
503
|
+
href: B.value.href,
|
|
504
|
+
target: l.target
|
|
505
|
+
} : {}), r = u(() => {
|
|
506
|
+
if (f.value === !1)
|
|
507
|
+
return -1;
|
|
508
|
+
const { matched: q } = B.value, { length: R } = q, V = q[R - 1];
|
|
509
|
+
if (V === void 0)
|
|
510
|
+
return -1;
|
|
511
|
+
const O = s.$route.matched;
|
|
512
|
+
if (O.length === 0)
|
|
513
|
+
return -1;
|
|
514
|
+
const j = O.findIndex(
|
|
515
|
+
Ee.bind(null, V)
|
|
516
|
+
);
|
|
517
|
+
if (j !== -1)
|
|
518
|
+
return j;
|
|
519
|
+
const W = we(q[R - 2]);
|
|
520
|
+
return (
|
|
521
|
+
// we are dealing with nested routes
|
|
522
|
+
R > 1 && we(V) === W && O[O.length - 1].path !== W ? O.findIndex(
|
|
523
|
+
Ee.bind(null, q[R - 2])
|
|
524
|
+
) : j
|
|
525
|
+
);
|
|
526
|
+
}), g = u(
|
|
527
|
+
() => f.value === !0 && r.value !== -1 && wt(s.$route.params, B.value.params)
|
|
528
|
+
), v = u(
|
|
529
|
+
() => g.value === !0 && r.value === s.$route.matched.length - 1 && Lt(s.$route.params, B.value.params)
|
|
530
|
+
), k = u(() => f.value === !0 ? v.value === !0 ? ` ${l.exactActiveClass} ${l.activeClass}` : l.exact === !0 ? "" : g.value === !0 ? ` ${l.activeClass}` : "" : "");
|
|
531
|
+
function S(q) {
|
|
532
|
+
try {
|
|
533
|
+
return s.$router.resolve(q);
|
|
534
|
+
} catch {
|
|
535
|
+
}
|
|
536
|
+
return null;
|
|
537
|
+
}
|
|
538
|
+
function p(q, { returnRouterError: R, to: V = l.to, replace: O = l.replace } = {}) {
|
|
539
|
+
if (l.disable === !0)
|
|
540
|
+
return q.preventDefault(), Promise.resolve(!1);
|
|
541
|
+
if (
|
|
542
|
+
// don't redirect with control keys;
|
|
543
|
+
// should match RouterLink from Vue Router
|
|
544
|
+
q.metaKey || q.altKey || q.ctrlKey || q.shiftKey || q.button !== void 0 && q.button !== 0 || l.target === "_blank"
|
|
545
|
+
)
|
|
546
|
+
return Promise.resolve(!1);
|
|
547
|
+
q.preventDefault();
|
|
548
|
+
const j = s.$router[O === !0 ? "replace" : "push"](V);
|
|
549
|
+
return R === !0 ? j : j.then(() => {
|
|
550
|
+
}).catch(() => {
|
|
551
|
+
});
|
|
552
|
+
}
|
|
553
|
+
function E(q) {
|
|
554
|
+
if (f.value === !0) {
|
|
555
|
+
const R = (V) => p(q, V);
|
|
556
|
+
o("click", q, R), q.defaultPrevented !== !0 && R();
|
|
557
|
+
} else
|
|
558
|
+
o("click", q);
|
|
559
|
+
}
|
|
560
|
+
return {
|
|
561
|
+
hasRouterLink: f,
|
|
562
|
+
hasHrefLink: i,
|
|
563
|
+
hasLink: $,
|
|
564
|
+
linkTag: d,
|
|
565
|
+
resolvedLink: B,
|
|
566
|
+
linkIsActive: g,
|
|
567
|
+
linkIsExactActive: v,
|
|
568
|
+
linkClass: k,
|
|
569
|
+
linkAttrs: y,
|
|
570
|
+
getLink: S,
|
|
571
|
+
navigateToRouterLink: p,
|
|
572
|
+
navigateOnClick: E
|
|
573
|
+
};
|
|
574
|
+
}
|
|
575
|
+
const Pe = {
|
|
576
|
+
none: 0,
|
|
577
|
+
xs: 4,
|
|
578
|
+
sm: 8,
|
|
579
|
+
md: 16,
|
|
580
|
+
lg: 24,
|
|
581
|
+
xl: 32
|
|
582
|
+
}, Mt = {
|
|
583
|
+
xs: 8,
|
|
584
|
+
sm: 10,
|
|
585
|
+
md: 14,
|
|
586
|
+
lg: 20,
|
|
587
|
+
xl: 24
|
|
588
|
+
}, Rt = ["button", "submit", "reset"], Vt = /[^\s]\/[^\s]/, It = ["flat", "outline", "push", "unelevated"];
|
|
589
|
+
function Ye(e, t) {
|
|
590
|
+
return e.flat === !0 ? "flat" : e.outline === !0 ? "outline" : e.push === !0 ? "push" : e.unelevated === !0 ? "unelevated" : t;
|
|
591
|
+
}
|
|
592
|
+
function Nn(e) {
|
|
593
|
+
const t = Ye(e);
|
|
594
|
+
return t !== void 0 ? { [t]: !0 } : {};
|
|
595
|
+
}
|
|
596
|
+
const At = {
|
|
597
|
+
...ce,
|
|
598
|
+
...He,
|
|
599
|
+
type: {
|
|
600
|
+
type: String,
|
|
601
|
+
default: "button"
|
|
602
|
+
},
|
|
603
|
+
label: [Number, String],
|
|
604
|
+
icon: String,
|
|
605
|
+
iconRight: String,
|
|
606
|
+
...It.reduce(
|
|
607
|
+
(e, t) => (e[t] = Boolean) && e,
|
|
608
|
+
{}
|
|
609
|
+
),
|
|
610
|
+
square: Boolean,
|
|
611
|
+
rounded: Boolean,
|
|
612
|
+
glossy: Boolean,
|
|
613
|
+
size: String,
|
|
614
|
+
fab: Boolean,
|
|
615
|
+
fabMini: Boolean,
|
|
616
|
+
padding: String,
|
|
617
|
+
color: String,
|
|
618
|
+
textColor: String,
|
|
619
|
+
noCaps: Boolean,
|
|
620
|
+
noWrap: Boolean,
|
|
621
|
+
dense: Boolean,
|
|
622
|
+
tabindex: [Number, String],
|
|
623
|
+
ripple: {
|
|
624
|
+
type: [Boolean, Object],
|
|
625
|
+
default: !0
|
|
626
|
+
},
|
|
627
|
+
align: {
|
|
628
|
+
...Ct.align,
|
|
629
|
+
default: "center"
|
|
630
|
+
},
|
|
631
|
+
stack: Boolean,
|
|
632
|
+
stretch: Boolean,
|
|
633
|
+
loading: {
|
|
634
|
+
type: Boolean,
|
|
635
|
+
default: null
|
|
636
|
+
},
|
|
637
|
+
disable: Boolean
|
|
638
|
+
}, Tt = {
|
|
639
|
+
...At,
|
|
640
|
+
round: Boolean
|
|
641
|
+
};
|
|
642
|
+
function zt(e) {
|
|
643
|
+
const t = de(e, Mt), n = Bt(e), { hasRouterLink: l, hasLink: s, linkTag: o, linkAttrs: a, navigateOnClick: i } = Xe({
|
|
644
|
+
fallbackTag: "button"
|
|
645
|
+
}), _ = u(() => {
|
|
646
|
+
const v = e.fab === !1 && e.fabMini === !1 ? t.value : {};
|
|
647
|
+
return e.padding !== void 0 ? Object.assign({}, v, {
|
|
648
|
+
padding: e.padding.split(/\s+/).map((k) => k in Pe ? Pe[k] + "px" : k).join(" "),
|
|
649
|
+
minWidth: "0",
|
|
650
|
+
minHeight: "0"
|
|
651
|
+
}) : v;
|
|
652
|
+
}), B = u(
|
|
653
|
+
() => e.rounded === !0 || e.fab === !0 || e.fabMini === !0
|
|
654
|
+
), f = u(
|
|
655
|
+
() => e.disable !== !0 && e.loading !== !0
|
|
656
|
+
), $ = u(() => f.value === !0 ? e.tabindex || 0 : -1), d = u(() => Ye(e, "standard")), y = u(() => {
|
|
657
|
+
const v = { tabindex: $.value };
|
|
658
|
+
return s.value === !0 ? Object.assign(v, a.value) : Rt.includes(e.type) === !0 && (v.type = e.type), o.value === "a" ? (e.disable === !0 ? v["aria-disabled"] = "true" : v.href === void 0 && (v.role = "button"), l.value !== !0 && Vt.test(e.type) === !0 && (v.type = e.type)) : e.disable === !0 && (v.disabled = "", v["aria-disabled"] = "true"), e.loading === !0 && e.percentage !== void 0 && Object.assign(v, {
|
|
659
|
+
role: "progressbar",
|
|
660
|
+
"aria-valuemin": 0,
|
|
661
|
+
"aria-valuemax": 100,
|
|
662
|
+
"aria-valuenow": e.percentage
|
|
663
|
+
}), v;
|
|
664
|
+
}), r = u(() => {
|
|
665
|
+
let v;
|
|
666
|
+
e.color !== void 0 ? e.flat === !0 || e.outline === !0 ? v = `text-${e.textColor || e.color}` : v = `bg-${e.color} text-${e.textColor || "white"}` : e.textColor && (v = `text-${e.textColor}`);
|
|
667
|
+
const k = e.round === !0 ? "round" : `rectangle${B.value === !0 ? " q-btn--rounded" : e.square === !0 ? " q-btn--square" : ""}`;
|
|
668
|
+
return `q-btn--${d.value} q-btn--${k}` + (v !== void 0 ? " " + v : "") + (f.value === !0 ? " q-btn--actionable q-focusable q-hoverable" : e.disable === !0 ? " disabled" : "") + (e.fab === !0 ? " q-btn--fab" : e.fabMini === !0 ? " q-btn--fab-mini" : "") + (e.noCaps === !0 ? " q-btn--no-uppercase" : "") + (e.dense === !0 ? " q-btn--dense" : "") + (e.stretch === !0 ? " no-border-radius self-stretch" : "") + (e.glossy === !0 ? " glossy" : "") + (e.square ? " q-btn--square" : "");
|
|
669
|
+
}), g = u(
|
|
670
|
+
() => n.value + (e.stack === !0 ? " column" : " row") + (e.noWrap === !0 ? " no-wrap text-no-wrap" : "") + (e.loading === !0 ? " q-btn__content--hidden" : "")
|
|
671
|
+
);
|
|
672
|
+
return {
|
|
673
|
+
classes: r,
|
|
674
|
+
style: _,
|
|
675
|
+
innerClasses: g,
|
|
676
|
+
attributes: y,
|
|
677
|
+
hasLink: s,
|
|
678
|
+
linkTag: o,
|
|
679
|
+
navigateOnClick: i,
|
|
680
|
+
isActionable: f
|
|
681
|
+
};
|
|
682
|
+
}
|
|
683
|
+
const { passiveCapture: z } = fe;
|
|
684
|
+
let Z = null, J = null, ee = null;
|
|
685
|
+
const Ot = ne({
|
|
686
|
+
name: "QBtn",
|
|
687
|
+
props: {
|
|
688
|
+
...Tt,
|
|
689
|
+
percentage: Number,
|
|
690
|
+
darkPercentage: Boolean,
|
|
691
|
+
onTouchstart: [Function, Array]
|
|
692
|
+
},
|
|
693
|
+
emits: ["click", "keydown", "mousedown", "keyup"],
|
|
694
|
+
setup(e, { slots: t, emit: n }) {
|
|
695
|
+
const { proxy: l } = te(), {
|
|
696
|
+
classes: s,
|
|
697
|
+
style: o,
|
|
698
|
+
innerClasses: a,
|
|
699
|
+
attributes: i,
|
|
700
|
+
hasLink: _,
|
|
701
|
+
linkTag: B,
|
|
702
|
+
navigateOnClick: f,
|
|
703
|
+
isActionable: $
|
|
704
|
+
} = zt(e), d = Q(null), y = Q(null);
|
|
705
|
+
let r = null, g, v = null;
|
|
706
|
+
const k = u(
|
|
707
|
+
() => e.label !== void 0 && e.label !== null && e.label !== ""
|
|
708
|
+
), S = u(() => e.disable === !0 || e.ripple === !1 ? !1 : {
|
|
709
|
+
keyCodes: _.value === !0 ? [13, 32] : [13],
|
|
710
|
+
...e.ripple === !0 ? {} : e.ripple
|
|
711
|
+
}), p = u(() => ({ center: e.round })), E = u(() => {
|
|
712
|
+
const c = Math.max(0, Math.min(100, e.percentage));
|
|
713
|
+
return c > 0 ? { transition: "transform 0.6s", transform: `translateX(${c - 100}%)` } : {};
|
|
714
|
+
}), q = u(() => {
|
|
715
|
+
if (e.loading === !0)
|
|
716
|
+
return {
|
|
717
|
+
onMousedown: I,
|
|
718
|
+
onTouchstart: I,
|
|
719
|
+
onClick: I,
|
|
720
|
+
onKeydown: I,
|
|
721
|
+
onKeyup: I
|
|
722
|
+
};
|
|
723
|
+
if ($.value === !0) {
|
|
724
|
+
const c = {
|
|
725
|
+
onClick: V,
|
|
726
|
+
onKeydown: O,
|
|
727
|
+
onMousedown: W
|
|
728
|
+
};
|
|
729
|
+
if (l.$q.platform.has.touch === !0) {
|
|
730
|
+
const w = e.onTouchstart !== void 0 ? "" : "Passive";
|
|
731
|
+
c[`onTouchstart${w}`] = j;
|
|
732
|
+
}
|
|
733
|
+
return c;
|
|
734
|
+
}
|
|
735
|
+
return {
|
|
736
|
+
// needed; especially for disabled <a> tags
|
|
737
|
+
onClick: N
|
|
738
|
+
};
|
|
739
|
+
}), R = u(() => ({
|
|
740
|
+
ref: d,
|
|
741
|
+
class: "q-btn q-btn-item non-selectable no-outline " + s.value,
|
|
742
|
+
style: o.value,
|
|
743
|
+
...i.value,
|
|
744
|
+
...q.value
|
|
745
|
+
}));
|
|
746
|
+
function V(c) {
|
|
747
|
+
if (d.value !== null) {
|
|
748
|
+
if (c !== void 0) {
|
|
749
|
+
if (c.defaultPrevented === !0) return;
|
|
750
|
+
const w = document.activeElement;
|
|
751
|
+
if (e.type === "submit" && w !== document.body && d.value.contains(w) === !1 && w.contains(d.value) === !1) {
|
|
752
|
+
c.qAvoidFocus !== !0 && d.value.focus();
|
|
753
|
+
const U = () => {
|
|
754
|
+
var le;
|
|
755
|
+
document.removeEventListener("keydown", N, !0), document.removeEventListener("keyup", U, z), (le = d.value) == null || le.removeEventListener("blur", U, z);
|
|
756
|
+
};
|
|
757
|
+
document.addEventListener("keydown", N, !0), document.addEventListener("keyup", U, z), d.value.addEventListener("blur", U, z);
|
|
758
|
+
}
|
|
759
|
+
}
|
|
760
|
+
f(c);
|
|
761
|
+
}
|
|
762
|
+
}
|
|
763
|
+
function O(c) {
|
|
764
|
+
d.value !== null && (n("keydown", c), ae(c, [13, 32]) === !0 && J !== d.value && (J !== null && h(), c.defaultPrevented !== !0 && (c.qAvoidFocus !== !0 && d.value.focus(), J = d.value, d.value.classList.add("q-btn--active"), document.addEventListener("keyup", T, !0), d.value.addEventListener("blur", T, z)), N(c)));
|
|
765
|
+
}
|
|
766
|
+
function j(c) {
|
|
767
|
+
d.value !== null && (n("touchstart", c), c.defaultPrevented !== !0 && (Z !== d.value && (Z !== null && h(), Z = d.value, r = c.target, r.addEventListener("touchcancel", T, z), r.addEventListener("touchend", T, z)), g = !0, v !== null && clearTimeout(v), v = setTimeout(() => {
|
|
768
|
+
v = null, g = !1;
|
|
769
|
+
}, 200)));
|
|
770
|
+
}
|
|
771
|
+
function W(c) {
|
|
772
|
+
d.value !== null && (c.qSkipRipple = g === !0, n("mousedown", c), c.defaultPrevented !== !0 && ee !== d.value && (ee !== null && h(), ee = d.value, d.value.classList.add("q-btn--active"), document.addEventListener("mouseup", T, z)));
|
|
773
|
+
}
|
|
774
|
+
function T(c) {
|
|
775
|
+
if (d.value !== null && !((c == null ? void 0 : c.type) === "blur" && document.activeElement === d.value)) {
|
|
776
|
+
if ((c == null ? void 0 : c.type) === "keyup") {
|
|
777
|
+
if (J === d.value && ae(c, [13, 32]) === !0) {
|
|
778
|
+
const w = new MouseEvent("click", c);
|
|
779
|
+
w.qKeyEvent = !0, c.defaultPrevented === !0 && bt(w), c.cancelBubble === !0 && Qe(w), d.value.dispatchEvent(w), N(c), c.qKeyEvent = !0;
|
|
780
|
+
}
|
|
781
|
+
n("keyup", c);
|
|
782
|
+
}
|
|
783
|
+
h();
|
|
784
|
+
}
|
|
785
|
+
}
|
|
786
|
+
function h(c) {
|
|
787
|
+
var U, le;
|
|
788
|
+
const w = y.value;
|
|
789
|
+
c !== !0 && (Z === d.value || ee === d.value) && w !== null && w !== document.activeElement && (w.setAttribute("tabindex", -1), w.focus()), Z === d.value && (r !== null && (r.removeEventListener("touchcancel", T, z), r.removeEventListener("touchend", T, z)), Z = r = null), ee === d.value && (document.removeEventListener("mouseup", T, z), ee = null), J === d.value && (document.removeEventListener("keyup", T, !0), (U = d.value) == null || U.removeEventListener("blur", T, z), J = null), (le = d.value) == null || le.classList.remove("q-btn--active");
|
|
790
|
+
}
|
|
791
|
+
function I(c) {
|
|
792
|
+
N(c), c.qSkipRipple = !0;
|
|
793
|
+
}
|
|
794
|
+
return Ge(() => {
|
|
795
|
+
h(!0);
|
|
796
|
+
}), Object.assign(l, {
|
|
797
|
+
click: (c) => {
|
|
798
|
+
$.value === !0 && V(c);
|
|
799
|
+
}
|
|
800
|
+
}), () => {
|
|
801
|
+
let c = [];
|
|
802
|
+
e.icon !== void 0 && c.push(
|
|
803
|
+
m(he, {
|
|
804
|
+
name: e.icon,
|
|
805
|
+
left: e.stack !== !0 && k.value === !0,
|
|
806
|
+
role: "img"
|
|
807
|
+
})
|
|
808
|
+
), k.value === !0 && c.push(
|
|
809
|
+
m("span", { class: "block" }, [e.label])
|
|
810
|
+
), c = H(t.default, c), e.iconRight !== void 0 && e.round === !1 && c.push(
|
|
811
|
+
m(he, {
|
|
812
|
+
name: e.iconRight,
|
|
813
|
+
right: e.stack !== !0 && k.value === !0,
|
|
814
|
+
role: "img"
|
|
815
|
+
})
|
|
816
|
+
);
|
|
817
|
+
const w = [
|
|
818
|
+
m("span", {
|
|
819
|
+
class: "q-focus-helper",
|
|
820
|
+
ref: y
|
|
821
|
+
})
|
|
822
|
+
];
|
|
823
|
+
return e.loading === !0 && e.percentage !== void 0 && w.push(
|
|
824
|
+
m("span", {
|
|
825
|
+
class: "q-btn__progress absolute-full overflow-hidden" + (e.darkPercentage === !0 ? " q-btn__progress--dark" : "")
|
|
826
|
+
}, [
|
|
827
|
+
m("span", {
|
|
828
|
+
class: "q-btn__progress-indicator fit block",
|
|
829
|
+
style: E.value
|
|
830
|
+
})
|
|
831
|
+
])
|
|
832
|
+
), w.push(
|
|
833
|
+
m("span", {
|
|
834
|
+
class: "q-btn__content text-center col items-center q-anchor--skip " + a.value
|
|
835
|
+
}, c)
|
|
836
|
+
), e.loading !== null && w.push(
|
|
837
|
+
m(Ze, {
|
|
838
|
+
name: "q-transition--fade"
|
|
839
|
+
}, () => e.loading === !0 ? [
|
|
840
|
+
m("span", {
|
|
841
|
+
key: "loading",
|
|
842
|
+
class: "absolute-full flex flex-center"
|
|
843
|
+
}, t.loading !== void 0 ? t.loading() : [m(xe)])
|
|
844
|
+
] : null)
|
|
845
|
+
), se(
|
|
846
|
+
m(
|
|
847
|
+
B.value,
|
|
848
|
+
R.value,
|
|
849
|
+
w
|
|
850
|
+
),
|
|
851
|
+
[[
|
|
852
|
+
$t,
|
|
853
|
+
S.value,
|
|
854
|
+
void 0,
|
|
855
|
+
p.value
|
|
856
|
+
]]
|
|
857
|
+
);
|
|
858
|
+
};
|
|
859
|
+
}
|
|
860
|
+
}), jt = /* @__PURE__ */ F({
|
|
861
|
+
__name: "AppButton",
|
|
862
|
+
props: {
|
|
863
|
+
size: { default: A.MD },
|
|
864
|
+
transparent: { type: Boolean },
|
|
865
|
+
flat: { type: Boolean },
|
|
866
|
+
rounded: { type: Boolean },
|
|
867
|
+
color: { default: Oe.PRIMARY },
|
|
868
|
+
iconLeft: {},
|
|
869
|
+
iconRight: {},
|
|
870
|
+
iconMiddle: {},
|
|
871
|
+
disabled: { type: Boolean },
|
|
872
|
+
loading: { type: Boolean },
|
|
873
|
+
to: {},
|
|
874
|
+
href: {},
|
|
875
|
+
target: {},
|
|
876
|
+
submit: { type: Boolean },
|
|
877
|
+
ariaLabel: {},
|
|
878
|
+
label: {},
|
|
879
|
+
download: {}
|
|
880
|
+
},
|
|
881
|
+
emits: ["click"],
|
|
882
|
+
setup(e) {
|
|
883
|
+
const t = e, n = u(() => [
|
|
884
|
+
"app-btn",
|
|
885
|
+
{
|
|
886
|
+
"app-btn_default": !t.transparent && !t.flat,
|
|
887
|
+
"app-btn_trans": t.transparent,
|
|
888
|
+
"app-btn_flat": t.flat,
|
|
889
|
+
"app-btn_rounded": t.rounded,
|
|
890
|
+
"app-btn_icon-left": t.iconLeft,
|
|
891
|
+
"app-btn_icon-right": t.iconRight,
|
|
892
|
+
"app-btn_icon-middle": t.iconMiddle
|
|
893
|
+
},
|
|
894
|
+
`app-btn_${t.size}`,
|
|
895
|
+
`app-btn_${t.color}`
|
|
896
|
+
]);
|
|
897
|
+
return (l, s) => (b(), K(D(Ot), {
|
|
898
|
+
"no-caps": "",
|
|
899
|
+
unelevated: "",
|
|
900
|
+
class: L(n.value),
|
|
901
|
+
padding: D(at)[l.size || D(A).MD],
|
|
902
|
+
loading: l.loading,
|
|
903
|
+
disable: l.disabled || void 0,
|
|
904
|
+
to: l.to,
|
|
905
|
+
href: l.href,
|
|
906
|
+
target: l.target,
|
|
907
|
+
type: l.submit ? "submit" : void 0,
|
|
908
|
+
"aria-label": l.ariaLabel,
|
|
909
|
+
download: l.download,
|
|
910
|
+
onClick: s[0] || (s[0] = (o) => l.$emit("click", o))
|
|
911
|
+
}, {
|
|
912
|
+
default: Ie(() => [
|
|
913
|
+
l.iconLeft || l.iconMiddle ? (b(), C("i", {
|
|
914
|
+
key: 0,
|
|
915
|
+
class: L([
|
|
916
|
+
"icon-kl",
|
|
917
|
+
l.iconLeft ? "icon-kl_left" : "icon-kl_middle",
|
|
918
|
+
`icon-kl-${l.iconLeft || l.iconMiddle}`,
|
|
919
|
+
l.transparent || l.flat ? `text-${l.color}` : "text-secondary"
|
|
920
|
+
])
|
|
921
|
+
}, null, 2)) : P("", !0),
|
|
922
|
+
X(l.$slots, "default", {}, void 0, !0),
|
|
923
|
+
l.label ? (b(), C(ie, { key: 1 }, [
|
|
924
|
+
ke(Y(l.label), 1)
|
|
925
|
+
], 64)) : P("", !0),
|
|
926
|
+
l.iconRight ? (b(), C("i", {
|
|
927
|
+
key: 2,
|
|
928
|
+
class: L([
|
|
929
|
+
"icon-kl",
|
|
930
|
+
"icon-kl_right",
|
|
931
|
+
`icon-kl-${l.iconRight}`,
|
|
932
|
+
l.transparent ? `text-${l.color}` : "text-secondary"
|
|
933
|
+
])
|
|
934
|
+
}, null, 2)) : P("", !0)
|
|
935
|
+
]),
|
|
936
|
+
_: 3
|
|
937
|
+
}, 8, ["class", "padding", "loading", "disable", "to", "href", "target", "type", "aria-label", "download"]));
|
|
938
|
+
}
|
|
939
|
+
}), x = (e, t) => {
|
|
940
|
+
const n = e.__vccOpts || e;
|
|
941
|
+
for (const [l, s] of t)
|
|
942
|
+
n[l] = s;
|
|
943
|
+
return n;
|
|
944
|
+
}, Kn = /* @__PURE__ */ x(jt, [["__scopeId", "data-v-c9951ab6"]]), Dt = /* @__PURE__ */ F({
|
|
945
|
+
__name: "CloseButton",
|
|
946
|
+
props: {
|
|
947
|
+
size: { default: A.MD }
|
|
948
|
+
},
|
|
949
|
+
setup(e) {
|
|
950
|
+
const t = e, n = u(() => ["close-btn", `close-btn_${t.size}`]);
|
|
951
|
+
return (l, s) => (b(), C("button", {
|
|
952
|
+
class: L(n.value),
|
|
953
|
+
type: "button",
|
|
954
|
+
"aria-label": "Close"
|
|
955
|
+
}, [...s[0] || (s[0] = [
|
|
956
|
+
M("i", { class: "icon-kl icon-kl-close" }, null, -1)
|
|
957
|
+
])], 2));
|
|
958
|
+
}
|
|
959
|
+
}), Fn = /* @__PURE__ */ x(Dt, [["__scopeId", "data-v-7cc56d51"]]), Nt = {
|
|
960
|
+
key: 0,
|
|
961
|
+
class: "app-toggle__label app-toggle__label_left"
|
|
962
|
+
}, Kt = { class: "app-toggle__container" }, Ft = ["checked", "disabled"], xt = { class: "app-toggle__thumb" }, Qt = {
|
|
963
|
+
key: 1,
|
|
964
|
+
class: "app-toggle__label"
|
|
965
|
+
}, Ut = /* @__PURE__ */ F({
|
|
966
|
+
__name: "AppToggle",
|
|
967
|
+
props: {
|
|
968
|
+
modelValue: { type: Boolean },
|
|
969
|
+
size: { default: A.MD },
|
|
970
|
+
label: {},
|
|
971
|
+
disabled: { type: Boolean },
|
|
972
|
+
color: { default: Oe.PRIMARY },
|
|
973
|
+
iconColor: {},
|
|
974
|
+
icon: {},
|
|
975
|
+
iconActive: {},
|
|
976
|
+
labelLeft: { type: Boolean }
|
|
977
|
+
},
|
|
978
|
+
emits: ["update:modelValue"],
|
|
979
|
+
setup(e, { emit: t }) {
|
|
980
|
+
const n = e, l = t, s = u({
|
|
981
|
+
get: () => n.modelValue,
|
|
982
|
+
set: (a) => {
|
|
983
|
+
l("update:modelValue", a);
|
|
984
|
+
}
|
|
985
|
+
}), o = u(() => [
|
|
986
|
+
"app-toggle",
|
|
987
|
+
{
|
|
988
|
+
"app-toggle_active": s.value,
|
|
989
|
+
"app-toggle_disabled": n.disabled
|
|
990
|
+
},
|
|
991
|
+
`app-toggle_${n.size}`,
|
|
992
|
+
`app-toggle_${n.color}`
|
|
993
|
+
]);
|
|
994
|
+
return (a, i) => (b(), C("div", {
|
|
995
|
+
class: L(o.value),
|
|
996
|
+
onClick: i[1] || (i[1] = Ae(() => {
|
|
997
|
+
}, ["stop"]))
|
|
998
|
+
}, [
|
|
999
|
+
a.label && a.labelLeft ? (b(), C("span", Nt, Y(a.label), 1)) : P("", !0),
|
|
1000
|
+
M("label", Kt, [
|
|
1001
|
+
M("input", {
|
|
1002
|
+
type: "checkbox",
|
|
1003
|
+
checked: s.value,
|
|
1004
|
+
onChange: i[0] || (i[0] = (_) => s.value = !s.value),
|
|
1005
|
+
disabled: a.disabled,
|
|
1006
|
+
class: "app-toggle__input"
|
|
1007
|
+
}, null, 40, Ft),
|
|
1008
|
+
M("span", {
|
|
1009
|
+
class: L(["app-toggle__slider", s.value ? `bg-${a.color}` : ""])
|
|
1010
|
+
}, [
|
|
1011
|
+
M("span", xt, [
|
|
1012
|
+
a.icon && !a.modelValue ? (b(), C("i", {
|
|
1013
|
+
key: 0,
|
|
1014
|
+
class: L(["icon-kl", `icon-kl-${a.icon}`, "app-toggle__icon"])
|
|
1015
|
+
}, null, 2)) : P("", !0),
|
|
1016
|
+
a.modelValue && (a.iconActive || a.icon) ? (b(), C("i", {
|
|
1017
|
+
key: 1,
|
|
1018
|
+
class: L([
|
|
1019
|
+
"icon-kl",
|
|
1020
|
+
`icon-kl-${a.iconActive || a.icon}`,
|
|
1021
|
+
"app-toggle__icon",
|
|
1022
|
+
s.value ? `text-${a.iconColor}` : ""
|
|
1023
|
+
])
|
|
1024
|
+
}, null, 2)) : P("", !0)
|
|
1025
|
+
])
|
|
1026
|
+
], 2),
|
|
1027
|
+
X(a.$slots, "default", {}, void 0, !0)
|
|
1028
|
+
]),
|
|
1029
|
+
a.label && !a.labelLeft ? (b(), C("span", Qt, Y(a.label), 1)) : P("", !0)
|
|
1030
|
+
], 2));
|
|
1031
|
+
}
|
|
1032
|
+
}), We = /* @__PURE__ */ x(Ut, [["__scopeId", "data-v-ba49356e"]]), ye = {
|
|
1033
|
+
dark: {
|
|
1034
|
+
type: Boolean,
|
|
1035
|
+
default: null
|
|
1036
|
+
}
|
|
1037
|
+
};
|
|
1038
|
+
function _e(e, t) {
|
|
1039
|
+
return u(() => e.dark === null ? t.dark.isActive : e.dark);
|
|
1040
|
+
}
|
|
1041
|
+
function Ht(e, t) {
|
|
1042
|
+
const n = Q(null), l = u(() => e.disable === !0 ? null : m("span", {
|
|
1043
|
+
ref: n,
|
|
1044
|
+
class: "no-outline",
|
|
1045
|
+
tabindex: -1
|
|
1046
|
+
}));
|
|
1047
|
+
function s(o) {
|
|
1048
|
+
const a = t.value;
|
|
1049
|
+
(o == null ? void 0 : o.qAvoidFocus) !== !0 && ((o == null ? void 0 : o.type.indexOf("key")) === 0 ? document.activeElement !== a && (a == null ? void 0 : a.contains(document.activeElement)) === !0 && a.focus() : n.value !== null && (o === void 0 || (a == null ? void 0 : a.contains(o.target)) === !0) && n.value.focus());
|
|
1050
|
+
}
|
|
1051
|
+
return {
|
|
1052
|
+
refocusTargetEl: l,
|
|
1053
|
+
refocusTarget: s
|
|
1054
|
+
};
|
|
1055
|
+
}
|
|
1056
|
+
const Xt = {
|
|
1057
|
+
name: String
|
|
1058
|
+
};
|
|
1059
|
+
function Yt(e = {}) {
|
|
1060
|
+
return (t, n, l) => {
|
|
1061
|
+
t[n](
|
|
1062
|
+
m("input", {
|
|
1063
|
+
class: "hidden" + (l || ""),
|
|
1064
|
+
...e.value
|
|
1065
|
+
})
|
|
1066
|
+
);
|
|
1067
|
+
};
|
|
1068
|
+
}
|
|
1069
|
+
function xn(e) {
|
|
1070
|
+
return u(() => e.name || e.for);
|
|
1071
|
+
}
|
|
1072
|
+
const Wt = {
|
|
1073
|
+
xs: 30,
|
|
1074
|
+
sm: 35,
|
|
1075
|
+
md: 40,
|
|
1076
|
+
lg: 50,
|
|
1077
|
+
xl: 60
|
|
1078
|
+
}, Gt = {
|
|
1079
|
+
...ye,
|
|
1080
|
+
...ce,
|
|
1081
|
+
...Xt,
|
|
1082
|
+
modelValue: {
|
|
1083
|
+
required: !0,
|
|
1084
|
+
default: null
|
|
1085
|
+
},
|
|
1086
|
+
val: {},
|
|
1087
|
+
trueValue: { default: !0 },
|
|
1088
|
+
falseValue: { default: !1 },
|
|
1089
|
+
indeterminateValue: { default: null },
|
|
1090
|
+
checkedIcon: String,
|
|
1091
|
+
uncheckedIcon: String,
|
|
1092
|
+
indeterminateIcon: String,
|
|
1093
|
+
toggleOrder: {
|
|
1094
|
+
type: String,
|
|
1095
|
+
validator: (e) => e === "tf" || e === "ft"
|
|
1096
|
+
},
|
|
1097
|
+
toggleIndeterminate: Boolean,
|
|
1098
|
+
label: String,
|
|
1099
|
+
leftLabel: Boolean,
|
|
1100
|
+
color: String,
|
|
1101
|
+
keepColor: Boolean,
|
|
1102
|
+
dense: Boolean,
|
|
1103
|
+
disable: Boolean,
|
|
1104
|
+
tabindex: [String, Number]
|
|
1105
|
+
}, Zt = ["update:modelValue"];
|
|
1106
|
+
function Jt(e, t) {
|
|
1107
|
+
const { props: n, slots: l, emit: s, proxy: o } = te(), { $q: a } = o, i = _e(n, a), _ = Q(null), { refocusTargetEl: B, refocusTarget: f } = Ht(n, _), $ = de(n, Wt), d = u(
|
|
1108
|
+
() => n.val !== void 0 && Array.isArray(n.modelValue)
|
|
1109
|
+
), y = u(() => {
|
|
1110
|
+
const h = G(n.val);
|
|
1111
|
+
return d.value === !0 ? n.modelValue.findIndex((I) => G(I) === h) : -1;
|
|
1112
|
+
}), r = u(() => d.value === !0 ? y.value !== -1 : G(n.modelValue) === G(n.trueValue)), g = u(() => d.value === !0 ? y.value === -1 : G(n.modelValue) === G(n.falseValue)), v = u(
|
|
1113
|
+
() => r.value === !1 && g.value === !1
|
|
1114
|
+
), k = u(() => n.disable === !0 ? -1 : n.tabindex || 0), S = u(
|
|
1115
|
+
() => `q-${e} cursor-pointer no-outline row inline no-wrap items-center` + (n.disable === !0 ? " disabled" : "") + (i.value === !0 ? ` q-${e}--dark` : "") + (n.dense === !0 ? ` q-${e}--dense` : "") + (n.leftLabel === !0 ? " reverse" : "")
|
|
1116
|
+
), p = u(() => {
|
|
1117
|
+
const h = r.value === !0 ? "truthy" : g.value === !0 ? "falsy" : "indet", I = n.color !== void 0 && (n.keepColor === !0 || g.value !== !0) ? ` text-${n.color}` : "";
|
|
1118
|
+
return `q-${e}__inner relative-position non-selectable q-${e}__inner--${h}${I}`;
|
|
1119
|
+
}), E = u(() => {
|
|
1120
|
+
const h = { type: "checkbox" };
|
|
1121
|
+
return n.name !== void 0 && Object.assign(h, {
|
|
1122
|
+
// see https://vuejs.org/guide/extras/render-function.html#creating-vnodes (.prop)
|
|
1123
|
+
".checked": r.value,
|
|
1124
|
+
"^checked": r.value === !0 ? "checked" : void 0,
|
|
1125
|
+
name: n.name,
|
|
1126
|
+
value: d.value === !0 ? n.val : n.trueValue
|
|
1127
|
+
}), h;
|
|
1128
|
+
}), q = Yt(E), R = u(() => {
|
|
1129
|
+
const h = {
|
|
1130
|
+
tabindex: k.value,
|
|
1131
|
+
role: "checkbox",
|
|
1132
|
+
"aria-label": n.label,
|
|
1133
|
+
"aria-checked": v.value === !0 ? "mixed" : r.value === !0 ? "true" : "false"
|
|
1134
|
+
};
|
|
1135
|
+
return n.disable === !0 && (h["aria-disabled"] = "true"), h;
|
|
1136
|
+
});
|
|
1137
|
+
function V(h) {
|
|
1138
|
+
h !== void 0 && (N(h), f(h)), n.disable !== !0 && s("update:modelValue", O(), h);
|
|
1139
|
+
}
|
|
1140
|
+
function O() {
|
|
1141
|
+
if (d.value === !0) {
|
|
1142
|
+
if (r.value === !0) {
|
|
1143
|
+
const h = n.modelValue.slice();
|
|
1144
|
+
return h.splice(y.value, 1), h;
|
|
1145
|
+
}
|
|
1146
|
+
return n.modelValue.concat([n.val]);
|
|
1147
|
+
}
|
|
1148
|
+
if (r.value === !0) {
|
|
1149
|
+
if (n.toggleOrder !== "ft" || n.toggleIndeterminate === !1)
|
|
1150
|
+
return n.falseValue;
|
|
1151
|
+
} else if (g.value === !0) {
|
|
1152
|
+
if (n.toggleOrder === "ft" || n.toggleIndeterminate === !1)
|
|
1153
|
+
return n.trueValue;
|
|
1154
|
+
} else
|
|
1155
|
+
return n.toggleOrder !== "ft" ? n.trueValue : n.falseValue;
|
|
1156
|
+
return n.indeterminateValue;
|
|
1157
|
+
}
|
|
1158
|
+
function j(h) {
|
|
1159
|
+
(h.keyCode === 13 || h.keyCode === 32) && N(h);
|
|
1160
|
+
}
|
|
1161
|
+
function W(h) {
|
|
1162
|
+
(h.keyCode === 13 || h.keyCode === 32) && V(h);
|
|
1163
|
+
}
|
|
1164
|
+
const T = t(r, v);
|
|
1165
|
+
return Object.assign(o, { toggle: V }), () => {
|
|
1166
|
+
const h = T();
|
|
1167
|
+
n.disable !== !0 && q(
|
|
1168
|
+
h,
|
|
1169
|
+
"unshift",
|
|
1170
|
+
` q-${e}__native absolute q-ma-none q-pa-none`
|
|
1171
|
+
);
|
|
1172
|
+
const I = [
|
|
1173
|
+
m("div", {
|
|
1174
|
+
class: p.value,
|
|
1175
|
+
style: $.value,
|
|
1176
|
+
"aria-hidden": "true"
|
|
1177
|
+
}, h)
|
|
1178
|
+
];
|
|
1179
|
+
B.value !== null && I.push(B.value);
|
|
1180
|
+
const c = n.label !== void 0 ? H(l.default, [n.label]) : De(l.default);
|
|
1181
|
+
return c !== void 0 && I.push(
|
|
1182
|
+
m("div", {
|
|
1183
|
+
class: `q-${e}__label q-anchor--skip`
|
|
1184
|
+
}, c)
|
|
1185
|
+
), m("div", {
|
|
1186
|
+
ref: _,
|
|
1187
|
+
class: S.value,
|
|
1188
|
+
...R.value,
|
|
1189
|
+
onClick: V,
|
|
1190
|
+
onKeydown: j,
|
|
1191
|
+
onKeyup: W
|
|
1192
|
+
}, I);
|
|
1193
|
+
};
|
|
1194
|
+
}
|
|
1195
|
+
const en = () => m("div", {
|
|
1196
|
+
key: "svg",
|
|
1197
|
+
class: "q-checkbox__bg absolute"
|
|
1198
|
+
}, [
|
|
1199
|
+
m("svg", {
|
|
1200
|
+
class: "q-checkbox__svg fit absolute-full",
|
|
1201
|
+
viewBox: "0 0 24 24"
|
|
1202
|
+
}, [
|
|
1203
|
+
m("path", {
|
|
1204
|
+
class: "q-checkbox__truthy",
|
|
1205
|
+
fill: "none",
|
|
1206
|
+
d: "M1.73,12.91 8.1,19.28 22.79,4.59"
|
|
1207
|
+
}),
|
|
1208
|
+
m("path", {
|
|
1209
|
+
class: "q-checkbox__indet",
|
|
1210
|
+
d: "M4,14H20V10H4"
|
|
1211
|
+
})
|
|
1212
|
+
])
|
|
1213
|
+
]), tn = ne({
|
|
1214
|
+
name: "QCheckbox",
|
|
1215
|
+
props: Gt,
|
|
1216
|
+
emits: Zt,
|
|
1217
|
+
setup(e) {
|
|
1218
|
+
const t = en();
|
|
1219
|
+
function n(l, s) {
|
|
1220
|
+
const o = u(
|
|
1221
|
+
() => (l.value === !0 ? e.checkedIcon : s.value === !0 ? e.indeterminateIcon : e.uncheckedIcon) || null
|
|
1222
|
+
);
|
|
1223
|
+
return () => o.value !== null ? [
|
|
1224
|
+
m("div", {
|
|
1225
|
+
key: "icon",
|
|
1226
|
+
class: "q-checkbox__icon-container absolute-full flex flex-center no-wrap"
|
|
1227
|
+
}, [
|
|
1228
|
+
m(he, {
|
|
1229
|
+
class: "q-checkbox__icon",
|
|
1230
|
+
name: o.value
|
|
1231
|
+
})
|
|
1232
|
+
])
|
|
1233
|
+
] : [t];
|
|
1234
|
+
}
|
|
1235
|
+
return Jt("checkbox", n);
|
|
1236
|
+
}
|
|
1237
|
+
}), nn = [];
|
|
1238
|
+
function ln(e) {
|
|
1239
|
+
return nn.find(
|
|
1240
|
+
(t) => t.contentEl !== null && t.contentEl.contains(e)
|
|
1241
|
+
);
|
|
1242
|
+
}
|
|
1243
|
+
function an(e, t) {
|
|
1244
|
+
do {
|
|
1245
|
+
if (e.$options.name === "QMenu") {
|
|
1246
|
+
if (e.hide(t), e.$props.separateClosePopup === !0)
|
|
1247
|
+
return oe(e);
|
|
1248
|
+
} else if (e.__qPortal === !0) {
|
|
1249
|
+
const n = oe(e);
|
|
1250
|
+
return (n == null ? void 0 : n.$options.name) === "QPopupProxy" ? (e.hide(t), n) : e;
|
|
1251
|
+
}
|
|
1252
|
+
e = oe(e);
|
|
1253
|
+
} while (e != null);
|
|
1254
|
+
}
|
|
1255
|
+
function on(e, t, n) {
|
|
1256
|
+
for (; n !== 0 && e !== void 0 && e !== null; ) {
|
|
1257
|
+
if (e.__qPortal === !0) {
|
|
1258
|
+
if (n--, e.$options.name === "QMenu") {
|
|
1259
|
+
e = an(e, t);
|
|
1260
|
+
continue;
|
|
1261
|
+
}
|
|
1262
|
+
e.hide(t);
|
|
1263
|
+
}
|
|
1264
|
+
e = oe(e);
|
|
1265
|
+
}
|
|
1266
|
+
}
|
|
1267
|
+
function Me(e) {
|
|
1268
|
+
if (e === !1)
|
|
1269
|
+
return 0;
|
|
1270
|
+
if (e === !0 || e === void 0)
|
|
1271
|
+
return 1;
|
|
1272
|
+
const t = parseInt(e, 10);
|
|
1273
|
+
return isNaN(t) ? 0 : t;
|
|
1274
|
+
}
|
|
1275
|
+
const sn = je(
|
|
1276
|
+
{
|
|
1277
|
+
name: "close-popup",
|
|
1278
|
+
beforeMount(e, { value: t }) {
|
|
1279
|
+
const n = {
|
|
1280
|
+
depth: Me(t),
|
|
1281
|
+
handler(l) {
|
|
1282
|
+
n.depth !== 0 && setTimeout(() => {
|
|
1283
|
+
const s = ln(e);
|
|
1284
|
+
s !== void 0 && on(s, l, n.depth);
|
|
1285
|
+
});
|
|
1286
|
+
},
|
|
1287
|
+
handlerKey(l) {
|
|
1288
|
+
ae(l, 13) === !0 && n.handler(l);
|
|
1289
|
+
}
|
|
1290
|
+
};
|
|
1291
|
+
e.__qclosepopup = n, e.addEventListener("click", n.handler), e.addEventListener("keyup", n.handlerKey);
|
|
1292
|
+
},
|
|
1293
|
+
updated(e, { value: t, oldValue: n }) {
|
|
1294
|
+
t !== n && (e.__qclosepopup.depth = Me(t));
|
|
1295
|
+
},
|
|
1296
|
+
beforeUnmount(e) {
|
|
1297
|
+
const t = e.__qclosepopup;
|
|
1298
|
+
e.removeEventListener("click", t.handler), e.removeEventListener("keyup", t.handlerKey), delete e.__qclosepopup;
|
|
1299
|
+
}
|
|
1300
|
+
}
|
|
1301
|
+
), un = {
|
|
1302
|
+
key: 0,
|
|
1303
|
+
class: "menu-item__loading"
|
|
1304
|
+
}, rn = {
|
|
1305
|
+
key: 0,
|
|
1306
|
+
class: "menu-item__checked"
|
|
1307
|
+
}, cn = {
|
|
1308
|
+
key: 2,
|
|
1309
|
+
class: "menu-item__icon"
|
|
1310
|
+
}, dn = { class: "menu-item__label" }, fn = {
|
|
1311
|
+
key: 3,
|
|
1312
|
+
class: "menu-item__icon-right icon-kl icon-kl-arrow-right"
|
|
1313
|
+
}, vn = /* @__PURE__ */ F({
|
|
1314
|
+
__name: "PopupItem",
|
|
1315
|
+
props: {
|
|
1316
|
+
label: {},
|
|
1317
|
+
icon: {},
|
|
1318
|
+
iconSize: {},
|
|
1319
|
+
color: {},
|
|
1320
|
+
iconRight: {},
|
|
1321
|
+
arrow: { type: Boolean },
|
|
1322
|
+
toggle: { type: Boolean },
|
|
1323
|
+
checkbox: { type: Boolean },
|
|
1324
|
+
active: { type: Boolean },
|
|
1325
|
+
modelValue: { type: Boolean },
|
|
1326
|
+
persistent: { type: Boolean },
|
|
1327
|
+
loading: { type: Boolean },
|
|
1328
|
+
disabled: { type: Boolean },
|
|
1329
|
+
gap: { type: Boolean },
|
|
1330
|
+
checked: { type: Boolean },
|
|
1331
|
+
isMobile: { type: Boolean }
|
|
1332
|
+
},
|
|
1333
|
+
emits: ["update:modelValue", "closePopup"],
|
|
1334
|
+
setup(e, { emit: t }) {
|
|
1335
|
+
const n = e, l = t, s = () => {
|
|
1336
|
+
n.disabled || (n.toggle || n.checkbox ? l("update:modelValue", !n.modelValue) : n.persistent || l("closePopup"));
|
|
1337
|
+
};
|
|
1338
|
+
return (o, a) => se((b(), C("div", {
|
|
1339
|
+
class: L(["menu-item", [
|
|
1340
|
+
{ "menu-item_gap": o.gap },
|
|
1341
|
+
{ "menu-item_disabled": o.disabled },
|
|
1342
|
+
{ "menu-item_active": o.active },
|
|
1343
|
+
{ "menu-item_mobile": o.isMobile }
|
|
1344
|
+
]]),
|
|
1345
|
+
onClick: s
|
|
1346
|
+
}, [
|
|
1347
|
+
M("div", {
|
|
1348
|
+
class: L(["row items-center no-wrap", `text-${o.color ? o.color : "dark"}`])
|
|
1349
|
+
}, [
|
|
1350
|
+
o.loading ? (b(), C("div", un, [
|
|
1351
|
+
Je(D(xe), {
|
|
1352
|
+
size: "19px",
|
|
1353
|
+
color: o.color ? o.color : "dark"
|
|
1354
|
+
}, null, 8, ["color"])
|
|
1355
|
+
])) : (b(), C(ie, { key: 1 }, [
|
|
1356
|
+
o.checked ? (b(), C("div", rn, [...a[3] || (a[3] = [
|
|
1357
|
+
M("i", { class: "icon-kl icon-kl-check" }, null, -1)
|
|
1358
|
+
])])) : P("", !0),
|
|
1359
|
+
o.checkbox ? (b(), K(tn, {
|
|
1360
|
+
key: 1,
|
|
1361
|
+
class: "menu-item__checkbox",
|
|
1362
|
+
size: "34px",
|
|
1363
|
+
"model-value": o.modelValue,
|
|
1364
|
+
"onUpdate:modelValue": a[0] || (a[0] = (i) => l("update:modelValue", i)),
|
|
1365
|
+
onClick: a[1] || (a[1] = Ae(() => {
|
|
1366
|
+
}, ["stop"]))
|
|
1367
|
+
}, null, 8, ["model-value"])) : P("", !0),
|
|
1368
|
+
o.icon ? (b(), C("div", cn, [
|
|
1369
|
+
M("i", {
|
|
1370
|
+
class: L(`icon-kl icon-kl-${o.icon}`),
|
|
1371
|
+
style: ue({ fontSize: o.iconSize || "27px" })
|
|
1372
|
+
}, null, 6)
|
|
1373
|
+
])) : P("", !0)
|
|
1374
|
+
], 64)),
|
|
1375
|
+
M("span", dn, Y(o.label), 1)
|
|
1376
|
+
], 2),
|
|
1377
|
+
o.$slots.right ? X(o.$slots, "right", { key: 0 }, void 0, !0) : o.toggle ? (b(), K(We, {
|
|
1378
|
+
key: 1,
|
|
1379
|
+
class: "menu-item__toggle",
|
|
1380
|
+
"model-value": o.modelValue,
|
|
1381
|
+
disabled: o.disabled || o.loading,
|
|
1382
|
+
"onUpdate:modelValue": a[2] || (a[2] = (i) => l("update:modelValue", i))
|
|
1383
|
+
}, null, 8, ["model-value", "disabled"])) : o.iconRight ? (b(), C("i", {
|
|
1384
|
+
key: 2,
|
|
1385
|
+
class: L([
|
|
1386
|
+
"menu-item__icon-right menu-item__icon-right_custom icon-kl",
|
|
1387
|
+
`icon-kl-${o.iconRight}`
|
|
1388
|
+
])
|
|
1389
|
+
}, null, 2)) : o.arrow ? (b(), C("i", fn)) : P("", !0)
|
|
1390
|
+
], 2)), [
|
|
1391
|
+
[sn, !o.toggle && !o.checkbox && !o.persistent && !o.disabled]
|
|
1392
|
+
]);
|
|
1393
|
+
}
|
|
1394
|
+
}), Qn = /* @__PURE__ */ x(vn, [["__scopeId", "data-v-4b2a03b5"]]), mn = /* @__PURE__ */ F({
|
|
1395
|
+
__name: "AppIcon",
|
|
1396
|
+
props: {
|
|
1397
|
+
name: {},
|
|
1398
|
+
size: {},
|
|
1399
|
+
color: {}
|
|
1400
|
+
},
|
|
1401
|
+
setup(e) {
|
|
1402
|
+
return (t, n) => (b(), C("i", {
|
|
1403
|
+
class: L(["icon-kl", `icon-kl-${t.name}`, t.color ? `text-${t.color}` : ""]),
|
|
1404
|
+
style: ue(t.size ? `font-size: ${t.size}` : void 0)
|
|
1405
|
+
}, null, 6));
|
|
1406
|
+
}
|
|
1407
|
+
}), ge = /* @__PURE__ */ x(mn, [["__scopeId", "data-v-941765ee"]]), gn = {
|
|
1408
|
+
xs: 2,
|
|
1409
|
+
sm: 4,
|
|
1410
|
+
md: 6,
|
|
1411
|
+
lg: 10,
|
|
1412
|
+
xl: 14
|
|
1413
|
+
};
|
|
1414
|
+
function Re(e, t, n) {
|
|
1415
|
+
return {
|
|
1416
|
+
transform: t === !0 ? `translateX(${n.lang.rtl === !0 ? "-" : ""}100%) scale3d(${-e},1,1)` : `scale3d(${e},1,1)`
|
|
1417
|
+
};
|
|
1418
|
+
}
|
|
1419
|
+
const pn = ne({
|
|
1420
|
+
name: "QLinearProgress",
|
|
1421
|
+
props: {
|
|
1422
|
+
...ye,
|
|
1423
|
+
...ce,
|
|
1424
|
+
value: {
|
|
1425
|
+
type: Number,
|
|
1426
|
+
default: 0
|
|
1427
|
+
},
|
|
1428
|
+
buffer: Number,
|
|
1429
|
+
color: String,
|
|
1430
|
+
trackColor: String,
|
|
1431
|
+
reverse: Boolean,
|
|
1432
|
+
stripe: Boolean,
|
|
1433
|
+
indeterminate: Boolean,
|
|
1434
|
+
query: Boolean,
|
|
1435
|
+
rounded: Boolean,
|
|
1436
|
+
animationSpeed: {
|
|
1437
|
+
type: [String, Number],
|
|
1438
|
+
default: 2100
|
|
1439
|
+
},
|
|
1440
|
+
instantFeedback: Boolean
|
|
1441
|
+
},
|
|
1442
|
+
setup(e, { slots: t }) {
|
|
1443
|
+
const { proxy: n } = te(), l = _e(e, n.$q), s = de(e, gn), o = u(() => e.indeterminate === !0 || e.query === !0), a = u(() => e.reverse !== e.query), i = u(() => ({
|
|
1444
|
+
...s.value !== null ? s.value : {},
|
|
1445
|
+
"--q-linear-progress-speed": `${e.animationSpeed}ms`
|
|
1446
|
+
})), _ = u(
|
|
1447
|
+
() => "q-linear-progress" + (e.color !== void 0 ? ` text-${e.color}` : "") + (e.reverse === !0 || e.query === !0 ? " q-linear-progress--reverse" : "") + (e.rounded === !0 ? " rounded-borders" : "")
|
|
1448
|
+
), B = u(() => Re(e.buffer !== void 0 ? e.buffer : 1, a.value, n.$q)), f = u(() => `with${e.instantFeedback === !0 ? "out" : ""}-transition`), $ = u(
|
|
1449
|
+
() => `q-linear-progress__track absolute-full q-linear-progress__track--${f.value} q-linear-progress__track--${l.value === !0 ? "dark" : "light"}` + (e.trackColor !== void 0 ? ` bg-${e.trackColor}` : "")
|
|
1450
|
+
), d = u(() => Re(o.value === !0 ? 1 : e.value, a.value, n.$q)), y = u(
|
|
1451
|
+
() => `q-linear-progress__model absolute-full q-linear-progress__model--${f.value} q-linear-progress__model--${o.value === !0 ? "in" : ""}determinate`
|
|
1452
|
+
), r = u(() => ({ width: `${e.value * 100}%` })), g = u(
|
|
1453
|
+
() => `q-linear-progress__stripe absolute-${e.reverse === !0 ? "right" : "left"} q-linear-progress__stripe--${f.value}`
|
|
1454
|
+
);
|
|
1455
|
+
return () => {
|
|
1456
|
+
const v = [
|
|
1457
|
+
m("div", {
|
|
1458
|
+
class: $.value,
|
|
1459
|
+
style: B.value
|
|
1460
|
+
}),
|
|
1461
|
+
m("div", {
|
|
1462
|
+
class: y.value,
|
|
1463
|
+
style: d.value
|
|
1464
|
+
})
|
|
1465
|
+
];
|
|
1466
|
+
return e.stripe === !0 && o.value === !1 && v.push(
|
|
1467
|
+
m("div", {
|
|
1468
|
+
class: g.value,
|
|
1469
|
+
style: r.value
|
|
1470
|
+
})
|
|
1471
|
+
), m("div", {
|
|
1472
|
+
class: _.value,
|
|
1473
|
+
style: i.value,
|
|
1474
|
+
role: "progressbar",
|
|
1475
|
+
"aria-valuemin": 0,
|
|
1476
|
+
"aria-valuemax": 1,
|
|
1477
|
+
"aria-valuenow": e.indeterminate === !0 ? void 0 : e.value
|
|
1478
|
+
}, H(t.default, v));
|
|
1479
|
+
};
|
|
1480
|
+
}
|
|
1481
|
+
}), bn = {
|
|
1482
|
+
key: 0,
|
|
1483
|
+
class: "code-field__label"
|
|
1484
|
+
}, hn = { class: "code-field__inputs" }, kn = ["onUpdate:modelValue", "disabled", "onInput", "onKeydown", "onPaste"], yn = /* @__PURE__ */ F({
|
|
1485
|
+
__name: "AppCodeInput",
|
|
1486
|
+
props: {
|
|
1487
|
+
length: { default: 5 },
|
|
1488
|
+
size: { default: A.MD },
|
|
1489
|
+
label: {},
|
|
1490
|
+
disabled: { type: Boolean },
|
|
1491
|
+
loading: { type: Boolean },
|
|
1492
|
+
autofocus: { type: Boolean },
|
|
1493
|
+
color: {}
|
|
1494
|
+
},
|
|
1495
|
+
emits: ["update:modelValue", "completed"],
|
|
1496
|
+
setup(e, { expose: t, emit: n }) {
|
|
1497
|
+
const l = e, s = n, o = Q(Array(l.length).fill("")), a = Q([]), i = u(() => [
|
|
1498
|
+
"code-field",
|
|
1499
|
+
{
|
|
1500
|
+
"code-field_disabled": l.disabled || l.loading
|
|
1501
|
+
},
|
|
1502
|
+
`code-field_${l.size}`,
|
|
1503
|
+
`code-field_${l.color}`
|
|
1504
|
+
]), _ = u(() => {
|
|
1505
|
+
let r = "";
|
|
1506
|
+
return l.size == A.SM && (r += `width: ${l.length * 26 + (l.length - 1) * 5}px`), l.size == A.MD && (r += `width: ${l.length * 32 + (l.length - 1) * 8}px`), l.size == A.LG && (r += `width: ${l.length * 44 + (l.length - 1) * 10}px`), r;
|
|
1507
|
+
}), B = (r, g) => {
|
|
1508
|
+
var S;
|
|
1509
|
+
const k = r.target.value;
|
|
1510
|
+
if (k.length === 1)
|
|
1511
|
+
g < l.length - 1 && a.value && ((S = a.value[g + 1]) == null || S.focus());
|
|
1512
|
+
else if (k.length > 1) {
|
|
1513
|
+
const p = k.slice(0, l.length - g).split("");
|
|
1514
|
+
p.forEach((E, q) => {
|
|
1515
|
+
o.value[g + q] = E;
|
|
1516
|
+
}), $e(() => {
|
|
1517
|
+
var E;
|
|
1518
|
+
a.value && ((E = a.value[Math.min(g + p.length, l.length - 1)]) == null || E.focus());
|
|
1519
|
+
});
|
|
1520
|
+
}
|
|
1521
|
+
}, f = (r) => {
|
|
1522
|
+
var g;
|
|
1523
|
+
o.value[r] === "" && a.value && r > 0 && ((g = a.value[r - 1]) == null || g.focus());
|
|
1524
|
+
}, $ = (r, g) => {
|
|
1525
|
+
var S;
|
|
1526
|
+
r.preventDefault();
|
|
1527
|
+
const v = ((S = r.clipboardData) == null ? void 0 : S.getData("text")) ?? "";
|
|
1528
|
+
if (!v) return;
|
|
1529
|
+
const k = v.slice(0, l.length - g).split("");
|
|
1530
|
+
k.forEach((p, E) => {
|
|
1531
|
+
o.value[g + E] = p;
|
|
1532
|
+
}), $e(() => {
|
|
1533
|
+
var p;
|
|
1534
|
+
a.value && ((p = a.value[Math.min(g + k.length, l.length - 1)]) == null || p.focus());
|
|
1535
|
+
});
|
|
1536
|
+
};
|
|
1537
|
+
et(
|
|
1538
|
+
o,
|
|
1539
|
+
(r) => {
|
|
1540
|
+
const g = r.join("");
|
|
1541
|
+
d(g);
|
|
1542
|
+
},
|
|
1543
|
+
{ deep: !0 }
|
|
1544
|
+
);
|
|
1545
|
+
const d = (r) => {
|
|
1546
|
+
s("update:modelValue", r), r.length === l.length && !r.includes(" ") && s("completed", r);
|
|
1547
|
+
}, y = (r) => {
|
|
1548
|
+
r && (o.value = r.split("").slice(0, l.length));
|
|
1549
|
+
};
|
|
1550
|
+
return tt(() => {
|
|
1551
|
+
l.autofocus && a.value && a.value[0] && a.value[0].focus();
|
|
1552
|
+
}), t({
|
|
1553
|
+
injectCode: y
|
|
1554
|
+
}), (r, g) => (b(), C("div", {
|
|
1555
|
+
class: L(i.value),
|
|
1556
|
+
style: ue(_.value)
|
|
1557
|
+
}, [
|
|
1558
|
+
r.label ? (b(), C("label", bn, Y(r.label), 1)) : P("", !0),
|
|
1559
|
+
M("div", hn, [
|
|
1560
|
+
(b(!0), C(ie, null, Te(r.length, (v, k) => se((b(), C("input", {
|
|
1561
|
+
key: k,
|
|
1562
|
+
"onUpdate:modelValue": (S) => o.value[k] = S,
|
|
1563
|
+
ref_for: !0,
|
|
1564
|
+
ref_key: "inputRefs",
|
|
1565
|
+
ref: a,
|
|
1566
|
+
type: "number",
|
|
1567
|
+
maxlength: "1",
|
|
1568
|
+
class: "code-field__input",
|
|
1569
|
+
disabled: r.disabled || r.loading,
|
|
1570
|
+
onInput: (S) => B(S, k),
|
|
1571
|
+
onKeydown: nt((S) => f(k), ["backspace"]),
|
|
1572
|
+
onPaste: (S) => $(S, k)
|
|
1573
|
+
}, null, 40, kn)), [
|
|
1574
|
+
[lt, o.value[k]]
|
|
1575
|
+
])), 128))
|
|
1576
|
+
]),
|
|
1577
|
+
r.loading ? (b(), K(pn, {
|
|
1578
|
+
key: 1,
|
|
1579
|
+
indeterminate: "",
|
|
1580
|
+
rounded: "",
|
|
1581
|
+
color: r.color,
|
|
1582
|
+
class: "code-field__loading"
|
|
1583
|
+
}, null, 8, ["color"])) : P("", !0)
|
|
1584
|
+
], 6));
|
|
1585
|
+
}
|
|
1586
|
+
}), Un = /* @__PURE__ */ x(yn, [["__scopeId", "data-v-4e11db87"]]), _n = { class: "app-segment__track" }, $n = { class: "app-segment__buttons" }, qn = ["onClick", "disabled"], Cn = /* @__PURE__ */ F({
|
|
1587
|
+
__name: "AppSegment",
|
|
1588
|
+
props: /* @__PURE__ */ pe({
|
|
1589
|
+
options: {},
|
|
1590
|
+
disabled: { type: Boolean },
|
|
1591
|
+
size: { default: A.MD }
|
|
1592
|
+
}, {
|
|
1593
|
+
modelValue: {},
|
|
1594
|
+
modelModifiers: {}
|
|
1595
|
+
}),
|
|
1596
|
+
emits: ["update:modelValue"],
|
|
1597
|
+
setup(e) {
|
|
1598
|
+
const t = ze(e, "modelValue"), n = e, l = u(
|
|
1599
|
+
() => n.options.findIndex((o) => o.value === t.value)
|
|
1600
|
+
);
|
|
1601
|
+
function s(o) {
|
|
1602
|
+
n.disabled || (t.value = o);
|
|
1603
|
+
}
|
|
1604
|
+
return (o, a) => (b(), C("div", {
|
|
1605
|
+
class: L(["app-segment", [{ "app-segment_disabled": o.disabled }, `app-segment_${o.size}`]])
|
|
1606
|
+
}, [
|
|
1607
|
+
M("div", _n, [
|
|
1608
|
+
M("div", {
|
|
1609
|
+
class: "app-segment__thumb",
|
|
1610
|
+
style: ue({
|
|
1611
|
+
width: `${100 / o.options.length}%`,
|
|
1612
|
+
transform: `translateX(${l.value * 100}%)`
|
|
1613
|
+
})
|
|
1614
|
+
}, null, 4)
|
|
1615
|
+
]),
|
|
1616
|
+
M("div", $n, [
|
|
1617
|
+
(b(!0), C(ie, null, Te(o.options, (i, _) => (b(), C("button", {
|
|
1618
|
+
key: _,
|
|
1619
|
+
class: L(["app-segment__btn", { active: t.value === i.value }]),
|
|
1620
|
+
onClick: (B) => s(i.value),
|
|
1621
|
+
disabled: o.disabled
|
|
1622
|
+
}, [
|
|
1623
|
+
X(o.$slots, "option", { option: i }, () => [
|
|
1624
|
+
ke(Y(i.label), 1)
|
|
1625
|
+
], !0)
|
|
1626
|
+
], 10, qn))), 128))
|
|
1627
|
+
])
|
|
1628
|
+
], 2));
|
|
1629
|
+
}
|
|
1630
|
+
}), Hn = /* @__PURE__ */ x(Cn, [["__scopeId", "data-v-ff56abdf"]]), Bn = {}, Sn = { class: "system-menu" };
|
|
1631
|
+
function wn(e, t) {
|
|
1632
|
+
return b(), C("div", Sn, [
|
|
1633
|
+
X(e.$slots, "default", {}, void 0, !0)
|
|
1634
|
+
]);
|
|
1635
|
+
}
|
|
1636
|
+
const Xn = /* @__PURE__ */ x(Bn, [["render", wn], ["__scopeId", "data-v-5649b2f4"]]), En = ne({
|
|
1637
|
+
name: "QItem",
|
|
1638
|
+
props: {
|
|
1639
|
+
...ye,
|
|
1640
|
+
...Pt,
|
|
1641
|
+
tag: {
|
|
1642
|
+
type: String,
|
|
1643
|
+
default: "div"
|
|
1644
|
+
},
|
|
1645
|
+
active: {
|
|
1646
|
+
type: Boolean,
|
|
1647
|
+
default: null
|
|
1648
|
+
},
|
|
1649
|
+
clickable: Boolean,
|
|
1650
|
+
dense: Boolean,
|
|
1651
|
+
insetLevel: Number,
|
|
1652
|
+
tabindex: [String, Number],
|
|
1653
|
+
focused: Boolean,
|
|
1654
|
+
manualFocus: Boolean
|
|
1655
|
+
},
|
|
1656
|
+
emits: ["click", "keyup"],
|
|
1657
|
+
setup(e, { slots: t, emit: n }) {
|
|
1658
|
+
const { proxy: { $q: l } } = te(), s = _e(e, l), { hasLink: o, linkAttrs: a, linkClass: i, linkTag: _, navigateOnClick: B } = Xe(), f = Q(null), $ = Q(null), d = u(
|
|
1659
|
+
() => e.clickable === !0 || o.value === !0 || e.tag === "label"
|
|
1660
|
+
), y = u(
|
|
1661
|
+
() => e.disable !== !0 && d.value === !0
|
|
1662
|
+
), r = u(
|
|
1663
|
+
() => "q-item q-item-type row no-wrap" + (e.dense === !0 ? " q-item--dense" : "") + (s.value === !0 ? " q-item--dark" : "") + (o.value === !0 && e.active === null ? i.value : e.active === !0 ? ` q-item--active${e.activeClass !== void 0 ? ` ${e.activeClass}` : ""}` : "") + (e.disable === !0 ? " disabled" : "") + (y.value === !0 ? " q-item--clickable q-link cursor-pointer " + (e.manualFocus === !0 ? "q-manual-focusable" : "q-focusable q-hoverable") + (e.focused === !0 ? " q-manual-focusable--focused" : "") : "")
|
|
1664
|
+
), g = u(() => e.insetLevel === void 0 ? null : {
|
|
1665
|
+
["padding" + (l.lang.rtl === !0 ? "Right" : "Left")]: 16 + e.insetLevel * 56 + "px"
|
|
1666
|
+
});
|
|
1667
|
+
function v(p) {
|
|
1668
|
+
y.value === !0 && ($.value !== null && p.qAvoidFocus !== !0 && (p.qKeyEvent !== !0 && document.activeElement === f.value ? $.value.focus() : document.activeElement === $.value && f.value.focus()), B(p));
|
|
1669
|
+
}
|
|
1670
|
+
function k(p) {
|
|
1671
|
+
if (y.value === !0 && ae(p, [13, 32]) === !0) {
|
|
1672
|
+
N(p), p.qKeyEvent = !0;
|
|
1673
|
+
const E = new MouseEvent("click", p);
|
|
1674
|
+
E.qKeyEvent = !0, f.value.dispatchEvent(E);
|
|
1675
|
+
}
|
|
1676
|
+
n("keyup", p);
|
|
1677
|
+
}
|
|
1678
|
+
function S() {
|
|
1679
|
+
const p = ot(t.default, []);
|
|
1680
|
+
return y.value === !0 && p.unshift(
|
|
1681
|
+
m("div", { class: "q-focus-helper", tabindex: -1, ref: $ })
|
|
1682
|
+
), p;
|
|
1683
|
+
}
|
|
1684
|
+
return () => {
|
|
1685
|
+
const p = {
|
|
1686
|
+
ref: f,
|
|
1687
|
+
class: r.value,
|
|
1688
|
+
style: g.value,
|
|
1689
|
+
role: "listitem",
|
|
1690
|
+
onClick: v,
|
|
1691
|
+
onKeyup: k
|
|
1692
|
+
};
|
|
1693
|
+
return y.value === !0 ? (p.tabindex = e.tabindex || "0", Object.assign(p, a.value)) : d.value === !0 && (p["aria-disabled"] = "true"), m(
|
|
1694
|
+
_.value,
|
|
1695
|
+
p,
|
|
1696
|
+
S()
|
|
1697
|
+
);
|
|
1698
|
+
};
|
|
1699
|
+
}
|
|
1700
|
+
}), Ln = { class: "menu-item__content" }, Pn = {
|
|
1701
|
+
key: 0,
|
|
1702
|
+
class: "menu-item__value"
|
|
1703
|
+
}, Mn = /* @__PURE__ */ F({
|
|
1704
|
+
__name: "MenuItem",
|
|
1705
|
+
props: /* @__PURE__ */ pe({
|
|
1706
|
+
label: {},
|
|
1707
|
+
icon: {},
|
|
1708
|
+
iconRight: {},
|
|
1709
|
+
arrow: { type: Boolean },
|
|
1710
|
+
color: {},
|
|
1711
|
+
to: {},
|
|
1712
|
+
href: {},
|
|
1713
|
+
target: {},
|
|
1714
|
+
disabled: { type: Boolean },
|
|
1715
|
+
toggle: { type: Boolean },
|
|
1716
|
+
isMobile: { type: Boolean }
|
|
1717
|
+
}, {
|
|
1718
|
+
modelValue: { type: Boolean },
|
|
1719
|
+
modelModifiers: {}
|
|
1720
|
+
}),
|
|
1721
|
+
emits: /* @__PURE__ */ pe(["click"], ["update:modelValue"]),
|
|
1722
|
+
setup(e, { emit: t }) {
|
|
1723
|
+
const n = e, l = t, s = ze(e, "modelValue"), o = async () => {
|
|
1724
|
+
n.toggle && (s.value = !s.value), l("click");
|
|
1725
|
+
};
|
|
1726
|
+
return (a, i) => (b(), K(D(En), {
|
|
1727
|
+
class: L(["menu-item", {
|
|
1728
|
+
"menu-item_disabled": a.disabled,
|
|
1729
|
+
"menu-item_mobile": a.isMobile
|
|
1730
|
+
}]),
|
|
1731
|
+
to: a.to,
|
|
1732
|
+
href: a.href,
|
|
1733
|
+
target: a.target,
|
|
1734
|
+
disable: a.disabled,
|
|
1735
|
+
clickable: "",
|
|
1736
|
+
onClick: o
|
|
1737
|
+
}, {
|
|
1738
|
+
default: Ie(() => [
|
|
1739
|
+
a.icon ? (b(), K(D(ge), {
|
|
1740
|
+
key: 0,
|
|
1741
|
+
name: a.icon.name,
|
|
1742
|
+
class: L(["menu-item__icon", `bg-${a.icon.color}`])
|
|
1743
|
+
}, null, 8, ["name", "class"])) : P("", !0),
|
|
1744
|
+
M("div", Ln, [
|
|
1745
|
+
M("span", {
|
|
1746
|
+
class: L(["app-menu-item__label", a.color ? `text-${a.color}` : ""])
|
|
1747
|
+
}, [
|
|
1748
|
+
ke(Y(a.label) + " ", 1),
|
|
1749
|
+
X(a.$slots, "default", {}, void 0, !0)
|
|
1750
|
+
], 2),
|
|
1751
|
+
a.$slots.value ? (b(), C("span", Pn, [
|
|
1752
|
+
X(a.$slots, "value", {}, void 0, !0)
|
|
1753
|
+
])) : P("", !0),
|
|
1754
|
+
a.toggle ? (b(), K(D(We), {
|
|
1755
|
+
key: 1,
|
|
1756
|
+
modelValue: s.value,
|
|
1757
|
+
"onUpdate:modelValue": i[0] || (i[0] = (_) => s.value = _)
|
|
1758
|
+
}, null, 8, ["modelValue"])) : P("", !0),
|
|
1759
|
+
a.iconRight ? (b(), K(D(ge), {
|
|
1760
|
+
key: 2,
|
|
1761
|
+
class: "menu-item__icon-right",
|
|
1762
|
+
name: a.iconRight.name,
|
|
1763
|
+
color: a.iconRight.color
|
|
1764
|
+
}, null, 8, ["name", "color"])) : P("", !0),
|
|
1765
|
+
a.arrow ? (b(), K(D(ge), {
|
|
1766
|
+
key: 3,
|
|
1767
|
+
class: "menu-item__icon-right menu-item__arrow",
|
|
1768
|
+
name: "arrow-right"
|
|
1769
|
+
})) : P("", !0)
|
|
1770
|
+
])
|
|
1771
|
+
]),
|
|
1772
|
+
_: 3
|
|
1773
|
+
}, 8, ["class", "to", "href", "target", "disable"]));
|
|
1774
|
+
}
|
|
1775
|
+
}), Yn = /* @__PURE__ */ x(Mn, [["__scopeId", "data-v-b9907ab7"]]), Wn = re(
|
|
1776
|
+
() => import("./AppButtonCopy-CyAsc8Wj.js")
|
|
1777
|
+
), Gn = re(
|
|
1778
|
+
() => import("./AppSelect-De8uYZsG.js")
|
|
1779
|
+
), Zn = re(
|
|
1780
|
+
() => import("./DropdownButton-GVvCXcoz.js")
|
|
1781
|
+
), Jn = re(
|
|
1782
|
+
() => import("./BottomSheet-DgjCj1MF.js")
|
|
1783
|
+
);
|
|
1784
|
+
export {
|
|
1785
|
+
Kn as A,
|
|
1786
|
+
pt as B,
|
|
1787
|
+
Oe as C,
|
|
1788
|
+
an as D,
|
|
1789
|
+
zn as E,
|
|
1790
|
+
Fn as F,
|
|
1791
|
+
jn as G,
|
|
1792
|
+
St as H,
|
|
1793
|
+
Dn as I,
|
|
1794
|
+
Tn as J,
|
|
1795
|
+
gt as K,
|
|
1796
|
+
Wn as L,
|
|
1797
|
+
Un as M,
|
|
1798
|
+
ge as N,
|
|
1799
|
+
Hn as O,
|
|
1800
|
+
Qn as P,
|
|
1801
|
+
he as Q,
|
|
1802
|
+
$t as R,
|
|
1803
|
+
A as S,
|
|
1804
|
+
Gn as T,
|
|
1805
|
+
We as U,
|
|
1806
|
+
Jn as V,
|
|
1807
|
+
Zn as W,
|
|
1808
|
+
Yn as X,
|
|
1809
|
+
Xn as Y,
|
|
1810
|
+
Vn as Z,
|
|
1811
|
+
x as _,
|
|
1812
|
+
_e as a,
|
|
1813
|
+
xe as b,
|
|
1814
|
+
ne as c,
|
|
1815
|
+
ce as d,
|
|
1816
|
+
de as e,
|
|
1817
|
+
An as f,
|
|
1818
|
+
In as g,
|
|
1819
|
+
De as h,
|
|
1820
|
+
Xt as i,
|
|
1821
|
+
xn as j,
|
|
1822
|
+
yt as k,
|
|
1823
|
+
Qe as l,
|
|
1824
|
+
ae as m,
|
|
1825
|
+
On as n,
|
|
1826
|
+
En as o,
|
|
1827
|
+
bt as p,
|
|
1828
|
+
H as q,
|
|
1829
|
+
At as r,
|
|
1830
|
+
N as s,
|
|
1831
|
+
Nn as t,
|
|
1832
|
+
ye as u,
|
|
1833
|
+
Ot as v,
|
|
1834
|
+
ht as w,
|
|
1835
|
+
kt as x,
|
|
1836
|
+
fe as y,
|
|
1837
|
+
nn as z
|
|
1838
|
+
};
|