@carto/ps-react-maps 4.3.0 → 4.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +433 -429
- package/dist/index.js.map +1 -1
- package/dist/types/providers/map/types.d.ts +1 -0
- package/dist/types/use-event-manager.d.ts +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as G, jsxs as yt } from "react/jsx-runtime";
|
|
2
2
|
import { c as j } from "react/compiler-runtime";
|
|
3
|
-
import { useImperativeHandle as Ie, useEffect as
|
|
3
|
+
import { useImperativeHandle as Ie, useEffect as Q, useState as ue, createContext as He, useContext as Ne, useMemo as ge, useCallback as se, useRef as ke } from "react";
|
|
4
4
|
import { MapProvider as Vt, Map as qt, useMap as jt } from "react-map-gl/maplibre";
|
|
5
5
|
import Bt from "@deck.gl/react";
|
|
6
6
|
import { useMap as ht, Map as It, APIProvider as Ht } from "@vis.gl/react-google-maps";
|
|
@@ -154,11 +154,11 @@ const $n = (n) => {
|
|
|
154
154
|
let a, l;
|
|
155
155
|
e[3] !== s ? (a = () => (r.setMap(s), () => {
|
|
156
156
|
r.finalize();
|
|
157
|
-
}), l = [r, s], e[3] = s, e[4] = a, e[5] = l) : (a = e[4], l = e[5]),
|
|
157
|
+
}), l = [r, s], e[3] = s, e[4] = a, e[5] = l) : (a = e[4], l = e[5]), Q(a, l);
|
|
158
158
|
let d, p;
|
|
159
159
|
return e[6] !== n ? (d = () => {
|
|
160
160
|
r.setProps(n);
|
|
161
|
-
}, p = [r, n], e[6] = n, e[7] = d, e[8] = p) : (d = e[7], p = e[8]),
|
|
161
|
+
}, p = [r, n], e[6] = n, e[7] = d, e[8] = p) : (d = e[7], p = e[8]), Q(d, p), null;
|
|
162
162
|
};
|
|
163
163
|
function Un(n) {
|
|
164
164
|
const e = j(77);
|
|
@@ -197,105 +197,105 @@ function Un(n) {
|
|
|
197
197
|
}, e[18] = r, e[19] = ie) : ie = e[19], u = ie;
|
|
198
198
|
break e;
|
|
199
199
|
}
|
|
200
|
-
const
|
|
201
|
-
let
|
|
202
|
-
e[20] !==
|
|
203
|
-
dragPan:
|
|
204
|
-
doubleClickZoom:
|
|
205
|
-
scrollZoom:
|
|
206
|
-
}, e[20] =
|
|
200
|
+
const ee = r, ne = ee?.dragPan ?? !0, J = ee?.doubleClickZoom ?? !0, K = ee?.scrollZoom ?? !0;
|
|
201
|
+
let te;
|
|
202
|
+
e[20] !== ne || e[21] !== J || e[22] !== K ? (te = {
|
|
203
|
+
dragPan: ne,
|
|
204
|
+
doubleClickZoom: J,
|
|
205
|
+
scrollZoom: K
|
|
206
|
+
}, e[20] = ne, e[21] = J, e[22] = K, e[23] = te) : te = e[23], u = te;
|
|
207
207
|
}
|
|
208
208
|
const m = u;
|
|
209
209
|
let g;
|
|
210
210
|
e[24] !== i ? (g = i.filter(qn).map(Vn), e[24] = i, e[25] = g) : g = e[25];
|
|
211
211
|
const w = g;
|
|
212
212
|
let v;
|
|
213
|
-
e[26] !== h.initialViewState?.maxZoom || e[27] !== h.initialViewState?.minZoom ? (v = (
|
|
213
|
+
e[26] !== h.initialViewState?.maxZoom || e[27] !== h.initialViewState?.minZoom ? (v = (ee) => {
|
|
214
214
|
const {
|
|
215
|
-
detail:
|
|
216
|
-
} =
|
|
217
|
-
center:
|
|
218
|
-
zoom:
|
|
219
|
-
heading:
|
|
215
|
+
detail: ne
|
|
216
|
+
} = ee, {
|
|
217
|
+
center: J,
|
|
218
|
+
zoom: K,
|
|
219
|
+
heading: te,
|
|
220
220
|
tilt: ie
|
|
221
|
-
} =
|
|
221
|
+
} = ne;
|
|
222
222
|
return {
|
|
223
223
|
maxZoom: h.initialViewState?.maxZoom,
|
|
224
224
|
minZoom: h.initialViewState?.minZoom,
|
|
225
|
-
latitude:
|
|
226
|
-
longitude:
|
|
227
|
-
zoom:
|
|
228
|
-
bearing:
|
|
225
|
+
latitude: J.lat,
|
|
226
|
+
longitude: J.lng,
|
|
227
|
+
zoom: K - 1,
|
|
228
|
+
bearing: te,
|
|
229
229
|
pitch: ie
|
|
230
230
|
};
|
|
231
231
|
}, e[26] = h.initialViewState?.maxZoom, e[27] = h.initialViewState?.minZoom, e[28] = v) : v = e[28], h.initialViewState?.maxZoom, h.initialViewState?.minZoom;
|
|
232
232
|
const k = v;
|
|
233
|
-
let
|
|
234
|
-
e[29] !== o || e[30] !== l ? (
|
|
235
|
-
const
|
|
236
|
-
...
|
|
237
|
-
...
|
|
238
|
-
},
|
|
239
|
-
...
|
|
240
|
-
latitude:
|
|
241
|
-
longitude:
|
|
242
|
-
zoom:
|
|
243
|
-
pitch:
|
|
244
|
-
bearing:
|
|
245
|
-
width:
|
|
246
|
-
height:
|
|
233
|
+
let D;
|
|
234
|
+
e[29] !== o || e[30] !== l ? (D = (ee) => {
|
|
235
|
+
const J = o?.current?._deck, K = {
|
|
236
|
+
...J?.viewState,
|
|
237
|
+
...ee
|
|
238
|
+
}, te = {
|
|
239
|
+
...K,
|
|
240
|
+
latitude: K.latitude,
|
|
241
|
+
longitude: K.longitude,
|
|
242
|
+
zoom: K.zoom,
|
|
243
|
+
pitch: K.pitch,
|
|
244
|
+
bearing: K.bearing,
|
|
245
|
+
width: J?.width,
|
|
246
|
+
height: J?.height
|
|
247
247
|
};
|
|
248
248
|
l?.({
|
|
249
|
-
viewState:
|
|
249
|
+
viewState: te,
|
|
250
250
|
interactionState: {
|
|
251
251
|
isZooming: !0
|
|
252
252
|
}
|
|
253
253
|
});
|
|
254
|
-
}, e[29] = o, e[30] = l, e[31] =
|
|
255
|
-
const
|
|
254
|
+
}, e[29] = o, e[30] = l, e[31] = D) : D = e[31];
|
|
255
|
+
const U = D;
|
|
256
256
|
let A;
|
|
257
|
-
e[32] !==
|
|
258
|
-
const
|
|
259
|
-
|
|
260
|
-
}, e[32] =
|
|
261
|
-
const
|
|
257
|
+
e[32] !== U || e[33] !== k ? (A = (ee) => {
|
|
258
|
+
const ne = k(ee);
|
|
259
|
+
U(ne);
|
|
260
|
+
}, e[32] = U, e[33] = k, e[34] = A) : A = e[34];
|
|
261
|
+
const V = A, q = h.initialViewState?.latitude ?? 0, F = h.initialViewState?.longitude ?? 0;
|
|
262
262
|
let _;
|
|
263
|
-
e[35] !== q || e[36] !==
|
|
263
|
+
e[35] !== q || e[36] !== F ? (_ = {
|
|
264
264
|
lat: q,
|
|
265
|
-
lng:
|
|
266
|
-
}, e[35] = q, e[36] =
|
|
265
|
+
lng: F
|
|
266
|
+
}, e[35] = q, e[36] = F, e[37] = _) : _ = e[37];
|
|
267
267
|
const O = (h.initialViewState?.zoom ?? 0) + 1, c = (h.initialViewState?.maxZoom ?? 23) + 1, y = (h.initialViewState?.minZoom ?? 0) + 1, T = h.initialViewState?.pitch, P = h.initialViewState?.bearing;
|
|
268
268
|
let C;
|
|
269
|
-
e[38] !==
|
|
269
|
+
e[38] !== U || e[39] !== a || e[40] !== h.initialViewState ? (C = () => {
|
|
270
270
|
a({
|
|
271
271
|
type: "load",
|
|
272
272
|
value: !0
|
|
273
|
-
}),
|
|
274
|
-
}, e[38] =
|
|
275
|
-
const E = typeof m.scrollZoom == "boolean" ? m.scrollZoom : !!m.scrollZoom, B = m.dragPan ? "greedy" : "none",
|
|
276
|
-
let
|
|
277
|
-
e[42] !== s || e[43] !== d ? (
|
|
278
|
-
let
|
|
279
|
-
e[45] !== a ? (
|
|
273
|
+
}), U(h.initialViewState);
|
|
274
|
+
}, e[38] = U, e[39] = a, e[40] = h.initialViewState, e[41] = C) : C = e[41];
|
|
275
|
+
const E = typeof m.scrollZoom == "boolean" ? m.scrollZoom : !!m.scrollZoom, B = m.dragPan ? "greedy" : "none", Z = !m.doubleClickZoom;
|
|
276
|
+
let I;
|
|
277
|
+
e[42] !== s || e[43] !== d ? (I = /* @__PURE__ */ G(jn, { id: s, overlayRef: d }), e[42] = s, e[43] = d, e[44] = I) : I = e[44];
|
|
278
|
+
let $;
|
|
279
|
+
e[45] !== a ? ($ = () => {
|
|
280
280
|
a({
|
|
281
281
|
type: "deckgl",
|
|
282
282
|
value: !0
|
|
283
283
|
});
|
|
284
|
-
}, e[45] = a, e[46] =
|
|
285
|
-
let
|
|
286
|
-
e[47] !== p ? (
|
|
284
|
+
}, e[45] = a, e[46] = $) : $ = e[46];
|
|
285
|
+
let H;
|
|
286
|
+
e[47] !== p ? (H = {
|
|
287
287
|
depthTest: !1,
|
|
288
288
|
...p
|
|
289
|
-
}, e[47] = p, e[48] =
|
|
290
|
-
let
|
|
291
|
-
e[49] !== w || e[50] !== s || e[51] !== o || e[52] !== h || e[53] !==
|
|
292
|
-
let
|
|
293
|
-
e[56] !== S || e[57] !== t || e[58] !==
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
] }) }), e[56] = S, e[57] = t, e[58] =
|
|
289
|
+
}, e[47] = p, e[48] = H) : H = e[48];
|
|
290
|
+
let W;
|
|
291
|
+
e[49] !== w || e[50] !== s || e[51] !== o || e[52] !== h || e[53] !== $ || e[54] !== H ? (W = /* @__PURE__ */ G($n, { id: s, instanceRef: o, layers: w, onLoad: $, parameters: H, ...h }), e[49] = w, e[50] = s, e[51] = o, e[52] = h, e[53] = $, e[54] = H, e[55] = W) : W = e[55];
|
|
292
|
+
let X;
|
|
293
|
+
e[56] !== S || e[57] !== t || e[58] !== V || e[59] !== s || e[60] !== _ || e[61] !== O || e[62] !== c || e[63] !== y || e[64] !== T || e[65] !== P || e[66] !== C || e[67] !== E || e[68] !== B || e[69] !== Z || e[70] !== I || e[71] !== W ? (X = /* @__PURE__ */ G("div", { className: "deckgl-map", children: /* @__PURE__ */ yt(It, { id: s, mapTypeId: t, disableDefaultUI: !0, ...S, center: _, zoom: O, maxZoom: c, minZoom: y, tilt: T, heading: P, onTilesLoaded: C, onBoundsChanged: V, onZoomChanged: V, scrollwheel: E, gestureHandling: B, disableDoubleClickZoom: Z, children: [
|
|
294
|
+
I,
|
|
295
|
+
W
|
|
296
|
+
] }) }), e[56] = S, e[57] = t, e[58] = V, e[59] = s, e[60] = _, e[61] = O, e[62] = c, e[63] = y, e[64] = T, e[65] = P, e[66] = C, e[67] = E, e[68] = B, e[69] = Z, e[70] = I, e[71] = W, e[72] = X) : X = e[72];
|
|
297
297
|
let le;
|
|
298
|
-
return e[73] !== M || e[74] !== L || e[75] !==
|
|
298
|
+
return e[73] !== M || e[74] !== L || e[75] !== X ? (le = /* @__PURE__ */ G(Ht, { apiKey: L, ...M, children: X }), e[73] = M, e[74] = L, e[75] = X, e[76] = le) : le = e[76], le;
|
|
299
299
|
}
|
|
300
300
|
function Vn(n) {
|
|
301
301
|
const {
|
|
@@ -338,16 +338,16 @@ function Bn(n) {
|
|
|
338
338
|
const m = u, g = h === void 0 ? Pn : h, w = b === void 0 ? On : b, v = f === void 0 ? Hn : f;
|
|
339
339
|
let k;
|
|
340
340
|
e[15] === Symbol.for("react.memo_cache_sentinel") ? (k = [!1, !1], e[15] = k) : k = e[15];
|
|
341
|
-
const [
|
|
341
|
+
const [D, U] = ue(k), {
|
|
342
342
|
url: A,
|
|
343
|
-
type:
|
|
344
|
-
} = we[M], q =
|
|
345
|
-
let
|
|
346
|
-
e[16] === Symbol.for("react.memo_cache_sentinel") ? (
|
|
343
|
+
type: V
|
|
344
|
+
} = we[M], q = V === ce.googleMaps;
|
|
345
|
+
let F;
|
|
346
|
+
e[16] === Symbol.for("react.memo_cache_sentinel") ? (F = (C) => {
|
|
347
347
|
const E = C.type === "deckgl" ? 0 : 1;
|
|
348
|
-
|
|
349
|
-
}, e[16] =
|
|
350
|
-
const _ =
|
|
348
|
+
U((B) => B.map((Z, I) => I === E ? C.value : Z));
|
|
349
|
+
}, e[16] = F) : F = e[16];
|
|
350
|
+
const _ = F;
|
|
351
351
|
let O, c;
|
|
352
352
|
e[17] === Symbol.for("react.memo_cache_sentinel") ? (O = () => () => {
|
|
353
353
|
_({
|
|
@@ -357,12 +357,12 @@ function Bn(n) {
|
|
|
357
357
|
type: "deckgl",
|
|
358
358
|
value: !1
|
|
359
359
|
});
|
|
360
|
-
}, c = [_], e[17] = O, e[18] = c) : (O = e[17], c = e[18]),
|
|
360
|
+
}, c = [_], e[17] = O, e[18] = c) : (O = e[17], c = e[18]), Q(O, c);
|
|
361
361
|
let y, T;
|
|
362
|
-
if (e[19] !==
|
|
363
|
-
const C =
|
|
362
|
+
if (e[19] !== D || e[20] !== s ? (y = () => {
|
|
363
|
+
const C = D.every(In);
|
|
364
364
|
s?.(C);
|
|
365
|
-
}, T = [
|
|
365
|
+
}, T = [D, s], e[19] = D, e[20] = s, e[21] = y, e[22] = T) : (y = e[21], T = e[22]), Q(y, T), q) {
|
|
366
366
|
let C;
|
|
367
367
|
return e[23] !== M || e[24] !== S || e[25] !== g || e[26] !== w || e[27] !== t || e[28] !== L || e[29] !== r || e[30] !== m || e[31] !== v || e[32] !== o || e[33] !== i ? (C = /* @__PURE__ */ G(Un, { instanceRef: r, overlayRef: o, controller: S, id: L, basemap: M, layers: m, gmapsProps: t, getCursor: g, getTooltip: w, onLoad: _, onViewStateChange: v, ...i }), e[23] = M, e[24] = S, e[25] = g, e[26] = w, e[27] = t, e[28] = L, e[29] = r, e[30] = m, e[31] = v, e[32] = o, e[33] = i, e[34] = C) : C = e[34], C;
|
|
368
368
|
}
|
|
@@ -570,6 +570,7 @@ const me = /* @__PURE__ */ Tt(zn), Gn = (n) => {
|
|
|
570
570
|
maps: a
|
|
571
571
|
};
|
|
572
572
|
}),
|
|
573
|
+
getController: (s) => r().maps[s]?.controller ?? {},
|
|
573
574
|
setController: (s, o) => t((i) => {
|
|
574
575
|
const a = i.maps[s]?.controller ?? {}, d = !o || typeof o == "boolean" ? o : me(typeof a == "boolean" ? {} : a, o);
|
|
575
576
|
return {
|
|
@@ -770,7 +771,7 @@ function x(n) {
|
|
|
770
771
|
throw new Error("Missing MapProvider in the tree");
|
|
771
772
|
return ze(e, n);
|
|
772
773
|
}
|
|
773
|
-
function
|
|
774
|
+
function bo(n) {
|
|
774
775
|
const e = j(9), {
|
|
775
776
|
children: t,
|
|
776
777
|
mapId: r
|
|
@@ -792,7 +793,7 @@ function go(n) {
|
|
|
792
793
|
function tr(n) {
|
|
793
794
|
return n.setBasemap;
|
|
794
795
|
}
|
|
795
|
-
const
|
|
796
|
+
const oe = {
|
|
796
797
|
addFeature: "addFeature",
|
|
797
798
|
addTentativePosition: "addTentativePosition",
|
|
798
799
|
updateTentativeFeature: "updateTentativeFeature",
|
|
@@ -807,7 +808,7 @@ class nr extends zt {
|
|
|
807
808
|
handleKeyUp(e, t) {
|
|
808
809
|
super.handleKeyUp(e, t), e.key === "Enter" && (this.resetClickSequence(), t.onEdit({
|
|
809
810
|
updatedData: t.data,
|
|
810
|
-
editType:
|
|
811
|
+
editType: oe.addFeature,
|
|
811
812
|
editContext: {}
|
|
812
813
|
}));
|
|
813
814
|
}
|
|
@@ -913,7 +914,7 @@ const he = "lassoLayer", Oe = "maskLayer", rr = {
|
|
|
913
914
|
layers: r
|
|
914
915
|
};
|
|
915
916
|
})
|
|
916
|
-
})), rt = ["click", "
|
|
917
|
+
})), rt = ["click", "keyup", "panstart", "panmove", "panend", "pointermove"], kt = {
|
|
917
918
|
multipan: [Qe, {
|
|
918
919
|
threshold: 10,
|
|
919
920
|
direction: on.Vertical,
|
|
@@ -956,7 +957,7 @@ function Ct(n) {
|
|
|
956
957
|
eventManager: S
|
|
957
958
|
}
|
|
958
959
|
}));
|
|
959
|
-
}, M = [d, b, a, l, r, t, p], e[4] = l, e[5] = d, e[6] = b, e[7] = a, e[8] = r, e[9] = t, e[10] = p, e[11] = f, e[12] = M) : (f = e[11], M = e[12]),
|
|
960
|
+
}, M = [d, b, a, l, r, t, p], e[4] = l, e[5] = d, e[6] = b, e[7] = a, e[8] = r, e[9] = t, e[10] = p, e[11] = f, e[12] = M) : (f = e[11], M = e[12]), Q(f, M);
|
|
960
961
|
}
|
|
961
962
|
function or(n) {
|
|
962
963
|
const [e, t, r, s] = kt[n], o = {
|
|
@@ -1156,7 +1157,7 @@ function fr(n) {
|
|
|
1156
1157
|
let i;
|
|
1157
1158
|
return e[2] !== t || e[3] !== o ? (i = /* @__PURE__ */ G(Ot.Provider, { value: o, children: t }), e[2] = t, e[3] = o, e[4] = i) : i = e[4], i;
|
|
1158
1159
|
}
|
|
1159
|
-
function
|
|
1160
|
+
function Y(n) {
|
|
1160
1161
|
const e = Ne(Ot);
|
|
1161
1162
|
if (!Object.keys(e).length)
|
|
1162
1163
|
throw new Error("Missing LassoToolsProvider in the tree");
|
|
@@ -1166,8 +1167,8 @@ function pr({
|
|
|
1166
1167
|
mapId: n,
|
|
1167
1168
|
children: e
|
|
1168
1169
|
}) {
|
|
1169
|
-
const t =
|
|
1170
|
-
|
|
1170
|
+
const t = Y((f) => f.data[n]?.enabled), r = Y((f) => f.setEnabled), s = Y((f) => f.data[n]?.values), o = Y((f) => f.setValue), i = Y((f) => f.setVisibility), a = Y((f) => f.data[n]?.modeSelected), l = Y((f) => f.setModeSelected), d = Y((f) => f.data[n]?.modes), p = Y((f) => f.setModeInstance);
|
|
1171
|
+
Q(() => {
|
|
1171
1172
|
const f = d[a];
|
|
1172
1173
|
if (f && t) {
|
|
1173
1174
|
const M = f.mode;
|
|
@@ -1188,7 +1189,7 @@ function pr({
|
|
|
1188
1189
|
Object.values(s).filter((L) => L.type === "mask").map(f)
|
|
1189
1190
|
// , draw
|
|
1190
1191
|
];
|
|
1191
|
-
}, [s]), b =
|
|
1192
|
+
}, [s]), b = se((f) => {
|
|
1192
1193
|
r(n, !!f), l(n, f);
|
|
1193
1194
|
}, [n, r, l]);
|
|
1194
1195
|
return e({
|
|
@@ -1200,9 +1201,9 @@ function pr({
|
|
|
1200
1201
|
mask: h
|
|
1201
1202
|
// draw,
|
|
1202
1203
|
},
|
|
1203
|
-
setValue:
|
|
1204
|
-
setEnabled:
|
|
1205
|
-
setVisibility:
|
|
1204
|
+
setValue: se((f, M) => o(n, f, M), [n, o]),
|
|
1205
|
+
setEnabled: se((f) => r(n, f), [n, r]),
|
|
1206
|
+
setVisibility: se((f, M) => i(n, f, M), [n, i]),
|
|
1206
1207
|
setModeSelected: b
|
|
1207
1208
|
});
|
|
1208
1209
|
}
|
|
@@ -1270,7 +1271,7 @@ function Ae({
|
|
|
1270
1271
|
})}`;
|
|
1271
1272
|
return i === "area" && (b += "2"), s ? s(b) : b;
|
|
1272
1273
|
}
|
|
1273
|
-
function
|
|
1274
|
+
function So(n, {
|
|
1274
1275
|
hasDoubleClickZoom: e
|
|
1275
1276
|
}) {
|
|
1276
1277
|
return typeof n == "boolean" ? {
|
|
@@ -1389,7 +1390,7 @@ class gr extends Xt {
|
|
|
1389
1390
|
const s = this.getAddFeatureOrBooleanPolygonAction(r, e);
|
|
1390
1391
|
this._isMeasuringSessionFinished = !0, s && (this.resultPolygon = s.updatedData, e.onEdit({
|
|
1391
1392
|
...s,
|
|
1392
|
-
editType:
|
|
1393
|
+
editType: oe.addPosition,
|
|
1393
1394
|
editContext: {
|
|
1394
1395
|
...s.editContext,
|
|
1395
1396
|
distance: this.area,
|
|
@@ -1457,7 +1458,7 @@ class br extends St {
|
|
|
1457
1458
|
const r = this.getAddFeatureOrBooleanPolygonAction(t, e);
|
|
1458
1459
|
this._isMeasuringSessionFinished = !0, e.onUpdateCursor("cell"), r && (this.resultPolygon = r.updatedData, e.onEdit({
|
|
1459
1460
|
...r,
|
|
1460
|
-
editType:
|
|
1461
|
+
editType: oe.addPosition,
|
|
1461
1462
|
editContext: {
|
|
1462
1463
|
...r.editContext,
|
|
1463
1464
|
distance: this._currentArea,
|
|
@@ -1500,7 +1501,7 @@ class Dt extends tn {
|
|
|
1500
1501
|
super.handleClick(e, t), t.onEdit({
|
|
1501
1502
|
// data is the same
|
|
1502
1503
|
updatedData: t.data,
|
|
1503
|
-
editType:
|
|
1504
|
+
editType: oe.addPosition,
|
|
1504
1505
|
editContext: {
|
|
1505
1506
|
distance: this._currentDistance,
|
|
1506
1507
|
finished: this._isMeasuringSessionFinished,
|
|
@@ -1514,7 +1515,7 @@ class Dt extends tn {
|
|
|
1514
1515
|
const {
|
|
1515
1516
|
key: r
|
|
1516
1517
|
} = e, s = this.getClickSequence().length;
|
|
1517
|
-
let o =
|
|
1518
|
+
let o = oe.finish;
|
|
1518
1519
|
switch (r) {
|
|
1519
1520
|
case "Escape":
|
|
1520
1521
|
t.onEdit({
|
|
@@ -1522,12 +1523,12 @@ class Dt extends tn {
|
|
|
1522
1523
|
type: "FeatureCollection",
|
|
1523
1524
|
features: []
|
|
1524
1525
|
},
|
|
1525
|
-
editType:
|
|
1526
|
+
editType: oe.cancel,
|
|
1526
1527
|
editContext: {}
|
|
1527
1528
|
});
|
|
1528
1529
|
break;
|
|
1529
1530
|
case "Enter":
|
|
1530
|
-
this._isMeasuringSessionFinished = !0, s === 1 && (this.resetClickSequence(), o =
|
|
1531
|
+
this._isMeasuringSessionFinished = !0, s === 1 && (this.resetClickSequence(), o = oe.cancel), t.onUpdateCursor("cell"), t.onEdit({
|
|
1531
1532
|
updatedData: t.data,
|
|
1532
1533
|
editType: o,
|
|
1533
1534
|
editContext: {
|
|
@@ -1638,7 +1639,7 @@ const fe = "mapMeasureLayer", Sr = {
|
|
|
1638
1639
|
[N.mile]: "mile",
|
|
1639
1640
|
[N.yard]: "yard",
|
|
1640
1641
|
[N.feet]: "foot"
|
|
1641
|
-
},
|
|
1642
|
+
}, re = {
|
|
1642
1643
|
"m-km": {
|
|
1643
1644
|
value: "m-km",
|
|
1644
1645
|
system: "metric"
|
|
@@ -1675,7 +1676,7 @@ const fe = "mapMeasureLayer", Sr = {
|
|
|
1675
1676
|
value: "feet",
|
|
1676
1677
|
system: "imperial"
|
|
1677
1678
|
}
|
|
1678
|
-
}, ct = [
|
|
1679
|
+
}, ct = [re["m-km"], re.kilometer, re.meter, re["ft-mi"], re.mile, re.feet], wr = [re["m-km"], re.kilometer, re.meter, re["ft-mi"], re.mile, re.feet], Mr = {
|
|
1679
1680
|
distance: {
|
|
1680
1681
|
value: "distance",
|
|
1681
1682
|
mode: Dt
|
|
@@ -1706,7 +1707,7 @@ function Tr({
|
|
|
1706
1707
|
layerProps: s = {},
|
|
1707
1708
|
defaultType: o = "mask"
|
|
1708
1709
|
}) {
|
|
1709
|
-
const i =
|
|
1710
|
+
const i = Y((_) => _.data[e]?.enabled), a = Y((_) => _.setEnabled), l = Y((_) => _.data[e]?.values), d = Y((_) => _.setValue), p = Y((_) => _.data[e]?.modeInstance), h = Y((_) => _.data[e]?.modeSelected), b = Se((_) => _.setLayer), f = x((_) => _.addLayers), M = x((_) => _.removeLayers), S = x(vt((_) => _.maps[e]?.layers.filter((O) => !Er.includes(O)))), L = x((_) => _.getDeckInstance), u = ke({});
|
|
1710
1711
|
Ct({
|
|
1711
1712
|
mapId: e,
|
|
1712
1713
|
layerId: he
|
|
@@ -1721,32 +1722,32 @@ function Tr({
|
|
|
1721
1722
|
properties: _.properties,
|
|
1722
1723
|
id: _.id
|
|
1723
1724
|
}))
|
|
1724
|
-
}), [m]), w = ge(() => m.filter((_) => _.properties.visible).map((_) => _.id), [m]), [v, k] = ue(g), [
|
|
1725
|
+
}), [m]), w = ge(() => m.filter((_) => _.properties.visible).map((_) => _.id), [m]), [v, k] = ue(g), [D, U] = ue([]), A = se(() => {
|
|
1725
1726
|
const _ = {
|
|
1726
1727
|
...g,
|
|
1727
1728
|
features: g.features.filter((O) => O.properties?.visible)
|
|
1728
1729
|
};
|
|
1729
1730
|
k(_);
|
|
1730
1731
|
}, [g]);
|
|
1731
|
-
|
|
1732
|
+
Q(() => {
|
|
1732
1733
|
A();
|
|
1733
1734
|
}, [A]);
|
|
1734
|
-
const
|
|
1735
|
-
|
|
1735
|
+
const V = ke(m.length);
|
|
1736
|
+
Q(() => (f(e, [he]), () => {
|
|
1736
1737
|
M(e, [he]);
|
|
1737
1738
|
}), [f, e, M]);
|
|
1738
|
-
const q =
|
|
1739
|
-
A(),
|
|
1740
|
-
}, [e, A, a]),
|
|
1739
|
+
const q = se(() => {
|
|
1740
|
+
A(), U([]), a(e, !1);
|
|
1741
|
+
}, [e, A, a]), F = se(({
|
|
1741
1742
|
editType: _,
|
|
1742
1743
|
updatedData: O
|
|
1743
1744
|
}) => {
|
|
1744
|
-
if (_ ===
|
|
1745
|
+
if (_ === oe.cancel) {
|
|
1745
1746
|
q();
|
|
1746
1747
|
return;
|
|
1747
1748
|
}
|
|
1748
|
-
k(O), _ !==
|
|
1749
|
-
c.properties.label ??= `${r?.mask} ${
|
|
1749
|
+
k(O), _ !== oe.updateTentativeFeature && _ === oe.addFeature && (h !== "edit" && (V.current = V.current + 1), O.features.forEach((c, y) => {
|
|
1750
|
+
c.properties.label ??= `${r?.mask} ${V.current}`, c.properties.index = y, c.properties.visible = c.properties.visible ?? !0;
|
|
1750
1751
|
const T = c.id ?? crypto.randomUUID();
|
|
1751
1752
|
d(e, T, {
|
|
1752
1753
|
geometry: c.geometry,
|
|
@@ -1756,7 +1757,7 @@ function Tr({
|
|
|
1756
1757
|
});
|
|
1757
1758
|
}), q());
|
|
1758
1759
|
}, [o, q, r?.mask, e, h, d]);
|
|
1759
|
-
return
|
|
1760
|
+
return Q(() => {
|
|
1760
1761
|
const _ = i, {
|
|
1761
1762
|
border: O,
|
|
1762
1763
|
point: c,
|
|
@@ -1769,26 +1770,26 @@ function Tr({
|
|
|
1769
1770
|
...s.mask,
|
|
1770
1771
|
pickable: _,
|
|
1771
1772
|
data: v,
|
|
1772
|
-
selectedFeatureIndexes:
|
|
1773
|
+
selectedFeatureIndexes: D,
|
|
1773
1774
|
updateTriggers: {
|
|
1774
1775
|
getFilterValue: w
|
|
1775
1776
|
},
|
|
1776
1777
|
onClick: (E) => {
|
|
1777
1778
|
const B = E;
|
|
1778
|
-
B.isGuide ||
|
|
1779
|
+
B.isGuide || U([B.index]);
|
|
1779
1780
|
}
|
|
1780
1781
|
},
|
|
1781
|
-
getLineColor: (E) =>
|
|
1782
|
-
getFillColor: (E) =>
|
|
1782
|
+
getLineColor: (E) => D[0] === E.properties.index ? O : T,
|
|
1783
|
+
getFillColor: (E) => D[0] === E.properties.index ? y : P,
|
|
1783
1784
|
pointColor: {
|
|
1784
1785
|
fill: c,
|
|
1785
1786
|
outline: O
|
|
1786
1787
|
},
|
|
1787
|
-
onEdit:
|
|
1788
|
+
onEdit: F,
|
|
1788
1789
|
mode: _ ? p : new nn()
|
|
1789
1790
|
});
|
|
1790
1791
|
b(he, C);
|
|
1791
|
-
}, [v, i, s.mask, w, p,
|
|
1792
|
+
}, [v, i, s.mask, w, p, F, D, b, t.colors.editing, t.colors.finished]), Q(() => {
|
|
1792
1793
|
const _ = {
|
|
1793
1794
|
...Te,
|
|
1794
1795
|
data: g,
|
|
@@ -1803,7 +1804,7 @@ function Tr({
|
|
|
1803
1804
|
}), f(e, [Te.id]), () => {
|
|
1804
1805
|
M(e, [Te.id]);
|
|
1805
1806
|
};
|
|
1806
|
-
}, [f, e, g, w, M, b]),
|
|
1807
|
+
}, [f, e, g, w, M, b]), Q(() => {
|
|
1807
1808
|
S?.forEach((_) => {
|
|
1808
1809
|
const O = L(e)?.props.layers.find((y) => y.props.id === _);
|
|
1809
1810
|
if (!O) return;
|
|
@@ -2060,13 +2061,13 @@ function xt(n) {
|
|
|
2060
2061
|
e[18] !== v || e[19] !== t || e[20] !== m ? (k = (R) => {
|
|
2061
2062
|
m(!!R), v(t, R);
|
|
2062
2063
|
}, e[18] = v, e[19] = t, e[20] = m, e[21] = k) : k = e[21];
|
|
2063
|
-
const
|
|
2064
|
-
let
|
|
2065
|
-
e[22] !== t ? (
|
|
2066
|
-
const A = z(
|
|
2064
|
+
const D = k;
|
|
2065
|
+
let U;
|
|
2066
|
+
e[22] !== t ? (U = (R) => R.measurements[t].finished, e[22] = t, e[23] = U) : U = e[23];
|
|
2067
|
+
const A = z(U), V = z(Rr);
|
|
2067
2068
|
let q;
|
|
2068
|
-
e[24] !==
|
|
2069
|
-
const
|
|
2069
|
+
e[24] !== V || e[25] !== t ? (q = (R) => V(t, R), e[24] = V, e[25] = t, e[26] = q) : q = e[26];
|
|
2070
|
+
const F = q;
|
|
2070
2071
|
let _;
|
|
2071
2072
|
e[27] !== t ? (_ = (R) => R.measurements[t].locale, e[27] = t, e[28] = _) : _ = e[28];
|
|
2072
2073
|
const O = z(_), c = z(Dr);
|
|
@@ -2078,31 +2079,31 @@ function xt(n) {
|
|
|
2078
2079
|
const C = z(P), E = z(Fr);
|
|
2079
2080
|
let B;
|
|
2080
2081
|
e[34] !== E || e[35] !== t ? (B = (R) => E(t, R), e[34] = E, e[35] = t, e[36] = B) : B = e[36];
|
|
2081
|
-
const
|
|
2082
|
-
let
|
|
2083
|
-
e[37] !== t ? (
|
|
2084
|
-
const
|
|
2085
|
-
let
|
|
2086
|
-
e[39] !==
|
|
2087
|
-
const
|
|
2082
|
+
const Z = B;
|
|
2083
|
+
let I;
|
|
2084
|
+
e[37] !== t ? (I = (R) => R.measurements[t].positions, e[37] = t, e[38] = I) : I = e[38];
|
|
2085
|
+
const $ = z(I), H = z(Ar);
|
|
2086
|
+
let W;
|
|
2087
|
+
e[39] !== H || e[40] !== t ? (W = (R) => H(t, R), e[39] = H, e[40] = t, e[41] = W) : W = e[41];
|
|
2088
|
+
const X = W;
|
|
2088
2089
|
let le;
|
|
2089
2090
|
e[42] !== t ? (le = (R) => R.measurements[t].unit, e[42] = t, e[43] = le) : le = e[43];
|
|
2090
|
-
const
|
|
2091
|
-
let
|
|
2092
|
-
e[44] !==
|
|
2093
|
-
const
|
|
2094
|
-
let
|
|
2095
|
-
e[47] !== C || e[48] !==
|
|
2096
|
-
C?.resetClickSequence(),
|
|
2097
|
-
}, e[47] = C, e[48] =
|
|
2098
|
-
const ie =
|
|
2091
|
+
const ee = z(le), ne = z(Or);
|
|
2092
|
+
let J;
|
|
2093
|
+
e[44] !== ne || e[45] !== t ? (J = (R) => ne(t, R), e[44] = ne, e[45] = t, e[46] = J) : J = e[46];
|
|
2094
|
+
const K = J;
|
|
2095
|
+
let te;
|
|
2096
|
+
e[47] !== C || e[48] !== X ? (te = () => {
|
|
2097
|
+
C?.resetClickSequence(), X([]);
|
|
2098
|
+
}, e[47] = C, e[48] = X, e[49] = te) : te = e[49];
|
|
2099
|
+
const ie = te;
|
|
2099
2100
|
let Me;
|
|
2100
2101
|
e[50] !== m ? (Me = (R) => {
|
|
2101
2102
|
m(R);
|
|
2102
2103
|
}, e[50] = m, e[51] = Me) : Me = e[51];
|
|
2103
2104
|
const Fe = Me;
|
|
2104
2105
|
let _e;
|
|
2105
|
-
return e[52] !== ie || e[53] !== f || e[54] !== l || e[55] !== S || e[56] !== A || e[57] !== O || e[58] !== C || e[59] !== w || e[60] !== s || e[61] !==
|
|
2106
|
+
return e[52] !== ie || e[53] !== f || e[54] !== l || e[55] !== S || e[56] !== A || e[57] !== O || e[58] !== C || e[59] !== w || e[60] !== s || e[61] !== $ || e[62] !== h || e[63] !== m || e[64] !== F || e[65] !== T || e[66] !== Z || e[67] !== D || e[68] !== X || e[69] !== K || e[70] !== Fe || e[71] !== ee || e[72] !== i ? (_e = {
|
|
2106
2107
|
modes: s,
|
|
2107
2108
|
units: i,
|
|
2108
2109
|
distance: l,
|
|
@@ -2112,19 +2113,19 @@ function xt(n) {
|
|
|
2112
2113
|
finished: A,
|
|
2113
2114
|
locale: O,
|
|
2114
2115
|
modeInstance: C,
|
|
2115
|
-
positions:
|
|
2116
|
-
unit:
|
|
2116
|
+
positions: $,
|
|
2117
|
+
unit: ee,
|
|
2117
2118
|
setDistance: h,
|
|
2118
|
-
setModeSelected:
|
|
2119
|
-
setFinished:
|
|
2119
|
+
setModeSelected: D,
|
|
2120
|
+
setFinished: F,
|
|
2120
2121
|
setLocale: T,
|
|
2121
|
-
setPositions:
|
|
2122
|
-
setUnit:
|
|
2122
|
+
setPositions: X,
|
|
2123
|
+
setUnit: K,
|
|
2123
2124
|
setEnabled: m,
|
|
2124
2125
|
toggleLayer: Fe,
|
|
2125
2126
|
clearLayer: ie,
|
|
2126
|
-
setModeInstance:
|
|
2127
|
-
}, e[52] = ie, e[53] = f, e[54] = l, e[55] = S, e[56] = A, e[57] = O, e[58] = C, e[59] = w, e[60] = s, e[61] =
|
|
2127
|
+
setModeInstance: Z
|
|
2128
|
+
}, e[52] = ie, e[53] = f, e[54] = l, e[55] = S, e[56] = A, e[57] = O, e[58] = C, e[59] = w, e[60] = s, e[61] = $, e[62] = h, e[63] = m, e[64] = F, e[65] = T, e[66] = Z, e[67] = D, e[68] = X, e[69] = K, e[70] = Fe, e[71] = ee, e[72] = i, e[73] = _e) : _e = e[73], _e;
|
|
2128
2129
|
}
|
|
2129
2130
|
function Or(n) {
|
|
2130
2131
|
return n.setUnit;
|
|
@@ -2178,10 +2179,10 @@ function Vr(n) {
|
|
|
2178
2179
|
setModeInstance: w,
|
|
2179
2180
|
positions: v,
|
|
2180
2181
|
setPositions: k,
|
|
2181
|
-
unit:
|
|
2182
|
-
setUnit:
|
|
2182
|
+
unit: D,
|
|
2183
|
+
setUnit: U,
|
|
2183
2184
|
clearLayer: A,
|
|
2184
|
-
toggleLayer:
|
|
2185
|
+
toggleLayer: V
|
|
2185
2186
|
} = xt(o);
|
|
2186
2187
|
let q;
|
|
2187
2188
|
e[2] !== h || e[3] !== i || e[4] !== w || e[5] !== k ? (q = () => {
|
|
@@ -2193,29 +2194,29 @@ function Vr(n) {
|
|
|
2193
2194
|
k([]);
|
|
2194
2195
|
};
|
|
2195
2196
|
}, e[2] = h, e[3] = i, e[4] = w, e[5] = k, e[6] = q) : q = e[6];
|
|
2196
|
-
let
|
|
2197
|
-
e[7] !== h || e[8] !== i || e[9] !== M || e[10] !== w || e[11] !== k ? (
|
|
2197
|
+
let F;
|
|
2198
|
+
e[7] !== h || e[8] !== i || e[9] !== M || e[10] !== w || e[11] !== k ? (F = [i, h, k, w, M], e[7] = h, e[8] = i, e[9] = M, e[10] = w, e[11] = k, e[12] = F) : F = e[12], Q(q, F);
|
|
2198
2199
|
let _;
|
|
2199
|
-
e[13] !==
|
|
2200
|
-
T && (p || !S) && A(),
|
|
2201
|
-
}, e[13] =
|
|
2200
|
+
e[13] !== V || e[14] !== A || e[15] !== p || e[16] !== S ? (_ = (T) => {
|
|
2201
|
+
T && (p || !S) && A(), V(T);
|
|
2202
|
+
}, e[13] = V, e[14] = A, e[15] = p, e[16] = S, e[17] = _) : _ = e[17];
|
|
2202
2203
|
const O = _, c = !!p;
|
|
2203
2204
|
let y;
|
|
2204
|
-
return e[18] !== s || e[19] !== A || e[20] !== l || e[21] !== f || e[22] !== S || e[23] !== u || e[24] !== t || e[25] !== g || e[26] !== h || e[27] !== i || e[28] !== v || e[29] !== d || e[30] !== M || e[31] !== L || e[32] !== m || e[33] !== b || e[34] !== k || e[35] !==
|
|
2205
|
+
return e[18] !== s || e[19] !== A || e[20] !== l || e[21] !== f || e[22] !== S || e[23] !== u || e[24] !== t || e[25] !== g || e[26] !== h || e[27] !== i || e[28] !== v || e[29] !== d || e[30] !== M || e[31] !== L || e[32] !== m || e[33] !== b || e[34] !== k || e[35] !== U || e[36] !== c || e[37] !== r || e[38] !== O || e[39] !== D || e[40] !== a ? (y = s({
|
|
2205
2206
|
mapId: t,
|
|
2206
2207
|
distance: l,
|
|
2207
2208
|
enabled: f,
|
|
2208
2209
|
finished: S,
|
|
2209
2210
|
locale: u,
|
|
2210
2211
|
positions: v,
|
|
2211
|
-
unit:
|
|
2212
|
+
unit: D,
|
|
2212
2213
|
clearLayerOnStart: c,
|
|
2213
2214
|
modeSelected: h,
|
|
2214
2215
|
modes: i,
|
|
2215
2216
|
units: a,
|
|
2216
2217
|
value: Ae({
|
|
2217
2218
|
meters: l,
|
|
2218
|
-
unit:
|
|
2219
|
+
unit: D,
|
|
2219
2220
|
locale: u,
|
|
2220
2221
|
options: r
|
|
2221
2222
|
}),
|
|
@@ -2225,11 +2226,11 @@ function Vr(n) {
|
|
|
2225
2226
|
setFinished: L,
|
|
2226
2227
|
setLocale: m,
|
|
2227
2228
|
setPositions: k,
|
|
2228
|
-
setUnit:
|
|
2229
|
+
setUnit: U,
|
|
2229
2230
|
setEnabled: M,
|
|
2230
2231
|
toggleLayer: O,
|
|
2231
2232
|
clearLayer: A
|
|
2232
|
-
}), e[18] = s, e[19] = A, e[20] = l, e[21] = f, e[22] = S, e[23] = u, e[24] = t, e[25] = g, e[26] = h, e[27] = i, e[28] = v, e[29] = d, e[30] = M, e[31] = L, e[32] = m, e[33] = b, e[34] = k, e[35] =
|
|
2233
|
+
}), e[18] = s, e[19] = A, e[20] = l, e[21] = f, e[22] = S, e[23] = u, e[24] = t, e[25] = g, e[26] = h, e[27] = i, e[28] = v, e[29] = d, e[30] = M, e[31] = L, e[32] = m, e[33] = b, e[34] = k, e[35] = U, e[36] = c, e[37] = r, e[38] = O, e[39] = D, e[40] = a, e[41] = y) : y = e[41], y;
|
|
2233
2234
|
}
|
|
2234
2235
|
const qr = [fe];
|
|
2235
2236
|
function jr(n) {
|
|
@@ -2261,77 +2262,77 @@ function jr(n) {
|
|
|
2261
2262
|
setPositions: u,
|
|
2262
2263
|
unit: m,
|
|
2263
2264
|
modeInstance: g
|
|
2264
|
-
} = xt(p), w = Se(
|
|
2265
|
-
let
|
|
2266
|
-
e[4] !== r ? (
|
|
2267
|
-
const
|
|
2268
|
-
let
|
|
2269
|
-
e[6] === Symbol.for("react.memo_cache_sentinel") ? (
|
|
2270
|
-
const
|
|
2271
|
-
let
|
|
2272
|
-
e[7] !== r ? (
|
|
2265
|
+
} = xt(p), w = Se(Gr), v = x(zr), k = x(Zr), D = x(Nr), U = x(Hr);
|
|
2266
|
+
let A;
|
|
2267
|
+
e[4] !== r ? (A = (I) => I.maps[r]?.layers.filter(Ir), e[4] = r, e[5] = A) : A = e[5];
|
|
2268
|
+
const V = x(vt(A)), q = x(Br);
|
|
2269
|
+
let F;
|
|
2270
|
+
e[6] === Symbol.for("react.memo_cache_sentinel") ? (F = {}, e[6] = F) : F = e[6];
|
|
2271
|
+
const _ = ke(F);
|
|
2272
|
+
let O;
|
|
2273
|
+
e[7] !== r ? (O = {
|
|
2273
2274
|
mapId: r,
|
|
2274
2275
|
layerId: fe
|
|
2275
|
-
}, e[7] = r, e[8] =
|
|
2276
|
-
let
|
|
2277
|
-
e[9] !==
|
|
2278
|
-
const I =
|
|
2279
|
-
return f && (
|
|
2276
|
+
}, e[7] = r, e[8] = O) : O = e[8], Ct(O);
|
|
2277
|
+
let c;
|
|
2278
|
+
e[9] !== D || e[10] !== f || e[11] !== v || e[12] !== r || e[13] !== U || e[14] !== k ? (c = () => {
|
|
2279
|
+
const I = v(r);
|
|
2280
|
+
return f && (D(r, [fe]), k(r, {
|
|
2280
2281
|
doubleClickZoom: !1
|
|
2281
2282
|
})), () => {
|
|
2282
|
-
|
|
2283
|
+
U(r, [fe]), k(r, I);
|
|
2283
2284
|
};
|
|
2284
|
-
}, e[9] =
|
|
2285
|
-
let
|
|
2286
|
-
e[16] !==
|
|
2287
|
-
let
|
|
2288
|
-
e[24] !== f || e[25] !==
|
|
2289
|
-
|
|
2290
|
-
const
|
|
2291
|
-
if (
|
|
2285
|
+
}, e[9] = D, e[10] = f, e[11] = v, e[12] = r, e[13] = U, e[14] = k, e[15] = c) : c = e[15];
|
|
2286
|
+
let y;
|
|
2287
|
+
e[16] !== D || e[17] !== b || e[18] !== f || e[19] !== v || e[20] !== r || e[21] !== U || e[22] !== k ? (y = [D, b, r, U, f, v, k], e[16] = D, e[17] = b, e[18] = f, e[19] = v, e[20] = r, e[21] = U, e[22] = k, e[23] = y) : y = e[23], Q(c, y);
|
|
2288
|
+
let T, P;
|
|
2289
|
+
e[24] !== f || e[25] !== q || e[26] !== r || e[27] !== V || e[28] !== w ? (T = () => {
|
|
2290
|
+
V?.forEach((I) => {
|
|
2291
|
+
const $ = q(r)?.props.layers.find((W) => W.props.id === I);
|
|
2292
|
+
if (!$)
|
|
2292
2293
|
return;
|
|
2293
|
-
f && (
|
|
2294
|
-
const
|
|
2294
|
+
f && (_.current[I] = $?.props.pickable);
|
|
2295
|
+
const H = !f && (_.current[I] ?? $?.props.pickable);
|
|
2295
2296
|
w(I, {
|
|
2296
2297
|
props: {
|
|
2297
|
-
pickable:
|
|
2298
|
+
pickable: H
|
|
2298
2299
|
}
|
|
2299
2300
|
});
|
|
2300
2301
|
});
|
|
2301
|
-
},
|
|
2302
|
-
let
|
|
2303
|
-
e[31] !== g || e[32] !== h || e[33] !== S || e[34] !== u ? (
|
|
2302
|
+
}, P = [f, q, r, V, w], e[24] = f, e[25] = q, e[26] = r, e[27] = V, e[28] = w, e[29] = T, e[30] = P) : (T = e[29], P = e[30]), Q(T, P);
|
|
2303
|
+
let C;
|
|
2304
|
+
e[31] !== g || e[32] !== h || e[33] !== S || e[34] !== u ? (C = (I) => {
|
|
2304
2305
|
const {
|
|
2305
|
-
editType:
|
|
2306
|
-
editContext:
|
|
2306
|
+
editType: $,
|
|
2307
|
+
editContext: H
|
|
2307
2308
|
} = I;
|
|
2308
|
-
if (
|
|
2309
|
+
if ($ === oe.cancel) {
|
|
2309
2310
|
g.resetClickSequence();
|
|
2310
2311
|
return;
|
|
2311
2312
|
}
|
|
2312
|
-
|
|
2313
|
-
const
|
|
2314
|
-
|
|
2315
|
-
}, e[31] = g, e[32] = h, e[33] = S, e[34] = u, e[35] =
|
|
2316
|
-
const
|
|
2317
|
-
let
|
|
2318
|
-
return e[36] !== f || e[37] !== M || e[38] !== o || e[39] !== L || e[40] !== g || e[41] !==
|
|
2319
|
-
const I = M ? d.colors.finished : d.colors.editing,
|
|
2313
|
+
$ === oe.addPosition && h(H.distance), S(!!H.finished);
|
|
2314
|
+
const W = H.positions;
|
|
2315
|
+
W?.length && u(W);
|
|
2316
|
+
}, e[31] = g, e[32] = h, e[33] = S, e[34] = u, e[35] = C) : C = e[35];
|
|
2317
|
+
const E = C;
|
|
2318
|
+
let B, Z;
|
|
2319
|
+
return e[36] !== f || e[37] !== M || e[38] !== o || e[39] !== L || e[40] !== g || e[41] !== E || e[42] !== w || e[43] !== d.colors.editing || e[44] !== d.colors.finished || e[45] !== d.colors.point || e[46] !== i || e[47] !== m ? (B = () => {
|
|
2320
|
+
const I = M ? d.colors.finished : d.colors.editing, $ = M ? d.colors.finished : d.colors.point, H = Lr({
|
|
2320
2321
|
layerProps: {
|
|
2321
2322
|
...o,
|
|
2322
2323
|
pickable: o?.pickable ?? !M
|
|
2323
2324
|
},
|
|
2324
2325
|
enabled: f,
|
|
2325
2326
|
guideColor: I,
|
|
2326
|
-
pointColor:
|
|
2327
|
+
pointColor: $,
|
|
2327
2328
|
locale: L,
|
|
2328
|
-
onEdit:
|
|
2329
|
+
onEdit: E,
|
|
2329
2330
|
unit: m,
|
|
2330
2331
|
mode: g,
|
|
2331
2332
|
textOptions: i
|
|
2332
2333
|
});
|
|
2333
|
-
w(fe,
|
|
2334
|
-
},
|
|
2334
|
+
w(fe, H);
|
|
2335
|
+
}, Z = [M, g, o, L, E, w, d.colors.editing, d.colors.finished, d.colors.point, i, m, f], e[36] = f, e[37] = M, e[38] = o, e[39] = L, e[40] = g, e[41] = E, e[42] = w, e[43] = d.colors.editing, e[44] = d.colors.finished, e[45] = d.colors.point, e[46] = i, e[47] = m, e[48] = B, e[49] = Z) : (B = e[48], Z = e[49]), Q(B, Z), t;
|
|
2335
2336
|
}
|
|
2336
2337
|
function Br(n) {
|
|
2337
2338
|
return n.getDeckInstance;
|
|
@@ -2349,10 +2350,13 @@ function Zr(n) {
|
|
|
2349
2350
|
return n.setController;
|
|
2350
2351
|
}
|
|
2351
2352
|
function zr(n) {
|
|
2353
|
+
return n.getController;
|
|
2354
|
+
}
|
|
2355
|
+
function Gr(n) {
|
|
2352
2356
|
return n.setLayer;
|
|
2353
2357
|
}
|
|
2354
2358
|
jr.Controls = Vr;
|
|
2355
|
-
function
|
|
2359
|
+
function Wr(n) {
|
|
2356
2360
|
const e = j(7), {
|
|
2357
2361
|
mapId: t
|
|
2358
2362
|
} = n;
|
|
@@ -2360,19 +2364,19 @@ function Gr(n) {
|
|
|
2360
2364
|
e[0] !== t ? (r = (l) => l.maps[t], e[0] = t, e[1] = r) : r = e[1];
|
|
2361
2365
|
const {
|
|
2362
2366
|
layers: s
|
|
2363
|
-
} = x(r), o = Se(
|
|
2367
|
+
} = x(r), o = Se(Yr);
|
|
2364
2368
|
let i;
|
|
2365
2369
|
if (e[2] !== o || e[3] !== s) {
|
|
2366
2370
|
let l;
|
|
2367
|
-
e[5] !== o ? (l = (d) => o[d], e[5] = o, e[6] = l) : l = e[6], i = s.map(l).filter(
|
|
2371
|
+
e[5] !== o ? (l = (d) => o[d], e[5] = o, e[6] = l) : l = e[6], i = s.map(l).filter(Kr), e[2] = o, e[3] = s, e[4] = i;
|
|
2368
2372
|
} else
|
|
2369
2373
|
i = e[4];
|
|
2370
2374
|
return i;
|
|
2371
2375
|
}
|
|
2372
|
-
function
|
|
2376
|
+
function Kr(n) {
|
|
2373
2377
|
return !!n;
|
|
2374
2378
|
}
|
|
2375
|
-
function
|
|
2379
|
+
function Yr(n) {
|
|
2376
2380
|
return n.layers;
|
|
2377
2381
|
}
|
|
2378
2382
|
const ut = [Oe, he, fe];
|
|
@@ -2380,8 +2384,8 @@ function $t(n) {
|
|
|
2380
2384
|
const e = n.filter((r) => !ut.includes(r.props.id)).sort((r, s) => (r.order ?? 1 / 0) - (s.order ?? 1 / 0)), t = ut.map((r) => n.find((s) => s.props.id === r)).filter((r) => !!r);
|
|
2381
2385
|
return [...e, ...t];
|
|
2382
2386
|
}
|
|
2383
|
-
const
|
|
2384
|
-
function
|
|
2387
|
+
const Jr = 200;
|
|
2388
|
+
function vo(n) {
|
|
2385
2389
|
const e = j(51);
|
|
2386
2390
|
let t, r, s, o;
|
|
2387
2391
|
e[0] !== n ? ({
|
|
@@ -2404,36 +2408,36 @@ function So(n) {
|
|
|
2404
2408
|
const M = x(f);
|
|
2405
2409
|
let S;
|
|
2406
2410
|
e[13] !== t ? (S = (E) => E.maps[t].controller, e[13] = t, e[14] = S) : S = e[14];
|
|
2407
|
-
const L = x(S), u = x(
|
|
2411
|
+
const L = x(S), u = x(rs), m = x(ns), g = x(ts), w = x(es), v = x(Xr);
|
|
2408
2412
|
let k;
|
|
2409
2413
|
e[15] !== t ? (k = {
|
|
2410
2414
|
mapId: t
|
|
2411
2415
|
}, e[15] = t, e[16] = k) : k = e[16];
|
|
2412
|
-
const
|
|
2416
|
+
const D = Wr(k);
|
|
2417
|
+
let U;
|
|
2418
|
+
e[17] !== D ? (U = $t(D), e[17] = D, e[18] = U) : U = e[18];
|
|
2419
|
+
const A = U;
|
|
2413
2420
|
let V;
|
|
2414
|
-
e[
|
|
2415
|
-
const A = V;
|
|
2416
|
-
let $;
|
|
2417
|
-
e[19] !== t || e[20] !== s || e[21] !== m || e[22] !== v ? ($ = (E) => {
|
|
2421
|
+
e[19] !== t || e[20] !== s || e[21] !== m || e[22] !== v ? (V = (E) => {
|
|
2418
2422
|
const B = m;
|
|
2419
2423
|
if (b.current && clearInterval(b.current), b.current = setTimeout(() => {
|
|
2420
2424
|
v(t);
|
|
2421
|
-
},
|
|
2425
|
+
}, Jr), s) {
|
|
2422
2426
|
s(E, B);
|
|
2423
2427
|
return;
|
|
2424
2428
|
}
|
|
2425
2429
|
B(t, E.viewState);
|
|
2426
|
-
}, e[19] = t, e[20] = s, e[21] = m, e[22] = v, e[23] =
|
|
2427
|
-
const q =
|
|
2428
|
-
let
|
|
2429
|
-
e[24] !== t || e[25] !== r || e[26] !== g || e[27] !== v ? (
|
|
2430
|
+
}, e[19] = t, e[20] = s, e[21] = m, e[22] = v, e[23] = V) : V = e[23];
|
|
2431
|
+
const q = V;
|
|
2432
|
+
let F;
|
|
2433
|
+
e[24] !== t || e[25] !== r || e[26] !== g || e[27] !== v ? (F = (E) => {
|
|
2430
2434
|
g(t, E), r?.(E), v(t);
|
|
2431
|
-
}, e[24] = t, e[25] = r, e[26] = g, e[27] = v, e[28] =
|
|
2432
|
-
const _ =
|
|
2435
|
+
}, e[24] = t, e[25] = r, e[26] = g, e[27] = v, e[28] = F) : F = e[28];
|
|
2436
|
+
const _ = F;
|
|
2433
2437
|
let O;
|
|
2434
2438
|
e[29] !== u || e[30] !== t || e[31] !== o || e[32] !== w ? (O = (E) => {
|
|
2435
|
-
const
|
|
2436
|
-
w(t,
|
|
2439
|
+
const Z = !!u(t)?.props.layers?.every(Qr);
|
|
2440
|
+
w(t, Z), o.onAfterRender?.(E);
|
|
2437
2441
|
}, e[29] = u, e[30] = t, e[31] = o, e[32] = w, e[33] = O) : O = e[33];
|
|
2438
2442
|
const c = O, y = o.onDragEnd;
|
|
2439
2443
|
let T;
|
|
@@ -2445,26 +2449,26 @@ function So(n) {
|
|
|
2445
2449
|
let C;
|
|
2446
2450
|
return e[38] !== a || e[39] !== A || e[40] !== L || e[41] !== c || e[42] !== P || e[43] !== _ || e[44] !== q || e[45] !== t || e[46] !== d || e[47] !== h || e[48] !== o || e[49] !== M ? (C = /* @__PURE__ */ G(Bn, { ...o, controller: L, id: t, layers: A, instanceRef: d, overlayRef: h, basemap: a, initialViewState: M, onLoad: _, onViewStateChange: q, onAfterRender: c, onDragEnd: P }), e[38] = a, e[39] = A, e[40] = L, e[41] = c, e[42] = P, e[43] = _, e[44] = q, e[45] = t, e[46] = d, e[47] = h, e[48] = o, e[49] = M, e[50] = C) : C = e[50], C;
|
|
2447
2451
|
}
|
|
2448
|
-
function
|
|
2452
|
+
function Qr(n) {
|
|
2449
2453
|
return n?.isLoaded;
|
|
2450
2454
|
}
|
|
2451
|
-
function
|
|
2455
|
+
function Xr(n) {
|
|
2452
2456
|
return n.updateViewPort;
|
|
2453
2457
|
}
|
|
2454
|
-
function
|
|
2458
|
+
function es(n) {
|
|
2455
2459
|
return n.setLayersLoad;
|
|
2456
2460
|
}
|
|
2457
|
-
function
|
|
2461
|
+
function ts(n) {
|
|
2458
2462
|
return n.setLoad;
|
|
2459
2463
|
}
|
|
2460
|
-
function
|
|
2464
|
+
function ns(n) {
|
|
2461
2465
|
return n.setViewState;
|
|
2462
2466
|
}
|
|
2463
|
-
function
|
|
2467
|
+
function rs(n) {
|
|
2464
2468
|
return n.getDeckInstance;
|
|
2465
2469
|
}
|
|
2466
2470
|
var Le = { exports: {} }, dt;
|
|
2467
|
-
function
|
|
2471
|
+
function ss() {
|
|
2468
2472
|
return dt || (dt = 1, (function(n, e) {
|
|
2469
2473
|
var t = typeof globalThis < "u" && globalThis || typeof self < "u" && self || typeof Ee < "u" && Ee, r = (function() {
|
|
2470
2474
|
function o() {
|
|
@@ -2641,15 +2645,15 @@ function rs() {
|
|
|
2641
2645
|
throw new Error("could not read FormData body as text");
|
|
2642
2646
|
return Promise.resolve(this._bodyText);
|
|
2643
2647
|
}, l.formData && (this.formData = function() {
|
|
2644
|
-
return this.text().then(
|
|
2648
|
+
return this.text().then(V);
|
|
2645
2649
|
}), this.json = function() {
|
|
2646
2650
|
return this.text().then(JSON.parse);
|
|
2647
2651
|
}, this;
|
|
2648
2652
|
}
|
|
2649
|
-
var
|
|
2650
|
-
function
|
|
2653
|
+
var D = ["CONNECT", "DELETE", "GET", "HEAD", "OPTIONS", "PATCH", "POST", "PUT", "TRACE"];
|
|
2654
|
+
function U(c) {
|
|
2651
2655
|
var y = c.toUpperCase();
|
|
2652
|
-
return
|
|
2656
|
+
return D.indexOf(y) > -1 ? y : c;
|
|
2653
2657
|
}
|
|
2654
2658
|
function A(c, y) {
|
|
2655
2659
|
if (!(this instanceof A))
|
|
@@ -2662,7 +2666,7 @@ function rs() {
|
|
|
2662
2666
|
this.url = c.url, this.credentials = c.credentials, y.headers || (this.headers = new S(c.headers)), this.method = c.method, this.mode = c.mode, this.signal = c.signal, !T && c._bodyInit != null && (T = c._bodyInit, c.bodyUsed = !0);
|
|
2663
2667
|
} else
|
|
2664
2668
|
this.url = String(c);
|
|
2665
|
-
if (this.credentials = y.credentials || this.credentials || "same-origin", (y.headers || !this.headers) && (this.headers = new S(y.headers)), this.method =
|
|
2669
|
+
if (this.credentials = y.credentials || this.credentials || "same-origin", (y.headers || !this.headers) && (this.headers = new S(y.headers)), this.method = U(y.method || this.method || "GET"), this.mode = y.mode || this.mode || null, this.signal = y.signal || this.signal || (function() {
|
|
2666
2670
|
if ("AbortController" in a) {
|
|
2667
2671
|
var E = new AbortController();
|
|
2668
2672
|
return E.signal;
|
|
@@ -2682,7 +2686,7 @@ function rs() {
|
|
|
2682
2686
|
A.prototype.clone = function() {
|
|
2683
2687
|
return new A(this, { body: this._bodyInit });
|
|
2684
2688
|
};
|
|
2685
|
-
function
|
|
2689
|
+
function V(c) {
|
|
2686
2690
|
var y = new FormData();
|
|
2687
2691
|
return c.trim().split("&").forEach(function(T) {
|
|
2688
2692
|
if (T) {
|
|
@@ -2702,36 +2706,36 @@ function rs() {
|
|
|
2702
2706
|
var B = C.join(":").trim();
|
|
2703
2707
|
try {
|
|
2704
2708
|
y.append(E, B);
|
|
2705
|
-
} catch (
|
|
2706
|
-
console.warn("Response " +
|
|
2709
|
+
} catch (Z) {
|
|
2710
|
+
console.warn("Response " + Z.message);
|
|
2707
2711
|
}
|
|
2708
2712
|
}
|
|
2709
2713
|
}), y;
|
|
2710
2714
|
}
|
|
2711
2715
|
k.call(A.prototype);
|
|
2712
|
-
function
|
|
2713
|
-
if (!(this instanceof
|
|
2716
|
+
function F(c, y) {
|
|
2717
|
+
if (!(this instanceof F))
|
|
2714
2718
|
throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');
|
|
2715
2719
|
if (y || (y = {}), this.type = "default", this.status = y.status === void 0 ? 200 : y.status, this.status < 200 || this.status > 599)
|
|
2716
2720
|
throw new RangeError("Failed to construct 'Response': The status provided (0) is outside the range [200, 599].");
|
|
2717
2721
|
this.ok = this.status >= 200 && this.status < 300, this.statusText = y.statusText === void 0 ? "" : "" + y.statusText, this.headers = new S(y.headers), this.url = y.url || "", this._initBody(c);
|
|
2718
2722
|
}
|
|
2719
|
-
k.call(
|
|
2720
|
-
return new
|
|
2723
|
+
k.call(F.prototype), F.prototype.clone = function() {
|
|
2724
|
+
return new F(this._bodyInit, {
|
|
2721
2725
|
status: this.status,
|
|
2722
2726
|
statusText: this.statusText,
|
|
2723
2727
|
headers: new S(this.headers),
|
|
2724
2728
|
url: this.url
|
|
2725
2729
|
});
|
|
2726
|
-
},
|
|
2727
|
-
var c = new
|
|
2730
|
+
}, F.error = function() {
|
|
2731
|
+
var c = new F(null, { status: 200, statusText: "" });
|
|
2728
2732
|
return c.ok = !1, c.status = 0, c.type = "error", c;
|
|
2729
2733
|
};
|
|
2730
2734
|
var _ = [301, 302, 303, 307, 308];
|
|
2731
|
-
|
|
2735
|
+
F.redirect = function(c, y) {
|
|
2732
2736
|
if (_.indexOf(y) === -1)
|
|
2733
2737
|
throw new RangeError("Invalid status code");
|
|
2734
|
-
return new
|
|
2738
|
+
return new F(null, { status: y, headers: { location: c } });
|
|
2735
2739
|
}, i.DOMException = a.DOMException;
|
|
2736
2740
|
try {
|
|
2737
2741
|
new i.DOMException();
|
|
@@ -2752,14 +2756,14 @@ function rs() {
|
|
|
2752
2756
|
E.abort();
|
|
2753
2757
|
}
|
|
2754
2758
|
E.onload = function() {
|
|
2755
|
-
var
|
|
2759
|
+
var $ = {
|
|
2756
2760
|
statusText: E.statusText,
|
|
2757
2761
|
headers: q(E.getAllResponseHeaders() || "")
|
|
2758
2762
|
};
|
|
2759
|
-
C.url.indexOf("file://") === 0 && (E.status < 200 || E.status > 599) ?
|
|
2760
|
-
var
|
|
2763
|
+
C.url.indexOf("file://") === 0 && (E.status < 200 || E.status > 599) ? $.status = 200 : $.status = E.status, $.url = "responseURL" in E ? E.responseURL : $.headers.get("X-Request-URL");
|
|
2764
|
+
var H = "response" in E ? E.response : E.responseText;
|
|
2761
2765
|
setTimeout(function() {
|
|
2762
|
-
T(new
|
|
2766
|
+
T(new F(H, $));
|
|
2763
2767
|
}, 0);
|
|
2764
2768
|
}, E.onerror = function() {
|
|
2765
2769
|
setTimeout(function() {
|
|
@@ -2774,57 +2778,57 @@ function rs() {
|
|
|
2774
2778
|
P(new i.DOMException("Aborted", "AbortError"));
|
|
2775
2779
|
}, 0);
|
|
2776
2780
|
};
|
|
2777
|
-
function
|
|
2781
|
+
function Z($) {
|
|
2778
2782
|
try {
|
|
2779
|
-
return
|
|
2783
|
+
return $ === "" && a.location.href ? a.location.href : $;
|
|
2780
2784
|
} catch {
|
|
2781
|
-
return
|
|
2785
|
+
return $;
|
|
2782
2786
|
}
|
|
2783
2787
|
}
|
|
2784
|
-
if (E.open(C.method,
|
|
2785
|
-
var
|
|
2786
|
-
Object.getOwnPropertyNames(y.headers).forEach(function(
|
|
2787
|
-
|
|
2788
|
-
}), C.headers.forEach(function(
|
|
2789
|
-
|
|
2788
|
+
if (E.open(C.method, Z(C.url), !0), C.credentials === "include" ? E.withCredentials = !0 : C.credentials === "omit" && (E.withCredentials = !1), "responseType" in E && (l.blob ? E.responseType = "blob" : l.arrayBuffer && (E.responseType = "arraybuffer")), y && typeof y.headers == "object" && !(y.headers instanceof S || a.Headers && y.headers instanceof a.Headers)) {
|
|
2789
|
+
var I = [];
|
|
2790
|
+
Object.getOwnPropertyNames(y.headers).forEach(function($) {
|
|
2791
|
+
I.push(b($)), E.setRequestHeader($, f(y.headers[$]));
|
|
2792
|
+
}), C.headers.forEach(function($, H) {
|
|
2793
|
+
I.indexOf(H) === -1 && E.setRequestHeader(H, $);
|
|
2790
2794
|
});
|
|
2791
2795
|
} else
|
|
2792
|
-
C.headers.forEach(function(
|
|
2793
|
-
E.setRequestHeader(
|
|
2796
|
+
C.headers.forEach(function($, H) {
|
|
2797
|
+
E.setRequestHeader(H, $);
|
|
2794
2798
|
});
|
|
2795
2799
|
C.signal && (C.signal.addEventListener("abort", B), E.onreadystatechange = function() {
|
|
2796
2800
|
E.readyState === 4 && C.signal.removeEventListener("abort", B);
|
|
2797
2801
|
}), E.send(typeof C._bodyInit > "u" ? null : C._bodyInit);
|
|
2798
2802
|
});
|
|
2799
2803
|
}
|
|
2800
|
-
return O.polyfill = !0, a.fetch || (a.fetch = O, a.Headers = S, a.Request = A, a.Response =
|
|
2804
|
+
return O.polyfill = !0, a.fetch || (a.fetch = O, a.Headers = S, a.Request = A, a.Response = F), i.Headers = S, i.Request = A, i.Response = F, i.fetch = O, i;
|
|
2801
2805
|
})({});
|
|
2802
2806
|
})(r), r.fetch.ponyfill = !0, delete r.fetch.polyfill;
|
|
2803
2807
|
var s = t.fetch ? t : r;
|
|
2804
2808
|
e = s.fetch, e.default = s.fetch, e.fetch = s.fetch, e.Headers = s.Headers, e.Request = s.Request, e.Response = s.Response, n.exports = e;
|
|
2805
2809
|
})(Le, Le.exports)), Le.exports;
|
|
2806
2810
|
}
|
|
2807
|
-
var
|
|
2808
|
-
const
|
|
2811
|
+
var os = ss();
|
|
2812
|
+
const is = /* @__PURE__ */ Tt(os), Ke = "https://gcp-us-east1.api.carto.com", Ye = "v3", as = "ps", be = {
|
|
2809
2813
|
get: "GET",
|
|
2810
2814
|
post: "POST"
|
|
2811
2815
|
};
|
|
2812
|
-
function
|
|
2816
|
+
function ls(n, e) {
|
|
2813
2817
|
return Array.isArray(e) ? `${n}=${encodeURIComponent(JSON.stringify(e))}` : e == null || e === "" ? "" : typeof e == "object" ? `${n}=${encodeURIComponent(JSON.stringify(e))}` : `${n}=${encodeURIComponent(e)}`;
|
|
2814
2818
|
}
|
|
2815
|
-
function
|
|
2819
|
+
function cs({
|
|
2816
2820
|
params: n,
|
|
2817
2821
|
url: e
|
|
2818
2822
|
}) {
|
|
2819
2823
|
if (!n) return e;
|
|
2820
|
-
const t = Object.entries(n).map(([r, s]) =>
|
|
2824
|
+
const t = Object.entries(n).map(([r, s]) => ls(r, s));
|
|
2821
2825
|
return `${e}?${t.filter(Boolean).join("&")}`;
|
|
2822
2826
|
}
|
|
2823
|
-
function
|
|
2827
|
+
function us(n) {
|
|
2824
2828
|
return n && n.__esModule && Object.prototype.hasOwnProperty.call(n, "default") ? n.default : n;
|
|
2825
2829
|
}
|
|
2826
2830
|
var qe, ft;
|
|
2827
|
-
function
|
|
2831
|
+
function ds() {
|
|
2828
2832
|
if (ft) return qe;
|
|
2829
2833
|
ft = 1;
|
|
2830
2834
|
var n = function(u) {
|
|
@@ -2897,8 +2901,8 @@ function us() {
|
|
|
2897
2901
|
var L = S;
|
|
2898
2902
|
return qe = L, qe;
|
|
2899
2903
|
}
|
|
2900
|
-
var
|
|
2901
|
-
const Je = /* @__PURE__ */
|
|
2904
|
+
var fs = ds();
|
|
2905
|
+
const Je = /* @__PURE__ */ us(fs);
|
|
2902
2906
|
function pt(n) {
|
|
2903
2907
|
return Je({
|
|
2904
2908
|
method: be.get,
|
|
@@ -2917,21 +2921,21 @@ function je(n, e) {
|
|
|
2917
2921
|
body: JSON.stringify(e)
|
|
2918
2922
|
}, n);
|
|
2919
2923
|
}
|
|
2920
|
-
const
|
|
2924
|
+
const ps = {
|
|
2921
2925
|
GET: pt,
|
|
2922
2926
|
POST: je,
|
|
2923
2927
|
PUT: je,
|
|
2924
2928
|
PATCH: je,
|
|
2925
2929
|
DELETE: pt
|
|
2926
2930
|
};
|
|
2927
|
-
function
|
|
2931
|
+
function ms({
|
|
2928
2932
|
body: n,
|
|
2929
2933
|
accessToken: e,
|
|
2930
2934
|
method: t,
|
|
2931
2935
|
...r
|
|
2932
2936
|
}) {
|
|
2933
2937
|
let s = e;
|
|
2934
|
-
return s && !s.includes("Bearer") && (s = "Bearer " + s),
|
|
2938
|
+
return s && !s.includes("Bearer") && (s = "Bearer " + s), ps[t](Je({
|
|
2935
2939
|
method: t,
|
|
2936
2940
|
headers: {
|
|
2937
2941
|
...!!s && {
|
|
@@ -2940,7 +2944,7 @@ function ps({
|
|
|
2940
2944
|
}
|
|
2941
2945
|
}, r), n);
|
|
2942
2946
|
}
|
|
2943
|
-
const
|
|
2947
|
+
const ys = 6144;
|
|
2944
2948
|
async function Ut({
|
|
2945
2949
|
signal: n,
|
|
2946
2950
|
body: e,
|
|
@@ -2952,23 +2956,23 @@ async function Ut({
|
|
|
2952
2956
|
requestOptions: {
|
|
2953
2957
|
getMaxUrlLength: a
|
|
2954
2958
|
} = {
|
|
2955
|
-
getMaxUrlLength:
|
|
2959
|
+
getMaxUrlLength: ys
|
|
2956
2960
|
},
|
|
2957
2961
|
...l
|
|
2958
2962
|
}) {
|
|
2959
|
-
let d =
|
|
2963
|
+
let d = cs({
|
|
2960
2964
|
url: i,
|
|
2961
2965
|
params: o
|
|
2962
2966
|
}), p = e, h = s;
|
|
2963
2967
|
s === be.get && d.length > a && (p = o, h = be.post, d = i);
|
|
2964
|
-
const b =
|
|
2968
|
+
const b = ms({
|
|
2965
2969
|
body: p,
|
|
2966
2970
|
accessToken: t ?? r?.accessToken,
|
|
2967
2971
|
method: h,
|
|
2968
2972
|
...l
|
|
2969
2973
|
});
|
|
2970
2974
|
n && (b.signal = n);
|
|
2971
|
-
const f = await
|
|
2975
|
+
const f = await is(d, b);
|
|
2972
2976
|
if (!f.ok) {
|
|
2973
2977
|
const M = await f.text();
|
|
2974
2978
|
throw new Error(M);
|
|
@@ -2985,12 +2989,12 @@ const Pe = gt()(kn((n, e) => ({
|
|
|
2985
2989
|
i && (i.destroy(), delete o[t].widgets);
|
|
2986
2990
|
const a = o[t], l = {
|
|
2987
2991
|
apiBaseUrl: Ke,
|
|
2988
|
-
clientId:
|
|
2992
|
+
clientId: as,
|
|
2989
2993
|
apiVersion: Ye,
|
|
2990
2994
|
...a,
|
|
2991
2995
|
...r
|
|
2992
2996
|
};
|
|
2993
|
-
return l.widgets =
|
|
2997
|
+
return l.widgets = Ss({
|
|
2994
2998
|
source: l
|
|
2995
2999
|
}), o[t] = l, {
|
|
2996
3000
|
sources: o
|
|
@@ -3052,17 +3056,17 @@ const Pe = gt()(kn((n, e) => ({
|
|
|
3052
3056
|
}, r);
|
|
3053
3057
|
}
|
|
3054
3058
|
})));
|
|
3055
|
-
function
|
|
3059
|
+
function hs(n) {
|
|
3056
3060
|
const e = j(2);
|
|
3057
3061
|
let t;
|
|
3058
3062
|
return e[0] !== n ? (t = (r) => r.sources[n], e[0] = n, e[1] = t) : t = e[1], Pe(t);
|
|
3059
3063
|
}
|
|
3060
|
-
function
|
|
3064
|
+
function gs(n) {
|
|
3061
3065
|
const e = j(2);
|
|
3062
3066
|
let t;
|
|
3063
3067
|
return e[0] !== n ? (t = (r) => r.filters[n], e[0] = n, e[1] = t) : t = e[1], Pe(t);
|
|
3064
3068
|
}
|
|
3065
|
-
function
|
|
3069
|
+
function wo(n) {
|
|
3066
3070
|
const e = j(9);
|
|
3067
3071
|
let t;
|
|
3068
3072
|
e[0] !== n ? (t = (a) => a.sources[n], e[0] = n, e[1] = t) : t = e[1];
|
|
@@ -3086,26 +3090,26 @@ function vo(n) {
|
|
|
3086
3090
|
}
|
|
3087
3091
|
return i;
|
|
3088
3092
|
}
|
|
3089
|
-
function
|
|
3093
|
+
function Mo(n, {
|
|
3090
3094
|
column: e,
|
|
3091
3095
|
type: t
|
|
3092
3096
|
}) {
|
|
3093
3097
|
return n?.[e]?.[t]?.values ?? [];
|
|
3094
3098
|
}
|
|
3095
|
-
function
|
|
3099
|
+
function bs(n) {
|
|
3096
3100
|
const [, e] = n.type.split("+", 2);
|
|
3097
3101
|
return {
|
|
3098
3102
|
spatialDataType: n.spatialDataType ?? e ?? "geo",
|
|
3099
3103
|
spatialDataColumn: n.spatialDataColumn ?? e ?? "geom"
|
|
3100
3104
|
};
|
|
3101
3105
|
}
|
|
3102
|
-
function
|
|
3106
|
+
function Ss({
|
|
3103
3107
|
source: n
|
|
3104
3108
|
}) {
|
|
3105
3109
|
const {
|
|
3106
3110
|
spatialDataType: e,
|
|
3107
3111
|
spatialDataColumn: t
|
|
3108
|
-
} =
|
|
3112
|
+
} = bs(n), r = {
|
|
3109
3113
|
query: () => {
|
|
3110
3114
|
const i = n;
|
|
3111
3115
|
return new En({
|
|
@@ -3153,8 +3157,8 @@ function bs({
|
|
|
3153
3157
|
}, s = n.type.split("+")[0], o = r[s];
|
|
3154
3158
|
return o?.();
|
|
3155
3159
|
}
|
|
3156
|
-
function
|
|
3157
|
-
const t = j(5), r =
|
|
3160
|
+
function vs(n, e) {
|
|
3161
|
+
const t = j(5), r = gs(n);
|
|
3158
3162
|
let s;
|
|
3159
3163
|
e: {
|
|
3160
3164
|
if (!e?.length) {
|
|
@@ -3163,12 +3167,12 @@ function Ss(n, e) {
|
|
|
3163
3167
|
}
|
|
3164
3168
|
if (!r) {
|
|
3165
3169
|
let i;
|
|
3166
|
-
t[0] !== e ? (i = e.reduce(
|
|
3170
|
+
t[0] !== e ? (i = e.reduce(Ms, {}), t[0] = e, t[1] = i) : i = t[1], s = i;
|
|
3167
3171
|
break e;
|
|
3168
3172
|
}
|
|
3169
3173
|
let o;
|
|
3170
3174
|
if (t[2] !== e || t[3] !== r) {
|
|
3171
|
-
const i = e.reduce(
|
|
3175
|
+
const i = e.reduce(ws, {});
|
|
3172
3176
|
o = me(r, i), t[2] = e, t[3] = r, t[4] = o;
|
|
3173
3177
|
} else
|
|
3174
3178
|
o = t[4];
|
|
@@ -3176,43 +3180,43 @@ function Ss(n, e) {
|
|
|
3176
3180
|
}
|
|
3177
3181
|
return s;
|
|
3178
3182
|
}
|
|
3179
|
-
function vs(n, e) {
|
|
3180
|
-
return We(n, e);
|
|
3181
|
-
}
|
|
3182
3183
|
function ws(n, e) {
|
|
3183
3184
|
return We(n, e);
|
|
3184
3185
|
}
|
|
3185
3186
|
function Ms(n, e) {
|
|
3186
|
-
|
|
3187
|
+
return We(n, e);
|
|
3188
|
+
}
|
|
3189
|
+
function _s(n, e) {
|
|
3190
|
+
const t = hs(e);
|
|
3187
3191
|
return ge(() => {
|
|
3188
3192
|
const r = t?.widgets;
|
|
3189
3193
|
return !r || !n ? null : (r.props.accessToken = n, r);
|
|
3190
3194
|
}, [n, t]);
|
|
3191
3195
|
}
|
|
3192
|
-
const
|
|
3193
|
-
function
|
|
3196
|
+
const Es = ["authorization", "cache-control"];
|
|
3197
|
+
function Ts(n) {
|
|
3194
3198
|
if (!n || typeof n != "object")
|
|
3195
3199
|
return "";
|
|
3196
3200
|
const e = {};
|
|
3197
3201
|
for (const [t, r] of Object.entries(n)) {
|
|
3198
3202
|
const s = t.toLowerCase();
|
|
3199
|
-
|
|
3203
|
+
Es.includes(s) && (e[s] = r);
|
|
3200
3204
|
}
|
|
3201
3205
|
return Object.keys(e).length > 0 ? JSON.stringify(e) : "";
|
|
3202
3206
|
}
|
|
3203
|
-
function
|
|
3207
|
+
function Ls(n) {
|
|
3204
3208
|
const e = j(12), {
|
|
3205
3209
|
accessToken: t,
|
|
3206
3210
|
sourceId: r,
|
|
3207
3211
|
widgetProps: s,
|
|
3208
3212
|
additionalFilter: o
|
|
3209
|
-
} = n, i =
|
|
3213
|
+
} = n, i = vs(r, o), a = _s(t, r);
|
|
3210
3214
|
let l;
|
|
3211
3215
|
if (e[0] !== t || e[1] !== i || e[2] !== r || e[3] !== a || e[4] !== s) {
|
|
3212
3216
|
l = [r, s], a?.props && "queryParameters" in a.props && a.props.queryParameters && l.push(a.props.queryParameters), i && l.push(i);
|
|
3213
3217
|
const h = a?.props.headers;
|
|
3214
3218
|
let b;
|
|
3215
|
-
e[6] !== h ? (b =
|
|
3219
|
+
e[6] !== h ? (b = Ts(h), e[6] = h, e[7] = b) : b = e[7];
|
|
3216
3220
|
const f = b;
|
|
3217
3221
|
f && l.push(f), l.push(t), e[0] = t, e[1] = i, e[2] = r, e[3] = a, e[4] = s, e[5] = l;
|
|
3218
3222
|
} else
|
|
@@ -3256,20 +3260,20 @@ function de({
|
|
|
3256
3260
|
mergedFilters: L,
|
|
3257
3261
|
queryKey: u,
|
|
3258
3262
|
widgetModel: m
|
|
3259
|
-
} =
|
|
3263
|
+
} = Ls(S);
|
|
3260
3264
|
let g;
|
|
3261
3265
|
o[10] !== u ? (g = [...n, ...u], o[10] = u, o[11] = g) : g = o[11];
|
|
3262
3266
|
let w;
|
|
3263
|
-
o[12] !== L || o[13] !== m || o[14] !== l ? (w = (
|
|
3267
|
+
o[12] !== L || o[13] !== m || o[14] !== l ? (w = (D) => {
|
|
3264
3268
|
const {
|
|
3265
|
-
signal:
|
|
3266
|
-
} =
|
|
3269
|
+
signal: U
|
|
3270
|
+
} = D;
|
|
3267
3271
|
if (!m)
|
|
3268
3272
|
throw new Error("widgetModel is not available");
|
|
3269
3273
|
return e(m)({
|
|
3270
3274
|
...l,
|
|
3271
3275
|
filters: L,
|
|
3272
|
-
signal:
|
|
3276
|
+
signal: U
|
|
3273
3277
|
});
|
|
3274
3278
|
}, o[12] = L, o[13] = m, o[14] = l, o[15] = w) : w = o[15];
|
|
3275
3279
|
const v = !!m && M;
|
|
@@ -3297,13 +3301,13 @@ function de({
|
|
|
3297
3301
|
};
|
|
3298
3302
|
}
|
|
3299
3303
|
const {
|
|
3300
|
-
useModelHook:
|
|
3301
|
-
ModelComponent:
|
|
3304
|
+
useModelHook: _o,
|
|
3305
|
+
ModelComponent: Eo
|
|
3302
3306
|
} = de({
|
|
3303
3307
|
queryKeyPrefix: ["aggregations"],
|
|
3304
3308
|
getWidgetMethod: (n) => (e) => {
|
|
3305
3309
|
let t = e.aggregations.filter((s) => s.operation !== "custom");
|
|
3306
|
-
e.aggregations.some((s) => s.operation === "custom") && (t =
|
|
3310
|
+
e.aggregations.some((s) => s.operation === "custom") && (t = ks(e.aggregations).join(","));
|
|
3307
3311
|
const r = {
|
|
3308
3312
|
...e,
|
|
3309
3313
|
aggregations: t
|
|
@@ -3311,7 +3315,7 @@ const {
|
|
|
3311
3315
|
return n.getAggregations(r);
|
|
3312
3316
|
}
|
|
3313
3317
|
});
|
|
3314
|
-
function
|
|
3318
|
+
function ks(n) {
|
|
3315
3319
|
return n.map((e) => {
|
|
3316
3320
|
if (e.operation === "custom")
|
|
3317
3321
|
return `${e.aggregationExp} AS ${e.alias}`;
|
|
@@ -3337,55 +3341,55 @@ function Ls(n) {
|
|
|
3337
3341
|
});
|
|
3338
3342
|
}
|
|
3339
3343
|
const {
|
|
3340
|
-
useModelHook:
|
|
3341
|
-
ModelComponent:
|
|
3344
|
+
useModelHook: To,
|
|
3345
|
+
ModelComponent: Lo
|
|
3342
3346
|
} = de({
|
|
3343
3347
|
queryKeyPrefix: ["categories"],
|
|
3344
3348
|
getWidgetMethod: (n) => n.getCategories.bind(n)
|
|
3345
3349
|
}), {
|
|
3346
|
-
useModelHook:
|
|
3347
|
-
ModelComponent:
|
|
3350
|
+
useModelHook: ko,
|
|
3351
|
+
ModelComponent: Co
|
|
3348
3352
|
} = de({
|
|
3349
3353
|
queryKeyPrefix: ["features"],
|
|
3350
3354
|
getWidgetMethod: (n) => n.getFeatures.bind(n)
|
|
3351
3355
|
}), {
|
|
3352
|
-
useModelHook:
|
|
3353
|
-
ModelComponent:
|
|
3356
|
+
useModelHook: Po,
|
|
3357
|
+
ModelComponent: Oo
|
|
3354
3358
|
} = de({
|
|
3355
3359
|
queryKeyPrefix: ["formula"],
|
|
3356
3360
|
getWidgetMethod: (n) => n.getFormula.bind(n)
|
|
3357
3361
|
}), {
|
|
3358
|
-
useModelHook:
|
|
3359
|
-
ModelComponent:
|
|
3362
|
+
useModelHook: Ao,
|
|
3363
|
+
ModelComponent: Fo
|
|
3360
3364
|
} = de({
|
|
3361
3365
|
queryKeyPrefix: ["histogram"],
|
|
3362
3366
|
getWidgetMethod: (n) => n.getHistogram.bind(n)
|
|
3363
3367
|
}), {
|
|
3364
|
-
useModelHook:
|
|
3365
|
-
ModelComponent:
|
|
3368
|
+
useModelHook: Do,
|
|
3369
|
+
ModelComponent: Ro
|
|
3366
3370
|
} = de({
|
|
3367
3371
|
queryKeyPrefix: ["range"],
|
|
3368
3372
|
getWidgetMethod: (n) => n.getRange.bind(n)
|
|
3369
3373
|
}), {
|
|
3370
|
-
useModelHook:
|
|
3371
|
-
ModelComponent:
|
|
3374
|
+
useModelHook: xo,
|
|
3375
|
+
ModelComponent: $o
|
|
3372
3376
|
} = de({
|
|
3373
3377
|
queryKeyPrefix: ["scatter"],
|
|
3374
3378
|
getWidgetMethod: (n) => n.getScatter.bind(n)
|
|
3375
3379
|
}), {
|
|
3376
|
-
useModelHook:
|
|
3377
|
-
ModelComponent:
|
|
3380
|
+
useModelHook: Uo,
|
|
3381
|
+
ModelComponent: Vo
|
|
3378
3382
|
} = de({
|
|
3379
3383
|
queryKeyPrefix: ["table"],
|
|
3380
3384
|
getWidgetMethod: (n) => n.getTable.bind(n)
|
|
3381
3385
|
}), {
|
|
3382
|
-
useModelHook:
|
|
3383
|
-
ModelComponent:
|
|
3386
|
+
useModelHook: qo,
|
|
3387
|
+
ModelComponent: jo
|
|
3384
3388
|
} = de({
|
|
3385
3389
|
queryKeyPrefix: ["timeSeries"],
|
|
3386
3390
|
getWidgetMethod: (n) => n.getTimeSeries.bind(n)
|
|
3387
|
-
}),
|
|
3388
|
-
function
|
|
3391
|
+
}), Bo = "ps";
|
|
3392
|
+
function Io(n) {
|
|
3389
3393
|
const e = j(13), {
|
|
3390
3394
|
children: t,
|
|
3391
3395
|
maps: r,
|
|
@@ -3405,8 +3409,8 @@ function Bo(n) {
|
|
|
3405
3409
|
let b;
|
|
3406
3410
|
return e[10] !== r || e[11] !== h ? (b = /* @__PURE__ */ G(er, { values: r, children: h }), e[10] = r, e[11] = h, e[12] = b) : b = e[12], b;
|
|
3407
3411
|
}
|
|
3408
|
-
function
|
|
3409
|
-
const t = Se((d) => d.layers), r = Se((d) => d.setLayer), s = ge(() => $t(n.map((d) => t[d]).filter((d) => !!d?.legend)).toReversed(), [t, n]), o = ge(() => s.map(e), [e, s]), i =
|
|
3412
|
+
function Ho(n, e) {
|
|
3413
|
+
const t = Se((d) => d.layers), r = Se((d) => d.setLayer), s = ge(() => $t(n.map((d) => t[d]).filter((d) => !!d?.legend)).toReversed(), [t, n]), o = ge(() => s.map(e), [e, s]), i = se(({
|
|
3410
3414
|
id: d,
|
|
3411
3415
|
visible: p,
|
|
3412
3416
|
...h
|
|
@@ -3417,7 +3421,7 @@ function Io(n, e) {
|
|
|
3417
3421
|
},
|
|
3418
3422
|
legend: h
|
|
3419
3423
|
});
|
|
3420
|
-
}, [r]), a =
|
|
3424
|
+
}, [r]), a = se(({
|
|
3421
3425
|
id: d,
|
|
3422
3426
|
collapsed: p
|
|
3423
3427
|
}) => {
|
|
@@ -3426,7 +3430,7 @@ function Io(n, e) {
|
|
|
3426
3430
|
collapsed: p
|
|
3427
3431
|
}
|
|
3428
3432
|
});
|
|
3429
|
-
}, [r]), l =
|
|
3433
|
+
}, [r]), l = se(({
|
|
3430
3434
|
id: d,
|
|
3431
3435
|
opacity: p
|
|
3432
3436
|
}) => {
|
|
@@ -3443,12 +3447,12 @@ function Io(n, e) {
|
|
|
3443
3447
|
onChangeRowCollapse: a
|
|
3444
3448
|
};
|
|
3445
3449
|
}
|
|
3446
|
-
function
|
|
3450
|
+
function No({
|
|
3447
3451
|
mapId: n
|
|
3448
3452
|
}) {
|
|
3449
3453
|
const [e, t] = ue(void 0), [r, s] = ue(!1), [o, i] = ue(void 0), a = x((u) => u.maps[n]?.basemap), l = x((u) => u.getDeckInstance), d = x((u) => u.getOverlayInstance), p = x((u) => u.areLayersLoaded[n]), b = x((u) => u.maps[n]?.isLoaded) && p, {
|
|
3450
3454
|
type: f
|
|
3451
|
-
} = we[a], M = f === ce.googleMaps, S =
|
|
3455
|
+
} = we[a], M = f === ce.googleMaps, S = se(async () => {
|
|
3452
3456
|
const u = l(n), m = d(n);
|
|
3453
3457
|
try {
|
|
3454
3458
|
const g = document.createElement("canvas");
|
|
@@ -3458,10 +3462,10 @@ function Ho({
|
|
|
3458
3462
|
const k = m;
|
|
3459
3463
|
if (k.getRenderingType() !== "RASTER")
|
|
3460
3464
|
throw new Error("Only raster type is supported for Google Maps");
|
|
3461
|
-
const
|
|
3465
|
+
const D = await Cn(k.getDiv(), {
|
|
3462
3466
|
useCORS: !0
|
|
3463
3467
|
});
|
|
3464
|
-
w?.drawImage(
|
|
3468
|
+
w?.drawImage(D, 0, 0, u.width, u.height);
|
|
3465
3469
|
} else {
|
|
3466
3470
|
const k = m;
|
|
3467
3471
|
k.redraw(), w?.drawImage(k.getMap().getCanvas(), 0, 0, u.width, u.height);
|
|
@@ -3476,7 +3480,7 @@ function Ho({
|
|
|
3476
3480
|
}
|
|
3477
3481
|
}, [l, M, n, d]);
|
|
3478
3482
|
return {
|
|
3479
|
-
takeScreenshot:
|
|
3483
|
+
takeScreenshot: se(() => {
|
|
3480
3484
|
i(void 0), s(!0), b && S();
|
|
3481
3485
|
}, [S, b]),
|
|
3482
3486
|
isLoading: r,
|
|
@@ -3484,7 +3488,7 @@ function Ho({
|
|
|
3484
3488
|
error: o
|
|
3485
3489
|
};
|
|
3486
3490
|
}
|
|
3487
|
-
function
|
|
3491
|
+
function Zo(n) {
|
|
3488
3492
|
const e = j(11), {
|
|
3489
3493
|
mapId: t
|
|
3490
3494
|
} = n;
|
|
@@ -3492,17 +3496,17 @@ function No(n) {
|
|
|
3492
3496
|
e[0] !== t ? (r = {
|
|
3493
3497
|
mapId: t
|
|
3494
3498
|
}, e[0] = t, e[1] = r) : r = e[1];
|
|
3495
|
-
const s =
|
|
3499
|
+
const s = Cs(r);
|
|
3496
3500
|
let o;
|
|
3497
3501
|
e[2] !== t ? (o = {
|
|
3498
3502
|
mapId: t
|
|
3499
3503
|
}, e[2] = t, e[3] = o) : o = e[3];
|
|
3500
|
-
const i =
|
|
3504
|
+
const i = Ps(o);
|
|
3501
3505
|
let a;
|
|
3502
3506
|
e[4] !== t ? (a = {
|
|
3503
3507
|
mapId: t
|
|
3504
3508
|
}, e[4] = t, e[5] = a) : a = e[5];
|
|
3505
|
-
const l =
|
|
3509
|
+
const l = Fs(a), d = i ?? l ?? s;
|
|
3506
3510
|
let p;
|
|
3507
3511
|
return e[6] !== i || e[7] !== l || e[8] !== d || e[9] !== s ? (p = {
|
|
3508
3512
|
spatialFilter: d,
|
|
@@ -3511,7 +3515,7 @@ function No(n) {
|
|
|
3511
3515
|
viewportSpatialFilter: s
|
|
3512
3516
|
}, e[6] = i, e[7] = l, e[8] = d, e[9] = s, e[10] = p) : p = e[10], p;
|
|
3513
3517
|
}
|
|
3514
|
-
function
|
|
3518
|
+
function Cs(n) {
|
|
3515
3519
|
const e = j(4), {
|
|
3516
3520
|
mapId: t
|
|
3517
3521
|
} = n;
|
|
@@ -3529,38 +3533,38 @@ function ks(n) {
|
|
|
3529
3533
|
}
|
|
3530
3534
|
return o;
|
|
3531
3535
|
}
|
|
3532
|
-
function
|
|
3536
|
+
function Ps(n) {
|
|
3533
3537
|
const e = j(5), {
|
|
3534
3538
|
mapId: t
|
|
3535
3539
|
} = n;
|
|
3536
3540
|
let r;
|
|
3537
3541
|
e[0] !== t ? (r = (i) => i.data[t]?.values, e[0] = t, e[1] = r) : r = e[1];
|
|
3538
|
-
const s =
|
|
3542
|
+
const s = Y(r);
|
|
3539
3543
|
let o;
|
|
3540
3544
|
e: {
|
|
3541
3545
|
let i;
|
|
3542
3546
|
if (e[2] !== s) {
|
|
3543
3547
|
const a = At({
|
|
3544
3548
|
values: s
|
|
3545
|
-
}).filter(
|
|
3549
|
+
}).filter(As);
|
|
3546
3550
|
if (!a?.length) {
|
|
3547
3551
|
o = void 0;
|
|
3548
3552
|
break e;
|
|
3549
3553
|
}
|
|
3550
|
-
i = Ge(a.map(
|
|
3554
|
+
i = Ge(a.map(Os)), e[2] = s, e[3] = i, e[4] = o;
|
|
3551
3555
|
} else
|
|
3552
3556
|
i = e[3], o = e[4];
|
|
3553
3557
|
o = i.geometry;
|
|
3554
3558
|
}
|
|
3555
3559
|
return o;
|
|
3556
3560
|
}
|
|
3557
|
-
function
|
|
3561
|
+
function Os(n) {
|
|
3558
3562
|
return n.geometry.coordinates;
|
|
3559
3563
|
}
|
|
3560
|
-
function
|
|
3564
|
+
function As(n) {
|
|
3561
3565
|
return n.properties.visible;
|
|
3562
3566
|
}
|
|
3563
|
-
function
|
|
3567
|
+
function Fs(n) {
|
|
3564
3568
|
const e = j(4), {
|
|
3565
3569
|
mapId: t
|
|
3566
3570
|
} = n;
|
|
@@ -3575,7 +3579,7 @@ function As(n) {
|
|
|
3575
3579
|
}
|
|
3576
3580
|
let i;
|
|
3577
3581
|
if (e[2] !== s) {
|
|
3578
|
-
const a = Object.values(s).filter(
|
|
3582
|
+
const a = Object.values(s).filter(Rs).flatMap(Ds);
|
|
3579
3583
|
i = Ge(a), e[2] = s, e[3] = i;
|
|
3580
3584
|
} else
|
|
3581
3585
|
i = e[3];
|
|
@@ -3583,10 +3587,10 @@ function As(n) {
|
|
|
3583
3587
|
}
|
|
3584
3588
|
return o;
|
|
3585
3589
|
}
|
|
3586
|
-
function
|
|
3590
|
+
function Ds(n) {
|
|
3587
3591
|
return n.type === "Polygon" ? [n.coordinates] : n.coordinates;
|
|
3588
3592
|
}
|
|
3589
|
-
function
|
|
3593
|
+
function Rs(n) {
|
|
3590
3594
|
return n != null;
|
|
3591
3595
|
}
|
|
3592
3596
|
const ye = {
|
|
@@ -3607,17 +3611,17 @@ const ye = {
|
|
|
3607
3611
|
format: (n) => n.toLocaleString()
|
|
3608
3612
|
}
|
|
3609
3613
|
};
|
|
3610
|
-
function
|
|
3614
|
+
function zo({
|
|
3611
3615
|
properties: n,
|
|
3612
3616
|
formatters: e = {},
|
|
3613
3617
|
includeColumns: t = Object.keys(n),
|
|
3614
3618
|
locale: r = "en-US",
|
|
3615
3619
|
showColumnName: s = !0,
|
|
3616
3620
|
title: o,
|
|
3617
|
-
getColumnName: i =
|
|
3618
|
-
getFieldHtml: a =
|
|
3619
|
-
getTitle: l =
|
|
3620
|
-
getValue: d =
|
|
3621
|
+
getColumnName: i = qs,
|
|
3622
|
+
getFieldHtml: a = $s,
|
|
3623
|
+
getTitle: l = xs,
|
|
3624
|
+
getValue: d = Us
|
|
3621
3625
|
}) {
|
|
3622
3626
|
const p = o ? l(o) : "", b = t.reduce((f, M) => {
|
|
3623
3627
|
const S = e[M], L = n[M], u = d(L, r, S), m = s ? i(M) : "";
|
|
@@ -3625,26 +3629,26 @@ function Zo({
|
|
|
3625
3629
|
}, "");
|
|
3626
3630
|
return p + b;
|
|
3627
3631
|
}
|
|
3628
|
-
function
|
|
3632
|
+
function xs(n) {
|
|
3629
3633
|
return `<h3 style="margin: 0"><strong>${n}</strong></h3></br>`;
|
|
3630
3634
|
}
|
|
3631
|
-
function
|
|
3635
|
+
function $s(n, e) {
|
|
3632
3636
|
return `${n}${e}</br>`;
|
|
3633
3637
|
}
|
|
3634
|
-
function
|
|
3638
|
+
function Us(n, e, t) {
|
|
3635
3639
|
try {
|
|
3636
|
-
return
|
|
3640
|
+
return Vs(t)(n, e);
|
|
3637
3641
|
} catch {
|
|
3638
3642
|
return n;
|
|
3639
3643
|
}
|
|
3640
3644
|
}
|
|
3641
|
-
function
|
|
3645
|
+
function Vs(n) {
|
|
3642
3646
|
return typeof n == "function" ? n : ((n && mt[n]) ?? mt[ye.default]).format;
|
|
3643
3647
|
}
|
|
3644
|
-
function
|
|
3648
|
+
function qs(n) {
|
|
3645
3649
|
return `<strong>${n}</strong>: `;
|
|
3646
3650
|
}
|
|
3647
|
-
function
|
|
3651
|
+
function Go(n) {
|
|
3648
3652
|
return {
|
|
3649
3653
|
collapsed: n.legend?.collapsed,
|
|
3650
3654
|
collapsible: n.legend?.collapsible,
|
|
@@ -3660,7 +3664,7 @@ function zo(n) {
|
|
|
3660
3664
|
visible: n.props.visible ?? !0
|
|
3661
3665
|
};
|
|
3662
3666
|
}
|
|
3663
|
-
const
|
|
3667
|
+
const js = {
|
|
3664
3668
|
Point: (n) => yn(n.coordinates),
|
|
3665
3669
|
LineString: (n) => mn(n.coordinates),
|
|
3666
3670
|
Polygon: (n) => pn(n.coordinates),
|
|
@@ -3668,12 +3672,12 @@ const qs = {
|
|
|
3668
3672
|
MultiLineString: (n) => dn(n.coordinates),
|
|
3669
3673
|
MultiPolygon: (n) => Ge(n.coordinates)
|
|
3670
3674
|
};
|
|
3671
|
-
function
|
|
3672
|
-
const e =
|
|
3675
|
+
function Wo(n) {
|
|
3676
|
+
const e = js[n.type], t = e?.(n);
|
|
3673
3677
|
if (t)
|
|
3674
3678
|
return wt(t).geometry.coordinates;
|
|
3675
3679
|
}
|
|
3676
|
-
function
|
|
3680
|
+
function Ko(n) {
|
|
3677
3681
|
const e = j(22), {
|
|
3678
3682
|
children: t,
|
|
3679
3683
|
mapId: r
|
|
@@ -3687,7 +3691,7 @@ function Wo(n) {
|
|
|
3687
3691
|
} = x(s);
|
|
3688
3692
|
let l;
|
|
3689
3693
|
e[2] !== r ? (l = (v) => v.areLayersLoaded[r], e[2] = r, e[3] = l) : l = e[3];
|
|
3690
|
-
const d = x(l), p = x(
|
|
3694
|
+
const d = x(l), p = x(Hs), h = x(Is), b = x(Bs), f = !d;
|
|
3691
3695
|
let M;
|
|
3692
3696
|
e[4] !== r || e[5] !== p ? (M = (v) => p(r, v), e[4] = r, e[5] = p, e[6] = M) : M = e[6];
|
|
3693
3697
|
const S = M;
|
|
@@ -3708,16 +3712,16 @@ function Wo(n) {
|
|
|
3708
3712
|
resetViewState: g
|
|
3709
3713
|
}), e[13] = t, e[14] = i, e[15] = a, e[16] = f, e[17] = S, e[18] = u, e[19] = g, e[20] = o, e[21] = w) : w = e[21], w;
|
|
3710
3714
|
}
|
|
3711
|
-
function
|
|
3715
|
+
function Bs(n) {
|
|
3712
3716
|
return n.resetViewState;
|
|
3713
3717
|
}
|
|
3714
|
-
function
|
|
3718
|
+
function Is(n) {
|
|
3715
3719
|
return n.flyTo;
|
|
3716
3720
|
}
|
|
3717
|
-
function
|
|
3721
|
+
function Hs(n) {
|
|
3718
3722
|
return n.setZoom;
|
|
3719
3723
|
}
|
|
3720
|
-
async function
|
|
3724
|
+
async function Ns({
|
|
3721
3725
|
baseUrl: n = Ke,
|
|
3722
3726
|
connection: e,
|
|
3723
3727
|
accessToken: t,
|
|
@@ -3745,7 +3749,7 @@ async function Hs({
|
|
|
3745
3749
|
...i
|
|
3746
3750
|
});
|
|
3747
3751
|
}
|
|
3748
|
-
async function
|
|
3752
|
+
async function Zs({
|
|
3749
3753
|
baseUrl: n = Ke,
|
|
3750
3754
|
connection: e,
|
|
3751
3755
|
accessToken: t,
|
|
@@ -3770,7 +3774,7 @@ async function Ns({
|
|
|
3770
3774
|
...a
|
|
3771
3775
|
});
|
|
3772
3776
|
}
|
|
3773
|
-
function
|
|
3777
|
+
function Yo(n) {
|
|
3774
3778
|
const e = j(20), {
|
|
3775
3779
|
source: t,
|
|
3776
3780
|
attribute: r,
|
|
@@ -3790,7 +3794,7 @@ function Ko(n) {
|
|
|
3790
3794
|
let b;
|
|
3791
3795
|
e[5] !== r || e[6] !== t ? (b = [t, r], e[5] = r, e[6] = t, e[7] = b) : b = e[7];
|
|
3792
3796
|
let f;
|
|
3793
|
-
e[8] !== s || e[9] !== r || e[10] !== i || e[11] !== o || e[12] !== t ? (f = () =>
|
|
3797
|
+
e[8] !== s || e[9] !== r || e[10] !== i || e[11] !== o || e[12] !== t ? (f = () => zs({
|
|
3794
3798
|
source: t,
|
|
3795
3799
|
params: o,
|
|
3796
3800
|
attribute: r,
|
|
@@ -3811,7 +3815,7 @@ function Ko(n) {
|
|
|
3811
3815
|
...p
|
|
3812
3816
|
}, e[14] = h, e[15] = t, e[16] = b, e[17] = f, e[18] = p, e[19] = M) : M = e[19], Et(M);
|
|
3813
3817
|
}
|
|
3814
|
-
function
|
|
3818
|
+
function zs({
|
|
3815
3819
|
source: n,
|
|
3816
3820
|
params: e,
|
|
3817
3821
|
attribute: t,
|
|
@@ -3819,7 +3823,7 @@ function Zs({
|
|
|
3819
3823
|
fetcherOptions: s
|
|
3820
3824
|
}) {
|
|
3821
3825
|
if (n.type.startsWith("query"))
|
|
3822
|
-
return
|
|
3826
|
+
return Ns({
|
|
3823
3827
|
connection: n.connectionName,
|
|
3824
3828
|
baseUrl: n.apiBaseUrl,
|
|
3825
3829
|
apiVersion: n.apiVersion,
|
|
@@ -3831,7 +3835,7 @@ function Zs({
|
|
|
3831
3835
|
fetcherOptions: s
|
|
3832
3836
|
});
|
|
3833
3837
|
if (n.type.startsWith("table"))
|
|
3834
|
-
return
|
|
3838
|
+
return Zs({
|
|
3835
3839
|
connection: n.connectionName,
|
|
3836
3840
|
baseUrl: n.apiBaseUrl,
|
|
3837
3841
|
apiVersion: n.apiVersion,
|
|
@@ -3842,7 +3846,7 @@ function Zs({
|
|
|
3842
3846
|
fetcherOptions: s
|
|
3843
3847
|
});
|
|
3844
3848
|
if (n.type.startsWith("tileset"))
|
|
3845
|
-
return
|
|
3849
|
+
return Gs({
|
|
3846
3850
|
source: n,
|
|
3847
3851
|
accessToken: r,
|
|
3848
3852
|
target: n.data,
|
|
@@ -3850,7 +3854,7 @@ function Zs({
|
|
|
3850
3854
|
});
|
|
3851
3855
|
throw new Error(`Unsupported source type: ${n.type}`);
|
|
3852
3856
|
}
|
|
3853
|
-
async function
|
|
3857
|
+
async function Gs({
|
|
3854
3858
|
source: n,
|
|
3855
3859
|
accessToken: e,
|
|
3856
3860
|
target: t,
|
|
@@ -3871,12 +3875,12 @@ async function zs({
|
|
|
3871
3875
|
return i;
|
|
3872
3876
|
}
|
|
3873
3877
|
export {
|
|
3874
|
-
|
|
3875
|
-
|
|
3878
|
+
Eo as AggregationsModel,
|
|
3879
|
+
bo as BasemapsControls,
|
|
3876
3880
|
at as CONVERSIONS_UNITS,
|
|
3877
3881
|
Re as CartoBasemapURL,
|
|
3878
3882
|
ae as CartoBasemaps,
|
|
3879
|
-
|
|
3883
|
+
Lo as CategoriesModel,
|
|
3880
3884
|
nr as CustomCompositeEditMode,
|
|
3881
3885
|
Pt as CustomEditableGeojsonLayer,
|
|
3882
3886
|
gr as CustomMeasureAreaMode,
|
|
@@ -3891,11 +3895,11 @@ export {
|
|
|
3891
3895
|
_r as DEFAULT_MEASUREMENT_TOOLS_UNITS,
|
|
3892
3896
|
Ve as DEFAULT_MEASURE_COLORS,
|
|
3893
3897
|
Bn as DeckGLComponent,
|
|
3894
|
-
|
|
3895
|
-
|
|
3896
|
-
|
|
3898
|
+
oe as EditableEditType,
|
|
3899
|
+
Co as FeaturesModel,
|
|
3900
|
+
Oo as FormulaModel,
|
|
3897
3901
|
De as GmapsBasemap,
|
|
3898
|
-
|
|
3902
|
+
Fo as HistogramModel,
|
|
3899
3903
|
ve as INTL_UNITS,
|
|
3900
3904
|
Tr as LassoTools,
|
|
3901
3905
|
fr as LassoToolsProvider,
|
|
@@ -3905,63 +3909,63 @@ export {
|
|
|
3905
3909
|
fe as MAP_MEASURE_LAYER_ID,
|
|
3906
3910
|
wr as MEASUREMENT_TOOLS_UNITS_AREA,
|
|
3907
3911
|
ct as MEASUREMENT_TOOLS_UNITS_DISTANCE,
|
|
3908
|
-
|
|
3909
|
-
|
|
3912
|
+
re as MEASUREMENT_TOOLS_UNITS_DISTANCE_VALUES,
|
|
3913
|
+
vo as MapComponent,
|
|
3910
3914
|
Be as MapMeasurementUnitAuto,
|
|
3911
3915
|
vr as MapMeasurementUnitTurf,
|
|
3912
3916
|
er as MapProvider,
|
|
3913
|
-
|
|
3917
|
+
Io as MapsProvider,
|
|
3914
3918
|
ce as MapsTypes,
|
|
3915
3919
|
jr as MeasurementTools,
|
|
3916
3920
|
Pr as MeasurementToolsProvider,
|
|
3917
|
-
|
|
3918
|
-
|
|
3919
|
-
|
|
3920
|
-
|
|
3921
|
-
|
|
3922
|
-
|
|
3921
|
+
Ro as RangeModel,
|
|
3922
|
+
$o as ScatterModel,
|
|
3923
|
+
Vo as TableModel,
|
|
3924
|
+
jo as TimeSeriesModel,
|
|
3925
|
+
Ko as ZoomControls,
|
|
3926
|
+
Bo as clientID,
|
|
3923
3927
|
st as convertMetersTo,
|
|
3924
3928
|
dr as createLassoToolsStore,
|
|
3925
3929
|
Xn as createMapStore,
|
|
3926
3930
|
Cr as createMeasurementToolsStore,
|
|
3927
3931
|
ye as formatterTypes,
|
|
3928
|
-
|
|
3932
|
+
Wo as getCentroid,
|
|
3929
3933
|
Pn as getCursorDefault,
|
|
3930
|
-
|
|
3931
|
-
|
|
3934
|
+
So as getDeckController,
|
|
3935
|
+
Mo as getFilterValues,
|
|
3932
3936
|
cr as getLassoToolsLayer,
|
|
3933
3937
|
Lr as getMeasurementToolsLayer,
|
|
3934
3938
|
Ae as getTextLayerFormattedDistance,
|
|
3935
3939
|
On as getTooltipDefault,
|
|
3936
|
-
|
|
3937
|
-
|
|
3940
|
+
Go as mappingLegendMeridian,
|
|
3941
|
+
zo as objectToHtml,
|
|
3938
3942
|
$t as sortLayers,
|
|
3939
3943
|
Nn as transitionFlyConfig,
|
|
3940
|
-
|
|
3941
|
-
|
|
3944
|
+
_o as useAggregations,
|
|
3945
|
+
To as useCategories,
|
|
3942
3946
|
Ct as useEventManager,
|
|
3943
|
-
|
|
3944
|
-
|
|
3945
|
-
|
|
3946
|
-
|
|
3947
|
-
|
|
3948
|
-
|
|
3947
|
+
ko as useFeatures,
|
|
3948
|
+
gs as useFilters,
|
|
3949
|
+
Po as useFormula,
|
|
3950
|
+
Ao as useHistogram,
|
|
3951
|
+
Ps as useLassoToolsSpatialFilter,
|
|
3952
|
+
Y as useLassoToolsState,
|
|
3949
3953
|
Se as useLayerStore,
|
|
3950
|
-
|
|
3951
|
-
|
|
3952
|
-
|
|
3954
|
+
Wr as useLayers,
|
|
3955
|
+
Ho as useLegend,
|
|
3956
|
+
No as useMapScreenshot,
|
|
3953
3957
|
x as useMapStore,
|
|
3954
3958
|
z as useMeasurementToolsState,
|
|
3955
|
-
|
|
3956
|
-
|
|
3957
|
-
|
|
3959
|
+
Do as useRange,
|
|
3960
|
+
xo as useScatter,
|
|
3961
|
+
hs as useSource,
|
|
3958
3962
|
Pe as useSourceStore,
|
|
3959
|
-
|
|
3960
|
-
|
|
3961
|
-
|
|
3962
|
-
|
|
3963
|
-
|
|
3964
|
-
|
|
3965
|
-
|
|
3963
|
+
wo as useSourceWithFilters,
|
|
3964
|
+
Zo as useSpatialFilter,
|
|
3965
|
+
Yo as useStats,
|
|
3966
|
+
Uo as useTable,
|
|
3967
|
+
qo as useTimeSeries,
|
|
3968
|
+
Cs as useViewportSpatialFilter,
|
|
3969
|
+
_s as useWidgetModel
|
|
3966
3970
|
};
|
|
3967
3971
|
//# sourceMappingURL=index.js.map
|