@carto/ps-react-maps 1.4.1 → 1.5.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.cjs +9 -9
- package/dist/index.js +529 -540
- package/dist/types/map-measurement-tool/custom-editable-geojson-layer.class.d.ts +1 -1
- package/dist/types/map-measurement-tool/custom-measurement-distance-mode.class.d.ts +2 -2
- package/dist/types/map-measurement-tool/index.d.ts +1 -1
- package/dist/types/map-measurement-tool/map-measurement-tool.const.d.ts +3 -12
- package/dist/types/map-measurement-tool/map-measurement-tool.layer.d.ts +1 -1
- package/dist/types/map-measurement-tool/map-measurement-tool.styles.d.ts +1 -1
- package/dist/types/map-measurement-tool/map-measurement-tool.types.d.ts +4 -5
- package/dist/types/map-measurement-tool/map-measurement-tool.util.d.ts +5 -0
- package/dist/types/map-provider/map-provider.types.d.ts +2 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { EditableGeoJsonLayer as
|
|
3
|
-
import { MeasureDistanceMode as
|
|
4
|
-
import { EventManager as
|
|
5
|
-
import
|
|
6
|
-
var
|
|
1
|
+
import et, { createContext as Q, useContext as ee, useCallback as O, useReducer as tt, useRef as se, useMemo as Zt, useEffect as rt } from "react";
|
|
2
|
+
import { EditableGeoJsonLayer as Jt } from "@nebula.gl/layers";
|
|
3
|
+
import { MeasureDistanceMode as Kt } from "@nebula.gl/edit-modes";
|
|
4
|
+
import { EventManager as Xt } from "mjolnir.js";
|
|
5
|
+
import Qt from "convert-units";
|
|
6
|
+
var er = /* @__PURE__ */ ((t) => (t.Roadmap = "roadmap", t.Satellite = "satellite", t.Hybrid = "hybrid", t))(er || {}), tr = /* @__PURE__ */ ((t) => (t.DarkMatter = "dark-matter", t.Positron = "positron", t.Voyager = "voyager", t))(tr || {});
|
|
7
7
|
const ye = {
|
|
8
8
|
positron: "https://basemaps.cartocdn.com/gl/positron-gl-style/style.json",
|
|
9
9
|
voyager: "https://basemaps.cartocdn.com/gl/voyager-gl-style/style.json",
|
|
10
10
|
"dark-matter": "https://basemaps.cartocdn.com/gl/dark-matter-gl-style/style.json"
|
|
11
11
|
};
|
|
12
|
-
var
|
|
12
|
+
var nt = /* @__PURE__ */ ((t) => (t.Maplibre = "maplibre", t.GoogleMaps = "google-maps", t))(nt || {});
|
|
13
13
|
const he = {
|
|
14
14
|
positron: {
|
|
15
15
|
url: ye.positron,
|
|
@@ -59,128 +59,128 @@ const he = {
|
|
|
59
59
|
setZoom: z,
|
|
60
60
|
setLoaded: z
|
|
61
61
|
}
|
|
62
|
-
},
|
|
62
|
+
}, at = Q(
|
|
63
63
|
K.state
|
|
64
|
-
),
|
|
64
|
+
), ot = Q(K.references), it = Q(
|
|
65
65
|
K.actions
|
|
66
66
|
);
|
|
67
|
-
var
|
|
68
|
-
function
|
|
67
|
+
var F = /* @__PURE__ */ ((t) => (t.SetViewState = "SetViewState", t.SetBasemap = "SetBasemap", t.SetResize = "SetResize", t.SetZoom = "SetZoom", t.SetLoaded = "SetLoaded", t))(F || {});
|
|
68
|
+
function rr(t, { type: r, payload: a }) {
|
|
69
69
|
return {
|
|
70
70
|
SetViewState: () => {
|
|
71
|
-
const { id: o, viewState:
|
|
72
|
-
return
|
|
71
|
+
const { id: o, viewState: f } = a, l = { ...t.maps };
|
|
72
|
+
return l[o] = {
|
|
73
73
|
...t.maps[o],
|
|
74
|
-
viewState:
|
|
74
|
+
viewState: f
|
|
75
75
|
}, {
|
|
76
76
|
...t,
|
|
77
|
-
maps:
|
|
77
|
+
maps: l
|
|
78
78
|
};
|
|
79
79
|
},
|
|
80
80
|
SetResize: () => {
|
|
81
|
-
const { id: o, width:
|
|
82
|
-
return
|
|
81
|
+
const { id: o, width: f, height: l } = a, g = { ...t.maps };
|
|
82
|
+
return g[o] = {
|
|
83
83
|
...t.maps[o],
|
|
84
84
|
viewState: {
|
|
85
85
|
...t.maps[o].viewState,
|
|
86
|
-
width:
|
|
87
|
-
height:
|
|
86
|
+
width: f,
|
|
87
|
+
height: l
|
|
88
88
|
}
|
|
89
89
|
}, {
|
|
90
90
|
...t,
|
|
91
|
-
maps:
|
|
91
|
+
maps: g
|
|
92
92
|
};
|
|
93
93
|
},
|
|
94
94
|
SetBasemap: () => {
|
|
95
|
-
const { id: o, basemap:
|
|
96
|
-
return
|
|
95
|
+
const { id: o, basemap: f } = a, l = { ...t.maps }, { basemap: g } = l[o], c = he[g]?.type, y = he[f]?.type, h = c === y;
|
|
96
|
+
return l[o] = {
|
|
97
97
|
...t.maps[o],
|
|
98
|
-
basemap:
|
|
99
|
-
isLoaded:
|
|
98
|
+
basemap: f,
|
|
99
|
+
isLoaded: h
|
|
100
100
|
}, {
|
|
101
101
|
...t,
|
|
102
|
-
maps:
|
|
102
|
+
maps: l
|
|
103
103
|
};
|
|
104
104
|
},
|
|
105
105
|
SetZoom: () => {
|
|
106
|
-
const { id: o, zoom:
|
|
107
|
-
return
|
|
106
|
+
const { id: o, zoom: f } = a, l = { ...t.maps };
|
|
107
|
+
return l[o] = {
|
|
108
108
|
...t.maps[o],
|
|
109
109
|
viewState: {
|
|
110
110
|
...t.maps[o].viewState,
|
|
111
|
-
zoom:
|
|
111
|
+
zoom: f
|
|
112
112
|
}
|
|
113
113
|
}, {
|
|
114
114
|
...t,
|
|
115
|
-
maps:
|
|
115
|
+
maps: l
|
|
116
116
|
};
|
|
117
117
|
},
|
|
118
118
|
SetLoaded: () => {
|
|
119
|
-
const { id: o, value:
|
|
120
|
-
return
|
|
119
|
+
const { id: o, value: f } = a, l = { ...t.maps };
|
|
120
|
+
return l[o] = {
|
|
121
121
|
...t.maps[o],
|
|
122
|
-
isLoaded:
|
|
122
|
+
isLoaded: f
|
|
123
123
|
}, {
|
|
124
124
|
...t,
|
|
125
|
-
maps:
|
|
125
|
+
maps: l
|
|
126
126
|
};
|
|
127
127
|
}
|
|
128
128
|
}[r]?.() ?? t;
|
|
129
129
|
}
|
|
130
|
-
function
|
|
131
|
-
return
|
|
130
|
+
function st(t) {
|
|
131
|
+
return ee(at).maps[t];
|
|
132
132
|
}
|
|
133
133
|
function _e(t) {
|
|
134
|
-
const r =
|
|
135
|
-
const
|
|
136
|
-
return
|
|
137
|
-
}, [a]),
|
|
138
|
-
(
|
|
134
|
+
const r = ee(ot), { instanceRef: a, overlayRef: s } = r.current[t], o = O(() => {
|
|
135
|
+
const y = a?.current;
|
|
136
|
+
return y?.deck || y?._deck;
|
|
137
|
+
}, [a]), f = O(() => s?.current, [s]), l = O(() => o()?._getViewState(), [o]), g = O(
|
|
138
|
+
(y) => o()?.getViewports(y),
|
|
139
139
|
[o]
|
|
140
|
-
),
|
|
141
|
-
(
|
|
142
|
-
[
|
|
140
|
+
), c = O(
|
|
141
|
+
(y = 0, h) => g(h)?.[y],
|
|
142
|
+
[g]
|
|
143
143
|
);
|
|
144
144
|
return {
|
|
145
145
|
instanceRef: a,
|
|
146
146
|
overlayRef: s,
|
|
147
147
|
getDeckInstance: o,
|
|
148
|
-
getOverlayInstance:
|
|
149
|
-
getViewState:
|
|
150
|
-
getViewport:
|
|
151
|
-
getViewports:
|
|
148
|
+
getOverlayInstance: f,
|
|
149
|
+
getViewState: l,
|
|
150
|
+
getViewport: c,
|
|
151
|
+
getViewports: g
|
|
152
152
|
};
|
|
153
153
|
}
|
|
154
|
-
function
|
|
155
|
-
const { setBasemap: r, setResize: a, setViewState: s, setZoom: o, setLoaded:
|
|
154
|
+
function nr(t) {
|
|
155
|
+
const { setBasemap: r, setResize: a, setViewState: s, setZoom: o, setLoaded: f } = ee(it), { getViewport: l } = _e(t);
|
|
156
156
|
return {
|
|
157
|
-
setBasemap: (
|
|
158
|
-
setResize: (
|
|
159
|
-
setViewState: (
|
|
160
|
-
setZoom: (
|
|
161
|
-
setLoaded: (
|
|
162
|
-
fitBounds: (
|
|
163
|
-
boundsOptions:
|
|
164
|
-
viewStateOptions:
|
|
157
|
+
setBasemap: (c) => r(c, t),
|
|
158
|
+
setResize: (c) => a(c, t),
|
|
159
|
+
setViewState: (c) => s(c, t),
|
|
160
|
+
setZoom: (c) => o(c, t),
|
|
161
|
+
setLoaded: (c) => f(c, t),
|
|
162
|
+
fitBounds: (c, {
|
|
163
|
+
boundsOptions: y,
|
|
164
|
+
viewStateOptions: h
|
|
165
165
|
} = {}) => {
|
|
166
|
-
const b =
|
|
167
|
-
|
|
168
|
-
|
|
166
|
+
const b = l(), { latitude: M, longitude: v, zoom: E } = b.fitBounds(
|
|
167
|
+
c,
|
|
168
|
+
y
|
|
169
169
|
);
|
|
170
|
-
s({ ...
|
|
170
|
+
s({ ...h, latitude: M, longitude: v, zoom: E }, t);
|
|
171
171
|
}
|
|
172
172
|
};
|
|
173
173
|
}
|
|
174
|
-
function
|
|
175
|
-
return
|
|
174
|
+
function zr(t) {
|
|
175
|
+
return st(t);
|
|
176
176
|
}
|
|
177
|
-
function
|
|
177
|
+
function qr(t) {
|
|
178
178
|
return _e(t);
|
|
179
179
|
}
|
|
180
|
-
function
|
|
181
|
-
return
|
|
180
|
+
function Gr(t) {
|
|
181
|
+
return nr(t);
|
|
182
182
|
}
|
|
183
|
-
function
|
|
183
|
+
function ar(t) {
|
|
184
184
|
return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
|
|
185
185
|
}
|
|
186
186
|
var Ee = { exports: {} }, q = {};
|
|
@@ -193,23 +193,23 @@ var Ee = { exports: {} }, q = {};
|
|
|
193
193
|
* This source code is licensed under the MIT license found in the
|
|
194
194
|
* LICENSE file in the root directory of this source tree.
|
|
195
195
|
*/
|
|
196
|
-
var
|
|
197
|
-
function
|
|
198
|
-
if (
|
|
196
|
+
var Ge;
|
|
197
|
+
function or() {
|
|
198
|
+
if (Ge)
|
|
199
199
|
return q;
|
|
200
|
-
|
|
201
|
-
var t =
|
|
202
|
-
function
|
|
203
|
-
var
|
|
204
|
-
|
|
205
|
-
for (
|
|
206
|
-
s.call(
|
|
207
|
-
if (
|
|
208
|
-
for (
|
|
209
|
-
b[
|
|
210
|
-
return { $$typeof: r, type:
|
|
200
|
+
Ge = 1;
|
|
201
|
+
var t = et, r = Symbol.for("react.element"), a = Symbol.for("react.fragment"), s = Object.prototype.hasOwnProperty, o = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, f = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
202
|
+
function l(g, c, y) {
|
|
203
|
+
var h, b = {}, M = null, v = null;
|
|
204
|
+
y !== void 0 && (M = "" + y), c.key !== void 0 && (M = "" + c.key), c.ref !== void 0 && (v = c.ref);
|
|
205
|
+
for (h in c)
|
|
206
|
+
s.call(c, h) && !f.hasOwnProperty(h) && (b[h] = c[h]);
|
|
207
|
+
if (g && g.defaultProps)
|
|
208
|
+
for (h in c = g.defaultProps, c)
|
|
209
|
+
b[h] === void 0 && (b[h] = c[h]);
|
|
210
|
+
return { $$typeof: r, type: g, key: M, ref: v, props: b, _owner: o.current };
|
|
211
211
|
}
|
|
212
|
-
return q.Fragment = a, q.jsx =
|
|
212
|
+
return q.Fragment = a, q.jsx = l, q.jsxs = l, q;
|
|
213
213
|
}
|
|
214
214
|
var G = {};
|
|
215
215
|
/**
|
|
@@ -221,11 +221,11 @@ var G = {};
|
|
|
221
221
|
* This source code is licensed under the MIT license found in the
|
|
222
222
|
* LICENSE file in the root directory of this source tree.
|
|
223
223
|
*/
|
|
224
|
-
var
|
|
225
|
-
function
|
|
226
|
-
return
|
|
227
|
-
var t =
|
|
228
|
-
function
|
|
224
|
+
var Ze;
|
|
225
|
+
function ir() {
|
|
226
|
+
return Ze || (Ze = 1, process.env.NODE_ENV !== "production" && function() {
|
|
227
|
+
var t = et, r = Symbol.for("react.element"), a = Symbol.for("react.portal"), s = Symbol.for("react.fragment"), o = Symbol.for("react.strict_mode"), f = Symbol.for("react.profiler"), l = Symbol.for("react.provider"), g = Symbol.for("react.context"), c = Symbol.for("react.forward_ref"), y = Symbol.for("react.suspense"), h = Symbol.for("react.suspense_list"), b = Symbol.for("react.memo"), M = Symbol.for("react.lazy"), v = Symbol.for("react.offscreen"), E = Symbol.iterator, x = "@@iterator";
|
|
228
|
+
function I(e) {
|
|
229
229
|
if (e === null || typeof e != "object")
|
|
230
230
|
return null;
|
|
231
231
|
var n = E && e[E] || e[x];
|
|
@@ -234,38 +234,38 @@ function sr() {
|
|
|
234
234
|
var j = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
235
235
|
function S(e) {
|
|
236
236
|
{
|
|
237
|
-
for (var n = arguments.length, i = new Array(n > 1 ? n - 1 : 0),
|
|
238
|
-
i[
|
|
239
|
-
|
|
237
|
+
for (var n = arguments.length, i = new Array(n > 1 ? n - 1 : 0), u = 1; u < n; u++)
|
|
238
|
+
i[u - 1] = arguments[u];
|
|
239
|
+
Re("error", e, i);
|
|
240
240
|
}
|
|
241
241
|
}
|
|
242
|
-
function
|
|
242
|
+
function Re(e, n, i) {
|
|
243
243
|
{
|
|
244
|
-
var
|
|
245
|
-
|
|
244
|
+
var u = j.ReactDebugCurrentFrame, p = u.getStackAddendum();
|
|
245
|
+
p !== "" && (n += "%s", i = i.concat([p]));
|
|
246
246
|
var _ = i.map(function(m) {
|
|
247
247
|
return String(m);
|
|
248
248
|
});
|
|
249
249
|
_.unshift("Warning: " + n), Function.prototype.apply.call(console[e], console, _);
|
|
250
250
|
}
|
|
251
251
|
}
|
|
252
|
-
var
|
|
253
|
-
|
|
254
|
-
function
|
|
255
|
-
return !!(typeof e == "string" || typeof e == "function" || e === s || e ===
|
|
252
|
+
var Y = !1, B = !1, Et = !1, bt = !1, _t = !1, Te;
|
|
253
|
+
Te = Symbol.for("react.module.reference");
|
|
254
|
+
function St(e) {
|
|
255
|
+
return !!(typeof e == "string" || typeof e == "function" || e === s || e === f || _t || e === o || e === y || e === h || bt || e === v || Y || B || Et || typeof e == "object" && e !== null && (e.$$typeof === M || e.$$typeof === b || e.$$typeof === l || e.$$typeof === g || e.$$typeof === c || // This needs to include all possible module reference object
|
|
256
256
|
// types supported by any Flight configuration anywhere since
|
|
257
257
|
// we don't know which Flight build this will end up being used
|
|
258
258
|
// with.
|
|
259
|
-
e.$$typeof ===
|
|
259
|
+
e.$$typeof === Te || e.getModuleId !== void 0));
|
|
260
260
|
}
|
|
261
|
-
function
|
|
262
|
-
var
|
|
263
|
-
if (
|
|
264
|
-
return
|
|
265
|
-
var
|
|
266
|
-
return
|
|
261
|
+
function Rt(e, n, i) {
|
|
262
|
+
var u = e.displayName;
|
|
263
|
+
if (u)
|
|
264
|
+
return u;
|
|
265
|
+
var p = n.displayName || n.name || "";
|
|
266
|
+
return p !== "" ? i + "(" + p + ")" : i;
|
|
267
267
|
}
|
|
268
|
-
function
|
|
268
|
+
function Me(e) {
|
|
269
269
|
return e.displayName || "Context";
|
|
270
270
|
}
|
|
271
271
|
function A(e) {
|
|
@@ -280,30 +280,30 @@ function sr() {
|
|
|
280
280
|
return "Fragment";
|
|
281
281
|
case a:
|
|
282
282
|
return "Portal";
|
|
283
|
-
case
|
|
283
|
+
case f:
|
|
284
284
|
return "Profiler";
|
|
285
285
|
case o:
|
|
286
286
|
return "StrictMode";
|
|
287
|
-
case p:
|
|
288
|
-
return "Suspense";
|
|
289
287
|
case y:
|
|
288
|
+
return "Suspense";
|
|
289
|
+
case h:
|
|
290
290
|
return "SuspenseList";
|
|
291
291
|
}
|
|
292
292
|
if (typeof e == "object")
|
|
293
293
|
switch (e.$$typeof) {
|
|
294
|
-
case
|
|
294
|
+
case g:
|
|
295
295
|
var n = e;
|
|
296
|
-
return
|
|
297
|
-
case
|
|
296
|
+
return Me(n) + ".Consumer";
|
|
297
|
+
case l:
|
|
298
298
|
var i = e;
|
|
299
|
-
return
|
|
300
|
-
case
|
|
301
|
-
return
|
|
299
|
+
return Me(i._context) + ".Provider";
|
|
300
|
+
case c:
|
|
301
|
+
return Rt(e, e.render, "ForwardRef");
|
|
302
302
|
case b:
|
|
303
|
-
var
|
|
304
|
-
return
|
|
305
|
-
case
|
|
306
|
-
var
|
|
303
|
+
var u = e.displayName || null;
|
|
304
|
+
return u !== null ? u : A(e.type) || "Memo";
|
|
305
|
+
case M: {
|
|
306
|
+
var p = e, _ = p._payload, m = p._init;
|
|
307
307
|
try {
|
|
308
308
|
return A(m(_));
|
|
309
309
|
} catch {
|
|
@@ -313,18 +313,18 @@ function sr() {
|
|
|
313
313
|
}
|
|
314
314
|
return null;
|
|
315
315
|
}
|
|
316
|
-
var
|
|
317
|
-
function
|
|
316
|
+
var L = Object.assign, W = 0, Oe, Pe, Ce, we, xe, je, Ae;
|
|
317
|
+
function De() {
|
|
318
318
|
}
|
|
319
|
-
|
|
320
|
-
function
|
|
319
|
+
De.__reactDisabledLog = !0;
|
|
320
|
+
function Tt() {
|
|
321
321
|
{
|
|
322
322
|
if (W === 0) {
|
|
323
|
-
|
|
323
|
+
Oe = console.log, Pe = console.info, Ce = console.warn, we = console.error, xe = console.group, je = console.groupCollapsed, Ae = console.groupEnd;
|
|
324
324
|
var e = {
|
|
325
325
|
configurable: !0,
|
|
326
326
|
enumerable: !0,
|
|
327
|
-
value:
|
|
327
|
+
value: De,
|
|
328
328
|
writable: !0
|
|
329
329
|
};
|
|
330
330
|
Object.defineProperties(console, {
|
|
@@ -340,7 +340,7 @@ function sr() {
|
|
|
340
340
|
W++;
|
|
341
341
|
}
|
|
342
342
|
}
|
|
343
|
-
function
|
|
343
|
+
function Mt() {
|
|
344
344
|
{
|
|
345
345
|
if (W--, W === 0) {
|
|
346
346
|
var e = {
|
|
@@ -349,26 +349,26 @@ function sr() {
|
|
|
349
349
|
writable: !0
|
|
350
350
|
};
|
|
351
351
|
Object.defineProperties(console, {
|
|
352
|
-
log:
|
|
352
|
+
log: L({}, e, {
|
|
353
|
+
value: Oe
|
|
354
|
+
}),
|
|
355
|
+
info: L({}, e, {
|
|
353
356
|
value: Pe
|
|
354
357
|
}),
|
|
355
|
-
|
|
358
|
+
warn: L({}, e, {
|
|
356
359
|
value: Ce
|
|
357
360
|
}),
|
|
358
|
-
|
|
361
|
+
error: L({}, e, {
|
|
359
362
|
value: we
|
|
360
363
|
}),
|
|
361
|
-
|
|
364
|
+
group: L({}, e, {
|
|
362
365
|
value: xe
|
|
363
366
|
}),
|
|
364
|
-
|
|
367
|
+
groupCollapsed: L({}, e, {
|
|
365
368
|
value: je
|
|
366
369
|
}),
|
|
367
|
-
|
|
370
|
+
groupEnd: L({}, e, {
|
|
368
371
|
value: Ae
|
|
369
|
-
}),
|
|
370
|
-
groupEnd: I({}, e, {
|
|
371
|
-
value: De
|
|
372
372
|
})
|
|
373
373
|
});
|
|
374
374
|
}
|
|
@@ -376,38 +376,38 @@ function sr() {
|
|
|
376
376
|
}
|
|
377
377
|
}
|
|
378
378
|
var ue = j.ReactCurrentDispatcher, le;
|
|
379
|
-
function
|
|
379
|
+
function te(e, n, i) {
|
|
380
380
|
{
|
|
381
381
|
if (le === void 0)
|
|
382
382
|
try {
|
|
383
383
|
throw Error();
|
|
384
|
-
} catch (
|
|
385
|
-
var
|
|
386
|
-
le =
|
|
384
|
+
} catch (p) {
|
|
385
|
+
var u = p.stack.trim().match(/\n( *(at )?)/);
|
|
386
|
+
le = u && u[1] || "";
|
|
387
387
|
}
|
|
388
388
|
return `
|
|
389
389
|
` + le + e;
|
|
390
390
|
}
|
|
391
391
|
}
|
|
392
|
-
var fe = !1,
|
|
392
|
+
var fe = !1, re;
|
|
393
393
|
{
|
|
394
|
-
var
|
|
395
|
-
|
|
394
|
+
var Ot = typeof WeakMap == "function" ? WeakMap : Map;
|
|
395
|
+
re = new Ot();
|
|
396
396
|
}
|
|
397
|
-
function
|
|
397
|
+
function Fe(e, n) {
|
|
398
398
|
if (!e || fe)
|
|
399
399
|
return "";
|
|
400
400
|
{
|
|
401
|
-
var i =
|
|
401
|
+
var i = re.get(e);
|
|
402
402
|
if (i !== void 0)
|
|
403
403
|
return i;
|
|
404
404
|
}
|
|
405
|
-
var
|
|
405
|
+
var u;
|
|
406
406
|
fe = !0;
|
|
407
|
-
var
|
|
407
|
+
var p = Error.prepareStackTrace;
|
|
408
408
|
Error.prepareStackTrace = void 0;
|
|
409
409
|
var _;
|
|
410
|
-
_ = ue.current, ue.current = null,
|
|
410
|
+
_ = ue.current, ue.current = null, Tt();
|
|
411
411
|
try {
|
|
412
412
|
if (n) {
|
|
413
413
|
var m = function() {
|
|
@@ -421,14 +421,14 @@ function sr() {
|
|
|
421
421
|
try {
|
|
422
422
|
Reflect.construct(m, []);
|
|
423
423
|
} catch (D) {
|
|
424
|
-
|
|
424
|
+
u = D;
|
|
425
425
|
}
|
|
426
426
|
Reflect.construct(e, [], m);
|
|
427
427
|
} else {
|
|
428
428
|
try {
|
|
429
429
|
m.call();
|
|
430
430
|
} catch (D) {
|
|
431
|
-
|
|
431
|
+
u = D;
|
|
432
432
|
}
|
|
433
433
|
e.call(m.prototype);
|
|
434
434
|
}
|
|
@@ -436,14 +436,14 @@ function sr() {
|
|
|
436
436
|
try {
|
|
437
437
|
throw Error();
|
|
438
438
|
} catch (D) {
|
|
439
|
-
|
|
439
|
+
u = D;
|
|
440
440
|
}
|
|
441
441
|
e();
|
|
442
442
|
}
|
|
443
443
|
} catch (D) {
|
|
444
|
-
if (D &&
|
|
444
|
+
if (D && u && typeof D.stack == "string") {
|
|
445
445
|
for (var d = D.stack.split(`
|
|
446
|
-
`), P =
|
|
446
|
+
`), P = u.stack.split(`
|
|
447
447
|
`), R = d.length - 1, T = P.length - 1; R >= 1 && T >= 0 && d[R] !== P[T]; )
|
|
448
448
|
T--;
|
|
449
449
|
for (; R >= 1 && T >= 0; R--, T--)
|
|
@@ -453,92 +453,92 @@ function sr() {
|
|
|
453
453
|
if (R--, T--, T < 0 || d[R] !== P[T]) {
|
|
454
454
|
var w = `
|
|
455
455
|
` + d[R].replace(" at new ", " at ");
|
|
456
|
-
return e.displayName && w.includes("<anonymous>") && (w = w.replace("<anonymous>", e.displayName)), typeof e == "function" &&
|
|
456
|
+
return e.displayName && w.includes("<anonymous>") && (w = w.replace("<anonymous>", e.displayName)), typeof e == "function" && re.set(e, w), w;
|
|
457
457
|
}
|
|
458
458
|
while (R >= 1 && T >= 0);
|
|
459
459
|
break;
|
|
460
460
|
}
|
|
461
461
|
}
|
|
462
462
|
} finally {
|
|
463
|
-
fe = !1, ue.current = _,
|
|
463
|
+
fe = !1, ue.current = _, Mt(), Error.prepareStackTrace = p;
|
|
464
464
|
}
|
|
465
|
-
var
|
|
466
|
-
return typeof e == "function" &&
|
|
465
|
+
var U = e ? e.displayName || e.name : "", qe = U ? te(U) : "";
|
|
466
|
+
return typeof e == "function" && re.set(e, qe), qe;
|
|
467
467
|
}
|
|
468
|
-
function
|
|
469
|
-
return
|
|
468
|
+
function Pt(e, n, i) {
|
|
469
|
+
return Fe(e, !1);
|
|
470
470
|
}
|
|
471
|
-
function
|
|
471
|
+
function Ct(e) {
|
|
472
472
|
var n = e.prototype;
|
|
473
473
|
return !!(n && n.isReactComponent);
|
|
474
474
|
}
|
|
475
|
-
function
|
|
475
|
+
function ne(e, n, i) {
|
|
476
476
|
if (e == null)
|
|
477
477
|
return "";
|
|
478
478
|
if (typeof e == "function")
|
|
479
|
-
return
|
|
479
|
+
return Fe(e, Ct(e));
|
|
480
480
|
if (typeof e == "string")
|
|
481
|
-
return
|
|
481
|
+
return te(e);
|
|
482
482
|
switch (e) {
|
|
483
|
-
case p:
|
|
484
|
-
return re("Suspense");
|
|
485
483
|
case y:
|
|
486
|
-
return
|
|
484
|
+
return te("Suspense");
|
|
485
|
+
case h:
|
|
486
|
+
return te("SuspenseList");
|
|
487
487
|
}
|
|
488
488
|
if (typeof e == "object")
|
|
489
489
|
switch (e.$$typeof) {
|
|
490
|
-
case
|
|
491
|
-
return
|
|
490
|
+
case c:
|
|
491
|
+
return Pt(e.render);
|
|
492
492
|
case b:
|
|
493
|
-
return
|
|
494
|
-
case
|
|
495
|
-
var
|
|
493
|
+
return ne(e.type, n, i);
|
|
494
|
+
case M: {
|
|
495
|
+
var u = e, p = u._payload, _ = u._init;
|
|
496
496
|
try {
|
|
497
|
-
return
|
|
497
|
+
return ne(_(p), n, i);
|
|
498
498
|
} catch {
|
|
499
499
|
}
|
|
500
500
|
}
|
|
501
501
|
}
|
|
502
502
|
return "";
|
|
503
503
|
}
|
|
504
|
-
var
|
|
505
|
-
function
|
|
504
|
+
var ae = Object.prototype.hasOwnProperty, ke = {}, Le = j.ReactDebugCurrentFrame;
|
|
505
|
+
function oe(e) {
|
|
506
506
|
if (e) {
|
|
507
|
-
var n = e._owner, i =
|
|
508
|
-
|
|
507
|
+
var n = e._owner, i = ne(e.type, e._source, n ? n.type : null);
|
|
508
|
+
Le.setExtraStackFrame(i);
|
|
509
509
|
} else
|
|
510
|
-
|
|
510
|
+
Le.setExtraStackFrame(null);
|
|
511
511
|
}
|
|
512
|
-
function
|
|
512
|
+
function wt(e, n, i, u, p) {
|
|
513
513
|
{
|
|
514
|
-
var _ = Function.call.bind(
|
|
514
|
+
var _ = Function.call.bind(ae);
|
|
515
515
|
for (var m in e)
|
|
516
516
|
if (_(e, m)) {
|
|
517
517
|
var d = void 0;
|
|
518
518
|
try {
|
|
519
519
|
if (typeof e[m] != "function") {
|
|
520
|
-
var P = Error((
|
|
520
|
+
var P = Error((u || "React class") + ": " + i + " type `" + m + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof e[m] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
521
521
|
throw P.name = "Invariant Violation", P;
|
|
522
522
|
}
|
|
523
|
-
d = e[m](n, m,
|
|
523
|
+
d = e[m](n, m, u, i, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
524
524
|
} catch (R) {
|
|
525
525
|
d = R;
|
|
526
526
|
}
|
|
527
|
-
d && !(d instanceof Error) && (
|
|
527
|
+
d && !(d instanceof Error) && (oe(p), S("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", u || "React class", i, m, typeof d), oe(null)), d instanceof Error && !(d.message in ke) && (ke[d.message] = !0, oe(p), S("Failed %s type: %s", i, d.message), oe(null));
|
|
528
528
|
}
|
|
529
529
|
}
|
|
530
530
|
}
|
|
531
|
-
var
|
|
531
|
+
var xt = Array.isArray;
|
|
532
532
|
function de(e) {
|
|
533
|
-
return
|
|
533
|
+
return xt(e);
|
|
534
534
|
}
|
|
535
|
-
function
|
|
535
|
+
function jt(e) {
|
|
536
536
|
{
|
|
537
537
|
var n = typeof Symbol == "function" && Symbol.toStringTag, i = n && e[Symbol.toStringTag] || e.constructor.name || "Object";
|
|
538
538
|
return i;
|
|
539
539
|
}
|
|
540
540
|
}
|
|
541
|
-
function
|
|
541
|
+
function At(e) {
|
|
542
542
|
try {
|
|
543
543
|
return Ie(e), !1;
|
|
544
544
|
} catch {
|
|
@@ -548,19 +548,19 @@ function sr() {
|
|
|
548
548
|
function Ie(e) {
|
|
549
549
|
return "" + e;
|
|
550
550
|
}
|
|
551
|
-
function
|
|
552
|
-
if (
|
|
553
|
-
return S("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",
|
|
551
|
+
function Ne(e) {
|
|
552
|
+
if (At(e))
|
|
553
|
+
return S("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", jt(e)), Ie(e);
|
|
554
554
|
}
|
|
555
|
-
var H = j.ReactCurrentOwner,
|
|
555
|
+
var H = j.ReactCurrentOwner, Dt = {
|
|
556
556
|
key: !0,
|
|
557
557
|
ref: !0,
|
|
558
558
|
__self: !0,
|
|
559
559
|
__source: !0
|
|
560
|
-
},
|
|
560
|
+
}, Ue, Ve, me;
|
|
561
561
|
me = {};
|
|
562
|
-
function
|
|
563
|
-
if (
|
|
562
|
+
function Ft(e) {
|
|
563
|
+
if (ae.call(e, "ref")) {
|
|
564
564
|
var n = Object.getOwnPropertyDescriptor(e, "ref").get;
|
|
565
565
|
if (n && n.isReactWarning)
|
|
566
566
|
return !1;
|
|
@@ -568,14 +568,14 @@ function sr() {
|
|
|
568
568
|
return e.ref !== void 0;
|
|
569
569
|
}
|
|
570
570
|
function kt(e) {
|
|
571
|
-
if (
|
|
571
|
+
if (ae.call(e, "key")) {
|
|
572
572
|
var n = Object.getOwnPropertyDescriptor(e, "key").get;
|
|
573
573
|
if (n && n.isReactWarning)
|
|
574
574
|
return !1;
|
|
575
575
|
}
|
|
576
576
|
return e.key !== void 0;
|
|
577
577
|
}
|
|
578
|
-
function
|
|
578
|
+
function Lt(e, n) {
|
|
579
579
|
if (typeof e.ref == "string" && H.current && n && H.current.stateNode !== n) {
|
|
580
580
|
var i = A(H.current.type);
|
|
581
581
|
me[i] || (S('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', A(H.current.type), e.ref), me[i] = !0);
|
|
@@ -584,7 +584,7 @@ function sr() {
|
|
|
584
584
|
function It(e, n) {
|
|
585
585
|
{
|
|
586
586
|
var i = function() {
|
|
587
|
-
|
|
587
|
+
Ue || (Ue = !0, S("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", n));
|
|
588
588
|
};
|
|
589
589
|
i.isReactWarning = !0, Object.defineProperty(e, "key", {
|
|
590
590
|
get: i,
|
|
@@ -592,10 +592,10 @@ function sr() {
|
|
|
592
592
|
});
|
|
593
593
|
}
|
|
594
594
|
}
|
|
595
|
-
function
|
|
595
|
+
function Nt(e, n) {
|
|
596
596
|
{
|
|
597
597
|
var i = function() {
|
|
598
|
-
|
|
598
|
+
Ve || (Ve = !0, S("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", n));
|
|
599
599
|
};
|
|
600
600
|
i.isReactWarning = !0, Object.defineProperty(e, "ref", {
|
|
601
601
|
get: i,
|
|
@@ -603,7 +603,7 @@ function sr() {
|
|
|
603
603
|
});
|
|
604
604
|
}
|
|
605
605
|
}
|
|
606
|
-
var
|
|
606
|
+
var Ut = function(e, n, i, u, p, _, m) {
|
|
607
607
|
var d = {
|
|
608
608
|
// This tag allows us to uniquely identify this as a React Element
|
|
609
609
|
$$typeof: r,
|
|
@@ -624,20 +624,20 @@ function sr() {
|
|
|
624
624
|
configurable: !1,
|
|
625
625
|
enumerable: !1,
|
|
626
626
|
writable: !1,
|
|
627
|
-
value:
|
|
627
|
+
value: u
|
|
628
628
|
}), Object.defineProperty(d, "_source", {
|
|
629
629
|
configurable: !1,
|
|
630
630
|
enumerable: !1,
|
|
631
631
|
writable: !1,
|
|
632
|
-
value:
|
|
632
|
+
value: p
|
|
633
633
|
}), Object.freeze && (Object.freeze(d.props), Object.freeze(d)), d;
|
|
634
634
|
};
|
|
635
|
-
function
|
|
635
|
+
function Vt(e, n, i, u, p) {
|
|
636
636
|
{
|
|
637
637
|
var _, m = {}, d = null, P = null;
|
|
638
|
-
i !== void 0 && (
|
|
638
|
+
i !== void 0 && (Ne(i), d = "" + i), kt(n) && (Ne(n.key), d = "" + n.key), Ft(n) && (P = n.ref, Lt(n, p));
|
|
639
639
|
for (_ in n)
|
|
640
|
-
|
|
640
|
+
ae.call(n, _) && !Dt.hasOwnProperty(_) && (m[_] = n[_]);
|
|
641
641
|
if (e && e.defaultProps) {
|
|
642
642
|
var R = e.defaultProps;
|
|
643
643
|
for (_ in R)
|
|
@@ -645,25 +645,25 @@ function sr() {
|
|
|
645
645
|
}
|
|
646
646
|
if (d || P) {
|
|
647
647
|
var T = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
|
|
648
|
-
d && It(m, T), P &&
|
|
648
|
+
d && It(m, T), P && Nt(m, T);
|
|
649
649
|
}
|
|
650
|
-
return
|
|
650
|
+
return Ut(e, d, P, p, u, H.current, m);
|
|
651
651
|
}
|
|
652
652
|
}
|
|
653
|
-
var pe = j.ReactCurrentOwner,
|
|
654
|
-
function
|
|
653
|
+
var pe = j.ReactCurrentOwner, $e = j.ReactDebugCurrentFrame;
|
|
654
|
+
function N(e) {
|
|
655
655
|
if (e) {
|
|
656
|
-
var n = e._owner, i =
|
|
657
|
-
|
|
656
|
+
var n = e._owner, i = ne(e.type, e._source, n ? n.type : null);
|
|
657
|
+
$e.setExtraStackFrame(i);
|
|
658
658
|
} else
|
|
659
|
-
|
|
659
|
+
$e.setExtraStackFrame(null);
|
|
660
660
|
}
|
|
661
661
|
var ve;
|
|
662
662
|
ve = !1;
|
|
663
663
|
function ge(e) {
|
|
664
664
|
return typeof e == "object" && e !== null && e.$$typeof === r;
|
|
665
665
|
}
|
|
666
|
-
function
|
|
666
|
+
function Ye() {
|
|
667
667
|
{
|
|
668
668
|
if (pe.current) {
|
|
669
669
|
var e = A(pe.current.type);
|
|
@@ -675,7 +675,7 @@ Check the render method of \`` + e + "`.";
|
|
|
675
675
|
return "";
|
|
676
676
|
}
|
|
677
677
|
}
|
|
678
|
-
function
|
|
678
|
+
function $t(e) {
|
|
679
679
|
{
|
|
680
680
|
if (e !== void 0) {
|
|
681
681
|
var n = e.fileName.replace(/^.*[\\\/]/, ""), i = e.lineNumber;
|
|
@@ -686,10 +686,10 @@ Check your code at ` + n + ":" + i + ".";
|
|
|
686
686
|
return "";
|
|
687
687
|
}
|
|
688
688
|
}
|
|
689
|
-
var
|
|
690
|
-
function
|
|
689
|
+
var Be = {};
|
|
690
|
+
function Yt(e) {
|
|
691
691
|
{
|
|
692
|
-
var n =
|
|
692
|
+
var n = Ye();
|
|
693
693
|
if (!n) {
|
|
694
694
|
var i = typeof e == "string" ? e : e.displayName || e.name;
|
|
695
695
|
i && (n = `
|
|
@@ -699,39 +699,39 @@ Check the top-level render call using <` + i + ">.");
|
|
|
699
699
|
return n;
|
|
700
700
|
}
|
|
701
701
|
}
|
|
702
|
-
function
|
|
702
|
+
function We(e, n) {
|
|
703
703
|
{
|
|
704
704
|
if (!e._store || e._store.validated || e.key != null)
|
|
705
705
|
return;
|
|
706
706
|
e._store.validated = !0;
|
|
707
|
-
var i =
|
|
708
|
-
if (
|
|
707
|
+
var i = Yt(n);
|
|
708
|
+
if (Be[i])
|
|
709
709
|
return;
|
|
710
|
-
|
|
711
|
-
var
|
|
712
|
-
e && e._owner && e._owner !== pe.current && (
|
|
710
|
+
Be[i] = !0;
|
|
711
|
+
var u = "";
|
|
712
|
+
e && e._owner && e._owner !== pe.current && (u = " It was passed a child from " + A(e._owner.type) + "."), N(e), S('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', i, u), N(null);
|
|
713
713
|
}
|
|
714
714
|
}
|
|
715
|
-
function
|
|
715
|
+
function He(e, n) {
|
|
716
716
|
{
|
|
717
717
|
if (typeof e != "object")
|
|
718
718
|
return;
|
|
719
719
|
if (de(e))
|
|
720
720
|
for (var i = 0; i < e.length; i++) {
|
|
721
|
-
var
|
|
722
|
-
ge(
|
|
721
|
+
var u = e[i];
|
|
722
|
+
ge(u) && We(u, n);
|
|
723
723
|
}
|
|
724
724
|
else if (ge(e))
|
|
725
725
|
e._store && (e._store.validated = !0);
|
|
726
726
|
else if (e) {
|
|
727
|
-
var
|
|
728
|
-
if (typeof
|
|
729
|
-
for (var _ =
|
|
730
|
-
ge(m.value) &&
|
|
727
|
+
var p = I(e);
|
|
728
|
+
if (typeof p == "function" && p !== e.entries)
|
|
729
|
+
for (var _ = p.call(e), m; !(m = _.next()).done; )
|
|
730
|
+
ge(m.value) && We(m.value, n);
|
|
731
731
|
}
|
|
732
732
|
}
|
|
733
733
|
}
|
|
734
|
-
function
|
|
734
|
+
function Bt(e) {
|
|
735
735
|
{
|
|
736
736
|
var n = e.type;
|
|
737
737
|
if (n == null || typeof n == "string")
|
|
@@ -739,89 +739,89 @@ Check the top-level render call using <` + i + ">.");
|
|
|
739
739
|
var i;
|
|
740
740
|
if (typeof n == "function")
|
|
741
741
|
i = n.propTypes;
|
|
742
|
-
else if (typeof n == "object" && (n.$$typeof ===
|
|
742
|
+
else if (typeof n == "object" && (n.$$typeof === c || // Note: Memo only checks outer props here.
|
|
743
743
|
// Inner props are checked in the reconciler.
|
|
744
744
|
n.$$typeof === b))
|
|
745
745
|
i = n.propTypes;
|
|
746
746
|
else
|
|
747
747
|
return;
|
|
748
748
|
if (i) {
|
|
749
|
-
var
|
|
750
|
-
|
|
749
|
+
var u = A(n);
|
|
750
|
+
wt(i, e.props, "prop", u, e);
|
|
751
751
|
} else if (n.PropTypes !== void 0 && !ve) {
|
|
752
752
|
ve = !0;
|
|
753
|
-
var
|
|
754
|
-
S("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",
|
|
753
|
+
var p = A(n);
|
|
754
|
+
S("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", p || "Unknown");
|
|
755
755
|
}
|
|
756
756
|
typeof n.getDefaultProps == "function" && !n.getDefaultProps.isReactClassApproved && S("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
757
757
|
}
|
|
758
758
|
}
|
|
759
|
-
function
|
|
759
|
+
function Wt(e) {
|
|
760
760
|
{
|
|
761
761
|
for (var n = Object.keys(e.props), i = 0; i < n.length; i++) {
|
|
762
|
-
var
|
|
763
|
-
if (
|
|
764
|
-
|
|
762
|
+
var u = n[i];
|
|
763
|
+
if (u !== "children" && u !== "key") {
|
|
764
|
+
N(e), S("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", u), N(null);
|
|
765
765
|
break;
|
|
766
766
|
}
|
|
767
767
|
}
|
|
768
|
-
e.ref !== null && (
|
|
768
|
+
e.ref !== null && (N(e), S("Invalid attribute `ref` supplied to `React.Fragment`."), N(null));
|
|
769
769
|
}
|
|
770
770
|
}
|
|
771
|
-
function
|
|
771
|
+
function ze(e, n, i, u, p, _) {
|
|
772
772
|
{
|
|
773
|
-
var m =
|
|
773
|
+
var m = St(e);
|
|
774
774
|
if (!m) {
|
|
775
775
|
var d = "";
|
|
776
776
|
(e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (d += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
777
|
-
var P =
|
|
778
|
-
P ? d += P : d +=
|
|
777
|
+
var P = $t(p);
|
|
778
|
+
P ? d += P : d += Ye();
|
|
779
779
|
var R;
|
|
780
780
|
e === null ? R = "null" : de(e) ? R = "array" : e !== void 0 && e.$$typeof === r ? (R = "<" + (A(e.type) || "Unknown") + " />", d = " Did you accidentally export a JSX literal instead of a component?") : R = typeof e, S("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", R, d);
|
|
781
781
|
}
|
|
782
|
-
var T =
|
|
782
|
+
var T = Vt(e, n, i, p, _);
|
|
783
783
|
if (T == null)
|
|
784
784
|
return T;
|
|
785
785
|
if (m) {
|
|
786
786
|
var w = n.children;
|
|
787
787
|
if (w !== void 0)
|
|
788
|
-
if (
|
|
788
|
+
if (u)
|
|
789
789
|
if (de(w)) {
|
|
790
|
-
for (var
|
|
791
|
-
|
|
790
|
+
for (var U = 0; U < w.length; U++)
|
|
791
|
+
He(w[U], e);
|
|
792
792
|
Object.freeze && Object.freeze(w);
|
|
793
793
|
} else
|
|
794
794
|
S("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
795
795
|
else
|
|
796
|
-
|
|
796
|
+
He(w, e);
|
|
797
797
|
}
|
|
798
|
-
return e === s ?
|
|
798
|
+
return e === s ? Wt(T) : Bt(T), T;
|
|
799
799
|
}
|
|
800
800
|
}
|
|
801
|
-
function
|
|
802
|
-
return
|
|
801
|
+
function Ht(e, n, i) {
|
|
802
|
+
return ze(e, n, i, !0);
|
|
803
803
|
}
|
|
804
|
-
function
|
|
805
|
-
return
|
|
804
|
+
function zt(e, n, i) {
|
|
805
|
+
return ze(e, n, i, !1);
|
|
806
806
|
}
|
|
807
|
-
var
|
|
808
|
-
G.Fragment = s, G.jsx =
|
|
807
|
+
var qt = zt, Gt = Ht;
|
|
808
|
+
G.Fragment = s, G.jsx = qt, G.jsxs = Gt;
|
|
809
809
|
}()), G;
|
|
810
810
|
}
|
|
811
|
-
process.env.NODE_ENV === "production" ? Ee.exports =
|
|
811
|
+
process.env.NODE_ENV === "production" ? Ee.exports = or() : Ee.exports = ir();
|
|
812
812
|
var J = Ee.exports;
|
|
813
|
-
function
|
|
813
|
+
function Zr({
|
|
814
814
|
children: t,
|
|
815
815
|
maps: r,
|
|
816
816
|
externalSync: a
|
|
817
817
|
}) {
|
|
818
|
-
const [s, o] =
|
|
818
|
+
const [s, o] = tt(rr, {
|
|
819
819
|
...K.state,
|
|
820
820
|
maps: r.reduce((v, E) => (v[E.id] = {
|
|
821
821
|
...E,
|
|
822
822
|
isLoaded: !1
|
|
823
823
|
}, v), K.state.maps)
|
|
824
|
-
}),
|
|
824
|
+
}), f = se(
|
|
825
825
|
r.reduce((v, E) => (v[E.id] = {
|
|
826
826
|
instanceRef: {
|
|
827
827
|
current: null
|
|
@@ -830,7 +830,7 @@ function Jr({
|
|
|
830
830
|
current: null
|
|
831
831
|
}
|
|
832
832
|
}, v), {})
|
|
833
|
-
),
|
|
833
|
+
), l = O(
|
|
834
834
|
(v, E, x) => {
|
|
835
835
|
r[0].id === v && a?.({
|
|
836
836
|
type: E,
|
|
@@ -838,33 +838,33 @@ function Jr({
|
|
|
838
838
|
});
|
|
839
839
|
},
|
|
840
840
|
[a, r]
|
|
841
|
-
),
|
|
841
|
+
), g = O(
|
|
842
842
|
(v, E) => {
|
|
843
843
|
o({
|
|
844
|
-
type:
|
|
844
|
+
type: F.SetViewState,
|
|
845
845
|
payload: {
|
|
846
846
|
id: E,
|
|
847
847
|
viewState: v
|
|
848
848
|
}
|
|
849
|
-
}),
|
|
849
|
+
}), l(E, F.SetViewState, v);
|
|
850
850
|
},
|
|
851
|
-
[o,
|
|
852
|
-
),
|
|
851
|
+
[o, l]
|
|
852
|
+
), c = O(
|
|
853
853
|
({ height: v, width: E }, x) => {
|
|
854
854
|
o({
|
|
855
|
-
type:
|
|
855
|
+
type: F.SetResize,
|
|
856
856
|
payload: {
|
|
857
857
|
id: x,
|
|
858
858
|
height: v,
|
|
859
859
|
width: E
|
|
860
860
|
}
|
|
861
|
-
}),
|
|
861
|
+
}), l(x, F.SetResize, { height: v, width: E });
|
|
862
862
|
},
|
|
863
|
-
[o,
|
|
864
|
-
),
|
|
863
|
+
[o, l]
|
|
864
|
+
), y = O(
|
|
865
865
|
(v, E) => {
|
|
866
866
|
o({
|
|
867
|
-
type:
|
|
867
|
+
type: F.SetBasemap,
|
|
868
868
|
payload: {
|
|
869
869
|
id: E,
|
|
870
870
|
basemap: v
|
|
@@ -872,10 +872,10 @@ function Jr({
|
|
|
872
872
|
});
|
|
873
873
|
},
|
|
874
874
|
[o]
|
|
875
|
-
),
|
|
875
|
+
), h = O(
|
|
876
876
|
(v, E) => {
|
|
877
877
|
o({
|
|
878
|
-
type:
|
|
878
|
+
type: F.SetZoom,
|
|
879
879
|
payload: {
|
|
880
880
|
id: E,
|
|
881
881
|
zoom: v
|
|
@@ -883,10 +883,10 @@ function Jr({
|
|
|
883
883
|
});
|
|
884
884
|
},
|
|
885
885
|
[o]
|
|
886
|
-
), b =
|
|
886
|
+
), b = O(
|
|
887
887
|
(v, E) => {
|
|
888
888
|
o({
|
|
889
|
-
type:
|
|
889
|
+
type: F.SetLoaded,
|
|
890
890
|
payload: {
|
|
891
891
|
id: E,
|
|
892
892
|
value: v
|
|
@@ -894,25 +894,25 @@ function Jr({
|
|
|
894
894
|
});
|
|
895
895
|
},
|
|
896
896
|
[o]
|
|
897
|
-
),
|
|
898
|
-
setViewState:
|
|
899
|
-
setBasemap:
|
|
900
|
-
setResize:
|
|
901
|
-
setZoom:
|
|
897
|
+
), M = se({
|
|
898
|
+
setViewState: g,
|
|
899
|
+
setBasemap: y,
|
|
900
|
+
setResize: c,
|
|
901
|
+
setZoom: h,
|
|
902
902
|
setLoaded: b
|
|
903
903
|
});
|
|
904
|
-
return /* @__PURE__ */ J.jsx(
|
|
904
|
+
return /* @__PURE__ */ J.jsx(it.Provider, { value: M.current, children: /* @__PURE__ */ J.jsx(ot.Provider, { value: f, children: /* @__PURE__ */ J.jsx(at.Provider, { value: s, children: t }) }) });
|
|
905
905
|
}
|
|
906
|
-
var C = /* @__PURE__ */ ((t) => (t.milimeter = "milimeter", t.centimeter = "centimeter", t.meter = "meter", t.kilometer = "kilometer", t.mile = "mile", t.feet = "feet", t))(C || {}),
|
|
907
|
-
const
|
|
906
|
+
var C = /* @__PURE__ */ ((t) => (t.milimeter = "milimeter", t.centimeter = "centimeter", t.meter = "meter", t.kilometer = "kilometer", t.mile = "mile", t.feet = "feet", t))(C || {}), ct = /* @__PURE__ */ ((t) => (t.meters = "meters", t.kilometer = "kilometers", t.mile = "miles", t))(ct || {}), ce = /* @__PURE__ */ ((t) => (t.AddPosition = "addPosition", t.Finish = "finish", t))(ce || {});
|
|
907
|
+
const Je = [
|
|
908
908
|
"anyclick",
|
|
909
909
|
"pointermove",
|
|
910
910
|
"panstart",
|
|
911
911
|
"panmove",
|
|
912
912
|
"panend",
|
|
913
913
|
"keyup"
|
|
914
|
-
],
|
|
915
|
-
id:
|
|
914
|
+
], sr = "mapMeasureLayer", cr = {
|
|
915
|
+
id: sr,
|
|
916
916
|
pickable: !1,
|
|
917
917
|
billboard: !1,
|
|
918
918
|
editHandlePointRadiusUnits: "pixels",
|
|
@@ -940,16 +940,14 @@ const Ke = [
|
|
|
940
940
|
}, be = {
|
|
941
941
|
editing: [71, 219, 153, 255],
|
|
942
942
|
finished: [49, 153, 107, 255]
|
|
943
|
-
},
|
|
944
|
-
locale: "en",
|
|
945
|
-
getColumnName: "<b>Total distance</b> ",
|
|
943
|
+
}, ur = {
|
|
946
944
|
styles: {
|
|
947
945
|
colors: {
|
|
948
946
|
editing: be.editing,
|
|
949
947
|
finished: be.finished
|
|
950
948
|
}
|
|
951
949
|
}
|
|
952
|
-
},
|
|
950
|
+
}, Ke = {
|
|
953
951
|
[C.kilometer]: "km",
|
|
954
952
|
[C.centimeter]: "cm",
|
|
955
953
|
[C.milimeter]: "mm",
|
|
@@ -964,14 +962,14 @@ const Ke = [
|
|
|
964
962
|
[C.meter]: "meter",
|
|
965
963
|
[C.feet]: "foot"
|
|
966
964
|
};
|
|
967
|
-
class fr extends
|
|
965
|
+
class fr extends Jt {
|
|
968
966
|
eventManager;
|
|
969
967
|
constructor(r) {
|
|
970
968
|
super(r), this.eventManager = r.eventManager;
|
|
971
969
|
}
|
|
972
970
|
_addEventHandlers() {
|
|
973
971
|
const r = this._getEventManager(), { eventHandler: a } = this.state._editableLayerState;
|
|
974
|
-
for (const s of
|
|
972
|
+
for (const s of Je)
|
|
975
973
|
r.on(s, a, {
|
|
976
974
|
// give nebula a higher priority so that it can stop propagation to deck.gl's map panning handlers
|
|
977
975
|
priority: 100
|
|
@@ -979,7 +977,7 @@ class fr extends Kt {
|
|
|
979
977
|
}
|
|
980
978
|
_removeEventHandlers(r = void 0) {
|
|
981
979
|
const a = r || this._getEventManager(), { eventHandler: s } = this.state._editableLayerState;
|
|
982
|
-
for (const o of
|
|
980
|
+
for (const o of Je)
|
|
983
981
|
a.off(o, s);
|
|
984
982
|
}
|
|
985
983
|
_getEventManager() {
|
|
@@ -987,14 +985,15 @@ class fr extends Kt {
|
|
|
987
985
|
this.context.deck.eventManager;
|
|
988
986
|
}
|
|
989
987
|
}
|
|
990
|
-
class dr extends
|
|
988
|
+
class dr extends Kt {
|
|
991
989
|
handleClick(r, a) {
|
|
992
990
|
super.handleClick(r, a), a.onEdit({
|
|
993
991
|
// data is the same
|
|
994
992
|
updatedData: a.data,
|
|
995
|
-
editType:
|
|
993
|
+
editType: ce.AddPosition,
|
|
996
994
|
editContext: {
|
|
997
|
-
distance: this._currentDistance
|
|
995
|
+
distance: this._currentDistance,
|
|
996
|
+
finished: this._isMeasuringSessionFinished
|
|
998
997
|
}
|
|
999
998
|
});
|
|
1000
999
|
}
|
|
@@ -1008,7 +1007,7 @@ class dr extends Xt {
|
|
|
1008
1007
|
case "Escape":
|
|
1009
1008
|
this._isMeasuringSessionFinished = !0, o === 1 && (this.resetClickSequence(), this._currentTooltips = []), a.onUpdateCursor("cell"), a.onEdit({
|
|
1010
1009
|
updatedData: a.data,
|
|
1011
|
-
editType:
|
|
1010
|
+
editType: ce.Finish,
|
|
1012
1011
|
editContext: {
|
|
1013
1012
|
finished: this._isMeasuringSessionFinished
|
|
1014
1013
|
}
|
|
@@ -1021,162 +1020,79 @@ function mr(t) {
|
|
|
1021
1020
|
return he[t]?.type;
|
|
1022
1021
|
}
|
|
1023
1022
|
function pr(t) {
|
|
1024
|
-
return mr(t) ===
|
|
1023
|
+
return mr(t) === nt.GoogleMaps;
|
|
1025
1024
|
}
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
style: "decimal",
|
|
1029
|
-
maximumFractionDigits: 1,
|
|
1030
|
-
minimumFractionDigits: 0,
|
|
1031
|
-
notation: "compact",
|
|
1032
|
-
compactDisplay: "short"
|
|
1033
|
-
},
|
|
1034
|
-
CURRENCY: {
|
|
1035
|
-
style: "currency",
|
|
1036
|
-
currency: "USD",
|
|
1037
|
-
maximumFractionDigits: 2,
|
|
1038
|
-
minimumFractionDigits: 2,
|
|
1039
|
-
notation: "compact",
|
|
1040
|
-
compactDisplay: "short"
|
|
1041
|
-
},
|
|
1042
|
-
DATE: {
|
|
1043
|
-
year: "numeric",
|
|
1044
|
-
month: "2-digit",
|
|
1045
|
-
day: "2-digit"
|
|
1046
|
-
}
|
|
1025
|
+
var vr = function(r) {
|
|
1026
|
+
return gr(r) && !yr(r);
|
|
1047
1027
|
};
|
|
1048
|
-
function
|
|
1049
|
-
return
|
|
1050
|
-
}
|
|
1051
|
-
function mt(t, r, a = {}) {
|
|
1052
|
-
return dt(t, r, { ...ft.NUMBER, ...a });
|
|
1053
|
-
}
|
|
1054
|
-
function vr(t, r, a = {}) {
|
|
1055
|
-
return dt(t, r, { ...ft.CURRENCY, ...a });
|
|
1056
|
-
}
|
|
1057
|
-
var N = /* @__PURE__ */ ((t) => (t.CURRENCY = "CURRENCY", t.DEFAULT = "DEFAULT", t.NUMBER = "NUMBER", t))(N || {});
|
|
1058
|
-
const et = {
|
|
1059
|
-
[N.CURRENCY]: {
|
|
1060
|
-
type: N.CURRENCY,
|
|
1061
|
-
format: (t, r) => vr(t, r)
|
|
1062
|
-
},
|
|
1063
|
-
[N.NUMBER]: {
|
|
1064
|
-
type: N.NUMBER,
|
|
1065
|
-
format: (t, r) => mt(t, r)
|
|
1066
|
-
},
|
|
1067
|
-
[N.DEFAULT]: {
|
|
1068
|
-
type: N.DEFAULT,
|
|
1069
|
-
format: (t) => t.toLocaleString()
|
|
1070
|
-
}
|
|
1071
|
-
};
|
|
1072
|
-
function gr({
|
|
1073
|
-
properties: t,
|
|
1074
|
-
formatters: r = {},
|
|
1075
|
-
includeColumns: a = Object.keys(t),
|
|
1076
|
-
locale: s = "en-US",
|
|
1077
|
-
showColumnName: o = !0,
|
|
1078
|
-
title: l,
|
|
1079
|
-
getColumnName: f = _r,
|
|
1080
|
-
getFieldHtml: h = hr,
|
|
1081
|
-
getTitle: u = yr,
|
|
1082
|
-
getValue: p = Er
|
|
1083
|
-
}) {
|
|
1084
|
-
const y = l ? u(l) : "", O = a.reduce((v, E) => {
|
|
1085
|
-
const x = r[E], U = t[E], j = p(U, s, x), S = o ? f(E) : "";
|
|
1086
|
-
return v + h(S, j);
|
|
1087
|
-
}, "");
|
|
1088
|
-
return y + O;
|
|
1028
|
+
function gr(t) {
|
|
1029
|
+
return !!t && typeof t == "object";
|
|
1089
1030
|
}
|
|
1090
1031
|
function yr(t) {
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
function hr(t, r) {
|
|
1094
|
-
return `${t}${r}</br>`;
|
|
1095
|
-
}
|
|
1096
|
-
function Er(t, r, a) {
|
|
1097
|
-
try {
|
|
1098
|
-
return br(a)(t, r);
|
|
1099
|
-
} catch {
|
|
1100
|
-
return t;
|
|
1101
|
-
}
|
|
1032
|
+
var r = Object.prototype.toString.call(t);
|
|
1033
|
+
return r === "[object RegExp]" || r === "[object Date]" || br(t);
|
|
1102
1034
|
}
|
|
1035
|
+
var hr = typeof Symbol == "function" && Symbol.for, Er = hr ? Symbol.for("react.element") : 60103;
|
|
1103
1036
|
function br(t) {
|
|
1104
|
-
return typeof
|
|
1037
|
+
return t.$$typeof === Er;
|
|
1105
1038
|
}
|
|
1106
1039
|
function _r(t) {
|
|
1107
|
-
return `<strong>${t}</strong>: `;
|
|
1108
|
-
}
|
|
1109
|
-
var Sr = function(r) {
|
|
1110
|
-
return Rr(r) && !Tr(r);
|
|
1111
|
-
};
|
|
1112
|
-
function Rr(t) {
|
|
1113
|
-
return !!t && typeof t == "object";
|
|
1114
|
-
}
|
|
1115
|
-
function Tr(t) {
|
|
1116
|
-
var r = Object.prototype.toString.call(t);
|
|
1117
|
-
return r === "[object RegExp]" || r === "[object Date]" || Pr(t);
|
|
1118
|
-
}
|
|
1119
|
-
var Mr = typeof Symbol == "function" && Symbol.for, Or = Mr ? Symbol.for("react.element") : 60103;
|
|
1120
|
-
function Pr(t) {
|
|
1121
|
-
return t.$$typeof === Or;
|
|
1122
|
-
}
|
|
1123
|
-
function Cr(t) {
|
|
1124
1040
|
return Array.isArray(t) ? [] : {};
|
|
1125
1041
|
}
|
|
1126
|
-
function
|
|
1127
|
-
return r.clone !== !1 && r.isMergeableObject(t) ?
|
|
1042
|
+
function X(t, r) {
|
|
1043
|
+
return r.clone !== !1 && r.isMergeableObject(t) ? $(_r(t), t, r) : t;
|
|
1128
1044
|
}
|
|
1129
|
-
function
|
|
1045
|
+
function Sr(t, r, a) {
|
|
1130
1046
|
return t.concat(r).map(function(s) {
|
|
1131
|
-
return
|
|
1047
|
+
return X(s, a);
|
|
1132
1048
|
});
|
|
1133
1049
|
}
|
|
1134
|
-
function
|
|
1050
|
+
function Rr(t, r) {
|
|
1135
1051
|
if (!r.customMerge)
|
|
1136
|
-
return
|
|
1052
|
+
return $;
|
|
1137
1053
|
var a = r.customMerge(t);
|
|
1138
|
-
return typeof a == "function" ? a :
|
|
1054
|
+
return typeof a == "function" ? a : $;
|
|
1139
1055
|
}
|
|
1140
|
-
function
|
|
1056
|
+
function Tr(t) {
|
|
1141
1057
|
return Object.getOwnPropertySymbols ? Object.getOwnPropertySymbols(t).filter(function(r) {
|
|
1142
1058
|
return Object.propertyIsEnumerable.call(t, r);
|
|
1143
1059
|
}) : [];
|
|
1144
1060
|
}
|
|
1145
|
-
function
|
|
1146
|
-
return Object.keys(t).concat(
|
|
1061
|
+
function Xe(t) {
|
|
1062
|
+
return Object.keys(t).concat(Tr(t));
|
|
1147
1063
|
}
|
|
1148
|
-
function
|
|
1064
|
+
function ut(t, r) {
|
|
1149
1065
|
try {
|
|
1150
1066
|
return r in t;
|
|
1151
1067
|
} catch {
|
|
1152
1068
|
return !1;
|
|
1153
1069
|
}
|
|
1154
1070
|
}
|
|
1155
|
-
function
|
|
1156
|
-
return
|
|
1071
|
+
function Mr(t, r) {
|
|
1072
|
+
return ut(t, r) && !(Object.hasOwnProperty.call(t, r) && Object.propertyIsEnumerable.call(t, r));
|
|
1157
1073
|
}
|
|
1158
|
-
function
|
|
1074
|
+
function Or(t, r, a) {
|
|
1159
1075
|
var s = {};
|
|
1160
|
-
return a.isMergeableObject(t) &&
|
|
1161
|
-
s[o] =
|
|
1162
|
-
}),
|
|
1163
|
-
|
|
1076
|
+
return a.isMergeableObject(t) && Xe(t).forEach(function(o) {
|
|
1077
|
+
s[o] = X(t[o], a);
|
|
1078
|
+
}), Xe(r).forEach(function(o) {
|
|
1079
|
+
Mr(t, o) || (ut(t, o) && a.isMergeableObject(r[o]) ? s[o] = Rr(o, a)(t[o], r[o], a) : s[o] = X(r[o], a));
|
|
1164
1080
|
}), s;
|
|
1165
1081
|
}
|
|
1166
|
-
function
|
|
1167
|
-
a = a || {}, a.arrayMerge = a.arrayMerge ||
|
|
1168
|
-
var s = Array.isArray(r), o = Array.isArray(t),
|
|
1169
|
-
return
|
|
1082
|
+
function $(t, r, a) {
|
|
1083
|
+
a = a || {}, a.arrayMerge = a.arrayMerge || Sr, a.isMergeableObject = a.isMergeableObject || vr, a.cloneUnlessOtherwiseSpecified = X;
|
|
1084
|
+
var s = Array.isArray(r), o = Array.isArray(t), f = s === o;
|
|
1085
|
+
return f ? s ? a.arrayMerge(t, r, a) : Or(t, r, a) : X(r, a);
|
|
1170
1086
|
}
|
|
1171
|
-
|
|
1087
|
+
$.all = function(r, a) {
|
|
1172
1088
|
if (!Array.isArray(r))
|
|
1173
1089
|
throw new Error("first argument should be an array");
|
|
1174
1090
|
return r.reduce(function(s, o) {
|
|
1175
|
-
return
|
|
1091
|
+
return $(s, o, a);
|
|
1176
1092
|
}, {});
|
|
1177
1093
|
};
|
|
1178
|
-
var
|
|
1179
|
-
const
|
|
1094
|
+
var Pr = $, Cr = Pr;
|
|
1095
|
+
const ie = /* @__PURE__ */ ar(Cr), Z = () => {
|
|
1180
1096
|
throw new Error(
|
|
1181
1097
|
"You forgot to wrap your component in <MeasurementToolsProvider>."
|
|
1182
1098
|
);
|
|
@@ -1195,18 +1111,49 @@ const se = /* @__PURE__ */ or(Lr), Z = () => {
|
|
|
1195
1111
|
setDistance: Z,
|
|
1196
1112
|
setLocale: Z
|
|
1197
1113
|
}
|
|
1198
|
-
},
|
|
1199
|
-
function
|
|
1200
|
-
return
|
|
1201
|
-
|
|
1114
|
+
}, lt = Q(Se.state), ft = Q(Se.actions);
|
|
1115
|
+
function dt() {
|
|
1116
|
+
return ee(
|
|
1117
|
+
lt
|
|
1202
1118
|
);
|
|
1203
1119
|
}
|
|
1204
|
-
function
|
|
1205
|
-
return
|
|
1206
|
-
|
|
1120
|
+
function mt() {
|
|
1121
|
+
return ee(
|
|
1122
|
+
ft
|
|
1207
1123
|
);
|
|
1208
1124
|
}
|
|
1209
|
-
const
|
|
1125
|
+
const pt = {
|
|
1126
|
+
NUMBER: {
|
|
1127
|
+
style: "decimal",
|
|
1128
|
+
maximumFractionDigits: 1,
|
|
1129
|
+
minimumFractionDigits: 0,
|
|
1130
|
+
notation: "compact",
|
|
1131
|
+
compactDisplay: "short"
|
|
1132
|
+
},
|
|
1133
|
+
CURRENCY: {
|
|
1134
|
+
style: "currency",
|
|
1135
|
+
currency: "USD",
|
|
1136
|
+
maximumFractionDigits: 2,
|
|
1137
|
+
minimumFractionDigits: 2,
|
|
1138
|
+
notation: "compact",
|
|
1139
|
+
compactDisplay: "short"
|
|
1140
|
+
},
|
|
1141
|
+
DATE: {
|
|
1142
|
+
year: "numeric",
|
|
1143
|
+
month: "2-digit",
|
|
1144
|
+
day: "2-digit"
|
|
1145
|
+
}
|
|
1146
|
+
};
|
|
1147
|
+
function vt(t, r, a) {
|
|
1148
|
+
return Intl.NumberFormat(r, a).format(t);
|
|
1149
|
+
}
|
|
1150
|
+
function gt(t, r, a = {}) {
|
|
1151
|
+
return vt(t, r, { ...pt.NUMBER, ...a });
|
|
1152
|
+
}
|
|
1153
|
+
function wr(t, r, a = {}) {
|
|
1154
|
+
return vt(t, r, { ...pt.CURRENCY, ...a });
|
|
1155
|
+
}
|
|
1156
|
+
const xr = {
|
|
1210
1157
|
nm: {
|
|
1211
1158
|
name: {
|
|
1212
1159
|
singular: "Nanometer",
|
|
@@ -1249,7 +1196,7 @@ const kr = {
|
|
|
1249
1196
|
},
|
|
1250
1197
|
to_anchor: 1e3
|
|
1251
1198
|
}
|
|
1252
|
-
},
|
|
1199
|
+
}, jr = {
|
|
1253
1200
|
mil: {
|
|
1254
1201
|
name: {
|
|
1255
1202
|
singular: "Mil",
|
|
@@ -1306,10 +1253,10 @@ const kr = {
|
|
|
1306
1253
|
},
|
|
1307
1254
|
to_anchor: 6076.12
|
|
1308
1255
|
}
|
|
1309
|
-
},
|
|
1256
|
+
}, Ar = {
|
|
1310
1257
|
systems: {
|
|
1311
|
-
metric:
|
|
1312
|
-
imperial:
|
|
1258
|
+
metric: xr,
|
|
1259
|
+
imperial: jr
|
|
1313
1260
|
},
|
|
1314
1261
|
anchors: {
|
|
1315
1262
|
metric: {
|
|
@@ -1323,89 +1270,78 @@ const kr = {
|
|
|
1323
1270
|
}
|
|
1324
1271
|
}
|
|
1325
1272
|
}
|
|
1326
|
-
},
|
|
1327
|
-
length:
|
|
1273
|
+
}, Dr = Qt({
|
|
1274
|
+
length: Ar
|
|
1328
1275
|
});
|
|
1329
|
-
function
|
|
1330
|
-
return
|
|
1276
|
+
function yt(t, r) {
|
|
1277
|
+
return Dr(t).from(Ke[C.meter]).to(Ke[r]);
|
|
1331
1278
|
}
|
|
1332
|
-
function
|
|
1279
|
+
function ht({
|
|
1333
1280
|
meters: t,
|
|
1334
1281
|
unit: r,
|
|
1335
1282
|
locale: a
|
|
1336
1283
|
}) {
|
|
1337
|
-
return `${
|
|
1284
|
+
return `${gt(yt(t, r), a, {
|
|
1338
1285
|
style: "unit",
|
|
1339
1286
|
unit: lr[r],
|
|
1340
1287
|
unitDisplay: "short"
|
|
1341
1288
|
})}`;
|
|
1342
1289
|
}
|
|
1290
|
+
function Jr(t, {
|
|
1291
|
+
hasDoubleClickZoom: r
|
|
1292
|
+
}) {
|
|
1293
|
+
return typeof t == "boolean" ? { doubleClickZoom: r } : { ...t, doubleClickZoom: r };
|
|
1294
|
+
}
|
|
1343
1295
|
function Kr({
|
|
1344
1296
|
mapId: t,
|
|
1345
|
-
defaultProps: {
|
|
1346
|
-
|
|
1347
|
-
},
|
|
1348
|
-
layerProps: s = {}
|
|
1297
|
+
defaultProps: { styles: r = ur.styles } = {},
|
|
1298
|
+
layerProps: a = {}
|
|
1349
1299
|
}) {
|
|
1350
|
-
const { enable:
|
|
1351
|
-
if (!y || !pr(
|
|
1300
|
+
const { enable: s, unit: o, finished: f, locale: l } = dt(), { setDistance: g, setFinished: c } = mt(), { isLoaded: y, basemap: h } = st(t), { getOverlayInstance: b } = _e(t), M = se(), v = Zt(() => {
|
|
1301
|
+
if (!y || !pr(h))
|
|
1352
1302
|
return null;
|
|
1353
|
-
const
|
|
1354
|
-
return new
|
|
1355
|
-
}, [y,
|
|
1356
|
-
(
|
|
1357
|
-
|
|
1358
|
-
properties: {
|
|
1359
|
-
distance: Re({
|
|
1360
|
-
meters: L.distance,
|
|
1361
|
-
locale: L.locale,
|
|
1362
|
-
unit: l
|
|
1363
|
-
})
|
|
1364
|
-
},
|
|
1365
|
-
getColumnName: () => r
|
|
1366
|
-
});
|
|
1303
|
+
const Y = b()?.getDiv();
|
|
1304
|
+
return new Xt(Y, {});
|
|
1305
|
+
}, [y, b, h]), E = f ? r.colors?.finished : r.colors?.editing, x = O(
|
|
1306
|
+
({ editType: Y, editContext: B }) => {
|
|
1307
|
+
Y === ce.AddPosition && g(B.distance), c(B.finished);
|
|
1367
1308
|
},
|
|
1368
|
-
[
|
|
1369
|
-
), j = M(
|
|
1370
|
-
({ editType: F, editContext: L }) => {
|
|
1371
|
-
F === X.AddPosition ? u(L.distance) : F === X.Finish && p(L.finished);
|
|
1372
|
-
},
|
|
1373
|
-
[u, p]
|
|
1309
|
+
[g, c]
|
|
1374
1310
|
);
|
|
1375
|
-
if (
|
|
1376
|
-
|
|
1377
|
-
}, [
|
|
1311
|
+
if (rt(() => {
|
|
1312
|
+
s || (M.current = void 0);
|
|
1313
|
+
}, [s]), !s || !y)
|
|
1378
1314
|
return null;
|
|
1379
|
-
const S =
|
|
1380
|
-
|
|
1381
|
-
h,
|
|
1315
|
+
const { pickable: I, onHover: j, ...S } = Fr(
|
|
1316
|
+
a,
|
|
1382
1317
|
l,
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1318
|
+
o,
|
|
1319
|
+
x,
|
|
1320
|
+
E || be.guide
|
|
1386
1321
|
);
|
|
1387
|
-
return !
|
|
1322
|
+
return !M.current && !S.mode && (M.current = new dr()), new fr({
|
|
1388
1323
|
...S,
|
|
1389
|
-
|
|
1390
|
-
|
|
1324
|
+
pickable: I || !f,
|
|
1325
|
+
onHover: f ? j : void 0,
|
|
1326
|
+
mode: S?.mode || M.current,
|
|
1327
|
+
eventManager: v
|
|
1391
1328
|
});
|
|
1392
1329
|
}
|
|
1393
|
-
function
|
|
1394
|
-
const f =
|
|
1330
|
+
function Fr(t, r, a, s, o) {
|
|
1331
|
+
const f = ie(t, {
|
|
1395
1332
|
modeConfig: {
|
|
1396
1333
|
// We force distance due to conversion is addressed at feature getText level
|
|
1397
|
-
formatTooltip: (
|
|
1334
|
+
formatTooltip: (c) => c,
|
|
1398
1335
|
turfOptions: {
|
|
1399
|
-
units:
|
|
1336
|
+
units: ct.meters
|
|
1400
1337
|
}
|
|
1401
1338
|
},
|
|
1402
|
-
|
|
1403
|
-
onEdit: o,
|
|
1339
|
+
onEdit: s,
|
|
1404
1340
|
_subLayerProps: {
|
|
1405
1341
|
tooltips: {
|
|
1406
|
-
getText: (
|
|
1407
|
-
...
|
|
1408
|
-
meters:
|
|
1342
|
+
getText: (c) => ht({
|
|
1343
|
+
...c,
|
|
1344
|
+
meters: c.text,
|
|
1409
1345
|
locale: r,
|
|
1410
1346
|
unit: a
|
|
1411
1347
|
}),
|
|
@@ -1414,33 +1350,33 @@ function Vr(t, r, a, s, o, l) {
|
|
|
1414
1350
|
}
|
|
1415
1351
|
}
|
|
1416
1352
|
}
|
|
1417
|
-
}),
|
|
1353
|
+
}), l = ie(cr, {
|
|
1418
1354
|
_subLayerProps: {
|
|
1419
1355
|
guides: {
|
|
1420
|
-
getLineColor:
|
|
1421
|
-
getFillColor:
|
|
1356
|
+
getLineColor: o,
|
|
1357
|
+
getFillColor: o
|
|
1422
1358
|
}
|
|
1423
1359
|
},
|
|
1424
|
-
getEditHandlePointColor:
|
|
1425
|
-
getEditHandlePointOutlineColor:
|
|
1360
|
+
getEditHandlePointColor: o,
|
|
1361
|
+
getEditHandlePointOutlineColor: o
|
|
1426
1362
|
});
|
|
1427
|
-
return
|
|
1363
|
+
return ie(l, f);
|
|
1428
1364
|
}
|
|
1429
1365
|
function Xr({ children: t }) {
|
|
1430
|
-
const { distance: r, enable: a, unit: s, locale: o } =
|
|
1431
|
-
|
|
1366
|
+
const { distance: r, enable: a, unit: s, locale: o } = dt(), { setDistance: f, setEnable: l } = mt(), g = yt(r, s), c = () => {
|
|
1367
|
+
f(0), l(!a);
|
|
1432
1368
|
};
|
|
1433
1369
|
return t({
|
|
1434
1370
|
enable: a,
|
|
1435
1371
|
meters: r,
|
|
1436
|
-
text:
|
|
1437
|
-
distance:
|
|
1372
|
+
text: ht({ meters: r, unit: s, locale: o }),
|
|
1373
|
+
distance: g,
|
|
1438
1374
|
unit: s,
|
|
1439
|
-
onToggleButton:
|
|
1375
|
+
onToggleButton: c
|
|
1440
1376
|
});
|
|
1441
1377
|
}
|
|
1442
|
-
var
|
|
1443
|
-
function
|
|
1378
|
+
var V = /* @__PURE__ */ ((t) => (t.SetEnable = "SET_ENABLE", t.SetFinished = "SET_FINISHED", t.SetDistance = "SET_DISTANCE", t.SetUnit = "SET_UNIT", t.SetLocale = "SET_LOCALE", t))(V || {});
|
|
1379
|
+
function kr(t, { type: r, payload: a }) {
|
|
1444
1380
|
return {
|
|
1445
1381
|
SET_ENABLE: () => ({
|
|
1446
1382
|
...t,
|
|
@@ -1470,87 +1406,140 @@ function Qr({
|
|
|
1470
1406
|
defaultProps: r = {},
|
|
1471
1407
|
locale: a
|
|
1472
1408
|
}) {
|
|
1473
|
-
const [s, o] =
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
),
|
|
1409
|
+
const [s, o] = tt(
|
|
1410
|
+
kr,
|
|
1411
|
+
ie(Se.state, r)
|
|
1412
|
+
), f = O(
|
|
1477
1413
|
(b) => {
|
|
1478
|
-
o({ type:
|
|
1414
|
+
o({ type: V.SetLocale, payload: b });
|
|
1479
1415
|
},
|
|
1480
1416
|
[o]
|
|
1481
1417
|
);
|
|
1482
|
-
|
|
1483
|
-
a &&
|
|
1484
|
-
}, [a,
|
|
1485
|
-
const
|
|
1418
|
+
rt(() => {
|
|
1419
|
+
a && f(a);
|
|
1420
|
+
}, [a, f]);
|
|
1421
|
+
const l = O(
|
|
1486
1422
|
(b) => {
|
|
1487
|
-
o({ type:
|
|
1423
|
+
o({ type: V.SetEnable, payload: b });
|
|
1488
1424
|
},
|
|
1489
1425
|
[o]
|
|
1490
|
-
),
|
|
1426
|
+
), g = O(
|
|
1491
1427
|
(b) => {
|
|
1492
|
-
o({ type:
|
|
1428
|
+
o({ type: V.SetFinished, payload: b });
|
|
1493
1429
|
},
|
|
1494
1430
|
[o]
|
|
1495
|
-
),
|
|
1431
|
+
), c = O(
|
|
1496
1432
|
(b) => {
|
|
1497
|
-
o({ type:
|
|
1433
|
+
o({ type: V.SetDistance, payload: b });
|
|
1498
1434
|
},
|
|
1499
1435
|
[o]
|
|
1500
|
-
),
|
|
1436
|
+
), y = O(
|
|
1501
1437
|
(b) => {
|
|
1502
|
-
o({ type:
|
|
1438
|
+
o({ type: V.SetUnit, payload: b });
|
|
1503
1439
|
},
|
|
1504
1440
|
[o]
|
|
1505
|
-
),
|
|
1506
|
-
setEnable:
|
|
1507
|
-
setFinished:
|
|
1508
|
-
setDistance:
|
|
1509
|
-
setUnit:
|
|
1510
|
-
setLocale:
|
|
1441
|
+
), h = se({
|
|
1442
|
+
setEnable: l,
|
|
1443
|
+
setFinished: g,
|
|
1444
|
+
setDistance: c,
|
|
1445
|
+
setUnit: y,
|
|
1446
|
+
setLocale: f
|
|
1511
1447
|
});
|
|
1512
|
-
return /* @__PURE__ */ J.jsx(
|
|
1448
|
+
return /* @__PURE__ */ J.jsx(ft.Provider, { value: h.current, children: /* @__PURE__ */ J.jsx(lt.Provider, { value: s, children: t }) });
|
|
1449
|
+
}
|
|
1450
|
+
var k = /* @__PURE__ */ ((t) => (t.CURRENCY = "CURRENCY", t.DEFAULT = "DEFAULT", t.NUMBER = "NUMBER", t))(k || {});
|
|
1451
|
+
const Qe = {
|
|
1452
|
+
[k.CURRENCY]: {
|
|
1453
|
+
type: k.CURRENCY,
|
|
1454
|
+
format: (t, r) => wr(t, r)
|
|
1455
|
+
},
|
|
1456
|
+
[k.NUMBER]: {
|
|
1457
|
+
type: k.NUMBER,
|
|
1458
|
+
format: (t, r) => gt(t, r)
|
|
1459
|
+
},
|
|
1460
|
+
[k.DEFAULT]: {
|
|
1461
|
+
type: k.DEFAULT,
|
|
1462
|
+
format: (t) => t.toLocaleString()
|
|
1463
|
+
}
|
|
1464
|
+
};
|
|
1465
|
+
function en({
|
|
1466
|
+
properties: t,
|
|
1467
|
+
formatters: r = {},
|
|
1468
|
+
includeColumns: a = Object.keys(t),
|
|
1469
|
+
locale: s = "en-US",
|
|
1470
|
+
showColumnName: o = !0,
|
|
1471
|
+
title: f,
|
|
1472
|
+
getColumnName: l = Vr,
|
|
1473
|
+
getFieldHtml: g = Ir,
|
|
1474
|
+
getTitle: c = Lr,
|
|
1475
|
+
getValue: y = Nr
|
|
1476
|
+
}) {
|
|
1477
|
+
const h = f ? c(f) : "", M = a.reduce((v, E) => {
|
|
1478
|
+
const x = r[E], I = t[E], j = y(I, s, x), S = o ? l(E) : "";
|
|
1479
|
+
return v + g(S, j);
|
|
1480
|
+
}, "");
|
|
1481
|
+
return h + M;
|
|
1482
|
+
}
|
|
1483
|
+
function Lr(t) {
|
|
1484
|
+
return `<h3 style="margin: 0"><strong>${t}</strong></h3></br>`;
|
|
1485
|
+
}
|
|
1486
|
+
function Ir(t, r) {
|
|
1487
|
+
return `${t}${r}</br>`;
|
|
1488
|
+
}
|
|
1489
|
+
function Nr(t, r, a) {
|
|
1490
|
+
try {
|
|
1491
|
+
return Ur(a)(t, r);
|
|
1492
|
+
} catch {
|
|
1493
|
+
return t;
|
|
1494
|
+
}
|
|
1495
|
+
}
|
|
1496
|
+
function Ur(t) {
|
|
1497
|
+
return typeof t == "function" ? t : (t && Qe[t] || Qe[k.DEFAULT]).format;
|
|
1498
|
+
}
|
|
1499
|
+
function Vr(t) {
|
|
1500
|
+
return `<strong>${t}</strong>: `;
|
|
1513
1501
|
}
|
|
1514
1502
|
export {
|
|
1515
|
-
|
|
1503
|
+
Ke as CONVERSIONS_UNITS,
|
|
1516
1504
|
ye as CartoBasemapURL,
|
|
1517
|
-
|
|
1505
|
+
tr as CartoBasemapsNames,
|
|
1518
1506
|
fr as CustomEditableGeojsonLayer,
|
|
1519
1507
|
dr as CustomMeasureDistanceMode,
|
|
1520
1508
|
be as DEFAULT_COLORS,
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1525
|
-
|
|
1526
|
-
|
|
1509
|
+
cr as DEFAULT_LAYER_PROPS,
|
|
1510
|
+
ur as DEFAULT_PROPS,
|
|
1511
|
+
Je as EVENT_MANAGER_EVENT_TYPES,
|
|
1512
|
+
ce as EditType,
|
|
1513
|
+
k as FormatterTypes,
|
|
1514
|
+
er as GMapsBasemap,
|
|
1527
1515
|
lr as INTL_UNITS,
|
|
1528
1516
|
he as MAPS_BASEMAP,
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
|
|
1517
|
+
sr as MAP_MEASURE_LAYER_ID,
|
|
1518
|
+
F as MapActions,
|
|
1519
|
+
it as MapActionsContext,
|
|
1520
|
+
at as MapContext,
|
|
1533
1521
|
Xr as MapMeasurementTools,
|
|
1534
1522
|
Kr as MapMeasurementToolsLayer,
|
|
1535
1523
|
Qr as MapMeasurementToolsProvider,
|
|
1536
1524
|
C as MapMeasurementUnit,
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1525
|
+
ct as MapMeasurementUnitTurf,
|
|
1526
|
+
Zr as MapProvider,
|
|
1527
|
+
ot as MapReferencesContext,
|
|
1528
|
+
nt as MapsTypes,
|
|
1529
|
+
yt as convertMetersTo,
|
|
1530
|
+
Jr as getDeckController,
|
|
1542
1531
|
mr as getMapType,
|
|
1543
|
-
|
|
1532
|
+
ht as getTextLayerFormattedDistance,
|
|
1544
1533
|
pr as isGmaps,
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1534
|
+
en as objectToHtml,
|
|
1535
|
+
rr as reducer,
|
|
1536
|
+
st as useMap,
|
|
1537
|
+
nr as useMapActions,
|
|
1538
|
+
Gr as useMapActionsByID,
|
|
1539
|
+
zr as useMapByID,
|
|
1540
|
+
dt as useMapMeasurementTools,
|
|
1541
|
+
mt as useMapMeasurementToolsActions,
|
|
1553
1542
|
_e as useMapRefences,
|
|
1554
1543
|
_e as useMapReferences,
|
|
1555
|
-
|
|
1544
|
+
qr as useMapReferencesByID
|
|
1556
1545
|
};
|