@citruslime/ui 2.4.7-beta.0 → 2.4.7-beta.2
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,9 +1,9 @@
|
|
|
1
1
|
import { Icon as U } from "@iconify/vue";
|
|
2
|
-
import { defineComponent as B, ref as I, openBlock as u, createElementBlock as
|
|
2
|
+
import { defineComponent as B, ref as I, openBlock as u, createElementBlock as v, renderSlot as j, normalizeProps as oe, guardReactiveProps as ae, Fragment as D, createElementVNode as f, normalizeClass as _, createVNode as C, unref as p, Transition as ve, withCtx as P, withDirectives as H, mergeProps as re, vShow as Z, createBlock as V, Teleport as Re, renderList as ee, toDisplayString as S, createCommentVNode as N, nextTick as Ce, toHandlers as ol, withModifiers as Q, computed as A, useCssVars as sl, watch as Y, vModelText as nl, onMounted as Ae, vModelDynamic as al, withKeys as ke, onUnmounted as ze, resolveComponent as rl, createTextVNode as te, watchEffect as il, createSlots as Ue, normalizeStyle as cl } from "vue";
|
|
3
3
|
import { generateStringId as ul } from "@citruslime/utils";
|
|
4
4
|
import { onClickOutside as Me, useTimeoutFn as Qe, useDebounceFn as Ye, useWindowSize as dl } from "@vueuse/core";
|
|
5
5
|
import { createI18n as pl, useI18n as se } from "vue-i18n";
|
|
6
|
-
import { DateTime as
|
|
6
|
+
import { DateTime as x } from "luxon";
|
|
7
7
|
import { DatePicker as Le } from "v-calendar";
|
|
8
8
|
import { useDebouncer as fl, copy as ce } from "@citruslime/vue-utils";
|
|
9
9
|
const ml = { class: "cl-overflow-hidden" }, gl = /* @__PURE__ */ B({
|
|
@@ -26,7 +26,7 @@ const ml = { class: "cl-overflow-hidden" }, gl = /* @__PURE__ */ B({
|
|
|
26
26
|
i.id !== d && (i.open = !1);
|
|
27
27
|
}), a.open = !a.open);
|
|
28
28
|
}
|
|
29
|
-
return (d, a) => (u(),
|
|
29
|
+
return (d, a) => (u(), v("div", ml, [
|
|
30
30
|
j(d.$slots, "default", oe(ae({ isItemOpen: l, toggleItem: s })))
|
|
31
31
|
]));
|
|
32
32
|
}
|
|
@@ -45,7 +45,7 @@ const ml = { class: "cl-overflow-hidden" }, gl = /* @__PURE__ */ B({
|
|
|
45
45
|
function l() {
|
|
46
46
|
e.disabled || o("toggle");
|
|
47
47
|
}
|
|
48
|
-
return (s, d) => (u(),
|
|
48
|
+
return (s, d) => (u(), v(D, null, [
|
|
49
49
|
f("div", {
|
|
50
50
|
class: _(["cl-border-b cl-border-grey-1 cl-relative", {
|
|
51
51
|
"cl-bg-grey-0": s.disabled,
|
|
@@ -69,7 +69,7 @@ const ml = { class: "cl-overflow-hidden" }, gl = /* @__PURE__ */ B({
|
|
|
69
69
|
f("div", hl, [
|
|
70
70
|
C(ve, { name: "grow-down" }, {
|
|
71
71
|
default: P(() => [
|
|
72
|
-
|
|
72
|
+
H(f("div", re(s.$attrs, { class: "cl-ml-10 cl-p-4" }), [
|
|
73
73
|
j(s.$slots, "default")
|
|
74
74
|
], 16), [
|
|
75
75
|
[Z, s.open]
|
|
@@ -87,7 +87,7 @@ const ml = { class: "cl-overflow-hidden" }, gl = /* @__PURE__ */ B({
|
|
|
87
87
|
return e;
|
|
88
88
|
}, wl = {}, $l = { 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 kl(t, o) {
|
|
90
|
-
return u(),
|
|
90
|
+
return u(), v("div", $l, [
|
|
91
91
|
j(t.$slots, "default")
|
|
92
92
|
]);
|
|
93
93
|
}
|
|
@@ -121,7 +121,7 @@ const Tl = ["onClick"], Ol = { class: "cl-flex-1 cl-select-none cl-text-ellipsis
|
|
|
121
121
|
"cl-bottom-5 cl-right-5": o.position === "bottom-right"
|
|
122
122
|
}])
|
|
123
123
|
}, [
|
|
124
|
-
(u(!0),
|
|
124
|
+
(u(!0), v(D, null, ee(p(qe), (l, s) => (u(), v("div", re(o.$attrs, {
|
|
125
125
|
key: s,
|
|
126
126
|
class: ["cl-break-words cl-cursor-pointer cl-flex cl-font-semibold cl-group cl-mb-2 cl-overflow-hidden cl-p-4 cl-rounded cl-shadow-lg cl-text-sm", {
|
|
127
127
|
"cl-bg-white": l.colour === "default",
|
|
@@ -149,7 +149,7 @@ const Tl = ["onClick"], Ol = { class: "cl-flex-1 cl-select-none cl-text-ellipsis
|
|
|
149
149
|
removePadding: { type: Boolean, default: !1 }
|
|
150
150
|
},
|
|
151
151
|
setup(t) {
|
|
152
|
-
return (o, e) => (u(),
|
|
152
|
+
return (o, e) => (u(), v(D, null, [
|
|
153
153
|
C(Xe, {
|
|
154
154
|
class: _({
|
|
155
155
|
"first:cl-mt-[4.25rem]": o.$slots.header
|
|
@@ -165,8 +165,8 @@ const Tl = ["onClick"], Ol = { class: "cl-flex-1 cl-select-none cl-text-ellipsis
|
|
|
165
165
|
j(o.$slots, "navigation"),
|
|
166
166
|
f("div", {
|
|
167
167
|
class: _(["cl-grow cl-max-h-full cl-overflow-x-hidden cl-overflow-y-auto cl-overscroll-y-none cl-w-auto", {
|
|
168
|
-
"
|
|
169
|
-
"lg:cl-pb-8 md:cl-px-8 cl-px-2 md:cl-pt-8 cl-pt-2
|
|
168
|
+
"lg:cl-pb-0": o.removePadding,
|
|
169
|
+
"lg:cl-pb-8 md:cl-px-8 cl-px-2 md:cl-pt-8 cl-pt-2": !o.removePadding
|
|
170
170
|
}])
|
|
171
171
|
}, [
|
|
172
172
|
j(o.$slots, "default")
|
|
@@ -178,7 +178,7 @@ const Tl = ["onClick"], Ol = { class: "cl-flex-1 cl-select-none cl-text-ellipsis
|
|
|
178
178
|
});
|
|
179
179
|
const ql = {}, Al = { class: "loading-spinner" };
|
|
180
180
|
function Il(t, o) {
|
|
181
|
-
return u(),
|
|
181
|
+
return u(), v("div", Al);
|
|
182
182
|
}
|
|
183
183
|
const Ie = /* @__PURE__ */ me(ql, [["render", Il], ["__scopeId", "data-v-a21dc5d2"]]), Nl = ["disabled"], ge = /* @__PURE__ */ B({
|
|
184
184
|
inheritAttrs: !1,
|
|
@@ -195,11 +195,11 @@ const Ie = /* @__PURE__ */ me(ql, [["render", Il], ["__scopeId", "data-v-a21dc5d
|
|
|
195
195
|
focus() {
|
|
196
196
|
e.value && e.value.focus();
|
|
197
197
|
}
|
|
198
|
-
}), (l, s) => (u(),
|
|
199
|
-
|
|
198
|
+
}), (l, s) => (u(), v(D, null, [
|
|
199
|
+
H(C(Ie, { class: "relative" }, null, 512), [
|
|
200
200
|
[Z, l.loading]
|
|
201
201
|
]),
|
|
202
|
-
|
|
202
|
+
H(f("button", re(l.$attrs, {
|
|
203
203
|
ref_key: "buttonRef",
|
|
204
204
|
ref: e,
|
|
205
205
|
class: ["cl-align-middle cl-border cl-font-semibold cl-inline-block cl-rounded cl-select-none cl-shadow cl-text-center cl-transition-colors", {
|
|
@@ -240,15 +240,15 @@ const Ie = /* @__PURE__ */ me(ql, [["render", Il], ["__scopeId", "data-v-a21dc5d
|
|
|
240
240
|
hover: { type: Boolean, default: !1 }
|
|
241
241
|
},
|
|
242
242
|
setup(t) {
|
|
243
|
-
return (o, e) => (u(),
|
|
243
|
+
return (o, e) => (u(), v("div", {
|
|
244
244
|
class: _(["cl-border cl-border-transparent cl-overflow-hidden cl-relative cl-rounded-md cl-shadow-lg cl-transition-all", {
|
|
245
245
|
"cl-cursor-pointer hover:cl-shadow-xl hover:cl-border-grey-0": o.hover
|
|
246
246
|
}])
|
|
247
247
|
}, [
|
|
248
|
-
o.$slots.image ? (u(),
|
|
248
|
+
o.$slots.image ? (u(), v("div", Rl, [
|
|
249
249
|
j(o.$slots, "image")
|
|
250
250
|
])) : N("", !0),
|
|
251
|
-
o.$slots.title ? (u(),
|
|
251
|
+
o.$slots.title ? (u(), v("div", {
|
|
252
252
|
key: 1,
|
|
253
253
|
class: _(["cl-border-grey-2 cl-font-normal", {
|
|
254
254
|
"cl-p-2 cl-text-2xl cl-leading-8": o.size === "small",
|
|
@@ -269,7 +269,7 @@ const Ie = /* @__PURE__ */ me(ql, [["render", Il], ["__scopeId", "data-v-a21dc5d
|
|
|
269
269
|
}, [
|
|
270
270
|
j(o.$slots, "default")
|
|
271
271
|
], 2),
|
|
272
|
-
o.$slots.footer ? (u(),
|
|
272
|
+
o.$slots.footer ? (u(), v("div", {
|
|
273
273
|
key: 2,
|
|
274
274
|
class: _(["cl-border-grey-2 cl-border-t", {
|
|
275
275
|
"cl-p-2": o.size === "small",
|
|
@@ -478,9 +478,9 @@ function Ll(t, o, e, l, s) {
|
|
|
478
478
|
i = l >= (Number(t) || 0), a = pe(i, de("input.greaterOrEqualToValue", { label: e, min: t.toString() }));
|
|
479
479
|
break;
|
|
480
480
|
case "date":
|
|
481
|
-
s ? (r =
|
|
481
|
+
s ? (r = x.fromISO(l).setZone(s), c = x.fromISO(t).setZone(s)) : (r = x.fromISO(l, {
|
|
482
482
|
zone: "UTC"
|
|
483
|
-
}), c =
|
|
483
|
+
}), c = x.fromISO(t, {
|
|
484
484
|
zone: "UTC"
|
|
485
485
|
})), i = r >= c, a = pe(i, de("input.afterOrEqualToValue", {
|
|
486
486
|
label: e,
|
|
@@ -488,9 +488,9 @@ function Ll(t, o, e, l, s) {
|
|
|
488
488
|
}));
|
|
489
489
|
break;
|
|
490
490
|
case "datetime":
|
|
491
|
-
s ? (r =
|
|
491
|
+
s ? (r = x.fromISO(l).setZone(s), c = x.fromISO(t).setZone(s)) : (r = x.fromISO(l, {
|
|
492
492
|
zone: "UTC"
|
|
493
|
-
}), c =
|
|
493
|
+
}), c = x.fromISO(t, {
|
|
494
494
|
zone: "UTC"
|
|
495
495
|
})), i = r >= c, s && (c = c.setZone(s)), a = pe(i, de("input.afterOrEqualToValue", {
|
|
496
496
|
label: e,
|
|
@@ -527,9 +527,9 @@ function Dl(t, o, e, l, s) {
|
|
|
527
527
|
i = l <= (Number(t) || 0), a = pe(i, de("input.lessOrEqualToValue", { label: e, max: t.toString() }));
|
|
528
528
|
break;
|
|
529
529
|
case "date":
|
|
530
|
-
s ? (r =
|
|
530
|
+
s ? (r = x.fromISO(l).setZone(s), c = x.fromISO(t).setZone(s)) : (r = x.fromISO(l, {
|
|
531
531
|
zone: "UTC"
|
|
532
|
-
}), c =
|
|
532
|
+
}), c = x.fromISO(t, {
|
|
533
533
|
zone: "UTC"
|
|
534
534
|
})), i = r <= c, a = pe(i, de("input.beforeOrEqualToValue", {
|
|
535
535
|
label: e,
|
|
@@ -537,9 +537,9 @@ function Dl(t, o, e, l, s) {
|
|
|
537
537
|
}));
|
|
538
538
|
break;
|
|
539
539
|
case "datetime":
|
|
540
|
-
s ? (r =
|
|
540
|
+
s ? (r = x.fromISO(l).setZone(s), c = x.fromISO(t).setZone(s)) : (r = x.fromISO(l, {
|
|
541
541
|
zone: "UTC"
|
|
542
|
-
}), c =
|
|
542
|
+
}), c = x.fromISO(t, {
|
|
543
543
|
zone: "UTC"
|
|
544
544
|
})), i = r <= c, a = pe(i, de("input.beforeOrEqualToValue", {
|
|
545
545
|
label: e,
|
|
@@ -594,7 +594,7 @@ const Hl = { class: "cl-relative" }, xl = ["value", "disabled", "placeholder"],
|
|
|
594
594
|
}
|
|
595
595
|
return o({
|
|
596
596
|
focus: l
|
|
597
|
-
}), (s, d) => (u(),
|
|
597
|
+
}), (s, d) => (u(), v("div", Hl, [
|
|
598
598
|
f("input", re({
|
|
599
599
|
ref_key: "element",
|
|
600
600
|
ref: e
|
|
@@ -604,7 +604,7 @@ const Hl = { class: "cl-relative" }, xl = ["value", "disabled", "placeholder"],
|
|
|
604
604
|
disabled: s.disabled,
|
|
605
605
|
placeholder: s.placeholder
|
|
606
606
|
}, ol(s.events, !0)), null, 16, xl),
|
|
607
|
-
|
|
607
|
+
H(C(p(U), {
|
|
608
608
|
class: _(["cl-absolute cl-bg-transparent cl-cursor-text cl-left-2 cl-text-grey-4 cl-top-3.5 icon", {
|
|
609
609
|
"!cl-bg-off-white": s.disabled
|
|
610
610
|
}]),
|
|
@@ -613,7 +613,7 @@ const Hl = { class: "cl-relative" }, xl = ["value", "disabled", "placeholder"],
|
|
|
613
613
|
}, null, 8, ["class", "icon"]), [
|
|
614
614
|
[Z, !s.disabled]
|
|
615
615
|
]),
|
|
616
|
-
s.disabled ? N("", !0) : (u(),
|
|
616
|
+
s.disabled ? N("", !0) : (u(), v("div", Zl, [
|
|
617
617
|
s.type !== "time" ? (u(), V(p(U), {
|
|
618
618
|
key: 0,
|
|
619
619
|
class: "cl-cursor-pointer hover:cl-text-link-light",
|
|
@@ -647,77 +647,77 @@ const Pe = /* @__PURE__ */ me(Gl, [["__scopeId", "data-v-d680bbf4"]]), Wl = /* @
|
|
|
647
647
|
setup(t, { expose: o, emit: e }) {
|
|
648
648
|
const l = t, s = A(() => l.timeZone ?? "UTC"), d = A({
|
|
649
649
|
get() {
|
|
650
|
-
let
|
|
651
|
-
return l.type === "time" ?
|
|
650
|
+
let h = null;
|
|
651
|
+
return l.type === "time" ? h = l.date === null ? "00:00" : l.date : l.date !== null && (h = x.fromISO(l.date, {
|
|
652
652
|
zone: s.value
|
|
653
|
-
}).toJSDate()),
|
|
653
|
+
}).toJSDate()), h;
|
|
654
654
|
},
|
|
655
|
-
set(
|
|
656
|
-
let
|
|
657
|
-
l.type === "time" ?
|
|
655
|
+
set(h) {
|
|
656
|
+
let y = null;
|
|
657
|
+
l.type === "time" ? y = h : h !== null && (y = x.fromJSDate(h, {
|
|
658
658
|
zone: s.value
|
|
659
|
-
}).setZone(s.value).toISO(), l.timeZone === null && (
|
|
659
|
+
}).setZone(s.value).toISO(), l.timeZone === null && (y = (y == null ? void 0 : y.replace("Z", "")) ?? null)), e("update:date", y);
|
|
660
660
|
}
|
|
661
661
|
}), { locale: a, t: i } = se(), r = A(() => {
|
|
662
|
-
let
|
|
662
|
+
let h;
|
|
663
663
|
switch (l.type) {
|
|
664
664
|
case "date":
|
|
665
|
-
|
|
665
|
+
h = i("calendar.datePlaceholder");
|
|
666
666
|
break;
|
|
667
667
|
case "datetime":
|
|
668
|
-
|
|
668
|
+
h = i("calendar.dateTimePlaceholder");
|
|
669
669
|
break;
|
|
670
670
|
case "time":
|
|
671
|
-
|
|
671
|
+
h = i("calendar.timePlaceholder");
|
|
672
672
|
break;
|
|
673
673
|
}
|
|
674
|
-
return l.placeholder ??
|
|
674
|
+
return l.placeholder ?? h;
|
|
675
675
|
}), c = A(() => l.disabled ? !1 : {
|
|
676
676
|
visibility: "focus",
|
|
677
677
|
showDelay: 150,
|
|
678
678
|
hideDelay: 100
|
|
679
679
|
});
|
|
680
680
|
function m() {
|
|
681
|
-
let
|
|
681
|
+
let h = k(x.now());
|
|
682
682
|
if (l.max) {
|
|
683
|
-
const
|
|
684
|
-
|
|
683
|
+
const y = x.fromISO(l.max).setZone(s.value);
|
|
684
|
+
h > y && (h = k(y), h.equals(y) || (l.type === "date" ? h = h.minus({ days: 1 }) : h = h.minus({ minutes: 1 })));
|
|
685
685
|
}
|
|
686
686
|
if (l.min) {
|
|
687
|
-
const
|
|
688
|
-
|
|
687
|
+
const y = x.fromISO(l.min).setZone(s.value);
|
|
688
|
+
h < y && (h = k(y), h.equals(y) || (l.type === "date" ? h = h.plus({ days: 1 }) : h = h.plus({ minutes: 1 })));
|
|
689
689
|
}
|
|
690
|
-
d.value =
|
|
690
|
+
d.value = h.toJSDate();
|
|
691
691
|
}
|
|
692
|
-
function k(
|
|
693
|
-
let
|
|
694
|
-
return l.type === "date" && (
|
|
692
|
+
function k(h) {
|
|
693
|
+
let y = h.set({ second: 0, millisecond: 0 }).setZone(s.value);
|
|
694
|
+
return l.type === "date" && (y = y.set({ hour: 0, minute: 0 }).setZone(s.value)), y;
|
|
695
695
|
}
|
|
696
696
|
const n = A(() => {
|
|
697
|
-
const
|
|
697
|
+
const h = x.fromObject({
|
|
698
698
|
day: 3,
|
|
699
699
|
month: 4,
|
|
700
700
|
year: 2e3,
|
|
701
701
|
hour: 5,
|
|
702
702
|
minute: 6
|
|
703
703
|
}).setLocale(a.value);
|
|
704
|
-
let
|
|
705
|
-
return l.type === "datetime" || l.type === "date" ?
|
|
706
|
-
}),
|
|
704
|
+
let y;
|
|
705
|
+
return l.type === "datetime" || l.type === "date" ? y = h.toFormat("D") : y = h.toFormat("t"), y.replace("2000", "YYYY").replace("20", "YY").replace("04", "MM").replace("4", "M").replace("03", "DD").replace("3", "D").replace("05", "HH").replace("5", "H").replace("06", "mm").replace("6", "m").replace("AM", "A").trim();
|
|
706
|
+
}), b = I(null);
|
|
707
707
|
return o({
|
|
708
708
|
focus() {
|
|
709
|
-
var
|
|
710
|
-
(
|
|
709
|
+
var h;
|
|
710
|
+
(h = b.value) == null || h.focus();
|
|
711
711
|
}
|
|
712
|
-
}), (
|
|
712
|
+
}), (h, y) => h.type === "time" ? (u(), V(p(Le), {
|
|
713
713
|
key: 0,
|
|
714
714
|
modelValue: d.value,
|
|
715
|
-
"onUpdate:modelValue":
|
|
715
|
+
"onUpdate:modelValue": y[1] || (y[1] = (T) => d.value = T),
|
|
716
716
|
modelModifiers: { string: !0 },
|
|
717
717
|
locale: p(a),
|
|
718
718
|
is24hr: p(a) !== "en-US",
|
|
719
|
-
mode:
|
|
720
|
-
"is-required":
|
|
719
|
+
mode: h.type,
|
|
720
|
+
"is-required": h.required,
|
|
721
721
|
"update-on-input": !1,
|
|
722
722
|
masks: { modelValue: "HH:mm", input: n.value },
|
|
723
723
|
color: "primary",
|
|
@@ -726,30 +726,30 @@ const Pe = /* @__PURE__ */ me(Gl, [["__scopeId", "data-v-d680bbf4"]]), Wl = /* @
|
|
|
726
726
|
popover: c.value
|
|
727
727
|
}, {
|
|
728
728
|
default: P(({ inputValue: T, inputEvents: E }) => [
|
|
729
|
-
C(Pe, re(
|
|
729
|
+
C(Pe, re(h.$attrs, {
|
|
730
730
|
ref_key: "input",
|
|
731
|
-
ref:
|
|
731
|
+
ref: b,
|
|
732
732
|
date: T,
|
|
733
733
|
events: E,
|
|
734
|
-
type:
|
|
734
|
+
type: h.type,
|
|
735
735
|
placeholder: r.value,
|
|
736
|
-
required:
|
|
737
|
-
disabled:
|
|
738
|
-
onClear:
|
|
736
|
+
required: h.required,
|
|
737
|
+
disabled: h.disabled,
|
|
738
|
+
onClear: y[0] || (y[0] = ($) => d.value = null)
|
|
739
739
|
}), null, 16, ["date", "events", "type", "placeholder", "required", "disabled"])
|
|
740
740
|
]),
|
|
741
741
|
_: 1
|
|
742
742
|
}, 8, ["modelValue", "locale", "is24hr", "mode", "is-required", "masks", "popover"])) : (u(), V(p(Le), {
|
|
743
743
|
key: 1,
|
|
744
744
|
modelValue: d.value,
|
|
745
|
-
"onUpdate:modelValue":
|
|
745
|
+
"onUpdate:modelValue": y[3] || (y[3] = (T) => d.value = T),
|
|
746
746
|
locale: p(a),
|
|
747
747
|
is24hr: p(a) !== "en-US",
|
|
748
748
|
timezone: s.value,
|
|
749
|
-
mode:
|
|
750
|
-
"min-date":
|
|
751
|
-
"max-date":
|
|
752
|
-
"is-required":
|
|
749
|
+
mode: h.type,
|
|
750
|
+
"min-date": h.min,
|
|
751
|
+
"max-date": h.max,
|
|
752
|
+
"is-required": h.required,
|
|
753
753
|
"update-on-input": !1,
|
|
754
754
|
masks: { L: n.value },
|
|
755
755
|
color: "primary",
|
|
@@ -758,16 +758,16 @@ const Pe = /* @__PURE__ */ me(Gl, [["__scopeId", "data-v-d680bbf4"]]), Wl = /* @
|
|
|
758
758
|
popover: c.value
|
|
759
759
|
}, {
|
|
760
760
|
default: P(({ inputValue: T, inputEvents: E }) => [
|
|
761
|
-
C(Pe, re(
|
|
761
|
+
C(Pe, re(h.$attrs, {
|
|
762
762
|
ref_key: "input",
|
|
763
|
-
ref:
|
|
763
|
+
ref: b,
|
|
764
764
|
date: T,
|
|
765
765
|
events: E,
|
|
766
|
-
type:
|
|
766
|
+
type: h.type,
|
|
767
767
|
placeholder: r.value,
|
|
768
|
-
required:
|
|
769
|
-
disabled:
|
|
770
|
-
onClear:
|
|
768
|
+
required: h.required,
|
|
769
|
+
disabled: h.disabled,
|
|
770
|
+
onClear: y[2] || (y[2] = ($) => d.value = null),
|
|
771
771
|
onReset: m
|
|
772
772
|
}), null, 16, ["date", "events", "type", "placeholder", "required", "disabled"])
|
|
773
773
|
]),
|
|
@@ -841,8 +841,8 @@ const Ql = [
|
|
|
841
841
|
set: (n) => e("update:value", n || l.min)
|
|
842
842
|
});
|
|
843
843
|
Y(r, (n) => a(() => {
|
|
844
|
-
const
|
|
845
|
-
r.value = l.enforceStep ? Math.ceil(
|
|
844
|
+
const b = Math.max(Math.min(n, l.max), l.min);
|
|
845
|
+
r.value = l.enforceStep ? Math.ceil(b / l.step) * l.step : b;
|
|
846
846
|
}));
|
|
847
847
|
const c = A(() => {
|
|
848
848
|
let n = (r.value - l.min) / (l.max - l.min) * 100;
|
|
@@ -855,33 +855,33 @@ const Ql = [
|
|
|
855
855
|
}
|
|
856
856
|
});
|
|
857
857
|
const k = I(!1);
|
|
858
|
-
return (n,
|
|
858
|
+
return (n, b) => m.value ? (u(), v("div", oe(re({ key: 0 }, n.$attrs)), [
|
|
859
859
|
f("div", Yl, [
|
|
860
860
|
f("span", {
|
|
861
861
|
class: _(["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", {
|
|
862
862
|
"cl-bg-white cl-cursor-pointer hover:cl-border-grey-1": !n.disabled,
|
|
863
863
|
"cl-bg-grey-0": n.disabled
|
|
864
864
|
}]),
|
|
865
|
-
onClick:
|
|
865
|
+
onClick: b[0] || (b[0] = (h) => r.value = n.disabled ? r.value : n.min)
|
|
866
866
|
}, S(p(s)(n.min, Number.isInteger(n.min) ? p(le).INTEGER : p(le).DECIMAL)), 3),
|
|
867
|
-
typeof r.value == "number" ? (u(),
|
|
867
|
+
typeof r.value == "number" ? (u(), v("div", Jl, [
|
|
868
868
|
k.value ? (u(), V(p(ie), {
|
|
869
869
|
key: 0,
|
|
870
870
|
ref_key: "sliderRef",
|
|
871
871
|
ref: i,
|
|
872
872
|
modelValue: r.value,
|
|
873
|
-
"onUpdate:modelValue":
|
|
873
|
+
"onUpdate:modelValue": b[1] || (b[1] = (h) => r.value = h),
|
|
874
874
|
class: "cl-min-w-[8.5rem] cl-w-full",
|
|
875
875
|
"input-type": "number",
|
|
876
876
|
min: n.min,
|
|
877
877
|
max: n.max,
|
|
878
878
|
step: n.step,
|
|
879
879
|
disabled: n.disabled
|
|
880
|
-
}, null, 8, ["modelValue", "min", "max", "step", "disabled"])) : (u(),
|
|
881
|
-
|
|
880
|
+
}, null, 8, ["modelValue", "min", "max", "step", "disabled"])) : (u(), v(D, { key: 1 }, [
|
|
881
|
+
H(f("input", {
|
|
882
882
|
ref_key: "sliderRef",
|
|
883
883
|
ref: i,
|
|
884
|
-
"onUpdate:modelValue":
|
|
884
|
+
"onUpdate:modelValue": b[2] || (b[2] = (h) => r.value = h),
|
|
885
885
|
class: "cl-align-middle cl-appearance-none cl-border cl-border-grey-2 cl-delay-500 cl-ease-in cl-flex-1 cl-h-5 cl-min-w-[8.5rem] cl-outline-none cl-rounded-full cl-transition-colors cl-w-full",
|
|
886
886
|
type: "range",
|
|
887
887
|
min: n.min,
|
|
@@ -904,18 +904,18 @@ const Ql = [
|
|
|
904
904
|
"cl-bg-white cl-cursor-pointer hover:cl-border-grey-1": !n.disabled,
|
|
905
905
|
"cl-bg-grey-0": n.disabled
|
|
906
906
|
}]),
|
|
907
|
-
onClick:
|
|
907
|
+
onClick: b[3] || (b[3] = (h) => r.value = n.disabled ? r.value : n.max)
|
|
908
908
|
}, S(p(s)(n.max, Number.isInteger(n.max) ? p(le).INTEGER : p(le).DECIMAL)), 3),
|
|
909
909
|
f("div", lt, [
|
|
910
910
|
f("div", tt, [
|
|
911
911
|
C(p(U), {
|
|
912
912
|
icon: "ph:arrows-left-right-thin",
|
|
913
|
-
onClick:
|
|
913
|
+
onClick: b[4] || (b[4] = (h) => k.value = !k.value)
|
|
914
914
|
})
|
|
915
915
|
])
|
|
916
916
|
])
|
|
917
917
|
])
|
|
918
|
-
], 16)) : (u(),
|
|
918
|
+
], 16)) : (u(), v("div", ot, S(p(d)("slider.invalidProps")), 1));
|
|
919
919
|
}
|
|
920
920
|
});
|
|
921
921
|
const nt = /* @__PURE__ */ me(st, [["__scopeId", "data-v-298c940f"]]);
|
|
@@ -1027,27 +1027,27 @@ const it = { class: "cl-flex cl-justify-between" }, ct = { class: "cl-w-full" },
|
|
|
1027
1027
|
},
|
|
1028
1028
|
emits: ["update:model-value", "click", "focus", "input", "change", "validated"],
|
|
1029
1029
|
setup(t, { expose: o, emit: e }) {
|
|
1030
|
-
const l = t, s = I(null), d = I(!1), a = I(!1), i = A(
|
|
1030
|
+
const l = t, s = I(null), d = I(!1), a = I(!1), i = A(F), r = A(() => l.placeholderText.trim() !== "" ? l.placeholderText : l.label), c = I(0), m = A({
|
|
1031
1031
|
get: () => l.modelValue,
|
|
1032
|
-
set: (
|
|
1032
|
+
set: (g) => M(g, !1)
|
|
1033
1033
|
}), k = A({
|
|
1034
1034
|
get: () => l.modelValue,
|
|
1035
|
-
set: (
|
|
1036
|
-
}), n = A(() => typeof l.min == "number" ? l.min.toString() : l.min),
|
|
1037
|
-
var
|
|
1035
|
+
set: (g) => w(g)
|
|
1036
|
+
}), n = A(() => typeof l.min == "number" ? l.min.toString() : l.min), b = A(() => typeof l.max == "number" ? l.max.toString() : l.max), h = A(() => typeof l.min == "number" || l.min === null ? l.min : parseFloat(l.min)), y = A(() => typeof l.max == "number" || l.max === null ? l.max : parseFloat(l.max)), T = A(() => l.messageWhenValid.trim() !== "" ? l.messageWhenValid : ""), E = I(!0), $ = I(!0), z = I([]), q = A(() => {
|
|
1037
|
+
var g, R;
|
|
1038
1038
|
return [
|
|
1039
|
-
...((
|
|
1039
|
+
...((g = z.value) == null ? void 0 : g.filter((L) => ((L == null ? void 0 : L.length) ?? 0) > 0)) ?? [],
|
|
1040
1040
|
...((R = l.externalErrors) == null ? void 0 : R.filter((L) => ((L == null ? void 0 : L.length) ?? 0) > 0)) ?? []
|
|
1041
1041
|
].join(`
|
|
1042
1042
|
`);
|
|
1043
1043
|
});
|
|
1044
|
-
async function
|
|
1045
|
-
l.validateOn === "input" && await G(
|
|
1044
|
+
async function w(g) {
|
|
1045
|
+
l.validateOn === "input" && await G(g), e("update:model-value", g);
|
|
1046
1046
|
}
|
|
1047
|
-
async function M(
|
|
1048
|
-
l.onInputFunction !== void 0 && (
|
|
1047
|
+
async function M(g, R) {
|
|
1048
|
+
l.onInputFunction !== void 0 && (g = l.onInputFunction(g)), l.validateOn === "change" && ($.value = !1), (R || l.validateOn === "input") && await G(g), e("update:model-value", g);
|
|
1049
1049
|
}
|
|
1050
|
-
function G(
|
|
1050
|
+
function G(g) {
|
|
1051
1051
|
const R = {
|
|
1052
1052
|
message: "",
|
|
1053
1053
|
valid: !0
|
|
@@ -1055,41 +1055,41 @@ const it = { class: "cl-flex cl-justify-between" }, ct = { class: "cl-w-full" },
|
|
|
1055
1055
|
l.customValidationFunction === null || l.customValidationFunction === void 0 ? new Promise((he) => {
|
|
1056
1056
|
he(R);
|
|
1057
1057
|
}) : new Promise((he) => {
|
|
1058
|
-
he(l.customValidationFunction(l.label,
|
|
1058
|
+
he(l.customValidationFunction(l.label, g));
|
|
1059
1059
|
})
|
|
1060
1060
|
];
|
|
1061
|
-
return (typeof
|
|
1061
|
+
return (typeof g == "string" || typeof g == "number") && (L.push(Ll(l.min, l.inputType, l.label, g, l.timeZone)), L.push(Dl(l.max, l.inputType, l.label, g, l.timeZone))), l.isRequired && L.push(Pl(l.label, g)), l.inputType === "email" && typeof g == "string" && L.push(Fl(l.label, g)), Promise.all(L).then((he) => {
|
|
1062
1062
|
const tl = [...he.map((Te) => Te.message)], Ve = he.some((Te) => Te.message.length > 0 && Te.valid === !1) || l.externalErrors.length > 0;
|
|
1063
|
-
$.value = !0, Ve ? (z.value = tl, e("validated", !1,
|
|
1063
|
+
$.value = !0, Ve ? (z.value = tl, e("validated", !1, g)) : (z.value = [], e("validated", !0, g)), E.value = !Ve;
|
|
1064
1064
|
});
|
|
1065
1065
|
}
|
|
1066
1066
|
function K() {
|
|
1067
|
-
let
|
|
1068
|
-
return l.inputType === "color" && m.value && (l.disabled ?
|
|
1067
|
+
let g = "";
|
|
1068
|
+
return l.inputType === "color" && m.value && (l.disabled ? g = "background: #999999" : g = `background: ${m.value};`), g;
|
|
1069
1069
|
}
|
|
1070
|
-
function ue(
|
|
1071
|
-
$e(l.inputType) ? (
|
|
1070
|
+
function ue(g) {
|
|
1071
|
+
$e(l.inputType) ? (g.preventDefault(), e("click", g)) : l.inputType === "checkbox" && e("click", g);
|
|
1072
1072
|
}
|
|
1073
|
-
function Ne(
|
|
1073
|
+
function Ne(g) {
|
|
1074
1074
|
if (s.value) {
|
|
1075
1075
|
s.value.stepUp(), s.value.focus(), M(s.value.valueAsNumber, !1);
|
|
1076
1076
|
const R = {
|
|
1077
1077
|
target: s.value
|
|
1078
1078
|
};
|
|
1079
|
-
e("input", R, s.value.valueAsNumber), e("change",
|
|
1079
|
+
e("input", R, s.value.valueAsNumber), e("change", g, s.value.valueAsNumber);
|
|
1080
1080
|
}
|
|
1081
1081
|
}
|
|
1082
|
-
function je(
|
|
1082
|
+
function je(g) {
|
|
1083
1083
|
if (s.value) {
|
|
1084
1084
|
s.value.stepDown(), s.value.focus(), M(s.value.valueAsNumber, !1);
|
|
1085
1085
|
const R = {
|
|
1086
1086
|
target: s.value
|
|
1087
1087
|
};
|
|
1088
|
-
e("input", R, s.value.valueAsNumber), e("change",
|
|
1088
|
+
e("input", R, s.value.valueAsNumber), e("change", g, s.value.valueAsNumber);
|
|
1089
1089
|
}
|
|
1090
1090
|
}
|
|
1091
|
-
function ye(
|
|
1092
|
-
d.value =
|
|
1091
|
+
function ye(g) {
|
|
1092
|
+
d.value = g;
|
|
1093
1093
|
}
|
|
1094
1094
|
async function be() {
|
|
1095
1095
|
a.value = !0, ye(!1), l.validateOn === "change" && await G(m.value);
|
|
@@ -1097,18 +1097,18 @@ const it = { class: "cl-flex cl-justify-between" }, ct = { class: "cl-w-full" },
|
|
|
1097
1097
|
function we() {
|
|
1098
1098
|
c.value++;
|
|
1099
1099
|
}
|
|
1100
|
-
function O(
|
|
1101
|
-
|
|
1100
|
+
function O(g) {
|
|
1101
|
+
g.target.blur();
|
|
1102
1102
|
}
|
|
1103
|
-
function
|
|
1103
|
+
function F() {
|
|
1104
1104
|
var L;
|
|
1105
|
-
let
|
|
1105
|
+
let g = !0;
|
|
1106
1106
|
const R = i.value;
|
|
1107
|
-
return d.value ?
|
|
1107
|
+
return d.value ? g = R : a.value && ((L = m.value) == null ? void 0 : L.toString().trim()) === "" && l.requiredText.trim() !== "" && (g = !1), !l.hideRequiredAsterisk && g;
|
|
1108
1108
|
}
|
|
1109
|
-
async function ne(
|
|
1110
|
-
const R = xe(
|
|
1111
|
-
l.validateOn === "change" && await G(R), e("change",
|
|
1109
|
+
async function ne(g) {
|
|
1110
|
+
const R = xe(g, l.inputType);
|
|
1111
|
+
l.validateOn === "change" && await G(R), e("change", g, R);
|
|
1112
1112
|
}
|
|
1113
1113
|
async function W() {
|
|
1114
1114
|
await be(), we();
|
|
@@ -1124,14 +1124,14 @@ const it = { class: "cl-flex cl-justify-between" }, ct = { class: "cl-w-full" },
|
|
|
1124
1124
|
}
|
|
1125
1125
|
), o({
|
|
1126
1126
|
focus() {
|
|
1127
|
-
var
|
|
1128
|
-
(
|
|
1127
|
+
var g;
|
|
1128
|
+
(g = s.value) == null || g.focus();
|
|
1129
1129
|
},
|
|
1130
1130
|
blur() {
|
|
1131
|
-
var
|
|
1132
|
-
(
|
|
1131
|
+
var g;
|
|
1132
|
+
(g = s.value) == null || g.blur();
|
|
1133
1133
|
}
|
|
1134
|
-
}), (
|
|
1134
|
+
}), (g, R) => (u(), v("div", re({ ...g.$attrs, id: void 0 }, {
|
|
1135
1135
|
key: c.value,
|
|
1136
1136
|
class: "cl-align-top cl-border-none cl-inline-block cl-text-left"
|
|
1137
1137
|
}), [
|
|
@@ -1141,47 +1141,47 @@ const it = { class: "cl-flex cl-justify-between" }, ct = { class: "cl-w-full" },
|
|
|
1141
1141
|
}, [
|
|
1142
1142
|
f("div", it, [
|
|
1143
1143
|
f("div", ct, [
|
|
1144
|
-
|
|
1145
|
-
[Z,
|
|
1144
|
+
H(f("label", { class: "cl-block cl-mb-1 cl-text-grey-4 cl-text-xs cl-tracking-widest" }, S(g.label), 513), [
|
|
1145
|
+
[Z, g.showLabel && g.label !== ""]
|
|
1146
1146
|
])
|
|
1147
1147
|
]),
|
|
1148
|
-
|
|
1149
|
-
|
|
1148
|
+
g.isRequired && i.value ? (u(), v("label", ut, " * ")) : N("", !0),
|
|
1149
|
+
g.isRequired && !i.value && g.requiredText.length ? (u(), v("label", dt, S(g.requiredText), 1)) : N("", !0)
|
|
1150
1150
|
]),
|
|
1151
|
-
|
|
1152
|
-
|
|
1151
|
+
g.inputType !== "range" && !p(He)(g.inputType) ? (u(), v("div", pt, [
|
|
1152
|
+
H(f("input", re({
|
|
1153
1153
|
ref_key: "inputElement",
|
|
1154
1154
|
ref: s,
|
|
1155
1155
|
"onUpdate:modelValue": R[0] || (R[0] = (L) => m.value = L)
|
|
1156
|
-
},
|
|
1156
|
+
}, g.$attrs, {
|
|
1157
1157
|
class: ["!cl-mb-1 cl-block cl-border cl-duration-300 cl-h-full cl-transition cl-w-full focus:cl-outline-none", {
|
|
1158
|
-
"hover:!cl-border-grey-3":
|
|
1159
|
-
"!cl-cursor-default":
|
|
1158
|
+
"hover:!cl-border-grey-3": g.disabled === !1 && !p($e)(g.inputType),
|
|
1159
|
+
"!cl-cursor-default": g.disabled,
|
|
1160
1160
|
"!cl-border-danger-default": !E.value,
|
|
1161
|
-
"!cl-border-primary-default": E.value &&
|
|
1162
|
-
"cl-border-grey-0 focus:cl-border-blue-light": E.value && !p($e)(
|
|
1163
|
-
"!cl-p-2":
|
|
1164
|
-
"cl-p-3 cl-rounded-lg": !p($e)(
|
|
1165
|
-
[`${
|
|
1161
|
+
"!cl-border-primary-default": E.value && g.highlightWhenValid,
|
|
1162
|
+
"cl-border-grey-0 focus:cl-border-blue-light": E.value && !p($e)(g.inputType),
|
|
1163
|
+
"!cl-p-2": g.inputType === "checkbox" || g.inputType === "radio",
|
|
1164
|
+
"cl-p-3 cl-rounded-lg": !p($e)(g.inputType),
|
|
1165
|
+
[`${g.inputSpecificClasses}`]: g.inputSpecificClasses !== ""
|
|
1166
1166
|
}],
|
|
1167
1167
|
style: K(),
|
|
1168
|
-
type:
|
|
1169
|
-
disabled:
|
|
1170
|
-
min:
|
|
1171
|
-
max:
|
|
1172
|
-
minlength:
|
|
1173
|
-
maxlength:
|
|
1174
|
-
step:
|
|
1168
|
+
type: g.inputType,
|
|
1169
|
+
disabled: g.disabled,
|
|
1170
|
+
min: g.min ?? void 0,
|
|
1171
|
+
max: g.max ?? void 0,
|
|
1172
|
+
minlength: g.min !== null && p(Fe)(g.inputType) ? g.min : void 0,
|
|
1173
|
+
maxlength: g.max !== null && p(Fe)(g.inputType) ? g.max : void 0,
|
|
1174
|
+
step: g.step,
|
|
1175
1175
|
placeholder: r.value,
|
|
1176
|
-
accept:
|
|
1177
|
-
name:
|
|
1178
|
-
autocomplete:
|
|
1176
|
+
accept: g.fileExtensions,
|
|
1177
|
+
name: g.group,
|
|
1178
|
+
autocomplete: g.autocomplete,
|
|
1179
1179
|
onClick: R[1] || (R[1] = (L) => ue(L)),
|
|
1180
1180
|
onFocus: R[2] || (R[2] = (L) => e("focus")),
|
|
1181
1181
|
onBlur: Q(W, ["self"]),
|
|
1182
1182
|
onMousewheelPassive: O,
|
|
1183
1183
|
onInput: R[3] || (R[3] = (L) => {
|
|
1184
|
-
e("input", L, p(xe)(L,
|
|
1184
|
+
e("input", L, p(xe)(L, g.inputType));
|
|
1185
1185
|
}),
|
|
1186
1186
|
onChange: ne
|
|
1187
1187
|
}), null, 16, ft), [
|
|
@@ -1192,7 +1192,7 @@ const it = { class: "cl-flex cl-justify-between" }, ct = { class: "cl-w-full" },
|
|
|
1192
1192
|
duration: 300
|
|
1193
1193
|
}, {
|
|
1194
1194
|
default: P(() => [
|
|
1195
|
-
|
|
1195
|
+
g.inputType === "number" && !g.disabled && g.showArrows ? H((u(), v("div", mt, [
|
|
1196
1196
|
C(p(U), {
|
|
1197
1197
|
icon: "ph:caret-up-bold",
|
|
1198
1198
|
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",
|
|
@@ -1213,43 +1213,43 @@ const it = { class: "cl-flex cl-justify-between" }, ct = { class: "cl-w-full" },
|
|
|
1213
1213
|
]),
|
|
1214
1214
|
_: 1
|
|
1215
1215
|
})
|
|
1216
|
-
])) : p(He)(
|
|
1216
|
+
])) : p(He)(g.inputType) ? (u(), V(p(Wl), re({ key: 1 }, g.$attrs, {
|
|
1217
1217
|
ref_key: "inputElement",
|
|
1218
1218
|
ref: s,
|
|
1219
1219
|
date: k.value,
|
|
1220
1220
|
"onUpdate:date": R[6] || (R[6] = (L) => k.value = L),
|
|
1221
1221
|
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", {
|
|
1222
|
-
"hover:cl-border-grey-3": !
|
|
1222
|
+
"hover:cl-border-grey-3": !g.disabled,
|
|
1223
1223
|
"!cl-border-danger-default": !E.value,
|
|
1224
|
-
"!cl-border-primary-default": E.value &&
|
|
1224
|
+
"!cl-border-primary-default": E.value && g.highlightWhenValid
|
|
1225
1225
|
}],
|
|
1226
|
-
disabled:
|
|
1227
|
-
required:
|
|
1228
|
-
type: p(rt)(
|
|
1229
|
-
"time-zone":
|
|
1226
|
+
disabled: g.disabled,
|
|
1227
|
+
required: g.isRequired,
|
|
1228
|
+
type: p(rt)(g.inputType),
|
|
1229
|
+
"time-zone": g.timeZone,
|
|
1230
1230
|
min: n.value,
|
|
1231
|
-
max:
|
|
1231
|
+
max: b.value,
|
|
1232
1232
|
placeholder: r.value,
|
|
1233
1233
|
onBlur: Q(be, ["self"]),
|
|
1234
1234
|
onFocus: R[7] || (R[7] = (L) => e("focus"))
|
|
1235
|
-
}), null, 16, ["date", "class", "disabled", "required", "type", "time-zone", "min", "max", "placeholder", "onBlur"])) :
|
|
1235
|
+
}), null, 16, ["date", "class", "disabled", "required", "type", "time-zone", "min", "max", "placeholder", "onBlur"])) : g.inputType === "range" && typeof m.value == "number" ? (u(), v("div", gt, [
|
|
1236
1236
|
C(p(nt), {
|
|
1237
1237
|
ref_key: "inputElement",
|
|
1238
1238
|
ref: s,
|
|
1239
1239
|
value: m.value,
|
|
1240
1240
|
"onUpdate:value": R[8] || (R[8] = (L) => m.value = L),
|
|
1241
|
-
min:
|
|
1242
|
-
max:
|
|
1243
|
-
step:
|
|
1241
|
+
min: h.value ?? 0,
|
|
1242
|
+
max: y.value ?? 1e3,
|
|
1243
|
+
step: g.step,
|
|
1244
1244
|
"enforce-step": !0,
|
|
1245
|
-
disabled:
|
|
1245
|
+
disabled: g.disabled,
|
|
1246
1246
|
onBlur: Q(be, ["self"]),
|
|
1247
1247
|
onFocus: R[9] || (R[9] = (L) => e("focus"))
|
|
1248
1248
|
}, null, 8, ["value", "min", "max", "step", "disabled", "onBlur"])
|
|
1249
1249
|
])) : N("", !0)
|
|
1250
1250
|
], 32),
|
|
1251
|
-
E.value && T.value && $.value ? (u(),
|
|
1252
|
-
!E.value && q.value.length > 0 &&
|
|
1251
|
+
E.value && T.value && $.value ? (u(), v("div", vt, S(T.value), 1)) : N("", !0),
|
|
1252
|
+
!E.value && q.value.length > 0 && g.showValidationMessages && $.value ? (u(), v("div", bt, S(q.value), 1)) : N("", !0)
|
|
1253
1253
|
], 16));
|
|
1254
1254
|
}
|
|
1255
1255
|
});
|
|
@@ -1272,12 +1272,12 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1272
1272
|
function d(a) {
|
|
1273
1273
|
a.key === "Escape" && s();
|
|
1274
1274
|
}
|
|
1275
|
-
return (a, i) => (u(),
|
|
1275
|
+
return (a, i) => (u(), v(D, null, [
|
|
1276
1276
|
j(a.$slots, "trigger", oe(ae({ open: l }))),
|
|
1277
1277
|
(u(), V(Re, { to: "body" }, [
|
|
1278
1278
|
C(ve, { name: "fade" }, {
|
|
1279
1279
|
default: P(() => [
|
|
1280
|
-
|
|
1280
|
+
H(f("div", yt, [
|
|
1281
1281
|
f("div", re(a.$attrs, {
|
|
1282
1282
|
class: ["cl-bg-white cl-flex cl-flex-wrap cl-max-h-[calc(100%-8rem)] cl-mx-0 cl-my-auto cl-overflow-y-auto cl-overscroll-y-none cl-relative cl-rounded-lg cl-shadow-lg xl:cl-max-h-[calc(100vh-8rem)]", {
|
|
1283
1283
|
"lg:cl-w-2/12 cl-w-10/12": a.size === "x-small",
|
|
@@ -1286,7 +1286,7 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1286
1286
|
"cl-w-10/12": a.size === "large"
|
|
1287
1287
|
}]
|
|
1288
1288
|
}), [
|
|
1289
|
-
|
|
1289
|
+
H(f("div", {
|
|
1290
1290
|
class: _(["cl-absolute cl-cursor-pointer cl-right-4 cl-top-4 cl-transition-colors cl-w-3", {
|
|
1291
1291
|
"cl-text-white hover:cl-text-off-white": a.headerColour === "secondary" || a.headerColour === "primary",
|
|
1292
1292
|
"cl-text-black hover:cl-text-grey-7": a.headerColour === "white"
|
|
@@ -1336,15 +1336,15 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1336
1336
|
"clear-object": null
|
|
1337
1337
|
},
|
|
1338
1338
|
setup(t) {
|
|
1339
|
-
return (o, e) => (u(),
|
|
1340
|
-
o.additionalText !== "" ? (u(),
|
|
1339
|
+
return (o, e) => (u(), v("div", kt, [
|
|
1340
|
+
o.additionalText !== "" ? (u(), v("div", Ct, S(o.additionalText), 1)) : N("", !0),
|
|
1341
1341
|
f("div", {
|
|
1342
1342
|
class: _({
|
|
1343
1343
|
"cl-w-1/2": o.additionalText !== "",
|
|
1344
1344
|
"cl-w-full": o.additionalText === ""
|
|
1345
1345
|
})
|
|
1346
1346
|
}, S(o.text), 3),
|
|
1347
|
-
|
|
1347
|
+
H(f("div", {
|
|
1348
1348
|
class: "cl-cursor-pointer cl-float-right",
|
|
1349
1349
|
onMousedown: e[0] || (e[0] = (l) => o.$emit("clear-object"))
|
|
1350
1350
|
}, [
|
|
@@ -1394,24 +1394,24 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1394
1394
|
}
|
|
1395
1395
|
return Y(() => e.selectedIndex, () => r()), (c, m) => {
|
|
1396
1396
|
var k, n;
|
|
1397
|
-
return u(),
|
|
1397
|
+
return u(), v("div", {
|
|
1398
1398
|
class: _(["cl-cursor-pointer cl-duration-75 cl-flex cl-p-1 cl-text-left cl-transition-colors", {
|
|
1399
1399
|
"cl-bg-white": d.value === !1,
|
|
1400
1400
|
"cl-bg-link-light cl-text-white cl-opacity-90": d.value && c.isCreateNewOption === !1,
|
|
1401
1401
|
"cl-bg-primary-default cl-text-white cl-opacity-90": d.value && c.isCreateNewOption
|
|
1402
1402
|
}]),
|
|
1403
1403
|
onMousedown: a,
|
|
1404
|
-
onMousemove: m[0] || (m[0] = (
|
|
1405
|
-
onMouseleave: m[1] || (m[1] = (
|
|
1404
|
+
onMousemove: m[0] || (m[0] = (b) => i(!0)),
|
|
1405
|
+
onMouseleave: m[1] || (m[1] = (b) => i(!1))
|
|
1406
1406
|
}, [
|
|
1407
|
-
c.option !== null && ((k = c.option) == null ? void 0 : k.parentId) !== 0 && ((n = c.option) == null ? void 0 : n.parentId) !== void 0 ? (u(),
|
|
1407
|
+
c.option !== null && ((k = c.option) == null ? void 0 : k.parentId) !== 0 && ((n = c.option) == null ? void 0 : n.parentId) !== void 0 ? (u(), v("div", Tt, S(s.value), 1)) : N("", !0),
|
|
1408
1408
|
f("div", {
|
|
1409
1409
|
class: _({
|
|
1410
1410
|
"cl-w-1/2": s.value !== "",
|
|
1411
1411
|
"cl-w-full": s.value === ""
|
|
1412
1412
|
})
|
|
1413
1413
|
}, S(l.value), 3),
|
|
1414
|
-
|
|
1414
|
+
H(f("div", Ot, [
|
|
1415
1415
|
C(p(U), {
|
|
1416
1416
|
class: _(["cl-transition-colors", {
|
|
1417
1417
|
"cl-text-white": d.value,
|
|
@@ -1448,11 +1448,11 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1448
1448
|
},
|
|
1449
1449
|
setup(t, { emit: o }) {
|
|
1450
1450
|
const e = t, { t: l } = se(), s = I(""), d = I(!1), a = I(-1), i = A(() => d.value ? -1 : 0), r = I();
|
|
1451
|
-
function c(
|
|
1452
|
-
(
|
|
1451
|
+
function c(w) {
|
|
1452
|
+
(w === void 0 || (w == null ? void 0 : w.code.startsWith("Arrow")) === !1 && (w == null ? void 0 : w.code.startsWith("Control")) === !1 && (w == null ? void 0 : w.code.startsWith("Shift")) === !1 && (w == null ? void 0 : w.code.startsWith("Tab")) === !1 && (w == null ? void 0 : w.code) !== "Enter") && (o("search", s.value), a.value = -2);
|
|
1453
1453
|
}
|
|
1454
|
-
function m(
|
|
1455
|
-
o("select-object",
|
|
1454
|
+
function m(w) {
|
|
1455
|
+
o("select-object", w);
|
|
1456
1456
|
}
|
|
1457
1457
|
function k() {
|
|
1458
1458
|
o("create-object", s.value), n();
|
|
@@ -1460,58 +1460,58 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1460
1460
|
function n() {
|
|
1461
1461
|
o("hide-dropdown");
|
|
1462
1462
|
}
|
|
1463
|
-
function
|
|
1464
|
-
a.value < e.results.length - 1 ? (a.value === -2 && s.value === "" && a.value++, a.value++) : a.value =
|
|
1463
|
+
function b(w) {
|
|
1464
|
+
a.value < e.results.length - 1 ? (a.value === -2 && s.value === "" && a.value++, a.value++) : a.value = w, E();
|
|
1465
1465
|
}
|
|
1466
|
-
function
|
|
1467
|
-
a.value >
|
|
1466
|
+
function h(w) {
|
|
1467
|
+
a.value > w ? a.value-- : a.value = e.results.length - 1, E();
|
|
1468
1468
|
}
|
|
1469
|
-
function
|
|
1469
|
+
function y() {
|
|
1470
1470
|
a.value >= 0 && e.results !== void 0 ? m(e.results[a.value].id) : a.value === -1 && k();
|
|
1471
1471
|
}
|
|
1472
|
-
function T(
|
|
1473
|
-
if (
|
|
1472
|
+
function T(w) {
|
|
1473
|
+
if (w.key === "Tab" && w.shiftKey === !0) {
|
|
1474
1474
|
const M = document.getElementsByTagName("input");
|
|
1475
1475
|
let G = -1;
|
|
1476
1476
|
for (let K = 0; K < M.length; K++)
|
|
1477
|
-
M[K] ===
|
|
1477
|
+
M[K] === w.target && (G = K - 1);
|
|
1478
1478
|
G >= 0 && (M[G].focus(), n());
|
|
1479
1479
|
}
|
|
1480
1480
|
}
|
|
1481
1481
|
function E() {
|
|
1482
|
-
var
|
|
1483
|
-
e.results && e.results.length > 1 && ((
|
|
1482
|
+
var w;
|
|
1483
|
+
e.results && e.results.length > 1 && ((w = r.value) == null || w.scrollTo(0, (a.value + 1) * 34 - 34 * 2));
|
|
1484
1484
|
}
|
|
1485
1485
|
function $() {
|
|
1486
|
-
let
|
|
1487
|
-
e.results !== null && e.results.length === 1 && (
|
|
1486
|
+
let w = !1;
|
|
1487
|
+
e.results !== null && e.results.length === 1 && (w = s.value.toUpperCase().trim() === e.results[0].name.toUpperCase().trim()), d.value = e.canCreateNewObject === !0 && e.errorMessage === "" && s.value.trim() !== "" && w === !1;
|
|
1488
1488
|
}
|
|
1489
|
-
function z(
|
|
1490
|
-
a.value =
|
|
1489
|
+
function z(w) {
|
|
1490
|
+
a.value = w;
|
|
1491
1491
|
}
|
|
1492
1492
|
function q() {
|
|
1493
1493
|
e.isVisible === !0 && (s.value = "", c(), Ce(() => {
|
|
1494
|
-
var
|
|
1495
|
-
return (M = (
|
|
1494
|
+
var w, M;
|
|
1495
|
+
return (M = (w = r.value) == null ? void 0 : w.querySelector("input")) == null ? void 0 : M.focus();
|
|
1496
1496
|
}));
|
|
1497
1497
|
}
|
|
1498
1498
|
return Y(() => e.results, () => $()), Y(() => e.errorMessage, () => $()), Y(() => e.isVisible, () => q()), Ae(() => {
|
|
1499
|
-
var
|
|
1500
|
-
return (
|
|
1499
|
+
var w;
|
|
1500
|
+
return (w = r.value) == null ? void 0 : w.addEventListener("keydown", T);
|
|
1501
1501
|
}), ze(() => {
|
|
1502
|
-
var
|
|
1503
|
-
return (
|
|
1504
|
-
}), (
|
|
1502
|
+
var w;
|
|
1503
|
+
return (w = r.value) == null ? void 0 : w.removeEventListener("keydown", T);
|
|
1504
|
+
}), (w, M) => {
|
|
1505
1505
|
var G;
|
|
1506
|
-
return u(),
|
|
1506
|
+
return u(), v("div", {
|
|
1507
1507
|
ref_key: "container",
|
|
1508
1508
|
ref: r,
|
|
1509
1509
|
class: "cl-absolute cl-bg-white cl-border cl-border-collapse cl-border-grey-0 cl-h-52 cl-overflow-y-auto cl-overscroll-y-none cl-rounded cl-text-sm cl-w-full cl-z-20",
|
|
1510
1510
|
onKeydown: [
|
|
1511
|
-
M[2] || (M[2] = ke(Q((K) =>
|
|
1512
|
-
M[3] || (M[3] = ke(Q((K) =>
|
|
1511
|
+
M[2] || (M[2] = ke(Q((K) => h(i.value), ["prevent", "stop"]), ["up"])),
|
|
1512
|
+
M[3] || (M[3] = ke(Q((K) => b(i.value), ["prevent", "stop"]), ["down"]))
|
|
1513
1513
|
],
|
|
1514
|
-
onKeyup: ke(Q(
|
|
1514
|
+
onKeyup: ke(Q(y, ["prevent", "stop"]), ["enter"])
|
|
1515
1515
|
}, [
|
|
1516
1516
|
f("div", Et, [
|
|
1517
1517
|
C(ie, {
|
|
@@ -1519,47 +1519,47 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1519
1519
|
"onUpdate:modelValue": M[0] || (M[0] = (K) => s.value = K),
|
|
1520
1520
|
class: "!cl-mr-0 cl-w-full",
|
|
1521
1521
|
"input-type": "text",
|
|
1522
|
-
"placeholder-text":
|
|
1522
|
+
"placeholder-text": w.searchHint,
|
|
1523
1523
|
onKeyup: c,
|
|
1524
1524
|
onBlur: n
|
|
1525
1525
|
}, null, 8, ["modelValue", "placeholder-text"]),
|
|
1526
|
-
|
|
1527
|
-
[Z,
|
|
1526
|
+
H(C(Ie, { class: "cl-absolute cl-ml-2 cl-mt-11" }, null, 512), [
|
|
1527
|
+
[Z, w.loading]
|
|
1528
1528
|
])
|
|
1529
1529
|
]),
|
|
1530
|
-
|
|
1530
|
+
w.currentObjectName !== "" ? (u(), V(Oe, {
|
|
1531
1531
|
key: 0,
|
|
1532
|
-
"show-clear-button":
|
|
1533
|
-
text:
|
|
1534
|
-
onClearObject: M[1] || (M[1] = (K) =>
|
|
1532
|
+
"show-clear-button": w.canClearSelectedObject,
|
|
1533
|
+
text: w.currentObjectName,
|
|
1534
|
+
onClearObject: M[1] || (M[1] = (K) => w.$emit("clear-object"))
|
|
1535
1535
|
}, null, 8, ["show-clear-button", "text"])) : N("", !0),
|
|
1536
|
-
|
|
1536
|
+
w.objectParentType !== "" && w.results !== void 0 && w.results.length > 0 && w.errorMessage === "" ? (u(), V(Oe, {
|
|
1537
1537
|
key: 1,
|
|
1538
|
-
text:
|
|
1539
|
-
"additional-text":
|
|
1538
|
+
text: w.objectType,
|
|
1539
|
+
"additional-text": w.objectParentType,
|
|
1540
1540
|
class: "cl-bg-grey-2 cl-mt-1"
|
|
1541
1541
|
}, null, 8, ["text", "additional-text"])) : N("", !0),
|
|
1542
|
-
|
|
1542
|
+
w.results !== null && ((G = w.results) == null ? void 0 : G.length) === 0 && s.value.trim() !== "" && w.canCreateNewObject === !1 && w.errorMessage === "" ? (u(), V(Oe, {
|
|
1543
1543
|
key: 2,
|
|
1544
1544
|
text: p(l)("comboBox.noResults", { value: s.value })
|
|
1545
1545
|
}, null, 8, ["text"])) : N("", !0),
|
|
1546
|
-
|
|
1546
|
+
w.errorMessage !== "" ? (u(), V(Oe, {
|
|
1547
1547
|
key: 3,
|
|
1548
1548
|
class: "!cl-bg-danger-light cl-border-danger-light cl-rounded cl-text-danger-dark",
|
|
1549
|
-
text: p(l)("comboBox.errorMessage", { error:
|
|
1549
|
+
text: p(l)("comboBox.errorMessage", { error: w.errorMessage })
|
|
1550
1550
|
}, null, 8, ["text"])) : N("", !0),
|
|
1551
1551
|
d.value ? (u(), V(Ze, {
|
|
1552
1552
|
key: 4,
|
|
1553
1553
|
"is-create-new-option": !0,
|
|
1554
|
-
text: p(l)("comboBox.addPrompt", { value: s.value, object:
|
|
1554
|
+
text: p(l)("comboBox.addPrompt", { value: s.value, object: w.objectType }),
|
|
1555
1555
|
index: -1,
|
|
1556
1556
|
"selected-index": a.value,
|
|
1557
1557
|
class: "cl-px-2",
|
|
1558
1558
|
onCreateObject: k,
|
|
1559
1559
|
onOptionHighlighted: z
|
|
1560
1560
|
}, null, 8, ["text", "selected-index"])) : N("", !0),
|
|
1561
|
-
|
|
1562
|
-
(u(!0),
|
|
1561
|
+
w.errorMessage === "" && w.results !== null ? (u(), v("div", qt, [
|
|
1562
|
+
(u(!0), v(D, null, ee(w.results, (K, ue) => (u(), V(Ze, {
|
|
1563
1563
|
key: ue,
|
|
1564
1564
|
option: K,
|
|
1565
1565
|
index: ue,
|
|
@@ -1603,56 +1603,56 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1603
1603
|
const l = t, s = A(() => l.placeholderText ? l.placeholderText : a("comboBox.emptyHintText", { object: l.objectType })), d = A(() => l.searchHint ? l.searchHint : a("comboBox.searchHint", { object: l.objectType })), { t: a } = se(), i = I(!1), r = A({
|
|
1604
1604
|
get: () => l.currentObject,
|
|
1605
1605
|
set: (O) => e("update:current-object", O)
|
|
1606
|
-
}), c = I(null), m = I(null), k = A(() => ye()), n = I(""),
|
|
1606
|
+
}), c = I(null), m = I(null), k = A(() => ye()), n = I(""), b = I(""), h = I(), y = I(!0), T = I(!1);
|
|
1607
1607
|
function E(O) {
|
|
1608
1608
|
var ne, W;
|
|
1609
|
-
const
|
|
1610
|
-
T.value = window.innerHeight -
|
|
1609
|
+
const F = ((ne = we.value) == null ? void 0 : ne.getBoundingClientRect().top) || 0;
|
|
1610
|
+
T.value = window.innerHeight - F < 280, l.disabled || (typeof O < "u" ? i.value = O : i.value = !i.value), (W = c.value) == null || W.blur();
|
|
1611
1611
|
}
|
|
1612
1612
|
function $(O) {
|
|
1613
1613
|
n.value = O, e("search", O);
|
|
1614
1614
|
}
|
|
1615
1615
|
function z(O) {
|
|
1616
|
-
|
|
1616
|
+
b.value = O, e("search-parent", O);
|
|
1617
1617
|
}
|
|
1618
1618
|
function q() {
|
|
1619
1619
|
r.value = null, E(!1);
|
|
1620
1620
|
}
|
|
1621
|
-
function
|
|
1622
|
-
const
|
|
1623
|
-
r.value =
|
|
1621
|
+
function w(O) {
|
|
1622
|
+
const F = M(O);
|
|
1623
|
+
r.value = F, E(!1);
|
|
1624
1624
|
}
|
|
1625
1625
|
function M(O) {
|
|
1626
|
-
let
|
|
1626
|
+
let F = null;
|
|
1627
1627
|
if (l.results !== null) {
|
|
1628
1628
|
for (let ne = 0; ne < l.results.length; ne++)
|
|
1629
1629
|
if (l.results[ne].id === O) {
|
|
1630
|
-
|
|
1630
|
+
F = l.results[ne];
|
|
1631
1631
|
break;
|
|
1632
1632
|
}
|
|
1633
1633
|
}
|
|
1634
|
-
return
|
|
1634
|
+
return F;
|
|
1635
1635
|
}
|
|
1636
1636
|
function G() {
|
|
1637
1637
|
var O;
|
|
1638
|
-
|
|
1638
|
+
h.value = {
|
|
1639
1639
|
name: n.value,
|
|
1640
1640
|
parentId: ((O = m.value) == null ? void 0 : O.id) ?? 0
|
|
1641
|
-
}, e("create-object",
|
|
1641
|
+
}, e("create-object", h.value);
|
|
1642
1642
|
}
|
|
1643
1643
|
function K() {
|
|
1644
|
-
|
|
1645
|
-
name:
|
|
1644
|
+
h.value = {
|
|
1645
|
+
name: b.value,
|
|
1646
1646
|
parentId: 0
|
|
1647
|
-
}, e("create-parent-object",
|
|
1647
|
+
}, e("create-parent-object", h.value);
|
|
1648
1648
|
}
|
|
1649
1649
|
function ue() {
|
|
1650
|
-
var O,
|
|
1650
|
+
var O, F;
|
|
1651
1651
|
(O = l.objectCreatedResponse) != null && O.error ? De({
|
|
1652
1652
|
message: a("comboBox.createFailed", { name: n.value, error: l.objectCreatedResponse.error }),
|
|
1653
1653
|
colour: "danger",
|
|
1654
1654
|
duration: 1e4
|
|
1655
|
-
}) : (
|
|
1655
|
+
}) : (F = l.objectCreatedResponse) != null && F.id && je();
|
|
1656
1656
|
}
|
|
1657
1657
|
function Ne() {
|
|
1658
1658
|
var O;
|
|
@@ -1662,16 +1662,16 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1662
1662
|
});
|
|
1663
1663
|
}
|
|
1664
1664
|
function je() {
|
|
1665
|
-
var
|
|
1665
|
+
var F, ne, W, g, R;
|
|
1666
1666
|
De({
|
|
1667
|
-
message: a("comboBox.createSuccessful", { object: l.objectType, name: ((
|
|
1667
|
+
message: a("comboBox.createSuccessful", { object: l.objectType, name: ((F = l.objectCreatedResponse) == null ? void 0 : F.name) ?? "" }),
|
|
1668
1668
|
colour: "primary",
|
|
1669
1669
|
duration: 1e4
|
|
1670
1670
|
});
|
|
1671
1671
|
let O = "";
|
|
1672
1672
|
m.value && m.value.id === ((ne = l.objectCreatedResponse) == null ? void 0 : ne.parentId) && (O = m.value.name), r.value = {
|
|
1673
1673
|
id: ((W = l.objectCreatedResponse) == null ? void 0 : W.id) ?? 0,
|
|
1674
|
-
name: ((
|
|
1674
|
+
name: ((g = l.objectCreatedResponse) == null ? void 0 : g.name) ?? "",
|
|
1675
1675
|
parentId: ((R = l.objectCreatedResponse) == null ? void 0 : R.parentId) ?? 0,
|
|
1676
1676
|
parentName: O
|
|
1677
1677
|
};
|
|
@@ -1682,7 +1682,7 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1682
1682
|
}
|
|
1683
1683
|
function be() {
|
|
1684
1684
|
let O = !0;
|
|
1685
|
-
n.value === "" && (O = !1), l.objectParentType !== "" && m.value === null && (O = !1),
|
|
1685
|
+
n.value === "" && (O = !1), l.objectParentType !== "" && m.value === null && (O = !1), y.value = O;
|
|
1686
1686
|
}
|
|
1687
1687
|
Y(() => l.objectCreatedResponse, () => ue()), Y(() => l.parentObjectCreatedResponse, () => Ne()), Y(() => n.value, () => be()), Y(() => m.value, () => be()), o({
|
|
1688
1688
|
focus() {
|
|
@@ -1691,9 +1691,9 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1691
1691
|
}
|
|
1692
1692
|
});
|
|
1693
1693
|
const we = I();
|
|
1694
|
-
return Me(we, () => i.value ? E(!1) : ""), (O,
|
|
1694
|
+
return Me(we, () => i.value ? E(!1) : ""), (O, F) => {
|
|
1695
1695
|
const ne = rl("cl-ui-combo-box", !0);
|
|
1696
|
-
return u(),
|
|
1696
|
+
return u(), v("div", {
|
|
1697
1697
|
ref_key: "outsideRef",
|
|
1698
1698
|
ref: we,
|
|
1699
1699
|
class: "cl-relative"
|
|
@@ -1703,17 +1703,17 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1703
1703
|
ref_key: "inputRef",
|
|
1704
1704
|
ref: c,
|
|
1705
1705
|
modelValue: k.value,
|
|
1706
|
-
"onUpdate:modelValue":
|
|
1706
|
+
"onUpdate:modelValue": F[0] || (F[0] = (W) => k.value = W),
|
|
1707
1707
|
class: _(["!cl-mr-0 cl-mb-0 cl-rounded-r-none cl-w-full cl-z-10", {
|
|
1708
1708
|
"cl-cursor-pointer": O.disabled === !1
|
|
1709
1709
|
}]),
|
|
1710
1710
|
"input-type": "text",
|
|
1711
1711
|
"placeholder-text": s.value,
|
|
1712
|
-
onFocus:
|
|
1712
|
+
onFocus: F[1] || (F[1] = (W) => {
|
|
1713
1713
|
E(), O.$emit("focus");
|
|
1714
1714
|
})
|
|
1715
1715
|
}, null, 8, ["modelValue", "class", "placeholder-text"]),
|
|
1716
|
-
|
|
1716
|
+
H(f("div", Nt, [
|
|
1717
1717
|
f("div", jt, [
|
|
1718
1718
|
te(S(p(a)("comboBox.required")) + " ", 1),
|
|
1719
1719
|
C(p(U), {
|
|
@@ -1724,25 +1724,25 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1724
1724
|
], 512), [
|
|
1725
1725
|
[Z, O.required && O.disabled === !1 && O.currentObject === null]
|
|
1726
1726
|
]),
|
|
1727
|
-
i.value ? (u(),
|
|
1727
|
+
i.value ? (u(), v("div", {
|
|
1728
1728
|
key: 1,
|
|
1729
1729
|
class: _(["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", {
|
|
1730
1730
|
"cl-cursor-default": O.disabled,
|
|
1731
1731
|
"cl-cursor-pointer": O.disabled === !1
|
|
1732
1732
|
}]),
|
|
1733
|
-
onClick:
|
|
1733
|
+
onClick: F[3] || (F[3] = (W) => E(!1))
|
|
1734
1734
|
}, [
|
|
1735
1735
|
C(p(U), {
|
|
1736
1736
|
icon: "ph:caret-up-bold",
|
|
1737
1737
|
class: "cl-ml-[5px] cl-mt-[12px]"
|
|
1738
1738
|
})
|
|
1739
|
-
], 2)) : (u(),
|
|
1739
|
+
], 2)) : (u(), v("div", {
|
|
1740
1740
|
key: 0,
|
|
1741
1741
|
class: _(["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", {
|
|
1742
1742
|
"cl-cursor-default": O.disabled,
|
|
1743
1743
|
"cl-cursor-pointer": O.disabled === !1
|
|
1744
1744
|
}]),
|
|
1745
|
-
onClick:
|
|
1745
|
+
onClick: F[2] || (F[2] = (W) => E(!0))
|
|
1746
1746
|
}, [
|
|
1747
1747
|
C(p(U), {
|
|
1748
1748
|
icon: "ph:caret-down-bold",
|
|
@@ -1755,7 +1755,7 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1755
1755
|
te(S(p(a)("comboBox.createTitle", { object: O.objectType })), 1)
|
|
1756
1756
|
]),
|
|
1757
1757
|
trigger: P(({ open: W }) => [
|
|
1758
|
-
|
|
1758
|
+
H(C(At, {
|
|
1759
1759
|
"can-create-new-object": O.canCreateNewObject,
|
|
1760
1760
|
"can-clear-selected-object": O.canClearSelectedObject,
|
|
1761
1761
|
loading: O.loading,
|
|
@@ -1770,9 +1770,10 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1770
1770
|
}),
|
|
1771
1771
|
"search-hint": d.value,
|
|
1772
1772
|
onCreateObject: W,
|
|
1773
|
-
onSelectObject:
|
|
1773
|
+
onSelectObject: w,
|
|
1774
1774
|
onClearObject: q,
|
|
1775
|
-
onSearch:
|
|
1775
|
+
onSearch: $,
|
|
1776
|
+
onHideDropdown: F[4] || (F[4] = (g) => E(!1))
|
|
1776
1777
|
}, 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"]), [
|
|
1777
1778
|
[Z, i.value]
|
|
1778
1779
|
])
|
|
@@ -1793,8 +1794,8 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1793
1794
|
C(ge, {
|
|
1794
1795
|
colour: "primary",
|
|
1795
1796
|
size: "small",
|
|
1796
|
-
disabled: !
|
|
1797
|
-
onClick: (
|
|
1797
|
+
disabled: !y.value,
|
|
1798
|
+
onClick: (g) => {
|
|
1798
1799
|
G(), W();
|
|
1799
1800
|
}
|
|
1800
1801
|
}, {
|
|
@@ -1810,7 +1811,7 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1810
1811
|
O.objectParentType ? (u(), V(ne, {
|
|
1811
1812
|
key: 0,
|
|
1812
1813
|
"current-object": m.value,
|
|
1813
|
-
"onUpdate:currentObject":
|
|
1814
|
+
"onUpdate:currentObject": F[5] || (F[5] = (W) => m.value = W),
|
|
1814
1815
|
class: "cl-mt-3",
|
|
1815
1816
|
results: O.parentResults,
|
|
1816
1817
|
loading: O.loading,
|
|
@@ -1824,7 +1825,7 @@ const ie = /* @__PURE__ */ me(ht, [["__scopeId", "data-v-e205e4b1"]]), yt = { cl
|
|
|
1824
1825
|
}, null, 8, ["current-object", "results", "loading", "object-type", "object-created-response", "can-create-new-object", "can-clear-selected-object", "error-message"])) : N("", !0),
|
|
1825
1826
|
C(ie, {
|
|
1826
1827
|
modelValue: n.value,
|
|
1827
|
-
"onUpdate:modelValue":
|
|
1828
|
+
"onUpdate:modelValue": F[6] || (F[6] = (W) => n.value = W),
|
|
1828
1829
|
label: p(a)("comboBox.createProperty"),
|
|
1829
1830
|
class: "cl-mb-2 cl-pt-3 cl-w-full",
|
|
1830
1831
|
"input-type": "text"
|
|
@@ -1851,11 +1852,11 @@ const Bt = {}, Vt = { class: "cl-flex cl-flex-wrap cl-left-0 cl-mt-4 cl-w-full"
|
|
|
1851
1852
|
class: "cl-leading-10 cl-text-sm cl-w-full"
|
|
1852
1853
|
}, Pt = { class: "cl-float-left" }, Ft = { class: "cl-float-right" };
|
|
1853
1854
|
function Ht(t, o) {
|
|
1854
|
-
return u(),
|
|
1855
|
-
t.$slots.default ? (u(),
|
|
1855
|
+
return u(), v("div", Vt, [
|
|
1856
|
+
t.$slots.default ? (u(), v("div", Lt, [
|
|
1856
1857
|
j(t.$slots, "default")
|
|
1857
1858
|
])) : N("", !0),
|
|
1858
|
-
t.$slots.left || t.$slots.right ? (u(),
|
|
1859
|
+
t.$slots.left || t.$slots.right ? (u(), v("div", Dt, [
|
|
1859
1860
|
f("span", Pt, [
|
|
1860
1861
|
j(t.$slots, "left")
|
|
1861
1862
|
]),
|
|
@@ -1896,7 +1897,7 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
1896
1897
|
emits: ["update:edit-mode", "update:filterPanelOpen", "clear-filters"],
|
|
1897
1898
|
setup(t) {
|
|
1898
1899
|
const o = t, { t: e } = se(), l = A(() => o.request.filters.some((s) => s.filterValue !== ""));
|
|
1899
|
-
return (s, d) => (u(),
|
|
1900
|
+
return (s, d) => (u(), v(D, null, [
|
|
1900
1901
|
f("div", Gt, [
|
|
1901
1902
|
f("strong", null, S(p(e)("grid.gridTools")), 1)
|
|
1902
1903
|
]),
|
|
@@ -1915,18 +1916,18 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
1915
1916
|
onClick: d[0] || (d[0] = Q((a) => s.$emit("update:edit-mode", !s.editMode), ["prevent"]))
|
|
1916
1917
|
}, {
|
|
1917
1918
|
default: P(() => [
|
|
1918
|
-
s.editMode ? (u(),
|
|
1919
|
+
s.editMode ? (u(), v(D, { key: 0 }, [
|
|
1919
1920
|
te(S(p(e)("grid.finishEditing")), 1)
|
|
1920
|
-
], 64)) : (u(),
|
|
1921
|
+
], 64)) : (u(), v(D, { key: 1 }, [
|
|
1921
1922
|
te(S(p(e)("grid.editData")), 1)
|
|
1922
1923
|
], 64))
|
|
1923
1924
|
]),
|
|
1924
1925
|
_: 1
|
|
1925
1926
|
})) : N("", !0),
|
|
1926
|
-
s.options.hideViewManager ? N("", !0) : (u(),
|
|
1927
|
+
s.options.hideViewManager ? N("", !0) : (u(), v("div", Yt, [
|
|
1927
1928
|
j(s.$slots, "view-manager")
|
|
1928
1929
|
])),
|
|
1929
|
-
p(Ge)(s.columns) || p(Zt)(s.columns) ? (u(),
|
|
1930
|
+
p(Ge)(s.columns) || p(Zt)(s.columns) ? (u(), v(D, { key: 2 }, [
|
|
1930
1931
|
f("div", Jt, [
|
|
1931
1932
|
C(ge, {
|
|
1932
1933
|
class: "cl-w-full",
|
|
@@ -1981,9 +1982,9 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
1981
1982
|
const o = t, { t: e, locale: l, n: s } = se();
|
|
1982
1983
|
function d(a, i) {
|
|
1983
1984
|
let r;
|
|
1984
|
-
o.timeZone ? r =
|
|
1985
|
+
o.timeZone ? r = x.fromISO(a, {
|
|
1985
1986
|
locale: l.value
|
|
1986
|
-
}).setZone(o.timeZone) : r =
|
|
1987
|
+
}).setZone(o.timeZone) : r = x.fromISO(a, {
|
|
1987
1988
|
locale: l.value,
|
|
1988
1989
|
zone: "UTC"
|
|
1989
1990
|
});
|
|
@@ -2016,16 +2017,16 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2016
2017
|
"input-type": "checkbox",
|
|
2017
2018
|
"model-value": a.data[a.column.field],
|
|
2018
2019
|
disabled: !0
|
|
2019
|
-
}, null, 8, ["model-value"])) : (a.column.type === "date" || a.column.type === "datetime") && a.column.field !== void 0 ? (u(),
|
|
2020
|
-
a.column.format !== void 0 ? (u(),
|
|
2020
|
+
}, null, 8, ["model-value"])) : (a.column.type === "date" || a.column.type === "datetime") && a.column.field !== void 0 ? (u(), v(D, { key: 2 }, [
|
|
2021
|
+
a.column.format !== void 0 ? (u(), v(D, { key: 0 }, [
|
|
2021
2022
|
te(S(d(a.data[a.column.field], a.column.format)), 1)
|
|
2022
|
-
], 64)) : a.column.type === "date" ? (u(),
|
|
2023
|
+
], 64)) : a.column.type === "date" ? (u(), v(D, { key: 1 }, [
|
|
2023
2024
|
te(S(d(a.data[a.column.field], p(J).DATE)), 1)
|
|
2024
|
-
], 64)) : (u(),
|
|
2025
|
+
], 64)) : (u(), v(D, { key: 2 }, [
|
|
2025
2026
|
te(S(d(a.data[a.column.field], p(J).DATETIME)), 1)
|
|
2026
2027
|
], 64))
|
|
2027
|
-
], 64)) : a.column.type === "list" && a.column.field !== void 0 && a.column.listEntries !== void 0 ? (u(),
|
|
2028
|
-
a.column.maxLength !== void 0 ? (u(),
|
|
2028
|
+
], 64)) : a.column.type === "list" && a.column.field !== void 0 && a.column.listEntries !== void 0 ? (u(), v("span", eo, S(p(e)(((r = a.column.listEntries.find((c) => c.value === a.data[a.column.field])) == null ? void 0 : r.translationKey) ?? "")), 1)) : a.column.type === "number" && a.column.field !== void 0 ? (u(), v("span", lo, S(p(s)(a.data[a.column.field], a.column.format ?? p(le).DECIMAL)), 1)) : a.column.field !== void 0 ? (u(), v(D, { key: 5 }, [
|
|
2029
|
+
a.column.maxLength !== void 0 ? (u(), v("span", to, S(a.data[a.column.field].trimToLength(a.column.maxLength, a.column.format !== void 0 ? a.column.format === "ellipsis" : !1)), 1)) : (u(), v("span", oo, S(a.data[a.column.field]), 1))
|
|
2029
2030
|
], 64)) : N("", !0);
|
|
2030
2031
|
};
|
|
2031
2032
|
}
|
|
@@ -2051,7 +2052,7 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2051
2052
|
r !== "" && (i[r] !== e.data[r] ? o("edit", i[r]) : o("undo"));
|
|
2052
2053
|
}, {
|
|
2053
2054
|
deep: !0
|
|
2054
|
-
}), (i, r) => (u(),
|
|
2055
|
+
}), (i, r) => (u(), v("td", {
|
|
2055
2056
|
class: _(["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", {
|
|
2056
2057
|
"cl-bg-link-lighter": d.value
|
|
2057
2058
|
}])
|
|
@@ -2097,8 +2098,8 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2097
2098
|
},
|
|
2098
2099
|
emits: ["cell-focus", "cell-edit", "cell-undo", "row-select"],
|
|
2099
2100
|
setup(t) {
|
|
2100
|
-
return (o, e) => (u(),
|
|
2101
|
-
(u(!0),
|
|
2101
|
+
return (o, e) => (u(), v("tr", null, [
|
|
2102
|
+
(u(!0), v(D, null, ee(o.columns, (l, s) => (u(), V(no, {
|
|
2102
2103
|
key: s,
|
|
2103
2104
|
data: o.data,
|
|
2104
2105
|
column: l,
|
|
@@ -2143,27 +2144,27 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2143
2144
|
function a(n) {
|
|
2144
2145
|
s.value.index !== -1 && s.value.index !== n && d(), s.value.index = n;
|
|
2145
2146
|
}
|
|
2146
|
-
function i(n,
|
|
2147
|
-
a(n),
|
|
2147
|
+
function i(n, b) {
|
|
2148
|
+
a(n), b.field !== void 0 && (s.value.record[b.field] = b.value);
|
|
2148
2149
|
}
|
|
2149
2150
|
function r(n) {
|
|
2150
2151
|
if (n !== void 0) {
|
|
2151
|
-
const { [n]:
|
|
2152
|
+
const { [n]: b, ...h } = s.value.record;
|
|
2152
2153
|
s.value.record = {
|
|
2153
|
-
...
|
|
2154
|
+
...h
|
|
2154
2155
|
};
|
|
2155
2156
|
}
|
|
2156
2157
|
}
|
|
2157
2158
|
const c = I({});
|
|
2158
2159
|
Y(() => e.data, () => {
|
|
2159
|
-
var n,
|
|
2160
|
-
return c.value = Object.fromEntries(((
|
|
2161
|
-
[
|
|
2160
|
+
var n, b;
|
|
2161
|
+
return c.value = Object.fromEntries(((b = (n = e.data) == null ? void 0 : n.results) == null ? void 0 : b.map((h, y) => [
|
|
2162
|
+
[y],
|
|
2162
2163
|
{
|
|
2163
2164
|
count: 0,
|
|
2164
2165
|
target: null,
|
|
2165
2166
|
reset: Qe(() => {
|
|
2166
|
-
c.value[
|
|
2167
|
+
c.value[y] && (c.value[y].count = 0, c.value[y].target = null);
|
|
2167
2168
|
}, 2500, { immediate: !1 })
|
|
2168
2169
|
}
|
|
2169
2170
|
])) ?? []);
|
|
@@ -2171,21 +2172,21 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2171
2172
|
deep: !0,
|
|
2172
2173
|
immediate: !0
|
|
2173
2174
|
});
|
|
2174
|
-
function m(n,
|
|
2175
|
-
const { currentTarget:
|
|
2176
|
-
e.options.rowSelectionEnabled ? (k(
|
|
2175
|
+
function m(n, b, h) {
|
|
2176
|
+
const { currentTarget: y } = h;
|
|
2177
|
+
e.options.rowSelectionEnabled ? (k(y), o("row-select", b)) : (c.value[n].count++, c.value[n].target = y, c.value[n].count > 1 ? (c.value[n].reset.stop(), c.value[n].count = 0, k(y), c.value[n].target = null, o("row-select", b)) : c.value[n].reset.start());
|
|
2177
2178
|
}
|
|
2178
2179
|
function k(n) {
|
|
2179
2180
|
e.options.highlightRowSelection && (n == null || n.classList.toggle("!cl-bg-link-lighter"));
|
|
2180
2181
|
}
|
|
2181
2182
|
return Y(() => e.editMode, () => {
|
|
2182
2183
|
e.editMode || (d(), s.value.index = -1);
|
|
2183
|
-
}), (n,
|
|
2184
|
-
var
|
|
2185
|
-
return u(),
|
|
2186
|
-
n.data && ((
|
|
2184
|
+
}), (n, b) => {
|
|
2185
|
+
var h;
|
|
2186
|
+
return u(), v("tbody", null, [
|
|
2187
|
+
n.data && ((h = n.data.results) != null && h.length) ? (u(!0), v(D, { key: 0 }, ee(n.data.results, (y, T) => (u(), V(ao, {
|
|
2187
2188
|
key: T,
|
|
2188
|
-
data:
|
|
2189
|
+
data: y,
|
|
2189
2190
|
columns: n.columns,
|
|
2190
2191
|
"time-zone": n.timeZone,
|
|
2191
2192
|
"edit-mode": n.editMode,
|
|
@@ -2195,7 +2196,7 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2195
2196
|
"cl-cursor-pointer hover:cl-bg-link-lighter": n.options.rowSelectionEnabled && n.options.highlightRowSelection && !n.editMode
|
|
2196
2197
|
}]),
|
|
2197
2198
|
onClick: (E) => {
|
|
2198
|
-
n.editMode || m(T,
|
|
2199
|
+
n.editMode || m(T, y, E);
|
|
2199
2200
|
},
|
|
2200
2201
|
onCellFocus: (E) => {
|
|
2201
2202
|
a(T);
|
|
@@ -2211,18 +2212,18 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2211
2212
|
j(n.$slots, $, oe(ae(z)))
|
|
2212
2213
|
])
|
|
2213
2214
|
}))
|
|
2214
|
-
]), 1032, ["data", "columns", "time-zone", "edit-mode", "class", "onClick", "onCellFocus", "onCellEdit"]))), 128)) : n.loading ? N("", !0) : (u(),
|
|
2215
|
+
]), 1032, ["data", "columns", "time-zone", "edit-mode", "class", "onClick", "onCellFocus", "onCellEdit"]))), 128)) : n.loading ? N("", !0) : (u(), v("tr", ro, [
|
|
2215
2216
|
f("td", {
|
|
2216
2217
|
colspan: n.columns.length
|
|
2217
2218
|
}, [
|
|
2218
2219
|
f("div", co, [
|
|
2219
2220
|
f("strong", uo, S(p(l)("grid.noData")), 1),
|
|
2220
|
-
n.request.filters.some((
|
|
2221
|
+
n.request.filters.some((y) => y.filterValue !== "") ? (u(), v("div", po, [
|
|
2221
2222
|
f("div", fo, S(p(l)("grid.noDataFiltersPresent")), 1),
|
|
2222
2223
|
C(ge, {
|
|
2223
2224
|
size: "small",
|
|
2224
2225
|
colour: "danger",
|
|
2225
|
-
onClick:
|
|
2226
|
+
onClick: b[0] || (b[0] = Q((y) => n.$emit("clear-filters"), ["prevent"]))
|
|
2226
2227
|
}, {
|
|
2227
2228
|
default: P(() => [
|
|
2228
2229
|
te(S(p(l)("grid.clearFilters")), 1)
|
|
@@ -2254,20 +2255,20 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2254
2255
|
return e.data !== null ? Math.ceil((((n = e.data) == null ? void 0 : n.totalRecords) ?? 0) / e.request.pageSize) : 1;
|
|
2255
2256
|
}), a = A(() => {
|
|
2256
2257
|
const n = Array.from(Array(d.value + 1).keys());
|
|
2257
|
-
let
|
|
2258
|
+
let b = [];
|
|
2258
2259
|
if (n.shift(), n.length) {
|
|
2259
|
-
const
|
|
2260
|
-
|
|
2260
|
+
const h = e.request.pageNumber === d.value || e.request.pageNumber === d.value - 1 ? d.value - 3 : e.request.pageNumber - 1;
|
|
2261
|
+
b = n.slice(h, h + 3);
|
|
2261
2262
|
}
|
|
2262
|
-
return
|
|
2263
|
+
return b;
|
|
2263
2264
|
});
|
|
2264
2265
|
function i(n) {
|
|
2265
|
-
const
|
|
2266
|
-
|
|
2266
|
+
const b = ce(e.request);
|
|
2267
|
+
b.pageNumber !== n && (b.pageNumber = Math.max(Math.min(Math.trunc(n), d.value), 1), o("update:request", b));
|
|
2267
2268
|
}
|
|
2268
2269
|
function r(n) {
|
|
2269
|
-
const
|
|
2270
|
-
i(
|
|
2270
|
+
const b = parseInt(n == null ? void 0 : n.value) || 1;
|
|
2271
|
+
i(b);
|
|
2271
2272
|
}
|
|
2272
2273
|
const c = [
|
|
2273
2274
|
5,
|
|
@@ -2278,13 +2279,13 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2278
2279
|
200
|
|
2279
2280
|
];
|
|
2280
2281
|
function m(n) {
|
|
2281
|
-
const
|
|
2282
|
-
|
|
2282
|
+
const b = ce(e.request);
|
|
2283
|
+
b.pageSize = n, b.pageNumber = 1, o("update:request", b);
|
|
2283
2284
|
}
|
|
2284
2285
|
const k = Ye(r, 750);
|
|
2285
|
-
return (n,
|
|
2286
|
-
var
|
|
2287
|
-
return (
|
|
2286
|
+
return (n, b) => {
|
|
2287
|
+
var h, y;
|
|
2288
|
+
return (y = (h = n.data) == null ? void 0 : h.results) != null && y.length && n.request ? (u(), v("div", go, [
|
|
2288
2289
|
f("div", vo, [
|
|
2289
2290
|
f("span", bo, S(p(s)("grid.jumpToPage")), 1),
|
|
2290
2291
|
C(ie, {
|
|
@@ -2295,7 +2296,7 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2295
2296
|
"show-label": !1,
|
|
2296
2297
|
min: "1",
|
|
2297
2298
|
max: d.value,
|
|
2298
|
-
onInput:
|
|
2299
|
+
onInput: b[0] || (b[0] = (T) => p(k)(T.target))
|
|
2299
2300
|
}, null, 8, ["model-value", "max"])
|
|
2300
2301
|
]),
|
|
2301
2302
|
f("div", ho, [
|
|
@@ -2305,9 +2306,9 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2305
2306
|
]),
|
|
2306
2307
|
f("ul", ko, [
|
|
2307
2308
|
f("li", Co, S(p(l)(n.request.pageNumber, p(le).INTEGER)) + " / " + S(p(l)(d.value, p(le).INTEGER)), 1),
|
|
2308
|
-
|
|
2309
|
+
H(f("li", {
|
|
2309
2310
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
2310
|
-
onClick:
|
|
2311
|
+
onClick: b[1] || (b[1] = (T) => i(1))
|
|
2311
2312
|
}, [
|
|
2312
2313
|
C(p(U), {
|
|
2313
2314
|
icon: "ph:caret-double-left",
|
|
@@ -2316,9 +2317,9 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2316
2317
|
], 512), [
|
|
2317
2318
|
[Z, n.request.pageNumber > 1]
|
|
2318
2319
|
]),
|
|
2319
|
-
|
|
2320
|
+
H(f("li", {
|
|
2320
2321
|
class: "cl-cursor-pointer cl-mt-1 lg:cl-mr-2 mr-1",
|
|
2321
|
-
onClick:
|
|
2322
|
+
onClick: b[2] || (b[2] = (T) => i(n.request.pageNumber - 1))
|
|
2322
2323
|
}, [
|
|
2323
2324
|
C(p(U), {
|
|
2324
2325
|
icon: "ph:caret-left",
|
|
@@ -2327,7 +2328,7 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2327
2328
|
], 512), [
|
|
2328
2329
|
[Z, n.request.pageNumber > 1]
|
|
2329
2330
|
]),
|
|
2330
|
-
(u(!0),
|
|
2331
|
+
(u(!0), v(D, null, ee(a.value, (T, E) => (u(), v("li", {
|
|
2331
2332
|
key: E,
|
|
2332
2333
|
class: _(["cl-cursor-pointer cl-mr-1 lg:cl-mr-2", {
|
|
2333
2334
|
"cl-text-black cl-font-bold": n.request.pageNumber === T,
|
|
@@ -2335,9 +2336,9 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2335
2336
|
}]),
|
|
2336
2337
|
onClick: ($) => i(T)
|
|
2337
2338
|
}, S(p(l)(T, p(le).INTEGER)), 11, To))), 128)),
|
|
2338
|
-
|
|
2339
|
+
H(f("li", {
|
|
2339
2340
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
2340
|
-
onClick:
|
|
2341
|
+
onClick: b[3] || (b[3] = (T) => i(n.request.pageNumber + 1))
|
|
2341
2342
|
}, [
|
|
2342
2343
|
C(p(U), {
|
|
2343
2344
|
icon: "ph:caret-right",
|
|
@@ -2346,9 +2347,9 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2346
2347
|
], 512), [
|
|
2347
2348
|
[Z, n.request.pageNumber < d.value]
|
|
2348
2349
|
]),
|
|
2349
|
-
|
|
2350
|
+
H(f("li", {
|
|
2350
2351
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
2351
|
-
onClick:
|
|
2352
|
+
onClick: b[4] || (b[4] = (T) => i(d.value))
|
|
2352
2353
|
}, [
|
|
2353
2354
|
C(p(U), {
|
|
2354
2355
|
icon: "ph:caret-double-right",
|
|
@@ -2361,7 +2362,7 @@ const Gt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Wt = { class: "cl-gap-1
|
|
|
2361
2362
|
]),
|
|
2362
2363
|
f("ul", Oo, [
|
|
2363
2364
|
f("li", So, S(p(s)("grid.pageSize")), 1),
|
|
2364
|
-
(u(),
|
|
2365
|
+
(u(), v(D, null, ee(c, (T, E) => f("li", {
|
|
2365
2366
|
key: E,
|
|
2366
2367
|
class: _(["cl-cursor-pointer cl-mr-1 lg:cl-mr-2", {
|
|
2367
2368
|
"cl-text-black cl-font-bold": n.request.pageSize === T,
|
|
@@ -2598,7 +2599,7 @@ const Lo = {
|
|
|
2598
2599
|
return;
|
|
2599
2600
|
o("update:filter", r);
|
|
2600
2601
|
}
|
|
2601
|
-
return (i, r) => (u(),
|
|
2602
|
+
return (i, r) => (u(), v("div", Fo, [
|
|
2602
2603
|
f("div", Ho, [
|
|
2603
2604
|
d.value ? (u(), V(p(U), {
|
|
2604
2605
|
key: 0,
|
|
@@ -2616,9 +2617,9 @@ const Lo = {
|
|
|
2616
2617
|
}])
|
|
2617
2618
|
}, [
|
|
2618
2619
|
f("strong", xo, S(p(l)("grid.availableMethods")), 1),
|
|
2619
|
-
(u(!0),
|
|
2620
|
+
(u(!0), v(D, null, ee(s.value, (c, m) => {
|
|
2620
2621
|
var k;
|
|
2621
|
-
return u(),
|
|
2622
|
+
return u(), v("span", {
|
|
2622
2623
|
key: m,
|
|
2623
2624
|
class: _(["cl-cursor-pointer cl-px-4 cl-py-1 cl-transition-colors cl-w-full hover:cl-bg-grey-0", {
|
|
2624
2625
|
"cl-bg-primary-default cl-opacity-80": c.method === ((k = d.value) == null ? void 0 : k.method)
|
|
@@ -2657,11 +2658,11 @@ const Lo = {
|
|
|
2657
2658
|
set: ($) => o("update:filter", $)
|
|
2658
2659
|
}), i = A(() => e.column.type === "date" || e.column.type === "datetime" || e.column.type === "slot" && (e.column.slotType === "date" || e.column.slotType === "datetime")), r = A(() => e.column.type === "list" || e.column.type === "slot" && e.column.slotType === "list"), c = A(() => r.value && e.column.listType === "number"), m = A({
|
|
2659
2660
|
get() {
|
|
2660
|
-
var z, q,
|
|
2661
|
+
var z, q, w, M;
|
|
2661
2662
|
let $ = (z = a.value) == null ? void 0 : z[0];
|
|
2662
2663
|
if ($ && i.value) {
|
|
2663
2664
|
if ((((q = e.filter) == null ? void 0 : q.length) ?? 0) > 1) {
|
|
2664
|
-
const G = (
|
|
2665
|
+
const G = (w = a.value) == null ? void 0 : w.find((ue) => ue.filterOperation === X.EQUAL_OR_GREATER_THAN), K = (M = a.value) == null ? void 0 : M.find((ue) => ue.filterOperation === X.LESS_THAN);
|
|
2665
2666
|
G && K && ($ = {
|
|
2666
2667
|
filterOnColumn: e.column.field,
|
|
2667
2668
|
filterOperation: X.EQUAL,
|
|
@@ -2669,7 +2670,7 @@ const Lo = {
|
|
|
2669
2670
|
filterValue: G.filterValue
|
|
2670
2671
|
});
|
|
2671
2672
|
} else if ($.filterOperation === X.EQUAL_OR_LESS_THAN) {
|
|
2672
|
-
let G =
|
|
2673
|
+
let G = x.fromISO($.filterValue, {
|
|
2673
2674
|
zone: e.timeZone ?? "UTC"
|
|
2674
2675
|
});
|
|
2675
2676
|
e.column.type === "date" || e.column.type === "slot" && e.column.slotType === "date" ? G = G.minus({ days: 1 }) : G = G.minus({ minutes: 1 }), $ = {
|
|
@@ -2685,10 +2686,10 @@ const Lo = {
|
|
|
2685
2686
|
set($) {
|
|
2686
2687
|
let z;
|
|
2687
2688
|
if ($ != null && $.filterMethod && k($.filterMethod, $.filterValue)) {
|
|
2688
|
-
let q =
|
|
2689
|
+
let q = x.fromISO($.filterValue, {
|
|
2689
2690
|
zone: e.timeZone ?? "UTC"
|
|
2690
2691
|
}).set({ second: 0, millisecond: 0 });
|
|
2691
|
-
const
|
|
2692
|
+
const w = q.toISO();
|
|
2692
2693
|
e.column.type === "date" || e.column.type === "slot" && e.column.slotType === "date" ? q = q.plus({ days: 1 }) : q = q.plus({ minutes: 1 });
|
|
2693
2694
|
const M = q.toISO();
|
|
2694
2695
|
z = [
|
|
@@ -2696,7 +2697,7 @@ const Lo = {
|
|
|
2696
2697
|
filterOnColumn: e.column.field,
|
|
2697
2698
|
filterOperation: X.EQUAL_OR_GREATER_THAN,
|
|
2698
2699
|
filterMethod: "equalorgreaterthan",
|
|
2699
|
-
filterValue:
|
|
2700
|
+
filterValue: w
|
|
2700
2701
|
},
|
|
2701
2702
|
{
|
|
2702
2703
|
filterOnColumn: e.column.field,
|
|
@@ -2706,7 +2707,7 @@ const Lo = {
|
|
|
2706
2707
|
}
|
|
2707
2708
|
];
|
|
2708
2709
|
} else if ($ != null && $.filterMethod && k($.filterMethod, $.filterValue, "equalorlessthan")) {
|
|
2709
|
-
let q =
|
|
2710
|
+
let q = x.fromISO($.filterValue, {
|
|
2710
2711
|
zone: e.timeZone ?? "UTC"
|
|
2711
2712
|
}).set({ second: 0, millisecond: 0 });
|
|
2712
2713
|
e.column.type === "date" || e.column.type === "slot" && e.column.slotType === "date" ? q = q.plus({ days: 1 }) : q = q.plus({ minutes: 1 }), z = [
|
|
@@ -2721,7 +2722,7 @@ const Lo = {
|
|
|
2721
2722
|
z = $ && [$];
|
|
2722
2723
|
if (z && i.value)
|
|
2723
2724
|
for (const q of z)
|
|
2724
|
-
e.timeZone ? q.filterValue =
|
|
2725
|
+
e.timeZone ? q.filterValue = x.fromISO(q.filterValue).setZone("UTC").toISO() ?? "" : q.filterValue = q.filterValue.replace("Z", "");
|
|
2725
2726
|
a.value = z;
|
|
2726
2727
|
}
|
|
2727
2728
|
});
|
|
@@ -2731,13 +2732,13 @@ const Lo = {
|
|
|
2731
2732
|
const n = A(() => {
|
|
2732
2733
|
var $;
|
|
2733
2734
|
return (($ = m.value) == null ? void 0 : $.filterValue) ?? "";
|
|
2734
|
-
}),
|
|
2735
|
+
}), b = A(() => n.value === "" ? null : n.value), h = A(() => Intl.NumberFormat(l.value).format(1.1).replace(/[0-9]+/g, "")), y = A(() => Be(e.column));
|
|
2735
2736
|
function T($, z) {
|
|
2736
2737
|
var G;
|
|
2737
|
-
let q,
|
|
2738
|
+
let q, w = !1;
|
|
2738
2739
|
const M = (($ == null ? void 0 : $.value) ?? z).trim();
|
|
2739
2740
|
if (m.value)
|
|
2740
|
-
|
|
2741
|
+
w = ((G = m.value) == null ? void 0 : G.filterValue) === M, q = ce(m.value), q.filterValue = M;
|
|
2741
2742
|
else if (M !== "" && typeof e.column.field < "u") {
|
|
2742
2743
|
const K = d();
|
|
2743
2744
|
q = {
|
|
@@ -2748,14 +2749,14 @@ const Lo = {
|
|
|
2748
2749
|
};
|
|
2749
2750
|
} else
|
|
2750
2751
|
return;
|
|
2751
|
-
|
|
2752
|
+
w === !1 && (m.value = q);
|
|
2752
2753
|
}
|
|
2753
2754
|
function E($, z) {
|
|
2754
|
-
let q,
|
|
2755
|
-
e.column.format === le.INTEGER ? (typeof
|
|
2755
|
+
let q, w = ($ == null ? void 0 : $.value) ?? z ?? 0;
|
|
2756
|
+
e.column.format === le.INTEGER ? (typeof w == "string" && (w = parseInt(w)), q = Math.round(w)) : (typeof w == "string" && (w = parseFloat(w.replace(h.value, "."))), q = w), T(null, isNaN(q) ? "" : q.toString());
|
|
2756
2757
|
}
|
|
2757
|
-
return ($, z) =>
|
|
2758
|
-
$.column.type === "boolean" || $.column.slotType === "boolean" ? (u(),
|
|
2758
|
+
return ($, z) => y.value ? (u(), v("div", Wo, [
|
|
2759
|
+
$.column.type === "boolean" || $.column.slotType === "boolean" ? (u(), v("select", {
|
|
2759
2760
|
key: 0,
|
|
2760
2761
|
class: "!cl-h-[2rem] cl-border-none cl-mb-0 cl-rounded-md cl-w-full",
|
|
2761
2762
|
onChange: z[0] || (z[0] = (q) => T(q.target))
|
|
@@ -2771,7 +2772,7 @@ const Lo = {
|
|
|
2771
2772
|
}, S(p(s)("grid.false")), 9, Yo)
|
|
2772
2773
|
], 32)) : $.column.type === "date" || $.column.type === "datetime" || $.column.slotType === "date" || $.column.slotType === "datetime" ? (u(), V(ie, {
|
|
2773
2774
|
key: 1,
|
|
2774
|
-
"model-value":
|
|
2775
|
+
"model-value": b.value,
|
|
2775
2776
|
class: "!cl-h-[2rem] !cl-text-xs cl-border-none cl-mb-0 cl-w-full lg:!cl-text-base",
|
|
2776
2777
|
label: $.column.caption,
|
|
2777
2778
|
"show-label": !1,
|
|
@@ -2784,20 +2785,20 @@ const Lo = {
|
|
|
2784
2785
|
class: "!cl-h-[2rem] !cl-text-xs cl-border-none cl-mb-0 cl-w-full lg:!cl-text-base",
|
|
2785
2786
|
"input-type": "number",
|
|
2786
2787
|
"show-arrows": !1,
|
|
2787
|
-
onInput: z[2] || (z[2] = (q,
|
|
2788
|
+
onInput: z[2] || (z[2] = (q, w) => E(null, w))
|
|
2788
2789
|
}, null, 8, ["model-value"])) : $.column.type === "string" || $.column.slotType === "string" ? (u(), V(ie, {
|
|
2789
2790
|
key: 3,
|
|
2790
2791
|
"model-value": n.value,
|
|
2791
2792
|
class: "!cl-h-[2rem] !cl-text-xs cl-border-none cl-mb-0 cl-w-full lg:!cl-text-base",
|
|
2792
2793
|
"input-type": "text",
|
|
2793
|
-
onInput: z[3] || (z[3] = (q,
|
|
2794
|
-
}, null, 8, ["model-value"])) : r.value ? (u(),
|
|
2794
|
+
onInput: z[3] || (z[3] = (q, w) => T(null, w))
|
|
2795
|
+
}, null, 8, ["model-value"])) : r.value ? (u(), v("select", {
|
|
2795
2796
|
key: 4,
|
|
2796
2797
|
class: "!cl-h-[2rem] cl-border-none cl-mb-0 cl-rounded-md cl-w-full",
|
|
2797
2798
|
onChange: z[4] || (z[4] = (q) => c.value ? E(q.target) : T(q.target))
|
|
2798
2799
|
}, [
|
|
2799
2800
|
Jo,
|
|
2800
|
-
(u(!0),
|
|
2801
|
+
(u(!0), v(D, null, ee($.column.listEntries ?? [], (q) => (u(), v("option", {
|
|
2801
2802
|
key: q.value,
|
|
2802
2803
|
value: q.value,
|
|
2803
2804
|
selected: n.value === q.value.toString()
|
|
@@ -2849,9 +2850,9 @@ const Lo = {
|
|
|
2849
2850
|
], c.pageNumber = 1, s.value = c;
|
|
2850
2851
|
}
|
|
2851
2852
|
}
|
|
2852
|
-
return (r, c) => (u(),
|
|
2853
|
+
return (r, c) => (u(), v("thead", ls, [
|
|
2853
2854
|
f("tr", ts, [
|
|
2854
|
-
(u(!0),
|
|
2855
|
+
(u(!0), v(D, null, ee(r.columns, (m, k) => (u(), v("th", {
|
|
2855
2856
|
key: k,
|
|
2856
2857
|
class: _(["cl-text-grey-3 cl-text-sm", {
|
|
2857
2858
|
"cl-cursor-pointer": p(Ee)(m)
|
|
@@ -2860,13 +2861,13 @@ const Lo = {
|
|
|
2860
2861
|
}
|
|
2861
2862
|
}, [
|
|
2862
2863
|
te(S(m.caption) + " ", 1),
|
|
2863
|
-
|
|
2864
|
+
H(C(p(U), {
|
|
2864
2865
|
class: "cl-inline-block",
|
|
2865
2866
|
icon: "ph:caret-up"
|
|
2866
2867
|
}, null, 512), [
|
|
2867
2868
|
[Z, d(m, !0)]
|
|
2868
2869
|
]),
|
|
2869
|
-
|
|
2870
|
+
H(C(p(U), {
|
|
2870
2871
|
class: "cl-inline-block",
|
|
2871
2872
|
icon: "ph:caret-down"
|
|
2872
2873
|
}, null, 512), [
|
|
@@ -2887,14 +2888,14 @@ const Lo = {
|
|
|
2887
2888
|
onClick: c[0] || (c[0] = Q((m) => r.$emit("update:filterPanelOpen", !1), ["prevent"]))
|
|
2888
2889
|
})
|
|
2889
2890
|
]),
|
|
2890
|
-
(u(!0),
|
|
2891
|
+
(u(!0), v(D, null, ee(r.columns, (m, k) => (u(), v("th", {
|
|
2891
2892
|
key: k,
|
|
2892
2893
|
class: _(["cl-grid cl-grid-cols-4 cl-py-1 cl-text-xs cl-w-full lg:cl-table-cell lg:cl-w-auto", {
|
|
2893
2894
|
"cl-hidden lg:cl-table-cell": !p(Be)(m)
|
|
2894
2895
|
}])
|
|
2895
2896
|
}, [
|
|
2896
2897
|
f("div", ns, S(m.caption), 1),
|
|
2897
|
-
p(Ee)(m) ? (u(),
|
|
2898
|
+
p(Ee)(m) ? (u(), v("div", {
|
|
2898
2899
|
key: 0,
|
|
2899
2900
|
class: "cl-col-span-2 cl-gap-1 cl-span lg:cl-hidden",
|
|
2900
2901
|
onClick: (n) => a(m.field)
|
|
@@ -2939,14 +2940,14 @@ const Lo = {
|
|
|
2939
2940
|
m < r.length && m >= 0 && r.splice(m, 0, r.splice(c, 1)[0]);
|
|
2940
2941
|
}
|
|
2941
2942
|
function a(r, c) {
|
|
2942
|
-
const m = ce(e.columns), k = (r == null ? void 0 : r.checked) ?? !1, n = m.findIndex((
|
|
2943
|
+
const m = ce(e.columns), k = (r == null ? void 0 : r.checked) ?? !1, n = m.findIndex((b) => b.name === c.name);
|
|
2943
2944
|
n >= 0 && (m[n].visible = k), o("update:columns", m);
|
|
2944
2945
|
}
|
|
2945
2946
|
function i(r, c) {
|
|
2946
2947
|
const m = ce(e.columns), k = c === "up" ? r + 1 : r - 1;
|
|
2947
2948
|
d(m, r, k), o("update:columns", m);
|
|
2948
2949
|
}
|
|
2949
|
-
return (r, c) => (u(),
|
|
2950
|
+
return (r, c) => (u(), v(D, null, [
|
|
2950
2951
|
C(ge, re(r.$attrs, {
|
|
2951
2952
|
class: "cl-w-full",
|
|
2952
2953
|
size: "small",
|
|
@@ -2960,7 +2961,7 @@ const Lo = {
|
|
|
2960
2961
|
(u(), V(Re, { to: "body" }, [
|
|
2961
2962
|
C(ve, { name: "slide-left" }, {
|
|
2962
2963
|
default: P(() => [
|
|
2963
|
-
|
|
2964
|
+
H(f("div", cs, [
|
|
2964
2965
|
f("div", us, [
|
|
2965
2966
|
C(p(U), {
|
|
2966
2967
|
class: "cl-absolute cl-cursor-pointer cl-right-3 cl-text-off-white cl-top-3",
|
|
@@ -2975,7 +2976,7 @@ const Lo = {
|
|
|
2975
2976
|
f("strong", gs, S(p(l)("grid.visible")), 1),
|
|
2976
2977
|
f("strong", vs, S(p(l)("grid.order")), 1)
|
|
2977
2978
|
]),
|
|
2978
|
-
(u(!0),
|
|
2979
|
+
(u(!0), v(D, null, ee(r.columns, (m, k) => (u(), v("li", {
|
|
2979
2980
|
key: k,
|
|
2980
2981
|
class: "cl-border-b cl-border-grey-2 cl-flex cl-py-2 cl-text-sm cl-w-full"
|
|
2981
2982
|
}, [
|
|
@@ -2988,7 +2989,7 @@ const Lo = {
|
|
|
2988
2989
|
}, null, 8, ["model-value", "onClick"])
|
|
2989
2990
|
]),
|
|
2990
2991
|
f("div", ys, [
|
|
2991
|
-
m.visible === void 0 || m.visible === !0 ? (u(),
|
|
2992
|
+
m.visible === void 0 || m.visible === !0 ? (u(), v(D, { key: 0 }, [
|
|
2992
2993
|
k !== 0 ? (u(), V(p(U), {
|
|
2993
2994
|
key: 0,
|
|
2994
2995
|
class: "cl-cursor-pointer cl-inline-block cl-mr-2",
|
|
@@ -3001,7 +3002,7 @@ const Lo = {
|
|
|
3001
3002
|
icon: "ph:arrow-right",
|
|
3002
3003
|
onClick: (n) => i(k, "up")
|
|
3003
3004
|
}, null, 8, ["onClick"])) : N("", !0)
|
|
3004
|
-
], 64)) : (u(),
|
|
3005
|
+
], 64)) : (u(), v("em", ws, S(p(l)("grid.hidden")), 1))
|
|
3005
3006
|
])
|
|
3006
3007
|
]))), 128))
|
|
3007
3008
|
])
|
|
@@ -3029,47 +3030,47 @@ const Lo = {
|
|
|
3029
3030
|
setup(t, { emit: o }) {
|
|
3030
3031
|
const e = t, l = A({
|
|
3031
3032
|
get: () => e.columns,
|
|
3032
|
-
set: (
|
|
3033
|
-
}), s = A(() => l.value.filter((
|
|
3033
|
+
set: (y) => o("update:columns", y)
|
|
3034
|
+
}), s = A(() => l.value.filter((y) => y.visible ?? !0)), d = I({});
|
|
3034
3035
|
function a() {
|
|
3035
|
-
const
|
|
3036
|
+
const y = {};
|
|
3036
3037
|
window.innerWidth >= 1024 && l.value.forEach((T) => {
|
|
3037
3038
|
const E = T.width ? `${T.width}px` : "";
|
|
3038
|
-
|
|
3039
|
-
}), d.value =
|
|
3039
|
+
y[`${T.name}`] = `width: ${E}; min-width: ${E};`;
|
|
3040
|
+
}), d.value = y;
|
|
3040
3041
|
}
|
|
3041
|
-
function i(
|
|
3042
|
-
return d.value[
|
|
3042
|
+
function i(y) {
|
|
3043
|
+
return d.value[y] ?? "";
|
|
3043
3044
|
}
|
|
3044
3045
|
Ae(() => {
|
|
3045
3046
|
window.addEventListener("resize", a), a();
|
|
3046
3047
|
}), ze(() => window.removeEventListener("resize", a));
|
|
3047
3048
|
const r = A({
|
|
3048
3049
|
get: () => e.request,
|
|
3049
|
-
set: (
|
|
3050
|
+
set: (y) => o("update:request", y)
|
|
3050
3051
|
});
|
|
3051
3052
|
function c() {
|
|
3052
|
-
const
|
|
3053
|
-
|
|
3053
|
+
const y = ce(r.value);
|
|
3054
|
+
y.pageNumber = 1, y.filters = [], r.value = y;
|
|
3054
3055
|
}
|
|
3055
3056
|
const m = Ye(() => o("data-request"), 750);
|
|
3056
3057
|
Y(r, m, {
|
|
3057
3058
|
deep: !0,
|
|
3058
3059
|
immediate: !0
|
|
3059
3060
|
});
|
|
3060
|
-
const k = A(() => e.data), n = I(!1),
|
|
3061
|
+
const k = A(() => e.data), n = I(!1), b = I(!1);
|
|
3061
3062
|
Y(n, () => n.value ? o("edit-start") : o("edit-end"));
|
|
3062
|
-
const
|
|
3063
|
+
const h = A(() => ({
|
|
3063
3064
|
highlightRowSelection: !0,
|
|
3064
3065
|
...e.options
|
|
3065
3066
|
}));
|
|
3066
|
-
return (
|
|
3067
|
+
return (y, T) => (u(), v("div", ks, [
|
|
3067
3068
|
C(ve, { name: "fade" }, {
|
|
3068
3069
|
default: P(() => [
|
|
3069
|
-
|
|
3070
|
+
H(f("div", Cs, [
|
|
3070
3071
|
C(Ie)
|
|
3071
3072
|
], 512), [
|
|
3072
|
-
[Z,
|
|
3073
|
+
[Z, y.loading]
|
|
3073
3074
|
])
|
|
3074
3075
|
]),
|
|
3075
3076
|
_: 1
|
|
@@ -3077,16 +3078,16 @@ const Lo = {
|
|
|
3077
3078
|
C(Xt, {
|
|
3078
3079
|
"edit-mode": n.value,
|
|
3079
3080
|
"onUpdate:editMode": T[1] || (T[1] = (E) => n.value = E),
|
|
3080
|
-
"filter-panel-open":
|
|
3081
|
-
"onUpdate:filterPanelOpen": T[2] || (T[2] = (E) =>
|
|
3082
|
-
columns:
|
|
3083
|
-
options:
|
|
3084
|
-
request:
|
|
3085
|
-
loading:
|
|
3081
|
+
"filter-panel-open": b.value,
|
|
3082
|
+
"onUpdate:filterPanelOpen": T[2] || (T[2] = (E) => b.value = E),
|
|
3083
|
+
columns: y.columns,
|
|
3084
|
+
options: h.value,
|
|
3085
|
+
request: y.request,
|
|
3086
|
+
loading: y.loading,
|
|
3086
3087
|
onClearFilters: c
|
|
3087
3088
|
}, {
|
|
3088
3089
|
"additional-grid-actions": P((E) => [
|
|
3089
|
-
j(
|
|
3090
|
+
j(y.$slots, "additional-grid-actions", oe(ae(E)))
|
|
3090
3091
|
]),
|
|
3091
3092
|
"view-manager": P(() => [
|
|
3092
3093
|
C($s, {
|
|
@@ -3099,11 +3100,11 @@ const Lo = {
|
|
|
3099
3100
|
f("div", Ts, [
|
|
3100
3101
|
f("table", {
|
|
3101
3102
|
class: _(["cl-delay-75 cl-min-h-[276px] cl-overflow-x-auto cl-overscroll-x-none cl-text-left cl-transition-opacity cl-w-full", {
|
|
3102
|
-
"cl-opacity-40":
|
|
3103
|
+
"cl-opacity-40": y.loading
|
|
3103
3104
|
}])
|
|
3104
3105
|
}, [
|
|
3105
3106
|
f("colgroup", Os, [
|
|
3106
|
-
(u(!0),
|
|
3107
|
+
(u(!0), v(D, null, ee(s.value, (E, $) => (u(), v("col", {
|
|
3107
3108
|
key: $,
|
|
3108
3109
|
style: cl(i(E.name)),
|
|
3109
3110
|
span: 1
|
|
@@ -3112,28 +3113,28 @@ const Lo = {
|
|
|
3112
3113
|
C(is, {
|
|
3113
3114
|
request: r.value,
|
|
3114
3115
|
"onUpdate:request": T[3] || (T[3] = (E) => r.value = E),
|
|
3115
|
-
"filter-panel-open":
|
|
3116
|
-
"onUpdate:filterPanelOpen": T[4] || (T[4] = (E) =>
|
|
3116
|
+
"filter-panel-open": b.value,
|
|
3117
|
+
"onUpdate:filterPanelOpen": T[4] || (T[4] = (E) => b.value = E),
|
|
3117
3118
|
columns: s.value,
|
|
3118
|
-
options:
|
|
3119
|
-
"time-zone":
|
|
3119
|
+
options: h.value,
|
|
3120
|
+
"time-zone": y.timeZone
|
|
3120
3121
|
}, null, 8, ["request", "filter-panel-open", "columns", "options", "time-zone"]),
|
|
3121
3122
|
C(mo, {
|
|
3122
3123
|
columns: s.value,
|
|
3123
3124
|
request: r.value,
|
|
3124
3125
|
data: k.value,
|
|
3125
|
-
"time-zone":
|
|
3126
|
-
loading:
|
|
3126
|
+
"time-zone": y.timeZone,
|
|
3127
|
+
loading: y.loading,
|
|
3127
3128
|
"edit-mode": n.value,
|
|
3128
|
-
options:
|
|
3129
|
+
options: h.value,
|
|
3129
3130
|
onClearFilters: c,
|
|
3130
|
-
onRowEdit: T[5] || (T[5] = (E) =>
|
|
3131
|
-
onRowSelect: T[6] || (T[6] = (E) =>
|
|
3131
|
+
onRowEdit: T[5] || (T[5] = (E) => y.$emit("row-edit", E)),
|
|
3132
|
+
onRowSelect: T[6] || (T[6] = (E) => y.$emit("row-select", E))
|
|
3132
3133
|
}, Ue({ _: 2 }, [
|
|
3133
|
-
ee(
|
|
3134
|
+
ee(y.$slots, (E, $) => ({
|
|
3134
3135
|
name: $,
|
|
3135
3136
|
fn: P((z) => [
|
|
3136
|
-
j(
|
|
3137
|
+
j(y.$slots, $, oe(ae(z)))
|
|
3137
3138
|
])
|
|
3138
3139
|
}))
|
|
3139
3140
|
]), 1032, ["columns", "request", "data", "time-zone", "loading", "edit-mode", "options"])
|
|
@@ -3142,7 +3143,7 @@ const Lo = {
|
|
|
3142
3143
|
C(No, {
|
|
3143
3144
|
request: r.value,
|
|
3144
3145
|
"onUpdate:request": T[7] || (T[7] = (E) => r.value = E),
|
|
3145
|
-
data:
|
|
3146
|
+
data: y.data
|
|
3146
3147
|
}, null, 8, ["request", "data"])
|
|
3147
3148
|
]));
|
|
3148
3149
|
}
|
|
@@ -3156,7 +3157,7 @@ const Lo = {
|
|
|
3156
3157
|
const e = t, l = I();
|
|
3157
3158
|
return Me(l, () => {
|
|
3158
3159
|
(e.isOpen ?? !1) && o("open-click");
|
|
3159
|
-
}), (s, d) => (u(),
|
|
3160
|
+
}), (s, d) => (u(), v("header", Es, [
|
|
3160
3161
|
j(s.$slots, "logo"),
|
|
3161
3162
|
f("div", {
|
|
3162
3163
|
ref_key: "headerMenuElement",
|
|
@@ -3186,14 +3187,14 @@ const Lo = {
|
|
|
3186
3187
|
},
|
|
3187
3188
|
setup(t) {
|
|
3188
3189
|
const o = t;
|
|
3189
|
-
return (e, l) => (u(),
|
|
3190
|
+
return (e, l) => (u(), v("div", {
|
|
3190
3191
|
class: _(["md:cl-relative", {
|
|
3191
3192
|
"cl-bg-primary-default": (o == null ? void 0 : o.colour) === "default",
|
|
3192
3193
|
"cl-bg-blue-light": o.colour === "secondary"
|
|
3193
3194
|
}])
|
|
3194
3195
|
}, [
|
|
3195
3196
|
f("div", As, [
|
|
3196
|
-
e.image ? (u(),
|
|
3197
|
+
e.image ? (u(), v("img", {
|
|
3197
3198
|
key: 0,
|
|
3198
3199
|
src: e.image,
|
|
3199
3200
|
class: "cl-hidden cl-m-4 cl-max-h-12 cl-max-w-12 cl-ring-2 cl-ring-white cl-rounded-full md:cl-block"
|
|
@@ -3210,8 +3211,8 @@ const Lo = {
|
|
|
3210
3211
|
"cl-text-white": o.colour === "secondary"
|
|
3211
3212
|
}])
|
|
3212
3213
|
}, [
|
|
3213
|
-
e.username ? (u(),
|
|
3214
|
-
e.group ? (u(),
|
|
3214
|
+
e.username ? (u(), v("div", Ns, S(e.username), 1)) : N("", !0),
|
|
3215
|
+
e.group ? (u(), v("div", js, S(e.group), 1)) : N("", !0)
|
|
3215
3216
|
], 2),
|
|
3216
3217
|
f("div", _s, [
|
|
3217
3218
|
C(p(U), {
|
|
@@ -3226,7 +3227,7 @@ const Lo = {
|
|
|
3226
3227
|
]),
|
|
3227
3228
|
C(ve, { name: "fade" }, {
|
|
3228
3229
|
default: P(() => [
|
|
3229
|
-
|
|
3230
|
+
H(f("div", Rs, [
|
|
3230
3231
|
j(e.$slots, "default")
|
|
3231
3232
|
], 512), [
|
|
3232
3233
|
[Z, e.isOpen]
|
|
@@ -3272,7 +3273,7 @@ const Bs = {
|
|
|
3272
3273
|
}
|
|
3273
3274
|
return Y(() => e.disabled, (r) => {
|
|
3274
3275
|
r && (s.value = !1);
|
|
3275
|
-
}), (r, c) => d.value !== null && p(_e)(d.value) ? (u(),
|
|
3276
|
+
}), (r, c) => d.value !== null && p(_e)(d.value) ? (u(), v("div", Bs, [
|
|
3276
3277
|
f("div", {
|
|
3277
3278
|
class: _(["cl-flex cl-items-center", {
|
|
3278
3279
|
"cl-cursor-pointer": !r.disabled
|
|
@@ -3287,8 +3288,8 @@ const Bs = {
|
|
|
3287
3288
|
], 2),
|
|
3288
3289
|
C(ve, { name: "fade" }, {
|
|
3289
3290
|
default: P(() => [
|
|
3290
|
-
|
|
3291
|
-
(u(!0),
|
|
3291
|
+
H(f("div", Vs, [
|
|
3292
|
+
(u(!0), v(D, null, ee(a.value, (m, k) => (u(), v("div", {
|
|
3292
3293
|
key: k,
|
|
3293
3294
|
class: "cl-border-b cl-border-grey-0 cl-cursor-pointer cl-flex cl-items-center cl-justify-center cl-p-1 cl-text-center cl-transition-colors cl-w-28 hover:cl-bg-grey-0 last-child:cl-border-b-0 last:cl-border-b-0 lg:cl-p-2",
|
|
3294
3295
|
"data-localename": m.name,
|
|
@@ -3333,16 +3334,16 @@ const Bs = {
|
|
|
3333
3334
|
o("update:errors", []);
|
|
3334
3335
|
}
|
|
3335
3336
|
function c(k, n) {
|
|
3336
|
-
const
|
|
3337
|
+
const b = {
|
|
3337
3338
|
valid: !0,
|
|
3338
3339
|
message: ""
|
|
3339
3340
|
};
|
|
3340
|
-
return typeof n == "string" && n.trim() === "" && (
|
|
3341
|
+
return typeof n == "string" && n.trim() === "" && (b.valid = !1), b;
|
|
3341
3342
|
}
|
|
3342
3343
|
function m(k, n) {
|
|
3343
3344
|
a.value = k;
|
|
3344
3345
|
}
|
|
3345
|
-
return (k, n) => (u(),
|
|
3346
|
+
return (k, n) => (u(), v("div", Fs, [
|
|
3346
3347
|
f("div", Hs, [
|
|
3347
3348
|
j(k.$slots, "background")
|
|
3348
3349
|
]),
|
|
@@ -3350,7 +3351,7 @@ const Bs = {
|
|
|
3350
3351
|
f("div", Zs, [
|
|
3351
3352
|
j(k.$slots, "logo")
|
|
3352
3353
|
]),
|
|
3353
|
-
k.$slots["language-switcher"] ? (u(),
|
|
3354
|
+
k.$slots["language-switcher"] ? (u(), v("div", Gs, [
|
|
3354
3355
|
j(k.$slots, "language-switcher")
|
|
3355
3356
|
])) : N("", !0),
|
|
3356
3357
|
f("div", {
|
|
@@ -3369,7 +3370,7 @@ const Bs = {
|
|
|
3369
3370
|
C(ie, {
|
|
3370
3371
|
id: "cl-ui-login-usernameinput",
|
|
3371
3372
|
modelValue: l.value,
|
|
3372
|
-
"onUpdate:modelValue": n[0] || (n[0] = (
|
|
3373
|
+
"onUpdate:modelValue": n[0] || (n[0] = (b) => l.value = b),
|
|
3373
3374
|
modelModifiers: { trim: !0 },
|
|
3374
3375
|
class: "!cl-border-2 !cl-mb-1 cl-w-full",
|
|
3375
3376
|
"input-type": "email",
|
|
@@ -3395,26 +3396,26 @@ const Bs = {
|
|
|
3395
3396
|
icon: "ph:lock",
|
|
3396
3397
|
size: 18
|
|
3397
3398
|
}),
|
|
3398
|
-
|
|
3399
|
+
H(C(p(U), {
|
|
3399
3400
|
class: "cl-absolute cl-cursor-pointer cl-right-4 cl-top-2.5 cl-z-10",
|
|
3400
3401
|
icon: "ph:eye",
|
|
3401
3402
|
size: 18,
|
|
3402
|
-
onClick: n[1] || (n[1] = (
|
|
3403
|
+
onClick: n[1] || (n[1] = (b) => d.value = "text")
|
|
3403
3404
|
}, null, 512), [
|
|
3404
3405
|
[Z, d.value === "password"]
|
|
3405
3406
|
]),
|
|
3406
|
-
|
|
3407
|
+
H(C(p(U), {
|
|
3407
3408
|
class: "cl-absolute cl-cursor-pointer cl-right-4 cl-top-2.5 cl-z-10",
|
|
3408
3409
|
icon: "ph:eye-slash",
|
|
3409
3410
|
size: 18,
|
|
3410
|
-
onClick: n[2] || (n[2] = (
|
|
3411
|
+
onClick: n[2] || (n[2] = (b) => d.value = "password")
|
|
3411
3412
|
}, null, 512), [
|
|
3412
3413
|
[Z, d.value === "text"]
|
|
3413
3414
|
]),
|
|
3414
3415
|
C(ie, {
|
|
3415
3416
|
id: "cl-ui-login-passwordinput",
|
|
3416
3417
|
modelValue: s.value,
|
|
3417
|
-
"onUpdate:modelValue": n[3] || (n[3] = (
|
|
3418
|
+
"onUpdate:modelValue": n[3] || (n[3] = (b) => s.value = b),
|
|
3418
3419
|
class: "!cl-border-2 cl-w-full",
|
|
3419
3420
|
"input-type": d.value,
|
|
3420
3421
|
"highlight-when-valid": s.value !== void 0 && s.value !== "",
|
|
@@ -3451,16 +3452,16 @@ const Bs = {
|
|
|
3451
3452
|
], 2),
|
|
3452
3453
|
C(ve, { name: "cl-grow-down" }, {
|
|
3453
3454
|
default: P(() => {
|
|
3454
|
-
var
|
|
3455
|
+
var b;
|
|
3455
3456
|
return [
|
|
3456
|
-
|
|
3457
|
-
(u(!0),
|
|
3457
|
+
H(f("span", Js, [
|
|
3458
|
+
(u(!0), v(D, null, ee(k.errors, (h, y) => (u(), v("div", {
|
|
3458
3459
|
id: "cl-ui-login-errors",
|
|
3459
|
-
key:
|
|
3460
|
+
key: y,
|
|
3460
3461
|
class: "cl-font-semibold"
|
|
3461
|
-
}, S(
|
|
3462
|
+
}, S(h), 1))), 128))
|
|
3462
3463
|
], 512), [
|
|
3463
|
-
[Z, (
|
|
3464
|
+
[Z, (b = k.errors) == null ? void 0 : b.length]
|
|
3464
3465
|
])
|
|
3465
3466
|
];
|
|
3466
3467
|
}),
|
|
@@ -3486,70 +3487,72 @@ const Bs = {
|
|
|
3486
3487
|
props: {
|
|
3487
3488
|
colour: { default: "default" }
|
|
3488
3489
|
},
|
|
3489
|
-
setup(t) {
|
|
3490
|
-
const
|
|
3491
|
-
function
|
|
3492
|
-
let h =
|
|
3490
|
+
setup(t, { expose: o }) {
|
|
3491
|
+
const e = I([]), l = A(() => e.value.filter((b) => b.open === !0).length > 0);
|
|
3492
|
+
function s(b) {
|
|
3493
|
+
let h = e.value.find((y) => y.id === b);
|
|
3493
3494
|
return h || (h = {
|
|
3494
|
-
id:
|
|
3495
|
+
id: b,
|
|
3495
3496
|
open: !1
|
|
3496
|
-
},
|
|
3497
|
+
}, e.value.push(h)), h.open;
|
|
3497
3498
|
}
|
|
3498
|
-
function
|
|
3499
|
-
const h =
|
|
3500
|
-
h && (h.open = !h.open,
|
|
3501
|
-
|
|
3499
|
+
function d(b) {
|
|
3500
|
+
const h = e.value.find((y) => y.id === b);
|
|
3501
|
+
h && (h.open = !h.open, e.value.forEach((y) => {
|
|
3502
|
+
y.id !== b && (y.open = !1);
|
|
3502
3503
|
}));
|
|
3503
3504
|
}
|
|
3504
|
-
const
|
|
3505
|
+
const a = dl();
|
|
3505
3506
|
Y(
|
|
3506
|
-
() =>
|
|
3507
|
+
() => a,
|
|
3507
3508
|
() => {
|
|
3508
|
-
|
|
3509
|
+
i.value = !1;
|
|
3509
3510
|
},
|
|
3510
3511
|
{
|
|
3511
3512
|
deep: !0
|
|
3512
3513
|
}
|
|
3513
3514
|
);
|
|
3514
|
-
const
|
|
3515
|
-
function
|
|
3516
|
-
|
|
3515
|
+
const i = I(!1), r = I(!1), { start: c } = Qe(() => r.value = !1, 100);
|
|
3516
|
+
function m() {
|
|
3517
|
+
i.value = !i.value, r.value = !0, c();
|
|
3517
3518
|
}
|
|
3518
|
-
const
|
|
3519
|
-
function
|
|
3520
|
-
|
|
3521
|
-
|
|
3519
|
+
const k = I();
|
|
3520
|
+
function n() {
|
|
3521
|
+
i.value === !1 && l.value === !0 && e.value.forEach((b) => {
|
|
3522
|
+
b.open = !1;
|
|
3522
3523
|
});
|
|
3523
3524
|
}
|
|
3524
|
-
return Me(
|
|
3525
|
+
return Me(k, n), o({
|
|
3526
|
+
closeNavigation: n
|
|
3527
|
+
}), (b, h) => (u(), v("div", {
|
|
3525
3528
|
ref_key: "navElement",
|
|
3526
|
-
ref:
|
|
3529
|
+
ref: k,
|
|
3527
3530
|
class: "cl-flex cl-flex-nowrap cl-relative"
|
|
3528
3531
|
}, [
|
|
3529
3532
|
f("div", {
|
|
3530
3533
|
id: "group-container",
|
|
3531
3534
|
class: _(["cl-h-full cl-overflow-y-auto cl-overscroll-y-none cl-pb-20 cl-w-20 cl-z-40 xl:cl-pb-0", {
|
|
3532
|
-
"cl-bg-primary-default":
|
|
3533
|
-
"cl-bg-blue-dark":
|
|
3535
|
+
"cl-bg-primary-default": b.colour === "default",
|
|
3536
|
+
"cl-bg-blue-dark": b.colour === "secondary"
|
|
3534
3537
|
}])
|
|
3535
3538
|
}, [
|
|
3536
|
-
j(
|
|
3539
|
+
j(b.$slots, "icon", re({ navcolour: b.colour }, { groupIsOpen: s, toggleOpen: d }), void 0, !0)
|
|
3537
3540
|
], 2),
|
|
3538
|
-
|
|
3541
|
+
r.value ? (u(), v("div", tn)) : N("", !0),
|
|
3539
3542
|
C(ve, { name: "slide-right" }, {
|
|
3540
3543
|
default: P(() => [
|
|
3541
|
-
|
|
3544
|
+
H(f("div", {
|
|
3542
3545
|
class: _(["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", {
|
|
3543
|
-
"cl-relative":
|
|
3544
|
-
"cl-absolute cl-left-20 cl-shadow-lg": !
|
|
3546
|
+
"cl-relative": i.value,
|
|
3547
|
+
"cl-absolute cl-left-20 cl-shadow-lg": !i.value
|
|
3545
3548
|
}])
|
|
3546
3549
|
}, [
|
|
3547
3550
|
f("div", on, [
|
|
3548
3551
|
f("span", {
|
|
3549
3552
|
class: "cl-absolute cl-cursor-pointer cl-hidden cl-right-0 cl-top-1.5 lg:cl-block",
|
|
3550
|
-
onClick:
|
|
3553
|
+
onClick: m
|
|
3551
3554
|
}, [
|
|
3552
|
-
|
|
3555
|
+
i.value ? (u(), V(p(U), {
|
|
3553
3556
|
key: 1,
|
|
3554
3557
|
icon: "ph:push-pin-slash"
|
|
3555
3558
|
})) : (u(), V(p(U), {
|
|
@@ -3557,10 +3560,10 @@ const Bs = {
|
|
|
3557
3560
|
icon: "ph:push-pin"
|
|
3558
3561
|
}))
|
|
3559
3562
|
]),
|
|
3560
|
-
j(
|
|
3563
|
+
j(b.$slots, "default", oe(ae({ groupIsOpen: s })), void 0, !0)
|
|
3561
3564
|
])
|
|
3562
3565
|
], 2), [
|
|
3563
|
-
[Z,
|
|
3566
|
+
[Z, l.value]
|
|
3564
3567
|
])
|
|
3565
3568
|
]),
|
|
3566
3569
|
_: 3
|
|
@@ -3568,7 +3571,7 @@ const Bs = {
|
|
|
3568
3571
|
], 512));
|
|
3569
3572
|
}
|
|
3570
3573
|
});
|
|
3571
|
-
const nn = /* @__PURE__ */ me(sn, [["__scopeId", "data-v-
|
|
3574
|
+
const nn = /* @__PURE__ */ me(sn, [["__scopeId", "data-v-0958dcf5"]]), an = /* @__PURE__ */ B({
|
|
3572
3575
|
__name: "cl-ui-navigation-icon",
|
|
3573
3576
|
props: {
|
|
3574
3577
|
iconValue: {},
|
|
@@ -3576,7 +3579,7 @@ const nn = /* @__PURE__ */ me(sn, [["__scopeId", "data-v-971f01d8"]]), an = /* @
|
|
|
3576
3579
|
colour: { default: "default" }
|
|
3577
3580
|
},
|
|
3578
3581
|
setup(t) {
|
|
3579
|
-
return (o, e) => (u(),
|
|
3582
|
+
return (o, e) => (u(), v("div", {
|
|
3580
3583
|
class: _(["cl-cursor-pointer cl-flex cl-h-20 cl-items-center cl-justify-center cl-transition-colors cl-w-20", {
|
|
3581
3584
|
"cl-text-secondary-default hover:cl-bg-primary-dark hover:cl-text-white": o.colour === "default",
|
|
3582
3585
|
"cl-bg-primary-darker cl-text-white": o.open && o.colour === "default",
|
|
@@ -3600,8 +3603,8 @@ const nn = /* @__PURE__ */ me(sn, [["__scopeId", "data-v-971f01d8"]]), an = /* @
|
|
|
3600
3603
|
open: { type: Boolean }
|
|
3601
3604
|
},
|
|
3602
3605
|
setup(t) {
|
|
3603
|
-
return (o, e) => o.open ? (u(),
|
|
3604
|
-
o.$slots.title ? (u(),
|
|
3606
|
+
return (o, e) => o.open ? (u(), v(D, { key: 0 }, [
|
|
3607
|
+
o.$slots.title ? (u(), v("div", rn, [
|
|
3605
3608
|
j(o.$slots, "title")
|
|
3606
3609
|
])) : N("", !0),
|
|
3607
3610
|
f("div", cn, [
|
|
@@ -3614,8 +3617,8 @@ const nn = /* @__PURE__ */ me(sn, [["__scopeId", "data-v-971f01d8"]]), an = /* @
|
|
|
3614
3617
|
class: "cl-font-bold cl-mb-4 cl-select-none"
|
|
3615
3618
|
}, mn = { class: "cl-flex cl-flex-wrap cl-space-y-2" };
|
|
3616
3619
|
function gn(t, o) {
|
|
3617
|
-
return u(),
|
|
3618
|
-
t.$slots.title ? (u(),
|
|
3620
|
+
return u(), v("div", pn, [
|
|
3621
|
+
t.$slots.title ? (u(), v("div", fn, [
|
|
3619
3622
|
j(t.$slots, "title")
|
|
3620
3623
|
])) : N("", !0),
|
|
3621
3624
|
f("span", mn, [
|
|
@@ -3623,9 +3626,9 @@ function gn(t, o) {
|
|
|
3623
3626
|
])
|
|
3624
3627
|
]);
|
|
3625
3628
|
}
|
|
3626
|
-
const vn = /* @__PURE__ */ me(dn, [["render", gn]]), bn = {}, hn = { class: "cl-cursor-pointer cl-transition-colors cl-w-full hover:cl-text-
|
|
3629
|
+
const vn = /* @__PURE__ */ me(dn, [["render", gn]]), bn = {}, hn = { class: "cl-cursor-pointer cl-transition-colors cl-w-full hover:cl-text-primary-darker" };
|
|
3627
3630
|
function yn(t, o) {
|
|
3628
|
-
return u(),
|
|
3631
|
+
return u(), v("div", hn, [
|
|
3629
3632
|
j(t.$slots, "default")
|
|
3630
3633
|
]);
|
|
3631
3634
|
}
|
|
@@ -3658,9 +3661,9 @@ const wn = /* @__PURE__ */ me(bn, [["render", yn]]), $n = { class: "cl-w-full" }
|
|
|
3658
3661
|
c === "left" && (k = -m), e.value.scroll(e.value.scrollLeft + k, 0);
|
|
3659
3662
|
}
|
|
3660
3663
|
}
|
|
3661
|
-
return Ae(() => i()), ze(() => window.removeEventListener("resize", a)), (c, m) => (u(),
|
|
3664
|
+
return Ae(() => i()), ze(() => window.removeEventListener("resize", a)), (c, m) => (u(), v("div", $n, [
|
|
3662
3665
|
f("div", null, [
|
|
3663
|
-
l.value ? (u(),
|
|
3666
|
+
l.value ? (u(), v("div", {
|
|
3664
3667
|
key: 0,
|
|
3665
3668
|
class: "cl-bg-white cl-cursor-pointer cl-float-left cl-h-11 cl-w-4",
|
|
3666
3669
|
onClick: m[0] || (m[0] = (k) => r("left"))
|
|
@@ -3686,7 +3689,7 @@ const wn = /* @__PURE__ */ me(bn, [["render", yn]]), $n = { class: "cl-w-full" }
|
|
|
3686
3689
|
}, [
|
|
3687
3690
|
j(c.$slots, "headings", oe(ae({ isTabOpen: d, disabled: c.disabled, colour: c.colour })))
|
|
3688
3691
|
], 34),
|
|
3689
|
-
s.value ? (u(),
|
|
3692
|
+
s.value ? (u(), v("div", {
|
|
3690
3693
|
key: 1,
|
|
3691
3694
|
class: "cl-bg-white cl-bottom-12 cl-cursor-pointer cl-float-right cl-h-11 cl-relative cl-w-4",
|
|
3692
3695
|
onClick: m[1] || (m[1] = (k) => r("right"))
|
|
@@ -3716,7 +3719,7 @@ const wn = /* @__PURE__ */ me(bn, [["render", yn]]), $n = { class: "cl-w-full" }
|
|
|
3716
3719
|
function a() {
|
|
3717
3720
|
e.disabled || (l.value = !1, s.value = !1, o("update:currentTab", e.id));
|
|
3718
3721
|
}
|
|
3719
|
-
return (i, r) => (u(),
|
|
3722
|
+
return (i, r) => (u(), v("div", {
|
|
3720
3723
|
class: _(["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", {
|
|
3721
3724
|
"!cl-cursor-default cl-text-grey-4 !cl-border-grey-2": i.disabled,
|
|
3722
3725
|
"cl-border cl-border-b-0 cl-rounded-t-md cl-shadow-[inset_0_-1px_0_#ffffff] cl-cursor-default": d.value,
|