@opengis/partsmap 0.1.3 → 0.1.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/index.js +367 -367
- package/index.umd.cjs +1 -1
- package/package.json +1 -1
package/index.js
CHANGED
@@ -1,10 +1,10 @@
|
|
1
|
-
import { defineComponent as Y, ref as V, watch as
|
2
|
-
const
|
1
|
+
import { defineComponent as Y, ref as V, watch as D, createBlock as j, openBlock as p, resolveDynamicComponent as oe, mergeProps as Z, withCtx as re, renderSlot as ee, computed as E, useSlots as we, createElementBlock as k, createCommentVNode as S, Fragment as K, renderList as q, unref as e, createElementVNode as a, normalizeClass as F, toDisplayString as L, createVNode as I, createTextVNode as W, toRaw as ve, cloneVNode as Je, nextTick as ke, onMounted as ue, onBeforeUnmount as he, Teleport as Ie, withDirectives as P, normalizeStyle as Ce, vShow as X, vModelText as te, withModifiers as Pe, isRef as Xe, createStaticVNode as Te, resolveDirective as et, getCurrentInstance as tt } from "vue";
|
2
|
+
const lt = { class: "flex items-center justify-between w-full text-sm" }, at = { class: "flex items-center cursor-pointer w-full" }, ot = {
|
3
3
|
key: 0,
|
4
4
|
width: "16",
|
5
5
|
height: "auto",
|
6
6
|
src: "data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PScwIDAgMTYgMTYnIGZpbGw9J3doaXRlJyB4bWxucz0naHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmcnPjxwYXRoIGQ9J00xMi4yMDcgNC43OTNhMSAxIDAgMDEwIDEuNDE0bC01IDVhMSAxIDAgMDEtMS40MTQgMGwtMi0yYTEgMSAwIDAxMS40MTQtMS40MTRMNi41IDkuMDg2bDQuMjkzLTQuMjkzYTEgMSAwIDAxMS40MTQgMHonLz48L3N2Zz4="
|
7
|
-
},
|
7
|
+
}, rt = ["value"], nt = { class: "w-[calc(100%-18px)] flex flex-row items-center justify-between pl-[10px]" }, it = { class: "flex flex-row items-center font-normal text-gray-800 gap-x-1" }, st = {
|
8
8
|
key: 0,
|
9
9
|
class: "text-xs text-gray-500 dark:text-neutral-500 pr-1"
|
10
10
|
}, _e = /* @__PURE__ */ Y({
|
@@ -31,15 +31,15 @@ const tt = { class: "flex items-center justify-between w-full text-sm" }, lt = {
|
|
31
31
|
ref_key: "el",
|
32
32
|
ref: v
|
33
33
|
}, [
|
34
|
-
a("div",
|
35
|
-
a("div",
|
34
|
+
a("div", lt, [
|
35
|
+
a("div", at, [
|
36
36
|
a("label", {
|
37
37
|
for: "radio-9740",
|
38
38
|
class: F([
|
39
39
|
["inline", "popover"].includes(g.layout) ? "text-sm text-gray-500 px-2 w-full py-2 cursor-pointer !flex flex-row items-center" : "flex flex-row items-center w-full px-2 py-2 text-sm text-gray-500 cursor-pointer",
|
40
40
|
{ "bg-blue-100": g.highlighted }
|
41
41
|
]),
|
42
|
-
onClick:
|
42
|
+
onClick: Pe(s, ["stop", "prevent"])
|
43
43
|
}, [
|
44
44
|
a("div", {
|
45
45
|
class: F(["w-[18px] h-[18px] border flex items-center justify-center", [
|
@@ -47,17 +47,17 @@ const tt = { class: "flex items-center justify-between w-full text-sm" }, lt = {
|
|
47
47
|
g.color ? `bg-[${g.color}] border-[#ffffff]` : g.isSelected ? "bg-[#2563eb] border-[#ffffff]" : "bg-[#ffffff] border-[#d9d9d9]"
|
48
48
|
]])
|
49
49
|
}, [
|
50
|
-
g.isSelected ? (p(), k("img",
|
50
|
+
g.isSelected ? (p(), k("img", ot)) : S("", !0)
|
51
51
|
], 2),
|
52
52
|
a("input", {
|
53
53
|
type: "checkbox",
|
54
54
|
class: "hidden",
|
55
55
|
id: "radio-9740",
|
56
56
|
value: g.value
|
57
|
-
}, null, 8,
|
58
|
-
a("div",
|
59
|
-
a("span",
|
60
|
-
g.count ? (p(), k("div",
|
57
|
+
}, null, 8, rt),
|
58
|
+
a("div", nt, [
|
59
|
+
a("span", it, L(g.label ?? "Відсутні данні"), 1),
|
60
|
+
g.count ? (p(), k("div", st, " (" + L(g.count) + ") ", 1)) : S("", !0)
|
61
61
|
])
|
62
62
|
], 2)
|
63
63
|
])
|
@@ -65,7 +65,7 @@ const tt = { class: "flex items-center justify-between w-full text-sm" }, lt = {
|
|
65
65
|
], 512));
|
66
66
|
}
|
67
67
|
});
|
68
|
-
function
|
68
|
+
function He(i, o) {
|
69
69
|
const {
|
70
70
|
options: d = [],
|
71
71
|
limit: r = 20
|
@@ -86,7 +86,7 @@ function Te(i, o) {
|
|
86
86
|
const n = b.value;
|
87
87
|
return i.layout === "popover" || f.value ? n : n.slice(0, r);
|
88
88
|
});
|
89
|
-
|
89
|
+
D(() => i.modelValue, (n) => {
|
90
90
|
s.value = t(n);
|
91
91
|
}, { immediate: !0 }), b.value = [...d].sort((n, C) => i.sort === "count" ? C.count && n.count ? C.count - n.count : 0 : i.sort === "name" ? String(n[m.value] ?? "").localeCompare(String(C[m.value] ?? "")) : 0);
|
92
92
|
function u(n) {
|
@@ -122,18 +122,18 @@ const le = (i, o) => {
|
|
122
122
|
for (const [r, t] of o)
|
123
123
|
d[r] = t;
|
124
124
|
return d;
|
125
|
-
},
|
125
|
+
}, ut = {}, dt = {
|
126
126
|
class: "w-48 mx-auto",
|
127
127
|
viewBox: "0 0 178 90",
|
128
128
|
fill: "none",
|
129
129
|
xmlns: "http://www.w3.org/2000/svg"
|
130
130
|
};
|
131
|
-
function
|
132
|
-
return p(), k("svg",
|
133
|
-
|
131
|
+
function ct(i, o) {
|
132
|
+
return p(), k("svg", dt, o[0] || (o[0] = [
|
133
|
+
Te('<rect x="27" y="50.5" width="124" height="39" rx="7.5" fill="currentColor" class="fill-white dark:fill-neutral-800"></rect><rect x="27" y="50.5" width="124" height="39" rx="7.5" stroke="currentColor" class="stroke-gray-50 dark:stroke-neutral-700/10"></rect><rect x="34.5" y="58" width="24" height="24" rx="4" fill="currentColor" class="fill-gray-50 dark:fill-neutral-700/30"></rect><rect x="66.5" y="61" width="60" height="6" rx="3" fill="currentColor" class="fill-gray-50 dark:fill-neutral-700/30"></rect><rect x="66.5" y="73" width="77" height="6" rx="3" fill="currentColor" class="fill-gray-50 dark:fill-neutral-700/30"></rect><rect x="19.5" y="28.5" width="139" height="39" rx="7.5" fill="currentColor" class="fill-white dark:fill-neutral-800"></rect><rect x="19.5" y="28.5" width="139" height="39" rx="7.5" stroke="currentColor" class="stroke-gray-100 dark:stroke-neutral-700/30"></rect><rect x="27" y="36" width="24" height="24" rx="4" fill="currentColor" class="fill-gray-100 dark:fill-neutral-700/70"></rect><rect x="59" y="39" width="60" height="6" rx="3" fill="currentColor" class="fill-gray-100 dark:fill-neutral-700/70"></rect><rect x="59" y="51" width="92" height="6" rx="3" fill="currentColor" class="fill-gray-100 dark:fill-neutral-700/70"></rect><g filter="url(#filter1)"><rect x="12" y="6" width="154" height="40" rx="8" fill="currentColor" class="fill-white dark:fill-neutral-800" shape-rendering="crispEdges"></rect><rect x="12.5" y="6.5" width="153" height="39" rx="7.5" stroke="currentColor" class="stroke-gray-100 dark:stroke-neutral-700/60" shape-rendering="crispEdges"></rect><rect x="20" y="14" width="24" height="24" rx="4" fill="currentColor" class="fill-gray-200 dark:fill-neutral-700"></rect><rect x="52" y="17" width="60" height="6" rx="3" fill="currentColor" class="fill-gray-200 dark:fill-neutral-700"></rect><rect x="52" y="29" width="106" height="6" rx="3" fill="currentColor" class="fill-gray-200 dark:fill-neutral-700"></rect></g><defs><filter id="filter1" x="0" y="0" width="178" height="64" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"></feColorMatrix><feOffset dy="6"></feOffset><feGaussianBlur stdDeviation="6"></feGaussianBlur><feComposite in2="hardAlpha" operator="out"></feComposite><feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.03 0"></feColorMatrix><feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_1187_14810"></feBlend><feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_1187_14810" result="shape"></feBlend></filter></defs>', 12)
|
134
134
|
]));
|
135
135
|
}
|
136
|
-
const Ve = /* @__PURE__ */ le(
|
136
|
+
const Ve = /* @__PURE__ */ le(ut, [["render", ct]]), pt = {}, ft = {
|
137
137
|
xmlns: "http://www.w3.org/2000/svg",
|
138
138
|
width: "24",
|
139
139
|
height: "24",
|
@@ -145,8 +145,8 @@ const Ve = /* @__PURE__ */ le(st, [["render", dt]]), ct = {}, pt = {
|
|
145
145
|
"stroke-linejoin": "round",
|
146
146
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-chevron-down w-[14px] rotate"
|
147
147
|
};
|
148
|
-
function
|
149
|
-
return p(), k("svg",
|
148
|
+
function vt(i, o) {
|
149
|
+
return p(), k("svg", ft, o[0] || (o[0] = [
|
150
150
|
a("path", {
|
151
151
|
stroke: "none",
|
152
152
|
d: "M0 0h24v24H0z",
|
@@ -155,7 +155,7 @@ function ft(i, o) {
|
|
155
155
|
a("path", { d: "M6 9l6 6l6 -6" }, null, -1)
|
156
156
|
]));
|
157
157
|
}
|
158
|
-
const be = /* @__PURE__ */ le(
|
158
|
+
const be = /* @__PURE__ */ le(pt, [["render", vt]]), mt = {}, gt = {
|
159
159
|
xmlns: "http://www.w3.org/2000/svg",
|
160
160
|
width: "24",
|
161
161
|
height: "24",
|
@@ -167,8 +167,8 @@ const be = /* @__PURE__ */ le(ct, [["render", ft]]), vt = {}, mt = {
|
|
167
167
|
"stroke-linejoin": "round",
|
168
168
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-chevron-down w-[14px] rotate-[180deg]"
|
169
169
|
};
|
170
|
-
function
|
171
|
-
return p(), k("svg",
|
170
|
+
function ht(i, o) {
|
171
|
+
return p(), k("svg", gt, o[0] || (o[0] = [
|
172
172
|
a("path", {
|
173
173
|
stroke: "none",
|
174
174
|
d: "M0 0h24v24H0z",
|
@@ -177,16 +177,16 @@ function gt(i, o) {
|
|
177
177
|
a("path", { d: "M6 9l6 6l6 -6" }, null, -1)
|
178
178
|
]));
|
179
179
|
}
|
180
|
-
const Se = /* @__PURE__ */ le(
|
180
|
+
const Se = /* @__PURE__ */ le(mt, [["render", ht]]), bt = {
|
181
181
|
key: 0,
|
182
182
|
class: "w-full"
|
183
|
-
},
|
183
|
+
}, yt = { class: "flex flex-col items-center justify-center p-5 text-center" }, xt = {
|
184
184
|
key: 0,
|
185
185
|
class: "flex justify-between p-2 border-t bg-gray-50 text-xs text-gray-500"
|
186
|
-
},
|
186
|
+
}, wt = {
|
187
187
|
key: 1,
|
188
188
|
class: "flex justify-between items-center text-xs text-gray-500 p-1 border-t"
|
189
|
-
},
|
189
|
+
}, kt = /* @__PURE__ */ Y({
|
190
190
|
__name: "radio",
|
191
191
|
props: {
|
192
192
|
id: {},
|
@@ -226,14 +226,14 @@ const Se = /* @__PURE__ */ le(vt, [["render", gt]]), ht = {
|
|
226
226
|
labelKey: u,
|
227
227
|
valueKey: l,
|
228
228
|
allOptions: x
|
229
|
-
} =
|
229
|
+
} = He({
|
230
230
|
...r,
|
231
231
|
modelValue: r.modelValue ?? r.default ?? ""
|
232
232
|
}, s);
|
233
233
|
return o({
|
234
234
|
clear: m,
|
235
235
|
inputTextRef: t
|
236
|
-
}),
|
236
|
+
}), D(
|
237
237
|
() => r.modelValue,
|
238
238
|
(h) => {
|
239
239
|
h === void 0 && (v.value = void 0);
|
@@ -259,8 +259,8 @@ const Se = /* @__PURE__ */ le(vt, [["render", gt]]), ht = {
|
|
259
259
|
onItemClick: (M) => e(w)(C)
|
260
260
|
}, null, 8, ["layout", "count", "label", "color", "value", "is-selected", "onItemClick"]))), 128))
|
261
261
|
], 2),
|
262
|
-
h.type === "select" && e(g).length === 0 && !e(y) ? (p(), k("div",
|
263
|
-
a("div",
|
262
|
+
h.type === "select" && e(g).length === 0 && !e(y) ? (p(), k("div", bt, [
|
263
|
+
a("div", yt, [
|
264
264
|
I(Ve),
|
265
265
|
n[4] || (n[4] = a("div", { class: "max-w-sm mx-auto mt-6" }, [
|
266
266
|
a("p", { class: "font-medium text-gray-800 dark:text-neutral-200" }, "За вашим запитом нічого не знайдено"),
|
@@ -289,7 +289,7 @@ const Se = /* @__PURE__ */ le(vt, [["render", gt]]), ht = {
|
|
289
289
|
])) : S("", !0)
|
290
290
|
], 64)) : S("", !0),
|
291
291
|
h.cleanable ? (p(), k(K, { key: 2 }, [
|
292
|
-
h.layout === "inline" ? (p(), k("div",
|
292
|
+
h.layout === "inline" ? (p(), k("div", xt, [
|
293
293
|
W(L(e(v) || e(v) === null ? 1 : 0) + " з " + L(e(x).length) + " обрано ", 1),
|
294
294
|
P(a("button", {
|
295
295
|
class: "text-gray-600 hover:text-gray-800",
|
@@ -299,7 +299,7 @@ const Se = /* @__PURE__ */ le(vt, [["render", gt]]), ht = {
|
|
299
299
|
[X, e(v) !== "" && e(v) !== void 0]
|
300
300
|
])
|
301
301
|
])) : S("", !0),
|
302
|
-
h.layout === "popover" ? (p(), k("div",
|
302
|
+
h.layout === "popover" ? (p(), k("div", wt, [
|
303
303
|
a("span", null, L(e(v) || e(v) === null ? 1 : 0) + " з " + L(e(x).length) + " обрано", 1),
|
304
304
|
P(a("button", {
|
305
305
|
class: "text-gray-600 hover:text-gray-800",
|
@@ -313,7 +313,7 @@ const Se = /* @__PURE__ */ le(vt, [["render", gt]]), ht = {
|
|
313
313
|
], 2));
|
314
314
|
}
|
315
315
|
});
|
316
|
-
function
|
316
|
+
function Ee(i, o) {
|
317
317
|
const {
|
318
318
|
options: d = [],
|
319
319
|
limit: r = 20
|
@@ -334,7 +334,7 @@ function He(i, o) {
|
|
334
334
|
const n = b.value;
|
335
335
|
return i.layout === "popover" || f.value ? n : n.slice(0, r);
|
336
336
|
});
|
337
|
-
|
337
|
+
D(() => i.modelValue, (n) => {
|
338
338
|
s.value = t(n);
|
339
339
|
}, { immediate: !0 }), b.value = [...d].sort((n, C) => i.sort === "count" ? C.count && n.count ? C.count - n.count : 0 : i.sort === "name" ? String(n[m.value]).localeCompare(String(C[m.value])) : 0);
|
340
340
|
function u(n) {
|
@@ -366,16 +366,16 @@ function He(i, o) {
|
|
366
366
|
allOptions: b
|
367
367
|
};
|
368
368
|
}
|
369
|
-
const
|
369
|
+
const Ct = {
|
370
370
|
key: 0,
|
371
371
|
class: "w-full"
|
372
|
-
},
|
372
|
+
}, _t = { class: "flex flex-col items-center justify-center p-5 text-center" }, Vt = {
|
373
373
|
key: 0,
|
374
374
|
class: "flex justify-between p-2 border-t bg-gray-50 text-xs text-gray-500"
|
375
|
-
},
|
375
|
+
}, St = {
|
376
376
|
key: 1,
|
377
377
|
class: "flex justify-between items-center text-xs text-gray-500 p-1 border-t"
|
378
|
-
},
|
378
|
+
}, Fe = /* @__PURE__ */ Y({
|
379
379
|
__name: "checkbox",
|
380
380
|
props: {
|
381
381
|
id: {},
|
@@ -415,11 +415,11 @@ const kt = {
|
|
415
415
|
labelKey: c,
|
416
416
|
valueKey: u,
|
417
417
|
allOptions: l
|
418
|
-
} =
|
418
|
+
} = Ee({
|
419
419
|
...r,
|
420
420
|
modelValue: r.modelValue
|
421
421
|
}, t);
|
422
|
-
return
|
422
|
+
return D(
|
423
423
|
() => r.modelValue,
|
424
424
|
(x) => {
|
425
425
|
x === void 0 && (s.value = []);
|
@@ -446,8 +446,8 @@ const kt = {
|
|
446
446
|
onItemClick: (C) => e(b)(n)
|
447
447
|
}, null, 8, ["layout", "count", "label", "color", "value", "is-selected", "onItemClick"]))), 256))
|
448
448
|
], 2),
|
449
|
-
x.type === "select" && e(v).length === 0 && !e(f) ? (p(), k("div",
|
450
|
-
a("div",
|
449
|
+
x.type === "select" && e(v).length === 0 && !e(f) ? (p(), k("div", Ct, [
|
450
|
+
a("div", _t, [
|
451
451
|
I(Ve),
|
452
452
|
h[4] || (h[4] = a("div", { class: "max-w-sm mx-auto mt-6" }, [
|
453
453
|
a("p", { class: "font-medium text-gray-800 dark:text-neutral-200" }, "За вашим запитом нічого не знайдено"),
|
@@ -476,7 +476,7 @@ const kt = {
|
|
476
476
|
])) : S("", !0)
|
477
477
|
], 64)) : S("", !0),
|
478
478
|
x.cleanable ? (p(), k(K, { key: 2 }, [
|
479
|
-
x.layout === "inline" ? (p(), k("div",
|
479
|
+
x.layout === "inline" ? (p(), k("div", Vt, [
|
480
480
|
W(L(e(s).length) + " з " + L(e(l).length) + " обрано ", 1),
|
481
481
|
P(a("button", {
|
482
482
|
class: "text-gray-600 hover:text-gray-800",
|
@@ -486,7 +486,7 @@ const kt = {
|
|
486
486
|
[X, e(s).length !== 0]
|
487
487
|
])
|
488
488
|
])) : S("", !0),
|
489
|
-
x.layout === "popover" ? (p(), k("div",
|
489
|
+
x.layout === "popover" ? (p(), k("div", St, [
|
490
490
|
a("span", null, L(e(s).length) + " з " + L(e(l).length) + " обрано", 1),
|
491
491
|
P(a("button", {
|
492
492
|
class: "text-gray-600 hover:text-gray-800",
|
@@ -499,7 +499,7 @@ const kt = {
|
|
499
499
|
], 64)) : S("", !0)
|
500
500
|
], 2));
|
501
501
|
}
|
502
|
-
}),
|
502
|
+
}), Mt = {}, Bt = {
|
503
503
|
xmlns: "http://www.w3.org/2000/svg",
|
504
504
|
width: "15px",
|
505
505
|
height: "15px",
|
@@ -511,8 +511,8 @@ const kt = {
|
|
511
511
|
"stroke-linejoin": "round",
|
512
512
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-search stroke-gray-500 transition-all"
|
513
513
|
};
|
514
|
-
function
|
515
|
-
return p(), k("svg",
|
514
|
+
function $t(i, o) {
|
515
|
+
return p(), k("svg", Bt, o[0] || (o[0] = [
|
516
516
|
a("path", {
|
517
517
|
stroke: "none",
|
518
518
|
d: "M0 0h24v24H0z",
|
@@ -522,7 +522,7 @@ function Bt(i, o) {
|
|
522
522
|
a("path", { d: "M21 21l-6 -6" }, null, -1)
|
523
523
|
]));
|
524
524
|
}
|
525
|
-
const
|
525
|
+
const Ye = /* @__PURE__ */ le(Mt, [["render", $t]]), At = {}, Rt = {
|
526
526
|
xmlns: "http://www.w3.org/2000/svg",
|
527
527
|
viewBox: "0 0 24 24",
|
528
528
|
fill: "none",
|
@@ -534,8 +534,8 @@ const Ee = /* @__PURE__ */ le(St, [["render", Bt]]), $t = {}, At = {
|
|
534
534
|
width: "15px",
|
535
535
|
height: "15px"
|
536
536
|
};
|
537
|
-
function
|
538
|
-
return p(), k("svg",
|
537
|
+
function Dt(i, o) {
|
538
|
+
return p(), k("svg", Rt, o[0] || (o[0] = [
|
539
539
|
a("path", {
|
540
540
|
stroke: "none",
|
541
541
|
d: "M0 0h24v24H0z",
|
@@ -545,13 +545,13 @@ function Rt(i, o) {
|
|
545
545
|
a("path", { d: "M6 6l12 12" }, null, -1)
|
546
546
|
]));
|
547
547
|
}
|
548
|
-
const
|
548
|
+
const We = /* @__PURE__ */ le(At, [["render", Dt]]);
|
549
549
|
class ye {
|
550
550
|
static getWidthClass(o) {
|
551
551
|
return typeof o == "number" ? `max-w-[${o}px]` : typeof o == "string" ? o.endsWith("%") || o.endsWith("px") ? `max-w-[${o}]` : `max-w-${o}` : "w-full";
|
552
552
|
}
|
553
553
|
}
|
554
|
-
const
|
554
|
+
const zt = { class: "absolute bottom-2/4 translate-y-2/4 cursor-pointer left-3" }, jt = ["placeholder"], Ft = /* @__PURE__ */ Y({
|
555
555
|
__name: "text-input",
|
556
556
|
props: {
|
557
557
|
id: {},
|
@@ -579,7 +579,7 @@ const Dt = { class: "absolute bottom-2/4 translate-y-2/4 cursor-pointer left-3"
|
|
579
579
|
emits: ["update:modelValue", "change", "clear"],
|
580
580
|
setup(i, { emit: o }) {
|
581
581
|
const d = i, r = V((d.placeHolder || d.label || d.name || "search").toString()), t = o, s = V(d.modelValue ?? "");
|
582
|
-
|
582
|
+
D(
|
583
583
|
() => d.modelValue,
|
584
584
|
(b) => {
|
585
585
|
b !== s.value && (s.value = b ?? "");
|
@@ -597,15 +597,15 @@ const Dt = { class: "absolute bottom-2/4 translate-y-2/4 cursor-pointer left-3"
|
|
597
597
|
b.layout === "inline" ? e(ye).getWidthClass(b.width) : "mb-2" + (b.layout === "popover" ? " m-2" : "")
|
598
598
|
])
|
599
599
|
}, [
|
600
|
-
a("div",
|
601
|
-
I(
|
600
|
+
a("div", zt, [
|
601
|
+
I(Ye)
|
602
602
|
]),
|
603
603
|
s.value !== "" ? (p(), k("div", {
|
604
604
|
key: 0,
|
605
605
|
onClick: g,
|
606
606
|
class: "absolute bottom-2/4 translate-y-2/4 right-3 cursor-pointer"
|
607
607
|
}, [
|
608
|
-
I(
|
608
|
+
I(We)
|
609
609
|
])) : S("", !0),
|
610
610
|
P(a("input", {
|
611
611
|
type: "text",
|
@@ -613,37 +613,37 @@ const Dt = { class: "absolute bottom-2/4 translate-y-2/4 cursor-pointer left-3"
|
|
613
613
|
onInput: v,
|
614
614
|
placeholder: r.value,
|
615
615
|
class: "!pr-7 !pl-8 bg-white h-[38px] min-w-[100px] text-sm py-2 px-3 block w-full border border-solid placeholder:text-nowrap border-stone-200 rounded-lg text-sm text-stone-800 placeholder:text-stone-400 focus:border-2 focus:z-10 focus:border-blue-500 focus:ring-blue-500 focus:outline-blue-500"
|
616
|
-
}, null, 40,
|
616
|
+
}, null, 40, jt), [
|
617
617
|
[te, s.value]
|
618
618
|
])
|
619
619
|
], 2));
|
620
620
|
}
|
621
621
|
});
|
622
|
-
function
|
622
|
+
function qe(i = { color: "blue" }) {
|
623
623
|
return E(() => {
|
624
624
|
const o = `w-full px-3 py-2 border-solid border border-gray-300 text-sm rounded focus:outline-none focus:ring-2 focus:ring-${i.color}-500 focus:border-transparent`;
|
625
625
|
return (i == null ? void 0 : i.size) === "sm" ? `${o}h-[32px]` : `${o}h-[38px]`;
|
626
626
|
});
|
627
627
|
}
|
628
|
-
function
|
628
|
+
function Kt() {
|
629
629
|
return "rounded-md font-medium border-gray-200 border-solid disabled:pointer-events-none disabled:opacity-50 px-4 py-2 w-full bg-transparent border text-black text-sm h-[38px]";
|
630
630
|
}
|
631
|
-
function
|
631
|
+
function Lt() {
|
632
632
|
return "font-medium border-gray-200 border-solid disabled:pointer-events-none disabled:opacity-50 border h-7 rounded-md text-xs px-2 py-1 hover:bg-gray-100";
|
633
633
|
}
|
634
|
-
function
|
634
|
+
function Ne(i) {
|
635
635
|
return i === "ghost" ? "inline-flex relative py-2 px-4 items-center gap-x-2 text-sm font-medium rounded-lg border border-transparent text-gray-600 hover:bg-blue-100 hover:text-gray-800 focus:outline-hidden focus:bg-gray-100 focus:text-gray-800 disabled:opacity-50 disabled:pointer-events-none dark:text-gray-500 dark:hover:bg-blue-800/30 dark:hover:text-blue-400 dark:focus:bg-blue-800/30 dark:focus:text-blue-400" : i === "soft" ? "inline-flex relative py-2 px-4 items-center gap-x-2 text-sm font-medium rounded-lg border border-transparent bg-gray-100 text-gray-800 hover:bg-gray-200 hover:bg-gray-200 focus:outline-hidden focus:bg-gray-200 disabled:opacity-50 disabled:pointer-events-none dark:text-blue-400 dark:hover:bg-blue-900 dark:focus:bg-blue-900" : "relative border-solid border-gray-200 focus-visible:outline-hidden focus-visible:ring-ring inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 border-input hover:bg-gray-100 border px-4 py-2 gap-2 bg-transparent h-[38px]";
|
636
636
|
}
|
637
|
-
const
|
637
|
+
const Ut = {
|
638
638
|
key: 0,
|
639
639
|
class: "block text-xs font-medium text-gray-600 mb-1"
|
640
|
-
},
|
640
|
+
}, Ot = ["placeholder", "disabled"], It = {
|
641
641
|
key: 0,
|
642
642
|
class: "block text-xs font-medium text-gray-600 mb-1"
|
643
|
-
},
|
643
|
+
}, Pt = {
|
644
644
|
key: 0,
|
645
645
|
class: "block text-xs font-medium text-gray-600 mb-1"
|
646
|
-
},
|
646
|
+
}, Tt = ["placeholder", "disabled"], Ht = ["disabled"], Et = /* @__PURE__ */ Y({
|
647
647
|
__name: "range-input",
|
648
648
|
props: {
|
649
649
|
id: {},
|
@@ -670,7 +670,7 @@ const Lt = {
|
|
670
670
|
},
|
671
671
|
emits: ["update:modelValue", "change", "clear"],
|
672
672
|
setup(i, { expose: o, emit: d }) {
|
673
|
-
const r =
|
673
|
+
const r = qe(), t = Kt(), s = i, v = V(
|
674
674
|
s.modelValue ?? s.default ?? []
|
675
675
|
), g = d, b = E({
|
676
676
|
get: () => s.modelValue ?? v.value,
|
@@ -684,7 +684,7 @@ const Lt = {
|
|
684
684
|
function m() {
|
685
685
|
v.value = [], b.value = v.value, g("clear", s.name);
|
686
686
|
}
|
687
|
-
return
|
687
|
+
return D(() => s.modelValue, (f) => {
|
688
688
|
f !== void 0 && s.layout !== "popover" ? (v.value = f, g("update:modelValue", f)) : v.value = [];
|
689
689
|
}), o({
|
690
690
|
clear: m,
|
@@ -697,7 +697,7 @@ const Lt = {
|
|
697
697
|
class: F(f.layout === "vertical" ? "inline-flex items-center gap-2" : "space-y-3 p-2")
|
698
698
|
}, [
|
699
699
|
a("div", null, [
|
700
|
-
f.layout !== "vertical" ? (p(), k("label",
|
700
|
+
f.layout !== "vertical" ? (p(), k("label", Ut, "Від")) : S("", !0),
|
701
701
|
P(a("input", {
|
702
702
|
type: "number",
|
703
703
|
class: F(e(r)),
|
@@ -706,13 +706,13 @@ const Lt = {
|
|
706
706
|
style: { outline: "none" },
|
707
707
|
"onUpdate:modelValue": y[0] || (y[0] = (u) => b.value[0] = u),
|
708
708
|
disabled: f.disabled
|
709
|
-
}, null, 10,
|
709
|
+
}, null, 10, Ot), [
|
710
710
|
[te, b.value[0]]
|
711
711
|
])
|
712
712
|
]),
|
713
|
-
f.layout === "vertical" ? (p(), k("label",
|
713
|
+
f.layout === "vertical" ? (p(), k("label", It, " - ")) : S("", !0),
|
714
714
|
a("div", null, [
|
715
|
-
f.layout !== "vertical" ? (p(), k("label",
|
715
|
+
f.layout !== "vertical" ? (p(), k("label", Pt, "До")) : S("", !0),
|
716
716
|
P(a("input", {
|
717
717
|
type: "number",
|
718
718
|
class: F(e(r)),
|
@@ -723,7 +723,7 @@ const Lt = {
|
|
723
723
|
style: { outline: "none" },
|
724
724
|
"onUpdate:modelValue": y[1] || (y[1] = (u) => b.value[1] = u),
|
725
725
|
disabled: f.disabled
|
726
|
-
}, null, 10,
|
726
|
+
}, null, 10, Tt), [
|
727
727
|
[te, b.value[1]]
|
728
728
|
])
|
729
729
|
]),
|
@@ -737,17 +737,17 @@ const Lt = {
|
|
737
737
|
disabled: !(b.value[0] || b.value[1]),
|
738
738
|
onClick: m,
|
739
739
|
class: F(e(t) + " hover:bg-gray-100")
|
740
|
-
}, "Очистити", 10,
|
740
|
+
}, "Очистити", 10, Ht)) : S("", !0)
|
741
741
|
], 2)
|
742
742
|
]),
|
743
743
|
(f.cleanable && v.value.length, S("", !0))
|
744
744
|
], 64);
|
745
745
|
};
|
746
746
|
}
|
747
|
-
}),
|
747
|
+
}), Yt = ["disabled", "title"], Wt = {
|
748
748
|
key: 0,
|
749
749
|
class: "absolute top-0 end-0 inline-flex min-h-[10px] min-w-[10px] z-10 items-center py-0.5 rounded-full text-xs font-medium transform -translate-y-1/2 translate-x-1/2 bg-blue-600 text-white px-1"
|
750
|
-
},
|
750
|
+
}, qt = { class: "w-full text-sm text-stone-800 bg-white shadow-[0_10px_40px_10px_rgba(0,0,0,0.08)] rounded-lg focus:outline-none focus:bg-stone-100 after:h-4 after:absolute after:-bottom-4 after:start-0 after:w-full before:h-4 before:absolute before:-top-4 before:start-0 before:w-full" }, Nt = { class: "w-[360px] max-h-[500px] overflow-auto [&::-webkit-scrollbar]:h-2 [&::-webkit-scrollbar]:w-1 [&::-webkit-scrollbar-thumb]:rounded-full [&::-webkit-scrollbar-track]:bg-stone-100 [&::-webkit-scrollbar-thumb]:bg-stone-300 dark:[&::-webkit-scrollbar-track]:bg-neutral-700 dark:[&::-webkit-scrollbar-thumb]:bg-neutral-500 before:w-full p-2" }, Me = /* @__PURE__ */ Y({
|
751
751
|
__name: "popover-field",
|
752
752
|
props: {
|
753
753
|
disabled: { type: Boolean, default: !1 },
|
@@ -759,7 +759,7 @@ const Lt = {
|
|
759
759
|
layout: {}
|
760
760
|
},
|
761
761
|
setup(i, { expose: o }) {
|
762
|
-
const d = i, r = E(() =>
|
762
|
+
const d = i, r = E(() => Ne(d.mode)), t = V(!1), s = V({ top: 0, left: 0 }), v = V(null), g = V(null), b = V(null);
|
763
763
|
function w() {
|
764
764
|
const l = g.value, x = b.value;
|
765
765
|
if (!l || !x) return;
|
@@ -810,9 +810,9 @@ const Lt = {
|
|
810
810
|
class: F(["truncate text-ellipsis block", l.width ? e(ye).getWidthClass(l.width - 50) : "w-full"])
|
811
811
|
}, L(u.value), 3),
|
812
812
|
I(be, { class: "h-4 w-4" }),
|
813
|
-
(Array.isArray(l.currentValue) ? l.currentValue === null || l.currentValue.length > 0 : l.currentValue === null || l.currentValue) && l.layout === "inline" ? (p(), k("span",
|
814
|
-
], 10,
|
815
|
-
_.value ? (p(), j(
|
813
|
+
(Array.isArray(l.currentValue) ? l.currentValue === null || l.currentValue.length > 0 : l.currentValue === null || l.currentValue) && l.layout === "inline" ? (p(), k("span", Wt)) : S("", !0)
|
814
|
+
], 10, Yt),
|
815
|
+
_.value ? (p(), j(Ie, {
|
816
816
|
key: 0,
|
817
817
|
to: "body"
|
818
818
|
}, [
|
@@ -823,8 +823,8 @@ const Lt = {
|
|
823
823
|
style: Ce({ top: `${s.value.top}px`, left: `${s.value.left}px` }),
|
824
824
|
"data-inside-popover": ""
|
825
825
|
}, [
|
826
|
-
a("div",
|
827
|
-
a("div",
|
826
|
+
a("div", qt, [
|
827
|
+
a("div", Nt, [
|
828
828
|
ee(l.$slots, "default")
|
829
829
|
])
|
830
830
|
])
|
@@ -835,7 +835,7 @@ const Lt = {
|
|
835
835
|
]));
|
836
836
|
}
|
837
837
|
});
|
838
|
-
function
|
838
|
+
function Gt(i) {
|
839
839
|
return String(i).charAt(0).toUpperCase() + String(i).slice(1);
|
840
840
|
}
|
841
841
|
class N {
|
@@ -886,7 +886,7 @@ class N {
|
|
886
886
|
return r.setDate(d.getDate() - o), [this.format(r), this.format(d)];
|
887
887
|
}
|
888
888
|
}
|
889
|
-
function
|
889
|
+
function Ge(i, o) {
|
890
890
|
const {
|
891
891
|
popoverRef: d
|
892
892
|
} = i, r = V(""), t = V(
|
@@ -1033,22 +1033,22 @@ function Ne(i, o) {
|
|
1033
1033
|
clear: c
|
1034
1034
|
};
|
1035
1035
|
}
|
1036
|
-
const
|
1036
|
+
const Qt = {
|
1037
1037
|
key: 0,
|
1038
1038
|
class: "relative flex w-full h-auto gap-2 filter-date m-2 flex-wrap"
|
1039
|
-
},
|
1039
|
+
}, Zt = {
|
1040
1040
|
key: 0,
|
1041
1041
|
class: "flex gap-1 !w-[75%] rounded-lg"
|
1042
|
-
},
|
1042
|
+
}, Jt = ["max", "disabled"], Xt = ["min", "disabled"], el = {
|
1043
1043
|
key: 0,
|
1044
1044
|
class: "block text-xs font-medium text-gray-600 mb-1"
|
1045
|
-
},
|
1045
|
+
}, tl = ["max", "disabled"], ll = {
|
1046
1046
|
key: 0,
|
1047
1047
|
class: "block text-xs font-medium text-gray-600 mb-1"
|
1048
|
-
},
|
1048
|
+
}, al = {
|
1049
1049
|
key: 0,
|
1050
1050
|
class: "block text-xs font-medium text-gray-600 mb-1"
|
1051
|
-
},
|
1051
|
+
}, ol = ["min", "disabled"], rl = { class: "flex gap-1 pt-2" }, nl = ["onClick"], il = /* @__PURE__ */ Y({
|
1052
1052
|
__name: "date-input",
|
1053
1053
|
props: {
|
1054
1054
|
id: {},
|
@@ -1075,25 +1075,25 @@ const Gt = {
|
|
1075
1075
|
},
|
1076
1076
|
emits: ["update:modelValue", "change", "clear"],
|
1077
1077
|
setup(i, { expose: o, emit: d }) {
|
1078
|
-
const r = i, t =
|
1078
|
+
const r = i, t = qe(), s = Lt(), v = d, g = V(null), {
|
1079
1079
|
activeMode: b,
|
1080
1080
|
innerValue: w,
|
1081
1081
|
onSelectChange: m,
|
1082
1082
|
nextClick: f,
|
1083
1083
|
prevClick: y,
|
1084
1084
|
clear: _
|
1085
|
-
} =
|
1085
|
+
} = Ge({
|
1086
1086
|
...r,
|
1087
1087
|
popoverRef: g
|
1088
1088
|
}, v);
|
1089
|
-
return
|
1089
|
+
return D(() => r.modelValue, (c) => {
|
1090
1090
|
c !== void 0 ? (w.value = c, v("update:modelValue", c)) : (b.value = "", w.value = []);
|
1091
1091
|
}), o({
|
1092
1092
|
clear: _,
|
1093
1093
|
popoverRef: g
|
1094
1094
|
}), (c, u) => (p(), k(K, null, [
|
1095
|
-
c.layout === "inline" ? (p(), k("div",
|
1096
|
-
e(b) !== "" && e(b) === "range" ? (p(), k("div",
|
1095
|
+
c.layout === "inline" ? (p(), k("div", Qt, [
|
1096
|
+
e(b) !== "" && e(b) === "range" ? (p(), k("div", Zt, [
|
1097
1097
|
P(a("input", {
|
1098
1098
|
type: "date",
|
1099
1099
|
max: e(w)[1],
|
@@ -1101,7 +1101,7 @@ const Gt = {
|
|
1101
1101
|
"onUpdate:modelValue": u[0] || (u[0] = (l) => e(w)[0] = l),
|
1102
1102
|
class: "px-2 p-0 border text-[12px] max-w-[calc(50%-5px)] h-[38px] rounded-lg focus:outline-blue-600",
|
1103
1103
|
disabled: c.disabled
|
1104
|
-
}, null, 8,
|
1104
|
+
}, null, 8, Jt), [
|
1105
1105
|
[te, e(w)[0]]
|
1106
1106
|
]),
|
1107
1107
|
P(a("input", {
|
@@ -1111,7 +1111,7 @@ const Gt = {
|
|
1111
1111
|
"onUpdate:modelValue": u[1] || (u[1] = (l) => e(w)[1] = l),
|
1112
1112
|
class: "px-2 p-0 border text-[12px] max-w-[calc(50%-5px)] h-[38px] rounded-lg focus:outline-blue-600 appearance-auto",
|
1113
1113
|
disabled: c.disabled
|
1114
|
-
}, null, 8,
|
1114
|
+
}, null, 8, Xt), [
|
1115
1115
|
[te, e(w)[1]]
|
1116
1116
|
])
|
1117
1117
|
])) : S("", !0)
|
@@ -1122,7 +1122,7 @@ const Gt = {
|
|
1122
1122
|
a("div", {
|
1123
1123
|
class: F(c.layout !== "popover" ? "w-[48%]" : "")
|
1124
1124
|
}, [
|
1125
|
-
c.layout === "popover" ? (p(), k("label",
|
1125
|
+
c.layout === "popover" ? (p(), k("label", el, "Від")) : S("", !0),
|
1126
1126
|
P(a("input", {
|
1127
1127
|
type: "date",
|
1128
1128
|
max: e(w)[1],
|
@@ -1130,15 +1130,15 @@ const Gt = {
|
|
1130
1130
|
"onUpdate:modelValue": u[2] || (u[2] = (l) => e(w)[0] = l),
|
1131
1131
|
class: F(e(t)),
|
1132
1132
|
disabled: c.disabled
|
1133
|
-
}, null, 10,
|
1133
|
+
}, null, 10, tl), [
|
1134
1134
|
[te, e(w)[0]]
|
1135
1135
|
])
|
1136
1136
|
], 2),
|
1137
|
-
c.layout !== "popover" ? (p(), k("label",
|
1137
|
+
c.layout !== "popover" ? (p(), k("label", ll, " - ")) : S("", !0),
|
1138
1138
|
a("div", {
|
1139
1139
|
class: F(c.layout !== "popover" ? "w-[48%]" : "")
|
1140
1140
|
}, [
|
1141
|
-
c.layout === "popover" ? (p(), k("label",
|
1141
|
+
c.layout === "popover" ? (p(), k("label", al, "До")) : S("", !0),
|
1142
1142
|
P(a("input", {
|
1143
1143
|
type: "date",
|
1144
1144
|
min: e(w)[0],
|
@@ -1146,17 +1146,17 @@ const Gt = {
|
|
1146
1146
|
"onUpdate:modelValue": u[3] || (u[3] = (l) => e(w)[1] = l),
|
1147
1147
|
class: F(e(t)),
|
1148
1148
|
disabled: c.disabled
|
1149
|
-
}, null, 10,
|
1149
|
+
}, null, 10, ol), [
|
1150
1150
|
[te, e(w)[1]]
|
1151
1151
|
])
|
1152
1152
|
], 2)
|
1153
1153
|
], 2),
|
1154
|
-
a("div",
|
1154
|
+
a("div", rl, [
|
1155
1155
|
(p(), k(K, null, q(["today", "week", "month", "quarter", "year"], (l) => a("button", {
|
1156
1156
|
key: l,
|
1157
1157
|
class: F(e(s) + (e(b) === l ? " bg-blue-100" : "")),
|
1158
1158
|
onClick: (x) => e(m)(l)
|
1159
|
-
}, L(e(
|
1159
|
+
}, L(e(Gt)(l)), 11, nl)), 64)),
|
1160
1160
|
a("button", {
|
1161
1161
|
class: F(e(s)),
|
1162
1162
|
onClick: u[4] || (u[4] = //@ts-ignore
|
@@ -1172,7 +1172,7 @@ const Gt = {
|
|
1172
1172
|
], 64));
|
1173
1173
|
}
|
1174
1174
|
});
|
1175
|
-
function
|
1175
|
+
function sl(i, o) {
|
1176
1176
|
const {
|
1177
1177
|
api: d,
|
1178
1178
|
options: r = [],
|
@@ -1223,11 +1223,11 @@ function il(i, o) {
|
|
1223
1223
|
}
|
1224
1224
|
}
|
1225
1225
|
}
|
1226
|
-
|
1226
|
+
D(w, (B) => {
|
1227
1227
|
d && (C && clearTimeout(C), C = setTimeout(() => {
|
1228
1228
|
M(B);
|
1229
1229
|
}, 200));
|
1230
|
-
}),
|
1230
|
+
}), D(() => i.modelValue, (B) => {
|
1231
1231
|
b.value = g(B);
|
1232
1232
|
}, { immediate: !0 }), d ? M("") : f.value = r;
|
1233
1233
|
function $(B) {
|
@@ -1254,7 +1254,7 @@ function il(i, o) {
|
|
1254
1254
|
C && clearTimeout(C);
|
1255
1255
|
});
|
1256
1256
|
const J = V(-1);
|
1257
|
-
|
1257
|
+
D(n, () => {
|
1258
1258
|
J.value = n.value.length > 0 ? 0 : -1;
|
1259
1259
|
});
|
1260
1260
|
function H(B) {
|
@@ -1289,16 +1289,16 @@ function il(i, o) {
|
|
1289
1289
|
totalCount: x
|
1290
1290
|
};
|
1291
1291
|
}
|
1292
|
-
const
|
1292
|
+
const ul = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relative justify-center" }, dl = {
|
1293
1293
|
key: 0,
|
1294
1294
|
class: "w-full"
|
1295
|
-
},
|
1295
|
+
}, cl = { class: "flex flex-col items-center justify-center p-5 text-center" }, pl = {
|
1296
1296
|
key: 0,
|
1297
1297
|
class: "flex justify-between p-2 border-t bg-gray-50 text-xs text-gray-500"
|
1298
|
-
},
|
1298
|
+
}, fl = {
|
1299
1299
|
key: 1,
|
1300
1300
|
class: "flex justify-between items-center text-xs text-gray-500 p-1 border-t"
|
1301
|
-
},
|
1301
|
+
}, vl = /* @__PURE__ */ Y({
|
1302
1302
|
__name: "select",
|
1303
1303
|
props: {
|
1304
1304
|
id: {},
|
@@ -1343,26 +1343,26 @@ const sl = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relat
|
|
1343
1343
|
onKeyDown: C,
|
1344
1344
|
selectedLabels: M,
|
1345
1345
|
totalCount: $
|
1346
|
-
} =
|
1346
|
+
} = sl({
|
1347
1347
|
...r,
|
1348
1348
|
modelValue: r.modelValue
|
1349
1349
|
}, t);
|
1350
1350
|
ue(() => {
|
1351
1351
|
f();
|
1352
|
-
}),
|
1352
|
+
}), D(
|
1353
1353
|
() => r.modelValue,
|
1354
1354
|
(T) => {
|
1355
1355
|
T === void 0 && (r.multi ? v.value = [] : v.value = void 0);
|
1356
1356
|
}
|
1357
1357
|
);
|
1358
1358
|
const A = V([]);
|
1359
|
-
return
|
1359
|
+
return D(n, (T) => {
|
1360
1360
|
var U;
|
1361
1361
|
T >= 0 && A.value[T] && ((U = A.value[T]) == null || U.scrollIntoView({
|
1362
1362
|
block: "nearest",
|
1363
1363
|
behavior: "smooth"
|
1364
1364
|
}));
|
1365
|
-
}),
|
1365
|
+
}), D(g, () => {
|
1366
1366
|
A.value = [];
|
1367
1367
|
}), o({
|
1368
1368
|
clear: m,
|
@@ -1373,9 +1373,9 @@ const sl = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relat
|
|
1373
1373
|
return p(), k("div", {
|
1374
1374
|
class: F([T.layout === "popover" ? "flex flex-col h-full" : "flex flex-col vs-filter-checkbox space-y-0.5"])
|
1375
1375
|
}, [
|
1376
|
-
a("div",
|
1376
|
+
a("div", ul, [
|
1377
1377
|
P(a("input", {
|
1378
|
-
"onUpdate:modelValue": U[0] || (U[0] = (H) =>
|
1378
|
+
"onUpdate:modelValue": U[0] || (U[0] = (H) => Xe(l) ? l.value = H : null),
|
1379
1379
|
onKeydown: U[1] || (U[1] = //@ts-ignore
|
1380
1380
|
(...H) => e(C) && e(C)(...H)),
|
1381
1381
|
class: "w-full h-full text-[13px] px-4 border rounded-sm pl-9 focus:outline-none focus:ring-ring focus:ring-1 focus:ring-blue-500",
|
@@ -1386,8 +1386,8 @@ const sl = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relat
|
|
1386
1386
|
}, null, 544), [
|
1387
1387
|
[te, e(l)]
|
1388
1388
|
]),
|
1389
|
-
I(
|
1390
|
-
I(
|
1389
|
+
I(Ye, { class: "absolute text-gray-400 -translate-y-1/2 left-4 top-1/2" }),
|
1390
|
+
I(We, {
|
1391
1391
|
onClick: U[2] || (U[2] = (H) => l.value = ""),
|
1392
1392
|
class: "absolute text-gray-400 -translate-y-1/2 cursor-pointer hover:text-red-500 right-4 top-1/2"
|
1393
1393
|
})
|
@@ -1412,8 +1412,8 @@ const sl = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relat
|
|
1412
1412
|
ref: (O) => A.value[B] = O == null ? void 0 : O.el
|
1413
1413
|
}, null, 8, ["layout", "count", "label", "color", "type", "value", "is-selected", "highlighted", "onItemClick"]))), 256))
|
1414
1414
|
], 2),
|
1415
|
-
T.type === "select" && e(g).length === 0 && !e(_) ? (p(), k("div",
|
1416
|
-
a("div",
|
1415
|
+
T.type === "select" && e(g).length === 0 && !e(_) ? (p(), k("div", dl, [
|
1416
|
+
a("div", cl, [
|
1417
1417
|
I(Ve),
|
1418
1418
|
U[7] || (U[7] = a("div", { class: "max-w-sm mx-auto mt-6" }, [
|
1419
1419
|
a("p", { class: "font-medium text-gray-800 dark:text-neutral-200" }, "За вашим запитом нічого не знайдено"),
|
@@ -1442,7 +1442,7 @@ const sl = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relat
|
|
1442
1442
|
])) : S("", !0)
|
1443
1443
|
], 64)) : S("", !0),
|
1444
1444
|
T.cleanable ? (p(), k(K, { key: 2 }, [
|
1445
|
-
T.layout === "inline" ? (p(), k("div",
|
1445
|
+
T.layout === "inline" ? (p(), k("div", pl, [
|
1446
1446
|
W(L(T.multi && Array.isArray(e(v)) ? (de = e(v)) == null ? void 0 : de.length : e(v) !== void 0 && (e(v) || e(v) === null) ? 1 : 0) + " з " + L(e($)) + " обрано ", 1),
|
1447
1447
|
P(a("button", {
|
1448
1448
|
class: "text-gray-600 hover:text-gray-800",
|
@@ -1452,7 +1452,7 @@ const sl = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relat
|
|
1452
1452
|
[X, e(v) !== "" && e(v) !== void 0 || e(v)]
|
1453
1453
|
])
|
1454
1454
|
])) : S("", !0),
|
1455
|
-
T.layout === "popover" ? (p(), k("div",
|
1455
|
+
T.layout === "popover" ? (p(), k("div", fl, [
|
1456
1456
|
a("span", null, L(T.multi && Array.isArray(e(v)) ? (J = e(v)) == null ? void 0 : J.length : e(v) !== void 0 && (e(v) || e(v) === null) ? 1 : 0) + " з " + L(e($)) + " обрано", 1),
|
1457
1457
|
P(a("button", {
|
1458
1458
|
class: "text-gray-600 hover:text-gray-800",
|
@@ -1466,13 +1466,13 @@ const sl = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relat
|
|
1466
1466
|
], 2);
|
1467
1467
|
};
|
1468
1468
|
}
|
1469
|
-
}),
|
1469
|
+
}), ml = ["for", "onClick"], gl = ["id", "name", "value"], hl = { class: "block" }, bl = {
|
1470
1470
|
key: 0,
|
1471
1471
|
class: "flex justify-between p-2 border-t bg-gray-50 text-xs text-gray-500"
|
1472
|
-
},
|
1472
|
+
}, yl = {
|
1473
1473
|
key: 1,
|
1474
1474
|
class: "flex justify-between items-center text-xs text-gray-500 p-1 border-t"
|
1475
|
-
},
|
1475
|
+
}, xl = /* @__PURE__ */ Y({
|
1476
1476
|
__name: "tag-field",
|
1477
1477
|
props: {
|
1478
1478
|
id: {},
|
@@ -1507,16 +1507,16 @@ const sl = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relat
|
|
1507
1507
|
labelKey: w,
|
1508
1508
|
valueKey: m,
|
1509
1509
|
allOptions: f
|
1510
|
-
} = r.multi ?
|
1510
|
+
} = r.multi ? Ee({
|
1511
1511
|
...r,
|
1512
1512
|
modelValue: r.modelValue ?? r.default ?? []
|
1513
|
-
}, t) :
|
1513
|
+
}, t) : He({
|
1514
1514
|
...r,
|
1515
1515
|
modelValue: r.modelValue !== void 0 ? r.modelValue : r.default ?? ""
|
1516
1516
|
}, t);
|
1517
1517
|
return o({
|
1518
1518
|
clear: b
|
1519
|
-
}),
|
1519
|
+
}), D(
|
1520
1520
|
() => r.modelValue,
|
1521
1521
|
(y) => {
|
1522
1522
|
y === void 0 && (r.multi ? s.value = [] : s.value = void 0);
|
@@ -1530,7 +1530,7 @@ const sl = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relat
|
|
1530
1530
|
(p(!0), k(K, null, q(e(f), (l) => (p(), k("label", {
|
1531
1531
|
key: `item-${l[e(m)]}`,
|
1532
1532
|
for: `item-${l[e(m)]}`,
|
1533
|
-
onClick:
|
1533
|
+
onClick: Pe((x) => e(g)(l), ["stop", "prevent"]),
|
1534
1534
|
class: F([e(v)(l) ? "ring-2 ring-indigo-600" : "", "p-2.5 group relative flex justify-center items-center gap-x-12 text-center text-xs bg-white text-gray-800 border border-gray-200 cursor-pointer rounded-lg dark:bg-neutral-900 dark:border-neutral-700 dark:text-neutral-200 peer-checked:text-indigo-600 dark:has-checked:text-indigo-500 peer-checked:border-indigo-600 dark:has-checked:border-indigo-500 peer-checked:ring peer-checked:shadow focus:ring dark:has-checked:ring-indigo-500 has-disabled:pointer-events-none has-disabled:text-gray-200 dark:has-disabled:text-neutral-700 has-disabled:after:absolute has-disabled:after:inset-0 has-disabled:after:bg-[linear-gradient(to_right_bottom,transparent_calc(50%-1px),var(--color-gray-200)_calc(50%-1px),var(--color-gray-200)_50%,transparent_50%)] dark:has-disabled:after:bg-[linear-gradient(to_right_bottom,transparent_calc(50%-1px),var(--color-neutral-700)_calc(50%-1px),var(--color-neutral-700)_50%,transparent_50%)]"])
|
1535
1535
|
}, [
|
1536
1536
|
a("input", {
|
@@ -1539,12 +1539,12 @@ const sl = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relat
|
|
1539
1539
|
class: "hidden w4poy border-gray-200 g41z1 g22e3 axcnw dark:text-indigo-500 dark:border-neutral-700 dark:focus:ring-neutral-900",
|
1540
1540
|
name: `item-${l[e(m)]}`,
|
1541
1541
|
value: l[e(m)]
|
1542
|
-
}, null, 8,
|
1543
|
-
a("span",
|
1544
|
-
], 10,
|
1542
|
+
}, null, 8, gl),
|
1543
|
+
a("span", hl, L(l[e(w)]), 1)
|
1544
|
+
], 10, ml))), 128))
|
1545
1545
|
], 2),
|
1546
1546
|
y.cleanable ? (p(), k(K, { key: 0 }, [
|
1547
|
-
y.layout === "inline" ? (p(), k("div",
|
1547
|
+
y.layout === "inline" ? (p(), k("div", bl, [
|
1548
1548
|
W(L(y.multi && Array.isArray(e(s)) ? (c = e(s)) == null ? void 0 : c.length : e(s) !== void 0 && (e(s) || e(s) === null) ? 1 : 0) + " з " + L(e(f).length) + " обрано ", 1),
|
1549
1549
|
P(a("button", {
|
1550
1550
|
class: "text-gray-600 hover:text-gray-800",
|
@@ -1554,7 +1554,7 @@ const sl = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relat
|
|
1554
1554
|
[X, e(s) !== "" && e(s) !== void 0 || e(s)]
|
1555
1555
|
])
|
1556
1556
|
])) : S("", !0),
|
1557
|
-
y.layout === "popover" ? (p(), k("div",
|
1557
|
+
y.layout === "popover" ? (p(), k("div", yl, [
|
1558
1558
|
a("span", null, L(y.multi && Array.isArray(e(s)) ? (u = e(s)) == null ? void 0 : u.length : e(s) !== void 0 && (e(s) || e(s) === null) ? 1 : 0) + " з " + L(e(f).length) + " обрано", 1),
|
1559
1559
|
P(a("button", {
|
1560
1560
|
class: "text-gray-600 hover:text-gray-800",
|
@@ -1568,7 +1568,7 @@ const sl = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relat
|
|
1568
1568
|
], 64);
|
1569
1569
|
};
|
1570
1570
|
}
|
1571
|
-
}),
|
1571
|
+
}), wl = {}, kl = {
|
1572
1572
|
xmlns: "http://www.w3.org/2000/svg",
|
1573
1573
|
width: "24",
|
1574
1574
|
height: "24",
|
@@ -1580,12 +1580,12 @@ const sl = { class: "h-[45px] shrink-0 px-[6px] py-[4px] flex items-center relat
|
|
1580
1580
|
"stroke-linejoin": "round",
|
1581
1581
|
class: "text-blue-600 w-[16px] h-[16px]"
|
1582
1582
|
};
|
1583
|
-
function
|
1584
|
-
return p(), k("svg",
|
1583
|
+
function Cl(i, o) {
|
1584
|
+
return p(), k("svg", kl, o[0] || (o[0] = [
|
1585
1585
|
a("path", { d: "M20 6 9 17l-5-5" }, null, -1)
|
1586
1586
|
]));
|
1587
1587
|
}
|
1588
|
-
const se = /* @__PURE__ */ le(
|
1588
|
+
const se = /* @__PURE__ */ le(wl, [["render", Cl]]), _l = {}, Vl = {
|
1589
1589
|
xmlns: "http://www.w3.org/2000/svg",
|
1590
1590
|
width: "15px",
|
1591
1591
|
height: "24",
|
@@ -1597,8 +1597,8 @@ const se = /* @__PURE__ */ le(xl, [["render", kl]]), Cl = {}, _l = {
|
|
1597
1597
|
"stroke-linejoin": "round",
|
1598
1598
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-chevron-down text-gray-800 rotate-[90deg]"
|
1599
1599
|
};
|
1600
|
-
function
|
1601
|
-
return p(), k("svg",
|
1600
|
+
function Sl(i, o) {
|
1601
|
+
return p(), k("svg", Vl, o[0] || (o[0] = [
|
1602
1602
|
a("path", {
|
1603
1603
|
stroke: "none",
|
1604
1604
|
d: "M0 0h24v24H0z",
|
@@ -1607,7 +1607,7 @@ function Vl(i, o) {
|
|
1607
1607
|
a("path", { d: "M6 9l6 6l6 -6" }, null, -1)
|
1608
1608
|
]));
|
1609
1609
|
}
|
1610
|
-
const
|
1610
|
+
const Ml = /* @__PURE__ */ le(_l, [["render", Sl]]), Bl = {}, $l = {
|
1611
1611
|
xmlns: "http://www.w3.org/2000/svg",
|
1612
1612
|
width: "15px",
|
1613
1613
|
height: "24",
|
@@ -1619,8 +1619,8 @@ const Sl = /* @__PURE__ */ le(Cl, [["render", Vl]]), Ml = {}, Bl = {
|
|
1619
1619
|
"stroke-linejoin": "round",
|
1620
1620
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-chevron-down text-gray-800 rotate-[270deg]"
|
1621
1621
|
};
|
1622
|
-
function
|
1623
|
-
return p(), k("svg",
|
1622
|
+
function Al(i, o) {
|
1623
|
+
return p(), k("svg", $l, o[0] || (o[0] = [
|
1624
1624
|
a("path", {
|
1625
1625
|
stroke: "none",
|
1626
1626
|
d: "M0 0h24v24H0z",
|
@@ -1629,10 +1629,10 @@ function $l(i, o) {
|
|
1629
1629
|
a("path", { d: "M6 9l6 6l6 -6" }, null, -1)
|
1630
1630
|
]));
|
1631
1631
|
}
|
1632
|
-
const
|
1632
|
+
const Rl = /* @__PURE__ */ le(Bl, [["render", Al]]), Dl = { class: "flex" }, zl = { class: "mb-1" }, jl = { class: "mb-1" }, Fl = { class: "inline-flex rounded-lg shrink-0 pl-1" }, Kl = { class: "inline-flex rounded-lg shrink-0 pl-1" }, Ll = {
|
1633
1633
|
key: 1,
|
1634
1634
|
class: "flex gap-1 !w-[75%] rounded-lg"
|
1635
|
-
},
|
1635
|
+
}, Ul = ["max", "disabled"], Ol = ["min", "disabled"], Il = /* @__PURE__ */ Y({
|
1636
1636
|
__name: "date-input-inline",
|
1637
1637
|
props: {
|
1638
1638
|
id: {},
|
@@ -1667,17 +1667,17 @@ const Al = /* @__PURE__ */ le(Ml, [["render", $l]]), Rl = { class: "flex" }, Dl
|
|
1667
1667
|
prevClick: m,
|
1668
1668
|
currentLabel: f,
|
1669
1669
|
clear: y
|
1670
|
-
} =
|
1670
|
+
} = Ge({
|
1671
1671
|
...r,
|
1672
1672
|
popoverRef: s
|
1673
1673
|
}, t);
|
1674
|
-
return
|
1674
|
+
return D(() => r.modelValue, (_) => {
|
1675
1675
|
_ !== void 0 ? (g.value = _, t("update:modelValue", _)) : (v.value = "", g.value = []);
|
1676
1676
|
}), o({
|
1677
1677
|
clear: y,
|
1678
1678
|
popoverRef: s
|
1679
1679
|
}), (_, c) => (p(), k(K, null, [
|
1680
|
-
a("div",
|
1680
|
+
a("div", Dl, [
|
1681
1681
|
I(Me, {
|
1682
1682
|
ref_key: "popoverRef",
|
1683
1683
|
ref: s,
|
@@ -1741,7 +1741,7 @@ const Al = /* @__PURE__ */ le(Ml, [["render", $l]]), Rl = { class: "flex" }, Dl
|
|
1741
1741
|
e(v) === "quarter" ? (p(), j(se, { key: 0 })) : S("", !0)
|
1742
1742
|
])
|
1743
1743
|
]),
|
1744
|
-
a("div",
|
1744
|
+
a("div", zl, [
|
1745
1745
|
a("button", {
|
1746
1746
|
type: "button",
|
1747
1747
|
onClick: c[5] || (c[5] = (u) => e(b)("year")),
|
@@ -1751,7 +1751,7 @@ const Al = /* @__PURE__ */ le(Ml, [["render", $l]]), Rl = { class: "flex" }, Dl
|
|
1751
1751
|
e(v) === "year" ? (p(), j(se, { key: 0 })) : S("", !0)
|
1752
1752
|
])
|
1753
1753
|
]),
|
1754
|
-
a("div",
|
1754
|
+
a("div", jl, [
|
1755
1755
|
a("button", {
|
1756
1756
|
type: "button",
|
1757
1757
|
onClick: c[6] || (c[6] = (u) => e(y)()),
|
@@ -1766,7 +1766,7 @@ const Al = /* @__PURE__ */ le(Ml, [["render", $l]]), Rl = { class: "flex" }, Dl
|
|
1766
1766
|
__: [19]
|
1767
1767
|
}, 8, ["label", "current-value", "mode", "onClear", "layout"]),
|
1768
1768
|
e(v) !== "" && e(v) !== "range" && e(v) !== "last_7_days" ? (p(), k(K, { key: 0 }, [
|
1769
|
-
a("div",
|
1769
|
+
a("div", Fl, [
|
1770
1770
|
a("button", {
|
1771
1771
|
type: "button",
|
1772
1772
|
title: "Попередній період",
|
@@ -1774,10 +1774,10 @@ const Al = /* @__PURE__ */ le(Ml, [["render", $l]]), Rl = { class: "flex" }, Dl
|
|
1774
1774
|
onClick: c[7] || (c[7] = //@ts-ignore
|
1775
1775
|
(...u) => e(m) && e(m)(...u))
|
1776
1776
|
}, [
|
1777
|
-
I(
|
1777
|
+
I(Ml)
|
1778
1778
|
])
|
1779
1779
|
]),
|
1780
|
-
a("div",
|
1780
|
+
a("div", Kl, [
|
1781
1781
|
a("button", {
|
1782
1782
|
type: "button",
|
1783
1783
|
title: "Наступний період",
|
@@ -1785,11 +1785,11 @@ const Al = /* @__PURE__ */ le(Ml, [["render", $l]]), Rl = { class: "flex" }, Dl
|
|
1785
1785
|
onClick: c[8] || (c[8] = //@ts-ignore
|
1786
1786
|
(...u) => e(w) && e(w)(...u))
|
1787
1787
|
}, [
|
1788
|
-
I(
|
1788
|
+
I(Rl)
|
1789
1789
|
])
|
1790
1790
|
])
|
1791
1791
|
], 64)) : S("", !0),
|
1792
|
-
e(v) !== "" && e(v) === "range" ? (p(), k("div",
|
1792
|
+
e(v) !== "" && e(v) === "range" ? (p(), k("div", Ll, [
|
1793
1793
|
P(a("input", {
|
1794
1794
|
type: "date",
|
1795
1795
|
max: e(g)[1],
|
@@ -1797,7 +1797,7 @@ const Al = /* @__PURE__ */ le(Ml, [["render", $l]]), Rl = { class: "flex" }, Dl
|
|
1797
1797
|
"onUpdate:modelValue": c[9] || (c[9] = (u) => e(g)[0] = u),
|
1798
1798
|
class: "px-2 p-0 border text-[12px] max-w-[calc(50%-5px)] h-[38px] rounded-lg focus:outline-blue-600",
|
1799
1799
|
disabled: _.disabled
|
1800
|
-
}, null, 8,
|
1800
|
+
}, null, 8, Ul), [
|
1801
1801
|
[te, e(g)[0]]
|
1802
1802
|
]),
|
1803
1803
|
P(a("input", {
|
@@ -1807,7 +1807,7 @@ const Al = /* @__PURE__ */ le(Ml, [["render", $l]]), Rl = { class: "flex" }, Dl
|
|
1807
1807
|
"onUpdate:modelValue": c[10] || (c[10] = (u) => e(g)[1] = u),
|
1808
1808
|
class: "px-2 p-0 border text-[12px] max-w-[calc(50%-5px)] h-[38px] rounded-lg focus:outline-blue-600 appearance-auto",
|
1809
1809
|
disabled: _.disabled
|
1810
|
-
}, null, 8,
|
1810
|
+
}, null, 8, Ol), [
|
1811
1811
|
[te, e(g)[1]]
|
1812
1812
|
])
|
1813
1813
|
])) : S("", !0)
|
@@ -1815,16 +1815,16 @@ const Al = /* @__PURE__ */ le(Ml, [["render", $l]]), Rl = { class: "flex" }, Dl
|
|
1815
1815
|
(_.cleanable, S("", !0))
|
1816
1816
|
], 64));
|
1817
1817
|
}
|
1818
|
-
}),
|
1819
|
-
radio:
|
1820
|
-
checkbox:
|
1821
|
-
check:
|
1822
|
-
text:
|
1823
|
-
range:
|
1824
|
-
date:
|
1825
|
-
select:
|
1826
|
-
tag:
|
1827
|
-
"date:inline":
|
1818
|
+
}), Ke = {
|
1819
|
+
radio: kt,
|
1820
|
+
checkbox: Fe,
|
1821
|
+
check: Fe,
|
1822
|
+
text: Ft,
|
1823
|
+
range: Et,
|
1824
|
+
date: il,
|
1825
|
+
select: vl,
|
1826
|
+
tag: xl,
|
1827
|
+
"date:inline": Il
|
1828
1828
|
};
|
1829
1829
|
function Be(i, o) {
|
1830
1830
|
let d;
|
@@ -1839,11 +1839,11 @@ function Be(i, o) {
|
|
1839
1839
|
d = i == null ? void 0 : i.toString().toLowerCase();
|
1840
1840
|
}
|
1841
1841
|
return d === "date" && o && o === "inline" && (d = "date:inline"), {
|
1842
|
-
component:
|
1842
|
+
component: Ke[d] || Ke.text,
|
1843
1843
|
type: d
|
1844
1844
|
};
|
1845
1845
|
}
|
1846
|
-
const
|
1846
|
+
const Pl = {}, Tl = {
|
1847
1847
|
xmlns: "http://www.w3.org/2000/svg",
|
1848
1848
|
width: "15px",
|
1849
1849
|
height: "24",
|
@@ -1855,8 +1855,8 @@ const Il = {}, Pl = {
|
|
1855
1855
|
"stroke-linejoin": "round",
|
1856
1856
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-reload absolute inline mr-1 text-gray-800 transition-all cursor-pointer active:rotate-90 right-1 top-1 hover:text-blue-500"
|
1857
1857
|
};
|
1858
|
-
function
|
1859
|
-
return p(), k("svg",
|
1858
|
+
function Hl(i, o) {
|
1859
|
+
return p(), k("svg", Tl, o[0] || (o[0] = [
|
1860
1860
|
a("path", {
|
1861
1861
|
stroke: "none",
|
1862
1862
|
d: "M0 0h24v24H0z",
|
@@ -1866,7 +1866,7 @@ function Tl(i, o) {
|
|
1866
1866
|
a("path", { d: "M20 4v5h-5" }, null, -1)
|
1867
1867
|
]));
|
1868
1868
|
}
|
1869
|
-
const
|
1869
|
+
const El = /* @__PURE__ */ le(Pl, [["render", Hl]]), Yl = { style: { display: "inline-flex", margin: "0px", width: "100%" } }, Wl = { class: "relative w-full mb-2 p-4 bg-white rounded-lg shadow-sm" }, ql = { class: "block mb-3 text-sm font-medium text-gray-800 dark:text-neutral-200" }, Nl = { class: "flex items-center" }, Gl = { class: "text-sm font-medium max-w-[80%] text-gray-800 flex items-center gap-x-1" }, Ql = { class: "filter-layout__body" }, Zl = /* @__PURE__ */ Y({
|
1870
1870
|
__name: "vertical-layout",
|
1871
1871
|
props: {
|
1872
1872
|
id: {},
|
@@ -1906,12 +1906,12 @@ const Hl = /* @__PURE__ */ le(Il, [["render", Tl]]), El = { style: { display: "i
|
|
1906
1906
|
function m() {
|
1907
1907
|
s.value && s.value.clear(), t("clear", r.name);
|
1908
1908
|
}
|
1909
|
-
return
|
1909
|
+
return D(
|
1910
1910
|
() => r.default,
|
1911
1911
|
(f) => {
|
1912
1912
|
g.value = f;
|
1913
1913
|
}
|
1914
|
-
),
|
1914
|
+
), D(
|
1915
1915
|
() => r.modelValue,
|
1916
1916
|
(f) => {
|
1917
1917
|
g.value = f;
|
@@ -1920,18 +1920,18 @@ const Hl = /* @__PURE__ */ le(Il, [["render", Tl]]), El = { style: { display: "i
|
|
1920
1920
|
filterRef: s
|
1921
1921
|
}), (f, y) => {
|
1922
1922
|
var _, c, u;
|
1923
|
-
return p(), k("div",
|
1924
|
-
a("div",
|
1925
|
-
a("div",
|
1926
|
-
a("div",
|
1927
|
-
a("span",
|
1923
|
+
return p(), k("div", Yl, [
|
1924
|
+
a("div", Wl, [
|
1925
|
+
a("div", ql, [
|
1926
|
+
a("div", Nl, [
|
1927
|
+
a("span", Gl, L(f.label), 1)
|
1928
1928
|
]),
|
1929
|
-
typeof g.value == "string" && g.value.trim() !== "" || Array.isArray(g.value) && g.value.length > 0 && g.value.some((l) => l !== void 0) || g.value === null ? (p(), j(
|
1929
|
+
typeof g.value == "string" && g.value.trim() !== "" || Array.isArray(g.value) && g.value.length > 0 && g.value.some((l) => l !== void 0) || g.value === null ? (p(), j(El, {
|
1930
1930
|
key: 0,
|
1931
1931
|
onClick: m
|
1932
1932
|
})) : S("", !0)
|
1933
1933
|
]),
|
1934
|
-
a("div",
|
1934
|
+
a("div", Ql, [
|
1935
1935
|
((_ = e(v)) == null ? void 0 : _.type) !== "select" ? (p(), j(oe((c = e(v)) == null ? void 0 : c.component), Z({ key: 0 }, r, {
|
1936
1936
|
type: (u = e(v)) == null ? void 0 : u.type,
|
1937
1937
|
onChange: y[0] || (y[0] = (l) => w(l.name, l.value)),
|
@@ -1969,7 +1969,7 @@ const Hl = /* @__PURE__ */ le(Il, [["render", Tl]]), El = { style: { display: "i
|
|
1969
1969
|
]);
|
1970
1970
|
};
|
1971
1971
|
}
|
1972
|
-
}),
|
1972
|
+
}), Le = /* @__PURE__ */ Y({
|
1973
1973
|
__name: "inline-layout",
|
1974
1974
|
props: {
|
1975
1975
|
id: {},
|
@@ -2006,12 +2006,12 @@ const Hl = /* @__PURE__ */ le(Il, [["render", Tl]]), El = { style: { display: "i
|
|
2006
2006
|
function w(m, f) {
|
2007
2007
|
t("change", { name: m, value: f }), r.modelValue !== void 0 && t("update:modelValue", f);
|
2008
2008
|
}
|
2009
|
-
return
|
2009
|
+
return D(
|
2010
2010
|
() => r.default,
|
2011
2011
|
(m) => {
|
2012
2012
|
g.value = m;
|
2013
2013
|
}
|
2014
|
-
),
|
2014
|
+
), D(
|
2015
2015
|
() => r.modelValue,
|
2016
2016
|
(m) => {
|
2017
2017
|
g.value = m;
|
@@ -2057,7 +2057,7 @@ const Hl = /* @__PURE__ */ le(Il, [["render", Tl]]), El = { style: { display: "i
|
|
2057
2057
|
}, 8, ["current-value", "label", "mode", "fieldRef", "width", "disabled"]));
|
2058
2058
|
};
|
2059
2059
|
}
|
2060
|
-
}),
|
2060
|
+
}), Jl = /* @__PURE__ */ Y({
|
2061
2061
|
__name: "popover-layout",
|
2062
2062
|
props: {
|
2063
2063
|
id: {},
|
@@ -2094,17 +2094,17 @@ const Hl = /* @__PURE__ */ le(Il, [["render", Tl]]), El = { style: { display: "i
|
|
2094
2094
|
function w(m, f) {
|
2095
2095
|
t("change", { name: m, value: f }), r.modelValue !== void 0 && t("update:modelValue", f);
|
2096
2096
|
}
|
2097
|
-
return
|
2097
|
+
return D(
|
2098
2098
|
() => r.default,
|
2099
2099
|
(m) => {
|
2100
2100
|
g.value = m;
|
2101
2101
|
}
|
2102
|
-
),
|
2102
|
+
), D(
|
2103
2103
|
() => r.modelValue,
|
2104
2104
|
(m) => {
|
2105
2105
|
g.value = m;
|
2106
2106
|
}
|
2107
|
-
),
|
2107
|
+
), D(
|
2108
2108
|
() => r,
|
2109
2109
|
(m) => {
|
2110
2110
|
g.value = m;
|
@@ -2161,12 +2161,12 @@ const Hl = /* @__PURE__ */ le(Il, [["render", Tl]]), El = { style: { display: "i
|
|
2161
2161
|
function b(m, f) {
|
2162
2162
|
t("change", { name: m, value: f }), r.modelValue !== void 0 && t("update:modelValue", f);
|
2163
2163
|
}
|
2164
|
-
|
2164
|
+
D(
|
2165
2165
|
() => r.default,
|
2166
2166
|
(m) => {
|
2167
2167
|
v.value = m;
|
2168
2168
|
}
|
2169
|
-
),
|
2169
|
+
), D(
|
2170
2170
|
() => r.modelValue,
|
2171
2171
|
(m) => {
|
2172
2172
|
v.value = m;
|
@@ -2177,13 +2177,13 @@ const Hl = /* @__PURE__ */ le(Il, [["render", Tl]]), El = { style: { display: "i
|
|
2177
2177
|
function w() {
|
2178
2178
|
switch (r.layout) {
|
2179
2179
|
case "inline":
|
2180
|
-
return
|
2180
|
+
return Le;
|
2181
2181
|
case "vertical":
|
2182
|
-
return Ql;
|
2183
|
-
case "popover":
|
2184
2182
|
return Zl;
|
2183
|
+
case "popover":
|
2184
|
+
return Jl;
|
2185
2185
|
default:
|
2186
|
-
return
|
2186
|
+
return Le;
|
2187
2187
|
}
|
2188
2188
|
}
|
2189
2189
|
return (m, f) => (p(), j(oe(w()), Z(r, {
|
@@ -2199,11 +2199,11 @@ function $e(i, o) {
|
|
2199
2199
|
slots: d
|
2200
2200
|
} = i, r = V(i.value ?? {}), t = E(() => {
|
2201
2201
|
var h;
|
2202
|
-
return (
|
2202
|
+
return (ve((h = d == null ? void 0 : d.default) == null ? void 0 : h.call(d)) ?? []).flatMap((n) => Array.isArray(n.children) ? n.children : [n]);
|
2203
2203
|
});
|
2204
2204
|
function s(h) {
|
2205
2205
|
delete r.value[h], o("clear", {
|
2206
|
-
data:
|
2206
|
+
data: ve(r.value),
|
2207
2207
|
name: h
|
2208
2208
|
});
|
2209
2209
|
}
|
@@ -2212,7 +2212,7 @@ function $e(i, o) {
|
|
2212
2212
|
...r.value,
|
2213
2213
|
[h]: n
|
2214
2214
|
}, o("change", {
|
2215
|
-
data:
|
2215
|
+
data: ve(r.value),
|
2216
2216
|
name: h,
|
2217
2217
|
value: n
|
2218
2218
|
});
|
@@ -2220,7 +2220,7 @@ function $e(i, o) {
|
|
2220
2220
|
const g = E(() => t.value.map((h) => {
|
2221
2221
|
var C;
|
2222
2222
|
const n = (C = h.props) == null ? void 0 : C.name;
|
2223
|
-
return
|
2223
|
+
return Je(h, {
|
2224
2224
|
...h.props,
|
2225
2225
|
layout: i.view,
|
2226
2226
|
showClean: !0,
|
@@ -2241,7 +2241,7 @@ function $e(i, o) {
|
|
2241
2241
|
);
|
2242
2242
|
function w(h = !1) {
|
2243
2243
|
r.value = {}, h || o("clearAll", {
|
2244
|
-
data:
|
2244
|
+
data: ve(r.value),
|
2245
2245
|
name: "ALL"
|
2246
2246
|
});
|
2247
2247
|
}
|
@@ -2249,7 +2249,7 @@ function $e(i, o) {
|
|
2249
2249
|
var h;
|
2250
2250
|
return (h = i.schema) != null && h.value ? Object.entries(r.value).filter(([n, C]) => i.schema && !(n in i.schema.value) ? !1 : Array.isArray(C) ? C.some((M) => M !== "" && M !== void 0) : C !== "" && C !== void 0).length : 0;
|
2251
2251
|
}), y = V();
|
2252
|
-
|
2252
|
+
D(m, async () => {
|
2253
2253
|
var h, n;
|
2254
2254
|
await ke(), (n = (h = y == null ? void 0 : y.value) == null ? void 0 : h.filterRef) != null && n.inputTextRef && y.value.filterRef.inputTextRef.focus();
|
2255
2255
|
});
|
@@ -2292,7 +2292,7 @@ function $e(i, o) {
|
|
2292
2292
|
filterRef: y
|
2293
2293
|
};
|
2294
2294
|
}
|
2295
|
-
const
|
2295
|
+
const Xl = /* @__PURE__ */ Y({
|
2296
2296
|
__name: "popover",
|
2297
2297
|
emits: ["open", "close"],
|
2298
2298
|
setup(i, { emit: o }) {
|
@@ -2327,14 +2327,14 @@ const Jl = /* @__PURE__ */ Y({
|
|
2327
2327
|
(y = s.value) == null || y.removeEventListener("click", g), document.removeEventListener("click", w), window.removeEventListener("resize", b), window.removeEventListener("scroll", b, !0);
|
2328
2328
|
});
|
2329
2329
|
const f = o;
|
2330
|
-
return
|
2330
|
+
return D(d, async (y) => {
|
2331
2331
|
y ? (f("open"), await ke(), b()) : f("close");
|
2332
2332
|
}), (y, _) => (p(), k("div", {
|
2333
2333
|
ref_key: "wrapperRef",
|
2334
2334
|
ref: t
|
2335
2335
|
}, [
|
2336
2336
|
ee(y.$slots, "trigger"),
|
2337
|
-
m.value ? (p(), j(
|
2337
|
+
m.value ? (p(), j(Ie, {
|
2338
2338
|
key: 0,
|
2339
2339
|
to: "body"
|
2340
2340
|
}, [
|
@@ -2351,7 +2351,7 @@ const Jl = /* @__PURE__ */ Y({
|
|
2351
2351
|
])) : S("", !0)
|
2352
2352
|
], 512));
|
2353
2353
|
}
|
2354
|
-
}),
|
2354
|
+
}), ea = {}, ta = {
|
2355
2355
|
xmlns: "http://www.w3.org/2000/svg",
|
2356
2356
|
width: "24",
|
2357
2357
|
height: "24",
|
@@ -2363,27 +2363,27 @@ const Jl = /* @__PURE__ */ Y({
|
|
2363
2363
|
"stroke-linejoin": "round",
|
2364
2364
|
class: "lucide lucide-filter h-4 w-4"
|
2365
2365
|
};
|
2366
|
-
function
|
2367
|
-
return p(), k("svg",
|
2366
|
+
function la(i, o) {
|
2367
|
+
return p(), k("svg", ta, o[0] || (o[0] = [
|
2368
2368
|
a("polygon", { points: "22 3 2 3 10 12.46 10 19 14 21 14 12.46 22 3" }, null, -1)
|
2369
2369
|
]));
|
2370
2370
|
}
|
2371
|
-
const
|
2371
|
+
const aa = /* @__PURE__ */ le(ea, [["render", la]]), oa = {
|
2372
2372
|
key: 0,
|
2373
2373
|
class: "inline-flex rounded-sm items-center border font-semibold border-transparent hover:bg-secondary/80 bg-blue-500 text-white text-xs px-1.5"
|
2374
|
-
},
|
2374
|
+
}, ra = { class: "flex" }, na = { class: "w-64 border-r border-gray-200" }, ia = { class: "p-2" }, sa = ["onClick"], ua = { class: "flex items-center gap-2" }, da = { class: "text-sm font-medium" }, ca = {
|
2375
2375
|
key: 0,
|
2376
2376
|
class: "inline-flex items-center rounded-full border font-semibold transition-colors focus:outline-hidden focus:ring-2 focus:ring-ring focus:ring-offset-2 border-transparent hover:bg-secondary/80 bg-blue-100 text-blue-700 text-xs p-2"
|
2377
|
-
},
|
2377
|
+
}, pa = ["onClick"], fa = { class: "flex items-center gap-2" }, va = { class: "text-sm font-medium" }, ma = {
|
2378
2378
|
key: 0,
|
2379
2379
|
class: "inline-flex items-center rounded-full border font-semibold transition-colors focus:outline-hidden focus:ring-2 focus:ring-ring focus:ring-offset-2 border-transparent hover:bg-secondary/80 bg-blue-100 text-blue-700 text-xs p-2"
|
2380
|
-
},
|
2380
|
+
}, ga = {
|
2381
2381
|
key: 0,
|
2382
2382
|
class: "p-2 border-t"
|
2383
|
-
},
|
2383
|
+
}, ha = { class: "flex-1 min-h-[300px] overflow-y-auto" }, ba = {
|
2384
2384
|
key: 0,
|
2385
2385
|
class: "flex items-center justify-center h-full text-gray-500"
|
2386
|
-
},
|
2386
|
+
}, Qe = /* @__PURE__ */ Y({
|
2387
2387
|
__name: "popover-filter-layout",
|
2388
2388
|
props: {
|
2389
2389
|
schema: {},
|
@@ -2395,7 +2395,7 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2395
2395
|
},
|
2396
2396
|
emits: ["change", "clear", "clearAll"],
|
2397
2397
|
setup(i, { expose: o, emit: d }) {
|
2398
|
-
const r = i, t =
|
2398
|
+
const r = i, t = Ne(r.mode), s = we(), v = d, g = V({}), {
|
2399
2399
|
activeFilter: b,
|
2400
2400
|
activeFilterCount: w,
|
2401
2401
|
onFilterChange: m,
|
@@ -2411,7 +2411,7 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2411
2411
|
schema: g,
|
2412
2412
|
slots: s
|
2413
2413
|
}, v);
|
2414
|
-
return
|
2414
|
+
return D(
|
2415
2415
|
() => r.schema,
|
2416
2416
|
(h) => {
|
2417
2417
|
g.value = h;
|
@@ -2420,7 +2420,7 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2420
2420
|
), o({
|
2421
2421
|
clearFilter: f,
|
2422
2422
|
clearAllFilters: y
|
2423
|
-
}), (h, n) => (p(), j(
|
2423
|
+
}), (h, n) => (p(), j(Xl, {
|
2424
2424
|
onOpen: e(u),
|
2425
2425
|
onClose: n[5] || (n[5] = (C) => l.value = "")
|
2426
2426
|
}, {
|
@@ -2434,18 +2434,18 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2434
2434
|
),
|
2435
2435
|
type: "button"
|
2436
2436
|
}, [
|
2437
|
-
I(
|
2437
|
+
I(aa),
|
2438
2438
|
n[6] || (n[6] = W(" Фільтр ", -1)),
|
2439
|
-
e(w) > 0 ? (p(), k("div",
|
2439
|
+
e(w) > 0 ? (p(), k("div", oa, L(e(w)), 1)) : S("", !0)
|
2440
2440
|
], 2)
|
2441
2441
|
]),
|
2442
2442
|
default: re(() => [
|
2443
|
-
a("div",
|
2444
|
-
a("div",
|
2443
|
+
a("div", ra, [
|
2444
|
+
a("div", na, [
|
2445
2445
|
n[7] || (n[7] = a("div", { class: "p-4 border-b" }, [
|
2446
2446
|
a("p", { class: "text-sm text-gray-600" }, "Select a field to start creating a filter.")
|
2447
2447
|
], -1)),
|
2448
|
-
a("div",
|
2448
|
+
a("div", ia, [
|
2449
2449
|
h.schema ? (p(!0), k(K, { key: 0 }, q(Object.entries(e(_)), ([C, M]) => {
|
2450
2450
|
var $;
|
2451
2451
|
return p(), k("button", {
|
@@ -2458,11 +2458,11 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2458
2458
|
e(l) === C ? "bg-blue-50 text-blue-700 border-l-2 border-blue-500" : ""
|
2459
2459
|
])
|
2460
2460
|
}, [
|
2461
|
-
a("div",
|
2462
|
-
a("span",
|
2461
|
+
a("div", ua, [
|
2462
|
+
a("span", da, L(M.label), 1)
|
2463
2463
|
]),
|
2464
|
-
(Array.isArray(e(b)[C]) ? (($ = e(b)[C]) == null ? void 0 : $.length) > 0 : e(b)[C] || e(b)[C] === null) ? (p(), k("div",
|
2465
|
-
], 10,
|
2464
|
+
(Array.isArray(e(b)[C]) ? (($ = e(b)[C]) == null ? void 0 : $.length) > 0 : e(b)[C] || e(b)[C] === null) ? (p(), k("div", ca)) : S("", !0)
|
2465
|
+
], 10, sa);
|
2466
2466
|
}), 128)) : S("", !0),
|
2467
2467
|
(p(!0), k(K, null, q(e(c), (C, M) => {
|
2468
2468
|
var $;
|
@@ -2474,14 +2474,14 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2474
2474
|
e(l) === C.props.name ? "bg-blue-50 text-blue-700 border-l-2 border-blue-500" : ""
|
2475
2475
|
])
|
2476
2476
|
}, [
|
2477
|
-
a("div",
|
2478
|
-
a("span",
|
2477
|
+
a("div", fa, [
|
2478
|
+
a("span", va, L(C.props.label), 1)
|
2479
2479
|
]),
|
2480
|
-
(($ = e(b)[C.props.name]) == null ? void 0 : $.length) > 0 ? (p(), k("div",
|
2481
|
-
], 10,
|
2480
|
+
(($ = e(b)[C.props.name]) == null ? void 0 : $.length) > 0 ? (p(), k("div", ma)) : S("", !0)
|
2481
|
+
], 10, pa);
|
2482
2482
|
}), 128))
|
2483
2483
|
]),
|
2484
|
-
e(w) > 0 ? (p(), k("div",
|
2484
|
+
e(w) > 0 ? (p(), k("div", ga, [
|
2485
2485
|
a("button", {
|
2486
2486
|
class: "w-full px-3 py-2 text-left text-sm text-gray-600 hover:bg-gray-50 transition-colors",
|
2487
2487
|
onClick: n[0] || (n[0] = (C) => e(y)()),
|
@@ -2489,8 +2489,8 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2489
2489
|
}, " Очистити всі ")
|
2490
2490
|
])) : S("", !0)
|
2491
2491
|
]),
|
2492
|
-
a("div",
|
2493
|
-
e(l) === "" ? (p(), k("div",
|
2492
|
+
a("div", ha, [
|
2493
|
+
e(l) === "" ? (p(), k("div", ba, n[8] || (n[8] = [
|
2494
2494
|
a("p", { class: "text-sm" }, "Select a field to start creating a filter.", -1)
|
2495
2495
|
]))) : S("", !0),
|
2496
2496
|
e(l) ? (p(), k(K, { key: 1 }, [
|
@@ -2538,7 +2538,7 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2538
2538
|
_: 1
|
2539
2539
|
}, 8, ["onOpen"]));
|
2540
2540
|
}
|
2541
|
-
}),
|
2541
|
+
}), ya = { class: "flex gap-1 items-center flex-wrap" }, Ue = /* @__PURE__ */ Y({
|
2542
2542
|
__name: "inline-filter-layout",
|
2543
2543
|
props: {
|
2544
2544
|
schema: {},
|
@@ -2572,7 +2572,7 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2572
2572
|
function h() {
|
2573
2573
|
x.value && x.value.clearAllFilters(!0), f();
|
2574
2574
|
}
|
2575
|
-
return
|
2575
|
+
return D(
|
2576
2576
|
() => r.schema,
|
2577
2577
|
(n) => {
|
2578
2578
|
v.value = n;
|
@@ -2581,7 +2581,7 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2581
2581
|
), o({
|
2582
2582
|
clearFilter: m,
|
2583
2583
|
clearAllFilters: f
|
2584
|
-
}), (n, C) => (p(), k("div",
|
2584
|
+
}), (n, C) => (p(), k("div", ya, [
|
2585
2585
|
n.schema ? (p(!0), k(K, { key: 0 }, q(Object.entries(e(y)), ([M, $]) => (p(), j(ne, Z({
|
2586
2586
|
key: M,
|
2587
2587
|
name: M,
|
@@ -2606,7 +2606,7 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2606
2606
|
modelValue: e(g)[M.props.name],
|
2607
2607
|
"onUpdate:modelValue": (A) => e(g)[M.props.name] = A
|
2608
2608
|
}), null, 16, ["modelValue", "onUpdate:modelValue"]))), 128)),
|
2609
|
-
Object.entries(e(_)).length > 0 || e(l).length > 0 ? (p(), j(
|
2609
|
+
Object.entries(e(_)).length > 0 || e(l).length > 0 ? (p(), j(Qe, Z({ key: 1 }, r, {
|
2610
2610
|
schema: e(_),
|
2611
2611
|
limit: 0,
|
2612
2612
|
onChange: C[3] || (C[3] = (M) => e(w)(M.name, M.value)),
|
@@ -2632,10 +2632,10 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2632
2632
|
}, " Очистити ")) : S("", !0)
|
2633
2633
|
]));
|
2634
2634
|
}
|
2635
|
-
}),
|
2635
|
+
}), xa = {
|
2636
2636
|
key: 0,
|
2637
2637
|
class: "p-2 overflow-y-auto overflow-hidden [&::-webkit-scrollbar]:w-2 [&::-webkit-scrollbar-thumb]:rounded-full [&::-webkit-scrollbar-track]:bg-gray-100 [&::-webkit-scrollbar-thumb]:bg-gray-300 dark:[&::-webkit-scrollbar-track]:bg-neutral-700 dark:[&::-webkit-scrollbar-thumb]:bg-neutral-500 dark:bg-neutral-800 max-h-[calc(100%-142px)] h-full bg-gray-100"
|
2638
|
-
},
|
2638
|
+
}, wa = { class: "flex items-center vst-filters vsTailwind flex-col w-full" }, ka = /* @__PURE__ */ Y({
|
2639
2639
|
__name: "vertical-filter-layout",
|
2640
2640
|
props: {
|
2641
2641
|
schema: {},
|
@@ -2661,8 +2661,8 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2661
2661
|
return o({
|
2662
2662
|
clearFilter: w,
|
2663
2663
|
clearAllFilters: m
|
2664
|
-
}), (y, _) => y.view === "vertical" ? (p(), k("div",
|
2665
|
-
a("div",
|
2664
|
+
}), (y, _) => y.view === "vertical" ? (p(), k("div", xa, [
|
2665
|
+
a("div", wa, [
|
2666
2666
|
e(g) > 0 ? (p(), k("button", {
|
2667
2667
|
key: 0,
|
2668
2668
|
onClick: _[0] || (_[0] = (c) => e(m)()),
|
@@ -2716,7 +2716,7 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2716
2716
|
if (Array.isArray(u))
|
2717
2717
|
return u.map((l) => g(l));
|
2718
2718
|
if (u !== null && typeof u == "object") {
|
2719
|
-
const l =
|
2719
|
+
const l = ve(u), x = {};
|
2720
2720
|
for (const h in l)
|
2721
2721
|
x[h] = g(l[h]);
|
2722
2722
|
return x;
|
@@ -2757,16 +2757,16 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2757
2757
|
function y() {
|
2758
2758
|
switch (r.view) {
|
2759
2759
|
case "inline":
|
2760
|
-
return
|
2760
|
+
return Ue;
|
2761
2761
|
case "vertical":
|
2762
|
-
return
|
2762
|
+
return ka;
|
2763
2763
|
case "popover":
|
2764
|
-
return
|
2764
|
+
return Qe;
|
2765
2765
|
default:
|
2766
|
-
return
|
2766
|
+
return Ue;
|
2767
2767
|
}
|
2768
2768
|
}
|
2769
|
-
|
2769
|
+
D(
|
2770
2770
|
() => r.schema,
|
2771
2771
|
(u) => {
|
2772
2772
|
if (!u) {
|
@@ -2810,16 +2810,16 @@ const la = /* @__PURE__ */ le(Xl, [["render", ta]]), aa = {
|
|
2810
2810
|
xe.install = function(i) {
|
2811
2811
|
i.component("Filter", xe), i.component("FilterField", ne);
|
2812
2812
|
};
|
2813
|
-
function
|
2813
|
+
function Ca(i) {
|
2814
2814
|
const { page: o, id: d, filter: r } = i, t = new URL(window.location.href), s = new URLSearchParams(window.location.search);
|
2815
2815
|
o ? s.set("page", o.toString()) : s.delete("page"), d ? s.set("id", d.toString()) : s.delete("id"), r ? s.set("filter", r) : s.delete("filter"), t.search = decodeURI(s.toString()), window.history.pushState({}, "", t);
|
2816
2816
|
}
|
2817
|
-
const
|
2817
|
+
const _a = { class: "flex items-center justify-between w-full gap-x-1" }, Va = { class: "flex items-center" }, Sa = ["disabled"], Ma = { class: "flex items-center gap-x-1" }, Ba = ["onClick"], $a = ["disabled"], Aa = { class: "flex justify-center items-center gap-x-5 ml-3" }, Ra = { class: "relative" }, Da = {
|
2818
2818
|
class: "hs-dropdown-menu z-50 bg-white shadow-md rounded-lg p-1 space-y-0.5 dark:bg-neutral-800 dark:border dark:border-neutral-700 right-0 dark:divide-neutral-700 absolute bottom-[100%]",
|
2819
2819
|
role: "menu",
|
2820
2820
|
"aria-orientation": "vertical",
|
2821
2821
|
"aria-labelledby": "dropdown-button"
|
2822
|
-
},
|
2822
|
+
}, za = ["onClick"], ja = {
|
2823
2823
|
key: 0,
|
2824
2824
|
xmlns: "http://www.w3.org/2000/svg",
|
2825
2825
|
viewBox: "0 0 24 24",
|
@@ -2831,7 +2831,7 @@ const Ca = { class: "flex items-center justify-between w-full gap-x-1" }, _a = {
|
|
2831
2831
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-check text-blue-600",
|
2832
2832
|
width: "14",
|
2833
2833
|
height: "14"
|
2834
|
-
},
|
2834
|
+
}, Fa = /* @__PURE__ */ Y({
|
2835
2835
|
__name: "pagination",
|
2836
2836
|
props: {
|
2837
2837
|
total: {},
|
@@ -2841,7 +2841,7 @@ const Ca = { class: "flex items-center justify-between w-full gap-x-1" }, _a = {
|
|
2841
2841
|
emits: ["update:currentPage", "update:pageSize", "pageChange", "pageSizeChange"],
|
2842
2842
|
setup(i, { emit: o }) {
|
2843
2843
|
const d = i, r = o, t = V(d.currentPage), s = V(d.pageSize), v = V(!1);
|
2844
|
-
|
2844
|
+
D(() => d.pageSize, (_) => {
|
2845
2845
|
s.value = _;
|
2846
2846
|
});
|
2847
2847
|
const g = E(() => Math.ceil(d.total / d.pageSize)), b = E(() => {
|
@@ -2861,8 +2861,8 @@ const Ca = { class: "flex items-center justify-between w-full gap-x-1" }, _a = {
|
|
2861
2861
|
}, y = (_ = s.value) => {
|
2862
2862
|
s.value = _, v.value = !1, r("update:pageSize", s.value), r("update:currentPage", 1), r("pageSizeChange", s.value);
|
2863
2863
|
};
|
2864
|
-
return (_, c) => (p(), k("nav",
|
2865
|
-
a("div",
|
2864
|
+
return (_, c) => (p(), k("nav", _a, [
|
2865
|
+
a("div", Va, [
|
2866
2866
|
a("button", {
|
2867
2867
|
type: "button",
|
2868
2868
|
"aria-label": "Previous",
|
@@ -2893,14 +2893,14 @@ const Ca = { class: "flex items-center justify-between w-full gap-x-1" }, _a = {
|
|
2893
2893
|
"aria-hidden": "true",
|
2894
2894
|
class: "sr-only"
|
2895
2895
|
}, "Previous", -1)
|
2896
|
-
]), 8,
|
2897
|
-
a("div",
|
2896
|
+
]), 8, Sa),
|
2897
|
+
a("div", Ma, [
|
2898
2898
|
(p(!0), k(K, null, q(b.value, (u) => (p(), k("button", {
|
2899
2899
|
type: "button",
|
2900
2900
|
key: u,
|
2901
2901
|
onClick: (l) => f(u),
|
2902
2902
|
class: F(t.value === u ? "flex justify-center items-center rounded-lg text-sm dark:text-neutral-300 py-2 px-3 focus:outline-none disabled:opacity-50 disabled:pointer-events-none bg-[#e5e7eb] dark:bg-[#242424] border border-gray-200 text-base h-[38px] min-w-[38px]" : "flex justify-center items-center rounded-lg text-sm dark:text-neutral-400 hover:bg-gray-100 py-2 px-3 focus:outline-none focus:bg-gray-100 disabled:opacity-50 disabled:pointer-events-none dark:hover:bg-neutral-800 dark:focus:bg-neutral-800 text-base h-[38px] min-w-[38px]")
|
2903
|
-
}, L(u), 11,
|
2903
|
+
}, L(u), 11, Ba))), 128))
|
2904
2904
|
]),
|
2905
2905
|
a("button", {
|
2906
2906
|
type: "button",
|
@@ -2932,11 +2932,11 @@ const Ca = { class: "flex items-center justify-between w-full gap-x-1" }, _a = {
|
|
2932
2932
|
}),
|
2933
2933
|
a("path", { d: "M6 9l6 6l6 -6" })
|
2934
2934
|
], -1)
|
2935
|
-
]), 8,
|
2935
|
+
]), 8, $a)
|
2936
2936
|
]),
|
2937
|
-
a("div",
|
2938
|
-
a("div",
|
2939
|
-
P(a("div",
|
2937
|
+
a("div", Aa, [
|
2938
|
+
a("div", Ra, [
|
2939
|
+
P(a("div", Da, [
|
2940
2940
|
(p(), k(K, null, q([10, 20, 30], (u) => a("button", {
|
2941
2941
|
type: "button",
|
2942
2942
|
key: u,
|
@@ -2944,7 +2944,7 @@ const Ca = { class: "flex items-center justify-between w-full gap-x-1" }, _a = {
|
|
2944
2944
|
class: "w-full flex items-center gap-x-3.5 py-2 px-3 rounded-lg text-sm text-gray-800 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-neutral-300 dark:focus:bg-neutral-700"
|
2945
2945
|
}, [
|
2946
2946
|
W(L(u) + " ", 1),
|
2947
|
-
s.value === u ? (p(), k("svg",
|
2947
|
+
s.value === u ? (p(), k("svg", ja, c[3] || (c[3] = [
|
2948
2948
|
a("path", {
|
2949
2949
|
stroke: "none",
|
2950
2950
|
d: "M0 0h24v24H0z",
|
@@ -2952,7 +2952,7 @@ const Ca = { class: "flex items-center justify-between w-full gap-x-1" }, _a = {
|
|
2952
2952
|
}, null, -1),
|
2953
2953
|
a("path", { d: "M5 12l5 5l10 -10" }, null, -1)
|
2954
2954
|
]))) : S("", !0)
|
2955
|
-
], 8,
|
2955
|
+
], 8, za)), 64))
|
2956
2956
|
], 512), [
|
2957
2957
|
[X, v.value]
|
2958
2958
|
]),
|
@@ -2989,12 +2989,12 @@ const Ca = { class: "flex items-center justify-between w-full gap-x-1" }, _a = {
|
|
2989
2989
|
])
|
2990
2990
|
]));
|
2991
2991
|
}
|
2992
|
-
}),
|
2992
|
+
}), me = (i, o) => {
|
2993
2993
|
const d = i.__vccOpts || i;
|
2994
2994
|
for (const [r, t] of o)
|
2995
2995
|
d[r] = t;
|
2996
2996
|
return d;
|
2997
|
-
},
|
2997
|
+
}, Ka = {}, La = {
|
2998
2998
|
class: "w-48 mx-auto mb-4",
|
2999
2999
|
width: "178",
|
3000
3000
|
height: "90",
|
@@ -3002,12 +3002,12 @@ const Ca = { class: "flex items-center justify-between w-full gap-x-1" }, _a = {
|
|
3002
3002
|
fill: "none",
|
3003
3003
|
xmlns: "http://www.w3.org/2000/svg"
|
3004
3004
|
};
|
3005
|
-
function
|
3006
|
-
return p(), k("svg",
|
3007
|
-
|
3005
|
+
function Ua(i, o) {
|
3006
|
+
return p(), k("svg", La, o[0] || (o[0] = [
|
3007
|
+
Te('<rect x="27" y="50.5" width="124" height="39" rx="7.5" fill="currentColor" class="fill-white dark:fill-neutral-800"></rect><rect x="27" y="50.5" width="124" height="39" rx="7.5" stroke="currentColor" class="stroke-stone-50 dark:stroke-neutral-700/10"></rect><rect x="34.5" y="58" width="24" height="24" rx="4" fill="currentColor" class="fill-stone-50 dark:fill-neutral-700/30"></rect><rect x="66.5" y="61" width="60" height="6" rx="3" fill="currentColor" class="fill-stone-50 dark:fill-neutral-700/30"></rect><rect x="66.5" y="73" width="77" height="6" rx="3" fill="currentColor" class="fill-stone-50 dark:fill-neutral-700/30"></rect><rect x="19.5" y="28.5" width="139" height="39" rx="7.5" fill="currentColor" class="fill-white dark:fill-neutral-800"></rect><rect x="19.5" y="28.5" width="139" height="39" rx="7.5" stroke="currentColor" class="stroke-stone-100 dark:stroke-neutral-700/30"></rect><rect x="27" y="36" width="24" height="24" rx="4" fill="currentColor" class="fill-stone-100 dark:fill-neutral-700/70"></rect><rect x="59" y="39" width="60" height="6" rx="3" fill="currentColor" class="fill-stone-100 dark:fill-neutral-700/70"></rect><rect x="59" y="51" width="92" height="6" rx="3" fill="currentColor" class="fill-stone-100 dark:fill-neutral-700/70"></rect><g filter="url(#filter2)"><rect x="12" y="6" width="154" height="40" rx="8" fill="currentColor" class="fill-white dark:fill-neutral-800" shape-rendering="crispEdges"></rect><rect x="12.5" y="6.5" width="153" height="39" rx="7.5" stroke="currentColor" class="stroke-stone-100 dark:stroke-neutral-700/60" shape-rendering="crispEdges"></rect><rect x="20" y="14" width="24" height="24" rx="4" fill="currentColor" class="fill-stone-200 dark:fill-neutral-700"></rect><rect x="52" y="17" width="60" height="6" rx="3" fill="currentColor" class="fill-stone-200 dark:fill-neutral-700"></rect><rect x="52" y="29" width="106" height="6" rx="3" fill="currentColor" class="fill-stone-200 dark:fill-neutral-700"></rect></g><defs><filter id="filter2" x="0" y="0" width="178" height="64" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"></feColorMatrix><feOffset dy="6"></feOffset><feGaussianBlur stdDeviation="6"></feGaussianBlur><feComposite in2="hardAlpha" operator="out"></feComposite><feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.03 0"></feColorMatrix><feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_1187_14810"></feBlend><feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_1187_14810" result="shape"></feBlend></filter></defs>', 12)
|
3008
3008
|
]));
|
3009
3009
|
}
|
3010
|
-
const
|
3010
|
+
const Oa = /* @__PURE__ */ me(Ka, [["render", Ua]]), Ia = {}, Pa = {
|
3011
3011
|
xmlns: "http://www.w3.org/2000/svg",
|
3012
3012
|
width: "21",
|
3013
3013
|
height: "20",
|
@@ -3019,8 +3019,8 @@ const Ua = /* @__PURE__ */ ve(Fa, [["render", La]]), Oa = {}, Ia = {
|
|
3019
3019
|
"stroke-linejoin": "round",
|
3020
3020
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-layout-sidebar-right-collapse"
|
3021
3021
|
};
|
3022
|
-
function
|
3023
|
-
return p(), k("svg",
|
3022
|
+
function Ta(i, o) {
|
3023
|
+
return p(), k("svg", Pa, o[0] || (o[0] = [
|
3024
3024
|
a("path", {
|
3025
3025
|
stroke: "none",
|
3026
3026
|
d: "M0 0h24v24H0z",
|
@@ -3031,7 +3031,7 @@ function Pa(i, o) {
|
|
3031
3031
|
a("path", { d: "M9 10l2 2l-2 2" }, null, -1)
|
3032
3032
|
]));
|
3033
3033
|
}
|
3034
|
-
const
|
3034
|
+
const Ha = /* @__PURE__ */ me(Ia, [["render", Ta]]), Ea = {}, Ya = {
|
3035
3035
|
xmlns: "http://www.w3.org/2000/svg",
|
3036
3036
|
width: "21",
|
3037
3037
|
height: "20",
|
@@ -3043,8 +3043,8 @@ const Ta = /* @__PURE__ */ ve(Oa, [["render", Pa]]), Ha = {}, Ea = {
|
|
3043
3043
|
"stroke-linejoin": "round",
|
3044
3044
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-layout-sidebar-right-expand"
|
3045
3045
|
};
|
3046
|
-
function
|
3047
|
-
return p(), k("svg",
|
3046
|
+
function Wa(i, o) {
|
3047
|
+
return p(), k("svg", Ya, o[0] || (o[0] = [
|
3048
3048
|
a("path", {
|
3049
3049
|
stroke: "none",
|
3050
3050
|
d: "M0 0h24v24H0z",
|
@@ -3055,7 +3055,7 @@ function Ya(i, o) {
|
|
3055
3055
|
a("path", { d: "M10 10l-2 2l2 2" }, null, -1)
|
3056
3056
|
]));
|
3057
3057
|
}
|
3058
|
-
const
|
3058
|
+
const qa = /* @__PURE__ */ me(Ea, [["render", Wa]]), Na = {}, Ga = {
|
3059
3059
|
xmlns: "http://www.w3.org/2000/svg",
|
3060
3060
|
width: "24",
|
3061
3061
|
height: "24",
|
@@ -3067,8 +3067,8 @@ const Wa = /* @__PURE__ */ ve(Ha, [["render", Ya]]), qa = {}, Na = {
|
|
3067
3067
|
"stroke-linejoin": "round",
|
3068
3068
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-map"
|
3069
3069
|
};
|
3070
|
-
function
|
3071
|
-
return p(), k("svg",
|
3070
|
+
function Qa(i, o) {
|
3071
|
+
return p(), k("svg", Ga, o[0] || (o[0] = [
|
3072
3072
|
a("path", {
|
3073
3073
|
stroke: "none",
|
3074
3074
|
d: "M0 0h24v24H0z",
|
@@ -3079,7 +3079,7 @@ function Ga(i, o) {
|
|
3079
3079
|
a("path", { d: "M15 7v13" }, null, -1)
|
3080
3080
|
]));
|
3081
3081
|
}
|
3082
|
-
const
|
3082
|
+
const Za = /* @__PURE__ */ me(Na, [["render", Qa]]), Ja = {}, Xa = {
|
3083
3083
|
xmlns: "http://www.w3.org/2000/svg",
|
3084
3084
|
width: "24",
|
3085
3085
|
height: "24",
|
@@ -3091,8 +3091,8 @@ const Qa = /* @__PURE__ */ ve(qa, [["render", Ga]]), Za = {}, Ja = {
|
|
3091
3091
|
"stroke-linejoin": "round",
|
3092
3092
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-table"
|
3093
3093
|
};
|
3094
|
-
function
|
3095
|
-
return p(), k("svg",
|
3094
|
+
function eo(i, o) {
|
3095
|
+
return p(), k("svg", Xa, o[0] || (o[0] = [
|
3096
3096
|
a("path", {
|
3097
3097
|
stroke: "none",
|
3098
3098
|
d: "M0 0h24v24H0z",
|
@@ -3103,14 +3103,14 @@ function Xa(i, o) {
|
|
3103
3103
|
a("path", { d: "M10 3v18" }, null, -1)
|
3104
3104
|
]));
|
3105
3105
|
}
|
3106
|
-
const
|
3107
|
-
function
|
3106
|
+
const to = /* @__PURE__ */ me(Ja, [["render", eo]]);
|
3107
|
+
function lo(i, o) {
|
3108
3108
|
let d;
|
3109
3109
|
return function(...r) {
|
3110
3110
|
clearTimeout(d), d = setTimeout(() => i(...r), o);
|
3111
3111
|
};
|
3112
3112
|
}
|
3113
|
-
function
|
3113
|
+
function ao(i, o, d) {
|
3114
3114
|
o && (o.addSource("vector", {
|
3115
3115
|
type: "vector",
|
3116
3116
|
tiles: [
|
@@ -3169,10 +3169,10 @@ const ge = [
|
|
3169
3169
|
url: "https://mt1.google.com/vt/lyrs=s&x={x}&y={y}&z={z}",
|
3170
3170
|
preview: "https://mt1.google.com/vt/lyrs=s&x=2422&y=1400&z=12"
|
3171
3171
|
}
|
3172
|
-
],
|
3172
|
+
], oo = { class: "relative w-auto h-full" }, ro = { class: "absolute left-[20px] bottom-[74px] bg-white max-w-[250px] p-[10px] rounded-lg z-10 border" }, no = { class: "flex justify-start items-center gap-2" }, io = { class: "ml-1 text-[0.875rem]" }, so = {
|
3173
3173
|
class: "vs-map-slot-layers z-10 select-none",
|
3174
3174
|
style: { display: "flex" }
|
3175
|
-
},
|
3175
|
+
}, uo = ["title", "onClick"], co = ["src"], po = { class: "absolute py-2 px-4 text-sm text-stone-800 bg-white shadow-[0_10px_40px_10px_rgba(0,0,0,0.08)] rounded-lg top-[-46px] hidden whitespace-nowrap left-1/2 -translate-x-1/2" }, fo = /* @__PURE__ */ Y({
|
3176
3176
|
__name: "map",
|
3177
3177
|
props: {
|
3178
3178
|
table: {},
|
@@ -3243,7 +3243,7 @@ const ge = [
|
|
3243
3243
|
}), t.on("load", () => {
|
3244
3244
|
t == null || t.resize(), g.value = !0;
|
3245
3245
|
const l = _.filter((h) => h.id).reduce((h, n) => [n.id, n.color].concat(h), []), x = ["match", ["get", d.colorAttr], ...l, "#808080"];
|
3246
|
-
|
3246
|
+
ao(d.table, t, x);
|
3247
3247
|
}), t.on("click", (l) => {
|
3248
3248
|
const x = t.queryRenderedFeatures(l.point);
|
3249
3249
|
x.length && r("update:modelValue", x[0].properties.id);
|
@@ -3258,14 +3258,14 @@ const ge = [
|
|
3258
3258
|
const h = x[0], { coordinates: n } = h.geometry, C = h.geometry.type === "Point" ? n : n[0][0];
|
3259
3259
|
f.value = h.properties, s.setLngLat(C).setHTML((M = m.value) == null ? void 0 : M.innerHTML).addTo(t);
|
3260
3260
|
});
|
3261
|
-
}),
|
3261
|
+
}), D(() => d.center, (u) => {
|
3262
3262
|
t && t.setCenter(u || c);
|
3263
|
-
}),
|
3263
|
+
}), D(() => d.zoom, (u) => {
|
3264
3264
|
t && t.setZoom(u);
|
3265
|
-
}),
|
3265
|
+
}), D(() => d.filter, (u) => {
|
3266
3266
|
const l = `http://${window.location.host}/api/vtile/${d.table}/ua/{z}/{x}/{y}.vmt?pointZoom=12&filter=${u}`;
|
3267
3267
|
t.getSource("vector").setTiles([l]);
|
3268
|
-
}),
|
3268
|
+
}), D(b, (u, l) => {
|
3269
3269
|
const x = ge.find((h) => h.name === u);
|
3270
3270
|
x && (t.removeLayer(l), t.removeSource(l), t.addSource(u, { type: "raster", tiles: [x.url], tileSize: 256 }), t.addLayer({
|
3271
3271
|
id: x.name,
|
@@ -3277,24 +3277,24 @@ const ge = [
|
|
3277
3277
|
}), he(() => {
|
3278
3278
|
t && t.remove();
|
3279
3279
|
}), (u, l) => {
|
3280
|
-
const x =
|
3281
|
-
return P((p(), k("div",
|
3280
|
+
const x = et("tooltip");
|
3281
|
+
return P((p(), k("div", oo, [
|
3282
3282
|
a("div", {
|
3283
3283
|
ref_key: "mapContainer",
|
3284
3284
|
ref: v,
|
3285
3285
|
class: "map-container w-auto relative"
|
3286
3286
|
}, null, 512),
|
3287
|
-
a("div",
|
3287
|
+
a("div", ro, [
|
3288
3288
|
(p(!0), k(K, null, q(e(_), (h) => (p(), k("div", {
|
3289
3289
|
class: "legend-item",
|
3290
3290
|
key: h.id
|
3291
3291
|
}, [
|
3292
|
-
a("div",
|
3292
|
+
a("div", no, [
|
3293
3293
|
a("div", {
|
3294
3294
|
class: "w-[15px] h-[15px] rounded-[50%] min-w-[15px]",
|
3295
3295
|
style: Ce("background-color:" + h.color)
|
3296
3296
|
}, null, 4),
|
3297
|
-
a("div",
|
3297
|
+
a("div", io, L(h.text), 1)
|
3298
3298
|
])
|
3299
3299
|
]))), 128))
|
3300
3300
|
]),
|
@@ -3305,7 +3305,7 @@ const ge = [
|
|
3305
3305
|
}, [
|
3306
3306
|
ee(u.$slots, "default", { hoverData: f.value })
|
3307
3307
|
], 512),
|
3308
|
-
a("div",
|
3308
|
+
a("div", so, [
|
3309
3309
|
(p(!0), k(K, null, q(e(ge), (h) => P((p(), k("div", {
|
3310
3310
|
key: h.name,
|
3311
3311
|
title: h.label || h.name,
|
@@ -3315,9 +3315,9 @@ const ge = [
|
|
3315
3315
|
a("img", {
|
3316
3316
|
src: h.preview,
|
3317
3317
|
class: "vs-map-slot-layers__image"
|
3318
|
-
}, null, 8,
|
3319
|
-
a("div",
|
3320
|
-
], 10,
|
3318
|
+
}, null, 8, co),
|
3319
|
+
a("div", po, L(h.label), 1)
|
3320
|
+
], 10, uo)), [
|
3321
3321
|
[x, h.label || h.name]
|
3322
3322
|
])), 128))
|
3323
3323
|
])
|
@@ -3326,7 +3326,7 @@ const ge = [
|
|
3326
3326
|
]);
|
3327
3327
|
};
|
3328
3328
|
}
|
3329
|
-
}),
|
3329
|
+
}), Ze = {
|
3330
3330
|
mounted(i, o) {
|
3331
3331
|
if (typeof document > "u") return;
|
3332
3332
|
let d = null;
|
@@ -3354,19 +3354,19 @@ const ge = [
|
|
3354
3354
|
const o = i.tooltipHandlers;
|
3355
3355
|
o && (i.removeEventListener("mouseenter", o.showTooltip), i.removeEventListener("mouseleave", o.hideTooltip));
|
3356
3356
|
}
|
3357
|
-
},
|
3357
|
+
}, vo = { class: "pt-[20px]" }, mo = { class: "w-full gap-5 inline-flex mb-[6px] pr-3" }, go = { class: "flex items-center" }, ho = ["title"], bo = { class: "max-[1000px]:flex gap-2 min-[1001px]:hidden" }, yo = { class: "flex" }, xo = {
|
3358
3358
|
key: 0,
|
3359
3359
|
class: "py-[15px] pb-[24px] pl-2"
|
3360
|
-
},
|
3360
|
+
}, wo = { class: "font-bold text-2xl mr-[10px]" }, ko = { class: "text-sm text-stone-500 font-medium" }, Co = {
|
3361
3361
|
class: "wrapperTable flex flex-col",
|
3362
3362
|
style: { height: "calc(100vh - 302px)" }
|
3363
|
-
},
|
3363
|
+
}, _o = {
|
3364
3364
|
key: 1,
|
3365
3365
|
class: "text-center py-28"
|
3366
|
-
},
|
3366
|
+
}, Vo = { key: 1 }, So = {
|
3367
3367
|
key: 2,
|
3368
3368
|
class: "my-5 pr-2"
|
3369
|
-
},
|
3369
|
+
}, Mo = { class: "flex justify-between" }, Bo = { class: "w-full lg:w-1/2 relative" }, Oe = /* @__PURE__ */ Y({
|
3370
3370
|
__name: "vs-parts-map",
|
3371
3371
|
props: {
|
3372
3372
|
title: {},
|
@@ -3383,47 +3383,47 @@ const ge = [
|
|
3383
3383
|
},
|
3384
3384
|
emits: ["change:filter", "update:map"],
|
3385
3385
|
setup(i, { emit: o }) {
|
3386
|
-
var ie, ae, Ae, Re, De, ze;
|
3387
|
-
const d =
|
3388
|
-
d && !(d != null && d.appContext.directives.tooltip) && (d.appContext.directives.tooltip =
|
3389
|
-
function r(
|
3390
|
-
return (
|
3386
|
+
var ie, ae, Ae, Re, De, ze, je;
|
3387
|
+
const d = tt();
|
3388
|
+
d && !(d != null && d.appContext.directives.tooltip) && (console.log("init tooltip"), d.appContext.directives.tooltip = Ze);
|
3389
|
+
function r(R) {
|
3390
|
+
return R ? (R.type === "Point" ? R.coordinates : null) || (R.type.includes("Multi") ? R.coordinates[0][0][0] : R.coordinates[0][0]) : null;
|
3391
3391
|
}
|
3392
3392
|
const t = i, s = o, v = V(0);
|
3393
3393
|
v.value = t.initTotal ?? ((ie = t.rows) == null ? void 0 : ie.length) ?? 0;
|
3394
|
-
const g = V(""), b = V(null), w = V(!0), m = V(((ae = t.rows) == null ? void 0 : ae.length) === 1), f = V(0), y = V(t.rows), _ = V(1), c = V(20), u = V(t.filters || []), l = V(""), x = V({}), h = V(((Ae = t.rows) == null ? void 0 : Ae.length) === 1 ? t.rows[0] : {}), n = V(((Re = t.rows) == null ? void 0 : Re.length) === 1 ? t.rows[0].id : ""), C = V(((De = t.rows) == null ? void 0 : De.length) === 1 ? r(t.rows[0].geom) : t.center || null), M = V(((
|
3395
|
-
function $(
|
3396
|
-
return Object.entries(
|
3394
|
+
const g = V(""), b = V(null), w = V(!0), m = V(((ae = t.rows) == null ? void 0 : ae.length) === 1), f = V(0), y = V(t.rows), _ = V(1), c = V(20), u = V(t.filters || []), l = V(""), x = V({}), h = V(((Ae = t.rows) == null ? void 0 : Ae.length) === 1 ? t.rows[0] : {}), n = V(((Re = t.rows) == null ? void 0 : Re.length) === 1 ? t.rows[0].id : ""), C = V(((De = t.rows) == null ? void 0 : De.length) === 1 ? r((ze = t.rows[0]) == null ? void 0 : ze.geom) : t.center || null), M = V(((je = t.rows) == null ? void 0 : je.length) === 1 ? 14 : t.zoom || 5);
|
3395
|
+
function $(R) {
|
3396
|
+
return Object.entries(R).filter(([, z]) => z).map(([z, ce]) => `${z}=${ce}`).join("|");
|
3397
3397
|
}
|
3398
3398
|
async function A() {
|
3399
|
-
const
|
3400
|
-
l.value =
|
3399
|
+
const R = $(x.value);
|
3400
|
+
l.value = R;
|
3401
3401
|
try {
|
3402
3402
|
const z = {
|
3403
3403
|
search: g.value,
|
3404
3404
|
limit: c.value.toString(),
|
3405
3405
|
page: _.value.toString(),
|
3406
|
-
filter:
|
3407
|
-
}, ce = new URL(`/api/data/${t.table}`, window.location.origin) + (n.value ? `/${n.value}` : ""), G = new URLSearchParams(z).toString(),
|
3406
|
+
filter: R
|
3407
|
+
}, ce = new URL(`/api/data/${t.table}`, window.location.origin) + (n.value ? `/${n.value}` : ""), G = new URLSearchParams(z).toString(), fe = await fetch(`${ce.toString()}?${G}`).then((pe) => pe.json());
|
3408
3408
|
if (n.value) {
|
3409
|
-
const [
|
3410
|
-
h.value =
|
3409
|
+
const [pe] = fe.rows;
|
3410
|
+
h.value = pe, C.value = r(pe == null ? void 0 : pe.geom), M.value = 14, m.value = !0;
|
3411
3411
|
} else
|
3412
|
-
m.value = !1, M.value = t.zoom || 5, y.value =
|
3413
|
-
v.value =
|
3412
|
+
m.value = !1, M.value = t.zoom || 5, y.value = fe == null ? void 0 : fe.rows;
|
3413
|
+
v.value = fe.filtered, Ca({ page: _.value, filter: R, id: n.value });
|
3414
3414
|
} catch (z) {
|
3415
3415
|
console.error(z.message);
|
3416
3416
|
}
|
3417
3417
|
}
|
3418
|
-
const T =
|
3419
|
-
function U(
|
3420
|
-
c.value =
|
3418
|
+
const T = lo(A, 300);
|
3419
|
+
function U(R) {
|
3420
|
+
c.value = R, _.value = 1, A();
|
3421
3421
|
}
|
3422
|
-
function de(
|
3423
|
-
_.value =
|
3422
|
+
function de(R) {
|
3423
|
+
_.value = R, A();
|
3424
3424
|
}
|
3425
|
-
function J(
|
3426
|
-
x.value =
|
3425
|
+
function J(R) {
|
3426
|
+
x.value = R.data, _.value = 1, n.value ? n.value = "" : A(), s("change:filter", R);
|
3427
3427
|
}
|
3428
3428
|
async function H() {
|
3429
3429
|
if (t.filters) return;
|
@@ -3435,29 +3435,29 @@ const ge = [
|
|
3435
3435
|
}
|
3436
3436
|
ue(async () => {
|
3437
3437
|
f.value = window.innerWidth, f.value < 1e3 && (w.value = !1);
|
3438
|
-
const
|
3439
|
-
_.value = Number(
|
3438
|
+
const R = new URLSearchParams(window.location.search);
|
3439
|
+
_.value = Number(R.get("page")) || 1, c.value = Number(R.get("limit")) || c.value, n.value = R.get("id") || "", m.value = !!n.value, H(), !y.value && !n.value && A();
|
3440
3440
|
});
|
3441
3441
|
function O() {
|
3442
3442
|
m.value = !1, h.value = null, n.value = "", A();
|
3443
3443
|
}
|
3444
|
-
function Q(
|
3445
|
-
n.value =
|
3444
|
+
function Q(R) {
|
3445
|
+
n.value = R.id;
|
3446
3446
|
}
|
3447
|
-
return
|
3448
|
-
s("update:map",
|
3449
|
-
}),
|
3450
|
-
|
3451
|
-
}),
|
3447
|
+
return D(b, (R) => {
|
3448
|
+
s("update:map", R);
|
3449
|
+
}), D(g, (R) => {
|
3450
|
+
R || A();
|
3451
|
+
}), D(n, () => {
|
3452
3452
|
A();
|
3453
|
-
}), (
|
3453
|
+
}), (R, z) => {
|
3454
3454
|
var ce;
|
3455
|
-
return p(), k("section",
|
3456
|
-
ee(
|
3455
|
+
return p(), k("section", vo, [
|
3456
|
+
ee(R.$slots, "header", {
|
3457
3457
|
title: t.title,
|
3458
3458
|
total: v.value
|
3459
3459
|
}),
|
3460
|
-
a("div",
|
3460
|
+
a("div", mo, [
|
3461
3461
|
I(e(ne), {
|
3462
3462
|
type: "text",
|
3463
3463
|
modelValue: g.value,
|
@@ -3475,33 +3475,33 @@ const ge = [
|
|
3475
3475
|
value: x.value,
|
3476
3476
|
ref: "filterRef"
|
3477
3477
|
}, null, 8, ["schema", "value"])) : S("", !0),
|
3478
|
-
a("div",
|
3478
|
+
a("div", go, [
|
3479
3479
|
a("button", {
|
3480
3480
|
type: "button",
|
3481
3481
|
class: "map-visible-button py-2 px-2 hidden min-[1001px]:inline-flex items-center gap-x-1.5 text-sm rounded-lg border border-gray-200 bg-white text-gray-600 shadow-sm hover:bg-stone-50 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-gray-100",
|
3482
3482
|
title: w.value ? "Приховати карту" : "Показати карту",
|
3483
3483
|
onClick: z[1] || (z[1] = (G) => w.value = !w.value)
|
3484
3484
|
}, [
|
3485
|
-
w.value ? (p(), j(
|
3485
|
+
w.value ? (p(), j(Ha, { key: 0 })) : (p(), j(qa, { key: 1 })),
|
3486
3486
|
z[8] || (z[8] = a("span", { class: "sr-only" }, "Відкрити мапу", -1))
|
3487
|
-
], 8,
|
3488
|
-
a("div",
|
3487
|
+
], 8, ho),
|
3488
|
+
a("div", bo, [
|
3489
3489
|
a("button", {
|
3490
3490
|
onClick: z[2] || (z[2] = (G) => w.value = !1),
|
3491
3491
|
class: "py-2 px-2 h-[38px] inline-flex items-center gap-x-1.5 text-sm rounded-lg border border-gray-200 bg-white text-gray-600 shadow-sm hover:bg-stone-50 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-gray-100"
|
3492
3492
|
}, [
|
3493
|
-
I(
|
3493
|
+
I(to)
|
3494
3494
|
]),
|
3495
3495
|
a("button", {
|
3496
3496
|
onClick: z[3] || (z[3] = (G) => w.value = !0),
|
3497
3497
|
class: "py-2 px-2 h-[38px] inline-flex items-center gap-x-1.5 text-sm rounded-lg border border-gray-200 bg-white text-gray-600 shadow-sm hover:bg-stone-50 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-gray-100"
|
3498
3498
|
}, [
|
3499
|
-
I(
|
3499
|
+
I(Za)
|
3500
3500
|
])
|
3501
3501
|
])
|
3502
3502
|
])
|
3503
3503
|
]),
|
3504
|
-
a("div",
|
3504
|
+
a("div", yo, [
|
3505
3505
|
a("div", {
|
3506
3506
|
class: F([
|
3507
3507
|
"relative overflow-hidden shrink-0",
|
@@ -3509,18 +3509,18 @@ const ge = [
|
|
3509
3509
|
m.value ? "hidden" : ""
|
3510
3510
|
])
|
3511
3511
|
}, [
|
3512
|
-
(ce =
|
3513
|
-
a("span",
|
3514
|
-
a("span",
|
3512
|
+
(ce = R.$slots) != null && ce.header ? S("", !0) : (p(), k("h1", xo, [
|
3513
|
+
a("span", wo, L(t.title), 1),
|
3514
|
+
a("span", ko, L(v.value), 1),
|
3515
3515
|
z[9] || (z[9] = a("span", { class: "text-sm text-stone-500 font-medium" }, " об'єктів", -1))
|
3516
3516
|
])),
|
3517
|
-
a("div",
|
3518
|
-
v.value >= 1 ? ee(
|
3517
|
+
a("div", Co, [
|
3518
|
+
v.value >= 1 ? ee(R.$slots, "table", {
|
3519
3519
|
key: 0,
|
3520
3520
|
rows: y.value,
|
3521
3521
|
selectRow: Q
|
3522
|
-
}) : (p(), k("div",
|
3523
|
-
I(
|
3522
|
+
}) : (p(), k("div", _o, [
|
3523
|
+
I(Oa),
|
3524
3524
|
z[10] || (z[10] = a("h2", { class: "font-medium text-base text-gray-500 rounded-xl" }, " За вашим запитом даних не знайдено! ", -1)),
|
3525
3525
|
z[11] || (z[11] = a("p", { class: "font-normal text-sm text-gray-500 rounded-xl" }, " Введіть, будь ласка, інші значення для пошуку. ", -1)),
|
3526
3526
|
a("button", {
|
@@ -3530,10 +3530,10 @@ const ge = [
|
|
3530
3530
|
}, " Очистити дані пошуку ")
|
3531
3531
|
]))
|
3532
3532
|
]),
|
3533
|
-
v.value >= 1 ? (p(), k("hr",
|
3534
|
-
v.value >= 1 ? (p(), k("div",
|
3535
|
-
a("div",
|
3536
|
-
I(
|
3533
|
+
v.value >= 1 ? (p(), k("hr", Vo)) : S("", !0),
|
3534
|
+
v.value >= 1 ? (p(), k("div", So, [
|
3535
|
+
a("div", Mo, [
|
3536
|
+
I(Fa, {
|
3537
3537
|
total: v.value,
|
3538
3538
|
currentPage: _.value ?? 1,
|
3539
3539
|
pageSize: c.value,
|
@@ -3550,14 +3550,14 @@ const ge = [
|
|
3550
3550
|
),
|
3551
3551
|
style: { height: "calc(100vh - 152px)" }
|
3552
3552
|
}, [
|
3553
|
-
ee(
|
3553
|
+
ee(R.$slots, "details", {
|
3554
3554
|
table: t.table,
|
3555
3555
|
selectedRow: h.value,
|
3556
3556
|
closeObjCard: O
|
3557
3557
|
})
|
3558
3558
|
], 2)) : S("", !0),
|
3559
|
-
P(a("div",
|
3560
|
-
I(
|
3559
|
+
P(a("div", Bo, [
|
3560
|
+
I(fo, {
|
3561
3561
|
table: t.table,
|
3562
3562
|
map: b.value,
|
3563
3563
|
"onUpdate:map": z[6] || (z[6] = (G) => b.value = G),
|
@@ -3569,11 +3569,11 @@ const ge = [
|
|
3569
3569
|
"onUpdate:modelValue": z[7] || (z[7] = (G) => n.value = G)
|
3570
3570
|
}, {
|
3571
3571
|
default: re(({ hoverData: G }) => [
|
3572
|
-
ee(
|
3572
|
+
ee(R.$slots, "popup", { data: G })
|
3573
3573
|
]),
|
3574
3574
|
_: 3
|
3575
3575
|
}, 8, ["table", "map", "zoom", "colorAttr", "filter", "center", "modelValue"]),
|
3576
|
-
ee(
|
3576
|
+
ee(R.$slots, "default", {
|
3577
3577
|
table: t.table,
|
3578
3578
|
map: b.value,
|
3579
3579
|
selectedRow: h.value
|
@@ -3586,9 +3586,9 @@ const ge = [
|
|
3586
3586
|
};
|
3587
3587
|
}
|
3588
3588
|
});
|
3589
|
-
|
3590
|
-
i.component("VsPartsMap",
|
3589
|
+
Oe.install = (i) => {
|
3590
|
+
i.component("VsPartsMap", Oe), i._context.directives.tooltip || i.directive("tooltip", Ze);
|
3591
3591
|
};
|
3592
3592
|
export {
|
3593
|
-
|
3593
|
+
Oe as default
|
3594
3594
|
};
|