@ghentcdh/ui 1.1.1 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ControlWrapper-DejmeYzV.js +1 -0
- package/ControlWrapper-DqO2d36v.js +152 -0
- package/Markdown-DcpBYoNe.js +1 -0
- package/Markdown-Dj1gzJJq.js +59 -0
- package/button/Btn.properties.d.ts +6 -2
- package/button/btn.vue.d.ts +15 -5
- package/const/colors.d.ts +2 -1
- package/drawer/drawer.properties.d.ts +4 -0
- package/drawer/drawer.vue.d.ts +9 -0
- package/filter/filter.vue.d.ts +1 -1
- package/form/Checkbox.properties.d.ts +14 -1
- package/form/Checkbox.vue.d.ts +41 -8
- package/form/Input.properties.d.ts +18 -1
- package/form/Input.vue.d.ts +50 -8
- package/form/InputNumber.properties.d.ts +14 -1
- package/form/InputNumber.vue.d.ts +41 -8
- package/form/Textarea.properties.d.ts +26 -1
- package/form/Textarea.vue.d.ts +68 -8
- package/form/core/ControlWrapper.properties.d.ts +54 -1
- package/form/core/ControlWrapper.vue.d.ts +42 -8
- package/form/core/properties.d.ts +2 -16
- package/form/core/styles.d.ts +1 -1
- package/form/core/utils/style.d.ts +3 -3
- package/form/index.d.ts +273 -1
- package/form/select/AutoComplete.properties.d.ts +27 -2
- package/form/select/AutoComplete.vue.d.ts +75 -15
- package/form/select/ListResults.properties.d.ts +7 -1
- package/form/select/ListResults.vue.d.ts +12 -3
- package/form/select/MultiSelect.vue.d.ts +73 -13
- package/form/select/SelectComponent.vue.d.ts +61 -10
- package/form/select/SelectWrapper.properties.d.ts +57 -9
- package/form/select/SelectWrapper.vue.d.ts +99 -17
- package/form/text/Markdown.vue.d.ts +41 -8
- package/form/text/MarkdownComponent.properties.d.ts +14 -1
- package/form/text/MarkdownFallback.vue.d.ts +267 -0
- package/icons/icon-list.d.ts +3 -1
- package/index.css +3 -1
- package/index.d.ts +1 -0
- package/index.js +2 -2
- package/index.mjs +2318 -2359
- package/modal/modal.vue.d.ts +1 -0
- package/package.json +26 -16
- package/table/cells/text.cell.vue.d.ts +1 -1
- package/table/column.model.d.ts +6 -0
- package/table/header/sort.header.properties.d.ts +1 -1
- package/table/header/sort.header.vue.d.ts +2 -2
- package/table/index.d.ts +2 -0
- package/table/pagination.component.properties.d.ts +5 -0
- package/table/pagination.component.vue.d.ts +9 -0
- package/table/table.component.properties.d.ts +4 -0
- package/table/table.component.vue.d.ts +9 -0
- package/table/table.model.d.ts +4 -1
- package/testing.js +1 -1
- package/testing.mjs +338 -419
- package/test-utils/withSetup.d.ts +0 -4
package/index.mjs
CHANGED
|
@@ -1,2372 +1,2331 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
ChevronRight: Je,
|
|
21
|
-
ChevronLeft: Ze,
|
|
22
|
-
ChevronDown: Xe,
|
|
23
|
-
ChevronUp: Ge,
|
|
24
|
-
DblChevronLeft: We,
|
|
25
|
-
DblChevronRight: He,
|
|
26
|
-
Language: Ue,
|
|
27
|
-
Check: Ke,
|
|
28
|
-
View: Fe,
|
|
29
|
-
Text: je,
|
|
30
|
-
Link: qe
|
|
31
|
-
}, mt = {
|
|
32
|
-
icon: { type: [String, Object, Function] },
|
|
33
|
-
size: { type: String }
|
|
34
|
-
}, q = /* @__PURE__ */ k({
|
|
35
|
-
__name: "icon",
|
|
36
|
-
props: mt,
|
|
37
|
-
setup(e) {
|
|
38
|
-
const t = e, o = v(() => t.icon ? typeof t.icon == "string" ? ft[t.icon] : t.icon : null);
|
|
39
|
-
return (n, l) => o.value ? (r(), y(ne(o.value), {
|
|
40
|
-
key: 0,
|
|
41
|
-
"aria-hidden": "true",
|
|
42
|
-
class: $([
|
|
43
|
-
{
|
|
44
|
-
"w-full h-full": !n.size,
|
|
45
|
-
"w-2 h-2": n.size === "xs",
|
|
46
|
-
"w-4 h-4": n.size === "sm",
|
|
47
|
-
"w-6 h-6": n.size === "lg",
|
|
48
|
-
"w-8 h-8": n.size === "xl"
|
|
49
|
-
}
|
|
50
|
-
])
|
|
51
|
-
}, null, 8, ["class"])) : _("", !0);
|
|
52
|
-
}
|
|
53
|
-
}), bt = { class: "dropdown dropdown-end" }, gt = {
|
|
54
|
-
tabindex: "0",
|
|
55
|
-
role: "menu",
|
|
56
|
-
class: "menu dropdown-content bg-white z-1 mt-4 p-2 shadow-sm"
|
|
57
|
-
}, vt = { class: "min-w-max flex-no-wrap text-black" }, pe = /* @__PURE__ */ k({
|
|
58
|
-
__name: "sub-menu",
|
|
59
|
-
props: {
|
|
60
|
-
label: {},
|
|
61
|
-
items: {},
|
|
62
|
-
action: { type: Function },
|
|
63
|
-
disabled: { type: Boolean },
|
|
64
|
-
btnClass: {},
|
|
65
|
-
disableArrow: { type: Boolean }
|
|
66
|
-
},
|
|
67
|
-
setup(e) {
|
|
68
|
-
return (t, o) => (r(), f("div", bt, [
|
|
69
|
-
u("div", {
|
|
70
|
-
tabindex: "0",
|
|
71
|
-
role: "button",
|
|
72
|
-
"aria-haspopup": "menu",
|
|
73
|
-
class: $([e.btnClass, "btn btn-ghost text-right flex-nowrap flex"])
|
|
74
|
-
}, [
|
|
75
|
-
u("span", null, w(e.label), 1),
|
|
76
|
-
e.disableArrow ? _("", !0) : (r(), y(g(q), {
|
|
77
|
-
key: 0,
|
|
78
|
-
icon: g(R).ChevronDown,
|
|
79
|
-
size: "sm"
|
|
80
|
-
}, null, 8, ["icon"]))
|
|
81
|
-
], 2),
|
|
82
|
-
u("ul", gt, [
|
|
83
|
-
u("li", vt, [
|
|
84
|
-
(r(!0), f(L, null, M(e.items, (n) => (r(), y(Pe, B({
|
|
85
|
-
key: n.label
|
|
86
|
-
}, { ref_for: !0 }, n), null, 16))), 128))
|
|
87
|
-
])
|
|
88
|
-
])
|
|
89
|
-
]));
|
|
90
|
-
}
|
|
91
|
-
}), oe = "btn btn-ghost text-left justify-between min-w-max font-normal", Pe = /* @__PURE__ */ k({
|
|
92
|
-
__name: "menu-item",
|
|
93
|
-
props: {
|
|
94
|
-
label: {},
|
|
95
|
-
items: {},
|
|
96
|
-
action: {},
|
|
97
|
-
disabled: { type: Boolean, default: !1 }
|
|
98
|
-
},
|
|
99
|
-
setup(e) {
|
|
100
|
-
const t = e, o = v(() => !t.disabled && t.action && "routerLink" in t.action), n = v(() => !t.disabled && t.action), l = v(() => t.items?.length), a = v(() => {
|
|
101
|
-
const d = t.action;
|
|
102
|
-
return d && "routerLink" in d && "params" in d ? {
|
|
103
|
-
name: d.routerLink,
|
|
104
|
-
params: d.params
|
|
105
|
-
} : "";
|
|
106
|
-
}), c = () => {
|
|
107
|
-
t.action?.();
|
|
108
|
-
};
|
|
109
|
-
return (d, p) => {
|
|
110
|
-
const i = ce("RouterLink");
|
|
111
|
-
return l.value ? (r(), y(pe, B({ key: 0 }, t, { "btn-class": oe }), null, 16)) : o.value ? (r(), y(i, {
|
|
112
|
-
key: 1,
|
|
113
|
-
to: a.value,
|
|
114
|
-
class: $(oe),
|
|
115
|
-
onClick: c
|
|
116
|
-
}, {
|
|
117
|
-
default: S(() => [
|
|
118
|
-
E(w(e.label), 1)
|
|
119
|
-
]),
|
|
120
|
-
_: 1
|
|
121
|
-
}, 8, ["to"])) : n.value ? (r(), f("button", {
|
|
122
|
-
key: 2,
|
|
123
|
-
class: $(oe),
|
|
124
|
-
onClick: c
|
|
125
|
-
}, w(e.label), 1)) : (r(), f("div", {
|
|
126
|
-
key: 3,
|
|
127
|
-
class: $([oe, { "btn-disabled": e.disabled }])
|
|
128
|
-
}, w(e.label), 3));
|
|
129
|
-
};
|
|
130
|
-
}
|
|
131
|
-
}), ht = { class: "navbar bg-base-100 shadow-sm" }, yt = { class: "flex-1" }, wt = {
|
|
132
|
-
key: 0,
|
|
133
|
-
class: "breadcrumbs text-sm"
|
|
134
|
-
}, kt = { class: "flex grow justify-end px-2" }, _t = { class: "flex items-stretch" }, wn = /* @__PURE__ */ k({
|
|
135
|
-
__name: "menu",
|
|
136
|
-
props: {
|
|
137
|
-
menu: {},
|
|
138
|
-
breadcrumbs: {}
|
|
139
|
-
},
|
|
140
|
-
setup(e) {
|
|
141
|
-
return (t, o) => {
|
|
142
|
-
const n = ce("RouterLink");
|
|
143
|
-
return r(), f("nav", ht, [
|
|
144
|
-
u("div", yt, [
|
|
145
|
-
e.breadcrumbs ? (r(), f("div", wt, [
|
|
146
|
-
u("ul", null, [
|
|
147
|
-
(r(!0), f(L, null, M(e.breadcrumbs, (l) => (r(), f("li", {
|
|
148
|
-
key: l.label
|
|
149
|
-
}, [
|
|
150
|
-
l.routerLink ? (r(), y(n, {
|
|
151
|
-
key: 0,
|
|
152
|
-
to: { name: l.routerLink, params: l.params },
|
|
153
|
-
role: "navigation",
|
|
154
|
-
"aria-label": l.label
|
|
155
|
-
}, {
|
|
156
|
-
default: S(() => [
|
|
157
|
-
E(w(l.label), 1)
|
|
158
|
-
]),
|
|
159
|
-
_: 2
|
|
160
|
-
}, 1032, ["to", "aria-label"])) : (r(), f(L, { key: 1 }, [
|
|
161
|
-
E(w(l.label), 1)
|
|
162
|
-
], 64))
|
|
163
|
-
]))), 128))
|
|
164
|
-
])
|
|
165
|
-
])) : _("", !0)
|
|
166
|
-
]),
|
|
167
|
-
u("div", kt, [
|
|
168
|
-
u("div", _t, [
|
|
169
|
-
(r(!0), f(L, null, M(e.menu, (l) => (r(), y(Pe, B({
|
|
170
|
-
key: l.label
|
|
171
|
-
}, { ref_for: !0 }, l), null, 16))), 128))
|
|
172
|
-
])
|
|
173
|
-
])
|
|
174
|
-
]);
|
|
175
|
-
};
|
|
176
|
-
}
|
|
177
|
-
}), kn = /* @__PURE__ */ k({
|
|
178
|
-
__name: "dropdown",
|
|
179
|
-
props: {
|
|
180
|
-
items: {}
|
|
181
|
-
},
|
|
182
|
-
setup(e) {
|
|
183
|
-
const t = x(!0);
|
|
184
|
-
return (o, n) => (r(), y(pe, {
|
|
185
|
-
items: e.items,
|
|
186
|
-
label: "test",
|
|
187
|
-
open: t.value,
|
|
188
|
-
"btn-class": "",
|
|
189
|
-
"disable-arrow": !0
|
|
190
|
-
}, null, 8, ["items", "open"]));
|
|
191
|
-
}
|
|
192
|
-
}), $t = {
|
|
193
|
-
modalTitle: { type: String, required: !0 },
|
|
194
|
-
buttonLabel: { type: String },
|
|
195
|
-
buttonSaveLabel: { type: String },
|
|
196
|
-
data: { default: void 0 },
|
|
197
|
-
open: { type: Boolean, default: !1 },
|
|
198
|
-
disableClose: { type: Boolean, default: !1 },
|
|
199
|
-
width: { type: String, default: "sm" }
|
|
200
|
-
}, Ct = ["closeModal"], xt = 'a[href], button:not([disabled]), textarea:not([disabled]), input:not([disabled]), select:not([disabled]), [tabindex]:not([tabindex="-1"])', ke = (e) => Array.from(e.querySelectorAll(xt)), Lt = ({
|
|
201
|
-
containerRef: e,
|
|
202
|
-
isActive: t,
|
|
203
|
-
onEscape: o,
|
|
204
|
-
restoreFocus: n = !0
|
|
205
|
-
}) => {
|
|
206
|
-
let l = null;
|
|
207
|
-
const a = (p) => {
|
|
208
|
-
const i = e.value;
|
|
209
|
-
if (!i) return;
|
|
210
|
-
if (p.key === "Escape") {
|
|
211
|
-
o?.();
|
|
212
|
-
return;
|
|
213
|
-
}
|
|
214
|
-
if (p.key !== "Tab") return;
|
|
215
|
-
const s = ke(i);
|
|
216
|
-
if (s.length === 0) return;
|
|
217
|
-
const m = s[0], b = s[s.length - 1];
|
|
218
|
-
p.shiftKey ? document.activeElement === m && (p.preventDefault(), b.focus()) : document.activeElement === b && (p.preventDefault(), m.focus());
|
|
219
|
-
}, c = () => {
|
|
220
|
-
const p = e.value;
|
|
221
|
-
if (!p) return;
|
|
222
|
-
l = document.activeElement, document.addEventListener("keydown", a);
|
|
223
|
-
const i = ke(p);
|
|
224
|
-
i.length > 0 && i[0].focus();
|
|
225
|
-
}, d = () => {
|
|
226
|
-
document.removeEventListener("keydown", a), n && l && (l.focus(), l = null);
|
|
227
|
-
};
|
|
228
|
-
j(t, (p) => {
|
|
229
|
-
p ? c() : d();
|
|
230
|
-
}, { immediate: !0 }), _e(() => {
|
|
231
|
-
d();
|
|
232
|
-
});
|
|
233
|
-
}, St = {
|
|
234
|
-
xs: "max-w-xs w-[50VW]",
|
|
235
|
-
sm: "max-w-sm w-[50VW]",
|
|
236
|
-
lg: "max-w-2xl w-[80VW]",
|
|
237
|
-
xl: "max-w-[80VW] w-[80VW]"
|
|
238
|
-
}, Pt = {
|
|
239
|
-
xs: "btn-xs",
|
|
240
|
-
sm: "btn-sm",
|
|
241
|
-
lg: "btn-sm",
|
|
242
|
-
xl: "btn"
|
|
243
|
-
}, Mt = {
|
|
244
|
-
xs: "badge-xs text-xxs",
|
|
245
|
-
sm: "badge-sm text-xs",
|
|
246
|
-
lg: "badge-sm text-xs",
|
|
247
|
-
xl: "badge text-xs"
|
|
248
|
-
}, Bt = { class: "flex justify-end gap-2 pt-2 mt-2 border-t border-gray-300 shrink-0" }, Vt = /* @__PURE__ */ k({
|
|
249
|
-
__name: "modal",
|
|
250
|
-
props: $t,
|
|
251
|
-
emits: Ct,
|
|
252
|
-
setup(e, { expose: t, emit: o }) {
|
|
253
|
-
const n = e, l = `modal_${de()}`, a = `${l}_title`, c = `${l}_content`, d = x(null), p = x(!1), i = o, s = () => {
|
|
254
|
-
d.value?.showModal(), p.value = !0;
|
|
255
|
-
}, m = () => {
|
|
256
|
-
d.value?.close(), p.value = !1, i("closeModal");
|
|
257
|
-
}, b = () => {
|
|
258
|
-
n.disableClose || m();
|
|
259
|
-
};
|
|
260
|
-
return Lt({
|
|
261
|
-
containerRef: d,
|
|
262
|
-
isActive: p,
|
|
263
|
-
onEscape: () => {
|
|
264
|
-
n.disableClose || m();
|
|
265
|
-
}
|
|
266
|
-
}), t({ closeModal: m, openModal: s }), j(
|
|
267
|
-
() => n.open,
|
|
268
|
-
() => {
|
|
269
|
-
n.open ? s() : m();
|
|
270
|
-
}
|
|
271
|
-
), $e(() => {
|
|
272
|
-
n.open && s();
|
|
273
|
-
}), (h, D) => (r(), f("dialog", {
|
|
274
|
-
ref_key: "dialogRef",
|
|
275
|
-
ref: d,
|
|
276
|
-
class: "modal",
|
|
277
|
-
role: "dialog",
|
|
278
|
-
"aria-modal": "true",
|
|
279
|
-
"aria-labelledby": a,
|
|
280
|
-
"aria-describedby": c,
|
|
281
|
-
onCancel: le(b, ["prevent"])
|
|
282
|
-
}, [
|
|
283
|
-
u("div", {
|
|
284
|
-
class: $([
|
|
285
|
-
"modal-box bg-white min-h-0 max-h-[90vh] flex flex-col overflow-hidden",
|
|
286
|
-
g(St)[h.width]
|
|
287
|
-
])
|
|
288
|
-
}, [
|
|
289
|
-
h.disableClose ? _("", !0) : (r(), f("button", {
|
|
290
|
-
key: 0,
|
|
291
|
-
type: "button",
|
|
292
|
-
class: "btn btn-sm btn-circle btn-ghost absolute right-2 top-2",
|
|
293
|
-
"aria-label": "Close",
|
|
294
|
-
onClick: m
|
|
295
|
-
}, " ✕ ")),
|
|
296
|
-
u("h3", {
|
|
297
|
-
id: a,
|
|
298
|
-
class: "font-bold shrink-0"
|
|
299
|
-
}, w(h.modalTitle), 1),
|
|
300
|
-
u("div", {
|
|
301
|
-
id: c,
|
|
302
|
-
class: "pt-4 flex-1 min-h-0 flex flex-col"
|
|
303
|
-
}, [
|
|
304
|
-
P(h.$slots, "content")
|
|
305
|
-
]),
|
|
306
|
-
u("div", Bt, [
|
|
307
|
-
P(h.$slots, "actions")
|
|
308
|
-
])
|
|
309
|
-
], 2)
|
|
310
|
-
], 544));
|
|
311
|
-
}
|
|
312
|
-
});
|
|
313
|
-
var fe = /* @__PURE__ */ ((e) => (e.button = "button", e.submit = "submit", e.reset = "reset", e))(fe || {}), Me = /* @__PURE__ */ ((e) => (e.a = "a", e.button = "button", e))(Me || {}), z = /* @__PURE__ */ ((e) => (e.blank = "blank", e.primary = "primary", e.secondary = "secondary", e.error = "error", e))(z || {});
|
|
314
|
-
const At = {
|
|
315
|
-
blank: "btn-ghost",
|
|
316
|
-
primary: "btn-primary",
|
|
317
|
-
secondary: "btn-soft btn-primary",
|
|
318
|
-
error: "btn-error"
|
|
319
|
-
}, Ot = {
|
|
320
|
-
blank: "badge-ghost",
|
|
321
|
-
primary: "badge-primary",
|
|
322
|
-
secondary: "badge-soft badge-primary",
|
|
323
|
-
error: "badge-error"
|
|
324
|
-
}, It = {
|
|
325
|
-
href: { type: String },
|
|
326
|
-
disabled: { type: Boolean, default: !1 },
|
|
327
|
-
tooltip: { type: String },
|
|
328
|
-
as: { type: String, default: Me.button },
|
|
329
|
-
icon: { type: [String, Object, Function] },
|
|
330
|
-
type: { type: String, default: fe.button },
|
|
331
|
-
outline: { type: Boolean, default: !1 },
|
|
332
|
-
color: { type: String, default: z.primary },
|
|
333
|
-
size: { type: String, default: "sm" },
|
|
334
|
-
square: { type: Boolean, default: !1 }
|
|
335
|
-
}, Dt = ["click"], Rt = {
|
|
336
|
-
icon: { type: [String, Object, Function] },
|
|
337
|
-
type: { type: String, default: fe.button },
|
|
338
|
-
color: { type: String, default: z.primary },
|
|
339
|
-
disabled: { type: Boolean, default: !1 },
|
|
340
|
-
size: { type: String, default: "sm" }
|
|
341
|
-
}, Tt = ["click"], N = /* @__PURE__ */ k({
|
|
342
|
-
__name: "btn",
|
|
343
|
-
props: It,
|
|
344
|
-
emits: Dt,
|
|
345
|
-
setup(e, { emit: t }) {
|
|
346
|
-
const o = e, n = t;
|
|
347
|
-
return (l, a) => (r(), y(ne(o.as), {
|
|
348
|
-
class: $([
|
|
349
|
-
"btn p-1 flex justify-center flex-nowrap",
|
|
350
|
-
g(At)[o.color],
|
|
351
|
-
g(Pt)[o.size],
|
|
352
|
-
{ "btn-outline": o.outline, "btn-square": o.square, tooltip: o.tooltip }
|
|
353
|
-
]),
|
|
354
|
-
href: o.href,
|
|
355
|
-
type: o.type,
|
|
356
|
-
disabled: o.disabled,
|
|
357
|
-
"data-tip": o.tooltip,
|
|
358
|
-
onClick: a[0] || (a[0] = (c) => n("click"))
|
|
359
|
-
}, {
|
|
360
|
-
default: S(() => [
|
|
361
|
-
o.icon ? (r(), y(g(q), {
|
|
362
|
-
key: 0,
|
|
363
|
-
icon: o.icon,
|
|
364
|
-
size: o.size
|
|
365
|
-
}, null, 8, ["icon", "size"])) : _("", !0),
|
|
366
|
-
P(l.$slots, "default")
|
|
367
|
-
]),
|
|
368
|
-
_: 3
|
|
369
|
-
}, 8, ["class", "href", "type", "disabled", "data-tip"]));
|
|
370
|
-
}
|
|
371
|
-
}), Et = ["type", "disabled"], _n = /* @__PURE__ */ k({
|
|
372
|
-
__name: "btn-badge",
|
|
373
|
-
props: Rt,
|
|
374
|
-
emits: Tt,
|
|
375
|
-
setup(e, { emit: t }) {
|
|
376
|
-
const o = e, n = t;
|
|
377
|
-
return (l, a) => (r(), f("button", {
|
|
378
|
-
class: $(["badge gap-1", g(Mt)[o.size], g(Ot)[o.color]]),
|
|
379
|
-
type: o.type,
|
|
380
|
-
disabled: o.disabled,
|
|
381
|
-
onClick: a[0] || (a[0] = (c) => n("click"))
|
|
382
|
-
}, [
|
|
383
|
-
P(l.$slots, "default"),
|
|
384
|
-
o.icon ? (r(), y(g(q), {
|
|
385
|
-
key: 0,
|
|
386
|
-
icon: o.icon,
|
|
387
|
-
size: o.size
|
|
388
|
-
}, null, 8, ["icon", "size"])) : _("", !0)
|
|
389
|
-
], 10, Et));
|
|
390
|
-
}
|
|
391
|
-
}), zt = /* @__PURE__ */ k({
|
|
392
|
-
__name: "confirmModal",
|
|
393
|
-
props: {
|
|
394
|
-
title: {},
|
|
395
|
-
message: {},
|
|
396
|
-
confirmLabel: { default: "Ok" },
|
|
397
|
-
cancelLabel: { default: "Cancel" }
|
|
398
|
-
},
|
|
399
|
-
emits: ["closeModal"],
|
|
400
|
-
setup(e, { emit: t }) {
|
|
401
|
-
const o = t, n = (l) => {
|
|
402
|
-
o("closeModal", { confirmed: l });
|
|
403
|
-
};
|
|
404
|
-
return (l, a) => (r(), y(Vt, {
|
|
405
|
-
"modal-title": e.title,
|
|
406
|
-
open: !0,
|
|
407
|
-
"disable-close": !0
|
|
408
|
-
}, {
|
|
409
|
-
content: S(() => [
|
|
410
|
-
E(w(e.message), 1)
|
|
411
|
-
]),
|
|
412
|
-
actions: S(() => [
|
|
413
|
-
V(g(N), {
|
|
414
|
-
color: g(z).secondary,
|
|
415
|
-
outline: !0,
|
|
416
|
-
"aria-label": e.cancelLabel,
|
|
417
|
-
onClick: a[0] || (a[0] = (c) => n(!1))
|
|
418
|
-
}, {
|
|
419
|
-
default: S(() => [
|
|
420
|
-
E(w(e.cancelLabel), 1)
|
|
421
|
-
]),
|
|
422
|
-
_: 1
|
|
423
|
-
}, 8, ["color", "aria-label"]),
|
|
424
|
-
V(g(N), {
|
|
425
|
-
"aria-label": e.confirmLabel,
|
|
426
|
-
onClick: a[1] || (a[1] = (c) => n(!0))
|
|
427
|
-
}, {
|
|
428
|
-
default: S(() => [
|
|
429
|
-
E(w(e.confirmLabel), 1)
|
|
430
|
-
]),
|
|
431
|
-
_: 1
|
|
432
|
-
}, 8, ["aria-label"])
|
|
433
|
-
]),
|
|
434
|
-
_: 1
|
|
435
|
-
}, 8, ["modal-title"]));
|
|
436
|
-
}
|
|
437
|
-
});
|
|
438
|
-
class me {
|
|
439
|
-
constructor() {
|
|
440
|
-
this.showModal = x(!1), this.modals = [];
|
|
441
|
-
}
|
|
442
|
-
openModal(t) {
|
|
443
|
-
const o = t.props.onClose, n = de(), l = t;
|
|
444
|
-
t.props.onClose = (a) => {
|
|
445
|
-
o(a), this.closeModal(n);
|
|
446
|
-
}, l.id = n, this.modals = [...this.modals, l], this.showModal.value = Date.now();
|
|
447
|
-
}
|
|
448
|
-
closeModal(t) {
|
|
449
|
-
this.modals = this.modals.filter((o) => o.id !== t), this.showModal.value = Date.now();
|
|
450
|
-
}
|
|
451
|
-
static showConfirm(t) {
|
|
452
|
-
this.getInstance().openModal({
|
|
453
|
-
component: zt,
|
|
454
|
-
props: t
|
|
455
|
-
});
|
|
456
|
-
}
|
|
457
|
-
static openModal(t) {
|
|
458
|
-
this.getInstance().openModal(t);
|
|
459
|
-
}
|
|
460
|
-
static getInstance() {
|
|
461
|
-
return this.instance || (this.instance = new me()), this.instance;
|
|
462
|
-
}
|
|
463
|
-
static closeAll() {
|
|
464
|
-
this.instance.closeAll();
|
|
465
|
-
}
|
|
466
|
-
closeAll() {
|
|
467
|
-
this.modals = [], this.showModal.value = !1;
|
|
468
|
-
}
|
|
1
|
+
import { a as e, c as t, i as n, l as r, n as i, o as a, r as o, s, t as c } from "./ControlWrapper-DqO2d36v.js";
|
|
2
|
+
import { Fragment as l, Teleport as u, Transition as d, camelize as f, computed as p, createBlock as m, createCommentVNode as h, createElementBlock as g, createElementVNode as _, createTextVNode as v, createVNode as y, defineAsyncComponent as b, defineComponent as x, getCurrentInstance as S, guardReactiveProps as C, h as w, mergeModels as T, mergeProps as E, nextTick as D, normalizeClass as O, normalizeProps as k, normalizeStyle as A, onMounted as ee, onUnmounted as te, openBlock as j, ref as M, renderList as N, renderSlot as P, resolveComponent as ne, resolveDynamicComponent as F, toDisplayString as I, toHandlerKey as L, toRef as re, unref as R, useAttrs as ie, useModel as z, useSlots as ae, vModelCheckbox as oe, vModelDynamic as se, vModelText as ce, watch as B, withCtx as V, withDirectives as H, withModifiers as U } from "vue";
|
|
3
|
+
import { RouterLink as le } from "vue-router";
|
|
4
|
+
//#region src/icons/icon-list.ts
|
|
5
|
+
function W(e) {
|
|
6
|
+
return x({ render() {
|
|
7
|
+
return w("svg", {
|
|
8
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
9
|
+
fill: "none",
|
|
10
|
+
viewBox: "0 0 24 24",
|
|
11
|
+
"stroke-width": "1.5",
|
|
12
|
+
stroke: "currentColor",
|
|
13
|
+
"aria-hidden": "true"
|
|
14
|
+
}, e.map((e) => w("path", {
|
|
15
|
+
"stroke-linecap": "round",
|
|
16
|
+
"stroke-linejoin": "round",
|
|
17
|
+
d: e
|
|
18
|
+
})));
|
|
19
|
+
} });
|
|
469
20
|
}
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
}
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
}
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
}
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
21
|
+
var ue = W(["M3.75 6.75h16.5M3.75 12h16.5m-16.5 5.25h16.5"]), de = W(["M3 4.5h14.25M3 9h9.75M3 13.5h9.75m4.5-4.5v12m0 0-3.75-3.75M17.25 21 21 17.25"]), fe = W(["M3 4.5h14.25M3 9h9.75M3 13.5h5.25m5.25-.75L17.25 9m0 0L21 12.75M17.25 9v12"]), pe = W(["m4.5 12.75 6 6 9-13.5"]), me = W(["m18.75 4.5-7.5 7.5 7.5 7.5m-6-15L5.25 12l7.5 7.5"]), he = W(["m5.25 4.5 7.5 7.5-7.5 7.5m6-15 7.5 7.5-7.5 7.5"]), ge = W(["m19.5 8.25-7.5 7.5-7.5-7.5"]), _e = W(["M15.75 19.5 8.25 12l7.5-7.5"]), ve = W(["m8.25 4.5 7.5 7.5-7.5 7.5"]), ye = W(["m4.5 15.75 7.5-7.5 7.5 7.5"]), be = W(["M19.5 14.25v-2.625a3.375 3.375 0 0 0-3.375-3.375h-1.5A1.125 1.125 0 0 1 13.5 7.125v-1.5a3.375 3.375 0 0 0-3.375-3.375H8.25m0 12.75h7.5m-7.5 3H12M10.5 2.25H5.625c-.621 0-1.125.504-1.125 1.125v17.25c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 0 0-9-9Z"]), xe = W(["M2.036 12.322a1.012 1.012 0 0 1 0-.639C3.423 7.51 7.36 4.5 12 4.5c4.638 0 8.573 3.007 9.963 7.178.07.207.07.431 0 .639C20.577 16.49 16.64 19.5 12 19.5c-4.638 0-8.573-3.007-9.963-7.178Z", "M15 12a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"]), Se = W(["M12 3c2.755 0 5.455.232 8.083.678.533.09.917.556.917 1.096v1.044a2.25 2.25 0 0 1-.659 1.591l-5.432 5.432a2.25 2.25 0 0 0-.659 1.591v2.927a2.25 2.25 0 0 1-1.244 2.013L9.75 21v-6.568a2.25 2.25 0 0 0-.659-1.591L3.659 7.409A2.25 2.25 0 0 1 3 5.818V4.774c0-.54.384-1.006.917-1.096A48.32 48.32 0 0 1 12 3Z"]), Ce = W(["m10.5 21 5.25-11.25L21 21m-9-3h7.5M3 5.621a48.474 48.474 0 0 1 6-.371m0 0c1.12 0 2.233.038 3.334.114M9 5.25V3m3.334 2.364C11.176 10.658 7.69 15.08 3 17.502m9.334-12.138c.896.061 1.785.147 2.666.257m-4.589 8.495a18.023 18.023 0 0 1-3.827-5.802"]), we = W(["M13.19 8.688a4.5 4.5 0 0 1 1.242 7.244l-4.5 4.5a4.5 4.5 0 0 1-6.364-6.364l1.757-1.757m13.35-.622 1.757-1.757a4.5 4.5 0 0 0-6.364-6.364l-4.5 4.5a4.5 4.5 0 0 0 1.242 7.244"]), Te = W(["m18.375 12.739-7.693 7.693a4.5 4.5 0 0 1-6.364-6.364l10.94-10.94A3 3 0 1 1 19.5 7.372L8.552 18.32m.009-.01-.01.01m5.699-9.941-7.81 7.81a1.5 1.5 0 0 0 2.112 2.13"]), Ee = W(["m16.862 4.487 1.687-1.688a1.875 1.875 0 1 1 2.652 2.652L10.582 16.07a4.5 4.5 0 0 1-1.897 1.13L6 18l.8-2.685a4.5 4.5 0 0 1 1.13-1.897l8.932-8.931Zm0 0L19.5 7.125M18 14v4.75A2.25 2.25 0 0 1 15.75 21H5.25A2.25 2.25 0 0 1 3 18.75V8.25A2.25 2.25 0 0 1 5.25 6H10"]), De = W(["M12 9v6m3-3H9m12 0a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z"]), Oe = W(["m14.74 9-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 0 1-2.244 2.077H8.084a2.25 2.25 0 0 1-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 0 0-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 0 1 3.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 0 0-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 0 0-7.5 0"]), ke = W(["M6 18 18 6M6 6l12 12"]), Ae = W(["M16.023 9.348h4.992v-.001M2.985 19.644v-4.992m0 0h4.992m-4.993 0 3.181 3.183a8.25 8.25 0 0 0 13.803-3.7M4.031 9.865a8.25 8.25 0 0 1 13.803-3.7l3.181 3.182m0-4.991v4.99"]), je = W(["M3 4a1 1 0 011-1h16a1 1 0 011 1v2a1 1 0 01-.293.707L13 13.414V19a1 1 0 01-.553.894l-4 2A1 1 0 017 21v-7.586L3.293 6.707A1 1 0 013 6V4z"]), G = /* @__PURE__ */ function(e) {
|
|
22
|
+
return e.Edit = "Edit", e.Delete = "Delete", e.BarsArrowDown = "BarsArrowDown", e.BarsArrowUp = "BarsArrowUp", e.Funnel = "Funnel", e.Close = "Close", e.Plus = "Plus", e.PaperClip = "PaperClip", e.Hamburger = "Hamburger", e.ChevronRight = "ChevronRight", e.ChevronLeft = "ChevronLeft", e.ChevronDown = "ChevronDown", e.ChevronUp = "ChevronUp", e.DblChevronLeft = "DblChevronLeft", e.DblChevronRight = "DblChevronRight", e.Language = "Language", e.Check = "Check", e.View = "View", e.Text = "Text", e.Link = "Link", e.Filter = "Filter", e.Sync = "Sync", e;
|
|
23
|
+
}({}), Me = {
|
|
24
|
+
Edit: Ee,
|
|
25
|
+
Delete: Oe,
|
|
26
|
+
BarsArrowDown: de,
|
|
27
|
+
BarsArrowUp: fe,
|
|
28
|
+
Funnel: Se,
|
|
29
|
+
Close: ke,
|
|
30
|
+
Plus: De,
|
|
31
|
+
PaperClip: Te,
|
|
32
|
+
Hamburger: ue,
|
|
33
|
+
ChevronRight: ve,
|
|
34
|
+
ChevronLeft: _e,
|
|
35
|
+
ChevronDown: ge,
|
|
36
|
+
ChevronUp: ye,
|
|
37
|
+
DblChevronLeft: me,
|
|
38
|
+
DblChevronRight: he,
|
|
39
|
+
Language: Ce,
|
|
40
|
+
Check: pe,
|
|
41
|
+
View: xe,
|
|
42
|
+
Text: be,
|
|
43
|
+
Link: we,
|
|
44
|
+
Filter: je,
|
|
45
|
+
Sync: Ae
|
|
46
|
+
}, Ne = {
|
|
47
|
+
icon: { type: [
|
|
48
|
+
String,
|
|
49
|
+
Object,
|
|
50
|
+
Function
|
|
51
|
+
] },
|
|
52
|
+
size: { type: String }
|
|
53
|
+
}, K = /* @__PURE__ */ x({
|
|
54
|
+
__name: "icon",
|
|
55
|
+
props: Ne,
|
|
56
|
+
setup(e) {
|
|
57
|
+
let t = e, n = p(() => t.icon ? typeof t.icon == "string" ? Me[t.icon] : t.icon : null);
|
|
58
|
+
return (e, t) => n.value ? (j(), m(F(n.value), {
|
|
59
|
+
key: 0,
|
|
60
|
+
"aria-hidden": "true",
|
|
61
|
+
class: O([{
|
|
62
|
+
"w-full h-full": !e.size,
|
|
63
|
+
"w-2 h-2": e.size === "xs",
|
|
64
|
+
"w-4 h-4": e.size === "sm",
|
|
65
|
+
"w-6 h-6": e.size === "lg",
|
|
66
|
+
"w-8 h-8": e.size === "xl"
|
|
67
|
+
}])
|
|
68
|
+
}, null, 8, ["class"])) : h("", !0);
|
|
69
|
+
}
|
|
70
|
+
}), Pe = { class: "dropdown dropdown-end" }, Fe = {
|
|
71
|
+
tabindex: "0",
|
|
72
|
+
role: "menu",
|
|
73
|
+
class: "menu dropdown-content bg-white z-1 mt-4 p-2 shadow-sm"
|
|
74
|
+
}, Ie = { class: "min-w-max flex-no-wrap text-black" }, q = /* @__PURE__ */ x({
|
|
75
|
+
__name: "sub-menu",
|
|
76
|
+
props: {
|
|
77
|
+
label: {},
|
|
78
|
+
items: {},
|
|
79
|
+
action: { type: Function },
|
|
80
|
+
disabled: { type: Boolean },
|
|
81
|
+
btnClass: {},
|
|
82
|
+
disableArrow: { type: Boolean }
|
|
83
|
+
},
|
|
84
|
+
setup(e) {
|
|
85
|
+
return (t, n) => (j(), g("div", Pe, [_("div", {
|
|
86
|
+
tabindex: "0",
|
|
87
|
+
role: "button",
|
|
88
|
+
"aria-haspopup": "menu",
|
|
89
|
+
class: O([e.btnClass, "btn btn-ghost text-right flex-nowrap flex"])
|
|
90
|
+
}, [_("span", null, I(e.label), 1), e.disableArrow ? h("", !0) : (j(), m(R(K), {
|
|
91
|
+
key: 0,
|
|
92
|
+
icon: R(G).ChevronDown,
|
|
93
|
+
size: "sm"
|
|
94
|
+
}, null, 8, ["icon"]))], 2), _("ul", Fe, [_("li", Ie, [(j(!0), g(l, null, N(e.items, (e) => (j(), m(Le, E({ key: e.label }, { ref_for: !0 }, e), null, 16))), 128))])])]));
|
|
95
|
+
}
|
|
96
|
+
}), J = "btn btn-ghost text-left justify-between min-w-max font-normal", Le = /* @__PURE__ */ x({
|
|
97
|
+
__name: "menu-item",
|
|
98
|
+
props: {
|
|
99
|
+
label: {},
|
|
100
|
+
items: {},
|
|
101
|
+
action: {},
|
|
102
|
+
disabled: {
|
|
103
|
+
type: Boolean,
|
|
104
|
+
default: !1
|
|
105
|
+
}
|
|
106
|
+
},
|
|
107
|
+
setup(e) {
|
|
108
|
+
let t = e, n = p(() => !t.disabled && t.action && "routerLink" in t.action), r = p(() => !t.disabled && t.action), i = p(() => t.items?.length), a = p(() => {
|
|
109
|
+
let e = t.action;
|
|
110
|
+
return e && "routerLink" in e && "params" in e ? {
|
|
111
|
+
name: e.routerLink,
|
|
112
|
+
params: e.params
|
|
113
|
+
} : "";
|
|
114
|
+
}), o = () => {
|
|
115
|
+
t.action?.();
|
|
116
|
+
};
|
|
117
|
+
return (s, c) => {
|
|
118
|
+
let l = ne("RouterLink");
|
|
119
|
+
return i.value ? (j(), m(q, E({ key: 0 }, t, { "btn-class": J }), null, 16)) : n.value ? (j(), m(l, {
|
|
120
|
+
key: 1,
|
|
121
|
+
to: a.value,
|
|
122
|
+
class: O(J),
|
|
123
|
+
onClick: o
|
|
124
|
+
}, {
|
|
125
|
+
default: V(() => [v(I(e.label), 1)]),
|
|
126
|
+
_: 1
|
|
127
|
+
}, 8, ["to"])) : r.value ? (j(), g("button", {
|
|
128
|
+
key: 2,
|
|
129
|
+
class: O(J),
|
|
130
|
+
onClick: o
|
|
131
|
+
}, I(e.label), 1)) : (j(), g("div", {
|
|
132
|
+
key: 3,
|
|
133
|
+
class: O([J, { "btn-disabled": e.disabled }])
|
|
134
|
+
}, I(e.label), 3));
|
|
135
|
+
};
|
|
136
|
+
}
|
|
137
|
+
}), Re = { class: "navbar bg-base-100 shadow-sm" }, ze = { class: "flex-1" }, Be = {
|
|
138
|
+
key: 0,
|
|
139
|
+
class: "breadcrumbs text-sm"
|
|
140
|
+
}, Ve = { class: "flex grow justify-end px-2" }, He = { class: "flex items-stretch" }, Ue = /* @__PURE__ */ x({
|
|
141
|
+
__name: "menu",
|
|
142
|
+
props: {
|
|
143
|
+
menu: {},
|
|
144
|
+
breadcrumbs: {}
|
|
145
|
+
},
|
|
146
|
+
setup(e) {
|
|
147
|
+
return (t, n) => {
|
|
148
|
+
let r = ne("RouterLink");
|
|
149
|
+
return j(), g("nav", Re, [_("div", ze, [e.breadcrumbs ? (j(), g("div", Be, [_("ul", null, [(j(!0), g(l, null, N(e.breadcrumbs, (e) => (j(), g("li", { key: e.label }, [e.routerLink ? (j(), m(r, {
|
|
150
|
+
key: 0,
|
|
151
|
+
to: {
|
|
152
|
+
name: e.routerLink,
|
|
153
|
+
params: e.params
|
|
154
|
+
},
|
|
155
|
+
role: "navigation",
|
|
156
|
+
"aria-label": e.label
|
|
157
|
+
}, {
|
|
158
|
+
default: V(() => [v(I(e.label), 1)]),
|
|
159
|
+
_: 2
|
|
160
|
+
}, 1032, ["to", "aria-label"])) : (j(), g(l, { key: 1 }, [v(I(e.label), 1)], 64))]))), 128))])])) : h("", !0)]), _("div", Ve, [_("div", He, [(j(!0), g(l, null, N(e.menu, (e) => (j(), m(Le, E({ key: e.label }, { ref_for: !0 }, e), null, 16))), 128))])])]);
|
|
161
|
+
};
|
|
162
|
+
}
|
|
163
|
+
}), We = /* @__PURE__ */ x({
|
|
164
|
+
__name: "dropdown",
|
|
165
|
+
props: { items: {} },
|
|
166
|
+
setup(e) {
|
|
167
|
+
let t = M(!0);
|
|
168
|
+
return (n, r) => (j(), m(q, {
|
|
169
|
+
items: e.items,
|
|
170
|
+
label: "test",
|
|
171
|
+
open: t.value,
|
|
172
|
+
"btn-class": "",
|
|
173
|
+
"disable-arrow": !0
|
|
174
|
+
}, null, 8, ["items", "open"]));
|
|
175
|
+
}
|
|
176
|
+
}), Ge = {
|
|
177
|
+
modalTitle: {
|
|
178
|
+
type: String,
|
|
179
|
+
required: !0
|
|
180
|
+
},
|
|
181
|
+
buttonLabel: { type: String },
|
|
182
|
+
buttonSaveLabel: { type: String },
|
|
183
|
+
data: { default: void 0 },
|
|
184
|
+
open: {
|
|
185
|
+
type: Boolean,
|
|
186
|
+
default: !1
|
|
187
|
+
},
|
|
188
|
+
disableClose: {
|
|
189
|
+
type: Boolean,
|
|
190
|
+
default: !1
|
|
191
|
+
},
|
|
192
|
+
width: {
|
|
193
|
+
type: String,
|
|
194
|
+
default: "sm"
|
|
195
|
+
}
|
|
196
|
+
}, Ke = ["closeModal"], qe = "a[href], button:not([disabled]), textarea:not([disabled]), input:not([disabled]), select:not([disabled]), [tabindex]:not([tabindex=\"-1\"])", Je = (e) => Array.from(e.querySelectorAll(qe)), Ye = ({ containerRef: e, isActive: t, onEscape: n, restoreFocus: r = !0 }) => {
|
|
197
|
+
let i = null, a = (t) => {
|
|
198
|
+
let r = e.value;
|
|
199
|
+
if (!r) return;
|
|
200
|
+
if (t.key === "Escape") {
|
|
201
|
+
n?.();
|
|
202
|
+
return;
|
|
203
|
+
}
|
|
204
|
+
if (t.key !== "Tab") return;
|
|
205
|
+
let i = Je(r);
|
|
206
|
+
if (i.length === 0) return;
|
|
207
|
+
let a = i[0], o = i[i.length - 1];
|
|
208
|
+
t.shiftKey ? document.activeElement === a && (t.preventDefault(), o.focus()) : document.activeElement === o && (t.preventDefault(), a.focus());
|
|
209
|
+
}, o = () => {
|
|
210
|
+
let t = e.value;
|
|
211
|
+
if (!t) return;
|
|
212
|
+
i = document.activeElement, document.addEventListener("keydown", a);
|
|
213
|
+
let n = Je(t);
|
|
214
|
+
n.length > 0 && n[0].focus();
|
|
215
|
+
}, s = () => {
|
|
216
|
+
document.removeEventListener("keydown", a), r && i && (i.focus(), i = null);
|
|
217
|
+
};
|
|
218
|
+
B(t, (e) => {
|
|
219
|
+
e ? o() : s();
|
|
220
|
+
}, { immediate: !0 }), te(() => {
|
|
221
|
+
s();
|
|
222
|
+
});
|
|
223
|
+
}, Xe = {
|
|
224
|
+
xs: "max-w-xs w-[50VW]",
|
|
225
|
+
sm: "max-w-sm w-[50VW]",
|
|
226
|
+
lg: "max-w-2xl w-[80VW]",
|
|
227
|
+
xl: "max-w-[80VW] w-[80VW]"
|
|
228
|
+
}, Ze = {
|
|
229
|
+
xs: "btn-xs",
|
|
230
|
+
sm: "btn-sm",
|
|
231
|
+
lg: "btn-sm",
|
|
232
|
+
xl: "btn"
|
|
233
|
+
}, Qe = {
|
|
234
|
+
xs: "badge-xs text-xxs",
|
|
235
|
+
sm: "badge-sm text-xs",
|
|
236
|
+
lg: "badge-sm text-xs",
|
|
237
|
+
xl: "badge text-xs"
|
|
238
|
+
}, $e = { class: "flex justify-end gap-2 pt-2 mt-2 border-t border-gray-300 shrink-0" }, et = /* @__PURE__ */ x({
|
|
239
|
+
__name: "modal",
|
|
240
|
+
props: Ge,
|
|
241
|
+
emits: Ke,
|
|
242
|
+
setup(e, { expose: t, emit: n }) {
|
|
243
|
+
let r = e, i = `modal_${crypto.randomUUID()}`, a = `${i}_title`, o = `${i}_content`, s = M(null), c = M(!1), l = n, u = () => {
|
|
244
|
+
s.value?.showModal(), c.value = !0;
|
|
245
|
+
}, d = () => {
|
|
246
|
+
s.value?.close(), c.value = !1, l("closeModal");
|
|
247
|
+
}, f = () => {
|
|
248
|
+
r.disableClose || d();
|
|
249
|
+
};
|
|
250
|
+
return Ye({
|
|
251
|
+
containerRef: s,
|
|
252
|
+
isActive: c,
|
|
253
|
+
onEscape: () => {
|
|
254
|
+
r.disableClose || d();
|
|
255
|
+
}
|
|
256
|
+
}), t({
|
|
257
|
+
closeModal: d,
|
|
258
|
+
openModal: u
|
|
259
|
+
}), B(() => r.open, () => {
|
|
260
|
+
r.open ? u() : d();
|
|
261
|
+
}), ee(() => {
|
|
262
|
+
r.open && u();
|
|
263
|
+
}), (e, t) => (j(), g("dialog", {
|
|
264
|
+
ref_key: "dialogRef",
|
|
265
|
+
ref: s,
|
|
266
|
+
class: "modal",
|
|
267
|
+
role: "dialog",
|
|
268
|
+
"aria-modal": "true",
|
|
269
|
+
"aria-labelledby": a,
|
|
270
|
+
"aria-describedby": o,
|
|
271
|
+
onCancel: U(f, ["prevent"])
|
|
272
|
+
}, [_("div", { class: O(["modal-box bg-white min-h-0 max-h-[90vh] flex flex-col overflow-hidden", R(Xe)[e.width]]) }, [
|
|
273
|
+
e.disableClose ? h("", !0) : (j(), g("button", {
|
|
274
|
+
key: 0,
|
|
275
|
+
type: "button",
|
|
276
|
+
class: "btn btn-sm btn-circle btn-ghost absolute right-2 top-2",
|
|
277
|
+
"aria-label": "Close",
|
|
278
|
+
onClick: d
|
|
279
|
+
}, " ✕ ")),
|
|
280
|
+
e.$slots.title ? P(e.$slots, "title", { key: 1 }) : (j(), g("h3", {
|
|
281
|
+
key: 2,
|
|
282
|
+
id: a,
|
|
283
|
+
class: "font-bold shrink-0"
|
|
284
|
+
}, I(e.modalTitle), 1)),
|
|
285
|
+
_("div", {
|
|
286
|
+
id: o,
|
|
287
|
+
class: "pt-4 flex-1 min-h-0 flex flex-col"
|
|
288
|
+
}, [P(e.$slots, "content")]),
|
|
289
|
+
_("div", $e, [P(e.$slots, "actions")])
|
|
290
|
+
], 2)], 544));
|
|
291
|
+
}
|
|
292
|
+
}), Y = /* @__PURE__ */ function(e) {
|
|
293
|
+
return e.button = "button", e.submit = "submit", e.reset = "reset", e;
|
|
294
|
+
}({}), tt = /* @__PURE__ */ function(e) {
|
|
295
|
+
return e.a = "a", e.button = "button", e;
|
|
296
|
+
}({}), X = /* @__PURE__ */ function(e) {
|
|
297
|
+
return e.blank = "blank", e.primary = "primary", e.secondary = "secondary", e.error = "error", e.ghost = "ghost", e;
|
|
298
|
+
}({}), nt = {
|
|
299
|
+
blank: "btn-ghost",
|
|
300
|
+
primary: "btn-primary",
|
|
301
|
+
secondary: "btn-soft btn-primary",
|
|
302
|
+
error: "btn-error",
|
|
303
|
+
ghost: "btn-ghost"
|
|
304
|
+
}, rt = {
|
|
305
|
+
blank: "badge-ghost",
|
|
306
|
+
primary: "badge-primary",
|
|
307
|
+
secondary: "badge-soft badge-primary",
|
|
308
|
+
error: "badge-error",
|
|
309
|
+
ghost: "badge-ghost"
|
|
310
|
+
}, it = {
|
|
311
|
+
href: { type: String },
|
|
312
|
+
disabled: {
|
|
313
|
+
type: Boolean,
|
|
314
|
+
default: !1
|
|
315
|
+
},
|
|
316
|
+
tooltip: { type: String },
|
|
317
|
+
as: {
|
|
318
|
+
type: String,
|
|
319
|
+
default: tt.button
|
|
320
|
+
},
|
|
321
|
+
icon: { type: [
|
|
322
|
+
String,
|
|
323
|
+
Object,
|
|
324
|
+
Function
|
|
325
|
+
] },
|
|
326
|
+
type: {
|
|
327
|
+
type: String,
|
|
328
|
+
default: Y.button
|
|
329
|
+
},
|
|
330
|
+
outline: {
|
|
331
|
+
type: Boolean,
|
|
332
|
+
default: !1
|
|
333
|
+
},
|
|
334
|
+
color: {
|
|
335
|
+
type: String,
|
|
336
|
+
default: X.primary
|
|
337
|
+
},
|
|
338
|
+
size: {
|
|
339
|
+
type: String,
|
|
340
|
+
default: "sm"
|
|
341
|
+
},
|
|
342
|
+
square: {
|
|
343
|
+
type: Boolean,
|
|
344
|
+
default: !1
|
|
345
|
+
},
|
|
346
|
+
noBorder: {
|
|
347
|
+
type: Boolean,
|
|
348
|
+
default: !1
|
|
349
|
+
}
|
|
350
|
+
}, at = ["click"], ot = {
|
|
351
|
+
icon: { type: [
|
|
352
|
+
String,
|
|
353
|
+
Object,
|
|
354
|
+
Function
|
|
355
|
+
] },
|
|
356
|
+
type: {
|
|
357
|
+
type: String,
|
|
358
|
+
default: Y.button
|
|
359
|
+
},
|
|
360
|
+
color: {
|
|
361
|
+
type: String,
|
|
362
|
+
default: X.primary
|
|
363
|
+
},
|
|
364
|
+
disabled: {
|
|
365
|
+
type: Boolean,
|
|
366
|
+
default: !1
|
|
367
|
+
},
|
|
368
|
+
size: {
|
|
369
|
+
type: String,
|
|
370
|
+
default: "sm"
|
|
371
|
+
}
|
|
372
|
+
}, st = ["click"], ct = {
|
|
373
|
+
key: 1,
|
|
374
|
+
class: "whitespace-nowrap"
|
|
375
|
+
}, Z = /* @__PURE__ */ x({
|
|
376
|
+
__name: "btn",
|
|
377
|
+
props: it,
|
|
378
|
+
emits: at,
|
|
379
|
+
setup(e, { emit: t }) {
|
|
380
|
+
let n = e, r = t;
|
|
381
|
+
return (e, t) => (j(), m(F(n.as), {
|
|
382
|
+
class: O([
|
|
383
|
+
"btn p-1 flex justify-center flex-nowrap",
|
|
384
|
+
R(nt)[n.color],
|
|
385
|
+
R(Ze)[n.size],
|
|
386
|
+
{
|
|
387
|
+
"btn-outline": n.outline,
|
|
388
|
+
"btn-square": n.square,
|
|
389
|
+
tooltip: n.tooltip,
|
|
390
|
+
"border-0": n.noBorder
|
|
391
|
+
}
|
|
392
|
+
]),
|
|
393
|
+
href: n.href,
|
|
394
|
+
type: n.type,
|
|
395
|
+
disabled: n.disabled,
|
|
396
|
+
"data-tip": n.tooltip,
|
|
397
|
+
onClick: t[0] ||= (e) => r("click")
|
|
398
|
+
}, {
|
|
399
|
+
default: V(() => [n.icon ? (j(), m(R(K), {
|
|
400
|
+
key: 0,
|
|
401
|
+
icon: n.icon
|
|
402
|
+
}, null, 8, ["icon"])) : h("", !0), e.$slots.default ? (j(), g("span", ct, [P(e.$slots, "default")])) : h("", !0)]),
|
|
403
|
+
_: 3
|
|
404
|
+
}, 8, [
|
|
405
|
+
"class",
|
|
406
|
+
"href",
|
|
407
|
+
"type",
|
|
408
|
+
"disabled",
|
|
409
|
+
"data-tip"
|
|
410
|
+
]));
|
|
411
|
+
}
|
|
412
|
+
}), lt = ["type", "disabled"], ut = /* @__PURE__ */ x({
|
|
413
|
+
__name: "btn-badge",
|
|
414
|
+
props: ot,
|
|
415
|
+
emits: st,
|
|
416
|
+
setup(e, { emit: t }) {
|
|
417
|
+
let n = e, r = t;
|
|
418
|
+
return (e, t) => (j(), g("button", {
|
|
419
|
+
class: O([
|
|
420
|
+
"badge gap-1",
|
|
421
|
+
R(Qe)[n.size],
|
|
422
|
+
R(rt)[n.color]
|
|
423
|
+
]),
|
|
424
|
+
type: n.type,
|
|
425
|
+
disabled: n.disabled,
|
|
426
|
+
onClick: t[0] ||= (e) => r("click")
|
|
427
|
+
}, [P(e.$slots, "default"), n.icon ? (j(), m(R(K), {
|
|
428
|
+
key: 0,
|
|
429
|
+
icon: n.icon,
|
|
430
|
+
size: n.size
|
|
431
|
+
}, null, 8, ["icon", "size"])) : h("", !0)], 10, lt));
|
|
432
|
+
}
|
|
433
|
+
}), dt = /* @__PURE__ */ x({
|
|
434
|
+
__name: "confirmModal",
|
|
435
|
+
props: {
|
|
436
|
+
title: {},
|
|
437
|
+
message: {},
|
|
438
|
+
confirmLabel: { default: "Ok" },
|
|
439
|
+
cancelLabel: { default: "Cancel" }
|
|
440
|
+
},
|
|
441
|
+
emits: ["closeModal"],
|
|
442
|
+
setup(e, { emit: t }) {
|
|
443
|
+
let n = t, r = (e) => {
|
|
444
|
+
n("closeModal", { confirmed: e });
|
|
445
|
+
};
|
|
446
|
+
return (t, n) => (j(), m(et, {
|
|
447
|
+
"modal-title": e.title,
|
|
448
|
+
open: !0,
|
|
449
|
+
"disable-close": !0
|
|
450
|
+
}, {
|
|
451
|
+
content: V(() => [v(I(e.message), 1)]),
|
|
452
|
+
actions: V(() => [y(R(Z), {
|
|
453
|
+
color: R(X).secondary,
|
|
454
|
+
outline: !0,
|
|
455
|
+
"aria-label": e.cancelLabel,
|
|
456
|
+
onClick: n[0] ||= (e) => r(!1)
|
|
457
|
+
}, {
|
|
458
|
+
default: V(() => [v(I(e.cancelLabel), 1)]),
|
|
459
|
+
_: 1
|
|
460
|
+
}, 8, ["color", "aria-label"]), y(R(Z), {
|
|
461
|
+
"aria-label": e.confirmLabel,
|
|
462
|
+
onClick: n[1] ||= (e) => r(!0)
|
|
463
|
+
}, {
|
|
464
|
+
default: V(() => [v(I(e.confirmLabel), 1)]),
|
|
465
|
+
_: 1
|
|
466
|
+
}, 8, ["aria-label"])]),
|
|
467
|
+
_: 1
|
|
468
|
+
}, 8, ["modal-title"]));
|
|
469
|
+
}
|
|
470
|
+
}), ft = class e {
|
|
471
|
+
constructor() {
|
|
472
|
+
this.showModal = M(!1), this.modals = [];
|
|
473
|
+
}
|
|
474
|
+
openModal(e) {
|
|
475
|
+
let t = e.props.onClose, n = crypto.randomUUID(), r = e;
|
|
476
|
+
e.props.onClose = (e) => {
|
|
477
|
+
t(e), this.closeModal(n);
|
|
478
|
+
}, r.id = n, this.modals = [...this.modals, r], this.showModal.value = Date.now();
|
|
479
|
+
}
|
|
480
|
+
closeModal(e) {
|
|
481
|
+
this.modals = this.modals.filter((t) => t.id !== e), this.showModal.value = Date.now();
|
|
482
|
+
}
|
|
483
|
+
static showConfirm(e) {
|
|
484
|
+
this.getInstance().openModal({
|
|
485
|
+
component: dt,
|
|
486
|
+
props: e
|
|
487
|
+
});
|
|
488
|
+
}
|
|
489
|
+
static openModal(e) {
|
|
490
|
+
this.getInstance().openModal(e);
|
|
491
|
+
}
|
|
492
|
+
static getInstance() {
|
|
493
|
+
return this.instance ||= new e(), this.instance;
|
|
494
|
+
}
|
|
495
|
+
static closeAll() {
|
|
496
|
+
this.instance.closeAll();
|
|
497
|
+
}
|
|
498
|
+
closeAll() {
|
|
499
|
+
this.modals = [], this.showModal.value = !1;
|
|
500
|
+
}
|
|
501
|
+
}, pt = /* @__PURE__ */ x({
|
|
502
|
+
__name: "modalWrapper",
|
|
503
|
+
setup(e) {
|
|
504
|
+
let t = ft.getInstance(), n = p(() => t.showModal.value ? t.modals : []);
|
|
505
|
+
return (e, t) => (j(!0), g(l, null, N(n.value, (e) => (j(), m(F(e?.component), E({
|
|
506
|
+
key: e.id,
|
|
507
|
+
ref_for: !0
|
|
508
|
+
}, e?.props, {
|
|
509
|
+
open: !0,
|
|
510
|
+
onCloseModal: e?.props?.onClose
|
|
511
|
+
}), null, 16, ["onCloseModal"]))), 128));
|
|
512
|
+
}
|
|
513
|
+
}), mt = /* @__PURE__ */ x({
|
|
514
|
+
__name: "notification-message",
|
|
515
|
+
props: {
|
|
516
|
+
message: {},
|
|
517
|
+
type: {}
|
|
518
|
+
},
|
|
519
|
+
setup(e) {
|
|
520
|
+
let t = {
|
|
521
|
+
success: "alert-success",
|
|
522
|
+
error: "alert-error",
|
|
523
|
+
warning: "alert-warning",
|
|
524
|
+
info: "alert-info"
|
|
525
|
+
};
|
|
526
|
+
return (n, r) => (j(), g("div", {
|
|
527
|
+
role: "alert",
|
|
528
|
+
class: O(`alert ${t[e.type]} `)
|
|
529
|
+
}, [_("span", null, I(e.message), 1)], 2));
|
|
530
|
+
}
|
|
531
|
+
}), ht = 5e3, gt = class e {
|
|
532
|
+
constructor() {
|
|
533
|
+
this.notifications = M([]), this.addNotification = (e, t = "info") => {
|
|
534
|
+
let n = {
|
|
535
|
+
id: crypto.randomUUID(),
|
|
536
|
+
duration: ht,
|
|
537
|
+
message: e,
|
|
538
|
+
type: t
|
|
539
|
+
};
|
|
540
|
+
this.notifications.value.push(n), this.removeNotificationAfterDuration(n);
|
|
541
|
+
}, this.removeNotificationAfterDuration = (e) => {
|
|
542
|
+
setTimeout(() => {
|
|
543
|
+
this.removeNotification(e.id);
|
|
544
|
+
}, e.duration);
|
|
545
|
+
}, this.removeNotification = (e) => {
|
|
546
|
+
this.notifications.value = this.notifications.value.filter((t) => t.id !== e);
|
|
547
|
+
};
|
|
548
|
+
}
|
|
549
|
+
static getInstance() {
|
|
550
|
+
return this.instance ||= new e(), this.instance;
|
|
551
|
+
}
|
|
552
|
+
static info(e) {
|
|
553
|
+
this.getInstance().addNotification(e, "info");
|
|
554
|
+
}
|
|
555
|
+
static success(e) {
|
|
556
|
+
this.getInstance().addNotification(e, "success");
|
|
557
|
+
}
|
|
558
|
+
static warning(e) {
|
|
559
|
+
this.getInstance().addNotification(e, "warning");
|
|
560
|
+
}
|
|
561
|
+
static error(e) {
|
|
562
|
+
this.getInstance().addNotification(e, "error");
|
|
563
|
+
}
|
|
564
|
+
static removeNotification(e) {
|
|
565
|
+
this.getInstance().removeNotification(e);
|
|
566
|
+
}
|
|
567
|
+
}, _t = { class: "toast toast-top toast-center z-[999]" }, vt = /* @__PURE__ */ x({
|
|
568
|
+
__name: "notifications",
|
|
569
|
+
setup(e) {
|
|
570
|
+
let t = gt.getInstance();
|
|
571
|
+
return (e, n) => (j(), g("div", _t, [(j(!0), g(l, null, N(R(t).notifications.value, (e) => (j(), m(mt, E({ key: e.id }, { ref_for: !0 }, e), null, 16))), 128))]));
|
|
572
|
+
}
|
|
573
|
+
}), yt = { class: "flex h-screen flex-col" }, bt = { class: "shrink-0" }, xt = { class: "navbar bg-primary text-primary-content w-full z-100" }, St = {
|
|
574
|
+
key: 0,
|
|
575
|
+
class: "navbar-start"
|
|
576
|
+
}, Ct = { class: "navbar-center" }, wt = ["href"], Tt = { class: "navbar-end" }, Et = { class: "drawer-content overflow-y-auto mb-2 mr-2 shadow-md" }, Dt = { class: "drawer-side h-full shadow-md" }, Ot = { class: "flex-grow overflow-y-auto" }, kt = { class: "bg-base-200 p-4" }, At = /* @__PURE__ */ x({
|
|
577
|
+
__name: "shell.component",
|
|
578
|
+
props: {
|
|
579
|
+
title: {},
|
|
580
|
+
menu: {},
|
|
581
|
+
user: {},
|
|
582
|
+
version: {},
|
|
583
|
+
widthSidebar: { default: 300 }
|
|
584
|
+
},
|
|
585
|
+
emits: ["logout"],
|
|
586
|
+
setup(e, { emit: t }) {
|
|
587
|
+
let n = e, r = M(!1), i = () => {
|
|
588
|
+
r.value = !r.value;
|
|
589
|
+
}, a = t, o = p(() => n.user ? {
|
|
590
|
+
label: n.user.name,
|
|
591
|
+
items: [{
|
|
592
|
+
label: "Logout",
|
|
593
|
+
action: () => {
|
|
594
|
+
a("logout");
|
|
595
|
+
}
|
|
596
|
+
}]
|
|
597
|
+
} : null);
|
|
598
|
+
return (t, n) => (j(), g(l, null, [
|
|
599
|
+
y(vt),
|
|
600
|
+
y(R(pt)),
|
|
601
|
+
_("div", yt, [_("header", bt, [_("nav", xt, [
|
|
602
|
+
e.menu?.length ? (j(), g("div", St, [_("button", {
|
|
603
|
+
"aria-label": "open sidebar",
|
|
604
|
+
class: "btn btn-square btn-ghost p-1",
|
|
605
|
+
onClick: i
|
|
606
|
+
}, [y(R(K), { icon: R(G).Hamburger }, null, 8, ["icon"])])])) : h("", !0),
|
|
607
|
+
_("div", Ct, [_("a", {
|
|
608
|
+
class: "btn btn-ghost text-primary-content text-lg color-white",
|
|
609
|
+
href: R("/")
|
|
610
|
+
}, I(e.title), 9, wt)]),
|
|
611
|
+
_("div", Tt, [o.value ? (j(), m(R(q), E({ key: 0 }, o.value, { "btn-class": "" }), null, 16)) : h("", !0)])
|
|
612
|
+
])]), _("div", { class: O(["drawer flex-1 overflow-hidden", { "drawer-open": r.value }]) }, [
|
|
613
|
+
H(_("input", {
|
|
614
|
+
id: "app-drawer",
|
|
615
|
+
"onUpdate:modelValue": n[0] ||= (e) => r.value = e,
|
|
616
|
+
type: "checkbox",
|
|
617
|
+
class: "drawer-toggle"
|
|
618
|
+
}, null, 512), [[oe, r.value]]),
|
|
619
|
+
_("main", Et, [P(t.$slots, "default")]),
|
|
620
|
+
_("div", Dt, [n[1] ||= _("label", {
|
|
621
|
+
for: "app-drawer",
|
|
622
|
+
"aria-label": "close sidebar",
|
|
623
|
+
class: "drawer-overlay"
|
|
624
|
+
}, null, -1), _("div", {
|
|
625
|
+
class: "menu bg-base-100 h-full flex flex-col justify-between",
|
|
626
|
+
style: A({ width: e.widthSidebar + "px" })
|
|
627
|
+
}, [_("ul", Ot, [(j(!0), g(l, null, N(e.menu, (e) => (j(), g("li", { key: e.label }, [y(R(le), { to: {
|
|
628
|
+
name: e.routerLink,
|
|
629
|
+
params: e.params
|
|
630
|
+
} }, {
|
|
631
|
+
default: V(() => [v(I(e.label), 1)]),
|
|
632
|
+
_: 2
|
|
633
|
+
}, 1032, ["to"])]))), 128))]), _("div", kt, " version: " + I(e.version), 1)], 4)])
|
|
634
|
+
], 2)])
|
|
635
|
+
], 64));
|
|
636
|
+
}
|
|
637
|
+
}), Q = /* @__PURE__ */ x({
|
|
638
|
+
__name: "pagination-button.component",
|
|
639
|
+
props: {
|
|
640
|
+
currentPage: {
|
|
641
|
+
type: Number,
|
|
642
|
+
required: !0
|
|
643
|
+
},
|
|
644
|
+
page: {
|
|
645
|
+
type: Number,
|
|
646
|
+
required: !0
|
|
647
|
+
},
|
|
648
|
+
label: {
|
|
649
|
+
type: String,
|
|
650
|
+
required: !0
|
|
651
|
+
},
|
|
652
|
+
neverActive: {
|
|
653
|
+
type: Boolean,
|
|
654
|
+
default: !1
|
|
655
|
+
},
|
|
656
|
+
disabled: {
|
|
657
|
+
type: Boolean,
|
|
658
|
+
default: !1
|
|
659
|
+
}
|
|
660
|
+
},
|
|
661
|
+
emits: ["updatePage", "updatePageSize"],
|
|
662
|
+
setup(e, { emit: t }) {
|
|
663
|
+
let n = e, r = t, i = p(() => n.neverActive ? !1 : n.page === n.currentPage), a = p(() => n.neverActive ? X.blank : i.value ? X.primary : X.secondary), o = () => {
|
|
664
|
+
r("updatePage", n.page);
|
|
665
|
+
};
|
|
666
|
+
return (e, t) => (j(), m(R(Z), {
|
|
667
|
+
disabled: e.disabled,
|
|
668
|
+
square: !0,
|
|
669
|
+
size: "xs",
|
|
670
|
+
color: a.value,
|
|
671
|
+
onClick: t[0] ||= (e) => o()
|
|
672
|
+
}, {
|
|
673
|
+
default: V(() => [v(I(e.label), 1)]),
|
|
674
|
+
_: 1
|
|
675
|
+
}, 8, ["disabled", "color"]));
|
|
676
|
+
}
|
|
677
|
+
}), jt = {
|
|
678
|
+
totalItems: {
|
|
679
|
+
type: Number,
|
|
680
|
+
default: 0
|
|
681
|
+
},
|
|
682
|
+
itemsPerPage: {
|
|
683
|
+
type: Number,
|
|
684
|
+
default: 1
|
|
685
|
+
},
|
|
686
|
+
currentPage: {
|
|
687
|
+
type: Number,
|
|
688
|
+
default: 1
|
|
689
|
+
},
|
|
690
|
+
pageSizeOptions: {
|
|
691
|
+
type: Array,
|
|
692
|
+
default: () => [
|
|
693
|
+
10,
|
|
694
|
+
20,
|
|
695
|
+
50,
|
|
696
|
+
100
|
|
697
|
+
]
|
|
698
|
+
}
|
|
699
|
+
}, Mt = ["updatePage", "updatePageSize"], Nt = { class: "flex items-center justify-between gap-4" }, Pt = { class: "flex gap-1" }, Ft = { class: "flex items-center gap-4 text-xs text-base-content/60" }, It = { class: "flex items-center gap-2 whitespace-nowrap text-sm" }, Lt = ["value"], Rt = ["value"], zt = { class: "whitespace-nowrap" }, $ = 6, Bt = /* @__PURE__ */ x({
|
|
700
|
+
__name: "pagination.component",
|
|
701
|
+
props: jt,
|
|
702
|
+
emits: Mt,
|
|
703
|
+
setup(e, { emit: t }) {
|
|
704
|
+
let n = e, r = t, i = p(() => {
|
|
705
|
+
let e = Math.ceil(n.totalItems / n.itemsPerPage);
|
|
706
|
+
return e < 1 ? 1 : e;
|
|
707
|
+
}), a = $ / 2, o = p(() => {
|
|
708
|
+
if (i.value <= $) return {
|
|
709
|
+
min: 1,
|
|
710
|
+
max: i.value
|
|
711
|
+
};
|
|
712
|
+
let e = n.currentPage - a;
|
|
713
|
+
e <= 1 ? e = 1 : e + $ > i.value && (e = i.value - $);
|
|
714
|
+
let t = e + $;
|
|
715
|
+
return {
|
|
716
|
+
min: e,
|
|
717
|
+
max: t
|
|
718
|
+
};
|
|
719
|
+
}), s = (e) => ({
|
|
720
|
+
label: "...",
|
|
721
|
+
currentPage: e,
|
|
722
|
+
page: -10,
|
|
723
|
+
disabled: !0,
|
|
724
|
+
neverActive: !0
|
|
725
|
+
}), c = p(() => {
|
|
726
|
+
let e = i.value;
|
|
727
|
+
e < 1 && (e = 1);
|
|
728
|
+
let t = n.currentPage, r = [], { min: a, max: c } = o.value;
|
|
729
|
+
return Array.from({ length: e }, (n, i) => {
|
|
730
|
+
let o = i + 1;
|
|
731
|
+
o !== 1 && o !== e && (o > c || o < a) || (o === e && e > 1 && c < e && r.push(s(t)), r.push({
|
|
732
|
+
label: `${o}`,
|
|
733
|
+
totalPages: e,
|
|
734
|
+
currentPage: t,
|
|
735
|
+
page: o
|
|
736
|
+
}), o === 1 && e > 1 && a > 1 && r.push(s(t)));
|
|
737
|
+
}), r;
|
|
738
|
+
}), u = p(() => {
|
|
739
|
+
let e = (n.currentPage - 1) * n.itemsPerPage;
|
|
740
|
+
return Math.min(e + n.itemsPerPage, n.totalItems);
|
|
741
|
+
}), d = (e) => {
|
|
742
|
+
r("updatePage", e);
|
|
743
|
+
}, f = (e) => {
|
|
744
|
+
r("updatePageSize", Number(e.target.value));
|
|
745
|
+
};
|
|
746
|
+
return (e, t) => (j(), g("div", Nt, [_("div", Pt, [
|
|
747
|
+
y(Q, E(n, {
|
|
748
|
+
page: 1,
|
|
749
|
+
label: "<<",
|
|
750
|
+
"current-page": e.currentPage,
|
|
751
|
+
"never-active": !0,
|
|
752
|
+
disabled: e.currentPage === 1,
|
|
753
|
+
onUpdatePage: d
|
|
754
|
+
}), null, 16, ["current-page", "disabled"]),
|
|
755
|
+
y(Q, E(n, {
|
|
756
|
+
page: e.currentPage - 1,
|
|
757
|
+
label: "<",
|
|
758
|
+
"current-page": e.currentPage,
|
|
759
|
+
"never-active": !0,
|
|
760
|
+
disabled: e.currentPage === 1,
|
|
761
|
+
onUpdatePage: d
|
|
762
|
+
}), null, 16, [
|
|
763
|
+
"page",
|
|
764
|
+
"current-page",
|
|
765
|
+
"disabled"
|
|
766
|
+
]),
|
|
767
|
+
(j(!0), g(l, null, N(c.value, (e) => (j(), m(Q, E({
|
|
768
|
+
key: e.page,
|
|
769
|
+
ref_for: !0
|
|
770
|
+
}, e, { onUpdatePage: d }), null, 16))), 128)),
|
|
771
|
+
y(Q, E(n, {
|
|
772
|
+
page: e.currentPage + 1,
|
|
773
|
+
label: ">",
|
|
774
|
+
"current-page": e.currentPage,
|
|
775
|
+
"never-active": !0,
|
|
776
|
+
disabled: n.currentPage === i.value,
|
|
777
|
+
onUpdatePage: d
|
|
778
|
+
}), null, 16, [
|
|
779
|
+
"page",
|
|
780
|
+
"current-page",
|
|
781
|
+
"disabled"
|
|
782
|
+
]),
|
|
783
|
+
y(Q, E(n, {
|
|
784
|
+
page: i.value,
|
|
785
|
+
label: ">>",
|
|
786
|
+
"current-page": e.currentPage,
|
|
787
|
+
"never-active": !0,
|
|
788
|
+
disabled: n.currentPage === i.value,
|
|
789
|
+
onUpdatePage: d
|
|
790
|
+
}), null, 16, [
|
|
791
|
+
"page",
|
|
792
|
+
"current-page",
|
|
793
|
+
"disabled"
|
|
794
|
+
])
|
|
795
|
+
]), _("div", Ft, [_("label", It, [t[0] ||= v(" Records per page: ", -1), _("select", {
|
|
796
|
+
class: "select select-xs select-bordered",
|
|
797
|
+
value: n.itemsPerPage,
|
|
798
|
+
onChange: f
|
|
799
|
+
}, [(j(!0), g(l, null, N(e.pageSizeOptions, (e) => (j(), g("option", {
|
|
800
|
+
key: e,
|
|
801
|
+
value: e
|
|
802
|
+
}, I(e), 9, Rt))), 128))], 40, Lt)]), _("span", zt, " Showing " + I(u.value) + " of " + I(e.totalItems) + " records", 1)])]));
|
|
803
|
+
}
|
|
804
|
+
}), Vt = {
|
|
805
|
+
column: {
|
|
806
|
+
type: Object,
|
|
807
|
+
required: !0
|
|
808
|
+
},
|
|
809
|
+
sortColumn: { type: String },
|
|
810
|
+
sortDirection: { type: String }
|
|
811
|
+
}, Ht = ["sort"], Ut = ["disabled"], Wt = { class: "whitespace-nowrap" }, Gt = { class: "h-4 w-4 relative" }, Kt = /* @__PURE__ */ x({
|
|
812
|
+
__name: "sort.header",
|
|
813
|
+
props: Vt,
|
|
814
|
+
emits: Ht,
|
|
815
|
+
setup(e, { emit: t }) {
|
|
816
|
+
let n = e, r = t, i = p(() => n.column.options?.sortable !== !1), a = p(() => n.sortDirection === "asc" ? G.BarsArrowUp : G.BarsArrowDown), o = p(() => n.column.options?.sortId ?? n.column.id), s = () => {
|
|
817
|
+
i.value && r("sort", o.value);
|
|
818
|
+
};
|
|
819
|
+
return (e, t) => (j(), g("button", {
|
|
820
|
+
class: O(["flex items-center gap-2", i.value ? "cursor-pointer" : "cursor-default"]),
|
|
821
|
+
disabled: !i.value,
|
|
822
|
+
onClick: s
|
|
823
|
+
}, [_("span", Wt, I(e.column.label), 1), _("div", Gt, [i.value && e.sortColumn === o.value ? (j(), m(R(K), {
|
|
824
|
+
key: 0,
|
|
825
|
+
icon: a.value
|
|
826
|
+
}, null, 8, ["icon"])) : h("", !0)])], 10, Ut));
|
|
827
|
+
}
|
|
828
|
+
}), qt = {
|
|
829
|
+
loading: {
|
|
830
|
+
type: Boolean,
|
|
831
|
+
default: !1
|
|
832
|
+
},
|
|
833
|
+
multiselect: {
|
|
834
|
+
type: Boolean,
|
|
835
|
+
default: !1
|
|
836
|
+
},
|
|
837
|
+
actions: { type: Array },
|
|
838
|
+
data: { type: Array },
|
|
839
|
+
displayColumns: {
|
|
840
|
+
type: Array,
|
|
841
|
+
required: !0
|
|
842
|
+
},
|
|
843
|
+
page: { type: Object },
|
|
844
|
+
sort: { type: Object }
|
|
845
|
+
}, Jt = [
|
|
846
|
+
"updatePage",
|
|
847
|
+
"updatePageSize",
|
|
848
|
+
"sort",
|
|
849
|
+
"selectionChange"
|
|
850
|
+
], Yt = { class: "border border-gray-200" }, Xt = { class: "overflow-x-auto" }, Zt = { class: "w-full text-sm" }, Qt = { class: "text-xs text-text-muted font-medium border-b border-gray-200 border-solid sticky top-0 rounded-md" }, $t = { class: "border-b border-gray-200" }, en = {
|
|
851
|
+
key: 0,
|
|
852
|
+
class: "px-3 py-1 w-10 text-left border-r border-gray-200"
|
|
853
|
+
}, tn = ["checked", "indeterminate"], nn = { key: 0 }, rn = ["colspan"], an = { key: 1 }, on = ["colspan"], sn = ["ui-id"], cn = {
|
|
854
|
+
key: 0,
|
|
855
|
+
class: "py-1 px-3"
|
|
856
|
+
}, ln = ["checked", "onChange"], un = {
|
|
857
|
+
class: "px-3 flex items-center gap-2 rounded-sm relative border hover:bg-gray-50 hover:border-gray-200 border-transparent max-w-56",
|
|
858
|
+
style: {
|
|
859
|
+
"min-width": "100%",
|
|
860
|
+
"min-height": "38px"
|
|
861
|
+
}
|
|
862
|
+
}, dn = { class: "whitespace-nowrap overflow-hidden overflow-ellipsis" }, fn = { class: "align-middle p-0 sticky right-0 bg-white hover:bg-gray-50 shadow-[-4px_0_6px_-2px_rgba(0,0,0,0.05)]" }, pn = { class: "px-3 py-1 items-center justify-end gap-1 flex whitespace-nowrap" }, mn = { key: 0 }, hn = /* @__PURE__ */ x({
|
|
863
|
+
inheritAttrs: !1,
|
|
864
|
+
__name: "table.component",
|
|
865
|
+
props: qt,
|
|
866
|
+
emits: Jt,
|
|
867
|
+
setup(e, { emit: t }) {
|
|
868
|
+
let n = e, r = M(/* @__PURE__ */ new Set());
|
|
869
|
+
B(() => n.data, () => {
|
|
870
|
+
r.value.clear();
|
|
871
|
+
});
|
|
872
|
+
let i = p(() => !!n.data?.length && n.data.every((e) => r.value.has(e.id))), a = p(() => !!n.data?.some((e) => r.value.has(e.id)) && !i.value), o = (e) => {
|
|
873
|
+
let t = new Set(r.value);
|
|
874
|
+
t.has(e.id) ? t.delete(e.id) : t.add(e.id), r.value = t, u("selectionChange", n.data?.filter((e) => t.has(e.id)) ?? []);
|
|
875
|
+
}, s = () => {
|
|
876
|
+
i.value ? r.value = /* @__PURE__ */ new Set() : r.value = new Set(n.data?.map((e) => e.id) ?? []), u("selectionChange", n.data?.filter((e) => r.value.has(e.id)) ?? []);
|
|
877
|
+
}, c = p(() => {
|
|
878
|
+
let e = n.actions ?? [];
|
|
879
|
+
return f.value && e.push({
|
|
880
|
+
tooltip: "View",
|
|
881
|
+
icon: G.View,
|
|
882
|
+
action: x
|
|
883
|
+
}), v.value && e.push({
|
|
884
|
+
tooltip: "Edit",
|
|
885
|
+
icon: G.Edit,
|
|
886
|
+
action: S
|
|
887
|
+
}), b.value && e.push({
|
|
888
|
+
tooltip: "Delete",
|
|
889
|
+
icon: G.Delete,
|
|
890
|
+
action: C
|
|
891
|
+
}), e;
|
|
892
|
+
}), u = t, d = ie(), f = p(() => "onView" in d), v = p(() => "onEdit" in d), b = p(() => "onDelete" in d), x = (e) => {
|
|
893
|
+
d.onView?.(e);
|
|
894
|
+
}, S = (e) => {
|
|
895
|
+
d.onEdit?.(e);
|
|
896
|
+
}, C = (e) => {
|
|
897
|
+
d.onDelete?.(e);
|
|
898
|
+
}, w = (e) => {
|
|
899
|
+
u("updatePage", e);
|
|
900
|
+
}, T = (e) => {
|
|
901
|
+
u("updatePageSize", e);
|
|
902
|
+
}, D = (e) => {
|
|
903
|
+
u("sort", e);
|
|
904
|
+
};
|
|
905
|
+
return (e, t) => (j(), g("div", Yt, [_("div", Xt, [_("table", Zt, [_("thead", Qt, [_("tr", $t, [
|
|
906
|
+
e.multiselect ? (j(), g("th", en, [_("input", {
|
|
907
|
+
type: "checkbox",
|
|
908
|
+
checked: i.value,
|
|
909
|
+
indeterminate: a.value,
|
|
910
|
+
class: "cursor-pointer",
|
|
911
|
+
onChange: s
|
|
912
|
+
}, null, 40, tn)])) : h("", !0),
|
|
913
|
+
(j(!0), g(l, null, N(e.displayColumns, (t) => (j(), g("th", {
|
|
914
|
+
key: t.scope,
|
|
915
|
+
class: "relative px-3 py-1 text-left font-semibold text-text-accent hover:bg-gray-50 select-none border-r border-gray-200",
|
|
916
|
+
style: A(t.width ? {
|
|
917
|
+
width: t.width,
|
|
918
|
+
maxWidth: t.width,
|
|
919
|
+
minWidth: t.width
|
|
920
|
+
} : { minWidth: "150px" })
|
|
921
|
+
}, [y(Kt, E({ column: t }, { ref_for: !0 }, e.sort, { onSort: D }), null, 16, ["column"])], 4))), 128)),
|
|
922
|
+
t[0] ||= _("th", { class: "sticky right-0 w-10 cursor-grab rounded-tr-md visible bg-white shadow-[-4px_0_6px_-2px_rgba(0,0,0,0.05)]" }, " \xA0 ", -1)
|
|
923
|
+
])]), _("tbody", null, [e.loading ? (j(), g("tr", nn, [_("td", {
|
|
924
|
+
colspan: e.displayColumns.length + 1 + +!!e.multiselect,
|
|
925
|
+
class: "text-center p-2"
|
|
926
|
+
}, [...t[1] ||= [_("span", { class: "loading loading-bars loading-xs" }, null, -1)]], 8, rn)])) : e.data?.length ? h("", !0) : (j(), g("tr", an, [_("td", {
|
|
927
|
+
colspan: e.displayColumns.length + 1 + +!!e.multiselect,
|
|
928
|
+
class: "text-center p-8 font-bold"
|
|
929
|
+
}, " No records found ", 8, on)])), (j(!0), g(l, null, N(e.data, (t) => (j(), g("tr", {
|
|
930
|
+
key: t.id,
|
|
931
|
+
"ui-id": `table_${t.id}`,
|
|
932
|
+
class: "hover:bg-gray-100 transition-none transition-colors border-b border-gray-200"
|
|
933
|
+
}, [
|
|
934
|
+
e.multiselect ? (j(), g("td", cn, [_("input", {
|
|
935
|
+
type: "checkbox",
|
|
936
|
+
checked: r.value.has(t.id),
|
|
937
|
+
class: "cursor-pointer",
|
|
938
|
+
onChange: (e) => o(t)
|
|
939
|
+
}, null, 40, ln)])) : h("", !0),
|
|
940
|
+
(j(!0), g(l, null, N(e.displayColumns, (e) => (j(), g("td", {
|
|
941
|
+
key: e.scope,
|
|
942
|
+
class: "py-1 px-3 text-sm overflow-hidden"
|
|
943
|
+
}, [_("div", un, [_("div", dn, [(j(), m(F(e.component), E({ ref_for: !0 }, e, {
|
|
944
|
+
data: t,
|
|
945
|
+
column: e
|
|
946
|
+
}), null, 16, ["data", "column"]))])])]))), 128)),
|
|
947
|
+
_("td", fn, [_("span", pn, [(j(!0), g(l, null, N(c.value, (e) => (j(), g(l, { key: e.label }, [!e.visible || e.visible(t) ? (j(), m(Z, {
|
|
948
|
+
key: 0,
|
|
949
|
+
"aria-label": e.tooltip ?? e.label,
|
|
950
|
+
icon: e.icon,
|
|
951
|
+
color: R(X).secondary,
|
|
952
|
+
size: "xs",
|
|
953
|
+
onClick: (n) => e.action(t)
|
|
954
|
+
}, {
|
|
955
|
+
default: V(() => [e.label ? (j(), g("span", mn, I(e.label), 1)) : h("", !0)]),
|
|
956
|
+
_: 2
|
|
957
|
+
}, 1032, [
|
|
958
|
+
"aria-label",
|
|
959
|
+
"icon",
|
|
960
|
+
"color",
|
|
961
|
+
"onClick"
|
|
962
|
+
])) : h("", !0)], 64))), 128))])])
|
|
963
|
+
], 8, sn))), 128))])])]), e.page ? (j(), m(Bt, {
|
|
964
|
+
key: 0,
|
|
965
|
+
class: "p-3",
|
|
966
|
+
"total-items": e.page.count,
|
|
967
|
+
"items-per-page": e.page.pageSize,
|
|
968
|
+
"current-page": e.page.page,
|
|
969
|
+
onUpdatePage: w,
|
|
970
|
+
onUpdatePageSize: T
|
|
971
|
+
}, null, 8, [
|
|
972
|
+
"total-items",
|
|
973
|
+
"items-per-page",
|
|
974
|
+
"current-page"
|
|
975
|
+
])) : h("", !0)]));
|
|
976
|
+
}
|
|
977
|
+
}), gn = {
|
|
978
|
+
data: {
|
|
979
|
+
type: Object,
|
|
980
|
+
required: !0
|
|
981
|
+
},
|
|
982
|
+
column: {
|
|
983
|
+
type: Object,
|
|
984
|
+
required: !0
|
|
985
|
+
},
|
|
986
|
+
options: { type: Object }
|
|
987
|
+
}, _n = { class: "truncate" }, vn = ["href"], yn = /* @__PURE__ */ x({
|
|
988
|
+
__name: "text.cell",
|
|
989
|
+
props: gn,
|
|
990
|
+
setup(e) {
|
|
991
|
+
let t = e, n = p(() => {
|
|
992
|
+
let e = t.column.options?.dataPath ?? t.column.id, n = t.data[e];
|
|
993
|
+
if (n == null) return null;
|
|
994
|
+
let r = t.column.options?.key;
|
|
995
|
+
return r ? n[r] ?? null : t.column.options?.format === "keyValue" ? n[t.column.options.key] : n;
|
|
996
|
+
}), r = p(() => typeof n.value == "string" && n.value.startsWith("http"));
|
|
997
|
+
return (e, t) => (j(), g("div", _n, [r.value ? (j(), g("a", {
|
|
998
|
+
key: 0,
|
|
999
|
+
href: n.value,
|
|
1000
|
+
target: "_blank",
|
|
1001
|
+
rel: "noopener noreferrer"
|
|
1002
|
+
}, I(n.value), 9, vn)) : (j(), g(l, { key: 1 }, [v(I(n.value), 1)], 64))]));
|
|
1003
|
+
}
|
|
1004
|
+
}), bn = { class: "flex justify-center" }, xn = /* @__PURE__ */ x({
|
|
1005
|
+
__name: "boolean.cell",
|
|
1006
|
+
props: gn,
|
|
1007
|
+
setup(e) {
|
|
1008
|
+
let t = e, n = p(() => {
|
|
1009
|
+
let e = t.data[t.column.id];
|
|
1010
|
+
return e ? t.column.options?.format === "keyValue" ? e[t.column.options.key] : e : null;
|
|
1011
|
+
});
|
|
1012
|
+
return (e, t) => (j(), g("div", bn, [n.value === !0 ? (j(), m(K, {
|
|
1013
|
+
key: 0,
|
|
1014
|
+
icon: R(G).Check,
|
|
1015
|
+
size: "sm"
|
|
1016
|
+
}, null, 8, ["icon"])) : h("", !0)]));
|
|
1017
|
+
}
|
|
1018
|
+
}), Sn = (e, t) => {
|
|
1019
|
+
let n = e.__vccOpts || e;
|
|
1020
|
+
for (let [e, r] of t) n[e] = r;
|
|
1021
|
+
return n;
|
|
1022
|
+
}, Cn = {}, wn = { class: "card bg-base-100 shadow-sm" }, Tn = { class: "card-body" }, En = {
|
|
1023
|
+
key: 0,
|
|
1024
|
+
class: "card-title"
|
|
1025
|
+
}, Dn = {
|
|
1026
|
+
key: 1,
|
|
1027
|
+
class: "card-actions justify-end"
|
|
935
1028
|
};
|
|
936
|
-
function
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
u("p", null, [
|
|
943
|
-
P(e.$slots, "default"),
|
|
944
|
-
P(e.$slots, "content")
|
|
945
|
-
]),
|
|
946
|
-
e.$slots.actions ? (r(), f("div", Bo, [
|
|
947
|
-
P(e.$slots, "actions")
|
|
948
|
-
])) : _("", !0)
|
|
949
|
-
])
|
|
950
|
-
]);
|
|
1029
|
+
function On(e, t) {
|
|
1030
|
+
return j(), g("div", wn, [_("div", Tn, [
|
|
1031
|
+
e.$slots.title ? (j(), g("h2", En, [P(e.$slots, "title")])) : h("", !0),
|
|
1032
|
+
_("p", null, [P(e.$slots, "default"), P(e.$slots, "content")]),
|
|
1033
|
+
e.$slots.actions ? (j(), g("div", Dn, [P(e.$slots, "actions")])) : h("", !0)
|
|
1034
|
+
])]);
|
|
951
1035
|
}
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
},
|
|
959
|
-
|
|
960
|
-
},
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
1036
|
+
var kn = /* @__PURE__ */ Sn(Cn, [["render", On]]), An = (e, t) => {
|
|
1037
|
+
if (!e) return null;
|
|
1038
|
+
let n = (n) => {
|
|
1039
|
+
e.contains(n.target) || t();
|
|
1040
|
+
};
|
|
1041
|
+
return document.addEventListener("click", n), n;
|
|
1042
|
+
}, jn = (e) => {
|
|
1043
|
+
document.removeEventListener("click", e);
|
|
1044
|
+
}, Mn = {
|
|
1045
|
+
beforeMount(e, t) {
|
|
1046
|
+
e.clickOutsideEvent = function(n) {
|
|
1047
|
+
e === n.target || e.contains(n.target) || t.value(n);
|
|
1048
|
+
}, document.addEventListener("click", e.clickOutsideEvent);
|
|
1049
|
+
},
|
|
1050
|
+
unmounted(e) {
|
|
1051
|
+
document.removeEventListener("click", e.clickOutsideEvent);
|
|
1052
|
+
}
|
|
969
1053
|
};
|
|
970
|
-
|
|
971
|
-
|
|
1054
|
+
//#endregion
|
|
1055
|
+
//#region src/utils/hasCustomEventListener.ts
|
|
1056
|
+
function Nn(e) {
|
|
1057
|
+
return e.replace(/[:\s_-]+(.)/g, (e, t) => t.toUpperCase()).replace(/^[A-Z]/, (e) => e.toLowerCase());
|
|
972
1058
|
}
|
|
973
|
-
function
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
`on:${n}`
|
|
988
|
-
].some(
|
|
989
|
-
(c) => !!o[c]
|
|
990
|
-
);
|
|
1059
|
+
function Pn(e) {
|
|
1060
|
+
let t = S();
|
|
1061
|
+
if (!t) return !1;
|
|
1062
|
+
let n = t.vnode.props;
|
|
1063
|
+
if (!n) return !1;
|
|
1064
|
+
let r = Nn(e), i = f(e);
|
|
1065
|
+
return [
|
|
1066
|
+
L(e),
|
|
1067
|
+
L(i),
|
|
1068
|
+
L(r),
|
|
1069
|
+
`on:${e}`,
|
|
1070
|
+
`on:${i}`,
|
|
1071
|
+
`on:${r}`
|
|
1072
|
+
].some((e) => !!n[e]);
|
|
991
1073
|
}
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
},
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
}
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
},
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1074
|
+
//#endregion
|
|
1075
|
+
//#region src/form/text/MarkdownFallback.vue?vue&type=script&setup=true&lang.ts
|
|
1076
|
+
var Fn = [
|
|
1077
|
+
"id",
|
|
1078
|
+
"aria-label",
|
|
1079
|
+
"value"
|
|
1080
|
+
], In = /* @__PURE__ */ x({
|
|
1081
|
+
__name: "MarkdownFallback",
|
|
1082
|
+
props: /* @__PURE__ */ T(e, {
|
|
1083
|
+
modelValue: {},
|
|
1084
|
+
modelModifiers: {}
|
|
1085
|
+
}),
|
|
1086
|
+
emits: /* @__PURE__ */ T(a, ["update:modelValue"]),
|
|
1087
|
+
setup(e, { emit: t }) {
|
|
1088
|
+
let n = e, r = t, i = z(e, "modelValue"), a = (e) => {
|
|
1089
|
+
let t = e.target.value;
|
|
1090
|
+
i.value = t, r("change", t);
|
|
1091
|
+
};
|
|
1092
|
+
return (e, t) => (j(), m(c, k(C(n)), {
|
|
1093
|
+
default: V(() => [_("textarea", {
|
|
1094
|
+
id: e.id,
|
|
1095
|
+
"aria-label": e.id,
|
|
1096
|
+
class: O([[e.minHeight, e.width], "textarea textarea-bordered w-full font-mono text-sm"]),
|
|
1097
|
+
value: i.value ?? "",
|
|
1098
|
+
onInput: a
|
|
1099
|
+
}, null, 42, Fn)]),
|
|
1100
|
+
_: 1
|
|
1101
|
+
}, 16));
|
|
1102
|
+
}
|
|
1103
|
+
}), Ln = ["select"], Rn = {
|
|
1104
|
+
options: {
|
|
1105
|
+
type: Array,
|
|
1106
|
+
required: !1
|
|
1107
|
+
},
|
|
1108
|
+
isLoading: {
|
|
1109
|
+
type: Boolean,
|
|
1110
|
+
default: !1
|
|
1111
|
+
},
|
|
1112
|
+
query: {
|
|
1113
|
+
type: String,
|
|
1114
|
+
default: void 0
|
|
1115
|
+
},
|
|
1116
|
+
isActive: {
|
|
1117
|
+
type: Function,
|
|
1118
|
+
default: (e) => !1
|
|
1119
|
+
},
|
|
1120
|
+
teleported: {
|
|
1121
|
+
type: Boolean,
|
|
1122
|
+
default: !1
|
|
1123
|
+
}
|
|
1124
|
+
}, zn = {
|
|
1125
|
+
...s,
|
|
1126
|
+
options: {
|
|
1127
|
+
type: Array,
|
|
1128
|
+
required: !0
|
|
1129
|
+
},
|
|
1130
|
+
labelKey: {
|
|
1131
|
+
type: String,
|
|
1132
|
+
default: "label"
|
|
1133
|
+
},
|
|
1134
|
+
valueKey: {
|
|
1135
|
+
type: String,
|
|
1136
|
+
default: "value"
|
|
1137
|
+
},
|
|
1138
|
+
enableCreate: {
|
|
1139
|
+
type: Boolean,
|
|
1140
|
+
default: !1
|
|
1141
|
+
},
|
|
1142
|
+
clearable: {
|
|
1143
|
+
type: Boolean,
|
|
1144
|
+
default: !1
|
|
1145
|
+
},
|
|
1146
|
+
value: {
|
|
1147
|
+
type: null,
|
|
1148
|
+
default: void 0
|
|
1149
|
+
}
|
|
1150
|
+
}, Bn = [
|
|
1151
|
+
"select",
|
|
1152
|
+
"clear",
|
|
1153
|
+
"close",
|
|
1154
|
+
"create"
|
|
1155
|
+
], Vn = {
|
|
1156
|
+
...Rn,
|
|
1157
|
+
...zn,
|
|
1158
|
+
isOpen: {
|
|
1159
|
+
type: Boolean,
|
|
1160
|
+
default: !1
|
|
1161
|
+
},
|
|
1162
|
+
isActive: {
|
|
1163
|
+
type: Function,
|
|
1164
|
+
default: (e) => !1
|
|
1165
|
+
}
|
|
1166
|
+
}, Hn = {
|
|
1167
|
+
key: 1,
|
|
1168
|
+
tabindex: "-1",
|
|
1169
|
+
class: "pointer-events-none"
|
|
1170
|
+
}, Un = [
|
|
1171
|
+
"data-index",
|
|
1172
|
+
"aria-selected",
|
|
1173
|
+
"aria-disabled",
|
|
1174
|
+
"onMousedown",
|
|
1175
|
+
"onMousemove"
|
|
1176
|
+
], Wn = ["innerHTML"], Gn = {
|
|
1177
|
+
key: 0,
|
|
1178
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1179
|
+
class: "h-4 w-4 shrink-0 opacity-80 text-primary",
|
|
1180
|
+
fill: "none",
|
|
1181
|
+
viewBox: "0 0 24 24",
|
|
1182
|
+
stroke: "currentColor",
|
|
1183
|
+
"stroke-width": "2.5"
|
|
1085
1184
|
};
|
|
1086
|
-
function
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
new RegExp(`(${o})`, "gi"),
|
|
1091
|
-
'<mark class="bg-warning/40 text-inherit rounded-sm px-0.5">$1</mark>'
|
|
1092
|
-
);
|
|
1185
|
+
function Kn(e, t, n) {
|
|
1186
|
+
if (e || !n) return t;
|
|
1187
|
+
let r = n.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
1188
|
+
return t.replace(RegExp(`(${r})`, "gi"), "<mark class=\"bg-warning/40 text-inherit rounded-sm px-0.5\">$1</mark>");
|
|
1093
1189
|
}
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
},
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
u("button", {
|
|
1390
|
-
type: "button",
|
|
1391
|
-
class: $(["truncate block text-left", [m.value, A.width]]),
|
|
1392
|
-
"aria-label": A.id,
|
|
1393
|
-
role: "combobox",
|
|
1394
|
-
onClick: C[0] || (C[0] = (T) => o.value = !0)
|
|
1395
|
-
}, w(i.value ?? "Select value"), 11, Xo)
|
|
1396
|
-
]),
|
|
1397
|
-
_: 1
|
|
1398
|
-
}, 16, ["options", "disabled", "is-open", "query"]));
|
|
1399
|
-
}
|
|
1400
|
-
}), Zo = {
|
|
1401
|
-
...ve,
|
|
1402
|
-
...ge,
|
|
1403
|
-
/** v-model binding */
|
|
1404
|
-
modelValue: {
|
|
1405
|
-
type: [String, Object],
|
|
1406
|
-
default: ""
|
|
1407
|
-
},
|
|
1408
|
-
/**
|
|
1409
|
-
* HTTP mode: async function that receives the search string and returns
|
|
1410
|
-
* an array of strings or { label, value } objects.
|
|
1411
|
-
* e.g. :fetchOptions="(q) => fetch(`/api/search?q=${q}`).then(r => r.json())"
|
|
1412
|
-
*/
|
|
1413
|
-
fetchOptions: {
|
|
1414
|
-
type: Function,
|
|
1415
|
-
default: null
|
|
1416
|
-
},
|
|
1417
|
-
/** Debounce delay in ms for HTTP mode */
|
|
1418
|
-
debounceMs: {
|
|
1419
|
-
type: Number,
|
|
1420
|
-
default: 200
|
|
1421
|
-
},
|
|
1422
|
-
/** How many results to show at once */
|
|
1423
|
-
maxResults: {
|
|
1424
|
-
type: Number,
|
|
1425
|
-
default: 8
|
|
1426
|
-
},
|
|
1427
|
-
/** Allow free-text (don't clear input if nothing selected) */
|
|
1428
|
-
freeText: {
|
|
1429
|
-
type: Boolean,
|
|
1430
|
-
default: !1
|
|
1431
|
-
}
|
|
1190
|
+
//#endregion
|
|
1191
|
+
//#region src/form/select/ListResults.vue
|
|
1192
|
+
var qn = /* @__PURE__ */ x({
|
|
1193
|
+
__name: "ListResults",
|
|
1194
|
+
props: Rn,
|
|
1195
|
+
emits: Ln,
|
|
1196
|
+
setup(e, { expose: t, emit: n }) {
|
|
1197
|
+
let r = e, i = M(-1), a = M(), o = n;
|
|
1198
|
+
B(() => r.options, () => {
|
|
1199
|
+
i.value = -1;
|
|
1200
|
+
});
|
|
1201
|
+
function s() {
|
|
1202
|
+
D(() => {
|
|
1203
|
+
(a.value?.querySelector(`[data-index="${i.value}"]`))?.scrollIntoView({ block: "nearest" });
|
|
1204
|
+
});
|
|
1205
|
+
}
|
|
1206
|
+
function c(e) {
|
|
1207
|
+
let t = r.options?.length ?? 0;
|
|
1208
|
+
if (t) switch (e.key) {
|
|
1209
|
+
case "ArrowDown":
|
|
1210
|
+
e.preventDefault(), i.value = (i.value + 1) % t, s();
|
|
1211
|
+
break;
|
|
1212
|
+
case "ArrowUp":
|
|
1213
|
+
e.preventDefault(), i.value = i.value <= 0 ? t - 1 : i.value - 1, s();
|
|
1214
|
+
break;
|
|
1215
|
+
case "Enter":
|
|
1216
|
+
if (e.preventDefault(), i.value >= 0 && i.value < t) {
|
|
1217
|
+
let e = r.options[i.value];
|
|
1218
|
+
e.disabled || u(e);
|
|
1219
|
+
}
|
|
1220
|
+
break;
|
|
1221
|
+
}
|
|
1222
|
+
}
|
|
1223
|
+
function u(e) {
|
|
1224
|
+
i.value = -1, o("select", e);
|
|
1225
|
+
}
|
|
1226
|
+
return t({ handleKeydown: c }), (e, t) => (j(), g("ul", {
|
|
1227
|
+
ref_key: "listRef",
|
|
1228
|
+
ref: a,
|
|
1229
|
+
role: "listbox",
|
|
1230
|
+
"data-select-listbox": "",
|
|
1231
|
+
class: O(["bg-base-100 border border-base-300 rounded-box shadow-xl overflow-auto max-h-72 origin-top p-1", e.teleported ? "" : "absolute z-50 w-full mt-1"])
|
|
1232
|
+
}, [e.isLoading ? (j(), g(l, { key: 0 }, N(2, (e) => _("li", {
|
|
1233
|
+
key: `skel-${e}`,
|
|
1234
|
+
class: "pointer-events-none px-3 py-2"
|
|
1235
|
+
}, [...t[0] ||= [_("div", { class: "flex items-center gap-3" }, [_("div", { class: "skeleton h-3 w-3/4 rounded" })], -1)]])), 64)) : e.options?.length === 0 ? (j(), g("li", Hn, [...t[1] ||= [_("span", { class: "px-3 py-2 text-sm opacity-50 italic" }, " No results found ", -1)]])) : (j(!0), g(l, { key: 2 }, N(e.options, (n, r) => (j(), g("li", {
|
|
1236
|
+
key: n.value,
|
|
1237
|
+
"data-index": r,
|
|
1238
|
+
role: "option",
|
|
1239
|
+
"aria-selected": r === i.value,
|
|
1240
|
+
"aria-disabled": n.disabled,
|
|
1241
|
+
onMousedown: U((e) => !n.disabled && u(n), ["prevent"]),
|
|
1242
|
+
onMousemove: (e) => !n.disabled && (i.value = r)
|
|
1243
|
+
}, [_("a", { class: O(["text-sm flex items-center justify-between gap-2 rounded-lg px-3 py-2 text-sm text-base-content no-underline transition-colors duration-100", {
|
|
1244
|
+
"opacity-40 cursor-not-allowed": n.disabled,
|
|
1245
|
+
"cursor-pointer": !n.disabled,
|
|
1246
|
+
"bg-base-200": !n.disabled && r === i.value,
|
|
1247
|
+
"bg-base-300": e.isActive(n),
|
|
1248
|
+
"hover:bg-base-200": !n.disabled && r !== i.value
|
|
1249
|
+
}]) }, [_("span", {
|
|
1250
|
+
class: "whitespace-nowrap",
|
|
1251
|
+
innerHTML: Kn(e.isActive(n), n.label, e.query)
|
|
1252
|
+
}, null, 8, Wn), e.isActive(n) ? (j(), g("svg", Gn, [...t[2] ||= [_("path", {
|
|
1253
|
+
"stroke-linecap": "round",
|
|
1254
|
+
"stroke-linejoin": "round",
|
|
1255
|
+
d: "M5 13l4 4L19 7"
|
|
1256
|
+
}, null, -1)]])) : h("", !0)], 2)], 40, Un))), 128))], 2));
|
|
1257
|
+
}
|
|
1258
|
+
}), Jn = ["aria-label"], Yn = { class: "flex items-center w-full" }, Xn = { class: "overflow-hidden w-full" }, Zn = { class: "absolute inset-y-0 right-0 flex items-center pr-3 gap-1 pointer-events-none" }, Qn = {
|
|
1259
|
+
key: 0,
|
|
1260
|
+
class: "loading loading-spinner loading-xs text-primary pointer-events-none"
|
|
1261
|
+
}, $n = /* @__PURE__ */ x({
|
|
1262
|
+
__name: "SelectWrapper",
|
|
1263
|
+
props: Vn,
|
|
1264
|
+
emits: Bn,
|
|
1265
|
+
setup(e, { emit: t }) {
|
|
1266
|
+
let n = e, r = M(), i = M(), a = M(), o = t, s = M("body"), l = p(() => {
|
|
1267
|
+
let e = i.value ?? r.value;
|
|
1268
|
+
if (!e) return {};
|
|
1269
|
+
let t = e.getBoundingClientRect();
|
|
1270
|
+
return {
|
|
1271
|
+
position: "fixed",
|
|
1272
|
+
zIndex: 9999,
|
|
1273
|
+
top: `${t.bottom + 4}px`,
|
|
1274
|
+
left: `${t.left}px`,
|
|
1275
|
+
width: `${t.width}px`
|
|
1276
|
+
};
|
|
1277
|
+
}), f = () => {
|
|
1278
|
+
v(), o("clear");
|
|
1279
|
+
}, v = () => {
|
|
1280
|
+
o("close");
|
|
1281
|
+
}, b = (e) => {
|
|
1282
|
+
if (e.key === "Escape") {
|
|
1283
|
+
v();
|
|
1284
|
+
return;
|
|
1285
|
+
}
|
|
1286
|
+
a.value?.handleKeydown(e);
|
|
1287
|
+
}, x = (e) => {
|
|
1288
|
+
r.value && !r.value.contains(e.target) && v();
|
|
1289
|
+
};
|
|
1290
|
+
return ee(() => {
|
|
1291
|
+
document.addEventListener("click", x);
|
|
1292
|
+
let e = r.value?.closest("dialog");
|
|
1293
|
+
e && (s.value = e);
|
|
1294
|
+
}), te(() => {
|
|
1295
|
+
document.removeEventListener("click", x);
|
|
1296
|
+
}), (e, t) => (j(), g("div", {
|
|
1297
|
+
ref_key: "selectWrapperRef",
|
|
1298
|
+
ref: r,
|
|
1299
|
+
"aria-label": e.id,
|
|
1300
|
+
role: "select"
|
|
1301
|
+
}, [y(c, k(C(n)), {
|
|
1302
|
+
default: V(() => [_("div", Yn, [_("div", {
|
|
1303
|
+
ref_key: "inputWrapperRef",
|
|
1304
|
+
ref: i,
|
|
1305
|
+
class: "relative w-full",
|
|
1306
|
+
onKeydown: b
|
|
1307
|
+
}, [
|
|
1308
|
+
_("div", Xn, [P(e.$slots, "default")]),
|
|
1309
|
+
_("div", Zn, [
|
|
1310
|
+
e.isLoading && !e.label ? (j(), g("span", Qn)) : h("", !0),
|
|
1311
|
+
e.query && !e.isLoading && e.clearable ? (j(), g("button", {
|
|
1312
|
+
key: 1,
|
|
1313
|
+
type: "button",
|
|
1314
|
+
class: "pointer-events-auto btn btn-ghost btn-xs btn-circle opacity-60 hover:opacity-100",
|
|
1315
|
+
tabindex: "-1",
|
|
1316
|
+
"aria-label": "Clear",
|
|
1317
|
+
onMousedown: U(f, ["prevent"])
|
|
1318
|
+
}, [...t[2] ||= [_("svg", {
|
|
1319
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1320
|
+
class: "h-3.5 w-3.5",
|
|
1321
|
+
fill: "none",
|
|
1322
|
+
viewBox: "0 0 24 24",
|
|
1323
|
+
stroke: "currentColor",
|
|
1324
|
+
"stroke-width": "2.5"
|
|
1325
|
+
}, [_("path", {
|
|
1326
|
+
"stroke-linecap": "round",
|
|
1327
|
+
"stroke-linejoin": "round",
|
|
1328
|
+
d: "M6 18L18 6M6 6l12 12"
|
|
1329
|
+
})], -1)]], 32)) : h("", !0),
|
|
1330
|
+
(j(), g("svg", {
|
|
1331
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1332
|
+
class: O(["h-4 w-4 opacity-40 transition-transform duration-200", { "rotate-180": e.isOpen }]),
|
|
1333
|
+
fill: "none",
|
|
1334
|
+
viewBox: "0 0 24 24",
|
|
1335
|
+
stroke: "currentColor",
|
|
1336
|
+
"stroke-width": "2"
|
|
1337
|
+
}, [...t[3] ||= [_("path", {
|
|
1338
|
+
"stroke-linecap": "round",
|
|
1339
|
+
"stroke-linejoin": "round",
|
|
1340
|
+
d: "M19 9l-7 7-7-7"
|
|
1341
|
+
}, null, -1)]], 2))
|
|
1342
|
+
]),
|
|
1343
|
+
(j(), m(u, { to: s.value }, [y(d, {
|
|
1344
|
+
"enter-active-class": "transition-all duration-150 ease-out",
|
|
1345
|
+
"enter-from-class": "opacity-0 -translate-y-1 scale-y-95",
|
|
1346
|
+
"enter-to-class": "opacity-100 translate-y-0 scale-y-100",
|
|
1347
|
+
"leave-active-class": "transition-all duration-100 ease-in",
|
|
1348
|
+
"leave-from-class": "opacity-100 translate-y-0 scale-y-100",
|
|
1349
|
+
"leave-to-class": "opacity-0 -translate-y-1 scale-y-95"
|
|
1350
|
+
}, {
|
|
1351
|
+
default: V(() => [e.isOpen ? (j(), m(qn, {
|
|
1352
|
+
key: 0,
|
|
1353
|
+
ref_key: "listResultsRef",
|
|
1354
|
+
ref: a,
|
|
1355
|
+
teleported: !0,
|
|
1356
|
+
style: A(l.value),
|
|
1357
|
+
query: void 0,
|
|
1358
|
+
options: e.options,
|
|
1359
|
+
"is-loading": e.isLoading,
|
|
1360
|
+
"is-active": e.isActive,
|
|
1361
|
+
onSelect: t[0] ||= (e) => o("select", e)
|
|
1362
|
+
}, null, 8, [
|
|
1363
|
+
"style",
|
|
1364
|
+
"options",
|
|
1365
|
+
"is-loading",
|
|
1366
|
+
"is-active"
|
|
1367
|
+
])) : h("", !0)]),
|
|
1368
|
+
_: 1
|
|
1369
|
+
})], 8, ["to"]))
|
|
1370
|
+
], 544), e.enableCreate ? (j(), m(Z, {
|
|
1371
|
+
key: 0,
|
|
1372
|
+
icon: R(G).Plus,
|
|
1373
|
+
color: R(X).blank,
|
|
1374
|
+
size: "lg",
|
|
1375
|
+
tooltip: "Create new",
|
|
1376
|
+
"aria-label": "create",
|
|
1377
|
+
onClick: t[1] ||= (e) => o("create")
|
|
1378
|
+
}, null, 8, ["icon", "color"])) : h("", !0)])]),
|
|
1379
|
+
_: 3
|
|
1380
|
+
}, 16)], 8, Jn));
|
|
1381
|
+
}
|
|
1382
|
+
}), er = (e, t) => {
|
|
1383
|
+
if (e) return typeof e == "object" ? e[t.labelKey] : e;
|
|
1384
|
+
}, tr = (e, t) => {
|
|
1385
|
+
if (e) return typeof e == "object" ? e[t.valueKey] : e;
|
|
1386
|
+
}, nr = (e) => {
|
|
1387
|
+
let t = M([]), n = /* @__PURE__ */ new Map(), r = /* @__PURE__ */ new Map(), i = (i) => {
|
|
1388
|
+
let a = [];
|
|
1389
|
+
n.clear(), r.clear(), i?.forEach((t) => {
|
|
1390
|
+
let i = {
|
|
1391
|
+
value: tr(t, e),
|
|
1392
|
+
label: er(t, e),
|
|
1393
|
+
...t?.disabled !== void 0 && { disabled: !!t.disabled }
|
|
1394
|
+
};
|
|
1395
|
+
n.set(i.value, t), r.set(i.value, i), a.push(i);
|
|
1396
|
+
}), t.value = a;
|
|
1397
|
+
}, a = (e) => n.get(e.value);
|
|
1398
|
+
return {
|
|
1399
|
+
options: t,
|
|
1400
|
+
setOptions: i,
|
|
1401
|
+
getOriginal: a,
|
|
1402
|
+
getLabels: (...t) => t.map((t) => t != null && typeof t != "object" ? r.get(String(t))?.label ?? String(t) : er(t, e)),
|
|
1403
|
+
getValues: (...t) => t.map((t) => tr(t, e)),
|
|
1404
|
+
getOption: (t) => r.get(tr(t, e)),
|
|
1405
|
+
getOriginals: (...e) => e.map(a).filter(Boolean)
|
|
1406
|
+
};
|
|
1407
|
+
}, rr = (e) => nr(e), ir = ["aria-label"], ar = /* @__PURE__ */ x({
|
|
1408
|
+
__name: "SelectComponent",
|
|
1409
|
+
props: /* @__PURE__ */ T(zn, {
|
|
1410
|
+
modelValue: {},
|
|
1411
|
+
modelModifiers: {}
|
|
1412
|
+
}),
|
|
1413
|
+
emits: /* @__PURE__ */ T([
|
|
1414
|
+
"update:modelValue",
|
|
1415
|
+
"change",
|
|
1416
|
+
"clear",
|
|
1417
|
+
"focus",
|
|
1418
|
+
"blur"
|
|
1419
|
+
], ["update:modelValue"]),
|
|
1420
|
+
setup(e, { emit: n }) {
|
|
1421
|
+
let r = M(!1), a = e, o = n, s = z(e, "modelValue"), c = rr(a), { options: l } = c;
|
|
1422
|
+
B(() => a.options, () => {
|
|
1423
|
+
c.setOptions(a.options);
|
|
1424
|
+
}, { immediate: !0 });
|
|
1425
|
+
let u = (e) => {
|
|
1426
|
+
o("change", e);
|
|
1427
|
+
}, d = p(() => s.value ?? a.value), f = p(() => d.value ? c.getLabels(d.value)[0] : ""), h = p(() => t(a.styles)), g = p(() => i(h.value.control.select, a)), v = (e) => {
|
|
1428
|
+
let t = c.getOriginal(e);
|
|
1429
|
+
s.value = t, r.value = !1, u(t);
|
|
1430
|
+
}, y = () => {
|
|
1431
|
+
r.value = !1, s.value = null, u(void 0);
|
|
1432
|
+
}, b = (e) => c.getValues(d.value)?.[0] === e.value, x = () => {
|
|
1433
|
+
r.value = !1;
|
|
1434
|
+
};
|
|
1435
|
+
return (e, t) => (j(), m($n, E(a, {
|
|
1436
|
+
options: R(l),
|
|
1437
|
+
disabled: !e.enabled,
|
|
1438
|
+
"is-open": r.value,
|
|
1439
|
+
query: f.value,
|
|
1440
|
+
"is-active": b,
|
|
1441
|
+
clearable: a.clearable,
|
|
1442
|
+
onClose: x,
|
|
1443
|
+
onSelect: v,
|
|
1444
|
+
onClear: y
|
|
1445
|
+
}), {
|
|
1446
|
+
default: V(() => [_("button", {
|
|
1447
|
+
type: "button",
|
|
1448
|
+
class: O(["truncate block text-left", [g.value, e.width]]),
|
|
1449
|
+
"aria-label": e.id,
|
|
1450
|
+
role: "combobox",
|
|
1451
|
+
onClick: t[0] ||= (e) => r.value = !0
|
|
1452
|
+
}, I(f.value ?? "Select value"), 11, ir)]),
|
|
1453
|
+
_: 1
|
|
1454
|
+
}, 16, [
|
|
1455
|
+
"options",
|
|
1456
|
+
"disabled",
|
|
1457
|
+
"is-open",
|
|
1458
|
+
"query",
|
|
1459
|
+
"clearable"
|
|
1460
|
+
]));
|
|
1461
|
+
}
|
|
1462
|
+
}), or = {
|
|
1463
|
+
...zn,
|
|
1464
|
+
...Rn,
|
|
1465
|
+
modelValue: {
|
|
1466
|
+
type: [String, Object],
|
|
1467
|
+
default: ""
|
|
1468
|
+
},
|
|
1469
|
+
fetchOptions: {
|
|
1470
|
+
type: Function,
|
|
1471
|
+
default: null
|
|
1472
|
+
},
|
|
1473
|
+
debounceMs: {
|
|
1474
|
+
type: Number,
|
|
1475
|
+
default: 200
|
|
1476
|
+
},
|
|
1477
|
+
maxResults: {
|
|
1478
|
+
type: Number,
|
|
1479
|
+
default: 8
|
|
1480
|
+
},
|
|
1481
|
+
freeText: {
|
|
1482
|
+
type: Boolean,
|
|
1483
|
+
default: !1
|
|
1484
|
+
}
|
|
1432
1485
|
};
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1486
|
+
//#endregion
|
|
1487
|
+
//#region src/form/select/composables/useSearch.ts
|
|
1488
|
+
function sr(e) {
|
|
1489
|
+
let t = M([]), n = M(!1);
|
|
1490
|
+
function r(n) {
|
|
1491
|
+
if (!e.options) {
|
|
1492
|
+
t.value = [];
|
|
1493
|
+
return;
|
|
1494
|
+
}
|
|
1495
|
+
let r = n.toLowerCase();
|
|
1496
|
+
t.value = (r ? e.options.filter((t) => er(t, e).toLowerCase().includes(r)) : e.options).slice(0, e.maxResults);
|
|
1497
|
+
}
|
|
1498
|
+
function i() {
|
|
1499
|
+
t.value = [];
|
|
1500
|
+
}
|
|
1501
|
+
return {
|
|
1502
|
+
results: t,
|
|
1503
|
+
isLoading: n,
|
|
1504
|
+
search: r,
|
|
1505
|
+
clear: i
|
|
1506
|
+
};
|
|
1449
1507
|
}
|
|
1450
|
-
function
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1508
|
+
function cr(e) {
|
|
1509
|
+
let t = M([]), n = M(!1), r = null, i = null;
|
|
1510
|
+
async function a(r) {
|
|
1511
|
+
i && i.abort(), i = new AbortController(), n.value = !0;
|
|
1512
|
+
try {
|
|
1513
|
+
t.value = (await e.fetchOptions(r, i.signal) || []).slice(0, e.maxResults);
|
|
1514
|
+
} catch (e) {
|
|
1515
|
+
e.name !== "AbortError" && (t.value = []);
|
|
1516
|
+
} finally {
|
|
1517
|
+
n.value = !1;
|
|
1518
|
+
}
|
|
1519
|
+
}
|
|
1520
|
+
function o(t) {
|
|
1521
|
+
r && clearTimeout(r), n.value = !0, r = setTimeout(() => {
|
|
1522
|
+
a(t);
|
|
1523
|
+
}, e.debounceMs);
|
|
1524
|
+
}
|
|
1525
|
+
function s() {
|
|
1526
|
+
r && clearTimeout(r), i && i.abort(), t.value = [], n.value = !1;
|
|
1527
|
+
}
|
|
1528
|
+
return {
|
|
1529
|
+
results: t,
|
|
1530
|
+
isLoading: n,
|
|
1531
|
+
search: o,
|
|
1532
|
+
clear: s
|
|
1533
|
+
};
|
|
1473
1534
|
}
|
|
1474
|
-
function
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1535
|
+
function lr(e) {
|
|
1536
|
+
let t = e.fetchOptions ? cr(e) : sr(e);
|
|
1537
|
+
function n(e) {
|
|
1538
|
+
t.search(e);
|
|
1539
|
+
}
|
|
1540
|
+
return {
|
|
1541
|
+
results: t.results,
|
|
1542
|
+
isLoading: t.isLoading,
|
|
1543
|
+
triggerSearch: n,
|
|
1544
|
+
clear: t.clear
|
|
1545
|
+
};
|
|
1485
1546
|
}
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1525
|
-
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
}
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
|
|
1611
|
-
|
|
1612
|
-
|
|
1613
|
-
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
|
|
1617
|
-
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
|
|
1674
|
-
|
|
1675
|
-
|
|
1676
|
-
|
|
1677
|
-
|
|
1678
|
-
|
|
1679
|
-
|
|
1680
|
-
|
|
1681
|
-
|
|
1682
|
-
|
|
1683
|
-
|
|
1684
|
-
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
|
|
1736
|
-
|
|
1737
|
-
|
|
1738
|
-
|
|
1739
|
-
|
|
1740
|
-
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
|
|
1753
|
-
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
|
|
1788
|
-
|
|
1789
|
-
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
},
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
},
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
},
|
|
1893
|
-
|
|
1894
|
-
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
|
|
1915
|
-
|
|
1916
|
-
|
|
1917
|
-
|
|
1918
|
-
|
|
1919
|
-
|
|
1920
|
-
|
|
1921
|
-
|
|
1922
|
-
|
|
1923
|
-
|
|
1924
|
-
|
|
1925
|
-
|
|
1926
|
-
|
|
1927
|
-
|
|
1928
|
-
|
|
1929
|
-
|
|
1930
|
-
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
|
|
1935
|
-
|
|
1936
|
-
|
|
1937
|
-
|
|
1938
|
-
|
|
1939
|
-
|
|
1940
|
-
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
|
|
1955
|
-
|
|
1956
|
-
|
|
1957
|
-
|
|
1958
|
-
|
|
1959
|
-
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
},
|
|
1964
|
-
|
|
1965
|
-
|
|
1966
|
-
|
|
1967
|
-
|
|
1968
|
-
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
|
|
1985
|
-
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
|
|
1994
|
-
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
|
|
2000
|
-
|
|
2001
|
-
|
|
2002
|
-
|
|
2003
|
-
|
|
2004
|
-
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
|
-
|
|
2008
|
-
|
|
2009
|
-
|
|
2010
|
-
|
|
2011
|
-
|
|
2012
|
-
|
|
2013
|
-
|
|
2014
|
-
|
|
2015
|
-
|
|
2016
|
-
|
|
2017
|
-
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
|
|
2021
|
-
|
|
2022
|
-
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
|
|
2027
|
-
|
|
2028
|
-
|
|
2029
|
-
|
|
2030
|
-
|
|
2031
|
-
|
|
2032
|
-
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2040
|
-
|
|
2041
|
-
|
|
2042
|
-
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
|
|
2046
|
-
|
|
2047
|
-
|
|
2048
|
-
|
|
2049
|
-
|
|
2050
|
-
|
|
2051
|
-
|
|
2052
|
-
|
|
2053
|
-
|
|
2054
|
-
|
|
2055
|
-
|
|
2056
|
-
|
|
2057
|
-
|
|
2058
|
-
|
|
2059
|
-
|
|
2060
|
-
|
|
2061
|
-
|
|
2062
|
-
|
|
2063
|
-
|
|
2064
|
-
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
|
|
2074
|
-
}
|
|
2075
|
-
|
|
2076
|
-
|
|
2077
|
-
|
|
2078
|
-
|
|
2079
|
-
|
|
2080
|
-
|
|
2081
|
-
|
|
2082
|
-
|
|
2083
|
-
|
|
2084
|
-
|
|
2085
|
-
|
|
2086
|
-
|
|
2087
|
-
},
|
|
2088
|
-
|
|
2089
|
-
|
|
2090
|
-
|
|
2091
|
-
|
|
2092
|
-
|
|
2093
|
-
|
|
2094
|
-
|
|
2095
|
-
|
|
2096
|
-
|
|
2097
|
-
|
|
2098
|
-
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
|
|
2103
|
-
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
|
|
2108
|
-
|
|
2109
|
-
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2154
|
-
|
|
2155
|
-
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
|
|
2161
|
-
|
|
2162
|
-
|
|
2163
|
-
|
|
2164
|
-
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
|
|
2168
|
-
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
|
|
2172
|
-
|
|
2173
|
-
|
|
2174
|
-
|
|
2175
|
-
|
|
2176
|
-
|
|
2177
|
-
|
|
2178
|
-
|
|
2179
|
-
|
|
2180
|
-
|
|
2181
|
-
|
|
2182
|
-
|
|
2183
|
-
|
|
2184
|
-
|
|
2185
|
-
|
|
2186
|
-
|
|
2187
|
-
|
|
2188
|
-
|
|
2189
|
-
|
|
2190
|
-
|
|
2191
|
-
|
|
2192
|
-
|
|
2193
|
-
|
|
2194
|
-
|
|
2195
|
-
|
|
2196
|
-
|
|
2197
|
-
|
|
2198
|
-
|
|
2199
|
-
|
|
2200
|
-
|
|
2201
|
-
|
|
2202
|
-
|
|
2203
|
-
|
|
2204
|
-
|
|
2205
|
-
|
|
2206
|
-
|
|
2207
|
-
|
|
2208
|
-
|
|
2209
|
-
|
|
2210
|
-
|
|
2211
|
-
|
|
2212
|
-
|
|
2213
|
-
|
|
2214
|
-
|
|
2215
|
-
|
|
2216
|
-
|
|
2217
|
-
|
|
2218
|
-
|
|
2219
|
-
|
|
2220
|
-
|
|
2221
|
-
|
|
2222
|
-
|
|
2223
|
-
|
|
2224
|
-
|
|
2225
|
-
|
|
2226
|
-
|
|
2227
|
-
|
|
2228
|
-
|
|
2229
|
-
|
|
2230
|
-
|
|
2231
|
-
|
|
2232
|
-
|
|
2233
|
-
|
|
2234
|
-
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
|
|
2239
|
-
|
|
2240
|
-
|
|
2241
|
-
|
|
2242
|
-
|
|
2243
|
-
|
|
2244
|
-
|
|
2245
|
-
|
|
2246
|
-
|
|
2247
|
-
},
|
|
2248
|
-
|
|
2249
|
-
|
|
2250
|
-
},
|
|
2251
|
-
|
|
2252
|
-
|
|
2253
|
-
|
|
2254
|
-
|
|
2255
|
-
|
|
2256
|
-
|
|
2257
|
-
|
|
2258
|
-
|
|
2259
|
-
|
|
2260
|
-
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
|
|
2264
|
-
|
|
2265
|
-
|
|
2266
|
-
|
|
2267
|
-
|
|
2268
|
-
onClick: m[0] || (m[0] = //@ts-ignore
|
|
2269
|
-
(...b) => g(d) && g(d)(...b))
|
|
2270
|
-
}, " All "),
|
|
2271
|
-
u("button", {
|
|
2272
|
-
class: "btn btn-ghost btn-xs",
|
|
2273
|
-
type: "button",
|
|
2274
|
-
tabindex: "-1",
|
|
2275
|
-
onClick: m[1] || (m[1] = //@ts-ignore
|
|
2276
|
-
(...b) => g(p) && g(p)(...b))
|
|
2277
|
-
}, " None ")
|
|
2278
|
-
])
|
|
2279
|
-
]),
|
|
2280
|
-
u("div", rn, [
|
|
2281
|
-
(r(!0), f(L, null, M(l.value, (b) => (r(), f("label", {
|
|
2282
|
-
key: b[s.valueKey],
|
|
2283
|
-
class: $(["flex items-center gap-3 px-2 py-1.5 rounded-lg cursor-pointer transition-colors hover:bg-base-200", { "bg-base-200/60": g(a)(b[s.valueKey]) }])
|
|
2284
|
-
}, [
|
|
2285
|
-
u("input", {
|
|
2286
|
-
type: "checkbox",
|
|
2287
|
-
class: "checkbox checkbox-sm",
|
|
2288
|
-
checked: g(a)(b[s.valueKey]),
|
|
2289
|
-
onChange: (h) => g(i)(
|
|
2290
|
-
b[s.valueKey],
|
|
2291
|
-
h.target.checked
|
|
2292
|
-
)
|
|
2293
|
-
}, null, 40, un),
|
|
2294
|
-
s.colorKey && b[s.colorKey] ? (r(), f("span", {
|
|
2295
|
-
key: 0,
|
|
2296
|
-
class: "w-3 h-3 rounded-full shrink-0 ring-1 ring-black/10",
|
|
2297
|
-
style: X({ backgroundColor: b[s.colorKey] })
|
|
2298
|
-
}, null, 4)) : _("", !0),
|
|
2299
|
-
u("span", cn, w(b[s.labelKey]), 1),
|
|
2300
|
-
b[s.countKey] > 0 ? (r(), f("span", dn, w(b[s.countKey]), 1)) : _("", !0)
|
|
2301
|
-
], 2))), 128))
|
|
2302
|
-
])
|
|
2303
|
-
]),
|
|
2304
|
-
_: 1
|
|
2305
|
-
}, 8, ["title", "opened"]));
|
|
2306
|
-
}
|
|
1547
|
+
//#endregion
|
|
1548
|
+
//#region src/form/select/AutoComplete.vue?vue&type=script&setup=true&lang.ts
|
|
1549
|
+
var ur = [
|
|
1550
|
+
"aria-label",
|
|
1551
|
+
"aria-expanded",
|
|
1552
|
+
"value",
|
|
1553
|
+
"placeholder",
|
|
1554
|
+
"disabled"
|
|
1555
|
+
], dr = /* @__PURE__ */ x({
|
|
1556
|
+
__name: "AutoComplete",
|
|
1557
|
+
props: or,
|
|
1558
|
+
emits: [
|
|
1559
|
+
"update:modelValue",
|
|
1560
|
+
"change",
|
|
1561
|
+
"clear",
|
|
1562
|
+
"focus",
|
|
1563
|
+
"blur"
|
|
1564
|
+
],
|
|
1565
|
+
setup(e, { emit: n }) {
|
|
1566
|
+
let r = e, a = n, o = M(null), s = M(""), c = M(!1), l = lr(r), { isLoading: u, triggerSearch: d, clear: f } = l, h = rr(r), { options: g } = h;
|
|
1567
|
+
B(() => l.results.value, () => {
|
|
1568
|
+
h.setOptions(l.results.value);
|
|
1569
|
+
}, { immediate: !0 }), B(() => r.modelValue, (e) => {
|
|
1570
|
+
if (e == null || e === "") {
|
|
1571
|
+
s.value = "";
|
|
1572
|
+
return;
|
|
1573
|
+
}
|
|
1574
|
+
let t = typeof e == "object" ? e[r.labelKey] : e;
|
|
1575
|
+
t !== s.value && (s.value = t);
|
|
1576
|
+
}, { immediate: !0 });
|
|
1577
|
+
let v = (e) => {
|
|
1578
|
+
s.value = e.target.value, r.freeText ? a("update:modelValue", s.value) : a("update:modelValue", ""), d(s.value), c.value = !0;
|
|
1579
|
+
}, y = () => {
|
|
1580
|
+
d(s.value), c.value = !0;
|
|
1581
|
+
};
|
|
1582
|
+
function b() {
|
|
1583
|
+
setTimeout(() => {
|
|
1584
|
+
c.value = !1, r.freeText ? a("change", s.value) : r.modelValue || (s.value = "");
|
|
1585
|
+
}, 150);
|
|
1586
|
+
}
|
|
1587
|
+
let x = (e) => {
|
|
1588
|
+
let t = h.getOriginal(e);
|
|
1589
|
+
s.value = e.label, c.value = !1, a("update:modelValue", t), a("change", t);
|
|
1590
|
+
}, S = () => {
|
|
1591
|
+
s.value = "", f(), c.value = !1, a("update:modelValue", ""), a("clear"), D(() => o.value?.focus());
|
|
1592
|
+
}, C = () => {
|
|
1593
|
+
c.value = !1;
|
|
1594
|
+
}, w = p(() => t(r.styles)), T = p(() => i(w.value.control.select, r));
|
|
1595
|
+
return (e, t) => (j(), m($n, E(r, {
|
|
1596
|
+
options: R(g),
|
|
1597
|
+
"is-loading": R(u),
|
|
1598
|
+
"is-open": c.value,
|
|
1599
|
+
query: s.value,
|
|
1600
|
+
onClose: C,
|
|
1601
|
+
onSelect: x,
|
|
1602
|
+
onClear: S
|
|
1603
|
+
}), {
|
|
1604
|
+
default: V(() => [_("input", {
|
|
1605
|
+
ref_key: "inputRef",
|
|
1606
|
+
ref: o,
|
|
1607
|
+
type: "text",
|
|
1608
|
+
role: "combobox",
|
|
1609
|
+
"aria-label": e.id,
|
|
1610
|
+
"aria-expanded": c.value,
|
|
1611
|
+
"aria-autocomplete": "list",
|
|
1612
|
+
"aria-haspopup": "listbox",
|
|
1613
|
+
autocomplete: "off",
|
|
1614
|
+
autocorrect: "off",
|
|
1615
|
+
spellcheck: "false",
|
|
1616
|
+
class: O([T.value, "w-full"]),
|
|
1617
|
+
value: s.value,
|
|
1618
|
+
placeholder: e.placeholder,
|
|
1619
|
+
disabled: !e.enabled,
|
|
1620
|
+
onInput: v,
|
|
1621
|
+
onFocus: y,
|
|
1622
|
+
onBlur: b
|
|
1623
|
+
}, null, 42, ur)]),
|
|
1624
|
+
_: 1
|
|
1625
|
+
}, 16, [
|
|
1626
|
+
"options",
|
|
1627
|
+
"is-loading",
|
|
1628
|
+
"is-open",
|
|
1629
|
+
"query"
|
|
1630
|
+
]));
|
|
1631
|
+
}
|
|
1632
|
+
}), fr = ["aria-label"], pr = /* @__PURE__ */ x({
|
|
1633
|
+
__name: "MultiSelect",
|
|
1634
|
+
props: /* @__PURE__ */ T(Vn, {
|
|
1635
|
+
modelValue: {},
|
|
1636
|
+
modelModifiers: {}
|
|
1637
|
+
}),
|
|
1638
|
+
emits: /* @__PURE__ */ T([
|
|
1639
|
+
"update:modelValue",
|
|
1640
|
+
"change",
|
|
1641
|
+
"clear",
|
|
1642
|
+
"focus",
|
|
1643
|
+
"blur"
|
|
1644
|
+
], ["update:modelValue"]),
|
|
1645
|
+
setup(e, { emit: n }) {
|
|
1646
|
+
let r = M(!1), a = e, o = n, s = z(e, "modelValue"), c = (e) => {
|
|
1647
|
+
o("change", e);
|
|
1648
|
+
}, l = rr(a), { options: u } = l;
|
|
1649
|
+
B(() => a.options, () => {
|
|
1650
|
+
l.setOptions(a.options);
|
|
1651
|
+
}, { immediate: !0 });
|
|
1652
|
+
let d = p(() => s.value ? l.getLabels(...s.value).join(", ") : void 0), f = p(() => l.getValues(...s.value ?? [])), h = (e) => {
|
|
1653
|
+
let t = s.value ?? [];
|
|
1654
|
+
if (y(e)) t = t.filter((t) => l.getOption(t)?.value !== e.value);
|
|
1655
|
+
else {
|
|
1656
|
+
let n = l.getOriginal(e);
|
|
1657
|
+
t.push(n);
|
|
1658
|
+
}
|
|
1659
|
+
s.value = t, c(t);
|
|
1660
|
+
}, g = () => {
|
|
1661
|
+
r.value = !1, s.value = [], c([]);
|
|
1662
|
+
}, v = () => {
|
|
1663
|
+
r.value = !1;
|
|
1664
|
+
}, y = (e) => f.value?.includes(e.value) ?? !1, b = p(() => t(a.styles)), x = p(() => i(b.value.control.select, a));
|
|
1665
|
+
return (e, t) => (j(), m($n, E(a, {
|
|
1666
|
+
options: R(u),
|
|
1667
|
+
"is-open": r.value,
|
|
1668
|
+
disabled: !e.enabled,
|
|
1669
|
+
query: void 0,
|
|
1670
|
+
"is-active": y,
|
|
1671
|
+
onClose: v,
|
|
1672
|
+
onSelect: h,
|
|
1673
|
+
onClear: g
|
|
1674
|
+
}), {
|
|
1675
|
+
default: V(() => [_("button", {
|
|
1676
|
+
type: "button",
|
|
1677
|
+
class: O(["truncate block text-left", [x.value, e.width]]),
|
|
1678
|
+
"aria-label": e.id,
|
|
1679
|
+
role: "combobox",
|
|
1680
|
+
onClick: t[0] ||= (e) => r.value = !0
|
|
1681
|
+
}, I(d.value ?? "Select value"), 11, fr)]),
|
|
1682
|
+
_: 1
|
|
1683
|
+
}, 16, [
|
|
1684
|
+
"options",
|
|
1685
|
+
"is-open",
|
|
1686
|
+
"disabled"
|
|
1687
|
+
]));
|
|
1688
|
+
}
|
|
1689
|
+
}), mr = { ...s }, hr = [
|
|
1690
|
+
"change",
|
|
1691
|
+
"focus",
|
|
1692
|
+
"blur"
|
|
1693
|
+
], gr = { class: "flex items-center justify-center h-full" }, _r = { class: "fieldset-label" }, vr = ["aria-label", "disabled"], yr = { class: "font-bold text-gray-500 text-sm" }, br = /* @__PURE__ */ x({
|
|
1694
|
+
__name: "Checkbox",
|
|
1695
|
+
props: /* @__PURE__ */ T(mr, {
|
|
1696
|
+
modelValue: {},
|
|
1697
|
+
modelModifiers: {}
|
|
1698
|
+
}),
|
|
1699
|
+
emits: /* @__PURE__ */ T(hr, ["update:modelValue"]),
|
|
1700
|
+
setup(e, { emit: t }) {
|
|
1701
|
+
let n = e, r = t, a = z(e, "modelValue"), o = (e) => {
|
|
1702
|
+
r("change", a.value);
|
|
1703
|
+
}, s = (e) => {
|
|
1704
|
+
r("focus", e);
|
|
1705
|
+
}, l = (e) => {
|
|
1706
|
+
r("blur", e);
|
|
1707
|
+
}, u = p(() => i(n.styles.control.checkbox, n));
|
|
1708
|
+
return (e, t) => (j(), g("div", gr, [y(c, E(n, { "hide-label": !0 }), {
|
|
1709
|
+
default: V(() => [_("label", _r, [H(_("input", {
|
|
1710
|
+
"onUpdate:modelValue": t[0] ||= (e) => a.value = e,
|
|
1711
|
+
"aria-label": e.id,
|
|
1712
|
+
role: "checkbox",
|
|
1713
|
+
type: "checkbox",
|
|
1714
|
+
class: O(u.value),
|
|
1715
|
+
disabled: !e.enabled,
|
|
1716
|
+
onChange: o,
|
|
1717
|
+
onFocus: s,
|
|
1718
|
+
onBlur: l
|
|
1719
|
+
}, null, 42, vr), [[oe, a.value]]), _("span", yr, I(e.label), 1)])]),
|
|
1720
|
+
_: 1
|
|
1721
|
+
}, 16)]));
|
|
1722
|
+
}
|
|
1723
|
+
}), xr = {
|
|
1724
|
+
...s,
|
|
1725
|
+
type: {
|
|
1726
|
+
type: String,
|
|
1727
|
+
default: "text"
|
|
1728
|
+
},
|
|
1729
|
+
clearable: {
|
|
1730
|
+
type: Boolean,
|
|
1731
|
+
default: !1
|
|
1732
|
+
}
|
|
1733
|
+
}, Sr = [
|
|
1734
|
+
"change",
|
|
1735
|
+
"focus",
|
|
1736
|
+
"blur",
|
|
1737
|
+
"clear"
|
|
1738
|
+
], Cr = { class: "relative w-full" }, wr = [
|
|
1739
|
+
"aria-label",
|
|
1740
|
+
"type",
|
|
1741
|
+
"disabled",
|
|
1742
|
+
"autofocus",
|
|
1743
|
+
"placeholder"
|
|
1744
|
+
], Tr = /* @__PURE__ */ x({
|
|
1745
|
+
__name: "Input",
|
|
1746
|
+
props: /* @__PURE__ */ T(xr, {
|
|
1747
|
+
modelValue: {},
|
|
1748
|
+
modelModifiers: {}
|
|
1749
|
+
}),
|
|
1750
|
+
emits: /* @__PURE__ */ T(Sr, ["update:modelValue"]),
|
|
1751
|
+
setup(e, { emit: t }) {
|
|
1752
|
+
let n = e, r = t, a = z(e, "modelValue"), o = (e) => {
|
|
1753
|
+
r("change", e);
|
|
1754
|
+
}, s = (e) => {
|
|
1755
|
+
r("focus", e);
|
|
1756
|
+
}, l = (e) => {
|
|
1757
|
+
r("blur", e);
|
|
1758
|
+
}, u = () => {
|
|
1759
|
+
a.value = "", r("clear");
|
|
1760
|
+
}, d = p(() => i(n.styles.control.input, n));
|
|
1761
|
+
return (e, t) => (j(), m(c, k(C(n)), {
|
|
1762
|
+
default: V(() => [_("div", Cr, [H(_("input", {
|
|
1763
|
+
"onUpdate:modelValue": t[0] ||= (e) => a.value = e,
|
|
1764
|
+
"aria-label": e.id,
|
|
1765
|
+
autocomplete: "off",
|
|
1766
|
+
type: e.type,
|
|
1767
|
+
class: O([[d.value, { "pr-7": e.clearable && a.value }], "!w-full"]),
|
|
1768
|
+
disabled: !e.enabled,
|
|
1769
|
+
autofocus: e.isFocused,
|
|
1770
|
+
placeholder: e.placeholder,
|
|
1771
|
+
onChange: o,
|
|
1772
|
+
onFocus: s,
|
|
1773
|
+
onBlur: l
|
|
1774
|
+
}, null, 42, wr), [[se, a.value]]), e.clearable && a.value ? (j(), g("button", {
|
|
1775
|
+
key: 0,
|
|
1776
|
+
type: "button",
|
|
1777
|
+
class: "absolute inset-y-0 right-0 flex items-center pr-2 btn btn-ghost btn-xs btn-circle opacity-60 hover:opacity-100",
|
|
1778
|
+
tabindex: "-1",
|
|
1779
|
+
"aria-label": "Clear",
|
|
1780
|
+
onMousedown: U(u, ["prevent"])
|
|
1781
|
+
}, [...t[1] ||= [_("svg", {
|
|
1782
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1783
|
+
class: "h-3.5 w-3.5",
|
|
1784
|
+
fill: "none",
|
|
1785
|
+
viewBox: "0 0 24 24",
|
|
1786
|
+
stroke: "currentColor",
|
|
1787
|
+
"stroke-width": "2.5"
|
|
1788
|
+
}, [_("path", {
|
|
1789
|
+
"stroke-linecap": "round",
|
|
1790
|
+
"stroke-linejoin": "round",
|
|
1791
|
+
d: "M6 18L18 6M6 6l12 12"
|
|
1792
|
+
})], -1)]], 32)) : h("", !0)])]),
|
|
1793
|
+
_: 1
|
|
1794
|
+
}, 16));
|
|
1795
|
+
}
|
|
1796
|
+
}), Er = {
|
|
1797
|
+
...s,
|
|
1798
|
+
steps: {
|
|
1799
|
+
type: Number,
|
|
1800
|
+
default: 1
|
|
1801
|
+
}
|
|
1802
|
+
}, Dr = [
|
|
1803
|
+
"change",
|
|
1804
|
+
"focus",
|
|
1805
|
+
"blur"
|
|
1806
|
+
], Or = [
|
|
1807
|
+
"aria-label",
|
|
1808
|
+
"disabled",
|
|
1809
|
+
"step",
|
|
1810
|
+
"autofocus",
|
|
1811
|
+
"placeholder"
|
|
1812
|
+
], kr = /* @__PURE__ */ x({
|
|
1813
|
+
__name: "InputNumber",
|
|
1814
|
+
props: /* @__PURE__ */ T(Er, {
|
|
1815
|
+
modelValue: {},
|
|
1816
|
+
modelModifiers: {}
|
|
1817
|
+
}),
|
|
1818
|
+
emits: /* @__PURE__ */ T(Dr, ["update:modelValue"]),
|
|
1819
|
+
setup(e, { emit: t }) {
|
|
1820
|
+
let n = e, r = t, a = z(e, "modelValue"), o = (e) => {
|
|
1821
|
+
r("change", e);
|
|
1822
|
+
}, s = (e) => {
|
|
1823
|
+
r("focus", e);
|
|
1824
|
+
}, l = (e) => {
|
|
1825
|
+
r("blur", e);
|
|
1826
|
+
}, u = p(() => i(n.styles?.control?.input, n));
|
|
1827
|
+
return (e, t) => (j(), m(c, k(C(n)), {
|
|
1828
|
+
default: V(() => [H(_("input", {
|
|
1829
|
+
"onUpdate:modelValue": t[0] ||= (e) => a.value = e,
|
|
1830
|
+
autocomplete: "off",
|
|
1831
|
+
"aria-label": e.id,
|
|
1832
|
+
type: "number",
|
|
1833
|
+
class: O(["w-full", [u.value]]),
|
|
1834
|
+
disabled: !e.enabled,
|
|
1835
|
+
step: e.steps,
|
|
1836
|
+
autofocus: e.isFocused,
|
|
1837
|
+
placeholder: e.placeholder,
|
|
1838
|
+
onChange: o,
|
|
1839
|
+
onFocus: s,
|
|
1840
|
+
onBlur: l
|
|
1841
|
+
}, null, 42, Or), [[ce, a.value]])]),
|
|
1842
|
+
_: 1
|
|
1843
|
+
}, 16));
|
|
1844
|
+
}
|
|
1845
|
+
}), Ar = {
|
|
1846
|
+
...s,
|
|
1847
|
+
rows: {
|
|
1848
|
+
type: Number,
|
|
1849
|
+
default: 4
|
|
1850
|
+
},
|
|
1851
|
+
dir: {
|
|
1852
|
+
type: String,
|
|
1853
|
+
default: "ltr"
|
|
1854
|
+
},
|
|
1855
|
+
height: {
|
|
1856
|
+
type: String,
|
|
1857
|
+
default: void 0
|
|
1858
|
+
},
|
|
1859
|
+
minHeight: {
|
|
1860
|
+
type: String,
|
|
1861
|
+
default: void 0
|
|
1862
|
+
}
|
|
1863
|
+
}, jr = [
|
|
1864
|
+
"change",
|
|
1865
|
+
"focus",
|
|
1866
|
+
"blur"
|
|
1867
|
+
], Mr = [
|
|
1868
|
+
"aria-label",
|
|
1869
|
+
"disabled",
|
|
1870
|
+
"rows",
|
|
1871
|
+
"dir",
|
|
1872
|
+
"autofocus",
|
|
1873
|
+
"placeholder"
|
|
1874
|
+
], Nr = /* @__PURE__ */ x({
|
|
1875
|
+
__name: "Textarea",
|
|
1876
|
+
props: /* @__PURE__ */ T(Ar, {
|
|
1877
|
+
modelValue: {},
|
|
1878
|
+
modelModifiers: {}
|
|
1879
|
+
}),
|
|
1880
|
+
emits: /* @__PURE__ */ T(jr, ["update:modelValue"]),
|
|
1881
|
+
setup(e, { emit: t }) {
|
|
1882
|
+
let n = e, r = t, a = z(e, "modelValue"), o = (e) => {
|
|
1883
|
+
r("change", e);
|
|
1884
|
+
}, s = (e) => {
|
|
1885
|
+
r("focus", e);
|
|
1886
|
+
}, l = (e) => {
|
|
1887
|
+
r("blur", e);
|
|
1888
|
+
}, u = p(() => i(n.styles.control.textarea, n));
|
|
1889
|
+
return (e, t) => (j(), m(c, k(C(n)), {
|
|
1890
|
+
default: V(() => [H(_("textarea", {
|
|
1891
|
+
"onUpdate:modelValue": t[0] ||= (e) => a.value = e,
|
|
1892
|
+
autocomplete: "off",
|
|
1893
|
+
type: "text",
|
|
1894
|
+
"aria-label": e.id,
|
|
1895
|
+
class: O(["w-full", u.value]),
|
|
1896
|
+
disabled: !e.enabled,
|
|
1897
|
+
rows: e.rows,
|
|
1898
|
+
dir: e.dir,
|
|
1899
|
+
style: A({
|
|
1900
|
+
height: e.height,
|
|
1901
|
+
minHeight: e.minHeight
|
|
1902
|
+
}),
|
|
1903
|
+
autofocus: e.isFocused,
|
|
1904
|
+
placeholder: e.placeholder,
|
|
1905
|
+
onChange: o,
|
|
1906
|
+
onFocus: s,
|
|
1907
|
+
onBlur: l
|
|
1908
|
+
}, null, 46, Mr), [[ce, a.value]])]),
|
|
1909
|
+
_: 1
|
|
1910
|
+
}, 16));
|
|
1911
|
+
}
|
|
1912
|
+
}), Pr = b({
|
|
1913
|
+
loader: () => import("./Markdown-Dj1gzJJq.js"),
|
|
1914
|
+
errorComponent: In,
|
|
1915
|
+
onError(e, t, n) {
|
|
1916
|
+
console.warn("[@ghentcdh/ui] Markdown editor could not load — install the TipTap peer dependencies (@tiptap/pm, @tiptap/starter-kit, @tiptap/vue-3, tiptap-markdown) to enable it. Falling back to a plain textarea.", e), n();
|
|
1917
|
+
}
|
|
1918
|
+
}), Fr = {
|
|
1919
|
+
widthLeft: {
|
|
1920
|
+
type: Number,
|
|
1921
|
+
default: 200
|
|
1922
|
+
},
|
|
1923
|
+
widthRight: {
|
|
1924
|
+
type: Number,
|
|
1925
|
+
default: 200
|
|
1926
|
+
},
|
|
1927
|
+
initialLeftOpen: {
|
|
1928
|
+
type: Boolean,
|
|
1929
|
+
default: !0
|
|
1930
|
+
},
|
|
1931
|
+
initialRightOpen: {
|
|
1932
|
+
type: Boolean,
|
|
1933
|
+
default: !0
|
|
1934
|
+
},
|
|
1935
|
+
drawerColor: {
|
|
1936
|
+
type: String,
|
|
1937
|
+
default: "bg-base-200"
|
|
1938
|
+
}
|
|
1939
|
+
}, Ir = { class: "flex h-full overflow-hidden gap-2" }, Lr = {
|
|
1940
|
+
key: 0,
|
|
1941
|
+
id: "drawer-left",
|
|
1942
|
+
class: "min-h-0 relative flex-shrink-0 overflow-visible flex"
|
|
1943
|
+
}, Rr = ["aria-expanded", "aria-label"], zr = { class: "flex-1 overflow-y-auto bg-white" }, Br = {
|
|
1944
|
+
key: 1,
|
|
1945
|
+
class: "min-h-0 relative flex-shrink-0 bg-white overflow-visible flex"
|
|
1946
|
+
}, Vr = ["aria-expanded", "aria-label"], Hr = /* @__PURE__ */ x({
|
|
1947
|
+
__name: "drawer",
|
|
1948
|
+
props: Fr,
|
|
1949
|
+
setup(e) {
|
|
1950
|
+
let t = e, n = ae(), r = p(() => !!n["left-drawer"]), i = p(() => !!n["right-drawer"]), a = M({
|
|
1951
|
+
left: t.initialLeftOpen,
|
|
1952
|
+
right: t.initialRightOpen
|
|
1953
|
+
}), o = (e) => {
|
|
1954
|
+
a.value[e] = !a.value[e];
|
|
1955
|
+
};
|
|
1956
|
+
return (e, t) => (j(), g("main", Ir, [
|
|
1957
|
+
r.value ? (j(), g("aside", Lr, [_("div", {
|
|
1958
|
+
id: "drawer-left-panel",
|
|
1959
|
+
style: A({ width: a.value.left ? e.widthLeft + "px" : "0px" }),
|
|
1960
|
+
class: O(["h-full overflow-hidden shadow-sm transition-[width] duration-300 ease-in-out", [e.drawerColor]])
|
|
1961
|
+
}, [_("div", {
|
|
1962
|
+
style: A({ width: e.widthLeft + "px" }),
|
|
1963
|
+
class: "h-full overflow-y-auto p-4"
|
|
1964
|
+
}, [P(e.$slots, "left-drawer")], 4)], 6), _("button", {
|
|
1965
|
+
"aria-expanded": a.value.left,
|
|
1966
|
+
"aria-controls": "drawer-left-panel",
|
|
1967
|
+
"aria-label": a.value.left ? "Collapse left panel" : "Expand left panel",
|
|
1968
|
+
class: "hover:bg-base-300 hover:text-base-content transition-colors cursor-pointer",
|
|
1969
|
+
onClick: t[0] ||= (e) => o("left")
|
|
1970
|
+
}, [y(R(K), {
|
|
1971
|
+
size: "lg",
|
|
1972
|
+
icon: a.value.left ? R(G).ChevronLeft : R(G).ChevronRight
|
|
1973
|
+
}, null, 8, ["icon"])], 8, Rr)])) : h("", !0),
|
|
1974
|
+
_("div", zr, [P(e.$slots, "default")]),
|
|
1975
|
+
i.value ? (j(), g("aside", Br, [_("button", {
|
|
1976
|
+
"aria-expanded": a.value.right,
|
|
1977
|
+
"aria-controls": "drawer-right-panel",
|
|
1978
|
+
"aria-label": a.value.right ? "Collapse right panel" : "Expand right panel",
|
|
1979
|
+
class: "hover:bg-base-300 hover:text-base-content transition-colors cursor-pointer",
|
|
1980
|
+
onClick: t[1] ||= (e) => o("right")
|
|
1981
|
+
}, [y(R(K), {
|
|
1982
|
+
size: "lg",
|
|
1983
|
+
icon: a.value.right ? R(G).ChevronRight : R(G).ChevronLeft
|
|
1984
|
+
}, null, 8, ["icon"])], 8, Vr), _("div", {
|
|
1985
|
+
id: "drawer-right-panel",
|
|
1986
|
+
style: A({ width: a.value.right ? e.widthRight + "px" : "0px" }),
|
|
1987
|
+
class: O(["h-full overflow-hidden shadow-sm transition-[width] duration-300 ease-in-out", [e.drawerColor]])
|
|
1988
|
+
}, [_("div", {
|
|
1989
|
+
style: A({ width: e.widthRight + "px" }),
|
|
1990
|
+
class: "h-full overflow-y-auto p-4"
|
|
1991
|
+
}, [P(e.$slots, "right-drawer")], 4)], 6)])) : h("", !0)
|
|
1992
|
+
]));
|
|
1993
|
+
}
|
|
1994
|
+
}), Ur = { class: "ml-1" }, Wr = {
|
|
1995
|
+
key: 0,
|
|
1996
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1997
|
+
viewBox: "0 0 24 24",
|
|
1998
|
+
fill: "currentColor",
|
|
1999
|
+
"aria-hidden": "true",
|
|
2000
|
+
class: "w-3 h-3"
|
|
2001
|
+
}, Gr = {
|
|
2002
|
+
key: 1,
|
|
2003
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
2004
|
+
viewBox: "0 0 24 24",
|
|
2005
|
+
fill: "currentColor",
|
|
2006
|
+
"aria-hidden": "true",
|
|
2007
|
+
class: "w-3 h-3"
|
|
2008
|
+
}, Kr = { class: "truncate flex-1 min-w-0 text-left" }, qr = {
|
|
2009
|
+
key: 0,
|
|
2010
|
+
class: "badge badge-ghost badge-sm flex-shrink-0"
|
|
2011
|
+
}, Jr = /* @__PURE__ */ x({
|
|
2012
|
+
__name: "TreeItem",
|
|
2013
|
+
props: {
|
|
2014
|
+
active: {},
|
|
2015
|
+
node: {},
|
|
2016
|
+
expanded: {},
|
|
2017
|
+
isExpanded: { type: Function }
|
|
2018
|
+
},
|
|
2019
|
+
emits: ["toggle", "select"],
|
|
2020
|
+
setup(e, { emit: t }) {
|
|
2021
|
+
let n = e, r = t, i = p(() => n.active === n.node.id);
|
|
2022
|
+
return (t, n) => {
|
|
2023
|
+
let a = ne("TreeItem", !0);
|
|
2024
|
+
return j(), g("li", Ur, [_("div", { class: O(["flex items-center gap-1 cursor-pointer rounded-md px-1 py-0.5\n hover:bg-gray-100", i.value ? "text-primary" : ""]) }, [(e.node?.children?.length ?? 0) > 0 ? (j(), g("span", {
|
|
2025
|
+
key: 0,
|
|
2026
|
+
class: "flex items-center justify-center",
|
|
2027
|
+
onClick: n[0] ||= (t) => r("toggle", e.node)
|
|
2028
|
+
}, [e.node.children && e.isExpanded(e.node.id) ? (j(), g("svg", Wr, [...n[4] ||= [_("path", {
|
|
2029
|
+
"fill-rule": "evenodd",
|
|
2030
|
+
d: "M12.53 16.28a.75.75 0 0 1-1.06 0l-7.5-7.5a.75.75 0 0 1 1.06-1.06L12 14.69l6.97-6.97a.75.75 0 1 1 1.06 1.06l-7.5 7.5Z",
|
|
2031
|
+
"clip-rule": "evenodd"
|
|
2032
|
+
}, null, -1)]])) : (j(), g("svg", Gr, [...n[5] ||= [_("path", {
|
|
2033
|
+
"fill-rule": "evenodd",
|
|
2034
|
+
d: "M16.28 11.47a.75.75 0 0 1 0 1.06l-7.5 7.5a.75.75 0 0 1-1.06-1.06L14.69 12 7.72 5.03a.75.75 0 0 1 1.06-1.06l7.5 7.5Z",
|
|
2035
|
+
"clip-rule": "evenodd"
|
|
2036
|
+
}, null, -1)]]))])) : h("", !0), _("div", {
|
|
2037
|
+
class: "flex items-center gap-2 w-full min-w-0",
|
|
2038
|
+
onClick: n[1] ||= (t) => r("select", e.node)
|
|
2039
|
+
}, [_("div", Kr, I(e.node.label), 1), e.node.tag ? (j(), g("div", qr, I(e.node.tag), 1)) : h("", !0)])], 2), e.node.children && e.isExpanded(e.node.id) ? (j(), g("ul", {
|
|
2040
|
+
key: 0,
|
|
2041
|
+
class: O(["ml-4 border-l pl-2", {
|
|
2042
|
+
"border-gray-200": !i.value,
|
|
2043
|
+
"border-primary": i.value
|
|
2044
|
+
}])
|
|
2045
|
+
}, [(j(!0), g(l, null, N(e.node.children, (t) => (j(), m(a, {
|
|
2046
|
+
key: t.id,
|
|
2047
|
+
node: t,
|
|
2048
|
+
expanded: e.expanded,
|
|
2049
|
+
active: e.active,
|
|
2050
|
+
"is-expanded": e.isExpanded,
|
|
2051
|
+
onToggle: n[2] ||= (e) => r("toggle", e),
|
|
2052
|
+
onSelect: n[3] ||= (e) => r("select", e)
|
|
2053
|
+
}, null, 8, [
|
|
2054
|
+
"node",
|
|
2055
|
+
"expanded",
|
|
2056
|
+
"active",
|
|
2057
|
+
"is-expanded"
|
|
2058
|
+
]))), 128))], 2)) : h("", !0)]);
|
|
2059
|
+
};
|
|
2060
|
+
}
|
|
2061
|
+
}), Yr = { class: "select-none text-sm" }, Xr = /* @__PURE__ */ x({
|
|
2062
|
+
__name: "TreeView",
|
|
2063
|
+
props: {
|
|
2064
|
+
data: {},
|
|
2065
|
+
active: {}
|
|
2066
|
+
},
|
|
2067
|
+
emits: ["select"],
|
|
2068
|
+
setup(e, { emit: t }) {
|
|
2069
|
+
let n = e, r = t, i = M(/* @__PURE__ */ new Set()), a = (e) => {
|
|
2070
|
+
let t = e.id;
|
|
2071
|
+
if (!e.children || e.children.length === 0) {
|
|
2072
|
+
r("select", e);
|
|
2073
|
+
return;
|
|
2074
|
+
}
|
|
2075
|
+
i.value.has(t) ? i.value.delete(t) : i.value.add(t);
|
|
2076
|
+
}, o = (e) => {
|
|
2077
|
+
r("select", e), i.value.add(e.id);
|
|
2078
|
+
}, s = (e) => i.value.has(e);
|
|
2079
|
+
return (t, r) => (j(), g("ul", Yr, [(j(!0), g(l, null, N(n.data, (t) => (j(), m(Jr, {
|
|
2080
|
+
key: t.id,
|
|
2081
|
+
node: t,
|
|
2082
|
+
expanded: i.value,
|
|
2083
|
+
active: e.active,
|
|
2084
|
+
"is-expanded": s,
|
|
2085
|
+
onToggle: a,
|
|
2086
|
+
onSelect: o
|
|
2087
|
+
}, null, 8, [
|
|
2088
|
+
"node",
|
|
2089
|
+
"expanded",
|
|
2090
|
+
"active"
|
|
2091
|
+
]))), 128))]));
|
|
2092
|
+
}
|
|
2093
|
+
}), Zr = {
|
|
2094
|
+
key: 0,
|
|
2095
|
+
role: "status",
|
|
2096
|
+
"aria-live": "polite",
|
|
2097
|
+
class: "flex items-center justify-center h-20"
|
|
2098
|
+
}, Qr = /* @__PURE__ */ x({
|
|
2099
|
+
__name: "loading",
|
|
2100
|
+
props: { loading: { type: Boolean } },
|
|
2101
|
+
setup(e) {
|
|
2102
|
+
return (t, n) => e.loading ? (j(), g("div", Zr, [...n[0] ||= [_("span", {
|
|
2103
|
+
"aria-hidden": "true",
|
|
2104
|
+
class: "loading loading-bars loading-md text-primary"
|
|
2105
|
+
}, null, -1), _("span", { class: "sr-only" }, "Loading...", -1)]])) : h("", !0);
|
|
2106
|
+
}
|
|
2107
|
+
}), $r = {
|
|
2108
|
+
title: {
|
|
2109
|
+
type: String,
|
|
2110
|
+
required: !0
|
|
2111
|
+
},
|
|
2112
|
+
opened: {
|
|
2113
|
+
type: Boolean,
|
|
2114
|
+
default: !0
|
|
2115
|
+
},
|
|
2116
|
+
heightFull: {
|
|
2117
|
+
type: Boolean,
|
|
2118
|
+
default: !1
|
|
2119
|
+
},
|
|
2120
|
+
scrollable: {
|
|
2121
|
+
type: Boolean,
|
|
2122
|
+
default: !1
|
|
2123
|
+
},
|
|
2124
|
+
disabled: {
|
|
2125
|
+
type: Boolean,
|
|
2126
|
+
default: !1
|
|
2127
|
+
},
|
|
2128
|
+
actions: {
|
|
2129
|
+
type: Array,
|
|
2130
|
+
default: () => []
|
|
2131
|
+
}
|
|
2132
|
+
}, ei = ["checked", "aria-label"], ti = { class: "collapse-title text-gray-500 text-xs font-medium" }, ni = { class: "flex items-center justify-between" }, ri = {
|
|
2133
|
+
key: 0,
|
|
2134
|
+
class: "list bg-base-100"
|
|
2135
|
+
}, ii = {
|
|
2136
|
+
key: 1,
|
|
2137
|
+
class: "shrink-0 pt-2"
|
|
2138
|
+
}, ai = /* @__PURE__ */ x({
|
|
2139
|
+
__name: "Collapse",
|
|
2140
|
+
props: $r,
|
|
2141
|
+
setup(e) {
|
|
2142
|
+
let t = ae(), n = e, r = M(n.opened), i = M(n.opened || n.disabled);
|
|
2143
|
+
return (e, a) => (j(), g("div", { class: O(["collapse collapse-arrow bg-white border border-gray-300", [
|
|
2144
|
+
e.scrollable ? "flex-1 min-h-0 !grid-rows-[auto_1fr] overflow-hidden" : "",
|
|
2145
|
+
e.heightFull ? "h-full" : "",
|
|
2146
|
+
e.disabled ? "collapse-open" : "",
|
|
2147
|
+
i.value && !e.scrollable ? "overflow-visible" : ""
|
|
2148
|
+
]]) }, [
|
|
2149
|
+
e.disabled ? h("", !0) : (j(), g("input", {
|
|
2150
|
+
key: 0,
|
|
2151
|
+
type: "checkbox",
|
|
2152
|
+
checked: r.value,
|
|
2153
|
+
tabindex: "-1",
|
|
2154
|
+
"aria-label": "Toggle " + e.title,
|
|
2155
|
+
onChange: a[0] ||= (e) => i.value = e.target.checked
|
|
2156
|
+
}, null, 40, ei)),
|
|
2157
|
+
_("div", ti, [_("div", ni, [_("span", null, I(e.title), 1), n.actions.length > 0 ? (j(), g("div", {
|
|
2158
|
+
key: 0,
|
|
2159
|
+
class: "relative z-10 flex gap-1 overflow-y-auto",
|
|
2160
|
+
onClick: a[1] ||= U(() => {}, ["stop"])
|
|
2161
|
+
}, [(j(!0), g(l, null, N(n.actions, (e, t) => (j(), m(R(Z), {
|
|
2162
|
+
key: t,
|
|
2163
|
+
color: R(X).blank,
|
|
2164
|
+
size: "xs",
|
|
2165
|
+
icon: e.icon,
|
|
2166
|
+
tooltip: e.tooltip,
|
|
2167
|
+
disabled: e.disabled,
|
|
2168
|
+
onClick: e.onClick
|
|
2169
|
+
}, {
|
|
2170
|
+
default: V(() => [v(I(e.label), 1)]),
|
|
2171
|
+
_: 2
|
|
2172
|
+
}, 1032, [
|
|
2173
|
+
"color",
|
|
2174
|
+
"icon",
|
|
2175
|
+
"tooltip",
|
|
2176
|
+
"disabled",
|
|
2177
|
+
"onClick"
|
|
2178
|
+
]))), 128))])) : h("", !0)])]),
|
|
2179
|
+
_("div", { class: O(["collapse-content", [e.scrollable ? "!flex !flex-col min-h-0" : "", R(t).list ? "p-0" : ""]]) }, [
|
|
2180
|
+
_("div", { class: O(e.scrollable ? "flex-1 min-h-0 overflow-y-auto" : "") }, [P(e.$slots, "default")], 2),
|
|
2181
|
+
R(t).list ? (j(), g("ul", ri, [P(e.$slots, "list")])) : h("", !0),
|
|
2182
|
+
R(t).footer ? (j(), g("div", ii, [P(e.$slots, "footer")])) : h("", !0)
|
|
2183
|
+
], 2)
|
|
2184
|
+
], 2));
|
|
2185
|
+
}
|
|
2186
|
+
}), oi = {
|
|
2187
|
+
title: { type: String },
|
|
2188
|
+
label: { type: String },
|
|
2189
|
+
labelLink: { type: String },
|
|
2190
|
+
description: { type: String },
|
|
2191
|
+
descriptionLink: { type: String }
|
|
2192
|
+
}, si = { class: "list-row" }, ci = { class: "list-col-grow" }, li = { key: 0 }, ui = {
|
|
2193
|
+
key: 1,
|
|
2194
|
+
class: "text-xs text-gray-600"
|
|
2195
|
+
}, di = ["href"], fi = { key: 1 }, pi = {
|
|
2196
|
+
key: 0,
|
|
2197
|
+
class: "text-xs text-gray-500"
|
|
2198
|
+
}, mi = ["href"], hi = { key: 1 }, gi = /* @__PURE__ */ x({
|
|
2199
|
+
__name: "CollapseRow",
|
|
2200
|
+
props: oi,
|
|
2201
|
+
setup(e) {
|
|
2202
|
+
return (e, t) => (j(), g("li", si, [
|
|
2203
|
+
_("div", ci, [e.title ? (j(), g("div", li, I(e.title), 1)) : h("", !0), e.description || e.descriptionLink ? (j(), g("div", ui, [e.descriptionLink ? (j(), g("a", {
|
|
2204
|
+
key: 0,
|
|
2205
|
+
href: e.descriptionLink,
|
|
2206
|
+
target: "_blank"
|
|
2207
|
+
}, I(e.description ?? e.descriptionLink), 9, di)) : (j(), g("span", fi, I(e.description), 1))])) : h("", !0)]),
|
|
2208
|
+
e.label ? (j(), g("div", pi, [e.labelLink ? (j(), g("a", {
|
|
2209
|
+
key: 0,
|
|
2210
|
+
href: e.labelLink,
|
|
2211
|
+
target: "_blank"
|
|
2212
|
+
}, I(e.label), 9, mi)) : (j(), g("span", hi, I(e.label), 1))])) : h("", !0),
|
|
2213
|
+
P(e.$slots, "default")
|
|
2214
|
+
]));
|
|
2215
|
+
}
|
|
2216
|
+
}), _i = { class: "text-gray-800" }, vi = /* @__PURE__ */ x({
|
|
2217
|
+
__name: "alert",
|
|
2218
|
+
props: {
|
|
2219
|
+
message: {},
|
|
2220
|
+
type: {}
|
|
2221
|
+
},
|
|
2222
|
+
setup(e) {
|
|
2223
|
+
let t = {
|
|
2224
|
+
success: "alert-success",
|
|
2225
|
+
error: "alert-error",
|
|
2226
|
+
warning: "alert-warning",
|
|
2227
|
+
info: "alert-info"
|
|
2228
|
+
};
|
|
2229
|
+
return (n, r) => (j(), g("div", {
|
|
2230
|
+
role: "alert",
|
|
2231
|
+
class: O(`alert alert-soft ${t[e.type]} `)
|
|
2232
|
+
}, [_("span", _i, I(e.message), 1), P(n.$slots, "default")], 2));
|
|
2233
|
+
}
|
|
2234
|
+
}), yi = {
|
|
2235
|
+
title: {
|
|
2236
|
+
type: String,
|
|
2237
|
+
required: !0
|
|
2238
|
+
},
|
|
2239
|
+
items: {
|
|
2240
|
+
type: Array,
|
|
2241
|
+
required: !0
|
|
2242
|
+
},
|
|
2243
|
+
modelValue: {
|
|
2244
|
+
type: Array,
|
|
2245
|
+
default: () => []
|
|
2246
|
+
},
|
|
2247
|
+
labelKey: {
|
|
2248
|
+
type: String,
|
|
2249
|
+
default: "label"
|
|
2250
|
+
},
|
|
2251
|
+
valueKey: {
|
|
2252
|
+
type: String,
|
|
2253
|
+
default: "id"
|
|
2254
|
+
},
|
|
2255
|
+
colorKey: {
|
|
2256
|
+
type: String,
|
|
2257
|
+
default: void 0
|
|
2258
|
+
},
|
|
2259
|
+
countKey: {
|
|
2260
|
+
type: String,
|
|
2261
|
+
default: "count"
|
|
2262
|
+
},
|
|
2263
|
+
counts: {
|
|
2264
|
+
type: Object,
|
|
2265
|
+
default: void 0
|
|
2266
|
+
},
|
|
2267
|
+
opened: {
|
|
2268
|
+
type: Boolean,
|
|
2269
|
+
default: !0
|
|
2270
|
+
}
|
|
2271
|
+
}, bi = ["update:modelValue"], xi = (e, t, n, r) => {
|
|
2272
|
+
let i = p(() => e.value.map((e) => e[n.value]));
|
|
2273
|
+
return {
|
|
2274
|
+
isSelected: (e) => t.value.includes(e),
|
|
2275
|
+
selectedLabel: p(() => {
|
|
2276
|
+
let e = t.value.length;
|
|
2277
|
+
return e === 0 ? "None" : e === i.value.length ? "All" : `${e}`;
|
|
2278
|
+
}),
|
|
2279
|
+
selectAll: () => r("update:modelValue", [...i.value]),
|
|
2280
|
+
selectNone: () => r("update:modelValue", []),
|
|
2281
|
+
toggleItem: (e, n) => {
|
|
2282
|
+
n ? r("update:modelValue", [...t.value, e]) : r("update:modelValue", t.value.filter((t) => t !== e));
|
|
2283
|
+
}
|
|
2284
|
+
};
|
|
2285
|
+
}, Si = { class: "flex items-center justify-between mb-2" }, Ci = { class: "text-xs text-base-content/50" }, wi = { class: "flex gap-1" }, Ti = { class: "flex flex-col gap-1" }, Ei = ["checked", "onChange"], Di = { class: "text-sm flex-1 select-none" }, Oi = {
|
|
2286
|
+
key: 1,
|
|
2287
|
+
class: "badge badge-sm badge-ghost"
|
|
2288
|
+
}, ki = /* @__PURE__ */ x({
|
|
2289
|
+
__name: "filter",
|
|
2290
|
+
props: yi,
|
|
2291
|
+
emits: bi,
|
|
2292
|
+
setup(e, { emit: t }) {
|
|
2293
|
+
let n = e, r = t, i = p(() => n.items ?? []), { isSelected: a, selectedLabel: o, selectAll: s, selectNone: c, toggleItem: u } = xi(i, re(n, "modelValue"), re(n, "valueKey"), r);
|
|
2294
|
+
return (e, t) => (j(), m(R(ai), {
|
|
2295
|
+
title: e.title,
|
|
2296
|
+
opened: e.opened
|
|
2297
|
+
}, {
|
|
2298
|
+
default: V(() => [_("div", Si, [_("span", Ci, I(R(o)) + " of " + I(i.value.length) + " items ", 1), _("div", wi, [_("button", {
|
|
2299
|
+
class: "btn btn-ghost btn-xs",
|
|
2300
|
+
type: "button",
|
|
2301
|
+
tabindex: "-1",
|
|
2302
|
+
onClick: t[0] ||= (...e) => R(s) && R(s)(...e)
|
|
2303
|
+
}, " All "), _("button", {
|
|
2304
|
+
class: "btn btn-ghost btn-xs",
|
|
2305
|
+
type: "button",
|
|
2306
|
+
tabindex: "-1",
|
|
2307
|
+
onClick: t[1] ||= (...e) => R(c) && R(c)(...e)
|
|
2308
|
+
}, " None ")])]), _("div", Ti, [(j(!0), g(l, null, N(i.value, (t) => (j(), g("label", {
|
|
2309
|
+
key: t[e.valueKey],
|
|
2310
|
+
class: O(["flex items-center gap-3 px-2 py-1.5 rounded-lg cursor-pointer transition-colors hover:bg-base-200", { "bg-base-200/60": R(a)(t[e.valueKey]) }])
|
|
2311
|
+
}, [
|
|
2312
|
+
_("input", {
|
|
2313
|
+
type: "checkbox",
|
|
2314
|
+
class: "checkbox checkbox-sm",
|
|
2315
|
+
checked: R(a)(t[e.valueKey]),
|
|
2316
|
+
onChange: (n) => R(u)(t[e.valueKey], n.target.checked)
|
|
2317
|
+
}, null, 40, Ei),
|
|
2318
|
+
e.colorKey && t[e.colorKey] ? (j(), g("span", {
|
|
2319
|
+
key: 0,
|
|
2320
|
+
class: "w-3 h-3 rounded-full shrink-0 ring-1 ring-black/10",
|
|
2321
|
+
style: A({ backgroundColor: t[e.colorKey] })
|
|
2322
|
+
}, null, 4)) : h("", !0),
|
|
2323
|
+
_("span", Di, I(t[e.labelKey]), 1),
|
|
2324
|
+
t[e.countKey] > 0 ? (j(), g("span", Oi, I(t[e.countKey]), 1)) : h("", !0)
|
|
2325
|
+
], 2))), 128))])]),
|
|
2326
|
+
_: 1
|
|
2327
|
+
}, 8, ["title", "opened"]));
|
|
2328
|
+
}
|
|
2307
2329
|
});
|
|
2308
|
-
|
|
2309
|
-
|
|
2310
|
-
On as Autocomplete,
|
|
2311
|
-
Mt as BadgeSize,
|
|
2312
|
-
Ln as BooleanCell,
|
|
2313
|
-
N as Btn,
|
|
2314
|
-
_n as BtnBadge,
|
|
2315
|
-
Tt as BtnBadgeEmits,
|
|
2316
|
-
Rt as BtnBadgeProperties,
|
|
2317
|
-
Dt as BtnEmits,
|
|
2318
|
-
It as BtnProperties,
|
|
2319
|
-
Pt as ButtonSize,
|
|
2320
|
-
Me as ButtonTag,
|
|
2321
|
-
fe as ButtonType,
|
|
2322
|
-
Sn as Card,
|
|
2323
|
-
Rn as Checkbox,
|
|
2324
|
-
Bn as ClickOutside,
|
|
2325
|
-
Fs as Collapse,
|
|
2326
|
-
Fn as CollapseRow,
|
|
2327
|
-
z as Color,
|
|
2328
|
-
zt as ConfirmModal,
|
|
2329
|
-
Z as ControlWrapper,
|
|
2330
|
-
Nn as Drawer,
|
|
2331
|
-
kn as Dropdown,
|
|
2332
|
-
Un as Filter,
|
|
2333
|
-
on as FilterEmits,
|
|
2334
|
-
tn as FilterProperties,
|
|
2335
|
-
q as Icon,
|
|
2336
|
-
R as IconEnum,
|
|
2337
|
-
ft as IconMap,
|
|
2338
|
-
mt as IconProperties,
|
|
2339
|
-
Tn as Input,
|
|
2340
|
-
En as InputNumber,
|
|
2341
|
-
jn as Loading,
|
|
2342
|
-
Dn as Markdown,
|
|
2343
|
-
wn as Menu,
|
|
2344
|
-
Vt as Modal,
|
|
2345
|
-
Ct as ModalEmits,
|
|
2346
|
-
$t as ModalProperties,
|
|
2347
|
-
me as ModalService,
|
|
2348
|
-
St as ModalSize,
|
|
2349
|
-
Nt as ModalWrapper,
|
|
2350
|
-
In as MultiSelect,
|
|
2351
|
-
qt as NotificationMessage,
|
|
2352
|
-
be as NotificationService,
|
|
2353
|
-
Kt as Notifications,
|
|
2354
|
-
co as PaginationComponent,
|
|
2355
|
-
An as SelectComponent,
|
|
2356
|
-
$n as ShellComponent,
|
|
2357
|
-
pe as SubMenu,
|
|
2358
|
-
xn as Table,
|
|
2359
|
-
xn as TableComponent,
|
|
2360
|
-
Cn as TextCell,
|
|
2361
|
-
zn as Textarea,
|
|
2362
|
-
qn as TreeView,
|
|
2363
|
-
Pn as addClickOutsideEventListener,
|
|
2364
|
-
U as buildInputStyle,
|
|
2365
|
-
Vn as hasCustomEventListener,
|
|
2366
|
-
qo as isDescriptionHidden,
|
|
2367
|
-
ae as mergeStyles,
|
|
2368
|
-
se as myStyles,
|
|
2369
|
-
Mn as removeClickOutsideEventListener,
|
|
2370
|
-
Ae as showErrors,
|
|
2371
|
-
sn as useFilter
|
|
2372
|
-
};
|
|
2330
|
+
//#endregion
|
|
2331
|
+
export { vi as Alert, dr as Autocomplete, Qe as BadgeSize, xn as BooleanCell, Z as Btn, ut as BtnBadge, st as BtnBadgeEmits, ot as BtnBadgeProperties, at as BtnEmits, it as BtnProperties, Ze as ButtonSize, tt as ButtonTag, Y as ButtonType, kn as Card, br as Checkbox, Mn as ClickOutside, ai as Collapse, gi as CollapseRow, X as Color, dt as ConfirmModal, c as ControlWrapper, s as ControlWrapperProperties, Hr as Drawer, We as Dropdown, ki as Filter, bi as FilterEmits, yi as FilterProperties, K as Icon, G as IconEnum, Me as IconMap, Ne as IconProperties, Tr as Input, kr as InputNumber, Qr as Loading, Pr as Markdown, Ue as Menu, et as Modal, Ke as ModalEmits, Ge as ModalProperties, ft as ModalService, Xe as ModalSize, pt as ModalWrapper, pr as MultiSelect, mt as NotificationMessage, gt as NotificationService, vt as Notifications, Bt as PaginationComponent, ar as SelectComponent, At as ShellComponent, q as SubMenu, hn as Table, hn as TableComponent, yn as TextCell, Nr as Textarea, Xr as TreeView, An as addClickOutsideEventListener, i as buildInputStyle, Pn as hasCustomEventListener, o as isDescriptionHidden, t as mergeStyles, r as myStyles, jn as removeClickOutsideEventListener, n as showErrors, xi as useFilter, Ye as useFocusTrap };
|