@citruslime/ui 2.6.5 → 2.6.6-beta.1
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
|
-
import { Icon as
|
|
1
|
+
import { Icon as H } from "@iconify/vue";
|
|
2
2
|
import { defineComponent as Q, ref as I, openBlock as p, createElementBlock as y, renderSlot as V, normalizeProps as ce, guardReactiveProps as ve, Fragment as X, createElementVNode as b, normalizeClass as M, createVNode as S, unref as v, Transition as Te, withCtx as Y, withDirectives as le, mergeProps as fe, vShow as te, createBlock as G, Teleport as ll, renderList as se, toDisplayString as q, createCommentVNode as j, nextTick as Fe, computed as R, toHandlers as Vl, withModifiers as ne, useCssVars as Ll, vModelText as Pl, onMounted as Ze, watch as oe, vModelDynamic as Ul, toRefs as Bl, withKeys as Ee, onUnmounted as tl, resolveComponent as Tl, createTextVNode as de, watchEffect as zl, createSlots as al, normalizeStyle as _l } from "vue";
|
|
3
|
-
import { generateStringId as
|
|
3
|
+
import { generateStringId as Hl, highlightText as xl } from "@citruslime/utils";
|
|
4
4
|
import { useMediaQuery as Gl, useDebounceFn as ol, unrefElement as Zl, tryOnScopeDispose as Kl, onClickOutside as nl, useTimeoutFn as $l, useWindowSize as Ql } from "@vueuse/core";
|
|
5
5
|
import { createI18n as Wl, useI18n as ie } from "vue-i18n";
|
|
6
|
-
import { DateTime as
|
|
6
|
+
import { DateTime as x } from "luxon";
|
|
7
7
|
import { DatePicker as We } from "v-calendar";
|
|
8
8
|
import { copy as ge } from "@citruslime/vue-utils";
|
|
9
9
|
const Yl = { class: "cl-overflow-hidden" }, Jl = /* @__PURE__ */ Q({
|
|
@@ -54,7 +54,7 @@ const Yl = { class: "cl-overflow-hidden" }, Jl = /* @__PURE__ */ Q({
|
|
|
54
54
|
onClick: t
|
|
55
55
|
}, [
|
|
56
56
|
b("div", Xl, [
|
|
57
|
-
S(v(
|
|
57
|
+
S(v(H), {
|
|
58
58
|
class: M(["cl-duration-300 cl-ease-in-out cl-text-grey-3 cl-transform-gpu cl-transition-transform", {
|
|
59
59
|
"cl-rotate-180": n.open
|
|
60
60
|
}]),
|
|
@@ -94,7 +94,7 @@ function nt(a, e) {
|
|
|
94
94
|
const rt = /* @__PURE__ */ ke(at, [["render", nt]]), Pe = I([]);
|
|
95
95
|
function sl(a) {
|
|
96
96
|
const e = {
|
|
97
|
-
id:
|
|
97
|
+
id: Hl(),
|
|
98
98
|
...a
|
|
99
99
|
};
|
|
100
100
|
Pe.value.push(e), setTimeout(() => Cl(e), a.duration);
|
|
@@ -133,7 +133,7 @@ const st = ["onClick"], it = { class: "cl-flex-1 cl-select-none cl-text-ellipsis
|
|
|
133
133
|
onClick: (c) => v(Cl)(t)
|
|
134
134
|
}), [
|
|
135
135
|
b("span", it, q(t.message), 1),
|
|
136
|
-
S(v(
|
|
136
|
+
S(v(H), {
|
|
137
137
|
class: "cl-inline-block cl-opacity-0 cl-transition-opacity group-hover:cl-opacity-100",
|
|
138
138
|
icon: "ph:x",
|
|
139
139
|
size: 16,
|
|
@@ -164,6 +164,7 @@ const st = ["onClick"], it = { class: "cl-flex-1 cl-select-none cl-text-ellipsis
|
|
|
164
164
|
}, [
|
|
165
165
|
V(e.$slots, "navigation"),
|
|
166
166
|
b("div", {
|
|
167
|
+
id: "cl-ui-app-container",
|
|
167
168
|
class: M(["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-0": e.removePadding,
|
|
169
170
|
"lg:cl-pb-8 md:cl-px-8 cl-px-2 md:cl-pt-8 cl-pt-2": !e.removePadding
|
|
@@ -495,9 +496,9 @@ function $t(a, e, l, t, n) {
|
|
|
495
496
|
o = t >= (Number(a) || 0), r = ye(o, he("input.greaterOrEqualToValue", { label: l, min: a.toString() }));
|
|
496
497
|
break;
|
|
497
498
|
case "date":
|
|
498
|
-
n ? (s =
|
|
499
|
+
n ? (s = x.fromISO(t).setZone(n), i = x.fromISO(a).setZone(n)) : (s = x.fromISO(t, {
|
|
499
500
|
zone: "UTC"
|
|
500
|
-
}), i =
|
|
501
|
+
}), i = x.fromISO(a, {
|
|
501
502
|
zone: "UTC"
|
|
502
503
|
})), o = s >= i, r = ye(o, he("input.afterOrEqualToValue", {
|
|
503
504
|
label: l,
|
|
@@ -505,9 +506,9 @@ function $t(a, e, l, t, n) {
|
|
|
505
506
|
}));
|
|
506
507
|
break;
|
|
507
508
|
case "datetime":
|
|
508
|
-
n ? (s =
|
|
509
|
+
n ? (s = x.fromISO(t).setZone(n), i = x.fromISO(a).setZone(n)) : (s = x.fromISO(t, {
|
|
509
510
|
zone: "UTC"
|
|
510
|
-
}), i =
|
|
511
|
+
}), i = x.fromISO(a, {
|
|
511
512
|
zone: "UTC"
|
|
512
513
|
})), o = s >= i, n && (i = i.setZone(n)), r = ye(o, he("input.afterOrEqualToValue", {
|
|
513
514
|
label: l,
|
|
@@ -544,9 +545,9 @@ function Ct(a, e, l, t, n) {
|
|
|
544
545
|
o = t <= (Number(a) || 0), r = ye(o, he("input.lessOrEqualToValue", { label: l, max: a.toString() }));
|
|
545
546
|
break;
|
|
546
547
|
case "date":
|
|
547
|
-
n ? (s =
|
|
548
|
+
n ? (s = x.fromISO(t).setZone(n), i = x.fromISO(a).setZone(n)) : (s = x.fromISO(t, {
|
|
548
549
|
zone: "UTC"
|
|
549
|
-
}), i =
|
|
550
|
+
}), i = x.fromISO(a, {
|
|
550
551
|
zone: "UTC"
|
|
551
552
|
})), o = s <= i, r = ye(o, he("input.beforeOrEqualToValue", {
|
|
552
553
|
label: l,
|
|
@@ -554,9 +555,9 @@ function Ct(a, e, l, t, n) {
|
|
|
554
555
|
}));
|
|
555
556
|
break;
|
|
556
557
|
case "datetime":
|
|
557
|
-
n ? (s =
|
|
558
|
+
n ? (s = x.fromISO(t).setZone(n), i = x.fromISO(a).setZone(n)) : (s = x.fromISO(t, {
|
|
558
559
|
zone: "UTC"
|
|
559
|
-
}), i =
|
|
560
|
+
}), i = x.fromISO(a, {
|
|
560
561
|
zone: "UTC"
|
|
561
562
|
})), o = s <= i, r = ye(o, he("input.beforeOrEqualToValue", {
|
|
562
563
|
label: l,
|
|
@@ -643,7 +644,7 @@ const Nt = {
|
|
|
643
644
|
onClick: s[0] || (s[0] = (i) => o.$emit("togglePopover"))
|
|
644
645
|
}, {
|
|
645
646
|
default: Y(() => [
|
|
646
|
-
S(v(
|
|
647
|
+
S(v(H), {
|
|
647
648
|
icon: "bi:calendar3",
|
|
648
649
|
class: "cl-text-xl icon"
|
|
649
650
|
})
|
|
@@ -661,7 +662,7 @@ const Nt = {
|
|
|
661
662
|
onClick: s[1] || (s[1] = (i) => o.$emit("clear"))
|
|
662
663
|
}, {
|
|
663
664
|
default: Y(() => [
|
|
664
|
-
S(v(
|
|
665
|
+
S(v(H), {
|
|
665
666
|
icon: "ph:x",
|
|
666
667
|
class: "clear-icon"
|
|
667
668
|
})
|
|
@@ -678,7 +679,7 @@ const Nt = {
|
|
|
678
679
|
disabled: o.disabled,
|
|
679
680
|
placeholder: r.value
|
|
680
681
|
}, Vl(o.events, !0)), null, 16, At),
|
|
681
|
-
le(S(v(
|
|
682
|
+
le(S(v(H), {
|
|
682
683
|
class: M(["cl-absolute cl-bg-transparent cl-cursor-text cl-left-2 cl-text-grey-4 cl-top-3.5 icon", {
|
|
683
684
|
"!cl-bg-off-white": o.disabled
|
|
684
685
|
}]),
|
|
@@ -688,13 +689,13 @@ const Nt = {
|
|
|
688
689
|
[te, !o.disabled]
|
|
689
690
|
]),
|
|
690
691
|
o.disabled ? j("", !0) : (p(), y("div", qt, [
|
|
691
|
-
o.type !== "time" ? (p(), G(v(
|
|
692
|
+
o.type !== "time" ? (p(), G(v(H), {
|
|
692
693
|
key: 0,
|
|
693
694
|
class: "cl-cursor-pointer hover:cl-text-link-light",
|
|
694
695
|
icon: "ph:arrow-counter-clockwise",
|
|
695
696
|
onClick: s[2] || (s[2] = ne((i) => o.$emit("reset"), ["prevent"]))
|
|
696
697
|
})) : j("", !0),
|
|
697
|
-
!o.required && o.date && (o.type !== "time" || o.date !== "00:00") ? (p(), G(v(
|
|
698
|
+
!o.required && o.date && (o.type !== "time" || o.date !== "00:00") ? (p(), G(v(H), {
|
|
698
699
|
key: 1,
|
|
699
700
|
class: "cl-cursor-pointer clear-icon hover:cl-text-link-light md:cl-ml-0.5",
|
|
700
701
|
icon: "ph:x",
|
|
@@ -891,26 +892,26 @@ const Ye = /* @__PURE__ */ ke(Rt, [["__scopeId", "data-v-905eee52"]]), Dt = { cl
|
|
|
891
892
|
setup(a, { expose: e, emit: l }) {
|
|
892
893
|
const t = a, n = R(() => t.timeZone ?? "UTC"), c = R({
|
|
893
894
|
get() {
|
|
894
|
-
let
|
|
895
|
-
return t.type === "time" ?
|
|
895
|
+
let d = null;
|
|
896
|
+
return t.type === "time" ? d = t.date === null ? "00:00" : t.date : t.date !== null && typeof t.date == "string" ? d = x.fromISO(t.date, {
|
|
896
897
|
zone: n.value
|
|
897
|
-
}).toJSDate() : t.date !== null && t.date.start && t.date.end && (
|
|
898
|
-
start:
|
|
898
|
+
}).toJSDate() : t.date !== null && t.date.start && t.date.end && (d = {
|
|
899
|
+
start: x.fromISO(t.date.start, {
|
|
899
900
|
zone: n.value
|
|
900
901
|
}).toJSDate(),
|
|
901
|
-
end:
|
|
902
|
+
end: x.fromISO(t.date.end, {
|
|
902
903
|
zone: n.value
|
|
903
904
|
}).endOf("day").toJSDate()
|
|
904
|
-
}),
|
|
905
|
+
}), d;
|
|
905
906
|
},
|
|
906
|
-
set(
|
|
907
|
+
set(d) {
|
|
907
908
|
let f = null;
|
|
908
909
|
if (t.type === "time")
|
|
909
|
-
f =
|
|
910
|
-
else if (
|
|
911
|
-
f = r(
|
|
912
|
-
else if (
|
|
913
|
-
const O =
|
|
910
|
+
f = d;
|
|
911
|
+
else if (d !== null && t.type !== "dateRange")
|
|
912
|
+
f = r(d, !1);
|
|
913
|
+
else if (d !== null) {
|
|
914
|
+
const O = d;
|
|
914
915
|
f = {
|
|
915
916
|
start: r(O.start, !0) ?? "",
|
|
916
917
|
end: r(O.end, !1) ?? ""
|
|
@@ -919,8 +920,8 @@ const Ye = /* @__PURE__ */ ke(Rt, [["__scopeId", "data-v-905eee52"]]), Dt = { cl
|
|
|
919
920
|
l("update:date", f);
|
|
920
921
|
}
|
|
921
922
|
});
|
|
922
|
-
function r(
|
|
923
|
-
let O =
|
|
923
|
+
function r(d, f) {
|
|
924
|
+
let O = x.fromJSDate(d, { zone: n.value }).setZone(n.value);
|
|
924
925
|
f && (O = O.startOf("day"));
|
|
925
926
|
let $ = O.toISO();
|
|
926
927
|
return t.timeZone === null && ($ = ($ == null ? void 0 : $.replace("Z", "")) ?? null), $;
|
|
@@ -929,26 +930,35 @@ const Ye = /* @__PURE__ */ ke(Rt, [["__scopeId", "data-v-905eee52"]]), Dt = { cl
|
|
|
929
930
|
visibility: "focus",
|
|
930
931
|
showDelay: 0,
|
|
931
932
|
hideDelay: 250,
|
|
932
|
-
positionFixed: !0
|
|
933
|
+
positionFixed: !0,
|
|
934
|
+
placement: "auto",
|
|
935
|
+
modifiers: [
|
|
936
|
+
{
|
|
937
|
+
name: "preventOverflow",
|
|
938
|
+
options: {
|
|
939
|
+
boundary: document.querySelector("#cl-ui-app-container")
|
|
940
|
+
}
|
|
941
|
+
}
|
|
942
|
+
]
|
|
933
943
|
});
|
|
934
944
|
function i() {
|
|
935
|
-
let
|
|
945
|
+
let d = m(x.now());
|
|
936
946
|
if (t.max) {
|
|
937
|
-
const f =
|
|
938
|
-
|
|
947
|
+
const f = x.fromISO(t.max).setZone(n.value);
|
|
948
|
+
d > f && (d = m(f), d.equals(f) || (t.type === "date" ? d = d.minus({ days: 1 }) : d = d.minus({ minutes: 1 })));
|
|
939
949
|
}
|
|
940
950
|
if (t.min) {
|
|
941
|
-
const f =
|
|
942
|
-
|
|
951
|
+
const f = x.fromISO(t.min).setZone(n.value);
|
|
952
|
+
d < f && (d = m(f), d.equals(f) || (t.type === "date" ? d = d.plus({ days: 1 }) : d = d.plus({ minutes: 1 })));
|
|
943
953
|
}
|
|
944
|
-
c.value =
|
|
954
|
+
c.value = d.toJSDate();
|
|
945
955
|
}
|
|
946
|
-
function m(
|
|
947
|
-
let f =
|
|
956
|
+
function m(d) {
|
|
957
|
+
let f = d.set({ second: 0, millisecond: 0 }).setZone(n.value);
|
|
948
958
|
return t.type === "date" && (f = f.set({ hour: 0, minute: 0 }).setZone(n.value)), f;
|
|
949
959
|
}
|
|
950
960
|
const k = R(() => {
|
|
951
|
-
const
|
|
961
|
+
const d = x.fromObject({
|
|
952
962
|
day: 3,
|
|
953
963
|
month: 4,
|
|
954
964
|
year: 2e3,
|
|
@@ -956,60 +966,60 @@ const Ye = /* @__PURE__ */ ke(Rt, [["__scopeId", "data-v-905eee52"]]), Dt = { cl
|
|
|
956
966
|
minute: 6
|
|
957
967
|
}).setLocale(o.value);
|
|
958
968
|
let f;
|
|
959
|
-
return t.type === "date" ? f =
|
|
960
|
-
}),
|
|
961
|
-
let
|
|
969
|
+
return t.type === "date" ? f = d.toFormat("D") : t.type === "datetime" ? f = d.toFormat("f") : f = d.toFormat("t"), f.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();
|
|
970
|
+
}), u = I(null), h = R(() => {
|
|
971
|
+
let d;
|
|
962
972
|
if (t.date && t.type !== "dateRange")
|
|
963
|
-
|
|
973
|
+
d = x.fromISO(t.date, {
|
|
964
974
|
zone: n.value
|
|
965
975
|
});
|
|
966
976
|
else if (t.date && t.type === "dateRange") {
|
|
967
977
|
const f = t.date;
|
|
968
|
-
|
|
978
|
+
d = x.fromISO(f.start, {
|
|
969
979
|
zone: n.value
|
|
970
980
|
});
|
|
971
981
|
} else
|
|
972
|
-
t.initialDate ?
|
|
982
|
+
t.initialDate ? d = x.fromISO(t.initialDate, {
|
|
973
983
|
zone: n.value
|
|
974
|
-
}) :
|
|
975
|
-
return
|
|
984
|
+
}) : d = x.utc().setZone(n.value);
|
|
985
|
+
return d;
|
|
976
986
|
});
|
|
977
987
|
e({
|
|
978
988
|
focus() {
|
|
979
|
-
var
|
|
980
|
-
(
|
|
989
|
+
var d;
|
|
990
|
+
(d = u.value) == null || d.focus();
|
|
981
991
|
}
|
|
982
992
|
});
|
|
983
993
|
const A = I(null), P = I();
|
|
984
|
-
function U(
|
|
985
|
-
const f = Z(
|
|
986
|
-
c.value = f, A.value =
|
|
994
|
+
function U(d) {
|
|
995
|
+
const f = Z(d);
|
|
996
|
+
c.value = f, A.value = d, P.value.move(f.start), P.value.hidePopover();
|
|
987
997
|
}
|
|
988
|
-
function Z(
|
|
989
|
-
const f =
|
|
998
|
+
function Z(d) {
|
|
999
|
+
const f = d.range, O = d.scope === "past" ? -1 : d.scope === "current" ? 0 : 1, $ = x.now().setZone(n.value).startOf(f).plus({ days: f === "day" ? O : 0, weeks: f === "week" ? O : 0, months: f === "month" ? O : 0, years: f === "year" ? O : 0 }), _ = $.endOf(f);
|
|
990
1000
|
return {
|
|
991
1001
|
start: $.toJSDate(),
|
|
992
1002
|
end: _.toJSDate()
|
|
993
1003
|
};
|
|
994
1004
|
}
|
|
995
1005
|
const ae = R(() => {
|
|
996
|
-
let
|
|
1006
|
+
let d = "";
|
|
997
1007
|
const f = c.value;
|
|
998
1008
|
if (f !== null && Object.hasOwn(f, "start") && Object.hasOwn(f, "end")) {
|
|
999
|
-
const O =
|
|
1000
|
-
|
|
1009
|
+
const O = x.fromJSDate(f.start).setZone(n.value).setLocale(o.value).toLocaleString(x.DATETIME_SHORT), $ = x.fromJSDate(f.end).setZone(n.value).setLocale(o.value).toLocaleString(x.DATETIME_SHORT);
|
|
1010
|
+
d = `${O} - ${$}`;
|
|
1001
1011
|
}
|
|
1002
|
-
return
|
|
1012
|
+
return d;
|
|
1003
1013
|
}), N = Gl("(min-width: 768px)"), B = R(() => N.value ? 2 : 1);
|
|
1004
|
-
return (
|
|
1014
|
+
return (d, f) => d.type === "time" ? (p(), G(v(We), {
|
|
1005
1015
|
key: 0,
|
|
1006
1016
|
modelValue: c.value,
|
|
1007
1017
|
"onUpdate:modelValue": f[1] || (f[1] = (O) => c.value = O),
|
|
1008
1018
|
modelModifiers: { string: !0 },
|
|
1009
1019
|
locale: v(o),
|
|
1010
1020
|
is24hr: v(o) !== "en-US",
|
|
1011
|
-
mode:
|
|
1012
|
-
"is-required":
|
|
1021
|
+
mode: d.type,
|
|
1022
|
+
"is-required": d.required,
|
|
1013
1023
|
"update-on-input": !1,
|
|
1014
1024
|
masks: { modelValue: "HH:mm", input: k.value, inputTime: [k.value], inputTime24hr: [k.value] },
|
|
1015
1025
|
color: "primary",
|
|
@@ -1018,20 +1028,20 @@ const Ye = /* @__PURE__ */ ke(Rt, [["__scopeId", "data-v-905eee52"]]), Dt = { cl
|
|
|
1018
1028
|
popover: s.value
|
|
1019
1029
|
}, {
|
|
1020
1030
|
default: Y(({ inputValue: O, inputEvents: $ }) => [
|
|
1021
|
-
S(Ye, fe(
|
|
1031
|
+
S(Ye, fe(d.$attrs, {
|
|
1022
1032
|
ref_key: "input",
|
|
1023
|
-
ref:
|
|
1033
|
+
ref: u,
|
|
1024
1034
|
date: O,
|
|
1025
1035
|
events: $,
|
|
1026
|
-
type:
|
|
1027
|
-
placeholder:
|
|
1028
|
-
required:
|
|
1029
|
-
disabled:
|
|
1036
|
+
type: d.type,
|
|
1037
|
+
placeholder: d.placeholder,
|
|
1038
|
+
required: d.required,
|
|
1039
|
+
disabled: d.disabled,
|
|
1030
1040
|
onClear: f[0] || (f[0] = (_) => c.value = null)
|
|
1031
1041
|
}), null, 16, ["date", "events", "type", "placeholder", "required", "disabled"])
|
|
1032
1042
|
]),
|
|
1033
1043
|
_: 1
|
|
1034
|
-
}, 8, ["modelValue", "locale", "is24hr", "mode", "is-required", "masks", "popover"])) :
|
|
1044
|
+
}, 8, ["modelValue", "locale", "is24hr", "mode", "is-required", "masks", "popover"])) : d.type === "dateRange" ? (p(), G(v(We), {
|
|
1035
1045
|
key: 1,
|
|
1036
1046
|
ref_key: "calendar",
|
|
1037
1047
|
ref: P,
|
|
@@ -1045,18 +1055,18 @@ const Ye = /* @__PURE__ */ ke(Rt, [["__scopeId", "data-v-905eee52"]]), Dt = { cl
|
|
|
1045
1055
|
timezone: n.value,
|
|
1046
1056
|
columns: B.value,
|
|
1047
1057
|
popover: s.value,
|
|
1048
|
-
"min-date":
|
|
1049
|
-
"max-date":
|
|
1058
|
+
"min-date": d.min,
|
|
1059
|
+
"max-date": d.max,
|
|
1050
1060
|
"initial-page": h.value,
|
|
1051
1061
|
onDayclick: f[4] || (f[4] = (O) => A.value = null)
|
|
1052
1062
|
}, {
|
|
1053
1063
|
default: Y(({ togglePopover: O }) => [
|
|
1054
|
-
S(Ye, fe(
|
|
1064
|
+
S(Ye, fe(d.$attrs, {
|
|
1055
1065
|
ref_key: "input",
|
|
1056
|
-
ref:
|
|
1057
|
-
type:
|
|
1058
|
-
required:
|
|
1059
|
-
disabled:
|
|
1066
|
+
ref: u,
|
|
1067
|
+
type: d.type,
|
|
1068
|
+
required: d.required,
|
|
1069
|
+
disabled: d.disabled,
|
|
1060
1070
|
"range-selected": c.value !== null,
|
|
1061
1071
|
title: ae.value,
|
|
1062
1072
|
placeholder: null,
|
|
@@ -1067,9 +1077,9 @@ const Ye = /* @__PURE__ */ ke(Rt, [["__scopeId", "data-v-905eee52"]]), Dt = { cl
|
|
|
1067
1077
|
}), null, 16, ["type", "required", "disabled", "range-selected", "title", "onTogglePopover"])
|
|
1068
1078
|
]),
|
|
1069
1079
|
footer: Y(() => [
|
|
1070
|
-
|
|
1080
|
+
d.quickDateScope !== "none" ? (p(), G(Lt, {
|
|
1071
1081
|
key: 0,
|
|
1072
|
-
scope:
|
|
1082
|
+
scope: d.quickDateScope,
|
|
1073
1083
|
"selected-quick-date": A.value,
|
|
1074
1084
|
"current-date-range": t.date,
|
|
1075
1085
|
onQuickDateSelected: U
|
|
@@ -1083,11 +1093,11 @@ const Ye = /* @__PURE__ */ ke(Rt, [["__scopeId", "data-v-905eee52"]]), Dt = { cl
|
|
|
1083
1093
|
locale: v(o),
|
|
1084
1094
|
is24hr: v(o) !== "en-US",
|
|
1085
1095
|
timezone: n.value,
|
|
1086
|
-
mode:
|
|
1087
|
-
"min-date":
|
|
1088
|
-
"max-date":
|
|
1096
|
+
mode: d.type,
|
|
1097
|
+
"min-date": d.min,
|
|
1098
|
+
"max-date": d.max,
|
|
1089
1099
|
"initial-page": h.value,
|
|
1090
|
-
"is-required":
|
|
1100
|
+
"is-required": d.required,
|
|
1091
1101
|
"update-on-input": !1,
|
|
1092
1102
|
masks: { L: k.value, inputDateTime: [k.value], inputDateTime24hr: [k.value] },
|
|
1093
1103
|
color: "primary",
|
|
@@ -1096,15 +1106,15 @@ const Ye = /* @__PURE__ */ ke(Rt, [["__scopeId", "data-v-905eee52"]]), Dt = { cl
|
|
|
1096
1106
|
popover: s.value
|
|
1097
1107
|
}, {
|
|
1098
1108
|
default: Y(({ inputValue: O, inputEvents: $ }) => [
|
|
1099
|
-
S(Ye, fe(
|
|
1109
|
+
S(Ye, fe(d.$attrs, {
|
|
1100
1110
|
ref_key: "input",
|
|
1101
|
-
ref:
|
|
1111
|
+
ref: u,
|
|
1102
1112
|
date: O,
|
|
1103
1113
|
events: $,
|
|
1104
|
-
type:
|
|
1105
|
-
placeholder:
|
|
1106
|
-
required:
|
|
1107
|
-
disabled:
|
|
1114
|
+
type: d.type,
|
|
1115
|
+
placeholder: d.placeholder,
|
|
1116
|
+
required: d.required,
|
|
1117
|
+
disabled: d.disabled,
|
|
1108
1118
|
onClear: f[5] || (f[5] = (_) => c.value = null),
|
|
1109
1119
|
onReset: i
|
|
1110
1120
|
}), null, 16, ["date", "events", "type", "placeholder", "required", "disabled"])
|
|
@@ -1151,7 +1161,7 @@ const Bt = [
|
|
|
1151
1161
|
"text",
|
|
1152
1162
|
"url",
|
|
1153
1163
|
...Re
|
|
1154
|
-
], zt = { class: "cl-flex cl-items-start" }, _t = { class: "cl-w-full" },
|
|
1164
|
+
], zt = { class: "cl-flex cl-items-start" }, _t = { class: "cl-w-full" }, Ht = ["min", "max", "step", "disabled"], xt = { class: "cl-bg-transparent cl-text-center cl-text-sm cl-w-full" }, Gt = { class: "cl-bg-transparent cl-text-sm" }, Zt = {
|
|
1155
1165
|
key: 1,
|
|
1156
1166
|
class: "cl-emphasis-danger cl-text-sm cl-w-full"
|
|
1157
1167
|
}, Kt = /* @__PURE__ */ Q({
|
|
@@ -1170,32 +1180,32 @@ const Bt = [
|
|
|
1170
1180
|
},
|
|
1171
1181
|
setup(a, { expose: e, emit: l }) {
|
|
1172
1182
|
const t = a;
|
|
1173
|
-
Ll((
|
|
1183
|
+
Ll((u) => ({
|
|
1174
1184
|
44703202: i.value
|
|
1175
1185
|
}));
|
|
1176
1186
|
const { n, t: c } = ie(), r = I(), o = R({
|
|
1177
1187
|
get: () => t.value,
|
|
1178
|
-
set: (
|
|
1179
|
-
}), s = ol((
|
|
1188
|
+
set: (u) => l("update:value", u ?? "")
|
|
1189
|
+
}), s = ol((u) => o.value = u || u === 0 ? u : t.min, 1e3), i = R(() => {
|
|
1180
1190
|
let h = ((typeof o.value == "number" ? o.value : t.min) - t.min) / (t.max - t.min) * 100;
|
|
1181
1191
|
return h < 35 && h > 0 ? h < 20 ? h += 0.5 : h += 0.25 : h > 65 && h < 100 && (h > 80 ? h -= 0.5 : h -= 0.25), `${h}%`;
|
|
1182
1192
|
}), m = R(() => t.min <= t.max && t.step > 0);
|
|
1183
1193
|
e({
|
|
1184
1194
|
focus() {
|
|
1185
|
-
var
|
|
1186
|
-
(
|
|
1195
|
+
var u;
|
|
1196
|
+
(u = r.value) == null || u.focus();
|
|
1187
1197
|
}
|
|
1188
1198
|
});
|
|
1189
1199
|
const k = I(!1);
|
|
1190
|
-
return (
|
|
1200
|
+
return (u, h) => m.value ? (p(), y("div", ce(fe({ key: 0 }, u.$attrs)), [
|
|
1191
1201
|
b("div", zt, [
|
|
1192
1202
|
b("span", {
|
|
1193
1203
|
class: M(["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", {
|
|
1194
|
-
"cl-bg-white cl-cursor-pointer hover:cl-border-grey-1": !
|
|
1195
|
-
"cl-bg-grey-0":
|
|
1204
|
+
"cl-bg-white cl-cursor-pointer hover:cl-border-grey-1": !u.disabled,
|
|
1205
|
+
"cl-bg-grey-0": u.disabled
|
|
1196
1206
|
}]),
|
|
1197
|
-
onClick: h[0] || (h[0] = (A) => o.value =
|
|
1198
|
-
}, q(v(n)(
|
|
1207
|
+
onClick: h[0] || (h[0] = (A) => o.value = u.disabled ? o.value : u.min)
|
|
1208
|
+
}, q(v(n)(u.min, Number.isInteger(u.min) ? v(ue).INTEGER : v(ue).DECIMAL)), 3),
|
|
1199
1209
|
b("div", _t, [
|
|
1200
1210
|
k.value ? (p(), G(v(me), {
|
|
1201
1211
|
key: 0,
|
|
@@ -1208,11 +1218,11 @@ const Bt = [
|
|
|
1208
1218
|
],
|
|
1209
1219
|
class: "cl-min-w-[8.5rem] cl-w-full",
|
|
1210
1220
|
"input-type": "number",
|
|
1211
|
-
min:
|
|
1212
|
-
max:
|
|
1213
|
-
step:
|
|
1214
|
-
disabled:
|
|
1215
|
-
"placeholder-text":
|
|
1221
|
+
min: u.min,
|
|
1222
|
+
max: u.max,
|
|
1223
|
+
step: u.step,
|
|
1224
|
+
disabled: u.disabled,
|
|
1225
|
+
"placeholder-text": u.placeholder,
|
|
1216
1226
|
"show-validation-messages": !1
|
|
1217
1227
|
}, null, 8, ["modelValue", "min", "max", "step", "disabled", "placeholder-text", "onUpdate:modelValue"])) : (p(), y(X, { key: 1 }, [
|
|
1218
1228
|
le(b("input", {
|
|
@@ -1221,11 +1231,11 @@ const Bt = [
|
|
|
1221
1231
|
"onUpdate:modelValue": h[2] || (h[2] = (A) => o.value = A),
|
|
1222
1232
|
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",
|
|
1223
1233
|
type: "range",
|
|
1224
|
-
min:
|
|
1225
|
-
max:
|
|
1226
|
-
step:
|
|
1227
|
-
disabled:
|
|
1228
|
-
}, null, 8,
|
|
1234
|
+
min: u.min,
|
|
1235
|
+
max: u.max,
|
|
1236
|
+
step: u.step,
|
|
1237
|
+
disabled: u.disabled
|
|
1238
|
+
}, null, 8, Ht), [
|
|
1229
1239
|
[
|
|
1230
1240
|
Pl,
|
|
1231
1241
|
o.value,
|
|
@@ -1233,22 +1243,22 @@ const Bt = [
|
|
|
1233
1243
|
{ number: !0 }
|
|
1234
1244
|
]
|
|
1235
1245
|
]),
|
|
1236
|
-
b("div",
|
|
1246
|
+
b("div", xt, q(o.value), 1)
|
|
1237
1247
|
], 64))
|
|
1238
1248
|
]),
|
|
1239
1249
|
b("span", {
|
|
1240
1250
|
class: M(["cl-border cl-border-transparent cl-leading-6 cl-ml-1 cl-px-2 cl-rounded-full cl-select-none cl-shadow cl-text-center cl-text-xs", {
|
|
1241
|
-
"cl-bg-white cl-cursor-pointer hover:cl-border-grey-1": !
|
|
1242
|
-
"cl-bg-grey-0":
|
|
1251
|
+
"cl-bg-white cl-cursor-pointer hover:cl-border-grey-1": !u.disabled,
|
|
1252
|
+
"cl-bg-grey-0": u.disabled
|
|
1243
1253
|
}]),
|
|
1244
|
-
onClick: h[3] || (h[3] = (A) => o.value =
|
|
1245
|
-
}, q(v(n)(
|
|
1254
|
+
onClick: h[3] || (h[3] = (A) => o.value = u.disabled ? o.value : u.max)
|
|
1255
|
+
}, q(v(n)(u.max, Number.isInteger(u.max) ? v(ue).INTEGER : v(ue).DECIMAL)), 3),
|
|
1246
1256
|
b("div", Gt, [
|
|
1247
1257
|
b("div", {
|
|
1248
1258
|
class: "cl-bg-white cl-border cl-border-transparent cl-cursor-pointer cl-float-right cl-p-1.5 cl-px-2 cl-rounded-full cl-shadow cl-text-xs hover:cl-border-grey-1",
|
|
1249
1259
|
onClick: h[4] || (h[4] = (A) => k.value = !k.value)
|
|
1250
1260
|
}, [
|
|
1251
|
-
S(v(
|
|
1261
|
+
S(v(H), { icon: "ph:arrows-left-right-thin" })
|
|
1252
1262
|
])
|
|
1253
1263
|
])
|
|
1254
1264
|
])
|
|
@@ -1375,8 +1385,8 @@ const Jt = { class: "cl-flex cl-justify-between" }, Xt = { class: "cl-w-full" },
|
|
|
1375
1385
|
set: (g) => f(g, !1)
|
|
1376
1386
|
}), k = R({
|
|
1377
1387
|
get: () => t.modelValue,
|
|
1378
|
-
set: (g) =>
|
|
1379
|
-
}),
|
|
1388
|
+
set: (g) => d(g)
|
|
1389
|
+
}), u = R(() => typeof t.min == "number" ? t.min.toString() : t.min), h = R(() => typeof t.max == "number" ? t.max.toString() : t.max), A = R(() => typeof t.min == "number" || t.min === null ? t.min : parseFloat(t.min)), P = R(() => typeof t.max == "number" || t.max === null ? t.max : parseFloat(t.max)), U = R(() => t.messageWhenValid.trim() !== "" ? t.messageWhenValid : ""), Z = I(!0), ae = I(!0), N = I([]), B = R(() => {
|
|
1380
1390
|
var g, F;
|
|
1381
1391
|
return [
|
|
1382
1392
|
...((g = N.value) == null ? void 0 : g.filter((K) => ((K == null ? void 0 : K.length) ?? 0) > 0)) ?? [],
|
|
@@ -1384,7 +1394,7 @@ const Jt = { class: "cl-flex cl-justify-between" }, Xt = { class: "cl-w-full" },
|
|
|
1384
1394
|
].join(`
|
|
1385
1395
|
`);
|
|
1386
1396
|
});
|
|
1387
|
-
async function
|
|
1397
|
+
async function d(g) {
|
|
1388
1398
|
t.validateOn === "input" && await O(g), l("update:model-value", g);
|
|
1389
1399
|
}
|
|
1390
1400
|
async function f(g, F) {
|
|
@@ -1536,14 +1546,14 @@ const Jt = { class: "cl-flex cl-justify-between" }, Xt = { class: "cl-w-full" },
|
|
|
1536
1546
|
}, {
|
|
1537
1547
|
default: Y(() => [
|
|
1538
1548
|
g.inputType === "number" && !g.disabled && g.showArrows ? le((p(), y("div", oa, [
|
|
1539
|
-
S(v(
|
|
1549
|
+
S(v(H), {
|
|
1540
1550
|
icon: "ph:caret-up-bold",
|
|
1541
1551
|
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",
|
|
1542
1552
|
onClick: z,
|
|
1543
1553
|
onMousedown: F[4] || (F[4] = ne(() => {
|
|
1544
1554
|
}, ["prevent"]))
|
|
1545
1555
|
}),
|
|
1546
|
-
S(v(
|
|
1556
|
+
S(v(H), {
|
|
1547
1557
|
icon: "ph:caret-down-bold",
|
|
1548
1558
|
class: "cl-absolute cl-bg-link-default cl-bottom-2 cl-right-1 cl-rounded-full cl-text-sm cl-text-white hover:cl-bg-link-light hover:cl-cursor-pointer",
|
|
1549
1559
|
onClick: T,
|
|
@@ -1570,7 +1580,7 @@ const Jt = { class: "cl-flex cl-justify-between" }, Xt = { class: "cl-w-full" },
|
|
|
1570
1580
|
required: g.isRequired,
|
|
1571
1581
|
type: v(Yt)(g.inputType),
|
|
1572
1582
|
"time-zone": g.timeZone,
|
|
1573
|
-
min:
|
|
1583
|
+
min: u.value,
|
|
1574
1584
|
max: h.value,
|
|
1575
1585
|
placeholder: s.value,
|
|
1576
1586
|
"initial-date": g.initialDate,
|
|
@@ -1610,7 +1620,7 @@ var Nl = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
1610
1620
|
return a == null || (e = a.getRootNode) === null || e === void 0 ? void 0 : e.call(a);
|
|
1611
1621
|
} : function(a) {
|
|
1612
1622
|
return a == null ? void 0 : a.ownerDocument;
|
|
1613
|
-
},
|
|
1623
|
+
}, He = function a(e, l) {
|
|
1614
1624
|
var t;
|
|
1615
1625
|
l === void 0 && (l = !0);
|
|
1616
1626
|
var n = e == null || (t = e.getAttribute) === null || t === void 0 ? void 0 : t.call(e, "inert"), c = n === "" || n === "true", r = c || l && e && a(e.parentNode);
|
|
@@ -1619,14 +1629,14 @@ var Nl = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
1619
1629
|
var l, t = e == null || (l = e.getAttribute) === null || l === void 0 ? void 0 : l.call(e, "contenteditable");
|
|
1620
1630
|
return t === "" || t === "true";
|
|
1621
1631
|
}, Al = function(e, l, t) {
|
|
1622
|
-
if (
|
|
1632
|
+
if (He(e))
|
|
1623
1633
|
return [];
|
|
1624
1634
|
var n = Array.prototype.slice.apply(e.querySelectorAll(ze));
|
|
1625
1635
|
return l && Se.call(e, ze) && n.unshift(e), n = n.filter(t), n;
|
|
1626
1636
|
}, ql = function a(e, l, t) {
|
|
1627
1637
|
for (var n = [], c = Array.from(e); c.length; ) {
|
|
1628
1638
|
var r = c.shift();
|
|
1629
|
-
if (!
|
|
1639
|
+
if (!He(r, !1))
|
|
1630
1640
|
if (r.tagName === "SLOT") {
|
|
1631
1641
|
var o = r.assignedElements(), s = o.length ? o : r.children, i = a(s, !0, t);
|
|
1632
1642
|
t.flatten ? n.push.apply(n, i) : n.push({
|
|
@@ -1637,8 +1647,8 @@ var Nl = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
1637
1647
|
var m = Se.call(r, ze);
|
|
1638
1648
|
m && t.filter(r) && (l || !e.includes(r)) && n.push(r);
|
|
1639
1649
|
var k = r.shadowRoot || // check for an undisclosed shadow
|
|
1640
|
-
typeof t.getShadowRoot == "function" && t.getShadowRoot(r),
|
|
1641
|
-
if (k &&
|
|
1650
|
+
typeof t.getShadowRoot == "function" && t.getShadowRoot(r), u = !He(k, !1) && (!t.shadowRootFilter || t.shadowRootFilter(r));
|
|
1651
|
+
if (k && u) {
|
|
1642
1652
|
var h = a(k === !0 ? r.children : k.children, !0, t);
|
|
1643
1653
|
t.flatten ? n.push.apply(n, h) : n.push({
|
|
1644
1654
|
scopeParent: r,
|
|
@@ -1744,14 +1754,14 @@ var Nl = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
1744
1754
|
l = l.parentElement;
|
|
1745
1755
|
}
|
|
1746
1756
|
return !1;
|
|
1747
|
-
},
|
|
1757
|
+
}, xe = function(e, l) {
|
|
1748
1758
|
return !(l.disabled || // we must do an inert look up to filter out any elements inside an inert ancestor
|
|
1749
1759
|
// because we're limited in the type of selectors we can use in JSDom (see related
|
|
1750
1760
|
// note related to `candidateSelectors`)
|
|
1751
|
-
|
|
1761
|
+
He(l) || fa(l) || ya(l, e) || // For a details element with a summary, the summary element gets the focus
|
|
1752
1762
|
pa(l) || wa(l));
|
|
1753
1763
|
}, Xe = function(e, l) {
|
|
1754
|
-
return !(ba(l) || Oe(l) < 0 || !
|
|
1764
|
+
return !(ba(l) || Oe(l) < 0 || !xe(e, l));
|
|
1755
1765
|
}, ka = function(e) {
|
|
1756
1766
|
var l = parseInt(e.getAttribute("tabindex"), 10);
|
|
1757
1767
|
return !!(isNaN(l) || l >= 0);
|
|
@@ -1782,10 +1792,10 @@ var Nl = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
1782
1792
|
l = l || {};
|
|
1783
1793
|
var t;
|
|
1784
1794
|
return l.getShadowRoot ? t = ql([e], l.includeContainer, {
|
|
1785
|
-
filter:
|
|
1795
|
+
filter: xe.bind(null, l),
|
|
1786
1796
|
flatten: !0,
|
|
1787
1797
|
getShadowRoot: l.getShadowRoot
|
|
1788
|
-
}) : t = Al(e, l.includeContainer,
|
|
1798
|
+
}) : t = Al(e, l.includeContainer, xe.bind(null, l)), t;
|
|
1789
1799
|
}, Ne = function(e, l) {
|
|
1790
1800
|
if (l = l || {}, !e)
|
|
1791
1801
|
throw new Error("No node provided");
|
|
@@ -1793,7 +1803,7 @@ var Nl = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
1793
1803
|
}, Oa = /* @__PURE__ */ Nl.concat("iframe").join(","), Je = function(e, l) {
|
|
1794
1804
|
if (l = l || {}, !e)
|
|
1795
1805
|
throw new Error("No node provided");
|
|
1796
|
-
return Se.call(e, Oa) === !1 ? !1 :
|
|
1806
|
+
return Se.call(e, Oa) === !1 ? !1 : xe(l, e);
|
|
1797
1807
|
};
|
|
1798
1808
|
/*!
|
|
1799
1809
|
* focus-trap 7.5.2
|
|
@@ -1967,7 +1977,7 @@ var ml = {
|
|
|
1967
1977
|
if (!T)
|
|
1968
1978
|
throw new Error("Your focus-trap needs to have at least one focusable element");
|
|
1969
1979
|
return T;
|
|
1970
|
-
},
|
|
1980
|
+
}, u = function() {
|
|
1971
1981
|
if (r.containerGroups = r.containers.map(function(T) {
|
|
1972
1982
|
var w = $a(T, c.tabbableOptions), E = Ca(T, c.tabbableOptions), L = w.length > 0 ? w[0] : void 0, C = w.length > 0 ? w[w.length - 1] : void 0, D = E.find(function(g) {
|
|
1973
1983
|
return Ne(g);
|
|
@@ -2037,7 +2047,7 @@ var ml = {
|
|
|
2037
2047
|
return w || (w === !1 ? !1 : T);
|
|
2038
2048
|
}, P = function(T) {
|
|
2039
2049
|
var w = T.target, E = T.event, L = T.isBackward, C = L === void 0 ? !1 : L;
|
|
2040
|
-
w = w || Me(E),
|
|
2050
|
+
w = w || Me(E), u();
|
|
2041
2051
|
var D = null;
|
|
2042
2052
|
if (r.tabbableGroups.length > 0) {
|
|
2043
2053
|
var J = i(w, E), W = J >= 0 ? r.containerGroups[J] : void 0;
|
|
@@ -2133,7 +2143,7 @@ var ml = {
|
|
|
2133
2143
|
}, B = function(T) {
|
|
2134
2144
|
var w = Me(T);
|
|
2135
2145
|
i(w, T) >= 0 || qe(c.clickOutsideDeactivates, T) || qe(c.allowOutsideClick, T) || (T.preventDefault(), T.stopImmediatePropagation());
|
|
2136
|
-
},
|
|
2146
|
+
}, d = function() {
|
|
2137
2147
|
if (r.active)
|
|
2138
2148
|
return ml.activateTrap(n, o), r.delayInitialFocusTimer = c.delayInitialFocus ? vl(function() {
|
|
2139
2149
|
h(k());
|
|
@@ -2180,9 +2190,9 @@ var ml = {
|
|
|
2180
2190
|
if (r.active)
|
|
2181
2191
|
return this;
|
|
2182
2192
|
var w = s(T, "onActivate"), E = s(T, "onPostActivate"), L = s(T, "checkCanFocusTrap");
|
|
2183
|
-
L ||
|
|
2193
|
+
L || u(), r.active = !0, r.paused = !1, r.nodeFocusedBeforeActivation = t.activeElement, w == null || w();
|
|
2184
2194
|
var C = function() {
|
|
2185
|
-
L &&
|
|
2195
|
+
L && u(), d(), _(), E == null || E();
|
|
2186
2196
|
};
|
|
2187
2197
|
return L ? (L(r.containers.concat()).then(C, C), this) : (C(), this);
|
|
2188
2198
|
},
|
|
@@ -2214,13 +2224,13 @@ var ml = {
|
|
|
2214
2224
|
if (!r.paused || !r.active)
|
|
2215
2225
|
return this;
|
|
2216
2226
|
var w = s(T, "onUnpause"), E = s(T, "onPostUnpause");
|
|
2217
|
-
return r.paused = !1, w == null || w(),
|
|
2227
|
+
return r.paused = !1, w == null || w(), u(), d(), _(), E == null || E(), this;
|
|
2218
2228
|
},
|
|
2219
2229
|
updateContainerElements: function(T) {
|
|
2220
2230
|
var w = [].concat(T).filter(Boolean);
|
|
2221
2231
|
return r.containers = w.map(function(E) {
|
|
2222
2232
|
return typeof E == "string" ? t.querySelector(E) : E;
|
|
2223
|
-
}), r.active &&
|
|
2233
|
+
}), r.active && u(), _(), this;
|
|
2224
2234
|
}
|
|
2225
2235
|
}, o.updateContainerElements(e), o;
|
|
2226
2236
|
}, Fa = Object.defineProperty, Ma = Object.defineProperties, Va = Object.getOwnPropertyDescriptors, Ge = Object.getOwnPropertySymbols, Il = Object.prototype.hasOwnProperty, jl = Object.prototype.propertyIsEnumerable, bl = (a, e, l) => e in a ? Fa(a, e, { enumerable: !0, configurable: !0, writable: !0, value: l }) : a[e] = l, La = (a, e) => {
|
|
@@ -2241,15 +2251,15 @@ var ml = {
|
|
|
2241
2251
|
};
|
|
2242
2252
|
function Ba(a, e = {}) {
|
|
2243
2253
|
let l;
|
|
2244
|
-
const t = e, { immediate: n } = t, c = Ua(t, ["immediate"]), r = I(!1), o = I(!1), s = (
|
|
2254
|
+
const t = e, { immediate: n } = t, c = Ua(t, ["immediate"]), r = I(!1), o = I(!1), s = (u) => l && l.activate(u), i = (u) => l && l.deactivate(u), m = () => {
|
|
2245
2255
|
l && (l.pause(), o.value = !0);
|
|
2246
2256
|
}, k = () => {
|
|
2247
2257
|
l && (l.unpause(), o.value = !1);
|
|
2248
2258
|
};
|
|
2249
2259
|
return oe(
|
|
2250
2260
|
() => Zl(a),
|
|
2251
|
-
(
|
|
2252
|
-
|
|
2261
|
+
(u) => {
|
|
2262
|
+
u && (l = ja(u, Pa(La({}, c), {
|
|
2253
2263
|
onActivate() {
|
|
2254
2264
|
r.value = !0, e.onActivate && e.onActivate();
|
|
2255
2265
|
},
|
|
@@ -2268,10 +2278,10 @@ function Ba(a, e = {}) {
|
|
|
2268
2278
|
unpause: k
|
|
2269
2279
|
};
|
|
2270
2280
|
}
|
|
2271
|
-
const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypress"],
|
|
2281
|
+
const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypress"], Ha = {
|
|
2272
2282
|
key: 0,
|
|
2273
2283
|
class: "cl-mt-1 cl-opacity-60 cl-text-primary-default"
|
|
2274
|
-
},
|
|
2284
|
+
}, xa = { class: "cl-overflow-y-auto cl-overscroll-y-none cl-p-2 cl-w-full" }, Fl = /* @__PURE__ */ Q({
|
|
2275
2285
|
inheritAttrs: !1,
|
|
2276
2286
|
__name: "cl-ui-modal",
|
|
2277
2287
|
props: {
|
|
@@ -2331,7 +2341,7 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2331
2341
|
onKeypress: Ee(o, ["enter"]),
|
|
2332
2342
|
onClick: o
|
|
2333
2343
|
}, [
|
|
2334
|
-
S(v(
|
|
2344
|
+
S(v(H), { icon: "ph:x" })
|
|
2335
2345
|
], 42, _a), [
|
|
2336
2346
|
[te, !i.preventClose]
|
|
2337
2347
|
]),
|
|
@@ -2342,9 +2352,9 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2342
2352
|
}])
|
|
2343
2353
|
}, [
|
|
2344
2354
|
V(i.$slots, "title"),
|
|
2345
|
-
i.headerColour === "white" ? (p(), y("hr",
|
|
2355
|
+
i.headerColour === "white" ? (p(), y("hr", Ha)) : j("", !0)
|
|
2346
2356
|
], 2),
|
|
2347
|
-
b("div",
|
|
2357
|
+
b("div", xa, [
|
|
2348
2358
|
V(i.$slots, "default", ce(ve({ close: o })))
|
|
2349
2359
|
]),
|
|
2350
2360
|
V(i.$slots, "footer", ce(ve({ close: o })))
|
|
@@ -2384,7 +2394,7 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2384
2394
|
class: "cl-cursor-pointer cl-float-right",
|
|
2385
2395
|
onMousedown: l[0] || (l[0] = (t) => e.$emit("clear-object"))
|
|
2386
2396
|
}, [
|
|
2387
|
-
S(v(
|
|
2397
|
+
S(v(H), {
|
|
2388
2398
|
class: "cl-mt-1 cl-transition-colors hover:cl-text-link-default",
|
|
2389
2399
|
icon: "ph:x"
|
|
2390
2400
|
})
|
|
@@ -2429,7 +2439,7 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2429
2439
|
l.selectedIndex === l.index ? c.value = !0 : c.value = !1;
|
|
2430
2440
|
}
|
|
2431
2441
|
return oe(() => l.selectedIndex, () => s()), (i, m) => {
|
|
2432
|
-
var k,
|
|
2442
|
+
var k, u;
|
|
2433
2443
|
return p(), y("div", {
|
|
2434
2444
|
class: M(["cl-cursor-pointer cl-duration-75 cl-flex cl-p-1 cl-text-left cl-transition-colors", {
|
|
2435
2445
|
"cl-bg-white": c.value === !1,
|
|
@@ -2440,7 +2450,7 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2440
2450
|
onMousemove: m[0] || (m[0] = (h) => o(!0)),
|
|
2441
2451
|
onMouseleave: m[1] || (m[1] = (h) => o(!1))
|
|
2442
2452
|
}, [
|
|
2443
|
-
i.option !== null && ((k = i.option) == null ? void 0 : k.parentId) !== 0 && ((
|
|
2453
|
+
i.option !== null && ((k = i.option) == null ? void 0 : k.parentId) !== 0 && ((u = i.option) == null ? void 0 : u.parentId) !== void 0 ? (p(), y("div", Ka, q(n.value), 1)) : j("", !0),
|
|
2444
2454
|
b("div", {
|
|
2445
2455
|
class: M({
|
|
2446
2456
|
"cl-w-1/2": n.value !== "",
|
|
@@ -2448,7 +2458,7 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2448
2458
|
})
|
|
2449
2459
|
}, q(t.value), 3),
|
|
2450
2460
|
le(b("div", Qa, [
|
|
2451
|
-
S(v(
|
|
2461
|
+
S(v(H), {
|
|
2452
2462
|
class: "cl-transition-colors",
|
|
2453
2463
|
icon: "ph:plus"
|
|
2454
2464
|
})
|
|
@@ -2481,60 +2491,60 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2481
2491
|
},
|
|
2482
2492
|
setup(a, { emit: e }) {
|
|
2483
2493
|
const l = a, { t } = ie(), n = I(""), c = I(!1), r = I(-1), o = R(() => c.value ? -1 : 0), s = I();
|
|
2484
|
-
function i(
|
|
2485
|
-
(
|
|
2494
|
+
function i(d) {
|
|
2495
|
+
(d === void 0 || (d == null ? void 0 : d.code.startsWith("Arrow")) === !1 && (d == null ? void 0 : d.code.startsWith("Control")) === !1 && (d == null ? void 0 : d.code.startsWith("Shift")) === !1 && (d == null ? void 0 : d.code.startsWith("Tab")) === !1 && (d == null ? void 0 : d.code) !== "Enter") && (e("search", n.value), r.value = -2);
|
|
2486
2496
|
}
|
|
2487
|
-
function m(
|
|
2488
|
-
e("select-object",
|
|
2497
|
+
function m(d) {
|
|
2498
|
+
e("select-object", d);
|
|
2489
2499
|
}
|
|
2490
2500
|
function k() {
|
|
2491
|
-
e("create-object", n.value),
|
|
2501
|
+
e("create-object", n.value), u();
|
|
2492
2502
|
}
|
|
2493
|
-
function
|
|
2503
|
+
function u() {
|
|
2494
2504
|
e("hide-dropdown");
|
|
2495
2505
|
}
|
|
2496
|
-
function h(
|
|
2497
|
-
r.value < l.results.length - 1 ? (r.value === -2 && n.value === "" && r.value++, r.value++) : r.value =
|
|
2506
|
+
function h(d) {
|
|
2507
|
+
r.value < l.results.length - 1 ? (r.value === -2 && n.value === "" && r.value++, r.value++) : r.value = d, Z();
|
|
2498
2508
|
}
|
|
2499
|
-
function A(
|
|
2500
|
-
r.value >
|
|
2509
|
+
function A(d) {
|
|
2510
|
+
r.value > d ? r.value-- : r.value = l.results.length - 1, Z();
|
|
2501
2511
|
}
|
|
2502
2512
|
function P() {
|
|
2503
2513
|
r.value >= 0 && l.results !== void 0 ? m(l.results[r.value].id) : r.value === -1 && k();
|
|
2504
2514
|
}
|
|
2505
|
-
function U(
|
|
2506
|
-
if (
|
|
2515
|
+
function U(d) {
|
|
2516
|
+
if (d.key === "Tab" && d.shiftKey === !0) {
|
|
2507
2517
|
const f = document.getElementsByTagName("input");
|
|
2508
2518
|
let O = -1;
|
|
2509
2519
|
for (let $ = 0; $ < f.length; $++)
|
|
2510
|
-
f[$] ===
|
|
2511
|
-
O >= 0 && (f[O].focus(),
|
|
2520
|
+
f[$] === d.target && (O = $ - 1);
|
|
2521
|
+
O >= 0 && (f[O].focus(), u());
|
|
2512
2522
|
}
|
|
2513
2523
|
}
|
|
2514
2524
|
function Z() {
|
|
2515
|
-
var
|
|
2516
|
-
l.results && l.results.length > 1 && ((
|
|
2525
|
+
var d;
|
|
2526
|
+
l.results && l.results.length > 1 && ((d = s.value) == null || d.scrollTo(0, (r.value + 1) * 34 - 34 * 2));
|
|
2517
2527
|
}
|
|
2518
2528
|
function ae() {
|
|
2519
|
-
let
|
|
2520
|
-
l.results !== null && l.results.length === 1 && (
|
|
2529
|
+
let d = !1;
|
|
2530
|
+
l.results !== null && l.results.length === 1 && (d = n.value.toUpperCase().trim() === l.results[0].name.toUpperCase().trim()), c.value = l.canCreateNewObject === !0 && l.errorMessage === "" && n.value.trim() !== "" && d === !1;
|
|
2521
2531
|
}
|
|
2522
|
-
function N(
|
|
2523
|
-
r.value =
|
|
2532
|
+
function N(d) {
|
|
2533
|
+
r.value = d;
|
|
2524
2534
|
}
|
|
2525
2535
|
function B() {
|
|
2526
2536
|
l.isVisible === !0 && (n.value = "", i(), Fe(() => {
|
|
2527
|
-
var
|
|
2528
|
-
return (f = (
|
|
2537
|
+
var d, f;
|
|
2538
|
+
return (f = (d = s.value) == null ? void 0 : d.querySelector("input")) == null ? void 0 : f.focus();
|
|
2529
2539
|
}));
|
|
2530
2540
|
}
|
|
2531
2541
|
return oe(() => l.results, () => ae()), oe(() => l.errorMessage, () => ae()), oe(() => l.isVisible, () => B()), Ze(() => {
|
|
2532
|
-
var
|
|
2533
|
-
return (
|
|
2542
|
+
var d;
|
|
2543
|
+
return (d = s.value) == null ? void 0 : d.addEventListener("keydown", U);
|
|
2534
2544
|
}), tl(() => {
|
|
2535
|
-
var
|
|
2536
|
-
return (
|
|
2537
|
-
}), (
|
|
2545
|
+
var d;
|
|
2546
|
+
return (d = s.value) == null ? void 0 : d.removeEventListener("keydown", U);
|
|
2547
|
+
}), (d, f) => {
|
|
2538
2548
|
var O;
|
|
2539
2549
|
return p(), y("div", {
|
|
2540
2550
|
ref_key: "container",
|
|
@@ -2552,47 +2562,47 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2552
2562
|
"onUpdate:modelValue": f[0] || (f[0] = ($) => n.value = $),
|
|
2553
2563
|
class: "!cl-mr-0 cl-w-full",
|
|
2554
2564
|
"input-type": "text",
|
|
2555
|
-
"placeholder-text":
|
|
2565
|
+
"placeholder-text": d.searchHint,
|
|
2556
2566
|
onKeyup: i,
|
|
2557
|
-
onBlur:
|
|
2567
|
+
onBlur: u
|
|
2558
2568
|
}, null, 8, ["modelValue", "placeholder-text"]),
|
|
2559
2569
|
le(S(Ke, { class: "cl-absolute cl-ml-2 cl-mt-11" }, null, 512), [
|
|
2560
|
-
[te,
|
|
2570
|
+
[te, d.loading]
|
|
2561
2571
|
])
|
|
2562
2572
|
]),
|
|
2563
|
-
|
|
2573
|
+
d.currentObjectName !== "" ? (p(), G(Ve, {
|
|
2564
2574
|
key: 0,
|
|
2565
|
-
"show-clear-button":
|
|
2566
|
-
text:
|
|
2567
|
-
onClearObject: f[1] || (f[1] = ($) =>
|
|
2575
|
+
"show-clear-button": d.canClearSelectedObject,
|
|
2576
|
+
text: d.currentObjectName,
|
|
2577
|
+
onClearObject: f[1] || (f[1] = ($) => d.$emit("clear-object"))
|
|
2568
2578
|
}, null, 8, ["show-clear-button", "text"])) : j("", !0),
|
|
2569
|
-
|
|
2579
|
+
d.objectParentType !== "" && d.results !== void 0 && d.results.length > 0 && d.errorMessage === "" ? (p(), G(Ve, {
|
|
2570
2580
|
key: 1,
|
|
2571
|
-
text:
|
|
2572
|
-
"additional-text":
|
|
2581
|
+
text: d.objectType,
|
|
2582
|
+
"additional-text": d.objectParentType,
|
|
2573
2583
|
class: "cl-bg-grey-2 cl-mt-1"
|
|
2574
2584
|
}, null, 8, ["text", "additional-text"])) : j("", !0),
|
|
2575
|
-
|
|
2585
|
+
d.results !== null && ((O = d.results) == null ? void 0 : O.length) === 0 && n.value.trim() !== "" && d.canCreateNewObject === !1 && d.errorMessage === "" ? (p(), G(Ve, {
|
|
2576
2586
|
key: 2,
|
|
2577
2587
|
text: v(t)("comboBox.noResults", { value: n.value })
|
|
2578
2588
|
}, null, 8, ["text"])) : j("", !0),
|
|
2579
|
-
|
|
2589
|
+
d.errorMessage !== "" ? (p(), G(Ve, {
|
|
2580
2590
|
key: 3,
|
|
2581
2591
|
class: "!cl-bg-danger-light cl-border-danger-light cl-rounded cl-text-danger-dark",
|
|
2582
|
-
text: v(t)("comboBox.errorMessage", { error:
|
|
2592
|
+
text: v(t)("comboBox.errorMessage", { error: d.errorMessage })
|
|
2583
2593
|
}, null, 8, ["text"])) : j("", !0),
|
|
2584
2594
|
c.value ? (p(), G(hl, {
|
|
2585
2595
|
key: 4,
|
|
2586
2596
|
"is-create-new-option": !0,
|
|
2587
|
-
text: v(t)("comboBox.addPrompt", { value: n.value, object:
|
|
2597
|
+
text: v(t)("comboBox.addPrompt", { value: n.value, object: d.objectType }),
|
|
2588
2598
|
index: -1,
|
|
2589
2599
|
"selected-index": r.value,
|
|
2590
2600
|
class: "cl-px-2",
|
|
2591
2601
|
onCreateObject: k,
|
|
2592
2602
|
onOptionHighlighted: N
|
|
2593
2603
|
}, null, 8, ["text", "selected-index"])) : j("", !0),
|
|
2594
|
-
|
|
2595
|
-
(p(!0), y(X, null, se(
|
|
2604
|
+
d.errorMessage === "" && d.results !== null ? (p(), y("div", Ja, [
|
|
2605
|
+
(p(!0), y(X, null, se(d.results, ($, _) => (p(), G(hl, {
|
|
2596
2606
|
key: _,
|
|
2597
2607
|
option: $,
|
|
2598
2608
|
index: _,
|
|
@@ -2637,14 +2647,14 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2637
2647
|
const t = a, n = R(() => t.placeholderText ? t.placeholderText : r("comboBox.emptyHintText", { object: t.objectType })), c = R(() => t.searchHint ? t.searchHint : r("comboBox.searchHint", { object: t.objectType })), { t: r } = ie(), o = I(!1), s = R({
|
|
2638
2648
|
get: () => t.currentObject,
|
|
2639
2649
|
set: (C) => l("update:current-object", C)
|
|
2640
|
-
}), i = I(null), m = I(null), k = R(() => w()),
|
|
2650
|
+
}), i = I(null), m = I(null), k = R(() => w()), u = I(""), h = I(""), A = I(), P = I(!0), U = I(!1);
|
|
2641
2651
|
function Z(C) {
|
|
2642
2652
|
var J, W;
|
|
2643
2653
|
const D = ((J = L.value) == null ? void 0 : J.getBoundingClientRect().top) || 0;
|
|
2644
2654
|
U.value = window.innerHeight - D < 280, t.disabled || (typeof C < "u" ? o.value = C : o.value = !o.value), (W = i.value) == null || W.blur();
|
|
2645
2655
|
}
|
|
2646
2656
|
function ae(C) {
|
|
2647
|
-
|
|
2657
|
+
u.value = C, l("search", C);
|
|
2648
2658
|
}
|
|
2649
2659
|
function N(C) {
|
|
2650
2660
|
h.value = C, l("search-parent", C);
|
|
@@ -2652,7 +2662,7 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2652
2662
|
function B() {
|
|
2653
2663
|
s.value = null, Z(!1);
|
|
2654
2664
|
}
|
|
2655
|
-
function
|
|
2665
|
+
function d(C) {
|
|
2656
2666
|
const D = f(C);
|
|
2657
2667
|
s.value = D, Z(!1);
|
|
2658
2668
|
}
|
|
@@ -2670,7 +2680,7 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2670
2680
|
function O() {
|
|
2671
2681
|
var C;
|
|
2672
2682
|
A.value = {
|
|
2673
|
-
name:
|
|
2683
|
+
name: u.value,
|
|
2674
2684
|
parentId: ((C = m.value) == null ? void 0 : C.id) ?? 0
|
|
2675
2685
|
}, l("create-object", A.value);
|
|
2676
2686
|
}
|
|
@@ -2683,7 +2693,7 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2683
2693
|
function _() {
|
|
2684
2694
|
var C, D;
|
|
2685
2695
|
(C = t.objectCreatedResponse) != null && C.error ? sl({
|
|
2686
|
-
message: r("comboBox.createFailed", { name:
|
|
2696
|
+
message: r("comboBox.createFailed", { name: u.value, error: t.objectCreatedResponse.error }),
|
|
2687
2697
|
colour: "danger",
|
|
2688
2698
|
duration: 1e4
|
|
2689
2699
|
}) : (D = t.objectCreatedResponse) != null && D.id && T();
|
|
@@ -2716,9 +2726,9 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2716
2726
|
}
|
|
2717
2727
|
function E() {
|
|
2718
2728
|
let C = !0;
|
|
2719
|
-
|
|
2729
|
+
u.value === "" && (C = !1), t.objectParentType !== "" && m.value === null && (C = !1), P.value = C;
|
|
2720
2730
|
}
|
|
2721
|
-
oe(() => t.objectCreatedResponse, () => _()), oe(() => t.parentObjectCreatedResponse, () => z()), oe(() =>
|
|
2731
|
+
oe(() => t.objectCreatedResponse, () => _()), oe(() => t.parentObjectCreatedResponse, () => z()), oe(() => u.value, () => E()), oe(() => m.value, () => E()), e({
|
|
2722
2732
|
focus() {
|
|
2723
2733
|
var C;
|
|
2724
2734
|
(C = i.value) == null || C.focus();
|
|
@@ -2750,7 +2760,7 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2750
2760
|
le(b("div", lo, [
|
|
2751
2761
|
b("div", to, [
|
|
2752
2762
|
de(q(v(r)("comboBox.required")) + " ", 1),
|
|
2753
|
-
S(v(
|
|
2763
|
+
S(v(H), {
|
|
2754
2764
|
class: "cl-ml-1 cl-mt-1",
|
|
2755
2765
|
icon: "ph:warning"
|
|
2756
2766
|
})
|
|
@@ -2766,7 +2776,7 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2766
2776
|
}]),
|
|
2767
2777
|
onClick: D[3] || (D[3] = (W) => Z(!1))
|
|
2768
2778
|
}, [
|
|
2769
|
-
S(v(
|
|
2779
|
+
S(v(H), {
|
|
2770
2780
|
icon: "ph:caret-up-bold",
|
|
2771
2781
|
class: "cl-ml-[4px] cl-mt-[12px]"
|
|
2772
2782
|
})
|
|
@@ -2778,7 +2788,7 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2778
2788
|
}]),
|
|
2779
2789
|
onClick: D[2] || (D[2] = (W) => Z(!0))
|
|
2780
2790
|
}, [
|
|
2781
|
-
S(v(
|
|
2791
|
+
S(v(H), {
|
|
2782
2792
|
icon: "ph:caret-down-bold",
|
|
2783
2793
|
class: "cl-ml-[4px] cl-mt-[12px]"
|
|
2784
2794
|
})
|
|
@@ -2804,7 +2814,7 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2804
2814
|
}),
|
|
2805
2815
|
"search-hint": c.value,
|
|
2806
2816
|
onCreateObject: () => C.objectParentType === "" && C.skipObjectCreationModal === !0 ? O() : W(),
|
|
2807
|
-
onSelectObject:
|
|
2817
|
+
onSelectObject: d,
|
|
2808
2818
|
onClearObject: B,
|
|
2809
2819
|
onSearch: ae,
|
|
2810
2820
|
onHideDropdown: D[4] || (D[4] = (g) => Z(!1))
|
|
@@ -2858,8 +2868,8 @@ const za = /* @__PURE__ */ b("div", { tabindex: "0" }, null, -1), _a = ["onKeypr
|
|
|
2858
2868
|
onCreateObject: $
|
|
2859
2869
|
}, null, 8, ["current-object", "results", "loading", "object-type", "object-created-response", "can-create-new-object", "can-clear-selected-object", "error-message"])) : j("", !0),
|
|
2860
2870
|
S(me, {
|
|
2861
|
-
modelValue:
|
|
2862
|
-
"onUpdate:modelValue": D[6] || (D[6] = (W) =>
|
|
2871
|
+
modelValue: u.value,
|
|
2872
|
+
"onUpdate:modelValue": D[6] || (D[6] = (W) => u.value = W),
|
|
2863
2873
|
label: v(r)("comboBox.createProperty"),
|
|
2864
2874
|
class: "cl-mb-2 cl-pt-3 cl-w-full",
|
|
2865
2875
|
"input-type": "text"
|
|
@@ -3016,9 +3026,9 @@ const ho = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, yo = { class: "cl-gap-1
|
|
|
3016
3026
|
const e = a, { t: l, locale: t, n } = ie();
|
|
3017
3027
|
function c(o, s) {
|
|
3018
3028
|
let i;
|
|
3019
|
-
e.timeZone ? i =
|
|
3029
|
+
e.timeZone ? i = x.fromISO(o, {
|
|
3020
3030
|
locale: t.value
|
|
3021
|
-
}).setZone(e.timeZone) : i =
|
|
3031
|
+
}).setZone(e.timeZone) : i = x.fromISO(o, {
|
|
3022
3032
|
locale: t.value,
|
|
3023
3033
|
zone: "UTC"
|
|
3024
3034
|
});
|
|
@@ -3048,7 +3058,7 @@ const ho = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, yo = { class: "cl-gap-1
|
|
|
3048
3058
|
}
|
|
3049
3059
|
function r() {
|
|
3050
3060
|
let o = e.data[e.column.field];
|
|
3051
|
-
return e.column.maxLength && (o = o.trimToLength(e.column.maxLength, e.column.format !== void 0 ? e.column.format === "ellipsis" : !1)), e.searchValue && e.column.searchable && (o =
|
|
3061
|
+
return e.column.maxLength && (o = o.trimToLength(e.column.maxLength, e.column.format !== void 0 ? e.column.format === "ellipsis" : !1)), e.searchValue && e.column.searchable && (o = xl(o, e.searchValue.split(" "))), e.column.format === "wrap-text" && (o = `<span class="cl-break-words cl-whitespace-pre-wrap">${o}</span>`), o;
|
|
3052
3062
|
}
|
|
3053
3063
|
return (o, s) => {
|
|
3054
3064
|
var i;
|
|
@@ -3194,15 +3204,15 @@ const ho = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, yo = { class: "cl-gap-1
|
|
|
3194
3204
|
function c() {
|
|
3195
3205
|
Object.keys(n.value.record).length !== 0 && (e("row-edit", ge(n.value)), n.value.record = {});
|
|
3196
3206
|
}
|
|
3197
|
-
function r(
|
|
3198
|
-
n.value.index !== -1 && n.value.index !==
|
|
3207
|
+
function r(u) {
|
|
3208
|
+
n.value.index !== -1 && n.value.index !== u && c(), n.value.index = u;
|
|
3199
3209
|
}
|
|
3200
|
-
function o(
|
|
3201
|
-
r(
|
|
3210
|
+
function o(u, h) {
|
|
3211
|
+
r(u), h.field !== void 0 && (n.value.record[h.field] = h.value);
|
|
3202
3212
|
}
|
|
3203
|
-
function s(
|
|
3204
|
-
if (
|
|
3205
|
-
const { [
|
|
3213
|
+
function s(u) {
|
|
3214
|
+
if (u !== void 0) {
|
|
3215
|
+
const { [u]: h, ...A } = n.value.record;
|
|
3206
3216
|
n.value.record = {
|
|
3207
3217
|
...A
|
|
3208
3218
|
};
|
|
@@ -3210,8 +3220,8 @@ const ho = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, yo = { class: "cl-gap-1
|
|
|
3210
3220
|
}
|
|
3211
3221
|
const i = I({});
|
|
3212
3222
|
oe(() => l.data, () => {
|
|
3213
|
-
var
|
|
3214
|
-
return i.value = Object.fromEntries(((h = (
|
|
3223
|
+
var u, h;
|
|
3224
|
+
return i.value = Object.fromEntries(((h = (u = l.data) == null ? void 0 : u.results) == null ? void 0 : h.map((A, P) => [
|
|
3215
3225
|
[P],
|
|
3216
3226
|
{
|
|
3217
3227
|
count: 0,
|
|
@@ -3225,32 +3235,33 @@ const ho = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, yo = { class: "cl-gap-1
|
|
|
3225
3235
|
deep: !0,
|
|
3226
3236
|
immediate: !0
|
|
3227
3237
|
});
|
|
3228
|
-
function m(
|
|
3238
|
+
function m(u, h, A) {
|
|
3229
3239
|
const { currentTarget: P } = A;
|
|
3230
|
-
l.options.rowSelectionEnabled ? (k(P), e("row-select", h)) : (i.value[
|
|
3240
|
+
l.options.rowSelectionEnabled ? (k(P), e("row-select", h)) : (i.value[u].count++, i.value[u].target = P, i.value[u].count > 1 ? (i.value[u].reset.stop(), i.value[u].count = 0, k(P), i.value[u].target = null, e("row-select", h)) : i.value[u].reset.start());
|
|
3231
3241
|
}
|
|
3232
|
-
function k(
|
|
3233
|
-
l.options.highlightRowSelection && (
|
|
3242
|
+
function k(u) {
|
|
3243
|
+
l.options.highlightRowSelection && (u == null || u.classList.toggle("!cl-bg-link-lighter"));
|
|
3234
3244
|
}
|
|
3235
3245
|
return oe(() => l.editMode, () => {
|
|
3236
3246
|
l.editMode || (c(), n.value.index = -1);
|
|
3237
|
-
}), (
|
|
3247
|
+
}), (u, h) => {
|
|
3238
3248
|
var A;
|
|
3239
3249
|
return p(), y("tbody", null, [
|
|
3240
|
-
|
|
3250
|
+
u.data && ((A = u.data.results) != null && A.length) ? (p(!0), y(X, { key: 0 }, se(u.data.results, (P, U) => (p(), G(Ro, {
|
|
3241
3251
|
key: U,
|
|
3242
3252
|
data: P,
|
|
3243
|
-
columns:
|
|
3244
|
-
"time-zone":
|
|
3245
|
-
"search-value":
|
|
3246
|
-
"edit-mode":
|
|
3247
|
-
class: M(["cl-bg-opacity-100 cl-
|
|
3248
|
-
"cl-bg-white": U % 2 === 0 &&
|
|
3249
|
-
"cl-bg-off-white": U % 2 === 1 ||
|
|
3250
|
-
"cl-cursor-pointer
|
|
3253
|
+
columns: u.columns,
|
|
3254
|
+
"time-zone": u.timeZone,
|
|
3255
|
+
"search-value": u.searchValue,
|
|
3256
|
+
"edit-mode": u.editMode,
|
|
3257
|
+
class: M(["cl-bg-opacity-100 cl-transition-colors", {
|
|
3258
|
+
"cl-bg-white": U % 2 === 0 && u.data.totalRecords > 1,
|
|
3259
|
+
"cl-bg-off-white": U % 2 === 1 || u.data.totalRecords === 1,
|
|
3260
|
+
"cl-cursor-pointer": (u.options.highlightRowSelection || u.options.rowSelectionEnabled) && !u.editMode,
|
|
3261
|
+
"hover:cl-bg-link-lighter": u.options.rowSelectionEnabled && u.options.highlightRowSelection && !u.editMode
|
|
3251
3262
|
}]),
|
|
3252
3263
|
onClick: (Z) => {
|
|
3253
|
-
|
|
3264
|
+
u.editMode || m(U, P, Z);
|
|
3254
3265
|
},
|
|
3255
3266
|
onCellFocus: (Z) => {
|
|
3256
3267
|
r(U);
|
|
@@ -3260,24 +3271,24 @@ const ho = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, yo = { class: "cl-gap-1
|
|
|
3260
3271
|
},
|
|
3261
3272
|
onCellUndo: s
|
|
3262
3273
|
}, al({ _: 2 }, [
|
|
3263
|
-
se(
|
|
3274
|
+
se(u.$slots, (Z, ae) => ({
|
|
3264
3275
|
name: ae,
|
|
3265
3276
|
fn: Y((N) => [
|
|
3266
|
-
V(
|
|
3277
|
+
V(u.$slots, ae, fe(N, { disabled: u.loading }))
|
|
3267
3278
|
])
|
|
3268
3279
|
}))
|
|
3269
|
-
]), 1032, ["data", "columns", "time-zone", "search-value", "edit-mode", "class", "onClick", "onCellFocus", "onCellEdit"]))), 128)) :
|
|
3280
|
+
]), 1032, ["data", "columns", "time-zone", "search-value", "edit-mode", "class", "onClick", "onCellFocus", "onCellEdit"]))), 128)) : u.loading ? j("", !0) : (p(), y("tr", Do, [
|
|
3270
3281
|
b("td", {
|
|
3271
|
-
colspan:
|
|
3282
|
+
colspan: u.columns.length
|
|
3272
3283
|
}, [
|
|
3273
3284
|
b("div", jo, [
|
|
3274
3285
|
b("strong", Fo, q(v(t)("grid.noData")), 1),
|
|
3275
|
-
|
|
3286
|
+
u.request.filters.some((P) => P.filterValue !== "") ? (p(), y("div", Mo, [
|
|
3276
3287
|
b("div", Vo, q(v(t)("grid.noDataFiltersPresent")), 1),
|
|
3277
3288
|
S(be, {
|
|
3278
3289
|
size: "small",
|
|
3279
3290
|
colour: "danger",
|
|
3280
|
-
onClick: h[0] || (h[0] = ne((P) =>
|
|
3291
|
+
onClick: h[0] || (h[0] = ne((P) => u.$emit("clear-filters"), ["prevent"]))
|
|
3281
3292
|
}, {
|
|
3282
3293
|
default: Y(() => [
|
|
3283
3294
|
de(q(v(t)("grid.clearFilters")), 1)
|
|
@@ -3294,7 +3305,7 @@ const ho = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, yo = { class: "cl-gap-1
|
|
|
3294
3305
|
}), Po = {
|
|
3295
3306
|
key: 0,
|
|
3296
3307
|
class: "cl-flex cl-flex-wrap cl-justify-end cl-mt-2 cl-w-full"
|
|
3297
|
-
}, Uo = { class: "cl-bg-off-white cl-border cl-border-grey-1 cl-flex cl-items-center cl-mb-2 cl-px-3 cl-rounded-lg cl-shadow-md cl-text-sm cl-w-full lg:cl-w-auto" }, Bo = { class: "cl-text-grey-3 cl-w-max" }, zo = { class: "cl-bg-off-white cl-border cl-border-grey-1 cl-flex cl-flex-wrap cl-items-center cl-mb-2 cl-px-3 cl-py-2 cl-rounded-lg cl-shadow-md cl-text-sm cl-w-full lg:cl-ml-2 lg:cl-w-auto mb:cl-flex-nowrap" }, _o = { class: "cl-flex cl-flex-wrap cl-mb-2 cl-text-sm cl-w-full lg:cl-p-2 md:cl-mb-0 md:cl-w-auto" },
|
|
3308
|
+
}, Uo = { class: "cl-bg-off-white cl-border cl-border-grey-1 cl-flex cl-items-center cl-mb-2 cl-px-3 cl-rounded-lg cl-shadow-md cl-text-sm cl-w-full lg:cl-w-auto" }, Bo = { class: "cl-text-grey-3 cl-w-max" }, zo = { class: "cl-bg-off-white cl-border cl-border-grey-1 cl-flex cl-flex-wrap cl-items-center cl-mb-2 cl-px-3 cl-py-2 cl-rounded-lg cl-shadow-md cl-text-sm cl-w-full lg:cl-ml-2 lg:cl-w-auto mb:cl-flex-nowrap" }, _o = { class: "cl-flex cl-flex-wrap cl-mb-2 cl-text-sm cl-w-full lg:cl-p-2 md:cl-mb-0 md:cl-w-auto" }, Ho = { class: "cl-flex cl-flex-wrap cl-mb-2 cl-w-full lg:cl-mb-0 lg:cl-mr-2 lg:cl-w-auto" }, xo = { class: "cl-text-grey-3 cl-w-full lg:cl-mr-2 lg:cl-w-auto" }, Go = { class: "cl-flex cl-flex-wrap cl-text-sm mb:cl-flex-nowrap" }, Zo = { class: "cl-pr-2" }, Ko = ["onClick"], Qo = { class: "cl-flex cl-flex-wrap cl-mb-2 cl-text-sm cl-w-full lg:cl-p-2 md:cl-mb-0 md:cl-w-auto" }, Wo = { class: "cl-mb-2 cl-text-grey-3 cl-w-full lg:cl-mb-0 lg:cl-mr-2 lg:cl-w-auto" }, Yo = ["onClick"], Jo = { class: "cl-mb-2 cl-w-full lg:cl-p-2 md:cl-mb-0 md:cl-w-auto" }, Xo = { class: "cl-block cl-mb-2 cl-text-grey-3 cl-w-full lg:cl-inline-block lg:cl-mb-0 lg:cl-mr-1 lg:cl-w-auto" }, en = { class: "cl-block lg:cl-inline-block" }, ln = /* @__PURE__ */ Q({
|
|
3298
3309
|
__name: "cl-ui-grid-footer",
|
|
3299
3310
|
props: {
|
|
3300
3311
|
request: {},
|
|
@@ -3306,23 +3317,23 @@ const ho = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, yo = { class: "cl-gap-1
|
|
|
3306
3317
|
},
|
|
3307
3318
|
setup(a, { emit: e }) {
|
|
3308
3319
|
const l = a, { n: t, t: n } = ie(), c = R(() => {
|
|
3309
|
-
var
|
|
3310
|
-
return l.data !== null ? Math.ceil((((
|
|
3320
|
+
var u;
|
|
3321
|
+
return l.data !== null ? Math.ceil((((u = l.data) == null ? void 0 : u.totalRecords) ?? 0) / l.request.pageSize) : 1;
|
|
3311
3322
|
}), r = R(() => {
|
|
3312
|
-
const
|
|
3323
|
+
const u = Array.from(Array(c.value + 1).keys());
|
|
3313
3324
|
let h = [];
|
|
3314
|
-
if (
|
|
3325
|
+
if (u.shift(), u.length) {
|
|
3315
3326
|
const A = l.request.pageNumber === c.value || l.request.pageNumber === c.value - 1 ? c.value - 3 : l.request.pageNumber - 1;
|
|
3316
|
-
h =
|
|
3327
|
+
h = u.slice(A, A + 3);
|
|
3317
3328
|
}
|
|
3318
3329
|
return h;
|
|
3319
3330
|
});
|
|
3320
|
-
function o(
|
|
3331
|
+
function o(u) {
|
|
3321
3332
|
const h = ge(l.request);
|
|
3322
|
-
h.pageNumber !==
|
|
3333
|
+
h.pageNumber !== u && (h.pageNumber = Math.max(Math.min(Math.trunc(u), c.value), 1), e("update:request", h));
|
|
3323
3334
|
}
|
|
3324
|
-
function s(
|
|
3325
|
-
const h = parseInt(
|
|
3335
|
+
function s(u) {
|
|
3336
|
+
const h = parseInt(u == null ? void 0 : u.value) || 1;
|
|
3326
3337
|
o(h);
|
|
3327
3338
|
}
|
|
3328
3339
|
const i = [
|
|
@@ -3333,21 +3344,21 @@ const ho = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, yo = { class: "cl-gap-1
|
|
|
3333
3344
|
100,
|
|
3334
3345
|
200
|
|
3335
3346
|
];
|
|
3336
|
-
function m(
|
|
3347
|
+
function m(u) {
|
|
3337
3348
|
const h = ge(l.request);
|
|
3338
|
-
h.pageSize =
|
|
3349
|
+
h.pageSize = u, h.pageNumber = 1, e("update:request", h);
|
|
3339
3350
|
}
|
|
3340
3351
|
const k = ol(s, 750);
|
|
3341
|
-
return (
|
|
3352
|
+
return (u, h) => {
|
|
3342
3353
|
var A, P;
|
|
3343
|
-
return (P = (A =
|
|
3354
|
+
return (P = (A = u.data) == null ? void 0 : A.results) != null && P.length && u.request ? (p(), y("div", Po, [
|
|
3344
3355
|
b("div", Uo, [
|
|
3345
3356
|
b("span", Bo, q(v(n)("grid.jumpToPage")), 1),
|
|
3346
3357
|
S(me, {
|
|
3347
|
-
"model-value":
|
|
3358
|
+
"model-value": u.request.pageNumber,
|
|
3348
3359
|
class: "cl-ml-1 cl-mt-0.5 cl-text-sm",
|
|
3349
3360
|
"input-type": "number",
|
|
3350
|
-
disabled:
|
|
3361
|
+
disabled: u.loading,
|
|
3351
3362
|
"show-label": !1,
|
|
3352
3363
|
min: 1,
|
|
3353
3364
|
max: c.value,
|
|
@@ -3356,62 +3367,62 @@ const ho = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, yo = { class: "cl-gap-1
|
|
|
3356
3367
|
]),
|
|
3357
3368
|
b("div", zo, [
|
|
3358
3369
|
b("div", _o, [
|
|
3359
|
-
b("li",
|
|
3360
|
-
b("span",
|
|
3370
|
+
b("li", Ho, [
|
|
3371
|
+
b("span", xo, q(v(n)("grid.page")), 1)
|
|
3361
3372
|
]),
|
|
3362
3373
|
b("ul", Go, [
|
|
3363
|
-
b("li", Zo, q(v(t)(
|
|
3374
|
+
b("li", Zo, q(v(t)(u.request.pageNumber, v(ue).INTEGER)) + " / " + q(v(t)(c.value, v(ue).INTEGER)), 1),
|
|
3364
3375
|
le(b("li", {
|
|
3365
3376
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
3366
3377
|
onClick: h[1] || (h[1] = (U) => o(1))
|
|
3367
3378
|
}, [
|
|
3368
|
-
S(v(
|
|
3379
|
+
S(v(H), {
|
|
3369
3380
|
icon: "ph:caret-double-left",
|
|
3370
3381
|
size: 14
|
|
3371
3382
|
})
|
|
3372
3383
|
], 512), [
|
|
3373
|
-
[te,
|
|
3384
|
+
[te, u.request.pageNumber > 1]
|
|
3374
3385
|
]),
|
|
3375
3386
|
le(b("li", {
|
|
3376
3387
|
class: "cl-cursor-pointer cl-mt-1 lg:cl-mr-2 mr-1",
|
|
3377
|
-
onClick: h[2] || (h[2] = (U) => o(
|
|
3388
|
+
onClick: h[2] || (h[2] = (U) => o(u.request.pageNumber - 1))
|
|
3378
3389
|
}, [
|
|
3379
|
-
S(v(
|
|
3390
|
+
S(v(H), {
|
|
3380
3391
|
icon: "ph:caret-left",
|
|
3381
3392
|
size: 14
|
|
3382
3393
|
})
|
|
3383
3394
|
], 512), [
|
|
3384
|
-
[te,
|
|
3395
|
+
[te, u.request.pageNumber > 1]
|
|
3385
3396
|
]),
|
|
3386
3397
|
(p(!0), y(X, null, se(r.value, (U, Z) => (p(), y("li", {
|
|
3387
3398
|
key: Z,
|
|
3388
3399
|
class: M(["cl-cursor-pointer cl-mr-1 lg:cl-mr-2", {
|
|
3389
|
-
"cl-text-black cl-font-bold":
|
|
3390
|
-
"cl-text-grey-6":
|
|
3400
|
+
"cl-text-black cl-font-bold": u.request.pageNumber === U,
|
|
3401
|
+
"cl-text-grey-6": u.request.pageNumber !== U
|
|
3391
3402
|
}]),
|
|
3392
3403
|
onClick: (ae) => o(U)
|
|
3393
3404
|
}, q(v(t)(U, v(ue).INTEGER)), 11, Ko))), 128)),
|
|
3394
3405
|
le(b("li", {
|
|
3395
3406
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
3396
|
-
onClick: h[3] || (h[3] = (U) => o(
|
|
3407
|
+
onClick: h[3] || (h[3] = (U) => o(u.request.pageNumber + 1))
|
|
3397
3408
|
}, [
|
|
3398
|
-
S(v(
|
|
3409
|
+
S(v(H), {
|
|
3399
3410
|
icon: "ph:caret-right",
|
|
3400
3411
|
size: 14
|
|
3401
3412
|
})
|
|
3402
3413
|
], 512), [
|
|
3403
|
-
[te,
|
|
3414
|
+
[te, u.request.pageNumber < c.value]
|
|
3404
3415
|
]),
|
|
3405
3416
|
le(b("li", {
|
|
3406
3417
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
3407
3418
|
onClick: h[4] || (h[4] = (U) => o(c.value))
|
|
3408
3419
|
}, [
|
|
3409
|
-
S(v(
|
|
3420
|
+
S(v(H), {
|
|
3410
3421
|
icon: "ph:caret-double-right",
|
|
3411
3422
|
size: 14
|
|
3412
3423
|
})
|
|
3413
3424
|
], 512), [
|
|
3414
|
-
[te,
|
|
3425
|
+
[te, u.request.pageNumber < c.value]
|
|
3415
3426
|
])
|
|
3416
3427
|
])
|
|
3417
3428
|
]),
|
|
@@ -3420,15 +3431,15 @@ const ho = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, yo = { class: "cl-gap-1
|
|
|
3420
3431
|
(p(), y(X, null, se(i, (U, Z) => b("li", {
|
|
3421
3432
|
key: Z,
|
|
3422
3433
|
class: M(["cl-cursor-pointer cl-mr-1 lg:cl-mr-2", {
|
|
3423
|
-
"cl-text-black cl-font-bold":
|
|
3424
|
-
"cl-text-grey-6":
|
|
3434
|
+
"cl-text-black cl-font-bold": u.request.pageSize === U,
|
|
3435
|
+
"cl-text-grey-6": u.request.pageSize !== U
|
|
3425
3436
|
}]),
|
|
3426
3437
|
onClick: (ae) => m(U)
|
|
3427
3438
|
}, q(v(t)(U, v(ue).INTEGER)), 11, Yo)), 64))
|
|
3428
3439
|
]),
|
|
3429
3440
|
b("ul", Jo, [
|
|
3430
3441
|
b("li", Xo, q(v(n)("grid.totalRecords")), 1),
|
|
3431
|
-
b("li", en, q(v(t)(
|
|
3442
|
+
b("li", en, q(v(t)(u.data.totalRecords, v(ue).INTEGER)), 1)
|
|
3432
3443
|
])
|
|
3433
3444
|
])
|
|
3434
3445
|
])) : j("", !0);
|
|
@@ -3662,7 +3673,7 @@ const dn = {
|
|
|
3662
3673
|
}
|
|
3663
3674
|
return (o, s) => (p(), y("div", mn, [
|
|
3664
3675
|
b("div", vn, [
|
|
3665
|
-
c.value ? (p(), G(v(
|
|
3676
|
+
c.value ? (p(), G(v(H), {
|
|
3666
3677
|
key: 0,
|
|
3667
3678
|
icon: c.value.icon,
|
|
3668
3679
|
class: M(["cl-text-lg", {
|
|
@@ -3686,10 +3697,10 @@ const dn = {
|
|
|
3686
3697
|
class: M(["cl-cursor-pointer cl-px-4 cl-py-1 cl-transition-colors cl-w-full hover:cl-bg-grey-0", {
|
|
3687
3698
|
"cl-bg-primary-default cl-opacity-80": i.method === ((k = c.value) == null ? void 0 : k.method)
|
|
3688
3699
|
}]),
|
|
3689
|
-
onClick: ne((
|
|
3700
|
+
onClick: ne((u) => r(i.method), ["prevent"])
|
|
3690
3701
|
}, [
|
|
3691
3702
|
de(q(i.description) + " ", 1),
|
|
3692
|
-
S(v(
|
|
3703
|
+
S(v(H), {
|
|
3693
3704
|
icon: i.icon,
|
|
3694
3705
|
class: "cl-float-right cl-text-grey-4 cl-text-sm"
|
|
3695
3706
|
}, null, 8, ["icon"])
|
|
@@ -3735,7 +3746,7 @@ const dn = {
|
|
|
3735
3746
|
filterValue: L.filterValue
|
|
3736
3747
|
});
|
|
3737
3748
|
} else if (f.filterOperation === ee.EQUAL_OR_LESS_THAN || f.filterOperation === ee.GREATER_THAN) {
|
|
3738
|
-
let L =
|
|
3749
|
+
let L = x.fromISO(f.filterValue, {
|
|
3739
3750
|
zone: l.timeZone ?? "UTC"
|
|
3740
3751
|
});
|
|
3741
3752
|
l.column.type === "date" || l.column.type === "slot" && l.column.slotType === "date" ? L = L.minus({ days: 1 }) : L = L.minus({ minutes: 1 }), f = {
|
|
@@ -3765,7 +3776,7 @@ const dn = {
|
|
|
3765
3776
|
if (o.value) {
|
|
3766
3777
|
const $ = f, _ = ($ == null ? void 0 : $.filterMethod) && h($.filterMethod, $.filterValue, "equal"), z = ($ == null ? void 0 : $.filterMethod) && h($.filterMethod, $.filterValue, "equalorlessthan"), T = ($ == null ? void 0 : $.filterMethod) && h($.filterMethod, $.filterValue, "greaterthan");
|
|
3767
3778
|
if (_) {
|
|
3768
|
-
let w =
|
|
3779
|
+
let w = x.fromISO($.filterValue, {
|
|
3769
3780
|
zone: l.timeZone ?? "UTC"
|
|
3770
3781
|
}).set({ second: 0, millisecond: 0 });
|
|
3771
3782
|
const E = w.toISO();
|
|
@@ -3786,7 +3797,7 @@ const dn = {
|
|
|
3786
3797
|
}
|
|
3787
3798
|
];
|
|
3788
3799
|
} else if (z || T) {
|
|
3789
|
-
let w =
|
|
3800
|
+
let w = x.fromISO($.filterValue, {
|
|
3790
3801
|
zone: l.timeZone ?? "UTC"
|
|
3791
3802
|
}).set({ second: 0, millisecond: 0 });
|
|
3792
3803
|
l.column.type === "date" || l.column.type === "slot" && l.column.slotType === "date" ? w = w.plus({ days: 1 }) : w = w.plus({ minutes: 1 }), O = [
|
|
@@ -3799,9 +3810,9 @@ const dn = {
|
|
|
3799
3810
|
];
|
|
3800
3811
|
}
|
|
3801
3812
|
} else if (s.value && (f != null && f.filterValue)) {
|
|
3802
|
-
const $ = f.filterValue, _ =
|
|
3813
|
+
const $ = f.filterValue, _ = x.fromISO($.start, {
|
|
3803
3814
|
zone: l.timeZone ?? "UTC"
|
|
3804
|
-
}).toISO(), z =
|
|
3815
|
+
}).toISO(), z = x.fromISO($.end, {
|
|
3805
3816
|
zone: l.timeZone ?? "UTC"
|
|
3806
3817
|
}).toISO();
|
|
3807
3818
|
O = [
|
|
@@ -3825,10 +3836,10 @@ const dn = {
|
|
|
3825
3836
|
}
|
|
3826
3837
|
if (O && (o.value || s.value))
|
|
3827
3838
|
for (const $ of O)
|
|
3828
|
-
l.timeZone ? $.filterValue =
|
|
3839
|
+
l.timeZone ? $.filterValue = x.fromISO($.filterValue).setZone("UTC").toISO() ?? "" : $.filterValue = $.filterValue.replace("Z", "");
|
|
3829
3840
|
r.value = O;
|
|
3830
3841
|
}
|
|
3831
|
-
}),
|
|
3842
|
+
}), u = R({
|
|
3832
3843
|
get: () => k.value,
|
|
3833
3844
|
set(f) {
|
|
3834
3845
|
k.value = f;
|
|
@@ -3846,7 +3857,7 @@ const dn = {
|
|
|
3846
3857
|
let $, _ = !1;
|
|
3847
3858
|
const z = ((f == null ? void 0 : f.value) ?? O).trim();
|
|
3848
3859
|
if (k.value)
|
|
3849
|
-
_ = ((T = k.value) == null ? void 0 : T.filterValue) === z, $ = ge(
|
|
3860
|
+
_ = ((T = k.value) == null ? void 0 : T.filterValue) === z, $ = ge(u.value), $.filterValue = z;
|
|
3850
3861
|
else if (z !== "" && typeof l.column.field < "u") {
|
|
3851
3862
|
const w = c();
|
|
3852
3863
|
$ = {
|
|
@@ -3863,7 +3874,7 @@ const dn = {
|
|
|
3863
3874
|
let $, _ = (f == null ? void 0 : f.value) ?? O ?? 0;
|
|
3864
3875
|
l.column.format === ue.INTEGER ? (typeof _ == "string" && (_ = parseInt(_)), $ = Math.round(_)) : (typeof _ == "string" && (_ = parseFloat(_.replace(Z.value, "."))), $ = _), N(null, isNaN($) ? "" : $.toString());
|
|
3865
3876
|
}
|
|
3866
|
-
function
|
|
3877
|
+
function d(f) {
|
|
3867
3878
|
var _;
|
|
3868
3879
|
let O, $ = !1;
|
|
3869
3880
|
if (k.value)
|
|
@@ -3914,7 +3925,7 @@ const dn = {
|
|
|
3914
3925
|
"input-type": "dateRange",
|
|
3915
3926
|
"time-zone": f.timeZone,
|
|
3916
3927
|
"quick-date-scope": f.quickDateScope,
|
|
3917
|
-
"onUpdate:modelValue": O[2] || (O[2] = ($) =>
|
|
3928
|
+
"onUpdate:modelValue": O[2] || (O[2] = ($) => d($))
|
|
3918
3929
|
}, null, 8, ["model-value", "disabled", "time-zone", "quick-date-scope"])) : f.column.type === "number" || f.column.type === "slot" && f.column.slotType === "number" ? (p(), G(me, {
|
|
3919
3930
|
key: 3,
|
|
3920
3931
|
"model-value": A.value,
|
|
@@ -3945,8 +3956,8 @@ const dn = {
|
|
|
3945
3956
|
], 40, Cn)) : j("", !0),
|
|
3946
3957
|
s.value ? j("", !0) : (p(), G(hn, {
|
|
3947
3958
|
key: 6,
|
|
3948
|
-
filter:
|
|
3949
|
-
"onUpdate:filter": O[6] || (O[6] = ($) =>
|
|
3959
|
+
filter: u.value,
|
|
3960
|
+
"onUpdate:filter": O[6] || (O[6] = ($) => u.value = $),
|
|
3950
3961
|
loading: f.loading,
|
|
3951
3962
|
column: f.column,
|
|
3952
3963
|
"default-operation": c(),
|
|
@@ -3999,17 +4010,17 @@ const dn = {
|
|
|
3999
4010
|
class: M(["cl-text-grey-3 cl-text-sm", {
|
|
4000
4011
|
"cl-cursor-pointer": v(Le)(m) && s.loading === !1
|
|
4001
4012
|
}]),
|
|
4002
|
-
onClick: (
|
|
4013
|
+
onClick: (u) => v(Le)(m) && s.loading === !1 ? r(m.field) : () => {
|
|
4003
4014
|
}
|
|
4004
4015
|
}, [
|
|
4005
4016
|
de(q(m.caption) + " ", 1),
|
|
4006
|
-
le(S(v(
|
|
4017
|
+
le(S(v(H), {
|
|
4007
4018
|
class: "cl-inline-block",
|
|
4008
4019
|
icon: "ph:caret-up"
|
|
4009
4020
|
}, null, 512), [
|
|
4010
4021
|
[te, c(m, !0)]
|
|
4011
4022
|
]),
|
|
4012
|
-
le(S(v(
|
|
4023
|
+
le(S(v(H), {
|
|
4013
4024
|
class: "cl-inline-block",
|
|
4014
4025
|
icon: "ph:caret-down"
|
|
4015
4026
|
}, null, 512), [
|
|
@@ -4023,7 +4034,7 @@ const dn = {
|
|
|
4023
4034
|
}])
|
|
4024
4035
|
}, [
|
|
4025
4036
|
b("div", Rn, [
|
|
4026
|
-
S(v(
|
|
4037
|
+
S(v(H), {
|
|
4027
4038
|
class: "cl-text-grey-4 hover:cl-cursor-pointer hover:cl-text-link-default",
|
|
4028
4039
|
icon: "ph:x",
|
|
4029
4040
|
size: 16,
|
|
@@ -4040,18 +4051,18 @@ const dn = {
|
|
|
4040
4051
|
v(Le)(m) ? (p(), y("div", {
|
|
4041
4052
|
key: 0,
|
|
4042
4053
|
class: "cl-col-span-2 cl-gap-1 cl-span lg:cl-hidden",
|
|
4043
|
-
onClick: (
|
|
4054
|
+
onClick: (u) => s.loading === !1 ? r(m.field) : void 0
|
|
4044
4055
|
}, [
|
|
4045
4056
|
b("span", jn, q(v(t)("grid.sortBy")), 1),
|
|
4046
|
-
c(m, !0) ? (p(), G(v(
|
|
4057
|
+
c(m, !0) ? (p(), G(v(H), {
|
|
4047
4058
|
key: 0,
|
|
4048
4059
|
class: "cl-cursor-pointer cl-inline-block",
|
|
4049
4060
|
icon: "ph:caret-up"
|
|
4050
|
-
})) : c(m, !1) ? (p(), G(v(
|
|
4061
|
+
})) : c(m, !1) ? (p(), G(v(H), {
|
|
4051
4062
|
key: 1,
|
|
4052
4063
|
class: "cl-cursor-pointer cl-inline-block",
|
|
4053
4064
|
icon: "ph:caret-down"
|
|
4054
|
-
})) : (p(), G(v(
|
|
4065
|
+
})) : (p(), G(v(H), {
|
|
4055
4066
|
key: 2,
|
|
4056
4067
|
class: "cl-cursor-pointer cl-inline-block",
|
|
4057
4068
|
icon: "ph:minus"
|
|
@@ -4060,7 +4071,7 @@ const dn = {
|
|
|
4060
4071
|
S(Nn, {
|
|
4061
4072
|
class: "cl-col-span-4",
|
|
4062
4073
|
loading: s.loading,
|
|
4063
|
-
filter: n.value.filters.filter((
|
|
4074
|
+
filter: n.value.filters.filter((u) => u.filterOnColumn === m.field),
|
|
4064
4075
|
column: m,
|
|
4065
4076
|
"time-zone": s.timeZone,
|
|
4066
4077
|
"quick-date-scope": m.quickDateScope ?? null,
|
|
@@ -4076,8 +4087,7 @@ const dn = {
|
|
|
4076
4087
|
props: {
|
|
4077
4088
|
searchValue: {},
|
|
4078
4089
|
columns: {},
|
|
4079
|
-
request: {}
|
|
4080
|
-
loading: { type: Boolean }
|
|
4090
|
+
request: {}
|
|
4081
4091
|
},
|
|
4082
4092
|
emits: ["update:searchValue", "update:request"],
|
|
4083
4093
|
setup(a, { emit: e }) {
|
|
@@ -4123,7 +4133,7 @@ const dn = {
|
|
|
4123
4133
|
]);
|
|
4124
4134
|
};
|
|
4125
4135
|
}
|
|
4126
|
-
}), Ln = { class: "cl-fixed cl-flex cl-h-full cl-justify-end cl-right-0 cl-shadow-lg cl-top-0 cl-z-40" }, Pn = { class: "cl-bg-secondary-default cl-h-full cl-overflow-y-auto cl-overscroll-y-none cl-px-10 cl-py-20 cl-relative cl-text-grey-2 cl-w-80" }, Un = { class: "cl-mb-4 cl-text-2xl cl-text-off-white" }, Bn = { class: "cl-border-grey-3 cl-border-t cl-flex cl-flex-wrap cl-text-sm cl-w-full" }, zn = { class: "cl-border-b cl-border-grey-2 cl-flex cl-py-2 cl-text-sm cl-w-full" }, _n = { class: "cl-flex-1 cl-py-2" },
|
|
4136
|
+
}), Ln = { class: "cl-fixed cl-flex cl-h-full cl-justify-end cl-right-0 cl-shadow-lg cl-top-0 cl-z-40" }, Pn = { class: "cl-bg-secondary-default cl-h-full cl-overflow-y-auto cl-overscroll-y-none cl-px-10 cl-py-20 cl-relative cl-text-grey-2 cl-w-80" }, Un = { class: "cl-mb-4 cl-text-2xl cl-text-off-white" }, Bn = { class: "cl-border-grey-3 cl-border-t cl-flex cl-flex-wrap cl-text-sm cl-w-full" }, zn = { class: "cl-border-b cl-border-grey-2 cl-flex cl-py-2 cl-text-sm cl-w-full" }, _n = { class: "cl-flex-1 cl-py-2" }, Hn = { class: "cl-py-2 cl-w-1/4" }, xn = { class: "cl-py-2 cl-w-1/5" }, Gn = { class: "cl-flex-1 cl-py-2" }, Zn = { class: "cl-py-2 cl-w-1/4" }, Kn = { class: "cl-py-2 cl-text-off-white cl-w-1/5" }, Qn = { key: 1 }, Wn = /* @__PURE__ */ Q({
|
|
4127
4137
|
inheritAttrs: !1,
|
|
4128
4138
|
__name: "cl-ui-grid-view-manager",
|
|
4129
4139
|
props: {
|
|
@@ -4137,8 +4147,8 @@ const dn = {
|
|
|
4137
4147
|
m < s.length && m >= 0 && s.splice(m, 0, s.splice(i, 1)[0]);
|
|
4138
4148
|
}
|
|
4139
4149
|
function r(s, i) {
|
|
4140
|
-
const m = ge(l.columns), k = (s == null ? void 0 : s.checked) ?? !1,
|
|
4141
|
-
|
|
4150
|
+
const m = ge(l.columns), k = (s == null ? void 0 : s.checked) ?? !1, u = m.findIndex((h) => h.name === i.name);
|
|
4151
|
+
u >= 0 && (m[u].visible = k), e("update:columns", m);
|
|
4142
4152
|
}
|
|
4143
4153
|
function o(s, i) {
|
|
4144
4154
|
const m = ge(l.columns), k = i === "up" ? s + 1 : s - 1;
|
|
@@ -4161,7 +4171,7 @@ const dn = {
|
|
|
4161
4171
|
default: Y(() => [
|
|
4162
4172
|
le(b("div", Ln, [
|
|
4163
4173
|
b("div", Pn, [
|
|
4164
|
-
S(v(
|
|
4174
|
+
S(v(H), {
|
|
4165
4175
|
class: "cl-absolute cl-cursor-pointer cl-right-3 cl-text-off-white cl-top-3",
|
|
4166
4176
|
icon: "ph:x",
|
|
4167
4177
|
size: 16,
|
|
@@ -4171,8 +4181,8 @@ const dn = {
|
|
|
4171
4181
|
b("ul", Bn, [
|
|
4172
4182
|
b("li", zn, [
|
|
4173
4183
|
b("strong", _n, q(v(t)("grid.column")), 1),
|
|
4174
|
-
b("strong",
|
|
4175
|
-
b("strong",
|
|
4184
|
+
b("strong", Hn, q(v(t)("grid.visible")), 1),
|
|
4185
|
+
b("strong", xn, q(v(t)("grid.order")), 1)
|
|
4176
4186
|
]),
|
|
4177
4187
|
(p(!0), y(X, null, se(s.columns, (m, k) => (p(), y("li", {
|
|
4178
4188
|
key: k,
|
|
@@ -4183,22 +4193,22 @@ const dn = {
|
|
|
4183
4193
|
S(me, {
|
|
4184
4194
|
"model-value": m.visible === void 0 || m.visible === !0,
|
|
4185
4195
|
"input-type": "checkbox",
|
|
4186
|
-
onClick: (
|
|
4196
|
+
onClick: (u) => r(u.target, m)
|
|
4187
4197
|
}, null, 8, ["model-value", "onClick"])
|
|
4188
4198
|
]),
|
|
4189
4199
|
b("div", Kn, [
|
|
4190
4200
|
m.visible === void 0 || m.visible === !0 ? (p(), y(X, { key: 0 }, [
|
|
4191
|
-
k !== 0 ? (p(), G(v(
|
|
4201
|
+
k !== 0 ? (p(), G(v(H), {
|
|
4192
4202
|
key: 0,
|
|
4193
4203
|
class: "cl-cursor-pointer cl-inline-block cl-mr-2",
|
|
4194
4204
|
icon: "ph:arrow-left",
|
|
4195
|
-
onClick: (
|
|
4205
|
+
onClick: (u) => o(k, "down")
|
|
4196
4206
|
}, null, 8, ["onClick"])) : j("", !0),
|
|
4197
|
-
k !== s.columns.length - 1 ? (p(), G(v(
|
|
4207
|
+
k !== s.columns.length - 1 ? (p(), G(v(H), {
|
|
4198
4208
|
key: 1,
|
|
4199
4209
|
class: "cl-cursor-pointer cl-inline-block",
|
|
4200
4210
|
icon: "ph:arrow-right",
|
|
4201
|
-
onClick: (
|
|
4211
|
+
onClick: (u) => o(k, "up")
|
|
4202
4212
|
}, null, 8, ["onClick"])) : j("", !0)
|
|
4203
4213
|
], 64)) : (p(), y("em", Qn, q(v(t)("grid.hidden")), 1))
|
|
4204
4214
|
])
|
|
@@ -4234,8 +4244,8 @@ const dn = {
|
|
|
4234
4244
|
function r() {
|
|
4235
4245
|
const N = {};
|
|
4236
4246
|
window.innerWidth >= 1024 && t.value.forEach((B) => {
|
|
4237
|
-
const
|
|
4238
|
-
N[`${B.name}`] = `width: ${
|
|
4247
|
+
const d = B.width ? `${B.width}px` : "";
|
|
4248
|
+
N[`${B.name}`] = `width: ${d}; min-width: ${d};`;
|
|
4239
4249
|
}), c.value = N;
|
|
4240
4250
|
}
|
|
4241
4251
|
function o(N) {
|
|
@@ -4257,8 +4267,8 @@ const dn = {
|
|
|
4257
4267
|
deep: !0,
|
|
4258
4268
|
immediate: !0
|
|
4259
4269
|
});
|
|
4260
|
-
const k = R(() => l.data),
|
|
4261
|
-
oe(
|
|
4270
|
+
const k = R(() => l.data), u = I(!1), h = I(!1);
|
|
4271
|
+
oe(u, () => u.value ? e("edit-start") : e("edit-end"));
|
|
4262
4272
|
const A = R(() => ({
|
|
4263
4273
|
highlightRowSelection: !0,
|
|
4264
4274
|
...l.options
|
|
@@ -4270,7 +4280,7 @@ const dn = {
|
|
|
4270
4280
|
set(N) {
|
|
4271
4281
|
const B = [
|
|
4272
4282
|
...N.filters,
|
|
4273
|
-
...s.value.filters.filter((
|
|
4283
|
+
...s.value.filters.filter((d) => d.filterMethod === "andcontains" || d.filterOperation === ee.AND_CONTAINS)
|
|
4274
4284
|
];
|
|
4275
4285
|
s.value = {
|
|
4276
4286
|
...N,
|
|
@@ -4282,17 +4292,16 @@ const dn = {
|
|
|
4282
4292
|
Z.value.length > 0 ? (p(), G(Vn, {
|
|
4283
4293
|
key: 0,
|
|
4284
4294
|
"search-value": U.value,
|
|
4285
|
-
"onUpdate:searchValue": B[0] || (B[0] = (
|
|
4295
|
+
"onUpdate:searchValue": B[0] || (B[0] = (d) => U.value = d),
|
|
4286
4296
|
request: s.value,
|
|
4287
|
-
"onUpdate:request": B[1] || (B[1] = (
|
|
4288
|
-
columns: Z.value
|
|
4289
|
-
loading: N.loading
|
|
4297
|
+
"onUpdate:request": B[1] || (B[1] = (d) => s.value = d),
|
|
4298
|
+
columns: Z.value
|
|
4290
4299
|
}, {
|
|
4291
|
-
search: Y((
|
|
4292
|
-
V(N.$slots, "search", ce(ve(
|
|
4300
|
+
search: Y((d) => [
|
|
4301
|
+
V(N.$slots, "search", ce(ve(d)))
|
|
4293
4302
|
]),
|
|
4294
4303
|
_: 3
|
|
4295
|
-
}, 8, ["search-value", "request", "columns"
|
|
4304
|
+
}, 8, ["search-value", "request", "columns"])) : j("", !0),
|
|
4296
4305
|
S(Te, { name: "fade" }, {
|
|
4297
4306
|
default: Y(() => [
|
|
4298
4307
|
le(b("div", Jn, [
|
|
@@ -4304,23 +4313,23 @@ const dn = {
|
|
|
4304
4313
|
_: 1
|
|
4305
4314
|
}),
|
|
4306
4315
|
S(Co, {
|
|
4307
|
-
"edit-mode":
|
|
4308
|
-
"onUpdate:editMode": B[3] || (B[3] = (
|
|
4316
|
+
"edit-mode": u.value,
|
|
4317
|
+
"onUpdate:editMode": B[3] || (B[3] = (d) => u.value = d),
|
|
4309
4318
|
"filter-panel-open": h.value,
|
|
4310
|
-
"onUpdate:filterPanelOpen": B[4] || (B[4] = (
|
|
4319
|
+
"onUpdate:filterPanelOpen": B[4] || (B[4] = (d) => h.value = d),
|
|
4311
4320
|
columns: N.columns,
|
|
4312
4321
|
options: A.value,
|
|
4313
4322
|
request: s.value,
|
|
4314
4323
|
loading: N.loading,
|
|
4315
4324
|
onClearFilters: i
|
|
4316
4325
|
}, {
|
|
4317
|
-
"additional-grid-actions": Y((
|
|
4318
|
-
V(N.$slots, "additional-grid-actions", ce(ve(
|
|
4326
|
+
"additional-grid-actions": Y((d) => [
|
|
4327
|
+
V(N.$slots, "additional-grid-actions", ce(ve(d)))
|
|
4319
4328
|
]),
|
|
4320
4329
|
"view-manager": Y(() => [
|
|
4321
4330
|
S(Wn, {
|
|
4322
4331
|
columns: t.value,
|
|
4323
|
-
"onUpdate:columns": B[2] || (B[2] = (
|
|
4332
|
+
"onUpdate:columns": B[2] || (B[2] = (d) => t.value = d),
|
|
4324
4333
|
loading: N.loading
|
|
4325
4334
|
}, null, 8, ["columns", "loading"])
|
|
4326
4335
|
]),
|
|
@@ -4333,17 +4342,17 @@ const dn = {
|
|
|
4333
4342
|
}])
|
|
4334
4343
|
}, [
|
|
4335
4344
|
b("colgroup", er, [
|
|
4336
|
-
(p(!0), y(X, null, se(n.value, (
|
|
4345
|
+
(p(!0), y(X, null, se(n.value, (d, f) => (p(), y("col", {
|
|
4337
4346
|
key: f,
|
|
4338
|
-
style: _l(o(
|
|
4347
|
+
style: _l(o(d.name)),
|
|
4339
4348
|
span: 1
|
|
4340
4349
|
}, null, 4))), 128))
|
|
4341
4350
|
]),
|
|
4342
4351
|
S(Fn, {
|
|
4343
4352
|
request: P.value,
|
|
4344
|
-
"onUpdate:request": B[5] || (B[5] = (
|
|
4353
|
+
"onUpdate:request": B[5] || (B[5] = (d) => P.value = d),
|
|
4345
4354
|
"filter-panel-open": h.value,
|
|
4346
|
-
"onUpdate:filterPanelOpen": B[6] || (B[6] = (
|
|
4355
|
+
"onUpdate:filterPanelOpen": B[6] || (B[6] = (d) => h.value = d),
|
|
4347
4356
|
columns: n.value,
|
|
4348
4357
|
options: A.value,
|
|
4349
4358
|
loading: N.loading,
|
|
@@ -4357,12 +4366,12 @@ const dn = {
|
|
|
4357
4366
|
loading: N.loading,
|
|
4358
4367
|
"search-value": U.value,
|
|
4359
4368
|
options: A.value,
|
|
4360
|
-
"edit-mode":
|
|
4369
|
+
"edit-mode": u.value,
|
|
4361
4370
|
onClearFilters: i,
|
|
4362
|
-
onRowEdit: B[7] || (B[7] = (
|
|
4363
|
-
onRowSelect: B[8] || (B[8] = (
|
|
4371
|
+
onRowEdit: B[7] || (B[7] = (d) => N.$emit("row-edit", d)),
|
|
4372
|
+
onRowSelect: B[8] || (B[8] = (d) => N.$emit("row-select", d))
|
|
4364
4373
|
}, al({ _: 2 }, [
|
|
4365
|
-
se(N.$slots, (
|
|
4374
|
+
se(N.$slots, (d, f) => ({
|
|
4366
4375
|
name: f,
|
|
4367
4376
|
fn: Y((O) => [
|
|
4368
4377
|
V(N.$slots, f, ce(ve(O)))
|
|
@@ -4373,7 +4382,7 @@ const dn = {
|
|
|
4373
4382
|
]),
|
|
4374
4383
|
S(ln, {
|
|
4375
4384
|
request: s.value,
|
|
4376
|
-
"onUpdate:request": B[9] || (B[9] = (
|
|
4385
|
+
"onUpdate:request": B[9] || (B[9] = (d) => s.value = d),
|
|
4377
4386
|
loading: N.loading,
|
|
4378
4387
|
data: N.data
|
|
4379
4388
|
}, null, 8, ["request", "loading", "data"])
|
|
@@ -4430,7 +4439,7 @@ const dn = {
|
|
|
4430
4439
|
key: 0,
|
|
4431
4440
|
src: l.image,
|
|
4432
4441
|
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"
|
|
4433
|
-
}, null, 8, nr)) : (p(), G(v(
|
|
4442
|
+
}, null, 8, nr)) : (p(), G(v(H), {
|
|
4434
4443
|
key: 1,
|
|
4435
4444
|
class: "cl-hidden cl-m-4 cl-text-white md:cl-block",
|
|
4436
4445
|
icon: "ph:user-circle",
|
|
@@ -4447,7 +4456,7 @@ const dn = {
|
|
|
4447
4456
|
l.group ? (p(), y("div", sr, q(l.group), 1)) : j("", !0)
|
|
4448
4457
|
], 2),
|
|
4449
4458
|
b("div", ir, [
|
|
4450
|
-
S(v(
|
|
4459
|
+
S(v(H), {
|
|
4451
4460
|
class: M(["cl-transform-gpu cl-transition-transform", {
|
|
4452
4461
|
"cl-rotate-180": l.isOpen,
|
|
4453
4462
|
"cl-text-secondary-default": e.colour === "default",
|
|
@@ -4526,7 +4535,7 @@ const pr = {
|
|
|
4526
4535
|
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",
|
|
4527
4536
|
"data-localename": m.name,
|
|
4528
4537
|
"data-localecode": m.localeCode,
|
|
4529
|
-
onClick: (
|
|
4538
|
+
onClick: (u) => {
|
|
4530
4539
|
t.value = m.localeCode, o(), e("language-select", m.localeCode);
|
|
4531
4540
|
}
|
|
4532
4541
|
}, [
|
|
@@ -4565,17 +4574,17 @@ const pr = {
|
|
|
4565
4574
|
function s() {
|
|
4566
4575
|
e("update:errors", []);
|
|
4567
4576
|
}
|
|
4568
|
-
function i(k,
|
|
4577
|
+
function i(k, u) {
|
|
4569
4578
|
const h = {
|
|
4570
4579
|
valid: !0,
|
|
4571
4580
|
message: ""
|
|
4572
4581
|
};
|
|
4573
|
-
return typeof
|
|
4582
|
+
return typeof u == "string" && u.trim() === "" && (h.valid = !1), h;
|
|
4574
4583
|
}
|
|
4575
|
-
function m(k,
|
|
4584
|
+
function m(k, u) {
|
|
4576
4585
|
r.value = k;
|
|
4577
4586
|
}
|
|
4578
|
-
return (k,
|
|
4587
|
+
return (k, u) => (p(), y("div", hr, [
|
|
4579
4588
|
b("div", yr, [
|
|
4580
4589
|
V(k.$slots, "background")
|
|
4581
4590
|
]),
|
|
@@ -4594,7 +4603,7 @@ const pr = {
|
|
|
4594
4603
|
}, [
|
|
4595
4604
|
b("div", $r, [
|
|
4596
4605
|
b("div", Cr, [
|
|
4597
|
-
S(v(
|
|
4606
|
+
S(v(H), {
|
|
4598
4607
|
class: "cl-absolute cl-left-3 cl-top-2.5 cl-z-10",
|
|
4599
4608
|
icon: "ph:user",
|
|
4600
4609
|
size: 18
|
|
@@ -4602,7 +4611,7 @@ const pr = {
|
|
|
4602
4611
|
S(me, {
|
|
4603
4612
|
id: "cl-ui-login-usernameinput",
|
|
4604
4613
|
modelValue: t.value,
|
|
4605
|
-
"onUpdate:modelValue":
|
|
4614
|
+
"onUpdate:modelValue": u[0] || (u[0] = (h) => t.value = h),
|
|
4606
4615
|
modelModifiers: { trim: !0 },
|
|
4607
4616
|
class: "!cl-border-2 !cl-mb-1 cl-w-full",
|
|
4608
4617
|
"input-type": "email",
|
|
@@ -4623,31 +4632,31 @@ const pr = {
|
|
|
4623
4632
|
]),
|
|
4624
4633
|
b("div", Or, [
|
|
4625
4634
|
b("div", Sr, [
|
|
4626
|
-
S(v(
|
|
4635
|
+
S(v(H), {
|
|
4627
4636
|
class: "cl-absolute cl-left-3 cl-top-2.5 cl-z-10",
|
|
4628
4637
|
icon: "ph:lock",
|
|
4629
4638
|
size: 18
|
|
4630
4639
|
}),
|
|
4631
|
-
le(S(v(
|
|
4640
|
+
le(S(v(H), {
|
|
4632
4641
|
class: "cl-absolute cl-cursor-pointer cl-right-4 cl-top-2.5 cl-z-10",
|
|
4633
4642
|
icon: "ph:eye",
|
|
4634
4643
|
size: 18,
|
|
4635
|
-
onClick:
|
|
4644
|
+
onClick: u[1] || (u[1] = (h) => c.value = "text")
|
|
4636
4645
|
}, null, 512), [
|
|
4637
4646
|
[te, c.value === "password"]
|
|
4638
4647
|
]),
|
|
4639
|
-
le(S(v(
|
|
4648
|
+
le(S(v(H), {
|
|
4640
4649
|
class: "cl-absolute cl-cursor-pointer cl-right-4 cl-top-2.5 cl-z-10",
|
|
4641
4650
|
icon: "ph:eye-slash",
|
|
4642
4651
|
size: 18,
|
|
4643
|
-
onClick:
|
|
4652
|
+
onClick: u[2] || (u[2] = (h) => c.value = "password")
|
|
4644
4653
|
}, null, 512), [
|
|
4645
4654
|
[te, c.value === "text"]
|
|
4646
4655
|
]),
|
|
4647
4656
|
S(me, {
|
|
4648
4657
|
id: "cl-ui-login-passwordinput",
|
|
4649
4658
|
modelValue: n.value,
|
|
4650
|
-
"onUpdate:modelValue":
|
|
4659
|
+
"onUpdate:modelValue": u[3] || (u[3] = (h) => n.value = h),
|
|
4651
4660
|
class: "!cl-border-2 cl-w-full",
|
|
4652
4661
|
"input-type": c.value,
|
|
4653
4662
|
"highlight-when-valid": n.value !== void 0 && n.value !== "",
|
|
@@ -4749,13 +4758,13 @@ const pr = {
|
|
|
4749
4758
|
o.value = !o.value, s.value = !0, i();
|
|
4750
4759
|
}
|
|
4751
4760
|
const k = I();
|
|
4752
|
-
function
|
|
4761
|
+
function u() {
|
|
4753
4762
|
o.value === !1 && t.value === !0 && l.value.forEach((h) => {
|
|
4754
4763
|
h.open = !1;
|
|
4755
4764
|
});
|
|
4756
4765
|
}
|
|
4757
|
-
return nl(k,
|
|
4758
|
-
closeNavigation:
|
|
4766
|
+
return nl(k, u), e({
|
|
4767
|
+
closeNavigation: u
|
|
4759
4768
|
}), (h, A) => (p(), y("div", {
|
|
4760
4769
|
ref_key: "navElement",
|
|
4761
4770
|
ref: k,
|
|
@@ -4784,10 +4793,10 @@ const pr = {
|
|
|
4784
4793
|
class: "cl-absolute cl-cursor-pointer cl-hidden cl-right-0 cl-top-1.5 lg:cl-block",
|
|
4785
4794
|
onClick: m
|
|
4786
4795
|
}, [
|
|
4787
|
-
o.value ? (p(), G(v(
|
|
4796
|
+
o.value ? (p(), G(v(H), {
|
|
4788
4797
|
key: 1,
|
|
4789
4798
|
icon: "ph:push-pin-slash"
|
|
4790
|
-
})) : (p(), G(v(
|
|
4799
|
+
})) : (p(), G(v(H), {
|
|
4791
4800
|
key: 0,
|
|
4792
4801
|
icon: "ph:push-pin"
|
|
4793
4802
|
}))
|
|
@@ -4819,7 +4828,7 @@ const jr = /* @__PURE__ */ ke(Ir, [["__scopeId", "data-v-0958dcf5"]]), Fr = /* @
|
|
|
4819
4828
|
"cl-bg-blue-light": e.open && e.colour === "secondary"
|
|
4820
4829
|
}])
|
|
4821
4830
|
}, [
|
|
4822
|
-
S(v(
|
|
4831
|
+
S(v(H), {
|
|
4823
4832
|
class: "cl-block",
|
|
4824
4833
|
icon: e.iconValue,
|
|
4825
4834
|
width: "24"
|
|
@@ -4862,13 +4871,13 @@ function _r(a, e) {
|
|
|
4862
4871
|
])
|
|
4863
4872
|
]);
|
|
4864
4873
|
}
|
|
4865
|
-
const
|
|
4874
|
+
const Hr = /* @__PURE__ */ ke(Pr, [["render", _r]]), xr = {}, Gr = { class: "cl-cursor-pointer cl-transition-colors cl-w-full hover:cl-text-primary-darker" };
|
|
4866
4875
|
function Zr(a, e) {
|
|
4867
4876
|
return p(), y("div", Gr, [
|
|
4868
4877
|
V(a.$slots, "default")
|
|
4869
4878
|
]);
|
|
4870
4879
|
}
|
|
4871
|
-
const Kr = /* @__PURE__ */ ke(
|
|
4880
|
+
const Kr = /* @__PURE__ */ ke(xr, [["render", Zr]]), Qr = { class: "cl-w-full" }, Wr = /* @__PURE__ */ Q({
|
|
4872
4881
|
__name: "cl-ui-tab",
|
|
4873
4882
|
props: {
|
|
4874
4883
|
currentTab: { default: 0 },
|
|
@@ -4904,7 +4913,7 @@ const Kr = /* @__PURE__ */ ke(Hr, [["render", Zr]]), Qr = { class: "cl-w-full" }
|
|
|
4904
4913
|
class: "cl-bg-white cl-cursor-pointer cl-float-left cl-h-11 cl-w-4",
|
|
4905
4914
|
onClick: m[0] || (m[0] = (k) => s("left"))
|
|
4906
4915
|
}, [
|
|
4907
|
-
S(v(
|
|
4916
|
+
S(v(H), {
|
|
4908
4917
|
icon: "ph:caret-left",
|
|
4909
4918
|
class: "cl-mt-4 cl-text-secondary-default"
|
|
4910
4919
|
})
|
|
@@ -4930,7 +4939,7 @@ const Kr = /* @__PURE__ */ ke(Hr, [["render", Zr]]), Qr = { class: "cl-w-full" }
|
|
|
4930
4939
|
class: "cl-bg-white cl-bottom-12 cl-cursor-pointer cl-float-right cl-h-11 cl-relative cl-w-4",
|
|
4931
4940
|
onClick: m[1] || (m[1] = (k) => s("right"))
|
|
4932
4941
|
}, [
|
|
4933
|
-
S(v(
|
|
4942
|
+
S(v(H), {
|
|
4934
4943
|
icon: "ph:caret-right",
|
|
4935
4944
|
class: "cl-mt-4 cl-text-secondary-default"
|
|
4936
4945
|
})
|
|
@@ -5026,7 +5035,7 @@ const ls = /* @__PURE__ */ ke(Xr, [["render", es]]), ts = [
|
|
|
5026
5035
|
clUiNavigationGroup: Lr,
|
|
5027
5036
|
clUiNavigationIcon: Fr,
|
|
5028
5037
|
clUiNavigationItem: Kr,
|
|
5029
|
-
clUiNavigationSection:
|
|
5038
|
+
clUiNavigationSection: Hr,
|
|
5030
5039
|
clUiNotification: Ol,
|
|
5031
5040
|
clUiTab: Wr,
|
|
5032
5041
|
clUiTabContent: ls,
|
|
@@ -5053,7 +5062,7 @@ const ls = /* @__PURE__ */ ke(Xr, [["render", es]]), ts = [
|
|
|
5053
5062
|
tabScroll: as
|
|
5054
5063
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
5055
5064
|
const hs = (a) => {
|
|
5056
|
-
a.use(we), a.component("Icon",
|
|
5065
|
+
a.use(we), a.component("Icon", H), Object.entries(os).forEach(([
|
|
5057
5066
|
e,
|
|
5058
5067
|
l
|
|
5059
5068
|
]) => {
|
|
@@ -5089,7 +5098,7 @@ export {
|
|
|
5089
5098
|
Lr as clUiNavigationGroup,
|
|
5090
5099
|
Fr as clUiNavigationIcon,
|
|
5091
5100
|
Kr as clUiNavigationItem,
|
|
5092
|
-
|
|
5101
|
+
Hr as clUiNavigationSection,
|
|
5093
5102
|
Ol as clUiNotification,
|
|
5094
5103
|
Wr as clUiTab,
|
|
5095
5104
|
ls as clUiTabContent,
|