@opengis/gis 0.2.119 → 0.2.121

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,12 +1,12 @@
1
- import { openBlock as _, createElementBlock as S, createElementVNode as a, defineComponent as R, computed as C, createTextVNode as ve, createVNode as $, mergeModels as Me, defineAsyncComponent as ee, useModel as je, ref as x, withCtx as O, toDisplayString as N, unref as J, watch as A, onUnmounted as Le, createCommentVNode as q, onBeforeUnmount as he, onMounted as qe, withDirectives as Ae, vModelText as Ne, createBlock as I, normalizeClass as fe, normalizeStyle as Ee, Fragment as me, renderList as Ie, resolveDynamicComponent as Ue } from "vue";
2
- import { useRouter as Te, useRoute as De } from "vue-router";
3
- import { notify as B } from "@opengis/core";
4
- import { _ as Oe, f as ge, n as Re, o as Fe, p as Be, M as Pe, i as Qe, j as pe, m as He } from "./index-CbdZv1jy.js";
5
- import { S as Ye, C as Je } from "./CardIcon-ODZgA2Pb.js";
6
- import { _ as We, a as Xe, b as Ge, c as Ze } from "./HeaderActions.vue_vue_type_script_setup_true_lang-CTKkmXWD.js";
1
+ import { openBlock as b, createElementBlock as $, createElementVNode as a, defineComponent as F, computed as S, createTextVNode as ve, createVNode as V, mergeModels as Me, defineAsyncComponent as ee, useModel as je, ref as g, withCtx as R, toDisplayString as E, unref as J, watch as N, onUnmounted as Le, createCommentVNode as A, onBeforeUnmount as he, onMounted as qe, withDirectives as Ae, vModelText as Ne, createBlock as T, normalizeClass as fe, normalizeStyle as Ee, Fragment as me, renderList as Te, resolveDynamicComponent as Ue } from "vue";
2
+ import { useRouter as Ie, useRoute as De } from "vue-router";
3
+ import { notify as P } from "@opengis/core";
4
+ import { _ as Oe, f as ge, n as Re, o as Fe, p as Be, M as Pe, i as Qe, j as pe, m as He } from "./index-CActL7Mw.js";
5
+ import { S as Ye, C as Je } from "./CardIcon-Bu_mm6QX.js";
6
+ import { _ as We, a as Xe, b as Ge, c as Ze } from "./HeaderActions.vue_vue_type_script_setup_true_lang-B2ErIdAR.js";
7
7
  import { _ as xe } from "./MonacoEditor.vue_vue_type_script_setup_true_lang-D3ZPeXMw.js";
