@citruslime/ui 3.0.1-beta.6 → 3.0.1-beta.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/citrus-lime-ui.es.js +307 -307
- package/dist/citrus-lime-ui.umd.js +2 -2
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Icon as G } from "@iconify/vue";
|
|
2
|
-
import { defineComponent as j, ref as I, openBlock as p, createElementBlock as v, renderSlot as M, normalizeProps as fe, guardReactiveProps as ve, Fragment as _, createElementVNode as f, normalizeClass as F, createVNode as D, unref as m, Transition as qe, withCtx as R, withDirectives as Q, mergeProps as ee, vShow as te, createBlock as H, Teleport as rl, renderList as ue, toDisplayString as N, createCommentVNode as z, computed as
|
|
2
|
+
import { defineComponent as j, ref as I, openBlock as p, createElementBlock as v, renderSlot as M, normalizeProps as fe, guardReactiveProps as ve, Fragment as _, createElementVNode as f, normalizeClass as F, createVNode as D, unref as m, Transition as qe, withCtx as R, withDirectives as Q, mergeProps as ee, vShow as te, createBlock as H, Teleport as rl, renderList as ue, toDisplayString as N, createCommentVNode as z, computed as C, mergeModels as me, useModel as Te, createSlots as Ve, vModelDynamic as Vl, watch as oe, toRefs as Il, withKeys as be, onMounted as Pe, onUnmounted as _e, withModifiers as ae, nextTick as Ie, resolveComponent as He, createTextVNode as pe, inject as sl, vModelCheckbox as ot, toValue as yl, watchEffect as at, useAttrs as Nl, vModelText as il, useCssVars as Rl, toHandlers as nt, pushScopeId as Ml, popScopeId as Ul, provide as wl, normalizeStyle as rt } from "vue";
|
|
3
3
|
import { generateStringId as st, highlightText as it, validateEmail as ct } from "@citruslime/utils";
|
|
4
4
|
import { onKeyDown as Qe, unrefElement as ut, tryOnScopeDispose as dt, onClickOutside as cl, useTimeoutFn as zl, useMouseInElement as pt, useFocusWithin as ft, useMediaQuery as Fl, useThrottle as mt, useElementBounding as gt, useDebounceFn as vt, useWindowSize as bt } from "@vueuse/core";
|
|
5
5
|
import { useI18n as ce, createI18n as ht } from "vue-i18n";
|
|
@@ -304,7 +304,7 @@ const Xe = /* @__PURE__ */ we(Mt, [["render", zt], ["__scopeId", "data-v-a21dc5d
|
|
|
304
304
|
errors: { default: null }
|
|
305
305
|
},
|
|
306
306
|
setup(t) {
|
|
307
|
-
const o = t, l =
|
|
307
|
+
const o = t, l = C(() => Object.keys(o.errors ?? []).length > 0);
|
|
308
308
|
return (e, n) => (p(), v("div", Wt, [
|
|
309
309
|
f("div", Zt, [
|
|
310
310
|
f("div", Gt, [
|
|
@@ -555,10 +555,10 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
555
555
|
},
|
|
556
556
|
emits: ["create-object", "select-object", "option-highlighted"],
|
|
557
557
|
setup(t, { emit: o }) {
|
|
558
|
-
const l = t, e = o, n =
|
|
558
|
+
const l = t, e = o, n = C(() => {
|
|
559
559
|
var u;
|
|
560
560
|
return ((u = l.option) == null ? void 0 : u.name) ?? l.text;
|
|
561
|
-
}), a =
|
|
561
|
+
}), a = C(() => {
|
|
562
562
|
var u;
|
|
563
563
|
return ((u = l.option) == null ? void 0 : u.parentName) ?? "";
|
|
564
564
|
}), d = I(!1);
|
|
@@ -573,7 +573,7 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
573
573
|
l.selectedIndex === l.index ? d.value = !0 : d.value = !1;
|
|
574
574
|
}
|
|
575
575
|
return oe(() => l.selectedIndex, () => i()), (u, c) => {
|
|
576
|
-
var g,
|
|
576
|
+
var g, b;
|
|
577
577
|
return p(), v("div", {
|
|
578
578
|
class: F(["cl-cursor-pointer cl-duration-75 cl-flex cl-p-1 cl-text-left cl-transition-colors", {
|
|
579
579
|
"cl-bg-white": d.value === !1,
|
|
@@ -581,10 +581,10 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
581
581
|
"cl-bg-primary-default cl-text-black cl-opacity-90": d.value && u.isCreateNewOption
|
|
582
582
|
}]),
|
|
583
583
|
onMousedown: s,
|
|
584
|
-
onMousemove: c[0] || (c[0] = (
|
|
585
|
-
onMouseleave: c[1] || (c[1] = (
|
|
584
|
+
onMousemove: c[0] || (c[0] = (h) => r(!0)),
|
|
585
|
+
onMouseleave: c[1] || (c[1] = (h) => r(!1))
|
|
586
586
|
}, [
|
|
587
|
-
u.option !== null && ((g = u.option) == null ? void 0 : g.parentId) !== 0 && ((
|
|
587
|
+
u.option !== null && ((g = u.option) == null ? void 0 : g.parentId) !== 0 && ((b = u.option) == null ? void 0 : b.parentId) !== void 0 ? (p(), v("div", ro, N(a.value), 1)) : z("", !0),
|
|
588
588
|
f("div", {
|
|
589
589
|
class: F({
|
|
590
590
|
"cl-w-1/2": a.value !== "",
|
|
@@ -621,7 +621,7 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
621
621
|
},
|
|
622
622
|
emits: ["clear-object", "create-object", "select-object", "search", "hide-dropdown"],
|
|
623
623
|
setup(t, { emit: o }) {
|
|
624
|
-
const l = t, e = o, { t: n } = ce(), a = I(""), d = I(!1), s = I(-1), r =
|
|
624
|
+
const l = t, e = o, { t: n } = ce(), a = I(""), d = I(!1), s = I(-1), r = C(() => d.value ? -1 : 0), i = I();
|
|
625
625
|
function u(E) {
|
|
626
626
|
(E === void 0 || E.code && E.code.startsWith("Arrow") === !1 && E.code.startsWith("Control") === !1 && E.code.startsWith("Shift") === !1 && E.code.startsWith("Tab") === !1 && E.code !== "Enter") && (e("search", a.value), s.value = -2);
|
|
627
627
|
}
|
|
@@ -629,12 +629,12 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
629
629
|
e("select-object", E);
|
|
630
630
|
}
|
|
631
631
|
function g() {
|
|
632
|
-
e("create-object", a.value),
|
|
632
|
+
e("create-object", a.value), b();
|
|
633
633
|
}
|
|
634
|
-
function
|
|
634
|
+
function b() {
|
|
635
635
|
e("hide-dropdown");
|
|
636
636
|
}
|
|
637
|
-
function
|
|
637
|
+
function h(E) {
|
|
638
638
|
s.value < l.results.length - 1 ? (s.value === -2 && a.value === "" && s.value++, s.value++) : s.value = E, L();
|
|
639
639
|
}
|
|
640
640
|
function $(E) {
|
|
@@ -643,13 +643,13 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
643
643
|
function q() {
|
|
644
644
|
s.value >= 0 && l.results !== void 0 ? c(l.results[s.value].id) : s.value === -1 && g();
|
|
645
645
|
}
|
|
646
|
-
function
|
|
646
|
+
function T(E) {
|
|
647
647
|
if (E.key === "Tab" && E.shiftKey === !0) {
|
|
648
648
|
const Y = document.getElementsByTagName("input");
|
|
649
649
|
let ne = -1;
|
|
650
650
|
for (let w = 0; w < Y.length; w++)
|
|
651
651
|
Y[w] === E.target && (ne = w - 1);
|
|
652
|
-
ne >= 0 && (Y[ne].focus(),
|
|
652
|
+
ne >= 0 && (Y[ne].focus(), b());
|
|
653
653
|
}
|
|
654
654
|
}
|
|
655
655
|
function L() {
|
|
@@ -671,10 +671,10 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
671
671
|
}
|
|
672
672
|
return oe(() => l.results, () => S()), oe(() => l.errorMessage, () => S()), oe(() => l.isVisible, () => x()), Pe(() => {
|
|
673
673
|
var E;
|
|
674
|
-
return (E = i.value) == null ? void 0 : E.addEventListener("keydown",
|
|
674
|
+
return (E = i.value) == null ? void 0 : E.addEventListener("keydown", T);
|
|
675
675
|
}), _e(() => {
|
|
676
676
|
var E;
|
|
677
|
-
return (E = i.value) == null ? void 0 : E.removeEventListener("keydown",
|
|
677
|
+
return (E = i.value) == null ? void 0 : E.removeEventListener("keydown", T);
|
|
678
678
|
}), (E, Y) => {
|
|
679
679
|
var ne;
|
|
680
680
|
return p(), v("div", {
|
|
@@ -685,7 +685,7 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
685
685
|
}]),
|
|
686
686
|
onKeydown: [
|
|
687
687
|
Y[2] || (Y[2] = be(ae((w) => $(r.value), ["prevent", "stop"]), ["up"])),
|
|
688
|
-
Y[3] || (Y[3] = be(ae((w) =>
|
|
688
|
+
Y[3] || (Y[3] = be(ae((w) => h(r.value), ["prevent", "stop"]), ["down"]))
|
|
689
689
|
],
|
|
690
690
|
onKeyup: be(ae(q, ["prevent", "stop"]), ["enter"])
|
|
691
691
|
}, [
|
|
@@ -702,7 +702,7 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
702
702
|
placeholder: E.searchHint,
|
|
703
703
|
type: "search",
|
|
704
704
|
onKeyup: u,
|
|
705
|
-
onBlur:
|
|
705
|
+
onBlur: b
|
|
706
706
|
}, {
|
|
707
707
|
default: R(() => [
|
|
708
708
|
fo
|
|
@@ -778,11 +778,11 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
778
778
|
},
|
|
779
779
|
emits: ["focus", "search", "search-parent", "create-object", "create-parent-object", "update:current-object"],
|
|
780
780
|
setup(t, { expose: o, emit: l }) {
|
|
781
|
-
const e = t, n = l, a =
|
|
781
|
+
const e = t, n = l, a = C(() => e.placeholderText ? e.placeholderText : s("comboBox.emptyHintText", { object: e.objectType })), d = C(() => e.searchHint ? e.searchHint : s("comboBox.searchHint", { object: e.objectType })), { t: s } = ce(), r = I(!1), i = C({
|
|
782
782
|
get: () => e.currentObject,
|
|
783
783
|
set: (O) => n("update:current-object", O)
|
|
784
|
-
}), u = I(null), c =
|
|
785
|
-
function
|
|
784
|
+
}), u = I(null), c = C(() => U()), g = I(""), b = I(""), h = I(), $ = I(!0), q = I(!1);
|
|
785
|
+
function T(O) {
|
|
786
786
|
var J;
|
|
787
787
|
const Z = ((J = re.value) == null ? void 0 : J.getBoundingClientRect().top) || 0;
|
|
788
788
|
q.value = window.innerHeight - Z < 280, e.disabled || (typeof O < "u" ? r.value = O : r.value = !r.value);
|
|
@@ -791,14 +791,14 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
791
791
|
g.value = O, n("search", O);
|
|
792
792
|
}
|
|
793
793
|
function S(O) {
|
|
794
|
-
|
|
794
|
+
b.value = O, n("search-parent", O);
|
|
795
795
|
}
|
|
796
796
|
function P() {
|
|
797
|
-
i.value = null,
|
|
797
|
+
i.value = null, T(!1);
|
|
798
798
|
}
|
|
799
799
|
function x(O) {
|
|
800
800
|
const Z = E(O ?? 0);
|
|
801
|
-
i.value = Z,
|
|
801
|
+
i.value = Z, T(!1);
|
|
802
802
|
}
|
|
803
803
|
function E(O) {
|
|
804
804
|
let Z = null;
|
|
@@ -813,16 +813,16 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
813
813
|
}
|
|
814
814
|
function Y() {
|
|
815
815
|
var O;
|
|
816
|
-
|
|
816
|
+
h.value = {
|
|
817
817
|
name: g.value,
|
|
818
818
|
parentId: ((O = u.value) == null ? void 0 : O.id) ?? 0
|
|
819
|
-
}, n("create-object",
|
|
819
|
+
}, n("create-object", h.value);
|
|
820
820
|
}
|
|
821
821
|
function ne() {
|
|
822
|
-
|
|
823
|
-
name:
|
|
822
|
+
h.value = {
|
|
823
|
+
name: b.value,
|
|
824
824
|
parentId: 0
|
|
825
|
-
}, n("create-parent-object",
|
|
825
|
+
}, n("create-parent-object", h.value);
|
|
826
826
|
}
|
|
827
827
|
function w() {
|
|
828
828
|
var O, Z;
|
|
@@ -870,9 +870,9 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
870
870
|
}
|
|
871
871
|
oe(() => e.objectCreatedResponse, () => w()), oe(() => e.parentObjectCreatedResponse, () => V()), oe(() => g.value, () => A()), oe(() => u.value, () => A());
|
|
872
872
|
const re = I();
|
|
873
|
-
return cl(re, () => r.value ?
|
|
873
|
+
return cl(re, () => r.value ? T(!1) : ""), o({
|
|
874
874
|
focus() {
|
|
875
|
-
|
|
875
|
+
T(), n("focus");
|
|
876
876
|
}
|
|
877
877
|
}), (O, Z) => {
|
|
878
878
|
const J = He("cl-ui-combo-box", !0);
|
|
@@ -893,7 +893,7 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
893
893
|
placeholder: a.value,
|
|
894
894
|
disabled: O.disabled,
|
|
895
895
|
onFocus: Z[1] || (Z[1] = (se) => {
|
|
896
|
-
|
|
896
|
+
T(), O.$emit("focus");
|
|
897
897
|
})
|
|
898
898
|
}, {
|
|
899
899
|
default: R(() => [
|
|
@@ -920,7 +920,7 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
920
920
|
"cl-cursor-pointer hover:cl-bg-link-light hover:cl-opacity-90 hover:cl-text-white cl-bg-white": O.disabled === !1
|
|
921
921
|
}]),
|
|
922
922
|
disabled: O.disabled,
|
|
923
|
-
onClick: Z[3] || (Z[3] = (se) =>
|
|
923
|
+
onClick: Z[3] || (Z[3] = (se) => T(!1))
|
|
924
924
|
}, [
|
|
925
925
|
D(m(G), {
|
|
926
926
|
icon: "ph:caret-up-bold",
|
|
@@ -933,7 +933,7 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
933
933
|
"cl-cursor-pointer hover:cl-bg-link-light hover:cl-opacity-90 hover:cl-text-white cl-bg-white": O.disabled === !1
|
|
934
934
|
}]),
|
|
935
935
|
disabled: O.disabled,
|
|
936
|
-
onClick: Z[2] || (Z[2] = (se) =>
|
|
936
|
+
onClick: Z[2] || (Z[2] = (se) => T(!0))
|
|
937
937
|
}, [
|
|
938
938
|
D(m(G), {
|
|
939
939
|
icon: "ph:caret-down-bold",
|
|
@@ -964,7 +964,7 @@ const lo = /* @__PURE__ */ f("div", { tabindex: "0" }, null, -1), to = {
|
|
|
964
964
|
onSelectObject: x,
|
|
965
965
|
onClearObject: P,
|
|
966
966
|
onSearch: L,
|
|
967
|
-
onHideDropdown: Z[4] || (Z[4] = (ie) =>
|
|
967
|
+
onHideDropdown: Z[4] || (Z[4] = (ie) => T(!1))
|
|
968
968
|
}, 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"]), [
|
|
969
969
|
[te, r.value]
|
|
970
970
|
])
|
|
@@ -1090,7 +1090,7 @@ const zo = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Fo = { class: "cl-gap-1
|
|
|
1090
1090
|
},
|
|
1091
1091
|
emits: ["update:edit-mode", "update:filterPanelOpen", "clear-filters"],
|
|
1092
1092
|
setup(t) {
|
|
1093
|
-
const o = t, { t: l } = ce(), e =
|
|
1093
|
+
const o = t, { t: l } = ce(), e = C(() => o.request.filters.some((a) => a.filterValue !== "")), n = sl("cl-ui-grid-id") ?? "cl-ui-grid-filter";
|
|
1094
1094
|
return (a, d) => (p(), v(_, null, [
|
|
1095
1095
|
f("div", zo, [
|
|
1096
1096
|
f("strong", null, N(m(l)("grid.gridTools")), 1)
|
|
@@ -1475,13 +1475,13 @@ function Tl(t, o, l) {
|
|
|
1475
1475
|
const a = [
|
|
1476
1476
|
".",
|
|
1477
1477
|
","
|
|
1478
|
-
], d = Re(n, 1, "currency", "unit"), s = Re(n, 1, "percentSign"), r = Re(n, 1, "plusSign"), i = Re(n, -1, "minusSign"), u = Re(n, -10000.11111, "literal", "unknown"), c = i.some((
|
|
1479
|
-
let
|
|
1480
|
-
if (a.some((
|
|
1478
|
+
], d = Re(n, 1, "currency", "unit"), s = Re(n, 1, "percentSign"), r = Re(n, 1, "plusSign"), i = Re(n, -1, "minusSign"), u = Re(n, -10000.11111, "literal", "unknown"), c = i.some((T) => t.startsWith(T) || t.endsWith(T)) || t.startsWith("(") && t.endsWith(")"), g = s.some((T) => t.startsWith(T) || t.endsWith(T)), b = (c ? -1 : 1) * (g ? 0.01 : 1);
|
|
1479
|
+
let h = t;
|
|
1480
|
+
if (a.some((T) => t.includes(T)) && q())
|
|
1481
1481
|
return NaN;
|
|
1482
|
-
return
|
|
1482
|
+
return h = Oe(h, a, "."), h = Oe(h, d, ""), h = Oe(h, s, ""), h = Oe(h, r, ""), h = Oe(h, i, ""), h = Oe(h, u, ""), +h * b;
|
|
1483
1483
|
function q() {
|
|
1484
|
-
return a.some((
|
|
1484
|
+
return a.some((T) => h.indexOf(T) !== h.lastIndexOf(T));
|
|
1485
1485
|
}
|
|
1486
1486
|
}
|
|
1487
1487
|
function Oe(t, o, l, e = t.length + 1, n = !1) {
|
|
@@ -1775,7 +1775,7 @@ const na = {
|
|
|
1775
1775
|
},
|
|
1776
1776
|
emits: ["edit", "focus", "undo"],
|
|
1777
1777
|
setup(t, { emit: o }) {
|
|
1778
|
-
const l = t, e = o, { t: n } = ce(), a = I(ge(l.data)), d =
|
|
1778
|
+
const l = t, e = o, { t: n } = ce(), a = I(ge(l.data)), d = C(() => l.column.field !== void 0 && a.value[l.column.field] !== l.data[l.column.field]), s = C(() => {
|
|
1779
1779
|
var r;
|
|
1780
1780
|
return ((r = l.column.listEntries) == null ? void 0 : r.map((i, u) => ({
|
|
1781
1781
|
id: u,
|
|
@@ -1886,15 +1886,15 @@ const na = {
|
|
|
1886
1886
|
function d() {
|
|
1887
1887
|
Object.keys(a.value.record).length !== 0 && (e("row-edit", ge(a.value)), a.value.record = {});
|
|
1888
1888
|
}
|
|
1889
|
-
function s(
|
|
1890
|
-
a.value.index !== -1 && a.value.index !==
|
|
1889
|
+
function s(b) {
|
|
1890
|
+
a.value.index !== -1 && a.value.index !== b && d(), a.value.index = b;
|
|
1891
1891
|
}
|
|
1892
|
-
function r(
|
|
1893
|
-
s(
|
|
1892
|
+
function r(b, h) {
|
|
1893
|
+
s(b), h.field !== void 0 && (a.value.record[h.field] = h.value);
|
|
1894
1894
|
}
|
|
1895
|
-
function i(
|
|
1896
|
-
if (
|
|
1897
|
-
const { [
|
|
1895
|
+
function i(b) {
|
|
1896
|
+
if (b !== void 0) {
|
|
1897
|
+
const { [b]: h, ...$ } = a.value.record;
|
|
1898
1898
|
a.value.record = {
|
|
1899
1899
|
...$
|
|
1900
1900
|
}, e("row-edit-cancelled", ge(a.value));
|
|
@@ -1902,8 +1902,8 @@ const na = {
|
|
|
1902
1902
|
}
|
|
1903
1903
|
const u = I({});
|
|
1904
1904
|
oe(() => l.data, () => {
|
|
1905
|
-
var
|
|
1906
|
-
return u.value = Object.fromEntries(((
|
|
1905
|
+
var b, h;
|
|
1906
|
+
return u.value = Object.fromEntries(((h = (b = l.data) == null ? void 0 : b.results) == null ? void 0 : h.map(($, q) => [
|
|
1907
1907
|
[q],
|
|
1908
1908
|
{
|
|
1909
1909
|
count: 0,
|
|
@@ -1917,60 +1917,60 @@ const na = {
|
|
|
1917
1917
|
deep: !0,
|
|
1918
1918
|
immediate: !0
|
|
1919
1919
|
});
|
|
1920
|
-
function c(
|
|
1920
|
+
function c(b, h, $) {
|
|
1921
1921
|
const { currentTarget: q } = $;
|
|
1922
|
-
l.options.rowSelectionEnabled ? (g(q), e("row-select",
|
|
1922
|
+
l.options.rowSelectionEnabled ? (g(q), e("row-select", h)) : (u.value[b].count++, u.value[b].target = q, u.value[b].count > 1 ? (u.value[b].reset.stop(), u.value[b].count = 0, g(q), u.value[b].target = null, e("row-select", h)) : u.value[b].reset.start());
|
|
1923
1923
|
}
|
|
1924
|
-
function g(
|
|
1925
|
-
l.options.highlightRowSelection === !0 && (
|
|
1924
|
+
function g(b) {
|
|
1925
|
+
l.options.highlightRowSelection === !0 && (b == null || b.classList.toggle("!cl-bg-link-lighter"));
|
|
1926
1926
|
}
|
|
1927
1927
|
return oe(() => l.editMode, () => {
|
|
1928
1928
|
l.editMode || (d(), a.value.index = -1);
|
|
1929
|
-
}), (
|
|
1929
|
+
}), (b, h) => {
|
|
1930
1930
|
var $;
|
|
1931
1931
|
return p(), v("tbody", null, [
|
|
1932
|
-
|
|
1933
|
-
key:
|
|
1932
|
+
b.data && (($ = b.data.results) != null && $.length) ? (p(!0), v(_, { key: 0 }, ue(b.data.results, (q, T) => (p(), H(da, {
|
|
1933
|
+
key: T,
|
|
1934
1934
|
data: q,
|
|
1935
|
-
columns:
|
|
1936
|
-
"time-zone":
|
|
1937
|
-
"search-value":
|
|
1938
|
-
"edit-mode":
|
|
1935
|
+
columns: b.columns,
|
|
1936
|
+
"time-zone": b.timeZone,
|
|
1937
|
+
"search-value": b.searchValue,
|
|
1938
|
+
"edit-mode": b.editMode,
|
|
1939
1939
|
class: F(["cl-bg-opacity-100 cl-transition-colors", {
|
|
1940
|
-
"cl-bg-white":
|
|
1941
|
-
"cl-bg-off-white":
|
|
1942
|
-
"cl-cursor-pointer": (
|
|
1943
|
-
"hover:cl-bg-link-lighter":
|
|
1940
|
+
"cl-bg-white": T % 2 === 0 && b.data.totalRecords > 1,
|
|
1941
|
+
"cl-bg-off-white": T % 2 === 1 || b.data.totalRecords === 1,
|
|
1942
|
+
"cl-cursor-pointer": (b.options.highlightRowSelection || b.options.rowSelectionEnabled) && !b.editMode,
|
|
1943
|
+
"hover:cl-bg-link-lighter": b.options.rowSelectionEnabled && b.options.highlightRowSelection === !0 && !b.editMode
|
|
1944
1944
|
}]),
|
|
1945
1945
|
onClick: (L) => {
|
|
1946
|
-
|
|
1946
|
+
b.editMode || c(T, q, L);
|
|
1947
1947
|
},
|
|
1948
1948
|
onCellFocus: (L) => {
|
|
1949
|
-
s(
|
|
1949
|
+
s(T);
|
|
1950
1950
|
},
|
|
1951
1951
|
onCellEdit: (L) => {
|
|
1952
|
-
r(
|
|
1952
|
+
r(T, L);
|
|
1953
1953
|
},
|
|
1954
1954
|
onCellUndo: i
|
|
1955
1955
|
}, Ve({ _: 2 }, [
|
|
1956
|
-
ue(
|
|
1956
|
+
ue(b.$slots, (L, S) => ({
|
|
1957
1957
|
name: S,
|
|
1958
1958
|
fn: R((P) => [
|
|
1959
|
-
M(
|
|
1959
|
+
M(b.$slots, S, ee(P, { disabled: b.loading }))
|
|
1960
1960
|
])
|
|
1961
1961
|
}))
|
|
1962
|
-
]), 1032, ["data", "columns", "time-zone", "search-value", "edit-mode", "class", "onClick", "onCellFocus", "onCellEdit"]))), 128)) :
|
|
1962
|
+
]), 1032, ["data", "columns", "time-zone", "search-value", "edit-mode", "class", "onClick", "onCellFocus", "onCellEdit"]))), 128)) : b.loading ? z("", !0) : (p(), v("tr", pa, [
|
|
1963
1963
|
f("td", {
|
|
1964
|
-
colspan:
|
|
1964
|
+
colspan: b.columns.length
|
|
1965
1965
|
}, [
|
|
1966
1966
|
f("div", ma, [
|
|
1967
1967
|
f("strong", ga, N(m(n)("grid.noData")), 1),
|
|
1968
|
-
|
|
1968
|
+
b.request.filters.some((q) => q.filterValue !== "") ? (p(), v("div", va, [
|
|
1969
1969
|
f("div", ba, N(m(n)("grid.noDataFiltersPresent")), 1),
|
|
1970
1970
|
D(ye, {
|
|
1971
1971
|
size: "small",
|
|
1972
1972
|
colour: "danger",
|
|
1973
|
-
onClick:
|
|
1973
|
+
onClick: h[0] || (h[0] = ae((q) => b.$emit("clear-filters"), ["prevent"]))
|
|
1974
1974
|
}, {
|
|
1975
1975
|
default: R(() => [
|
|
1976
1976
|
pe(N(m(n)("grid.clearFilters")), 1)
|
|
@@ -2006,29 +2006,29 @@ const na = {
|
|
|
2006
2006
|
}),
|
|
2007
2007
|
emits: /* @__PURE__ */ me(["focus", "blur", "keySinglePress"], ["update:modelValue"]),
|
|
2008
2008
|
setup(t, { expose: o, emit: l }) {
|
|
2009
|
-
const e = t, n = Te(t, "modelValue"), a = l, d = I(0), s = I(), r = I(), { isOutside: i } = pt(r), { focused: u } = ft(s), c =
|
|
2009
|
+
const e = t, n = Te(t, "modelValue"), a = l, d = I(0), s = I(), r = I(), { isOutside: i } = pt(r), { focused: u } = ft(s), c = C(() => e.showArrows && i.value === !1);
|
|
2010
2010
|
oe(u, () => {
|
|
2011
|
-
u.value ? (
|
|
2011
|
+
u.value ? (T.value = Xo(S.value, {
|
|
2012
2012
|
locale: e.locale
|
|
2013
|
-
}), a("focus")) : (x(S.value, !0),
|
|
2013
|
+
}), a("focus")) : (x(S.value, !0), T.value = void 0, a("blur"));
|
|
2014
2014
|
});
|
|
2015
|
-
const g =
|
|
2015
|
+
const g = C(() => ({
|
|
2016
2016
|
style: e.format === le.CURRENCY ? "currency" : void 0,
|
|
2017
2017
|
currency: e.currency || void 0,
|
|
2018
2018
|
currencyDisplay: "narrowSymbol",
|
|
2019
2019
|
minimumFractionDigits: e.precision,
|
|
2020
2020
|
maximumFractionDigits: e.precision
|
|
2021
|
-
})),
|
|
2021
|
+
})), b = C(() => e.format ? pl(e.format, {
|
|
2022
2022
|
locale: e.locale,
|
|
2023
2023
|
additionalOptions: g.value
|
|
2024
|
-
}) : g.value),
|
|
2025
|
-
oe(n, () =>
|
|
2026
|
-
const L =
|
|
2027
|
-
get: () =>
|
|
2028
|
-
set: (w) =>
|
|
2029
|
-
}), S =
|
|
2030
|
-
get: () =>
|
|
2031
|
-
set: (w) =>
|
|
2024
|
+
}) : g.value), h = C(() => Math.pow(10, b.value.maximumFractionDigits ?? 0)), $ = C(() => Math.pow(10, e.format === le.PERCENTAGE ? 2 : 0)), q = C(() => h.value * $.value), T = I(void 0);
|
|
2025
|
+
oe(n, () => T.value = void 0);
|
|
2026
|
+
const L = C({
|
|
2027
|
+
get: () => T.value ? Y(T.value) : n.value,
|
|
2028
|
+
set: (w) => T.value = E(w)
|
|
2029
|
+
}), S = C({
|
|
2030
|
+
get: () => T.value ?? E(n.value),
|
|
2031
|
+
set: (w) => T.value = w
|
|
2032
2032
|
});
|
|
2033
2033
|
function P(w) {
|
|
2034
2034
|
return w = e.min === null ? w : Math.max(e.min, w), w = e.max === null ? w : Math.min(e.max, w), w;
|
|
@@ -2151,10 +2151,10 @@ const na = {
|
|
|
2151
2151
|
},
|
|
2152
2152
|
emits: ["update:request"],
|
|
2153
2153
|
setup(t, { emit: o }) {
|
|
2154
|
-
const l = t, e = o, { t: n } = ce(), a =
|
|
2154
|
+
const l = t, e = o, { t: n } = ce(), a = C(() => {
|
|
2155
2155
|
var u;
|
|
2156
2156
|
return l.data !== null ? Math.ceil((((u = l.data) == null ? void 0 : u.totalRecords) ?? 0) / l.request.pageSize) : 1;
|
|
2157
|
-
}), d =
|
|
2157
|
+
}), d = C(() => {
|
|
2158
2158
|
const u = Array.from(Array(a.value + 1).keys());
|
|
2159
2159
|
let c = [];
|
|
2160
2160
|
if (u.shift(), u.length) {
|
|
@@ -2184,8 +2184,8 @@ const na = {
|
|
|
2184
2184
|
}
|
|
2185
2185
|
}
|
|
2186
2186
|
return (u, c) => {
|
|
2187
|
-
var g,
|
|
2188
|
-
return (
|
|
2187
|
+
var g, b;
|
|
2188
|
+
return (b = (g = u.data) == null ? void 0 : g.results) != null && b.length && u.request ? (p(), v("div", Ca, [
|
|
2189
2189
|
f("div", Ta, [
|
|
2190
2190
|
f("span", qa, N(m(n)("grid.jumpToPage")), 1),
|
|
2191
2191
|
D(We, {
|
|
@@ -2212,7 +2212,7 @@ const na = {
|
|
|
2212
2212
|
f("li", Ia, N(m(De)(u.request.pageNumber)) + " / " + N(m(De)(a.value)), 1),
|
|
2213
2213
|
Q(f("li", {
|
|
2214
2214
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
2215
|
-
onClick: c[0] || (c[0] = (
|
|
2215
|
+
onClick: c[0] || (c[0] = (h) => s(1))
|
|
2216
2216
|
}, [
|
|
2217
2217
|
D(m(G), {
|
|
2218
2218
|
icon: "ph:caret-double-left",
|
|
@@ -2223,7 +2223,7 @@ const na = {
|
|
|
2223
2223
|
]),
|
|
2224
2224
|
Q(f("li", {
|
|
2225
2225
|
class: "cl-cursor-pointer cl-mt-1 lg:cl-mr-2 mr-1",
|
|
2226
|
-
onClick: c[1] || (c[1] = (
|
|
2226
|
+
onClick: c[1] || (c[1] = (h) => s(u.request.pageNumber - 1))
|
|
2227
2227
|
}, [
|
|
2228
2228
|
D(m(G), {
|
|
2229
2229
|
icon: "ph:caret-left",
|
|
@@ -2232,17 +2232,17 @@ const na = {
|
|
|
2232
2232
|
], 512), [
|
|
2233
2233
|
[te, u.request.pageNumber > 1]
|
|
2234
2234
|
]),
|
|
2235
|
-
(p(!0), v(_, null, ue(d.value, (
|
|
2235
|
+
(p(!0), v(_, null, ue(d.value, (h, $) => (p(), v("li", {
|
|
2236
2236
|
key: $,
|
|
2237
2237
|
class: F(["cl-cursor-pointer cl-mr-1 lg:cl-mr-2", {
|
|
2238
|
-
"cl-text-black cl-font-bold": u.request.pageNumber ===
|
|
2239
|
-
"cl-text-grey-6": u.request.pageNumber !==
|
|
2238
|
+
"cl-text-black cl-font-bold": u.request.pageNumber === h,
|
|
2239
|
+
"cl-text-grey-6": u.request.pageNumber !== h
|
|
2240
2240
|
}]),
|
|
2241
|
-
onClick: (q) => s(
|
|
2242
|
-
}, N(m(De)(
|
|
2241
|
+
onClick: (q) => s(h)
|
|
2242
|
+
}, N(m(De)(h)), 11, Na))), 128)),
|
|
2243
2243
|
Q(f("li", {
|
|
2244
2244
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
2245
|
-
onClick: c[2] || (c[2] = (
|
|
2245
|
+
onClick: c[2] || (c[2] = (h) => s(u.request.pageNumber + 1))
|
|
2246
2246
|
}, [
|
|
2247
2247
|
D(m(G), {
|
|
2248
2248
|
icon: "ph:caret-right",
|
|
@@ -2253,7 +2253,7 @@ const na = {
|
|
|
2253
2253
|
]),
|
|
2254
2254
|
Q(f("li", {
|
|
2255
2255
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
2256
|
-
onClick: c[3] || (c[3] = (
|
|
2256
|
+
onClick: c[3] || (c[3] = (h) => s(a.value))
|
|
2257
2257
|
}, [
|
|
2258
2258
|
D(m(G), {
|
|
2259
2259
|
icon: "ph:caret-double-right",
|
|
@@ -2266,14 +2266,14 @@ const na = {
|
|
|
2266
2266
|
]),
|
|
2267
2267
|
f("ul", Ra, [
|
|
2268
2268
|
f("li", Ma, N(m(n)("grid.pageSize")), 1),
|
|
2269
|
-
(p(), v(_, null, ue(r, (
|
|
2269
|
+
(p(), v(_, null, ue(r, (h, $) => f("li", {
|
|
2270
2270
|
key: $,
|
|
2271
2271
|
class: F(["cl-cursor-pointer cl-mr-1 lg:cl-mr-2", {
|
|
2272
|
-
"cl-text-black cl-font-bold": u.request.pageSize ===
|
|
2273
|
-
"cl-text-grey-6": u.request.pageSize !==
|
|
2272
|
+
"cl-text-black cl-font-bold": u.request.pageSize === h,
|
|
2273
|
+
"cl-text-grey-6": u.request.pageSize !== h
|
|
2274
2274
|
}]),
|
|
2275
|
-
onClick: (q) => i(
|
|
2276
|
-
}, N(m(De)(
|
|
2275
|
+
onClick: (q) => i(h)
|
|
2276
|
+
}, N(m(De)(h)), 11, Ua)), 64))
|
|
2277
2277
|
]),
|
|
2278
2278
|
f("ul", za, [
|
|
2279
2279
|
f("li", Fa, N(m(n)("grid.totalRecords")), 1),
|
|
@@ -2520,7 +2520,7 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
2520
2520
|
},
|
|
2521
2521
|
emits: ["quick-date-selected"],
|
|
2522
2522
|
setup(t, { emit: o }) {
|
|
2523
|
-
const l = t, e = o, { t: n } = ce(), a =
|
|
2523
|
+
const l = t, e = o, { t: n } = ce(), a = C(() => {
|
|
2524
2524
|
const d = [];
|
|
2525
2525
|
switch (l.scope) {
|
|
2526
2526
|
case "past":
|
|
@@ -2569,7 +2569,7 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
2569
2569
|
},
|
|
2570
2570
|
emits: ["togglePopover", "clear"],
|
|
2571
2571
|
setup(t) {
|
|
2572
|
-
const { t: o } = ce(), l =
|
|
2572
|
+
const { t: o } = ce(), l = C(() => {
|
|
2573
2573
|
const { class: e, ...n } = Nl();
|
|
2574
2574
|
return n;
|
|
2575
2575
|
});
|
|
@@ -2641,7 +2641,7 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
2641
2641
|
}),
|
|
2642
2642
|
emits: ["update:modelValue"],
|
|
2643
2643
|
setup(t) {
|
|
2644
|
-
const o = t, l = Te(t, "modelValue"), e =
|
|
2644
|
+
const o = t, l = Te(t, "modelValue"), e = C(() => o.timeZone ?? "UTC"), n = C({
|
|
2645
2645
|
get() {
|
|
2646
2646
|
let $ = null;
|
|
2647
2647
|
return l.value !== null && ($ = {
|
|
@@ -2663,12 +2663,12 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
2663
2663
|
} else
|
|
2664
2664
|
l.value = null;
|
|
2665
2665
|
}
|
|
2666
|
-
}), { locale: a } = ce(), d =
|
|
2666
|
+
}), { locale: a } = ce(), d = C(() => o.dateFormatLocale ?? a.value), s = C(() => ml(o.disabled, o.popoverPlacement)), r = C(() => gl(l.value, o.initialCalendarDate, e.value, "dateRange")), i = C(() => Kl(n.value, e.value, d.value)), u = I(null), c = I(null);
|
|
2667
2667
|
function g($) {
|
|
2668
2668
|
const q = Gl($, e.value);
|
|
2669
2669
|
n.value = q, u.value = $, c.value.move(q.start), c.value.hidePopover();
|
|
2670
2670
|
}
|
|
2671
|
-
const
|
|
2671
|
+
const b = Fl("(min-width: 768px)"), h = C(() => b.value ? 2 : 1);
|
|
2672
2672
|
return ($, q) => (p(), H(Ne, { "show-required-asterisk": $.required }, {
|
|
2673
2673
|
label: R(() => [
|
|
2674
2674
|
M($.$slots, "default")
|
|
@@ -2678,27 +2678,27 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
2678
2678
|
ref_key: "calendar",
|
|
2679
2679
|
ref: c,
|
|
2680
2680
|
modelValue: n.value,
|
|
2681
|
-
"onUpdate:modelValue": q[1] || (q[1] = (
|
|
2681
|
+
"onUpdate:modelValue": q[1] || (q[1] = (T) => n.value = T),
|
|
2682
2682
|
modelModifiers: { range: !0 },
|
|
2683
2683
|
mode: "date",
|
|
2684
2684
|
color: "primary",
|
|
2685
2685
|
"title-position": "left",
|
|
2686
2686
|
locale: d.value,
|
|
2687
2687
|
timezone: e.value,
|
|
2688
|
-
columns:
|
|
2688
|
+
columns: h.value,
|
|
2689
2689
|
popover: s.value,
|
|
2690
2690
|
"min-date": $.minDate,
|
|
2691
2691
|
"max-date": $.maxDate,
|
|
2692
2692
|
"initial-page": r.value,
|
|
2693
|
-
onDayclick: q[2] || (q[2] = (
|
|
2693
|
+
onDayclick: q[2] || (q[2] = (T) => u.value = null)
|
|
2694
2694
|
}, {
|
|
2695
|
-
default: R(({ togglePopover:
|
|
2695
|
+
default: R(({ togglePopover: T }) => [
|
|
2696
2696
|
D(bl, ee($.$attrs, {
|
|
2697
2697
|
required: $.required,
|
|
2698
2698
|
disabled: $.disabled,
|
|
2699
2699
|
"date-range-selected": !!n.value,
|
|
2700
2700
|
title: i.value,
|
|
2701
|
-
onTogglePopover:
|
|
2701
|
+
onTogglePopover: T,
|
|
2702
2702
|
onClear: q[0] || (q[0] = (L) => {
|
|
2703
2703
|
n.value = null, u.value = null, c.value.hidePopover();
|
|
2704
2704
|
})
|
|
@@ -2832,7 +2832,7 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
2832
2832
|
Rl((c) => ({
|
|
2833
2833
|
"5aa4acec": s.value
|
|
2834
2834
|
}));
|
|
2835
|
-
const l = t, e = Te(t, "modelValue"), { t: n } = ce(), a = I(), d = I(), s =
|
|
2835
|
+
const l = t, e = Te(t, "modelValue"), { t: n } = ce(), a = I(), d = I(), s = C(() => `${100 * (e.value - l.min) / (l.max - l.min)}%`), r = I(!1), i = mt(e, 50);
|
|
2836
2836
|
function u(c) {
|
|
2837
2837
|
var g;
|
|
2838
2838
|
e.value = c, (g = a.value) == null || g.focus();
|
|
@@ -2847,7 +2847,7 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
2847
2847
|
return ((c = a.value) == null ? void 0 : c.blur()) || ((g = d.value) == null ? void 0 : g.blur());
|
|
2848
2848
|
}
|
|
2849
2849
|
}), (c, g) => {
|
|
2850
|
-
const
|
|
2850
|
+
const b = He("icon");
|
|
2851
2851
|
return p(), H(Ne, {
|
|
2852
2852
|
errors: c.errors,
|
|
2853
2853
|
"show-required-asterisk": c.required
|
|
@@ -2857,14 +2857,14 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
2857
2857
|
f("button", {
|
|
2858
2858
|
disabled: c.disabled,
|
|
2859
2859
|
class: "active:cl-bg-grey-0 cl-bg-white cl-border cl-border-grey-2 cl-leading-none cl-min-w-[26px] cl-p-[5px] cl-rounded-full cl-shadow cl-text-xs cl-transition-colors disabled:cl-bg-grey-1 hover:cl-bg-off-white",
|
|
2860
|
-
onClick: g[0] || (g[0] = (
|
|
2860
|
+
onClick: g[0] || (g[0] = (h) => u(c.min))
|
|
2861
2861
|
}, N(m(al)(c.min, c.precision)), 9, Ja),
|
|
2862
2862
|
f("div", _a, [
|
|
2863
2863
|
Q(f("div", Xa, [
|
|
2864
2864
|
Q(f("input", ee({
|
|
2865
2865
|
ref_key: "sliderRef",
|
|
2866
2866
|
ref: a,
|
|
2867
|
-
"onUpdate:modelValue": g[1] || (g[1] = (
|
|
2867
|
+
"onUpdate:modelValue": g[1] || (g[1] = (h) => e.value = h)
|
|
2868
2868
|
}, c.$attrs, {
|
|
2869
2869
|
class: "cl-appearance-none cl-bg-transparent cl-cursor-pointer cl-outline-none cl-w-48 disabled:cl-cursor-default",
|
|
2870
2870
|
type: "range",
|
|
@@ -2889,7 +2889,7 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
2889
2889
|
ref_key: "inputRef",
|
|
2890
2890
|
ref: d,
|
|
2891
2891
|
modelValue: e.value,
|
|
2892
|
-
"onUpdate:modelValue": g[2] || (g[2] = (
|
|
2892
|
+
"onUpdate:modelValue": g[2] || (g[2] = (h) => e.value = h),
|
|
2893
2893
|
class: "cl-py-0.5 cl-w-48"
|
|
2894
2894
|
}, c.$attrs, {
|
|
2895
2895
|
min: c.min,
|
|
@@ -2904,15 +2904,15 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
2904
2904
|
f("button", {
|
|
2905
2905
|
disabled: c.disabled,
|
|
2906
2906
|
class: "active:cl-bg-grey-0 cl-bg-white cl-border cl-border-grey-2 cl-leading-none cl-min-w-[26px] cl-p-[5px] cl-rounded-full cl-shadow cl-text-xs cl-transition-colors disabled:cl-bg-grey-1 hover:cl-bg-off-white",
|
|
2907
|
-
onClick: g[3] || (g[3] = (
|
|
2907
|
+
onClick: g[3] || (g[3] = (h) => u(c.max))
|
|
2908
2908
|
}, N(m(al)(c.max, c.precision)), 9, tn),
|
|
2909
2909
|
f("button", {
|
|
2910
2910
|
disabled: c.disabled,
|
|
2911
2911
|
class: "active:cl-bg-grey-0 cl-bg-white cl-border cl-border-grey-2 cl-leading-none cl-min-w-0 cl-p-[5px] cl-rounded-full cl-shadow cl-text-xs cl-transition-colors disabled:cl-bg-grey-1 hover:cl-bg-off-white",
|
|
2912
2912
|
title: m(n)("input.switchInputMode"),
|
|
2913
|
-
onClick: g[4] || (g[4] = (
|
|
2913
|
+
onClick: g[4] || (g[4] = (h) => r.value = !r.value)
|
|
2914
2914
|
}, [
|
|
2915
|
-
D(
|
|
2915
|
+
D(b, { icon: "ph:arrows-left-right-thin" })
|
|
2916
2916
|
], 8, on)
|
|
2917
2917
|
])
|
|
2918
2918
|
]),
|
|
@@ -2969,7 +2969,7 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
2969
2969
|
var s;
|
|
2970
2970
|
(s = e.value) == null || s.focus();
|
|
2971
2971
|
}
|
|
2972
|
-
const { t: a } = ce(), d =
|
|
2972
|
+
const { t: a } = ce(), d = C(() => {
|
|
2973
2973
|
let s = "";
|
|
2974
2974
|
switch (l.type) {
|
|
2975
2975
|
case "date":
|
|
@@ -3043,17 +3043,17 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
3043
3043
|
}),
|
|
3044
3044
|
emits: /* @__PURE__ */ me(["focus"], ["update:modelValue"]),
|
|
3045
3045
|
setup(t, { expose: o, emit: l }) {
|
|
3046
|
-
const e = t, n = Te(t, "modelValue"), a = l, d =
|
|
3046
|
+
const e = t, n = Te(t, "modelValue"), a = l, d = C(() => e.timeZone ?? "UTC"), s = C({
|
|
3047
3047
|
get() {
|
|
3048
|
-
let
|
|
3049
|
-
return e.type === "time" ?
|
|
3048
|
+
let h = null;
|
|
3049
|
+
return e.type === "time" ? h = n.value === null ? "00:00" : n.value : n.value !== null && (h = W.fromISO(n.value, {
|
|
3050
3050
|
zone: d.value
|
|
3051
|
-
}).toJSDate()),
|
|
3051
|
+
}).toJSDate()), h;
|
|
3052
3052
|
},
|
|
3053
|
-
set(
|
|
3054
|
-
e.type === "time" ? n.value =
|
|
3053
|
+
set(h) {
|
|
3054
|
+
e.type === "time" ? n.value = h : h !== null ? n.value = Ue(h, null, !0, e.timeZone) : n.value = null;
|
|
3055
3055
|
}
|
|
3056
|
-
}), { locale: r } = ce(), i =
|
|
3056
|
+
}), { locale: r } = ce(), i = C(() => e.dateFormatLocale ?? r.value), u = C(() => ml(e.disabled, e.popoverPlacement)), c = C(() => Zl(i.value, e.type)), g = I(null), b = C(() => gl(n.value, e.initialCalendarDate, d.value, e.type));
|
|
3057
3057
|
return oe(() => [
|
|
3058
3058
|
e.minDate,
|
|
3059
3059
|
e.maxDate
|
|
@@ -3061,23 +3061,23 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
3061
3061
|
e.type !== "time" && (s.value instanceof Date || s.value === null) && (s.value = ja(e.minDate, e.maxDate, s.value, d.value, e.type));
|
|
3062
3062
|
}), o({
|
|
3063
3063
|
focus() {
|
|
3064
|
-
var
|
|
3065
|
-
(
|
|
3064
|
+
var h;
|
|
3065
|
+
(h = g.value) == null || h.focus(), a("focus");
|
|
3066
3066
|
}
|
|
3067
|
-
}), (
|
|
3067
|
+
}), (h, $) => (p(), H(Ne, { "show-required-asterisk": h.required }, {
|
|
3068
3068
|
label: R(() => [
|
|
3069
|
-
M(
|
|
3069
|
+
M(h.$slots, "default")
|
|
3070
3070
|
]),
|
|
3071
3071
|
default: R(() => [
|
|
3072
|
-
|
|
3072
|
+
h.type === "time" ? (p(), H(m(Me), {
|
|
3073
3073
|
key: 0,
|
|
3074
3074
|
modelValue: s.value,
|
|
3075
3075
|
"onUpdate:modelValue": $[1] || ($[1] = (q) => s.value = q),
|
|
3076
3076
|
modelModifiers: { string: !0 },
|
|
3077
3077
|
locale: m(r),
|
|
3078
3078
|
is24hr: m(r) !== "en-US",
|
|
3079
|
-
mode:
|
|
3080
|
-
"is-required":
|
|
3079
|
+
mode: h.type,
|
|
3080
|
+
"is-required": h.required,
|
|
3081
3081
|
"update-on-input": !1,
|
|
3082
3082
|
masks: { modelValue: "HH:mm", input: c.value, inputTime: [c.value], inputTime24hr: [c.value] },
|
|
3083
3083
|
color: "primary",
|
|
@@ -3085,16 +3085,16 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
3085
3085
|
"hide-time-header": "",
|
|
3086
3086
|
popover: u.value
|
|
3087
3087
|
}, {
|
|
3088
|
-
default: R(({ inputValue: q, inputEvents:
|
|
3089
|
-
D(je, ee(
|
|
3088
|
+
default: R(({ inputValue: q, inputEvents: T }) => [
|
|
3089
|
+
D(je, ee(h.$attrs, {
|
|
3090
3090
|
ref_key: "input",
|
|
3091
3091
|
ref: g,
|
|
3092
3092
|
date: q,
|
|
3093
|
-
events:
|
|
3094
|
-
type:
|
|
3095
|
-
placeholder:
|
|
3096
|
-
required:
|
|
3097
|
-
disabled:
|
|
3093
|
+
events: T,
|
|
3094
|
+
type: h.type,
|
|
3095
|
+
placeholder: h.placeholder,
|
|
3096
|
+
required: h.required,
|
|
3097
|
+
disabled: h.disabled,
|
|
3098
3098
|
onClear: $[0] || ($[0] = (L) => s.value = null)
|
|
3099
3099
|
}), null, 16, ["date", "events", "type", "placeholder", "required", "disabled"])
|
|
3100
3100
|
]),
|
|
@@ -3106,11 +3106,11 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
3106
3106
|
locale: m(r),
|
|
3107
3107
|
is24hr: m(r) !== "en-US",
|
|
3108
3108
|
timezone: d.value,
|
|
3109
|
-
mode:
|
|
3110
|
-
"min-date":
|
|
3111
|
-
"max-date":
|
|
3112
|
-
"initial-page":
|
|
3113
|
-
"is-required":
|
|
3109
|
+
mode: h.type,
|
|
3110
|
+
"min-date": h.minDate,
|
|
3111
|
+
"max-date": h.maxDate,
|
|
3112
|
+
"initial-page": b.value,
|
|
3113
|
+
"is-required": h.required,
|
|
3114
3114
|
"update-on-input": !1,
|
|
3115
3115
|
masks: { L: c.value, inputDateTime: [c.value], inputDateTime24hr: [c.value] },
|
|
3116
3116
|
color: "primary",
|
|
@@ -3118,18 +3118,18 @@ const Pa = { class: "cl-gap-1 cl-grid cl-grid-cols-2" }, Ha = ["onClick"], Wa =
|
|
|
3118
3118
|
"hide-time-header": "",
|
|
3119
3119
|
popover: u.value
|
|
3120
3120
|
}, {
|
|
3121
|
-
default: R(({ inputValue: q, inputEvents:
|
|
3122
|
-
D(je, ee(
|
|
3121
|
+
default: R(({ inputValue: q, inputEvents: T }) => [
|
|
3122
|
+
D(je, ee(h.$attrs, {
|
|
3123
3123
|
ref_key: "input",
|
|
3124
3124
|
ref: g,
|
|
3125
3125
|
date: q,
|
|
3126
|
-
events:
|
|
3127
|
-
type:
|
|
3128
|
-
placeholder:
|
|
3129
|
-
required:
|
|
3130
|
-
disabled:
|
|
3126
|
+
events: T,
|
|
3127
|
+
type: h.type,
|
|
3128
|
+
placeholder: h.placeholder,
|
|
3129
|
+
required: h.required,
|
|
3130
|
+
disabled: h.disabled,
|
|
3131
3131
|
onClear: $[2] || ($[2] = (L) => s.value = null),
|
|
3132
|
-
onReset: $[3] || ($[3] = (L) => s.value = m(Wl)(
|
|
3132
|
+
onReset: $[3] || ($[3] = (L) => s.value = m(Wl)(h.minDate, h.maxDate, d.value, h.type))
|
|
3133
3133
|
}), null, 16, ["date", "events", "type", "placeholder", "required", "disabled"])
|
|
3134
3134
|
]),
|
|
3135
3135
|
_: 1
|
|
@@ -3333,19 +3333,19 @@ const wn = {
|
|
|
3333
3333
|
},
|
|
3334
3334
|
emits: ["update:filter"],
|
|
3335
3335
|
setup(t, { emit: o }) {
|
|
3336
|
-
const l = t, e = o, { t: n } = ce(), a =
|
|
3336
|
+
const l = t, e = o, { t: n } = ce(), a = C(() => {
|
|
3337
3337
|
let c = [];
|
|
3338
3338
|
return l.column.type !== "slot" ? c = Ol.filter((g) => g.allowedTypes.includes(l.column.type)) : typeof l.column.slotType < "u" && typeof l.column.field < "u" && (c = Ol.filter((g) => g.allowedTypes.includes(l.column.slotType))), l.column.type === "date" || l.column.type === "datetime" || l.column.slotType === "date" || l.column.slotType === "datetime" ? c.forEach((g) => {
|
|
3339
3339
|
g.description = n(`grid.${g.key}`);
|
|
3340
3340
|
}) : c.forEach((g) => {
|
|
3341
3341
|
g.description = n(`grid.${g.method}`);
|
|
3342
3342
|
}), c;
|
|
3343
|
-
}), d =
|
|
3343
|
+
}), d = C(() => {
|
|
3344
3344
|
var g;
|
|
3345
3345
|
let c = (g = l.filter) == null ? void 0 : g.filterMethod;
|
|
3346
|
-
return typeof c > "u" && (c = X[l.defaultOperation].replace("_", "").toLowerCase()), a.value.find((
|
|
3347
|
-
var
|
|
3348
|
-
return
|
|
3346
|
+
return typeof c > "u" && (c = X[l.defaultOperation].replace("_", "").toLowerCase()), a.value.find((b) => {
|
|
3347
|
+
var h;
|
|
3348
|
+
return b.method.toLowerCase() === ((h = c == null ? void 0 : c.removeNonAlphanumeric()) == null ? void 0 : h.toLowerCase());
|
|
3349
3349
|
});
|
|
3350
3350
|
});
|
|
3351
3351
|
function s(c) {
|
|
@@ -3363,7 +3363,7 @@ const wn = {
|
|
|
3363
3363
|
return;
|
|
3364
3364
|
e("update:filter", g);
|
|
3365
3365
|
}
|
|
3366
|
-
const r = I(), { left: i } = gt(r), u =
|
|
3366
|
+
const r = I(), { left: i } = gt(r), u = C(() => i.value / 2 < 208);
|
|
3367
3367
|
return (c, g) => (p(), v("div", {
|
|
3368
3368
|
ref_key: "gridMethodSelectElement",
|
|
3369
3369
|
ref: r,
|
|
@@ -3387,18 +3387,18 @@ const wn = {
|
|
|
3387
3387
|
}])
|
|
3388
3388
|
}, [
|
|
3389
3389
|
f("strong", Tn, N(m(n)("grid.availableMethods")), 1),
|
|
3390
|
-
(p(!0), v(_, null, ue(a.value, (
|
|
3390
|
+
(p(!0), v(_, null, ue(a.value, (b, h) => {
|
|
3391
3391
|
var $;
|
|
3392
3392
|
return p(), v("span", {
|
|
3393
|
-
key:
|
|
3393
|
+
key: h,
|
|
3394
3394
|
class: F(["cl-cursor-pointer cl-px-4 cl-py-1 cl-transition-colors cl-w-full hover:cl-bg-grey-0", {
|
|
3395
|
-
"cl-bg-primary-default cl-opacity-80":
|
|
3395
|
+
"cl-bg-primary-default cl-opacity-80": b.method === (($ = d.value) == null ? void 0 : $.method)
|
|
3396
3396
|
}]),
|
|
3397
|
-
onClick: ae((q) => s(
|
|
3397
|
+
onClick: ae((q) => s(b.method), ["prevent"])
|
|
3398
3398
|
}, [
|
|
3399
|
-
pe(N(
|
|
3399
|
+
pe(N(b.description) + " ", 1),
|
|
3400
3400
|
D(m(G), {
|
|
3401
|
-
icon:
|
|
3401
|
+
icon: b.icon,
|
|
3402
3402
|
class: "cl-float-right cl-text-grey-4 cl-text-sm"
|
|
3403
3403
|
}, null, 8, ["icon"])
|
|
3404
3404
|
], 10, qn);
|
|
@@ -3434,10 +3434,10 @@ const wn = {
|
|
|
3434
3434
|
function d() {
|
|
3435
3435
|
return l.column.type === "string" || l.column.slotType === "string" ? X.CONTAINS : l.column.type === "datetime" || l.column.slotType === "datetime" || l.column.type === "date" || l.column.slotType === "date" ? X.LESS_THAN : X.EQUAL;
|
|
3436
3436
|
}
|
|
3437
|
-
const s =
|
|
3437
|
+
const s = C({
|
|
3438
3438
|
get: () => l.filter,
|
|
3439
3439
|
set: (k) => e("update:filter", k)
|
|
3440
|
-
}), r =
|
|
3440
|
+
}), r = C(() => l.column.type === "date" || l.column.type === "datetime" || l.column.type === "slot" && (l.column.slotType === "date" || l.column.slotType === "datetime")), i = C(() => l.column.type === "dateRange" || l.column.type === "slot" && l.column.slotType === "dateRange"), u = C(() => l.column.type === "list" || l.column.type === "slot" && l.column.slotType === "list"), c = C(() => u.value && l.column.listType === "number"), g = C(() => l.column.format === le.INTEGER ? le.DECIMAL : l.column.format ?? le.DECIMAL), b = C({
|
|
3441
3441
|
get() {
|
|
3442
3442
|
var U, A, re, O, Z, J, se;
|
|
3443
3443
|
let k = (U = s.value) == null ? void 0 : U[0];
|
|
@@ -3551,26 +3551,26 @@ const wn = {
|
|
|
3551
3551
|
l.timeZone ? A.filterValue = W.fromISO(A.filterValue).setZone("UTC").toISO() ?? "" : A.filterValue = A.filterValue.replace("Z", "");
|
|
3552
3552
|
s.value = U;
|
|
3553
3553
|
}
|
|
3554
|
-
}),
|
|
3555
|
-
get: () =>
|
|
3554
|
+
}), h = C({
|
|
3555
|
+
get: () => b.value,
|
|
3556
3556
|
set(k) {
|
|
3557
|
-
|
|
3557
|
+
b.value = k;
|
|
3558
3558
|
}
|
|
3559
3559
|
});
|
|
3560
3560
|
function $(k, U, A) {
|
|
3561
3561
|
return U !== void 0 && U !== "" && k === A && r.value;
|
|
3562
3562
|
}
|
|
3563
|
-
const q =
|
|
3563
|
+
const q = C(() => {
|
|
3564
3564
|
var k;
|
|
3565
|
-
return ((k =
|
|
3566
|
-
}),
|
|
3565
|
+
return ((k = b.value) == null ? void 0 : k.filterValue) ?? "";
|
|
3566
|
+
}), T = C(() => q.value === "" ? null : q.value), L = C(() => q.value === "" ? null : q.value), S = C(() => ul(l.column));
|
|
3567
3567
|
function P(k, U) {
|
|
3568
3568
|
var ie;
|
|
3569
3569
|
let A, re = (k == null ? void 0 : k.value) ?? U;
|
|
3570
|
-
const O = ((ie =
|
|
3570
|
+
const O = ((ie = b.value) == null ? void 0 : ie.filterValue.toString()) ?? "", Z = !!re.trim(), J = !!O.trim();
|
|
3571
3571
|
if (Z === !1 && J && (re = ""), Z || J) {
|
|
3572
|
-
if (
|
|
3573
|
-
A = ge(
|
|
3572
|
+
if (b.value)
|
|
3573
|
+
A = ge(h.value), A.filterValue = re;
|
|
3574
3574
|
else if (Z && typeof l.column.field < "u") {
|
|
3575
3575
|
const he = d();
|
|
3576
3576
|
A = {
|
|
@@ -3581,7 +3581,7 @@ const wn = {
|
|
|
3581
3581
|
};
|
|
3582
3582
|
} else
|
|
3583
3583
|
return;
|
|
3584
|
-
|
|
3584
|
+
b.value = A;
|
|
3585
3585
|
}
|
|
3586
3586
|
}
|
|
3587
3587
|
function x(k, U) {
|
|
@@ -3598,8 +3598,8 @@ const wn = {
|
|
|
3598
3598
|
function E(k) {
|
|
3599
3599
|
var re;
|
|
3600
3600
|
let U, A = !1;
|
|
3601
|
-
if (
|
|
3602
|
-
A = ((re =
|
|
3601
|
+
if (b.value)
|
|
3602
|
+
A = ((re = b.value) == null ? void 0 : re.filterValue) === k, U = ge(b.value), U.filterValue = k ?? "";
|
|
3603
3603
|
else if (k !== null && typeof l.column.field < "u") {
|
|
3604
3604
|
const O = d();
|
|
3605
3605
|
U = {
|
|
@@ -3610,7 +3610,7 @@ const wn = {
|
|
|
3610
3610
|
};
|
|
3611
3611
|
} else
|
|
3612
3612
|
return;
|
|
3613
|
-
A === !1 && (
|
|
3613
|
+
A === !1 && (b.value = U);
|
|
3614
3614
|
}
|
|
3615
3615
|
function Y(k) {
|
|
3616
3616
|
k === "Enter" && e("perform-data-request");
|
|
@@ -3646,7 +3646,7 @@ const wn = {
|
|
|
3646
3646
|
], 40, Dn)) : r.value ? (p(), H(et, {
|
|
3647
3647
|
key: 1,
|
|
3648
3648
|
id: `${m(V)}-${k.column.name}`,
|
|
3649
|
-
"model-value":
|
|
3649
|
+
"model-value": T.value,
|
|
3650
3650
|
"time-zone": k.timeZone,
|
|
3651
3651
|
readonly: k.loading,
|
|
3652
3652
|
type: k.column.type === "slot" ? k.column.slotType : k.column.type,
|
|
@@ -3714,8 +3714,8 @@ const wn = {
|
|
|
3714
3714
|
], 40, zn)) : z("", !0),
|
|
3715
3715
|
i.value ? z("", !0) : (p(), H(Sn, {
|
|
3716
3716
|
key: 6,
|
|
3717
|
-
filter:
|
|
3718
|
-
"onUpdate:filter": U[6] || (U[6] = (A) =>
|
|
3717
|
+
filter: h.value,
|
|
3718
|
+
"onUpdate:filter": U[6] || (U[6] = (A) => h.value = A),
|
|
3719
3719
|
loading: k.loading,
|
|
3720
3720
|
column: k.column,
|
|
3721
3721
|
"default-operation": d()
|
|
@@ -3734,7 +3734,7 @@ const wn = {
|
|
|
3734
3734
|
},
|
|
3735
3735
|
emits: ["update:request", "update:filterPanelOpen", "perform-data-request"],
|
|
3736
3736
|
setup(t, { emit: o }) {
|
|
3737
|
-
const l = t, e = o, { t: n } = ce(), a =
|
|
3737
|
+
const l = t, e = o, { t: n } = ce(), a = C({
|
|
3738
3738
|
get: () => l.request,
|
|
3739
3739
|
set: (i) => e("update:request", i)
|
|
3740
3740
|
});
|
|
@@ -3767,7 +3767,7 @@ const wn = {
|
|
|
3767
3767
|
class: F(["cl-text-grey-3 cl-text-sm", {
|
|
3768
3768
|
"cl-cursor-pointer": m(Ke)(c) && i.loading === !1
|
|
3769
3769
|
}]),
|
|
3770
|
-
onClick: (
|
|
3770
|
+
onClick: (b) => m(Ke)(c) && i.loading === !1 ? s(c.field) : () => {
|
|
3771
3771
|
}
|
|
3772
3772
|
}, [
|
|
3773
3773
|
pe(N(c.caption) + " ", 1),
|
|
@@ -3808,7 +3808,7 @@ const wn = {
|
|
|
3808
3808
|
m(Ke)(c) ? (p(), v("div", {
|
|
3809
3809
|
key: 0,
|
|
3810
3810
|
class: "cl-col-span-2 cl-gap-1 cl-span lg:cl-hidden",
|
|
3811
|
-
onClick: (
|
|
3811
|
+
onClick: (b) => i.loading === !1 ? s(c.field) : void 0
|
|
3812
3812
|
}, [
|
|
3813
3813
|
f("span", Qn, N(m(n)("grid.sortBy")), 1),
|
|
3814
3814
|
d(c, !0) ? (p(), H(m(G), {
|
|
@@ -3828,13 +3828,13 @@ const wn = {
|
|
|
3828
3828
|
D(jn, {
|
|
3829
3829
|
class: "cl-col-span-4",
|
|
3830
3830
|
loading: i.loading,
|
|
3831
|
-
filter: a.value.filters.filter((
|
|
3831
|
+
filter: a.value.filters.filter((b) => b.filterOnColumn === c.field),
|
|
3832
3832
|
column: c,
|
|
3833
3833
|
"time-zone": i.timeZone,
|
|
3834
3834
|
"quick-date-scope": c.quickDateScope ?? null,
|
|
3835
3835
|
"header-display-timezone": i.headerDisplayTimezone,
|
|
3836
3836
|
"onUpdate:filter": r,
|
|
3837
|
-
onPerformDataRequest: u[1] || (u[1] = (
|
|
3837
|
+
onPerformDataRequest: u[1] || (u[1] = (b) => e("perform-data-request"))
|
|
3838
3838
|
}, null, 8, ["loading", "filter", "column", "time-zone", "quick-date-scope", "header-display-timezone"])
|
|
3839
3839
|
], 2))), 128))
|
|
3840
3840
|
], 2)
|
|
@@ -3851,7 +3851,7 @@ const wn = {
|
|
|
3851
3851
|
}),
|
|
3852
3852
|
emits: /* @__PURE__ */ me(["update:request"], ["update:searchValue"]),
|
|
3853
3853
|
setup(t, { emit: o }) {
|
|
3854
|
-
const l = t, e = Te(t, "searchValue"), n = o, a =
|
|
3854
|
+
const l = t, e = Te(t, "searchValue"), n = o, a = C({
|
|
3855
3855
|
get: () => l.request,
|
|
3856
3856
|
set: (r) => n("update:request", r)
|
|
3857
3857
|
});
|
|
@@ -3914,7 +3914,7 @@ const wn = {
|
|
|
3914
3914
|
c < i.length && c >= 0 && i.splice(c, 0, i.splice(u, 1)[0]);
|
|
3915
3915
|
}
|
|
3916
3916
|
function s(i, u) {
|
|
3917
|
-
const c = ge(l.columns), g = c.findIndex((
|
|
3917
|
+
const c = ge(l.columns), g = c.findIndex((b) => b.name === u.name);
|
|
3918
3918
|
g >= 0 && (c[g].visible = i), e("update:columns", c);
|
|
3919
3919
|
}
|
|
3920
3920
|
function r(i, u) {
|
|
@@ -3959,7 +3959,7 @@ const wn = {
|
|
|
3959
3959
|
f("div", cr, [
|
|
3960
3960
|
D(dl, {
|
|
3961
3961
|
"model-value": c.visible === void 0 || c.visible === !0,
|
|
3962
|
-
"onUpdate:modelValue": (
|
|
3962
|
+
"onUpdate:modelValue": (b) => s(b, c)
|
|
3963
3963
|
}, null, 8, ["model-value", "onUpdate:modelValue"])
|
|
3964
3964
|
]),
|
|
3965
3965
|
f("div", ur, [
|
|
@@ -3968,13 +3968,13 @@ const wn = {
|
|
|
3968
3968
|
key: 0,
|
|
3969
3969
|
class: "cl-cursor-pointer cl-inline-block cl-mr-2",
|
|
3970
3970
|
icon: "ph:arrow-left",
|
|
3971
|
-
onClick: (
|
|
3971
|
+
onClick: (b) => r(g, "down")
|
|
3972
3972
|
}, null, 8, ["onClick"])) : z("", !0),
|
|
3973
3973
|
g !== i.columns.length - 1 ? (p(), H(m(G), {
|
|
3974
3974
|
key: 1,
|
|
3975
3975
|
class: "cl-cursor-pointer cl-inline-block",
|
|
3976
3976
|
icon: "ph:arrow-right",
|
|
3977
|
-
onClick: (
|
|
3977
|
+
onClick: (b) => r(g, "up")
|
|
3978
3978
|
}, null, 8, ["onClick"])) : z("", !0)
|
|
3979
3979
|
], 64)) : (p(), v("em", dr, N(m(n)("grid.hidden")), 1))
|
|
3980
3980
|
])
|
|
@@ -4007,12 +4007,12 @@ const wn = {
|
|
|
4007
4007
|
var ne;
|
|
4008
4008
|
const l = t, e = o, n = Nl();
|
|
4009
4009
|
wl("cl-ui-grid-id", n.id);
|
|
4010
|
-
const a =
|
|
4010
|
+
const a = C(() => l.headerDisplayTimezone ?? l.timeZone), d = C(() => l.dateFormatLocale);
|
|
4011
4011
|
wl(Pl, d);
|
|
4012
|
-
const s =
|
|
4012
|
+
const s = C({
|
|
4013
4013
|
get: () => l.columns,
|
|
4014
4014
|
set: (w) => e("update:columns", w)
|
|
4015
|
-
}), r =
|
|
4015
|
+
}), r = C(() => s.value.filter((w) => w.visible ?? !0)), i = I({});
|
|
4016
4016
|
function u() {
|
|
4017
4017
|
const w = {};
|
|
4018
4018
|
window.innerWidth >= 1024 && s.value.forEach((V) => {
|
|
@@ -4026,34 +4026,34 @@ const wn = {
|
|
|
4026
4026
|
Pe(() => {
|
|
4027
4027
|
window.addEventListener("resize", u), u();
|
|
4028
4028
|
}), _e(() => window.removeEventListener("resize", u));
|
|
4029
|
-
const g =
|
|
4029
|
+
const g = C({
|
|
4030
4030
|
get: () => l.request,
|
|
4031
4031
|
set: (w) => e("update:request", w)
|
|
4032
4032
|
});
|
|
4033
|
-
function
|
|
4033
|
+
function b() {
|
|
4034
4034
|
const w = ge(g.value);
|
|
4035
4035
|
w.pageNumber = 1, w.filters = [], E.value = "", g.value = w;
|
|
4036
4036
|
}
|
|
4037
|
-
function
|
|
4037
|
+
function h(w) {
|
|
4038
4038
|
w === !1 && e("data-request");
|
|
4039
4039
|
}
|
|
4040
|
-
const $ = vt(
|
|
4040
|
+
const $ = vt(h, 1e3);
|
|
4041
4041
|
oe(g, () => $(!1), {
|
|
4042
4042
|
deep: !0,
|
|
4043
4043
|
immediate: !0
|
|
4044
4044
|
});
|
|
4045
4045
|
function q() {
|
|
4046
|
-
$(!0),
|
|
4046
|
+
$(!0), h(!1);
|
|
4047
4047
|
}
|
|
4048
|
-
const
|
|
4048
|
+
const T = C(() => l.data), L = I(!1), S = I(!1);
|
|
4049
4049
|
oe(L, () => {
|
|
4050
4050
|
L.value ? e("edit-start") : Ie(() => e("edit-end"));
|
|
4051
4051
|
});
|
|
4052
|
-
const P =
|
|
4052
|
+
const P = C(() => ({
|
|
4053
4053
|
highlightRowSelection: !0,
|
|
4054
4054
|
disableUnsavedChangesWarning: !1,
|
|
4055
4055
|
...l.options
|
|
4056
|
-
})), x =
|
|
4056
|
+
})), x = C({
|
|
4057
4057
|
get() {
|
|
4058
4058
|
const w = ge(g.value);
|
|
4059
4059
|
return w.filters = w.filters.filter((V) => V.filterMethod !== "andcontains" && V.filterOperation !== X.AND_CONTAINS), w;
|
|
@@ -4068,7 +4068,7 @@ const wn = {
|
|
|
4068
4068
|
filters: V
|
|
4069
4069
|
};
|
|
4070
4070
|
}
|
|
4071
|
-
}), E = I(((ne = l.request.filters.find((w) => w.filterMethod === "andcontains" || w.filterOperation === X.AND_CONTAINS)) == null ? void 0 : ne.filterValue) ?? ""), Y =
|
|
4071
|
+
}), E = I(((ne = l.request.filters.find((w) => w.filterMethod === "andcontains" || w.filterOperation === X.AND_CONTAINS)) == null ? void 0 : ne.filterValue) ?? ""), Y = C(() => l.columns.filter((w) => (w.type === "string" || w.type === "slot" && w.slotType === "string") && w.searchable));
|
|
4072
4072
|
return (w, V) => (p(), v("div", fr, [
|
|
4073
4073
|
Y.value.length > 0 ? (p(), H(Xn, {
|
|
4074
4074
|
key: 0,
|
|
@@ -4102,7 +4102,7 @@ const wn = {
|
|
|
4102
4102
|
options: P.value,
|
|
4103
4103
|
request: g.value,
|
|
4104
4104
|
loading: w.loading,
|
|
4105
|
-
onClearFilters:
|
|
4105
|
+
onClearFilters: b
|
|
4106
4106
|
}, {
|
|
4107
4107
|
"additional-grid-actions": R((k) => [
|
|
4108
4108
|
M(w.$slots, "additional-grid-actions", fe(ve(k)))
|
|
@@ -4144,13 +4144,13 @@ const wn = {
|
|
|
4144
4144
|
D(ha, {
|
|
4145
4145
|
columns: r.value,
|
|
4146
4146
|
request: g.value,
|
|
4147
|
-
data:
|
|
4147
|
+
data: T.value,
|
|
4148
4148
|
"time-zone": w.timeZone,
|
|
4149
4149
|
loading: w.loading,
|
|
4150
4150
|
"search-value": E.value,
|
|
4151
4151
|
options: P.value,
|
|
4152
4152
|
"edit-mode": L.value,
|
|
4153
|
-
onClearFilters:
|
|
4153
|
+
onClearFilters: b,
|
|
4154
4154
|
onRowEdit: V[7] || (V[7] = (k) => w.$emit("row-edit", k)),
|
|
4155
4155
|
onRowEditCancelled: V[8] || (V[8] = (k) => w.$emit("row-edit-cancelled", k)),
|
|
4156
4156
|
onRowSelect: V[9] || (V[9] = (k) => w.$emit("row-select", k))
|
|
@@ -4287,7 +4287,7 @@ const wn = {
|
|
|
4287
4287
|
},
|
|
4288
4288
|
emits: ["update:date"],
|
|
4289
4289
|
setup(t, { expose: o, emit: l }) {
|
|
4290
|
-
const e = t, n = l, a =
|
|
4290
|
+
const e = t, n = l, a = C(() => e.timeZone ?? "UTC"), d = C({
|
|
4291
4291
|
get() {
|
|
4292
4292
|
let S = null;
|
|
4293
4293
|
return e.type === "time" ? S = e.date === null ? "00:00" : e.date : e.date !== null && typeof e.date == "string" ? S = W.fromISO(e.date, {
|
|
@@ -4316,12 +4316,12 @@ const wn = {
|
|
|
4316
4316
|
}
|
|
4317
4317
|
n("update:date", P);
|
|
4318
4318
|
}
|
|
4319
|
-
}), { locale: s } = ce(), r =
|
|
4319
|
+
}), { locale: s } = ce(), r = C(() => e.dateFormatLocale ?? s.value), i = C(() => ml(e.disabled, "auto")), u = C(() => Zl(r.value, e.type)), c = I(null), g = C(() => gl(e.date, e.initialDate, a.value, e.type)), b = I(null), h = I();
|
|
4320
4320
|
function $(S) {
|
|
4321
4321
|
const P = Gl(S, a.value);
|
|
4322
|
-
d.value = P,
|
|
4322
|
+
d.value = P, b.value = S, h.value.move(P.start), h.value.hidePopover();
|
|
4323
4323
|
}
|
|
4324
|
-
const q =
|
|
4324
|
+
const q = C(() => Kl(d.value, a.value, r.value)), T = Fl("(min-width: 768px)"), L = C(() => T.value ? 2 : 1);
|
|
4325
4325
|
return o({
|
|
4326
4326
|
focus() {
|
|
4327
4327
|
var S;
|
|
@@ -4360,7 +4360,7 @@ const wn = {
|
|
|
4360
4360
|
}, 8, ["modelValue", "locale", "is24hr", "mode", "is-required", "masks", "popover"])) : S.type === "dateRange" ? (p(), H(m(Me), {
|
|
4361
4361
|
key: 1,
|
|
4362
4362
|
ref_key: "calendar",
|
|
4363
|
-
ref:
|
|
4363
|
+
ref: h,
|
|
4364
4364
|
modelValue: d.value,
|
|
4365
4365
|
"onUpdate:modelValue": P[3] || (P[3] = (x) => d.value = x),
|
|
4366
4366
|
modelModifiers: { range: !0 },
|
|
@@ -4375,7 +4375,7 @@ const wn = {
|
|
|
4375
4375
|
"min-date": S.min,
|
|
4376
4376
|
"max-date": S.max,
|
|
4377
4377
|
"initial-page": g.value,
|
|
4378
|
-
onDayclick: P[4] || (P[4] = (x) =>
|
|
4378
|
+
onDayclick: P[4] || (P[4] = (x) => b.value = null)
|
|
4379
4379
|
}, {
|
|
4380
4380
|
default: R(({ togglePopover: x }) => [
|
|
4381
4381
|
D(je, ee(S.$attrs, {
|
|
@@ -4389,7 +4389,7 @@ const wn = {
|
|
|
4389
4389
|
placeholder: null,
|
|
4390
4390
|
onTogglePopover: x,
|
|
4391
4391
|
onClear: P[2] || (P[2] = (E) => {
|
|
4392
|
-
d.value = null,
|
|
4392
|
+
d.value = null, b.value = null, h.value.hidePopover();
|
|
4393
4393
|
})
|
|
4394
4394
|
}), null, 16, ["type", "required", "disabled", "range-selected", "title", "onTogglePopover"])
|
|
4395
4395
|
]),
|
|
@@ -4397,7 +4397,7 @@ const wn = {
|
|
|
4397
4397
|
S.quickDateScope !== "none" ? (p(), H(Jl, {
|
|
4398
4398
|
key: 0,
|
|
4399
4399
|
scope: S.quickDateScope,
|
|
4400
|
-
"selected-quick-date":
|
|
4400
|
+
"selected-quick-date": b.value,
|
|
4401
4401
|
"current-date-range": e.date,
|
|
4402
4402
|
onQuickDateSelected: $
|
|
4403
4403
|
}, null, 8, ["scope", "selected-quick-date", "current-date-range"])) : z("", !0)
|
|
@@ -4457,7 +4457,7 @@ const wn = {
|
|
|
4457
4457
|
},
|
|
4458
4458
|
emits: ["update:modelValue", "focus", "change"],
|
|
4459
4459
|
setup(t, { expose: o, emit: l }) {
|
|
4460
|
-
const e = t, n = l, { inputRef: a, setOptions: d, setValue: s, numberValue: r } = wt(e.currencyOptions, !1), i =
|
|
4460
|
+
const e = t, n = l, { inputRef: a, setOptions: d, setValue: s, numberValue: r } = wt(e.currencyOptions, !1), i = C(() => u(e.modelValue) ? e.modelValue : 0);
|
|
4461
4461
|
function u($) {
|
|
4462
4462
|
return typeof $ == "number" && isNaN($) === !1;
|
|
4463
4463
|
}
|
|
@@ -4467,10 +4467,10 @@ const wn = {
|
|
|
4467
4467
|
function g() {
|
|
4468
4468
|
u(r.value) === !1 && s(i.value), n("update:modelValue", r.value);
|
|
4469
4469
|
}
|
|
4470
|
-
function
|
|
4470
|
+
function b($) {
|
|
4471
4471
|
return Object.values($).some((q) => q !== "");
|
|
4472
4472
|
}
|
|
4473
|
-
function
|
|
4473
|
+
function h($) {
|
|
4474
4474
|
u(r.value) && n("change", $, r.value ?? 0);
|
|
4475
4475
|
}
|
|
4476
4476
|
return oe(
|
|
@@ -4481,7 +4481,7 @@ const wn = {
|
|
|
4481
4481
|
), oe(
|
|
4482
4482
|
() => e.currencyOptions,
|
|
4483
4483
|
($) => {
|
|
4484
|
-
|
|
4484
|
+
b($) && d($);
|
|
4485
4485
|
}
|
|
4486
4486
|
), o({
|
|
4487
4487
|
focus() {
|
|
@@ -4509,9 +4509,9 @@ const wn = {
|
|
|
4509
4509
|
placeholder: $.placeholder,
|
|
4510
4510
|
name: $.group,
|
|
4511
4511
|
onKeydown: be(c, ["enter"]),
|
|
4512
|
-
onChange:
|
|
4512
|
+
onChange: h,
|
|
4513
4513
|
onBlur: g,
|
|
4514
|
-
onFocus: q[0] || (q[0] = (
|
|
4514
|
+
onFocus: q[0] || (q[0] = (T) => n("focus"))
|
|
4515
4515
|
}, null, 42, Er));
|
|
4516
4516
|
}
|
|
4517
4517
|
}), Vr = (t) => (Ml("data-v-5cb4ccea"), t = t(), Ul(), t), Ir = { class: "cl-flex cl-items-start" }, Nr = { class: "cl-w-full" }, Rr = /* @__PURE__ */ Vr(() => /* @__PURE__ */ f("span", null, null, -1)), Mr = ["min", "max", "step", "disabled"], Ur = { class: "cl-bg-transparent cl-text-center cl-text-sm cl-w-full" }, zr = { class: "cl-bg-transparent cl-text-sm" }, Fr = {
|
|
@@ -4535,10 +4535,10 @@ const wn = {
|
|
|
4535
4535
|
Rl((i) => ({
|
|
4536
4536
|
"59055b28": d.value
|
|
4537
4537
|
}));
|
|
4538
|
-
const l = t, e = Te(t, "value"), { t: n } = ce(), a = I(), d =
|
|
4538
|
+
const l = t, e = Te(t, "value"), { t: n } = ce(), a = I(), d = C(() => {
|
|
4539
4539
|
let i = (e.value - l.min) / (l.max - l.min) * 100;
|
|
4540
4540
|
return i < 35 && i > 0 ? i < 20 ? i += 0.5 : i += 0.25 : i > 65 && i < 100 && (i > 80 ? i -= 0.5 : i -= 0.25), `${i}%`;
|
|
4541
|
-
}), s =
|
|
4541
|
+
}), s = C(() => l.min <= l.max && l.step > 0), r = I(!1);
|
|
4542
4542
|
return o({
|
|
4543
4543
|
focus() {
|
|
4544
4544
|
var i;
|
|
@@ -4729,24 +4729,24 @@ const Hr = { class: "cl-flex cl-justify-between" }, Wr = { class: "cl-w-full" },
|
|
|
4729
4729
|
},
|
|
4730
4730
|
emits: ["update:model-value", "click", "focus", "input", "change", "validated"],
|
|
4731
4731
|
setup(t, { expose: o, emit: l }) {
|
|
4732
|
-
const e = t, n = l, a = I(null), d = I(null), s = I(!1), r = I(!1), i =
|
|
4732
|
+
const e = t, n = l, a = I(null), d = I(null), s = I(!1), r = I(!1), i = C(() => {
|
|
4733
4733
|
var B;
|
|
4734
4734
|
let y = e.isRequired;
|
|
4735
4735
|
return r.value && ((B = g.value) == null ? void 0 : B.toString().trim()) === "" && e.requiredText.trim() !== "" && (y = !1), !e.hideRequiredAsterisk && y;
|
|
4736
|
-
}), u =
|
|
4736
|
+
}), u = C(() => e.placeholderText.trim() !== "" ? e.placeholderText : e.label), c = I(0), g = C({
|
|
4737
4737
|
get: () => e.modelValue,
|
|
4738
4738
|
set: (y) => w(y, !1)
|
|
4739
|
-
}),
|
|
4739
|
+
}), b = C({
|
|
4740
4740
|
get: () => e.modelValue,
|
|
4741
4741
|
set: (y) => ne(y)
|
|
4742
|
-
}),
|
|
4742
|
+
}), h = C(() => typeof e.min == "number" ? e.min.toString() : e.min), $ = C(() => typeof e.max == "number" ? e.max.toString() : e.max), q = C(() => typeof e.min == "number" || e.min === null ? e.min : parseFloat(e.min)), T = C(() => typeof e.max == "number" || e.max === null ? e.max : parseFloat(e.max)), L = C(() => e.messageWhenValid.trim() !== "" ? e.messageWhenValid : ""), S = I(!0), P = I(!0), x = I([]), E = C(() => {
|
|
4743
4743
|
var y, B;
|
|
4744
4744
|
return [
|
|
4745
4745
|
...((y = x.value) == null ? void 0 : y.filter((K) => ((K == null ? void 0 : K.length) ?? 0) > 0)) ?? [],
|
|
4746
4746
|
...((B = e.externalErrors) == null ? void 0 : B.filter((K) => ((K == null ? void 0 : K.length) ?? 0) > 0)) ?? []
|
|
4747
4747
|
].join(`
|
|
4748
4748
|
`);
|
|
4749
|
-
}), Y =
|
|
4749
|
+
}), Y = C(() => ({
|
|
4750
4750
|
currency: "GBP",
|
|
4751
4751
|
locale: "en-GB",
|
|
4752
4752
|
valueRange: {
|
|
@@ -4944,8 +4944,8 @@ const Hr = { class: "cl-flex cl-justify-between" }, Wr = { class: "cl-w-full" },
|
|
|
4944
4944
|
])) : m(El)(y.inputType) ? (p(), H(m(Dr), ee({ key: 2 }, y.$attrs, {
|
|
4945
4945
|
ref_key: "inputElement",
|
|
4946
4946
|
ref: a,
|
|
4947
|
-
date:
|
|
4948
|
-
"onUpdate:date": B[9] || (B[9] = (K) =>
|
|
4947
|
+
date: b.value,
|
|
4948
|
+
"onUpdate:date": B[9] || (B[9] = (K) => b.value = K),
|
|
4949
4949
|
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", {
|
|
4950
4950
|
"hover:cl-border-grey-3": !y.disabled && y.inputType !== "dateRange",
|
|
4951
4951
|
"!cl-border-danger-default": !S.value,
|
|
@@ -4955,7 +4955,7 @@ const Hr = { class: "cl-flex cl-justify-between" }, Wr = { class: "cl-w-full" },
|
|
|
4955
4955
|
required: y.isRequired,
|
|
4956
4956
|
type: m(Pr)(y.inputType),
|
|
4957
4957
|
"time-zone": y.timeZone,
|
|
4958
|
-
min:
|
|
4958
|
+
min: h.value,
|
|
4959
4959
|
max: $.value,
|
|
4960
4960
|
placeholder: u.value,
|
|
4961
4961
|
"initial-date": y.initialDate,
|
|
@@ -4970,7 +4970,7 @@ const Hr = { class: "cl-flex cl-justify-between" }, Wr = { class: "cl-w-full" },
|
|
|
4970
4970
|
value: g.value,
|
|
4971
4971
|
"onUpdate:value": B[11] || (B[11] = (K) => g.value = K),
|
|
4972
4972
|
min: q.value ?? 0,
|
|
4973
|
-
max:
|
|
4973
|
+
max: T.value ?? 1e3,
|
|
4974
4974
|
step: y.step,
|
|
4975
4975
|
placeholder: u.value,
|
|
4976
4976
|
"enforce-step": !0,
|
|
@@ -5032,10 +5032,10 @@ const ns = {
|
|
|
5032
5032
|
},
|
|
5033
5033
|
emits: ["language-select"],
|
|
5034
5034
|
setup(t, { emit: o }) {
|
|
5035
|
-
const l = t, e = o, { locale: n } = ce(), a = I(!1), d =
|
|
5035
|
+
const l = t, e = o, { locale: n } = ce(), a = I(!1), d = C(() => l.supportedLanguages.find((u) => u.localeCode === n.value) ?? r(l.supportedLanguages, n.value) ?? l.defaultLangauge), s = C(() => l.supportedLanguages.filter((u) => nl(u)).sort((u, c) => u.nativeName > c.nativeName ? 1 : c.nativeName > u.nativeName ? -1 : 0));
|
|
5036
5036
|
function r(u, c) {
|
|
5037
5037
|
const g = c.split("-")[0];
|
|
5038
|
-
return u.find((
|
|
5038
|
+
return u.find((h) => h.localeCode.split("-")[0] === g) ?? null;
|
|
5039
5039
|
}
|
|
5040
5040
|
function i() {
|
|
5041
5041
|
l.disabled || (a.value = !a.value);
|
|
@@ -5058,12 +5058,12 @@ const ns = {
|
|
|
5058
5058
|
D(qe, { name: "fade" }, {
|
|
5059
5059
|
default: R(() => [
|
|
5060
5060
|
Q(f("div", rs, [
|
|
5061
|
-
(p(!0), v(_, null, ue(s.value, (g,
|
|
5062
|
-
key:
|
|
5061
|
+
(p(!0), v(_, null, ue(s.value, (g, b) => (p(), v("div", {
|
|
5062
|
+
key: b,
|
|
5063
5063
|
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",
|
|
5064
5064
|
"data-localename": g.name,
|
|
5065
5065
|
"data-localecode": g.localeCode,
|
|
5066
|
-
onClick: (
|
|
5066
|
+
onClick: (h) => {
|
|
5067
5067
|
n.value = g.localeCode, i(), e("language-select", g.localeCode);
|
|
5068
5068
|
}
|
|
5069
5069
|
}, [
|
|
@@ -5091,35 +5091,35 @@ const ns = {
|
|
|
5091
5091
|
},
|
|
5092
5092
|
emits: ["login", "update:errors"],
|
|
5093
5093
|
setup(t, { emit: o }) {
|
|
5094
|
-
const l = o, { t: e } = ce(), n = I(""), a = I(""), d = I("password"), s =
|
|
5095
|
-
function
|
|
5096
|
-
const
|
|
5094
|
+
const l = o, { t: e } = ce(), n = I(""), a = I(""), d = I("password"), s = C(() => ct(n.value)), r = C(() => n.value ? s.value ? null : [e("input.valueNotValidEmail", { label: e("login.email") })] : []);
|
|
5095
|
+
function i() {
|
|
5096
|
+
const c = {
|
|
5097
5097
|
username: n.value,
|
|
5098
5098
|
password: a.value
|
|
5099
5099
|
};
|
|
5100
|
-
l("login",
|
|
5100
|
+
l("login", c);
|
|
5101
5101
|
}
|
|
5102
|
-
function
|
|
5102
|
+
function u() {
|
|
5103
5103
|
l("update:errors", []);
|
|
5104
5104
|
}
|
|
5105
5105
|
return oe([
|
|
5106
5106
|
n,
|
|
5107
5107
|
a
|
|
5108
|
-
],
|
|
5108
|
+
], u), (c, g) => (p(), v("div", us, [
|
|
5109
5109
|
f("div", ds, [
|
|
5110
|
-
M(
|
|
5110
|
+
M(c.$slots, "background")
|
|
5111
5111
|
]),
|
|
5112
5112
|
f("form", ps, [
|
|
5113
5113
|
f("div", fs, [
|
|
5114
|
-
M(
|
|
5114
|
+
M(c.$slots, "logo")
|
|
5115
5115
|
]),
|
|
5116
|
-
|
|
5117
|
-
M(
|
|
5116
|
+
c.$slots["language-switcher"] ? (p(), v("div", ms, [
|
|
5117
|
+
M(c.$slots, "language-switcher")
|
|
5118
5118
|
])) : z("", !0),
|
|
5119
5119
|
f("div", {
|
|
5120
5120
|
class: F(["cl-gap-y-4 cl-grid cl-grid-cols-1 lg:cl-gap-x-2 lg:cl-grid-cols-8", {
|
|
5121
|
-
"cl-col-span-7": !
|
|
5122
|
-
"cl-col-span-6":
|
|
5121
|
+
"cl-col-span-7": !c.$slots["language-switcher"],
|
|
5122
|
+
"cl-col-span-6": c.$slots["language-switcher"]
|
|
5123
5123
|
}])
|
|
5124
5124
|
}, [
|
|
5125
5125
|
f("div", gs, [
|
|
@@ -5133,13 +5133,13 @@ const ns = {
|
|
|
5133
5133
|
D(Ae, {
|
|
5134
5134
|
id: "cl-ui-login-usernameinput",
|
|
5135
5135
|
modelValue: n.value,
|
|
5136
|
-
"onUpdate:modelValue":
|
|
5136
|
+
"onUpdate:modelValue": g[0] || (g[0] = (b) => n.value = b),
|
|
5137
5137
|
modelModifiers: { trim: !0 },
|
|
5138
5138
|
class: F(["cl-border-2 cl-outline-none cl-p-2 cl-pl-9 cl-text-grey-5 cl-text-sm", {
|
|
5139
5139
|
"!cl-border-primary-default hover:!cl-border-grey-3 focus-within:!cl-border-link-light": n.value !== "" && s.value,
|
|
5140
5140
|
"!cl-border-danger-dark hover:!cl-border-grey-3 focus-within:!cl-border-link-light": n.value !== "" && !s.value
|
|
5141
5141
|
}]),
|
|
5142
|
-
errors:
|
|
5142
|
+
errors: r.value,
|
|
5143
5143
|
type: "email",
|
|
5144
5144
|
placeholder: m(e)("login.email"),
|
|
5145
5145
|
autocomplete: "username"
|
|
@@ -5164,7 +5164,7 @@ const ns = {
|
|
|
5164
5164
|
class: "cl-absolute cl-cursor-pointer cl-right-4 cl-top-3 cl-z-10",
|
|
5165
5165
|
icon: "ph:eye",
|
|
5166
5166
|
size: 18,
|
|
5167
|
-
onClick:
|
|
5167
|
+
onClick: g[1] || (g[1] = (b) => d.value = "text")
|
|
5168
5168
|
}, null, 512), [
|
|
5169
5169
|
[te, d.value === "password"]
|
|
5170
5170
|
]),
|
|
@@ -5172,14 +5172,14 @@ const ns = {
|
|
|
5172
5172
|
class: "cl-absolute cl-cursor-pointer cl-right-4 cl-top-3 cl-z-10",
|
|
5173
5173
|
icon: "ph:eye-slash",
|
|
5174
5174
|
size: 18,
|
|
5175
|
-
onClick:
|
|
5175
|
+
onClick: g[2] || (g[2] = (b) => d.value = "password")
|
|
5176
5176
|
}, null, 512), [
|
|
5177
5177
|
[te, d.value === "text"]
|
|
5178
5178
|
]),
|
|
5179
5179
|
D(Ae, {
|
|
5180
5180
|
id: "cl-ui-login-passwordinput",
|
|
5181
5181
|
modelValue: a.value,
|
|
5182
|
-
"onUpdate:modelValue":
|
|
5182
|
+
"onUpdate:modelValue": g[3] || (g[3] = (b) => a.value = b),
|
|
5183
5183
|
class: F(["cl-border-2 cl-outline-none cl-p-2 cl-px-9 cl-text-grey-5 cl-text-sm", {
|
|
5184
5184
|
"!cl-border-primary-default hover:!cl-border-grey-3 focus-within:!cl-border-link-light": a.value
|
|
5185
5185
|
}]),
|
|
@@ -5196,16 +5196,16 @@ const ns = {
|
|
|
5196
5196
|
]),
|
|
5197
5197
|
f("div", {
|
|
5198
5198
|
class: F(["cl-col-span-2", {
|
|
5199
|
-
"cl-mt-1.5 cl-mb-1 md:cl-mt-0.5 md:cl-mb-7 lg:cl-mb-0":
|
|
5199
|
+
"cl-mt-1.5 cl-mb-1 md:cl-mt-0.5 md:cl-mb-7 lg:cl-mb-0": c.loading
|
|
5200
5200
|
}])
|
|
5201
5201
|
}, [
|
|
5202
5202
|
D(ye, {
|
|
5203
5203
|
id: "cl-ui-login-loginbutton",
|
|
5204
5204
|
class: "cl-w-full",
|
|
5205
5205
|
colour: "blue",
|
|
5206
|
-
loading:
|
|
5206
|
+
loading: c.loading,
|
|
5207
5207
|
disabled: !s.value || a.value === "",
|
|
5208
|
-
onClick: ae(
|
|
5208
|
+
onClick: ae(i, ["prevent"])
|
|
5209
5209
|
}, {
|
|
5210
5210
|
default: R(() => [
|
|
5211
5211
|
pe(N(m(e)("login.login")), 1)
|
|
@@ -5216,16 +5216,16 @@ const ns = {
|
|
|
5216
5216
|
], 2),
|
|
5217
5217
|
D(qe, { name: "cl-grow-down" }, {
|
|
5218
5218
|
default: R(() => {
|
|
5219
|
-
var
|
|
5219
|
+
var b;
|
|
5220
5220
|
return [
|
|
5221
5221
|
Q(f("span", Cs, [
|
|
5222
|
-
(p(!0), v(_, null, ue(
|
|
5222
|
+
(p(!0), v(_, null, ue(c.errors, (h, $) => (p(), v("div", {
|
|
5223
5223
|
id: "cl-ui-login-errors",
|
|
5224
|
-
key:
|
|
5224
|
+
key: $,
|
|
5225
5225
|
class: "cl-font-semibold"
|
|
5226
5226
|
}, N(h), 1))), 128))
|
|
5227
5227
|
], 512), [
|
|
5228
|
-
[te, (
|
|
5228
|
+
[te, (b = c.errors) == null ? void 0 : b.length]
|
|
5229
5229
|
])
|
|
5230
5230
|
];
|
|
5231
5231
|
}),
|
|
@@ -5253,20 +5253,20 @@ const ns = {
|
|
|
5253
5253
|
},
|
|
5254
5254
|
emits: ["pinned-state", "open-state"],
|
|
5255
5255
|
setup(t, { expose: o, emit: l }) {
|
|
5256
|
-
const e = l, n = I([]), a =
|
|
5256
|
+
const e = l, n = I([]), a = C(() => n.value.filter((q) => q.open === !0).length > 0);
|
|
5257
5257
|
function d(q) {
|
|
5258
|
-
let
|
|
5259
|
-
return
|
|
5258
|
+
let T = n.value.find((L) => L.id === q);
|
|
5259
|
+
return T || (T = {
|
|
5260
5260
|
id: q,
|
|
5261
5261
|
open: !1
|
|
5262
|
-
}, n.value.push(
|
|
5262
|
+
}, n.value.push(T)), T.open;
|
|
5263
5263
|
}
|
|
5264
5264
|
function s(q) {
|
|
5265
|
-
const
|
|
5265
|
+
const T = n.value.find((S) => S.id === q);
|
|
5266
5266
|
let L;
|
|
5267
|
-
|
|
5267
|
+
T && (T.open = !T.open, T.open && (L = T.id), n.value.forEach((S) => {
|
|
5268
5268
|
S.id !== q && (S.open = !1);
|
|
5269
|
-
})), e("open-state", !!(
|
|
5269
|
+
})), e("open-state", !!(T != null && T.open), L);
|
|
5270
5270
|
}
|
|
5271
5271
|
const r = bt();
|
|
5272
5272
|
oe(
|
|
@@ -5282,8 +5282,8 @@ const ns = {
|
|
|
5282
5282
|
function g() {
|
|
5283
5283
|
i.value = !i.value, e("pinned-state", i.value), u.value = !0, c();
|
|
5284
5284
|
}
|
|
5285
|
-
const
|
|
5286
|
-
function
|
|
5285
|
+
const b = I();
|
|
5286
|
+
function h(q) {
|
|
5287
5287
|
g(), typeof q == "number" && s(q);
|
|
5288
5288
|
}
|
|
5289
5289
|
function $() {
|
|
@@ -5291,12 +5291,12 @@ const ns = {
|
|
|
5291
5291
|
q.open = !1;
|
|
5292
5292
|
}), e("open-state", !1, void 0));
|
|
5293
5293
|
}
|
|
5294
|
-
return cl(
|
|
5294
|
+
return cl(b, $), o({
|
|
5295
5295
|
closeNavigation: $,
|
|
5296
|
-
restorePinnedNavigation:
|
|
5297
|
-
}), (q,
|
|
5296
|
+
restorePinnedNavigation: h
|
|
5297
|
+
}), (q, T) => (p(), v("div", {
|
|
5298
5298
|
ref_key: "navElement",
|
|
5299
|
-
ref:
|
|
5299
|
+
ref: b,
|
|
5300
5300
|
class: "cl-flex cl-flex-nowrap cl-relative"
|
|
5301
5301
|
}, [
|
|
5302
5302
|
f("div", {
|
|
@@ -5320,7 +5320,7 @@ const ns = {
|
|
|
5320
5320
|
f("div", Ds, [
|
|
5321
5321
|
f("span", {
|
|
5322
5322
|
class: "cl-absolute cl-cursor-pointer cl-hidden cl-right-0 cl-top-1.5 lg:cl-block",
|
|
5323
|
-
onClick:
|
|
5323
|
+
onClick: T[0] || (T[0] = () => g())
|
|
5324
5324
|
}, [
|
|
5325
5325
|
i.value ? (p(), H(m(G), {
|
|
5326
5326
|
key: 1,
|
|
@@ -5413,45 +5413,45 @@ const Ws = /* @__PURE__ */ we(js, [["render", Hs]]), Zs = /* @__PURE__ */ j({
|
|
|
5413
5413
|
},
|
|
5414
5414
|
emits: ["tab-opened"],
|
|
5415
5415
|
setup(t, { expose: o, emit: l }) {
|
|
5416
|
-
const e = t, n = l, a = I([]), d =
|
|
5416
|
+
const e = t, n = l, a = I([]), d = C(() => a.value.filter((T) => T.open).length > 0), s = I(), r = I(!1), i = I(!1), u = C(() => e.layout === "horizontal");
|
|
5417
5417
|
function c() {
|
|
5418
5418
|
if (s.value) {
|
|
5419
|
-
const
|
|
5420
|
-
r.value = s.value.scrollLeft > 0, i.value = s.value.scrollLeft <
|
|
5419
|
+
const T = s.value.scrollWidth - s.value.clientWidth;
|
|
5420
|
+
r.value = s.value.scrollLeft > 0, i.value = s.value.scrollLeft < T;
|
|
5421
5421
|
} else
|
|
5422
5422
|
r.value = !1, i.value = !1;
|
|
5423
5423
|
}
|
|
5424
5424
|
function g() {
|
|
5425
5425
|
u.value && (c(), window.addEventListener("resize", c));
|
|
5426
5426
|
}
|
|
5427
|
-
function
|
|
5427
|
+
function b(T) {
|
|
5428
5428
|
if (s.value) {
|
|
5429
5429
|
const L = s.value.scrollWidth / 5;
|
|
5430
5430
|
let S = L;
|
|
5431
|
-
|
|
5431
|
+
T === "left" && (S = -L), s.value.scroll(s.value.scrollLeft + S, 0);
|
|
5432
5432
|
}
|
|
5433
5433
|
}
|
|
5434
|
-
function
|
|
5435
|
-
let L = a.value.find((S) => S.id ===
|
|
5434
|
+
function h(T) {
|
|
5435
|
+
let L = a.value.find((S) => S.id === T);
|
|
5436
5436
|
return L || (L = {
|
|
5437
|
-
id:
|
|
5437
|
+
id: T,
|
|
5438
5438
|
open: !1
|
|
5439
5439
|
}, a.value.push(L)), L.open;
|
|
5440
5440
|
}
|
|
5441
|
-
function $(
|
|
5442
|
-
const L = a.value.find((S) => S.id ===
|
|
5441
|
+
function $(T) {
|
|
5442
|
+
const L = a.value.find((S) => S.id === T);
|
|
5443
5443
|
L && L.open === !1 && (L.open = !L.open, a.value.forEach((S) => {
|
|
5444
|
-
S.id !==
|
|
5445
|
-
}), n("tab-opened",
|
|
5444
|
+
S.id !== T && (S.open = !1);
|
|
5445
|
+
}), n("tab-opened", T));
|
|
5446
5446
|
}
|
|
5447
|
-
function q(
|
|
5448
|
-
typeof
|
|
5447
|
+
function q(T) {
|
|
5448
|
+
typeof T == "number" && $(T);
|
|
5449
5449
|
}
|
|
5450
5450
|
return Pe(() => {
|
|
5451
5451
|
g(), $(a.value[0].id);
|
|
5452
5452
|
}), _e(() => window.removeEventListener("resize", c)), o({
|
|
5453
5453
|
setTab: q
|
|
5454
|
-
}), (
|
|
5454
|
+
}), (T, L) => (p(), v("div", {
|
|
5455
5455
|
class: F(["cl-w-full", {
|
|
5456
5456
|
"cl-flex cl-flex-row cl-gap-4 xl:cl-gap-6 cl-h-full": u.value === !1
|
|
5457
5457
|
}])
|
|
@@ -5467,7 +5467,7 @@ const Ws = /* @__PURE__ */ we(js, [["render", Hs]]), Zs = /* @__PURE__ */ j({
|
|
|
5467
5467
|
r.value && u.value ? (p(), v("div", {
|
|
5468
5468
|
key: 0,
|
|
5469
5469
|
class: "cl-bg-white cl-cursor-pointer cl-float-left cl-h-11 cl-w-4",
|
|
5470
|
-
onClick: L[0] || (L[0] = (S) =>
|
|
5470
|
+
onClick: L[0] || (L[0] = (S) => b("left"))
|
|
5471
5471
|
}, [
|
|
5472
5472
|
D(m(G), {
|
|
5473
5473
|
icon: "ph:caret-left",
|
|
@@ -5484,12 +5484,12 @@ const Ws = /* @__PURE__ */ we(js, [["render", Hs]]), Zs = /* @__PURE__ */ j({
|
|
|
5484
5484
|
}]),
|
|
5485
5485
|
onScrollPassive: c
|
|
5486
5486
|
}, [
|
|
5487
|
-
M(
|
|
5487
|
+
M(T.$slots, "headings", fe(ve({ isTabOpen: h, toggleOpen: $, colour: T.colour, layout: T.layout })))
|
|
5488
5488
|
], 34),
|
|
5489
5489
|
i.value && u.value ? (p(), v("div", {
|
|
5490
5490
|
key: 1,
|
|
5491
5491
|
class: "cl-bg-white cl-cursor-pointer cl-float-right cl-h-11 cl-relative cl-w-4",
|
|
5492
|
-
onClick: L[1] || (L[1] = (S) =>
|
|
5492
|
+
onClick: L[1] || (L[1] = (S) => b("right"))
|
|
5493
5493
|
}, [
|
|
5494
5494
|
D(m(G), {
|
|
5495
5495
|
icon: "ph:caret-right",
|
|
@@ -5498,7 +5498,7 @@ const Ws = /* @__PURE__ */ we(js, [["render", Hs]]), Zs = /* @__PURE__ */ j({
|
|
|
5498
5498
|
])) : z("", !0)
|
|
5499
5499
|
], 2),
|
|
5500
5500
|
Q(f("div", null, [
|
|
5501
|
-
M(
|
|
5501
|
+
M(T.$slots, "content", fe(ve({ isTabOpen: h })))
|
|
5502
5502
|
], 512), [
|
|
5503
5503
|
[te, d.value]
|
|
5504
5504
|
])
|
|
@@ -5514,7 +5514,7 @@ const Ws = /* @__PURE__ */ we(js, [["render", Hs]]), Zs = /* @__PURE__ */ j({
|
|
|
5514
5514
|
layout: { default: "horizontal" }
|
|
5515
5515
|
},
|
|
5516
5516
|
setup(t) {
|
|
5517
|
-
const o = t, l =
|
|
5517
|
+
const o = t, l = C(() => o.layout === "horizontal");
|
|
5518
5518
|
return (e, n) => (p(), v("div", {
|
|
5519
5519
|
class: F(["cl-flex cl-font-bold cl-items-center cl-px-4 cl-py-2 cl-whitespace-nowrap xl:cl-px-6 xl:cl-py-3 xl:cl-text-lg", {
|
|
5520
5520
|
"cl-border-b-4": l.value,
|
|
@@ -5575,8 +5575,8 @@ const Ws = /* @__PURE__ */ we(js, [["render", Hs]]), Zs = /* @__PURE__ */ j({
|
|
|
5575
5575
|
function n(c) {
|
|
5576
5576
|
var g;
|
|
5577
5577
|
if (l.disabled === !1) {
|
|
5578
|
-
const
|
|
5579
|
-
e("files-uploaded",
|
|
5578
|
+
const b = [...(g = c == null ? void 0 : c.dataTransfer) == null ? void 0 : g.files];
|
|
5579
|
+
e("files-uploaded", b), u();
|
|
5580
5580
|
}
|
|
5581
5581
|
}
|
|
5582
5582
|
function a(c) {
|
|
@@ -5614,8 +5614,8 @@ const Ws = /* @__PURE__ */ we(js, [["render", Hs]]), Zs = /* @__PURE__ */ j({
|
|
|
5614
5614
|
"cl-bg-opacity-10 hover:cl-bg-opacity-40": s.value === !1 && c.disabled === !1
|
|
5615
5615
|
}],
|
|
5616
5616
|
onDrop: ae(n, ["prevent"]),
|
|
5617
|
-
onDragenter: g[0] || (g[0] = (
|
|
5618
|
-
onDragleave: g[1] || (g[1] = (
|
|
5617
|
+
onDragenter: g[0] || (g[0] = (b) => s.value = !0),
|
|
5618
|
+
onDragleave: g[1] || (g[1] = (b) => s.value = !1)
|
|
5619
5619
|
}), [
|
|
5620
5620
|
f("input", {
|
|
5621
5621
|
ref_key: "fileRefDragDrop",
|
|
@@ -5663,7 +5663,7 @@ const Ws = /* @__PURE__ */ we(js, [["render", Hs]]), Zs = /* @__PURE__ */ j({
|
|
|
5663
5663
|
function d(r) {
|
|
5664
5664
|
Array.isArray(e.value) && (e.value.includes(r) ? s.value === !0 && e.value.splice(e.value.indexOf(r), 1) : e.value.push(r));
|
|
5665
5665
|
}
|
|
5666
|
-
const s =
|
|
5666
|
+
const s = C(() => {
|
|
5667
5667
|
var r;
|
|
5668
5668
|
return Array.isArray(e.value) ? l.required === !1 || (((r = e.value) == null ? void 0 : r.length) ?? 0) > 1 : !l.required;
|
|
5669
5669
|
});
|