@carto/ps-react-maps 3.9.2 → 3.10.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
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
var
|
|
2
|
-
var Dt = (r, e, t) => e in r ?
|
|
1
|
+
var At = Object.defineProperty;
|
|
2
|
+
var Dt = (r, e, t) => e in r ? At(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t;
|
|
3
3
|
var ee = (r, e, t) => Dt(r, typeof e != "symbol" ? e + "" : e, t);
|
|
4
4
|
import { jsx as N, jsxs as ft } from "react/jsx-runtime";
|
|
5
5
|
import { c as D } from "react/compiler-runtime";
|
|
6
|
-
import { useEffect as z, useImperativeHandle as Ne, useMemo as
|
|
7
|
-
import { MapProvider as Rt, Map as $t, useMap as
|
|
8
|
-
import
|
|
6
|
+
import { useEffect as z, useImperativeHandle as Ne, useMemo as oe, useCallback as Q, useState as se, createContext as He, useContext as Ge, useRef as Me } from "react";
|
|
7
|
+
import { MapProvider as Rt, Map as $t, useMap as xt } from "react-map-gl/maplibre";
|
|
8
|
+
import Ut from "@deck.gl/react";
|
|
9
9
|
import { useMap as pt, APIProvider as Bt, Map as jt } from "@vis.gl/react-google-maps";
|
|
10
10
|
import { GoogleMapsOverlay as qt } from "@deck.gl/google-maps";
|
|
11
11
|
import { createStore as ze, useStore as Qe, create as mt } from "zustand";
|
|
@@ -21,7 +21,7 @@ import as from "convert-units";
|
|
|
21
21
|
import ls from "convert-units/definitions/length";
|
|
22
22
|
import { removeFilter as Xe, addFilter as vt, WidgetRasterSource as cs, WidgetTilesetSource as us, TileFormat as ds, WidgetTableSource as fs, WidgetQuerySource as ps, createViewportSpatialFilter as ms, vectorTilesetSource as ys } from "@carto/api-client";
|
|
23
23
|
import { devtools as hs } from "zustand/middleware";
|
|
24
|
-
import { useQuery as
|
|
24
|
+
import { useQuery as ne } from "@tanstack/react-query";
|
|
25
25
|
import gs from "html2canvas";
|
|
26
26
|
const Re = {
|
|
27
27
|
roadmap: "roadmap",
|
|
@@ -79,7 +79,7 @@ function vs(r) {
|
|
|
79
79
|
}
|
|
80
80
|
function Ss(r) {
|
|
81
81
|
const e = D(42);
|
|
82
|
-
let t, s, n, o, i, a, l, c,
|
|
82
|
+
let t, s, n, o, i, a, l, c, h, p, y, f;
|
|
83
83
|
e[0] !== r ? ({
|
|
84
84
|
instanceRef: i,
|
|
85
85
|
overlayRef: p,
|
|
@@ -91,11 +91,11 @@ function Ss(r) {
|
|
|
91
91
|
getCursor: s,
|
|
92
92
|
getTooltip: n,
|
|
93
93
|
onLoad: c,
|
|
94
|
-
onViewStateChange:
|
|
95
|
-
...
|
|
96
|
-
} = r, e[0] = r, e[1] = t, e[2] = s, e[3] = n, e[4] = o, e[5] = i, e[6] = a, e[7] = l, e[8] = c, e[9] =
|
|
97
|
-
let
|
|
98
|
-
e[13] !== c ? (
|
|
94
|
+
onViewStateChange: h,
|
|
95
|
+
...f
|
|
96
|
+
} = r, e[0] = r, e[1] = t, e[2] = s, e[3] = n, e[4] = o, e[5] = i, e[6] = a, e[7] = l, e[8] = c, e[9] = h, e[10] = p, e[11] = y, e[12] = f) : (t = e[1], s = e[2], n = e[3], o = e[4], i = e[5], a = e[6], l = e[7], c = e[8], h = e[9], p = e[10], y = e[11], f = e[12]);
|
|
97
|
+
let m, b;
|
|
98
|
+
e[13] !== c ? (m = () => {
|
|
99
99
|
c({
|
|
100
100
|
type: "load",
|
|
101
101
|
value: !1
|
|
@@ -103,15 +103,15 @@ function Ss(r) {
|
|
|
103
103
|
type: "deckgl",
|
|
104
104
|
value: !1
|
|
105
105
|
});
|
|
106
|
-
},
|
|
107
|
-
let
|
|
108
|
-
e[16] !== a ? (
|
|
109
|
-
const
|
|
110
|
-
let
|
|
111
|
-
e[18] !== c ? (
|
|
106
|
+
}, b = [c], e[13] = c, e[14] = m, e[15] = b) : (m = e[14], b = e[15]), z(m, b);
|
|
107
|
+
let E, u;
|
|
108
|
+
e[16] !== a ? (u = a.filter(Es).map(Ts), e[16] = a, e[17] = u) : u = e[17], E = u;
|
|
109
|
+
const g = E, S = i;
|
|
110
|
+
let T;
|
|
111
|
+
e[18] !== c ? (T = () => c({
|
|
112
112
|
type: "deckgl",
|
|
113
113
|
value: !0
|
|
114
|
-
}), e[18] = c, e[19] =
|
|
114
|
+
}), e[18] = c, e[19] = T) : T = e[19];
|
|
115
115
|
let w;
|
|
116
116
|
e[20] !== y ? (w = {
|
|
117
117
|
depthTest: !1,
|
|
@@ -119,18 +119,18 @@ function Ss(r) {
|
|
|
119
119
|
}, e[20] = y, e[21] = w) : w = e[21];
|
|
120
120
|
let _;
|
|
121
121
|
e[22] !== p ? (_ = /* @__PURE__ */ N(_s, { overlayRef: p }), e[22] = p, e[23] = _) : _ = e[23];
|
|
122
|
-
let
|
|
123
|
-
e[24] !== c ? (
|
|
122
|
+
let F;
|
|
123
|
+
e[24] !== c ? (F = () => c({
|
|
124
124
|
type: "load",
|
|
125
125
|
value: !0
|
|
126
|
-
}), e[24] = c, e[25] =
|
|
127
|
-
let
|
|
128
|
-
e[26] !== l || e[27] !==
|
|
129
|
-
let
|
|
130
|
-
return e[29] !==
|
|
126
|
+
}), e[24] = c, e[25] = F) : F = e[25];
|
|
127
|
+
let x;
|
|
128
|
+
e[26] !== l || e[27] !== F ? (x = /* @__PURE__ */ N($t, { reuseMaps: !0, mapStyle: l, onLoad: F, onRender: ws }), e[26] = l, e[27] = F, e[28] = x) : x = e[28];
|
|
129
|
+
let A;
|
|
130
|
+
return e[29] !== g || e[30] !== t || e[31] !== s || e[32] !== n || e[33] !== o || e[34] !== h || e[35] !== f || e[36] !== x || e[37] !== S || e[38] !== T || e[39] !== w || e[40] !== _ ? (A = /* @__PURE__ */ N(Rt, { children: /* @__PURE__ */ N("div", { className: "deckgl-map", children: /* @__PURE__ */ ft(Ut, { controller: t, id: o, ref: S, layers: g, getCursor: s, getTooltip: n, onLoad: T, onViewStateChange: h, parameters: w, ...f, children: [
|
|
131
131
|
_,
|
|
132
|
-
|
|
133
|
-
] }) }) }), e[29] =
|
|
132
|
+
x
|
|
133
|
+
] }) }) }), e[29] = g, e[30] = t, e[31] = s, e[32] = n, e[33] = o, e[34] = h, e[35] = f, e[36] = x, e[37] = S, e[38] = T, e[39] = w, e[40] = _, e[41] = A) : A = e[41], A;
|
|
134
134
|
}
|
|
135
135
|
function ws() {
|
|
136
136
|
const r = document.querySelector(".maplibregl-compact-show");
|
|
@@ -151,7 +151,7 @@ function _s(r) {
|
|
|
151
151
|
overlayRef: t
|
|
152
152
|
} = r, {
|
|
153
153
|
default: s
|
|
154
|
-
} =
|
|
154
|
+
} = xt();
|
|
155
155
|
let n, o;
|
|
156
156
|
return e[0] !== s ? (n = () => s, o = [s], e[0] = s, e[1] = n, e[2] = o) : (n = e[1], o = e[2]), Ne(t, n, o), null;
|
|
157
157
|
}
|
|
@@ -168,10 +168,10 @@ const Ms = (r) => {
|
|
|
168
168
|
e[3] !== o ? (l = () => (n.setMap(o), () => {
|
|
169
169
|
n.finalize();
|
|
170
170
|
}), c = [n, o], e[3] = o, e[4] = l, e[5] = c) : (l = e[4], c = e[5]), z(l, c);
|
|
171
|
-
let
|
|
172
|
-
return e[6] !== r ? (
|
|
171
|
+
let h, p;
|
|
172
|
+
return e[6] !== r ? (h = () => {
|
|
173
173
|
n.setProps(r);
|
|
174
|
-
}, p = [n, r], e[6] = r, e[7] =
|
|
174
|
+
}, p = [n, r], e[6] = r, e[7] = h, e[8] = p) : (h = e[7], p = e[8]), z(h, p), null;
|
|
175
175
|
};
|
|
176
176
|
function Ps({
|
|
177
177
|
id: r,
|
|
@@ -188,10 +188,10 @@ function Ps({
|
|
|
188
188
|
overlayRef: a,
|
|
189
189
|
parameters: l,
|
|
190
190
|
onLoad: c,
|
|
191
|
-
onViewStateChange:
|
|
191
|
+
onViewStateChange: h,
|
|
192
192
|
...p
|
|
193
193
|
}) {
|
|
194
|
-
var
|
|
194
|
+
var b, E, u, g, S;
|
|
195
195
|
z(() => {
|
|
196
196
|
c({
|
|
197
197
|
type: "load",
|
|
@@ -201,53 +201,53 @@ function Ps({
|
|
|
201
201
|
value: !1
|
|
202
202
|
});
|
|
203
203
|
}, [c]);
|
|
204
|
-
const y =
|
|
205
|
-
type:
|
|
204
|
+
const y = oe(() => s.filter((T) => !!(T != null && T.type)).map(({
|
|
205
|
+
type: T,
|
|
206
206
|
props: w
|
|
207
|
-
}) => new
|
|
207
|
+
}) => new T(w)), [s]), f = Q(({
|
|
208
208
|
detail: {
|
|
209
|
-
center:
|
|
209
|
+
center: T,
|
|
210
210
|
zoom: w,
|
|
211
211
|
heading: _,
|
|
212
|
-
tilt:
|
|
212
|
+
tilt: F
|
|
213
213
|
}
|
|
214
214
|
}) => ({
|
|
215
|
-
latitude:
|
|
216
|
-
longitude:
|
|
215
|
+
latitude: T.lat,
|
|
216
|
+
longitude: T.lng,
|
|
217
217
|
zoom: w - 1,
|
|
218
218
|
bearing: _,
|
|
219
|
-
pitch:
|
|
220
|
-
}), []),
|
|
221
|
-
const w = e == null ? void 0 : e.current, _ = w == null ? void 0 : w._deck,
|
|
219
|
+
pitch: F
|
|
220
|
+
}), []), m = Q((T) => {
|
|
221
|
+
const w = e == null ? void 0 : e.current, _ = w == null ? void 0 : w._deck, F = {
|
|
222
222
|
// @ts-expect-error accessing protected props
|
|
223
223
|
..._ == null ? void 0 : _.viewState,
|
|
224
|
-
...
|
|
225
|
-
},
|
|
226
|
-
latitude:
|
|
227
|
-
longitude:
|
|
228
|
-
zoom:
|
|
229
|
-
pitch:
|
|
230
|
-
bearing:
|
|
224
|
+
...T
|
|
225
|
+
}, x = {
|
|
226
|
+
latitude: F.latitude,
|
|
227
|
+
longitude: F.longitude,
|
|
228
|
+
zoom: F.zoom,
|
|
229
|
+
pitch: F.pitch,
|
|
230
|
+
bearing: F.bearing,
|
|
231
231
|
// @ts-expect-error - `width` and `height` is not in the types
|
|
232
232
|
width: _ == null ? void 0 : _.width,
|
|
233
233
|
height: _ == null ? void 0 : _.height
|
|
234
234
|
};
|
|
235
|
-
|
|
236
|
-
viewState:
|
|
235
|
+
h == null || h({
|
|
236
|
+
viewState: x,
|
|
237
237
|
interactionState: {
|
|
238
238
|
isZooming: !0
|
|
239
239
|
}
|
|
240
240
|
});
|
|
241
|
-
}, [e,
|
|
241
|
+
}, [e, h]);
|
|
242
242
|
return /* @__PURE__ */ N(Bt, { apiKey: n, ...o, children: /* @__PURE__ */ N("div", { className: "deckgl-map", children: /* @__PURE__ */ ft(jt, { id: r, mapTypeId: t, disableDefaultUI: !0, gestureHandling: "greedy", ...i, center: {
|
|
243
|
-
lat: ((
|
|
244
|
-
lng: ((
|
|
245
|
-
}, zoom: (((
|
|
243
|
+
lat: ((b = p.initialViewState) == null ? void 0 : b.latitude) ?? 0,
|
|
244
|
+
lng: ((E = p.initialViewState) == null ? void 0 : E.longitude) ?? 0
|
|
245
|
+
}, zoom: (((u = p.initialViewState) == null ? void 0 : u.zoom) ?? 0) + 1, tilt: (g = p.initialViewState) == null ? void 0 : g.pitch, heading: (S = p.initialViewState) == null ? void 0 : S.bearing, onTilesLoaded: () => {
|
|
246
246
|
c({
|
|
247
247
|
type: "load",
|
|
248
248
|
value: !0
|
|
249
|
-
}),
|
|
250
|
-
}, onBoundsChanged: (
|
|
249
|
+
}), m(p.initialViewState);
|
|
250
|
+
}, onBoundsChanged: (T) => m(f(T)), onZoomChanged: (T) => m(f(T)), children: [
|
|
251
251
|
/* @__PURE__ */ N(Ls, { id: r, overlayRef: a }),
|
|
252
252
|
/* @__PURE__ */ N(Ms, { id: r, instanceRef: e, layers: y, onLoad: () => {
|
|
253
253
|
c({
|
|
@@ -271,49 +271,49 @@ function Ls(r) {
|
|
|
271
271
|
}
|
|
272
272
|
function Os(r) {
|
|
273
273
|
const e = D(46);
|
|
274
|
-
let t, s, n, o, i, a, l, c,
|
|
274
|
+
let t, s, n, o, i, a, l, c, h, p, y, f;
|
|
275
275
|
e[0] !== r ? ({
|
|
276
276
|
instanceRef: s,
|
|
277
277
|
overlayRef: o,
|
|
278
278
|
basemap: a,
|
|
279
279
|
controller: l,
|
|
280
280
|
id: c,
|
|
281
|
-
layers:
|
|
281
|
+
layers: h,
|
|
282
282
|
gmapsProps: t,
|
|
283
283
|
getCursor: p,
|
|
284
284
|
getTooltip: y,
|
|
285
285
|
onLoad: n,
|
|
286
|
-
onViewStateChange:
|
|
286
|
+
onViewStateChange: f,
|
|
287
287
|
...i
|
|
288
|
-
} = r, e[0] = r, e[1] = t, e[2] = s, e[3] = n, e[4] = o, e[5] = i, e[6] = a, e[7] = l, e[8] = c, e[9] =
|
|
289
|
-
const
|
|
290
|
-
let
|
|
291
|
-
e[13] !==
|
|
292
|
-
const
|
|
288
|
+
} = r, e[0] = r, e[1] = t, e[2] = s, e[3] = n, e[4] = o, e[5] = i, e[6] = a, e[7] = l, e[8] = c, e[9] = h, e[10] = p, e[11] = y, e[12] = f) : (t = e[1], s = e[2], n = e[3], o = e[4], i = e[5], a = e[6], l = e[7], c = e[8], h = e[9], p = e[10], y = e[11], f = e[12]);
|
|
289
|
+
const m = a === void 0 ? J.positron : a, b = l === void 0 ? !0 : l, E = c === void 0 ? "deck-gl-map" : c;
|
|
290
|
+
let u;
|
|
291
|
+
e[13] !== h ? (u = h === void 0 ? [] : h, e[13] = h, e[14] = u) : u = e[14];
|
|
292
|
+
const g = u, S = p === void 0 ? bs : p, T = y === void 0 ? vs : y, w = f === void 0 ? ks : f;
|
|
293
293
|
let _;
|
|
294
294
|
e[15] === Symbol.for("react.memo_cache_sentinel") ? (_ = [!1, !1], e[15] = _) : _ = e[15];
|
|
295
|
-
const [
|
|
296
|
-
let
|
|
297
|
-
e[16] !==
|
|
298
|
-
const j =
|
|
295
|
+
const [F, x] = se(_);
|
|
296
|
+
let A;
|
|
297
|
+
e[16] !== F ? (A = F.every(Fs), e[16] = F, e[17] = A) : A = e[17];
|
|
298
|
+
const j = A, {
|
|
299
299
|
url: B,
|
|
300
|
-
type:
|
|
301
|
-
} = ye[
|
|
302
|
-
let
|
|
303
|
-
e[18] === Symbol.for("react.memo_cache_sentinel") ? (
|
|
300
|
+
type: U
|
|
301
|
+
} = ye[m], M = U === te.googleMaps;
|
|
302
|
+
let k;
|
|
303
|
+
e[18] === Symbol.for("react.memo_cache_sentinel") ? (k = (L) => {
|
|
304
304
|
const O = L.type === "deckgl" ? 0 : 1;
|
|
305
|
-
|
|
306
|
-
}, e[18] =
|
|
307
|
-
const
|
|
305
|
+
x((H) => H.map((W, K) => K === O ? L.value : W));
|
|
306
|
+
}, e[18] = k) : k = e[18];
|
|
307
|
+
const d = k;
|
|
308
308
|
let v, P;
|
|
309
309
|
if (e[19] !== j || e[20] !== n ? (v = () => {
|
|
310
310
|
n == null || n(j);
|
|
311
311
|
}, P = [j, n], e[19] = j, e[20] = n, e[21] = v, e[22] = P) : (v = e[21], P = e[22]), z(v, P), M) {
|
|
312
312
|
let L;
|
|
313
|
-
return e[23] !==
|
|
313
|
+
return e[23] !== m || e[24] !== b || e[25] !== S || e[26] !== T || e[27] !== t || e[28] !== E || e[29] !== s || e[30] !== g || e[31] !== w || e[32] !== o || e[33] !== i ? (L = /* @__PURE__ */ N(Ps, { instanceRef: s, overlayRef: o, controller: b, id: E, basemap: m, layers: g, gmapsProps: t, getCursor: S, getTooltip: T, onLoad: d, onViewStateChange: w, ...i }), e[23] = m, e[24] = b, e[25] = S, e[26] = T, e[27] = t, e[28] = E, e[29] = s, e[30] = g, e[31] = w, e[32] = o, e[33] = i, e[34] = L) : L = e[34], L;
|
|
314
314
|
}
|
|
315
|
-
let
|
|
316
|
-
return e[35] !==
|
|
315
|
+
let C;
|
|
316
|
+
return e[35] !== b || e[36] !== S || e[37] !== T || e[38] !== E || e[39] !== s || e[40] !== g || e[41] !== B || e[42] !== w || e[43] !== o || e[44] !== i ? (C = /* @__PURE__ */ N(Ss, { instanceRef: s, overlayRef: o, controller: b, id: E, layers: g, mapStyle: B, getCursor: S, getTooltip: T, onLoad: d, onViewStateChange: w, ...i }), e[35] = b, e[36] = S, e[37] = T, e[38] = E, e[39] = s, e[40] = g, e[41] = B, e[42] = w, e[43] = o, e[44] = i, e[45] = C) : C = e[45], C;
|
|
317
317
|
}
|
|
318
318
|
function Fs(r) {
|
|
319
319
|
return r;
|
|
@@ -321,12 +321,12 @@ function Fs(r) {
|
|
|
321
321
|
function ks() {
|
|
322
322
|
return null;
|
|
323
323
|
}
|
|
324
|
-
const
|
|
324
|
+
const Cs = {
|
|
325
325
|
transitionDuration: "auto",
|
|
326
326
|
transitionInterpolator: new Vt({
|
|
327
327
|
curve: 2
|
|
328
328
|
})
|
|
329
|
-
},
|
|
329
|
+
}, As = (r) => {
|
|
330
330
|
const e = r.reduce((t, s) => {
|
|
331
331
|
const {
|
|
332
332
|
id: n,
|
|
@@ -347,12 +347,12 @@ const As = {
|
|
|
347
347
|
return (t, s) => ({
|
|
348
348
|
maps: e,
|
|
349
349
|
setBasemap: (n, o) => t((i) => {
|
|
350
|
-
var
|
|
350
|
+
var h;
|
|
351
351
|
const {
|
|
352
352
|
type: a
|
|
353
353
|
} = ye[i.maps[n].basemap], {
|
|
354
354
|
type: l
|
|
355
|
-
} = ye[o], c = a === l && !!((
|
|
355
|
+
} = ye[o], c = a === l && !!((h = i.maps[n]) != null && h.isLoaded);
|
|
356
356
|
return {
|
|
357
357
|
maps: {
|
|
358
358
|
...i.maps,
|
|
@@ -399,18 +399,18 @@ const As = {
|
|
|
399
399
|
return (c = l == null ? void 0 : l.getViewports(i)) == null ? void 0 : c[o];
|
|
400
400
|
},
|
|
401
401
|
getBounds: (n, o, i) => {
|
|
402
|
-
var
|
|
403
|
-
const a = s(), l = (
|
|
402
|
+
var h;
|
|
403
|
+
const a = s(), l = (h = a.getViewport) == null ? void 0 : h.call(a, n);
|
|
404
404
|
return l ? {
|
|
405
405
|
...l == null ? void 0 : l.fitBounds(o, i == null ? void 0 : i.boundsOptions),
|
|
406
406
|
...i == null ? void 0 : i.viewStateOptions
|
|
407
407
|
} : void 0;
|
|
408
408
|
},
|
|
409
409
|
addLayers: (n, o) => t((i) => {
|
|
410
|
-
var
|
|
410
|
+
var h;
|
|
411
411
|
const a = {
|
|
412
412
|
...i.maps
|
|
413
|
-
}, l = ((
|
|
413
|
+
}, l = ((h = a[n]) == null ? void 0 : h.layers) ?? [], c = /* @__PURE__ */ new Set([...l, ...o]);
|
|
414
414
|
return a[n] = {
|
|
415
415
|
...a[n],
|
|
416
416
|
layers: [...c]
|
|
@@ -425,7 +425,7 @@ const As = {
|
|
|
425
425
|
}, l = ((c = a[n]) == null ? void 0 : c.layers) ?? [];
|
|
426
426
|
return a[n] = {
|
|
427
427
|
...a[n],
|
|
428
|
-
layers: l.filter((
|
|
428
|
+
layers: l.filter((h) => !o.includes(h))
|
|
429
429
|
}, {
|
|
430
430
|
maps: a
|
|
431
431
|
};
|
|
@@ -522,7 +522,7 @@ const As = {
|
|
|
522
522
|
},
|
|
523
523
|
flyTo: (t, s, n = {}) => {
|
|
524
524
|
const o = e(), i = {
|
|
525
|
-
...
|
|
525
|
+
...Cs,
|
|
526
526
|
...n == null ? void 0 : n.viewStateOptions
|
|
527
527
|
}, a = {
|
|
528
528
|
...s,
|
|
@@ -542,7 +542,7 @@ const As = {
|
|
|
542
542
|
const s = e(), n = s.initialViewStates;
|
|
543
543
|
n[t] && s.flyTo(t, n[t]);
|
|
544
544
|
}
|
|
545
|
-
}),
|
|
545
|
+
}), xs = (r) => {
|
|
546
546
|
const e = r.reduce((t, s) => (t[s.id] = s.spatialFilter ?? {}, t), {});
|
|
547
547
|
return (t) => ({
|
|
548
548
|
spatialFilter: e,
|
|
@@ -558,11 +558,11 @@ const As = {
|
|
|
558
558
|
});
|
|
559
559
|
}
|
|
560
560
|
});
|
|
561
|
-
},
|
|
562
|
-
...
|
|
561
|
+
}, Us = (r) => ze()((...e) => ({
|
|
562
|
+
...As(r)(...e),
|
|
563
563
|
...Ds(r)(...e),
|
|
564
564
|
...Rs(r)(...e),
|
|
565
|
-
...
|
|
565
|
+
...xs(r)(...e),
|
|
566
566
|
...$s(...e)
|
|
567
567
|
})), St = He({});
|
|
568
568
|
function Bs(r) {
|
|
@@ -571,8 +571,8 @@ function Bs(r) {
|
|
|
571
571
|
values: s
|
|
572
572
|
} = r;
|
|
573
573
|
let n;
|
|
574
|
-
e[0] !== s ? (n =
|
|
575
|
-
const [o] =
|
|
574
|
+
e[0] !== s ? (n = Us(s), e[0] = s, e[1] = n) : n = e[1];
|
|
575
|
+
const [o] = se(n);
|
|
576
576
|
let i;
|
|
577
577
|
return e[2] !== t || e[3] !== o ? (i = /* @__PURE__ */ N(St.Provider, { value: o, children: t }), e[2] = t, e[3] = o, e[4] = i) : i = e[4], i;
|
|
578
578
|
}
|
|
@@ -588,12 +588,12 @@ function zr(r) {
|
|
|
588
588
|
mapId: s
|
|
589
589
|
} = r;
|
|
590
590
|
let n;
|
|
591
|
-
e[0] !== s ? (n = (
|
|
591
|
+
e[0] !== s ? (n = (h) => h.maps[s], e[0] = s, e[1] = n) : n = e[1];
|
|
592
592
|
const {
|
|
593
593
|
basemap: o
|
|
594
594
|
} = $(n), i = $(js);
|
|
595
595
|
let a;
|
|
596
|
-
e[2] !== s || e[3] !== i ? (a = (
|
|
596
|
+
e[2] !== s || e[3] !== i ? (a = (h) => i(s, h), e[2] = s, e[3] = i, e[4] = a) : a = e[4];
|
|
597
597
|
const l = a;
|
|
598
598
|
let c;
|
|
599
599
|
return e[5] !== o || e[6] !== t || e[7] !== l ? (c = t({
|
|
@@ -647,7 +647,7 @@ const ce = "lassoLayer", Le = "maskLayer", Vs = {
|
|
|
647
647
|
border: [71, 219, 153, 255],
|
|
648
648
|
fill: [71, 219, 153, 0]
|
|
649
649
|
}
|
|
650
|
-
},
|
|
650
|
+
}, xe = {
|
|
651
651
|
styles: {
|
|
652
652
|
colors: {
|
|
653
653
|
editing: Je.editing,
|
|
@@ -666,7 +666,7 @@ const ce = "lassoLayer", Le = "maskLayer", Vs = {
|
|
|
666
666
|
visible: !0,
|
|
667
667
|
extensions: Is,
|
|
668
668
|
filterRange: [1, 1]
|
|
669
|
-
},
|
|
669
|
+
}, Ue = {
|
|
670
670
|
polygon: {
|
|
671
671
|
value: "polygon",
|
|
672
672
|
mode: Wt
|
|
@@ -701,7 +701,7 @@ const ce = "lassoLayer", Le = "maskLayer", Vs = {
|
|
|
701
701
|
const o = n[e] ?? {
|
|
702
702
|
type: null,
|
|
703
703
|
props: {}
|
|
704
|
-
}, i = [...o.props.extensions ?? [], ...((l = t.props) == null ? void 0 : l.extensions) ?? []].reduce((
|
|
704
|
+
}, i = [...o.props.extensions ?? [], ...((l = t.props) == null ? void 0 : l.extensions) ?? []].reduce((h, p) => (h.some((y) => y.equals(p)) || h.push(p), h), []), a = o.legend || t.legend ? {
|
|
705
705
|
...o.legend,
|
|
706
706
|
...t.legend
|
|
707
707
|
} : void 0;
|
|
@@ -740,77 +740,77 @@ var Be, et;
|
|
|
740
740
|
function Ns() {
|
|
741
741
|
if (et) return Be;
|
|
742
742
|
et = 1;
|
|
743
|
-
var r = function(
|
|
744
|
-
return e(
|
|
743
|
+
var r = function(g) {
|
|
744
|
+
return e(g) && !t(g);
|
|
745
745
|
};
|
|
746
|
-
function e(
|
|
747
|
-
return !!
|
|
746
|
+
function e(u) {
|
|
747
|
+
return !!u && typeof u == "object";
|
|
748
748
|
}
|
|
749
|
-
function t(
|
|
750
|
-
var
|
|
751
|
-
return
|
|
749
|
+
function t(u) {
|
|
750
|
+
var g = Object.prototype.toString.call(u);
|
|
751
|
+
return g === "[object RegExp]" || g === "[object Date]" || o(u);
|
|
752
752
|
}
|
|
753
753
|
var s = typeof Symbol == "function" && Symbol.for, n = s ? Symbol.for("react.element") : 60103;
|
|
754
|
-
function o(
|
|
755
|
-
return
|
|
754
|
+
function o(u) {
|
|
755
|
+
return u.$$typeof === n;
|
|
756
756
|
}
|
|
757
|
-
function i(
|
|
758
|
-
return Array.isArray(
|
|
757
|
+
function i(u) {
|
|
758
|
+
return Array.isArray(u) ? [] : {};
|
|
759
759
|
}
|
|
760
|
-
function a(
|
|
761
|
-
return
|
|
760
|
+
function a(u, g) {
|
|
761
|
+
return g.clone !== !1 && g.isMergeableObject(u) ? b(i(u), u, g) : u;
|
|
762
762
|
}
|
|
763
|
-
function l(
|
|
764
|
-
return
|
|
765
|
-
return a(
|
|
763
|
+
function l(u, g, S) {
|
|
764
|
+
return u.concat(g).map(function(T) {
|
|
765
|
+
return a(T, S);
|
|
766
766
|
});
|
|
767
767
|
}
|
|
768
|
-
function c(
|
|
769
|
-
if (!
|
|
770
|
-
return
|
|
771
|
-
var S =
|
|
772
|
-
return typeof S == "function" ? S :
|
|
768
|
+
function c(u, g) {
|
|
769
|
+
if (!g.customMerge)
|
|
770
|
+
return b;
|
|
771
|
+
var S = g.customMerge(u);
|
|
772
|
+
return typeof S == "function" ? S : b;
|
|
773
773
|
}
|
|
774
|
-
function
|
|
775
|
-
return Object.getOwnPropertySymbols ? Object.getOwnPropertySymbols(
|
|
776
|
-
return Object.propertyIsEnumerable.call(
|
|
774
|
+
function h(u) {
|
|
775
|
+
return Object.getOwnPropertySymbols ? Object.getOwnPropertySymbols(u).filter(function(g) {
|
|
776
|
+
return Object.propertyIsEnumerable.call(u, g);
|
|
777
777
|
}) : [];
|
|
778
778
|
}
|
|
779
|
-
function p(
|
|
780
|
-
return Object.keys(
|
|
779
|
+
function p(u) {
|
|
780
|
+
return Object.keys(u).concat(h(u));
|
|
781
781
|
}
|
|
782
|
-
function y(
|
|
782
|
+
function y(u, g) {
|
|
783
783
|
try {
|
|
784
|
-
return
|
|
784
|
+
return g in u;
|
|
785
785
|
} catch {
|
|
786
786
|
return !1;
|
|
787
787
|
}
|
|
788
788
|
}
|
|
789
|
-
function
|
|
790
|
-
return y(
|
|
789
|
+
function f(u, g) {
|
|
790
|
+
return y(u, g) && !(Object.hasOwnProperty.call(u, g) && Object.propertyIsEnumerable.call(u, g));
|
|
791
791
|
}
|
|
792
|
-
function
|
|
793
|
-
var
|
|
794
|
-
return S.isMergeableObject(
|
|
795
|
-
|
|
796
|
-
}), p(
|
|
797
|
-
|
|
798
|
-
}),
|
|
792
|
+
function m(u, g, S) {
|
|
793
|
+
var T = {};
|
|
794
|
+
return S.isMergeableObject(u) && p(u).forEach(function(w) {
|
|
795
|
+
T[w] = a(u[w], S);
|
|
796
|
+
}), p(g).forEach(function(w) {
|
|
797
|
+
f(u, w) || (y(u, w) && S.isMergeableObject(g[w]) ? T[w] = c(w, S)(u[w], g[w], S) : T[w] = a(g[w], S));
|
|
798
|
+
}), T;
|
|
799
799
|
}
|
|
800
|
-
function
|
|
800
|
+
function b(u, g, S) {
|
|
801
801
|
S = S || {}, S.arrayMerge = S.arrayMerge || l, S.isMergeableObject = S.isMergeableObject || r, S.cloneUnlessOtherwiseSpecified = a;
|
|
802
|
-
var
|
|
803
|
-
return _ ?
|
|
802
|
+
var T = Array.isArray(g), w = Array.isArray(u), _ = T === w;
|
|
803
|
+
return _ ? T ? S.arrayMerge(u, g, S) : m(u, g, S) : a(g, S);
|
|
804
804
|
}
|
|
805
|
-
|
|
806
|
-
if (!Array.isArray(
|
|
805
|
+
b.all = function(g, S) {
|
|
806
|
+
if (!Array.isArray(g))
|
|
807
807
|
throw new Error("first argument should be an array");
|
|
808
|
-
return
|
|
809
|
-
return
|
|
808
|
+
return g.reduce(function(T, w) {
|
|
809
|
+
return b(T, w, S);
|
|
810
810
|
}, {});
|
|
811
811
|
};
|
|
812
|
-
var
|
|
813
|
-
return Be =
|
|
812
|
+
var E = b;
|
|
813
|
+
return Be = E, Be;
|
|
814
814
|
}
|
|
815
815
|
var Hs = Ns();
|
|
816
816
|
const ue = /* @__PURE__ */ wt(Hs), tt = ["anyclick", "pointermove", "panstart", "panmove", "panend", "keyup"];
|
|
@@ -895,17 +895,17 @@ const Qs = (r) => ze()((e) => ({
|
|
|
895
895
|
const {
|
|
896
896
|
enabled: o = !1,
|
|
897
897
|
mapId: i,
|
|
898
|
-
modeInstance: a = new
|
|
899
|
-
modes: l =
|
|
900
|
-
modeSelected: c =
|
|
901
|
-
values:
|
|
898
|
+
modeInstance: a = new Ue.polygon.mode(),
|
|
899
|
+
modes: l = Ue,
|
|
900
|
+
modeSelected: c = Ue.polygon.value,
|
|
901
|
+
values: h = {}
|
|
902
902
|
} = n;
|
|
903
903
|
return s[i] = {
|
|
904
904
|
enabled: o,
|
|
905
905
|
modeInstance: a,
|
|
906
906
|
modes: l,
|
|
907
907
|
modeSelected: c,
|
|
908
|
-
values:
|
|
908
|
+
values: h
|
|
909
909
|
}, s;
|
|
910
910
|
}, {}),
|
|
911
911
|
setEnabled: (s, n) => {
|
|
@@ -991,7 +991,7 @@ function Ws(r) {
|
|
|
991
991
|
} = r;
|
|
992
992
|
let n;
|
|
993
993
|
e[0] !== s ? (n = () => Qs(s), e[0] = s, e[1] = n) : n = e[1];
|
|
994
|
-
const [o] =
|
|
994
|
+
const [o] = se(n);
|
|
995
995
|
let i;
|
|
996
996
|
return e[2] !== t || e[3] !== o ? (i = /* @__PURE__ */ N(Et.Provider, { value: o, children: t }), e[2] = t, e[3] = o, e[4] = i) : i = e[4], i;
|
|
997
997
|
}
|
|
@@ -1005,44 +1005,44 @@ function Ks({
|
|
|
1005
1005
|
mapId: r,
|
|
1006
1006
|
children: e
|
|
1007
1007
|
}) {
|
|
1008
|
-
const t = G((
|
|
1009
|
-
var
|
|
1010
|
-
return (
|
|
1011
|
-
}), s = G((
|
|
1012
|
-
var
|
|
1013
|
-
return (
|
|
1014
|
-
}), o = G((
|
|
1015
|
-
var
|
|
1016
|
-
return (
|
|
1017
|
-
}), l = G((
|
|
1018
|
-
var
|
|
1019
|
-
return (
|
|
1020
|
-
}),
|
|
1008
|
+
const t = G((f) => {
|
|
1009
|
+
var m;
|
|
1010
|
+
return (m = f.data[r]) == null ? void 0 : m.enabled;
|
|
1011
|
+
}), s = G((f) => f.setEnabled), n = G((f) => {
|
|
1012
|
+
var m;
|
|
1013
|
+
return (m = f.data[r]) == null ? void 0 : m.values;
|
|
1014
|
+
}), o = G((f) => f.setValue), i = G((f) => f.setVisibility), a = G((f) => {
|
|
1015
|
+
var m;
|
|
1016
|
+
return (m = f.data[r]) == null ? void 0 : m.modeSelected;
|
|
1017
|
+
}), l = G((f) => f.setModeSelected), c = G((f) => {
|
|
1018
|
+
var m;
|
|
1019
|
+
return (m = f.data[r]) == null ? void 0 : m.modes;
|
|
1020
|
+
}), h = G((f) => f.setModeInstance);
|
|
1021
1021
|
z(() => {
|
|
1022
|
-
const
|
|
1023
|
-
if (
|
|
1024
|
-
const
|
|
1025
|
-
|
|
1022
|
+
const f = c[a];
|
|
1023
|
+
if (f && t) {
|
|
1024
|
+
const m = f.mode;
|
|
1025
|
+
h(r, new m());
|
|
1026
1026
|
}
|
|
1027
|
-
}, [t, r, a, c,
|
|
1027
|
+
}, [t, r, a, c, h]);
|
|
1028
1028
|
const [
|
|
1029
1029
|
p
|
|
1030
1030
|
// , draw
|
|
1031
|
-
] =
|
|
1032
|
-
const
|
|
1033
|
-
var
|
|
1031
|
+
] = oe(() => {
|
|
1032
|
+
const f = (E) => {
|
|
1033
|
+
var u;
|
|
1034
1034
|
return {
|
|
1035
|
-
id:
|
|
1036
|
-
visible:
|
|
1037
|
-
label: (
|
|
1035
|
+
id: E.id,
|
|
1036
|
+
visible: E.properties.visible,
|
|
1037
|
+
label: (u = E.properties) == null ? void 0 : u.label
|
|
1038
1038
|
};
|
|
1039
1039
|
};
|
|
1040
1040
|
return [
|
|
1041
|
-
Object.values(n).filter((
|
|
1041
|
+
Object.values(n).filter((E) => E.type === "mask").map(f)
|
|
1042
1042
|
// , draw
|
|
1043
1043
|
];
|
|
1044
|
-
}, [n]), y = Q((
|
|
1045
|
-
s(r, !!
|
|
1044
|
+
}, [n]), y = Q((f) => {
|
|
1045
|
+
s(r, !!f), l(r, f);
|
|
1046
1046
|
}, [r, s, l]);
|
|
1047
1047
|
return e({
|
|
1048
1048
|
mapId: r,
|
|
@@ -1053,9 +1053,9 @@ function Ks({
|
|
|
1053
1053
|
mask: p
|
|
1054
1054
|
// draw,
|
|
1055
1055
|
},
|
|
1056
|
-
setValue: Q((
|
|
1057
|
-
setEnabled: Q((
|
|
1058
|
-
setVisibility: Q((
|
|
1056
|
+
setValue: Q((f) => o(r, f), [r, o]),
|
|
1057
|
+
setEnabled: Q((f) => s(r, f), [r, s]),
|
|
1058
|
+
setVisibility: Q((f, m) => i(r, f, m), [r, i]),
|
|
1059
1059
|
setModeSelected: y
|
|
1060
1060
|
});
|
|
1061
1061
|
}
|
|
@@ -1085,9 +1085,9 @@ function Oe({
|
|
|
1085
1085
|
const o = e === Ie["m-km"], i = e === Ie["ft-mi"], a = o || i;
|
|
1086
1086
|
let l, c;
|
|
1087
1087
|
if (a) {
|
|
1088
|
-
const
|
|
1089
|
-
let p =
|
|
1090
|
-
l =
|
|
1088
|
+
const h = r < (s ?? nt);
|
|
1089
|
+
let p = h ? V.meter : V.kilometer;
|
|
1090
|
+
l = h ? me.meter : me.kilometer, i && (l = h ? me.feet : me.mile, p = h ? V.feet : V.mile), c = st(r, p);
|
|
1091
1091
|
} else
|
|
1092
1092
|
l = me[e], c = st(r, e);
|
|
1093
1093
|
return `${bt(c, t, {
|
|
@@ -1386,8 +1386,8 @@ class Pt extends Xt {
|
|
|
1386
1386
|
});
|
|
1387
1387
|
}
|
|
1388
1388
|
}
|
|
1389
|
-
const
|
|
1390
|
-
id:
|
|
1389
|
+
const re = "mapMeasureLayer", Js = {
|
|
1390
|
+
id: re,
|
|
1391
1391
|
pickable: !1,
|
|
1392
1392
|
billboard: !1,
|
|
1393
1393
|
editHandlePointRadiusUnits: "pixels",
|
|
@@ -1516,32 +1516,32 @@ function Lt(r) {
|
|
|
1516
1516
|
layerId: s
|
|
1517
1517
|
} = r;
|
|
1518
1518
|
let n;
|
|
1519
|
-
e[0] !== t ? (n = (
|
|
1520
|
-
var
|
|
1521
|
-
return (
|
|
1519
|
+
e[0] !== t ? (n = (m) => {
|
|
1520
|
+
var b;
|
|
1521
|
+
return (b = m.maps[t]) == null ? void 0 : b.basemap;
|
|
1522
1522
|
}, e[0] = t, e[1] = n) : n = e[1];
|
|
1523
1523
|
const o = $(n);
|
|
1524
1524
|
let i;
|
|
1525
|
-
e[2] !== t ? (i = (
|
|
1526
|
-
var
|
|
1527
|
-
return (
|
|
1525
|
+
e[2] !== t ? (i = (m) => {
|
|
1526
|
+
var b;
|
|
1527
|
+
return (b = m.maps[t]) == null ? void 0 : b.isLoaded;
|
|
1528
1528
|
}, e[2] = t, e[3] = i) : i = e[3];
|
|
1529
1529
|
const a = $(i), l = $(on), c = pe(rn), {
|
|
1530
|
-
type:
|
|
1531
|
-
} = ye[o], p =
|
|
1532
|
-
let y,
|
|
1530
|
+
type: h
|
|
1531
|
+
} = ye[o], p = h === te.googleMaps;
|
|
1532
|
+
let y, f;
|
|
1533
1533
|
e[4] !== l || e[5] !== p || e[6] !== a || e[7] !== s || e[8] !== t || e[9] !== c ? (y = () => {
|
|
1534
|
-
let
|
|
1534
|
+
let m = null;
|
|
1535
1535
|
if (p && a) {
|
|
1536
|
-
const
|
|
1537
|
-
|
|
1536
|
+
const b = l(t);
|
|
1537
|
+
m = new ss(b.getDiv(), {});
|
|
1538
1538
|
}
|
|
1539
1539
|
c(s, {
|
|
1540
1540
|
props: {
|
|
1541
|
-
eventManager:
|
|
1541
|
+
eventManager: m
|
|
1542
1542
|
}
|
|
1543
1543
|
});
|
|
1544
|
-
},
|
|
1544
|
+
}, f = [l, p, a, s, t, c], e[4] = l, e[5] = p, e[6] = a, e[7] = s, e[8] = t, e[9] = c, e[10] = y, e[11] = f) : (y = e[10], f = e[11]), z(y, f);
|
|
1545
1545
|
}
|
|
1546
1546
|
function rn(r) {
|
|
1547
1547
|
return r.setLayer;
|
|
@@ -1549,84 +1549,84 @@ function rn(r) {
|
|
|
1549
1549
|
function on(r) {
|
|
1550
1550
|
return r.getOverlayInstance;
|
|
1551
1551
|
}
|
|
1552
|
-
const an = [ce, Le,
|
|
1552
|
+
const an = [ce, Le, re];
|
|
1553
1553
|
function ln({
|
|
1554
1554
|
children: r,
|
|
1555
1555
|
mapId: e,
|
|
1556
1556
|
defaultProps: {
|
|
1557
|
-
styles: t =
|
|
1557
|
+
styles: t = xe.styles,
|
|
1558
1558
|
labels: s
|
|
1559
1559
|
} = {
|
|
1560
|
-
styles:
|
|
1561
|
-
labels:
|
|
1560
|
+
styles: xe.styles,
|
|
1561
|
+
labels: xe.labels
|
|
1562
1562
|
},
|
|
1563
1563
|
layerProps: n = {},
|
|
1564
1564
|
defaultType: o = "mask"
|
|
1565
1565
|
}) {
|
|
1566
1566
|
const i = G((M) => {
|
|
1567
|
-
var
|
|
1568
|
-
return (
|
|
1567
|
+
var k;
|
|
1568
|
+
return (k = M.data[e]) == null ? void 0 : k.enabled;
|
|
1569
1569
|
}), a = G((M) => M.setEnabled), l = G((M) => {
|
|
1570
|
-
var
|
|
1571
|
-
return (
|
|
1572
|
-
}), c = G((M) => M.setValue),
|
|
1573
|
-
var
|
|
1574
|
-
return (
|
|
1570
|
+
var k;
|
|
1571
|
+
return (k = M.data[e]) == null ? void 0 : k.values;
|
|
1572
|
+
}), c = G((M) => M.setValue), h = G((M) => {
|
|
1573
|
+
var k;
|
|
1574
|
+
return (k = M.data[e]) == null ? void 0 : k.modeInstance;
|
|
1575
1575
|
}), p = G((M) => {
|
|
1576
|
-
var
|
|
1577
|
-
return (
|
|
1578
|
-
}), y = pe((M) => M.setLayer),
|
|
1579
|
-
var
|
|
1580
|
-
return (
|
|
1581
|
-
})),
|
|
1576
|
+
var k;
|
|
1577
|
+
return (k = M.data[e]) == null ? void 0 : k.modeSelected;
|
|
1578
|
+
}), y = pe((M) => M.setLayer), f = $((M) => M.addLayers), m = $((M) => M.removeLayers), b = $(ht((M) => {
|
|
1579
|
+
var k;
|
|
1580
|
+
return (k = M.maps[e]) == null ? void 0 : k.layers.filter((d) => !an.includes(d));
|
|
1581
|
+
})), E = $((M) => M.getDeckInstance), u = Me({});
|
|
1582
1582
|
Lt({
|
|
1583
1583
|
mapId: e,
|
|
1584
1584
|
layerId: ce
|
|
1585
1585
|
});
|
|
1586
|
-
const
|
|
1586
|
+
const g = oe(() => _t({
|
|
1587
1587
|
values: l
|
|
1588
|
-
}), [l]), S =
|
|
1588
|
+
}), [l]), S = oe(() => ({
|
|
1589
1589
|
type: "FeatureCollection",
|
|
1590
|
-
features:
|
|
1590
|
+
features: g.map((M) => ({
|
|
1591
1591
|
type: "Feature",
|
|
1592
1592
|
geometry: M.geometry,
|
|
1593
1593
|
properties: M.properties,
|
|
1594
1594
|
id: M.id
|
|
1595
1595
|
}))
|
|
1596
|
-
}), [
|
|
1596
|
+
}), [g]), T = oe(() => g.filter((M) => M.properties.visible).map((M) => M.id), [g]), [w, _] = se(S), [F, x] = se([]), A = Q(() => {
|
|
1597
1597
|
const M = {
|
|
1598
1598
|
...S,
|
|
1599
|
-
features: S.features.filter((
|
|
1600
|
-
var
|
|
1601
|
-
return (
|
|
1599
|
+
features: S.features.filter((k) => {
|
|
1600
|
+
var d;
|
|
1601
|
+
return (d = k.properties) == null ? void 0 : d.visible;
|
|
1602
1602
|
})
|
|
1603
1603
|
};
|
|
1604
1604
|
_(M);
|
|
1605
1605
|
}, [S]);
|
|
1606
1606
|
z(() => {
|
|
1607
|
-
|
|
1608
|
-
}, [
|
|
1609
|
-
const j = Me(
|
|
1610
|
-
z(() => (
|
|
1611
|
-
|
|
1612
|
-
}), [
|
|
1607
|
+
A();
|
|
1608
|
+
}, [A]);
|
|
1609
|
+
const j = Me(g.length);
|
|
1610
|
+
z(() => (f(e, [ce]), () => {
|
|
1611
|
+
m(e, [ce]);
|
|
1612
|
+
}), [f, e, m]);
|
|
1613
1613
|
const B = Q(() => {
|
|
1614
|
-
|
|
1615
|
-
}, [e,
|
|
1614
|
+
A(), x([]), a(e, !1);
|
|
1615
|
+
}, [e, A, a]), U = Q(({
|
|
1616
1616
|
editType: M,
|
|
1617
|
-
updatedData:
|
|
1617
|
+
updatedData: k
|
|
1618
1618
|
}) => {
|
|
1619
1619
|
if (M === Y.cancel) {
|
|
1620
1620
|
B();
|
|
1621
1621
|
return;
|
|
1622
1622
|
}
|
|
1623
|
-
_(
|
|
1624
|
-
var
|
|
1625
|
-
(
|
|
1626
|
-
const P =
|
|
1623
|
+
_(k), M !== Y.updateTentativeFeature && M === Y.addFeature && (p !== "edit" && (j.current = j.current + 1), k.features.forEach((d, v) => {
|
|
1624
|
+
var C;
|
|
1625
|
+
(C = d.properties).label ?? (C.label = `${s == null ? void 0 : s.mask} ${j.current}`), d.properties.index = v, d.properties.visible = d.properties.visible ?? !0;
|
|
1626
|
+
const P = d.id ?? crypto.randomUUID();
|
|
1627
1627
|
c(e, P, {
|
|
1628
|
-
geometry:
|
|
1629
|
-
properties:
|
|
1628
|
+
geometry: d.geometry,
|
|
1629
|
+
properties: d.properties,
|
|
1630
1630
|
// visible: true,
|
|
1631
1631
|
type: o
|
|
1632
1632
|
});
|
|
@@ -1634,66 +1634,66 @@ function ln({
|
|
|
1634
1634
|
}, [o, B, s == null ? void 0 : s.mask, e, p, c]);
|
|
1635
1635
|
return z(() => {
|
|
1636
1636
|
const M = i, {
|
|
1637
|
-
border:
|
|
1638
|
-
point:
|
|
1637
|
+
border: k,
|
|
1638
|
+
point: d,
|
|
1639
1639
|
fill: v
|
|
1640
1640
|
} = t.colors.editing, {
|
|
1641
1641
|
border: P,
|
|
1642
|
-
fill:
|
|
1642
|
+
fill: C
|
|
1643
1643
|
} = t.colors.finished, L = Gs({
|
|
1644
1644
|
layerProps: {
|
|
1645
1645
|
...n.mask,
|
|
1646
1646
|
pickable: M,
|
|
1647
1647
|
data: w,
|
|
1648
|
-
selectedFeatureIndexes:
|
|
1648
|
+
selectedFeatureIndexes: F,
|
|
1649
1649
|
updateTriggers: {
|
|
1650
|
-
getFilterValue:
|
|
1650
|
+
getFilterValue: T
|
|
1651
1651
|
},
|
|
1652
1652
|
onClick: (O) => {
|
|
1653
1653
|
const H = O;
|
|
1654
|
-
H.isGuide ||
|
|
1654
|
+
H.isGuide || x([H.index]);
|
|
1655
1655
|
}
|
|
1656
1656
|
},
|
|
1657
|
-
getLineColor: (O) =>
|
|
1658
|
-
getFillColor: (O) =>
|
|
1657
|
+
getLineColor: (O) => F[0] === O.properties.index ? k : P,
|
|
1658
|
+
getFillColor: (O) => F[0] === O.properties.index ? v : C,
|
|
1659
1659
|
pointColor: {
|
|
1660
|
-
fill:
|
|
1661
|
-
outline:
|
|
1660
|
+
fill: d,
|
|
1661
|
+
outline: k
|
|
1662
1662
|
},
|
|
1663
|
-
onEdit:
|
|
1664
|
-
mode: M ?
|
|
1663
|
+
onEdit: U,
|
|
1664
|
+
mode: M ? h : new Jt()
|
|
1665
1665
|
});
|
|
1666
1666
|
y(ce, L);
|
|
1667
|
-
}, [w, i, n.mask,
|
|
1667
|
+
}, [w, i, n.mask, T, h, U, F, y, t.colors.editing, t.colors.finished]), z(() => {
|
|
1668
1668
|
const M = {
|
|
1669
1669
|
...Te,
|
|
1670
1670
|
data: S,
|
|
1671
|
-
getFilterValue: (
|
|
1671
|
+
getFilterValue: (k) => Number(T.includes(k.id)),
|
|
1672
1672
|
updateTriggers: {
|
|
1673
|
-
getFilterValue:
|
|
1673
|
+
getFilterValue: T
|
|
1674
1674
|
}
|
|
1675
1675
|
};
|
|
1676
1676
|
return y(Te.id, {
|
|
1677
1677
|
type: ns,
|
|
1678
1678
|
props: M
|
|
1679
|
-
}),
|
|
1680
|
-
|
|
1679
|
+
}), f(e, [Te.id]), () => {
|
|
1680
|
+
m(e, [Te.id]);
|
|
1681
1681
|
};
|
|
1682
|
-
}, [
|
|
1683
|
-
|
|
1682
|
+
}, [f, e, S, T, m, y]), z(() => {
|
|
1683
|
+
b == null || b.forEach((M) => {
|
|
1684
1684
|
var v;
|
|
1685
|
-
const
|
|
1686
|
-
i && (
|
|
1687
|
-
const
|
|
1685
|
+
const k = (v = E(e)) == null ? void 0 : v.props.layers.find((P) => P.props.id === M);
|
|
1686
|
+
i && (u.current[M] = k == null ? void 0 : k.props.pickable);
|
|
1687
|
+
const d = !i && (u.current[M] ?? (k == null ? void 0 : k.props.pickable));
|
|
1688
1688
|
y(M, {
|
|
1689
1689
|
props: {
|
|
1690
|
-
pickable:
|
|
1690
|
+
pickable: d,
|
|
1691
1691
|
extensions: [new ts()],
|
|
1692
|
-
maskId: !i &&
|
|
1692
|
+
maskId: !i && T.length ? Le : void 0
|
|
1693
1693
|
}
|
|
1694
1694
|
});
|
|
1695
1695
|
});
|
|
1696
|
-
}, [i,
|
|
1696
|
+
}, [i, E, e, b, T.length, y]), r;
|
|
1697
1697
|
}
|
|
1698
1698
|
ln.Controls = Ks;
|
|
1699
1699
|
function cn({
|
|
@@ -1747,8 +1747,8 @@ function un({
|
|
|
1747
1747
|
smoothing: 0.2
|
|
1748
1748
|
},
|
|
1749
1749
|
getText: (y) => {
|
|
1750
|
-
var
|
|
1751
|
-
return (
|
|
1750
|
+
var f;
|
|
1751
|
+
return (f = r == null ? void 0 : r.getTooltipText) == null ? void 0 : f.call(r, {
|
|
1752
1752
|
meters: y.text,
|
|
1753
1753
|
locale: t,
|
|
1754
1754
|
unit: n,
|
|
@@ -1760,7 +1760,7 @@ function un({
|
|
|
1760
1760
|
}
|
|
1761
1761
|
}
|
|
1762
1762
|
}
|
|
1763
|
-
}),
|
|
1763
|
+
}), h = ue(Js, {
|
|
1764
1764
|
_subLayerProps: {
|
|
1765
1765
|
guides: {
|
|
1766
1766
|
getLineColor: i,
|
|
@@ -1770,7 +1770,7 @@ function un({
|
|
|
1770
1770
|
getEditHandlePointColor: a,
|
|
1771
1771
|
getEditHandlePointOutlineColor: i
|
|
1772
1772
|
});
|
|
1773
|
-
return ue(
|
|
1773
|
+
return ue(h, c);
|
|
1774
1774
|
}
|
|
1775
1775
|
const dn = (r) => ze()((e) => ({
|
|
1776
1776
|
measurements: r.reduce((s, n) => {
|
|
@@ -1780,24 +1780,24 @@ const dn = (r) => ze()((e) => ({
|
|
|
1780
1780
|
modes: a = sn,
|
|
1781
1781
|
units: l = nn,
|
|
1782
1782
|
distance: c = 0,
|
|
1783
|
-
finished:
|
|
1783
|
+
finished: h = !1,
|
|
1784
1784
|
locale: p = "en",
|
|
1785
1785
|
positions: y = [],
|
|
1786
|
-
clearLayerOnStart:
|
|
1787
|
-
unit:
|
|
1788
|
-
enabled:
|
|
1786
|
+
clearLayerOnStart: f = !1,
|
|
1787
|
+
unit: m = Ie["m-km"],
|
|
1788
|
+
enabled: b = !1
|
|
1789
1789
|
} = n;
|
|
1790
1790
|
return s[o] = {
|
|
1791
1791
|
modes: a,
|
|
1792
1792
|
units: l,
|
|
1793
1793
|
modeSelected: i,
|
|
1794
1794
|
distance: c,
|
|
1795
|
-
finished:
|
|
1795
|
+
finished: h,
|
|
1796
1796
|
locale: p,
|
|
1797
1797
|
positions: y,
|
|
1798
|
-
unit:
|
|
1799
|
-
clearLayerOnStart:
|
|
1800
|
-
enabled:
|
|
1798
|
+
unit: m,
|
|
1799
|
+
clearLayerOnStart: f,
|
|
1800
|
+
enabled: b
|
|
1801
1801
|
}, s;
|
|
1802
1802
|
}, {}),
|
|
1803
1803
|
mode: Pt,
|
|
@@ -1897,7 +1897,7 @@ function fn(r) {
|
|
|
1897
1897
|
} = r;
|
|
1898
1898
|
let n;
|
|
1899
1899
|
e[0] !== s ? (n = dn(s), e[0] = s, e[1] = n) : n = e[1];
|
|
1900
|
-
const [o] =
|
|
1900
|
+
const [o] = se(n);
|
|
1901
1901
|
let i;
|
|
1902
1902
|
return e[2] !== t || e[3] !== o ? (i = /* @__PURE__ */ N(Ot.Provider, { value: o, children: t }), e[2] = t, e[3] = o, e[4] = i) : i = e[4], i;
|
|
1903
1903
|
}
|
|
@@ -1920,41 +1920,41 @@ function Ft(r) {
|
|
|
1920
1920
|
let a;
|
|
1921
1921
|
e[4] !== t ? (a = (R) => R.measurements[t].distance, e[4] = t, e[5] = a) : a = e[5];
|
|
1922
1922
|
const l = I(a), c = I(Sn);
|
|
1923
|
-
let
|
|
1924
|
-
e[6] !== c || e[7] !== t ? (
|
|
1925
|
-
const p =
|
|
1923
|
+
let h;
|
|
1924
|
+
e[6] !== c || e[7] !== t ? (h = (R) => c(t, R), e[6] = c, e[7] = t, e[8] = h) : h = e[8];
|
|
1925
|
+
const p = h;
|
|
1926
1926
|
let y;
|
|
1927
1927
|
e[9] !== t ? (y = (R) => R.measurements[t].clearLayerOnStart, e[9] = t, e[10] = y) : y = e[10];
|
|
1928
|
-
const
|
|
1929
|
-
let
|
|
1930
|
-
e[11] !== t ? (
|
|
1931
|
-
const
|
|
1932
|
-
let
|
|
1933
|
-
e[13] !==
|
|
1934
|
-
const
|
|
1928
|
+
const f = I(y);
|
|
1929
|
+
let m;
|
|
1930
|
+
e[11] !== t ? (m = (R) => R.measurements[t].enabled, e[11] = t, e[12] = m) : m = e[12];
|
|
1931
|
+
const b = I(m), E = I(vn);
|
|
1932
|
+
let u;
|
|
1933
|
+
e[13] !== E || e[14] !== t ? (u = (R) => E(t, R), e[13] = E, e[14] = t, e[15] = u) : u = e[15];
|
|
1934
|
+
const g = u;
|
|
1935
1935
|
let S;
|
|
1936
1936
|
e[16] !== t ? (S = (R) => R.measurements[t].modeSelected, e[16] = t, e[17] = S) : S = e[17];
|
|
1937
|
-
const
|
|
1937
|
+
const T = I(S), w = I(bn);
|
|
1938
1938
|
let _;
|
|
1939
|
-
e[18] !== w || e[19] !== t || e[20] !==
|
|
1940
|
-
|
|
1941
|
-
}, e[18] = w, e[19] = t, e[20] =
|
|
1942
|
-
const
|
|
1943
|
-
let
|
|
1944
|
-
e[22] !== t ? (
|
|
1945
|
-
const
|
|
1939
|
+
e[18] !== w || e[19] !== t || e[20] !== g ? (_ = (R) => {
|
|
1940
|
+
g(!!R), w(t, R);
|
|
1941
|
+
}, e[18] = w, e[19] = t, e[20] = g, e[21] = _) : _ = e[21];
|
|
1942
|
+
const F = _;
|
|
1943
|
+
let x;
|
|
1944
|
+
e[22] !== t ? (x = (R) => R.measurements[t].finished, e[22] = t, e[23] = x) : x = e[23];
|
|
1945
|
+
const A = I(x), j = I(gn);
|
|
1946
1946
|
let B;
|
|
1947
1947
|
e[24] !== j || e[25] !== t ? (B = (R) => j(t, R), e[24] = j, e[25] = t, e[26] = B) : B = e[26];
|
|
1948
|
-
const
|
|
1948
|
+
const U = B;
|
|
1949
1949
|
let M;
|
|
1950
1950
|
e[27] !== t ? (M = (R) => R.measurements[t].locale, e[27] = t, e[28] = M) : M = e[28];
|
|
1951
|
-
const
|
|
1951
|
+
const k = I(M), d = I(hn);
|
|
1952
1952
|
let v;
|
|
1953
|
-
e[29] !==
|
|
1953
|
+
e[29] !== d || e[30] !== t ? (v = (R) => d(t, R), e[29] = d, e[30] = t, e[31] = v) : v = e[31];
|
|
1954
1954
|
const P = v;
|
|
1955
|
-
let
|
|
1956
|
-
e[32] !== t ? (
|
|
1957
|
-
const L = I(
|
|
1955
|
+
let C;
|
|
1956
|
+
e[32] !== t ? (C = (R) => R.measurements[t].modeInstance, e[32] = t, e[33] = C) : C = e[33];
|
|
1957
|
+
const L = I(C), O = I(yn);
|
|
1958
1958
|
let H;
|
|
1959
1959
|
e[34] !== O || e[35] !== t ? (H = (R) => O(t, R), e[34] = O, e[35] = t, e[36] = H) : H = e[36];
|
|
1960
1960
|
const W = H;
|
|
@@ -1969,41 +1969,41 @@ function Ft(r) {
|
|
|
1969
1969
|
const Fe = I(ge), ke = I(pn);
|
|
1970
1970
|
let be;
|
|
1971
1971
|
e[44] !== ke || e[45] !== t ? (be = (R) => ke(t, R), e[44] = ke, e[45] = t, e[46] = be) : be = e[46];
|
|
1972
|
-
const
|
|
1972
|
+
const Ce = be;
|
|
1973
1973
|
let ve;
|
|
1974
1974
|
e[47] !== L || e[48] !== fe ? (ve = () => {
|
|
1975
1975
|
L == null || L.resetClickSequence(), fe([]);
|
|
1976
1976
|
}, e[47] = L, e[48] = fe, e[49] = ve) : ve = e[49];
|
|
1977
|
-
const
|
|
1977
|
+
const Ae = ve;
|
|
1978
1978
|
let Se;
|
|
1979
|
-
e[50] !==
|
|
1980
|
-
|
|
1981
|
-
}, e[50] =
|
|
1979
|
+
e[50] !== g ? (Se = (R) => {
|
|
1980
|
+
g(R);
|
|
1981
|
+
}, e[50] = g, e[51] = Se) : Se = e[51];
|
|
1982
1982
|
const De = Se;
|
|
1983
1983
|
let we;
|
|
1984
|
-
return e[52] !==
|
|
1984
|
+
return e[52] !== Ae || e[53] !== f || e[54] !== l || e[55] !== b || e[56] !== A || e[57] !== k || e[58] !== L || e[59] !== T || e[60] !== n || e[61] !== q || e[62] !== p || e[63] !== g || e[64] !== U || e[65] !== P || e[66] !== W || e[67] !== F || e[68] !== fe || e[69] !== Ce || e[70] !== De || e[71] !== Fe || e[72] !== i ? (we = {
|
|
1985
1985
|
modes: n,
|
|
1986
1986
|
units: i,
|
|
1987
1987
|
distance: l,
|
|
1988
|
-
clearLayerOnStart:
|
|
1989
|
-
modeSelected:
|
|
1990
|
-
enabled:
|
|
1991
|
-
finished:
|
|
1992
|
-
locale:
|
|
1988
|
+
clearLayerOnStart: f,
|
|
1989
|
+
modeSelected: T,
|
|
1990
|
+
enabled: b,
|
|
1991
|
+
finished: A,
|
|
1992
|
+
locale: k,
|
|
1993
1993
|
modeInstance: L,
|
|
1994
1994
|
positions: q,
|
|
1995
1995
|
unit: Fe,
|
|
1996
1996
|
setDistance: p,
|
|
1997
|
-
setModeSelected:
|
|
1998
|
-
setFinished:
|
|
1997
|
+
setModeSelected: F,
|
|
1998
|
+
setFinished: U,
|
|
1999
1999
|
setLocale: P,
|
|
2000
2000
|
setPositions: fe,
|
|
2001
|
-
setUnit:
|
|
2002
|
-
setEnabled:
|
|
2001
|
+
setUnit: Ce,
|
|
2002
|
+
setEnabled: g,
|
|
2003
2003
|
toggleLayer: De,
|
|
2004
|
-
clearLayer:
|
|
2004
|
+
clearLayer: Ae,
|
|
2005
2005
|
setModeInstance: W
|
|
2006
|
-
}, e[52] =
|
|
2006
|
+
}, e[52] = Ae, e[53] = f, e[54] = l, e[55] = b, e[56] = A, e[57] = k, e[58] = L, e[59] = T, e[60] = n, e[61] = q, e[62] = p, e[63] = g, e[64] = U, e[65] = P, e[66] = W, e[67] = F, e[68] = fe, e[69] = Ce, e[70] = De, e[71] = Fe, e[72] = i, e[73] = we) : we = e[73], we;
|
|
2007
2007
|
}
|
|
2008
2008
|
function pn(r) {
|
|
2009
2009
|
return r.setUnit;
|
|
@@ -2044,73 +2044,73 @@ function wn(r) {
|
|
|
2044
2044
|
units: a,
|
|
2045
2045
|
distance: l,
|
|
2046
2046
|
setDistance: c,
|
|
2047
|
-
clearLayerOnStart:
|
|
2047
|
+
clearLayerOnStart: h,
|
|
2048
2048
|
modeSelected: p,
|
|
2049
2049
|
setModeSelected: y,
|
|
2050
|
-
enabled:
|
|
2051
|
-
setEnabled:
|
|
2052
|
-
finished:
|
|
2053
|
-
setFinished:
|
|
2054
|
-
locale:
|
|
2055
|
-
setLocale:
|
|
2050
|
+
enabled: f,
|
|
2051
|
+
setEnabled: m,
|
|
2052
|
+
finished: b,
|
|
2053
|
+
setFinished: E,
|
|
2054
|
+
locale: u,
|
|
2055
|
+
setLocale: g,
|
|
2056
2056
|
modeInstance: S,
|
|
2057
|
-
setModeInstance:
|
|
2057
|
+
setModeInstance: T,
|
|
2058
2058
|
positions: w,
|
|
2059
2059
|
setPositions: _,
|
|
2060
|
-
unit:
|
|
2061
|
-
setUnit:
|
|
2062
|
-
clearLayer:
|
|
2060
|
+
unit: F,
|
|
2061
|
+
setUnit: x,
|
|
2062
|
+
clearLayer: A,
|
|
2063
2063
|
toggleLayer: j
|
|
2064
2064
|
} = Ft(o);
|
|
2065
2065
|
let B;
|
|
2066
|
-
e[2] !== p || e[3] !== i || e[4] !==
|
|
2066
|
+
e[2] !== p || e[3] !== i || e[4] !== T || e[5] !== _ ? (B = () => {
|
|
2067
2067
|
if (p && i[p]) {
|
|
2068
2068
|
const P = i[p].mode;
|
|
2069
|
-
|
|
2069
|
+
T(new P());
|
|
2070
2070
|
}
|
|
2071
2071
|
return () => {
|
|
2072
2072
|
_([]);
|
|
2073
2073
|
};
|
|
2074
|
-
}, e[2] = p, e[3] = i, e[4] =
|
|
2075
|
-
let
|
|
2076
|
-
e[7] !== p || e[8] !== i || e[9] !==
|
|
2074
|
+
}, e[2] = p, e[3] = i, e[4] = T, e[5] = _, e[6] = B) : B = e[6];
|
|
2075
|
+
let U;
|
|
2076
|
+
e[7] !== p || e[8] !== i || e[9] !== m || e[10] !== T || e[11] !== _ ? (U = [i, p, _, T, m], e[7] = p, e[8] = i, e[9] = m, e[10] = T, e[11] = _, e[12] = U) : U = e[12], z(B, U);
|
|
2077
2077
|
let M;
|
|
2078
|
-
e[13] !== j || e[14] !==
|
|
2079
|
-
P && (
|
|
2080
|
-
}, e[13] = j, e[14] =
|
|
2081
|
-
const
|
|
2078
|
+
e[13] !== j || e[14] !== A || e[15] !== h || e[16] !== b ? (M = (P) => {
|
|
2079
|
+
P && (h || !b) && A(), j(P);
|
|
2080
|
+
}, e[13] = j, e[14] = A, e[15] = h, e[16] = b, e[17] = M) : M = e[17];
|
|
2081
|
+
const k = M, d = !!h;
|
|
2082
2082
|
let v;
|
|
2083
|
-
return e[18] !== n || e[19] !==
|
|
2083
|
+
return e[18] !== n || e[19] !== A || e[20] !== l || e[21] !== f || e[22] !== b || e[23] !== u || e[24] !== t || e[25] !== S || e[26] !== p || e[27] !== i || e[28] !== w || e[29] !== c || e[30] !== m || e[31] !== E || e[32] !== g || e[33] !== y || e[34] !== _ || e[35] !== x || e[36] !== d || e[37] !== s || e[38] !== k || e[39] !== F || e[40] !== a ? (v = n({
|
|
2084
2084
|
mapId: t,
|
|
2085
2085
|
distance: l,
|
|
2086
|
-
enabled:
|
|
2087
|
-
finished:
|
|
2088
|
-
locale:
|
|
2086
|
+
enabled: f,
|
|
2087
|
+
finished: b,
|
|
2088
|
+
locale: u,
|
|
2089
2089
|
positions: w,
|
|
2090
|
-
unit:
|
|
2091
|
-
clearLayerOnStart:
|
|
2090
|
+
unit: F,
|
|
2091
|
+
clearLayerOnStart: d,
|
|
2092
2092
|
modeSelected: p,
|
|
2093
2093
|
modes: i,
|
|
2094
2094
|
units: a,
|
|
2095
2095
|
value: Oe({
|
|
2096
2096
|
meters: l,
|
|
2097
|
-
unit:
|
|
2098
|
-
locale:
|
|
2097
|
+
unit: F,
|
|
2098
|
+
locale: u,
|
|
2099
2099
|
options: s
|
|
2100
2100
|
}),
|
|
2101
2101
|
modeInstance: S,
|
|
2102
2102
|
setModeSelected: y,
|
|
2103
2103
|
setDistance: c,
|
|
2104
|
-
setFinished:
|
|
2105
|
-
setLocale:
|
|
2104
|
+
setFinished: E,
|
|
2105
|
+
setLocale: g,
|
|
2106
2106
|
setPositions: _,
|
|
2107
|
-
setUnit:
|
|
2108
|
-
setEnabled:
|
|
2109
|
-
toggleLayer:
|
|
2110
|
-
clearLayer:
|
|
2111
|
-
}), e[18] = n, e[19] =
|
|
2107
|
+
setUnit: x,
|
|
2108
|
+
setEnabled: m,
|
|
2109
|
+
toggleLayer: k,
|
|
2110
|
+
clearLayer: A
|
|
2111
|
+
}), e[18] = n, e[19] = A, e[20] = l, e[21] = f, e[22] = b, e[23] = u, e[24] = t, e[25] = S, e[26] = p, e[27] = i, e[28] = w, e[29] = c, e[30] = m, e[31] = E, e[32] = g, e[33] = y, e[34] = _, e[35] = x, e[36] = d, e[37] = s, e[38] = k, e[39] = F, e[40] = a, e[41] = v) : v = e[41], v;
|
|
2112
2112
|
}
|
|
2113
|
-
const Tn = [
|
|
2113
|
+
const Tn = [re];
|
|
2114
2114
|
function En({
|
|
2115
2115
|
children: r,
|
|
2116
2116
|
mapId: e,
|
|
@@ -2128,48 +2128,48 @@ function En({
|
|
|
2128
2128
|
enabled: a,
|
|
2129
2129
|
finished: l,
|
|
2130
2130
|
setFinished: c,
|
|
2131
|
-
locale:
|
|
2131
|
+
locale: h,
|
|
2132
2132
|
setPositions: p,
|
|
2133
2133
|
unit: y,
|
|
2134
|
-
modeInstance:
|
|
2134
|
+
modeInstance: f
|
|
2135
2135
|
} = Ft({
|
|
2136
2136
|
mapId: e
|
|
2137
|
-
}),
|
|
2137
|
+
}), m = pe((w) => w.setLayer), b = $((w) => w.addLayers), E = $((w) => w.removeLayers), u = $(ht((w) => {
|
|
2138
2138
|
var _;
|
|
2139
|
-
return (_ = w.maps[e]) == null ? void 0 : _.layers.filter((
|
|
2140
|
-
})),
|
|
2139
|
+
return (_ = w.maps[e]) == null ? void 0 : _.layers.filter((F) => !Tn.includes(F));
|
|
2140
|
+
})), g = $((w) => w.getDeckInstance), S = Me({});
|
|
2141
2141
|
Lt({
|
|
2142
2142
|
mapId: e,
|
|
2143
|
-
layerId:
|
|
2144
|
-
}), z(() => (a &&
|
|
2145
|
-
|
|
2146
|
-
}), [
|
|
2147
|
-
|
|
2148
|
-
var
|
|
2149
|
-
const _ = (
|
|
2143
|
+
layerId: re
|
|
2144
|
+
}), z(() => (a && b(e, [re]), () => {
|
|
2145
|
+
E(e, [re]);
|
|
2146
|
+
}), [b, i, e, E, a]), z(() => {
|
|
2147
|
+
u == null || u.forEach((w) => {
|
|
2148
|
+
var x;
|
|
2149
|
+
const _ = (x = g(e)) == null ? void 0 : x.props.layers.find((A) => A.props.id === w);
|
|
2150
2150
|
a && (S.current[w] = _ == null ? void 0 : _.props.pickable);
|
|
2151
|
-
const
|
|
2152
|
-
|
|
2151
|
+
const F = !a && (S.current[w] ?? (_ == null ? void 0 : _.props.pickable));
|
|
2152
|
+
m(w, {
|
|
2153
2153
|
props: {
|
|
2154
|
-
pickable:
|
|
2154
|
+
pickable: F
|
|
2155
2155
|
}
|
|
2156
2156
|
});
|
|
2157
2157
|
});
|
|
2158
|
-
}, [a,
|
|
2159
|
-
const
|
|
2158
|
+
}, [a, g, e, u, m]);
|
|
2159
|
+
const T = Q(({
|
|
2160
2160
|
editType: w,
|
|
2161
2161
|
editContext: _
|
|
2162
2162
|
}) => {
|
|
2163
2163
|
if (w === Y.cancel) {
|
|
2164
|
-
|
|
2164
|
+
f.resetClickSequence();
|
|
2165
2165
|
return;
|
|
2166
2166
|
}
|
|
2167
2167
|
w === Y.addPosition && o(_.distance), c(!!_.finished);
|
|
2168
|
-
const
|
|
2169
|
-
|
|
2170
|
-
}, [
|
|
2168
|
+
const F = _.positions;
|
|
2169
|
+
F != null && F.length && p(F);
|
|
2170
|
+
}, [f, o, c, p]);
|
|
2171
2171
|
return z(() => {
|
|
2172
|
-
const w = l ? t.colors.finished : t.colors.editing, _ = l ? t.colors.finished : t.colors.point,
|
|
2172
|
+
const w = l ? t.colors.finished : t.colors.editing, _ = l ? t.colors.finished : t.colors.point, F = cn({
|
|
2173
2173
|
layerProps: {
|
|
2174
2174
|
...s,
|
|
2175
2175
|
pickable: s.pickable ?? !l
|
|
@@ -2177,14 +2177,14 @@ function En({
|
|
|
2177
2177
|
enabled: a,
|
|
2178
2178
|
guideColor: w,
|
|
2179
2179
|
pointColor: _,
|
|
2180
|
-
locale:
|
|
2181
|
-
onEdit:
|
|
2180
|
+
locale: h,
|
|
2181
|
+
onEdit: T,
|
|
2182
2182
|
unit: y,
|
|
2183
|
-
mode:
|
|
2183
|
+
mode: f,
|
|
2184
2184
|
textOptions: n
|
|
2185
2185
|
});
|
|
2186
|
-
|
|
2187
|
-
}, [l,
|
|
2186
|
+
m(re, F);
|
|
2187
|
+
}, [l, f, s, h, T, m, t.colors.editing, t.colors.finished, t.colors.point, n, y, a]), r;
|
|
2188
2188
|
}
|
|
2189
2189
|
En.Controls = wn;
|
|
2190
2190
|
function _n(r) {
|
|
@@ -2199,7 +2199,7 @@ function _n(r) {
|
|
|
2199
2199
|
let i, a;
|
|
2200
2200
|
if (e[2] !== o || e[3] !== n) {
|
|
2201
2201
|
let c;
|
|
2202
|
-
e[5] !== o ? (c = (
|
|
2202
|
+
e[5] !== o ? (c = (h) => o[h], e[5] = o, e[6] = c) : c = e[6], a = n.map(c).filter(Mn), e[2] = o, e[3] = n, e[4] = a;
|
|
2203
2203
|
} else
|
|
2204
2204
|
a = e[4];
|
|
2205
2205
|
return i = a, i;
|
|
@@ -2210,7 +2210,7 @@ function Mn(r) {
|
|
|
2210
2210
|
function Pn(r) {
|
|
2211
2211
|
return r.layers;
|
|
2212
2212
|
}
|
|
2213
|
-
const at = [Le, ce,
|
|
2213
|
+
const at = [Le, ce, re];
|
|
2214
2214
|
function kt(r) {
|
|
2215
2215
|
const e = r.filter((s) => !at.includes(s.props.id)).sort((s, n) => (s.order ?? 1 / 0) - (n.order ?? 1 / 0)), t = at.map((s) => r.find((n) => n.props.id === s)).filter((s) => !!s);
|
|
2216
2216
|
return [...e, ...t];
|
|
@@ -2231,23 +2231,23 @@ function Wr(r) {
|
|
|
2231
2231
|
let l;
|
|
2232
2232
|
e[7] !== t ? (l = (L) => L.maps[t].instanceRef, e[7] = t, e[8] = l) : l = e[8];
|
|
2233
2233
|
const c = $(l);
|
|
2234
|
-
let
|
|
2235
|
-
e[9] !== t ? (
|
|
2236
|
-
const p = $(
|
|
2237
|
-
let
|
|
2238
|
-
e[11] !== t ? (
|
|
2239
|
-
const
|
|
2240
|
-
let
|
|
2241
|
-
e[13] !== t ? (
|
|
2234
|
+
let h;
|
|
2235
|
+
e[9] !== t ? (h = (L) => L.maps[t].overlayRef, e[9] = t, e[10] = h) : h = e[10];
|
|
2236
|
+
const p = $(h), y = Me(null);
|
|
2237
|
+
let f;
|
|
2238
|
+
e[11] !== t ? (f = (L) => L.viewStates[t], e[11] = t, e[12] = f) : f = e[12];
|
|
2239
|
+
const m = $(f), b = $(Dn), E = $(An), u = $(Cn), g = $(kn), S = $(Fn);
|
|
2240
|
+
let T;
|
|
2241
|
+
e[13] !== t ? (T = {
|
|
2242
2242
|
mapId: t
|
|
2243
|
-
}, e[13] = t, e[14] =
|
|
2244
|
-
const w = _n(
|
|
2245
|
-
let _,
|
|
2246
|
-
e[15] !== w ? (
|
|
2247
|
-
const
|
|
2248
|
-
let
|
|
2249
|
-
e[17] !== t || e[18] !== n || e[19] !==
|
|
2250
|
-
const O =
|
|
2243
|
+
}, e[13] = t, e[14] = T) : T = e[14];
|
|
2244
|
+
const w = _n(T);
|
|
2245
|
+
let _, F;
|
|
2246
|
+
e[15] !== w ? (F = kt(w), e[15] = w, e[16] = F) : F = e[16], _ = F;
|
|
2247
|
+
const x = _;
|
|
2248
|
+
let A;
|
|
2249
|
+
e[17] !== t || e[18] !== n || e[19] !== E || e[20] !== S ? (A = (L) => {
|
|
2250
|
+
const O = E;
|
|
2251
2251
|
if (y.current && clearInterval(y.current), y.current = setTimeout(() => {
|
|
2252
2252
|
S(t);
|
|
2253
2253
|
}, Ln), n) {
|
|
@@ -2255,28 +2255,28 @@ function Wr(r) {
|
|
|
2255
2255
|
return;
|
|
2256
2256
|
}
|
|
2257
2257
|
O(t, L.viewState);
|
|
2258
|
-
}, e[17] = t, e[18] = n, e[19] =
|
|
2259
|
-
const j =
|
|
2258
|
+
}, e[17] = t, e[18] = n, e[19] = E, e[20] = S, e[21] = A) : A = e[21];
|
|
2259
|
+
const j = A;
|
|
2260
2260
|
let B;
|
|
2261
|
-
e[22] !== t || e[23] !== s || e[24] !==
|
|
2262
|
-
|
|
2263
|
-
}, e[22] = t, e[23] = s, e[24] =
|
|
2264
|
-
const
|
|
2261
|
+
e[22] !== t || e[23] !== s || e[24] !== u || e[25] !== S ? (B = (L) => {
|
|
2262
|
+
u(t, L), s == null || s(L), S(t);
|
|
2263
|
+
}, e[22] = t, e[23] = s, e[24] = u, e[25] = S, e[26] = B) : B = e[26];
|
|
2264
|
+
const U = B;
|
|
2265
2265
|
let M;
|
|
2266
|
-
e[27] !==
|
|
2266
|
+
e[27] !== b || e[28] !== t || e[29] !== o || e[30] !== g ? (M = (L) => {
|
|
2267
2267
|
var W, K;
|
|
2268
|
-
const O = (W =
|
|
2269
|
-
|
|
2270
|
-
}, e[27] =
|
|
2271
|
-
const
|
|
2268
|
+
const O = (W = b(t)) == null ? void 0 : W.props.layers, H = !!(O != null && O.every(On));
|
|
2269
|
+
g(t, H), (K = o.onAfterRender) == null || K.call(o, L);
|
|
2270
|
+
}, e[27] = b, e[28] = t, e[29] = o, e[30] = g, e[31] = M) : M = e[31];
|
|
2271
|
+
const k = M, d = o.onDragEnd;
|
|
2272
2272
|
let v;
|
|
2273
|
-
e[32] !==
|
|
2273
|
+
e[32] !== d || e[33] !== t || e[34] !== S ? (v = (...L) => {
|
|
2274
2274
|
const O = L;
|
|
2275
|
-
S(t),
|
|
2276
|
-
}, e[32] =
|
|
2275
|
+
S(t), d && d(...O);
|
|
2276
|
+
}, e[32] = d, e[33] = t, e[34] = S, e[35] = v) : v = e[35];
|
|
2277
2277
|
const P = v;
|
|
2278
|
-
let
|
|
2279
|
-
return e[36] !== a || e[37] !==
|
|
2278
|
+
let C;
|
|
2279
|
+
return e[36] !== a || e[37] !== x || e[38] !== k || e[39] !== P || e[40] !== U || e[41] !== j || e[42] !== t || e[43] !== c || e[44] !== p || e[45] !== o || e[46] !== m ? (C = /* @__PURE__ */ N(Os, { ...o, id: t, layers: x, instanceRef: c, overlayRef: p, basemap: a, initialViewState: m, onLoad: U, onViewStateChange: j, onAfterRender: k, onDragEnd: P }), e[36] = a, e[37] = x, e[38] = k, e[39] = P, e[40] = U, e[41] = j, e[42] = t, e[43] = c, e[44] = p, e[45] = o, e[46] = m, e[47] = C) : C = e[47], C;
|
|
2280
2280
|
}
|
|
2281
2281
|
function On(r) {
|
|
2282
2282
|
return r == null ? void 0 : r.isLoaded;
|
|
@@ -2287,10 +2287,10 @@ function Fn(r) {
|
|
|
2287
2287
|
function kn(r) {
|
|
2288
2288
|
return r.setLayersLoad;
|
|
2289
2289
|
}
|
|
2290
|
-
function
|
|
2290
|
+
function Cn(r) {
|
|
2291
2291
|
return r.setLoad;
|
|
2292
2292
|
}
|
|
2293
|
-
function
|
|
2293
|
+
function An(r) {
|
|
2294
2294
|
return r.setViewState;
|
|
2295
2295
|
}
|
|
2296
2296
|
function Dn(r) {
|
|
@@ -2321,11 +2321,11 @@ function Rn() {
|
|
|
2321
2321
|
formData: "FormData" in a,
|
|
2322
2322
|
arrayBuffer: "ArrayBuffer" in a
|
|
2323
2323
|
};
|
|
2324
|
-
function c(
|
|
2325
|
-
return
|
|
2324
|
+
function c(d) {
|
|
2325
|
+
return d && DataView.prototype.isPrototypeOf(d);
|
|
2326
2326
|
}
|
|
2327
2327
|
if (l.arrayBuffer)
|
|
2328
|
-
var
|
|
2328
|
+
var h = [
|
|
2329
2329
|
"[object Int8Array]",
|
|
2330
2330
|
"[object Uint8Array]",
|
|
2331
2331
|
"[object Uint8ClampedArray]",
|
|
@@ -2335,21 +2335,21 @@ function Rn() {
|
|
|
2335
2335
|
"[object Uint32Array]",
|
|
2336
2336
|
"[object Float32Array]",
|
|
2337
2337
|
"[object Float64Array]"
|
|
2338
|
-
], p = ArrayBuffer.isView || function(
|
|
2339
|
-
return
|
|
2338
|
+
], p = ArrayBuffer.isView || function(d) {
|
|
2339
|
+
return d && h.indexOf(Object.prototype.toString.call(d)) > -1;
|
|
2340
2340
|
};
|
|
2341
|
-
function y(
|
|
2342
|
-
if (typeof
|
|
2343
|
-
throw new TypeError('Invalid character in header field name: "' +
|
|
2344
|
-
return
|
|
2341
|
+
function y(d) {
|
|
2342
|
+
if (typeof d != "string" && (d = String(d)), /[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(d) || d === "")
|
|
2343
|
+
throw new TypeError('Invalid character in header field name: "' + d + '"');
|
|
2344
|
+
return d.toLowerCase();
|
|
2345
2345
|
}
|
|
2346
|
-
function d
|
|
2347
|
-
return typeof
|
|
2346
|
+
function f(d) {
|
|
2347
|
+
return typeof d != "string" && (d = String(d)), d;
|
|
2348
2348
|
}
|
|
2349
|
-
function
|
|
2349
|
+
function m(d) {
|
|
2350
2350
|
var v = {
|
|
2351
2351
|
next: function() {
|
|
2352
|
-
var P =
|
|
2352
|
+
var P = d.shift();
|
|
2353
2353
|
return { done: P === void 0, value: P };
|
|
2354
2354
|
}
|
|
2355
2355
|
};
|
|
@@ -2357,90 +2357,90 @@ function Rn() {
|
|
|
2357
2357
|
return v;
|
|
2358
2358
|
}), v;
|
|
2359
2359
|
}
|
|
2360
|
-
function
|
|
2361
|
-
this.map = {},
|
|
2360
|
+
function b(d) {
|
|
2361
|
+
this.map = {}, d instanceof b ? d.forEach(function(v, P) {
|
|
2362
2362
|
this.append(P, v);
|
|
2363
|
-
}, this) : Array.isArray(
|
|
2363
|
+
}, this) : Array.isArray(d) ? d.forEach(function(v) {
|
|
2364
2364
|
if (v.length != 2)
|
|
2365
2365
|
throw new TypeError("Headers constructor: expected name/value pair to be length 2, found" + v.length);
|
|
2366
2366
|
this.append(v[0], v[1]);
|
|
2367
|
-
}, this) :
|
|
2368
|
-
this.append(v,
|
|
2367
|
+
}, this) : d && Object.getOwnPropertyNames(d).forEach(function(v) {
|
|
2368
|
+
this.append(v, d[v]);
|
|
2369
2369
|
}, this);
|
|
2370
2370
|
}
|
|
2371
|
-
|
|
2372
|
-
|
|
2373
|
-
var P = this.map[
|
|
2374
|
-
this.map[
|
|
2375
|
-
},
|
|
2376
|
-
delete this.map[y(
|
|
2377
|
-
},
|
|
2378
|
-
return
|
|
2379
|
-
},
|
|
2380
|
-
return this.map.hasOwnProperty(y(
|
|
2381
|
-
},
|
|
2382
|
-
this.map[y(
|
|
2383
|
-
},
|
|
2371
|
+
b.prototype.append = function(d, v) {
|
|
2372
|
+
d = y(d), v = f(v);
|
|
2373
|
+
var P = this.map[d];
|
|
2374
|
+
this.map[d] = P ? P + ", " + v : v;
|
|
2375
|
+
}, b.prototype.delete = function(d) {
|
|
2376
|
+
delete this.map[y(d)];
|
|
2377
|
+
}, b.prototype.get = function(d) {
|
|
2378
|
+
return d = y(d), this.has(d) ? this.map[d] : null;
|
|
2379
|
+
}, b.prototype.has = function(d) {
|
|
2380
|
+
return this.map.hasOwnProperty(y(d));
|
|
2381
|
+
}, b.prototype.set = function(d, v) {
|
|
2382
|
+
this.map[y(d)] = f(v);
|
|
2383
|
+
}, b.prototype.forEach = function(d, v) {
|
|
2384
2384
|
for (var P in this.map)
|
|
2385
|
-
this.map.hasOwnProperty(P) &&
|
|
2386
|
-
},
|
|
2387
|
-
var
|
|
2385
|
+
this.map.hasOwnProperty(P) && d.call(v, this.map[P], P, this);
|
|
2386
|
+
}, b.prototype.keys = function() {
|
|
2387
|
+
var d = [];
|
|
2388
2388
|
return this.forEach(function(v, P) {
|
|
2389
|
-
|
|
2390
|
-
}),
|
|
2391
|
-
},
|
|
2392
|
-
var
|
|
2389
|
+
d.push(P);
|
|
2390
|
+
}), m(d);
|
|
2391
|
+
}, b.prototype.values = function() {
|
|
2392
|
+
var d = [];
|
|
2393
2393
|
return this.forEach(function(v) {
|
|
2394
|
-
|
|
2395
|
-
}),
|
|
2396
|
-
},
|
|
2397
|
-
var
|
|
2394
|
+
d.push(v);
|
|
2395
|
+
}), m(d);
|
|
2396
|
+
}, b.prototype.entries = function() {
|
|
2397
|
+
var d = [];
|
|
2398
2398
|
return this.forEach(function(v, P) {
|
|
2399
|
-
|
|
2400
|
-
}),
|
|
2401
|
-
}, l.iterable && (
|
|
2402
|
-
function
|
|
2403
|
-
if (!
|
|
2404
|
-
if (
|
|
2399
|
+
d.push([P, v]);
|
|
2400
|
+
}), m(d);
|
|
2401
|
+
}, l.iterable && (b.prototype[Symbol.iterator] = b.prototype.entries);
|
|
2402
|
+
function E(d) {
|
|
2403
|
+
if (!d._noBody) {
|
|
2404
|
+
if (d.bodyUsed)
|
|
2405
2405
|
return Promise.reject(new TypeError("Already read"));
|
|
2406
|
-
|
|
2406
|
+
d.bodyUsed = !0;
|
|
2407
2407
|
}
|
|
2408
2408
|
}
|
|
2409
|
-
function
|
|
2409
|
+
function u(d) {
|
|
2410
2410
|
return new Promise(function(v, P) {
|
|
2411
|
-
|
|
2412
|
-
v(
|
|
2413
|
-
},
|
|
2414
|
-
P(
|
|
2411
|
+
d.onload = function() {
|
|
2412
|
+
v(d.result);
|
|
2413
|
+
}, d.onerror = function() {
|
|
2414
|
+
P(d.error);
|
|
2415
2415
|
};
|
|
2416
2416
|
});
|
|
2417
2417
|
}
|
|
2418
|
-
function
|
|
2419
|
-
var v = new FileReader(), P =
|
|
2420
|
-
return v.readAsArrayBuffer(
|
|
2418
|
+
function g(d) {
|
|
2419
|
+
var v = new FileReader(), P = u(v);
|
|
2420
|
+
return v.readAsArrayBuffer(d), P;
|
|
2421
2421
|
}
|
|
2422
|
-
function S(
|
|
2423
|
-
var v = new FileReader(), P =
|
|
2424
|
-
return v.readAsText(
|
|
2422
|
+
function S(d) {
|
|
2423
|
+
var v = new FileReader(), P = u(v), C = /charset=([A-Za-z0-9_-]+)/.exec(d.type), L = C ? C[1] : "utf-8";
|
|
2424
|
+
return v.readAsText(d, L), P;
|
|
2425
2425
|
}
|
|
2426
|
-
function
|
|
2427
|
-
for (var v = new Uint8Array(
|
|
2428
|
-
P[
|
|
2426
|
+
function T(d) {
|
|
2427
|
+
for (var v = new Uint8Array(d), P = new Array(v.length), C = 0; C < v.length; C++)
|
|
2428
|
+
P[C] = String.fromCharCode(v[C]);
|
|
2429
2429
|
return P.join("");
|
|
2430
2430
|
}
|
|
2431
|
-
function w(
|
|
2432
|
-
if (
|
|
2433
|
-
return
|
|
2434
|
-
var v = new Uint8Array(
|
|
2435
|
-
return v.set(new Uint8Array(
|
|
2431
|
+
function w(d) {
|
|
2432
|
+
if (d.slice)
|
|
2433
|
+
return d.slice(0);
|
|
2434
|
+
var v = new Uint8Array(d.byteLength);
|
|
2435
|
+
return v.set(new Uint8Array(d)), v.buffer;
|
|
2436
2436
|
}
|
|
2437
2437
|
function _() {
|
|
2438
|
-
return this.bodyUsed = !1, this._initBody = function(
|
|
2439
|
-
this.bodyUsed = this.bodyUsed, this._bodyInit =
|
|
2438
|
+
return this.bodyUsed = !1, this._initBody = function(d) {
|
|
2439
|
+
this.bodyUsed = this.bodyUsed, this._bodyInit = d, d ? typeof d == "string" ? this._bodyText = d : l.blob && Blob.prototype.isPrototypeOf(d) ? this._bodyBlob = d : l.formData && FormData.prototype.isPrototypeOf(d) ? this._bodyFormData = d : l.searchParams && URLSearchParams.prototype.isPrototypeOf(d) ? this._bodyText = d.toString() : l.arrayBuffer && l.blob && c(d) ? (this._bodyArrayBuffer = w(d.buffer), this._bodyInit = new Blob([this._bodyArrayBuffer])) : l.arrayBuffer && (ArrayBuffer.prototype.isPrototypeOf(d) || p(d)) ? this._bodyArrayBuffer = w(d) : this._bodyText = d = Object.prototype.toString.call(d) : (this._noBody = !0, this._bodyText = ""), this.headers.get("content-type") || (typeof d == "string" ? this.headers.set("content-type", "text/plain;charset=UTF-8") : this._bodyBlob && this._bodyBlob.type ? this.headers.set("content-type", this._bodyBlob.type) : l.searchParams && URLSearchParams.prototype.isPrototypeOf(d) && this.headers.set("content-type", "application/x-www-form-urlencoded;charset=UTF-8"));
|
|
2440
2440
|
}, l.blob && (this.blob = function() {
|
|
2441
|
-
var
|
|
2442
|
-
if (
|
|
2443
|
-
return
|
|
2441
|
+
var d = E(this);
|
|
2442
|
+
if (d)
|
|
2443
|
+
return d;
|
|
2444
2444
|
if (this._bodyBlob)
|
|
2445
2445
|
return Promise.resolve(this._bodyBlob);
|
|
2446
2446
|
if (this._bodyArrayBuffer)
|
|
@@ -2450,8 +2450,8 @@ function Rn() {
|
|
|
2450
2450
|
return Promise.resolve(new Blob([this._bodyText]));
|
|
2451
2451
|
}), this.arrayBuffer = function() {
|
|
2452
2452
|
if (this._bodyArrayBuffer) {
|
|
2453
|
-
var
|
|
2454
|
-
return
|
|
2453
|
+
var d = E(this);
|
|
2454
|
+
return d || (ArrayBuffer.isView(this._bodyArrayBuffer) ? Promise.resolve(
|
|
2455
2455
|
this._bodyArrayBuffer.buffer.slice(
|
|
2456
2456
|
this._bodyArrayBuffer.byteOffset,
|
|
2457
2457
|
this._bodyArrayBuffer.byteOffset + this._bodyArrayBuffer.byteLength
|
|
@@ -2459,17 +2459,17 @@ function Rn() {
|
|
|
2459
2459
|
) : Promise.resolve(this._bodyArrayBuffer));
|
|
2460
2460
|
} else {
|
|
2461
2461
|
if (l.blob)
|
|
2462
|
-
return this.blob().then(
|
|
2462
|
+
return this.blob().then(g);
|
|
2463
2463
|
throw new Error("could not read as ArrayBuffer");
|
|
2464
2464
|
}
|
|
2465
2465
|
}, this.text = function() {
|
|
2466
|
-
var
|
|
2467
|
-
if (
|
|
2468
|
-
return
|
|
2466
|
+
var d = E(this);
|
|
2467
|
+
if (d)
|
|
2468
|
+
return d;
|
|
2469
2469
|
if (this._bodyBlob)
|
|
2470
2470
|
return S(this._bodyBlob);
|
|
2471
2471
|
if (this._bodyArrayBuffer)
|
|
2472
|
-
return Promise.resolve(
|
|
2472
|
+
return Promise.resolve(T(this._bodyArrayBuffer));
|
|
2473
2473
|
if (this._bodyFormData)
|
|
2474
2474
|
throw new Error("could not read FormData body as text");
|
|
2475
2475
|
return Promise.resolve(this._bodyText);
|
|
@@ -2479,23 +2479,23 @@ function Rn() {
|
|
|
2479
2479
|
return this.text().then(JSON.parse);
|
|
2480
2480
|
}, this;
|
|
2481
2481
|
}
|
|
2482
|
-
var
|
|
2483
|
-
function
|
|
2484
|
-
var v =
|
|
2485
|
-
return
|
|
2482
|
+
var F = ["CONNECT", "DELETE", "GET", "HEAD", "OPTIONS", "PATCH", "POST", "PUT", "TRACE"];
|
|
2483
|
+
function x(d) {
|
|
2484
|
+
var v = d.toUpperCase();
|
|
2485
|
+
return F.indexOf(v) > -1 ? v : d;
|
|
2486
2486
|
}
|
|
2487
|
-
function
|
|
2488
|
-
if (!(this instanceof
|
|
2487
|
+
function A(d, v) {
|
|
2488
|
+
if (!(this instanceof A))
|
|
2489
2489
|
throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');
|
|
2490
2490
|
v = v || {};
|
|
2491
2491
|
var P = v.body;
|
|
2492
|
-
if (
|
|
2493
|
-
if (
|
|
2492
|
+
if (d instanceof A) {
|
|
2493
|
+
if (d.bodyUsed)
|
|
2494
2494
|
throw new TypeError("Already read");
|
|
2495
|
-
this.url =
|
|
2495
|
+
this.url = d.url, this.credentials = d.credentials, v.headers || (this.headers = new b(d.headers)), this.method = d.method, this.mode = d.mode, this.signal = d.signal, !P && d._bodyInit != null && (P = d._bodyInit, d.bodyUsed = !0);
|
|
2496
2496
|
} else
|
|
2497
|
-
this.url = String(
|
|
2498
|
-
if (this.credentials = v.credentials || this.credentials || "same-origin", (v.headers || !this.headers) && (this.headers = new
|
|
2497
|
+
this.url = String(d);
|
|
2498
|
+
if (this.credentials = v.credentials || this.credentials || "same-origin", (v.headers || !this.headers) && (this.headers = new b(v.headers)), this.method = x(v.method || this.method || "GET"), this.mode = v.mode || this.mode || null, this.signal = v.signal || this.signal || function() {
|
|
2499
2499
|
if ("AbortController" in a) {
|
|
2500
2500
|
var O = new AbortController();
|
|
2501
2501
|
return O.signal;
|
|
@@ -2503,34 +2503,34 @@ function Rn() {
|
|
|
2503
2503
|
}(), this.referrer = null, (this.method === "GET" || this.method === "HEAD") && P)
|
|
2504
2504
|
throw new TypeError("Body not allowed for GET or HEAD requests");
|
|
2505
2505
|
if (this._initBody(P), (this.method === "GET" || this.method === "HEAD") && (v.cache === "no-store" || v.cache === "no-cache")) {
|
|
2506
|
-
var
|
|
2507
|
-
if (
|
|
2508
|
-
this.url = this.url.replace(
|
|
2506
|
+
var C = /([?&])_=[^&]*/;
|
|
2507
|
+
if (C.test(this.url))
|
|
2508
|
+
this.url = this.url.replace(C, "$1_=" + (/* @__PURE__ */ new Date()).getTime());
|
|
2509
2509
|
else {
|
|
2510
2510
|
var L = /\?/;
|
|
2511
2511
|
this.url += (L.test(this.url) ? "&" : "?") + "_=" + (/* @__PURE__ */ new Date()).getTime();
|
|
2512
2512
|
}
|
|
2513
2513
|
}
|
|
2514
2514
|
}
|
|
2515
|
-
|
|
2516
|
-
return new
|
|
2515
|
+
A.prototype.clone = function() {
|
|
2516
|
+
return new A(this, { body: this._bodyInit });
|
|
2517
2517
|
};
|
|
2518
|
-
function j(
|
|
2518
|
+
function j(d) {
|
|
2519
2519
|
var v = new FormData();
|
|
2520
|
-
return
|
|
2520
|
+
return d.trim().split("&").forEach(function(P) {
|
|
2521
2521
|
if (P) {
|
|
2522
|
-
var
|
|
2522
|
+
var C = P.split("="), L = C.shift().replace(/\+/g, " "), O = C.join("=").replace(/\+/g, " ");
|
|
2523
2523
|
v.append(decodeURIComponent(L), decodeURIComponent(O));
|
|
2524
2524
|
}
|
|
2525
2525
|
}), v;
|
|
2526
2526
|
}
|
|
2527
|
-
function B(
|
|
2528
|
-
var v = new
|
|
2529
|
-
return P.split("\r").map(function(
|
|
2530
|
-
return
|
|
2531
|
-
`) === 0 ?
|
|
2532
|
-
}).forEach(function(
|
|
2533
|
-
var L =
|
|
2527
|
+
function B(d) {
|
|
2528
|
+
var v = new b(), P = d.replace(/\r?\n[\t ]+/g, " ");
|
|
2529
|
+
return P.split("\r").map(function(C) {
|
|
2530
|
+
return C.indexOf(`
|
|
2531
|
+
`) === 0 ? C.substr(1, C.length) : C;
|
|
2532
|
+
}).forEach(function(C) {
|
|
2533
|
+
var L = C.split(":"), O = L.shift().trim();
|
|
2534
2534
|
if (O) {
|
|
2535
2535
|
var H = L.join(":").trim();
|
|
2536
2536
|
try {
|
|
@@ -2541,45 +2541,45 @@ function Rn() {
|
|
|
2541
2541
|
}
|
|
2542
2542
|
}), v;
|
|
2543
2543
|
}
|
|
2544
|
-
_.call(
|
|
2545
|
-
function
|
|
2546
|
-
if (!(this instanceof
|
|
2544
|
+
_.call(A.prototype);
|
|
2545
|
+
function U(d, v) {
|
|
2546
|
+
if (!(this instanceof U))
|
|
2547
2547
|
throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');
|
|
2548
2548
|
if (v || (v = {}), this.type = "default", this.status = v.status === void 0 ? 200 : v.status, this.status < 200 || this.status > 599)
|
|
2549
2549
|
throw new RangeError("Failed to construct 'Response': The status provided (0) is outside the range [200, 599].");
|
|
2550
|
-
this.ok = this.status >= 200 && this.status < 300, this.statusText = v.statusText === void 0 ? "" : "" + v.statusText, this.headers = new
|
|
2550
|
+
this.ok = this.status >= 200 && this.status < 300, this.statusText = v.statusText === void 0 ? "" : "" + v.statusText, this.headers = new b(v.headers), this.url = v.url || "", this._initBody(d);
|
|
2551
2551
|
}
|
|
2552
|
-
_.call(
|
|
2553
|
-
return new
|
|
2552
|
+
_.call(U.prototype), U.prototype.clone = function() {
|
|
2553
|
+
return new U(this._bodyInit, {
|
|
2554
2554
|
status: this.status,
|
|
2555
2555
|
statusText: this.statusText,
|
|
2556
|
-
headers: new
|
|
2556
|
+
headers: new b(this.headers),
|
|
2557
2557
|
url: this.url
|
|
2558
2558
|
});
|
|
2559
|
-
},
|
|
2560
|
-
var
|
|
2561
|
-
return
|
|
2559
|
+
}, U.error = function() {
|
|
2560
|
+
var d = new U(null, { status: 200, statusText: "" });
|
|
2561
|
+
return d.ok = !1, d.status = 0, d.type = "error", d;
|
|
2562
2562
|
};
|
|
2563
2563
|
var M = [301, 302, 303, 307, 308];
|
|
2564
|
-
|
|
2564
|
+
U.redirect = function(d, v) {
|
|
2565
2565
|
if (M.indexOf(v) === -1)
|
|
2566
2566
|
throw new RangeError("Invalid status code");
|
|
2567
|
-
return new
|
|
2567
|
+
return new U(null, { status: v, headers: { location: d } });
|
|
2568
2568
|
}, i.DOMException = a.DOMException;
|
|
2569
2569
|
try {
|
|
2570
2570
|
new i.DOMException();
|
|
2571
2571
|
} catch {
|
|
2572
2572
|
i.DOMException = function(v, P) {
|
|
2573
2573
|
this.message = v, this.name = P;
|
|
2574
|
-
var
|
|
2575
|
-
this.stack =
|
|
2574
|
+
var C = Error(v);
|
|
2575
|
+
this.stack = C.stack;
|
|
2576
2576
|
}, i.DOMException.prototype = Object.create(Error.prototype), i.DOMException.prototype.constructor = i.DOMException;
|
|
2577
2577
|
}
|
|
2578
|
-
function
|
|
2579
|
-
return new Promise(function(P,
|
|
2580
|
-
var L = new
|
|
2578
|
+
function k(d, v) {
|
|
2579
|
+
return new Promise(function(P, C) {
|
|
2580
|
+
var L = new A(d, v);
|
|
2581
2581
|
if (L.signal && L.signal.aborted)
|
|
2582
|
-
return
|
|
2582
|
+
return C(new i.DOMException("Aborted", "AbortError"));
|
|
2583
2583
|
var O = new XMLHttpRequest();
|
|
2584
2584
|
function H() {
|
|
2585
2585
|
O.abort();
|
|
@@ -2592,19 +2592,19 @@ function Rn() {
|
|
|
2592
2592
|
L.url.indexOf("file://") === 0 && (O.status < 200 || O.status > 599) ? q.status = 200 : q.status = O.status, q.url = "responseURL" in O ? O.responseURL : q.headers.get("X-Request-URL");
|
|
2593
2593
|
var X = "response" in O ? O.response : O.responseText;
|
|
2594
2594
|
setTimeout(function() {
|
|
2595
|
-
P(new
|
|
2595
|
+
P(new U(X, q));
|
|
2596
2596
|
}, 0);
|
|
2597
2597
|
}, O.onerror = function() {
|
|
2598
2598
|
setTimeout(function() {
|
|
2599
|
-
|
|
2599
|
+
C(new TypeError("Network request failed"));
|
|
2600
2600
|
}, 0);
|
|
2601
2601
|
}, O.ontimeout = function() {
|
|
2602
2602
|
setTimeout(function() {
|
|
2603
|
-
|
|
2603
|
+
C(new TypeError("Network request timed out"));
|
|
2604
2604
|
}, 0);
|
|
2605
2605
|
}, O.onabort = function() {
|
|
2606
2606
|
setTimeout(function() {
|
|
2607
|
-
|
|
2607
|
+
C(new i.DOMException("Aborted", "AbortError"));
|
|
2608
2608
|
}, 0);
|
|
2609
2609
|
};
|
|
2610
2610
|
function W(q) {
|
|
@@ -2614,10 +2614,10 @@ function Rn() {
|
|
|
2614
2614
|
return q;
|
|
2615
2615
|
}
|
|
2616
2616
|
}
|
|
2617
|
-
if (O.open(L.method, W(L.url), !0), L.credentials === "include" ? O.withCredentials = !0 : L.credentials === "omit" && (O.withCredentials = !1), "responseType" in O && (l.blob ? O.responseType = "blob" : l.arrayBuffer && (O.responseType = "arraybuffer")), v && typeof v.headers == "object" && !(v.headers instanceof
|
|
2617
|
+
if (O.open(L.method, W(L.url), !0), L.credentials === "include" ? O.withCredentials = !0 : L.credentials === "omit" && (O.withCredentials = !1), "responseType" in O && (l.blob ? O.responseType = "blob" : l.arrayBuffer && (O.responseType = "arraybuffer")), v && typeof v.headers == "object" && !(v.headers instanceof b || a.Headers && v.headers instanceof a.Headers)) {
|
|
2618
2618
|
var K = [];
|
|
2619
2619
|
Object.getOwnPropertyNames(v.headers).forEach(function(q) {
|
|
2620
|
-
K.push(y(q)), O.setRequestHeader(q,
|
|
2620
|
+
K.push(y(q)), O.setRequestHeader(q, f(v.headers[q]));
|
|
2621
2621
|
}), L.headers.forEach(function(q, X) {
|
|
2622
2622
|
K.indexOf(X) === -1 && O.setRequestHeader(X, q);
|
|
2623
2623
|
});
|
|
@@ -2630,7 +2630,7 @@ function Rn() {
|
|
|
2630
2630
|
}), O.send(typeof L._bodyInit > "u" ? null : L._bodyInit);
|
|
2631
2631
|
});
|
|
2632
2632
|
}
|
|
2633
|
-
return
|
|
2633
|
+
return k.polyfill = !0, a.fetch || (a.fetch = k, a.Headers = b, a.Request = A, a.Response = U), i.Headers = b, i.Request = A, i.Response = U, i.fetch = k, i;
|
|
2634
2634
|
})({});
|
|
2635
2635
|
})(s), s.fetch.ponyfill = !0, delete s.fetch.polyfill;
|
|
2636
2636
|
var n = t.fetch ? t : s;
|
|
@@ -2638,7 +2638,7 @@ function Rn() {
|
|
|
2638
2638
|
}(_e, _e.exports)), _e.exports;
|
|
2639
2639
|
}
|
|
2640
2640
|
var $n = Rn();
|
|
2641
|
-
const
|
|
2641
|
+
const xn = /* @__PURE__ */ wt($n), We = "https://gcp-us-east1.api.carto.com", Ke = "v3", Un = "ps", de = {
|
|
2642
2642
|
get: "GET",
|
|
2643
2643
|
post: "POST"
|
|
2644
2644
|
};
|
|
@@ -2660,75 +2660,75 @@ var qe, ct;
|
|
|
2660
2660
|
function Vn() {
|
|
2661
2661
|
if (ct) return qe;
|
|
2662
2662
|
ct = 1;
|
|
2663
|
-
var r = function(
|
|
2664
|
-
return e(
|
|
2663
|
+
var r = function(u) {
|
|
2664
|
+
return e(u) && !t(u);
|
|
2665
2665
|
};
|
|
2666
|
-
function e(
|
|
2667
|
-
return !!
|
|
2666
|
+
function e(u) {
|
|
2667
|
+
return !!u && typeof u == "object";
|
|
2668
2668
|
}
|
|
2669
|
-
function t(
|
|
2670
|
-
var
|
|
2671
|
-
return
|
|
2669
|
+
function t(u) {
|
|
2670
|
+
var g = Object.prototype.toString.call(u);
|
|
2671
|
+
return g === "[object RegExp]" || g === "[object Date]" || o(u);
|
|
2672
2672
|
}
|
|
2673
2673
|
var s = typeof Symbol == "function" && Symbol.for, n = s ? Symbol.for("react.element") : 60103;
|
|
2674
|
-
function o(
|
|
2675
|
-
return
|
|
2674
|
+
function o(u) {
|
|
2675
|
+
return u.$$typeof === n;
|
|
2676
2676
|
}
|
|
2677
|
-
function i(
|
|
2678
|
-
return Array.isArray(
|
|
2677
|
+
function i(u) {
|
|
2678
|
+
return Array.isArray(u) ? [] : {};
|
|
2679
2679
|
}
|
|
2680
|
-
function a(
|
|
2681
|
-
return
|
|
2680
|
+
function a(u, g) {
|
|
2681
|
+
return g.clone !== !1 && g.isMergeableObject(u) ? b(i(u), u, g) : u;
|
|
2682
2682
|
}
|
|
2683
|
-
function l(
|
|
2684
|
-
return
|
|
2685
|
-
return a(
|
|
2683
|
+
function l(u, g, S) {
|
|
2684
|
+
return u.concat(g).map(function(T) {
|
|
2685
|
+
return a(T, S);
|
|
2686
2686
|
});
|
|
2687
2687
|
}
|
|
2688
|
-
function c(
|
|
2689
|
-
if (!
|
|
2690
|
-
var S =
|
|
2691
|
-
return typeof S == "function" ? S :
|
|
2688
|
+
function c(u, g) {
|
|
2689
|
+
if (!g.customMerge) return b;
|
|
2690
|
+
var S = g.customMerge(u);
|
|
2691
|
+
return typeof S == "function" ? S : b;
|
|
2692
2692
|
}
|
|
2693
|
-
function
|
|
2694
|
-
return Object.getOwnPropertySymbols ? Object.getOwnPropertySymbols(
|
|
2695
|
-
return Object.propertyIsEnumerable.call(
|
|
2693
|
+
function h(u) {
|
|
2694
|
+
return Object.getOwnPropertySymbols ? Object.getOwnPropertySymbols(u).filter(function(g) {
|
|
2695
|
+
return Object.propertyIsEnumerable.call(u, g);
|
|
2696
2696
|
}) : [];
|
|
2697
2697
|
}
|
|
2698
|
-
function p(
|
|
2699
|
-
return Object.keys(
|
|
2698
|
+
function p(u) {
|
|
2699
|
+
return Object.keys(u).concat(h(u));
|
|
2700
2700
|
}
|
|
2701
|
-
function y(
|
|
2701
|
+
function y(u, g) {
|
|
2702
2702
|
try {
|
|
2703
|
-
return
|
|
2703
|
+
return g in u;
|
|
2704
2704
|
} catch {
|
|
2705
2705
|
return !1;
|
|
2706
2706
|
}
|
|
2707
2707
|
}
|
|
2708
|
-
function
|
|
2709
|
-
return y(
|
|
2708
|
+
function f(u, g) {
|
|
2709
|
+
return y(u, g) && !(Object.hasOwnProperty.call(u, g) && Object.propertyIsEnumerable.call(u, g));
|
|
2710
2710
|
}
|
|
2711
|
-
function
|
|
2712
|
-
var
|
|
2713
|
-
return S.isMergeableObject(
|
|
2714
|
-
|
|
2715
|
-
}), p(
|
|
2716
|
-
|
|
2717
|
-
}),
|
|
2711
|
+
function m(u, g, S) {
|
|
2712
|
+
var T = {};
|
|
2713
|
+
return S.isMergeableObject(u) && p(u).forEach(function(w) {
|
|
2714
|
+
T[w] = a(u[w], S);
|
|
2715
|
+
}), p(g).forEach(function(w) {
|
|
2716
|
+
f(u, w) || (y(u, w) && S.isMergeableObject(g[w]) ? T[w] = c(w, S)(u[w], g[w], S) : T[w] = a(g[w], S));
|
|
2717
|
+
}), T;
|
|
2718
2718
|
}
|
|
2719
|
-
function
|
|
2719
|
+
function b(u, g, S) {
|
|
2720
2720
|
S = S || {}, S.arrayMerge = S.arrayMerge || l, S.isMergeableObject = S.isMergeableObject || r, S.cloneUnlessOtherwiseSpecified = a;
|
|
2721
|
-
var
|
|
2722
|
-
return _ ?
|
|
2721
|
+
var T = Array.isArray(g), w = Array.isArray(u), _ = T === w;
|
|
2722
|
+
return _ ? T ? S.arrayMerge(u, g, S) : m(u, g, S) : a(g, S);
|
|
2723
2723
|
}
|
|
2724
|
-
|
|
2725
|
-
if (!Array.isArray(
|
|
2726
|
-
return
|
|
2727
|
-
return
|
|
2724
|
+
b.all = function(u, g) {
|
|
2725
|
+
if (!Array.isArray(u)) throw new Error("first argument should be an array");
|
|
2726
|
+
return u.reduce(function(S, T) {
|
|
2727
|
+
return b(S, T, g);
|
|
2728
2728
|
}, {});
|
|
2729
2729
|
};
|
|
2730
|
-
var
|
|
2731
|
-
return qe =
|
|
2730
|
+
var E = b;
|
|
2731
|
+
return qe = E, qe;
|
|
2732
2732
|
}
|
|
2733
2733
|
var In = Vn();
|
|
2734
2734
|
const Ze = /* @__PURE__ */ qn(In);
|
|
@@ -2774,7 +2774,7 @@ function Hn({
|
|
|
2774
2774
|
}, s), r);
|
|
2775
2775
|
}
|
|
2776
2776
|
const Gn = 6144;
|
|
2777
|
-
async function
|
|
2777
|
+
async function Ct({
|
|
2778
2778
|
signal: r,
|
|
2779
2779
|
body: e,
|
|
2780
2780
|
accessToken: t,
|
|
@@ -2792,95 +2792,111 @@ async function At({
|
|
|
2792
2792
|
let c = jn({
|
|
2793
2793
|
url: i,
|
|
2794
2794
|
params: o
|
|
2795
|
-
}),
|
|
2796
|
-
n === de.get && c.length > a && (
|
|
2795
|
+
}), h = e, p = n;
|
|
2796
|
+
n === de.get && c.length > a && (h = o, p = de.post, c = i);
|
|
2797
2797
|
const y = Hn({
|
|
2798
|
-
body:
|
|
2798
|
+
body: h,
|
|
2799
2799
|
accessToken: t ?? (s == null ? void 0 : s.accessToken),
|
|
2800
2800
|
method: p,
|
|
2801
2801
|
...l
|
|
2802
2802
|
});
|
|
2803
2803
|
r && (y.signal = r);
|
|
2804
|
-
const
|
|
2805
|
-
if (!
|
|
2806
|
-
const
|
|
2807
|
-
return Promise.reject(new Error(
|
|
2804
|
+
const f = await xn(c, y);
|
|
2805
|
+
if (!f.ok) {
|
|
2806
|
+
const m = await f.text();
|
|
2807
|
+
return Promise.reject(new Error(m));
|
|
2808
2808
|
}
|
|
2809
|
-
return
|
|
2809
|
+
return f.status === 204 ? Promise.resolve() : await f.json();
|
|
2810
2810
|
}
|
|
2811
|
-
const Pe = mt()(hs((r) => ({
|
|
2811
|
+
const Pe = mt()(hs((r, e) => ({
|
|
2812
2812
|
sources: {},
|
|
2813
2813
|
filters: {},
|
|
2814
|
-
setSource: (
|
|
2815
|
-
var
|
|
2816
|
-
const
|
|
2817
|
-
...
|
|
2818
|
-
},
|
|
2819
|
-
if (
|
|
2820
|
-
return delete
|
|
2821
|
-
sources:
|
|
2814
|
+
setSource: (t, s) => r((n) => {
|
|
2815
|
+
var m;
|
|
2816
|
+
const o = {
|
|
2817
|
+
...n.sources
|
|
2818
|
+
}, i = (m = o[t]) == null ? void 0 : m.widgets;
|
|
2819
|
+
if (i && (i.destroy(), delete o[t].widgets), !s)
|
|
2820
|
+
return delete o[t], {
|
|
2821
|
+
sources: o
|
|
2822
2822
|
};
|
|
2823
|
-
const
|
|
2824
|
-
apiBaseUrl:
|
|
2825
|
-
clientId:
|
|
2826
|
-
apiVersion:
|
|
2827
|
-
...
|
|
2828
|
-
} =
|
|
2829
|
-
...
|
|
2830
|
-
...
|
|
2831
|
-
apiBaseUrl:
|
|
2832
|
-
apiVersion:
|
|
2833
|
-
clientId:
|
|
2834
|
-
},
|
|
2835
|
-
source:
|
|
2823
|
+
const a = o[t], {
|
|
2824
|
+
apiBaseUrl: l = We,
|
|
2825
|
+
clientId: c = Un,
|
|
2826
|
+
apiVersion: h = Ke,
|
|
2827
|
+
...p
|
|
2828
|
+
} = s, y = {
|
|
2829
|
+
...a,
|
|
2830
|
+
...p,
|
|
2831
|
+
apiBaseUrl: l,
|
|
2832
|
+
apiVersion: h,
|
|
2833
|
+
clientId: c
|
|
2834
|
+
}, f = Wn({
|
|
2835
|
+
source: y
|
|
2836
2836
|
});
|
|
2837
|
-
return
|
|
2838
|
-
sources:
|
|
2837
|
+
return y.widgets = f, o[t] = y, {
|
|
2838
|
+
sources: o
|
|
2839
2839
|
};
|
|
2840
2840
|
}, void 0, "setSource"),
|
|
2841
|
-
removeSource: (
|
|
2842
|
-
var
|
|
2843
|
-
const
|
|
2844
|
-
...
|
|
2845
|
-
},
|
|
2846
|
-
return
|
|
2847
|
-
sources:
|
|
2841
|
+
removeSource: (t) => r((s) => {
|
|
2842
|
+
var i;
|
|
2843
|
+
const n = {
|
|
2844
|
+
...s.sources
|
|
2845
|
+
}, o = (i = n[t]) == null ? void 0 : i.widgets;
|
|
2846
|
+
return o && (o.destroy(), delete n[t].widgets), delete n[t], {
|
|
2847
|
+
sources: n
|
|
2848
2848
|
};
|
|
2849
2849
|
}, void 0, "removeSource"),
|
|
2850
|
-
setFilters: (
|
|
2851
|
-
let
|
|
2852
|
-
const
|
|
2853
|
-
return
|
|
2854
|
-
var
|
|
2855
|
-
return !("values" in
|
|
2856
|
-
},
|
|
2850
|
+
setFilters: (t, s) => r((n) => {
|
|
2851
|
+
let o = {};
|
|
2852
|
+
const i = n.filters[t] ?? {};
|
|
2853
|
+
return s.length !== 0 && (o = s.reduce((a, l) => {
|
|
2854
|
+
var c;
|
|
2855
|
+
return !("values" in l) || !((c = l.values) != null && c.length) ? Xe(a, l) : vt(a, l);
|
|
2856
|
+
}, i)), {
|
|
2857
2857
|
filters: {
|
|
2858
|
-
...
|
|
2859
|
-
[
|
|
2860
|
-
...
|
|
2858
|
+
...n.filters,
|
|
2859
|
+
[t]: {
|
|
2860
|
+
...o
|
|
2861
2861
|
}
|
|
2862
2862
|
// important: destructuring here to not conservere the reference to the same object
|
|
2863
2863
|
}
|
|
2864
2864
|
};
|
|
2865
2865
|
}, void 0, "setFilters"),
|
|
2866
|
-
removeFilters: (
|
|
2867
|
-
const
|
|
2868
|
-
if (!
|
|
2869
|
-
return
|
|
2870
|
-
let
|
|
2871
|
-
return
|
|
2872
|
-
column:
|
|
2873
|
-
owner:
|
|
2866
|
+
removeFilters: (t, s, n) => r((o) => {
|
|
2867
|
+
const i = o.filters[t] ?? {};
|
|
2868
|
+
if (!i)
|
|
2869
|
+
return o;
|
|
2870
|
+
let a = {};
|
|
2871
|
+
return s && (a = Xe(i, {
|
|
2872
|
+
column: s,
|
|
2873
|
+
owner: n
|
|
2874
2874
|
})), {
|
|
2875
2875
|
filters: {
|
|
2876
|
-
...
|
|
2877
|
-
[
|
|
2878
|
-
...
|
|
2876
|
+
...o.filters,
|
|
2877
|
+
[t]: {
|
|
2878
|
+
...a
|
|
2879
2879
|
}
|
|
2880
2880
|
// important: destructuring here to not conservere the reference to the same object
|
|
2881
2881
|
}
|
|
2882
2882
|
};
|
|
2883
|
-
}, void 0, "removeFilters")
|
|
2883
|
+
}, void 0, "removeFilters"),
|
|
2884
|
+
invalidateSourcesCache: (t, {
|
|
2885
|
+
timeout: s = 500
|
|
2886
|
+
} = {}) => {
|
|
2887
|
+
t.forEach((n) => {
|
|
2888
|
+
e().setSource(n, {
|
|
2889
|
+
headers: {
|
|
2890
|
+
"Cache-Control": "no-cache, max-age=10"
|
|
2891
|
+
}
|
|
2892
|
+
});
|
|
2893
|
+
}), setTimeout(() => {
|
|
2894
|
+
t.forEach((n) => {
|
|
2895
|
+
const o = e().sources[n];
|
|
2896
|
+
o && (delete o.headers, e().setSource(n, o));
|
|
2897
|
+
});
|
|
2898
|
+
}, s);
|
|
2899
|
+
}
|
|
2884
2900
|
})));
|
|
2885
2901
|
function zn(r) {
|
|
2886
2902
|
const e = D(2);
|
|
@@ -2970,7 +2986,7 @@ function Wn({
|
|
|
2970
2986
|
}
|
|
2971
2987
|
function ie(r, e) {
|
|
2972
2988
|
const t = zn(e);
|
|
2973
|
-
return
|
|
2989
|
+
return oe(() => {
|
|
2974
2990
|
const s = t == null ? void 0 : t.widgets;
|
|
2975
2991
|
return !s || !r ? null : (s.props.accessToken = r, s);
|
|
2976
2992
|
}, [r, t]);
|
|
@@ -3012,28 +3028,28 @@ function Zn(r) {
|
|
|
3012
3028
|
enabled: l,
|
|
3013
3029
|
...c
|
|
3014
3030
|
} = a, e[2] = a, e[3] = l, e[4] = c) : (l = e[3], c = e[4]);
|
|
3015
|
-
const
|
|
3016
|
-
let
|
|
3017
|
-
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (
|
|
3018
|
-
let
|
|
3019
|
-
e[10] !== p || e[11] !== y || e[12] !== n ? (
|
|
3031
|
+
const h = l === void 0 ? !0 : l, p = ae(s, o), y = ie(t, s);
|
|
3032
|
+
let f;
|
|
3033
|
+
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (f = ["categories", s, t, n, p], e[5] = t, e[6] = p, e[7] = s, e[8] = n, e[9] = f) : f = e[9];
|
|
3034
|
+
let m;
|
|
3035
|
+
e[10] !== p || e[11] !== y || e[12] !== n ? (m = (u) => {
|
|
3020
3036
|
const {
|
|
3021
|
-
signal:
|
|
3022
|
-
} =
|
|
3037
|
+
signal: g
|
|
3038
|
+
} = u;
|
|
3023
3039
|
return y == null ? void 0 : y.getCategories({
|
|
3024
3040
|
...n,
|
|
3025
3041
|
filters: p,
|
|
3026
|
-
signal:
|
|
3042
|
+
signal: g
|
|
3027
3043
|
});
|
|
3028
|
-
}, e[10] = p, e[11] = y, e[12] = n, e[13] =
|
|
3029
|
-
const
|
|
3030
|
-
let
|
|
3031
|
-
return e[14] !==
|
|
3032
|
-
queryKey:
|
|
3033
|
-
queryFn:
|
|
3034
|
-
enabled:
|
|
3044
|
+
}, e[10] = p, e[11] = y, e[12] = n, e[13] = m) : m = e[13];
|
|
3045
|
+
const b = !!y && h;
|
|
3046
|
+
let E;
|
|
3047
|
+
return e[14] !== f || e[15] !== m || e[16] !== b || e[17] !== c ? (E = {
|
|
3048
|
+
queryKey: f,
|
|
3049
|
+
queryFn: m,
|
|
3050
|
+
enabled: b,
|
|
3035
3051
|
...c
|
|
3036
|
-
}, e[14] =
|
|
3052
|
+
}, e[14] = f, e[15] = m, e[16] = b, e[17] = c, e[18] = E) : E = e[18], ne(E);
|
|
3037
3053
|
}
|
|
3038
3054
|
function Yr(r) {
|
|
3039
3055
|
const e = D(6);
|
|
@@ -3061,28 +3077,28 @@ function Yn(r) {
|
|
|
3061
3077
|
enabled: l,
|
|
3062
3078
|
...c
|
|
3063
3079
|
} = a, e[2] = a, e[3] = l, e[4] = c) : (l = e[3], c = e[4]);
|
|
3064
|
-
const
|
|
3065
|
-
let
|
|
3066
|
-
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (
|
|
3067
|
-
let
|
|
3068
|
-
e[10] !== p || e[11] !== y || e[12] !== n ? (
|
|
3080
|
+
const h = l === void 0 ? !0 : l, p = ae(s, o), y = ie(t, s);
|
|
3081
|
+
let f;
|
|
3082
|
+
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (f = ["features", s, t, n, p], e[5] = t, e[6] = p, e[7] = s, e[8] = n, e[9] = f) : f = e[9];
|
|
3083
|
+
let m;
|
|
3084
|
+
e[10] !== p || e[11] !== y || e[12] !== n ? (m = (u) => {
|
|
3069
3085
|
const {
|
|
3070
|
-
signal:
|
|
3071
|
-
} =
|
|
3086
|
+
signal: g
|
|
3087
|
+
} = u;
|
|
3072
3088
|
return y == null ? void 0 : y.getFeatures({
|
|
3073
3089
|
...n,
|
|
3074
3090
|
filters: p,
|
|
3075
|
-
signal:
|
|
3091
|
+
signal: g
|
|
3076
3092
|
});
|
|
3077
|
-
}, e[10] = p, e[11] = y, e[12] = n, e[13] =
|
|
3078
|
-
const
|
|
3079
|
-
let
|
|
3080
|
-
return e[14] !==
|
|
3081
|
-
queryKey:
|
|
3082
|
-
queryFn:
|
|
3083
|
-
enabled:
|
|
3093
|
+
}, e[10] = p, e[11] = y, e[12] = n, e[13] = m) : m = e[13];
|
|
3094
|
+
const b = !!y && h;
|
|
3095
|
+
let E;
|
|
3096
|
+
return e[14] !== f || e[15] !== m || e[16] !== b || e[17] !== c ? (E = {
|
|
3097
|
+
queryKey: f,
|
|
3098
|
+
queryFn: m,
|
|
3099
|
+
enabled: b,
|
|
3084
3100
|
...c
|
|
3085
|
-
}, e[14] =
|
|
3101
|
+
}, e[14] = f, e[15] = m, e[16] = b, e[17] = c, e[18] = E) : E = e[18], ne(E);
|
|
3086
3102
|
}
|
|
3087
3103
|
function Xr(r) {
|
|
3088
3104
|
const e = D(6);
|
|
@@ -3110,28 +3126,28 @@ function Xn(r) {
|
|
|
3110
3126
|
enabled: l,
|
|
3111
3127
|
...c
|
|
3112
3128
|
} = a, e[2] = a, e[3] = l, e[4] = c) : (l = e[3], c = e[4]);
|
|
3113
|
-
const
|
|
3114
|
-
let
|
|
3115
|
-
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (
|
|
3116
|
-
let
|
|
3117
|
-
e[10] !== p || e[11] !== y || e[12] !== n ? (
|
|
3129
|
+
const h = l === void 0 ? !0 : l, p = ae(s, o), y = ie(t, s);
|
|
3130
|
+
let f;
|
|
3131
|
+
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (f = ["formula", s, t, n, p], e[5] = t, e[6] = p, e[7] = s, e[8] = n, e[9] = f) : f = e[9];
|
|
3132
|
+
let m;
|
|
3133
|
+
e[10] !== p || e[11] !== y || e[12] !== n ? (m = (u) => {
|
|
3118
3134
|
const {
|
|
3119
|
-
signal:
|
|
3120
|
-
} =
|
|
3135
|
+
signal: g
|
|
3136
|
+
} = u;
|
|
3121
3137
|
return y == null ? void 0 : y.getFormula({
|
|
3122
3138
|
...n,
|
|
3123
3139
|
filters: p,
|
|
3124
|
-
signal:
|
|
3140
|
+
signal: g
|
|
3125
3141
|
});
|
|
3126
|
-
}, e[10] = p, e[11] = y, e[12] = n, e[13] =
|
|
3127
|
-
const
|
|
3128
|
-
let
|
|
3129
|
-
return e[14] !==
|
|
3130
|
-
queryKey:
|
|
3131
|
-
queryFn:
|
|
3132
|
-
enabled:
|
|
3142
|
+
}, e[10] = p, e[11] = y, e[12] = n, e[13] = m) : m = e[13];
|
|
3143
|
+
const b = !!y && h;
|
|
3144
|
+
let E;
|
|
3145
|
+
return e[14] !== f || e[15] !== m || e[16] !== b || e[17] !== c ? (E = {
|
|
3146
|
+
queryKey: f,
|
|
3147
|
+
queryFn: m,
|
|
3148
|
+
enabled: b,
|
|
3133
3149
|
...c
|
|
3134
|
-
}, e[14] =
|
|
3150
|
+
}, e[14] = f, e[15] = m, e[16] = b, e[17] = c, e[18] = E) : E = e[18], ne(E);
|
|
3135
3151
|
}
|
|
3136
3152
|
function Jr(r) {
|
|
3137
3153
|
const e = D(6);
|
|
@@ -3159,28 +3175,28 @@ function Jn(r) {
|
|
|
3159
3175
|
enabled: l,
|
|
3160
3176
|
...c
|
|
3161
3177
|
} = a, e[2] = a, e[3] = l, e[4] = c) : (l = e[3], c = e[4]);
|
|
3162
|
-
const
|
|
3163
|
-
let
|
|
3164
|
-
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (
|
|
3165
|
-
let
|
|
3166
|
-
e[10] !== p || e[11] !== y || e[12] !== n ? (
|
|
3178
|
+
const h = l === void 0 ? !0 : l, p = ae(s, o), y = ie(t, s);
|
|
3179
|
+
let f;
|
|
3180
|
+
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (f = ["histogram", s, t, n, p], e[5] = t, e[6] = p, e[7] = s, e[8] = n, e[9] = f) : f = e[9];
|
|
3181
|
+
let m;
|
|
3182
|
+
e[10] !== p || e[11] !== y || e[12] !== n ? (m = (u) => {
|
|
3167
3183
|
const {
|
|
3168
|
-
signal:
|
|
3169
|
-
} =
|
|
3184
|
+
signal: g
|
|
3185
|
+
} = u;
|
|
3170
3186
|
return y == null ? void 0 : y.getHistogram({
|
|
3171
3187
|
...n,
|
|
3172
3188
|
filters: p,
|
|
3173
|
-
signal:
|
|
3189
|
+
signal: g
|
|
3174
3190
|
});
|
|
3175
|
-
}, e[10] = p, e[11] = y, e[12] = n, e[13] =
|
|
3176
|
-
const
|
|
3177
|
-
let
|
|
3178
|
-
return e[14] !==
|
|
3179
|
-
queryKey:
|
|
3180
|
-
queryFn:
|
|
3181
|
-
enabled:
|
|
3191
|
+
}, e[10] = p, e[11] = y, e[12] = n, e[13] = m) : m = e[13];
|
|
3192
|
+
const b = !!y && h;
|
|
3193
|
+
let E;
|
|
3194
|
+
return e[14] !== f || e[15] !== m || e[16] !== b || e[17] !== c ? (E = {
|
|
3195
|
+
queryKey: f,
|
|
3196
|
+
queryFn: m,
|
|
3197
|
+
enabled: b,
|
|
3182
3198
|
...c
|
|
3183
|
-
}, e[14] =
|
|
3199
|
+
}, e[14] = f, e[15] = m, e[16] = b, e[17] = c, e[18] = E) : E = e[18], ne(E);
|
|
3184
3200
|
}
|
|
3185
3201
|
function eo(r) {
|
|
3186
3202
|
const e = D(6);
|
|
@@ -3208,28 +3224,28 @@ function er(r) {
|
|
|
3208
3224
|
enabled: l,
|
|
3209
3225
|
...c
|
|
3210
3226
|
} = a, e[2] = a, e[3] = l, e[4] = c) : (l = e[3], c = e[4]);
|
|
3211
|
-
const
|
|
3212
|
-
let
|
|
3213
|
-
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (
|
|
3214
|
-
let
|
|
3215
|
-
e[10] !== p || e[11] !== y || e[12] !== n ? (
|
|
3227
|
+
const h = l === void 0 ? !0 : l, p = ae(s, o), y = ie(t, s);
|
|
3228
|
+
let f;
|
|
3229
|
+
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (f = ["range", s, t, n, p], e[5] = t, e[6] = p, e[7] = s, e[8] = n, e[9] = f) : f = e[9];
|
|
3230
|
+
let m;
|
|
3231
|
+
e[10] !== p || e[11] !== y || e[12] !== n ? (m = (u) => {
|
|
3216
3232
|
const {
|
|
3217
|
-
signal:
|
|
3218
|
-
} =
|
|
3233
|
+
signal: g
|
|
3234
|
+
} = u;
|
|
3219
3235
|
return y == null ? void 0 : y.getRange({
|
|
3220
3236
|
...n,
|
|
3221
3237
|
filters: p,
|
|
3222
|
-
signal:
|
|
3238
|
+
signal: g
|
|
3223
3239
|
});
|
|
3224
|
-
}, e[10] = p, e[11] = y, e[12] = n, e[13] =
|
|
3225
|
-
const
|
|
3226
|
-
let
|
|
3227
|
-
return e[14] !==
|
|
3228
|
-
queryKey:
|
|
3229
|
-
queryFn:
|
|
3230
|
-
enabled:
|
|
3240
|
+
}, e[10] = p, e[11] = y, e[12] = n, e[13] = m) : m = e[13];
|
|
3241
|
+
const b = !!y && h;
|
|
3242
|
+
let E;
|
|
3243
|
+
return e[14] !== f || e[15] !== m || e[16] !== b || e[17] !== c ? (E = {
|
|
3244
|
+
queryKey: f,
|
|
3245
|
+
queryFn: m,
|
|
3246
|
+
enabled: b,
|
|
3231
3247
|
...c
|
|
3232
|
-
}, e[14] =
|
|
3248
|
+
}, e[14] = f, e[15] = m, e[16] = b, e[17] = c, e[18] = E) : E = e[18], ne(E);
|
|
3233
3249
|
}
|
|
3234
3250
|
function to(r) {
|
|
3235
3251
|
const e = D(6);
|
|
@@ -3257,28 +3273,28 @@ function tr(r) {
|
|
|
3257
3273
|
enabled: l,
|
|
3258
3274
|
...c
|
|
3259
3275
|
} = a, e[2] = a, e[3] = l, e[4] = c) : (l = e[3], c = e[4]);
|
|
3260
|
-
const
|
|
3261
|
-
let
|
|
3262
|
-
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (
|
|
3263
|
-
let
|
|
3264
|
-
e[10] !== p || e[11] !== y || e[12] !== n ? (
|
|
3276
|
+
const h = l === void 0 ? !0 : l, p = ae(s, o), y = ie(t, s);
|
|
3277
|
+
let f;
|
|
3278
|
+
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (f = ["scatter", s, t, n, p], e[5] = t, e[6] = p, e[7] = s, e[8] = n, e[9] = f) : f = e[9];
|
|
3279
|
+
let m;
|
|
3280
|
+
e[10] !== p || e[11] !== y || e[12] !== n ? (m = (u) => {
|
|
3265
3281
|
const {
|
|
3266
|
-
signal:
|
|
3267
|
-
} =
|
|
3282
|
+
signal: g
|
|
3283
|
+
} = u;
|
|
3268
3284
|
return y == null ? void 0 : y.getScatter({
|
|
3269
3285
|
...n,
|
|
3270
3286
|
filters: p,
|
|
3271
|
-
signal:
|
|
3287
|
+
signal: g
|
|
3272
3288
|
});
|
|
3273
|
-
}, e[10] = p, e[11] = y, e[12] = n, e[13] =
|
|
3274
|
-
const
|
|
3275
|
-
let
|
|
3276
|
-
return e[14] !==
|
|
3277
|
-
queryKey:
|
|
3278
|
-
queryFn:
|
|
3279
|
-
enabled:
|
|
3289
|
+
}, e[10] = p, e[11] = y, e[12] = n, e[13] = m) : m = e[13];
|
|
3290
|
+
const b = !!y && h;
|
|
3291
|
+
let E;
|
|
3292
|
+
return e[14] !== f || e[15] !== m || e[16] !== b || e[17] !== c ? (E = {
|
|
3293
|
+
queryKey: f,
|
|
3294
|
+
queryFn: m,
|
|
3295
|
+
enabled: b,
|
|
3280
3296
|
...c
|
|
3281
|
-
}, e[14] =
|
|
3297
|
+
}, e[14] = f, e[15] = m, e[16] = b, e[17] = c, e[18] = E) : E = e[18], ne(E);
|
|
3282
3298
|
}
|
|
3283
3299
|
function so(r) {
|
|
3284
3300
|
const e = D(6);
|
|
@@ -3306,28 +3322,28 @@ function sr(r) {
|
|
|
3306
3322
|
enabled: l,
|
|
3307
3323
|
...c
|
|
3308
3324
|
} = a, e[2] = a, e[3] = l, e[4] = c) : (l = e[3], c = e[4]);
|
|
3309
|
-
const
|
|
3310
|
-
let
|
|
3311
|
-
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (
|
|
3312
|
-
let
|
|
3313
|
-
e[10] !== p || e[11] !== y || e[12] !== n ? (
|
|
3325
|
+
const h = l === void 0 ? !0 : l, p = ae(s, o), y = ie(t, s);
|
|
3326
|
+
let f;
|
|
3327
|
+
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (f = ["table", s, t, n, p], e[5] = t, e[6] = p, e[7] = s, e[8] = n, e[9] = f) : f = e[9];
|
|
3328
|
+
let m;
|
|
3329
|
+
e[10] !== p || e[11] !== y || e[12] !== n ? (m = (u) => {
|
|
3314
3330
|
const {
|
|
3315
|
-
signal:
|
|
3316
|
-
} =
|
|
3331
|
+
signal: g
|
|
3332
|
+
} = u;
|
|
3317
3333
|
return y == null ? void 0 : y.getTable({
|
|
3318
3334
|
...n,
|
|
3319
3335
|
filters: p,
|
|
3320
|
-
signal:
|
|
3336
|
+
signal: g
|
|
3321
3337
|
});
|
|
3322
|
-
}, e[10] = p, e[11] = y, e[12] = n, e[13] =
|
|
3323
|
-
const
|
|
3324
|
-
let
|
|
3325
|
-
return e[14] !==
|
|
3326
|
-
queryKey:
|
|
3327
|
-
queryFn:
|
|
3328
|
-
enabled:
|
|
3338
|
+
}, e[10] = p, e[11] = y, e[12] = n, e[13] = m) : m = e[13];
|
|
3339
|
+
const b = !!y && h;
|
|
3340
|
+
let E;
|
|
3341
|
+
return e[14] !== f || e[15] !== m || e[16] !== b || e[17] !== c ? (E = {
|
|
3342
|
+
queryKey: f,
|
|
3343
|
+
queryFn: m,
|
|
3344
|
+
enabled: b,
|
|
3329
3345
|
...c
|
|
3330
|
-
}, e[14] =
|
|
3346
|
+
}, e[14] = f, e[15] = m, e[16] = b, e[17] = c, e[18] = E) : E = e[18], ne(E);
|
|
3331
3347
|
}
|
|
3332
3348
|
function no(r) {
|
|
3333
3349
|
const e = D(6);
|
|
@@ -3355,28 +3371,28 @@ function nr(r) {
|
|
|
3355
3371
|
enabled: l,
|
|
3356
3372
|
...c
|
|
3357
3373
|
} = a, e[2] = a, e[3] = l, e[4] = c) : (l = e[3], c = e[4]);
|
|
3358
|
-
const
|
|
3359
|
-
let
|
|
3360
|
-
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (
|
|
3361
|
-
let
|
|
3362
|
-
e[10] !== p || e[11] !== y || e[12] !== n ? (
|
|
3374
|
+
const h = l === void 0 ? !0 : l, p = ae(s, o), y = ie(t, s);
|
|
3375
|
+
let f;
|
|
3376
|
+
e[5] !== t || e[6] !== p || e[7] !== s || e[8] !== n ? (f = ["timeSeries", s, t, n, p], e[5] = t, e[6] = p, e[7] = s, e[8] = n, e[9] = f) : f = e[9];
|
|
3377
|
+
let m;
|
|
3378
|
+
e[10] !== p || e[11] !== y || e[12] !== n ? (m = (u) => {
|
|
3363
3379
|
const {
|
|
3364
|
-
signal:
|
|
3365
|
-
} =
|
|
3380
|
+
signal: g
|
|
3381
|
+
} = u;
|
|
3366
3382
|
return y == null ? void 0 : y.getTimeSeries({
|
|
3367
3383
|
...n,
|
|
3368
3384
|
filters: p,
|
|
3369
|
-
signal:
|
|
3385
|
+
signal: g
|
|
3370
3386
|
});
|
|
3371
|
-
}, e[10] = p, e[11] = y, e[12] = n, e[13] =
|
|
3372
|
-
const
|
|
3373
|
-
let
|
|
3374
|
-
return e[14] !==
|
|
3375
|
-
queryKey:
|
|
3376
|
-
queryFn:
|
|
3377
|
-
enabled:
|
|
3387
|
+
}, e[10] = p, e[11] = y, e[12] = n, e[13] = m) : m = e[13];
|
|
3388
|
+
const b = !!y && h;
|
|
3389
|
+
let E;
|
|
3390
|
+
return e[14] !== f || e[15] !== m || e[16] !== b || e[17] !== c ? (E = {
|
|
3391
|
+
queryKey: f,
|
|
3392
|
+
queryFn: m,
|
|
3393
|
+
enabled: b,
|
|
3378
3394
|
...c
|
|
3379
|
-
}, e[14] =
|
|
3395
|
+
}, e[14] = f, e[15] = m, e[16] = b, e[17] = c, e[18] = E) : E = e[18], ne(E);
|
|
3380
3396
|
}
|
|
3381
3397
|
function ro(r) {
|
|
3382
3398
|
const e = D(6);
|
|
@@ -3403,41 +3419,41 @@ function io(r) {
|
|
|
3403
3419
|
let l;
|
|
3404
3420
|
e[2] !== o ? (l = o === void 0 ? [] : o, e[2] = o, e[3] = l) : l = e[3];
|
|
3405
3421
|
const c = l;
|
|
3406
|
-
let
|
|
3407
|
-
e[4] !== t || e[5] !== c ? (
|
|
3422
|
+
let h;
|
|
3423
|
+
e[4] !== t || e[5] !== c ? (h = /* @__PURE__ */ N(fn, { values: c, children: t }), e[4] = t, e[5] = c, e[6] = h) : h = e[6];
|
|
3408
3424
|
let p;
|
|
3409
|
-
e[7] !== a || e[8] !==
|
|
3425
|
+
e[7] !== a || e[8] !== h ? (p = /* @__PURE__ */ N(Ws, { values: a, children: h }), e[7] = a, e[8] = h, e[9] = p) : p = e[9];
|
|
3410
3426
|
let y;
|
|
3411
3427
|
return e[10] !== s || e[11] !== p ? (y = /* @__PURE__ */ N(Bs, { values: s, children: p }), e[10] = s, e[11] = p, e[12] = y) : y = e[12], y;
|
|
3412
3428
|
}
|
|
3413
3429
|
function ao(r, e) {
|
|
3414
|
-
const t = pe((c) => c.layers), s = pe((c) => c.setLayer), n =
|
|
3430
|
+
const t = pe((c) => c.layers), s = pe((c) => c.setLayer), n = oe(() => kt(r.map((c) => t[c]).filter((c) => !!(c != null && c.legend))).toReversed(), [t, r]), o = oe(() => n.map(e), [e, n]), i = Q(({
|
|
3415
3431
|
id: c,
|
|
3416
|
-
visible:
|
|
3432
|
+
visible: h,
|
|
3417
3433
|
...p
|
|
3418
3434
|
}) => {
|
|
3419
3435
|
s(c, {
|
|
3420
3436
|
props: {
|
|
3421
|
-
visible:
|
|
3437
|
+
visible: h
|
|
3422
3438
|
},
|
|
3423
3439
|
legend: p
|
|
3424
3440
|
});
|
|
3425
3441
|
}, [s]), a = Q(({
|
|
3426
3442
|
id: c,
|
|
3427
|
-
collapsed:
|
|
3443
|
+
collapsed: h
|
|
3428
3444
|
}) => {
|
|
3429
3445
|
s(c, {
|
|
3430
3446
|
legend: {
|
|
3431
|
-
collapsed:
|
|
3447
|
+
collapsed: h
|
|
3432
3448
|
}
|
|
3433
3449
|
});
|
|
3434
3450
|
}, [s]), l = Q(({
|
|
3435
3451
|
id: c,
|
|
3436
|
-
opacity:
|
|
3452
|
+
opacity: h
|
|
3437
3453
|
}) => {
|
|
3438
3454
|
s(c, {
|
|
3439
3455
|
props: {
|
|
3440
|
-
opacity:
|
|
3456
|
+
opacity: h
|
|
3441
3457
|
}
|
|
3442
3458
|
});
|
|
3443
3459
|
}, [s]);
|
|
@@ -3451,47 +3467,48 @@ function ao(r, e) {
|
|
|
3451
3467
|
function lo({
|
|
3452
3468
|
mapId: r
|
|
3453
3469
|
}) {
|
|
3454
|
-
const [e, t] =
|
|
3455
|
-
var
|
|
3456
|
-
return (
|
|
3457
|
-
}),
|
|
3458
|
-
var
|
|
3459
|
-
return (
|
|
3460
|
-
}) &&
|
|
3461
|
-
type:
|
|
3462
|
-
} = ye[
|
|
3463
|
-
const
|
|
3470
|
+
const [e, t] = se(void 0), [s, n] = se(!1), [o, i] = se(void 0), a = $((u) => {
|
|
3471
|
+
var g;
|
|
3472
|
+
return (g = u.maps[r]) == null ? void 0 : g.basemap;
|
|
3473
|
+
}), l = $((u) => u.getDeckInstance), c = $((u) => u.getOverlayInstance), h = $((u) => u.areLayersLoaded[r]), y = $((u) => {
|
|
3474
|
+
var g;
|
|
3475
|
+
return (g = u.maps[r]) == null ? void 0 : g.isLoaded;
|
|
3476
|
+
}) && h, {
|
|
3477
|
+
type: f
|
|
3478
|
+
} = ye[a], m = f === te.googleMaps, b = Q(async () => {
|
|
3479
|
+
const u = l(r), g = c(r);
|
|
3464
3480
|
try {
|
|
3465
|
-
const
|
|
3466
|
-
|
|
3467
|
-
const
|
|
3468
|
-
if (
|
|
3469
|
-
const
|
|
3470
|
-
if (
|
|
3481
|
+
const S = document.createElement("canvas");
|
|
3482
|
+
S.width = u.width ?? 0, S.height = u.height ?? 0;
|
|
3483
|
+
const T = S.getContext("2d");
|
|
3484
|
+
if (m) {
|
|
3485
|
+
const _ = g;
|
|
3486
|
+
if (_.getRenderingType() !== "RASTER")
|
|
3471
3487
|
throw new Error("Only raster type is supported for Google Maps");
|
|
3472
|
-
const
|
|
3488
|
+
const F = await gs(_.getDiv(), {
|
|
3473
3489
|
useCORS: !0
|
|
3474
3490
|
});
|
|
3475
|
-
|
|
3491
|
+
T == null || T.drawImage(F, 0, 0, u.width, u.height);
|
|
3476
3492
|
} else {
|
|
3477
|
-
const
|
|
3478
|
-
|
|
3493
|
+
const _ = g;
|
|
3494
|
+
_.redraw(), T == null || T.drawImage(_.getMap().getCanvas(), 0, 0, u.width, u.height);
|
|
3479
3495
|
}
|
|
3480
|
-
|
|
3481
|
-
const
|
|
3482
|
-
t(
|
|
3483
|
-
} catch (
|
|
3484
|
-
console.error(
|
|
3496
|
+
u == null || u.redraw("screenshot"), T == null || T.drawImage(u.getCanvas(), 0, 0, u.width, u.height);
|
|
3497
|
+
const w = S.toDataURL();
|
|
3498
|
+
t(w);
|
|
3499
|
+
} catch (S) {
|
|
3500
|
+
i(S), console.error(S);
|
|
3485
3501
|
} finally {
|
|
3486
3502
|
n(!1);
|
|
3487
3503
|
}
|
|
3488
|
-
}, [
|
|
3504
|
+
}, [l, m, r, c]);
|
|
3489
3505
|
return {
|
|
3490
3506
|
takeScreenshot: Q(() => {
|
|
3491
|
-
n(!0),
|
|
3492
|
-
}, [
|
|
3507
|
+
i(void 0), n(!0), y && b();
|
|
3508
|
+
}, [b, y]),
|
|
3493
3509
|
isLoading: s,
|
|
3494
|
-
screenshot: e
|
|
3510
|
+
screenshot: e,
|
|
3511
|
+
error: o
|
|
3495
3512
|
};
|
|
3496
3513
|
}
|
|
3497
3514
|
function co(r) {
|
|
@@ -3513,13 +3530,13 @@ function co(r) {
|
|
|
3513
3530
|
mapId: t
|
|
3514
3531
|
}, e[4] = t, e[5] = a) : a = e[5];
|
|
3515
3532
|
const l = lr(a), c = i ?? l ?? n;
|
|
3516
|
-
let
|
|
3517
|
-
return e[6] !== i || e[7] !== l || e[8] !== c || e[9] !== n ? (
|
|
3533
|
+
let h;
|
|
3534
|
+
return e[6] !== i || e[7] !== l || e[8] !== c || e[9] !== n ? (h = {
|
|
3518
3535
|
spatialFilter: c,
|
|
3519
3536
|
staticSpatialFilter: l,
|
|
3520
3537
|
lassoToolsSpatialFilter: i,
|
|
3521
3538
|
viewportSpatialFilter: n
|
|
3522
|
-
}, e[6] = i, e[7] = l, e[8] = c, e[9] = n, e[10] =
|
|
3539
|
+
}, e[6] = i, e[7] = l, e[8] = c, e[9] = n, e[10] = h) : h = e[10], h;
|
|
3523
3540
|
}
|
|
3524
3541
|
function rr(r) {
|
|
3525
3542
|
const e = D(4), {
|
|
@@ -3632,11 +3649,11 @@ function uo({
|
|
|
3632
3649
|
getTitle: l = dr,
|
|
3633
3650
|
getValue: c = pr
|
|
3634
3651
|
}) {
|
|
3635
|
-
const
|
|
3636
|
-
const
|
|
3637
|
-
return
|
|
3652
|
+
const h = o ? l(o) : "", y = t.reduce((f, m) => {
|
|
3653
|
+
const b = e[m], E = r[m], u = c(E, s, b), g = n ? i(m) : "";
|
|
3654
|
+
return f + a(g, u);
|
|
3638
3655
|
}, "");
|
|
3639
|
-
return
|
|
3656
|
+
return h + y;
|
|
3640
3657
|
}
|
|
3641
3658
|
function dr(r) {
|
|
3642
3659
|
return `<h3 style="margin: 0"><strong>${r}</strong></h3></br>`;
|
|
@@ -3688,26 +3705,26 @@ function po(r) {
|
|
|
3688
3705
|
} = $(n);
|
|
3689
3706
|
let l;
|
|
3690
3707
|
e[2] !== s ? (l = (w) => w.areLayersLoaded[s], e[2] = s, e[3] = l) : l = e[3];
|
|
3691
|
-
const c = $(l),
|
|
3708
|
+
const c = $(l), h = $(br), p = $(gr), y = $(hr), f = !c;
|
|
3709
|
+
let m;
|
|
3710
|
+
e[4] !== s || e[5] !== h ? (m = (w) => h(s, w), e[4] = s, e[5] = h, e[6] = m) : m = e[6];
|
|
3711
|
+
const b = m;
|
|
3712
|
+
let E;
|
|
3713
|
+
e[7] !== p || e[8] !== s ? (E = (w) => p(s, w), e[7] = p, e[8] = s, e[9] = E) : E = e[9];
|
|
3714
|
+
const u = E;
|
|
3692
3715
|
let g;
|
|
3693
|
-
e[
|
|
3694
|
-
const
|
|
3716
|
+
e[10] !== s || e[11] !== y ? (g = () => y(s), e[10] = s, e[11] = y, e[12] = g) : g = e[12];
|
|
3717
|
+
const S = g;
|
|
3695
3718
|
let T;
|
|
3696
|
-
e[
|
|
3697
|
-
const f = T;
|
|
3698
|
-
let b;
|
|
3699
|
-
e[10] !== s || e[11] !== y ? (b = () => y(s), e[10] = s, e[11] = y, e[12] = b) : b = e[12];
|
|
3700
|
-
const S = b;
|
|
3701
|
-
let E;
|
|
3702
|
-
return e[13] !== t || e[14] !== i || e[15] !== a || e[16] !== d || e[17] !== h || e[18] !== f || e[19] !== S || e[20] !== o ? (E = t({
|
|
3719
|
+
return e[13] !== t || e[14] !== i || e[15] !== a || e[16] !== f || e[17] !== b || e[18] !== u || e[19] !== S || e[20] !== o ? (T = t({
|
|
3703
3720
|
zoom: o,
|
|
3704
3721
|
maxZoom: i,
|
|
3705
3722
|
minZoom: a,
|
|
3706
|
-
isLoading:
|
|
3707
|
-
setZoom:
|
|
3708
|
-
flyTo:
|
|
3723
|
+
isLoading: f,
|
|
3724
|
+
setZoom: b,
|
|
3725
|
+
flyTo: u,
|
|
3709
3726
|
resetViewState: S
|
|
3710
|
-
}), e[13] = t, e[14] = i, e[15] = a, e[16] =
|
|
3727
|
+
}), e[13] = t, e[14] = i, e[15] = a, e[16] = f, e[17] = b, e[18] = u, e[19] = S, e[20] = o, e[21] = T) : T = e[21], T;
|
|
3711
3728
|
}
|
|
3712
3729
|
function hr(r) {
|
|
3713
3730
|
return r.resetViewState;
|
|
@@ -3732,11 +3749,11 @@ async function vr({
|
|
|
3732
3749
|
params: l,
|
|
3733
3750
|
apiVersion: c = Ke
|
|
3734
3751
|
}) {
|
|
3735
|
-
const
|
|
3736
|
-
return
|
|
3752
|
+
const h = `${r}/${c}/stats/${e}/${n}`;
|
|
3753
|
+
return Ct({
|
|
3737
3754
|
accessToken: t,
|
|
3738
3755
|
signal: o,
|
|
3739
|
-
url:
|
|
3756
|
+
url: h,
|
|
3740
3757
|
method: de.get,
|
|
3741
3758
|
params: {
|
|
3742
3759
|
q: s,
|
|
@@ -3760,7 +3777,7 @@ async function Sr({
|
|
|
3760
3777
|
apiVersion: l = Ke
|
|
3761
3778
|
}) {
|
|
3762
3779
|
const c = `${r}/${l}/stats/${e}/${s}/${n}`;
|
|
3763
|
-
return
|
|
3780
|
+
return Ct({
|
|
3764
3781
|
accessToken: t,
|
|
3765
3782
|
signal: i,
|
|
3766
3783
|
url: c,
|
|
@@ -3782,35 +3799,35 @@ function mo(r) {
|
|
|
3782
3799
|
} = r;
|
|
3783
3800
|
let l;
|
|
3784
3801
|
e[0] !== a ? (l = a === void 0 ? {} : a, e[0] = a, e[1] = l) : l = e[1];
|
|
3785
|
-
let c,
|
|
3802
|
+
let c, h;
|
|
3786
3803
|
e[2] !== l ? ({
|
|
3787
3804
|
enabled: c,
|
|
3788
|
-
...
|
|
3789
|
-
} = l, e[2] = l, e[3] = c, e[4] =
|
|
3805
|
+
...h
|
|
3806
|
+
} = l, e[2] = l, e[3] = c, e[4] = h) : (c = e[3], h = e[4]);
|
|
3790
3807
|
const p = c === void 0 ? !0 : c;
|
|
3791
3808
|
let y;
|
|
3792
3809
|
e[5] !== s || e[6] !== t ? (y = [t, s], e[5] = s, e[6] = t, e[7] = y) : y = e[7];
|
|
3793
|
-
let
|
|
3794
|
-
e[8] !== n || e[9] !== s || e[10] !== i || e[11] !== o || e[12] !== t ? (
|
|
3810
|
+
let f;
|
|
3811
|
+
e[8] !== n || e[9] !== s || e[10] !== i || e[11] !== o || e[12] !== t ? (f = () => wr({
|
|
3795
3812
|
source: t,
|
|
3796
3813
|
params: o,
|
|
3797
3814
|
attribute: s,
|
|
3798
3815
|
accessToken: n,
|
|
3799
3816
|
fetcherOptions: i
|
|
3800
|
-
}), e[8] = n, e[9] = s, e[10] = i, e[11] = o, e[12] = t, e[13] =
|
|
3801
|
-
let
|
|
3802
|
-
return e[14] !== p || e[15] !== t || e[16] !== y || e[17] !==
|
|
3817
|
+
}), e[8] = n, e[9] = s, e[10] = i, e[11] = o, e[12] = t, e[13] = f) : f = e[13];
|
|
3818
|
+
let m;
|
|
3819
|
+
return e[14] !== p || e[15] !== t || e[16] !== y || e[17] !== f || e[18] !== h ? (m = {
|
|
3803
3820
|
queryKey: y,
|
|
3804
|
-
queryFn:
|
|
3805
|
-
select(
|
|
3821
|
+
queryFn: f,
|
|
3822
|
+
select(b) {
|
|
3806
3823
|
return {
|
|
3807
|
-
...
|
|
3808
|
-
type:
|
|
3824
|
+
...b,
|
|
3825
|
+
type: b.type.toLowerCase()
|
|
3809
3826
|
};
|
|
3810
3827
|
},
|
|
3811
3828
|
enabled: !!t && p,
|
|
3812
|
-
...
|
|
3813
|
-
}, e[14] = p, e[15] = t, e[16] = y, e[17] =
|
|
3829
|
+
...h
|
|
3830
|
+
}, e[14] = p, e[15] = t, e[16] = y, e[17] = f, e[18] = h, e[19] = m) : m = e[19], ne(m);
|
|
3814
3831
|
}
|
|
3815
3832
|
function wr({
|
|
3816
3833
|
source: r,
|
|
@@ -3867,7 +3884,7 @@ async function Tr({
|
|
|
3867
3884
|
});
|
|
3868
3885
|
if (!((c = (l = (a = n == null ? void 0 : n.tilestats) == null ? void 0 : a.layers) == null ? void 0 : l[0]) != null && c.attributes))
|
|
3869
3886
|
throw new Error(`${s} not found in tileset attributes`);
|
|
3870
|
-
const i = n.tilestats.layers[0].attributes.find((
|
|
3887
|
+
const i = n.tilestats.layers[0].attributes.find((h) => h.attribute === s);
|
|
3871
3888
|
if (!i)
|
|
3872
3889
|
throw new Error(`${s} not found in tileset attributes`);
|
|
3873
3890
|
return i;
|
|
@@ -3885,8 +3902,8 @@ export {
|
|
|
3885
3902
|
Pt as CustomMeasureDistanceMode,
|
|
3886
3903
|
Je as DEFAULT_LASSO_TOOLS_COLORS,
|
|
3887
3904
|
Vs as DEFAULT_LASSO_TOOLS_LAYER_PROPS,
|
|
3888
|
-
|
|
3889
|
-
|
|
3905
|
+
Ue as DEFAULT_LASSO_TOOLS_MODES,
|
|
3906
|
+
xe as DEFAULT_LASSO_TOOLS_PROPS,
|
|
3890
3907
|
Te as DEFAULT_MASK_LAYER_PROPS,
|
|
3891
3908
|
sn as DEFAULT_MEASUREMENT_TOOLS_MODES,
|
|
3892
3909
|
nn as DEFAULT_MEASUREMENT_TOOLS_UNITS,
|
|
@@ -3903,7 +3920,7 @@ export {
|
|
|
3903
3920
|
ye as MAPS_BASEMAP,
|
|
3904
3921
|
ce as MAP_LASSO_TOOLS_LAYER_ID,
|
|
3905
3922
|
Le as MAP_MASK_LAYER_ID,
|
|
3906
|
-
|
|
3923
|
+
re as MAP_MEASURE_LAYER_ID,
|
|
3907
3924
|
tn as MEASUREMENT_TOOLS_UNITS_AREA,
|
|
3908
3925
|
it as MEASUREMENT_TOOLS_UNITS_DISTANCE,
|
|
3909
3926
|
Z as MEASUREMENT_TOOLS_UNITS_DISTANCE_VALUES,
|
|
@@ -3923,7 +3940,7 @@ export {
|
|
|
3923
3940
|
oo as clientID,
|
|
3924
3941
|
st as convertMetersTo,
|
|
3925
3942
|
Qs as createLassoToolsStore,
|
|
3926
|
-
|
|
3943
|
+
Us as createMapStore,
|
|
3927
3944
|
dn as createMeasurementToolsStore,
|
|
3928
3945
|
le as formatterTypes,
|
|
3929
3946
|
bs as getCursorDefault,
|
|
@@ -3936,7 +3953,7 @@ export {
|
|
|
3936
3953
|
fo as mappingLegendMeridian,
|
|
3937
3954
|
uo as objectToHtml,
|
|
3938
3955
|
kt as sortLayers,
|
|
3939
|
-
|
|
3956
|
+
Cs as transitionFlyConfig,
|
|
3940
3957
|
Zn as useCategories,
|
|
3941
3958
|
Lt as useEventManager,
|
|
3942
3959
|
Yn as useFeatures,
|