@signal24/vue-foundation 4.25.4 → 4.25.5
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.
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var D = (e, t, n) =>
|
|
4
|
-
import { defineComponent as R, ref as T, computed as M, watch as H, onMounted as _, createElementBlock as k, withDirectives as ne, openBlock as b, createElementVNode as B, toDisplayString as W, createCommentVNode as A, Fragment as oe, renderList as se, vModelSelect as
|
|
5
|
-
import { compact as
|
|
6
|
-
import {
|
|
7
|
-
import { escapeHtml as
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
const
|
|
1
|
+
var At = Object.defineProperty;
|
|
2
|
+
var $t = (e, t, n) => t in e ? At(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
|
+
var D = (e, t, n) => $t(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
|
+
import { defineComponent as R, ref as T, computed as M, watch as H, onMounted as _, createElementBlock as k, withDirectives as ne, openBlock as b, createElementVNode as B, toDisplayString as W, createCommentVNode as A, Fragment as oe, renderList as se, vModelSelect as Bt, getCurrentInstance as ge, withModifiers as we, normalizeStyle as _t, normalizeClass as $, renderSlot as U, reactive as Nt, h as ie, Teleport as Rt, markRaw as Wt, onBeforeUnmount as Ee, resolveDirective as Ut, createBlock as et, createSlots as jt, withCtx as me, createTextVNode as X, vModelText as Pt, onActivated as tt, onDeactivated as nt } from "vue";
|
|
5
|
+
import { compact as ot, cloneDeep as qt, uniq as zt, groupBy as Kt, debounce as Yt, isEqual as st, startCase as Xt, upperFirst as Zt, remove as Gt, last as Jt } from "lodash";
|
|
6
|
+
import { configureOpenApiClient as Qt, OpenApiError as en } from "@signal24/openapi-client-codegen/browser";
|
|
7
|
+
import { escapeHtml as tn } from "@vue/shared";
|
|
8
|
+
import { escapeHtml as hs } from "@vue/shared";
|
|
9
|
+
import { format as P, addDays as nn, parse as on } from "date-fns";
|
|
10
|
+
const sn = {
|
|
11
11
|
key: 0,
|
|
12
12
|
disabled: ""
|
|
13
|
-
},
|
|
13
|
+
}, ln = {
|
|
14
14
|
key: 0,
|
|
15
15
|
value: null
|
|
16
|
-
},
|
|
16
|
+
}, rn = ["value"], Uo = /* @__PURE__ */ R({
|
|
17
17
|
__name: "vf-ajax-select",
|
|
18
18
|
props: {
|
|
19
19
|
modelValue: {},
|
|
@@ -40,21 +40,21 @@ const on = {
|
|
|
40
40
|
key: 1,
|
|
41
41
|
"onUpdate:modelValue": p[0] || (p[0] = (E) => a.value = E)
|
|
42
42
|
}, [
|
|
43
|
-
n.nullText ? (b(), k("option",
|
|
43
|
+
n.nullText ? (b(), k("option", ln, W(n.nullText), 1)) : A("", !0),
|
|
44
44
|
(b(!0), k(oe, null, se(s.value, (E, v) => {
|
|
45
45
|
var w;
|
|
46
46
|
return b(), k("option", {
|
|
47
47
|
key: v,
|
|
48
48
|
value: (w = l.value) == null ? void 0 : w[v]
|
|
49
|
-
}, W(E), 9,
|
|
49
|
+
}, W(E), 9, rn);
|
|
50
50
|
}), 128))
|
|
51
51
|
], 512)), [
|
|
52
|
-
[
|
|
53
|
-
]) : (b(), k("select",
|
|
52
|
+
[Bt, a.value]
|
|
53
|
+
]) : (b(), k("select", sn, [
|
|
54
54
|
B("option", null, W(n.loadingText || "Loading..."), 1)
|
|
55
55
|
]));
|
|
56
56
|
}
|
|
57
|
-
}),
|
|
57
|
+
}), an = /* @__PURE__ */ R({
|
|
58
58
|
__name: "overlay-anchor",
|
|
59
59
|
props: {
|
|
60
60
|
overlayId: {},
|
|
@@ -96,7 +96,7 @@ const on = {
|
|
|
96
96
|
};
|
|
97
97
|
}
|
|
98
98
|
function c() {
|
|
99
|
-
window.removeEventListener("click", c),
|
|
99
|
+
window.removeEventListener("click", c), dn(t.overlayId);
|
|
100
100
|
}
|
|
101
101
|
return _(() => {
|
|
102
102
|
setTimeout(() => {
|
|
@@ -104,25 +104,25 @@ const on = {
|
|
|
104
104
|
}, 10);
|
|
105
105
|
}), (p, E) => (b(), k("div", {
|
|
106
106
|
class: $(["vf-overlay-anchor", l.value]),
|
|
107
|
-
style:
|
|
107
|
+
style: _t(o.value),
|
|
108
108
|
onClick: we(c, ["stop"])
|
|
109
109
|
}, [
|
|
110
|
-
|
|
110
|
+
U(p.$slots, "default")
|
|
111
111
|
], 6));
|
|
112
112
|
}
|
|
113
113
|
});
|
|
114
|
-
let
|
|
115
|
-
const N =
|
|
114
|
+
let un = 0;
|
|
115
|
+
const N = Nt([]), jo = R({
|
|
116
116
|
setup() {
|
|
117
117
|
return () => ie("div", [
|
|
118
|
-
se(N, (e) => ie(
|
|
118
|
+
se(N, (e) => ie(Rt, { key: e.id, to: "#vf-overlay-target" }, [e.wrapperVnode ?? e.vnode]))
|
|
119
119
|
]);
|
|
120
120
|
}
|
|
121
121
|
});
|
|
122
122
|
function be(e, t, n) {
|
|
123
123
|
const o = document.getElementById("vf-overlay-target") ?? document.createElement("div");
|
|
124
124
|
o.id = "vf-overlay-target", o.removeAttribute("inert"), document.body.appendChild(o);
|
|
125
|
-
const l = String(++
|
|
125
|
+
const l = String(++un), s = Wt(e), a = ie(s, t), r = n != null && n.anchor ? ie(an, { overlayId: l, anchor: n.anchor }, () => [a]) : void 0, c = {
|
|
126
126
|
id: l,
|
|
127
127
|
component: s,
|
|
128
128
|
props: t,
|
|
@@ -132,19 +132,19 @@ function be(e, t, n) {
|
|
|
132
132
|
};
|
|
133
133
|
return N.push(c), c;
|
|
134
134
|
}
|
|
135
|
-
function
|
|
136
|
-
e.$ &&
|
|
135
|
+
function Po(e) {
|
|
136
|
+
e.$ && it(e.$);
|
|
137
137
|
}
|
|
138
|
-
function
|
|
138
|
+
function it(e) {
|
|
139
139
|
let t = e;
|
|
140
|
-
for (; t && !
|
|
140
|
+
for (; t && !cn(t.vnode); )
|
|
141
141
|
t = t.parent;
|
|
142
142
|
}
|
|
143
|
-
function
|
|
143
|
+
function cn(e) {
|
|
144
144
|
const t = N.findIndex((n) => n.vnode.component === e.component);
|
|
145
145
|
return t >= 0 ? (N[t].props.callback(), !0) : !1;
|
|
146
146
|
}
|
|
147
|
-
function
|
|
147
|
+
function dn(e) {
|
|
148
148
|
const t = N.findIndex((n) => n.id === e);
|
|
149
149
|
return t >= 0 ? (N[t].props.callback(), !0) : !1;
|
|
150
150
|
}
|
|
@@ -172,17 +172,17 @@ function re(e, t) {
|
|
|
172
172
|
classes: e.classes ?? []
|
|
173
173
|
} : { title: t ? e : void 0, message: t ?? e, classes: [] };
|
|
174
174
|
}
|
|
175
|
-
async function
|
|
175
|
+
async function fn(e, t) {
|
|
176
176
|
await ke(ue, re(e, t));
|
|
177
177
|
}
|
|
178
|
-
async function
|
|
178
|
+
async function qo(e, t) {
|
|
179
179
|
const n = re(e, t);
|
|
180
180
|
return await ke(ue, {
|
|
181
181
|
...n,
|
|
182
182
|
shouldConfirm: !0
|
|
183
183
|
}) === !0;
|
|
184
184
|
}
|
|
185
|
-
async function
|
|
185
|
+
async function zo(e, t) {
|
|
186
186
|
const n = re(e, t);
|
|
187
187
|
return await ke(ue, {
|
|
188
188
|
...n,
|
|
@@ -190,7 +190,7 @@ async function qo(e, t) {
|
|
|
190
190
|
classes: ["destructive", ...n.classes]
|
|
191
191
|
}) === !0;
|
|
192
192
|
}
|
|
193
|
-
function
|
|
193
|
+
function Ko(e, t) {
|
|
194
194
|
const n = re(e, t), o = be(ue, {
|
|
195
195
|
...n,
|
|
196
196
|
isBare: !0,
|
|
@@ -207,7 +207,7 @@ const I = {
|
|
|
207
207
|
defaultTimeFormat: "H:mm",
|
|
208
208
|
defaultCurrencyDivisor: 1
|
|
209
209
|
};
|
|
210
|
-
function
|
|
210
|
+
function Yo(e) {
|
|
211
211
|
Object.assign(I, e);
|
|
212
212
|
}
|
|
213
213
|
class ae extends Error {
|
|
@@ -215,7 +215,7 @@ class ae extends Error {
|
|
|
215
215
|
super(t), this.name = "UserError";
|
|
216
216
|
}
|
|
217
217
|
}
|
|
218
|
-
function
|
|
218
|
+
function vn(e) {
|
|
219
219
|
return e instanceof ae ? e.message : `An application error has occurred:
|
|
220
220
|
|
|
221
221
|
${Te(e).message}
|
|
@@ -223,47 +223,47 @@ ${Te(e).message}
|
|
|
223
223
|
Please refresh the page and try again. If this error persists, ${I.unhandledErrorSupportText}.`;
|
|
224
224
|
}
|
|
225
225
|
function Te(e) {
|
|
226
|
-
return
|
|
226
|
+
return mn(e) ? e : new Error(String(e));
|
|
227
227
|
}
|
|
228
|
-
function
|
|
228
|
+
function mn(e) {
|
|
229
229
|
return e instanceof Error || typeof e == "object" && e !== null && "message" in e && "name" in e;
|
|
230
230
|
}
|
|
231
|
-
async function
|
|
231
|
+
async function Xo(e, t) {
|
|
232
232
|
const n = Te(e);
|
|
233
|
-
return n instanceof ae || I.errorHandler(n),
|
|
233
|
+
return n instanceof ae || I.errorHandler(n), fn({
|
|
234
234
|
title: t == null ? void 0 : t.title,
|
|
235
235
|
message: n,
|
|
236
236
|
classes: t == null ? void 0 : t.classes
|
|
237
237
|
});
|
|
238
238
|
}
|
|
239
|
-
async function
|
|
239
|
+
async function Zo(e) {
|
|
240
240
|
const t = Te(e);
|
|
241
241
|
t instanceof ae || I.errorHandler(t);
|
|
242
242
|
}
|
|
243
243
|
const Z = Symbol("MaskState");
|
|
244
|
-
function
|
|
244
|
+
function Go(e, t) {
|
|
245
245
|
var l;
|
|
246
246
|
const n = (l = e.$) == null ? void 0 : l.vnode.el, o = n.closest(".vf-modal");
|
|
247
|
-
return
|
|
247
|
+
return pn(o ?? n, t);
|
|
248
248
|
}
|
|
249
|
-
function
|
|
249
|
+
function Jo(e) {
|
|
250
250
|
var o;
|
|
251
251
|
const t = (o = e.$) == null ? void 0 : o.vnode.el, n = t.closest(".vf-modal");
|
|
252
|
-
return
|
|
252
|
+
return lt(n ?? t);
|
|
253
253
|
}
|
|
254
|
-
function
|
|
254
|
+
function pn(e, t) {
|
|
255
255
|
if (!e[Z]) {
|
|
256
256
|
const n = document.createElement("div");
|
|
257
257
|
n.classList.add("vf-mask"), e.appendChild(n), e[Z] = { maskEl: n };
|
|
258
258
|
}
|
|
259
|
-
return e[Z].maskEl.innerText = t ?? "", () =>
|
|
259
|
+
return e[Z].maskEl.innerText = t ?? "", () => lt(e);
|
|
260
260
|
}
|
|
261
|
-
function
|
|
261
|
+
function lt(e) {
|
|
262
262
|
e[Z] && e.removeChild(e[Z].maskEl);
|
|
263
263
|
}
|
|
264
264
|
const ye = Symbol("FormMaskState");
|
|
265
|
-
function
|
|
266
|
-
const o = e instanceof Element ? e :
|
|
265
|
+
function hn(e, t, n) {
|
|
266
|
+
const o = e instanceof Element ? e : at(e);
|
|
267
267
|
if (!o) return () => {
|
|
268
268
|
};
|
|
269
269
|
o.classList.add("vf-masked");
|
|
@@ -275,26 +275,26 @@ function pn(e, t, n) {
|
|
|
275
275
|
disabledElements: r,
|
|
276
276
|
waitButton: l,
|
|
277
277
|
buttonHtml: s
|
|
278
|
-
}, () =>
|
|
278
|
+
}, () => rt(o);
|
|
279
279
|
}
|
|
280
|
-
function
|
|
281
|
-
const t = e instanceof Element ? e :
|
|
280
|
+
function rt(e) {
|
|
281
|
+
const t = e instanceof Element ? e : at(e);
|
|
282
282
|
if (!t) return;
|
|
283
283
|
const n = t[ye];
|
|
284
284
|
n && (t.classList.remove("vf-masked"), n.disabledElements.forEach((o) => o.removeAttribute("disabled")), n.waitButton && (n.waitButton.innerHTML = n.buttonHtml, n.waitButton.removeAttribute("disabled")), delete t[ye]);
|
|
285
285
|
}
|
|
286
|
-
function
|
|
286
|
+
function at(e) {
|
|
287
287
|
var n;
|
|
288
288
|
const t = (n = e == null ? void 0 : e.$) == null ? void 0 : n.vnode.el;
|
|
289
289
|
return t ? t.tagName === "FORM" ? t : t.querySelector("form") : null;
|
|
290
290
|
}
|
|
291
|
-
const
|
|
291
|
+
const yn = ["id"], gn = {
|
|
292
292
|
key: 0,
|
|
293
293
|
class: "vf-modal-header"
|
|
294
|
-
},
|
|
294
|
+
}, wn = { class: "vf-modal-content" }, En = {
|
|
295
295
|
key: 1,
|
|
296
296
|
class: "vf-modal-footer"
|
|
297
|
-
},
|
|
297
|
+
}, bn = /* @__PURE__ */ R({
|
|
298
298
|
__name: "vf-modal",
|
|
299
299
|
props: {
|
|
300
300
|
id: {},
|
|
@@ -307,7 +307,7 @@ const hn = ["id"], yn = {
|
|
|
307
307
|
setup(e, { expose: t }) {
|
|
308
308
|
const n = ge(), o = e;
|
|
309
309
|
t({ mask: v, unmask: w, hide: g, unhide: u });
|
|
310
|
-
const l = T(), s = T(), a = T(!1), r = M(() =>
|
|
310
|
+
const l = T(), s = T(), a = T(!1), r = M(() => ot([...Array.isArray(o.class) ? o.class : [o.class], a.value && "hidden"]));
|
|
311
311
|
_(() => {
|
|
312
312
|
var d;
|
|
313
313
|
document.body.classList.add("vf-modal-open"), o.closeOnMaskClick && (window.addEventListener("keydown", p), (d = l.value) == null || d.addEventListener("click", c));
|
|
@@ -324,13 +324,13 @@ const hn = ["id"], yn = {
|
|
|
324
324
|
}
|
|
325
325
|
}
|
|
326
326
|
function E() {
|
|
327
|
-
|
|
327
|
+
it(n);
|
|
328
328
|
}
|
|
329
329
|
function v() {
|
|
330
|
-
return
|
|
330
|
+
return hn(s.value), () => w();
|
|
331
331
|
}
|
|
332
332
|
function w() {
|
|
333
|
-
|
|
333
|
+
rt(s.value);
|
|
334
334
|
}
|
|
335
335
|
function g() {
|
|
336
336
|
return a.value = !0, () => u();
|
|
@@ -351,24 +351,24 @@ const hn = ["id"], yn = {
|
|
|
351
351
|
class: $(["vf-modal", { scrolls: d.scrolls }]),
|
|
352
352
|
onSubmit: S[0] || (S[0] = we((O) => d.$emit("formSubmit"), ["prevent"]))
|
|
353
353
|
}, [
|
|
354
|
-
d.$slots.header ? (b(), k("div",
|
|
355
|
-
|
|
354
|
+
d.$slots.header ? (b(), k("div", gn, [
|
|
355
|
+
U(d.$slots, "header"),
|
|
356
356
|
o.closeX ? (b(), k("i", {
|
|
357
357
|
key: 0,
|
|
358
358
|
class: "close",
|
|
359
359
|
onClick: E
|
|
360
360
|
})) : A("", !0)
|
|
361
361
|
])) : A("", !0),
|
|
362
|
-
B("div",
|
|
363
|
-
|
|
362
|
+
B("div", wn, [
|
|
363
|
+
U(d.$slots, "default")
|
|
364
364
|
]),
|
|
365
|
-
d.$slots.footer ? (b(), k("div",
|
|
366
|
-
|
|
365
|
+
d.$slots.footer ? (b(), k("div", En, [
|
|
366
|
+
U(d.$slots, "footer")
|
|
367
367
|
])) : A("", !0)
|
|
368
368
|
], 34)
|
|
369
|
-
], 10,
|
|
369
|
+
], 10, yn));
|
|
370
370
|
}
|
|
371
|
-
}),
|
|
371
|
+
}), kn = ["innerHtml"], Tn = ["innerText"], ue = /* @__PURE__ */ R({
|
|
372
372
|
__name: "vf-alert-modal",
|
|
373
373
|
props: {
|
|
374
374
|
isBare: { type: Boolean },
|
|
@@ -381,10 +381,10 @@ const hn = ["id"], yn = {
|
|
|
381
381
|
callback: { type: Function }
|
|
382
382
|
},
|
|
383
383
|
setup(e) {
|
|
384
|
-
const t = e, n = M(() => t.message instanceof Error ?
|
|
384
|
+
const t = e, n = M(() => t.message instanceof Error ? vn(t.message) : t.message);
|
|
385
385
|
return (o, l) => {
|
|
386
|
-
const s =
|
|
387
|
-
return b(),
|
|
386
|
+
const s = Ut("autofocus");
|
|
387
|
+
return b(), et(bn, {
|
|
388
388
|
class: $(["vf-alert", ...o.classes ?? []])
|
|
389
389
|
}, jt({
|
|
390
390
|
default: me(() => [
|
|
@@ -396,10 +396,10 @@ const hn = ["id"], yn = {
|
|
|
396
396
|
key: 1,
|
|
397
397
|
innerHtml: o.message,
|
|
398
398
|
class: "user-message"
|
|
399
|
-
}, null, 8,
|
|
399
|
+
}, null, 8, kn)) : (b(), k("div", {
|
|
400
400
|
key: 2,
|
|
401
401
|
innerText: n.value
|
|
402
|
-
}, null, 8,
|
|
402
|
+
}, null, 8, Tn))
|
|
403
403
|
]),
|
|
404
404
|
_: 2
|
|
405
405
|
}, [
|
|
@@ -442,6 +442,70 @@ const hn = ["id"], yn = {
|
|
|
442
442
|
};
|
|
443
443
|
}
|
|
444
444
|
});
|
|
445
|
+
function Qo(e, t, n) {
|
|
446
|
+
const o = typeof t == "function" ? e.findIndex(t) : e.indexOf(t);
|
|
447
|
+
return o === -1 ? !1 : (e.splice(o, 1, n), !0);
|
|
448
|
+
}
|
|
449
|
+
function es(e, t) {
|
|
450
|
+
const n = document.createElement("div");
|
|
451
|
+
n.classList.add("vf-overlay"), n.addEventListener("click", v), document.body.appendChild(n);
|
|
452
|
+
const o = document.createElement("div");
|
|
453
|
+
o.classList.add("vf-context-menu"), o.style.position = "absolute", n.appendChild(o);
|
|
454
|
+
const l = e.currentTarget;
|
|
455
|
+
l.style.userSelect = "none", l.classList.add("context-menu-active"), t.targetClass && l.classList.add(t.targetClass), t.class && o.classList.add(t.class), t.items.forEach((g) => {
|
|
456
|
+
if (g == "-") {
|
|
457
|
+
const d = document.createElement("div");
|
|
458
|
+
d.classList.add("separator"), o.appendChild(d);
|
|
459
|
+
return;
|
|
460
|
+
}
|
|
461
|
+
const u = document.createElement("div");
|
|
462
|
+
u.classList.add("item"), u.style.userSelect = "none", u.innerText = g.title, o.appendChild(u), g.class && u.classList.add(g.class), g.shouldConfirm ? u.addEventListener("click", (d) => w(d, u, g.handler)) : u.addEventListener("click", () => g.handler());
|
|
463
|
+
});
|
|
464
|
+
const s = window.innerWidth - e.clientX, a = window.innerHeight - e.clientY, r = o.offsetHeight, c = o.offsetWidth, p = s < c ? e.clientX - c - 1 : e.clientX + 1, E = a < r ? e.clientY - r - 1 : e.clientY + 1;
|
|
465
|
+
o.style.left = p + "px", o.style.top = E + "px", setTimeout(() => {
|
|
466
|
+
o.style.width = o.offsetWidth + "px";
|
|
467
|
+
}, 50);
|
|
468
|
+
function v() {
|
|
469
|
+
t.targetClass && l.classList.remove(t.targetClass), l.classList.remove("context-menu-active"), l.style.userSelect = "", n.remove();
|
|
470
|
+
}
|
|
471
|
+
function w(g, u, d) {
|
|
472
|
+
if (u.classList.contains("pending-confirm"))
|
|
473
|
+
return d();
|
|
474
|
+
const S = u.innerHTML;
|
|
475
|
+
u.classList.add("pending-confirm"), u.innerText = "Confirm";
|
|
476
|
+
const O = () => {
|
|
477
|
+
u.classList.remove("pending-confirm"), u.innerHTML = S, u.removeEventListener("mouseleave", O);
|
|
478
|
+
};
|
|
479
|
+
u.addEventListener("mouseleave", O), g.stopPropagation();
|
|
480
|
+
}
|
|
481
|
+
}
|
|
482
|
+
const Cn = (e) => new Promise((t) => setTimeout(t, e)), ts = (e) => Cn(e * 1e3);
|
|
483
|
+
function Sn(e) {
|
|
484
|
+
return e.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",");
|
|
485
|
+
}
|
|
486
|
+
function ns(e, t) {
|
|
487
|
+
return e != null ? qt(e) : t;
|
|
488
|
+
}
|
|
489
|
+
function os(e, t) {
|
|
490
|
+
const n = { ...e };
|
|
491
|
+
for (const o of t)
|
|
492
|
+
n[o] === "" && (n[o] = null);
|
|
493
|
+
return n;
|
|
494
|
+
}
|
|
495
|
+
function je(e) {
|
|
496
|
+
return e != null;
|
|
497
|
+
}
|
|
498
|
+
function ss(e, t) {
|
|
499
|
+
Qt(e, {
|
|
500
|
+
...t,
|
|
501
|
+
onError(n, o) {
|
|
502
|
+
var s;
|
|
503
|
+
n instanceof en && n.response.status === 422 && typeof n.body == "object" && n.body && "error" in n.body && typeof n.body.error == "string" && (n = new ae(n.body.error));
|
|
504
|
+
const l = (s = t.onError) == null ? void 0 : s.call(t, n, o);
|
|
505
|
+
return l !== void 0 ? l : n;
|
|
506
|
+
}
|
|
507
|
+
});
|
|
508
|
+
}
|
|
445
509
|
/*!
|
|
446
510
|
* currency.js - v2.0.4
|
|
447
511
|
* http://scurker.github.io/currency.js
|
|
@@ -449,7 +513,7 @@ const hn = ["id"], yn = {
|
|
|
449
513
|
* Copyright (c) 2021 Jason Wilson
|
|
450
514
|
* Released under MIT license
|
|
451
515
|
*/
|
|
452
|
-
var
|
|
516
|
+
var Mn = {
|
|
453
517
|
symbol: "$",
|
|
454
518
|
separator: ",",
|
|
455
519
|
decimal: ".",
|
|
@@ -457,21 +521,21 @@ var Tn = {
|
|
|
457
521
|
precision: 2,
|
|
458
522
|
pattern: "!#",
|
|
459
523
|
negativePattern: "-!#",
|
|
460
|
-
format:
|
|
524
|
+
format: In,
|
|
461
525
|
fromCents: !1
|
|
462
|
-
},
|
|
526
|
+
}, ut = function(t) {
|
|
463
527
|
return Math.round(t);
|
|
464
528
|
}, Ce = function(t) {
|
|
465
529
|
return Math.pow(10, t);
|
|
466
|
-
},
|
|
467
|
-
return
|
|
468
|
-
},
|
|
530
|
+
}, Ln = function(t, n) {
|
|
531
|
+
return ut(t / n) * n;
|
|
532
|
+
}, xn = /(\d)(?=(\d{3})+\b)/g, Fn = /(\d)(?=(\d\d)+\d\b)/g;
|
|
469
533
|
function V(e, t) {
|
|
470
534
|
var n = this;
|
|
471
535
|
if (!(n instanceof V))
|
|
472
536
|
return new V(e, t);
|
|
473
|
-
var o = Object.assign({},
|
|
474
|
-
n.intValue = s, n.value = s / l, o.increment = o.increment || 1 / l, o.useVedic ? o.groups =
|
|
537
|
+
var o = Object.assign({}, Mn, t), l = Ce(o.precision), s = te(e, o);
|
|
538
|
+
n.intValue = s, n.value = s / l, o.increment = o.increment || 1 / l, o.useVedic ? o.groups = Fn : o.groups = xn, this.s = o, this.p = l;
|
|
475
539
|
}
|
|
476
540
|
function te(e, t) {
|
|
477
541
|
var n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : !0, o = 0, l = t.decimal, s = t.errorOnInvalid, a = t.precision, r = t.fromCents, c = Ce(a), p = typeof e == "number", E = e instanceof V;
|
|
@@ -487,9 +551,9 @@ function te(e, t) {
|
|
|
487
551
|
throw Error("Invalid Input");
|
|
488
552
|
o = 0;
|
|
489
553
|
}
|
|
490
|
-
return r || (o *= c, o = o.toFixed(4)), n ?
|
|
554
|
+
return r || (o *= c, o = o.toFixed(4)), n ? ut(o) : o;
|
|
491
555
|
}
|
|
492
|
-
function
|
|
556
|
+
function In(e, t) {
|
|
493
557
|
var n = t.pattern, o = t.negativePattern, l = t.symbol, s = t.separator, a = t.decimal, r = t.groups, c = ("" + e).replace(/^-/, "").split("."), p = c[0], E = c[1];
|
|
494
558
|
return (e.value >= 0 ? n : o).replace("!", l).replace("#", p.replace(r, "$1" + s) + (E ? a + E : ""));
|
|
495
559
|
}
|
|
@@ -573,7 +637,7 @@ V.prototype = {
|
|
|
573
637
|
*/
|
|
574
638
|
toString: function() {
|
|
575
639
|
var t = this.intValue, n = this.p, o = this.s;
|
|
576
|
-
return
|
|
640
|
+
return Ln(t / n, o.increment).toFixed(o.precision);
|
|
577
641
|
},
|
|
578
642
|
/**
|
|
579
643
|
* Value for JSON serialization.
|
|
@@ -586,56 +650,56 @@ V.prototype = {
|
|
|
586
650
|
const x = [];
|
|
587
651
|
for (let e = 0; e < 256; ++e)
|
|
588
652
|
x.push((e + 256).toString(16).slice(1));
|
|
589
|
-
function
|
|
653
|
+
function On(e, t = 0) {
|
|
590
654
|
return (x[e[t + 0]] + x[e[t + 1]] + x[e[t + 2]] + x[e[t + 3]] + "-" + x[e[t + 4]] + x[e[t + 5]] + "-" + x[e[t + 6]] + x[e[t + 7]] + "-" + x[e[t + 8]] + x[e[t + 9]] + "-" + x[e[t + 10]] + x[e[t + 11]] + x[e[t + 12]] + x[e[t + 13]] + x[e[t + 14]] + x[e[t + 15]]).toLowerCase();
|
|
591
655
|
}
|
|
592
656
|
let pe;
|
|
593
|
-
const
|
|
594
|
-
function
|
|
657
|
+
const Dn = new Uint8Array(16);
|
|
658
|
+
function Hn() {
|
|
595
659
|
if (!pe) {
|
|
596
660
|
if (typeof crypto > "u" || !crypto.getRandomValues)
|
|
597
661
|
throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
|
|
598
662
|
pe = crypto.getRandomValues.bind(crypto);
|
|
599
663
|
}
|
|
600
|
-
return pe(
|
|
664
|
+
return pe(Dn);
|
|
601
665
|
}
|
|
602
|
-
const
|
|
603
|
-
function
|
|
666
|
+
const Vn = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), Pe = { randomUUID: Vn };
|
|
667
|
+
function An(e, t, n) {
|
|
604
668
|
var l;
|
|
605
|
-
if (
|
|
606
|
-
return
|
|
669
|
+
if (Pe.randomUUID && !e)
|
|
670
|
+
return Pe.randomUUID();
|
|
607
671
|
e = e || {};
|
|
608
|
-
const o = e.random ?? ((l = e.rng) == null ? void 0 : l.call(e)) ??
|
|
672
|
+
const o = e.random ?? ((l = e.rng) == null ? void 0 : l.call(e)) ?? Hn();
|
|
609
673
|
if (o.length < 16)
|
|
610
674
|
throw new Error("Random bytes length must be >= 16");
|
|
611
|
-
return o[6] = o[6] & 15 | 64, o[8] = o[8] & 63 | 128,
|
|
675
|
+
return o[6] = o[6] & 15 | 64, o[8] = o[8] & 63 | 128, On(o);
|
|
612
676
|
}
|
|
613
|
-
function
|
|
677
|
+
function is(e) {
|
|
614
678
|
return e.replace(/\n/g, "<br>");
|
|
615
679
|
}
|
|
616
|
-
function
|
|
680
|
+
function $n(e) {
|
|
617
681
|
return e.replace(/_/g, " ");
|
|
618
682
|
}
|
|
619
|
-
function
|
|
683
|
+
function Bn(e) {
|
|
620
684
|
const t = e.replace(/\D/g, "").replace(/^1/, "");
|
|
621
685
|
return t.length != 10 ? e : "(" + t.substring(0, 3) + ") " + t.substring(3, 6) + "-" + t.substring(6);
|
|
622
686
|
}
|
|
623
|
-
function
|
|
687
|
+
function _n(e, t) {
|
|
624
688
|
return V(e).divide(t ?? I.defaultCurrencyDivisor).format();
|
|
625
689
|
}
|
|
626
|
-
function
|
|
627
|
-
return
|
|
690
|
+
function ls() {
|
|
691
|
+
return An();
|
|
628
692
|
}
|
|
629
|
-
const
|
|
693
|
+
const Nn = ["disabled", "placeholder", "required", "name"], Rn = {
|
|
630
694
|
key: 0,
|
|
631
695
|
class: "no-results"
|
|
632
|
-
},
|
|
696
|
+
}, Wn = {
|
|
633
697
|
key: 0,
|
|
634
698
|
class: "group-title"
|
|
635
|
-
},
|
|
699
|
+
}, Un = ["onMousemove", "onMousedown"], jn = ["innerHTML"], Pn = ["innerHTML"], qn = {
|
|
636
700
|
key: 1,
|
|
637
701
|
class: "no-results"
|
|
638
|
-
},
|
|
702
|
+
}, zn = "`1234567890-=[]\\;',./~!@#$%^&*()_+{}|:\"<>?qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM", Kn = /* @__PURE__ */ R({
|
|
639
703
|
__name: "vf-smart-select",
|
|
640
704
|
props: {
|
|
641
705
|
modelValue: {},
|
|
@@ -674,13 +738,13 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
674
738
|
setup(e, { expose: t, emit: n }) {
|
|
675
739
|
const o = Symbol("null"), l = Symbol("create"), s = e, a = n;
|
|
676
740
|
t({
|
|
677
|
-
addRemoteOption:
|
|
741
|
+
addRemoteOption: Vt
|
|
678
742
|
});
|
|
679
|
-
const r = T(), c = T(), p = T(), E = T(!1), v = T(!1), w = T(), g = T(!1), u = T(""), d = T(null), S = T(null), O = T(!1), L = T(null), Le = T(!1),
|
|
743
|
+
const r = T(), c = T(), p = T(), E = T(!1), v = T(!1), w = T(), g = T(!1), u = T(""), d = T(null), S = T(null), O = T(!1), L = T(null), Le = T(!1), gt = M(() => s.showCreateTextOnNewItem ?? !0), wt = M(() => s.prependOptions ?? []), Et = M(() => s.appendOptions ?? []), xe = M(() => !!s.disabled || !s.options && !w.value), bt = M(() => !v.value && s.preload ? "Loading..." : s.nullTitle ? s.nullTitle : s.placeholder || ""), kt = M(() => s.noResultsText || "No options match your search."), q = M(() => s.valueExtractor ? s.valueExtractor : s.valueField ? (i) => i[s.valueField] : null), z = M(() => s.keyExtractor ? s.keyExtractor : s.keyField ? (i) => String(i[s.keyField]) : q.value ? (i) => String(q.value(i)) : null), ce = M(() => s.groupFormatter ? s.groupFormatter : s.groupField ? (i) => String(i[s.groupField]) : null), Fe = M(() => s.formatter ? s.formatter : s.labelField ? (i) => String(i[s.labelField]) : (i) => String(i)), Ie = M(() => s.selectionFormatter ? s.selectionFormatter : Fe.value), Oe = M(() => [...wt.value, ...w.value ?? [], ...Et.value]), De = M(() => !!(s.groupField || s.groupFormatter)), de = M(() => Oe.value.map((i, m) => {
|
|
680
744
|
var Ne, Re, We;
|
|
681
745
|
const h = (Ne = ce.value) == null ? void 0 : Ne.call(ce, i), f = Fe.value(i), y = (Re = s.subtitleFormatter) == null ? void 0 : Re.call(s, i), C = f ? f.trim().toLowerCase() : "", _e = y ? y.trim().toLowerCase() : "", ee = [];
|
|
682
|
-
return s.searchFields ? s.searchFields.forEach((
|
|
683
|
-
i[
|
|
746
|
+
return s.searchFields ? s.searchFields.forEach((Ue) => {
|
|
747
|
+
i[Ue] && ee.push(String(i[Ue]).toLowerCase());
|
|
684
748
|
}) : (ee.push(C), _e && ee.push(_e)), {
|
|
685
749
|
key: ((We = z.value) == null ? void 0 : We.call(z, i)) ?? String(m),
|
|
686
750
|
group: h,
|
|
@@ -695,7 +759,7 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
695
759
|
const m = u.value.trim().toLowerCase();
|
|
696
760
|
if (m.length) {
|
|
697
761
|
i = i.filter((y) => y.searchContent.includes(m));
|
|
698
|
-
const h =
|
|
762
|
+
const h = tn(u.value).replace(/[-/\\^$*+?.()|[\]{}]/g, "\\$&"), f = new RegExp(`(${h})`, "ig");
|
|
699
763
|
i = i.map((y) => {
|
|
700
764
|
var C;
|
|
701
765
|
return {
|
|
@@ -705,7 +769,7 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
705
769
|
};
|
|
706
770
|
}), Le.value && (i.find((C) => C.searchContent === m) !== void 0 || i.push({
|
|
707
771
|
key: l,
|
|
708
|
-
title:
|
|
772
|
+
title: gt.value ? "Create <strong>" + u.value.trim() + "</strong>..." : u.value.trim()
|
|
709
773
|
}));
|
|
710
774
|
}
|
|
711
775
|
} else s.nullTitle && i.unshift({
|
|
@@ -713,7 +777,7 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
713
777
|
title: s.nullTitle
|
|
714
778
|
});
|
|
715
779
|
return i;
|
|
716
|
-
}),
|
|
780
|
+
}), Tt = M(() => {
|
|
717
781
|
if (!De.value)
|
|
718
782
|
return [
|
|
719
783
|
{
|
|
@@ -721,7 +785,7 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
721
785
|
options: F.value
|
|
722
786
|
}
|
|
723
787
|
];
|
|
724
|
-
const i =
|
|
788
|
+
const i = zt(F.value.map((h) => h.group ?? "")), m = Kt(F.value, (h) => h.group ?? "");
|
|
725
789
|
return i.map((h) => ({
|
|
726
790
|
groupTitle: h,
|
|
727
791
|
options: m[h]
|
|
@@ -737,7 +801,7 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
737
801
|
}), H(u, () => {
|
|
738
802
|
g.value && !s.remoteSearch && !u.value.trim().length && (g.value = !1);
|
|
739
803
|
}), H(O, () => {
|
|
740
|
-
O.value ? setTimeout(
|
|
804
|
+
O.value ? setTimeout(Ot, 0) : (g.value = !1, u.value = S.value ?? "", p.value && (p.value.style.visibility = "hidden"));
|
|
741
805
|
}), H(F, () => {
|
|
742
806
|
var i;
|
|
743
807
|
s.modelValue !== null && d.value === null && ve(), (L.value !== null || g.value) && !F.value.find((m) => m.key == L.value) && (L.value = ((i = F.value[0]) == null ? void 0 : i.key) ?? o);
|
|
@@ -745,9 +809,9 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
745
809
|
Le.value = s.onCreateItem !== void 0, s.options ? (w.value = [...s.options], v.value = !0) : s.loadOptions && s.preload && await He(), !s.options && (s.valueField || s.valueExtractor) ? u.value = s.loadingText ?? "..." : ve(), H(d, () => {
|
|
746
810
|
d.value !== s.modelValue && a(
|
|
747
811
|
"update:modelValue",
|
|
748
|
-
d.value
|
|
812
|
+
je(d.value) && q.value !== null ? q.value(d.value) : d.value
|
|
749
813
|
);
|
|
750
|
-
}), s.remoteSearch && H(u,
|
|
814
|
+
}), s.remoteSearch && H(u, Yt(Ct, 250));
|
|
751
815
|
});
|
|
752
816
|
async function He() {
|
|
753
817
|
await Ve(), w.value && a("optionsLoaded", w.value);
|
|
@@ -757,10 +821,10 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
757
821
|
const i = s.remoteSearch && g.value && u.value.length ? u.value : null;
|
|
758
822
|
E.value = !0, w.value = await ((m = s.loadOptions) == null ? void 0 : m.call(s, i)) ?? [], E.value = !1, v.value = !0;
|
|
759
823
|
}
|
|
760
|
-
function
|
|
824
|
+
function Ct() {
|
|
761
825
|
g.value && (Ve(), g.value = u.value.trim().length > 0);
|
|
762
826
|
}
|
|
763
|
-
function
|
|
827
|
+
function St(i) {
|
|
764
828
|
if (i.key == "Escape") {
|
|
765
829
|
i.stopPropagation(), i.target.blur(), Be();
|
|
766
830
|
return;
|
|
@@ -785,37 +849,37 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
785
849
|
u.value.length > 1 && (g.value = !0);
|
|
786
850
|
return;
|
|
787
851
|
}
|
|
788
|
-
!i.metaKey &&
|
|
852
|
+
!i.metaKey && zn.includes(i.key) && (g.value = !0);
|
|
789
853
|
}
|
|
790
854
|
}
|
|
791
|
-
function
|
|
792
|
-
|
|
855
|
+
function Mt() {
|
|
856
|
+
Lt(), O.value = !0, setTimeout(() => {
|
|
793
857
|
var i;
|
|
794
858
|
return (i = c.value) == null ? void 0 : i.select();
|
|
795
859
|
}, 0);
|
|
796
860
|
}
|
|
797
|
-
function Mt(i) {
|
|
798
|
-
d.value ? L.value = Lt(d.value) : s.nullTitle && (L.value = o);
|
|
799
|
-
}
|
|
800
861
|
function Lt(i) {
|
|
801
|
-
|
|
802
|
-
return z.value ? z.value(d.value) : ((m = xt(i)) == null ? void 0 : m.key) ?? "";
|
|
862
|
+
d.value ? L.value = xt(d.value) : s.nullTitle && (L.value = o);
|
|
803
863
|
}
|
|
804
864
|
function xt(i) {
|
|
865
|
+
var m;
|
|
866
|
+
return z.value ? z.value(d.value) : ((m = Ft(i)) == null ? void 0 : m.key) ?? "";
|
|
867
|
+
}
|
|
868
|
+
function Ft(i) {
|
|
805
869
|
const m = F.value.find((y) => y.ref === i);
|
|
806
870
|
if (m)
|
|
807
871
|
return m;
|
|
808
|
-
const h = s.keyExtractor ? (y, C) => s.keyExtractor(y) === s.keyExtractor(C) :
|
|
872
|
+
const h = s.keyExtractor ? (y, C) => s.keyExtractor(y) === s.keyExtractor(C) : st, f = F.value.find((y) => h(y.ref, i));
|
|
809
873
|
return f || null;
|
|
810
874
|
}
|
|
811
|
-
function
|
|
875
|
+
function It() {
|
|
812
876
|
s.debug || (!u.value.length && s.nullTitle && (d.value = null, S.value = null), O.value = !1);
|
|
813
877
|
}
|
|
814
|
-
function
|
|
878
|
+
function Ot() {
|
|
815
879
|
var i;
|
|
816
|
-
v.value || He(), s.optionsListId && ((i = p.value) == null || i.setAttribute("id", s.optionsListId)),
|
|
880
|
+
v.value || He(), s.optionsListId && ((i = p.value) == null || i.setAttribute("id", s.optionsListId)), Dt();
|
|
817
881
|
}
|
|
818
|
-
function
|
|
882
|
+
function Dt() {
|
|
819
883
|
const i = r.value.getBoundingClientRect(), m = i.y + i.height + 2, h = i.x, f = p.value, y = window.getComputedStyle(r.value);
|
|
820
884
|
for (let C in y)
|
|
821
885
|
/^(font|text)/.test(C) && (f.style[C] = y[C]);
|
|
@@ -830,7 +894,7 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
830
894
|
const i = F.value.findIndex((f) => f.key == L.value), m = p.value, h = m == null ? void 0 : m.querySelectorAll(".option")[i];
|
|
831
895
|
h && (m.scrollTop = h.offsetTop);
|
|
832
896
|
}
|
|
833
|
-
function
|
|
897
|
+
function Ht(i) {
|
|
834
898
|
L.value = i ? i.key : null;
|
|
835
899
|
}
|
|
836
900
|
function fe(i) {
|
|
@@ -855,9 +919,9 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
855
919
|
(h = c.value) == null || h.blur(), Be();
|
|
856
920
|
}
|
|
857
921
|
function ve() {
|
|
858
|
-
s.modelValue !== null ? (d.value = q.value ? Oe.value.find((i) => s.modelValue === q.value(i)) : s.modelValue, S.value = d.value
|
|
922
|
+
s.modelValue !== null ? (d.value = q.value ? Oe.value.find((i) => s.modelValue === q.value(i)) : s.modelValue, S.value = je(d.value) ? Ie.value(d.value) : null, u.value = S.value ?? "") : (d.value = null, S.value = null, u.value = "");
|
|
859
923
|
}
|
|
860
|
-
function
|
|
924
|
+
function Vt(i) {
|
|
861
925
|
w.value.unshift(i);
|
|
862
926
|
}
|
|
863
927
|
function Be() {
|
|
@@ -884,15 +948,15 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
884
948
|
type: "text",
|
|
885
949
|
disabled: xe.value,
|
|
886
950
|
class: $({ nullable: !!i.nullTitle }),
|
|
887
|
-
placeholder:
|
|
951
|
+
placeholder: bt.value,
|
|
888
952
|
required: i.required,
|
|
889
953
|
name: i.name,
|
|
890
954
|
"data-1p-ignore": "",
|
|
891
|
-
onKeydown:
|
|
892
|
-
onFocus:
|
|
893
|
-
onBlur:
|
|
894
|
-
}, null, 42,
|
|
895
|
-
[
|
|
955
|
+
onKeydown: St,
|
|
956
|
+
onFocus: Mt,
|
|
957
|
+
onBlur: It
|
|
958
|
+
}, null, 42, Nn), [
|
|
959
|
+
[Pt, u.value]
|
|
896
960
|
]),
|
|
897
961
|
O.value ? (b(), k("div", {
|
|
898
962
|
key: 0,
|
|
@@ -900,12 +964,12 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
900
964
|
ref: p,
|
|
901
965
|
class: $(["vf-smart-select-options", { grouped: De.value }])
|
|
902
966
|
}, [
|
|
903
|
-
v.value ? (b(!0), k(oe, { key: 1 }, se(
|
|
967
|
+
v.value ? (b(!0), k(oe, { key: 1 }, se(Tt.value, (h) => (b(), k("div", {
|
|
904
968
|
key: h.groupTitle,
|
|
905
969
|
class: "group"
|
|
906
970
|
}, [
|
|
907
|
-
h.groupTitle ? (b(), k("div",
|
|
908
|
-
|
|
971
|
+
h.groupTitle ? (b(), k("div", Wn, [
|
|
972
|
+
U(i.$slots, "group", {
|
|
909
973
|
group: h.groupTitle
|
|
910
974
|
}, () => [
|
|
911
975
|
X(W(h.groupTitle), 1)
|
|
@@ -916,32 +980,32 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
916
980
|
return b(), k("div", {
|
|
917
981
|
key: f.key,
|
|
918
982
|
class: $(["option", [L.value === f.key && "highlighted", f.ref && ((y = i.classForOption) == null ? void 0 : y.call(i, f.ref))]]),
|
|
919
|
-
onMousemove: (C) =>
|
|
983
|
+
onMousemove: (C) => Ht(f),
|
|
920
984
|
onMousedown: (C) => $e(f)
|
|
921
985
|
}, [
|
|
922
|
-
|
|
986
|
+
U(i.$slots, "option", { option: f }, () => [
|
|
923
987
|
B("div", {
|
|
924
988
|
class: "title",
|
|
925
989
|
innerHTML: f.title
|
|
926
|
-
}, null, 8,
|
|
990
|
+
}, null, 8, jn),
|
|
927
991
|
f.subtitle ? (b(), k("div", {
|
|
928
992
|
key: 0,
|
|
929
993
|
class: "subtitle",
|
|
930
994
|
innerHTML: f.subtitle
|
|
931
|
-
}, null, 8,
|
|
995
|
+
}, null, 8, Pn)) : A("", !0)
|
|
932
996
|
])
|
|
933
|
-
], 42,
|
|
997
|
+
], 42, Un);
|
|
934
998
|
}), 128)),
|
|
935
|
-
!F.value.length && u.value ? (b(), k("div",
|
|
936
|
-
|
|
937
|
-
X(W(
|
|
999
|
+
!F.value.length && u.value ? (b(), k("div", qn, [
|
|
1000
|
+
U(i.$slots, "no-results", {}, () => [
|
|
1001
|
+
X(W(kt.value), 1)
|
|
938
1002
|
])
|
|
939
1003
|
])) : A("", !0)
|
|
940
|
-
]))), 128)) : (b(), k("div",
|
|
1004
|
+
]))), 128)) : (b(), k("div", Rn, "Loading..."))
|
|
941
1005
|
], 2)) : A("", !0)
|
|
942
1006
|
], 2));
|
|
943
1007
|
}
|
|
944
|
-
}),
|
|
1008
|
+
}), rs = /* @__PURE__ */ R({
|
|
945
1009
|
__name: "vf-ez-smart-select",
|
|
946
1010
|
props: {
|
|
947
1011
|
modelValue: {},
|
|
@@ -964,9 +1028,9 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
964
1028
|
}
|
|
965
1029
|
), H(a, (r) => {
|
|
966
1030
|
var p;
|
|
967
|
-
const c = r ? (p = o.value.find((E) =>
|
|
1031
|
+
const c = r ? (p = o.value.find((E) => st(E, r))) == null ? void 0 : p.value : null;
|
|
968
1032
|
s("update:modelValue", c ?? null);
|
|
969
|
-
}), (r, c) => (b(),
|
|
1033
|
+
}), (r, c) => (b(), et(Kn, {
|
|
970
1034
|
modelValue: a.value,
|
|
971
1035
|
"onUpdate:modelValue": c[0] || (c[0] = (p) => a.value = p),
|
|
972
1036
|
options: o.value,
|
|
@@ -977,16 +1041,16 @@ const $n = ["disabled", "placeholder", "required", "name"], Bn = {
|
|
|
977
1041
|
}, null, 8, ["modelValue", "options", "formatter", "null-title", "placeholder", "name"]));
|
|
978
1042
|
}
|
|
979
1043
|
});
|
|
980
|
-
function
|
|
1044
|
+
function as() {
|
|
981
1045
|
return T();
|
|
982
1046
|
}
|
|
983
|
-
const
|
|
1047
|
+
const Yn = { class: "content" }, Xn = { class: "message" }, Zn = {
|
|
984
1048
|
key: 0,
|
|
985
1049
|
class: "close"
|
|
986
|
-
},
|
|
1050
|
+
}, Gn = {
|
|
987
1051
|
key: 0,
|
|
988
1052
|
class: "progress-bar"
|
|
989
|
-
},
|
|
1053
|
+
}, Jn = /* @__PURE__ */ R({
|
|
990
1054
|
__name: "vf-toast",
|
|
991
1055
|
props: {
|
|
992
1056
|
message: {},
|
|
@@ -1013,11 +1077,11 @@ const qn = { class: "content" }, zn = { class: "message" }, Kn = {
|
|
|
1013
1077
|
class: $(["vf-toast", l.className]),
|
|
1014
1078
|
onClick: we(n, ["stop"])
|
|
1015
1079
|
}, [
|
|
1016
|
-
B("div",
|
|
1017
|
-
B("div",
|
|
1018
|
-
l.disableClose ? A("", !0) : (b(), k("div",
|
|
1080
|
+
B("div", Yn, [
|
|
1081
|
+
B("div", Xn, W(l.message), 1),
|
|
1082
|
+
l.disableClose ? A("", !0) : (b(), k("div", Zn, "x"))
|
|
1019
1083
|
]),
|
|
1020
|
-
l.durationSecs !== null ? (b(), k("div",
|
|
1084
|
+
l.durationSecs !== null ? (b(), k("div", Gn, [
|
|
1021
1085
|
B("div", {
|
|
1022
1086
|
ref_key: "progressInnerEl",
|
|
1023
1087
|
ref: o,
|
|
@@ -1027,173 +1091,111 @@ const qn = { class: "content" }, zn = { class: "message" }, Kn = {
|
|
|
1027
1091
|
], 2));
|
|
1028
1092
|
}
|
|
1029
1093
|
});
|
|
1030
|
-
function
|
|
1031
|
-
const t = be(
|
|
1094
|
+
function us(e) {
|
|
1095
|
+
const t = be(Jn, {
|
|
1032
1096
|
...e,
|
|
1033
1097
|
callback: () => le(t)
|
|
1034
1098
|
});
|
|
1035
1099
|
return () => le(t);
|
|
1036
1100
|
}
|
|
1037
|
-
function
|
|
1101
|
+
function Qn(e) {
|
|
1038
1102
|
const t = Math.floor(Math.log(e) / Math.log(1024)), o = (e / Math.pow(1024, t)).toFixed(2), l = ["B", "KB", "MB", "GB", "TB"][t];
|
|
1039
1103
|
return `${o} ${l}`;
|
|
1040
1104
|
}
|
|
1041
|
-
function
|
|
1105
|
+
function eo(e) {
|
|
1042
1106
|
return e != null && String(e).length ? e : "-";
|
|
1043
1107
|
}
|
|
1044
|
-
function
|
|
1108
|
+
function to(e) {
|
|
1045
1109
|
return e || "-";
|
|
1046
1110
|
}
|
|
1047
|
-
function
|
|
1048
|
-
return e === null || typeof e == "string" && !/^\d+$/.test(e) ? e :
|
|
1111
|
+
function no(e) {
|
|
1112
|
+
return e === null || typeof e == "string" && !/^\d+$/.test(e) ? e : Sn(Number(e));
|
|
1049
1113
|
}
|
|
1050
|
-
function
|
|
1051
|
-
return e &&
|
|
1114
|
+
function oo(e) {
|
|
1115
|
+
return e && Bn(e);
|
|
1052
1116
|
}
|
|
1053
|
-
function
|
|
1054
|
-
return e ?
|
|
1117
|
+
function so(e) {
|
|
1118
|
+
return e ? Zt(e) : null;
|
|
1055
1119
|
}
|
|
1056
|
-
function
|
|
1057
|
-
return e ?
|
|
1120
|
+
function ct(e) {
|
|
1121
|
+
return e ? Xt(e) : null;
|
|
1058
1122
|
}
|
|
1059
|
-
function
|
|
1123
|
+
function io(e) {
|
|
1060
1124
|
return e ? e.toUpperCase() : null;
|
|
1061
1125
|
}
|
|
1062
|
-
function
|
|
1063
|
-
return e ?
|
|
1126
|
+
function lo(e) {
|
|
1127
|
+
return e ? ct(e.toLowerCase()) : null;
|
|
1064
1128
|
}
|
|
1065
|
-
function
|
|
1066
|
-
return e ?
|
|
1129
|
+
function ro(e) {
|
|
1130
|
+
return e ? $n(e) : null;
|
|
1067
1131
|
}
|
|
1068
|
-
function
|
|
1069
|
-
return
|
|
1132
|
+
function ao(e, t) {
|
|
1133
|
+
return _n(e, t);
|
|
1070
1134
|
}
|
|
1071
|
-
function
|
|
1135
|
+
function uo(e, t) {
|
|
1072
1136
|
return V(e).divide(t).value;
|
|
1073
1137
|
}
|
|
1074
|
-
function
|
|
1138
|
+
function co(e, t) {
|
|
1075
1139
|
return e && P(new Date(e), t ?? I.defaultDateFormat);
|
|
1076
1140
|
}
|
|
1077
|
-
function
|
|
1141
|
+
function fo(e, t) {
|
|
1078
1142
|
return e && P(new Date(e), t ?? I.defaultTimeFormat);
|
|
1079
1143
|
}
|
|
1080
|
-
function
|
|
1144
|
+
function vo(e, t) {
|
|
1081
1145
|
return e && P(new Date(e), t ?? `${I.defaultDateFormat} ${I.defaultTimeFormat}`);
|
|
1082
1146
|
}
|
|
1083
|
-
function
|
|
1084
|
-
return e && P(
|
|
1085
|
-
}
|
|
1086
|
-
const
|
|
1087
|
-
bytes:
|
|
1088
|
-
dash:
|
|
1089
|
-
dashZeros:
|
|
1090
|
-
number:
|
|
1091
|
-
phone:
|
|
1092
|
-
upperFirst:
|
|
1093
|
-
startCase:
|
|
1094
|
-
upperCase:
|
|
1095
|
-
upperWords:
|
|
1096
|
-
desnake:
|
|
1097
|
-
usCurrency:
|
|
1098
|
-
divide:
|
|
1099
|
-
date:
|
|
1100
|
-
time:
|
|
1101
|
-
dateTime:
|
|
1102
|
-
oneDayForward:
|
|
1103
|
-
},
|
|
1104
|
-
...
|
|
1105
|
-
...e(
|
|
1106
|
-
});
|
|
1107
|
-
function
|
|
1108
|
-
const o = typeof t == "function" ? e.findIndex(t) : e.indexOf(t);
|
|
1109
|
-
return o === -1 ? !1 : (e.splice(o, 1, n), !0);
|
|
1110
|
-
}
|
|
1111
|
-
function is(e, t) {
|
|
1112
|
-
const n = document.createElement("div");
|
|
1113
|
-
n.classList.add("vf-overlay"), n.addEventListener("click", v), document.body.appendChild(n);
|
|
1114
|
-
const o = document.createElement("div");
|
|
1115
|
-
o.classList.add("vf-context-menu"), o.style.position = "absolute", n.appendChild(o);
|
|
1116
|
-
const l = e.currentTarget;
|
|
1117
|
-
l.style.userSelect = "none", l.classList.add("context-menu-active"), t.targetClass && l.classList.add(t.targetClass), t.class && o.classList.add(t.class), t.items.forEach((g) => {
|
|
1118
|
-
if (g == "-") {
|
|
1119
|
-
const d = document.createElement("div");
|
|
1120
|
-
d.classList.add("separator"), o.appendChild(d);
|
|
1121
|
-
return;
|
|
1122
|
-
}
|
|
1123
|
-
const u = document.createElement("div");
|
|
1124
|
-
u.classList.add("item"), u.style.userSelect = "none", u.innerText = g.title, o.appendChild(u), g.class && u.classList.add(g.class), g.shouldConfirm ? u.addEventListener("click", (d) => w(d, u, g.handler)) : u.addEventListener("click", () => g.handler());
|
|
1125
|
-
});
|
|
1126
|
-
const s = window.innerWidth - e.clientX, a = window.innerHeight - e.clientY, r = o.offsetHeight, c = o.offsetWidth, p = s < c ? e.clientX - c - 1 : e.clientX + 1, E = a < r ? e.clientY - r - 1 : e.clientY + 1;
|
|
1127
|
-
o.style.left = p + "px", o.style.top = E + "px", setTimeout(() => {
|
|
1128
|
-
o.style.width = o.offsetWidth + "px";
|
|
1129
|
-
}, 50);
|
|
1130
|
-
function v() {
|
|
1131
|
-
t.targetClass && l.classList.remove(t.targetClass), l.classList.remove("context-menu-active"), l.style.userSelect = "", n.remove();
|
|
1132
|
-
}
|
|
1133
|
-
function w(g, u, d) {
|
|
1134
|
-
if (u.classList.contains("pending-confirm"))
|
|
1135
|
-
return d();
|
|
1136
|
-
const S = u.innerHTML;
|
|
1137
|
-
u.classList.add("pending-confirm"), u.innerText = "Confirm";
|
|
1138
|
-
const O = () => {
|
|
1139
|
-
u.classList.remove("pending-confirm"), u.innerHTML = S, u.removeEventListener("mouseleave", O);
|
|
1140
|
-
};
|
|
1141
|
-
u.addEventListener("mouseleave", O), g.stopPropagation();
|
|
1142
|
-
}
|
|
1143
|
-
}
|
|
1144
|
-
const fo = (e) => new Promise((t) => setTimeout(t, e)), ls = (e) => fo(e * 1e3);
|
|
1145
|
-
function vo(e) {
|
|
1146
|
-
return e.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",");
|
|
1147
|
-
}
|
|
1148
|
-
function rs(e, t) {
|
|
1149
|
-
return e != null ? Xt(e) : t;
|
|
1150
|
-
}
|
|
1151
|
-
function as(e, t) {
|
|
1152
|
-
const n = { ...e };
|
|
1153
|
-
for (const o of t)
|
|
1154
|
-
n[o] === "" && (n[o] = null);
|
|
1155
|
-
return n;
|
|
1156
|
-
}
|
|
1157
|
-
function us(e, t) {
|
|
1158
|
-
tn(e, {
|
|
1159
|
-
...t,
|
|
1160
|
-
onError(n, o) {
|
|
1161
|
-
var s;
|
|
1162
|
-
n instanceof nn && n.response.status === 422 && typeof n.body == "object" && n.body && "error" in n.body && typeof n.body.error == "string" && (n = new ae(n.body.error));
|
|
1163
|
-
const l = (s = t.onError) == null ? void 0 : s.call(t, n, o);
|
|
1164
|
-
return l !== void 0 ? l : n;
|
|
1165
|
-
}
|
|
1166
|
-
});
|
|
1167
|
-
}
|
|
1168
|
-
const Se = Symbol("HookState");
|
|
1169
|
-
function cs(e, t) {
|
|
1147
|
+
function mo(e) {
|
|
1148
|
+
return e && P(nn(on(e, "yyyy-MM-dd", /* @__PURE__ */ new Date()), 1), I.defaultDateFormat);
|
|
1149
|
+
}
|
|
1150
|
+
const qe = {
|
|
1151
|
+
bytes: Qn,
|
|
1152
|
+
dash: eo,
|
|
1153
|
+
dashZeros: to,
|
|
1154
|
+
number: no,
|
|
1155
|
+
phone: oo,
|
|
1156
|
+
upperFirst: so,
|
|
1157
|
+
startCase: ct,
|
|
1158
|
+
upperCase: io,
|
|
1159
|
+
upperWords: lo,
|
|
1160
|
+
desnake: ro,
|
|
1161
|
+
usCurrency: ao,
|
|
1162
|
+
divide: uo,
|
|
1163
|
+
date: co,
|
|
1164
|
+
time: fo,
|
|
1165
|
+
dateTime: vo,
|
|
1166
|
+
oneDayForward: mo
|
|
1167
|
+
}, cs = (e) => ({
|
|
1168
|
+
...qe,
|
|
1169
|
+
...e(qe)
|
|
1170
|
+
}), Se = Symbol("HookState");
|
|
1171
|
+
function ds(e, t) {
|
|
1170
1172
|
const n = t ?? ge();
|
|
1171
|
-
_(() =>
|
|
1173
|
+
_(() => po(n, e), n), tt(() => ho(n), n), nt(() => ze(n), n), Ee(() => ze(n), n);
|
|
1172
1174
|
}
|
|
1173
|
-
function
|
|
1175
|
+
function po(e, t) {
|
|
1174
1176
|
const n = {};
|
|
1175
1177
|
if (t.elScrolledToBottom && (n.el = new G(e.vnode.el, t.elScrolledToBottom)), t.ancestorScrolledToBottom) {
|
|
1176
|
-
const o =
|
|
1178
|
+
const o = dt(e.vnode.el);
|
|
1177
1179
|
o ? n.ancestor = new G(o, t.ancestorScrolledToBottom) : console.warn("[VueFoundation] No scollable ancestor found for component:", e);
|
|
1178
1180
|
}
|
|
1179
1181
|
t.windowScrolledToBottom && (n.window = new G(window, t.windowScrolledToBottom)), e[Se] = n;
|
|
1180
1182
|
}
|
|
1181
|
-
function
|
|
1183
|
+
function ho(e) {
|
|
1182
1184
|
var n, o, l;
|
|
1183
1185
|
const t = e[Se];
|
|
1184
1186
|
(n = t == null ? void 0 : t.el) == null || n.install(), (o = t == null ? void 0 : t.ancestor) == null || o.install(), (l = t == null ? void 0 : t.window) == null || l.install();
|
|
1185
1187
|
}
|
|
1186
|
-
function
|
|
1188
|
+
function ze(e) {
|
|
1187
1189
|
var n, o, l;
|
|
1188
1190
|
const t = e[Se];
|
|
1189
1191
|
(n = t == null ? void 0 : t.el) == null || n.uninstall(), (o = t == null ? void 0 : t.ancestor) == null || o.uninstall(), (l = t == null ? void 0 : t.window) == null || l.uninstall();
|
|
1190
1192
|
}
|
|
1191
1193
|
const he = ["auto", "scroll"];
|
|
1192
|
-
function
|
|
1194
|
+
function dt(e) {
|
|
1193
1195
|
const t = e.parentElement;
|
|
1194
1196
|
if (!t) return null;
|
|
1195
1197
|
const n = window.getComputedStyle(t);
|
|
1196
|
-
return he.includes(n.overflow) || he.includes(n.overflowX) || he.includes(n.overflowY) ? t :
|
|
1198
|
+
return he.includes(n.overflow) || he.includes(n.overflowX) || he.includes(n.overflowY) ? t : dt(t);
|
|
1197
1199
|
}
|
|
1198
1200
|
class G {
|
|
1199
1201
|
constructor(t, n) {
|
|
@@ -1211,23 +1213,23 @@ class G {
|
|
|
1211
1213
|
Math.ceil(this.el.scrollTop + this.el.clientHeight + 5) >= this.el.scrollHeight ? this.isTripped || (this.handler(t), this.isTripped = !0) : this.isTripped && (this.isTripped = !1);
|
|
1212
1214
|
}
|
|
1213
1215
|
}
|
|
1214
|
-
function
|
|
1215
|
-
_(() => window.addEventListener("resize", e)),
|
|
1216
|
+
function fs(e) {
|
|
1217
|
+
_(() => window.addEventListener("resize", e)), tt(() => window.addEventListener("resize", e)), nt(() => window.removeEventListener("resize", e)), Ee(() => window.removeEventListener("resize", e));
|
|
1216
1218
|
}
|
|
1217
|
-
const
|
|
1218
|
-
mounted:
|
|
1219
|
-
updated:
|
|
1220
|
-
},
|
|
1221
|
-
function
|
|
1222
|
-
if (t.value === void 0 && e[
|
|
1223
|
-
e[
|
|
1219
|
+
const yo = {
|
|
1220
|
+
mounted: Ye,
|
|
1221
|
+
updated: Ye
|
|
1222
|
+
}, Ke = Symbol("HasAutoFocused");
|
|
1223
|
+
function Ye(e, t) {
|
|
1224
|
+
if (t.value === void 0 && e[Ke] || t.value !== void 0 && !t.value || t.oldValue !== void 0 && t.value == t.oldValue) return;
|
|
1225
|
+
e[Ke] = !0;
|
|
1224
1226
|
const n = ["BUTTON", "INPUT", "TEXTAREA", "SELECT"].indexOf(e.tagName) > -1 ? e : e.querySelectorAll("input")[0];
|
|
1225
1227
|
setTimeout(() => n.focus(), 10);
|
|
1226
1228
|
}
|
|
1227
|
-
const
|
|
1228
|
-
mounted:
|
|
1229
|
+
const go = {
|
|
1230
|
+
mounted: wo
|
|
1229
1231
|
}, K = Symbol("ConfirmState");
|
|
1230
|
-
function
|
|
1232
|
+
function wo(e, t) {
|
|
1231
1233
|
e.addEventListener("click", (n) => {
|
|
1232
1234
|
var a, r;
|
|
1233
1235
|
const o = Date.now(), l = ((a = t.value) == null ? void 0 : a.text) !== void 0 ? t.value.text : "Confirm";
|
|
@@ -1249,10 +1251,10 @@ function go(e, t) {
|
|
|
1249
1251
|
e[K] = s, l && (e.innerHTML = l), (r = t.value) != null && r.class && e.classList.add(t.value.class), e.addEventListener("mouseout", s.resetHandler);
|
|
1250
1252
|
});
|
|
1251
1253
|
}
|
|
1252
|
-
const
|
|
1253
|
-
beforeMount:
|
|
1254
|
+
const Eo = {
|
|
1255
|
+
beforeMount: bo
|
|
1254
1256
|
};
|
|
1255
|
-
function
|
|
1257
|
+
function bo(e) {
|
|
1256
1258
|
e.addEventListener("blur", () => {
|
|
1257
1259
|
let t = e.value;
|
|
1258
1260
|
/^\d{1,2}\/\d{1,2}$/.test(t) && (t += "/" + P(/* @__PURE__ */ new Date(), "yy"));
|
|
@@ -1260,14 +1262,14 @@ function Eo(e) {
|
|
|
1260
1262
|
isNaN(n) ? e.value = "" : e.value = P(n, "MM/dd/yyyy"), e.dispatchEvent(new Event("input"));
|
|
1261
1263
|
});
|
|
1262
1264
|
}
|
|
1263
|
-
const
|
|
1264
|
-
beforeMount:
|
|
1265
|
-
updated:
|
|
1265
|
+
const ko = {
|
|
1266
|
+
beforeMount: Xe,
|
|
1267
|
+
updated: Xe
|
|
1266
1268
|
};
|
|
1267
|
-
function
|
|
1268
|
-
t.value == t.oldValue && e.innerHTML.length || (e.innerText =
|
|
1269
|
+
function Xe(e, t) {
|
|
1270
|
+
t.value == t.oldValue && e.innerHTML.length || (e.innerText = To(e, t));
|
|
1269
1271
|
}
|
|
1270
|
-
function
|
|
1272
|
+
function To(e, t) {
|
|
1271
1273
|
var p, E;
|
|
1272
1274
|
if (!t.value)
|
|
1273
1275
|
return ((p = e.attributes.getNamedItem("placeholder")) == null ? void 0 : p.value) ?? "";
|
|
@@ -1285,50 +1287,50 @@ function ko(e, t) {
|
|
|
1285
1287
|
const w = /* @__PURE__ */ new Date();
|
|
1286
1288
|
w.getFullYear() === s.getFullYear() ? (w.getMonth() !== s.getMonth() || w.getDate() !== s.getDate()) && (v = "M/d") : v = "M/d/yy";
|
|
1287
1289
|
const g = r ? null : I.defaultTimeFormat;
|
|
1288
|
-
a =
|
|
1290
|
+
a = ot([v, g]).join(" ");
|
|
1289
1291
|
}
|
|
1290
1292
|
a || (r ? a = I.defaultDateFormat : a = `${I.defaultDateFormat} ${I.defaultTimeFormat}`);
|
|
1291
1293
|
let c = P(s, a);
|
|
1292
1294
|
return n && (c = n + " " + c), c;
|
|
1293
1295
|
}
|
|
1294
|
-
const
|
|
1295
|
-
beforeMount:
|
|
1296
|
-
updated:
|
|
1297
|
-
unmounted:
|
|
1296
|
+
const Co = {
|
|
1297
|
+
beforeMount: Ze,
|
|
1298
|
+
updated: Ze,
|
|
1299
|
+
unmounted: So
|
|
1298
1300
|
};
|
|
1299
|
-
function
|
|
1301
|
+
function Ze(e, t) {
|
|
1300
1302
|
e.tagName === "LABEL" && (t.value ? e.classList.remove("disabled") : e.classList.add("disabled"), e = e.querySelector("input")), t.value ? e.setAttribute("disabled", "disabled") : e.removeAttribute("disabled");
|
|
1301
1303
|
}
|
|
1302
|
-
function
|
|
1304
|
+
function So(e) {
|
|
1303
1305
|
e.tagName === "LABEL" && (e.classList.remove("disabled"), e = e.querySelector("input")), e.removeAttribute("disabled");
|
|
1304
1306
|
}
|
|
1305
|
-
const
|
|
1306
|
-
beforeMount:
|
|
1307
|
-
updated:
|
|
1308
|
-
unmounted:
|
|
1307
|
+
const Mo = {
|
|
1308
|
+
beforeMount: Ge,
|
|
1309
|
+
updated: Ge,
|
|
1310
|
+
unmounted: vt
|
|
1309
1311
|
}, Q = Symbol("HasAutoFocused"), Me = [];
|
|
1310
|
-
function
|
|
1311
|
-
Me.forEach(
|
|
1312
|
+
function Lo() {
|
|
1313
|
+
Me.forEach(ft);
|
|
1312
1314
|
}
|
|
1313
|
-
setInterval(
|
|
1314
|
-
function
|
|
1315
|
+
setInterval(Lo, 1e3);
|
|
1316
|
+
function Ge(e, t) {
|
|
1315
1317
|
var a;
|
|
1316
1318
|
if (t.value == t.oldValue) return;
|
|
1317
|
-
if (!t.value) return
|
|
1319
|
+
if (!t.value) return vt(e);
|
|
1318
1320
|
const n = new Date(t.value), o = (a = e.attributes.getNamedItem("base-time")) == null ? void 0 : a.value, l = n.getTime() - (o ? new Date(o).getTime() - t.value * 1e3 : 0), s = e.getAttribute("no-seconds") === null;
|
|
1319
1321
|
e[Q] || Me.push(e), e[Q] = {
|
|
1320
1322
|
startTs: l,
|
|
1321
1323
|
includeSeconds: s
|
|
1322
|
-
},
|
|
1324
|
+
}, ft(e);
|
|
1323
1325
|
}
|
|
1324
|
-
function
|
|
1326
|
+
function ft(e) {
|
|
1325
1327
|
const t = e[Q], n = Math.round((Date.now() - t.startTs) / 1e3);
|
|
1326
|
-
e.innerText =
|
|
1328
|
+
e.innerText = xo(n, t.includeSeconds);
|
|
1327
1329
|
}
|
|
1328
|
-
function
|
|
1329
|
-
e[Q] && (
|
|
1330
|
+
function vt(e) {
|
|
1331
|
+
e[Q] && (Gt(Me, e), delete e[Q]), e.innerText = "-";
|
|
1330
1332
|
}
|
|
1331
|
-
function
|
|
1333
|
+
function xo(e, t) {
|
|
1332
1334
|
const n = [], o = Math.floor(e / 86400);
|
|
1333
1335
|
o && n.push(o + "d"), e -= o * 86400;
|
|
1334
1336
|
const l = Math.floor(e / 3600);
|
|
@@ -1336,34 +1338,34 @@ function Lo(e, t) {
|
|
|
1336
1338
|
const s = Math.floor(e / 60);
|
|
1337
1339
|
return (o || l || s) && n.push(s + "m"), t ? n.length || n.push("0m") : (e -= s * 60, n.push(e + "s")), n.join(" ");
|
|
1338
1340
|
}
|
|
1339
|
-
const
|
|
1340
|
-
mounted:
|
|
1341
|
-
updated:
|
|
1342
|
-
unmounted:
|
|
1343
|
-
},
|
|
1344
|
-
function vt(e, t) {
|
|
1345
|
-
U.size === 0 && window.addEventListener("keydown", pt), U.set(t.value.toLowerCase(), [...U.get(t.value.toLowerCase()) ?? [], e]);
|
|
1346
|
-
}
|
|
1341
|
+
const Fo = {
|
|
1342
|
+
mounted: mt,
|
|
1343
|
+
updated: Io,
|
|
1344
|
+
unmounted: pt
|
|
1345
|
+
}, j = /* @__PURE__ */ new Map();
|
|
1347
1346
|
function mt(e, t) {
|
|
1348
|
-
|
|
1347
|
+
j.size === 0 && window.addEventListener("keydown", ht), j.set(t.value.toLowerCase(), [...j.get(t.value.toLowerCase()) ?? [], e]);
|
|
1348
|
+
}
|
|
1349
|
+
function pt(e, t) {
|
|
1350
|
+
const n = j.get(t.value.toLowerCase());
|
|
1349
1351
|
if (n) {
|
|
1350
1352
|
const o = n.indexOf(e);
|
|
1351
|
-
o !== -1 && n.splice(o, 1), n.length === 0 &&
|
|
1353
|
+
o !== -1 && n.splice(o, 1), n.length === 0 && j.delete(t.value.toLowerCase());
|
|
1352
1354
|
}
|
|
1353
|
-
|
|
1355
|
+
j.size === 0 && window.removeEventListener("keydown", ht);
|
|
1354
1356
|
}
|
|
1355
|
-
function
|
|
1356
|
-
|
|
1357
|
+
function Io(e, t) {
|
|
1358
|
+
pt(e, t), mt(e, t);
|
|
1357
1359
|
}
|
|
1358
|
-
function
|
|
1360
|
+
function ht(e) {
|
|
1359
1361
|
if (typeof e.key != "string") return;
|
|
1360
|
-
const t = e.key.toLowerCase(), n =
|
|
1362
|
+
const t = e.key.toLowerCase(), n = j.get(t);
|
|
1361
1363
|
if (n) {
|
|
1362
|
-
const o =
|
|
1364
|
+
const o = Jt(n);
|
|
1363
1365
|
o == null || o.click(), e.preventDefault();
|
|
1364
1366
|
}
|
|
1365
1367
|
}
|
|
1366
|
-
const Y = Symbol("InfiniteScrollHandler"),
|
|
1368
|
+
const Y = Symbol("InfiniteScrollHandler"), Oo = {
|
|
1367
1369
|
mounted(e, t) {
|
|
1368
1370
|
e[Y] = new G(e, t.value);
|
|
1369
1371
|
},
|
|
@@ -1375,19 +1377,19 @@ const Y = Symbol("InfiniteScrollHandler"), Io = {
|
|
|
1375
1377
|
var t;
|
|
1376
1378
|
(t = e[Y]) == null || t.uninstall(), delete e[Y];
|
|
1377
1379
|
}
|
|
1378
|
-
},
|
|
1379
|
-
beforeMount:
|
|
1380
|
-
updated:
|
|
1380
|
+
}, Do = {
|
|
1381
|
+
beforeMount: Je,
|
|
1382
|
+
updated: Je
|
|
1381
1383
|
};
|
|
1382
|
-
function
|
|
1384
|
+
function Je(e, t) {
|
|
1383
1385
|
e.tagName == "LABEL" && (e = e.querySelector("input")), t.value ? e.setAttribute("readonly", "readonly") : e.removeAttribute("readonly");
|
|
1384
1386
|
}
|
|
1385
|
-
const
|
|
1386
|
-
mounted:
|
|
1387
|
-
updated:
|
|
1388
|
-
unmounted:
|
|
1387
|
+
const Ho = {
|
|
1388
|
+
mounted: Qe,
|
|
1389
|
+
updated: Qe,
|
|
1390
|
+
unmounted: yt
|
|
1389
1391
|
}, J = Symbol("TooltipState");
|
|
1390
|
-
function
|
|
1392
|
+
function Qe(e, t) {
|
|
1391
1393
|
var o;
|
|
1392
1394
|
let n = ((o = e.attributes.getNamedItem("tip")) == null ? void 0 : o.value) ?? t.value;
|
|
1393
1395
|
if (t.value || (n = null), n) {
|
|
@@ -1395,15 +1397,15 @@ function Je(e, t) {
|
|
|
1395
1397
|
content: n,
|
|
1396
1398
|
html: e.getAttribute("html") !== null
|
|
1397
1399
|
};
|
|
1398
|
-
e[J] ? e[J].configure(l) : e[J] = new
|
|
1400
|
+
e[J] ? e[J].configure(l) : e[J] = new Vo(e, l);
|
|
1399
1401
|
} else
|
|
1400
|
-
|
|
1402
|
+
yt(e);
|
|
1401
1403
|
}
|
|
1402
|
-
function
|
|
1404
|
+
function yt(e) {
|
|
1403
1405
|
var t;
|
|
1404
1406
|
(t = e[J]) == null || t.destroy(), delete e[J];
|
|
1405
1407
|
}
|
|
1406
|
-
class
|
|
1408
|
+
class Vo {
|
|
1407
1409
|
constructor(t, n) {
|
|
1408
1410
|
D(this, "lastMoveEvt");
|
|
1409
1411
|
D(this, "checkInterval");
|
|
@@ -1451,61 +1453,62 @@ class Ho {
|
|
|
1451
1453
|
this.shouldShow = !1, this.removeTooltip(), this.el.removeEventListener("mouseenter", this.handleTargetMouseEnterWithContext), this.el.removeEventListener("mouseleave", this.handleTargetMouseLeaveWithContext), this.el.removeEventListener("click", this.handleTargetMouseLeaveWithContext);
|
|
1452
1454
|
}
|
|
1453
1455
|
}
|
|
1454
|
-
function
|
|
1455
|
-
e.directive("autofocus",
|
|
1456
|
+
function Ao(e) {
|
|
1457
|
+
e.directive("autofocus", yo), e.directive("confirm-button", go), e.directive("date-input", Eo), e.directive("datetime", ko), e.directive("disabled", Co), e.directive("duration", Mo), e.directive("hotkey", Fo), e.directive("infinite-scroll", Oo), e.directive("readonly", Do), e.directive("tooltip", Ho);
|
|
1456
1458
|
}
|
|
1457
|
-
function
|
|
1458
|
-
|
|
1459
|
+
function vs(e) {
|
|
1460
|
+
Ao(e);
|
|
1459
1461
|
}
|
|
1460
1462
|
export {
|
|
1461
1463
|
jo as OverlayContainer,
|
|
1462
1464
|
ae as UserError,
|
|
1463
|
-
|
|
1465
|
+
Uo as VfAjaxSelect,
|
|
1464
1466
|
ue as VfAlertModal,
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1467
|
+
rs as VfEzSmartSelect,
|
|
1468
|
+
bn as VfModal,
|
|
1469
|
+
Kn as VfSmartSelect,
|
|
1470
|
+
ns as cloneProp,
|
|
1471
|
+
Yo as configureVf,
|
|
1472
|
+
ss as configureVfOpenApiClient,
|
|
1473
|
+
cs as createFilters,
|
|
1472
1474
|
be as createOverlayInjection,
|
|
1473
|
-
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
pn as
|
|
1490
|
-
|
|
1491
|
-
|
|
1475
|
+
$n as desnakeCase,
|
|
1476
|
+
dn as dismissOverlayInjectionById,
|
|
1477
|
+
Po as dismissOverlayInjectionByInstance,
|
|
1478
|
+
it as dismissOverlayInjectionByInternalInstance,
|
|
1479
|
+
cn as dismissOverlayInjectionByVnode,
|
|
1480
|
+
hs as escapeHtml,
|
|
1481
|
+
vn as formatError,
|
|
1482
|
+
Sn as formatNumber,
|
|
1483
|
+
Bn as formatPhone,
|
|
1484
|
+
_n as formatUSCurrency,
|
|
1485
|
+
Zo as handleError,
|
|
1486
|
+
Xo as handleErrorAndAlert,
|
|
1487
|
+
vs as installVf,
|
|
1488
|
+
mn as isError,
|
|
1489
|
+
je as isNotNullOrUndefined,
|
|
1490
|
+
Go as maskComponent,
|
|
1491
|
+
pn as maskEl,
|
|
1492
|
+
hn as maskForm,
|
|
1493
|
+
is as nl2br,
|
|
1494
|
+
os as nullifyEmptyInputs,
|
|
1492
1495
|
ke as presentOverlay,
|
|
1493
1496
|
le as removeOverlayInjection,
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1497
|
+
Qo as replaceElement,
|
|
1498
|
+
fn as showAlert,
|
|
1499
|
+
qo as showConfirm,
|
|
1500
|
+
zo as showConfirmDestroy,
|
|
1501
|
+
es as showContextMenu,
|
|
1502
|
+
us as showToast,
|
|
1503
|
+
Ko as showWait,
|
|
1504
|
+
Cn as sleep,
|
|
1505
|
+
ts as sleepSecs,
|
|
1503
1506
|
Te as toError,
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1507
|
+
Jo as unmaskComponent,
|
|
1508
|
+
lt as unmaskEl,
|
|
1509
|
+
rt as unmaskForm,
|
|
1510
|
+
ds as useInfiniteScroll,
|
|
1511
|
+
fs as useResizeWatcher,
|
|
1512
|
+
ls as uuid,
|
|
1513
|
+
as as vfModalRef
|
|
1511
1514
|
};
|