@citruslime/ui 2.6.15-beta.1 → 2.6.16-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Icon as H } from "@iconify/vue";
|
|
2
|
-
import { defineComponent as K, ref as V, openBlock as p, createElementBlock as T, renderSlot as
|
|
2
|
+
import { defineComponent as K, ref as V, openBlock as p, createElementBlock as T, renderSlot as x, normalizeProps as de, guardReactiveProps as ve, Fragment as J, createElementVNode as b, normalizeClass as U, createVNode as E, unref as h, Transition as $e, withCtx as Q, withDirectives as ee, mergeProps as ue, vShow as te, createBlock as Z, Teleport as ol, renderList as se, toDisplayString as I, createCommentVNode as P, nextTick as Le, computed as F, toHandlers as Ul, withModifiers as oe, getCurrentInstance as xl, version as _l, watch as ae, useCssVars as Hl, vModelText as Gl, onMounted as Qe, vModelDynamic as Zl, toRefs as Kl, withKeys as Ae, onUnmounted as rl, resolveComponent as Cl, createTextVNode as pe, inject as Wl, watchEffect as Ql, createSlots as il, provide as Yl, normalizeStyle as Jl } from "vue";
|
|
3
3
|
import { generateStringId as Xl, highlightText as et } from "@citruslime/utils";
|
|
4
4
|
import { useMediaQuery as lt, useDebounceFn as sl, unrefElement as tt, tryOnScopeDispose as at, onClickOutside as cl, useTimeoutFn as Ol, useWindowSize as nt } from "@vueuse/core";
|
|
5
5
|
import { createI18n as ot, useI18n as ce } from "vue-i18n";
|
|
@@ -27,7 +27,7 @@ const rt = { class: "cl-overflow-hidden" }, it = /* @__PURE__ */ K({
|
|
|
27
27
|
}), o.open = !o.open);
|
|
28
28
|
}
|
|
29
29
|
return (s, o) => (p(), T("div", rt, [
|
|
30
|
-
|
|
30
|
+
x(s.$slots, "default", de(ve({ isItemOpen: t, toggleItem: n })))
|
|
31
31
|
]));
|
|
32
32
|
}
|
|
33
33
|
}), st = { class: "cl-absolute cl-left-5 cl-top-5" }, ct = { class: "cl-font-semibold cl-ml-10 cl-p-4 cl-select-none cl-text-grey-5" }, ut = { class: "cl-overflow-hidden" }, dt = /* @__PURE__ */ K({
|
|
@@ -47,7 +47,7 @@ const rt = { class: "cl-overflow-hidden" }, it = /* @__PURE__ */ K({
|
|
|
47
47
|
}
|
|
48
48
|
return (n, s) => (p(), T(J, null, [
|
|
49
49
|
b("div", {
|
|
50
|
-
class:
|
|
50
|
+
class: U(["cl-border-b cl-border-grey-1 cl-relative", {
|
|
51
51
|
"cl-bg-grey-0": n.disabled,
|
|
52
52
|
"cl-cursor-pointer": !n.disabled
|
|
53
53
|
}]),
|
|
@@ -55,7 +55,7 @@ const rt = { class: "cl-overflow-hidden" }, it = /* @__PURE__ */ K({
|
|
|
55
55
|
}, [
|
|
56
56
|
b("div", st, [
|
|
57
57
|
E(h(H), {
|
|
58
|
-
class:
|
|
58
|
+
class: U(["cl-duration-300 cl-ease-in-out cl-text-grey-3 cl-transform-gpu cl-transition-transform", {
|
|
59
59
|
"cl-rotate-180": n.open
|
|
60
60
|
}]),
|
|
61
61
|
icon: "ph:caret-down-bold",
|
|
@@ -63,14 +63,14 @@ const rt = { class: "cl-overflow-hidden" }, it = /* @__PURE__ */ K({
|
|
|
63
63
|
}, null, 8, ["class"])
|
|
64
64
|
]),
|
|
65
65
|
b("div", ct, [
|
|
66
|
-
|
|
66
|
+
x(n.$slots, "title")
|
|
67
67
|
])
|
|
68
68
|
], 2),
|
|
69
69
|
b("div", ut, [
|
|
70
70
|
E($e, { name: "grow-down" }, {
|
|
71
71
|
default: Q(() => [
|
|
72
72
|
ee(b("div", ue(n.$attrs, { class: "cl-ml-10 cl-p-4" }), [
|
|
73
|
-
|
|
73
|
+
x(n.$slots, "default")
|
|
74
74
|
], 16), [
|
|
75
75
|
[te, n.open]
|
|
76
76
|
])
|
|
@@ -88,7 +88,7 @@ const rt = { class: "cl-overflow-hidden" }, it = /* @__PURE__ */ K({
|
|
|
88
88
|
}, ft = {}, pt = { class: "cl-border-b cl-border-grey-1 cl-font-semibold cl-pl-14 cl-pr-4 cl-py-2 cl-text-grey-3 cl-text-sm" };
|
|
89
89
|
function mt(a, e) {
|
|
90
90
|
return p(), T("div", pt, [
|
|
91
|
-
|
|
91
|
+
x(a.$slots, "default")
|
|
92
92
|
]);
|
|
93
93
|
}
|
|
94
94
|
const vt = /* @__PURE__ */ Te(ft, [["render", mt]]), xe = V([]);
|
|
@@ -112,7 +112,7 @@ const ht = ["onClick"], gt = { class: "cl-flex-1 cl-select-none cl-text-ellipsis
|
|
|
112
112
|
setup(a) {
|
|
113
113
|
return (e, l) => (p(), Z(ol, { to: e.container }, [
|
|
114
114
|
b("div", {
|
|
115
|
-
class:
|
|
115
|
+
class: U(["cl-fixed cl-w-80 cl-z-50", {
|
|
116
116
|
"cl-top-5 cl-left-5": e.position === "top-left",
|
|
117
117
|
"cl-top-5 cl-left-1/2": e.position === "top-centre",
|
|
118
118
|
"cl-top-5 cl-right-5": e.position === "top-right",
|
|
@@ -132,7 +132,7 @@ const ht = ["onClick"], gt = { class: "cl-flex-1 cl-select-none cl-text-ellipsis
|
|
|
132
132
|
}],
|
|
133
133
|
onClick: (s) => h(El)(t)
|
|
134
134
|
}), [
|
|
135
|
-
b("span", gt,
|
|
135
|
+
b("span", gt, I(t.message), 1),
|
|
136
136
|
E(h(H), {
|
|
137
137
|
class: "cl-inline-block cl-opacity-0 cl-transition-opacity group-hover:cl-opacity-100",
|
|
138
138
|
icon: "ph:x",
|
|
@@ -151,26 +151,26 @@ const ht = ["onClick"], gt = { class: "cl-flex-1 cl-select-none cl-text-ellipsis
|
|
|
151
151
|
setup(a) {
|
|
152
152
|
return (e, l) => (p(), T(J, null, [
|
|
153
153
|
E(Nl, {
|
|
154
|
-
class:
|
|
154
|
+
class: U({
|
|
155
155
|
"first:cl-mt-[4.25rem]": e.$slots.header
|
|
156
156
|
})
|
|
157
157
|
}, null, 8, ["class"]),
|
|
158
158
|
b("div", bt, [
|
|
159
|
-
|
|
159
|
+
x(e.$slots, "header"),
|
|
160
160
|
b("div", {
|
|
161
|
-
class:
|
|
161
|
+
class: U(["cl-content-start cl-flex cl-flex-nowrap cl-h-dscreen cl-items-stretch cl-max-h-full cl-relative cl-w-full xl:cl-max-h-screen", {
|
|
162
162
|
"cl-pt-20": e.$slots.header
|
|
163
163
|
}])
|
|
164
164
|
}, [
|
|
165
|
-
|
|
165
|
+
x(e.$slots, "navigation"),
|
|
166
166
|
b("div", {
|
|
167
167
|
id: "cl-ui-app-container",
|
|
168
|
-
class:
|
|
168
|
+
class: U(["cl-grow cl-max-h-full cl-overflow-x-hidden cl-overflow-y-auto cl-overscroll-y-none cl-w-auto", {
|
|
169
169
|
"lg:cl-pb-0": e.removePadding,
|
|
170
170
|
"lg:cl-pb-8 md:cl-px-8 cl-px-2 md:cl-pt-8 cl-pt-2": !e.removePadding
|
|
171
171
|
}])
|
|
172
172
|
}, [
|
|
173
|
-
|
|
173
|
+
x(e.$slots, "default")
|
|
174
174
|
], 2)
|
|
175
175
|
], 2)
|
|
176
176
|
])
|
|
@@ -217,7 +217,7 @@ const Ye = /* @__PURE__ */ Te(wt, [["render", Tt], ["__scopeId", "data-v-a21dc5d
|
|
|
217
217
|
}],
|
|
218
218
|
disabled: t.disabled
|
|
219
219
|
}), [
|
|
220
|
-
|
|
220
|
+
x(t.$slots, "default")
|
|
221
221
|
], 16, $t), [
|
|
222
222
|
[te, !t.loading]
|
|
223
223
|
])
|
|
@@ -242,44 +242,44 @@ const Ye = /* @__PURE__ */ Te(wt, [["render", Tt], ["__scopeId", "data-v-a21dc5d
|
|
|
242
242
|
},
|
|
243
243
|
setup(a) {
|
|
244
244
|
return (e, l) => (p(), T("div", {
|
|
245
|
-
class:
|
|
245
|
+
class: U(["cl-border cl-border-transparent cl-overflow-hidden cl-relative cl-rounded-md cl-shadow-lg cl-transition-all", {
|
|
246
246
|
"cl-cursor-pointer hover:cl-shadow-xl hover:cl-border-grey-0": e.hover
|
|
247
247
|
}])
|
|
248
248
|
}, [
|
|
249
249
|
e.$slots.image ? (p(), T("div", Ot, [
|
|
250
|
-
|
|
251
|
-
])) :
|
|
250
|
+
x(e.$slots, "image")
|
|
251
|
+
])) : P("", !0),
|
|
252
252
|
e.$slots.title ? (p(), T("div", {
|
|
253
253
|
key: 1,
|
|
254
|
-
class:
|
|
254
|
+
class: U(["cl-border-grey-2 cl-font-normal", {
|
|
255
255
|
"cl-p-2 cl-text-2xl cl-leading-8": e.size === "small",
|
|
256
256
|
"cl-p-4 cl-text-3xl cl-leading-9": e.size === "medium",
|
|
257
257
|
"cl-p-6 cl-text-4xl cl-leading-10": e.size === "large",
|
|
258
258
|
"cl-border-t": e.$slots.image
|
|
259
259
|
}])
|
|
260
260
|
}, [
|
|
261
|
-
|
|
262
|
-
], 2)) :
|
|
261
|
+
x(e.$slots, "title")
|
|
262
|
+
], 2)) : P("", !0),
|
|
263
263
|
b("div", {
|
|
264
|
-
class:
|
|
264
|
+
class: U(["cl-border-grey-2", {
|
|
265
265
|
"cl-p-2": e.size === "small",
|
|
266
266
|
"cl-p-4": e.size === "medium",
|
|
267
267
|
"cl-p-6": e.size === "large",
|
|
268
268
|
"cl-border-t": e.$slots.image || e.$slots.title
|
|
269
269
|
}])
|
|
270
270
|
}, [
|
|
271
|
-
|
|
271
|
+
x(e.$slots, "default")
|
|
272
272
|
], 2),
|
|
273
273
|
e.$slots.footer ? (p(), T("div", {
|
|
274
274
|
key: 2,
|
|
275
|
-
class:
|
|
275
|
+
class: U(["cl-border-grey-2 cl-border-t", {
|
|
276
276
|
"cl-p-2": e.size === "small",
|
|
277
277
|
"cl-p-4": e.size === "medium",
|
|
278
278
|
"cl-p-6": e.size === "large"
|
|
279
279
|
}])
|
|
280
280
|
}, [
|
|
281
|
-
|
|
282
|
-
], 2)) :
|
|
281
|
+
x(e.$slots, "footer")
|
|
282
|
+
], 2)) : P("", !0)
|
|
283
283
|
], 2));
|
|
284
284
|
}
|
|
285
285
|
}), Nt = [
|
|
@@ -617,7 +617,7 @@ const Mt = {
|
|
|
617
617
|
var r;
|
|
618
618
|
(r = t.value) == null || r.focus();
|
|
619
619
|
}
|
|
620
|
-
const { t: s } = ce(), o =
|
|
620
|
+
const { t: s } = ce(), o = F(() => {
|
|
621
621
|
let r = "";
|
|
622
622
|
switch (l.type) {
|
|
623
623
|
case "date":
|
|
@@ -636,7 +636,7 @@ const Mt = {
|
|
|
636
636
|
focus: n
|
|
637
637
|
}), (r, i) => r.type === "dateRange" ? (p(), T("div", Mt, [
|
|
638
638
|
E(be, {
|
|
639
|
-
class:
|
|
639
|
+
class: U(["cl-basis-full cl-border-transparent cl-col-span-4 cl-flex cl-items-center cl-justify-center hover:cl-border-transparent", {
|
|
640
640
|
"cl-text-grey-4 hover:cl-text-grey-3": !r.rangeSelected,
|
|
641
641
|
"cl-text-primary-darker hover:cl-text-primary-dark": r.rangeSelected
|
|
642
642
|
}]),
|
|
@@ -651,10 +651,10 @@ const Mt = {
|
|
|
651
651
|
]),
|
|
652
652
|
_: 1
|
|
653
653
|
}, 8, ["disabled", "class"]),
|
|
654
|
-
r.required ?
|
|
654
|
+
r.required ? P("", !0) : (p(), Z(be, {
|
|
655
655
|
key: 0,
|
|
656
656
|
size: "small",
|
|
657
|
-
class:
|
|
657
|
+
class: U(["cl-basis-0 cl-border-transparent cl-flex cl-items-center cl-justify-center hover:cl-border-transparent", {
|
|
658
658
|
"cl-text-grey-4 hover:cl-text-grey-3": !r.rangeSelected,
|
|
659
659
|
"cl-text-danger-dark hover:cl-text-danger-default": r.rangeSelected
|
|
660
660
|
}]),
|
|
@@ -680,7 +680,7 @@ const Mt = {
|
|
|
680
680
|
placeholder: o.value
|
|
681
681
|
}, Ul(r.events, !0)), null, 16, jt),
|
|
682
682
|
ee(E(h(H), {
|
|
683
|
-
class:
|
|
683
|
+
class: U(["cl-absolute cl-bg-transparent cl-cursor-text cl-left-2 cl-text-grey-4 cl-top-3.5 icon", {
|
|
684
684
|
"!cl-bg-off-white": r.disabled
|
|
685
685
|
}]),
|
|
686
686
|
icon: r.type === "time" ? "ph-clock" : "ph:calendar",
|
|
@@ -688,19 +688,19 @@ const Mt = {
|
|
|
688
688
|
}, null, 8, ["class", "icon"]), [
|
|
689
689
|
[te, !r.disabled]
|
|
690
690
|
]),
|
|
691
|
-
r.disabled ?
|
|
691
|
+
r.disabled ? P("", !0) : (p(), T("div", Pt, [
|
|
692
692
|
r.type !== "time" ? (p(), Z(h(H), {
|
|
693
693
|
key: 0,
|
|
694
694
|
class: "cl-cursor-pointer hover:cl-text-link-light",
|
|
695
695
|
icon: "ph:arrow-counter-clockwise",
|
|
696
696
|
onClick: i[2] || (i[2] = oe((c) => r.$emit("reset"), ["prevent"]))
|
|
697
|
-
})) :
|
|
697
|
+
})) : P("", !0),
|
|
698
698
|
!r.required && r.date && (r.type !== "time" || r.date !== "00:00") ? (p(), Z(h(H), {
|
|
699
699
|
key: 1,
|
|
700
700
|
class: "cl-cursor-pointer clear-icon hover:cl-text-link-light md:cl-ml-0.5",
|
|
701
701
|
icon: "ph:x",
|
|
702
702
|
onClick: i[3] || (i[3] = oe((c) => r.$emit("clear"), ["prevent"]))
|
|
703
|
-
})) :
|
|
703
|
+
})) : P("", !0)
|
|
704
704
|
]))
|
|
705
705
|
]));
|
|
706
706
|
}
|
|
@@ -719,13 +719,13 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
719
719
|
var r, i;
|
|
720
720
|
return p(), T("button", {
|
|
721
721
|
key: o,
|
|
722
|
-
class:
|
|
722
|
+
class: U(["cl-border cl-cursor-pointer cl-py-1 cl-rounded-md cl-text-center", {
|
|
723
723
|
"cl-bg-primary-lighter cl-bg-opacity-30 cl-border-primary-default cl-font-bold hover:cl-border-primary-darker": ((r = t.selectedQuickDate) == null ? void 0 : r.name) === s.name,
|
|
724
724
|
"cl-border-grey-2 hover:cl-border-grey-3 hover:cl-opacity-95 cl-opacity-60": ((i = t.selectedQuickDate) == null ? void 0 : i.name) !== s.name
|
|
725
725
|
}]),
|
|
726
726
|
onClick: (c) => e("quick-date-selected", s)
|
|
727
727
|
}, [
|
|
728
|
-
b("span", null,
|
|
728
|
+
b("span", null, I(h(l)(s.translationKey)), 1)
|
|
729
729
|
], 10, Ut);
|
|
730
730
|
}), 128))
|
|
731
731
|
]));
|
|
@@ -834,7 +834,7 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
834
834
|
},
|
|
835
835
|
emits: ["quick-date-selected", "apply-button-clicked"],
|
|
836
836
|
setup(a, { emit: e }) {
|
|
837
|
-
const l = a, { t } = ce(), n =
|
|
837
|
+
const l = a, { t } = ce(), n = F(() => {
|
|
838
838
|
const s = [];
|
|
839
839
|
switch (l.scope) {
|
|
840
840
|
case "past":
|
|
@@ -859,7 +859,7 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
859
859
|
return s;
|
|
860
860
|
});
|
|
861
861
|
return (s, o) => (p(), T("div", Ht, [
|
|
862
|
-
b("div", null,
|
|
862
|
+
b("div", null, I(h(t)("quickDates.quickDatesHeader")), 1),
|
|
863
863
|
(p(!0), T(J, null, se(n.value, (r, i) => (p(), T("div", {
|
|
864
864
|
key: i,
|
|
865
865
|
class: "cl-pt-2"
|
|
@@ -869,7 +869,7 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
869
869
|
"selected-quick-date": s.selectedQuickDate,
|
|
870
870
|
onQuickDateSelected: o[0] || (o[0] = (c) => e("quick-date-selected", c))
|
|
871
871
|
}, null, 8, ["dates", "selected-quick-date"]),
|
|
872
|
-
i < n.value.length - 1 ? (p(), T("div", Gt)) :
|
|
872
|
+
i < n.value.length - 1 ? (p(), T("div", Gt)) : P("", !0)
|
|
873
873
|
]))), 128))
|
|
874
874
|
]));
|
|
875
875
|
}
|
|
@@ -891,7 +891,7 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
891
891
|
},
|
|
892
892
|
emits: ["update:date"],
|
|
893
893
|
setup(a, { expose: e, emit: l }) {
|
|
894
|
-
const t = a, n =
|
|
894
|
+
const t = a, n = F(() => t.timeZone ?? "UTC"), s = F({
|
|
895
895
|
get() {
|
|
896
896
|
let u = null;
|
|
897
897
|
return t.type === "time" ? u = t.date === null ? "00:00" : t.date : t.date !== null && typeof t.date == "string" ? u = G.fromISO(t.date, {
|
|
@@ -922,12 +922,12 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
922
922
|
}
|
|
923
923
|
});
|
|
924
924
|
function o(u, m, k) {
|
|
925
|
-
let
|
|
926
|
-
m && (
|
|
927
|
-
let
|
|
928
|
-
return t.timeZone === null && (
|
|
925
|
+
let M = G.fromJSDate(u, { zone: n.value }).setZone(n.value);
|
|
926
|
+
m && (M = M.startOf("day"));
|
|
927
|
+
let L = M.toISO({ includeOffset: k });
|
|
928
|
+
return t.timeZone === null && (L = (L == null ? void 0 : L.replace("Z", "")) ?? null), L;
|
|
929
929
|
}
|
|
930
|
-
const { locale: r } = ce(), i =
|
|
930
|
+
const { locale: r } = ce(), i = F(() => t.dateFormatLocale ?? r.value), c = F(() => t.disabled ? !1 : {
|
|
931
931
|
visibility: "focus",
|
|
932
932
|
showDelay: 0,
|
|
933
933
|
hideDelay: 250,
|
|
@@ -958,7 +958,7 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
958
958
|
let m = u.set({ second: 0, millisecond: 0 }).setZone(n.value);
|
|
959
959
|
return t.type === "date" && (m = m.set({ hour: 0, minute: 0 }).setZone(n.value)), m;
|
|
960
960
|
}
|
|
961
|
-
const d =
|
|
961
|
+
const d = F(() => {
|
|
962
962
|
const u = G.fromObject({
|
|
963
963
|
day: 3,
|
|
964
964
|
month: 4,
|
|
@@ -968,7 +968,7 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
968
968
|
}).setLocale(i.value);
|
|
969
969
|
let m;
|
|
970
970
|
return t.type === "date" ? m = u.toFormat("D") : t.type === "datetime" ? m = u.toFormat("f") : m = u.toFormat("t"), i.value === "en-US" ? m = m.replace("05", "hh").replace("5", "h") : m = m.replace("05", "HH").replace("5", "H"), m.replace("2000", "YYYY").replace("20", "YY").replace("04", "MM").replace("4", "M").replace("03", "DD").replace("3", "D").replace("06", "mm").replace("6", "m").replace("AM", "A").trim();
|
|
971
|
-
}), w = V(null), O =
|
|
971
|
+
}), w = V(null), O = F(() => {
|
|
972
972
|
let u;
|
|
973
973
|
if (t.date && t.type !== "dateRange")
|
|
974
974
|
u = G.fromISO(t.date, {
|
|
@@ -991,27 +991,27 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
991
991
|
(u = w.value) == null || u.focus();
|
|
992
992
|
}
|
|
993
993
|
});
|
|
994
|
-
const
|
|
995
|
-
function
|
|
996
|
-
const m =
|
|
997
|
-
s.value = m,
|
|
994
|
+
const D = V(null), N = V();
|
|
995
|
+
function z(u) {
|
|
996
|
+
const m = q(u);
|
|
997
|
+
s.value = m, D.value = u, N.value.move(m.start), N.value.hidePopover();
|
|
998
998
|
}
|
|
999
|
-
function
|
|
1000
|
-
const m = u.range, k = u.scope === "past" ? -1 : u.scope === "current" ? 0 : 1,
|
|
999
|
+
function q(u) {
|
|
1000
|
+
const m = u.range, k = u.scope === "past" ? -1 : u.scope === "current" ? 0 : 1, M = G.now().setZone(n.value).startOf(m).plus({ days: m === "day" ? k : 0, weeks: m === "week" ? k : 0, months: m === "month" ? k : 0, years: m === "year" ? k : 0 }), L = M.endOf(m);
|
|
1001
1001
|
return {
|
|
1002
|
-
start:
|
|
1003
|
-
end:
|
|
1002
|
+
start: M.toJSDate(),
|
|
1003
|
+
end: L.toJSDate()
|
|
1004
1004
|
};
|
|
1005
1005
|
}
|
|
1006
|
-
const le =
|
|
1006
|
+
const le = F(() => {
|
|
1007
1007
|
let u = "";
|
|
1008
1008
|
const m = s.value;
|
|
1009
1009
|
if (m !== null && Object.hasOwn(m, "start") && Object.hasOwn(m, "end")) {
|
|
1010
|
-
const k = G.fromJSDate(m.start).setZone(n.value).setLocale(i.value).toLocaleString(G.DATETIME_SHORT),
|
|
1011
|
-
u = `${k} - ${
|
|
1010
|
+
const k = G.fromJSDate(m.start).setZone(n.value).setLocale(i.value).toLocaleString(G.DATETIME_SHORT), M = G.fromJSDate(m.end).setZone(n.value).setLocale(i.value).toLocaleString(G.DATETIME_SHORT);
|
|
1011
|
+
u = `${k} - ${M}`;
|
|
1012
1012
|
}
|
|
1013
1013
|
return u;
|
|
1014
|
-
}), re = lt("(min-width: 768px)"), g =
|
|
1014
|
+
}), re = lt("(min-width: 768px)"), g = F(() => re.value ? 2 : 1);
|
|
1015
1015
|
return (u, m) => u.type === "time" ? (p(), Z(h(Je), {
|
|
1016
1016
|
key: 0,
|
|
1017
1017
|
modelValue: s.value,
|
|
@@ -1028,24 +1028,24 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
1028
1028
|
"hide-time-header": "",
|
|
1029
1029
|
popover: c.value
|
|
1030
1030
|
}, {
|
|
1031
|
-
default: Q(({ inputValue: k, inputEvents:
|
|
1031
|
+
default: Q(({ inputValue: k, inputEvents: M }) => [
|
|
1032
1032
|
E(Xe, ue(u.$attrs, {
|
|
1033
1033
|
ref_key: "input",
|
|
1034
1034
|
ref: w,
|
|
1035
1035
|
date: k,
|
|
1036
|
-
events:
|
|
1036
|
+
events: M,
|
|
1037
1037
|
type: u.type,
|
|
1038
1038
|
placeholder: u.placeholder,
|
|
1039
1039
|
required: u.required,
|
|
1040
1040
|
disabled: u.disabled,
|
|
1041
|
-
onClear: m[0] || (m[0] = (
|
|
1041
|
+
onClear: m[0] || (m[0] = (L) => s.value = null)
|
|
1042
1042
|
}), null, 16, ["date", "events", "type", "placeholder", "required", "disabled"])
|
|
1043
1043
|
]),
|
|
1044
1044
|
_: 1
|
|
1045
1045
|
}, 8, ["modelValue", "locale", "is24hr", "mode", "is-required", "masks", "popover"])) : u.type === "dateRange" ? (p(), Z(h(Je), {
|
|
1046
1046
|
key: 1,
|
|
1047
1047
|
ref_key: "calendar",
|
|
1048
|
-
ref:
|
|
1048
|
+
ref: N,
|
|
1049
1049
|
modelValue: s.value,
|
|
1050
1050
|
"onUpdate:modelValue": m[3] || (m[3] = (k) => s.value = k),
|
|
1051
1051
|
modelModifiers: { range: !0 },
|
|
@@ -1060,7 +1060,7 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
1060
1060
|
"min-date": u.min,
|
|
1061
1061
|
"max-date": u.max,
|
|
1062
1062
|
"initial-page": O.value,
|
|
1063
|
-
onDayclick: m[4] || (m[4] = (k) =>
|
|
1063
|
+
onDayclick: m[4] || (m[4] = (k) => D.value = null)
|
|
1064
1064
|
}, {
|
|
1065
1065
|
default: Q(({ togglePopover: k }) => [
|
|
1066
1066
|
E(Xe, ue(u.$attrs, {
|
|
@@ -1073,8 +1073,8 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
1073
1073
|
title: le.value,
|
|
1074
1074
|
placeholder: null,
|
|
1075
1075
|
onTogglePopover: k,
|
|
1076
|
-
onClear: m[2] || (m[2] = (
|
|
1077
|
-
s.value = null,
|
|
1076
|
+
onClear: m[2] || (m[2] = (M) => {
|
|
1077
|
+
s.value = null, D.value = null, N.value.hidePopover();
|
|
1078
1078
|
})
|
|
1079
1079
|
}), null, 16, ["type", "required", "disabled", "range-selected", "title", "onTogglePopover"])
|
|
1080
1080
|
]),
|
|
@@ -1082,10 +1082,10 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
1082
1082
|
u.quickDateScope !== "none" ? (p(), Z(Zt, {
|
|
1083
1083
|
key: 0,
|
|
1084
1084
|
scope: u.quickDateScope,
|
|
1085
|
-
"selected-quick-date":
|
|
1085
|
+
"selected-quick-date": D.value,
|
|
1086
1086
|
"current-date-range": t.date,
|
|
1087
|
-
onQuickDateSelected:
|
|
1088
|
-
}, null, 8, ["scope", "selected-quick-date", "current-date-range"])) :
|
|
1087
|
+
onQuickDateSelected: z
|
|
1088
|
+
}, null, 8, ["scope", "selected-quick-date", "current-date-range"])) : P("", !0)
|
|
1089
1089
|
]),
|
|
1090
1090
|
_: 1
|
|
1091
1091
|
}, 8, ["modelValue", "locale", "is24hr", "timezone", "columns", "popover", "min-date", "max-date", "initial-page"])) : (p(), Z(h(Je), {
|
|
@@ -1107,17 +1107,17 @@ const Xe = /* @__PURE__ */ Te(zt, [["__scopeId", "data-v-14711049"]]), Bt = { cl
|
|
|
1107
1107
|
"hide-time-header": "",
|
|
1108
1108
|
popover: c.value
|
|
1109
1109
|
}, {
|
|
1110
|
-
default: Q(({ inputValue: k, inputEvents:
|
|
1110
|
+
default: Q(({ inputValue: k, inputEvents: M }) => [
|
|
1111
1111
|
E(Xe, ue(u.$attrs, {
|
|
1112
1112
|
ref_key: "input",
|
|
1113
1113
|
ref: w,
|
|
1114
1114
|
date: k,
|
|
1115
|
-
events:
|
|
1115
|
+
events: M,
|
|
1116
1116
|
type: u.type,
|
|
1117
1117
|
placeholder: u.placeholder,
|
|
1118
1118
|
required: u.required,
|
|
1119
1119
|
disabled: u.disabled,
|
|
1120
|
-
onClear: m[5] || (m[5] = (
|
|
1120
|
+
onClear: m[5] || (m[5] = (L) => s.value = null),
|
|
1121
1121
|
onReset: f
|
|
1122
1122
|
}), null, 16, ["date", "events", "type", "placeholder", "required", "disabled"])
|
|
1123
1123
|
]),
|
|
@@ -1156,10 +1156,10 @@ class Qt {
|
|
|
1156
1156
|
currencySign: d ? "accounting" : void 0,
|
|
1157
1157
|
currencyDisplay: c !== Ee.hidden ? c : void 0
|
|
1158
1158
|
};
|
|
1159
|
-
const O = new Intl.NumberFormat(f, this.options),
|
|
1160
|
-
this.currency = (l =
|
|
1161
|
-
const
|
|
1162
|
-
this.prefix =
|
|
1159
|
+
const O = new Intl.NumberFormat(f, this.options), D = O.formatToParts(123456);
|
|
1160
|
+
this.currency = (l = D.find(({ type: q }) => q === "currency")) === null || l === void 0 ? void 0 : l.value, this.digits = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9].map((q) => q.toLocaleString(f)), this.decimalSymbol = (t = D.find(({ type: q }) => q === "decimal")) === null || t === void 0 ? void 0 : t.value, this.groupingSymbol = (n = D.find(({ type: q }) => q === "group")) === null || n === void 0 ? void 0 : n.value, this.minusSign = (s = O.formatToParts(-1).find(({ type: q }) => q === "minusSign")) === null || s === void 0 ? void 0 : s.value, this.decimalSymbol === void 0 ? this.minimumFractionDigits = this.maximumFractionDigits = 0 : typeof v == "number" ? this.minimumFractionDigits = this.maximumFractionDigits = v : (this.minimumFractionDigits = (o = v == null ? void 0 : v.min) !== null && o !== void 0 ? o : O.resolvedOptions().minimumFractionDigits, this.maximumFractionDigits = (r = v == null ? void 0 : v.max) !== null && r !== void 0 ? r : O.resolvedOptions().maximumFractionDigits);
|
|
1161
|
+
const N = (q) => Wt(q, this.digits[1]), z = (q) => q.substring(q.lastIndexOf(this.decimalSymbol ? this.digits[0] : this.digits[1]) + 1);
|
|
1162
|
+
this.prefix = N(O.format(1)), this.suffix = z(O.format(1)), this.negativePrefix = N(O.format(-1)), this.negativeSuffix = z(O.format(-1));
|
|
1163
1163
|
}
|
|
1164
1164
|
parse(e) {
|
|
1165
1165
|
if (e) {
|
|
@@ -1409,29 +1409,29 @@ const la = (a) => a != null && a.matches("input") ? a : a == null ? void 0 : a.q
|
|
|
1409
1409
|
function ta(a, e) {
|
|
1410
1410
|
var l, t, n, s;
|
|
1411
1411
|
let o;
|
|
1412
|
-
const r = V(null), i = V(null), c = V(null), f = xl(), v = (f == null ? void 0 : f.emit) || ((t = (l = f == null ? void 0 : f.proxy) === null || l === void 0 ? void 0 : l.$emit) === null || t === void 0 ? void 0 : t.bind(f == null ? void 0 : f.proxy)), d = (f == null ? void 0 : f.props) || ((n = f == null ? void 0 : f.proxy) === null || n === void 0 ? void 0 : n.$props), w = _l.startsWith("3"), O = w && ((s = f == null ? void 0 : f.attrs.modelModifiers) === null || s === void 0 ? void 0 : s.lazy),
|
|
1413
|
-
return ae(r, (
|
|
1412
|
+
const r = V(null), i = V(null), c = V(null), f = xl(), v = (f == null ? void 0 : f.emit) || ((t = (l = f == null ? void 0 : f.proxy) === null || l === void 0 ? void 0 : l.$emit) === null || t === void 0 ? void 0 : t.bind(f == null ? void 0 : f.proxy)), d = (f == null ? void 0 : f.props) || ((n = f == null ? void 0 : f.proxy) === null || n === void 0 ? void 0 : n.$props), w = _l.startsWith("3"), O = w && ((s = f == null ? void 0 : f.attrs.modelModifiers) === null || s === void 0 ? void 0 : s.lazy), D = F(() => d == null ? void 0 : d[w ? "modelValue" : "value"]), N = w ? "update:modelValue" : "input", z = O ? "update:modelValue" : "change";
|
|
1413
|
+
return ae(r, (q) => {
|
|
1414
1414
|
var le;
|
|
1415
|
-
if (
|
|
1416
|
-
const re = la((le =
|
|
1415
|
+
if (q) {
|
|
1416
|
+
const re = la((le = q == null ? void 0 : q.$el) !== null && le !== void 0 ? le : q);
|
|
1417
1417
|
re ? (o = new ea({
|
|
1418
1418
|
el: re,
|
|
1419
1419
|
options: a,
|
|
1420
1420
|
onInput: (g) => {
|
|
1421
|
-
!O && e !== !1 &&
|
|
1421
|
+
!O && e !== !1 && D.value !== g.number && (v == null || v(N, g.number)), c.value = g.number, i.value = g.formatted;
|
|
1422
1422
|
},
|
|
1423
1423
|
onChange: (g) => {
|
|
1424
|
-
e !== !1 && (v == null || v(
|
|
1424
|
+
e !== !1 && (v == null || v(z, g.number));
|
|
1425
1425
|
}
|
|
1426
|
-
}), o.setValue(
|
|
1426
|
+
}), o.setValue(D.value)) : console.error('No input element found. Please make sure that the "inputRef" template ref is properly assigned.');
|
|
1427
1427
|
} else
|
|
1428
1428
|
o = null;
|
|
1429
1429
|
}), {
|
|
1430
1430
|
inputRef: r,
|
|
1431
1431
|
numberValue: c,
|
|
1432
1432
|
formattedValue: i,
|
|
1433
|
-
setValue: (
|
|
1434
|
-
setOptions: (
|
|
1433
|
+
setValue: (q) => o == null ? void 0 : o.setValue(q),
|
|
1434
|
+
setOptions: (q) => o == null ? void 0 : o.setOptions(q)
|
|
1435
1435
|
};
|
|
1436
1436
|
}
|
|
1437
1437
|
const aa = ["disabled", "step", "placeholder", "name"], na = /* @__PURE__ */ K({
|
|
@@ -1536,13 +1536,13 @@ const ra = [
|
|
|
1536
1536
|
Hl((d) => ({
|
|
1537
1537
|
44703202: c.value
|
|
1538
1538
|
}));
|
|
1539
|
-
const { n, t: s } = ce(), o = V(), r =
|
|
1539
|
+
const { n, t: s } = ce(), o = V(), r = F({
|
|
1540
1540
|
get: () => t.value,
|
|
1541
1541
|
set: (d) => l("update:value", d ?? "")
|
|
1542
|
-
}), i = sl((d) => r.value = d || d === 0 ? d : t.min, 1e3), c =
|
|
1542
|
+
}), i = sl((d) => r.value = d || d === 0 ? d : t.min, 1e3), c = F(() => {
|
|
1543
1543
|
let w = ((typeof r.value == "number" ? r.value : t.min) - t.min) / (t.max - t.min) * 100;
|
|
1544
1544
|
return w < 35 && w > 0 ? w < 20 ? w += 0.5 : w += 0.25 : w > 65 && w < 100 && (w > 80 ? w -= 0.5 : w -= 0.25), `${w}%`;
|
|
1545
|
-
}), f =
|
|
1545
|
+
}), f = F(() => t.min <= t.max && t.step > 0);
|
|
1546
1546
|
e({
|
|
1547
1547
|
focus() {
|
|
1548
1548
|
var d;
|
|
@@ -1553,12 +1553,12 @@ const ra = [
|
|
|
1553
1553
|
return (d, w) => f.value ? (p(), T("div", de(ue({ key: 0 }, d.$attrs)), [
|
|
1554
1554
|
b("div", ia, [
|
|
1555
1555
|
b("span", {
|
|
1556
|
-
class:
|
|
1556
|
+
class: U(["cl-border cl-border-transparent cl-leading-6 cl-mr-1 cl-px-2 cl-rounded-full cl-select-none cl-shadow cl-text-center cl-text-xs", {
|
|
1557
1557
|
"cl-bg-white cl-cursor-pointer hover:cl-border-grey-1": !d.disabled,
|
|
1558
1558
|
"cl-bg-grey-0": d.disabled
|
|
1559
1559
|
}]),
|
|
1560
1560
|
onClick: w[0] || (w[0] = (O) => r.value = d.disabled ? r.value : d.min)
|
|
1561
|
-
},
|
|
1561
|
+
}, I(h(n)(d.min, Number.isInteger(d.min) ? h(fe).INTEGER : h(fe).DECIMAL)), 3),
|
|
1562
1562
|
b("div", sa, [
|
|
1563
1563
|
v.value ? (p(), Z(h(me), {
|
|
1564
1564
|
key: 0,
|
|
@@ -1596,16 +1596,16 @@ const ra = [
|
|
|
1596
1596
|
{ number: !0 }
|
|
1597
1597
|
]
|
|
1598
1598
|
]),
|
|
1599
|
-
b("div", ua,
|
|
1599
|
+
b("div", ua, I(r.value), 1)
|
|
1600
1600
|
], 64))
|
|
1601
1601
|
]),
|
|
1602
1602
|
b("span", {
|
|
1603
|
-
class:
|
|
1603
|
+
class: U(["cl-border cl-border-transparent cl-leading-6 cl-ml-1 cl-px-2 cl-rounded-full cl-select-none cl-shadow cl-text-center cl-text-xs", {
|
|
1604
1604
|
"cl-bg-white cl-cursor-pointer hover:cl-border-grey-1": !d.disabled,
|
|
1605
1605
|
"cl-bg-grey-0": d.disabled
|
|
1606
1606
|
}]),
|
|
1607
1607
|
onClick: w[3] || (w[3] = (O) => r.value = d.disabled ? r.value : d.max)
|
|
1608
|
-
},
|
|
1608
|
+
}, I(h(n)(d.max, Number.isInteger(d.max) ? h(fe).INTEGER : h(fe).DECIMAL)), 3),
|
|
1609
1609
|
b("div", da, [
|
|
1610
1610
|
b("div", {
|
|
1611
1611
|
class: "cl-bg-white cl-border cl-border-transparent cl-cursor-pointer cl-float-right cl-p-1.5 cl-px-2 cl-rounded-full cl-shadow cl-text-xs hover:cl-border-grey-1",
|
|
@@ -1615,7 +1615,7 @@ const ra = [
|
|
|
1615
1615
|
])
|
|
1616
1616
|
])
|
|
1617
1617
|
])
|
|
1618
|
-
], 16)) : (p(), T("div", fa,
|
|
1618
|
+
], 16)) : (p(), T("div", fa, I(h(s)("slider.invalidProps")), 1));
|
|
1619
1619
|
}
|
|
1620
1620
|
});
|
|
1621
1621
|
const ma = /* @__PURE__ */ Te(pa, [["__scopeId", "data-v-470989ac"]]);
|
|
@@ -1735,20 +1735,20 @@ const ga = { class: "cl-flex cl-justify-between" }, ba = { class: "cl-w-full" },
|
|
|
1735
1735
|
},
|
|
1736
1736
|
emits: ["update:model-value", "click", "focus", "input", "change", "validated"],
|
|
1737
1737
|
setup(a, { expose: e, emit: l }) {
|
|
1738
|
-
const t = a, n = V(null), s = V(!1), o = V(!1), r =
|
|
1738
|
+
const t = a, n = V(null), s = V(!1), o = V(!1), r = F(Y), i = F(() => t.placeholderText.trim() !== "" ? t.placeholderText : t.label), c = V(0), f = F({
|
|
1739
1739
|
get: () => t.modelValue,
|
|
1740
1740
|
set: (y) => m(y, !1)
|
|
1741
|
-
}), v =
|
|
1741
|
+
}), v = F({
|
|
1742
1742
|
get: () => t.modelValue,
|
|
1743
1743
|
set: (y) => u(y)
|
|
1744
|
-
}), d =
|
|
1745
|
-
var y,
|
|
1744
|
+
}), d = F(() => typeof t.min == "number" ? t.min.toString() : t.min), w = F(() => typeof t.max == "number" ? t.max.toString() : t.max), O = F(() => typeof t.min == "number" || t.min === null ? t.min : parseFloat(t.min)), D = F(() => typeof t.max == "number" || t.max === null ? t.max : parseFloat(t.max)), N = F(() => t.messageWhenValid.trim() !== "" ? t.messageWhenValid : ""), z = V(!0), q = V(!0), le = V([]), re = F(() => {
|
|
1745
|
+
var y, j;
|
|
1746
1746
|
return [
|
|
1747
|
-
...((y = le.value) == null ? void 0 : y.filter((
|
|
1748
|
-
...((
|
|
1747
|
+
...((y = le.value) == null ? void 0 : y.filter((_) => ((_ == null ? void 0 : _.length) ?? 0) > 0)) ?? [],
|
|
1748
|
+
...((j = t.externalErrors) == null ? void 0 : j.filter((_) => ((_ == null ? void 0 : _.length) ?? 0) > 0)) ?? []
|
|
1749
1749
|
].join(`
|
|
1750
1750
|
`);
|
|
1751
|
-
}), g =
|
|
1751
|
+
}), g = F(() => ({
|
|
1752
1752
|
currency: "GBP",
|
|
1753
1753
|
locale: "en-EN",
|
|
1754
1754
|
valueRange: {
|
|
@@ -1760,55 +1760,55 @@ const ga = { class: "cl-flex cl-justify-between" }, ba = { class: "cl-w-full" },
|
|
|
1760
1760
|
async function u(y) {
|
|
1761
1761
|
t.validateOn === "input" && await k(y), l("update:model-value", y);
|
|
1762
1762
|
}
|
|
1763
|
-
async function m(y,
|
|
1764
|
-
t.onInputFunction !== void 0 && (y = t.onInputFunction(y)), t.validateOn === "change" && (
|
|
1763
|
+
async function m(y, j) {
|
|
1764
|
+
t.onInputFunction !== void 0 && (y = t.onInputFunction(y)), t.validateOn === "change" && (q.value = !1), (j || t.validateOn === "input") && await k(y), l("update:model-value", y);
|
|
1765
1765
|
}
|
|
1766
1766
|
function k(y) {
|
|
1767
|
-
const
|
|
1767
|
+
const j = {
|
|
1768
1768
|
message: "",
|
|
1769
1769
|
valid: !0
|
|
1770
|
-
},
|
|
1770
|
+
}, _ = [
|
|
1771
1771
|
t.customValidationFunction === null || t.customValidationFunction === void 0 ? new Promise((ge) => {
|
|
1772
|
-
ge(
|
|
1772
|
+
ge(j);
|
|
1773
1773
|
}) : new Promise((ge) => {
|
|
1774
1774
|
ge(t.customValidationFunction(t.label, y));
|
|
1775
1775
|
})
|
|
1776
1776
|
];
|
|
1777
|
-
return (typeof y == "string" || typeof y == "number") && (
|
|
1777
|
+
return (typeof y == "string" || typeof y == "number") && (_.push(It(t.min, t.inputType, t.label, y, t.timeZone)), _.push(Rt(t.max, t.inputType, t.label, y, t.timeZone))), t.isRequired && _.push(Vt(t.label, y)), t.inputType === "email" && typeof y == "string" && _.push(qt(t.label, y)), Promise.all(_).then((ge) => {
|
|
1778
1778
|
const je = [...ge.map((Se) => Se.message)], De = ge.some((Se) => Se.message.length > 0 && Se.valid === !1) || t.externalErrors.length > 0;
|
|
1779
|
-
|
|
1779
|
+
q.value = !0, De ? (le.value = je, l("validated", !1, y)) : (le.value = [], l("validated", !0, y)), z.value = !De;
|
|
1780
1780
|
});
|
|
1781
1781
|
}
|
|
1782
|
-
function
|
|
1782
|
+
function M() {
|
|
1783
1783
|
let y = "";
|
|
1784
1784
|
return t.inputType === "color" && f.value && (t.disabled ? y = "background: #999999" : y = `background: ${f.value};`), y;
|
|
1785
1785
|
}
|
|
1786
|
-
function
|
|
1786
|
+
function L(y) {
|
|
1787
1787
|
Ve(t.inputType) ? (y.preventDefault(), l("click", y)) : t.inputType === "checkbox" && l("click", y);
|
|
1788
1788
|
}
|
|
1789
1789
|
function S(y) {
|
|
1790
1790
|
if (n.value) {
|
|
1791
1791
|
n.value.stepUp(), n.value.focus(), m(n.value.valueAsNumber, !1);
|
|
1792
|
-
const
|
|
1792
|
+
const j = {
|
|
1793
1793
|
target: n.value
|
|
1794
1794
|
};
|
|
1795
|
-
l("input",
|
|
1795
|
+
l("input", j, n.value.valueAsNumber), l("change", y, n.value.valueAsNumber);
|
|
1796
1796
|
}
|
|
1797
1797
|
}
|
|
1798
1798
|
function $(y) {
|
|
1799
1799
|
if (n.value) {
|
|
1800
1800
|
n.value.stepDown(), n.value.focus(), m(n.value.valueAsNumber, !1);
|
|
1801
|
-
const
|
|
1801
|
+
const j = {
|
|
1802
1802
|
target: n.value
|
|
1803
1803
|
};
|
|
1804
|
-
l("input",
|
|
1804
|
+
l("input", j, n.value.valueAsNumber), l("change", y, n.value.valueAsNumber);
|
|
1805
1805
|
}
|
|
1806
1806
|
}
|
|
1807
|
-
function
|
|
1807
|
+
function A(y) {
|
|
1808
1808
|
s.value = y;
|
|
1809
1809
|
}
|
|
1810
|
-
async function
|
|
1811
|
-
o.value = !0,
|
|
1810
|
+
async function B() {
|
|
1811
|
+
o.value = !0, A(!1), t.validateOn === "change" && await k(f.value);
|
|
1812
1812
|
}
|
|
1813
1813
|
function C() {
|
|
1814
1814
|
c.value++;
|
|
@@ -1817,17 +1817,17 @@ const ga = { class: "cl-flex cl-justify-between" }, ba = { class: "cl-w-full" },
|
|
|
1817
1817
|
y.target.blur();
|
|
1818
1818
|
}
|
|
1819
1819
|
function Y() {
|
|
1820
|
-
var
|
|
1820
|
+
var _;
|
|
1821
1821
|
let y = !0;
|
|
1822
|
-
const
|
|
1823
|
-
return s.value ? y =
|
|
1822
|
+
const j = r.value;
|
|
1823
|
+
return s.value ? y = j : o.value && ((_ = f.value) == null ? void 0 : _.toString().trim()) === "" && t.requiredText.trim() !== "" && (y = !1), !t.hideRequiredAsterisk && y;
|
|
1824
1824
|
}
|
|
1825
1825
|
async function W(y) {
|
|
1826
|
-
const
|
|
1827
|
-
t.validateOn === "change" && await k(
|
|
1826
|
+
const j = ll(y, t.inputType);
|
|
1827
|
+
t.validateOn === "change" && await k(j), l("change", y, j);
|
|
1828
1828
|
}
|
|
1829
1829
|
async function ne() {
|
|
1830
|
-
await
|
|
1830
|
+
await B(), C();
|
|
1831
1831
|
}
|
|
1832
1832
|
return Qe(() => {
|
|
1833
1833
|
t.validateImmediately && m(t.modelValue, !0);
|
|
@@ -1847,40 +1847,40 @@ const ga = { class: "cl-flex cl-justify-between" }, ba = { class: "cl-w-full" },
|
|
|
1847
1847
|
var y;
|
|
1848
1848
|
(y = n.value) == null || y.blur();
|
|
1849
1849
|
}
|
|
1850
|
-
}), (y,
|
|
1850
|
+
}), (y, j) => (p(), T("div", ue({ ...y.$attrs, id: void 0 }, {
|
|
1851
1851
|
key: c.value,
|
|
1852
1852
|
class: "cl-align-top cl-border-none cl-inline-block cl-text-left"
|
|
1853
1853
|
}), [
|
|
1854
1854
|
b("div", {
|
|
1855
|
-
onMouseenter:
|
|
1856
|
-
onMouseleave:
|
|
1855
|
+
onMouseenter: j[13] || (j[13] = (_) => A(!0)),
|
|
1856
|
+
onMouseleave: j[14] || (j[14] = (_) => A(!1))
|
|
1857
1857
|
}, [
|
|
1858
1858
|
b("div", ga, [
|
|
1859
1859
|
b("div", ba, [
|
|
1860
|
-
ee(b("label", { class: "cl-block cl-mb-1 cl-text-grey-4 cl-text-xs cl-tracking-widest" },
|
|
1860
|
+
ee(b("label", { class: "cl-block cl-mb-1 cl-text-grey-4 cl-text-xs cl-tracking-widest" }, I(y.label), 513), [
|
|
1861
1861
|
[te, y.showLabel && y.label !== ""]
|
|
1862
1862
|
])
|
|
1863
1863
|
]),
|
|
1864
|
-
y.isRequired && r.value ? (p(), T("label", ya, " * ")) :
|
|
1865
|
-
y.isRequired && !r.value && y.requiredText.length ? (p(), T("label", wa,
|
|
1864
|
+
y.isRequired && r.value ? (p(), T("label", ya, " * ")) : P("", !0),
|
|
1865
|
+
y.isRequired && !r.value && y.requiredText.length ? (p(), T("label", wa, I(y.requiredText), 1)) : P("", !0)
|
|
1866
1866
|
]),
|
|
1867
1867
|
y.inputType !== "range" && y.inputType !== "currency" && !h(ml)(y.inputType) ? (p(), T("div", ka, [
|
|
1868
1868
|
ee(b("input", ue({
|
|
1869
1869
|
ref_key: "inputElement",
|
|
1870
1870
|
ref: n,
|
|
1871
|
-
"onUpdate:modelValue":
|
|
1871
|
+
"onUpdate:modelValue": j[0] || (j[0] = (_) => f.value = _)
|
|
1872
1872
|
}, y.$attrs, {
|
|
1873
1873
|
class: ["!cl-mb-1 cl-block cl-border cl-duration-300 cl-h-full cl-transition cl-w-full focus:cl-outline-none", {
|
|
1874
1874
|
"hover:!cl-border-grey-3": y.disabled === !1 && !h(Ve)(y.inputType),
|
|
1875
1875
|
"!cl-cursor-default": y.disabled,
|
|
1876
|
-
"!cl-border-danger-default": !
|
|
1877
|
-
"!cl-border-primary-default":
|
|
1878
|
-
"cl-border-grey-0 focus:cl-border-blue-light":
|
|
1876
|
+
"!cl-border-danger-default": !z.value,
|
|
1877
|
+
"!cl-border-primary-default": z.value && y.highlightWhenValid,
|
|
1878
|
+
"cl-border-grey-0 focus:cl-border-blue-light": z.value && !h(Ve)(y.inputType),
|
|
1879
1879
|
"!cl-p-2": y.inputType === "checkbox" || y.inputType === "radio",
|
|
1880
1880
|
"cl-p-3 cl-rounded-lg": !h(Ve)(y.inputType),
|
|
1881
1881
|
[`${y.inputSpecificClasses}`]: y.inputSpecificClasses !== ""
|
|
1882
1882
|
}],
|
|
1883
|
-
style:
|
|
1883
|
+
style: M(),
|
|
1884
1884
|
type: y.inputType,
|
|
1885
1885
|
disabled: y.disabled,
|
|
1886
1886
|
min: y.min ?? void 0,
|
|
@@ -1892,12 +1892,12 @@ const ga = { class: "cl-flex cl-justify-between" }, ba = { class: "cl-w-full" },
|
|
|
1892
1892
|
accept: y.fileExtensions,
|
|
1893
1893
|
name: y.group,
|
|
1894
1894
|
autocomplete: y.autocomplete,
|
|
1895
|
-
onClick:
|
|
1896
|
-
onFocus:
|
|
1895
|
+
onClick: j[1] || (j[1] = (_) => L(_)),
|
|
1896
|
+
onFocus: j[2] || (j[2] = (_) => l("focus")),
|
|
1897
1897
|
onBlur: oe(ne, ["self"]),
|
|
1898
1898
|
onMousewheelPassive: R,
|
|
1899
|
-
onInput:
|
|
1900
|
-
l("input",
|
|
1899
|
+
onInput: j[3] || (j[3] = (_) => {
|
|
1900
|
+
l("input", _, h(ll)(_, y.inputType));
|
|
1901
1901
|
}),
|
|
1902
1902
|
onChange: W
|
|
1903
1903
|
}), null, 16, Ta), [
|
|
@@ -1913,40 +1913,40 @@ const ga = { class: "cl-flex cl-justify-between" }, ba = { class: "cl-w-full" },
|
|
|
1913
1913
|
icon: "ph:caret-up-bold",
|
|
1914
1914
|
class: "cl-absolute cl-bg-link-default cl-right-1 cl-rounded-full cl-text-sm cl-text-white cl-top-1 hover:cl-bg-link-light hover:cl-cursor-pointer",
|
|
1915
1915
|
onClick: S,
|
|
1916
|
-
onMousedown:
|
|
1916
|
+
onMousedown: j[4] || (j[4] = oe(() => {
|
|
1917
1917
|
}, ["prevent"]))
|
|
1918
1918
|
}),
|
|
1919
1919
|
E(h(H), {
|
|
1920
1920
|
icon: "ph:caret-down-bold",
|
|
1921
1921
|
class: "cl-absolute cl-bg-link-default cl-bottom-2 cl-right-1 cl-rounded-full cl-text-sm cl-text-white hover:cl-bg-link-light hover:cl-cursor-pointer",
|
|
1922
1922
|
onClick: $,
|
|
1923
|
-
onMousedown:
|
|
1923
|
+
onMousedown: j[5] || (j[5] = oe(() => {
|
|
1924
1924
|
}, ["prevent"]))
|
|
1925
1925
|
})
|
|
1926
1926
|
], 512)), [
|
|
1927
1927
|
[te, s.value]
|
|
1928
|
-
]) :
|
|
1928
|
+
]) : P("", !0)
|
|
1929
1929
|
]),
|
|
1930
1930
|
_: 1
|
|
1931
1931
|
})
|
|
1932
1932
|
])) : y.inputType === "currency" ? (p(), T("div", Sa, [
|
|
1933
1933
|
E(na, ue({
|
|
1934
1934
|
modelValue: f.value,
|
|
1935
|
-
"onUpdate:modelValue":
|
|
1935
|
+
"onUpdate:modelValue": j[6] || (j[6] = (_) => f.value = _),
|
|
1936
1936
|
modelModifiers: { lazy: !0 }
|
|
1937
1937
|
}, y.$attrs, {
|
|
1938
1938
|
disabled: y.disabled,
|
|
1939
1939
|
placeholder: i.value,
|
|
1940
|
-
"is-valid":
|
|
1940
|
+
"is-valid": z.value,
|
|
1941
1941
|
"highlight-when-valid": y.highlightWhenValid,
|
|
1942
1942
|
"input-specific-classes": y.inputSpecificClasses,
|
|
1943
1943
|
group: y.group,
|
|
1944
1944
|
step: y.step,
|
|
1945
1945
|
"currency-options": g.value,
|
|
1946
|
-
onFocus:
|
|
1947
|
-
onBlur: oe(
|
|
1948
|
-
onInput:
|
|
1949
|
-
l("input",
|
|
1946
|
+
onFocus: j[7] || (j[7] = (_) => l("focus")),
|
|
1947
|
+
onBlur: oe(B, ["self"]),
|
|
1948
|
+
onInput: j[8] || (j[8] = (_) => {
|
|
1949
|
+
l("input", _, h(ll)(_, y.inputType));
|
|
1950
1950
|
}),
|
|
1951
1951
|
onChange: W
|
|
1952
1952
|
}), null, 16, ["modelValue", "disabled", "placeholder", "is-valid", "highlight-when-valid", "input-specific-classes", "group", "step", "currency-options", "onBlur"])
|
|
@@ -1954,11 +1954,11 @@ const ga = { class: "cl-flex cl-justify-between" }, ba = { class: "cl-w-full" },
|
|
|
1954
1954
|
ref_key: "inputElement",
|
|
1955
1955
|
ref: n,
|
|
1956
1956
|
date: v.value,
|
|
1957
|
-
"onUpdate:date":
|
|
1957
|
+
"onUpdate:date": j[9] || (j[9] = (_) => v.value = _),
|
|
1958
1958
|
class: ["cl-block cl-duration-300 cl-h-fit cl-mb-1 cl-rounded-lg cl-text-sm cl-transition cl-w-full focus:cl-outline-none", {
|
|
1959
1959
|
"hover:cl-border-grey-3": !y.disabled && y.inputType !== "dateRange",
|
|
1960
|
-
"!cl-border-danger-default": !
|
|
1961
|
-
"!cl-border-primary-default":
|
|
1960
|
+
"!cl-border-danger-default": !z.value,
|
|
1961
|
+
"!cl-border-primary-default": z.value && y.highlightWhenValid
|
|
1962
1962
|
}],
|
|
1963
1963
|
disabled: y.disabled,
|
|
1964
1964
|
required: y.isRequired,
|
|
@@ -1970,27 +1970,27 @@ const ga = { class: "cl-flex cl-justify-between" }, ba = { class: "cl-w-full" },
|
|
|
1970
1970
|
"initial-date": y.initialDate,
|
|
1971
1971
|
"quick-date-scope": y.quickDateScope,
|
|
1972
1972
|
"date-format-locale": y.dateFormatLocale,
|
|
1973
|
-
onBlur: oe(
|
|
1974
|
-
onFocus:
|
|
1973
|
+
onBlur: oe(B, ["self"]),
|
|
1974
|
+
onFocus: j[10] || (j[10] = (_) => l("focus"))
|
|
1975
1975
|
}), null, 16, ["date", "class", "disabled", "required", "type", "time-zone", "min", "max", "placeholder", "initial-date", "quick-date-scope", "date-format-locale", "onBlur"])) : y.inputType === "range" && (typeof f.value == "number" || typeof f.value == "string") ? (p(), T("div", Ca, [
|
|
1976
1976
|
E(h(ma), {
|
|
1977
1977
|
ref_key: "inputElement",
|
|
1978
1978
|
ref: n,
|
|
1979
1979
|
value: f.value,
|
|
1980
|
-
"onUpdate:value":
|
|
1980
|
+
"onUpdate:value": j[11] || (j[11] = (_) => f.value = _),
|
|
1981
1981
|
min: O.value ?? 0,
|
|
1982
|
-
max:
|
|
1982
|
+
max: D.value ?? 1e3,
|
|
1983
1983
|
step: y.step,
|
|
1984
1984
|
placeholder: i.value,
|
|
1985
1985
|
"enforce-step": !0,
|
|
1986
1986
|
disabled: y.disabled,
|
|
1987
|
-
onBlur: oe(
|
|
1988
|
-
onFocus:
|
|
1987
|
+
onBlur: oe(B, ["self"]),
|
|
1988
|
+
onFocus: j[12] || (j[12] = (_) => l("focus"))
|
|
1989
1989
|
}, null, 8, ["value", "min", "max", "step", "placeholder", "disabled", "onBlur"])
|
|
1990
|
-
])) :
|
|
1990
|
+
])) : P("", !0)
|
|
1991
1991
|
], 32),
|
|
1992
|
-
|
|
1993
|
-
!
|
|
1992
|
+
z.value && N.value && q.value ? (p(), T("div", Oa, I(N.value), 1)) : P("", !0),
|
|
1993
|
+
!z.value && re.value.length > 0 && y.showValidationMessages && q.value ? (p(), T("div", Ea, I(re.value), 1)) : P("", !0)
|
|
1994
1994
|
], 16));
|
|
1995
1995
|
}
|
|
1996
1996
|
});
|
|
@@ -2318,26 +2318,26 @@ var bl = {
|
|
|
2318
2318
|
delayInitialFocusTimer: void 0,
|
|
2319
2319
|
// the most recent KeyboardEvent for the configured nav key (typically [SHIFT+]TAB), if any
|
|
2320
2320
|
recentNavEvent: void 0
|
|
2321
|
-
}, r, i = function(S, $,
|
|
2322
|
-
return S && S[$] !== void 0 ? S[$] : s[
|
|
2321
|
+
}, r, i = function(S, $, A) {
|
|
2322
|
+
return S && S[$] !== void 0 ? S[$] : s[A || $];
|
|
2323
2323
|
}, c = function(S, $) {
|
|
2324
|
-
var
|
|
2325
|
-
return o.containerGroups.findIndex(function(
|
|
2326
|
-
var C =
|
|
2324
|
+
var A = typeof ($ == null ? void 0 : $.composedPath) == "function" ? $.composedPath() : void 0;
|
|
2325
|
+
return o.containerGroups.findIndex(function(B) {
|
|
2326
|
+
var C = B.container, R = B.tabbableNodes;
|
|
2327
2327
|
return C.contains(S) || // fall back to explicit tabbable search which will take into consideration any
|
|
2328
2328
|
// web components if the `tabbableOptions.getShadowRoot` option was used for
|
|
2329
2329
|
// the trap, enabling shadow DOM support in tabbable (`Node.contains()` doesn't
|
|
2330
2330
|
// look inside web components even if open)
|
|
2331
|
-
(
|
|
2331
|
+
(A == null ? void 0 : A.includes(C)) || R.find(function(Y) {
|
|
2332
2332
|
return Y === S;
|
|
2333
2333
|
});
|
|
2334
2334
|
});
|
|
2335
2335
|
}, f = function(S) {
|
|
2336
2336
|
var $ = s[S];
|
|
2337
2337
|
if (typeof $ == "function") {
|
|
2338
|
-
for (var
|
|
2339
|
-
|
|
2340
|
-
$ = $.apply(void 0,
|
|
2338
|
+
for (var A = arguments.length, B = new Array(A > 1 ? A - 1 : 0), C = 1; C < A; C++)
|
|
2339
|
+
B[C - 1] = arguments[C];
|
|
2340
|
+
$ = $.apply(void 0, B);
|
|
2341
2341
|
}
|
|
2342
2342
|
if ($ === !0 && ($ = void 0), !$) {
|
|
2343
2343
|
if ($ === void 0 || $ === !1)
|
|
@@ -2356,17 +2356,17 @@ var bl = {
|
|
|
2356
2356
|
if (c(t.activeElement) >= 0)
|
|
2357
2357
|
S = t.activeElement;
|
|
2358
2358
|
else {
|
|
2359
|
-
var $ = o.tabbableGroups[0],
|
|
2360
|
-
S =
|
|
2359
|
+
var $ = o.tabbableGroups[0], A = $ && $.firstTabbableNode;
|
|
2360
|
+
S = A || f("fallbackFocus");
|
|
2361
2361
|
}
|
|
2362
2362
|
if (!S)
|
|
2363
2363
|
throw new Error("Your focus-trap needs to have at least one focusable element");
|
|
2364
2364
|
return S;
|
|
2365
2365
|
}, d = function() {
|
|
2366
2366
|
if (o.containerGroups = o.containers.map(function(S) {
|
|
2367
|
-
var $ = xa(S, s.tabbableOptions),
|
|
2367
|
+
var $ = xa(S, s.tabbableOptions), A = _a(S, s.tabbableOptions), B = $.length > 0 ? $[0] : void 0, C = $.length > 0 ? $[$.length - 1] : void 0, R = A.find(function(ne) {
|
|
2368
2368
|
return Fe(ne);
|
|
2369
|
-
}), Y =
|
|
2369
|
+
}), Y = A.slice().reverse().find(function(ne) {
|
|
2370
2370
|
return Fe(ne);
|
|
2371
2371
|
}), W = !!$.find(function(ne) {
|
|
2372
2372
|
return Oe(ne) > 0;
|
|
@@ -2374,11 +2374,11 @@ var bl = {
|
|
|
2374
2374
|
return {
|
|
2375
2375
|
container: S,
|
|
2376
2376
|
tabbableNodes: $,
|
|
2377
|
-
focusableNodes:
|
|
2377
|
+
focusableNodes: A,
|
|
2378
2378
|
/** True if at least one node with positive `tabindex` was found in this container. */
|
|
2379
2379
|
posTabIndexesFound: W,
|
|
2380
2380
|
/** First tabbable node in container, __tabindex__ order; `undefined` if none. */
|
|
2381
|
-
firstTabbableNode:
|
|
2381
|
+
firstTabbableNode: B,
|
|
2382
2382
|
/** Last tabbable node in container, __tabindex__ order; `undefined` if none. */
|
|
2383
2383
|
lastTabbableNode: C,
|
|
2384
2384
|
// NOTE: DOM order is NOT NECESSARILY "document position" order, but figuring that out
|
|
@@ -2401,12 +2401,12 @@ var bl = {
|
|
|
2401
2401
|
* @returns {HTMLElement|undefined} The next tabbable node, if any.
|
|
2402
2402
|
*/
|
|
2403
2403
|
nextTabbableNode: function(y) {
|
|
2404
|
-
var
|
|
2405
|
-
return
|
|
2404
|
+
var j = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0, _ = $.indexOf(y);
|
|
2405
|
+
return _ < 0 ? j ? A.slice(A.indexOf(y) + 1).find(function(ge) {
|
|
2406
2406
|
return Fe(ge);
|
|
2407
|
-
}) :
|
|
2407
|
+
}) : A.slice(0, A.indexOf(y)).reverse().find(function(ge) {
|
|
2408
2408
|
return Fe(ge);
|
|
2409
|
-
}) : $[
|
|
2409
|
+
}) : $[_ + (j ? 1 : -1)];
|
|
2410
2410
|
}
|
|
2411
2411
|
};
|
|
2412
2412
|
}), o.tabbableGroups = o.containerGroups.filter(function(S) {
|
|
@@ -2417,10 +2417,10 @@ var bl = {
|
|
|
2417
2417
|
return S.posTabIndexesFound;
|
|
2418
2418
|
}) && o.containerGroups.length > 1)
|
|
2419
2419
|
throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.");
|
|
2420
|
-
}, w = function
|
|
2420
|
+
}, w = function L(S) {
|
|
2421
2421
|
if (S !== !1 && S !== t.activeElement) {
|
|
2422
2422
|
if (!S || !S.focus) {
|
|
2423
|
-
|
|
2423
|
+
L(v());
|
|
2424
2424
|
return;
|
|
2425
2425
|
}
|
|
2426
2426
|
S.focus({
|
|
@@ -2430,12 +2430,12 @@ var bl = {
|
|
|
2430
2430
|
}, O = function(S) {
|
|
2431
2431
|
var $ = f("setReturnFocus", S);
|
|
2432
2432
|
return $ || ($ === !1 ? !1 : S);
|
|
2433
|
-
},
|
|
2434
|
-
var $ = S.target,
|
|
2435
|
-
$ = $ || Pe(
|
|
2433
|
+
}, D = function(S) {
|
|
2434
|
+
var $ = S.target, A = S.event, B = S.isBackward, C = B === void 0 ? !1 : B;
|
|
2435
|
+
$ = $ || Pe(A), d();
|
|
2436
2436
|
var R = null;
|
|
2437
2437
|
if (o.tabbableGroups.length > 0) {
|
|
2438
|
-
var Y = c($,
|
|
2438
|
+
var Y = c($, A), W = Y >= 0 ? o.containerGroups[Y] : void 0;
|
|
2439
2439
|
if (Y < 0)
|
|
2440
2440
|
C ? R = o.tabbableGroups[o.tabbableGroups.length - 1].lastTabbableNode : R = o.tabbableGroups[0].firstTabbableNode;
|
|
2441
2441
|
else if (C) {
|
|
@@ -2444,25 +2444,25 @@ var bl = {
|
|
|
2444
2444
|
return $ === Se;
|
|
2445
2445
|
});
|
|
2446
2446
|
if (ne < 0 && (W.container === $ || tl($, s.tabbableOptions) && !Fe($, s.tabbableOptions) && !W.nextTabbableNode($, !1)) && (ne = Y), ne >= 0) {
|
|
2447
|
-
var y = ne === 0 ? o.tabbableGroups.length - 1 : ne - 1,
|
|
2448
|
-
R = Oe($) >= 0 ?
|
|
2447
|
+
var y = ne === 0 ? o.tabbableGroups.length - 1 : ne - 1, j = o.tabbableGroups[y];
|
|
2448
|
+
R = Oe($) >= 0 ? j.lastTabbableNode : j.lastDomTabbableNode;
|
|
2449
2449
|
} else
|
|
2450
|
-
Me(
|
|
2450
|
+
Me(A) || (R = W.nextTabbableNode($, !1));
|
|
2451
2451
|
} else {
|
|
2452
|
-
var
|
|
2452
|
+
var _ = wl(o.tabbableGroups, function(De) {
|
|
2453
2453
|
var Se = De.lastTabbableNode;
|
|
2454
2454
|
return $ === Se;
|
|
2455
2455
|
});
|
|
2456
|
-
if (
|
|
2457
|
-
var ge =
|
|
2456
|
+
if (_ < 0 && (W.container === $ || tl($, s.tabbableOptions) && !Fe($, s.tabbableOptions) && !W.nextTabbableNode($)) && (_ = Y), _ >= 0) {
|
|
2457
|
+
var ge = _ === o.tabbableGroups.length - 1 ? 0 : _ + 1, je = o.tabbableGroups[ge];
|
|
2458
2458
|
R = Oe($) >= 0 ? je.firstTabbableNode : je.firstDomTabbableNode;
|
|
2459
2459
|
} else
|
|
2460
|
-
Me(
|
|
2460
|
+
Me(A) || (R = W.nextTabbableNode($));
|
|
2461
2461
|
}
|
|
2462
2462
|
} else
|
|
2463
2463
|
R = f("fallbackFocus");
|
|
2464
2464
|
return R;
|
|
2465
|
-
},
|
|
2465
|
+
}, N = function(S) {
|
|
2466
2466
|
var $ = Pe(S);
|
|
2467
2467
|
if (!(c($, S) >= 0)) {
|
|
2468
2468
|
if (Ie(s.clickOutsideDeactivates, S)) {
|
|
@@ -2479,13 +2479,13 @@ var bl = {
|
|
|
2479
2479
|
}
|
|
2480
2480
|
Ie(s.allowOutsideClick, S) || S.preventDefault();
|
|
2481
2481
|
}
|
|
2482
|
-
},
|
|
2483
|
-
var $ = Pe(S),
|
|
2484
|
-
if (
|
|
2485
|
-
|
|
2482
|
+
}, z = function(S) {
|
|
2483
|
+
var $ = Pe(S), A = c($, S) >= 0;
|
|
2484
|
+
if (A || $ instanceof Document)
|
|
2485
|
+
A && (o.mostRecentlyFocusedNode = $);
|
|
2486
2486
|
else {
|
|
2487
2487
|
S.stopImmediatePropagation();
|
|
2488
|
-
var
|
|
2488
|
+
var B, C = !0;
|
|
2489
2489
|
if (o.mostRecentlyFocusedNode)
|
|
2490
2490
|
if (Oe(o.mostRecentlyFocusedNode) > 0) {
|
|
2491
2491
|
var R = c(o.mostRecentlyFocusedNode), Y = o.containerGroups[R].tabbableNodes;
|
|
@@ -2493,7 +2493,7 @@ var bl = {
|
|
|
2493
2493
|
var W = Y.findIndex(function(ne) {
|
|
2494
2494
|
return ne === o.mostRecentlyFocusedNode;
|
|
2495
2495
|
});
|
|
2496
|
-
W >= 0 && (s.isKeyForward(o.recentNavEvent) ? W + 1 < Y.length && (
|
|
2496
|
+
W >= 0 && (s.isKeyForward(o.recentNavEvent) ? W + 1 < Y.length && (B = Y[W + 1], C = !1) : W - 1 >= 0 && (B = Y[W - 1], C = !1));
|
|
2497
2497
|
}
|
|
2498
2498
|
} else
|
|
2499
2499
|
o.containerGroups.some(function(ne) {
|
|
@@ -2503,28 +2503,28 @@ var bl = {
|
|
|
2503
2503
|
}) || (C = !1);
|
|
2504
2504
|
else
|
|
2505
2505
|
C = !1;
|
|
2506
|
-
C && (
|
|
2506
|
+
C && (B = D({
|
|
2507
2507
|
// move FROM the MRU node, not event-related node (which will be the node that is
|
|
2508
2508
|
// outside the trap causing the focus escape we're trying to fix)
|
|
2509
2509
|
target: o.mostRecentlyFocusedNode,
|
|
2510
2510
|
isBackward: s.isKeyBackward(o.recentNavEvent)
|
|
2511
|
-
})), w(
|
|
2511
|
+
})), w(B || o.mostRecentlyFocusedNode || v());
|
|
2512
2512
|
}
|
|
2513
2513
|
o.recentNavEvent = void 0;
|
|
2514
|
-
},
|
|
2514
|
+
}, q = function(S) {
|
|
2515
2515
|
var $ = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1;
|
|
2516
2516
|
o.recentNavEvent = S;
|
|
2517
|
-
var
|
|
2517
|
+
var A = D({
|
|
2518
2518
|
event: S,
|
|
2519
2519
|
isBackward: $
|
|
2520
2520
|
});
|
|
2521
|
-
|
|
2521
|
+
A && (Me(S) && S.preventDefault(), w(A));
|
|
2522
2522
|
}, le = function(S) {
|
|
2523
2523
|
if (Qa(S) && Ie(s.escapeDeactivates, S) !== !1) {
|
|
2524
2524
|
S.preventDefault(), r.deactivate();
|
|
2525
2525
|
return;
|
|
2526
2526
|
}
|
|
2527
|
-
(s.isKeyForward(S) || s.isKeyBackward(S)) &&
|
|
2527
|
+
(s.isKeyForward(S) || s.isKeyBackward(S)) && q(S, s.isKeyBackward(S));
|
|
2528
2528
|
}, re = function(S) {
|
|
2529
2529
|
var $ = Pe(S);
|
|
2530
2530
|
c($, S) >= 0 || Ie(s.clickOutsideDeactivates, S) || Ie(s.allowOutsideClick, S) || (S.preventDefault(), S.stopImmediatePropagation());
|
|
@@ -2532,10 +2532,10 @@ var bl = {
|
|
|
2532
2532
|
if (o.active)
|
|
2533
2533
|
return bl.activateTrap(n, r), o.delayInitialFocusTimer = s.delayInitialFocus ? yl(function() {
|
|
2534
2534
|
w(v());
|
|
2535
|
-
}) : w(v()), t.addEventListener("focusin",
|
|
2535
|
+
}) : w(v()), t.addEventListener("focusin", z, !0), t.addEventListener("mousedown", N, {
|
|
2536
2536
|
capture: !0,
|
|
2537
2537
|
passive: !1
|
|
2538
|
-
}), t.addEventListener("touchstart",
|
|
2538
|
+
}), t.addEventListener("touchstart", N, {
|
|
2539
2539
|
capture: !0,
|
|
2540
2540
|
passive: !1
|
|
2541
2541
|
}), t.addEventListener("click", re, {
|
|
@@ -2547,16 +2547,16 @@ var bl = {
|
|
|
2547
2547
|
}), r;
|
|
2548
2548
|
}, u = function() {
|
|
2549
2549
|
if (o.active)
|
|
2550
|
-
return t.removeEventListener("focusin",
|
|
2550
|
+
return t.removeEventListener("focusin", z, !0), t.removeEventListener("mousedown", N, !0), t.removeEventListener("touchstart", N, !0), t.removeEventListener("click", re, !0), t.removeEventListener("keydown", le, !0), r;
|
|
2551
2551
|
}, m = function(S) {
|
|
2552
|
-
var $ = S.some(function(
|
|
2553
|
-
var
|
|
2554
|
-
return
|
|
2552
|
+
var $ = S.some(function(A) {
|
|
2553
|
+
var B = Array.from(A.removedNodes);
|
|
2554
|
+
return B.some(function(C) {
|
|
2555
2555
|
return C === o.mostRecentlyFocusedNode;
|
|
2556
2556
|
});
|
|
2557
2557
|
});
|
|
2558
2558
|
$ && w(v());
|
|
2559
|
-
}, k = typeof window < "u" && "MutationObserver" in window ? new MutationObserver(m) : void 0,
|
|
2559
|
+
}, k = typeof window < "u" && "MutationObserver" in window ? new MutationObserver(m) : void 0, M = function() {
|
|
2560
2560
|
k && (k.disconnect(), o.active && !o.paused && o.containers.map(function(S) {
|
|
2561
2561
|
k.observe(S, {
|
|
2562
2562
|
subtree: !0,
|
|
@@ -2574,12 +2574,12 @@ var bl = {
|
|
|
2574
2574
|
activate: function(S) {
|
|
2575
2575
|
if (o.active)
|
|
2576
2576
|
return this;
|
|
2577
|
-
var $ = i(S, "onActivate"),
|
|
2578
|
-
|
|
2577
|
+
var $ = i(S, "onActivate"), A = i(S, "onPostActivate"), B = i(S, "checkCanFocusTrap");
|
|
2578
|
+
B || d(), o.active = !0, o.paused = !1, o.nodeFocusedBeforeActivation = t.activeElement, $ == null || $();
|
|
2579
2579
|
var C = function() {
|
|
2580
|
-
|
|
2580
|
+
B && d(), g(), M(), A == null || A();
|
|
2581
2581
|
};
|
|
2582
|
-
return
|
|
2582
|
+
return B ? (B(o.containers.concat()).then(C, C), this) : (C(), this);
|
|
2583
2583
|
},
|
|
2584
2584
|
deactivate: function(S) {
|
|
2585
2585
|
if (!o.active)
|
|
@@ -2589,12 +2589,12 @@ var bl = {
|
|
|
2589
2589
|
onPostDeactivate: s.onPostDeactivate,
|
|
2590
2590
|
checkCanReturnFocus: s.checkCanReturnFocus
|
|
2591
2591
|
}, S);
|
|
2592
|
-
clearTimeout(o.delayInitialFocusTimer), o.delayInitialFocusTimer = void 0, u(), o.active = !1, o.paused = !1,
|
|
2593
|
-
var
|
|
2594
|
-
|
|
2592
|
+
clearTimeout(o.delayInitialFocusTimer), o.delayInitialFocusTimer = void 0, u(), o.active = !1, o.paused = !1, M(), bl.deactivateTrap(n, r);
|
|
2593
|
+
var A = i($, "onDeactivate"), B = i($, "onPostDeactivate"), C = i($, "checkCanReturnFocus"), R = i($, "returnFocus", "returnFocusOnDeactivate");
|
|
2594
|
+
A == null || A();
|
|
2595
2595
|
var Y = function() {
|
|
2596
2596
|
yl(function() {
|
|
2597
|
-
R && w(O(o.nodeFocusedBeforeActivation)),
|
|
2597
|
+
R && w(O(o.nodeFocusedBeforeActivation)), B == null || B();
|
|
2598
2598
|
});
|
|
2599
2599
|
};
|
|
2600
2600
|
return R && C ? (C(O(o.nodeFocusedBeforeActivation)).then(Y, Y), this) : (Y(), this);
|
|
@@ -2602,20 +2602,20 @@ var bl = {
|
|
|
2602
2602
|
pause: function(S) {
|
|
2603
2603
|
if (o.paused || !o.active)
|
|
2604
2604
|
return this;
|
|
2605
|
-
var $ = i(S, "onPause"),
|
|
2606
|
-
return o.paused = !0, $ == null || $(), u(),
|
|
2605
|
+
var $ = i(S, "onPause"), A = i(S, "onPostPause");
|
|
2606
|
+
return o.paused = !0, $ == null || $(), u(), M(), A == null || A(), this;
|
|
2607
2607
|
},
|
|
2608
2608
|
unpause: function(S) {
|
|
2609
2609
|
if (!o.paused || !o.active)
|
|
2610
2610
|
return this;
|
|
2611
|
-
var $ = i(S, "onUnpause"),
|
|
2612
|
-
return o.paused = !1, $ == null || $(), d(), g(),
|
|
2611
|
+
var $ = i(S, "onUnpause"), A = i(S, "onPostUnpause");
|
|
2612
|
+
return o.paused = !1, $ == null || $(), d(), g(), M(), A == null || A(), this;
|
|
2613
2613
|
},
|
|
2614
2614
|
updateContainerElements: function(S) {
|
|
2615
2615
|
var $ = [].concat(S).filter(Boolean);
|
|
2616
|
-
return o.containers = $.map(function(
|
|
2617
|
-
return typeof
|
|
2618
|
-
}), o.active && d(),
|
|
2616
|
+
return o.containers = $.map(function(A) {
|
|
2617
|
+
return typeof A == "string" ? t.querySelector(A) : A;
|
|
2618
|
+
}), o.active && d(), M(), this;
|
|
2619
2619
|
}
|
|
2620
2620
|
}, r.updateContainerElements(e), r;
|
|
2621
2621
|
};
|
|
@@ -2684,7 +2684,7 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2684
2684
|
c.key === "Escape" && r();
|
|
2685
2685
|
}
|
|
2686
2686
|
return (c, f) => (p(), T(J, null, [
|
|
2687
|
-
|
|
2687
|
+
x(c.$slots, "trigger", de(ve({ open: o }))),
|
|
2688
2688
|
(p(), Z(ol, { to: "body" }, [
|
|
2689
2689
|
E($e, { name: "fade" }, {
|
|
2690
2690
|
default: Q(() => [
|
|
@@ -2703,7 +2703,7 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2703
2703
|
}]
|
|
2704
2704
|
}), [
|
|
2705
2705
|
ee(b("div", {
|
|
2706
|
-
class:
|
|
2706
|
+
class: U(["cl-absolute cl-cursor-pointer cl-right-4 cl-top-4 cl-transition-colors cl-w-3", {
|
|
2707
2707
|
"cl-text-white hover:cl-text-off-white": c.headerColour === "secondary",
|
|
2708
2708
|
"cl-text-secondary hover:cl-text-off-white": c.headerColour === "primary",
|
|
2709
2709
|
"cl-text-black hover:cl-text-grey-7": c.headerColour === "white"
|
|
@@ -2717,18 +2717,18 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2717
2717
|
[te, !c.preventClose]
|
|
2718
2718
|
]),
|
|
2719
2719
|
b("div", {
|
|
2720
|
-
class:
|
|
2720
|
+
class: U(["cl-leading-[2.75rem] cl-min-h-12 cl-overflow-hidden cl-pb-2 cl-pl-4 cl-pr-8 cl-pt-2 cl-text-2xl cl-w-full", {
|
|
2721
2721
|
"cl-bg-secondary-default cl-text-white": c.headerColour === "secondary",
|
|
2722
2722
|
"cl-bg-primary-default cl-text-secondary": c.headerColour === "primary"
|
|
2723
2723
|
}])
|
|
2724
2724
|
}, [
|
|
2725
|
-
|
|
2726
|
-
c.headerColour === "white" ? (p(), T("hr", nn)) :
|
|
2725
|
+
x(c.$slots, "title"),
|
|
2726
|
+
c.headerColour === "white" ? (p(), T("hr", nn)) : P("", !0)
|
|
2727
2727
|
], 2),
|
|
2728
2728
|
b("div", on, [
|
|
2729
|
-
|
|
2729
|
+
x(c.$slots, "default", de(ve({ close: r })))
|
|
2730
2730
|
]),
|
|
2731
|
-
|
|
2731
|
+
x(c.$slots, "footer", de(ve({ close: r })))
|
|
2732
2732
|
], 16)
|
|
2733
2733
|
], 512), [
|
|
2734
2734
|
[te, t.value]
|
|
@@ -2754,13 +2754,13 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2754
2754
|
},
|
|
2755
2755
|
setup(a) {
|
|
2756
2756
|
return (e, l) => (p(), T("div", rn, [
|
|
2757
|
-
e.additionalText !== "" ? (p(), T("div", sn,
|
|
2757
|
+
e.additionalText !== "" ? (p(), T("div", sn, I(e.additionalText), 1)) : P("", !0),
|
|
2758
2758
|
b("div", {
|
|
2759
|
-
class:
|
|
2759
|
+
class: U({
|
|
2760
2760
|
"cl-w-1/2": e.additionalText !== "",
|
|
2761
2761
|
"cl-w-full": e.additionalText === ""
|
|
2762
2762
|
})
|
|
2763
|
-
},
|
|
2763
|
+
}, I(e.text), 3),
|
|
2764
2764
|
ee(b("div", {
|
|
2765
2765
|
class: "cl-cursor-pointer cl-float-right",
|
|
2766
2766
|
onMousedown: l[0] || (l[0] = (t) => e.$emit("clear-object"))
|
|
@@ -2792,10 +2792,10 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2792
2792
|
"option-highlighted": null
|
|
2793
2793
|
},
|
|
2794
2794
|
setup(a, { emit: e }) {
|
|
2795
|
-
const l = a, t =
|
|
2795
|
+
const l = a, t = F(() => {
|
|
2796
2796
|
var c;
|
|
2797
2797
|
return ((c = l.option) == null ? void 0 : c.name) ?? l.text;
|
|
2798
|
-
}), n =
|
|
2798
|
+
}), n = F(() => {
|
|
2799
2799
|
var c;
|
|
2800
2800
|
return ((c = l.option) == null ? void 0 : c.parentName) ?? "";
|
|
2801
2801
|
}), s = V(!1);
|
|
@@ -2812,7 +2812,7 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2812
2812
|
return ae(() => l.selectedIndex, () => i()), (c, f) => {
|
|
2813
2813
|
var v, d;
|
|
2814
2814
|
return p(), T("div", {
|
|
2815
|
-
class:
|
|
2815
|
+
class: U(["cl-cursor-pointer cl-duration-75 cl-flex cl-p-1 cl-text-left cl-transition-colors", {
|
|
2816
2816
|
"cl-bg-white": s.value === !1,
|
|
2817
2817
|
"cl-bg-link-light cl-text-white cl-opacity-90": s.value && c.isCreateNewOption === !1,
|
|
2818
2818
|
"cl-bg-primary-default cl-text-black cl-opacity-90": s.value && c.isCreateNewOption
|
|
@@ -2821,13 +2821,13 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2821
2821
|
onMousemove: f[0] || (f[0] = (w) => r(!0)),
|
|
2822
2822
|
onMouseleave: f[1] || (f[1] = (w) => r(!1))
|
|
2823
2823
|
}, [
|
|
2824
|
-
c.option !== null && ((v = c.option) == null ? void 0 : v.parentId) !== 0 && ((d = c.option) == null ? void 0 : d.parentId) !== void 0 ? (p(), T("div", cn,
|
|
2824
|
+
c.option !== null && ((v = c.option) == null ? void 0 : v.parentId) !== 0 && ((d = c.option) == null ? void 0 : d.parentId) !== void 0 ? (p(), T("div", cn, I(n.value), 1)) : P("", !0),
|
|
2825
2825
|
b("div", {
|
|
2826
|
-
class:
|
|
2826
|
+
class: U({
|
|
2827
2827
|
"cl-w-1/2": n.value !== "",
|
|
2828
2828
|
"cl-w-full": n.value === ""
|
|
2829
2829
|
})
|
|
2830
|
-
},
|
|
2830
|
+
}, I(t.value), 3),
|
|
2831
2831
|
ee(b("div", un, [
|
|
2832
2832
|
E(h(H), {
|
|
2833
2833
|
class: "cl-transition-colors",
|
|
@@ -2861,7 +2861,7 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2861
2861
|
"hide-dropdown": null
|
|
2862
2862
|
},
|
|
2863
2863
|
setup(a, { emit: e }) {
|
|
2864
|
-
const l = a, { t } = ce(), n = V(""), s = V(!1), o = V(-1), r =
|
|
2864
|
+
const l = a, { t } = ce(), n = V(""), s = V(!1), o = V(-1), r = F(() => s.value ? -1 : 0), i = V();
|
|
2865
2865
|
function c(g) {
|
|
2866
2866
|
(g === void 0 || (g == null ? void 0 : g.code.startsWith("Arrow")) === !1 && (g == null ? void 0 : g.code.startsWith("Control")) === !1 && (g == null ? void 0 : g.code.startsWith("Shift")) === !1 && (g == null ? void 0 : g.code.startsWith("Tab")) === !1 && (g == null ? void 0 : g.code) !== "Enter") && (e("search", n.value), o.value = -2);
|
|
2867
2867
|
}
|
|
@@ -2875,15 +2875,15 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2875
2875
|
e("hide-dropdown");
|
|
2876
2876
|
}
|
|
2877
2877
|
function w(g) {
|
|
2878
|
-
o.value < l.results.length - 1 ? (o.value === -2 && n.value === "" && o.value++, o.value++) : o.value = g,
|
|
2878
|
+
o.value < l.results.length - 1 ? (o.value === -2 && n.value === "" && o.value++, o.value++) : o.value = g, z();
|
|
2879
2879
|
}
|
|
2880
2880
|
function O(g) {
|
|
2881
|
-
o.value > g ? o.value-- : o.value = l.results.length - 1,
|
|
2881
|
+
o.value > g ? o.value-- : o.value = l.results.length - 1, z();
|
|
2882
2882
|
}
|
|
2883
|
-
function
|
|
2883
|
+
function D() {
|
|
2884
2884
|
o.value >= 0 && l.results !== void 0 ? f(l.results[o.value].id) : o.value === -1 && v();
|
|
2885
2885
|
}
|
|
2886
|
-
function
|
|
2886
|
+
function N(g) {
|
|
2887
2887
|
if (g.key === "Tab" && g.shiftKey === !0) {
|
|
2888
2888
|
const u = document.getElementsByTagName("input");
|
|
2889
2889
|
let m = -1;
|
|
@@ -2892,11 +2892,11 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2892
2892
|
m >= 0 && (u[m].focus(), d());
|
|
2893
2893
|
}
|
|
2894
2894
|
}
|
|
2895
|
-
function
|
|
2895
|
+
function z() {
|
|
2896
2896
|
var g;
|
|
2897
2897
|
l.results && l.results.length > 1 && ((g = i.value) == null || g.scrollTo(0, (o.value + 1) * 34 - 34 * 2));
|
|
2898
2898
|
}
|
|
2899
|
-
function
|
|
2899
|
+
function q() {
|
|
2900
2900
|
let g = !1;
|
|
2901
2901
|
l.results !== null && l.results.length === 1 && (g = n.value.toUpperCase().trim() === l.results[0].name.toUpperCase().trim()), s.value = l.canCreateNewObject === !0 && l.errorMessage === "" && n.value.trim() !== "" && g === !1;
|
|
2902
2902
|
}
|
|
@@ -2909,12 +2909,12 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2909
2909
|
return (u = (g = i.value) == null ? void 0 : g.querySelector("input")) == null ? void 0 : u.focus();
|
|
2910
2910
|
}));
|
|
2911
2911
|
}
|
|
2912
|
-
return ae(() => l.results, () =>
|
|
2912
|
+
return ae(() => l.results, () => q()), ae(() => l.errorMessage, () => q()), ae(() => l.isVisible, () => re()), Qe(() => {
|
|
2913
2913
|
var g;
|
|
2914
|
-
return (g = i.value) == null ? void 0 : g.addEventListener("keydown",
|
|
2914
|
+
return (g = i.value) == null ? void 0 : g.addEventListener("keydown", N);
|
|
2915
2915
|
}), rl(() => {
|
|
2916
2916
|
var g;
|
|
2917
|
-
return (g = i.value) == null ? void 0 : g.removeEventListener("keydown",
|
|
2917
|
+
return (g = i.value) == null ? void 0 : g.removeEventListener("keydown", N);
|
|
2918
2918
|
}), (g, u) => {
|
|
2919
2919
|
var m;
|
|
2920
2920
|
return p(), T("div", {
|
|
@@ -2925,7 +2925,7 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2925
2925
|
u[2] || (u[2] = Ae(oe((k) => O(r.value), ["prevent", "stop"]), ["up"])),
|
|
2926
2926
|
u[3] || (u[3] = Ae(oe((k) => w(r.value), ["prevent", "stop"]), ["down"]))
|
|
2927
2927
|
],
|
|
2928
|
-
onKeyup: Ae(oe(
|
|
2928
|
+
onKeyup: Ae(oe(D, ["prevent", "stop"]), ["enter"])
|
|
2929
2929
|
}, [
|
|
2930
2930
|
b("div", fn, [
|
|
2931
2931
|
E(me, {
|
|
@@ -2946,22 +2946,22 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2946
2946
|
"show-clear-button": g.canClearSelectedObject,
|
|
2947
2947
|
text: g.currentObjectName,
|
|
2948
2948
|
onClearObject: u[1] || (u[1] = (k) => g.$emit("clear-object"))
|
|
2949
|
-
}, null, 8, ["show-clear-button", "text"])) :
|
|
2949
|
+
}, null, 8, ["show-clear-button", "text"])) : P("", !0),
|
|
2950
2950
|
g.objectParentType !== "" && g.results !== void 0 && g.results.length > 0 && g.errorMessage === "" ? (p(), Z(ze, {
|
|
2951
2951
|
key: 1,
|
|
2952
2952
|
text: g.objectType,
|
|
2953
2953
|
"additional-text": g.objectParentType,
|
|
2954
2954
|
class: "cl-bg-grey-2 cl-mt-1"
|
|
2955
|
-
}, null, 8, ["text", "additional-text"])) :
|
|
2955
|
+
}, null, 8, ["text", "additional-text"])) : P("", !0),
|
|
2956
2956
|
g.results !== null && ((m = g.results) == null ? void 0 : m.length) === 0 && n.value.trim() !== "" && g.canCreateNewObject === !1 && g.errorMessage === "" ? (p(), Z(ze, {
|
|
2957
2957
|
key: 2,
|
|
2958
2958
|
text: h(t)("comboBox.noResults", { value: n.value })
|
|
2959
|
-
}, null, 8, ["text"])) :
|
|
2959
|
+
}, null, 8, ["text"])) : P("", !0),
|
|
2960
2960
|
g.errorMessage !== "" ? (p(), Z(ze, {
|
|
2961
2961
|
key: 3,
|
|
2962
2962
|
class: "!cl-bg-danger-light cl-border-danger-light cl-rounded cl-text-danger-dark",
|
|
2963
2963
|
text: h(t)("comboBox.errorMessage", { error: g.errorMessage })
|
|
2964
|
-
}, null, 8, ["text"])) :
|
|
2964
|
+
}, null, 8, ["text"])) : P("", !0),
|
|
2965
2965
|
s.value ? (p(), Z(kl, {
|
|
2966
2966
|
key: 4,
|
|
2967
2967
|
"is-create-new-option": !0,
|
|
@@ -2971,18 +2971,18 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
2971
2971
|
class: "cl-px-2",
|
|
2972
2972
|
onCreateObject: v,
|
|
2973
2973
|
onOptionHighlighted: le
|
|
2974
|
-
}, null, 8, ["text", "selected-index"])) :
|
|
2974
|
+
}, null, 8, ["text", "selected-index"])) : P("", !0),
|
|
2975
2975
|
g.errorMessage === "" && g.results !== null ? (p(), T("div", pn, [
|
|
2976
|
-
(p(!0), T(J, null, se(g.results, (k,
|
|
2977
|
-
key:
|
|
2976
|
+
(p(!0), T(J, null, se(g.results, (k, M) => (p(), Z(kl, {
|
|
2977
|
+
key: M,
|
|
2978
2978
|
option: k,
|
|
2979
|
-
index:
|
|
2979
|
+
index: M,
|
|
2980
2980
|
class: "cl-px-2",
|
|
2981
2981
|
"selected-index": o.value,
|
|
2982
2982
|
onSelectObject: f,
|
|
2983
2983
|
onOptionHighlighted: le
|
|
2984
2984
|
}, null, 8, ["option", "index", "selected-index"]))), 128))
|
|
2985
|
-
])) :
|
|
2985
|
+
])) : P("", !0)
|
|
2986
2986
|
], 40, dn);
|
|
2987
2987
|
};
|
|
2988
2988
|
}
|
|
@@ -3015,27 +3015,27 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
3015
3015
|
"update:current-object": null
|
|
3016
3016
|
},
|
|
3017
3017
|
setup(a, { expose: e, emit: l }) {
|
|
3018
|
-
const t = a, n =
|
|
3018
|
+
const t = a, n = F(() => t.placeholderText ? t.placeholderText : o("comboBox.emptyHintText", { object: t.objectType })), s = F(() => t.searchHint ? t.searchHint : o("comboBox.searchHint", { object: t.objectType })), { t: o } = ce(), r = V(!1), i = F({
|
|
3019
3019
|
get: () => t.currentObject,
|
|
3020
3020
|
set: (C) => l("update:current-object", C)
|
|
3021
|
-
}), c = V(null), f = V(null), v =
|
|
3022
|
-
function
|
|
3021
|
+
}), c = V(null), f = V(null), v = F(() => $()), d = V(""), w = V(""), O = V(), D = V(!0), N = V(!1);
|
|
3022
|
+
function z(C) {
|
|
3023
3023
|
var Y, W;
|
|
3024
|
-
const R = ((Y =
|
|
3025
|
-
|
|
3024
|
+
const R = ((Y = B.value) == null ? void 0 : Y.getBoundingClientRect().top) || 0;
|
|
3025
|
+
N.value = window.innerHeight - R < 280, t.disabled || (typeof C < "u" ? r.value = C : r.value = !r.value), (W = c.value) == null || W.blur();
|
|
3026
3026
|
}
|
|
3027
|
-
function
|
|
3027
|
+
function q(C) {
|
|
3028
3028
|
d.value = C, l("search", C);
|
|
3029
3029
|
}
|
|
3030
3030
|
function le(C) {
|
|
3031
3031
|
w.value = C, l("search-parent", C);
|
|
3032
3032
|
}
|
|
3033
3033
|
function re() {
|
|
3034
|
-
i.value = null,
|
|
3034
|
+
i.value = null, z(!1);
|
|
3035
3035
|
}
|
|
3036
3036
|
function g(C) {
|
|
3037
3037
|
const R = u(C);
|
|
3038
|
-
i.value = R,
|
|
3038
|
+
i.value = R, z(!1);
|
|
3039
3039
|
}
|
|
3040
3040
|
function u(C) {
|
|
3041
3041
|
let R = null;
|
|
@@ -3061,7 +3061,7 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
3061
3061
|
parentId: 0
|
|
3062
3062
|
}, l("create-parent-object", O.value);
|
|
3063
3063
|
}
|
|
3064
|
-
function
|
|
3064
|
+
function M() {
|
|
3065
3065
|
var C, R;
|
|
3066
3066
|
(C = t.objectCreatedResponse) != null && C.error ? dl({
|
|
3067
3067
|
message: o("comboBox.createFailed", { name: d.value, error: t.objectCreatedResponse.error }),
|
|
@@ -3069,7 +3069,7 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
3069
3069
|
duration: 1e4
|
|
3070
3070
|
}) : (R = t.objectCreatedResponse) != null && R.id && S();
|
|
3071
3071
|
}
|
|
3072
|
-
function
|
|
3072
|
+
function L() {
|
|
3073
3073
|
var C;
|
|
3074
3074
|
(C = t.parentObjectCreatedResponse) != null && C.id && (f.value = {
|
|
3075
3075
|
id: t.parentObjectCreatedResponse.id,
|
|
@@ -3095,22 +3095,22 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
3095
3095
|
let C = "";
|
|
3096
3096
|
return i.value && (i.value.parentName ? C = i.value.parentName + "; " + i.value.name : C = i.value.name), C;
|
|
3097
3097
|
}
|
|
3098
|
-
function
|
|
3098
|
+
function A() {
|
|
3099
3099
|
let C = !0;
|
|
3100
|
-
d.value === "" && (C = !1), t.objectParentType !== "" && f.value === null && (C = !1),
|
|
3100
|
+
d.value === "" && (C = !1), t.objectParentType !== "" && f.value === null && (C = !1), D.value = C;
|
|
3101
3101
|
}
|
|
3102
|
-
ae(() => t.objectCreatedResponse, () =>
|
|
3102
|
+
ae(() => t.objectCreatedResponse, () => M()), ae(() => t.parentObjectCreatedResponse, () => L()), ae(() => d.value, () => A()), ae(() => f.value, () => A()), e({
|
|
3103
3103
|
focus() {
|
|
3104
3104
|
var C;
|
|
3105
3105
|
(C = c.value) == null || C.focus();
|
|
3106
3106
|
}
|
|
3107
3107
|
});
|
|
3108
|
-
const
|
|
3109
|
-
return cl(
|
|
3108
|
+
const B = V();
|
|
3109
|
+
return cl(B, () => r.value ? z(!1) : ""), (C, R) => {
|
|
3110
3110
|
const Y = Cl("cl-ui-combo-box", !0);
|
|
3111
3111
|
return p(), T("div", {
|
|
3112
3112
|
ref_key: "outsideRef",
|
|
3113
|
-
ref:
|
|
3113
|
+
ref: B,
|
|
3114
3114
|
class: "cl-relative"
|
|
3115
3115
|
}, [
|
|
3116
3116
|
b("div", vn, [
|
|
@@ -3119,18 +3119,18 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
3119
3119
|
ref: c,
|
|
3120
3120
|
modelValue: v.value,
|
|
3121
3121
|
"onUpdate:modelValue": R[0] || (R[0] = (W) => v.value = W),
|
|
3122
|
-
class:
|
|
3122
|
+
class: U(["!cl-mr-0 cl-mb-0 cl-rounded-r-none cl-w-full cl-z-10", {
|
|
3123
3123
|
"cl-cursor-pointer": C.disabled === !1
|
|
3124
3124
|
}]),
|
|
3125
3125
|
"input-type": "text",
|
|
3126
3126
|
"placeholder-text": n.value,
|
|
3127
3127
|
onFocus: R[1] || (R[1] = (W) => {
|
|
3128
|
-
|
|
3128
|
+
z(), C.$emit("focus");
|
|
3129
3129
|
})
|
|
3130
3130
|
}, null, 8, ["modelValue", "class", "placeholder-text"]),
|
|
3131
3131
|
ee(b("div", hn, [
|
|
3132
3132
|
b("div", gn, [
|
|
3133
|
-
pe(
|
|
3133
|
+
pe(I(h(o)("comboBox.required")) + " ", 1),
|
|
3134
3134
|
E(h(H), {
|
|
3135
3135
|
class: "cl-ml-1 cl-mt-1",
|
|
3136
3136
|
icon: "ph:warning"
|
|
@@ -3141,11 +3141,11 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
3141
3141
|
]),
|
|
3142
3142
|
r.value ? (p(), T("div", {
|
|
3143
3143
|
key: 1,
|
|
3144
|
-
class:
|
|
3144
|
+
class: U(["cl-bg-white cl-border cl-border-grey-1 cl-float-right cl-h-10 cl-rounded cl-rounded-l-none cl-text-grey-3 cl-transition-colors cl-w-[27px] hover:cl-bg-link-light hover:cl-opacity-90 hover:cl-text-white", {
|
|
3145
3145
|
"cl-cursor-default": C.disabled,
|
|
3146
3146
|
"cl-cursor-pointer": C.disabled === !1
|
|
3147
3147
|
}]),
|
|
3148
|
-
onClick: R[3] || (R[3] = (W) =>
|
|
3148
|
+
onClick: R[3] || (R[3] = (W) => z(!1))
|
|
3149
3149
|
}, [
|
|
3150
3150
|
E(h(H), {
|
|
3151
3151
|
icon: "ph:caret-up-bold",
|
|
@@ -3153,11 +3153,11 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
3153
3153
|
})
|
|
3154
3154
|
], 2)) : (p(), T("div", {
|
|
3155
3155
|
key: 0,
|
|
3156
|
-
class:
|
|
3156
|
+
class: U(["cl-bg-white cl-border cl-border-grey-1 cl-float-right cl-h-10 cl-rounded cl-rounded-l-none cl-text-grey-3 cl-transition-colors cl-w-[27px] hover:cl-bg-link-light hover:cl-opacity-90 hover:cl-text-white", {
|
|
3157
3157
|
"cl-cursor-default": C.disabled,
|
|
3158
3158
|
"cl-cursor-pointer": C.disabled === !1
|
|
3159
3159
|
}]),
|
|
3160
|
-
onClick: R[2] || (R[2] = (W) =>
|
|
3160
|
+
onClick: R[2] || (R[2] = (W) => z(!0))
|
|
3161
3161
|
}, [
|
|
3162
3162
|
E(h(H), {
|
|
3163
3163
|
icon: "ph:caret-down-bold",
|
|
@@ -3167,7 +3167,7 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
3167
3167
|
]),
|
|
3168
3168
|
E(Pl, { size: "small" }, {
|
|
3169
3169
|
title: Q(() => [
|
|
3170
|
-
pe(
|
|
3170
|
+
pe(I(h(o)("comboBox.createTitle", { object: C.objectType })), 1)
|
|
3171
3171
|
]),
|
|
3172
3172
|
trigger: Q(({ open: W }) => [
|
|
3173
3173
|
ee(E(mn, {
|
|
@@ -3180,15 +3180,15 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
3180
3180
|
"error-message": C.errorMessage,
|
|
3181
3181
|
"current-object-name": v.value,
|
|
3182
3182
|
"is-visible": r.value,
|
|
3183
|
-
class:
|
|
3184
|
-
"cl-bottom-full":
|
|
3183
|
+
class: U({
|
|
3184
|
+
"cl-bottom-full": N.value
|
|
3185
3185
|
}),
|
|
3186
3186
|
"search-hint": s.value,
|
|
3187
3187
|
onCreateObject: () => C.objectParentType === "" && C.skipObjectCreationModal === !0 ? m() : W(),
|
|
3188
3188
|
onSelectObject: g,
|
|
3189
3189
|
onClearObject: re,
|
|
3190
|
-
onSearch:
|
|
3191
|
-
onHideDropdown: R[4] || (R[4] = (ne) =>
|
|
3190
|
+
onSearch: q,
|
|
3191
|
+
onHideDropdown: R[4] || (R[4] = (ne) => z(!1))
|
|
3192
3192
|
}, null, 8, ["can-create-new-object", "can-clear-selected-object", "loading", "results", "object-type", "object-parent-type", "error-message", "current-object-name", "is-visible", "class", "search-hint", "onCreateObject"]), [
|
|
3193
3193
|
[te, r.value]
|
|
3194
3194
|
])
|
|
@@ -3202,20 +3202,20 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
3202
3202
|
onClick: W
|
|
3203
3203
|
}, {
|
|
3204
3204
|
default: Q(() => [
|
|
3205
|
-
pe(
|
|
3205
|
+
pe(I(h(o)("comboBox.cancel")), 1)
|
|
3206
3206
|
]),
|
|
3207
3207
|
_: 2
|
|
3208
3208
|
}, 1032, ["onClick"]),
|
|
3209
3209
|
E(be, {
|
|
3210
3210
|
colour: "primary",
|
|
3211
3211
|
size: "small",
|
|
3212
|
-
disabled: !
|
|
3212
|
+
disabled: !D.value,
|
|
3213
3213
|
onClick: (ne) => {
|
|
3214
3214
|
m(), W();
|
|
3215
3215
|
}
|
|
3216
3216
|
}, {
|
|
3217
3217
|
default: Q(() => [
|
|
3218
|
-
pe(
|
|
3218
|
+
pe(I(h(o)("comboBox.create")), 1)
|
|
3219
3219
|
]),
|
|
3220
3220
|
_: 2
|
|
3221
3221
|
}, 1032, ["disabled", "onClick"])
|
|
@@ -3237,7 +3237,7 @@ const tn = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), an = ["onKeypr
|
|
|
3237
3237
|
"error-message": C.errorMessage,
|
|
3238
3238
|
onSearch: le,
|
|
3239
3239
|
onCreateObject: k
|
|
3240
|
-
}, null, 8, ["current-object", "results", "loading", "object-type", "object-created-response", "can-create-new-object", "can-clear-selected-object", "error-message"])) :
|
|
3240
|
+
}, null, 8, ["current-object", "results", "loading", "object-type", "object-created-response", "can-create-new-object", "can-clear-selected-object", "error-message"])) : P("", !0),
|
|
3241
3241
|
E(me, {
|
|
3242
3242
|
modelValue: d.value,
|
|
3243
3243
|
"onUpdate:modelValue": R[6] || (R[6] = (W) => d.value = W),
|
|
@@ -3269,16 +3269,16 @@ const $n = {}, Sn = { class: "cl-flex cl-flex-wrap cl-left-0 cl-mt-4 cl-w-full"
|
|
|
3269
3269
|
function Dn(a, e) {
|
|
3270
3270
|
return p(), T("div", Sn, [
|
|
3271
3271
|
a.$slots.default ? (p(), T("div", Cn, [
|
|
3272
|
-
|
|
3273
|
-
])) :
|
|
3272
|
+
x(a.$slots, "default")
|
|
3273
|
+
])) : P("", !0),
|
|
3274
3274
|
a.$slots.left || a.$slots.right ? (p(), T("div", On, [
|
|
3275
3275
|
b("span", En, [
|
|
3276
|
-
|
|
3276
|
+
x(a.$slots, "left")
|
|
3277
3277
|
]),
|
|
3278
3278
|
b("span", Nn, [
|
|
3279
|
-
|
|
3279
|
+
x(a.$slots, "right")
|
|
3280
3280
|
])
|
|
3281
|
-
])) :
|
|
3281
|
+
])) : P("", !0)
|
|
3282
3282
|
]);
|
|
3283
3283
|
}
|
|
3284
3284
|
const Fn = /* @__PURE__ */ Te($n, [["render", Dn]]), zl = Symbol();
|
|
@@ -3311,14 +3311,14 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3311
3311
|
},
|
|
3312
3312
|
emits: ["update:edit-mode", "update:filterPanelOpen", "clear-filters"],
|
|
3313
3313
|
setup(a) {
|
|
3314
|
-
const e = a, { t: l } = ce(), t =
|
|
3314
|
+
const e = a, { t: l } = ce(), t = F(() => e.request.filters.some((n) => n.filterValue !== ""));
|
|
3315
3315
|
return (n, s) => (p(), T(J, null, [
|
|
3316
3316
|
b("div", In, [
|
|
3317
|
-
b("strong", null,
|
|
3317
|
+
b("strong", null, I(h(l)("grid.gridTools")), 1)
|
|
3318
3318
|
]),
|
|
3319
3319
|
b("div", Rn, [
|
|
3320
3320
|
b("div", Vn, [
|
|
3321
|
-
|
|
3321
|
+
x(n.$slots, "additional-grid-actions", de(ve({
|
|
3322
3322
|
loading: n.loading,
|
|
3323
3323
|
editMode: n.editMode
|
|
3324
3324
|
})))
|
|
@@ -3333,15 +3333,15 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3333
3333
|
}, {
|
|
3334
3334
|
default: Q(() => [
|
|
3335
3335
|
n.editMode ? (p(), T(J, { key: 0 }, [
|
|
3336
|
-
pe(
|
|
3336
|
+
pe(I(h(l)("grid.finishEditing")), 1)
|
|
3337
3337
|
], 64)) : (p(), T(J, { key: 1 }, [
|
|
3338
|
-
pe(
|
|
3338
|
+
pe(I(h(l)("grid.editData")), 1)
|
|
3339
3339
|
], 64))
|
|
3340
3340
|
]),
|
|
3341
3341
|
_: 1
|
|
3342
|
-
}, 8, ["disabled"])) :
|
|
3343
|
-
n.options.hideViewManager ?
|
|
3344
|
-
|
|
3342
|
+
}, 8, ["disabled"])) : P("", !0),
|
|
3343
|
+
n.options.hideViewManager ? P("", !0) : (p(), T("div", Mn, [
|
|
3344
|
+
x(n.$slots, "view-manager")
|
|
3345
3345
|
])),
|
|
3346
3346
|
h(Tl)(n.columns) || h(An)(n.columns) ? (p(), T(J, { key: 2 }, [
|
|
3347
3347
|
b("div", Ln, [
|
|
@@ -3352,7 +3352,7 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3352
3352
|
onClick: s[1] || (s[1] = oe((o) => n.$emit("update:filterPanelOpen", !n.filterPanelOpen), ["prevent"]))
|
|
3353
3353
|
}, {
|
|
3354
3354
|
default: Q(() => [
|
|
3355
|
-
pe(
|
|
3355
|
+
pe(I(h(l)("grid.modifyFilters")), 1)
|
|
3356
3356
|
]),
|
|
3357
3357
|
_: 1
|
|
3358
3358
|
}, 8, ["disabled"])
|
|
@@ -3362,17 +3362,17 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3362
3362
|
size: "small",
|
|
3363
3363
|
colour: "danger",
|
|
3364
3364
|
disabled: !t.value || n.loading,
|
|
3365
|
-
class:
|
|
3365
|
+
class: U({
|
|
3366
3366
|
"cl-col-span-2": n.columns.some((o) => o.editable)
|
|
3367
3367
|
}),
|
|
3368
3368
|
onClick: s[2] || (s[2] = oe((o) => n.$emit("clear-filters"), ["prevent"]))
|
|
3369
3369
|
}, {
|
|
3370
3370
|
default: Q(() => [
|
|
3371
|
-
pe(
|
|
3371
|
+
pe(I(h(l)("grid.clearFilters")), 1)
|
|
3372
3372
|
]),
|
|
3373
3373
|
_: 1
|
|
3374
|
-
}, 8, ["disabled", "class"])) :
|
|
3375
|
-
], 64)) :
|
|
3374
|
+
}, 8, ["disabled", "class"])) : P("", !0)
|
|
3375
|
+
], 64)) : P("", !0)
|
|
3376
3376
|
])
|
|
3377
3377
|
], 64));
|
|
3378
3378
|
}
|
|
@@ -3433,24 +3433,24 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3433
3433
|
}
|
|
3434
3434
|
return (i, c) => {
|
|
3435
3435
|
var f;
|
|
3436
|
-
return i.column.type === "slot" ?
|
|
3436
|
+
return i.column.type === "slot" ? x(i.$slots, i.column.name, { key: 0 }) : i.column.type === "boolean" && i.column.field !== void 0 ? (p(), Z(me, {
|
|
3437
3437
|
key: 1,
|
|
3438
3438
|
"input-type": "checkbox",
|
|
3439
3439
|
"model-value": i.data[i.column.field],
|
|
3440
3440
|
disabled: !0
|
|
3441
3441
|
}, null, 8, ["model-value"])) : (i.column.type === "date" || i.column.type === "datetime" || i.column.type === "dateRange") && i.column.field !== void 0 ? (p(), T(J, { key: 2 }, [
|
|
3442
3442
|
i.column.format !== void 0 ? (p(), T(J, { key: 0 }, [
|
|
3443
|
-
pe(
|
|
3443
|
+
pe(I(o(i.data[i.column.field], i.column.format)), 1)
|
|
3444
3444
|
], 64)) : i.column.type === "date" || i.column.type === "dateRange" ? (p(), T(J, { key: 1 }, [
|
|
3445
|
-
pe(
|
|
3445
|
+
pe(I(o(i.data[i.column.field], h(ie).DATE)), 1)
|
|
3446
3446
|
], 64)) : (p(), T(J, { key: 2 }, [
|
|
3447
|
-
pe(
|
|
3447
|
+
pe(I(o(i.data[i.column.field], h(ie).DATETIME)), 1)
|
|
3448
3448
|
], 64))
|
|
3449
|
-
], 64)) : i.column.type === "list" && i.column.field !== void 0 && i.column.listEntries !== void 0 ? (p(), T("span", Pn,
|
|
3449
|
+
], 64)) : i.column.type === "list" && i.column.field !== void 0 && i.column.listEntries !== void 0 ? (p(), T("span", Pn, I(h(t)(((f = i.column.listEntries.find((v) => v.value === i.data[i.column.field])) == null ? void 0 : f.translationKey) ?? "")), 1)) : i.column.type === "number" && i.column.field !== void 0 ? (p(), T("span", zn, I(h(s)(i.data[i.column.field], i.column.format ?? h(fe).DECIMAL)), 1)) : i.column.field !== void 0 ? (p(), T("span", Bn, [
|
|
3450
3450
|
b("span", {
|
|
3451
3451
|
innerHTML: r()
|
|
3452
3452
|
}, null, 8, Un)
|
|
3453
|
-
])) :
|
|
3453
|
+
])) : P("", !0);
|
|
3454
3454
|
};
|
|
3455
3455
|
}
|
|
3456
3456
|
}), xn = { class: "cl-font-semibold lg:cl-hidden" }, _n = /* @__PURE__ */ K({
|
|
@@ -3464,7 +3464,7 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3464
3464
|
},
|
|
3465
3465
|
emits: ["edit", "focus", "undo"],
|
|
3466
3466
|
setup(a, { emit: e }) {
|
|
3467
|
-
const l = a, { t } = ce(), n = V(he(l.data)), s =
|
|
3467
|
+
const l = a, { t } = ce(), n = V(he(l.data)), s = F(() => l.column.field !== void 0 && n.value[l.column.field] !== l.data[l.column.field]), o = F(() => {
|
|
3468
3468
|
var r;
|
|
3469
3469
|
return ((r = l.column.listEntries) == null ? void 0 : r.map((i, c) => ({
|
|
3470
3470
|
id: c,
|
|
@@ -3477,12 +3477,12 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3477
3477
|
}, {
|
|
3478
3478
|
deep: !0
|
|
3479
3479
|
}), (r, i) => (p(), T("td", {
|
|
3480
|
-
class:
|
|
3480
|
+
class: U(["cl-border-b cl-border-grey-1 cl-gap-1 cl-grid cl-grid-cols-2 cl-m-1 cl-mb-0 cl-py-2 cl-text-xs lg:cl-border-b-0 lg:cl-m-0 lg:cl-px-1 lg:cl-table-cell lg:cl-text-base", {
|
|
3481
3481
|
"cl-bg-link-lighter": s.value
|
|
3482
3482
|
}])
|
|
3483
3483
|
}, [
|
|
3484
|
-
b("span", xn,
|
|
3485
|
-
r.editMode && r.column.editable === !0 ?
|
|
3484
|
+
b("span", xn, I(r.column.caption), 1),
|
|
3485
|
+
r.editMode && r.column.editable === !0 ? x(r.$slots, `${r.column.name}Edit`, de(ue({ key: 0 }, {
|
|
3486
3486
|
cellFocused: () => e("focus"),
|
|
3487
3487
|
column: r.column,
|
|
3488
3488
|
edited: s.value,
|
|
@@ -3497,7 +3497,7 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3497
3497
|
"search-value": r.searchValue
|
|
3498
3498
|
}, {
|
|
3499
3499
|
[r.column.name]: Q(() => [
|
|
3500
|
-
|
|
3500
|
+
x(r.$slots, r.column.name, de(ve({
|
|
3501
3501
|
column: r.column,
|
|
3502
3502
|
record: r.data,
|
|
3503
3503
|
searchValue: r.searchValue
|
|
@@ -3513,7 +3513,7 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3513
3513
|
"search-value": r.searchValue
|
|
3514
3514
|
}, {
|
|
3515
3515
|
[r.column.name]: Q(() => [
|
|
3516
|
-
|
|
3516
|
+
x(r.$slots, r.column.name, de(ve({ column: r.column, record: r.data, searchValue: r.searchValue })))
|
|
3517
3517
|
]),
|
|
3518
3518
|
_: 2
|
|
3519
3519
|
}, 1032, ["column", "data", "time-zone", "search-value"]))
|
|
@@ -3545,7 +3545,7 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3545
3545
|
se(e.$slots, (s, o) => ({
|
|
3546
3546
|
name: o,
|
|
3547
3547
|
fn: Q((r) => [
|
|
3548
|
-
|
|
3548
|
+
x(e.$slots, o, de(ve(r)))
|
|
3549
3549
|
])
|
|
3550
3550
|
}))
|
|
3551
3551
|
]), 1032, ["data", "column", "time-zone", "search-value", "edit-mode", "onEdit", "onUndo"]))), 128))
|
|
@@ -3592,13 +3592,13 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3592
3592
|
const c = V({});
|
|
3593
3593
|
ae(() => l.data, () => {
|
|
3594
3594
|
var d, w;
|
|
3595
|
-
return c.value = Object.fromEntries(((w = (d = l.data) == null ? void 0 : d.results) == null ? void 0 : w.map((O,
|
|
3596
|
-
[
|
|
3595
|
+
return c.value = Object.fromEntries(((w = (d = l.data) == null ? void 0 : d.results) == null ? void 0 : w.map((O, D) => [
|
|
3596
|
+
[D],
|
|
3597
3597
|
{
|
|
3598
3598
|
count: 0,
|
|
3599
3599
|
target: null,
|
|
3600
3600
|
reset: Ol(() => {
|
|
3601
|
-
c.value[
|
|
3601
|
+
c.value[D] && (c.value[D].count = 0, c.value[D].target = null);
|
|
3602
3602
|
}, 2500, { immediate: !1 })
|
|
3603
3603
|
}
|
|
3604
3604
|
])) ?? []);
|
|
@@ -3607,8 +3607,8 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3607
3607
|
immediate: !0
|
|
3608
3608
|
});
|
|
3609
3609
|
function f(d, w, O) {
|
|
3610
|
-
const { currentTarget:
|
|
3611
|
-
l.options.rowSelectionEnabled ? (v(
|
|
3610
|
+
const { currentTarget: D } = O;
|
|
3611
|
+
l.options.rowSelectionEnabled ? (v(D), e("row-select", w)) : (c.value[d].count++, c.value[d].target = D, c.value[d].count > 1 ? (c.value[d].reset.stop(), c.value[d].count = 0, v(D), c.value[d].target = null, e("row-select", w)) : c.value[d].reset.start());
|
|
3612
3612
|
}
|
|
3613
3613
|
function v(d) {
|
|
3614
3614
|
l.options.highlightRowSelection && (d == null || d.classList.toggle("!cl-bg-link-lighter"));
|
|
@@ -3618,55 +3618,55 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3618
3618
|
}), (d, w) => {
|
|
3619
3619
|
var O;
|
|
3620
3620
|
return p(), T("tbody", null, [
|
|
3621
|
-
d.data && ((O = d.data.results) != null && O.length) ? (p(!0), T(J, { key: 0 }, se(d.data.results, (
|
|
3622
|
-
key:
|
|
3623
|
-
data:
|
|
3621
|
+
d.data && ((O = d.data.results) != null && O.length) ? (p(!0), T(J, { key: 0 }, se(d.data.results, (D, N) => (p(), Z(Hn, {
|
|
3622
|
+
key: N,
|
|
3623
|
+
data: D,
|
|
3624
3624
|
columns: d.columns,
|
|
3625
3625
|
"time-zone": d.timeZone,
|
|
3626
3626
|
"search-value": d.searchValue,
|
|
3627
3627
|
"edit-mode": d.editMode,
|
|
3628
|
-
class:
|
|
3629
|
-
"cl-bg-white":
|
|
3630
|
-
"cl-bg-off-white":
|
|
3628
|
+
class: U(["cl-bg-opacity-100 cl-transition-colors", {
|
|
3629
|
+
"cl-bg-white": N % 2 === 0 && d.data.totalRecords > 1,
|
|
3630
|
+
"cl-bg-off-white": N % 2 === 1 || d.data.totalRecords === 1,
|
|
3631
3631
|
"cl-cursor-pointer": (d.options.highlightRowSelection || d.options.rowSelectionEnabled) && !d.editMode,
|
|
3632
3632
|
"hover:cl-bg-link-lighter": d.options.rowSelectionEnabled && d.options.highlightRowSelection && !d.editMode
|
|
3633
3633
|
}]),
|
|
3634
|
-
onClick: (
|
|
3635
|
-
d.editMode || f(
|
|
3634
|
+
onClick: (z) => {
|
|
3635
|
+
d.editMode || f(N, D, z);
|
|
3636
3636
|
},
|
|
3637
|
-
onCellFocus: (
|
|
3638
|
-
o(
|
|
3637
|
+
onCellFocus: (z) => {
|
|
3638
|
+
o(N);
|
|
3639
3639
|
},
|
|
3640
|
-
onCellEdit: (
|
|
3641
|
-
r(
|
|
3640
|
+
onCellEdit: (z) => {
|
|
3641
|
+
r(N, z);
|
|
3642
3642
|
},
|
|
3643
3643
|
onCellUndo: i
|
|
3644
3644
|
}, il({ _: 2 }, [
|
|
3645
|
-
se(d.$slots, (
|
|
3646
|
-
name:
|
|
3645
|
+
se(d.$slots, (z, q) => ({
|
|
3646
|
+
name: q,
|
|
3647
3647
|
fn: Q((le) => [
|
|
3648
|
-
|
|
3648
|
+
x(d.$slots, q, ue(le, { disabled: d.loading }))
|
|
3649
3649
|
])
|
|
3650
3650
|
}))
|
|
3651
|
-
]), 1032, ["data", "columns", "time-zone", "search-value", "edit-mode", "class", "onClick", "onCellFocus", "onCellEdit"]))), 128)) : d.loading ?
|
|
3651
|
+
]), 1032, ["data", "columns", "time-zone", "search-value", "edit-mode", "class", "onClick", "onCellFocus", "onCellEdit"]))), 128)) : d.loading ? P("", !0) : (p(), T("tr", Gn, [
|
|
3652
3652
|
b("td", {
|
|
3653
3653
|
colspan: d.columns.length
|
|
3654
3654
|
}, [
|
|
3655
3655
|
b("div", Kn, [
|
|
3656
|
-
b("strong", Wn,
|
|
3657
|
-
d.request.filters.some((
|
|
3658
|
-
b("div", Yn,
|
|
3656
|
+
b("strong", Wn, I(h(t)("grid.noData")), 1),
|
|
3657
|
+
d.request.filters.some((D) => D.filterValue !== "") ? (p(), T("div", Qn, [
|
|
3658
|
+
b("div", Yn, I(h(t)("grid.noDataFiltersPresent")), 1),
|
|
3659
3659
|
E(be, {
|
|
3660
3660
|
size: "small",
|
|
3661
3661
|
colour: "danger",
|
|
3662
|
-
onClick: w[0] || (w[0] = oe((
|
|
3662
|
+
onClick: w[0] || (w[0] = oe((D) => d.$emit("clear-filters"), ["prevent"]))
|
|
3663
3663
|
}, {
|
|
3664
3664
|
default: Q(() => [
|
|
3665
|
-
pe(
|
|
3665
|
+
pe(I(h(t)("grid.clearFilters")), 1)
|
|
3666
3666
|
]),
|
|
3667
3667
|
_: 1
|
|
3668
3668
|
})
|
|
3669
|
-
])) :
|
|
3669
|
+
])) : P("", !0)
|
|
3670
3670
|
])
|
|
3671
3671
|
], 8, Zn)
|
|
3672
3672
|
]))
|
|
@@ -3687,10 +3687,10 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3687
3687
|
"update:request": null
|
|
3688
3688
|
},
|
|
3689
3689
|
setup(a, { emit: e }) {
|
|
3690
|
-
const l = a, { n: t, t: n } = ce(), s =
|
|
3690
|
+
const l = a, { n: t, t: n } = ce(), s = F(() => {
|
|
3691
3691
|
var d;
|
|
3692
3692
|
return l.data !== null ? Math.ceil((((d = l.data) == null ? void 0 : d.totalRecords) ?? 0) / l.request.pageSize) : 1;
|
|
3693
|
-
}), o =
|
|
3693
|
+
}), o = F(() => {
|
|
3694
3694
|
const d = Array.from(Array(s.value + 1).keys());
|
|
3695
3695
|
let w = [];
|
|
3696
3696
|
if (d.shift(), d.length) {
|
|
@@ -3721,10 +3721,10 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3721
3721
|
}
|
|
3722
3722
|
const v = sl(i, 750);
|
|
3723
3723
|
return (d, w) => {
|
|
3724
|
-
var O,
|
|
3725
|
-
return (
|
|
3724
|
+
var O, D;
|
|
3725
|
+
return (D = (O = d.data) == null ? void 0 : O.results) != null && D.length && d.request ? (p(), T("div", Xn, [
|
|
3726
3726
|
b("div", eo, [
|
|
3727
|
-
b("span", lo,
|
|
3727
|
+
b("span", lo, I(h(n)("grid.jumpToPage")), 1),
|
|
3728
3728
|
E(me, {
|
|
3729
3729
|
"model-value": d.request.pageNumber,
|
|
3730
3730
|
class: "cl-ml-1 cl-mt-0.5 cl-text-sm",
|
|
@@ -3733,19 +3733,19 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3733
3733
|
"show-label": !1,
|
|
3734
3734
|
min: 1,
|
|
3735
3735
|
max: s.value,
|
|
3736
|
-
onInput: w[0] || (w[0] = (
|
|
3736
|
+
onInput: w[0] || (w[0] = (N) => h(v)(N.target))
|
|
3737
3737
|
}, null, 8, ["model-value", "disabled", "max"])
|
|
3738
3738
|
]),
|
|
3739
3739
|
b("div", to, [
|
|
3740
3740
|
b("div", ao, [
|
|
3741
3741
|
b("li", no, [
|
|
3742
|
-
b("span", oo,
|
|
3742
|
+
b("span", oo, I(h(n)("grid.page")), 1)
|
|
3743
3743
|
]),
|
|
3744
3744
|
b("ul", ro, [
|
|
3745
|
-
b("li", io,
|
|
3745
|
+
b("li", io, I(h(t)(d.request.pageNumber, h(fe).INTEGER)) + " / " + I(h(t)(s.value, h(fe).INTEGER)), 1),
|
|
3746
3746
|
ee(b("li", {
|
|
3747
3747
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
3748
|
-
onClick: w[1] || (w[1] = (
|
|
3748
|
+
onClick: w[1] || (w[1] = (N) => r(1))
|
|
3749
3749
|
}, [
|
|
3750
3750
|
E(h(H), {
|
|
3751
3751
|
icon: "ph:caret-double-left",
|
|
@@ -3756,7 +3756,7 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3756
3756
|
]),
|
|
3757
3757
|
ee(b("li", {
|
|
3758
3758
|
class: "cl-cursor-pointer cl-mt-1 lg:cl-mr-2 mr-1",
|
|
3759
|
-
onClick: w[2] || (w[2] = (
|
|
3759
|
+
onClick: w[2] || (w[2] = (N) => r(d.request.pageNumber - 1))
|
|
3760
3760
|
}, [
|
|
3761
3761
|
E(h(H), {
|
|
3762
3762
|
icon: "ph:caret-left",
|
|
@@ -3765,17 +3765,17 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3765
3765
|
], 512), [
|
|
3766
3766
|
[te, d.request.pageNumber > 1]
|
|
3767
3767
|
]),
|
|
3768
|
-
(p(!0), T(J, null, se(o.value, (
|
|
3769
|
-
key:
|
|
3770
|
-
class:
|
|
3771
|
-
"cl-text-black cl-font-bold": d.request.pageNumber ===
|
|
3772
|
-
"cl-text-grey-6": d.request.pageNumber !==
|
|
3768
|
+
(p(!0), T(J, null, se(o.value, (N, z) => (p(), T("li", {
|
|
3769
|
+
key: z,
|
|
3770
|
+
class: U(["cl-cursor-pointer cl-mr-1 lg:cl-mr-2", {
|
|
3771
|
+
"cl-text-black cl-font-bold": d.request.pageNumber === N,
|
|
3772
|
+
"cl-text-grey-6": d.request.pageNumber !== N
|
|
3773
3773
|
}]),
|
|
3774
|
-
onClick: (
|
|
3775
|
-
},
|
|
3774
|
+
onClick: (q) => r(N)
|
|
3775
|
+
}, I(h(t)(N, h(fe).INTEGER)), 11, so))), 128)),
|
|
3776
3776
|
ee(b("li", {
|
|
3777
3777
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
3778
|
-
onClick: w[3] || (w[3] = (
|
|
3778
|
+
onClick: w[3] || (w[3] = (N) => r(d.request.pageNumber + 1))
|
|
3779
3779
|
}, [
|
|
3780
3780
|
E(h(H), {
|
|
3781
3781
|
icon: "ph:caret-right",
|
|
@@ -3786,7 +3786,7 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3786
3786
|
]),
|
|
3787
3787
|
ee(b("li", {
|
|
3788
3788
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
3789
|
-
onClick: w[4] || (w[4] = (
|
|
3789
|
+
onClick: w[4] || (w[4] = (N) => r(s.value))
|
|
3790
3790
|
}, [
|
|
3791
3791
|
E(h(H), {
|
|
3792
3792
|
icon: "ph:caret-double-right",
|
|
@@ -3798,22 +3798,22 @@ const In = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Rn = { class: "cl-gap-1
|
|
|
3798
3798
|
])
|
|
3799
3799
|
]),
|
|
3800
3800
|
b("ul", co, [
|
|
3801
|
-
b("li", uo,
|
|
3802
|
-
(p(), T(J, null, se(c, (
|
|
3803
|
-
key:
|
|
3804
|
-
class:
|
|
3805
|
-
"cl-text-black cl-font-bold": d.request.pageSize ===
|
|
3806
|
-
"cl-text-grey-6": d.request.pageSize !==
|
|
3801
|
+
b("li", uo, I(h(n)("grid.pageSize")), 1),
|
|
3802
|
+
(p(), T(J, null, se(c, (N, z) => b("li", {
|
|
3803
|
+
key: z,
|
|
3804
|
+
class: U(["cl-cursor-pointer cl-mr-1 lg:cl-mr-2", {
|
|
3805
|
+
"cl-text-black cl-font-bold": d.request.pageSize === N,
|
|
3806
|
+
"cl-text-grey-6": d.request.pageSize !== N
|
|
3807
3807
|
}]),
|
|
3808
|
-
onClick: (
|
|
3809
|
-
},
|
|
3808
|
+
onClick: (q) => f(N)
|
|
3809
|
+
}, I(h(t)(N, h(fe).INTEGER)), 11, fo)), 64))
|
|
3810
3810
|
]),
|
|
3811
3811
|
b("ul", po, [
|
|
3812
|
-
b("li", mo,
|
|
3813
|
-
b("li", vo,
|
|
3812
|
+
b("li", mo, I(h(n)("grid.totalRecords")), 1),
|
|
3813
|
+
b("li", vo, I(h(t)(d.data.totalRecords, h(fe).INTEGER)), 1)
|
|
3814
3814
|
])
|
|
3815
3815
|
])
|
|
3816
|
-
])) :
|
|
3816
|
+
])) : P("", !0);
|
|
3817
3817
|
};
|
|
3818
3818
|
}
|
|
3819
3819
|
}), go = [
|
|
@@ -4012,14 +4012,14 @@ const Co = {
|
|
|
4012
4012
|
},
|
|
4013
4013
|
emits: ["update:filter"],
|
|
4014
4014
|
setup(a, { emit: e }) {
|
|
4015
|
-
const l = a, { t } = ce(), n =
|
|
4015
|
+
const l = a, { t } = ce(), n = F(() => {
|
|
4016
4016
|
let r = [];
|
|
4017
4017
|
return l.column.type !== "slot" ? r = Sl.filter((i) => i.allowedTypes.includes(l.column.type)) : typeof l.column.slotType < "u" && typeof l.column.field < "u" && (r = Sl.filter((i) => i.allowedTypes.includes(l.column.slotType))), l.column.type === "date" || l.column.type === "datetime" || l.column.slotType === "date" || l.column.slotType === "datetime" ? r.forEach((i) => {
|
|
4018
4018
|
i.description = t(`grid.${i.key}`);
|
|
4019
4019
|
}) : r.forEach((i) => {
|
|
4020
4020
|
i.description = t(`grid.${i.method}`);
|
|
4021
4021
|
}), r;
|
|
4022
|
-
}), s =
|
|
4022
|
+
}), s = F(() => {
|
|
4023
4023
|
var i;
|
|
4024
4024
|
let r = (i = l.filter) == null ? void 0 : i.filterMethod;
|
|
4025
4025
|
return typeof r > "u" && (r = X[l.defaultOperation].replace("_", "").toLowerCase()), n.value.find((c) => {
|
|
@@ -4047,30 +4047,30 @@ const Co = {
|
|
|
4047
4047
|
s.value ? (p(), Z(h(H), {
|
|
4048
4048
|
key: 0,
|
|
4049
4049
|
icon: s.value.icon,
|
|
4050
|
-
class:
|
|
4050
|
+
class: U(["cl-text-lg", {
|
|
4051
4051
|
"cl-text-grey-4": l.filter === void 0 || l.filter.filterValue === "",
|
|
4052
4052
|
"cl-text-primary-default": l.filter && l.filter.filterValue !== ""
|
|
4053
4053
|
}])
|
|
4054
|
-
}, null, 8, ["icon", "class"])) :
|
|
4054
|
+
}, null, 8, ["icon", "class"])) : P("", !0)
|
|
4055
4055
|
]),
|
|
4056
4056
|
b("div", {
|
|
4057
|
-
class:
|
|
4057
|
+
class: U(["cl-absolute cl-bg-white cl-border cl-border-grey-0 cl-flex-wrap cl-font-normal cl-h-0 cl-hidden cl-rounded cl-shadow-lg cl-text-left cl-text-xs cl-top-8 cl-z-10", {
|
|
4058
4058
|
"group-hover:cl-flex group-hover:cl-h-auto group-hover:cl-w-52": r.loading === !1,
|
|
4059
4059
|
"cl-left-0": r.firstHalf,
|
|
4060
4060
|
"cl--left-44": !r.firstHalf
|
|
4061
4061
|
}])
|
|
4062
4062
|
}, [
|
|
4063
|
-
b("strong", Fo,
|
|
4063
|
+
b("strong", Fo, I(h(t)("grid.availableMethods")), 1),
|
|
4064
4064
|
(p(!0), T(J, null, se(n.value, (c, f) => {
|
|
4065
4065
|
var v;
|
|
4066
4066
|
return p(), T("span", {
|
|
4067
4067
|
key: f,
|
|
4068
|
-
class:
|
|
4068
|
+
class: U(["cl-cursor-pointer cl-px-4 cl-py-1 cl-transition-colors cl-w-full hover:cl-bg-grey-0", {
|
|
4069
4069
|
"cl-bg-primary-default cl-opacity-80": c.method === ((v = s.value) == null ? void 0 : v.method)
|
|
4070
4070
|
}]),
|
|
4071
4071
|
onClick: oe((d) => o(c.method), ["prevent"])
|
|
4072
4072
|
}, [
|
|
4073
|
-
pe(
|
|
4073
|
+
pe(I(c.description) + " ", 1),
|
|
4074
4074
|
E(h(H), {
|
|
4075
4075
|
icon: c.icon,
|
|
4076
4076
|
class: "cl-float-right cl-text-grey-4 cl-text-sm"
|
|
@@ -4100,42 +4100,42 @@ const Co = {
|
|
|
4100
4100
|
function s() {
|
|
4101
4101
|
return l.column.type === "string" || l.column.slotType === "string" ? X.CONTAINS : l.column.type === "datetime" || l.column.slotType === "datetime" || l.column.type === "date" || l.column.slotType === "date" ? X.LESS_THAN : X.EQUAL;
|
|
4102
4102
|
}
|
|
4103
|
-
const o =
|
|
4103
|
+
const o = F({
|
|
4104
4104
|
get: () => l.filter,
|
|
4105
4105
|
set: (u) => e("update:filter", u)
|
|
4106
|
-
}), r =
|
|
4106
|
+
}), r = F(() => l.column.type === "date" || l.column.type === "datetime" || l.column.type === "slot" && (l.column.slotType === "date" || l.column.slotType === "datetime")), i = F(() => l.column.type === "dateRange" || l.column.type === "slot" && l.column.slotType === "dateRange"), c = F(() => l.column.type === "list" || l.column.type === "slot" && l.column.slotType === "list"), f = F(() => c.value && l.column.listType === "number"), v = F({
|
|
4107
4107
|
get() {
|
|
4108
|
-
var m, k,
|
|
4108
|
+
var m, k, M, L, S, $, A;
|
|
4109
4109
|
let u = (m = o.value) == null ? void 0 : m[0];
|
|
4110
4110
|
if (u) {
|
|
4111
4111
|
if (r.value) {
|
|
4112
4112
|
if ((((k = l.filter) == null ? void 0 : k.length) ?? 0) > 1) {
|
|
4113
|
-
const
|
|
4114
|
-
|
|
4113
|
+
const B = (M = o.value) == null ? void 0 : M.find((R) => R.filterOperation === X.EQUAL_OR_GREATER_THAN), C = (L = o.value) == null ? void 0 : L.find((R) => R.filterOperation === X.LESS_THAN);
|
|
4114
|
+
B && C && (u = {
|
|
4115
4115
|
filterOnColumn: l.column.field,
|
|
4116
4116
|
filterOperation: X.EQUAL,
|
|
4117
4117
|
filterMethod: "equal",
|
|
4118
|
-
filterValue:
|
|
4118
|
+
filterValue: B.filterValue
|
|
4119
4119
|
});
|
|
4120
4120
|
} else if (u.filterOperation === X.EQUAL_OR_LESS_THAN || u.filterOperation === X.GREATER_THAN) {
|
|
4121
|
-
let
|
|
4121
|
+
let B = G.fromISO(u.filterValue, {
|
|
4122
4122
|
zone: l.timeZone ?? "UTC"
|
|
4123
4123
|
});
|
|
4124
|
-
l.column.type === "date" || l.column.type === "slot" && l.column.slotType === "date" ?
|
|
4124
|
+
l.column.type === "date" || l.column.type === "slot" && l.column.slotType === "date" ? B = B.minus({ days: 1 }) : B = B.minus({ minutes: 1 }), u = {
|
|
4125
4125
|
filterOnColumn: l.column.field,
|
|
4126
4126
|
filterOperation: u.filterOperation,
|
|
4127
4127
|
filterMethod: u.filterOperation === X.EQUAL_OR_LESS_THAN ? "equalorlessthan" : "greaterthan",
|
|
4128
|
-
filterValue:
|
|
4128
|
+
filterValue: B.plus({ milliseconds: 1 }).toISO() ?? ""
|
|
4129
4129
|
};
|
|
4130
4130
|
}
|
|
4131
4131
|
} else if (i.value && (((S = l.filter) == null ? void 0 : S.length) ?? 0) > 1) {
|
|
4132
|
-
const
|
|
4133
|
-
|
|
4132
|
+
const B = ($ = o.value) == null ? void 0 : $.find((R) => R.filterOperation === X.EQUAL_OR_GREATER_THAN), C = (A = o.value) == null ? void 0 : A.find((R) => R.filterOperation === X.EQUAL_OR_LESS_THAN);
|
|
4133
|
+
B && C && (u = {
|
|
4134
4134
|
filterOnColumn: l.column.field,
|
|
4135
4135
|
filterOperation: X.EQUAL,
|
|
4136
4136
|
filterMethod: "equal",
|
|
4137
4137
|
filterValue: {
|
|
4138
|
-
start:
|
|
4138
|
+
start: B.filterValue,
|
|
4139
4139
|
end: C.filterValue
|
|
4140
4140
|
}
|
|
4141
4141
|
});
|
|
@@ -4146,45 +4146,45 @@ const Co = {
|
|
|
4146
4146
|
set(u) {
|
|
4147
4147
|
let m = null;
|
|
4148
4148
|
if (r.value) {
|
|
4149
|
-
const k = u,
|
|
4150
|
-
if (
|
|
4149
|
+
const k = u, M = (k == null ? void 0 : k.filterMethod) && w(k.filterMethod, k.filterValue, "equal"), L = (k == null ? void 0 : k.filterMethod) && w(k.filterMethod, k.filterValue, "equalorlessthan"), S = (k == null ? void 0 : k.filterMethod) && w(k.filterMethod, k.filterValue, "greaterthan");
|
|
4150
|
+
if (M) {
|
|
4151
4151
|
let $ = G.fromISO(k.filterValue, {
|
|
4152
4152
|
zone: l.timeZone ?? "UTC"
|
|
4153
4153
|
}).set({ second: 0, millisecond: 0 });
|
|
4154
|
-
const
|
|
4154
|
+
const A = $.toISO();
|
|
4155
4155
|
l.column.type === "date" || l.column.type === "slot" && l.column.slotType === "date" ? $ = $.plus({ days: 1 }) : $ = $.plus({ minutes: 1 });
|
|
4156
|
-
const
|
|
4156
|
+
const B = $.toISO();
|
|
4157
4157
|
m = [
|
|
4158
4158
|
{
|
|
4159
4159
|
filterOnColumn: l.column.field,
|
|
4160
4160
|
filterOperation: X.EQUAL_OR_GREATER_THAN,
|
|
4161
4161
|
filterMethod: "equalorgreaterthan",
|
|
4162
|
-
filterValue:
|
|
4162
|
+
filterValue: A
|
|
4163
4163
|
},
|
|
4164
4164
|
{
|
|
4165
4165
|
filterOnColumn: l.column.field,
|
|
4166
4166
|
filterOperation: X.LESS_THAN,
|
|
4167
4167
|
filterMethod: "lessthan",
|
|
4168
|
-
filterValue:
|
|
4168
|
+
filterValue: B
|
|
4169
4169
|
}
|
|
4170
4170
|
];
|
|
4171
|
-
} else if (
|
|
4171
|
+
} else if (L || S) {
|
|
4172
4172
|
let $ = G.fromISO(k.filterValue, {
|
|
4173
4173
|
zone: l.timeZone ?? "UTC"
|
|
4174
4174
|
}).set({ second: 0, millisecond: 0 });
|
|
4175
4175
|
l.column.type === "date" || l.column.type === "slot" && l.column.slotType === "date" ? $ = $.plus({ days: 1 }) : $ = $.plus({ minutes: 1 }), m = [
|
|
4176
4176
|
{
|
|
4177
4177
|
filterOnColumn: l.column.field,
|
|
4178
|
-
filterOperation:
|
|
4179
|
-
filterMethod:
|
|
4178
|
+
filterOperation: L ? X.EQUAL_OR_LESS_THAN : X.GREATER_THAN,
|
|
4179
|
+
filterMethod: L ? "equalorlessthan" : "greaterthan",
|
|
4180
4180
|
filterValue: $.minus({ milliseconds: 1 }).toISO()
|
|
4181
4181
|
}
|
|
4182
4182
|
];
|
|
4183
4183
|
}
|
|
4184
4184
|
} else if (i.value && (u != null && u.filterValue)) {
|
|
4185
|
-
const k = u.filterValue,
|
|
4185
|
+
const k = u.filterValue, M = G.fromISO(k.start, {
|
|
4186
4186
|
zone: l.timeZone ?? "UTC"
|
|
4187
|
-
}).toISO(),
|
|
4187
|
+
}).toISO(), L = G.fromISO(k.end, {
|
|
4188
4188
|
zone: l.timeZone ?? "UTC"
|
|
4189
4189
|
}).toISO();
|
|
4190
4190
|
m = [
|
|
@@ -4192,13 +4192,13 @@ const Co = {
|
|
|
4192
4192
|
filterOnColumn: l.column.field,
|
|
4193
4193
|
filterOperation: X.EQUAL_OR_GREATER_THAN,
|
|
4194
4194
|
filterMethod: "equalorgreaterthan",
|
|
4195
|
-
filterValue:
|
|
4195
|
+
filterValue: M
|
|
4196
4196
|
},
|
|
4197
4197
|
{
|
|
4198
4198
|
filterOnColumn: l.column.field,
|
|
4199
4199
|
filterOperation: X.EQUAL_OR_LESS_THAN,
|
|
4200
4200
|
filterMethod: "equalorlessthan",
|
|
4201
|
-
filterValue:
|
|
4201
|
+
filterValue: L
|
|
4202
4202
|
}
|
|
4203
4203
|
];
|
|
4204
4204
|
}
|
|
@@ -4211,7 +4211,7 @@ const Co = {
|
|
|
4211
4211
|
l.timeZone ? k.filterValue = G.fromISO(k.filterValue).setZone("UTC").toISO() ?? "" : k.filterValue = k.filterValue.replace("Z", "");
|
|
4212
4212
|
o.value = m;
|
|
4213
4213
|
}
|
|
4214
|
-
}), d =
|
|
4214
|
+
}), d = F({
|
|
4215
4215
|
get: () => v.value,
|
|
4216
4216
|
set(u) {
|
|
4217
4217
|
v.value = u;
|
|
@@ -4220,50 +4220,50 @@ const Co = {
|
|
|
4220
4220
|
function w(u, m, k) {
|
|
4221
4221
|
return m !== void 0 && m !== "" && u === k && r.value;
|
|
4222
4222
|
}
|
|
4223
|
-
const O =
|
|
4223
|
+
const O = F(() => {
|
|
4224
4224
|
var u;
|
|
4225
4225
|
return ((u = v.value) == null ? void 0 : u.filterValue) ?? "";
|
|
4226
|
-
}),
|
|
4226
|
+
}), D = F(() => O.value === "" ? null : O.value), N = F(() => O.value === "" ? null : O.value), z = F(() => Intl.NumberFormat(t.value).format(1.1).replace(/[0-9]+/g, "")), q = F(() => ul(l.column));
|
|
4227
4227
|
function le(u, m) {
|
|
4228
4228
|
var S;
|
|
4229
|
-
let k,
|
|
4230
|
-
const
|
|
4229
|
+
let k, M = !1;
|
|
4230
|
+
const L = ((u == null ? void 0 : u.value) ?? m).trim();
|
|
4231
4231
|
if (v.value)
|
|
4232
|
-
|
|
4233
|
-
else if (
|
|
4232
|
+
M = ((S = v.value) == null ? void 0 : S.filterValue) === L, k = he(d.value), k.filterValue = L;
|
|
4233
|
+
else if (L !== "" && typeof l.column.field < "u") {
|
|
4234
4234
|
const $ = s();
|
|
4235
4235
|
k = {
|
|
4236
4236
|
filterOnColumn: l.column.field,
|
|
4237
4237
|
filterMethod: X[$].replace("_", "").toLowerCase(),
|
|
4238
4238
|
filterOperation: $,
|
|
4239
|
-
filterValue:
|
|
4239
|
+
filterValue: L
|
|
4240
4240
|
};
|
|
4241
4241
|
} else
|
|
4242
4242
|
return;
|
|
4243
|
-
|
|
4243
|
+
M === !1 && (v.value = k);
|
|
4244
4244
|
}
|
|
4245
4245
|
function re(u, m) {
|
|
4246
|
-
let k,
|
|
4247
|
-
l.column.format === fe.INTEGER ? (typeof
|
|
4246
|
+
let k, M = (u == null ? void 0 : u.value) ?? m ?? 0;
|
|
4247
|
+
l.column.format === fe.INTEGER ? (typeof M == "string" && (M = parseInt(M)), k = Math.round(M)) : (typeof M == "string" && (M = parseFloat(M.replace(z.value, "."))), k = M), le(null, isNaN(k) ? "" : k.toString());
|
|
4248
4248
|
}
|
|
4249
4249
|
function g(u) {
|
|
4250
|
-
var
|
|
4250
|
+
var M;
|
|
4251
4251
|
let m, k = !1;
|
|
4252
4252
|
if (v.value)
|
|
4253
|
-
k = ((
|
|
4253
|
+
k = ((M = v.value) == null ? void 0 : M.filterValue) === u, m = he(v.value), m.filterValue = u ?? "";
|
|
4254
4254
|
else if (u !== null && typeof l.column.field < "u") {
|
|
4255
|
-
const
|
|
4255
|
+
const L = s();
|
|
4256
4256
|
m = {
|
|
4257
4257
|
filterOnColumn: l.column.field,
|
|
4258
|
-
filterMethod: X[
|
|
4259
|
-
filterOperation:
|
|
4258
|
+
filterMethod: X[L].replace("_", "").toLowerCase(),
|
|
4259
|
+
filterOperation: L,
|
|
4260
4260
|
filterValue: u
|
|
4261
4261
|
};
|
|
4262
4262
|
} else
|
|
4263
4263
|
return;
|
|
4264
4264
|
k === !1 && (v.value = m);
|
|
4265
4265
|
}
|
|
4266
|
-
return (u, m) =>
|
|
4266
|
+
return (u, m) => q.value ? (p(), T("div", Ro, [
|
|
4267
4267
|
u.column.type === "boolean" || u.column.type === "slot" && u.column.slotType === "boolean" ? (p(), T("select", {
|
|
4268
4268
|
key: 0,
|
|
4269
4269
|
disabled: u.loading,
|
|
@@ -4274,14 +4274,14 @@ const Co = {
|
|
|
4274
4274
|
b("option", {
|
|
4275
4275
|
value: "true",
|
|
4276
4276
|
selected: O.value === "true"
|
|
4277
|
-
},
|
|
4277
|
+
}, I(h(n)("grid.true")), 9, Mo),
|
|
4278
4278
|
b("option", {
|
|
4279
4279
|
value: "false",
|
|
4280
4280
|
selected: O.value === "false"
|
|
4281
|
-
},
|
|
4281
|
+
}, I(h(n)("grid.false")), 9, Lo)
|
|
4282
4282
|
], 40, Vo)) : r.value ? (p(), Z(me, {
|
|
4283
4283
|
key: 1,
|
|
4284
|
-
"model-value":
|
|
4284
|
+
"model-value": D.value,
|
|
4285
4285
|
class: "!cl-h-[2rem] !cl-text-xs cl-border-none cl-mb-0 cl-w-full lg:!cl-text-base",
|
|
4286
4286
|
disabled: u.loading,
|
|
4287
4287
|
label: u.column.caption,
|
|
@@ -4291,7 +4291,7 @@ const Co = {
|
|
|
4291
4291
|
"onUpdate:modelValue": m[1] || (m[1] = (k) => le(null, k ?? ""))
|
|
4292
4292
|
}, null, 8, ["model-value", "disabled", "label", "input-type", "time-zone"])) : i.value ? (p(), Z(me, {
|
|
4293
4293
|
key: 2,
|
|
4294
|
-
"model-value":
|
|
4294
|
+
"model-value": N.value,
|
|
4295
4295
|
class: "!cl-h-[2rem] [&_.clear-icon]:-cl-m-1 [&_.icon]:cl-text-sm cl-border-none cl-mb-0 cl-w-full",
|
|
4296
4296
|
disabled: u.loading,
|
|
4297
4297
|
"input-type": "dateRange",
|
|
@@ -4305,14 +4305,14 @@ const Co = {
|
|
|
4305
4305
|
disabled: u.loading,
|
|
4306
4306
|
"input-type": "number",
|
|
4307
4307
|
"show-arrows": !1,
|
|
4308
|
-
onInput: m[3] || (m[3] = (k,
|
|
4308
|
+
onInput: m[3] || (m[3] = (k, M) => re(null, M))
|
|
4309
4309
|
}, null, 8, ["model-value", "disabled"])) : u.column.type === "string" || u.column.type === "slot" && u.column.slotType === "string" ? (p(), Z(me, {
|
|
4310
4310
|
key: 4,
|
|
4311
4311
|
"model-value": O.value,
|
|
4312
4312
|
class: "!cl-h-[2rem] !cl-text-xs cl-border-none cl-mb-0 cl-w-full lg:!cl-text-base",
|
|
4313
4313
|
disabled: u.loading,
|
|
4314
4314
|
"input-type": "text",
|
|
4315
|
-
onInput: m[4] || (m[4] = (k,
|
|
4315
|
+
onInput: m[4] || (m[4] = (k, M) => le(null, M))
|
|
4316
4316
|
}, null, 8, ["model-value", "disabled"])) : c.value ? (p(), T("select", {
|
|
4317
4317
|
key: 5,
|
|
4318
4318
|
class: "!cl-h-[2rem] cl-bg-white cl-border-none cl-mb-0 cl-rounded-md cl-w-full",
|
|
@@ -4324,9 +4324,9 @@ const Co = {
|
|
|
4324
4324
|
key: k.value,
|
|
4325
4325
|
value: k.value,
|
|
4326
4326
|
selected: O.value === k.value.toString()
|
|
4327
|
-
},
|
|
4328
|
-
], 40, jo)) :
|
|
4329
|
-
i.value ?
|
|
4327
|
+
}, I(h(n)(k.translationKey)), 9, zo))), 128))
|
|
4328
|
+
], 40, jo)) : P("", !0),
|
|
4329
|
+
i.value ? P("", !0) : (p(), Z(Io, {
|
|
4330
4330
|
key: 6,
|
|
4331
4331
|
filter: d.value,
|
|
4332
4332
|
"onUpdate:filter": m[6] || (m[6] = (k) => d.value = k),
|
|
@@ -4335,7 +4335,7 @@ const Co = {
|
|
|
4335
4335
|
"default-operation": s(),
|
|
4336
4336
|
"first-half": u.firstHalf
|
|
4337
4337
|
}, null, 8, ["filter", "loading", "column", "default-operation", "first-half"]))
|
|
4338
|
-
])) :
|
|
4338
|
+
])) : P("", !0);
|
|
4339
4339
|
}
|
|
4340
4340
|
}), Uo = { class: "-cl-top-1 cl-bg-white cl-shadow-sm cl-sticky cl-z-20 lg:cl-bg-transparent lg:cl-relative lg:cl-shadow-none" }, xo = { class: "cl-hidden lg:cl-table-row" }, _o = ["onClick"], Ho = { class: "cl-flex cl-justify-end cl-w-full lg:cl-hidden" }, Go = { class: "cl-col-span-2 lg:cl-hidden" }, Zo = ["onClick"], Ko = { class: "cl-font-normal cl-mr-1" }, Wo = /* @__PURE__ */ K({
|
|
4341
4341
|
__name: "cl-ui-grid-header",
|
|
@@ -4350,7 +4350,7 @@ const Co = {
|
|
|
4350
4350
|
},
|
|
4351
4351
|
emits: ["update:request", "update:filterPanelOpen"],
|
|
4352
4352
|
setup(a, { emit: e }) {
|
|
4353
|
-
const l = a, { t } = ce(), n =
|
|
4353
|
+
const l = a, { t } = ce(), n = F({
|
|
4354
4354
|
get: () => l.request,
|
|
4355
4355
|
set: (i) => e("update:request", i)
|
|
4356
4356
|
});
|
|
@@ -4380,13 +4380,13 @@ const Co = {
|
|
|
4380
4380
|
b("tr", xo, [
|
|
4381
4381
|
(p(!0), T(J, null, se(i.columns, (f, v) => (p(), T("th", {
|
|
4382
4382
|
key: v,
|
|
4383
|
-
class:
|
|
4383
|
+
class: U(["cl-text-grey-3 cl-text-sm", {
|
|
4384
4384
|
"cl-cursor-pointer": h(Ue)(f) && i.loading === !1
|
|
4385
4385
|
}]),
|
|
4386
4386
|
onClick: (d) => h(Ue)(f) && i.loading === !1 ? o(f.field) : () => {
|
|
4387
4387
|
}
|
|
4388
4388
|
}, [
|
|
4389
|
-
pe(
|
|
4389
|
+
pe(I(f.caption) + " ", 1),
|
|
4390
4390
|
ee(E(h(H), {
|
|
4391
4391
|
class: "cl-inline-block",
|
|
4392
4392
|
icon: "ph:caret-up"
|
|
@@ -4402,7 +4402,7 @@ const Co = {
|
|
|
4402
4402
|
], 10, _o))), 128))
|
|
4403
4403
|
]),
|
|
4404
4404
|
b("tr", {
|
|
4405
|
-
class:
|
|
4405
|
+
class: U(["cl-border cl-border-grey-2 cl-flex cl-flex-wrap cl-p-2 lg:cl-border-none lg:cl-p-0 lg:cl-table-row", {
|
|
4406
4406
|
"cl-hidden lg:cl-table-row": !i.filterPanelOpen
|
|
4407
4407
|
}])
|
|
4408
4408
|
}, [
|
|
@@ -4416,17 +4416,17 @@ const Co = {
|
|
|
4416
4416
|
]),
|
|
4417
4417
|
(p(!0), T(J, null, se(i.columns, (f, v) => (p(), T("th", {
|
|
4418
4418
|
key: v,
|
|
4419
|
-
class:
|
|
4419
|
+
class: U(["cl-grid cl-grid-cols-4 cl-py-1 cl-text-xs cl-w-full lg:cl-table-cell lg:cl-w-auto", {
|
|
4420
4420
|
"cl-hidden lg:cl-table-cell": !h(ul)(f)
|
|
4421
4421
|
}])
|
|
4422
4422
|
}, [
|
|
4423
|
-
b("div", Go,
|
|
4423
|
+
b("div", Go, I(f.caption), 1),
|
|
4424
4424
|
h(Ue)(f) ? (p(), T("div", {
|
|
4425
4425
|
key: 0,
|
|
4426
4426
|
class: "cl-col-span-2 cl-gap-1 cl-span lg:cl-hidden",
|
|
4427
4427
|
onClick: (d) => i.loading === !1 ? o(f.field) : void 0
|
|
4428
4428
|
}, [
|
|
4429
|
-
b("span", Ko,
|
|
4429
|
+
b("span", Ko, I(h(t)("grid.sortBy")), 1),
|
|
4430
4430
|
s(f, !0) ? (p(), Z(h(H), {
|
|
4431
4431
|
key: 0,
|
|
4432
4432
|
class: "cl-cursor-pointer cl-inline-block",
|
|
@@ -4440,7 +4440,7 @@ const Co = {
|
|
|
4440
4440
|
class: "cl-cursor-pointer cl-inline-block",
|
|
4441
4441
|
icon: "ph:minus"
|
|
4442
4442
|
}))
|
|
4443
|
-
], 8, Zo)) :
|
|
4443
|
+
], 8, Zo)) : P("", !0),
|
|
4444
4444
|
E(Bo, {
|
|
4445
4445
|
class: "cl-col-span-4",
|
|
4446
4446
|
loading: i.loading,
|
|
@@ -4465,7 +4465,7 @@ const Co = {
|
|
|
4465
4465
|
},
|
|
4466
4466
|
emits: ["update:searchValue", "update:request"],
|
|
4467
4467
|
setup(a, { emit: e }) {
|
|
4468
|
-
const l = a, t =
|
|
4468
|
+
const l = a, t = F({
|
|
4469
4469
|
get: () => l.request,
|
|
4470
4470
|
set: (o) => e("update:request", o)
|
|
4471
4471
|
});
|
|
@@ -4487,7 +4487,7 @@ const Co = {
|
|
|
4487
4487
|
const { t: s } = ce();
|
|
4488
4488
|
return (o, r) => {
|
|
4489
4489
|
const i = Cl("icon");
|
|
4490
|
-
return
|
|
4490
|
+
return x(o.$slots, "search", de(ve({ searchValue: o.searchValue, performSearch: n })), () => [
|
|
4491
4491
|
b("div", Qo, [
|
|
4492
4492
|
E(me, {
|
|
4493
4493
|
"model-value": o.searchValue,
|
|
@@ -4536,7 +4536,7 @@ const Co = {
|
|
|
4536
4536
|
onClick: c[0] || (c[0] = oe((f) => n.value = !0, ["prevent"]))
|
|
4537
4537
|
}), {
|
|
4538
4538
|
default: Q(() => [
|
|
4539
|
-
pe(
|
|
4539
|
+
pe(I(h(t)("grid.manageView")), 1)
|
|
4540
4540
|
]),
|
|
4541
4541
|
_: 1
|
|
4542
4542
|
}, 16, ["disabled"]),
|
|
@@ -4551,18 +4551,18 @@ const Co = {
|
|
|
4551
4551
|
size: 16,
|
|
4552
4552
|
onClick: c[1] || (c[1] = (f) => n.value = !1)
|
|
4553
4553
|
}),
|
|
4554
|
-
b("h3", er,
|
|
4554
|
+
b("h3", er, I(h(t)("grid.manageView")), 1),
|
|
4555
4555
|
b("ul", lr, [
|
|
4556
4556
|
b("li", tr, [
|
|
4557
|
-
b("strong", ar,
|
|
4558
|
-
b("strong", nr,
|
|
4559
|
-
b("strong", or,
|
|
4557
|
+
b("strong", ar, I(h(t)("grid.column")), 1),
|
|
4558
|
+
b("strong", nr, I(h(t)("grid.visible")), 1),
|
|
4559
|
+
b("strong", or, I(h(t)("grid.order")), 1)
|
|
4560
4560
|
]),
|
|
4561
4561
|
(p(!0), T(J, null, se(i.columns, (f, v) => (p(), T("li", {
|
|
4562
4562
|
key: v,
|
|
4563
4563
|
class: "cl-border-b cl-border-grey-2 cl-flex cl-py-2 cl-text-sm cl-w-full"
|
|
4564
4564
|
}, [
|
|
4565
|
-
b("div", rr,
|
|
4565
|
+
b("div", rr, I(f.caption), 1),
|
|
4566
4566
|
b("div", ir, [
|
|
4567
4567
|
E(me, {
|
|
4568
4568
|
"model-value": f.visible === void 0 || f.visible === !0,
|
|
@@ -4577,14 +4577,14 @@ const Co = {
|
|
|
4577
4577
|
class: "cl-cursor-pointer cl-inline-block cl-mr-2",
|
|
4578
4578
|
icon: "ph:arrow-left",
|
|
4579
4579
|
onClick: (d) => r(v, "down")
|
|
4580
|
-
}, null, 8, ["onClick"])) :
|
|
4580
|
+
}, null, 8, ["onClick"])) : P("", !0),
|
|
4581
4581
|
v !== i.columns.length - 1 ? (p(), Z(h(H), {
|
|
4582
4582
|
key: 1,
|
|
4583
4583
|
class: "cl-cursor-pointer cl-inline-block",
|
|
4584
4584
|
icon: "ph:arrow-right",
|
|
4585
4585
|
onClick: (d) => r(v, "up")
|
|
4586
|
-
}, null, 8, ["onClick"])) :
|
|
4587
|
-
], 64)) : (p(), T("em", cr,
|
|
4586
|
+
}, null, 8, ["onClick"])) : P("", !0)
|
|
4587
|
+
], 64)) : (p(), T("em", cr, I(h(t)("grid.hidden")), 1))
|
|
4588
4588
|
])
|
|
4589
4589
|
]))), 128))
|
|
4590
4590
|
])
|
|
@@ -4613,12 +4613,12 @@ const Co = {
|
|
|
4613
4613
|
emits: ["update:columns", "update:request", "data-request", "row-edit", "edit-start", "edit-end", "row-select"],
|
|
4614
4614
|
setup(a, { emit: e }) {
|
|
4615
4615
|
var re;
|
|
4616
|
-
const l = a, t =
|
|
4616
|
+
const l = a, t = F(() => l.headerDisplayTimezone ?? l.timeZone), n = F(() => l.dateFormatLocale);
|
|
4617
4617
|
Yl(zl, n);
|
|
4618
|
-
const s =
|
|
4618
|
+
const s = F({
|
|
4619
4619
|
get: () => l.columns,
|
|
4620
4620
|
set: (g) => e("update:columns", g)
|
|
4621
|
-
}), o =
|
|
4621
|
+
}), o = F(() => s.value.filter((g) => g.visible ?? !0)), r = V({});
|
|
4622
4622
|
function i() {
|
|
4623
4623
|
const g = {};
|
|
4624
4624
|
window.innerWidth >= 1024 && s.value.forEach((u) => {
|
|
@@ -4632,25 +4632,25 @@ const Co = {
|
|
|
4632
4632
|
Qe(() => {
|
|
4633
4633
|
window.addEventListener("resize", i), i();
|
|
4634
4634
|
}), rl(() => window.removeEventListener("resize", i));
|
|
4635
|
-
const f =
|
|
4635
|
+
const f = F({
|
|
4636
4636
|
get: () => l.request,
|
|
4637
4637
|
set: (g) => e("update:request", g)
|
|
4638
4638
|
});
|
|
4639
4639
|
function v() {
|
|
4640
4640
|
const g = he(f.value);
|
|
4641
|
-
g.pageNumber = 1, g.filters = [],
|
|
4641
|
+
g.pageNumber = 1, g.filters = [], q.value = "", f.value = g;
|
|
4642
4642
|
}
|
|
4643
4643
|
const d = sl(() => e("data-request"), 750);
|
|
4644
4644
|
ae(f, d, {
|
|
4645
4645
|
deep: !0,
|
|
4646
4646
|
immediate: !0
|
|
4647
4647
|
});
|
|
4648
|
-
const w =
|
|
4648
|
+
const w = F(() => l.data), O = V(!1), D = V(!1);
|
|
4649
4649
|
ae(O, () => O.value ? e("edit-start") : e("edit-end"));
|
|
4650
|
-
const
|
|
4650
|
+
const N = F(() => ({
|
|
4651
4651
|
highlightRowSelection: !0,
|
|
4652
4652
|
...l.options
|
|
4653
|
-
})),
|
|
4653
|
+
})), z = F({
|
|
4654
4654
|
get() {
|
|
4655
4655
|
const g = he(f.value);
|
|
4656
4656
|
return g.filters = g.filters.filter((u) => u.filterMethod !== "andcontains" && u.filterOperation !== X.AND_CONTAINS), g;
|
|
@@ -4665,21 +4665,21 @@ const Co = {
|
|
|
4665
4665
|
filters: u
|
|
4666
4666
|
};
|
|
4667
4667
|
}
|
|
4668
|
-
}),
|
|
4668
|
+
}), q = V(((re = l.request.filters.find((g) => g.filterMethod === "andcontains" || g.filterOperation === X.AND_CONTAINS)) == null ? void 0 : re.filterValue) ?? ""), le = F(() => l.columns.filter((g) => (g.type === "string" || g.type === "slot" && g.slotType === "string") && g.searchable));
|
|
4669
4669
|
return (g, u) => (p(), T("div", dr, [
|
|
4670
4670
|
le.value.length > 0 ? (p(), Z(Yo, {
|
|
4671
4671
|
key: 0,
|
|
4672
|
-
"search-value":
|
|
4673
|
-
"onUpdate:searchValue": u[0] || (u[0] = (m) =>
|
|
4672
|
+
"search-value": q.value,
|
|
4673
|
+
"onUpdate:searchValue": u[0] || (u[0] = (m) => q.value = m),
|
|
4674
4674
|
request: f.value,
|
|
4675
4675
|
"onUpdate:request": u[1] || (u[1] = (m) => f.value = m),
|
|
4676
4676
|
columns: le.value
|
|
4677
4677
|
}, {
|
|
4678
4678
|
search: Q((m) => [
|
|
4679
|
-
|
|
4679
|
+
x(g.$slots, "search", de(ve(m)))
|
|
4680
4680
|
]),
|
|
4681
4681
|
_: 3
|
|
4682
|
-
}, 8, ["search-value", "request", "columns"])) :
|
|
4682
|
+
}, 8, ["search-value", "request", "columns"])) : P("", !0),
|
|
4683
4683
|
E($e, { name: "fade" }, {
|
|
4684
4684
|
default: Q(() => [
|
|
4685
4685
|
ee(b("div", fr, [
|
|
@@ -4693,16 +4693,16 @@ const Co = {
|
|
|
4693
4693
|
E(jn, {
|
|
4694
4694
|
"edit-mode": O.value,
|
|
4695
4695
|
"onUpdate:editMode": u[3] || (u[3] = (m) => O.value = m),
|
|
4696
|
-
"filter-panel-open":
|
|
4697
|
-
"onUpdate:filterPanelOpen": u[4] || (u[4] = (m) =>
|
|
4696
|
+
"filter-panel-open": D.value,
|
|
4697
|
+
"onUpdate:filterPanelOpen": u[4] || (u[4] = (m) => D.value = m),
|
|
4698
4698
|
columns: g.columns,
|
|
4699
|
-
options:
|
|
4699
|
+
options: N.value,
|
|
4700
4700
|
request: f.value,
|
|
4701
4701
|
loading: g.loading,
|
|
4702
4702
|
onClearFilters: v
|
|
4703
4703
|
}, {
|
|
4704
4704
|
"additional-grid-actions": Q((m) => [
|
|
4705
|
-
|
|
4705
|
+
x(g.$slots, "additional-grid-actions", de(ve(m)))
|
|
4706
4706
|
]),
|
|
4707
4707
|
"view-manager": Q(() => [
|
|
4708
4708
|
E(ur, {
|
|
@@ -4715,7 +4715,7 @@ const Co = {
|
|
|
4715
4715
|
}, 8, ["edit-mode", "filter-panel-open", "columns", "options", "request", "loading"]),
|
|
4716
4716
|
b("div", pr, [
|
|
4717
4717
|
b("table", {
|
|
4718
|
-
class:
|
|
4718
|
+
class: U(["cl-delay-75 cl-min-h-[276px] cl-overflow-x-auto cl-overscroll-x-none cl-text-left cl-transition-opacity cl-w-full", {
|
|
4719
4719
|
"cl-opacity-40 cl-pointer-events-none": g.loading
|
|
4720
4720
|
}])
|
|
4721
4721
|
}, [
|
|
@@ -4727,12 +4727,12 @@ const Co = {
|
|
|
4727
4727
|
}, null, 4))), 128))
|
|
4728
4728
|
]),
|
|
4729
4729
|
E(Wo, {
|
|
4730
|
-
request:
|
|
4731
|
-
"onUpdate:request": u[5] || (u[5] = (m) =>
|
|
4732
|
-
"filter-panel-open":
|
|
4733
|
-
"onUpdate:filterPanelOpen": u[6] || (u[6] = (m) =>
|
|
4730
|
+
request: z.value,
|
|
4731
|
+
"onUpdate:request": u[5] || (u[5] = (m) => z.value = m),
|
|
4732
|
+
"filter-panel-open": D.value,
|
|
4733
|
+
"onUpdate:filterPanelOpen": u[6] || (u[6] = (m) => D.value = m),
|
|
4734
4734
|
columns: o.value,
|
|
4735
|
-
options:
|
|
4735
|
+
options: N.value,
|
|
4736
4736
|
loading: g.loading,
|
|
4737
4737
|
"time-zone": g.timeZone,
|
|
4738
4738
|
"header-display-timezone": t.value
|
|
@@ -4743,8 +4743,8 @@ const Co = {
|
|
|
4743
4743
|
data: w.value,
|
|
4744
4744
|
"time-zone": g.timeZone,
|
|
4745
4745
|
loading: g.loading,
|
|
4746
|
-
"search-value":
|
|
4747
|
-
options:
|
|
4746
|
+
"search-value": q.value,
|
|
4747
|
+
options: N.value,
|
|
4748
4748
|
"edit-mode": O.value,
|
|
4749
4749
|
onClearFilters: v,
|
|
4750
4750
|
onRowEdit: u[7] || (u[7] = (m) => g.$emit("row-edit", m)),
|
|
@@ -4752,8 +4752,8 @@ const Co = {
|
|
|
4752
4752
|
}, il({ _: 2 }, [
|
|
4753
4753
|
se(g.$slots, (m, k) => ({
|
|
4754
4754
|
name: k,
|
|
4755
|
-
fn: Q((
|
|
4756
|
-
|
|
4755
|
+
fn: Q((M) => [
|
|
4756
|
+
x(g.$slots, k, de(ve(M)))
|
|
4757
4757
|
])
|
|
4758
4758
|
}))
|
|
4759
4759
|
]), 1032, ["columns", "request", "data", "time-zone", "loading", "search-value", "options", "edit-mode"])
|
|
@@ -4778,15 +4778,15 @@ const Co = {
|
|
|
4778
4778
|
return cl(t, () => {
|
|
4779
4779
|
(l.isOpen ?? !1) && e("open-click");
|
|
4780
4780
|
}), (n, s) => (p(), T("header", hr, [
|
|
4781
|
-
|
|
4781
|
+
x(n.$slots, "logo"),
|
|
4782
4782
|
b("div", {
|
|
4783
4783
|
ref_key: "headerMenuElement",
|
|
4784
4784
|
ref: t,
|
|
4785
4785
|
class: "cl-cursor-pointer cl-flex cl-flex-nowrap",
|
|
4786
4786
|
onClick: s[0] || (s[0] = (o) => n.$emit("open-click"))
|
|
4787
4787
|
}, [
|
|
4788
|
-
|
|
4789
|
-
|
|
4788
|
+
x(n.$slots, "menu"),
|
|
4789
|
+
x(n.$slots, "icon")
|
|
4790
4790
|
], 512)
|
|
4791
4791
|
]));
|
|
4792
4792
|
}
|
|
@@ -4808,7 +4808,7 @@ const Co = {
|
|
|
4808
4808
|
setup(a) {
|
|
4809
4809
|
const e = a;
|
|
4810
4810
|
return (l, t) => (p(), T("div", {
|
|
4811
|
-
class:
|
|
4811
|
+
class: U(["md:cl-relative", {
|
|
4812
4812
|
"cl-bg-primary-default": (e == null ? void 0 : e.colour) === "default",
|
|
4813
4813
|
"cl-bg-blue-light": e.colour === "secondary"
|
|
4814
4814
|
}])
|
|
@@ -4826,17 +4826,17 @@ const Co = {
|
|
|
4826
4826
|
height: "48"
|
|
4827
4827
|
})),
|
|
4828
4828
|
b("div", {
|
|
4829
|
-
class:
|
|
4829
|
+
class: U(["cl-grow cl-hidden cl-my-4 md:cl-block", {
|
|
4830
4830
|
"cl-text-secondary-default": e.colour === "default",
|
|
4831
4831
|
"cl-text-white": e.colour === "secondary"
|
|
4832
4832
|
}])
|
|
4833
4833
|
}, [
|
|
4834
|
-
l.username ? (p(), T("div", wr,
|
|
4835
|
-
l.group ? (p(), T("div", kr,
|
|
4834
|
+
l.username ? (p(), T("div", wr, I(l.username), 1)) : P("", !0),
|
|
4835
|
+
l.group ? (p(), T("div", kr, I(l.group), 1)) : P("", !0)
|
|
4836
4836
|
], 2),
|
|
4837
4837
|
b("div", Tr, [
|
|
4838
4838
|
E(h(H), {
|
|
4839
|
-
class:
|
|
4839
|
+
class: U(["cl-transform-gpu cl-transition-transform", {
|
|
4840
4840
|
"cl-rotate-180": l.isOpen,
|
|
4841
4841
|
"cl-text-secondary-default": e.colour === "default",
|
|
4842
4842
|
"cl-text-white": e.colour === "secondary"
|
|
@@ -4848,7 +4848,7 @@ const Co = {
|
|
|
4848
4848
|
E($e, { name: "fade" }, {
|
|
4849
4849
|
default: Q(() => [
|
|
4850
4850
|
ee(b("div", $r, [
|
|
4851
|
-
|
|
4851
|
+
x(l.$slots, "default")
|
|
4852
4852
|
], 512), [
|
|
4853
4853
|
[te, l.isOpen]
|
|
4854
4854
|
])
|
|
@@ -4887,7 +4887,7 @@ const Er = {
|
|
|
4887
4887
|
},
|
|
4888
4888
|
emits: ["language-select"],
|
|
4889
4889
|
setup(a, { emit: e }) {
|
|
4890
|
-
const l = a, { locale: t } = ce(), n = V(!1), s =
|
|
4890
|
+
const l = a, { locale: t } = ce(), n = V(!1), s = F(() => l.supportedLanguages.find((i) => i.localeCode === t.value) ?? l.defaultLangauge), o = F(() => l.supportedLanguages.filter((i) => nl(i)).sort((i, c) => i.nativeName > c.nativeName ? 1 : c.nativeName > i.nativeName ? -1 : 0));
|
|
4891
4891
|
function r() {
|
|
4892
4892
|
l.disabled || (n.value = !n.value);
|
|
4893
4893
|
}
|
|
@@ -4895,16 +4895,16 @@ const Er = {
|
|
|
4895
4895
|
i && (n.value = !1);
|
|
4896
4896
|
}), (i, c) => s.value !== null && h(nl)(s.value) ? (p(), T("div", Er, [
|
|
4897
4897
|
b("div", {
|
|
4898
|
-
class:
|
|
4898
|
+
class: U(["cl-flex cl-items-center", {
|
|
4899
4899
|
"cl-cursor-pointer": !i.disabled
|
|
4900
4900
|
}]),
|
|
4901
4901
|
onClick: r
|
|
4902
4902
|
}, [
|
|
4903
4903
|
b("span", {
|
|
4904
|
-
class:
|
|
4904
|
+
class: U(["cl-font-semibold cl-text-xs", {
|
|
4905
4905
|
"cl-opacity-50": i.disabled
|
|
4906
4906
|
}])
|
|
4907
|
-
},
|
|
4907
|
+
}, I(s.value.nativeName), 3)
|
|
4908
4908
|
], 2),
|
|
4909
4909
|
E($e, { name: "fade" }, {
|
|
4910
4910
|
default: Q(() => [
|
|
@@ -4918,7 +4918,7 @@ const Er = {
|
|
|
4918
4918
|
t.value = f.localeCode, r(), e("language-select", f.localeCode);
|
|
4919
4919
|
}
|
|
4920
4920
|
}, [
|
|
4921
|
-
b("span", Fr,
|
|
4921
|
+
b("span", Fr, I(f.nativeName), 1)
|
|
4922
4922
|
], 8, Dr))), 128))
|
|
4923
4923
|
], 512), [
|
|
4924
4924
|
[te, n.value]
|
|
@@ -4926,7 +4926,7 @@ const Er = {
|
|
|
4926
4926
|
]),
|
|
4927
4927
|
_: 1
|
|
4928
4928
|
})
|
|
4929
|
-
])) :
|
|
4929
|
+
])) : P("", !0);
|
|
4930
4930
|
}
|
|
4931
4931
|
}), Ir = { class: "cl-relative" }, Rr = { class: "cl-h-full cl-z-0 xl:cl-h-screen" }, Vr = { class: "cl-absolute cl-bg-secondary-default cl-gap-y-1 cl-grid cl-grid-cols-1 cl-left-0 cl-opacity-95 cl-p-6 cl-top-0 cl-w-full cl-z-10 lg:cl-gap-x-1 lg:cl-grid-cols-10 lg:cl-p-10" }, qr = { class: "cl-col-span-10 lg:cl-col-span-3" }, Mr = {
|
|
4932
4932
|
key: 0,
|
|
@@ -4965,17 +4965,17 @@ const Er = {
|
|
|
4965
4965
|
}
|
|
4966
4966
|
return (v, d) => (p(), T("div", Ir, [
|
|
4967
4967
|
b("div", Rr, [
|
|
4968
|
-
|
|
4968
|
+
x(v.$slots, "background")
|
|
4969
4969
|
]),
|
|
4970
4970
|
b("form", Vr, [
|
|
4971
4971
|
b("div", qr, [
|
|
4972
|
-
|
|
4972
|
+
x(v.$slots, "logo")
|
|
4973
4973
|
]),
|
|
4974
4974
|
v.$slots["language-switcher"] ? (p(), T("div", Mr, [
|
|
4975
|
-
|
|
4976
|
-
])) :
|
|
4975
|
+
x(v.$slots, "language-switcher")
|
|
4976
|
+
])) : P("", !0),
|
|
4977
4977
|
b("div", {
|
|
4978
|
-
class:
|
|
4978
|
+
class: U(["cl-gap-y-4 cl-grid cl-grid-cols-1 lg:cl-gap-x-2 lg:cl-grid-cols-8", {
|
|
4979
4979
|
"cl-col-span-7": !v.$slots["language-switcher"],
|
|
4980
4980
|
"cl-col-span-6": v.$slots["language-switcher"]
|
|
4981
4981
|
}])
|
|
@@ -5051,7 +5051,7 @@ const Er = {
|
|
|
5051
5051
|
])
|
|
5052
5052
|
]),
|
|
5053
5053
|
b("div", {
|
|
5054
|
-
class:
|
|
5054
|
+
class: U(["cl-col-span-2", {
|
|
5055
5055
|
"cl-mt-1.5 cl-mb-1 md:cl-mt-0.5 md:cl-mb-7 lg:cl-mb-0": v.loading
|
|
5056
5056
|
}])
|
|
5057
5057
|
}, [
|
|
@@ -5064,7 +5064,7 @@ const Er = {
|
|
|
5064
5064
|
onClick: oe(r, ["prevent"])
|
|
5065
5065
|
}, {
|
|
5066
5066
|
default: Q(() => [
|
|
5067
|
-
pe(
|
|
5067
|
+
pe(I(h(l)("login.login")), 1)
|
|
5068
5068
|
]),
|
|
5069
5069
|
_: 1
|
|
5070
5070
|
}, 8, ["loading", "disabled", "onClick"])
|
|
@@ -5075,11 +5075,11 @@ const Er = {
|
|
|
5075
5075
|
var w;
|
|
5076
5076
|
return [
|
|
5077
5077
|
ee(b("span", Br, [
|
|
5078
|
-
(p(!0), T(J, null, se(v.errors, (O,
|
|
5078
|
+
(p(!0), T(J, null, se(v.errors, (O, D) => (p(), T("div", {
|
|
5079
5079
|
id: "cl-ui-login-errors",
|
|
5080
|
-
key:
|
|
5080
|
+
key: D,
|
|
5081
5081
|
class: "cl-font-semibold"
|
|
5082
|
-
},
|
|
5082
|
+
}, I(O), 1))), 128))
|
|
5083
5083
|
], 512), [
|
|
5084
5084
|
[te, (w = v.errors) == null ? void 0 : w.length]
|
|
5085
5085
|
])
|
|
@@ -5109,19 +5109,20 @@ const Er = {
|
|
|
5109
5109
|
},
|
|
5110
5110
|
emits: ["pinned-state", "open-state"],
|
|
5111
5111
|
setup(a, { expose: e, emit: l }) {
|
|
5112
|
-
const t = V([]), n =
|
|
5113
|
-
function s(
|
|
5114
|
-
let
|
|
5115
|
-
return
|
|
5116
|
-
id:
|
|
5112
|
+
const t = V([]), n = F(() => t.value.filter((D) => D.open === !0).length > 0);
|
|
5113
|
+
function s(D) {
|
|
5114
|
+
let N = t.value.find((z) => z.id === D);
|
|
5115
|
+
return N || (N = {
|
|
5116
|
+
id: D,
|
|
5117
5117
|
open: !1
|
|
5118
|
-
}, t.value.push(
|
|
5118
|
+
}, t.value.push(N)), N.open;
|
|
5119
5119
|
}
|
|
5120
|
-
function o(
|
|
5121
|
-
const
|
|
5122
|
-
|
|
5123
|
-
|
|
5124
|
-
|
|
5120
|
+
function o(D) {
|
|
5121
|
+
const N = t.value.find((q) => q.id === D);
|
|
5122
|
+
let z;
|
|
5123
|
+
N && (N.open = !N.open, N.open && (z = N.id), t.value.forEach((q) => {
|
|
5124
|
+
q.id !== D && (q.open = !1);
|
|
5125
|
+
})), l("open-state", !!(N != null && N.open), z);
|
|
5125
5126
|
}
|
|
5126
5127
|
const r = nt();
|
|
5127
5128
|
ae(
|
|
@@ -5138,36 +5139,36 @@ const Er = {
|
|
|
5138
5139
|
i.value = !i.value, l("pinned-state", i.value), c.value = !0, f();
|
|
5139
5140
|
}
|
|
5140
5141
|
const d = V();
|
|
5141
|
-
function w() {
|
|
5142
|
-
|
|
5143
|
-
|
|
5142
|
+
function w(D) {
|
|
5143
|
+
v(), typeof D == "number" && o(D);
|
|
5144
|
+
}
|
|
5145
|
+
function O() {
|
|
5146
|
+
i.value === !1 && n.value === !0 && t.value.forEach((D) => {
|
|
5147
|
+
D.open = !1;
|
|
5144
5148
|
});
|
|
5145
5149
|
}
|
|
5146
|
-
return cl(d,
|
|
5147
|
-
closeNavigation:
|
|
5148
|
-
|
|
5150
|
+
return cl(d, O), e({
|
|
5151
|
+
closeNavigation: O,
|
|
5152
|
+
restorePinnedNavigation: w
|
|
5153
|
+
}), (D, N) => (p(), T("div", {
|
|
5149
5154
|
ref_key: "navElement",
|
|
5150
5155
|
ref: d,
|
|
5151
5156
|
class: "cl-flex cl-flex-nowrap cl-relative"
|
|
5152
5157
|
}, [
|
|
5153
5158
|
b("div", {
|
|
5154
5159
|
id: "group-container",
|
|
5155
|
-
class:
|
|
5156
|
-
"cl-bg-primary-default":
|
|
5157
|
-
"cl-bg-blue-dark":
|
|
5160
|
+
class: U(["cl-h-full cl-overflow-y-auto cl-overscroll-y-none cl-pb-20 cl-w-20 cl-z-40 xl:cl-pb-0", {
|
|
5161
|
+
"cl-bg-primary-default": D.colour === "default",
|
|
5162
|
+
"cl-bg-blue-dark": D.colour === "secondary"
|
|
5158
5163
|
}])
|
|
5159
5164
|
}, [
|
|
5160
|
-
|
|
5165
|
+
x(D.$slots, "icon", ue({ navcolour: D.colour }, { groupIsOpen: s, toggleOpen: o }), void 0, !0)
|
|
5161
5166
|
], 2),
|
|
5162
|
-
c.value ? (p(), T("div", Hr)) :
|
|
5163
|
-
E($e, {
|
|
5164
|
-
name: "slide-right",
|
|
5165
|
-
onAfterEnter: A[0] || (A[0] = (I) => l("open-state", n.value)),
|
|
5166
|
-
onAfterLeave: A[1] || (A[1] = (I) => l("open-state", n.value))
|
|
5167
|
-
}, {
|
|
5167
|
+
c.value ? (p(), T("div", Hr)) : P("", !0),
|
|
5168
|
+
E($e, { name: "slide-right" }, {
|
|
5168
5169
|
default: Q(() => [
|
|
5169
5170
|
ee(b("div", {
|
|
5170
|
-
class:
|
|
5171
|
+
class: U(["cl-bg-grey-0 cl-border-grey-2 cl-border-r cl-duration-75 cl-h-full cl-min-w-[260px] cl-overflow-y-auto cl-overscroll-y-none cl-p-8 cl-pb-24 cl-top-0 cl-transition-shadow cl-w-[260px] cl-z-30 xl:cl-pb-0", {
|
|
5171
5172
|
"cl-relative": i.value,
|
|
5172
5173
|
"cl-absolute cl-left-20 cl-shadow-lg": !i.value
|
|
5173
5174
|
}])
|
|
@@ -5175,7 +5176,7 @@ const Er = {
|
|
|
5175
5176
|
b("div", Gr, [
|
|
5176
5177
|
b("span", {
|
|
5177
5178
|
class: "cl-absolute cl-cursor-pointer cl-hidden cl-right-0 cl-top-1.5 lg:cl-block",
|
|
5178
|
-
onClick: v
|
|
5179
|
+
onClick: N[0] || (N[0] = () => v())
|
|
5179
5180
|
}, [
|
|
5180
5181
|
i.value ? (p(), Z(h(H), {
|
|
5181
5182
|
key: 1,
|
|
@@ -5185,7 +5186,7 @@ const Er = {
|
|
|
5185
5186
|
icon: "ph:push-pin"
|
|
5186
5187
|
}))
|
|
5187
5188
|
]),
|
|
5188
|
-
|
|
5189
|
+
x(D.$slots, "default", de(ve({ groupIsOpen: s })), void 0, !0)
|
|
5189
5190
|
])
|
|
5190
5191
|
], 2), [
|
|
5191
5192
|
[te, n.value]
|
|
@@ -5196,7 +5197,7 @@ const Er = {
|
|
|
5196
5197
|
], 512));
|
|
5197
5198
|
}
|
|
5198
5199
|
});
|
|
5199
|
-
const Kr = /* @__PURE__ */ Te(Zr, [["__scopeId", "data-v-
|
|
5200
|
+
const Kr = /* @__PURE__ */ Te(Zr, [["__scopeId", "data-v-c9a98297"]]), Wr = /* @__PURE__ */ K({
|
|
5200
5201
|
__name: "cl-ui-navigation-icon",
|
|
5201
5202
|
props: {
|
|
5202
5203
|
iconValue: {},
|
|
@@ -5205,7 +5206,7 @@ const Kr = /* @__PURE__ */ Te(Zr, [["__scopeId", "data-v-9950f94e"]]), Wr = /* @
|
|
|
5205
5206
|
},
|
|
5206
5207
|
setup(a) {
|
|
5207
5208
|
return (e, l) => (p(), T("div", {
|
|
5208
|
-
class:
|
|
5209
|
+
class: U(["cl-cursor-pointer cl-flex cl-h-20 cl-items-center cl-justify-center cl-transition-colors cl-w-20", {
|
|
5209
5210
|
"cl-text-secondary-default hover:cl-bg-primary-dark hover:cl-text-white": e.colour === "default",
|
|
5210
5211
|
"cl-bg-primary-darker cl-text-white": e.open && e.colour === "default",
|
|
5211
5212
|
"cl-text-white hover:cl-bg-blue-light": e.colour === "secondary",
|
|
@@ -5229,15 +5230,15 @@ const Kr = /* @__PURE__ */ Te(Zr, [["__scopeId", "data-v-9950f94e"]]), Wr = /* @
|
|
|
5229
5230
|
},
|
|
5230
5231
|
setup(a) {
|
|
5231
5232
|
return (e, l) => (p(), T("div", {
|
|
5232
|
-
class:
|
|
5233
|
+
class: U({
|
|
5233
5234
|
"cl-hidden": !e.open
|
|
5234
5235
|
})
|
|
5235
5236
|
}, [
|
|
5236
5237
|
e.$slots.title ? (p(), T("div", Qr, [
|
|
5237
|
-
|
|
5238
|
-
])) :
|
|
5238
|
+
x(e.$slots, "title")
|
|
5239
|
+
])) : P("", !0),
|
|
5239
5240
|
b("div", Yr, [
|
|
5240
|
-
|
|
5241
|
+
x(e.$slots, "default")
|
|
5241
5242
|
])
|
|
5242
5243
|
], 2));
|
|
5243
5244
|
}
|
|
@@ -5248,17 +5249,17 @@ const Kr = /* @__PURE__ */ Te(Zr, [["__scopeId", "data-v-9950f94e"]]), Wr = /* @
|
|
|
5248
5249
|
function ai(a, e) {
|
|
5249
5250
|
return p(), T("div", ei, [
|
|
5250
5251
|
a.$slots.title ? (p(), T("div", li, [
|
|
5251
|
-
|
|
5252
|
-
])) :
|
|
5252
|
+
x(a.$slots, "title")
|
|
5253
|
+
])) : P("", !0),
|
|
5253
5254
|
b("span", ti, [
|
|
5254
|
-
|
|
5255
|
+
x(a.$slots, "default")
|
|
5255
5256
|
])
|
|
5256
5257
|
]);
|
|
5257
5258
|
}
|
|
5258
5259
|
const ni = /* @__PURE__ */ Te(Xr, [["render", ai]]), oi = {}, ri = { class: "cl-cursor-pointer cl-transition-colors cl-w-full hover:cl-text-primary-darker" };
|
|
5259
5260
|
function ii(a, e) {
|
|
5260
5261
|
return p(), T("div", ri, [
|
|
5261
|
-
|
|
5262
|
+
x(a.$slots, "default")
|
|
5262
5263
|
]);
|
|
5263
5264
|
}
|
|
5264
5265
|
const si = /* @__PURE__ */ Te(oi, [["render", ii]]), ci = { class: "cl-w-full" }, ui = /* @__PURE__ */ K({
|
|
@@ -5301,11 +5302,11 @@ const si = /* @__PURE__ */ Te(oi, [["render", ii]]), ci = { class: "cl-w-full" }
|
|
|
5301
5302
|
icon: "ph:caret-left",
|
|
5302
5303
|
class: "cl-mt-4 cl-text-secondary-default"
|
|
5303
5304
|
})
|
|
5304
|
-
])) :
|
|
5305
|
+
])) : P("", !0),
|
|
5305
5306
|
b("div", {
|
|
5306
5307
|
ref_key: "headerContainer",
|
|
5307
5308
|
ref: l,
|
|
5308
|
-
class:
|
|
5309
|
+
class: U(["cl-flex cl-overflow-x-auto cl-overscroll-x-none", {
|
|
5309
5310
|
"cl-shadow-[inset_0_-1px_0_#eeeeee]": !c.disabled && c.colour === "default",
|
|
5310
5311
|
"cl-shadow-[inset_0_-1px_0_#dae32c]": !c.disabled && c.colour === "primary",
|
|
5311
5312
|
"cl-shadow-[inset_0_-1px_0_#30363e]": !c.disabled && c.colour === "secondary",
|
|
@@ -5316,7 +5317,7 @@ const si = /* @__PURE__ */ Te(oi, [["render", ii]]), ci = { class: "cl-w-full" }
|
|
|
5316
5317
|
}]),
|
|
5317
5318
|
onScrollPassive: o
|
|
5318
5319
|
}, [
|
|
5319
|
-
|
|
5320
|
+
x(c.$slots, "headings", de(ve({ isTabOpen: s, disabled: c.disabled, colour: c.colour })))
|
|
5320
5321
|
], 34),
|
|
5321
5322
|
n.value ? (p(), T("div", {
|
|
5322
5323
|
key: 1,
|
|
@@ -5327,9 +5328,9 @@ const si = /* @__PURE__ */ Te(oi, [["render", ii]]), ci = { class: "cl-w-full" }
|
|
|
5327
5328
|
icon: "ph:caret-right",
|
|
5328
5329
|
class: "cl-mt-4 cl-text-secondary-default"
|
|
5329
5330
|
})
|
|
5330
|
-
])) :
|
|
5331
|
+
])) : P("", !0)
|
|
5331
5332
|
]),
|
|
5332
|
-
|
|
5333
|
+
x(c.$slots, "content", de(ve({ isTabOpen: s, disabled: c.disabled, colour: c.colour })))
|
|
5333
5334
|
]));
|
|
5334
5335
|
}
|
|
5335
5336
|
}), di = ["onKeyup"], fi = /* @__PURE__ */ K({
|
|
@@ -5344,12 +5345,12 @@ const si = /* @__PURE__ */ Te(oi, [["render", ii]]), ci = { class: "cl-w-full" }
|
|
|
5344
5345
|
"update:currentTab": null
|
|
5345
5346
|
},
|
|
5346
5347
|
setup(a, { emit: e }) {
|
|
5347
|
-
const l = a, t = V(), n = V(), s =
|
|
5348
|
+
const l = a, t = V(), n = V(), s = F(() => l.id === l.currentTab);
|
|
5348
5349
|
function o() {
|
|
5349
5350
|
l.disabled || (t.value = !1, n.value = !1, e("update:currentTab", l.id));
|
|
5350
5351
|
}
|
|
5351
5352
|
return (r, i) => (p(), T("div", {
|
|
5352
|
-
class:
|
|
5353
|
+
class: U(["cl-border-b cl-cursor-pointer cl-flex cl-items-center cl-px-4 cl-py-2 cl-rounded-b-none cl-rounded-sm cl-select-none cl-text-xl cl-transition cl-whitespace-nowrap focus:cl-outline-none", {
|
|
5353
5354
|
"!cl-cursor-default cl-text-grey-4 !cl-border-grey-2": r.disabled,
|
|
5354
5355
|
"cl-border cl-border-b-0 cl-rounded-t-md cl-shadow-[inset_0_-1px_0_#ffffff] cl-cursor-default": s.value,
|
|
5355
5356
|
"cl-border-grey-0": r.colour === "default",
|
|
@@ -5376,12 +5377,12 @@ const si = /* @__PURE__ */ Te(oi, [["render", ii]]), ci = { class: "cl-w-full" }
|
|
|
5376
5377
|
onFocusout: i[3] || (i[3] = (c) => t.value = !1),
|
|
5377
5378
|
onKeyup: Ae(oe(o, ["self"]), ["enter"])
|
|
5378
5379
|
}, [
|
|
5379
|
-
|
|
5380
|
+
x(r.$slots, "default")
|
|
5380
5381
|
], 42, di));
|
|
5381
5382
|
}
|
|
5382
5383
|
}), pi = {};
|
|
5383
5384
|
function mi(a, e) {
|
|
5384
|
-
return
|
|
5385
|
+
return x(a.$slots, "default");
|
|
5385
5386
|
}
|
|
5386
5387
|
const vi = /* @__PURE__ */ Te(pi, [["render", mi]]), hi = [
|
|
5387
5388
|
"default",
|