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