@opengis/form 0.0.75 → 0.0.76

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { defineComponent as Z, ref as S, onMounted as be, onUnmounted as dt, createElementBlock as c, openBlock as i, createCommentVNode as F, renderSlot as Ee, createElementVNode as l, toDisplayString as H, mergeProps as De, computed as L, normalizeStyle as ye, createTextVNode as he, normalizeProps as wt, guardReactiveProps as kt, normalizeClass as U, mergeModels as ne, useModel as ue, withDirectives as re, unref as le, vModelText as me, vModelCheckbox as Ot, createVNode as P, createBlock as pe, resolveDynamicComponent as Pe, withCtx as Te, withModifiers as ge, onBeforeUnmount as ct, watch as te, createStaticVNode as xe, vModelRadio as Dt, Fragment as ae, renderList as ie, reactive as Ut, vModelDynamic as Wt, inject as Ae, vShow as _t, resolveComponent as Vt, Transition as $t, nextTick as Be, Teleport as We, getCurrentInstance as Jt, withKeys as Yt, toRef as Xt, provide as Lt, watchEffect as Qt } from "vue";
1
+ import { defineComponent as Z, ref as S, onMounted as ye, onUnmounted as dt, createElementBlock as c, openBlock as i, createCommentVNode as F, renderSlot as Ee, createElementVNode as l, toDisplayString as H, mergeProps as De, computed as L, normalizeStyle as be, createTextVNode as he, normalizeProps as wt, guardReactiveProps as kt, normalizeClass as U, mergeModels as ne, useModel as ue, withDirectives as re, unref as le, vModelText as me, vModelCheckbox as Ot, createVNode as P, createBlock as pe, resolveDynamicComponent as Pe, withCtx as Te, withModifiers as ge, onBeforeUnmount as ct, watch as te, createStaticVNode as xe, vModelRadio as Dt, Fragment as ae, renderList as ie, reactive as Ut, vModelDynamic as Wt, inject as Ae, vShow as _t, resolveComponent as Vt, Transition as $t, nextTick as Be, Teleport as We, getCurrentInstance as Jt, withKeys as Yt, toRef as Xt, provide as Lt, watchEffect as Qt } from "vue";
2
2
  import { notify as de, VsModal as Rt, modal as el } from "@opengis/core";
