bt-core-app 1.4.87 → 1.4.88
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/bt-core-app.js +654 -644
- package/package.json +1 -1
package/dist/bt-core-app.js
CHANGED
|
@@ -1,28 +1,28 @@
|
|
|
1
|
-
import { ref as z, shallowRef as Re, computed as te, toValue as K, watch as
|
|
2
|
-
import { watchArray as Or, useStorage as
|
|
1
|
+
import { ref as z, shallowRef as Re, computed as te, toValue as K, watch as _e, toRef as Yt, onMounted as Xr, openBlock as Zt, createElementBlock as Jt } from "vue";
|
|
2
|
+
import { watchArray as Or, useStorage as jt, useEventListener as me, toValue as Ae, useParentElement as Kt, useResizeObserver as Qt, useArrayUnique as Xt, useArrayDifference as Gr, watchDebounced as Ot, tryOnMounted as pt } from "@vueuse/core";
|
|
3
3
|
import { defineStore as pr } from "pinia";
|
|
4
4
|
import { DateTime as he } from "luxon";
|
|
5
5
|
import { useRouter as Mr, useRoute as et } from "vue-router";
|
|
6
|
-
function
|
|
7
|
-
return (e || "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx").replace(/[xy]/g,
|
|
6
|
+
function en(e) {
|
|
7
|
+
return (e || "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx").replace(/[xy]/g, rn);
|
|
8
8
|
}
|
|
9
|
-
function
|
|
9
|
+
function rn(e) {
|
|
10
10
|
const t = Math.random() * 16 | 0;
|
|
11
11
|
return (e == "x" ? t : t & 3 | 8).toString(16);
|
|
12
12
|
}
|
|
13
|
-
function
|
|
14
|
-
const t = z([]), l = Re(), S = Re(),
|
|
13
|
+
function tn(e) {
|
|
14
|
+
const t = z([]), l = Re(), S = Re(), f = Re(), g = te(() => l.value != null);
|
|
15
15
|
function x(d) {
|
|
16
16
|
t.value = t.value.filter((h) => h.id != d);
|
|
17
17
|
}
|
|
18
18
|
function P(d) {
|
|
19
19
|
const h = {
|
|
20
|
-
id:
|
|
20
|
+
id: en(),
|
|
21
21
|
msg: d ?? "Loading"
|
|
22
22
|
};
|
|
23
23
|
return t.value.push(h), h.id;
|
|
24
24
|
}
|
|
25
|
-
function
|
|
25
|
+
function T(d) {
|
|
26
26
|
d != null && (S.value = d.toString());
|
|
27
27
|
}
|
|
28
28
|
function N() {
|
|
@@ -34,14 +34,14 @@ function en(e) {
|
|
|
34
34
|
const r = P(u.loadingMsg);
|
|
35
35
|
let y = null;
|
|
36
36
|
try {
|
|
37
|
-
return u.requireConfirmation || u.confirmationMsg, y = await d(), u.completionMsg != null && (
|
|
37
|
+
return u.requireConfirmation || u.confirmationMsg, y = await d(), u.completionMsg != null && (f.value = u.completionMsg), y;
|
|
38
38
|
} catch (I) {
|
|
39
39
|
if ((e == null ? void 0 : e.onError) != null)
|
|
40
40
|
e.onError(I);
|
|
41
41
|
else {
|
|
42
42
|
if (u.throwError == !0)
|
|
43
43
|
return I;
|
|
44
|
-
|
|
44
|
+
T(u.errorMsg ?? I ?? "error");
|
|
45
45
|
}
|
|
46
46
|
} finally {
|
|
47
47
|
x(r);
|
|
@@ -52,49 +52,49 @@ function en(e) {
|
|
|
52
52
|
}, { deep: !0 }), {
|
|
53
53
|
actionErrorMsg: S,
|
|
54
54
|
actionLoadingMsg: l,
|
|
55
|
-
actionCompleteMsg:
|
|
55
|
+
actionCompleteMsg: f,
|
|
56
56
|
clearErrors: N,
|
|
57
57
|
doAction: $,
|
|
58
58
|
isLoading: g,
|
|
59
|
-
logError:
|
|
59
|
+
logError: T
|
|
60
60
|
};
|
|
61
61
|
}
|
|
62
62
|
var Qe = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
63
|
-
function
|
|
63
|
+
function nn(e) {
|
|
64
64
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
65
65
|
}
|
|
66
66
|
var Ue = function() {
|
|
67
|
-
function e(
|
|
68
|
-
return
|
|
67
|
+
function e(f) {
|
|
68
|
+
return f;
|
|
69
69
|
}
|
|
70
|
-
function t(
|
|
71
|
-
return typeof
|
|
70
|
+
function t(f) {
|
|
71
|
+
return typeof f == "string" ? f.toLowerCase() : f;
|
|
72
72
|
}
|
|
73
|
-
function l(
|
|
74
|
-
if (g = typeof g == "object" ? g : { direction: g }, typeof
|
|
75
|
-
var x =
|
|
76
|
-
|
|
73
|
+
function l(f, g) {
|
|
74
|
+
if (g = typeof g == "object" ? g : { direction: g }, typeof f != "function") {
|
|
75
|
+
var x = f;
|
|
76
|
+
f = function(d) {
|
|
77
77
|
return d[x] ? d[x] : "";
|
|
78
78
|
};
|
|
79
79
|
}
|
|
80
|
-
if (
|
|
81
|
-
var P =
|
|
80
|
+
if (f.length === 1) {
|
|
81
|
+
var P = f, T = g.ignoreCase ? t : e, N = g.cmp || function(d, h) {
|
|
82
82
|
return d < h ? -1 : d > h ? 1 : 0;
|
|
83
83
|
};
|
|
84
|
-
|
|
85
|
-
return N(
|
|
84
|
+
f = function(d, h) {
|
|
85
|
+
return N(T(P(d)), T(P(h)));
|
|
86
86
|
};
|
|
87
87
|
}
|
|
88
88
|
const $ = { "-1": "", desc: "" };
|
|
89
89
|
return g.direction in $ ? function(d, h) {
|
|
90
|
-
return -
|
|
91
|
-
} :
|
|
90
|
+
return -f(d, h);
|
|
91
|
+
} : f;
|
|
92
92
|
}
|
|
93
|
-
function S(
|
|
94
|
-
var x = typeof this == "function" && !this.firstBy ? this : !1, P = l(
|
|
93
|
+
function S(f, g) {
|
|
94
|
+
var x = typeof this == "function" && !this.firstBy ? this : !1, P = l(f, g), T = x ? function(N, $) {
|
|
95
95
|
return x(N, $) || P(N, $);
|
|
96
96
|
} : P;
|
|
97
|
-
return
|
|
97
|
+
return T.thenBy = S, T;
|
|
98
98
|
}
|
|
99
99
|
return S.firstBy = S, S;
|
|
100
100
|
}();
|
|
@@ -110,18 +110,18 @@ function Be(e, t) {
|
|
|
110
110
|
while (S.startsWith("/"));
|
|
111
111
|
return `${l}/${S}`;
|
|
112
112
|
}
|
|
113
|
-
function
|
|
113
|
+
function On(e) {
|
|
114
114
|
return e == null || !Array.isArray(e) ? e : [...new Set(e.map((t) => t))];
|
|
115
115
|
}
|
|
116
|
-
function
|
|
116
|
+
function pn(e = "blitzItExtensionExists") {
|
|
117
117
|
try {
|
|
118
118
|
var t = document.getElementById(e);
|
|
119
119
|
return t != null;
|
|
120
120
|
} catch (l) {
|
|
121
|
-
return console.log(
|
|
121
|
+
return console.log(dn(l)), !1;
|
|
122
122
|
}
|
|
123
123
|
}
|
|
124
|
-
function
|
|
124
|
+
function ea(e, t) {
|
|
125
125
|
return [
|
|
126
126
|
{ lat: e.lat - t, lng: e.lng + t },
|
|
127
127
|
{ lat: e.lat - t, lng: e.lng - t },
|
|
@@ -129,7 +129,7 @@ function jn(e, t) {
|
|
|
129
129
|
{ lat: e.lat + t, lng: e.lng + t }
|
|
130
130
|
];
|
|
131
131
|
}
|
|
132
|
-
function
|
|
132
|
+
function ra(e, t) {
|
|
133
133
|
return [
|
|
134
134
|
{ lat: e.lat - t * 2, lng: e.lng + t },
|
|
135
135
|
{ lat: e.lat - t * 2, lng: e.lng - t },
|
|
@@ -137,7 +137,7 @@ function Kn(e, t) {
|
|
|
137
137
|
{ lat: e.lat, lng: e.lng + t }
|
|
138
138
|
];
|
|
139
139
|
}
|
|
140
|
-
function
|
|
140
|
+
function ta(e, t) {
|
|
141
141
|
return [
|
|
142
142
|
{ lat: e.lat, lng: e.lng + t },
|
|
143
143
|
{ lat: e.lat, lng: e.lng - t },
|
|
@@ -145,7 +145,7 @@ function Qn(e, t) {
|
|
|
145
145
|
{ lat: e.lat + t * 2, lng: e.lng + t }
|
|
146
146
|
];
|
|
147
147
|
}
|
|
148
|
-
function
|
|
148
|
+
function na(e) {
|
|
149
149
|
var t = rt(e, !0);
|
|
150
150
|
return t = t.toLowerCase(), t = t.replace(" victoria ", "vic"), t = t.replace(" queensland ", "qld"), t = t.replace(" new south wales ", "nsw"), t = t.replace(" northern territory ", "nt"), t = t.replace(" western australia ", "wa"), t = t.replace(" tasmania ", "tas"), t = t.replace(" south australia ", "sa"), t = t.replace(" australian captial territory ", "act"), t = t.replace(" & ", " and "), t = t.replace(" road", " rd"), t = t.replace(" street", " st"), t = t.replace(" lane", " ln"), t = t.replace(" alley", " aly"), t = t.replace(" arcade", " arc"), t = t.replace(" boulevard", " blvd"), t = t.replace(" court", " ct"), t = t.replace(" cove", " cv"), t = t.replace(" highway", " hwy"), t.replaceAll(" ", "");
|
|
151
151
|
}
|
|
@@ -157,36 +157,36 @@ function rt(e, t = !1) {
|
|
|
157
157
|
var l = "";
|
|
158
158
|
return e.addressLineOne != null && !t && (l = e.addressLineOne + " "), e.streetNumber != null && (l = l + e.streetNumber + " "), e.streetName != null && (l = l + e.streetName + ", "), e.suburb != null && (l = l + e.suburb + " "), e.state != null && (l = l + e.state + " "), e.postcode != null && (l = l + e.postcode), l;
|
|
159
159
|
}
|
|
160
|
-
function
|
|
160
|
+
function aa(e, t, l) {
|
|
161
161
|
if (e) {
|
|
162
162
|
var S = new Image();
|
|
163
163
|
S.onload = t, S.onerror = l, S.src = e;
|
|
164
164
|
}
|
|
165
165
|
}
|
|
166
|
-
async function
|
|
166
|
+
async function la(e, t = !0) {
|
|
167
167
|
return new Promise((l, S) => {
|
|
168
168
|
e == null && S("no url given");
|
|
169
|
-
var
|
|
170
|
-
|
|
169
|
+
var f = new Image();
|
|
170
|
+
f.setAttribute("crossOrigin", "anonymous"), f.onload = function() {
|
|
171
171
|
var g = document.createElement("canvas");
|
|
172
172
|
g.width = this.width, g.height = this.height;
|
|
173
173
|
var x = g.getContext("2d");
|
|
174
174
|
x == null || x.drawImage(this, 0, 0), l(g.toDataURL("image/png"));
|
|
175
|
-
},
|
|
175
|
+
}, f.onerror = function() {
|
|
176
176
|
console.log("errr"), t ? S("image could not be loaded for some reason") : l(null);
|
|
177
|
-
}, e != null && (
|
|
177
|
+
}, e != null && (f.src = e);
|
|
178
178
|
});
|
|
179
179
|
}
|
|
180
|
-
function
|
|
180
|
+
function an(e) {
|
|
181
181
|
return e && e.replace(/([A-Z])/g, " $1").replace(/^./, (t) => t.toUpperCase());
|
|
182
182
|
}
|
|
183
|
-
function
|
|
183
|
+
function ua(e) {
|
|
184
184
|
if (e != null && typeof e == "object")
|
|
185
185
|
for (var t in e)
|
|
186
186
|
/^[A-Z]/.test(t) && Object.hasOwnProperty.call(e, t) && (e[t.charAt(0).toLowerCase() + t.substring(1)] = e[t], delete e[t]);
|
|
187
187
|
return e;
|
|
188
188
|
}
|
|
189
|
-
function
|
|
189
|
+
function ln(e) {
|
|
190
190
|
return e == null ? e : e.replace(/\w\S*/g, (t) => t.replace(/^\w/, (l) => l.toUpperCase()));
|
|
191
191
|
}
|
|
192
192
|
const Ye = [
|
|
@@ -199,73 +199,73 @@ const Ye = [
|
|
|
199
199
|
{ value: 7, short: "sat", values: ["sat", "saturday"] },
|
|
200
200
|
{ value: 0, short: "always", values: ["always", null, void 0] }
|
|
201
201
|
];
|
|
202
|
-
function
|
|
202
|
+
function ia(e) {
|
|
203
203
|
if (e == null)
|
|
204
204
|
return 0;
|
|
205
|
-
const t = e.replaceAll(" ", "").split(",").map((S) => S.toLowerCase()), l = Ye.filter((S) => S.values.some((
|
|
205
|
+
const t = e.replaceAll(" ", "").split(",").map((S) => S.toLowerCase()), l = Ye.filter((S) => S.values.some((f) => t.some((g) => f == g))).map((S) => S.value);
|
|
206
206
|
return l.length == 0 ? 8 : Math.min(...l);
|
|
207
207
|
}
|
|
208
|
-
function
|
|
208
|
+
function ca(e) {
|
|
209
209
|
return e == null ? e : e.toLowerCase().replaceAll(" ", "").split(",").map((t) => {
|
|
210
|
-
let l = Ye.find((S) => S.values.some((
|
|
210
|
+
let l = Ye.find((S) => S.values.some((f) => f == t));
|
|
211
211
|
return l != null ? l.short : "";
|
|
212
212
|
}).filter((t) => t != null && t.length > 0).toString();
|
|
213
213
|
}
|
|
214
|
-
function
|
|
214
|
+
function fa(e, t) {
|
|
215
215
|
if (e == null || t == null)
|
|
216
216
|
return !0;
|
|
217
|
-
const l = e.replaceAll(" ", "").split(",").map((g) => g.toLowerCase()), S = t.replaceAll(" ", "").toLowerCase(),
|
|
218
|
-
return
|
|
217
|
+
const l = e.replaceAll(" ", "").split(",").map((g) => g.toLowerCase()), S = t.replaceAll(" ", "").toLowerCase(), f = Ye.find((g) => g.values.some((x) => x == S));
|
|
218
|
+
return f != null && l.some((g) => g == f.short || f.values.some((x) => x == g));
|
|
219
219
|
}
|
|
220
|
-
function
|
|
220
|
+
function sa(e, t) {
|
|
221
221
|
if (t == null)
|
|
222
222
|
return e;
|
|
223
223
|
let l = e ?? "";
|
|
224
224
|
l = `${l},${t}`;
|
|
225
|
-
let S = [...new Set(l.replaceAll(" ", "").toLowerCase().split(",").map((
|
|
225
|
+
let S = [...new Set(l.replaceAll(" ", "").toLowerCase().split(",").map((f) => Ye.find((g) => g.values.some((x) => x == f))).filter((f) => f != null).sort(Ue.firstBy((f) => (f == null ? void 0 : f.value) ?? 0)).map((f) => f == null ? void 0 : f.short))].toString();
|
|
226
226
|
return S.length > 0 ? S : void 0;
|
|
227
227
|
}
|
|
228
|
-
function
|
|
228
|
+
function oa(e, t) {
|
|
229
229
|
if (t == null || e == null)
|
|
230
230
|
return e;
|
|
231
|
-
let l = e ?? "", S = t.replaceAll(" ", "").toLowerCase(),
|
|
232
|
-
return
|
|
231
|
+
let l = e ?? "", S = t.replaceAll(" ", "").toLowerCase(), f = [...new Set(l.replaceAll(" ", "").toLowerCase().split(",").map((g) => Ye.find((x) => x.values.some((P) => P == g && P != S))).filter((g) => g != null).sort(Ue.firstBy((g) => (g == null ? void 0 : g.value) ?? 0)).map((g) => g == null ? void 0 : g.short))].toString();
|
|
232
|
+
return f.length > 0 ? f : void 0;
|
|
233
233
|
}
|
|
234
|
-
function
|
|
234
|
+
function da(e, t) {
|
|
235
235
|
return e != null && Array.isArray(e) && e.length == t;
|
|
236
236
|
}
|
|
237
|
-
function
|
|
237
|
+
function Te(e, t = 0) {
|
|
238
238
|
return e != null && Array.isArray(e) && e.length > t;
|
|
239
239
|
}
|
|
240
|
-
function
|
|
240
|
+
function un(e) {
|
|
241
241
|
return e == "0001-01-01T00:00:00Z";
|
|
242
242
|
}
|
|
243
|
-
function
|
|
243
|
+
function ha() {
|
|
244
244
|
return (/* @__PURE__ */ new Date("0001-01-01T00:00:00Z")).getTime();
|
|
245
245
|
}
|
|
246
|
-
function
|
|
246
|
+
function cn() {
|
|
247
247
|
return "0001-01-01T00:00:00Z";
|
|
248
248
|
}
|
|
249
|
-
function
|
|
249
|
+
function ma(e, t) {
|
|
250
250
|
let l = "1", S = 0;
|
|
251
251
|
if (S < t)
|
|
252
252
|
do
|
|
253
253
|
l = l + "0", S += 1;
|
|
254
254
|
while (S < t);
|
|
255
|
-
let
|
|
256
|
-
return Math.round(e *
|
|
255
|
+
let f = Number.parseInt(l);
|
|
256
|
+
return Math.round(e * f) / f;
|
|
257
257
|
}
|
|
258
|
-
function
|
|
258
|
+
function va(e, t) {
|
|
259
259
|
let l = e ?? "";
|
|
260
|
-
return t != null && (
|
|
260
|
+
return t != null && (fn(l, t) ? l = l.split(",").filter((S) => S != t).toString() : l != null ? l = `${l},${t}` : l = t), l != null && l.length > 0 ? l : null;
|
|
261
261
|
}
|
|
262
|
-
function
|
|
262
|
+
function fn(e, t) {
|
|
263
263
|
if (e == null || e.length == 0)
|
|
264
264
|
return !1;
|
|
265
265
|
if (!t)
|
|
266
266
|
return !0;
|
|
267
267
|
var l = e.split(","), S = t.split(",");
|
|
268
|
-
return l.some((
|
|
268
|
+
return l.some((f) => S.some((g) => g == f));
|
|
269
269
|
}
|
|
270
270
|
function Lr(e) {
|
|
271
271
|
if (!e)
|
|
@@ -275,32 +275,32 @@ function Lr(e) {
|
|
|
275
275
|
t = e[S], l[S] = typeof t == "object" ? Lr(t) : t;
|
|
276
276
|
return l;
|
|
277
277
|
}
|
|
278
|
-
function
|
|
278
|
+
function sn(e) {
|
|
279
279
|
return e && Object.keys(e).sort().reduce(function(t, l) {
|
|
280
280
|
let S = e[l];
|
|
281
|
-
return t[l] = typeof S == "object" && S !== null ?
|
|
281
|
+
return t[l] = typeof S == "object" && S !== null ? sn(S) : S, t;
|
|
282
282
|
}, Array.isArray(e) ? [] : {});
|
|
283
283
|
}
|
|
284
|
-
function
|
|
284
|
+
function on(e, t) {
|
|
285
285
|
return t == null ? !0 : e == null ? !1 : e.toLowerCase().includes(t.toLowerCase());
|
|
286
286
|
}
|
|
287
287
|
function tt(e, t = (l) => l) {
|
|
288
288
|
if (e == null)
|
|
289
289
|
return [];
|
|
290
290
|
const l = Array.isArray(e) ? e : t(e);
|
|
291
|
-
return
|
|
292
|
-
S.push(
|
|
293
|
-
const g = tt(
|
|
294
|
-
return
|
|
291
|
+
return Te(l) ? [...l.reduce((S, f) => {
|
|
292
|
+
S.push(f);
|
|
293
|
+
const g = tt(f, t);
|
|
294
|
+
return Te(g) && S.push(...g), S;
|
|
295
295
|
}, [])] : [];
|
|
296
296
|
}
|
|
297
|
-
function
|
|
298
|
-
const t = e.split(","), l = t[0].indexOf("base64") >= 0 ? atob(t[1]) : decodeURI(t[1]), S = t[0].split(":")[1].split(";")[0],
|
|
297
|
+
function ga(e) {
|
|
298
|
+
const t = e.split(","), l = t[0].indexOf("base64") >= 0 ? atob(t[1]) : decodeURI(t[1]), S = t[0].split(":")[1].split(";")[0], f = new Uint8Array(l.length);
|
|
299
299
|
for (let g = 0; g < l.length; g++)
|
|
300
|
-
|
|
301
|
-
return new Blob([
|
|
300
|
+
f[g] = l.charCodeAt(g);
|
|
301
|
+
return new Blob([f], { type: S });
|
|
302
302
|
}
|
|
303
|
-
function
|
|
303
|
+
function dn(e) {
|
|
304
304
|
var t = "";
|
|
305
305
|
if (e) {
|
|
306
306
|
if (e.message && (t = e.message), e.response && e.response.data) {
|
|
@@ -313,27 +313,27 @@ function sn(e) {
|
|
|
313
313
|
}
|
|
314
314
|
return "hmmm no error was supplied";
|
|
315
315
|
}
|
|
316
|
-
function
|
|
316
|
+
function hn() {
|
|
317
317
|
const e = "#" + Math.floor(Math.random() * 16777215).toString(16);
|
|
318
|
-
return e.length !== 7 ?
|
|
318
|
+
return e.length !== 7 ? hn() : e;
|
|
319
319
|
}
|
|
320
|
-
function
|
|
320
|
+
function mn(e, t, l) {
|
|
321
321
|
if (t == null)
|
|
322
322
|
return !0;
|
|
323
323
|
if (e == null || l == null)
|
|
324
324
|
return !1;
|
|
325
|
-
for (let
|
|
326
|
-
const g = l[
|
|
325
|
+
for (let f = 0; f < l.length; f++) {
|
|
326
|
+
const g = l[f];
|
|
327
327
|
var S = Sr(e, g);
|
|
328
|
-
if (S != null && typeof S == "string" &&
|
|
328
|
+
if (S != null && typeof S == "string" && on(S, t))
|
|
329
329
|
return !0;
|
|
330
330
|
}
|
|
331
331
|
return !1;
|
|
332
332
|
}
|
|
333
|
-
function
|
|
333
|
+
function ya(e) {
|
|
334
334
|
return e != null ? e.replaceAll(" ", "").toLowerCase() : null;
|
|
335
335
|
}
|
|
336
|
-
function
|
|
336
|
+
function wa(e = 2e3) {
|
|
337
337
|
return new Promise((t) => {
|
|
338
338
|
setTimeout(() => t(), e);
|
|
339
339
|
});
|
|
@@ -343,15 +343,15 @@ function Sr(e, t) {
|
|
|
343
343
|
return null;
|
|
344
344
|
var l = t.split(".");
|
|
345
345
|
let S = l.length;
|
|
346
|
-
for (var
|
|
347
|
-
if (
|
|
346
|
+
for (var f = e, g = 0; g < S; g++)
|
|
347
|
+
if (f = f[l[g]], f == null)
|
|
348
348
|
return null;
|
|
349
|
-
return
|
|
349
|
+
return f;
|
|
350
350
|
}
|
|
351
|
-
function
|
|
351
|
+
function vn(e) {
|
|
352
352
|
return e ? /^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)*$/.test(e) : !1;
|
|
353
353
|
}
|
|
354
|
-
function
|
|
354
|
+
function gn(e) {
|
|
355
355
|
return e.endsWith("ies") ? e.slice(0, e.length - 3) : e.endsWith("s") ? e.slice(0, e.length - 1) : e;
|
|
356
356
|
}
|
|
357
357
|
function Xe(e) {
|
|
@@ -368,9 +368,9 @@ var nt = { exports: {} };
|
|
|
368
368
|
(function(l) {
|
|
369
369
|
e.exports = l();
|
|
370
370
|
})(function() {
|
|
371
|
-
return function l(S,
|
|
371
|
+
return function l(S, f, g) {
|
|
372
372
|
function x(N, $) {
|
|
373
|
-
if (!
|
|
373
|
+
if (!f[N]) {
|
|
374
374
|
if (!S[N]) {
|
|
375
375
|
var d = typeof Xe == "function" && Xe;
|
|
376
376
|
if (!$ && d)
|
|
@@ -380,26 +380,26 @@ var nt = { exports: {} };
|
|
|
380
380
|
var h = new Error("Cannot find module '" + N + "'");
|
|
381
381
|
throw h.code = "MODULE_NOT_FOUND", h;
|
|
382
382
|
}
|
|
383
|
-
var u =
|
|
383
|
+
var u = f[N] = { exports: {} };
|
|
384
384
|
S[N][0].call(u.exports, function(r) {
|
|
385
385
|
var y = S[N][1][r];
|
|
386
386
|
return x(y || r);
|
|
387
|
-
}, u, u.exports, l, S,
|
|
387
|
+
}, u, u.exports, l, S, f, g);
|
|
388
388
|
}
|
|
389
|
-
return
|
|
389
|
+
return f[N].exports;
|
|
390
390
|
}
|
|
391
|
-
for (var P = typeof Xe == "function" && Xe,
|
|
392
|
-
x(g[
|
|
391
|
+
for (var P = typeof Xe == "function" && Xe, T = 0; T < g.length; T++)
|
|
392
|
+
x(g[T]);
|
|
393
393
|
return x;
|
|
394
|
-
}({ 1: [function(l, S,
|
|
394
|
+
}({ 1: [function(l, S, f) {
|
|
395
395
|
(function(g) {
|
|
396
396
|
var x = g.MutationObserver || g.WebKitMutationObserver, P;
|
|
397
397
|
if (x) {
|
|
398
|
-
var
|
|
398
|
+
var T = 0, N = new x(r), $ = g.document.createTextNode("");
|
|
399
399
|
N.observe($, {
|
|
400
400
|
characterData: !0
|
|
401
401
|
}), P = function() {
|
|
402
|
-
$.data =
|
|
402
|
+
$.data = T = ++T % 2;
|
|
403
403
|
};
|
|
404
404
|
} else if (!g.setImmediate && typeof g.MessageChannel < "u") {
|
|
405
405
|
var d = new g.MessageChannel();
|
|
@@ -430,11 +430,11 @@ var nt = { exports: {} };
|
|
|
430
430
|
u.push(I) === 1 && !h && P();
|
|
431
431
|
}
|
|
432
432
|
}).call(this, typeof Qe < "u" ? Qe : typeof self < "u" ? self : typeof window < "u" ? window : {});
|
|
433
|
-
}, {}], 2: [function(l, S,
|
|
433
|
+
}, {}], 2: [function(l, S, f) {
|
|
434
434
|
var g = l(1);
|
|
435
435
|
function x() {
|
|
436
436
|
}
|
|
437
|
-
var P = {},
|
|
437
|
+
var P = {}, T = ["REJECTED"], N = ["FULFILLED"], $ = ["PENDING"];
|
|
438
438
|
S.exports = d;
|
|
439
439
|
function d(b) {
|
|
440
440
|
if (typeof b != "function")
|
|
@@ -443,19 +443,19 @@ var nt = { exports: {} };
|
|
|
443
443
|
}
|
|
444
444
|
d.prototype.catch = function(b) {
|
|
445
445
|
return this.then(null, b);
|
|
446
|
-
}, d.prototype.then = function(b,
|
|
447
|
-
if (typeof b != "function" && this.state === N || typeof
|
|
446
|
+
}, d.prototype.then = function(b, _) {
|
|
447
|
+
if (typeof b != "function" && this.state === N || typeof _ != "function" && this.state === T)
|
|
448
448
|
return this;
|
|
449
449
|
var D = new this.constructor(x);
|
|
450
450
|
if (this.state !== $) {
|
|
451
|
-
var L = this.state === N ? b :
|
|
451
|
+
var L = this.state === N ? b : _;
|
|
452
452
|
u(D, L, this.outcome);
|
|
453
453
|
} else
|
|
454
|
-
this.queue.push(new h(D, b,
|
|
454
|
+
this.queue.push(new h(D, b, _));
|
|
455
455
|
return D;
|
|
456
456
|
};
|
|
457
|
-
function h(b,
|
|
458
|
-
this.promise = b, typeof
|
|
457
|
+
function h(b, _, D) {
|
|
458
|
+
this.promise = b, typeof _ == "function" && (this.onFulfilled = _, this.callFulfilled = this.otherCallFulfilled), typeof D == "function" && (this.onRejected = D, this.callRejected = this.otherCallRejected);
|
|
459
459
|
}
|
|
460
460
|
h.prototype.callFulfilled = function(b) {
|
|
461
461
|
P.resolve(this.promise, b);
|
|
@@ -466,61 +466,61 @@ var nt = { exports: {} };
|
|
|
466
466
|
}, h.prototype.otherCallRejected = function(b) {
|
|
467
467
|
u(this.promise, this.onRejected, b);
|
|
468
468
|
};
|
|
469
|
-
function u(b,
|
|
469
|
+
function u(b, _, D) {
|
|
470
470
|
g(function() {
|
|
471
471
|
var L;
|
|
472
472
|
try {
|
|
473
|
-
L =
|
|
474
|
-
} catch (
|
|
475
|
-
return P.reject(b,
|
|
473
|
+
L = _(D);
|
|
474
|
+
} catch (s) {
|
|
475
|
+
return P.reject(b, s);
|
|
476
476
|
}
|
|
477
477
|
L === b ? P.reject(b, new TypeError("Cannot resolve promise with itself")) : P.resolve(b, L);
|
|
478
478
|
});
|
|
479
479
|
}
|
|
480
|
-
P.resolve = function(b,
|
|
481
|
-
var D = I(r,
|
|
480
|
+
P.resolve = function(b, _) {
|
|
481
|
+
var D = I(r, _);
|
|
482
482
|
if (D.status === "error")
|
|
483
483
|
return P.reject(b, D.value);
|
|
484
484
|
var L = D.value;
|
|
485
485
|
if (L)
|
|
486
486
|
y(b, L);
|
|
487
487
|
else {
|
|
488
|
-
b.state = N, b.outcome =
|
|
489
|
-
for (var
|
|
490
|
-
b.queue[
|
|
488
|
+
b.state = N, b.outcome = _;
|
|
489
|
+
for (var s = -1, A = b.queue.length; ++s < A; )
|
|
490
|
+
b.queue[s].callFulfilled(_);
|
|
491
491
|
}
|
|
492
492
|
return b;
|
|
493
|
-
}, P.reject = function(b,
|
|
494
|
-
b.state =
|
|
493
|
+
}, P.reject = function(b, _) {
|
|
494
|
+
b.state = T, b.outcome = _;
|
|
495
495
|
for (var D = -1, L = b.queue.length; ++D < L; )
|
|
496
|
-
b.queue[D].callRejected(
|
|
496
|
+
b.queue[D].callRejected(_);
|
|
497
497
|
return b;
|
|
498
498
|
};
|
|
499
499
|
function r(b) {
|
|
500
|
-
var
|
|
501
|
-
if (b && (typeof b == "object" || typeof b == "function") && typeof
|
|
500
|
+
var _ = b && b.then;
|
|
501
|
+
if (b && (typeof b == "object" || typeof b == "function") && typeof _ == "function")
|
|
502
502
|
return function() {
|
|
503
|
-
|
|
503
|
+
_.apply(b, arguments);
|
|
504
504
|
};
|
|
505
505
|
}
|
|
506
|
-
function y(b,
|
|
506
|
+
function y(b, _) {
|
|
507
507
|
var D = !1;
|
|
508
508
|
function L(Q) {
|
|
509
509
|
D || (D = !0, P.reject(b, Q));
|
|
510
510
|
}
|
|
511
|
-
function
|
|
511
|
+
function s(Q) {
|
|
512
512
|
D || (D = !0, P.resolve(b, Q));
|
|
513
513
|
}
|
|
514
514
|
function A() {
|
|
515
|
-
|
|
515
|
+
_(s, L);
|
|
516
516
|
}
|
|
517
517
|
var J = I(A);
|
|
518
518
|
J.status === "error" && L(J.value);
|
|
519
519
|
}
|
|
520
|
-
function I(b,
|
|
520
|
+
function I(b, _) {
|
|
521
521
|
var D = {};
|
|
522
522
|
try {
|
|
523
|
-
D.value = b(
|
|
523
|
+
D.value = b(_), D.status = "success";
|
|
524
524
|
} catch (L) {
|
|
525
525
|
D.status = "error", D.value = L;
|
|
526
526
|
}
|
|
@@ -532,53 +532,53 @@ var nt = { exports: {} };
|
|
|
532
532
|
}
|
|
533
533
|
d.reject = E;
|
|
534
534
|
function E(b) {
|
|
535
|
-
var
|
|
536
|
-
return P.reject(
|
|
535
|
+
var _ = new this(x);
|
|
536
|
+
return P.reject(_, b);
|
|
537
537
|
}
|
|
538
538
|
d.all = w;
|
|
539
539
|
function w(b) {
|
|
540
|
-
var
|
|
540
|
+
var _ = this;
|
|
541
541
|
if (Object.prototype.toString.call(b) !== "[object Array]")
|
|
542
542
|
return this.reject(new TypeError("must be an array"));
|
|
543
543
|
var D = b.length, L = !1;
|
|
544
544
|
if (!D)
|
|
545
545
|
return this.resolve([]);
|
|
546
|
-
for (var
|
|
546
|
+
for (var s = new Array(D), A = 0, J = -1, Q = new this(x); ++J < D; )
|
|
547
547
|
ee(b[J], J);
|
|
548
548
|
return Q;
|
|
549
549
|
function ee(ce, we) {
|
|
550
|
-
|
|
550
|
+
_.resolve(ce).then(W, function(Y) {
|
|
551
551
|
L || (L = !0, P.reject(Q, Y));
|
|
552
552
|
});
|
|
553
553
|
function W(Y) {
|
|
554
|
-
|
|
554
|
+
s[we] = Y, ++A === D && !L && (L = !0, P.resolve(Q, s));
|
|
555
555
|
}
|
|
556
556
|
}
|
|
557
557
|
}
|
|
558
558
|
d.race = M;
|
|
559
559
|
function M(b) {
|
|
560
|
-
var
|
|
560
|
+
var _ = this;
|
|
561
561
|
if (Object.prototype.toString.call(b) !== "[object Array]")
|
|
562
562
|
return this.reject(new TypeError("must be an array"));
|
|
563
563
|
var D = b.length, L = !1;
|
|
564
564
|
if (!D)
|
|
565
565
|
return this.resolve([]);
|
|
566
|
-
for (var
|
|
567
|
-
J(b[
|
|
566
|
+
for (var s = -1, A = new this(x); ++s < D; )
|
|
567
|
+
J(b[s]);
|
|
568
568
|
return A;
|
|
569
569
|
function J(Q) {
|
|
570
|
-
|
|
570
|
+
_.resolve(Q).then(function(ee) {
|
|
571
571
|
L || (L = !0, P.resolve(A, ee));
|
|
572
572
|
}, function(ee) {
|
|
573
573
|
L || (L = !0, P.reject(A, ee));
|
|
574
574
|
});
|
|
575
575
|
}
|
|
576
576
|
}
|
|
577
|
-
}, { 1: 1 }], 3: [function(l, S,
|
|
577
|
+
}, { 1: 1 }], 3: [function(l, S, f) {
|
|
578
578
|
(function(g) {
|
|
579
579
|
typeof g.Promise != "function" && (g.Promise = l(2));
|
|
580
580
|
}).call(this, typeof Qe < "u" ? Qe : typeof self < "u" ? self : typeof window < "u" ? window : {});
|
|
581
|
-
}, { 2: 2 }], 4: [function(l, S,
|
|
581
|
+
}, { 2: 2 }], 4: [function(l, S, f) {
|
|
582
582
|
var g = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(n) {
|
|
583
583
|
return typeof n;
|
|
584
584
|
} : function(n) {
|
|
@@ -604,10 +604,10 @@ var nt = { exports: {} };
|
|
|
604
604
|
return;
|
|
605
605
|
}
|
|
606
606
|
}
|
|
607
|
-
var
|
|
607
|
+
var T = P();
|
|
608
608
|
function N() {
|
|
609
609
|
try {
|
|
610
|
-
if (!
|
|
610
|
+
if (!T || !T.open)
|
|
611
611
|
return !1;
|
|
612
612
|
var n = typeof openDatabase < "u" && /(Safari|iPhone|iPad|iPod)/.test(navigator.userAgent) && !/Chrome/.test(navigator.userAgent) && !/BlackBerry/.test(navigator.platform), c = typeof fetch == "function" && fetch.toString().indexOf("[native code") !== -1;
|
|
613
613
|
return (!n || c) && typeof indexedDB < "u" && // some outdated implementations of IDB that appear on Samsung
|
|
@@ -651,7 +651,7 @@ var nt = { exports: {} };
|
|
|
651
651
|
return arguments[arguments.length - 1];
|
|
652
652
|
}
|
|
653
653
|
var I = "local-forage-detect-blob-support", i = void 0, E = {}, w = Object.prototype.toString, M = "readonly", b = "readwrite";
|
|
654
|
-
function
|
|
654
|
+
function _(n) {
|
|
655
655
|
for (var c = n.length, a = new ArrayBuffer(c), m = new Uint8Array(a), v = 0; v < c; v++)
|
|
656
656
|
m[v] = n.charCodeAt(v);
|
|
657
657
|
return a;
|
|
@@ -674,7 +674,7 @@ var nt = { exports: {} };
|
|
|
674
674
|
return i = c, i;
|
|
675
675
|
});
|
|
676
676
|
}
|
|
677
|
-
function
|
|
677
|
+
function s(n) {
|
|
678
678
|
var c = E[n.name], a = {};
|
|
679
679
|
a.promise = new d(function(m, v) {
|
|
680
680
|
a.resolve = m, a.reject = v;
|
|
@@ -696,12 +696,12 @@ var nt = { exports: {} };
|
|
|
696
696
|
return new d(function(a, m) {
|
|
697
697
|
if (E[n.name] = E[n.name] || ne(), n.db)
|
|
698
698
|
if (c)
|
|
699
|
-
|
|
699
|
+
s(n), n.db.close();
|
|
700
700
|
else
|
|
701
701
|
return a(n.db);
|
|
702
702
|
var v = [n.name];
|
|
703
703
|
c && v.push(n.version);
|
|
704
|
-
var o =
|
|
704
|
+
var o = T.open.apply(T, v);
|
|
705
705
|
c && (o.onupgradeneeded = function(C) {
|
|
706
706
|
var R = o.result;
|
|
707
707
|
try {
|
|
@@ -755,7 +755,7 @@ var nt = { exports: {} };
|
|
|
755
755
|
});
|
|
756
756
|
}
|
|
757
757
|
function Y(n) {
|
|
758
|
-
var c =
|
|
758
|
+
var c = _(atob(n.data));
|
|
759
759
|
return $([c], { type: n.type });
|
|
760
760
|
}
|
|
761
761
|
function H(n) {
|
|
@@ -770,7 +770,7 @@ var nt = { exports: {} };
|
|
|
770
770
|
return u(a, n, n), a;
|
|
771
771
|
}
|
|
772
772
|
function G(n) {
|
|
773
|
-
|
|
773
|
+
s(n);
|
|
774
774
|
for (var c = E[n.name], a = c.forages, m = 0; m < a.length; m++) {
|
|
775
775
|
var v = a[m];
|
|
776
776
|
v._dbInfo.db && (v._dbInfo.db.close(), v._dbInfo.db = null);
|
|
@@ -1071,7 +1071,7 @@ var nt = { exports: {} };
|
|
|
1071
1071
|
n.storeName ? v = C.then(function(R) {
|
|
1072
1072
|
if (R.objectStoreNames.contains(n.storeName)) {
|
|
1073
1073
|
var B = R.version + 1;
|
|
1074
|
-
|
|
1074
|
+
s(n);
|
|
1075
1075
|
var F = E[n.name], k = F.forages;
|
|
1076
1076
|
R.close();
|
|
1077
1077
|
for (var q = 0; q < k.length; q++) {
|
|
@@ -1079,7 +1079,7 @@ var nt = { exports: {} };
|
|
|
1079
1079
|
Z._dbInfo.db = null, Z._dbInfo.version = B;
|
|
1080
1080
|
}
|
|
1081
1081
|
var p = new d(function(re, ie) {
|
|
1082
|
-
var le =
|
|
1082
|
+
var le = T.open(n.name, B);
|
|
1083
1083
|
le.onerror = function(ye) {
|
|
1084
1084
|
var ze = le.result;
|
|
1085
1085
|
ze.close(), ie(ye);
|
|
@@ -1103,7 +1103,7 @@ var nt = { exports: {} };
|
|
|
1103
1103
|
});
|
|
1104
1104
|
}
|
|
1105
1105
|
}) : v = C.then(function(R) {
|
|
1106
|
-
|
|
1106
|
+
s(n);
|
|
1107
1107
|
var B = E[n.name], F = B.forages;
|
|
1108
1108
|
R.close();
|
|
1109
1109
|
for (var k = 0; k < F.length; k++) {
|
|
@@ -1111,7 +1111,7 @@ var nt = { exports: {} };
|
|
|
1111
1111
|
q._dbInfo.db = null;
|
|
1112
1112
|
}
|
|
1113
1113
|
var Z = new d(function(p, re) {
|
|
1114
|
-
var ie =
|
|
1114
|
+
var ie = T.deleteDatabase(n.name);
|
|
1115
1115
|
ie.onerror = function() {
|
|
1116
1116
|
var le = ie.result;
|
|
1117
1117
|
le && le.close(), re(ie.error);
|
|
@@ -1522,7 +1522,7 @@ var nt = { exports: {} };
|
|
|
1522
1522
|
});
|
|
1523
1523
|
return h(a, n), a;
|
|
1524
1524
|
}
|
|
1525
|
-
function
|
|
1525
|
+
function _t(n, c) {
|
|
1526
1526
|
var a = this;
|
|
1527
1527
|
n = r(n);
|
|
1528
1528
|
var m = a.ready().then(function() {
|
|
@@ -1531,7 +1531,7 @@ var nt = { exports: {} };
|
|
|
1531
1531
|
});
|
|
1532
1532
|
return h(m, c), m;
|
|
1533
1533
|
}
|
|
1534
|
-
function
|
|
1534
|
+
function Tt(n, c) {
|
|
1535
1535
|
var a = this, m = a.ready().then(function() {
|
|
1536
1536
|
for (var v = a._dbInfo, o = v.keyPrefix, C = o.length, R = localStorage.length, B = 1, F = 0; F < R; F++) {
|
|
1537
1537
|
var k = localStorage.key(F);
|
|
@@ -1622,8 +1622,8 @@ var nt = { exports: {} };
|
|
|
1622
1622
|
_driver: "localStorageWrapper",
|
|
1623
1623
|
_initStorage: Dt,
|
|
1624
1624
|
_support: At(),
|
|
1625
|
-
iterate:
|
|
1626
|
-
getItem:
|
|
1625
|
+
iterate: Tt,
|
|
1626
|
+
getItem: _t,
|
|
1627
1627
|
setItem: Lt,
|
|
1628
1628
|
removeItem: Mt,
|
|
1629
1629
|
clear: xt,
|
|
@@ -1804,8 +1804,8 @@ var nt = { exports: {} };
|
|
|
1804
1804
|
}, { 3: 3 }] }, {}, [4])(4);
|
|
1805
1805
|
});
|
|
1806
1806
|
})(nt);
|
|
1807
|
-
var
|
|
1808
|
-
const at = /* @__PURE__ */
|
|
1807
|
+
var yn = nt.exports;
|
|
1808
|
+
const at = /* @__PURE__ */ nn(yn);
|
|
1809
1809
|
let ue;
|
|
1810
1810
|
function lt() {
|
|
1811
1811
|
const e = ue == null ? void 0 : ue.getEnv();
|
|
@@ -1815,17 +1815,17 @@ function Wr() {
|
|
|
1815
1815
|
const e = ue == null ? void 0 : ue.getEnv();
|
|
1816
1816
|
return console.log(`env var: ${e}`), ue == null ? "" : (ue[e] ?? ue.development).auth ?? "";
|
|
1817
1817
|
}
|
|
1818
|
-
function
|
|
1818
|
+
function wn(e) {
|
|
1819
1819
|
const t = ue == null ? void 0 : ue.getEnv();
|
|
1820
1820
|
if (ue == null)
|
|
1821
1821
|
return "";
|
|
1822
1822
|
const l = ue[t] ?? ue.development;
|
|
1823
1823
|
return e == null ? l.data ?? "" : l.other[e] ?? l.data ?? "";
|
|
1824
1824
|
}
|
|
1825
|
-
function
|
|
1825
|
+
function ba() {
|
|
1826
1826
|
return ue;
|
|
1827
1827
|
}
|
|
1828
|
-
function
|
|
1828
|
+
function bn(e) {
|
|
1829
1829
|
return ue = e, ue;
|
|
1830
1830
|
}
|
|
1831
1831
|
let Oe = null;
|
|
@@ -1836,21 +1836,21 @@ function ve() {
|
|
|
1836
1836
|
const e = lt();
|
|
1837
1837
|
return (Oe == null || Oe.config.name != e) && (Oe = at.createInstance({ name: e })), Oe;
|
|
1838
1838
|
}
|
|
1839
|
-
function
|
|
1840
|
-
async function e(
|
|
1839
|
+
function Sa() {
|
|
1840
|
+
async function e(f) {
|
|
1841
1841
|
const g = ve();
|
|
1842
|
-
(await g.keys()).filter((
|
|
1843
|
-
g.removeItem(
|
|
1842
|
+
(await g.keys()).filter((T) => T.startsWith(f)).forEach((T) => {
|
|
1843
|
+
g.removeItem(T);
|
|
1844
1844
|
});
|
|
1845
1845
|
}
|
|
1846
|
-
async function t(
|
|
1847
|
-
return await ve().getItem(
|
|
1846
|
+
async function t(f) {
|
|
1847
|
+
return await ve().getItem(f);
|
|
1848
1848
|
}
|
|
1849
|
-
async function l(
|
|
1850
|
-
return await ve().removeItem(
|
|
1849
|
+
async function l(f) {
|
|
1850
|
+
return await ve().removeItem(f);
|
|
1851
1851
|
}
|
|
1852
|
-
async function S(
|
|
1853
|
-
await ve().setItem(g,
|
|
1852
|
+
async function S(f, g) {
|
|
1853
|
+
await ve().setItem(g, f);
|
|
1854
1854
|
}
|
|
1855
1855
|
return {
|
|
1856
1856
|
clearAsync: e,
|
|
@@ -1860,21 +1860,21 @@ function ma() {
|
|
|
1860
1860
|
};
|
|
1861
1861
|
}
|
|
1862
1862
|
let er;
|
|
1863
|
-
function
|
|
1863
|
+
function Aa(e) {
|
|
1864
1864
|
return er(e)();
|
|
1865
1865
|
}
|
|
1866
1866
|
function Le(e) {
|
|
1867
1867
|
return er(e);
|
|
1868
1868
|
}
|
|
1869
|
-
function
|
|
1870
|
-
return er = (t) =>
|
|
1869
|
+
function Sn(e) {
|
|
1870
|
+
return er = (t) => An({
|
|
1871
1871
|
...e,
|
|
1872
1872
|
...t
|
|
1873
1873
|
}), er;
|
|
1874
1874
|
}
|
|
1875
|
-
function
|
|
1876
|
-
var t, l, S,
|
|
1877
|
-
if (e.storeMode ?? (e.storeMode = ((l = (t = e.navigation) == null ? void 0 : t.findItem(e.nav)) == null ? void 0 : l.storeMode) ?? "session"), e.storageMode ?? (e.storageMode = ((
|
|
1875
|
+
function An(e) {
|
|
1876
|
+
var t, l, S, f, g;
|
|
1877
|
+
if (e.storeMode ?? (e.storeMode = ((l = (t = e.navigation) == null ? void 0 : t.findItem(e.nav)) == null ? void 0 : l.storeMode) ?? "session"), e.storageMode ?? (e.storageMode = ((f = (S = e.navigation) == null ? void 0 : S.findItem(e.nav)) == null ? void 0 : f.storageMode) ?? "local-cache"), e.storeName ?? (e.storeName = ((g = e.navigation) == null ? void 0 : g.findStoreName(e.nav)) ?? e.nav), e.storeName == null)
|
|
1878
1878
|
throw new Error("no store name provided");
|
|
1879
1879
|
if (e.storeMode == "whole-last-updated") {
|
|
1880
1880
|
if (e.api == null)
|
|
@@ -1885,23 +1885,23 @@ function bn(e) {
|
|
|
1885
1885
|
throw new Error("Must supply an api object to use store");
|
|
1886
1886
|
return qr({ ...e, storeName: e.storeName ?? "" });
|
|
1887
1887
|
} else
|
|
1888
|
-
return
|
|
1888
|
+
return In({ ...e, storeName: e.storeName ?? "" });
|
|
1889
1889
|
}
|
|
1890
|
-
const
|
|
1890
|
+
const En = (e) => {
|
|
1891
1891
|
let t = K(e.url) ?? void 0;
|
|
1892
1892
|
if (e.additionalUrl != null && (t == null ? t = e.additionalUrl : t = Be(t, e.additionalUrl)), e.id != null && (t != null && t.includes("{id}") ? t = t.replaceAll("{id}", e.id) : t = Be(t, e.id)), e.params != null) {
|
|
1893
1893
|
t ?? (t = "");
|
|
1894
1894
|
let l = new URLSearchParams();
|
|
1895
|
-
Object.entries(e.params).sort(Ue.firstBy((
|
|
1896
|
-
|
|
1895
|
+
Object.entries(e.params).sort(Ue.firstBy((f) => f[0])).forEach((f) => {
|
|
1896
|
+
f[1] != null && l.append(f[0], f[1].toString());
|
|
1897
1897
|
}), t = `${t}?${l.toString()}`;
|
|
1898
1898
|
}
|
|
1899
1899
|
return e.finalUrl = t, e.finalUrl ?? "";
|
|
1900
1900
|
};
|
|
1901
|
-
function
|
|
1901
|
+
function In(e) {
|
|
1902
1902
|
return pr(e.storeName, () => {
|
|
1903
1903
|
var u;
|
|
1904
|
-
const t = he.utc().toSeconds() / 86400, l = z({}), S = z({}),
|
|
1904
|
+
const t = he.utc().toSeconds() / 86400, l = z({}), S = z({}), f = e.storageMode == "local-cache", g = e.buildUrl ?? ((u = e.api) == null ? void 0 : u.buildUrl) ?? En;
|
|
1905
1905
|
function x(r) {
|
|
1906
1906
|
var i, E;
|
|
1907
1907
|
let y = "";
|
|
@@ -1913,7 +1913,7 @@ function An(e) {
|
|
|
1913
1913
|
const y = x(r), I = r.refresh;
|
|
1914
1914
|
if (!I && l.value[y] !== void 0)
|
|
1915
1915
|
return l.value[y];
|
|
1916
|
-
if (!I &&
|
|
1916
|
+
if (!I && f == !0) {
|
|
1917
1917
|
const i = await ve().getItem(y);
|
|
1918
1918
|
if (i != null && (e.api == null || parseFloat(i.meta.storedOn) > t - 7))
|
|
1919
1919
|
return l.value[y] = i, i;
|
|
@@ -1925,15 +1925,15 @@ function An(e) {
|
|
|
1925
1925
|
i == null && (i = new Promise(async (w, M) => {
|
|
1926
1926
|
var b;
|
|
1927
1927
|
try {
|
|
1928
|
-
const
|
|
1928
|
+
const _ = await ((b = e.api) == null ? void 0 : b.getAll(r)), D = {
|
|
1929
1929
|
meta: { storedOn: t.toString() },
|
|
1930
|
-
data:
|
|
1931
|
-
count:
|
|
1932
|
-
filters: (
|
|
1930
|
+
data: _ == null ? void 0 : _.data,
|
|
1931
|
+
count: _ == null ? void 0 : _.count,
|
|
1932
|
+
filters: (_ == null ? void 0 : _.filters) ?? []
|
|
1933
1933
|
};
|
|
1934
|
-
|
|
1935
|
-
} catch (
|
|
1936
|
-
M(
|
|
1934
|
+
f == !0 && await ve().setItem(y, D), w(D);
|
|
1935
|
+
} catch (_) {
|
|
1936
|
+
M(_);
|
|
1937
1937
|
} finally {
|
|
1938
1938
|
delete S.value[y];
|
|
1939
1939
|
}
|
|
@@ -1948,12 +1948,12 @@ function An(e) {
|
|
|
1948
1948
|
throw i;
|
|
1949
1949
|
}
|
|
1950
1950
|
}
|
|
1951
|
-
async function
|
|
1951
|
+
async function T(r) {
|
|
1952
1952
|
r.additionalUrl ?? (r.additionalUrl = "/get"), g(r);
|
|
1953
1953
|
const y = x(r), I = r.refresh;
|
|
1954
1954
|
if (!I && l.value[y] !== void 0)
|
|
1955
1955
|
return l.value[y];
|
|
1956
|
-
if (!I &&
|
|
1956
|
+
if (!I && f == !0) {
|
|
1957
1957
|
const i = await ve().getItem(y);
|
|
1958
1958
|
if (i != null && (e.api == null || parseFloat(i.meta.storedOn) > t - 7))
|
|
1959
1959
|
return l.value[y] = i, { data: i.data };
|
|
@@ -1965,14 +1965,14 @@ function An(e) {
|
|
|
1965
1965
|
i == null && (i = new Promise(async (w, M) => {
|
|
1966
1966
|
var b;
|
|
1967
1967
|
try {
|
|
1968
|
-
let
|
|
1968
|
+
let _ = await ((b = e.api) == null ? void 0 : b.get(r));
|
|
1969
1969
|
const D = {
|
|
1970
1970
|
meta: { storedOn: t.toString() },
|
|
1971
|
-
data:
|
|
1971
|
+
data: _ == null ? void 0 : _.data
|
|
1972
1972
|
};
|
|
1973
|
-
|
|
1974
|
-
} catch (
|
|
1975
|
-
M(
|
|
1973
|
+
f == !0 && await ve().setItem(y, D), w(D);
|
|
1974
|
+
} catch (_) {
|
|
1975
|
+
M(_);
|
|
1976
1976
|
} finally {
|
|
1977
1977
|
delete S.value[y];
|
|
1978
1978
|
}
|
|
@@ -2002,12 +2002,12 @@ function An(e) {
|
|
|
2002
2002
|
meta: { storedOn: t.toString() },
|
|
2003
2003
|
data: { ...(i = l.value[y]) == null ? void 0 : i.data, ...I }
|
|
2004
2004
|
};
|
|
2005
|
-
return l.value[y] = E,
|
|
2005
|
+
return l.value[y] = E, f == !0 && await ve().setItem(y, E), I.id != null && I.rowVersion != null && Object.entries(l.value).forEach((M) => {
|
|
2006
2006
|
const b = M[1].data;
|
|
2007
2007
|
if (b != null)
|
|
2008
2008
|
if (Array.isArray(b))
|
|
2009
|
-
for (let
|
|
2010
|
-
b[
|
|
2009
|
+
for (let _ = 0; _ < b.length; _++)
|
|
2010
|
+
b[_].id == I.id && b.splice(_, 1, E.data);
|
|
2011
2011
|
else
|
|
2012
2012
|
b.id == I.id && (l.value[M[0]] = E);
|
|
2013
2013
|
}), E.data;
|
|
@@ -2032,7 +2032,7 @@ function An(e) {
|
|
|
2032
2032
|
meta: { storedOn: t.toString() },
|
|
2033
2033
|
data: I
|
|
2034
2034
|
};
|
|
2035
|
-
return
|
|
2035
|
+
return f == !0 && await ve().setItem(y, i), l.value[y] = i, i.data;
|
|
2036
2036
|
}
|
|
2037
2037
|
return I;
|
|
2038
2038
|
}
|
|
@@ -2058,7 +2058,7 @@ function An(e) {
|
|
|
2058
2058
|
M[b].id == I && M.splice(b, 1);
|
|
2059
2059
|
else
|
|
2060
2060
|
delete l.value[w[0]];
|
|
2061
|
-
}),
|
|
2061
|
+
}), f == !0 && await ve().removeItem(y);
|
|
2062
2062
|
}
|
|
2063
2063
|
async function h(r) {
|
|
2064
2064
|
if (r.additionalUrl ?? (r.additionalUrl = `/patch/restore?id=${r.data.id}`), g(r), e.api != null)
|
|
@@ -2071,7 +2071,7 @@ function An(e) {
|
|
|
2071
2071
|
}
|
|
2072
2072
|
return {
|
|
2073
2073
|
deleteItem: d,
|
|
2074
|
-
get:
|
|
2074
|
+
get: T,
|
|
2075
2075
|
getAll: P,
|
|
2076
2076
|
patch: N,
|
|
2077
2077
|
post: $,
|
|
@@ -2083,13 +2083,13 @@ function An(e) {
|
|
|
2083
2083
|
}
|
|
2084
2084
|
function qr(e) {
|
|
2085
2085
|
return pr(e.storeName, () => {
|
|
2086
|
-
const t = z(), l = z(0), S = he.utc().toSeconds() / 3600,
|
|
2087
|
-
function
|
|
2086
|
+
const t = z(), l = z(0), S = he.utc().toSeconds() / 3600, f = z(), g = z(), x = z({}), P = e.storageMode == "local-cache";
|
|
2087
|
+
function T() {
|
|
2088
2088
|
var i;
|
|
2089
2089
|
return `${e.storeName}_${((i = e.auth) == null ? void 0 : i.credentials.value.userID) ?? "no-user-id"}`;
|
|
2090
2090
|
}
|
|
2091
2091
|
async function N() {
|
|
2092
|
-
P == !0 && await ve().setItem(
|
|
2092
|
+
P == !0 && await ve().setItem(T(), {
|
|
2093
2093
|
meta: g.value,
|
|
2094
2094
|
data: t.value,
|
|
2095
2095
|
count: l.value,
|
|
@@ -2097,21 +2097,21 @@ function qr(e) {
|
|
|
2097
2097
|
});
|
|
2098
2098
|
}
|
|
2099
2099
|
function $(i) {
|
|
2100
|
-
const E =
|
|
2100
|
+
const E = T();
|
|
2101
2101
|
return x.value[E] || (x.value[E] = new Promise(async (w, M) => {
|
|
2102
|
-
var b,
|
|
2102
|
+
var b, _;
|
|
2103
2103
|
try {
|
|
2104
|
-
let D = await ((
|
|
2104
|
+
let D = await ((_ = e.api) == null ? void 0 : _.getAll({
|
|
2105
2105
|
additionalUrl: "/getAll",
|
|
2106
2106
|
nav: i.nav,
|
|
2107
2107
|
params: {
|
|
2108
|
-
lastUpdate: ((b = g.value) == null ? void 0 : b.lastUpdate) ??
|
|
2108
|
+
lastUpdate: ((b = g.value) == null ? void 0 : b.lastUpdate) ?? cn()
|
|
2109
2109
|
}
|
|
2110
2110
|
}));
|
|
2111
2111
|
D == null ? M(D) : (t.value ?? (t.value = []), D.data.forEach((L) => {
|
|
2112
2112
|
var A, J;
|
|
2113
|
-
const
|
|
2114
|
-
|
|
2113
|
+
const s = t.value.findIndex((Q) => Q.id == L.id);
|
|
2114
|
+
s >= 0 ? (A = t.value) == null || A.splice(s, 1, L) : (J = t.value) == null || J.push(L);
|
|
2115
2115
|
}), l.value = t.value.length, g.value = {
|
|
2116
2116
|
lastUpdate: he.utc().toString(),
|
|
2117
2117
|
storedOn: S.toString()
|
|
@@ -2124,8 +2124,8 @@ function qr(e) {
|
|
|
2124
2124
|
})), x.value[E];
|
|
2125
2125
|
}
|
|
2126
2126
|
async function d(i) {
|
|
2127
|
-
var M, b,
|
|
2128
|
-
const E =
|
|
2127
|
+
var M, b, _;
|
|
2128
|
+
const E = T(), w = i.refresh;
|
|
2129
2129
|
if (!w && t.value != null)
|
|
2130
2130
|
return {
|
|
2131
2131
|
count: (M = t.value) == null ? void 0 : M.length,
|
|
@@ -2135,7 +2135,7 @@ function qr(e) {
|
|
|
2135
2135
|
if (!w && P == !0) {
|
|
2136
2136
|
const D = await ve().getItem(E);
|
|
2137
2137
|
if (D != null && parseFloat(D.meta.storedOn) > S - 7)
|
|
2138
|
-
return t.value = D.data, l.value = D.data.length,
|
|
2138
|
+
return t.value = D.data, l.value = D.data.length, f.value = D.filters ?? [], g.value = D.meta, {
|
|
2139
2139
|
count: (b = t.value) == null ? void 0 : b.length,
|
|
2140
2140
|
data: t.value ?? [],
|
|
2141
2141
|
filters: []
|
|
@@ -2143,9 +2143,9 @@ function qr(e) {
|
|
|
2143
2143
|
}
|
|
2144
2144
|
if (e.api == null)
|
|
2145
2145
|
return {
|
|
2146
|
-
count: (
|
|
2146
|
+
count: (_ = t.value) == null ? void 0 : _.length,
|
|
2147
2147
|
data: t.value ?? [],
|
|
2148
|
-
filters:
|
|
2148
|
+
filters: f.value
|
|
2149
2149
|
};
|
|
2150
2150
|
t.value ?? (t.value = []);
|
|
2151
2151
|
try {
|
|
@@ -2156,34 +2156,34 @@ function qr(e) {
|
|
|
2156
2156
|
}
|
|
2157
2157
|
}
|
|
2158
2158
|
async function h(i) {
|
|
2159
|
-
var b,
|
|
2160
|
-
const E =
|
|
2159
|
+
var b, _, D, L;
|
|
2160
|
+
const E = T(), w = i.id ?? ((b = i.data) == null ? void 0 : b.id);
|
|
2161
2161
|
if (w == null)
|
|
2162
2162
|
throw new Error("no id provided");
|
|
2163
2163
|
let M = i.refresh;
|
|
2164
2164
|
if (!M && t.value != null) {
|
|
2165
|
-
const
|
|
2166
|
-
if (
|
|
2167
|
-
return { data:
|
|
2165
|
+
const s = t.value.find((A) => A.id == w);
|
|
2166
|
+
if (s != null)
|
|
2167
|
+
return { data: s };
|
|
2168
2168
|
}
|
|
2169
2169
|
if (!M && P == !0) {
|
|
2170
|
-
const
|
|
2171
|
-
if (
|
|
2172
|
-
t.value =
|
|
2173
|
-
let A = (
|
|
2170
|
+
const s = await ve().getItem(E);
|
|
2171
|
+
if (s != null && parseFloat(s.meta.storedOn) > S - 12) {
|
|
2172
|
+
t.value = s.data, l.value = s.data.length, f.value = s.filters ?? [], g.value = s.meta;
|
|
2173
|
+
let A = (_ = t.value) == null ? void 0 : _.find((J) => J.id == i.id);
|
|
2174
2174
|
if (A != null)
|
|
2175
2175
|
return { data: A };
|
|
2176
2176
|
}
|
|
2177
2177
|
}
|
|
2178
2178
|
if (e.api == null)
|
|
2179
2179
|
return {
|
|
2180
|
-
data: (D = t.value) == null ? void 0 : D.find((
|
|
2180
|
+
data: (D = t.value) == null ? void 0 : D.find((s) => s.id == i.id)
|
|
2181
2181
|
};
|
|
2182
2182
|
t.value ?? (t.value = []);
|
|
2183
2183
|
try {
|
|
2184
|
-
return await $(i), { data: (L = t.value) == null ? void 0 : L.find((
|
|
2185
|
-
} catch (
|
|
2186
|
-
let A =
|
|
2184
|
+
return await $(i), { data: (L = t.value) == null ? void 0 : L.find((s) => s.id == i.id) };
|
|
2185
|
+
} catch (s) {
|
|
2186
|
+
let A = s;
|
|
2187
2187
|
throw new Error(A.message ?? "Problem");
|
|
2188
2188
|
}
|
|
2189
2189
|
}
|
|
@@ -2193,19 +2193,19 @@ function qr(e) {
|
|
|
2193
2193
|
let E;
|
|
2194
2194
|
if (e.api != null)
|
|
2195
2195
|
try {
|
|
2196
|
-
let
|
|
2197
|
-
E = { ...i.data, ...
|
|
2198
|
-
} catch (
|
|
2199
|
-
let D =
|
|
2196
|
+
let _ = await e.api.patch(i);
|
|
2197
|
+
E = { ...i.data, ..._ == null ? void 0 : _.data };
|
|
2198
|
+
} catch (_) {
|
|
2199
|
+
let D = _;
|
|
2200
2200
|
throw new Error(D.message ?? "Patch Problem");
|
|
2201
2201
|
}
|
|
2202
2202
|
else
|
|
2203
2203
|
E = i.data;
|
|
2204
2204
|
if (E != null) {
|
|
2205
|
-
let
|
|
2206
|
-
|
|
2205
|
+
let _ = (w = t.value) == null ? void 0 : w.findIndex((D) => D.id == E.id);
|
|
2206
|
+
_ != null && _ >= 0 && (t.value ?? (t.value = []), (M = t.value) == null || M.splice(_, 1, E), await N());
|
|
2207
2207
|
}
|
|
2208
|
-
return (b = t.value) == null ? void 0 : b.find((
|
|
2208
|
+
return (b = t.value) == null ? void 0 : b.find((_) => _.id == (i.id ?? i.data.id));
|
|
2209
2209
|
}
|
|
2210
2210
|
async function r(i) {
|
|
2211
2211
|
var w, M;
|
|
@@ -2216,8 +2216,8 @@ function qr(e) {
|
|
|
2216
2216
|
let b = await e.api.post(i);
|
|
2217
2217
|
E = b == null ? void 0 : b.data;
|
|
2218
2218
|
} catch (b) {
|
|
2219
|
-
let
|
|
2220
|
-
throw new Error(
|
|
2219
|
+
let _ = b;
|
|
2220
|
+
throw new Error(_.message ?? "Patch Problem");
|
|
2221
2221
|
}
|
|
2222
2222
|
else
|
|
2223
2223
|
E = i.data;
|
|
@@ -2231,12 +2231,12 @@ function qr(e) {
|
|
|
2231
2231
|
if (b != null)
|
|
2232
2232
|
return b;
|
|
2233
2233
|
} catch (b) {
|
|
2234
|
-
let
|
|
2235
|
-
throw new Error(
|
|
2234
|
+
let _ = b;
|
|
2235
|
+
throw new Error(_.message ?? "Patch Problem");
|
|
2236
2236
|
}
|
|
2237
2237
|
const E = i.id ?? i.data.id;
|
|
2238
2238
|
if (E != null) {
|
|
2239
|
-
let b = (w = t.value) == null ? void 0 : w.findIndex((
|
|
2239
|
+
let b = (w = t.value) == null ? void 0 : w.findIndex((_) => _.id == E);
|
|
2240
2240
|
b != null && b >= 0 && (t.value ?? (t.value = []), (M = t.value) == null || M.splice(b, 1), await N());
|
|
2241
2241
|
}
|
|
2242
2242
|
}
|
|
@@ -2271,8 +2271,8 @@ let Ar;
|
|
|
2271
2271
|
function Er() {
|
|
2272
2272
|
return Ar;
|
|
2273
2273
|
}
|
|
2274
|
-
function
|
|
2275
|
-
const t = (e == null ? void 0 : e.buildHeaders) ?? P, l = (e == null ? void 0 : e.buildQuery) ?? g, S = (e == null ? void 0 : e.buildUrl) ?? x,
|
|
2274
|
+
function Dn(e) {
|
|
2275
|
+
const t = (e == null ? void 0 : e.buildHeaders) ?? P, l = (e == null ? void 0 : e.buildQuery) ?? g, S = (e == null ? void 0 : e.buildUrl) ?? x, f = e == null ? void 0 : e.demo;
|
|
2276
2276
|
function g(u) {
|
|
2277
2277
|
let r = new URLSearchParams();
|
|
2278
2278
|
return Object.entries(u).forEach((y) => {
|
|
@@ -2290,11 +2290,11 @@ function En(e) {
|
|
|
2290
2290
|
let r = { ...u.headers };
|
|
2291
2291
|
return u.proxyID && (r.ManagedCompanyAccountID ?? (r.ManagedCompanyAccountID = u.proxyID)), (e == null ? void 0 : e.useBearerToken) != !1 && ((y = e == null ? void 0 : e.auth) == null ? void 0 : y.isLoggedIn.value) == !0 && (r.authorization ?? (r.authorization = `bearer ${(I = e == null ? void 0 : e.auth) == null ? void 0 : I.credentials.value.token}`)), r["Content-Type"] ?? (r["Content-Type"] = u.contentType ?? (e == null ? void 0 : e.defaultContentType) ?? "application/json"), r;
|
|
2292
2292
|
}
|
|
2293
|
-
async function
|
|
2293
|
+
async function T(u) {
|
|
2294
2294
|
const r = u.throwError ?? (e == null ? void 0 : e.defaultThrowError) ?? !0, y = u.returnJson ?? (e == null ? void 0 : e.defaultReturnJson) ?? !0, I = u.returnText ?? (e == null ? void 0 : e.defaultReturnText) ?? !1;
|
|
2295
2295
|
let i = u.finalUrl, E = u.headers;
|
|
2296
|
-
if (i == null && (i = S(u)), u.overrideHeaders !== !0 && (E = t(u)),
|
|
2297
|
-
return console.log(`DEMO: Get from ${i}`),
|
|
2296
|
+
if (i == null && (i = S(u)), u.overrideHeaders !== !0 && (E = t(u)), f != null && f.isDemoing.value)
|
|
2297
|
+
return console.log(`DEMO: Get from ${i}`), f.get(u);
|
|
2298
2298
|
console.log(`Get from ${i}`);
|
|
2299
2299
|
let w;
|
|
2300
2300
|
try {
|
|
@@ -2328,8 +2328,8 @@ function En(e) {
|
|
|
2328
2328
|
async function N(u) {
|
|
2329
2329
|
const r = u.throwError ?? (e == null ? void 0 : e.defaultThrowError) ?? !0, y = u.returnJson ?? (e == null ? void 0 : e.defaultReturnJson) ?? !0, I = u.returnText ?? (e == null ? void 0 : e.defaultReturnText) ?? !1;
|
|
2330
2330
|
let i = u.finalUrl, E = u.headers;
|
|
2331
|
-
if (i == null && (i = S(u)), u.overrideHeaders !== !0 && (E = t(u)),
|
|
2332
|
-
return console.log(`DEMO: Get all from ${i}`),
|
|
2331
|
+
if (i == null && (i = S(u)), u.overrideHeaders !== !0 && (E = t(u)), f != null && f.isDemoing.value)
|
|
2332
|
+
return console.log(`DEMO: Get all from ${i}`), f.getAll(u);
|
|
2333
2333
|
console.log(`Get all from ${i}`);
|
|
2334
2334
|
let w;
|
|
2335
2335
|
try {
|
|
@@ -2363,8 +2363,8 @@ function En(e) {
|
|
|
2363
2363
|
async function $(u) {
|
|
2364
2364
|
const r = u.throwError ?? (e == null ? void 0 : e.defaultThrowError) ?? !0, y = u.returnJson ?? (e == null ? void 0 : e.defaultReturnJson) ?? !0, I = u.returnText ?? (e == null ? void 0 : e.defaultReturnText) ?? !1;
|
|
2365
2365
|
let i = u.finalUrl, E = u.headers;
|
|
2366
|
-
if (i == null && (i = S(u)), u.overrideHeaders !== !0 && (E = t(u)),
|
|
2367
|
-
return console.log(`DEMO: Post to ${i}`),
|
|
2366
|
+
if (i == null && (i = S(u)), u.overrideHeaders !== !0 && (E = t(u)), f != null && f.isDemoing.value)
|
|
2367
|
+
return console.log(`DEMO: Post to ${i}`), f.post(u);
|
|
2368
2368
|
console.log(`Post to ${i}`);
|
|
2369
2369
|
let w;
|
|
2370
2370
|
try {
|
|
@@ -2399,8 +2399,8 @@ function En(e) {
|
|
|
2399
2399
|
async function d(u) {
|
|
2400
2400
|
const r = u.throwError ?? (e == null ? void 0 : e.defaultThrowError) ?? !0, y = u.returnJson ?? (e == null ? void 0 : e.defaultReturnJson) ?? !0, I = u.returnText ?? (e == null ? void 0 : e.defaultReturnText) ?? !1;
|
|
2401
2401
|
let i = u.finalUrl, E = u.headers;
|
|
2402
|
-
if (i == null && (i = S(u)), u.overrideHeaders !== !0 && (E = t(u)),
|
|
2403
|
-
return console.log(`DEMO: Patch to ${i}`),
|
|
2402
|
+
if (i == null && (i = S(u)), u.overrideHeaders !== !0 && (E = t(u)), f != null && f.isDemoing.value)
|
|
2403
|
+
return console.log(`DEMO: Patch to ${i}`), f.patch(u);
|
|
2404
2404
|
console.log(`Patch to ${i}`);
|
|
2405
2405
|
let w;
|
|
2406
2406
|
try {
|
|
@@ -2435,8 +2435,8 @@ function En(e) {
|
|
|
2435
2435
|
async function h(u) {
|
|
2436
2436
|
const r = u.throwError ?? (e == null ? void 0 : e.defaultThrowError) ?? !0;
|
|
2437
2437
|
let y = u.finalUrl, I = u.headers;
|
|
2438
|
-
if (y == null && (y = S(u)), u.overrideHeaders !== !0 && (I = t(u)),
|
|
2439
|
-
return console.log(`DEMO: Delete ${y}`),
|
|
2438
|
+
if (y == null && (y = S(u)), u.overrideHeaders !== !0 && (I = t(u)), f != null && f.isDemoing.value)
|
|
2439
|
+
return console.log(`DEMO: Delete ${y}`), f.deleteItem(u);
|
|
2440
2440
|
console.log(`Delete ${y}`);
|
|
2441
2441
|
let i;
|
|
2442
2442
|
try {
|
|
@@ -2465,14 +2465,14 @@ function En(e) {
|
|
|
2465
2465
|
buildQuery: l,
|
|
2466
2466
|
buildUrl: S,
|
|
2467
2467
|
deleteItem: h,
|
|
2468
|
-
get:
|
|
2468
|
+
get: T,
|
|
2469
2469
|
getAll: N,
|
|
2470
2470
|
patch: d,
|
|
2471
2471
|
post: $
|
|
2472
2472
|
}, Ar;
|
|
2473
2473
|
}
|
|
2474
2474
|
function ut(e) {
|
|
2475
|
-
const { actionErrorMsg: t, actionLoadingMsg: l, clearErrors: S, isLoading:
|
|
2475
|
+
const { actionErrorMsg: t, actionLoadingMsg: l, clearErrors: S, isLoading: f, doAction: g, logError: x } = tn(e);
|
|
2476
2476
|
function P(r) {
|
|
2477
2477
|
r.nav ?? (r.nav = e == null ? void 0 : e.nav), r.proxyID ?? (r.proxyID = e == null ? void 0 : e.proxyID), r.refresh ?? (r.refresh = e == null ? void 0 : e.refresh), r.throwError ?? (r.throwError = e == null ? void 0 : e.throwError), r.url ?? (r.url = e == null ? void 0 : e.url), r.confirmationMsg ?? (r.confirmationMsg = r.requireConfirmation === !0 ? "Are you sure you want to delete this item?" : void 0);
|
|
2478
2478
|
let y = (r == null ? void 0 : r.store) ?? (e == null ? void 0 : e.store);
|
|
@@ -2496,7 +2496,7 @@ function ut(e) {
|
|
|
2496
2496
|
throwError: r.throwError ?? (e == null ? void 0 : e.throwError)
|
|
2497
2497
|
});
|
|
2498
2498
|
}
|
|
2499
|
-
function
|
|
2499
|
+
function T(r) {
|
|
2500
2500
|
r.nav ?? (r.nav = e == null ? void 0 : e.nav), r.proxyID ?? (r.proxyID = e == null ? void 0 : e.proxyID), r.refresh ?? (r.refresh = e == null ? void 0 : e.refresh), r.throwError ?? (r.throwError = e == null ? void 0 : e.throwError), r.url ?? (r.url = e == null ? void 0 : e.url), r.confirmationMsg ?? (r.confirmationMsg = r.requireConfirmation === !0 ? "Are you sure you want to get this item?" : void 0);
|
|
2501
2501
|
let y = (r == null ? void 0 : r.store) ?? (e == null ? void 0 : e.store);
|
|
2502
2502
|
const I = (e == null ? void 0 : e.items) ?? [];
|
|
@@ -2592,8 +2592,8 @@ function ut(e) {
|
|
|
2592
2592
|
deleteItem: P,
|
|
2593
2593
|
doAction: g,
|
|
2594
2594
|
getAllItems: N,
|
|
2595
|
-
getItem:
|
|
2596
|
-
isLoading:
|
|
2595
|
+
getItem: T,
|
|
2596
|
+
isLoading: f,
|
|
2597
2597
|
logError: x,
|
|
2598
2598
|
restoreItem: $,
|
|
2599
2599
|
saveItem: d
|
|
@@ -2601,17 +2601,17 @@ function ut(e) {
|
|
|
2601
2601
|
}
|
|
2602
2602
|
let hr = "Australia/Melbourne", Ir;
|
|
2603
2603
|
const Hr = "auth-credentials-state";
|
|
2604
|
-
function
|
|
2604
|
+
function xn() {
|
|
2605
2605
|
return Ir;
|
|
2606
2606
|
}
|
|
2607
|
-
function
|
|
2607
|
+
function _n(e) {
|
|
2608
2608
|
const t = e.expiryTokenFormat ?? "d/MM/yyyy h:mm:ss a";
|
|
2609
2609
|
let l = z(localStorage.getItem(Hr) ?? "");
|
|
2610
2610
|
l.value.length == 0 && S();
|
|
2611
2611
|
function S() {
|
|
2612
2612
|
l.value = Math.random().toString(36).substring(4, 19) + Math.random().toString(12).substring(1, 11), localStorage.setItem(Hr, l.value);
|
|
2613
2613
|
}
|
|
2614
|
-
const
|
|
2614
|
+
const f = jt("auth-credentials", {});
|
|
2615
2615
|
function g(D) {
|
|
2616
2616
|
if (D == null)
|
|
2617
2617
|
return !0;
|
|
@@ -2620,10 +2620,10 @@ function Dn(e) {
|
|
|
2620
2620
|
return !1;
|
|
2621
2621
|
if (L.requiresAuth === !1)
|
|
2622
2622
|
return !0;
|
|
2623
|
-
const
|
|
2624
|
-
if (
|
|
2623
|
+
const s = K(f);
|
|
2624
|
+
if (s.isSuspended && L.ignoreSuspension !== !0)
|
|
2625
2625
|
return !1;
|
|
2626
|
-
if (
|
|
2626
|
+
if (s.isGlobalAdmin)
|
|
2627
2627
|
return !0;
|
|
2628
2628
|
if (L.permissions != null) {
|
|
2629
2629
|
for (var A = 0; A < L.permissions.length; A++)
|
|
@@ -2633,11 +2633,11 @@ function Dn(e) {
|
|
|
2633
2633
|
return !0;
|
|
2634
2634
|
}
|
|
2635
2635
|
function x(D) {
|
|
2636
|
-
const L = K(
|
|
2636
|
+
const L = K(f);
|
|
2637
2637
|
if (L.userPermissions != null)
|
|
2638
|
-
for (var
|
|
2639
|
-
var A = L.userPermissions[
|
|
2640
|
-
if (L.userPermissions[
|
|
2638
|
+
for (var s = 0; s < L.userPermissions.length; s++) {
|
|
2639
|
+
var A = L.userPermissions[s].split(".");
|
|
2640
|
+
if (L.userPermissions[s] == "everything.edit" || D == A[0] && A.length > 1 && A[1] == "edit")
|
|
2641
2641
|
return !0;
|
|
2642
2642
|
}
|
|
2643
2643
|
return !1;
|
|
@@ -2650,89 +2650,89 @@ function Dn(e) {
|
|
|
2650
2650
|
return !1;
|
|
2651
2651
|
if (L.requiresAuth === !1)
|
|
2652
2652
|
return !0;
|
|
2653
|
-
const
|
|
2654
|
-
if (
|
|
2653
|
+
const s = K(f);
|
|
2654
|
+
if (s.isSuspended && L.ignoreSuspension !== !0)
|
|
2655
2655
|
return !1;
|
|
2656
|
-
if (
|
|
2656
|
+
if (s.isGlobalAdmin)
|
|
2657
2657
|
return !0;
|
|
2658
2658
|
if (L.permissions != null) {
|
|
2659
2659
|
for (var A = 0; A < L.permissions.length; A++)
|
|
2660
|
-
if (!
|
|
2660
|
+
if (!T(L.permissions[A]))
|
|
2661
2661
|
return !1;
|
|
2662
2662
|
}
|
|
2663
2663
|
return !0;
|
|
2664
2664
|
}
|
|
2665
|
-
function
|
|
2666
|
-
const L = K(
|
|
2665
|
+
function T(D) {
|
|
2666
|
+
const L = K(f);
|
|
2667
2667
|
if (L.userPermissions != null)
|
|
2668
|
-
for (var
|
|
2669
|
-
var A = L.userPermissions[
|
|
2670
|
-
if (D == A[0] || D == "everything" || L.userPermissions[
|
|
2668
|
+
for (var s = 0; s < L.userPermissions.length; s++) {
|
|
2669
|
+
var A = L.userPermissions[s].split(".");
|
|
2670
|
+
if (D == A[0] || D == "everything" || L.userPermissions[s] == "everything.view" || L.userPermissions[s] == "everything.edit")
|
|
2671
2671
|
return !0;
|
|
2672
2672
|
}
|
|
2673
2673
|
return !1;
|
|
2674
2674
|
}
|
|
2675
|
-
function N(D, L,
|
|
2675
|
+
function N(D, L, s) {
|
|
2676
2676
|
let A = !0;
|
|
2677
|
-
return K(
|
|
2678
|
-
|
|
2677
|
+
return K(f).isGlobalAdmin ? !0 : (L != null && L.length > 0 && L.forEach((Q) => {
|
|
2678
|
+
s == "edit" ? x(Q) || (A = !1) : T(Q) || (A = !1);
|
|
2679
2679
|
}), D != null && D.length > 0 && (D.some((Q) => u(Q)) || (A = !1)), A);
|
|
2680
2680
|
}
|
|
2681
2681
|
function $(D, L = !1) {
|
|
2682
|
-
var
|
|
2682
|
+
var s = e.getAuthItem != null ? e.getAuthItem(D) : null;
|
|
2683
2683
|
let A = !1;
|
|
2684
|
-
if (
|
|
2684
|
+
if (s == null)
|
|
2685
2685
|
return !1;
|
|
2686
|
-
let J =
|
|
2687
|
-
return ee || !L || !
|
|
2686
|
+
let J = s.subscriptions ?? [], Q = s.permissions ?? [], ee = N(J, Q, "view");
|
|
2687
|
+
return ee || !L || !Te(s.children) ? ee : ((s == null ? void 0 : s.children) != null && s.children.forEach((ce) => {
|
|
2688
2688
|
$(ce, !0) && (A = !0);
|
|
2689
2689
|
}), A);
|
|
2690
2690
|
}
|
|
2691
2691
|
function d(D) {
|
|
2692
|
-
return e.getAuthorizeUrl ?? (e.getAuthorizeUrl = (L,
|
|
2693
|
-
const A = Be(Wr(), `authorize?response_type=code&client_id=${e.oauthClientID}&redirect_uri=${window.location.origin}/authentication&state=${
|
|
2692
|
+
return e.getAuthorizeUrl ?? (e.getAuthorizeUrl = (L, s) => {
|
|
2693
|
+
const A = Be(Wr(), `authorize?response_type=code&client_id=${e.oauthClientID}&redirect_uri=${window.location.origin}/authentication&state=${s}`);
|
|
2694
2694
|
return L ? `${A}&redirect_path=${L}` : A;
|
|
2695
2695
|
}), e.getAuthorizeUrl != null ? e.getAuthorizeUrl(D, l.value) ?? "" : "";
|
|
2696
2696
|
}
|
|
2697
2697
|
function h(D) {
|
|
2698
|
-
var
|
|
2699
|
-
return D == null ? 0 : ((
|
|
2698
|
+
var s;
|
|
2699
|
+
return D == null ? 0 : ((s = (e.subscriptionOptions ?? []).find((A) => A.code == D)) == null ? void 0 : s.value) ?? 0;
|
|
2700
2700
|
}
|
|
2701
2701
|
function u(D) {
|
|
2702
|
-
const L = K(
|
|
2702
|
+
const L = K(f);
|
|
2703
2703
|
if (L.subscriptionCode == null)
|
|
2704
2704
|
return !1;
|
|
2705
2705
|
if (L.subscriptionCode == D)
|
|
2706
2706
|
return !0;
|
|
2707
|
-
const
|
|
2708
|
-
return
|
|
2707
|
+
const s = h(D), A = h(L.subscriptionCode);
|
|
2708
|
+
return s <= A;
|
|
2709
2709
|
}
|
|
2710
2710
|
function r(D) {
|
|
2711
|
-
const
|
|
2712
|
-
atob(
|
|
2711
|
+
const s = D.split(".")[1].replace(/-/g, "+").replace(/_/g, "/"), A = decodeURIComponent(
|
|
2712
|
+
atob(s).split("").map(function(J) {
|
|
2713
2713
|
return "%" + ("00" + J.charCodeAt(0).toString(16)).slice(-2);
|
|
2714
2714
|
}).join("")
|
|
2715
2715
|
);
|
|
2716
2716
|
return JSON.parse(A);
|
|
2717
2717
|
}
|
|
2718
2718
|
function y(D, L) {
|
|
2719
|
-
|
|
2719
|
+
f.value = void 0, M(), D != null && L != null && L.currentRoute.value.path != D && L.push({ path: D });
|
|
2720
2720
|
}
|
|
2721
2721
|
function I(D) {
|
|
2722
|
-
var
|
|
2723
|
-
K(
|
|
2722
|
+
var s;
|
|
2723
|
+
K(f).isLoggedIn || ((s = e.demo) == null || s.endDemo(), _() && (y(), window.location.href = d(D)));
|
|
2724
2724
|
}
|
|
2725
2725
|
async function i(D, L) {
|
|
2726
2726
|
return e.getToken ?? (e.getToken = async () => {
|
|
2727
|
-
let
|
|
2728
|
-
if (
|
|
2727
|
+
let s = D, A = L, J = e.oauthGrantType ?? "authorization_token", Q = e.oauthClientID ?? "";
|
|
2728
|
+
if (s == null || A == null)
|
|
2729
2729
|
throw new Error("Code and State required in OAuth token process");
|
|
2730
2730
|
if (A != l.value)
|
|
2731
2731
|
throw new Error("state does not match");
|
|
2732
2732
|
let ee = "";
|
|
2733
|
-
e.getTokenUrl ?? (e.getTokenUrl = () => Be(Wr(), "token")), ee = e.getTokenUrl(
|
|
2733
|
+
e.getTokenUrl ?? (e.getTokenUrl = () => Be(Wr(), "token")), ee = e.getTokenUrl(s, `${window.location.origin}/authentication`, J, Q);
|
|
2734
2734
|
const ce = {};
|
|
2735
|
-
ce.grant_type = J, ce.code =
|
|
2735
|
+
ce.grant_type = J, ce.code = s, ce.redirect_uri = `${window.location.origin}/authentication`, ce.client_id = Q;
|
|
2736
2736
|
const W = await Er().post({
|
|
2737
2737
|
additionalUrl: ee,
|
|
2738
2738
|
data: ce
|
|
@@ -2743,93 +2743,93 @@ function Dn(e) {
|
|
|
2743
2743
|
function E(D) {
|
|
2744
2744
|
if (D != null && (e.demo == null || !e.demo.isDemoing.value)) {
|
|
2745
2745
|
const L = r(D);
|
|
2746
|
-
w(L, D), e.processTokenPayload != null && e.processTokenPayload(
|
|
2746
|
+
w(L, D), e.processTokenPayload != null && e.processTokenPayload(f, L);
|
|
2747
2747
|
}
|
|
2748
2748
|
}
|
|
2749
2749
|
function w(D, L) {
|
|
2750
2750
|
var A;
|
|
2751
|
-
const
|
|
2752
|
-
|
|
2751
|
+
const s = f.value;
|
|
2752
|
+
s.expiresOn = D.ExpiresOn, s.isGlobalAdmin = D.IsGlobalAdmin == "True", s.isLoggedIn = !0, s.permissions = D.Permissions, s.subscriptionCode = D.Subscription, s.timeZone ?? (s.timeZone = e.defaultTimeZone ?? hr), s.token = L, s.userID = D.UserLoginID, s.userPermissions = ((A = D.Permissions) == null ? void 0 : A.split(",")) ?? [];
|
|
2753
2753
|
}
|
|
2754
2754
|
function M() {
|
|
2755
2755
|
var D;
|
|
2756
|
-
|
|
2756
|
+
f.value ?? (f.value = {}), (D = f.value).timeZone ?? (D.timeZone = e.defaultTimeZone ?? hr);
|
|
2757
2757
|
}
|
|
2758
2758
|
function b() {
|
|
2759
|
-
const D = K(
|
|
2760
|
-
return D.isLoggedIn &&
|
|
2759
|
+
const D = K(f);
|
|
2760
|
+
return D.isLoggedIn && _() && (y(), window.location.href = d()), D.isLoggedIn;
|
|
2761
2761
|
}
|
|
2762
|
-
function
|
|
2763
|
-
const D = K(
|
|
2762
|
+
function _() {
|
|
2763
|
+
const D = K(f);
|
|
2764
2764
|
if (D == null || D.expiresOn == null)
|
|
2765
2765
|
return !0;
|
|
2766
|
-
const L = he.fromFormat(D.expiresOn, t),
|
|
2767
|
-
return L <=
|
|
2766
|
+
const L = he.fromFormat(D.expiresOn, t), s = he.utc();
|
|
2767
|
+
return L <= s;
|
|
2768
2768
|
}
|
|
2769
2769
|
return M(), Ir = {
|
|
2770
2770
|
authState: l,
|
|
2771
2771
|
canEdit: g,
|
|
2772
2772
|
canEditPermit: x,
|
|
2773
2773
|
canView: P,
|
|
2774
|
-
canViewPermit:
|
|
2775
|
-
credentials:
|
|
2774
|
+
canViewPermit: T,
|
|
2775
|
+
credentials: f,
|
|
2776
2776
|
doShow: N,
|
|
2777
2777
|
doShowByNav: $,
|
|
2778
2778
|
getAuthorizeUrl: d,
|
|
2779
2779
|
getToken: i,
|
|
2780
|
-
isLoggedIn: te(() =>
|
|
2780
|
+
isLoggedIn: te(() => f.value.isLoggedIn === !0),
|
|
2781
2781
|
login: I,
|
|
2782
2782
|
logout: y,
|
|
2783
2783
|
resetAuthState: S,
|
|
2784
2784
|
setAuth: E,
|
|
2785
|
-
timeZone: te(() =>
|
|
2785
|
+
timeZone: te(() => f.value.timeZone ?? e.defaultTimeZone ?? hr),
|
|
2786
2786
|
tryLogin: b
|
|
2787
2787
|
}, Ir;
|
|
2788
2788
|
}
|
|
2789
|
-
function
|
|
2789
|
+
function Tn(e, t, l = {}) {
|
|
2790
2790
|
const {
|
|
2791
2791
|
preventDefault: S = !1,
|
|
2792
|
-
stopPropagation:
|
|
2792
|
+
stopPropagation: f = !1,
|
|
2793
2793
|
axis: g = "both"
|
|
2794
2794
|
} = l, x = { capture: l.capture ?? !0 };
|
|
2795
|
-
let P = { x: 0, y: 0 },
|
|
2795
|
+
let P = { x: 0, y: 0 }, T = { x: 0, y: 0 }, N = { x: 0, y: 0 }, $ = [], d = [], h = z(!1);
|
|
2796
2796
|
function u(M) {
|
|
2797
|
-
K(S) && M.preventDefault(), K(
|
|
2797
|
+
K(S) && M.preventDefault(), K(f) && M.stopPropagation();
|
|
2798
2798
|
}
|
|
2799
2799
|
function r(M) {
|
|
2800
|
-
var
|
|
2800
|
+
var s;
|
|
2801
2801
|
const b = K(e);
|
|
2802
2802
|
if (!b)
|
|
2803
2803
|
return;
|
|
2804
|
-
const
|
|
2805
|
-
N = { x: L.clientX, y: L.clientY },
|
|
2806
|
-
x:
|
|
2807
|
-
y:
|
|
2804
|
+
const _ = b.$el, L = M.type === "touchstart" && M.touches.length > 0 ? M.touches[0] : M;
|
|
2805
|
+
N = { x: L.clientX, y: L.clientY }, T = {
|
|
2806
|
+
x: _.offsetLeft,
|
|
2807
|
+
y: _.offsetTop
|
|
2808
2808
|
}, P = {
|
|
2809
|
-
x:
|
|
2810
|
-
y:
|
|
2811
|
-
}, ((
|
|
2809
|
+
x: _.offsetLeft,
|
|
2810
|
+
y: _.offsetTop
|
|
2811
|
+
}, ((s = l.onStart) == null ? void 0 : s.call(l, N, M)) !== !1 && (d.push(me("mousemove", y)), d.push(me("touchmove", y)), d.push(me("mouseup", I)), d.push(me("touchend", I)), u(M));
|
|
2812
2812
|
}
|
|
2813
2813
|
function y(M) {
|
|
2814
2814
|
var A;
|
|
2815
2815
|
if (!N || !K(e))
|
|
2816
2816
|
return;
|
|
2817
2817
|
const D = M.type === "touchmove" && M.touches.length > 0 ? M.touches[0] : M;
|
|
2818
|
-
let L = D.clientX - N.x,
|
|
2819
|
-
(g === "x" || g === "both") && (P.x =
|
|
2818
|
+
let L = D.clientX - N.x, s = D.clientY - N.y;
|
|
2819
|
+
(g === "x" || g === "both") && (P.x = T.x + L), (g === "y" || g === "both") && (P.y = T.y + s), (A = l.onMove) == null || A.call(l, P, M), u(M), i(P);
|
|
2820
2820
|
}
|
|
2821
2821
|
function I(M) {
|
|
2822
2822
|
var b;
|
|
2823
|
-
document.documentElement.style.cursor = "", d.forEach((
|
|
2824
|
-
|
|
2823
|
+
document.documentElement.style.cursor = "", d.forEach((_) => {
|
|
2824
|
+
_();
|
|
2825
2825
|
}), d.length = 0, (b = l.onEnd) == null || b.call(l, P, M), u(M);
|
|
2826
2826
|
}
|
|
2827
2827
|
function i(M) {
|
|
2828
2828
|
const b = K(e);
|
|
2829
2829
|
if (!b)
|
|
2830
2830
|
return;
|
|
2831
|
-
const
|
|
2832
|
-
|
|
2831
|
+
const _ = b.$el;
|
|
2832
|
+
_.style.left = `${M.x}px`, _.style.top = `${M.y}px`;
|
|
2833
2833
|
}
|
|
2834
2834
|
function E() {
|
|
2835
2835
|
if (K(h))
|
|
@@ -2847,8 +2847,8 @@ function xn(e, t, l = {}) {
|
|
|
2847
2847
|
if (!M)
|
|
2848
2848
|
return;
|
|
2849
2849
|
const b = M.$el;
|
|
2850
|
-
b.style.cursor = "", $.forEach((
|
|
2851
|
-
|
|
2850
|
+
b.style.cursor = "", $.forEach((_) => {
|
|
2851
|
+
_();
|
|
2852
2852
|
}), $.length = 0, h.value = !1;
|
|
2853
2853
|
}
|
|
2854
2854
|
return {
|
|
@@ -2857,9 +2857,9 @@ function xn(e, t, l = {}) {
|
|
|
2857
2857
|
turnDraggableOn: E
|
|
2858
2858
|
};
|
|
2859
2859
|
}
|
|
2860
|
-
const
|
|
2861
|
-
function
|
|
2862
|
-
let l, S = t.handleWidth ?? 12,
|
|
2860
|
+
const Cn = ["t", "r", "b", "l", "tr", "br", "bl", "tl"];
|
|
2861
|
+
function Pn(e, t = {}) {
|
|
2862
|
+
let l, S = t.handleWidth ?? 12, f = t.handleZIndex ?? 100, g = t.minWidth ?? 0, x = t.maxWidth ?? Number.MAX_SAFE_INTEGER, P = t.minHeight ?? 0, T = t.maxHeight ?? Number.MAX_SAFE_INTEGER, N = t.preventDefault ?? !1, $ = t.stopPropagation ?? !1, d, h = [];
|
|
2863
2863
|
const u = z(!1);
|
|
2864
2864
|
let r = [], y = [];
|
|
2865
2865
|
const I = z(!1), i = z({ x: 0, y: 0 });
|
|
@@ -2870,12 +2870,12 @@ function _n(e, t = {}) {
|
|
|
2870
2870
|
function b(W, Y) {
|
|
2871
2871
|
h = Y.map(D), h.forEach((H) => W.$el.appendChild(H));
|
|
2872
2872
|
}
|
|
2873
|
-
function
|
|
2873
|
+
function _(W) {
|
|
2874
2874
|
h.forEach((Y) => W.$el.removeChild(Y));
|
|
2875
2875
|
}
|
|
2876
2876
|
function D(W) {
|
|
2877
|
-
const Y = S + "px", H = -S / 2 + "px", ae =
|
|
2878
|
-
return G.dataset.handle = W, G.style.position = "absolute", G.style.touchAction = "none", G.style.userSelect = "none", G.style.zIndex = (W.length === 1 ?
|
|
2877
|
+
const Y = S + "px", H = -S / 2 + "px", ae = f + 1, G = document.createElement("div");
|
|
2878
|
+
return G.dataset.handle = W, G.style.position = "absolute", G.style.touchAction = "none", G.style.userSelect = "none", G.style.zIndex = (W.length === 1 ? f : ae).toString(), G.style.cursor = J(W), W.includes("t") && (G.style.top = H, G.style.height = Y, W === "t" && (G.style.left = "0", G.style.width = "100%")), W.includes("b") && (G.style.bottom = H, G.style.height = Y, W === "b" && (G.style.left = "0", G.style.width = "100%")), W.includes("r") && (G.style.right = H, G.style.width = Y, W === "r" && (G.style.top = "0", G.style.height = "100%")), W.includes("l") && (G.style.left = H, G.style.width = Y, W === "l" && (G.style.top = "0", G.style.height = "100%")), G;
|
|
2879
2879
|
}
|
|
2880
2880
|
function L(W) {
|
|
2881
2881
|
var ne;
|
|
@@ -2893,9 +2893,9 @@ function _n(e, t = {}) {
|
|
|
2893
2893
|
}, w = Lr(E), ((ne = t.onStart) == null ? void 0 : ne.call(t, i.value, W)) === !1)
|
|
2894
2894
|
return;
|
|
2895
2895
|
let X = W.target;
|
|
2896
|
-
document.documentElement.style.cursor = J(X.dataset.handle), d = X.dataset.handle, y.push(me("mousemove",
|
|
2896
|
+
document.documentElement.style.cursor = J(X.dataset.handle), d = X.dataset.handle, y.push(me("mousemove", s)), y.push(me("mouseup", A)), y.push(me("touchmove", s)), y.push(me("touchend", A)), M(W);
|
|
2897
2897
|
}
|
|
2898
|
-
function
|
|
2898
|
+
function s(W) {
|
|
2899
2899
|
const Y = Ae(e);
|
|
2900
2900
|
if (!Y)
|
|
2901
2901
|
return;
|
|
@@ -2903,11 +2903,11 @@ function _n(e, t = {}) {
|
|
|
2903
2903
|
let X = G.clientX - i.value.x, ne = G.clientY - i.value.y;
|
|
2904
2904
|
const se = Ae(E);
|
|
2905
2905
|
if (d.includes("t")) {
|
|
2906
|
-
const fe = Math.min(
|
|
2906
|
+
const fe = Math.min(T, Math.max(P, (se.height ?? 0) - ne));
|
|
2907
2907
|
w.height = fe, w.top = (se.top ?? 0) + ne;
|
|
2908
2908
|
}
|
|
2909
2909
|
if (d.includes("b")) {
|
|
2910
|
-
const fe = Math.min(
|
|
2910
|
+
const fe = Math.min(T, Math.max(P, (se.height ?? 0) + ne));
|
|
2911
2911
|
w.height = fe;
|
|
2912
2912
|
}
|
|
2913
2913
|
if (d.includes("l")) {
|
|
@@ -2940,7 +2940,7 @@ function _n(e, t = {}) {
|
|
|
2940
2940
|
return;
|
|
2941
2941
|
const H = Y.$el;
|
|
2942
2942
|
if (console.log(l), l !== "page" && W == "page") {
|
|
2943
|
-
const ae =
|
|
2943
|
+
const ae = Kt(H), G = Ae(ae) ?? null;
|
|
2944
2944
|
let X = 0;
|
|
2945
2945
|
if (G != null) {
|
|
2946
2946
|
const ne = window.getComputedStyle(G);
|
|
@@ -2992,13 +2992,13 @@ function _n(e, t = {}) {
|
|
|
2992
2992
|
if (I.value)
|
|
2993
2993
|
return;
|
|
2994
2994
|
const H = Ae(e);
|
|
2995
|
-
H && (b(H, W ??
|
|
2995
|
+
H && (b(H, W ?? Cn), Q(Y), r.push(me(H.$el, "mousedown", L)), r.push(me(H.$el, "touchstart", L)), I.value = !0, l = Y);
|
|
2996
2996
|
}
|
|
2997
2997
|
function we(W) {
|
|
2998
2998
|
if (!I.value)
|
|
2999
2999
|
return;
|
|
3000
3000
|
const Y = Ae(e);
|
|
3001
|
-
Y && (
|
|
3001
|
+
Y && (_(Y), Q(W), r.forEach((H) => {
|
|
3002
3002
|
H();
|
|
3003
3003
|
}), r.length = 0, I.value = !1);
|
|
3004
3004
|
}
|
|
@@ -3008,16 +3008,16 @@ function _n(e, t = {}) {
|
|
|
3008
3008
|
turnResizingOff: we
|
|
3009
3009
|
};
|
|
3010
3010
|
}
|
|
3011
|
-
function
|
|
3012
|
-
const t = (e == null ? void 0 : e.blade) ?? z(null), l = (e == null ? void 0 : e.handle) ?? z(null), S = z(!1),
|
|
3013
|
-
|
|
3011
|
+
function Nn(e) {
|
|
3012
|
+
const t = (e == null ? void 0 : e.blade) ?? z(null), l = (e == null ? void 0 : e.handle) ?? z(null), S = z(!1), f = (e == null ? void 0 : e.mobileBreakpoint) ?? 500, g = z((e == null ? void 0 : e.defaultVariant) ?? "page"), x = z({}), { turnResizingOff: P, turnResizingOn: T } = Pn(t), { turnDraggableOff: N, turnDraggableOn: $ } = Tn(t, l);
|
|
3013
|
+
Qt(t, (h) => {
|
|
3014
3014
|
const u = h[0], { width: r } = u.contentRect;
|
|
3015
|
-
S.value = r <
|
|
3015
|
+
S.value = r < f;
|
|
3016
3016
|
});
|
|
3017
3017
|
function d(h) {
|
|
3018
|
-
N(), h == "page" ? P(h) : h == "blade" ?
|
|
3018
|
+
N(), h == "page" ? P(h) : h == "blade" ? T(["l", "r"], h) : h == "freestyle" ? (P(), T(void 0, h), $()) : h == "inline" && P();
|
|
3019
3019
|
}
|
|
3020
|
-
return d(g.value),
|
|
3020
|
+
return d(g.value), _e(g, (h) => d(h)), {
|
|
3021
3021
|
isMobile: S,
|
|
3022
3022
|
variant: g,
|
|
3023
3023
|
bladeData: x
|
|
@@ -3041,10 +3041,10 @@ const mr = {
|
|
|
3041
3041
|
warning: "#FB8C00"
|
|
3042
3042
|
};
|
|
3043
3043
|
let Dr;
|
|
3044
|
-
function
|
|
3044
|
+
function Ea() {
|
|
3045
3045
|
return Dr;
|
|
3046
3046
|
}
|
|
3047
|
-
function
|
|
3047
|
+
function Ia(e) {
|
|
3048
3048
|
const t = localStorage.getItem("cosmetics");
|
|
3049
3049
|
let l;
|
|
3050
3050
|
return t != null && t.length > 0 && (l = JSON.parse(t)), l ?? (l = {}), l.dark ?? (l.dark = e == null ? void 0 : e.dark), l.light ?? (l.light = e == null ? void 0 : e.light), l.theme ?? (l.theme = e == null ? void 0 : e.defaultTheme), {
|
|
@@ -3059,7 +3059,7 @@ function ya(e) {
|
|
|
3059
3059
|
}
|
|
3060
3060
|
};
|
|
3061
3061
|
}
|
|
3062
|
-
function
|
|
3062
|
+
function Mn(e) {
|
|
3063
3063
|
const t = z({});
|
|
3064
3064
|
let l = e.vuetifyInstance;
|
|
3065
3065
|
function S() {
|
|
@@ -3072,7 +3072,7 @@ function Pn(e) {
|
|
|
3072
3072
|
drawerStick: e.defaultDrawerStick ?? !1
|
|
3073
3073
|
};
|
|
3074
3074
|
}
|
|
3075
|
-
function
|
|
3075
|
+
function f() {
|
|
3076
3076
|
localStorage.setItem("cosmetics", JSON.stringify(t.value));
|
|
3077
3077
|
}
|
|
3078
3078
|
function g(d) {
|
|
@@ -3100,7 +3100,7 @@ function Pn(e) {
|
|
|
3100
3100
|
function P() {
|
|
3101
3101
|
t.value.drawer = !t.value.drawer;
|
|
3102
3102
|
}
|
|
3103
|
-
function
|
|
3103
|
+
function T() {
|
|
3104
3104
|
t.value.drawerStick = !t.value.drawerStick;
|
|
3105
3105
|
}
|
|
3106
3106
|
function N() {
|
|
@@ -3113,47 +3113,47 @@ function Pn(e) {
|
|
|
3113
3113
|
h.colors.primary = (t.value.dark ?? { ...vr, ...e.defaultDarkTheme }).primary, u.colors.primary = (t.value.light ?? { ...mr, ...e.defaultLightTheme }).primary, (d = document.querySelector('meta[name="theme-color"]')) == null || d.setAttribute("content", "");
|
|
3114
3114
|
}
|
|
3115
3115
|
}
|
|
3116
|
-
return S(),
|
|
3117
|
-
|
|
3116
|
+
return S(), _e(t, () => {
|
|
3117
|
+
f();
|
|
3118
3118
|
}), Dr = {
|
|
3119
3119
|
state: t,
|
|
3120
3120
|
resetCosmetics: g,
|
|
3121
3121
|
setTemporaryColor: x,
|
|
3122
3122
|
toggleDrawer: P,
|
|
3123
|
-
toggleDrawerStick:
|
|
3123
|
+
toggleDrawerStick: T,
|
|
3124
3124
|
toggleLightDark: N,
|
|
3125
3125
|
undoTemporaryColor: $
|
|
3126
3126
|
}, Dr;
|
|
3127
3127
|
}
|
|
3128
|
-
const
|
|
3128
|
+
const Da = {
|
|
3129
3129
|
canExportCSV: !1
|
|
3130
3130
|
};
|
|
3131
|
-
function
|
|
3131
|
+
function Ln() {
|
|
3132
3132
|
function e(t) {
|
|
3133
3133
|
const {
|
|
3134
3134
|
items: l,
|
|
3135
3135
|
headers: S,
|
|
3136
|
-
fileName:
|
|
3136
|
+
fileName: f = "data.csv",
|
|
3137
3137
|
format: g = "file"
|
|
3138
3138
|
} = t;
|
|
3139
|
-
if (!
|
|
3139
|
+
if (!Te(l))
|
|
3140
3140
|
return;
|
|
3141
3141
|
let x = [];
|
|
3142
3142
|
S != null ? x = S == null ? void 0 : S.filter((I) => (I.csv ?? I.csvText ?? I.csvFilter ?? I.csvArray) != null).map((I) => ({
|
|
3143
3143
|
header: I.title ?? I.value ?? "",
|
|
3144
3144
|
itemText: I.itemText,
|
|
3145
3145
|
value: I.value
|
|
3146
|
-
})) : x = Object.keys(l[0]).map((I) => ({ header:
|
|
3146
|
+
})) : x = Object.keys(l[0]).map((I) => ({ header: an(I) ?? "", value: I })), x = x.filter((I) => I.header.length > 0);
|
|
3147
3147
|
var P = [];
|
|
3148
3148
|
for (let I = 0; I < l.length; I++) {
|
|
3149
3149
|
const i = l[I];
|
|
3150
|
-
var
|
|
3150
|
+
var T = {}, N = [];
|
|
3151
3151
|
for (let E = 0; E < x.length; E++) {
|
|
3152
3152
|
const w = x[E];
|
|
3153
3153
|
var $ = null;
|
|
3154
|
-
typeof w.value == "function" ? $ = w.value(i) : typeof w.value == "string" && ($ = Sr(i, w.value)), w.itemText != null ?
|
|
3154
|
+
typeof w.value == "function" ? $ = w.value(i) : typeof w.value == "string" && ($ = Sr(i, w.value)), w.itemText != null ? T[w.header] = Sr($, w.itemText) : T[w.header] = $;
|
|
3155
3155
|
}
|
|
3156
|
-
P.push(
|
|
3156
|
+
P.push(T), Te(N) && N.forEach((E) => {
|
|
3157
3157
|
P.push(E);
|
|
3158
3158
|
}), N = [];
|
|
3159
3159
|
}
|
|
@@ -3169,10 +3169,10 @@ function Nn() {
|
|
|
3169
3169
|
var h = d.join(`
|
|
3170
3170
|
`), u = new Blob([h], { type: "text/plain;charset=utf-8" });
|
|
3171
3171
|
if (window.navigator.msSaveOrOpenBlob)
|
|
3172
|
-
window.navigator.msSaveOrOpenBlob(u,
|
|
3172
|
+
window.navigator.msSaveOrOpenBlob(u, f);
|
|
3173
3173
|
else {
|
|
3174
3174
|
var r = document.createElement("a"), y = URL.createObjectURL(u);
|
|
3175
|
-
r.href = y, r.download =
|
|
3175
|
+
r.href = y, r.download = f, document.body.appendChild(r), r.click(), setTimeout(function() {
|
|
3176
3176
|
document.body.removeChild(r), window.URL.revokeObjectURL(y);
|
|
3177
3177
|
}, 0);
|
|
3178
3178
|
}
|
|
@@ -3182,60 +3182,60 @@ function Nn() {
|
|
|
3182
3182
|
};
|
|
3183
3183
|
}
|
|
3184
3184
|
let xr;
|
|
3185
|
-
function
|
|
3185
|
+
function xa() {
|
|
3186
3186
|
return xr;
|
|
3187
3187
|
}
|
|
3188
|
-
function
|
|
3188
|
+
function Rn(e) {
|
|
3189
3189
|
const t = e.getUTC ?? he.utc;
|
|
3190
3190
|
function l() {
|
|
3191
|
-
return
|
|
3191
|
+
return f().startOf("day").toUTC().toString() ?? "";
|
|
3192
3192
|
}
|
|
3193
3193
|
function S() {
|
|
3194
|
-
return
|
|
3194
|
+
return f().startOf("day").plus({ day: 1 }).toUTC().toString() ?? "";
|
|
3195
3195
|
}
|
|
3196
|
-
function
|
|
3197
|
-
return
|
|
3196
|
+
function f(T, N) {
|
|
3197
|
+
return T == null ? t().setZone(e.getTimeZone()) : N ? he.fromFormat(T, N, { zone: e.getTimeZone() }) : he.fromISO(T, { zone: e.getTimeZone() });
|
|
3198
3198
|
}
|
|
3199
|
-
function g(
|
|
3200
|
-
if (
|
|
3199
|
+
function g(T, N, $) {
|
|
3200
|
+
if (T == null) {
|
|
3201
3201
|
const h = t().setZone(e.getTimeZone());
|
|
3202
3202
|
return N ? h.toFormat(N) : h.toString();
|
|
3203
3203
|
}
|
|
3204
|
-
if (
|
|
3204
|
+
if (T == "Invalid DateTime")
|
|
3205
3205
|
return "";
|
|
3206
|
-
const d = $ ? he.fromFormat(
|
|
3206
|
+
const d = $ ? he.fromFormat(T, $, { zone: e.getTimeZone() }) : he.fromISO(T, { zone: e.getTimeZone() });
|
|
3207
3207
|
return N ? d.toFormat(N) : d == null ? void 0 : d.toString();
|
|
3208
3208
|
}
|
|
3209
|
-
function x(
|
|
3210
|
-
return
|
|
3209
|
+
function x(T, N) {
|
|
3210
|
+
return T == null ? t() : N ? he.fromFormat(T, N) : he.fromISO(T);
|
|
3211
3211
|
}
|
|
3212
|
-
function P(
|
|
3213
|
-
if (
|
|
3212
|
+
function P(T, N, $) {
|
|
3213
|
+
if (T == null)
|
|
3214
3214
|
return N ? t().toFormat(N) : t().toString();
|
|
3215
3215
|
{
|
|
3216
|
-
const d = $ ? he.fromFormat(
|
|
3216
|
+
const d = $ ? he.fromFormat(T, $) : he.fromISO(T);
|
|
3217
3217
|
return N ? d.toFormat(N) : d.toString();
|
|
3218
3218
|
}
|
|
3219
3219
|
}
|
|
3220
3220
|
return xr = {
|
|
3221
3221
|
getToday: l,
|
|
3222
3222
|
getTomorrow: S,
|
|
3223
|
-
tzDate:
|
|
3223
|
+
tzDate: f,
|
|
3224
3224
|
tzString: g,
|
|
3225
3225
|
utcDate: x,
|
|
3226
3226
|
utcString: P
|
|
3227
3227
|
}, xr;
|
|
3228
3228
|
}
|
|
3229
|
-
let
|
|
3230
|
-
function
|
|
3231
|
-
return
|
|
3229
|
+
let _r;
|
|
3230
|
+
function _a() {
|
|
3231
|
+
return _r;
|
|
3232
3232
|
}
|
|
3233
|
-
function
|
|
3233
|
+
function Un(e) {
|
|
3234
3234
|
const t = z(!1), l = (e == null ? void 0 : e.apis) ?? [];
|
|
3235
3235
|
function S() {
|
|
3236
3236
|
t.value = !0;
|
|
3237
3237
|
}
|
|
3238
|
-
function
|
|
3238
|
+
function f() {
|
|
3239
3239
|
t.value = !1;
|
|
3240
3240
|
}
|
|
3241
3241
|
function g(d) {
|
|
@@ -3275,7 +3275,7 @@ function Ln(e) {
|
|
|
3275
3275
|
});
|
|
3276
3276
|
});
|
|
3277
3277
|
}
|
|
3278
|
-
function
|
|
3278
|
+
function T(d) {
|
|
3279
3279
|
if (l == null)
|
|
3280
3280
|
throw new Error("no demo data available for this api");
|
|
3281
3281
|
const h = g(d);
|
|
@@ -3326,138 +3326,138 @@ function Ln(e) {
|
|
|
3326
3326
|
});
|
|
3327
3327
|
});
|
|
3328
3328
|
}
|
|
3329
|
-
return
|
|
3330
|
-
endDemo:
|
|
3329
|
+
return _r = {
|
|
3330
|
+
endDemo: f,
|
|
3331
3331
|
isDemoing: t,
|
|
3332
3332
|
startDemo: S,
|
|
3333
3333
|
data: l,
|
|
3334
3334
|
deleteItem: x,
|
|
3335
3335
|
get: P,
|
|
3336
|
-
getAll:
|
|
3336
|
+
getAll: T,
|
|
3337
3337
|
post: N,
|
|
3338
3338
|
patch: $
|
|
3339
|
-
},
|
|
3339
|
+
}, _r;
|
|
3340
3340
|
}
|
|
3341
|
-
var
|
|
3342
|
-
function
|
|
3341
|
+
var Bn = { BASE_URL: "/", MODE: "production", DEV: !1, PROD: !0, SSR: !1 };
|
|
3342
|
+
function Ta(e) {
|
|
3343
3343
|
function t(l) {
|
|
3344
|
-
var
|
|
3344
|
+
var f;
|
|
3345
3345
|
const S = l.matched.slice().reverse().find((g) => g.meta && g.meta.title);
|
|
3346
3346
|
if (S)
|
|
3347
3347
|
document.title = S.meta.title;
|
|
3348
3348
|
else {
|
|
3349
|
-
const g =
|
|
3349
|
+
const g = Bn.VITE_NODE_ENV;
|
|
3350
3350
|
let x = "";
|
|
3351
|
-
g == "development" ? x = "BWeb Dev" : g == "staging" ? x = "BlitzIt Sandpit" : x = "BlitzIt Web | Cloud-Based Wholesale Logistics Platform", ((
|
|
3351
|
+
g == "development" ? x = "BWeb Dev" : g == "staging" ? x = "BlitzIt Sandpit" : x = "BlitzIt Web | Cloud-Based Wholesale Logistics Platform", ((f = e == null ? void 0 : e.demo) == null ? void 0 : f.isDemoing.value) == !0 && (x = `Training: ${x}`), document.title = x;
|
|
3352
3352
|
}
|
|
3353
3353
|
}
|
|
3354
3354
|
return {
|
|
3355
3355
|
updateMeta: t
|
|
3356
3356
|
};
|
|
3357
3357
|
}
|
|
3358
|
-
let
|
|
3359
|
-
function
|
|
3360
|
-
return
|
|
3358
|
+
let Tr;
|
|
3359
|
+
function Ca() {
|
|
3360
|
+
return Tr;
|
|
3361
3361
|
}
|
|
3362
|
-
function
|
|
3363
|
-
function t(
|
|
3364
|
-
return
|
|
3362
|
+
function $n(e) {
|
|
3363
|
+
function t(s, A, J) {
|
|
3364
|
+
return s ? un(s) ? J ?? "" : e.dates.tzString(s, A) : J ?? s ?? "";
|
|
3365
3365
|
}
|
|
3366
|
-
function l(
|
|
3367
|
-
if (!
|
|
3366
|
+
function l(s) {
|
|
3367
|
+
if (!s)
|
|
3368
3368
|
return "";
|
|
3369
|
-
if (typeof
|
|
3370
|
-
return
|
|
3369
|
+
if (typeof s != "object")
|
|
3370
|
+
return s;
|
|
3371
3371
|
var A = "";
|
|
3372
|
-
return
|
|
3372
|
+
return s.companyAccount != null && (A = s.companyAccount.companyName + " | "), s.addressLineOne != null && (A = A + s.addressLineOne + " "), s.streetNumber != null && (A = A + s.streetNumber + " "), s.streetName != null && (A = A + s.streetName + ", "), s.suburb != null && (A = A + s.suburb + " "), s.state != null && (A = A + s.state + " "), s.postcode != null && (A = A + s.postcode), A;
|
|
3373
3373
|
}
|
|
3374
|
-
function S(
|
|
3375
|
-
if (typeof
|
|
3376
|
-
return
|
|
3374
|
+
function S(s) {
|
|
3375
|
+
if (typeof s != "number")
|
|
3376
|
+
return s;
|
|
3377
3377
|
var A = new Intl.NumberFormat("en-US", {
|
|
3378
3378
|
style: "currency",
|
|
3379
3379
|
currency: "AUD",
|
|
3380
3380
|
minimumFractionDigits: 2
|
|
3381
3381
|
});
|
|
3382
|
-
return A.format(
|
|
3382
|
+
return A.format(s);
|
|
3383
3383
|
}
|
|
3384
|
-
function s
|
|
3385
|
-
return t(
|
|
3384
|
+
function f(s, A) {
|
|
3385
|
+
return t(s, "ccc | d LLL", A);
|
|
3386
3386
|
}
|
|
3387
|
-
function g(
|
|
3388
|
-
return t(
|
|
3387
|
+
function g(s, A) {
|
|
3388
|
+
return t(s, "d LLL", A);
|
|
3389
3389
|
}
|
|
3390
|
-
function x(
|
|
3391
|
-
return t(
|
|
3390
|
+
function x(s, A) {
|
|
3391
|
+
return t(s, "ccc", A);
|
|
3392
3392
|
}
|
|
3393
|
-
function P(
|
|
3394
|
-
return t(
|
|
3393
|
+
function P(s, A) {
|
|
3394
|
+
return t(s, "ccc dd LLL yyyy", A);
|
|
3395
3395
|
}
|
|
3396
|
-
function
|
|
3397
|
-
return t(
|
|
3396
|
+
function T(s, A) {
|
|
3397
|
+
return t(s, "ccc dd LLL @ hh:mm a", A);
|
|
3398
3398
|
}
|
|
3399
|
-
function N(
|
|
3400
|
-
return new Intl.NumberFormat().format(
|
|
3399
|
+
function N(s) {
|
|
3400
|
+
return new Intl.NumberFormat().format(s);
|
|
3401
3401
|
}
|
|
3402
|
-
function $(
|
|
3403
|
-
return
|
|
3402
|
+
function $(s) {
|
|
3403
|
+
return s == 0 ? "" : new Intl.NumberFormat().format(s);
|
|
3404
3404
|
}
|
|
3405
|
-
function d(
|
|
3406
|
-
if (
|
|
3405
|
+
function d(s) {
|
|
3406
|
+
if (s == 0)
|
|
3407
3407
|
return "";
|
|
3408
|
-
var A = new Intl.NumberFormat().format(
|
|
3409
|
-
return
|
|
3408
|
+
var A = new Intl.NumberFormat().format(s);
|
|
3409
|
+
return s > 0 ? "+" + A : A;
|
|
3410
3410
|
}
|
|
3411
|
-
function h(
|
|
3412
|
-
return e.dates.utcString(
|
|
3411
|
+
function h(s, A) {
|
|
3412
|
+
return e.dates.utcString(s, A);
|
|
3413
3413
|
}
|
|
3414
|
-
function u(
|
|
3415
|
-
return rt(
|
|
3414
|
+
function u(s) {
|
|
3415
|
+
return rt(s, !1);
|
|
3416
3416
|
}
|
|
3417
|
-
function r(
|
|
3418
|
-
if (!
|
|
3417
|
+
function r(s) {
|
|
3418
|
+
if (!s)
|
|
3419
3419
|
return "";
|
|
3420
|
-
if (typeof
|
|
3421
|
-
return
|
|
3420
|
+
if (typeof s != "object")
|
|
3421
|
+
return s;
|
|
3422
3422
|
var A = "";
|
|
3423
|
-
return
|
|
3423
|
+
return s.addressLineOne != null && (A = s.addressLineOne + " "), s.streetNumber != null && (A = A + s.streetNumber + " "), s.streetName != null && (A = A + s.streetName + " "), s.suburb != null && (A = A + s.suburb + " "), s.state != null && (A = A + s.state + " "), s.postcode != null && (A = A + s.postcode), A = A.replaceAll(",", " "), A;
|
|
3424
3424
|
}
|
|
3425
|
-
function y(
|
|
3426
|
-
return t(
|
|
3425
|
+
function y(s, A) {
|
|
3426
|
+
return t(s, "ddd DD MMM YYYY", A);
|
|
3427
3427
|
}
|
|
3428
|
-
function I(
|
|
3429
|
-
return t(
|
|
3428
|
+
function I(s, A) {
|
|
3429
|
+
return t(s, "ccc dd LLL yyyy hh:mm a", A);
|
|
3430
3430
|
}
|
|
3431
|
-
function i(
|
|
3431
|
+
function i(s) {
|
|
3432
3432
|
var A = new Intl.NumberFormat("en-US", {
|
|
3433
3433
|
style: "percent",
|
|
3434
3434
|
minimumFractionDigits: 2
|
|
3435
3435
|
});
|
|
3436
|
-
return A.format(
|
|
3436
|
+
return A.format(s);
|
|
3437
3437
|
}
|
|
3438
|
-
function E(
|
|
3439
|
-
return
|
|
3438
|
+
function E(s) {
|
|
3439
|
+
return s.replaceAll(",", " ");
|
|
3440
3440
|
}
|
|
3441
|
-
function w(
|
|
3442
|
-
return t(
|
|
3441
|
+
function w(s, A) {
|
|
3442
|
+
return t(s, "dd LLL yyyy", A);
|
|
3443
3443
|
}
|
|
3444
|
-
function M(
|
|
3445
|
-
return t(
|
|
3444
|
+
function M(s, A) {
|
|
3445
|
+
return t(s, "dd LLL yyyy hh:mm a", A);
|
|
3446
3446
|
}
|
|
3447
|
-
function b(
|
|
3448
|
-
return t(
|
|
3447
|
+
function b(s, A) {
|
|
3448
|
+
return t(s, "hh:mm a", A);
|
|
3449
3449
|
}
|
|
3450
|
-
function
|
|
3451
|
-
return
|
|
3450
|
+
function _(s) {
|
|
3451
|
+
return s == null ? "" : typeof s == "number" ? e.dates.tzDate().startOf("day").plus({ minutes: s }).toFormat("T") : typeof s == "string" ? e.dates.tzString(s, "t") : "unknown";
|
|
3452
3452
|
}
|
|
3453
3453
|
const D = {
|
|
3454
3454
|
toCompanyNameAndLocationLine: l,
|
|
3455
3455
|
toCurrency: S,
|
|
3456
|
-
toDayDate:
|
|
3456
|
+
toDayDate: f,
|
|
3457
3457
|
toDayMonth: g,
|
|
3458
3458
|
toDayOfWeek: x,
|
|
3459
3459
|
toDayShortDate: P,
|
|
3460
|
-
toDayShortDateAndTime:
|
|
3460
|
+
toDayShortDateAndTime: T,
|
|
3461
3461
|
toDisplayNumber: N,
|
|
3462
3462
|
toDisplayNumberOver: $,
|
|
3463
3463
|
toDisplayNumberSigned: d,
|
|
@@ -3471,37 +3471,37 @@ function Un(e) {
|
|
|
3471
3471
|
toShortDate: w,
|
|
3472
3472
|
toShortDateAndTime: M,
|
|
3473
3473
|
toTime: b,
|
|
3474
|
-
toTimeOfDay:
|
|
3474
|
+
toTimeOfDay: _
|
|
3475
3475
|
};
|
|
3476
|
-
function L(
|
|
3477
|
-
if (
|
|
3478
|
-
let A =
|
|
3476
|
+
function L(s) {
|
|
3477
|
+
if (s != null) {
|
|
3478
|
+
let A = s;
|
|
3479
3479
|
if (A != null && D[A] != null)
|
|
3480
3480
|
return D[A];
|
|
3481
3481
|
}
|
|
3482
3482
|
return (A) => A;
|
|
3483
3483
|
}
|
|
3484
|
-
return
|
|
3484
|
+
return Tr = {
|
|
3485
3485
|
findFilter: L,
|
|
3486
3486
|
...D
|
|
3487
|
-
},
|
|
3487
|
+
}, Tr;
|
|
3488
3488
|
}
|
|
3489
|
-
function
|
|
3489
|
+
function Fn(e, t) {
|
|
3490
3490
|
const l = z(!1), S = Yt(e);
|
|
3491
|
-
let
|
|
3492
|
-
(t == null ? void 0 : t.useTracker) !== !1 &&
|
|
3493
|
-
l.value = g(P) !=
|
|
3491
|
+
let f = g(K(e));
|
|
3492
|
+
(t == null ? void 0 : t.useTracker) !== !1 && _e(S, (P) => {
|
|
3493
|
+
l.value = g(P) != f;
|
|
3494
3494
|
}, { deep: !0 });
|
|
3495
3495
|
function g(P) {
|
|
3496
|
-
const
|
|
3496
|
+
const T = Lr(P);
|
|
3497
3497
|
return t != null && (t.propsToIgnore != null ? t.propsToIgnore.forEach((N) => {
|
|
3498
|
-
delete
|
|
3498
|
+
delete T[N];
|
|
3499
3499
|
}) : t.propsToTrack != null && Object.keys(P).forEach(($) => {
|
|
3500
|
-
t.propsToTrack.some((d) => d == $) || delete
|
|
3501
|
-
})), JSON.stringify(
|
|
3500
|
+
t.propsToTrack.some((d) => d == $) || delete T[$];
|
|
3501
|
+
})), JSON.stringify(T);
|
|
3502
3502
|
}
|
|
3503
3503
|
function x() {
|
|
3504
|
-
|
|
3504
|
+
f = g(K(S)), l.value = !1;
|
|
3505
3505
|
}
|
|
3506
3506
|
return {
|
|
3507
3507
|
asyncItem: S,
|
|
@@ -3509,42 +3509,42 @@ function Bn(e, t) {
|
|
|
3509
3509
|
restartTracker: x
|
|
3510
3510
|
};
|
|
3511
3511
|
}
|
|
3512
|
-
function
|
|
3512
|
+
function Pa(e, t) {
|
|
3513
3513
|
var ae;
|
|
3514
3514
|
const {
|
|
3515
3515
|
// useBladeSrc = true,
|
|
3516
3516
|
useRouteSrc: l = !0
|
|
3517
|
-
} = t ?? {}, S = e.storeMode ?? (t == null ? void 0 : t.storeMode),
|
|
3517
|
+
} = t ?? {}, S = e.storeMode ?? (t == null ? void 0 : t.storeMode), f = e.storageMode ?? (t == null ? void 0 : t.storageMode), g = e.nav ?? e.bladeName ?? "basic", x = Mr(), P = et(), T = K(e.proxyQueryKey), N = te(() => {
|
|
3518
3518
|
var G;
|
|
3519
|
-
return K(e.proxyID) ?? (
|
|
3519
|
+
return K(e.proxyID) ?? (T != null ? (G = P == null ? void 0 : P.query) == null ? void 0 : G[T] : void 0);
|
|
3520
3520
|
}), $ = z(void 0), { actionErrorMsg: d, actionLoadingMsg: h, deleteItem: u, getItem: r, getAllItems: y, restoreItem: I, saveItem: i } = ut({
|
|
3521
3521
|
nav: g,
|
|
3522
3522
|
onError: e.onError ?? (t == null ? void 0 : t.onError),
|
|
3523
3523
|
proxyID: N.value,
|
|
3524
3524
|
store: Le({
|
|
3525
3525
|
storeMode: S,
|
|
3526
|
-
storageMode:
|
|
3526
|
+
storageMode: f,
|
|
3527
3527
|
nav: g
|
|
3528
3528
|
})
|
|
3529
|
-
}), E = te(() => e.errorMsg ?? d.value), w = te(() => e.loadingMsg ?? h.value), M = te(() => w.value != null), b = z(e.itemID ?? (l ? (ae = P == null ? void 0 : P.params) == null ? void 0 : ae.id : void 0)),
|
|
3530
|
-
if (
|
|
3529
|
+
}), E = te(() => e.errorMsg ?? d.value), w = te(() => e.loadingMsg ?? h.value), M = te(() => w.value != null), b = z(e.itemID ?? (l ? (ae = P == null ? void 0 : P.params) == null ? void 0 : ae.id : void 0)), _ = z(b.value == "new" ? "new" : e.startEditing ? "edit" : "view"), D = Re(!1), L = te(() => {
|
|
3530
|
+
if (_.value == "new")
|
|
3531
3531
|
return !1;
|
|
3532
3532
|
const G = K($);
|
|
3533
3533
|
return e.onCanDelete != null ? e.onCanDelete(G) : (G == null ? void 0 : G.isInactive) !== !0;
|
|
3534
|
-
}),
|
|
3535
|
-
if (
|
|
3534
|
+
}), s = te(() => {
|
|
3535
|
+
if (_.value == "new")
|
|
3536
3536
|
return !1;
|
|
3537
3537
|
const G = K($);
|
|
3538
3538
|
return e.onCanEdit != null ? e.onCanEdit(G) : !0;
|
|
3539
3539
|
}), A = te(() => {
|
|
3540
|
-
if (
|
|
3540
|
+
if (_.value == "new")
|
|
3541
3541
|
return !1;
|
|
3542
3542
|
const G = K($);
|
|
3543
3543
|
return e.onCanRestore != null ? e.onCanRestore(G) : (G == null ? void 0 : G.isInactive) === !0;
|
|
3544
3544
|
}), J = te(() => {
|
|
3545
3545
|
const G = K($);
|
|
3546
3546
|
return e.onCanSave != null ? e.onCanSave(G) : !0;
|
|
3547
|
-
}), { isChanged: Q, restartTracker: ee } =
|
|
3547
|
+
}), { isChanged: Q, restartTracker: ee } = Fn($, {
|
|
3548
3548
|
useTracker: e.trackChanges,
|
|
3549
3549
|
propsToIgnore: e.trackIgnoreProps,
|
|
3550
3550
|
propsToTrack: e.trackProps
|
|
@@ -3616,7 +3616,7 @@ function Ia(e, t) {
|
|
|
3616
3616
|
onCanSaveAsync: se,
|
|
3617
3617
|
onGetSaveAsync: fe,
|
|
3618
3618
|
onSaveAsync: Ee,
|
|
3619
|
-
onSaveSuccessAsync: $e = (Ce) => ((X == null ? void 0 : X.navBack) === !0 ? x.back() : (G.rowVersion != null && Ce.rowVersion != null && (G.rowVersion = Ce.rowVersion), ee(),
|
|
3619
|
+
onSaveSuccessAsync: $e = (Ce) => ((X == null ? void 0 : X.navBack) === !0 ? x.back() : (G.rowVersion != null && Ce.rowVersion != null && (G.rowVersion = Ce.rowVersion), ee(), _.value = "view"), Promise.resolve(void 0))
|
|
3620
3620
|
} = { ...e };
|
|
3621
3621
|
i({
|
|
3622
3622
|
additionalUrl: ne,
|
|
@@ -3629,16 +3629,16 @@ function Ia(e, t) {
|
|
|
3629
3629
|
proxyID: N.value,
|
|
3630
3630
|
// ...params.getOptions(),
|
|
3631
3631
|
// ...(useBladeSrc ? bladeData.value : {}),
|
|
3632
|
-
mode:
|
|
3632
|
+
mode: _.value
|
|
3633
3633
|
});
|
|
3634
3634
|
}
|
|
3635
3635
|
function H() {
|
|
3636
|
-
const G = K(
|
|
3637
|
-
!G || G == "view" ?
|
|
3636
|
+
const G = K(_);
|
|
3637
|
+
!G || G == "view" ? _.value = "edit" : G == "edit" && (_.value = "view");
|
|
3638
3638
|
}
|
|
3639
|
-
return
|
|
3639
|
+
return _e(E, (G) => {
|
|
3640
3640
|
D.value = G != null;
|
|
3641
|
-
}),
|
|
3641
|
+
}), _e(() => e.refreshToggle, () => {
|
|
3642
3642
|
W({ deepRefresh: !0 });
|
|
3643
3643
|
}), Xr(async () => {
|
|
3644
3644
|
var G;
|
|
@@ -3649,14 +3649,14 @@ function Ia(e, t) {
|
|
|
3649
3649
|
errorMsg: E,
|
|
3650
3650
|
isChanged: Q,
|
|
3651
3651
|
isDeletable: L,
|
|
3652
|
-
isEditing: te(() =>
|
|
3653
|
-
isEditable:
|
|
3652
|
+
isEditing: te(() => _.value == "new" || _.value == "edit"),
|
|
3653
|
+
isEditable: s,
|
|
3654
3654
|
isLoading: M,
|
|
3655
|
-
isNew: te(() =>
|
|
3655
|
+
isNew: te(() => _.value == "new"),
|
|
3656
3656
|
isRestorable: A,
|
|
3657
3657
|
isSaveable: J,
|
|
3658
3658
|
loadingMsg: w,
|
|
3659
|
-
mode:
|
|
3659
|
+
mode: _,
|
|
3660
3660
|
refresh: W,
|
|
3661
3661
|
restoreItem: we,
|
|
3662
3662
|
saveItem: Y,
|
|
@@ -3669,13 +3669,13 @@ let yr = null, Cr;
|
|
|
3669
3669
|
function it() {
|
|
3670
3670
|
return Cr;
|
|
3671
3671
|
}
|
|
3672
|
-
function
|
|
3672
|
+
function kn(e) {
|
|
3673
3673
|
const t = e.defaultCacheExpiryHours ?? 7;
|
|
3674
3674
|
e.getDisplayName ?? (e.getDisplayName = (h) => {
|
|
3675
3675
|
if (h.displayName != null)
|
|
3676
3676
|
return h.displayName;
|
|
3677
3677
|
if (h.name != null)
|
|
3678
|
-
return
|
|
3678
|
+
return ln(h.name.replaceAll("-", " "));
|
|
3679
3679
|
});
|
|
3680
3680
|
const l = (e.navItems ?? []).map((h) => ({
|
|
3681
3681
|
displayName: h.displayName ?? e.getDisplayName(h),
|
|
@@ -3685,7 +3685,7 @@ function $n(e) {
|
|
|
3685
3685
|
var u;
|
|
3686
3686
|
return (u = P(h)) == null ? void 0 : u.archiveName;
|
|
3687
3687
|
}
|
|
3688
|
-
function
|
|
3688
|
+
function f(h) {
|
|
3689
3689
|
var u;
|
|
3690
3690
|
return ((u = P(h)) == null ? void 0 : u.cacheExpiryHours) ?? t;
|
|
3691
3691
|
}
|
|
@@ -3703,11 +3703,11 @@ function $n(e) {
|
|
|
3703
3703
|
return r.name == h || r.singleName == h || ((y = r.aliases) == null ? void 0 : y.some((I) => I == h));
|
|
3704
3704
|
}) ?? null;
|
|
3705
3705
|
}
|
|
3706
|
-
function
|
|
3706
|
+
function T(h) {
|
|
3707
3707
|
const u = P(h);
|
|
3708
3708
|
if (u == null)
|
|
3709
3709
|
return;
|
|
3710
|
-
let r =
|
|
3710
|
+
let r = wn(u.microservice ?? "default") ?? "";
|
|
3711
3711
|
return u.path != null && (r = Be(r, u.path)), r != null && r.endsWith("/") && (r = r.slice(0, r.length - 1)), r;
|
|
3712
3712
|
}
|
|
3713
3713
|
function N(h) {
|
|
@@ -3716,7 +3716,7 @@ function $n(e) {
|
|
|
3716
3716
|
return u.singleName;
|
|
3717
3717
|
const r = u == null ? void 0 : u.displayName;
|
|
3718
3718
|
if (r != null)
|
|
3719
|
-
return
|
|
3719
|
+
return gn(r);
|
|
3720
3720
|
}
|
|
3721
3721
|
function $(h) {
|
|
3722
3722
|
const u = P(h);
|
|
@@ -3737,19 +3737,19 @@ function $n(e) {
|
|
|
3737
3737
|
hesitate: gr,
|
|
3738
3738
|
navigationItems: l,
|
|
3739
3739
|
findArchiveName: S,
|
|
3740
|
-
findCacheHours:
|
|
3740
|
+
findCacheHours: f,
|
|
3741
3741
|
findDisplay: g,
|
|
3742
3742
|
findIcon: x,
|
|
3743
3743
|
findItem: P,
|
|
3744
3744
|
findStoreName: $,
|
|
3745
|
-
findPath:
|
|
3745
|
+
findPath: T,
|
|
3746
3746
|
findSingleDisplay: N,
|
|
3747
3747
|
updateNavigationProperties: d
|
|
3748
3748
|
}, Cr;
|
|
3749
3749
|
}
|
|
3750
|
-
function
|
|
3750
|
+
function Na(e, t, l) {
|
|
3751
3751
|
var qe, He;
|
|
3752
|
-
const S =
|
|
3752
|
+
const S = Ln(), f = it(), g = Mr(), x = et(), { bladeData: P } = Nn({}), T = e.useBladeSrc ?? !0, N = e.useRouteSrc ?? !0, $ = e.nav ?? e.bladeName ?? e.itemBladeName ?? "basic", d = e.storeMode ?? ((qe = f.findItem($)) == null ? void 0 : qe.storeMode), h = e.storageMode ?? ((He = f.findItem($)) == null ? void 0 : He.storageMode), u = K(e.customFilters) ?? [], r = z([]), y = te(() => Xt([
|
|
3753
3753
|
...u.filter((U) => U.name != null).map((U) => U.name),
|
|
3754
3754
|
...e.defaultFilters ?? [],
|
|
3755
3755
|
...r.value
|
|
@@ -3758,7 +3758,7 @@ function Da(e, t, l) {
|
|
|
3758
3758
|
const E = te(() => Gr(i, I).value.length > 0 || Gr(I, i).value.length > 0), w = z(M());
|
|
3759
3759
|
function M() {
|
|
3760
3760
|
var U, j;
|
|
3761
|
-
if (
|
|
3761
|
+
if (T) {
|
|
3762
3762
|
const V = (U = P.value) == null ? void 0 : U.page;
|
|
3763
3763
|
if (V != null)
|
|
3764
3764
|
return Number.parseInt(V);
|
|
@@ -3772,7 +3772,7 @@ function Da(e, t, l) {
|
|
|
3772
3772
|
}
|
|
3773
3773
|
const b = te(() => {
|
|
3774
3774
|
var U, j;
|
|
3775
|
-
if (
|
|
3775
|
+
if (T) {
|
|
3776
3776
|
const V = (U = P.value) == null ? void 0 : U.proxyID;
|
|
3777
3777
|
if (V != null)
|
|
3778
3778
|
return V;
|
|
@@ -3783,10 +3783,10 @@ function Da(e, t, l) {
|
|
|
3783
3783
|
return V;
|
|
3784
3784
|
}
|
|
3785
3785
|
return e.proxyID;
|
|
3786
|
-
}),
|
|
3786
|
+
}), _ = z(D());
|
|
3787
3787
|
function D() {
|
|
3788
3788
|
var U, j;
|
|
3789
|
-
if (
|
|
3789
|
+
if (T) {
|
|
3790
3790
|
const V = (U = P.value) == null ? void 0 : U.search;
|
|
3791
3791
|
if (V != null)
|
|
3792
3792
|
return V;
|
|
@@ -3797,7 +3797,7 @@ function Da(e, t, l) {
|
|
|
3797
3797
|
return V;
|
|
3798
3798
|
}
|
|
3799
3799
|
}
|
|
3800
|
-
const L = z(K(e.startShowingInactive) ?? !1),
|
|
3800
|
+
const L = z(K(e.startShowingInactive) ?? !1), s = te(() => [
|
|
3801
3801
|
...e.searchProps ?? [],
|
|
3802
3802
|
...(e.headers ?? []).filter((U) => U.searchable != null && U.value != null).map((U) => U.value ?? "")
|
|
3803
3803
|
]), A = z([]), J = Re([]), Q = z([]);
|
|
@@ -3818,11 +3818,11 @@ function Da(e, t, l) {
|
|
|
3818
3818
|
ge != null ? U = U != null ? `${U}ANDALSO${ge.filterFunction()}` : ge.filterFunction() : j.push(de);
|
|
3819
3819
|
});
|
|
3820
3820
|
const V = {};
|
|
3821
|
-
return
|
|
3821
|
+
return Te(j) && (V.filterBy = j.toString()), U != null && (V.query = U), V;
|
|
3822
3822
|
}), rr = te(() => {
|
|
3823
3823
|
var j;
|
|
3824
3824
|
let U = e.params != null ? { ...e.params } : {};
|
|
3825
|
-
return e.useServerPagination && e.itemsPerPage != null && (U.includeCount = !0, U.takeAmount = e.itemsPerPage, U.takeFrom = (w.value - 1) * e.itemsPerPage), Ce.value != null && (U = { ...U, ...Ce.value }), L.value && (U.includeInactive = !0),
|
|
3825
|
+
return e.useServerPagination && e.itemsPerPage != null && (U.includeCount = !0, U.takeAmount = e.itemsPerPage, U.takeFrom = (w.value - 1) * e.itemsPerPage), Ce.value != null && (U = { ...U, ...Ce.value }), L.value && (U.includeInactive = !0), Te(e.selectProps) && (U.properties = (j = e.selectProps) == null ? void 0 : j.toString()), _.value != null && (U.searchString = _.value), U;
|
|
3826
3826
|
}), tr = te(() => (U) => e.onCanDelete != null ? e.onCanDelete(U) : !(U != null && U.isInactive === !0)), nr = te(() => (U) => L.value ? e.onCanRestore != null ? e.onCanRestore(U) : (U == null ? void 0 : U.isInactive) === !0 : !1), Pe = te(() => Q.value.filter((U) => !U.hide)), ar = te(() => {
|
|
3827
3827
|
let U = new Array();
|
|
3828
3828
|
return Pe.value.filter((V) => V.sublevel != null).forEach((V) => {
|
|
@@ -3899,9 +3899,9 @@ function Da(e, t, l) {
|
|
|
3899
3899
|
}
|
|
3900
3900
|
function Ne() {
|
|
3901
3901
|
let U = K(A);
|
|
3902
|
-
if (U = e.onFilter ? e.onFilter(U) : U,
|
|
3903
|
-
let j = [...
|
|
3904
|
-
e.itemText && j.push(e.itemText),
|
|
3902
|
+
if (U = e.onFilter ? e.onFilter(U) : U, _.value != null && _.value.length > 0) {
|
|
3903
|
+
let j = [...s.value];
|
|
3904
|
+
e.itemText && j.push(e.itemText), Te(j) && (U = U.filter((V) => mn(V, _.value, j)));
|
|
3905
3905
|
}
|
|
3906
3906
|
J.value = U;
|
|
3907
3907
|
}
|
|
@@ -3910,7 +3910,7 @@ function Da(e, t, l) {
|
|
|
3910
3910
|
e.headers != null && (Q.value = [...e.headers], U || Q.value.push({ title: "Actions", value: "itemActions", align: "end" }));
|
|
3911
3911
|
}
|
|
3912
3912
|
async function Ie(U) {
|
|
3913
|
-
if (fe.value = !1, (U == null ? void 0 : U.resetSearch) === !0 && (Ee.value = e.showSearch ?? !1,
|
|
3913
|
+
if (fe.value = !1, (U == null ? void 0 : U.resetSearch) === !0 && (Ee.value = e.showSearch ?? !1, _.value = void 0), e.items != null) {
|
|
3914
3914
|
A.value = e.onGetSuccessAsync != null ? await e.onGetSuccessAsync(e.items) : e.items;
|
|
3915
3915
|
return;
|
|
3916
3916
|
}
|
|
@@ -3960,15 +3960,15 @@ function Da(e, t, l) {
|
|
|
3960
3960
|
}
|
|
3961
3961
|
}
|
|
3962
3962
|
function je() {
|
|
3963
|
-
Ee.value ? (Ee.value = e.showSearch ?? !1,
|
|
3963
|
+
Ee.value ? (Ee.value = e.showSearch ?? !1, _.value = void 0, Ie()) : Ee.value = e.showSearch ?? !0;
|
|
3964
3964
|
}
|
|
3965
|
-
return We(),
|
|
3965
|
+
return We(), Ot([_], () => {
|
|
3966
3966
|
Ne();
|
|
3967
|
-
}, { debounce: 500, maxWait: 500 }),
|
|
3967
|
+
}, { debounce: 500, maxWait: 500 }), _e([L, w], async () => {
|
|
3968
3968
|
await Ie();
|
|
3969
|
-
}),
|
|
3969
|
+
}), _e([X, () => e.errorMsg], ([U, j]) => {
|
|
3970
3970
|
fe.value = U != null || j != null;
|
|
3971
|
-
}),
|
|
3971
|
+
}), _e(() => e.refreshToggle, () => {
|
|
3972
3972
|
Ie({ deepRefresh: !0 });
|
|
3973
3973
|
}), Or([A, () => e.items], () => {
|
|
3974
3974
|
Ne();
|
|
@@ -3993,7 +3993,7 @@ function Da(e, t, l) {
|
|
|
3993
3993
|
loadingMsg: ne,
|
|
3994
3994
|
refresh: Ie,
|
|
3995
3995
|
restoreItem: Ze,
|
|
3996
|
-
searchString:
|
|
3996
|
+
searchString: _,
|
|
3997
3997
|
selectedFilters: I,
|
|
3998
3998
|
selectItem: Je,
|
|
3999
3999
|
// serverFilters,
|
|
@@ -4008,7 +4008,7 @@ function Da(e, t, l) {
|
|
|
4008
4008
|
};
|
|
4009
4009
|
}
|
|
4010
4010
|
let Ge;
|
|
4011
|
-
function
|
|
4011
|
+
function Gn(e) {
|
|
4012
4012
|
const t = z((e == null ? void 0 : e.default) ?? "Admin"), l = z((e == null ? void 0 : e.groups) ?? []);
|
|
4013
4013
|
return Ge = {
|
|
4014
4014
|
currentGroup: t,
|
|
@@ -4016,45 +4016,45 @@ function Fn(e) {
|
|
|
4016
4016
|
useRoutes: e == null ? void 0 : e.useRoutes
|
|
4017
4017
|
}, Ge;
|
|
4018
4018
|
}
|
|
4019
|
-
function
|
|
4020
|
-
const e = Mr(), t = it(), l =
|
|
4019
|
+
function Ma() {
|
|
4020
|
+
const e = Mr(), t = it(), l = xn();
|
|
4021
4021
|
let S = e.getRoutes();
|
|
4022
4022
|
return {
|
|
4023
4023
|
...Ge,
|
|
4024
4024
|
sidebarNavItems: te(() => {
|
|
4025
4025
|
var g;
|
|
4026
4026
|
S = S.filter((x) => x.meta != null && x.meta.menuGroup != null);
|
|
4027
|
-
const
|
|
4027
|
+
const f = [];
|
|
4028
4028
|
return S.forEach((x) => {
|
|
4029
4029
|
var d;
|
|
4030
|
-
const P = Ge.groupOptions.value.find((h) => h.displayName == x.meta.menuGroup),
|
|
4031
|
-
let $ =
|
|
4030
|
+
const P = Ge.groupOptions.value.find((h) => h.displayName == x.meta.menuGroup), T = t.findItem(x.meta.nav), N = x.meta;
|
|
4031
|
+
let $ = f.find((h) => h.displayName == N.menuGroup);
|
|
4032
4032
|
$ == null && ($ = {
|
|
4033
4033
|
displayName: N.menuGroup,
|
|
4034
|
-
icon: (P == null ? void 0 : P.icon) ?? (N == null ? void 0 : N.icon) ?? (
|
|
4034
|
+
icon: (P == null ? void 0 : P.icon) ?? (N == null ? void 0 : N.icon) ?? (T == null ? void 0 : T.icon),
|
|
4035
4035
|
isGroup: !0,
|
|
4036
4036
|
items: []
|
|
4037
|
-
},
|
|
4038
|
-
displayName: (N == null ? void 0 : N.displayName) ?? t.findDisplay(
|
|
4039
|
-
icon: (N == null ? void 0 : N.icon) ?? t.findIcon(
|
|
4040
|
-
permissions: (N == null ? void 0 : N.permissions) ?? (
|
|
4037
|
+
}, f.push($)), (d = $.items) == null || d.push({
|
|
4038
|
+
displayName: (N == null ? void 0 : N.displayName) ?? t.findDisplay(T ?? void 0),
|
|
4039
|
+
icon: (N == null ? void 0 : N.icon) ?? t.findIcon(T ?? void 0),
|
|
4040
|
+
permissions: (N == null ? void 0 : N.permissions) ?? (T == null ? void 0 : T.permissions) ?? [],
|
|
4041
4041
|
requiresAuth: (N == null ? void 0 : N.requiresAuth) !== !1,
|
|
4042
|
-
subscriptions: (N == null ? void 0 : N.subscriptions) ?? (
|
|
4043
|
-
subFilters: (N == null ? void 0 : N.subFilters) ?? (
|
|
4042
|
+
subscriptions: (N == null ? void 0 : N.subscriptions) ?? (T == null ? void 0 : T.subscriptions) ?? [],
|
|
4043
|
+
subFilters: (N == null ? void 0 : N.subFilters) ?? (T == null ? void 0 : T.subFilters) ?? [],
|
|
4044
4044
|
routeName: x.name
|
|
4045
4045
|
});
|
|
4046
|
-
}),
|
|
4046
|
+
}), f.forEach((x) => {
|
|
4047
4047
|
var P;
|
|
4048
|
-
x.items = (P = x.items) == null ? void 0 : P.filter((
|
|
4049
|
-
}), Ge.currentGroup.value != null ? ((g =
|
|
4048
|
+
x.items = (P = x.items) == null ? void 0 : P.filter((T) => !T.requiresAuth || l.doShow(T.subscriptions, T.permissions, "view")).sort(Ue.firstBy((T) => T.displayName));
|
|
4049
|
+
}), Ge.currentGroup.value != null ? ((g = f.find((x) => x.displayName == Ge.currentGroup.value)) == null ? void 0 : g.items) ?? [] : f.filter((x) => !x.requiresAuth || l.doShow(x.subscriptions, x.permissions, "view"));
|
|
4050
4050
|
})
|
|
4051
4051
|
};
|
|
4052
4052
|
}
|
|
4053
4053
|
let Pr;
|
|
4054
|
-
function
|
|
4054
|
+
function La(e) {
|
|
4055
4055
|
return Pr.usePresets(e);
|
|
4056
4056
|
}
|
|
4057
|
-
function
|
|
4057
|
+
function Wn(e) {
|
|
4058
4058
|
function t(l) {
|
|
4059
4059
|
if (!l)
|
|
4060
4060
|
return {};
|
|
@@ -4068,10 +4068,10 @@ function kn(e) {
|
|
|
4068
4068
|
let Zr, Jr, jr, Kr = !1;
|
|
4069
4069
|
const wr = z(!1), br = z(!1), Qr = z(), pe = z();
|
|
4070
4070
|
let Nr;
|
|
4071
|
-
function
|
|
4071
|
+
function Ra() {
|
|
4072
4072
|
return Nr;
|
|
4073
4073
|
}
|
|
4074
|
-
function
|
|
4074
|
+
function qn() {
|
|
4075
4075
|
function e(x) {
|
|
4076
4076
|
pe.value = x.detail, br.value = !0;
|
|
4077
4077
|
}
|
|
@@ -4085,14 +4085,14 @@ function Gn() {
|
|
|
4085
4085
|
function S() {
|
|
4086
4086
|
return !!window.matchMedia("(display-mode: standalone)").matches;
|
|
4087
4087
|
}
|
|
4088
|
-
function
|
|
4088
|
+
function f(x) {
|
|
4089
4089
|
x.preventDefault(), wr.value = !0, Qr.value = x;
|
|
4090
4090
|
}
|
|
4091
4091
|
function g() {
|
|
4092
4092
|
br.value = !1, !(!pe.value || !pe.value.waiting) && pe.value.waiting.postMessage({ type: "SKIP_WAITING" });
|
|
4093
4093
|
}
|
|
4094
|
-
return
|
|
4095
|
-
Zr == null && (Zr = document.addEventListener("swUpdated", e, { once: !0 })), Jr == null && (Jr = navigator.serviceWorker.addEventListener("controllerchange", t)), jr == null && (jr = window.addEventListener("beforeinstallprompt",
|
|
4094
|
+
return pt(() => {
|
|
4095
|
+
Zr == null && (Zr = document.addEventListener("swUpdated", e, { once: !0 })), Jr == null && (Jr = navigator.serviceWorker.addEventListener("controllerchange", t)), jr == null && (jr = window.addEventListener("beforeinstallprompt", f));
|
|
4096
4096
|
}), Nr = {
|
|
4097
4097
|
canInstallApp: wr,
|
|
4098
4098
|
canUpdateApp: br,
|
|
@@ -4101,122 +4101,132 @@ function Gn() {
|
|
|
4101
4101
|
updateApp: g
|
|
4102
4102
|
}, Nr;
|
|
4103
4103
|
}
|
|
4104
|
-
function
|
|
4104
|
+
function Ua(e) {
|
|
4105
4105
|
const t = [];
|
|
4106
|
-
return (e == null ? void 0 : e.required) == !0 && t.push((l) => !!l || "Field is required"), (e == null ? void 0 : e.otherRules) != null && (Array.isArray(e == null ? void 0 : e.otherRules) ? t.push(...e.otherRules) : t.push(e.otherRules)), (e == null ? void 0 : e.forPassword) == !0 && (t.push((l) => !!l || "Password is required"), t.push((l) => l != null && l.length > 9 || "Password must be 10 or more characters"), t.push((l) => /^(.*[a-z].*)$/.test(l) || "Password must contain a lowercase letter"), t.push((l) => /^(.*[A-Z].*)$/.test(l) || "Password must contain an uppercase letter"), t.push((l) => /^(.*\d.*)$/.test(l) || "Password must contain a number")), (e == null ? void 0 : e.forEmail) == !0 && (t.push((l) => !!l || "Email is required"), t.push((l) =>
|
|
4106
|
+
return (e == null ? void 0 : e.required) == !0 && t.push((l) => !!l || "Field is required"), (e == null ? void 0 : e.otherRules) != null && (Array.isArray(e == null ? void 0 : e.otherRules) ? t.push(...e.otherRules) : t.push(e.otherRules)), (e == null ? void 0 : e.forPassword) == !0 && (t.push((l) => !!l || "Password is required"), t.push((l) => l != null && l.length > 9 || "Password must be 10 or more characters"), t.push((l) => /^(.*[a-z].*)$/.test(l) || "Password must contain a lowercase letter"), t.push((l) => /^(.*[A-Z].*)$/.test(l) || "Password must contain an uppercase letter"), t.push((l) => /^(.*\d.*)$/.test(l) || "Password must contain a number")), (e == null ? void 0 : e.forEmail) == !0 && (t.push((l) => !!l || "Email is required"), t.push((l) => vn(l) || "Email must be valid")), t;
|
|
4107
|
+
}
|
|
4108
|
+
const Hn = (e, t) => {
|
|
4109
|
+
const l = e.__vccOpts || e;
|
|
4110
|
+
for (const [S, f] of t)
|
|
4111
|
+
l[S] = f;
|
|
4112
|
+
return l;
|
|
4113
|
+
}, Vn = {};
|
|
4114
|
+
function zn(e, t) {
|
|
4115
|
+
return Zt(), Jt("div", null, "test");
|
|
4107
4116
|
}
|
|
4108
|
-
|
|
4117
|
+
const Yn = /* @__PURE__ */ Hn(Vn, [["render", zn]]);
|
|
4118
|
+
function Ba(e) {
|
|
4109
4119
|
return {
|
|
4110
4120
|
install(t, l) {
|
|
4111
|
-
var
|
|
4112
|
-
console.log(t), e.vuetifyInstance ?? (e.vuetifyInstance = l.vuetifyInstance),
|
|
4113
|
-
const S =
|
|
4114
|
-
|
|
4115
|
-
const g =
|
|
4116
|
-
|
|
4117
|
-
const x =
|
|
4121
|
+
var T;
|
|
4122
|
+
console.log(t), t.component("bt-test", Yn), e.vuetifyInstance ?? (e.vuetifyInstance = l.vuetifyInstance), bn(e.urls), Mn(e);
|
|
4123
|
+
const S = Un(), f = kn(e);
|
|
4124
|
+
Wn(e), (T = e.auth).demo ?? (T.demo = S), e.auth.getAuthItem = f.findItem;
|
|
4125
|
+
const g = _n(e.auth);
|
|
4126
|
+
Gn(e.menu);
|
|
4127
|
+
const x = Dn({
|
|
4118
4128
|
auth: g,
|
|
4119
|
-
findPath:
|
|
4129
|
+
findPath: f.findPath,
|
|
4120
4130
|
useBearerToken: !0
|
|
4121
|
-
}), P =
|
|
4131
|
+
}), P = Rn({
|
|
4122
4132
|
getTimeZone: () => g.timeZone.value
|
|
4123
4133
|
});
|
|
4124
|
-
|
|
4134
|
+
$n({
|
|
4125
4135
|
dates: P
|
|
4126
|
-
}),
|
|
4136
|
+
}), qn(), Sn({
|
|
4127
4137
|
api: x,
|
|
4128
4138
|
auth: g,
|
|
4129
|
-
navigation:
|
|
4139
|
+
navigation: f
|
|
4130
4140
|
});
|
|
4131
4141
|
}
|
|
4132
4142
|
};
|
|
4133
4143
|
}
|
|
4134
4144
|
export {
|
|
4135
|
-
|
|
4136
|
-
|
|
4145
|
+
ga as DataURIToBlob,
|
|
4146
|
+
sa as addWeekday,
|
|
4137
4147
|
Be as appendUrl,
|
|
4138
|
-
|
|
4139
|
-
|
|
4140
|
-
|
|
4141
|
-
|
|
4148
|
+
ln as capitalizeWords,
|
|
4149
|
+
aa as checkImage,
|
|
4150
|
+
on as containsSearch,
|
|
4151
|
+
fa as containsWeekday,
|
|
4142
4152
|
Lr as copyDeep,
|
|
4143
|
-
|
|
4144
|
-
|
|
4145
|
-
|
|
4146
|
-
|
|
4147
|
-
|
|
4148
|
-
|
|
4149
|
-
|
|
4150
|
-
|
|
4151
|
-
|
|
4152
|
-
|
|
4153
|
-
|
|
4154
|
-
|
|
4155
|
-
|
|
4156
|
-
|
|
4157
|
-
|
|
4153
|
+
sn as copyItemByAlphabet,
|
|
4154
|
+
Dn as createApi,
|
|
4155
|
+
_n as createAuth,
|
|
4156
|
+
Ba as createCore,
|
|
4157
|
+
Mn as createCosmetics,
|
|
4158
|
+
Rn as createDates,
|
|
4159
|
+
Un as createDemo,
|
|
4160
|
+
$n as createFilters,
|
|
4161
|
+
Gn as createMenu,
|
|
4162
|
+
kn as createNavigation,
|
|
4163
|
+
qn as createPWA,
|
|
4164
|
+
Wn as createPresets,
|
|
4165
|
+
In as createSessionStoreDefinition,
|
|
4166
|
+
Sn as createStoreBuilder,
|
|
4167
|
+
bn as createUrl,
|
|
4158
4168
|
qr as createWholeLastUpdateStoreDefinition,
|
|
4159
|
-
|
|
4160
|
-
|
|
4169
|
+
fn as csvContains,
|
|
4170
|
+
Da as csvDefaults,
|
|
4161
4171
|
tt as deepSelect,
|
|
4162
|
-
|
|
4163
|
-
|
|
4164
|
-
|
|
4165
|
-
|
|
4166
|
-
|
|
4167
|
-
|
|
4168
|
-
|
|
4169
|
-
|
|
4170
|
-
|
|
4172
|
+
On as distinct,
|
|
4173
|
+
pn as extensionExists,
|
|
4174
|
+
dn as extractErrorDescription,
|
|
4175
|
+
an as fromCamelCase,
|
|
4176
|
+
ea as getAreaAround,
|
|
4177
|
+
ra as getAreaToLeft,
|
|
4178
|
+
ta as getAreaToRight,
|
|
4179
|
+
na as getGoogleMapsLocationLine,
|
|
4180
|
+
la as getImageData,
|
|
4171
4181
|
rt as getLocationLine,
|
|
4172
|
-
|
|
4173
|
-
|
|
4174
|
-
|
|
4175
|
-
|
|
4176
|
-
|
|
4177
|
-
|
|
4178
|
-
|
|
4182
|
+
ha as getMinDate,
|
|
4183
|
+
cn as getMinDateString,
|
|
4184
|
+
hn as getRandomColor,
|
|
4185
|
+
mn as hasSearch,
|
|
4186
|
+
da as isArrayOfLength,
|
|
4187
|
+
Te as isLengthyArray,
|
|
4188
|
+
un as isMinDate,
|
|
4179
4189
|
Sr as nestedValue,
|
|
4180
|
-
|
|
4181
|
-
|
|
4182
|
-
|
|
4183
|
-
|
|
4184
|
-
|
|
4185
|
-
|
|
4186
|
-
|
|
4190
|
+
oa as removeWeekday,
|
|
4191
|
+
ma as roundTo,
|
|
4192
|
+
gn as singularize,
|
|
4193
|
+
ua as toCamelCase,
|
|
4194
|
+
ya as toCompareString,
|
|
4195
|
+
va as toggleCSV,
|
|
4196
|
+
wa as twiddleThumbs,
|
|
4187
4197
|
ut as useActions,
|
|
4188
|
-
|
|
4198
|
+
tn as useActionsTracker,
|
|
4189
4199
|
Er as useApi,
|
|
4190
|
-
|
|
4200
|
+
xn as useAuth,
|
|
4191
4201
|
Wr as useAuthUrl,
|
|
4192
|
-
|
|
4193
|
-
|
|
4194
|
-
|
|
4195
|
-
|
|
4196
|
-
|
|
4202
|
+
Nn as useBlade,
|
|
4203
|
+
Ln as useCSV,
|
|
4204
|
+
Ea as useCosmetics,
|
|
4205
|
+
wn as useDataUrl,
|
|
4206
|
+
xa as useDates,
|
|
4197
4207
|
lt as useDbName,
|
|
4198
|
-
|
|
4199
|
-
|
|
4200
|
-
|
|
4201
|
-
|
|
4202
|
-
|
|
4203
|
-
|
|
4204
|
-
|
|
4205
|
-
|
|
4206
|
-
|
|
4208
|
+
_a as useDemo,
|
|
4209
|
+
Ta as useDocumentMeta,
|
|
4210
|
+
Tn as useDraggable,
|
|
4211
|
+
Ca as useFilters,
|
|
4212
|
+
en as useId,
|
|
4213
|
+
Pa as useItem,
|
|
4214
|
+
Na as useList,
|
|
4215
|
+
Sa as useLocalCache,
|
|
4216
|
+
Ia as useLocalCosmetics,
|
|
4207
4217
|
ve as useLocalDb,
|
|
4208
|
-
|
|
4218
|
+
Ma as useMenu,
|
|
4209
4219
|
it as useNavigation,
|
|
4210
|
-
|
|
4211
|
-
|
|
4212
|
-
|
|
4213
|
-
|
|
4214
|
-
|
|
4220
|
+
Ra as usePWA,
|
|
4221
|
+
La as usePresets,
|
|
4222
|
+
Pn as useResizable,
|
|
4223
|
+
Ua as useRules,
|
|
4224
|
+
Aa as useStore,
|
|
4215
4225
|
Le as useStoreDefinition,
|
|
4216
|
-
|
|
4217
|
-
|
|
4218
|
-
|
|
4226
|
+
Fn as useTracker,
|
|
4227
|
+
ba as useUrls,
|
|
4228
|
+
vn as validEmail,
|
|
4219
4229
|
Ye as weekdayPairs,
|
|
4220
|
-
|
|
4221
|
-
|
|
4230
|
+
ca as weekdayShortName,
|
|
4231
|
+
ia as weekdayValue
|
|
4222
4232
|
};
|