@phila/layerboard 3.0.0-beta.31 → 3.0.0-beta.32

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.mjs CHANGED
@@ -1,7 +1,7 @@
1
- import { defineComponent as ye, ref as k, watch as Ie, computed as z, nextTick as Ne, onMounted as et, onUnmounted as Rt, createElementBlock as $, openBlock as m, createVNode as H, unref as d, withCtx as Ge, createBlock as q, createCommentVNode as R, Fragment as ue, renderList as ve, useAttrs as qt, toRef as Gt, normalizeClass as re, createElementVNode as P, toDisplayString as G, renderSlot as pe, withDirectives as At, mergeProps as mt, vModelDynamic as Ht, createTextVNode as xe, normalizeProps as xt, guardReactiveProps as $t, normalizeStyle as fe, withModifiers as Jt, readonly as j, provide as Z, onBeforeUnmount as Kt, useId as Mt, resolveComponent as Qt, vShow as Xt } from "vue";
2
- import { Map as Yt, DrawTool as eo, RasterLayer as Pt, CircleLayer as Tt, FillLayer as Ft, LineLayer as pt, MapMarker as to, MapPopup as oo } from "@phila/phila-ui-map-core";
1
+ import { defineComponent as me, ref as x, watch as Ie, computed as D, nextTick as Ne, onMounted as ot, onUnmounted as Rt, createElementBlock as $, openBlock as h, createVNode as J, unref as f, withCtx as Ge, createBlock as G, createCommentVNode as R, Fragment as ue, renderList as be, useAttrs as qt, toRef as Gt, normalizeClass as re, createElementVNode as P, toDisplayString as H, renderSlot as pe, withDirectives as At, mergeProps as mt, vModelDynamic as Ht, createTextVNode as xe, normalizeProps as xt, guardReactiveProps as $t, normalizeStyle as fe, withModifiers as Jt, readonly as q, provide as Z, onBeforeUnmount as Kt, useId as Mt, resolveComponent as Qt, vShow as Xt } from "vue";
2
+ import { Map as Yt, DrawTool as eo, RasterLayer as Pt, CircleLayer as Ft, FillLayer as Tt, LineLayer as yt, MapMarker as to, MapPopup as oo } from "@phila/phila-ui-map-core";
3
3
  import { cn as ht, Icon as ke, BaseLink as ao, ActionContent as Et } from "@phila/phila-ui-core";
