@quidgest/ui 0.14.0 → 0.14.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ui.css +4 -0
- package/dist/ui.esm.js +693 -686
- package/dist/ui.js +4 -4
- package/dist/ui.min.js +51 -51
- package/dist/ui.scss +1053 -1049
- package/esm/components/QBadge/QBadge.d.ts +14 -41
- package/esm/components/QBadge/QBadge.d.ts.map +1 -1
- package/esm/components/QBadge/QBadge.vue.js +33 -33
- package/esm/components/QBadge/index.d.ts +0 -1
- package/esm/components/QBadge/types.d.ts +6 -7
- package/esm/components/QBadge/types.d.ts.map +1 -1
- package/esm/components/QButton/QButton.d.ts +12 -35
- package/esm/components/QButton/QButton.d.ts.map +1 -1
- package/esm/components/QButton/index.d.ts +0 -1
- package/esm/components/QButtonGroup/QButtonGroup.d.ts +9 -26
- package/esm/components/QButtonGroup/QButtonGroup.d.ts.map +1 -1
- package/esm/components/QButtonGroup/index.d.ts +0 -1
- package/esm/components/QButtonToggle/QButtonToggle.d.ts +17 -47
- package/esm/components/QButtonToggle/QButtonToggle.d.ts.map +1 -1
- package/esm/components/QButtonToggle/index.d.ts +0 -1
- package/esm/components/QCombobox/QCombobox.d.ts +373 -485
- package/esm/components/QCombobox/QCombobox.d.ts.map +1 -1
- package/esm/components/QCombobox/QCombobox.vue.js +92 -87
- package/esm/components/QCombobox/index.d.ts +0 -1
- package/esm/components/QCombobox/types.d.ts +9 -8
- package/esm/components/QCombobox/types.d.ts.map +1 -1
- package/esm/components/QCombobox/types.js +3 -1
- package/esm/components/QDialog/QDialog.d.ts +21 -109
- package/esm/components/QDialog/QDialog.d.ts.map +1 -1
- package/esm/components/QDialog/QDialog.vue.js +16 -16
- package/esm/components/QDialog/index.d.ts +0 -1
- package/esm/components/QDialog/types.d.ts +6 -8
- package/esm/components/QDialog/types.d.ts.map +1 -1
- package/esm/components/QField/QField.d.ts +18 -41
- package/esm/components/QField/QField.d.ts.map +1 -1
- package/esm/components/QField/index.d.ts +0 -1
- package/esm/components/QIcon/InlineSvg.d.ts +6 -6
- package/esm/components/QIcon/QIcon.d.ts +2 -28
- package/esm/components/QIcon/QIcon.d.ts.map +1 -1
- package/esm/components/QIcon/QIconFont.d.ts +2 -30
- package/esm/components/QIcon/QIconFont.d.ts.map +1 -1
- package/esm/components/QIcon/QIconImg.d.ts +1 -11
- package/esm/components/QIcon/QIconImg.d.ts.map +1 -1
- package/esm/components/QIcon/QIconSvg.d.ts +6 -32
- package/esm/components/QIcon/QIconSvg.d.ts.map +1 -1
- package/esm/components/QIcon/index.d.ts +0 -1
- package/esm/components/QInputGroup/QInputGroup.d.ts +12 -39
- package/esm/components/QInputGroup/QInputGroup.d.ts.map +1 -1
- package/esm/components/QInputGroup/index.d.ts +0 -1
- package/esm/components/QInputGroup/types.d.ts +0 -1
- package/esm/components/QLineLoader/QLineLoader.d.ts +2 -24
- package/esm/components/QLineLoader/QLineLoader.d.ts.map +1 -1
- package/esm/components/QLineLoader/index.d.ts +0 -1
- package/esm/components/QList/QList.d.ts +22 -72
- package/esm/components/QList/QList.d.ts.map +1 -1
- package/esm/components/QList/QListItem.d.ts +14 -39
- package/esm/components/QList/QListItem.d.ts.map +1 -1
- package/esm/components/QList/QListItem.vue.js +5 -5
- package/esm/components/QList/QListItemGroup.d.ts +9 -26
- package/esm/components/QList/QListItemGroup.d.ts.map +1 -1
- package/esm/components/QList/index.d.ts +0 -1
- package/esm/components/QList/types.d.ts +5 -7
- package/esm/components/QList/types.d.ts.map +1 -1
- package/esm/components/QOverlay/QOverlay.d.ts +23 -141
- package/esm/components/QOverlay/QOverlay.d.ts.map +1 -1
- package/esm/components/QOverlay/index.d.ts +0 -1
- package/esm/components/QOverlay/types.d.ts +0 -1
- package/esm/components/QPopover/QPopover.d.ts +19 -77
- package/esm/components/QPopover/QPopover.d.ts.map +1 -1
- package/esm/components/QPopover/index.d.ts +0 -1
- package/esm/components/QPopover/types.d.ts +0 -1
- package/esm/components/QPropertyList/QPropertyList.d.ts +28 -56
- package/esm/components/QPropertyList/QPropertyList.d.ts.map +1 -1
- package/esm/components/QPropertyList/QPropertyList.vue.js +61 -62
- package/esm/components/QPropertyList/QPropertyListGroup.d.ts +7 -44
- package/esm/components/QPropertyList/QPropertyListGroup.d.ts.map +1 -1
- package/esm/components/QPropertyList/QPropertyListGroup.vue.js +22 -26
- package/esm/components/QPropertyList/QPropertyListPanel.d.ts +11 -43
- package/esm/components/QPropertyList/QPropertyListPanel.d.ts.map +1 -1
- package/esm/components/QPropertyList/QPropertyListPanel.vue.js +14 -16
- package/esm/components/QPropertyList/QPropertyListRow.d.ts +12 -17
- package/esm/components/QPropertyList/QPropertyListRow.d.ts.map +1 -1
- package/esm/components/QPropertyList/index.d.ts +0 -1
- package/esm/components/QPropertyList/types.d.ts +70 -34
- package/esm/components/QPropertyList/types.d.ts.map +1 -1
- package/esm/components/QSelect/QSelect.d.ts +199 -147
- package/esm/components/QSelect/QSelect.d.ts.map +1 -1
- package/esm/components/QSelect/QSelect.vue.js +130 -125
- package/esm/components/QSelect/index.d.ts +0 -1
- package/esm/components/QSelect/types.d.ts +9 -8
- package/esm/components/QSelect/types.d.ts.map +1 -1
- package/esm/components/QSelect/types.js +5 -3
- package/esm/components/QSkeletonLoader/QSkeletonLoader.d.ts +2 -28
- package/esm/components/QSkeletonLoader/QSkeletonLoader.d.ts.map +1 -1
- package/esm/components/QSkeletonLoader/QSkeletonLoader.vue.js +19 -19
- package/esm/components/QSkeletonLoader/index.d.ts +0 -1
- package/esm/components/QSpinnerLoader/QSpinnerLoader.d.ts +2 -26
- package/esm/components/QSpinnerLoader/QSpinnerLoader.d.ts.map +1 -1
- package/esm/components/QSpinnerLoader/index.d.ts +0 -1
- package/esm/components/QTextField/QTextField.d.ts +100 -96
- package/esm/components/QTextField/QTextField.d.ts.map +1 -1
- package/esm/components/QTextField/index.d.ts +0 -1
- package/esm/components/QTextField/types.d.ts +0 -1
- package/esm/components/QThemeProvider/QThemeProvider.d.ts +8 -13
- package/esm/components/QThemeProvider/QThemeProvider.d.ts.map +1 -1
- package/esm/components/QThemeProvider/index.d.ts +0 -1
- package/esm/components/QTooltip/QTooltip.d.ts +23 -121
- package/esm/components/QTooltip/QTooltip.d.ts.map +1 -1
- package/esm/components/QTooltip/index.d.ts +0 -1
- package/esm/components/QTooltip/types.d.ts +0 -1
- package/esm/composables/defaults.d.ts +0 -1
- package/esm/composables/theme.d.ts +0 -1
- package/esm/framework.d.ts +0 -1
- package/esm/templates/theme.d.ts +0 -1
- package/esm/utils/setupPropsProxy.d.ts +0 -1
- package/esm/utils/theme.d.ts +0 -1
- package/package.json +31 -31
package/dist/ui.esm.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as B, computed as
|
|
1
|
+
import { defineComponent as B, computed as g, openBlock as r, createElementBlock as p, normalizeClass as V, normalizeStyle as ue, getCurrentInstance as Ne, ref as D, provide as He, inject as Ge, withModifiers as ve, createVNode as z, unref as m, createCommentVNode as x, createElementVNode as L, Fragment as K, createTextVNode as ce, toDisplayString as O, renderSlot as h, createBlock as S, resolveDynamicComponent as Be, h as Qe, withCtx as _, normalizeProps as j, guardReactiveProps as le, toRef as Fe, mergeModels as Z, useModel as ne, renderList as he, mergeProps as J, reactive as ze, watch as te, nextTick as oe, onMounted as Re, onBeforeUnmount as ut, Teleport as ct, Transition as ft, withKeys as pt, createSlots as qe, withDirectives as mt, vModelDynamic as vt } from "vue";
|
|
2
2
|
/*!
|
|
3
|
-
* Quidgest UI v0.14.
|
|
3
|
+
* Quidgest UI v0.14.1
|
|
4
4
|
* (c) 2024 Quidgest - Consultores de Gestão, S.A.
|
|
5
5
|
* Released under the MIT License.
|
|
6
6
|
*/
|
|
@@ -35,7 +35,7 @@ const Ie = {
|
|
|
35
35
|
onWarning: "#fff",
|
|
36
36
|
onDanger: "#fff",
|
|
37
37
|
onInfo: "#fff"
|
|
38
|
-
},
|
|
38
|
+
}, Ke = {
|
|
39
39
|
primary: "#009ff5",
|
|
40
40
|
primaryLight: "#ade2ff",
|
|
41
41
|
primaryDark: "#164965",
|
|
@@ -66,9 +66,9 @@ const Ie = {
|
|
|
66
66
|
onWarning: "#fff",
|
|
67
67
|
onDanger: "#fff",
|
|
68
68
|
onInfo: "#fff"
|
|
69
|
-
},
|
|
69
|
+
}, On = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
70
70
|
__proto__: null,
|
|
71
|
-
defaultDarkColorScheme:
|
|
71
|
+
defaultDarkColorScheme: Ke,
|
|
72
72
|
defaultLightColorScheme: Ie
|
|
73
73
|
}, Symbol.toStringTag, { value: "Module" })), ht = /* @__PURE__ */ B({
|
|
74
74
|
__name: "QSpinnerLoader",
|
|
@@ -77,19 +77,19 @@ const Ie = {
|
|
|
77
77
|
class: { default: void 0 }
|
|
78
78
|
},
|
|
79
79
|
setup(o) {
|
|
80
|
-
const t = o, e =
|
|
80
|
+
const t = o, e = g(() => ({
|
|
81
81
|
"font-size": t.size !== 48 ? `${t.size}px` : void 0
|
|
82
82
|
}));
|
|
83
83
|
return (n, l) => (r(), p("div", {
|
|
84
|
-
class:
|
|
85
|
-
style:
|
|
84
|
+
class: V(["q-spinner-loader", t.class]),
|
|
85
|
+
style: ue(e.value)
|
|
86
86
|
}, null, 6));
|
|
87
87
|
}
|
|
88
88
|
});
|
|
89
89
|
function Se(o) {
|
|
90
90
|
return o == null ? !0 : typeof o == "string" || Array.isArray(o) ? o.length === 0 : typeof o == "object" ? Object.keys(o).length === 0 : !1;
|
|
91
91
|
}
|
|
92
|
-
function
|
|
92
|
+
function Me(o) {
|
|
93
93
|
return o !== null && typeof o == "object" && !Array.isArray(o);
|
|
94
94
|
}
|
|
95
95
|
function Ce(o = {}, t = {}) {
|
|
@@ -98,7 +98,7 @@ function Ce(o = {}, t = {}) {
|
|
|
98
98
|
e[n] = o[n];
|
|
99
99
|
for (const n in t) {
|
|
100
100
|
const l = o[n], s = t[n];
|
|
101
|
-
if (
|
|
101
|
+
if (Me(l) && Me(s)) {
|
|
102
102
|
e[n] = Ce(
|
|
103
103
|
l,
|
|
104
104
|
s
|
|
@@ -112,53 +112,53 @@ function Ce(o = {}, t = {}) {
|
|
|
112
112
|
const Te = "q-defaults";
|
|
113
113
|
function yt() {
|
|
114
114
|
var s, i;
|
|
115
|
-
const o =
|
|
115
|
+
const o = Ne();
|
|
116
116
|
if (!o)
|
|
117
117
|
throw new Error("[Quidgest UI] useDefaults must be called from inside a setup function");
|
|
118
118
|
const t = o.type.name ?? o.type.__name;
|
|
119
119
|
if (!t) throw new Error("[Quidgest UI] Could not determine component name");
|
|
120
|
-
const e =
|
|
121
|
-
return
|
|
120
|
+
const e = We(), n = (s = e.value) == null ? void 0 : s.Global, l = (i = e.value) == null ? void 0 : i[t];
|
|
121
|
+
return g(() => Ce(n, l));
|
|
122
122
|
}
|
|
123
|
-
function
|
|
123
|
+
function je(o) {
|
|
124
124
|
if (Se(o)) return;
|
|
125
|
-
const t =
|
|
126
|
-
|
|
125
|
+
const t = We(), e = D(o), n = g(() => Se(e.value) ? t.value : Ce(t.value, e.value));
|
|
126
|
+
He(Te, n);
|
|
127
127
|
}
|
|
128
|
-
function
|
|
129
|
-
const o =
|
|
128
|
+
function We() {
|
|
129
|
+
const o = Ge(Te, void 0);
|
|
130
130
|
if (!o) throw new Error("[Quidgest UI] Could not find defaults instance");
|
|
131
131
|
return o;
|
|
132
132
|
}
|
|
133
|
-
function
|
|
133
|
+
function Xe(o) {
|
|
134
134
|
return o.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();
|
|
135
135
|
}
|
|
136
|
-
function
|
|
136
|
+
function bt(o, t) {
|
|
137
137
|
var n;
|
|
138
|
-
const e =
|
|
138
|
+
const e = Xe(t);
|
|
139
139
|
return e ? typeof ((n = o.props) == null ? void 0 : n[e]) < "u" : !1;
|
|
140
140
|
}
|
|
141
|
-
function
|
|
141
|
+
function C(o) {
|
|
142
142
|
const t = o.setup;
|
|
143
143
|
return t && (o.setup = (e, n) => {
|
|
144
144
|
const l = yt();
|
|
145
145
|
if (Se(l.value)) return t(e, n);
|
|
146
|
-
const s =
|
|
146
|
+
const s = Ne();
|
|
147
147
|
if (s === null) return t(e, n);
|
|
148
148
|
const i = new Proxy(e, {
|
|
149
149
|
get(a, d) {
|
|
150
150
|
var I;
|
|
151
|
-
const
|
|
152
|
-
return typeof d == "string" && !
|
|
151
|
+
const c = Reflect.get(a, d), w = (I = l.value) == null ? void 0 : I[d];
|
|
152
|
+
return typeof d == "string" && !bt(s.vnode, d) ? w ?? c : c;
|
|
153
153
|
}
|
|
154
154
|
});
|
|
155
155
|
return t(i, n);
|
|
156
156
|
}), o;
|
|
157
157
|
}
|
|
158
|
-
const xe =
|
|
158
|
+
const xe = C(ht), gt = ["disabled"], _t = {
|
|
159
159
|
key: 0,
|
|
160
160
|
class: "q-btn__spinner"
|
|
161
|
-
}, kt = { class: "q-btn__content" },
|
|
161
|
+
}, kt = { class: "q-btn__content" }, wt = /* @__PURE__ */ B({
|
|
162
162
|
__name: "QButton",
|
|
163
163
|
props: {
|
|
164
164
|
active: { type: Boolean },
|
|
@@ -175,11 +175,11 @@ const xe = T(ht), bt = ["disabled"], _t = {
|
|
|
175
175
|
},
|
|
176
176
|
emits: ["click"],
|
|
177
177
|
setup(o, { emit: t }) {
|
|
178
|
-
const e = o, n = t, l =
|
|
178
|
+
const e = o, n = t, l = g(() => e.disabled || e.loading);
|
|
179
179
|
function s(a) {
|
|
180
180
|
l.value || n("click", a);
|
|
181
181
|
}
|
|
182
|
-
const i =
|
|
182
|
+
const i = g(() => {
|
|
183
183
|
const a = e.size !== "regular" ? `q-btn--${e.size}` : void 0;
|
|
184
184
|
return [
|
|
185
185
|
"q-btn",
|
|
@@ -197,25 +197,25 @@ const xe = T(ht), bt = ["disabled"], _t = {
|
|
|
197
197
|
});
|
|
198
198
|
return (a, d) => (r(), p("button", {
|
|
199
199
|
type: "button",
|
|
200
|
-
class:
|
|
200
|
+
class: V(i.value),
|
|
201
201
|
disabled: l.value,
|
|
202
202
|
onClick: ve(s, ["stop", "prevent"])
|
|
203
203
|
}, [
|
|
204
204
|
a.loading ? (r(), p("div", _t, [
|
|
205
|
-
|
|
205
|
+
z(m(xe), { size: 20 })
|
|
206
206
|
])) : x("", !0),
|
|
207
207
|
L("span", kt, [
|
|
208
208
|
a.iconOnRight ? (r(), p(K, { key: 0 }, [
|
|
209
|
-
|
|
209
|
+
ce(O(e.label), 1)
|
|
210
210
|
], 64)) : x("", !0),
|
|
211
211
|
h(a.$slots, "default"),
|
|
212
212
|
a.iconOnRight ? x("", !0) : (r(), p(K, { key: 1 }, [
|
|
213
|
-
|
|
213
|
+
ce(O(e.label), 1)
|
|
214
214
|
], 64))
|
|
215
215
|
])
|
|
216
|
-
], 10,
|
|
216
|
+
], 10, gt));
|
|
217
217
|
}
|
|
218
|
-
}), re =
|
|
218
|
+
}), re = C(wt), $t = /* @__PURE__ */ B({
|
|
219
219
|
__name: "QIcon",
|
|
220
220
|
props: {
|
|
221
221
|
icon: {},
|
|
@@ -224,20 +224,20 @@ const xe = T(ht), bt = ["disabled"], _t = {
|
|
|
224
224
|
type: { default: "svg" }
|
|
225
225
|
},
|
|
226
226
|
setup(o) {
|
|
227
|
-
const t = o, e =
|
|
227
|
+
const t = o, e = g(() => {
|
|
228
228
|
switch (t.type) {
|
|
229
229
|
case "svg":
|
|
230
|
-
return tt;
|
|
231
|
-
case "font":
|
|
232
230
|
return Je;
|
|
231
|
+
case "font":
|
|
232
|
+
return Ye;
|
|
233
233
|
case "img":
|
|
234
|
-
return
|
|
234
|
+
return Ze;
|
|
235
235
|
default:
|
|
236
236
|
return;
|
|
237
237
|
}
|
|
238
238
|
});
|
|
239
239
|
return (n, l) => (r(), S(Be(e.value), {
|
|
240
|
-
class:
|
|
240
|
+
class: V(t.class),
|
|
241
241
|
icon: t.icon,
|
|
242
242
|
size: t.size
|
|
243
243
|
}, null, 8, ["class", "icon", "size"]));
|
|
@@ -252,12 +252,12 @@ const xe = T(ht), bt = ["disabled"], _t = {
|
|
|
252
252
|
variant: { default: "" }
|
|
253
253
|
},
|
|
254
254
|
setup(o) {
|
|
255
|
-
const t = o, e =
|
|
255
|
+
const t = o, e = g(() => t.variant ? `${t.library}-${t.variant}` : t.library), n = g(() => t.library && t.icon ? `${t.library}-${t.icon}` : t.icon), l = g(() => ({
|
|
256
256
|
"font-size": t.size !== void 0 ? `${t.size}px` : void 0
|
|
257
257
|
}));
|
|
258
258
|
return (s, i) => (r(), p("i", {
|
|
259
|
-
class:
|
|
260
|
-
style:
|
|
259
|
+
class: V(["q-icon", "q-icon__font", e.value, n.value, t.class]),
|
|
260
|
+
style: ue(l.value)
|
|
261
261
|
}, null, 6));
|
|
262
262
|
}
|
|
263
263
|
}), xt = ["src"], Lt = /* @__PURE__ */ B({
|
|
@@ -268,16 +268,16 @@ const xe = T(ht), bt = ["disabled"], _t = {
|
|
|
268
268
|
class: {}
|
|
269
269
|
},
|
|
270
270
|
setup(o) {
|
|
271
|
-
const t = o, e =
|
|
271
|
+
const t = o, e = g(() => ({
|
|
272
272
|
"font-size": t.size !== void 0 ? `${t.size}px` : void 0
|
|
273
273
|
}));
|
|
274
274
|
return (n, l) => (r(), p("img", {
|
|
275
275
|
src: t.icon,
|
|
276
|
-
class:
|
|
277
|
-
style:
|
|
276
|
+
class: V(["q-icon", "q-icon__img", t.class]),
|
|
277
|
+
style: ue(e.value)
|
|
278
278
|
}, null, 14, xt));
|
|
279
279
|
}
|
|
280
|
-
}),
|
|
280
|
+
}), be = {}, It = B({
|
|
281
281
|
name: "InlineSvg",
|
|
282
282
|
emits: {
|
|
283
283
|
loaded: (o) => typeof o == "object",
|
|
@@ -288,9 +288,9 @@ const xe = T(ht), bt = ["disabled"], _t = {
|
|
|
288
288
|
render() {
|
|
289
289
|
if (!this.svgElSource) return null;
|
|
290
290
|
const o = this.getSvgContent(this.svgElSource);
|
|
291
|
-
if (!o) return
|
|
291
|
+
if (!o) return Qe("div", this.$attrs);
|
|
292
292
|
const t = {};
|
|
293
|
-
return this.copySvgAttrs(t, this.svgElSource), this.copySvgAttrs(t, o), this.copyComponentAttrs(t, this.$attrs), t.innerHTML = o.innerHTML,
|
|
293
|
+
return this.copySvgAttrs(t, this.svgElSource), this.copySvgAttrs(t, o), this.copyComponentAttrs(t, this.$attrs), t.innerHTML = o.innerHTML, Qe("svg", t);
|
|
294
294
|
},
|
|
295
295
|
props: {
|
|
296
296
|
/**
|
|
@@ -358,11 +358,11 @@ const xe = T(ht), bt = ["disabled"], _t = {
|
|
|
358
358
|
*/
|
|
359
359
|
async getSource(o) {
|
|
360
360
|
try {
|
|
361
|
-
|
|
362
|
-
const t = await
|
|
361
|
+
be[o] || (be[o] = Bt(this.download(o))), this.svgElSource && be[o].getIsPending() && !this.keepDuringLoading && (this.svgElSource = null, this.$emit("unloaded"));
|
|
362
|
+
const t = await be[o];
|
|
363
363
|
this.svgElSource = t, await this.$nextTick(), this.$emit("loaded", this.$el);
|
|
364
364
|
} catch (t) {
|
|
365
|
-
this.svgElSource && (this.svgElSource = null, this.$emit("unloaded")), delete
|
|
365
|
+
this.svgElSource && (this.svgElSource = null, this.$emit("unloaded")), delete be[o], this.$emit("error", t);
|
|
366
366
|
}
|
|
367
367
|
},
|
|
368
368
|
/**
|
|
@@ -415,7 +415,7 @@ const Ct = /* @__PURE__ */ B({
|
|
|
415
415
|
},
|
|
416
416
|
emits: ["loaded", "unloaded"],
|
|
417
417
|
setup(o, { emit: t }) {
|
|
418
|
-
const e = o, n = t, l =
|
|
418
|
+
const e = o, n = t, l = g(() => ({
|
|
419
419
|
"font-size": e.size !== void 0 ? `${e.size}px` : void 0
|
|
420
420
|
}));
|
|
421
421
|
function s(a) {
|
|
@@ -425,15 +425,15 @@ const Ct = /* @__PURE__ */ B({
|
|
|
425
425
|
n("unloaded");
|
|
426
426
|
}
|
|
427
427
|
return (a, d) => (r(), S(m(It), {
|
|
428
|
-
class:
|
|
428
|
+
class: V(["q-icon", "q-icon__svg", e.class]),
|
|
429
429
|
src: e.bundle,
|
|
430
430
|
symbol: e.icon,
|
|
431
|
-
style:
|
|
431
|
+
style: ue(l.value),
|
|
432
432
|
onLoaded: s,
|
|
433
433
|
onUnloaded: i
|
|
434
434
|
}, null, 8, ["class", "src", "symbol", "style"]));
|
|
435
435
|
}
|
|
436
|
-
}), N =
|
|
436
|
+
}), N = C($t), Ye = C(qt), Ze = C(Lt), Je = C(Ct), Tt = {
|
|
437
437
|
remove: {
|
|
438
438
|
icon: "close"
|
|
439
439
|
}
|
|
@@ -448,7 +448,7 @@ function Et(o) {
|
|
|
448
448
|
return { r: e, g: n, b: l };
|
|
449
449
|
}
|
|
450
450
|
}
|
|
451
|
-
function
|
|
451
|
+
function et(o) {
|
|
452
452
|
if (Vt(o)) {
|
|
453
453
|
o.length === 4 && (o = "#" + o[1] + o[1] + o[2] + o[2] + o[3] + o[3]);
|
|
454
454
|
const t = parseInt(o.slice(1, 3), 16), e = parseInt(o.slice(3, 5), 16), n = parseInt(o.slice(5, 7), 16);
|
|
@@ -466,16 +466,16 @@ function Dt(o) {
|
|
|
466
466
|
if (l === s)
|
|
467
467
|
i = a = 0;
|
|
468
468
|
else {
|
|
469
|
-
const
|
|
470
|
-
switch (a = d > 0.5 ?
|
|
469
|
+
const c = l - s;
|
|
470
|
+
switch (a = d > 0.5 ? c / (2 - l - s) : c / (l + s), l) {
|
|
471
471
|
case t:
|
|
472
|
-
i = (e - n) /
|
|
472
|
+
i = (e - n) / c + (e < n ? 6 : 0);
|
|
473
473
|
break;
|
|
474
474
|
case e:
|
|
475
|
-
i = (n - t) /
|
|
475
|
+
i = (n - t) / c + 2;
|
|
476
476
|
break;
|
|
477
477
|
case n:
|
|
478
|
-
i = (t - e) /
|
|
478
|
+
i = (t - e) / c + 4;
|
|
479
479
|
break;
|
|
480
480
|
}
|
|
481
481
|
i /= 6;
|
|
@@ -489,46 +489,46 @@ function Dt(o) {
|
|
|
489
489
|
function At(o) {
|
|
490
490
|
return o > 50 ? "#000" : "#fff";
|
|
491
491
|
}
|
|
492
|
-
const Qt =
|
|
492
|
+
const Qt = { class: "q-badge__content" }, Ft = /* @__PURE__ */ B({
|
|
493
493
|
__name: "QBadge",
|
|
494
494
|
props: {
|
|
495
495
|
color: { default: "primary" },
|
|
496
496
|
variant: { default: "tonal" },
|
|
497
497
|
removable: { type: Boolean },
|
|
498
498
|
pill: { type: Boolean },
|
|
499
|
-
|
|
499
|
+
icons: { default: () => Tt }
|
|
500
500
|
},
|
|
501
501
|
emits: ["click:remove"],
|
|
502
502
|
setup(o, { emit: t }) {
|
|
503
|
-
const e = o, n = t, l =
|
|
503
|
+
const e = o, n = t, l = g(
|
|
504
504
|
() => ["primary", "info", "success", "warning", "danger"].includes(e.color)
|
|
505
|
-
), s =
|
|
505
|
+
), s = g(() => {
|
|
506
506
|
const d = l.value ? `q-badge--${e.color}` : void 0;
|
|
507
507
|
return ["q-badge", `q-badge--${e.variant}`, d, { "q-badge--pill": e.pill }];
|
|
508
|
-
}), i =
|
|
509
|
-
let d,
|
|
508
|
+
}), i = g(() => {
|
|
509
|
+
let d, c;
|
|
510
510
|
if (!l.value)
|
|
511
511
|
if (d = e.color, e.variant === "tonal")
|
|
512
|
-
|
|
512
|
+
c = e.color;
|
|
513
513
|
else {
|
|
514
|
-
const
|
|
515
|
-
|
|
514
|
+
const w = et(d), I = Dt(w);
|
|
515
|
+
c = At(I.l);
|
|
516
516
|
}
|
|
517
517
|
return {
|
|
518
518
|
"--q-badge-color": d,
|
|
519
|
-
"--q-badge-text-color":
|
|
519
|
+
"--q-badge-text-color": c
|
|
520
520
|
};
|
|
521
521
|
});
|
|
522
522
|
function a() {
|
|
523
523
|
n("click:remove");
|
|
524
524
|
}
|
|
525
|
-
return (d,
|
|
526
|
-
class:
|
|
525
|
+
return (d, c) => (r(), p("span", {
|
|
526
|
+
class: V(s.value),
|
|
527
527
|
role: "presentation",
|
|
528
|
-
style:
|
|
528
|
+
style: ue(i.value)
|
|
529
529
|
}, [
|
|
530
|
-
|
|
531
|
-
L("div",
|
|
530
|
+
c[0] || (c[0] = L("div", { class: "q-badge__underlay" }, null, -1)),
|
|
531
|
+
L("div", Qt, [
|
|
532
532
|
h(d.$slots, "default"),
|
|
533
533
|
e.removable ? (r(), S(m(re), {
|
|
534
534
|
key: 0,
|
|
@@ -538,14 +538,14 @@ const Qt = /* @__PURE__ */ L("div", { class: "q-badge__underlay" }, null, -1), F
|
|
|
538
538
|
onClick: a
|
|
539
539
|
}, {
|
|
540
540
|
default: _(() => [
|
|
541
|
-
|
|
541
|
+
z(m(N), j(le(e.icons.remove)), null, 16)
|
|
542
542
|
]),
|
|
543
543
|
_: 1
|
|
544
544
|
})) : x("", !0)
|
|
545
545
|
])
|
|
546
546
|
], 6));
|
|
547
547
|
}
|
|
548
|
-
}),
|
|
548
|
+
}), zt = C(Ft), Mt = /* @__PURE__ */ B({
|
|
549
549
|
__name: "QButtonGroup",
|
|
550
550
|
props: {
|
|
551
551
|
disabled: { type: Boolean },
|
|
@@ -555,15 +555,15 @@ const Qt = /* @__PURE__ */ L("div", { class: "q-badge__underlay" }, null, -1), F
|
|
|
555
555
|
},
|
|
556
556
|
setup(o) {
|
|
557
557
|
const t = o;
|
|
558
|
-
return
|
|
558
|
+
return je({
|
|
559
559
|
QButton: {
|
|
560
560
|
bStyle: "secondary",
|
|
561
|
-
disabled:
|
|
562
|
-
borderless:
|
|
561
|
+
disabled: Fe(t, "disabled"),
|
|
562
|
+
borderless: Fe(t, "borderless"),
|
|
563
563
|
elevated: !1
|
|
564
564
|
}
|
|
565
565
|
}), (e, n) => (r(), p("div", {
|
|
566
|
-
class:
|
|
566
|
+
class: V([
|
|
567
567
|
"q-btn-group",
|
|
568
568
|
{
|
|
569
569
|
"q-btn-group--elevated": t.elevated
|
|
@@ -574,7 +574,7 @@ const Qt = /* @__PURE__ */ L("div", { class: "q-badge__underlay" }, null, -1), F
|
|
|
574
574
|
h(e.$slots, "default")
|
|
575
575
|
], 2));
|
|
576
576
|
}
|
|
577
|
-
}),
|
|
577
|
+
}), tt = C(Mt), Ot = /* @__PURE__ */ B({
|
|
578
578
|
__name: "QButtonToggle",
|
|
579
579
|
props: /* @__PURE__ */ Z({
|
|
580
580
|
options: {},
|
|
@@ -589,13 +589,13 @@ const Qt = /* @__PURE__ */ L("div", { class: "q-badge__underlay" }, null, -1), F
|
|
|
589
589
|
}),
|
|
590
590
|
emits: ["update:modelValue"],
|
|
591
591
|
setup(o) {
|
|
592
|
-
const t = o, e =
|
|
592
|
+
const t = o, e = ne(o, "modelValue");
|
|
593
593
|
function n(l) {
|
|
594
594
|
e.value === l.key && !t.required ? e.value = void 0 : e.value = l.key;
|
|
595
595
|
}
|
|
596
|
-
return (l, s) => (r(), S(m(
|
|
596
|
+
return (l, s) => (r(), S(m(tt), {
|
|
597
597
|
"b-style": "secondary",
|
|
598
|
-
class:
|
|
598
|
+
class: V(t.class),
|
|
599
599
|
disabled: t.disabled,
|
|
600
600
|
borderless: t.borderless,
|
|
601
601
|
elevated: t.elevated
|
|
@@ -617,7 +617,7 @@ const Qt = /* @__PURE__ */ L("div", { class: "q-badge__underlay" }, null, -1), F
|
|
|
617
617
|
_: 3
|
|
618
618
|
}, 8, ["class", "disabled", "borderless", "elevated"]));
|
|
619
619
|
}
|
|
620
|
-
}),
|
|
620
|
+
}), Pt = C(Ot), Ut = /* @__PURE__ */ B({
|
|
621
621
|
__name: "QList",
|
|
622
622
|
props: /* @__PURE__ */ Z({
|
|
623
623
|
highlighted: { type: [String, Number, Boolean, Symbol], default: void 0 },
|
|
@@ -636,28 +636,28 @@ const Qt = /* @__PURE__ */ L("div", { class: "q-badge__underlay" }, null, -1), F
|
|
|
636
636
|
}),
|
|
637
637
|
emits: ["update:modelValue"],
|
|
638
638
|
setup(o, { expose: t }) {
|
|
639
|
-
const e = o, n =
|
|
640
|
-
(v) => e.items.some((
|
|
641
|
-
) : [{ id: "", title: "" }]), a =
|
|
639
|
+
const e = o, n = ne(o, "modelValue"), l = D(!1), s = g(() => i.value.length > 1 ? "div" : "ul"), i = g(() => e.groups.length ? e.groups.filter(
|
|
640
|
+
(v) => e.items.some(($) => $.group === v.id)
|
|
641
|
+
) : [{ id: "", title: "" }]), a = D(null);
|
|
642
642
|
function d(v) {
|
|
643
643
|
n.value = v;
|
|
644
644
|
}
|
|
645
|
-
function
|
|
645
|
+
function c() {
|
|
646
646
|
l.value = !0;
|
|
647
647
|
}
|
|
648
|
-
function
|
|
648
|
+
function w() {
|
|
649
649
|
l.value = !1;
|
|
650
650
|
}
|
|
651
651
|
function I(v) {
|
|
652
|
-
var
|
|
653
|
-
if ((
|
|
652
|
+
var b;
|
|
653
|
+
if ((b = a.value) != null && b.contains(v.relatedTarget))
|
|
654
654
|
return;
|
|
655
|
-
let
|
|
656
|
-
n.value ?
|
|
657
|
-
const
|
|
658
|
-
|
|
655
|
+
let $;
|
|
656
|
+
n.value ? $ = e.items.findIndex((G) => G[e.itemValue] === n.value) : $ = Q();
|
|
657
|
+
const f = l.value;
|
|
658
|
+
T($, f);
|
|
659
659
|
}
|
|
660
|
-
function
|
|
660
|
+
function P(v) {
|
|
661
661
|
switch (["ArrowDown", "ArrowUp", "Home", "End"].includes(v.key) && v.preventDefault(), v.key) {
|
|
662
662
|
case "ArrowDown":
|
|
663
663
|
A("next");
|
|
@@ -677,101 +677,101 @@ const Qt = /* @__PURE__ */ L("div", { class: "q-badge__underlay" }, null, -1), F
|
|
|
677
677
|
switch (v) {
|
|
678
678
|
case "next":
|
|
679
679
|
case "prev":
|
|
680
|
-
|
|
680
|
+
T(W(v));
|
|
681
681
|
break;
|
|
682
682
|
case "first":
|
|
683
|
-
|
|
683
|
+
T(Q());
|
|
684
684
|
break;
|
|
685
685
|
case "last":
|
|
686
|
-
|
|
686
|
+
T(H());
|
|
687
687
|
break;
|
|
688
688
|
}
|
|
689
689
|
}
|
|
690
|
-
function
|
|
691
|
-
var
|
|
692
|
-
(
|
|
690
|
+
function T(v, $ = !1) {
|
|
691
|
+
var b;
|
|
692
|
+
(b = y()[v]) == null || b.focus({ preventScroll: $ });
|
|
693
693
|
}
|
|
694
694
|
function y() {
|
|
695
|
-
var
|
|
696
|
-
const v = (
|
|
695
|
+
var $;
|
|
696
|
+
const v = ($ = a.value) == null ? void 0 : $.querySelectorAll("li");
|
|
697
697
|
return v ? Array.from(v) : [];
|
|
698
698
|
}
|
|
699
|
-
function
|
|
699
|
+
function E(v) {
|
|
700
700
|
return y()[v];
|
|
701
701
|
}
|
|
702
|
-
function
|
|
702
|
+
function M() {
|
|
703
703
|
return y().indexOf(document.activeElement);
|
|
704
704
|
}
|
|
705
|
-
function
|
|
706
|
-
const v = y(),
|
|
707
|
-
return
|
|
705
|
+
function Q() {
|
|
706
|
+
const v = y(), $ = v.find((f) => U(f));
|
|
707
|
+
return $ ? v.indexOf($) : -1;
|
|
708
708
|
}
|
|
709
709
|
function H() {
|
|
710
|
-
const v = y(),
|
|
711
|
-
return
|
|
710
|
+
const v = y(), $ = [...v].reverse().find((f) => U(f));
|
|
711
|
+
return $ ? v.indexOf($) : -1;
|
|
712
712
|
}
|
|
713
|
-
function
|
|
714
|
-
return
|
|
713
|
+
function se(v, $, f) {
|
|
714
|
+
return $ === "prev" && v === 0 || $ === "next" && v === f.length - 1;
|
|
715
715
|
}
|
|
716
716
|
function W(v) {
|
|
717
|
-
const
|
|
718
|
-
return
|
|
717
|
+
const $ = M();
|
|
718
|
+
return ae($, v);
|
|
719
719
|
}
|
|
720
|
-
function
|
|
721
|
-
const
|
|
722
|
-
if (
|
|
720
|
+
function ae(v, $) {
|
|
721
|
+
const f = y();
|
|
722
|
+
if (se(v, $, f))
|
|
723
723
|
return v;
|
|
724
|
-
let
|
|
725
|
-
for (; !U(
|
|
726
|
-
if (
|
|
724
|
+
let b = v + ($ === "next" ? 1 : -1);
|
|
725
|
+
for (; !U(f[b]); ) {
|
|
726
|
+
if (se(b, $, f))
|
|
727
727
|
return v;
|
|
728
|
-
|
|
728
|
+
b += $ === "next" ? 1 : -1;
|
|
729
729
|
}
|
|
730
|
-
return
|
|
730
|
+
return b;
|
|
731
731
|
}
|
|
732
732
|
function U(v) {
|
|
733
733
|
return v.tabIndex === -2;
|
|
734
734
|
}
|
|
735
735
|
function Y(v) {
|
|
736
|
-
return v ? e.items.filter((
|
|
736
|
+
return v ? e.items.filter(($) => $.group === v) : e.items;
|
|
737
737
|
}
|
|
738
738
|
return t({
|
|
739
|
-
focusItem:
|
|
740
|
-
getItem:
|
|
741
|
-
getAdjacentItemIndex:
|
|
742
|
-
getFirstFocusableItemIndex:
|
|
739
|
+
focusItem: T,
|
|
740
|
+
getItem: E,
|
|
741
|
+
getAdjacentItemIndex: ae,
|
|
742
|
+
getFirstFocusableItemIndex: Q,
|
|
743
743
|
getLastFocusableItemIndex: H
|
|
744
|
-
}), (v,
|
|
744
|
+
}), (v, $) => (r(), S(Be(s.value), {
|
|
745
745
|
ref_key: "listRef",
|
|
746
746
|
ref: a,
|
|
747
|
-
class:
|
|
747
|
+
class: V(["q-list", { "q-list--disabled": e.disabled }, e.class]),
|
|
748
748
|
role: "listbox",
|
|
749
749
|
tabindex: e.disabled ? -1 : 0,
|
|
750
750
|
onFocus: I,
|
|
751
|
-
onMousedown:
|
|
752
|
-
onMouseup:
|
|
753
|
-
onKeydown:
|
|
751
|
+
onMousedown: c,
|
|
752
|
+
onMouseup: w,
|
|
753
|
+
onKeydown: P
|
|
754
754
|
}, {
|
|
755
755
|
default: _(() => [
|
|
756
|
-
(r(!0), p(K, null, he(i.value, (
|
|
757
|
-
key:
|
|
758
|
-
id:
|
|
759
|
-
title: i.value.length === 1 ? void 0 :
|
|
756
|
+
(r(!0), p(K, null, he(i.value, (f) => (r(), S(m(nt), {
|
|
757
|
+
key: f.id,
|
|
758
|
+
id: f.id,
|
|
759
|
+
title: i.value.length === 1 ? void 0 : f.title
|
|
760
760
|
}, {
|
|
761
761
|
default: _(() => [
|
|
762
|
-
(r(!0), p(K, null, he(Y(
|
|
763
|
-
key:
|
|
764
|
-
value:
|
|
765
|
-
label:
|
|
766
|
-
description:
|
|
767
|
-
icon:
|
|
768
|
-
disabled: e.disabled ||
|
|
769
|
-
highlighted: e.highlighted ===
|
|
770
|
-
selected: v.selectable && n.value ===
|
|
762
|
+
(r(!0), p(K, null, he(Y(f.id), (b) => (r(), S(m(ot), {
|
|
763
|
+
key: b[e.itemValue],
|
|
764
|
+
value: b[e.itemValue],
|
|
765
|
+
label: b[e.itemLabel],
|
|
766
|
+
description: b.description,
|
|
767
|
+
icon: b.icon,
|
|
768
|
+
disabled: e.disabled || f.disabled || b.disabled,
|
|
769
|
+
highlighted: e.highlighted === b[e.itemValue],
|
|
770
|
+
selected: v.selectable && n.value === b[e.itemValue],
|
|
771
771
|
onSelect: d
|
|
772
772
|
}, {
|
|
773
773
|
default: _(() => [
|
|
774
|
-
h(v.$slots, "item", { item:
|
|
774
|
+
h(v.$slots, "item", { item: b })
|
|
775
775
|
]),
|
|
776
776
|
_: 2
|
|
777
777
|
}, 1032, ["value", "label", "description", "icon", "disabled", "highlighted", "selected"]))), 128))
|
|
@@ -782,7 +782,7 @@ const Qt = /* @__PURE__ */ L("div", { class: "q-badge__underlay" }, null, -1), F
|
|
|
782
782
|
_: 3
|
|
783
783
|
}, 40, ["class", "tabindex"]));
|
|
784
784
|
}
|
|
785
|
-
}),
|
|
785
|
+
}), Nt = {
|
|
786
786
|
check: {
|
|
787
787
|
icon: "check"
|
|
788
788
|
},
|
|
@@ -790,14 +790,14 @@ const Qt = /* @__PURE__ */ L("div", { class: "q-badge__underlay" }, null, -1), F
|
|
|
790
790
|
icon: "information-outline"
|
|
791
791
|
}
|
|
792
792
|
};
|
|
793
|
-
let
|
|
793
|
+
let Ht = 0;
|
|
794
794
|
function fe(o) {
|
|
795
|
-
return o || `uid-${++
|
|
795
|
+
return o || `uid-${++Ht}`;
|
|
796
796
|
}
|
|
797
|
-
const
|
|
797
|
+
const Gt = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], Rt = { class: "q-list-item__container" }, Kt = { class: "q-list-item__content" }, jt = {
|
|
798
798
|
key: 0,
|
|
799
799
|
class: "q-list-item__description"
|
|
800
|
-
},
|
|
800
|
+
}, Wt = { class: "q-list-item__check-container" }, Xt = /* @__PURE__ */ B({
|
|
801
801
|
__name: "QListItem",
|
|
802
802
|
props: {
|
|
803
803
|
value: { type: [String, Number, Boolean, Symbol] },
|
|
@@ -807,7 +807,7 @@ const Rt = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], Kt = {
|
|
|
807
807
|
highlighted: { type: Boolean },
|
|
808
808
|
disabled: { type: Boolean },
|
|
809
809
|
description: { default: void 0 },
|
|
810
|
-
|
|
810
|
+
icons: { default: () => Nt }
|
|
811
811
|
},
|
|
812
812
|
emits: ["select"],
|
|
813
813
|
setup(o, { emit: t }) {
|
|
@@ -823,7 +823,7 @@ const Rt = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], Kt = {
|
|
|
823
823
|
"data-key": e.value,
|
|
824
824
|
role: "option",
|
|
825
825
|
tabindex: e.disabled ? void 0 : -2,
|
|
826
|
-
class:
|
|
826
|
+
class: V([
|
|
827
827
|
"q-list-item",
|
|
828
828
|
{
|
|
829
829
|
"q-list-item--disabled": e.disabled,
|
|
@@ -836,24 +836,24 @@ const Rt = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], Kt = {
|
|
|
836
836
|
onKeydown: i,
|
|
837
837
|
onClick: ve(s, ["stop", "prevent"])
|
|
838
838
|
}, [
|
|
839
|
-
L("div",
|
|
840
|
-
L("div",
|
|
839
|
+
L("div", Rt, [
|
|
840
|
+
L("div", Kt, [
|
|
841
841
|
h(a.$slots, "default", {}, () => [
|
|
842
|
-
e.icon ? (r(), S(m(N), j(
|
|
843
|
-
|
|
842
|
+
e.icon ? (r(), S(m(N), j(J({ key: 0 }, e.icon)), null, 16)) : x("", !0),
|
|
843
|
+
ce(" " + O(e.label), 1)
|
|
844
844
|
])
|
|
845
845
|
]),
|
|
846
|
-
e.description ? (r(), p("div",
|
|
847
|
-
|
|
848
|
-
L("span", null,
|
|
846
|
+
e.description ? (r(), p("div", jt, [
|
|
847
|
+
z(m(N), j(le(e.icons.description)), null, 16),
|
|
848
|
+
L("span", null, O(e.description), 1)
|
|
849
849
|
])) : x("", !0)
|
|
850
850
|
]),
|
|
851
|
-
L("div",
|
|
852
|
-
e.selected ? (r(), S(m(N),
|
|
851
|
+
L("div", Wt, [
|
|
852
|
+
e.selected ? (r(), S(m(N), J({ key: 0 }, e.icons.check, { class: "q-list-item__check" }), null, 16)) : x("", !0)
|
|
853
853
|
])
|
|
854
|
-
], 42,
|
|
854
|
+
], 42, Gt));
|
|
855
855
|
}
|
|
856
|
-
}),
|
|
856
|
+
}), Yt = ["data-key", "aria-labelledby"], Zt = ["id"], Jt = /* @__PURE__ */ B({
|
|
857
857
|
__name: "QListItemGroup",
|
|
858
858
|
props: {
|
|
859
859
|
id: {},
|
|
@@ -872,69 +872,69 @@ const Rt = ["id", "data-key", "tabindex", "aria-label", "aria-selected"], Kt = {
|
|
|
872
872
|
id: m(e),
|
|
873
873
|
class: "q-list-item-group__title",
|
|
874
874
|
role: "presentation"
|
|
875
|
-
},
|
|
875
|
+
}, O(t.title), 9, Zt)) : x("", !0),
|
|
876
876
|
h(n.$slots, "default")
|
|
877
|
-
], 8,
|
|
877
|
+
], 8, Yt));
|
|
878
878
|
}
|
|
879
|
-
}), Ve =
|
|
880
|
-
function
|
|
881
|
-
const l = (n == null ? void 0 : n.offset) ?? 0, s = (n == null ? void 0 : n.placement) ?? "bottom", i = o.getBoundingClientRect(), a = t.getBoundingClientRect(), d = e == null ? void 0 : e.getBoundingClientRect(),
|
|
879
|
+
}), Ve = C(Ut), ot = C(Xt), nt = C(Jt), we = 8;
|
|
880
|
+
function eo(o, t, e, n) {
|
|
881
|
+
const l = (n == null ? void 0 : n.offset) ?? 0, s = (n == null ? void 0 : n.placement) ?? "bottom", i = o.getBoundingClientRect(), a = t.getBoundingClientRect(), d = e == null ? void 0 : e.getBoundingClientRect(), c = to(i, a, s, l), w = so(i, a, c), I = no(w, c, l), P = oo(I, a, c);
|
|
882
882
|
let A;
|
|
883
883
|
if (n != null && n.arrow) {
|
|
884
884
|
if (!d)
|
|
885
885
|
throw new Error("[Quidgest UI] The arrow element must exist to compute its position");
|
|
886
|
-
A =
|
|
886
|
+
A = lo(P, i, a, d, c);
|
|
887
887
|
}
|
|
888
|
-
return { overlayCoords:
|
|
888
|
+
return { overlayCoords: P, arrowCoords: A, placement: c };
|
|
889
889
|
}
|
|
890
|
-
function
|
|
891
|
-
const l =
|
|
892
|
-
if (
|
|
890
|
+
function to(o, t, e, n) {
|
|
891
|
+
const l = Oe(o, t, e, n);
|
|
892
|
+
if (Pe(l)) {
|
|
893
893
|
const s = _e(e), a = {
|
|
894
894
|
top: "bottom",
|
|
895
895
|
bottom: "top",
|
|
896
896
|
left: "right",
|
|
897
897
|
right: "left"
|
|
898
|
-
}[s], d =
|
|
898
|
+
}[s], d = Oe(
|
|
899
899
|
o,
|
|
900
900
|
t,
|
|
901
901
|
a,
|
|
902
902
|
n
|
|
903
903
|
);
|
|
904
|
-
if (
|
|
904
|
+
if (Pe(d))
|
|
905
905
|
return e;
|
|
906
|
-
const
|
|
907
|
-
return
|
|
906
|
+
const c = ro(e);
|
|
907
|
+
return c ? `${a}-${c}` : a;
|
|
908
908
|
}
|
|
909
909
|
return e;
|
|
910
910
|
}
|
|
911
|
-
function
|
|
912
|
-
const n =
|
|
913
|
-
return n === "x" ? s.x = l(o.x,
|
|
911
|
+
function oo(o, t, e) {
|
|
912
|
+
const n = $e(e), l = (i, a, d) => Math.min(Math.max(i, a), d), s = { ...o };
|
|
913
|
+
return n === "x" ? s.x = l(o.x, we, window.innerWidth - t.width - we) : s.y = l(o.y, we, window.innerHeight - t.height - we), s;
|
|
914
914
|
}
|
|
915
|
-
function
|
|
915
|
+
function no(o, t, e) {
|
|
916
916
|
const n = _e(t);
|
|
917
917
|
return {
|
|
918
918
|
x: o.x + (n === "left" ? -e : n === "right" ? e : 0),
|
|
919
919
|
y: o.y + (n === "top" ? -e : n === "bottom" ? e : 0)
|
|
920
920
|
};
|
|
921
921
|
}
|
|
922
|
-
function
|
|
923
|
-
if (
|
|
924
|
-
const i = t.top + t.height / 2, a = o.y + e.height / 2, d = a - i,
|
|
925
|
-
if (
|
|
922
|
+
function lo(o, t, e, n, l) {
|
|
923
|
+
if ($e(l) === "y") {
|
|
924
|
+
const i = t.top + t.height / 2, a = o.y + e.height / 2, d = a - i, c = e.height / 2 - d - n.height / 2 + 2;
|
|
925
|
+
if (c > 0 && c < e.height - n.height)
|
|
926
926
|
return {
|
|
927
|
-
y:
|
|
927
|
+
y: c
|
|
928
928
|
};
|
|
929
929
|
} else {
|
|
930
|
-
const i = t.left + t.width / 2, a = o.x + e.width / 2, d = a - i,
|
|
931
|
-
if (
|
|
930
|
+
const i = t.left + t.width / 2, a = o.x + e.width / 2, d = a - i, c = e.width / 2 - d - n.width / 2 + 2;
|
|
931
|
+
if (c > 0 && c < e.width - n.width)
|
|
932
932
|
return {
|
|
933
|
-
x:
|
|
933
|
+
x: c
|
|
934
934
|
};
|
|
935
935
|
}
|
|
936
936
|
}
|
|
937
|
-
function
|
|
937
|
+
function so(o, t, e) {
|
|
938
938
|
const [n, l] = e.split("-"), s = o.x + o.width / 2 - t.width / 2, i = o.y + o.height / 2 - t.height / 2;
|
|
939
939
|
let a;
|
|
940
940
|
switch (n) {
|
|
@@ -955,20 +955,20 @@ function ao(o, t, e) {
|
|
|
955
955
|
}
|
|
956
956
|
if (!l)
|
|
957
957
|
return a;
|
|
958
|
-
const
|
|
958
|
+
const c = $e(e) === "y" ? "height" : "width", w = $e(e), I = o[c] / 2 - t[c] / 2;
|
|
959
959
|
switch (l) {
|
|
960
960
|
case "start":
|
|
961
|
-
a[
|
|
961
|
+
a[w] -= I;
|
|
962
962
|
break;
|
|
963
963
|
case "end":
|
|
964
|
-
a[
|
|
964
|
+
a[w] += I;
|
|
965
965
|
break;
|
|
966
966
|
default:
|
|
967
967
|
throw new Error(`[Quidgest UI] Invalid alignment value: ${l}`);
|
|
968
968
|
}
|
|
969
969
|
return a;
|
|
970
970
|
}
|
|
971
|
-
function
|
|
971
|
+
function Oe(o, t, e, n) {
|
|
972
972
|
const l = _e(e);
|
|
973
973
|
let s = 0;
|
|
974
974
|
switch (l) {
|
|
@@ -989,31 +989,31 @@ function Ue(o, t, e, n) {
|
|
|
989
989
|
}
|
|
990
990
|
return s;
|
|
991
991
|
}
|
|
992
|
-
function
|
|
992
|
+
function ao(o) {
|
|
993
993
|
return o === "x" ? "y" : "x";
|
|
994
994
|
}
|
|
995
|
-
function
|
|
995
|
+
function io(o) {
|
|
996
996
|
const t = _e(o);
|
|
997
997
|
return ["left", "right"].includes(t) ? "x" : "y";
|
|
998
998
|
}
|
|
999
|
-
function
|
|
1000
|
-
return io(
|
|
999
|
+
function $e(o) {
|
|
1000
|
+
return ao(io(o));
|
|
1001
1001
|
}
|
|
1002
1002
|
function _e(o) {
|
|
1003
1003
|
const [t] = o.split("-");
|
|
1004
1004
|
return t;
|
|
1005
1005
|
}
|
|
1006
|
-
function
|
|
1006
|
+
function ro(o) {
|
|
1007
1007
|
const [, t] = o.split("-");
|
|
1008
1008
|
return t;
|
|
1009
1009
|
}
|
|
1010
|
-
function
|
|
1010
|
+
function Pe(o) {
|
|
1011
1011
|
return o < 0;
|
|
1012
1012
|
}
|
|
1013
1013
|
function uo(o) {
|
|
1014
1014
|
return typeof o == "string" ? document.querySelector(o) : o;
|
|
1015
1015
|
}
|
|
1016
|
-
const
|
|
1016
|
+
const co = ["role"], fo = /* @__PURE__ */ B({
|
|
1017
1017
|
inheritAttrs: !1,
|
|
1018
1018
|
__name: "QOverlay",
|
|
1019
1019
|
props: /* @__PURE__ */ Z({
|
|
@@ -1041,7 +1041,7 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1041
1041
|
}),
|
|
1042
1042
|
emits: /* @__PURE__ */ Z(["enter", "leave"], ["update:modelValue"]),
|
|
1043
1043
|
setup(o, { emit: t }) {
|
|
1044
|
-
const e = o, n = t, l =
|
|
1044
|
+
const e = o, n = t, l = ne(o, "modelValue"), s = g(() => [
|
|
1045
1045
|
"q-overlay",
|
|
1046
1046
|
`q-overlay--${_e(a.placement)}`,
|
|
1047
1047
|
{
|
|
@@ -1049,19 +1049,19 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1049
1049
|
"q-overlay--inverted": e.appearance === "inverted"
|
|
1050
1050
|
},
|
|
1051
1051
|
e.class
|
|
1052
|
-
]), i =
|
|
1052
|
+
]), i = g(() => (l.value || a.animating) && !e.nonModal), a = ze({
|
|
1053
1053
|
animating: !1,
|
|
1054
1054
|
top: 0,
|
|
1055
1055
|
left: 0,
|
|
1056
1056
|
width: 0,
|
|
1057
1057
|
placement: e.placement
|
|
1058
|
-
}), d =
|
|
1058
|
+
}), d = ze({
|
|
1059
1059
|
top: void 0,
|
|
1060
1060
|
left: void 0,
|
|
1061
1061
|
hidden: !0
|
|
1062
|
-
}),
|
|
1063
|
-
|
|
1064
|
-
const
|
|
1062
|
+
}), c = g(() => a.top !== 0 && a.left !== 0);
|
|
1063
|
+
te(l, () => a.animating = !0);
|
|
1064
|
+
const w = g(() => {
|
|
1065
1065
|
if (e.anchor === void 0) return;
|
|
1066
1066
|
const k = U(), pe = e.width === "anchor", X = pe ? k == null ? void 0 : k.getBoundingClientRect().width : void 0;
|
|
1067
1067
|
return {
|
|
@@ -1069,15 +1069,15 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1069
1069
|
left: `${a.left}px`,
|
|
1070
1070
|
width: X !== void 0 ? `${X}px` : void 0
|
|
1071
1071
|
};
|
|
1072
|
-
}), I =
|
|
1072
|
+
}), I = g(() => {
|
|
1073
1073
|
if (e.arrow)
|
|
1074
1074
|
return {
|
|
1075
1075
|
top: d.top !== void 0 ? `${d.top}px` : void 0,
|
|
1076
1076
|
left: d.left !== void 0 ? `${d.left}px` : void 0,
|
|
1077
1077
|
opacity: d.hidden ? 0 : 1
|
|
1078
1078
|
};
|
|
1079
|
-
}),
|
|
1080
|
-
function
|
|
1079
|
+
}), P = D(null), A = D(null);
|
|
1080
|
+
function T() {
|
|
1081
1081
|
const k = U();
|
|
1082
1082
|
if (!k || !A.value)
|
|
1083
1083
|
return;
|
|
@@ -1086,26 +1086,26 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1086
1086
|
width: e.width,
|
|
1087
1087
|
offset: e.offset,
|
|
1088
1088
|
arrow: e.arrow
|
|
1089
|
-
}, X =
|
|
1089
|
+
}, X = eo(
|
|
1090
1090
|
k,
|
|
1091
1091
|
A.value,
|
|
1092
|
-
(
|
|
1092
|
+
(P == null ? void 0 : P.value) ?? void 0,
|
|
1093
1093
|
pe
|
|
1094
1094
|
);
|
|
1095
1095
|
a.left = X.overlayCoords.x, a.top = X.overlayCoords.y, a.placement = X.placement, d.hidden = X.arrowCoords === void 0, X.arrowCoords && (d.top = X.arrowCoords.y, d.left = X.arrowCoords.x);
|
|
1096
1096
|
}
|
|
1097
|
-
|
|
1097
|
+
te(
|
|
1098
1098
|
() => e.placement,
|
|
1099
|
-
() =>
|
|
1099
|
+
() => oe(T)
|
|
1100
1100
|
);
|
|
1101
1101
|
let y;
|
|
1102
|
-
function
|
|
1103
|
-
|
|
1102
|
+
function E() {
|
|
1103
|
+
Q(0);
|
|
1104
1104
|
}
|
|
1105
|
-
function
|
|
1106
|
-
|
|
1105
|
+
function M() {
|
|
1106
|
+
Q(e.delay);
|
|
1107
1107
|
}
|
|
1108
|
-
function
|
|
1108
|
+
function Q(k) {
|
|
1109
1109
|
y || (y = window.setTimeout(() => {
|
|
1110
1110
|
l.value = !0;
|
|
1111
1111
|
}, k));
|
|
@@ -1116,12 +1116,12 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1116
1116
|
k == null || k.focus();
|
|
1117
1117
|
}
|
|
1118
1118
|
}
|
|
1119
|
-
|
|
1120
|
-
function
|
|
1119
|
+
te(c, () => oe(se));
|
|
1120
|
+
function se() {
|
|
1121
1121
|
n("enter");
|
|
1122
1122
|
}
|
|
1123
1123
|
let W;
|
|
1124
|
-
function
|
|
1124
|
+
function ae() {
|
|
1125
1125
|
window.clearTimeout(W), W = window.setTimeout(() => a.animating = !1, 200), n("leave");
|
|
1126
1126
|
}
|
|
1127
1127
|
function U() {
|
|
@@ -1131,88 +1131,88 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1131
1131
|
function v() {
|
|
1132
1132
|
const k = U();
|
|
1133
1133
|
if (k)
|
|
1134
|
-
switch (Y = new MutationObserver(
|
|
1134
|
+
switch (Y = new MutationObserver(T), Y.observe(k, {
|
|
1135
1135
|
attributes: !1,
|
|
1136
1136
|
childList: !0,
|
|
1137
1137
|
characterData: !0,
|
|
1138
1138
|
subtree: !0
|
|
1139
1139
|
}), e.trigger) {
|
|
1140
1140
|
case "click":
|
|
1141
|
-
k.addEventListener("click",
|
|
1141
|
+
k.addEventListener("click", E);
|
|
1142
1142
|
break;
|
|
1143
1143
|
case "hover":
|
|
1144
|
-
k.addEventListener("mouseenter",
|
|
1144
|
+
k.addEventListener("mouseenter", M), k.addEventListener("mouseleave", H), k.addEventListener("focusin", E), k.addEventListener("focusout", H);
|
|
1145
1145
|
break;
|
|
1146
1146
|
}
|
|
1147
1147
|
}
|
|
1148
|
-
function
|
|
1148
|
+
function $() {
|
|
1149
1149
|
const k = U();
|
|
1150
1150
|
if (k)
|
|
1151
1151
|
switch (Y == null || Y.disconnect(), e.trigger) {
|
|
1152
1152
|
case "click":
|
|
1153
|
-
k.removeEventListener("click",
|
|
1153
|
+
k.removeEventListener("click", E);
|
|
1154
1154
|
break;
|
|
1155
1155
|
case "hover":
|
|
1156
|
-
k.removeEventListener("mouseenter",
|
|
1156
|
+
k.removeEventListener("mouseenter", M), k.removeEventListener("mouseleave", H), k.removeEventListener("focusin", E), k.removeEventListener("focusout", H);
|
|
1157
1157
|
break;
|
|
1158
1158
|
}
|
|
1159
1159
|
}
|
|
1160
|
-
function
|
|
1161
|
-
window.addEventListener("resize",
|
|
1160
|
+
function f() {
|
|
1161
|
+
window.addEventListener("resize", T), e.scrollLock || window.addEventListener("scroll", T);
|
|
1162
1162
|
}
|
|
1163
|
-
function
|
|
1164
|
-
window.removeEventListener("resize",
|
|
1163
|
+
function b() {
|
|
1164
|
+
window.removeEventListener("resize", T), e.scrollLock || window.removeEventListener("scroll", T);
|
|
1165
1165
|
}
|
|
1166
1166
|
let G;
|
|
1167
|
-
function
|
|
1168
|
-
U() ? (
|
|
1167
|
+
function ie() {
|
|
1168
|
+
U() ? (T(), G = window.setTimeout(ie, 100)) : H();
|
|
1169
1169
|
}
|
|
1170
|
-
function
|
|
1171
|
-
|
|
1170
|
+
function ee() {
|
|
1171
|
+
f(), e.spy ? ie() : T(), e.scrollLock && document.body.classList.add("no-scroll"), (e.anchor === void 0 || e.trigger === "click") && oe(() => {
|
|
1172
1172
|
var k;
|
|
1173
1173
|
return (k = A.value) == null ? void 0 : k.focus();
|
|
1174
1174
|
});
|
|
1175
1175
|
}
|
|
1176
1176
|
function de() {
|
|
1177
|
-
|
|
1177
|
+
b(), e.spy && (clearTimeout(G), G = void 0), e.scrollLock && document.body.classList.remove("no-scroll"), a.top = 0, a.left = 0;
|
|
1178
1178
|
}
|
|
1179
1179
|
function ke() {
|
|
1180
1180
|
e.persistent || H();
|
|
1181
1181
|
}
|
|
1182
|
-
return
|
|
1183
|
-
|
|
1184
|
-
}),
|
|
1185
|
-
|
|
1186
|
-
}),
|
|
1182
|
+
return Re(() => {
|
|
1183
|
+
oe(v);
|
|
1184
|
+
}), ut(() => {
|
|
1185
|
+
$(), de();
|
|
1186
|
+
}), te(
|
|
1187
1187
|
l,
|
|
1188
1188
|
(k) => {
|
|
1189
|
-
|
|
1189
|
+
oe(() => k ? ee() : de());
|
|
1190
1190
|
},
|
|
1191
1191
|
{ immediate: !0 }
|
|
1192
|
-
), (k, pe) => (r(), S(
|
|
1192
|
+
), (k, pe) => (r(), S(ct, {
|
|
1193
1193
|
disabled: !l.value && !a.animating || e.inline,
|
|
1194
1194
|
to: e.attach
|
|
1195
1195
|
}, [
|
|
1196
1196
|
i.value ? (r(), p("div", {
|
|
1197
1197
|
key: 0,
|
|
1198
|
-
class:
|
|
1198
|
+
class: V([
|
|
1199
1199
|
e.backdropClass,
|
|
1200
1200
|
"q-overlay__underlay",
|
|
1201
1201
|
{ "q-overlay__underlay--blur": e.backdropBlur }
|
|
1202
1202
|
])
|
|
1203
1203
|
}, null, 2)) : x("", !0),
|
|
1204
|
-
|
|
1204
|
+
z(ft, {
|
|
1205
1205
|
name: e.transition,
|
|
1206
1206
|
appear: "",
|
|
1207
|
-
onLeave:
|
|
1207
|
+
onLeave: ae
|
|
1208
1208
|
}, {
|
|
1209
1209
|
default: _(() => [
|
|
1210
1210
|
l.value ? (r(), p("div", {
|
|
1211
1211
|
key: 0,
|
|
1212
|
-
class:
|
|
1213
|
-
style:
|
|
1212
|
+
class: V(s.value),
|
|
1213
|
+
style: ue(w.value)
|
|
1214
1214
|
}, [
|
|
1215
|
-
L("div",
|
|
1215
|
+
L("div", J({
|
|
1216
1216
|
class: "q-overlay__content",
|
|
1217
1217
|
ref_key: "overlayRef",
|
|
1218
1218
|
ref: A,
|
|
@@ -1225,32 +1225,32 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1225
1225
|
e.arrow ? (r(), p("div", {
|
|
1226
1226
|
key: 0,
|
|
1227
1227
|
ref_key: "arrowRef",
|
|
1228
|
-
ref:
|
|
1228
|
+
ref: P,
|
|
1229
1229
|
role: "presentation",
|
|
1230
1230
|
class: "q-overlay__arrow",
|
|
1231
|
-
style:
|
|
1231
|
+
style: ue(I.value)
|
|
1232
1232
|
}, null, 4)) : x("", !0),
|
|
1233
1233
|
h(k.$slots, "default")
|
|
1234
|
-
], 16,
|
|
1234
|
+
], 16, co)
|
|
1235
1235
|
], 6)) : x("", !0)
|
|
1236
1236
|
]),
|
|
1237
1237
|
_: 3
|
|
1238
1238
|
}, 8, ["name"])
|
|
1239
1239
|
], 8, ["disabled", "to"]));
|
|
1240
1240
|
}
|
|
1241
|
-
}), ye =
|
|
1241
|
+
}), ye = C(fo), po = ["id"], mo = {
|
|
1242
1242
|
key: 0,
|
|
1243
1243
|
class: "q-field__label"
|
|
1244
|
-
},
|
|
1244
|
+
}, vo = ["for"], ho = {
|
|
1245
1245
|
key: 0,
|
|
1246
1246
|
class: "q-field__prepend"
|
|
1247
|
-
},
|
|
1247
|
+
}, yo = {
|
|
1248
1248
|
key: 1,
|
|
1249
1249
|
class: "q-field__append"
|
|
1250
1250
|
}, bo = {
|
|
1251
1251
|
key: 1,
|
|
1252
1252
|
class: "q-field__extras"
|
|
1253
|
-
},
|
|
1253
|
+
}, go = /* @__PURE__ */ B({
|
|
1254
1254
|
inheritAttrs: !1,
|
|
1255
1255
|
__name: "QField",
|
|
1256
1256
|
props: {
|
|
@@ -1264,12 +1264,12 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1264
1264
|
class: { default: void 0 }
|
|
1265
1265
|
},
|
|
1266
1266
|
setup(o, { expose: t }) {
|
|
1267
|
-
const e = o, n = fe(e.id), l =
|
|
1267
|
+
const e = o, n = fe(e.id), l = D(null), s = g(() => e.required && !e.readonly && !e.disabled);
|
|
1268
1268
|
return t({
|
|
1269
1269
|
fieldRef: l
|
|
1270
1270
|
}), (i, a) => (r(), p("div", {
|
|
1271
1271
|
id: m(n),
|
|
1272
|
-
class:
|
|
1272
|
+
class: V([
|
|
1273
1273
|
"q-field",
|
|
1274
1274
|
`q-field--${e.size}`,
|
|
1275
1275
|
{
|
|
@@ -1280,24 +1280,24 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1280
1280
|
e.class
|
|
1281
1281
|
])
|
|
1282
1282
|
}, [
|
|
1283
|
-
e.label ? (r(), p("div",
|
|
1283
|
+
e.label ? (r(), p("div", mo, [
|
|
1284
1284
|
h(i.$slots, "label.prepend"),
|
|
1285
1285
|
L("label", {
|
|
1286
1286
|
for: e.for
|
|
1287
|
-
},
|
|
1287
|
+
}, O(e.label), 9, vo),
|
|
1288
1288
|
h(i.$slots, "label.append")
|
|
1289
1289
|
])) : x("", !0),
|
|
1290
1290
|
h(i.$slots, "control", {}, () => [
|
|
1291
|
-
L("div",
|
|
1291
|
+
L("div", J({
|
|
1292
1292
|
class: "q-field__control",
|
|
1293
1293
|
ref_key: "fieldRef",
|
|
1294
1294
|
ref: l
|
|
1295
1295
|
}, i.$attrs), [
|
|
1296
|
-
i.$slots.prepend ? (r(), p("div",
|
|
1296
|
+
i.$slots.prepend ? (r(), p("div", ho, [
|
|
1297
1297
|
h(i.$slots, "prepend")
|
|
1298
1298
|
])) : x("", !0),
|
|
1299
1299
|
h(i.$slots, "default"),
|
|
1300
|
-
i.$slots.append ? (r(), p("div",
|
|
1300
|
+
i.$slots.append ? (r(), p("div", yo, [
|
|
1301
1301
|
h(i.$slots, "append")
|
|
1302
1302
|
])) : x("", !0)
|
|
1303
1303
|
], 16)
|
|
@@ -1305,9 +1305,9 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1305
1305
|
i.$slots.extras ? (r(), p("div", bo, [
|
|
1306
1306
|
h(i.$slots, "extras")
|
|
1307
1307
|
])) : x("", !0)
|
|
1308
|
-
], 10,
|
|
1308
|
+
], 10, po));
|
|
1309
1309
|
}
|
|
1310
|
-
}), Le =
|
|
1310
|
+
}), Le = C(go), _o = ["id", "type", "role", "required", "placeholder", "readonly", "disabled", "maxlength"], ko = /* @__PURE__ */ B({
|
|
1311
1311
|
inheritAttrs: !1,
|
|
1312
1312
|
__name: "QTextField",
|
|
1313
1313
|
props: /* @__PURE__ */ Z({
|
|
@@ -1328,19 +1328,19 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1328
1328
|
}),
|
|
1329
1329
|
emits: ["update:modelValue"],
|
|
1330
1330
|
setup(o, { expose: t }) {
|
|
1331
|
-
const e = o, n =
|
|
1331
|
+
const e = o, n = ne(o, "modelValue"), l = fe(e.id), s = D(null), i = D(null), a = g(
|
|
1332
1332
|
() => e.readonly || e.disabled ? "" : e.placeholder
|
|
1333
1333
|
);
|
|
1334
1334
|
return t({
|
|
1335
|
-
fieldRef:
|
|
1335
|
+
fieldRef: g(() => {
|
|
1336
1336
|
var d;
|
|
1337
1337
|
return (d = s.value) == null ? void 0 : d.fieldRef;
|
|
1338
1338
|
}),
|
|
1339
1339
|
inputRef: i
|
|
1340
|
-
}), (d,
|
|
1340
|
+
}), (d, c) => (r(), S(m(Le), {
|
|
1341
1341
|
ref_key: "fieldRef",
|
|
1342
1342
|
ref: s,
|
|
1343
|
-
class:
|
|
1343
|
+
class: V(["q-text-field", e.class]),
|
|
1344
1344
|
for: m(l),
|
|
1345
1345
|
label: e.label,
|
|
1346
1346
|
size: e.size,
|
|
@@ -1355,8 +1355,8 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1355
1355
|
h(d.$slots, "label.append")
|
|
1356
1356
|
]),
|
|
1357
1357
|
default: _(() => [
|
|
1358
|
-
mt(L("input",
|
|
1359
|
-
"onUpdate:modelValue":
|
|
1358
|
+
mt(L("input", J({
|
|
1359
|
+
"onUpdate:modelValue": c[0] || (c[0] = (w) => n.value = w),
|
|
1360
1360
|
ref_key: "inputRef",
|
|
1361
1361
|
ref: i,
|
|
1362
1362
|
id: m(l),
|
|
@@ -1368,7 +1368,7 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1368
1368
|
readonly: e.readonly,
|
|
1369
1369
|
disabled: e.disabled,
|
|
1370
1370
|
maxlength: e.maxLength
|
|
1371
|
-
}, d.$attrs), null, 16,
|
|
1371
|
+
}, d.$attrs), null, 16, _o), [
|
|
1372
1372
|
[vt, n.value]
|
|
1373
1373
|
])
|
|
1374
1374
|
]),
|
|
@@ -1397,22 +1397,25 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1397
1397
|
} : void 0
|
|
1398
1398
|
]), 1032, ["class", "for", "label", "size", "readonly", "disabled", "required"]));
|
|
1399
1399
|
}
|
|
1400
|
-
}),
|
|
1401
|
-
noData: "No data available"
|
|
1402
|
-
|
|
1400
|
+
}), lt = C(ko), wo = {
|
|
1401
|
+
noData: "No data available",
|
|
1402
|
+
clearValue: "Clear value",
|
|
1403
|
+
showOptions: "Show options"
|
|
1404
|
+
}, $o = {
|
|
1403
1405
|
chevron: {
|
|
1404
1406
|
icon: "chevron-down"
|
|
1405
1407
|
},
|
|
1406
1408
|
clear: {
|
|
1407
1409
|
icon: "close"
|
|
1408
1410
|
}
|
|
1409
|
-
},
|
|
1411
|
+
}, qo = ["data-key"], xo = {
|
|
1410
1412
|
key: 0,
|
|
1411
1413
|
class: "q-select__loader"
|
|
1412
|
-
},
|
|
1414
|
+
}, Lo = {
|
|
1413
1415
|
key: 2,
|
|
1414
1416
|
class: "q-select__loader"
|
|
1415
|
-
},
|
|
1417
|
+
}, Io = /* @__PURE__ */ B({
|
|
1418
|
+
inheritAttrs: !1,
|
|
1416
1419
|
__name: "QCombobox",
|
|
1417
1420
|
props: /* @__PURE__ */ Z({
|
|
1418
1421
|
id: { default: void 0 },
|
|
@@ -1432,7 +1435,8 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1432
1435
|
emptyValue: { type: [String, Number, Boolean, Symbol], default: void 0 },
|
|
1433
1436
|
size: { default: void 0 },
|
|
1434
1437
|
class: { default: void 0 },
|
|
1435
|
-
|
|
1438
|
+
icons: { default: () => $o },
|
|
1439
|
+
texts: { default: () => wo }
|
|
1436
1440
|
}, {
|
|
1437
1441
|
modelValue: {
|
|
1438
1442
|
type: [String, Number, Boolean, Symbol]
|
|
@@ -1445,108 +1449,108 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1445
1449
|
}),
|
|
1446
1450
|
emits: /* @__PURE__ */ Z(["before-show", "before-hide", "show", "hide"], ["update:modelValue", "update:open", "update:search"]),
|
|
1447
1451
|
setup(o, { expose: t, emit: e }) {
|
|
1448
|
-
const n = o, l = e, s =
|
|
1449
|
-
|
|
1450
|
-
const A =
|
|
1451
|
-
var
|
|
1452
|
-
return n.filterMode === "manual" || !H.value ? n.items : (
|
|
1452
|
+
const n = o, l = e, s = ne(o, "modelValue"), i = ne(o, "open"), a = ne(o, "search"), d = D(void 0), c = D(null), w = D(null), I = D(null), P = D(null);
|
|
1453
|
+
Re(W);
|
|
1454
|
+
const A = g(() => n.clearable && !n.readonly && !n.disabled), T = g(() => {
|
|
1455
|
+
var u;
|
|
1456
|
+
return n.filterMode === "manual" || !H.value ? n.items : (u = n.items) == null ? void 0 : u.filter(
|
|
1453
1457
|
(q) => q[n.itemLabel].toLowerCase().startsWith(a.value.toLowerCase())
|
|
1454
1458
|
);
|
|
1455
|
-
}), y =
|
|
1456
|
-
var
|
|
1457
|
-
return (
|
|
1458
|
-
}),
|
|
1459
|
-
const
|
|
1460
|
-
if (
|
|
1461
|
-
return
|
|
1462
|
-
}),
|
|
1459
|
+
}), y = g(() => {
|
|
1460
|
+
var u;
|
|
1461
|
+
return (u = n.items) == null ? void 0 : u.find((q) => q[n.itemValue] === s.value);
|
|
1462
|
+
}), E = g(() => y.value === void 0), M = g(() => {
|
|
1463
|
+
const u = d.value;
|
|
1464
|
+
if (u !== void 0 && T.value[u])
|
|
1465
|
+
return T.value[u];
|
|
1466
|
+
}), Q = g(() => {
|
|
1463
1467
|
var q;
|
|
1464
1468
|
if (d.value === void 0)
|
|
1465
1469
|
return;
|
|
1466
|
-
const
|
|
1467
|
-
return
|
|
1468
|
-
}), H =
|
|
1469
|
-
var
|
|
1470
|
-
return a.value.length > 0 && a.value !== ((
|
|
1470
|
+
const u = (q = w.value) == null ? void 0 : q.getItem(d.value);
|
|
1471
|
+
return u == null ? void 0 : u.id;
|
|
1472
|
+
}), H = g(() => {
|
|
1473
|
+
var u;
|
|
1474
|
+
return a.value.length > 0 && a.value !== ((u = y.value) == null ? void 0 : u[n.itemLabel]);
|
|
1471
1475
|
});
|
|
1472
|
-
function
|
|
1473
|
-
s.value =
|
|
1476
|
+
function se(u) {
|
|
1477
|
+
s.value = u, U();
|
|
1474
1478
|
}
|
|
1475
1479
|
function W() {
|
|
1476
1480
|
var q;
|
|
1477
|
-
const
|
|
1478
|
-
a.value !==
|
|
1481
|
+
const u = ((q = y.value) == null ? void 0 : q[n.itemLabel]) || "";
|
|
1482
|
+
a.value !== u && (a.value = u);
|
|
1479
1483
|
}
|
|
1480
|
-
function
|
|
1484
|
+
function ae() {
|
|
1481
1485
|
i.value || n.readonly || n.disabled || (l("before-show"), i.value = !0, de());
|
|
1482
1486
|
}
|
|
1483
1487
|
function U() {
|
|
1484
1488
|
i.value && (l("before-hide"), i.value = !1, d.value = void 0);
|
|
1485
1489
|
}
|
|
1486
1490
|
function Y() {
|
|
1487
|
-
i.value ? U() :
|
|
1491
|
+
i.value ? U() : $();
|
|
1488
1492
|
}
|
|
1489
1493
|
function v() {
|
|
1490
1494
|
A.value && (s.value = n.emptyValue, d.value = void 0, de());
|
|
1491
1495
|
}
|
|
1492
|
-
function
|
|
1493
|
-
if (
|
|
1494
|
-
const
|
|
1495
|
-
|
|
1496
|
+
function $() {
|
|
1497
|
+
if (ae(), y.value !== void 0) {
|
|
1498
|
+
const u = T.value.indexOf(y.value);
|
|
1499
|
+
u !== -1 && oe(() => X(u));
|
|
1496
1500
|
}
|
|
1497
1501
|
}
|
|
1498
|
-
function u
|
|
1499
|
-
var q,
|
|
1500
|
-
if (!(!
|
|
1501
|
-
if (["ArrowDown", "ArrowUp", "Home", "End"].includes(
|
|
1502
|
+
function f(u) {
|
|
1503
|
+
var q, F;
|
|
1504
|
+
if (!(!u.key || n.readonly || n.disabled))
|
|
1505
|
+
if (["ArrowDown", "ArrowUp", "Home", "End"].includes(u.key) && (u.preventDefault(), u.stopPropagation()), u.key === "Escape")
|
|
1502
1506
|
W(), i.value && U();
|
|
1503
|
-
else if (["ArrowDown", "ArrowUp"].includes(
|
|
1504
|
-
i.value ?
|
|
1507
|
+
else if (["ArrowDown", "ArrowUp"].includes(u.key))
|
|
1508
|
+
i.value ? oe(() => {
|
|
1505
1509
|
if (d.value === void 0)
|
|
1506
|
-
|
|
1510
|
+
b();
|
|
1507
1511
|
else {
|
|
1508
|
-
const R =
|
|
1509
|
-
|
|
1512
|
+
const R = u.key === "ArrowDown" ? "next" : "prev";
|
|
1513
|
+
ie(d.value, R);
|
|
1510
1514
|
}
|
|
1511
|
-
}) : (
|
|
1512
|
-
|
|
1515
|
+
}) : (ae(), oe(() => {
|
|
1516
|
+
u.key === "ArrowDown" ? b() : G();
|
|
1513
1517
|
}));
|
|
1514
|
-
else if (
|
|
1515
|
-
if (
|
|
1516
|
-
|
|
1517
|
-
} else
|
|
1518
|
-
}
|
|
1519
|
-
function
|
|
1520
|
-
var
|
|
1521
|
-
if (
|
|
1522
|
-
d.value = (q =
|
|
1518
|
+
else if (u.key === "Enter") {
|
|
1519
|
+
if (M.value === void 0) return;
|
|
1520
|
+
se(M.value[n.itemValue]);
|
|
1521
|
+
} else u.key === "Home" ? d.value = (q = w.value) == null ? void 0 : q.getFirstFocusableItemIndex() : u.key === "End" ? d.value = (F = w.value) == null ? void 0 : F.getLastFocusableItemIndex() : (/^[a-z]$/i.test(u.key) || u.key === "Backspace") && ae();
|
|
1522
|
+
}
|
|
1523
|
+
function b() {
|
|
1524
|
+
var u, q;
|
|
1525
|
+
if (E.value)
|
|
1526
|
+
d.value = (q = w.value) == null ? void 0 : q.getFirstFocusableItemIndex();
|
|
1523
1527
|
else {
|
|
1524
|
-
const
|
|
1528
|
+
const F = T.value.findIndex(
|
|
1525
1529
|
(R) => R[n.itemValue] === s.value
|
|
1526
1530
|
);
|
|
1527
|
-
|
|
1531
|
+
F === -1 ? d.value = (u = w.value) == null ? void 0 : u.getFirstFocusableItemIndex() : d.value = F;
|
|
1528
1532
|
}
|
|
1529
1533
|
}
|
|
1530
1534
|
function G() {
|
|
1531
|
-
var
|
|
1532
|
-
d.value = (
|
|
1535
|
+
var u;
|
|
1536
|
+
d.value = (u = w.value) == null ? void 0 : u.getLastFocusableItemIndex();
|
|
1533
1537
|
}
|
|
1534
|
-
function
|
|
1535
|
-
var
|
|
1536
|
-
d.value = (
|
|
1538
|
+
function ie(u, q) {
|
|
1539
|
+
var F;
|
|
1540
|
+
d.value = (F = w.value) == null ? void 0 : F.getAdjacentItemIndex(u, q);
|
|
1537
1541
|
}
|
|
1538
|
-
function
|
|
1539
|
-
var me,
|
|
1540
|
-
const q = ((me = I == null ? void 0 : I.value) == null ? void 0 : me.$el) ===
|
|
1541
|
-
if (q || R ||
|
|
1542
|
-
|
|
1542
|
+
function ee(u) {
|
|
1543
|
+
var me, Ee, De, Ae;
|
|
1544
|
+
const q = ((me = I == null ? void 0 : I.value) == null ? void 0 : me.$el) === u.relatedTarget, F = (De = (Ee = c == null ? void 0 : c.value) == null ? void 0 : Ee.$el) == null ? void 0 : De.contains(u.relatedTarget), R = (Ae = P == null ? void 0 : P.value) == null ? void 0 : Ae.contains(u.relatedTarget);
|
|
1545
|
+
if (q || R || F) {
|
|
1546
|
+
u.preventDefault(), u.stopPropagation();
|
|
1543
1547
|
return;
|
|
1544
1548
|
}
|
|
1545
1549
|
U(), A.value && !a.value && (s.value = n.emptyValue), W();
|
|
1546
1550
|
}
|
|
1547
1551
|
function de() {
|
|
1548
|
-
var
|
|
1549
|
-
(q = (
|
|
1552
|
+
var u, q;
|
|
1553
|
+
(q = (u = c.value) == null ? void 0 : u.inputRef) == null || q.focus();
|
|
1550
1554
|
}
|
|
1551
1555
|
function ke() {
|
|
1552
1556
|
de();
|
|
@@ -1557,45 +1561,45 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1557
1561
|
function pe() {
|
|
1558
1562
|
l("hide");
|
|
1559
1563
|
}
|
|
1560
|
-
function X(
|
|
1561
|
-
var
|
|
1562
|
-
const q = (
|
|
1563
|
-
|
|
1564
|
+
function X(u) {
|
|
1565
|
+
var F;
|
|
1566
|
+
const q = (F = w.value) == null ? void 0 : F.getItem(u);
|
|
1567
|
+
w.value && (w.value.$el.scrollTop = q == null ? void 0 : q.offsetTop);
|
|
1564
1568
|
}
|
|
1565
|
-
return
|
|
1569
|
+
return te(s, W), te(
|
|
1566
1570
|
() => n.items,
|
|
1567
|
-
(
|
|
1568
|
-
if (!
|
|
1569
|
-
const
|
|
1570
|
-
a.value === (
|
|
1571
|
+
(u, q) => {
|
|
1572
|
+
if (!E.value) {
|
|
1573
|
+
const F = q.find((R) => R[n.itemValue] === s.value);
|
|
1574
|
+
a.value === (F == null ? void 0 : F[n.itemLabel]) && W();
|
|
1571
1575
|
}
|
|
1572
1576
|
},
|
|
1573
1577
|
{ deep: !0 }
|
|
1574
|
-
),
|
|
1575
|
-
|
|
1576
|
-
}),
|
|
1577
|
-
|
|
1578
|
-
}),
|
|
1578
|
+
), te(d, (u) => {
|
|
1579
|
+
u !== void 0 && X(u);
|
|
1580
|
+
}), te(a, (u) => {
|
|
1581
|
+
u && i.value && n.selectionMode === "automatic" && oe(b);
|
|
1582
|
+
}), te(
|
|
1579
1583
|
() => n.loading,
|
|
1580
|
-
(
|
|
1581
|
-
!
|
|
1584
|
+
(u) => {
|
|
1585
|
+
!u && i.value && oe(b);
|
|
1582
1586
|
}
|
|
1583
1587
|
), t({
|
|
1584
|
-
triggerEl:
|
|
1585
|
-
}), (
|
|
1586
|
-
var
|
|
1588
|
+
triggerEl: c
|
|
1589
|
+
}), (u, q) => {
|
|
1590
|
+
var F;
|
|
1587
1591
|
return r(), p(K, null, [
|
|
1588
|
-
|
|
1592
|
+
z(m(lt), J({
|
|
1589
1593
|
modelValue: a.value,
|
|
1590
1594
|
"onUpdate:modelValue": q[0] || (q[0] = (R) => a.value = R),
|
|
1591
1595
|
id: n.id,
|
|
1592
1596
|
label: n.label,
|
|
1593
1597
|
required: n.required,
|
|
1594
1598
|
ref_key: "triggerEl",
|
|
1595
|
-
ref:
|
|
1599
|
+
ref: c,
|
|
1596
1600
|
role: "combobox",
|
|
1597
1601
|
placeholder: n.placeholder,
|
|
1598
|
-
class:
|
|
1602
|
+
class: [
|
|
1599
1603
|
"q-combobox",
|
|
1600
1604
|
{
|
|
1601
1605
|
"q-combobox--readonly": n.readonly,
|
|
@@ -1603,7 +1607,7 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1603
1607
|
"q-combobox--expanded": i.value
|
|
1604
1608
|
},
|
|
1605
1609
|
n.class
|
|
1606
|
-
]
|
|
1610
|
+
],
|
|
1607
1611
|
readonly: n.readonly,
|
|
1608
1612
|
disabled: n.disabled,
|
|
1609
1613
|
"data-loading": n.loading,
|
|
@@ -1611,38 +1615,41 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1611
1615
|
"aria-expanded": i.value,
|
|
1612
1616
|
"aria-haspopup": "listbox",
|
|
1613
1617
|
"aria-autocomplete": "list",
|
|
1614
|
-
"aria-activedescendant":
|
|
1615
|
-
size: n.size
|
|
1616
|
-
|
|
1617
|
-
|
|
1618
|
-
|
|
1619
|
-
|
|
1618
|
+
"aria-activedescendant": Q.value,
|
|
1619
|
+
size: n.size
|
|
1620
|
+
}, u.$attrs, {
|
|
1621
|
+
onClick: $,
|
|
1622
|
+
onFocusout: ee,
|
|
1623
|
+
onKeydown: ve(f, ["stop"])
|
|
1624
|
+
}), qe({
|
|
1620
1625
|
"label.prepend": _(() => [
|
|
1621
|
-
h(
|
|
1626
|
+
h(u.$slots, "label.prepend")
|
|
1622
1627
|
]),
|
|
1623
1628
|
"label.append": _(() => [
|
|
1624
|
-
h(
|
|
1629
|
+
h(u.$slots, "label.append")
|
|
1625
1630
|
]),
|
|
1626
1631
|
append: _(() => [
|
|
1627
|
-
h(
|
|
1632
|
+
h(u.$slots, "append"),
|
|
1628
1633
|
A.value && a.value ? (r(), S(m(re), {
|
|
1629
1634
|
key: 0,
|
|
1630
1635
|
class: "q-combobox__clear",
|
|
1636
|
+
"aria-label": n.texts.clearValue,
|
|
1631
1637
|
"b-style": "plain",
|
|
1632
1638
|
borderless: "",
|
|
1633
1639
|
tabindex: "-1",
|
|
1634
1640
|
onClick: v
|
|
1635
1641
|
}, {
|
|
1636
1642
|
default: _(() => [
|
|
1637
|
-
|
|
1643
|
+
z(m(N), j(le(n.icons.clear)), null, 16)
|
|
1638
1644
|
]),
|
|
1639
1645
|
_: 1
|
|
1640
|
-
})) : x("", !0),
|
|
1646
|
+
}, 8, ["aria-label"])) : x("", !0),
|
|
1641
1647
|
n.readonly ? x("", !0) : (r(), S(m(re), {
|
|
1642
1648
|
key: 1,
|
|
1643
1649
|
ref_key: "toggleRef",
|
|
1644
1650
|
ref: I,
|
|
1645
1651
|
class: "q-combobox__chevron",
|
|
1652
|
+
"aria-label": n.texts.showOptions,
|
|
1646
1653
|
"b-style": "plain",
|
|
1647
1654
|
borderless: "",
|
|
1648
1655
|
tabindex: "-1",
|
|
@@ -1650,29 +1657,29 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1650
1657
|
onMousedown: ve(Y, ["stop", "prevent"])
|
|
1651
1658
|
}, {
|
|
1652
1659
|
default: _(() => [
|
|
1653
|
-
|
|
1660
|
+
z(m(N), j(le(n.icons.chevron)), null, 16)
|
|
1654
1661
|
]),
|
|
1655
1662
|
_: 1
|
|
1656
|
-
}, 8, ["disabled"]))
|
|
1663
|
+
}, 8, ["aria-label", "disabled"]))
|
|
1657
1664
|
]),
|
|
1658
1665
|
_: 2
|
|
1659
1666
|
}, [
|
|
1660
|
-
|
|
1667
|
+
u.$slots.prepend ? {
|
|
1661
1668
|
name: "prepend",
|
|
1662
1669
|
fn: _(() => [
|
|
1663
|
-
h(
|
|
1670
|
+
h(u.$slots, "prepend")
|
|
1664
1671
|
]),
|
|
1665
1672
|
key: "0"
|
|
1666
1673
|
} : void 0,
|
|
1667
|
-
|
|
1674
|
+
u.$slots.extras ? {
|
|
1668
1675
|
name: "extras",
|
|
1669
1676
|
fn: _(() => [
|
|
1670
|
-
h(
|
|
1677
|
+
h(u.$slots, "extras")
|
|
1671
1678
|
]),
|
|
1672
1679
|
key: "1"
|
|
1673
1680
|
} : void 0
|
|
1674
|
-
]),
|
|
1675
|
-
|
|
1681
|
+
]), 1040, ["modelValue", "id", "label", "required", "placeholder", "class", "readonly", "disabled", "data-loading", "aria-expanded", "aria-activedescendant", "size"]),
|
|
1682
|
+
z(m(ye), {
|
|
1676
1683
|
modelValue: i.value,
|
|
1677
1684
|
"onUpdate:modelValue": q[2] || (q[2] = (R) => i.value = R),
|
|
1678
1685
|
spy: "",
|
|
@@ -1681,7 +1688,7 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1681
1688
|
placement: "bottom-start",
|
|
1682
1689
|
width: "anchor",
|
|
1683
1690
|
offset: 4,
|
|
1684
|
-
anchor: (
|
|
1691
|
+
anchor: (F = c.value) == null ? void 0 : F.$el,
|
|
1685
1692
|
onEnter: k,
|
|
1686
1693
|
onLeave: pe
|
|
1687
1694
|
}, {
|
|
@@ -1690,40 +1697,40 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1690
1697
|
return [
|
|
1691
1698
|
L("div", {
|
|
1692
1699
|
ref_key: "contentRef",
|
|
1693
|
-
ref:
|
|
1700
|
+
ref: P,
|
|
1694
1701
|
class: "q-select__body",
|
|
1695
1702
|
"data-testid": "combobox-dropdown",
|
|
1696
1703
|
"data-key": n.id,
|
|
1697
|
-
onFocusout:
|
|
1704
|
+
onFocusout: ee
|
|
1698
1705
|
}, [
|
|
1699
|
-
h(
|
|
1700
|
-
n.loading ? (r(), p("div",
|
|
1701
|
-
|
|
1702
|
-
])) :
|
|
1706
|
+
h(u.$slots, "body.prepend"),
|
|
1707
|
+
n.loading ? (r(), p("div", xo, [
|
|
1708
|
+
z(m(xe), { size: 24 })
|
|
1709
|
+
])) : T.value.length ? (r(), S(m(Ve), {
|
|
1703
1710
|
key: 1,
|
|
1704
1711
|
ref_key: "listRef",
|
|
1705
|
-
ref:
|
|
1712
|
+
ref: w,
|
|
1706
1713
|
class: "q-select__items",
|
|
1707
1714
|
selectable: "",
|
|
1708
1715
|
modelValue: s.value,
|
|
1709
1716
|
"onUpdate:modelValue": [
|
|
1710
1717
|
q[1] || (q[1] = (me) => s.value = me),
|
|
1711
|
-
|
|
1718
|
+
se
|
|
1712
1719
|
],
|
|
1713
|
-
highlighted: (R =
|
|
1714
|
-
items:
|
|
1715
|
-
groups:
|
|
1720
|
+
highlighted: (R = M.value) == null ? void 0 : R[n.itemValue],
|
|
1721
|
+
items: T.value,
|
|
1722
|
+
groups: u.groups,
|
|
1716
1723
|
"item-label": n.itemLabel,
|
|
1717
1724
|
"item-value": n.itemValue,
|
|
1718
1725
|
onMouseup: ke
|
|
1719
1726
|
}, {
|
|
1720
1727
|
item: _(({ item: me }) => [
|
|
1721
|
-
h(
|
|
1728
|
+
h(u.$slots, "item", { item: me })
|
|
1722
1729
|
]),
|
|
1723
1730
|
_: 3
|
|
1724
|
-
}, 8, ["modelValue", "highlighted", "items", "groups", "item-label", "item-value"])) : (r(), p("div",
|
|
1725
|
-
h(
|
|
1726
|
-
], 40,
|
|
1731
|
+
}, 8, ["modelValue", "highlighted", "items", "groups", "item-label", "item-value"])) : (r(), p("div", Lo, O(n.texts.noData), 1)),
|
|
1732
|
+
h(u.$slots, "body.append")
|
|
1733
|
+
], 40, qo)
|
|
1727
1734
|
];
|
|
1728
1735
|
}),
|
|
1729
1736
|
_: 3
|
|
@@ -1731,7 +1738,7 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1731
1738
|
], 64);
|
|
1732
1739
|
};
|
|
1733
1740
|
}
|
|
1734
|
-
}),
|
|
1741
|
+
}), So = C(Io), Bo = [
|
|
1735
1742
|
{
|
|
1736
1743
|
id: "button",
|
|
1737
1744
|
icon: {
|
|
@@ -1742,37 +1749,37 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1742
1749
|
label: "Ok"
|
|
1743
1750
|
}
|
|
1744
1751
|
}
|
|
1745
|
-
],
|
|
1752
|
+
], Co = {
|
|
1746
1753
|
icon: "check-circle-outline"
|
|
1747
|
-
},
|
|
1754
|
+
}, To = {
|
|
1748
1755
|
close: {
|
|
1749
1756
|
icon: "close"
|
|
1750
1757
|
}
|
|
1751
|
-
},
|
|
1758
|
+
}, Vo = { class: "q-dialog__header" }, Eo = { class: "q-dialog__header-title" }, Do = { class: "q-dialog__body" }, Ao = {
|
|
1752
1759
|
key: 0,
|
|
1753
1760
|
class: "q-dialog__body-icon"
|
|
1754
|
-
},
|
|
1761
|
+
}, Qo = { class: "q-dialog__body-text" }, Fo = ["innerHTML"], zo = { key: 1 }, Mo = { class: "q-dialog__body-actions" }, Oo = /* @__PURE__ */ B({
|
|
1755
1762
|
__name: "QDialog",
|
|
1756
1763
|
props: /* @__PURE__ */ Z({
|
|
1757
1764
|
text: { default: "" },
|
|
1758
1765
|
attach: { default: "body" },
|
|
1759
1766
|
inline: { type: Boolean },
|
|
1760
1767
|
backdropBlur: { type: Boolean, default: !0 },
|
|
1761
|
-
buttons: { default: () =>
|
|
1768
|
+
buttons: { default: () => Bo },
|
|
1762
1769
|
dismissible: { type: Boolean },
|
|
1763
1770
|
html: { type: Boolean, default: !0 },
|
|
1764
|
-
icon: { default: () =>
|
|
1771
|
+
icon: { default: () => Co },
|
|
1765
1772
|
id: { default: void 0 },
|
|
1766
1773
|
title: { default: "" },
|
|
1767
1774
|
class: { default: void 0 },
|
|
1768
|
-
|
|
1775
|
+
icons: { default: () => To }
|
|
1769
1776
|
}, {
|
|
1770
1777
|
modelValue: { type: Boolean },
|
|
1771
1778
|
modelModifiers: {}
|
|
1772
1779
|
}),
|
|
1773
1780
|
emits: ["update:modelValue"],
|
|
1774
1781
|
setup(o) {
|
|
1775
|
-
const t = o, e =
|
|
1782
|
+
const t = o, e = ne(o, "modelValue"), n = fe(t.id), l = g(() => ["q-dialog", t.class]);
|
|
1776
1783
|
function s() {
|
|
1777
1784
|
e.value = !1;
|
|
1778
1785
|
}
|
|
@@ -1792,47 +1799,47 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1792
1799
|
}, {
|
|
1793
1800
|
default: _(() => [
|
|
1794
1801
|
L("div", {
|
|
1795
|
-
class:
|
|
1802
|
+
class: V(l.value)
|
|
1796
1803
|
}, [
|
|
1797
|
-
L("div",
|
|
1798
|
-
L("span",
|
|
1804
|
+
L("div", Vo, [
|
|
1805
|
+
L("span", Eo, O(t.title), 1),
|
|
1799
1806
|
t.dismissible ? (r(), S(m(re), {
|
|
1800
1807
|
key: 0,
|
|
1801
1808
|
"b-style": "tertiary",
|
|
1802
1809
|
onClick: s
|
|
1803
1810
|
}, {
|
|
1804
1811
|
default: _(() => [
|
|
1805
|
-
|
|
1812
|
+
z(m(N), j(le(t.icons.close)), null, 16)
|
|
1806
1813
|
]),
|
|
1807
1814
|
_: 1
|
|
1808
1815
|
})) : x("", !0)
|
|
1809
1816
|
]),
|
|
1810
1817
|
h(a.$slots, "body.content", {}, () => [
|
|
1811
|
-
L("div",
|
|
1818
|
+
L("div", Do, [
|
|
1812
1819
|
h(a.$slots, "body.icon", {}, () => [
|
|
1813
|
-
t.icon ? (r(), p("span",
|
|
1814
|
-
|
|
1820
|
+
t.icon ? (r(), p("span", Ao, [
|
|
1821
|
+
z(m(N), j(le(t.icon)), null, 16)
|
|
1815
1822
|
])) : x("", !0)
|
|
1816
1823
|
]),
|
|
1817
|
-
L("div",
|
|
1824
|
+
L("div", Qo, [
|
|
1818
1825
|
t.html ? (r(), p("span", {
|
|
1819
1826
|
key: 0,
|
|
1820
1827
|
innerHTML: t.text
|
|
1821
|
-
}, null, 8,
|
|
1828
|
+
}, null, 8, Fo)) : (r(), p("span", zo, O(t.text), 1))
|
|
1822
1829
|
]),
|
|
1823
1830
|
h(a.$slots, "body.append")
|
|
1824
1831
|
])
|
|
1825
1832
|
]),
|
|
1826
|
-
L("div",
|
|
1827
|
-
(r(!0), p(K, null, he(t.buttons, (
|
|
1828
|
-
key:
|
|
1829
|
-
onClick: () => i(
|
|
1833
|
+
L("div", Mo, [
|
|
1834
|
+
(r(!0), p(K, null, he(t.buttons, (c) => (r(), S(m(re), J({ ref_for: !0 }, c.props, {
|
|
1835
|
+
key: c.id,
|
|
1836
|
+
onClick: () => i(c)
|
|
1830
1837
|
}), {
|
|
1831
1838
|
default: _(() => [
|
|
1832
|
-
|
|
1839
|
+
c.icon ? (r(), S(m(N), J({
|
|
1833
1840
|
key: 0,
|
|
1834
1841
|
ref_for: !0
|
|
1835
|
-
},
|
|
1842
|
+
}, c.icon), null, 16)) : x("", !0)
|
|
1836
1843
|
]),
|
|
1837
1844
|
_: 2
|
|
1838
1845
|
}, 1040, ["onClick"]))), 128))
|
|
@@ -1842,13 +1849,13 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1842
1849
|
_: 3
|
|
1843
1850
|
}, 8, ["model-value", "id", "inline", "attach", "backdrop-blur"]));
|
|
1844
1851
|
}
|
|
1845
|
-
}),
|
|
1852
|
+
}), Po = C(Oo), Uo = {
|
|
1846
1853
|
key: 0,
|
|
1847
1854
|
class: "q-input-group__prepend"
|
|
1848
|
-
},
|
|
1855
|
+
}, No = { key: 0 }, Ho = {
|
|
1849
1856
|
key: 1,
|
|
1850
1857
|
class: "q-input-group__append"
|
|
1851
|
-
},
|
|
1858
|
+
}, Go = { key: 0 }, Ro = /* @__PURE__ */ B({
|
|
1852
1859
|
__name: "QInputGroup",
|
|
1853
1860
|
props: {
|
|
1854
1861
|
id: { default: void 0 },
|
|
@@ -1861,28 +1868,28 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1861
1868
|
},
|
|
1862
1869
|
setup(o) {
|
|
1863
1870
|
const t = o;
|
|
1864
|
-
return
|
|
1871
|
+
return je({
|
|
1865
1872
|
QField: {
|
|
1866
1873
|
size: "block"
|
|
1867
1874
|
}
|
|
1868
1875
|
}), (e, n) => (r(), S(m(Le), {
|
|
1869
1876
|
id: t.id,
|
|
1870
|
-
class:
|
|
1877
|
+
class: V(["q-input-group", t.class]),
|
|
1871
1878
|
label: t.label,
|
|
1872
1879
|
required: t.required,
|
|
1873
1880
|
size: t.size
|
|
1874
1881
|
}, qe({
|
|
1875
1882
|
default: _(() => [
|
|
1876
|
-
e.$slots.prepend || t.prependIcon ? (r(), p("div",
|
|
1877
|
-
t.prependIcon ? (r(), p("span",
|
|
1878
|
-
|
|
1883
|
+
e.$slots.prepend || t.prependIcon ? (r(), p("div", Uo, [
|
|
1884
|
+
t.prependIcon ? (r(), p("span", No, [
|
|
1885
|
+
z(m(N), j(le(t.prependIcon)), null, 16)
|
|
1879
1886
|
])) : x("", !0),
|
|
1880
1887
|
h(e.$slots, "prepend")
|
|
1881
1888
|
])) : x("", !0),
|
|
1882
1889
|
h(e.$slots, "default"),
|
|
1883
|
-
e.$slots.append || t.appendIcon ? (r(), p("div",
|
|
1884
|
-
t.appendIcon ? (r(), p("span",
|
|
1885
|
-
|
|
1890
|
+
e.$slots.append || t.appendIcon ? (r(), p("div", Ho, [
|
|
1891
|
+
t.appendIcon ? (r(), p("span", Go, [
|
|
1892
|
+
z(m(N), j(le(t.appendIcon)), null, 16)
|
|
1886
1893
|
])) : x("", !0),
|
|
1887
1894
|
h(e.$slots, "append")
|
|
1888
1895
|
])) : x("", !0)
|
|
@@ -1898,7 +1905,7 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1898
1905
|
} : void 0
|
|
1899
1906
|
]), 1032, ["id", "class", "label", "required", "size"]));
|
|
1900
1907
|
}
|
|
1901
|
-
}),
|
|
1908
|
+
}), Ko = C(Ro), jo = /* @__PURE__ */ B({
|
|
1902
1909
|
__name: "QLineLoader",
|
|
1903
1910
|
props: {
|
|
1904
1911
|
class: { default: void 0 }
|
|
@@ -1906,16 +1913,16 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1906
1913
|
setup(o) {
|
|
1907
1914
|
const t = o;
|
|
1908
1915
|
return (e, n) => (r(), p("div", {
|
|
1909
|
-
class:
|
|
1916
|
+
class: V(["q-line-loader", t.class])
|
|
1910
1917
|
}, null, 2));
|
|
1911
1918
|
}
|
|
1912
|
-
}),
|
|
1919
|
+
}), Wo = C(jo), Xo = {
|
|
1913
1920
|
key: 0,
|
|
1914
1921
|
class: "q-popover__header"
|
|
1915
|
-
},
|
|
1922
|
+
}, Yo = {
|
|
1916
1923
|
key: 1,
|
|
1917
1924
|
class: "q-popover__body"
|
|
1918
|
-
},
|
|
1925
|
+
}, Zo = ["innerHTML"], Jo = { key: 1 }, en = /* @__PURE__ */ B({
|
|
1919
1926
|
inheritAttrs: !1,
|
|
1920
1927
|
__name: "QPopover",
|
|
1921
1928
|
props: /* @__PURE__ */ Z({
|
|
@@ -1934,7 +1941,7 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1934
1941
|
}),
|
|
1935
1942
|
emits: ["update:modelValue"],
|
|
1936
1943
|
setup(o) {
|
|
1937
|
-
const t = o, e =
|
|
1944
|
+
const t = o, e = ne(o, "modelValue");
|
|
1938
1945
|
return (n, l) => (r(), S(m(ye), {
|
|
1939
1946
|
modelValue: e.value,
|
|
1940
1947
|
"onUpdate:modelValue": l[0] || (l[0] = (s) => e.value = s),
|
|
@@ -1948,35 +1955,31 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1948
1955
|
placement: t.placement
|
|
1949
1956
|
}, {
|
|
1950
1957
|
default: _(() => [
|
|
1951
|
-
t.title || n.$slots.header ? (r(), p("h3",
|
|
1952
|
-
|
|
1958
|
+
t.title || n.$slots.header ? (r(), p("h3", Xo, [
|
|
1959
|
+
ce(O(t.title) + " ", 1),
|
|
1953
1960
|
h(n.$slots, "header")
|
|
1954
1961
|
])) : x("", !0),
|
|
1955
|
-
t.text || n.$slots.body ? (r(), p("div",
|
|
1962
|
+
t.text || n.$slots.body ? (r(), p("div", Yo, [
|
|
1956
1963
|
t.html ? (r(), p("span", {
|
|
1957
1964
|
key: 0,
|
|
1958
1965
|
innerHTML: t.text
|
|
1959
|
-
}, null, 8,
|
|
1966
|
+
}, null, 8, Zo)) : (r(), p("span", Jo, O(t.text), 1)),
|
|
1960
1967
|
h(n.$slots, "body")
|
|
1961
1968
|
])) : x("", !0)
|
|
1962
1969
|
]),
|
|
1963
1970
|
_: 3
|
|
1964
1971
|
}, 8, ["modelValue", "anchor", "arrow", "attach", "inline", "disabled", "placement"]));
|
|
1965
1972
|
}
|
|
1966
|
-
}),
|
|
1973
|
+
}), tn = C(en), st = {
|
|
1967
1974
|
emptyMessage: "Select a field to view details."
|
|
1968
|
-
},
|
|
1975
|
+
}, at = {
|
|
1969
1976
|
open: {
|
|
1970
1977
|
icon: "minus-box"
|
|
1971
1978
|
},
|
|
1972
1979
|
close: {
|
|
1973
1980
|
icon: "plus-box"
|
|
1974
1981
|
}
|
|
1975
|
-
},
|
|
1976
|
-
/* @__PURE__ */ L("tr", null, [
|
|
1977
|
-
/* @__PURE__ */ L("th", { colspan: "2" })
|
|
1978
|
-
])
|
|
1979
|
-
], -1), sn = /* @__PURE__ */ B({
|
|
1982
|
+
}, on = { class: "q-property-list__table" }, nn = /* @__PURE__ */ B({
|
|
1980
1983
|
__name: "QPropertyList",
|
|
1981
1984
|
props: {
|
|
1982
1985
|
fields: { default: () => [] },
|
|
@@ -1985,79 +1988,82 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
1985
1988
|
panelPosition: { default: "bottom" },
|
|
1986
1989
|
groups: { default: () => [] },
|
|
1987
1990
|
class: { default: void 0 },
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
}) },
|
|
1992
|
-
readonly: { type: Boolean }
|
|
1991
|
+
readonly: { type: Boolean },
|
|
1992
|
+
icons: { default: () => at },
|
|
1993
|
+
texts: { default: () => st }
|
|
1993
1994
|
},
|
|
1994
1995
|
emits: ["field-change"],
|
|
1995
1996
|
setup(o, { emit: t }) {
|
|
1996
|
-
const e = o, n = t, l =
|
|
1997
|
-
(y) => e.fields.some((
|
|
1998
|
-
) : [{ id: "", title: "" }]), d =
|
|
1997
|
+
const e = o, n = t, l = D(e.groups.map((y) => y.id)), s = D(void 0), i = D(null), a = g(() => e.groups.length ? e.groups.filter(
|
|
1998
|
+
(y) => e.fields.some((E) => E.group === y.id)
|
|
1999
|
+
) : [{ id: "", title: "" }]), d = g(() => [
|
|
1999
2000
|
e.class,
|
|
2000
2001
|
{
|
|
2001
2002
|
"q-property-list--side-panel": e.panelPosition === "right"
|
|
2002
2003
|
}
|
|
2003
2004
|
]);
|
|
2004
|
-
function
|
|
2005
|
+
function c() {
|
|
2005
2006
|
var y;
|
|
2006
2007
|
(y = i.value) != null && y.contains(document.activeElement) || (s.value = void 0);
|
|
2007
2008
|
}
|
|
2008
|
-
function
|
|
2009
|
-
return y ? e.fields.filter((
|
|
2009
|
+
function w(y) {
|
|
2010
|
+
return y ? e.fields.filter((E) => E.group === y) : e.fields;
|
|
2010
2011
|
}
|
|
2011
2012
|
function I(y) {
|
|
2012
|
-
const
|
|
2013
|
-
|
|
2013
|
+
const E = l.value.indexOf(y);
|
|
2014
|
+
E === -1 ? l.value.push(y) : l.value.splice(E, 1);
|
|
2014
2015
|
}
|
|
2015
|
-
function
|
|
2016
|
-
var
|
|
2016
|
+
function P(y) {
|
|
2017
|
+
var Q;
|
|
2018
|
+
const E = y.group && !l.value.includes(y.group), M = ((Q = s.value) == null ? void 0 : Q.id) === y.id;
|
|
2017
2019
|
return [
|
|
2018
2020
|
{
|
|
2019
|
-
"q-property-list__row--closed":
|
|
2020
|
-
"q-property-list__row--selected":
|
|
2021
|
+
"q-property-list__row--closed": E,
|
|
2022
|
+
"q-property-list__row--selected": M
|
|
2021
2023
|
}
|
|
2022
2024
|
];
|
|
2023
2025
|
}
|
|
2024
2026
|
function A(y) {
|
|
2025
2027
|
s.value = y;
|
|
2026
2028
|
}
|
|
2027
|
-
function
|
|
2028
|
-
e.readonly || (y.props.readonly ?? !1) || (y.props.modelValue =
|
|
2029
|
+
function T(y, E) {
|
|
2030
|
+
e.readonly || (y.props.readonly ?? !1) || (y.props.modelValue = E, n("field-change", y));
|
|
2029
2031
|
}
|
|
2030
|
-
return (y,
|
|
2032
|
+
return (y, E) => (r(), p("div", {
|
|
2031
2033
|
tabindex: "0",
|
|
2032
|
-
class:
|
|
2034
|
+
class: V(["q-property-list", d.value]),
|
|
2033
2035
|
ref_key: "componentRoot",
|
|
2034
2036
|
ref: i,
|
|
2035
|
-
onFocusout:
|
|
2037
|
+
onFocusout: c
|
|
2036
2038
|
}, [
|
|
2037
|
-
L("table",
|
|
2038
|
-
|
|
2039
|
+
L("table", on, [
|
|
2040
|
+
E[0] || (E[0] = L("thead", { class: "q-property-list__header" }, [
|
|
2041
|
+
L("tr", null, [
|
|
2042
|
+
L("th", { colspan: "2" })
|
|
2043
|
+
])
|
|
2044
|
+
], -1)),
|
|
2039
2045
|
L("tbody", null, [
|
|
2040
|
-
(r(!0), p(K, null, he(a.value, (
|
|
2041
|
-
key:
|
|
2046
|
+
(r(!0), p(K, null, he(a.value, (M) => (r(), p(K, {
|
|
2047
|
+
key: M.id
|
|
2042
2048
|
}, [
|
|
2043
|
-
|
|
2049
|
+
M.title ? (r(), S(m(rt), {
|
|
2044
2050
|
key: 0,
|
|
2045
|
-
id:
|
|
2046
|
-
title:
|
|
2047
|
-
|
|
2051
|
+
id: M.id,
|
|
2052
|
+
title: M.title,
|
|
2053
|
+
icons: e.icons,
|
|
2048
2054
|
"no-toggle": e.noToggle,
|
|
2049
2055
|
onToggleGroup: I
|
|
2050
|
-
}, null, 8, ["id", "title", "
|
|
2051
|
-
(r(!0), p(K, null, he(
|
|
2052
|
-
key:
|
|
2053
|
-
class:
|
|
2054
|
-
field:
|
|
2056
|
+
}, null, 8, ["id", "title", "icons", "no-toggle"])) : x("", !0),
|
|
2057
|
+
(r(!0), p(K, null, he(w(M.id), (Q) => (r(), S(m(it), {
|
|
2058
|
+
key: Q.id,
|
|
2059
|
+
class: V(P(Q)),
|
|
2060
|
+
field: Q,
|
|
2055
2061
|
readonly: e.readonly,
|
|
2056
2062
|
onFocus: A,
|
|
2057
|
-
onFieldChange:
|
|
2063
|
+
onFieldChange: T
|
|
2058
2064
|
}, {
|
|
2059
2065
|
default: _(() => [
|
|
2060
|
-
h(y.$slots,
|
|
2066
|
+
h(y.$slots, Q.id, { field: Q })
|
|
2061
2067
|
]),
|
|
2062
2068
|
_: 2
|
|
2063
2069
|
}, 1032, ["class", "field", "readonly"]))), 128))
|
|
@@ -2066,8 +2072,8 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2066
2072
|
]),
|
|
2067
2073
|
e.noPanel ? x("", !0) : (r(), S(m(dt), {
|
|
2068
2074
|
key: 0,
|
|
2069
|
-
|
|
2070
|
-
|
|
2075
|
+
field: s.value,
|
|
2076
|
+
texts: e.texts
|
|
2071
2077
|
}, {
|
|
2072
2078
|
default: _(() => [
|
|
2073
2079
|
s.value ? h(y.$slots, "panel", {
|
|
@@ -2076,10 +2082,10 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2076
2082
|
}) : x("", !0)
|
|
2077
2083
|
]),
|
|
2078
2084
|
_: 3
|
|
2079
|
-
}, 8, ["
|
|
2085
|
+
}, 8, ["field", "texts"]))
|
|
2080
2086
|
], 34));
|
|
2081
2087
|
}
|
|
2082
|
-
}),
|
|
2088
|
+
}), ln = { class: "q-property-list-field__container" }, sn = /* @__PURE__ */ B({
|
|
2083
2089
|
__name: "QPropertyListRow",
|
|
2084
2090
|
props: {
|
|
2085
2091
|
field: {},
|
|
@@ -2088,36 +2094,36 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2088
2094
|
},
|
|
2089
2095
|
emits: ["focus", "field-change"],
|
|
2090
2096
|
setup(o, { emit: t }) {
|
|
2091
|
-
const e = o, n = t, l =
|
|
2097
|
+
const e = o, n = t, l = g(() => ["q-property-list__row", e.class]), s = g(() => {
|
|
2092
2098
|
var I;
|
|
2093
|
-
const
|
|
2094
|
-
return (I = e.field.props) != null && I.required &&
|
|
2095
|
-
}), i =
|
|
2099
|
+
const w = ["q-property-list__cell", "q-property-list__cell--label"];
|
|
2100
|
+
return (I = e.field.props) != null && I.required && w.push("q-property-list__cell--required"), w;
|
|
2101
|
+
}), i = g(() => e.readonly || (e.field.props.readonly ?? !1));
|
|
2096
2102
|
function a() {
|
|
2097
2103
|
n("focus", e.field);
|
|
2098
2104
|
}
|
|
2099
|
-
function d(
|
|
2100
|
-
n("field-change", e.field,
|
|
2105
|
+
function d(w) {
|
|
2106
|
+
n("field-change", e.field, w);
|
|
2101
2107
|
}
|
|
2102
|
-
const
|
|
2108
|
+
const c = g(() => ({
|
|
2103
2109
|
...e.field.props,
|
|
2104
2110
|
readonly: i.value
|
|
2105
2111
|
}));
|
|
2106
|
-
return (
|
|
2107
|
-
class:
|
|
2112
|
+
return (w, I) => (r(), p("tr", {
|
|
2113
|
+
class: V(l.value),
|
|
2108
2114
|
onFocusin: a
|
|
2109
2115
|
}, [
|
|
2110
2116
|
L("td", {
|
|
2111
|
-
class:
|
|
2117
|
+
class: V(s.value),
|
|
2112
2118
|
onClick: a
|
|
2113
|
-
},
|
|
2119
|
+
}, O(e.field.label), 3),
|
|
2114
2120
|
L("td", {
|
|
2115
2121
|
class: "q-property-list__cell",
|
|
2116
2122
|
onClick: a
|
|
2117
2123
|
}, [
|
|
2118
|
-
h(
|
|
2119
|
-
L("div",
|
|
2120
|
-
(r(), S(Be(e.field.component),
|
|
2124
|
+
h(w.$slots, "default", {}, () => [
|
|
2125
|
+
L("div", ln, [
|
|
2126
|
+
(r(), S(Be(e.field.component), J(c.value, {
|
|
2121
2127
|
"model-value": e.field.props.modelValue,
|
|
2122
2128
|
"onUpdate:modelValue": d
|
|
2123
2129
|
}), null, 16, ["model-value"]))
|
|
@@ -2126,22 +2132,18 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2126
2132
|
])
|
|
2127
2133
|
], 34));
|
|
2128
2134
|
}
|
|
2129
|
-
}),
|
|
2135
|
+
}), an = ["data-key", "aria-labelledby"], rn = ["id"], dn = { class: "q-property-list-group__content" }, un = /* @__PURE__ */ B({
|
|
2130
2136
|
__name: "QPropertyListGroup",
|
|
2131
2137
|
props: {
|
|
2132
2138
|
id: {},
|
|
2133
2139
|
title: {},
|
|
2134
2140
|
noToggle: { type: Boolean, default: !1 },
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
texts: Ee
|
|
2138
|
-
}) }
|
|
2141
|
+
icons: { default: () => at },
|
|
2142
|
+
texts: {}
|
|
2139
2143
|
},
|
|
2140
2144
|
emits: ["toggle-group"],
|
|
2141
2145
|
setup(o, { emit: t }) {
|
|
2142
|
-
const e = o, n = t, l =
|
|
2143
|
-
() => l.value ? e.internals.icons.open : e.internals.icons.close
|
|
2144
|
-
), a = b(() => [
|
|
2146
|
+
const e = o, n = t, l = D(!0), s = fe(), i = g(() => l.value ? e.icons.open : e.icons.close), a = g(() => [
|
|
2145
2147
|
"q-property-list-group",
|
|
2146
2148
|
{
|
|
2147
2149
|
"q-property-list-group--no-toggle": e.noToggle
|
|
@@ -2150,8 +2152,8 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2150
2152
|
function d() {
|
|
2151
2153
|
e.noToggle || (l.value = !l.value, n("toggle-group", e.id));
|
|
2152
2154
|
}
|
|
2153
|
-
return (
|
|
2154
|
-
class:
|
|
2155
|
+
return (c, w) => (r(), p("tr", {
|
|
2156
|
+
class: V(a.value),
|
|
2155
2157
|
role: "group",
|
|
2156
2158
|
"data-key": e.id,
|
|
2157
2159
|
"aria-labelledby": m(s),
|
|
@@ -2161,7 +2163,7 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2161
2163
|
id: m(s),
|
|
2162
2164
|
colspan: "2"
|
|
2163
2165
|
}, [
|
|
2164
|
-
L("div",
|
|
2166
|
+
L("div", dn, [
|
|
2165
2167
|
e.noToggle ? x("", !0) : (r(), S(m(re), {
|
|
2166
2168
|
key: 0,
|
|
2167
2169
|
"b-style": "tertiary",
|
|
@@ -2169,55 +2171,56 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2169
2171
|
onClick: d
|
|
2170
2172
|
}, {
|
|
2171
2173
|
default: _(() => [
|
|
2172
|
-
|
|
2174
|
+
z(m(N), j(le(i.value)), null, 16)
|
|
2173
2175
|
]),
|
|
2174
2176
|
_: 1
|
|
2175
2177
|
})),
|
|
2176
|
-
|
|
2178
|
+
ce(" " + O(e.title), 1)
|
|
2177
2179
|
])
|
|
2178
|
-
], 8,
|
|
2179
|
-
], 10,
|
|
2180
|
+
], 8, rn)
|
|
2181
|
+
], 10, an));
|
|
2180
2182
|
}
|
|
2181
|
-
}),
|
|
2183
|
+
}), cn = { class: "q-property-list-panel__container" }, fn = { class: "q-property-list-panel__label" }, pn = { class: "q-property-list-panel__description" }, mn = {
|
|
2182
2184
|
key: 1,
|
|
2183
2185
|
class: "q-property-list-panel__empty"
|
|
2184
|
-
},
|
|
2186
|
+
}, vn = /* @__PURE__ */ B({
|
|
2185
2187
|
__name: "QPropertyListPanel",
|
|
2186
2188
|
props: {
|
|
2187
2189
|
field: { default: void 0 },
|
|
2188
|
-
|
|
2189
|
-
|
|
2190
|
-
texts: Ee
|
|
2191
|
-
}) }
|
|
2190
|
+
icons: {},
|
|
2191
|
+
texts: { default: () => st }
|
|
2192
2192
|
},
|
|
2193
2193
|
setup(o) {
|
|
2194
2194
|
const t = o;
|
|
2195
|
-
return (e, n) => (r(), p("div",
|
|
2195
|
+
return (e, n) => (r(), p("div", cn, [
|
|
2196
2196
|
t.field ? h(e.$slots, "default", { key: 0 }, () => [
|
|
2197
|
-
L("div",
|
|
2198
|
-
L("div",
|
|
2199
|
-
]) : (r(), p("div",
|
|
2197
|
+
L("div", fn, O(t.field.label), 1),
|
|
2198
|
+
L("div", pn, O(t.field.description), 1)
|
|
2199
|
+
]) : (r(), p("div", mn, O(t.texts.emptyMessage), 1))
|
|
2200
2200
|
]));
|
|
2201
2201
|
}
|
|
2202
|
-
}),
|
|
2203
|
-
placeholder: "Choose..."
|
|
2204
|
-
|
|
2202
|
+
}), hn = C(nn), it = C(sn), rt = C(un), dt = C(vn), yn = {
|
|
2203
|
+
placeholder: "Choose...",
|
|
2204
|
+
clearValue: "Clear value",
|
|
2205
|
+
showOptions: "Show options"
|
|
2206
|
+
}, bn = {
|
|
2205
2207
|
chevron: {
|
|
2206
2208
|
icon: "chevron-down"
|
|
2207
2209
|
},
|
|
2208
2210
|
clear: {
|
|
2209
2211
|
icon: "close"
|
|
2210
2212
|
}
|
|
2211
|
-
},
|
|
2213
|
+
}, gn = {
|
|
2212
2214
|
key: 0,
|
|
2213
2215
|
class: "q-select__value"
|
|
2214
|
-
},
|
|
2216
|
+
}, _n = {
|
|
2215
2217
|
key: 1,
|
|
2216
2218
|
class: "q-select__placeholder"
|
|
2217
|
-
},
|
|
2219
|
+
}, kn = ["data-key"], wn = {
|
|
2218
2220
|
key: 0,
|
|
2219
2221
|
class: "q-select__loader"
|
|
2220
|
-
},
|
|
2222
|
+
}, $n = /* @__PURE__ */ B({
|
|
2223
|
+
inheritAttrs: !1,
|
|
2221
2224
|
__name: "QSelect",
|
|
2222
2225
|
props: /* @__PURE__ */ Z({
|
|
2223
2226
|
id: { default: void 0 },
|
|
@@ -2234,7 +2237,8 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2234
2237
|
emptyValue: { type: [String, Number, Boolean, Symbol], default: void 0 },
|
|
2235
2238
|
size: { default: void 0 },
|
|
2236
2239
|
class: { default: "" },
|
|
2237
|
-
|
|
2240
|
+
icons: { default: () => bn },
|
|
2241
|
+
texts: { default: () => yn }
|
|
2238
2242
|
}, {
|
|
2239
2243
|
modelValue: {
|
|
2240
2244
|
type: [String, Number, Boolean, Symbol]
|
|
@@ -2243,79 +2247,79 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2243
2247
|
}),
|
|
2244
2248
|
emits: /* @__PURE__ */ Z(["before-show", "before-hide", "show", "hide"], ["update:modelValue"]),
|
|
2245
2249
|
setup(o, { emit: t }) {
|
|
2246
|
-
const e = o, n = t, l =
|
|
2250
|
+
const e = o, n = t, l = ne(o, "modelValue"), s = D(!1), i = D(""), a = D(null), d = D(null), c = D(null), w = g(() => I.value === void 0), I = g(
|
|
2247
2251
|
() => {
|
|
2248
|
-
var
|
|
2249
|
-
return (
|
|
2252
|
+
var f;
|
|
2253
|
+
return (f = e.items) == null ? void 0 : f.find((b) => b[e.itemValue] === l.value);
|
|
2250
2254
|
}
|
|
2251
|
-
),
|
|
2255
|
+
), P = g(
|
|
2252
2256
|
() => I.value ? I.value[e.itemLabel] : ""
|
|
2253
|
-
), A =
|
|
2257
|
+
), A = g(
|
|
2254
2258
|
() => e.clearable && !e.readonly && !e.disabled && !e.loading
|
|
2255
2259
|
);
|
|
2256
|
-
function
|
|
2257
|
-
l.value =
|
|
2260
|
+
function T(f) {
|
|
2261
|
+
l.value = f, Q();
|
|
2258
2262
|
}
|
|
2259
2263
|
function y() {
|
|
2260
|
-
A.value && (
|
|
2264
|
+
A.value && (T(e.emptyValue), Y());
|
|
2261
2265
|
}
|
|
2262
|
-
function
|
|
2263
|
-
var
|
|
2264
|
-
!((
|
|
2266
|
+
function E(f) {
|
|
2267
|
+
var b, G, ie;
|
|
2268
|
+
!((b = c.value) != null && b.contains(f.relatedTarget)) && !((ie = (G = a.value) == null ? void 0 : G.fieldRef) != null && ie.contains(f.relatedTarget)) && Q();
|
|
2265
2269
|
}
|
|
2266
|
-
function
|
|
2270
|
+
function M() {
|
|
2267
2271
|
s.value || (n("before-show"), s.value = !0);
|
|
2268
2272
|
}
|
|
2269
|
-
function
|
|
2273
|
+
function Q() {
|
|
2270
2274
|
s.value && (n("before-hide"), s.value = !1);
|
|
2271
2275
|
}
|
|
2272
2276
|
function H() {
|
|
2273
|
-
e.readonly || e.disabled || (s.value ?
|
|
2274
|
-
}
|
|
2275
|
-
let
|
|
2276
|
-
function W(
|
|
2277
|
-
if (!(!
|
|
2278
|
-
if (window.clearTimeout(
|
|
2279
|
-
i.value +=
|
|
2280
|
-
for (let
|
|
2281
|
-
if (e.items[
|
|
2282
|
-
|
|
2277
|
+
e.readonly || e.disabled || (s.value ? Q() : M());
|
|
2278
|
+
}
|
|
2279
|
+
let se;
|
|
2280
|
+
function W(f) {
|
|
2281
|
+
if (!(!f.key || e.readonly || e.disabled)) {
|
|
2282
|
+
if (window.clearTimeout(se), ["Enter", " ", "ArrowDown", "ArrowUp", "Home", "End"].includes(f.key) && (f.preventDefault(), f.stopPropagation()), ["Enter", " "].includes(f.key) && (s.value = !0), ["Escape", "Tab"].includes(f.key) && (s.value ? s.value = !1 : A.value && f.key === "Escape" && y()), f.key === "Delete" && e.clearable && y(), /^[a-z]$/i.test(f.key)) {
|
|
2283
|
+
i.value += f.key.toLowerCase();
|
|
2284
|
+
for (let b = 0; b < e.items.length; b++)
|
|
2285
|
+
if (e.items[b][e.itemLabel].toLowerCase().startsWith(i.value)) {
|
|
2286
|
+
$(b);
|
|
2283
2287
|
break;
|
|
2284
2288
|
}
|
|
2285
2289
|
}
|
|
2286
|
-
|
|
2290
|
+
se = window.setTimeout(function() {
|
|
2287
2291
|
i.value = "";
|
|
2288
2292
|
}, 500);
|
|
2289
2293
|
}
|
|
2290
2294
|
}
|
|
2291
|
-
function
|
|
2292
|
-
var
|
|
2293
|
-
e.loading ? (
|
|
2295
|
+
function ae() {
|
|
2296
|
+
var f;
|
|
2297
|
+
e.loading ? (f = c.value) == null || f.focus() : v(), n("show");
|
|
2294
2298
|
}
|
|
2295
2299
|
function U() {
|
|
2296
2300
|
Y(), n("hide");
|
|
2297
2301
|
}
|
|
2298
2302
|
function Y() {
|
|
2299
|
-
var
|
|
2300
|
-
(
|
|
2303
|
+
var f, b;
|
|
2304
|
+
(b = (f = a.value) == null ? void 0 : f.fieldRef) == null || b.focus();
|
|
2301
2305
|
}
|
|
2302
2306
|
function v() {
|
|
2303
|
-
var
|
|
2304
|
-
(
|
|
2307
|
+
var f;
|
|
2308
|
+
(f = d.value) == null || f.$el.focus();
|
|
2305
2309
|
}
|
|
2306
|
-
function
|
|
2307
|
-
var
|
|
2308
|
-
(
|
|
2310
|
+
function $(f) {
|
|
2311
|
+
var b;
|
|
2312
|
+
(b = d.value) == null || b.focusItem(f);
|
|
2309
2313
|
}
|
|
2310
|
-
return
|
|
2314
|
+
return te(
|
|
2311
2315
|
() => e.loading,
|
|
2312
|
-
(
|
|
2313
|
-
!
|
|
2316
|
+
(f) => {
|
|
2317
|
+
!f && s.value && oe(v);
|
|
2314
2318
|
}
|
|
2315
|
-
), (
|
|
2316
|
-
var G,
|
|
2319
|
+
), (f, b) => {
|
|
2320
|
+
var G, ie;
|
|
2317
2321
|
return r(), p(K, null, [
|
|
2318
|
-
|
|
2322
|
+
z(m(Le), J({
|
|
2319
2323
|
id: e.id,
|
|
2320
2324
|
label: e.label,
|
|
2321
2325
|
required: e.required,
|
|
@@ -2323,7 +2327,7 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2323
2327
|
ref: a,
|
|
2324
2328
|
role: "combobox",
|
|
2325
2329
|
tabindex: e.disabled ? -1 : 0,
|
|
2326
|
-
class:
|
|
2330
|
+
class: [
|
|
2327
2331
|
"q-select",
|
|
2328
2332
|
{
|
|
2329
2333
|
"q-select--readonly": e.readonly,
|
|
@@ -2331,34 +2335,37 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2331
2335
|
"q-select--expanded": s.value
|
|
2332
2336
|
},
|
|
2333
2337
|
e.class
|
|
2334
|
-
]
|
|
2338
|
+
],
|
|
2335
2339
|
readonly: e.readonly,
|
|
2336
2340
|
disabled: e.disabled,
|
|
2337
2341
|
"data-loading": e.loading,
|
|
2338
2342
|
"aria-expanded": s.value,
|
|
2339
2343
|
"aria-haspopup": "listbox",
|
|
2340
|
-
size: e.size
|
|
2344
|
+
size: e.size
|
|
2345
|
+
}, f.$attrs, {
|
|
2341
2346
|
onClick: H,
|
|
2342
2347
|
onKeydown: ve(W, ["stop"])
|
|
2343
|
-
}, qe({
|
|
2348
|
+
}), qe({
|
|
2344
2349
|
append: _(() => [
|
|
2345
|
-
h(
|
|
2350
|
+
h(f.$slots, "append"),
|
|
2346
2351
|
A.value && l.value ? (r(), S(m(re), {
|
|
2347
2352
|
key: 0,
|
|
2348
2353
|
class: "q-select__clear",
|
|
2354
|
+
"aria-label": e.texts.clearValue,
|
|
2349
2355
|
"b-style": "plain",
|
|
2350
2356
|
borderless: "",
|
|
2351
2357
|
tabindex: "-1",
|
|
2352
2358
|
onClick: y
|
|
2353
2359
|
}, {
|
|
2354
2360
|
default: _(() => [
|
|
2355
|
-
|
|
2361
|
+
z(m(N), j(le(e.icons.clear)), null, 16)
|
|
2356
2362
|
]),
|
|
2357
2363
|
_: 1
|
|
2358
|
-
})) : x("", !0),
|
|
2364
|
+
}, 8, ["aria-label"])) : x("", !0),
|
|
2359
2365
|
e.readonly ? x("", !0) : (r(), S(m(re), {
|
|
2360
2366
|
key: 1,
|
|
2361
2367
|
class: "q-select__chevron",
|
|
2368
|
+
"aria-label": e.texts.showOptions,
|
|
2362
2369
|
"b-style": "plain",
|
|
2363
2370
|
borderless: "",
|
|
2364
2371
|
tabindex: "-1",
|
|
@@ -2366,66 +2373,66 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2366
2373
|
onClick: H
|
|
2367
2374
|
}, {
|
|
2368
2375
|
default: _(() => [
|
|
2369
|
-
|
|
2376
|
+
z(m(N), j(le(e.icons.chevron)), null, 16)
|
|
2370
2377
|
]),
|
|
2371
2378
|
_: 1
|
|
2372
|
-
}, 8, ["disabled"]))
|
|
2379
|
+
}, 8, ["aria-label", "disabled"]))
|
|
2373
2380
|
]),
|
|
2374
2381
|
default: _(() => [
|
|
2375
|
-
|
|
2382
|
+
w.value ? (r(), p("span", _n, [
|
|
2376
2383
|
!e.readonly && !e.disabled ? (r(), p(K, { key: 0 }, [
|
|
2377
|
-
|
|
2384
|
+
ce(O(e.texts.placeholder), 1)
|
|
2378
2385
|
], 64)) : x("", !0)
|
|
2379
|
-
])) : (r(), p("span",
|
|
2386
|
+
])) : (r(), p("span", gn, O(P.value), 1))
|
|
2380
2387
|
]),
|
|
2381
2388
|
_: 2
|
|
2382
2389
|
}, [
|
|
2383
|
-
(G = I.value) != null && G.icon ||
|
|
2390
|
+
(G = I.value) != null && G.icon || f.$slots.prepend ? {
|
|
2384
2391
|
name: "prepend",
|
|
2385
2392
|
fn: _(() => {
|
|
2386
|
-
var
|
|
2393
|
+
var ee, de;
|
|
2387
2394
|
return [
|
|
2388
|
-
h(
|
|
2389
|
-
(
|
|
2395
|
+
h(f.$slots, "prepend"),
|
|
2396
|
+
(ee = I.value) != null && ee.icon ? (r(), S(m(N), j(J({ key: 0 }, (de = I.value) == null ? void 0 : de.icon)), null, 16)) : x("", !0)
|
|
2390
2397
|
];
|
|
2391
2398
|
}),
|
|
2392
2399
|
key: "0"
|
|
2393
2400
|
} : void 0,
|
|
2394
|
-
|
|
2401
|
+
f.$slots.extras ? {
|
|
2395
2402
|
name: "extras",
|
|
2396
2403
|
fn: _(() => [
|
|
2397
|
-
h(
|
|
2404
|
+
h(f.$slots, "extras")
|
|
2398
2405
|
]),
|
|
2399
2406
|
key: "1"
|
|
2400
2407
|
} : void 0
|
|
2401
|
-
]),
|
|
2402
|
-
|
|
2408
|
+
]), 1040, ["id", "label", "required", "tabindex", "class", "readonly", "disabled", "data-loading", "aria-expanded", "size"]),
|
|
2409
|
+
z(m(ye), {
|
|
2403
2410
|
modelValue: s.value,
|
|
2404
|
-
"onUpdate:modelValue":
|
|
2411
|
+
"onUpdate:modelValue": b[0] || (b[0] = (ee) => s.value = ee),
|
|
2405
2412
|
spy: "",
|
|
2406
2413
|
trigger: "manual",
|
|
2407
2414
|
placement: "bottom-start",
|
|
2408
2415
|
width: "anchor",
|
|
2409
2416
|
"scroll-lock": "",
|
|
2410
|
-
anchor: (
|
|
2417
|
+
anchor: (ie = a.value) == null ? void 0 : ie.$el,
|
|
2411
2418
|
offset: 2,
|
|
2412
|
-
onEnter:
|
|
2419
|
+
onEnter: ae,
|
|
2413
2420
|
onLeave: U
|
|
2414
2421
|
}, {
|
|
2415
2422
|
default: _(() => [
|
|
2416
2423
|
L("div", {
|
|
2417
2424
|
ref_key: "contentRef",
|
|
2418
|
-
ref:
|
|
2425
|
+
ref: c,
|
|
2419
2426
|
"data-testid": "combobox-dropdown",
|
|
2420
2427
|
"data-key": e.id,
|
|
2421
2428
|
class: "q-select__body",
|
|
2422
2429
|
tabindex: "-1",
|
|
2423
|
-
onFocusout:
|
|
2430
|
+
onFocusout: E,
|
|
2424
2431
|
onKeydown: ve(W, ["stop"])
|
|
2425
2432
|
}, [
|
|
2426
|
-
h(
|
|
2427
|
-
e.loading ? (r(), p("div",
|
|
2428
|
-
|
|
2433
|
+
h(f.$slots, "body.prepend"),
|
|
2434
|
+
e.loading ? (r(), p("div", wn, [
|
|
2435
|
+
z(m(xe), { size: 24 })
|
|
2429
2436
|
])) : (r(), S(m(Ve), {
|
|
2430
2437
|
key: 1,
|
|
2431
2438
|
ref_key: "listRef",
|
|
@@ -2434,27 +2441,25 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2434
2441
|
selectable: "",
|
|
2435
2442
|
"model-value": l.value,
|
|
2436
2443
|
items: e.items,
|
|
2437
|
-
groups:
|
|
2444
|
+
groups: f.groups,
|
|
2438
2445
|
"item-label": e.itemLabel,
|
|
2439
2446
|
"item-value": e.itemValue,
|
|
2440
|
-
"onUpdate:modelValue":
|
|
2447
|
+
"onUpdate:modelValue": T
|
|
2441
2448
|
}, {
|
|
2442
|
-
item: _(({ item:
|
|
2443
|
-
h(
|
|
2449
|
+
item: _(({ item: ee }) => [
|
|
2450
|
+
h(f.$slots, "item", { item: ee })
|
|
2444
2451
|
]),
|
|
2445
2452
|
_: 3
|
|
2446
2453
|
}, 8, ["model-value", "items", "groups", "item-label", "item-value"])),
|
|
2447
|
-
h(
|
|
2448
|
-
], 40,
|
|
2454
|
+
h(f.$slots, "body.append")
|
|
2455
|
+
], 40, kn)
|
|
2449
2456
|
]),
|
|
2450
2457
|
_: 3
|
|
2451
2458
|
}, 8, ["modelValue", "anchor"])
|
|
2452
2459
|
], 64);
|
|
2453
2460
|
};
|
|
2454
2461
|
}
|
|
2455
|
-
}),
|
|
2456
|
-
In
|
|
2457
|
-
], Bn = /* @__PURE__ */ B({
|
|
2462
|
+
}), qn = C($n), xn = /* @__PURE__ */ B({
|
|
2458
2463
|
__name: "QSkeletonLoader",
|
|
2459
2464
|
props: {
|
|
2460
2465
|
type: { default: void 0 },
|
|
@@ -2462,7 +2467,7 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2462
2467
|
height: { default: void 0 }
|
|
2463
2468
|
},
|
|
2464
2469
|
setup(o) {
|
|
2465
|
-
const t = o, e =
|
|
2470
|
+
const t = o, e = g(() => t.type ? `q-skeleton-loader--${t.type}` : void 0), n = g(() => {
|
|
2466
2471
|
const l = typeof t.width == "number" ? `${t.width}px` : t.width, s = typeof t.height == "number" ? `${t.height}px` : t.height;
|
|
2467
2472
|
return {
|
|
2468
2473
|
width: l,
|
|
@@ -2470,11 +2475,13 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2470
2475
|
};
|
|
2471
2476
|
});
|
|
2472
2477
|
return (l, s) => (r(), p("div", {
|
|
2473
|
-
class:
|
|
2474
|
-
style:
|
|
2475
|
-
},
|
|
2478
|
+
class: V(["q-skeleton-loader", e.value]),
|
|
2479
|
+
style: ue(n.value)
|
|
2480
|
+
}, s[0] || (s[0] = [
|
|
2481
|
+
L("div", { class: "q-skeleton-loader__bone" }, null, -1)
|
|
2482
|
+
]), 6));
|
|
2476
2483
|
}
|
|
2477
|
-
}),
|
|
2484
|
+
}), Ln = C(xn), In = /* @__PURE__ */ B({
|
|
2478
2485
|
__name: "QThemeProvider",
|
|
2479
2486
|
props: {
|
|
2480
2487
|
theme: {}
|
|
@@ -2482,12 +2489,12 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2482
2489
|
setup(o) {
|
|
2483
2490
|
const t = o;
|
|
2484
2491
|
return (e, n) => (r(), p("div", {
|
|
2485
|
-
class:
|
|
2492
|
+
class: V(["q-theme-provider", `q-theme--${t.theme}`])
|
|
2486
2493
|
}, [
|
|
2487
2494
|
h(e.$slots, "default")
|
|
2488
2495
|
], 2));
|
|
2489
2496
|
}
|
|
2490
|
-
}),
|
|
2497
|
+
}), Sn = C(In), Bn = ["innerHTML"], Cn = /* @__PURE__ */ B({
|
|
2491
2498
|
__name: "QTooltip",
|
|
2492
2499
|
props: /* @__PURE__ */ Z({
|
|
2493
2500
|
id: { default: void 0 },
|
|
@@ -2510,12 +2517,12 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2510
2517
|
}),
|
|
2511
2518
|
emits: ["update:modelValue"],
|
|
2512
2519
|
setup(o) {
|
|
2513
|
-
const t = o, e =
|
|
2520
|
+
const t = o, e = ne(o, "modelValue"), n = fe(t.id);
|
|
2514
2521
|
return (l, s) => (r(), p(K, null, [
|
|
2515
2522
|
h(l.$slots, "anchor", {
|
|
2516
2523
|
props: { "aria-describedby": m(n) }
|
|
2517
2524
|
}),
|
|
2518
|
-
|
|
2525
|
+
z(m(ye), {
|
|
2519
2526
|
"model-value": e.value,
|
|
2520
2527
|
anchor: t.anchor,
|
|
2521
2528
|
role: "tooltip",
|
|
@@ -2525,7 +2532,7 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2525
2532
|
arrow: t.arrow,
|
|
2526
2533
|
attach: t.attach,
|
|
2527
2534
|
inline: t.inline,
|
|
2528
|
-
class:
|
|
2535
|
+
class: V(["q-tooltip", t.class]),
|
|
2529
2536
|
delay: t.delay,
|
|
2530
2537
|
disabled: t.disabled,
|
|
2531
2538
|
placement: t.placement,
|
|
@@ -2533,12 +2540,12 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2533
2540
|
}, {
|
|
2534
2541
|
default: _(() => [
|
|
2535
2542
|
h(l.$slots, "default", {}, () => [
|
|
2536
|
-
t.icon ? (r(), S(m(N), j(
|
|
2543
|
+
t.icon ? (r(), S(m(N), j(J({ key: 0 }, t.icon)), null, 16)) : x("", !0),
|
|
2537
2544
|
t.html ? (r(), p("span", {
|
|
2538
2545
|
key: 1,
|
|
2539
2546
|
innerHTML: t.text
|
|
2540
|
-
}, null, 8,
|
|
2541
|
-
|
|
2547
|
+
}, null, 8, Bn)) : (r(), p(K, { key: 2 }, [
|
|
2548
|
+
ce(O(t.text), 1)
|
|
2542
2549
|
], 64))
|
|
2543
2550
|
])
|
|
2544
2551
|
]),
|
|
@@ -2546,57 +2553,57 @@ const fo = ["role"], po = /* @__PURE__ */ B({
|
|
|
2546
2553
|
}, 8, ["model-value", "anchor", "id", "appearance", "arrow", "attach", "inline", "class", "delay", "disabled", "placement", "trigger"])
|
|
2547
2554
|
], 64));
|
|
2548
2555
|
}
|
|
2549
|
-
}),
|
|
2556
|
+
}), Tn = C(Cn), Vn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2550
2557
|
__proto__: null,
|
|
2551
|
-
QBadge:
|
|
2558
|
+
QBadge: zt,
|
|
2552
2559
|
QButton: re,
|
|
2553
|
-
QButtonGroup:
|
|
2554
|
-
QButtonToggle:
|
|
2555
|
-
QCombobox:
|
|
2556
|
-
QDialog:
|
|
2560
|
+
QButtonGroup: tt,
|
|
2561
|
+
QButtonToggle: Pt,
|
|
2562
|
+
QCombobox: So,
|
|
2563
|
+
QDialog: Po,
|
|
2557
2564
|
QField: Le,
|
|
2558
2565
|
QIcon: N,
|
|
2559
|
-
QIconFont:
|
|
2560
|
-
QIconImg:
|
|
2561
|
-
QIconSvg:
|
|
2562
|
-
QInputGroup:
|
|
2563
|
-
QLineLoader:
|
|
2566
|
+
QIconFont: Ye,
|
|
2567
|
+
QIconImg: Ze,
|
|
2568
|
+
QIconSvg: Je,
|
|
2569
|
+
QInputGroup: Ko,
|
|
2570
|
+
QLineLoader: Wo,
|
|
2564
2571
|
QList: Ve,
|
|
2565
|
-
QListItem:
|
|
2566
|
-
QListItemGroup:
|
|
2572
|
+
QListItem: ot,
|
|
2573
|
+
QListItemGroup: nt,
|
|
2567
2574
|
QOverlay: ye,
|
|
2568
|
-
QPopover:
|
|
2569
|
-
QPropertyList:
|
|
2575
|
+
QPopover: tn,
|
|
2576
|
+
QPropertyList: hn,
|
|
2570
2577
|
QPropertyListGroup: rt,
|
|
2571
2578
|
QPropertyListPanel: dt,
|
|
2572
2579
|
QPropertyListRow: it,
|
|
2573
|
-
QSelect:
|
|
2574
|
-
QSkeletonLoader:
|
|
2580
|
+
QSelect: qn,
|
|
2581
|
+
QSkeletonLoader: Ln,
|
|
2575
2582
|
QSpinnerLoader: xe,
|
|
2576
|
-
QTextField:
|
|
2577
|
-
QThemeProvider:
|
|
2578
|
-
QTooltip:
|
|
2579
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
2580
|
-
function
|
|
2581
|
-
const o =
|
|
2583
|
+
QTextField: lt,
|
|
2584
|
+
QThemeProvider: Sn,
|
|
2585
|
+
QTooltip: Tn
|
|
2586
|
+
}, Symbol.toStringTag, { value: "Module" })), ge = "q-theme";
|
|
2587
|
+
function En() {
|
|
2588
|
+
const o = Ge(ge);
|
|
2582
2589
|
if (!o)
|
|
2583
2590
|
throw new Error("[Quidgest UI] Could not find theme instance");
|
|
2584
2591
|
return o;
|
|
2585
2592
|
}
|
|
2586
|
-
function
|
|
2587
|
-
const t =
|
|
2588
|
-
activeTheme:
|
|
2593
|
+
function Pn(o) {
|
|
2594
|
+
const t = En(), e = {
|
|
2595
|
+
activeTheme: D(o),
|
|
2589
2596
|
themes: t.themes
|
|
2590
2597
|
};
|
|
2591
|
-
return
|
|
2598
|
+
return He(ge, e), e;
|
|
2592
2599
|
}
|
|
2593
|
-
function
|
|
2600
|
+
function Dn() {
|
|
2594
2601
|
let o = document.getElementById(
|
|
2595
|
-
|
|
2602
|
+
ge
|
|
2596
2603
|
);
|
|
2597
|
-
return o || (o = document.createElement("style"), o.id =
|
|
2604
|
+
return o || (o = document.createElement("style"), o.id = ge, document.head.appendChild(o)), o;
|
|
2598
2605
|
}
|
|
2599
|
-
function
|
|
2606
|
+
function An(o) {
|
|
2600
2607
|
let t = "";
|
|
2601
2608
|
for (const n of o) {
|
|
2602
2609
|
t += `.q-theme--${n.name} {
|
|
@@ -2606,32 +2613,32 @@ function Mn(o) {
|
|
|
2606
2613
|
for (s in l) {
|
|
2607
2614
|
const i = l[s];
|
|
2608
2615
|
if (i) {
|
|
2609
|
-
t += ` ${
|
|
2616
|
+
t += ` ${Ue(s)}: ${i};
|
|
2610
2617
|
`;
|
|
2611
|
-
const a =
|
|
2612
|
-
t += ` ${
|
|
2618
|
+
const a = et(i);
|
|
2619
|
+
t += ` ${Ue(s)}-rgb: ${a.r} ${a.g} ${a.b};
|
|
2613
2620
|
`;
|
|
2614
2621
|
}
|
|
2615
2622
|
}
|
|
2616
2623
|
t += `}
|
|
2617
2624
|
`;
|
|
2618
2625
|
}
|
|
2619
|
-
const e =
|
|
2626
|
+
const e = Dn();
|
|
2620
2627
|
e.textContent = t;
|
|
2621
2628
|
}
|
|
2622
|
-
function
|
|
2623
|
-
return o ? `--q-theme-${
|
|
2629
|
+
function Ue(o) {
|
|
2630
|
+
return o ? `--q-theme-${Xe(o)}` : "";
|
|
2624
2631
|
}
|
|
2625
|
-
function
|
|
2632
|
+
function Qn(o = {}) {
|
|
2626
2633
|
return { install: (e) => {
|
|
2627
2634
|
const n = o.components || {};
|
|
2628
2635
|
for (const s in n)
|
|
2629
2636
|
e.component(s, n[s]);
|
|
2630
2637
|
const l = o.defaults || {};
|
|
2631
|
-
e.provide(Te,
|
|
2638
|
+
e.provide(Te, D(l)), Fn(e, o.themes);
|
|
2632
2639
|
} };
|
|
2633
2640
|
}
|
|
2634
|
-
function
|
|
2641
|
+
function Fn(o, t) {
|
|
2635
2642
|
const e = [];
|
|
2636
2643
|
let n;
|
|
2637
2644
|
if (!t)
|
|
@@ -2642,7 +2649,7 @@ function On(o, t) {
|
|
|
2642
2649
|
});
|
|
2643
2650
|
else
|
|
2644
2651
|
for (const l of t.themes) {
|
|
2645
|
-
const i = { ...l.mode === "light" ? Ie :
|
|
2652
|
+
const i = { ...l.mode === "light" ? Ie : Ke, ...l.colors };
|
|
2646
2653
|
e.push({
|
|
2647
2654
|
name: l.name,
|
|
2648
2655
|
mode: l.mode,
|
|
@@ -2651,21 +2658,21 @@ function On(o, t) {
|
|
|
2651
2658
|
}
|
|
2652
2659
|
if (n) {
|
|
2653
2660
|
const l = {
|
|
2654
|
-
activeTheme:
|
|
2661
|
+
activeTheme: D(n),
|
|
2655
2662
|
themes: e
|
|
2656
2663
|
};
|
|
2657
|
-
|
|
2664
|
+
An(e), te(l.activeTheme, zn, { immediate: !0 }), o.provide(ge, l);
|
|
2658
2665
|
}
|
|
2659
2666
|
}
|
|
2660
|
-
function
|
|
2667
|
+
function zn(o) {
|
|
2661
2668
|
const t = document.documentElement, n = Array.from(t.classList).filter((l) => !l.startsWith("q-theme"));
|
|
2662
2669
|
t.className = n.join(" "), t.classList.add(`q-theme--${o}`);
|
|
2663
2670
|
}
|
|
2664
|
-
const
|
|
2671
|
+
const Un = (o = {}) => Qn({ components: Vn, ...o });
|
|
2665
2672
|
export {
|
|
2666
|
-
|
|
2667
|
-
|
|
2668
|
-
|
|
2669
|
-
|
|
2670
|
-
|
|
2673
|
+
Vn as components,
|
|
2674
|
+
Un as createFramework,
|
|
2675
|
+
Pn as provideTheme,
|
|
2676
|
+
On as templates,
|
|
2677
|
+
En as useTheme
|
|
2671
2678
|
};
|