@aerogel/core 0.1.1-next.b25730fd2850ebabef064973972dabd342d92769 → 0.1.1-next.f40b19c2bd8a3c0f252f1811ed740ce17bb6f699
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/aerogel-core.d.ts +222 -261
- package/dist/aerogel-core.js +1371 -1359
- package/dist/aerogel-core.js.map +1 -1
- package/package.json +3 -2
- package/src/components/AppOverlays.vue +3 -2
- package/src/components/contracts/AlertModal.ts +1 -1
- package/src/components/contracts/Button.ts +1 -1
- package/src/components/contracts/ConfirmModal.ts +5 -2
- package/src/components/contracts/Modal.ts +8 -3
- package/src/components/contracts/PromptModal.ts +6 -2
- package/src/components/contracts/Toast.ts +1 -1
- package/src/components/headless/HeadlessInputInput.vue +13 -5
- package/src/components/headless/HeadlessModal.vue +6 -34
- package/src/components/headless/HeadlessModalContent.vue +5 -12
- package/src/components/index.ts +0 -1
- package/src/components/ui/AdvancedOptions.vue +4 -13
- package/src/components/ui/Button.vue +1 -0
- package/src/components/ui/ConfirmModal.vue +7 -2
- package/src/components/ui/Details.vue +20 -0
- package/src/components/ui/LoadingModal.vue +1 -2
- package/src/components/ui/Modal.vue +53 -33
- package/src/components/ui/PromptModal.vue +7 -2
- package/src/components/ui/Toast.vue +1 -0
- package/src/components/ui/index.ts +1 -1
- package/src/forms/FormController.ts +4 -0
- package/src/index.css +9 -0
- package/src/ui/UI.state.ts +0 -11
- package/src/ui/UI.ts +42 -125
- package/src/ui/index.ts +1 -0
- package/src/ui/modals.ts +36 -0
- package/src/utils/composition/reactiveSet.test.ts +32 -0
- package/src/utils/composition/reactiveSet.ts +53 -0
- package/src/utils/index.ts +2 -0
- package/src/utils/time.ts +2 -0
- package/src/components/AppModals.vue +0 -14
- package/src/components/ui/ModalContext.vue +0 -31
package/dist/aerogel-core.js
CHANGED
|
@@ -1,42 +1,44 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var _ = (t, s, e) =>
|
|
4
|
-
import { markRaw as
|
|
5
|
-
import { JSError as
|
|
6
|
-
import
|
|
7
|
-
import { createPinia as
|
|
8
|
-
import
|
|
9
|
-
import { marked as
|
|
10
|
-
import as from "
|
|
11
|
-
import {
|
|
12
|
-
import
|
|
13
|
-
import {
|
|
14
|
-
|
|
1
|
+
var At = Object.defineProperty;
|
|
2
|
+
var Pt = (t, s, e) => s in t ? At(t, s, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[s] = e;
|
|
3
|
+
var _ = (t, s, e) => Pt(t, typeof s != "symbol" ? s + "" : s, e);
|
|
4
|
+
import { markRaw as V, Comment as Dt, Text as Bt, Static as jt, inject as Y, reactive as ve, unref as l, onUnmounted as $e, ref as N, computed as c, readonly as _e, nextTick as Ft, useAttrs as tt, onMounted as st, watch as Le, toRaw as Ut, customRef as Ot, watchEffect as G, defineComponent as h, createBlock as f, openBlock as o, mergeProps as H, withCtx as m, renderSlot as $, createPropsRestProxy as K, createVNode as d, normalizeProps as ce, guardReactiveProps as de, createTextVNode as L, toDisplayString as x, normalizeClass as C, createElementBlock as y, Fragment as D, renderList as U, provide as pe, resolveDynamicComponent as ee, useSlots as Ie, createCommentVNode as M, createElementVNode as b, h as Nt, useTemplateRef as te, withModifiers as rt, withDirectives as nt, vModelCheckbox as Wt, normalizeStyle as Kt, resolveComponent as Qt, createApp as Jt, vModelText as Zt } from "vue";
|
|
5
|
+
import { JSError as xe, stringToSlug as Xt, tap as se, MagicObject as at, PromisedValue as J, Storage as O, objectOnly as ae, arrayFrom as lt, isEmpty as Te, objectDeepClone as Yt, fail as W, facade as re, arrayRemove as He, getEnv as Gt, updateLocationQueryParameters as es, forever as ts, toString as j, objectWithout as ss, noop as rs, debounce as ns, stringMatchAll as ot, isDevelopment as Z, isTesting as ze, after as oe, uuid as ue, isObject as he, objectWithoutEmpty as it, value as as, isInstanceOf as Oe, stringExcerpt as ls, arraySorted as os, ListenersManager as is, toError as us, round as cs } from "@noeldemartin/utils";
|
|
6
|
+
import B from "virtual:aerogel";
|
|
7
|
+
import { createPinia as ds, setActivePinia as ps, defineStore as ms } from "pinia";
|
|
8
|
+
import fs from "dompurify";
|
|
9
|
+
import { marked as hs, Renderer as Ne } from "marked";
|
|
10
|
+
import { injectModal as ut, useModal as gs, createModal as vs, showModal as We, closeModal as Ke, modals as le, ModalComponent as bs, ModalsPortal as ys } from "@noeldemartin/vue-modals";
|
|
11
|
+
import { ModalComponent as po, ModalsPortal as mo, closeModal as fo, createModal as ho, injectModal as go, modals as vo, showModal as bo } from "@noeldemartin/vue-modals";
|
|
12
|
+
import ws from "clsx";
|
|
13
|
+
import { cva as $s } from "class-variance-authority";
|
|
14
|
+
import { twMerge as _s } from "tailwind-merge";
|
|
15
|
+
import { Primitive as xs, SelectValue as Qe, SelectTrigger as Cs, SelectIcon as Ss, SelectItem as ks, SelectItemText as Ts, SelectPortal as Ms, SelectContent as Es, SelectViewport as Hs, SelectRoot as Vs, Label as Ls, useForwardExpose as Re, SwitchRoot as Is, SwitchThumb as zs, DialogRoot as Rs, DialogPortal as qs, DialogContent as As, DialogDescription as Ps, DialogOverlay as Ds, DialogTitle as Bs, ToastClose as js, ToastRoot as Fs, ToastProvider as Us, ToastViewport as Os, DropdownMenuItem as Ns, DropdownMenuContent as Ws, DropdownMenuRoot as Ks, DropdownMenuTrigger as Qs, DropdownMenuPortal as Js } from "reka-ui";
|
|
16
|
+
class Ve extends xe {
|
|
15
17
|
constructor(s, e) {
|
|
16
18
|
super(`Service '${s}' failed booting`, { cause: e });
|
|
17
19
|
}
|
|
18
20
|
}
|
|
19
|
-
function
|
|
20
|
-
return
|
|
21
|
+
function Zs() {
|
|
22
|
+
return B.namespace ?? Xt(B.name);
|
|
21
23
|
}
|
|
22
|
-
let
|
|
23
|
-
function
|
|
24
|
-
return
|
|
24
|
+
let qe = null;
|
|
25
|
+
function ct() {
|
|
26
|
+
return qe ?? Xs();
|
|
25
27
|
}
|
|
26
|
-
function
|
|
27
|
-
return
|
|
28
|
-
|
|
28
|
+
function Xs() {
|
|
29
|
+
return se(ds(), (t) => {
|
|
30
|
+
qe = t, ps(t);
|
|
29
31
|
});
|
|
30
32
|
}
|
|
31
|
-
function
|
|
32
|
-
return
|
|
33
|
+
function Ys() {
|
|
34
|
+
return qe ?? ct();
|
|
33
35
|
}
|
|
34
|
-
function
|
|
35
|
-
return
|
|
36
|
+
function Gs(t, s) {
|
|
37
|
+
return ct(), ms(t, s)();
|
|
36
38
|
}
|
|
37
|
-
function
|
|
39
|
+
function Ce(t) {
|
|
38
40
|
var s;
|
|
39
|
-
return s = class extends
|
|
41
|
+
return s = class extends Se {
|
|
40
42
|
usesStore() {
|
|
41
43
|
return !0;
|
|
42
44
|
}
|
|
@@ -72,8 +74,8 @@ To fix this problem, declare your initialState as a function instead.`
|
|
|
72
74
|
}
|
|
73
75
|
}, _(s, "persist", t.persist ?? []), s;
|
|
74
76
|
}
|
|
75
|
-
var
|
|
76
|
-
let
|
|
77
|
+
var Ee;
|
|
78
|
+
let Se = (Ee = class extends at {
|
|
77
79
|
constructor() {
|
|
78
80
|
super();
|
|
79
81
|
_(this, "_name");
|
|
@@ -82,7 +84,7 @@ let we = (ke = class extends Qe {
|
|
|
82
84
|
_(this, "_watchers");
|
|
83
85
|
_(this, "_store");
|
|
84
86
|
const e = this.getComputedStateDefinition();
|
|
85
|
-
this._name = this.getName() ?? new.target.name, this._booted = new
|
|
87
|
+
this._name = this.getName() ?? new.target.name, this._booted = new J(), this._computedStateKeys = new Set(Object.keys(e)), this._watchers = this.getStateWatchers(), this._store = this.usesStore() && Gs(this._name, {
|
|
86
88
|
state: () => this.getInitialState(),
|
|
87
89
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
88
90
|
getters: e
|
|
@@ -95,7 +97,7 @@ let we = (ke = class extends Qe {
|
|
|
95
97
|
return super.static(e);
|
|
96
98
|
}
|
|
97
99
|
launch() {
|
|
98
|
-
const e = (r) => this._booted.reject(new
|
|
100
|
+
const e = (r) => this._booted.reject(new Ve(this._name, r));
|
|
99
101
|
try {
|
|
100
102
|
this.frameworkBoot().then(() => this.boot()).then(() => this._booted.resolve()).catch(e);
|
|
101
103
|
} catch (r) {
|
|
@@ -116,14 +118,14 @@ let we = (ke = class extends Qe {
|
|
|
116
118
|
setState(e, r) {
|
|
117
119
|
if (!this._store)
|
|
118
120
|
return;
|
|
119
|
-
const n = typeof e == "string" ? { [e]: r } : e, a =
|
|
121
|
+
const n = typeof e == "string" ? { [e]: r } : e, a = ae(this._store.$state, Object.keys(n));
|
|
120
122
|
Object.assign(this._store.$state, n), this.onStateUpdated(n, a);
|
|
121
123
|
}
|
|
122
124
|
updatePersistedState(e) {
|
|
123
125
|
if (!this._store)
|
|
124
126
|
return;
|
|
125
|
-
const r =
|
|
126
|
-
|
|
127
|
+
const r = lt(e), n = ae(this._store.$state, r);
|
|
128
|
+
Te(n) || this.onPersistentStateUpdated(n);
|
|
127
129
|
}
|
|
128
130
|
__get(e) {
|
|
129
131
|
return this.hasState(e) ? this.getState(e) : super.__get(e);
|
|
@@ -132,21 +134,21 @@ let we = (ke = class extends Qe {
|
|
|
132
134
|
this.setState({ [e]: r });
|
|
133
135
|
}
|
|
134
136
|
get storageKey() {
|
|
135
|
-
return `${
|
|
137
|
+
return `${Zs()}:${this._name}`;
|
|
136
138
|
}
|
|
137
139
|
onStateUpdated(e, r) {
|
|
138
|
-
const n =
|
|
139
|
-
|
|
140
|
+
const n = ae(e, this.static("persist"));
|
|
141
|
+
Te(n) || this.onPersistentStateUpdated(n);
|
|
140
142
|
for (const a in e) {
|
|
141
|
-
const
|
|
142
|
-
!
|
|
143
|
+
const u = this._watchers[a];
|
|
144
|
+
!u || e[a] === r[a] || u.call(this, e[a], r[a]);
|
|
143
145
|
}
|
|
144
146
|
}
|
|
145
147
|
onPersistentStateUpdated(e) {
|
|
146
148
|
const r = O.get(this.storageKey);
|
|
147
149
|
r && O.set(this.storageKey, {
|
|
148
150
|
...r,
|
|
149
|
-
...this.serializePersistedState(
|
|
151
|
+
...this.serializePersistedState(Yt(e))
|
|
150
152
|
});
|
|
151
153
|
}
|
|
152
154
|
usesStore() {
|
|
@@ -176,25 +178,25 @@ let we = (ke = class extends Qe {
|
|
|
176
178
|
async boot() {
|
|
177
179
|
}
|
|
178
180
|
restorePersistedState() {
|
|
179
|
-
if (!(!this.usesStore() ||
|
|
181
|
+
if (!(!this.usesStore() || Te(this.static("persist")))) {
|
|
180
182
|
if (O.has(this.storageKey)) {
|
|
181
183
|
const e = O.require(this.storageKey);
|
|
182
184
|
this.setState(this.deserializePersistedState(e));
|
|
183
185
|
return;
|
|
184
186
|
}
|
|
185
|
-
O.set(this.storageKey,
|
|
187
|
+
O.set(this.storageKey, ae(this.getState(), this.static("persist")));
|
|
186
188
|
}
|
|
187
189
|
}
|
|
188
190
|
requireStore() {
|
|
189
|
-
return this._store ? this._store :
|
|
191
|
+
return this._store ? this._store : W(`Failed getting '${this._name}' store`);
|
|
190
192
|
}
|
|
191
|
-
}, _(
|
|
192
|
-
const
|
|
193
|
+
}, _(Ee, "persist", []), Ee);
|
|
194
|
+
const Cl = {
|
|
193
195
|
Low: -256,
|
|
194
196
|
Default: 0,
|
|
195
197
|
High: 256
|
|
196
198
|
};
|
|
197
|
-
class
|
|
199
|
+
class er extends Se {
|
|
198
200
|
constructor() {
|
|
199
201
|
super(...arguments);
|
|
200
202
|
_(this, "listeners", {});
|
|
@@ -208,57 +210,57 @@ class Ds extends we {
|
|
|
208
210
|
async emit(e, r) {
|
|
209
211
|
var a;
|
|
210
212
|
const n = this.listeners[e] ?? { priorities: [], handlers: {} };
|
|
211
|
-
for (const
|
|
212
|
-
await Promise.all(((a = n.handlers[
|
|
213
|
+
for (const u of n.priorities)
|
|
214
|
+
await Promise.all(((a = n.handlers[u]) == null ? void 0 : a.map((i) => i(r))) ?? []);
|
|
213
215
|
}
|
|
214
216
|
// prettier-ignore
|
|
215
217
|
/* eslint-enable max-len */
|
|
216
218
|
on(e, r, n) {
|
|
217
|
-
const a = typeof r == "function" ? {} : typeof r == "number" ? { priority: r } : r,
|
|
218
|
-
return this.registerListener(e, a,
|
|
219
|
+
const a = typeof r == "function" ? {} : typeof r == "number" ? { priority: r } : r, u = typeof r == "function" ? r : n;
|
|
220
|
+
return this.registerListener(e, a, u), () => this.off(e, u);
|
|
219
221
|
}
|
|
220
222
|
// prettier-ignore
|
|
221
223
|
/* eslint-enable max-len */
|
|
222
224
|
once(e, r, n) {
|
|
223
225
|
let a = null;
|
|
224
|
-
const
|
|
225
|
-
return
|
|
226
|
+
const u = typeof r == "function" ? {} : r, i = typeof r == "function" ? r : n;
|
|
227
|
+
return se(
|
|
226
228
|
() => a && this.off(e, a),
|
|
227
|
-
(
|
|
228
|
-
a = (...
|
|
229
|
+
(p) => {
|
|
230
|
+
a = (...g) => (p(), i(...g)), this.registerListener(e, u, i);
|
|
229
231
|
}
|
|
230
232
|
);
|
|
231
233
|
}
|
|
232
234
|
off(e, r) {
|
|
233
|
-
var
|
|
235
|
+
var u;
|
|
234
236
|
const n = this.listeners[e];
|
|
235
237
|
if (!n)
|
|
236
238
|
return;
|
|
237
239
|
const a = [...n.priorities];
|
|
238
|
-
for (const
|
|
239
|
-
|
|
240
|
+
for (const i of a)
|
|
241
|
+
He(n.handlers[i] ?? [], r), ((u = n.handlers[i]) == null ? void 0 : u.length) === 0 && (delete n.handlers[i], He(n.priorities, i));
|
|
240
242
|
n.priorities.length === 0 && delete this.listeners[e];
|
|
241
243
|
}
|
|
242
244
|
registerListener(e, r, n) {
|
|
243
|
-
var
|
|
245
|
+
var p, g, w;
|
|
244
246
|
const a = r.priority ?? 0;
|
|
245
247
|
e in this.listeners || (this.listeners[e] = { priorities: [], handlers: {} });
|
|
246
|
-
const
|
|
247
|
-
|
|
248
|
+
const u = ((p = this.listeners[e]) == null ? void 0 : p.priorities) ?? W(`priorities missing for event '${e}'`), i = ((g = this.listeners[e]) == null ? void 0 : g.handlers) ?? W(`handlers missing for event '${e}'`);
|
|
249
|
+
u.includes(a) || (u.push(a), u.sort((v, k) => k - v), i[a] = []), (w = i[a]) == null || w.push(n);
|
|
248
250
|
}
|
|
249
251
|
}
|
|
250
|
-
const
|
|
251
|
-
function
|
|
252
|
+
const F = re(er);
|
|
253
|
+
function Sl(t) {
|
|
252
254
|
return t;
|
|
253
255
|
}
|
|
254
|
-
const
|
|
256
|
+
const tr = Ce({
|
|
255
257
|
name: "app",
|
|
256
258
|
initialState: {
|
|
257
259
|
plugins: {},
|
|
258
260
|
instance: null,
|
|
259
|
-
environment:
|
|
260
|
-
version:
|
|
261
|
-
sourceUrl:
|
|
261
|
+
environment: Gt() ?? "development",
|
|
262
|
+
version: B.version,
|
|
263
|
+
sourceUrl: B.sourceUrl,
|
|
262
264
|
settings: []
|
|
263
265
|
},
|
|
264
266
|
computed: {
|
|
@@ -266,19 +268,19 @@ const js = ye({
|
|
|
266
268
|
staging: (t) => t.environment === "staging",
|
|
267
269
|
testing: (t) => t.environment === "test" || t.environment === "testing",
|
|
268
270
|
versionName(t) {
|
|
269
|
-
return this.development ? "dev." +
|
|
271
|
+
return this.development ? "dev." + B.sourceHash.toString().substring(0, 7) : this.staging ? "staging." + B.sourceHash.toString().substring(0, 7) : `v${t.version}`;
|
|
270
272
|
},
|
|
271
273
|
versionUrl(t) {
|
|
272
|
-
return t.sourceUrl + (this.development || this.staging ? `/tree/${
|
|
274
|
+
return t.sourceUrl + (this.development || this.staging ? `/tree/${B.sourceHash}` : `/releases/tag/${this.versionName}`);
|
|
273
275
|
}
|
|
274
276
|
}
|
|
275
277
|
});
|
|
276
|
-
class
|
|
278
|
+
class sr extends tr {
|
|
277
279
|
constructor() {
|
|
278
280
|
super(...arguments);
|
|
279
|
-
_(this, "name",
|
|
280
|
-
_(this, "ready", new
|
|
281
|
-
_(this, "mounted", new
|
|
281
|
+
_(this, "name", B.name);
|
|
282
|
+
_(this, "ready", new J());
|
|
283
|
+
_(this, "mounted", new J());
|
|
282
284
|
}
|
|
283
285
|
isReady() {
|
|
284
286
|
return this.ready.isResolved();
|
|
@@ -287,13 +289,13 @@ class Bs extends js {
|
|
|
287
289
|
return this.mounted.isResolved();
|
|
288
290
|
}
|
|
289
291
|
addSetting(e) {
|
|
290
|
-
this.settings.push(
|
|
292
|
+
this.settings.push(V(e));
|
|
291
293
|
}
|
|
292
294
|
async whenReady(e) {
|
|
293
295
|
return await this.ready.then(e);
|
|
294
296
|
}
|
|
295
297
|
async reload(e) {
|
|
296
|
-
e &&
|
|
298
|
+
e && es(e), location.reload(), await ts();
|
|
297
299
|
}
|
|
298
300
|
plugin(e) {
|
|
299
301
|
return this.plugins[e] ?? null;
|
|
@@ -303,15 +305,15 @@ class Bs extends js {
|
|
|
303
305
|
return ((r = this.instance) == null ? void 0 : r.config.globalProperties[e]) ?? null;
|
|
304
306
|
}
|
|
305
307
|
async boot() {
|
|
306
|
-
|
|
308
|
+
F.once("application-ready", () => this.ready.resolve()), F.once("application-mounted", () => this.mounted.resolve());
|
|
307
309
|
}
|
|
308
310
|
}
|
|
309
|
-
const
|
|
310
|
-
function
|
|
311
|
+
const P = re(sr);
|
|
312
|
+
function kl(t) {
|
|
311
313
|
return t;
|
|
312
314
|
}
|
|
313
|
-
async function
|
|
314
|
-
|
|
315
|
+
async function rr(t, ...s) {
|
|
316
|
+
P.setState(
|
|
315
317
|
"plugins",
|
|
316
318
|
t.reduce(
|
|
317
319
|
(e, r) => (r.name && (e[r.name] = r), e),
|
|
@@ -319,55 +321,55 @@ async function Fs(t, ...s) {
|
|
|
319
321
|
)
|
|
320
322
|
), await Promise.all(t.map((e) => e.install(...s)) ?? []);
|
|
321
323
|
}
|
|
322
|
-
function
|
|
323
|
-
return Object.entries(t.props ?? {}).reduce((s, [e, r]) => s + `${e}="${
|
|
324
|
+
function nr(t) {
|
|
325
|
+
return Object.entries(t.props ?? {}).reduce((s, [e, r]) => s + `${e}="${j(r)}"`, "");
|
|
324
326
|
}
|
|
325
|
-
function
|
|
327
|
+
function Tl(t) {
|
|
326
328
|
return t;
|
|
327
329
|
}
|
|
328
|
-
function
|
|
329
|
-
const s =
|
|
330
|
-
return s ?
|
|
330
|
+
function ar(t) {
|
|
331
|
+
const s = Y(t);
|
|
332
|
+
return s ? ve(s) : void 0;
|
|
331
333
|
}
|
|
332
|
-
function
|
|
333
|
-
return
|
|
334
|
+
function R(t, s) {
|
|
335
|
+
return ar(t) ?? W(s ?? `Could not resolve '${j(t)}' injection key`);
|
|
334
336
|
}
|
|
335
|
-
function
|
|
336
|
-
return
|
|
337
|
+
function lr(t, s) {
|
|
338
|
+
return Y(t) ?? W(s ?? `Could not resolve '${j(t)}' injection key`);
|
|
337
339
|
}
|
|
338
|
-
function
|
|
339
|
-
return typeof t == "string" ? t : t.type ===
|
|
340
|
+
function dt(t) {
|
|
341
|
+
return typeof t == "string" ? t : t.type === Dt ? "" : t.type === Bt || t.type === jt ? t.children : t.type === "br" ? `
|
|
340
342
|
|
|
341
|
-
` : `<${t.type} ${
|
|
343
|
+
` : `<${t.type} ${nr(t)}>${Array.from(t.children).map(dt).join("")}</${t.type}>`;
|
|
342
344
|
}
|
|
343
|
-
const
|
|
345
|
+
const Me = /* @__PURE__ */ new WeakMap(), or = {
|
|
344
346
|
mounted(t, { value: s, modifiers: e }) {
|
|
345
347
|
const r = typeof s == "function" ? s : null, n = () => {
|
|
346
348
|
const a = t.getBoundingClientRect();
|
|
347
349
|
e.css && (t.style.setProperty("--width", `${a.width}px`), t.style.setProperty("--height", `${a.height}px`)), r == null || r({ width: a.width, height: a.height });
|
|
348
350
|
};
|
|
349
|
-
e.watch &&
|
|
351
|
+
e.watch && Me.set(t, se(new ResizeObserver(n)).observe(t)), n();
|
|
350
352
|
},
|
|
351
353
|
unmounted(t) {
|
|
352
354
|
var s;
|
|
353
|
-
(s =
|
|
355
|
+
(s = Me.get(t)) == null || s.unobserve(t), Me.delete(t);
|
|
354
356
|
}
|
|
355
357
|
};
|
|
356
|
-
function
|
|
357
|
-
const { baseClasses: e, ...r } = t, { baseClasses: n, ...a } = s,
|
|
358
|
-
return
|
|
358
|
+
function pt(t, s) {
|
|
359
|
+
const { baseClasses: e, ...r } = t, { baseClasses: n, ...a } = s, u = $s(n, a);
|
|
360
|
+
return E(u(r), l(e));
|
|
359
361
|
}
|
|
360
|
-
function
|
|
361
|
-
return
|
|
362
|
+
function E(...t) {
|
|
363
|
+
return _s(ws(t));
|
|
362
364
|
}
|
|
363
|
-
function
|
|
364
|
-
const e =
|
|
365
|
-
|
|
365
|
+
function Ml(t, s) {
|
|
366
|
+
const e = F.on(t, s);
|
|
367
|
+
$e(() => e());
|
|
366
368
|
}
|
|
367
|
-
const
|
|
369
|
+
const ir = {
|
|
368
370
|
required: (t) => t ? void 0 : "required"
|
|
369
371
|
};
|
|
370
|
-
function
|
|
372
|
+
function ur(t, s) {
|
|
371
373
|
var e;
|
|
372
374
|
if (t == null)
|
|
373
375
|
return !0;
|
|
@@ -386,20 +388,20 @@ function Qs(t, s) {
|
|
|
386
388
|
return typeof t == "object";
|
|
387
389
|
}
|
|
388
390
|
}
|
|
389
|
-
const
|
|
390
|
-
function
|
|
391
|
-
|
|
391
|
+
const ge = { ...ir };
|
|
392
|
+
function El(t, s) {
|
|
393
|
+
ge[t] = s;
|
|
392
394
|
}
|
|
393
|
-
function
|
|
394
|
-
return
|
|
395
|
+
function cr(t, s) {
|
|
396
|
+
return ur(t, s) ? [] : ["invalid_value"];
|
|
395
397
|
}
|
|
396
|
-
function
|
|
398
|
+
function dr(t, s) {
|
|
397
399
|
var r;
|
|
398
|
-
const e = (r =
|
|
399
|
-
return e ?
|
|
400
|
+
const e = (r = ge[s]) == null ? void 0 : r.call(ge, t);
|
|
401
|
+
return e ? lt(e) : [];
|
|
400
402
|
}
|
|
401
|
-
const
|
|
402
|
-
class
|
|
403
|
+
const Hl = Symbol(), Je = /* @__PURE__ */ new WeakMap();
|
|
404
|
+
class pr extends at {
|
|
403
405
|
constructor(e) {
|
|
404
406
|
super();
|
|
405
407
|
_(this, "errors");
|
|
@@ -408,21 +410,21 @@ class Xs extends Qe {
|
|
|
408
410
|
_(this, "_submitted");
|
|
409
411
|
_(this, "_errors");
|
|
410
412
|
_(this, "_listeners", {});
|
|
411
|
-
this._fields = e, this._submitted =
|
|
413
|
+
this._fields = e, this._submitted = N(!1), this._data = this.getInitialData(e), this._errors = this.getInitialErrors(e), Je.set(
|
|
412
414
|
this,
|
|
413
415
|
c(() => !Object.values(this._errors).some((r) => r !== null))
|
|
414
|
-
), this.errors =
|
|
416
|
+
), this.errors = _e(this._errors);
|
|
415
417
|
}
|
|
416
418
|
get valid() {
|
|
417
419
|
var e;
|
|
418
|
-
return !!((e =
|
|
420
|
+
return !!((e = Je.get(this)) != null && e.value);
|
|
419
421
|
}
|
|
420
422
|
get submitted() {
|
|
421
423
|
return this._submitted.value;
|
|
422
424
|
}
|
|
423
425
|
setFieldValue(e, r) {
|
|
424
|
-
const n = this._fields[e] ??
|
|
425
|
-
this._data[e] = n.type === "string" && (n.trim ?? !0) ?
|
|
426
|
+
const n = this._fields[e] ?? W(`Trying to set undefined '${j(e)}' field`);
|
|
427
|
+
this._data[e] = n.type === "string" && (n.trim ?? !0) ? j(r).trim() : r, this._submitted.value && this.validate();
|
|
426
428
|
}
|
|
427
429
|
getFieldValue(e) {
|
|
428
430
|
return this._data[e];
|
|
@@ -431,6 +433,9 @@ class Xs extends Qe {
|
|
|
431
433
|
var r, n;
|
|
432
434
|
return ((n = (r = this._fields[e]) == null ? void 0 : r.rules) == null ? void 0 : n.split("|")) ?? [];
|
|
433
435
|
}
|
|
436
|
+
setFieldErrors(e, r) {
|
|
437
|
+
this._errors[e] = r;
|
|
438
|
+
}
|
|
434
439
|
getFieldType(e) {
|
|
435
440
|
var r;
|
|
436
441
|
return ((r = this._fields[e]) == null ? void 0 : r.type) ?? null;
|
|
@@ -459,11 +464,11 @@ class Xs extends Qe {
|
|
|
459
464
|
return (n = this._listeners)[e] ?? (n[e] = []), (a = this._listeners[e]) == null || a.push(r), () => this.off(e, r);
|
|
460
465
|
}
|
|
461
466
|
off(e, r) {
|
|
462
|
-
|
|
467
|
+
He(this._listeners[e] ?? [], r);
|
|
463
468
|
}
|
|
464
469
|
async focus(e) {
|
|
465
470
|
var r;
|
|
466
|
-
await
|
|
471
|
+
await Ft(), (r = this._listeners.focus) == null || r.forEach((n) => n(e));
|
|
467
472
|
}
|
|
468
473
|
__get(e) {
|
|
469
474
|
return e in this._fields ? this.getFieldValue(e) : super.__get(e);
|
|
@@ -476,24 +481,24 @@ class Xs extends Qe {
|
|
|
476
481
|
this.setFieldValue(e, r);
|
|
477
482
|
}
|
|
478
483
|
getFieldErrors(e, r) {
|
|
479
|
-
var
|
|
480
|
-
const n = [], a = this._data[e],
|
|
481
|
-
n.push(...
|
|
482
|
-
for (const
|
|
483
|
-
|
|
484
|
+
var i;
|
|
485
|
+
const n = [], a = this._data[e], u = ((i = r.rules) == null ? void 0 : i.split("|")) ?? [];
|
|
486
|
+
n.push(...cr(a, r));
|
|
487
|
+
for (const p of u)
|
|
488
|
+
p !== "required" && a == null || n.push(...dr(a, p));
|
|
484
489
|
return n.length > 0 ? n : null;
|
|
485
490
|
}
|
|
486
491
|
getInitialData(e) {
|
|
487
492
|
if (this.static().isConjuring())
|
|
488
493
|
return {};
|
|
489
|
-
const r = Object.entries(e).reduce((n, [a,
|
|
490
|
-
return
|
|
494
|
+
const r = Object.entries(e).reduce((n, [a, u]) => (n[a] = u.default ?? null, n), {});
|
|
495
|
+
return ve(r);
|
|
491
496
|
}
|
|
492
497
|
getInitialErrors(e) {
|
|
493
498
|
if (this.static().isConjuring())
|
|
494
499
|
return {};
|
|
495
500
|
const r = Object.keys(e).reduce((n, a) => (n[a] = null, n), {});
|
|
496
|
-
return
|
|
501
|
+
return ve(r);
|
|
497
502
|
}
|
|
498
503
|
resetData() {
|
|
499
504
|
for (const [e, r] of Object.entries(this._fields))
|
|
@@ -503,87 +508,114 @@ class Xs extends Qe {
|
|
|
503
508
|
Object.keys(this._errors).forEach((r) => delete this._errors[r]), e && Object.assign(this._errors, e);
|
|
504
509
|
}
|
|
505
510
|
}
|
|
506
|
-
function
|
|
507
|
-
const e =
|
|
508
|
-
|
|
511
|
+
function mt(t, s) {
|
|
512
|
+
const e = Y("form", null), r = e == null ? void 0 : e.on("focus", (n) => t.name === n && s());
|
|
513
|
+
$e(() => r == null ? void 0 : r());
|
|
509
514
|
}
|
|
510
|
-
function
|
|
511
|
-
return new
|
|
515
|
+
function ft(t) {
|
|
516
|
+
return new pr(t);
|
|
512
517
|
}
|
|
513
|
-
function
|
|
514
|
-
const t =
|
|
515
|
-
return [c(() =>
|
|
518
|
+
function Ae() {
|
|
519
|
+
const t = tt(), s = c(() => t.class);
|
|
520
|
+
return [c(() => ss(t, "class")), s];
|
|
516
521
|
}
|
|
517
|
-
function
|
|
518
|
-
let s =
|
|
519
|
-
|
|
522
|
+
function Vl(t) {
|
|
523
|
+
let s = rs;
|
|
524
|
+
st(() => s = t()), $e(() => s());
|
|
520
525
|
}
|
|
521
|
-
function
|
|
522
|
-
const e =
|
|
523
|
-
return
|
|
526
|
+
function Ll(t, s) {
|
|
527
|
+
const e = ve(O.get(t) ?? s);
|
|
528
|
+
return Le(e, () => O.set(t, Ut(e))), e;
|
|
524
529
|
}
|
|
525
|
-
function
|
|
526
|
-
|
|
527
|
-
|
|
530
|
+
function mr(t) {
|
|
531
|
+
let s = new Set(t), e, r;
|
|
532
|
+
const n = Ot((a, u) => (r = a, e = u, {
|
|
533
|
+
get: () => s,
|
|
534
|
+
set: () => W("Attempted to write read-only reactive set")
|
|
535
|
+
}));
|
|
536
|
+
return {
|
|
537
|
+
values() {
|
|
538
|
+
return r(), Array.from(n.value.values());
|
|
539
|
+
},
|
|
540
|
+
has(a) {
|
|
541
|
+
return r(), n.value.has(a);
|
|
542
|
+
},
|
|
543
|
+
add(a) {
|
|
544
|
+
e(), n.value.add(a);
|
|
545
|
+
},
|
|
546
|
+
delete(a) {
|
|
547
|
+
e(), n.value.delete(a);
|
|
548
|
+
},
|
|
549
|
+
clear() {
|
|
550
|
+
e(), n.value.clear();
|
|
551
|
+
},
|
|
552
|
+
reset(a) {
|
|
553
|
+
e(), s = new Set(a);
|
|
554
|
+
}
|
|
555
|
+
};
|
|
556
|
+
}
|
|
557
|
+
function Il(t) {
|
|
558
|
+
const s = N(), e = c(t);
|
|
559
|
+
return Le(e, async () => s.value = await e.value, { immediate: !0 }), s;
|
|
528
560
|
}
|
|
529
|
-
function
|
|
530
|
-
const e = s ? t : {}, r = s ?? t, n =
|
|
531
|
-
return
|
|
561
|
+
function zl(t, s) {
|
|
562
|
+
const e = s ? t : {}, r = s ?? t, n = N(e.initial ?? null), a = ns((u) => n.value = u, e.delay ?? 300);
|
|
563
|
+
return G(() => a(r())), n;
|
|
532
564
|
}
|
|
533
565
|
let ie = null;
|
|
534
|
-
function
|
|
535
|
-
return
|
|
566
|
+
function fr() {
|
|
567
|
+
return se(new Ne(), (t) => {
|
|
536
568
|
t.link = function(s) {
|
|
537
|
-
const e =
|
|
569
|
+
const e = Ne.prototype.link.apply(this, [s]);
|
|
538
570
|
return s.href.startsWith("#") ? e : e.replace("<a", '<a target="_blank"');
|
|
539
571
|
};
|
|
540
572
|
});
|
|
541
573
|
}
|
|
542
|
-
function
|
|
543
|
-
const s =
|
|
574
|
+
function hr(t) {
|
|
575
|
+
const s = ot(t, /<a[^>]*href="#action:([^"]+)"[^>]*>([^<]+)<\/a>/g);
|
|
544
576
|
for (const [e, r, n] of s)
|
|
545
577
|
t = t.replace(e, `<button type="button" data-markdown-action="${r}">${n}</button>`);
|
|
546
578
|
return t;
|
|
547
579
|
}
|
|
548
|
-
function
|
|
549
|
-
const s =
|
|
580
|
+
function gr(t) {
|
|
581
|
+
const s = ot(t, /<a[^>]*href="#route:([^"]+)"[^>]*>([^<]+)<\/a>/g);
|
|
550
582
|
for (const [e, r, n] of s) {
|
|
551
583
|
const a = (ie == null ? void 0 : ie.resolve(r)) ?? r;
|
|
552
584
|
t = t.replace(e, `<a data-markdown-route="${r}" href="${a}">${n}</a>`);
|
|
553
585
|
}
|
|
554
586
|
return t;
|
|
555
587
|
}
|
|
556
|
-
function
|
|
588
|
+
function vr() {
|
|
557
589
|
return ie;
|
|
558
590
|
}
|
|
559
|
-
function
|
|
591
|
+
function Rl(t) {
|
|
560
592
|
ie = t;
|
|
561
593
|
}
|
|
562
|
-
function
|
|
563
|
-
let s =
|
|
564
|
-
return s =
|
|
594
|
+
function br(t) {
|
|
595
|
+
let s = hs(t, { renderer: fr(), async: !1 });
|
|
596
|
+
return s = ht(s), s = hr(s), s = gr(s), s;
|
|
565
597
|
}
|
|
566
|
-
function
|
|
567
|
-
return
|
|
598
|
+
function ht(t) {
|
|
599
|
+
return fs.sanitize(t, { ADD_ATTR: ["target"] });
|
|
568
600
|
}
|
|
569
|
-
const
|
|
601
|
+
const yr = 6e4, Ze = -(/* @__PURE__ */ new Date()).getTimezoneOffset() * -yr, wr = {
|
|
570
602
|
mounted(t, { value: s }) {
|
|
571
|
-
t.innerHTML =
|
|
603
|
+
t.innerHTML = ht(s);
|
|
572
604
|
}
|
|
573
|
-
},
|
|
574
|
-
measure:
|
|
575
|
-
"safe-html":
|
|
576
|
-
},
|
|
605
|
+
}, $r = {
|
|
606
|
+
measure: or,
|
|
607
|
+
"safe-html": wr
|
|
608
|
+
}, _r = {
|
|
577
609
|
install(t, s) {
|
|
578
610
|
const e = {
|
|
579
|
-
|
|
611
|
+
...$r,
|
|
580
612
|
...s.directives
|
|
581
613
|
};
|
|
582
614
|
for (const [r, n] of Object.entries(e))
|
|
583
615
|
t.directive(r, n);
|
|
584
616
|
}
|
|
585
617
|
};
|
|
586
|
-
class
|
|
618
|
+
class xr extends Se {
|
|
587
619
|
constructor() {
|
|
588
620
|
super(...arguments);
|
|
589
621
|
_(this, "cache");
|
|
@@ -599,72 +631,79 @@ class lr extends we {
|
|
|
599
631
|
(await n.keys(e)).length !== 0 && await n.put(e, r);
|
|
600
632
|
}
|
|
601
633
|
async open() {
|
|
602
|
-
return this.cache = this.cache ??
|
|
634
|
+
return this.cache = this.cache ?? se(new J(), (e) => {
|
|
603
635
|
caches.open("app").then((r) => e.resolve(r));
|
|
604
636
|
});
|
|
605
637
|
}
|
|
606
638
|
}
|
|
607
|
-
const
|
|
608
|
-
class
|
|
639
|
+
const ql = re(xr);
|
|
640
|
+
class Cr extends Se {
|
|
609
641
|
async purge() {
|
|
610
|
-
await
|
|
642
|
+
await F.emit("purge-storage");
|
|
611
643
|
}
|
|
612
644
|
}
|
|
613
|
-
const
|
|
614
|
-
function
|
|
645
|
+
const gt = re(Cr);
|
|
646
|
+
function Al(t, s) {
|
|
615
647
|
return {
|
|
616
648
|
...t,
|
|
617
|
-
...
|
|
649
|
+
...ae(s, Object.keys(t))
|
|
618
650
|
};
|
|
619
651
|
}
|
|
620
|
-
const
|
|
621
|
-
$app:
|
|
622
|
-
$events:
|
|
623
|
-
$storage:
|
|
652
|
+
const Sr = {
|
|
653
|
+
$app: P,
|
|
654
|
+
$events: F,
|
|
655
|
+
$storage: gt
|
|
624
656
|
};
|
|
625
|
-
async function
|
|
657
|
+
async function ke(t, s) {
|
|
626
658
|
await Promise.all(
|
|
627
659
|
Object.entries(s).map(async ([e, r]) => {
|
|
628
660
|
await r.launch().catch((n) => {
|
|
629
|
-
var a,
|
|
630
|
-
return (
|
|
661
|
+
var a, u;
|
|
662
|
+
return (u = (a = t.config).errorHandler) == null ? void 0 : u.call(a, n, null, `Failed launching ${e}.`);
|
|
631
663
|
});
|
|
632
664
|
})
|
|
633
|
-
), Object.assign(t.config.globalProperties, s), (
|
|
665
|
+
), Object.assign(t.config.globalProperties, s), (Z() || ze()) && Object.assign(globalThis, s);
|
|
634
666
|
}
|
|
635
|
-
const
|
|
667
|
+
const kr = {
|
|
636
668
|
async install(t, s) {
|
|
637
669
|
var r;
|
|
638
670
|
const e = {
|
|
639
|
-
...
|
|
671
|
+
...Sr,
|
|
640
672
|
...s.services
|
|
641
673
|
};
|
|
642
|
-
t.use(
|
|
643
|
-
}
|
|
644
|
-
},
|
|
674
|
+
t.use(Ys()), (r = s.settings) == null || r.forEach((n) => P.addSetting(n)), await ke(t, e);
|
|
675
|
+
}
|
|
676
|
+
}, Xe = /* @__PURE__ */ new WeakSet();
|
|
677
|
+
function Pe() {
|
|
678
|
+
const t = ut(), { close: s, remove: e, ...r } = gs(Xe.has(t) ? {} : { removeOnClose: !1 });
|
|
679
|
+
return Xe.add(t), {
|
|
680
|
+
...r,
|
|
681
|
+
async close(n) {
|
|
682
|
+
s(n), await oe(1e3), e();
|
|
683
|
+
}
|
|
684
|
+
};
|
|
685
|
+
}
|
|
686
|
+
const vt = 768, be = {
|
|
645
687
|
Mobile: "mobile",
|
|
646
688
|
Desktop: "desktop"
|
|
647
689
|
};
|
|
648
|
-
function
|
|
649
|
-
return globalThis.innerWidth >
|
|
690
|
+
function bt() {
|
|
691
|
+
return globalThis.innerWidth > vt ? be.Desktop : be.Mobile;
|
|
650
692
|
}
|
|
651
|
-
const
|
|
693
|
+
const Tr = Ce({
|
|
652
694
|
name: "ui",
|
|
653
695
|
initialState: {
|
|
654
|
-
modals: [],
|
|
655
696
|
toasts: [],
|
|
656
|
-
layout:
|
|
697
|
+
layout: bt()
|
|
657
698
|
},
|
|
658
699
|
computed: {
|
|
659
|
-
desktop: ({ layout: t }) => t ===
|
|
660
|
-
mobile: ({ layout: t }) => t ===
|
|
661
|
-
openModals: ({ modals: t }) => t.filter(({ closing: s }) => !s)
|
|
700
|
+
desktop: ({ layout: t }) => t === be.Desktop,
|
|
701
|
+
mobile: ({ layout: t }) => t === be.Mobile
|
|
662
702
|
}
|
|
663
703
|
});
|
|
664
|
-
class
|
|
704
|
+
class Mr extends Tr {
|
|
665
705
|
constructor() {
|
|
666
706
|
super(...arguments);
|
|
667
|
-
_(this, "modalCallbacks", {});
|
|
668
707
|
_(this, "components", {});
|
|
669
708
|
}
|
|
670
709
|
registerComponent(e, r) {
|
|
@@ -674,7 +713,7 @@ class dr extends cr {
|
|
|
674
713
|
return this.components[e] ?? null;
|
|
675
714
|
}
|
|
676
715
|
requireComponent(e) {
|
|
677
|
-
return this.resolveComponent(e) ??
|
|
716
|
+
return this.resolveComponent(e) ?? W(`UI Component '${e}' is not defined!`);
|
|
678
717
|
}
|
|
679
718
|
alert(e, r) {
|
|
680
719
|
const n = () => typeof r != "string" ? { message: e } : {
|
|
@@ -686,7 +725,7 @@ class dr extends cr {
|
|
|
686
725
|
// prettier-ignore
|
|
687
726
|
/* eslint-enable max-len */
|
|
688
727
|
async confirm(e, r, n) {
|
|
689
|
-
const
|
|
728
|
+
const u = typeof r != "string" ? {
|
|
690
729
|
...r ?? {},
|
|
691
730
|
message: e,
|
|
692
731
|
required: !!(r != null && r.required)
|
|
@@ -695,31 +734,31 @@ class dr extends cr {
|
|
|
695
734
|
title: e,
|
|
696
735
|
message: r,
|
|
697
736
|
required: !!(n != null && n.required)
|
|
698
|
-
},
|
|
699
|
-
(
|
|
700
|
-
[
|
|
701
|
-
|
|
737
|
+
}, { response: i } = await this.modal(this.requireComponent("confirm-modal"), u), p = typeof i == "object" ? i[0] : i ?? !1, g = typeof i == "object" ? i[1] : Object.entries(u.checkboxes ?? {}).reduce(
|
|
738
|
+
(w, [v, { default: k }]) => ({
|
|
739
|
+
[v]: k ?? !1,
|
|
740
|
+
...w
|
|
702
741
|
}),
|
|
703
742
|
{}
|
|
704
743
|
);
|
|
705
|
-
for (const [
|
|
706
|
-
if (!(!
|
|
707
|
-
return
|
|
708
|
-
return "checkboxes" in
|
|
744
|
+
for (const [w, v] of Object.entries(u.checkboxes ?? {}))
|
|
745
|
+
if (!(!v.required || g[w]))
|
|
746
|
+
return p && Z() && console.warn(`Confirmed confirm modal was suppressed because required '${w}' checkbox was missing`), [!1, g];
|
|
747
|
+
return "checkboxes" in u ? [p, g] : p;
|
|
709
748
|
}
|
|
710
749
|
async prompt(e, r, n) {
|
|
711
|
-
const a = (n == null ? void 0 : n.trim) ?? !0,
|
|
750
|
+
const a = (n == null ? void 0 : n.trim) ?? !0, u = () => typeof r != "string" ? {
|
|
712
751
|
message: e,
|
|
713
752
|
...r ?? {}
|
|
714
753
|
} : {
|
|
715
754
|
title: e,
|
|
716
755
|
message: r,
|
|
717
756
|
...n ?? {}
|
|
718
|
-
},
|
|
719
|
-
return (a && typeof
|
|
757
|
+
}, { response: i } = await this.modal(this.requireComponent("prompt-modal"), u());
|
|
758
|
+
return (a && typeof i == "string" ? i == null ? void 0 : i.trim() : i) ?? null;
|
|
720
759
|
}
|
|
721
760
|
async loading(e, r) {
|
|
722
|
-
const n = (
|
|
761
|
+
const n = (v) => typeof v == "function" ? Promise.resolve(v()) : v, a = () => {
|
|
723
762
|
if (typeof e == "string")
|
|
724
763
|
return {
|
|
725
764
|
props: { message: e },
|
|
@@ -727,93 +766,59 @@ class dr extends cr {
|
|
|
727
766
|
};
|
|
728
767
|
if (typeof e == "function" || e instanceof Promise)
|
|
729
768
|
return { operationPromise: n(e) };
|
|
730
|
-
const { delay:
|
|
769
|
+
const { delay: v, ...k } = e;
|
|
731
770
|
return {
|
|
732
|
-
props:
|
|
733
|
-
delay: l(
|
|
771
|
+
props: k,
|
|
772
|
+
delay: l(v),
|
|
734
773
|
operationPromise: n(r)
|
|
735
774
|
};
|
|
736
775
|
};
|
|
737
|
-
let
|
|
738
|
-
const { operationPromise:
|
|
739
|
-
if (
|
|
740
|
-
return
|
|
741
|
-
const
|
|
776
|
+
let u = !1;
|
|
777
|
+
const { operationPromise: i, props: p, delay: g } = a();
|
|
778
|
+
if (g && await Promise.race([oe({ ms: g }).then(() => u = !0), i]), g && !u)
|
|
779
|
+
return i;
|
|
780
|
+
const w = vs(this.requireComponent("loading-modal"), p);
|
|
781
|
+
We(w);
|
|
742
782
|
try {
|
|
743
|
-
const
|
|
744
|
-
return await
|
|
783
|
+
const v = await i;
|
|
784
|
+
return await oe({ ms: 500 }), v;
|
|
745
785
|
} finally {
|
|
746
|
-
await
|
|
786
|
+
await Ke(w.id, { removeAfter: 1e3 });
|
|
747
787
|
}
|
|
748
788
|
}
|
|
749
789
|
toast(e, r = {}) {
|
|
750
|
-
const { component: n, ...a } = r,
|
|
751
|
-
id:
|
|
790
|
+
const { component: n, ...a } = r, u = {
|
|
791
|
+
id: ue(),
|
|
752
792
|
properties: { message: e, ...a },
|
|
753
|
-
component:
|
|
793
|
+
component: V(n ?? this.requireComponent("toast"))
|
|
754
794
|
};
|
|
755
|
-
this.setState("toasts", this.toasts.concat(
|
|
756
|
-
}
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
id: n,
|
|
760
|
-
closing: !1,
|
|
761
|
-
properties: r ?? {},
|
|
762
|
-
component: E(e),
|
|
763
|
-
beforeClose: new Promise((d) => a.willClose = d),
|
|
764
|
-
afterClose: new Promise((d) => a.hasClosed = d)
|
|
765
|
-
}, o = this.modals.concat(i);
|
|
766
|
-
return this.modalCallbacks[i.id] = a, this.setState({ modals: o }), await Oe(), i;
|
|
767
|
-
}
|
|
768
|
-
async modalForm(e, r) {
|
|
769
|
-
return await (await this.modal(e, r)).beforeClose;
|
|
770
|
-
}
|
|
771
|
-
async closeModal(e, r) {
|
|
772
|
-
if (!A.isMounted()) {
|
|
773
|
-
await this.removeModal(e, r);
|
|
774
|
-
return;
|
|
775
|
-
}
|
|
776
|
-
await R.emit("close-modal", { id: e, result: r });
|
|
795
|
+
this.setState("toasts", this.toasts.concat(u));
|
|
796
|
+
}
|
|
797
|
+
modal(e, r) {
|
|
798
|
+
return We(e, r ?? {});
|
|
777
799
|
}
|
|
778
800
|
async closeAllModals() {
|
|
779
|
-
|
|
780
|
-
await this.closeModal(Kt(this.modals[this.modals.length - 1]).id);
|
|
801
|
+
await Promise.all(le.value.map(({ id: e }) => Ke(e, { removeAfter: 1e3 })));
|
|
781
802
|
}
|
|
782
803
|
async boot() {
|
|
783
|
-
this.
|
|
784
|
-
}
|
|
785
|
-
async removeModal(e, r) {
|
|
786
|
-
var n, a;
|
|
787
|
-
this.setState(
|
|
788
|
-
"modals",
|
|
789
|
-
this.modals.filter((i) => i.id !== e)
|
|
790
|
-
), (a = (n = this.modalCallbacks[e]) == null ? void 0 : n.hasClosed) == null || a.call(n, r), delete this.modalCallbacks[e];
|
|
791
|
-
}
|
|
792
|
-
watchModalEvents() {
|
|
793
|
-
R.on("modal-will-close", ({ modal: { id: e }, result: r }) => {
|
|
794
|
-
var a, i;
|
|
795
|
-
const n = this.modals.find((o) => e === o.id);
|
|
796
|
-
n && (n.closing = !0), (i = (a = this.modalCallbacks[e]) == null ? void 0 : a.willClose) == null || i.call(a, r);
|
|
797
|
-
}), R.on("modal-has-closed", async ({ modal: { id: e }, result: r }) => {
|
|
798
|
-
await this.removeModal(e, r);
|
|
799
|
-
});
|
|
804
|
+
this.watchMountedEvent(), this.watchViewportBreakpoints();
|
|
800
805
|
}
|
|
801
806
|
watchMountedEvent() {
|
|
802
|
-
|
|
807
|
+
F.once("application-mounted", async () => {
|
|
803
808
|
if (!globalThis.document || !globalThis.getComputedStyle)
|
|
804
809
|
return;
|
|
805
810
|
const e = globalThis.document.getElementById("splash");
|
|
806
|
-
e && (globalThis.getComputedStyle(e).opacity !== "0" && (e.style.opacity = "0", await
|
|
811
|
+
e && (globalThis.getComputedStyle(e).opacity !== "0" && (e.style.opacity = "0", await oe({ ms: 600 })), e.remove());
|
|
807
812
|
});
|
|
808
813
|
}
|
|
809
814
|
watchViewportBreakpoints() {
|
|
810
815
|
if (!globalThis.matchMedia)
|
|
811
816
|
return;
|
|
812
|
-
globalThis.matchMedia(`(min-width: ${
|
|
817
|
+
globalThis.matchMedia(`(min-width: ${vt}px)`).addEventListener("change", () => this.setState({ layout: bt() }));
|
|
813
818
|
}
|
|
814
819
|
}
|
|
815
|
-
const
|
|
816
|
-
class
|
|
820
|
+
const A = re(Mr);
|
|
821
|
+
class Er {
|
|
817
822
|
constructor(s, e) {
|
|
818
823
|
this.locale = s, this.fallbackLocale = e;
|
|
819
824
|
}
|
|
@@ -833,13 +838,13 @@ class pr {
|
|
|
833
838
|
return ["en"];
|
|
834
839
|
}
|
|
835
840
|
translate(s) {
|
|
836
|
-
return
|
|
841
|
+
return Z() && console.warn("Lang provider is missing"), s;
|
|
837
842
|
}
|
|
838
843
|
translateWithDefault(s, e) {
|
|
839
|
-
return
|
|
844
|
+
return Z() && console.warn("Lang provider is missing"), e;
|
|
840
845
|
}
|
|
841
846
|
}
|
|
842
|
-
const
|
|
847
|
+
const Hr = Ce({
|
|
843
848
|
name: "lang",
|
|
844
849
|
persist: ["locale", "fallbackLocale"],
|
|
845
850
|
initialState: {
|
|
@@ -848,11 +853,11 @@ const mr = ye({
|
|
|
848
853
|
fallbackLocale: "en"
|
|
849
854
|
}
|
|
850
855
|
});
|
|
851
|
-
class
|
|
856
|
+
class Vr extends Hr {
|
|
852
857
|
constructor() {
|
|
853
858
|
super();
|
|
854
859
|
_(this, "provider");
|
|
855
|
-
this.provider = new
|
|
860
|
+
this.provider = new Er(
|
|
856
861
|
this.getState("locale") ?? this.getBrowserLocale(),
|
|
857
862
|
this.getState("fallbackLocale")
|
|
858
863
|
);
|
|
@@ -880,7 +885,7 @@ class fr extends mr {
|
|
|
880
885
|
);
|
|
881
886
|
}
|
|
882
887
|
}
|
|
883
|
-
const
|
|
888
|
+
const X = re(Vr), yt = X.translate.bind(X), S = X.translateWithDefault.bind(X), Lr = Ce({
|
|
884
889
|
name: "errors",
|
|
885
890
|
initialState: {
|
|
886
891
|
logs: [],
|
|
@@ -893,7 +898,7 @@ const Z = te(fr), it = Z.translate.bind(Z), S = Z.translateWithDefault.bind(Z),
|
|
|
893
898
|
hasStartupErrors: ({ startupErrors: t }) => t.length > 0
|
|
894
899
|
}
|
|
895
900
|
});
|
|
896
|
-
class
|
|
901
|
+
class Ir extends Lr {
|
|
897
902
|
constructor() {
|
|
898
903
|
super(...arguments);
|
|
899
904
|
_(this, "forceReporting", !1);
|
|
@@ -908,18 +913,18 @@ class gr extends hr {
|
|
|
908
913
|
}
|
|
909
914
|
async inspect(e, r) {
|
|
910
915
|
if (Array.isArray(e) && e.length === 0) {
|
|
911
|
-
|
|
916
|
+
A.alert(S("errors.inspectEmpty", "Nothing to inspect!"));
|
|
912
917
|
return;
|
|
913
918
|
}
|
|
914
919
|
const n = Array.isArray(e) ? e[0] : this.isErrorReport(e) ? e : await this.createErrorReport(e), a = Array.isArray(e) ? e : r ?? [n];
|
|
915
|
-
|
|
920
|
+
A.modal(A.requireComponent("error-report-modal"), { report: n, reports: a });
|
|
916
921
|
}
|
|
917
922
|
async report(e, r) {
|
|
918
|
-
if (await
|
|
923
|
+
if (await F.emit("error", { error: e, message: r }), ze("unit") || (Z() && this.logError(e), !this.enabled))
|
|
919
924
|
throw e;
|
|
920
|
-
if (!
|
|
921
|
-
const
|
|
922
|
-
|
|
925
|
+
if (!P.isMounted()) {
|
|
926
|
+
const u = await this.createStartupErrorReport(e);
|
|
927
|
+
u && this.setState({ startupErrors: this.startupErrors.concat(u) });
|
|
923
928
|
return;
|
|
924
929
|
}
|
|
925
930
|
const n = await this.createErrorReport(e), a = {
|
|
@@ -927,7 +932,7 @@ class gr extends hr {
|
|
|
927
932
|
seen: !1,
|
|
928
933
|
date: /* @__PURE__ */ new Date()
|
|
929
934
|
};
|
|
930
|
-
|
|
935
|
+
A.toast(
|
|
931
936
|
r ?? S("errors.notice", "Something went wrong, but it's not your fault. Try again!"),
|
|
932
937
|
{
|
|
933
938
|
variant: "danger",
|
|
@@ -935,14 +940,14 @@ class gr extends hr {
|
|
|
935
940
|
{
|
|
936
941
|
label: S("errors.viewDetails", "View details"),
|
|
937
942
|
dismiss: !0,
|
|
938
|
-
click: () =>
|
|
943
|
+
click: () => A.modal(A.requireComponent("error-report-modal"), { report: n, reports: [n] })
|
|
939
944
|
}
|
|
940
945
|
]
|
|
941
946
|
}
|
|
942
947
|
), this.setState({ logs: [a].concat(this.logs) });
|
|
943
948
|
}
|
|
944
949
|
reportDevelopmentError(e, r) {
|
|
945
|
-
|
|
950
|
+
Z() && (r && console.warn(r), this.logError(e));
|
|
946
951
|
}
|
|
947
952
|
see(e) {
|
|
948
953
|
this.setState({
|
|
@@ -953,7 +958,7 @@ class gr extends hr {
|
|
|
953
958
|
});
|
|
954
959
|
}
|
|
955
960
|
async boot() {
|
|
956
|
-
|
|
961
|
+
G(async () => {
|
|
957
962
|
var e;
|
|
958
963
|
if (!this.debug) {
|
|
959
964
|
(e = this.eruda) == null || e.destroy();
|
|
@@ -963,17 +968,17 @@ class gr extends hr {
|
|
|
963
968
|
});
|
|
964
969
|
}
|
|
965
970
|
logError(e) {
|
|
966
|
-
console.error(e),
|
|
971
|
+
console.error(e), he(e) && e.cause && this.logError(e.cause);
|
|
967
972
|
}
|
|
968
973
|
isErrorReport(e) {
|
|
969
|
-
return
|
|
974
|
+
return he(e) && "title" in e;
|
|
970
975
|
}
|
|
971
976
|
async createErrorReport(e) {
|
|
972
|
-
return typeof e == "string" ? { title: e } : e instanceof Error || e instanceof
|
|
973
|
-
title:
|
|
977
|
+
return typeof e == "string" ? { title: e } : e instanceof Error || e instanceof xe ? this.createErrorReportFromError(e) : he(e) ? it({
|
|
978
|
+
title: j(
|
|
974
979
|
e.name ?? e.title ?? S("errors.unknown", "Unknown Error")
|
|
975
980
|
),
|
|
976
|
-
description:
|
|
981
|
+
description: j(
|
|
977
982
|
e.message ?? e.description ?? S("errors.unknownDescription", "Unknown error object")
|
|
978
983
|
),
|
|
979
984
|
error: e
|
|
@@ -983,7 +988,7 @@ class gr extends hr {
|
|
|
983
988
|
};
|
|
984
989
|
}
|
|
985
990
|
async createStartupErrorReport(e) {
|
|
986
|
-
return e instanceof
|
|
991
|
+
return e instanceof Ve ? e.cause instanceof Ve ? null : this.createErrorReport(e.cause) : this.createErrorReport(e);
|
|
987
992
|
}
|
|
988
993
|
createErrorReportFromError(e, r = {}) {
|
|
989
994
|
return {
|
|
@@ -995,7 +1000,7 @@ class gr extends hr {
|
|
|
995
1000
|
};
|
|
996
1001
|
}
|
|
997
1002
|
}
|
|
998
|
-
const
|
|
1003
|
+
const wt = re(Ir), $t = /* @__PURE__ */ h({
|
|
999
1004
|
__name: "HeadlessButton",
|
|
1000
1005
|
props: {
|
|
1001
1006
|
class: {},
|
|
@@ -1012,8 +1017,8 @@ const ut = te(gr), ct = /* @__PURE__ */ g({
|
|
|
1012
1017
|
},
|
|
1013
1018
|
setup(t) {
|
|
1014
1019
|
const s = c(() => t.as ? { as: t.as } : t.route ? {
|
|
1015
|
-
as:
|
|
1016
|
-
to:
|
|
1020
|
+
as: A.resolveComponent("router-link") ?? "a",
|
|
1021
|
+
to: it({
|
|
1017
1022
|
name: t.route,
|
|
1018
1023
|
params: t.routeParams,
|
|
1019
1024
|
query: t.routeQuery
|
|
@@ -1026,18 +1031,18 @@ const ut = te(gr), ct = /* @__PURE__ */ g({
|
|
|
1026
1031
|
as: "button",
|
|
1027
1032
|
type: t.submit ? "submit" : "button"
|
|
1028
1033
|
});
|
|
1029
|
-
return (e, r) => (
|
|
1034
|
+
return (e, r) => (o(), f(l(xs), H({
|
|
1030
1035
|
class: t.class,
|
|
1031
1036
|
"as-child": e.asChild,
|
|
1032
1037
|
disabled: e.disabled
|
|
1033
1038
|
}, s.value), {
|
|
1034
|
-
default:
|
|
1035
|
-
|
|
1039
|
+
default: m(() => [
|
|
1040
|
+
$(e.$slots, "default")
|
|
1036
1041
|
]),
|
|
1037
1042
|
_: 3
|
|
1038
1043
|
}, 16, ["class", "as-child", "disabled"]));
|
|
1039
1044
|
}
|
|
1040
|
-
}),
|
|
1045
|
+
}), I = /* @__PURE__ */ h({
|
|
1041
1046
|
__name: "Button",
|
|
1042
1047
|
props: {
|
|
1043
1048
|
class: {},
|
|
@@ -1053,7 +1058,7 @@ const ut = te(gr), ct = /* @__PURE__ */ g({
|
|
|
1053
1058
|
as: {}
|
|
1054
1059
|
},
|
|
1055
1060
|
setup(t) {
|
|
1056
|
-
const s =
|
|
1061
|
+
const s = K(t, ["class", "size", "variant", "disabled"]), e = c(() => pt(
|
|
1057
1062
|
{ baseClasses: t.class, variant: t.variant, size: t.size, disabled: t.disabled },
|
|
1058
1063
|
{
|
|
1059
1064
|
baseClasses: "focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2",
|
|
@@ -1062,6 +1067,7 @@ const ut = te(gr), ct = /* @__PURE__ */ g({
|
|
|
1062
1067
|
default: "bg-primary-600 text-white focus-visible:outline-primary-600",
|
|
1063
1068
|
secondary: "bg-background text-gray-900 ring-gray-300",
|
|
1064
1069
|
danger: "bg-red-600 text-white focus-visible:outline-red-600",
|
|
1070
|
+
warning: "bg-yellow-600 text-white focus-visible:outline-yellow-600",
|
|
1065
1071
|
ghost: "bg-transparent",
|
|
1066
1072
|
outline: "bg-transparent text-primary-600 ring-primary-600",
|
|
1067
1073
|
link: "text-links"
|
|
@@ -1148,62 +1154,62 @@ const ut = te(gr), ct = /* @__PURE__ */ g({
|
|
|
1148
1154
|
}
|
|
1149
1155
|
}
|
|
1150
1156
|
));
|
|
1151
|
-
return (r, n) => (
|
|
1157
|
+
return (r, n) => (o(), f($t, H({
|
|
1152
1158
|
class: e.value,
|
|
1153
1159
|
disabled: r.disabled
|
|
1154
1160
|
}, s), {
|
|
1155
|
-
default:
|
|
1156
|
-
|
|
1161
|
+
default: m(() => [
|
|
1162
|
+
$(r.$slots, "default")
|
|
1157
1163
|
]),
|
|
1158
1164
|
_: 3
|
|
1159
1165
|
}, 16, ["class", "disabled"]));
|
|
1160
1166
|
}
|
|
1161
1167
|
});
|
|
1162
|
-
function
|
|
1168
|
+
function zr(t) {
|
|
1163
1169
|
return typeof t == "object" && t !== null && "label" in t;
|
|
1164
1170
|
}
|
|
1165
|
-
const
|
|
1171
|
+
const _t = /* @__PURE__ */ h({
|
|
1166
1172
|
__name: "HeadlessSelectValue",
|
|
1167
1173
|
setup(t) {
|
|
1168
|
-
const s =
|
|
1174
|
+
const s = R(
|
|
1169
1175
|
"select",
|
|
1170
1176
|
"<HeadlessSelectValue> must be a child of a <HeadlessSelect>"
|
|
1171
1177
|
);
|
|
1172
|
-
return (e, r) => e.$slots.default ? (
|
|
1178
|
+
return (e, r) => e.$slots.default ? (o(), f(l(Qe), {
|
|
1173
1179
|
key: 0,
|
|
1174
1180
|
placeholder: l(s).placeholder
|
|
1175
1181
|
}, {
|
|
1176
|
-
default:
|
|
1177
|
-
|
|
1182
|
+
default: m(() => [
|
|
1183
|
+
$(e.$slots, "default")
|
|
1178
1184
|
]),
|
|
1179
1185
|
_: 3
|
|
1180
|
-
}, 8, ["placeholder"])) : (
|
|
1186
|
+
}, 8, ["placeholder"])) : (o(), f(l(Qe), {
|
|
1181
1187
|
key: 1,
|
|
1182
1188
|
placeholder: l(s).placeholder
|
|
1183
1189
|
}, null, 8, ["placeholder"]));
|
|
1184
1190
|
}
|
|
1185
|
-
}),
|
|
1191
|
+
}), xt = /* @__PURE__ */ h({
|
|
1186
1192
|
__name: "HeadlessSelectTrigger",
|
|
1187
1193
|
setup(t) {
|
|
1188
|
-
const s =
|
|
1194
|
+
const s = R(
|
|
1189
1195
|
"select",
|
|
1190
1196
|
"<HeadlessSelectTrigger> must be a child of a <HeadlessSelect>"
|
|
1191
1197
|
);
|
|
1192
|
-
return (e, r) => (
|
|
1198
|
+
return (e, r) => (o(), f(l(Cs), {
|
|
1193
1199
|
id: l(s).id
|
|
1194
1200
|
}, {
|
|
1195
|
-
default:
|
|
1196
|
-
|
|
1197
|
-
|
|
1201
|
+
default: m(() => [
|
|
1202
|
+
$(e.$slots, "default", {}, () => [
|
|
1203
|
+
d(_t, {
|
|
1198
1204
|
placeholder: l(s).placeholder
|
|
1199
1205
|
}, null, 8, ["placeholder"]),
|
|
1200
|
-
|
|
1206
|
+
d(l(Ss))
|
|
1201
1207
|
])
|
|
1202
1208
|
]),
|
|
1203
1209
|
_: 3
|
|
1204
1210
|
}, 8, ["id"]));
|
|
1205
1211
|
}
|
|
1206
|
-
}),
|
|
1212
|
+
}), Ct = /* @__PURE__ */ h({
|
|
1207
1213
|
__name: "HeadlessSelectOption",
|
|
1208
1214
|
props: {
|
|
1209
1215
|
value: {},
|
|
@@ -1213,20 +1219,20 @@ const dt = /* @__PURE__ */ g({
|
|
|
1213
1219
|
as: {}
|
|
1214
1220
|
},
|
|
1215
1221
|
setup(t) {
|
|
1216
|
-
const s =
|
|
1222
|
+
const s = R(
|
|
1217
1223
|
"select",
|
|
1218
1224
|
"<HeadlessSelectOption> must be a child of a <HeadlessSelect>"
|
|
1219
1225
|
), e = c(() => {
|
|
1220
1226
|
var n;
|
|
1221
1227
|
const r = (n = s.options) == null ? void 0 : n.find((a) => a.value === t.value);
|
|
1222
|
-
return r ? r.label :
|
|
1228
|
+
return r ? r.label : j(t.value);
|
|
1223
1229
|
});
|
|
1224
|
-
return (r, n) => (
|
|
1225
|
-
default:
|
|
1226
|
-
|
|
1227
|
-
default:
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
+
return (r, n) => (o(), f(l(ks), ce(de(r.$props)), {
|
|
1231
|
+
default: m(() => [
|
|
1232
|
+
d(l(Ts), null, {
|
|
1233
|
+
default: m(() => [
|
|
1234
|
+
$(r.$slots, "default", {}, () => [
|
|
1235
|
+
L(x(e.value), 1)
|
|
1230
1236
|
])
|
|
1231
1237
|
]),
|
|
1232
1238
|
_: 3
|
|
@@ -1235,33 +1241,33 @@ const dt = /* @__PURE__ */ g({
|
|
|
1235
1241
|
_: 3
|
|
1236
1242
|
}, 16));
|
|
1237
1243
|
}
|
|
1238
|
-
}),
|
|
1244
|
+
}), St = /* @__PURE__ */ h({
|
|
1239
1245
|
__name: "HeadlessSelectOptions",
|
|
1240
1246
|
props: {
|
|
1241
1247
|
class: {},
|
|
1242
1248
|
innerClass: {}
|
|
1243
1249
|
},
|
|
1244
1250
|
setup(t) {
|
|
1245
|
-
const s =
|
|
1251
|
+
const s = R(
|
|
1246
1252
|
"select",
|
|
1247
1253
|
"<HeadlessSelectOptions> must be a child of a <HeadlessSelect>"
|
|
1248
|
-
), e = c(() =>
|
|
1249
|
-
return (r, n) => (
|
|
1250
|
-
default:
|
|
1251
|
-
|
|
1254
|
+
), e = c(() => E("min-w-(--reka-select-trigger-width) max-h-(--reka-select-content-available-height)", t.class));
|
|
1255
|
+
return (r, n) => (o(), f(l(Ms), null, {
|
|
1256
|
+
default: m(() => [
|
|
1257
|
+
d(l(Es), {
|
|
1252
1258
|
position: "popper",
|
|
1253
|
-
class:
|
|
1259
|
+
class: C(e.value),
|
|
1254
1260
|
align: l(s).align,
|
|
1255
1261
|
side: l(s).side,
|
|
1256
1262
|
"side-offset": 4
|
|
1257
1263
|
}, {
|
|
1258
|
-
default:
|
|
1259
|
-
|
|
1260
|
-
class:
|
|
1264
|
+
default: m(() => [
|
|
1265
|
+
d(l(Hs), {
|
|
1266
|
+
class: C(r.innerClass)
|
|
1261
1267
|
}, {
|
|
1262
|
-
default:
|
|
1263
|
-
|
|
1264
|
-
(
|
|
1268
|
+
default: m(() => [
|
|
1269
|
+
$(r.$slots, "default", {}, () => [
|
|
1270
|
+
(o(!0), y(D, null, U(l(s).options ?? [], (a) => (o(), f(Ct, {
|
|
1265
1271
|
key: a.key,
|
|
1266
1272
|
value: a.value
|
|
1267
1273
|
}, null, 8, ["value"]))), 128))
|
|
@@ -1276,7 +1282,7 @@ const dt = /* @__PURE__ */ g({
|
|
|
1276
1282
|
_: 3
|
|
1277
1283
|
}));
|
|
1278
1284
|
}
|
|
1279
|
-
}),
|
|
1285
|
+
}), Rr = /* @__PURE__ */ h({
|
|
1280
1286
|
inheritAttrs: !1,
|
|
1281
1287
|
__name: "HeadlessSelect",
|
|
1282
1288
|
props: {
|
|
@@ -1296,56 +1302,56 @@ const dt = /* @__PURE__ */ g({
|
|
|
1296
1302
|
},
|
|
1297
1303
|
emits: ["update:modelValue"],
|
|
1298
1304
|
setup(t, { expose: s, emit: e }) {
|
|
1299
|
-
const r = e, n =
|
|
1300
|
-
key:
|
|
1301
|
-
label: t.renderOption ? t.renderOption(
|
|
1302
|
-
value:
|
|
1303
|
-
})) : null),
|
|
1305
|
+
const r = e, n = Y("form", null), a = c(() => n && t.name ? n.getFieldValue(t.name) : t.modelValue), u = c(() => a.value), i = c(() => !n || !t.name ? null : n.errors[t.name] ?? null), p = c(() => t.options ? t.options.map((v) => ({
|
|
1306
|
+
key: ue(),
|
|
1307
|
+
label: t.renderOption ? t.renderOption(v) : zr(v) ? as(v.label) : j(v),
|
|
1308
|
+
value: v
|
|
1309
|
+
})) : null), g = {
|
|
1304
1310
|
labelClass: t.labelClass,
|
|
1305
1311
|
optionsClass: t.optionsClass,
|
|
1306
1312
|
align: t.align,
|
|
1307
1313
|
side: t.side,
|
|
1308
1314
|
value: a,
|
|
1309
|
-
id: `select-${
|
|
1315
|
+
id: `select-${ue()}`,
|
|
1310
1316
|
name: c(() => t.name),
|
|
1311
1317
|
label: c(() => t.label),
|
|
1312
1318
|
description: c(() => t.description),
|
|
1313
1319
|
placeholder: c(() => t.placeholder ?? S("ui.select", "Select an option")),
|
|
1314
|
-
options:
|
|
1320
|
+
options: p,
|
|
1315
1321
|
selectedOption: c(() => {
|
|
1316
|
-
var
|
|
1317
|
-
return (
|
|
1322
|
+
var v;
|
|
1323
|
+
return (v = p.value) == null ? void 0 : v.find((k) => k.value === t.modelValue);
|
|
1318
1324
|
}),
|
|
1319
|
-
errors:
|
|
1325
|
+
errors: _e(i),
|
|
1320
1326
|
required: c(() => {
|
|
1321
1327
|
if (!(!t.name || !n))
|
|
1322
1328
|
return n.getFieldRules(t.name).includes("required");
|
|
1323
1329
|
}),
|
|
1324
|
-
update(
|
|
1330
|
+
update(v) {
|
|
1325
1331
|
if (n && t.name) {
|
|
1326
|
-
n.setFieldValue(t.name,
|
|
1332
|
+
n.setFieldValue(t.name, v);
|
|
1327
1333
|
return;
|
|
1328
1334
|
}
|
|
1329
|
-
r("update:modelValue",
|
|
1335
|
+
r("update:modelValue", v);
|
|
1330
1336
|
}
|
|
1331
1337
|
};
|
|
1332
|
-
function
|
|
1333
|
-
|
|
1338
|
+
function w(v) {
|
|
1339
|
+
g.update(v);
|
|
1334
1340
|
}
|
|
1335
|
-
return
|
|
1336
|
-
"model-value":
|
|
1337
|
-
by:
|
|
1338
|
-
"onUpdate:modelValue":
|
|
1341
|
+
return pe("select", g), s(g), (v, k) => (o(), f(l(Vs), {
|
|
1342
|
+
"model-value": u.value,
|
|
1343
|
+
by: v.compareOptions,
|
|
1344
|
+
"onUpdate:modelValue": k[0] || (k[0] = (q) => w(q))
|
|
1339
1345
|
}, {
|
|
1340
|
-
default:
|
|
1341
|
-
(
|
|
1342
|
-
default:
|
|
1343
|
-
|
|
1344
|
-
modelValue:
|
|
1345
|
-
open:
|
|
1346
|
+
default: m(({ open: q }) => [
|
|
1347
|
+
(o(), f(ee(v.as), ce(de(v.$attrs)), {
|
|
1348
|
+
default: m(() => [
|
|
1349
|
+
$(v.$slots, "default", {
|
|
1350
|
+
modelValue: v.modelValue,
|
|
1351
|
+
open: q
|
|
1346
1352
|
}, () => [
|
|
1347
|
-
|
|
1348
|
-
|
|
1353
|
+
d(xt),
|
|
1354
|
+
d(St)
|
|
1349
1355
|
])
|
|
1350
1356
|
]),
|
|
1351
1357
|
_: 2
|
|
@@ -1354,50 +1360,50 @@ const dt = /* @__PURE__ */ g({
|
|
|
1354
1360
|
_: 3
|
|
1355
1361
|
}, 8, ["model-value", "by"]));
|
|
1356
1362
|
}
|
|
1357
|
-
}),
|
|
1363
|
+
}), Ye = /* @__PURE__ */ h({
|
|
1358
1364
|
__name: "HeadlessSelectLabel",
|
|
1359
1365
|
props: {
|
|
1360
1366
|
asChild: { type: Boolean },
|
|
1361
1367
|
as: {}
|
|
1362
1368
|
},
|
|
1363
1369
|
setup(t) {
|
|
1364
|
-
const s =
|
|
1370
|
+
const s = R(
|
|
1365
1371
|
"select",
|
|
1366
1372
|
"<HeadlessSelectLabel> must be a child of a <HeadlessSelect>"
|
|
1367
|
-
), e =
|
|
1368
|
-
return (n, a) => r.value ? (
|
|
1373
|
+
), e = Ie(), r = c(() => !!(s.label || e.default));
|
|
1374
|
+
return (n, a) => r.value ? (o(), f(l(Ls), H({
|
|
1369
1375
|
key: 0,
|
|
1370
1376
|
for: l(s).id
|
|
1371
1377
|
}, n.$props), {
|
|
1372
|
-
default:
|
|
1373
|
-
|
|
1374
|
-
|
|
1378
|
+
default: m(() => [
|
|
1379
|
+
$(n.$slots, "default", {}, () => [
|
|
1380
|
+
L(x(l(s).label), 1)
|
|
1375
1381
|
])
|
|
1376
1382
|
]),
|
|
1377
1383
|
_: 3
|
|
1378
|
-
}, 16, ["for"])) :
|
|
1384
|
+
}, 16, ["for"])) : M("", !0);
|
|
1379
1385
|
}
|
|
1380
|
-
}),
|
|
1386
|
+
}), kt = /* @__PURE__ */ h({
|
|
1381
1387
|
__name: "SelectLabel",
|
|
1382
1388
|
props: {
|
|
1383
1389
|
class: {}
|
|
1384
1390
|
},
|
|
1385
1391
|
setup(t) {
|
|
1386
|
-
const s =
|
|
1387
|
-
return (r, n) => r.$slots.default ? (
|
|
1392
|
+
const s = R("select", "<SelectLabel> must be a child of a <Select>"), e = c(() => E("block text-sm leading-6 font-medium text-gray-900", s.labelClass, t.class));
|
|
1393
|
+
return (r, n) => r.$slots.default ? (o(), f(Ye, {
|
|
1388
1394
|
key: 0,
|
|
1389
|
-
class:
|
|
1395
|
+
class: C(e.value)
|
|
1390
1396
|
}, {
|
|
1391
|
-
default:
|
|
1392
|
-
|
|
1397
|
+
default: m(() => [
|
|
1398
|
+
$(r.$slots, "default")
|
|
1393
1399
|
]),
|
|
1394
1400
|
_: 3
|
|
1395
|
-
}, 8, ["class"])) : (
|
|
1401
|
+
}, 8, ["class"])) : (o(), f(Ye, {
|
|
1396
1402
|
key: 1,
|
|
1397
|
-
class:
|
|
1403
|
+
class: C(e.value)
|
|
1398
1404
|
}, null, 8, ["class"]));
|
|
1399
1405
|
}
|
|
1400
|
-
}),
|
|
1406
|
+
}), Ge = /* @__PURE__ */ h({
|
|
1401
1407
|
__name: "SelectOption",
|
|
1402
1408
|
props: {
|
|
1403
1409
|
value: {},
|
|
@@ -1405,62 +1411,62 @@ const dt = /* @__PURE__ */ g({
|
|
|
1405
1411
|
innerClass: {}
|
|
1406
1412
|
},
|
|
1407
1413
|
setup(t) {
|
|
1408
|
-
const s = c(() =>
|
|
1414
|
+
const s = c(() => E("group p-1 outline-none", t.class)), e = c(() => E(
|
|
1409
1415
|
// eslint-disable-next-line vue/max-len
|
|
1410
1416
|
"relative flex max-w-[calc(100vw-2rem)] cursor-pointer items-center truncate rounded-md gap-2 px-2 py-1 text-sm select-none *:truncate group-data-[highlighted]:bg-gray-100 group-data-[state=checked]:font-semibold group-data-[state=unchecked]:opacity-50",
|
|
1411
1417
|
t.innerClass
|
|
1412
1418
|
));
|
|
1413
|
-
return (r, n) => (
|
|
1414
|
-
class:
|
|
1419
|
+
return (r, n) => (o(), f(Ct, {
|
|
1420
|
+
class: C(s.value),
|
|
1415
1421
|
value: r.value
|
|
1416
1422
|
}, {
|
|
1417
|
-
default:
|
|
1418
|
-
|
|
1419
|
-
class:
|
|
1423
|
+
default: m(() => [
|
|
1424
|
+
b("div", {
|
|
1425
|
+
class: C(e.value)
|
|
1420
1426
|
}, [
|
|
1421
|
-
|
|
1427
|
+
$(r.$slots, "default")
|
|
1422
1428
|
], 2)
|
|
1423
1429
|
]),
|
|
1424
1430
|
_: 3
|
|
1425
1431
|
}, 8, ["class", "value"]));
|
|
1426
1432
|
}
|
|
1427
|
-
}),
|
|
1433
|
+
}), Tt = /* @__PURE__ */ h({
|
|
1428
1434
|
__name: "SelectOptions",
|
|
1429
1435
|
props: {
|
|
1430
1436
|
class: {}
|
|
1431
1437
|
},
|
|
1432
1438
|
setup(t) {
|
|
1433
|
-
const s =
|
|
1439
|
+
const s = R("select", "<SelectOptions> must be a child of a <Select>"), e = c(() => E(
|
|
1434
1440
|
"z-50 overflow-auto rounded-lg bg-white text-base shadow-lg ring-1 ring-black/5 focus:outline-hidden",
|
|
1435
1441
|
s.optionsClass,
|
|
1436
1442
|
t.class
|
|
1437
1443
|
));
|
|
1438
|
-
return (r, n) => (
|
|
1439
|
-
class:
|
|
1444
|
+
return (r, n) => (o(), f(St, {
|
|
1445
|
+
class: C(e.value)
|
|
1440
1446
|
}, {
|
|
1441
|
-
default:
|
|
1447
|
+
default: m(() => {
|
|
1442
1448
|
var a;
|
|
1443
1449
|
return [
|
|
1444
|
-
(a = l(s).options) != null && a.length ?
|
|
1445
|
-
var
|
|
1450
|
+
(a = l(s).options) != null && a.length ? $(r.$slots, "default", { key: 0 }, () => {
|
|
1451
|
+
var u;
|
|
1446
1452
|
return [
|
|
1447
|
-
(
|
|
1448
|
-
key:
|
|
1449
|
-
value:
|
|
1453
|
+
(o(!0), y(D, null, U(((u = l(s)) == null ? void 0 : u.options) ?? [], (i) => (o(), f(Ge, {
|
|
1454
|
+
key: i.key,
|
|
1455
|
+
value: i.value
|
|
1450
1456
|
}, {
|
|
1451
|
-
default:
|
|
1452
|
-
|
|
1457
|
+
default: m(() => [
|
|
1458
|
+
L(x(i.label), 1)
|
|
1453
1459
|
]),
|
|
1454
1460
|
_: 2
|
|
1455
1461
|
}, 1032, ["value"]))), 128))
|
|
1456
1462
|
];
|
|
1457
|
-
}) :
|
|
1458
|
-
|
|
1463
|
+
}) : $(r.$slots, "default", { key: 1 }, () => [
|
|
1464
|
+
d(Ge, {
|
|
1459
1465
|
disabled: "",
|
|
1460
1466
|
value: null
|
|
1461
1467
|
}, {
|
|
1462
|
-
default:
|
|
1463
|
-
|
|
1468
|
+
default: m(() => [
|
|
1469
|
+
L(x(r.$td("ui.selectEmpty", "No options available")), 1)
|
|
1464
1470
|
]),
|
|
1465
1471
|
_: 1
|
|
1466
1472
|
})
|
|
@@ -1470,42 +1476,42 @@ const dt = /* @__PURE__ */ g({
|
|
|
1470
1476
|
_: 3
|
|
1471
1477
|
}, 8, ["class"]));
|
|
1472
1478
|
}
|
|
1473
|
-
}),
|
|
1479
|
+
}), qr = {
|
|
1474
1480
|
viewBox: "0 0 20 20",
|
|
1475
1481
|
width: "1.2em",
|
|
1476
1482
|
height: "1.2em"
|
|
1477
1483
|
};
|
|
1478
|
-
function
|
|
1479
|
-
return
|
|
1480
|
-
|
|
1484
|
+
function Ar(t, s) {
|
|
1485
|
+
return o(), y("svg", qr, s[0] || (s[0] = [
|
|
1486
|
+
b("path", {
|
|
1481
1487
|
fill: "currentColor",
|
|
1482
1488
|
d: "m9.293 12.95l.707.707L15.657 8l-1.414-1.414L10 10.828L5.757 6.586L4.343 8z"
|
|
1483
1489
|
}, null, -1)
|
|
1484
1490
|
]));
|
|
1485
1491
|
}
|
|
1486
|
-
const
|
|
1492
|
+
const Pr = V({ name: "zondicons-cheveron-down", render: Ar }), Mt = /* @__PURE__ */ h({
|
|
1487
1493
|
__name: "SelectTrigger",
|
|
1488
1494
|
props: {
|
|
1489
1495
|
class: {}
|
|
1490
1496
|
},
|
|
1491
1497
|
setup(t) {
|
|
1492
|
-
const s =
|
|
1498
|
+
const s = R("select", "<SelectTrigger> must be a child of a <Select>"), e = c(() => E(
|
|
1493
1499
|
// eslint-disable-next-line vue/max-len
|
|
1494
1500
|
"focus:outline-primary-600 data-[state=open]:outline-primary-600 grid w-full cursor-default grid-cols-1 rounded-md bg-white py-1.5 pr-2 pl-3 text-left text-gray-900 outline-1 -outline-offset-1 outline-gray-300 focus:outline-2 focus:-outline-offset-2 sm:text-sm/6",
|
|
1495
1501
|
{ "mt-1": s.label },
|
|
1496
1502
|
t.class
|
|
1497
1503
|
));
|
|
1498
|
-
return (r, n) => (
|
|
1499
|
-
class:
|
|
1504
|
+
return (r, n) => (o(), f(xt, {
|
|
1505
|
+
class: C(e.value)
|
|
1500
1506
|
}, {
|
|
1501
|
-
default:
|
|
1502
|
-
|
|
1503
|
-
|
|
1507
|
+
default: m(() => [
|
|
1508
|
+
d(_t, { class: "col-start-1 row-start-1 truncate pr-6" }),
|
|
1509
|
+
d(l(Pr), { class: "col-start-1 row-start-1 size-5 self-center justify-self-end text-gray-500 sm:size-4" })
|
|
1504
1510
|
]),
|
|
1505
1511
|
_: 1
|
|
1506
1512
|
}, 8, ["class"]));
|
|
1507
1513
|
}
|
|
1508
|
-
}),
|
|
1514
|
+
}), Dr = /* @__PURE__ */ h({
|
|
1509
1515
|
__name: "Select",
|
|
1510
1516
|
props: {
|
|
1511
1517
|
as: {},
|
|
@@ -1524,72 +1530,72 @@ const $r = E({ name: "zondicons-cheveron-down", render: wr }), vt = /* @__PURE__
|
|
|
1524
1530
|
},
|
|
1525
1531
|
emits: ["update:modelValue"],
|
|
1526
1532
|
setup(t) {
|
|
1527
|
-
const { forwardRef: s } =
|
|
1528
|
-
return (e, r) => (
|
|
1533
|
+
const { forwardRef: s } = Re();
|
|
1534
|
+
return (e, r) => (o(), f(Rr, H({ ref: l(s) }, e.$props, {
|
|
1529
1535
|
"onUpdate:modelValue": r[0] || (r[0] = (n) => e.$emit("update:modelValue", n))
|
|
1530
1536
|
}), {
|
|
1531
|
-
default:
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
|
|
1537
|
+
default: m(() => [
|
|
1538
|
+
d(kt),
|
|
1539
|
+
$(e.$slots, "default", {}, () => [
|
|
1540
|
+
d(Mt),
|
|
1541
|
+
d(Tt)
|
|
1536
1542
|
])
|
|
1537
1543
|
]),
|
|
1538
1544
|
_: 3
|
|
1539
1545
|
}, 16));
|
|
1540
1546
|
}
|
|
1541
|
-
}),
|
|
1547
|
+
}), Br = { class: "grow" }, jr = /* @__PURE__ */ h({
|
|
1542
1548
|
__name: "Language",
|
|
1543
1549
|
setup(t) {
|
|
1544
|
-
const s =
|
|
1550
|
+
const s = X.getBrowserLocale(), e = c(() => [null, ...X.locales]);
|
|
1545
1551
|
function r(n) {
|
|
1546
|
-
return (n &&
|
|
1547
|
-
locale:
|
|
1552
|
+
return (n && B.locales[n]) ?? S("settings.localeDefault", "{locale} (default)", {
|
|
1553
|
+
locale: B.locales[s] ?? s
|
|
1548
1554
|
});
|
|
1549
1555
|
}
|
|
1550
|
-
return (n, a) => (
|
|
1556
|
+
return (n, a) => (o(), f(Dr, {
|
|
1551
1557
|
modelValue: n.$lang.locale,
|
|
1552
|
-
"onUpdate:modelValue": a[0] || (a[0] = (
|
|
1558
|
+
"onUpdate:modelValue": a[0] || (a[0] = (u) => n.$lang.locale = u),
|
|
1553
1559
|
class: "flex flex-col items-start md:flex-row",
|
|
1554
1560
|
as: "div",
|
|
1555
1561
|
options: e.value,
|
|
1556
1562
|
"render-option": r
|
|
1557
1563
|
}, {
|
|
1558
|
-
default:
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
default:
|
|
1562
|
-
|
|
1564
|
+
default: m(() => [
|
|
1565
|
+
b("div", Br, [
|
|
1566
|
+
d(kt, { class: "text-base font-semibold" }, {
|
|
1567
|
+
default: m(() => [
|
|
1568
|
+
L(x(n.$td("settings.locale", "Language")), 1)
|
|
1563
1569
|
]),
|
|
1564
1570
|
_: 1
|
|
1565
1571
|
}),
|
|
1566
|
-
|
|
1572
|
+
d(z, {
|
|
1567
1573
|
"lang-key": "settings.localeDescription",
|
|
1568
1574
|
"lang-default": "Choose the application's language.",
|
|
1569
1575
|
class: "mt-1 text-sm text-gray-500"
|
|
1570
1576
|
})
|
|
1571
1577
|
]),
|
|
1572
|
-
|
|
1578
|
+
d(I, {
|
|
1573
1579
|
variant: "ghost",
|
|
1574
|
-
as:
|
|
1580
|
+
as: Mt,
|
|
1575
1581
|
class: "grid w-auto outline-none"
|
|
1576
1582
|
}),
|
|
1577
|
-
|
|
1583
|
+
d(Tt)
|
|
1578
1584
|
]),
|
|
1579
1585
|
_: 1
|
|
1580
1586
|
}, 8, ["modelValue", "options"]));
|
|
1581
1587
|
}
|
|
1582
|
-
}),
|
|
1588
|
+
}), Fr = [
|
|
1583
1589
|
{
|
|
1584
1590
|
priority: 100,
|
|
1585
|
-
component:
|
|
1591
|
+
component: jr
|
|
1586
1592
|
}
|
|
1587
|
-
],
|
|
1593
|
+
], Ur = { $lang: X }, Or = {
|
|
1588
1594
|
async install(t) {
|
|
1589
1595
|
var s;
|
|
1590
|
-
(s = t.config.globalProperties).$t ?? (s.$t =
|
|
1596
|
+
(s = t.config.globalProperties).$t ?? (s.$t = yt), t.config.globalProperties.$td = S, Fr.forEach((e) => P.addSetting(e)), await ke(t, Ur);
|
|
1591
1597
|
}
|
|
1592
|
-
},
|
|
1598
|
+
}, Nr = /* @__PURE__ */ h({
|
|
1593
1599
|
__name: "Markdown",
|
|
1594
1600
|
props: {
|
|
1595
1601
|
as: {},
|
|
@@ -1601,38 +1607,38 @@ const $r = E({ name: "zondicons-cheveron-down", render: wr }), vt = /* @__PURE__
|
|
|
1601
1607
|
actions: {}
|
|
1602
1608
|
},
|
|
1603
1609
|
setup(t) {
|
|
1604
|
-
const s =
|
|
1610
|
+
const s = tt(), e = Ie(), r = c(() => e.default ? e.default().map(dt).join("") : t.text ?? (t.langKey && (t.langDefault ? S(t.langKey, t.langDefault, t.langParams ?? {}) : yt(t.langKey, t.langParams ?? {})))), n = c(() => {
|
|
1605
1611
|
if (!r.value)
|
|
1606
1612
|
return null;
|
|
1607
|
-
let
|
|
1608
|
-
return t.inline && (
|
|
1609
|
-
}), a = () =>
|
|
1613
|
+
let i = br(r.value);
|
|
1614
|
+
return t.inline && (i = i.replace("<p>", "<span>").replace("</p>", "</span>")), i;
|
|
1615
|
+
}), a = () => Nt(t.as ?? (t.inline ? "span" : "div"), {
|
|
1610
1616
|
innerHTML: n.value,
|
|
1611
|
-
onClick:
|
|
1617
|
+
onClick: u,
|
|
1612
1618
|
...s,
|
|
1613
1619
|
class: `${s.class ?? ""} ${t.inline ? "" : "prose"}`
|
|
1614
1620
|
});
|
|
1615
|
-
async function i
|
|
1616
|
-
var
|
|
1617
|
-
const { target:
|
|
1618
|
-
if (
|
|
1619
|
-
(
|
|
1621
|
+
async function u(i) {
|
|
1622
|
+
var g, w;
|
|
1623
|
+
const { target: p } = i;
|
|
1624
|
+
if (Oe(p, HTMLElement) && p.dataset.markdownAction) {
|
|
1625
|
+
(w = (g = t.actions) == null ? void 0 : g[p.dataset.markdownAction]) == null || w.call(g);
|
|
1620
1626
|
return;
|
|
1621
1627
|
}
|
|
1622
|
-
if (
|
|
1623
|
-
const
|
|
1624
|
-
|
|
1628
|
+
if (Oe(p, HTMLAnchorElement) && p.dataset.markdownRoute) {
|
|
1629
|
+
const v = vr();
|
|
1630
|
+
v && (i.preventDefault(), v.visit(p.dataset.markdownRoute));
|
|
1625
1631
|
return;
|
|
1626
1632
|
}
|
|
1627
1633
|
}
|
|
1628
|
-
return (
|
|
1634
|
+
return (i, p) => (o(), f(a));
|
|
1629
1635
|
}
|
|
1630
|
-
}),
|
|
1636
|
+
}), Wr = (t, s) => {
|
|
1631
1637
|
const e = t.__vccOpts || t;
|
|
1632
1638
|
for (const [r, n] of s)
|
|
1633
1639
|
e[r] = n;
|
|
1634
1640
|
return e;
|
|
1635
|
-
},
|
|
1641
|
+
}, z = /* @__PURE__ */ Wr(Nr, [["__scopeId", "data-v-8b211cfb"]]), Kr = { class: "flex-grow" }, Qr = ["id"], Jr = /* @__PURE__ */ h({
|
|
1636
1642
|
__name: "Setting",
|
|
1637
1643
|
props: {
|
|
1638
1644
|
title: {},
|
|
@@ -1642,29 +1648,29 @@ const $r = E({ name: "zondicons-cheveron-down", render: wr }), vt = /* @__PURE__
|
|
|
1642
1648
|
layout: { default: "horizontal" }
|
|
1643
1649
|
},
|
|
1644
1650
|
setup(t) {
|
|
1645
|
-
const s = c(() =>
|
|
1646
|
-
return (e, r) => (
|
|
1647
|
-
class:
|
|
1651
|
+
const s = c(() => E(t.class, "flex flex-col justify-center gap-1"));
|
|
1652
|
+
return (e, r) => (o(), y("div", {
|
|
1653
|
+
class: C(["mt-4 flex", { "flex-col": e.layout === "vertical" }])
|
|
1648
1654
|
}, [
|
|
1649
|
-
|
|
1650
|
-
|
|
1655
|
+
b("div", Kr, [
|
|
1656
|
+
b("h3", {
|
|
1651
1657
|
id: e.titleId,
|
|
1652
1658
|
class: "text-base font-semibold"
|
|
1653
|
-
}, x(e.title), 9,
|
|
1654
|
-
e.description ? (
|
|
1659
|
+
}, x(e.title), 9, Qr),
|
|
1660
|
+
e.description ? (o(), f(z, {
|
|
1655
1661
|
key: 0,
|
|
1656
1662
|
text: e.description,
|
|
1657
1663
|
class: "mt-1 text-sm text-gray-500"
|
|
1658
|
-
}, null, 8, ["text"])) :
|
|
1664
|
+
}, null, 8, ["text"])) : M("", !0)
|
|
1659
1665
|
]),
|
|
1660
|
-
|
|
1661
|
-
class:
|
|
1666
|
+
b("div", {
|
|
1667
|
+
class: C(s.value)
|
|
1662
1668
|
}, [
|
|
1663
|
-
|
|
1669
|
+
$(e.$slots, "default")
|
|
1664
1670
|
], 2)
|
|
1665
1671
|
], 2));
|
|
1666
1672
|
}
|
|
1667
|
-
}),
|
|
1673
|
+
}), Zr = ["for"], Xr = /* @__PURE__ */ h({
|
|
1668
1674
|
inheritAttrs: !1,
|
|
1669
1675
|
__name: "HeadlessSwitch",
|
|
1670
1676
|
props: {
|
|
@@ -1679,71 +1685,71 @@ const $r = E({ name: "zondicons-cheveron-down", render: wr }), vt = /* @__PURE__
|
|
|
1679
1685
|
},
|
|
1680
1686
|
emits: ["update:modelValue"],
|
|
1681
1687
|
setup(t, { expose: s, emit: e }) {
|
|
1682
|
-
const r = e, n =
|
|
1683
|
-
id: `switch-${
|
|
1688
|
+
const r = e, n = Y("form", null), a = c(() => !n || !t.name ? null : n.errors[t.name] ?? null), u = {
|
|
1689
|
+
id: `switch-${ue()}`,
|
|
1684
1690
|
name: c(() => t.name),
|
|
1685
1691
|
label: c(() => t.label),
|
|
1686
1692
|
description: c(() => t.description),
|
|
1687
1693
|
value: c(() => n && t.name ? n.getFieldValue(t.name) : t.modelValue),
|
|
1688
|
-
errors:
|
|
1694
|
+
errors: _e(a),
|
|
1689
1695
|
required: c(() => {
|
|
1690
1696
|
if (!(!t.name || !n))
|
|
1691
1697
|
return n.getFieldRules(t.name).includes("required");
|
|
1692
1698
|
}),
|
|
1693
|
-
update(
|
|
1699
|
+
update(i) {
|
|
1694
1700
|
if (n && t.name) {
|
|
1695
|
-
n.setFieldValue(t.name,
|
|
1701
|
+
n.setFieldValue(t.name, i);
|
|
1696
1702
|
return;
|
|
1697
1703
|
}
|
|
1698
|
-
r("update:modelValue",
|
|
1704
|
+
r("update:modelValue", i);
|
|
1699
1705
|
}
|
|
1700
1706
|
};
|
|
1701
|
-
return s(
|
|
1707
|
+
return s(u), G(() => {
|
|
1702
1708
|
!t.description && !a.value || console.warn("Errors and description not implemented in <HeadlessSwitch>");
|
|
1703
|
-
}), (
|
|
1704
|
-
class:
|
|
1709
|
+
}), (i, p) => (o(), y("div", {
|
|
1710
|
+
class: C(t.class)
|
|
1705
1711
|
}, [
|
|
1706
|
-
|
|
1712
|
+
i.label ? (o(), y("label", {
|
|
1707
1713
|
key: 0,
|
|
1708
|
-
for:
|
|
1709
|
-
class:
|
|
1710
|
-
}, x(
|
|
1711
|
-
|
|
1712
|
-
id:
|
|
1713
|
-
name:
|
|
1714
|
-
"model-value":
|
|
1715
|
-
},
|
|
1716
|
-
class:
|
|
1717
|
-
"onUpdate:modelValue":
|
|
1714
|
+
for: u.id,
|
|
1715
|
+
class: C(i.labelClass)
|
|
1716
|
+
}, x(i.label), 11, Zr)) : M("", !0),
|
|
1717
|
+
d(l(Is), H({
|
|
1718
|
+
id: u.id,
|
|
1719
|
+
name: i.name,
|
|
1720
|
+
"model-value": u.value.value
|
|
1721
|
+
}, i.$attrs, {
|
|
1722
|
+
class: i.inputClass,
|
|
1723
|
+
"onUpdate:modelValue": p[0] || (p[0] = (g) => i.$emit("update:modelValue", g))
|
|
1718
1724
|
}), {
|
|
1719
|
-
default:
|
|
1720
|
-
|
|
1721
|
-
class:
|
|
1725
|
+
default: m(() => [
|
|
1726
|
+
d(l(zs), {
|
|
1727
|
+
class: C(i.thumbClass)
|
|
1722
1728
|
}, null, 8, ["class"])
|
|
1723
1729
|
]),
|
|
1724
1730
|
_: 1
|
|
1725
1731
|
}, 16, ["id", "name", "model-value", "class"])
|
|
1726
1732
|
], 2));
|
|
1727
1733
|
}
|
|
1728
|
-
}),
|
|
1734
|
+
}), Yr = /* @__PURE__ */ h({
|
|
1729
1735
|
__name: "Switch",
|
|
1730
1736
|
setup(t) {
|
|
1731
|
-
return (s, e) => (
|
|
1737
|
+
return (s, e) => (o(), f(Xr, {
|
|
1732
1738
|
class: "flex flex-row items-center gap-1",
|
|
1733
1739
|
"input-class": "disabled:opacity-50 disabled:cursor-not-allowed data-[state=checked]:bg-primary-600 data-[state=unchecked]:bg-gray-200 relative inline-flex h-6 w-11 shrink-0 cursor-pointer rounded-full border-2 border-transparent transition-colors duration-200 ease-in-out focusdisabled:opacity-50 disabled:cursor-not-allowed :ring-2 focus:ring-primary-600 focus:ring-offset-2 focus:outline-hidden",
|
|
1734
1740
|
"thumb-class": "data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0 pointer-events-none inline-block size-5 transform rounded-full bg-white shadow-sm ring-0 transition duration-200 ease-in-out"
|
|
1735
1741
|
}));
|
|
1736
1742
|
}
|
|
1737
|
-
}),
|
|
1743
|
+
}), Gr = /* @__PURE__ */ h({
|
|
1738
1744
|
__name: "Debug",
|
|
1739
1745
|
setup(t) {
|
|
1740
|
-
return (s, e) => (
|
|
1746
|
+
return (s, e) => (o(), f(Jr, {
|
|
1741
1747
|
"title-id": "debug-setting",
|
|
1742
1748
|
title: s.$td("settings.debug", "Debugging"),
|
|
1743
1749
|
description: s.$td("settings.debugDescription", "Enable debugging with [Eruda](https://eruda.liriliri.io/).")
|
|
1744
1750
|
}, {
|
|
1745
|
-
default:
|
|
1746
|
-
|
|
1751
|
+
default: m(() => [
|
|
1752
|
+
d(Yr, {
|
|
1747
1753
|
modelValue: s.$errors.debug,
|
|
1748
1754
|
"onUpdate:modelValue": e[0] || (e[0] = (r) => s.$errors.debug = r),
|
|
1749
1755
|
"aria-labelledby": "debug-setting"
|
|
@@ -1752,85 +1758,78 @@ const $r = E({ name: "zondicons-cheveron-down", render: wr }), vt = /* @__PURE__
|
|
|
1752
1758
|
_: 1
|
|
1753
1759
|
}, 8, ["title", "description"]));
|
|
1754
1760
|
}
|
|
1755
|
-
}),
|
|
1761
|
+
}), en = [
|
|
1756
1762
|
{
|
|
1757
1763
|
priority: 10,
|
|
1758
|
-
component:
|
|
1764
|
+
component: Gr
|
|
1759
1765
|
}
|
|
1760
|
-
],
|
|
1761
|
-
function
|
|
1762
|
-
|
|
1766
|
+
], Et = [];
|
|
1767
|
+
function Pl(t) {
|
|
1768
|
+
Et.push(t);
|
|
1763
1769
|
}
|
|
1764
|
-
function
|
|
1765
|
-
for (const s of
|
|
1770
|
+
function Ht(t) {
|
|
1771
|
+
for (const s of Et) {
|
|
1766
1772
|
const e = s(t);
|
|
1767
1773
|
if (e)
|
|
1768
1774
|
return e;
|
|
1769
1775
|
}
|
|
1770
|
-
return typeof t == "string" ? t : t instanceof Error || t instanceof
|
|
1776
|
+
return typeof t == "string" ? t : t instanceof Error || t instanceof xe ? t.message : he(t) ? j(t.message ?? t.description ?? "Unknown error object") : S("errors.unknown", "Unknown Error");
|
|
1771
1777
|
}
|
|
1772
|
-
class
|
|
1778
|
+
class et extends xe {
|
|
1773
1779
|
}
|
|
1774
|
-
const
|
|
1775
|
-
function
|
|
1776
|
-
const e = (r) => s(r) ||
|
|
1777
|
-
t.config.errorHandler = e, globalThis.onerror = (r, n, a,
|
|
1780
|
+
const tn = { $errors: wt }, sn = (t) => (wt.report(t), !0);
|
|
1781
|
+
function rn(t, s = () => !1) {
|
|
1782
|
+
const e = (r) => s(r) || sn(r);
|
|
1783
|
+
t.config.errorHandler = e, globalThis.onerror = (r, n, a, u, i) => e(i ?? r), globalThis.onunhandledrejection = (r) => e(r.reason);
|
|
1778
1784
|
}
|
|
1779
|
-
const
|
|
1785
|
+
const nn = {
|
|
1780
1786
|
async install(t, s) {
|
|
1781
|
-
|
|
1787
|
+
rn(t, s.handleError), en.forEach((e) => P.addSetting(e)), await ke(t, tn);
|
|
1782
1788
|
}
|
|
1783
|
-
},
|
|
1789
|
+
}, an = {
|
|
1784
1790
|
async install() {
|
|
1785
|
-
|
|
1786
|
-
on: (...t) =>
|
|
1787
|
-
service: (t) =>
|
|
1791
|
+
ze() && (globalThis.testingRuntime = {
|
|
1792
|
+
on: (...t) => F.on(...t),
|
|
1793
|
+
service: (t) => P.service(t)
|
|
1788
1794
|
});
|
|
1789
1795
|
}
|
|
1790
|
-
},
|
|
1796
|
+
}, ln = {
|
|
1791
1797
|
viewBox: "0 0 20 20",
|
|
1792
1798
|
width: "1.2em",
|
|
1793
1799
|
height: "1.2em"
|
|
1794
1800
|
};
|
|
1795
|
-
function
|
|
1796
|
-
return
|
|
1797
|
-
|
|
1801
|
+
function on(t, s) {
|
|
1802
|
+
return o(), y("svg", ln, s[0] || (s[0] = [
|
|
1803
|
+
b("path", {
|
|
1798
1804
|
fill: "currentColor",
|
|
1799
1805
|
d: "M10 8.586L2.929 1.515L1.515 2.929L8.586 10l-7.071 7.071l1.414 1.414L10 11.414l7.071 7.071l1.414-1.414L11.414 10l7.071-7.071l-1.414-1.414z"
|
|
1800
1806
|
}, null, -1)
|
|
1801
1807
|
]));
|
|
1802
1808
|
}
|
|
1803
|
-
const
|
|
1809
|
+
const un = V({ name: "zondicons-close", render: on }), cn = /* @__PURE__ */ h({
|
|
1804
1810
|
__name: "HeadlessModal",
|
|
1805
1811
|
props: {
|
|
1806
1812
|
persistent: { type: Boolean },
|
|
1813
|
+
fullscreen: { type: Boolean },
|
|
1814
|
+
fullscreenMobile: { type: Boolean },
|
|
1807
1815
|
title: {},
|
|
1808
1816
|
titleHidden: { type: Boolean },
|
|
1809
1817
|
description: {},
|
|
1810
1818
|
descriptionHidden: { type: Boolean }
|
|
1811
1819
|
},
|
|
1812
1820
|
setup(t, { expose: s }) {
|
|
1813
|
-
const e =
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
)
|
|
1817
|
-
s({ close: i, $content: e });
|
|
1818
|
-
const { forwardRef: n } = Ve(), a = U(!1);
|
|
1819
|
-
le("$modalContentRef", e), tt("close-modal", async ({ id: o, result: d }) => {
|
|
1820
|
-
o === r.id && await i(d);
|
|
1821
|
-
});
|
|
1822
|
-
async function i(o) {
|
|
1823
|
-
a.value || (await R.emit("modal-will-close", { modal: r, result: o }), a.value = !0, await R.emit("modal-has-closed", { modal: r, result: o }));
|
|
1824
|
-
}
|
|
1825
|
-
return (o, d) => (u(), h(l(ws), {
|
|
1821
|
+
const e = N(null), { close: r } = Pe();
|
|
1822
|
+
s({ $content: e });
|
|
1823
|
+
const { forwardRef: n } = Re();
|
|
1824
|
+
return pe("$modalContentRef", e), (a, u) => (o(), f(l(Rs), {
|
|
1826
1825
|
ref: l(n),
|
|
1827
1826
|
open: "",
|
|
1828
|
-
"onUpdate:open":
|
|
1827
|
+
"onUpdate:open": u[0] || (u[0] = (i) => a.persistent || i || l(r)())
|
|
1829
1828
|
}, {
|
|
1830
|
-
default:
|
|
1831
|
-
|
|
1832
|
-
default:
|
|
1833
|
-
|
|
1829
|
+
default: m(() => [
|
|
1830
|
+
d(l(qs), null, {
|
|
1831
|
+
default: m(() => [
|
|
1832
|
+
$(a.$slots, "default", { close: l(r) })
|
|
1834
1833
|
]),
|
|
1835
1834
|
_: 3
|
|
1836
1835
|
})
|
|
@@ -1838,58 +1837,36 @@ const Nr = E({ name: "zondicons-close", render: Or }), Wr = /* @__PURE__ */ g({
|
|
|
1838
1837
|
_: 3
|
|
1839
1838
|
}, 512));
|
|
1840
1839
|
}
|
|
1841
|
-
}),
|
|
1842
|
-
__name: "ModalContext",
|
|
1843
|
-
props: {
|
|
1844
|
-
modal: {},
|
|
1845
|
-
childIndex: {}
|
|
1846
|
-
},
|
|
1847
|
-
setup(t) {
|
|
1848
|
-
const s = t, e = c(() => {
|
|
1849
|
-
const r = {};
|
|
1850
|
-
for (const n in s.modal.properties)
|
|
1851
|
-
r[n] = l(s.modal.properties[n]);
|
|
1852
|
-
return r;
|
|
1853
|
-
});
|
|
1854
|
-
return le("modal", {
|
|
1855
|
-
modal: Re(s, "modal"),
|
|
1856
|
-
childIndex: Re(s, "childIndex")
|
|
1857
|
-
}), (r, n) => (u(), h(W(r.modal.component), ne(ae(e.value)), null, 16));
|
|
1858
|
-
}
|
|
1859
|
-
}), Kr = /* @__PURE__ */ g({
|
|
1840
|
+
}), dn = /* @__PURE__ */ h({
|
|
1860
1841
|
__name: "HeadlessModalContent",
|
|
1861
1842
|
setup(t) {
|
|
1862
|
-
const {
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
default: f(() => [
|
|
1868
|
-
w(a.$slots, "default"),
|
|
1869
|
-
n.value ? (u(), h(wt, {
|
|
1843
|
+
const { child: s } = Pe(), e = lr("$modalContentRef"), r = te("$contentRef");
|
|
1844
|
+
return G(() => e.value = r.value), (n, a) => (o(), f(l(As), { ref: "$contentRef" }, {
|
|
1845
|
+
default: m(() => [
|
|
1846
|
+
$(n.$slots, "default"),
|
|
1847
|
+
l(s) ? (o(), f(l(bs), {
|
|
1870
1848
|
key: 0,
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
}, null, 8, ["child-index", "modal"])) : T("", !0)
|
|
1849
|
+
is: l(s)
|
|
1850
|
+
}, null, 8, ["is"])) : M("", !0)
|
|
1874
1851
|
]),
|
|
1875
1852
|
_: 3
|
|
1876
1853
|
}, 512));
|
|
1877
1854
|
}
|
|
1878
|
-
}),
|
|
1855
|
+
}), pn = /* @__PURE__ */ h({
|
|
1879
1856
|
__name: "HeadlessModalDescription",
|
|
1880
1857
|
props: {
|
|
1881
1858
|
asChild: { type: Boolean },
|
|
1882
1859
|
as: {}
|
|
1883
1860
|
},
|
|
1884
1861
|
setup(t) {
|
|
1885
|
-
return (s, e) => (
|
|
1886
|
-
default:
|
|
1887
|
-
|
|
1862
|
+
return (s, e) => (o(), f(l(Ps), ce(de(s.$props)), {
|
|
1863
|
+
default: m(() => [
|
|
1864
|
+
$(s.$slots, "default")
|
|
1888
1865
|
]),
|
|
1889
1866
|
_: 3
|
|
1890
1867
|
}, 16));
|
|
1891
1868
|
}
|
|
1892
|
-
}),
|
|
1869
|
+
}), mn = /* @__PURE__ */ h({
|
|
1893
1870
|
__name: "HeadlessModalOverlay",
|
|
1894
1871
|
props: {
|
|
1895
1872
|
forceMount: { type: Boolean },
|
|
@@ -1897,34 +1874,33 @@ const Nr = E({ name: "zondicons-close", render: Or }), Wr = /* @__PURE__ */ g({
|
|
|
1897
1874
|
as: {}
|
|
1898
1875
|
},
|
|
1899
1876
|
setup(t) {
|
|
1900
|
-
return (s, e) => (
|
|
1901
|
-
default:
|
|
1902
|
-
|
|
1877
|
+
return (s, e) => (o(), f(l(Ds), ce(de(s.$props)), {
|
|
1878
|
+
default: m(() => [
|
|
1879
|
+
$(s.$slots, "default")
|
|
1903
1880
|
]),
|
|
1904
1881
|
_: 3
|
|
1905
1882
|
}, 16));
|
|
1906
1883
|
}
|
|
1907
|
-
}),
|
|
1884
|
+
}), fn = /* @__PURE__ */ h({
|
|
1908
1885
|
__name: "HeadlessModalTitle",
|
|
1909
1886
|
props: {
|
|
1910
1887
|
asChild: { type: Boolean },
|
|
1911
1888
|
as: {}
|
|
1912
1889
|
},
|
|
1913
1890
|
setup(t) {
|
|
1914
|
-
return (s, e) => (
|
|
1915
|
-
default:
|
|
1916
|
-
|
|
1891
|
+
return (s, e) => (o(), f(l(Bs), ce(de(s.$props)), {
|
|
1892
|
+
default: m(() => [
|
|
1893
|
+
$(s.$slots, "default")
|
|
1917
1894
|
]),
|
|
1918
1895
|
_: 3
|
|
1919
1896
|
}, 16));
|
|
1920
1897
|
}
|
|
1921
|
-
}),
|
|
1922
|
-
key: 0,
|
|
1923
|
-
class: "absolute top-0 right-0 hidden pt-3.5 pr-2.5 sm:block"
|
|
1924
|
-
}, Yr = ["onClick"], Gr = { class: "sr-only" }, se = /* @__PURE__ */ g({
|
|
1898
|
+
}), hn = ["onClick"], gn = { class: "sr-only" }, fe = mr(), ne = /* @__PURE__ */ h({
|
|
1925
1899
|
__name: "Modal",
|
|
1926
1900
|
props: {
|
|
1927
1901
|
persistent: { type: Boolean },
|
|
1902
|
+
fullscreen: { type: Boolean },
|
|
1903
|
+
fullscreenMobile: { type: Boolean },
|
|
1928
1904
|
title: {},
|
|
1929
1905
|
titleHidden: { type: Boolean },
|
|
1930
1906
|
description: {},
|
|
@@ -1934,117 +1910,132 @@ const Nr = E({ name: "zondicons-close", render: Or }), Wr = /* @__PURE__ */ g({
|
|
|
1934
1910
|
closeHidden: { type: Boolean }
|
|
1935
1911
|
},
|
|
1936
1912
|
setup(t, { expose: s }) {
|
|
1937
|
-
const e =
|
|
1913
|
+
const e = K(t, ["class", "wrapperClass", "title", "titleHidden", "description", "persistent", "closeHidden", "fullscreen", "fullscreenMobile"]);
|
|
1938
1914
|
s({
|
|
1939
|
-
close: async (m) => {
|
|
1940
|
-
var C;
|
|
1941
|
-
return (C = a.value) == null ? void 0 : C.close(m);
|
|
1942
|
-
},
|
|
1943
1915
|
$content: c(() => {
|
|
1944
|
-
var
|
|
1945
|
-
return (
|
|
1916
|
+
var T;
|
|
1917
|
+
return (T = i.value) == null ? void 0 : T.$content;
|
|
1946
1918
|
})
|
|
1947
1919
|
});
|
|
1948
|
-
const { forwardRef: r, currentRef: n } =
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
|
|
1955
|
-
|
|
1956
|
-
|
|
1920
|
+
const { forwardRef: r, currentRef: n } = Re(), { id: a, visible: u } = Pe(), i = n, p = ut(), g = c(
|
|
1921
|
+
() => {
|
|
1922
|
+
var T;
|
|
1923
|
+
return u.value && ((T = le.value.toReversed().find((je) => je.visible.value)) == null ? void 0 : T.id) === a.value;
|
|
1924
|
+
}
|
|
1925
|
+
), w = c(() => le.value.find((T) => T.visible.value)), v = c(() => le.value.some((T) => fe.has(T))), k = c(() => t.description ? {} : { "aria-describedby": void 0 }), q = c(() => E(
|
|
1926
|
+
"overflow-auto px-4 pb-4 flex flex-col flex-1",
|
|
1927
|
+
{ "pt-4": !t.title || t.titleHidden, "max-h-[90vh]": !Q.value },
|
|
1928
|
+
t.class
|
|
1929
|
+
)), Q = c(() => t.fullscreen || t.fullscreenMobile && A.mobile), qt = c(() => E(
|
|
1930
|
+
"isolate fixed z-50 flex flex-col overflow-hidden bg-white text-left duration-300",
|
|
1931
|
+
Q.value ? [
|
|
1932
|
+
"inset-0 transition-[transform,translate] will-change-[transform,translate]",
|
|
1933
|
+
fe.has(p.value) || "animate-[slide-in_var(--tw-duration)_ease-in-out]",
|
|
1934
|
+
g.value ? "translate-y-0" : "translate-y-full"
|
|
1935
|
+
] : [
|
|
1936
|
+
"top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 w-full",
|
|
1937
|
+
"max-w-[calc(100%-2rem)] rounded-lg shadow-xl sm:max-w-lg",
|
|
1938
|
+
"transition-[scale,opacity] will-change-[scale,opacity]",
|
|
1939
|
+
fe.has(p.value) || "animate-[fade-in_var(--tw-duration)_ease-in-out,grow_var(--tw-duration)_ease-in-out]",
|
|
1940
|
+
g.value ? "scale-100 opacity-100" : "scale-50 opacity-0"
|
|
1941
|
+
],
|
|
1957
1942
|
t.wrapperClass
|
|
1958
1943
|
));
|
|
1959
|
-
return
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
ref: (L) => l(r)(L),
|
|
1963
|
-
persistent: m.persistent
|
|
1944
|
+
return st(() => oe(500).then(() => fe.add(p.value))), (T, je) => (o(), f(cn, H(e, {
|
|
1945
|
+
ref: (me) => l(r)(me),
|
|
1946
|
+
persistent: T.persistent
|
|
1964
1947
|
}), {
|
|
1965
|
-
default:
|
|
1966
|
-
|
|
1967
|
-
|
|
1968
|
-
|
|
1969
|
-
"
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1948
|
+
default: m(({ close: me }) => {
|
|
1949
|
+
var Fe, Ue;
|
|
1950
|
+
return [
|
|
1951
|
+
d(mn, {
|
|
1952
|
+
class: C(["fixed inset-0 transition-opacity duration-300 will-change-[opacity]", {
|
|
1953
|
+
"animate-[fade-in_var(--tw-duration)_ease-in-out]": !v.value,
|
|
1954
|
+
"bg-black/30": ((Fe = w.value) == null ? void 0 : Fe.id) === l(a) || !w.value && ((Ue = l(le)[0]) == null ? void 0 : Ue.id) === l(a),
|
|
1955
|
+
"opacity-0": !w.value,
|
|
1956
|
+
hidden: Q.value
|
|
1957
|
+
}])
|
|
1958
|
+
}, null, 8, ["class"]),
|
|
1959
|
+
d(dn, H(k.value, { class: qt.value }), {
|
|
1960
|
+
default: m(() => [
|
|
1961
|
+
!T.persistent && !T.closeHidden ? (o(), y("div", {
|
|
1962
|
+
key: 0,
|
|
1963
|
+
class: C(["absolute top-0 right-0 pt-3.5 pr-2.5", { "hidden sm:block": !Q.value }])
|
|
1979
1964
|
}, [
|
|
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
|
-
|
|
1965
|
+
b("button", {
|
|
1966
|
+
type: "button",
|
|
1967
|
+
class: "clickable z-10 rounded-full p-2.5 text-gray-400 hover:text-gray-500",
|
|
1968
|
+
onClick: (cl) => me()
|
|
1969
|
+
}, [
|
|
1970
|
+
b("span", gn, x(T.$td("ui.close", "Close")), 1),
|
|
1971
|
+
d(l(un), { class: "size-4" })
|
|
1972
|
+
], 8, hn)
|
|
1973
|
+
], 2)) : M("", !0),
|
|
1974
|
+
T.title ? (o(), f(fn, {
|
|
1975
|
+
key: 1,
|
|
1976
|
+
class: C(["px-4 pt-5 text-base font-semibold text-gray-900", {
|
|
1977
|
+
"sr-only": T.titleHidden,
|
|
1978
|
+
"pb-0": T.description && !T.descriptionHidden,
|
|
1979
|
+
"pb-2": !T.description || T.descriptionHidden
|
|
1980
|
+
}])
|
|
1981
|
+
}, {
|
|
1982
|
+
default: m(() => [
|
|
1983
|
+
d(z, {
|
|
1984
|
+
text: T.title,
|
|
1985
|
+
inline: ""
|
|
1986
|
+
}, null, 8, ["text"])
|
|
1987
|
+
]),
|
|
1988
|
+
_: 1
|
|
1989
|
+
}, 8, ["class"])) : M("", !0),
|
|
1990
|
+
T.description ? (o(), f(pn, {
|
|
1991
|
+
key: 2,
|
|
1992
|
+
class: C(["px-4 pt-1 pb-2", { "sr-only": T.descriptionHidden }])
|
|
1993
|
+
}, {
|
|
1994
|
+
default: m(() => [
|
|
1995
|
+
d(z, {
|
|
1996
|
+
text: T.description,
|
|
1997
|
+
class: "text-sm leading-6 text-gray-500"
|
|
1998
|
+
}, null, 8, ["text"])
|
|
1999
|
+
]),
|
|
2000
|
+
_: 1
|
|
2001
|
+
}, 8, ["class"])) : M("", !0),
|
|
2002
|
+
b("div", {
|
|
2003
|
+
class: C(q.value)
|
|
2004
|
+
}, [
|
|
2005
|
+
$(T.$slots, "default", { close: me })
|
|
2006
|
+
], 2)
|
|
2007
|
+
]),
|
|
2008
|
+
_: 2
|
|
2009
|
+
}, 1040, ["class"])
|
|
2010
|
+
];
|
|
2011
|
+
}),
|
|
2021
2012
|
_: 3
|
|
2022
2013
|
}, 16, ["persistent"]));
|
|
2023
2014
|
}
|
|
2024
2015
|
});
|
|
2025
|
-
function
|
|
2016
|
+
function vn(t) {
|
|
2026
2017
|
const s = c(() => t.title ?? S("ui.alert", "Alert")), e = c(() => !t.title);
|
|
2027
2018
|
return { renderedTitle: s, titleHidden: e };
|
|
2028
2019
|
}
|
|
2029
|
-
const
|
|
2020
|
+
const bn = /* @__PURE__ */ h({
|
|
2030
2021
|
__name: "AlertModal",
|
|
2031
2022
|
props: {
|
|
2032
2023
|
title: {},
|
|
2033
2024
|
message: {}
|
|
2034
2025
|
},
|
|
2035
2026
|
setup(t, { expose: s }) {
|
|
2036
|
-
const e = t, { renderedTitle: r, titleHidden: n } =
|
|
2037
|
-
return s(), (a,
|
|
2027
|
+
const e = t, { renderedTitle: r, titleHidden: n } = vn(e);
|
|
2028
|
+
return s(), (a, u) => (o(), f(ne, {
|
|
2038
2029
|
title: l(r),
|
|
2039
2030
|
"title-hidden": l(n)
|
|
2040
2031
|
}, {
|
|
2041
|
-
default:
|
|
2042
|
-
|
|
2032
|
+
default: m(() => [
|
|
2033
|
+
d(z, { text: a.message }, null, 8, ["text"])
|
|
2043
2034
|
]),
|
|
2044
2035
|
_: 1
|
|
2045
2036
|
}, 8, ["title", "title-hidden"]));
|
|
2046
2037
|
}
|
|
2047
|
-
}),
|
|
2038
|
+
}), Vt = /* @__PURE__ */ h({
|
|
2048
2039
|
__name: "Form",
|
|
2049
2040
|
props: {
|
|
2050
2041
|
form: {}
|
|
@@ -2053,36 +2044,36 @@ const tn = /* @__PURE__ */ g({
|
|
|
2053
2044
|
setup(t, { emit: s }) {
|
|
2054
2045
|
let e;
|
|
2055
2046
|
const r = s;
|
|
2056
|
-
return
|
|
2047
|
+
return G((n) => {
|
|
2057
2048
|
var a;
|
|
2058
2049
|
e == null || e(), e = (a = t.form) == null ? void 0 : a.on("submit", () => r("submit")), n(() => e == null ? void 0 : e());
|
|
2059
|
-
}),
|
|
2060
|
-
onSubmit: a[0] || (a[0] =
|
|
2050
|
+
}), pe("form", t.form), (n, a) => (o(), y("form", {
|
|
2051
|
+
onSubmit: a[0] || (a[0] = rt((u) => n.form ? n.form.submit() : n.$emit("submit"), ["prevent"]))
|
|
2061
2052
|
}, [
|
|
2062
|
-
|
|
2053
|
+
$(n.$slots, "default")
|
|
2063
2054
|
], 32));
|
|
2064
2055
|
}
|
|
2065
2056
|
});
|
|
2066
|
-
function
|
|
2067
|
-
const s =
|
|
2057
|
+
function yn(t) {
|
|
2058
|
+
const s = ft(
|
|
2068
2059
|
Object.entries(t.checkboxes ?? {}).reduce(
|
|
2069
|
-
(
|
|
2070
|
-
[
|
|
2060
|
+
(u, [i, p]) => ({
|
|
2061
|
+
[i]: {
|
|
2071
2062
|
type: "boolean",
|
|
2072
|
-
default:
|
|
2073
|
-
required:
|
|
2063
|
+
default: p.default,
|
|
2064
|
+
required: p.required ? "required" : void 0
|
|
2074
2065
|
},
|
|
2075
|
-
...
|
|
2066
|
+
...u
|
|
2076
2067
|
}),
|
|
2077
2068
|
{}
|
|
2078
2069
|
)
|
|
2079
2070
|
), e = c(() => t.title ?? S("ui.confirm", "Confirm")), r = c(() => !t.title), n = c(() => t.acceptText ?? S("ui.accept", "Ok")), a = c(() => t.cancelText ?? S("ui.cancel", "Cancel"));
|
|
2080
2071
|
return { form: s, renderedTitle: e, titleHidden: r, renderedAcceptText: n, renderedCancelText: a };
|
|
2081
2072
|
}
|
|
2082
|
-
const
|
|
2073
|
+
const wn = {
|
|
2083
2074
|
key: 0,
|
|
2084
2075
|
class: "mt-4 flex flex-col text-sm text-gray-600"
|
|
2085
|
-
},
|
|
2076
|
+
}, $n = { class: "flex items-center" }, _n = ["onUpdate:modelValue", "required"], xn = { class: "ml-1.5" }, Cn = { class: "mt-4 flex flex-row-reverse gap-2" }, Sn = /* @__PURE__ */ h({
|
|
2086
2077
|
__name: "ConfirmModal",
|
|
2087
2078
|
props: {
|
|
2088
2079
|
title: {},
|
|
@@ -2095,55 +2086,56 @@ const rn = {
|
|
|
2095
2086
|
actions: {},
|
|
2096
2087
|
required: { type: Boolean }
|
|
2097
2088
|
},
|
|
2089
|
+
emits: ["close"],
|
|
2098
2090
|
setup(t, { expose: s }) {
|
|
2099
|
-
const e =
|
|
2100
|
-
return s(), (
|
|
2091
|
+
const e = K(t, ["cancelVariant"]), { form: r, renderedTitle: n, titleHidden: a, renderedAcceptText: u, renderedCancelText: i } = yn(e);
|
|
2092
|
+
return s(), (p, g) => (o(), f(ne, {
|
|
2101
2093
|
title: l(n),
|
|
2102
2094
|
"title-hidden": l(a),
|
|
2103
2095
|
persistent: ""
|
|
2104
2096
|
}, {
|
|
2105
|
-
default:
|
|
2106
|
-
|
|
2097
|
+
default: m(({ close: w }) => [
|
|
2098
|
+
d(Vt, {
|
|
2107
2099
|
form: l(r),
|
|
2108
|
-
onSubmit: (
|
|
2100
|
+
onSubmit: (v) => w([!0, l(r).data()])
|
|
2109
2101
|
}, {
|
|
2110
|
-
default:
|
|
2111
|
-
|
|
2112
|
-
text:
|
|
2113
|
-
actions:
|
|
2102
|
+
default: m(() => [
|
|
2103
|
+
d(z, {
|
|
2104
|
+
text: p.message,
|
|
2105
|
+
actions: p.actions
|
|
2114
2106
|
}, null, 8, ["text", "actions"]),
|
|
2115
|
-
|
|
2116
|
-
(
|
|
2117
|
-
|
|
2118
|
-
|
|
2119
|
-
"onUpdate:modelValue": (
|
|
2107
|
+
p.checkboxes ? (o(), y("ul", wn, [
|
|
2108
|
+
(o(!0), y(D, null, U(p.checkboxes, (v, k) => (o(), y("li", { key: k }, [
|
|
2109
|
+
b("label", $n, [
|
|
2110
|
+
nt(b("input", {
|
|
2111
|
+
"onUpdate:modelValue": (q) => l(r)[k] = q,
|
|
2120
2112
|
type: "checkbox",
|
|
2121
|
-
required:
|
|
2113
|
+
required: v.required,
|
|
2122
2114
|
class: "border-primary-600 text-primary-600 hover:bg-primary-50 hover:checked:bg-primary-500 focus:ring-primary-600 focus-visible:ring-primary-600 rounded border-2"
|
|
2123
|
-
}, null, 8,
|
|
2124
|
-
[
|
|
2115
|
+
}, null, 8, _n), [
|
|
2116
|
+
[Wt, l(r)[k]]
|
|
2125
2117
|
]),
|
|
2126
|
-
|
|
2118
|
+
b("span", xn, x(v.label), 1)
|
|
2127
2119
|
])
|
|
2128
2120
|
]))), 128))
|
|
2129
|
-
])) :
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
variant:
|
|
2121
|
+
])) : M("", !0),
|
|
2122
|
+
b("div", Cn, [
|
|
2123
|
+
d(I, {
|
|
2124
|
+
variant: p.acceptVariant,
|
|
2133
2125
|
submit: ""
|
|
2134
2126
|
}, {
|
|
2135
|
-
default:
|
|
2136
|
-
|
|
2127
|
+
default: m(() => [
|
|
2128
|
+
L(x(l(u)), 1)
|
|
2137
2129
|
]),
|
|
2138
2130
|
_: 1
|
|
2139
2131
|
}, 8, ["variant"]),
|
|
2140
|
-
|
|
2132
|
+
p.required ? M("", !0) : (o(), f(I, {
|
|
2141
2133
|
key: 0,
|
|
2142
|
-
variant:
|
|
2143
|
-
onClick: (
|
|
2134
|
+
variant: p.cancelVariant,
|
|
2135
|
+
onClick: (v) => w(!1)
|
|
2144
2136
|
}, {
|
|
2145
|
-
default:
|
|
2146
|
-
|
|
2137
|
+
default: m(() => [
|
|
2138
|
+
L(x(l(i)), 1)
|
|
2147
2139
|
]),
|
|
2148
2140
|
_: 2
|
|
2149
2141
|
}, 1032, ["variant", "onClick"]))
|
|
@@ -2155,127 +2147,127 @@ const rn = {
|
|
|
2155
2147
|
_: 1
|
|
2156
2148
|
}, 8, ["title", "title-hidden"]));
|
|
2157
2149
|
}
|
|
2158
|
-
}),
|
|
2150
|
+
}), kn = {
|
|
2159
2151
|
viewBox: "0 0 20 20",
|
|
2160
2152
|
width: "1.2em",
|
|
2161
2153
|
height: "1.2em"
|
|
2162
2154
|
};
|
|
2163
|
-
function
|
|
2164
|
-
return
|
|
2165
|
-
|
|
2155
|
+
function Tn(t, s) {
|
|
2156
|
+
return o(), y("svg", kn, s[0] || (s[0] = [
|
|
2157
|
+
b("path", {
|
|
2166
2158
|
fill: "currentColor",
|
|
2167
2159
|
d: "M7.05 9.293L6.343 10L12 15.657l1.414-1.414L9.172 10l4.242-4.243L12 4.343z"
|
|
2168
2160
|
}, null, -1)
|
|
2169
2161
|
]));
|
|
2170
2162
|
}
|
|
2171
|
-
const
|
|
2163
|
+
const Mn = V({ name: "zondicons-cheveron-left", render: Tn }), En = {
|
|
2172
2164
|
viewBox: "0 0 20 20",
|
|
2173
2165
|
width: "1.2em",
|
|
2174
2166
|
height: "1.2em"
|
|
2175
2167
|
};
|
|
2176
|
-
function
|
|
2177
|
-
return
|
|
2178
|
-
|
|
2168
|
+
function Hn(t, s) {
|
|
2169
|
+
return o(), y("svg", En, s[0] || (s[0] = [
|
|
2170
|
+
b("path", {
|
|
2179
2171
|
fill: "currentColor",
|
|
2180
2172
|
d: "m12.95 10.707l.707-.707L8 4.343L6.586 5.757L10.828 10l-4.242 4.243L8 15.657z"
|
|
2181
2173
|
}, null, -1)
|
|
2182
2174
|
]));
|
|
2183
2175
|
}
|
|
2184
|
-
const
|
|
2176
|
+
const Lt = V({ name: "zondicons-cheveron-right", render: Hn }), Vn = {
|
|
2185
2177
|
viewBox: "0 0 20 20",
|
|
2186
2178
|
width: "1.2em",
|
|
2187
2179
|
height: "1.2em"
|
|
2188
2180
|
};
|
|
2189
|
-
function
|
|
2190
|
-
return
|
|
2191
|
-
|
|
2181
|
+
function Ln(t, s) {
|
|
2182
|
+
return o(), y("svg", Vn, s[0] || (s[0] = [
|
|
2183
|
+
b("path", {
|
|
2192
2184
|
fill: "currentColor",
|
|
2193
2185
|
d: "M2.93 17.07A10 10 0 1 1 17.07 2.93A10 10 0 0 1 2.93 17.07M9 5v6h2V5zm0 8v2h2v-2z"
|
|
2194
2186
|
}, null, -1)
|
|
2195
2187
|
]));
|
|
2196
2188
|
}
|
|
2197
|
-
const
|
|
2189
|
+
const De = V({ name: "zondicons-exclamation-solid", render: Ln }), In = {
|
|
2198
2190
|
viewBox: "0 0 24 24",
|
|
2199
2191
|
width: "1.2em",
|
|
2200
2192
|
height: "1.2em"
|
|
2201
2193
|
};
|
|
2202
|
-
function
|
|
2203
|
-
return
|
|
2204
|
-
|
|
2194
|
+
function zn(t, s) {
|
|
2195
|
+
return o(), y("svg", In, s[0] || (s[0] = [
|
|
2196
|
+
b("path", {
|
|
2205
2197
|
fill: "currentColor",
|
|
2206
2198
|
d: "M20 19V7H4v12zm0-16a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2zm-7 14v-2h5v2zm-3.42-4L5.57 9H8.4l3.3 3.3c.39.39.39 1.03 0 1.42L8.42 17H5.59z"
|
|
2207
2199
|
}, null, -1)
|
|
2208
2200
|
]));
|
|
2209
2201
|
}
|
|
2210
|
-
const
|
|
2202
|
+
const Rn = V({ name: "mdi-console", render: zn }), qn = {
|
|
2211
2203
|
viewBox: "0 0 20 20",
|
|
2212
2204
|
width: "1.2em",
|
|
2213
2205
|
height: "1.2em"
|
|
2214
2206
|
};
|
|
2215
|
-
function
|
|
2216
|
-
return
|
|
2217
|
-
|
|
2207
|
+
function An(t, s) {
|
|
2208
|
+
return o(), y("svg", qn, s[0] || (s[0] = [
|
|
2209
|
+
b("path", {
|
|
2218
2210
|
fill: "currentColor",
|
|
2219
2211
|
d: "M6 6V2c0-1.1.9-2 2-2h10a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2h-4v4a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V8c0-1.1.9-2 2-2zm2 0h4a2 2 0 0 1 2 2v4h4V2H8zM2 8v10h10V8z"
|
|
2220
2212
|
}, null, -1)
|
|
2221
2213
|
]));
|
|
2222
2214
|
}
|
|
2223
|
-
const
|
|
2215
|
+
const Pn = V({ name: "zondicons-copy", render: An }), Dn = {
|
|
2224
2216
|
viewBox: "0 0 24 24",
|
|
2225
2217
|
width: "1.2em",
|
|
2226
2218
|
height: "1.2em"
|
|
2227
2219
|
};
|
|
2228
|
-
function
|
|
2229
|
-
return
|
|
2230
|
-
|
|
2220
|
+
function Bn(t, s) {
|
|
2221
|
+
return o(), y("svg", Dn, s[0] || (s[0] = [
|
|
2222
|
+
b("path", {
|
|
2231
2223
|
fill: "currentColor",
|
|
2232
2224
|
d: "M12 2A10 10 0 0 0 2 12c0 4.42 2.87 8.17 6.84 9.5c.5.08.66-.23.66-.5v-1.69c-2.77.6-3.36-1.34-3.36-1.34c-.46-1.16-1.11-1.47-1.11-1.47c-.91-.62.07-.6.07-.6c1 .07 1.53 1.03 1.53 1.03c.87 1.52 2.34 1.07 2.91.83c.09-.65.35-1.09.63-1.34c-2.22-.25-4.55-1.11-4.55-4.92c0-1.11.38-2 1.03-2.71c-.1-.25-.45-1.29.1-2.64c0 0 .84-.27 2.75 1.02c.79-.22 1.65-.33 2.5-.33s1.71.11 2.5.33c1.91-1.29 2.75-1.02 2.75-1.02c.55 1.35.2 2.39.1 2.64c.65.71 1.03 1.6 1.03 2.71c0 3.82-2.34 4.66-4.57 4.91c.36.31.69.92.69 1.85V21c0 .27.16.59.67.5C19.14 20.16 22 16.42 22 12A10 10 0 0 0 12 2"
|
|
2233
2225
|
}, null, -1)
|
|
2234
2226
|
]));
|
|
2235
2227
|
}
|
|
2236
|
-
const
|
|
2228
|
+
const jn = V({ name: "mdi-github", render: Bn }), Fn = { class: "flex" }, Un = { class: "sr-only" }, On = /* @__PURE__ */ h({
|
|
2237
2229
|
__name: "ErrorReportModalButtons",
|
|
2238
2230
|
props: {
|
|
2239
2231
|
report: {}
|
|
2240
2232
|
},
|
|
2241
2233
|
setup(t) {
|
|
2242
2234
|
const s = t, e = c(() => s.report.description ? `${s.report.title}: ${s.report.description}` : s.report.title), r = c(() => {
|
|
2243
|
-
if (!
|
|
2235
|
+
if (!P.sourceUrl)
|
|
2244
2236
|
return !1;
|
|
2245
|
-
const a = encodeURIComponent(e.value),
|
|
2237
|
+
const a = encodeURIComponent(e.value), u = encodeURIComponent(
|
|
2246
2238
|
[
|
|
2247
2239
|
"[Please, explain here what you were trying to do when this error appeared]",
|
|
2248
2240
|
"",
|
|
2249
2241
|
"Error details:",
|
|
2250
2242
|
"```",
|
|
2251
|
-
|
|
2243
|
+
ls(
|
|
2252
2244
|
s.report.details ?? "Details missing from report",
|
|
2253
|
-
1800 - a.length -
|
|
2245
|
+
1800 - a.length - P.sourceUrl.length
|
|
2254
2246
|
).trim(),
|
|
2255
2247
|
"```"
|
|
2256
2248
|
].join(`
|
|
2257
2249
|
`)
|
|
2258
2250
|
);
|
|
2259
|
-
return `${
|
|
2260
|
-
}), n = c(() =>
|
|
2251
|
+
return `${P.sourceUrl}/issues/new?title=${a}&body=${u}`;
|
|
2252
|
+
}), n = c(() => se(
|
|
2261
2253
|
[
|
|
2262
2254
|
{
|
|
2263
2255
|
id: "clipboard",
|
|
2264
2256
|
description: "Copy to clipboard",
|
|
2265
|
-
iconComponent:
|
|
2257
|
+
iconComponent: Pn,
|
|
2266
2258
|
async click() {
|
|
2267
2259
|
await navigator.clipboard.writeText(`${e.value}
|
|
2268
2260
|
|
|
2269
|
-
${s.report.details}`),
|
|
2261
|
+
${s.report.details}`), A.toast(S("errors.copiedToClipboard", "Debug information copied to clipboard"));
|
|
2270
2262
|
}
|
|
2271
2263
|
},
|
|
2272
2264
|
{
|
|
2273
2265
|
id: "console",
|
|
2274
2266
|
description: "Log to console",
|
|
2275
|
-
iconComponent:
|
|
2267
|
+
iconComponent: Rn,
|
|
2276
2268
|
click() {
|
|
2277
2269
|
const a = s.report.error ?? s.report;
|
|
2278
|
-
window.error = a, console.error(a),
|
|
2270
|
+
window.error = a, console.error(a), A.toast(
|
|
2279
2271
|
S(
|
|
2280
2272
|
"errors.addedToConsole",
|
|
2281
2273
|
"You can now use the **error** variable in the console"
|
|
@@ -2288,24 +2280,24 @@ ${s.report.details}`), z.toast(S("errors.copiedToClipboard", "Debug information
|
|
|
2288
2280
|
r.value && a.push({
|
|
2289
2281
|
id: "github",
|
|
2290
2282
|
description: "Report in GitHub",
|
|
2291
|
-
iconComponent:
|
|
2283
|
+
iconComponent: jn,
|
|
2292
2284
|
url: r.value
|
|
2293
2285
|
});
|
|
2294
2286
|
}
|
|
2295
2287
|
));
|
|
2296
|
-
return (a,
|
|
2297
|
-
(
|
|
2298
|
-
|
|
2288
|
+
return (a, u) => (o(), y("div", Fn, [
|
|
2289
|
+
(o(!0), y(D, null, U(n.value, (i) => $(a.$slots, "default", H({ ref_for: !0 }, i), () => [
|
|
2290
|
+
d(I, {
|
|
2299
2291
|
size: "icon",
|
|
2300
2292
|
variant: "ghost",
|
|
2301
2293
|
class: "group whitespace-nowrap",
|
|
2302
|
-
href:
|
|
2303
|
-
title: a.$td(`errors.report_${
|
|
2304
|
-
onClick:
|
|
2294
|
+
href: i.url,
|
|
2295
|
+
title: a.$td(`errors.report_${i.id}`, i.description),
|
|
2296
|
+
onClick: i.click
|
|
2305
2297
|
}, {
|
|
2306
|
-
default:
|
|
2307
|
-
|
|
2308
|
-
(
|
|
2298
|
+
default: m(() => [
|
|
2299
|
+
b("span", Un, x(a.$td(`errors.report_${i.id}`, i.description)), 1),
|
|
2300
|
+
(o(), f(ee(i.iconComponent), {
|
|
2309
2301
|
class: "size-4",
|
|
2310
2302
|
"aria-hidden": "true"
|
|
2311
2303
|
}))
|
|
@@ -2315,7 +2307,7 @@ ${s.report.details}`), z.toast(S("errors.copiedToClipboard", "Debug information
|
|
|
2315
2307
|
])), 256))
|
|
2316
2308
|
]));
|
|
2317
2309
|
}
|
|
2318
|
-
}),
|
|
2310
|
+
}), Nn = /* @__PURE__ */ h({
|
|
2319
2311
|
__name: "ErrorReportModalTitle",
|
|
2320
2312
|
props: {
|
|
2321
2313
|
report: {},
|
|
@@ -2324,17 +2316,17 @@ ${s.report.details}`), z.toast(S("errors.copiedToClipboard", "Debug information
|
|
|
2324
2316
|
},
|
|
2325
2317
|
setup(t) {
|
|
2326
2318
|
const s = c(() => !t.totalReports || t.totalReports <= 1 ? t.report.title : `${t.report.title} (${t.currentReport}/${t.totalReports})`);
|
|
2327
|
-
return (e, r) => (
|
|
2319
|
+
return (e, r) => (o(), f(z, {
|
|
2328
2320
|
text: s.value,
|
|
2329
2321
|
inline: ""
|
|
2330
2322
|
}, null, 8, ["text"]));
|
|
2331
2323
|
}
|
|
2332
2324
|
});
|
|
2333
|
-
function
|
|
2334
|
-
const s =
|
|
2325
|
+
function Wn(t) {
|
|
2326
|
+
const s = N(t.reports.includes(t.report) ? t.reports.indexOf(t.report) : 0), e = c(() => t.reports[s.value]), r = c(
|
|
2335
2327
|
() => {
|
|
2336
|
-
var
|
|
2337
|
-
return ((
|
|
2328
|
+
var u;
|
|
2329
|
+
return ((u = e.value.details) == null ? void 0 : u.trim()) || S("errors.detailsEmpty", "This error is missing a stacktrace.");
|
|
2338
2330
|
}
|
|
2339
2331
|
), n = S("errors.previousReport", "Show previous report"), a = S("errors.nextReport", "Show next report");
|
|
2340
2332
|
return {
|
|
@@ -2345,102 +2337,102 @@ function En(t) {
|
|
|
2345
2337
|
activeReport: e
|
|
2346
2338
|
};
|
|
2347
2339
|
}
|
|
2348
|
-
const
|
|
2340
|
+
const Kn = { class: "px-4 pt-5 pb-4" }, Qn = { class: "flex justify-between gap-4" }, Jn = { class: "flex items-center gap-2" }, Zn = {
|
|
2349
2341
|
key: 0,
|
|
2350
2342
|
class: "flex gap-0.5"
|
|
2351
|
-
},
|
|
2343
|
+
}, Xn = { class: "-mt-2 max-h-[75vh] overflow-auto bg-red-800/10" }, Yn = ["textContent"], Gn = /* @__PURE__ */ h({
|
|
2352
2344
|
__name: "ErrorReportModal",
|
|
2353
2345
|
props: {
|
|
2354
2346
|
report: {},
|
|
2355
2347
|
reports: {}
|
|
2356
2348
|
},
|
|
2357
2349
|
setup(t, { expose: s }) {
|
|
2358
|
-
const e = t, { activeReportIndex: r, details: n, nextReportText: a, previousReportText:
|
|
2359
|
-
return s(), (
|
|
2360
|
-
title:
|
|
2350
|
+
const e = t, { activeReportIndex: r, details: n, nextReportText: a, previousReportText: u, activeReport: i } = Wn(e);
|
|
2351
|
+
return s(), (p, g) => (o(), f(ne, {
|
|
2352
|
+
title: p.$td("errors.report", "Error report"),
|
|
2361
2353
|
"title-hidden": "",
|
|
2362
2354
|
"close-hidden": "",
|
|
2363
2355
|
class: "p-0",
|
|
2364
2356
|
"wrapper-class": "sm:w-auto sm:min-w-lg sm:max-w-[80vw]"
|
|
2365
2357
|
}, {
|
|
2366
|
-
default:
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
|
|
2370
|
-
|
|
2371
|
-
|
|
2358
|
+
default: m(() => [
|
|
2359
|
+
b("div", Kn, [
|
|
2360
|
+
b("h2", Qn, [
|
|
2361
|
+
b("div", Jn, [
|
|
2362
|
+
d(l(De), { class: "size-5 text-red-600" }),
|
|
2363
|
+
d(Nn, {
|
|
2372
2364
|
class: "text-lg leading-6 font-semibold text-gray-900",
|
|
2373
|
-
report: l(
|
|
2365
|
+
report: l(i),
|
|
2374
2366
|
"current-report": l(r) + 1,
|
|
2375
|
-
"total-reports":
|
|
2367
|
+
"total-reports": p.reports.length
|
|
2376
2368
|
}, null, 8, ["report", "current-report", "total-reports"]),
|
|
2377
|
-
|
|
2378
|
-
|
|
2369
|
+
p.reports.length > 1 ? (o(), y("span", Zn, [
|
|
2370
|
+
d(I, {
|
|
2379
2371
|
size: "icon",
|
|
2380
2372
|
variant: "ghost",
|
|
2381
2373
|
disabled: l(r) === 0,
|
|
2382
|
-
"aria-label": l(
|
|
2383
|
-
title: l(
|
|
2384
|
-
onClick:
|
|
2374
|
+
"aria-label": l(u),
|
|
2375
|
+
title: l(u),
|
|
2376
|
+
onClick: g[0] || (g[0] = (w) => r.value--)
|
|
2385
2377
|
}, {
|
|
2386
|
-
default:
|
|
2387
|
-
|
|
2378
|
+
default: m(() => [
|
|
2379
|
+
d(l(Mn), { class: "size-4" })
|
|
2388
2380
|
]),
|
|
2389
2381
|
_: 1
|
|
2390
2382
|
}, 8, ["disabled", "aria-label", "title"]),
|
|
2391
|
-
|
|
2383
|
+
d(I, {
|
|
2392
2384
|
size: "icon",
|
|
2393
2385
|
variant: "ghost",
|
|
2394
|
-
disabled: l(r) ===
|
|
2386
|
+
disabled: l(r) === p.reports.length - 1,
|
|
2395
2387
|
"aria-label": l(a),
|
|
2396
2388
|
title: l(a),
|
|
2397
|
-
onClick:
|
|
2389
|
+
onClick: g[1] || (g[1] = (w) => r.value++)
|
|
2398
2390
|
}, {
|
|
2399
|
-
default:
|
|
2400
|
-
|
|
2391
|
+
default: m(() => [
|
|
2392
|
+
d(l(Lt), { class: "size-4" })
|
|
2401
2393
|
]),
|
|
2402
2394
|
_: 1
|
|
2403
2395
|
}, 8, ["disabled", "aria-label", "title"])
|
|
2404
|
-
])) :
|
|
2396
|
+
])) : M("", !0)
|
|
2405
2397
|
]),
|
|
2406
|
-
|
|
2407
|
-
report: l(
|
|
2398
|
+
d(On, {
|
|
2399
|
+
report: l(i),
|
|
2408
2400
|
class: "gap-0.5"
|
|
2409
2401
|
}, null, 8, ["report"])
|
|
2410
2402
|
]),
|
|
2411
|
-
l(
|
|
2403
|
+
l(i).description ? (o(), f(z, {
|
|
2412
2404
|
key: 0,
|
|
2413
|
-
text: l(
|
|
2405
|
+
text: l(i).description,
|
|
2414
2406
|
class: "text-gray-600"
|
|
2415
|
-
}, null, 8, ["text"])) :
|
|
2407
|
+
}, null, 8, ["text"])) : M("", !0)
|
|
2416
2408
|
]),
|
|
2417
|
-
|
|
2418
|
-
|
|
2409
|
+
b("div", Xn, [
|
|
2410
|
+
b("pre", {
|
|
2419
2411
|
class: "p-4 text-xs text-red-800",
|
|
2420
2412
|
textContent: x(l(n))
|
|
2421
|
-
}, null, 8,
|
|
2413
|
+
}, null, 8, Yn)
|
|
2422
2414
|
])
|
|
2423
2415
|
]),
|
|
2424
2416
|
_: 1
|
|
2425
2417
|
}, 8, ["title"]));
|
|
2426
2418
|
}
|
|
2427
|
-
}),
|
|
2419
|
+
}), ea = {
|
|
2428
2420
|
viewBox: "0 0 24 24",
|
|
2429
2421
|
width: "1.2em",
|
|
2430
2422
|
height: "1.2em"
|
|
2431
2423
|
};
|
|
2432
|
-
function
|
|
2433
|
-
return
|
|
2434
|
-
|
|
2424
|
+
function ta(t, s) {
|
|
2425
|
+
return o(), y("svg", ea, s[0] || (s[0] = [
|
|
2426
|
+
b("path", {
|
|
2435
2427
|
fill: "currentColor",
|
|
2436
2428
|
d: "M12,1A11,11,0,1,0,23,12,11,11,0,0,0,12,1Zm0,19a8,8,0,1,1,8-8A8,8,0,0,1,12,20Z",
|
|
2437
2429
|
opacity: ".25"
|
|
2438
2430
|
}, null, -1),
|
|
2439
|
-
|
|
2431
|
+
b("path", {
|
|
2440
2432
|
fill: "currentColor",
|
|
2441
2433
|
d: "M10.14,1.16a11,11,0,0,0-9,8.92A1.59,1.59,0,0,0,2.46,12,1.52,1.52,0,0,0,4.11,10.7a8,8,0,0,1,6.66-6.61A1.42,1.42,0,0,0,12,2.69h0A1.57,1.57,0,0,0,10.14,1.16Z"
|
|
2442
2434
|
}, [
|
|
2443
|
-
|
|
2435
|
+
b("animateTransform", {
|
|
2444
2436
|
attributeName: "transform",
|
|
2445
2437
|
dur: "0.75s",
|
|
2446
2438
|
repeatCount: "indefinite",
|
|
@@ -2450,7 +2442,7 @@ function Dn(t, s) {
|
|
|
2450
2442
|
], -1)
|
|
2451
2443
|
]));
|
|
2452
2444
|
}
|
|
2453
|
-
const
|
|
2445
|
+
const sa = V({ name: "svg-spinners-90-ring-with-bg", render: ta }), ra = { class: "mt-1 h-2 w-full overflow-hidden rounded-full bg-gray-200" }, na = { class: "sr-only" }, aa = /* @__PURE__ */ h({
|
|
2454
2446
|
__name: "ProgressBar",
|
|
2455
2447
|
props: {
|
|
2456
2448
|
filledClass: {},
|
|
@@ -2459,31 +2451,31 @@ const jn = E({ name: "svg-spinners-90-ring-with-bg", render: Dn }), Bn = { class
|
|
|
2459
2451
|
},
|
|
2460
2452
|
setup(t) {
|
|
2461
2453
|
let s;
|
|
2462
|
-
const e =
|
|
2463
|
-
return
|
|
2454
|
+
const e = N(0), r = c(() => E("size-full transition-transform duration-500 rounded-r-full ease-linear bg-primary-600", t.filledClass)), n = c(() => typeof t.progress == "number" ? t.progress : e.value);
|
|
2455
|
+
return Le(
|
|
2464
2456
|
() => t.job,
|
|
2465
2457
|
() => {
|
|
2466
2458
|
s && s(), e.value = t.job ? t.job.progress : 0, s = t.job && t.job.listeners.add({ onUpdated: (a) => e.value = a });
|
|
2467
2459
|
},
|
|
2468
2460
|
{ immediate: !0 }
|
|
2469
|
-
),
|
|
2470
|
-
|
|
2471
|
-
class:
|
|
2472
|
-
style:
|
|
2461
|
+
), $e(() => s && s()), (a, u) => (o(), y("div", ra, [
|
|
2462
|
+
b("div", {
|
|
2463
|
+
class: C(r.value),
|
|
2464
|
+
style: Kt(`transform:translateX(-${(1 - n.value) * 100}%)`)
|
|
2473
2465
|
}, null, 6),
|
|
2474
|
-
|
|
2466
|
+
b("span", na, x(a.$td("ui.progress", "{progress}% complete", {
|
|
2475
2467
|
progress: n.value * 100
|
|
2476
2468
|
})), 1)
|
|
2477
2469
|
]));
|
|
2478
2470
|
}
|
|
2479
2471
|
});
|
|
2480
|
-
function
|
|
2472
|
+
function la(t) {
|
|
2481
2473
|
const s = c(() => t.title ?? S("ui.loading", "Loading")), e = c(
|
|
2482
2474
|
() => t.message ?? S("ui.loadingInProgress", "Loading in progress...")
|
|
2483
2475
|
), r = c(() => typeof t.progress == "number" || !!t.job), n = c(() => !t.title);
|
|
2484
2476
|
return { renderedTitle: s, renderedMessage: e, titleHidden: n, showProgress: r };
|
|
2485
2477
|
}
|
|
2486
|
-
const
|
|
2478
|
+
const oa = /* @__PURE__ */ h({
|
|
2487
2479
|
__name: "LoadingModal",
|
|
2488
2480
|
props: {
|
|
2489
2481
|
title: {},
|
|
@@ -2492,30 +2484,30 @@ const Nn = /* @__PURE__ */ g({
|
|
|
2492
2484
|
job: {}
|
|
2493
2485
|
},
|
|
2494
2486
|
setup(t, { expose: s }) {
|
|
2495
|
-
const e = t, { renderedTitle: r, renderedMessage: n, titleHidden: a, showProgress:
|
|
2496
|
-
return s(), (
|
|
2487
|
+
const e = t, { renderedTitle: r, renderedMessage: n, titleHidden: a, showProgress: u } = la(e);
|
|
2488
|
+
return s(), (i, p) => (o(), f(ne, {
|
|
2497
2489
|
persistent: "",
|
|
2498
|
-
class: k(["flex", { "flex-col-reverse": l(i), "items-center justify-center gap-2": !l(i) }]),
|
|
2499
2490
|
"wrapper-class": "w-auto",
|
|
2500
2491
|
title: l(r),
|
|
2501
|
-
"title-hidden": l(a)
|
|
2492
|
+
"title-hidden": l(a),
|
|
2493
|
+
class: C({ "flex-col-reverse": l(u), "flex-row items-center justify-center gap-2": !l(u) })
|
|
2502
2494
|
}, {
|
|
2503
|
-
default:
|
|
2504
|
-
l(
|
|
2495
|
+
default: m(() => [
|
|
2496
|
+
l(u) ? (o(), f(aa, {
|
|
2505
2497
|
key: 0,
|
|
2506
|
-
progress:
|
|
2507
|
-
job:
|
|
2498
|
+
progress: i.progress,
|
|
2499
|
+
job: i.job,
|
|
2508
2500
|
class: "min-w-[min(400px,80vw)]"
|
|
2509
|
-
}, null, 8, ["progress", "job"])) : (
|
|
2501
|
+
}, null, 8, ["progress", "job"])) : (o(), f(l(sa), {
|
|
2510
2502
|
key: 1,
|
|
2511
2503
|
class: "text-primary-600 mr-1 size-6"
|
|
2512
2504
|
})),
|
|
2513
|
-
|
|
2505
|
+
d(z, { text: l(n) }, null, 8, ["text"])
|
|
2514
2506
|
]),
|
|
2515
2507
|
_: 1
|
|
2516
2508
|
}, 8, ["title", "title-hidden", "class"]));
|
|
2517
2509
|
}
|
|
2518
|
-
}),
|
|
2510
|
+
}), Be = /* @__PURE__ */ h({
|
|
2519
2511
|
__name: "HeadlessInput",
|
|
2520
2512
|
props: {
|
|
2521
2513
|
name: {},
|
|
@@ -2526,128 +2518,133 @@ const Nn = /* @__PURE__ */ g({
|
|
|
2526
2518
|
},
|
|
2527
2519
|
emits: ["update:modelValue"],
|
|
2528
2520
|
setup(t, { expose: s, emit: e }) {
|
|
2529
|
-
const r = e, n =
|
|
2530
|
-
id: `input-${
|
|
2521
|
+
const r = e, n = Y("form", null), a = c(() => !n || !t.name ? null : n.errors[t.name] ?? null), u = {
|
|
2522
|
+
id: `input-${ue()}`,
|
|
2531
2523
|
name: c(() => t.name),
|
|
2532
2524
|
label: c(() => t.label),
|
|
2533
2525
|
description: c(() => t.description),
|
|
2534
2526
|
value: c(() => n && t.name ? n.getFieldValue(t.name) : t.modelValue),
|
|
2535
|
-
errors:
|
|
2527
|
+
errors: _e(a),
|
|
2536
2528
|
required: c(() => {
|
|
2537
2529
|
if (!(!t.name || !n))
|
|
2538
2530
|
return n.getFieldRules(t.name).includes("required");
|
|
2539
2531
|
}),
|
|
2540
|
-
update(
|
|
2532
|
+
update(i) {
|
|
2541
2533
|
if (n && t.name) {
|
|
2542
|
-
n.setFieldValue(t.name,
|
|
2534
|
+
n.setFieldValue(t.name, i);
|
|
2543
2535
|
return;
|
|
2544
2536
|
}
|
|
2545
|
-
r("update:modelValue",
|
|
2537
|
+
r("update:modelValue", i);
|
|
2546
2538
|
}
|
|
2547
2539
|
};
|
|
2548
|
-
return
|
|
2549
|
-
default:
|
|
2550
|
-
|
|
2540
|
+
return pe("input", u), s(u), (i, p) => (o(), f(ee(i.as), null, {
|
|
2541
|
+
default: m(() => [
|
|
2542
|
+
$(i.$slots, "default")
|
|
2551
2543
|
]),
|
|
2552
2544
|
_: 3
|
|
2553
2545
|
}));
|
|
2554
2546
|
}
|
|
2555
|
-
}),
|
|
2547
|
+
}), ia = ["for"], ye = /* @__PURE__ */ h({
|
|
2556
2548
|
__name: "HeadlessInputLabel",
|
|
2557
2549
|
setup(t) {
|
|
2558
|
-
const s =
|
|
2559
|
-
return (n, a) => r.value ? (
|
|
2550
|
+
const s = R("input", "<HeadlessInputLabel> must be a child of a <HeadlessInput>"), e = Ie(), r = c(() => !!(s.label || e.default));
|
|
2551
|
+
return (n, a) => r.value ? (o(), y("label", {
|
|
2560
2552
|
key: 0,
|
|
2561
2553
|
for: l(s).id
|
|
2562
2554
|
}, [
|
|
2563
|
-
|
|
2564
|
-
|
|
2555
|
+
$(n.$slots, "default", {}, () => [
|
|
2556
|
+
L(x(l(s).label), 1)
|
|
2565
2557
|
])
|
|
2566
|
-
], 8,
|
|
2558
|
+
], 8, ia)) : M("", !0);
|
|
2567
2559
|
}
|
|
2568
|
-
}),
|
|
2560
|
+
}), ua = ["id", "name", "checked", "type", "required", "aria-invalid", "aria-describedby"], It = /* @__PURE__ */ h({
|
|
2569
2561
|
__name: "HeadlessInputInput",
|
|
2570
2562
|
props: {
|
|
2571
2563
|
type: {}
|
|
2572
2564
|
},
|
|
2573
2565
|
setup(t) {
|
|
2574
|
-
const s =
|
|
2566
|
+
const s = te("$inputRef"), e = R("input", "<HeadlessInputInput> must be a child of a <HeadlessInput>"), r = Y("form", null), n = c(() => e.name ?? void 0), a = c(() => e.value), u = c(() => {
|
|
2575
2567
|
if (t.type)
|
|
2576
2568
|
return t.type;
|
|
2577
|
-
const
|
|
2578
|
-
return ["text", "email", "number", "tel", "url"].includes(
|
|
2579
|
-
}),
|
|
2580
|
-
if (
|
|
2569
|
+
const w = (n.value && (r == null ? void 0 : r.getFieldType(n.value))) ?? "";
|
|
2570
|
+
return ["text", "email", "number", "tel", "url"].includes(w) ? w : "text";
|
|
2571
|
+
}), i = c(() => {
|
|
2572
|
+
if (u.value === "checkbox")
|
|
2581
2573
|
return !!a.value;
|
|
2582
2574
|
});
|
|
2583
|
-
function
|
|
2584
|
-
s.value && e.update(
|
|
2575
|
+
function p() {
|
|
2576
|
+
s.value && e.update(g());
|
|
2585
2577
|
}
|
|
2586
|
-
function
|
|
2578
|
+
function g() {
|
|
2587
2579
|
if (!s.value)
|
|
2588
2580
|
return null;
|
|
2589
|
-
switch (
|
|
2581
|
+
switch (u.value) {
|
|
2590
2582
|
case "checkbox":
|
|
2591
2583
|
return s.value.checked;
|
|
2592
2584
|
case "date":
|
|
2593
|
-
|
|
2585
|
+
case "time":
|
|
2586
|
+
case "datetime-local":
|
|
2587
|
+
return new Date(Math.round(s.value.valueAsNumber / 6e4) * 6e4 + Ze);
|
|
2588
|
+
case "number":
|
|
2589
|
+
return s.value.valueAsNumber;
|
|
2594
2590
|
default:
|
|
2595
2591
|
return s.value.value;
|
|
2596
2592
|
}
|
|
2597
2593
|
}
|
|
2598
|
-
return
|
|
2599
|
-
var
|
|
2600
|
-
return (
|
|
2601
|
-
}),
|
|
2594
|
+
return mt(e, () => {
|
|
2595
|
+
var w;
|
|
2596
|
+
return (w = s.value) == null ? void 0 : w.focus();
|
|
2597
|
+
}), G(() => {
|
|
2602
2598
|
if (s.value) {
|
|
2603
|
-
if (
|
|
2604
|
-
|
|
2599
|
+
if (["date", "time", "datetime-local"].includes(u.value) && a.value instanceof Date) {
|
|
2600
|
+
const w = Math.round(a.value.getTime() / 6e4) * 6e4;
|
|
2601
|
+
s.value.valueAsNumber = w - Ze, e.update(new Date(w));
|
|
2605
2602
|
return;
|
|
2606
2603
|
}
|
|
2607
2604
|
s.value.value = a.value ?? null;
|
|
2608
2605
|
}
|
|
2609
|
-
}), (
|
|
2606
|
+
}), (w, v) => (o(), y("input", {
|
|
2610
2607
|
id: l(e).id,
|
|
2611
2608
|
ref: "$inputRef",
|
|
2612
2609
|
name: n.value,
|
|
2613
|
-
checked:
|
|
2614
|
-
type:
|
|
2610
|
+
checked: i.value,
|
|
2611
|
+
type: u.value,
|
|
2615
2612
|
required: l(e).required ?? void 0,
|
|
2616
2613
|
"aria-invalid": l(e).errors ? "true" : "false",
|
|
2617
2614
|
"aria-describedby": l(e).errors ? `${l(e).id}-error` : l(e).description ? `${l(e).id}-description` : void 0,
|
|
2618
|
-
onInput:
|
|
2619
|
-
}, null, 40,
|
|
2615
|
+
onInput: p
|
|
2616
|
+
}, null, 40, ua));
|
|
2620
2617
|
}
|
|
2621
|
-
}),
|
|
2618
|
+
}), zt = /* @__PURE__ */ h({
|
|
2622
2619
|
inheritAttrs: !1,
|
|
2623
2620
|
__name: "HeadlessInputDescription",
|
|
2624
2621
|
setup(t) {
|
|
2625
|
-
const s =
|
|
2622
|
+
const s = R(
|
|
2626
2623
|
"input",
|
|
2627
2624
|
"<HeadlessInputDescription> must be a child of a <HeadlessInput>"
|
|
2628
2625
|
), e = c(() => typeof s.description == "string" ? s.description : ""), r = c(() => !!s.description);
|
|
2629
|
-
return (n, a) =>
|
|
2626
|
+
return (n, a) => $(n.$slots, "default", {
|
|
2630
2627
|
id: `${l(s).id}-description`
|
|
2631
2628
|
}, () => [
|
|
2632
|
-
r.value ? (
|
|
2629
|
+
r.value ? (o(), f(z, H({ key: 0 }, n.$attrs, {
|
|
2633
2630
|
id: `${l(s).id}-description`,
|
|
2634
2631
|
text: e.value
|
|
2635
|
-
}), null, 16, ["id", "text"])) :
|
|
2632
|
+
}), null, 16, ["id", "text"])) : M("", !0)
|
|
2636
2633
|
]);
|
|
2637
2634
|
}
|
|
2638
|
-
}),
|
|
2635
|
+
}), ca = ["id"], we = /* @__PURE__ */ h({
|
|
2639
2636
|
__name: "HeadlessInputError",
|
|
2640
2637
|
setup(t) {
|
|
2641
|
-
const s =
|
|
2642
|
-
return (r, n) => e.value ? (
|
|
2638
|
+
const s = R("input", "<HeadlessInputError> must be a child of a <HeadlessInput>"), e = c(() => s.errors ? S(`errors.${s.errors[0]}`, `Error: ${s.errors[0]}`) : null);
|
|
2639
|
+
return (r, n) => e.value ? (o(), y("p", {
|
|
2643
2640
|
key: 0,
|
|
2644
2641
|
id: `${l(s).id}-error`
|
|
2645
|
-
}, x(e.value), 9,
|
|
2642
|
+
}, x(e.value), 9, ca)) : M("", !0);
|
|
2646
2643
|
}
|
|
2647
|
-
}),
|
|
2644
|
+
}), da = {
|
|
2648
2645
|
key: 0,
|
|
2649
2646
|
class: "pointer-events-none absolute inset-y-0 right-0 flex items-center pr-3"
|
|
2650
|
-
},
|
|
2647
|
+
}, pa = /* @__PURE__ */ h({
|
|
2651
2648
|
inheritAttrs: !1,
|
|
2652
2649
|
__name: "Input",
|
|
2653
2650
|
props: {
|
|
@@ -2660,61 +2657,61 @@ const Nn = /* @__PURE__ */ g({
|
|
|
2660
2657
|
},
|
|
2661
2658
|
emits: ["update:modelValue"],
|
|
2662
2659
|
setup(t) {
|
|
2663
|
-
const s =
|
|
2664
|
-
var
|
|
2665
|
-
return
|
|
2660
|
+
const s = K(t, ["label", "inputClass", "wrapperClass"]), e = te("$inputRef"), [r, n] = Ae(), a = c(() => E("relative rounded-md shadow-2xs", { "mt-1": t.label }, t.wrapperClass)), u = c(() => {
|
|
2661
|
+
var i, p, g;
|
|
2662
|
+
return E(
|
|
2666
2663
|
// eslint-disable-next-line vue/max-len
|
|
2667
2664
|
"block w-full rounded-md border-0 py-1.5 ring-1 ring-inset focus:ring-2 focus:ring-inset sm:text-sm sm:leading-6",
|
|
2668
2665
|
{
|
|
2669
|
-
"focus:ring-primary-600": !((
|
|
2670
|
-
"text-gray-900 shadow-2xs ring-gray-900/10 placeholder:text-gray-400": !((
|
|
2671
|
-
"pr-10 text-red-900 ring-red-900/10 placeholder:text-red-300 focus:ring-red-500": (
|
|
2666
|
+
"focus:ring-primary-600": !((i = e.value) != null && i.errors),
|
|
2667
|
+
"text-gray-900 shadow-2xs ring-gray-900/10 placeholder:text-gray-400": !((p = e.value) != null && p.errors),
|
|
2668
|
+
"pr-10 text-red-900 ring-red-900/10 placeholder:text-red-300 focus:ring-red-500": (g = e.value) == null ? void 0 : g.errors
|
|
2672
2669
|
},
|
|
2673
2670
|
t.inputClass
|
|
2674
2671
|
);
|
|
2675
2672
|
});
|
|
2676
|
-
return (
|
|
2673
|
+
return (i, p) => (o(), f(Be, H({
|
|
2677
2674
|
ref: "$inputRef",
|
|
2678
|
-
label:
|
|
2675
|
+
label: i.label,
|
|
2679
2676
|
class: l(n)
|
|
2680
2677
|
}, s, {
|
|
2681
|
-
"onUpdate:modelValue":
|
|
2678
|
+
"onUpdate:modelValue": p[0] || (p[0] = (g) => i.$emit("update:modelValue", g))
|
|
2682
2679
|
}), {
|
|
2683
|
-
default:
|
|
2684
|
-
var
|
|
2680
|
+
default: m(() => {
|
|
2681
|
+
var g;
|
|
2685
2682
|
return [
|
|
2686
|
-
|
|
2687
|
-
|
|
2688
|
-
class:
|
|
2683
|
+
d(ye, { class: "block text-sm leading-6 font-medium text-gray-900" }),
|
|
2684
|
+
b("div", {
|
|
2685
|
+
class: C(a.value)
|
|
2689
2686
|
}, [
|
|
2690
|
-
|
|
2691
|
-
(
|
|
2692
|
-
|
|
2693
|
-
])) :
|
|
2687
|
+
d(It, H(l(r), { class: u.value }), null, 16, ["class"]),
|
|
2688
|
+
(g = e.value) != null && g.errors ? (o(), y("div", da, [
|
|
2689
|
+
d(l(De), { class: "size-5 text-red-500" })
|
|
2690
|
+
])) : M("", !0)
|
|
2694
2691
|
], 2),
|
|
2695
|
-
|
|
2696
|
-
|
|
2692
|
+
d(zt, { class: "mt-2 text-sm text-gray-600" }),
|
|
2693
|
+
d(we, { class: "mt-2 text-sm text-red-600" })
|
|
2697
2694
|
];
|
|
2698
2695
|
}),
|
|
2699
2696
|
_: 1
|
|
2700
2697
|
}, 16, ["label", "class"]));
|
|
2701
2698
|
}
|
|
2702
2699
|
});
|
|
2703
|
-
function
|
|
2700
|
+
function Dl(t, s = {}) {
|
|
2704
2701
|
return {
|
|
2705
2702
|
default: t,
|
|
2706
2703
|
type: "boolean",
|
|
2707
2704
|
rules: s.rules
|
|
2708
2705
|
};
|
|
2709
2706
|
}
|
|
2710
|
-
function
|
|
2707
|
+
function Bl(t, s = {}) {
|
|
2711
2708
|
return {
|
|
2712
2709
|
default: t,
|
|
2713
2710
|
type: "date",
|
|
2714
2711
|
rules: s.rules
|
|
2715
2712
|
};
|
|
2716
2713
|
}
|
|
2717
|
-
function
|
|
2714
|
+
function jl(t, s, e = {}) {
|
|
2718
2715
|
return {
|
|
2719
2716
|
default: s,
|
|
2720
2717
|
type: "enum",
|
|
@@ -2722,21 +2719,21 @@ function xl(t, s, e = {}) {
|
|
|
2722
2719
|
values: t
|
|
2723
2720
|
};
|
|
2724
2721
|
}
|
|
2725
|
-
function
|
|
2722
|
+
function Fl(t) {
|
|
2726
2723
|
return {
|
|
2727
2724
|
default: t,
|
|
2728
2725
|
type: "boolean",
|
|
2729
2726
|
rules: "required"
|
|
2730
2727
|
};
|
|
2731
2728
|
}
|
|
2732
|
-
function
|
|
2729
|
+
function Ul(t) {
|
|
2733
2730
|
return {
|
|
2734
2731
|
default: t,
|
|
2735
2732
|
type: "date",
|
|
2736
2733
|
rules: "required"
|
|
2737
2734
|
};
|
|
2738
2735
|
}
|
|
2739
|
-
function
|
|
2736
|
+
function Ol(t, s) {
|
|
2740
2737
|
return {
|
|
2741
2738
|
default: s,
|
|
2742
2739
|
type: "enum",
|
|
@@ -2744,55 +2741,55 @@ function Sl(t, s) {
|
|
|
2744
2741
|
values: t
|
|
2745
2742
|
};
|
|
2746
2743
|
}
|
|
2747
|
-
function
|
|
2744
|
+
function Nl(t) {
|
|
2748
2745
|
return {
|
|
2749
2746
|
default: t,
|
|
2750
2747
|
type: "number",
|
|
2751
2748
|
rules: "required"
|
|
2752
2749
|
};
|
|
2753
2750
|
}
|
|
2754
|
-
function
|
|
2751
|
+
function Wl(t) {
|
|
2755
2752
|
return {
|
|
2756
2753
|
default: t,
|
|
2757
2754
|
type: "object",
|
|
2758
2755
|
rules: "required"
|
|
2759
2756
|
};
|
|
2760
2757
|
}
|
|
2761
|
-
function
|
|
2758
|
+
function ma(t) {
|
|
2762
2759
|
return {
|
|
2763
2760
|
default: t,
|
|
2764
2761
|
type: "string",
|
|
2765
2762
|
rules: "required"
|
|
2766
2763
|
};
|
|
2767
2764
|
}
|
|
2768
|
-
function
|
|
2765
|
+
function Kl(t, s = {}) {
|
|
2769
2766
|
return {
|
|
2770
2767
|
default: t,
|
|
2771
2768
|
type: "number",
|
|
2772
2769
|
rules: s.rules
|
|
2773
2770
|
};
|
|
2774
2771
|
}
|
|
2775
|
-
function
|
|
2772
|
+
function Ql(t, s = {}) {
|
|
2776
2773
|
return {
|
|
2777
2774
|
default: t,
|
|
2778
2775
|
type: "object",
|
|
2779
2776
|
rules: s.rules
|
|
2780
2777
|
};
|
|
2781
2778
|
}
|
|
2782
|
-
function
|
|
2779
|
+
function Jl(t, s = {}) {
|
|
2783
2780
|
return {
|
|
2784
2781
|
default: t,
|
|
2785
2782
|
type: "string",
|
|
2786
2783
|
rules: s.rules
|
|
2787
2784
|
};
|
|
2788
2785
|
}
|
|
2789
|
-
function
|
|
2790
|
-
const s =
|
|
2791
|
-
draft:
|
|
2786
|
+
function fa(t) {
|
|
2787
|
+
const s = ft({
|
|
2788
|
+
draft: ma(t.defaultValue ?? "")
|
|
2792
2789
|
}), e = c(() => t.title ?? t.message), r = c(() => t.title ? t.message : null), n = c(() => t.acceptText ?? S("ui.accept", "Ok")), a = c(() => t.cancelText ?? S("ui.cancel", "Cancel"));
|
|
2793
2790
|
return { form: s, renderedTitle: e, renderedMessage: r, renderedAcceptText: n, renderedCancelText: a };
|
|
2794
2791
|
}
|
|
2795
|
-
const
|
|
2792
|
+
const ha = { class: "mt-4 flex flex-row-reverse gap-2" }, ga = /* @__PURE__ */ h({
|
|
2796
2793
|
__name: "PromptModal",
|
|
2797
2794
|
props: {
|
|
2798
2795
|
title: {},
|
|
@@ -2805,44 +2802,45 @@ const Gn = { class: "mt-4 flex flex-row-reverse gap-2" }, ea = /* @__PURE__ */ g
|
|
|
2805
2802
|
cancelText: {},
|
|
2806
2803
|
cancelVariant: { default: "secondary" }
|
|
2807
2804
|
},
|
|
2805
|
+
emits: ["close"],
|
|
2808
2806
|
setup(t, { expose: s }) {
|
|
2809
|
-
const e =
|
|
2810
|
-
return s(), (
|
|
2807
|
+
const e = K(t, ["cancelVariant"]), { form: r, renderedTitle: n, renderedMessage: a, renderedAcceptText: u, renderedCancelText: i } = fa(e);
|
|
2808
|
+
return s(), (p, g) => (o(), f(ne, {
|
|
2811
2809
|
title: l(n),
|
|
2812
2810
|
persistent: ""
|
|
2813
2811
|
}, {
|
|
2814
|
-
default:
|
|
2815
|
-
|
|
2812
|
+
default: m(({ close: w }) => [
|
|
2813
|
+
d(Vt, {
|
|
2816
2814
|
form: l(r),
|
|
2817
|
-
onSubmit: (
|
|
2815
|
+
onSubmit: (v) => w(l(r).draft)
|
|
2818
2816
|
}, {
|
|
2819
|
-
default:
|
|
2820
|
-
l(a) ? (
|
|
2817
|
+
default: m(() => [
|
|
2818
|
+
l(a) ? (o(), f(z, {
|
|
2821
2819
|
key: 0,
|
|
2822
2820
|
text: l(a)
|
|
2823
|
-
}, null, 8, ["text"])) :
|
|
2824
|
-
|
|
2821
|
+
}, null, 8, ["text"])) : M("", !0),
|
|
2822
|
+
d(pa, {
|
|
2825
2823
|
name: "draft",
|
|
2826
2824
|
class: "mt-2",
|
|
2827
|
-
placeholder:
|
|
2828
|
-
label:
|
|
2825
|
+
placeholder: p.placeholder,
|
|
2826
|
+
label: p.label
|
|
2829
2827
|
}, null, 8, ["placeholder", "label"]),
|
|
2830
|
-
|
|
2831
|
-
|
|
2832
|
-
variant:
|
|
2828
|
+
b("div", ha, [
|
|
2829
|
+
d(I, {
|
|
2830
|
+
variant: p.acceptVariant,
|
|
2833
2831
|
submit: ""
|
|
2834
2832
|
}, {
|
|
2835
|
-
default:
|
|
2836
|
-
|
|
2833
|
+
default: m(() => [
|
|
2834
|
+
L(x(l(u)), 1)
|
|
2837
2835
|
]),
|
|
2838
2836
|
_: 1
|
|
2839
2837
|
}, 8, ["variant"]),
|
|
2840
|
-
|
|
2841
|
-
variant:
|
|
2842
|
-
onClick: (
|
|
2838
|
+
d(I, {
|
|
2839
|
+
variant: p.cancelVariant,
|
|
2840
|
+
onClick: (v) => w()
|
|
2843
2841
|
}, {
|
|
2844
|
-
default:
|
|
2845
|
-
|
|
2842
|
+
default: m(() => [
|
|
2843
|
+
L(x(l(i)), 1)
|
|
2846
2844
|
]),
|
|
2847
2845
|
_: 2
|
|
2848
2846
|
}, 1032, ["variant", "onClick"])
|
|
@@ -2854,63 +2852,63 @@ const Gn = { class: "mt-4 flex flex-row-reverse gap-2" }, ea = /* @__PURE__ */ g
|
|
|
2854
2852
|
_: 1
|
|
2855
2853
|
}, 8, ["title"]));
|
|
2856
2854
|
}
|
|
2857
|
-
}),
|
|
2855
|
+
}), va = {
|
|
2858
2856
|
viewBox: "0 0 24 24",
|
|
2859
2857
|
width: "1.2em",
|
|
2860
2858
|
height: "1.2em"
|
|
2861
2859
|
};
|
|
2862
|
-
function
|
|
2863
|
-
return
|
|
2864
|
-
|
|
2860
|
+
function ba(t, s) {
|
|
2861
|
+
return o(), y("svg", va, s[0] || (s[0] = [
|
|
2862
|
+
b("path", {
|
|
2865
2863
|
fill: "currentColor",
|
|
2866
2864
|
d: "M12 21q-1.625 0-3.012-.8T6.8 18H4v-2h2.1q-.075-.5-.088-1T6 14H4v-2h2q0-.5.012-1t.088-1H4V8h2.8q.35-.575.788-1.075T8.6 6.05L7 4.4L8.4 3l2.15 2.15q.7-.225 1.425-.225t1.425.225L15.6 3L17 4.4l-1.65 1.65q.575.375 1.038.862T17.2 8H20v2h-2.1q.075.5.088 1T18 12h2v2h-2q0 .5-.013 1t-.087 1H20v2h-2.8q-.8 1.4-2.187 2.2T12 21m-2-5h4v-2h-4zm0-4h4v-2h-4z"
|
|
2867
2865
|
}, null, -1)
|
|
2868
2866
|
]));
|
|
2869
2867
|
}
|
|
2870
|
-
const
|
|
2868
|
+
const ya = V({ name: "material-symbols-bug-report", render: ba }), wa = {
|
|
2871
2869
|
viewBox: "0 0 24 24",
|
|
2872
2870
|
width: "1.2em",
|
|
2873
2871
|
height: "1.2em"
|
|
2874
2872
|
};
|
|
2875
|
-
function
|
|
2876
|
-
return
|
|
2877
|
-
|
|
2873
|
+
function $a(t, s) {
|
|
2874
|
+
return o(), y("svg", wa, s[0] || (s[0] = [
|
|
2875
|
+
b("path", {
|
|
2878
2876
|
fill: "currentColor",
|
|
2879
2877
|
d: "M7 21q-.825 0-1.412-.587T5 19V6q-.425 0-.712-.288T4 5t.288-.712T5 4h4q0-.425.288-.712T10 3h4q.425 0 .713.288T15 4h4q.425 0 .713.288T20 5t-.288.713T19 6v13q0 .825-.587 1.413T17 21zm5-7.1l1.9 1.9q.275.275.7.275t.7-.275t.275-.7t-.275-.7l-1.9-1.9l1.9-1.9q.275-.275.275-.7t-.275-.7t-.7-.275t-.7.275L12 11.1l-1.9-1.9q-.275-.275-.7-.275t-.7.275t-.275.7t.275.7l1.9 1.9l-1.9 1.9q-.275.275-.275.7t.275.7t.7.275t.7-.275z"
|
|
2880
2878
|
}, null, -1)
|
|
2881
2879
|
]));
|
|
2882
2880
|
}
|
|
2883
|
-
const
|
|
2881
|
+
const _a = V({ name: "material-symbols-delete-forever-rounded", render: $a }), xa = {
|
|
2884
2882
|
viewBox: "0 0 24 24",
|
|
2885
2883
|
width: "1.2em",
|
|
2886
2884
|
height: "1.2em"
|
|
2887
2885
|
};
|
|
2888
|
-
function
|
|
2889
|
-
return
|
|
2890
|
-
|
|
2886
|
+
function Ca(t, s) {
|
|
2887
|
+
return o(), y("svg", xa, s[0] || (s[0] = [
|
|
2888
|
+
b("path", {
|
|
2891
2889
|
fill: "currentColor",
|
|
2892
2890
|
d: "M11.25 13.5q.95 0 1.6-.65t.65-1.6t-.65-1.6t-1.6-.65t-1.6.65t-.65 1.6t.65 1.6t1.6.65m4.825 4l-2.625-2.625q-.5.325-1.062.475t-1.138.15q-1.775 0-3.012-1.237T7 11.25t1.238-3.012T11.25 7t3.013 1.238T15.5 11.25q0 .575-.162 1.138t-.488 1.062l2.65 2.65zM5 21q-.825 0-1.412-.587T3 19v-4h2v4h4v2zm10 0v-2h4v-4h2v4q0 .825-.587 1.413T19 21zM3 9V5q0-.825.588-1.412T5 3h4v2H5v4zm16 0V5h-4V3h4q.825 0 1.413.588T21 5v4z"
|
|
2893
2891
|
}, null, -1)
|
|
2894
2892
|
]));
|
|
2895
2893
|
}
|
|
2896
|
-
const
|
|
2894
|
+
const Sa = V({ name: "material-symbols-frame-inspect", render: Ca }), ka = {
|
|
2897
2895
|
viewBox: "0 0 24 24",
|
|
2898
2896
|
width: "1.2em",
|
|
2899
2897
|
height: "1.2em"
|
|
2900
2898
|
};
|
|
2901
|
-
function
|
|
2902
|
-
return
|
|
2903
|
-
|
|
2899
|
+
function Ta(t, s) {
|
|
2900
|
+
return o(), y("svg", ka, s[0] || (s[0] = [
|
|
2901
|
+
b("path", {
|
|
2904
2902
|
fill: "currentColor",
|
|
2905
2903
|
d: "M12 20q-3.35 0-5.675-2.325T4 12t2.325-5.675T12 4q1.725 0 3.3.712T18 6.75V5q0-.425.288-.712T19 4t.713.288T20 5v5q0 .425-.288.713T19 11h-5q-.425 0-.712-.288T13 10t.288-.712T14 9h3.2q-.8-1.4-2.187-2.2T12 6Q9.5 6 7.75 7.75T6 12t1.75 4.25T12 18q1.7 0 3.113-.862t2.187-2.313q.2-.35.563-.487t.737-.013q.4.125.575.525t-.025.75q-1.025 2-2.925 3.2T12 20"
|
|
2906
2904
|
}, null, -1)
|
|
2907
2905
|
]));
|
|
2908
2906
|
}
|
|
2909
|
-
const
|
|
2907
|
+
const Ma = V({ name: "material-symbols-refresh-rounded", render: Ta }), Ea = { class: "grid grow place-items-center" }, Ha = { class: "flex flex-col items-center p-8" }, Va = { class: "mt-0 mb-0 text-center text-4xl font-medium text-red-600" }, La = { class: "mt-4 grid grid-cols-1 gap-2 sm:grid-cols-2 [&_button]:justify-start sm:[&_button]:size-32 sm:[&_button]:flex-col sm:[&_button]:justify-center [&_svg]:size-6 sm:[&_svg]:size-8" }, Ia = /* @__PURE__ */ h({
|
|
2910
2908
|
__name: "StartupCrash",
|
|
2911
2909
|
setup(t) {
|
|
2912
2910
|
async function s() {
|
|
2913
|
-
await
|
|
2911
|
+
await A.confirm(
|
|
2914
2912
|
S("startupCrash.purgeConfirmTitle", "Delete everything?"),
|
|
2915
2913
|
S(
|
|
2916
2914
|
"startupCrash.purgeConfirmMessage",
|
|
@@ -2922,59 +2920,59 @@ Do you still want to proceed?`
|
|
|
2922
2920
|
acceptVariant: "danger",
|
|
2923
2921
|
acceptText: S("startupCrash.purgeConfirmAccept", "Purge device")
|
|
2924
2922
|
}
|
|
2925
|
-
) && (await
|
|
2923
|
+
) && (await gt.purge(), await P.reload());
|
|
2926
2924
|
}
|
|
2927
2925
|
return (e, r) => {
|
|
2928
|
-
const n =
|
|
2929
|
-
return
|
|
2930
|
-
|
|
2931
|
-
|
|
2932
|
-
|
|
2933
|
-
|
|
2926
|
+
const n = Qt("i-majesticons-exclamation");
|
|
2927
|
+
return o(), y("div", Ea, [
|
|
2928
|
+
b("div", Ha, [
|
|
2929
|
+
d(n, { class: "size-20 text-red-600" }),
|
|
2930
|
+
b("h1", Va, x(e.$td("startupCrash.title", "Oops, something went wrong!")), 1),
|
|
2931
|
+
d(z, {
|
|
2934
2932
|
text: e.$td(
|
|
2935
2933
|
"startupCrash.message",
|
|
2936
2934
|
"There was a problem starting the application, but here's some things you can do:"
|
|
2937
2935
|
),
|
|
2938
2936
|
class: "mt-4 text-center"
|
|
2939
2937
|
}, null, 8, ["text"]),
|
|
2940
|
-
|
|
2941
|
-
|
|
2938
|
+
b("div", La, [
|
|
2939
|
+
d(I, {
|
|
2942
2940
|
variant: "danger",
|
|
2943
2941
|
onClick: r[0] || (r[0] = (a) => e.$app.reload())
|
|
2944
2942
|
}, {
|
|
2945
|
-
default:
|
|
2946
|
-
|
|
2947
|
-
|
|
2943
|
+
default: m(() => [
|
|
2944
|
+
d(l(Ma)),
|
|
2945
|
+
L(" " + x(e.$td("startupCrash.reload", "Try again")), 1)
|
|
2948
2946
|
]),
|
|
2949
2947
|
_: 1
|
|
2950
2948
|
}),
|
|
2951
|
-
|
|
2949
|
+
d(I, {
|
|
2952
2950
|
variant: "danger",
|
|
2953
2951
|
onClick: r[1] || (r[1] = (a) => e.$errors.inspect(e.$errors.startupErrors))
|
|
2954
2952
|
}, {
|
|
2955
|
-
default:
|
|
2956
|
-
|
|
2957
|
-
|
|
2953
|
+
default: m(() => [
|
|
2954
|
+
d(l(ya)),
|
|
2955
|
+
L(" " + x(e.$td("startupCrash.inspect", "View error details")), 1)
|
|
2958
2956
|
]),
|
|
2959
2957
|
_: 1
|
|
2960
2958
|
}),
|
|
2961
|
-
|
|
2959
|
+
d(I, {
|
|
2962
2960
|
variant: "danger",
|
|
2963
2961
|
onClick: r[2] || (r[2] = (a) => s())
|
|
2964
2962
|
}, {
|
|
2965
|
-
default:
|
|
2966
|
-
|
|
2967
|
-
|
|
2963
|
+
default: m(() => [
|
|
2964
|
+
d(l(_a)),
|
|
2965
|
+
L(" " + x(e.$td("startupCrash.purge", "Purge device")), 1)
|
|
2968
2966
|
]),
|
|
2969
2967
|
_: 1
|
|
2970
2968
|
}),
|
|
2971
|
-
|
|
2969
|
+
d(I, {
|
|
2972
2970
|
variant: "danger",
|
|
2973
2971
|
onClick: r[3] || (r[3] = (a) => e.$errors.debug = !e.$errors.debug)
|
|
2974
2972
|
}, {
|
|
2975
|
-
default:
|
|
2976
|
-
|
|
2977
|
-
|
|
2973
|
+
default: m(() => [
|
|
2974
|
+
d(l(Sa)),
|
|
2975
|
+
L(" " + x(e.$td("startupCrash.debug", "Toggle debugging")), 1)
|
|
2978
2976
|
]),
|
|
2979
2977
|
_: 1
|
|
2980
2978
|
})
|
|
@@ -2983,23 +2981,23 @@ Do you still want to proceed?`
|
|
|
2983
2981
|
]);
|
|
2984
2982
|
};
|
|
2985
2983
|
}
|
|
2986
|
-
}),
|
|
2984
|
+
}), Rt = /* @__PURE__ */ h({
|
|
2987
2985
|
__name: "HeadlessToastAction",
|
|
2988
2986
|
props: {
|
|
2989
2987
|
action: {}
|
|
2990
2988
|
},
|
|
2991
2989
|
setup(t) {
|
|
2992
|
-
return (s, e) => (
|
|
2990
|
+
return (s, e) => (o(), f(ee(s.action.dismiss ? l(js) : "button"), {
|
|
2993
2991
|
type: "button",
|
|
2994
2992
|
onClick: s.action.click
|
|
2995
2993
|
}, {
|
|
2996
|
-
default:
|
|
2997
|
-
|
|
2994
|
+
default: m(() => [
|
|
2995
|
+
L(x(s.action.label), 1)
|
|
2998
2996
|
]),
|
|
2999
2997
|
_: 1
|
|
3000
2998
|
}, 8, ["onClick"]));
|
|
3001
2999
|
}
|
|
3002
|
-
}),
|
|
3000
|
+
}), za = { key: 0 }, Ra = /* @__PURE__ */ h({
|
|
3003
3001
|
__name: "HeadlessToast",
|
|
3004
3002
|
props: {
|
|
3005
3003
|
message: {},
|
|
@@ -3007,11 +3005,11 @@ Do you still want to proceed?`
|
|
|
3007
3005
|
variant: {}
|
|
3008
3006
|
},
|
|
3009
3007
|
setup(t) {
|
|
3010
|
-
return (s, e) => (
|
|
3011
|
-
default:
|
|
3012
|
-
|
|
3013
|
-
s.message ? (
|
|
3014
|
-
(
|
|
3008
|
+
return (s, e) => (o(), f(l(Fs), null, {
|
|
3009
|
+
default: m(() => [
|
|
3010
|
+
$(s.$slots, "default", {}, () => [
|
|
3011
|
+
s.message ? (o(), y("span", za, x(s.message), 1)) : M("", !0),
|
|
3012
|
+
(o(!0), y(D, null, U(s.actions, (r, n) => (o(), f(Rt, {
|
|
3015
3013
|
key: n,
|
|
3016
3014
|
action: r
|
|
3017
3015
|
}, null, 8, ["action"]))), 128))
|
|
@@ -3020,7 +3018,7 @@ Do you still want to proceed?`
|
|
|
3020
3018
|
_: 3
|
|
3021
3019
|
}));
|
|
3022
3020
|
}
|
|
3023
|
-
}),
|
|
3021
|
+
}), qa = /* @__PURE__ */ h({
|
|
3024
3022
|
__name: "Toast",
|
|
3025
3023
|
props: {
|
|
3026
3024
|
message: {},
|
|
@@ -3029,14 +3027,15 @@ Do you still want to proceed?`
|
|
|
3029
3027
|
class: {}
|
|
3030
3028
|
},
|
|
3031
3029
|
setup(t, { expose: s }) {
|
|
3032
|
-
const e = c(() =>
|
|
3030
|
+
const e = c(() => pt(
|
|
3033
3031
|
{ baseClasses: t.class, variant: t.variant },
|
|
3034
3032
|
{
|
|
3035
3033
|
baseClasses: "flex items-center gap-2 rounded-md p-2 ring-1 shadow-lg border-gray-200",
|
|
3036
3034
|
variants: {
|
|
3037
3035
|
variant: {
|
|
3038
3036
|
secondary: "bg-gray-900 text-white ring-black",
|
|
3039
|
-
danger: "bg-red-50 text-red-900 ring-red-100"
|
|
3037
|
+
danger: "bg-red-50 text-red-900 ring-red-100",
|
|
3038
|
+
warning: "bg-yellow-50 text-yellow-900 ring-yellow-100"
|
|
3040
3039
|
}
|
|
3041
3040
|
},
|
|
3042
3041
|
defaultVariants: {
|
|
@@ -3044,110 +3043,98 @@ Do you still want to proceed?`
|
|
|
3044
3043
|
}
|
|
3045
3044
|
}
|
|
3046
3045
|
));
|
|
3047
|
-
return s(), (r, n) => (
|
|
3048
|
-
class:
|
|
3046
|
+
return s(), (r, n) => (o(), f(Ra, {
|
|
3047
|
+
class: C(e.value)
|
|
3049
3048
|
}, {
|
|
3050
|
-
default:
|
|
3051
|
-
r.message ? (
|
|
3049
|
+
default: m(() => [
|
|
3050
|
+
r.message ? (o(), f(z, {
|
|
3052
3051
|
key: 0,
|
|
3053
3052
|
text: r.message,
|
|
3054
3053
|
inline: ""
|
|
3055
|
-
}, null, 8, ["text"])) :
|
|
3056
|
-
(
|
|
3057
|
-
key:
|
|
3054
|
+
}, null, 8, ["text"])) : M("", !0),
|
|
3055
|
+
(o(!0), y(D, null, U(r.actions, (a, u) => (o(), f(I, {
|
|
3056
|
+
key: u,
|
|
3058
3057
|
action: a,
|
|
3059
3058
|
variant: r.variant,
|
|
3060
|
-
as:
|
|
3059
|
+
as: Rt
|
|
3061
3060
|
}, null, 8, ["action", "variant"]))), 128))
|
|
3062
3061
|
]),
|
|
3063
3062
|
_: 1
|
|
3064
3063
|
}, 8, ["class"]));
|
|
3065
3064
|
}
|
|
3066
|
-
}),
|
|
3065
|
+
}), Aa = { $ui: A }, Pa = {
|
|
3067
3066
|
async install(t, s) {
|
|
3068
3067
|
const e = {
|
|
3069
|
-
"alert-modal":
|
|
3070
|
-
"confirm-modal":
|
|
3071
|
-
"error-report-modal":
|
|
3072
|
-
"loading-modal":
|
|
3073
|
-
"prompt-modal":
|
|
3074
|
-
"startup-crash":
|
|
3075
|
-
toast:
|
|
3068
|
+
"alert-modal": bn,
|
|
3069
|
+
"confirm-modal": Sn,
|
|
3070
|
+
"error-report-modal": Gn,
|
|
3071
|
+
"loading-modal": oa,
|
|
3072
|
+
"prompt-modal": ga,
|
|
3073
|
+
"startup-crash": Ia,
|
|
3074
|
+
toast: qa,
|
|
3076
3075
|
...s.components
|
|
3077
3076
|
};
|
|
3078
3077
|
for (const [r, n] of Object.entries(e))
|
|
3079
|
-
|
|
3080
|
-
await
|
|
3078
|
+
A.registerComponent(r, n);
|
|
3079
|
+
await ke(t, Aa);
|
|
3081
3080
|
}
|
|
3082
3081
|
};
|
|
3083
|
-
async function
|
|
3082
|
+
async function Da(t, s = {}) {
|
|
3084
3083
|
var r;
|
|
3085
|
-
const e = [
|
|
3086
|
-
|
|
3084
|
+
const e = [an, _r, nn, Or, kr, Pa, ...s.plugins ?? []];
|
|
3085
|
+
P.instance = t, await rr(e, t, s), await ((r = s.install) == null ? void 0 : r.call(s, t)), await F.emit("application-ready");
|
|
3087
3086
|
}
|
|
3088
|
-
async function
|
|
3087
|
+
async function Zl(t, s = {}) {
|
|
3089
3088
|
var r;
|
|
3090
|
-
const e =
|
|
3091
|
-
|
|
3089
|
+
const e = Jt(t);
|
|
3090
|
+
Z() && (window.$aerogel = e), await Da(e, s), e.mount("#app"), (r = e._container) == null || r.classList.remove("loading"), await F.emit("application-mounted");
|
|
3092
3091
|
}
|
|
3093
|
-
const
|
|
3094
|
-
__name: "AppModals",
|
|
3095
|
-
setup(t) {
|
|
3096
|
-
const s = c(() => z.modals[0] ?? null);
|
|
3097
|
-
return (e, r) => s.value ? (u(), b("aside", Ca, [
|
|
3098
|
-
p(wt, {
|
|
3099
|
-
"child-index": 1,
|
|
3100
|
-
modal: s.value
|
|
3101
|
-
}, null, 8, ["modal"])
|
|
3102
|
-
])) : T("", !0);
|
|
3103
|
-
}
|
|
3104
|
-
}), Sa = /* @__PURE__ */ g({
|
|
3092
|
+
const Ba = /* @__PURE__ */ h({
|
|
3105
3093
|
__name: "AppToasts",
|
|
3106
3094
|
setup(t) {
|
|
3107
|
-
return (s, e) => (
|
|
3108
|
-
default:
|
|
3109
|
-
(
|
|
3095
|
+
return (s, e) => (o(), f(l(Us), null, {
|
|
3096
|
+
default: m(() => [
|
|
3097
|
+
(o(!0), y(D, null, U(s.$ui.toasts, (r) => (o(), f(ee(r.component), H({
|
|
3110
3098
|
id: r.id,
|
|
3111
|
-
key: r.id
|
|
3112
|
-
|
|
3113
|
-
|
|
3114
|
-
p(l(Hs), { class: "fixed right-0 bottom-0 z-50 flex flex-col items-end space-y-4 px-4 py-6 sm:p-6" })
|
|
3099
|
+
key: r.id
|
|
3100
|
+
}, { ref_for: !0 }, r.properties), null, 16, ["id"]))), 128)),
|
|
3101
|
+
d(l(Os), { class: "fixed right-0 bottom-0 z-50 flex flex-col items-end space-y-4 px-4 py-6 sm:p-6" })
|
|
3115
3102
|
]),
|
|
3116
3103
|
_: 1
|
|
3117
3104
|
}));
|
|
3118
3105
|
}
|
|
3119
|
-
}),
|
|
3106
|
+
}), ja = /* @__PURE__ */ h({
|
|
3120
3107
|
__name: "AppOverlays",
|
|
3121
3108
|
setup(t) {
|
|
3122
|
-
return (s, e) => (
|
|
3123
|
-
|
|
3124
|
-
|
|
3109
|
+
return (s, e) => (o(), y(D, null, [
|
|
3110
|
+
d(l(ys), { nested: "" }),
|
|
3111
|
+
d(Ba)
|
|
3125
3112
|
], 64));
|
|
3126
3113
|
}
|
|
3127
|
-
}),
|
|
3114
|
+
}), Fa = { class: "flex min-h-full flex-col text-base leading-tight font-normal text-gray-900 antialiased" }, Xl = /* @__PURE__ */ h({
|
|
3128
3115
|
__name: "AppLayout",
|
|
3129
3116
|
setup(t) {
|
|
3130
|
-
return (s, e) => (
|
|
3131
|
-
s.$errors.hasStartupErrors ?
|
|
3132
|
-
(
|
|
3133
|
-
]) :
|
|
3134
|
-
|
|
3117
|
+
return (s, e) => (o(), y("div", Fa, [
|
|
3118
|
+
s.$errors.hasStartupErrors ? $(s.$slots, "startup-crash", { key: 0 }, () => [
|
|
3119
|
+
(o(), f(ee(s.$ui.requireComponent("startup-crash"))))
|
|
3120
|
+
]) : $(s.$slots, "default", { key: 1 }),
|
|
3121
|
+
d(ja)
|
|
3135
3122
|
]));
|
|
3136
3123
|
}
|
|
3137
|
-
}),
|
|
3124
|
+
}), Ua = ["id", "name", "value", "required", "aria-invalid", "aria-describedby"], Oa = /* @__PURE__ */ h({
|
|
3138
3125
|
__name: "HeadlessInputTextArea",
|
|
3139
3126
|
setup(t) {
|
|
3140
|
-
const s =
|
|
3127
|
+
const s = te("$textAreaRef"), e = R(
|
|
3141
3128
|
"input",
|
|
3142
3129
|
"<HeadlessInputTextArea> must be a child of a <HeadlessInput>"
|
|
3143
3130
|
), r = c(() => e.name ?? void 0), n = c(() => e.value);
|
|
3144
3131
|
function a() {
|
|
3145
3132
|
s.value && e.update(s.value.value);
|
|
3146
3133
|
}
|
|
3147
|
-
return
|
|
3148
|
-
var
|
|
3149
|
-
return (
|
|
3150
|
-
}), (
|
|
3134
|
+
return mt(e, () => {
|
|
3135
|
+
var u;
|
|
3136
|
+
return (u = s.value) == null ? void 0 : u.focus();
|
|
3137
|
+
}), (u, i) => (o(), y("textarea", {
|
|
3151
3138
|
id: l(e).id,
|
|
3152
3139
|
ref: "$textAreaRef",
|
|
3153
3140
|
name: r.value,
|
|
@@ -3156,22 +3143,37 @@ const Ca = { key: 0 }, ka = /* @__PURE__ */ g({
|
|
|
3156
3143
|
"aria-invalid": l(e).errors ? "true" : "false",
|
|
3157
3144
|
"aria-describedby": l(e).errors ? `${l(e).id}-error` : l(e).description ? `${l(e).id}-description` : void 0,
|
|
3158
3145
|
onInput: a
|
|
3159
|
-
}, null, 40,
|
|
3146
|
+
}, null, 40, Ua));
|
|
3160
3147
|
}
|
|
3161
|
-
}),
|
|
3162
|
-
__name: "
|
|
3148
|
+
}), Na = { class: "group" }, Wa = { class: "-ml-2 flex w-[max-content] items-center rounded-lg py-2 pr-3 pl-1 hover:bg-gray-100 focus-visible:outline focus-visible:outline-gray-700" }, Ka = { class: "pt-2 pl-4" }, Qa = /* @__PURE__ */ h({
|
|
3149
|
+
__name: "Details",
|
|
3150
|
+
props: {
|
|
3151
|
+
label: {}
|
|
3152
|
+
},
|
|
3163
3153
|
setup(t) {
|
|
3164
|
-
return (s, e) => (
|
|
3165
|
-
|
|
3166
|
-
|
|
3167
|
-
|
|
3154
|
+
return (s, e) => (o(), y("details", Na, [
|
|
3155
|
+
b("summary", Wa, [
|
|
3156
|
+
d(l(Lt), { class: "size-6 transition-transform group-open:rotate-90" }),
|
|
3157
|
+
b("span", null, x(s.label), 1)
|
|
3168
3158
|
]),
|
|
3169
|
-
|
|
3170
|
-
|
|
3159
|
+
b("div", Ka, [
|
|
3160
|
+
$(s.$slots, "default")
|
|
3171
3161
|
])
|
|
3172
3162
|
]));
|
|
3173
3163
|
}
|
|
3174
|
-
}),
|
|
3164
|
+
}), Yl = /* @__PURE__ */ h({
|
|
3165
|
+
__name: "AdvancedOptions",
|
|
3166
|
+
setup(t) {
|
|
3167
|
+
return (s, e) => (o(), f(Qa, {
|
|
3168
|
+
label: s.$td("ui.advancedOptions", "Advanced options")
|
|
3169
|
+
}, {
|
|
3170
|
+
default: m(() => [
|
|
3171
|
+
$(s.$slots, "default")
|
|
3172
|
+
]),
|
|
3173
|
+
_: 3
|
|
3174
|
+
}, 8, ["label"]));
|
|
3175
|
+
}
|
|
3176
|
+
}), Ja = { class: "flex h-6 items-center" }, Gl = /* @__PURE__ */ h({
|
|
3175
3177
|
inheritAttrs: !1,
|
|
3176
3178
|
__name: "Checkbox",
|
|
3177
3179
|
props: {
|
|
@@ -3184,53 +3186,53 @@ const Ca = { key: 0 }, ka = /* @__PURE__ */ g({
|
|
|
3184
3186
|
},
|
|
3185
3187
|
emits: ["update:modelValue"],
|
|
3186
3188
|
setup(t) {
|
|
3187
|
-
const s =
|
|
3188
|
-
var
|
|
3189
|
-
return
|
|
3189
|
+
const s = K(t, ["inputClass", "labelClass"]), e = te("$inputRef"), [r, n] = Ae(), a = c(() => E("relative flex items-start", n.value)), u = c(() => {
|
|
3190
|
+
var p, g;
|
|
3191
|
+
return E(
|
|
3190
3192
|
"size-4 rounded text-primary-600 not-checked:hover:bg-gray-200 checked:hover:text-primary-500 checked:border-0",
|
|
3191
3193
|
{
|
|
3192
|
-
"border-gray-300 focus:ring-primary-600": !((
|
|
3193
|
-
"border-red-400 border-2 focus:ring-red-600": (
|
|
3194
|
+
"border-gray-300 focus:ring-primary-600": !((p = e.value) != null && p.errors),
|
|
3195
|
+
"border-red-400 border-2 focus:ring-red-600": (g = e.value) == null ? void 0 : g.errors
|
|
3194
3196
|
},
|
|
3195
3197
|
t.inputClass
|
|
3196
3198
|
);
|
|
3197
|
-
}),
|
|
3198
|
-
return (
|
|
3199
|
+
}), i = c(() => E("ml-2 text-sm leading-6", t.labelClass));
|
|
3200
|
+
return (p, g) => (o(), f(Be, H({
|
|
3199
3201
|
ref: "$inputRef",
|
|
3200
3202
|
class: a.value
|
|
3201
3203
|
}, s, {
|
|
3202
|
-
"onUpdate:modelValue":
|
|
3204
|
+
"onUpdate:modelValue": g[0] || (g[0] = (w) => p.$emit("update:modelValue", w))
|
|
3203
3205
|
}), {
|
|
3204
|
-
default:
|
|
3205
|
-
|
|
3206
|
-
|
|
3206
|
+
default: m(() => [
|
|
3207
|
+
b("div", Ja, [
|
|
3208
|
+
d(It, H(l(r), {
|
|
3207
3209
|
type: "checkbox",
|
|
3208
|
-
class:
|
|
3210
|
+
class: u.value
|
|
3209
3211
|
}), null, 16, ["class"])
|
|
3210
3212
|
]),
|
|
3211
|
-
|
|
3213
|
+
p.$slots.default ? (o(), y("div", {
|
|
3212
3214
|
key: 0,
|
|
3213
|
-
class:
|
|
3215
|
+
class: C(i.value)
|
|
3214
3216
|
}, [
|
|
3215
|
-
|
|
3216
|
-
default:
|
|
3217
|
-
|
|
3217
|
+
d(ye, { class: "text-gray-900" }, {
|
|
3218
|
+
default: m(() => [
|
|
3219
|
+
$(p.$slots, "default")
|
|
3218
3220
|
]),
|
|
3219
3221
|
_: 3
|
|
3220
3222
|
}),
|
|
3221
|
-
|
|
3222
|
-
], 2)) :
|
|
3223
|
+
d(we, { class: "text-red-600" })
|
|
3224
|
+
], 2)) : p.label ? (o(), y("div", {
|
|
3223
3225
|
key: 1,
|
|
3224
|
-
class:
|
|
3226
|
+
class: C(i.value)
|
|
3225
3227
|
}, [
|
|
3226
|
-
|
|
3227
|
-
|
|
3228
|
-
], 2)) :
|
|
3228
|
+
d(ye, { class: "text-gray-900" }),
|
|
3229
|
+
d(we, { class: "text-red-600" })
|
|
3230
|
+
], 2)) : M("", !0)
|
|
3229
3231
|
]),
|
|
3230
3232
|
_: 3
|
|
3231
3233
|
}, 16, ["class"]));
|
|
3232
3234
|
}
|
|
3233
|
-
}),
|
|
3235
|
+
}), Za = /* @__PURE__ */ h({
|
|
3234
3236
|
__name: "DropdownMenuOption",
|
|
3235
3237
|
props: {
|
|
3236
3238
|
class: {},
|
|
@@ -3239,40 +3241,40 @@ const Ca = { key: 0 }, ka = /* @__PURE__ */ g({
|
|
|
3239
3241
|
},
|
|
3240
3242
|
emits: ["select"],
|
|
3241
3243
|
setup(t) {
|
|
3242
|
-
const s =
|
|
3244
|
+
const s = K(t, ["class"]), e = c(() => E(
|
|
3243
3245
|
"flex w-full items-center gap-2 rounded-lg px-2 py-2 text-sm text-gray-900 data-[highlighted]:bg-gray-100",
|
|
3244
3246
|
t.class
|
|
3245
3247
|
));
|
|
3246
|
-
return (r, n) => (
|
|
3248
|
+
return (r, n) => (o(), f(l(Ns), H({ class: e.value }, s, {
|
|
3247
3249
|
onSelect: n[0] || (n[0] = (a) => r.$emit("select"))
|
|
3248
3250
|
}), {
|
|
3249
|
-
default:
|
|
3250
|
-
|
|
3251
|
+
default: m(() => [
|
|
3252
|
+
$(r.$slots, "default")
|
|
3251
3253
|
]),
|
|
3252
3254
|
_: 3
|
|
3253
3255
|
}, 16, ["class"]));
|
|
3254
3256
|
}
|
|
3255
|
-
}),
|
|
3257
|
+
}), Xa = /* @__PURE__ */ h({
|
|
3256
3258
|
__name: "DropdownMenuOptions",
|
|
3257
3259
|
setup(t) {
|
|
3258
|
-
const s =
|
|
3260
|
+
const s = R(
|
|
3259
3261
|
"dropdown-menu",
|
|
3260
3262
|
"<DropdownMenuOptions> must be a child of a <DropdownMenu>"
|
|
3261
3263
|
);
|
|
3262
|
-
return (e, r) => (
|
|
3264
|
+
return (e, r) => (o(), f(l(Ws), {
|
|
3263
3265
|
class: "gap-y-0.5 rounded-lg bg-white p-1.5 shadow-lg ring-1 ring-black/5",
|
|
3264
3266
|
align: l(s).align,
|
|
3265
3267
|
side: l(s).side
|
|
3266
3268
|
}, {
|
|
3267
|
-
default:
|
|
3268
|
-
|
|
3269
|
-
(
|
|
3269
|
+
default: m(() => [
|
|
3270
|
+
$(e.$slots, "default", {}, () => [
|
|
3271
|
+
(o(!0), y(D, null, U(l(s).options, (n, a) => (o(), f(Za, H(
|
|
3270
3272
|
{
|
|
3271
3273
|
key: a,
|
|
3272
|
-
as: n.route || n.href ?
|
|
3273
|
-
class: n.class
|
|
3274
|
-
ref_for: !0
|
|
3274
|
+
as: n.route || n.href ? $t : void 0,
|
|
3275
|
+
class: n.class
|
|
3275
3276
|
},
|
|
3277
|
+
{ ref_for: !0 },
|
|
3276
3278
|
n.route || n.href ? {
|
|
3277
3279
|
href: n.href,
|
|
3278
3280
|
route: n.route,
|
|
@@ -3280,14 +3282,14 @@ const Ca = { key: 0 }, ka = /* @__PURE__ */ g({
|
|
|
3280
3282
|
routeQuery: n.routeQuery
|
|
3281
3283
|
} : {},
|
|
3282
3284
|
{
|
|
3283
|
-
onSelect: (
|
|
3284
|
-
var
|
|
3285
|
-
return (
|
|
3285
|
+
onSelect: (u) => {
|
|
3286
|
+
var i;
|
|
3287
|
+
return (i = n.click) == null ? void 0 : i.call(n);
|
|
3286
3288
|
}
|
|
3287
3289
|
}
|
|
3288
3290
|
), {
|
|
3289
|
-
default:
|
|
3290
|
-
|
|
3291
|
+
default: m(() => [
|
|
3292
|
+
L(x(n.label), 1)
|
|
3291
3293
|
]),
|
|
3292
3294
|
_: 2
|
|
3293
3295
|
}, 1040, ["as", "class", "onSelect"]))), 128))
|
|
@@ -3296,7 +3298,7 @@ const Ca = { key: 0 }, ka = /* @__PURE__ */ g({
|
|
|
3296
3298
|
_: 3
|
|
3297
3299
|
}, 8, ["align", "side"]));
|
|
3298
3300
|
}
|
|
3299
|
-
}),
|
|
3301
|
+
}), eo = /* @__PURE__ */ h({
|
|
3300
3302
|
__name: "DropdownMenu",
|
|
3301
3303
|
props: {
|
|
3302
3304
|
align: {},
|
|
@@ -3312,18 +3314,18 @@ const Ca = { key: 0 }, ka = /* @__PURE__ */ g({
|
|
|
3312
3314
|
return (r = t.options) == null ? void 0 : r.filter(Boolean);
|
|
3313
3315
|
})
|
|
3314
3316
|
};
|
|
3315
|
-
return
|
|
3316
|
-
default:
|
|
3317
|
-
|
|
3318
|
-
default:
|
|
3319
|
-
|
|
3317
|
+
return pe("dropdown-menu", e), s(e), (r, n) => (o(), f(l(Ks), null, {
|
|
3318
|
+
default: m(() => [
|
|
3319
|
+
d(l(Qs), null, {
|
|
3320
|
+
default: m(() => [
|
|
3321
|
+
$(r.$slots, "default")
|
|
3320
3322
|
]),
|
|
3321
3323
|
_: 3
|
|
3322
3324
|
}),
|
|
3323
|
-
|
|
3324
|
-
default:
|
|
3325
|
-
|
|
3326
|
-
|
|
3325
|
+
d(l(Js), null, {
|
|
3326
|
+
default: m(() => [
|
|
3327
|
+
$(r.$slots, "options", {}, () => [
|
|
3328
|
+
d(Xa)
|
|
3327
3329
|
])
|
|
3328
3330
|
]),
|
|
3329
3331
|
_: 3
|
|
@@ -3332,7 +3334,7 @@ const Ca = { key: 0 }, ka = /* @__PURE__ */ g({
|
|
|
3332
3334
|
_: 3
|
|
3333
3335
|
}));
|
|
3334
3336
|
}
|
|
3335
|
-
}),
|
|
3337
|
+
}), Ya = ["aria-hidden"], Ga = ["tabindex", "aria-label", "type"], to = /* @__PURE__ */ h({
|
|
3336
3338
|
__name: "EditableContent",
|
|
3337
3339
|
props: {
|
|
3338
3340
|
type: { default: "text" },
|
|
@@ -3345,106 +3347,106 @@ const Ca = { key: 0 }, ka = /* @__PURE__ */ g({
|
|
|
3345
3347
|
},
|
|
3346
3348
|
emits: ["update", "save"],
|
|
3347
3349
|
setup(t, { emit: s }) {
|
|
3348
|
-
const e = s, r =
|
|
3349
|
-
function
|
|
3350
|
+
const e = s, r = te("$inputRef"), n = N(null), a = N(t.text), u = c(() => E("inline whitespace-pre", t.contentClass)), i = c(() => E("invisible whitespace-pre", t.contentClass)), p = c(() => E("absolute inset-0 h-full w-full resize-none border-0 bg-transparent p-0 focus:ring-0", t.contentClass));
|
|
3351
|
+
function g() {
|
|
3350
3352
|
n.value = t.text;
|
|
3351
3353
|
}
|
|
3352
|
-
function
|
|
3354
|
+
function w() {
|
|
3353
3355
|
n.value && (t.type !== "number" && a.value.trim().length === 0 && (a.value = n.value, e("update", a.value)), n.value = null, e("save"));
|
|
3354
3356
|
}
|
|
3355
|
-
return
|
|
3356
|
-
class:
|
|
3357
|
+
return G(() => a.value = t.text), (v, k) => (o(), y("div", {
|
|
3358
|
+
class: C(["relative", { "pointer-events-none!": v.disabled && !n.value }])
|
|
3357
3359
|
}, [
|
|
3358
|
-
n.value ? (
|
|
3360
|
+
n.value ? (o(), y("span", {
|
|
3359
3361
|
key: 1,
|
|
3360
|
-
class:
|
|
3361
|
-
}, x(a.value), 3)) : (
|
|
3362
|
+
class: C(i.value)
|
|
3363
|
+
}, x(a.value), 3)) : (o(), y("div", {
|
|
3362
3364
|
key: 0,
|
|
3363
|
-
class:
|
|
3365
|
+
class: C(u.value)
|
|
3364
3366
|
}, [
|
|
3365
|
-
|
|
3367
|
+
$(v.$slots, "default")
|
|
3366
3368
|
], 2)),
|
|
3367
|
-
|
|
3369
|
+
v.type === "number" ? (o(), y("span", {
|
|
3368
3370
|
key: 2,
|
|
3369
|
-
class:
|
|
3370
|
-
}, null, 2)) :
|
|
3371
|
-
|
|
3371
|
+
class: C(["inline-block transition-[width]", n.value ? "w-5" : "w-0"])
|
|
3372
|
+
}, null, 2)) : M("", !0),
|
|
3373
|
+
b("form", {
|
|
3372
3374
|
class: "w-full",
|
|
3373
|
-
"aria-hidden":
|
|
3374
|
-
onSubmit:
|
|
3375
|
-
var
|
|
3376
|
-
return (
|
|
3375
|
+
"aria-hidden": v.formAriaHidden,
|
|
3376
|
+
onSubmit: k[4] || (k[4] = rt((q) => {
|
|
3377
|
+
var Q;
|
|
3378
|
+
return (Q = r.value) == null ? void 0 : Q.blur();
|
|
3377
3379
|
}, ["prevent"]))
|
|
3378
3380
|
}, [
|
|
3379
|
-
|
|
3381
|
+
nt(b("input", {
|
|
3380
3382
|
ref: "$inputRef",
|
|
3381
|
-
"onUpdate:modelValue":
|
|
3382
|
-
tabindex:
|
|
3383
|
-
"aria-label":
|
|
3384
|
-
type:
|
|
3385
|
-
class:
|
|
3386
|
-
|
|
3387
|
-
{ "opacity-0": !n.value, "appearance-textfield": !n.value &&
|
|
3383
|
+
"onUpdate:modelValue": k[0] || (k[0] = (q) => a.value = q),
|
|
3384
|
+
tabindex: v.tabindex ?? void 0,
|
|
3385
|
+
"aria-label": v.ariaLabel ?? void 0,
|
|
3386
|
+
type: v.type,
|
|
3387
|
+
class: C([
|
|
3388
|
+
p.value,
|
|
3389
|
+
{ "opacity-0": !n.value, "appearance-textfield": !n.value && v.type === "number" }
|
|
3388
3390
|
]),
|
|
3389
|
-
onKeyup:
|
|
3390
|
-
onFocus:
|
|
3391
|
-
onBlur:
|
|
3392
|
-
}, null, 42,
|
|
3393
|
-
[
|
|
3391
|
+
onKeyup: k[1] || (k[1] = (q) => v.$emit("update", a.value)),
|
|
3392
|
+
onFocus: k[2] || (k[2] = (q) => g()),
|
|
3393
|
+
onBlur: k[3] || (k[3] = (q) => w())
|
|
3394
|
+
}, null, 42, Ga), [
|
|
3395
|
+
[Zt, a.value]
|
|
3394
3396
|
])
|
|
3395
|
-
], 40,
|
|
3397
|
+
], 40, Ya)
|
|
3396
3398
|
], 2));
|
|
3397
3399
|
}
|
|
3398
|
-
}),
|
|
3400
|
+
}), el = {
|
|
3399
3401
|
viewBox: "0 0 512 512",
|
|
3400
3402
|
width: "1.2em",
|
|
3401
3403
|
height: "1.2em"
|
|
3402
3404
|
};
|
|
3403
|
-
function
|
|
3404
|
-
return
|
|
3405
|
-
|
|
3405
|
+
function tl(t, s) {
|
|
3406
|
+
return o(), y("svg", el, s[0] || (s[0] = [
|
|
3407
|
+
b("path", {
|
|
3406
3408
|
fill: "currentColor",
|
|
3407
3409
|
d: "M449.07 399.08L278.64 82.58c-12.08-22.44-44.26-22.44-56.35 0L51.87 399.08A32 32 0 0 0 80 446.25h340.89a32 32 0 0 0 28.18-47.17m-198.6-1.83a20 20 0 1 1 20-20a20 20 0 0 1-20 20m21.72-201.15l-5.74 122a16 16 0 0 1-32 0l-5.74-121.95a21.73 21.73 0 0 1 21.5-22.69h.21a21.74 21.74 0 0 1 21.73 22.7Z"
|
|
3408
3410
|
}, null, -1)
|
|
3409
3411
|
]));
|
|
3410
3412
|
}
|
|
3411
|
-
const
|
|
3413
|
+
const sl = V({ name: "ion-warning", render: tl }), rl = {
|
|
3412
3414
|
viewBox: "0 0 20 20",
|
|
3413
3415
|
width: "1.2em",
|
|
3414
3416
|
height: "1.2em"
|
|
3415
3417
|
};
|
|
3416
|
-
function
|
|
3417
|
-
return
|
|
3418
|
-
|
|
3418
|
+
function nl(t, s) {
|
|
3419
|
+
return o(), y("svg", rl, s[0] || (s[0] = [
|
|
3420
|
+
b("path", {
|
|
3419
3421
|
fill: "currentColor",
|
|
3420
3422
|
d: "M.2 10a11 11 0 0 1 19.6 0A11 11 0 0 1 .2 10m9.8 4a4 4 0 1 0 0-8a4 4 0 0 0 0 8m0-2a2 2 0 1 1 0-4a2 2 0 0 1 0 4"
|
|
3421
3423
|
}, null, -1)
|
|
3422
3424
|
]));
|
|
3423
3425
|
}
|
|
3424
|
-
const
|
|
3426
|
+
const al = V({ name: "zondicons-view-show", render: nl }), ll = { class: "font-medium" }, ol = ["datetime"], il = /* @__PURE__ */ h({
|
|
3425
3427
|
__name: "ErrorLogsModal",
|
|
3426
3428
|
setup(t) {
|
|
3427
|
-
return (s, e) => (
|
|
3429
|
+
return (s, e) => (o(), f(ne, {
|
|
3428
3430
|
title: s.$td("errors.report", "Errors ({count})", { count: s.$errors.logs.length })
|
|
3429
3431
|
}, {
|
|
3430
|
-
default:
|
|
3431
|
-
|
|
3432
|
-
(
|
|
3432
|
+
default: m(() => [
|
|
3433
|
+
b("ol", null, [
|
|
3434
|
+
(o(!0), y(D, null, U(s.$errors.logs, (r, n) => (o(), y("li", {
|
|
3433
3435
|
key: n,
|
|
3434
3436
|
class: "mb-2 flex max-w-prose min-w-56 justify-between py-2 last:mb-0"
|
|
3435
3437
|
}, [
|
|
3436
|
-
|
|
3437
|
-
|
|
3438
|
-
|
|
3438
|
+
b("div", null, [
|
|
3439
|
+
b("h3", ll, x(r.report.title), 1),
|
|
3440
|
+
b("time", {
|
|
3439
3441
|
datetime: r.date.toISOString(),
|
|
3440
3442
|
class: "text-xs text-gray-700"
|
|
3441
|
-
}, x(r.date.toLocaleTimeString()), 9,
|
|
3442
|
-
|
|
3443
|
+
}, x(r.date.toLocaleTimeString()), 9, ol),
|
|
3444
|
+
d(z, {
|
|
3443
3445
|
class: "text-sm text-gray-500",
|
|
3444
|
-
text: r.report.description ?? l(
|
|
3446
|
+
text: r.report.description ?? l(Ht)(r.report)
|
|
3445
3447
|
}, null, 8, ["text"])
|
|
3446
3448
|
]),
|
|
3447
|
-
|
|
3449
|
+
d(I, {
|
|
3448
3450
|
size: "icon",
|
|
3449
3451
|
variant: "ghost",
|
|
3450
3452
|
"aria-label": s.$td("errors.viewDetails", "View details"),
|
|
@@ -3452,11 +3454,11 @@ const Oa = E({ name: "zondicons-view-show", render: Ua }), Na = { class: "font-m
|
|
|
3452
3454
|
class: "self-center",
|
|
3453
3455
|
onClick: (a) => s.$errors.inspect(
|
|
3454
3456
|
r.report,
|
|
3455
|
-
s.$errors.logs.map(({ report:
|
|
3457
|
+
s.$errors.logs.map(({ report: u }) => u)
|
|
3456
3458
|
)
|
|
3457
3459
|
}, {
|
|
3458
|
-
default:
|
|
3459
|
-
|
|
3460
|
+
default: m(() => [
|
|
3461
|
+
d(l(al), {
|
|
3460
3462
|
class: "size-4",
|
|
3461
3463
|
"aria-hidden": "true"
|
|
3462
3464
|
})
|
|
@@ -3469,36 +3471,36 @@ const Oa = E({ name: "zondicons-view-show", render: Ua }), Na = { class: "font-m
|
|
|
3469
3471
|
_: 1
|
|
3470
3472
|
}, 8, ["title"]));
|
|
3471
3473
|
}
|
|
3472
|
-
}),
|
|
3474
|
+
}), so = /* @__PURE__ */ h({
|
|
3473
3475
|
__name: "ErrorLogs",
|
|
3474
3476
|
setup(t) {
|
|
3475
|
-
return (s, e) => s.$errors.logs.length > 0 ? (
|
|
3477
|
+
return (s, e) => s.$errors.logs.length > 0 ? (o(), f(I, {
|
|
3476
3478
|
key: 0,
|
|
3477
3479
|
size: "icon",
|
|
3478
3480
|
variant: "ghost",
|
|
3479
3481
|
title: s.$td("errors.viewLogs", "View error logs"),
|
|
3480
3482
|
"aria-label": s.$td("errors.viewLogs", "View error logs"),
|
|
3481
|
-
onClick: e[0] || (e[0] = (r) => s.$ui.modal(
|
|
3483
|
+
onClick: e[0] || (e[0] = (r) => s.$ui.modal(il))
|
|
3482
3484
|
}, {
|
|
3483
|
-
default:
|
|
3484
|
-
|
|
3485
|
+
default: m(() => [
|
|
3486
|
+
d(l(sl), { class: "size-6 text-red-500" })
|
|
3485
3487
|
]),
|
|
3486
3488
|
_: 1
|
|
3487
|
-
}, 8, ["title", "aria-label"])) :
|
|
3489
|
+
}, 8, ["title", "aria-label"])) : M("", !0);
|
|
3488
3490
|
}
|
|
3489
|
-
}),
|
|
3491
|
+
}), ro = /* @__PURE__ */ h({
|
|
3490
3492
|
__name: "ErrorMessage",
|
|
3491
3493
|
props: {
|
|
3492
3494
|
error: {}
|
|
3493
3495
|
},
|
|
3494
3496
|
setup(t) {
|
|
3495
|
-
const s = c(() =>
|
|
3496
|
-
return (e, r) => (
|
|
3497
|
+
const s = c(() => Ht(t.error));
|
|
3498
|
+
return (e, r) => (o(), f(z, {
|
|
3497
3499
|
text: s.value,
|
|
3498
3500
|
inline: ""
|
|
3499
3501
|
}, null, 8, ["text"]));
|
|
3500
3502
|
}
|
|
3501
|
-
}),
|
|
3503
|
+
}), no = /* @__PURE__ */ h({
|
|
3502
3504
|
__name: "Link",
|
|
3503
3505
|
props: {
|
|
3504
3506
|
class: {},
|
|
@@ -3513,30 +3515,30 @@ const Oa = E({ name: "zondicons-view-show", render: Ua }), Na = { class: "font-m
|
|
|
3513
3515
|
as: {}
|
|
3514
3516
|
},
|
|
3515
3517
|
setup(t) {
|
|
3516
|
-
return (s, e) => (
|
|
3517
|
-
default:
|
|
3518
|
-
|
|
3518
|
+
return (s, e) => (o(), f(I, H({ variant: "link" }, s.$props), {
|
|
3519
|
+
default: m(() => [
|
|
3520
|
+
$(s.$slots, "default")
|
|
3519
3521
|
]),
|
|
3520
3522
|
_: 3
|
|
3521
3523
|
}, 16));
|
|
3522
3524
|
}
|
|
3523
|
-
}),
|
|
3525
|
+
}), ao = /* @__PURE__ */ h({
|
|
3524
3526
|
__name: "SettingsModal",
|
|
3525
3527
|
setup(t) {
|
|
3526
|
-
const s = c(() =>
|
|
3527
|
-
return (e, r) => (
|
|
3528
|
+
const s = c(() => os(P.settings, "priority", "desc"));
|
|
3529
|
+
return (e, r) => (o(), f(ne, {
|
|
3528
3530
|
title: e.$td("settings.title", "Settings")
|
|
3529
3531
|
}, {
|
|
3530
|
-
default:
|
|
3531
|
-
(
|
|
3532
|
+
default: m(() => [
|
|
3533
|
+
(o(!0), y(D, null, U(s.value, (n, a) => (o(), f(ee(n.component), { key: a }))), 128))
|
|
3532
3534
|
]),
|
|
3533
3535
|
_: 1
|
|
3534
3536
|
}, 8, ["title"]));
|
|
3535
3537
|
}
|
|
3536
|
-
}),
|
|
3538
|
+
}), ul = {
|
|
3537
3539
|
key: 0,
|
|
3538
3540
|
class: "pointer-events-none absolute inset-y-0 right-0 flex items-center pr-3"
|
|
3539
|
-
},
|
|
3541
|
+
}, lo = /* @__PURE__ */ h({
|
|
3540
3542
|
inheritAttrs: !1,
|
|
3541
3543
|
__name: "TextArea",
|
|
3542
3544
|
props: {
|
|
@@ -3549,47 +3551,47 @@ const Oa = E({ name: "zondicons-view-show", render: Ua }), Na = { class: "font-m
|
|
|
3549
3551
|
},
|
|
3550
3552
|
emits: ["update:modelValue"],
|
|
3551
3553
|
setup(t) {
|
|
3552
|
-
const s =
|
|
3553
|
-
var
|
|
3554
|
-
return
|
|
3554
|
+
const s = K(t, ["label", "inputClass", "wrapperClass"]), e = te("$inputRef"), [r, n] = Ae(), a = c(() => E("relative rounded-md shadow-2xs", { "mt-1": t.label }, t.wrapperClass)), u = c(() => {
|
|
3555
|
+
var i, p, g;
|
|
3556
|
+
return E(
|
|
3555
3557
|
// eslint-disable-next-line vue/max-len
|
|
3556
3558
|
"block w-full rounded-md border-0 py-1.5 ring-1 ring-inset focus:ring-2 focus:ring-inset sm:text-sm sm:leading-6",
|
|
3557
3559
|
{
|
|
3558
|
-
"focus:ring-primary-600": !((
|
|
3559
|
-
"text-gray-900 shadow-2xs ring-gray-900/10 placeholder:text-gray-400": !((
|
|
3560
|
-
"pr-10 text-red-900 ring-red-900/10 placeholder:text-red-300 focus:ring-red-500": (
|
|
3560
|
+
"focus:ring-primary-600": !((i = e.value) != null && i.errors),
|
|
3561
|
+
"text-gray-900 shadow-2xs ring-gray-900/10 placeholder:text-gray-400": !((p = e.value) != null && p.errors),
|
|
3562
|
+
"pr-10 text-red-900 ring-red-900/10 placeholder:text-red-300 focus:ring-red-500": (g = e.value) == null ? void 0 : g.errors
|
|
3561
3563
|
},
|
|
3562
3564
|
t.inputClass
|
|
3563
3565
|
);
|
|
3564
3566
|
});
|
|
3565
|
-
return (
|
|
3567
|
+
return (i, p) => (o(), f(Be, H({
|
|
3566
3568
|
ref: "$inputRef",
|
|
3567
|
-
label:
|
|
3569
|
+
label: i.label,
|
|
3568
3570
|
class: l(n)
|
|
3569
3571
|
}, s, {
|
|
3570
|
-
"onUpdate:modelValue":
|
|
3572
|
+
"onUpdate:modelValue": p[0] || (p[0] = (g) => i.$emit("update:modelValue", g))
|
|
3571
3573
|
}), {
|
|
3572
|
-
default:
|
|
3573
|
-
var
|
|
3574
|
+
default: m(() => {
|
|
3575
|
+
var g;
|
|
3574
3576
|
return [
|
|
3575
|
-
|
|
3576
|
-
|
|
3577
|
-
class:
|
|
3577
|
+
d(ye, { class: "block text-sm leading-6 font-medium text-gray-900" }),
|
|
3578
|
+
b("div", {
|
|
3579
|
+
class: C(a.value)
|
|
3578
3580
|
}, [
|
|
3579
|
-
|
|
3580
|
-
(
|
|
3581
|
-
|
|
3582
|
-
])) :
|
|
3581
|
+
d(Oa, H(l(r), { class: u.value }), null, 16, ["class"]),
|
|
3582
|
+
(g = e.value) != null && g.errors ? (o(), y("div", ul, [
|
|
3583
|
+
d(l(De), { class: "size-5 text-red-500" })
|
|
3584
|
+
])) : M("", !0)
|
|
3583
3585
|
], 2),
|
|
3584
|
-
|
|
3585
|
-
|
|
3586
|
+
d(zt, { class: "mt-2 text-sm text-gray-600" }),
|
|
3587
|
+
d(we, { class: "mt-2 text-sm text-red-600" })
|
|
3586
3588
|
];
|
|
3587
3589
|
}),
|
|
3588
3590
|
_: 1
|
|
3589
3591
|
}, 16, ["label", "class"]));
|
|
3590
3592
|
}
|
|
3591
3593
|
});
|
|
3592
|
-
class
|
|
3594
|
+
class oo {
|
|
3593
3595
|
constructor() {
|
|
3594
3596
|
_(this, "status");
|
|
3595
3597
|
_(this, "_listeners");
|
|
@@ -3597,22 +3599,22 @@ class Ul {
|
|
|
3597
3599
|
_(this, "_cancelled");
|
|
3598
3600
|
_(this, "_started");
|
|
3599
3601
|
_(this, "_completed");
|
|
3600
|
-
this.status = this.getInitialStatus(), this._listeners = new
|
|
3602
|
+
this.status = this.getInitialStatus(), this._listeners = new is(), this._started = new J(), this._completed = new J();
|
|
3601
3603
|
}
|
|
3602
3604
|
async start() {
|
|
3603
3605
|
this.beforeStart(), this._started.resolve();
|
|
3604
3606
|
try {
|
|
3605
3607
|
await this.updateProgress(), await this.run(), await this.updateProgress(), this._completed.resolve();
|
|
3606
3608
|
} catch (s) {
|
|
3607
|
-
if (s instanceof
|
|
3609
|
+
if (s instanceof et)
|
|
3608
3610
|
return;
|
|
3609
|
-
throw
|
|
3611
|
+
throw se(us(s), (e) => {
|
|
3610
3612
|
this._completed.reject(e);
|
|
3611
3613
|
});
|
|
3612
3614
|
}
|
|
3613
3615
|
}
|
|
3614
3616
|
async cancel() {
|
|
3615
|
-
this._cancelled = new
|
|
3617
|
+
this._cancelled = new J(), await this._cancelled;
|
|
3616
3618
|
}
|
|
3617
3619
|
serialize() {
|
|
3618
3620
|
return this.serializeStatus(this.status);
|
|
@@ -3647,10 +3649,10 @@ class Ul {
|
|
|
3647
3649
|
}
|
|
3648
3650
|
assertNotCancelled() {
|
|
3649
3651
|
if (this._cancelled)
|
|
3650
|
-
throw this._cancelled.resolve(), new
|
|
3652
|
+
throw this._cancelled.resolve(), new et();
|
|
3651
3653
|
}
|
|
3652
3654
|
calculateCurrentProgress(s) {
|
|
3653
|
-
return s ?? (s = this.status), s.completed ? 1 : s.children ?
|
|
3655
|
+
return s ?? (s = this.status), s.completed ? 1 : s.children ? cs(
|
|
3654
3656
|
s.children.reduce((e, r) => e + this.calculateCurrentProgress(r), 0) / s.children.length,
|
|
3655
3657
|
2
|
|
3656
3658
|
) : 0;
|
|
@@ -3664,148 +3666,158 @@ class Ul {
|
|
|
3664
3666
|
return { ...s };
|
|
3665
3667
|
}
|
|
3666
3668
|
}
|
|
3667
|
-
async function
|
|
3669
|
+
async function io(t) {
|
|
3668
3670
|
await t.start();
|
|
3669
3671
|
}
|
|
3670
3672
|
export {
|
|
3671
|
-
|
|
3672
|
-
|
|
3673
|
-
|
|
3674
|
-
|
|
3675
|
-
|
|
3676
|
-
|
|
3677
|
-
|
|
3678
|
-
|
|
3679
|
-
|
|
3680
|
-
|
|
3681
|
-
|
|
3682
|
-
|
|
3683
|
-
|
|
3684
|
-
|
|
3685
|
-
|
|
3686
|
-
|
|
3687
|
-
|
|
3688
|
-
|
|
3689
|
-
|
|
3690
|
-
|
|
3691
|
-
|
|
3692
|
-
|
|
3693
|
-
|
|
3694
|
-
|
|
3695
|
-
|
|
3696
|
-
|
|
3697
|
-
|
|
3698
|
-
|
|
3699
|
-
|
|
3700
|
-
|
|
3701
|
-
|
|
3702
|
-
|
|
3703
|
-
|
|
3704
|
-
|
|
3705
|
-
|
|
3706
|
-
|
|
3707
|
-
|
|
3708
|
-
|
|
3709
|
-
|
|
3710
|
-
|
|
3711
|
-
|
|
3712
|
-
|
|
3713
|
-
|
|
3714
|
-
|
|
3715
|
-
|
|
3716
|
-
|
|
3717
|
-
|
|
3718
|
-
|
|
3719
|
-
|
|
3720
|
-
|
|
3721
|
-
|
|
3722
|
-
|
|
3723
|
-
|
|
3724
|
-
|
|
3725
|
-
|
|
3726
|
-
|
|
3727
|
-
|
|
3728
|
-
|
|
3729
|
-
|
|
3730
|
-
|
|
3731
|
-
|
|
3732
|
-
|
|
3733
|
-
|
|
3734
|
-
|
|
3735
|
-
|
|
3736
|
-
|
|
3737
|
-
|
|
3738
|
-
|
|
3739
|
-
|
|
3740
|
-
|
|
3741
|
-
|
|
3742
|
-
|
|
3743
|
-
|
|
3744
|
-
|
|
3745
|
-
|
|
3746
|
-
|
|
3747
|
-
|
|
3748
|
-
|
|
3749
|
-
|
|
3750
|
-
|
|
3751
|
-
|
|
3752
|
-
|
|
3753
|
-
$
|
|
3754
|
-
|
|
3755
|
-
|
|
3756
|
-
|
|
3757
|
-
|
|
3758
|
-
|
|
3759
|
-
|
|
3760
|
-
|
|
3761
|
-
|
|
3762
|
-
|
|
3763
|
-
|
|
3764
|
-
|
|
3765
|
-
|
|
3766
|
-
|
|
3767
|
-
|
|
3768
|
-
|
|
3769
|
-
|
|
3770
|
-
|
|
3771
|
-
|
|
3772
|
-
|
|
3773
|
-
|
|
3774
|
-
|
|
3775
|
-
|
|
3776
|
-
|
|
3777
|
-
|
|
3778
|
-
|
|
3779
|
-
|
|
3780
|
-
|
|
3781
|
-
|
|
3782
|
-
|
|
3783
|
-
|
|
3784
|
-
|
|
3785
|
-
|
|
3786
|
-
|
|
3787
|
-
|
|
3788
|
-
|
|
3789
|
-
|
|
3790
|
-
|
|
3791
|
-
|
|
3792
|
-
|
|
3793
|
-
|
|
3794
|
-
|
|
3795
|
-
|
|
3796
|
-
|
|
3673
|
+
Yl as AdvancedOptions,
|
|
3674
|
+
bn as AlertModal,
|
|
3675
|
+
P as App,
|
|
3676
|
+
Xl as AppLayout,
|
|
3677
|
+
ja as AppOverlays,
|
|
3678
|
+
sr as AppService,
|
|
3679
|
+
Ba as AppToasts,
|
|
3680
|
+
I as Button,
|
|
3681
|
+
ql as Cache,
|
|
3682
|
+
xr as CacheService,
|
|
3683
|
+
Gl as Checkbox,
|
|
3684
|
+
Sn as ConfirmModal,
|
|
3685
|
+
Qa as Details,
|
|
3686
|
+
eo as DropdownMenu,
|
|
3687
|
+
Za as DropdownMenuOption,
|
|
3688
|
+
Xa as DropdownMenuOptions,
|
|
3689
|
+
to as EditableContent,
|
|
3690
|
+
so as ErrorLogs,
|
|
3691
|
+
il as ErrorLogsModal,
|
|
3692
|
+
ro as ErrorMessage,
|
|
3693
|
+
Gn as ErrorReportModal,
|
|
3694
|
+
On as ErrorReportModalButtons,
|
|
3695
|
+
Nn as ErrorReportModalTitle,
|
|
3696
|
+
wt as Errors,
|
|
3697
|
+
Cl as EventListenerPriorities,
|
|
3698
|
+
F as Events,
|
|
3699
|
+
er as EventsService,
|
|
3700
|
+
Vt as Form,
|
|
3701
|
+
pr as FormController,
|
|
3702
|
+
$t as HeadlessButton,
|
|
3703
|
+
Be as HeadlessInput,
|
|
3704
|
+
zt as HeadlessInputDescription,
|
|
3705
|
+
we as HeadlessInputError,
|
|
3706
|
+
It as HeadlessInputInput,
|
|
3707
|
+
ye as HeadlessInputLabel,
|
|
3708
|
+
Oa as HeadlessInputTextArea,
|
|
3709
|
+
cn as HeadlessModal,
|
|
3710
|
+
dn as HeadlessModalContent,
|
|
3711
|
+
pn as HeadlessModalDescription,
|
|
3712
|
+
mn as HeadlessModalOverlay,
|
|
3713
|
+
fn as HeadlessModalTitle,
|
|
3714
|
+
Rr as HeadlessSelect,
|
|
3715
|
+
Ye as HeadlessSelectLabel,
|
|
3716
|
+
Ct as HeadlessSelectOption,
|
|
3717
|
+
St as HeadlessSelectOptions,
|
|
3718
|
+
xt as HeadlessSelectTrigger,
|
|
3719
|
+
_t as HeadlessSelectValue,
|
|
3720
|
+
Xr as HeadlessSwitch,
|
|
3721
|
+
Ra as HeadlessToast,
|
|
3722
|
+
pa as Input,
|
|
3723
|
+
oo as Job,
|
|
3724
|
+
et as JobCancelledError,
|
|
3725
|
+
Ze as LOCAL_TIMEZONE_OFFSET,
|
|
3726
|
+
X as Lang,
|
|
3727
|
+
be as Layouts,
|
|
3728
|
+
no as Link,
|
|
3729
|
+
oa as LoadingModal,
|
|
3730
|
+
yr as MINUTE_MILLISECONDS,
|
|
3731
|
+
vt as MOBILE_BREAKPOINT,
|
|
3732
|
+
z as Markdown,
|
|
3733
|
+
ne as Modal,
|
|
3734
|
+
po as ModalComponent,
|
|
3735
|
+
mo as ModalsPortal,
|
|
3736
|
+
aa as ProgressBar,
|
|
3737
|
+
ga as PromptModal,
|
|
3738
|
+
Dr as Select,
|
|
3739
|
+
kt as SelectLabel,
|
|
3740
|
+
Ge as SelectOption,
|
|
3741
|
+
Tt as SelectOptions,
|
|
3742
|
+
Mt as SelectTrigger,
|
|
3743
|
+
Se as Service,
|
|
3744
|
+
Ve as ServiceBootError,
|
|
3745
|
+
Jr as Setting,
|
|
3746
|
+
ao as SettingsModal,
|
|
3747
|
+
Ia as StartupCrash,
|
|
3748
|
+
gt as Storage,
|
|
3749
|
+
Yr as Switch,
|
|
3750
|
+
lo as TextArea,
|
|
3751
|
+
qa as Toast,
|
|
3752
|
+
A as UI,
|
|
3753
|
+
Mr as UIService,
|
|
3754
|
+
Hl as __valueType,
|
|
3755
|
+
$r as aerogelDirectives,
|
|
3756
|
+
Zs as appNamespace,
|
|
3757
|
+
Dl as booleanInput,
|
|
3758
|
+
ke as bootServices,
|
|
3759
|
+
Zl as bootstrap,
|
|
3760
|
+
Da as bootstrapApplication,
|
|
3761
|
+
E as classes,
|
|
3762
|
+
fo as closeModal,
|
|
3763
|
+
Il as computedAsync,
|
|
3764
|
+
zl as computedDebounce,
|
|
3765
|
+
ho as createModal,
|
|
3766
|
+
Bl as dateInput,
|
|
3767
|
+
Tl as defineDirective,
|
|
3768
|
+
El as defineFormValidationRule,
|
|
3769
|
+
kl as definePlugin,
|
|
3770
|
+
Ce as defineServiceState,
|
|
3771
|
+
Gs as defineServiceStore,
|
|
3772
|
+
Sl as defineSettings,
|
|
3773
|
+
io as dispatch,
|
|
3774
|
+
jl as enumInput,
|
|
3775
|
+
bt as getCurrentLayout,
|
|
3776
|
+
Ht as getErrorMessage,
|
|
3777
|
+
vr as getMarkdownRouter,
|
|
3778
|
+
Ys as getPiniaStore,
|
|
3779
|
+
zr as hasSelectOptionLabel,
|
|
3780
|
+
go as injectModal,
|
|
3781
|
+
lr as injectOrFail,
|
|
3782
|
+
ar as injectReactive,
|
|
3783
|
+
R as injectReactiveOrFail,
|
|
3784
|
+
rr as installPlugins,
|
|
3785
|
+
vo as modals,
|
|
3786
|
+
Kl as numberInput,
|
|
3787
|
+
Ql as objectInput,
|
|
3788
|
+
Vl as onCleanMounted,
|
|
3789
|
+
mt as onFormFocus,
|
|
3790
|
+
Ll as persistent,
|
|
3791
|
+
mr as reactiveSet,
|
|
3792
|
+
Pl as registerErrorHandler,
|
|
3793
|
+
br as renderMarkdown,
|
|
3794
|
+
dt as renderVNode,
|
|
3795
|
+
Al as replaceExisting,
|
|
3796
|
+
Fl as requiredBooleanInput,
|
|
3797
|
+
Ul as requiredDateInput,
|
|
3798
|
+
Ol as requiredEnumInput,
|
|
3799
|
+
Nl as requiredNumberInput,
|
|
3800
|
+
Wl as requiredObjectInput,
|
|
3801
|
+
ma as requiredStringInput,
|
|
3802
|
+
Xs as resetPiniaStore,
|
|
3803
|
+
ht as safeHtml,
|
|
3804
|
+
Rl as setMarkdownRouter,
|
|
3805
|
+
bo as showModal,
|
|
3806
|
+
Jl as stringInput,
|
|
3807
|
+
yt as translate,
|
|
3797
3808
|
S as translateWithDefault,
|
|
3798
|
-
|
|
3799
|
-
|
|
3800
|
-
|
|
3801
|
-
|
|
3802
|
-
|
|
3803
|
-
|
|
3804
|
-
|
|
3805
|
-
|
|
3806
|
-
|
|
3807
|
-
|
|
3808
|
-
|
|
3809
|
-
|
|
3809
|
+
vn as useAlertModal,
|
|
3810
|
+
yn as useConfirmModal,
|
|
3811
|
+
Wn as useErrorReportModal,
|
|
3812
|
+
Ml as useEvent,
|
|
3813
|
+
ft as useForm,
|
|
3814
|
+
Ae as useInputAttrs,
|
|
3815
|
+
la as useLoadingModal,
|
|
3816
|
+
Pe as useModal,
|
|
3817
|
+
fa as usePromptModal,
|
|
3818
|
+
dr as validate,
|
|
3819
|
+
cr as validateType,
|
|
3820
|
+
ge as validators,
|
|
3821
|
+
pt as variantClasses
|
|
3810
3822
|
};
|
|
3811
3823
|
//# sourceMappingURL=aerogel-core.js.map
|