4
- const io = { class: "map-panel" }, lo = /* @__PURE__ */ ye({
4
+ const io = { class: "map-panel" }, lo = /* @__PURE__ */ me({
5
5
  __name: "MapPanel",
6
6
  props: {
7
7
  visibleLayers: {},
@@ -24,119 +24,119 @@ const io = { class: "map-panel" }, lo = /* @__PURE__ */ ye({
24
24
  },
25
25
  emits: ["zoom", "layerLoading", "layerError"],
26
26
  setup(e, { emit: i }) {
27
- const l = e, o = i, r = k(null), n = k(null), c = k(0);
28
- function w(t) {
27
+ const l = e, o = i, r = x(null), n = x(null), c = x(0);
28
+ function b(t) {
29
29
  o("zoom", t), n.value && (c.value = p(n.value));
30
30
  }
31
31
  function p(t) {
32
- const u = t.getZoom(), b = t.getCenter().lat, C = 559082264028e-3, F = b * Math.PI / 180;
33
- return C * Math.cos(F) / Math.pow(2, u);
34
- }
35
- const x = k({}), h = k(null), g = k(/* @__PURE__ */ new Set());
36
- async function a(t, u, s, b, C) {
37
- const F = encodeURIComponent(b || "1=1"), B = JSON.stringify({
38
- xmin: u.west,
39
- ymin: u.south,
40
- xmax: u.east,
41
- ymax: u.north,
32
+ const d = t.getZoom(), S = t.getCenter().lat, k = 559082264028e-3, O = S * Math.PI / 180;
33
+ return k * Math.cos(O) / Math.pow(2, d);
34
+ }
35
+ const C = x({}), y = x(null), g = x(/* @__PURE__ */ new Set());
36
+ async function a(t, d, s, S, k) {
37
+ const O = encodeURIComponent(S || "1=1"), B = JSON.stringify({
38
+ xmin: d.west,
39
+ ymin: d.south,
40
+ xmax: d.east,
41
+ ymax: d.north,
42
42
  spatialReference: { wkid: 4326 }
43
- }), Y = C !== void 0 && C < 14 ? `&maxAllowableOffset=${360 / (Math.pow(2, C) * 512)}` : "", V = 2e3;
44
- let oe = 0, A = [], K = !0;
45
- for (; K; ) {
46
- const N = `${t}/query?where=${F}&geometry=${encodeURIComponent(B)}&geometryType=esriGeometryEnvelope&spatialRel=esriSpatialRelIntersects&outFields=*&returnGeometry=true&resultRecordCount=${V}&resultOffset=${oe}${Y}&f=geojson`, ne = await fetch(N);
43
+ }), ee = k !== void 0 && k < 14 ? `&maxAllowableOffset=${360 / (Math.pow(2, k) * 512)}` : "", N = 2e3;
44
+ let oe = 0, A = [], Q = !0;
45
+ for (; Q; ) {
46
+ const U = `${t}/query?where=${O}&geometry=${encodeURIComponent(B)}&geometryType=esriGeometryEnvelope&spatialRel=esriSpatialRelIntersects&outFields=*&returnGeometry=true&resultRecordCount=${N}&resultOffset=${oe}${ee}&f=geojson`, ne = await fetch(U);
47
47
  if (!ne.ok)
48
48
  throw new Error(`HTTP ${ne.status}: ${ne.statusText}`);
49
49
  const ce = await ne.json();
50
- ce.features && ce.features.length > 0 ? (A = A.concat(ce.features), oe += ce.features.length, K = ce.features.length === V) : K = !1;
50
+ ce.features && ce.features.length > 0 ? (A = A.concat(ce.features), oe += ce.features.length, Q = ce.features.length === N) : Q = !1;
51
51
  }
52
- return A = A.map((N) => {
53
- if (N.properties) {
52
+ return A = A.map((U) => {
53
+ if (U.properties) {
54
54
  const ne = {};
55
- for (const ce of Object.keys(N.properties))
56
- ne[ce.toLowerCase()] = N.properties[ce];
57
- return { ...N, properties: ne };
55
+ for (const ce of Object.keys(U.properties))
56
+ ne[ce.toLowerCase()] = U.properties[ce];
57
+ return { ...U, properties: ne };
58
58
  }
59
- return N;
59
+ return U;
60
60
  }), {
61
61
  type: "FeatureCollection",
62
62
  features: A
63
63
  };
64
64
  }
65
- async function v(t, u, s) {
66
- const b = u.map(async (C) => {
67
- const F = l.layerList.find((B) => B.config.id === C)?.config;
68
- if (F && !(s !== void 0 && F.minZoom !== void 0 && s < F.minZoom)) {
69
- o("layerLoading", C, !0);
65
+ async function v(t, d, s) {
66
+ const S = d.map(async (k) => {
67
+ const O = l.layerList.find((B) => B.config.id === k)?.config;
68
+ if (O && !(s !== void 0 && O.minZoom !== void 0 && s < O.minZoom)) {
69
+ o("layerLoading", k, !0);
70
70
  try {
71
- const B = await a(F.url, t, C, F.where, s);
72
- x.value = { ...x.value, [C]: B }, o("layerError", C, null);
71
+ const B = await a(O.url, t, k, O.where, s);
72
+ C.value = { ...C.value, [k]: B }, o("layerError", k, null);
73
73
  } catch (B) {
74
- const Y = B instanceof Error ? B.message : "Failed to load";
75
- o("layerError", C, Y);
74
+ const ee = B instanceof Error ? B.message : "Failed to load";
75
+ o("layerError", k, ee);
76
76
  } finally {
77
- o("layerLoading", C, !1);
77
+ o("layerLoading", k, !1);
78
78
  }
79
79
  }
80
80
  });
81
- await Promise.all(b);
81
+ await Promise.all(S);
82
82
  }
83
- async function f(t, u) {
83
+ async function u(t, d) {
84
84
  const s = [...l.visibleLayers];
85
- await v(t, s, u);
85
+ await v(t, s, d);
86
86
  }
87
- function L(t) {
88
- h.value = t.bounds, f(t.bounds, t.zoom);
87
+ function w(t) {
88
+ y.value = t.bounds, u(t.bounds, t.zoom);
89
89
  }
90
- function S(t) {
90
+ function L(t) {
91
91
  n.value = t;
92
- const u = t.getBounds();
93
- h.value = {
94
- west: u.getWest(),
95
- south: u.getSouth(),
96
- east: u.getEast(),
97
- north: u.getNorth()
92
+ const d = t.getBounds();
93
+ y.value = {
94
+ west: d.getWest(),
95
+ south: d.getSouth(),
96
+ east: d.getEast(),
97
+ north: d.getNorth()
98
98
  };
99
99
  const s = t.getZoom();
100
- o("zoom", s), c.value = p(t), f(h.value, s);
100
+ o("zoom", s), c.value = p(t), u(y.value, s);
101
101
  }
102
102
  Ie(
103
103
  () => l.visibleLayers,
104
104
  async () => {
105
- if (se.value.length > 0 && ie(), h.value) {
106
- const t = new Set(l.visibleLayers), u = [...t].filter((s) => !g.value.has(s));
107
- if (g.value = new Set(t), u.length > 0) {
105
+ if (se.value.length > 0 && ie(), y.value) {
106
+ const t = new Set(l.visibleLayers), d = [...t].filter((s) => !g.value.has(s));
107
+ if (g.value = new Set(t), d.length > 0) {
108
108
  const s = n.value?.getZoom();
109
- await v(h.value, u, s);
109
+ await v(y.value, d, s);
110
110
  }
111
111
  }
112
112
  }
113
113
  );
114
- function E(t) {
114
+ function F(t) {
115
115
  return l.visibleLayers.has(t);
116
116
  }
117
- function D(t) {
118
- return !!x.value[t.id];
117
+ function E(t) {
118
+ return !!C.value[t.id];
119
119
  }
120
- const X = z(
121
- () => l.layerList.filter((t) => t.config.type === "circle" && E(t.config.id) && D(t.config)).map((t) => t.config)
122
- ), T = z(
123
- () => l.layerList.filter((t) => t.config.type === "fill" && E(t.config.id) && D(t.config)).map((t) => t.config)
124
- ), O = z(
120
+ const V = D(
121
+ () => l.layerList.filter((t) => t.config.type === "circle" && F(t.config.id) && E(t.config)).map((t) => t.config)
122
+ ), T = D(
123
+ () => l.layerList.filter((t) => t.config.type === "fill" && F(t.config.id) && E(t.config)).map((t) => t.config)
124
+ ), I = D(
125
125
  () => l.layerList.filter(
126
- (t) => t.config.type === "fill" && t.config.outlinePaint && E(t.config.id) && D(t.config)
126
+ (t) => t.config.type === "fill" && t.config.outlinePaint && F(t.config.id) && E(t.config)
127
127
  ).map((t) => t.config)
128
- ), _ = z(
129
- () => l.layerList.filter((t) => t.config.type === "line" && E(t.config.id) && D(t.config)).map((t) => t.config)
128
+ ), _ = D(
129
+ () => l.layerList.filter((t) => t.config.type === "line" && F(t.config.id) && E(t.config)).map((t) => t.config)
130
130
  );
131
131
  Ie(_, async (t) => {
132
132
  if (t.length < 2) return;
133
133
  await Ne();
134
- const u = n.value;
135
- if (u)
134
+ const d = n.value;
135
+ if (d)
136
136
  for (let s = t.length - 1; s >= 0; s--) {
137
- const b = s < t.length - 1 ? t[s + 1].id : "highlight-lines";
137
+ const S = s < t.length - 1 ? t[s + 1].id : "highlight-lines";
138
138
  try {
139
- u.getLayer(t[s].id) && u.moveLayer(t[s].id, b);
139
+ d.getLayer(t[s].id) && d.moveLayer(t[s].id, S);
140
140
  } catch {
141
141
  }
142
142
  }
@@ -144,56 +144,56 @@ const io = { class: "map-panel" }, lo = /* @__PURE__ */ ye({
144
144
  function te(t) {
145
145
  return l.visibleTiledLayers?.has(t) ?? !1;
146
146
  }
147
- function U(t) {
147
+ function W(t) {
148
148
  return l.tiledLayerOpacities?.[t] ?? 1;
149
149
  }
150
- function me(t) {
150
+ function he(t) {
151
151
  return `${t.replace(/\/$/, "")}/tile/{z}/{y}/{x}`;
152
152
  }
153
- function he(t) {
153
+ function ge(t) {
154
154
  return {
155
155
  type: "raster",
156
- tiles: [me(t.url)],
156
+ tiles: [he(t.url)],
157
157
  tileSize: 256,
158
158
  attribution: t.attribution || ""
159
159
  };
160
160
  }
161
- const Ue = k({}), Je = k(/* @__PURE__ */ new Set());
162
- async function lt(t) {
163
- if (!Je.value.has(t.id)) {
164
- Je.value.add(t.id);
161
+ const Ue = x({}), Ke = x(/* @__PURE__ */ new Set());
162
+ async function nt(t) {
163
+ if (!Ke.value.has(t.id)) {
164
+ Ke.value.add(t.id);
165
165
  try {
166
- const u = t.url.replace(/\/$/, ""), s = await fetch(`${u}?f=json`);
166
+ const d = t.url.replace(/\/$/, ""), s = await fetch(`${d}?f=json`);
167
167
  if (!s.ok)
168
168
  return;
169
- const b = await s.json(), C = b.minScale || 0;
170
- let F = b.maxScale || 0;
171
- if (b.layers && b.layers.length > 0)
172
- for (const B of b.layers)
173
- B.maxScale && B.maxScale > 0 && (F === 0 || B.maxScale < F) && (F = B.maxScale);
174
- F === 0 && (F = 72e3), Ue.value = {
169
+ const S = await s.json(), k = S.minScale || 0;
170
+ let O = S.maxScale || 0;
171
+ if (S.layers && S.layers.length > 0)
172
+ for (const B of S.layers)
173
+ B.maxScale && B.maxScale > 0 && (O === 0 || B.maxScale < O) && (O = B.maxScale);
174
+ O === 0 && (O = 72e3), Ue.value = {
175
175
  ...Ue.value,
176
- [t.id]: { minScale: C, maxScale: F }
176
+ [t.id]: { minScale: k, maxScale: O }
177
177
  };
178
178
  } catch {
179
179
  }
180
180
  }
181
181
  }
182
- et(() => {
182
+ ot(() => {
183
183
  if (l.tiledLayers)
184
184
  for (const t of l.tiledLayers)
185
- t.scaleBasedRendering && lt(t);
185
+ t.scaleBasedRendering && nt(t);
186
186
  });
187
187
  function De(t) {
188
188
  if (!t.scaleBasedRendering)
189
189
  return "tiled";
190
- const u = Ue.value[t.id];
191
- if (!u)
190
+ const d = Ue.value[t.id];
191
+ if (!d)
192
192
  return "tiled";
193
193
  const s = c.value;
194
- return s === 0 || s > u.maxScale ? "tiled" : "dynamic";
194
+ return s === 0 || s > d.maxScale ? "tiled" : "dynamic";
195
195
  }
196
- const nt = z(() => l.tiledLayers ? l.tiledLayers.filter((t) => te(t.id) ? t.scaleBasedRendering ? De(t) === "tiled" : !0 : !1) : []), rt = z(() => l.tiledLayers ? l.tiledLayers.filter((t) => te(t.id) && t.scaleBasedRendering ? De(t) === "dynamic" : !1) : []);
196
+ const rt = D(() => l.tiledLayers ? l.tiledLayers.filter((t) => te(t.id) ? t.scaleBasedRendering ? De(t) === "tiled" : !0 : !1) : []), st = D(() => l.tiledLayers ? l.tiledLayers.filter((t) => te(t.id) && t.scaleBasedRendering ? De(t) === "dynamic" : !1) : []);
197
197
  function _e(t) {
198
198
  return {
199
199
  type: "raster",
@@ -203,175 +203,175 @@ const io = { class: "map-panel" }, lo = /* @__PURE__ */ ye({
203
203
  };
204
204
  }
205
205
  function Me(t) {
206
- return { type: "geojson", data: x.value[t.id], tolerance: 0 };
206
+ return { type: "geojson", data: C.value[t.id], tolerance: 0 };
207
207
  }
208
208
  function Re(t) {
209
209
  return l.layerOpacities[t] ?? 1;
210
210
  }
211
211
  function Pe(t) {
212
- const u = Re(t.id), s = t.type === "circle" ? "circle-opacity" : t.type === "fill" ? "fill-opacity" : "line-opacity";
212
+ const d = Re(t.id), s = t.type === "circle" ? "circle-opacity" : t.type === "fill" ? "fill-opacity" : "line-opacity";
213
213
  if (t.type === "fill" && t.paint["fill-opacity"] === 0)
214
214
  return { ...t.paint, "fill-opacity": 0 };
215
- const b = t.type === "circle" ? "circle-color" : t.type === "fill" ? "fill-color" : "line-color", C = { ...t.paint }, F = C[b], B = C[s] === 1, Y = typeof F == "string" && F.startsWith("rgba(");
216
- if (B && Y) {
217
- if (u === 1)
218
- return C;
215
+ const S = t.type === "circle" ? "circle-color" : t.type === "fill" ? "fill-color" : "line-color", k = { ...t.paint }, O = k[S], B = k[s] === 1, ee = typeof O == "string" && O.startsWith("rgba(");
216
+ if (B && ee) {
217
+ if (d === 1)
218
+ return k;
219
219
  {
220
- const V = F.match(/rgba\((\d+),\s*(\d+),\s*(\d+),\s*([\d.]+)\)/);
221
- if (V && V[4]) {
222
- const [, oe, A, K, N] = V, ne = parseFloat(N) * u;
223
- C[b] = `rgba(${oe}, ${A}, ${K}, ${ne})`, C[s] = 1;
220
+ const N = O.match(/rgba\((\d+),\s*(\d+),\s*(\d+),\s*([\d.]+)\)/);
221
+ if (N && N[4]) {
222
+ const [, oe, A, Q, U] = N, ne = parseFloat(U) * d;
223
+ k[S] = `rgba(${oe}, ${A}, ${Q}, ${ne})`, k[s] = 1;
224
224
  }
225
- return C;
225
+ return k;
226
226
  }
227
227
  }
228
- if (Y) {
229
- const V = F.match(/rgba\((\d+),\s*(\d+),\s*(\d+),\s*([\d.]+)\)/);
230
- if (V) {
231
- const [, oe, A, K] = V;
232
- C[b] = `rgb(${oe}, ${A}, ${K})`;
228
+ if (ee) {
229
+ const N = O.match(/rgba\((\d+),\s*(\d+),\s*(\d+),\s*([\d.]+)\)/);
230
+ if (N) {
231
+ const [, oe, A, Q] = N;
232
+ k[S] = `rgb(${oe}, ${A}, ${Q})`;
233
233
  }
234
234
  }
235
- return C[s] = u, C;
235
+ return k[s] = d, k;
236
236
  }
237
- function st(t) {
238
- const u = Re(t.id);
239
- return { ...t.outlinePaint, "line-opacity": u };
237
+ function ct(t) {
238
+ const d = Re(t.id);
239
+ return { ...t.outlinePaint, "line-opacity": d };
240
240
  }
241
- const se = k([]), Ae = k(null), ae = k(0);
242
- function Fe(t) {
243
- const u = t.replace(/-outline$/, "");
244
- return l.layerList.find((b) => b.config.id === u)?.config;
241
+ const se = x([]), Ae = x(null), ae = x(0);
242
+ function Te(t) {
243
+ const d = t.replace(/-outline$/, "");
244
+ return l.layerList.find((S) => S.config.id === d)?.config;
245
245
  }
246
- function ct(t, u) {
247
- return t.replace(/\{([^}]+)\}/g, (s, b) => {
248
- const C = u[b];
249
- return C == null ? "" : String(C);
246
+ function ut(t, d) {
247
+ return t.replace(/\{([^}]+)\}/g, (s, S) => {
248
+ const k = d[S];
249
+ return k == null ? "" : String(k);
250
250
  });
251
251
  }
252
252
  function we(t) {
253
253
  return t.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;");
254
254
  }
255
- function We(t, u, s) {
255
+ function We(t, d, s) {
256
256
  if (t == null) return "-";
257
- if (u?.dateFormat && typeof t == "number") {
258
- const b = new Date(t);
259
- if (s && u.dateFormat === "shortDateShortTime")
260
- return b.toLocaleString(void 0, { dateStyle: "short", timeStyle: "short" });
261
- switch (u.dateFormat) {
257
+ if (d?.dateFormat && typeof t == "number") {
258
+ const S = new Date(t);
259
+ if (s && d.dateFormat === "shortDateShortTime")
260
+ return S.toLocaleString(void 0, { dateStyle: "short", timeStyle: "short" });
261
+ switch (d.dateFormat) {
262
262
  case "shortDateShortTime":
263
- return b.toLocaleDateString();
263
+ return S.toLocaleDateString();
264
264
  case "longMonthDayYear":
265
- return b.toLocaleDateString(void 0, { month: "long", day: "numeric", year: "numeric" });
265
+ return S.toLocaleDateString(void 0, { month: "long", day: "numeric", year: "numeric" });
266
266
  case "shortDate":
267
- return b.toLocaleDateString();
267
+ return S.toLocaleDateString();
268
268
  case "longDate":
269
- return b.toLocaleDateString(void 0, { weekday: "long", month: "long", day: "numeric", year: "numeric" });
269
+ return S.toLocaleDateString(void 0, { weekday: "long", month: "long", day: "numeric", year: "numeric" });
270
270
  default:
271
- return b.toLocaleDateString();
271
+ return S.toLocaleDateString();
272
272
  }
273
273
  }
274
274
  if (typeof t == "number") {
275
- if (t > 1e12 && !u)
275
+ if (t > 1e12 && !d)
276
276
  return new Date(t).toLocaleDateString();
277
- const b = u?.places, C = u?.digitSeparator ?? !0;
278
- if (b !== void 0) {
279
- if (Number.isInteger(t) && b >= 0)
277
+ const S = d?.places, k = d?.digitSeparator ?? !0;
278
+ if (S !== void 0) {
279
+ if (Number.isInteger(t) && S >= 0)
280
280
  return String(t);
281
- const F = t.toFixed(b);
282
- if (C) {
283
- const B = F.split("."), Y = B[0] || "0", V = B[1], oe = Y.replace(/\B(?=(\d{3})+(?!\d))/g, ",");
284
- return V ? `${oe}.${V}` : oe;
281
+ const O = t.toFixed(S);
282
+ if (k) {
283
+ const B = O.split("."), ee = B[0] || "0", N = B[1], oe = ee.replace(/\B(?=(\d{3})+(?!\d))/g, ",");
284
+ return N ? `${oe}.${N}` : oe;
285
285
  }
286
- return F;
286
+ return O;
287
287
  }
288
- return Number.isInteger(t) ? String(t) : C ? t.toLocaleString() : String(t);
288
+ return Number.isInteger(t) ? String(t) : k ? t.toLocaleString() : String(t);
289
289
  }
290
290
  return String(t);
291
291
  }
292
292
  function je(t) {
293
- const u = /* @__PURE__ */ new Set();
293
+ const d = /* @__PURE__ */ new Set();
294
294
  return t.filter((s) => {
295
- const C = `${s.layer.id.replace(/-outline$/, "")}:${JSON.stringify(s.properties)}`;
296
- return u.has(C) ? !1 : (u.add(C), !0);
295
+ const k = `${s.layer.id.replace(/-outline$/, "")}:${JSON.stringify(s.properties)}`;
296
+ return d.has(k) ? !1 : (d.add(k), !0);
297
297
  });
298
298
  }
299
- function Ke(t, u) {
300
- const s = x.value[t];
299
+ function Qe(t, d) {
300
+ const s = C.value[t];
301
301
  if (!s?.features) return null;
302
- const b = u.objectid ?? u.OBJECTID ?? u.FID;
303
- if (b != null) {
304
- const C = s.features.find(
305
- (F) => (F.properties?.objectid ?? F.properties?.OBJECTID ?? F.properties?.FID) === b
302
+ const S = d.objectid ?? d.OBJECTID ?? d.FID;
303
+ if (S != null) {
304
+ const k = s.features.find(
305
+ (O) => (O.properties?.objectid ?? O.properties?.OBJECTID ?? O.properties?.FID) === S
306
306
  );
307
- if (C) return C.geometry;
307
+ if (k) return k.geometry;
308
308
  }
309
309
  return null;
310
310
  }
311
- function Le(t, u) {
311
+ function Le(t, d) {
312
312
  const s = /* @__PURE__ */ new Map();
313
- return u.forEach((b, C) => {
314
- s.set(b.id, C);
315
- }), t.sort((b, C) => {
316
- const F = b.layer.id.replace(/-outline$/, ""), B = C.layer.id.replace(/-outline$/, ""), Y = s.get(F) ?? -1;
317
- return (s.get(B) ?? -1) - Y;
313
+ return d.forEach((S, k) => {
314
+ s.set(S.id, k);
315
+ }), t.sort((S, k) => {
316
+ const O = S.layer.id.replace(/-outline$/, ""), B = k.layer.id.replace(/-outline$/, ""), ee = s.get(O) ?? -1;
317
+ return (s.get(B) ?? -1) - ee;
318
318
  });
319
319
  }
320
320
  function Be(t) {
321
- const u = n.value;
322
- if (!u) return;
321
+ const d = n.value;
322
+ if (!d) return;
323
323
  const s = [];
324
324
  l.layerList.forEach((A) => {
325
- const K = A.config;
326
- l.visibleLayers.has(K.id) && (s.push(K.id), K.outlinePaint && s.push(`${K.id}-outline`));
325
+ const Q = A.config;
326
+ l.visibleLayers.has(Q.id) && (s.push(Q.id), Q.outlinePaint && s.push(`${Q.id}-outline`));
327
327
  });
328
- const b = u.project([t.lngLat.lng, t.lngLat.lat]), C = u.queryRenderedFeatures(b, {
328
+ const S = d.project([t.lngLat.lng, t.lngLat.lat]), k = d.queryRenderedFeatures(S, {
329
329
  layers: s
330
330
  });
331
- if (C.length === 0) return;
332
- const F = je(C), B = l.layerList.map((A) => A.config), V = Le(F, B).map((A) => {
333
- const K = A.layer.id.replace(/-outline$/, ""), N = Fe(K);
334
- if (!N) return null;
335
- const ne = Ke(N.id, A.properties || {});
331
+ if (k.length === 0) return;
332
+ const O = je(k), B = l.layerList.map((A) => A.config), N = Le(O, B).map((A) => {
333
+ const Q = A.layer.id.replace(/-outline$/, ""), U = Te(Q);
334
+ if (!U) return null;
335
+ const ne = Qe(U.id, A.properties || {});
336
336
  return {
337
- layerId: N.id,
338
- layerTitle: N.title,
337
+ layerId: U.id,
338
+ layerTitle: U.title,
339
339
  properties: A.properties || {},
340
340
  geometry: ne || A.geometry,
341
- popupConfig: N.popup
341
+ popupConfig: U.popup
342
342
  };
343
343
  }).filter((A) => A !== null);
344
- if (V.length === 0) return;
345
- V.sort((A, K) => {
346
- const N = A.popupConfig?.popupSortField, ne = K.popupConfig?.popupSortField;
347
- if (!N || N !== ne) return 0;
348
- const ce = A.properties[N], ft = K.properties[N];
349
- if (ce == null || ft == null) return 0;
344
+ if (N.length === 0) return;
345
+ N.sort((A, Q) => {
346
+ const U = A.popupConfig?.popupSortField, ne = Q.popupConfig?.popupSortField;
347
+ if (!U || U !== ne) return 0;
348
+ const ce = A.properties[U], pt = Q.properties[U];
349
+ if (ce == null || pt == null) return 0;
350
350
  const kt = A.popupConfig?.popupSortOrder !== "asc";
351
- return ce < ft ? kt ? 1 : -1 : ce > ft ? kt ? -1 : 1 : 0;
352
- }), se.value = V, ae.value = 0, Ae.value = [t.lngLat.lng, t.lngLat.lat];
353
- const oe = V[0];
351
+ return ce < pt ? kt ? 1 : -1 : ce > pt ? kt ? -1 : 1 : 0;
352
+ }), se.value = N, ae.value = 0, Ae.value = [t.lngLat.lng, t.lngLat.lat];
353
+ const oe = N[0];
354
354
  if (oe) {
355
- const A = Fe(oe.layerId);
355
+ const A = Te(oe.layerId);
356
356
  if (A) {
357
- const K = M(oe.geometry), N = J(A.id, A.type);
358
- y.value = {
357
+ const Q = M(oe.geometry), U = K(A.id, A.type);
358
+ m.value = {
359
359
  geometry: oe.geometry,
360
- geometryType: K,
360
+ geometryType: Q,
361
361
  layerId: A.id,
362
362
  properties: oe.properties,
363
- originalStyle: N
363
+ originalStyle: U
364
364
  };
365
365
  }
366
366
  }
367
367
  }
368
368
  function ie() {
369
- se.value = [], Ae.value = null, ae.value = 0, y.value = null;
369
+ se.value = [], Ae.value = null, ae.value = 0, m.value = null;
370
370
  }
371
- function Qe(t) {
371
+ function Xe(t) {
372
372
  if (se.value.length === 0) return;
373
- const u = t.target;
374
- if (!(u.tagName === "INPUT" || u.tagName === "TEXTAREA" || u.isContentEditable))
373
+ const d = t.target;
374
+ if (!(d.tagName === "INPUT" || d.tagName === "TEXTAREA" || d.isContentEditable))
375
375
  switch (t.key) {
376
376
  case "ArrowLeft":
377
377
  case "ArrowUp":
@@ -386,10 +386,10 @@ const io = { class: "map-panel" }, lo = /* @__PURE__ */ ye({
386
386
  break;
387
387
  }
388
388
  }
389
- et(() => {
390
- window.addEventListener("keydown", Qe);
389
+ ot(() => {
390
+ window.addEventListener("keydown", Xe);
391
391
  }), Rt(() => {
392
- window.removeEventListener("keydown", Qe);
392
+ window.removeEventListener("keydown", Xe);
393
393
  });
394
394
  function Ee() {
395
395
  const t = se.value.length;
@@ -398,106 +398,106 @@ const io = { class: "map-panel" }, lo = /* @__PURE__ */ ye({
398
398
  function de() {
399
399
  se.value.length <= 1 || ae.value <= 0 || (ae.value = ae.value - 1);
400
400
  }
401
- const Oe = z(() => se.value.length === 0 ? null : se.value[ae.value]), ge = z(() => {
401
+ const Oe = D(() => se.value.length === 0 ? null : se.value[ae.value]), ve = D(() => {
402
402
  const t = Oe.value;
403
- return !t || !t.popupConfig ? t?.layerTitle || "" : ct(t.popupConfig.title, t.properties);
404
- }), qe = z(() => {
403
+ return !t || !t.popupConfig ? t?.layerTitle || "" : ut(t.popupConfig.title, t.properties);
404
+ }), qe = D(() => {
405
405
  const t = Oe.value;
406
406
  if (!t) return "";
407
- let u = '<div class="popup-content">';
408
- if (u += `<h3 class="popup-title">${we(ge.value)}</h3>`, t.popupConfig?.fields?.length) {
409
- u += `<table class="popup-table" aria-label="${we(ge.value)}">`;
407
+ let d = '<div class="popup-content">';
408
+ if (d += `<h3 class="popup-title">${we(ve.value)}</h3>`, t.popupConfig?.fields?.length) {
409
+ d += `<table class="popup-table" aria-label="${we(ve.value)}">`;
410
410
  for (const s of t.popupConfig.fields) {
411
- const b = We(t.properties[s.field], s.format, t.popupConfig.showTime), C = s.label.toLowerCase(), F = C.includes("url") || C.includes("website"), B = b.startsWith("http://") || b.startsWith("https://") || b.startsWith("www.") || F && b.includes("."), Y = b.startsWith("http://") || b.startsWith("https://") ? b : `https://${b}`, V = B ? `<a href="${we(Y)}" target="_blank" rel="noopener noreferrer">${we(b)}</a>` : we(b);
412
- u += `<tr><th scope="row">${we(s.label)}</th><td>${V}</td></tr>`;
411
+ const S = We(t.properties[s.field], s.format, t.popupConfig.showTime), k = s.label.toLowerCase(), O = k.includes("url") || k.includes("website"), B = S.startsWith("http://") || S.startsWith("https://") || S.startsWith("www.") || O && S.includes("."), ee = S.startsWith("http://") || S.startsWith("https://") ? S : `https://${S}`, N = B ? `<a href="${we(ee)}" target="_blank" rel="noopener noreferrer">${we(S)}</a>` : we(S);
412
+ d += `<tr><th scope="row">${we(s.label)}</th><td>${N}</td></tr>`;
413
413
  }
414
- u += "</table>";
414
+ d += "</table>";
415
415
  }
416
- return u += "</div>", u;
417
- }), Se = k({
416
+ return d += "</div>", d;
417
+ }), Se = x({
418
418
  type: "FeatureCollection",
419
419
  features: []
420
- }), le = k({
420
+ }), le = x({
421
421
  type: "FeatureCollection",
422
422
  features: []
423
- }), Ze = k({
423
+ }), Ve = x({
424
424
  type: "FeatureCollection",
425
425
  features: []
426
- }), ut = {
426
+ }), dt = {
427
427
  "circle-radius": ["get", "highlightRadius"],
428
428
  "circle-color": "#00FFFF",
429
429
  "circle-opacity": 0.8,
430
430
  "circle-stroke-width": 2,
431
431
  "circle-stroke-color": "#FFFFFF"
432
- }, dt = {
432
+ }, ft = {
433
433
  "line-width": ["get", "highlightWidth"],
434
434
  "line-color": "#00FFFF",
435
435
  "line-opacity": 0.9
436
- }, Xe = {
436
+ }, Ye = {
437
437
  "fill-color": "#808080",
438
438
  "fill-opacity": 0.5
439
- }, y = k(null);
439
+ }, m = x(null);
440
440
  function M(t) {
441
441
  return t.type;
442
442
  }
443
- function J(t, u) {
444
- const s = Fe(t);
443
+ function K(t, d) {
444
+ const s = Te(t);
445
445
  if (!s) return { radius: 5, width: 2 };
446
- const b = s.paint || {};
447
- if (u === "circle") {
448
- const C = b["circle-radius"];
449
- return typeof C == "number" ? { radius: C } : { radius: 5 };
446
+ const S = s.paint || {};
447
+ if (d === "circle") {
448
+ const k = S["circle-radius"];
449
+ return typeof k == "number" ? { radius: k } : { radius: 5 };
450
450
  }
451
- if (u === "line" || u === "fill") {
452
- const C = b["line-width"];
453
- if (typeof C == "number")
454
- return { width: C };
451
+ if (d === "line" || d === "fill") {
452
+ const k = S["line-width"];
453
+ if (typeof k == "number")
454
+ return { width: k };
455
455
  if (s.outlinePaint && s.outlinePaint["line-width"]) {
456
- const F = s.outlinePaint["line-width"];
457
- if (typeof F == "number")
458
- return { width: F };
456
+ const O = s.outlinePaint["line-width"];
457
+ if (typeof O == "number")
458
+ return { width: O };
459
459
  }
460
460
  return { width: 2 };
461
461
  }
462
462
  return { radius: 5, width: 2 };
463
463
  }
464
- function W(t) {
464
+ function j(t) {
465
465
  return !t || t.length === 0 ? [] : t[0] ?? [];
466
466
  }
467
- function Q(t) {
468
- const { geometry: u, geometryType: s, originalStyle: b } = t;
467
+ function Y(t) {
468
+ const { geometry: d, geometryType: s, originalStyle: S } = t;
469
469
  if (s === "Point" || s === "MultiPoint") {
470
- const F = (b.radius || 5) + 3;
470
+ const O = (S.radius || 5) + 3;
471
471
  return {
472
472
  type: "FeatureCollection",
473
473
  features: [
474
474
  {
475
475
  type: "Feature",
476
- geometry: u,
476
+ geometry: d,
477
477
  properties: {
478
- highlightRadius: F
478
+ highlightRadius: O
479
479
  }
480
480
  }
481
481
  ]
482
482
  };
483
483
  }
484
484
  if (s === "LineString" || s === "MultiLineString") {
485
- const F = (b.width || 2) + 3;
485
+ const O = (S.width || 2) + 3;
486
486
  return {
487
487
  type: "FeatureCollection",
488
488
  features: [
489
489
  {
490
490
  type: "Feature",
491
- geometry: u,
491
+ geometry: d,
492
492
  properties: {
493
- highlightWidth: F
493
+ highlightWidth: O
494
494
  }
495
495
  }
496
496
  ]
497
497
  };
498
498
  }
499
499
  if (s === "Polygon") {
500
- const C = u.coordinates, F = W(C), Y = (b.width || 2) + 3;
500
+ const k = d.coordinates, O = j(k), ee = (S.width || 2) + 3;
501
501
  return {
502
502
  type: "FeatureCollection",
503
503
  features: [
@@ -505,24 +505,24 @@ const io = { class: "map-panel" }, lo = /* @__PURE__ */ ye({
505
505
  type: "Feature",
506
506
  geometry: {
507
507
  type: "LineString",
508
- coordinates: F
508
+ coordinates: O
509
509
  },
510
510
  properties: {
511
- highlightWidth: Y
511
+ highlightWidth: ee
512
512
  }
513
513
  }
514
514
  ]
515
515
  };
516
516
  }
517
517
  if (s === "MultiPolygon") {
518
- const C = u.coordinates, B = (b.width || 2) + 3;
518
+ const k = d.coordinates, B = (S.width || 2) + 3;
519
519
  return {
520
520
  type: "FeatureCollection",
521
- features: C.map((V) => ({
521
+ features: k.map((N) => ({
522
522
  type: "Feature",
523
523
  geometry: {
524
524
  type: "LineString",
525
- coordinates: W(V)
525
+ coordinates: j(N)
526
526
  },
527
527
  properties: {
528
528
  highlightWidth: B
@@ -536,56 +536,56 @@ const io = { class: "map-panel" }, lo = /* @__PURE__ */ ye({
536
536
  };
537
537
  }
538
538
  function Ce(t) {
539
- const { geometry: u, geometryType: s } = t;
539
+ const { geometry: d, geometryType: s } = t;
540
540
  return s === "Polygon" || s === "MultiPolygon" ? {
541
541
  type: "FeatureCollection",
542
- features: [{ type: "Feature", geometry: u, properties: {} }]
542
+ features: [{ type: "Feature", geometry: d, properties: {} }]
543
543
  } : { type: "FeatureCollection", features: [] };
544
544
  }
545
- function Ve(t) {
545
+ function Ze(t) {
546
546
  if (!t) {
547
547
  Wt();
548
548
  return;
549
549
  }
550
- const u = Q(t);
551
- t.geometryType === "Point" || t.geometryType === "MultiPoint" ? (Se.value = u, le.value = { type: "FeatureCollection", features: [] }, Ze.value = { type: "FeatureCollection", features: [] }) : (le.value = u, Se.value = { type: "FeatureCollection", features: [] }, Ze.value = Ce(t));
550
+ const d = Y(t);
551
+ t.geometryType === "Point" || t.geometryType === "MultiPoint" ? (Se.value = d, le.value = { type: "FeatureCollection", features: [] }, Ve.value = { type: "FeatureCollection", features: [] }) : (le.value = d, Se.value = { type: "FeatureCollection", features: [] }, Ve.value = Ce(t));
552
552
  }
553
553
  function Wt() {
554
- Se.value = { type: "FeatureCollection", features: [] }, le.value = { type: "FeatureCollection", features: [] }, Ze.value = { type: "FeatureCollection", features: [] };
554
+ Se.value = { type: "FeatureCollection", features: [] }, le.value = { type: "FeatureCollection", features: [] }, Ve.value = { type: "FeatureCollection", features: [] };
555
555
  }
556
- Ie(y, (t) => {
557
- Ve(t);
556
+ Ie(m, (t) => {
557
+ Ze(t);
558
558
  }), Ie(
559
559
  () => l.visibleLayers,
560
560
  (t) => {
561
- y.value && !t.has(y.value.layerId) && (y.value = null, ie());
561
+ m.value && !t.has(m.value.layerId) && (m.value = null, ie());
562
562
  },
563
563
  { deep: !0 }
564
564
  ), Ie(ae, () => {
565
565
  const t = Oe.value;
566
566
  if (!t) {
567
- y.value = null;
567
+ m.value = null;
568
568
  return;
569
569
  }
570
- const u = Fe(t.layerId);
571
- if (u) {
572
- const s = M(t.geometry), b = J(u.id, u.type);
573
- y.value = {
570
+ const d = Te(t.layerId);
571
+ if (d) {
572
+ const s = M(t.geometry), S = K(d.id, d.type);
573
+ m.value = {
574
574
  geometry: t.geometry,
575
575
  geometryType: s,
576
- layerId: u.id,
576
+ layerId: d.id,
577
577
  properties: t.properties,
578
- originalStyle: b
578
+ originalStyle: S
579
579
  };
580
580
  }
581
581
  });
582
- const Ct = k(null);
582
+ const Ct = x(null);
583
583
  function jt(t) {
584
- const [u, s] = t.geometry.coordinates;
585
- Ct.value = [u, s];
584
+ const [d, s] = t.geometry.coordinates;
585
+ Ct.value = [d, s];
586
586
  }
587
- return (t, u) => (m(), $("div", io, [
588
- H(d(Yt), {
587
+ return (t, d) => (h(), $("div", io, [
588
+ J(f(Yt), {
589
589
  ref_key: "mapRef",
590
590
  ref: r,
591
591
  zoom: l.initialZoom,
@@ -602,34 +602,34 @@ const io = { class: "map-panel" }, lo = /* @__PURE__ */ ye({
602
602
  "pictometry-button-position": l.pictometryButtonPosition,
603
603
  "tool-panel-layout": "vertical",
604
604
  "tool-panel-split-ratio": 50,
605
- onZoom: w,
605
+ onZoom: b,
606
606
  onClick: ie,
607
- onMoveend: L,
608
- onLoad: S,
607
+ onMoveend: w,
608
+ onLoad: L,
609
609
  onSearchResult: jt
610
610
  }, {
611
611
  default: Ge(() => [
612
- l.drawControlPosition !== null ? (m(), q(d(eo), {
612
+ l.drawControlPosition !== null ? (h(), G(f(eo), {
613
613
  key: 0,
614
614
  position: l.drawControlPosition
615
615
  }, null, 8, ["position"])) : R("", !0),
616
- (m(!0), $(ue, null, ve(nt.value, (s) => (m(), q(d(Pt), {
616
+ (h(!0), $(ue, null, be(rt.value, (s) => (h(), G(f(Pt), {
617
617
  id: "tiled-" + s.id,
618
618
  key: "tiled-" + s.id,
619
- source: he(s),
620
- paint: { "raster-opacity": U(s.id) },
619
+ source: ge(s),
620
+ paint: { "raster-opacity": W(s.id) },
621
621
  minzoom: s.minZoom,
622
622
  maxzoom: s.maxZoom
623
623
  }, null, 8, ["id", "source", "paint", "minzoom", "maxzoom"]))), 128)),
624
- (m(!0), $(ue, null, ve(rt.value, (s) => (m(), q(d(Pt), {
624
+ (h(!0), $(ue, null, be(st.value, (s) => (h(), G(f(Pt), {
625
625
  id: "dynamic-" + s.id,
626
626
  key: "dynamic-" + s.id,
627
627
  source: _e(s),
628
- paint: { "raster-opacity": U(s.id) },
628
+ paint: { "raster-opacity": W(s.id) },
629
629
  minzoom: s.minZoom,
630
630
  maxzoom: s.maxZoom
631
631
  }, null, 8, ["id", "source", "paint", "minzoom", "maxzoom"]))), 128)),
632
- (m(!0), $(ue, null, ve(X.value, (s) => (m(), q(d(Tt), {
632
+ (h(!0), $(ue, null, be(V.value, (s) => (h(), G(f(Ft), {
633
633
  id: s.id,
634
634
  key: s.id,
635
635
  source: Me(s),
@@ -639,7 +639,7 @@ const io = { class: "map-panel" }, lo = /* @__PURE__ */ ye({
639
639
  "before-id": "highlight-circles",
640
640
  onClick: Be
641
641
  }, null, 8, ["id", "source", "paint", "minzoom", "maxzoom"]))), 128)),
642
- (m(!0), $(ue, null, ve(T.value, (s) => (m(), q(d(Ft), {
642
+ (h(!0), $(ue, null, be(T.value, (s) => (h(), G(f(Tt), {
643
643
  id: s.id,
644
644
  key: s.id,
645
645
  source: Me(s),
@@ -649,17 +649,17 @@ const io = { class: "map-panel" }, lo = /* @__PURE__ */ ye({
649
649
  "before-id": "highlight-circles",
650
650
  onClick: Be
651
651
  }, null, 8, ["id", "source", "paint", "minzoom", "maxzoom"]))), 128)),
652
- (m(!0), $(ue, null, ve(O.value, (s) => (m(), q(d(pt), {
652
+ (h(!0), $(ue, null, be(I.value, (s) => (h(), G(f(yt), {
653
653
  id: s.id + "-outline",
654
654
  key: s.id + "-outline",
655
655
  source: Me(s),
656
- paint: st(s),
656
+ paint: ct(s),
657
657
  minzoom: s.minZoom,
658
658
  maxzoom: s.maxZoom,
659
659
  "before-id": "highlight-lines",
660
660
  onClick: Be
661
661
  }, null, 8, ["id", "source", "paint", "minzoom", "maxzoom"]))), 128)),
662
- (m(!0), $(ue, null, ve(_.value, (s) => (m(), q(d(pt), {
662
+ (h(!0), $(ue, null, be(_.value, (s) => (h(), G(f(yt), {
663
663
  id: s.id,
664
664
  key: s.id,
665
665
  source: Me(s),
@@ -669,29 +669,29 @@ const io = { class: "map-panel" }, lo = /* @__PURE__ */ ye({
669
669
  "before-id": "highlight-lines",
670
670
  onClick: Be
671
671
  }, null, 8, ["id", "source", "paint", "minzoom", "maxzoom"]))), 128)),
672
- H(d(Tt), {
672
+ J(f(Ft), {
673
673
  id: "highlight-circles",
674
674
  key: "highlight-circles-layer",
675
675
  source: { type: "geojson", data: Se.value },
676
- paint: ut
676
+ paint: dt
677
677
  }, null, 8, ["source"]),
678
- H(d(Ft), {
678
+ J(f(Tt), {
679
679
  id: "highlight-fill",
680
680
  key: "highlight-fill-layer",
681
- source: { type: "geojson", data: Ze.value },
682
- paint: Xe
681
+ source: { type: "geojson", data: Ve.value },
682
+ paint: Ye
683
683
  }, null, 8, ["source"]),
684
- H(d(pt), {
684
+ J(f(yt), {
685
685
  id: "highlight-lines",
686
686
  key: "highlight-lines-layer",
687
687
  source: { type: "geojson", data: le.value },
688
- paint: dt
688
+ paint: ft
689
689
  }, null, 8, ["source"]),
690
- H(d(to), {
690
+ J(f(to), {
691
691
  "lng-lat": Ct.value,
692
692
  color: "#2176d2"
693
693
  }, null, 8, ["lng-lat"]),
694
- Oe.value && Ae.value ? (m(), q(d(oo), {
694
+ Oe.value && Ae.value ? (h(), G(f(oo), {
695
695
  key: 1,
696
696
  "lng-lat": Ae.value,
697
697
  html: qe.value,
@@ -720,7 +720,7 @@ function Bt(e) {
720
720
  let i = e.split("?")[0] || e;
721
721
  return i = i.replace(/\/query$/, ""), i = i.replace(/\/$/, ""), i.toLowerCase();
722
722
  }
723
- const ro = ["disabled"], so = /* @__PURE__ */ ye({
723
+ const ro = ["disabled"], so = /* @__PURE__ */ me({
724
724
  inheritAttrs: !1,
725
725
  __name: "PhlButton",
726
726
  props: {
@@ -742,14 +742,14 @@ const ro = ["disabled"], so = /* @__PURE__ */ ye({
742
742
  svgRaw: {}
743
743
  },
744
744
  setup(e) {
745
- const i = e, l = (c) => "href" in c && c.href !== void 0 || "to" in c && c.to !== void 0, o = z(() => ht(
745
+ const i = e, l = (c) => "href" in c && c.href !== void 0 || "to" in c && c.to !== void 0, o = D(() => ht(
746
746
  "phila-button",
747
747
  `phila-button--${i.variant}`,
748
748
  i.size && `is-${i.size}`,
749
749
  i.iconOnly && "icon-button",
750
750
  i.iconOnly && i.variant === "standard" && "icon-button--standard",
751
751
  i.className
752
- )), r = z(() => l(i) ? "to" in i && i.to !== void 0 ? {
752
+ )), r = D(() => l(i) ? "to" in i && i.to !== void 0 ? {
753
753
  to: i.to,
754
754
  disabled: i.disabled,
755
755
  className: o.value
@@ -759,7 +759,7 @@ const ro = ["disabled"], so = /* @__PURE__ */ ye({
759
759
  rel: i.rel,
760
760
  disabled: i.disabled,
761
761
  className: o.value
762
- } : {}), n = z(
762
+ } : {}), n = D(
763
763
  () => ({
764
764
  iconDefinition: i.iconDefinition,
765
765
  iconClass: i.iconClass,
@@ -770,28 +770,28 @@ const ro = ["disabled"], so = /* @__PURE__ */ ye({
770
770
  size: i.size
771
771
  })
772
772
  );
773
- return (c, w) => l(i) ? (m(), q(d(ao), mt({ key: 0 }, { ...r.value, ...c.$attrs }, { role: "button" }), {
773
+ return (c, b) => l(i) ? (h(), G(f(ao), mt({ key: 0 }, { ...r.value, ...c.$attrs }, { role: "button" }), {
774
774
  default: Ge(() => [
775
- H(d(Et), xt($t(n.value)), {
775
+ J(f(Et), xt($t(n.value)), {
776
776
  default: Ge(() => [
777
777
  pe(c.$slots, "default", {}, () => [
778
- xe(G(i.text), 1)
778
+ xe(H(i.text), 1)
779
779
  ])
780
780
  ]),
781
781
  _: 3
782
782
  }, 16)
783
783
  ]),
784
784
  _: 3
785
- }, 16)) : (m(), $("button", mt({
785
+ }, 16)) : (h(), $("button", mt({
786
786
  key: 1,
787
787
  type: "button",
788
788
  disabled: i.disabled,
789
789
  class: o.value
790
790
  }, c.$attrs), [
791
- H(d(Et), xt($t(n.value)), {
791
+ J(f(Et), xt($t(n.value)), {
792
792
  default: Ge(() => [
793
793
  pe(c.$slots, "default", {}, () => [
794
- xe(G(i.text), 1)
794
+ xe(H(i.text), 1)
795
795
  ])
796
796
  ]),
797
797
  _: 3
@@ -814,7 +814,7 @@ const yo = ["for"], mo = { class: "state-layer" }, ho = { class: "content" }, go
814
814
  }, wo = {
815
815
  key: 2,
816
816
  class: "has-text-body-small phila-error-text"
817
- }, Lo = /* @__PURE__ */ ye({
817
+ }, Lo = /* @__PURE__ */ me({
818
818
  inheritAttrs: !1,
819
819
  __name: "TextField",
820
820
  props: {
@@ -832,37 +832,37 @@ const yo = ["for"], mo = { class: "state-layer" }, ho = { class: "content" }, go
832
832
  },
833
833
  emits: ["update:modelValue"],
834
834
  setup(e, { emit: i }) {
835
- const l = qt(), o = e, r = z(() => typeof o.error == "string" ? o.error : o.error[0]), n = Gt(o, "id"), c = i, w = k(""), p = z({
836
- get: () => o.modelValue !== void 0 ? o.modelValue : w.value,
837
- set: (f) => {
838
- c("update:modelValue", f), w.value = f;
835
+ const l = qt(), o = e, r = D(() => typeof o.error == "string" ? o.error : o.error[0]), n = Gt(o, "id"), c = i, b = x(""), p = D({
836
+ get: () => o.modelValue !== void 0 ? o.modelValue : b.value,
837
+ set: (u) => {
838
+ c("update:modelValue", u), b.value = u;
839
839
  }
840
- }), x = z(() => {
841
- const f = ["default-class"];
842
- return l.disabled != null && f.push("phila-input--disabled"), r.value && f.push("phila-input--error"), l.required != null && f.push("phila-input--required"), ht(...f);
843
- }), h = z(() => {
844
- const f = [];
845
- return p.value !== "" && f.push("phila-text-field--filled"), o.className && f.push(o.className), ht(...f);
846
- }), g = z(() => {
840
+ }), C = D(() => {
841
+ const u = ["default-class"];
842
+ return l.disabled != null && u.push("phila-input--disabled"), r.value && u.push("phila-input--error"), l.required != null && u.push("phila-input--required"), ht(...u);
843
+ }), y = D(() => {
844
+ const u = [];
845
+ return p.value !== "" && u.push("phila-text-field--filled"), o.className && u.push(o.className), ht(...u);
846
+ }), g = D(() => {
847
847
  if (!(o.label || l["aria-label"]))
848
848
  return o.placeholder || void 0;
849
- }), a = k(null), v = (f) => {
850
- f.target.closest("button") || a.value?.focus();
849
+ }), a = x(null), v = (u) => {
850
+ u.target.closest("button") || a.value?.focus();
851
851
  };
852
- return (f, L) => (m(), $("div", {
853
- class: re(["phila-input", x.value])
852
+ return (u, w) => (h(), $("div", {
853
+ class: re(["phila-input", C.value])
854
854
  }, [
855
- o.label ? (m(), $("label", {
855
+ o.label ? (h(), $("label", {
856
856
  key: 0,
857
857
  for: n.value,
858
858
  class: "has-text-label-small phila-label"
859
- }, G(o.label), 9, yo)) : R("", !0),
859
+ }, H(o.label), 9, yo)) : R("", !0),
860
860
  P("div", {
861
- class: re(["phila-text-field", h.value]),
861
+ class: re(["phila-text-field", y.value]),
862
862
  onClick: v
863
863
  }, [
864
864
  P("div", mo, [
865
- o.leadingIcon ? (m(), q(d(ke), {
865
+ o.leadingIcon ? (h(), G(f(ke), {
866
866
  key: 0,
867
867
  "icon-class": o.leadingIcon,
868
868
  inline: "",
@@ -874,42 +874,42 @@ const yo = ["for"], mo = { class: "state-layer" }, ho = { class: "content" }, go
874
874
  id: n.value,
875
875
  ref_key: "inputRef",
876
876
  ref: a,
877
- "onUpdate:modelValue": L[0] || (L[0] = (S) => p.value = S),
877
+ "onUpdate:modelValue": w[0] || (w[0] = (L) => p.value = L),
878
878
  class: "phila-text-field-input has-text-body-default",
879
879
  placeholder: o.placeholder,
880
880
  "aria-label": g.value
881
- }, d(l)), null, 16, vo), [
881
+ }, f(l)), null, 16, vo), [
882
882
  [Ht, p.value]
883
883
  ])
884
884
  ])
885
885
  ]),
886
- p.value != "" ? (m(), q(d(so), {
886
+ p.value != "" ? (h(), G(f(so), {
887
887
  key: 1,
888
888
  variant: "standard",
889
889
  size: "small",
890
890
  "icon-only": "",
891
- "icon-definition": d(po),
892
- onClick: L[1] || (L[1] = (S) => p.value = "")
891
+ "icon-definition": f(po),
892
+ onClick: w[1] || (w[1] = (L) => p.value = "")
893
893
  }, null, 8, ["icon-definition"])) : R("", !0),
894
- o.trailingIcon ? (m(), q(d(ke), {
894
+ o.trailingIcon ? (h(), G(f(ke), {
895
895
  key: 2,
896
896
  size: "small",
897
897
  "icon-class": o.trailingIcon,
898
898
  inline: "",
899
899
  decorative: ""
900
900
  }, null, 8, ["icon-class"])) : R("", !0),
901
- pe(f.$slots, "trailing-action")
901
+ pe(u.$slots, "trailing-action")
902
902
  ])
903
903
  ], 2),
904
- o.supportingText ? (m(), $("div", bo, G(o.supportingText), 1)) : R("", !0),
905
- r.value ? (m(), $("div", wo, [
906
- H(d(ke), {
907
- "icon-definition": d(uo),
904
+ o.supportingText ? (h(), $("div", bo, H(o.supportingText), 1)) : R("", !0),
905
+ r.value ? (h(), $("div", wo, [
906
+ J(f(ke), {
907
+ "icon-definition": f(uo),
908
908
  size: "small",
909
909
  inline: "",
910
910
  decorative: ""
911
911
  }, null, 8, ["icon-definition"]),
912
- xe(" " + G(r.value), 1)
912
+ xe(" " + H(r.value), 1)
913
913
  ])) : R("", !0)
914
914
  ], 2));
915
915
  }
@@ -943,10 +943,10 @@ const Mo = {
943
943
  key: 0,
944
944
  class: "loading-indicator",
945
945
  role: "status"
946
- }, Po = ["aria-label"], To = {
946
+ }, Po = ["aria-label"], Fo = {
947
947
  key: 2,
948
948
  class: "zoom-indicator"
949
- }, Fo = /* @__PURE__ */ ye({
949
+ }, To = /* @__PURE__ */ me({
950
950
  __name: "LayerStatusIndicators",
951
951
  props: {
952
952
  loading: { type: Boolean },
@@ -954,18 +954,18 @@ const Mo = {
954
954
  unavailable: { type: Boolean }
955
955
  },
956
956
  setup(e) {
957
- return (i, l) => (m(), $(ue, null, [
958
- e.loading && !e.unavailable ? (m(), $("span", Mo, " Loading... ")) : R("", !0),
959
- e.error ? (m(), $("span", {
957
+ return (i, l) => (h(), $(ue, null, [
958
+ e.loading && !e.unavailable ? (h(), $("span", Mo, " Loading... ")) : R("", !0),
959
+ e.error ? (h(), $("span", {
960
960
  key: 1,
961
961
  class: "error-indicator",
962
962
  "aria-label": e.error,
963
963
  role: "status"
964
964
  }, " Error ", 8, Po)) : R("", !0),
965
- e.unavailable ? (m(), $("span", To, " (zoom in) ")) : R("", !0)
965
+ e.unavailable ? (h(), $("span", Fo, " (zoom in) ")) : R("", !0)
966
966
  ], 64));
967
967
  }
968
- }), tt = /* @__PURE__ */ $e(Fo, [["__scopeId", "data-v-19b1b402"]]), Eo = { class: "opacity-control" }, Oo = ["for"], Io = ["id", "value", "aria-label"], zo = /* @__PURE__ */ ye({
968
+ }), at = /* @__PURE__ */ $e(To, [["__scopeId", "data-v-19b1b402"]]), Eo = { class: "opacity-control" }, Oo = ["for"], Io = ["id", "value", "aria-label"], zo = /* @__PURE__ */ me({
969
969
  __name: "LayerOpacitySlider",
970
970
  props: {
971
971
  layerId: {},
@@ -979,11 +979,11 @@ const Mo = {
979
979
  const n = r.target;
980
980
  l("update:opacity", parseFloat(n.value));
981
981
  }
982
- return (r, n) => (m(), $("div", Eo, [
982
+ return (r, n) => (h(), $("div", Eo, [
983
983
  P("label", {
984
984
  class: "opacity-label",
985
985
  for: "opacity-" + e.layerId
986
- }, " Opacity: " + G(Math.round(e.opacity * 100)) + "% ", 9, Oo),
986
+ }, " Opacity: " + H(Math.round(e.opacity * 100)) + "% ", 9, Oo),
987
987
  P("input", {
988
988
  id: "opacity-" + e.layerId,
989
989
  type: "range",
@@ -997,27 +997,27 @@ const Mo = {
997
997
  }, null, 40, Io)
998
998
  ]));
999
999
  }
1000
- }), vt = /* @__PURE__ */ $e(zo, [["__scopeId", "data-v-1a025f6a"]]), Do = ["aria-label"], _o = { class: "legend-label" }, Ro = /* @__PURE__ */ ye({
1000
+ }), vt = /* @__PURE__ */ $e(zo, [["__scopeId", "data-v-1a025f6a"]]), Do = ["aria-label"], _o = { class: "legend-label" }, Ro = /* @__PURE__ */ me({
1001
1001
  __name: "LayerLegend",
1002
1002
  props: {
1003
1003
  items: {},
1004
1004
  label: {}
1005
1005
  },
1006
1006
  setup(e) {
1007
- return (i, l) => (m(), $("ul", {
1007
+ return (i, l) => (h(), $("ul", {
1008
1008
  class: "layer-legend",
1009
1009
  "aria-label": e.label
1010
1010
  }, [
1011
- (m(!0), $(ue, null, ve(e.items, (o, r) => (m(), $("li", {
1011
+ (h(!0), $(ue, null, be(e.items, (o, r) => (h(), $("li", {
1012
1012
  key: r,
1013
1013
  class: "legend-item"
1014
1014
  }, [
1015
- o.type === "circle" ? (m(), $("span", {
1015
+ o.type === "circle" ? (h(), $("span", {
1016
1016
  key: 0,
1017
1017
  class: "legend-symbol legend-circle",
1018
1018
  style: fe({ backgroundColor: o.color }),
1019
1019
  "aria-hidden": "true"
1020
- }, null, 4)) : o.type === "line" ? (m(), $("span", {
1020
+ }, null, 4)) : o.type === "line" ? (h(), $("span", {
1021
1021
  key: 1,
1022
1022
  class: "legend-symbol legend-line",
1023
1023
  style: fe({
@@ -1025,13 +1025,13 @@ const Mo = {
1025
1025
  height: `${o.width || 2}px`
1026
1026
  }),
1027
1027
  "aria-hidden": "true"
1028
- }, null, 4)) : o.type === "fill" ? (m(), $("span", {
1028
+ }, null, 4)) : o.type === "fill" ? (h(), $("span", {
1029
1029
  key: 2,
1030
1030
  class: "legend-symbol legend-fill",
1031
1031
  style: fe({ backgroundColor: o.color }),
1032
1032
  "aria-hidden": "true"
1033
1033
  }, null, 4)) : R("", !0),
1034
- P("span", _o, G(o.label), 1)
1034
+ P("span", _o, H(o.label), 1)
1035
1035
  ]))), 128))
1036
1036
  ], 8, Do));
1037
1037
  }
@@ -1050,24 +1050,24 @@ function wt(e) {
1050
1050
  return e().layerErrors[c] || null;
1051
1051
  }
1052
1052
  function n(c) {
1053
- const w = e().currentZoom, p = c.minZoom, x = c.maxZoom;
1054
- return !(p !== void 0 && w < p || x !== void 0 && w > x);
1053
+ const b = e().currentZoom, p = c.minZoom, C = c.maxZoom;
1054
+ return !(p !== void 0 && b < p || C !== void 0 && b > C);
1055
1055
  }
1056
1056
  return { isVisible: i, getLayerOpacity: l, isLayerLoading: o, getLayerError: r, isLayerAvailableAtZoom: n };
1057
1057
  }
1058
1058
  const Ao = { class: "layer-panel" }, Bo = {
1059
1059
  key: 0,
1060
1060
  class: "search-box"
1061
- }, Zo = {
1061
+ }, Vo = {
1062
1062
  key: 1,
1063
1063
  class: "topics-container"
1064
- }, Vo = { class: "layer-row" }, No = ["href", "aria-label"], Uo = {
1064
+ }, Zo = { class: "layer-row" }, No = ["href", "aria-label"], Uo = {
1065
1065
  key: 1,
1066
1066
  class: "metadata-placeholder"
1067
1067
  }, Wo = ["checked", "disabled", "onChange"], jo = { class: "layer-title" }, qo = {
1068
1068
  key: 0,
1069
1069
  class: "no-results"
1070
- }, Go = /* @__PURE__ */ ye({
1070
+ }, Go = /* @__PURE__ */ me({
1071
1071
  __name: "LayerPanel",
1072
1072
  props: {
1073
1073
  layerList: {},
@@ -1086,40 +1086,40 @@ const Ao = { class: "layer-panel" }, Bo = {
1086
1086
  },
1087
1087
  emits: ["toggleLayer", "setOpacity", "updateSearch"],
1088
1088
  setup(e, { emit: i }) {
1089
- const l = e, o = i, r = z(() => {
1089
+ const l = e, o = i, r = D(() => {
1090
1090
  if (!l.searchQuery.trim())
1091
1091
  return l.layerList;
1092
- const f = l.searchQuery.toLowerCase();
1093
- return l.layerList.filter((L) => L.config.title.toLowerCase().includes(f));
1092
+ const u = l.searchQuery.toLowerCase();
1093
+ return l.layerList.filter((w) => w.config.title.toLowerCase().includes(u));
1094
1094
  });
1095
- function n(f) {
1096
- const L = Bt(f);
1097
- return l.layerMetadata[L] || null;
1095
+ function n(u) {
1096
+ const w = Bt(u);
1097
+ return l.layerMetadata[w] || null;
1098
1098
  }
1099
- const c = z(() => l.layerList.some((f) => n(f.config.url))), { isVisible: w, getLayerOpacity: p, isLayerLoading: x, getLayerError: h, isLayerAvailableAtZoom: g } = wt(() => ({
1099
+ const c = D(() => l.layerList.some((u) => n(u.config.url))), { isVisible: b, getLayerOpacity: p, isLayerLoading: C, getLayerError: y, isLayerAvailableAtZoom: g } = wt(() => ({
1100
1100
  visibleLayerIds: l.visibleLayers,
1101
1101
  layerOpacities: l.layerOpacities,
1102
1102
  loadingLayerIds: l.loadingLayers,
1103
1103
  layerErrors: l.layerErrors,
1104
1104
  currentZoom: l.currentZoom
1105
- })), a = z({
1105
+ })), a = D({
1106
1106
  get: () => l.searchQuery,
1107
- set: (f) => o("updateSearch", f)
1107
+ set: (u) => o("updateSearch", u)
1108
1108
  });
1109
- function v(f) {
1110
- o("toggleLayer", f);
1109
+ function v(u) {
1110
+ o("toggleLayer", u);
1111
1111
  }
1112
- return (f, L) => (m(), $("div", Ao, [
1113
- e.showSearch ? (m(), $("div", Bo, [
1114
- H(d(Lo), {
1112
+ return (u, w) => (h(), $("div", Ao, [
1113
+ e.showSearch ? (h(), $("div", Bo, [
1114
+ J(f(Lo), {
1115
1115
  modelValue: a.value,
1116
- "onUpdate:modelValue": L[0] || (L[0] = (S) => a.value = S),
1116
+ "onUpdate:modelValue": w[0] || (w[0] = (L) => a.value = L),
1117
1117
  placeholder: e.searchPlaceholder,
1118
1118
  "class-name": "layer-search-field"
1119
1119
  }, {
1120
1120
  "trailing-action": Ge(() => [
1121
- H(d(ke), {
1122
- "icon-definition": d(So),
1121
+ J(f(ke), {
1122
+ "icon-definition": f(So),
1123
1123
  size: "small",
1124
1124
  inline: "",
1125
1125
  decorative: ""
@@ -1128,142 +1128,178 @@ const Ao = { class: "layer-panel" }, Bo = {
1128
1128
  _: 1
1129
1129
  }, 8, ["modelValue", "placeholder"])
1130
1130
  ])) : R("", !0),
1131
- e.mode === "topics" ? (m(), $("div", Zo, [
1132
- pe(f.$slots, "topics", {}, () => [
1133
- L[2] || (L[2] = P("div", { class: "no-topics" }, ' No topic components provided. Use the "topics" slot to add TopicAccordion components. ', -1))
1131
+ e.mode === "topics" ? (h(), $("div", Vo, [
1132
+ pe(u.$slots, "topics", {}, () => [
1133
+ w[2] || (w[2] = P("div", { class: "no-topics" }, ' No topic components provided. Use the "topics" slot to add TopicAccordion components. ', -1))
1134
1134
  ], !0)
1135
- ])) : (m(), $("div", {
1135
+ ])) : (h(), $("div", {
1136
1136
  key: 2,
1137
1137
  class: re(["layer-list", { "has-metadata": c.value }])
1138
1138
  }, [
1139
- (m(!0), $(ue, null, ve(r.value, (S) => (m(), $("div", {
1140
- key: S.config.id,
1139
+ (h(!0), $(ue, null, be(r.value, (L) => (h(), $("div", {
1140
+ key: L.config.id,
1141
1141
  class: "layer-item"
1142
1142
  }, [
1143
- P("div", Vo, [
1144
- n(S.config.url) ? (m(), $("a", {
1143
+ P("div", Zo, [
1144
+ n(L.config.url) ? (h(), $("a", {
1145
1145
  key: 0,
1146
- href: n(S.config.url) || "",
1146
+ href: n(L.config.url) || "",
1147
1147
  target: "_blank",
1148
1148
  rel: "noopener noreferrer",
1149
1149
  class: "metadata-link",
1150
- "aria-label": "View metadata for " + S.config.title,
1151
- onClick: L[1] || (L[1] = Jt(() => {
1150
+ "aria-label": "View metadata for " + L.config.title,
1151
+ onClick: w[1] || (w[1] = Jt(() => {
1152
1152
  }, ["stop"]))
1153
1153
  }, [
1154
- H(d(ke), {
1155
- "icon-definition": d($o),
1154
+ J(f(ke), {
1155
+ "icon-definition": f($o),
1156
1156
  size: "small",
1157
1157
  inline: "",
1158
1158
  decorative: ""
1159
1159
  }, null, 8, ["icon-definition"])
1160
- ], 8, No)) : c.value ? (m(), $("span", Uo)) : R("", !0),
1160
+ ], 8, No)) : c.value ? (h(), $("span", Uo)) : R("", !0),
1161
1161
  P("label", {
1162
1162
  class: re(["layer-checkbox", {
1163
- "layer-unavailable": !d(g)(S.config),
1164
- "layer-error": d(h)(S.config.id)
1163
+ "layer-unavailable": !f(g)(L.config),
1164
+ "layer-error": f(y)(L.config.id)
1165
1165
  }])
1166
1166
  }, [
1167
1167
  P("input", {
1168
1168
  type: "checkbox",
1169
- checked: d(w)(S.config.id),
1170
- disabled: !d(g)(S.config),
1171
- onChange: (E) => v(S.config.id)
1169
+ checked: f(b)(L.config.id),
1170
+ disabled: !f(g)(L.config),
1171
+ onChange: (F) => v(L.config.id)
1172
1172
  }, null, 40, Wo),
1173
1173
  P("span", jo, [
1174
- xe(G(S.config.title) + " ", 1),
1175
- H(tt, {
1176
- loading: d(x)(S.config.id),
1177
- error: d(h)(S.config.id),
1178
- unavailable: !d(g)(S.config)
1174
+ xe(H(L.config.title) + " ", 1),
1175
+ J(at, {
1176
+ loading: f(C)(L.config.id),
1177
+ error: f(y)(L.config.id),
1178
+ unavailable: !f(g)(L.config)
1179
1179
  }, null, 8, ["loading", "error", "unavailable"])
1180
1180
  ])
1181
1181
  ], 2)
1182
1182
  ]),
1183
- e.showOpacity && d(w)(S.config.id) && d(g)(S.config) ? (m(), q(vt, {
1183
+ e.showOpacity && f(b)(L.config.id) && f(g)(L.config) ? (h(), G(vt, {
1184
1184
  key: 0,
1185
- "layer-id": S.config.id,
1186
- "layer-name": S.config.title,
1187
- opacity: d(p)(S.config.id),
1188
- "onUpdate:opacity": (E) => o("setOpacity", S.config.id, E)
1185
+ "layer-id": L.config.id,
1186
+ "layer-name": L.config.title,
1187
+ opacity: f(p)(L.config.id),
1188
+ "onUpdate:opacity": (F) => o("setOpacity", L.config.id, F)
1189
1189
  }, null, 8, ["layer-id", "layer-name", "opacity", "onUpdate:opacity"])) : R("", !0),
1190
- e.showLegend && d(w)(S.config.id) && d(g)(S.config) && S.config.legend?.length ? (m(), q(bt, {
1190
+ e.showLegend && f(b)(L.config.id) && f(g)(L.config) && L.config.legend?.length ? (h(), G(bt, {
1191
1191
  key: 1,
1192
- items: S.config.legend,
1193
- label: "Legend for " + S.config.title
1192
+ items: L.config.legend,
1193
+ label: "Legend for " + L.config.title
1194
1194
  }, null, 8, ["items", "label"])) : R("", !0)
1195
1195
  ]))), 128)),
1196
- r.value.length === 0 ? (m(), $("div", qo, 'No layers match "' + G(e.searchQuery) + '"', 1)) : R("", !0)
1196
+ r.value.length === 0 ? (h(), $("div", qo, 'No layers match "' + H(e.searchQuery) + '"', 1)) : R("", !0)
1197
1197
  ], 2))
1198
1198
  ]));
1199
1199
  }
1200
1200
  }), Ho = /* @__PURE__ */ $e(Go, [["__scopeId", "data-v-e48bb978"]]), Jo = {
1201
1201
  esriSLSSolid: null,
1202
- esriSLSDash: [4, 3],
1203
- esriSLSDot: [1, 3],
1204
- esriSLSDashDot: [4, 3, 1, 3],
1205
- esriSLSDashDotDot: [4, 3, 1, 3, 1, 3],
1202
+ esriSLSDash: [6, 1.5],
1203
+ esriSLSDot: [1, 1.5],
1204
+ esriSLSDashDot: [6, 1.5, 1, 1.5],
1205
+ esriSLSDashDotDot: [6, 1.5, 1, 1.5, 1, 1.5],
1206
1206
  esriSLSNull: null
1207
1207
  };
1208
- function at(e) {
1208
+ function Je(e) {
1209
1209
  if (e)
1210
1210
  return Jo[e] ?? void 0;
1211
1211
  }
1212
1212
  function Ko(e, i, l, o, r) {
1213
1213
  const n = [];
1214
- let c = i[0], w = [e[0]], p = 0;
1214
+ let c = i[0], b = [e[0]], p = 0;
1215
1215
  for (let a = 1; a < e.length; a++)
1216
- i[a] === c ? w.push(e[a]) : (n.push({ style: c, breaks: w, startIndex: p }), c = i[a], w = [e[a]], p = a);
1217
- n.push({ style: c, breaks: w, startIndex: p });
1218
- const x = [], h = /* @__PURE__ */ new Set();
1216
+ i[a] === c ? b.push(e[a]) : (n.push({ style: c, breaks: b, startIndex: p }), c = i[a], b = [e[a]], p = a);
1217
+ n.push({ style: c, breaks: b, startIndex: p });
1218
+ const C = [], y = /* @__PURE__ */ new Set();
1219
1219
  let g = o.minValue ?? 0;
1220
1220
  for (let a = 0; a < n.length; a++) {
1221
- const v = n[a], f = v.breaks, L = at(v.style), S = a === 0 ? null : n[a - 1].breaks[n[a - 1].breaks.length - 1].classMaxValue, E = f[f.length - 1].classMaxValue;
1222
- let D;
1223
- const X = !!o.defaultSymbol;
1224
- S === null ? D = `${!X && o.minValue != null ? `${l} >= ${o.minValue} AND ` : ""}${l} <= ${E}` : a === n.length - 1 && X ? D = `${l} > ${S}` : D = `${l} > ${S} AND ${l} <= ${E}`;
1221
+ const v = n[a], u = v.breaks, w = Je(v.style), L = a === 0 ? null : n[a - 1].breaks[n[a - 1].breaks.length - 1].classMaxValue, F = u[u.length - 1].classMaxValue;
1222
+ let E;
1223
+ const V = !!o.defaultSymbol;
1224
+ L === null ? E = `${!V && o.minValue != null ? `${l} >= ${o.minValue} AND ` : ""}${l} <= ${F}` : a === n.length - 1 && V ? E = `${l} > ${L}` : E = `${l} > ${L} AND ${l} <= ${F}`;
1225
1225
  const T = {
1226
- "line-opacity": be(r)
1226
+ "line-opacity": ye(r)
1227
1227
  };
1228
- if (L && (T["line-dasharray"] = L), f.length === 1)
1229
- T["line-color"] = I(f[0].symbol?.color), T["line-width"] = ee(f[0].symbol?.width || 2);
1228
+ if (w && (T["line-dasharray"] = w), u.length === 1)
1229
+ T["line-color"] = z(u[0].symbol?.color), T["line-width"] = X(u[0].symbol?.width || 2);
1230
1230
  else {
1231
- const U = ["step", ["get", l]], me = ["step", ["get", l]];
1232
- U.push(I(f[0].symbol?.color)), me.push(ee(f[0].symbol?.width || 2));
1233
- for (let he = 1; he < f.length; he++)
1234
- U.push(f[he - 1].classMaxValue), U.push(I(f[he].symbol?.color)), me.push(f[he - 1].classMaxValue), me.push(ee(f[he].symbol?.width || 2));
1235
- T["line-color"] = U, T["line-width"] = me;
1236
- }
1237
- const O = [];
1238
- for (const U of f)
1239
- O.push({
1231
+ const W = ["step", ["get", l]], he = ["step", ["get", l]];
1232
+ W.push(z(u[0].symbol?.color)), he.push(X(u[0].symbol?.width || 2));
1233
+ for (let ge = 1; ge < u.length; ge++)
1234
+ W.push(u[ge - 1].classMaxValue), W.push(z(u[ge].symbol?.color)), he.push(u[ge - 1].classMaxValue), he.push(X(u[ge].symbol?.width || 2));
1235
+ T["line-color"] = W, T["line-width"] = he;
1236
+ }
1237
+ const I = [];
1238
+ for (const W of u)
1239
+ I.push({
1240
1240
  type: "line",
1241
- color: I(U.symbol?.color),
1242
- width: ee(U.symbol?.width || 2),
1243
- label: U.label || `${g} - ${U.classMaxValue}`
1244
- }), g = U.classMaxValue + 1;
1241
+ color: z(W.symbol?.color),
1242
+ width: X(W.symbol?.width || 2),
1243
+ label: W.label || `${g} - ${W.classMaxValue}`
1244
+ }), g = W.classMaxValue + 1;
1245
1245
  const _ = v.style.replace("esriSLS", "").toLowerCase();
1246
1246
  let te;
1247
- a === 0 ? te = "" : h.has(_) ? te = `-${_}-${a}` : te = `-${_}`, h.add(_), x.push({ suffix: te, where: D, paint: T, legend: O });
1247
+ a === 0 ? te = "" : y.has(_) ? te = `-${_}-${a}` : te = `-${_}`, y.add(_), C.push({ suffix: te, where: E, paint: T, legend: I });
1248
1248
  }
1249
- return x;
1249
+ return C;
1250
1250
  }
1251
- function I(e) {
1251
+ function Qo(e, i, l, o, r) {
1252
+ const n = /* @__PURE__ */ new Map();
1253
+ for (const C of e) {
1254
+ const y = C.symbol?.style || "esriSLSSolid";
1255
+ n.has(y) || n.set(y, []), n.get(y).push(C);
1256
+ }
1257
+ const c = [], b = /* @__PURE__ */ new Set();
1258
+ let p = !0;
1259
+ for (const [C, y] of n) {
1260
+ const g = Je(C), v = y.map((E) => `${i} = '${String(E.value).replace(/'/g, "''")}'`).join(" OR "), u = {
1261
+ "line-opacity": ye(o)
1262
+ };
1263
+ if (g && (u["line-dasharray"] = g), y.length === 1)
1264
+ u["line-color"] = z(y[0].symbol?.color), u["line-width"] = X(y[0].symbol?.width || 2);
1265
+ else {
1266
+ const E = ["match", ["to-string", ["get", i]]];
1267
+ for (const V of y)
1268
+ E.push(tt(V.value)), E.push(z(V.symbol?.color));
1269
+ E.push(l ? z(l.color) : "rgba(0, 0, 0, 0)"), u["line-color"] = E, u["line-width"] = X(y[0].symbol?.width || 2);
1270
+ }
1271
+ const w = [];
1272
+ for (const E of y) {
1273
+ const V = String(E.value), I = r?.get(V) || E.label || V;
1274
+ w.push({
1275
+ type: "line",
1276
+ color: z(E.symbol?.color),
1277
+ width: X(E.symbol?.width || 1),
1278
+ label: I
1279
+ });
1280
+ }
1281
+ const L = C.replace("esriSLS", "").toLowerCase();
1282
+ let F;
1283
+ p ? F = "" : b.has(L) ? F = `-${L}-${c.length}` : F = `-${L}`, b.add(L), p = !1, c.push({ suffix: F, where: v, paint: u, legend: w });
1284
+ }
1285
+ return c;
1286
+ }
1287
+ function z(e) {
1252
1288
  if (!e || !Array.isArray(e) || e.length < 3) return "#888888";
1253
1289
  const i = e[0], l = e[1], o = e[2], n = (e[3] ?? 255) / 255;
1254
1290
  return n === 1 ? `#${i.toString(16).padStart(2, "0")}${l.toString(16).padStart(2, "0")}${o.toString(16).padStart(2, "0")}` : `rgba(${i}, ${l}, ${o}, ${n.toFixed(2)})`;
1255
1291
  }
1256
- function be(e) {
1292
+ function ye(e) {
1257
1293
  return e !== void 0 ? e : 1;
1258
1294
  }
1259
- function ee(e) {
1295
+ function X(e) {
1260
1296
  return Math.round(e * (96 / 72) * 10) / 10;
1261
1297
  }
1262
- const Qo = 559082264;
1298
+ const Xo = 559082264;
1263
1299
  function It(e) {
1264
- return !e || e <= 0 ? null : Math.round(Math.log2(Qo / e) * 100) / 100;
1300
+ return !e || e <= 0 ? null : Math.round(Math.log2(Xo / e) * 100) / 100;
1265
1301
  }
1266
- function Xo(e, i) {
1302
+ function Yo(e, i) {
1267
1303
  const l = {};
1268
1304
  if (e && e > 0) {
1269
1305
  const o = It(e);
@@ -1275,7 +1311,7 @@ function Xo(e, i) {
1275
1311
  }
1276
1312
  return l;
1277
1313
  }
1278
- function it(e) {
1314
+ function lt(e) {
1279
1315
  if (!e) return "fill";
1280
1316
  switch (e.type) {
1281
1317
  case "esriSFS":
@@ -1292,249 +1328,253 @@ function it(e) {
1292
1328
  return "fill";
1293
1329
  }
1294
1330
  }
1295
- function Te(e) {
1331
+ function Fe(e) {
1296
1332
  return !(!e || e.style === "esriSLSNull" || e.color === null || e.width === 0 || e.color && e.color[3] === 0);
1297
1333
  }
1298
- function yt(e) {
1334
+ function tt(e) {
1299
1335
  return String(e);
1300
1336
  }
1301
- function Zt(e, i, l) {
1302
- const o = e.symbol, r = it(o);
1303
- let n = {}, c = [], w = null;
1337
+ function Vt(e, i, l) {
1338
+ const o = e.symbol, r = lt(o);
1339
+ let n = {}, c = [], b = null;
1304
1340
  if (r === "fill" && o) {
1305
- const p = o.color === null ? 0 : o.color?.[3] ?? 255, x = p === 0 ? "rgba(0, 0, 0, 0)" : I(o.color), h = p === 0 ? 0 : p < 255 ? 1 : be(i);
1341
+ const p = o.color === null ? 0 : o.color?.[3] ?? 255, C = p === 0 ? "rgba(0, 0, 0, 0)" : z(o.color), y = p === 0 ? 0 : p < 255 ? 1 : ye(i);
1306
1342
  if (n = {
1307
- "fill-color": x,
1308
- "fill-opacity": h
1309
- }, Te(o.outline)) {
1310
- const g = ee(o.outline.width || 1);
1311
- w = {
1312
- "line-color": I(o.outline.color),
1343
+ "fill-color": C,
1344
+ "fill-opacity": y
1345
+ }, Fe(o.outline)) {
1346
+ const g = X(o.outline.width || 1);
1347
+ b = {
1348
+ "line-color": z(o.outline.color),
1313
1349
  "line-width": g
1314
1350
  };
1315
1351
  }
1316
1352
  c = [
1317
1353
  {
1318
1354
  type: "fill",
1319
- color: I(o.color),
1355
+ color: z(o.color),
1320
1356
  label: e.label || "Feature"
1321
1357
  }
1322
1358
  ];
1323
1359
  } else if (r === "line" && o) {
1324
1360
  n = {
1325
- "line-color": I(o.color),
1326
- "line-width": ee(o.width || 1),
1327
- "line-opacity": be(i)
1361
+ "line-color": z(o.color),
1362
+ "line-width": X(o.width || 1),
1363
+ "line-opacity": ye(i)
1328
1364
  };
1329
- const p = at(o.style);
1365
+ const p = Je(o.style);
1330
1366
  p && (n["line-dasharray"] = p), c = [
1331
1367
  {
1332
1368
  type: "line",
1333
- color: I(o.color),
1334
- width: ee(o.width || 1),
1369
+ color: z(o.color),
1370
+ width: X(o.width || 1),
1335
1371
  label: e.label || "Feature"
1336
1372
  }
1337
1373
  ];
1338
1374
  } else if (r === "circle" && o) {
1339
1375
  const p = Math.round((o.size || 6) * 0.71 * 100) / 100;
1340
1376
  n = {
1341
- "circle-color": I(o.color),
1377
+ "circle-color": z(o.color),
1342
1378
  "circle-radius": p,
1343
- "circle-opacity": be(i)
1344
- }, Te(o.outline) && (n["circle-stroke-color"] = I(o.outline.color), n["circle-stroke-width"] = ee(o.outline.width || 1)), c = [
1379
+ "circle-opacity": ye(i)
1380
+ }, Fe(o.outline) && (n["circle-stroke-color"] = z(o.outline.color), n["circle-stroke-width"] = X(o.outline.width || 1)), c = [
1345
1381
  {
1346
1382
  type: "circle",
1347
- color: I(o.color),
1383
+ color: z(o.color),
1348
1384
  label: e.label || "Feature"
1349
1385
  }
1350
1386
  ];
1351
1387
  }
1352
- return { paint: n, legend: c, geomType: r, outlinePaint: w };
1388
+ return { paint: n, legend: c, geomType: r, outlinePaint: b };
1353
1389
  }
1354
- function Yo(e, i, l) {
1390
+ function ea(e, i, l) {
1355
1391
  const o = e.field1.toLowerCase(), r = e.uniqueValueInfos || [], n = e.defaultSymbol;
1356
1392
  if (r.length === 0)
1357
- return Zt({ ...e, symbol: n }, i);
1358
- const c = r[0]?.symbol || n, w = it(c);
1393
+ return Vt({ ...e, symbol: n }, i);
1394
+ const c = r[0]?.symbol || n, b = lt(c);
1359
1395
  let p = {};
1360
- const x = [];
1361
- let h = null;
1362
- if (w === "fill") {
1396
+ const C = [];
1397
+ let y = null;
1398
+ if (b === "fill") {
1363
1399
  const g = ["match", ["to-string", ["get", o]]];
1364
1400
  for (const a of r) {
1365
- g.push(yt(a.value)), g.push(I(a.symbol?.color));
1366
- const v = String(a.value), L = l?.get(v) || a.label || v;
1367
- x.push({
1401
+ g.push(tt(a.value)), g.push(z(a.symbol?.color));
1402
+ const v = String(a.value), w = l?.get(v) || a.label || v;
1403
+ C.push({
1368
1404
  type: "fill",
1369
- color: I(a.symbol?.color),
1370
- label: L
1405
+ color: z(a.symbol?.color),
1406
+ label: w
1371
1407
  });
1372
1408
  }
1373
- if (g.push(n ? I(n.color) : "rgba(0, 0, 0, 0)"), p = {
1409
+ if (g.push(n ? z(n.color) : "rgba(0, 0, 0, 0)"), p = {
1374
1410
  "fill-color": g,
1375
- "fill-opacity": be(i)
1376
- }, Te(c?.outline)) {
1377
- const a = ee(Math.max(c.outline.width || 1, 1));
1378
- h = {
1379
- "line-color": I(c.outline.color),
1411
+ "fill-opacity": ye(i)
1412
+ }, Fe(c?.outline)) {
1413
+ const a = X(Math.max(c.outline.width || 1, 1));
1414
+ y = {
1415
+ "line-color": z(c.outline.color),
1380
1416
  "line-width": a
1381
1417
  };
1382
1418
  }
1383
- } else if (w === "line") {
1419
+ } else if (b === "line") {
1384
1420
  const g = ["match", ["to-string", ["get", o]]];
1385
- for (const f of r) {
1386
- g.push(yt(f.value)), g.push(I(f.symbol?.color));
1387
- const L = String(f.value), E = l?.get(L) || f.label || L;
1388
- x.push({
1421
+ for (const u of r) {
1422
+ g.push(tt(u.value)), g.push(z(u.symbol?.color));
1423
+ const w = String(u.value), F = l?.get(w) || u.label || w;
1424
+ C.push({
1389
1425
  type: "line",
1390
- color: I(f.symbol?.color),
1391
- width: ee(f.symbol?.width || 1),
1392
- label: E
1426
+ color: z(u.symbol?.color),
1427
+ width: X(u.symbol?.width || 1),
1428
+ label: F
1393
1429
  });
1394
1430
  }
1395
- g.push(n ? I(n.color) : "rgba(0, 0, 0, 0)"), p = {
1431
+ g.push(n ? z(n.color) : "rgba(0, 0, 0, 0)"), p = {
1396
1432
  "line-color": g,
1397
- "line-width": ee(c?.width || 2),
1398
- "line-opacity": be(i)
1433
+ "line-width": X(c?.width || 2),
1434
+ "line-opacity": ye(i)
1399
1435
  };
1400
- const a = r.map((f) => f.symbol?.style).filter(Boolean), v = [...new Set(a)];
1436
+ const a = r.map((u) => u.symbol?.style || "esriSLSSolid"), v = [...new Set(a)];
1437
+ if (v.length > 1) {
1438
+ const u = Qo(r, o, n, i, l);
1439
+ return { paint: {}, legend: [], geomType: b, outlinePaint: y, splitLayers: u };
1440
+ }
1401
1441
  if (v.length === 1) {
1402
- const f = at(v[0]);
1403
- f && (p["line-dasharray"] = f);
1442
+ const u = Je(v[0]);
1443
+ u && (p["line-dasharray"] = u);
1404
1444
  }
1405
- } else if (w === "circle") {
1445
+ } else if (b === "circle") {
1406
1446
  const g = ["match", ["to-string", ["get", o]]];
1407
1447
  for (const v of r) {
1408
- g.push(yt(v.value)), g.push(I(v.symbol?.color));
1409
- const f = String(v.value), S = l?.get(f) || v.label || f;
1410
- x.push({
1448
+ g.push(tt(v.value)), g.push(z(v.symbol?.color));
1449
+ const u = String(v.value), L = l?.get(u) || v.label || u;
1450
+ C.push({
1411
1451
  type: "circle",
1412
- color: I(v.symbol?.color),
1413
- label: S
1452
+ color: z(v.symbol?.color),
1453
+ label: L
1414
1454
  });
1415
1455
  }
1416
- g.push(n ? I(n.color) : "rgba(0, 0, 0, 0)");
1456
+ g.push(n ? z(n.color) : "rgba(0, 0, 0, 0)");
1417
1457
  const a = Math.round((c?.size || 6) * 0.71 * 100) / 100;
1418
1458
  p = {
1419
1459
  "circle-color": g,
1420
1460
  "circle-radius": a,
1421
- "circle-opacity": be(i)
1422
- }, Te(c?.outline) && (p["circle-stroke-color"] = I(c.outline.color), p["circle-stroke-width"] = ee(c.outline.width || 1));
1461
+ "circle-opacity": ye(i)
1462
+ }, Fe(c?.outline) && (p["circle-stroke-color"] = z(c.outline.color), p["circle-stroke-width"] = X(c.outline.width || 1));
1423
1463
  }
1424
- return { paint: p, legend: x, geomType: w, outlinePaint: h };
1464
+ return { paint: p, legend: C, geomType: b, outlinePaint: y };
1425
1465
  }
1426
- function ea(e, i) {
1427
- const l = e.field.toLowerCase(), o = e.classBreakInfos || [], r = e.visualVariables?.find((h) => h.type === "colorInfo");
1466
+ function ta(e, i) {
1467
+ const l = e.field.toLowerCase(), o = e.classBreakInfos || [], r = e.visualVariables?.find((y) => y.type === "colorInfo");
1428
1468
  if (r?.stops && r.stops.length > 0)
1429
- return ta(r, l, e, i);
1469
+ return oa(r, l, e, i);
1430
1470
  if (o.length === 0)
1431
1471
  return { paint: {}, legend: [], geomType: "fill", outlinePaint: null };
1432
- const n = o[0]?.symbol, c = it(n);
1433
- let w = {};
1472
+ const n = o[0]?.symbol, c = lt(n);
1473
+ let b = {};
1434
1474
  const p = [];
1435
- let x = null;
1475
+ let C = null;
1436
1476
  if (c === "fill") {
1437
- const h = ["step", ["get", l]];
1438
- h.push(I(o[0]?.symbol?.color));
1477
+ const y = ["step", ["get", l]];
1478
+ y.push(z(o[0]?.symbol?.color));
1439
1479
  for (let g = 0; g < o.length; g++) {
1440
1480
  const a = o[g];
1441
- g > 0 && (h.push(o[g - 1].classMaxValue), h.push(I(a.symbol?.color))), p.push({
1481
+ g > 0 && (y.push(o[g - 1].classMaxValue), y.push(z(a.symbol?.color))), p.push({
1442
1482
  type: "fill",
1443
- color: I(a.symbol?.color),
1483
+ color: z(a.symbol?.color),
1444
1484
  label: a.label || `${a.classMaxValue}`
1445
1485
  });
1446
1486
  }
1447
- if (w = {
1448
- "fill-color": h,
1449
- "fill-opacity": be(i)
1450
- }, Te(n?.outline)) {
1451
- const g = ee(n.outline.width || 1);
1452
- x = {
1453
- "line-color": I(n.outline.color),
1487
+ if (b = {
1488
+ "fill-color": y,
1489
+ "fill-opacity": ye(i)
1490
+ }, Fe(n?.outline)) {
1491
+ const g = X(n.outline.width || 1);
1492
+ C = {
1493
+ "line-color": z(n.outline.color),
1454
1494
  "line-width": g
1455
1495
  };
1456
1496
  }
1457
1497
  } else if (c === "line") {
1458
- const h = o.map((E) => E.symbol?.style || "esriSLSSolid"), g = [...new Set(h)];
1498
+ const y = o.map((F) => F.symbol?.style || "esriSLSSolid"), g = [...new Set(y)];
1459
1499
  if (g.length > 1) {
1460
- const E = Ko(o, h, l, e, i);
1461
- return { paint: {}, legend: [], geomType: c, outlinePaint: x, splitLayers: E };
1500
+ const F = Ko(o, y, l, e, i);
1501
+ return { paint: {}, legend: [], geomType: c, outlinePaint: C, splitLayers: F };
1462
1502
  }
1463
1503
  const v = ["step", ["get", l]];
1464
- v.push(I(o[0]?.symbol?.color));
1465
- let f = e.minValue ?? 0;
1466
- for (let E = 0; E < o.length; E++) {
1467
- const D = o[E];
1468
- E > 0 && (v.push(o[E - 1].classMaxValue), v.push(I(D.symbol?.color))), p.push({
1504
+ v.push(z(o[0]?.symbol?.color));
1505
+ let u = e.minValue ?? 0;
1506
+ for (let F = 0; F < o.length; F++) {
1507
+ const E = o[F];
1508
+ F > 0 && (v.push(o[F - 1].classMaxValue), v.push(z(E.symbol?.color))), p.push({
1469
1509
  type: "line",
1470
- color: I(D.symbol?.color),
1471
- width: ee(D.symbol?.width || n?.width || 2),
1472
- label: D.label || `${f} - ${D.classMaxValue}`
1473
- }), f = D.classMaxValue + 1;
1510
+ color: z(E.symbol?.color),
1511
+ width: X(E.symbol?.width || n?.width || 2),
1512
+ label: E.label || `${u} - ${E.classMaxValue}`
1513
+ }), u = E.classMaxValue + 1;
1474
1514
  }
1475
- const L = ee(n?.width || 2);
1476
- w = {
1515
+ const w = X(n?.width || 2);
1516
+ b = {
1477
1517
  "line-color": v,
1478
- "line-width": L,
1479
- "line-opacity": be(i)
1518
+ "line-width": w,
1519
+ "line-opacity": ye(i)
1480
1520
  };
1481
- const S = at(g[0]);
1482
- S && (w["line-dasharray"] = S);
1521
+ const L = Je(g[0]);
1522
+ L && (b["line-dasharray"] = L);
1483
1523
  }
1484
- return { paint: w, legend: p, geomType: c, outlinePaint: x };
1524
+ return { paint: b, legend: p, geomType: c, outlinePaint: C };
1485
1525
  }
1486
- function ta(e, i, l, o) {
1526
+ function oa(e, i, l, o) {
1487
1527
  const r = e.stops || [];
1488
1528
  if (r.length === 0)
1489
1529
  return { paint: {}, legend: [], geomType: "fill", outlinePaint: null };
1490
- const n = l.classBreakInfos?.[0]?.symbol || l.defaultSymbol, c = it(n);
1491
- let w = {};
1530
+ const n = l.classBreakInfos?.[0]?.symbol || l.defaultSymbol, c = lt(n);
1531
+ let b = {};
1492
1532
  const p = [];
1493
- let x = null;
1533
+ let C = null;
1494
1534
  if (c === "fill") {
1495
- const h = ["interpolate", ["linear"], ["get", i]];
1535
+ const y = ["interpolate", ["linear"], ["get", i]];
1496
1536
  for (const a of r)
1497
- h.push(a.value), h.push(I(a.color)), p.push({
1537
+ y.push(a.value), y.push(z(a.color)), p.push({
1498
1538
  type: "fill",
1499
- color: I(a.color),
1539
+ color: z(a.color),
1500
1540
  label: a.label || `${a.value}`
1501
1541
  });
1502
- if (w = {
1542
+ if (b = {
1503
1543
  "fill-color": [
1504
1544
  "case",
1505
1545
  ["==", ["get", i], null],
1506
1546
  "rgba(0, 0, 0, 0)",
1507
1547
  // Transparent for null/no-data values
1508
- h
1548
+ y
1509
1549
  // Otherwise use the interpolated color
1510
1550
  ],
1511
- "fill-opacity": be(o)
1512
- }, Te(n?.outline)) {
1513
- const a = ee(n.outline.width || 1);
1514
- x = {
1515
- "line-color": I(n.outline.color),
1551
+ "fill-opacity": ye(o)
1552
+ }, Fe(n?.outline)) {
1553
+ const a = X(n.outline.width || 1);
1554
+ C = {
1555
+ "line-color": z(n.outline.color),
1516
1556
  "line-width": a
1517
1557
  };
1518
1558
  }
1519
1559
  }
1520
- return { paint: w, legend: p, geomType: c, outlinePaint: x };
1560
+ return { paint: b, legend: p, geomType: c, outlinePaint: C };
1521
1561
  }
1522
- function oa(e, i, l, o) {
1562
+ function aa(e, i, l, o) {
1523
1563
  if (!e?.renderer)
1524
1564
  return { paint: {}, legend: [], geomType: "fill", outlinePaint: null };
1525
1565
  const r = e.renderer;
1526
1566
  switch (r.type) {
1527
1567
  case "simple":
1528
- return Zt(r, i);
1568
+ return Vt(r, i);
1529
1569
  case "uniqueValue":
1530
- return Yo(r, i, l);
1570
+ return ea(r, i, l);
1531
1571
  case "classBreaks":
1532
- return ea(r, i);
1572
+ return ta(r, i);
1533
1573
  default:
1534
1574
  return { paint: {}, legend: [], geomType: "fill", outlinePaint: null };
1535
1575
  }
1536
1576
  }
1537
- function aa(e) {
1577
+ function ia(e) {
1538
1578
  if (!e) return null;
1539
1579
  const i = (e.title || "").replace(/\{([^}]+)\}/g, (n, c) => `{${c.toLowerCase()}}`), o = (e.fieldInfos || []).filter((n) => n.visible === !0).map((n) => {
1540
1580
  const c = {
@@ -1548,16 +1588,16 @@ function aa(e) {
1548
1588
  };
1549
1589
  return e.showTime && (r.showTime = !0), r;
1550
1590
  }
1551
- function ia(e) {
1591
+ function la(e) {
1552
1592
  return e?.definitionExpression;
1553
1593
  }
1554
- function la(e) {
1594
+ function na(e) {
1555
1595
  return (e.includes("_") ? e.split("_").slice(1).join(" ") : e).toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-|-$/g, "");
1556
1596
  }
1557
- function na(e) {
1597
+ function ra(e) {
1558
1598
  return e.includes("_") ? e.split("_").slice(1).join(" ") : e;
1559
1599
  }
1560
- function ra(e) {
1600
+ function sa(e) {
1561
1601
  const i = /* @__PURE__ */ new Map();
1562
1602
  if (!e)
1563
1603
  return i;
@@ -1566,13 +1606,13 @@ function ra(e) {
1566
1606
  for (const r of l) {
1567
1607
  const n = r.trim().match(o);
1568
1608
  if (n) {
1569
- const [, c, w] = n;
1570
- c && w && i.set(c, w.trim());
1609
+ const [, c, b] = n;
1610
+ c && b && i.set(c, b.trim());
1571
1611
  }
1572
1612
  }
1573
1613
  return i;
1574
1614
  }
1575
- async function sa(e) {
1615
+ async function ca(e) {
1576
1616
  try {
1577
1617
  const i = await fetch(`${e}?f=json`);
1578
1618
  if (!i.ok)
@@ -1599,85 +1639,85 @@ function zt(e) {
1599
1639
  };
1600
1640
  return e.where && (i.where = e.where), e.minZoom !== void 0 && (i.minZoom = e.minZoom), e.maxZoom !== void 0 && (i.maxZoom = e.maxZoom), e.outlinePaint && (i.outlinePaint = e.outlinePaint), i;
1601
1641
  }
1602
- async function Vt(e) {
1642
+ async function Zt(e) {
1603
1643
  const i = e.operationalLayers || [], l = [], o = ["Zoning and Planning_Land Use"];
1604
1644
  for (const r of i)
1605
1645
  if (r.url && !r.title?.toLowerCase().includes("(under construction)") && !(r.url && /\/MapServer(\/\d+)?$/i.test(r.url)))
1606
1646
  try {
1607
1647
  let n = r.layerDefinition?.drawingInfo, c;
1608
- const w = !n || !n.renderer, p = o.includes(r.title), x = n?.renderer?.uniqueValueInfos?.[0]?.symbol?.outline || n?.renderer?.defaultSymbol?.outline;
1609
- if ((w || p) && r.url) {
1610
- const O = await sa(r.url);
1611
- if (O) {
1612
- if (n = O.drawingInfo, x && Te(x) && n?.renderer) {
1648
+ const b = !n || !n.renderer, p = o.includes(r.title), C = n?.renderer?.uniqueValueInfos?.[0]?.symbol?.outline || n?.renderer?.defaultSymbol?.outline;
1649
+ if ((b || p) && r.url) {
1650
+ const I = await ca(r.url);
1651
+ if (I) {
1652
+ if (n = I.drawingInfo, C && Fe(C) && n?.renderer) {
1613
1653
  const _ = n.renderer, te = _.uniqueValueInfos?.[0]?.symbol?.outline || _.defaultSymbol?.outline;
1614
- if (!Te(te)) {
1615
- for (const U of _.uniqueValueInfos || [])
1616
- U.symbol && (U.symbol.outline = x);
1617
- _.defaultSymbol && (_.defaultSymbol.outline = x);
1654
+ if (!Fe(te)) {
1655
+ for (const W of _.uniqueValueInfos || [])
1656
+ W.symbol && (W.symbol.outline = C);
1657
+ _.defaultSymbol && (_.defaultSymbol.outline = C);
1618
1658
  }
1619
1659
  }
1620
- O.description && (c = ra(O.description), c.size > 0);
1660
+ I.description && (c = sa(I.description), c.size > 0);
1621
1661
  }
1622
1662
  }
1623
- const { paint: h, legend: g, geomType: a, outlinePaint: v, splitLayers: f } = oa(
1663
+ const { paint: y, legend: g, geomType: a, outlinePaint: v, splitLayers: u } = aa(
1624
1664
  n,
1625
1665
  r.opacity,
1626
1666
  c,
1627
1667
  r.title
1628
- ), L = aa(r.popupInfo), S = ia(r.layerDefinition), E = Xo(r.layerDefinition?.minScale, r.layerDefinition?.maxScale), D = la(r.title), X = na(r.title), T = r.opacity ?? 1;
1629
- if (f && f.length > 0)
1630
- for (const O of f)
1668
+ ), w = ia(r.popupInfo), L = la(r.layerDefinition), F = Yo(r.layerDefinition?.minScale, r.layerDefinition?.maxScale), E = na(r.title), V = ra(r.title), T = r.opacity ?? 1;
1669
+ if (u && u.length > 0)
1670
+ for (const I of u)
1631
1671
  l.push(zt({
1632
- id: `${D}${O.suffix}`,
1633
- title: X,
1672
+ id: `${E}${I.suffix}`,
1673
+ title: V,
1634
1674
  type: a,
1635
1675
  url: r.url,
1636
1676
  opacity: T,
1637
- paint: O.paint,
1638
- legend: O.legend,
1639
- popup: L,
1640
- where: S ? `(${S}) AND (${O.where})` : O.where,
1641
- minZoom: E.minZoom,
1642
- maxZoom: E.maxZoom
1677
+ paint: I.paint,
1678
+ legend: I.legend,
1679
+ popup: w,
1680
+ where: L ? `(${L}) AND (${I.where})` : I.where,
1681
+ minZoom: F.minZoom,
1682
+ maxZoom: F.maxZoom
1643
1683
  }));
1644
1684
  else
1645
1685
  l.push(zt({
1646
- id: D,
1647
- title: X,
1686
+ id: E,
1687
+ title: V,
1648
1688
  type: a,
1649
1689
  url: r.url,
1650
1690
  opacity: T,
1651
- paint: h,
1691
+ paint: y,
1652
1692
  legend: g,
1653
- popup: L,
1654
- where: S,
1655
- minZoom: E.minZoom,
1656
- maxZoom: E.maxZoom,
1693
+ popup: w,
1694
+ where: L,
1695
+ minZoom: F.minZoom,
1696
+ maxZoom: F.maxZoom,
1657
1697
  outlinePaint: v
1658
1698
  }));
1659
1699
  } catch {
1660
1700
  }
1661
1701
  return l.sort((r, n) => r.title.localeCompare(n.title)), l;
1662
1702
  }
1663
- const Dt = {}, Lt = "376af635c84643cd816a8c5d017a53aa", qa = Lt;
1703
+ const Dt = {}, Lt = "376af635c84643cd816a8c5d017a53aa", Ga = Lt;
1664
1704
  function St(e, i) {
1665
1705
  let l = `https://www.arcgis.com/sharing/rest/content/items/${e}/data?f=json`;
1666
1706
  return i && (l += `&token=${i}`), l;
1667
1707
  }
1668
- function Ga() {
1708
+ function Ha() {
1669
1709
  return St(Lt);
1670
1710
  }
1671
- const ot = /* @__PURE__ */ new Map(), He = /* @__PURE__ */ new Map();
1672
- function ca(e) {
1673
- e ? (ot.delete(e), He.delete(e)) : (ot.clear(), He.clear());
1711
+ const it = /* @__PURE__ */ new Map(), He = /* @__PURE__ */ new Map();
1712
+ function ua(e) {
1713
+ e ? (it.delete(e), He.delete(e)) : (it.clear(), He.clear());
1674
1714
  }
1675
- let Ye, _t = 0;
1676
- async function ua() {
1715
+ let et, _t = 0;
1716
+ async function da() {
1677
1717
  const e = typeof import.meta < "u" && Dt?.VITE_AGO_USERNAME, i = typeof import.meta < "u" && Dt?.VITE_AGO_PASSWORD;
1678
1718
  if (!(!e || !i)) {
1679
- if (Ye && Date.now() < _t - 3e5)
1680
- return Ye;
1719
+ if (et && Date.now() < _t - 3e5)
1720
+ return et;
1681
1721
  try {
1682
1722
  const o = await (await fetch("https://www.arcgis.com/sharing/rest/generateToken", {
1683
1723
  method: "POST",
@@ -1693,13 +1733,13 @@ async function ua() {
1693
1733
  // 2 hours
1694
1734
  })
1695
1735
  })).json();
1696
- return o.error ? void 0 : (Ye = o.token, _t = o.expires, Ye);
1736
+ return o.error ? void 0 : (et = o.token, _t = o.expires, et);
1697
1737
  } catch {
1698
1738
  return;
1699
1739
  }
1700
1740
  }
1701
1741
  }
1702
- async function da(e, i) {
1742
+ async function fa(e, i) {
1703
1743
  const l = St(e, i), o = await fetch(l, { cache: "no-store" });
1704
1744
  if (!o.ok)
1705
1745
  throw new Error(`Failed to fetch WebMap: ${o.status} ${o.statusText}`);
@@ -1708,10 +1748,10 @@ async function da(e, i) {
1708
1748
  throw new Error(`ArcGIS error: ${r.error.message || r.error.code || "Unknown error"}`);
1709
1749
  return r;
1710
1750
  }
1711
- async function fa(e) {
1751
+ async function pa(e) {
1712
1752
  try {
1713
- const i = await ua(), l = await da(e, i);
1714
- return await Vt(l);
1753
+ const i = await da(), l = await fa(e, i);
1754
+ return await Zt(l);
1715
1755
  } catch (i) {
1716
1756
  throw new Error(
1717
1757
  `Failed to load dynamic layer configs: ${i instanceof Error ? i.message : "Unknown error"}`
@@ -1719,7 +1759,7 @@ async function fa(e) {
1719
1759
  }
1720
1760
  }
1721
1761
  async function gt(e = Lt) {
1722
- const i = ot.get(e);
1762
+ const i = it.get(e);
1723
1763
  if (i)
1724
1764
  return i;
1725
1765
  const l = He.get(e);
@@ -1727,16 +1767,16 @@ async function gt(e = Lt) {
1727
1767
  return l;
1728
1768
  const o = (async () => {
1729
1769
  try {
1730
- const r = await fa(e);
1731
- return ot.set(e, r), r;
1770
+ const r = await pa(e);
1771
+ return it.set(e, r), r;
1732
1772
  } finally {
1733
1773
  He.delete(e);
1734
1774
  }
1735
1775
  })();
1736
1776
  return He.set(e, o), o;
1737
1777
  }
1738
- function pa(e) {
1739
- const i = k({}), l = /* @__PURE__ */ new Map();
1778
+ function ya(e) {
1779
+ const i = x({}), l = /* @__PURE__ */ new Map();
1740
1780
  for (const a of e)
1741
1781
  i.value[a.id] = {
1742
1782
  data: null,
@@ -1756,48 +1796,48 @@ function pa(e) {
1756
1796
  }
1757
1797
  };
1758
1798
  try {
1759
- let f;
1799
+ let u;
1760
1800
  if (a.type === "http-get") {
1761
- const L = await fetch(a.url, {
1801
+ const w = await fetch(a.url, {
1762
1802
  method: "GET",
1763
1803
  ...a.options
1764
1804
  });
1765
- if (!L.ok)
1766
- throw new Error(`HTTP ${L.status}: ${L.statusText}`);
1767
- f = await L.json();
1805
+ if (!w.ok)
1806
+ throw new Error(`HTTP ${w.status}: ${w.statusText}`);
1807
+ u = await w.json();
1768
1808
  } else if (a.type === "http-post") {
1769
- const L = await fetch(a.url, {
1809
+ const w = await fetch(a.url, {
1770
1810
  method: "POST",
1771
1811
  ...a.options
1772
1812
  });
1773
- if (!L.ok)
1774
- throw new Error(`HTTP ${L.status}: ${L.statusText}`);
1775
- f = await L.json();
1813
+ if (!w.ok)
1814
+ throw new Error(`HTTP ${w.status}: ${w.statusText}`);
1815
+ u = await w.json();
1776
1816
  } else if (a.type === "esri") {
1777
- const S = `${a.url.replace(/\/$/, "")}/query?where=1%3D1&outFields=*&returnGeometry=false&f=json`, E = await fetch(S, a.options);
1778
- if (!E.ok)
1779
- throw new Error(`HTTP ${E.status}: ${E.statusText}`);
1780
- f = (await E.json()).features?.map((X) => X.attributes) || [];
1817
+ const L = `${a.url.replace(/\/$/, "")}/query?where=1%3D1&outFields=*&returnGeometry=false&f=json`, F = await fetch(L, a.options);
1818
+ if (!F.ok)
1819
+ throw new Error(`HTTP ${F.status}: ${F.statusText}`);
1820
+ u = (await F.json()).features?.map((V) => V.attributes) || [];
1781
1821
  } else
1782
1822
  throw new Error(`Unknown data source type: ${a.type}`);
1783
- a.transform && (f = a.transform(f)), i.value = {
1823
+ a.transform && (u = a.transform(u)), i.value = {
1784
1824
  ...i.value,
1785
1825
  [v]: {
1786
- data: f,
1826
+ data: u,
1787
1827
  loading: !1,
1788
1828
  error: null,
1789
1829
  lastFetched: Date.now()
1790
1830
  }
1791
1831
  };
1792
- } catch (f) {
1793
- const L = f instanceof Error ? f.message : "Unknown error";
1832
+ } catch (u) {
1833
+ const w = u instanceof Error ? u.message : "Unknown error";
1794
1834
  i.value = {
1795
1835
  ...i.value,
1796
1836
  [v]: {
1797
1837
  data: i.value[v]?.data ?? null,
1798
1838
  lastFetched: i.value[v]?.lastFetched ?? null,
1799
1839
  loading: !1,
1800
- error: L
1840
+ error: w
1801
1841
  }
1802
1842
  };
1803
1843
  }
@@ -1806,20 +1846,20 @@ function pa(e) {
1806
1846
  await Promise.all(e.map((a) => o(a)));
1807
1847
  }
1808
1848
  async function n(a) {
1809
- const v = e.find((f) => f.id === a);
1849
+ const v = e.find((u) => u.id === a);
1810
1850
  v && await o(v);
1811
1851
  }
1812
1852
  function c(a) {
1813
1853
  return i.value[a]?.data ?? null;
1814
1854
  }
1815
- const w = z(() => Object.values(i.value).some((a) => a.loading));
1855
+ const b = D(() => Object.values(i.value).some((a) => a.loading));
1816
1856
  function p(a) {
1817
1857
  return i.value[a]?.loading ?? !1;
1818
1858
  }
1819
- function x(a) {
1859
+ function C(a) {
1820
1860
  return i.value[a]?.error ?? null;
1821
1861
  }
1822
- function h() {
1862
+ function y() {
1823
1863
  for (const a of e)
1824
1864
  if (a.pollInterval && a.pollInterval > 0) {
1825
1865
  const v = window.setInterval(() => {
@@ -1833,15 +1873,15 @@ function pa(e) {
1833
1873
  window.clearInterval(a);
1834
1874
  l.clear();
1835
1875
  }
1836
- return et(() => {
1837
- r(), h();
1876
+ return ot(() => {
1877
+ r(), y();
1838
1878
  }), Rt(() => {
1839
1879
  g();
1840
1880
  }), {
1841
1881
  /** Reactive state for all data sources */
1842
- state: j(i),
1882
+ state: q(i),
1843
1883
  /** Whether any data source is currently loading */
1844
- isLoading: w,
1884
+ isLoading: b,
1845
1885
  /** Fetch all data sources */
1846
1886
  fetchAll: r,
1847
1887
  /** Refetch a specific data source by id */
@@ -1851,27 +1891,27 @@ function pa(e) {
1851
1891
  /** Check if a specific source is loading */
1852
1892
  isSourceLoading: p,
1853
1893
  /** Get error for a specific source */
1854
- getError: x,
1894
+ getError: C,
1855
1895
  /** Stop all polling (useful for cleanup) */
1856
1896
  stopPolling: g
1857
1897
  };
1858
1898
  }
1859
- const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
1899
+ const ma = { class: "layerboard-layout" }, ha = ["aria-expanded"], ga = {
1860
1900
  key: 0,
1861
1901
  class: "layerboard-subtitle"
1862
- }, ga = { class: "layerboard-mobile-menu-content" }, va = { class: "layerboard-main" }, ba = {
1902
+ }, va = { class: "layerboard-mobile-menu-content" }, ba = { class: "layerboard-main" }, wa = {
1863
1903
  key: 0,
1864
1904
  class: "layerboard-loading",
1865
1905
  role: "status",
1866
1906
  "aria-live": "polite"
1867
- }, wa = {
1907
+ }, La = {
1868
1908
  key: 1,
1869
1909
  class: "layerboard-error",
1870
1910
  role: "alert"
1871
- }, La = ["aria-expanded", "aria-label"], Sa = { key: 0 }, Ca = { key: 1 }, ka = {
1911
+ }, Sa = ["aria-expanded", "aria-label"], Ca = { key: 0 }, ka = { key: 1 }, xa = {
1872
1912
  class: "sr-only",
1873
1913
  "aria-live": "polite"
1874
- }, xa = /* @__PURE__ */ ye({
1914
+ }, $a = /* @__PURE__ */ me({
1875
1915
  __name: "Layerboard",
1876
1916
  props: {
1877
1917
  title: {},
@@ -1901,193 +1941,193 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
1901
1941
  },
1902
1942
  emits: ["configs-loaded", "load-error", "zoom"],
1903
1943
  setup(e, { expose: i, emit: l }) {
1904
- const o = e, r = l, n = k([]), c = k(!0), w = k(null), p = k(12), x = k(""), h = k(/* @__PURE__ */ new Set()), g = k({}), a = k(/* @__PURE__ */ new Set()), v = k({}), f = k({}), L = k(/* @__PURE__ */ new Set()), S = k({});
1905
- function E() {
1906
- const y = {};
1944
+ const o = e, r = l, n = x([]), c = x(!0), b = x(null), p = x(12), C = x(""), y = x(/* @__PURE__ */ new Set()), g = x({}), a = x(/* @__PURE__ */ new Set()), v = x({}), u = x({}), w = x(/* @__PURE__ */ new Set()), L = x({});
1945
+ function F() {
1946
+ const m = {};
1907
1947
  for (const M of o.tiledLayers)
1908
- y[M.id] = M.opacity ?? 1;
1909
- S.value = y;
1948
+ m[M.id] = M.opacity ?? 1;
1949
+ L.value = m;
1910
1950
  }
1911
- function D(y) {
1912
- L.value.has(y) ? L.value.delete(y) : L.value.add(y), L.value = new Set(L.value);
1951
+ function E(m) {
1952
+ w.value.has(m) ? w.value.delete(m) : w.value.add(m), w.value = new Set(w.value);
1913
1953
  }
1914
- function X(y, M) {
1915
- M ? L.value.add(y) : L.value.delete(y), L.value = new Set(L.value);
1954
+ function V(m, M) {
1955
+ M ? w.value.add(m) : w.value.delete(m), w.value = new Set(w.value);
1916
1956
  }
1917
- function T(y, M) {
1918
- S.value = { ...S.value, [y]: M };
1957
+ function T(m, M) {
1958
+ L.value = { ...L.value, [m]: M };
1919
1959
  }
1920
- const O = o.dataSources.length > 0 ? pa(o.dataSources) : null, _ = z(() => O?.state.value ?? {}), te = z(() => O?.isLoading.value ?? !1);
1921
- function U(y) {
1922
- return O?.getData(y) ?? null;
1960
+ const I = o.dataSources.length > 0 ? ya(o.dataSources) : null, _ = D(() => I?.state.value ?? {}), te = D(() => I?.isLoading.value ?? !1);
1961
+ function W(m) {
1962
+ return I?.getData(m) ?? null;
1923
1963
  }
1924
- function me(y) {
1925
- return O?.refetch(y) ?? Promise.resolve();
1964
+ function he(m) {
1965
+ return I?.refetch(m) ?? Promise.resolve();
1926
1966
  }
1927
- Z("layerboard-layers", j(n)), Z("layerboard-visible", h), Z("layerboard-opacities", g), Z("layerboard-loading", j(a)), Z("layerboard-errors", j(v)), Z("layerboard-zoom", j(p)), Z("layerboard-toggle-layer", _e), Z("layerboard-set-layer-visible", Me), Z("layerboard-set-layers-visible", Re), Z("layerboard-set-opacity", Pe), Z("layerboard-tiled-layers", j(z(() => o.tiledLayers))), Z("layerboard-visible-tiled", L), Z("layerboard-tiled-opacities", S), Z("layerboard-toggle-tiled", D), Z("layerboard-set-tiled-opacity", T), Z("layerboard-set-tiled-visible", X), Z("layerboard-data-sources-state", _), Z("layerboard-data-sources-loading", te), Z("layerboard-get-data-source", U), Z("layerboard-refetch-data-source", me);
1928
- const he = z(() => ({
1967
+ Z("layerboard-layers", q(n)), Z("layerboard-visible", y), Z("layerboard-opacities", g), Z("layerboard-loading", q(a)), Z("layerboard-errors", q(v)), Z("layerboard-zoom", q(p)), Z("layerboard-toggle-layer", _e), Z("layerboard-set-layer-visible", Me), Z("layerboard-set-layers-visible", Re), Z("layerboard-set-opacity", Pe), Z("layerboard-tiled-layers", q(D(() => o.tiledLayers))), Z("layerboard-visible-tiled", w), Z("layerboard-tiled-opacities", L), Z("layerboard-toggle-tiled", E), Z("layerboard-set-tiled-opacity", T), Z("layerboard-set-tiled-visible", V), Z("layerboard-data-sources-state", _), Z("layerboard-data-sources-loading", te), Z("layerboard-get-data-source", W), Z("layerboard-refetch-data-source", he);
1968
+ const ge = D(() => ({
1929
1969
  backgroundColor: o.themeColor
1930
- })), Ue = z(() => ({
1970
+ })), Ue = D(() => ({
1931
1971
  backgroundColor: o.themeColor
1932
- })), Je = z(() => ({
1972
+ })), Ke = D(() => ({
1933
1973
  backgroundColor: o.themeColor
1934
- })), lt = z(() => ({
1974
+ })), nt = D(() => ({
1935
1975
  width: de.value ? "0" : o.sidebarWidth
1936
1976
  }));
1937
1977
  async function De() {
1938
1978
  try {
1939
- c.value = !0, w.value = null;
1940
- const M = (await gt(o.webMapId)).map((W) => {
1941
- let Q = W;
1942
- const Ce = o.layerStyleOverrides[W.id];
1943
- Ce && (Q = {
1944
- ...Q,
1945
- paint: Ce.paint ?? Q.paint,
1946
- outlinePaint: Ce.outlinePaint ?? Q.outlinePaint,
1947
- legend: Ce.legend ?? Q.legend,
1948
- type: Ce.type ?? Q.type
1979
+ c.value = !0, b.value = null;
1980
+ const M = (await gt(o.webMapId)).map((j) => {
1981
+ let Y = j;
1982
+ const Ce = o.layerStyleOverrides[j.id];
1983
+ Ce && (Y = {
1984
+ ...Y,
1985
+ paint: Ce.paint ?? Y.paint,
1986
+ outlinePaint: Ce.outlinePaint ?? Y.outlinePaint,
1987
+ legend: Ce.legend ?? Y.legend,
1988
+ type: Ce.type ?? Y.type
1949
1989
  });
1950
- const Ve = o.popupOverrides[W.id];
1951
- return Ve && Q.popup && (Q = {
1952
- ...Q,
1953
- popup: { ...Q.popup, ...Ve }
1954
- }), Q;
1990
+ const Ze = o.popupOverrides[j.id];
1991
+ return Ze && Y.popup && (Y = {
1992
+ ...Y,
1993
+ popup: { ...Y.popup, ...Ze }
1994
+ }), Y;
1955
1995
  });
1956
- n.value = M.map((W) => ({
1957
- config: W,
1958
- component: W.type
1996
+ n.value = M.map((j) => ({
1997
+ config: j,
1998
+ component: j.type
1959
1999
  }));
1960
- const J = {};
1961
- M.forEach((W) => {
1962
- J[W.id] = W.opacity ?? 1;
1963
- }), g.value = J, r("configs-loaded", M);
1964
- } catch (y) {
1965
- const M = y instanceof Error ? y.message : "Failed to load layer configurations";
1966
- w.value = M, r("load-error", M);
2000
+ const K = {};
2001
+ M.forEach((j) => {
2002
+ K[j.id] = j.opacity ?? 1;
2003
+ }), g.value = K, r("configs-loaded", M);
2004
+ } catch (m) {
2005
+ const M = m instanceof Error ? m.message : "Failed to load layer configurations";
2006
+ b.value = M, r("load-error", M);
1967
2007
  } finally {
1968
2008
  c.value = !1;
1969
2009
  }
1970
2010
  }
1971
- async function nt() {
2011
+ async function rt() {
1972
2012
  if (o.fetchMetadata)
1973
2013
  try {
1974
- const y = "https://phl.carto.com/api/v2/sql?q=" + encodeURIComponent(
2014
+ const m = "https://phl.carto.com/api/v2/sql?q=" + encodeURIComponent(
1975
2015
  "select url_text, COALESCE(representation, '') as representation from phl.knack_metadata_reps_endpoints_join WHERE ( format = 'API' OR format = 'GeoService' ) AND url_text IS NOT null"
1976
- ), M = await fetch(y);
2016
+ ), M = await fetch(m);
1977
2017
  if (!M.ok) return;
1978
- const J = await M.json(), W = {};
1979
- for (const Q of J.rows || [])
1980
- if (Q.url_text && Q.representation) {
1981
- const Ce = Bt(Q.url_text), Ve = `https://metadata.phila.gov/#home/representationdetails/${Q.representation}/`;
1982
- W[Ce] = Ve;
2018
+ const K = await M.json(), j = {};
2019
+ for (const Y of K.rows || [])
2020
+ if (Y.url_text && Y.representation) {
2021
+ const Ce = Bt(Y.url_text), Ze = `https://metadata.phila.gov/#home/representationdetails/${Y.representation}/`;
2022
+ j[Ce] = Ze;
1983
2023
  }
1984
- f.value = W;
2024
+ u.value = j;
1985
2025
  } catch {
1986
2026
  }
1987
2027
  }
1988
- function rt(y) {
1989
- p.value = y, r("zoom", y);
2028
+ function st(m) {
2029
+ p.value = m, r("zoom", m);
1990
2030
  }
1991
- function _e(y) {
1992
- h.value.has(y) ? h.value.delete(y) : h.value.add(y), h.value = new Set(h.value);
2031
+ function _e(m) {
2032
+ y.value.has(m) ? y.value.delete(m) : y.value.add(m), y.value = new Set(y.value);
1993
2033
  }
1994
- function Me(y, M) {
1995
- M ? h.value.add(y) : h.value.delete(y), h.value = new Set(h.value);
2034
+ function Me(m, M) {
2035
+ M ? y.value.add(m) : y.value.delete(m), y.value = new Set(y.value);
1996
2036
  }
1997
- function Re(y, M) {
1998
- for (const J of y)
1999
- M ? h.value.add(J) : h.value.delete(J);
2000
- h.value = new Set(h.value);
2037
+ function Re(m, M) {
2038
+ for (const K of m)
2039
+ M ? y.value.add(K) : y.value.delete(K);
2040
+ y.value = new Set(y.value);
2001
2041
  }
2002
- function Pe(y, M) {
2003
- g.value = { ...g.value, [y]: M };
2042
+ function Pe(m, M) {
2043
+ g.value = { ...g.value, [m]: M };
2004
2044
  }
2005
- function st(y, M) {
2006
- M ? a.value.add(y) : a.value.delete(y), a.value = new Set(a.value);
2045
+ function ct(m, M) {
2046
+ M ? a.value.add(m) : a.value.delete(m), a.value = new Set(a.value);
2007
2047
  }
2008
- function se(y, M) {
2048
+ function se(m, M) {
2009
2049
  if (M)
2010
- v.value = { ...v.value, [y]: M };
2050
+ v.value = { ...v.value, [m]: M };
2011
2051
  else {
2012
- const J = { ...v.value };
2013
- delete J[y], v.value = J;
2052
+ const K = { ...v.value };
2053
+ delete K[m], v.value = K;
2014
2054
  }
2015
2055
  }
2016
- function Ae(y) {
2017
- x.value = y;
2056
+ function Ae(m) {
2057
+ C.value = m;
2018
2058
  }
2019
- const ae = k(null), Fe = k(null), ct = k(null), we = k(null), We = k(null), je = k(null), Ke = k(null), Le = k("map");
2059
+ const ae = x(null), Te = x(null), ut = x(null), we = x(null), We = x(null), je = x(null), Qe = x(null), Le = x("sidebar");
2020
2060
  function Be() {
2021
2061
  Le.value = Le.value === "sidebar" ? "map" : "sidebar", Ne(() => {
2022
2062
  Le.value === "sidebar" && ae.value?.focus();
2023
2063
  });
2024
2064
  }
2025
- const ie = k(!1);
2026
- function Qe() {
2065
+ const ie = x(!1);
2066
+ function Xe() {
2027
2067
  ie.value = !ie.value, ie.value && Ne(() => {
2028
2068
  we.value?.focus();
2029
2069
  });
2030
2070
  }
2031
2071
  function Ee() {
2032
2072
  ie.value = !1, Ne(() => {
2033
- Fe.value?.focus();
2073
+ Te.value?.focus();
2034
2074
  });
2035
2075
  }
2036
- const de = k(!1);
2076
+ const de = x(!1);
2037
2077
  function Oe() {
2038
2078
  de.value = !de.value;
2039
2079
  }
2040
- const ge = k(!1), qe = k(null);
2080
+ const ve = x(!1), qe = x(null);
2041
2081
  function Se() {
2042
- qe.value = document.activeElement, ge.value = !0, Ne(() => {
2043
- Ke.value?.focus();
2082
+ qe.value = document.activeElement, ve.value = !0, Ne(() => {
2083
+ Qe.value?.focus();
2044
2084
  });
2045
2085
  }
2046
2086
  function le() {
2047
- ge.value = !1, Ne(() => {
2087
+ ve.value = !1, Ne(() => {
2048
2088
  qe.value?.focus(), qe.value = null;
2049
2089
  });
2050
2090
  }
2051
- function Ze(y) {
2052
- y.target.classList.contains("layerboard-modal-backdrop") && le();
2091
+ function Ve(m) {
2092
+ m.target.classList.contains("layerboard-modal-backdrop") && le();
2053
2093
  }
2054
- function ut(y) {
2055
- if (y.key === "Escape") {
2094
+ function dt(m) {
2095
+ if (m.key === "Escape") {
2056
2096
  Ee();
2057
2097
  return;
2058
2098
  }
2059
- if (y.key === "Tab" && We.value) {
2099
+ if (m.key === "Tab" && We.value) {
2060
2100
  const M = Array.from(
2061
2101
  We.value.querySelectorAll(
2062
2102
  'a[href], button:not([disabled]), textarea, input:not([disabled]), select:not([disabled]), [tabindex]:not([tabindex="-1"])'
2063
2103
  )
2064
2104
  );
2065
2105
  if (M.length === 0) return;
2066
- const J = M[0], W = M[M.length - 1];
2067
- y.shiftKey ? document.activeElement === J && (y.preventDefault(), W.focus()) : document.activeElement === W && (y.preventDefault(), J.focus());
2106
+ const K = M[0], j = M[M.length - 1];
2107
+ m.shiftKey ? document.activeElement === K && (m.preventDefault(), j.focus()) : document.activeElement === j && (m.preventDefault(), K.focus());
2068
2108
  }
2069
2109
  }
2070
- function dt(y) {
2071
- if (y.key === "Escape") {
2110
+ function ft(m) {
2111
+ if (m.key === "Escape") {
2072
2112
  le();
2073
2113
  return;
2074
2114
  }
2075
- if (y.key === "Tab" && je.value) {
2115
+ if (m.key === "Tab" && je.value) {
2076
2116
  const M = Array.from(
2077
2117
  je.value.querySelectorAll(
2078
2118
  'a[href], button:not([disabled]), textarea, input:not([disabled]), select:not([disabled]), [tabindex]:not([tabindex="-1"])'
2079
2119
  )
2080
2120
  );
2081
2121
  if (M.length === 0) return;
2082
- const J = M[0], W = M[M.length - 1];
2083
- y.shiftKey ? document.activeElement === J && (y.preventDefault(), W.focus()) : document.activeElement === W && (y.preventDefault(), J.focus());
2122
+ const K = M[0], j = M[M.length - 1];
2123
+ m.shiftKey ? document.activeElement === K && (m.preventDefault(), j.focus()) : document.activeElement === j && (m.preventDefault(), K.focus());
2084
2124
  }
2085
2125
  }
2086
- Z("layerboard-open-modal", Se), Z("layerboard-close-modal", le), Z("layerboard-is-modal-open", j(ge)), i({
2126
+ Z("layerboard-open-modal", Se), Z("layerboard-close-modal", le), Z("layerboard-is-modal-open", q(ve)), i({
2087
2127
  /** Layer configurations */
2088
2128
  layerList: n,
2089
2129
  /** Set of visible layer IDs */
2090
- visibleLayers: h,
2130
+ visibleLayers: y,
2091
2131
  /** Layer opacity values */
2092
2132
  layerOpacities: g,
2093
2133
  /** Set of currently loading layer IDs */
@@ -2107,16 +2147,16 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2107
2147
  /** Reload layer configurations */
2108
2148
  reloadConfigs: De,
2109
2149
  /** Clear configuration cache */
2110
- clearCache: () => ca(o.webMapId),
2150
+ clearCache: () => ua(o.webMapId),
2111
2151
  // Tiled layer APIs
2112
2152
  /** Set of visible tiled layer IDs */
2113
- visibleTiledLayers: L,
2153
+ visibleTiledLayers: w,
2114
2154
  /** Tiled layer opacity values */
2115
- tiledLayerOpacities: S,
2155
+ tiledLayerOpacities: L,
2116
2156
  /** Toggle a tiled layer's visibility */
2117
- toggleTiledLayer: D,
2157
+ toggleTiledLayer: E,
2118
2158
  /** Set a tiled layer's visibility explicitly */
2119
- setTiledLayerVisible: X,
2159
+ setTiledLayerVisible: V,
2120
2160
  /** Set a tiled layer's opacity */
2121
2161
  setTiledLayerOpacity: T,
2122
2162
  // Data source APIs
@@ -2125,32 +2165,32 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2125
2165
  /** Whether any data source is loading */
2126
2166
  dataSourcesLoading: te,
2127
2167
  /** Get data from a specific data source */
2128
- getDataSourceData: U,
2168
+ getDataSourceData: W,
2129
2169
  /** Refetch a specific data source */
2130
- refetchDataSource: me,
2170
+ refetchDataSource: he,
2131
2171
  // Modal APIs
2132
2172
  /** Whether the modal is currently open */
2133
- isModalOpen: ge,
2173
+ isModalOpen: ve,
2134
2174
  /** Open the modal */
2135
2175
  openModal: Se,
2136
2176
  /** Close the modal */
2137
2177
  closeModal: le
2138
2178
  });
2139
- function Xe(y) {
2140
- y.key === "Escape" && ie.value && Ee();
2179
+ function Ye(m) {
2180
+ m.key === "Escape" && ie.value && Ee();
2141
2181
  }
2142
- return et(() => {
2143
- De(), nt(), E(), document.addEventListener("keydown", Xe);
2182
+ return ot(() => {
2183
+ De(), rt(), F(), document.addEventListener("keydown", Ye);
2144
2184
  }), Kt(() => {
2145
- document.removeEventListener("keydown", Xe);
2146
- }), (y, M) => (m(), $("div", ya, [
2185
+ document.removeEventListener("keydown", Ye);
2186
+ }), (m, M) => (h(), $("div", ma, [
2147
2187
  M[5] || (M[5] = P("a", {
2148
2188
  href: "#main-content",
2149
2189
  class: "skip-to-main-content-link"
2150
2190
  }, "Skip to main content", -1)),
2151
2191
  P("header", {
2152
2192
  class: "layerboard-header",
2153
- style: fe(he.value)
2193
+ style: fe(ge.value)
2154
2194
  }, [
2155
2195
  M[1] || (M[1] = P("a", {
2156
2196
  href: "https://www.phila.gov/",
@@ -2167,24 +2207,24 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2167
2207
  }, null, -1)),
2168
2208
  P("button", {
2169
2209
  ref_key: "hamburgerRef",
2170
- ref: Fe,
2210
+ ref: Te,
2171
2211
  class: "layerboard-hamburger layerboard-mobile-only",
2172
2212
  "aria-expanded": ie.value,
2173
2213
  "aria-label": "Toggle menu",
2174
- onClick: Qe
2214
+ onClick: Xe
2175
2215
  }, [
2176
- H(d(ke), {
2177
- "icon-definition": d(xo),
2216
+ J(f(ke), {
2217
+ "icon-definition": f(xo),
2178
2218
  size: "medium",
2179
2219
  inline: "",
2180
2220
  decorative: ""
2181
2221
  }, null, 8, ["icon-definition"])
2182
- ], 8, ma),
2183
- pe(y.$slots, "header", {}, () => [
2184
- P("h1", null, G(e.title), 1),
2185
- e.subtitle ? (m(), $("span", ha, G(e.subtitle), 1)) : R("", !0)
2222
+ ], 8, ha),
2223
+ pe(m.$slots, "header", {}, () => [
2224
+ P("h1", null, H(e.title), 1),
2225
+ e.subtitle ? (h(), $("span", ga, H(e.subtitle), 1)) : R("", !0)
2186
2226
  ], !0),
2187
- ie.value ? (m(), $("div", {
2227
+ ie.value ? (h(), $("div", {
2188
2228
  key: 0,
2189
2229
  ref_key: "mobileMenuRef",
2190
2230
  ref: We,
@@ -2193,13 +2233,13 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2193
2233
  "aria-modal": "true",
2194
2234
  "aria-label": "Site menu",
2195
2235
  style: fe({ backgroundColor: e.themeColor }),
2196
- onKeydown: ut
2236
+ onKeydown: dt
2197
2237
  }, [
2198
- P("div", ga, [
2199
- pe(y.$slots, "footer", {
2238
+ P("div", va, [
2239
+ pe(m.$slots, "footer", {
2200
2240
  openModal: Se,
2201
2241
  closeModal: le,
2202
- isModalOpen: ge.value
2242
+ isModalOpen: ve.value
2203
2243
  }, () => [
2204
2244
  M[0] || (M[0] = xe(" City of Philadelphia ", -1))
2205
2245
  ], !0)
@@ -2211,47 +2251,47 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2211
2251
  "aria-label": "Close menu",
2212
2252
  onClick: Ee
2213
2253
  }, [
2214
- H(d(ke), {
2215
- "icon-definition": d(Ot),
2254
+ J(f(ke), {
2255
+ "icon-definition": f(Ot),
2216
2256
  size: "medium",
2217
2257
  decorative: ""
2218
2258
  }, null, 8, ["icon-definition"])
2219
2259
  ], 512)
2220
2260
  ], 36)) : R("", !0),
2221
- ie.value ? (m(), $("div", {
2261
+ ie.value ? (h(), $("div", {
2222
2262
  key: 1,
2223
2263
  class: "layerboard-mobile-menu-backdrop",
2224
2264
  onClick: Ee
2225
2265
  })) : R("", !0)
2226
2266
  ], 4),
2227
- P("div", va, [
2228
- c.value ? (m(), $("div", ba, [
2267
+ P("div", ba, [
2268
+ c.value ? (h(), $("div", wa, [
2229
2269
  P("div", {
2230
2270
  class: "layerboard-spinner",
2231
2271
  style: fe({ borderTopColor: e.themeColor })
2232
2272
  }, null, 4),
2233
- P("p", null, "Loading " + G(e.title) + "...", 1)
2234
- ])) : w.value ? (m(), $("div", wa, [
2273
+ P("p", null, "Loading " + H(e.title) + "...", 1)
2274
+ ])) : b.value ? (h(), $("div", La, [
2235
2275
  M[3] || (M[3] = P("h2", null, "Error Loading Layers", -1)),
2236
- P("p", null, G(w.value), 1),
2276
+ P("p", null, H(b.value), 1),
2237
2277
  P("button", {
2238
2278
  class: "layerboard-retry-button",
2239
2279
  style: fe({ backgroundColor: e.themeColor }),
2240
2280
  onClick: De
2241
2281
  }, " Retry ", 4)
2242
- ])) : (m(), $(ue, { key: 2 }, [
2282
+ ])) : (h(), $(ue, { key: 2 }, [
2243
2283
  P("aside", {
2244
2284
  id: "main-content",
2245
2285
  ref_key: "sidebarRef",
2246
2286
  ref: ae,
2247
2287
  class: re(["layerboard-sidebar", { "is-active": Le.value === "sidebar" }]),
2248
- style: fe(lt.value),
2288
+ style: fe(nt.value),
2249
2289
  "aria-label": "Map layers",
2250
2290
  tabindex: "-1"
2251
2291
  }, [
2252
- pe(y.$slots, "sidebar", {
2292
+ pe(m.$slots, "sidebar", {
2253
2293
  layers: n.value,
2254
- visibleLayers: h.value,
2294
+ visibleLayers: y.value,
2255
2295
  layerOpacities: g.value,
2256
2296
  loadingLayers: a.value,
2257
2297
  layerErrors: v.value,
@@ -2261,26 +2301,26 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2261
2301
  setLayersVisible: Re,
2262
2302
  setOpacity: Pe,
2263
2303
  tiledLayers: e.tiledLayers,
2264
- visibleTiledLayers: L.value,
2265
- tiledLayerOpacities: S.value,
2266
- toggleTiledLayer: D,
2267
- setTiledLayerVisible: X,
2304
+ visibleTiledLayers: w.value,
2305
+ tiledLayerOpacities: L.value,
2306
+ toggleTiledLayer: E,
2307
+ setTiledLayerVisible: V,
2268
2308
  setTiledLayerOpacity: T,
2269
2309
  dataSourcesState: _.value,
2270
2310
  dataSourcesLoading: te.value,
2271
- getDataSource: U,
2272
- refetchDataSource: me
2311
+ getDataSource: W,
2312
+ refetchDataSource: he
2273
2313
  }, () => [
2274
- e.showDefaultSidebar ? (m(), q(Ho, {
2314
+ e.showDefaultSidebar ? (h(), G(Ho, {
2275
2315
  key: 0,
2276
2316
  "layer-list": n.value,
2277
- "visible-layers": h.value,
2317
+ "visible-layers": y.value,
2278
2318
  "layer-opacities": g.value,
2279
2319
  "loading-layers": a.value,
2280
2320
  "layer-errors": v.value,
2281
2321
  "current-zoom": p.value,
2282
- "search-query": x.value,
2283
- "layer-metadata": f.value,
2322
+ "search-query": C.value,
2323
+ "layer-metadata": u.value,
2284
2324
  onToggleLayer: _e,
2285
2325
  onSetOpacity: Pe,
2286
2326
  onUpdateSearch: Ae
@@ -2292,13 +2332,13 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2292
2332
  "aria-label": "Map",
2293
2333
  class: re(["layerboard-map", { "is-active": Le.value === "map" }])
2294
2334
  }, [
2295
- H(no, {
2296
- "visible-layers": h.value,
2335
+ J(no, {
2336
+ "visible-layers": y.value,
2297
2337
  "layer-opacities": g.value,
2298
2338
  "layer-list": n.value,
2299
2339
  "tiled-layers": e.tiledLayers,
2300
- "visible-tiled-layers": L.value,
2301
- "tiled-layer-opacities": S.value,
2340
+ "visible-tiled-layers": w.value,
2341
+ "tiled-layer-opacities": L.value,
2302
2342
  "cyclomedia-config": e.cyclomediaConfig,
2303
2343
  "pictometry-credentials": e.pictometryCredentials,
2304
2344
  "basemap-control-position": e.basemapControlPosition,
@@ -2310,8 +2350,8 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2310
2350
  "pictometry-button-position": e.pictometryButtonPosition,
2311
2351
  "initial-zoom": e.initialZoom,
2312
2352
  "initial-center": e.initialCenter,
2313
- onZoom: rt,
2314
- onLayerLoading: st,
2353
+ onZoom: st,
2354
+ onLayerLoading: ct,
2315
2355
  onLayerError: se
2316
2356
  }, null, 8, ["visible-layers", "layer-opacities", "layer-list", "tiled-layers", "visible-tiled-layers", "tiled-layer-opacities", "cyclomedia-config", "pictometry-credentials", "basemap-control-position", "navigation-control-position", "geolocation-control-position", "search-control-position", "draw-control-position", "cyclomedia-button-position", "pictometry-button-position", "initial-zoom", "initial-center"])
2317
2357
  ], 2),
@@ -2322,40 +2362,40 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2322
2362
  "aria-label": de.value ? "Expand sidebar" : "Collapse sidebar",
2323
2363
  onClick: Oe
2324
2364
  }, [
2325
- H(d(ke), {
2326
- "icon-definition": de.value ? d(Co) : d(ko),
2365
+ J(f(ke), {
2366
+ "icon-definition": de.value ? f(Co) : f(ko),
2327
2367
  size: "medium",
2328
2368
  decorative: ""
2329
2369
  }, null, 8, ["icon-definition"])
2330
- ], 14, La)
2370
+ ], 14, Sa)
2331
2371
  ], 64))
2332
2372
  ]),
2333
2373
  P("button", {
2334
2374
  ref_key: "mobileToggleRef",
2335
- ref: ct,
2375
+ ref: ut,
2336
2376
  class: "layerboard-mobile-toggle",
2337
- style: fe(Je.value),
2377
+ style: fe(Ke.value),
2338
2378
  onClick: Be
2339
2379
  }, [
2340
- Le.value === "map" ? (m(), $("span", Sa, G(e.sidebarLabel), 1)) : (m(), $("span", Ca, G(e.mapLabel), 1))
2380
+ Le.value === "map" ? (h(), $("span", Ca, H(e.sidebarLabel), 1)) : (h(), $("span", ka, H(e.mapLabel), 1))
2341
2381
  ], 4),
2342
2382
  P("footer", {
2343
2383
  class: "layerboard-footer",
2344
2384
  style: fe(Ue.value)
2345
2385
  }, [
2346
- pe(y.$slots, "footer", {
2386
+ pe(m.$slots, "footer", {
2347
2387
  openModal: Se,
2348
2388
  closeModal: le,
2349
- isModalOpen: ge.value
2389
+ isModalOpen: ve.value
2350
2390
  }, () => [
2351
2391
  M[4] || (M[4] = xe(" City of Philadelphia ", -1))
2352
2392
  ], !0)
2353
2393
  ], 4),
2354
- ge.value ? (m(), $("div", {
2394
+ ve.value ? (h(), $("div", {
2355
2395
  key: 0,
2356
2396
  class: "layerboard-modal-backdrop",
2357
- onClick: Ze,
2358
- onKeydown: dt
2397
+ onClick: Ve,
2398
+ onKeydown: ft
2359
2399
  }, [
2360
2400
  P("div", {
2361
2401
  ref_key: "modalRef",
@@ -2367,27 +2407,27 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2367
2407
  }, [
2368
2408
  P("button", {
2369
2409
  ref_key: "modalCloseRef",
2370
- ref: Ke,
2410
+ ref: Qe,
2371
2411
  class: "layerboard-modal-close",
2372
2412
  "aria-label": "Close modal",
2373
2413
  onClick: le
2374
2414
  }, [
2375
- H(d(ke), {
2376
- "icon-definition": d(Ot),
2415
+ J(f(ke), {
2416
+ "icon-definition": f(Ot),
2377
2417
  size: "medium",
2378
2418
  decorative: ""
2379
2419
  }, null, 8, ["icon-definition"])
2380
2420
  ], 512),
2381
- pe(y.$slots, "modal", { closeModal: le }, void 0, !0)
2421
+ pe(m.$slots, "modal", { closeModal: le }, void 0, !0)
2382
2422
  ], 512)
2383
2423
  ], 32)) : R("", !0),
2384
- P("span", ka, G(Le.value === "sidebar" ? "Showing layers panel" : "Showing map"), 1)
2424
+ P("span", xa, H(Le.value === "sidebar" ? "Showing layers panel" : "Showing map"), 1)
2385
2425
  ]));
2386
2426
  }
2387
- }), Ha = /* @__PURE__ */ $e(xa, [["__scopeId", "data-v-67021805"]]), $a = ["aria-expanded"], Ma = {
2427
+ }), Ja = /* @__PURE__ */ $e($a, [["__scopeId", "data-v-0a7b6d44"]]), Ma = ["aria-expanded"], Pa = {
2388
2428
  key: 0,
2389
2429
  class: "topic-icon"
2390
- }, Pa = { class: "topic-title" }, Ta = /* @__PURE__ */ ye({
2430
+ }, Fa = { class: "topic-title" }, Ta = /* @__PURE__ */ me({
2391
2431
  __name: "TopicAccordion",
2392
2432
  props: {
2393
2433
  title: {},
@@ -2398,19 +2438,19 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2398
2438
  },
2399
2439
  emits: ["toggle", "layerChange"],
2400
2440
  setup(e, { emit: i }) {
2401
- const l = e, o = i, r = k(l.expanded), n = `topic-panel-${Mt()}`, c = `topic-header-${Mt()}`;
2441
+ const l = e, o = i, r = x(l.expanded), n = `topic-panel-${Mt()}`, c = `topic-header-${Mt()}`;
2402
2442
  Ie(
2403
2443
  () => l.expanded,
2404
2444
  (p) => {
2405
2445
  r.value = p;
2406
2446
  }
2407
2447
  );
2408
- function w() {
2448
+ function b() {
2409
2449
  r.value = !r.value, o("toggle", r.value);
2410
2450
  }
2411
- return (p, x) => {
2412
- const h = Qt("font-awesome-icon");
2413
- return m(), $("div", {
2451
+ return (p, C) => {
2452
+ const y = Qt("font-awesome-icon");
2453
+ return h(), $("div", {
2414
2454
  class: re(["topic-accordion", { "is-expanded": r.value }])
2415
2455
  }, [
2416
2456
  P("button", {
@@ -2419,21 +2459,21 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2419
2459
  type: "button",
2420
2460
  "aria-expanded": r.value,
2421
2461
  "aria-controls": n,
2422
- onClick: w
2462
+ onClick: b
2423
2463
  }, [
2424
- e.icon || p.$slots.icon ? (m(), $("span", Ma, [
2464
+ e.icon || p.$slots.icon ? (h(), $("span", Pa, [
2425
2465
  pe(p.$slots, "icon", {}, () => [
2426
- e.icon ? (m(), q(h, {
2466
+ e.icon ? (h(), G(y, {
2427
2467
  key: 0,
2428
2468
  icon: ["fas", e.icon],
2429
2469
  "aria-hidden": "true"
2430
2470
  }, null, 8, ["icon"])) : R("", !0)
2431
2471
  ], !0)
2432
2472
  ])) : R("", !0),
2433
- P("span", Pa, G(e.title), 1),
2473
+ P("span", Fa, H(e.title), 1),
2434
2474
  P("span", {
2435
2475
  class: re(["topic-chevron", { "is-rotated": r.value }])
2436
- }, [...x[0] || (x[0] = [
2476
+ }, [...C[0] || (C[0] = [
2437
2477
  P("svg", {
2438
2478
  xmlns: "http://www.w3.org/2000/svg",
2439
2479
  width: "20",
@@ -2449,7 +2489,7 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2449
2489
  P("polyline", { points: "6 9 12 15 18 9" })
2450
2490
  ], -1)
2451
2491
  ])], 2)
2452
- ], 10, $a),
2492
+ ], 10, Ma),
2453
2493
  At(P("div", {
2454
2494
  id: n,
2455
2495
  role: "region",
@@ -2457,7 +2497,7 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2457
2497
  class: "topic-content"
2458
2498
  }, [
2459
2499
  pe(p.$slots, "default", {}, () => [
2460
- x[1] || (x[1] = P("p", { class: "topic-empty" }, "No content provided for this topic.", -1))
2500
+ C[1] || (C[1] = P("p", { class: "topic-empty" }, "No content provided for this topic.", -1))
2461
2501
  ], !0)
2462
2502
  ], 512), [
2463
2503
  [Xt, r.value]
@@ -2465,8 +2505,8 @@ const ya = { class: "layerboard-layout" }, ma = ["aria-expanded"], ha = {
2465
2505
  ], 2);
2466
2506
  };
2467
2507
  }
2468
- }), Ja = /* @__PURE__ */ $e(Ta, [["__scopeId", "data-v-a2023afa"]]);
2469
- function Fa(e) {
2508
+ }), Ka = /* @__PURE__ */ $e(Ta, [["__scopeId", "data-v-a2023afa"]]);
2509
+ function Ea(e) {
2470
2510
  return e.displayOptions?.shouldShowCheckbox !== !1;
2471
2511
  }
2472
2512
  function Nt(e, i) {
@@ -2478,10 +2518,10 @@ function Ut(e, i) {
2478
2518
  function ze(e) {
2479
2519
  return e.displayOptions?.layerNameChange || e.title;
2480
2520
  }
2481
- const Ea = ["aria-label"], Oa = ["checked", "disabled", "onChange"], Ia = { class: "layer-title" }, za = { class: "layer-title" }, Da = {
2521
+ const Oa = ["aria-label"], Ia = ["checked", "disabled", "onChange"], za = { class: "layer-title" }, Da = { class: "layer-title" }, _a = {
2482
2522
  key: 0,
2483
2523
  class: "empty-state"
2484
- }, _a = /* @__PURE__ */ ye({
2524
+ }, Ra = /* @__PURE__ */ me({
2485
2525
  __name: "LayerCheckboxSet",
2486
2526
  props: {
2487
2527
  layers: {},
@@ -2496,78 +2536,78 @@ const Ea = ["aria-label"], Oa = ["checked", "disabled", "onChange"], Ia = { clas
2496
2536
  },
2497
2537
  emits: ["toggleLayer", "setOpacity"],
2498
2538
  setup(e, { emit: i }) {
2499
- const l = e, o = i, { isVisible: r, getLayerOpacity: n, isLayerLoading: c, getLayerError: w, isLayerAvailableAtZoom: p } = wt(
2539
+ const l = e, o = i, { isVisible: r, getLayerOpacity: n, isLayerLoading: c, getLayerError: b, isLayerAvailableAtZoom: p } = wt(
2500
2540
  () => l
2501
2541
  );
2502
- function x(h) {
2503
- o("toggleLayer", h);
2542
+ function C(y) {
2543
+ o("toggleLayer", y);
2504
2544
  }
2505
- return (h, g) => (m(), $("fieldset", {
2545
+ return (y, g) => (h(), $("fieldset", {
2506
2546
  class: "layer-checkbox-set",
2507
2547
  role: "group",
2508
2548
  "aria-label": e.groupLabel
2509
2549
  }, [
2510
- (m(!0), $(ue, null, ve(e.layers, (a) => (m(), $("div", {
2550
+ (h(!0), $(ue, null, be(e.layers, (a) => (h(), $("div", {
2511
2551
  key: a.id,
2512
2552
  class: "layer-item"
2513
2553
  }, [
2514
- d(Fa)(a) ? (m(), $("label", {
2554
+ f(Ea)(a) ? (h(), $("label", {
2515
2555
  key: 0,
2516
2556
  class: re(["layer-checkbox", {
2517
- "layer-unavailable": !d(p)(a),
2518
- "layer-error": d(w)(a.id)
2557
+ "layer-unavailable": !f(p)(a),
2558
+ "layer-error": f(b)(a.id)
2519
2559
  }])
2520
2560
  }, [
2521
2561
  P("input", {
2522
2562
  type: "checkbox",
2523
- checked: d(r)(a.id),
2524
- disabled: !d(p)(a),
2525
- onChange: (v) => x(a.id)
2526
- }, null, 40, Oa),
2527
- P("span", Ia, [
2528
- xe(G(d(ze)(a)) + " ", 1),
2529
- H(tt, {
2530
- loading: d(c)(a.id),
2531
- error: d(w)(a.id),
2532
- unavailable: !d(p)(a)
2563
+ checked: f(r)(a.id),
2564
+ disabled: !f(p)(a),
2565
+ onChange: (v) => C(a.id)
2566
+ }, null, 40, Ia),
2567
+ P("span", za, [
2568
+ xe(H(f(ze)(a)) + " ", 1),
2569
+ J(at, {
2570
+ loading: f(c)(a.id),
2571
+ error: f(b)(a.id),
2572
+ unavailable: !f(p)(a)
2533
2573
  }, null, 8, ["loading", "error", "unavailable"])
2534
2574
  ])
2535
- ], 2)) : (m(), $("div", {
2575
+ ], 2)) : (h(), $("div", {
2536
2576
  key: 1,
2537
2577
  class: re(["layer-label-only", {
2538
- "layer-unavailable": !d(p)(a),
2539
- "layer-error": d(w)(a.id)
2578
+ "layer-unavailable": !f(p)(a),
2579
+ "layer-error": f(b)(a.id)
2540
2580
  }])
2541
2581
  }, [
2542
- P("span", za, [
2543
- xe(G(d(ze)(a)) + " ", 1),
2544
- H(tt, {
2545
- loading: d(c)(a.id),
2546
- error: d(w)(a.id),
2547
- unavailable: !d(p)(a)
2582
+ P("span", Da, [
2583
+ xe(H(f(ze)(a)) + " ", 1),
2584
+ J(at, {
2585
+ loading: f(c)(a.id),
2586
+ error: f(b)(a.id),
2587
+ unavailable: !f(p)(a)
2548
2588
  }, null, 8, ["loading", "error", "unavailable"])
2549
2589
  ])
2550
2590
  ], 2)),
2551
- d(Nt)(a, e.showOpacity) && d(r)(a.id) && d(p)(a) ? (m(), q(vt, {
2591
+ f(Nt)(a, e.showOpacity) && f(r)(a.id) && f(p)(a) ? (h(), G(vt, {
2552
2592
  key: 2,
2553
2593
  "layer-id": a.id,
2554
- "layer-name": d(ze)(a),
2555
- opacity: d(n)(a.id),
2594
+ "layer-name": f(ze)(a),
2595
+ opacity: f(n)(a.id),
2556
2596
  "onUpdate:opacity": (v) => o("setOpacity", a.id, v)
2557
2597
  }, null, 8, ["layer-id", "layer-name", "opacity", "onUpdate:opacity"])) : R("", !0),
2558
- d(Ut)(a, e.showLegend) && d(r)(a.id) && d(p)(a) && a.legend?.length ? (m(), q(bt, {
2598
+ f(Ut)(a, e.showLegend) && f(r)(a.id) && f(p)(a) && a.legend?.length ? (h(), G(bt, {
2559
2599
  key: 3,
2560
2600
  items: a.legend,
2561
- label: "Legend for " + d(ze)(a)
2601
+ label: "Legend for " + f(ze)(a)
2562
2602
  }, null, 8, ["items", "label"])) : R("", !0)
2563
2603
  ]))), 128)),
2564
- e.layers.length === 0 ? (m(), $("div", Da, "No layers available")) : R("", !0)
2565
- ], 8, Ea));
2604
+ e.layers.length === 0 ? (h(), $("div", _a, "No layers available")) : R("", !0)
2605
+ ], 8, Oa));
2566
2606
  }
2567
- }), Ka = /* @__PURE__ */ $e(_a, [["__scopeId", "data-v-bfcd7855"]]), Ra = ["aria-label"], Aa = ["name", "checked", "disabled", "onChange"], Ba = { class: "layer-title" }, Za = {
2607
+ }), Qa = /* @__PURE__ */ $e(Ra, [["__scopeId", "data-v-bfcd7855"]]), Aa = ["aria-label"], Ba = ["name", "checked", "disabled", "onChange"], Va = { class: "layer-title" }, Za = {
2568
2608
  key: 0,
2569
2609
  class: "empty-state"
2570
- }, Va = /* @__PURE__ */ ye({
2610
+ }, Na = /* @__PURE__ */ me({
2571
2611
  __name: "LayerRadioButtonSet",
2572
2612
  props: {
2573
2613
  layers: {},
@@ -2583,152 +2623,152 @@ const Ea = ["aria-label"], Oa = ["checked", "disabled", "onChange"], Ia = { clas
2583
2623
  },
2584
2624
  emits: ["selectLayer", "setOpacity"],
2585
2625
  setup(e, { emit: i }) {
2586
- const l = e, o = i, { isVisible: r, getLayerOpacity: n, isLayerLoading: c, getLayerError: w, isLayerAvailableAtZoom: p } = wt(
2626
+ const l = e, o = i, { isVisible: r, getLayerOpacity: n, isLayerLoading: c, getLayerError: b, isLayerAvailableAtZoom: p } = wt(
2587
2627
  () => l
2588
2628
  );
2589
- function x(h) {
2590
- const g = l.layers.filter((a) => l.visibleLayerIds.has(a.id) && a.id !== h).map((a) => a.id);
2591
- o("selectLayer", h, g);
2629
+ function C(y) {
2630
+ const g = l.layers.filter((a) => l.visibleLayerIds.has(a.id) && a.id !== y).map((a) => a.id);
2631
+ o("selectLayer", y, g);
2592
2632
  }
2593
- return (h, g) => (m(), $("div", {
2633
+ return (y, g) => (h(), $("div", {
2594
2634
  class: "layer-radio-set",
2595
2635
  role: "radiogroup",
2596
2636
  "aria-label": e.groupLabel
2597
2637
  }, [
2598
- (m(!0), $(ue, null, ve(e.layers, (a) => (m(), $("div", {
2638
+ (h(!0), $(ue, null, be(e.layers, (a) => (h(), $("div", {
2599
2639
  key: a.id,
2600
2640
  class: "layer-item"
2601
2641
  }, [
2602
2642
  P("label", {
2603
2643
  class: re(["layer-radio", {
2604
- "layer-unavailable": !d(p)(a),
2605
- "layer-error": d(w)(a.id)
2644
+ "layer-unavailable": !f(p)(a),
2645
+ "layer-error": f(b)(a.id)
2606
2646
  }])
2607
2647
  }, [
2608
2648
  P("input", {
2609
2649
  type: "radio",
2610
2650
  name: e.groupName,
2611
- checked: d(r)(a.id),
2612
- disabled: !d(p)(a),
2613
- onChange: (v) => x(a.id)
2614
- }, null, 40, Aa),
2615
- P("span", Ba, [
2616
- xe(G(d(ze)(a)) + " ", 1),
2617
- H(tt, {
2618
- loading: d(c)(a.id),
2619
- error: d(w)(a.id),
2620
- unavailable: !d(p)(a)
2651
+ checked: f(r)(a.id),
2652
+ disabled: !f(p)(a),
2653
+ onChange: (v) => C(a.id)
2654
+ }, null, 40, Ba),
2655
+ P("span", Va, [
2656
+ xe(H(f(ze)(a)) + " ", 1),
2657
+ J(at, {
2658
+ loading: f(c)(a.id),
2659
+ error: f(b)(a.id),
2660
+ unavailable: !f(p)(a)
2621
2661
  }, null, 8, ["loading", "error", "unavailable"])
2622
2662
  ])
2623
2663
  ], 2),
2624
- d(Nt)(a, e.showOpacity) && d(r)(a.id) && d(p)(a) ? (m(), q(vt, {
2664
+ f(Nt)(a, e.showOpacity) && f(r)(a.id) && f(p)(a) ? (h(), G(vt, {
2625
2665
  key: 0,
2626
2666
  "layer-id": a.id,
2627
- "layer-name": d(ze)(a),
2628
- opacity: d(n)(a.id),
2667
+ "layer-name": f(ze)(a),
2668
+ opacity: f(n)(a.id),
2629
2669
  "onUpdate:opacity": (v) => o("setOpacity", a.id, v)
2630
2670
  }, null, 8, ["layer-id", "layer-name", "opacity", "onUpdate:opacity"])) : R("", !0),
2631
- d(Ut)(a, e.showLegend) && d(r)(a.id) && d(p)(a) && a.legend?.length ? (m(), q(bt, {
2671
+ f(Ut)(a, e.showLegend) && f(r)(a.id) && f(p)(a) && a.legend?.length ? (h(), G(bt, {
2632
2672
  key: 1,
2633
2673
  items: a.legend,
2634
- label: "Legend for " + d(ze)(a)
2674
+ label: "Legend for " + f(ze)(a)
2635
2675
  }, null, 8, ["items", "label"])) : R("", !0)
2636
2676
  ]))), 128)),
2637
- e.layers.length === 0 ? (m(), $("div", Za, "No layers available")) : R("", !0)
2638
- ], 8, Ra));
2677
+ e.layers.length === 0 ? (h(), $("div", Za, "No layers available")) : R("", !0)
2678
+ ], 8, Aa));
2639
2679
  }
2640
- }), Qa = /* @__PURE__ */ $e(Va, [["__scopeId", "data-v-c368d815"]]);
2641
- function Xa(e) {
2642
- const i = k([]), l = k(/* @__PURE__ */ new Set()), o = k({}), r = k(/* @__PURE__ */ new Set()), n = k({}), c = k(""), w = k(!1), p = k(!1), x = k(null), h = z(() => {
2680
+ }), Xa = /* @__PURE__ */ $e(Na, [["__scopeId", "data-v-c368d815"]]);
2681
+ function Ya(e) {
2682
+ const i = x([]), l = x(/* @__PURE__ */ new Set()), o = x({}), r = x(/* @__PURE__ */ new Set()), n = x({}), c = x(""), b = x(!1), p = x(!1), C = x(null), y = D(() => {
2643
2683
  if (!c.value.trim())
2644
2684
  return i.value;
2645
2685
  const T = c.value.toLowerCase();
2646
- return i.value.filter((O) => O.title.toLowerCase().includes(T));
2647
- }), g = z(() => i.value.map((T) => ({
2686
+ return i.value.filter((I) => I.title.toLowerCase().includes(T));
2687
+ }), g = D(() => i.value.map((T) => ({
2648
2688
  config: T,
2649
2689
  component: T.type
2650
2690
  // "circle", "fill", or "line"
2651
2691
  })));
2652
2692
  async function a() {
2653
2693
  if (!p.value) {
2654
- w.value = !0, x.value = null;
2694
+ b.value = !0, C.value = null;
2655
2695
  try {
2656
2696
  let T;
2657
2697
  e.mode === "dynamic" || !e.mode ? e.webMapId ? T = await v(e.webMapId) : T = await gt() : T = await gt(), i.value = T;
2658
- const O = {};
2698
+ const I = {};
2659
2699
  T.forEach((_) => {
2660
- O[_.id] = _.opacity ?? 1;
2661
- }), o.value = O, p.value = !0;
2700
+ I[_.id] = _.opacity ?? 1;
2701
+ }), o.value = I, p.value = !0;
2662
2702
  } catch (T) {
2663
- x.value = T instanceof Error ? T : new Error("Failed to initialize layerboard");
2703
+ C.value = T instanceof Error ? T : new Error("Failed to initialize layerboard");
2664
2704
  } finally {
2665
- w.value = !1;
2705
+ b.value = !1;
2666
2706
  }
2667
2707
  }
2668
2708
  }
2669
2709
  async function v(T) {
2670
- const O = St(T), _ = await fetch(O, { cache: "no-store" });
2710
+ const I = St(T), _ = await fetch(I, { cache: "no-store" });
2671
2711
  if (!_.ok)
2672
2712
  throw new Error(`Failed to fetch WebMap: ${_.status} ${_.statusText}`);
2673
2713
  const te = await _.json();
2674
- return Vt(te);
2714
+ return Zt(te);
2675
2715
  }
2676
- function f(T) {
2677
- const O = new Set(l.value);
2678
- O.has(T) ? O.delete(T) : O.add(T), l.value = O;
2716
+ function u(T) {
2717
+ const I = new Set(l.value);
2718
+ I.has(T) ? I.delete(T) : I.add(T), l.value = I;
2679
2719
  }
2680
- function L(T, O) {
2720
+ function w(T, I) {
2681
2721
  o.value = {
2682
2722
  ...o.value,
2683
- [T]: Math.max(0, Math.min(1, O))
2723
+ [T]: Math.max(0, Math.min(1, I))
2684
2724
  };
2685
2725
  }
2686
- function S(T) {
2726
+ function L(T) {
2687
2727
  c.value = T;
2688
2728
  }
2689
- function E(T, O) {
2729
+ function F(T, I) {
2690
2730
  const _ = new Set(r.value);
2691
- O ? _.add(T) : _.delete(T), r.value = _;
2731
+ I ? _.add(T) : _.delete(T), r.value = _;
2692
2732
  }
2693
- function D(T, O) {
2694
- if (O)
2695
- n.value = { ...n.value, [T]: O };
2733
+ function E(T, I) {
2734
+ if (I)
2735
+ n.value = { ...n.value, [T]: I };
2696
2736
  else {
2697
2737
  const _ = { ...n.value };
2698
2738
  delete _[T], n.value = _;
2699
2739
  }
2700
2740
  }
2701
- function X() {
2702
- i.value = [], l.value = /* @__PURE__ */ new Set(), o.value = {}, r.value = /* @__PURE__ */ new Set(), n.value = {}, c.value = "", w.value = !1, p.value = !1, x.value = null;
2741
+ function V() {
2742
+ i.value = [], l.value = /* @__PURE__ */ new Set(), o.value = {}, r.value = /* @__PURE__ */ new Set(), n.value = {}, c.value = "", b.value = !1, p.value = !1, C.value = null;
2703
2743
  }
2704
2744
  return {
2705
2745
  // State (readonly)
2706
- layerConfigs: j(i),
2707
- visibleLayers: j(l),
2708
- layerOpacities: j(o),
2709
- loadingLayers: j(r),
2710
- layerErrors: j(n),
2711
- searchQuery: j(c),
2712
- isLoading: j(w),
2713
- isInitialized: j(p),
2714
- error: j(x),
2746
+ layerConfigs: q(i),
2747
+ visibleLayers: q(l),
2748
+ layerOpacities: q(o),
2749
+ loadingLayers: q(r),
2750
+ layerErrors: q(n),
2751
+ searchQuery: q(c),
2752
+ isLoading: q(b),
2753
+ isInitialized: q(p),
2754
+ error: q(C),
2715
2755
  // Computed
2716
- filteredLayerConfigs: h,
2756
+ filteredLayerConfigs: y,
2717
2757
  layerList: g,
2718
2758
  // Config
2719
2759
  config: e,
2720
2760
  // Methods
2721
2761
  initialize: a,
2722
- toggleLayer: f,
2723
- setLayerOpacity: L,
2724
- filterLayers: S,
2725
- setLayerLoading: E,
2726
- setLayerError: D,
2727
- reset: X
2762
+ toggleLayer: u,
2763
+ setLayerOpacity: w,
2764
+ filterLayers: L,
2765
+ setLayerLoading: F,
2766
+ setLayerError: E,
2767
+ reset: V
2728
2768
  };
2729
2769
  }
2730
- function Ya() {
2731
- const e = k([]), i = k(/* @__PURE__ */ new Set()), l = k(/* @__PURE__ */ new Set());
2770
+ function ei() {
2771
+ const e = x([]), i = x(/* @__PURE__ */ new Set()), l = x(/* @__PURE__ */ new Set());
2732
2772
  function o(n) {
2733
2773
  i.value.has(n) ? i.value.delete(n) : i.value.add(n);
2734
2774
  }
@@ -2736,38 +2776,38 @@ function Ya() {
2736
2776
  e.value = n;
2737
2777
  }
2738
2778
  return {
2739
- layers: z(() => e.value),
2740
- visibleLayerIds: z(() => i.value),
2741
- loadingLayerIds: z(() => l.value),
2779
+ layers: D(() => e.value),
2780
+ visibleLayerIds: D(() => i.value),
2781
+ loadingLayerIds: D(() => l.value),
2742
2782
  toggleLayer: o,
2743
2783
  setLayers: r
2744
2784
  };
2745
2785
  }
2746
- function Na(e) {
2747
- const i = k(null), l = k(!1), o = k(null), r = k(0);
2786
+ function Ua(e) {
2787
+ const i = x(null), l = x(!1), o = x(null), r = x(0);
2748
2788
  async function n(p = {}) {
2749
2789
  l.value = !0, o.value = null;
2750
- const x = e.pageSize || 2e3;
2751
- let h = 0, g = [], a = !0;
2790
+ const C = e.pageSize || 2e3;
2791
+ let y = 0, g = [], a = !0;
2752
2792
  try {
2753
2793
  for (; a; ) {
2754
- const f = e.url.replace(/\/$/, ""), L = encodeURIComponent(p.where || e.where || "1=1");
2755
- let S = `${f}/query?where=${L}&outFields=*&returnGeometry=true&resultRecordCount=${x}&resultOffset=${h}&f=geojson`;
2794
+ const u = e.url.replace(/\/$/, ""), w = encodeURIComponent(p.where || e.where || "1=1");
2795
+ let L = `${u}/query?where=${w}&outFields=*&returnGeometry=true&resultRecordCount=${C}&resultOffset=${y}&f=geojson`;
2756
2796
  if (p.bounds) {
2757
- const X = JSON.stringify({
2797
+ const V = JSON.stringify({
2758
2798
  xmin: p.bounds.west,
2759
2799
  ymin: p.bounds.south,
2760
2800
  xmax: p.bounds.east,
2761
2801
  ymax: p.bounds.north,
2762
2802
  spatialReference: { wkid: 4326 }
2763
2803
  });
2764
- S += `&geometry=${encodeURIComponent(X)}&geometryType=esriGeometryEnvelope&spatialRel=esriSpatialRelIntersects`;
2804
+ L += `&geometry=${encodeURIComponent(V)}&geometryType=esriGeometryEnvelope&spatialRel=esriSpatialRelIntersects`;
2765
2805
  }
2766
- const E = await fetch(S);
2767
- if (!E.ok)
2768
- throw new Error(`HTTP ${E.status}: ${E.statusText}`);
2769
- const D = await E.json();
2770
- D.features && D.features.length > 0 ? (g = g.concat(D.features), h += D.features.length, a = D.features.length === x) : a = !1;
2806
+ const F = await fetch(L);
2807
+ if (!F.ok)
2808
+ throw new Error(`HTTP ${F.status}: ${F.statusText}`);
2809
+ const E = await F.json();
2810
+ E.features && E.features.length > 0 ? (g = g.concat(E.features), y += E.features.length, a = E.features.length === C) : a = !1;
2771
2811
  }
2772
2812
  const v = {
2773
2813
  type: "FeatureCollection",
@@ -2775,8 +2815,8 @@ function Na(e) {
2775
2815
  };
2776
2816
  return i.value = v, r.value = g.length, v;
2777
2817
  } catch (v) {
2778
- const f = v instanceof Error ? v : new Error("Failed to fetch features");
2779
- throw o.value = f, f;
2818
+ const u = v instanceof Error ? v : new Error("Failed to fetch features");
2819
+ throw o.value = u, u;
2780
2820
  } finally {
2781
2821
  l.value = !1;
2782
2822
  }
@@ -2784,25 +2824,25 @@ function Na(e) {
2784
2824
  function c() {
2785
2825
  i.value = null, r.value = 0, o.value = null;
2786
2826
  }
2787
- async function w(p = {}) {
2827
+ async function b(p = {}) {
2788
2828
  return n(p);
2789
2829
  }
2790
2830
  return {
2791
2831
  // State (readonly)
2792
- data: j(i),
2793
- isLoading: j(l),
2794
- error: j(o),
2795
- totalFeatures: j(r),
2832
+ data: q(i),
2833
+ isLoading: q(l),
2834
+ error: q(o),
2835
+ totalFeatures: q(r),
2796
2836
  // Config
2797
2837
  config: e,
2798
2838
  // Methods
2799
2839
  fetch: n,
2800
- refetch: w,
2840
+ refetch: b,
2801
2841
  clear: c
2802
2842
  };
2803
2843
  }
2804
- function ei(e, i, l) {
2805
- const o = Na(e);
2844
+ function ti(e, i, l) {
2845
+ const o = Ua(e);
2806
2846
  return Ie(
2807
2847
  i,
2808
2848
  async (r) => {
@@ -2815,26 +2855,26 @@ function ei(e, i, l) {
2815
2855
  ), o;
2816
2856
  }
2817
2857
  export {
2818
- Ka as LayerCheckboxSet,
2858
+ Qa as LayerCheckboxSet,
2819
2859
  Ho as LayerPanel,
2820
- Qa as LayerRadioButtonSet,
2821
- Ha as Layerboard,
2860
+ Xa as LayerRadioButtonSet,
2861
+ Ja as Layerboard,
2822
2862
  no as MapPanel,
2823
- Ja as TopicAccordion,
2824
- qa as WEBMAP_ID,
2863
+ Ka as TopicAccordion,
2864
+ Ga as WEBMAP_ID,
2825
2865
  St as buildWebMapUrl,
2826
- ca as clearCache,
2866
+ ua as clearCache,
2827
2867
  gt as getLayerConfigs,
2828
2868
  ze as getLayerDisplayName,
2829
- Ga as getWebMapUrl,
2869
+ Ha as getWebMapUrl,
2830
2870
  Bt as normalizeUrl,
2831
- Fa as shouldShowCheckbox,
2871
+ Ea as shouldShowCheckbox,
2832
2872
  Ut as shouldShowLegendBox,
2833
2873
  Nt as shouldShowSlider,
2834
- Vt as transformWebMapToLayerConfigs,
2835
- pa as useApiDataSources,
2836
- Na as useDataSource,
2837
- Ya as useLayerConfig,
2838
- Xa as useLayerboard,
2839
- ei as useReactiveDataSource
2874
+ Zt as transformWebMapToLayerConfigs,
2875
+ ya as useApiDataSources,
2876
+ Ua as useDataSource,
2877
+ ei as useLayerConfig,
2878
+ Ya as useLayerboard,
2879
+ ti as useReactiveDataSource
2840
2880
  };