8
- import { V as Ke } from "./vs-datatable-D_Xzh4qf.js";
9
- import { _ as et } from "./ExtentOutlineLayer.vue_vue_type_script_setup_true_lang-DLAIOHJh.js";
8
+ import { V as Ke } from "./vs-datatable-RkRQEa10.js";
9
+ import { _ as et } from "./ExtentOutlineLayer.vue_vue_type_script_setup_true_lang-CF1EEob3.js";
10
10
  const tt = {}, ot = {
11
11
  xmlns: "http://www.w3.org/2000/svg",
12
12
  width: "24",
@@ -19,8 +19,8 @@ const tt = {}, ot = {
19
19
  "stroke-linejoin": "round",
20
20
  class: "lucide lucide-table"
21
21
  };
22
- function at(j, r) {
23
- return _(), S("svg", ot, [...r[0] || (r[0] = [
22
+ function at(L, l) {
23
+ return b(), $("svg", ot, [...l[0] || (l[0] = [
24
24
  a("path", { d: "M12 3v18" }, null, -1),
25
25
  a("rect", {
26
26
  width: "18",
@@ -33,24 +33,24 @@ function at(j, r) {
33
33
  a("path", { d: "M3 15h18" }, null, -1)
34
34
  ])]);
35
35
  }
36
- const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-col h-full" }, rt = { class: "flex justify-end mb-3 gap-2" }, lt = /* @__PURE__ */ R({
36
+ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-col h-full" }, lt = { class: "flex justify-end mb-3 gap-2" }, rt = /* @__PURE__ */ F({
37
37
  __name: "cartocss-css-tab",
38
38
  props: {
39
39
  modelValue: {}
40
40
  },
41
41
  emits: ["update:modelValue", "save"],
42
- setup(j, { emit: r }) {
43
- const c = j, V = r, w = C({
44
- get: () => c.modelValue,
45
- set: (g) => V("update:modelValue", g)
42
+ setup(L, { emit: l }) {
43
+ const u = L, z = l, _ = S({
44
+ get: () => u.modelValue,
45
+ set: (h) => z("update:modelValue", h)
46
46
  });
47
- return (g, u) => (_(), S("div", st, [
48
- a("div", rt, [
47
+ return (h, i) => (b(), $("div", st, [
48
+ a("div", lt, [
49
49
  a("button", {
50
50
  type: "button",
51
51
  class: "inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md font-medium bg-gradient-to-r from-sky-400 to-blue-400 hover:from-sky-500 hover:to-blue-500 text-white shadow-sm px-4 py-2 h-9 text-xs transition-all duration-300",
52
- onClick: u[0] || (u[0] = (d) => g.$emit("save"))
53
- }, [...u[2] || (u[2] = [
52
+ onClick: i[0] || (i[0] = (d) => h.$emit("save"))
53
+ }, [...i[2] || (i[2] = [
54
54
  a("svg", {
55
55
  xmlns: "http://www.w3.org/2000/svg",
56
56
  width: "24",
@@ -70,23 +70,23 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
70
70
  ve(" Зберегти ", -1)
71
71
  ])])
72
72
  ]),
73
- $(xe, {
74
- modelValue: w.value,
75
- "onUpdate:modelValue": u[1] || (u[1] = (d) => w.value = d),
73
+ V(xe, {
74
+ modelValue: _.value,
75
+ "onUpdate:modelValue": i[1] || (i[1] = (d) => _.value = d),
76
76
  language: "cartocss",
77
77
  class: "flex-1 rounded-lg overflow-hidden"
78
78
  }, null, 8, ["modelValue"])
79
79
  ]));
80
80
  }
81
- }), ut = { class: "flex flex-col flex-1 min-h-0" }, it = { class: "flex justify-between mb-3 gap-2" }, ct = { class: "text-left" }, dt = { class: "font-medium text-gray-900" }, ft = { class: "text-xs text-gray-500" }, mt = { class: "flex justify-center gap-2" }, pt = ["checked", "onChange"], yt = { class: "text-sm font-medium text-gray-900" }, vt = /* @__PURE__ */ R({
81
+ }), ut = { class: "flex flex-col flex-1 min-h-0" }, it = { class: "flex justify-between mb-3 gap-2" }, ct = { class: "text-left" }, dt = { class: "font-medium text-gray-900" }, ft = { class: "text-xs text-gray-500" }, mt = { class: "flex justify-center gap-2" }, pt = ["checked", "onChange"], yt = { class: "text-sm font-medium text-gray-900" }, vt = /* @__PURE__ */ F({
82
82
  __name: "cartocss-data-tab",
83
83
  props: {
84
84
  modelValue: { default: [] },
85
85
  modelModifiers: {}
86
86
  },
87
87
  emits: /* @__PURE__ */ Me(["save"], ["update:modelValue"]),
88
- setup(j, { emit: r }) {
89
- const c = [
88
+ setup(L, { emit: l }) {
89
+ const u = [
90
90
  { key: "table", label: "Таблиця", slot: "datasetCell" },
91
91
  {
92
92
  key: "active",
@@ -100,9 +100,9 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
100
100
  slot: "zoomCell",
101
101
  width: "140px"
102
102
  }
103
- ], V = ee(
104
- () => import("@opengis/core").then((b) => b.VsModal)
105
- ), w = ee(() => import("@opengis/form")), g = je(j, "modelValue"), u = r, d = x(!1), s = x({
103
+ ], z = ee(
104
+ () => import("@opengis/core").then((x) => x.VsModal)
105
+ ), _ = ee(() => import("@opengis/form")), h = je(L, "modelValue"), i = l, d = g(!1), s = g({
106
106
  table: "",
107
107
  query: "",
108
108
  srid: "",
@@ -139,28 +139,28 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
139
139
  function k() {
140
140
  d.value = !1;
141
141
  }
142
- function L() {
143
- var f, p;
144
- const b = (f = s.value.table) == null ? void 0 : f.trim(), h = (p = s.value.key) == null ? void 0 : p.trim();
145
- if (!b || !h) {
146
- B({
142
+ function q() {
143
+ var f, w;
144
+ const x = (f = s.value.table) == null ? void 0 : f.trim(), v = (w = s.value.key) == null ? void 0 : w.trim();
145
+ if (!x || !v) {
146
+ P({
147
147
  type: "warning",
148
148
  title: "Перевірка",
149
149
  message: "Вкажіть таблицю та підпис"
150
150
  });
151
151
  return;
152
152
  }
153
- g.value = [
154
- ...Array.isArray(g.value) ? g.value : [],
155
- { ...s.value, table: b, key: h }
153
+ h.value = [
154
+ ...Array.isArray(h.value) ? h.value : [],
155
+ { ...s.value, table: x, key: v }
156
156
  ], d.value = !1;
157
157
  }
158
- function v(b, h) {
159
- var p;
160
- const f = ((p = h == null ? void 0 : h.target) == null ? void 0 : p.checked) ?? !1;
161
- b.active = f, g.value = Array.isArray(g.value) ? [...g.value] : [];
158
+ function p(x, v) {
159
+ var w;
160
+ const f = ((w = v == null ? void 0 : v.target) == null ? void 0 : w.checked) ?? !1;
161
+ x.active = f, h.value = Array.isArray(h.value) ? [...h.value] : [];
162
162
  }
163
- return (b, h) => (_(), S("div", ut, [
163
+ return (x, v) => (b(), $("div", ut, [
164
164
  a("div", it, [
165
165
  a("button", {
166
166
  type: "button",
@@ -170,45 +170,45 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
170
170
  a("button", {
171
171
  type: "button",
172
172
  class: "inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md font-medium bg-gradient-to-r from-sky-400 to-blue-400 hover:from-sky-500 hover:to-blue-500 text-white shadow-sm px-4 py-2 h-9 text-xs transition-all duration-300",
173
- onClick: h[0] || (h[0] = (f) => u("save"))
173
+ onClick: v[0] || (v[0] = (f) => i("save"))
174
174
  }, " Зберегти ")
175
175
  ]),
176
- $(Ke, {
177
- modelValue: g.value,
178
- "onUpdate:modelValue": h[1] || (h[1] = (f) => g.value = f),
179
- "columns-scheme": c,
176
+ V(Ke, {
177
+ modelValue: h.value,
178
+ "onUpdate:modelValue": v[1] || (v[1] = (f) => h.value = f),
179
+ "columns-scheme": u,
180
180
  "form-scheme": m,
181
181
  "add-button": !1,
182
182
  "main-col-width": "260px"
183
183
  }, {
184
- datasetCell: O(({ row: f }) => [
184
+ datasetCell: R(({ row: f }) => [
185
185
  a("div", ct, [
186
- a("div", dt, N(f.table), 1),
187
- a("div", ft, N(f.key), 1)
186
+ a("div", dt, E(f.table), 1),
187
+ a("div", ft, E(f.key), 1)
188
188
  ])
189
189
  ]),
190
- activeCell: O(({ row: f }) => [
190
+ activeCell: R(({ row: f }) => [
191
191
  a("label", mt, [
192
192
  a("input", {
193
193
  type: "checkbox",
194
194
  class: "h-4 w-4 text-sky-500 border-gray-300 rounded focus:ring-sky-300",
195
195
  checked: f.active,
196
- onChange: (p) => v(f, p)
196
+ onChange: (w) => p(f, w)
197
197
  }, null, 40, pt)
198
198
  ])
199
199
  ]),
200
- zoomCell: O(({ row: f }) => [
201
- a("div", yt, N(f.zoom), 1)
200
+ zoomCell: R(({ row: f }) => [
201
+ a("div", yt, E(f.zoom), 1)
202
202
  ]),
203
203
  _: 1
204
204
  }, 8, ["modelValue"]),
205
- $(J(V), {
205
+ V(J(z), {
206
206
  teleport: "#modal",
207
207
  visible: d.value,
208
- "onUpdate:visible": h[3] || (h[3] = (f) => d.value = f),
208
+ "onUpdate:visible": v[3] || (v[3] = (f) => d.value = f),
209
209
  title: "Нова таблиця CartoCSS"
210
210
  }, {
211
- footer: O(() => [
211
+ footer: R(() => [
212
212
  a("div", { class: "flex justify-end gap-2 p-4 border-т" }, [
213
213
  a("button", {
214
214
  type: "button",
@@ -218,14 +218,14 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
218
218
  a("button", {
219
219
  type: "button",
220
220
  class: "px-4 py-2 rounded bg-blue-600 text-white",
221
- onClick: L
221
+ onClick: q
222
222
  }, " Додати ")
223
223
  ])
224
224
  ]),
225
- default: O(() => [
226
- $(J(w), {
225
+ default: R(() => [
226
+ V(J(_), {
227
227
  values: s.value,
228
- "onUpdate:values": h[2] || (h[2] = (f) => s.value = f),
228
+ "onUpdate:values": v[2] || (v[2] = (f) => s.value = f),
229
229
  schema: m
230
230
  }, null, 8, ["values"])
231
231
  ]),
@@ -233,22 +233,22 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
233
233
  }, 8, ["visible"])
234
234
  ]));
235
235
  }
236
- }), ht = { class: "flex flex-col flex-1 min-h-0 gap-4" }, gt = { class: "h-[calc(100vh-230px)] rounded-md border border-gray-200 bg-white" }, xt = /* @__PURE__ */ R({
236
+ }), ht = { class: "flex flex-col flex-1 min-h-0 gap-4" }, gt = { class: "h-[calc(100vh-230px)] rounded-md border border-gray-200 bg-white" }, xt = /* @__PURE__ */ F({
237
237
  __name: "cartocss-card-tab",
238
238
  props: {
239
239
  card: {},
240
240
  table: {}
241
241
  },
242
242
  emits: ["save"],
243
- setup(j, { emit: r }) {
244
- const c = j, V = r, w = x(c.table), g = x(c.card), u = ee(() => import("@opengis/form").then((s) => s.VsInputText));
243
+ setup(L, { emit: l }) {
244
+ const u = L, z = l, _ = g(u.table), h = g(u.card), i = ee(() => import("@opengis/form").then((s) => s.VsInputText));
245
245
  function d() {
246
- V("save", {
247
- card_html: g.value,
248
- card_table: w.value
246
+ z("save", {
247
+ card_html: h.value,
248
+ card_table: _.value
249
249
  });
250
250
  }
251
- return (s, m) => (_(), S("div", ht, [
251
+ return (s, m) => (b(), $("div", ht, [
252
252
  a("div", { class: "flex items-center justify-end gap-3" }, [
253
253
  a("button", {
254
254
  type: "button",
@@ -275,15 +275,15 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
275
275
  ])])
276
276
  ]),
277
277
  a("div", null, [
278
- $(J(u), {
279
- modelValue: w.value,
280
- "onUpdate:modelValue": m[0] || (m[0] = (n) => w.value = n)
278
+ V(J(i), {
279
+ modelValue: _.value,
280
+ "onUpdate:modelValue": m[0] || (m[0] = (n) => _.value = n)
281
281
  }, null, 8, ["modelValue"])
282
282
  ]),
283
283
  a("div", gt, [
284
- $(xe, {
285
- modelValue: g.value,
286
- "onUpdate:modelValue": m[1] || (m[1] = (n) => g.value = n),
284
+ V(xe, {
285
+ modelValue: h.value,
286
+ "onUpdate:modelValue": m[1] || (m[1] = (n) => h.value = n),
287
287
  language: "html",
288
288
  theme: "vs-light",
289
289
  class: "h-full w-full rounded-md"
@@ -291,7 +291,7 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
291
291
  ])
292
292
  ]));
293
293
  }
294
- }), bt = /* @__PURE__ */ R({
294
+ }), bt = /* @__PURE__ */ F({
295
295
  __name: "CartocssLayerLoader",
296
296
  props: {
297
297
  layerId: { type: String, required: !0 },
@@ -301,124 +301,126 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
301
301
  owner: { type: String, default: "" },
302
302
  opacity: { type: Number, default: 1 }
303
303
  },
304
- setup(j) {
305
- const r = j, c = ge(), {
306
- activateTemporaryLayer: V,
307
- deactivateTemporaryLayer: w,
308
- setTemporaryLayerOpacity: g
309
- } = Re(c.map), u = C(() => {
304
+ setup(L) {
305
+ const l = L, u = ge(), {
306
+ activateTemporaryLayer: z,
307
+ deactivateTemporaryLayer: _,
308
+ setTemporaryLayerOpacity: h
309
+ } = Re(u.map), i = S(() => {
310
310
  var k;
311
- const n = `${(k = r == null ? void 0 : r.tileUrl) == null ? void 0 : k.trim()}`;
311
+ const n = `${(k = l == null ? void 0 : l.tileUrl) == null ? void 0 : k.trim()}`;
312
312
  return n ? typeof window > "u" || typeof location > "u" || /^https?:\/\//i.test(n) ? n : n.startsWith("//") ? `${window.location.protocol}${n}` : n.startsWith("/") ? `${location.origin}${n}` : `${location.origin}/${n}` : "";
313
313
  });
314
314
  let d = "", s = "";
315
315
  function m() {
316
- const n = r.active && !!u.value;
317
- d && (!n || d !== r.layerId) && (w(d, s || void 0), d = "", s = ""), n && (V(
316
+ const n = l.active && !!i.value;
317
+ d && (!n || d !== l.layerId) && (_(d, s || void 0), d = "", s = ""), n && (z(
318
318
  {
319
- id: r.layerId,
320
- title: r.title || r.layerId,
321
- url: u.value,
322
- opacity: r.opacity
319
+ id: l.layerId,
320
+ title: l.title || l.layerId,
321
+ url: i.value,
322
+ opacity: l.opacity
323
323
  },
324
324
  {},
325
- r.owner
326
- ), d = r.layerId, s = r.owner || "");
325
+ l.owner
326
+ ), d = l.layerId, s = l.owner || "");
327
327
  }
328
- return A(
329
- () => [r.layerId, u.value, r.active, r.owner],
328
+ return N(
329
+ () => [l.layerId, i.value, l.active, l.owner],
330
330
  m,
331
331
  { immediate: !0 }
332
- ), A(
333
- () => r.opacity,
332
+ ), N(
333
+ () => l.opacity,
334
334
  (n) => {
335
- !d || !r.active || g(d, n, s || void 0);
335
+ !d || !l.active || h(d, n, s || void 0);
336
336
  },
337
337
  { immediate: !0 }
338
338
  ), Le(() => {
339
- d && (w(d, s || void 0), d = "", s = "");
340
- }), (n, k) => q("", !0);
339
+ d && (_(d, s || void 0), d = "", s = "");
340
+ }), (n, k) => A("", !0);
341
341
  }
342
- }), _t = /* @__PURE__ */ R({
342
+ }), _t = /* @__PURE__ */ F({
343
343
  __name: "CartocssMapClickListener",
344
344
  props: {
345
345
  cartocssId: {},
346
346
  infoEnabled: { type: [Boolean, null] }
347
347
  },
348
- setup(j) {
349
- const r = j, c = C(() => r.cartocssId ?? null), V = C(() => !!r.infoEnabled), { map: w, ready: g } = ge(), u = (v) => {
350
- !v || typeof window > "u" || window.dispatchEvent(
351
- new CustomEvent(Be, { detail: v })
348
+ setup(L) {
349
+ const l = L, u = S(() => l.cartocssId ?? null), z = S(() => !!l.infoEnabled), { map: _, ready: h } = ge(), i = (p) => {
350
+ !p || typeof window > "u" || window.dispatchEvent(
351
+ new CustomEvent(Be, { detail: p })
352
352
  );
353
- }, d = async (v) => {
354
- const b = await fetch(`/api/map-format?${v.toString()}`);
355
- if (!b.ok)
356
- throw new Error(`API returned ${b.status}`);
357
- return b.json();
353
+ }, d = async (p) => {
354
+ const x = await fetch(`/api/map-format?${p.toString()}`);
355
+ if (!x.ok)
356
+ throw new Error(`API returned ${x.status}`);
357
+ return x.json();
358
358
  };
359
359
  let s = null, m = null;
360
- const n = (v) => {
361
- if (!v) return null;
362
- if (typeof v == "string")
360
+ const n = (p) => {
361
+ if (!p) return null;
362
+ if (typeof p == "string")
363
363
  try {
364
- return JSON.parse(v);
364
+ return JSON.parse(p);
365
365
  } catch {
366
366
  return null;
367
367
  }
368
- return v;
369
- }, k = async (v, b) => {
370
- var f;
371
- const h = new URLSearchParams({
372
- layer: c.value ?? "",
373
- id: String(v)
368
+ return p;
369
+ }, k = async (p, x) => {
370
+ var w;
371
+ const v = u.value ? `external:${u.value},${String(p)}` : null, f = new URLSearchParams({
372
+ layer: u.value ?? "",
373
+ id: String(p)
374
374
  });
375
375
  try {
376
- const p = await d(h), E = typeof p.html == "string" ? p.html : null, U = n(
377
- ((f = p == null ? void 0 : p.data) == null ? void 0 : f.geom) ?? (p == null ? void 0 : p.geom) ?? null
376
+ const C = await d(f), U = typeof C.html == "string" ? C.html : null, I = n(
377
+ ((w = C == null ? void 0 : C.data) == null ? void 0 : w.geom) ?? (C == null ? void 0 : C.geom) ?? null
378
378
  );
379
- (E || U) && u({
380
- html: E,
381
- geometry: U ?? b
379
+ (U || I) && i({
380
+ html: U,
381
+ geometry: I ?? x,
382
+ infoToken: v
382
383
  });
383
- } catch (p) {
384
- console.warn("CartoCSS map-format (id) error", p);
384
+ } catch (C) {
385
+ console.warn("CartoCSS map-format (id) error", C);
385
386
  }
386
- }, L = async (v) => {
387
- var p, E, U, P;
388
- if (!c.value) return;
389
- if (!V.value) {
390
- B({
387
+ }, q = async (p) => {
388
+ var w, C, U, I;
389
+ if (!u.value) return;
390
+ if (!z.value) {
391
+ P({
391
392
  type: "error",
392
393
  title: "CartoCSS",
393
394
  message: "Картка не налаштована"
394
395
  });
395
396
  return;
396
397
  }
397
- const b = (p = v == null ? void 0 : v.lngLat) == null ? void 0 : p.lng, h = (E = v == null ? void 0 : v.lngLat) == null ? void 0 : E.lat;
398
- if (typeof b != "number" || typeof h != "number") return;
398
+ const x = (w = p == null ? void 0 : p.lngLat) == null ? void 0 : w.lng, v = (C = p == null ? void 0 : p.lngLat) == null ? void 0 : C.lat;
399
+ if (typeof x != "number" || typeof v != "number") return;
399
400
  const f = new URLSearchParams({
400
- layer: c.value,
401
- lat: h.toFixed(6),
402
- lng: b.toFixed(6)
401
+ layer: u.value,
402
+ lat: v.toFixed(6),
403
+ lng: x.toFixed(6)
403
404
  });
404
405
  try {
405
- const y = await d(f), T = n(
406
+ const y = await d(f), D = n(
406
407
  ((U = y == null ? void 0 : y.data) == null ? void 0 : U.geom) ?? (y == null ? void 0 : y.geom) ?? null
407
- ), D = ((P = y == null ? void 0 : y.data) == null ? void 0 : P.id) ?? (y == null ? void 0 : y.id);
408
- if (D != null) {
409
- await k(D, T);
408
+ ), O = ((I = y == null ? void 0 : y.data) == null ? void 0 : I.id) ?? (y == null ? void 0 : y.id);
409
+ if (O != null) {
410
+ await k(O, D);
410
411
  return;
411
412
  }
412
- Fe({ html: y == null ? void 0 : y.html }) && u({
413
+ Fe({ html: y == null ? void 0 : y.html }) && i({
413
414
  html: y == null ? void 0 : y.html,
414
- geometry: T
415
+ geometry: D,
416
+ infoToken: null
415
417
  });
416
418
  } catch (y) {
417
419
  console.warn("CartoCSS map-format error", y);
418
420
  }
419
421
  };
420
- return g().then(() => {
421
- m = w.value, m && (m.on("click", L), s = () => m == null ? void 0 : m.off("click", L));
422
+ return h().then(() => {
423
+ m = _.value, m && (m.on("click", q), s = () => m == null ? void 0 : m.off("click", q));
422
424
  }), he(() => {
423
425
  s == null || s(), s = null, m = null;
424
426
  }), () => {
@@ -427,108 +429,108 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
427
429
  }), wt = { class: "flex h-full bg-gradient-to-br from-slate-50 to-white" }, kt = { class: "flex-1 relative overflow-hidden" }, Ct = { class: "absolute top-0 left-0 w-full z-20" }, St = { class: "px-4 sm:px-6 py-4 border-b border-gray-200 bg-white shadow-sm" }, $t = { class: "flex items-start justify-between gap-4" }, Vt = { class: "flex-1 min-w-0" }, zt = { class: "flex items-center text-sm text-gray-500 mb-3" }, Mt = { class: "text-gray-900 font-medium truncate max-w-xs" }, jt = { class: "flex items-center justify-between gap-4" }, Lt = { class: "flex-1 min-w-0" }, qt = { class: "flex items-center gap-3 mb-1" }, At = { class: "text-base font-semibold text-gray-900 truncate" }, Nt = {
428
430
  key: 0,
429
431
  class: "px-2 py-0.5 bg-green-50 border border-green-200 rounded flex-shrink-0"
430
- }, Et = { class: "text-xs font-medium text-green-700" }, It = ["title"], Ut = { class: "w-full h-full bg-gradient-to-br from-sky-50 via-white to-blue-50 flex items-center justify-center relative pt-[115px]" }, Tt = { class: "relative w-full h-full" }, Dt = { class: "absolute top-[5.5rem] left-4 z-30 flex flex-col items-start gap-2" }, Ot = { class: "rounded-2xl bg-white/90 px-3 py-2 text-xs font-medium text-slate-600 shadow-sm backdrop-blur" }, Rt = { class: "flex items-center gap-2" }, Ft = { class: "rounded-2xl bg-white/90 px-3 py-2 text-xs font-medium text-slate-600 shadow-sm backdrop-blur" }, Bt = { class: "inline-flex items-center gap-2 text-[11px] text-slate-600" }, Pt = ["checked"], Qt = { class: "absolute top-4 left-4 z-20" }, Ht = { class: "absolute top-[6.5rem] right-2 space-y-1 z-20" }, Yt = { class: "flex-1 flex flex-col h-full" }, Jt = {
432
+ }, Et = { class: "text-xs font-medium text-green-700" }, Tt = ["title"], Ut = { class: "w-full h-full bg-gradient-to-br from-sky-50 via-white to-blue-50 flex items-center justify-center relative pt-[115px]" }, It = { class: "relative w-full h-full" }, Dt = { class: "absolute top-[5.5rem] left-4 z-30 flex flex-col items-start gap-2" }, Ot = { class: "rounded-2xl bg-white/90 px-3 py-2 text-xs font-medium text-slate-600 shadow-sm backdrop-blur" }, Rt = { class: "flex items-center gap-2" }, Ft = { class: "rounded-2xl bg-white/90 px-3 py-2 text-xs font-medium text-slate-600 shadow-sm backdrop-blur" }, Bt = { class: "inline-flex items-center gap-2 text-[11px] text-slate-600" }, Pt = ["checked"], Qt = { class: "absolute top-4 left-4 z-20" }, Ht = { class: "absolute top-[6.5rem] right-2 space-y-1 z-20" }, Yt = { class: "flex-1 flex flex-col h-full" }, Jt = {
431
433
  key: 0,
432
434
  class: "px-3 pt-3 pb-2 border-b border-gray-100"
433
435
  }, Wt = ["aria-selected", "onClick"], Xt = { class: "leading-none" }, Gt = { class: "flex flex-col flex-1 overflow-y-hidden p-3" }, Zt = {
434
436
  key: 0,
435
437
  class: "flex-1 flex items-center justify-center text-sm text-gray-500"
436
- }, Kt = "cartocss-demo-001", eo = "OpenGIS", ye = 2, Y = 5, co = /* @__PURE__ */ R({
438
+ }, Kt = "cartocss-demo-001", eo = "OpenGIS", ye = 2, Y = 5, co = /* @__PURE__ */ F({
437
439
  __name: "cartocss",
438
- setup(j) {
439
- const r = Te(), c = De(), V = x(null), w = [
440
+ setup(L) {
441
+ const l = Ie(), u = De(), z = g(null), _ = [
440
442
  { key: "css", label: "CSS", icon: Ye },
441
443
  { key: "data", label: "Дані", icon: nt },
442
444
  { key: "metadata", label: "Метадані", icon: Ze },
443
445
  { key: "card", label: "Картка", icon: Je }
444
- ], g = w.map((e) => e.key), u = x(
445
- g.includes(c.query.tab) ? c.query.tab : "css"
446
- ), d = x(!0), s = x(null), m = C(() => {
446
+ ], h = _.map((e) => e.key), i = g(
447
+ h.includes(u.query.tab) ? u.query.tab : "css"
448
+ ), d = g(!0), s = g(null), m = S(() => {
447
449
  var e;
448
- return (e = s.value) != null && e.source_path ? w.filter((o) => o.key === "card" || o.key === "metadata") : w;
449
- }), n = C(
450
- () => c.params.id || Kt
451
- ), k = x({
450
+ return (e = s.value) != null && e.source_path ? _.filter((o) => o.key === "card" || o.key === "metadata") : _;
451
+ }), n = S(
452
+ () => u.params.id || Kt
453
+ ), k = g({
452
454
  id: n.value,
453
455
  name: "",
454
456
  description: ""
455
457
  });
456
- let L = null;
457
- const v = x(!1);
458
- function b(e) {
459
- if (Array.isArray(e)) return b(e[0]);
458
+ let q = null;
459
+ const p = g(!1);
460
+ function x(e) {
461
+ if (Array.isArray(e)) return x(e[0]);
460
462
  if (typeof e != "string" && typeof e != "number") return null;
461
463
  const o = typeof e == "number" ? e : Number(e.trim());
462
464
  return Number.isFinite(o) ? o : null;
463
465
  }
464
- function h(e, o) {
466
+ function v(e, o) {
465
467
  return e.toFixed(o);
466
468
  }
467
469
  function f(e, o, t) {
468
- const l = 0.5 * 10 ** -t;
469
- return Math.abs(e - o) > l;
470
+ const r = 0.5 * 10 ** -t;
471
+ return Math.abs(e - o) > r;
470
472
  }
471
- function p() {
473
+ function w() {
472
474
  var e;
473
- return (e = V.value) == null ? void 0 : e.ctx;
475
+ return (e = z.value) == null ? void 0 : e.ctx;
474
476
  }
475
- function E() {
476
- var F, ie, ce, de;
477
- const e = (ie = (F = p()) == null ? void 0 : F.map) == null ? void 0 : ie.value;
477
+ function C() {
478
+ var B, ie, ce, de;
479
+ const e = (ie = (B = w()) == null ? void 0 : B.map) == null ? void 0 : ie.value;
478
480
  if (!e) return;
479
- const o = b(c.query.z), t = b(c.query.x), l = b(c.query.y);
480
- if (o == null || t == null || l == null) return;
481
- const i = (ce = e.getCenter) == null ? void 0 : ce.call(e), z = (de = e.getZoom) == null ? void 0 : de.call(e);
482
- (!i || f(i.lng, t, Y) || f(i.lat, l, Y) || f(z ?? 0, o, ye)) && (v.value = !0, e.jumpTo({ center: [t, l], zoom: o }), v.value = !1);
481
+ const o = x(u.query.z), t = x(u.query.x), r = x(u.query.y);
482
+ if (o == null || t == null || r == null) return;
483
+ const c = (ce = e.getCenter) == null ? void 0 : ce.call(e), M = (de = e.getZoom) == null ? void 0 : de.call(e);
484
+ (!c || f(c.lng, t, Y) || f(c.lat, r, Y) || f(M ?? 0, o, ye)) && (p.value = !0, e.jumpTo({ center: [t, r], zoom: o }), p.value = !1);
483
485
  }
484
486
  function U() {
485
- var i, z, M, F;
486
- if (v.value) return;
487
- const e = (z = (i = p()) == null ? void 0 : i.map) == null ? void 0 : z.value;
487
+ var c, M, j, B;
488
+ if (p.value) return;
489
+ const e = (M = (c = w()) == null ? void 0 : c.map) == null ? void 0 : M.value;
488
490
  if (!e) return;
489
- const o = (M = e.getCenter) == null ? void 0 : M.call(e), t = (F = e.getZoom) == null ? void 0 : F.call(e);
491
+ const o = (j = e.getCenter) == null ? void 0 : j.call(e), t = (B = e.getZoom) == null ? void 0 : B.call(e);
490
492
  if (!o || t == null) return;
491
- const l = {
492
- ...c.query,
493
- z: h(t, ye),
494
- x: h(o.lng, Y),
495
- y: h(o.lat, Y)
493
+ const r = {
494
+ ...u.query,
495
+ z: v(t, ye),
496
+ x: v(o.lng, Y),
497
+ y: v(o.lat, Y)
496
498
  };
497
- c.query.z === l.z && c.query.x === l.x && c.query.y === l.y || r.replace({ query: l });
499
+ u.query.z === r.z && u.query.x === r.x && u.query.y === r.y || l.replace({ query: r });
498
500
  }
499
- function P(e) {
501
+ function I(e) {
500
502
  typeof document > "u" || (document.title = e ? `${e} — CartoCSS` : eo);
501
503
  }
502
- const y = x("");
503
- x("");
504
- const T = x([]), D = x(!1), te = x(!1), W = x(""), X = x(0), Q = x(!1), H = x(1), G = x(!0), be = C(() => `cartocss-layer-${n.value}`), _e = C(() => `${Math.round(H.value * 100)}%`), we = C(() => `cartocss-extent-${n.value}`), oe = C(() => {
505
- var i;
506
- const e = (i = W.value) == null ? void 0 : i.trim();
504
+ const y = g("");
505
+ g("");
506
+ const D = g([]), O = g(!1), te = g(!1), W = g(""), X = g(0), Q = g(!1), H = g(1), G = g(!0), be = S(() => `cartocss-layer-${n.value}`), _e = S(() => `${Math.round(H.value * 100)}%`), we = S(() => `cartocss-extent-${n.value}`), oe = S(() => {
507
+ var c;
508
+ const e = (c = W.value) == null ? void 0 : c.trim();
507
509
  if (!e) return "";
508
- const o = e.includes("?") ? "&" : "?", t = `${e}${o}nottl=1`, l = X.value;
509
- return l ? `${e}${o}ts=${l}&nocache=1` : t;
510
+ const o = e.includes("?") ? "&" : "?", t = `${e}${o}nottl=1`, r = X.value;
511
+ return r ? `${e}${o}ts=${r}&nocache=1` : t;
510
512
  });
511
- C(() => {
513
+ S(() => {
512
514
  const e = s.value;
513
515
  return e ? e.cartocss_key || e.source_path || n.value || "" : n.value || "";
514
516
  });
515
- const ae = x(""), ne = x(""), se = C(() => {
516
- var z;
517
- const e = (z = s.value) == null ? void 0 : z.bounds;
517
+ const ae = g(""), ne = g(""), se = S(() => {
518
+ var M;
519
+ const e = (M = s.value) == null ? void 0 : M.bounds;
518
520
  if (!Array.isArray(e) || e.length < 4) return null;
519
- const [o, t, l, i] = e;
520
- return [o, t, l, i].some(
521
- (M) => typeof M != "number" || Number.isNaN(M)
522
- ) ? null : [(o + l) / 2, (t + i) / 2];
523
- }), ke = C(() => {
524
- var z;
525
- const e = (z = s.value) == null ? void 0 : z.bounds;
521
+ const [o, t, r, c] = e;
522
+ return [o, t, r, c].some(
523
+ (j) => typeof j != "number" || Number.isNaN(j)
524
+ ) ? null : [(o + r) / 2, (t + c) / 2];
525
+ }), ke = S(() => {
526
+ var M;
527
+ const e = (M = s.value) == null ? void 0 : M.bounds;
526
528
  if (!Array.isArray(e) || e.length < 4) return null;
527
- const [o, t, l, i] = e;
528
- return [o, t, l, i].some(
529
- (M) => typeof M != "number" || Number.isNaN(M)
530
- ) ? null : [o, t, l, i];
531
- }), Z = C(() => {
529
+ const [o, t, r, c] = e;
530
+ return [o, t, r, c].some(
531
+ (j) => typeof j != "number" || Number.isNaN(j)
532
+ ) ? null : [o, t, r, c];
533
+ }), Z = S(() => {
532
534
  const e = s.value;
533
535
  return e ? [
534
536
  e.description,
@@ -537,60 +539,60 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
537
539
  e.is_public === !0 ? "Публічний" : "Не публічний",
538
540
  e.enabled === !0 ? "Активний" : "Неактивний"
539
541
  ].filter(Boolean).join(", ") : "";
540
- }), re = C(() => {
542
+ }), le = S(() => {
541
543
  var o;
542
544
  const e = (o = s.value) == null ? void 0 : o.group_id;
543
545
  return e ? String(e).toUpperCase() : "";
544
546
  });
545
- A(
547
+ N(
546
548
  n,
547
549
  (e) => {
548
550
  e && K(e);
549
551
  },
550
552
  { immediate: !0 }
551
- ), A(
553
+ ), N(
552
554
  () => {
553
555
  var e;
554
556
  return (e = k.value) == null ? void 0 : e.name;
555
557
  },
556
- (e) => P(e),
558
+ (e) => I(e),
557
559
  { immediate: !0 }
558
560
  );
559
561
  async function Ce() {
560
- var l;
561
- const e = p();
562
+ var r;
563
+ const e = w();
562
564
  if (!(e != null && e.ready)) return;
563
- await e.ready(), E();
564
- const o = (l = e.map) == null ? void 0 : l.value;
565
+ await e.ready(), C();
566
+ const o = (r = e.map) == null ? void 0 : r.value;
565
567
  if (!o) return;
566
568
  const t = () => U();
567
- o.on("moveend", t), o.on("zoomend", t), L = () => {
569
+ o.on("moveend", t), o.on("zoomend", t), q = () => {
568
570
  o.off("moveend", t), o.off("zoomend", t);
569
571
  };
570
572
  }
571
- A(
572
- () => [c.query.z, c.query.x, c.query.y],
573
+ N(
574
+ () => [u.query.z, u.query.x, u.query.y],
573
575
  () => {
574
- E();
576
+ C();
575
577
  }
576
578
  ), qe(() => {
577
579
  Ce();
578
580
  }), he(() => {
579
- L == null || L(), L = null;
580
- }), A(
581
- () => c.query.tab,
581
+ q == null || q(), q = null;
582
+ }), N(
583
+ () => u.query.tab,
582
584
  (e) => {
583
- e && m.value.some((o) => o.key === e) && u.value !== e && (u.value = e);
585
+ e && m.value.some((o) => o.key === e) && i.value !== e && (i.value = e);
584
586
  }
585
- ), A(
587
+ ), N(
586
588
  m,
587
589
  (e) => {
588
- e.length && !e.some((o) => o.key === u.value) && (u.value = e[0].key);
590
+ e.length && !e.some((o) => o.key === i.value) && (i.value = e[0].key);
589
591
  },
590
592
  { immediate: !0 }
591
- ), A(u, (e) => {
592
- c.query.tab !== e && m.value.some((o) => o.key === e) && r.replace({ query: { ...c.query, tab: e } });
593
- }), A(
593
+ ), N(i, (e) => {
594
+ u.query.tab !== e && m.value.some((o) => o.key === e) && l.replace({ query: { ...u.query, tab: e } });
595
+ }), N(
594
596
  () => s.value,
595
597
  (e) => {
596
598
  const o = e == null ? void 0 : e.card_html;
@@ -598,7 +600,7 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
598
600
  },
599
601
  { immediate: !0 }
600
602
  );
601
- function le() {
603
+ function re() {
602
604
  n.value && K(n.value, { bustCache: !0 });
603
605
  }
604
606
  async function Se(e, o) {
@@ -611,9 +613,9 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
611
613
  body: JSON.stringify(e)
612
614
  });
613
615
  if (!t.ok) throw new Error(`Failed to save cartocss: ${t.status}`);
614
- B({ type: "success", title: "Збережено", message: o }), await K(n.value, { bustCache: !0 });
616
+ P({ type: "success", title: "Збережено", message: o }), await K(n.value, { bustCache: !0 });
615
617
  } catch (t) {
616
- console.error("Failed to save CartoCSS", t), B({ type: "error", title: "Помилка", message: "Не вдалося зберегти CartoCSS" });
618
+ console.error("Failed to save CartoCSS", t), P({ type: "error", title: "Помилка", message: "Не вдалося зберегти CartoCSS" });
617
619
  } finally {
618
620
  te.value = !1;
619
621
  }
@@ -631,8 +633,8 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
631
633
  }
632
634
  function Ve(e) {
633
635
  const o = Array.isArray(e) ? e : e == null ? void 0 : e.datasets;
634
- return Array.isArray(o) ? o.map((t, l) => ({
635
- table: (t == null ? void 0 : t.table) || (t == null ? void 0 : t.id) || `dataset_${l + 1}`,
636
+ return Array.isArray(o) ? o.map((t, r) => ({
637
+ table: (t == null ? void 0 : t.table) || (t == null ? void 0 : t.id) || `dataset_${r + 1}`,
636
638
  query: (t == null ? void 0 : t.query) || "",
637
639
  srid: (t == null ? void 0 : t.srid) || "",
638
640
  key: (t == null ? void 0 : t.key) || (t == null ? void 0 : t.label) || "Без підпису",
@@ -644,31 +646,31 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
644
646
  })) : [];
645
647
  }
646
648
  async function K(e, o) {
647
- D.value = !0;
649
+ O.value = !0;
648
650
  try {
649
651
  const t = await fetch(`/api/gis-css/${e}`);
650
652
  if (!t.ok) throw new Error(`Failed to load cartocss: ${t.status}`);
651
- const l = await t.json(), i = (l == null ? void 0 : l.message) || l || {};
652
- s.value = i, k.value = {
653
- id: i.cartocss_key || e,
654
- name: i.name || k.value.name,
655
- description: i.description || k.value.description
656
- }, y.value = typeof i.style == "string" ? i.style : "";
657
- const z = $e(i.config ?? []);
658
- T.value = Ve(z);
659
- const M = typeof i.url == "string" ? i.url : "";
660
- W.value = M, Q.value = !!(M && i.enabled !== !1), X.value = o != null && o.bustCache ? Date.now() : 0;
653
+ const r = await t.json(), c = (r == null ? void 0 : r.message) || r || {};
654
+ s.value = c, k.value = {
655
+ id: c.cartocss_key || e,
656
+ name: c.name || k.value.name,
657
+ description: c.description || k.value.description
658
+ }, y.value = typeof c.style == "string" ? c.style : "";
659
+ const M = $e(c.config ?? []);
660
+ D.value = Ve(M);
661
+ const j = typeof c.url == "string" ? c.url : "";
662
+ W.value = j, Q.value = !!(j && c.enabled !== !1), X.value = o != null && o.bustCache ? Date.now() : 0;
661
663
  } catch (t) {
662
664
  console.error("Failed to fetch CartoCSS", t), Q.value = !1, W.value = "", X.value = 0, s.value = null;
663
665
  } finally {
664
- D.value = !1;
666
+ O.value = !1;
665
667
  }
666
668
  }
667
669
  async function ue() {
668
670
  await Se(
669
671
  {
670
672
  style: y.value || "",
671
- config: T.value
673
+ config: D.value
672
674
  },
673
675
  "CartoCSS оновлено"
674
676
  );
@@ -680,9 +682,9 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
680
682
  body: JSON.stringify(e)
681
683
  });
682
684
  if (!o.ok) throw new Error(`Failed to save cartocss: ${o.status}`);
683
- B({ type: "success", title: "Збережено", message: "Картка CartoCSS оновлена" });
685
+ P({ type: "success", title: "Збережено", message: "Картка CartoCSS оновлена" });
684
686
  }
685
- return (e, o) => (_(), S("div", wt, [
687
+ return (e, o) => (b(), $("div", wt, [
686
688
  a("div", kt, [
687
689
  a("div", Ct, [
688
690
  a("div", St, [
@@ -692,7 +694,7 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
692
694
  a("button", {
693
695
  type: "button",
694
696
  class: "hover:text-gray-700 cursor-pointer transition-colors",
695
- onClick: o[0] || (o[0] = (t) => J(r).push("/gis.cartocss"))
697
+ onClick: o[0] || (o[0] = (t) => J(l).push("/gis.cartocss"))
696
698
  }, " CartoCSS "),
697
699
  o[6] || (o[6] = a("svg", {
698
700
  xmlns: "http://www.w3.org/2000/svg",
@@ -708,25 +710,25 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
708
710
  }, [
709
711
  a("path", { d: "m9 18 6-6-6-6" })
710
712
  ], -1)),
711
- a("span", Mt, N(k.value.name || "CartoCSS"), 1)
713
+ a("span", Mt, E(k.value.name || "CartoCSS"), 1)
712
714
  ]),
713
715
  a("div", jt, [
714
716
  a("div", Lt, [
715
717
  a("div", qt, [
716
- a("h1", At, N(k.value.name || "CartoCSS"), 1),
717
- re.value ? (_(), S("div", Nt, [
718
- a("span", Et, N(re.value), 1)
719
- ])) : q("", !0)
718
+ a("h1", At, E(k.value.name || "CartoCSS"), 1),
719
+ le.value ? (b(), $("div", Nt, [
720
+ a("span", Et, E(le.value), 1)
721
+ ])) : A("", !0)
720
722
  ]),
721
- Z.value ? (_(), S("p", {
723
+ Z.value ? (b(), $("p", {
722
724
  key: 0,
723
725
  class: "text-xs text-gray-500 truncate",
724
726
  title: Z.value
725
- }, N(Z.value), 9, It)) : q("", !0)
727
+ }, E(Z.value), 9, Tt)) : A("", !0)
726
728
  ])
727
729
  ])
728
730
  ]),
729
- $(We, {
731
+ V(We, {
730
732
  class: "flex-shrink-0",
731
733
  "entity-id": n.value,
732
734
  "entity-info": k.value,
@@ -734,26 +736,26 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
734
736
  "save-endpoint": (t) => `/api/gis-css/${t}`,
735
737
  "entity-label": "CartoCSS",
736
738
  "save-method": "post",
737
- onSaved: le
739
+ onSaved: re
738
740
  }, null, 8, ["entity-id", "entity-info", "form-endpoint", "save-endpoint"])
739
741
  ])
740
742
  ])
741
743
  ]),
742
744
  a("div", Ut, [
743
- a("div", Tt, [
744
- $(Pe, {
745
+ a("div", It, [
746
+ V(Pe, {
745
747
  ref_key: "mapViewRef",
746
- ref: V
748
+ ref: z
747
749
  }, {
748
- default: O(() => {
749
- var t, l;
750
+ default: R(() => {
751
+ var t, r;
750
752
  return [
751
753
  a("div", Dt, [
752
754
  a("div", Ot, [
753
755
  a("div", Rt, [
754
756
  o[7] || (o[7] = a("span", null, "Прозорість:", -1)),
755
757
  Ae(a("input", {
756
- "onUpdate:modelValue": o[1] || (o[1] = (i) => H.value = i),
758
+ "onUpdate:modelValue": o[1] || (o[1] = (c) => H.value = c),
757
759
  type: "range",
758
760
  min: "0",
759
761
  max: "1",
@@ -768,7 +770,7 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
768
770
  { number: !0 }
769
771
  ]
770
772
  ]),
771
- a("span", null, N(_e.value), 1)
773
+ a("span", null, E(_e.value), 1)
772
774
  ])
773
775
  ]),
774
776
  a("div", Ft, [
@@ -777,25 +779,25 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
777
779
  type: "checkbox",
778
780
  class: "h-3.5 w-3.5 rounded border-slate-300 text-blue-600 focus:ring-blue-200",
779
781
  checked: G.value,
780
- onChange: o[2] || (o[2] = (i) => G.value = i.target.checked)
782
+ onChange: o[2] || (o[2] = (c) => G.value = c.target.checked)
781
783
  }, null, 40, Pt),
782
784
  o[8] || (o[8] = a("span", null, "Межі css", -1))
783
785
  ])
784
786
  ])
785
787
  ]),
786
788
  a("div", Qt, [
787
- $(Qe)
789
+ V(Qe)
788
790
  ]),
789
791
  a("div", Ht, [
790
- $(pe),
791
- se.value ? (_(), I(pe, {
792
+ V(pe),
793
+ se.value ? (b(), T(pe, {
792
794
  key: 0,
793
795
  targetCenter: se.value,
794
796
  targetLabel: "Центр даних",
795
797
  targetAriaLabel: "Перейти до центру даних"
796
- }, null, 8, ["targetCenter"])) : q("", !0)
798
+ }, null, 8, ["targetCenter"])) : A("", !0)
797
799
  ]),
798
- oe.value ? (_(), I(bt, {
800
+ oe.value ? (b(), T(bt, {
799
801
  key: 0,
800
802
  "layer-id": be.value,
801
803
  "tile-url": oe.value,
@@ -803,87 +805,87 @@ const nt = /* @__PURE__ */ Oe(tt, [["render", at]]), st = { class: "flex flex-co
803
805
  opacity: H.value,
804
806
  title: k.value.name,
805
807
  owner: n.value
806
- }, null, 8, ["layer-id", "tile-url", "active", "opacity", "title", "owner"])) : q("", !0),
807
- $(et, {
808
+ }, null, 8, ["layer-id", "tile-url", "active", "opacity", "title", "owner"])) : A("", !0),
809
+ V(et, {
808
810
  extent: G.value ? ke.value : null,
809
811
  "layer-id": we.value
810
812
  }, null, 8, ["extent", "layer-id"]),
811
- $(_t, {
813
+ V(_t, {
812
814
  "cartocss-id": n.value,
813
815
  bounds: ((t = s.value) == null ? void 0 : t.bounds) ?? null,
814
816
  active: Q.value,
815
- "info-enabled": (l = s.value) == null ? void 0 : l.info
817
+ "info-enabled": (r = s.value) == null ? void 0 : r.info
816
818
  }, null, 8, ["cartocss-id", "bounds", "active", "info-enabled"]),
817
- $(He, { "map-id": n.value }, null, 8, ["map-id"])
819
+ V(He, { "map-id": n.value }, null, 8, ["map-id"])
818
820
  ];
819
821
  }),
820
822
  _: 1
821
823
  }, 512)
822
824
  ])
823
825
  ]),
824
- s.value ? (_(), I(Xe, {
826
+ s.value ? (b(), T(Xe, {
825
827
  key: 0,
826
828
  open: d.value,
827
829
  onToggle: o[3] || (o[3] = (t) => d.value = !d.value)
828
- }, null, 8, ["open"])) : q("", !0)
830
+ }, null, 8, ["open"])) : A("", !0)
829
831
  ]),
830
- s.value ? (_(), S("div", {
832
+ s.value ? (b(), $("div", {
831
833
  key: 0,
832
834
  class: fe(["bg-white border-l border-gray-100 flex flex-col overflow-hidden shadow-lg flex-shrink-0 transition-[width] duration-100 ease-in-out", d.value ? "w-[650px]" : "w-0"])
833
835
  }, [
834
836
  a("div", Yt, [
835
- m.value.length > 1 ? (_(), S("div", Jt, [
837
+ m.value.length > 1 ? (b(), $("div", Jt, [
836
838
  a("div", {
837
839
  class: "items-center justify-center text-muted-foreground grid w-full h-12 p-1 bg-gray-50 rounded-xl shadow-sm",
838
840
  style: Ee({ gridTemplateColumns: `repeat(${m.value.length}, minmax(0, 1fr))` })
839
841
  }, [
840
- (_(!0), S(me, null, Ie(m.value, (t) => (_(), S("button", {
842
+ (b(!0), $(me, null, Te(m.value, (t) => (b(), $("button", {
841
843
  key: t.key,
842
844
  type: "button",
843
845
  role: "tab",
844
- "aria-selected": u.value === t.key,
846
+ "aria-selected": i.value === t.key,
845
847
  class: fe([
846
848
  "whitespace-nowrap flex flex-col items-center justify-center gap-0.5 py-1 px-1 text-[9px] font-medium transition-all duration-300 hover:bg-white/70 rounded-lg group",
847
- u.value === t.key ? "bg-white shadow-sm text-gray-700" : ""
849
+ i.value === t.key ? "bg-white shadow-sm text-gray-700" : ""
848
850
  ]),
849
- onClick: (l) => u.value = t.key
851
+ onClick: (r) => i.value = t.key
850
852
  }, [
851
- (_(), I(Ue(t.icon), { class: "h-3.5 w-3.5 mb-0.5" })),
852
- a("span", Xt, N(t.label), 1)
853
+ (b(), T(Ue(t.icon), { class: "h-3.5 w-3.5 mb-0.5" })),
854
+ a("span", Xt, E(t.label), 1)
853
855
  ], 10, Wt))), 128))
854
856
  ], 4)
855
- ])) : q("", !0),
857
+ ])) : A("", !0),
856
858
  a("div", Gt, [
857
- D.value ? (_(), S("div", Zt, " Завантаження стилю… ")) : (_(), S(me, { key: 1 }, [
858
- u.value === "css" ? (_(), I(lt, {
859
+ O.value ? (b(), $("div", Zt, " Завантаження стилю… ")) : (b(), $(me, { key: 1 }, [
860
+ i.value === "css" ? (b(), T(rt, {
859
861
  key: 0,
860
862
  modelValue: y.value,
861
863
  "onUpdate:modelValue": o[4] || (o[4] = (t) => y.value = t),
862
864
  class: "flex-1 min-h-0",
863
865
  onSave: ue
864
- }, null, 8, ["modelValue"])) : u.value === "data" ? (_(), I(vt, {
866
+ }, null, 8, ["modelValue"])) : i.value === "data" ? (b(), T(vt, {
865
867
  key: 1,
866
- modelValue: T.value,
867
- "onUpdate:modelValue": o[5] || (o[5] = (t) => T.value = t),
868
+ modelValue: D.value,
869
+ "onUpdate:modelValue": o[5] || (o[5] = (t) => D.value = t),
868
870
  class: "flex-1 min-h-0 flex flex-col",
869
871
  onSave: ue
870
- }, null, 8, ["modelValue"])) : u.value === "card" ? (_(), I(xt, {
872
+ }, null, 8, ["modelValue"])) : i.value === "card" ? (b(), T(xt, {
871
873
  key: 2,
872
874
  card: ae.value,
873
875
  table: ne.value,
874
876
  class: "flex-1 min-h-0",
875
877
  onSave: ze
876
- }, null, 8, ["card", "table"])) : u.value === "metadata" ? (_(), I(Ge, {
878
+ }, null, 8, ["card", "table"])) : i.value === "metadata" ? (b(), T(Ge, {
877
879
  key: 3,
878
880
  data: s.value,
879
881
  "entity-id": n.value,
880
882
  "entity-type": "css",
881
- onSaved: le
882
- }, null, 8, ["data", "entity-id"])) : q("", !0)
883
+ onSaved: re
884
+ }, null, 8, ["data", "entity-id"])) : A("", !0)
883
885
  ], 64))
884
886
  ])
885
887
  ])
886
- ], 2)) : q("", !0)
888
+ ], 2)) : A("", !0)
887
889
  ]));
888
890
  }
889
891
  });