@citruslime/ui 2.4.1-beta.3 → 2.4.1-beta.4
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 +1179 -1174
- package/dist/citrus-lime-ui.umd.js +2 -2
- package/dist/components/combo-box/cl-ui-combo-box.vue.d.ts +10 -0
- package/dist/components/combo-box/search-container/cl-ui-combo-box-search.vue.d.ts +2 -0
- package/dist/components/header/cl-ui-header.vue.d.ts +15 -2
- package/dist/components/header/menu/cl-ui-header-menu.vue.d.ts +2 -6
- package/package.json +1 -1
|
@@ -1,36 +1,36 @@
|
|
|
1
1
|
import { Icon as I } from "@iconify/vue";
|
|
2
|
-
import { defineComponent as
|
|
2
|
+
import { defineComponent as M, ref as A, openBlock as u, createElementBlock as v, renderSlot as j, normalizeProps as le, guardReactiveProps as ne, Fragment as F, createElementVNode as p, normalizeClass as _, createVNode as k, unref as d, Transition as me, withCtx as P, withDirectives as L, mergeProps as se, vShow as H, createBlock as V, Teleport as _e, renderList as Q, toDisplayString as T, createCommentVNode as N, nextTick as ge, toHandlers as ll, withModifiers as W, computed as S, watch as K, normalizeStyle as Ze, vModelText as tl, onMounted as Ae, vModelDynamic as ol, withKeys as we, onUnmounted as Ie, resolveComponent as nl, createTextVNode as ee, watchEffect as sl, createSlots as Re } from "vue";
|
|
3
3
|
import { generateStringId as al } from "@citruslime/utils";
|
|
4
4
|
import { onClickOutside as ze, useTimeoutFn as We, useDebounceFn as Ke, useWindowSize as rl } from "@vueuse/core";
|
|
5
|
-
import { createI18n as il, useI18n as
|
|
6
|
-
import { DateTime as
|
|
5
|
+
import { createI18n as il, useI18n as oe } from "vue-i18n";
|
|
6
|
+
import { DateTime as $e } from "luxon";
|
|
7
7
|
import { DatePicker as Me } from "v-calendar";
|
|
8
|
-
import { useDebouncer as cl, copy as
|
|
9
|
-
const ul = { class: "cl-overflow-hidden" }, dl = /* @__PURE__ */
|
|
8
|
+
import { useDebouncer as cl, copy as re } from "@citruslime/vue-utils";
|
|
9
|
+
const ul = { class: "cl-overflow-hidden" }, dl = /* @__PURE__ */ M({
|
|
10
10
|
__name: "cl-ui-accordion",
|
|
11
11
|
props: {
|
|
12
12
|
exclusive: { type: Boolean, default: !1 }
|
|
13
13
|
},
|
|
14
14
|
setup(t) {
|
|
15
|
-
const o = t,
|
|
16
|
-
function
|
|
17
|
-
let s =
|
|
15
|
+
const o = t, l = A([]);
|
|
16
|
+
function e(m) {
|
|
17
|
+
let s = l.value.find((a) => a.id === m);
|
|
18
18
|
return s || (s = {
|
|
19
|
-
id:
|
|
19
|
+
id: m,
|
|
20
20
|
open: !1
|
|
21
|
-
},
|
|
21
|
+
}, l.value.push(s)), s.open;
|
|
22
22
|
}
|
|
23
|
-
function n(
|
|
24
|
-
const s =
|
|
25
|
-
s && (o.exclusive &&
|
|
26
|
-
a.id !==
|
|
23
|
+
function n(m) {
|
|
24
|
+
const s = l.value.find((a) => a.id === m);
|
|
25
|
+
s && (o.exclusive && l.value.forEach((a) => {
|
|
26
|
+
a.id !== m && (a.open = !1);
|
|
27
27
|
}), s.open = !s.open);
|
|
28
28
|
}
|
|
29
|
-
return (
|
|
30
|
-
|
|
29
|
+
return (m, s) => (u(), v("div", ul, [
|
|
30
|
+
j(m.$slots, "default", le(ne({ isItemOpen: e, toggleItem: n })))
|
|
31
31
|
]));
|
|
32
32
|
}
|
|
33
|
-
}), pl = { class: "cl-absolute cl-left-5 cl-top-5" }, fl = { class: "cl-font-semibold cl-ml-10 cl-p-4 cl-select-none cl-text-grey-5" }, ml = { class: "cl-overflow-hidden" }, gl = /* @__PURE__ */
|
|
33
|
+
}), pl = { class: "cl-absolute cl-left-5 cl-top-5" }, fl = { class: "cl-font-semibold cl-ml-10 cl-p-4 cl-select-none cl-text-grey-5" }, ml = { class: "cl-overflow-hidden" }, gl = /* @__PURE__ */ M({
|
|
34
34
|
inheritAttrs: !1,
|
|
35
35
|
__name: "cl-ui-accordion-item",
|
|
36
36
|
props: {
|
|
@@ -41,20 +41,20 @@ const ul = { class: "cl-overflow-hidden" }, dl = /* @__PURE__ */ U({
|
|
|
41
41
|
toggle: null
|
|
42
42
|
},
|
|
43
43
|
setup(t, { emit: o }) {
|
|
44
|
-
const
|
|
45
|
-
function
|
|
46
|
-
|
|
44
|
+
const l = t;
|
|
45
|
+
function e() {
|
|
46
|
+
l.disabled || o("toggle");
|
|
47
47
|
}
|
|
48
|
-
return (n,
|
|
49
|
-
|
|
48
|
+
return (n, m) => (u(), v(F, null, [
|
|
49
|
+
p("div", {
|
|
50
50
|
class: _(["cl-border-b cl-border-grey-1 cl-relative", {
|
|
51
51
|
"cl-bg-grey-0": n.disabled,
|
|
52
52
|
"cl-cursor-pointer": !n.disabled
|
|
53
53
|
}]),
|
|
54
|
-
onClick:
|
|
54
|
+
onClick: e
|
|
55
55
|
}, [
|
|
56
|
-
|
|
57
|
-
|
|
56
|
+
p("div", pl, [
|
|
57
|
+
k(d(I), {
|
|
58
58
|
class: _(["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
|
}]),
|
|
@@ -62,15 +62,15 @@ const ul = { class: "cl-overflow-hidden" }, dl = /* @__PURE__ */ U({
|
|
|
62
62
|
width: "20"
|
|
63
63
|
}, null, 8, ["class"])
|
|
64
64
|
]),
|
|
65
|
-
|
|
66
|
-
|
|
65
|
+
p("div", fl, [
|
|
66
|
+
j(n.$slots, "title")
|
|
67
67
|
])
|
|
68
68
|
], 2),
|
|
69
|
-
|
|
70
|
-
|
|
69
|
+
p("div", ml, [
|
|
70
|
+
k(me, { name: "grow-down" }, {
|
|
71
71
|
default: P(() => [
|
|
72
|
-
L(
|
|
73
|
-
|
|
72
|
+
L(p("div", se(n.$attrs, { class: "cl-ml-10 cl-p-4" }), [
|
|
73
|
+
j(n.$slots, "default")
|
|
74
74
|
], 16), [
|
|
75
75
|
[H, n.open]
|
|
76
76
|
])
|
|
@@ -80,29 +80,29 @@ const ul = { class: "cl-overflow-hidden" }, dl = /* @__PURE__ */ U({
|
|
|
80
80
|
])
|
|
81
81
|
], 64));
|
|
82
82
|
}
|
|
83
|
-
}),
|
|
84
|
-
const
|
|
85
|
-
for (const [
|
|
86
|
-
e
|
|
87
|
-
return
|
|
83
|
+
}), de = (t, o) => {
|
|
84
|
+
const l = t.__vccOpts || t;
|
|
85
|
+
for (const [e, n] of o)
|
|
86
|
+
l[e] = n;
|
|
87
|
+
return l;
|
|
88
88
|
}, vl = {}, bl = { class: "cl-border-b cl-border-grey-1 cl-font-semibold cl-pl-14 cl-pr-4 cl-py-2 cl-text-grey-3 cl-text-sm" };
|
|
89
89
|
function hl(t, o) {
|
|
90
90
|
return u(), v("div", bl, [
|
|
91
|
-
|
|
91
|
+
j(t.$slots, "default")
|
|
92
92
|
]);
|
|
93
93
|
}
|
|
94
|
-
const yl = /* @__PURE__ */
|
|
94
|
+
const yl = /* @__PURE__ */ de(vl, [["render", hl]]), qe = A([]);
|
|
95
95
|
function Ve(t) {
|
|
96
96
|
const o = {
|
|
97
97
|
id: al(),
|
|
98
98
|
...t
|
|
99
99
|
};
|
|
100
|
-
|
|
100
|
+
qe.value.push(o), setTimeout(() => Qe(o), t.duration);
|
|
101
101
|
}
|
|
102
102
|
function Qe(t) {
|
|
103
|
-
|
|
103
|
+
qe.value = qe.value.filter((o) => o.id !== t.id);
|
|
104
104
|
}
|
|
105
|
-
const wl = ["onClick"], $l = { class: "cl-flex-1 cl-select-none cl-text-ellipsis cl-w-64" }, Je = /* @__PURE__ */
|
|
105
|
+
const wl = ["onClick"], $l = { class: "cl-flex-1 cl-select-none cl-text-ellipsis cl-w-64" }, Je = /* @__PURE__ */ M({
|
|
106
106
|
inheritAttrs: !1,
|
|
107
107
|
__name: "cl-ui-notification",
|
|
108
108
|
props: {
|
|
@@ -110,8 +110,8 @@ const wl = ["onClick"], $l = { class: "cl-flex-1 cl-select-none cl-text-ellipsis
|
|
|
110
110
|
position: { default: "top-right" }
|
|
111
111
|
},
|
|
112
112
|
setup(t) {
|
|
113
|
-
return (o,
|
|
114
|
-
|
|
113
|
+
return (o, l) => (u(), V(_e, { to: o.container }, [
|
|
114
|
+
p("div", {
|
|
115
115
|
class: _(["cl-fixed cl-w-80 cl-z-40", {
|
|
116
116
|
"cl-top-5 cl-left-5": o.position === "top-left",
|
|
117
117
|
"cl-top-5 cl-left-1/2": o.position === "top-centre",
|
|
@@ -121,19 +121,19 @@ const wl = ["onClick"], $l = { class: "cl-flex-1 cl-select-none cl-text-ellipsis
|
|
|
121
121
|
"cl-bottom-5 cl-right-5": o.position === "bottom-right"
|
|
122
122
|
}])
|
|
123
123
|
}, [
|
|
124
|
-
(u(!0), v(F, null,
|
|
124
|
+
(u(!0), v(F, null, Q(d(qe), (e, n) => (u(), v("div", se(o.$attrs, {
|
|
125
125
|
key: n,
|
|
126
126
|
class: ["cl-break-words cl-cursor-pointer cl-flex cl-font-semibold cl-group cl-mb-2 cl-overflow-hidden cl-p-4 cl-rounded cl-shadow-lg cl-text-sm", {
|
|
127
|
-
"cl-bg-white":
|
|
128
|
-
"cl-bg-primary-default":
|
|
129
|
-
"cl-bg-secondary-default":
|
|
130
|
-
"cl-bg-danger-default":
|
|
131
|
-
"cl-bg-warning-default":
|
|
127
|
+
"cl-bg-white": e.colour === "default",
|
|
128
|
+
"cl-bg-primary-default": e.colour === "primary",
|
|
129
|
+
"cl-bg-secondary-default": e.colour === "secondary",
|
|
130
|
+
"cl-bg-danger-default": e.colour === "danger",
|
|
131
|
+
"cl-bg-warning-default": e.colour === "warning"
|
|
132
132
|
}],
|
|
133
|
-
onClick: (
|
|
133
|
+
onClick: (m) => d(Qe)(e)
|
|
134
134
|
}), [
|
|
135
|
-
|
|
136
|
-
|
|
135
|
+
p("span", $l, T(e.message), 1),
|
|
136
|
+
k(d(I), {
|
|
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,
|
|
@@ -143,29 +143,29 @@ const wl = ["onClick"], $l = { class: "cl-flex-1 cl-select-none cl-text-ellipsis
|
|
|
143
143
|
], 2)
|
|
144
144
|
], 8, ["to"]));
|
|
145
145
|
}
|
|
146
|
-
}), kl = { class: "cl-absolute cl-flex cl-flex-wrap cl-h-screen cl-max-h-screen cl-max-w-full cl-min-h-screen cl-min-w-full cl-w-full" }, Cl = /* @__PURE__ */
|
|
146
|
+
}), kl = { class: "cl-absolute cl-flex cl-flex-wrap cl-h-screen cl-max-h-screen cl-max-w-full cl-min-h-screen cl-min-w-full cl-w-full" }, Cl = /* @__PURE__ */ M({
|
|
147
147
|
__name: "cl-ui-app",
|
|
148
148
|
props: {
|
|
149
149
|
removePadding: { type: Boolean, default: !1 }
|
|
150
150
|
},
|
|
151
151
|
setup(t) {
|
|
152
|
-
return (o,
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
152
|
+
return (o, l) => (u(), v(F, null, [
|
|
153
|
+
k(Je),
|
|
154
|
+
p("div", kl, [
|
|
155
|
+
j(o.$slots, "header"),
|
|
156
|
+
p("div", {
|
|
157
157
|
class: _(["cl-content-start cl-flex cl-flex-nowrap cl-items-stretch cl-max-h-screen cl-relative cl-w-full", {
|
|
158
158
|
"cl-pt-20": o.$slots.header
|
|
159
159
|
}])
|
|
160
160
|
}, [
|
|
161
|
-
|
|
162
|
-
|
|
161
|
+
j(o.$slots, "navigation"),
|
|
162
|
+
p("div", {
|
|
163
163
|
class: _(["cl-grow cl-max-h-full cl-overflow-x-hidden cl-overflow-y-auto cl-overscroll-y-none cl-w-auto", {
|
|
164
164
|
"cl-pb-20 lg:cl-pb-0": o.removePadding,
|
|
165
165
|
"lg:cl-pb-8 md:cl-px-8 cl-px-2 md:cl-pt-8 cl-pt-2 cl-pb-20": !o.removePadding
|
|
166
166
|
}])
|
|
167
167
|
}, [
|
|
168
|
-
|
|
168
|
+
j(o.$slots, "default")
|
|
169
169
|
], 2)
|
|
170
170
|
], 2)
|
|
171
171
|
])
|
|
@@ -176,7 +176,7 @@ const Tl = {}, El = { class: "loading-spinner" };
|
|
|
176
176
|
function Ol(t, o) {
|
|
177
177
|
return u(), v("div", El);
|
|
178
178
|
}
|
|
179
|
-
const Se = /* @__PURE__ */
|
|
179
|
+
const Se = /* @__PURE__ */ de(Tl, [["render", Ol], ["__scopeId", "data-v-a21dc5d2"]]), ql = ["disabled"], fe = /* @__PURE__ */ M({
|
|
180
180
|
inheritAttrs: !1,
|
|
181
181
|
__name: "cl-ui-button",
|
|
182
182
|
props: {
|
|
@@ -186,39 +186,39 @@ const Se = /* @__PURE__ */ fe(Tl, [["render", Ol], ["__scopeId", "data-v-a21dc5d
|
|
|
186
186
|
disabled: { type: Boolean, default: !1 }
|
|
187
187
|
},
|
|
188
188
|
setup(t, { expose: o }) {
|
|
189
|
-
const
|
|
189
|
+
const l = A(null);
|
|
190
190
|
return o({
|
|
191
191
|
focus() {
|
|
192
|
-
|
|
192
|
+
l.value && l.value.focus();
|
|
193
193
|
}
|
|
194
|
-
}), (
|
|
195
|
-
L(
|
|
196
|
-
[H,
|
|
194
|
+
}), (e, n) => (u(), v(F, null, [
|
|
195
|
+
L(k(Se, { class: "relative" }, null, 512), [
|
|
196
|
+
[H, e.loading]
|
|
197
197
|
]),
|
|
198
|
-
L(
|
|
198
|
+
L(p("button", se(e.$attrs, {
|
|
199
199
|
ref_key: "buttonRef",
|
|
200
|
-
ref:
|
|
200
|
+
ref: l,
|
|
201
201
|
class: ["cl-align-middle cl-border cl-font-semibold cl-inline-block cl-rounded cl-select-none cl-shadow cl-text-center cl-transition-colors", {
|
|
202
|
-
"cl-py-[5px] cl-px-4 cl-text-sm":
|
|
203
|
-
"cl-py-[9px] cl-px-8 cl-text-sm":
|
|
204
|
-
"cl-px-10 cl-py-4":
|
|
205
|
-
"cl-bg-white cl-border-grey-0 hover:cl-border-grey-2 cl-text-secondary":
|
|
206
|
-
"cl-border-primary-default cl-bg-primary-default cl-text-white hover:cl-bg-primary-light hover:cl-border-primary-light":
|
|
207
|
-
"cl-border-secondary-default cl-bg-secondary-default cl-text-white hover:cl-bg-secondary-light hover:cl-border-secondary-light":
|
|
208
|
-
"cl-border-danger-default cl-bg-danger-default cl-text-white hover:cl-bg-danger-dark hover:cl-border-danger-dark":
|
|
209
|
-
"cl-border-link-default cl-bg-link-default cl-text-white hover:cl-bg-link-light hover:cl-border-link-light":
|
|
210
|
-
"cl-border-orange-default cl-bg-orange-default cl-opacity-100 cl-text-white hover:cl-bg-orange-dark hover:cl-border-orange-dark":
|
|
211
|
-
"!cl-border-grey-3 !cl-bg-grey-3 cl-text-grey-0 hover:!cl-bg-grey-3 hover:!cl-border-grey-3 cl-cursor-default":
|
|
202
|
+
"cl-py-[5px] cl-px-4 cl-text-sm": e.size === "small",
|
|
203
|
+
"cl-py-[9px] cl-px-8 cl-text-sm": e.size === "medium",
|
|
204
|
+
"cl-px-10 cl-py-4": e.size === "large",
|
|
205
|
+
"cl-bg-white cl-border-grey-0 hover:cl-border-grey-2 cl-text-secondary": e.colour === "default",
|
|
206
|
+
"cl-border-primary-default cl-bg-primary-default cl-text-white hover:cl-bg-primary-light hover:cl-border-primary-light": e.colour === "primary",
|
|
207
|
+
"cl-border-secondary-default cl-bg-secondary-default cl-text-white hover:cl-bg-secondary-light hover:cl-border-secondary-light": e.colour === "secondary",
|
|
208
|
+
"cl-border-danger-default cl-bg-danger-default cl-text-white hover:cl-bg-danger-dark hover:cl-border-danger-dark": e.colour === "danger",
|
|
209
|
+
"cl-border-link-default cl-bg-link-default cl-text-white hover:cl-bg-link-light hover:cl-border-link-light": e.colour === "blue",
|
|
210
|
+
"cl-border-orange-default cl-bg-orange-default cl-opacity-100 cl-text-white hover:cl-bg-orange-dark hover:cl-border-orange-dark": e.colour === "orange",
|
|
211
|
+
"!cl-border-grey-3 !cl-bg-grey-3 cl-text-grey-0 hover:!cl-bg-grey-3 hover:!cl-border-grey-3 cl-cursor-default": e.disabled
|
|
212
212
|
}],
|
|
213
|
-
disabled:
|
|
213
|
+
disabled: e.disabled
|
|
214
214
|
}), [
|
|
215
|
-
|
|
216
|
-
], 16,
|
|
217
|
-
[H, !
|
|
215
|
+
j(e.$slots, "default")
|
|
216
|
+
], 16, ql), [
|
|
217
|
+
[H, !e.loading]
|
|
218
218
|
])
|
|
219
219
|
], 64));
|
|
220
220
|
}
|
|
221
|
-
}),
|
|
221
|
+
}), Al = [
|
|
222
222
|
"default",
|
|
223
223
|
"primary",
|
|
224
224
|
"secondary",
|
|
@@ -229,21 +229,21 @@ const Se = /* @__PURE__ */ fe(Tl, [["render", Ol], ["__scopeId", "data-v-a21dc5d
|
|
|
229
229
|
"small",
|
|
230
230
|
"medium",
|
|
231
231
|
"large"
|
|
232
|
-
], Nl = { key: 0 }, jl = /* @__PURE__ */
|
|
232
|
+
], Nl = { key: 0 }, jl = /* @__PURE__ */ M({
|
|
233
233
|
__name: "cl-ui-card",
|
|
234
234
|
props: {
|
|
235
235
|
size: { default: "medium" },
|
|
236
236
|
hover: { type: Boolean, default: !1 }
|
|
237
237
|
},
|
|
238
238
|
setup(t) {
|
|
239
|
-
return (o,
|
|
239
|
+
return (o, l) => (u(), v("div", {
|
|
240
240
|
class: _(["cl-border cl-border-transparent cl-overflow-hidden cl-relative cl-rounded-md cl-shadow-lg cl-transition-all", {
|
|
241
241
|
"cl-cursor-pointer hover:cl-shadow-xl hover:cl-border-grey-0": o.hover
|
|
242
242
|
}])
|
|
243
243
|
}, [
|
|
244
244
|
o.$slots.image ? (u(), v("div", Nl, [
|
|
245
|
-
|
|
246
|
-
])) :
|
|
245
|
+
j(o.$slots, "image")
|
|
246
|
+
])) : N("", !0),
|
|
247
247
|
o.$slots.title ? (u(), v("div", {
|
|
248
248
|
key: 1,
|
|
249
249
|
class: _(["cl-border-grey-2 cl-font-normal", {
|
|
@@ -253,9 +253,9 @@ const Se = /* @__PURE__ */ fe(Tl, [["render", Ol], ["__scopeId", "data-v-a21dc5d
|
|
|
253
253
|
"cl-border-t": o.$slots.image
|
|
254
254
|
}])
|
|
255
255
|
}, [
|
|
256
|
-
|
|
257
|
-
], 2)) :
|
|
258
|
-
|
|
256
|
+
j(o.$slots, "title")
|
|
257
|
+
], 2)) : N("", !0),
|
|
258
|
+
p("div", {
|
|
259
259
|
class: _(["cl-border-grey-2", {
|
|
260
260
|
"cl-p-2": o.size === "small",
|
|
261
261
|
"cl-p-4": o.size === "medium",
|
|
@@ -263,7 +263,7 @@ const Se = /* @__PURE__ */ fe(Tl, [["render", Ol], ["__scopeId", "data-v-a21dc5d
|
|
|
263
263
|
"cl-border-t": o.$slots.image || o.$slots.title
|
|
264
264
|
}])
|
|
265
265
|
}, [
|
|
266
|
-
|
|
266
|
+
j(o.$slots, "default")
|
|
267
267
|
], 2),
|
|
268
268
|
o.$slots.footer ? (u(), v("div", {
|
|
269
269
|
key: 2,
|
|
@@ -273,8 +273,8 @@ const Se = /* @__PURE__ */ fe(Tl, [["render", Ol], ["__scopeId", "data-v-a21dc5d
|
|
|
273
273
|
"cl-p-6": o.size === "large"
|
|
274
274
|
}])
|
|
275
275
|
}, [
|
|
276
|
-
|
|
277
|
-
], 2)) :
|
|
276
|
+
j(o.$slots, "footer")
|
|
277
|
+
], 2)) : N("", !0)
|
|
278
278
|
], 2));
|
|
279
279
|
}
|
|
280
280
|
}), _l = [
|
|
@@ -282,7 +282,7 @@ const Se = /* @__PURE__ */ fe(Tl, [["render", Ol], ["__scopeId", "data-v-a21dc5d
|
|
|
282
282
|
"medium",
|
|
283
283
|
"large"
|
|
284
284
|
];
|
|
285
|
-
var
|
|
285
|
+
var Y = /* @__PURE__ */ ((t) => (t.CURRENCY = "currency", t.PERCENTAGE = "percentage", t.INTEGER = "integer", t.DECIMAL = "decimal", t.MULTIPLIER = "multiplier", t))(Y || {}), x = /* @__PURE__ */ ((t) => (t.SHORT_DATE = "short-date", t.SHORT_DATETIME = "short-datetime", t.DATE = "date", t.DATETIME = "datetime", t.LONG_DATE = "long-date", t.LONG_DATETIME = "long-datetime", t.TIME = "time", t.MONTH_YEAR = "month-year", t))(x || {});
|
|
286
286
|
const Il = {
|
|
287
287
|
"en-GB": {
|
|
288
288
|
comboBox: {
|
|
@@ -366,16 +366,16 @@ const Il = {
|
|
|
366
366
|
}
|
|
367
367
|
}, Rl = {
|
|
368
368
|
"en-GB": {
|
|
369
|
-
[
|
|
369
|
+
[Y.PERCENTAGE]: {
|
|
370
370
|
style: "percent"
|
|
371
371
|
},
|
|
372
|
-
[
|
|
372
|
+
[Y.INTEGER]: {
|
|
373
373
|
maximumFractionDigits: 0
|
|
374
374
|
},
|
|
375
|
-
[
|
|
375
|
+
[Y.DECIMAL]: {
|
|
376
376
|
minimumFractionDigits: 1
|
|
377
377
|
},
|
|
378
|
-
[
|
|
378
|
+
[Y.CURRENCY]: {
|
|
379
379
|
style: "currency",
|
|
380
380
|
currency: "GBP",
|
|
381
381
|
currencyDisplay: "symbol"
|
|
@@ -383,52 +383,52 @@ const Il = {
|
|
|
383
383
|
}
|
|
384
384
|
}, zl = {
|
|
385
385
|
"en-GB": {
|
|
386
|
-
[
|
|
386
|
+
[x.SHORT_DATE]: {
|
|
387
387
|
day: "numeric",
|
|
388
388
|
month: "numeric",
|
|
389
389
|
year: "2-digit"
|
|
390
390
|
},
|
|
391
|
-
[
|
|
391
|
+
[x.SHORT_DATETIME]: {
|
|
392
392
|
day: "numeric",
|
|
393
393
|
month: "numeric",
|
|
394
394
|
year: "2-digit",
|
|
395
395
|
hour: "numeric",
|
|
396
396
|
minute: "numeric"
|
|
397
397
|
},
|
|
398
|
-
[
|
|
398
|
+
[x.DATE]: {
|
|
399
399
|
day: "numeric",
|
|
400
400
|
month: "numeric",
|
|
401
401
|
year: "numeric"
|
|
402
402
|
},
|
|
403
|
-
[
|
|
403
|
+
[x.DATETIME]: {
|
|
404
404
|
day: "numeric",
|
|
405
405
|
month: "numeric",
|
|
406
406
|
year: "numeric",
|
|
407
407
|
hour: "numeric",
|
|
408
408
|
minute: "numeric"
|
|
409
409
|
},
|
|
410
|
-
[
|
|
410
|
+
[x.LONG_DATE]: {
|
|
411
411
|
day: "numeric",
|
|
412
412
|
month: "long",
|
|
413
413
|
year: "numeric"
|
|
414
414
|
},
|
|
415
|
-
[
|
|
415
|
+
[x.LONG_DATETIME]: {
|
|
416
416
|
day: "numeric",
|
|
417
417
|
month: "long",
|
|
418
418
|
year: "numeric",
|
|
419
419
|
hour: "numeric",
|
|
420
420
|
minute: "numeric"
|
|
421
421
|
},
|
|
422
|
-
[
|
|
422
|
+
[x.TIME]: {
|
|
423
423
|
hour: "numeric",
|
|
424
424
|
minute: "numeric"
|
|
425
425
|
},
|
|
426
|
-
[
|
|
426
|
+
[x.MONTH_YEAR]: {
|
|
427
427
|
month: "long",
|
|
428
428
|
year: "numeric"
|
|
429
429
|
}
|
|
430
430
|
}
|
|
431
|
-
},
|
|
431
|
+
}, X = il({
|
|
432
432
|
locale: "en-GB",
|
|
433
433
|
fallbackLocale: "en-GB",
|
|
434
434
|
messages: Il,
|
|
@@ -440,21 +440,21 @@ const Il = {
|
|
|
440
440
|
warnHtmlMessage: !1
|
|
441
441
|
});
|
|
442
442
|
function Rs(t, o) {
|
|
443
|
-
return
|
|
443
|
+
return X.global.mergeLocaleMessage(t, o), ge();
|
|
444
444
|
}
|
|
445
445
|
function zs(t, o) {
|
|
446
|
-
return
|
|
446
|
+
return X.global.mergeNumberFormat(t, o), ge();
|
|
447
447
|
}
|
|
448
448
|
function Us(t, o) {
|
|
449
|
-
return
|
|
449
|
+
return X.global.mergeDateTimeFormat(t, o), ge();
|
|
450
450
|
}
|
|
451
451
|
function Bs(t) {
|
|
452
|
-
return
|
|
452
|
+
return X.global.locale.value = t, ge();
|
|
453
453
|
}
|
|
454
|
-
const { t:
|
|
455
|
-
function Ul(t, o,
|
|
456
|
-
const n =
|
|
457
|
-
return new Promise((
|
|
454
|
+
const { t: ce } = X.global;
|
|
455
|
+
function Ul(t, o, l, e) {
|
|
456
|
+
const n = X.global.locale.value;
|
|
457
|
+
return new Promise((m) => {
|
|
458
458
|
let s = {
|
|
459
459
|
valid: !1,
|
|
460
460
|
message: ""
|
|
@@ -468,29 +468,29 @@ function Ul(t, o, e, l) {
|
|
|
468
468
|
case "tel":
|
|
469
469
|
case "text":
|
|
470
470
|
case "url":
|
|
471
|
-
a = ((
|
|
471
|
+
a = ((e == null ? void 0 : e.length) ?? 0) >= (Number(t) || 0), s = ue(a, ce("input.greaterOrEqualToCharacters", { label: l, min: t.toString() }));
|
|
472
472
|
break;
|
|
473
473
|
case "number":
|
|
474
474
|
case "range":
|
|
475
|
-
a =
|
|
475
|
+
a = e >= (Number(t) || 0), s = ue(a, ce("input.greaterOrEqualToValue", { label: l, min: t.toString() }));
|
|
476
476
|
break;
|
|
477
477
|
case "date":
|
|
478
|
-
a = new Date(
|
|
478
|
+
a = new Date(e).getTime() >= new Date(t).getTime(), s = ue(a, ce("input.afterOrEqualToValue", { label: l, min: X.global.d(new Date(t), x.DATE, n ?? X.global.locale.value) }));
|
|
479
479
|
break;
|
|
480
480
|
case "datetime":
|
|
481
|
-
a = new Date(
|
|
481
|
+
a = new Date(e).getTime() >= new Date(t).getTime(), s = ue(a, ce("input.afterOrEqualToValue", { label: l, min: X.global.d(new Date(t), x.DATETIME, n ?? X.global.locale.value) }));
|
|
482
482
|
break;
|
|
483
483
|
default:
|
|
484
484
|
s.valid = !0;
|
|
485
485
|
break;
|
|
486
486
|
}
|
|
487
487
|
}
|
|
488
|
-
|
|
488
|
+
m(s);
|
|
489
489
|
});
|
|
490
490
|
}
|
|
491
|
-
function Bl(t, o,
|
|
492
|
-
const n =
|
|
493
|
-
return new Promise((
|
|
491
|
+
function Bl(t, o, l, e) {
|
|
492
|
+
const n = X.global.locale.value;
|
|
493
|
+
return new Promise((m) => {
|
|
494
494
|
let s = {
|
|
495
495
|
valid: !1,
|
|
496
496
|
message: ""
|
|
@@ -504,39 +504,39 @@ function Bl(t, o, e, l) {
|
|
|
504
504
|
case "tel":
|
|
505
505
|
case "text":
|
|
506
506
|
case "url":
|
|
507
|
-
a = ((
|
|
507
|
+
a = ((e == null ? void 0 : e.length) ?? 0) <= (Number(t) || 0), s = ue(a, ce("input.lessOrEqualToCharacters", { label: l, max: t.toString() }));
|
|
508
508
|
break;
|
|
509
509
|
case "number":
|
|
510
510
|
case "range":
|
|
511
|
-
a =
|
|
511
|
+
a = e <= (Number(t) || 0), s = ue(a, ce("input.lessOrEqualToValue", { label: l, max: t.toString() }));
|
|
512
512
|
break;
|
|
513
513
|
case "date":
|
|
514
|
-
a = new Date(
|
|
514
|
+
a = new Date(e).getTime() <= new Date(t).getTime(), s = ue(a, ce("input.beforeOrEqualToValue", { label: l, max: X.global.d(new Date(t), x.DATE, n ?? X.global.locale.value) }));
|
|
515
515
|
break;
|
|
516
516
|
case "datetime":
|
|
517
|
-
a = new Date(
|
|
517
|
+
a = new Date(e).getTime() <= new Date(t).getTime(), s = ue(a, ce("input.beforeOrEqualToValue", { label: l, min: X.global.d(new Date(t), x.DATETIME, n ?? X.global.locale.value) }));
|
|
518
518
|
break;
|
|
519
519
|
default:
|
|
520
520
|
s.valid = !0;
|
|
521
521
|
break;
|
|
522
522
|
}
|
|
523
523
|
}
|
|
524
|
-
|
|
524
|
+
m(s);
|
|
525
525
|
});
|
|
526
526
|
}
|
|
527
527
|
function Ml(t, o) {
|
|
528
|
-
return new Promise((
|
|
529
|
-
const
|
|
530
|
-
|
|
528
|
+
return new Promise((l) => {
|
|
529
|
+
const e = o != null && o !== "" && o.toString().trim() !== "", n = ue(e, ce("input.valueIsRequired", { label: t }));
|
|
530
|
+
l(n);
|
|
531
531
|
});
|
|
532
532
|
}
|
|
533
533
|
function Vl(t, o) {
|
|
534
|
-
return new Promise((
|
|
535
|
-
const n = o === "" || /[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?\.)+[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?/.exec(o) !== null,
|
|
536
|
-
|
|
534
|
+
return new Promise((l) => {
|
|
535
|
+
const n = o === "" || /[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?\.)+[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?/.exec(o) !== null, m = ue(n, ce("input.valueNotValidEmail", { label: t }));
|
|
536
|
+
l(m);
|
|
537
537
|
});
|
|
538
538
|
}
|
|
539
|
-
function
|
|
539
|
+
function ue(t, o) {
|
|
540
540
|
return {
|
|
541
541
|
valid: t,
|
|
542
542
|
message: t ? "" : o
|
|
@@ -545,7 +545,7 @@ function pe(t, o) {
|
|
|
545
545
|
const Dl = { class: "cl-relative" }, Ll = ["value", "disabled", "placeholder"], Pl = {
|
|
546
546
|
key: 0,
|
|
547
547
|
class: "action-icon cl-absolute cl-bg-transparent cl-flex cl-right-2 cl-text-grey-4 cl-top-3.5"
|
|
548
|
-
}, Fl = /* @__PURE__ */
|
|
548
|
+
}, Fl = /* @__PURE__ */ M({
|
|
549
549
|
__name: "cl-ui-calendar-input",
|
|
550
550
|
props: {
|
|
551
551
|
date: {},
|
|
@@ -557,48 +557,48 @@ const Dl = { class: "cl-relative" }, Ll = ["value", "disabled", "placeholder"],
|
|
|
557
557
|
},
|
|
558
558
|
emits: ["clear", "reset"],
|
|
559
559
|
setup(t, { expose: o }) {
|
|
560
|
-
const
|
|
560
|
+
const l = A(null);
|
|
561
561
|
return o({
|
|
562
562
|
focus() {
|
|
563
|
-
var
|
|
564
|
-
(
|
|
563
|
+
var e;
|
|
564
|
+
(e = l.value) == null || e.focus();
|
|
565
565
|
}
|
|
566
|
-
}), (
|
|
567
|
-
|
|
566
|
+
}), (e, n) => (u(), v("div", Dl, [
|
|
567
|
+
p("input", se({
|
|
568
568
|
ref_key: "element",
|
|
569
|
-
ref:
|
|
570
|
-
},
|
|
571
|
-
value:
|
|
569
|
+
ref: l
|
|
570
|
+
}, e.$attrs, {
|
|
571
|
+
value: e.date,
|
|
572
572
|
type: "text",
|
|
573
|
-
disabled:
|
|
574
|
-
placeholder:
|
|
575
|
-
}, ll(
|
|
576
|
-
L(
|
|
573
|
+
disabled: e.disabled,
|
|
574
|
+
placeholder: e.placeholder
|
|
575
|
+
}, ll(e.events, !0)), null, 16, Ll),
|
|
576
|
+
L(k(d(I), {
|
|
577
577
|
class: _(["cl-absolute cl-bg-transparent cl-left-2 cl-text-grey-4 cl-top-3.5 icon", {
|
|
578
|
-
"!cl-bg-off-white":
|
|
578
|
+
"!cl-bg-off-white": e.disabled
|
|
579
579
|
}]),
|
|
580
|
-
icon:
|
|
580
|
+
icon: e.type === "time" ? "ph-clock" : "ph:calendar"
|
|
581
581
|
}, null, 8, ["class", "icon"]), [
|
|
582
|
-
[H, !
|
|
582
|
+
[H, !e.disabled]
|
|
583
583
|
]),
|
|
584
|
-
|
|
585
|
-
|
|
584
|
+
e.disabled ? N("", !0) : (u(), v("div", Pl, [
|
|
585
|
+
e.type !== "time" ? (u(), V(d(I), {
|
|
586
586
|
key: 0,
|
|
587
587
|
class: "cl-cursor-pointer hover:cl-text-link-light",
|
|
588
588
|
icon: "ph:arrow-counter-clockwise",
|
|
589
|
-
onClick: n[0] || (n[0] =
|
|
590
|
-
})) :
|
|
591
|
-
!
|
|
589
|
+
onClick: n[0] || (n[0] = W((m) => e.$emit("reset"), ["prevent"]))
|
|
590
|
+
})) : N("", !0),
|
|
591
|
+
!e.required && e.date && (e.type !== "time" || e.date !== "00:00") ? (u(), V(d(I), {
|
|
592
592
|
key: 1,
|
|
593
593
|
class: "cl-cursor-pointer hover:cl-text-link-light md:cl-ml-0.5",
|
|
594
594
|
icon: "ph:x",
|
|
595
|
-
onClick: n[1] || (n[1] =
|
|
596
|
-
})) :
|
|
595
|
+
onClick: n[1] || (n[1] = W((m) => e.$emit("clear"), ["prevent"]))
|
|
596
|
+
})) : N("", !0)
|
|
597
597
|
]))
|
|
598
598
|
]));
|
|
599
599
|
}
|
|
600
600
|
});
|
|
601
|
-
const De = /* @__PURE__ */
|
|
601
|
+
const De = /* @__PURE__ */ de(Fl, [["__scopeId", "data-v-4c802181"]]), Hl = /* @__PURE__ */ M({
|
|
602
602
|
inheritAttrs: !1,
|
|
603
603
|
__name: "cl-ui-calendar",
|
|
604
604
|
props: {
|
|
@@ -612,23 +612,23 @@ const De = /* @__PURE__ */ fe(Fl, [["__scopeId", "data-v-4c802181"]]), Hl = /* @
|
|
|
612
612
|
placeholder: { default: null }
|
|
613
613
|
},
|
|
614
614
|
emits: ["update:date"],
|
|
615
|
-
setup(t, { expose: o, emit:
|
|
616
|
-
const
|
|
615
|
+
setup(t, { expose: o, emit: l }) {
|
|
616
|
+
const e = t, n = S({
|
|
617
617
|
get() {
|
|
618
618
|
let b = null;
|
|
619
|
-
return
|
|
620
|
-
zone:
|
|
619
|
+
return e.type === "time" ? b = e.date === null ? "00:00" : e.date : e.date !== null && (b = $e.fromISO(e.date, {
|
|
620
|
+
zone: e.timeZone
|
|
621
621
|
}).toJSDate()), b;
|
|
622
622
|
},
|
|
623
623
|
set(b) {
|
|
624
624
|
let r = null;
|
|
625
|
-
|
|
626
|
-
zone:
|
|
627
|
-
}).setZone(
|
|
625
|
+
e.type === "time" ? r = b : b !== null && (r = $e.fromJSDate(b, {
|
|
626
|
+
zone: e.timeZone
|
|
627
|
+
}).setZone(e.timeZone).toISO()), l("update:date", r);
|
|
628
628
|
}
|
|
629
|
-
}), { locale:
|
|
629
|
+
}), { locale: m, t: s } = oe(), a = S(() => {
|
|
630
630
|
let b;
|
|
631
|
-
switch (
|
|
631
|
+
switch (e.type) {
|
|
632
632
|
case "date":
|
|
633
633
|
b = s("calendar.datePlaceholder");
|
|
634
634
|
break;
|
|
@@ -639,48 +639,48 @@ const De = /* @__PURE__ */ fe(Fl, [["__scopeId", "data-v-4c802181"]]), Hl = /* @
|
|
|
639
639
|
b = s("calendar.timePlaceholder");
|
|
640
640
|
break;
|
|
641
641
|
}
|
|
642
|
-
return
|
|
643
|
-
}), i =
|
|
642
|
+
return e.placeholder ?? b;
|
|
643
|
+
}), i = S(() => e.disabled ? !1 : {
|
|
644
644
|
visibility: "focus",
|
|
645
645
|
showDelay: 150,
|
|
646
646
|
hideDelay: 100
|
|
647
647
|
});
|
|
648
648
|
function c() {
|
|
649
|
-
let b =
|
|
650
|
-
|
|
649
|
+
let b = $e.now().set({ second: 0, millisecond: 0 }).setZone(e.timeZone);
|
|
650
|
+
e.type === "date" && (b = b.set({ hour: 0, minute: 0 }).setZone(e.timeZone)), n.value = b.toJSDate();
|
|
651
651
|
}
|
|
652
|
-
const
|
|
652
|
+
const g = A(null);
|
|
653
653
|
return o({
|
|
654
654
|
focus() {
|
|
655
655
|
var b;
|
|
656
|
-
(b =
|
|
656
|
+
(b = g.value) == null || b.focus();
|
|
657
657
|
}
|
|
658
658
|
}), (b, r) => b.type === "time" ? (u(), V(d(Me), {
|
|
659
659
|
key: 0,
|
|
660
660
|
modelValue: n.value,
|
|
661
661
|
"onUpdate:modelValue": r[1] || (r[1] = (w) => n.value = w),
|
|
662
662
|
modelModifiers: { string: !0 },
|
|
663
|
-
locale: d(
|
|
664
|
-
is24hr: d(
|
|
663
|
+
locale: d(m),
|
|
664
|
+
is24hr: d(m) !== "en-US",
|
|
665
665
|
mode: b.type,
|
|
666
666
|
"is-required": b.required,
|
|
667
|
-
masks: d(
|
|
667
|
+
masks: d(m) === "en-US" ? { modelValue: "HH:mm", input: "h:mm A" } : { modelValue: "HH:mm", input: "HH:mm" },
|
|
668
668
|
color: "primary",
|
|
669
669
|
"title-position": "left",
|
|
670
670
|
"hide-time-header": "",
|
|
671
671
|
popover: i.value
|
|
672
672
|
}, {
|
|
673
673
|
default: P(({ inputValue: w, inputEvents: h }) => [
|
|
674
|
-
|
|
674
|
+
k(De, se(b.$attrs, {
|
|
675
675
|
ref_key: "input",
|
|
676
|
-
ref:
|
|
676
|
+
ref: g,
|
|
677
677
|
date: w,
|
|
678
678
|
events: h,
|
|
679
679
|
type: b.type,
|
|
680
680
|
placeholder: a.value,
|
|
681
681
|
required: b.required,
|
|
682
682
|
disabled: b.disabled,
|
|
683
|
-
onClear: r[0] || (r[0] = (
|
|
683
|
+
onClear: r[0] || (r[0] = (q) => n.value = null),
|
|
684
684
|
onReset: c
|
|
685
685
|
}), null, 16, ["date", "events", "type", "placeholder", "required", "disabled"])
|
|
686
686
|
]),
|
|
@@ -689,8 +689,8 @@ const De = /* @__PURE__ */ fe(Fl, [["__scopeId", "data-v-4c802181"]]), Hl = /* @
|
|
|
689
689
|
key: 1,
|
|
690
690
|
modelValue: n.value,
|
|
691
691
|
"onUpdate:modelValue": r[3] || (r[3] = (w) => n.value = w),
|
|
692
|
-
locale: d(
|
|
693
|
-
is24hr: d(
|
|
692
|
+
locale: d(m),
|
|
693
|
+
is24hr: d(m) !== "en-US",
|
|
694
694
|
timezone: b.timeZone,
|
|
695
695
|
mode: b.type,
|
|
696
696
|
"min-date": b.min,
|
|
@@ -702,16 +702,16 @@ const De = /* @__PURE__ */ fe(Fl, [["__scopeId", "data-v-4c802181"]]), Hl = /* @
|
|
|
702
702
|
popover: i.value
|
|
703
703
|
}, {
|
|
704
704
|
default: P(({ inputValue: w, inputEvents: h }) => [
|
|
705
|
-
|
|
705
|
+
k(De, se(b.$attrs, {
|
|
706
706
|
ref_key: "input",
|
|
707
|
-
ref:
|
|
707
|
+
ref: g,
|
|
708
708
|
date: w,
|
|
709
709
|
events: h,
|
|
710
710
|
type: b.type,
|
|
711
711
|
placeholder: a.value,
|
|
712
712
|
required: b.required,
|
|
713
713
|
disabled: b.disabled,
|
|
714
|
-
onClear: r[2] || (r[2] = (
|
|
714
|
+
onClear: r[2] || (r[2] = (q) => n.value = null),
|
|
715
715
|
onReset: c
|
|
716
716
|
}), null, 16, ["date", "events", "type", "placeholder", "required", "disabled"])
|
|
717
717
|
]),
|
|
@@ -739,7 +739,7 @@ function Gl(t) {
|
|
|
739
739
|
function Ms() {
|
|
740
740
|
return Gl;
|
|
741
741
|
}
|
|
742
|
-
const
|
|
742
|
+
const xl = [
|
|
743
743
|
"button",
|
|
744
744
|
"checkbox",
|
|
745
745
|
"color",
|
|
@@ -756,13 +756,13 @@ const Zl = [
|
|
|
756
756
|
"text",
|
|
757
757
|
"url",
|
|
758
758
|
...Ee
|
|
759
|
-
],
|
|
759
|
+
], Zl = { class: "cl-flex cl-flex-wrap cl-items-center" }, Wl = { class: "cl-flex cl-flex-1 cl-flex-wrap cl-items-center cl-mb-2 cl-mt-3 cl-relative md:cl-mt-0" }, Kl = { class: "cl-absolute cl-bg-grey-0 cl-leading-6 cl-ml-0 cl-px-3 cl-rounded-full cl-text-center cl-text-xs cl-top-full" }, Ql = {
|
|
760
760
|
key: 0,
|
|
761
761
|
class: "cl-w-full"
|
|
762
762
|
}, Jl = ["min", "max", "step", "disabled"], Yl = { class: "cl-absolute cl-bg-grey-0 cl-leading-6 cl-ml-2 cl-px-3 cl-right-0 cl-rounded-full cl-text-center cl-text-xs cl-top-full" }, Xl = {
|
|
763
763
|
key: 1,
|
|
764
764
|
class: "emphasis-danger text-sm w-full"
|
|
765
|
-
}, et = /* @__PURE__ */
|
|
765
|
+
}, et = /* @__PURE__ */ M({
|
|
766
766
|
__name: "cl-ui-slider",
|
|
767
767
|
props: {
|
|
768
768
|
value: {},
|
|
@@ -776,51 +776,51 @@ const Zl = [
|
|
|
776
776
|
emits: {
|
|
777
777
|
"update:value": null
|
|
778
778
|
},
|
|
779
|
-
setup(t, { expose: o, emit:
|
|
780
|
-
const
|
|
781
|
-
get: () =>
|
|
782
|
-
set: (h) =>
|
|
783
|
-
}),
|
|
784
|
-
let h = (c.value -
|
|
779
|
+
setup(t, { expose: o, emit: l }) {
|
|
780
|
+
const e = t, { n, t: m } = oe(), { debounce: s } = cl(), a = A(e.value), i = A(), c = S({
|
|
781
|
+
get: () => e.value,
|
|
782
|
+
set: (h) => l("update:value", h)
|
|
783
|
+
}), g = S(() => e.disabled ? "rgba(153, 153, 153, 0.8)" : "#9acd32"), b = S(() => {
|
|
784
|
+
let h = (c.value - e.min) / (e.max - e.min) * 100;
|
|
785
785
|
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;
|
|
786
|
-
}), r =
|
|
787
|
-
function w(h,
|
|
788
|
-
const
|
|
789
|
-
c.value =
|
|
786
|
+
}), r = S(() => e.min <= e.max && e.step > 0);
|
|
787
|
+
function w(h, q) {
|
|
788
|
+
const $ = (h == null ? void 0 : h.value) ?? "", R = Math.max(Math.min(parseFloat($) || e.min, e.max), e.min);
|
|
789
|
+
c.value = e.enforceStep ? Math.ceil(R / e.step) * e.step : R, ge(() => q());
|
|
790
790
|
}
|
|
791
|
-
return
|
|
791
|
+
return K(() => e.value, () => a.value = e.value), o({
|
|
792
792
|
focus() {
|
|
793
793
|
var h;
|
|
794
794
|
(h = i.value) == null || h.focus();
|
|
795
795
|
}
|
|
796
|
-
}), (h,
|
|
797
|
-
L(
|
|
796
|
+
}), (h, q) => r.value ? (u(), v("div", le(se({ key: 0 }, h.$attrs)), [
|
|
797
|
+
L(p("div", { class: "cl-bg-transparent cl-relative cl-text-center cl-text-sm" }, T(c.value), 513), [
|
|
798
798
|
[H, !h.showNumericInput]
|
|
799
799
|
]),
|
|
800
|
-
|
|
801
|
-
L(
|
|
800
|
+
p("div", Zl, [
|
|
801
|
+
L(k(d(ae), {
|
|
802
802
|
modelValue: a.value,
|
|
803
|
-
"onUpdate:modelValue":
|
|
803
|
+
"onUpdate:modelValue": q[0] || (q[0] = ($) => a.value = $),
|
|
804
804
|
class: "!cl-text-sm md:!cl-w-auto",
|
|
805
805
|
"input-type": "number",
|
|
806
806
|
min: h.min,
|
|
807
807
|
max: h.max,
|
|
808
808
|
step: h.step,
|
|
809
809
|
disabled: h.disabled,
|
|
810
|
-
onInput:
|
|
810
|
+
onInput: q[1] || (q[1] = ($) => d(s)(w, $.target, h.$forceUpdate))
|
|
811
811
|
}, null, 8, ["modelValue", "min", "max", "step", "disabled"]), [
|
|
812
812
|
[H, h.showNumericInput]
|
|
813
813
|
]),
|
|
814
|
-
|
|
815
|
-
|
|
814
|
+
p("div", Wl, [
|
|
815
|
+
p("span", Kl, T(d(n)(h.min, Number.isInteger(h.min) ? d(Y).INTEGER : d(Y).DECIMAL)), 1),
|
|
816
816
|
typeof c.value == "number" ? (u(), v("div", Ql, [
|
|
817
|
-
L(
|
|
817
|
+
L(p("input", {
|
|
818
818
|
ref_key: "sliderRef",
|
|
819
819
|
ref: i,
|
|
820
|
-
"onUpdate:modelValue":
|
|
820
|
+
"onUpdate:modelValue": q[2] || (q[2] = ($) => c.value = $),
|
|
821
821
|
class: "cl-align-middle cl-appearance-none cl-bg-gradient-to-r cl-border cl-border-grey-2 cl-delay-500 cl-ease-in cl-flex-1 cl-h-5 cl-mb-2 cl-outline-none cl-rounded-full cl-transition-colors cl-w-full",
|
|
822
|
-
style:
|
|
823
|
-
background: `linear-gradient(to right, ${
|
|
822
|
+
style: Ze({
|
|
823
|
+
background: `linear-gradient(to right, ${g.value} 0%, ${g.value} ${b.value}%, white ${b.value}%, white 100%)`
|
|
824
824
|
}),
|
|
825
825
|
type: "range",
|
|
826
826
|
min: h.min,
|
|
@@ -835,14 +835,14 @@ const Zl = [
|
|
|
835
835
|
{ number: !0 }
|
|
836
836
|
]
|
|
837
837
|
])
|
|
838
|
-
])) :
|
|
839
|
-
|
|
838
|
+
])) : N("", !0),
|
|
839
|
+
p("span", Yl, T(d(n)(h.max, Number.isInteger(h.max) ? d(Y).INTEGER : d(Y).DECIMAL)), 1)
|
|
840
840
|
])
|
|
841
841
|
])
|
|
842
|
-
], 16)) : (u(), v("div", Xl,
|
|
842
|
+
], 16)) : (u(), v("div", Xl, T(d(m)("slider.invalidProps")), 1));
|
|
843
843
|
}
|
|
844
844
|
});
|
|
845
|
-
const lt = /* @__PURE__ */
|
|
845
|
+
const lt = /* @__PURE__ */ de(et, [["__scopeId", "data-v-849763cf"]]);
|
|
846
846
|
function Le(t) {
|
|
847
847
|
let o = !1;
|
|
848
848
|
switch (t) {
|
|
@@ -877,7 +877,7 @@ function Pe(t) {
|
|
|
877
877
|
}
|
|
878
878
|
return o;
|
|
879
879
|
}
|
|
880
|
-
function
|
|
880
|
+
function ye(t) {
|
|
881
881
|
return t === "button" || t === "submit" || t === "reset";
|
|
882
882
|
}
|
|
883
883
|
function ot(t) {
|
|
@@ -897,8 +897,8 @@ function ot(t) {
|
|
|
897
897
|
return o;
|
|
898
898
|
}
|
|
899
899
|
function Fe(t, o) {
|
|
900
|
-
const
|
|
901
|
-
return tt(o) ?
|
|
900
|
+
const l = t.target;
|
|
901
|
+
return tt(o) ? l.valueAsNumber : ye(o) ? l.checked : l.value;
|
|
902
902
|
}
|
|
903
903
|
const nt = { class: "cl-flex cl-justify-between" }, st = { class: "cl-w-full" }, at = {
|
|
904
904
|
key: 0,
|
|
@@ -918,7 +918,7 @@ const nt = { class: "cl-flex cl-justify-between" }, st = { class: "cl-w-full" },
|
|
|
918
918
|
}, ft = {
|
|
919
919
|
key: 1,
|
|
920
920
|
class: "cl-bg-danger-light cl-px-2 cl-rounded-md cl-text-center cl-text-danger-default cl-text-xs cl-w-auto cl-whitespace-pre-line"
|
|
921
|
-
}, mt = /* @__PURE__ */
|
|
921
|
+
}, mt = /* @__PURE__ */ M({
|
|
922
922
|
inheritAttrs: !1,
|
|
923
923
|
__name: "cl-ui-input",
|
|
924
924
|
props: {
|
|
@@ -949,228 +949,228 @@ const nt = { class: "cl-flex cl-justify-between" }, st = { class: "cl-w-full" },
|
|
|
949
949
|
showValidationMessages: { type: Boolean, default: !0 }
|
|
950
950
|
},
|
|
951
951
|
emits: ["update:model-value", "click", "focus", "input", "change", "validated"],
|
|
952
|
-
setup(t, { expose: o, emit:
|
|
953
|
-
const
|
|
954
|
-
get: () =>
|
|
955
|
-
set: (
|
|
956
|
-
}), b =
|
|
957
|
-
get: () =>
|
|
958
|
-
set: (
|
|
959
|
-
}), r =
|
|
960
|
-
var
|
|
952
|
+
setup(t, { expose: o, emit: l }) {
|
|
953
|
+
const e = t, n = A(null), m = A(!1), s = A(!1), a = S(C), i = S(() => e.placeholderText.trim() !== "" ? e.placeholderText : e.label), c = A(0), g = S({
|
|
954
|
+
get: () => e.modelValue,
|
|
955
|
+
set: (f) => y(f, !1)
|
|
956
|
+
}), b = S({
|
|
957
|
+
get: () => e.modelValue,
|
|
958
|
+
set: (f) => U(f)
|
|
959
|
+
}), r = S(() => typeof e.min == "number" ? e.min.toString() : e.min), w = S(() => typeof e.max == "number" ? e.max.toString() : e.max), h = S(() => typeof e.min == "number" || e.min === null ? e.min : parseFloat(e.min)), q = S(() => typeof e.max == "number" || e.max === null ? e.max : parseFloat(e.max)), $ = S(() => e.messageWhenValid.trim() !== "" ? e.messageWhenValid : ""), R = A(!0), O = A([]), z = S(() => {
|
|
960
|
+
var f, E;
|
|
961
961
|
return [
|
|
962
|
-
...((
|
|
963
|
-
...((
|
|
962
|
+
...((f = O.value) == null ? void 0 : f.filter((B) => ((B == null ? void 0 : B.length) ?? 0) > 0)) ?? [],
|
|
963
|
+
...((E = e.externalErrors) == null ? void 0 : E.filter((B) => ((B == null ? void 0 : B.length) ?? 0) > 0)) ?? []
|
|
964
964
|
].join(`
|
|
965
965
|
`);
|
|
966
966
|
});
|
|
967
|
-
async function
|
|
968
|
-
|
|
967
|
+
async function U(f) {
|
|
968
|
+
e.validateOn === "input" && await D(f), l("update:model-value", f);
|
|
969
969
|
}
|
|
970
|
-
async function y(
|
|
971
|
-
|
|
970
|
+
async function y(f, E) {
|
|
971
|
+
e.onInputFunction !== void 0 && (f = e.onInputFunction(f)), (E || e.validateOn === "input") && await D(f), l("update:model-value", f);
|
|
972
972
|
}
|
|
973
|
-
function D(
|
|
974
|
-
const
|
|
973
|
+
function D(f) {
|
|
974
|
+
const E = {
|
|
975
975
|
message: "",
|
|
976
976
|
valid: !0
|
|
977
|
-
},
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
}) : new Promise((
|
|
981
|
-
|
|
977
|
+
}, B = [
|
|
978
|
+
e.customValidationFunction === null || e.customValidationFunction === void 0 ? new Promise((pe) => {
|
|
979
|
+
pe(E);
|
|
980
|
+
}) : new Promise((pe) => {
|
|
981
|
+
pe(e.customValidationFunction(e.label, f));
|
|
982
982
|
})
|
|
983
983
|
];
|
|
984
|
-
return (typeof
|
|
985
|
-
const el = [...
|
|
986
|
-
Be ? (O.value = el,
|
|
984
|
+
return (typeof f == "string" || typeof f == "number") && (B.push(Ul(e.min, e.inputType, e.label, f)), B.push(Bl(e.max, e.inputType, e.label, f))), e.isRequired && B.push(Ml(e.label, f)), e.inputType === "email" && typeof f == "string" && B.push(Vl(e.label, f)), Promise.all(B).then((pe) => {
|
|
985
|
+
const el = [...pe.map((Ce) => Ce.message)], Be = pe.some((Ce) => Ce.message.length > 0 && Ce.valid === !1) || e.externalErrors.length > 0;
|
|
986
|
+
Be ? (O.value = el, l("validated", !1, f)) : (O.value = [], l("validated", !0, f)), R.value = !Be;
|
|
987
987
|
});
|
|
988
988
|
}
|
|
989
|
-
function
|
|
990
|
-
let
|
|
991
|
-
return
|
|
989
|
+
function J() {
|
|
990
|
+
let f = "";
|
|
991
|
+
return e.inputType === "color" && g.value && (e.disabled ? f = "background: #999999" : f = `background: ${g.value};`), f;
|
|
992
992
|
}
|
|
993
|
-
function
|
|
994
|
-
|
|
993
|
+
function Z(f) {
|
|
994
|
+
ye(e.inputType) ? (f.preventDefault(), l("click", f)) : e.inputType === "checkbox" && l("click", f);
|
|
995
995
|
}
|
|
996
|
-
function
|
|
996
|
+
function ie(f) {
|
|
997
997
|
if (n.value) {
|
|
998
998
|
n.value.stepUp(), n.value.focus(), y(n.value.valueAsNumber, !1);
|
|
999
|
-
const
|
|
999
|
+
const E = {
|
|
1000
1000
|
target: n.value
|
|
1001
1001
|
};
|
|
1002
|
-
|
|
1002
|
+
l("input", E, n.value.valueAsNumber), l("change", f, n.value.valueAsNumber);
|
|
1003
1003
|
}
|
|
1004
1004
|
}
|
|
1005
|
-
function Ne(
|
|
1005
|
+
function Ne(f) {
|
|
1006
1006
|
if (n.value) {
|
|
1007
1007
|
n.value.stepDown(), n.value.focus(), y(n.value.valueAsNumber, !1);
|
|
1008
|
-
const
|
|
1008
|
+
const E = {
|
|
1009
1009
|
target: n.value
|
|
1010
1010
|
};
|
|
1011
|
-
|
|
1011
|
+
l("input", E, n.value.valueAsNumber), l("change", f, n.value.valueAsNumber);
|
|
1012
1012
|
}
|
|
1013
1013
|
}
|
|
1014
|
-
function
|
|
1015
|
-
|
|
1014
|
+
function ve(f) {
|
|
1015
|
+
m.value = f;
|
|
1016
1016
|
}
|
|
1017
|
-
function
|
|
1018
|
-
s.value = !0,
|
|
1017
|
+
function be() {
|
|
1018
|
+
s.value = !0, ve(!1);
|
|
1019
1019
|
}
|
|
1020
|
-
function
|
|
1020
|
+
function ke() {
|
|
1021
1021
|
c.value++;
|
|
1022
1022
|
}
|
|
1023
|
-
function
|
|
1024
|
-
|
|
1023
|
+
function he(f) {
|
|
1024
|
+
f.target.blur();
|
|
1025
1025
|
}
|
|
1026
|
-
function
|
|
1027
|
-
var
|
|
1028
|
-
let
|
|
1029
|
-
const
|
|
1030
|
-
return
|
|
1031
|
-
}
|
|
1032
|
-
async function
|
|
1033
|
-
const
|
|
1034
|
-
|
|
1035
|
-
}
|
|
1036
|
-
return
|
|
1037
|
-
|
|
1038
|
-
}),
|
|
1039
|
-
await D(
|
|
1040
|
-
}),
|
|
1026
|
+
function C() {
|
|
1027
|
+
var B;
|
|
1028
|
+
let f = !0;
|
|
1029
|
+
const E = a.value;
|
|
1030
|
+
return m.value ? f = E : s.value && ((B = g.value) == null ? void 0 : B.toString().trim()) === "" && (f = !1), f;
|
|
1031
|
+
}
|
|
1032
|
+
async function G(f) {
|
|
1033
|
+
const E = Fe(f, e.inputType);
|
|
1034
|
+
e.validateOn === "change" && await D(E), l("change", f, E);
|
|
1035
|
+
}
|
|
1036
|
+
return Ae(() => {
|
|
1037
|
+
e.validateImmediately && y(e.modelValue, !0);
|
|
1038
|
+
}), K(() => e.isRequired, () => y(e.modelValue, !0)), K(() => e.externalErrors, async () => {
|
|
1039
|
+
await D(g.value), l("update:model-value", g.value);
|
|
1040
|
+
}), K(() => e.modelValue, () => y(e.modelValue, !0)), o({
|
|
1041
1041
|
focus() {
|
|
1042
|
-
var
|
|
1043
|
-
(
|
|
1042
|
+
var f;
|
|
1043
|
+
(f = n.value) == null || f.focus();
|
|
1044
1044
|
},
|
|
1045
1045
|
blur() {
|
|
1046
|
-
var
|
|
1047
|
-
(
|
|
1046
|
+
var f;
|
|
1047
|
+
(f = n.value) == null || f.blur();
|
|
1048
1048
|
}
|
|
1049
|
-
}), (
|
|
1049
|
+
}), (f, E) => (u(), v("div", se({ ...f.$attrs, id: void 0 }, {
|
|
1050
1050
|
key: c.value,
|
|
1051
1051
|
class: "cl-align-top cl-border-none cl-inline-block cl-text-left"
|
|
1052
1052
|
}), [
|
|
1053
|
-
|
|
1054
|
-
onMouseenter:
|
|
1055
|
-
onMouseleave:
|
|
1053
|
+
p("div", {
|
|
1054
|
+
onMouseenter: E[11] || (E[11] = (B) => ve(!0)),
|
|
1055
|
+
onMouseleave: E[12] || (E[12] = (B) => ve(!1))
|
|
1056
1056
|
}, [
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
L(
|
|
1060
|
-
[H,
|
|
1057
|
+
p("div", nt, [
|
|
1058
|
+
p("div", st, [
|
|
1059
|
+
L(p("label", { class: "cl-block cl-mb-1 cl-text-grey-4 cl-text-xs cl-tracking-widest" }, T(f.label), 513), [
|
|
1060
|
+
[H, f.showLabel && f.label !== ""]
|
|
1061
1061
|
])
|
|
1062
1062
|
]),
|
|
1063
|
-
|
|
1064
|
-
|
|
1063
|
+
f.isRequired && a.value ? (u(), v("label", at, " * ")) : N("", !0),
|
|
1064
|
+
f.isRequired && !a.value && f.requiredText.length ? (u(), v("label", rt, T(f.requiredText), 1)) : N("", !0)
|
|
1065
1065
|
]),
|
|
1066
|
-
|
|
1067
|
-
L(
|
|
1066
|
+
f.inputType !== "range" && !d(Pe)(f.inputType) ? (u(), v("div", it, [
|
|
1067
|
+
L(p("input", se({
|
|
1068
1068
|
ref_key: "inputElement",
|
|
1069
1069
|
ref: n,
|
|
1070
|
-
"onUpdate:modelValue":
|
|
1071
|
-
},
|
|
1070
|
+
"onUpdate:modelValue": E[0] || (E[0] = (B) => g.value = B)
|
|
1071
|
+
}, f.$attrs, {
|
|
1072
1072
|
class: ["!cl-mb-1 cl-block cl-border cl-duration-300 cl-h-full cl-transition cl-w-full focus:cl-outline-none", {
|
|
1073
|
-
"hover:!cl-border-grey-3":
|
|
1074
|
-
"!cl-cursor-default":
|
|
1075
|
-
"!cl-border-danger-default": !
|
|
1076
|
-
"!cl-border-primary-default":
|
|
1077
|
-
"cl-border-grey-0 focus:cl-border-blue-light":
|
|
1078
|
-
"!cl-p-2":
|
|
1079
|
-
"cl-p-3 cl-rounded-lg": !d(
|
|
1080
|
-
[`${
|
|
1073
|
+
"hover:!cl-border-grey-3": f.disabled === !1 && !d(ye)(f.inputType),
|
|
1074
|
+
"!cl-cursor-default": f.disabled,
|
|
1075
|
+
"!cl-border-danger-default": !R.value,
|
|
1076
|
+
"!cl-border-primary-default": R.value && f.highlightWhenValid,
|
|
1077
|
+
"cl-border-grey-0 focus:cl-border-blue-light": R.value && !d(ye)(f.inputType),
|
|
1078
|
+
"!cl-p-2": f.inputType === "checkbox" || f.inputType === "radio",
|
|
1079
|
+
"cl-p-3 cl-rounded-lg": !d(ye)(f.inputType),
|
|
1080
|
+
[`${f.inputSpecificClasses}`]: f.inputSpecificClasses !== ""
|
|
1081
1081
|
}],
|
|
1082
|
-
style:
|
|
1083
|
-
type:
|
|
1084
|
-
disabled:
|
|
1085
|
-
min:
|
|
1086
|
-
max:
|
|
1087
|
-
minlength:
|
|
1088
|
-
maxlength:
|
|
1089
|
-
step:
|
|
1082
|
+
style: J(),
|
|
1083
|
+
type: f.inputType,
|
|
1084
|
+
disabled: f.disabled,
|
|
1085
|
+
min: f.min ?? void 0,
|
|
1086
|
+
max: f.max ?? void 0,
|
|
1087
|
+
minlength: f.min !== null && d(Le)(f.inputType) ? f.min : void 0,
|
|
1088
|
+
maxlength: f.max !== null && d(Le)(f.inputType) ? f.max : void 0,
|
|
1089
|
+
step: f.step,
|
|
1090
1090
|
placeholder: i.value,
|
|
1091
|
-
accept:
|
|
1092
|
-
name:
|
|
1093
|
-
autocomplete:
|
|
1094
|
-
onClick:
|
|
1095
|
-
onFocus:
|
|
1096
|
-
onBlur:
|
|
1097
|
-
|
|
1091
|
+
accept: f.fileExtensions,
|
|
1092
|
+
name: f.group,
|
|
1093
|
+
autocomplete: f.autocomplete,
|
|
1094
|
+
onClick: E[1] || (E[1] = (B) => Z(B)),
|
|
1095
|
+
onFocus: E[2] || (E[2] = (B) => l("focus")),
|
|
1096
|
+
onBlur: E[3] || (E[3] = W((B) => {
|
|
1097
|
+
be(), ke();
|
|
1098
1098
|
}, ["self"])),
|
|
1099
|
-
onMousewheelPassive:
|
|
1100
|
-
onInput:
|
|
1101
|
-
|
|
1099
|
+
onMousewheelPassive: he,
|
|
1100
|
+
onInput: E[4] || (E[4] = (B) => {
|
|
1101
|
+
l("input", B, d(Fe)(B, f.inputType));
|
|
1102
1102
|
}),
|
|
1103
|
-
onChange:
|
|
1103
|
+
onChange: G
|
|
1104
1104
|
}), null, 16, ct), [
|
|
1105
|
-
[ol,
|
|
1105
|
+
[ol, g.value]
|
|
1106
1106
|
]),
|
|
1107
|
-
|
|
1107
|
+
k(me, {
|
|
1108
1108
|
name: "fade",
|
|
1109
1109
|
duration: 300
|
|
1110
1110
|
}, {
|
|
1111
1111
|
default: P(() => [
|
|
1112
|
-
|
|
1113
|
-
|
|
1112
|
+
f.inputType === "number" && !f.disabled && f.showArrows ? L((u(), v("div", ut, [
|
|
1113
|
+
k(d(I), {
|
|
1114
1114
|
icon: "ph:caret-up-bold",
|
|
1115
1115
|
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",
|
|
1116
|
-
onClick:
|
|
1117
|
-
onMousedown:
|
|
1116
|
+
onClick: ie,
|
|
1117
|
+
onMousedown: E[5] || (E[5] = W(() => {
|
|
1118
1118
|
}, ["prevent"]))
|
|
1119
1119
|
}),
|
|
1120
|
-
|
|
1120
|
+
k(d(I), {
|
|
1121
1121
|
icon: "ph:caret-down-bold",
|
|
1122
1122
|
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",
|
|
1123
1123
|
onClick: Ne,
|
|
1124
|
-
onMousedown:
|
|
1124
|
+
onMousedown: E[6] || (E[6] = W(() => {
|
|
1125
1125
|
}, ["prevent"]))
|
|
1126
1126
|
})
|
|
1127
1127
|
], 512)), [
|
|
1128
|
-
[H,
|
|
1129
|
-
]) :
|
|
1128
|
+
[H, m.value]
|
|
1129
|
+
]) : N("", !0)
|
|
1130
1130
|
]),
|
|
1131
1131
|
_: 1
|
|
1132
1132
|
})
|
|
1133
|
-
])) : d(Pe)(
|
|
1133
|
+
])) : d(Pe)(f.inputType) ? (u(), V(d(Hl), se({ key: 1 }, f.$attrs, {
|
|
1134
1134
|
ref_key: "inputElement",
|
|
1135
1135
|
ref: n,
|
|
1136
1136
|
date: b.value,
|
|
1137
|
-
"onUpdate:date":
|
|
1137
|
+
"onUpdate:date": E[7] || (E[7] = (B) => b.value = B),
|
|
1138
1138
|
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", {
|
|
1139
|
-
"hover:cl-border-grey-3": !
|
|
1140
|
-
"!cl-border-danger-default": !
|
|
1141
|
-
"!cl-border-primary-default":
|
|
1139
|
+
"hover:cl-border-grey-3": !f.disabled,
|
|
1140
|
+
"!cl-border-danger-default": !R.value,
|
|
1141
|
+
"!cl-border-primary-default": R.value && f.highlightWhenValid
|
|
1142
1142
|
}],
|
|
1143
|
-
disabled:
|
|
1144
|
-
required:
|
|
1145
|
-
type: d(ot)(
|
|
1146
|
-
"time-zone":
|
|
1143
|
+
disabled: f.disabled,
|
|
1144
|
+
required: f.isRequired,
|
|
1145
|
+
type: d(ot)(f.inputType),
|
|
1146
|
+
"time-zone": f.timeZone,
|
|
1147
1147
|
min: r.value,
|
|
1148
1148
|
max: w.value,
|
|
1149
1149
|
placeholder: i.value,
|
|
1150
|
-
onBlur:
|
|
1151
|
-
onFocus:
|
|
1152
|
-
}), null, 16, ["date", "class", "disabled", "required", "type", "time-zone", "min", "max", "placeholder", "onBlur"])) :
|
|
1153
|
-
|
|
1150
|
+
onBlur: W(be, ["self"]),
|
|
1151
|
+
onFocus: E[8] || (E[8] = (B) => l("focus"))
|
|
1152
|
+
}), null, 16, ["date", "class", "disabled", "required", "type", "time-zone", "min", "max", "placeholder", "onBlur"])) : f.inputType === "range" && typeof g.value == "number" ? (u(), v("div", dt, [
|
|
1153
|
+
k(d(lt), {
|
|
1154
1154
|
ref_key: "inputElement",
|
|
1155
1155
|
ref: n,
|
|
1156
|
-
value:
|
|
1157
|
-
"onUpdate:value":
|
|
1156
|
+
value: g.value,
|
|
1157
|
+
"onUpdate:value": E[9] || (E[9] = (B) => g.value = B),
|
|
1158
1158
|
min: h.value ?? 0,
|
|
1159
|
-
max:
|
|
1160
|
-
step:
|
|
1161
|
-
disabled:
|
|
1159
|
+
max: q.value ?? 1e3,
|
|
1160
|
+
step: f.step,
|
|
1161
|
+
disabled: f.disabled,
|
|
1162
1162
|
"show-numeric-input": !1,
|
|
1163
|
-
onBlur:
|
|
1164
|
-
onFocus:
|
|
1163
|
+
onBlur: W(be, ["self"]),
|
|
1164
|
+
onFocus: E[10] || (E[10] = (B) => l("focus"))
|
|
1165
1165
|
}, null, 8, ["value", "min", "max", "step", "disabled", "onBlur"])
|
|
1166
|
-
])) :
|
|
1166
|
+
])) : N("", !0)
|
|
1167
1167
|
], 32),
|
|
1168
|
-
|
|
1169
|
-
!
|
|
1168
|
+
R.value && $.value ? (u(), v("div", pt, T($.value), 1)) : N("", !0),
|
|
1169
|
+
!R.value && z.value.length > 0 && f.showValidationMessages ? (u(), v("div", ft, T(z.value), 1)) : N("", !0)
|
|
1170
1170
|
], 16));
|
|
1171
1171
|
}
|
|
1172
1172
|
});
|
|
1173
|
-
const
|
|
1173
|
+
const ae = /* @__PURE__ */ de(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { class: "cl-align-items-center cl-bg-black cl-bg-opacity-40 cl-bottom-0 cl-fixed cl-flex cl-h-screen cl-justify-center cl-left-0 cl-right-0 cl-top-0 cl-w-full cl-z-40" }, vt = ["onKeypress"], bt = { class: "cl-overflow-y-auto cl-overscroll-y-none cl-p-2 cl-w-full" }, Ye = /* @__PURE__ */ M({
|
|
1174
1174
|
inheritAttrs: !1,
|
|
1175
1175
|
__name: "cl-ui-modal",
|
|
1176
1176
|
props: {
|
|
@@ -1179,23 +1179,23 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1179
1179
|
size: { default: "medium" }
|
|
1180
1180
|
},
|
|
1181
1181
|
setup(t) {
|
|
1182
|
-
const o = t,
|
|
1183
|
-
function
|
|
1184
|
-
|
|
1182
|
+
const o = t, l = A(!1);
|
|
1183
|
+
function e() {
|
|
1184
|
+
l.value = !0, document.addEventListener("keydown", m);
|
|
1185
1185
|
}
|
|
1186
1186
|
function n() {
|
|
1187
|
-
o.preventClose || (
|
|
1187
|
+
o.preventClose || (l.value = !1, document.removeEventListener("keydown", m));
|
|
1188
1188
|
}
|
|
1189
|
-
function
|
|
1189
|
+
function m(s) {
|
|
1190
1190
|
s.key === "Escape" && n();
|
|
1191
1191
|
}
|
|
1192
1192
|
return (s, a) => (u(), v(F, null, [
|
|
1193
|
-
|
|
1193
|
+
j(s.$slots, "trigger", le(ne({ open: e }))),
|
|
1194
1194
|
(u(), V(_e, { to: "body" }, [
|
|
1195
|
-
|
|
1195
|
+
k(me, { name: "fade" }, {
|
|
1196
1196
|
default: P(() => [
|
|
1197
|
-
L(
|
|
1198
|
-
|
|
1197
|
+
L(p("div", gt, [
|
|
1198
|
+
p("div", se(s.$attrs, {
|
|
1199
1199
|
class: ["cl-bg-white cl-flex cl-flex-wrap cl-max-h-[calc(100vh-8rem)] cl-mx-0 cl-my-auto cl-overflow-y-auto cl-overscroll-y-none cl-relative cl-rounded-lg cl-shadow-lg", {
|
|
1200
1200
|
"lg:cl-w-2/12 cl-w-10/12": s.size === "x-small",
|
|
1201
1201
|
"cl-w-6/12": s.size === "small",
|
|
@@ -1203,35 +1203,35 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1203
1203
|
"cl-w-10/12": s.size === "large"
|
|
1204
1204
|
}]
|
|
1205
1205
|
}), [
|
|
1206
|
-
L(
|
|
1206
|
+
L(p("div", {
|
|
1207
1207
|
class: _(["cl-absolute cl-cursor-pointer cl-right-4 cl-top-4 cl-transition-colors cl-w-3", {
|
|
1208
1208
|
"cl-text-white hover:cl-text-off-white": s.headerColour === "secondary" || s.headerColour === "primary",
|
|
1209
1209
|
"cl-text-black hover:cl-text-grey-7": s.headerColour === "white"
|
|
1210
1210
|
}]),
|
|
1211
1211
|
tabindex: 0,
|
|
1212
|
-
onKeypress:
|
|
1212
|
+
onKeypress: we(n, ["enter"]),
|
|
1213
1213
|
onClick: n
|
|
1214
1214
|
}, [
|
|
1215
|
-
|
|
1215
|
+
k(d(I), { icon: "ph:x" })
|
|
1216
1216
|
], 42, vt), [
|
|
1217
1217
|
[H, !s.preventClose]
|
|
1218
1218
|
]),
|
|
1219
|
-
|
|
1219
|
+
p("div", {
|
|
1220
1220
|
class: _(["cl-leading-[2.75rem] cl-min-h-12 cl-overflow-hidden cl-pl-3 cl-pr-8 cl-text-2xl cl-w-full", {
|
|
1221
1221
|
"cl-border-b cl-border-grey-2": s.headerColour === "white",
|
|
1222
1222
|
"cl-bg-secondary-default cl-text-white": s.headerColour === "secondary",
|
|
1223
1223
|
"cl-bg-primary-default cl-text-white": s.headerColour === "primary"
|
|
1224
1224
|
}])
|
|
1225
1225
|
}, [
|
|
1226
|
-
|
|
1226
|
+
j(s.$slots, "title")
|
|
1227
1227
|
], 2),
|
|
1228
|
-
|
|
1229
|
-
|
|
1228
|
+
p("div", bt, [
|
|
1229
|
+
j(s.$slots, "default", le(ne({ close: n })))
|
|
1230
1230
|
]),
|
|
1231
|
-
|
|
1231
|
+
j(s.$slots, "footer", le(ne({ close: n })))
|
|
1232
1232
|
], 16)
|
|
1233
1233
|
], 512), [
|
|
1234
|
-
[H,
|
|
1234
|
+
[H, l.value]
|
|
1235
1235
|
])
|
|
1236
1236
|
]),
|
|
1237
1237
|
_: 3
|
|
@@ -1242,7 +1242,7 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1242
1242
|
}), ht = { class: "cl-bg-grey-0 cl-flex cl-p-1 cl-text-left" }, yt = {
|
|
1243
1243
|
key: 0,
|
|
1244
1244
|
class: "cl-w-1/2"
|
|
1245
|
-
}, Te = /* @__PURE__ */
|
|
1245
|
+
}, Te = /* @__PURE__ */ M({
|
|
1246
1246
|
__name: "cl-ui-combo-box-header",
|
|
1247
1247
|
props: {
|
|
1248
1248
|
showClearButton: { type: Boolean, default: !1 },
|
|
@@ -1253,19 +1253,19 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1253
1253
|
"clear-object": null
|
|
1254
1254
|
},
|
|
1255
1255
|
setup(t) {
|
|
1256
|
-
return (o,
|
|
1257
|
-
o.additionalText !== "" ? (u(), v("div", yt,
|
|
1258
|
-
|
|
1256
|
+
return (o, l) => (u(), v("div", ht, [
|
|
1257
|
+
o.additionalText !== "" ? (u(), v("div", yt, T(o.additionalText), 1)) : N("", !0),
|
|
1258
|
+
p("div", {
|
|
1259
1259
|
class: _({
|
|
1260
1260
|
"cl-w-1/2": o.additionalText !== "",
|
|
1261
1261
|
"cl-w-full": o.additionalText === ""
|
|
1262
1262
|
})
|
|
1263
|
-
},
|
|
1264
|
-
L(
|
|
1263
|
+
}, T(o.text), 3),
|
|
1264
|
+
L(p("div", {
|
|
1265
1265
|
class: "cl-cursor-pointer cl-float-right",
|
|
1266
|
-
onMousedown:
|
|
1266
|
+
onMousedown: l[0] || (l[0] = (e) => o.$emit("clear-object"))
|
|
1267
1267
|
}, [
|
|
1268
|
-
|
|
1268
|
+
k(d(I), {
|
|
1269
1269
|
class: "cl-mt-1 cl-transition-colors hover:cl-text-link-default",
|
|
1270
1270
|
icon: "ph:x"
|
|
1271
1271
|
})
|
|
@@ -1277,7 +1277,7 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1277
1277
|
}), wt = {
|
|
1278
1278
|
key: 0,
|
|
1279
1279
|
class: "cl-w-1/2"
|
|
1280
|
-
}, $t = { class: "cl-float-right cl-py-1" }, He = /* @__PURE__ */
|
|
1280
|
+
}, $t = { class: "cl-float-right cl-py-1" }, He = /* @__PURE__ */ M({
|
|
1281
1281
|
__name: "cl-ui-combo-box-selectable",
|
|
1282
1282
|
props: {
|
|
1283
1283
|
isCreateNewOption: { type: Boolean, default: !1 },
|
|
@@ -1292,47 +1292,47 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1292
1292
|
"option-highlighted": null
|
|
1293
1293
|
},
|
|
1294
1294
|
setup(t, { emit: o }) {
|
|
1295
|
-
const
|
|
1295
|
+
const l = t, e = S(() => {
|
|
1296
1296
|
var c;
|
|
1297
|
-
return ((c =
|
|
1298
|
-
}), n =
|
|
1297
|
+
return ((c = l.option) == null ? void 0 : c.name) ?? l.text;
|
|
1298
|
+
}), n = S(() => {
|
|
1299
1299
|
var c;
|
|
1300
|
-
return ((c =
|
|
1301
|
-
}),
|
|
1300
|
+
return ((c = l.option) == null ? void 0 : c.parentName) ?? "";
|
|
1301
|
+
}), m = A(!1);
|
|
1302
1302
|
function s() {
|
|
1303
1303
|
var c;
|
|
1304
|
-
|
|
1304
|
+
l.isCreateNewOption === !0 ? o("create-object") : o("select-object", (c = l.option) == null ? void 0 : c.id);
|
|
1305
1305
|
}
|
|
1306
1306
|
function a(c) {
|
|
1307
|
-
c === !0 ? (
|
|
1307
|
+
c === !0 ? (m.value = !0, o("option-highlighted", l.index)) : l.index !== l.selectedIndex && (m.value = !1);
|
|
1308
1308
|
}
|
|
1309
1309
|
function i() {
|
|
1310
|
-
|
|
1310
|
+
l.selectedIndex === l.index ? m.value = !0 : m.value = !1;
|
|
1311
1311
|
}
|
|
1312
|
-
return
|
|
1312
|
+
return K(() => l.selectedIndex, () => i()), (c, g) => {
|
|
1313
1313
|
var b, r;
|
|
1314
1314
|
return u(), v("div", {
|
|
1315
1315
|
class: _(["cl-cursor-pointer cl-duration-75 cl-flex cl-p-1 cl-text-left cl-transition-colors", {
|
|
1316
|
-
"cl-bg-white":
|
|
1317
|
-
"cl-bg-link-light cl-text-white cl-opacity-90":
|
|
1318
|
-
"cl-bg-primary-default cl-text-white cl-opacity-90":
|
|
1316
|
+
"cl-bg-white": m.value === !1,
|
|
1317
|
+
"cl-bg-link-light cl-text-white cl-opacity-90": m.value && c.isCreateNewOption === !1,
|
|
1318
|
+
"cl-bg-primary-default cl-text-white cl-opacity-90": m.value && c.isCreateNewOption
|
|
1319
1319
|
}]),
|
|
1320
1320
|
onMousedown: s,
|
|
1321
|
-
onMousemove:
|
|
1322
|
-
onMouseleave:
|
|
1321
|
+
onMousemove: g[0] || (g[0] = (w) => a(!0)),
|
|
1322
|
+
onMouseleave: g[1] || (g[1] = (w) => a(!1))
|
|
1323
1323
|
}, [
|
|
1324
|
-
c.option !== null && ((b = c.option) == null ? void 0 : b.parentId) !== 0 && ((r = c.option) == null ? void 0 : r.parentId) !== void 0 ? (u(), v("div", wt,
|
|
1325
|
-
|
|
1324
|
+
c.option !== null && ((b = c.option) == null ? void 0 : b.parentId) !== 0 && ((r = c.option) == null ? void 0 : r.parentId) !== void 0 ? (u(), v("div", wt, T(n.value), 1)) : N("", !0),
|
|
1325
|
+
p("div", {
|
|
1326
1326
|
class: _({
|
|
1327
1327
|
"cl-w-1/2": n.value !== "",
|
|
1328
1328
|
"cl-w-full": n.value === ""
|
|
1329
1329
|
})
|
|
1330
|
-
},
|
|
1331
|
-
L(
|
|
1332
|
-
|
|
1330
|
+
}, T(e.value), 3),
|
|
1331
|
+
L(p("div", $t, [
|
|
1332
|
+
k(d(I), {
|
|
1333
1333
|
class: _(["cl-transition-colors", {
|
|
1334
|
-
"cl-text-white":
|
|
1335
|
-
"cl-text-black ": !
|
|
1334
|
+
"cl-text-white": m.value,
|
|
1335
|
+
"cl-text-black ": !m.value
|
|
1336
1336
|
}]),
|
|
1337
1337
|
icon: "ph:plus"
|
|
1338
1338
|
}, null, 8, ["class"])
|
|
@@ -1342,7 +1342,7 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1342
1342
|
], 34);
|
|
1343
1343
|
};
|
|
1344
1344
|
}
|
|
1345
|
-
}), kt = ["onKeyup"], Ct = { class: "cl-bg-white cl-flex cl-p-2 cl-pb-1 cl-sticky cl-top-0 cl-w-full cl-z-10" }, Tt = { key: 5 }, Et = /* @__PURE__ */
|
|
1345
|
+
}), kt = ["onKeyup"], Ct = { class: "cl-bg-white cl-flex cl-p-2 cl-pb-1 cl-sticky cl-top-0 cl-w-full cl-z-10" }, Tt = { key: 5 }, Et = /* @__PURE__ */ M({
|
|
1346
1346
|
__name: "cl-ui-combo-box-search",
|
|
1347
1347
|
props: {
|
|
1348
1348
|
loading: { type: Boolean, default: !1 },
|
|
@@ -1353,7 +1353,8 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1353
1353
|
canClearSelectedObject: { type: Boolean, default: !0 },
|
|
1354
1354
|
currentObjectName: { default: "" },
|
|
1355
1355
|
results: { default: () => [] },
|
|
1356
|
-
isVisible: { type: Boolean, default: !1 }
|
|
1356
|
+
isVisible: { type: Boolean, default: !1 },
|
|
1357
|
+
searchHint: {}
|
|
1357
1358
|
},
|
|
1358
1359
|
emits: {
|
|
1359
1360
|
"clear-object": null,
|
|
@@ -1363,11 +1364,11 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1363
1364
|
"hide-dropdown": null
|
|
1364
1365
|
},
|
|
1365
1366
|
setup(t, { emit: o }) {
|
|
1366
|
-
const
|
|
1367
|
+
const l = t, { t: e } = oe(), n = A(""), m = A(!1), s = A(-1), a = S(() => m.value ? -1 : 0), i = A();
|
|
1367
1368
|
function c(y) {
|
|
1368
1369
|
(y === void 0 || (y == null ? void 0 : y.code.startsWith("Arrow")) === !1 && (y == null ? void 0 : y.code.startsWith("Control")) === !1 && (y == null ? void 0 : y.code.startsWith("Shift")) === !1 && (y == null ? void 0 : y.code.startsWith("Tab")) === !1 && (y == null ? void 0 : y.code) !== "Enter") && (o("search", n.value), s.value = -2);
|
|
1369
1370
|
}
|
|
1370
|
-
function
|
|
1371
|
+
function g(y) {
|
|
1371
1372
|
o("select-object", y);
|
|
1372
1373
|
}
|
|
1373
1374
|
function b() {
|
|
@@ -1377,69 +1378,69 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1377
1378
|
o("hide-dropdown");
|
|
1378
1379
|
}
|
|
1379
1380
|
function w(y) {
|
|
1380
|
-
s.value <
|
|
1381
|
+
s.value < l.results.length - 1 ? (s.value === -2 && n.value === "" && s.value++, s.value++) : s.value = y, R();
|
|
1381
1382
|
}
|
|
1382
1383
|
function h(y) {
|
|
1383
|
-
s.value > y ? s.value-- : s.value =
|
|
1384
|
+
s.value > y ? s.value-- : s.value = l.results.length - 1, R();
|
|
1384
1385
|
}
|
|
1385
|
-
function
|
|
1386
|
-
s.value >= 0 &&
|
|
1386
|
+
function q() {
|
|
1387
|
+
s.value >= 0 && l.results !== void 0 ? g(l.results[s.value].id) : s.value === -1 && b();
|
|
1387
1388
|
}
|
|
1388
|
-
function
|
|
1389
|
+
function $(y) {
|
|
1389
1390
|
if (y.key === "Tab" && y.shiftKey === !0) {
|
|
1390
1391
|
const D = document.getElementsByTagName("input");
|
|
1391
|
-
let
|
|
1392
|
-
for (let
|
|
1393
|
-
D[
|
|
1394
|
-
|
|
1392
|
+
let J = -1;
|
|
1393
|
+
for (let Z = 0; Z < D.length; Z++)
|
|
1394
|
+
D[Z] === y.target && (J = Z - 1);
|
|
1395
|
+
J >= 0 && (D[J].focus(), r());
|
|
1395
1396
|
}
|
|
1396
1397
|
}
|
|
1397
|
-
function
|
|
1398
|
+
function R() {
|
|
1398
1399
|
var y;
|
|
1399
|
-
|
|
1400
|
+
l.results && l.results.length > 1 && ((y = i.value) == null || y.scrollTo(0, (s.value + 1) * 34 - 34 * 2));
|
|
1400
1401
|
}
|
|
1401
1402
|
function O() {
|
|
1402
1403
|
let y = !1;
|
|
1403
|
-
|
|
1404
|
+
l.results !== null && l.results.length === 1 && (y = n.value.toUpperCase().trim() === l.results[0].name.toUpperCase().trim()), m.value = l.canCreateNewObject === !0 && l.errorMessage === "" && n.value.trim() !== "" && y === !1;
|
|
1404
1405
|
}
|
|
1405
|
-
function
|
|
1406
|
+
function z(y) {
|
|
1406
1407
|
s.value = y;
|
|
1407
1408
|
}
|
|
1408
|
-
function
|
|
1409
|
-
|
|
1409
|
+
function U() {
|
|
1410
|
+
l.isVisible === !0 && (n.value = "", c(), ge(() => {
|
|
1410
1411
|
var y, D;
|
|
1411
1412
|
return (D = (y = i.value) == null ? void 0 : y.querySelector("input")) == null ? void 0 : D.focus();
|
|
1412
1413
|
}));
|
|
1413
1414
|
}
|
|
1414
|
-
return
|
|
1415
|
+
return K(() => l.results, () => O()), K(() => l.errorMessage, () => O()), K(() => l.isVisible, () => U()), Ae(() => {
|
|
1415
1416
|
var y;
|
|
1416
|
-
return (y = i.value) == null ? void 0 : y.addEventListener("keydown",
|
|
1417
|
+
return (y = i.value) == null ? void 0 : y.addEventListener("keydown", $);
|
|
1417
1418
|
}), Ie(() => {
|
|
1418
1419
|
var y;
|
|
1419
|
-
return (y = i.value) == null ? void 0 : y.removeEventListener("keydown",
|
|
1420
|
+
return (y = i.value) == null ? void 0 : y.removeEventListener("keydown", $);
|
|
1420
1421
|
}), (y, D) => {
|
|
1421
|
-
var
|
|
1422
|
+
var J;
|
|
1422
1423
|
return u(), v("div", {
|
|
1423
1424
|
ref_key: "container",
|
|
1424
1425
|
ref: i,
|
|
1425
1426
|
class: "cl-absolute cl-bg-white cl-border cl-border-collapse cl-border-grey-0 cl-h-52 cl-overflow-y-auto cl-overscroll-y-none cl-rounded cl-text-sm cl-w-full cl-z-20",
|
|
1426
1427
|
onKeydown: [
|
|
1427
|
-
D[2] || (D[2] =
|
|
1428
|
-
D[3] || (D[3] =
|
|
1428
|
+
D[2] || (D[2] = we(W((Z) => h(a.value), ["prevent", "stop"]), ["up"])),
|
|
1429
|
+
D[3] || (D[3] = we(W((Z) => w(a.value), ["prevent", "stop"]), ["down"]))
|
|
1429
1430
|
],
|
|
1430
|
-
onKeyup:
|
|
1431
|
+
onKeyup: we(W(q, ["prevent", "stop"]), ["enter"])
|
|
1431
1432
|
}, [
|
|
1432
|
-
|
|
1433
|
-
|
|
1433
|
+
p("div", Ct, [
|
|
1434
|
+
k(ae, {
|
|
1434
1435
|
modelValue: n.value,
|
|
1435
|
-
"onUpdate:modelValue": D[0] || (D[0] = (
|
|
1436
|
+
"onUpdate:modelValue": D[0] || (D[0] = (Z) => n.value = Z),
|
|
1436
1437
|
class: "!cl-mr-0 cl-w-full",
|
|
1437
1438
|
"input-type": "text",
|
|
1438
|
-
"placeholder-text":
|
|
1439
|
+
"placeholder-text": y.searchHint,
|
|
1439
1440
|
onKeyup: c,
|
|
1440
1441
|
onBlur: r
|
|
1441
1442
|
}, null, 8, ["modelValue", "placeholder-text"]),
|
|
1442
|
-
L(
|
|
1443
|
+
L(k(Se, { class: "cl-absolute cl-ml-2 cl-mt-11" }, null, 512), [
|
|
1443
1444
|
[H, y.loading]
|
|
1444
1445
|
])
|
|
1445
1446
|
]),
|
|
@@ -1447,48 +1448,48 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1447
1448
|
key: 0,
|
|
1448
1449
|
"show-clear-button": y.canClearSelectedObject,
|
|
1449
1450
|
text: y.currentObjectName,
|
|
1450
|
-
onClearObject: D[1] || (D[1] = (
|
|
1451
|
-
}, null, 8, ["show-clear-button", "text"])) :
|
|
1451
|
+
onClearObject: D[1] || (D[1] = (Z) => y.$emit("clear-object"))
|
|
1452
|
+
}, null, 8, ["show-clear-button", "text"])) : N("", !0),
|
|
1452
1453
|
y.objectParentType !== "" && y.results !== void 0 && y.results.length > 0 && y.errorMessage === "" ? (u(), V(Te, {
|
|
1453
1454
|
key: 1,
|
|
1454
1455
|
text: y.objectType,
|
|
1455
1456
|
"additional-text": y.objectParentType,
|
|
1456
1457
|
class: "cl-bg-grey-2 cl-mt-1"
|
|
1457
|
-
}, null, 8, ["text", "additional-text"])) :
|
|
1458
|
-
y.results !== null && ((
|
|
1458
|
+
}, null, 8, ["text", "additional-text"])) : N("", !0),
|
|
1459
|
+
y.results !== null && ((J = y.results) == null ? void 0 : J.length) === 0 && n.value.trim() !== "" && y.canCreateNewObject === !1 && y.errorMessage === "" ? (u(), V(Te, {
|
|
1459
1460
|
key: 2,
|
|
1460
|
-
text: d(
|
|
1461
|
-
}, null, 8, ["text"])) :
|
|
1461
|
+
text: d(e)("comboBox.noResults", { value: n.value })
|
|
1462
|
+
}, null, 8, ["text"])) : N("", !0),
|
|
1462
1463
|
y.errorMessage !== "" ? (u(), V(Te, {
|
|
1463
1464
|
key: 3,
|
|
1464
1465
|
class: "!cl-bg-danger-light cl-border-danger-light cl-rounded cl-text-danger-dark",
|
|
1465
|
-
text: d(
|
|
1466
|
-
}, null, 8, ["text"])) :
|
|
1467
|
-
|
|
1466
|
+
text: d(e)("comboBox.errorMessage", { error: y.errorMessage })
|
|
1467
|
+
}, null, 8, ["text"])) : N("", !0),
|
|
1468
|
+
m.value ? (u(), V(He, {
|
|
1468
1469
|
key: 4,
|
|
1469
1470
|
"is-create-new-option": !0,
|
|
1470
|
-
text: d(
|
|
1471
|
+
text: d(e)("comboBox.addPrompt", { value: n.value, object: y.objectType }),
|
|
1471
1472
|
index: -1,
|
|
1472
1473
|
"selected-index": s.value,
|
|
1473
1474
|
class: "cl-px-2",
|
|
1474
1475
|
onCreateObject: b,
|
|
1475
|
-
onOptionHighlighted:
|
|
1476
|
-
}, null, 8, ["text", "selected-index"])) :
|
|
1476
|
+
onOptionHighlighted: z
|
|
1477
|
+
}, null, 8, ["text", "selected-index"])) : N("", !0),
|
|
1477
1478
|
y.errorMessage === "" && y.results !== null ? (u(), v("div", Tt, [
|
|
1478
|
-
(u(!0), v(F, null,
|
|
1479
|
-
key:
|
|
1480
|
-
option:
|
|
1481
|
-
index:
|
|
1479
|
+
(u(!0), v(F, null, Q(y.results, (Z, ie) => (u(), V(He, {
|
|
1480
|
+
key: ie,
|
|
1481
|
+
option: Z,
|
|
1482
|
+
index: ie,
|
|
1482
1483
|
class: "cl-px-2",
|
|
1483
1484
|
"selected-index": s.value,
|
|
1484
|
-
onSelectObject:
|
|
1485
|
-
onOptionHighlighted:
|
|
1485
|
+
onSelectObject: g,
|
|
1486
|
+
onOptionHighlighted: z
|
|
1486
1487
|
}, null, 8, ["option", "index", "selected-index"]))), 128))
|
|
1487
|
-
])) :
|
|
1488
|
+
])) : N("", !0)
|
|
1488
1489
|
], 40, kt);
|
|
1489
1490
|
};
|
|
1490
1491
|
}
|
|
1491
|
-
}), Ot = { class: "cl-flex" },
|
|
1492
|
+
}), Ot = { class: "cl-flex" }, qt = { class: "cl-relative cl-right-20 cl-top-0.5" }, At = { class: "cl-absolute cl-flex cl-float-right cl-font-semibold cl-mt-2 cl-text-danger-default cl-text-sm cl-z-10" }, St = { class: "cl-min-h-[16rem] cl-mx-4" }, Nt = { class: "cl-p-2 cl-text-right cl-w-full" }, jt = /* @__PURE__ */ M({
|
|
1492
1493
|
__name: "cl-ui-combo-box",
|
|
1493
1494
|
props: {
|
|
1494
1495
|
loading: { type: Boolean, default: !1 },
|
|
@@ -1503,7 +1504,9 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1503
1504
|
parentObjectCreatedResponse: { default: null },
|
|
1504
1505
|
results: { default: () => [] },
|
|
1505
1506
|
parentResults: { default: () => [] },
|
|
1506
|
-
currentObject: {}
|
|
1507
|
+
currentObject: {},
|
|
1508
|
+
placeholderText: { default: null },
|
|
1509
|
+
searchHint: { default: null }
|
|
1507
1510
|
},
|
|
1508
1511
|
emits: {
|
|
1509
1512
|
focus: null,
|
|
@@ -1513,124 +1516,124 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1513
1516
|
"create-parent-object": null,
|
|
1514
1517
|
"update:current-object": null
|
|
1515
1518
|
},
|
|
1516
|
-
setup(t, { expose: o, emit:
|
|
1517
|
-
const
|
|
1518
|
-
get: () =>
|
|
1519
|
-
set: (C) =>
|
|
1520
|
-
}),
|
|
1521
|
-
function T(C) {
|
|
1522
|
-
var se, x;
|
|
1523
|
-
const G = ((se = ve.value) == null ? void 0 : se.getBoundingClientRect().top) || 0;
|
|
1524
|
-
h.value = window.innerHeight - G < 280, l.disabled || (typeof C < "u" ? p.value = C : p.value = !p.value), (x = a.value) == null || x.blur();
|
|
1525
|
-
}
|
|
1526
|
-
function k(C) {
|
|
1527
|
-
m.value = C, e("search", C);
|
|
1528
|
-
}
|
|
1529
|
-
function B(C) {
|
|
1530
|
-
b.value = C, e("search-parent", C);
|
|
1531
|
-
}
|
|
1532
|
-
function O() {
|
|
1533
|
-
s.value = null, T(!1);
|
|
1534
|
-
}
|
|
1519
|
+
setup(t, { expose: o, emit: l }) {
|
|
1520
|
+
const e = t, n = S(() => e.placeholderText ? e.placeholderText : s("comboBox.emptyHintText", { object: e.objectType })), m = S(() => e.searchHint ? e.searchHint : s("comboBox.searchHint", { object: e.objectType })), { t: s } = oe(), a = A(!1), i = S({
|
|
1521
|
+
get: () => e.currentObject,
|
|
1522
|
+
set: (C) => l("update:current-object", C)
|
|
1523
|
+
}), c = A(null), g = A(null), b = S(() => be()), r = A(""), w = A(""), h = A(), q = A(!0), $ = A(!1);
|
|
1535
1524
|
function R(C) {
|
|
1536
|
-
|
|
1537
|
-
|
|
1525
|
+
var f, E;
|
|
1526
|
+
const G = ((f = he.value) == null ? void 0 : f.getBoundingClientRect().top) || 0;
|
|
1527
|
+
$.value = window.innerHeight - G < 280, e.disabled || (typeof C < "u" ? a.value = C : a.value = !a.value), (E = c.value) == null || E.blur();
|
|
1528
|
+
}
|
|
1529
|
+
function O(C) {
|
|
1530
|
+
r.value = C, l("search", C);
|
|
1538
1531
|
}
|
|
1539
1532
|
function z(C) {
|
|
1533
|
+
w.value = C, l("search-parent", C);
|
|
1534
|
+
}
|
|
1535
|
+
function U() {
|
|
1536
|
+
i.value = null, R(!1);
|
|
1537
|
+
}
|
|
1538
|
+
function y(C) {
|
|
1539
|
+
const G = D(C);
|
|
1540
|
+
i.value = G, R(!1);
|
|
1541
|
+
}
|
|
1542
|
+
function D(C) {
|
|
1540
1543
|
let G = null;
|
|
1541
|
-
if (
|
|
1542
|
-
for (let
|
|
1543
|
-
if (
|
|
1544
|
-
G =
|
|
1544
|
+
if (e.results !== null) {
|
|
1545
|
+
for (let f = 0; f < e.results.length; f++)
|
|
1546
|
+
if (e.results[f].id === C) {
|
|
1547
|
+
G = e.results[f];
|
|
1545
1548
|
break;
|
|
1546
1549
|
}
|
|
1547
1550
|
}
|
|
1548
1551
|
return G;
|
|
1549
1552
|
}
|
|
1550
|
-
function
|
|
1553
|
+
function J() {
|
|
1551
1554
|
var C;
|
|
1552
|
-
|
|
1553
|
-
name:
|
|
1554
|
-
parentId: ((C =
|
|
1555
|
-
},
|
|
1556
|
-
}
|
|
1557
|
-
function
|
|
1558
|
-
|
|
1559
|
-
name:
|
|
1555
|
+
h.value = {
|
|
1556
|
+
name: r.value,
|
|
1557
|
+
parentId: ((C = g.value) == null ? void 0 : C.id) ?? 0
|
|
1558
|
+
}, l("create-object", h.value);
|
|
1559
|
+
}
|
|
1560
|
+
function Z() {
|
|
1561
|
+
h.value = {
|
|
1562
|
+
name: w.value,
|
|
1560
1563
|
parentId: 0
|
|
1561
|
-
},
|
|
1564
|
+
}, l("create-parent-object", h.value);
|
|
1562
1565
|
}
|
|
1563
|
-
function
|
|
1566
|
+
function ie() {
|
|
1564
1567
|
var C, G;
|
|
1565
|
-
(C =
|
|
1566
|
-
message:
|
|
1568
|
+
(C = e.objectCreatedResponse) != null && C.error ? Ve({
|
|
1569
|
+
message: s("comboBox.createFailed", { name: r.value, error: e.objectCreatedResponse.error }),
|
|
1567
1570
|
colour: "danger",
|
|
1568
1571
|
duration: 1e4
|
|
1569
|
-
}) : (G =
|
|
1572
|
+
}) : (G = e.objectCreatedResponse) != null && G.id && ve();
|
|
1570
1573
|
}
|
|
1571
|
-
function
|
|
1574
|
+
function Ne() {
|
|
1572
1575
|
var C;
|
|
1573
|
-
(C =
|
|
1574
|
-
id:
|
|
1575
|
-
name:
|
|
1576
|
+
(C = e.parentObjectCreatedResponse) != null && C.id && (g.value = {
|
|
1577
|
+
id: e.parentObjectCreatedResponse.id,
|
|
1578
|
+
name: e.parentObjectCreatedResponse.name ?? ""
|
|
1576
1579
|
});
|
|
1577
1580
|
}
|
|
1578
|
-
function
|
|
1579
|
-
var G,
|
|
1581
|
+
function ve() {
|
|
1582
|
+
var G, f, E, B, pe;
|
|
1580
1583
|
Ve({
|
|
1581
|
-
message:
|
|
1584
|
+
message: s("comboBox.createSuccessful", { object: e.objectType, name: ((G = e.objectCreatedResponse) == null ? void 0 : G.name) ?? "" }),
|
|
1582
1585
|
colour: "primary",
|
|
1583
1586
|
duration: 1e4
|
|
1584
1587
|
});
|
|
1585
1588
|
let C = "";
|
|
1586
|
-
|
|
1587
|
-
id: ((
|
|
1588
|
-
name: ((
|
|
1589
|
-
parentId: ((
|
|
1589
|
+
g.value && g.value.id === ((f = e.objectCreatedResponse) == null ? void 0 : f.parentId) && (C = g.value.name), i.value = {
|
|
1590
|
+
id: ((E = e.objectCreatedResponse) == null ? void 0 : E.id) ?? 0,
|
|
1591
|
+
name: ((B = e.objectCreatedResponse) == null ? void 0 : B.name) ?? "",
|
|
1592
|
+
parentId: ((pe = e.objectCreatedResponse) == null ? void 0 : pe.parentId) ?? 0,
|
|
1590
1593
|
parentName: C
|
|
1591
1594
|
};
|
|
1592
1595
|
}
|
|
1593
|
-
function
|
|
1596
|
+
function be() {
|
|
1594
1597
|
let C = "";
|
|
1595
|
-
return
|
|
1598
|
+
return i.value && (i.value.parentName ? C = i.value.parentName + "; " + i.value.name : C = i.value.name), C;
|
|
1596
1599
|
}
|
|
1597
|
-
function
|
|
1600
|
+
function ke() {
|
|
1598
1601
|
let C = !0;
|
|
1599
|
-
|
|
1602
|
+
r.value === "" && (C = !1), e.objectParentType !== "" && g.value === null && (C = !1), q.value = C;
|
|
1600
1603
|
}
|
|
1601
|
-
|
|
1604
|
+
K(() => e.objectCreatedResponse, () => ie()), K(() => e.parentObjectCreatedResponse, () => Ne()), K(() => r.value, () => ke()), K(() => g.value, () => ke()), o({
|
|
1602
1605
|
focus() {
|
|
1603
1606
|
var C;
|
|
1604
|
-
(C =
|
|
1607
|
+
(C = c.value) == null || C.focus();
|
|
1605
1608
|
}
|
|
1606
1609
|
});
|
|
1607
|
-
const
|
|
1608
|
-
return ze(
|
|
1609
|
-
const
|
|
1610
|
+
const he = A();
|
|
1611
|
+
return ze(he, () => a.value ? R(!1) : ""), (C, G) => {
|
|
1612
|
+
const f = nl("cl-ui-combo-box", !0);
|
|
1610
1613
|
return u(), v("div", {
|
|
1611
1614
|
ref_key: "outsideRef",
|
|
1612
|
-
ref:
|
|
1615
|
+
ref: he,
|
|
1613
1616
|
class: "cl-relative"
|
|
1614
1617
|
}, [
|
|
1615
|
-
|
|
1616
|
-
|
|
1618
|
+
p("div", Ot, [
|
|
1619
|
+
k(ae, {
|
|
1617
1620
|
ref_key: "inputRef",
|
|
1618
|
-
ref:
|
|
1619
|
-
modelValue:
|
|
1620
|
-
"onUpdate:modelValue": G[0] || (G[0] = (
|
|
1621
|
+
ref: c,
|
|
1622
|
+
modelValue: b.value,
|
|
1623
|
+
"onUpdate:modelValue": G[0] || (G[0] = (E) => b.value = E),
|
|
1621
1624
|
class: _(["!cl-mr-0 cl-mb-0 cl-rounded-r-none cl-w-full cl-z-10", {
|
|
1622
1625
|
"cl-cursor-pointer": C.disabled === !1
|
|
1623
1626
|
}]),
|
|
1624
1627
|
"input-type": "text",
|
|
1625
|
-
"placeholder-text":
|
|
1626
|
-
onFocus: G[1] || (G[1] = (
|
|
1627
|
-
|
|
1628
|
+
"placeholder-text": n.value,
|
|
1629
|
+
onFocus: G[1] || (G[1] = (E) => {
|
|
1630
|
+
R(), C.$emit("focus");
|
|
1628
1631
|
})
|
|
1629
1632
|
}, null, 8, ["modelValue", "class", "placeholder-text"]),
|
|
1630
|
-
L(
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1633
|
+
L(p("div", qt, [
|
|
1634
|
+
p("div", At, [
|
|
1635
|
+
ee(T(d(s)("comboBox.required")) + " ", 1),
|
|
1636
|
+
k(d(I), {
|
|
1634
1637
|
class: "cl-ml-1 cl-mt-1",
|
|
1635
1638
|
icon: "ph:warning"
|
|
1636
1639
|
})
|
|
@@ -1638,15 +1641,15 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1638
1641
|
], 512), [
|
|
1639
1642
|
[H, C.required && C.disabled === !1 && C.currentObject === null]
|
|
1640
1643
|
]),
|
|
1641
|
-
|
|
1644
|
+
a.value ? (u(), v("div", {
|
|
1642
1645
|
key: 1,
|
|
1643
1646
|
class: _(["cl-bg-white cl-border cl-border-grey-1 cl-float-right cl-h-10 cl-rounded cl-rounded-l-none cl-text-grey-3 cl-transition-colors cl-w-[27px] hover:cl-bg-link-light hover:cl-opacity-90 hover:cl-text-white", {
|
|
1644
1647
|
"cl-cursor-default": C.disabled,
|
|
1645
1648
|
"cl-cursor-pointer": C.disabled === !1
|
|
1646
1649
|
}]),
|
|
1647
|
-
onClick: G[3] || (G[3] = (
|
|
1650
|
+
onClick: G[3] || (G[3] = (E) => R(!1))
|
|
1648
1651
|
}, [
|
|
1649
|
-
|
|
1652
|
+
k(d(I), {
|
|
1650
1653
|
icon: "ph:caret-up-bold",
|
|
1651
1654
|
class: "cl-ml-[5px] cl-mt-[12px]"
|
|
1652
1655
|
})
|
|
@@ -1656,20 +1659,20 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1656
1659
|
"cl-cursor-default": C.disabled,
|
|
1657
1660
|
"cl-cursor-pointer": C.disabled === !1
|
|
1658
1661
|
}]),
|
|
1659
|
-
onClick: G[2] || (G[2] = (
|
|
1662
|
+
onClick: G[2] || (G[2] = (E) => R(!0))
|
|
1660
1663
|
}, [
|
|
1661
|
-
|
|
1664
|
+
k(d(I), {
|
|
1662
1665
|
icon: "ph:caret-down-bold",
|
|
1663
1666
|
class: "cl-ml-[5px] cl-mt-[12px]"
|
|
1664
1667
|
})
|
|
1665
1668
|
], 2))
|
|
1666
1669
|
]),
|
|
1667
|
-
|
|
1670
|
+
k(Ye, { size: "small" }, {
|
|
1668
1671
|
title: P(() => [
|
|
1669
|
-
|
|
1672
|
+
ee(T(d(s)("comboBox.createTitle", { object: C.objectType })), 1)
|
|
1670
1673
|
]),
|
|
1671
|
-
trigger: P(({ open:
|
|
1672
|
-
L(
|
|
1674
|
+
trigger: P(({ open: E }) => [
|
|
1675
|
+
L(k(Et, {
|
|
1673
1676
|
"can-create-new-object": C.canCreateNewObject,
|
|
1674
1677
|
"can-clear-selected-object": C.canClearSelectedObject,
|
|
1675
1678
|
loading: C.loading,
|
|
@@ -1677,53 +1680,54 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1677
1680
|
"object-type": C.objectType,
|
|
1678
1681
|
"object-parent-type": C.objectParentType,
|
|
1679
1682
|
"error-message": C.errorMessage,
|
|
1680
|
-
"current-object-name":
|
|
1681
|
-
"is-visible":
|
|
1683
|
+
"current-object-name": b.value,
|
|
1684
|
+
"is-visible": a.value,
|
|
1682
1685
|
class: _({
|
|
1683
|
-
"cl-bottom-full":
|
|
1686
|
+
"cl-bottom-full": $.value
|
|
1684
1687
|
}),
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1688
|
+
"search-hint": m.value,
|
|
1689
|
+
onCreateObject: E,
|
|
1690
|
+
onSelectObject: y,
|
|
1691
|
+
onClearObject: U,
|
|
1692
|
+
onSearch: O
|
|
1693
|
+
}, 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"]), [
|
|
1694
|
+
[H, a.value]
|
|
1691
1695
|
])
|
|
1692
1696
|
]),
|
|
1693
|
-
footer: P(({ close:
|
|
1694
|
-
|
|
1695
|
-
|
|
1697
|
+
footer: P(({ close: E }) => [
|
|
1698
|
+
p("div", Nt, [
|
|
1699
|
+
k(fe, {
|
|
1696
1700
|
class: "cl-mr-3",
|
|
1697
1701
|
colour: "default",
|
|
1698
1702
|
size: "small",
|
|
1699
|
-
onClick:
|
|
1703
|
+
onClick: E
|
|
1700
1704
|
}, {
|
|
1701
1705
|
default: P(() => [
|
|
1702
|
-
|
|
1706
|
+
ee(T(d(s)("comboBox.cancel")), 1)
|
|
1703
1707
|
]),
|
|
1704
1708
|
_: 2
|
|
1705
1709
|
}, 1032, ["onClick"]),
|
|
1706
|
-
|
|
1710
|
+
k(fe, {
|
|
1707
1711
|
colour: "primary",
|
|
1708
1712
|
size: "small",
|
|
1709
|
-
disabled: !
|
|
1710
|
-
onClick: (
|
|
1711
|
-
|
|
1713
|
+
disabled: !q.value,
|
|
1714
|
+
onClick: (B) => {
|
|
1715
|
+
J(), E();
|
|
1712
1716
|
}
|
|
1713
1717
|
}, {
|
|
1714
1718
|
default: P(() => [
|
|
1715
|
-
|
|
1719
|
+
ee(T(d(s)("comboBox.create")), 1)
|
|
1716
1720
|
]),
|
|
1717
1721
|
_: 2
|
|
1718
1722
|
}, 1032, ["disabled", "onClick"])
|
|
1719
1723
|
])
|
|
1720
1724
|
]),
|
|
1721
1725
|
default: P(() => [
|
|
1722
|
-
|
|
1723
|
-
C.objectParentType ? (u(), V(
|
|
1726
|
+
p("div", St, [
|
|
1727
|
+
C.objectParentType ? (u(), V(f, {
|
|
1724
1728
|
key: 0,
|
|
1725
|
-
"current-object":
|
|
1726
|
-
"onUpdate:currentObject": G[4] || (G[4] = (
|
|
1729
|
+
"current-object": g.value,
|
|
1730
|
+
"onUpdate:currentObject": G[4] || (G[4] = (E) => g.value = E),
|
|
1727
1731
|
class: "cl-mt-3",
|
|
1728
1732
|
results: C.parentResults,
|
|
1729
1733
|
loading: C.loading,
|
|
@@ -1732,13 +1736,13 @@ const ie = /* @__PURE__ */ fe(mt, [["__scopeId", "data-v-d01c4a47"]]), gt = { cl
|
|
|
1732
1736
|
"can-create-new-object": C.canCreateNewObject,
|
|
1733
1737
|
"can-clear-selected-object": C.canClearSelectedObject,
|
|
1734
1738
|
"error-message": C.errorMessage,
|
|
1735
|
-
onSearch:
|
|
1736
|
-
onCreateObject:
|
|
1737
|
-
}, null, 8, ["current-object", "results", "loading", "object-type", "object-created-response", "can-create-new-object", "can-clear-selected-object", "error-message"])) :
|
|
1738
|
-
|
|
1739
|
-
modelValue:
|
|
1740
|
-
"onUpdate:modelValue": G[5] || (G[5] = (
|
|
1741
|
-
label: d(
|
|
1739
|
+
onSearch: z,
|
|
1740
|
+
onCreateObject: Z
|
|
1741
|
+
}, null, 8, ["current-object", "results", "loading", "object-type", "object-created-response", "can-create-new-object", "can-clear-selected-object", "error-message"])) : N("", !0),
|
|
1742
|
+
k(ae, {
|
|
1743
|
+
modelValue: r.value,
|
|
1744
|
+
"onUpdate:modelValue": G[5] || (G[5] = (E) => r.value = E),
|
|
1745
|
+
label: d(s)("comboBox.createProperty"),
|
|
1742
1746
|
class: "cl-mb-2 cl-pt-3 cl-w-full",
|
|
1743
1747
|
"input-type": "text"
|
|
1744
1748
|
}, null, 8, ["modelValue", "label"])
|
|
@@ -1766,31 +1770,31 @@ const Rt = {}, zt = { class: "cl-flex cl-flex-wrap cl-left-0 cl-mt-4 cl-w-full"
|
|
|
1766
1770
|
function Dt(t, o) {
|
|
1767
1771
|
return u(), v("div", zt, [
|
|
1768
1772
|
t.$slots.default ? (u(), v("div", Ut, [
|
|
1769
|
-
|
|
1770
|
-
])) :
|
|
1773
|
+
j(t.$slots, "default")
|
|
1774
|
+
])) : N("", !0),
|
|
1771
1775
|
t.$slots.left || t.$slots.right ? (u(), v("div", Bt, [
|
|
1772
|
-
|
|
1773
|
-
|
|
1776
|
+
p("span", Mt, [
|
|
1777
|
+
j(t.$slots, "left")
|
|
1774
1778
|
]),
|
|
1775
|
-
|
|
1776
|
-
|
|
1779
|
+
p("span", Vt, [
|
|
1780
|
+
j(t.$slots, "right")
|
|
1777
1781
|
])
|
|
1778
|
-
])) :
|
|
1782
|
+
])) : N("", !0)
|
|
1779
1783
|
]);
|
|
1780
1784
|
}
|
|
1781
|
-
const Lt = /* @__PURE__ */
|
|
1785
|
+
const Lt = /* @__PURE__ */ de(Rt, [["render", Dt]]);
|
|
1782
1786
|
function Oe(t) {
|
|
1783
|
-
const o = t.type !== "slot" || t.slotType !== void 0 && t.field !== void 0,
|
|
1784
|
-
return o &&
|
|
1787
|
+
const o = t.type !== "slot" || t.slotType !== void 0 && t.field !== void 0, l = t.sortable ?? !0;
|
|
1788
|
+
return o && l;
|
|
1785
1789
|
}
|
|
1786
1790
|
function Ue(t) {
|
|
1787
|
-
const o = t.type !== "slot" || t.slotType !== void 0 && t.field !== void 0,
|
|
1788
|
-
return o &&
|
|
1791
|
+
const o = t.type !== "slot" || t.slotType !== void 0 && t.field !== void 0, l = t.filterable ?? !0;
|
|
1792
|
+
return o && l;
|
|
1789
1793
|
}
|
|
1790
|
-
const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1 cl-grid cl-grid-cols-2 cl-justify-end cl-mb-2 lg:cl-flex lg:cl-gap-2" }, Ht = { class: "cl-basis-0 cl-col-span-2 cl-flex-grow" }, Gt = /* @__PURE__ */
|
|
1794
|
+
const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1 cl-grid cl-grid-cols-2 cl-justify-end cl-mb-2 lg:cl-flex lg:cl-gap-2" }, Ht = { class: "cl-basis-0 cl-col-span-2 cl-flex-grow" }, Gt = /* @__PURE__ */ p("hr", { class: "cl-block cl-border-grey-3 cl-col-span-2 cl-my-4 lg:cl-hidden" }, null, -1), xt = {
|
|
1791
1795
|
key: 1,
|
|
1792
1796
|
class: "cl-hidden lg:cl-block"
|
|
1793
|
-
},
|
|
1797
|
+
}, Zt = { class: "cl-block lg:cl-hidden" }, Wt = /* @__PURE__ */ M({
|
|
1794
1798
|
__name: "cl-ui-grid-action-row",
|
|
1795
1799
|
props: {
|
|
1796
1800
|
editMode: { type: Boolean },
|
|
@@ -1802,64 +1806,64 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
1802
1806
|
},
|
|
1803
1807
|
emits: ["update:edit-mode", "update:filterPanelOpen", "clear-filters"],
|
|
1804
1808
|
setup(t) {
|
|
1805
|
-
const { t: o } =
|
|
1806
|
-
return (
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
+
const { t: o } = oe();
|
|
1810
|
+
return (l, e) => (u(), v(F, null, [
|
|
1811
|
+
p("div", Pt, [
|
|
1812
|
+
p("strong", null, T(d(o)("grid.gridTools")), 1)
|
|
1809
1813
|
]),
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
loading:
|
|
1814
|
-
editMode:
|
|
1814
|
+
p("div", Ft, [
|
|
1815
|
+
p("div", Ht, [
|
|
1816
|
+
j(l.$slots, "additional-grid-actions", le(ne({
|
|
1817
|
+
loading: l.loading,
|
|
1818
|
+
editMode: l.editMode
|
|
1815
1819
|
})))
|
|
1816
1820
|
]),
|
|
1817
1821
|
Gt,
|
|
1818
|
-
|
|
1822
|
+
l.columns.some((n) => n.editable) ? (u(), V(fe, {
|
|
1819
1823
|
key: 0,
|
|
1820
1824
|
size: "small",
|
|
1821
1825
|
colour: "default",
|
|
1822
|
-
onClick:
|
|
1826
|
+
onClick: e[0] || (e[0] = W((n) => l.$emit("update:edit-mode", !l.editMode), ["prevent"]))
|
|
1823
1827
|
}, {
|
|
1824
1828
|
default: P(() => [
|
|
1825
|
-
|
|
1826
|
-
|
|
1829
|
+
l.editMode ? (u(), v(F, { key: 0 }, [
|
|
1830
|
+
ee(T(d(o)("grid.finishEditing")), 1)
|
|
1827
1831
|
], 64)) : (u(), v(F, { key: 1 }, [
|
|
1828
|
-
|
|
1832
|
+
ee(T(d(o)("grid.editData")), 1)
|
|
1829
1833
|
], 64))
|
|
1830
1834
|
]),
|
|
1831
1835
|
_: 1
|
|
1832
|
-
})) :
|
|
1833
|
-
|
|
1834
|
-
|
|
1836
|
+
})) : N("", !0),
|
|
1837
|
+
l.options.hideViewManager ? N("", !0) : (u(), v("div", xt, [
|
|
1838
|
+
j(l.$slots, "view-manager")
|
|
1835
1839
|
])),
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1840
|
+
l.columns.some((n) => d(Ue)(n) || d(Oe)(n)) ? (u(), v(F, { key: 2 }, [
|
|
1841
|
+
p("div", Zt, [
|
|
1842
|
+
k(fe, {
|
|
1839
1843
|
class: "cl-w-full",
|
|
1840
1844
|
size: "small",
|
|
1841
|
-
onClick:
|
|
1845
|
+
onClick: e[1] || (e[1] = W((n) => l.$emit("update:filterPanelOpen", !l.filterPanelOpen), ["prevent"]))
|
|
1842
1846
|
}, {
|
|
1843
1847
|
default: P(() => [
|
|
1844
|
-
|
|
1848
|
+
ee(T(d(o)("grid.modifyFilters")), 1)
|
|
1845
1849
|
]),
|
|
1846
1850
|
_: 1
|
|
1847
1851
|
})
|
|
1848
1852
|
]),
|
|
1849
|
-
|
|
1853
|
+
k(fe, {
|
|
1850
1854
|
size: "small",
|
|
1851
|
-
colour:
|
|
1855
|
+
colour: l.request.filters.some((n) => n.filterValue !== "") ? "danger" : "default",
|
|
1852
1856
|
class: _({
|
|
1853
|
-
"cl-col-span-2":
|
|
1857
|
+
"cl-col-span-2": l.columns.some((n) => n.editable)
|
|
1854
1858
|
}),
|
|
1855
|
-
onClick:
|
|
1859
|
+
onClick: e[2] || (e[2] = W((n) => l.$emit("clear-filters"), ["prevent"]))
|
|
1856
1860
|
}, {
|
|
1857
1861
|
default: P(() => [
|
|
1858
|
-
|
|
1862
|
+
ee(T(d(o)("grid.clearFilters")), 1)
|
|
1859
1863
|
]),
|
|
1860
1864
|
_: 1
|
|
1861
1865
|
}, 8, ["colour", "class"])
|
|
1862
|
-
], 64)) :
|
|
1866
|
+
], 64)) : N("", !0)
|
|
1863
1867
|
])
|
|
1864
1868
|
], 64));
|
|
1865
1869
|
}
|
|
@@ -1875,7 +1879,7 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
1875
1879
|
}, Yt = {
|
|
1876
1880
|
key: 1,
|
|
1877
1881
|
class: "cl-inline-block cl-whitespace-nowrap"
|
|
1878
|
-
}, Ge = /* @__PURE__ */
|
|
1882
|
+
}, Ge = /* @__PURE__ */ M({
|
|
1879
1883
|
__name: "cl-ui-grid-cell-value",
|
|
1880
1884
|
props: {
|
|
1881
1885
|
data: {},
|
|
@@ -1883,28 +1887,28 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
1883
1887
|
timeZone: {}
|
|
1884
1888
|
},
|
|
1885
1889
|
setup(t) {
|
|
1886
|
-
const o = t, { t:
|
|
1887
|
-
function
|
|
1888
|
-
const i =
|
|
1889
|
-
locale:
|
|
1890
|
+
const o = t, { t: l, locale: e, n } = oe();
|
|
1891
|
+
function m(s, a) {
|
|
1892
|
+
const i = $e.fromISO(s, {
|
|
1893
|
+
locale: e.value
|
|
1890
1894
|
}).setZone(o.timeZone);
|
|
1891
1895
|
let c = "";
|
|
1892
1896
|
switch (a) {
|
|
1893
|
-
case
|
|
1894
|
-
case
|
|
1897
|
+
case x.SHORT_DATE:
|
|
1898
|
+
case x.DATE:
|
|
1895
1899
|
c = i.toFormat("D");
|
|
1896
1900
|
break;
|
|
1897
|
-
case
|
|
1901
|
+
case x.LONG_DATE:
|
|
1898
1902
|
c = i.toFormat("DDD");
|
|
1899
1903
|
break;
|
|
1900
|
-
case
|
|
1901
|
-
case
|
|
1904
|
+
case x.SHORT_DATETIME:
|
|
1905
|
+
case x.DATETIME:
|
|
1902
1906
|
c = i.toFormat("f");
|
|
1903
1907
|
break;
|
|
1904
|
-
case
|
|
1908
|
+
case x.LONG_DATETIME:
|
|
1905
1909
|
c = i.toFormat("fff");
|
|
1906
1910
|
break;
|
|
1907
|
-
case
|
|
1911
|
+
case x.TIME:
|
|
1908
1912
|
c = i.toFormat("t");
|
|
1909
1913
|
break;
|
|
1910
1914
|
}
|
|
@@ -1912,25 +1916,25 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
1912
1916
|
}
|
|
1913
1917
|
return (s, a) => {
|
|
1914
1918
|
var i;
|
|
1915
|
-
return s.column.type === "slot" ?
|
|
1919
|
+
return s.column.type === "slot" ? j(s.$slots, s.column.name, { key: 0 }) : s.column.type === "boolean" && s.column.field !== void 0 ? (u(), V(ae, {
|
|
1916
1920
|
key: 1,
|
|
1917
1921
|
"input-type": "checkbox",
|
|
1918
1922
|
"model-value": s.data[s.column.field],
|
|
1919
1923
|
disabled: !0
|
|
1920
1924
|
}, null, 8, ["model-value"])) : (s.column.type === "date" || s.column.type === "datetime") && s.column.field !== void 0 ? (u(), v(F, { key: 2 }, [
|
|
1921
1925
|
s.column.format !== void 0 ? (u(), v(F, { key: 0 }, [
|
|
1922
|
-
|
|
1926
|
+
ee(T(m(s.data[s.column.field], s.column.format)), 1)
|
|
1923
1927
|
], 64)) : s.column.type === "date" ? (u(), v(F, { key: 1 }, [
|
|
1924
|
-
|
|
1928
|
+
ee(T(m(s.data[s.column.field], d(x).DATE)), 1)
|
|
1925
1929
|
], 64)) : (u(), v(F, { key: 2 }, [
|
|
1926
|
-
|
|
1930
|
+
ee(T(m(s.data[s.column.field], d(x).DATETIME)), 1)
|
|
1927
1931
|
], 64))
|
|
1928
|
-
], 64)) : s.column.type === "list" && s.column.field !== void 0 && s.column.listEntries !== void 0 ? (u(), v("span", Kt,
|
|
1929
|
-
s.column.maxLength !== void 0 ? (u(), v("span", Jt,
|
|
1930
|
-
], 64)) :
|
|
1932
|
+
], 64)) : s.column.type === "list" && s.column.field !== void 0 && s.column.listEntries !== void 0 ? (u(), v("span", Kt, T(d(l)(((i = s.column.listEntries.find((c) => c.value === s.data[s.column.field])) == null ? void 0 : i.translationKey) ?? "")), 1)) : s.column.type === "number" && s.column.field !== void 0 ? (u(), v("span", Qt, T(d(n)(s.data[s.column.field], s.column.format ?? d(Y).DECIMAL)), 1)) : s.column.field !== void 0 ? (u(), v(F, { key: 5 }, [
|
|
1933
|
+
s.column.maxLength !== void 0 ? (u(), v("span", Jt, T(s.data[s.column.field].trimToLength(s.column.maxLength, s.column.format !== void 0 ? s.column.format === "ellipsis" : !1)), 1)) : (u(), v("span", Yt, T(s.data[s.column.field]), 1))
|
|
1934
|
+
], 64)) : N("", !0);
|
|
1931
1935
|
};
|
|
1932
1936
|
}
|
|
1933
|
-
}), Xt = { class: "cl-font-semibold lg:cl-hidden" }, eo = /* @__PURE__ */
|
|
1937
|
+
}), Xt = { class: "cl-font-semibold lg:cl-hidden" }, eo = /* @__PURE__ */ M({
|
|
1934
1938
|
__name: "cl-ui-grid-cell",
|
|
1935
1939
|
props: {
|
|
1936
1940
|
data: {},
|
|
@@ -1940,38 +1944,38 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
1940
1944
|
},
|
|
1941
1945
|
emits: ["edit", "focus", "undo"],
|
|
1942
1946
|
setup(t, { emit: o }) {
|
|
1943
|
-
const
|
|
1947
|
+
const l = t, { t: e } = oe(), n = A(re(l.data)), m = S(() => l.column.field !== void 0 && n.value[l.column.field] !== l.data[l.column.field]), s = S(() => {
|
|
1944
1948
|
var a;
|
|
1945
|
-
return ((a =
|
|
1949
|
+
return ((a = l.column.listEntries) == null ? void 0 : a.map((i, c) => ({
|
|
1946
1950
|
id: c,
|
|
1947
|
-
name:
|
|
1951
|
+
name: e(i.translationKey)
|
|
1948
1952
|
}))) ?? [];
|
|
1949
1953
|
});
|
|
1950
|
-
return sl(() => n.value =
|
|
1951
|
-
const i =
|
|
1952
|
-
i !== "" && (a[i] !==
|
|
1954
|
+
return sl(() => n.value = re(l.data)), K(n, (a) => {
|
|
1955
|
+
const i = l.column.field ?? "";
|
|
1956
|
+
i !== "" && (a[i] !== l.data[i] ? o("edit", a[i]) : o("undo"));
|
|
1953
1957
|
}, {
|
|
1954
1958
|
deep: !0
|
|
1955
1959
|
}), (a, i) => (u(), v("td", {
|
|
1956
1960
|
class: _(["cl-border-b cl-border-grey-1 cl-gap-1 cl-grid cl-grid-cols-2 cl-m-1 cl-mb-0 cl-py-2 cl-text-xs lg:cl-border-b-0 lg:cl-m-0 lg:cl-px-1 lg:cl-table-cell lg:cl-text-base", {
|
|
1957
|
-
"cl-bg-link-lighter":
|
|
1961
|
+
"cl-bg-link-lighter": m.value
|
|
1958
1962
|
}])
|
|
1959
1963
|
}, [
|
|
1960
|
-
|
|
1961
|
-
a.editMode && a.column.editable === !0 ?
|
|
1964
|
+
p("span", Xt, T(a.column.caption), 1),
|
|
1965
|
+
a.editMode && a.column.editable === !0 ? j(a.$slots, `${a.column.name}Edit`, le(se({ key: 0 }, {
|
|
1962
1966
|
cellFocused: () => o("focus"),
|
|
1963
1967
|
column: a.column,
|
|
1964
|
-
edited:
|
|
1968
|
+
edited: m.value,
|
|
1965
1969
|
record: n.value,
|
|
1966
1970
|
listEntries: s.value
|
|
1967
1971
|
})), () => [
|
|
1968
|
-
|
|
1972
|
+
k(Ge, {
|
|
1969
1973
|
column: a.column,
|
|
1970
1974
|
data: a.data,
|
|
1971
1975
|
"time-zone": a.timeZone
|
|
1972
1976
|
}, {
|
|
1973
1977
|
[a.column.name]: P(() => [
|
|
1974
|
-
|
|
1978
|
+
j(a.$slots, a.column.name, le(ne({ column: a.column, record: a.data })))
|
|
1975
1979
|
]),
|
|
1976
1980
|
_: 2
|
|
1977
1981
|
}, 1032, ["column", "data", "time-zone"])
|
|
@@ -1982,13 +1986,13 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
1982
1986
|
"time-zone": a.timeZone
|
|
1983
1987
|
}, {
|
|
1984
1988
|
[a.column.name]: P(() => [
|
|
1985
|
-
|
|
1989
|
+
j(a.$slots, a.column.name, le(ne({ column: a.column, record: a.data })))
|
|
1986
1990
|
]),
|
|
1987
1991
|
_: 2
|
|
1988
1992
|
}, 1032, ["column", "data", "time-zone"]))
|
|
1989
1993
|
], 2));
|
|
1990
1994
|
}
|
|
1991
|
-
}), lo = /* @__PURE__ */
|
|
1995
|
+
}), lo = /* @__PURE__ */ M({
|
|
1992
1996
|
__name: "cl-ui-grid-row",
|
|
1993
1997
|
props: {
|
|
1994
1998
|
data: {},
|
|
@@ -1998,21 +2002,21 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
1998
2002
|
},
|
|
1999
2003
|
emits: ["cell-focus", "cell-edit", "cell-undo", "row-select"],
|
|
2000
2004
|
setup(t) {
|
|
2001
|
-
return (o,
|
|
2002
|
-
(u(!0), v(F, null,
|
|
2005
|
+
return (o, l) => (u(), v("tr", null, [
|
|
2006
|
+
(u(!0), v(F, null, Q(o.columns, (e, n) => (u(), V(eo, {
|
|
2003
2007
|
key: n,
|
|
2004
2008
|
data: o.data,
|
|
2005
|
-
column:
|
|
2009
|
+
column: e,
|
|
2006
2010
|
"time-zone": o.timeZone,
|
|
2007
2011
|
"edit-mode": o.editMode,
|
|
2008
|
-
onFocus:
|
|
2009
|
-
onEdit: (
|
|
2010
|
-
onUndo: (
|
|
2012
|
+
onFocus: l[0] || (l[0] = (m) => o.$emit("cell-focus")),
|
|
2013
|
+
onEdit: (m) => o.$emit("cell-edit", { field: e.field, value: m }),
|
|
2014
|
+
onUndo: (m) => o.$emit("cell-undo", e.field)
|
|
2011
2015
|
}, Re({ _: 2 }, [
|
|
2012
|
-
|
|
2016
|
+
Q(o.$slots, (m, s) => ({
|
|
2013
2017
|
name: s,
|
|
2014
2018
|
fn: P((a) => [
|
|
2015
|
-
|
|
2019
|
+
j(o.$slots, s, le(ne(a)))
|
|
2016
2020
|
])
|
|
2017
2021
|
}))
|
|
2018
2022
|
]), 1032, ["data", "column", "time-zone", "edit-mode", "onEdit", "onUndo"]))), 128))
|
|
@@ -2021,7 +2025,7 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
2021
2025
|
}), to = { key: 1 }, oo = ["colspan"], no = { class: "cl-flex cl-flex-wrap cl-justify-center cl-text-center cl-text-sm cl-w-full" }, so = { class: "cl-mt-6 cl-w-full" }, ao = {
|
|
2022
2026
|
key: 0,
|
|
2023
2027
|
class: "cl-mt-4"
|
|
2024
|
-
}, ro = { class: "cl-mb-2 cl-w-full" }, io = /* @__PURE__ */
|
|
2028
|
+
}, ro = { class: "cl-mb-2 cl-w-full" }, io = /* @__PURE__ */ M({
|
|
2025
2029
|
__name: "cl-ui-grid-body",
|
|
2026
2030
|
props: {
|
|
2027
2031
|
columns: {},
|
|
@@ -2034,15 +2038,15 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
2034
2038
|
},
|
|
2035
2039
|
emits: ["row-select", "row-edit", "clear-filters"],
|
|
2036
2040
|
setup(t, { emit: o }) {
|
|
2037
|
-
const
|
|
2041
|
+
const l = t, { t: e } = oe(), n = A({
|
|
2038
2042
|
index: -1,
|
|
2039
2043
|
record: {}
|
|
2040
2044
|
});
|
|
2041
|
-
function
|
|
2042
|
-
Object.keys(n.value.record).length !== 0 && (o("row-edit",
|
|
2045
|
+
function m() {
|
|
2046
|
+
Object.keys(n.value.record).length !== 0 && (o("row-edit", re(n.value)), n.value.record = {});
|
|
2043
2047
|
}
|
|
2044
2048
|
function s(r) {
|
|
2045
|
-
n.value.index !== -1 && n.value.index !== r &&
|
|
2049
|
+
n.value.index !== -1 && n.value.index !== r && m(), n.value.index = r;
|
|
2046
2050
|
}
|
|
2047
2051
|
function a(r, w) {
|
|
2048
2052
|
s(r), w.field !== void 0 && (n.value.record[w.field] = w.value);
|
|
@@ -2056,15 +2060,15 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
2056
2060
|
}
|
|
2057
2061
|
}
|
|
2058
2062
|
const c = A({});
|
|
2059
|
-
|
|
2063
|
+
K(() => l.data, () => {
|
|
2060
2064
|
var r, w;
|
|
2061
|
-
return c.value = Object.fromEntries(((w = (r =
|
|
2062
|
-
[
|
|
2065
|
+
return c.value = Object.fromEntries(((w = (r = l.data) == null ? void 0 : r.results) == null ? void 0 : w.map((h, q) => [
|
|
2066
|
+
[q],
|
|
2063
2067
|
{
|
|
2064
2068
|
count: 0,
|
|
2065
2069
|
target: null,
|
|
2066
2070
|
reset: We(() => {
|
|
2067
|
-
c.value[
|
|
2071
|
+
c.value[q] && (c.value[q].count = 0, b(c.value[q].target), c.value[q].target = null);
|
|
2068
2072
|
}, 2500, { immediate: !1 })
|
|
2069
2073
|
}
|
|
2070
2074
|
])) ?? []);
|
|
@@ -2072,65 +2076,65 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
2072
2076
|
deep: !0,
|
|
2073
2077
|
immediate: !0
|
|
2074
2078
|
});
|
|
2075
|
-
function
|
|
2076
|
-
const { currentTarget:
|
|
2077
|
-
|
|
2079
|
+
function g(r, w, h) {
|
|
2080
|
+
const { currentTarget: q } = h;
|
|
2081
|
+
l.selectionEnabled ? o("row-select", w) : (c.value[r].count++, c.value[r].target = q, c.value[r].count > 1 ? (c.value[r].reset.stop(), c.value[r].count = 0, b(q), c.value[r].target = null, o("row-select", w)) : (c.value[r].reset.start(), b(q)));
|
|
2078
2082
|
}
|
|
2079
2083
|
function b(r) {
|
|
2080
2084
|
r == null || r.classList.toggle("!cl-bg-link-lighter");
|
|
2081
2085
|
}
|
|
2082
|
-
return
|
|
2083
|
-
|
|
2086
|
+
return K(() => l.editMode, () => {
|
|
2087
|
+
l.editMode || (m(), n.value.index = -1);
|
|
2084
2088
|
}), (r, w) => {
|
|
2085
2089
|
var h;
|
|
2086
2090
|
return u(), v("tbody", null, [
|
|
2087
|
-
r.data && ((h = r.data.results) != null && h.length) ? (u(!0), v(F, { key: 0 },
|
|
2088
|
-
key:
|
|
2089
|
-
data:
|
|
2091
|
+
r.data && ((h = r.data.results) != null && h.length) ? (u(!0), v(F, { key: 0 }, Q(r.data.results, (q, $) => (u(), V(lo, {
|
|
2092
|
+
key: $,
|
|
2093
|
+
data: q,
|
|
2090
2094
|
columns: r.columns,
|
|
2091
2095
|
"time-zone": r.timeZone,
|
|
2092
2096
|
"edit-mode": r.editMode,
|
|
2093
2097
|
class: _(["cl-bg-opacity-100 cl-cursor-pointer cl-transition-colors", {
|
|
2094
|
-
"cl-bg-white":
|
|
2095
|
-
"cl-bg-off-white":
|
|
2098
|
+
"cl-bg-white": $ % 2 === 0 && r.data.totalRecords > 1,
|
|
2099
|
+
"cl-bg-off-white": $ % 2 === 1 || r.data.totalRecords === 1,
|
|
2096
2100
|
"cl-cursor-pointer hover:cl-bg-link-lighter": r.selectionEnabled && !r.editMode
|
|
2097
2101
|
}]),
|
|
2098
|
-
onClick: (
|
|
2099
|
-
r.editMode ||
|
|
2102
|
+
onClick: (R) => {
|
|
2103
|
+
r.editMode || g($, q, R);
|
|
2100
2104
|
},
|
|
2101
|
-
onCellFocus: (
|
|
2102
|
-
s(
|
|
2105
|
+
onCellFocus: (R) => {
|
|
2106
|
+
s($);
|
|
2103
2107
|
},
|
|
2104
|
-
onCellEdit: (
|
|
2105
|
-
a(
|
|
2108
|
+
onCellEdit: (R) => {
|
|
2109
|
+
a($, R);
|
|
2106
2110
|
},
|
|
2107
2111
|
onCellUndo: i
|
|
2108
2112
|
}, Re({ _: 2 }, [
|
|
2109
|
-
|
|
2113
|
+
Q(r.$slots, (R, O) => ({
|
|
2110
2114
|
name: O,
|
|
2111
|
-
fn: P((
|
|
2112
|
-
|
|
2115
|
+
fn: P((z) => [
|
|
2116
|
+
j(r.$slots, O, le(ne(z)))
|
|
2113
2117
|
])
|
|
2114
2118
|
}))
|
|
2115
|
-
]), 1032, ["data", "columns", "time-zone", "edit-mode", "class", "onClick", "onCellFocus", "onCellEdit"]))), 128)) : r.loading ?
|
|
2116
|
-
|
|
2119
|
+
]), 1032, ["data", "columns", "time-zone", "edit-mode", "class", "onClick", "onCellFocus", "onCellEdit"]))), 128)) : r.loading ? N("", !0) : (u(), v("tr", to, [
|
|
2120
|
+
p("td", {
|
|
2117
2121
|
colspan: r.columns.length
|
|
2118
2122
|
}, [
|
|
2119
|
-
|
|
2120
|
-
|
|
2123
|
+
p("div", no, [
|
|
2124
|
+
p("strong", so, T(d(e)("grid.noData")), 1),
|
|
2121
2125
|
r.request.filters.length > 0 ? (u(), v("div", ao, [
|
|
2122
|
-
|
|
2123
|
-
|
|
2126
|
+
p("div", ro, T(d(e)("grid.noDataFiltersPresent")), 1),
|
|
2127
|
+
k(fe, {
|
|
2124
2128
|
size: "small",
|
|
2125
2129
|
colour: "danger",
|
|
2126
|
-
onClick: w[0] || (w[0] =
|
|
2130
|
+
onClick: w[0] || (w[0] = W((q) => r.$emit("clear-filters"), ["prevent"]))
|
|
2127
2131
|
}, {
|
|
2128
2132
|
default: P(() => [
|
|
2129
|
-
|
|
2133
|
+
ee(T(d(e)("grid.clearFilters")), 1)
|
|
2130
2134
|
]),
|
|
2131
2135
|
_: 1
|
|
2132
2136
|
})
|
|
2133
|
-
])) :
|
|
2137
|
+
])) : N("", !0)
|
|
2134
2138
|
])
|
|
2135
2139
|
], 8, oo)
|
|
2136
2140
|
]))
|
|
@@ -2140,7 +2144,7 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
2140
2144
|
}), co = {
|
|
2141
2145
|
key: 0,
|
|
2142
2146
|
class: "cl-flex cl-flex-wrap cl-justify-end cl-mt-2 cl-w-full"
|
|
2143
|
-
}, 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 cl-shadow-md cl-text-sm cl-w-full lg:cl-w-auto" }, po = { class: "cl-text-grey-3 cl-w-max" }, fo = { 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 cl-shadow-md cl-text-sm cl-w-full lg:cl-ml-2 lg:cl-w-auto mb:cl-flex-nowrap" }, mo = { 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" }, go = { class: "cl-flex cl-flex-wrap cl-mb-2 cl-w-full lg:cl-mb-0 lg:cl-mr-2 lg:cl-w-auto" }, vo = { class: "cl-text-grey-3 cl-w-full lg:cl-mr-2 lg:cl-w-auto" }, bo = { class: "cl-flex cl-flex-wrap cl-text-sm mb:cl-flex-nowrap" }, ho = { class: "cl-pr-2" }, yo = ["onClick"], wo = { 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" }, $o = { class: "cl-mb-2 cl-text-grey-3 cl-w-full lg:cl-mb-0 lg:cl-mr-2 lg:cl-w-auto" }, ko = ["onClick"], Co = { class: "cl-mb-2 cl-w-full lg:cl-p-2 md:cl-mb-0 md:cl-w-auto" }, To = { 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" }, Eo = { class: "cl-block lg:cl-inline-block" }, Oo = /* @__PURE__ */
|
|
2147
|
+
}, 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 cl-shadow-md cl-text-sm cl-w-full lg:cl-w-auto" }, po = { class: "cl-text-grey-3 cl-w-max" }, fo = { 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 cl-shadow-md cl-text-sm cl-w-full lg:cl-ml-2 lg:cl-w-auto mb:cl-flex-nowrap" }, mo = { 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" }, go = { class: "cl-flex cl-flex-wrap cl-mb-2 cl-w-full lg:cl-mb-0 lg:cl-mr-2 lg:cl-w-auto" }, vo = { class: "cl-text-grey-3 cl-w-full lg:cl-mr-2 lg:cl-w-auto" }, bo = { class: "cl-flex cl-flex-wrap cl-text-sm mb:cl-flex-nowrap" }, ho = { class: "cl-pr-2" }, yo = ["onClick"], wo = { 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" }, $o = { class: "cl-mb-2 cl-text-grey-3 cl-w-full lg:cl-mb-0 lg:cl-mr-2 lg:cl-w-auto" }, ko = ["onClick"], Co = { class: "cl-mb-2 cl-w-full lg:cl-p-2 md:cl-mb-0 md:cl-w-auto" }, To = { 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" }, Eo = { class: "cl-block lg:cl-inline-block" }, Oo = /* @__PURE__ */ M({
|
|
2144
2148
|
__name: "cl-ui-grid-footer",
|
|
2145
2149
|
props: {
|
|
2146
2150
|
request: {},
|
|
@@ -2150,21 +2154,21 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
2150
2154
|
"update:request": null
|
|
2151
2155
|
},
|
|
2152
2156
|
setup(t, { emit: o }) {
|
|
2153
|
-
const
|
|
2157
|
+
const l = t, { n: e, t: n } = oe(), m = S(() => {
|
|
2154
2158
|
var r;
|
|
2155
|
-
return
|
|
2156
|
-
}), s =
|
|
2157
|
-
const r = Array.from(Array(
|
|
2159
|
+
return l.data !== null ? Math.ceil((((r = l.data) == null ? void 0 : r.totalRecords) ?? 0) / l.request.pageSize) : 1;
|
|
2160
|
+
}), s = S(() => {
|
|
2161
|
+
const r = Array.from(Array(m.value + 1).keys());
|
|
2158
2162
|
let w = [];
|
|
2159
2163
|
if (r.shift(), r.length) {
|
|
2160
|
-
const h =
|
|
2164
|
+
const h = l.request.pageNumber === m.value || l.request.pageNumber === m.value - 1 ? m.value - 3 : l.request.pageNumber - 1;
|
|
2161
2165
|
w = r.slice(h, h + 3);
|
|
2162
2166
|
}
|
|
2163
2167
|
return w;
|
|
2164
2168
|
});
|
|
2165
2169
|
function a(r) {
|
|
2166
|
-
const w =
|
|
2167
|
-
w.pageNumber !== r && (w.pageNumber = Math.max(Math.min(Math.trunc(r),
|
|
2170
|
+
const w = re(l.request);
|
|
2171
|
+
w.pageNumber !== r && (w.pageNumber = Math.max(Math.min(Math.trunc(r), m.value), 1), o("update:request", w));
|
|
2168
2172
|
}
|
|
2169
2173
|
function i(r) {
|
|
2170
2174
|
const w = parseInt(r == null ? void 0 : r.value) || 1;
|
|
@@ -2178,108 +2182,108 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
2178
2182
|
100,
|
|
2179
2183
|
200
|
|
2180
2184
|
];
|
|
2181
|
-
function
|
|
2182
|
-
const w =
|
|
2185
|
+
function g(r) {
|
|
2186
|
+
const w = re(l.request);
|
|
2183
2187
|
w.pageSize = r, w.pageNumber = 1, o("update:request", w);
|
|
2184
2188
|
}
|
|
2185
2189
|
const b = Ke(i, 750);
|
|
2186
2190
|
return (r, w) => {
|
|
2187
|
-
var h,
|
|
2188
|
-
return (
|
|
2189
|
-
|
|
2190
|
-
|
|
2191
|
-
|
|
2191
|
+
var h, q;
|
|
2192
|
+
return (q = (h = r.data) == null ? void 0 : h.results) != null && q.length && r.request ? (u(), v("div", co, [
|
|
2193
|
+
p("div", uo, [
|
|
2194
|
+
p("span", po, T(d(n)("grid.jumpToPage")), 1),
|
|
2195
|
+
k(ae, {
|
|
2192
2196
|
"model-value": r.request.pageNumber,
|
|
2193
2197
|
class: "cl-ml-1 cl-mt-0.5 cl-text-sm",
|
|
2194
2198
|
"input-type": "number",
|
|
2195
2199
|
label: "Page",
|
|
2196
2200
|
"show-label": !1,
|
|
2197
2201
|
min: "1",
|
|
2198
|
-
max:
|
|
2199
|
-
onInput: w[0] || (w[0] = (
|
|
2202
|
+
max: m.value,
|
|
2203
|
+
onInput: w[0] || (w[0] = ($) => d(b)($.target))
|
|
2200
2204
|
}, null, 8, ["model-value", "max"])
|
|
2201
2205
|
]),
|
|
2202
|
-
|
|
2203
|
-
|
|
2204
|
-
|
|
2205
|
-
|
|
2206
|
+
p("div", fo, [
|
|
2207
|
+
p("div", mo, [
|
|
2208
|
+
p("li", go, [
|
|
2209
|
+
p("span", vo, T(d(n)("grid.page")), 1)
|
|
2206
2210
|
]),
|
|
2207
|
-
|
|
2208
|
-
|
|
2209
|
-
L(
|
|
2211
|
+
p("ul", bo, [
|
|
2212
|
+
p("li", ho, T(d(e)(r.request.pageNumber, d(Y).INTEGER)) + " / " + T(d(e)(m.value, d(Y).INTEGER)), 1),
|
|
2213
|
+
L(p("li", {
|
|
2210
2214
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
2211
|
-
onClick: w[1] || (w[1] = (
|
|
2215
|
+
onClick: w[1] || (w[1] = ($) => a(1))
|
|
2212
2216
|
}, [
|
|
2213
|
-
|
|
2217
|
+
k(d(I), {
|
|
2214
2218
|
icon: "ph:caret-double-left",
|
|
2215
2219
|
size: 14
|
|
2216
2220
|
})
|
|
2217
2221
|
], 512), [
|
|
2218
2222
|
[H, r.request.pageNumber > 1]
|
|
2219
2223
|
]),
|
|
2220
|
-
L(
|
|
2224
|
+
L(p("li", {
|
|
2221
2225
|
class: "cl-cursor-pointer cl-mt-1 lg:cl-mr-2 mr-1",
|
|
2222
|
-
onClick: w[2] || (w[2] = (
|
|
2226
|
+
onClick: w[2] || (w[2] = ($) => a(r.request.pageNumber - 1))
|
|
2223
2227
|
}, [
|
|
2224
|
-
|
|
2228
|
+
k(d(I), {
|
|
2225
2229
|
icon: "ph:caret-left",
|
|
2226
2230
|
size: 14
|
|
2227
2231
|
})
|
|
2228
2232
|
], 512), [
|
|
2229
2233
|
[H, r.request.pageNumber > 1]
|
|
2230
2234
|
]),
|
|
2231
|
-
(u(!0), v(F, null,
|
|
2232
|
-
key:
|
|
2235
|
+
(u(!0), v(F, null, Q(s.value, ($, R) => (u(), v("li", {
|
|
2236
|
+
key: R,
|
|
2233
2237
|
class: _(["cl-cursor-pointer cl-mr-1 lg:cl-mr-2", {
|
|
2234
|
-
"cl-text-black cl-font-bold": r.request.pageNumber ===
|
|
2235
|
-
"cl-text-grey-6": r.request.pageNumber !==
|
|
2238
|
+
"cl-text-black cl-font-bold": r.request.pageNumber === $,
|
|
2239
|
+
"cl-text-grey-6": r.request.pageNumber !== $
|
|
2236
2240
|
}]),
|
|
2237
|
-
onClick: (O) => a(
|
|
2238
|
-
},
|
|
2239
|
-
L(
|
|
2241
|
+
onClick: (O) => a($)
|
|
2242
|
+
}, T(d(e)($, d(Y).INTEGER)), 11, yo))), 128)),
|
|
2243
|
+
L(p("li", {
|
|
2240
2244
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
2241
|
-
onClick: w[3] || (w[3] = (
|
|
2245
|
+
onClick: w[3] || (w[3] = ($) => a(r.request.pageNumber + 1))
|
|
2242
2246
|
}, [
|
|
2243
|
-
|
|
2247
|
+
k(d(I), {
|
|
2244
2248
|
icon: "ph:caret-right",
|
|
2245
2249
|
size: 14
|
|
2246
2250
|
})
|
|
2247
2251
|
], 512), [
|
|
2248
|
-
[H, r.request.pageNumber <
|
|
2252
|
+
[H, r.request.pageNumber < m.value]
|
|
2249
2253
|
]),
|
|
2250
|
-
L(
|
|
2254
|
+
L(p("li", {
|
|
2251
2255
|
class: "cl-cursor-pointer cl-mr-1 cl-mt-1 lg:cl-mr-2",
|
|
2252
|
-
onClick: w[4] || (w[4] = (
|
|
2256
|
+
onClick: w[4] || (w[4] = ($) => a(m.value))
|
|
2253
2257
|
}, [
|
|
2254
|
-
|
|
2258
|
+
k(d(I), {
|
|
2255
2259
|
icon: "ph:caret-double-right",
|
|
2256
2260
|
size: 14
|
|
2257
2261
|
})
|
|
2258
2262
|
], 512), [
|
|
2259
|
-
[H, r.request.pageNumber <
|
|
2263
|
+
[H, r.request.pageNumber < m.value]
|
|
2260
2264
|
])
|
|
2261
2265
|
])
|
|
2262
2266
|
]),
|
|
2263
|
-
|
|
2264
|
-
|
|
2265
|
-
(u(), v(F, null,
|
|
2266
|
-
key:
|
|
2267
|
+
p("ul", wo, [
|
|
2268
|
+
p("li", $o, T(d(n)("grid.pageSize")), 1),
|
|
2269
|
+
(u(), v(F, null, Q(c, ($, R) => p("li", {
|
|
2270
|
+
key: R,
|
|
2267
2271
|
class: _(["cl-cursor-pointer cl-mr-1 lg:cl-mr-2", {
|
|
2268
|
-
"cl-text-black cl-font-bold": r.request.pageSize ===
|
|
2269
|
-
"cl-text-grey-6": r.request.pageSize !==
|
|
2272
|
+
"cl-text-black cl-font-bold": r.request.pageSize === $,
|
|
2273
|
+
"cl-text-grey-6": r.request.pageSize !== $
|
|
2270
2274
|
}]),
|
|
2271
|
-
onClick: (O) =>
|
|
2272
|
-
},
|
|
2275
|
+
onClick: (O) => g($)
|
|
2276
|
+
}, T(d(e)($, d(Y).INTEGER)), 11, ko)), 64))
|
|
2273
2277
|
]),
|
|
2274
|
-
|
|
2275
|
-
|
|
2276
|
-
|
|
2278
|
+
p("ul", Co, [
|
|
2279
|
+
p("li", To, T(d(n)("grid.totalRecords")), 1),
|
|
2280
|
+
p("li", Eo, T(d(e)(r.data.totalRecords, d(Y).INTEGER)), 1)
|
|
2277
2281
|
])
|
|
2278
2282
|
])
|
|
2279
|
-
])) :
|
|
2283
|
+
])) : N("", !0);
|
|
2280
2284
|
};
|
|
2281
2285
|
}
|
|
2282
|
-
}),
|
|
2286
|
+
}), qo = [
|
|
2283
2287
|
"string",
|
|
2284
2288
|
"boolean",
|
|
2285
2289
|
"number",
|
|
@@ -2291,11 +2295,11 @@ const Pt = { class: "cl-mb-2 cl-text-sm lg:cl-hidden" }, Ft = { class: "cl-gap-1
|
|
|
2291
2295
|
function Xe(t) {
|
|
2292
2296
|
return typeof t.caption == "string" && typeof t.name == "string" && typeof t.type == "string";
|
|
2293
2297
|
}
|
|
2294
|
-
function
|
|
2298
|
+
function Ao(t) {
|
|
2295
2299
|
let o = Array.isArray(t);
|
|
2296
2300
|
if (o) {
|
|
2297
|
-
for (const
|
|
2298
|
-
if (!Xe(
|
|
2301
|
+
for (const l of t)
|
|
2302
|
+
if (!Xe(l)) {
|
|
2299
2303
|
o = !1;
|
|
2300
2304
|
break;
|
|
2301
2305
|
}
|
|
@@ -2303,7 +2307,7 @@ function qo(t) {
|
|
|
2303
2307
|
return o;
|
|
2304
2308
|
}
|
|
2305
2309
|
const So = ["ellipsis"];
|
|
2306
|
-
var
|
|
2310
|
+
var te = /* @__PURE__ */ ((t) => (t[t.CONTAINS = 0] = "CONTAINS", t[t.NOT_CONTAINS = 1] = "NOT_CONTAINS", t[t.EQUAL = 2] = "EQUAL", t[t.NOT_EQUAL = 3] = "NOT_EQUAL", t[t.STARTS_WITH = 4] = "STARTS_WITH", t[t.ENDS_WITH = 5] = "ENDS_WITH", t[t.GREATER_THAN = 6] = "GREATER_THAN", t[t.LESS_THAN = 7] = "LESS_THAN", t[t.EQUAL_OR_GREATER_THAN = 8] = "EQUAL_OR_GREATER_THAN", t[t.EQUAL_OR_LESS_THAN = 9] = "EQUAL_OR_LESS_THAN", t))(te || {});
|
|
2307
2311
|
const No = [
|
|
2308
2312
|
"equal",
|
|
2309
2313
|
"notequal",
|
|
@@ -2325,8 +2329,8 @@ function _o(t) {
|
|
|
2325
2329
|
function Io(t) {
|
|
2326
2330
|
let o = typeof t.filters == "object" && Array.isArray(t.filters) && typeof t.pageNumber == "number" && typeof t.pageSize == "number" && typeof t.sort == "object" && _o(t.sort);
|
|
2327
2331
|
if (o) {
|
|
2328
|
-
for (const
|
|
2329
|
-
if (!jo(
|
|
2332
|
+
for (const l of t.filters)
|
|
2333
|
+
if (!jo(l)) {
|
|
2330
2334
|
o = !1;
|
|
2331
2335
|
break;
|
|
2332
2336
|
}
|
|
@@ -2334,15 +2338,15 @@ function Io(t) {
|
|
|
2334
2338
|
return o;
|
|
2335
2339
|
}
|
|
2336
2340
|
function Ro(t, o) {
|
|
2337
|
-
let
|
|
2338
|
-
if (
|
|
2339
|
-
for (const
|
|
2340
|
-
if (!o(
|
|
2341
|
-
|
|
2341
|
+
let l = typeof t.results == "object" && Array.isArray(t.results) && typeof t.totalRecords == "number";
|
|
2342
|
+
if (l) {
|
|
2343
|
+
for (const e of t.results)
|
|
2344
|
+
if (!o(e)) {
|
|
2345
|
+
l = !1;
|
|
2342
2346
|
break;
|
|
2343
2347
|
}
|
|
2344
2348
|
}
|
|
2345
|
-
return
|
|
2349
|
+
return l;
|
|
2346
2350
|
}
|
|
2347
2351
|
const zo = {
|
|
2348
2352
|
method: "equal",
|
|
@@ -2371,7 +2375,7 @@ const zo = {
|
|
|
2371
2375
|
"datetime"
|
|
2372
2376
|
],
|
|
2373
2377
|
key: "before"
|
|
2374
|
-
},
|
|
2378
|
+
}, xe = [
|
|
2375
2379
|
Uo,
|
|
2376
2380
|
{
|
|
2377
2381
|
method: "notcontains",
|
|
@@ -2459,7 +2463,7 @@ const zo = {
|
|
|
2459
2463
|
description: "Less than",
|
|
2460
2464
|
allowedTypes: ["number"]
|
|
2461
2465
|
}
|
|
2462
|
-
], Mo = { class: "cl-group cl-inline cl-relative cl-w-auto" }, Vo = { class: "cl-bg-off-white cl-border-grey-1 cl-border-r cl-flex cl-h-full cl-items-center cl-justify-center cl-rounded-md cl-w-10" }, Do = { class: "cl-p-2 cl-select-none" }, Lo = ["onClick"], Po = /* @__PURE__ */
|
|
2466
|
+
], Mo = { class: "cl-group cl-inline cl-relative cl-w-auto" }, Vo = { class: "cl-bg-off-white cl-border-grey-1 cl-border-r cl-flex cl-h-full cl-items-center cl-justify-center cl-rounded-md cl-w-10" }, Do = { class: "cl-p-2 cl-select-none" }, Lo = ["onClick"], Po = /* @__PURE__ */ M({
|
|
2463
2467
|
__name: "cl-ui-grid-method-selector",
|
|
2464
2468
|
props: {
|
|
2465
2469
|
filter: {},
|
|
@@ -2469,30 +2473,30 @@ const zo = {
|
|
|
2469
2473
|
},
|
|
2470
2474
|
emits: ["update:filter"],
|
|
2471
2475
|
setup(t, { emit: o }) {
|
|
2472
|
-
const
|
|
2476
|
+
const l = t, { t: e } = oe(), n = S(() => {
|
|
2473
2477
|
let a = [];
|
|
2474
|
-
return
|
|
2475
|
-
i.description =
|
|
2478
|
+
return l.column.type !== "slot" ? a = xe.filter((i) => i.allowedTypes.includes(l.column.type)) : typeof l.column.slotType < "u" && typeof l.column.field < "u" && (a = xe.filter((i) => i.allowedTypes.includes(l.column.slotType))), l.column.type === "date" || l.column.type === "datetime" || l.column.slotType === "date" || l.column.slotType === "datetime" ? a.forEach((i) => {
|
|
2479
|
+
i.description = e(`grid.${i.key}`);
|
|
2476
2480
|
}) : a.forEach((i) => {
|
|
2477
|
-
i.description =
|
|
2481
|
+
i.description = e(`grid.${i.method}`);
|
|
2478
2482
|
}), a;
|
|
2479
|
-
}),
|
|
2483
|
+
}), m = S(() => {
|
|
2480
2484
|
var i;
|
|
2481
|
-
let a = (i =
|
|
2482
|
-
return typeof a > "u" && (a =
|
|
2483
|
-
var
|
|
2484
|
-
return c.method.toLowerCase() === ((
|
|
2485
|
+
let a = (i = l.filter) == null ? void 0 : i.filterMethod;
|
|
2486
|
+
return typeof a > "u" && (a = te[l.defaultOperation].toLowerCase()), n.value.find((c) => {
|
|
2487
|
+
var g;
|
|
2488
|
+
return c.method.toLowerCase() === ((g = a == null ? void 0 : a.removeNonAlphanumeric()) == null ? void 0 : g.toLowerCase());
|
|
2485
2489
|
});
|
|
2486
2490
|
});
|
|
2487
2491
|
function s(a) {
|
|
2488
2492
|
let i;
|
|
2489
|
-
if (
|
|
2490
|
-
i =
|
|
2491
|
-
else if (typeof
|
|
2493
|
+
if (l.filter)
|
|
2494
|
+
i = re(l.filter), i.filterOperation = te[a.toUpperCase()], i.filterMethod = a.toLowerCase();
|
|
2495
|
+
else if (typeof l.column.field < "u")
|
|
2492
2496
|
i = {
|
|
2493
|
-
filterOnColumn:
|
|
2497
|
+
filterOnColumn: l.column.field,
|
|
2494
2498
|
filterMethod: a.toLowerCase(),
|
|
2495
|
-
filterOperation:
|
|
2499
|
+
filterOperation: te[a.toUpperCase()],
|
|
2496
2500
|
filterValue: ""
|
|
2497
2501
|
};
|
|
2498
2502
|
else
|
|
@@ -2500,34 +2504,34 @@ const zo = {
|
|
|
2500
2504
|
o("update:filter", i);
|
|
2501
2505
|
}
|
|
2502
2506
|
return (a, i) => (u(), v("div", Mo, [
|
|
2503
|
-
|
|
2504
|
-
|
|
2507
|
+
p("div", Vo, [
|
|
2508
|
+
m.value ? (u(), V(d(I), {
|
|
2505
2509
|
key: 0,
|
|
2506
|
-
icon:
|
|
2510
|
+
icon: m.value.icon,
|
|
2507
2511
|
class: _(["cl-text-lg", {
|
|
2508
|
-
"cl-text-grey-4":
|
|
2509
|
-
"cl-text-primary-default":
|
|
2512
|
+
"cl-text-grey-4": l.filter === void 0 || l.filter.filterValue === "",
|
|
2513
|
+
"cl-text-primary-default": l.filter && l.filter.filterValue !== ""
|
|
2510
2514
|
}])
|
|
2511
|
-
}, null, 8, ["icon", "class"])) :
|
|
2515
|
+
}, null, 8, ["icon", "class"])) : N("", !0)
|
|
2512
2516
|
]),
|
|
2513
|
-
|
|
2517
|
+
p("div", {
|
|
2514
2518
|
class: _(["cl-absolute cl-bg-white cl-border cl-border-grey-0 cl-flex-wrap cl-font-normal cl-h-0 cl-hidden cl-rounded cl-shadow-lg cl-text-left cl-text-xs cl-top-8 cl-z-10 group-hover:cl-flex group-hover:cl-h-auto group-hover:cl-w-52", {
|
|
2515
2519
|
"cl-left-0": a.firstHalf,
|
|
2516
2520
|
"cl--left-44": !a.firstHalf
|
|
2517
2521
|
}])
|
|
2518
2522
|
}, [
|
|
2519
|
-
|
|
2520
|
-
(u(!0), v(F, null,
|
|
2523
|
+
p("strong", Do, T(d(e)("grid.availableMethods")), 1),
|
|
2524
|
+
(u(!0), v(F, null, Q(n.value, (c, g) => {
|
|
2521
2525
|
var b;
|
|
2522
2526
|
return u(), v("span", {
|
|
2523
|
-
key:
|
|
2527
|
+
key: g,
|
|
2524
2528
|
class: _(["cl-cursor-pointer cl-px-4 cl-py-1 cl-transition-colors cl-w-full hover:cl-bg-grey-0", {
|
|
2525
|
-
"cl-bg-primary-default cl-opacity-80": c.method === ((b =
|
|
2529
|
+
"cl-bg-primary-default cl-opacity-80": c.method === ((b = m.value) == null ? void 0 : b.method)
|
|
2526
2530
|
}]),
|
|
2527
|
-
onClick:
|
|
2531
|
+
onClick: W((r) => s(c.method), ["prevent"])
|
|
2528
2532
|
}, [
|
|
2529
|
-
|
|
2530
|
-
|
|
2533
|
+
ee(T(c.description) + " ", 1),
|
|
2534
|
+
k(d(I), {
|
|
2531
2535
|
icon: c.icon,
|
|
2532
2536
|
class: "cl-float-right cl-text-grey-4 cl-text-sm"
|
|
2533
2537
|
}, null, 8, ["icon"])
|
|
@@ -2539,7 +2543,7 @@ const zo = {
|
|
|
2539
2543
|
}), Fo = {
|
|
2540
2544
|
key: 0,
|
|
2541
2545
|
class: "cl-border cl-border-grey-2 cl-flex cl-overflow-hidden cl-rounded-md lg:cl-overflow-visible"
|
|
2542
|
-
}, Ho = /* @__PURE__ */
|
|
2546
|
+
}, Ho = /* @__PURE__ */ p("option", { value: void 0 }, null, -1), Go = ["selected"], xo = ["selected"], Zo = /* @__PURE__ */ p("option", { value: void 0 }, null, -1), Wo = ["value", "selected"], Ko = /* @__PURE__ */ M({
|
|
2543
2547
|
__name: "cl-ui-grid-filter",
|
|
2544
2548
|
props: {
|
|
2545
2549
|
filter: {},
|
|
@@ -2549,46 +2553,46 @@ const zo = {
|
|
|
2549
2553
|
},
|
|
2550
2554
|
emits: ["update:filter"],
|
|
2551
2555
|
setup(t, { emit: o }) {
|
|
2552
|
-
const
|
|
2553
|
-
function
|
|
2554
|
-
return
|
|
2556
|
+
const l = t, { locale: e, t: n } = oe();
|
|
2557
|
+
function m() {
|
|
2558
|
+
return l.column.type === "string" || l.column.slotType === "string" ? te.CONTAINS : l.column.type === "datetime" || l.column.slotType === "datetime" || l.column.type === "date" || l.column.slotType === "date" ? te.LESS_THAN : te.EQUAL;
|
|
2555
2559
|
}
|
|
2556
|
-
const s =
|
|
2557
|
-
get: () =>
|
|
2560
|
+
const s = S({
|
|
2561
|
+
get: () => l.filter,
|
|
2558
2562
|
set: (O) => o("update:filter", O)
|
|
2559
|
-
}), a =
|
|
2563
|
+
}), a = S(() => l.column.type === "date" || l.column.type === "datetime" || l.column.type === "slot" && (l.column.slotType === "date" || l.column.slotType === "datetime")), i = S(() => l.column.type === "list" || l.column.type === "slot" && l.column.slotType === "list"), c = S(() => i.value && l.column.listType === "number"), g = S({
|
|
2560
2564
|
get() {
|
|
2561
|
-
var
|
|
2562
|
-
let O = (
|
|
2563
|
-
if (O && a.value && (((
|
|
2564
|
-
const
|
|
2565
|
-
|
|
2566
|
-
filterOnColumn:
|
|
2567
|
-
filterOperation:
|
|
2565
|
+
var z, U, y, D;
|
|
2566
|
+
let O = (z = s.value) == null ? void 0 : z[0];
|
|
2567
|
+
if (O && a.value && (((U = l.filter) == null ? void 0 : U.length) ?? 0 > 1)) {
|
|
2568
|
+
const J = (y = s.value) == null ? void 0 : y.find((ie) => ie.filterOperation === te.EQUAL_OR_GREATER_THAN), Z = (D = s.value) == null ? void 0 : D.find((ie) => ie.filterOperation === te.LESS_THAN);
|
|
2569
|
+
J && Z && (O = {
|
|
2570
|
+
filterOnColumn: l.column.field,
|
|
2571
|
+
filterOperation: te.EQUAL,
|
|
2568
2572
|
filterMethod: "equal",
|
|
2569
|
-
filterValue:
|
|
2573
|
+
filterValue: J.filterValue
|
|
2570
2574
|
});
|
|
2571
2575
|
}
|
|
2572
2576
|
return O;
|
|
2573
2577
|
},
|
|
2574
2578
|
set(O) {
|
|
2575
2579
|
if (O && b(O.filterOperation, O.filterValue)) {
|
|
2576
|
-
let
|
|
2577
|
-
zone:
|
|
2580
|
+
let z = $e.fromISO(O.filterValue, {
|
|
2581
|
+
zone: l.timeZone
|
|
2578
2582
|
}).set({ second: 0, millisecond: 0 });
|
|
2579
|
-
const
|
|
2580
|
-
|
|
2581
|
-
const y =
|
|
2583
|
+
const U = z.toISO();
|
|
2584
|
+
l.column.type === "date" || l.column.type === "slot" && l.column.slotType === "date" ? z = z.plus({ days: 1 }) : z = z.plus({ minutes: 1 });
|
|
2585
|
+
const y = z.toISO();
|
|
2582
2586
|
s.value = [
|
|
2583
2587
|
{
|
|
2584
|
-
filterOnColumn:
|
|
2585
|
-
filterOperation:
|
|
2588
|
+
filterOnColumn: l.column.field,
|
|
2589
|
+
filterOperation: te.EQUAL_OR_GREATER_THAN,
|
|
2586
2590
|
filterMethod: "equalorgreaterthan",
|
|
2587
|
-
filterValue:
|
|
2591
|
+
filterValue: U
|
|
2588
2592
|
},
|
|
2589
2593
|
{
|
|
2590
|
-
filterOnColumn:
|
|
2591
|
-
filterOperation:
|
|
2594
|
+
filterOnColumn: l.column.field,
|
|
2595
|
+
filterOperation: te.LESS_THAN,
|
|
2592
2596
|
filterMethod: "lessthan",
|
|
2593
2597
|
filterValue: y
|
|
2594
2598
|
}
|
|
@@ -2597,52 +2601,52 @@ const zo = {
|
|
|
2597
2601
|
s.value = O && [O];
|
|
2598
2602
|
}
|
|
2599
2603
|
});
|
|
2600
|
-
function b(O,
|
|
2601
|
-
const
|
|
2602
|
-
return
|
|
2604
|
+
function b(O, z) {
|
|
2605
|
+
const U = z !== void 0 && z !== "", y = O === te.EQUAL;
|
|
2606
|
+
return U && y && a.value;
|
|
2603
2607
|
}
|
|
2604
|
-
const r =
|
|
2608
|
+
const r = S(() => {
|
|
2605
2609
|
var O;
|
|
2606
|
-
return ((O =
|
|
2607
|
-
}), w =
|
|
2608
|
-
function
|
|
2609
|
-
var
|
|
2610
|
-
let
|
|
2611
|
-
const D = ((O == null ? void 0 : O.value) ??
|
|
2612
|
-
if (
|
|
2613
|
-
y = ((
|
|
2614
|
-
else if (D !== "" && typeof
|
|
2615
|
-
const
|
|
2616
|
-
|
|
2617
|
-
filterOnColumn:
|
|
2618
|
-
filterMethod:
|
|
2619
|
-
filterOperation:
|
|
2610
|
+
return ((O = g.value) == null ? void 0 : O.filterValue) ?? "";
|
|
2611
|
+
}), w = S(() => r.value === "" ? null : r.value), h = S(() => Intl.NumberFormat(e.value).format(1.1).replace(/[0-9]+/g, "")), q = S(() => Ue(l.column));
|
|
2612
|
+
function $(O, z) {
|
|
2613
|
+
var J;
|
|
2614
|
+
let U, y = !1;
|
|
2615
|
+
const D = ((O == null ? void 0 : O.value) ?? z).trim();
|
|
2616
|
+
if (g.value)
|
|
2617
|
+
y = ((J = g.value) == null ? void 0 : J.filterValue) === D, U = re(g.value), U.filterValue = D;
|
|
2618
|
+
else if (D !== "" && typeof l.column.field < "u") {
|
|
2619
|
+
const Z = m();
|
|
2620
|
+
U = {
|
|
2621
|
+
filterOnColumn: l.column.field,
|
|
2622
|
+
filterMethod: te[Z].toLowerCase(),
|
|
2623
|
+
filterOperation: Z,
|
|
2620
2624
|
filterValue: D
|
|
2621
2625
|
};
|
|
2622
2626
|
} else
|
|
2623
2627
|
return;
|
|
2624
|
-
y === !1 && (
|
|
2628
|
+
y === !1 && (g.value = U);
|
|
2625
2629
|
}
|
|
2626
|
-
function
|
|
2627
|
-
let
|
|
2628
|
-
|
|
2630
|
+
function R(O, z) {
|
|
2631
|
+
let U, y = (O == null ? void 0 : O.value) ?? z ?? 0;
|
|
2632
|
+
l.column.format === Y.INTEGER ? (typeof y == "string" && (y = parseInt(y)), U = Math.round(y)) : (typeof y == "string" && (y = parseFloat(y.replace(h.value, "."))), U = y), $(null, isNaN(U) ? "" : U.toString());
|
|
2629
2633
|
}
|
|
2630
|
-
return (O,
|
|
2634
|
+
return (O, z) => q.value ? (u(), v("div", Fo, [
|
|
2631
2635
|
O.column.type === "boolean" || O.column.slotType === "boolean" ? (u(), v("select", {
|
|
2632
2636
|
key: 0,
|
|
2633
2637
|
class: "!cl-h-[2rem] cl-border-none cl-mb-0 cl-rounded-md cl-w-full",
|
|
2634
|
-
onChange:
|
|
2638
|
+
onChange: z[0] || (z[0] = (U) => $(U.target))
|
|
2635
2639
|
}, [
|
|
2636
2640
|
Ho,
|
|
2637
|
-
|
|
2641
|
+
p("option", {
|
|
2638
2642
|
value: "true",
|
|
2639
2643
|
selected: r.value === "true"
|
|
2640
|
-
},
|
|
2641
|
-
|
|
2644
|
+
}, T(d(n)("grid.true")), 9, Go),
|
|
2645
|
+
p("option", {
|
|
2642
2646
|
value: "false",
|
|
2643
2647
|
selected: r.value === "false"
|
|
2644
|
-
},
|
|
2645
|
-
], 32)) : O.column.type === "date" || O.column.type === "datetime" || O.column.slotType === "date" || O.column.slotType === "datetime" ? (u(), V(
|
|
2648
|
+
}, T(d(n)("grid.false")), 9, xo)
|
|
2649
|
+
], 32)) : O.column.type === "date" || O.column.type === "datetime" || O.column.slotType === "date" || O.column.slotType === "datetime" ? (u(), V(ae, {
|
|
2646
2650
|
key: 1,
|
|
2647
2651
|
"model-value": w.value,
|
|
2648
2652
|
class: "!cl-h-[2rem] !cl-text-xs cl-border-none cl-mb-0 cl-w-full lg:!cl-text-base",
|
|
@@ -2650,42 +2654,42 @@ const zo = {
|
|
|
2650
2654
|
"show-label": !1,
|
|
2651
2655
|
"input-type": O.column.type === "slot" ? O.column.slotType : O.column.type,
|
|
2652
2656
|
"time-zone": O.timeZone,
|
|
2653
|
-
"onUpdate:modelValue":
|
|
2654
|
-
}, null, 8, ["model-value", "label", "input-type", "time-zone"])) : O.column.type === "number" || O.column.slotType === "number" ? (u(), V(
|
|
2657
|
+
"onUpdate:modelValue": z[1] || (z[1] = (U) => $(null, U ?? ""))
|
|
2658
|
+
}, null, 8, ["model-value", "label", "input-type", "time-zone"])) : O.column.type === "number" || O.column.slotType === "number" ? (u(), V(ae, {
|
|
2655
2659
|
key: 2,
|
|
2656
2660
|
"model-value": r.value,
|
|
2657
2661
|
class: "!cl-h-[2rem] !cl-text-xs cl-border-none cl-mb-0 cl-w-full lg:!cl-text-base",
|
|
2658
2662
|
"input-type": "number",
|
|
2659
2663
|
"show-arrows": !1,
|
|
2660
|
-
onInput:
|
|
2661
|
-
}, null, 8, ["model-value"])) : O.column.type === "string" || O.column.slotType === "string" ? (u(), V(
|
|
2664
|
+
onInput: z[2] || (z[2] = (U, y) => R(null, y))
|
|
2665
|
+
}, null, 8, ["model-value"])) : O.column.type === "string" || O.column.slotType === "string" ? (u(), V(ae, {
|
|
2662
2666
|
key: 3,
|
|
2663
2667
|
"model-value": r.value,
|
|
2664
2668
|
class: "!cl-h-[2rem] !cl-text-xs cl-border-none cl-mb-0 cl-w-full lg:!cl-text-base",
|
|
2665
2669
|
"input-type": "text",
|
|
2666
|
-
onInput:
|
|
2670
|
+
onInput: z[3] || (z[3] = (U, y) => $(null, y))
|
|
2667
2671
|
}, null, 8, ["model-value"])) : i.value ? (u(), v("select", {
|
|
2668
2672
|
key: 4,
|
|
2669
2673
|
class: "!cl-h-[2rem] cl-border-none cl-mb-0 cl-rounded-md cl-w-full",
|
|
2670
|
-
onChange:
|
|
2674
|
+
onChange: z[4] || (z[4] = (U) => c.value ? R(U.target) : $(U.target))
|
|
2671
2675
|
}, [
|
|
2672
|
-
|
|
2673
|
-
(u(!0), v(F, null,
|
|
2674
|
-
key:
|
|
2675
|
-
value:
|
|
2676
|
-
selected: r.value ===
|
|
2677
|
-
},
|
|
2678
|
-
], 32)) :
|
|
2679
|
-
|
|
2680
|
-
filter:
|
|
2681
|
-
"onUpdate:filter":
|
|
2676
|
+
Zo,
|
|
2677
|
+
(u(!0), v(F, null, Q(O.column.listEntries ?? [], (U) => (u(), v("option", {
|
|
2678
|
+
key: U.value,
|
|
2679
|
+
value: U.value,
|
|
2680
|
+
selected: r.value === U.value.toString()
|
|
2681
|
+
}, T(d(n)(U.translationKey)), 9, Wo))), 128))
|
|
2682
|
+
], 32)) : N("", !0),
|
|
2683
|
+
k(Po, {
|
|
2684
|
+
filter: g.value,
|
|
2685
|
+
"onUpdate:filter": z[5] || (z[5] = (U) => g.value = U),
|
|
2682
2686
|
column: O.column,
|
|
2683
|
-
"default-operation":
|
|
2687
|
+
"default-operation": m(),
|
|
2684
2688
|
"first-half": O.firstHalf
|
|
2685
2689
|
}, null, 8, ["filter", "column", "default-operation", "first-half"])
|
|
2686
|
-
])) :
|
|
2690
|
+
])) : N("", !0);
|
|
2687
2691
|
}
|
|
2688
|
-
}), Qo = { class: "-cl-top-1 cl-bg-white cl-shadow-sm cl-sticky cl-z-30 lg:cl-bg-transparent lg:cl-relative lg:cl-shadow-none" }, Jo = { class: "cl-hidden lg:cl-table-row" }, Yo = ["onClick"], Xo = { class: "cl-flex cl-justify-end cl-w-full lg:cl-hidden" }, en = { class: "cl-col-span-2 lg:cl-hidden" }, ln = ["onClick"], tn = { class: "cl-font-normal cl-mr-1" }, on = /* @__PURE__ */
|
|
2692
|
+
}), Qo = { class: "-cl-top-1 cl-bg-white cl-shadow-sm cl-sticky cl-z-30 lg:cl-bg-transparent lg:cl-relative lg:cl-shadow-none" }, Jo = { class: "cl-hidden lg:cl-table-row" }, Yo = ["onClick"], Xo = { class: "cl-flex cl-justify-end cl-w-full lg:cl-hidden" }, en = { class: "cl-col-span-2 lg:cl-hidden" }, ln = ["onClick"], tn = { class: "cl-font-normal cl-mr-1" }, on = /* @__PURE__ */ M({
|
|
2689
2693
|
__name: "cl-ui-grid-header",
|
|
2690
2694
|
props: {
|
|
2691
2695
|
request: {},
|
|
@@ -2696,17 +2700,17 @@ const zo = {
|
|
|
2696
2700
|
},
|
|
2697
2701
|
emits: ["update:request", "update:filterPanelOpen"],
|
|
2698
2702
|
setup(t, { emit: o }) {
|
|
2699
|
-
const
|
|
2700
|
-
get: () =>
|
|
2703
|
+
const l = t, { t: e } = oe(), n = S({
|
|
2704
|
+
get: () => l.request,
|
|
2701
2705
|
set: (i) => o("update:request", i)
|
|
2702
2706
|
});
|
|
2703
|
-
function
|
|
2704
|
-
var
|
|
2705
|
-
return ((
|
|
2707
|
+
function m(i, c) {
|
|
2708
|
+
var g, b;
|
|
2709
|
+
return ((g = n.value.sort) == null ? void 0 : g.sortOnColumn) === i.field && ((b = n.value.sort) == null ? void 0 : b.sortByAscending) === c;
|
|
2706
2710
|
}
|
|
2707
2711
|
function s(i) {
|
|
2708
2712
|
if (typeof i < "u") {
|
|
2709
|
-
const c =
|
|
2713
|
+
const c = re(l.request);
|
|
2710
2714
|
c.sort === null || c.sort.sortOnColumn !== i ? c.sort = {
|
|
2711
2715
|
sortOnColumn: i,
|
|
2712
2716
|
sortByAscending: !0
|
|
@@ -2715,69 +2719,69 @@ const zo = {
|
|
|
2715
2719
|
}
|
|
2716
2720
|
function a(i) {
|
|
2717
2721
|
if (i) {
|
|
2718
|
-
const c =
|
|
2722
|
+
const c = re(n.value);
|
|
2719
2723
|
c.filters = [
|
|
2720
|
-
...c.filters.filter((
|
|
2724
|
+
...c.filters.filter((g) => g.filterOnColumn !== i[0].filterOnColumn),
|
|
2721
2725
|
...i
|
|
2722
2726
|
], c.pageNumber = 1, n.value = c;
|
|
2723
2727
|
}
|
|
2724
2728
|
}
|
|
2725
2729
|
return (i, c) => (u(), v("thead", Qo, [
|
|
2726
|
-
|
|
2727
|
-
(u(!0), v(F, null,
|
|
2730
|
+
p("tr", Jo, [
|
|
2731
|
+
(u(!0), v(F, null, Q(i.columns, (g, b) => (u(), v("th", {
|
|
2728
2732
|
key: b,
|
|
2729
2733
|
class: _(["cl-text-grey-3 cl-text-sm", {
|
|
2730
|
-
"cl-cursor-pointer": d(Oe)(
|
|
2734
|
+
"cl-cursor-pointer": d(Oe)(g)
|
|
2731
2735
|
}]),
|
|
2732
|
-
onClick: (r) => d(Oe)(
|
|
2736
|
+
onClick: (r) => d(Oe)(g) ? s(g.field) : () => {
|
|
2733
2737
|
}
|
|
2734
2738
|
}, [
|
|
2735
|
-
|
|
2736
|
-
L(
|
|
2739
|
+
ee(T(g.caption) + " ", 1),
|
|
2740
|
+
L(k(d(I), {
|
|
2737
2741
|
class: "cl-inline-block",
|
|
2738
2742
|
icon: "ph:caret-up"
|
|
2739
2743
|
}, null, 512), [
|
|
2740
|
-
[H,
|
|
2744
|
+
[H, m(g, !0)]
|
|
2741
2745
|
]),
|
|
2742
|
-
L(
|
|
2746
|
+
L(k(d(I), {
|
|
2743
2747
|
class: "cl-inline-block",
|
|
2744
2748
|
icon: "ph:caret-down"
|
|
2745
2749
|
}, null, 512), [
|
|
2746
|
-
[H,
|
|
2750
|
+
[H, m(g, !1)]
|
|
2747
2751
|
])
|
|
2748
2752
|
], 10, Yo))), 128))
|
|
2749
2753
|
]),
|
|
2750
|
-
|
|
2754
|
+
p("tr", {
|
|
2751
2755
|
class: _(["cl-border cl-border-grey-2 cl-flex cl-flex-wrap cl-p-2 lg:cl-border-none lg:cl-p-0 lg:cl-table-row", {
|
|
2752
2756
|
"cl-hidden lg:cl-table-row": !i.filterPanelOpen
|
|
2753
2757
|
}])
|
|
2754
2758
|
}, [
|
|
2755
|
-
|
|
2756
|
-
|
|
2759
|
+
p("div", Xo, [
|
|
2760
|
+
k(d(I), {
|
|
2757
2761
|
class: "cl-text-grey-4 hover:cl-cursor-pointer hover:cl-text-link-default",
|
|
2758
2762
|
icon: "ph:x",
|
|
2759
2763
|
size: 16,
|
|
2760
|
-
onClick: c[0] || (c[0] =
|
|
2764
|
+
onClick: c[0] || (c[0] = W((g) => i.$emit("update:filterPanelOpen", !1), ["prevent"]))
|
|
2761
2765
|
})
|
|
2762
2766
|
]),
|
|
2763
|
-
(u(!0), v(F, null,
|
|
2767
|
+
(u(!0), v(F, null, Q(i.columns, (g, b) => (u(), v("th", {
|
|
2764
2768
|
key: b,
|
|
2765
2769
|
class: _(["cl-grid cl-grid-cols-4 cl-py-1 cl-text-xs cl-w-full lg:cl-table-cell lg:cl-w-auto", {
|
|
2766
|
-
"cl-hidden lg:cl-table-cell": !d(Ue)(
|
|
2770
|
+
"cl-hidden lg:cl-table-cell": !d(Ue)(g)
|
|
2767
2771
|
}])
|
|
2768
2772
|
}, [
|
|
2769
|
-
|
|
2770
|
-
d(Oe)(
|
|
2773
|
+
p("div", en, T(g.caption), 1),
|
|
2774
|
+
d(Oe)(g) ? (u(), v("div", {
|
|
2771
2775
|
key: 0,
|
|
2772
2776
|
class: "cl-col-span-2 cl-gap-1 cl-span lg:cl-hidden",
|
|
2773
|
-
onClick: (r) => s(
|
|
2777
|
+
onClick: (r) => s(g.field)
|
|
2774
2778
|
}, [
|
|
2775
|
-
|
|
2776
|
-
|
|
2779
|
+
p("span", tn, T(d(e)("grid.sortBy")), 1),
|
|
2780
|
+
m(g, !0) ? (u(), V(d(I), {
|
|
2777
2781
|
key: 0,
|
|
2778
2782
|
class: "cl-cursor-pointer cl-inline-block",
|
|
2779
2783
|
icon: "ph:caret-up"
|
|
2780
|
-
})) :
|
|
2784
|
+
})) : m(g, !1) ? (u(), V(d(I), {
|
|
2781
2785
|
key: 1,
|
|
2782
2786
|
class: "cl-cursor-pointer cl-inline-block",
|
|
2783
2787
|
icon: "ph:caret-down"
|
|
@@ -2786,11 +2790,11 @@ const zo = {
|
|
|
2786
2790
|
class: "cl-cursor-pointer cl-inline-block",
|
|
2787
2791
|
icon: "ph:minus"
|
|
2788
2792
|
}))
|
|
2789
|
-
], 8, ln)) :
|
|
2790
|
-
|
|
2793
|
+
], 8, ln)) : N("", !0),
|
|
2794
|
+
k(Ko, {
|
|
2791
2795
|
class: "cl-col-span-4",
|
|
2792
|
-
filter: n.value.filters.filter((r) => r.filterOnColumn ===
|
|
2793
|
-
column:
|
|
2796
|
+
filter: n.value.filters.filter((r) => r.filterOnColumn === g.field),
|
|
2797
|
+
column: g,
|
|
2794
2798
|
"time-zone": i.timeZone,
|
|
2795
2799
|
"first-half": b <= i.columns.length / 2,
|
|
2796
2800
|
"onUpdate:filter": a
|
|
@@ -2799,7 +2803,7 @@ const zo = {
|
|
|
2799
2803
|
], 2)
|
|
2800
2804
|
]));
|
|
2801
2805
|
}
|
|
2802
|
-
}), nn = { class: "cl-fixed cl-flex cl-h-full cl-justify-end cl-right-0 cl-shadow-lg cl-top-0 cl-z-50" }, sn = { 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" }, an = { class: "cl-mb-4 cl-text-2xl cl-text-off-white" }, rn = { class: "cl-border-grey-3 cl-border-t cl-flex cl-flex-wrap cl-text-sm cl-w-full" }, cn = { class: "cl-border-b cl-border-grey-2 cl-flex cl-py-2 cl-text-sm cl-w-full" }, un = { class: "cl-flex-1 cl-py-2" }, dn = { class: "cl-py-2 cl-w-1/4" }, pn = { class: "cl-py-2 cl-w-1/5" }, fn = { class: "cl-flex-1 cl-py-2" }, mn = { class: "cl-py-2 cl-w-1/4" }, gn = { class: "cl-py-2 cl-text-off-white cl-w-1/5" }, vn = { key: 1 }, bn = /* @__PURE__ */
|
|
2806
|
+
}), nn = { class: "cl-fixed cl-flex cl-h-full cl-justify-end cl-right-0 cl-shadow-lg cl-top-0 cl-z-50" }, sn = { 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" }, an = { class: "cl-mb-4 cl-text-2xl cl-text-off-white" }, rn = { class: "cl-border-grey-3 cl-border-t cl-flex cl-flex-wrap cl-text-sm cl-w-full" }, cn = { class: "cl-border-b cl-border-grey-2 cl-flex cl-py-2 cl-text-sm cl-w-full" }, un = { class: "cl-flex-1 cl-py-2" }, dn = { class: "cl-py-2 cl-w-1/4" }, pn = { class: "cl-py-2 cl-w-1/5" }, fn = { class: "cl-flex-1 cl-py-2" }, mn = { class: "cl-py-2 cl-w-1/4" }, gn = { class: "cl-py-2 cl-text-off-white cl-w-1/5" }, vn = { key: 1 }, bn = /* @__PURE__ */ M({
|
|
2803
2807
|
inheritAttrs: !1,
|
|
2804
2808
|
__name: "cl-ui-grid-view-manager",
|
|
2805
2809
|
props: {
|
|
@@ -2807,74 +2811,74 @@ const zo = {
|
|
|
2807
2811
|
},
|
|
2808
2812
|
emits: ["update:columns"],
|
|
2809
2813
|
setup(t, { emit: o }) {
|
|
2810
|
-
const
|
|
2811
|
-
function
|
|
2812
|
-
|
|
2814
|
+
const l = t, { t: e } = oe(), n = A(!1);
|
|
2815
|
+
function m(i, c, g) {
|
|
2816
|
+
g < i.length && g >= 0 && i.splice(g, 0, i.splice(c, 1)[0]);
|
|
2813
2817
|
}
|
|
2814
2818
|
function s(i, c) {
|
|
2815
|
-
const
|
|
2816
|
-
r >= 0 && (
|
|
2819
|
+
const g = re(l.columns), b = (i == null ? void 0 : i.checked) ?? !1, r = g.findIndex((w) => w.name === c.name);
|
|
2820
|
+
r >= 0 && (g[r].visible = b), o("update:columns", g);
|
|
2817
2821
|
}
|
|
2818
2822
|
function a(i, c) {
|
|
2819
|
-
const
|
|
2820
|
-
|
|
2823
|
+
const g = re(l.columns), b = c === "up" ? i + 1 : i - 1;
|
|
2824
|
+
m(g, i, b), o("update:columns", g);
|
|
2821
2825
|
}
|
|
2822
2826
|
return (i, c) => (u(), v(F, null, [
|
|
2823
|
-
|
|
2827
|
+
k(fe, se(i.$attrs, {
|
|
2824
2828
|
class: "cl-w-full",
|
|
2825
2829
|
size: "small",
|
|
2826
|
-
onClick: c[0] || (c[0] =
|
|
2830
|
+
onClick: c[0] || (c[0] = W((g) => n.value = !0, ["prevent"]))
|
|
2827
2831
|
}), {
|
|
2828
2832
|
default: P(() => [
|
|
2829
|
-
|
|
2833
|
+
ee(T(d(e)("grid.manageView")), 1)
|
|
2830
2834
|
]),
|
|
2831
2835
|
_: 1
|
|
2832
2836
|
}, 16),
|
|
2833
2837
|
(u(), V(_e, { to: "body" }, [
|
|
2834
|
-
|
|
2838
|
+
k(me, { name: "slide-left" }, {
|
|
2835
2839
|
default: P(() => [
|
|
2836
|
-
L(
|
|
2837
|
-
|
|
2838
|
-
|
|
2840
|
+
L(p("div", nn, [
|
|
2841
|
+
p("div", sn, [
|
|
2842
|
+
k(d(I), {
|
|
2839
2843
|
class: "cl-absolute cl-cursor-pointer cl-right-3 cl-text-off-white cl-top-3",
|
|
2840
2844
|
icon: "ph:x",
|
|
2841
2845
|
size: 16,
|
|
2842
|
-
onClick: c[1] || (c[1] = (
|
|
2846
|
+
onClick: c[1] || (c[1] = (g) => n.value = !1)
|
|
2843
2847
|
}),
|
|
2844
|
-
|
|
2845
|
-
|
|
2846
|
-
|
|
2847
|
-
|
|
2848
|
-
|
|
2849
|
-
|
|
2848
|
+
p("h3", an, T(d(e)("grid.manageView")), 1),
|
|
2849
|
+
p("ul", rn, [
|
|
2850
|
+
p("li", cn, [
|
|
2851
|
+
p("strong", un, T(d(e)("grid.column")), 1),
|
|
2852
|
+
p("strong", dn, T(d(e)("grid.visible")), 1),
|
|
2853
|
+
p("strong", pn, T(d(e)("grid.order")), 1)
|
|
2850
2854
|
]),
|
|
2851
|
-
(u(!0), v(F, null,
|
|
2855
|
+
(u(!0), v(F, null, Q(i.columns, (g, b) => (u(), v("li", {
|
|
2852
2856
|
key: b,
|
|
2853
2857
|
class: "cl-border-b cl-border-grey-2 cl-flex cl-py-2 cl-text-sm cl-w-full"
|
|
2854
2858
|
}, [
|
|
2855
|
-
|
|
2856
|
-
|
|
2857
|
-
|
|
2858
|
-
"model-value":
|
|
2859
|
+
p("div", fn, T(g.caption), 1),
|
|
2860
|
+
p("div", mn, [
|
|
2861
|
+
k(ae, {
|
|
2862
|
+
"model-value": g.visible === void 0 || g.visible === !0,
|
|
2859
2863
|
"input-type": "checkbox",
|
|
2860
|
-
onClick: (r) => s(r.target,
|
|
2864
|
+
onClick: (r) => s(r.target, g)
|
|
2861
2865
|
}, null, 8, ["model-value", "onClick"])
|
|
2862
2866
|
]),
|
|
2863
|
-
|
|
2864
|
-
|
|
2867
|
+
p("div", gn, [
|
|
2868
|
+
g.visible === void 0 || g.visible === !0 ? (u(), v(F, { key: 0 }, [
|
|
2865
2869
|
b !== 0 ? (u(), V(d(I), {
|
|
2866
2870
|
key: 0,
|
|
2867
2871
|
class: "cl-cursor-pointer cl-inline-block cl-mr-2",
|
|
2868
2872
|
icon: "ph:arrow-left",
|
|
2869
2873
|
onClick: (r) => a(b, "down")
|
|
2870
|
-
}, null, 8, ["onClick"])) :
|
|
2874
|
+
}, null, 8, ["onClick"])) : N("", !0),
|
|
2871
2875
|
b !== i.columns.length - 1 ? (u(), V(d(I), {
|
|
2872
2876
|
key: 1,
|
|
2873
2877
|
class: "cl-cursor-pointer cl-inline-block",
|
|
2874
2878
|
icon: "ph:arrow-right",
|
|
2875
2879
|
onClick: (r) => a(b, "up")
|
|
2876
|
-
}, null, 8, ["onClick"])) :
|
|
2877
|
-
], 64)) : (u(), v("em", vn,
|
|
2880
|
+
}, null, 8, ["onClick"])) : N("", !0)
|
|
2881
|
+
], 64)) : (u(), v("em", vn, T(d(e)("grid.hidden")), 1))
|
|
2878
2882
|
])
|
|
2879
2883
|
]))), 128))
|
|
2880
2884
|
])
|
|
@@ -2888,7 +2892,7 @@ const zo = {
|
|
|
2888
2892
|
]))
|
|
2889
2893
|
], 64));
|
|
2890
2894
|
}
|
|
2891
|
-
}), hn = { class: "cl-relative cl-w-full grid lg:cl-min-h-fit" }, yn = { class: "cl-absolute cl-flex cl-items-center cl-justify-center cl-min-h-full cl-p-32 cl-w-full" }, wn = { class: "cl-overflow-x-auto cl-overscroll-x-none cl-pt-1" }, $n = { class: "cl-hidden lg:cl-table-column-group" }, kn = /* @__PURE__ */
|
|
2895
|
+
}), hn = { class: "cl-relative cl-w-full grid lg:cl-min-h-fit" }, yn = { class: "cl-absolute cl-flex cl-items-center cl-justify-center cl-min-h-full cl-p-32 cl-w-full" }, wn = { class: "cl-overflow-x-auto cl-overscroll-x-none cl-pt-1" }, $n = { class: "cl-hidden lg:cl-table-column-group" }, kn = /* @__PURE__ */ M({
|
|
2892
2896
|
__name: "cl-ui-grid",
|
|
2893
2897
|
props: {
|
|
2894
2898
|
columns: {},
|
|
@@ -2900,93 +2904,93 @@ const zo = {
|
|
|
2900
2904
|
},
|
|
2901
2905
|
emits: ["update:columns", "update:request", "data-request", "row-edit", "edit-start", "edit-end", "row-select"],
|
|
2902
2906
|
setup(t, { emit: o }) {
|
|
2903
|
-
const
|
|
2904
|
-
get: () =>
|
|
2907
|
+
const l = t, e = S({
|
|
2908
|
+
get: () => l.columns,
|
|
2905
2909
|
set: (h) => o("update:columns", h)
|
|
2906
|
-
}), n =
|
|
2910
|
+
}), n = S(() => e.value.filter((h) => h.visible ?? !0)), m = A({});
|
|
2907
2911
|
function s() {
|
|
2908
2912
|
const h = {};
|
|
2909
|
-
window.innerWidth >= 1024 &&
|
|
2910
|
-
const
|
|
2911
|
-
h[`${
|
|
2912
|
-
}),
|
|
2913
|
+
window.innerWidth >= 1024 && e.value.forEach((q) => {
|
|
2914
|
+
const $ = q.width ? `${q.width}px` : "";
|
|
2915
|
+
h[`${q.name}`] = `width: ${$}; min-width: ${$};`;
|
|
2916
|
+
}), m.value = h;
|
|
2913
2917
|
}
|
|
2914
2918
|
function a(h) {
|
|
2915
|
-
return
|
|
2919
|
+
return m.value[h] ?? "";
|
|
2916
2920
|
}
|
|
2917
|
-
|
|
2921
|
+
Ae(() => {
|
|
2918
2922
|
window.addEventListener("resize", s), s();
|
|
2919
2923
|
}), Ie(() => window.removeEventListener("resize", s));
|
|
2920
|
-
const i =
|
|
2921
|
-
get: () =>
|
|
2924
|
+
const i = S({
|
|
2925
|
+
get: () => l.request,
|
|
2922
2926
|
set: (h) => o("update:request", h)
|
|
2923
2927
|
});
|
|
2924
2928
|
function c() {
|
|
2925
|
-
const h =
|
|
2929
|
+
const h = re(i.value);
|
|
2926
2930
|
h.pageNumber = 1, h.filters = [], i.value = h;
|
|
2927
2931
|
}
|
|
2928
|
-
const
|
|
2929
|
-
|
|
2932
|
+
const g = Ke(() => o("data-request"), 750);
|
|
2933
|
+
K(i, g, {
|
|
2930
2934
|
deep: !0,
|
|
2931
2935
|
immediate: !0
|
|
2932
2936
|
});
|
|
2933
|
-
const b =
|
|
2934
|
-
return
|
|
2935
|
-
|
|
2937
|
+
const b = S(() => l.data), r = A(!1), w = A(!1);
|
|
2938
|
+
return K(r, () => r.value ? o("edit-start") : o("edit-end")), (h, q) => (u(), v("div", hn, [
|
|
2939
|
+
k(me, { name: "fade" }, {
|
|
2936
2940
|
default: P(() => [
|
|
2937
|
-
L(
|
|
2938
|
-
|
|
2941
|
+
L(p("div", yn, [
|
|
2942
|
+
k(Se)
|
|
2939
2943
|
], 512), [
|
|
2940
2944
|
[H, h.loading]
|
|
2941
2945
|
])
|
|
2942
2946
|
]),
|
|
2943
2947
|
_: 1
|
|
2944
2948
|
}),
|
|
2945
|
-
|
|
2949
|
+
k(Wt, {
|
|
2946
2950
|
"edit-mode": r.value,
|
|
2947
|
-
"onUpdate:editMode":
|
|
2951
|
+
"onUpdate:editMode": q[1] || (q[1] = ($) => r.value = $),
|
|
2948
2952
|
"filter-panel-open": w.value,
|
|
2949
|
-
"onUpdate:filterPanelOpen":
|
|
2953
|
+
"onUpdate:filterPanelOpen": q[2] || (q[2] = ($) => w.value = $),
|
|
2950
2954
|
columns: h.columns,
|
|
2951
2955
|
options: h.options,
|
|
2952
2956
|
request: h.request,
|
|
2953
2957
|
loading: h.loading,
|
|
2954
2958
|
onClearFilters: c
|
|
2955
2959
|
}, {
|
|
2956
|
-
"additional-grid-actions": P((
|
|
2957
|
-
|
|
2960
|
+
"additional-grid-actions": P(($) => [
|
|
2961
|
+
j(h.$slots, "additional-grid-actions", le(ne($)))
|
|
2958
2962
|
]),
|
|
2959
2963
|
"view-manager": P(() => [
|
|
2960
|
-
|
|
2961
|
-
columns:
|
|
2962
|
-
"onUpdate:columns":
|
|
2964
|
+
k(bn, {
|
|
2965
|
+
columns: e.value,
|
|
2966
|
+
"onUpdate:columns": q[0] || (q[0] = ($) => e.value = $)
|
|
2963
2967
|
}, null, 8, ["columns"])
|
|
2964
2968
|
]),
|
|
2965
2969
|
_: 3
|
|
2966
2970
|
}, 8, ["edit-mode", "filter-panel-open", "columns", "options", "request", "loading"]),
|
|
2967
|
-
|
|
2968
|
-
|
|
2971
|
+
p("div", wn, [
|
|
2972
|
+
p("table", {
|
|
2969
2973
|
class: _(["cl-delay-75 cl-min-h-[276px] cl-overflow-x-auto cl-overscroll-x-none cl-text-left cl-transition-opacity cl-w-full", {
|
|
2970
2974
|
"cl-opacity-40": h.loading
|
|
2971
2975
|
}])
|
|
2972
2976
|
}, [
|
|
2973
|
-
|
|
2974
|
-
(u(!0), v(F, null,
|
|
2975
|
-
key:
|
|
2976
|
-
style:
|
|
2977
|
+
p("colgroup", $n, [
|
|
2978
|
+
(u(!0), v(F, null, Q(n.value, ($, R) => (u(), v("col", {
|
|
2979
|
+
key: R,
|
|
2980
|
+
style: Ze(a($.name)),
|
|
2977
2981
|
span: 1
|
|
2978
2982
|
}, null, 4))), 128))
|
|
2979
2983
|
]),
|
|
2980
|
-
|
|
2984
|
+
k(on, {
|
|
2981
2985
|
request: i.value,
|
|
2982
|
-
"onUpdate:request":
|
|
2986
|
+
"onUpdate:request": q[3] || (q[3] = ($) => i.value = $),
|
|
2983
2987
|
"filter-panel-open": w.value,
|
|
2984
|
-
"onUpdate:filterPanelOpen":
|
|
2988
|
+
"onUpdate:filterPanelOpen": q[4] || (q[4] = ($) => w.value = $),
|
|
2985
2989
|
columns: n.value,
|
|
2986
2990
|
options: h.options,
|
|
2987
2991
|
"time-zone": h.timeZone
|
|
2988
2992
|
}, null, 8, ["request", "filter-panel-open", "columns", "options", "time-zone"]),
|
|
2989
|
-
|
|
2993
|
+
k(io, {
|
|
2990
2994
|
columns: n.value,
|
|
2991
2995
|
request: i.value,
|
|
2992
2996
|
data: b.value,
|
|
@@ -2995,47 +2999,55 @@ const zo = {
|
|
|
2995
2999
|
"edit-mode": r.value,
|
|
2996
3000
|
"selection-enabled": h.options.rowSelectionEnabled,
|
|
2997
3001
|
onClearFilters: c,
|
|
2998
|
-
onRowEdit:
|
|
2999
|
-
onRowSelect:
|
|
3002
|
+
onRowEdit: q[5] || (q[5] = ($) => h.$emit("row-edit", $)),
|
|
3003
|
+
onRowSelect: q[6] || (q[6] = ($) => h.$emit("row-select", $))
|
|
3000
3004
|
}, Re({ _: 2 }, [
|
|
3001
|
-
|
|
3002
|
-
name:
|
|
3005
|
+
Q(h.$slots, ($, R) => ({
|
|
3006
|
+
name: R,
|
|
3003
3007
|
fn: P((O) => [
|
|
3004
|
-
|
|
3008
|
+
j(h.$slots, R, le(ne(O)))
|
|
3005
3009
|
])
|
|
3006
3010
|
}))
|
|
3007
3011
|
]), 1032, ["columns", "request", "data", "time-zone", "loading", "edit-mode", "selection-enabled"])
|
|
3008
3012
|
], 2)
|
|
3009
3013
|
]),
|
|
3010
|
-
|
|
3014
|
+
k(Oo, {
|
|
3011
3015
|
request: i.value,
|
|
3012
|
-
"onUpdate:request":
|
|
3016
|
+
"onUpdate:request": q[7] || (q[7] = ($) => i.value = $),
|
|
3013
3017
|
data: h.data
|
|
3014
3018
|
}, null, 8, ["request", "data"])
|
|
3015
3019
|
]));
|
|
3016
3020
|
}
|
|
3017
|
-
}), Cn = { class: "cl-absolute cl-bg-secondary-default cl-flex cl-h-20 cl-items-center cl-justify-between cl-left-0 cl-top-0 cl-w-full cl-z-40" }, Tn = /* @__PURE__ */
|
|
3021
|
+
}), Cn = { class: "cl-absolute cl-bg-secondary-default cl-flex cl-h-20 cl-items-center cl-justify-between cl-left-0 cl-top-0 cl-w-full cl-z-40" }, Tn = /* @__PURE__ */ M({
|
|
3018
3022
|
__name: "cl-ui-header",
|
|
3023
|
+
props: {
|
|
3024
|
+
isOpen: { type: Boolean }
|
|
3025
|
+
},
|
|
3019
3026
|
emits: ["open-click"],
|
|
3020
|
-
setup(t) {
|
|
3021
|
-
|
|
3022
|
-
|
|
3023
|
-
|
|
3027
|
+
setup(t, { emit: o }) {
|
|
3028
|
+
const l = t, e = A();
|
|
3029
|
+
return ze(e, () => {
|
|
3030
|
+
(l.isOpen ?? !1) && o("open-click");
|
|
3031
|
+
}), (n, m) => (u(), v("header", Cn, [
|
|
3032
|
+
j(n.$slots, "logo"),
|
|
3033
|
+
p("div", {
|
|
3034
|
+
ref_key: "headerMenuElement",
|
|
3035
|
+
ref: e,
|
|
3024
3036
|
class: "cl-cursor-pointer cl-flex cl-flex-nowrap",
|
|
3025
|
-
onClick:
|
|
3037
|
+
onClick: m[0] || (m[0] = (s) => n.$emit("open-click"))
|
|
3026
3038
|
}, [
|
|
3027
|
-
|
|
3028
|
-
|
|
3029
|
-
])
|
|
3039
|
+
j(n.$slots, "menu"),
|
|
3040
|
+
j(n.$slots, "icon")
|
|
3041
|
+
], 512)
|
|
3030
3042
|
]));
|
|
3031
3043
|
}
|
|
3032
|
-
}), En = { class: "cl-bg-transparent cl-flex cl-items-center cl-select-none hover:cl-bg-opacity-10 hover:cl-bg-white md:cl-min-w-[320px]" }, On = ["src"],
|
|
3044
|
+
}), En = { class: "cl-bg-transparent cl-flex cl-items-center cl-select-none hover:cl-bg-opacity-10 hover:cl-bg-white md:cl-min-w-[320px]" }, On = ["src"], qn = {
|
|
3033
3045
|
key: 0,
|
|
3034
3046
|
class: "cl-text-ellipsis cl-whitespace-nowrap"
|
|
3035
|
-
},
|
|
3047
|
+
}, An = {
|
|
3036
3048
|
key: 1,
|
|
3037
3049
|
class: "cl-text-ellipsis cl-text-xs cl-whitespace-nowrap"
|
|
3038
|
-
}, Sn = { class: "cl-content-center cl-flex cl-h-20 cl-items-center cl-justify-center cl-justify-items-center cl-transition-all cl-w-10 md:cl-ml-4 md:cl-w-20" }, Nn = { class: "cl-absolute cl-bg-white cl-right-0 cl-shadow-2xl cl-top-20 cl-w-full cl-z-20" }, jn = /* @__PURE__ */
|
|
3050
|
+
}, Sn = { class: "cl-content-center cl-flex cl-h-20 cl-items-center cl-justify-center cl-justify-items-center cl-transition-all cl-w-10 md:cl-ml-4 md:cl-w-20" }, Nn = { class: "cl-absolute cl-bg-white cl-right-0 cl-shadow-2xl cl-top-20 cl-w-full cl-z-20" }, jn = /* @__PURE__ */ M({
|
|
3039
3051
|
__name: "cl-ui-header-menu",
|
|
3040
3052
|
props: {
|
|
3041
3053
|
username: { default: "" },
|
|
@@ -3044,25 +3056,18 @@ const zo = {
|
|
|
3044
3056
|
isOpen: { type: Boolean },
|
|
3045
3057
|
colour: { default: "default" }
|
|
3046
3058
|
},
|
|
3047
|
-
|
|
3048
|
-
|
|
3049
|
-
|
|
3050
|
-
ze(l, n);
|
|
3051
|
-
function n() {
|
|
3052
|
-
e.isOpen === !0 && o("update:is-open", !1);
|
|
3053
|
-
}
|
|
3054
|
-
return (p, s) => (u(), v("div", {
|
|
3055
|
-
ref_key: "headerMenuElement",
|
|
3056
|
-
ref: l,
|
|
3059
|
+
setup(t) {
|
|
3060
|
+
const o = t;
|
|
3061
|
+
return (l, e) => (u(), v("div", {
|
|
3057
3062
|
class: _(["md:cl-relative", {
|
|
3058
|
-
"cl-bg-primary-default": (
|
|
3059
|
-
"cl-bg-blue-light":
|
|
3063
|
+
"cl-bg-primary-default": (o == null ? void 0 : o.colour) === "default",
|
|
3064
|
+
"cl-bg-blue-light": o.colour === "secondary"
|
|
3060
3065
|
}])
|
|
3061
3066
|
}, [
|
|
3062
|
-
|
|
3063
|
-
|
|
3067
|
+
p("div", En, [
|
|
3068
|
+
l.image ? (u(), v("img", {
|
|
3064
3069
|
key: 0,
|
|
3065
|
-
src:
|
|
3070
|
+
src: l.image,
|
|
3066
3071
|
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"
|
|
3067
3072
|
}, null, 8, On)) : (u(), V(d(I), {
|
|
3068
3073
|
key: 1,
|
|
@@ -3071,32 +3076,32 @@ const zo = {
|
|
|
3071
3076
|
width: "48",
|
|
3072
3077
|
height: "48"
|
|
3073
3078
|
})),
|
|
3074
|
-
|
|
3079
|
+
p("div", {
|
|
3075
3080
|
class: _(["cl-grow cl-hidden cl-my-4 md:cl-block", {
|
|
3076
|
-
"cl-text-secondary-default":
|
|
3077
|
-
"cl-text-white":
|
|
3081
|
+
"cl-text-secondary-default": o.colour === "default",
|
|
3082
|
+
"cl-text-white": o.colour === "secondary"
|
|
3078
3083
|
}])
|
|
3079
3084
|
}, [
|
|
3080
|
-
|
|
3081
|
-
|
|
3085
|
+
l.username ? (u(), v("div", qn, T(l.username), 1)) : N("", !0),
|
|
3086
|
+
l.group ? (u(), v("div", An, T(l.group), 1)) : N("", !0)
|
|
3082
3087
|
], 2),
|
|
3083
|
-
|
|
3084
|
-
|
|
3088
|
+
p("div", Sn, [
|
|
3089
|
+
k(d(I), {
|
|
3085
3090
|
class: _(["cl-transform-gpu cl-transition-transform", {
|
|
3086
|
-
"cl-rotate-180":
|
|
3087
|
-
"cl-text-secondary-default":
|
|
3088
|
-
"cl-text-white":
|
|
3091
|
+
"cl-rotate-180": l.isOpen,
|
|
3092
|
+
"cl-text-secondary-default": o.colour === "default",
|
|
3093
|
+
"cl-text-white": o.colour === "secondary"
|
|
3089
3094
|
}]),
|
|
3090
3095
|
icon: "ph:caret-down"
|
|
3091
3096
|
}, null, 8, ["class"])
|
|
3092
3097
|
])
|
|
3093
3098
|
]),
|
|
3094
|
-
|
|
3099
|
+
k(me, { name: "fade" }, {
|
|
3095
3100
|
default: P(() => [
|
|
3096
|
-
L(
|
|
3097
|
-
|
|
3101
|
+
L(p("div", Nn, [
|
|
3102
|
+
j(l.$slots, "default")
|
|
3098
3103
|
], 512), [
|
|
3099
|
-
[H,
|
|
3104
|
+
[H, l.isOpen]
|
|
3100
3105
|
])
|
|
3101
3106
|
]),
|
|
3102
3107
|
_: 3
|
|
@@ -3110,8 +3115,8 @@ function je(t) {
|
|
|
3110
3115
|
function _n(t) {
|
|
3111
3116
|
let o = Array.isArray(t);
|
|
3112
3117
|
if (o) {
|
|
3113
|
-
for (const
|
|
3114
|
-
if (!In(
|
|
3118
|
+
for (const l of t)
|
|
3119
|
+
if (!In(l)) {
|
|
3115
3120
|
o = !1;
|
|
3116
3121
|
break;
|
|
3117
3122
|
}
|
|
@@ -3124,7 +3129,7 @@ function In(t) {
|
|
|
3124
3129
|
const Rn = {
|
|
3125
3130
|
key: 0,
|
|
3126
3131
|
class: "cl-flex cl-relative cl-select-none cl-w-auto cl-z-30"
|
|
3127
|
-
}, zn = { class: "cl-absolute cl-bg-white cl-border cl-border-grey-0 cl-overflow-hidden cl-right-0 cl-rounded cl-shadow-xl cl-text-black cl-top-6 cl-z-3" }, Un = ["data-localename", "data-localecode", "onClick"], Bn = { class: "cl-text-xs" }, Mn = /* @__PURE__ */
|
|
3132
|
+
}, zn = { class: "cl-absolute cl-bg-white cl-border cl-border-grey-0 cl-overflow-hidden cl-right-0 cl-rounded cl-shadow-xl cl-text-black cl-top-6 cl-z-3" }, Un = ["data-localename", "data-localecode", "onClick"], Bn = { class: "cl-text-xs" }, Mn = /* @__PURE__ */ M({
|
|
3128
3133
|
__name: "cl-ui-language-switcher",
|
|
3129
3134
|
props: {
|
|
3130
3135
|
supportedLanguages: {},
|
|
@@ -3133,38 +3138,38 @@ const Rn = {
|
|
|
3133
3138
|
},
|
|
3134
3139
|
emits: ["language-select"],
|
|
3135
3140
|
setup(t, { emit: o }) {
|
|
3136
|
-
const
|
|
3141
|
+
const l = t, { locale: e } = oe(), n = A(!1), m = S(() => l.supportedLanguages.find((i) => i.localeCode === e.value) ?? l.defaultLangauge), s = S(() => l.supportedLanguages.filter((i) => je(i)).sort((i, c) => i.nativeName > c.nativeName ? 1 : c.nativeName > i.nativeName ? -1 : 0));
|
|
3137
3142
|
function a() {
|
|
3138
|
-
|
|
3143
|
+
l.disabled || (n.value = !n.value);
|
|
3139
3144
|
}
|
|
3140
|
-
return
|
|
3145
|
+
return K(() => l.disabled, (i) => {
|
|
3141
3146
|
i && (n.value = !1);
|
|
3142
|
-
}), (i, c) =>
|
|
3143
|
-
|
|
3147
|
+
}), (i, c) => m.value !== null && d(je)(m.value) ? (u(), v("div", Rn, [
|
|
3148
|
+
p("div", {
|
|
3144
3149
|
class: _(["cl-flex cl-items-center", {
|
|
3145
3150
|
"cl-cursor-pointer": !i.disabled
|
|
3146
3151
|
}]),
|
|
3147
3152
|
onClick: a
|
|
3148
3153
|
}, [
|
|
3149
|
-
|
|
3154
|
+
p("span", {
|
|
3150
3155
|
class: _(["cl-font-semibold cl-text-xs", {
|
|
3151
3156
|
"cl-opacity-50": i.disabled
|
|
3152
3157
|
}])
|
|
3153
|
-
},
|
|
3158
|
+
}, T(m.value.nativeName), 3)
|
|
3154
3159
|
], 2),
|
|
3155
|
-
|
|
3160
|
+
k(me, { name: "fade" }, {
|
|
3156
3161
|
default: P(() => [
|
|
3157
|
-
L(
|
|
3158
|
-
(u(!0), v(F, null,
|
|
3162
|
+
L(p("div", zn, [
|
|
3163
|
+
(u(!0), v(F, null, Q(s.value, (g, b) => (u(), v("div", {
|
|
3159
3164
|
key: b,
|
|
3160
3165
|
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",
|
|
3161
|
-
"data-localename":
|
|
3162
|
-
"data-localecode":
|
|
3166
|
+
"data-localename": g.name,
|
|
3167
|
+
"data-localecode": g.localeCode,
|
|
3163
3168
|
onClick: (r) => {
|
|
3164
|
-
|
|
3169
|
+
e.value = g.localeCode, a(), o("language-select", g.localeCode);
|
|
3165
3170
|
}
|
|
3166
3171
|
}, [
|
|
3167
|
-
|
|
3172
|
+
p("span", Bn, T(g.nativeName), 1)
|
|
3168
3173
|
], 8, Un))), 128))
|
|
3169
3174
|
], 512), [
|
|
3170
3175
|
[H, n.value]
|
|
@@ -3172,12 +3177,12 @@ const Rn = {
|
|
|
3172
3177
|
]),
|
|
3173
3178
|
_: 1
|
|
3174
3179
|
})
|
|
3175
|
-
])) :
|
|
3180
|
+
])) : N("", !0);
|
|
3176
3181
|
}
|
|
3177
3182
|
}), Vn = { class: "cl-relative" }, Dn = { class: "cl-h-screen cl-z-0" }, Ln = { class: "cl-absolute cl-bg-secondary-default cl-gap-y-1 cl-grid cl-grid-cols-1 cl-left-0 cl-opacity-95 cl-p-6 cl-top-0 cl-w-full cl-z-10 lg:cl-gap-x-1 lg:cl-grid-cols-10 lg:cl-p-10" }, Pn = { class: "cl-col-span-10 lg:cl-col-span-3" }, Fn = {
|
|
3178
3183
|
key: 0,
|
|
3179
3184
|
class: "cl-col-span-10 cl-flex cl-items-start cl-justify-end cl-text-white lg:cl-col-span-1 lg:cl-p-2"
|
|
3180
|
-
}, Hn = { class: "cl-col-span-3" }, Gn = { class: "cl-inline cl-relative cl-text-grey-4" },
|
|
3185
|
+
}, Hn = { class: "cl-col-span-3" }, Gn = { class: "cl-inline cl-relative cl-text-grey-4" }, xn = { class: "cl-col-span-3" }, Zn = { class: "cl-inline cl-relative cl-text-grey-4" }, Wn = { class: "cl-col-span-10 cl-emphasis-danger cl-mt-10 cl-p-3 cl-rounded-md cl-text-sm md:cl-mt-3" }, Kn = /* @__PURE__ */ M({
|
|
3181
3186
|
__name: "cl-ui-login",
|
|
3182
3187
|
props: {
|
|
3183
3188
|
errors: { default: () => [] },
|
|
@@ -3188,10 +3193,10 @@ const Rn = {
|
|
|
3188
3193
|
"update:errors": null
|
|
3189
3194
|
},
|
|
3190
3195
|
setup(t, { emit: o }) {
|
|
3191
|
-
const { t:
|
|
3196
|
+
const { t: l } = oe(), e = A(""), n = A(""), m = A("password"), s = A();
|
|
3192
3197
|
function a() {
|
|
3193
3198
|
const b = {
|
|
3194
|
-
username:
|
|
3199
|
+
username: e.value,
|
|
3195
3200
|
password: n.value
|
|
3196
3201
|
};
|
|
3197
3202
|
o("login", b);
|
|
@@ -3206,87 +3211,87 @@ const Rn = {
|
|
|
3206
3211
|
};
|
|
3207
3212
|
return typeof r == "string" && r.trim() === "" && (w.valid = !1), w;
|
|
3208
3213
|
}
|
|
3209
|
-
function
|
|
3214
|
+
function g(b, r) {
|
|
3210
3215
|
s.value = b;
|
|
3211
3216
|
}
|
|
3212
3217
|
return (b, r) => (u(), v("div", Vn, [
|
|
3213
|
-
|
|
3214
|
-
|
|
3218
|
+
p("div", Dn, [
|
|
3219
|
+
j(b.$slots, "background")
|
|
3215
3220
|
]),
|
|
3216
|
-
|
|
3217
|
-
|
|
3218
|
-
|
|
3221
|
+
p("form", Ln, [
|
|
3222
|
+
p("div", Pn, [
|
|
3223
|
+
j(b.$slots, "logo")
|
|
3219
3224
|
]),
|
|
3220
3225
|
b.$slots["language-switcher"] ? (u(), v("div", Fn, [
|
|
3221
|
-
|
|
3222
|
-
])) :
|
|
3223
|
-
|
|
3226
|
+
j(b.$slots, "language-switcher")
|
|
3227
|
+
])) : N("", !0),
|
|
3228
|
+
p("div", {
|
|
3224
3229
|
class: _(["cl-gap-y-4 cl-grid cl-grid-cols-1 lg:cl-gap-x-2 lg:cl-grid-cols-8", {
|
|
3225
3230
|
"cl-col-span-7": !b.$slots["language-switcher"],
|
|
3226
3231
|
"cl-col-span-6": b.$slots["language-switcher"]
|
|
3227
3232
|
}])
|
|
3228
3233
|
}, [
|
|
3229
|
-
|
|
3230
|
-
|
|
3231
|
-
|
|
3234
|
+
p("div", Hn, [
|
|
3235
|
+
p("div", Gn, [
|
|
3236
|
+
k(d(I), {
|
|
3232
3237
|
class: "cl-absolute cl-left-3 cl-top-2.5 cl-z-10",
|
|
3233
3238
|
icon: "ph:user",
|
|
3234
3239
|
size: 18
|
|
3235
3240
|
}),
|
|
3236
|
-
|
|
3241
|
+
k(ae, {
|
|
3237
3242
|
id: "cl-ui-login-usernameinput",
|
|
3238
|
-
modelValue:
|
|
3239
|
-
"onUpdate:modelValue": r[0] || (r[0] = (w) =>
|
|
3243
|
+
modelValue: e.value,
|
|
3244
|
+
"onUpdate:modelValue": r[0] || (r[0] = (w) => e.value = w),
|
|
3240
3245
|
modelModifiers: { trim: !0 },
|
|
3241
3246
|
class: "!cl-border-2 !cl-mb-1 cl-w-full",
|
|
3242
3247
|
"input-type": "email",
|
|
3243
|
-
"highlight-when-valid":
|
|
3244
|
-
label: d(
|
|
3248
|
+
"highlight-when-valid": e.value !== void 0 && e.value !== "",
|
|
3249
|
+
label: d(l)("login.username"),
|
|
3245
3250
|
"show-label": !1,
|
|
3246
|
-
"placeholder-text": d(
|
|
3251
|
+
"placeholder-text": d(l)("login.email"),
|
|
3247
3252
|
autocomplete: "username",
|
|
3248
3253
|
"validate-immediately": !0,
|
|
3249
3254
|
"custom-validation-function": c,
|
|
3250
3255
|
"input-specific-classes": "!cl-pl-9",
|
|
3251
|
-
"message-when-valid":
|
|
3256
|
+
"message-when-valid": e.value ? d(l)("login.validEmail") : "",
|
|
3252
3257
|
onInput: i,
|
|
3253
|
-
onValidated:
|
|
3258
|
+
onValidated: g
|
|
3254
3259
|
}, null, 8, ["modelValue", "highlight-when-valid", "label", "placeholder-text", "message-when-valid"])
|
|
3255
3260
|
])
|
|
3256
3261
|
]),
|
|
3257
|
-
|
|
3258
|
-
|
|
3259
|
-
|
|
3262
|
+
p("div", xn, [
|
|
3263
|
+
p("div", Zn, [
|
|
3264
|
+
k(d(I), {
|
|
3260
3265
|
class: "cl-absolute cl-left-3 cl-top-2.5 cl-z-10",
|
|
3261
3266
|
icon: "ph:lock",
|
|
3262
3267
|
size: 18
|
|
3263
3268
|
}),
|
|
3264
|
-
L(
|
|
3269
|
+
L(k(d(I), {
|
|
3265
3270
|
class: "cl-absolute cl-cursor-pointer cl-right-4 cl-top-2.5 cl-z-10",
|
|
3266
3271
|
icon: "ph:eye",
|
|
3267
3272
|
size: 18,
|
|
3268
|
-
onClick: r[1] || (r[1] = (w) =>
|
|
3273
|
+
onClick: r[1] || (r[1] = (w) => m.value = "text")
|
|
3269
3274
|
}, null, 512), [
|
|
3270
|
-
[H,
|
|
3275
|
+
[H, m.value === "password"]
|
|
3271
3276
|
]),
|
|
3272
|
-
L(
|
|
3277
|
+
L(k(d(I), {
|
|
3273
3278
|
class: "cl-absolute cl-cursor-pointer cl-right-4 cl-top-2.5 cl-z-10",
|
|
3274
3279
|
icon: "ph:eye-slash",
|
|
3275
3280
|
size: 18,
|
|
3276
|
-
onClick: r[2] || (r[2] = (w) =>
|
|
3281
|
+
onClick: r[2] || (r[2] = (w) => m.value = "password")
|
|
3277
3282
|
}, null, 512), [
|
|
3278
|
-
[H,
|
|
3283
|
+
[H, m.value === "text"]
|
|
3279
3284
|
]),
|
|
3280
|
-
|
|
3285
|
+
k(ae, {
|
|
3281
3286
|
id: "cl-ui-login-passwordinput",
|
|
3282
3287
|
modelValue: n.value,
|
|
3283
3288
|
"onUpdate:modelValue": r[3] || (r[3] = (w) => n.value = w),
|
|
3284
3289
|
class: "!cl-border-2 cl-w-full",
|
|
3285
|
-
"input-type":
|
|
3290
|
+
"input-type": m.value,
|
|
3286
3291
|
"highlight-when-valid": n.value !== void 0 && n.value !== "",
|
|
3287
|
-
label: d(
|
|
3292
|
+
label: d(l)("login.password"),
|
|
3288
3293
|
"show-label": !1,
|
|
3289
|
-
"placeholder-text": d(
|
|
3294
|
+
"placeholder-text": d(l)("login.password"),
|
|
3290
3295
|
autocomplete: "current-password",
|
|
3291
3296
|
"validate-immediately": !0,
|
|
3292
3297
|
"input-specific-classes": "!cl-pl-9 !cl-pr-9",
|
|
@@ -3295,36 +3300,36 @@ const Rn = {
|
|
|
3295
3300
|
}, null, 8, ["modelValue", "input-type", "highlight-when-valid", "label", "placeholder-text"])
|
|
3296
3301
|
])
|
|
3297
3302
|
]),
|
|
3298
|
-
|
|
3303
|
+
p("div", {
|
|
3299
3304
|
class: _(["cl-col-span-2", {
|
|
3300
3305
|
"cl-mt-1.5 cl-mb-1 md:cl-mt-0.5 md:cl-mb-7 lg:cl-mb-0": b.loading
|
|
3301
3306
|
}])
|
|
3302
3307
|
}, [
|
|
3303
|
-
|
|
3308
|
+
k(fe, {
|
|
3304
3309
|
id: "cl-ui-login-loginbutton",
|
|
3305
3310
|
class: "cl-w-full",
|
|
3306
3311
|
colour: "blue",
|
|
3307
3312
|
loading: b.loading,
|
|
3308
3313
|
disabled: !s.value || n.value === "",
|
|
3309
|
-
onClick:
|
|
3314
|
+
onClick: W(a, ["prevent"])
|
|
3310
3315
|
}, {
|
|
3311
3316
|
default: P(() => [
|
|
3312
|
-
|
|
3317
|
+
ee(T(d(l)("login.login")), 1)
|
|
3313
3318
|
]),
|
|
3314
3319
|
_: 1
|
|
3315
3320
|
}, 8, ["loading", "disabled", "onClick"])
|
|
3316
3321
|
], 2)
|
|
3317
3322
|
], 2),
|
|
3318
|
-
|
|
3323
|
+
k(me, { name: "cl-grow-down" }, {
|
|
3319
3324
|
default: P(() => {
|
|
3320
3325
|
var w;
|
|
3321
3326
|
return [
|
|
3322
|
-
L(
|
|
3323
|
-
(u(!0), v(F, null,
|
|
3327
|
+
L(p("span", Wn, [
|
|
3328
|
+
(u(!0), v(F, null, Q(b.errors, (h, q) => (u(), v("div", {
|
|
3324
3329
|
id: "cl-ui-login-errors",
|
|
3325
|
-
key:
|
|
3330
|
+
key: q,
|
|
3326
3331
|
class: "cl-font-semibold"
|
|
3327
|
-
},
|
|
3332
|
+
}, T(h), 1))), 128))
|
|
3328
3333
|
], 512), [
|
|
3329
3334
|
[H, (w = b.errors) == null ? void 0 : w.length]
|
|
3330
3335
|
])
|
|
@@ -3347,14 +3352,14 @@ const Rn = {
|
|
|
3347
3352
|
], Yn = {
|
|
3348
3353
|
key: 0,
|
|
3349
3354
|
class: "cl-h-0 cl-w-0"
|
|
3350
|
-
}, Xn = { class: "cl-relative cl-w-full" }, es = /* @__PURE__ */
|
|
3355
|
+
}, Xn = { class: "cl-relative cl-w-full" }, es = /* @__PURE__ */ M({
|
|
3351
3356
|
__name: "cl-ui-navigation",
|
|
3352
3357
|
props: {
|
|
3353
3358
|
colour: { default: "default" }
|
|
3354
3359
|
},
|
|
3355
3360
|
setup(t) {
|
|
3356
|
-
const o = A([]),
|
|
3357
|
-
function
|
|
3361
|
+
const o = A([]), l = S(() => o.value.filter((r) => r.open === !0).length > 0);
|
|
3362
|
+
function e(r) {
|
|
3358
3363
|
let w = o.value.find((h) => h.id === r);
|
|
3359
3364
|
return w || (w = {
|
|
3360
3365
|
id: r,
|
|
@@ -3367,9 +3372,9 @@ const Rn = {
|
|
|
3367
3372
|
h.id !== r && (h.open = !1);
|
|
3368
3373
|
}));
|
|
3369
3374
|
}
|
|
3370
|
-
const
|
|
3371
|
-
|
|
3372
|
-
() =>
|
|
3375
|
+
const m = rl();
|
|
3376
|
+
K(
|
|
3377
|
+
() => m,
|
|
3373
3378
|
() => {
|
|
3374
3379
|
s.value = !1;
|
|
3375
3380
|
},
|
|
@@ -3381,37 +3386,37 @@ const Rn = {
|
|
|
3381
3386
|
function c() {
|
|
3382
3387
|
s.value = !s.value, a.value = !0, i();
|
|
3383
3388
|
}
|
|
3384
|
-
const
|
|
3389
|
+
const g = A();
|
|
3385
3390
|
function b() {
|
|
3386
|
-
s.value === !1 &&
|
|
3391
|
+
s.value === !1 && l.value === !0 && o.value.forEach((r) => {
|
|
3387
3392
|
r.open = !1;
|
|
3388
3393
|
});
|
|
3389
3394
|
}
|
|
3390
|
-
return ze(
|
|
3395
|
+
return ze(g, b), (r, w) => (u(), v("div", {
|
|
3391
3396
|
ref_key: "navElement",
|
|
3392
|
-
ref:
|
|
3397
|
+
ref: g,
|
|
3393
3398
|
class: "cl-flex cl-flex-nowrap cl-relative"
|
|
3394
3399
|
}, [
|
|
3395
|
-
|
|
3400
|
+
p("div", {
|
|
3396
3401
|
id: "group-container",
|
|
3397
3402
|
class: _(["cl-h-full cl-overflow-y-auto cl-overscroll-y-none cl-pb-20 cl-w-20 cl-z-30 xl:cl-pb-0", {
|
|
3398
3403
|
"cl-bg-primary-default": r.colour === "default",
|
|
3399
3404
|
"cl-bg-blue-dark": r.colour === "secondary"
|
|
3400
3405
|
}])
|
|
3401
3406
|
}, [
|
|
3402
|
-
|
|
3407
|
+
j(r.$slots, "icon", se({ navcolour: r.colour }, { groupIsOpen: e, toggleOpen: n }), void 0, !0)
|
|
3403
3408
|
], 2),
|
|
3404
|
-
a.value ? (u(), v("div", Yn)) :
|
|
3405
|
-
|
|
3409
|
+
a.value ? (u(), v("div", Yn)) : N("", !0),
|
|
3410
|
+
k(me, { name: "slide-right" }, {
|
|
3406
3411
|
default: P(() => [
|
|
3407
|
-
L(
|
|
3412
|
+
L(p("div", {
|
|
3408
3413
|
class: _(["cl-bg-grey-0 cl-border-grey-2 cl-border-r cl-duration-75 cl-h-full cl-min-w-[260px] cl-overflow-y-auto cl-overscroll-y-none cl-p-8 cl-pb-24 cl-top-0 cl-transition-shadow cl-w-[260px] cl-z-20 xl:cl-pb-0", {
|
|
3409
3414
|
"cl-relative": s.value,
|
|
3410
3415
|
"cl-absolute cl-left-20 cl-shadow-lg": !s.value
|
|
3411
3416
|
}])
|
|
3412
3417
|
}, [
|
|
3413
|
-
|
|
3414
|
-
|
|
3418
|
+
p("div", Xn, [
|
|
3419
|
+
p("span", {
|
|
3415
3420
|
class: "cl-absolute cl-cursor-pointer cl-hidden cl-right-0 cl-top-1.5 lg:cl-block",
|
|
3416
3421
|
onClick: c
|
|
3417
3422
|
}, [
|
|
@@ -3423,10 +3428,10 @@ const Rn = {
|
|
|
3423
3428
|
icon: "ph:push-pin"
|
|
3424
3429
|
}))
|
|
3425
3430
|
]),
|
|
3426
|
-
|
|
3431
|
+
j(r.$slots, "default", le(ne({ groupIsOpen: e })), void 0, !0)
|
|
3427
3432
|
])
|
|
3428
3433
|
], 2), [
|
|
3429
|
-
[H,
|
|
3434
|
+
[H, l.value]
|
|
3430
3435
|
])
|
|
3431
3436
|
]),
|
|
3432
3437
|
_: 3
|
|
@@ -3434,7 +3439,7 @@ const Rn = {
|
|
|
3434
3439
|
], 512));
|
|
3435
3440
|
}
|
|
3436
3441
|
});
|
|
3437
|
-
const ls = /* @__PURE__ */
|
|
3442
|
+
const ls = /* @__PURE__ */ de(es, [["__scopeId", "data-v-7db412a7"]]), ts = /* @__PURE__ */ M({
|
|
3438
3443
|
__name: "cl-ui-navigation-icon",
|
|
3439
3444
|
props: {
|
|
3440
3445
|
iconValue: {},
|
|
@@ -3442,7 +3447,7 @@ const ls = /* @__PURE__ */ fe(es, [["__scopeId", "data-v-7db412a7"]]), ts = /* @
|
|
|
3442
3447
|
colour: { default: "default" }
|
|
3443
3448
|
},
|
|
3444
3449
|
setup(t) {
|
|
3445
|
-
return (o,
|
|
3450
|
+
return (o, l) => (u(), v("div", {
|
|
3446
3451
|
class: _(["cl-cursor-pointer cl-flex cl-h-20 cl-items-center cl-justify-center cl-transition-colors cl-w-20", {
|
|
3447
3452
|
"cl-text-secondary-default hover:cl-bg-primary-dark hover:cl-text-white": o.colour === "default",
|
|
3448
3453
|
"cl-bg-primary-darker cl-text-white": o.open && o.colour === "default",
|
|
@@ -3450,7 +3455,7 @@ const ls = /* @__PURE__ */ fe(es, [["__scopeId", "data-v-7db412a7"]]), ts = /* @
|
|
|
3450
3455
|
"cl-bg-blue-light": o.open && o.colour === "secondary"
|
|
3451
3456
|
}])
|
|
3452
3457
|
}, [
|
|
3453
|
-
|
|
3458
|
+
k(d(I), {
|
|
3454
3459
|
class: "cl-block",
|
|
3455
3460
|
icon: o.iconValue,
|
|
3456
3461
|
width: "24"
|
|
@@ -3460,20 +3465,20 @@ const ls = /* @__PURE__ */ fe(es, [["__scopeId", "data-v-7db412a7"]]), ts = /* @
|
|
|
3460
3465
|
}), os = {
|
|
3461
3466
|
key: 0,
|
|
3462
3467
|
class: "cl-font-bold cl-leading-8 cl-mb-8 cl-pr-8 cl-select-none cl-text-lg cl-text-secondary-default"
|
|
3463
|
-
}, ns = { class: "cl-flex cl-flex-wrap cl-space-y-8 cl-text-sm cl-w-full" }, ss = /* @__PURE__ */
|
|
3468
|
+
}, ns = { class: "cl-flex cl-flex-wrap cl-space-y-8 cl-text-sm cl-w-full" }, ss = /* @__PURE__ */ M({
|
|
3464
3469
|
__name: "cl-ui-navigation-group",
|
|
3465
3470
|
props: {
|
|
3466
3471
|
open: { type: Boolean }
|
|
3467
3472
|
},
|
|
3468
3473
|
setup(t) {
|
|
3469
|
-
return (o,
|
|
3474
|
+
return (o, l) => o.open ? (u(), v(F, { key: 0 }, [
|
|
3470
3475
|
o.$slots.title ? (u(), v("div", os, [
|
|
3471
|
-
|
|
3472
|
-
])) :
|
|
3473
|
-
|
|
3474
|
-
|
|
3476
|
+
j(o.$slots, "title")
|
|
3477
|
+
])) : N("", !0),
|
|
3478
|
+
p("div", ns, [
|
|
3479
|
+
j(o.$slots, "default")
|
|
3475
3480
|
])
|
|
3476
|
-
], 64)) :
|
|
3481
|
+
], 64)) : N("", !0);
|
|
3477
3482
|
}
|
|
3478
3483
|
}), as = {}, rs = { class: "cl-w-full" }, is = {
|
|
3479
3484
|
key: 0,
|
|
@@ -3482,20 +3487,20 @@ const ls = /* @__PURE__ */ fe(es, [["__scopeId", "data-v-7db412a7"]]), ts = /* @
|
|
|
3482
3487
|
function us(t, o) {
|
|
3483
3488
|
return u(), v("div", rs, [
|
|
3484
3489
|
t.$slots.title ? (u(), v("div", is, [
|
|
3485
|
-
|
|
3486
|
-
])) :
|
|
3487
|
-
|
|
3488
|
-
|
|
3490
|
+
j(t.$slots, "title")
|
|
3491
|
+
])) : N("", !0),
|
|
3492
|
+
p("span", cs, [
|
|
3493
|
+
j(t.$slots, "default")
|
|
3489
3494
|
])
|
|
3490
3495
|
]);
|
|
3491
3496
|
}
|
|
3492
|
-
const ds = /* @__PURE__ */
|
|
3497
|
+
const ds = /* @__PURE__ */ de(as, [["render", us]]), ps = {}, fs = { class: "cl-cursor-pointer cl-transition-colors cl-w-full hover:cl-text-blue-light" };
|
|
3493
3498
|
function ms(t, o) {
|
|
3494
3499
|
return u(), v("div", fs, [
|
|
3495
|
-
|
|
3500
|
+
j(t.$slots, "default")
|
|
3496
3501
|
]);
|
|
3497
3502
|
}
|
|
3498
|
-
const gs = /* @__PURE__ */
|
|
3503
|
+
const gs = /* @__PURE__ */ de(ps, [["render", ms]]), vs = { class: "cl-w-full" }, bs = /* @__PURE__ */ M({
|
|
3499
3504
|
__name: "cl-ui-tab",
|
|
3500
3505
|
props: {
|
|
3501
3506
|
currentTab: { default: 0 },
|
|
@@ -3503,42 +3508,42 @@ const gs = /* @__PURE__ */ fe(ps, [["render", ms]]), vs = { class: "cl-w-full" }
|
|
|
3503
3508
|
colour: { default: "default" }
|
|
3504
3509
|
},
|
|
3505
3510
|
setup(t) {
|
|
3506
|
-
const o = t,
|
|
3507
|
-
function
|
|
3511
|
+
const o = t, l = A(), e = A(!1), n = A(!1);
|
|
3512
|
+
function m(c) {
|
|
3508
3513
|
return c === o.currentTab;
|
|
3509
3514
|
}
|
|
3510
3515
|
function s() {
|
|
3511
|
-
if (
|
|
3512
|
-
const c =
|
|
3513
|
-
|
|
3516
|
+
if (l.value) {
|
|
3517
|
+
const c = l.value.scrollWidth - l.value.clientWidth;
|
|
3518
|
+
e.value = l.value.scrollLeft > 0, n.value = l.value.scrollLeft < c;
|
|
3514
3519
|
} else
|
|
3515
|
-
|
|
3520
|
+
e.value = !1, n.value = !1;
|
|
3516
3521
|
}
|
|
3517
3522
|
function a() {
|
|
3518
3523
|
s(), window.addEventListener("resize", s);
|
|
3519
3524
|
}
|
|
3520
3525
|
function i(c) {
|
|
3521
|
-
if (
|
|
3522
|
-
const
|
|
3523
|
-
let b =
|
|
3524
|
-
c === "left" && (b = -
|
|
3526
|
+
if (l.value) {
|
|
3527
|
+
const g = l.value.scrollWidth / 5;
|
|
3528
|
+
let b = g;
|
|
3529
|
+
c === "left" && (b = -g), l.value.scroll(l.value.scrollLeft + b, 0);
|
|
3525
3530
|
}
|
|
3526
3531
|
}
|
|
3527
|
-
return
|
|
3528
|
-
|
|
3529
|
-
|
|
3532
|
+
return Ae(() => a()), Ie(() => window.removeEventListener("resize", s)), (c, g) => (u(), v("div", vs, [
|
|
3533
|
+
p("div", null, [
|
|
3534
|
+
e.value ? (u(), v("div", {
|
|
3530
3535
|
key: 0,
|
|
3531
3536
|
class: "cl-bg-white cl-cursor-pointer cl-float-left cl-h-11 cl-w-4",
|
|
3532
|
-
onClick:
|
|
3537
|
+
onClick: g[0] || (g[0] = (b) => i("left"))
|
|
3533
3538
|
}, [
|
|
3534
|
-
|
|
3539
|
+
k(d(I), {
|
|
3535
3540
|
icon: "ph:caret-left",
|
|
3536
3541
|
class: "cl-mt-4 cl-text-secondary-default"
|
|
3537
3542
|
})
|
|
3538
|
-
])) :
|
|
3539
|
-
|
|
3543
|
+
])) : N("", !0),
|
|
3544
|
+
p("div", {
|
|
3540
3545
|
ref_key: "headerContainer",
|
|
3541
|
-
ref:
|
|
3546
|
+
ref: l,
|
|
3542
3547
|
class: _(["cl-flex cl-overflow-x-auto cl-overscroll-x-none", {
|
|
3543
3548
|
"cl-shadow-[inset_0_-1px_0_#eeeeee]": !c.disabled && c.colour === "default",
|
|
3544
3549
|
"cl-shadow-[inset_0_-1px_0_#9acd32]": !c.disabled && c.colour === "primary",
|
|
@@ -3550,23 +3555,23 @@ const gs = /* @__PURE__ */ fe(ps, [["render", ms]]), vs = { class: "cl-w-full" }
|
|
|
3550
3555
|
}]),
|
|
3551
3556
|
onScrollPassive: s
|
|
3552
3557
|
}, [
|
|
3553
|
-
|
|
3558
|
+
j(c.$slots, "headings", le(ne({ isTabOpen: m, disabled: c.disabled, colour: c.colour })))
|
|
3554
3559
|
], 34),
|
|
3555
3560
|
n.value ? (u(), v("div", {
|
|
3556
3561
|
key: 1,
|
|
3557
3562
|
class: "cl-bg-white cl-bottom-12 cl-cursor-pointer cl-float-right cl-h-11 cl-relative cl-w-4",
|
|
3558
|
-
onClick:
|
|
3563
|
+
onClick: g[1] || (g[1] = (b) => i("right"))
|
|
3559
3564
|
}, [
|
|
3560
|
-
|
|
3565
|
+
k(d(I), {
|
|
3561
3566
|
icon: "ph:caret-right",
|
|
3562
3567
|
class: "cl-mt-4 cl-text-secondary-default"
|
|
3563
3568
|
})
|
|
3564
|
-
])) :
|
|
3569
|
+
])) : N("", !0)
|
|
3565
3570
|
]),
|
|
3566
|
-
|
|
3571
|
+
j(c.$slots, "content", le(ne({ isTabOpen: m, disabled: c.disabled, colour: c.colour })))
|
|
3567
3572
|
]));
|
|
3568
3573
|
}
|
|
3569
|
-
}), hs = ["onKeyup"], ys = /* @__PURE__ */
|
|
3574
|
+
}), hs = ["onKeyup"], ys = /* @__PURE__ */ M({
|
|
3570
3575
|
__name: "cl-ui-tab-header",
|
|
3571
3576
|
props: {
|
|
3572
3577
|
id: {},
|
|
@@ -3578,46 +3583,46 @@ const gs = /* @__PURE__ */ fe(ps, [["render", ms]]), vs = { class: "cl-w-full" }
|
|
|
3578
3583
|
"update:currentTab": null
|
|
3579
3584
|
},
|
|
3580
3585
|
setup(t, { emit: o }) {
|
|
3581
|
-
const
|
|
3586
|
+
const l = t, e = A(), n = A(), m = S(() => l.id === l.currentTab);
|
|
3582
3587
|
function s() {
|
|
3583
|
-
|
|
3588
|
+
l.disabled || (e.value = !1, n.value = !1, o("update:currentTab", l.id));
|
|
3584
3589
|
}
|
|
3585
3590
|
return (a, i) => (u(), v("div", {
|
|
3586
3591
|
class: _(["cl-border-b cl-cursor-pointer cl-flex cl-items-center cl-px-4 cl-py-2 cl-rounded-b-none cl-rounded-sm cl-select-none cl-text-xl cl-transition cl-whitespace-nowrap focus:cl-outline-none", {
|
|
3587
3592
|
"!cl-cursor-default cl-text-grey-4 !cl-border-grey-2": a.disabled,
|
|
3588
|
-
"cl-border cl-border-b-0 cl-rounded-t-md cl-shadow-[inset_0_-1px_0_#ffffff] cl-cursor-default":
|
|
3593
|
+
"cl-border cl-border-b-0 cl-rounded-t-md cl-shadow-[inset_0_-1px_0_#ffffff] cl-cursor-default": m.value,
|
|
3589
3594
|
"cl-border-grey-0": a.colour === "default",
|
|
3590
3595
|
"cl-border-primary-default": a.colour === "primary",
|
|
3591
3596
|
"cl-border-secondary-default": a.colour === "secondary",
|
|
3592
3597
|
"cl-border-danger-default": a.colour === "danger",
|
|
3593
3598
|
"cl-border-link-default": a.colour === "blue",
|
|
3594
|
-
"hover:cl-bg-grey-0": !
|
|
3595
|
-
"hover:cl-bg-primary-lighter": !
|
|
3596
|
-
"hover:cl-bg-secondary-light focus:cl-text-white hover:cl-text-white": !
|
|
3597
|
-
"hover:cl-bg-danger-light": !
|
|
3598
|
-
"hover:cl-bg-link-lighter": !
|
|
3599
|
-
"cl-bg-grey-0":
|
|
3600
|
-
"cl-bg-primary-lighter":
|
|
3601
|
-
"cl-bg-secondary-light cl-text-white":
|
|
3602
|
-
"cl-bg-danger-light":
|
|
3603
|
-
"cl-bg-link-lighter":
|
|
3599
|
+
"hover:cl-bg-grey-0": !m.value && !a.disabled && a.colour === "default",
|
|
3600
|
+
"hover:cl-bg-primary-lighter": !m.value && !a.disabled && a.colour === "primary",
|
|
3601
|
+
"hover:cl-bg-secondary-light focus:cl-text-white hover:cl-text-white": !m.value && !a.disabled && a.colour === "secondary",
|
|
3602
|
+
"hover:cl-bg-danger-light": !m.value && !a.disabled && a.colour === "danger",
|
|
3603
|
+
"hover:cl-bg-link-lighter": !m.value && !a.disabled && a.colour === "blue",
|
|
3604
|
+
"cl-bg-grey-0": e.value && !a.disabled && a.colour === "default",
|
|
3605
|
+
"cl-bg-primary-lighter": e.value && !a.disabled && a.colour === "primary",
|
|
3606
|
+
"cl-bg-secondary-light cl-text-white": e.value && !a.disabled && a.colour === "secondary",
|
|
3607
|
+
"cl-bg-danger-light": e.value && !a.disabled && a.colour === "danger",
|
|
3608
|
+
"cl-bg-link-lighter": e.value && !a.disabled && a.colour === "blue"
|
|
3604
3609
|
}]),
|
|
3605
3610
|
tabindex: "0",
|
|
3606
3611
|
onClick: s,
|
|
3607
3612
|
onMouseover: i[0] || (i[0] = (c) => n.value = !0),
|
|
3608
3613
|
onMouseout: i[1] || (i[1] = (c) => n.value = !1),
|
|
3609
|
-
onFocusin: i[2] || (i[2] = (c) =>
|
|
3610
|
-
onFocusout: i[3] || (i[3] = (c) =>
|
|
3611
|
-
onKeyup:
|
|
3614
|
+
onFocusin: i[2] || (i[2] = (c) => e.value = !0),
|
|
3615
|
+
onFocusout: i[3] || (i[3] = (c) => e.value = !1),
|
|
3616
|
+
onKeyup: we(W(s, ["self"]), ["enter"])
|
|
3612
3617
|
}, [
|
|
3613
|
-
|
|
3618
|
+
j(a.$slots, "default")
|
|
3614
3619
|
], 42, hs));
|
|
3615
3620
|
}
|
|
3616
3621
|
}), ws = {};
|
|
3617
3622
|
function $s(t, o) {
|
|
3618
|
-
return
|
|
3623
|
+
return j(t.$slots, "default");
|
|
3619
3624
|
}
|
|
3620
|
-
const ks = /* @__PURE__ */
|
|
3625
|
+
const ks = /* @__PURE__ */ de(ws, [["render", $s]]), Cs = [
|
|
3621
3626
|
"default",
|
|
3622
3627
|
"primary",
|
|
3623
3628
|
"secondary",
|
|
@@ -3628,22 +3633,22 @@ const ks = /* @__PURE__ */ fe(ws, [["render", $s]]), Cs = [
|
|
|
3628
3633
|
"right"
|
|
3629
3634
|
], Es = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
3630
3635
|
__proto__: null,
|
|
3631
|
-
FilterOperation:
|
|
3632
|
-
buttonColours:
|
|
3636
|
+
FilterOperation: te,
|
|
3637
|
+
buttonColours: Al,
|
|
3633
3638
|
buttonSizes: Sl,
|
|
3634
3639
|
cardSizes: _l,
|
|
3635
3640
|
clUiAccordion: dl,
|
|
3636
3641
|
clUiAccordionHeader: yl,
|
|
3637
3642
|
clUiAccordionItem: gl,
|
|
3638
3643
|
clUiApp: Cl,
|
|
3639
|
-
clUiButton:
|
|
3644
|
+
clUiButton: fe,
|
|
3640
3645
|
clUiCard: jl,
|
|
3641
3646
|
clUiComboBox: jt,
|
|
3642
3647
|
clUiFooter: Lt,
|
|
3643
3648
|
clUiGrid: kn,
|
|
3644
3649
|
clUiHeader: Tn,
|
|
3645
3650
|
clUiHeaderMenu: jn,
|
|
3646
|
-
clUiInput:
|
|
3651
|
+
clUiInput: ae,
|
|
3647
3652
|
clUiLanguageSwitcher: Mn,
|
|
3648
3653
|
clUiLoadingSpinner: Se,
|
|
3649
3654
|
clUiLogin: Kn,
|
|
@@ -3658,14 +3663,14 @@ const ks = /* @__PURE__ */ fe(ws, [["render", $s]]), Cs = [
|
|
|
3658
3663
|
clUiTabContent: ks,
|
|
3659
3664
|
clUiTabHeader: ys,
|
|
3660
3665
|
filterMethodTypes: No,
|
|
3661
|
-
gridColumnTypes:
|
|
3662
|
-
inputTypes:
|
|
3666
|
+
gridColumnTypes: qo,
|
|
3667
|
+
inputTypes: xl,
|
|
3663
3668
|
isComboBoxCreateRequest: It,
|
|
3664
3669
|
isComboBoxItem: _t,
|
|
3665
3670
|
isFilterRequest: Io,
|
|
3666
3671
|
isFilterResponse: Ro,
|
|
3667
3672
|
isGridColumn: Xe,
|
|
3668
|
-
isGridColumnArray:
|
|
3673
|
+
isGridColumnArray: Ao,
|
|
3669
3674
|
isLanguageArray: _n,
|
|
3670
3675
|
isLanguageLocaleFormat: je,
|
|
3671
3676
|
modalColours: Jn,
|
|
@@ -3675,33 +3680,33 @@ const ks = /* @__PURE__ */ fe(ws, [["render", $s]]), Cs = [
|
|
|
3675
3680
|
tabScroll: Ts
|
|
3676
3681
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
3677
3682
|
const Vs = (t) => {
|
|
3678
|
-
t.use(
|
|
3683
|
+
t.use(X), t.component("Icon", I), Object.entries(Es).forEach(([
|
|
3679
3684
|
o,
|
|
3680
|
-
|
|
3685
|
+
l
|
|
3681
3686
|
]) => {
|
|
3682
|
-
t.component(o,
|
|
3687
|
+
t.component(o, l);
|
|
3683
3688
|
});
|
|
3684
3689
|
};
|
|
3685
3690
|
export {
|
|
3686
3691
|
Ms as CitrusLimeUI,
|
|
3687
|
-
|
|
3688
|
-
|
|
3689
|
-
|
|
3690
|
-
|
|
3692
|
+
x as DateFormat,
|
|
3693
|
+
te as FilterOperation,
|
|
3694
|
+
Y as NumberFormat,
|
|
3695
|
+
Al as buttonColours,
|
|
3691
3696
|
Sl as buttonSizes,
|
|
3692
3697
|
_l as cardSizes,
|
|
3693
3698
|
dl as clUiAccordion,
|
|
3694
3699
|
yl as clUiAccordionHeader,
|
|
3695
3700
|
gl as clUiAccordionItem,
|
|
3696
3701
|
Cl as clUiApp,
|
|
3697
|
-
|
|
3702
|
+
fe as clUiButton,
|
|
3698
3703
|
jl as clUiCard,
|
|
3699
3704
|
jt as clUiComboBox,
|
|
3700
3705
|
Lt as clUiFooter,
|
|
3701
3706
|
kn as clUiGrid,
|
|
3702
3707
|
Tn as clUiHeader,
|
|
3703
3708
|
jn as clUiHeaderMenu,
|
|
3704
|
-
|
|
3709
|
+
ae as clUiInput,
|
|
3705
3710
|
Mn as clUiLanguageSwitcher,
|
|
3706
3711
|
Se as clUiLoadingSpinner,
|
|
3707
3712
|
Kn as clUiLogin,
|
|
@@ -3718,15 +3723,15 @@ export {
|
|
|
3718
3723
|
zl as datetimeFormats,
|
|
3719
3724
|
Vs as default,
|
|
3720
3725
|
No as filterMethodTypes,
|
|
3721
|
-
|
|
3722
|
-
|
|
3723
|
-
|
|
3726
|
+
qo as gridColumnTypes,
|
|
3727
|
+
X as i18n,
|
|
3728
|
+
xl as inputTypes,
|
|
3724
3729
|
It as isComboBoxCreateRequest,
|
|
3725
3730
|
_t as isComboBoxItem,
|
|
3726
3731
|
Io as isFilterRequest,
|
|
3727
3732
|
Ro as isFilterResponse,
|
|
3728
3733
|
Xe as isGridColumn,
|
|
3729
|
-
|
|
3734
|
+
Ao as isGridColumnArray,
|
|
3730
3735
|
_n as isLanguageArray,
|
|
3731
3736
|
je as isLanguageLocaleFormat,
|
|
3732
3737
|
Il as messages,
|