@maptiler/sdk 3.5.1-rc5 → 3.6.0
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/maptiler-sdk.mjs
CHANGED
|
@@ -3,11 +3,11 @@ var fn = (r) => {
|
|
|
3
3
|
throw TypeError(r);
|
|
4
4
|
};
|
|
5
5
|
var Eo = (r, e, t) => e in r ? Ao(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t;
|
|
6
|
-
var S = (r, e, t) => Eo(r, typeof e != "symbol" ? e + "" : e, t),
|
|
7
|
-
var P = (r, e, t) => (
|
|
6
|
+
var S = (r, e, t) => Eo(r, typeof e != "symbol" ? e + "" : e, t), tr = (r, e, t) => e.has(r) || fn("Cannot " + t);
|
|
7
|
+
var P = (r, e, t) => (tr(r, e, "read from private field"), t ? t.call(r) : e.get(r)), be = (r, e, t) => e.has(r) ? fn("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(r) : e.set(r, t), _e = (r, e, t, n) => (tr(r, e, "write to private field"), n ? n.call(r, t) : e.set(r, t), t), H = (r, e, t) => (tr(r, e, "access private method"), t);
|
|
8
8
|
import k from "maplibre-gl";
|
|
9
|
-
import { Language as To, getLanguageInfoFromCode as dn, config as
|
|
10
|
-
import { MapStyle as Tp, MapStyleVariant as _p, ReferenceMapStyle as Ip, ServiceError as Mp, areSameLanguages as Pp, bufferToPixelDataBrowser as Rp, circumferenceAtLatitude as zp, coordinates as Fp, data as $p, elevation as Op, expandMapStyle as
|
|
9
|
+
import { Language as To, getLanguageInfoFromCode as dn, config as rr, MapStyle as Qe, mapStylePresetList as nr, expandMapStyle as _o, MapStyleVariant as Io, ReferenceMapStyle as Mo, toLanguageInfo as hn, getLanguageInfoFromFlag as Po, geolocation as yn } from "@maptiler/client";
|
|
10
|
+
import { MapStyle as Tp, MapStyleVariant as _p, ReferenceMapStyle as Ip, ServiceError as Mp, areSameLanguages as Pp, bufferToPixelDataBrowser as Rp, circumferenceAtLatitude as zp, coordinates as Fp, data as $p, elevation as Op, expandMapStyle as Np, geocoding as jp, geolocation as Dp, getAutoLanguage as Up, getBufferToPixelDataParser as Bp, getLanguageInfoFromCode as qp, getLanguageInfoFromFlag as Gp, getLanguageInfoFromKey as Vp, getTileCache as Hp, isLanguageInfo as Kp, mapStylePresetList as Xp, math as Zp, misc as Wp, staticMaps as Yp, styleToStyle as Jp, toLanguageInfo as Qp } from "@maptiler/client";
|
|
11
11
|
import Ro from "events";
|
|
12
12
|
import { v4 as zo } from "uuid";
|
|
13
13
|
import { Base64 as Fo } from "js-base64";
|
|
@@ -79,7 +79,7 @@ const V = {
|
|
|
79
79
|
terrainSourceId: "maptiler-terrain"
|
|
80
80
|
};
|
|
81
81
|
Object.freeze(V);
|
|
82
|
-
const
|
|
82
|
+
const Nr = zo();
|
|
83
83
|
class $o extends Ro {
|
|
84
84
|
constructor() {
|
|
85
85
|
super(...arguments);
|
|
@@ -149,7 +149,7 @@ class $o extends Ro {
|
|
|
149
149
|
* Set the MapTiler Cloud API key
|
|
150
150
|
*/
|
|
151
151
|
set apiKey(t) {
|
|
152
|
-
this._apiKey = t,
|
|
152
|
+
this._apiKey = t, rr.apiKey = t, this.emit("apiKey", t);
|
|
153
153
|
}
|
|
154
154
|
/**
|
|
155
155
|
* Get the MapTiler Cloud API key
|
|
@@ -161,16 +161,16 @@ class $o extends Ro {
|
|
|
161
161
|
* Set a the custom fetch function to replace the default one
|
|
162
162
|
*/
|
|
163
163
|
set fetch(t) {
|
|
164
|
-
|
|
164
|
+
rr.fetch = t;
|
|
165
165
|
}
|
|
166
166
|
/**
|
|
167
167
|
* Get the fetch fucntion
|
|
168
168
|
*/
|
|
169
169
|
get fetch() {
|
|
170
|
-
return
|
|
170
|
+
return rr.fetch;
|
|
171
171
|
}
|
|
172
172
|
}
|
|
173
|
-
const D = new $o(), Sr = "localcache_source", xr = "localcache", Oo = "maptiler_sdk",
|
|
173
|
+
const D = new $o(), Sr = "localcache_source", xr = "localcache", Oo = "maptiler_sdk", No = 1e3, jo = 100, kr = typeof caches < "u", { addProtocol: gn } = k;
|
|
174
174
|
function Do(r, e) {
|
|
175
175
|
if (kr && D.caching && D.session && r.host === V.maptilerApiHost) {
|
|
176
176
|
if (e === "Source" && r.href.includes("tiles.json"))
|
|
@@ -180,13 +180,13 @@ function Do(r, e) {
|
|
|
180
180
|
}
|
|
181
181
|
return r.href;
|
|
182
182
|
}
|
|
183
|
-
let
|
|
183
|
+
let ar;
|
|
184
184
|
async function fa() {
|
|
185
|
-
return
|
|
185
|
+
return ar || (ar = await caches.open(Oo)), ar;
|
|
186
186
|
}
|
|
187
187
|
let vn = 0;
|
|
188
188
|
async function Uo() {
|
|
189
|
-
const r = await fa(), e = await r.keys(), t = e.slice(0, Math.max(e.length -
|
|
189
|
+
const r = await fa(), e = await r.keys(), t = e.slice(0, Math.max(e.length - No, 0));
|
|
190
190
|
for (const n of t)
|
|
191
191
|
r.delete(n);
|
|
192
192
|
}
|
|
@@ -223,7 +223,7 @@ function Bo() {
|
|
|
223
223
|
c.signal = e.signal;
|
|
224
224
|
const p = await fetch(i, c);
|
|
225
225
|
return p.status >= 200 && p.status < 300 && (l.put(a, p.clone()).catch(() => {
|
|
226
|
-
}), ++vn >
|
|
226
|
+
}), ++vn > jo && (Uo(), vn = 0)), s(p);
|
|
227
227
|
});
|
|
228
228
|
}
|
|
229
229
|
function qo() {
|
|
@@ -248,7 +248,7 @@ function bn(r, e) {
|
|
|
248
248
|
url: r
|
|
249
249
|
};
|
|
250
250
|
}
|
|
251
|
-
return t.host === V.maptilerApiHost && (t.searchParams.has("key") || t.searchParams.append("key", D.apiKey), D.session && t.searchParams.append("mtsid",
|
|
251
|
+
return t.host === V.maptilerApiHost && (t.searchParams.has("key") || t.searchParams.append("key", D.apiKey), D.session && t.searchParams.append("mtsid", Nr)), {
|
|
252
252
|
url: Do(t, e)
|
|
253
253
|
};
|
|
254
254
|
}
|
|
@@ -267,7 +267,7 @@ function wn(r) {
|
|
|
267
267
|
function da() {
|
|
268
268
|
return Math.random().toString(36).substring(2);
|
|
269
269
|
}
|
|
270
|
-
function
|
|
270
|
+
function Ot(r) {
|
|
271
271
|
return /^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/gi.test(r);
|
|
272
272
|
}
|
|
273
273
|
function Vo(r) {
|
|
@@ -2476,7 +2476,7 @@ var ii = 8, si = {
|
|
|
2476
2476
|
},
|
|
2477
2477
|
"property-type": "color-ramp"
|
|
2478
2478
|
}
|
|
2479
|
-
},
|
|
2479
|
+
}, Ni = {
|
|
2480
2480
|
"circle-radius": {
|
|
2481
2481
|
type: "number",
|
|
2482
2482
|
default: 5,
|
|
@@ -2649,7 +2649,7 @@ var ii = 8, si = {
|
|
|
2649
2649
|
},
|
|
2650
2650
|
"property-type": "data-driven"
|
|
2651
2651
|
}
|
|
2652
|
-
},
|
|
2652
|
+
}, ji = {
|
|
2653
2653
|
"heatmap-radius": {
|
|
2654
2654
|
type: "number",
|
|
2655
2655
|
default: 30,
|
|
@@ -3516,8 +3516,8 @@ var ii = 8, si = {
|
|
|
3516
3516
|
}
|
|
3517
3517
|
},
|
|
3518
3518
|
paint_line: Oi,
|
|
3519
|
-
paint_circle:
|
|
3520
|
-
paint_heatmap:
|
|
3519
|
+
paint_circle: Ni,
|
|
3520
|
+
paint_heatmap: ji,
|
|
3521
3521
|
paint_symbol: Di,
|
|
3522
3522
|
paint_raster: Ui,
|
|
3523
3523
|
paint_hillshade: Bi,
|
|
@@ -3577,7 +3577,7 @@ class g {
|
|
|
3577
3577
|
this.message = (e ? `${e}: ` : "") + n, a && (this.identifier = a), t != null && t.__line__ && (this.line = t.__line__);
|
|
3578
3578
|
}
|
|
3579
3579
|
}
|
|
3580
|
-
function
|
|
3580
|
+
function Tt(r, ...e) {
|
|
3581
3581
|
for (const t of e)
|
|
3582
3582
|
for (const n in t)
|
|
3583
3583
|
r[n] = t[n];
|
|
@@ -3588,14 +3588,14 @@ class fe extends Error {
|
|
|
3588
3588
|
super(t), this.message = t, this.key = e;
|
|
3589
3589
|
}
|
|
3590
3590
|
}
|
|
3591
|
-
class
|
|
3591
|
+
class jr {
|
|
3592
3592
|
constructor(e, t = []) {
|
|
3593
3593
|
this.parent = e, this.bindings = {};
|
|
3594
3594
|
for (const [n, a] of t)
|
|
3595
3595
|
this.bindings[n] = a;
|
|
3596
3596
|
}
|
|
3597
3597
|
concat(e) {
|
|
3598
|
-
return new
|
|
3598
|
+
return new jr(this, e);
|
|
3599
3599
|
}
|
|
3600
3600
|
get(e) {
|
|
3601
3601
|
if (this.bindings[e])
|
|
@@ -3608,7 +3608,7 @@ class Nr {
|
|
|
3608
3608
|
return this.bindings[e] ? !0 : this.parent ? this.parent.has(e) : !1;
|
|
3609
3609
|
}
|
|
3610
3610
|
}
|
|
3611
|
-
const
|
|
3611
|
+
const Nt = { kind: "null" }, b = { kind: "number" }, I = { kind: "string" }, _ = { kind: "boolean" }, de = { kind: "color" }, jt = { kind: "projectionDefinition" }, Re = { kind: "object" }, T = { kind: "value" }, Ki = { kind: "error" }, Dt = { kind: "collator" }, Ut = { kind: "formatted" }, Bt = { kind: "padding" }, nt = { kind: "colorArray" }, qt = { kind: "numberArray" }, ft = { kind: "resolvedImage" }, Gt = { kind: "variableAnchorOffsetCollection" };
|
|
3612
3612
|
function W(r, e) {
|
|
3613
3613
|
return {
|
|
3614
3614
|
kind: "array",
|
|
@@ -3616,28 +3616,28 @@ function W(r, e) {
|
|
|
3616
3616
|
N: e
|
|
3617
3617
|
};
|
|
3618
3618
|
}
|
|
3619
|
-
function
|
|
3619
|
+
function N(r) {
|
|
3620
3620
|
if (r.kind === "array") {
|
|
3621
|
-
const e =
|
|
3621
|
+
const e = N(r.itemType);
|
|
3622
3622
|
return typeof r.N == "number" ? `array<${e}, ${r.N}>` : r.itemType.kind === "value" ? "array" : `array<${e}>`;
|
|
3623
3623
|
} else
|
|
3624
3624
|
return r.kind;
|
|
3625
3625
|
}
|
|
3626
3626
|
const Xi = [
|
|
3627
|
-
|
|
3628
|
-
|
|
3627
|
+
Nt,
|
|
3628
|
+
b,
|
|
3629
3629
|
I,
|
|
3630
3630
|
_,
|
|
3631
3631
|
de,
|
|
3632
3632
|
jt,
|
|
3633
|
-
|
|
3633
|
+
Ut,
|
|
3634
3634
|
Re,
|
|
3635
3635
|
W(T),
|
|
3636
|
-
Ut,
|
|
3637
3636
|
Bt,
|
|
3637
|
+
qt,
|
|
3638
3638
|
nt,
|
|
3639
3639
|
ft,
|
|
3640
|
-
|
|
3640
|
+
Gt
|
|
3641
3641
|
];
|
|
3642
3642
|
function at(r, e) {
|
|
3643
3643
|
if (e.kind === "error")
|
|
@@ -3654,7 +3654,7 @@ function at(r, e) {
|
|
|
3654
3654
|
return null;
|
|
3655
3655
|
}
|
|
3656
3656
|
}
|
|
3657
|
-
return `Expected ${
|
|
3657
|
+
return `Expected ${N(r)} but found ${N(e)} instead.`;
|
|
3658
3658
|
}
|
|
3659
3659
|
function Dr(r, e) {
|
|
3660
3660
|
return e.some((t) => t.kind === r.kind);
|
|
@@ -3670,33 +3670,33 @@ function ba(r) {
|
|
|
3670
3670
|
return r = r % 360, r < 0 && (r += 360), r;
|
|
3671
3671
|
}
|
|
3672
3672
|
function wa([r, e, t, n]) {
|
|
3673
|
-
r =
|
|
3673
|
+
r = or(r), e = or(e), t = or(t);
|
|
3674
3674
|
let a, o;
|
|
3675
|
-
const i =
|
|
3676
|
-
r === e && e === t ? a = o = i : (a =
|
|
3675
|
+
const i = ir((0.2225045 * r + 0.7168786 * e + 0.0606169 * t) / ya);
|
|
3676
|
+
r === e && e === t ? a = o = i : (a = ir((0.4360747 * r + 0.3850649 * e + 0.1430804 * t) / ha), o = ir((0.0139322 * r + 0.0971045 * e + 0.7141733 * t) / ma));
|
|
3677
3677
|
const s = 116 * i - 16;
|
|
3678
3678
|
return [s < 0 ? 0 : s, 500 * (a - i), 200 * (i - o), n];
|
|
3679
3679
|
}
|
|
3680
|
-
function
|
|
3680
|
+
function or(r) {
|
|
3681
3681
|
return r <= 0.04045 ? r / 12.92 : Math.pow((r + 0.055) / 1.055, 2.4);
|
|
3682
3682
|
}
|
|
3683
|
-
function
|
|
3683
|
+
function ir(r) {
|
|
3684
3684
|
return r > Zi ? Math.pow(r, 1 / 3) : r / va + ga;
|
|
3685
3685
|
}
|
|
3686
3686
|
function Sa([r, e, t, n]) {
|
|
3687
3687
|
let a = (r + 16) / 116, o = isNaN(e) ? a : a + e / 500, i = isNaN(t) ? a : a - t / 200;
|
|
3688
|
-
return a = ya *
|
|
3689
|
-
|
|
3688
|
+
return a = ya * lr(a), o = ha * lr(o), i = ma * lr(i), [
|
|
3689
|
+
sr(3.1338561 * o - 1.6168667 * a - 0.4906146 * i),
|
|
3690
3690
|
// D50 -> sRGB
|
|
3691
|
-
|
|
3692
|
-
|
|
3691
|
+
sr(-0.9787684 * o + 1.9161415 * a + 0.033454 * i),
|
|
3692
|
+
sr(0.0719453 * o - 0.2289914 * a + 1.4052427 * i),
|
|
3693
3693
|
n
|
|
3694
3694
|
];
|
|
3695
3695
|
}
|
|
3696
|
-
function
|
|
3696
|
+
function sr(r) {
|
|
3697
3697
|
return r = r <= 304e-5 ? 12.92 * r : 1.055 * Math.pow(r, 1 / 2.4) - 0.055, r < 0 ? 0 : r > 1 ? 1 : r;
|
|
3698
3698
|
}
|
|
3699
|
-
function
|
|
3699
|
+
function lr(r) {
|
|
3700
3700
|
return r > qe ? r * r * r : va * (r - ga);
|
|
3701
3701
|
}
|
|
3702
3702
|
function Ji(r) {
|
|
@@ -3764,7 +3764,7 @@ function rs(r) {
|
|
|
3764
3764
|
// ,|/ (optional)
|
|
3765
3765
|
m,
|
|
3766
3766
|
// <numeric> (optional)
|
|
3767
|
-
|
|
3767
|
+
w
|
|
3768
3768
|
// % (optional)
|
|
3769
3769
|
] = o, v = [u || " ", f || " ", y].join("");
|
|
3770
3770
|
if (v === " " || v === " /" || v === ",," || v === ",,,") {
|
|
@@ -3774,7 +3774,7 @@ function rs(r) {
|
|
|
3774
3774
|
Ue(+s / A, 0, 1),
|
|
3775
3775
|
Ue(+c / A, 0, 1),
|
|
3776
3776
|
Ue(+d / A, 0, 1),
|
|
3777
|
-
m ? kn(+m,
|
|
3777
|
+
m ? kn(+m, w) : 1
|
|
3778
3778
|
];
|
|
3779
3779
|
if (Cn(L))
|
|
3780
3780
|
return L;
|
|
@@ -4094,13 +4094,13 @@ class F {
|
|
|
4094
4094
|
let x = u - o;
|
|
4095
4095
|
u > o && x > 180 ? x -= 360 : u < o && o - u > 180 && (x += 360), d = o + n * x;
|
|
4096
4096
|
} else isNaN(o) ? isNaN(u) ? d = NaN : (d = u, (s === 1 || s === 0) && (h = c)) : (d = o, (p === 1 || p === 0) && (h = i));
|
|
4097
|
-
const [y, m,
|
|
4097
|
+
const [y, m, w, v] = Qi([
|
|
4098
4098
|
d,
|
|
4099
4099
|
h ?? Le(i, c, n),
|
|
4100
4100
|
Le(s, p, n),
|
|
4101
4101
|
Le(l, f, n)
|
|
4102
4102
|
]);
|
|
4103
|
-
return new F(y, m,
|
|
4103
|
+
return new F(y, m, w, v, !1);
|
|
4104
4104
|
}
|
|
4105
4105
|
case "lab": {
|
|
4106
4106
|
const [o, i, s, l] = Sa(Ve(e.lab, t.lab, n));
|
|
@@ -4255,7 +4255,7 @@ class X {
|
|
|
4255
4255
|
return new X(o);
|
|
4256
4256
|
}
|
|
4257
4257
|
}
|
|
4258
|
-
class
|
|
4258
|
+
class j extends Error {
|
|
4259
4259
|
constructor(e) {
|
|
4260
4260
|
super(e), this.name = "RuntimeError";
|
|
4261
4261
|
}
|
|
@@ -4286,11 +4286,11 @@ class ue {
|
|
|
4286
4286
|
static interpolate(e, t, n) {
|
|
4287
4287
|
const a = e.values, o = t.values;
|
|
4288
4288
|
if (a.length !== o.length)
|
|
4289
|
-
throw new
|
|
4289
|
+
throw new j(`Cannot interpolate values of different length. from: ${e.toString()}, to: ${t.toString()}`);
|
|
4290
4290
|
const i = [];
|
|
4291
4291
|
for (let s = 0; s < a.length; s += 2) {
|
|
4292
4292
|
if (a[s] !== o[s])
|
|
4293
|
-
throw new
|
|
4293
|
+
throw new j(`Cannot interpolate values containing mismatched anchors. from[${s}]: ${a[s]}, to[${s}]: ${o[s]}`);
|
|
4294
4294
|
i.push(a[s]);
|
|
4295
4295
|
const [l, u] = a[s + 1], [c, p] = o[s + 1];
|
|
4296
4296
|
i.push([Le(l, c, n), Le(u, p, n)]);
|
|
@@ -4348,29 +4348,29 @@ function ot(r) {
|
|
|
4348
4348
|
}
|
|
4349
4349
|
function B(r) {
|
|
4350
4350
|
if (r === null)
|
|
4351
|
-
return
|
|
4351
|
+
return Nt;
|
|
4352
4352
|
if (typeof r == "string")
|
|
4353
4353
|
return I;
|
|
4354
4354
|
if (typeof r == "boolean")
|
|
4355
4355
|
return _;
|
|
4356
4356
|
if (typeof r == "number")
|
|
4357
|
-
return
|
|
4357
|
+
return b;
|
|
4358
4358
|
if (r instanceof F)
|
|
4359
4359
|
return de;
|
|
4360
4360
|
if (r instanceof ie)
|
|
4361
4361
|
return jt;
|
|
4362
4362
|
if (r instanceof Ur)
|
|
4363
|
-
return Nt;
|
|
4364
|
-
if (r instanceof me)
|
|
4365
4363
|
return Dt;
|
|
4366
|
-
if (r instanceof
|
|
4364
|
+
if (r instanceof me)
|
|
4367
4365
|
return Ut;
|
|
4368
|
-
if (r instanceof
|
|
4366
|
+
if (r instanceof Q)
|
|
4369
4367
|
return Bt;
|
|
4368
|
+
if (r instanceof ee)
|
|
4369
|
+
return qt;
|
|
4370
4370
|
if (r instanceof X)
|
|
4371
4371
|
return nt;
|
|
4372
4372
|
if (r instanceof ue)
|
|
4373
|
-
return
|
|
4373
|
+
return Gt;
|
|
4374
4374
|
if (r instanceof Ee)
|
|
4375
4375
|
return ft;
|
|
4376
4376
|
if (Array.isArray(r)) {
|
|
@@ -4420,7 +4420,7 @@ class He {
|
|
|
4420
4420
|
}
|
|
4421
4421
|
const wt = {
|
|
4422
4422
|
string: I,
|
|
4423
|
-
number:
|
|
4423
|
+
number: b,
|
|
4424
4424
|
boolean: _,
|
|
4425
4425
|
object: Re
|
|
4426
4426
|
};
|
|
@@ -4468,7 +4468,7 @@ class se {
|
|
|
4468
4468
|
const n = this.args[t].evaluate(e);
|
|
4469
4469
|
if (at(this.type, B(n))) {
|
|
4470
4470
|
if (t === this.args.length - 1)
|
|
4471
|
-
throw new
|
|
4471
|
+
throw new j(`Expected value to be of type ${N(this.type)}, but found ${N(B(n))} instead.`);
|
|
4472
4472
|
} else return n;
|
|
4473
4473
|
}
|
|
4474
4474
|
throw new Error();
|
|
@@ -4483,7 +4483,7 @@ class se {
|
|
|
4483
4483
|
const Ln = {
|
|
4484
4484
|
"to-boolean": _,
|
|
4485
4485
|
"to-color": de,
|
|
4486
|
-
"to-number":
|
|
4486
|
+
"to-number": b,
|
|
4487
4487
|
"to-string": I
|
|
4488
4488
|
};
|
|
4489
4489
|
class ke {
|
|
@@ -4523,7 +4523,7 @@ class ke {
|
|
|
4523
4523
|
} else if (Array.isArray(t) && (t.length < 3 || t.length > 4 ? n = `Invalid rgba value ${JSON.stringify(t)}: expected an array containing either three or four numeric values.` : n = xa(t[0], t[1], t[2], t[3]), !n))
|
|
4524
4524
|
return new F(t[0] / 255, t[1] / 255, t[2] / 255, t[3]);
|
|
4525
4525
|
}
|
|
4526
|
-
throw new
|
|
4526
|
+
throw new j(n || `Could not parse color from value '${typeof t == "string" ? t : JSON.stringify(t)}'`);
|
|
4527
4527
|
}
|
|
4528
4528
|
case "padding": {
|
|
4529
4529
|
let t;
|
|
@@ -4533,7 +4533,7 @@ class ke {
|
|
|
4533
4533
|
if (a)
|
|
4534
4534
|
return a;
|
|
4535
4535
|
}
|
|
4536
|
-
throw new
|
|
4536
|
+
throw new j(`Could not parse padding from value '${typeof t == "string" ? t : JSON.stringify(t)}'`);
|
|
4537
4537
|
}
|
|
4538
4538
|
case "numberArray": {
|
|
4539
4539
|
let t;
|
|
@@ -4543,7 +4543,7 @@ class ke {
|
|
|
4543
4543
|
if (a)
|
|
4544
4544
|
return a;
|
|
4545
4545
|
}
|
|
4546
|
-
throw new
|
|
4546
|
+
throw new j(`Could not parse numberArray from value '${typeof t == "string" ? t : JSON.stringify(t)}'`);
|
|
4547
4547
|
}
|
|
4548
4548
|
case "colorArray": {
|
|
4549
4549
|
let t;
|
|
@@ -4553,7 +4553,7 @@ class ke {
|
|
|
4553
4553
|
if (a)
|
|
4554
4554
|
return a;
|
|
4555
4555
|
}
|
|
4556
|
-
throw new
|
|
4556
|
+
throw new j(`Could not parse colorArray from value '${typeof t == "string" ? t : JSON.stringify(t)}'`);
|
|
4557
4557
|
}
|
|
4558
4558
|
case "variableAnchorOffsetCollection": {
|
|
4559
4559
|
let t;
|
|
@@ -4563,7 +4563,7 @@ class ke {
|
|
|
4563
4563
|
if (a)
|
|
4564
4564
|
return a;
|
|
4565
4565
|
}
|
|
4566
|
-
throw new
|
|
4566
|
+
throw new j(`Could not parse variableAnchorOffsetCollection from value '${typeof t == "string" ? t : JSON.stringify(t)}'`);
|
|
4567
4567
|
}
|
|
4568
4568
|
case "number": {
|
|
4569
4569
|
let t = null;
|
|
@@ -4574,7 +4574,7 @@ class ke {
|
|
|
4574
4574
|
if (!isNaN(a))
|
|
4575
4575
|
return a;
|
|
4576
4576
|
}
|
|
4577
|
-
throw new
|
|
4577
|
+
throw new j(`Could not convert ${JSON.stringify(t)} to number.`);
|
|
4578
4578
|
}
|
|
4579
4579
|
case "formatted":
|
|
4580
4580
|
return me.fromString(tt(this.args[0].evaluate(e)));
|
|
@@ -4618,8 +4618,8 @@ class ka {
|
|
|
4618
4618
|
return t || (t = F.parse(e), this._parseColorCache.set(e, t)), t;
|
|
4619
4619
|
}
|
|
4620
4620
|
}
|
|
4621
|
-
class
|
|
4622
|
-
constructor(e, t, n = [], a, o = new
|
|
4621
|
+
class Vt {
|
|
4622
|
+
constructor(e, t, n = [], a, o = new jr(), i = []) {
|
|
4623
4623
|
this.registry = e, this.path = n, this.key = n.map((s) => `[${s}]`).join(""), this.scope = o, this.errors = i, this.expectedType = a, this._isConstant = t;
|
|
4624
4624
|
}
|
|
4625
4625
|
/**
|
|
@@ -4680,7 +4680,7 @@ class Gt {
|
|
|
4680
4680
|
*/
|
|
4681
4681
|
concat(e, t, n) {
|
|
4682
4682
|
const a = typeof e == "number" ? this.path.concat(e) : this.path, o = n ? this.scope.concat(n) : this.scope;
|
|
4683
|
-
return new
|
|
4683
|
+
return new Vt(this.registry, this._isConstant, a, t || null, o, this.errors);
|
|
4684
4684
|
}
|
|
4685
4685
|
/**
|
|
4686
4686
|
* Push a parsing (or type checking) error into the `this.errors`
|
|
@@ -4705,7 +4705,7 @@ class Gt {
|
|
|
4705
4705
|
return n && this.error(n), n;
|
|
4706
4706
|
}
|
|
4707
4707
|
}
|
|
4708
|
-
class
|
|
4708
|
+
class Ht {
|
|
4709
4709
|
constructor(e, t) {
|
|
4710
4710
|
this.type = t.type, this.bindings = [].concat(e), this.result = t;
|
|
4711
4711
|
}
|
|
@@ -4733,13 +4733,13 @@ class Vt {
|
|
|
4733
4733
|
n.push([i, s]);
|
|
4734
4734
|
}
|
|
4735
4735
|
const a = t.parse(e[e.length - 1], e.length - 1, t.expectedType, n);
|
|
4736
|
-
return a ? new
|
|
4736
|
+
return a ? new Ht(n, a) : null;
|
|
4737
4737
|
}
|
|
4738
4738
|
outputDefined() {
|
|
4739
4739
|
return this.result.outputDefined();
|
|
4740
4740
|
}
|
|
4741
4741
|
}
|
|
4742
|
-
class
|
|
4742
|
+
class Kt {
|
|
4743
4743
|
constructor(e, t) {
|
|
4744
4744
|
this.type = t.type, this.name = e, this.boundExpression = t;
|
|
4745
4745
|
}
|
|
@@ -4747,7 +4747,7 @@ class Ht {
|
|
|
4747
4747
|
if (e.length !== 2 || typeof e[1] != "string")
|
|
4748
4748
|
return t.error("'var' expression requires exactly one string literal argument.");
|
|
4749
4749
|
const n = e[1];
|
|
4750
|
-
return t.scope.has(n) ? new
|
|
4750
|
+
return t.scope.has(n) ? new Kt(n, t.scope.get(n)) : t.error(`Unknown variable "${n}". Make sure "${n}" has been bound in an enclosing "let" expression before using it.`, 1);
|
|
4751
4751
|
}
|
|
4752
4752
|
evaluate(e) {
|
|
4753
4753
|
return this.boundExpression.evaluate(e);
|
|
@@ -4765,7 +4765,7 @@ class Br {
|
|
|
4765
4765
|
static parse(e, t) {
|
|
4766
4766
|
if (e.length !== 3)
|
|
4767
4767
|
return t.error(`Expected 2 arguments, but found ${e.length - 1} instead.`);
|
|
4768
|
-
const n = t.parse(e[1], 1,
|
|
4768
|
+
const n = t.parse(e[1], 1, b), a = t.parse(e[2], 2, W(t.expectedType || T));
|
|
4769
4769
|
if (!n || !a)
|
|
4770
4770
|
return null;
|
|
4771
4771
|
const o = a.type;
|
|
@@ -4774,11 +4774,11 @@ class Br {
|
|
|
4774
4774
|
evaluate(e) {
|
|
4775
4775
|
const t = this.index.evaluate(e), n = this.input.evaluate(e);
|
|
4776
4776
|
if (t < 0)
|
|
4777
|
-
throw new
|
|
4777
|
+
throw new j(`Array index out of bounds: ${t} < 0.`);
|
|
4778
4778
|
if (t >= n.length)
|
|
4779
|
-
throw new
|
|
4779
|
+
throw new j(`Array index out of bounds: ${t} > ${n.length - 1}.`);
|
|
4780
4780
|
if (t !== Math.floor(t))
|
|
4781
|
-
throw new
|
|
4781
|
+
throw new j(`Array index must be an integer, but found ${t} instead.`);
|
|
4782
4782
|
return n[t];
|
|
4783
4783
|
}
|
|
4784
4784
|
eachChild(e) {
|
|
@@ -4796,16 +4796,16 @@ class qr {
|
|
|
4796
4796
|
if (e.length !== 3)
|
|
4797
4797
|
return t.error(`Expected 2 arguments, but found ${e.length - 1} instead.`);
|
|
4798
4798
|
const n = t.parse(e[1], 1, T), a = t.parse(e[2], 2, T);
|
|
4799
|
-
return !n || !a ? null : Dr(n.type, [_, I,
|
|
4799
|
+
return !n || !a ? null : Dr(n.type, [_, I, b, Nt, T]) ? new qr(n, a) : t.error(`Expected first argument to be of type boolean, string, number or null, but found ${N(n.type)} instead`);
|
|
4800
4800
|
}
|
|
4801
4801
|
evaluate(e) {
|
|
4802
4802
|
const t = this.needle.evaluate(e), n = this.haystack.evaluate(e);
|
|
4803
4803
|
if (!n)
|
|
4804
4804
|
return !1;
|
|
4805
4805
|
if (!ze(t, ["boolean", "string", "number", "null"]))
|
|
4806
|
-
throw new
|
|
4806
|
+
throw new j(`Expected first argument to be of type boolean, string, number or null, but found ${N(B(t))} instead.`);
|
|
4807
4807
|
if (!ze(n, ["string", "array"]))
|
|
4808
|
-
throw new
|
|
4808
|
+
throw new j(`Expected second argument to be of type array or string, but found ${N(B(n))} instead.`);
|
|
4809
4809
|
return n.indexOf(t) >= 0;
|
|
4810
4810
|
}
|
|
4811
4811
|
eachChild(e) {
|
|
@@ -4815,9 +4815,9 @@ class qr {
|
|
|
4815
4815
|
return !0;
|
|
4816
4816
|
}
|
|
4817
4817
|
}
|
|
4818
|
-
class
|
|
4818
|
+
class _t {
|
|
4819
4819
|
constructor(e, t, n) {
|
|
4820
|
-
this.type =
|
|
4820
|
+
this.type = b, this.needle = e, this.haystack = t, this.fromIndex = n;
|
|
4821
4821
|
}
|
|
4822
4822
|
static parse(e, t) {
|
|
4823
4823
|
if (e.length <= 2 || e.length >= 5)
|
|
@@ -4825,18 +4825,18 @@ class Tt {
|
|
|
4825
4825
|
const n = t.parse(e[1], 1, T), a = t.parse(e[2], 2, T);
|
|
4826
4826
|
if (!n || !a)
|
|
4827
4827
|
return null;
|
|
4828
|
-
if (!Dr(n.type, [_, I,
|
|
4829
|
-
return t.error(`Expected first argument to be of type boolean, string, number or null, but found ${
|
|
4828
|
+
if (!Dr(n.type, [_, I, b, Nt, T]))
|
|
4829
|
+
return t.error(`Expected first argument to be of type boolean, string, number or null, but found ${N(n.type)} instead`);
|
|
4830
4830
|
if (e.length === 4) {
|
|
4831
|
-
const o = t.parse(e[3], 3,
|
|
4832
|
-
return o ? new
|
|
4831
|
+
const o = t.parse(e[3], 3, b);
|
|
4832
|
+
return o ? new _t(n, a, o) : null;
|
|
4833
4833
|
} else
|
|
4834
|
-
return new
|
|
4834
|
+
return new _t(n, a);
|
|
4835
4835
|
}
|
|
4836
4836
|
evaluate(e) {
|
|
4837
4837
|
const t = this.needle.evaluate(e), n = this.haystack.evaluate(e);
|
|
4838
4838
|
if (!ze(t, ["boolean", "string", "number", "null"]))
|
|
4839
|
-
throw new
|
|
4839
|
+
throw new j(`Expected first argument to be of type boolean, string, number or null, but found ${N(B(t))} instead.`);
|
|
4840
4840
|
let a;
|
|
4841
4841
|
if (this.fromIndex && (a = this.fromIndex.evaluate(e)), ze(n, ["string"])) {
|
|
4842
4842
|
const o = n.indexOf(t, a);
|
|
@@ -4844,7 +4844,7 @@ class Tt {
|
|
|
4844
4844
|
} else {
|
|
4845
4845
|
if (ze(n, ["array"]))
|
|
4846
4846
|
return n.indexOf(t, a);
|
|
4847
|
-
throw new
|
|
4847
|
+
throw new j(`Expected second argument to be of type array or string, but found ${N(B(n))} instead.`);
|
|
4848
4848
|
}
|
|
4849
4849
|
}
|
|
4850
4850
|
eachChild(e) {
|
|
@@ -4953,23 +4953,23 @@ class Vr {
|
|
|
4953
4953
|
return this.branches.every(([e, t]) => t.outputDefined()) && this.otherwise.outputDefined();
|
|
4954
4954
|
}
|
|
4955
4955
|
}
|
|
4956
|
-
class
|
|
4956
|
+
class It {
|
|
4957
4957
|
constructor(e, t, n, a) {
|
|
4958
4958
|
this.type = e, this.input = t, this.beginIndex = n, this.endIndex = a;
|
|
4959
4959
|
}
|
|
4960
4960
|
static parse(e, t) {
|
|
4961
4961
|
if (e.length <= 2 || e.length >= 5)
|
|
4962
4962
|
return t.error(`Expected 3 or 4 arguments, but found ${e.length - 1} instead.`);
|
|
4963
|
-
const n = t.parse(e[1], 1, T), a = t.parse(e[2], 2,
|
|
4963
|
+
const n = t.parse(e[1], 1, T), a = t.parse(e[2], 2, b);
|
|
4964
4964
|
if (!n || !a)
|
|
4965
4965
|
return null;
|
|
4966
4966
|
if (!Dr(n.type, [W(T), I, T]))
|
|
4967
|
-
return t.error(`Expected first argument to be of type array or string, but found ${
|
|
4967
|
+
return t.error(`Expected first argument to be of type array or string, but found ${N(n.type)} instead`);
|
|
4968
4968
|
if (e.length === 4) {
|
|
4969
|
-
const o = t.parse(e[3], 3,
|
|
4970
|
-
return o ? new
|
|
4969
|
+
const o = t.parse(e[3], 3, b);
|
|
4970
|
+
return o ? new It(n.type, n, a, o) : null;
|
|
4971
4971
|
} else
|
|
4972
|
-
return new
|
|
4972
|
+
return new It(n.type, n, a);
|
|
4973
4973
|
}
|
|
4974
4974
|
evaluate(e) {
|
|
4975
4975
|
const t = this.input.evaluate(e), n = this.beginIndex.evaluate(e);
|
|
@@ -4978,7 +4978,7 @@ class _t {
|
|
|
4978
4978
|
return [...t].slice(n, a).join("");
|
|
4979
4979
|
if (ze(t, ["array"]))
|
|
4980
4980
|
return t.slice(n, a);
|
|
4981
|
-
throw new
|
|
4981
|
+
throw new j(`Expected first argument to be of type array or string, but found ${N(B(t))} instead.`);
|
|
4982
4982
|
}
|
|
4983
4983
|
eachChild(e) {
|
|
4984
4984
|
e(this.input), e(this.beginIndex), this.endIndex && e(this.endIndex);
|
|
@@ -4998,10 +4998,10 @@ function Ca(r, e) {
|
|
|
4998
4998
|
} else if (i > e)
|
|
4999
4999
|
a = o - 1;
|
|
5000
5000
|
else
|
|
5001
|
-
throw new
|
|
5001
|
+
throw new j("Input is not a number.");
|
|
5002
5002
|
return 0;
|
|
5003
5003
|
}
|
|
5004
|
-
class
|
|
5004
|
+
class Xt {
|
|
5005
5005
|
constructor(e, t, n) {
|
|
5006
5006
|
this.type = e, this.input = t, this.labels = [], this.outputs = [];
|
|
5007
5007
|
for (const [a, o] of n)
|
|
@@ -5012,7 +5012,7 @@ class Kt {
|
|
|
5012
5012
|
return t.error(`Expected at least 4 arguments, but found only ${e.length - 1}.`);
|
|
5013
5013
|
if ((e.length - 1) % 2 !== 0)
|
|
5014
5014
|
return t.error("Expected an even number of arguments.");
|
|
5015
|
-
const n = t.parse(e[1], 1,
|
|
5015
|
+
const n = t.parse(e[1], 1, b);
|
|
5016
5016
|
if (!n)
|
|
5017
5017
|
return null;
|
|
5018
5018
|
const a = [];
|
|
@@ -5029,7 +5029,7 @@ class Kt {
|
|
|
5029
5029
|
return null;
|
|
5030
5030
|
o = o || p.type, a.push([s, p]);
|
|
5031
5031
|
}
|
|
5032
|
-
return new
|
|
5032
|
+
return new Xt(o, n, a);
|
|
5033
5033
|
}
|
|
5034
5034
|
evaluate(e) {
|
|
5035
5035
|
const t = this.labels, n = this.outputs;
|
|
@@ -5056,10 +5056,10 @@ class Kt {
|
|
|
5056
5056
|
function ss(r) {
|
|
5057
5057
|
return r && r.__esModule && Object.prototype.hasOwnProperty.call(r, "default") ? r.default : r;
|
|
5058
5058
|
}
|
|
5059
|
-
var
|
|
5059
|
+
var ur, An;
|
|
5060
5060
|
function ls() {
|
|
5061
|
-
if (An) return
|
|
5062
|
-
An = 1,
|
|
5061
|
+
if (An) return ur;
|
|
5062
|
+
An = 1, ur = r;
|
|
5063
5063
|
function r(e, t, n, a) {
|
|
5064
5064
|
this.cx = 3 * e, this.bx = 3 * (n - e) - this.cx, this.ax = 1 - this.cx - this.bx, this.cy = 3 * t, this.by = 3 * (a - t) - this.cy, this.ay = 1 - this.cy - this.by, this.p1x = e, this.p1y = t, this.p2x = n, this.p2y = a;
|
|
5065
5065
|
}
|
|
@@ -5091,7 +5091,7 @@ function ls() {
|
|
|
5091
5091
|
solve: function(e, t) {
|
|
5092
5092
|
return this.sampleCurveY(this.solveCurveX(e, t));
|
|
5093
5093
|
}
|
|
5094
|
-
},
|
|
5094
|
+
}, ur;
|
|
5095
5095
|
}
|
|
5096
5096
|
var us = ls(), cs = /* @__PURE__ */ ss(us);
|
|
5097
5097
|
class he {
|
|
@@ -5103,12 +5103,12 @@ class he {
|
|
|
5103
5103
|
static interpolationFactor(e, t, n, a) {
|
|
5104
5104
|
let o = 0;
|
|
5105
5105
|
if (e.name === "exponential")
|
|
5106
|
-
o =
|
|
5106
|
+
o = cr(t, e.base, n, a);
|
|
5107
5107
|
else if (e.name === "linear")
|
|
5108
|
-
o =
|
|
5108
|
+
o = cr(t, 1, n, a);
|
|
5109
5109
|
else if (e.name === "cubic-bezier") {
|
|
5110
5110
|
const i = e.controlPoints;
|
|
5111
|
-
o = new cs(i[0], i[1], i[2], i[3]).solve(
|
|
5111
|
+
o = new cs(i[0], i[1], i[2], i[3]).solve(cr(t, 1, n, a));
|
|
5112
5112
|
}
|
|
5113
5113
|
return o;
|
|
5114
5114
|
}
|
|
@@ -5140,7 +5140,7 @@ class he {
|
|
|
5140
5140
|
return t.error(`Expected at least 4 arguments, but found only ${e.length - 1}.`);
|
|
5141
5141
|
if ((e.length - 1) % 2 !== 0)
|
|
5142
5142
|
return t.error("Expected an even number of arguments.");
|
|
5143
|
-
if (o = t.parse(o, 2,
|
|
5143
|
+
if (o = t.parse(o, 2, b), !o)
|
|
5144
5144
|
return null;
|
|
5145
5145
|
const s = [];
|
|
5146
5146
|
let l = null;
|
|
@@ -5156,7 +5156,7 @@ class he {
|
|
|
5156
5156
|
return null;
|
|
5157
5157
|
l = l || h.type, s.push([c, h]);
|
|
5158
5158
|
}
|
|
5159
|
-
return !we(l,
|
|
5159
|
+
return !we(l, b) && !we(l, jt) && !we(l, de) && !we(l, Bt) && !we(l, qt) && !we(l, nt) && !we(l, Gt) && !we(l, W(b)) ? t.error(`Type ${N(l)} is not interpolatable.`) : new he(l, n, a, o, s);
|
|
5160
5160
|
}
|
|
5161
5161
|
evaluate(e) {
|
|
5162
5162
|
const t = this.labels, n = this.outputs;
|
|
@@ -5214,7 +5214,7 @@ class he {
|
|
|
5214
5214
|
return this.outputs.every((e) => e.outputDefined());
|
|
5215
5215
|
}
|
|
5216
5216
|
}
|
|
5217
|
-
function
|
|
5217
|
+
function cr(r, e, t, n) {
|
|
5218
5218
|
const a = n - t, o = r - t;
|
|
5219
5219
|
return a === 0 ? 0 : e === 1 ? o / a : (Math.pow(e, o) - 1) / (Math.pow(e, a) - 1);
|
|
5220
5220
|
}
|
|
@@ -5307,20 +5307,20 @@ function Xe(r, e, t) {
|
|
|
5307
5307
|
if (!l)
|
|
5308
5308
|
return null;
|
|
5309
5309
|
if (!En(s, l.type))
|
|
5310
|
-
return i.concat(1).error(`"${s}" comparisons are not supported for type '${
|
|
5310
|
+
return i.concat(1).error(`"${s}" comparisons are not supported for type '${N(l.type)}'.`);
|
|
5311
5311
|
let u = i.parse(o[2], 2, T);
|
|
5312
5312
|
if (!u)
|
|
5313
5313
|
return null;
|
|
5314
5314
|
if (!En(s, u.type))
|
|
5315
|
-
return i.concat(2).error(`"${s}" comparisons are not supported for type '${
|
|
5315
|
+
return i.concat(2).error(`"${s}" comparisons are not supported for type '${N(u.type)}'.`);
|
|
5316
5316
|
if (l.type.kind !== u.type.kind && l.type.kind !== "value" && u.type.kind !== "value")
|
|
5317
|
-
return i.error(`Cannot compare types '${
|
|
5317
|
+
return i.error(`Cannot compare types '${N(l.type)}' and '${N(u.type)}'.`);
|
|
5318
5318
|
n && (l.type.kind === "value" && u.type.kind !== "value" ? l = new se(u.type, [l]) : l.type.kind !== "value" && u.type.kind === "value" && (u = new se(l.type, [u])));
|
|
5319
5319
|
let c = null;
|
|
5320
5320
|
if (o.length === 4) {
|
|
5321
5321
|
if (l.type.kind !== "string" && u.type.kind !== "string" && l.type.kind !== "value" && u.type.kind !== "value")
|
|
5322
5322
|
return i.error("Cannot use collator to compare non-string types.");
|
|
5323
|
-
if (c = i.parse(o[3], 3,
|
|
5323
|
+
if (c = i.parse(o[3], 3, Dt), !c)
|
|
5324
5324
|
return null;
|
|
5325
5325
|
}
|
|
5326
5326
|
return new Aa(l, u, c);
|
|
@@ -5330,7 +5330,7 @@ function Xe(r, e, t) {
|
|
|
5330
5330
|
if (n && this.hasUntypedArgument) {
|
|
5331
5331
|
const l = B(i), u = B(s);
|
|
5332
5332
|
if (l.kind !== u.kind || !(l.kind === "string" || l.kind === "number"))
|
|
5333
|
-
throw new
|
|
5333
|
+
throw new j(`Expected arguments for "${r}" to be (string, string) or (number, number), but found (${l.kind}, ${u.kind}) instead.`);
|
|
5334
5334
|
}
|
|
5335
5335
|
if (this.collator && !n && this.hasUntypedArgument) {
|
|
5336
5336
|
const l = B(i), u = B(s);
|
|
@@ -5348,9 +5348,9 @@ function Xe(r, e, t) {
|
|
|
5348
5348
|
};
|
|
5349
5349
|
}
|
|
5350
5350
|
const xs = Xe("==", ps, La), ks = Xe("!=", fs, gs), Cs = Xe("<", ds, vs), Ls = Xe(">", hs, bs), As = Xe("<=", ys, ws), Es = Xe(">=", ms, Ss);
|
|
5351
|
-
class
|
|
5351
|
+
class Zt {
|
|
5352
5352
|
constructor(e, t, n) {
|
|
5353
|
-
this.type =
|
|
5353
|
+
this.type = Dt, this.locale = n, this.caseSensitive = e, this.diacriticSensitive = t;
|
|
5354
5354
|
}
|
|
5355
5355
|
static parse(e, t) {
|
|
5356
5356
|
if (e.length !== 2)
|
|
@@ -5365,7 +5365,7 @@ class Xt {
|
|
|
5365
5365
|
if (!o)
|
|
5366
5366
|
return null;
|
|
5367
5367
|
let i = null;
|
|
5368
|
-
return n.locale && (i = t.parse(n.locale, 1, I), !i) ? null : new
|
|
5368
|
+
return n.locale && (i = t.parse(n.locale, 1, I), !i) ? null : new Zt(a, o, i);
|
|
5369
5369
|
}
|
|
5370
5370
|
evaluate(e) {
|
|
5371
5371
|
return new Ur(this.caseSensitive.evaluate(e), this.diacriticSensitive.evaluate(e), this.locale ? this.locale.evaluate(e) : null);
|
|
@@ -5384,7 +5384,7 @@ class Hr {
|
|
|
5384
5384
|
static parse(e, t) {
|
|
5385
5385
|
if (e.length !== 3)
|
|
5386
5386
|
return t.error("Expected two arguments.");
|
|
5387
|
-
const n = t.parse(e[1], 1,
|
|
5387
|
+
const n = t.parse(e[1], 1, b);
|
|
5388
5388
|
if (!n)
|
|
5389
5389
|
return null;
|
|
5390
5390
|
const a = e[2];
|
|
@@ -5397,10 +5397,10 @@ class Hr {
|
|
|
5397
5397
|
if (a.currency && (i = t.parse(a.currency, 1, I), !i))
|
|
5398
5398
|
return null;
|
|
5399
5399
|
let s = null;
|
|
5400
|
-
if (a["min-fraction-digits"] && (s = t.parse(a["min-fraction-digits"], 1,
|
|
5400
|
+
if (a["min-fraction-digits"] && (s = t.parse(a["min-fraction-digits"], 1, b), !s))
|
|
5401
5401
|
return null;
|
|
5402
5402
|
let l = null;
|
|
5403
|
-
return a["max-fraction-digits"] && (l = t.parse(a["max-fraction-digits"], 1,
|
|
5403
|
+
return a["max-fraction-digits"] && (l = t.parse(a["max-fraction-digits"], 1, b), !l) ? null : new Hr(n, o, i, s, l);
|
|
5404
5404
|
}
|
|
5405
5405
|
evaluate(e) {
|
|
5406
5406
|
return new Intl.NumberFormat(this.locale ? this.locale.evaluate(e) : [], {
|
|
@@ -5419,7 +5419,7 @@ class Hr {
|
|
|
5419
5419
|
}
|
|
5420
5420
|
class Kr {
|
|
5421
5421
|
constructor(e) {
|
|
5422
|
-
this.type =
|
|
5422
|
+
this.type = Ut, this.sections = e;
|
|
5423
5423
|
}
|
|
5424
5424
|
static parse(e, t) {
|
|
5425
5425
|
if (e.length < 2)
|
|
@@ -5434,7 +5434,7 @@ class Kr {
|
|
|
5434
5434
|
if (o && typeof s == "object" && !Array.isArray(s)) {
|
|
5435
5435
|
o = !1;
|
|
5436
5436
|
let l = null;
|
|
5437
|
-
if (s["font-scale"] && (l = t.parse(s["font-scale"], 1,
|
|
5437
|
+
if (s["font-scale"] && (l = t.parse(s["font-scale"], 1, b), !l))
|
|
5438
5438
|
return null;
|
|
5439
5439
|
let u = null;
|
|
5440
5440
|
if (s["text-font"] && (u = t.parse(s["text-font"], 1, W(I)), !u))
|
|
@@ -5501,13 +5501,13 @@ class Xr {
|
|
|
5501
5501
|
}
|
|
5502
5502
|
class Zr {
|
|
5503
5503
|
constructor(e) {
|
|
5504
|
-
this.type =
|
|
5504
|
+
this.type = b, this.input = e;
|
|
5505
5505
|
}
|
|
5506
5506
|
static parse(e, t) {
|
|
5507
5507
|
if (e.length !== 2)
|
|
5508
5508
|
return t.error(`Expected 1 argument, but found ${e.length - 1} instead.`);
|
|
5509
5509
|
const n = t.parse(e[1], 1);
|
|
5510
|
-
return n ? n.type.kind !== "array" && n.type.kind !== "string" && n.type.kind !== "value" ? t.error(`Expected argument of type string or array, but found ${
|
|
5510
|
+
return n ? n.type.kind !== "array" && n.type.kind !== "string" && n.type.kind !== "value" ? t.error(`Expected argument of type string or array, but found ${N(n.type)} instead.`) : new Zr(n) : null;
|
|
5511
5511
|
}
|
|
5512
5512
|
evaluate(e) {
|
|
5513
5513
|
const t = this.input.evaluate(e);
|
|
@@ -5515,7 +5515,7 @@ class Zr {
|
|
|
5515
5515
|
return [...t].length;
|
|
5516
5516
|
if (Array.isArray(t))
|
|
5517
5517
|
return t.length;
|
|
5518
|
-
throw new
|
|
5518
|
+
throw new j(`Expected value to be of type string or array, but found ${N(B(t))} instead.`);
|
|
5519
5519
|
}
|
|
5520
5520
|
eachChild(e) {
|
|
5521
5521
|
e(this.input);
|
|
@@ -5558,14 +5558,14 @@ function zs(r, e, t) {
|
|
|
5558
5558
|
const n = r[0] - e[0], a = r[1] - e[1], o = r[0] - t[0], i = r[1] - t[1];
|
|
5559
5559
|
return n * i - o * a === 0 && n * o <= 0 && a * i <= 0;
|
|
5560
5560
|
}
|
|
5561
|
-
function
|
|
5561
|
+
function Wt(r, e, t, n) {
|
|
5562
5562
|
const a = [e[0] - r[0], e[1] - r[1]], o = [n[0] - t[0], n[1] - t[1]];
|
|
5563
|
-
return
|
|
5563
|
+
return Ns(o, a) === 0 ? !1 : !!(Tn(r, e, t, n) && Tn(t, n, r, e));
|
|
5564
5564
|
}
|
|
5565
5565
|
function Fs(r, e, t) {
|
|
5566
5566
|
for (const n of t)
|
|
5567
5567
|
for (let a = 0; a < n.length - 1; ++a)
|
|
5568
|
-
if (
|
|
5568
|
+
if (Wt(r, e, n[a], n[a + 1]))
|
|
5569
5569
|
return !0;
|
|
5570
5570
|
return !1;
|
|
5571
5571
|
}
|
|
@@ -5600,7 +5600,7 @@ function Os(r, e) {
|
|
|
5600
5600
|
return !0;
|
|
5601
5601
|
return !1;
|
|
5602
5602
|
}
|
|
5603
|
-
function
|
|
5603
|
+
function Ns(r, e) {
|
|
5604
5604
|
return r[0] * e[1] - r[1] * e[0];
|
|
5605
5605
|
}
|
|
5606
5606
|
function Tn(r, e, t, n) {
|
|
@@ -5635,7 +5635,7 @@ function _a(r, e, t, n) {
|
|
|
5635
5635
|
}
|
|
5636
5636
|
dt(e, r);
|
|
5637
5637
|
}
|
|
5638
|
-
function
|
|
5638
|
+
function js(r) {
|
|
5639
5639
|
r[0] = r[1] = 1 / 0, r[2] = r[3] = -1 / 0;
|
|
5640
5640
|
}
|
|
5641
5641
|
function _n(r, e, t, n) {
|
|
@@ -5658,7 +5658,7 @@ function In(r, e, t, n) {
|
|
|
5658
5658
|
i.push(l);
|
|
5659
5659
|
}
|
|
5660
5660
|
if (e[2] - e[0] <= a / 2) {
|
|
5661
|
-
|
|
5661
|
+
js(e);
|
|
5662
5662
|
for (const s of i)
|
|
5663
5663
|
for (const l of s)
|
|
5664
5664
|
_a(l, e, t, a);
|
|
@@ -5862,7 +5862,7 @@ const Lr = 100, Ar = 50;
|
|
|
5862
5862
|
function Ma(r, e) {
|
|
5863
5863
|
return e[0] - r[0];
|
|
5864
5864
|
}
|
|
5865
|
-
function
|
|
5865
|
+
function Mt(r) {
|
|
5866
5866
|
return r[1] - r[0] + 1;
|
|
5867
5867
|
}
|
|
5868
5868
|
function ve(r, e) {
|
|
@@ -5871,7 +5871,7 @@ function ve(r, e) {
|
|
|
5871
5871
|
function Er(r, e) {
|
|
5872
5872
|
if (r[0] > r[1])
|
|
5873
5873
|
return [null, null];
|
|
5874
|
-
const t =
|
|
5874
|
+
const t = Mt(r);
|
|
5875
5875
|
if (e) {
|
|
5876
5876
|
if (t === 2)
|
|
5877
5877
|
return [r, null];
|
|
@@ -5929,7 +5929,7 @@ function Vs(r, e, t, n, a) {
|
|
|
5929
5929
|
const l = r[s], u = r[s + 1];
|
|
5930
5930
|
for (let c = n[0]; c < n[1]; ++c) {
|
|
5931
5931
|
const p = t[c], f = t[c + 1];
|
|
5932
|
-
if (
|
|
5932
|
+
if (Wt(l, u, p, f))
|
|
5933
5933
|
return 0;
|
|
5934
5934
|
i = Math.min(i, en(l, u, p, f, a));
|
|
5935
5935
|
}
|
|
@@ -5972,7 +5972,7 @@ function Xs(r, e, t, n) {
|
|
|
5972
5972
|
for (const l of t)
|
|
5973
5973
|
for (let u = 0, c = l.length, p = c - 1; u < c; p = u++) {
|
|
5974
5974
|
const f = l[p], d = l[u];
|
|
5975
|
-
if (
|
|
5975
|
+
if (Wt(i, s, f, d))
|
|
5976
5976
|
return 0;
|
|
5977
5977
|
a = Math.min(a, en(i, s, f, d, n));
|
|
5978
5978
|
}
|
|
@@ -6001,10 +6001,10 @@ function Zs(r, e, t, n = 1 / 0) {
|
|
|
6001
6001
|
const p = s[c], f = s[l];
|
|
6002
6002
|
for (const d of e)
|
|
6003
6003
|
for (let h = 0, y = d.length, m = y - 1; h < y; m = h++) {
|
|
6004
|
-
const
|
|
6005
|
-
if (
|
|
6004
|
+
const w = d[m], v = d[h];
|
|
6005
|
+
if (Wt(p, f, w, v))
|
|
6006
6006
|
return 0;
|
|
6007
|
-
i = Math.min(i, en(p, f,
|
|
6007
|
+
i = Math.min(i, en(p, f, w, v, t));
|
|
6008
6008
|
}
|
|
6009
6009
|
}
|
|
6010
6010
|
return i;
|
|
@@ -6021,7 +6021,7 @@ function St(r, e, t, n, a, o, i) {
|
|
|
6021
6021
|
const s = Qr(Tr(n, o), Tr(a, i), t);
|
|
6022
6022
|
s < e && r.push([s, o, i]);
|
|
6023
6023
|
}
|
|
6024
|
-
function
|
|
6024
|
+
function Pt(r, e, t, n, a = 1 / 0) {
|
|
6025
6025
|
let o = Math.min(n.distance(r[0], t[0][0]), a);
|
|
6026
6026
|
if (o === 0)
|
|
6027
6027
|
return o;
|
|
@@ -6031,7 +6031,7 @@ function Mt(r, e, t, n, a = 1 / 0) {
|
|
|
6031
6031
|
if (l[0] >= o)
|
|
6032
6032
|
continue;
|
|
6033
6033
|
const u = l[1], c = e ? Ar : Lr;
|
|
6034
|
-
if (
|
|
6034
|
+
if (Mt(u) <= c) {
|
|
6035
6035
|
if (!ve(u, r.length))
|
|
6036
6036
|
return NaN;
|
|
6037
6037
|
if (e) {
|
|
@@ -6052,7 +6052,7 @@ function Mt(r, e, t, n, a = 1 / 0) {
|
|
|
6052
6052
|
}
|
|
6053
6053
|
return o;
|
|
6054
6054
|
}
|
|
6055
|
-
function
|
|
6055
|
+
function Rt(r, e, t, n, a, o = 1 / 0) {
|
|
6056
6056
|
let i = Math.min(o, a.distance(r[0], t[0]));
|
|
6057
6057
|
if (i === 0)
|
|
6058
6058
|
return i;
|
|
@@ -6062,7 +6062,7 @@ function Pt(r, e, t, n, a, o = 1 / 0) {
|
|
|
6062
6062
|
if (l[0] >= i)
|
|
6063
6063
|
continue;
|
|
6064
6064
|
const u = l[1], c = l[2], p = e ? Ar : Lr, f = n ? Ar : Lr;
|
|
6065
|
-
if (
|
|
6065
|
+
if (Mt(u) <= p && Mt(c) <= f) {
|
|
6066
6066
|
if (!ve(u, r.length) && ve(c, t.length))
|
|
6067
6067
|
return NaN;
|
|
6068
6068
|
let d;
|
|
@@ -6096,13 +6096,13 @@ function Ws(r, e) {
|
|
|
6096
6096
|
for (const i of e) {
|
|
6097
6097
|
switch (i.type) {
|
|
6098
6098
|
case "Point":
|
|
6099
|
-
o = Math.min(o,
|
|
6099
|
+
o = Math.min(o, Rt(n, !1, [i.coordinates], !1, a, o));
|
|
6100
6100
|
break;
|
|
6101
6101
|
case "LineString":
|
|
6102
|
-
o = Math.min(o,
|
|
6102
|
+
o = Math.min(o, Rt(n, !1, i.coordinates, !0, a, o));
|
|
6103
6103
|
break;
|
|
6104
6104
|
case "Polygon":
|
|
6105
|
-
o = Math.min(o,
|
|
6105
|
+
o = Math.min(o, Pt(n, !1, i.coordinates, a, o));
|
|
6106
6106
|
break;
|
|
6107
6107
|
}
|
|
6108
6108
|
if (o === 0)
|
|
@@ -6119,13 +6119,13 @@ function Ys(r, e) {
|
|
|
6119
6119
|
for (const i of e) {
|
|
6120
6120
|
switch (i.type) {
|
|
6121
6121
|
case "Point":
|
|
6122
|
-
o = Math.min(o,
|
|
6122
|
+
o = Math.min(o, Rt(n, !0, [i.coordinates], !1, a, o));
|
|
6123
6123
|
break;
|
|
6124
6124
|
case "LineString":
|
|
6125
|
-
o = Math.min(o,
|
|
6125
|
+
o = Math.min(o, Rt(n, !0, i.coordinates, !0, a, o));
|
|
6126
6126
|
break;
|
|
6127
6127
|
case "Polygon":
|
|
6128
|
-
o = Math.min(o,
|
|
6128
|
+
o = Math.min(o, Pt(n, !0, i.coordinates, a, o));
|
|
6129
6129
|
break;
|
|
6130
6130
|
}
|
|
6131
6131
|
if (o === 0)
|
|
@@ -6143,10 +6143,10 @@ function Js(r, e) {
|
|
|
6143
6143
|
for (const s of n) {
|
|
6144
6144
|
switch (i.type) {
|
|
6145
6145
|
case "Point":
|
|
6146
|
-
o = Math.min(o,
|
|
6146
|
+
o = Math.min(o, Pt([i.coordinates], !1, s, a, o));
|
|
6147
6147
|
break;
|
|
6148
6148
|
case "LineString":
|
|
6149
|
-
o = Math.min(o,
|
|
6149
|
+
o = Math.min(o, Pt(i.coordinates, !0, s, a, o));
|
|
6150
6150
|
break;
|
|
6151
6151
|
case "Polygon":
|
|
6152
6152
|
o = Math.min(o, Zs(s, i.coordinates, a, o));
|
|
@@ -6157,7 +6157,7 @@ function Js(r, e) {
|
|
|
6157
6157
|
}
|
|
6158
6158
|
return o;
|
|
6159
6159
|
}
|
|
6160
|
-
function
|
|
6160
|
+
function pr(r) {
|
|
6161
6161
|
return r.type === "MultiPolygon" ? r.coordinates.map((e) => ({
|
|
6162
6162
|
type: "Polygon",
|
|
6163
6163
|
coordinates: e
|
|
@@ -6171,7 +6171,7 @@ function cr(r) {
|
|
|
6171
6171
|
}
|
|
6172
6172
|
class $e {
|
|
6173
6173
|
constructor(e, t) {
|
|
6174
|
-
this.type =
|
|
6174
|
+
this.type = b, this.geojson = e, this.geometries = t;
|
|
6175
6175
|
}
|
|
6176
6176
|
static parse(e, t) {
|
|
6177
6177
|
if (e.length !== 2)
|
|
@@ -6179,11 +6179,11 @@ class $e {
|
|
|
6179
6179
|
if (ot(e[1])) {
|
|
6180
6180
|
const n = e[1];
|
|
6181
6181
|
if (n.type === "FeatureCollection")
|
|
6182
|
-
return new $e(n, n.features.map((a) =>
|
|
6182
|
+
return new $e(n, n.features.map((a) => pr(a.geometry)).flat());
|
|
6183
6183
|
if (n.type === "Feature")
|
|
6184
|
-
return new $e(n,
|
|
6184
|
+
return new $e(n, pr(n.geometry));
|
|
6185
6185
|
if ("type" in n && "coordinates" in n)
|
|
6186
|
-
return new $e(n,
|
|
6186
|
+
return new $e(n, pr(n));
|
|
6187
6187
|
}
|
|
6188
6188
|
return t.error("'distance' expression requires valid geojson object that contains polygon geometry type.");
|
|
6189
6189
|
}
|
|
@@ -6238,29 +6238,29 @@ const tn = {
|
|
|
6238
6238
|
boolean: se,
|
|
6239
6239
|
case: Vr,
|
|
6240
6240
|
coalesce: it,
|
|
6241
|
-
collator:
|
|
6241
|
+
collator: Zt,
|
|
6242
6242
|
format: Kr,
|
|
6243
6243
|
image: Xr,
|
|
6244
6244
|
in: qr,
|
|
6245
|
-
"index-of":
|
|
6245
|
+
"index-of": _t,
|
|
6246
6246
|
interpolate: he,
|
|
6247
6247
|
"interpolate-hcl": he,
|
|
6248
6248
|
"interpolate-lab": he,
|
|
6249
6249
|
length: Zr,
|
|
6250
|
-
let:
|
|
6250
|
+
let: Ht,
|
|
6251
6251
|
literal: He,
|
|
6252
6252
|
match: Gr,
|
|
6253
6253
|
number: se,
|
|
6254
6254
|
"number-format": Hr,
|
|
6255
6255
|
object: se,
|
|
6256
|
-
slice:
|
|
6257
|
-
step:
|
|
6256
|
+
slice: It,
|
|
6257
|
+
step: Xt,
|
|
6258
6258
|
string: se,
|
|
6259
6259
|
"to-boolean": ke,
|
|
6260
6260
|
"to-color": ke,
|
|
6261
6261
|
"to-number": ke,
|
|
6262
6262
|
"to-string": ke,
|
|
6263
|
-
var:
|
|
6263
|
+
var: Kt,
|
|
6264
6264
|
within: Fe,
|
|
6265
6265
|
distance: $e,
|
|
6266
6266
|
"global-state": ht
|
|
@@ -6286,7 +6286,7 @@ class le {
|
|
|
6286
6286
|
u.length === e.length - 1);
|
|
6287
6287
|
let l = null;
|
|
6288
6288
|
for (const [u, c] of s) {
|
|
6289
|
-
l = new
|
|
6289
|
+
l = new Vt(t.registry, zt, t.path, null, t.scope);
|
|
6290
6290
|
const p = [];
|
|
6291
6291
|
let f = !1;
|
|
6292
6292
|
for (let d = 1; d < e.length; d++) {
|
|
@@ -6318,7 +6318,7 @@ class le {
|
|
|
6318
6318
|
const d = t.parse(e[f], 1 + p.length);
|
|
6319
6319
|
if (!d)
|
|
6320
6320
|
return null;
|
|
6321
|
-
p.push(
|
|
6321
|
+
p.push(N(d.type));
|
|
6322
6322
|
}
|
|
6323
6323
|
t.error(`Expected arguments of type ${c}, but found (${p.join(", ")}) instead.`);
|
|
6324
6324
|
}
|
|
@@ -6334,13 +6334,13 @@ function On(r, [e, t, n, a]) {
|
|
|
6334
6334
|
e = e.evaluate(r), t = t.evaluate(r), n = n.evaluate(r);
|
|
6335
6335
|
const o = a ? a.evaluate(r) : 1, i = xa(e, t, n, o);
|
|
6336
6336
|
if (i)
|
|
6337
|
-
throw new
|
|
6337
|
+
throw new j(i);
|
|
6338
6338
|
return new F(e / 255, t / 255, n / 255, o, !1);
|
|
6339
6339
|
}
|
|
6340
|
-
function
|
|
6340
|
+
function Nn(r, e) {
|
|
6341
6341
|
return r in e;
|
|
6342
6342
|
}
|
|
6343
|
-
function
|
|
6343
|
+
function fr(r, e) {
|
|
6344
6344
|
const t = e[r];
|
|
6345
6345
|
return typeof t > "u" ? null : t;
|
|
6346
6346
|
}
|
|
@@ -6361,16 +6361,16 @@ le.register(tn, {
|
|
|
6361
6361
|
Ki,
|
|
6362
6362
|
[I],
|
|
6363
6363
|
(r, [e]) => {
|
|
6364
|
-
throw new
|
|
6364
|
+
throw new j(e.evaluate(r));
|
|
6365
6365
|
}
|
|
6366
6366
|
],
|
|
6367
6367
|
typeof: [
|
|
6368
6368
|
I,
|
|
6369
6369
|
[T],
|
|
6370
|
-
(r, [e]) =>
|
|
6370
|
+
(r, [e]) => N(B(e.evaluate(r)))
|
|
6371
6371
|
],
|
|
6372
6372
|
"to-rgba": [
|
|
6373
|
-
W(
|
|
6373
|
+
W(b, 4),
|
|
6374
6374
|
[de],
|
|
6375
6375
|
(r, [e]) => {
|
|
6376
6376
|
const [t, n, a, o] = e.evaluate(r).rgb;
|
|
@@ -6379,12 +6379,12 @@ le.register(tn, {
|
|
|
6379
6379
|
],
|
|
6380
6380
|
rgb: [
|
|
6381
6381
|
de,
|
|
6382
|
-
[
|
|
6382
|
+
[b, b, b],
|
|
6383
6383
|
On
|
|
6384
6384
|
],
|
|
6385
6385
|
rgba: [
|
|
6386
6386
|
de,
|
|
6387
|
-
[
|
|
6387
|
+
[b, b, b, b],
|
|
6388
6388
|
On
|
|
6389
6389
|
],
|
|
6390
6390
|
has: {
|
|
@@ -6392,11 +6392,11 @@ le.register(tn, {
|
|
|
6392
6392
|
overloads: [
|
|
6393
6393
|
[
|
|
6394
6394
|
[I],
|
|
6395
|
-
(r, [e]) =>
|
|
6395
|
+
(r, [e]) => Nn(e.evaluate(r), r.properties())
|
|
6396
6396
|
],
|
|
6397
6397
|
[
|
|
6398
6398
|
[I, Re],
|
|
6399
|
-
(r, [e, t]) =>
|
|
6399
|
+
(r, [e, t]) => Nn(e.evaluate(r), t.evaluate(r))
|
|
6400
6400
|
]
|
|
6401
6401
|
]
|
|
6402
6402
|
},
|
|
@@ -6405,18 +6405,18 @@ le.register(tn, {
|
|
|
6405
6405
|
overloads: [
|
|
6406
6406
|
[
|
|
6407
6407
|
[I],
|
|
6408
|
-
(r, [e]) =>
|
|
6408
|
+
(r, [e]) => fr(e.evaluate(r), r.properties())
|
|
6409
6409
|
],
|
|
6410
6410
|
[
|
|
6411
6411
|
[I, Re],
|
|
6412
|
-
(r, [e, t]) =>
|
|
6412
|
+
(r, [e, t]) => fr(e.evaluate(r), t.evaluate(r))
|
|
6413
6413
|
]
|
|
6414
6414
|
]
|
|
6415
6415
|
},
|
|
6416
6416
|
"feature-state": [
|
|
6417
6417
|
T,
|
|
6418
6418
|
[I],
|
|
6419
|
-
(r, [e]) =>
|
|
6419
|
+
(r, [e]) => fr(e.evaluate(r), r.featureState || {})
|
|
6420
6420
|
],
|
|
6421
6421
|
properties: [
|
|
6422
6422
|
Re,
|
|
@@ -6434,22 +6434,22 @@ le.register(tn, {
|
|
|
6434
6434
|
(r) => r.id()
|
|
6435
6435
|
],
|
|
6436
6436
|
zoom: [
|
|
6437
|
-
|
|
6437
|
+
b,
|
|
6438
6438
|
[],
|
|
6439
6439
|
(r) => r.globals.zoom
|
|
6440
6440
|
],
|
|
6441
6441
|
"heatmap-density": [
|
|
6442
|
-
|
|
6442
|
+
b,
|
|
6443
6443
|
[],
|
|
6444
6444
|
(r) => r.globals.heatmapDensity || 0
|
|
6445
6445
|
],
|
|
6446
6446
|
elevation: [
|
|
6447
|
-
|
|
6447
|
+
b,
|
|
6448
6448
|
[],
|
|
6449
6449
|
(r) => r.globals.elevation || 0
|
|
6450
6450
|
],
|
|
6451
6451
|
"line-progress": [
|
|
6452
|
-
|
|
6452
|
+
b,
|
|
6453
6453
|
[],
|
|
6454
6454
|
(r) => r.globals.lineProgress || 0
|
|
6455
6455
|
],
|
|
@@ -6459,8 +6459,8 @@ le.register(tn, {
|
|
|
6459
6459
|
(r) => r.globals.accumulated === void 0 ? null : r.globals.accumulated
|
|
6460
6460
|
],
|
|
6461
6461
|
"+": [
|
|
6462
|
-
|
|
6463
|
-
Ie(
|
|
6462
|
+
b,
|
|
6463
|
+
Ie(b),
|
|
6464
6464
|
(r, e) => {
|
|
6465
6465
|
let t = 0;
|
|
6466
6466
|
for (const n of e)
|
|
@@ -6469,8 +6469,8 @@ le.register(tn, {
|
|
|
6469
6469
|
}
|
|
6470
6470
|
],
|
|
6471
6471
|
"*": [
|
|
6472
|
-
|
|
6473
|
-
Ie(
|
|
6472
|
+
b,
|
|
6473
|
+
Ie(b),
|
|
6474
6474
|
(r, e) => {
|
|
6475
6475
|
let t = 1;
|
|
6476
6476
|
for (const n of e)
|
|
@@ -6479,129 +6479,129 @@ le.register(tn, {
|
|
|
6479
6479
|
}
|
|
6480
6480
|
],
|
|
6481
6481
|
"-": {
|
|
6482
|
-
type:
|
|
6482
|
+
type: b,
|
|
6483
6483
|
overloads: [
|
|
6484
6484
|
[
|
|
6485
|
-
[
|
|
6485
|
+
[b, b],
|
|
6486
6486
|
(r, [e, t]) => e.evaluate(r) - t.evaluate(r)
|
|
6487
6487
|
],
|
|
6488
6488
|
[
|
|
6489
|
-
[
|
|
6489
|
+
[b],
|
|
6490
6490
|
(r, [e]) => -e.evaluate(r)
|
|
6491
6491
|
]
|
|
6492
6492
|
]
|
|
6493
6493
|
},
|
|
6494
6494
|
"/": [
|
|
6495
|
-
|
|
6496
|
-
[
|
|
6495
|
+
b,
|
|
6496
|
+
[b, b],
|
|
6497
6497
|
(r, [e, t]) => e.evaluate(r) / t.evaluate(r)
|
|
6498
6498
|
],
|
|
6499
6499
|
"%": [
|
|
6500
|
-
|
|
6501
|
-
[
|
|
6500
|
+
b,
|
|
6501
|
+
[b, b],
|
|
6502
6502
|
(r, [e, t]) => e.evaluate(r) % t.evaluate(r)
|
|
6503
6503
|
],
|
|
6504
6504
|
ln2: [
|
|
6505
|
-
|
|
6505
|
+
b,
|
|
6506
6506
|
[],
|
|
6507
6507
|
() => Math.LN2
|
|
6508
6508
|
],
|
|
6509
6509
|
pi: [
|
|
6510
|
-
|
|
6510
|
+
b,
|
|
6511
6511
|
[],
|
|
6512
6512
|
() => Math.PI
|
|
6513
6513
|
],
|
|
6514
6514
|
e: [
|
|
6515
|
-
|
|
6515
|
+
b,
|
|
6516
6516
|
[],
|
|
6517
6517
|
() => Math.E
|
|
6518
6518
|
],
|
|
6519
6519
|
"^": [
|
|
6520
|
-
|
|
6521
|
-
[
|
|
6520
|
+
b,
|
|
6521
|
+
[b, b],
|
|
6522
6522
|
(r, [e, t]) => Math.pow(e.evaluate(r), t.evaluate(r))
|
|
6523
6523
|
],
|
|
6524
6524
|
sqrt: [
|
|
6525
|
-
|
|
6526
|
-
[
|
|
6525
|
+
b,
|
|
6526
|
+
[b],
|
|
6527
6527
|
(r, [e]) => Math.sqrt(e.evaluate(r))
|
|
6528
6528
|
],
|
|
6529
6529
|
log10: [
|
|
6530
|
-
|
|
6531
|
-
[
|
|
6530
|
+
b,
|
|
6531
|
+
[b],
|
|
6532
6532
|
(r, [e]) => Math.log(e.evaluate(r)) / Math.LN10
|
|
6533
6533
|
],
|
|
6534
6534
|
ln: [
|
|
6535
|
-
|
|
6536
|
-
[
|
|
6535
|
+
b,
|
|
6536
|
+
[b],
|
|
6537
6537
|
(r, [e]) => Math.log(e.evaluate(r))
|
|
6538
6538
|
],
|
|
6539
6539
|
log2: [
|
|
6540
|
-
|
|
6541
|
-
[
|
|
6540
|
+
b,
|
|
6541
|
+
[b],
|
|
6542
6542
|
(r, [e]) => Math.log(e.evaluate(r)) / Math.LN2
|
|
6543
6543
|
],
|
|
6544
6544
|
sin: [
|
|
6545
|
-
|
|
6546
|
-
[
|
|
6545
|
+
b,
|
|
6546
|
+
[b],
|
|
6547
6547
|
(r, [e]) => Math.sin(e.evaluate(r))
|
|
6548
6548
|
],
|
|
6549
6549
|
cos: [
|
|
6550
|
-
|
|
6551
|
-
[
|
|
6550
|
+
b,
|
|
6551
|
+
[b],
|
|
6552
6552
|
(r, [e]) => Math.cos(e.evaluate(r))
|
|
6553
6553
|
],
|
|
6554
6554
|
tan: [
|
|
6555
|
-
|
|
6556
|
-
[
|
|
6555
|
+
b,
|
|
6556
|
+
[b],
|
|
6557
6557
|
(r, [e]) => Math.tan(e.evaluate(r))
|
|
6558
6558
|
],
|
|
6559
6559
|
asin: [
|
|
6560
|
-
|
|
6561
|
-
[
|
|
6560
|
+
b,
|
|
6561
|
+
[b],
|
|
6562
6562
|
(r, [e]) => Math.asin(e.evaluate(r))
|
|
6563
6563
|
],
|
|
6564
6564
|
acos: [
|
|
6565
|
-
|
|
6566
|
-
[
|
|
6565
|
+
b,
|
|
6566
|
+
[b],
|
|
6567
6567
|
(r, [e]) => Math.acos(e.evaluate(r))
|
|
6568
6568
|
],
|
|
6569
6569
|
atan: [
|
|
6570
|
-
|
|
6571
|
-
[
|
|
6570
|
+
b,
|
|
6571
|
+
[b],
|
|
6572
6572
|
(r, [e]) => Math.atan(e.evaluate(r))
|
|
6573
6573
|
],
|
|
6574
6574
|
min: [
|
|
6575
|
-
|
|
6576
|
-
Ie(
|
|
6575
|
+
b,
|
|
6576
|
+
Ie(b),
|
|
6577
6577
|
(r, e) => Math.min(...e.map((t) => t.evaluate(r)))
|
|
6578
6578
|
],
|
|
6579
6579
|
max: [
|
|
6580
|
-
|
|
6581
|
-
Ie(
|
|
6580
|
+
b,
|
|
6581
|
+
Ie(b),
|
|
6582
6582
|
(r, e) => Math.max(...e.map((t) => t.evaluate(r)))
|
|
6583
6583
|
],
|
|
6584
6584
|
abs: [
|
|
6585
|
-
|
|
6586
|
-
[
|
|
6585
|
+
b,
|
|
6586
|
+
[b],
|
|
6587
6587
|
(r, [e]) => Math.abs(e.evaluate(r))
|
|
6588
6588
|
],
|
|
6589
6589
|
round: [
|
|
6590
|
-
|
|
6591
|
-
[
|
|
6590
|
+
b,
|
|
6591
|
+
[b],
|
|
6592
6592
|
(r, [e]) => {
|
|
6593
6593
|
const t = e.evaluate(r);
|
|
6594
6594
|
return t < 0 ? -Math.round(-t) : Math.round(t);
|
|
6595
6595
|
}
|
|
6596
6596
|
],
|
|
6597
6597
|
floor: [
|
|
6598
|
-
|
|
6599
|
-
[
|
|
6598
|
+
b,
|
|
6599
|
+
[b],
|
|
6600
6600
|
(r, [e]) => Math.floor(e.evaluate(r))
|
|
6601
6601
|
],
|
|
6602
6602
|
ceil: [
|
|
6603
|
-
|
|
6604
|
-
[
|
|
6603
|
+
b,
|
|
6604
|
+
[b],
|
|
6605
6605
|
(r, [e]) => Math.ceil(e.evaluate(r))
|
|
6606
6606
|
],
|
|
6607
6607
|
"filter-==": [
|
|
@@ -6782,19 +6782,19 @@ le.register(tn, {
|
|
|
6782
6782
|
],
|
|
6783
6783
|
"resolved-locale": [
|
|
6784
6784
|
I,
|
|
6785
|
-
[
|
|
6785
|
+
[Dt],
|
|
6786
6786
|
(r, [e]) => e.evaluate(r).resolvedLocale()
|
|
6787
6787
|
]
|
|
6788
6788
|
});
|
|
6789
6789
|
function el(r) {
|
|
6790
|
-
return Array.isArray(r) ? `(${r.map(
|
|
6790
|
+
return Array.isArray(r) ? `(${r.map(N).join(", ")})` : `(${N(r.type)}...)`;
|
|
6791
6791
|
}
|
|
6792
|
-
function
|
|
6793
|
-
if (r instanceof
|
|
6794
|
-
return
|
|
6792
|
+
function zt(r) {
|
|
6793
|
+
if (r instanceof Kt)
|
|
6794
|
+
return zt(r.boundExpression);
|
|
6795
6795
|
if (r instanceof le && r.name === "error")
|
|
6796
6796
|
return !1;
|
|
6797
|
-
if (r instanceof
|
|
6797
|
+
if (r instanceof Zt)
|
|
6798
6798
|
return !1;
|
|
6799
6799
|
if (r instanceof Fe)
|
|
6800
6800
|
return !1;
|
|
@@ -6805,10 +6805,10 @@ function Rt(r) {
|
|
|
6805
6805
|
const e = r instanceof ke || r instanceof se;
|
|
6806
6806
|
let t = !0;
|
|
6807
6807
|
return r.eachChild((n) => {
|
|
6808
|
-
e ? t = t &&
|
|
6809
|
-
}), t ?
|
|
6808
|
+
e ? t = t && zt(n) : t = t && n instanceof He;
|
|
6809
|
+
}), t ? Yt(r) && Jt(r, ["zoom", "heatmap-density", "elevation", "line-progress", "accumulated", "is-supported-script"]) : !1;
|
|
6810
6810
|
}
|
|
6811
|
-
function
|
|
6811
|
+
function Yt(r) {
|
|
6812
6812
|
if (r instanceof le) {
|
|
6813
6813
|
if (r.name === "get" && r.args.length === 1)
|
|
6814
6814
|
return !1;
|
|
@@ -6825,7 +6825,7 @@ function Wt(r) {
|
|
|
6825
6825
|
return !1;
|
|
6826
6826
|
let e = !0;
|
|
6827
6827
|
return r.eachChild((t) => {
|
|
6828
|
-
e && !
|
|
6828
|
+
e && !Yt(t) && (e = !1);
|
|
6829
6829
|
}), e;
|
|
6830
6830
|
}
|
|
6831
6831
|
function lt(r) {
|
|
@@ -6836,12 +6836,12 @@ function lt(r) {
|
|
|
6836
6836
|
e && !lt(t) && (e = !1);
|
|
6837
6837
|
}), e;
|
|
6838
6838
|
}
|
|
6839
|
-
function
|
|
6839
|
+
function Jt(r, e) {
|
|
6840
6840
|
if (r instanceof le && e.indexOf(r.name) >= 0)
|
|
6841
6841
|
return !1;
|
|
6842
6842
|
let t = !0;
|
|
6843
6843
|
return r.eachChild((n) => {
|
|
6844
|
-
t && !
|
|
6844
|
+
t && !Jt(n, e) && (t = !1);
|
|
6845
6845
|
}), t;
|
|
6846
6846
|
}
|
|
6847
6847
|
function Ir(r) {
|
|
@@ -6850,7 +6850,7 @@ function Ir(r) {
|
|
|
6850
6850
|
function Be(r) {
|
|
6851
6851
|
return { result: "error", value: r };
|
|
6852
6852
|
}
|
|
6853
|
-
function
|
|
6853
|
+
function Ft(r) {
|
|
6854
6854
|
return r["property-type"] === "data-driven" || r["property-type"] === "cross-faded-data-driven";
|
|
6855
6855
|
}
|
|
6856
6856
|
function Pa(r) {
|
|
@@ -6879,7 +6879,7 @@ class tl {
|
|
|
6879
6879
|
if (s == null || typeof s == "number" && s !== s)
|
|
6880
6880
|
return this._defaultValue;
|
|
6881
6881
|
if (this._enumValues && !(s in this._enumValues))
|
|
6882
|
-
throw new
|
|
6882
|
+
throw new j(`Expected value to be one of ${Object.keys(this._enumValues).map((l) => JSON.stringify(l)).join(", ")}, but found ${JSON.stringify(s)} instead.`);
|
|
6883
6883
|
return s;
|
|
6884
6884
|
} catch (s) {
|
|
6885
6885
|
return this._warningHistory[s.message] || (this._warningHistory[s.message] = !0, typeof console < "u" && console.warn(s.message)), this._defaultValue;
|
|
@@ -6890,10 +6890,10 @@ function za(r) {
|
|
|
6890
6890
|
return Array.isArray(r) && r.length > 0 && typeof r[0] == "string" && r[0] in tn;
|
|
6891
6891
|
}
|
|
6892
6892
|
function Fa(r, e) {
|
|
6893
|
-
const t = new
|
|
6893
|
+
const t = new Vt(tn, zt, [], e ? nl(e) : void 0), n = t.parse(r, void 0, void 0, void 0, e && e.type === "string" ? { typeAnnotation: "coerce" } : void 0);
|
|
6894
6894
|
return n ? Ir(new tl(n, e)) : Be(t.errors);
|
|
6895
6895
|
}
|
|
6896
|
-
class
|
|
6896
|
+
class jn {
|
|
6897
6897
|
constructor(e, t) {
|
|
6898
6898
|
this.kind = e, this._styleExpression = t, this.isStateDependent = e !== "constant" && !lt(t.expression), this.globalStateRefs = nn(t.expression);
|
|
6899
6899
|
}
|
|
@@ -6922,13 +6922,13 @@ function rl(r, e) {
|
|
|
6922
6922
|
const t = Fa(r, e);
|
|
6923
6923
|
if (t.result === "error")
|
|
6924
6924
|
return t;
|
|
6925
|
-
const n = t.value.expression, a =
|
|
6926
|
-
if (!a && !
|
|
6925
|
+
const n = t.value.expression, a = Yt(n);
|
|
6926
|
+
if (!a && !Ft(e))
|
|
6927
6927
|
return Be([new fe("", "data expressions not supported")]);
|
|
6928
|
-
const o =
|
|
6928
|
+
const o = Jt(n, ["zoom"]);
|
|
6929
6929
|
if (!o && !Pa(e))
|
|
6930
6930
|
return Be([new fe("", "zoom expressions not supported")]);
|
|
6931
|
-
const i =
|
|
6931
|
+
const i = Ct(n);
|
|
6932
6932
|
if (!i && !o)
|
|
6933
6933
|
return Be([new fe("", '"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.')]);
|
|
6934
6934
|
if (i instanceof fe)
|
|
@@ -6936,21 +6936,21 @@ function rl(r, e) {
|
|
|
6936
6936
|
if (i instanceof he && !Ra(e))
|
|
6937
6937
|
return Be([new fe("", '"interpolate" expressions cannot be used with this property')]);
|
|
6938
6938
|
if (!i)
|
|
6939
|
-
return Ir(a ? new
|
|
6939
|
+
return Ir(a ? new jn("constant", t.value) : new jn("source", t.value));
|
|
6940
6940
|
const s = i instanceof he ? i.interpolation : void 0;
|
|
6941
6941
|
return Ir(a ? new Dn("camera", t.value, i.labels, s) : new Dn("composite", t.value, i.labels, s));
|
|
6942
6942
|
}
|
|
6943
|
-
function
|
|
6943
|
+
function Ct(r) {
|
|
6944
6944
|
let e = null;
|
|
6945
|
-
if (r instanceof
|
|
6946
|
-
e =
|
|
6945
|
+
if (r instanceof Ht)
|
|
6946
|
+
e = Ct(r.result);
|
|
6947
6947
|
else if (r instanceof it) {
|
|
6948
6948
|
for (const t of r.args)
|
|
6949
|
-
if (e =
|
|
6949
|
+
if (e = Ct(t), e)
|
|
6950
6950
|
break;
|
|
6951
|
-
} else (r instanceof
|
|
6951
|
+
} else (r instanceof Xt || r instanceof he) && r.input instanceof le && r.input.name === "zoom" && (e = r);
|
|
6952
6952
|
return e instanceof fe || r.eachChild((t) => {
|
|
6953
|
-
const n =
|
|
6953
|
+
const n = Ct(t);
|
|
6954
6954
|
n instanceof fe ? e = n : !e && n ? e = new fe("", '"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.') : e && n && e !== n && (e = new fe("", 'Only one zoom-based "step" or "interpolate" subexpression may be used in an expression.'));
|
|
6955
6955
|
}), e;
|
|
6956
6956
|
}
|
|
@@ -6963,16 +6963,16 @@ function nl(r) {
|
|
|
6963
6963
|
const e = {
|
|
6964
6964
|
color: de,
|
|
6965
6965
|
string: I,
|
|
6966
|
-
number:
|
|
6966
|
+
number: b,
|
|
6967
6967
|
enum: I,
|
|
6968
6968
|
boolean: _,
|
|
6969
|
-
formatted:
|
|
6970
|
-
padding:
|
|
6971
|
-
numberArray:
|
|
6969
|
+
formatted: Ut,
|
|
6970
|
+
padding: Bt,
|
|
6971
|
+
numberArray: qt,
|
|
6972
6972
|
colorArray: nt,
|
|
6973
6973
|
projectionDefinition: jt,
|
|
6974
6974
|
resolvedImage: ft,
|
|
6975
|
-
variableAnchorOffsetCollection:
|
|
6975
|
+
variableAnchorOffsetCollection: Gt
|
|
6976
6976
|
};
|
|
6977
6977
|
return r.type === "array" ? W(e[r.value] || T, r.length) : e[r.type];
|
|
6978
6978
|
}
|
|
@@ -7034,13 +7034,13 @@ function Oa(r) {
|
|
|
7034
7034
|
function U(r) {
|
|
7035
7035
|
return r instanceof Number || r instanceof String || r instanceof Boolean ? r.valueOf() : r;
|
|
7036
7036
|
}
|
|
7037
|
-
function
|
|
7037
|
+
function Ne(r) {
|
|
7038
7038
|
if (Array.isArray(r))
|
|
7039
|
-
return r.map(
|
|
7039
|
+
return r.map(Ne);
|
|
7040
7040
|
if (r instanceof Object && !(r instanceof Number || r instanceof String || r instanceof Boolean)) {
|
|
7041
7041
|
const e = {};
|
|
7042
7042
|
for (const t in r)
|
|
7043
|
-
e[t] =
|
|
7043
|
+
e[t] = Ne(r[t]);
|
|
7044
7044
|
return e;
|
|
7045
7045
|
}
|
|
7046
7046
|
return U(r);
|
|
@@ -7108,12 +7108,12 @@ function an(r) {
|
|
|
7108
7108
|
}));
|
|
7109
7109
|
return u;
|
|
7110
7110
|
}
|
|
7111
|
-
function
|
|
7111
|
+
function Qt(r) {
|
|
7112
7112
|
const e = r.key, t = r.value, n = r.valueSpec;
|
|
7113
7113
|
let a = M(t);
|
|
7114
7114
|
return a === "number" && t !== t && (a = "NaN"), a !== "number" ? [new g(e, t, `number expected, ${a} found`)] : "minimum" in n && t < n.minimum ? [new g(e, t, `${t} is less than the minimum value ${n.minimum}`)] : "maximum" in n && t > n.maximum ? [new g(e, t, `${t} is greater than the maximum value ${n.maximum}`)] : [];
|
|
7115
7115
|
}
|
|
7116
|
-
function
|
|
7116
|
+
function Na(r) {
|
|
7117
7117
|
const e = r.valueSpec, t = U(r.value.type);
|
|
7118
7118
|
let n, a = {}, o, i;
|
|
7119
7119
|
const s = t !== "categorical" && r.value.property === void 0, l = !s, u = M(r.value.stops) === "array" && M(r.value.stops[0]) === "array" && M(r.value.stops[0][0]) === "object", c = te({
|
|
@@ -7128,58 +7128,58 @@ function ja(r) {
|
|
|
7128
7128
|
default: h
|
|
7129
7129
|
}
|
|
7130
7130
|
});
|
|
7131
|
-
return t === "identity" && s && c.push(new g(r.key, r.value, 'missing required property "property"')), t !== "identity" && !r.value.stops && c.push(new g(r.key, r.value, 'missing required property "stops"')), t === "exponential" && r.valueSpec.expression && !Ra(r.valueSpec) && c.push(new g(r.key, r.value, "exponential functions not supported")), r.styleSpec.$version >= 8 && (l && !
|
|
7131
|
+
return t === "identity" && s && c.push(new g(r.key, r.value, 'missing required property "property"')), t !== "identity" && !r.value.stops && c.push(new g(r.key, r.value, 'missing required property "stops"')), t === "exponential" && r.valueSpec.expression && !Ra(r.valueSpec) && c.push(new g(r.key, r.value, "exponential functions not supported")), r.styleSpec.$version >= 8 && (l && !Ft(r.valueSpec) ? c.push(new g(r.key, r.value, "property functions not supported")) : s && !Pa(r.valueSpec) && c.push(new g(r.key, r.value, "zoom functions not supported"))), (t === "categorical" || u) && r.value.property === void 0 && c.push(new g(r.key, r.value, '"property" property is required')), c;
|
|
7132
7132
|
function p(y) {
|
|
7133
7133
|
if (t === "identity")
|
|
7134
7134
|
return [new g(y.key, y.value, 'identity function may not have a "stops" property')];
|
|
7135
7135
|
let m = [];
|
|
7136
|
-
const
|
|
7136
|
+
const w = y.value;
|
|
7137
7137
|
return m = m.concat(an({
|
|
7138
7138
|
key: y.key,
|
|
7139
|
-
value:
|
|
7139
|
+
value: w,
|
|
7140
7140
|
valueSpec: y.valueSpec,
|
|
7141
7141
|
validateSpec: y.validateSpec,
|
|
7142
7142
|
style: y.style,
|
|
7143
7143
|
styleSpec: y.styleSpec,
|
|
7144
7144
|
arrayElementValidator: f
|
|
7145
|
-
})), M(
|
|
7145
|
+
})), M(w) === "array" && w.length === 0 && m.push(new g(y.key, w, "array must have at least one stop")), m;
|
|
7146
7146
|
}
|
|
7147
7147
|
function f(y) {
|
|
7148
7148
|
let m = [];
|
|
7149
|
-
const
|
|
7150
|
-
if (M(
|
|
7151
|
-
return [new g(v,
|
|
7152
|
-
if (
|
|
7153
|
-
return [new g(v,
|
|
7149
|
+
const w = y.value, v = y.key;
|
|
7150
|
+
if (M(w) !== "array")
|
|
7151
|
+
return [new g(v, w, `array expected, ${M(w)} found`)];
|
|
7152
|
+
if (w.length !== 2)
|
|
7153
|
+
return [new g(v, w, `array length 2 expected, length ${w.length} found`)];
|
|
7154
7154
|
if (u) {
|
|
7155
|
-
if (M(
|
|
7156
|
-
return [new g(v,
|
|
7157
|
-
if (
|
|
7158
|
-
return [new g(v,
|
|
7159
|
-
if (
|
|
7160
|
-
return [new g(v,
|
|
7161
|
-
if (i && i > U(
|
|
7162
|
-
return [new g(v,
|
|
7163
|
-
U(
|
|
7155
|
+
if (M(w[0]) !== "object")
|
|
7156
|
+
return [new g(v, w, `object expected, ${M(w[0])} found`)];
|
|
7157
|
+
if (w[0].zoom === void 0)
|
|
7158
|
+
return [new g(v, w, "object stop key must have zoom")];
|
|
7159
|
+
if (w[0].value === void 0)
|
|
7160
|
+
return [new g(v, w, "object stop key must have value")];
|
|
7161
|
+
if (i && i > U(w[0].zoom))
|
|
7162
|
+
return [new g(v, w[0].zoom, "stop zoom values must appear in ascending order")];
|
|
7163
|
+
U(w[0].zoom) !== i && (i = U(w[0].zoom), o = void 0, a = {}), m = m.concat(te({
|
|
7164
7164
|
key: `${v}[0]`,
|
|
7165
|
-
value:
|
|
7165
|
+
value: w[0],
|
|
7166
7166
|
valueSpec: { zoom: {} },
|
|
7167
7167
|
validateSpec: y.validateSpec,
|
|
7168
7168
|
style: y.style,
|
|
7169
7169
|
styleSpec: y.styleSpec,
|
|
7170
|
-
objectElementValidators: { zoom:
|
|
7170
|
+
objectElementValidators: { zoom: Qt, value: d }
|
|
7171
7171
|
}));
|
|
7172
7172
|
} else
|
|
7173
7173
|
m = m.concat(d({
|
|
7174
7174
|
key: `${v}[0]`,
|
|
7175
|
-
value:
|
|
7175
|
+
value: w[0],
|
|
7176
7176
|
validateSpec: y.validateSpec,
|
|
7177
7177
|
style: y.style,
|
|
7178
7178
|
styleSpec: y.styleSpec
|
|
7179
|
-
},
|
|
7180
|
-
return za(
|
|
7179
|
+
}, w));
|
|
7180
|
+
return za(Ne(w[1])) ? m.concat([new g(`${v}[1]`, w[1], "expressions are not allowed in function stops.")]) : m.concat(y.validateSpec({
|
|
7181
7181
|
key: `${v}[1]`,
|
|
7182
|
-
value:
|
|
7182
|
+
value: w[1],
|
|
7183
7183
|
valueSpec: e,
|
|
7184
7184
|
validateSpec: y.validateSpec,
|
|
7185
7185
|
style: y.style,
|
|
@@ -7187,18 +7187,18 @@ function ja(r) {
|
|
|
7187
7187
|
}));
|
|
7188
7188
|
}
|
|
7189
7189
|
function d(y, m) {
|
|
7190
|
-
const
|
|
7190
|
+
const w = M(y.value), v = U(y.value), x = y.value !== null ? y.value : m;
|
|
7191
7191
|
if (!n)
|
|
7192
|
-
n =
|
|
7193
|
-
else if (
|
|
7194
|
-
return [new g(y.key, x, `${
|
|
7195
|
-
if (
|
|
7192
|
+
n = w;
|
|
7193
|
+
else if (w !== n)
|
|
7194
|
+
return [new g(y.key, x, `${w} stop domain type must match previous stop domain type ${n}`)];
|
|
7195
|
+
if (w !== "number" && w !== "string" && w !== "boolean")
|
|
7196
7196
|
return [new g(y.key, x, "stop domain value must be a number, string, or boolean")];
|
|
7197
|
-
if (
|
|
7198
|
-
let A = `number expected, ${
|
|
7199
|
-
return
|
|
7197
|
+
if (w !== "number" && t !== "categorical") {
|
|
7198
|
+
let A = `number expected, ${w} found`;
|
|
7199
|
+
return Ft(e) && t === void 0 && (A += '\nIf you intended to use a categorical function, specify `"type": "categorical"`.'), [new g(y.key, x, A)];
|
|
7200
7200
|
}
|
|
7201
|
-
return t === "categorical" &&
|
|
7201
|
+
return t === "categorical" && w === "number" && (!isFinite(v) || Math.floor(v) !== v) ? [new g(y.key, x, `integer expected, found ${v}`)] : t !== "categorical" && w === "number" && o !== void 0 && v < o ? [new g(y.key, x, "stop domain values must appear in ascending order")] : (o = v, t === "categorical" && v in a ? [new g(y.key, x, "stop domain values must be unique")] : (a[v] = !0, []));
|
|
7202
7202
|
}
|
|
7203
7203
|
function h(y) {
|
|
7204
7204
|
return y.validateSpec({
|
|
@@ -7212,7 +7212,7 @@ function ja(r) {
|
|
|
7212
7212
|
}
|
|
7213
7213
|
}
|
|
7214
7214
|
function Ke(r) {
|
|
7215
|
-
const e = (r.expressionContext === "property" ? rl : Fa)(
|
|
7215
|
+
const e = (r.expressionContext === "property" ? rl : Fa)(Ne(r.value), r.valueSpec);
|
|
7216
7216
|
if (e.result === "error")
|
|
7217
7217
|
return e.value.map((n) => new g(`${r.key}${n.key}`, r.value, n.message));
|
|
7218
7218
|
const t = e.value.expression || e.value._styleExpression.expression;
|
|
@@ -7223,9 +7223,9 @@ function Ke(r) {
|
|
|
7223
7223
|
if (r.expressionContext === "filter" && !lt(t))
|
|
7224
7224
|
return [new g(r.key, r.value, '"feature-state" data expressions are not supported with filters.')];
|
|
7225
7225
|
if (r.expressionContext && r.expressionContext.indexOf("cluster") === 0) {
|
|
7226
|
-
if (!
|
|
7226
|
+
if (!Jt(t, ["zoom", "feature-state"]))
|
|
7227
7227
|
return [new g(r.key, r.value, '"zoom" and "feature-state" expressions are not supported with cluster properties.')];
|
|
7228
|
-
if (r.expressionContext === "cluster-initial" && !
|
|
7228
|
+
if (r.expressionContext === "cluster-initial" && !Yt(t))
|
|
7229
7229
|
return [new g(r.key, r.value, "Feature data expressions are not supported with initial expression part of cluster properties.")];
|
|
7230
7230
|
}
|
|
7231
7231
|
return [];
|
|
@@ -7243,12 +7243,12 @@ function ut(r) {
|
|
|
7243
7243
|
return Array.isArray(n.values) ? n.values.indexOf(U(t)) === -1 && a.push(new g(e, t, `expected one of [${n.values.join(", ")}], ${JSON.stringify(t)} found`)) : Object.keys(n.values).indexOf(U(t)) === -1 && a.push(new g(e, t, `expected one of [${Object.keys(n.values).join(", ")}], ${JSON.stringify(t)} found`)), a;
|
|
7244
7244
|
}
|
|
7245
7245
|
function on(r) {
|
|
7246
|
-
return $a(
|
|
7246
|
+
return $a(Ne(r.value)) ? Ke(Tt({}, r, {
|
|
7247
7247
|
expressionContext: "filter",
|
|
7248
7248
|
valueSpec: { value: "boolean" }
|
|
7249
|
-
})) :
|
|
7249
|
+
})) : ja(r);
|
|
7250
7250
|
}
|
|
7251
|
-
function
|
|
7251
|
+
function ja(r) {
|
|
7252
7252
|
const e = r.value, t = r.key;
|
|
7253
7253
|
if (M(e) !== "array")
|
|
7254
7254
|
return [new g(t, e, `array expected, ${M(e)} found`)];
|
|
@@ -7289,7 +7289,7 @@ function Na(r) {
|
|
|
7289
7289
|
case "all":
|
|
7290
7290
|
case "none":
|
|
7291
7291
|
for (let i = 1; i < e.length; i++)
|
|
7292
|
-
o = o.concat(
|
|
7292
|
+
o = o.concat(ja({
|
|
7293
7293
|
key: `${t}[${i}]`,
|
|
7294
7294
|
value: e[i],
|
|
7295
7295
|
style: r.style,
|
|
@@ -7320,11 +7320,11 @@ function Da(r, e) {
|
|
|
7320
7320
|
if (!c)
|
|
7321
7321
|
return [new g(t, i, `unknown property "${s}"`)];
|
|
7322
7322
|
let p;
|
|
7323
|
-
if (M(i) === "string" &&
|
|
7323
|
+
if (M(i) === "string" && Ft(c) && !c.tokens && (p = /^{([^}]+)}$/.exec(i)))
|
|
7324
7324
|
return [new g(t, i, `"${s}" does not support interpolation syntax
|
|
7325
7325
|
Use an identity property function instead: \`{ "type": "identity", "property": ${JSON.stringify(p[1])} }\`.`)];
|
|
7326
7326
|
const f = [];
|
|
7327
|
-
return r.layerType === "symbol" && (s === "text-field" && a && !a.glyphs && f.push(new g(t, i, 'use of "text-field" requires a style "glyphs" property')), s === "text-font" && rn(
|
|
7327
|
+
return r.layerType === "symbol" && (s === "text-field" && a && !a.glyphs && f.push(new g(t, i, 'use of "text-field" requires a style "glyphs" property')), s === "text-font" && rn(Ne(i)) && U(i.type) === "identity" && f.push(new g(t, i, '"text-font" does not support identity functions'))), f.concat(n({
|
|
7328
7328
|
key: r.key,
|
|
7329
7329
|
value: i,
|
|
7330
7330
|
valueSpec: c,
|
|
@@ -7407,7 +7407,7 @@ function qa(r) {
|
|
|
7407
7407
|
validateSpec: l.validateSpec,
|
|
7408
7408
|
objectElementValidators: {
|
|
7409
7409
|
"*"(u) {
|
|
7410
|
-
return Ba(
|
|
7410
|
+
return Ba(Tt({ layerType: i }, u));
|
|
7411
7411
|
}
|
|
7412
7412
|
}
|
|
7413
7413
|
});
|
|
@@ -7422,7 +7422,7 @@ function qa(r) {
|
|
|
7422
7422
|
validateSpec: l.validateSpec,
|
|
7423
7423
|
objectElementValidators: {
|
|
7424
7424
|
"*"(u) {
|
|
7425
|
-
return Ua(
|
|
7425
|
+
return Ua(Tt({ layerType: i }, u));
|
|
7426
7426
|
}
|
|
7427
7427
|
}
|
|
7428
7428
|
});
|
|
@@ -7430,7 +7430,7 @@ function qa(r) {
|
|
|
7430
7430
|
}
|
|
7431
7431
|
})), e;
|
|
7432
7432
|
}
|
|
7433
|
-
function
|
|
7433
|
+
function je(r) {
|
|
7434
7434
|
const e = r.value, t = r.key, n = M(e);
|
|
7435
7435
|
return n !== "string" ? [new g(t, e, `string expected, ${n} found`)] : [];
|
|
7436
7436
|
}
|
|
@@ -7537,11 +7537,11 @@ function Ga(r) {
|
|
|
7537
7537
|
}
|
|
7538
7538
|
function sl({ key: r, value: e }) {
|
|
7539
7539
|
if (M(e) === "string")
|
|
7540
|
-
return
|
|
7540
|
+
return je({ key: r, value: e });
|
|
7541
7541
|
{
|
|
7542
7542
|
const t = [];
|
|
7543
7543
|
for (const n in e)
|
|
7544
|
-
t.push(...
|
|
7544
|
+
t.push(...je({ key: `${r}.${n}`, value: e[n] }));
|
|
7545
7545
|
return t;
|
|
7546
7546
|
}
|
|
7547
7547
|
}
|
|
@@ -7610,10 +7610,10 @@ function Ka(r) {
|
|
|
7610
7610
|
return o;
|
|
7611
7611
|
}
|
|
7612
7612
|
function ll(r) {
|
|
7613
|
-
return
|
|
7613
|
+
return je(r).length === 0 ? [] : Ke(r);
|
|
7614
7614
|
}
|
|
7615
7615
|
function ul(r) {
|
|
7616
|
-
return
|
|
7616
|
+
return je(r).length === 0 ? [] : Ke(r);
|
|
7617
7617
|
}
|
|
7618
7618
|
function cl(r) {
|
|
7619
7619
|
const e = r.key, t = r.value;
|
|
@@ -7633,7 +7633,7 @@ function cl(r) {
|
|
|
7633
7633
|
}));
|
|
7634
7634
|
return o;
|
|
7635
7635
|
} else
|
|
7636
|
-
return
|
|
7636
|
+
return Qt({
|
|
7637
7637
|
key: e,
|
|
7638
7638
|
value: t,
|
|
7639
7639
|
valueSpec: {}
|
|
@@ -7657,7 +7657,7 @@ function pl(r) {
|
|
|
7657
7657
|
}));
|
|
7658
7658
|
return o;
|
|
7659
7659
|
} else
|
|
7660
|
-
return
|
|
7660
|
+
return Qt({
|
|
7661
7661
|
key: e,
|
|
7662
7662
|
value: t,
|
|
7663
7663
|
valueSpec: {}
|
|
@@ -7730,7 +7730,7 @@ function Xa(r) {
|
|
|
7730
7730
|
}
|
|
7731
7731
|
return e;
|
|
7732
7732
|
} else
|
|
7733
|
-
return
|
|
7733
|
+
return je({
|
|
7734
7734
|
key: n,
|
|
7735
7735
|
value: t
|
|
7736
7736
|
});
|
|
@@ -7779,12 +7779,12 @@ const Bn = {
|
|
|
7779
7779
|
},
|
|
7780
7780
|
array: an,
|
|
7781
7781
|
boolean: ol,
|
|
7782
|
-
number:
|
|
7782
|
+
number: Qt,
|
|
7783
7783
|
color: Mr,
|
|
7784
7784
|
constants: Oa,
|
|
7785
7785
|
enum: ut,
|
|
7786
7786
|
filter: on,
|
|
7787
|
-
function:
|
|
7787
|
+
function: Na,
|
|
7788
7788
|
layer: qa,
|
|
7789
7789
|
object: te,
|
|
7790
7790
|
source: Ga,
|
|
@@ -7793,7 +7793,7 @@ const Bn = {
|
|
|
7793
7793
|
terrain: Ka,
|
|
7794
7794
|
projection: hl,
|
|
7795
7795
|
projectionDefinition: yl,
|
|
7796
|
-
string:
|
|
7796
|
+
string: je,
|
|
7797
7797
|
formatted: ll,
|
|
7798
7798
|
resolvedImage: ul,
|
|
7799
7799
|
padding: cl,
|
|
@@ -7803,25 +7803,25 @@ const Bn = {
|
|
|
7803
7803
|
sprite: Xa,
|
|
7804
7804
|
state: Za
|
|
7805
7805
|
};
|
|
7806
|
-
function
|
|
7806
|
+
function $t(r) {
|
|
7807
7807
|
const e = r.value, t = r.valueSpec, n = r.styleSpec;
|
|
7808
|
-
return r.validateSpec =
|
|
7808
|
+
return r.validateSpec = $t, t.expression && rn(U(e)) ? Na(r) : t.expression && za(Ne(e)) ? Ke(r) : t.type && Bn[t.type] ? Bn[t.type](r) : te(Tt({}, r, {
|
|
7809
7809
|
valueSpec: t.type ? n[t.type] : t
|
|
7810
7810
|
}));
|
|
7811
7811
|
}
|
|
7812
7812
|
function Wa(r) {
|
|
7813
|
-
const e = r.value, t = r.key, n =
|
|
7813
|
+
const e = r.value, t = r.key, n = je(r);
|
|
7814
7814
|
return n.length || (e.indexOf("{fontstack}") === -1 && n.push(new g(t, e, '"glyphs" url must include a "{fontstack}" token')), e.indexOf("{range}") === -1 && n.push(new g(t, e, '"glyphs" url must include a "{range}" token'))), n;
|
|
7815
7815
|
}
|
|
7816
7816
|
function Y(r, e = Hi) {
|
|
7817
7817
|
let t = [];
|
|
7818
|
-
return t = t.concat(
|
|
7818
|
+
return t = t.concat($t({
|
|
7819
7819
|
key: "",
|
|
7820
7820
|
value: r,
|
|
7821
7821
|
valueSpec: e.$root,
|
|
7822
7822
|
styleSpec: e,
|
|
7823
7823
|
style: r,
|
|
7824
|
-
validateSpec:
|
|
7824
|
+
validateSpec: $t,
|
|
7825
7825
|
objectElementValidators: {
|
|
7826
7826
|
glyphs: Wa,
|
|
7827
7827
|
"*"() {
|
|
@@ -7848,7 +7848,7 @@ function ce(r) {
|
|
|
7848
7848
|
return function(e) {
|
|
7849
7849
|
return r({
|
|
7850
7850
|
...e,
|
|
7851
|
-
validateSpec:
|
|
7851
|
+
validateSpec: $t
|
|
7852
7852
|
});
|
|
7853
7853
|
};
|
|
7854
7854
|
}
|
|
@@ -7863,7 +7863,7 @@ function pe(r) {
|
|
|
7863
7863
|
function qn(r) {
|
|
7864
7864
|
if (!r)
|
|
7865
7865
|
return {
|
|
7866
|
-
style: Qe[
|
|
7866
|
+
style: Qe[nr[0].referenceStyleID].getDefaultVariant().getExpandedStyleURL(),
|
|
7867
7867
|
requiresUrlMonitoring: !1,
|
|
7868
7868
|
// default styles don't require URL monitoring
|
|
7869
7869
|
isFallback: !0
|
|
@@ -7875,7 +7875,7 @@ function qn(r) {
|
|
|
7875
7875
|
requiresUrlMonitoring: !1,
|
|
7876
7876
|
isFallback: !1
|
|
7877
7877
|
} : t.isValidJSON ? {
|
|
7878
|
-
style: Qe[
|
|
7878
|
+
style: Qe[nr[0].referenceStyleID].getDefaultVariant().getExpandedStyleURL(),
|
|
7879
7879
|
requiresUrlMonitoring: !1,
|
|
7880
7880
|
// default styles don't require URL monitoring
|
|
7881
7881
|
isFallback: !0
|
|
@@ -7902,7 +7902,7 @@ function qn(r) {
|
|
|
7902
7902
|
requiresUrlMonitoring: !1,
|
|
7903
7903
|
isFallback: !1
|
|
7904
7904
|
} : {
|
|
7905
|
-
style: Qe[
|
|
7905
|
+
style: Qe[nr[0].referenceStyleID].getDefaultVariant().getExpandedStyleURL(),
|
|
7906
7906
|
requiresUrlMonitoring: !1,
|
|
7907
7907
|
// default styles don't require URL monitoring
|
|
7908
7908
|
isFallback: !0
|
|
@@ -8066,7 +8066,7 @@ class Cl extends ri {
|
|
|
8066
8066
|
}
|
|
8067
8067
|
}
|
|
8068
8068
|
var K, oe, Se, xe, Z, pt, q, Ja, J, Qa;
|
|
8069
|
-
class
|
|
8069
|
+
class dr {
|
|
8070
8070
|
constructor(e, t) {
|
|
8071
8071
|
be(this, q);
|
|
8072
8072
|
be(this, K);
|
|
@@ -8228,7 +8228,7 @@ class Ll {
|
|
|
8228
8228
|
this.projectionButton.classList.remove("maplibregl-ctrl-projection-globe"), this.projectionButton.classList.remove("maplibregl-ctrl-projection-mercator"), this.map.isGlobeProjection() ? (this.projectionButton.classList.add("maplibregl-ctrl-projection-mercator"), this.projectionButton.title = "Enable Mercator projection") : (this.projectionButton.classList.add("maplibregl-ctrl-projection-globe"), this.projectionButton.title = "Enable Globe projection");
|
|
8229
8229
|
}
|
|
8230
8230
|
}
|
|
8231
|
-
const Al = "@maptiler/sdk", El = "3.
|
|
8231
|
+
const Al = "@maptiler/sdk", El = "3.6.0", Tl = "The Javascript & TypeScript map SDK tailored for MapTiler Cloud", _l = "MapTiler", Il = "dist/maptiler-sdk.mjs", Ml = "dist/maptiler-sdk.d.ts", Pl = "dist/maptiler-sdk.css", Rl = "module", zl = "dist/maptiler-sdk.mjs", Fl = { ".": { import: "./dist/maptiler-sdk.mjs", types: "./dist/maptiler-sdk.d.ts" }, "./dist/maptiler-sdk.css": { import: "./dist/maptiler-sdk.css" }, "./style.css": { import: "./dist/maptiler-sdk.css" } }, $l = ["maptiler", "map", "sdk", "webmap", "cloud", "webGL", "maplibre"], Ol = "https://docs.maptiler.com/sdk-js/", Nl = "BSD-3-Clause", jl = { type: "git", url: "https://github.com/maptiler/maptiler-sdk-js.git" }, Dl = { prepare: "husky", doc: "rm -rf docs/* && typedoc --out docs && cp -r images docs/", ncu: "npx npm-check-updates", lint: "tsc --noEmit && eslint src", "lint:fix": "tsc --noEmit && eslint src --fix", "test:watch": "vitest watch -c vite.config-test.ts --dom", test: "vitest run -c vite.config-test.ts --dom", "install:clean": "rm -rf build/ dist/ node_modules/ && npm ci", dev: "npm run build-css && vite -c vite.config-dev.ts", "dev-umd": "npm run build-css && tsc && NODE_ENV=development vite build -w -c vite.config-umd.ts", "build-css": "mkdir -p dist build && node scripts/replace-path-with-content.js src/style/style_template.css dist/tmp_maptiler-sdk.css && cat node_modules/maplibre-gl/dist/maplibre-gl.css dist/tmp_maptiler-sdk.css > dist/maptiler-sdk.css && rm dist/tmp_maptiler-sdk.css && cp dist/maptiler-sdk.css build/maptiler-sdk.css", "build-umd": "tsc && NODE_ENV=production vite build -c vite.config-umd.ts", "build-es": "tsc && NODE_ENV=production vite build -c vite.config-es.ts", build: "npm run build-es; npm run build-umd; npm run build-css", make: "npm run install:clean && npm run build" }, Ul = { "@canvas/image-data": "^1.0.0", "@eslint/js": "^9.21.0", "@types/color-convert": "^2.0.4", "@types/color-name": "^2.0.0", "@types/stats.js": "^0.17.4", "@types/uuid": "^10.0.0", "@types/xmldom": "^0.1.31", "@vitest/web-worker": "^3.0.9", "@xmldom/xmldom": "^0.8.10", concurrently: "^9.1.2", eslint: "^9.21.0", "eslint-config-prettier": "^10.0.2", "eslint-plugin-prettier": "^5.2.3", "happy-dom": "^17.4.4", husky: "^8.0.0", jiti: "^2.4.2", "lint-staged": "^15.4.3", prettier: "3.5.2", "stats.js": "^0.17.0", typedoc: "^0.27.6", typescript: "^5.7.3", "typescript-eslint": "^8.25.0", vite: "^6.0.7", "vite-plugin-dts": "^4.5.0", vitest: "^3.0.9" }, Bl = { "@maplibre/maplibre-gl-style-spec": "~23.3.0", "@maptiler/client": "~2.4.0", events: "^3.3.0", "gl-matrix": "^3.4.3", "js-base64": "^3.7.7", "maplibre-gl": "~5.6.0", uuid: "^11.0.5" }, ql = {
|
|
8232
8232
|
name: Al,
|
|
8233
8233
|
version: El,
|
|
8234
8234
|
description: Tl,
|
|
@@ -8241,8 +8241,8 @@ const Al = "@maptiler/sdk", El = "3.5.1-rc5", Tl = "The Javascript & TypeScript
|
|
|
8241
8241
|
exports: Fl,
|
|
8242
8242
|
keywords: $l,
|
|
8243
8243
|
homepage: Ol,
|
|
8244
|
-
license:
|
|
8245
|
-
repository:
|
|
8244
|
+
license: Nl,
|
|
8245
|
+
repository: jl,
|
|
8246
8246
|
scripts: Dl,
|
|
8247
8247
|
"lint-staged": { "*.ts": "npm run lint:fix" },
|
|
8248
8248
|
"ts-typecheck": { "*.ts": "npm tsc --noEmit" },
|
|
@@ -8282,7 +8282,7 @@ class Gl {
|
|
|
8282
8282
|
}
|
|
8283
8283
|
preparePayload() {
|
|
8284
8284
|
const e = new URL(V.telemetryURL);
|
|
8285
|
-
return e.searchParams.append("sdk", ql.version), e.searchParams.append("key", D.apiKey), e.searchParams.append("mtsid",
|
|
8285
|
+
return e.searchParams.append("sdk", ql.version), e.searchParams.append("key", D.apiKey), e.searchParams.append("mtsid", Nr), e.searchParams.append("session", D.session ? "1" : "0"), e.searchParams.append("caching", D.caching ? "1" : "0"), e.searchParams.append("lang-updated", this.map.isLanguageUpdated() ? "1" : "0"), e.searchParams.append("terrain", this.map.getTerrain() ? "1" : "0"), e.searchParams.append("globe", this.map.isGlobeProjection() ? "1" : "0"), this.registeredModules.size > 0 && e.searchParams.append("modules", Array.from(this.registeredModules).join("|")), e.href;
|
|
8286
8286
|
}
|
|
8287
8287
|
}
|
|
8288
8288
|
var ct = typeof Float32Array < "u" ? Float32Array : Array;
|
|
@@ -8299,8 +8299,8 @@ function Vl(r, e, t, n, a, o, i, s, l, u, c, p, f, d, h, y, m) {
|
|
|
8299
8299
|
return r[0] = e, r[1] = t, r[2] = n, r[3] = a, r[4] = o, r[5] = i, r[6] = s, r[7] = l, r[8] = u, r[9] = c, r[10] = p, r[11] = f, r[12] = d, r[13] = h, r[14] = y, r[15] = m, r;
|
|
8300
8300
|
}
|
|
8301
8301
|
function Hl(r, e, t) {
|
|
8302
|
-
var n = e[0], a = e[1], o = e[2], i = e[3], s = e[4], l = e[5], u = e[6], c = e[7], p = e[8], f = e[9], d = e[10], h = e[11], y = e[12], m = e[13],
|
|
8303
|
-
return r[0] = x * n + A * s + L * p + $ * y, r[1] = x * a + A * l + L * f + $ * m, r[2] = x * o + A * u + L * d + $ *
|
|
8302
|
+
var n = e[0], a = e[1], o = e[2], i = e[3], s = e[4], l = e[5], u = e[6], c = e[7], p = e[8], f = e[9], d = e[10], h = e[11], y = e[12], m = e[13], w = e[14], v = e[15], x = t[0], A = t[1], L = t[2], $ = t[3];
|
|
8303
|
+
return r[0] = x * n + A * s + L * p + $ * y, r[1] = x * a + A * l + L * f + $ * m, r[2] = x * o + A * u + L * d + $ * w, r[3] = x * i + A * c + L * h + $ * v, x = t[4], A = t[5], L = t[6], $ = t[7], r[4] = x * n + A * s + L * p + $ * y, r[5] = x * a + A * l + L * f + $ * m, r[6] = x * o + A * u + L * d + $ * w, r[7] = x * i + A * c + L * h + $ * v, x = t[8], A = t[9], L = t[10], $ = t[11], r[8] = x * n + A * s + L * p + $ * y, r[9] = x * a + A * l + L * f + $ * m, r[10] = x * o + A * u + L * d + $ * w, r[11] = x * i + A * c + L * h + $ * v, x = t[12], A = t[13], L = t[14], $ = t[15], r[12] = x * n + A * s + L * p + $ * y, r[13] = x * a + A * l + L * f + $ * m, r[14] = x * o + A * u + L * d + $ * w, r[15] = x * i + A * c + L * h + $ * v, r;
|
|
8304
8304
|
}
|
|
8305
8305
|
function Kl(r, e, t) {
|
|
8306
8306
|
var n = t[0], a = t[1], o = t[2];
|
|
@@ -8323,7 +8323,7 @@ function Zl(r, e, t, n, a) {
|
|
|
8323
8323
|
return r[0] = o / t, r[1] = 0, r[2] = 0, r[3] = 0, r[4] = 0, r[5] = o, r[6] = 0, r[7] = 0, r[8] = 0, r[9] = 0, r[11] = -1, r[12] = 0, r[13] = 0, r[15] = 0, a != null && a !== 1 / 0 ? (i = 1 / (n - a), r[10] = (a + n) * i, r[14] = 2 * a * n * i) : (r[10] = -1, r[14] = -2 * n), r;
|
|
8324
8324
|
}
|
|
8325
8325
|
var Wl = Zl;
|
|
8326
|
-
function
|
|
8326
|
+
function Lt() {
|
|
8327
8327
|
var r = new ct(3);
|
|
8328
8328
|
return ct != Float32Array && (r[0] = 0, r[1] = 0, r[2] = 0), r;
|
|
8329
8329
|
}
|
|
@@ -8331,7 +8331,7 @@ function Yl(r, e, t) {
|
|
|
8331
8331
|
var n = new ct(3);
|
|
8332
8332
|
return n[0] = r, n[1] = e, n[2] = t, n;
|
|
8333
8333
|
}
|
|
8334
|
-
function
|
|
8334
|
+
function hr(r, e) {
|
|
8335
8335
|
var t = e[0], n = e[1], a = e[2], o = t * t + n * n + a * a;
|
|
8336
8336
|
return o > 0 && (o = 1 / Math.sqrt(o)), r[0] = e[0] * o, r[1] = e[1] * o, r[2] = e[2] * o, r;
|
|
8337
8337
|
}
|
|
@@ -8340,7 +8340,7 @@ function Xn(r, e, t) {
|
|
|
8340
8340
|
return r[0] = a * l - o * s, r[1] = o * i - n * l, r[2] = n * s - a * i, r;
|
|
8341
8341
|
}
|
|
8342
8342
|
(function() {
|
|
8343
|
-
var r =
|
|
8343
|
+
var r = Lt();
|
|
8344
8344
|
return function(e, t, n, a, o, i) {
|
|
8345
8345
|
var s, l;
|
|
8346
8346
|
for (t || (t = 3), n || (n = 0), a ? l = Math.min(a * t + n, e.length) : l = e.length, s = n; s < l; s += t)
|
|
@@ -8351,9 +8351,9 @@ function Xn(r, e, t) {
|
|
|
8351
8351
|
function Jl(r) {
|
|
8352
8352
|
return r && r.__esModule && Object.prototype.hasOwnProperty.call(r, "default") ? r.default : r;
|
|
8353
8353
|
}
|
|
8354
|
-
var
|
|
8354
|
+
var yr, Zn;
|
|
8355
8355
|
function Ql() {
|
|
8356
|
-
return Zn || (Zn = 1,
|
|
8356
|
+
return Zn || (Zn = 1, yr = {
|
|
8357
8357
|
aliceblue: [240, 248, 255],
|
|
8358
8358
|
antiquewhite: [250, 235, 215],
|
|
8359
8359
|
aqua: [0, 255, 255],
|
|
@@ -8502,11 +8502,11 @@ function Ql() {
|
|
|
8502
8502
|
whitesmoke: [245, 245, 245],
|
|
8503
8503
|
yellow: [255, 255, 0],
|
|
8504
8504
|
yellowgreen: [154, 205, 50]
|
|
8505
|
-
}),
|
|
8505
|
+
}), yr;
|
|
8506
8506
|
}
|
|
8507
|
-
var
|
|
8507
|
+
var mr, Wn;
|
|
8508
8508
|
function eo() {
|
|
8509
|
-
if (Wn) return
|
|
8509
|
+
if (Wn) return mr;
|
|
8510
8510
|
Wn = 1;
|
|
8511
8511
|
const r = Ql(), e = {};
|
|
8512
8512
|
for (const a of Object.keys(r))
|
|
@@ -8528,7 +8528,7 @@ function eo() {
|
|
|
8528
8528
|
apple: { channels: 3, labels: ["r16", "g16", "b16"] },
|
|
8529
8529
|
gray: { channels: 1, labels: ["gray"] }
|
|
8530
8530
|
};
|
|
8531
|
-
|
|
8531
|
+
mr = t;
|
|
8532
8532
|
for (const a of Object.keys(t)) {
|
|
8533
8533
|
if (!("channels" in t[a]))
|
|
8534
8534
|
throw new Error("missing channels property: " + a);
|
|
@@ -8805,11 +8805,11 @@ function eo() {
|
|
|
8805
8805
|
return "000000".substring(s.length) + s;
|
|
8806
8806
|
}, t.rgb.gray = function(a) {
|
|
8807
8807
|
return [(a[0] + a[1] + a[2]) / 3 / 255 * 100];
|
|
8808
|
-
},
|
|
8808
|
+
}, mr;
|
|
8809
8809
|
}
|
|
8810
|
-
var
|
|
8810
|
+
var gr, Yn;
|
|
8811
8811
|
function eu() {
|
|
8812
|
-
if (Yn) return
|
|
8812
|
+
if (Yn) return gr;
|
|
8813
8813
|
Yn = 1;
|
|
8814
8814
|
const r = eo();
|
|
8815
8815
|
function e() {
|
|
@@ -8846,18 +8846,18 @@ function eu() {
|
|
|
8846
8846
|
s.unshift(i[u].parent), l = n(r[i[u].parent][u], l), u = i[u].parent;
|
|
8847
8847
|
return l.conversion = s, l;
|
|
8848
8848
|
}
|
|
8849
|
-
return
|
|
8849
|
+
return gr = function(o) {
|
|
8850
8850
|
const i = t(o), s = {}, l = Object.keys(i);
|
|
8851
8851
|
for (let u = l.length, c = 0; c < u; c++) {
|
|
8852
8852
|
const p = l[c];
|
|
8853
8853
|
i[p].parent !== null && (s[p] = a(p, i));
|
|
8854
8854
|
}
|
|
8855
8855
|
return s;
|
|
8856
|
-
},
|
|
8856
|
+
}, gr;
|
|
8857
8857
|
}
|
|
8858
|
-
var
|
|
8858
|
+
var vr, Jn;
|
|
8859
8859
|
function tu() {
|
|
8860
|
-
if (Jn) return
|
|
8860
|
+
if (Jn) return vr;
|
|
8861
8861
|
Jn = 1;
|
|
8862
8862
|
const r = eo(), e = eu(), t = {}, n = Object.keys(r);
|
|
8863
8863
|
function a(i) {
|
|
@@ -8888,7 +8888,7 @@ function tu() {
|
|
|
8888
8888
|
const c = s[u];
|
|
8889
8889
|
t[i][u] = o(c), t[i][u].raw = a(c);
|
|
8890
8890
|
});
|
|
8891
|
-
}),
|
|
8891
|
+
}), vr = t, vr;
|
|
8892
8892
|
}
|
|
8893
8893
|
var ru = tu();
|
|
8894
8894
|
const nu = /* @__PURE__ */ Jl(ru);
|
|
@@ -8939,7 +8939,7 @@ function to({
|
|
|
8939
8939
|
indexBufferLength: f
|
|
8940
8940
|
};
|
|
8941
8941
|
}
|
|
8942
|
-
function
|
|
8942
|
+
function At(r) {
|
|
8943
8943
|
if (!r)
|
|
8944
8944
|
return [1, 1, 1, 0];
|
|
8945
8945
|
if (r === "transparent")
|
|
@@ -9077,10 +9077,10 @@ const Ge = {
|
|
|
9077
9077
|
}
|
|
9078
9078
|
};
|
|
9079
9079
|
var Me = /* @__PURE__ */ ((r) => (r.POSITIVE_X = "pX", r.NEGATIVE_X = "nX", r.POSITIVE_Y = "pY", r.NEGATIVE_Y = "nY", r.POSITIVE_Z = "pZ", r.NEGATIVE_Z = "nZ", r))(Me || {});
|
|
9080
|
-
let
|
|
9080
|
+
let xt, ta, ra;
|
|
9081
9081
|
function gu({ gl: r, faces: e, onReady: t, forceRefresh: n }) {
|
|
9082
|
-
|
|
9083
|
-
const a = r.createTexture();
|
|
9082
|
+
xt && !n && ra === JSON.stringify(e) && t(xt, ta), ra = JSON.stringify(e);
|
|
9083
|
+
const a = xt ?? r.createTexture();
|
|
9084
9084
|
if (r.bindTexture(r.TEXTURE_CUBE_MAP, a), !e) {
|
|
9085
9085
|
console.warn("[CubemapLayer][loadCubemapTexture]: Faces are null");
|
|
9086
9086
|
return;
|
|
@@ -9091,24 +9091,35 @@ function gu({ gl: r, faces: e, onReady: t, forceRefresh: n }) {
|
|
|
9091
9091
|
return;
|
|
9092
9092
|
}
|
|
9093
9093
|
const i = Object.entries(e).map(([s, l]) => new Promise((u, c) => {
|
|
9094
|
+
const p = s;
|
|
9094
9095
|
if (l === void 0) {
|
|
9095
|
-
|
|
9096
|
+
c(new Error(`[CubemapLayer][loadCubemapTexture]: Face ${s} is undefined`));
|
|
9096
9097
|
return;
|
|
9097
9098
|
}
|
|
9098
|
-
const
|
|
9099
|
-
|
|
9100
|
-
|
|
9101
|
-
|
|
9102
|
-
|
|
9103
|
-
|
|
9104
|
-
};
|
|
9105
|
-
|
|
9106
|
-
c(new Error(`[CubemapLayer][loadCubemapTexture]: Error loading image ${l}`));
|
|
9107
|
-
};
|
|
9108
|
-
}
|
|
9099
|
+
const f = new Image();
|
|
9100
|
+
f.crossOrigin = "anonymous";
|
|
9101
|
+
const d = () => {
|
|
9102
|
+
u({ image: f, key: p });
|
|
9103
|
+
};
|
|
9104
|
+
f.src = l, f.complete && f.naturalWidth > 0 ? d() : f.onload = d, f.onerror = () => {
|
|
9105
|
+
c(new Error(`[CubemapLayer][loadCubemapTexture]: Error loading image ${l}`));
|
|
9106
|
+
};
|
|
9109
9107
|
}));
|
|
9110
9108
|
Promise.all(i).then((s) => {
|
|
9111
|
-
|
|
9109
|
+
for (let u = 0; u < s.length; u++) {
|
|
9110
|
+
const p = r.RGBA, f = r.RGBA, d = r.UNSIGNED_BYTE, { image: h, key: y } = s[u] ?? {};
|
|
9111
|
+
if (!h || !y) {
|
|
9112
|
+
console.warn("[CubemapLayer][loadCubemapTexture]: Image or key is null");
|
|
9113
|
+
continue;
|
|
9114
|
+
}
|
|
9115
|
+
const m = vu(r, y);
|
|
9116
|
+
r.bindTexture(r.TEXTURE_CUBE_MAP, a), r.texParameteri(r.TEXTURE_CUBE_MAP, r.TEXTURE_MAG_FILTER, r.LINEAR), r.texParameteri(r.TEXTURE_CUBE_MAP, r.TEXTURE_MIN_FILTER, r.LINEAR), r.texParameteri(r.TEXTURE_CUBE_MAP, r.TEXTURE_WRAP_S, r.CLAMP_TO_EDGE), r.texParameteri(r.TEXTURE_CUBE_MAP, r.TEXTURE_WRAP_T, r.CLAMP_TO_EDGE), r.texImage2D(m, 0, p, f, d, h);
|
|
9117
|
+
}
|
|
9118
|
+
r.bindTexture(r.TEXTURE_CUBE_MAP, a), r.generateMipmap(r.TEXTURE_CUBE_MAP), r.texParameteri(r.TEXTURE_CUBE_MAP, r.TEXTURE_MIN_FILTER, r.LINEAR_MIPMAP_LINEAR), r.texParameteri(r.TEXTURE_CUBE_MAP, r.TEXTURE_MAG_FILTER, r.LINEAR);
|
|
9119
|
+
const l = s.map((u) => u.image);
|
|
9120
|
+
t(a, l), ta = l, xt = a;
|
|
9121
|
+
}).catch((s) => {
|
|
9122
|
+
console.error("[CubemapLayer][loadCubemapTexture]: Error loading cubemap texture", s);
|
|
9112
9123
|
});
|
|
9113
9124
|
}
|
|
9114
9125
|
function vu(r, e) {
|
|
@@ -9277,7 +9288,7 @@ class br {
|
|
|
9277
9288
|
*/
|
|
9278
9289
|
S(this, "imageFadeInDelta", 0);
|
|
9279
9290
|
const t = Cu(e, ku);
|
|
9280
|
-
this.options = t, this.currentFacesDefinitionKey = JSON.stringify(t.faces ?? t.preset ?? t.path), this.bgColor = [0, 0, 0, 0], this.targetBgColor =
|
|
9291
|
+
this.options = t, this.currentFacesDefinitionKey = JSON.stringify(t.faces ?? t.preset ?? t.path), this.bgColor = [0, 0, 0, 0], this.targetBgColor = At(t.color), this.faces = aa(t), this.useCubemapTexture = this.faces !== null;
|
|
9281
9292
|
}
|
|
9282
9293
|
/**
|
|
9283
9294
|
* Updates the cubemap object with the current faces and shader configuration.
|
|
@@ -9287,19 +9298,19 @@ class br {
|
|
|
9287
9298
|
* It creates a new Object3D instance with the specified vertex and fragment shaders,
|
|
9288
9299
|
* attributes, and uniforms. The cubemap will be rendered using this configuration.
|
|
9289
9300
|
*/
|
|
9290
|
-
updateCubemap() {
|
|
9301
|
+
updateCubemap({ facesNeedUpdate: e } = { facesNeedUpdate: !0 }) {
|
|
9291
9302
|
this.useCubemapTexture = this.faces !== null;
|
|
9292
|
-
const
|
|
9303
|
+
const t = Su.filter((n) => n === "cubeSampler" || n === "fadeOpacity" ? this.useCubemapTexture : !0);
|
|
9293
9304
|
this.cubemap = to({
|
|
9294
9305
|
gl: this.gl,
|
|
9295
9306
|
vertexShaderSource: yu,
|
|
9296
9307
|
// Because we only want to use the read the texture in gl if we're supposed to
|
|
9297
9308
|
fragmentShaderSource: this.useCubemapTexture ? ea.replace(na, xu) : ea.replace(na, ""),
|
|
9298
9309
|
attributesKeys: wu,
|
|
9299
|
-
uniformsKeys:
|
|
9310
|
+
uniformsKeys: t,
|
|
9300
9311
|
vertices: du,
|
|
9301
9312
|
indices: hu
|
|
9302
|
-
}), this.cubeMapNeedsUpdate =
|
|
9313
|
+
}), this.cubeMapNeedsUpdate = e, this.useCubemapTexture && this.updateTexture(this.gl, this.faces), this.animateColorChange();
|
|
9303
9314
|
}
|
|
9304
9315
|
/**
|
|
9305
9316
|
* Called when the layer is added to the map.
|
|
@@ -9455,16 +9466,16 @@ class br {
|
|
|
9455
9466
|
*/
|
|
9456
9467
|
async setCubemap(e) {
|
|
9457
9468
|
this.options = e;
|
|
9458
|
-
const t = JSON.stringify(e.faces ?? e.preset ?? e.path);
|
|
9459
|
-
|
|
9460
|
-
const
|
|
9461
|
-
if (e.color && this.targetBgColor.toString() !==
|
|
9462
|
-
this.setBgColor(
|
|
9469
|
+
const t = JSON.stringify(e.faces ?? e.preset ?? e.path), n = this.currentFacesDefinitionKey !== t;
|
|
9470
|
+
n && (await this.setCubemapFaces(e), this.cubeMapNeedsUpdate = !0);
|
|
9471
|
+
const a = At(e.color);
|
|
9472
|
+
if (e.color && this.targetBgColor.toString() !== a.toString())
|
|
9473
|
+
this.setBgColor(a);
|
|
9463
9474
|
else if (!e.color && e.preset && e.preset in Ge) {
|
|
9464
|
-
const
|
|
9465
|
-
this.setBgColor(
|
|
9475
|
+
const o = Ge[e.preset];
|
|
9476
|
+
this.setBgColor(At(o.color));
|
|
9466
9477
|
}
|
|
9467
|
-
this.updateCubemap();
|
|
9478
|
+
this.updateCubemap({ facesNeedUpdate: n });
|
|
9468
9479
|
}
|
|
9469
9480
|
/**
|
|
9470
9481
|
* Shows the cubemap layer by setting its visibility to "visible".
|
|
@@ -9746,20 +9757,20 @@ class wr {
|
|
|
9746
9757
|
Hl(i, t.defaultProjectionData.mainMatrix, a);
|
|
9747
9758
|
const s = this.plane.programInfo.uniformsLocations.matrix;
|
|
9748
9759
|
e.uniformMatrix4fv(s, !1, i);
|
|
9749
|
-
const l = rt(), u = this.map.transform.cameraPosition, c =
|
|
9750
|
-
Xn(f, p, c),
|
|
9751
|
-
const d =
|
|
9752
|
-
Xn(d, c, f),
|
|
9760
|
+
const l = rt(), u = this.map.transform.cameraPosition, c = hr(Lt(), u), p = Yl(0, 1, 0), f = Lt();
|
|
9761
|
+
Xn(f, p, c), hr(f, f);
|
|
9762
|
+
const d = Lt();
|
|
9763
|
+
Xn(d, c, f), hr(d, d), Vl(l, f[0], f[1], f[2], 0, d[0], d[1], d[2], 0, c[0], c[1], c[2], 0, 0, 0, 0, 1);
|
|
9753
9764
|
const h = this.plane.programInfo.uniformsLocations.rotationMatrix;
|
|
9754
9765
|
e.uniformMatrix4fv(h, !1, l);
|
|
9755
|
-
const y = this.gradient.stops.length, m = [],
|
|
9766
|
+
const y = this.gradient.stops.length, m = [], w = [];
|
|
9756
9767
|
for (let v = 0; v <= y; v++)
|
|
9757
9768
|
if (v < y) {
|
|
9758
9769
|
m[v] = this.gradient.stops[v][0];
|
|
9759
|
-
const x =
|
|
9760
|
-
|
|
9770
|
+
const x = At(this.gradient.stops[v][1]);
|
|
9771
|
+
w.push(...x);
|
|
9761
9772
|
}
|
|
9762
|
-
e.uniform1i(this.plane.programInfo.uniformsLocations.stopsNumber, y), e.uniform1fv(this.plane.programInfo.uniformsLocations.stops, new Float32Array(m)), e.uniform4fv(this.plane.programInfo.uniformsLocations.colors, new Float32Array(
|
|
9773
|
+
e.uniform1i(this.plane.programInfo.uniformsLocations.stopsNumber, y), e.uniform1fv(this.plane.programInfo.uniformsLocations.stops, new Float32Array(m)), e.uniform4fv(this.plane.programInfo.uniformsLocations.colors, new Float32Array(w)), e.uniform1f(this.plane.programInfo.uniformsLocations.maxDistance, Je), e.uniform1f(this.plane.programInfo.uniformsLocations.scale, o), e.drawArrays(e.TRIANGLE_STRIP, 0, 4);
|
|
9763
9774
|
}
|
|
9764
9775
|
/**
|
|
9765
9776
|
* Sets a new gradient for the radial gradient layer and animates the transition.
|
|
@@ -9837,9 +9848,9 @@ let Mu = class ro extends k.Map {
|
|
|
9837
9848
|
this.styleInProcess = !1;
|
|
9838
9849
|
}), this.on("error", (h) => {
|
|
9839
9850
|
if (h.error instanceof k.AJAXError) {
|
|
9840
|
-
const m = h.error.url,
|
|
9841
|
-
|
|
9842
|
-
const v =
|
|
9851
|
+
const m = h.error.url, w = new URL(m);
|
|
9852
|
+
w.search = "";
|
|
9853
|
+
const v = w.href;
|
|
9843
9854
|
this.monitoredStyleUrls && this.monitoredStyleUrls.has(v) && (this.monitoredStyleUrls.delete(v), u());
|
|
9844
9855
|
return;
|
|
9845
9856
|
}
|
|
@@ -9918,8 +9929,8 @@ let Mu = class ro extends k.Map {
|
|
|
9918
9929
|
} else t.maptilerLogo && this.addControl(new xn(), t.logoPosition);
|
|
9919
9930
|
if (t.scaleControl) {
|
|
9920
9931
|
const y = t.scaleControl === !0 || t.scaleControl === void 0 ? "bottom-right" : t.scaleControl, m = new ai({ unit: D.unit });
|
|
9921
|
-
this.addControl(m, y), D.on("unit", (
|
|
9922
|
-
m.setUnit(
|
|
9932
|
+
this.addControl(m, y), D.on("unit", (w) => {
|
|
9933
|
+
m.setUnit(w);
|
|
9923
9934
|
});
|
|
9924
9935
|
}
|
|
9925
9936
|
if (t.navigationControl !== !1) {
|
|
@@ -9969,7 +9980,7 @@ let Mu = class ro extends k.Map {
|
|
|
9969
9980
|
const {
|
|
9970
9981
|
zoom: y,
|
|
9971
9982
|
center: m,
|
|
9972
|
-
style:
|
|
9983
|
+
style: w,
|
|
9973
9984
|
language: v,
|
|
9974
9985
|
apiKey: x,
|
|
9975
9986
|
maptilerLogo: A,
|
|
@@ -9989,10 +10000,10 @@ let Mu = class ro extends k.Map {
|
|
|
9989
10000
|
pixelRatio: Co,
|
|
9990
10001
|
validateStyle: Lo
|
|
9991
10002
|
} = t;
|
|
9992
|
-
this.minimap = new
|
|
10003
|
+
this.minimap = new dr(h, {
|
|
9993
10004
|
zoom: y,
|
|
9994
10005
|
center: m,
|
|
9995
|
-
style:
|
|
10006
|
+
style: w,
|
|
9996
10007
|
language: v,
|
|
9997
10008
|
apiKey: x,
|
|
9998
10009
|
container: "null",
|
|
@@ -10013,7 +10024,7 @@ let Mu = class ro extends k.Map {
|
|
|
10013
10024
|
pixelRatio: Co,
|
|
10014
10025
|
validateStyle: Lo
|
|
10015
10026
|
}), this.addControl(this.minimap, h.position ?? "bottom-left");
|
|
10016
|
-
} else h === !0 ? (this.minimap = new
|
|
10027
|
+
} else h === !0 ? (this.minimap = new dr({}, t), this.addControl(this.minimap, "bottom-left")) : h !== void 0 && h !== !1 && (this.minimap = new dr({}, t), this.addControl(this.minimap, h));
|
|
10017
10028
|
});
|
|
10018
10029
|
const d = (h) => {
|
|
10019
10030
|
h.terrain && (p = !0, f = {
|
|
@@ -10031,7 +10042,7 @@ let Mu = class ro extends k.Map {
|
|
|
10031
10042
|
console.warn("[webglcontextlost]", "Unexpected loss of WebGL context!"), this.fire("webglContextLost", y);
|
|
10032
10043
|
});
|
|
10033
10044
|
const h = this.getLayersOrder()[0];
|
|
10034
|
-
this.initSpace({ options: t, before: h }), this.initHalo({ options: t, before: h });
|
|
10045
|
+
t.space && this.initSpace({ options: t, before: h }), t.halo && this.initHalo({ options: t, before: h });
|
|
10035
10046
|
}), this.telemetry = new Gl(this);
|
|
10036
10047
|
}
|
|
10037
10048
|
getSpace() {
|
|
@@ -10271,10 +10282,9 @@ let Mu = class ro extends k.Map {
|
|
|
10271
10282
|
else
|
|
10272
10283
|
return l(), this;
|
|
10273
10284
|
return this.styleInProcess && this.once("style.load", () => {
|
|
10274
|
-
var m,
|
|
10275
|
-
console.log("style.load");
|
|
10285
|
+
var m, w, v, x;
|
|
10276
10286
|
const h = this.getLayersOrder()[0], y = a.style;
|
|
10277
|
-
this.space ? this.setSpaceFromStyle({ style: y }) : this.initSpace({ before: h, spec: (
|
|
10287
|
+
this.space ? this.setSpaceFromStyle({ style: y }) : this.initSpace({ before: h, spec: (w = (m = y.metadata) == null ? void 0 : m.maptiler) == null ? void 0 : w.space }), this.halo ? this.setHaloFromStyle({ style: y }) : this.initHalo({ before: h, spec: (x = (v = y.metadata) == null ? void 0 : v.maptiler) == null ? void 0 : x.halo });
|
|
10278
10288
|
}), this;
|
|
10279
10289
|
}
|
|
10280
10290
|
/**
|
|
@@ -10491,8 +10501,8 @@ let Mu = class ro extends k.Map {
|
|
|
10491
10501
|
continue;
|
|
10492
10502
|
let m;
|
|
10493
10503
|
if (u ? (m = this.getLayoutProperty(h, "text-field"), this.originalLabelStyle.set(h, m)) : m = this.originalLabelStyle.get(h), typeof m == "string") {
|
|
10494
|
-
const { contains:
|
|
10495
|
-
if (!
|
|
10504
|
+
const { contains: w, exactMatch: v } = Zo(m, this.isStyleLocalized);
|
|
10505
|
+
if (!w) continue;
|
|
10496
10506
|
if (v)
|
|
10497
10507
|
this.setLayoutProperty(h, "text-field", s);
|
|
10498
10508
|
else {
|
|
@@ -10500,8 +10510,8 @@ let Mu = class ro extends k.Map {
|
|
|
10500
10510
|
this.setLayoutProperty(h, "text-field", x);
|
|
10501
10511
|
}
|
|
10502
10512
|
} else {
|
|
10503
|
-
const
|
|
10504
|
-
this.setLayoutProperty(h, "text-field",
|
|
10513
|
+
const w = Xo(m, s, this.isStyleLocalized);
|
|
10514
|
+
this.setLayoutProperty(h, "text-field", w);
|
|
10505
10515
|
}
|
|
10506
10516
|
}
|
|
10507
10517
|
this.languageIsUpdated = !0;
|
|
@@ -10566,9 +10576,18 @@ let Mu = class ro extends k.Map {
|
|
|
10566
10576
|
this.isTerrainEnabled = !0, this.growTerrain(t);
|
|
10567
10577
|
return;
|
|
10568
10578
|
}
|
|
10569
|
-
this.loaded() || this.isTerrainEnabled
|
|
10570
|
-
|
|
10571
|
-
|
|
10579
|
+
if (this.loaded() || this.isTerrainEnabled)
|
|
10580
|
+
a();
|
|
10581
|
+
else {
|
|
10582
|
+
const o = () => {
|
|
10583
|
+
this.getTerrain() && this.getSource(V.terrainSourceId) || a();
|
|
10584
|
+
};
|
|
10585
|
+
this.once("load", () => {
|
|
10586
|
+
o();
|
|
10587
|
+
}), this.once("moveend", () => {
|
|
10588
|
+
o();
|
|
10589
|
+
});
|
|
10590
|
+
}
|
|
10572
10591
|
}
|
|
10573
10592
|
/**
|
|
10574
10593
|
* Disable the 3D terrain visualization
|
|
@@ -10641,7 +10660,7 @@ let Mu = class ro extends k.Map {
|
|
|
10641
10660
|
* @returns
|
|
10642
10661
|
*/
|
|
10643
10662
|
getMaptilerSessionId() {
|
|
10644
|
-
return
|
|
10663
|
+
return Nr;
|
|
10645
10664
|
}
|
|
10646
10665
|
/**
|
|
10647
10666
|
* Updates the requestManager's transform request with a new function.
|
|
@@ -10774,16 +10793,16 @@ function Ru(r) {
|
|
|
10774
10793
|
times: n
|
|
10775
10794
|
};
|
|
10776
10795
|
}
|
|
10777
|
-
function
|
|
10796
|
+
function Et(r) {
|
|
10778
10797
|
const e = ["Polygon", "LineString", "Point", "Track", "gx:Track"];
|
|
10779
10798
|
let t, n, a, o, i;
|
|
10780
10799
|
const s = [], l = [];
|
|
10781
10800
|
if (E(r, "MultiGeometry") !== null)
|
|
10782
|
-
return
|
|
10801
|
+
return Et(E(r, "MultiGeometry"));
|
|
10783
10802
|
if (E(r, "MultiTrack") !== null)
|
|
10784
|
-
return
|
|
10803
|
+
return Et(E(r, "MultiTrack"));
|
|
10785
10804
|
if (E(r, "gx:MultiTrack") !== null)
|
|
10786
|
-
return
|
|
10805
|
+
return Et(E(r, "gx:MultiTrack"));
|
|
10787
10806
|
for (a = 0; a < e.length; a++)
|
|
10788
10807
|
if (n = G(r, e[a]), n) {
|
|
10789
10808
|
for (o = 0; o < n.length; o++)
|
|
@@ -10816,7 +10835,7 @@ function At(r) {
|
|
|
10816
10835
|
return { geoms: s, coordTimes: l };
|
|
10817
10836
|
}
|
|
10818
10837
|
function zu(r, e, t, n) {
|
|
10819
|
-
const a =
|
|
10838
|
+
const a = Et(r), o = {}, i = O(E(r, "name")), s = O(E(r, "address")), l = O(E(r, "description")), u = E(r, "TimeSpan"), c = E(r, "TimeStamp"), p = E(r, "ExtendedData"), f = E(r, "visibility");
|
|
10820
10839
|
let d, h = O(E(r, "styleUrl")), y = E(r, "LineStyle"), m = E(r, "PolyStyle");
|
|
10821
10840
|
if (!a.geoms.length) return [];
|
|
10822
10841
|
if (i && (o.name = i), s && (o.address = s), h) {
|
|
@@ -10854,7 +10873,7 @@ function zu(r, e, t, n) {
|
|
|
10854
10873
|
o[x[d].getAttribute("name") ?? ""] = O(x[d]) ?? "";
|
|
10855
10874
|
}
|
|
10856
10875
|
f !== null && (o.visibility = O(f) ?? ""), a.coordTimes.length !== 0 && (o.coordTimes = a.coordTimes.length === 1 ? a.coordTimes[0] : a.coordTimes);
|
|
10857
|
-
const
|
|
10876
|
+
const w = {
|
|
10858
10877
|
type: "Feature",
|
|
10859
10878
|
geometry: a.geoms.length === 1 ? a.geoms[0] : {
|
|
10860
10879
|
type: "GeometryCollection",
|
|
@@ -10862,7 +10881,7 @@ function zu(r, e, t, n) {
|
|
|
10862
10881
|
},
|
|
10863
10882
|
properties: o
|
|
10864
10883
|
};
|
|
10865
|
-
return Oe(r, "id") && (
|
|
10884
|
+
return Oe(r, "id") && (w.id = Oe(r, "id") ?? void 0), [w];
|
|
10866
10885
|
}
|
|
10867
10886
|
function io(r, e) {
|
|
10868
10887
|
const t = G(r, e), n = [], a = [];
|
|
@@ -10980,14 +10999,14 @@ function E(r, e) {
|
|
|
10980
10999
|
const t = G(r, e);
|
|
10981
11000
|
return t.length ? t[0] : null;
|
|
10982
11001
|
}
|
|
10983
|
-
function
|
|
11002
|
+
function Nu(r) {
|
|
10984
11003
|
return r.normalize && r.normalize(), r;
|
|
10985
11004
|
}
|
|
10986
11005
|
function lo(r) {
|
|
10987
11006
|
return r.map(Number.parseFloat).map((e) => Number.isNaN(e) ? null : e);
|
|
10988
11007
|
}
|
|
10989
11008
|
function O(r) {
|
|
10990
|
-
return r &&
|
|
11009
|
+
return r && Nu(r), r && r.textContent;
|
|
10991
11010
|
}
|
|
10992
11011
|
function Pr(r, e) {
|
|
10993
11012
|
const t = {};
|
|
@@ -11013,7 +11032,7 @@ function co(r) {
|
|
|
11013
11032
|
heartRate: n !== null ? Number.parseFloat(O(n) ?? "0") : null
|
|
11014
11033
|
};
|
|
11015
11034
|
}
|
|
11016
|
-
function
|
|
11035
|
+
function ju(r) {
|
|
11017
11036
|
let e = r;
|
|
11018
11037
|
try {
|
|
11019
11038
|
typeof e == "string" && (e = un(e));
|
|
@@ -11073,7 +11092,7 @@ const Rr = [
|
|
|
11073
11092
|
// https://colorhunt.co/palette/10a19d540375ff7000ffbf00
|
|
11074
11093
|
["#10A19D", "#540375", "#FF7000", "#FFBF00"]
|
|
11075
11094
|
];
|
|
11076
|
-
function
|
|
11095
|
+
function er() {
|
|
11077
11096
|
return Rr[~~(Math.random() * Rr.length)][~~(Math.random() * 4)];
|
|
11078
11097
|
}
|
|
11079
11098
|
function yt() {
|
|
@@ -11188,12 +11207,12 @@ function yo(r, e = 10) {
|
|
|
11188
11207
|
}).flat()
|
|
11189
11208
|
];
|
|
11190
11209
|
}
|
|
11191
|
-
function
|
|
11210
|
+
function kt(r) {
|
|
11192
11211
|
const e = r.toString(16);
|
|
11193
11212
|
return e.length === 1 ? `0${e}` : e;
|
|
11194
11213
|
}
|
|
11195
11214
|
function Bu(r) {
|
|
11196
|
-
return `#${
|
|
11215
|
+
return `#${kt(r[0])}${kt(r[1])}${kt(r[2])}${r.length === 4 ? kt(r[3]) : ""}`;
|
|
11197
11216
|
}
|
|
11198
11217
|
class C extends Array {
|
|
11199
11218
|
constructor(t = {}) {
|
|
@@ -12135,7 +12154,7 @@ async function qu(r, e, t = {}) {
|
|
|
12135
12154
|
throw new Error("Creating a polyline layer requires an existing .sourceId or a valid .data property");
|
|
12136
12155
|
let n = e.data;
|
|
12137
12156
|
if (typeof n == "string") {
|
|
12138
|
-
if (
|
|
12157
|
+
if (Ot(n))
|
|
12139
12158
|
n = `https://api.maptiler.com/data/${e.data}/features.json?key=${D.apiKey}`;
|
|
12140
12159
|
else if (((a = n.split(".").pop()) == null ? void 0 : a.toLowerCase().trim()) === "gpx") {
|
|
12141
12160
|
const s = await (await fetch(n, t)).text();
|
|
@@ -12144,7 +12163,7 @@ async function qu(r, e, t = {}) {
|
|
|
12144
12163
|
const s = await (await fetch(n, t)).text();
|
|
12145
12164
|
n = oo(s);
|
|
12146
12165
|
} else {
|
|
12147
|
-
const i = Vo(n) ??
|
|
12166
|
+
const i = Vo(n) ?? ju(n);
|
|
12148
12167
|
i && (n = i);
|
|
12149
12168
|
}
|
|
12150
12169
|
if (!n)
|
|
@@ -12167,7 +12186,7 @@ function Gu(r, e) {
|
|
|
12167
12186
|
type: "geojson",
|
|
12168
12187
|
data: e.data
|
|
12169
12188
|
});
|
|
12170
|
-
const o = e.lineWidth ?? 3, i = e.lineColor ??
|
|
12189
|
+
const o = e.lineWidth ?? 3, i = e.lineColor ?? er(), s = e.lineOpacity ?? 1, l = e.lineBlur ?? 0, u = e.lineGapWidth ?? 0;
|
|
12171
12190
|
let c = e.lineDashArray ?? null;
|
|
12172
12191
|
const p = e.outlineWidth ?? 1, f = e.outlineColor ?? "#FFFFFF", d = e.outlineOpacity ?? 1, h = e.outlineBlur ?? 0;
|
|
12173
12192
|
if (typeof c == "string" && (c = pn(c)), e.outline === !0) {
|
|
@@ -12231,13 +12250,13 @@ function Vu(r, e) {
|
|
|
12231
12250
|
};
|
|
12232
12251
|
if (e.data && !r.getSource(t)) {
|
|
12233
12252
|
let y = e.data;
|
|
12234
|
-
typeof y == "string" &&
|
|
12253
|
+
typeof y == "string" && Ot(y) && (y = `https://api.maptiler.com/data/${y}/features.json?key=${D.apiKey}`), r.addSource(t, {
|
|
12235
12254
|
type: "geojson",
|
|
12236
12255
|
data: y
|
|
12237
12256
|
});
|
|
12238
12257
|
}
|
|
12239
12258
|
let o = e.outlineDashArray ?? null;
|
|
12240
|
-
const i = e.outlineWidth ?? 1, s = e.outlineColor ?? "#FFFFFF", l = e.outlineOpacity ?? 1, u = e.outlineBlur ?? 0, c = e.fillColor ??
|
|
12259
|
+
const i = e.outlineWidth ?? 1, s = e.outlineColor ?? "#FFFFFF", l = e.outlineOpacity ?? 1, u = e.outlineBlur ?? 0, c = e.fillColor ?? er(), p = e.fillOpacity ?? 1, f = e.outlinePosition ?? "center", d = e.pattern ?? null;
|
|
12241
12260
|
typeof o == "string" && (o = pn(o));
|
|
12242
12261
|
const h = (y = null) => {
|
|
12243
12262
|
if (r.addLayer(
|
|
@@ -12258,14 +12277,14 @@ function Vu(r, e) {
|
|
|
12258
12277
|
), e.outline === !0) {
|
|
12259
12278
|
let m;
|
|
12260
12279
|
f === "inside" ? typeof i == "number" ? m = 0.5 * i : m = z(
|
|
12261
|
-
i.map(({ zoom:
|
|
12262
|
-
zoom:
|
|
12280
|
+
i.map(({ zoom: w, value: v }) => ({
|
|
12281
|
+
zoom: w,
|
|
12263
12282
|
value: 0.5 * v
|
|
12264
12283
|
}))
|
|
12265
12284
|
) : f === "outside" ? typeof i == "number" ? m = -0.5 * i : m = z(
|
|
12266
|
-
i.map((
|
|
12267
|
-
zoom:
|
|
12268
|
-
value: -0.5 *
|
|
12285
|
+
i.map((w) => ({
|
|
12286
|
+
zoom: w.zoom,
|
|
12287
|
+
value: -0.5 * w.value
|
|
12269
12288
|
}))
|
|
12270
12289
|
) : m = 0, r.addLayer(
|
|
12271
12290
|
{
|
|
@@ -12309,7 +12328,7 @@ function Hu(r, e) {
|
|
|
12309
12328
|
throw new Error(`A layer already exists with the layer id: ${e.layerId}`);
|
|
12310
12329
|
const t = e.minPointRadius ?? 10, n = e.maxPointRadius ?? 50, a = e.cluster ?? !1, o = 20, i = Array.isArray(e.pointColor) ? e.pointColor : mo.TURBO.scale(10, e.cluster ? 1e4 : 1e3).resample("ease-out-square"), s = i.getBounds(), l = e.sourceId ?? yt(), u = e.layerId ?? mt(), c = e.showLabel ?? a, p = e.alignOnViewport ?? !0, f = e.outline ?? !1, d = e.outlineOpacity ?? 1, h = e.outlineWidth ?? 1, y = e.outlineColor ?? "#FFFFFF";
|
|
12311
12330
|
let m;
|
|
12312
|
-
const
|
|
12331
|
+
const w = e.zoomCompensation ?? !0, v = e.minzoom ?? 0, x = e.maxzoom ?? 23;
|
|
12313
12332
|
typeof e.pointOpacity == "number" ? m = e.pointOpacity : Array.isArray(e.pointOpacity) ? m = z(e.pointOpacity) : e.cluster ? m = Or(i, "point_count") : e.property ? m = Or(i, e.property) : m = z([
|
|
12314
12333
|
{ zoom: v, value: 0 },
|
|
12315
12334
|
{ zoom: v + 0.25, value: 1 },
|
|
@@ -12324,7 +12343,7 @@ function Hu(r, e) {
|
|
|
12324
12343
|
};
|
|
12325
12344
|
if (e.data && !r.getSource(l)) {
|
|
12326
12345
|
let L = e.data;
|
|
12327
|
-
typeof L == "string" &&
|
|
12346
|
+
typeof L == "string" && Ot(L) && (L = `https://api.maptiler.com/data/${L}/features.json?key=${D.apiKey}`), r.addSource(l, {
|
|
12328
12347
|
type: "geojson",
|
|
12329
12348
|
data: L,
|
|
12330
12349
|
cluster: a
|
|
@@ -12390,13 +12409,13 @@ function Hu(r, e) {
|
|
|
12390
12409
|
e.beforeId
|
|
12391
12410
|
);
|
|
12392
12411
|
} else {
|
|
12393
|
-
let L = typeof e.pointColor == "string" ? e.pointColor : Array.isArray(e.pointColor) ? e.pointColor.getColorHex(e.pointColor.getBounds().min) :
|
|
12412
|
+
let L = typeof e.pointColor == "string" ? e.pointColor : Array.isArray(e.pointColor) ? e.pointColor.getColorHex(e.pointColor.getBounds().min) : er(), $ = typeof e.pointRadius == "number" ? w ? z([
|
|
12394
12413
|
{ zoom: 0, value: e.pointRadius * 0.025 },
|
|
12395
12414
|
{ zoom: 2, value: e.pointRadius * 0.05 },
|
|
12396
12415
|
{ zoom: 4, value: e.pointRadius * 0.1 },
|
|
12397
12416
|
{ zoom: 8, value: e.pointRadius * 0.25 },
|
|
12398
12417
|
{ zoom: 16, value: e.pointRadius * 1 }
|
|
12399
|
-
]) : e.pointRadius : Array.isArray(e.pointRadius) ? z(e.pointRadius) :
|
|
12418
|
+
]) : e.pointRadius : Array.isArray(e.pointRadius) ? z(e.pointRadius) : w ? z([
|
|
12400
12419
|
{ zoom: 0, value: t * 0.05 },
|
|
12401
12420
|
{ zoom: 2, value: t * 0.1 },
|
|
12402
12421
|
{ zoom: 4, value: t * 0.2 },
|
|
@@ -12412,7 +12431,7 @@ function Hu(r, e) {
|
|
|
12412
12431
|
color: typeof e.pointColor == "string" ? e.pointColor : i.getColorHex(vt)
|
|
12413
12432
|
};
|
|
12414
12433
|
});
|
|
12415
|
-
L = Fr(Te, e.property), $ = $r(Te, e.property,
|
|
12434
|
+
L = Fr(Te, e.property), $ = $r(Te, e.property, w);
|
|
12416
12435
|
}
|
|
12417
12436
|
r.addLayer(
|
|
12418
12437
|
{
|
|
@@ -12499,13 +12518,13 @@ function Ku(r, e) {
|
|
|
12499
12518
|
], y = e.radius ?? (i ? h : 10);
|
|
12500
12519
|
let m = 1;
|
|
12501
12520
|
typeof y == "number" ? m = y : Array.isArray(y) && "zoom" in y[0] ? m = z(y) : p && Array.isArray(y) && "propertyValue" in y[0] ? m = ho(y, p, i) : !p && Array.isArray(y) && "propertyValue" in y[0] ? (m = z(h), console.warn("The option `.radius` can only be property-driven if the option `.property` is provided.")) : m = z(h);
|
|
12502
|
-
const
|
|
12521
|
+
const w = {
|
|
12503
12522
|
heatmapLayerId: n,
|
|
12504
12523
|
heatmapSourceId: t
|
|
12505
12524
|
};
|
|
12506
12525
|
if (e.data && !r.getSource(t)) {
|
|
12507
12526
|
let v = e.data;
|
|
12508
|
-
typeof v == "string" &&
|
|
12527
|
+
typeof v == "string" && Ot(v) && (v = `https://api.maptiler.com/data/${v}/features.json?key=${D.apiKey}`), r.addSource(t, {
|
|
12509
12528
|
type: "geojson",
|
|
12510
12529
|
data: v
|
|
12511
12530
|
});
|
|
@@ -12526,7 +12545,7 @@ function Ku(r, e) {
|
|
|
12526
12545
|
}
|
|
12527
12546
|
},
|
|
12528
12547
|
e.beforeId
|
|
12529
|
-
),
|
|
12548
|
+
), w;
|
|
12530
12549
|
}
|
|
12531
12550
|
const xc = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
12532
12551
|
__proto__: null,
|
|
@@ -12540,7 +12559,7 @@ const xc = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
12540
12559
|
dashArrayMaker: pn,
|
|
12541
12560
|
generateRandomLayerName: mt,
|
|
12542
12561
|
generateRandomSourceName: yt,
|
|
12543
|
-
getRandomColor:
|
|
12562
|
+
getRandomColor: er,
|
|
12544
12563
|
heatmapIntensityFromColorRamp: yo,
|
|
12545
12564
|
lerpZoomNumberValues: zr,
|
|
12546
12565
|
opacityDrivenByProperty: Or,
|
|
@@ -12553,9 +12572,9 @@ const xc = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
12553
12572
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
12554
12573
|
qo();
|
|
12555
12574
|
function kc() {
|
|
12556
|
-
return "3.
|
|
12575
|
+
return "3.6.0";
|
|
12557
12576
|
}
|
|
12558
|
-
const Cc = k.Map, Lc = k.Marker, Ac = k.Popup, Ec = k.Style, Tc = k.CanvasSource, _c = k.GeoJSONSource, Ic = k.ImageSource, Mc = k.RasterTileSource, Pc = k.RasterDEMTileSource, Rc = k.VectorTileSource, zc = k.VideoSource, Fc = k.NavigationControl, $c = k.GeolocateControl, Oc = k.AttributionControl,
|
|
12577
|
+
const Cc = k.Map, Lc = k.Marker, Ac = k.Popup, Ec = k.Style, Tc = k.CanvasSource, _c = k.GeoJSONSource, Ic = k.ImageSource, Mc = k.RasterTileSource, Pc = k.RasterDEMTileSource, Rc = k.VectorTileSource, zc = k.VideoSource, Fc = k.NavigationControl, $c = k.GeolocateControl, Oc = k.AttributionControl, Nc = k.LogoControl, jc = k.ScaleControl, Dc = k.FullscreenControl, Uc = k.TerrainControl, Bc = k.BoxZoomHandler, qc = k.ScrollZoomHandler, Gc = k.CooperativeGesturesHandler, Vc = k.KeyboardHandler, Hc = k.TwoFingersTouchPitchHandler, Kc = k.MapWheelEvent, Xc = k.MapTouchEvent, Zc = k.MapMouseEvent, Wc = k.config, Yc = k.getVersion, {
|
|
12559
12578
|
setRTLTextPlugin: Jc,
|
|
12560
12579
|
getRTLTextPluginStatus: Qc,
|
|
12561
12580
|
LngLat: ep,
|
|
@@ -12623,7 +12642,7 @@ export {
|
|
|
12623
12642
|
ep as LngLat,
|
|
12624
12643
|
tp as LngLatBounds,
|
|
12625
12644
|
ni as LogoControl,
|
|
12626
|
-
|
|
12645
|
+
Nc as LogoControlMLGL,
|
|
12627
12646
|
Mu as Map,
|
|
12628
12647
|
Cc as MapMLGL,
|
|
12629
12648
|
Sc as MapMouseEvent,
|
|
@@ -12654,7 +12673,7 @@ export {
|
|
|
12654
12673
|
Mc as RasterTileSourceMLGL,
|
|
12655
12674
|
Ip as ReferenceMapStyle,
|
|
12656
12675
|
ai as ScaleControl,
|
|
12657
|
-
|
|
12676
|
+
jc as ScaleControlMLGL,
|
|
12658
12677
|
yc as ScrollZoomHandler,
|
|
12659
12678
|
qc as ScrollZoomHandlerMLGL,
|
|
12660
12679
|
$o as SdkConfig,
|
|
@@ -12685,8 +12704,8 @@ export {
|
|
|
12685
12704
|
$p as data,
|
|
12686
12705
|
ec as displayWebGLContextLostWarning,
|
|
12687
12706
|
Op as elevation,
|
|
12688
|
-
|
|
12689
|
-
|
|
12707
|
+
Np as expandMapStyle,
|
|
12708
|
+
jp as geocoding,
|
|
12690
12709
|
Dp as geolocation,
|
|
12691
12710
|
Up as getAutoLanguage,
|
|
12692
12711
|
mn as getBrowserLanguage,
|
|
@@ -12703,7 +12722,7 @@ export {
|
|
|
12703
12722
|
mp as getWorkerCount,
|
|
12704
12723
|
wp as getWorkerUrl,
|
|
12705
12724
|
ao as gpx,
|
|
12706
|
-
|
|
12725
|
+
ju as gpxOrKml,
|
|
12707
12726
|
no as hasChildNodeWithName,
|
|
12708
12727
|
xc as helpers,
|
|
12709
12728
|
kp as importScriptInWorkers,
|