3
3
  const tl = { class: "w-full relative" }, ll = {
4
4
  key: 0,
@@ -27,7 +27,7 @@ const tl = { class: "w-full relative" }, ll = {
27
27
  const e = S("uk"), t = (o) => {
28
28
  o.detail.key === "locale" && (e.value = o.detail.newValue);
29
29
  };
30
- return be(() => {
30
+ return ye(() => {
31
31
  e.value = localStorage.locale, window.addEventListener("storage", t);
32
32
  }), dt(() => {
33
33
  window.removeEventListener("resize", t);
@@ -84,14 +84,14 @@ const tl = { class: "w-full relative" }, ll = {
84
84
  n.value ? (i(), c("span", {
85
85
  key: 0,
86
86
  class: "text-sm text-gray-900 font-medium flex shrink-0",
87
- style: ye(r.value)
87
+ style: be(r.value)
88
88
  }, [
89
89
  he(H(p.ua || p.label) + " ", 1),
90
90
  p.item?.rules?.includes("required") && (p.ua || p.label) ? (i(), c("span", il, "*")) : F("", !0)
91
91
  ], 4)) : F("", !0),
92
92
  l("div", {
93
93
  class: "flex-1 min-w-0",
94
- style: ye(d.value)
94
+ style: be(d.value)
95
95
  }, [
96
96
  Ee(p.$slots, "default", wt(kt(p.$attrs)))
97
97
  ], 4),
@@ -127,10 +127,10 @@ const tl = { class: "w-full relative" }, ll = {
127
127
  }, hl = { class: "truncate" }, gl = {
128
128
  key: 0,
129
129
  class: "text-red-500 text-[14px]"
130
- }, yl = {
130
+ }, bl = {
131
131
  key: 1,
132
132
  class: "text-xs text-slate-500 dark:text-slate-400"
133
- }, bl = {
133
+ }, yl = {
134
134
  key: 0,
135
135
  class: "mt-1 text-xs text-red-500"
136
136
  }, xl = /* @__PURE__ */ Z({
@@ -153,7 +153,7 @@ const tl = { class: "w-full relative" }, ll = {
153
153
  const o = L(() => e.item?.description ?? ""), n = L(() => Array.isArray(e.item?.rules) && e.item.rules.includes("required")), r = L(() => (typeof e.error == "string" ? e.error : "") ?? ""), d = (p) => {
154
154
  p.key === "locale" && (t.value = p.newValue ?? "uk");
155
155
  };
156
- return be(() => {
156
+ return ye(() => {
157
157
  try {
158
158
  typeof localStorage < "u" && localStorage.locale && (t.value = localStorage.locale);
159
159
  } catch {
@@ -172,7 +172,7 @@ const tl = { class: "w-full relative" }, ll = {
172
172
  l("span", hl, H(p.item[t.value] || p.ua || p.label), 1),
173
173
  n.value ? (i(), c("span", gl, "*")) : F("", !0)
174
174
  ])) : F("", !0),
175
- o.value ? (i(), c("p", yl, H(o.value), 1)) : F("", !0)
175
+ o.value ? (i(), c("p", bl, H(o.value), 1)) : F("", !0)
176
176
  ]),
177
177
  l("div", {
178
178
  class: U(["w-full", ["select", "native-select"].includes(p.item.type) ? "md:w-[30%]" : "md:w-auto"])
@@ -180,7 +180,7 @@ const tl = { class: "w-full relative" }, ll = {
180
180
  Ee(p.$slots, "default", wt(kt(p.$attrs)))
181
181
  ], 2)
182
182
  ], 2),
183
- r.value ? (i(), c("p", bl, H(r.value), 1)) : F("", !0)
183
+ r.value ? (i(), c("p", yl, H(r.value), 1)) : F("", !0)
184
184
  ], 2));
185
185
  }
186
186
  }), wl = {
@@ -308,14 +308,14 @@ const kl = ["placeholder", "disabled"], _l = /* @__PURE__ */ Z({
308
308
  class: "icon icon-tabler icons-tabler-outline icon-tabler-check"
309
309
  };
310
310
  function Sl(s, e) {
311
- return i(), c("svg", Ml, [...e[0] || (e[0] = [
311
+ return i(), c("svg", Ml, e[0] || (e[0] = [
312
312
  l("path", {
313
313
  stroke: "none",
314
314
  d: "M0 0h24v24H0z",
315
315
  fill: "none"
316
316
  }, null, -1),
317
317
  l("path", { d: "M5 12l5 5l10 -10" }, null, -1)
318
- ])]);
318
+ ]));
319
319
  }
320
320
  const Bl = /* @__PURE__ */ J(Ll, [["render", Sl]]), Al = { class: "flex items-center gap-[4px]" }, jl = ["value", "id", "disabled"], El = ["for"], Il = { class: "text-[14px] text-gray-700 flex items-center dark:text-neutral-400" }, Tl = /* @__PURE__ */ Z({
321
321
  __name: "vs-checkbox-default",
@@ -421,7 +421,7 @@ const Bl = /* @__PURE__ */ J(Ll, [["render", Sl]]), Al = { class: "flex items-ce
421
421
  ])
422
422
  ], 2));
423
423
  }
424
- }), Rl = { class: "flex items-center" }, bt = /* @__PURE__ */ Z({
424
+ }), Rl = { class: "flex items-center" }, yt = /* @__PURE__ */ Z({
425
425
  __name: "vs-input-checkbox-item",
426
426
  props: {
427
427
  value: { default: "" },
@@ -459,7 +459,7 @@ const Bl = /* @__PURE__ */ J(Ll, [["render", Sl]]), Al = { class: "flex items-ce
459
459
  id: n,
460
460
  icon: p.icon,
461
461
  imgUrl: p.imgUrl,
462
- style: ye(p.style),
462
+ style: be(p.style),
463
463
  error: p.error
464
464
  }, {
465
465
  default: Te(() => [
@@ -480,14 +480,14 @@ const Bl = /* @__PURE__ */ J(Ll, [["render", Sl]]), Al = { class: "flex items-ce
480
480
  class: "icon icon-tabler icons-tabler-outline icon-tabler-chevron-down"
481
481
  };
482
482
  function Nl(s, e) {
483
- return i(), c("svg", Hl, [...e[0] || (e[0] = [
483
+ return i(), c("svg", Hl, e[0] || (e[0] = [
484
484
  l("path", {
485
485
  stroke: "none",
486
486
  d: "M0 0h24v24H0z",
487
487
  fill: "none"
488
488
  }, null, -1),
489
489
  l("path", { d: "M6 9l6 6l6 -6" }, null, -1)
490
- ])]);
490
+ ]));
491
491
  }
492
492
  const Gl = /* @__PURE__ */ J(Pl, [["render", Nl]]), Kl = {}, ql = {
493
493
  xmlns: "http://www.w3.org/2000/svg",
@@ -500,7 +500,7 @@ const Gl = /* @__PURE__ */ J(Pl, [["render", Nl]]), Kl = {}, ql = {
500
500
  class: "icon icon-tabler icons-tabler-outline icon-tabler-x"
501
501
  };
502
502
  function Zl(s, e) {
503
- return i(), c("svg", ql, [...e[0] || (e[0] = [
503
+ return i(), c("svg", ql, e[0] || (e[0] = [
504
504
  l("path", {
505
505
  stroke: "none",
506
506
  d: "M0 0h24v24H0z",
@@ -508,7 +508,7 @@ function Zl(s, e) {
508
508
  }, null, -1),
509
509
  l("path", { d: "M18 6l-12 12" }, null, -1),
510
510
  l("path", { d: "M6 6l12 12" }, null, -1)
511
- ])]);
511
+ ]));
512
512
  }
513
513
  const Ct = /* @__PURE__ */ J(Kl, [["render", Zl]]), Wl = {}, Jl = {
514
514
  xmlns: "http://www.w3.org/2000/svg",
@@ -522,7 +522,7 @@ const Ct = /* @__PURE__ */ J(Kl, [["render", Zl]]), Wl = {}, Jl = {
522
522
  "stroke-linejoin": "round"
523
523
  };
524
524
  function Yl(s, e) {
525
- return i(), c("svg", Jl, [...e[0] || (e[0] = [
525
+ return i(), c("svg", Jl, e[0] || (e[0] = [
526
526
  l("path", {
527
527
  stroke: "none",
528
528
  d: "M0 0h24v24H0z",
@@ -531,7 +531,7 @@ function Yl(s, e) {
531
531
  l("path", { d: "M12 9h.01" }, null, -1),
532
532
  l("path", { d: "M11 12h1v4h1" }, null, -1),
533
533
  l("path", { d: "M12 3c7.2 0 9 1.8 9 9s-1.8 9 -9 9s-9 -1.8 -9 -9s1.8 -9 9 -9z" }, null, -1)
534
- ])]);
534
+ ]));
535
535
  }
536
536
  const Xl = /* @__PURE__ */ J(Wl, [["render", Yl]]), Ql = {
537
537
  key: 0,
@@ -562,7 +562,7 @@ const Xl = /* @__PURE__ */ J(Wl, [["render", Yl]]), Ql = {
562
562
  setup(s) {
563
563
  const e = s, t = ue(s, "modelValue");
564
564
  return (o, n) => e.view === "checkbox" ? (i(), c("div", Ql, [
565
- P(bt, {
565
+ P(yt, {
566
566
  modelValue: t.value,
567
567
  "onUpdate:modelValue": n[0] || (n[0] = (r) => t.value = r),
568
568
  label: o.text,
@@ -631,7 +631,7 @@ const Xl = /* @__PURE__ */ J(Wl, [["render", Yl]]), Ql = {
631
631
  setup(s) {
632
632
  const e = s, { inputClass: t } = we(e.style), o = ue(s, "modelValue"), n = S(null);
633
633
  let r = null;
634
- return be(async () => {
634
+ return ye(async () => {
635
635
  if (n.value) {
636
636
  const { default: d } = await import("./index-W-qQIppj.js");
637
637
  r = d(n.value, {
@@ -829,10 +829,10 @@ const Xl = /* @__PURE__ */ J(Wl, [["render", Yl]]), Ql = {
829
829
  }), go = {
830
830
  key: 1,
831
831
  class: "w-full flex flex-col gap-4"
832
- }, yo = {
832
+ }, bo = {
833
833
  key: 0,
834
834
  class: "text-sm font-medium text-muted-foreground my-2"
835
- }, bo = "Без категорії", xo = /* @__PURE__ */ Z({
835
+ }, yo = "Без категорії", xo = /* @__PURE__ */ Z({
836
836
  __name: "vs-input-checkbox",
837
837
  props: {
838
838
  options: { default: () => [] },
@@ -869,12 +869,12 @@ const Xl = /* @__PURE__ */ J(Wl, [["render", Yl]]), Ql = {
869
869
  const C = _(m);
870
870
  M.push(C);
871
871
  });
872
- const y = /* @__PURE__ */ new Set(), x = (m) => {
872
+ const b = /* @__PURE__ */ new Set(), x = (m) => {
873
873
  const C = k.get(m) || [];
874
874
  if (!C.length)
875
875
  return null;
876
- const h = m === null ? "group-null" : `group-${String(m)}`, $ = m === null ? bo : String(m);
877
- return y.add(m), {
876
+ const h = m === null ? "group-null" : `group-${String(m)}`, $ = m === null ? yo : String(m);
877
+ return b.add(m), {
878
878
  key: h,
879
879
  label: $,
880
880
  options: C
@@ -884,7 +884,7 @@ const Xl = /* @__PURE__ */ J(Wl, [["render", Yl]]), Ql = {
884
884
  const C = x(m);
885
885
  C && g.push(C);
886
886
  }), k.forEach((m, C) => {
887
- if (y.has(C))
887
+ if (b.has(C))
888
888
  return;
889
889
  const h = x(C);
890
890
  h && g.push(h);
@@ -905,9 +905,9 @@ const Xl = /* @__PURE__ */ J(Wl, [["render", Yl]]), Ql = {
905
905
  r[M] = k;
906
906
  } else if (Array.isArray(k)) {
907
907
  const M = new Set(k);
908
- n.value.forEach((y) => {
909
- if (!y.disabled) {
910
- const x = d(y);
908
+ n.value.forEach((b) => {
909
+ if (!b.disabled) {
910
+ const x = d(b);
911
911
  r[x] = M.has(x);
912
912
  }
913
913
  });
@@ -925,7 +925,7 @@ const Xl = /* @__PURE__ */ J(Wl, [["render", Yl]]), Ql = {
925
925
  o("update:modelValue", k.length === 0 ? [] : k);
926
926
  },
927
927
  { deep: !0 }
928
- ), be(() => {
928
+ ), ye(() => {
929
929
  if (t.data)
930
930
  j().then(() => {
931
931
  if (typeof t.modelValue == "boolean" && n.value.length === 1) {
@@ -935,8 +935,8 @@ const Xl = /* @__PURE__ */ J(Wl, [["render", Yl]]), Ql = {
935
935
  const k = new Set(t.modelValue);
936
936
  n.value.forEach((M) => {
937
937
  if (!M.disabled) {
938
- const y = d(M);
939
- r[y] = k.has(y);
938
+ const b = d(M);
939
+ r[b] = k.has(b);
940
940
  }
941
941
  });
942
942
  }
@@ -948,28 +948,28 @@ const Xl = /* @__PURE__ */ J(Wl, [["render", Yl]]), Ql = {
948
948
  const k = new Set(t.modelValue);
949
949
  n.value.forEach((M) => {
950
950
  if (!M.disabled) {
951
- const y = d(M);
952
- r[y] = k.has(y);
951
+ const b = d(M);
952
+ r[b] = k.has(b);
953
953
  }
954
954
  });
955
955
  }
956
956
  }), (k, M) => t.group ? (i(), c("div", go, [
957
- (i(!0), c(ae, null, ie(w.value, (y) => (i(), c("div", {
958
- key: y.key,
957
+ (i(!0), c(ae, null, ie(w.value, (b) => (i(), c("div", {
958
+ key: b.key,
959
959
  class: "flex flex-col gap-2"
960
960
  }, [
961
- y.label ? (i(), c("span", yo, H(y.label), 1)) : F("", !0),
961
+ b.label ? (i(), c("span", bo, H(b.label), 1)) : F("", !0),
962
962
  l("div", {
963
963
  class: U(["p-0 w-full gap-[12px]", v.value])
964
964
  }, [
965
- (i(!0), c(ae, null, ie(y.options, (x) => (i(), pe(bt, {
965
+ (i(!0), c(ae, null, ie(b.options, (x) => (i(), pe(yt, {
966
966
  modelValue: r[d(x)],
967
967
  "onUpdate:modelValue": (g) => r[d(x)] = g,
968
968
  value: d(x),
969
969
  class: U(f(k.colSpan)),
970
970
  disabled: t.disabled || x.disabled,
971
971
  label: p(x),
972
- key: `${y.key}-${d(x)}`,
972
+ key: `${b.key}-${d(x)}`,
973
973
  icon: x?.icon,
974
974
  imgUrl: x?.imgUrl,
975
975
  option: x,
@@ -981,22 +981,22 @@ const Xl = /* @__PURE__ */ J(Wl, [["render", Yl]]), Ql = {
981
981
  key: 0,
982
982
  class: U(["p-0 w-full gap-[10px]", v.value])
983
983
  }, [
984
- (i(!0), c(ae, null, ie(n.value, (y) => (i(), pe(bt, {
985
- modelValue: r[d(y)],
986
- "onUpdate:modelValue": (x) => r[d(y)] = x,
987
- value: d(y),
984
+ (i(!0), c(ae, null, ie(n.value, (b) => (i(), pe(yt, {
985
+ modelValue: r[d(b)],
986
+ "onUpdate:modelValue": (x) => r[d(b)] = x,
987
+ value: d(b),
988
988
  class: U(f(k.colSpan)),
989
- disabled: t.disabled || y.disabled,
990
- label: p(y),
991
- key: d(y),
992
- icon: y?.icon,
993
- imgUrl: y?.imgUrl,
994
- option: y,
989
+ disabled: t.disabled || b.disabled,
990
+ label: p(b),
991
+ key: d(b),
992
+ icon: b?.icon,
993
+ imgUrl: b?.imgUrl,
994
+ option: b,
995
995
  view: k.view
996
996
  }, null, 8, ["modelValue", "onUpdate:modelValue", "value", "class", "disabled", "label", "icon", "imgUrl", "option", "view"]))), 128))
997
997
  ], 2));
998
998
  }
999
- }), wo = /* @__PURE__ */ J(xo, [["__scopeId", "data-v-cf0478ce"]]), ko = ["type", "placeholder", "disabled"], _o = /* @__PURE__ */ Z({
999
+ }), wo = /* @__PURE__ */ J(xo, [["__scopeId", "data-v-8e66207e"]]), ko = ["type", "placeholder", "disabled"], _o = /* @__PURE__ */ Z({
1000
1000
  __name: "vs-input-date1",
1001
1001
  props: {
1002
1002
  style: { default: () => ({}) },
@@ -1092,10 +1092,10 @@ const Xl = /* @__PURE__ */ J(Wl, [["render", Yl]]), Ql = {
1092
1092
  "stroke-linejoin": "round"
1093
1093
  };
1094
1094
  function Mo(s, e) {
1095
- return i(), c("svg", Lo, [...e[0] || (e[0] = [
1095
+ return i(), c("svg", Lo, e[0] || (e[0] = [
1096
1096
  l("path", { d: "M5 12h14" }, null, -1),
1097
1097
  l("path", { d: "M12 5v14" }, null, -1)
1098
- ])]);
1098
+ ]));
1099
1099
  }
1100
1100
  const je = /* @__PURE__ */ J(Vo, [["render", Mo]]), So = {}, Bo = {
1101
1101
  xmlns: "http://www.w3.org/2000/svg",
@@ -1110,9 +1110,9 @@ const je = /* @__PURE__ */ J(Vo, [["render", Mo]]), So = {}, Bo = {
1110
1110
  "stroke-linejoin": "round"
1111
1111
  };
1112
1112
  function Ao(s, e, t, o, n, r) {
1113
- return i(), c("svg", Bo, [...e[0] || (e[0] = [
1113
+ return i(), c("svg", Bo, e[0] || (e[0] = [
1114
1114
  xe('<path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M14 3v4a1 1 0 0 0 1 1h4"></path><path d="M17 21h-10a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2h7l5 5v11a2 2 0 0 1 -2 2z"></path><line x1="9" y1="9" x2="10" y2="9"></line><line x1="9" y1="13" x2="15" y2="13"></line><line x1="9" y1="17" x2="15" y2="17"></line>', 6)
1115
- ])]);
1115
+ ]));
1116
1116
  }
1117
1117
  const jo = /* @__PURE__ */ J(So, [["render", Ao]]), Eo = {}, Io = {
1118
1118
  xmlns: "http://www.w3.org/2000/svg",
@@ -1127,7 +1127,7 @@ const jo = /* @__PURE__ */ J(So, [["render", Ao]]), Eo = {}, Io = {
1127
1127
  "stroke-linejoin": "round"
1128
1128
  };
1129
1129
  function To(s, e, t, o, n, r) {
1130
- return i(), c("svg", Io, [...e[0] || (e[0] = [
1130
+ return i(), c("svg", Io, e[0] || (e[0] = [
1131
1131
  l("path", {
1132
1132
  stroke: "none",
1133
1133
  d: "M0 0h24v24H0z",
@@ -1152,7 +1152,7 @@ function To(s, e, t, o, n, r) {
1152
1152
  x2: "10",
1153
1153
  y2: "20"
1154
1154
  }, null, -1)
1155
- ])]);
1155
+ ]));
1156
1156
  }
1157
1157
  const zo = /* @__PURE__ */ J(Eo, [["render", To]]), Fo = {}, Oo = {
1158
1158
  xmlns: "http://www.w3.org/2000/svg",
@@ -1166,9 +1166,9 @@ const zo = /* @__PURE__ */ J(Eo, [["render", To]]), Fo = {}, Oo = {
1166
1166
  "stroke-linejoin": "round"
1167
1167
  };
1168
1168
  function Do(s, e) {
1169
- return i(), c("svg", Oo, [...e[0] || (e[0] = [
1169
+ return i(), c("svg", Oo, e[0] || (e[0] = [
1170
1170
  xe('<path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M14 3v4a1 1 0 0 0 1 1h4"></path><path d="M17 21h-10a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2h7l5 5v11a2 2 0 0 1 -2 2z"></path><path d="M9 9l1 0"></path><path d="M9 13l6 0"></path><path d="M9 17l6 0"></path>', 6)
1171
- ])]);
1171
+ ]));
1172
1172
  }
1173
1173
  const Ht = /* @__PURE__ */ J(Fo, [["render", Do]]), Uo = {}, Ro = {
1174
1174
  xmlns: "http://www.w3.org/2000/svg",
@@ -1183,9 +1183,9 @@ const Ht = /* @__PURE__ */ J(Fo, [["render", Do]]), Uo = {}, Ro = {
1183
1183
  "stroke-linejoin": "round"
1184
1184
  };
1185
1185
  function Po(s, e, t, o, n, r) {
1186
- return i(), c("svg", Ro, [...e[0] || (e[0] = [
1186
+ return i(), c("svg", Ro, e[0] || (e[0] = [
1187
1187
  xe('<path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M6 20.735a2 2 0 0 1 -1 -1.735v-14a2 2 0 0 1 2 -2h7l5 5v11a2 2 0 0 1 -2 2h-1"></path><path d="M11 17a2 2 0 0 1 2 2v2a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1v-2a2 2 0 0 1 2 -2z"></path><line x1="11" y1="5" x2="10" y2="5"></line><line x1="13" y1="7" x2="12" y2="7"></line><line x1="11" y1="9" x2="10" y2="9"></line><line x1="13" y1="11" x2="12" y2="11"></line><line x1="11" y1="13" x2="10" y2="13"></line><line x1="13" y1="15" x2="12" y2="15"></line>', 9)
1188
- ])]);
1188
+ ]));
1189
1189
  }
1190
1190
  const Ho = /* @__PURE__ */ J(Uo, [["render", Po]]), No = {}, Go = {
1191
1191
  xmlns: "http://www.w3.org/2000/svg",
@@ -1200,9 +1200,9 @@ const Ho = /* @__PURE__ */ J(Uo, [["render", Po]]), No = {}, Go = {
1200
1200
  "stroke-linejoin": "round"
1201
1201
  };
1202
1202
  function Ko(s, e, t, o, n, r) {
1203
- return i(), c("svg", Go, [...e[0] || (e[0] = [
1203
+ return i(), c("svg", Go, e[0] || (e[0] = [
1204
1204
  xe('<path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M14 3v4a1 1 0 0 0 1 1h4"></path><path d="M17 21h-10a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2h7l5 5v11a2 2 0 0 1 -2 2z"></path><path d="M10 13l-1 2l1 2"></path><path d="M14 13l1 2l-1 2"></path>', 5)
1205
- ])]);
1205
+ ]));
1206
1206
  }
1207
1207
  const qo = /* @__PURE__ */ J(No, [["render", Ko]]), Zo = (s) => {
1208
1208
  if (!s) return "";
@@ -1230,9 +1230,9 @@ const qo = /* @__PURE__ */ J(No, [["render", Ko]]), Zo = (s) => {
1230
1230
  class: "icon icon-tabler icons-tabler-outline icon-tabler-trash"
1231
1231
  };
1232
1232
  function Xo(s, e) {
1233
- return i(), c("svg", Yo, [...e[0] || (e[0] = [
1233
+ return i(), c("svg", Yo, e[0] || (e[0] = [
1234
1234
  xe('<path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M4 7l16 0"></path><path d="M10 11l0 6"></path><path d="M14 11l0 6"></path><path d="M5 7l1 12a2 2 0 0 0 2 2h8a2 2 0 0 0 2 -2l1 -12"></path><path d="M9 7v-3a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v3"></path>', 6)
1235
- ])]);
1235
+ ]));
1236
1236
  }
1237
1237
  const He = /* @__PURE__ */ J(Jo, [["render", Xo]]), Qo = {}, ea = {
1238
1238
  xmlns: "http://www.w3.org/2000/svg",
@@ -1247,7 +1247,7 @@ const He = /* @__PURE__ */ J(Jo, [["render", Xo]]), Qo = {}, ea = {
1247
1247
  class: "icon icon-tabler icons-tabler-outline icon-tabler-download"
1248
1248
  };
1249
1249
  function ta(s, e) {
1250
- return i(), c("svg", ea, [...e[0] || (e[0] = [
1250
+ return i(), c("svg", ea, e[0] || (e[0] = [
1251
1251
  l("path", {
1252
1252
  stroke: "none",
1253
1253
  d: "M0 0h24v24H0z",
@@ -1256,7 +1256,7 @@ function ta(s, e) {
1256
1256
  l("path", { d: "M4 17v2a2 2 0 0 0 2 2h12a2 2 0 0 0 2 -2v-2" }, null, -1),
1257
1257
  l("path", { d: "M7 11l5 5l5 -5" }, null, -1),
1258
1258
  l("path", { d: "M12 4l0 12" }, null, -1)
1259
- ])]);
1259
+ ]));
1260
1260
  }
1261
1261
  const Nt = /* @__PURE__ */ J(Qo, [["render", ta]]), la = ["title"], oa = { class: "absolute hidden top-0 right-0 flex items-center gap-x-2 w-full h-full justify-center" }, aa = /* @__PURE__ */ Z({
1262
1262
  __name: "vs-input-file-list-item",
@@ -1312,7 +1312,7 @@ const Nt = /* @__PURE__ */ J(Qo, [["render", ta]]), la = ["title"], oa = { class
1312
1312
  ])
1313
1313
  ], 8, la));
1314
1314
  }
1315
- }), jt = /* @__PURE__ */ J(aa, [["__scopeId", "data-v-b61a9d9a"]]), sa = { class: "flex items-center gap-x-2" }, na = ["accept", "multiple", "disabled"], ra = {
1315
+ }), jt = /* @__PURE__ */ J(aa, [["__scopeId", "data-v-286cdbc0"]]), sa = { class: "flex items-center gap-x-2" }, na = ["accept", "multiple", "disabled"], ra = {
1316
1316
  key: 1,
1317
1317
  class: "flex items-center flex-wrap gap-2"
1318
1318
  }, ia = {
@@ -1395,7 +1395,7 @@ const Nt = /* @__PURE__ */ J(Qo, [["render", ta]]), la = ["title"], oa = { class
1395
1395
  message: `Поля (${C}) необхідні для завантаження файлу`,
1396
1396
  position: "right-bottom"
1397
1397
  }), !1;
1398
- }, y = (m) => {
1398
+ }, b = (m) => {
1399
1399
  de({
1400
1400
  type: "error",
1401
1401
  title: "Помилка завантаження",
@@ -1425,21 +1425,21 @@ const Nt = /* @__PURE__ */ J(Qo, [["render", ta]]), la = ["title"], oa = { class
1425
1425
  if (t.multiple) {
1426
1426
  const I = Array.from(C).map(async (N) => await Bt(N, k())), A = await Promise.all(I), Y = A.filter((N) => N !== null).map((N) => N?.file_path).filter(Boolean);
1427
1427
  if (Y.length === 0) {
1428
- y();
1428
+ b();
1429
1429
  return;
1430
1430
  }
1431
- Y.length < A.length && y("Деякі файли не вдалося завантажити. Перевірте їх та спробуйте знову."), o.value = [...o.value || [], ...Y], n("change", o.value);
1431
+ Y.length < A.length && b("Деякі файли не вдалося завантажити. Перевірте їх та спробуйте знову."), o.value = [...o.value || [], ...Y], n("change", o.value);
1432
1432
  } else {
1433
1433
  const I = C[0], A = await Bt(I, k());
1434
1434
  if (!A?.file_path) {
1435
- y();
1435
+ b();
1436
1436
  return;
1437
1437
  }
1438
1438
  o.value = A?.file_path, n("change", o.value || "");
1439
1439
  }
1440
1440
  } catch (I) {
1441
1441
  const A = I?.message || void 0;
1442
- y(A);
1442
+ b(A);
1443
1443
  } finally {
1444
1444
  d.value = !1, r.value && (r.value.value = "");
1445
1445
  }
@@ -1494,7 +1494,7 @@ const Nt = /* @__PURE__ */ J(Qo, [["render", ta]]), la = ["title"], oa = { class
1494
1494
  ], 2))
1495
1495
  ]));
1496
1496
  }
1497
- }), ca = /* @__PURE__ */ J(da, [["__scopeId", "data-v-08fe911b"]]), pa = { class: "max-w-[55vw]" }, fa = { class: "text-sm font-semibold text-gray-800 truncate dark:text-neutral-200" }, va = { class: "flex items-center text-xs text-gray-500 truncate dark:text-neutral-500" }, ma = { class: "px-[5px]" }, ha = { class: "" }, rt = /* @__PURE__ */ Z({
1497
+ }), ca = /* @__PURE__ */ J(da, [["__scopeId", "data-v-94bcb5d9"]]), pa = { class: "max-w-[55vw]" }, fa = { class: "text-sm font-semibold text-gray-800 truncate dark:text-neutral-200" }, va = { class: "flex items-center text-xs text-gray-500 truncate dark:text-neutral-500" }, ma = { class: "px-[5px]" }, ha = { class: "" }, rt = /* @__PURE__ */ Z({
1498
1498
  __name: "vs-widget-file-info",
1499
1499
  props: {
1500
1500
  item: { default: null }
@@ -1533,10 +1533,10 @@ const Nt = /* @__PURE__ */ J(Qo, [["render", ta]]), la = ["title"], oa = { class
1533
1533
  ])
1534
1534
  ], 64));
1535
1535
  }
1536
- }), ga = { class: "p-3 relative group flex items-center gap-x-3 border border-gray-200 bg-white rounded-md w-full" }, ya = {
1536
+ }), ga = { class: "p-3 relative group flex items-center gap-x-3 border border-gray-200 bg-white rounded-md w-full" }, ba = {
1537
1537
  key: 0,
1538
1538
  class: "flex w-full gap-x-3 items-center"
1539
- }, ba = {
1539
+ }, ya = {
1540
1540
  key: 1,
1541
1541
  class: "flex gap-x-3 w-full items-center"
1542
1542
  }, xa = {
@@ -1588,14 +1588,14 @@ const Nt = /* @__PURE__ */ J(Qo, [["render", ta]]), la = ["title"], oa = { class
1588
1588
  (t.item.ext === "jpg" || t.item.ext === "png") && o("openLightbox", { item: t.item, index: _ });
1589
1589
  }
1590
1590
  return (_, w) => (i(), c("div", ga, [
1591
- _.item.ext === "jpg" || _.item.ext === "png" ? (i(), c("div", ya, [
1591
+ _.item.ext === "jpg" || _.item.ext === "png" ? (i(), c("div", ba, [
1592
1592
  l("div", {
1593
1593
  class: "max-w-[55vw] cursor-pointer flex gap-x-3 w-full items-center",
1594
1594
  onClick: w[0] || (w[0] = (j) => v(_.index))
1595
1595
  }, [
1596
1596
  P(rt, { item: _.item }, null, 8, ["item"])
1597
1597
  ])
1598
- ])) : n(_.item) ? (i(), c("div", ba, [
1598
+ ])) : n(_.item) ? (i(), c("div", ya, [
1599
1599
  P(rt, { item: _.item }, null, 8, ["item"])
1600
1600
  ])) : r(_.item) ? (i(), c("div", xa, [
1601
1601
  l("a", {
@@ -1651,7 +1651,7 @@ const Nt = /* @__PURE__ */ J(Qo, [["render", ta]]), la = ["title"], oa = { class
1651
1651
  class: "icon icon-tabler icons-tabler-outline icon-tabler-download"
1652
1652
  };
1653
1653
  function Ba(s, e) {
1654
- return i(), c("svg", Sa, [...e[0] || (e[0] = [
1654
+ return i(), c("svg", Sa, e[0] || (e[0] = [
1655
1655
  l("path", {
1656
1656
  stroke: "none",
1657
1657
  d: "M0 0h24v24H0z",
@@ -1660,7 +1660,7 @@ function Ba(s, e) {
1660
1660
  l("path", { d: "M4 17v2a2 2 0 0 0 2 2h12a2 2 0 0 0 2 -2v-2" }, null, -1),
1661
1661
  l("path", { d: "M7 11l5 5l5 -5" }, null, -1),
1662
1662
  l("path", { d: "M12 4l0 12" }, null, -1)
1663
- ])]);
1663
+ ]));
1664
1664
  }
1665
1665
  const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col widget-file xl:bg-white xl:rounded-xl dark:xl:bg-neutral-800 dark:xl:border-neutral-700 w-full" }, Ea = { class: "flex w-full mb-[12px] items-center gap-x-2" }, Ia = { class: "font-semibold text-gray-800 dark:text-neutral-200 text-[14px]" }, Ta = { class1: "ml-auto" }, za = { class: "py-1.5 px-4 inline-flex items-center gap-x-2 text-sm font-medium rounded-lg bg-gray-100 cursor-pointer hover:bg-gray-200 text-gray-800 shadow-2xs hover:bg-gray-50 focus:outline-hidden focus:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-white dark:hover:bg-neutral-700 dark:focus:bg-neutral-700" }, Fa = {
1666
1666
  key: 0,
@@ -1686,7 +1686,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
1686
1686
  const t = s, o = Ae("form"), n = L(() => o.value.formId), r = S(!1), d = S(0), p = e, f = S(!1), v = S({}), _ = S([]), w = S(""), j = L(() => Array.isArray(_.value) ? _.value.filter((C) => C.ext === "jpg" || C.ext === "png").map((C) => C?.file_path) : []), k = L(() => w.value === "" ? _.value : _.value.filter((C) => C?.uploaded_name?.includes(w.value))), M = (C) => {
1687
1687
  const h = j.value.findIndex(($) => $ === C.item.file_path);
1688
1688
  h !== -1 && (r.value = !0, d.value = h);
1689
- }, y = async () => {
1689
+ }, b = async () => {
1690
1690
  try {
1691
1691
  const C = await fetch(`${t.prefix}/widget/file/${n.value}`).then((h) => h.json());
1692
1692
  _.value = C?.rows;
@@ -1713,21 +1713,21 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
1713
1713
  }), console.error(I), null;
1714
1714
  }
1715
1715
  })
1716
- ), await y();
1716
+ ), await b();
1717
1717
  }, g = (C) => {
1718
1718
  const h = { ...C };
1719
1719
  return C.cancel || (h.cancel = () => {
1720
1720
  f.value = !1;
1721
1721
  }), C.updateListOnConfirm && (h.confirm = async () => {
1722
- await C.confirm(), f.value = !1, y();
1722
+ await C.confirm(), f.value = !1, b();
1723
1723
  }), h;
1724
1724
  }, m = (C) => {
1725
1725
  v.value = g(C), f.value = !0;
1726
1726
  };
1727
1727
  return te(n, (C) => {
1728
- C && y();
1729
- }), be(() => {
1730
- n.value && y();
1728
+ C && b();
1729
+ }), ye(() => {
1730
+ n.value && b();
1731
1731
  }), (C, h) => {
1732
1732
  const $ = Vt("Lightbox"), I = Vt("MessageBox");
1733
1733
  return i(), c("div", ja, [
@@ -1799,9 +1799,9 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
1799
1799
  onOpenModal: h[3] || (h[3] = (Y) => m(Y)),
1800
1800
  onOpenLightbox: h[4] || (h[4] = (Y) => M(Y))
1801
1801
  }, null, 8, ["prefix", "item", "index"]))), 128)),
1802
- k.value.length ? F("", !0) : (i(), c("div", Ua, [...h[9] || (h[9] = [
1802
+ k.value.length ? F("", !0) : (i(), c("div", Ua, h[9] || (h[9] = [
1803
1803
  l("p", { class: "text-sm text-gray-600 font-sm" }, " Файлів з такою назвою не існує, введіть інше пошукове слово ", -1)
1804
- ])]))
1804
+ ])))
1805
1805
  ])) : F("", !0),
1806
1806
  P($, {
1807
1807
  modelValue: r.value,
@@ -1847,7 +1847,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
1847
1847
  P(Pt, {
1848
1848
  modelValue: t.value,
1849
1849
  "onUpdate:modelValue": n[0] || (n[0] = (r) => t.value = r),
1850
- style: ye(s.style)
1850
+ style: be(s.style)
1851
1851
  }, null, 8, ["modelValue", "style"])
1852
1852
  ]),
1853
1853
  P($t, { name: "slide-fade" }, {
@@ -1862,7 +1862,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
1862
1862
  })
1863
1863
  ]));
1864
1864
  }
1865
- }), Ka = /* @__PURE__ */ J(Ga, [["__scopeId", "data-v-00f2f0fc"]]), qa = { class: "text-[16px] text-gray-900 font-medium" }, Za = { class: "grid gap-3" }, Wa = /* @__PURE__ */ Z({
1865
+ }), Ka = /* @__PURE__ */ J(Ga, [["__scopeId", "data-v-90320b87"]]), qa = { class: "text-[16px] text-gray-900 font-medium" }, Za = { class: "grid gap-3" }, Wa = /* @__PURE__ */ Z({
1866
1866
  __name: "vs-container-accordion",
1867
1867
  props: {
1868
1868
  title: {
@@ -1908,7 +1908,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
1908
1908
  })
1909
1909
  ]));
1910
1910
  }
1911
- }), Ja = /* @__PURE__ */ J(Wa, [["__scopeId", "data-v-78778cb5"]]), Ya = { class: "flex items-center justify-between" }, Xa = /* @__PURE__ */ Z({
1911
+ }), Ja = /* @__PURE__ */ J(Wa, [["__scopeId", "data-v-590eff11"]]), Ya = { class: "flex items-center justify-between" }, Xa = /* @__PURE__ */ Z({
1912
1912
  __name: "vs-container-default",
1913
1913
  props: {
1914
1914
  title: {
@@ -2018,7 +2018,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2018
2018
  return (p, f) => s.schema?.length ? (i(), pe(Pe(r.value), {
2019
2019
  key: 0,
2020
2020
  title: s.title,
2021
- style: ye(s.style)
2021
+ style: be(s.style)
2022
2022
  }, {
2023
2023
  default: Te(() => [
2024
2024
  (i(!0), c(ae, null, ie(n.value, (v) => (i(), pe(qt, De({
@@ -2037,7 +2037,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2037
2037
  }), fs = ["aria-expanded", "data-focus"], vs = {
2038
2038
  key: 0,
2039
2039
  class: "flex flex-wrap items-center gap-1 overflow-y-auto min-w-0 flex-1"
2040
- }, ms = { class: "flex items-center min-w-0" }, hs = ["title"], gs = ["innerHTML"], ys = ["onClick"], bs = { class: "flex-1 min-w-[2px]" }, xs = ["placeholder"], ws = ["title"], ks = ["innerHTML"], _s = {
2040
+ }, ms = { class: "flex items-center min-w-0" }, hs = ["title"], gs = ["innerHTML"], bs = ["onClick"], ys = { class: "flex-1 min-w-[2px]" }, xs = ["placeholder"], ws = ["title"], ks = ["innerHTML"], _s = {
2041
2041
  key: 2,
2042
2042
  class: "flex-1 min-w-[2px]"
2043
2043
  }, $s = ["placeholder"], Cs = { class: "flex items-center shrink-0" }, Vs = ["disabled"], Ls = ["disabled", "title"], Ms = ["aria-disabled", "onClick"], Ss = ["innerHTML"], Bs = {
@@ -2079,7 +2079,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2079
2079
  set: (V) => o("update:modelValue", V)
2080
2080
  });
2081
2081
  !d.value && t.defaultValue && (d.value = t.defaultValue);
2082
- const p = S(null), f = S(null), v = S(null), _ = S(null), w = S(!1), j = S(!1), k = S(null), M = S([]), y = S(-1), x = S([]), g = S(""), m = S(null), C = S("bottom"), h = S({}), $ = S([]), I = L(() => {
2082
+ const p = S(null), f = S(null), v = S(null), _ = S(null), w = S(!1), j = S(!1), k = S(null), M = S([]), b = S(-1), x = S([]), g = S(""), m = S(null), C = S("bottom"), h = S({}), $ = S([]), I = L(() => {
2083
2083
  if (!$.value.length) return [];
2084
2084
  const V = M.value, B = new Map(V.map((a) => [a.id?.toString(), a]));
2085
2085
  return $.value.map((a) => B.get(a?.toString())).filter((a) => !!a);
@@ -2090,8 +2090,8 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2090
2090
  if (!t.data && g.value.trim() !== "") {
2091
2091
  const B = g.value.toLowerCase();
2092
2092
  V = V.filter((a) => {
2093
- const u = D(a).toLowerCase(), b = a.text?.toLowerCase?.() || "";
2094
- return u.includes(B) || b.includes(B);
2093
+ const u = D(a).toLowerCase(), y = a.text?.toLowerCase?.() || "";
2094
+ return u.includes(B) || y.includes(B);
2095
2095
  });
2096
2096
  }
2097
2097
  if (n.value && $.value.length) {
@@ -2103,7 +2103,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2103
2103
  if (!V) return "";
2104
2104
  const B = G.value;
2105
2105
  return B ? B.replace(ee, (a, u) => {
2106
- const b = u.trim(), E = V[b];
2106
+ const y = u.trim(), E = V[y];
2107
2107
  return E != null ? String(E) : "";
2108
2108
  }) : V.text ?? "";
2109
2109
  }, D = (V) => {
@@ -2123,15 +2123,15 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2123
2123
  if (V?.trim()) {
2124
2124
  const a = V.toLowerCase();
2125
2125
  B = B.filter((u) => {
2126
- const b = D(u).toLowerCase(), E = u.text?.toLowerCase?.() || "";
2127
- return b.includes(a) || E.includes(a);
2126
+ const y = D(u).toLowerCase(), E = u.text?.toLowerCase?.() || "";
2127
+ return y.includes(a) || E.includes(a);
2128
2128
  });
2129
2129
  }
2130
2130
  return B;
2131
2131
  }
2132
2132
  try {
2133
- const B = t.host ?? "", a = t.prefix ?? "api", u = t.api ?? `/${a}/suggest/${t.data}`, b = `${B}${u}`, E = new URLSearchParams();
2134
- return E.set("json", "1"), V && E.set("key", V), X.value !== void 0 && X.value !== null && X.value !== "" && E.set("parent", X.value), (await fetch(`${b}?${E.toString()}`).then((K) => K.json()))?.data ?? [];
2133
+ const B = t.host ?? "", a = t.prefix ?? "api", u = t.api ?? `/${a}/suggest/${t.data}`, y = `${B}${u}`, E = new URLSearchParams();
2134
+ return E.set("json", "1"), V && E.set("key", V), X.value !== void 0 && X.value !== null && X.value !== "" && E.set("parent", X.value), (await fetch(`${y}?${E.toString()}`).then((K) => K.json()))?.data ?? [];
2135
2135
  } catch {
2136
2136
  return [];
2137
2137
  }
@@ -2143,7 +2143,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2143
2143
  if (B) return B;
2144
2144
  if (t.data)
2145
2145
  try {
2146
- const a = t.host ?? "", u = t.prefix ?? "api", b = t.api ?? `/${u}/suggest/${t.data}`, E = `${a}${b}`, z = new URLSearchParams();
2146
+ const a = t.host ?? "", u = t.prefix ?? "api", y = t.api ?? `/${u}/suggest/${t.data}`, E = `${a}${y}`, z = new URLSearchParams();
2147
2147
  return z.set("json", "1"), z.set("val", String(V)), X.value !== void 0 && X.value !== null && X.value !== "" && z.set("parent", X.value), ((await fetch(`${E}?${z.toString()}`).then((ce) => ce.json()))?.data ?? [])?.[0] ?? null;
2148
2148
  } catch {
2149
2149
  return null;
@@ -2151,17 +2151,17 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2151
2151
  return null;
2152
2152
  }, ke = async (V) => {
2153
2153
  const B = new Set(M.value.map((u) => u.id?.toString())), a = V.filter((u) => !B.has(u?.toString()));
2154
- a.length && await a.reduce(async (u, b) => {
2154
+ a.length && await a.reduce(async (u, y) => {
2155
2155
  await u;
2156
- const E = await Ve(b);
2156
+ const E = await Ve(y);
2157
2157
  E && M.value.push(E);
2158
2158
  }, Promise.resolve());
2159
2159
  }, Ne = async () => {
2160
2160
  r.value || (w.value = !0, await ve(), await Be(() => {
2161
- Fe(), m.value?.focus(), R.value.length ? y.value = 0 : y.value = -1;
2161
+ Fe(), m.value?.focus(), R.value.length ? b.value = 0 : b.value = -1;
2162
2162
  }));
2163
2163
  }, Me = () => {
2164
- w.value = !1, y.value = -1;
2164
+ w.value = !1, b.value = -1;
2165
2165
  }, pt = async (V) => {
2166
2166
  if (r.value) return;
2167
2167
  !w.value ? await Ne() : Me();
@@ -2173,15 +2173,15 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2173
2173
  n.value && ($.value = $.value.filter((B) => B?.toString() !== V?.toString()), d.value = [...$.value], o("change", d.value), Be(() => m.value?.focus()));
2174
2174
  }, Ge = (V) => {
2175
2175
  n.value ? (N(V.id) || ($.value = [...$.value, V.id], d.value = [...$.value], o("change", d.value)), g.value = "", Be(() => {
2176
- m.value?.focus(), y.value = Math.min(y.value, R.value.length - 1);
2176
+ m.value?.focus(), b.value = Math.min(b.value, R.value.length - 1);
2177
2177
  }), W(null)) : (k.value = V, d.value = V.id, o("change", d.value), g.value = "", Me(), W(V));
2178
2178
  }, mt = (V) => {
2179
2179
  N(V.id) || Ge(V);
2180
2180
  }, ze = (V, B) => {
2181
2181
  if (!V || !B) return;
2182
- const a = V.offsetTop, u = a + V.offsetHeight, b = B.scrollTop, E = b + B.clientHeight;
2182
+ const a = V.offsetTop, u = a + V.offsetHeight, y = B.scrollTop, E = y + B.clientHeight;
2183
2183
  let z = B.scrollTop;
2184
- a < b ? z = a - 80 : u > E && (z = u - B.clientHeight + 4);
2184
+ a < y ? z = a - 80 : u > E && (z = u - B.clientHeight + 4);
2185
2185
  const K = B;
2186
2186
  K.scrollTop = z;
2187
2187
  }, Le = (V) => {
@@ -2197,7 +2197,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2197
2197
  return document.body;
2198
2198
  }, Fe = () => {
2199
2199
  if (!f.value) return;
2200
- const V = f.value.getBoundingClientRect(), B = window.innerHeight || document.documentElement.clientHeight, a = window.innerWidth || document.documentElement.clientWidth, u = 8, b = 8, E = t.maxHeight || 300, z = B - V.bottom - b - u, K = V.top - b - u, se = z >= K, ce = Math.max(a - u * 2, 0);
2200
+ const V = f.value.getBoundingClientRect(), B = window.innerHeight || document.documentElement.clientHeight, a = window.innerWidth || document.documentElement.clientWidth, u = 8, y = 8, E = t.maxHeight || 300, z = B - V.bottom - y - u, K = V.top - y - u, se = z >= K, ce = Math.max(a - u * 2, 0);
2201
2201
  let { width: fe } = V;
2202
2202
  ce > 0 && fe > ce && (fe = ce);
2203
2203
  let { left: Ce } = V;
@@ -2213,7 +2213,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2213
2213
  minWidth: "300px",
2214
2214
  maxHeight: `${Ze}px`,
2215
2215
  transform: se ? "none" : "translateY(-100%)",
2216
- top: se ? `${V.bottom + b}px` : `${V.top - b}px`
2216
+ top: se ? `${V.bottom + y}px` : `${V.top - y}px`
2217
2217
  };
2218
2218
  }, Ke = async (V) => {
2219
2219
  r.value || !w.value && (V.key === "ArrowDown" || V.key === "ArrowUp") && (V.preventDefault(), await Ne());
@@ -2221,14 +2221,14 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2221
2221
  if (!w.value) return;
2222
2222
  const { key: B } = V;
2223
2223
  if (B === "ArrowDown")
2224
- V.preventDefault(), y.value + 1 < R.value.length && (y.value += 1, ze(x.value[y.value], v.value));
2224
+ V.preventDefault(), b.value + 1 < R.value.length && (b.value += 1, ze(x.value[b.value], v.value));
2225
2225
  else if (B === "ArrowUp")
2226
- V.preventDefault(), y.value > 0 && (y.value -= 1, ze(x.value[y.value], v.value));
2226
+ V.preventDefault(), b.value > 0 && (b.value -= 1, ze(x.value[b.value], v.value));
2227
2227
  else if (B === "Enter") {
2228
2228
  V.preventDefault();
2229
- const a = R.value[y.value];
2229
+ const a = R.value[b.value];
2230
2230
  a && Ge(a), m.value?.blur();
2231
- } else B === "Escape" ? (V.preventDefault(), Me()) : B === "Backspace" ? n.value && g.value === "" && $.value.length && ($.value = $.value.slice(0, -1), d.value = [...$.value], o("change", d.value)) : B === "Home" ? (y.value = 0, ze(x.value[0], v.value)) : B === "End" ? (y.value = R.value.length - 1, ze(x.value[y.value], v.value)) : B === "Tab" && Me();
2231
+ } else B === "Escape" ? (V.preventDefault(), Me()) : B === "Backspace" ? n.value && g.value === "" && $.value.length && ($.value = $.value.slice(0, -1), d.value = [...$.value], o("change", d.value)) : B === "Home" ? (b.value = 0, ze(x.value[0], v.value)) : B === "End" ? (b.value = R.value.length - 1, ze(x.value[b.value], v.value)) : B === "Tab" && Me();
2232
2232
  }, qe = () => {
2233
2233
  r.value || (j.value = !0);
2234
2234
  }, Re = () => {
@@ -2261,7 +2261,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2261
2261
  }
2262
2262
  te(d, () => {
2263
2263
  Se();
2264
- }), be(async () => {
2264
+ }), ye(async () => {
2265
2265
  addEventListener("keydown", Qe), addEventListener("scroll", tt, !0), addEventListener("resize", lt), document.addEventListener("click", et, !0), f.value && Le(f.value).addEventListener("scroll", Oe, !0), t.options?.length && !t.data ? M.value = [...t.options] : t.data && (M.value = await T("")), await Se(), nt.value = !1;
2266
2266
  }), dt(() => {
2267
2267
  removeEventListener("keydown", Qe), removeEventListener("scroll", tt, !0), removeEventListener("resize", lt), document.removeEventListener("click", et, !0), f.value && Le(f.value).removeEventListener("scroll", Oe, !0);
@@ -2276,7 +2276,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2276
2276
  body: JSON.stringify(Ie.value)
2277
2277
  }).then((u) => u.json());
2278
2278
  if (!t.options?.length && t.data) {
2279
- const { data: u } = await fetch(`${t.api ?? `/api/suggest/${t.data}`}?val=${a}`).then((b) => b.json());
2279
+ const u = await fetch(`${t.api ?? `/api/suggest/${t.data}`}?val=${a}`).then((y) => y.json());
2280
2280
  k.value = u[0], M.value.push(u[0]), d.value = a;
2281
2281
  }
2282
2282
  $e.value = !1, de({ title: "Success!", message: "Object created." });
@@ -2292,11 +2292,11 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2292
2292
  a && clearTimeout(a), a = window.setTimeout(() => V(...u), B);
2293
2293
  };
2294
2294
  }
2295
- const yt = gt(async (V) => {
2295
+ const bt = gt(async (V) => {
2296
2296
  M.value = await T(V);
2297
2297
  }, 200);
2298
2298
  te(g, (V) => {
2299
- t.data && yt(V.trim());
2299
+ t.data && bt(V.trim());
2300
2300
  }), te(() => t.options, (V) => {
2301
2301
  !t.data && V?.length && (M.value = [...V], Se());
2302
2302
  }, { immediate: !0 }), te(() => t.parent ?? t.parentValue, () => {
@@ -2377,7 +2377,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2377
2377
  a?.color ? (i(), c("span", {
2378
2378
  key: 0,
2379
2379
  class: "w-[16px] h-[16px] rounded-md block ml-1.5 flex-shrink-0",
2380
- style: ye({ backgroundColor: a?.color })
2380
+ style: be({ backgroundColor: a?.color })
2381
2381
  }, null, 4)) : F("", !0),
2382
2382
  l("div", {
2383
2383
  class: "truncate text-gray-900 overflow-hidden max-w-[200px] px-0.5 py-[2px] pl-1.5",
@@ -2395,7 +2395,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2395
2395
  role: "button",
2396
2396
  class: "flex items-center rounded-sm px-1 box-border hover:bg-[#ffbdad] hover:text-[#de350b] flex-shrink-0",
2397
2397
  onClick: ge((u) => Ye(a.id), ["stop"])
2398
- }, [...B[6] || (B[6] = [
2398
+ }, B[6] || (B[6] = [
2399
2399
  l("svg", {
2400
2400
  height: "14",
2401
2401
  width: "14",
@@ -2406,9 +2406,9 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2406
2406
  }, [
2407
2407
  l("path", { d: "M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z" })
2408
2408
  ], -1)
2409
- ])], 8, ys)
2409
+ ]), 8, bs)
2410
2410
  ]))), 128)),
2411
- l("div", bs, [
2411
+ l("div", ys, [
2412
2412
  !r.value && V.search ? re((i(), c("input", {
2413
2413
  key: 0,
2414
2414
  ref_key: "inputRef",
@@ -2438,7 +2438,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2438
2438
  k.value?.color ? (i(), c("span", {
2439
2439
  key: 0,
2440
2440
  class: "w-[14px] h-[14px] rounded-md block mr-1 mt-1 absolute",
2441
- style: ye({ backgroundColor: k.value?.color })
2441
+ style: be({ backgroundColor: k.value?.color })
2442
2442
  }, null, 4)) : F("", !0),
2443
2443
  G.value ? (i(), c("span", {
2444
2444
  key: 1,
@@ -2480,7 +2480,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2480
2480
  "aria-hidden": "true",
2481
2481
  disabled: r.value,
2482
2482
  onClick: ge(vt, ["stop"])
2483
- }, [...B[7] || (B[7] = [
2483
+ }, B[7] || (B[7] = [
2484
2484
  l("svg", {
2485
2485
  height: "20",
2486
2486
  width: "20",
@@ -2489,7 +2489,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2489
2489
  }, [
2490
2490
  l("path", { d: "M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z" })
2491
2491
  ], -1)
2492
- ])], 8, Vs)) : F("", !0),
2492
+ ]), 8, Vs)) : F("", !0),
2493
2493
  B[9] || (B[9] = l("div", { class: "self-stretch w-px bg-[#ccc] my-[1px]" }, null, -1)),
2494
2494
  l("button", {
2495
2495
  type: "button",
@@ -2498,7 +2498,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2498
2498
  disabled: r.value,
2499
2499
  onClick: B[4] || (B[4] = ge((a) => pt(), ["stop"])),
2500
2500
  title: w.value ? "Закрити список" : "Відкрити список"
2501
- }, [...B[8] || (B[8] = [
2501
+ }, B[8] || (B[8] = [
2502
2502
  l("svg", {
2503
2503
  height: "20",
2504
2504
  width: "20",
@@ -2507,7 +2507,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2507
2507
  }, [
2508
2508
  l("path", { d: "M4.516 7.548c0.436-0.446 1.043-0.481 1.576 0l3.908 3.747 3.908-3.747c0.533-0.481 1.141-0.446 1.574 0 0.436 0.445 0.408 1.197 0 1.615-0.406 0.418-4.695 4.502-4.695 4.502-0.217 0.223-0.502 0.335-0.787 0.335s-0.57-0.112-0.789-0.335c0 0-4.287-4.084-4.695-4.502s-0.436-1.17 0-1.615z" })
2509
2509
  ], -1)
2510
- ])], 8, Ls)
2510
+ ]), 8, Ls)
2511
2511
  ])
2512
2512
  ], 42, fs),
2513
2513
  (i(), pe(We, { to: "body" }, [
@@ -2518,40 +2518,40 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2518
2518
  class: U([
2519
2519
  "fixed z-[3000] rounded bg-white shadow-[0_0_0_1px_rgba(0,0,0,0.1),0_4px_11px_rgba(0,0,0,0.1)]"
2520
2520
  ]),
2521
- style: ye(h.value),
2521
+ style: be(h.value),
2522
2522
  role: "listbox"
2523
2523
  }, [
2524
2524
  l("div", {
2525
2525
  class: "overflow-y-auto py-1",
2526
- style: ye({ maxHeight: h.value.maxHeight || "300px" }),
2526
+ style: be({ maxHeight: h.value.maxHeight || "300px" }),
2527
2527
  ref_key: "listRef",
2528
2528
  ref: v
2529
2529
  }, [
2530
2530
  R.value.length ? (i(!0), c(ae, { key: 0 }, ie(R.value, (a, u) => (i(), c("div", {
2531
2531
  key: a.id,
2532
2532
  ref_for: !0,
2533
- ref: (b) => x.value[u] = b,
2533
+ ref: (y) => x.value[u] = y,
2534
2534
  class: U([
2535
2535
  "flex px-3 py-2 cursor-default select-none text-gray-900 ",
2536
2536
  N(a.id) ? "bg-blue-500 text-white" : "bg-white hover:bg-blue-100",
2537
- y.value === u && !N(a.id) ? "bg-blue-100" : ""
2537
+ b.value === u && !N(a.id) ? "bg-blue-100" : ""
2538
2538
  ]),
2539
2539
  "aria-disabled": N(a.id) ? "true" : "false",
2540
2540
  role: "option",
2541
2541
  tabindex: "-1",
2542
- onClick: (b) => mt(a)
2542
+ onClick: (y) => mt(a)
2543
2543
  }, [
2544
2544
  a?.color ? (i(), c("span", {
2545
2545
  key: 0,
2546
2546
  class: "w-[11px] h-[11px] rounded-full block mr-1 mt-1.5",
2547
- style: ye({ backgroundColor: a?.color })
2547
+ style: be({ backgroundColor: a?.color })
2548
2548
  }, null, 4)) : F("", !0),
2549
2549
  l("div", {
2550
2550
  class: U([
2551
2551
  "leading-[19px]",
2552
- y.value === a.id ? "text-white" : "",
2552
+ b.value === a.id ? "text-white" : "",
2553
2553
  // active style like react-select
2554
- (y.value === u, "")
2554
+ (b.value === u, "")
2555
2555
  ])
2556
2556
  }, [
2557
2557
  G.value ? (i(), c("span", {
@@ -2623,7 +2623,7 @@ const Aa = /* @__PURE__ */ J(Ma, [["render", Ba]]), ja = { class: "flex flex-col
2623
2623
  class: "icon icon-tabler icons-tabler-outline icon-tabler-search stroke-gray-500 transition-all"
2624
2624
  };
2625
2625
  function zs(s, e) {
2626
- return i(), c("svg", Ts, [...e[0] || (e[0] = [
2626
+ return i(), c("svg", Ts, e[0] || (e[0] = [
2627
2627
  l("path", {
2628
2628
  stroke: "none",
2629
2629
  d: "M0 0h24v24H0z",
@@ -2631,7 +2631,7 @@ function zs(s, e) {
2631
2631
  }, null, -1),
2632
2632
  l("path", { d: "M10 10m-7 0a7 7 0 1 0 14 0a7 7 0 1 0 -14 0" }, null, -1),
2633
2633
  l("path", { d: "M21 21l-6 -6" }, null, -1)
2634
- ])]);
2634
+ ]));
2635
2635
  }
2636
2636
  const Fs = /* @__PURE__ */ J(Is, [["render", zs]]), Os = {}, Ds = {
2637
2637
  class: "flex-shrink-0 mt-0.5 size-3.5",
@@ -2644,12 +2644,12 @@ const Fs = /* @__PURE__ */ J(Is, [["render", zs]]), Os = {}, Ds = {
2644
2644
  "stroke-linejoin": "round"
2645
2645
  };
2646
2646
  function Us(s, e) {
2647
- return i(), c("svg", Ds, [...e[0] || (e[0] = [
2647
+ return i(), c("svg", Ds, e[0] || (e[0] = [
2648
2648
  l("path", { d: "m3 16 4 4 4-4" }, null, -1),
2649
2649
  l("path", { d: "M7 20V4" }, null, -1),
2650
2650
  l("path", { d: "m21 8-4-4-4 4" }, null, -1),
2651
2651
  l("path", { d: "M17 4v16" }, null, -1)
2652
- ])]);
2652
+ ]));
2653
2653
  }
2654
2654
  const Rs = /* @__PURE__ */ J(Os, [["render", Us]]), Ps = {}, Hs = {
2655
2655
  xmlns: "http://www.w3.org/2000/svg",
@@ -2663,7 +2663,7 @@ const Rs = /* @__PURE__ */ J(Os, [["render", Us]]), Ps = {}, Hs = {
2663
2663
  "stroke-linejoin": "round"
2664
2664
  };
2665
2665
  function Ns(s, e) {
2666
- return i(), c("svg", Hs, [...e[0] || (e[0] = [
2666
+ return i(), c("svg", Hs, e[0] || (e[0] = [
2667
2667
  l("path", {
2668
2668
  stroke: "none",
2669
2669
  d: "M0 0h24v24H0z",
@@ -2672,7 +2672,7 @@ function Ns(s, e) {
2672
2672
  l("path", { d: "M4 17v2a2 2 0 0 0 2 2h12a2 2 0 0 0 2 -2v-2" }, null, -1),
2673
2673
  l("path", { d: "M7 9l5 -5l5 5" }, null, -1),
2674
2674
  l("path", { d: "M12 4l0 12" }, null, -1)
2675
- ])]);
2675
+ ]));
2676
2676
  }
2677
2677
  const Gs = /* @__PURE__ */ J(Ps, [["render", Ns]]), Ks = {}, qs = {
2678
2678
  xmlns: "http://www.w3.org/2000/svg",
@@ -2684,7 +2684,7 @@ const Gs = /* @__PURE__ */ J(Ps, [["render", Ns]]), Ks = {}, qs = {
2684
2684
  "stroke-linejoin": "round"
2685
2685
  };
2686
2686
  function Zs(s, e) {
2687
- return i(), c("svg", qs, [...e[0] || (e[0] = [
2687
+ return i(), c("svg", qs, e[0] || (e[0] = [
2688
2688
  l("path", {
2689
2689
  stroke: "none",
2690
2690
  d: "M0 0h24v24H0z",
@@ -2693,7 +2693,7 @@ function Zs(s, e) {
2693
2693
  l("path", { d: "M4 17v2a2 2 0 0 0 2 2h12a2 2 0 0 0 2 -2v-2" }, null, -1),
2694
2694
  l("path", { d: "M7 11l5 5l5 -5" }, null, -1),
2695
2695
  l("path", { d: "M12 4l0 12" }, null, -1)
2696
- ])]);
2696
+ ]));
2697
2697
  }
2698
2698
  const Ws = /* @__PURE__ */ J(Ks, [["render", Zs]]), Js = {}, Ys = {
2699
2699
  xmlns: "http://www.w3.org/2000/svg",
@@ -2705,9 +2705,9 @@ const Ws = /* @__PURE__ */ J(Ks, [["render", Zs]]), Js = {}, Ys = {
2705
2705
  "stroke-linejoin": "round"
2706
2706
  };
2707
2707
  function Xs(s, e) {
2708
- return i(), c("svg", Ys, [...e[0] || (e[0] = [
2708
+ return i(), c("svg", Ys, e[0] || (e[0] = [
2709
2709
  xe('<circle cx="9" cy="12" r="1"></circle><circle cx="9" cy="5" r="1"></circle><circle cx="9" cy="19" r="1"></circle><circle cx="15" cy="12" r="1"></circle><circle cx="15" cy="5" r="1"></circle><circle cx="15" cy="19" r="1"></circle>', 6)
2710
- ])]);
2710
+ ]));
2711
2711
  }
2712
2712
  const It = /* @__PURE__ */ J(Js, [["render", Xs]]), Qs = {}, en = {
2713
2713
  viewBox: "0 0 178 90",
@@ -2715,9 +2715,9 @@ const It = /* @__PURE__ */ J(Js, [["render", Xs]]), Qs = {}, en = {
2715
2715
  xmlns: "http://www.w3.org/2000/svg"
2716
2716
  };
2717
2717
  function tn(s, e) {
2718
- return i(), c("svg", en, [...e[0] || (e[0] = [
2718
+ return i(), c("svg", en, e[0] || (e[0] = [
2719
2719
  xe('<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)
2720
- ])]);
2720
+ ]));
2721
2721
  }
2722
2722
  const ln = /* @__PURE__ */ J(Qs, [["render", tn]]), on = {}, an = {
2723
2723
  xmlns: "http://www.w3.org/2000/svg",
@@ -2729,11 +2729,11 @@ const ln = /* @__PURE__ */ J(Qs, [["render", tn]]), on = {}, an = {
2729
2729
  "stroke-linejoin": "round"
2730
2730
  };
2731
2731
  function sn(s, e) {
2732
- return i(), c("svg", an, [...e[0] || (e[0] = [
2732
+ return i(), c("svg", an, e[0] || (e[0] = [
2733
2733
  l("path", { d: "M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z" }, null, -1)
2734
- ])]);
2734
+ ]));
2735
2735
  }
2736
- const nn = /* @__PURE__ */ J(on, [["render", sn]]), rn = { class: "vs-datatable border rounded-xl w-full flex-grow" }, un = { class: "flex items-center npm gap-[16px] justify-between p-[20px] pb-[16px]" }, dn = { class: "relative w-full" }, cn = { class: "table-wrapper flex gap-2" }, pn = { class: "vs-popover inline-block text-slate-700" }, fn = { class: "text-center" }, vn = { class: "" }, mn = { class: "py-1 px-0 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 dark:bg-neutral-900 dark:text-neutral-200 dark:focus:bg-neutral-800 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" }, hn = { class: "flex flex-col p-[1px] gap-[2px] w-[140px]" }, gn = { class: "text-sm items-center text-gray-800 flex gap-1" }, yn = { class: "w-full overflow-x-auto" }, bn = { class: "w-full table-auto caption-bottom text-sm" }, xn = { class: "[&_tr]:border-b" }, wn = { class: "border-b data-[state=selected]:bg-muted bg-slate-50/50 dark:bg-slate-700/50 hover:bg-slate-50/80 dark:hover:bg-slate-700/80 transition-colors" }, kn = { class: "h-10 px-2 align-middle font-medium text-muted-foreground [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px] w-12 text-center" }, _n = {
2736
+ const nn = /* @__PURE__ */ J(on, [["render", sn]]), rn = { class: "vs-datatable border rounded-xl w-full flex-grow" }, un = { class: "flex items-center npm gap-[16px] justify-between p-[20px] pb-[16px]" }, dn = { class: "relative w-full" }, cn = { class: "table-wrapper flex gap-2" }, pn = { class: "vs-popover inline-block text-slate-700" }, fn = { class: "text-center" }, vn = { class: "" }, mn = { class: "py-1 px-0 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 dark:bg-neutral-900 dark:text-neutral-200 dark:focus:bg-neutral-800 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" }, hn = { class: "flex flex-col p-[1px] gap-[2px] w-[140px]" }, gn = { class: "text-sm items-center text-gray-800 flex gap-1" }, bn = { class: "w-full overflow-x-auto" }, yn = { class: "w-full table-auto caption-bottom text-sm" }, xn = { class: "[&_tr]:border-b" }, wn = { class: "border-b data-[state=selected]:bg-muted bg-slate-50/50 dark:bg-slate-700/50 hover:bg-slate-50/80 dark:hover:bg-slate-700/80 transition-colors" }, kn = { class: "h-10 px-2 align-middle font-medium text-muted-foreground [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px] w-12 text-center" }, _n = {
2737
2737
  key: 0,
2738
2738
  colspan: "100%",
2739
2739
  class: "text-center"
@@ -2787,7 +2787,7 @@ const nn = /* @__PURE__ */ J(on, [["render", sn]]), rn = { class: "vs-datatable
2787
2787
  }, M = (G) => {
2788
2788
  const D = G.currentTarget.getBoundingClientRect();
2789
2789
  _.value = { top: D.bottom + window.scrollY, left: D.left + window.scrollX }, f.value = !f.value;
2790
- }, y = () => {
2790
+ }, b = () => {
2791
2791
  v.value && v.value.click();
2792
2792
  }, x = (G) => {
2793
2793
  const O = [".jpg", ".jpeg", ".png", ".gif", ".bmp", ".webp", ".svg", ".ico", ".tiff", ".tif"], D = G.toLowerCase();
@@ -2811,7 +2811,7 @@ const nn = /* @__PURE__ */ J(on, [["render", sn]]), rn = { class: "vs-datatable
2811
2811
  const G = JSON.stringify(t.value, null, 2), O = new Blob([G], { type: "application/json" }), D = URL.createObjectURL(O), W = document.createElement("a");
2812
2812
  W.href = D, W.download = "data.json", W.click(), URL.revokeObjectURL(D);
2813
2813
  };
2814
- be(async () => {
2814
+ ye(async () => {
2815
2815
  const G = e.colModel?.filter((O) => O.data);
2816
2816
  G?.length && Promise.all(G.map(async (O) => {
2817
2817
  const W = await (await fetch(`/api/suggest/${O.data}`)).json();
@@ -2892,12 +2892,12 @@ const nn = /* @__PURE__ */ J(on, [["render", sn]]), rn = { class: "vs-datatable
2892
2892
  f.value ? (i(), c("div", {
2893
2893
  key: 0,
2894
2894
  class: "text-slate-700 vsTailwind vs-popover__content bottom",
2895
- style: ye([{ width: "fit-content", "z-index": "10002", position: "fixed" }, { position: "absolute", top: _.value.top + "px", left: _.value.left + "px" }])
2895
+ style: be([{ width: "fit-content", "z-index": "10002", position: "fixed" }, { position: "absolute", top: _.value.top + "px", left: _.value.left + "px" }])
2896
2896
  }, [
2897
2897
  l("div", mn, [
2898
2898
  l("div", hn, [
2899
2899
  l("button", {
2900
- onClick: y,
2900
+ onClick: b,
2901
2901
  class: "text-slate-700 flex items-center gap-1 px-3 py-2 rounded-md cursor-pointer group hover:bg-gray-100"
2902
2902
  }, [
2903
2903
  P(Gs, {
@@ -2932,8 +2932,8 @@ const nn = /* @__PURE__ */ J(on, [["render", sn]]), rn = { class: "vs-datatable
2932
2932
  O[6] || (O[6] = he(" Додати ", -1))
2933
2933
  ])
2934
2934
  ]),
2935
- l("div", yn, [
2936
- l("table", bn, [
2935
+ l("div", bn, [
2936
+ l("table", yn, [
2937
2937
  l("thead", xn, [
2938
2938
  l("tr", wn, [
2939
2939
  l("th", kn, [
@@ -3182,7 +3182,7 @@ const nn = /* @__PURE__ */ J(on, [["render", sn]]), rn = { class: "vs-datatable
3182
3182
  class: "icon icon-tabler icons-tabler-outline icon-tabler-map-pin"
3183
3183
  };
3184
3184
  function Gn(s, e) {
3185
- return i(), c("svg", Nn, [...e[0] || (e[0] = [
3185
+ return i(), c("svg", Nn, e[0] || (e[0] = [
3186
3186
  l("path", {
3187
3187
  stroke: "none",
3188
3188
  d: "M0 0h24v24H0z",
@@ -3190,7 +3190,7 @@ function Gn(s, e) {
3190
3190
  }, null, -1),
3191
3191
  l("path", { d: "M9 11a3 3 0 1 0 6 0a3 3 0 0 0 -6 0" }, null, -1),
3192
3192
  l("path", { d: "M17.657 16.657l-4.243 4.243a2 2 0 0 1 -2.827 0l-4.244 -4.243a8 8 0 1 1 11.314 0z" }, null, -1)
3193
- ])]);
3193
+ ]));
3194
3194
  }
3195
3195
  const Kn = /* @__PURE__ */ J(Hn, [["render", Gn]]), qn = {}, Zn = {
3196
3196
  xmlns: "http://www.w3.org/2000/svg",
@@ -3203,7 +3203,7 @@ const Kn = /* @__PURE__ */ J(Hn, [["render", Gn]]), qn = {}, Zn = {
3203
3203
  class: "icon icon-tabler icons-tabler-outline icon-tabler-line"
3204
3204
  };
3205
3205
  function Wn(s, e) {
3206
- return i(), c("svg", Zn, [...e[0] || (e[0] = [
3206
+ return i(), c("svg", Zn, e[0] || (e[0] = [
3207
3207
  l("path", {
3208
3208
  stroke: "none",
3209
3209
  d: "M0 0h24v24H0z",
@@ -3212,7 +3212,7 @@ function Wn(s, e) {
3212
3212
  l("path", { d: "M6 18m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0" }, null, -1),
3213
3213
  l("path", { d: "M18 6m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0" }, null, -1),
3214
3214
  l("path", { d: "M7.5 16.5l9 -9" }, null, -1)
3215
- ])]);
3215
+ ]));
3216
3216
  }
3217
3217
  const Jn = /* @__PURE__ */ J(qn, [["render", Wn]]), Yn = {}, Xn = {
3218
3218
  xmlns: "http://www.w3.org/2000/svg",
@@ -3225,9 +3225,9 @@ const Jn = /* @__PURE__ */ J(qn, [["render", Wn]]), Yn = {}, Xn = {
3225
3225
  class: "icon icon-tabler icons-tabler-outline icon-tabler-polygon"
3226
3226
  };
3227
3227
  function Qn(s, e) {
3228
- return i(), c("svg", Xn, [...e[0] || (e[0] = [
3228
+ return i(), c("svg", Xn, e[0] || (e[0] = [
3229
3229
  xe('<path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M12 5m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0"></path><path d="M19 8m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0"></path><path d="M5 11m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0"></path><path d="M15 19m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0"></path><path d="M6.5 9.5l3.5 -3"></path><path d="M14 5.5l3 1.5"></path><path d="M18.5 10l-2.5 7"></path><path d="M13.5 17.5l-7 -5"></path>', 9)
3230
- ])]);
3230
+ ]));
3231
3231
  }
3232
3232
  const er = /* @__PURE__ */ J(Yn, [["render", Qn]]), tr = {}, lr = {
3233
3233
  xmlns: "http://www.w3.org/2000/svg",
@@ -3240,9 +3240,9 @@ const er = /* @__PURE__ */ J(Yn, [["render", Qn]]), tr = {}, lr = {
3240
3240
  class: "icon icon-tabler icons-tabler-outline icon-tabler-topology-ring-3"
3241
3241
  };
3242
3242
  function or(s, e) {
3243
- return i(), c("svg", lr, [...e[0] || (e[0] = [
3243
+ return i(), c("svg", lr, e[0] || (e[0] = [
3244
3244
  xe('<path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M8 18a2 2 0 1 0 -4 0a2 2 0 0 0 4 0z"></path><path d="M20 18a2 2 0 1 0 -4 0a2 2 0 0 0 4 0z"></path><path d="M20 6a2 2 0 1 0 -4 0a2 2 0 0 0 4 0z"></path><path d="M8 6a2 2 0 1 0 -4 0a2 2 0 0 0 4 0z"></path><path d="M6 8v8"></path><path d="M18 16v-8"></path><path d="M8 6h8"></path><path d="M16 18h-8"></path>', 9)
3245
- ])]);
3245
+ ]));
3246
3246
  }
3247
3247
  const ar = /* @__PURE__ */ J(tr, [["render", or]]), sr = {}, nr = {
3248
3248
  version: "1.1",
@@ -3253,7 +3253,7 @@ const ar = /* @__PURE__ */ J(tr, [["render", or]]), sr = {}, nr = {
3253
3253
  class: "fullscreen-icon"
3254
3254
  };
3255
3255
  function rr(s, e) {
3256
- return i(), c("svg", nr, [...e[0] || (e[0] = [
3256
+ return i(), c("svg", nr, e[0] || (e[0] = [
3257
3257
  l("title", null, null, -1),
3258
3258
  l("desc", null, null, -1),
3259
3259
  l("defs", null, null, -1),
@@ -3280,7 +3280,7 @@ function rr(s, e) {
3280
3280
  ])
3281
3281
  ])
3282
3282
  ], -1)
3283
- ])]);
3283
+ ]));
3284
3284
  }
3285
3285
  const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-widget flex flex-col gap-2 rounded-xl widget min-w-[200px]" }, dr = {
3286
3286
  key: 0,
@@ -3311,7 +3311,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3311
3311
  const $ = _.value;
3312
3312
  $ && !$.contains(h.target) && (v.value = !1);
3313
3313
  }
3314
- be(() => {
3314
+ ye(() => {
3315
3315
  window.addEventListener("click", j, !0);
3316
3316
  }), ct(() => {
3317
3317
  window.removeEventListener("click", j, !0);
@@ -3335,7 +3335,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3335
3335
  return null;
3336
3336
  return { lat: N, lng: R };
3337
3337
  }
3338
- function y(h) {
3338
+ function b(h) {
3339
3339
  return (h?.items || []).map((I, A) => ({
3340
3340
  id: String(I?.id ?? A),
3341
3341
  title: I?.title || I?.address?.label || "Знайдений обʼєкт",
@@ -3392,7 +3392,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3392
3392
  }
3393
3393
  const I = await fetch($.toString());
3394
3394
  if (!I.ok) throw new Error(`HTTP ${I.status}`);
3395
- const A = await I.json(), q = p.value === "here" ? y(A) : x(A);
3395
+ const A = await I.json(), q = p.value === "here" ? b(A) : x(A);
3396
3396
  if (!q.length)
3397
3397
  de({ type: "warning", title: "Пошук", message: "Не знайдено результатів" });
3398
3398
  else {
@@ -3427,7 +3427,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3427
3427
  viewBox: "0 0 24 24",
3428
3428
  fill: "none",
3429
3429
  xmlns: "http://www.w3.org/2000/svg"
3430
- }, [...$[2] || ($[2] = [
3430
+ }, $[2] || ($[2] = [
3431
3431
  l("path", {
3432
3432
  d: "M6 9l6 6 6-6",
3433
3433
  stroke: "currentColor",
@@ -3435,7 +3435,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3435
3435
  "stroke-linecap": "round",
3436
3436
  "stroke-linejoin": "round"
3437
3437
  }, null, -1)
3438
- ])], 2))
3438
+ ]), 2))
3439
3439
  ]),
3440
3440
  v.value ? (i(), c("div", dr, [
3441
3441
  l("ul", null, [
@@ -3485,7 +3485,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3485
3485
  ], 32)
3486
3486
  ]));
3487
3487
  }
3488
- }), gr = /* @__PURE__ */ J(hr, [["__scopeId", "data-v-c5cab151"]]), yr = { class: "bg-white/30 p-1 rounded-md shadow w-fit" }, br = { class: "flex gap-2" }, xr = ["onClick", "title"], wr = ["src"], kr = /* @__PURE__ */ Z({
3488
+ }), gr = /* @__PURE__ */ J(hr, [["__scopeId", "data-v-3048520a"]]), br = { class: "bg-white/30 p-1 rounded-md shadow w-fit" }, yr = { class: "flex gap-2" }, xr = ["onClick", "title"], wr = ["src"], kr = /* @__PURE__ */ Z({
3489
3489
  __name: "map-layers",
3490
3490
  props: {
3491
3491
  basemaps: {}
@@ -3496,8 +3496,8 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3496
3496
  function r(d) {
3497
3497
  n("onLayerChange", d), o.value = d;
3498
3498
  }
3499
- return (d, p) => (i(), c("div", yr, [
3500
- l("div", br, [
3499
+ return (d, p) => (i(), c("div", br, [
3500
+ l("div", yr, [
3501
3501
  (i(!0), c(ae, null, ie(d.basemaps, (f, v) => (i(), c("div", {
3502
3502
  key: v,
3503
3503
  class: U(["cursor-pointer border rounded-lg overflow-hidden hover:shadow-sm", { "ring-2 ring-blue-500 border-blue-300": o.value === v }]),
@@ -3557,10 +3557,10 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3557
3557
  },
3558
3558
  emits: ["update:modelValue"],
3559
3559
  setup(s, { emit: e }) {
3560
- const o = Jt()?.appContext?.config?.globalProperties?.$settings ?? {}, n = Array.isArray(o.center) && o.center.length === 2 ? o.center : [50, 30], r = typeof o.zoom == "number" ? o.zoom : typeof o.defaultZoom == "number" ? o.defaultZoom : 10, d = s, p = e, f = L(() => !!d.disabled), v = S(!1), _ = S(null), w = S(!1), j = S(""), k = S(null), M = S(null), y = S(!1), x = S(null), g = S(null), m = S(0), C = S(n), h = S(r), $ = S(null), I = L(() => {
3560
+ const o = Jt()?.appContext?.config?.globalProperties?.$settings ?? {}, n = Array.isArray(o.center) && o.center.length === 2 ? o.center : [50, 30], r = typeof o.zoom == "number" ? o.zoom : typeof o.defaultZoom == "number" ? o.defaultZoom : 10, d = s, p = e, f = L(() => !!d.disabled), v = S(!1), _ = S(null), w = S(!1), j = S(""), k = S(null), M = S(null), b = S(!1), x = S(null), g = S(null), m = S(0), C = S(n), h = S(r), $ = S(null), I = L(() => {
3561
3561
  const a = { search: !1, import: !1, export: !1, point: !1, line: !1, polygon: !1, rectangle: !1 };
3562
3562
  if (!d.tools?.length) return a;
3563
- const u = new Set(d.tools.map((b) => b.toLowerCase()));
3563
+ const u = new Set(d.tools.map((y) => y.toLowerCase()));
3564
3564
  return {
3565
3565
  search: u.has("search"),
3566
3566
  import: u.has("import"),
@@ -3572,23 +3572,23 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3572
3572
  };
3573
3573
  }), A = Ut({}), q = S([]), Y = L(() => q.value.map((a) => A[a]).filter(Boolean)), N = S(null), R = L(() => N.value?.title || N.value?.layerId || ""), Q = L(() => N.value?.entries ?? []), ee = L(() => {
3574
3574
  if (!N.value) return;
3575
- const a = 12, u = N.value.point.x + a, b = N.value.point.y + a;
3576
- return { left: `${u}px`, top: `${b}px` };
3575
+ const a = 12, u = N.value.point.x + a, y = N.value.point.y + a;
3576
+ return { left: `${u}px`, top: `${y}px` };
3577
3577
  });
3578
3578
  function oe(a) {
3579
3579
  if (typeof a != "string" || !a.trim()) return "";
3580
3580
  if (/^https?:\/\//i.test(a)) return a;
3581
- const u = window?.location?.origin ?? "", b = a.replace(/^\/+/, "");
3582
- return b ? u ? `${u}/${b}` : `/${b}` : u;
3581
+ const u = window?.location?.origin ?? "", y = a.replace(/^\/+/, "");
3582
+ return y ? u ? `${u}/${y}` : `/${y}` : u;
3583
3583
  }
3584
3584
  function G() {
3585
3585
  if (Array.isArray(o.basemaps) && o.basemaps.length) {
3586
- const u = o.basemaps.map((b, E) => {
3587
- const z = String(b?.key ?? b?.id ?? b?.name ?? `b${E}`), K = oe(String(b?.url ?? ""));
3586
+ const u = o.basemaps.map((y, E) => {
3587
+ const z = String(y?.key ?? y?.id ?? y?.name ?? `b${E}`), K = oe(String(y?.url ?? ""));
3588
3588
  if (!K) return null;
3589
- const se = typeof b?.preview == "string" && b.preview ? oe(b.preview) : "";
3590
- return [z, { ...b, url: K, preview: se }];
3591
- }).filter((b) => Array.isArray(b) && b.length === 2).reduce((b, [E, z]) => (b[E] = z, b), {});
3589
+ const se = typeof y?.preview == "string" && y.preview ? oe(y.preview) : "";
3590
+ return [z, { ...y, url: K, preview: se }];
3591
+ }).filter((y) => Array.isArray(y) && y.length === 2).reduce((y, [E, z]) => (y[E] = z, y), {});
3592
3592
  if (Object.keys(u).length) return u;
3593
3593
  }
3594
3594
  return {
@@ -3655,18 +3655,18 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3655
3655
  return;
3656
3656
  }
3657
3657
  E.preventDefault(), E.stopPropagation(), w.value = !1, T.scrollWheelZoom.enable(), setTimeout(() => T.scrollWheelZoom.disable(), 120);
3658
- }, b = (E) => {
3658
+ }, y = (E) => {
3659
3659
  if (E.touches.length === 1) {
3660
3660
  if (!d.ctrlZoom) return;
3661
3661
  w.value = !0, j.value = Me(), clearTimeout(a), a = window.setTimeout(() => w.value = !1, 3e3);
3662
3662
  } else
3663
3663
  w.value = !1;
3664
3664
  };
3665
- return _.value.addEventListener("wheel", u, { passive: !1 }), _.value.addEventListener("touchstart", b, { passive: !0 }), T.on("wheel", (E) => {
3665
+ return _.value.addEventListener("wheel", u, { passive: !1 }), _.value.addEventListener("touchstart", y, { passive: !0 }), T.on("wheel", (E) => {
3666
3666
  if (!d.ctrlZoom) return;
3667
3667
  E.originalEvent?.ctrlKey || E.originalEvent?.metaKey || E.originalEvent?.shiftKey || (E.originalEvent?.preventDefault?.(), E.originalEvent?.stopPropagation?.());
3668
3668
  }), () => {
3669
- _.value?.removeEventListener("wheel", u), _.value?.removeEventListener("touchstart", b), clearTimeout(a);
3669
+ _.value?.removeEventListener("wheel", u), _.value?.removeEventListener("touchstart", y), clearTimeout(a);
3670
3670
  };
3671
3671
  }
3672
3672
  function ft(a, u) {
@@ -3676,13 +3676,13 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3676
3676
  const u = (a?.url ?? "").trim();
3677
3677
  if (!u) return "";
3678
3678
  if (/^https?:\/\//i.test(u)) return u;
3679
- const b = window.location?.origin ?? "", E = u.replace(/^\/+/, "");
3680
- return `${b}/${E}`;
3679
+ const y = window.location?.origin ?? "", E = u.replace(/^\/+/, "");
3680
+ return `${y}/${E}`;
3681
3681
  }
3682
3682
  function Ye(a) {
3683
3683
  const u = a?.style ?? {};
3684
- return (b) => {
3685
- const E = u.colorAttr, z = u.colorSet ?? {}, K = typeof E == "string" ? z?.[b?.[E]] ?? u.color ?? "#3388ff" : u.color ?? "#3388ff", se = u.stroke ?? K;
3684
+ return (y) => {
3685
+ const E = u.colorAttr, z = u.colorSet ?? {}, K = typeof E == "string" ? z?.[y?.[E]] ?? u.color ?? "#3388ff" : u.color ?? "#3388ff", se = u.stroke ?? K;
3686
3686
  return {
3687
3687
  weight: u.width ?? 1,
3688
3688
  color: se,
@@ -3697,15 +3697,15 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3697
3697
  return a?.layer?.properties || a?.layer?.feature?.properties || a?.properties || {};
3698
3698
  }
3699
3699
  function mt(a, u = {}) {
3700
- return a.popup === !1 ? [] : Array.isArray(a.popup) && a.popup.length ? a.popup.map((b) => {
3701
- if (!b?.field) return null;
3702
- const E = u[b.field];
3703
- return E == null || E === "" ? null : { key: b.label || b.field, value: String(E) };
3704
- }).filter((b) => !!b) : Object.entries(u).filter(([b]) => typeof b == "string" && b).slice(0, 5).map(([b, E]) => ({ key: b, value: E == null ? "—" : String(E) }));
3700
+ return a.popup === !1 ? [] : Array.isArray(a.popup) && a.popup.length ? a.popup.map((y) => {
3701
+ if (!y?.field) return null;
3702
+ const E = u[y.field];
3703
+ return E == null || E === "" ? null : { key: y.label || y.field, value: String(E) };
3704
+ }).filter((y) => !!y) : Object.entries(u).filter(([y]) => typeof y == "string" && y).slice(0, 5).map(([y, E]) => ({ key: y, value: E == null ? "—" : String(E) }));
3705
3705
  }
3706
3706
  function ze(a, u) {
3707
3707
  if (!T || !u?.latlng) return;
3708
- const b = T.latLngToContainerPoint(u.latlng), E = Ge(u), z = mt(a, E);
3708
+ const y = T.latLngToContainerPoint(u.latlng), E = Ge(u), z = mt(a, E);
3709
3709
  if (!z.length) {
3710
3710
  Le(a.id);
3711
3711
  return;
@@ -3715,18 +3715,18 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3715
3715
  title: E?.name || a.title || a.name,
3716
3716
  properties: E,
3717
3717
  entries: z,
3718
- point: { x: b.x, y: b.y }
3718
+ point: { x: y.x, y: y.y }
3719
3719
  };
3720
3720
  }
3721
3721
  function Le(a) {
3722
3722
  a && N.value?.layerId !== a || (N.value = null);
3723
3723
  }
3724
3724
  function Fe(a) {
3725
- const u = (a?.service ?? "").toLowerCase(), b = vt(a), E = a.sourceLayer || a.layer || a.service_layer || a.service_key || a.map_key || a.dataset?.layer || a.id || a.table_name;
3725
+ const u = (a?.service ?? "").toLowerCase(), y = vt(a), E = a.sourceLayer || a.layer || a.service_layer || a.service_key || a.map_key || a.dataset?.layer || a.id || a.table_name;
3726
3726
  if (u === "vtile") {
3727
3727
  const z = $.value;
3728
3728
  if (z?.vectorGrid?.protobuf && !z?.maplibreGL) {
3729
- const K = z.vectorGrid.protobuf(b, {
3729
+ const K = z.vectorGrid.protobuf(y, {
3730
3730
  interactive: !0,
3731
3731
  maxNativeZoom: a.maxzoom ?? 19,
3732
3732
  vectorTileLayerStyles: {
@@ -3738,7 +3738,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3738
3738
  return K?.on?.("mouseover", (se) => ze(a, se)), K?.on?.("mousemove", (se) => ze(a, se)), K?.on?.("mouseout", () => Le(a.id)), K;
3739
3739
  }
3740
3740
  if (z?.maplibreGL && window?.maplibregl) {
3741
- const K = b;
3741
+ const K = y;
3742
3742
  return K ? z.maplibreGL({
3743
3743
  style: K,
3744
3744
  interactive: !1,
@@ -3747,10 +3747,10 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3747
3747
  }
3748
3748
  return null;
3749
3749
  }
3750
- return u === "tile" || /^https?:\/\//i.test(b) || b.includes("{z}") ? $.value.tileLayer(b, {
3750
+ return u === "tile" || /^https?:\/\//i.test(y) || y.includes("{z}") ? $.value.tileLayer(y, {
3751
3751
  opacity: a?.style?.opacity ?? 1,
3752
3752
  pane: ut
3753
- }) : $.value.tileLayer(b, {
3753
+ }) : $.value.tileLayer(y, {
3754
3754
  opacity: a?.style?.opacity ?? 1,
3755
3755
  pane: ut
3756
3756
  });
@@ -3758,15 +3758,15 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3758
3758
  function Ke(a) {
3759
3759
  const u = $.value;
3760
3760
  if (!u) return null;
3761
- const b = ("bounds" in a ? a.bounds : void 0) ?? d.bounds;
3762
- if (!Array.isArray(b) || !b.length) return null;
3761
+ const y = ("bounds" in a ? a.bounds : void 0) ?? d.bounds;
3762
+ if (!Array.isArray(y) || !y.length) return null;
3763
3763
  const z = {
3764
3764
  color: a.style?.stroke ?? a.style?.color ?? "#2563eb",
3765
3765
  weight: a.style?.width ?? 2,
3766
3766
  interactive: !1,
3767
3767
  opacity: a.style?.opacity ?? 0.8,
3768
3768
  dashArray: "4 4"
3769
- }, K = Array.isArray(a.bounds) && a.bounds.length ? a.bounds : b, se = Xe(K);
3769
+ }, K = Array.isArray(a.bounds) && a.bounds.length ? a.bounds : y, se = Xe(K);
3770
3770
  if (!se.length || !u?.polyline)
3771
3771
  return null;
3772
3772
  const ce = se.map((fe) => {
@@ -3779,16 +3779,16 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3779
3779
  function Xe(a) {
3780
3780
  const u = $.value;
3781
3781
  if (!u || !Array.isArray(a)) return [];
3782
- const b = (z) => {
3782
+ const y = (z) => {
3783
3783
  if (!Array.isArray(z) || z.length < 2) return null;
3784
3784
  const [K, se] = z;
3785
3785
  return !Number.isFinite(Number(se)) || !Number.isFinite(Number(K)) ? null : u.latLng(Number(se), Number(K));
3786
3786
  }, E = (z) => Array.isArray(z) && z.length >= 2 && z.every((K) => Number.isFinite(Number(K)));
3787
3787
  if (a.length && E(a[0])) {
3788
- const z = a.map(b).filter(Boolean);
3788
+ const z = a.map(y).filter(Boolean);
3789
3789
  return z.length ? [z] : [];
3790
3790
  }
3791
- return a.length && Array.isArray(a[0]) && E(a[0][0]) ? a.map((K) => Array.isArray(K) ? K.map(b).filter(Boolean) : []).filter((K) => K.length) : [];
3791
+ return a.length && Array.isArray(a[0]) && E(a[0][0]) ? a.map((K) => Array.isArray(K) ? K.map(y).filter(Boolean) : []).filter((K) => K.length) : [];
3792
3792
  }
3793
3793
  function qe() {
3794
3794
  if (!T || !$.value) return;
@@ -3814,11 +3814,11 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3814
3814
  te(
3815
3815
  () => d.layers,
3816
3816
  (a) => {
3817
- const u = Array.isArray(a) ? a : [], b = [], E = /* @__PURE__ */ new Set();
3817
+ const u = Array.isArray(a) ? a : [], y = [], E = /* @__PURE__ */ new Set();
3818
3818
  u.forEach((z, K) => {
3819
3819
  if (!z) return;
3820
3820
  const se = ft(z, K);
3821
- b.push(se), E.add(se);
3821
+ y.push(se), E.add(se);
3822
3822
  const ce = A[se], fe = { ...z, id: se }, Ce = ce?.visible ?? fe?.overlay !== !1;
3823
3823
  ce && (ce.layer && T?.hasLayer(ce.layer) && T.removeLayer(ce.layer), ce.boundsLayer && T?.hasLayer(ce.boundsLayer) && T.removeLayer(ce.boundsLayer), Le(se)), A[se] = {
3824
3824
  id: se,
@@ -3832,7 +3832,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3832
3832
  const K = A[z];
3833
3833
  K?.layer && T?.hasLayer(K.layer) && T.removeLayer(K.layer), K?.boundsLayer && T?.hasLayer(K.boundsLayer) && T.removeLayer(K.boundsLayer), Le(z), delete A[z];
3834
3834
  }
3835
- }), q.value = b, Re();
3835
+ }), q.value = y, Re();
3836
3836
  },
3837
3837
  { immediate: !0, deep: !0 }
3838
3838
  ), te(
@@ -3851,12 +3851,12 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3851
3851
  function tt(a) {
3852
3852
  const u = $.value;
3853
3853
  if (a instanceof u.Circle) {
3854
- const b = a.getRadius();
3855
- return Math.PI * (b * b) / 1e6;
3854
+ const y = a.getRadius();
3855
+ return Math.PI * (y * y) / 1e6;
3856
3856
  }
3857
3857
  if (a instanceof u.Polygon || a instanceof u.Rectangle)
3858
3858
  try {
3859
- const b = a.getLatLngs(), E = Array.isArray(b[0]) ? b[0] : b, z = u.GeometryUtil?.geodesicArea ? u.GeometryUtil.geodesicArea(E) : 0;
3859
+ const y = a.getLatLngs(), E = Array.isArray(y[0]) ? y[0] : y, z = u.GeometryUtil?.geodesicArea ? u.GeometryUtil.geodesicArea(E) : 0;
3860
3860
  return z ? z / 1e6 : 0;
3861
3861
  } catch {
3862
3862
  return null;
@@ -3868,12 +3868,12 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3868
3868
  }
3869
3869
  function Oe() {
3870
3870
  const a = ve.toGeoJSON(), u = [];
3871
- let b = null;
3871
+ let y = null;
3872
3872
  const E = (K) => {
3873
3873
  if (K)
3874
3874
  switch (K.type) {
3875
3875
  case "Point":
3876
- b = K;
3876
+ y = K;
3877
3877
  break;
3878
3878
  case "Polygon":
3879
3879
  u.push(K.coordinates);
@@ -3887,7 +3887,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3887
3887
  }
3888
3888
  };
3889
3889
  (a?.features || []).forEach((K) => E(K.geometry));
3890
- const z = b || (u.length ? { type: "MultiPolygon", coordinates: u } : null);
3890
+ const z = y || (u.length ? { type: "MultiPolygon", coordinates: u } : null);
3891
3891
  p("update:modelValue", z), m.value = ve.getLayers().length;
3892
3892
  }
3893
3893
  function Se() {
@@ -3896,8 +3896,8 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3896
3896
  M.value = null, m.value = 0;
3897
3897
  return;
3898
3898
  }
3899
- const u = a[a.length - 1], b = et(u), E = lt(u), z = tt(u);
3900
- M.value = { type: b, center: E, areaKm2: z, layer: u }, m.value = a.length;
3899
+ const u = a[a.length - 1], y = et(u), E = lt(u), z = tt(u);
3900
+ M.value = { type: y, center: E, areaKm2: z, layer: u }, m.value = a.length;
3901
3901
  }
3902
3902
  const $e = S("");
3903
3903
  function Ie(a) {
@@ -3934,8 +3934,8 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3934
3934
  }
3935
3935
  function gt(a) {
3936
3936
  if (f.value) return;
3937
- const u = a.target, b = u.files?.[0];
3938
- if (!b) return;
3937
+ const u = a.target, y = u.files?.[0];
3938
+ if (!y) return;
3939
3939
  const E = new FileReader();
3940
3940
  E.onload = () => {
3941
3941
  try {
@@ -3944,12 +3944,12 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3944
3944
  } finally {
3945
3945
  u.value = "";
3946
3946
  }
3947
- }, E.readAsText(b);
3947
+ }, E.readAsText(y);
3948
3948
  }
3949
- function yt() {
3949
+ function bt() {
3950
3950
  if (f.value) return;
3951
- const a = ve.toGeoJSON(), u = new Blob([JSON.stringify(a, null, 2)], { type: "application/json" }), b = URL.createObjectURL(u), E = document.createElement("a");
3952
- E.href = b, E.download = "data.geojson", E.click(), URL.revokeObjectURL(b);
3951
+ const a = ve.toGeoJSON(), u = new Blob([JSON.stringify(a, null, 2)], { type: "application/json" }), y = URL.createObjectURL(u), E = document.createElement("a");
3952
+ E.href = y, E.download = "data.geojson", E.click(), URL.revokeObjectURL(y);
3953
3953
  }
3954
3954
  function nt(a) {
3955
3955
  !T || !$.value || !O[a] || (X && T.removeLayer(X), X = $.value.tileLayer(O[a].url, {
@@ -3964,7 +3964,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3964
3964
  T.setView(u, 13);
3965
3965
  }
3966
3966
  let B = null;
3967
- return be(async () => {
3967
+ return ye(async () => {
3968
3968
  $.value = await Ne();
3969
3969
  const a = $.value;
3970
3970
  a.drawLocal = Pn, T = a.map(_.value, { zoomControl: !1, scrollWheelZoom: !1 }).setView(C.value, h.value), a.control.zoom({ position: "bottomright" }).addTo(T);
@@ -3982,9 +3982,9 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3982
3982
  }), T.on(a.Draw.Event.DELETED, () => {
3983
3983
  f.value || (Oe(), Se());
3984
3984
  });
3985
- let b = !1;
3985
+ let y = !1;
3986
3986
  T.on("mousemove", (E) => {
3987
- b || (T.invalidateSize(), b = !0);
3987
+ y || (T.invalidateSize(), y = !0);
3988
3988
  }), T.on("zoomend", () => {
3989
3989
  h.value = T.getZoom();
3990
3990
  }), B = pt(), Re(), qe();
@@ -3994,7 +3994,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
3994
3994
  setTimeout(() => {
3995
3995
  T?.invalidateSize && T.invalidateSize();
3996
3996
  }, 50);
3997
- }), te(y, async (a) => {
3997
+ }), te(b, async (a) => {
3998
3998
  if (!a || !g.value) {
3999
3999
  x.value = null;
4000
4000
  return;
@@ -4050,7 +4050,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4050
4050
  key: 1,
4051
4051
  type: "button",
4052
4052
  class: "inline-flex items-center gap-2 text-sm font-medium border rounded-md px-3 py-2 bg-white text-blue-600 border-stone-200 hover:bg-blue-500 hover:text-white transition",
4053
- onClick: yt,
4053
+ onClick: bt,
4054
4054
  disabled: f.value || m.value === 0
4055
4055
  }, " Export ", 8, Br)) : F("", !0)
4056
4056
  ]),
@@ -4068,17 +4068,17 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4068
4068
  Q.value.length ? (i(), c("div", {
4069
4069
  key: 1,
4070
4070
  class: "absolute z-[1500] pointer-events-none",
4071
- style: ye(ee.value)
4071
+ style: be(ee.value)
4072
4072
  }, [
4073
4073
  l("div", jr, [
4074
4074
  l("div", Er, H(R.value), 1),
4075
4075
  l("dl", Ir, [
4076
- (i(!0), c(ae, null, ie(Q.value, (b) => (i(), c("div", {
4077
- key: `${b.key}-${b.value}`,
4076
+ (i(!0), c(ae, null, ie(Q.value, (y) => (i(), c("div", {
4077
+ key: `${y.key}-${y.value}`,
4078
4078
  class: "flex justify-between gap-2"
4079
4079
  }, [
4080
- l("dt", Tr, H(b.key), 1),
4081
- l("dd", zr, H(b.value), 1)
4080
+ l("dt", Tr, H(y.key), 1),
4081
+ l("dd", zr, H(y.value), 1)
4082
4082
  ]))), 128))
4083
4083
  ])
4084
4084
  ])
@@ -4089,7 +4089,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4089
4089
  key: 0,
4090
4090
  class: U(["vs-btn", { "vs-active": $e.value === "marker" }]),
4091
4091
  title: "Point",
4092
- onClick: u[0] || (u[0] = (b) => Ie("marker")),
4092
+ onClick: u[0] || (u[0] = (y) => Ie("marker")),
4093
4093
  disabled: f.value
4094
4094
  }, [
4095
4095
  P(Kn)
@@ -4098,7 +4098,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4098
4098
  key: 1,
4099
4099
  class: U(["vs-btn", { "vs-active": $e.value === "polyline" }]),
4100
4100
  title: "Line",
4101
- onClick: u[1] || (u[1] = (b) => Ie("polyline")),
4101
+ onClick: u[1] || (u[1] = (y) => Ie("polyline")),
4102
4102
  disabled: f.value
4103
4103
  }, [
4104
4104
  P(Jn)
@@ -4107,7 +4107,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4107
4107
  key: 2,
4108
4108
  class: U(["vs-btn", { "vs-active": $e.value === "polygon" }]),
4109
4109
  title: "Polygon",
4110
- onClick: u[2] || (u[2] = (b) => Ie("polygon")),
4110
+ onClick: u[2] || (u[2] = (y) => Ie("polygon")),
4111
4111
  disabled: f.value
4112
4112
  }, [
4113
4113
  P(er)
@@ -4116,14 +4116,14 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4116
4116
  key: 3,
4117
4117
  class: U(["vs-btn", { "vs-active": $e.value === "rectangle" }]),
4118
4118
  title: "Rectangle",
4119
- onClick: u[3] || (u[3] = (b) => Ie("rectangle")),
4119
+ onClick: u[3] || (u[3] = (y) => Ie("rectangle")),
4120
4120
  disabled: f.value
4121
4121
  }, [
4122
4122
  P(ar)
4123
4123
  ], 10, Pr)) : F("", !0),
4124
4124
  l("button", {
4125
4125
  class: "vs-btn mt-5",
4126
- onClick: u[4] || (u[4] = (b) => v.value = !v.value),
4126
+ onClick: u[4] || (u[4] = (y) => v.value = !v.value),
4127
4127
  title: "Full Screen"
4128
4128
  }, [
4129
4129
  P(ir, { style: { width: "12px", height: "12px" } })
@@ -4141,18 +4141,18 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4141
4141
  Y.value.length ? (i(), c("div", Nr, [
4142
4142
  u[9] || (u[9] = l("p", { class: "font-semibold text-[11px] uppercase tracking-wide text-gray-500 mb-2" }, "Шари", -1)),
4143
4143
  l("div", Gr, [
4144
- (i(!0), c(ae, null, ie(Y.value, (b) => (i(), c("label", {
4145
- key: b.id,
4144
+ (i(!0), c(ae, null, ie(Y.value, (y) => (i(), c("label", {
4145
+ key: y.id,
4146
4146
  class: "flex items-center gap-2 cursor-pointer select-none"
4147
4147
  }, [
4148
4148
  l("input", {
4149
4149
  type: "checkbox",
4150
4150
  class: "rounded border-gray-300 text-blue-600 focus:ring-blue-500",
4151
- checked: b.visible,
4151
+ checked: y.visible,
4152
4152
  disabled: f.value,
4153
- onChange: (E) => Qe(b.id)
4153
+ onChange: (E) => Qe(y.id)
4154
4154
  }, null, 40, Kr),
4155
- l("span", qr, H(b.config.title || b.config.name || b.id), 1)
4155
+ l("span", qr, H(y.config.title || y.config.name || y.id), 1)
4156
4156
  ]))), 128))
4157
4157
  ])
4158
4158
  ])) : F("", !0)
@@ -4162,8 +4162,8 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4162
4162
  M.value ? (i(), c("div", Wr, [
4163
4163
  l("div", {
4164
4164
  class: "mr-auto flex items-center gap-2 min-w-0 relative",
4165
- onMouseenter: u[5] || (u[5] = (b) => y.value = !0),
4166
- onMouseleave: u[6] || (u[6] = (b) => y.value = !1)
4165
+ onMouseenter: u[5] || (u[5] = (y) => b.value = !0),
4166
+ onMouseleave: u[6] || (u[6] = (y) => b.value = !1)
4167
4167
  }, [
4168
4168
  l("div", Jr, [
4169
4169
  u[10] || (u[10] = he(" Type: ", -1)),
@@ -4177,10 +4177,10 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4177
4177
  style: { "max-width": "260px" }
4178
4178
  }, " Address: " + H(k.value), 513)) : F("", !0),
4179
4179
  (i(), pe(We, { to: "body" }, [
4180
- y.value && k.value && x.value ? (i(), c("div", {
4180
+ b.value && k.value && x.value ? (i(), c("div", {
4181
4181
  key: 0,
4182
4182
  class: "fixed z-[99999] pointer-events-none bg-gray-800 text-white text-xs px-2 py-1 rounded shadow whitespace-nowrap",
4183
- style: ye({ top: x.value.top + "px", left: x.value.left + "px" })
4183
+ style: be({ top: x.value.top + "px", left: x.value.left + "px" })
4184
4184
  }, H(k.value), 5)) : F("", !0)
4185
4185
  ]))
4186
4186
  ], 32),
@@ -4192,16 +4192,16 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4192
4192
  M.value.areaKm2 !== null ? (i(), c("div", ei, [
4193
4193
  u[12] || (u[12] = he(" Area: ", -1)),
4194
4194
  l("b", null, H(M.value.areaKm2.toFixed(1)) + " km²", 1)
4195
- ])) : (i(), c("div", ti, [...u[13] || (u[13] = [
4195
+ ])) : (i(), c("div", ti, u[13] || (u[13] = [
4196
4196
  he("Area: ", -1),
4197
4197
  l("b", null, "—", -1)
4198
- ])])),
4198
+ ]))),
4199
4199
  l("button", {
4200
4200
  class: "tool bg-gray-100 py-1.5 px-2 rounded-lg text-md mr-1 cursor-pointer hover:bg-blue-500 hover:text-white transition-all",
4201
4201
  title: "Zoom to feature",
4202
- onClick: u[7] || (u[7] = (b) => ot()),
4202
+ onClick: u[7] || (u[7] = (y) => ot()),
4203
4203
  disabled: f.value
4204
- }, [...u[14] || (u[14] = [
4204
+ }, u[14] || (u[14] = [
4205
4205
  l("svg", {
4206
4206
  xmlns: "http://www.w3.org/2000/svg",
4207
4207
  viewBox: "0 0 24 24",
@@ -4217,11 +4217,11 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4217
4217
  l("path", { d: "M10 7l0 6" }),
4218
4218
  l("path", { d: "M21 21l-6 -6" })
4219
4219
  ], -1)
4220
- ])], 8, li),
4220
+ ]), 8, li),
4221
4221
  l("button", {
4222
4222
  class: "tool bg-gray-100 py-1.5 px-2 rounded-lg text-md cursor-pointer hover:bg-blue-500 hover:text-white transition-all",
4223
4223
  title: "Delete feature",
4224
- onClick: u[8] || (u[8] = (b) => at()),
4224
+ onClick: u[8] || (u[8] = (y) => at()),
4225
4225
  disabled: f.value
4226
4226
  }, [
4227
4227
  P(He, { class: "w-3 h-3" })
@@ -4232,7 +4232,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4232
4232
  ], 2)
4233
4233
  ], 8, ["disabled"]));
4234
4234
  }
4235
- }), si = /* @__PURE__ */ J(ai, [["__scopeId", "data-v-fa01a958"]]), ni = ["data-focus"], ri = { class: "flex items-center" }, ii = { class: "overflow-hidden text-ellipsis whitespace-nowrap rounded-sm text-[#333] text-[85%] px-0.5 py-[3px] pl-1.5 box-border" }, ui = ["onClick", "aria-label"], di = {
4235
+ }), si = /* @__PURE__ */ J(ai, [["__scopeId", "data-v-2c15b74e"]]), ni = ["data-focus"], ri = { class: "flex items-center" }, ii = { class: "overflow-hidden text-ellipsis whitespace-nowrap rounded-sm text-[#333] text-[85%] px-0.5 py-[3px] pl-1.5 box-border" }, ui = ["onClick", "aria-label"], di = {
4236
4236
  key: 0,
4237
4237
  class: "absolute text-gray-500 truncate pl-2"
4238
4238
  }, ci = { class: "flex-1 min-w-[2px]" }, pi = ["placeholder"], fi = { class: "flex items-center shrink-0" }, vi = ["disabled"], mi = /* @__PURE__ */ Z({
@@ -4256,12 +4256,12 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4256
4256
  we(t.style);
4257
4257
  const n = S(null), r = S(null), d = S(null), p = S(!1), f = S(""), v = ue(s, "modelValue"), _ = L(() => t.placeholder || "Add tag…"), w = L(() => v.value?.length === 0 && f.value === ""), j = L(() => !t.disabled && v.value?.length > 0), k = L(() => t.disabled), M = async () => {
4258
4258
  k.value || await Be(() => d.value?.focus());
4259
- }, y = (I) => {
4259
+ }, b = (I) => {
4260
4260
  const A = I.trim();
4261
4261
  A !== "" && (!v.value || !Array.isArray(v.value) ? v.value = [A] : t.unique ? v.value.includes(A) || (v.value = [...v.value, A]) : v.value = [...v.value, A], f.value = "");
4262
4262
  }, x = () => {
4263
4263
  const I = f.value;
4264
- I.trim() !== "" && y(I), f.value = "";
4264
+ I.trim() !== "" && b(I), f.value = "";
4265
4265
  }, g = (I) => {
4266
4266
  const A = v.value.slice();
4267
4267
  A.splice(I, 1), o("update:modelValue", A);
@@ -4314,7 +4314,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4314
4314
  class: "flex items-center rounded-sm px-1 box-border hover:bg-[#ffbdad] hover:text-[#de350b]",
4315
4315
  onClick: ge((N) => g(Y), ["stop"]),
4316
4316
  "aria-label": `Remove ${q}`
4317
- }, [...A[2] || (A[2] = [
4317
+ }, A[2] || (A[2] = [
4318
4318
  l("svg", {
4319
4319
  height: "14",
4320
4320
  width: "14",
@@ -4325,7 +4325,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4325
4325
  }, [
4326
4326
  l("path", { d: "M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z" })
4327
4327
  ], -1)
4328
- ])], 8, ui)
4328
+ ]), 8, ui)
4329
4329
  ]))), 128)),
4330
4330
  w.value ? (i(), c("div", di, H(_.value), 1)) : F("", !0),
4331
4331
  l("div", ci, [
@@ -4359,7 +4359,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4359
4359
  "aria-label": "Clear all tags",
4360
4360
  disabled: k.value,
4361
4361
  onClick: ge(m, ["stop"])
4362
- }, [...A[3] || (A[3] = [
4362
+ }, A[3] || (A[3] = [
4363
4363
  l("svg", {
4364
4364
  height: "20",
4365
4365
  width: "20",
@@ -4368,13 +4368,13 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4368
4368
  }, [
4369
4369
  l("path", { d: "M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z" })
4370
4370
  ], -1)
4371
- ])], 8, vi)) : F("", !0)
4371
+ ]), 8, vi)) : F("", !0)
4372
4372
  ])
4373
4373
  ], 10, ni)
4374
4374
  ], 2)
4375
4375
  ], 512));
4376
4376
  }
4377
- }), hi = { class: "relative flex gap-1 bg-white w-full" }, gi = ["disabled", "placeholder"], yi = /* @__PURE__ */ Z({
4377
+ }), hi = { class: "relative flex gap-1 bg-white w-full" }, gi = ["disabled", "placeholder"], bi = /* @__PURE__ */ Z({
4378
4378
  __name: "vs-input-slug",
4379
4379
  props: /* @__PURE__ */ ne({
4380
4380
  disabled: { type: Boolean },
@@ -4449,7 +4449,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4449
4449
  }, " Gen ")
4450
4450
  ]));
4451
4451
  }
4452
- }), bi = /* @__PURE__ */ J(yi, [["__scopeId", "data-v-cb7b2b74"]]), xi = { class: "relative flex gap-1 bg-white w-full" }, wi = ["disabled", "placeholder"], ki = ["disabled"], _i = { key: 0 }, $i = { key: 1 }, Ci = /* @__PURE__ */ Z({
4452
+ }), yi = /* @__PURE__ */ J(bi, [["__scopeId", "data-v-b0eba370"]]), xi = { class: "relative flex gap-1 bg-white w-full" }, wi = ["disabled", "placeholder"], ki = ["disabled"], _i = { key: 0 }, $i = { key: 1 }, Ci = /* @__PURE__ */ Z({
4453
4453
  __name: "vs-input-codegen",
4454
4454
  props: /* @__PURE__ */ ne({
4455
4455
  table: {},
@@ -4489,7 +4489,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4489
4489
  }, f = () => {
4490
4490
  n.value && (t.value || p());
4491
4491
  };
4492
- return be(() => {
4492
+ return ye(() => {
4493
4493
  f();
4494
4494
  }), te(
4495
4495
  () => [e.table, e.code, e.init],
@@ -4514,7 +4514,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4514
4514
  ], 8, ki)
4515
4515
  ]));
4516
4516
  }
4517
- }), Vi = /* @__PURE__ */ J(Ci, [["__scopeId", "data-v-8f88fb66"]]), Li = { class: "w-full" }, Mi = {
4517
+ }), Vi = /* @__PURE__ */ J(Ci, [["__scopeId", "data-v-6ee5237d"]]), Li = { class: "w-full" }, Mi = {
4518
4518
  ref: "sortableContainer",
4519
4519
  class: "flex flex-col gap-1"
4520
4520
  }, Si = ["onDragstart", "onDrop"], Bi = { class: "w-1/3" }, Ai = { class: "w-2/3" }, ji = ["onClick"], Ei = {
@@ -4551,7 +4551,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4551
4551
  () => f.value.some((x) => x.key && !x.value || !x.key && x.value)
4552
4552
  ), M = () => {
4553
4553
  f.value.push({ id: t("key-value-"), key: "", value: "" });
4554
- }, y = (x) => {
4554
+ }, b = (x) => {
4555
4555
  f.value = f.value.filter((g) => g.id !== x);
4556
4556
  };
4557
4557
  return te(
@@ -4581,7 +4581,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4581
4581
  }, ["prevent"])),
4582
4582
  onDrop: (h) => j(C)
4583
4583
  }, [
4584
- g[1] || (g[1] = xe('<button class="cursor-move" data-v-c1219c25><svg fill="#000000" width="20" height="20" viewBox="0 0 36 36" data-v-c1219c25><circle cx="15" cy="12" r="1.5" data-v-c1219c25></circle><circle cx="15" cy="24" r="1.5" data-v-c1219c25></circle><circle cx="21" cy="12" r="1.5" data-v-c1219c25></circle><circle cx="21" cy="24" r="1.5" data-v-c1219c25></circle><circle cx="21" cy="18" r="1.5" data-v-c1219c25></circle><circle cx="15" cy="18" r="1.5" data-v-c1219c25></circle></svg></button>', 1)),
4584
+ g[1] || (g[1] = xe('<button class="cursor-move" data-v-a0f7fbfc><svg fill="#000000" width="20" height="20" viewBox="0 0 36 36" data-v-a0f7fbfc><circle cx="15" cy="12" r="1.5" data-v-a0f7fbfc></circle><circle cx="15" cy="24" r="1.5" data-v-a0f7fbfc></circle><circle cx="21" cy="12" r="1.5" data-v-a0f7fbfc></circle><circle cx="21" cy="24" r="1.5" data-v-a0f7fbfc></circle><circle cx="21" cy="18" r="1.5" data-v-a0f7fbfc></circle><circle cx="15" cy="18" r="1.5" data-v-a0f7fbfc></circle></svg></button>', 1)),
4585
4585
  l("div", Bi, [
4586
4586
  P(Je, {
4587
4587
  modelValue: m.key,
@@ -4597,7 +4597,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4597
4597
  }, null, 8, ["modelValue", "onUpdate:modelValue"])
4598
4598
  ]),
4599
4599
  l("button", {
4600
- onClick: (h) => y(m.id),
4600
+ onClick: (h) => b(m.id),
4601
4601
  class: "shrink-0 w-[30px] text-gray-600 h-[30px] rounded-full flex items-center justify-center bg-gray-100 hover:bg-gray-200"
4602
4602
  }, [
4603
4603
  P(le(Ct), {
@@ -4624,7 +4624,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4624
4624
  ])
4625
4625
  ]));
4626
4626
  }
4627
- }), Fi = /* @__PURE__ */ J(zi, [["__scopeId", "data-v-c1219c25"]]), Oi = { class: "w-full" }, Di = {
4627
+ }), Fi = /* @__PURE__ */ J(zi, [["__scopeId", "data-v-a0f7fbfc"]]), Oi = { class: "w-full" }, Di = {
4628
4628
  ref: "sortableContainer",
4629
4629
  class: "flex flex-col gap-1"
4630
4630
  }, Ui = ["onDragstart", "onDrop"], Ri = ["disabled"], Pi = { class: "flex-1" }, Hi = ["onClick", "disabled"], Ni = {
@@ -4678,7 +4678,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4678
4678
  function M(x) {
4679
4679
  r.value || (n.value = x);
4680
4680
  }
4681
- function y(x) {
4681
+ function b(x) {
4682
4682
  if (r.value || n.value === null || n.value === x) return;
4683
4683
  const g = [...o.value], [m] = g.splice(n.value, 1);
4684
4684
  g.splice(x, 0, m), o.value = g, n.value = null;
@@ -4692,15 +4692,15 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4692
4692
  onDragstart: (h) => M(C),
4693
4693
  onDragover: g[0] || (g[0] = ge(() => {
4694
4694
  }, ["prevent"])),
4695
- onDrop: (h) => y(C)
4695
+ onDrop: (h) => b(C)
4696
4696
  }, [
4697
4697
  l("button", {
4698
4698
  class: "cursor-move",
4699
4699
  type: "button",
4700
4700
  disabled: r.value
4701
- }, [...g[1] || (g[1] = [
4702
- xe('<svg fill="#000000" width="20" height="20" viewBox="0 0 36 36" data-v-9f5a70cd><circle cx="15" cy="12" r="1.5" data-v-9f5a70cd></circle><circle cx="15" cy="24" r="1.5" data-v-9f5a70cd></circle><circle cx="21" cy="12" r="1.5" data-v-9f5a70cd></circle><circle cx="21" cy="24" r="1.5" data-v-9f5a70cd></circle><circle cx="21" cy="18" r="1.5" data-v-9f5a70cd></circle><circle cx="15" cy="18" r="1.5" data-v-9f5a70cd></circle></svg>', 1)
4703
- ])], 8, Ri),
4701
+ }, g[1] || (g[1] = [
4702
+ xe('<svg fill="#000000" width="20" height="20" viewBox="0 0 36 36" data-v-efa2057b><circle cx="15" cy="12" r="1.5" data-v-efa2057b></circle><circle cx="15" cy="24" r="1.5" data-v-efa2057b></circle><circle cx="21" cy="12" r="1.5" data-v-efa2057b></circle><circle cx="21" cy="24" r="1.5" data-v-efa2057b></circle><circle cx="21" cy="18" r="1.5" data-v-efa2057b></circle><circle cx="15" cy="18" r="1.5" data-v-efa2057b></circle></svg>', 1)
4703
+ ]), 8, Ri),
4704
4704
  l("div", Pi, [
4705
4705
  P(Je, {
4706
4706
  modelValue: m.value,
@@ -4739,7 +4739,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4739
4739
  ])
4740
4740
  ]));
4741
4741
  }
4742
- }), Tt = /* @__PURE__ */ J(qi, [["__scopeId", "data-v-9f5a70cd"]]), Zi = { class: "flex items-center gap-2 w-full" }, Wi = ["disabled"], Ji = ["disabled"], Yi = /* @__PURE__ */ Z({
4742
+ }), Tt = /* @__PURE__ */ J(qi, [["__scopeId", "data-v-efa2057b"]]), Zi = { class: "flex items-center gap-2 w-full" }, Wi = ["disabled"], Ji = ["disabled"], Yi = /* @__PURE__ */ Z({
4743
4743
  __name: "vs-input-color",
4744
4744
  props: {
4745
4745
  style: { default: () => ({}) },
@@ -4889,7 +4889,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4889
4889
  p.value = !1;
4890
4890
  }
4891
4891
  }
4892
- function y() {
4892
+ function b() {
4893
4893
  v.value = !v.value;
4894
4894
  }
4895
4895
  function x(g) {
@@ -4918,9 +4918,9 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4918
4918
  key: 0,
4919
4919
  type: "button",
4920
4920
  class: "absolute right-2 top-1/2 -translate-y-1/2 text-gray-500 hover:text-blue-600",
4921
- onClick: y,
4921
+ onClick: b,
4922
4922
  title: "Show search results"
4923
- }, [...m[2] || (m[2] = [
4923
+ }, m[2] || (m[2] = [
4924
4924
  l("svg", {
4925
4925
  xmlns: "http://www.w3.org/2000/svg",
4926
4926
  width: "18",
@@ -4940,7 +4940,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4940
4940
  l("path", { d: "M12 16v-4" }),
4941
4941
  l("path", { d: "M12 8h.01" })
4942
4942
  ], -1)
4943
- ])])) : F("", !0)
4943
+ ]))) : F("", !0)
4944
4944
  ]),
4945
4945
  l("button", {
4946
4946
  type: "button",
@@ -4948,7 +4948,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4948
4948
  class: "flex items-center justify-center px-2 py-2 border rounded-md bg-white hover:bg-gray-50 text-gray-600 hover:text-blue-600 disabled:opacity-50 h-[38px]",
4949
4949
  disabled: p.value || !d.value?.trim()
4950
4950
  }, [
4951
- p.value ? (i(), c("svg", ru, [...m[4] || (m[4] = [
4951
+ p.value ? (i(), c("svg", ru, m[4] || (m[4] = [
4952
4952
  l("circle", {
4953
4953
  class: "opacity-25",
4954
4954
  cx: "12",
@@ -4962,7 +4962,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4962
4962
  fill: "currentColor",
4963
4963
  d: "M4 12a8 8 0 018-8v4a4 4 0 00-4 4H4z"
4964
4964
  }, null, -1)
4965
- ])])) : (i(), c("svg", nu, [...m[3] || (m[3] = [
4965
+ ]))) : (i(), c("svg", nu, m[3] || (m[3] = [
4966
4966
  l("circle", {
4967
4967
  cx: "11",
4968
4968
  cy: "11",
@@ -4974,7 +4974,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4974
4974
  x2: "16.65",
4975
4975
  y2: "16.65"
4976
4976
  }, null, -1)
4977
- ])]))
4977
+ ])))
4978
4978
  ], 8, su),
4979
4979
  (i(), pe(We, { to: "body" }, [
4980
4980
  v.value ? (i(), c("div", iu, [
@@ -4985,7 +4985,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
4985
4985
  class: "text-gray-500 hover:text-blue-600",
4986
4986
  onClick: m[1] || (m[1] = (C) => v.value = !1),
4987
4987
  title: "Close"
4988
- }, [...m[5] || (m[5] = [
4988
+ }, m[5] || (m[5] = [
4989
4989
  l("svg", {
4990
4990
  xmlns: "http://www.w3.org/2000/svg",
4991
4991
  width: "20",
@@ -5010,7 +5010,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
5010
5010
  y2: "18"
5011
5011
  })
5012
5012
  ], -1)
5013
- ])])
5013
+ ]))
5014
5014
  ]),
5015
5015
  l("ul", null, [
5016
5016
  (i(!0), c(ae, null, ie(f.value, (C, h) => (i(), c("li", {
@@ -5028,7 +5028,7 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
5028
5028
  }), Kt = (s = "") => `${s}${Math.floor(Math.random() * 1e4)}`, vu = { class: "vs-datalist space-y-3" }, mu = { class: "space-y-3" }, hu = ["onClick", "disabled"], gu = {
5029
5029
  key: 0,
5030
5030
  class: "rounded-lg border border-dashed border-gray-200 p-4 text-sm text-gray-500"
5031
- }, yu = ["disabled"], bu = /* @__PURE__ */ Z({
5031
+ }, bu = ["disabled"], yu = /* @__PURE__ */ Z({
5032
5032
  __name: "vs-input-datalist",
5033
5033
  props: /* @__PURE__ */ ne({
5034
5034
  schema: { default: () => [] },
@@ -5062,27 +5062,27 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
5062
5062
  }
5063
5063
  function v() {
5064
5064
  if (!e.minItems || t.value.length >= e.minItems) return;
5065
- const M = e.minItems - t.value.length, y = Array.from({ length: M }, _);
5066
- t.value = [...t.value, ...y];
5065
+ const M = e.minItems - t.value.length, b = Array.from({ length: M }, _);
5066
+ t.value = [...t.value, ...b];
5067
5067
  }
5068
5068
  function _() {
5069
5069
  const M = {};
5070
- return n.value.forEach((y) => {
5071
- M[y.name] = y?.default ?? null;
5070
+ return n.value.forEach((b) => {
5071
+ M[b.name] = b?.default ?? null;
5072
5072
  }), M;
5073
5073
  }
5074
5074
  function w() {
5075
5075
  d.value && (t.value = [...t.value, _()], f());
5076
5076
  }
5077
5077
  function j(M) {
5078
- p.value || (t.value = t.value.filter((y, x) => x !== M), f(), v());
5078
+ p.value || (t.value = t.value.filter((b, x) => x !== M), f(), v());
5079
5079
  }
5080
5080
  function k(M) {
5081
5081
  return {
5082
5082
  ...M
5083
5083
  };
5084
5084
  }
5085
- return (M, y) => (i(), c("div", vu, [
5085
+ return (M, b) => (i(), c("div", vu, [
5086
5086
  l("div", mu, [
5087
5087
  (i(!0), c(ae, null, ie(t.value, (x, g) => (i(), c("div", {
5088
5088
  key: o.value[g],
@@ -5115,10 +5115,10 @@ const ir = /* @__PURE__ */ J(sr, [["render", rr]]), ur = { class: "map-search-wi
5115
5115
  }, [
5116
5116
  P(je, { class: "w-5 h-5" }),
5117
5117
  he(" " + H(e.addButtonText), 1)
5118
- ], 8, yu)
5118
+ ], 8, bu)
5119
5119
  ]));
5120
5120
  }
5121
- }), xu = /* @__PURE__ */ J(bu, [["__scopeId", "data-v-3b714d78"]]), wu = {};
5121
+ }), xu = /* @__PURE__ */ J(yu, [["__scopeId", "data-v-a7a64a30"]]), wu = {};
5122
5122
  function ku(s, e) {
5123
5123
  return i(), c("svg", De({
5124
5124
  xmlns: "http://www.w3.org/2000/svg",
@@ -5130,7 +5130,7 @@ function ku(s, e) {
5130
5130
  "stroke-width": "2",
5131
5131
  "stroke-linecap": "round",
5132
5132
  "stroke-linejoin": "round"
5133
- }, s.$attrs), [...e[0] || (e[0] = [
5133
+ }, s.$attrs), e[0] || (e[0] = [
5134
5134
  l("rect", {
5135
5135
  width: "14",
5136
5136
  height: "14",
@@ -5140,7 +5140,7 @@ function ku(s, e) {
5140
5140
  ry: "2"
5141
5141
  }, null, -1),
5142
5142
  l("path", { d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2" }, null, -1)
5143
- ])], 16);
5143
+ ]), 16);
5144
5144
  }
5145
5145
  const _u = /* @__PURE__ */ J(wu, [["render", ku]]), $u = { class: "vs-dataform space-y-4" }, Cu = { class: "flex items-center justify-between mb-3" }, Vu = { class: "text-sm font-medium text-gray-700" }, Lu = { class: "flex items-center gap-2" }, Mu = ["title", "onClick", "disabled"], Su = ["title", "onClick", "disabled"], Bu = {
5146
5146
  key: 0,
@@ -5197,7 +5197,7 @@ const _u = /* @__PURE__ */ J(wu, [["render", ku]]), $u = { class: "vs-dataform s
5197
5197
  function M(g) {
5198
5198
  v.value || (t.value = t.value.filter((m, C) => C !== g), _(), w());
5199
5199
  }
5200
- function y(g) {
5200
+ function b(g) {
5201
5201
  if (e.disabled) return;
5202
5202
  const m = JSON.parse(JSON.stringify(t.value[g] ?? {}));
5203
5203
  t.value = [
@@ -5223,7 +5223,7 @@ const _u = /* @__PURE__ */ J(wu, [["render", ku]]), $u = { class: "vs-dataform s
5223
5223
  type: "button",
5224
5224
  class: "p-2 text-gray-400 hover:text-gray-600 hover:bg-gray-50 rounded-lg transition-all disabled:opacity-40",
5225
5225
  title: e.duplicateTitle,
5226
- onClick: ($) => y(h),
5226
+ onClick: ($) => b(h),
5227
5227
  disabled: e.disabled
5228
5228
  }, [
5229
5229
  P(_u, { class: "w-5 h-5" })
@@ -5262,7 +5262,7 @@ const _u = /* @__PURE__ */ J(wu, [["render", ku]]), $u = { class: "vs-dataform s
5262
5262
  ], 8, Au)
5263
5263
  ]));
5264
5264
  }
5265
- }), Eu = /* @__PURE__ */ J(ju, [["__scopeId", "data-v-9e39b4f5"]]), Iu = {
5265
+ }), Eu = /* @__PURE__ */ J(ju, [["__scopeId", "data-v-4dc5a1a3"]]), Iu = {
5266
5266
  VsInputText: Je,
5267
5267
  VsInputRadio: St,
5268
5268
  "vs-input-text": Je,
@@ -5284,7 +5284,7 @@ const _u = /* @__PURE__ */ J(wu, [["render", ku]]), $u = { class: "vs-dataform s
5284
5284
  "vs-input-map": si,
5285
5285
  "vs-input-file-list": Ra,
5286
5286
  "vs-input-tags": mi,
5287
- "vs-input-slug": bi,
5287
+ "vs-input-slug": yi,
5288
5288
  "vs-input-codegen": Vi,
5289
5289
  "vs-input-key-value": Fi,
5290
5290
  "vs-input-text[]": Tt,
@@ -5401,7 +5401,7 @@ const _u = /* @__PURE__ */ J(wu, [["render", ku]]), $u = { class: "vs-dataform s
5401
5401
  return { width: Q, minWidth: Q };
5402
5402
  });
5403
5403
  let v = null, _ = 0, w = 0, j = null, k = null, M = null;
5404
- const y = () => Y(), x = () => m();
5404
+ const b = () => Y(), x = () => m();
5405
5405
  te(
5406
5406
  () => t.target,
5407
5407
  async (R) => {
@@ -5422,7 +5422,7 @@ const _u = /* @__PURE__ */ J(wu, [["render", ku]]), $u = { class: "vs-dataform s
5422
5422
  g(R ?? null), Be(() => m());
5423
5423
  },
5424
5424
  { immediate: !0 }
5425
- ), be(() => {
5425
+ ), ye(() => {
5426
5426
  t.scrollContainer || g(null), m();
5427
5427
  }), ct(() => {
5428
5428
  I(), g(null, !0), j = null, typeof window < "u" && (_ && window.cancelAnimationFrame(_), w && window.cancelAnimationFrame(w));
@@ -5434,8 +5434,8 @@ const _u = /* @__PURE__ */ J(wu, [["render", ku]]), $u = { class: "vs-dataform s
5434
5434
  }
5435
5435
  if (k = R ?? null, typeof window > "u") return;
5436
5436
  const ee = R ?? window, oe = window;
5437
- ee.addEventListener("scroll", y, { passive: !0 }), oe.addEventListener("resize", x), M = () => {
5438
- ee.removeEventListener("scroll", y), oe.removeEventListener("resize", x);
5437
+ ee.addEventListener("scroll", b, { passive: !0 }), oe.addEventListener("resize", x), M = () => {
5438
+ ee.removeEventListener("scroll", b), oe.removeEventListener("resize", x);
5439
5439
  };
5440
5440
  }
5441
5441
  function m() {
@@ -5510,7 +5510,7 @@ const _u = /* @__PURE__ */ J(wu, [["render", ku]]), $u = { class: "vs-dataform s
5510
5510
  return e({ refresh: m }), (R, Q) => d.value && o.value.length ? (i(), c("div", {
5511
5511
  key: 0,
5512
5512
  class: U(p.value),
5513
- style: ye(f.value)
5513
+ style: be(f.value)
5514
5514
  }, [
5515
5515
  l("h2", Ou, H(R.title), 1),
5516
5516
  l("div", Du, [
@@ -5537,7 +5537,7 @@ const _u = /* @__PURE__ */ J(wu, [["render", ku]]), $u = { class: "vs-dataform s
5537
5537
  ])
5538
5538
  ], 6)) : F("", !0);
5539
5539
  }
5540
- }), Pu = /* @__PURE__ */ J(Ru, [["__scopeId", "data-v-b3e16a91"]]), Zt = {
5540
+ }), Pu = /* @__PURE__ */ J(Ru, [["__scopeId", "data-v-1584a562"]]), Zt = {
5541
5541
  required: "Це поле є обов’язковим",
5542
5542
  email: "Неправильний email"
5543
5543
  }, Hu = (s) => s ? !1 : Zt.required, Nu = (s) => {
@@ -5619,8 +5619,8 @@ function Wu(s, e, t = !1) {
5619
5619
  }
5620
5620
  let j = !1, k = null;
5621
5621
  w.rules.forEach((M) => {
5622
- const y = qu(s.value[w.name], M);
5623
- y && (j = !0, !k && typeof y == "string" && (k = y));
5622
+ const b = qu(s.value[w.name], M);
5623
+ b && (j = !0, !k && typeof b == "string" && (k = b));
5624
5624
  }), j && k ? n.value[w.name] = k : delete n.value[w.name];
5625
5625
  }
5626
5626
  w.schema && d(w.schema, !1);
@@ -5664,14 +5664,14 @@ const Ju = { class: "flex w-full h-full min-h-0 gap-6" }, Yu = {
5664
5664
  validate: f,
5665
5665
  reset: v,
5666
5666
  visibleSchema: _
5667
- } = Wu(d, n.schema, Xt(n, "disabled")), w = S(null), j = S(null), k = L(() => n.navigation), M = L(() => n.navWidth), y = L(() => n.style?.columns), x = Object.freeze({ container: 12, label: 3 }), g = L(() => n.columns ?? y.value ?? x), m = L(() => n.columns != null || y.value != null), C = L(() => m.value ? "horizontal" : n.layout), h = (q) => q?.columns ? "horizontal" : C.value, $ = (q) => q?.columns ?? g.value, I = () => {
5667
+ } = Wu(d, n.schema, Xt(n, "disabled")), w = S(null), j = S(null), k = L(() => n.navigation), M = L(() => n.navWidth), b = L(() => n.style?.columns), x = Object.freeze({ container: 12, label: 3 }), g = L(() => n.columns ?? b.value ?? x), m = L(() => n.columns != null || b.value != null), C = L(() => m.value ? "horizontal" : n.layout), h = (q) => q?.columns ? "horizontal" : C.value, $ = (q) => q?.columns ?? g.value, I = () => {
5668
5668
  o("update:modelValue", d.value), f(), o("handle-submit", d.value);
5669
5669
  };
5670
5670
  e({
5671
5671
  validate: f,
5672
5672
  reset: v,
5673
5673
  errors: p
5674
- }), be(() => {
5674
+ }), ye(() => {
5675
5675
  n.modelValue && (d.value = n.modelValue), r.value = {
5676
5676
  value: d.value,
5677
5677
  errors: p.value,
@@ -5703,7 +5703,7 @@ const Ju = { class: "flex w-full h-full min-h-0 gap-6" }, Yu = {
5703
5703
  class: U(h(N) === "horizontal" ? "col-span-12" : `col-span-${N.col || 12}`)
5704
5704
  }, [
5705
5705
  P(qt, {
5706
- style: ye(q.style),
5706
+ style: be(q.style),
5707
5707
  item: N,
5708
5708
  layout: h(N),
5709
5709
  columns: $(N),
@@ -5787,7 +5787,7 @@ const Ju = { class: "flex w-full h-full min-h-0 gap-6" }, Yu = {
5787
5787
  function _() {
5788
5788
  o("close");
5789
5789
  }
5790
- return be(async () => {
5790
+ return ye(async () => {
5791
5791
  try {
5792
5792
  if (t.form && !t.schema) {
5793
5793
  const w = await fetch(`/api/template/form/${t.form}`);
@@ -5834,7 +5834,7 @@ const Ju = { class: "flex w-full h-full min-h-0 gap-6" }, Yu = {
5834
5834
  onClick: _,
5835
5835
  type: "button",
5836
5836
  class: "size-8 inline-flex justify-center items-center gap-x-2 rounded-full border border-transparent bg-gray-100 text-gray-800 hover:bg-gray-200 focus:outline-none focus:bg-gray-200 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-700 dark:hover:bg-neutral-600 dark:text-neutral-400 dark:focus:bg-neutral-600"
5837
- }, [...j[2] || (j[2] = [
5837
+ }, j[2] || (j[2] = [
5838
5838
  l("span", { class: "sr-only" }, "Close", -1),
5839
5839
  l("svg", {
5840
5840
  class: "flex-shrink-0 w-4 h-4",
@@ -5851,7 +5851,7 @@ const Ju = { class: "flex w-full h-full min-h-0 gap-6" }, Yu = {
5851
5851
  l("path", { d: "M18 6 6 18" }),
5852
5852
  l("path", { d: "m6 6 12 12" })
5853
5853
  ], -1)
5854
- ])])
5854
+ ]))
5855
5855
  ]),
5856
5856
  l("div", od, [
5857
5857
  n.value ? (i(), pe(Ue, {
@@ -5903,20 +5903,20 @@ const Ju = { class: "flex w-full h-full min-h-0 gap-6" }, Yu = {
5903
5903
  setup(s) {
5904
5904
  const e = s, t = S(e.count), o = L(() => e.limit), { inputClass: n } = we(e.style), r = ue(s, "modelValue"), d = L(() => !!e.disabled), p = L(() => e.placeholder ?? "");
5905
5905
  Qt(() => {
5906
- const y = r.value?.length ?? 0;
5907
- y < t.value && (r.value = [
5906
+ const b = r.value?.length ?? 0;
5907
+ b < t.value && (r.value = [
5908
5908
  ...r.value ?? [],
5909
- ...Array(t.value - y)
5909
+ ...Array(t.value - b)
5910
5910
  ]);
5911
5911
  });
5912
5912
  const f = S({}), v = S({});
5913
- function _(y, x) {
5914
- y && (f.value[x] = y);
5913
+ function _(b, x) {
5914
+ b && (f.value[x] = b);
5915
5915
  }
5916
- async function w(y, x) {
5917
- if (!y || e.inputType !== "mask") return;
5916
+ async function w(b, x) {
5917
+ if (!b || e.inputType !== "mask") return;
5918
5918
  const { default: g } = await import("./index-W-qQIppj.js");
5919
- v.value[x] && v.value[x].destroy(), v.value[x] = g(y, {
5919
+ v.value[x] && v.value[x].destroy(), v.value[x] = g(b, {
5920
5920
  mask: e.mask || "",
5921
5921
  definitions: {
5922
5922
  9: /[0-9]/,
@@ -5932,41 +5932,41 @@ const Ju = { class: "flex w-full h-full min-h-0 gap-6" }, Yu = {
5932
5932
  m[x] = e.unmask ? v.value[x].unmaskedValue : v.value[x].value, r.value = m;
5933
5933
  }), r.value?.[x] && (v.value[x].value = r.value[x]);
5934
5934
  }
5935
- function j(y, x) {
5935
+ function j(b, x) {
5936
5936
  if (d.value) return;
5937
- const g = y.target.value ?? null, m = [...r.value];
5937
+ const g = b.target.value ?? null, m = [...r.value];
5938
5938
  m[x] = e.inputType === "text" ? g : Number(g), r.value = m;
5939
5939
  }
5940
5940
  function k() {
5941
5941
  t.value += 1;
5942
- const y = e.inputType === "text" || e.inputType === "mask" ? null : 0;
5943
- r.value = [...r.value, y], e.inputType === "mask" && setTimeout(() => {
5942
+ const b = e.inputType === "text" || e.inputType === "mask" ? null : 0;
5943
+ r.value = [...r.value, b], e.inputType === "mask" && setTimeout(() => {
5944
5944
  const x = t.value - 1;
5945
5945
  f.value[x] && w(f.value[x], x);
5946
5946
  }, 0);
5947
5947
  }
5948
- function M(y) {
5948
+ function M(b) {
5949
5949
  if (t.value > 1) {
5950
- v.value[y] && (v.value[y].destroy(), delete v.value[y]), t.value -= 1, r.value = r.value.filter((g, m) => m !== y);
5950
+ v.value[b] && (v.value[b].destroy(), delete v.value[b]), t.value -= 1, r.value = r.value.filter((g, m) => m !== b);
5951
5951
  const x = {};
5952
5952
  Object.keys(v.value).forEach((g) => {
5953
5953
  const m = parseInt(g, 10);
5954
- m > y ? x[m - 1] = v.value[m] : m < y && (x[m] = v.value[m]);
5954
+ m > b ? x[m - 1] = v.value[m] : m < b && (x[m] = v.value[m]);
5955
5955
  }), v.value = x;
5956
5956
  }
5957
5957
  }
5958
- return be(() => {
5958
+ return ye(() => {
5959
5959
  if (e.inputType === "mask")
5960
- for (let y = 0; y < t.value; y += 1)
5961
- f.value[y] && w(f.value[y], y);
5960
+ for (let b = 0; b < t.value; b += 1)
5961
+ f.value[b] && w(f.value[b], b);
5962
5962
  }), ct(() => {
5963
- Object.values(v.value).forEach((y) => {
5964
- y && y.destroy();
5963
+ Object.values(v.value).forEach((b) => {
5964
+ b && b.destroy();
5965
5965
  });
5966
- }), te(() => e.mask, (y) => {
5966
+ }), te(() => e.mask, (b) => {
5967
5967
  e.inputType === "mask" && Object.values(v.value).forEach((x) => {
5968
5968
  x && x.updateOptions({
5969
- mask: y,
5969
+ mask: b,
5970
5970
  definitions: {
5971
5971
  9: /[0-9]/,
5972
5972
  A: /[a-zA-Z]/,
@@ -5974,42 +5974,42 @@ const Ju = { class: "flex w-full h-full min-h-0 gap-6" }, Yu = {
5974
5974
  }
5975
5975
  });
5976
5976
  });
5977
- }), te(r, (y) => {
5978
- e.inputType === "mask" && y && y.forEach((x, g) => {
5977
+ }), te(r, (b) => {
5978
+ e.inputType === "mask" && b && b.forEach((x, g) => {
5979
5979
  v.value[g] && v.value[g].value !== x && (v.value[g].value = x || "");
5980
5980
  });
5981
- }, { deep: !0 }), (y, x) => (i(), c("div", {
5981
+ }, { deep: !0 }), (b, x) => (i(), c("div", {
5982
5982
  class: U(["grid gap-2", `grid-cols-${o.value}`])
5983
5983
  }, [
5984
5984
  (i(!0), c(ae, null, ie(t.value, (g) => (i(), c("div", {
5985
5985
  key: g,
5986
5986
  class: "flex items-center gap-2 w-full"
5987
5987
  }, [
5988
- y.inputType === "mask" ? (i(), c("input", {
5988
+ b.inputType === "mask" ? (i(), c("input", {
5989
5989
  key: 0,
5990
5990
  type: "text",
5991
5991
  ref_for: !0,
5992
5992
  ref: (m) => _(m, g - 1),
5993
- placeholder: y.placeholder,
5994
- disabled: y.disabled,
5995
- name: `${y.name}[${g - 1}]`,
5996
- class: U(["py-1.5 px-3 block w-full placeholder:text[#767f8f] bg-white", [le(n), { "!border-red-600": y.error }]]),
5993
+ placeholder: b.placeholder,
5994
+ disabled: b.disabled,
5995
+ name: `${b.name}[${g - 1}]`,
5996
+ class: U(["py-1.5 px-3 block w-full placeholder:text[#767f8f] bg-white", [le(n), { "!border-red-600": b.error }]]),
5997
5997
  style: {
5998
5998
  border: "1px solid #CFD9E0"
5999
5999
  }
6000
6000
  }, null, 10, sd)) : (i(), c("input", {
6001
6001
  key: 1,
6002
- type: y.inputType,
6002
+ type: b.inputType,
6003
6003
  value: r.value?.[g - 1],
6004
6004
  onInput: (m) => j(m, g - 1),
6005
6005
  placeholder: p.value,
6006
6006
  disabled: d.value,
6007
- class: U(["py-1.5 px-3 block w-full placeholder:text[#767f8f] bg-white", [le(n), { "!border-red-600": y.error }]]),
6007
+ class: U(["py-1.5 px-3 block w-full placeholder:text[#767f8f] bg-white", [le(n), { "!border-red-600": b.error }]]),
6008
6008
  style: {
6009
6009
  border: "1px solid #CFD9E0"
6010
6010
  }
6011
6011
  }, null, 42, nd)),
6012
- !y.disabled && g === t.value && y.isAdded ? (i(), c("button", {
6012
+ !b.disabled && g === t.value && b.isAdded ? (i(), c("button", {
6013
6013
  key: 2,
6014
6014
  type: "button",
6015
6015
  onClick: ge(k, ["stop"]),
@@ -6020,7 +6020,7 @@ const Ju = { class: "flex w-full h-full min-h-0 gap-6" }, Yu = {
6020
6020
  width: "18"
6021
6021
  })
6022
6022
  ])) : F("", !0),
6023
- !y.disabled && t.value > 1 && y.isAdded ? (i(), c("button", {
6023
+ !b.disabled && t.value > 1 && b.isAdded ? (i(), c("button", {
6024
6024
  key: 3,
6025
6025
  type: "button",
6026
6026
  onClick: ge((m) => M(g - 1), ["stop"]),
@@ -6077,7 +6077,7 @@ export {
6077
6077
  St as VsInputRadio,
6078
6078
  tu as VsInputRange,
6079
6079
  Et as VsInputSelect,
6080
- bi as VsInputSlug,
6080
+ yi as VsInputSlug,
6081
6081
  Mt as VsInputStatic,
6082
6082
  Pt as VsInputSwitcher,
6083
6083
  mi as VsInputTag,