@maptiler/geocoding-control 2.0.0 → 2.1.0-rc1
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/MapLibreBasedGeocodingControl.d.ts +3027 -27
- package/icons/10pin.svg +4 -1
- package/icons/9pin.svg +4 -1
- package/icons/alcohol.svg +1 -1
- package/icons/alpine_hut.svg +1 -1
- package/icons/apartment.svg +4 -1
- package/icons/area.svg +1 -5
- package/icons/artwork.svg +4 -1
- package/icons/beauty.svg +14 -1
- package/icons/bicycle_repair_station.svg +18 -1
- package/icons/biergarten.svg +4 -1
- package/icons/books.svg +14 -1
- package/icons/bowl.svg +4 -1
- package/icons/bowling_alley.svg +4 -1
- package/icons/bus_station.svg +1 -1
- package/icons/camping.svg +1 -1
- package/icons/car_repair.svg +14 -1
- package/icons/car_wash.svg +19 -1
- package/icons/cave_entrance.svg +15 -1
- package/icons/chalet.svg +1 -1
- package/icons/chemist.svg +14 -1
- package/icons/church.svg +4 -1
- package/icons/community_centre.svg +20 -1
- package/icons/firestation.svg +4 -1
- package/icons/guest_house.svg +29 -8
- package/icons/hotel.svg +1 -1
- package/icons/housenumber.svg +19 -14
- package/icons/hut.svg +1 -4
- package/icons/medical_supply.svg +20 -1
- package/icons/memorial.svg +14 -1
- package/icons/motel.svg +19 -1
- package/icons/post.svg +1 -1
- package/icons/post_office.svg +1 -1
- package/icons/postal_code.svg +1 -23
- package/icons/public_bookcase.svg +14 -1
- package/icons/public_building.svg +4 -1
- package/icons/shintoist.svg +1 -1
- package/icons/street.svg +11 -14
- package/icons/vehicle_inspection.svg +18 -1
- package/icons/wilderness_hut.svg +1 -1
- package/leaflet-controller.d.ts +1 -1
- package/leaflet-controller.js +113 -110
- package/leaflet-controller.js.map +1 -1
- package/leaflet-controller.umd.js +2 -2
- package/leaflet-controller.umd.js.map +1 -1
- package/leaflet.d.ts +58 -5
- package/leaflet.js +1438 -1265
- package/leaflet.js.map +1 -1
- package/leaflet.umd.js +3 -3
- package/leaflet.umd.js.map +1 -1
- package/maplibregl-controller.d.ts +1 -1
- package/maplibregl-controller.js +483 -469
- package/maplibregl-controller.js.map +1 -1
- package/maplibregl-controller.umd.js +3 -3
- package/maplibregl-controller.umd.js.map +1 -1
- package/maplibregl.d.ts +2499 -13
- package/maplibregl.js +2435 -2139
- package/maplibregl.js.map +1 -1
- package/maplibregl.umd.js +3 -3
- package/maplibregl.umd.js.map +1 -1
- package/maptilersdk.d.ts +2499 -13
- package/maptilersdk.js +2432 -2139
- package/maptilersdk.js.map +1 -1
- package/maptilersdk.umd.js +3 -3
- package/maptilersdk.umd.js.map +1 -1
- package/openlayers-controller.d.ts +1 -1
- package/openlayers-controller.js +66 -63
- package/openlayers-controller.js.map +1 -1
- package/openlayers-controller.umd.js +2 -2
- package/openlayers-controller.umd.js.map +1 -1
- package/openlayers.d.ts +53 -1
- package/openlayers.js +2046 -1902
- package/openlayers.js.map +1 -1
- package/openlayers.umd.js +3 -3
- package/openlayers.umd.js.map +1 -1
- package/package.json +28 -28
- package/react.d.ts +31 -5
- package/react.js +1252 -1096
- package/react.js.map +1 -1
- package/react.umd.js +1 -1
- package/react.umd.js.map +1 -1
- package/style.css +1 -1
- package/svelte/FeatureItem.svelte +60 -13
- package/svelte/FeatureItem.svelte.d.ts +4 -4
- package/svelte/GeocodingControl.svelte +166 -98
- package/svelte/GeocodingControl.svelte.d.ts +36 -16
- package/svelte/MapLibreBasedGeocodingControl.d.ts +3027 -27
- package/svelte/MapLibreBasedGeocodingControl.js +154 -21
- package/svelte/leaflet-controller.d.ts +1 -1
- package/svelte/leaflet-controller.js +6 -3
- package/svelte/leaflet.d.ts +58 -5
- package/svelte/leaflet.js +52 -21
- package/svelte/maplibregl-controller.d.ts +1 -1
- package/svelte/maplibregl-controller.js +47 -38
- package/svelte/maplibregl.d.ts +2499 -13
- package/svelte/maplibregl.js +11 -3
- package/svelte/maptilersdk.d.ts +2499 -13
- package/svelte/maptilersdk.js +11 -3
- package/svelte/openlayers-controller.d.ts +1 -1
- package/svelte/openlayers-controller.js +7 -4
- package/svelte/openlayers.d.ts +53 -1
- package/svelte/openlayers.js +66 -48
- package/svelte/react.d.ts +31 -5
- package/svelte/react.js +21 -9
- package/svelte/types.d.ts +106 -35
- package/svelte/vanilla.d.ts +46 -2
- package/svelte/vanilla.js +66 -10
- package/types.d.ts +106 -35
- package/vanilla.d.ts +46 -2
- package/vanilla.js +1260 -1057
- package/vanilla.js.map +1 -1
- package/vanilla.umd.js +1 -1
- package/vanilla.umd.js.map +1 -1
- package/icons/aerodrome.12.svg +0 -1
- package/icons/bus_stop.12.svg +0 -1
- package/icons/elevator.12.svg +0 -1
- /package/icons/{helipad.16.svg → helipad.svg} +0 -0
- /package/icons/{traffic_light.13.svg → traffic_light.svg} +0 -0
package/leaflet.js
CHANGED
|
@@ -1,52 +1,52 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
1
|
+
var En = Object.defineProperty;
|
|
2
|
+
var ti = (i) => {
|
|
3
3
|
throw TypeError(i);
|
|
4
4
|
};
|
|
5
|
-
var
|
|
6
|
-
var
|
|
7
|
-
var
|
|
8
|
-
import * as
|
|
9
|
-
function
|
|
5
|
+
var Ln = (i, e, t) => e in i ? En(i, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : i[e] = t;
|
|
6
|
+
var kt = (i, e, t) => Ln(i, typeof e != "symbol" ? e + "" : e, t), ii = (i, e, t) => e.has(i) || ti("Cannot " + t);
|
|
7
|
+
var te = (i, e, t) => (ii(i, e, "read from private field"), t ? t.call(i) : e.get(i)), Nt = (i, e, t) => e.has(i) ? ti("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(i) : e.set(i, t), Pt = (i, e, t, n) => (ii(i, e, "write to private field"), n ? n.call(i, t) : e.set(i, t), t);
|
|
8
|
+
import * as ue from "leaflet";
|
|
9
|
+
function D() {
|
|
10
10
|
}
|
|
11
|
-
function
|
|
11
|
+
function Sn(i, e) {
|
|
12
12
|
for (const t in e) i[t] = e[t];
|
|
13
13
|
return (
|
|
14
14
|
/** @type {T & S} */
|
|
15
15
|
i
|
|
16
16
|
);
|
|
17
17
|
}
|
|
18
|
-
function
|
|
18
|
+
function Ai(i) {
|
|
19
19
|
return i();
|
|
20
20
|
}
|
|
21
|
-
function
|
|
21
|
+
function ni() {
|
|
22
22
|
return /* @__PURE__ */ Object.create(null);
|
|
23
23
|
}
|
|
24
|
-
function
|
|
25
|
-
i.forEach(
|
|
24
|
+
function be(i) {
|
|
25
|
+
i.forEach(Ai);
|
|
26
26
|
}
|
|
27
|
-
function
|
|
27
|
+
function Wi(i) {
|
|
28
28
|
return typeof i == "function";
|
|
29
29
|
}
|
|
30
|
-
function
|
|
30
|
+
function Me(i, e) {
|
|
31
31
|
return i != i ? e == e : i !== e || i && typeof i == "object" || typeof i == "function";
|
|
32
32
|
}
|
|
33
|
-
let
|
|
33
|
+
let lt;
|
|
34
34
|
function X(i, e) {
|
|
35
|
-
return i === e ? !0 : (
|
|
35
|
+
return i === e ? !0 : (lt || (lt = document.createElement("a")), lt.href = e, i === lt.href);
|
|
36
36
|
}
|
|
37
|
-
function
|
|
37
|
+
function xn(i) {
|
|
38
38
|
return Object.keys(i).length === 0;
|
|
39
39
|
}
|
|
40
|
-
function
|
|
40
|
+
function Mn(i, e, t, n) {
|
|
41
41
|
if (i) {
|
|
42
|
-
const r =
|
|
42
|
+
const r = Bi(i, e, t, n);
|
|
43
43
|
return i[0](r);
|
|
44
44
|
}
|
|
45
45
|
}
|
|
46
|
-
function
|
|
47
|
-
return i[1] && n ?
|
|
46
|
+
function Bi(i, e, t, n) {
|
|
47
|
+
return i[1] && n ? Sn(t.ctx.slice(), i[1](n(e))) : t.ctx;
|
|
48
48
|
}
|
|
49
|
-
function
|
|
49
|
+
function Cn(i, e, t, n) {
|
|
50
50
|
if (i[2] && n) {
|
|
51
51
|
const r = i[2](n(t));
|
|
52
52
|
if (e.dirty === void 0)
|
|
@@ -61,13 +61,13 @@ function pn(i, e, t, n) {
|
|
|
61
61
|
}
|
|
62
62
|
return e.dirty;
|
|
63
63
|
}
|
|
64
|
-
function
|
|
64
|
+
function kn(i, e, t, n, r, o) {
|
|
65
65
|
if (r) {
|
|
66
|
-
const l =
|
|
66
|
+
const l = Bi(e, t, n, o);
|
|
67
67
|
i.p(l, r);
|
|
68
68
|
}
|
|
69
69
|
}
|
|
70
|
-
function
|
|
70
|
+
function Nn(i) {
|
|
71
71
|
if (i.ctx.length > 32) {
|
|
72
72
|
const e = [], t = i.ctx.length / 32;
|
|
73
73
|
for (let n = 0; n < t; n++)
|
|
@@ -76,77 +76,77 @@ function bn(i) {
|
|
|
76
76
|
}
|
|
77
77
|
return -1;
|
|
78
78
|
}
|
|
79
|
-
function
|
|
79
|
+
function dt(i) {
|
|
80
80
|
return i ?? "";
|
|
81
81
|
}
|
|
82
|
-
function
|
|
82
|
+
function I(i, e) {
|
|
83
83
|
i.appendChild(e);
|
|
84
84
|
}
|
|
85
85
|
function F(i, e, t) {
|
|
86
86
|
i.insertBefore(e, t || null);
|
|
87
87
|
}
|
|
88
|
-
function
|
|
88
|
+
function U(i) {
|
|
89
89
|
i.parentNode && i.parentNode.removeChild(i);
|
|
90
90
|
}
|
|
91
|
-
function
|
|
91
|
+
function B(i) {
|
|
92
92
|
return document.createElement(i);
|
|
93
93
|
}
|
|
94
|
-
function
|
|
94
|
+
function ce(i) {
|
|
95
95
|
return document.createElementNS("http://www.w3.org/2000/svg", i);
|
|
96
96
|
}
|
|
97
|
-
function
|
|
97
|
+
function Le(i) {
|
|
98
98
|
return document.createTextNode(i);
|
|
99
99
|
}
|
|
100
|
-
function
|
|
101
|
-
return
|
|
100
|
+
function ne() {
|
|
101
|
+
return Le(" ");
|
|
102
102
|
}
|
|
103
|
-
function
|
|
104
|
-
return
|
|
103
|
+
function Pn() {
|
|
104
|
+
return Le("");
|
|
105
105
|
}
|
|
106
|
-
function
|
|
106
|
+
function H(i, e, t, n) {
|
|
107
107
|
return i.addEventListener(e, t, n), () => i.removeEventListener(e, t, n);
|
|
108
108
|
}
|
|
109
|
-
function
|
|
109
|
+
function Tn(i) {
|
|
110
110
|
return function(e) {
|
|
111
111
|
return e.preventDefault(), i.call(this, e);
|
|
112
112
|
};
|
|
113
113
|
}
|
|
114
|
-
function
|
|
114
|
+
function p(i, e, t) {
|
|
115
115
|
t == null ? i.removeAttribute(e) : i.getAttribute(e) !== t && i.setAttribute(e, t);
|
|
116
116
|
}
|
|
117
|
-
function
|
|
117
|
+
function Rn(i) {
|
|
118
118
|
return Array.from(i.childNodes);
|
|
119
119
|
}
|
|
120
|
-
function
|
|
120
|
+
function Ze(i, e) {
|
|
121
121
|
e = "" + e, i.data !== e && (i.data = /** @type {string} */
|
|
122
122
|
e);
|
|
123
123
|
}
|
|
124
|
-
function
|
|
124
|
+
function ri(i, e) {
|
|
125
125
|
i.value = e ?? "";
|
|
126
126
|
}
|
|
127
|
-
function
|
|
127
|
+
function he(i, e, t) {
|
|
128
128
|
i.classList.toggle(e, !!t);
|
|
129
129
|
}
|
|
130
|
-
function
|
|
130
|
+
function On(i, e, { bubbles: t = !1, cancelable: n = !1 } = {}) {
|
|
131
131
|
return new CustomEvent(i, { detail: e, bubbles: t, cancelable: n });
|
|
132
132
|
}
|
|
133
|
-
let
|
|
134
|
-
function
|
|
135
|
-
|
|
133
|
+
let Qe;
|
|
134
|
+
function qe(i) {
|
|
135
|
+
Qe = i;
|
|
136
136
|
}
|
|
137
|
-
function
|
|
138
|
-
if (!
|
|
139
|
-
return
|
|
137
|
+
function Di() {
|
|
138
|
+
if (!Qe) throw new Error("Function called outside component initialization");
|
|
139
|
+
return Qe;
|
|
140
140
|
}
|
|
141
|
-
function
|
|
142
|
-
|
|
141
|
+
function In(i) {
|
|
142
|
+
Di().$$.on_destroy.push(i);
|
|
143
143
|
}
|
|
144
|
-
function
|
|
145
|
-
const i =
|
|
144
|
+
function Ui() {
|
|
145
|
+
const i = Di();
|
|
146
146
|
return (e, t, { cancelable: n = !1 } = {}) => {
|
|
147
147
|
const r = i.$$.callbacks[e];
|
|
148
148
|
if (r) {
|
|
149
|
-
const o =
|
|
149
|
+
const o = On(
|
|
150
150
|
/** @type {string} */
|
|
151
151
|
e,
|
|
152
152
|
t,
|
|
@@ -159,142 +159,142 @@ function xn() {
|
|
|
159
159
|
return !0;
|
|
160
160
|
};
|
|
161
161
|
}
|
|
162
|
-
function
|
|
162
|
+
function zn(i, e) {
|
|
163
163
|
const t = i.$$.callbacks[e.type];
|
|
164
164
|
t && t.slice().forEach((n) => n.call(this, e));
|
|
165
165
|
}
|
|
166
|
-
const
|
|
167
|
-
let
|
|
168
|
-
const
|
|
169
|
-
let
|
|
170
|
-
function
|
|
171
|
-
|
|
166
|
+
const Be = [], It = [];
|
|
167
|
+
let De = [];
|
|
168
|
+
const oi = [], An = /* @__PURE__ */ Promise.resolve();
|
|
169
|
+
let zt = !1;
|
|
170
|
+
function Wn() {
|
|
171
|
+
zt || (zt = !0, An.then(Fi));
|
|
172
172
|
}
|
|
173
|
-
function
|
|
174
|
-
|
|
173
|
+
function At(i) {
|
|
174
|
+
De.push(i);
|
|
175
175
|
}
|
|
176
|
-
const
|
|
177
|
-
let
|
|
178
|
-
function
|
|
179
|
-
if (
|
|
176
|
+
const Tt = /* @__PURE__ */ new Set();
|
|
177
|
+
let Ae = 0;
|
|
178
|
+
function Fi() {
|
|
179
|
+
if (Ae !== 0)
|
|
180
180
|
return;
|
|
181
|
-
const i =
|
|
181
|
+
const i = Qe;
|
|
182
182
|
do {
|
|
183
183
|
try {
|
|
184
|
-
for (;
|
|
185
|
-
const e = Ae
|
|
186
|
-
|
|
184
|
+
for (; Ae < Be.length; ) {
|
|
185
|
+
const e = Be[Ae];
|
|
186
|
+
Ae++, qe(e), Bn(e.$$);
|
|
187
187
|
}
|
|
188
188
|
} catch (e) {
|
|
189
|
-
throw
|
|
189
|
+
throw Be.length = 0, Ae = 0, e;
|
|
190
190
|
}
|
|
191
|
-
for (
|
|
192
|
-
for (let e = 0; e <
|
|
193
|
-
const t =
|
|
194
|
-
|
|
191
|
+
for (qe(null), Be.length = 0, Ae = 0; It.length; ) It.pop()();
|
|
192
|
+
for (let e = 0; e < De.length; e += 1) {
|
|
193
|
+
const t = De[e];
|
|
194
|
+
Tt.has(t) || (Tt.add(t), t());
|
|
195
195
|
}
|
|
196
|
-
|
|
197
|
-
} while (
|
|
198
|
-
for (;
|
|
199
|
-
|
|
200
|
-
|
|
196
|
+
De.length = 0;
|
|
197
|
+
} while (Be.length);
|
|
198
|
+
for (; oi.length; )
|
|
199
|
+
oi.pop()();
|
|
200
|
+
zt = !1, Tt.clear(), qe(i);
|
|
201
201
|
}
|
|
202
|
-
function
|
|
202
|
+
function Bn(i) {
|
|
203
203
|
if (i.fragment !== null) {
|
|
204
|
-
i.update(),
|
|
204
|
+
i.update(), be(i.before_update);
|
|
205
205
|
const e = i.dirty;
|
|
206
|
-
i.dirty = [-1], i.fragment && i.fragment.p(i.ctx, e), i.after_update.forEach(
|
|
206
|
+
i.dirty = [-1], i.fragment && i.fragment.p(i.ctx, e), i.after_update.forEach(At);
|
|
207
207
|
}
|
|
208
208
|
}
|
|
209
|
-
function
|
|
209
|
+
function Dn(i) {
|
|
210
210
|
const e = [], t = [];
|
|
211
|
-
|
|
211
|
+
De.forEach((n) => i.indexOf(n) === -1 ? e.push(n) : t.push(n)), t.forEach((n) => n()), De = e;
|
|
212
212
|
}
|
|
213
|
-
const
|
|
214
|
-
let
|
|
215
|
-
function
|
|
216
|
-
|
|
213
|
+
const ut = /* @__PURE__ */ new Set();
|
|
214
|
+
let Te;
|
|
215
|
+
function at() {
|
|
216
|
+
Te = {
|
|
217
217
|
r: 0,
|
|
218
218
|
c: [],
|
|
219
|
-
p:
|
|
219
|
+
p: Te
|
|
220
220
|
// parent group
|
|
221
221
|
};
|
|
222
222
|
}
|
|
223
|
-
function
|
|
224
|
-
|
|
223
|
+
function ct() {
|
|
224
|
+
Te.r || be(Te.c), Te = Te.p;
|
|
225
225
|
}
|
|
226
226
|
function Z(i, e) {
|
|
227
|
-
i && i.i && (
|
|
227
|
+
i && i.i && (ut.delete(i), i.i(e));
|
|
228
228
|
}
|
|
229
229
|
function V(i, e, t, n) {
|
|
230
230
|
if (i && i.o) {
|
|
231
|
-
if (
|
|
232
|
-
|
|
233
|
-
|
|
231
|
+
if (ut.has(i)) return;
|
|
232
|
+
ut.add(i), Te.c.push(() => {
|
|
233
|
+
ut.delete(i), n && (t && i.d(1), n());
|
|
234
234
|
}), i.o(e);
|
|
235
235
|
} else n && n();
|
|
236
236
|
}
|
|
237
|
-
function
|
|
237
|
+
function si(i) {
|
|
238
238
|
return (i == null ? void 0 : i.length) !== void 0 ? i : Array.from(i);
|
|
239
239
|
}
|
|
240
|
-
function
|
|
240
|
+
function Un(i, e) {
|
|
241
241
|
V(i, 1, 1, () => {
|
|
242
242
|
e.delete(i.key);
|
|
243
243
|
});
|
|
244
244
|
}
|
|
245
|
-
function
|
|
245
|
+
function Fn(i, e, t, n, r, o, l, s, c, u, h, a) {
|
|
246
246
|
let f = i.length, d = o.length, m = f;
|
|
247
|
-
const
|
|
248
|
-
for (; m--; )
|
|
249
|
-
const
|
|
247
|
+
const b = {};
|
|
248
|
+
for (; m--; ) b[i[m].key] = m;
|
|
249
|
+
const v = [], y = /* @__PURE__ */ new Map(), E = /* @__PURE__ */ new Map(), _ = [];
|
|
250
250
|
for (m = d; m--; ) {
|
|
251
|
-
const
|
|
252
|
-
let
|
|
253
|
-
|
|
251
|
+
const x = a(r, o, m), S = t(x);
|
|
252
|
+
let T = l.get(S);
|
|
253
|
+
T ? _.push(() => T.p(x, e)) : (T = u(S, x), T.c()), y.set(S, v[m] = T), S in b && E.set(S, Math.abs(m - b[S]));
|
|
254
254
|
}
|
|
255
|
-
const
|
|
256
|
-
function x
|
|
257
|
-
Z(
|
|
255
|
+
const L = /* @__PURE__ */ new Set(), P = /* @__PURE__ */ new Set();
|
|
256
|
+
function N(x) {
|
|
257
|
+
Z(x, 1), x.m(s, h), l.set(x.key, x), h = x.first, d--;
|
|
258
258
|
}
|
|
259
259
|
for (; f && d; ) {
|
|
260
|
-
const
|
|
261
|
-
|
|
260
|
+
const x = v[d - 1], S = i[f - 1], T = x.key, w = S.key;
|
|
261
|
+
x === S ? (h = x.first, f--, d--) : y.has(w) ? !l.has(T) || L.has(T) ? N(x) : P.has(w) ? f-- : E.get(T) > E.get(w) ? (P.add(T), N(x)) : (L.add(w), f--) : (c(S, l), f--);
|
|
262
262
|
}
|
|
263
263
|
for (; f--; ) {
|
|
264
|
-
const
|
|
265
|
-
|
|
264
|
+
const x = i[f];
|
|
265
|
+
y.has(x.key) || c(x, l);
|
|
266
266
|
}
|
|
267
|
-
for (; d; )
|
|
268
|
-
return
|
|
267
|
+
for (; d; ) N(v[d - 1]);
|
|
268
|
+
return be(_), v;
|
|
269
269
|
}
|
|
270
|
-
function
|
|
270
|
+
function Se(i) {
|
|
271
271
|
i && i.c();
|
|
272
272
|
}
|
|
273
|
-
function
|
|
273
|
+
function pe(i, e, t) {
|
|
274
274
|
const { fragment: n, after_update: r } = i.$$;
|
|
275
|
-
n && n.m(e, t),
|
|
276
|
-
const o = i.$$.on_mount.map(
|
|
277
|
-
i.$$.on_destroy ? i.$$.on_destroy.push(...o) :
|
|
278
|
-
}), r.forEach(
|
|
275
|
+
n && n.m(e, t), At(() => {
|
|
276
|
+
const o = i.$$.on_mount.map(Ai).filter(Wi);
|
|
277
|
+
i.$$.on_destroy ? i.$$.on_destroy.push(...o) : be(o), i.$$.on_mount = [];
|
|
278
|
+
}), r.forEach(At);
|
|
279
279
|
}
|
|
280
|
-
function
|
|
280
|
+
function ye(i, e) {
|
|
281
281
|
const t = i.$$;
|
|
282
|
-
t.fragment !== null && (
|
|
282
|
+
t.fragment !== null && (Dn(t.after_update), be(t.on_destroy), t.fragment && t.fragment.d(e), t.on_destroy = t.fragment = null, t.ctx = []);
|
|
283
283
|
}
|
|
284
|
-
function
|
|
285
|
-
i.$$.dirty[0] === -1 && (
|
|
284
|
+
function Gn(i, e) {
|
|
285
|
+
i.$$.dirty[0] === -1 && (Be.push(i), Wn(), i.$$.dirty.fill(0)), i.$$.dirty[e / 31 | 0] |= 1 << e % 31;
|
|
286
286
|
}
|
|
287
|
-
function
|
|
288
|
-
const c =
|
|
289
|
-
|
|
287
|
+
function Ce(i, e, t, n, r, o, l = null, s = [-1]) {
|
|
288
|
+
const c = Qe;
|
|
289
|
+
qe(i);
|
|
290
290
|
const u = i.$$ = {
|
|
291
291
|
fragment: null,
|
|
292
292
|
ctx: [],
|
|
293
293
|
// state
|
|
294
294
|
props: o,
|
|
295
|
-
update:
|
|
295
|
+
update: D,
|
|
296
296
|
not_equal: r,
|
|
297
|
-
bound:
|
|
297
|
+
bound: ni(),
|
|
298
298
|
// lifecycle
|
|
299
299
|
on_mount: [],
|
|
300
300
|
on_destroy: [],
|
|
@@ -303,7 +303,7 @@ function xe(i, e, t, n, r, o, l = null, s = [-1]) {
|
|
|
303
303
|
after_update: [],
|
|
304
304
|
context: new Map(e.context || (c ? c.$$.context : [])),
|
|
305
305
|
// everything else
|
|
306
|
-
callbacks:
|
|
306
|
+
callbacks: ni(),
|
|
307
307
|
dirty: s,
|
|
308
308
|
skip_bound: !1,
|
|
309
309
|
root: e.target || c.$$.root
|
|
@@ -312,18 +312,18 @@ function xe(i, e, t, n, r, o, l = null, s = [-1]) {
|
|
|
312
312
|
let h = !1;
|
|
313
313
|
if (u.ctx = t ? t(i, e.props || {}, (a, f, ...d) => {
|
|
314
314
|
const m = d.length ? d[0] : f;
|
|
315
|
-
return u.ctx && r(u.ctx[a], u.ctx[a] = m) && (!u.skip_bound && u.bound[a] && u.bound[a](m), h &&
|
|
316
|
-
}) : [], u.update(), h = !0,
|
|
315
|
+
return u.ctx && r(u.ctx[a], u.ctx[a] = m) && (!u.skip_bound && u.bound[a] && u.bound[a](m), h && Gn(i, a)), f;
|
|
316
|
+
}) : [], u.update(), h = !0, be(u.before_update), u.fragment = n ? n(u.ctx) : !1, e.target) {
|
|
317
317
|
if (e.hydrate) {
|
|
318
|
-
const a =
|
|
319
|
-
u.fragment && u.fragment.l(a), a.forEach(
|
|
318
|
+
const a = Rn(e.target);
|
|
319
|
+
u.fragment && u.fragment.l(a), a.forEach(U);
|
|
320
320
|
} else
|
|
321
321
|
u.fragment && u.fragment.c();
|
|
322
|
-
e.intro && Z(i.$$.fragment),
|
|
322
|
+
e.intro && Z(i.$$.fragment), pe(i, e.target, e.anchor), Fi();
|
|
323
323
|
}
|
|
324
|
-
|
|
324
|
+
qe(c);
|
|
325
325
|
}
|
|
326
|
-
class
|
|
326
|
+
class ke {
|
|
327
327
|
constructor() {
|
|
328
328
|
/**
|
|
329
329
|
* ### PRIVATE API
|
|
@@ -332,7 +332,7 @@ class Me {
|
|
|
332
332
|
*
|
|
333
333
|
* @type {any}
|
|
334
334
|
*/
|
|
335
|
-
|
|
335
|
+
kt(this, "$$");
|
|
336
336
|
/**
|
|
337
337
|
* ### PRIVATE API
|
|
338
338
|
*
|
|
@@ -340,11 +340,11 @@ class Me {
|
|
|
340
340
|
*
|
|
341
341
|
* @type {any}
|
|
342
342
|
*/
|
|
343
|
-
|
|
343
|
+
kt(this, "$$set");
|
|
344
344
|
}
|
|
345
345
|
/** @returns {void} */
|
|
346
346
|
$destroy() {
|
|
347
|
-
|
|
347
|
+
ye(this, 1), this.$destroy = D;
|
|
348
348
|
}
|
|
349
349
|
/**
|
|
350
350
|
* @template {Extract<keyof Events, string>} K
|
|
@@ -353,8 +353,8 @@ class Me {
|
|
|
353
353
|
* @returns {() => void}
|
|
354
354
|
*/
|
|
355
355
|
$on(e, t) {
|
|
356
|
-
if (!
|
|
357
|
-
return
|
|
356
|
+
if (!Wi(t))
|
|
357
|
+
return D;
|
|
358
358
|
const n = this.$$.callbacks[e] || (this.$$.callbacks[e] = []);
|
|
359
359
|
return n.push(t), () => {
|
|
360
360
|
const r = n.indexOf(t);
|
|
@@ -366,66 +366,71 @@ class Me {
|
|
|
366
366
|
* @returns {void}
|
|
367
367
|
*/
|
|
368
368
|
$set(e) {
|
|
369
|
-
this.$$set && !
|
|
369
|
+
this.$$set && !xn(e) && (this.$$.skip_bound = !0, this.$$set(e), this.$$.skip_bound = !1);
|
|
370
370
|
}
|
|
371
371
|
}
|
|
372
|
-
const
|
|
373
|
-
typeof window < "u" && (window.__svelte || (window.__svelte = { v: /* @__PURE__ */ new Set() })).v.add(
|
|
374
|
-
function
|
|
372
|
+
const jn = "4";
|
|
373
|
+
typeof window < "u" && (window.__svelte || (window.__svelte = { v: /* @__PURE__ */ new Set() })).v.add(jn);
|
|
374
|
+
function qn(i) {
|
|
375
375
|
let e, t;
|
|
376
376
|
return {
|
|
377
377
|
c() {
|
|
378
|
-
e =
|
|
378
|
+
e = ce("svg"), t = ce("path"), p(t, "d", "M13.12.706a.982.982 0 0 0-1.391 0L6.907 5.517 2.087.696a.982.982 0 1 0-1.391 1.39l4.821 4.821L.696 11.73a.982.982 0 1 0 1.39 1.39l4.821-4.821 4.822 4.821a.982.982 0 1 0 1.39-1.39L8.298 6.908l4.821-4.822a.988.988 0 0 0 0-1.38Z"), p(e, "viewBox", "0 0 14 14"), p(e, "width", "13"), p(e, "height", "13"), p(e, "class", "svelte-en2qvf");
|
|
379
379
|
},
|
|
380
380
|
m(n, r) {
|
|
381
|
-
F(n, e, r),
|
|
381
|
+
F(n, e, r), I(e, t);
|
|
382
382
|
},
|
|
383
|
-
p:
|
|
384
|
-
i:
|
|
385
|
-
o:
|
|
383
|
+
p: D,
|
|
384
|
+
i: D,
|
|
385
|
+
o: D,
|
|
386
386
|
d(n) {
|
|
387
|
-
n &&
|
|
387
|
+
n && U(e);
|
|
388
388
|
}
|
|
389
389
|
};
|
|
390
390
|
}
|
|
391
|
-
class
|
|
391
|
+
class Gi extends ke {
|
|
392
392
|
constructor(e) {
|
|
393
|
-
super(),
|
|
393
|
+
super(), Ce(this, e, null, qn, Me, {});
|
|
394
394
|
}
|
|
395
395
|
}
|
|
396
|
-
function
|
|
396
|
+
function Zn(i) {
|
|
397
397
|
let e, t;
|
|
398
398
|
return {
|
|
399
399
|
c() {
|
|
400
|
-
e =
|
|
400
|
+
e = ce("svg"), t = ce("path"), p(t, "d", "M15 0C6.705 0 0 6.705 0 15C0 23.295 6.705 30 15 30C23.295 30 30 23.295 30 15C30 6.705 23.295 0 15 0ZM22.5 20.385L20.385 22.5L15 17.115L9.615 22.5L7.5 20.385L12.885 15L7.5 9.615L9.615 7.5L15 12.885L20.385 7.5L22.5 9.615L17.115 15L22.5 20.385Z"), p(e, "viewBox", "0 0 30 30"), p(e, "fill", "none"), p(e, "xmlns", "http://www.w3.org/2000/svg"), p(e, "class", "svelte-d2loi5");
|
|
401
401
|
},
|
|
402
402
|
m(n, r) {
|
|
403
|
-
F(n, e, r),
|
|
403
|
+
F(n, e, r), I(e, t);
|
|
404
404
|
},
|
|
405
|
-
p:
|
|
406
|
-
i:
|
|
407
|
-
o:
|
|
405
|
+
p: D,
|
|
406
|
+
i: D,
|
|
407
|
+
o: D,
|
|
408
408
|
d(n) {
|
|
409
|
-
n &&
|
|
409
|
+
n && U(e);
|
|
410
410
|
}
|
|
411
411
|
};
|
|
412
412
|
}
|
|
413
|
-
class
|
|
413
|
+
class ji extends ke {
|
|
414
414
|
constructor(e) {
|
|
415
|
-
super(),
|
|
415
|
+
super(), Ce(this, e, null, Zn, Me, {});
|
|
416
416
|
}
|
|
417
417
|
}
|
|
418
|
-
function
|
|
418
|
+
function Qn(i) {
|
|
419
419
|
let e, t;
|
|
420
420
|
return {
|
|
421
421
|
c() {
|
|
422
|
-
e =
|
|
423
|
-
i[3] + "area.svg") ||
|
|
422
|
+
e = B("img"), X(e.src, t = /*iconsBaseUrl*/
|
|
423
|
+
i[3] + "area.svg") || p(e, "src", t), p(
|
|
424
424
|
e,
|
|
425
425
|
"alt",
|
|
426
426
|
/*placeType*/
|
|
427
427
|
i[6]
|
|
428
|
-
),
|
|
428
|
+
), p(
|
|
429
|
+
e,
|
|
430
|
+
"title",
|
|
431
|
+
/*placeType*/
|
|
432
|
+
i[6]
|
|
433
|
+
), p(e, "class", "svelte-z7p9pp");
|
|
429
434
|
},
|
|
430
435
|
m(n, r) {
|
|
431
436
|
F(n, e, r);
|
|
@@ -433,30 +438,41 @@ function An(i) {
|
|
|
433
438
|
p(n, r) {
|
|
434
439
|
r & /*iconsBaseUrl*/
|
|
435
440
|
8 && !X(e.src, t = /*iconsBaseUrl*/
|
|
436
|
-
n[3] + "area.svg") &&
|
|
437
|
-
64 &&
|
|
441
|
+
n[3] + "area.svg") && p(e, "src", t), r & /*placeType*/
|
|
442
|
+
64 && p(
|
|
438
443
|
e,
|
|
439
444
|
"alt",
|
|
440
445
|
/*placeType*/
|
|
441
446
|
n[6]
|
|
447
|
+
), r & /*placeType*/
|
|
448
|
+
64 && p(
|
|
449
|
+
e,
|
|
450
|
+
"title",
|
|
451
|
+
/*placeType*/
|
|
452
|
+
n[6]
|
|
442
453
|
);
|
|
443
454
|
},
|
|
444
455
|
d(n) {
|
|
445
|
-
n &&
|
|
456
|
+
n && U(e);
|
|
446
457
|
}
|
|
447
458
|
};
|
|
448
459
|
}
|
|
449
|
-
function
|
|
460
|
+
function Hn(i) {
|
|
450
461
|
let e, t;
|
|
451
462
|
return {
|
|
452
463
|
c() {
|
|
453
|
-
e =
|
|
454
|
-
i[3] + "reverse.svg") ||
|
|
464
|
+
e = B("img"), X(e.src, t = /*iconsBaseUrl*/
|
|
465
|
+
i[3] + "reverse.svg") || p(e, "src", t), p(
|
|
455
466
|
e,
|
|
456
467
|
"alt",
|
|
457
468
|
/*placeType*/
|
|
458
469
|
i[6]
|
|
459
|
-
),
|
|
470
|
+
), p(
|
|
471
|
+
e,
|
|
472
|
+
"title",
|
|
473
|
+
/*placeType*/
|
|
474
|
+
i[6]
|
|
475
|
+
), p(e, "class", "svelte-z7p9pp");
|
|
460
476
|
},
|
|
461
477
|
m(n, r) {
|
|
462
478
|
F(n, e, r);
|
|
@@ -464,30 +480,41 @@ function Bn(i) {
|
|
|
464
480
|
p(n, r) {
|
|
465
481
|
r & /*iconsBaseUrl*/
|
|
466
482
|
8 && !X(e.src, t = /*iconsBaseUrl*/
|
|
467
|
-
n[3] + "reverse.svg") &&
|
|
468
|
-
64 &&
|
|
483
|
+
n[3] + "reverse.svg") && p(e, "src", t), r & /*placeType*/
|
|
484
|
+
64 && p(
|
|
469
485
|
e,
|
|
470
486
|
"alt",
|
|
471
487
|
/*placeType*/
|
|
472
488
|
n[6]
|
|
489
|
+
), r & /*placeType*/
|
|
490
|
+
64 && p(
|
|
491
|
+
e,
|
|
492
|
+
"title",
|
|
493
|
+
/*placeType*/
|
|
494
|
+
n[6]
|
|
473
495
|
);
|
|
474
496
|
},
|
|
475
497
|
d(n) {
|
|
476
|
-
n &&
|
|
498
|
+
n && U(e);
|
|
477
499
|
}
|
|
478
500
|
};
|
|
479
501
|
}
|
|
480
|
-
function
|
|
502
|
+
function Vn(i) {
|
|
481
503
|
let e, t;
|
|
482
504
|
return {
|
|
483
505
|
c() {
|
|
484
|
-
e =
|
|
485
|
-
i[3] + "poi.svg") ||
|
|
506
|
+
e = B("img"), X(e.src, t = /*iconsBaseUrl*/
|
|
507
|
+
i[3] + "poi.svg") || p(e, "src", t), p(
|
|
486
508
|
e,
|
|
487
509
|
"alt",
|
|
488
510
|
/*placeType*/
|
|
489
511
|
i[6]
|
|
490
|
-
),
|
|
512
|
+
), p(
|
|
513
|
+
e,
|
|
514
|
+
"title",
|
|
515
|
+
/*placeType*/
|
|
516
|
+
i[6]
|
|
517
|
+
), p(e, "class", "svelte-z7p9pp");
|
|
491
518
|
},
|
|
492
519
|
m(n, r) {
|
|
493
520
|
F(n, e, r);
|
|
@@ -495,30 +522,41 @@ function Dn(i) {
|
|
|
495
522
|
p(n, r) {
|
|
496
523
|
r & /*iconsBaseUrl*/
|
|
497
524
|
8 && !X(e.src, t = /*iconsBaseUrl*/
|
|
498
|
-
n[3] + "poi.svg") &&
|
|
499
|
-
64 &&
|
|
525
|
+
n[3] + "poi.svg") && p(e, "src", t), r & /*placeType*/
|
|
526
|
+
64 && p(
|
|
500
527
|
e,
|
|
501
528
|
"alt",
|
|
502
529
|
/*placeType*/
|
|
503
530
|
n[6]
|
|
531
|
+
), r & /*placeType*/
|
|
532
|
+
64 && p(
|
|
533
|
+
e,
|
|
534
|
+
"title",
|
|
535
|
+
/*placeType*/
|
|
536
|
+
n[6]
|
|
504
537
|
);
|
|
505
538
|
},
|
|
506
539
|
d(n) {
|
|
507
|
-
n &&
|
|
540
|
+
n && U(e);
|
|
508
541
|
}
|
|
509
542
|
};
|
|
510
543
|
}
|
|
511
|
-
function
|
|
544
|
+
function Yn(i) {
|
|
512
545
|
let e, t;
|
|
513
546
|
return {
|
|
514
547
|
c() {
|
|
515
|
-
e =
|
|
516
|
-
i[3] + "postal_code.svg") ||
|
|
548
|
+
e = B("img"), X(e.src, t = /*iconsBaseUrl*/
|
|
549
|
+
i[3] + "postal_code.svg") || p(e, "src", t), p(
|
|
517
550
|
e,
|
|
518
551
|
"alt",
|
|
519
552
|
/*placeType*/
|
|
520
553
|
i[6]
|
|
521
|
-
),
|
|
554
|
+
), p(
|
|
555
|
+
e,
|
|
556
|
+
"title",
|
|
557
|
+
/*placeType*/
|
|
558
|
+
i[6]
|
|
559
|
+
), p(e, "class", "svelte-z7p9pp");
|
|
522
560
|
},
|
|
523
561
|
m(n, r) {
|
|
524
562
|
F(n, e, r);
|
|
@@ -526,30 +564,41 @@ function Un(i) {
|
|
|
526
564
|
p(n, r) {
|
|
527
565
|
r & /*iconsBaseUrl*/
|
|
528
566
|
8 && !X(e.src, t = /*iconsBaseUrl*/
|
|
529
|
-
n[3] + "postal_code.svg") &&
|
|
530
|
-
64 &&
|
|
567
|
+
n[3] + "postal_code.svg") && p(e, "src", t), r & /*placeType*/
|
|
568
|
+
64 && p(
|
|
531
569
|
e,
|
|
532
570
|
"alt",
|
|
533
571
|
/*placeType*/
|
|
534
572
|
n[6]
|
|
573
|
+
), r & /*placeType*/
|
|
574
|
+
64 && p(
|
|
575
|
+
e,
|
|
576
|
+
"title",
|
|
577
|
+
/*placeType*/
|
|
578
|
+
n[6]
|
|
535
579
|
);
|
|
536
580
|
},
|
|
537
581
|
d(n) {
|
|
538
|
-
n &&
|
|
582
|
+
n && U(e);
|
|
539
583
|
}
|
|
540
584
|
};
|
|
541
585
|
}
|
|
542
|
-
function
|
|
586
|
+
function Xn(i) {
|
|
543
587
|
let e, t;
|
|
544
588
|
return {
|
|
545
589
|
c() {
|
|
546
|
-
e =
|
|
547
|
-
i[3] + "street.svg") ||
|
|
590
|
+
e = B("img"), X(e.src, t = /*iconsBaseUrl*/
|
|
591
|
+
i[3] + "street.svg") || p(e, "src", t), p(
|
|
548
592
|
e,
|
|
549
593
|
"alt",
|
|
550
594
|
/*placeType*/
|
|
551
595
|
i[6]
|
|
552
|
-
),
|
|
596
|
+
), p(
|
|
597
|
+
e,
|
|
598
|
+
"title",
|
|
599
|
+
/*placeType*/
|
|
600
|
+
i[6]
|
|
601
|
+
), p(e, "class", "svelte-z7p9pp");
|
|
553
602
|
},
|
|
554
603
|
m(n, r) {
|
|
555
604
|
F(n, e, r);
|
|
@@ -557,30 +606,41 @@ function Fn(i) {
|
|
|
557
606
|
p(n, r) {
|
|
558
607
|
r & /*iconsBaseUrl*/
|
|
559
608
|
8 && !X(e.src, t = /*iconsBaseUrl*/
|
|
560
|
-
n[3] + "street.svg") &&
|
|
561
|
-
64 &&
|
|
609
|
+
n[3] + "street.svg") && p(e, "src", t), r & /*placeType*/
|
|
610
|
+
64 && p(
|
|
562
611
|
e,
|
|
563
612
|
"alt",
|
|
564
613
|
/*placeType*/
|
|
565
614
|
n[6]
|
|
615
|
+
), r & /*placeType*/
|
|
616
|
+
64 && p(
|
|
617
|
+
e,
|
|
618
|
+
"title",
|
|
619
|
+
/*placeType*/
|
|
620
|
+
n[6]
|
|
566
621
|
);
|
|
567
622
|
},
|
|
568
623
|
d(n) {
|
|
569
|
-
n &&
|
|
624
|
+
n && U(e);
|
|
570
625
|
}
|
|
571
626
|
};
|
|
572
627
|
}
|
|
573
|
-
function
|
|
628
|
+
function Kn(i) {
|
|
574
629
|
let e, t;
|
|
575
630
|
return {
|
|
576
631
|
c() {
|
|
577
|
-
e =
|
|
578
|
-
i[3] + "road.svg") ||
|
|
632
|
+
e = B("img"), X(e.src, t = /*iconsBaseUrl*/
|
|
633
|
+
i[3] + "road.svg") || p(e, "src", t), p(
|
|
579
634
|
e,
|
|
580
635
|
"alt",
|
|
581
636
|
/*placeType*/
|
|
582
637
|
i[6]
|
|
583
|
-
),
|
|
638
|
+
), p(
|
|
639
|
+
e,
|
|
640
|
+
"title",
|
|
641
|
+
/*placeType*/
|
|
642
|
+
i[6]
|
|
643
|
+
), p(e, "class", "svelte-z7p9pp");
|
|
584
644
|
},
|
|
585
645
|
m(n, r) {
|
|
586
646
|
F(n, e, r);
|
|
@@ -588,30 +648,41 @@ function Gn(i) {
|
|
|
588
648
|
p(n, r) {
|
|
589
649
|
r & /*iconsBaseUrl*/
|
|
590
650
|
8 && !X(e.src, t = /*iconsBaseUrl*/
|
|
591
|
-
n[3] + "road.svg") &&
|
|
592
|
-
64 &&
|
|
651
|
+
n[3] + "road.svg") && p(e, "src", t), r & /*placeType*/
|
|
652
|
+
64 && p(
|
|
593
653
|
e,
|
|
594
654
|
"alt",
|
|
595
655
|
/*placeType*/
|
|
596
656
|
n[6]
|
|
657
|
+
), r & /*placeType*/
|
|
658
|
+
64 && p(
|
|
659
|
+
e,
|
|
660
|
+
"title",
|
|
661
|
+
/*placeType*/
|
|
662
|
+
n[6]
|
|
597
663
|
);
|
|
598
664
|
},
|
|
599
665
|
d(n) {
|
|
600
|
-
n &&
|
|
666
|
+
n && U(e);
|
|
601
667
|
}
|
|
602
668
|
};
|
|
603
669
|
}
|
|
604
|
-
function
|
|
670
|
+
function Jn(i) {
|
|
605
671
|
let e, t;
|
|
606
672
|
return {
|
|
607
673
|
c() {
|
|
608
|
-
e =
|
|
609
|
-
i[3] + "housenumber.svg") ||
|
|
674
|
+
e = B("img"), X(e.src, t = /*iconsBaseUrl*/
|
|
675
|
+
i[3] + "housenumber.svg") || p(e, "src", t), p(
|
|
610
676
|
e,
|
|
611
677
|
"alt",
|
|
612
678
|
/*placeType*/
|
|
613
679
|
i[6]
|
|
614
|
-
),
|
|
680
|
+
), p(
|
|
681
|
+
e,
|
|
682
|
+
"title",
|
|
683
|
+
/*placeType*/
|
|
684
|
+
i[6]
|
|
685
|
+
), p(e, "class", "svelte-z7p9pp");
|
|
615
686
|
},
|
|
616
687
|
m(n, r) {
|
|
617
688
|
F(n, e, r);
|
|
@@ -619,33 +690,44 @@ function zn(i) {
|
|
|
619
690
|
p(n, r) {
|
|
620
691
|
r & /*iconsBaseUrl*/
|
|
621
692
|
8 && !X(e.src, t = /*iconsBaseUrl*/
|
|
622
|
-
n[3] + "housenumber.svg") &&
|
|
623
|
-
64 &&
|
|
693
|
+
n[3] + "housenumber.svg") && p(e, "src", t), r & /*placeType*/
|
|
694
|
+
64 && p(
|
|
624
695
|
e,
|
|
625
696
|
"alt",
|
|
626
697
|
/*placeType*/
|
|
627
698
|
n[6]
|
|
699
|
+
), r & /*placeType*/
|
|
700
|
+
64 && p(
|
|
701
|
+
e,
|
|
702
|
+
"title",
|
|
703
|
+
/*placeType*/
|
|
704
|
+
n[6]
|
|
628
705
|
);
|
|
629
706
|
},
|
|
630
707
|
d(n) {
|
|
631
|
-
n &&
|
|
708
|
+
n && U(e);
|
|
632
709
|
}
|
|
633
710
|
};
|
|
634
711
|
}
|
|
635
|
-
function
|
|
712
|
+
function $n(i) {
|
|
636
713
|
let e, t, n, r;
|
|
637
714
|
return {
|
|
638
715
|
c() {
|
|
639
|
-
e =
|
|
640
|
-
i[5]) ||
|
|
716
|
+
e = B("img"), X(e.src, t = /*imageUrl*/
|
|
717
|
+
i[5]) || p(e, "src", t), p(
|
|
641
718
|
e,
|
|
642
719
|
"alt",
|
|
643
720
|
/*category*/
|
|
644
721
|
i[4]
|
|
645
|
-
),
|
|
722
|
+
), p(
|
|
723
|
+
e,
|
|
724
|
+
"title",
|
|
725
|
+
/*placeType*/
|
|
726
|
+
i[6]
|
|
727
|
+
), p(e, "class", "svelte-z7p9pp");
|
|
646
728
|
},
|
|
647
729
|
m(o, l) {
|
|
648
|
-
F(o, e, l), n || (r =
|
|
730
|
+
F(o, e, l), n || (r = H(
|
|
649
731
|
e,
|
|
650
732
|
"error",
|
|
651
733
|
/*error_handler*/
|
|
@@ -655,48 +737,54 @@ function jn(i) {
|
|
|
655
737
|
p(o, l) {
|
|
656
738
|
l & /*imageUrl*/
|
|
657
739
|
32 && !X(e.src, t = /*imageUrl*/
|
|
658
|
-
o[5]) &&
|
|
659
|
-
16 &&
|
|
740
|
+
o[5]) && p(e, "src", t), l & /*category*/
|
|
741
|
+
16 && p(
|
|
660
742
|
e,
|
|
661
743
|
"alt",
|
|
662
744
|
/*category*/
|
|
663
745
|
o[4]
|
|
746
|
+
), l & /*placeType*/
|
|
747
|
+
64 && p(
|
|
748
|
+
e,
|
|
749
|
+
"title",
|
|
750
|
+
/*placeType*/
|
|
751
|
+
o[6]
|
|
664
752
|
);
|
|
665
753
|
},
|
|
666
754
|
d(o) {
|
|
667
|
-
o &&
|
|
755
|
+
o && U(e), n = !1, r();
|
|
668
756
|
}
|
|
669
757
|
};
|
|
670
758
|
}
|
|
671
|
-
function
|
|
759
|
+
function li(i) {
|
|
672
760
|
let e, t;
|
|
673
761
|
return {
|
|
674
762
|
c() {
|
|
675
|
-
e =
|
|
763
|
+
e = B("span"), t = Le(
|
|
676
764
|
/*placeType*/
|
|
677
765
|
i[6]
|
|
678
|
-
),
|
|
766
|
+
), p(e, "class", "secondary svelte-z7p9pp");
|
|
679
767
|
},
|
|
680
768
|
m(n, r) {
|
|
681
|
-
F(n, e, r),
|
|
769
|
+
F(n, e, r), I(e, t);
|
|
682
770
|
},
|
|
683
771
|
p(n, r) {
|
|
684
772
|
r & /*placeType*/
|
|
685
|
-
64 &&
|
|
773
|
+
64 && Ze(
|
|
686
774
|
t,
|
|
687
775
|
/*placeType*/
|
|
688
776
|
n[6]
|
|
689
777
|
);
|
|
690
778
|
},
|
|
691
779
|
d(n) {
|
|
692
|
-
n &&
|
|
780
|
+
n && U(e);
|
|
693
781
|
}
|
|
694
782
|
};
|
|
695
783
|
}
|
|
696
|
-
function
|
|
784
|
+
function er(i) {
|
|
697
785
|
let e, t, n, r, o, l, s, c, u, h = (
|
|
698
786
|
/*isReverse*/
|
|
699
|
-
(i[
|
|
787
|
+
(i[8] ? (
|
|
700
788
|
/*feature*/
|
|
701
789
|
i[0].place_name
|
|
702
790
|
) : (
|
|
@@ -706,203 +794,201 @@ function Zn(i) {
|
|
|
706
794
|
), a, f, d = (
|
|
707
795
|
/*showPlaceType*/
|
|
708
796
|
i[2] === "always" || /*showPlaceType*/
|
|
709
|
-
i[2] && !/*feature*/
|
|
797
|
+
i[2] !== "never" && !/*feature*/
|
|
710
798
|
i[0].address && !/*feature*/
|
|
711
799
|
i[0].id.startsWith("road.") && !/*feature*/
|
|
712
800
|
i[0].id.startsWith("address.") && !/*feature*/
|
|
713
801
|
i[0].id.startsWith("postal_code.") && (!/*feature*/
|
|
714
802
|
i[0].id.startsWith("poi.") || !/*imageUrl*/
|
|
715
803
|
i[5]) && !/*isReverse*/
|
|
716
|
-
i[
|
|
717
|
-
), m,
|
|
804
|
+
i[8]
|
|
805
|
+
), m, b, v = (
|
|
718
806
|
/*isReverse*/
|
|
719
|
-
(i[
|
|
807
|
+
(i[8] ? "" : (
|
|
720
808
|
/*feature*/
|
|
721
809
|
i[0].place_name.replace(/[^,]*,?\s*/, "")
|
|
722
810
|
)) + ""
|
|
723
|
-
),
|
|
724
|
-
function
|
|
725
|
-
return
|
|
726
|
-
1 && (t = null),
|
|
727
|
-
1 && (n = null),
|
|
728
|
-
1 && (r = null),
|
|
811
|
+
), y, E, _, L, P, N;
|
|
812
|
+
function x(M, R) {
|
|
813
|
+
return R & /*feature*/
|
|
814
|
+
1 && (t = null), R & /*feature*/
|
|
815
|
+
1 && (n = null), R & /*feature*/
|
|
816
|
+
1 && (r = null), R & /*feature*/
|
|
729
817
|
1 && (o = null), /*imageUrl*/
|
|
730
|
-
|
|
818
|
+
M[5] ? $n : (
|
|
731
819
|
/*feature*/
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
820
|
+
M[0].address ? Jn : (t == null && (t = !!/*feature*/
|
|
821
|
+
M[0].id.startsWith("road.")), t ? Kn : (n == null && (n = !!/*feature*/
|
|
822
|
+
M[0].id.startsWith("address.")), n ? Xn : (r == null && (r = !!/*feature*/
|
|
823
|
+
M[0].id.startsWith("postal_code.")), r ? Yn : (o == null && (o = !!/*feature*/
|
|
824
|
+
M[0].id.startsWith("poi.")), o ? Vn : (
|
|
737
825
|
/*isReverse*/
|
|
738
|
-
|
|
826
|
+
M[8] ? Hn : Qn
|
|
739
827
|
)))))
|
|
740
828
|
);
|
|
741
829
|
}
|
|
742
|
-
let
|
|
830
|
+
let S = x(i, -1), T = S(i), w = d && li(i);
|
|
743
831
|
return {
|
|
744
832
|
c() {
|
|
745
|
-
e =
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
/*
|
|
749
|
-
i[1]
|
|
750
|
-
), y(e, "class", "svelte-ltkwvy"), oe(
|
|
751
|
-
e,
|
|
752
|
-
"selected",
|
|
753
|
-
/*selected*/
|
|
833
|
+
e = B("li"), T.c(), l = ne(), s = B("span"), c = B("span"), u = B("span"), a = Le(h), f = ne(), w && w.c(), m = ne(), b = B("span"), y = Le(v), p(u, "class", "primary svelte-z7p9pp"), p(c, "class", "svelte-z7p9pp"), p(b, "class", "line2 svelte-z7p9pp"), p(s, "class", "texts svelte-z7p9pp"), p(e, "tabindex", "-1"), p(e, "role", "option"), p(e, "aria-selected", E = /*style*/
|
|
834
|
+
i[1] === "selected"), p(e, "aria-checked", _ = /*style*/
|
|
835
|
+
i[1] === "picked"), p(e, "class", L = dt(
|
|
836
|
+
/*style*/
|
|
754
837
|
i[1]
|
|
755
|
-
);
|
|
838
|
+
) + " svelte-z7p9pp");
|
|
756
839
|
},
|
|
757
|
-
m(
|
|
758
|
-
F(
|
|
759
|
-
|
|
840
|
+
m(M, R) {
|
|
841
|
+
F(M, e, R), T.m(e, null), I(e, l), I(e, s), I(s, c), I(c, u), I(u, a), I(c, f), w && w.m(c, null), I(s, m), I(s, b), I(b, y), P || (N = [
|
|
842
|
+
H(
|
|
760
843
|
e,
|
|
761
844
|
"mouseenter",
|
|
762
845
|
/*mouseenter_handler*/
|
|
763
|
-
i[
|
|
846
|
+
i[13]
|
|
764
847
|
),
|
|
765
|
-
|
|
848
|
+
H(
|
|
766
849
|
e,
|
|
767
850
|
"focus",
|
|
768
851
|
/*focus_handler*/
|
|
769
|
-
i[
|
|
852
|
+
i[15]
|
|
853
|
+
),
|
|
854
|
+
H(
|
|
855
|
+
e,
|
|
856
|
+
"click",
|
|
857
|
+
/*click_handler*/
|
|
858
|
+
i[16]
|
|
770
859
|
)
|
|
771
|
-
],
|
|
860
|
+
], P = !0);
|
|
772
861
|
},
|
|
773
|
-
p(
|
|
774
|
-
|
|
862
|
+
p(M, [R]) {
|
|
863
|
+
S === (S = x(M, R)) && T ? T.p(M, R) : (T.d(1), T = S(M), T && (T.c(), T.m(e, l))), R & /*feature*/
|
|
775
864
|
1 && h !== (h = /*isReverse*/
|
|
776
|
-
(
|
|
865
|
+
(M[8] ? (
|
|
777
866
|
/*feature*/
|
|
778
|
-
|
|
867
|
+
M[0].place_name
|
|
779
868
|
) : (
|
|
780
869
|
/*feature*/
|
|
781
|
-
|
|
782
|
-
)) + "") &&
|
|
870
|
+
M[0].place_name.replace(/,.*/, "")
|
|
871
|
+
)) + "") && Ze(a, h), R & /*showPlaceType, feature, imageUrl*/
|
|
783
872
|
37 && (d = /*showPlaceType*/
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
1 &&
|
|
794
|
-
(
|
|
873
|
+
M[2] === "always" || /*showPlaceType*/
|
|
874
|
+
M[2] !== "never" && !/*feature*/
|
|
875
|
+
M[0].address && !/*feature*/
|
|
876
|
+
M[0].id.startsWith("road.") && !/*feature*/
|
|
877
|
+
M[0].id.startsWith("address.") && !/*feature*/
|
|
878
|
+
M[0].id.startsWith("postal_code.") && (!/*feature*/
|
|
879
|
+
M[0].id.startsWith("poi.") || !/*imageUrl*/
|
|
880
|
+
M[5]) && !/*isReverse*/
|
|
881
|
+
M[8]), d ? w ? w.p(M, R) : (w = li(M), w.c(), w.m(c, null)) : w && (w.d(1), w = null), R & /*feature*/
|
|
882
|
+
1 && v !== (v = /*isReverse*/
|
|
883
|
+
(M[8] ? "" : (
|
|
795
884
|
/*feature*/
|
|
796
|
-
|
|
797
|
-
)) + "") &&
|
|
798
|
-
2 &&
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
"selected",
|
|
807
|
-
/*selected*/
|
|
808
|
-
w[1]
|
|
809
|
-
);
|
|
885
|
+
M[0].place_name.replace(/[^,]*,?\s*/, "")
|
|
886
|
+
)) + "") && Ze(y, v), R & /*style*/
|
|
887
|
+
2 && E !== (E = /*style*/
|
|
888
|
+
M[1] === "selected") && p(e, "aria-selected", E), R & /*style*/
|
|
889
|
+
2 && _ !== (_ = /*style*/
|
|
890
|
+
M[1] === "picked") && p(e, "aria-checked", _), R & /*style*/
|
|
891
|
+
2 && L !== (L = dt(
|
|
892
|
+
/*style*/
|
|
893
|
+
M[1]
|
|
894
|
+
) + " svelte-z7p9pp") && p(e, "class", L);
|
|
810
895
|
},
|
|
811
|
-
i:
|
|
812
|
-
o:
|
|
813
|
-
d(
|
|
814
|
-
|
|
896
|
+
i: D,
|
|
897
|
+
o: D,
|
|
898
|
+
d(M) {
|
|
899
|
+
M && U(e), T.d(), w && w.d(), P = !1, be(N);
|
|
815
900
|
}
|
|
816
901
|
};
|
|
817
902
|
}
|
|
818
|
-
function
|
|
819
|
-
var
|
|
820
|
-
let n, r, { feature: o } = e, {
|
|
821
|
-
const h = (
|
|
822
|
-
let
|
|
903
|
+
function tr(i, e, t) {
|
|
904
|
+
var P;
|
|
905
|
+
let n, r, { feature: o } = e, { style: l = "default" } = e, { showPlaceType: s } = e, { missingIconsCache: c } = e, { iconsBaseUrl: u } = e;
|
|
906
|
+
const h = Ui(), a = (P = o.properties) == null ? void 0 : P.categories;
|
|
907
|
+
let f, d, m = 0, b = o.place_type[0] === "reverse";
|
|
823
908
|
function v() {
|
|
824
|
-
|
|
909
|
+
d && c.add(d), t(11, m++, m);
|
|
825
910
|
}
|
|
826
|
-
function
|
|
827
|
-
|
|
911
|
+
function y(N) {
|
|
912
|
+
zn.call(this, i, N);
|
|
828
913
|
}
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
}
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
"feature" in S && t(0, o = S.feature), "selected" in S && t(1, l = S.selected), "showPlaceType" in S && t(2, s = S.showPlaceType), "missingIconsCache" in S && t(9, c = S.missingIconsCache), "iconsBaseUrl" in S && t(3, u = S.iconsBaseUrl);
|
|
914
|
+
const E = () => v(), _ = () => h("select", void 0), L = (N) => {
|
|
915
|
+
document.activeElement !== N.target && h("select", void 0);
|
|
916
|
+
};
|
|
917
|
+
return i.$$set = (N) => {
|
|
918
|
+
"feature" in N && t(0, o = N.feature), "style" in N && t(1, l = N.style), "showPlaceType" in N && t(2, s = N.showPlaceType), "missingIconsCache" in N && t(10, c = N.missingIconsCache), "iconsBaseUrl" in N && t(3, u = N.iconsBaseUrl);
|
|
835
919
|
}, i.$$.update = () => {
|
|
836
|
-
var
|
|
920
|
+
var N, x, S, T;
|
|
837
921
|
if (i.$$.dirty & /*loadIconAttempt, index, category, iconsBaseUrl, imageUrl, missingIconsCache*/
|
|
838
|
-
|
|
922
|
+
7224)
|
|
839
923
|
do
|
|
840
|
-
t(
|
|
841
|
-
while (n > -1 && (!
|
|
924
|
+
t(12, n--, n), t(4, f = a == null ? void 0 : a[n]), t(5, d = f ? u + f.replace(/ /g, "_") + ".svg" : void 0);
|
|
925
|
+
while (n > -1 && (!d || c.has(d)));
|
|
842
926
|
i.$$.dirty & /*feature*/
|
|
843
|
-
1 && t(6, r = ((
|
|
844
|
-
}, t(
|
|
927
|
+
1 && t(6, r = ((x = (N = o.properties) == null ? void 0 : N.categories) == null ? void 0 : x.join(", ")) ?? ((T = (S = o.properties) == null ? void 0 : S.place_type_name) == null ? void 0 : T[0]) ?? o.place_type[0]);
|
|
928
|
+
}, t(12, n = (a == null ? void 0 : a.length) ?? 0), [
|
|
845
929
|
o,
|
|
846
930
|
l,
|
|
847
931
|
s,
|
|
848
932
|
u,
|
|
849
|
-
a,
|
|
850
933
|
f,
|
|
934
|
+
d,
|
|
851
935
|
r,
|
|
852
|
-
|
|
936
|
+
h,
|
|
937
|
+
b,
|
|
853
938
|
v,
|
|
854
939
|
c,
|
|
855
|
-
|
|
940
|
+
m,
|
|
856
941
|
n,
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
_
|
|
942
|
+
y,
|
|
943
|
+
E,
|
|
944
|
+
_,
|
|
945
|
+
L
|
|
860
946
|
];
|
|
861
947
|
}
|
|
862
|
-
class
|
|
948
|
+
class ir extends ke {
|
|
863
949
|
constructor(e) {
|
|
864
|
-
super(),
|
|
950
|
+
super(), Ce(this, e, tr, er, Me, {
|
|
865
951
|
feature: 0,
|
|
866
|
-
|
|
952
|
+
style: 1,
|
|
867
953
|
showPlaceType: 2,
|
|
868
|
-
missingIconsCache:
|
|
954
|
+
missingIconsCache: 10,
|
|
869
955
|
iconsBaseUrl: 3
|
|
870
956
|
});
|
|
871
957
|
}
|
|
872
958
|
}
|
|
873
|
-
function
|
|
959
|
+
function nr(i) {
|
|
874
960
|
let e;
|
|
875
961
|
return {
|
|
876
962
|
c() {
|
|
877
|
-
e =
|
|
963
|
+
e = B("div"), e.innerHTML = '<svg viewBox="0 0 18 18" width="24" height="24" class="svelte-7cmwmc"><path fill="#333" d="M4.4 4.4l.8.8c2.1-2.1 5.5-2.1 7.6 0l.8-.8c-2.5-2.5-6.7-2.5-9.2 0z"></path><path opacity=".1" d="M12.8 12.9c-2.1 2.1-5.5 2.1-7.6 0-2.1-2.1-2.1-5.5 0-7.7l-.8-.8c-2.5 2.5-2.5 6.7 0 9.2s6.6 2.5 9.2 0 2.5-6.6 0-9.2l-.8.8c2.2 2.1 2.2 5.6 0 7.7z"></path></svg>', p(e, "class", "svelte-7cmwmc");
|
|
878
964
|
},
|
|
879
965
|
m(t, n) {
|
|
880
966
|
F(t, e, n);
|
|
881
967
|
},
|
|
882
|
-
p:
|
|
883
|
-
i:
|
|
884
|
-
o:
|
|
968
|
+
p: D,
|
|
969
|
+
i: D,
|
|
970
|
+
o: D,
|
|
885
971
|
d(t) {
|
|
886
|
-
t &&
|
|
972
|
+
t && U(e);
|
|
887
973
|
}
|
|
888
974
|
};
|
|
889
975
|
}
|
|
890
|
-
class
|
|
976
|
+
class rr extends ke {
|
|
891
977
|
constructor(e) {
|
|
892
|
-
super(),
|
|
978
|
+
super(), Ce(this, e, null, nr, Me, {});
|
|
893
979
|
}
|
|
894
980
|
}
|
|
895
|
-
function
|
|
981
|
+
function or(i) {
|
|
896
982
|
let e, t, n;
|
|
897
983
|
return {
|
|
898
984
|
c() {
|
|
899
|
-
e =
|
|
900
|
-
i[0] === "list" ? 20 : void 0),
|
|
985
|
+
e = ce("svg"), t = ce("path"), p(t, "stroke-width", "4"), p(t, "d", "M 5,33.103579 C 5,17.607779 18.457,5 35,5 C 51.543,5 65,17.607779 65,33.103579 C 65,56.388679 40.4668,76.048179 36.6112,79.137779 C 36.3714,79.329879 36.2116,79.457979 36.1427,79.518879 C 35.8203,79.800879 35.4102,79.942779 35,79.942779 C 34.5899,79.942779 34.1797,79.800879 33.8575,79.518879 C 33.7886,79.457979 33.6289,79.330079 33.3893,79.138079 C 29.5346,76.049279 5,56.389379 5,33.103579 Z M 35.0001,49.386379 C 43.1917,49.386379 49.8323,42.646079 49.8323,34.331379 C 49.8323,26.016779 43.1917,19.276479 35.0001,19.276479 C 26.8085,19.276479 20.1679,26.016779 20.1679,34.331379 C 20.1679,42.646079 26.8085,49.386379 35.0001,49.386379 Z"), p(t, "class", "svelte-gzo3ar"), p(e, "width", n = /*displayIn*/
|
|
986
|
+
i[0] === "list" ? 20 : void 0), p(e, "viewBox", "0 0 70 85"), p(e, "fill", "none"), p(e, "class", "svelte-gzo3ar"), he(
|
|
901
987
|
e,
|
|
902
988
|
"in-map",
|
|
903
989
|
/*displayIn*/
|
|
904
990
|
i[0] !== "list"
|
|
905
|
-
),
|
|
991
|
+
), he(
|
|
906
992
|
e,
|
|
907
993
|
"list-icon",
|
|
908
994
|
/*displayIn*/
|
|
@@ -910,107 +996,107 @@ function Yn(i) {
|
|
|
910
996
|
);
|
|
911
997
|
},
|
|
912
998
|
m(r, o) {
|
|
913
|
-
F(r, e, o),
|
|
999
|
+
F(r, e, o), I(e, t);
|
|
914
1000
|
},
|
|
915
1001
|
p(r, [o]) {
|
|
916
1002
|
o & /*displayIn*/
|
|
917
1003
|
1 && n !== (n = /*displayIn*/
|
|
918
|
-
r[0] === "list" ? 20 : void 0) &&
|
|
919
|
-
1 &&
|
|
1004
|
+
r[0] === "list" ? 20 : void 0) && p(e, "width", n), o & /*displayIn*/
|
|
1005
|
+
1 && he(
|
|
920
1006
|
e,
|
|
921
1007
|
"in-map",
|
|
922
1008
|
/*displayIn*/
|
|
923
1009
|
r[0] !== "list"
|
|
924
1010
|
), o & /*displayIn*/
|
|
925
|
-
1 &&
|
|
1011
|
+
1 && he(
|
|
926
1012
|
e,
|
|
927
1013
|
"list-icon",
|
|
928
1014
|
/*displayIn*/
|
|
929
1015
|
r[0] === "list"
|
|
930
1016
|
);
|
|
931
1017
|
},
|
|
932
|
-
i:
|
|
933
|
-
o:
|
|
1018
|
+
i: D,
|
|
1019
|
+
o: D,
|
|
934
1020
|
d(r) {
|
|
935
|
-
r &&
|
|
1021
|
+
r && U(e);
|
|
936
1022
|
}
|
|
937
1023
|
};
|
|
938
1024
|
}
|
|
939
|
-
function
|
|
1025
|
+
function sr(i, e, t) {
|
|
940
1026
|
let { displayIn: n } = e;
|
|
941
1027
|
return i.$$set = (r) => {
|
|
942
1028
|
"displayIn" in r && t(0, n = r.displayIn);
|
|
943
1029
|
}, [n];
|
|
944
1030
|
}
|
|
945
|
-
class
|
|
1031
|
+
class lr extends ke {
|
|
946
1032
|
constructor(e) {
|
|
947
|
-
super(),
|
|
1033
|
+
super(), Ce(this, e, sr, or, Me, { displayIn: 0 });
|
|
948
1034
|
}
|
|
949
1035
|
}
|
|
950
|
-
function
|
|
1036
|
+
function ur(i) {
|
|
951
1037
|
let e, t;
|
|
952
1038
|
return {
|
|
953
1039
|
c() {
|
|
954
|
-
e =
|
|
1040
|
+
e = ce("svg"), t = ce("path"), p(t, "d", "M30.003-26.765C13.46-26.765 0-14.158 0 1.337c0 23.286 24.535 42.952 28.39 46.04.24.192.402.316.471.376.323.282.732.424 1.142.424.41 0 .82-.142 1.142-.424.068-.06.231-.183.471-.376 3.856-3.09 28.39-22.754 28.39-46.04 0-15.495-13.46-28.102-30.003-28.102Zm1.757 12.469c4.38 0 7.858 1.052 10.431 3.158 2.595 2.105 3.89 4.913 3.89 8.422 0 2.34-.53 4.362-1.593 6.063-1.063 1.702-3.086 3.616-6.063 5.742-2.042 1.51-3.337 2.659-3.89 3.446-.532.787-.8 1.82-.8 3.096v1.914h-8.449V15.18c0-2.041.434-3.815 1.306-5.325.872-1.51 2.467-3.118 4.785-4.82 2.233-1.594 3.7-2.89 4.402-3.889a5.582 5.582 0 0 0 1.087-3.35c0-1.382-.51-2.435-1.531-3.158-1.02-.723-2.45-1.087-4.28-1.087-3.19 0-6.826 1.047-10.91 3.131l-3.472-6.986c4.742-2.659 9.77-3.992 15.087-3.992Zm-1.88 37.324c1.765 0 3.124.472 4.08 1.408.98.936 1.47 2.276 1.47 4.02 0 1.68-.49 3.007-1.47 3.985-.977.957-2.336 1.435-4.08 1.435-1.787 0-3.171-.465-4.15-1.4-.978-.958-1.47-2.298-1.47-4.02 0-1.787.48-3.14 1.436-4.054.957-.915 2.355-1.374 4.184-1.374Z"), p(e, "viewBox", "0 0 60.006 21.412"), p(e, "width", "14"), p(e, "height", "20"), p(e, "class", "svelte-en2qvf");
|
|
955
1041
|
},
|
|
956
1042
|
m(n, r) {
|
|
957
|
-
F(n, e, r),
|
|
1043
|
+
F(n, e, r), I(e, t);
|
|
958
1044
|
},
|
|
959
|
-
p:
|
|
960
|
-
i:
|
|
961
|
-
o:
|
|
1045
|
+
p: D,
|
|
1046
|
+
i: D,
|
|
1047
|
+
o: D,
|
|
962
1048
|
d(n) {
|
|
963
|
-
n &&
|
|
1049
|
+
n && U(e);
|
|
964
1050
|
}
|
|
965
1051
|
};
|
|
966
1052
|
}
|
|
967
|
-
class
|
|
1053
|
+
class ar extends ke {
|
|
968
1054
|
constructor(e) {
|
|
969
|
-
super(),
|
|
1055
|
+
super(), Ce(this, e, null, ur, Me, {});
|
|
970
1056
|
}
|
|
971
1057
|
}
|
|
972
|
-
function
|
|
1058
|
+
function cr(i) {
|
|
973
1059
|
let e, t, n;
|
|
974
1060
|
return {
|
|
975
1061
|
c() {
|
|
976
|
-
e =
|
|
1062
|
+
e = ce("svg"), t = ce("circle"), n = ce("path"), p(t, "cx", "4.789"), p(t, "cy", "4.787"), p(t, "r", "3.85"), p(t, "class", "svelte-1aq105l"), p(n, "d", "M12.063 12.063 7.635 7.635"), p(n, "class", "svelte-1aq105l"), p(e, "xmlns", "http://www.w3.org/2000/svg"), p(e, "width", "13"), p(e, "height", "13"), p(e, "viewBox", "0 0 13 13"), p(e, "class", "svelte-1aq105l");
|
|
977
1063
|
},
|
|
978
1064
|
m(r, o) {
|
|
979
|
-
F(r, e, o),
|
|
1065
|
+
F(r, e, o), I(e, t), I(e, n);
|
|
980
1066
|
},
|
|
981
|
-
p:
|
|
982
|
-
i:
|
|
983
|
-
o:
|
|
1067
|
+
p: D,
|
|
1068
|
+
i: D,
|
|
1069
|
+
o: D,
|
|
984
1070
|
d(r) {
|
|
985
|
-
r &&
|
|
1071
|
+
r && U(e);
|
|
986
1072
|
}
|
|
987
1073
|
};
|
|
988
1074
|
}
|
|
989
|
-
class
|
|
1075
|
+
class fr extends ke {
|
|
990
1076
|
constructor(e) {
|
|
991
|
-
super(),
|
|
1077
|
+
super(), Ce(this, e, null, cr, Me, {});
|
|
992
1078
|
}
|
|
993
1079
|
}
|
|
994
|
-
function
|
|
1080
|
+
function dr(i, e, t) {
|
|
995
1081
|
const n = e[1], r = e[0], o = n - r;
|
|
996
1082
|
return i === n && t ? i : ((i - r) % o + o) % o + r;
|
|
997
1083
|
}
|
|
998
|
-
function
|
|
1084
|
+
function He(i) {
|
|
999
1085
|
const e = [...i];
|
|
1000
1086
|
return e[2] < e[0] && (Math.abs((e[0] + e[2] + 360) / 2) > Math.abs((e[0] - 360 + e[2]) / 2) ? e[0] -= 360 : e[2] += 360), e;
|
|
1001
1087
|
}
|
|
1002
|
-
let
|
|
1003
|
-
async function
|
|
1088
|
+
let Fe;
|
|
1089
|
+
async function hr(i, e, t) {
|
|
1004
1090
|
const n = i == null ? void 0 : i.getCenterAndZoom();
|
|
1005
1091
|
for (const r of e ?? [])
|
|
1006
1092
|
if (!(n && (r.minZoom != null && r.minZoom > n[0] || r.maxZoom != null && r.maxZoom < n[0]))) {
|
|
1007
1093
|
if (r.type === "fixed")
|
|
1008
1094
|
return r.coordinates.join(",");
|
|
1009
1095
|
e: if (r.type === "client-geolocation") {
|
|
1010
|
-
if (
|
|
1011
|
-
if (!
|
|
1096
|
+
if (Fe && r.cachedLocationExpiry && Fe.time + r.cachedLocationExpiry > Date.now()) {
|
|
1097
|
+
if (!Fe.coords)
|
|
1012
1098
|
break e;
|
|
1013
|
-
return
|
|
1099
|
+
return Fe.coords;
|
|
1014
1100
|
}
|
|
1015
1101
|
let o;
|
|
1016
1102
|
try {
|
|
@@ -1031,7 +1117,7 @@ async function nr(i, e, t) {
|
|
|
1031
1117
|
}), o;
|
|
1032
1118
|
} catch {
|
|
1033
1119
|
} finally {
|
|
1034
|
-
r.cachedLocationExpiry && (
|
|
1120
|
+
r.cachedLocationExpiry && (Fe = {
|
|
1035
1121
|
time: Date.now(),
|
|
1036
1122
|
coords: o
|
|
1037
1123
|
});
|
|
@@ -1045,8 +1131,8 @@ async function nr(i, e, t) {
|
|
|
1045
1131
|
return n[1].toFixed(6) + "," + n[2].toFixed(6);
|
|
1046
1132
|
}
|
|
1047
1133
|
}
|
|
1048
|
-
const
|
|
1049
|
-
function
|
|
1134
|
+
const gr = /^(NORTH|SOUTH|[NS])?\s*([+-]?[0-8]?[0-9])\s*([•º°\.:]|D(?:EG)?(?:REES)?)?\s*,?([6-9][0-9])\s*(['′´’\.:]|M(?:IN)?(?:UTES)?)?\s*(NORTH|SOUTH|[NS])?(?:\s*[,/;]\s*|\s*)(EAST|WEST|[EW])?\s*([+-]?[0-1]?[0-9]?[0-9])\s*([•º°\.:]|D(?:EG)?(?:REES)?)?\s*,?([6-9][0-9])\s*(['′´’\.:]|M(?:IN)?(?:UTES)?)?\s*(EAST|WEST|[EW])?$/i, ui = /^([+-]?[0-8]?[0-9])\s+([0-5]?[0-9]\.\d{3,})[\s,]{1,}([+-]?[0-1]?[0-9]?[0-9])\s+([0-5]?[0-9]\.\d{3,})$/, ai = /^(NORTH|SOUTH|[NS])?[\s]*([+-]?[0-8]?[0-9](?:[\.,]\d{3,}))[\s]*([•º°]?)[\s]*(NORTH|SOUTH|[NS])?[\s]*[,/;]?[\s]*(EAST|WEST|[EW])?[\s]*([+-]?[0-1]?[0-9]?[0-9](?:[\.,]\d{3,}))[\s]*([•º°]?)[\s]*(EAST|WEST|[EW])?$/i, ci = /^(NORTH|SOUTH|[NS])?\s*([+-]?[0-8]?[0-9])\s*(\.)\s*([0-5]?[0-9])\s*(\.)\s*((?:[0-5]?[0-9])(?:[\.,]\d{1,3})?)?\s*(NORTH|SOUTH|[NS])?(?:\s*[,/;]\s*|\s*)(EAST|WEST|[EW])?\s*([+-]?[0-1]?[0-9]?[0-9])\s*(\.)\s*([0-5]?[0-9])\s*(\.)\s*((?:[0-5]?[0-9])(?:[\.,]\d{1,3})?)?\s*(EAST|WEST|[EW])?$/i, fi = /^(NORTH|SOUTH|[NS])?\s*([+-]?[0-8]?[0-9])\s*(D(?:EG)?(?:REES)?)\s*([0-5]?[0-9])\s*(M(?:IN)?(?:UTES)?)\s*((?:[0-5]?[0-9])(?:[\.,]\d{1,3})?)?\s*(S(?:EC)?(?:ONDS)?)?\s*(NORTH|SOUTH|[NS])?(?:\s*[,/;]\s*|\s*)(EAST|WEST|[EW])?\s*([+-]?[0-1]?[0-9]?[0-9])\s*(D(?:EG)?(?:REES)?)\s*([0-5]?[0-9])\s*(M(?:IN)?(?:UTES)?)\s*((?:[0-5]?[0-9])(?:[\.,]\d{1,3})?)?\s*(S(?:EC)?(?:ONDS)?)\s*(EAST|WEST|[EW])?$/i, di = /^(NORTH|SOUTH|[NS])?\s*([+-]?[0-8]?[0-9])\s*([•º°\.:]|D(?:EG)?(?:REES)?)?\s*,?([0-5]?[0-9](?:[\.,]\d{1,})?)?\s*(['′´’\.:]|M(?:IN)?(?:UTES)?)?\s*,?((?:[0-5]?[0-9])(?:[\.,]\d{1,3})?)?\s*(''|′′|’’|´´|["″”\.])?\s*(NORTH|SOUTH|[NS])?(?:\s*[,/;]\s*|\s*)(EAST|WEST|[EW])?\s*([+-]?[0-1]?[0-9]?[0-9])\s*([•º°\.:]|D(?:EG)?(?:REES)?)?\s*,?([0-5]?[0-9](?:[\.,]\d{1,})?)?\s*(['′´’\.:]|M(?:IN)?(?:UTES)?)?\s*,?((?:[0-5]?[0-9])(?:[\.,]\d{1,3})?)?\s*(''|′′|´´|’’|["″”\.])?\s*(EAST|WEST|[EW])?$/i;
|
|
1135
|
+
function mr(i) {
|
|
1050
1136
|
if (!["DMS", "DM", "DD"].includes(i))
|
|
1051
1137
|
throw new Error("invalid format specified");
|
|
1052
1138
|
if (this.decimalCoordinates && this.decimalCoordinates.trim()) {
|
|
@@ -1055,35 +1141,35 @@ function or(i) {
|
|
|
1055
1141
|
i == "DD" && (c = `${r}° ${l}, ${o}° ${s}`);
|
|
1056
1142
|
const u = Math.floor(r), h = Math.floor(o), a = (r - u) * 60, f = (o - h) * 60;
|
|
1057
1143
|
if (i == "DM") {
|
|
1058
|
-
let d =
|
|
1144
|
+
let d = hi(a, 3).toFixed(3).padStart(6, "0"), m = hi(f, 3).toFixed(3).padStart(6, "0");
|
|
1059
1145
|
d.endsWith(".000") && m.endsWith(".000") && (d = d.replace(/\.000$/, ""), m = m.replace(/\.000$/, "")), c = `${u}° ${d}' ${l}, ${h}° ${m}' ${s}`;
|
|
1060
1146
|
}
|
|
1061
1147
|
if (i == "DMS") {
|
|
1062
1148
|
const d = Math.floor(a), m = Math.floor(f);
|
|
1063
|
-
let
|
|
1064
|
-
const
|
|
1065
|
-
|
|
1149
|
+
let b = ((a - d) * 60).toFixed(1).padStart(4, "0"), v = ((f - m) * 60).toFixed(1).padStart(4, "0");
|
|
1150
|
+
const y = d.toString().padStart(2, "0"), E = m.toString().padStart(2, "0");
|
|
1151
|
+
b.endsWith(".0") && v.endsWith(".0") && (b = b.replace(/\.0$/, ""), v = v.replace(/\.0$/, "")), c = `${u}° ${y}' ${b}" ${l}, ${h}° ${E}' ${v}" ${s}`;
|
|
1066
1152
|
}
|
|
1067
1153
|
return c;
|
|
1068
1154
|
} else
|
|
1069
1155
|
throw new Error("no decimal coordinates to convert");
|
|
1070
1156
|
}
|
|
1071
|
-
function
|
|
1157
|
+
function hi(i, e) {
|
|
1072
1158
|
const t = Math.pow(10, e);
|
|
1073
1159
|
return Math.round((i + Number.EPSILON) * t) / t;
|
|
1074
1160
|
}
|
|
1075
|
-
function
|
|
1161
|
+
function jt(i, e) {
|
|
1076
1162
|
e || (e = 5), i = i.replace(/\s+/g, " ").trim();
|
|
1077
1163
|
let t = null, n = null, r = "", o = "", l = null, s = [], c = !1;
|
|
1078
|
-
if (
|
|
1164
|
+
if (gr.test(i))
|
|
1079
1165
|
throw new Error("invalid coordinate value");
|
|
1080
|
-
if (
|
|
1081
|
-
if (s =
|
|
1166
|
+
if (ui.test(i))
|
|
1167
|
+
if (s = ui.exec(i), c = Ge(s), c)
|
|
1082
1168
|
t = Math.abs(s[1]) + s[2] / 60, Number(s[1]) < 0 && (t *= -1), n = Math.abs(s[3]) + s[4] / 60, Number(s[3]) < 0 && (n *= -1), l = "DM";
|
|
1083
1169
|
else
|
|
1084
1170
|
throw new Error("invalid coordinate format");
|
|
1085
|
-
else if (
|
|
1086
|
-
if (s =
|
|
1171
|
+
else if (ai.test(i))
|
|
1172
|
+
if (s = ai.exec(i), c = Ge(s), c) {
|
|
1087
1173
|
if (t = s[2], n = s[6], t.includes(",") && (t = t.replace(",", ".")), n.includes(",") && (n = n.replace(",", ".")), l = "DD", Number(Math.round(t)) == Number(t))
|
|
1088
1174
|
throw new Error("integer only coordinate provided");
|
|
1089
1175
|
if (Number(Math.round(n)) == Number(n))
|
|
@@ -1091,18 +1177,18 @@ function At(i, e) {
|
|
|
1091
1177
|
s[1] ? (r = s[1], o = s[5]) : s[4] && (r = s[4], o = s[8]);
|
|
1092
1178
|
} else
|
|
1093
1179
|
throw new Error("invalid decimal coordinate format");
|
|
1094
|
-
else if (
|
|
1095
|
-
if (s =
|
|
1180
|
+
else if (ci.test(i))
|
|
1181
|
+
if (s = ci.exec(i), c = Ge(s), c)
|
|
1096
1182
|
t = Math.abs(parseInt(s[2])), s[4] && (t += s[4] / 60, l = "DM"), s[6] && (t += s[6].replace(",", ".") / 3600, l = "DMS"), parseInt(s[2]) < 0 && (t = -1 * t), n = Math.abs(parseInt(s[9])), s[11] && (n += s[11] / 60), s[13] && (n += s[13].replace(",", ".") / 3600), parseInt(s[9]) < 0 && (n = -1 * n), s[1] ? (r = s[1], o = s[8]) : s[7] && (r = s[7], o = s[14]);
|
|
1097
1183
|
else
|
|
1098
1184
|
throw new Error("invalid DMS coordinates format");
|
|
1099
|
-
else if (
|
|
1100
|
-
if (s =
|
|
1185
|
+
else if (fi.test(i))
|
|
1186
|
+
if (s = fi.exec(i), c = Ge(s), c)
|
|
1101
1187
|
t = Math.abs(parseInt(s[2])), s[4] && (t += s[4] / 60, l = "DM"), s[6] && (t += s[6] / 3600, l = "DMS"), parseInt(s[2]) < 0 && (t = -1 * t), n = Math.abs(parseInt(s[10])), s[12] && (n += s[12] / 60), s[14] && (n += s[14] / 3600), parseInt(s[10]) < 0 && (n = -1 * n), s[1] ? (r = s[1], o = s[9]) : s[8] && (r = s[8], o = s[16]);
|
|
1102
1188
|
else
|
|
1103
1189
|
throw new Error("invalid DMS coordinates format");
|
|
1104
|
-
else if (
|
|
1105
|
-
if (s =
|
|
1190
|
+
else if (di.test(i)) {
|
|
1191
|
+
if (s = di.exec(i), c = Ge(s), s.filter((u) => u).length <= 5)
|
|
1106
1192
|
throw new Error("invalid coordinates format");
|
|
1107
1193
|
if (c)
|
|
1108
1194
|
t = Math.abs(parseInt(s[2])), s[4] && (t += s[4].replace(",", ".") / 60, l = "DM"), s[6] && (t += s[6].replace(",", ".") / 3600, l = "DMS"), parseInt(s[2]) < 0 && (t = -1 * t), n = Math.abs(parseInt(s[10])), s[12] && (n += s[12].replace(",", ".") / 60), s[14] && (n += s[14].replace(",", ".") / 3600), parseInt(s[10]) < 0 && (n = -1 * n), s[1] ? (r = s[1], o = s[9]) : s[8] && (r = s[8], o = s[16]);
|
|
@@ -1125,27 +1211,27 @@ function At(i, e) {
|
|
|
1125
1211
|
let a, f;
|
|
1126
1212
|
const d = /[,/;\u0020]/g, m = h.match(d);
|
|
1127
1213
|
if (m == null) {
|
|
1128
|
-
const
|
|
1129
|
-
a = h.substring(0,
|
|
1214
|
+
const y = Math.floor(i.length / 2);
|
|
1215
|
+
a = h.substring(0, y).trim(), f = h.substring(y).trim();
|
|
1130
1216
|
} else {
|
|
1131
|
-
let
|
|
1132
|
-
m.length % 2 == 1 ?
|
|
1133
|
-
let
|
|
1134
|
-
if (
|
|
1135
|
-
|
|
1217
|
+
let y;
|
|
1218
|
+
m.length % 2 == 1 ? y = Math.floor(m.length / 2) : y = m.length / 2 - 1;
|
|
1219
|
+
let E = 0;
|
|
1220
|
+
if (y == 0)
|
|
1221
|
+
E = h.indexOf(m[0]), a = h.substring(0, E).trim(), f = h.substring(E + 1).trim();
|
|
1136
1222
|
else {
|
|
1137
|
-
let
|
|
1138
|
-
for (;
|
|
1139
|
-
|
|
1140
|
-
a = h.substring(0,
|
|
1223
|
+
let _ = 0, L = 0;
|
|
1224
|
+
for (; _ <= y; )
|
|
1225
|
+
E = h.indexOf(m[_], L), L = E + 1, _++;
|
|
1226
|
+
a = h.substring(0, E).trim(), f = h.substring(E + 1).trim();
|
|
1141
1227
|
}
|
|
1142
1228
|
}
|
|
1143
|
-
const
|
|
1144
|
-
if (v.length == 2 && v[1] == 0 && v[1].length != 2)
|
|
1145
|
-
throw new Error("invalid coordinates format");
|
|
1146
|
-
const b = f.split(".");
|
|
1229
|
+
const b = a.split(".");
|
|
1147
1230
|
if (b.length == 2 && b[1] == 0 && b[1].length != 2)
|
|
1148
1231
|
throw new Error("invalid coordinates format");
|
|
1232
|
+
const v = f.split(".");
|
|
1233
|
+
if (v.length == 2 && v[1] == 0 && v[1].length != 2)
|
|
1234
|
+
throw new Error("invalid coordinates format");
|
|
1149
1235
|
if (/^\d+$/.test(a) || /^\d+$/.test(f))
|
|
1150
1236
|
throw new Error("degree only coordinate/s provided");
|
|
1151
1237
|
return t = Number(Number(t).toFixed(e)), n = Number(Number(n).toFixed(e)), Object.freeze({
|
|
@@ -1156,13 +1242,13 @@ function At(i, e) {
|
|
|
1156
1242
|
decimalLongitude: n,
|
|
1157
1243
|
decimalCoordinates: `${t},${n}`,
|
|
1158
1244
|
originalFormat: l,
|
|
1159
|
-
closeEnough:
|
|
1160
|
-
toCoordinateFormat:
|
|
1245
|
+
closeEnough: pr,
|
|
1246
|
+
toCoordinateFormat: mr
|
|
1161
1247
|
});
|
|
1162
1248
|
} else
|
|
1163
1249
|
throw new Error("coordinates pattern match failed");
|
|
1164
1250
|
}
|
|
1165
|
-
function
|
|
1251
|
+
function Ge(i) {
|
|
1166
1252
|
if (!isNaN(i[0]))
|
|
1167
1253
|
return !1;
|
|
1168
1254
|
const e = [...i];
|
|
@@ -1181,28 +1267,28 @@ function Fe(i) {
|
|
|
1181
1267
|
}
|
|
1182
1268
|
return !0;
|
|
1183
1269
|
}
|
|
1184
|
-
function
|
|
1270
|
+
function gi(i, e) {
|
|
1185
1271
|
const t = Math.abs(i - e);
|
|
1186
1272
|
return Number(t.toFixed(6)) <= 1e-5;
|
|
1187
1273
|
}
|
|
1188
|
-
function
|
|
1274
|
+
function pr(i) {
|
|
1189
1275
|
if (!i)
|
|
1190
1276
|
throw new Error("coords must be provided");
|
|
1191
1277
|
if (i.includes(",")) {
|
|
1192
1278
|
const e = i.split(",");
|
|
1193
1279
|
if (Number(e[0]) == NaN || Number(e[1]) == NaN)
|
|
1194
1280
|
throw new Error("coords are not valid decimals");
|
|
1195
|
-
return
|
|
1281
|
+
return gi(this.decimalLatitude, Number(e[0])) && gi(this.decimalLongitude, e[1]);
|
|
1196
1282
|
} else
|
|
1197
1283
|
throw new Error("coords being tested must be separated by a comma");
|
|
1198
1284
|
}
|
|
1199
|
-
const
|
|
1285
|
+
const yr = Object.freeze({
|
|
1200
1286
|
DMS: "DMS",
|
|
1201
1287
|
DM: "DM",
|
|
1202
1288
|
DD: "DD"
|
|
1203
1289
|
});
|
|
1204
|
-
|
|
1205
|
-
const
|
|
1290
|
+
jt.to = yr;
|
|
1291
|
+
const br = [
|
|
1206
1292
|
{
|
|
1207
1293
|
verbatimCoordinates: "40.123, -74.123",
|
|
1208
1294
|
verbatimLatitude: "40.123",
|
|
@@ -1343,10 +1429,10 @@ const ur = [
|
|
|
1343
1429
|
verbatimLatitude: "40 7 22.8",
|
|
1344
1430
|
verbatimLongitude: "-74 7 22.8"
|
|
1345
1431
|
}
|
|
1346
|
-
],
|
|
1432
|
+
], vr = {
|
|
1347
1433
|
decimalLatitude: 40.123,
|
|
1348
1434
|
decimalLongitude: -74.123
|
|
1349
|
-
},
|
|
1435
|
+
}, _r = [
|
|
1350
1436
|
{
|
|
1351
1437
|
verbatimCoordinates: `50°4'17.698"south, 14°24'2.826"east`,
|
|
1352
1438
|
verbatimLatitude: `50°4'17.698"south`,
|
|
@@ -1431,7 +1517,7 @@ const ur = [
|
|
|
1431
1517
|
decimalLatitude: -18.4,
|
|
1432
1518
|
decimalLongitude: 22.75
|
|
1433
1519
|
}
|
|
1434
|
-
],
|
|
1520
|
+
], wr = [
|
|
1435
1521
|
{
|
|
1436
1522
|
verbatimCoordinates: "10.432342S 10.6345345E",
|
|
1437
1523
|
verbatimLatitude: "10.432342S",
|
|
@@ -1566,27 +1652,27 @@ const ur = [
|
|
|
1566
1652
|
decimalLongitude: 18.33453
|
|
1567
1653
|
}
|
|
1568
1654
|
];
|
|
1569
|
-
function
|
|
1655
|
+
function Er() {
|
|
1570
1656
|
const i = [];
|
|
1571
|
-
return
|
|
1572
|
-
e.decimalLatitude ? i.push(e) : i.push({ ...e, ...
|
|
1573
|
-
}), [...i, ...
|
|
1574
|
-
}
|
|
1575
|
-
const
|
|
1576
|
-
|
|
1577
|
-
const
|
|
1578
|
-
function
|
|
1657
|
+
return br.forEach((e) => {
|
|
1658
|
+
e.decimalLatitude ? i.push(e) : i.push({ ...e, ...vr });
|
|
1659
|
+
}), [...i, ..._r, ...wr];
|
|
1660
|
+
}
|
|
1661
|
+
const Lr = Er();
|
|
1662
|
+
jt.formats = Lr.map((i) => i.verbatimCoordinates);
|
|
1663
|
+
const Sr = jt;
|
|
1664
|
+
function mi(i, e, t) {
|
|
1579
1665
|
const n = i.slice();
|
|
1580
|
-
return n[
|
|
1666
|
+
return n[91] = e[t], n[93] = t, n;
|
|
1581
1667
|
}
|
|
1582
|
-
function
|
|
1668
|
+
function pi(i) {
|
|
1583
1669
|
let e, t;
|
|
1584
|
-
return e = new
|
|
1670
|
+
return e = new rr({}), {
|
|
1585
1671
|
c() {
|
|
1586
|
-
|
|
1672
|
+
Se(e.$$.fragment);
|
|
1587
1673
|
},
|
|
1588
1674
|
m(n, r) {
|
|
1589
|
-
|
|
1675
|
+
pe(e, n, r), t = !0;
|
|
1590
1676
|
},
|
|
1591
1677
|
i(n) {
|
|
1592
1678
|
t || (Z(e.$$.fragment, n), t = !0);
|
|
@@ -1595,20 +1681,20 @@ function ai(i) {
|
|
|
1595
1681
|
V(e.$$.fragment, n), t = !1;
|
|
1596
1682
|
},
|
|
1597
1683
|
d(n) {
|
|
1598
|
-
|
|
1684
|
+
ye(e, n);
|
|
1599
1685
|
}
|
|
1600
1686
|
};
|
|
1601
1687
|
}
|
|
1602
|
-
function
|
|
1688
|
+
function yi(i) {
|
|
1603
1689
|
let e, t, n, r, o;
|
|
1604
|
-
return t = new
|
|
1690
|
+
return t = new ar({}), {
|
|
1605
1691
|
c() {
|
|
1606
|
-
e =
|
|
1692
|
+
e = B("button"), Se(t.$$.fragment), p(e, "type", "button"), p(
|
|
1607
1693
|
e,
|
|
1608
1694
|
"title",
|
|
1609
1695
|
/*reverseButtonTitle*/
|
|
1610
|
-
i[
|
|
1611
|
-
),
|
|
1696
|
+
i[10]
|
|
1697
|
+
), p(e, "class", "svelte-bz0zu3"), he(
|
|
1612
1698
|
e,
|
|
1613
1699
|
"active",
|
|
1614
1700
|
/*reverseActive*/
|
|
@@ -1616,22 +1702,22 @@ function ci(i) {
|
|
|
1616
1702
|
);
|
|
1617
1703
|
},
|
|
1618
1704
|
m(l, s) {
|
|
1619
|
-
F(l, e, s),
|
|
1705
|
+
F(l, e, s), pe(t, e, null), n = !0, r || (o = H(
|
|
1620
1706
|
e,
|
|
1621
1707
|
"click",
|
|
1622
|
-
/*
|
|
1623
|
-
i[
|
|
1708
|
+
/*click_handler_3*/
|
|
1709
|
+
i[76]
|
|
1624
1710
|
), r = !0);
|
|
1625
1711
|
},
|
|
1626
1712
|
p(l, s) {
|
|
1627
1713
|
(!n || s[0] & /*reverseButtonTitle*/
|
|
1628
|
-
|
|
1714
|
+
1024) && p(
|
|
1629
1715
|
e,
|
|
1630
1716
|
"title",
|
|
1631
1717
|
/*reverseButtonTitle*/
|
|
1632
|
-
l[
|
|
1718
|
+
l[10]
|
|
1633
1719
|
), (!n || s[0] & /*reverseActive*/
|
|
1634
|
-
1) &&
|
|
1720
|
+
1) && he(
|
|
1635
1721
|
e,
|
|
1636
1722
|
"active",
|
|
1637
1723
|
/*reverseActive*/
|
|
@@ -1645,57 +1731,63 @@ function ci(i) {
|
|
|
1645
1731
|
V(t.$$.fragment, l), n = !1;
|
|
1646
1732
|
},
|
|
1647
1733
|
d(l) {
|
|
1648
|
-
l &&
|
|
1734
|
+
l && U(e), ye(t), r = !1, o();
|
|
1649
1735
|
}
|
|
1650
1736
|
};
|
|
1651
1737
|
}
|
|
1652
|
-
function
|
|
1653
|
-
let e, t = [], n = /* @__PURE__ */ new Map(), r, o, l, s =
|
|
1738
|
+
function xr(i) {
|
|
1739
|
+
let e, t = [], n = /* @__PURE__ */ new Map(), r, o, l, s = si(
|
|
1654
1740
|
/*listFeatures*/
|
|
1655
|
-
i[
|
|
1741
|
+
i[13]
|
|
1656
1742
|
);
|
|
1657
1743
|
const c = (u) => (
|
|
1658
1744
|
/*feature*/
|
|
1659
|
-
u[
|
|
1660
|
-
(u[
|
|
1661
|
-
u[
|
|
1745
|
+
u[91].id + /*feature*/
|
|
1746
|
+
(u[91].address ? "," + /*feature*/
|
|
1747
|
+
u[91].address : "")
|
|
1662
1748
|
);
|
|
1663
1749
|
for (let u = 0; u < s.length; u += 1) {
|
|
1664
|
-
let h =
|
|
1665
|
-
n.set(a, t[u] =
|
|
1750
|
+
let h = mi(i, s, u), a = c(h);
|
|
1751
|
+
n.set(a, t[u] = bi(a, h));
|
|
1666
1752
|
}
|
|
1667
1753
|
return {
|
|
1668
1754
|
c() {
|
|
1669
|
-
e =
|
|
1755
|
+
e = B("ul");
|
|
1670
1756
|
for (let u = 0; u < t.length; u += 1)
|
|
1671
1757
|
t[u].c();
|
|
1672
|
-
|
|
1758
|
+
p(e, "class", "options svelte-bz0zu3"), p(e, "role", "listbox");
|
|
1673
1759
|
},
|
|
1674
1760
|
m(u, h) {
|
|
1675
1761
|
F(u, e, h);
|
|
1676
1762
|
for (let a = 0; a < t.length; a += 1)
|
|
1677
1763
|
t[a] && t[a].m(e, null);
|
|
1678
1764
|
r = !0, o || (l = [
|
|
1679
|
-
|
|
1765
|
+
H(
|
|
1680
1766
|
e,
|
|
1681
1767
|
"mouseleave",
|
|
1682
|
-
/*
|
|
1683
|
-
i[
|
|
1768
|
+
/*handleMouseLeave*/
|
|
1769
|
+
i[27]
|
|
1684
1770
|
),
|
|
1685
|
-
|
|
1771
|
+
H(
|
|
1686
1772
|
e,
|
|
1687
1773
|
"blur",
|
|
1688
1774
|
/*blur_handler_1*/
|
|
1689
|
-
i[
|
|
1775
|
+
i[80]
|
|
1776
|
+
),
|
|
1777
|
+
H(
|
|
1778
|
+
e,
|
|
1779
|
+
"keydown",
|
|
1780
|
+
/*handleKeyDown*/
|
|
1781
|
+
i[23]
|
|
1690
1782
|
)
|
|
1691
1783
|
], o = !0);
|
|
1692
1784
|
},
|
|
1693
1785
|
p(u, h) {
|
|
1694
|
-
h[0] & /*listFeatures, showPlaceType, selectedItemIndex, missingIconsCache, iconsBaseUrl, pick*/
|
|
1695
|
-
|
|
1786
|
+
h[0] & /*listFeatures, showPlaceType, selectedItemIndex, picked, missingIconsCache, iconsBaseUrl, handleMouseEnter, pick*/
|
|
1787
|
+
102823936 && (s = si(
|
|
1696
1788
|
/*listFeatures*/
|
|
1697
|
-
u[
|
|
1698
|
-
),
|
|
1789
|
+
u[13]
|
|
1790
|
+
), at(), t = Fn(t, h, c, 1, u, s, n, e, Un, bi, null, mi), ct());
|
|
1699
1791
|
},
|
|
1700
1792
|
i(u) {
|
|
1701
1793
|
if (!r) {
|
|
@@ -1710,31 +1802,31 @@ function mr(i) {
|
|
|
1710
1802
|
r = !1;
|
|
1711
1803
|
},
|
|
1712
1804
|
d(u) {
|
|
1713
|
-
u &&
|
|
1805
|
+
u && U(e);
|
|
1714
1806
|
for (let h = 0; h < t.length; h += 1)
|
|
1715
1807
|
t[h].d();
|
|
1716
|
-
o = !1,
|
|
1808
|
+
o = !1, be(l);
|
|
1717
1809
|
}
|
|
1718
1810
|
};
|
|
1719
1811
|
}
|
|
1720
|
-
function
|
|
1812
|
+
function Mr(i) {
|
|
1721
1813
|
let e, t, n, r, o, l;
|
|
1722
|
-
return t = new
|
|
1814
|
+
return t = new ji({}), {
|
|
1723
1815
|
c() {
|
|
1724
|
-
e =
|
|
1816
|
+
e = B("div"), Se(t.$$.fragment), n = ne(), r = B("div"), o = Le(
|
|
1725
1817
|
/*noResultsMessage*/
|
|
1726
|
-
i[
|
|
1727
|
-
),
|
|
1818
|
+
i[8]
|
|
1819
|
+
), p(r, "class", "svelte-bz0zu3"), p(e, "class", "no-results svelte-bz0zu3");
|
|
1728
1820
|
},
|
|
1729
1821
|
m(s, c) {
|
|
1730
|
-
F(s, e, c),
|
|
1822
|
+
F(s, e, c), pe(t, e, null), I(e, n), I(e, r), I(r, o), l = !0;
|
|
1731
1823
|
},
|
|
1732
1824
|
p(s, c) {
|
|
1733
1825
|
(!l || c[0] & /*noResultsMessage*/
|
|
1734
|
-
|
|
1826
|
+
256) && Ze(
|
|
1735
1827
|
o,
|
|
1736
1828
|
/*noResultsMessage*/
|
|
1737
|
-
s[
|
|
1829
|
+
s[8]
|
|
1738
1830
|
);
|
|
1739
1831
|
},
|
|
1740
1832
|
i(s) {
|
|
@@ -1744,50 +1836,50 @@ function yr(i) {
|
|
|
1744
1836
|
V(t.$$.fragment, s), l = !1;
|
|
1745
1837
|
},
|
|
1746
1838
|
d(s) {
|
|
1747
|
-
s &&
|
|
1839
|
+
s && U(e), ye(t);
|
|
1748
1840
|
}
|
|
1749
1841
|
};
|
|
1750
1842
|
}
|
|
1751
|
-
function
|
|
1843
|
+
function Cr(i) {
|
|
1752
1844
|
let e = "", t;
|
|
1753
1845
|
return {
|
|
1754
1846
|
c() {
|
|
1755
|
-
t =
|
|
1847
|
+
t = Le(e);
|
|
1756
1848
|
},
|
|
1757
1849
|
m(n, r) {
|
|
1758
1850
|
F(n, t, r);
|
|
1759
1851
|
},
|
|
1760
|
-
p:
|
|
1761
|
-
i:
|
|
1762
|
-
o:
|
|
1852
|
+
p: D,
|
|
1853
|
+
i: D,
|
|
1854
|
+
o: D,
|
|
1763
1855
|
d(n) {
|
|
1764
|
-
n &&
|
|
1856
|
+
n && U(t);
|
|
1765
1857
|
}
|
|
1766
1858
|
};
|
|
1767
1859
|
}
|
|
1768
|
-
function
|
|
1860
|
+
function kr(i) {
|
|
1769
1861
|
let e, t, n, r, o, l, s, c, u, h, a;
|
|
1770
|
-
return t = new
|
|
1862
|
+
return t = new ji({}), c = new Gi({}), {
|
|
1771
1863
|
c() {
|
|
1772
|
-
e =
|
|
1864
|
+
e = B("div"), Se(t.$$.fragment), n = ne(), r = B("div"), o = Le(
|
|
1773
1865
|
/*errorMessage*/
|
|
1774
|
-
i[
|
|
1775
|
-
), l =
|
|
1866
|
+
i[7]
|
|
1867
|
+
), l = ne(), s = B("button"), Se(c.$$.fragment), p(r, "class", "svelte-bz0zu3"), p(s, "class", "svelte-bz0zu3"), p(e, "class", "error svelte-bz0zu3");
|
|
1776
1868
|
},
|
|
1777
1869
|
m(f, d) {
|
|
1778
|
-
F(f, e, d),
|
|
1870
|
+
F(f, e, d), pe(t, e, null), I(e, n), I(e, r), I(r, o), I(e, l), I(e, s), pe(c, s, null), u = !0, h || (a = H(
|
|
1779
1871
|
s,
|
|
1780
1872
|
"click",
|
|
1781
|
-
/*
|
|
1782
|
-
i[
|
|
1873
|
+
/*click_handler_4*/
|
|
1874
|
+
i[77]
|
|
1783
1875
|
), h = !0);
|
|
1784
1876
|
},
|
|
1785
1877
|
p(f, d) {
|
|
1786
1878
|
(!u || d[0] & /*errorMessage*/
|
|
1787
|
-
|
|
1879
|
+
128) && Ze(
|
|
1788
1880
|
o,
|
|
1789
1881
|
/*errorMessage*/
|
|
1790
|
-
f[
|
|
1882
|
+
f[7]
|
|
1791
1883
|
);
|
|
1792
1884
|
},
|
|
1793
1885
|
i(f) {
|
|
@@ -1797,300 +1889,322 @@ function vr(i) {
|
|
|
1797
1889
|
V(t.$$.fragment, f), V(c.$$.fragment, f), u = !1;
|
|
1798
1890
|
},
|
|
1799
1891
|
d(f) {
|
|
1800
|
-
f &&
|
|
1892
|
+
f && U(e), ye(t), ye(c), h = !1, a();
|
|
1801
1893
|
}
|
|
1802
1894
|
};
|
|
1803
1895
|
}
|
|
1804
|
-
function
|
|
1896
|
+
function bi(i, e) {
|
|
1897
|
+
var s;
|
|
1805
1898
|
let t, n, r;
|
|
1806
1899
|
function o() {
|
|
1807
1900
|
return (
|
|
1808
1901
|
/*mouseenter_handler*/
|
|
1809
|
-
e[
|
|
1902
|
+
e[78](
|
|
1810
1903
|
/*i*/
|
|
1811
|
-
e[
|
|
1904
|
+
e[93]
|
|
1812
1905
|
)
|
|
1813
1906
|
);
|
|
1814
1907
|
}
|
|
1815
1908
|
function l() {
|
|
1816
1909
|
return (
|
|
1817
|
-
/*
|
|
1818
|
-
e[
|
|
1910
|
+
/*select_handler*/
|
|
1911
|
+
e[79](
|
|
1819
1912
|
/*feature*/
|
|
1820
|
-
e[
|
|
1913
|
+
e[91]
|
|
1821
1914
|
)
|
|
1822
1915
|
);
|
|
1823
1916
|
}
|
|
1824
|
-
return n = new
|
|
1917
|
+
return n = new ir({
|
|
1825
1918
|
props: {
|
|
1826
1919
|
feature: (
|
|
1827
1920
|
/*feature*/
|
|
1828
|
-
e[
|
|
1921
|
+
e[91]
|
|
1829
1922
|
),
|
|
1830
1923
|
showPlaceType: (
|
|
1831
1924
|
/*showPlaceType*/
|
|
1832
|
-
e[
|
|
1925
|
+
e[11]
|
|
1833
1926
|
),
|
|
1834
|
-
|
|
1927
|
+
style: (
|
|
1835
1928
|
/*selectedItemIndex*/
|
|
1836
1929
|
e[15] === /*i*/
|
|
1837
|
-
e[
|
|
1930
|
+
e[93] ? "selected" : (
|
|
1931
|
+
/*picked*/
|
|
1932
|
+
((s = e[14]) == null ? void 0 : s.id) === /*feature*/
|
|
1933
|
+
e[91].id ? "picked" : "default"
|
|
1934
|
+
)
|
|
1838
1935
|
),
|
|
1839
1936
|
missingIconsCache: (
|
|
1840
1937
|
/*missingIconsCache*/
|
|
1841
|
-
e[
|
|
1938
|
+
e[21]
|
|
1842
1939
|
),
|
|
1843
1940
|
iconsBaseUrl: (
|
|
1844
1941
|
/*iconsBaseUrl*/
|
|
1845
1942
|
e[12]
|
|
1846
1943
|
)
|
|
1847
1944
|
}
|
|
1848
|
-
}), n.$on("mouseenter", o), n.$on("
|
|
1945
|
+
}), n.$on("mouseenter", o), n.$on("select", l), {
|
|
1849
1946
|
key: i,
|
|
1850
1947
|
first: null,
|
|
1851
1948
|
c() {
|
|
1852
|
-
t =
|
|
1949
|
+
t = Pn(), Se(n.$$.fragment), this.first = t;
|
|
1853
1950
|
},
|
|
1854
|
-
m(
|
|
1855
|
-
F(
|
|
1951
|
+
m(c, u) {
|
|
1952
|
+
F(c, t, u), pe(n, c, u), r = !0;
|
|
1856
1953
|
},
|
|
1857
|
-
p(
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1954
|
+
p(c, u) {
|
|
1955
|
+
var a;
|
|
1956
|
+
e = c;
|
|
1957
|
+
const h = {};
|
|
1958
|
+
u[0] & /*listFeatures*/
|
|
1959
|
+
8192 && (h.feature = /*feature*/
|
|
1960
|
+
e[91]), u[0] & /*showPlaceType*/
|
|
1961
|
+
2048 && (h.showPlaceType = /*showPlaceType*/
|
|
1962
|
+
e[11]), u[0] & /*selectedItemIndex, listFeatures, picked*/
|
|
1963
|
+
57344 && (h.style = /*selectedItemIndex*/
|
|
1866
1964
|
e[15] === /*i*/
|
|
1867
|
-
e[
|
|
1868
|
-
|
|
1869
|
-
|
|
1965
|
+
e[93] ? "selected" : (
|
|
1966
|
+
/*picked*/
|
|
1967
|
+
((a = e[14]) == null ? void 0 : a.id) === /*feature*/
|
|
1968
|
+
e[91].id ? "picked" : "default"
|
|
1969
|
+
)), u[0] & /*iconsBaseUrl*/
|
|
1970
|
+
4096 && (h.iconsBaseUrl = /*iconsBaseUrl*/
|
|
1971
|
+
e[12]), n.$set(h);
|
|
1870
1972
|
},
|
|
1871
|
-
i(
|
|
1872
|
-
r || (Z(n.$$.fragment,
|
|
1973
|
+
i(c) {
|
|
1974
|
+
r || (Z(n.$$.fragment, c), r = !0);
|
|
1873
1975
|
},
|
|
1874
|
-
o(
|
|
1875
|
-
V(n.$$.fragment,
|
|
1976
|
+
o(c) {
|
|
1977
|
+
V(n.$$.fragment, c), r = !1;
|
|
1876
1978
|
},
|
|
1877
|
-
d(
|
|
1878
|
-
|
|
1979
|
+
d(c) {
|
|
1980
|
+
c && U(t), ye(n, c);
|
|
1879
1981
|
}
|
|
1880
1982
|
};
|
|
1881
1983
|
}
|
|
1882
|
-
function
|
|
1883
|
-
let e, t, n, r, o, l, s, c, u, h, a, f, d, m, v,
|
|
1884
|
-
o = new
|
|
1885
|
-
let
|
|
1984
|
+
function Nr(i) {
|
|
1985
|
+
let e, t, n, r, o, l, s, c, u, h, a, f, d, m, b, v, y, E, _, L, P, N = !1;
|
|
1986
|
+
o = new fr({}), a = new Gi({});
|
|
1987
|
+
let x = (
|
|
1886
1988
|
/*abortController*/
|
|
1887
|
-
i[
|
|
1888
|
-
),
|
|
1989
|
+
i[20] && pi()
|
|
1990
|
+
), S = (
|
|
1889
1991
|
/*enableReverse*/
|
|
1890
|
-
i[
|
|
1992
|
+
i[6] === "button" && yi(i)
|
|
1891
1993
|
);
|
|
1892
|
-
const
|
|
1994
|
+
const T = (
|
|
1893
1995
|
/*#slots*/
|
|
1894
|
-
i[
|
|
1895
|
-
),
|
|
1896
|
-
|
|
1996
|
+
i[67].default
|
|
1997
|
+
), w = Mn(
|
|
1998
|
+
T,
|
|
1897
1999
|
i,
|
|
1898
2000
|
/*$$scope*/
|
|
1899
|
-
i[
|
|
2001
|
+
i[66],
|
|
1900
2002
|
null
|
|
1901
|
-
),
|
|
1902
|
-
function
|
|
1903
|
-
var
|
|
2003
|
+
), M = [kr, Cr, Mr, xr], R = [];
|
|
2004
|
+
function K(C, A) {
|
|
2005
|
+
var oe, j;
|
|
1904
2006
|
return (
|
|
1905
2007
|
/*error*/
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
2008
|
+
C[19] ? 0 : !/*focusedDelayed*/
|
|
2009
|
+
C[16] && !/*keepListOpen*/
|
|
2010
|
+
C[4] ? 1 : (
|
|
2011
|
+
/*listFeatures*/
|
|
2012
|
+
((oe = C[13]) == null ? void 0 : oe.length) === 0 ? 2 : (
|
|
1909
2013
|
/*listFeatures*/
|
|
1910
|
-
(
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
)
|
|
1915
|
-
) : 1
|
|
2014
|
+
(j = C[13]) != null && j.length && /*focusedDelayed*/
|
|
2015
|
+
(C[16] || /*keepListOpen*/
|
|
2016
|
+
C[4]) ? 3 : -1
|
|
2017
|
+
)
|
|
1916
2018
|
)
|
|
1917
2019
|
);
|
|
1918
2020
|
}
|
|
1919
|
-
return ~(
|
|
2021
|
+
return ~(v = K(i)) && (y = R[v] = M[v](i)), {
|
|
1920
2022
|
c() {
|
|
1921
|
-
e =
|
|
2023
|
+
e = ne(), t = B("form"), n = B("div"), r = B("button"), Se(o.$$.fragment), l = ne(), s = B("input"), c = ne(), u = B("div"), h = B("button"), Se(a.$$.fragment), f = ne(), x && x.c(), d = ne(), S && S.c(), m = ne(), w && w.c(), b = ne(), y && y.c(), p(r, "class", "search-button svelte-bz0zu3"), p(r, "type", "button"), p(
|
|
1922
2024
|
s,
|
|
1923
2025
|
"placeholder",
|
|
1924
2026
|
/*placeholder*/
|
|
1925
|
-
i[
|
|
1926
|
-
),
|
|
2027
|
+
i[9]
|
|
2028
|
+
), p(
|
|
1927
2029
|
s,
|
|
1928
2030
|
"aria-label",
|
|
1929
2031
|
/*placeholder*/
|
|
1930
|
-
i[
|
|
1931
|
-
),
|
|
2032
|
+
i[9]
|
|
2033
|
+
), p(s, "class", "svelte-bz0zu3"), p(h, "type", "button"), p(
|
|
1932
2034
|
h,
|
|
1933
2035
|
"title",
|
|
1934
2036
|
/*clearButtonTitle*/
|
|
1935
2037
|
i[3]
|
|
1936
|
-
),
|
|
2038
|
+
), p(h, "class", "svelte-bz0zu3"), p(u, "class", "clear-button-container svelte-bz0zu3"), he(
|
|
1937
2039
|
u,
|
|
1938
2040
|
"displayable",
|
|
1939
2041
|
/*searchValue*/
|
|
1940
2042
|
i[1] !== ""
|
|
1941
|
-
),
|
|
2043
|
+
), p(n, "class", "input-group svelte-bz0zu3"), p(t, "class", E = dt(
|
|
1942
2044
|
/*className*/
|
|
1943
2045
|
i[2]
|
|
1944
|
-
) + " svelte-
|
|
2046
|
+
) + " svelte-bz0zu3"), he(
|
|
1945
2047
|
t,
|
|
1946
2048
|
"can-collapse",
|
|
1947
2049
|
/*collapsed*/
|
|
1948
|
-
i[
|
|
2050
|
+
i[5] && /*searchValue*/
|
|
1949
2051
|
i[1] === ""
|
|
1950
2052
|
);
|
|
1951
2053
|
},
|
|
1952
|
-
m(
|
|
1953
|
-
F(
|
|
2054
|
+
m(C, A) {
|
|
2055
|
+
F(C, e, A), F(C, t, A), I(t, n), I(n, r), pe(o, r, null), I(n, l), I(n, s), i[69](s), ri(
|
|
1954
2056
|
s,
|
|
1955
2057
|
/*searchValue*/
|
|
1956
2058
|
i[1]
|
|
1957
|
-
),
|
|
1958
|
-
|
|
2059
|
+
), I(n, c), I(n, u), I(u, h), pe(a, h, null), I(u, f), x && x.m(u, null), I(n, d), S && S.m(n, null), I(n, m), w && w.m(n, null), I(t, b), ~v && R[v].m(t, null), _ = !0, L || (P = [
|
|
2060
|
+
H(
|
|
1959
2061
|
r,
|
|
1960
2062
|
"click",
|
|
1961
2063
|
/*click_handler*/
|
|
1962
|
-
i[
|
|
2064
|
+
i[68]
|
|
1963
2065
|
),
|
|
1964
|
-
|
|
2066
|
+
H(
|
|
1965
2067
|
s,
|
|
1966
2068
|
"input",
|
|
1967
2069
|
/*input_1_input_handler*/
|
|
1968
|
-
i[
|
|
2070
|
+
i[70]
|
|
1969
2071
|
),
|
|
1970
|
-
|
|
2072
|
+
H(
|
|
1971
2073
|
s,
|
|
1972
2074
|
"focus",
|
|
1973
2075
|
/*focus_handler*/
|
|
1974
|
-
i[
|
|
2076
|
+
i[71]
|
|
1975
2077
|
),
|
|
1976
|
-
|
|
2078
|
+
H(
|
|
1977
2079
|
s,
|
|
1978
2080
|
"blur",
|
|
1979
2081
|
/*blur_handler*/
|
|
1980
|
-
i[
|
|
2082
|
+
i[72]
|
|
1981
2083
|
),
|
|
1982
|
-
|
|
2084
|
+
H(
|
|
2085
|
+
s,
|
|
2086
|
+
"click",
|
|
2087
|
+
/*click_handler_1*/
|
|
2088
|
+
i[73]
|
|
2089
|
+
),
|
|
2090
|
+
H(
|
|
1983
2091
|
s,
|
|
1984
2092
|
"keydown",
|
|
1985
2093
|
/*handleKeyDown*/
|
|
1986
|
-
i[
|
|
2094
|
+
i[23]
|
|
1987
2095
|
),
|
|
1988
|
-
|
|
2096
|
+
H(
|
|
1989
2097
|
s,
|
|
1990
2098
|
"input",
|
|
1991
|
-
/*
|
|
1992
|
-
i[
|
|
2099
|
+
/*handleInput*/
|
|
2100
|
+
i[24]
|
|
1993
2101
|
),
|
|
1994
|
-
|
|
2102
|
+
H(
|
|
2103
|
+
s,
|
|
2104
|
+
"change",
|
|
2105
|
+
/*change_handler*/
|
|
2106
|
+
i[74]
|
|
2107
|
+
),
|
|
2108
|
+
H(
|
|
1995
2109
|
h,
|
|
1996
2110
|
"click",
|
|
1997
|
-
/*
|
|
1998
|
-
i[
|
|
2111
|
+
/*click_handler_2*/
|
|
2112
|
+
i[75]
|
|
1999
2113
|
),
|
|
2000
|
-
|
|
2001
|
-
/*
|
|
2002
|
-
i[
|
|
2114
|
+
H(t, "submit", Tn(
|
|
2115
|
+
/*handleSubmit*/
|
|
2116
|
+
i[22]
|
|
2003
2117
|
))
|
|
2004
|
-
],
|
|
2118
|
+
], L = !0);
|
|
2005
2119
|
},
|
|
2006
|
-
p(
|
|
2007
|
-
(!
|
|
2008
|
-
|
|
2120
|
+
p(C, A) {
|
|
2121
|
+
(!_ || A[0] & /*placeholder*/
|
|
2122
|
+
512) && p(
|
|
2009
2123
|
s,
|
|
2010
2124
|
"placeholder",
|
|
2011
2125
|
/*placeholder*/
|
|
2012
|
-
|
|
2013
|
-
), (!
|
|
2014
|
-
|
|
2126
|
+
C[9]
|
|
2127
|
+
), (!_ || A[0] & /*placeholder*/
|
|
2128
|
+
512) && p(
|
|
2015
2129
|
s,
|
|
2016
2130
|
"aria-label",
|
|
2017
2131
|
/*placeholder*/
|
|
2018
|
-
|
|
2019
|
-
),
|
|
2132
|
+
C[9]
|
|
2133
|
+
), A[0] & /*searchValue*/
|
|
2020
2134
|
2 && s.value !== /*searchValue*/
|
|
2021
|
-
|
|
2135
|
+
C[1] && ri(
|
|
2022
2136
|
s,
|
|
2023
2137
|
/*searchValue*/
|
|
2024
|
-
|
|
2025
|
-
), (!
|
|
2026
|
-
8) &&
|
|
2138
|
+
C[1]
|
|
2139
|
+
), (!_ || A[0] & /*clearButtonTitle*/
|
|
2140
|
+
8) && p(
|
|
2027
2141
|
h,
|
|
2028
2142
|
"title",
|
|
2029
2143
|
/*clearButtonTitle*/
|
|
2030
|
-
|
|
2144
|
+
C[3]
|
|
2031
2145
|
), /*abortController*/
|
|
2032
|
-
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
}),
|
|
2036
|
-
2) &&
|
|
2146
|
+
C[20] ? x ? A[0] & /*abortController*/
|
|
2147
|
+
1048576 && Z(x, 1) : (x = pi(), x.c(), Z(x, 1), x.m(u, null)) : x && (at(), V(x, 1, 1, () => {
|
|
2148
|
+
x = null;
|
|
2149
|
+
}), ct()), (!_ || A[0] & /*searchValue*/
|
|
2150
|
+
2) && he(
|
|
2037
2151
|
u,
|
|
2038
2152
|
"displayable",
|
|
2039
2153
|
/*searchValue*/
|
|
2040
|
-
|
|
2154
|
+
C[1] !== ""
|
|
2041
2155
|
), /*enableReverse*/
|
|
2042
|
-
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
}),
|
|
2046
|
-
|
|
2047
|
-
|
|
2156
|
+
C[6] === "button" ? S ? (S.p(C, A), A[0] & /*enableReverse*/
|
|
2157
|
+
64 && Z(S, 1)) : (S = yi(C), S.c(), Z(S, 1), S.m(n, m)) : S && (at(), V(S, 1, 1, () => {
|
|
2158
|
+
S = null;
|
|
2159
|
+
}), ct()), w && w.p && (!_ || A[2] & /*$$scope*/
|
|
2160
|
+
16) && kn(
|
|
2161
|
+
w,
|
|
2162
|
+
T,
|
|
2048
2163
|
C,
|
|
2049
|
-
M,
|
|
2050
2164
|
/*$$scope*/
|
|
2051
|
-
|
|
2052
|
-
|
|
2053
|
-
|
|
2165
|
+
C[66],
|
|
2166
|
+
_ ? Cn(
|
|
2167
|
+
T,
|
|
2054
2168
|
/*$$scope*/
|
|
2055
|
-
|
|
2056
|
-
|
|
2169
|
+
C[66],
|
|
2170
|
+
A,
|
|
2057
2171
|
null
|
|
2058
|
-
) :
|
|
2172
|
+
) : Nn(
|
|
2059
2173
|
/*$$scope*/
|
|
2060
|
-
|
|
2174
|
+
C[66]
|
|
2061
2175
|
),
|
|
2062
2176
|
null
|
|
2063
2177
|
);
|
|
2064
|
-
let
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
}),
|
|
2068
|
-
4 &&
|
|
2178
|
+
let oe = v;
|
|
2179
|
+
v = K(C), v === oe ? ~v && R[v].p(C, A) : (y && (at(), V(R[oe], 1, 1, () => {
|
|
2180
|
+
R[oe] = null;
|
|
2181
|
+
}), ct()), ~v ? (y = R[v], y ? y.p(C, A) : (y = R[v] = M[v](C), y.c()), Z(y, 1), y.m(t, null)) : y = null), (!_ || A[0] & /*className*/
|
|
2182
|
+
4 && E !== (E = dt(
|
|
2069
2183
|
/*className*/
|
|
2070
|
-
|
|
2071
|
-
) + " svelte-
|
|
2072
|
-
|
|
2184
|
+
C[2]
|
|
2185
|
+
) + " svelte-bz0zu3")) && p(t, "class", E), (!_ || A[0] & /*className, collapsed, searchValue*/
|
|
2186
|
+
38) && he(
|
|
2073
2187
|
t,
|
|
2074
2188
|
"can-collapse",
|
|
2075
2189
|
/*collapsed*/
|
|
2076
|
-
|
|
2077
|
-
|
|
2190
|
+
C[5] && /*searchValue*/
|
|
2191
|
+
C[1] === ""
|
|
2078
2192
|
);
|
|
2079
2193
|
},
|
|
2080
|
-
i(
|
|
2081
|
-
|
|
2194
|
+
i(C) {
|
|
2195
|
+
_ || (Z(N), Z(o.$$.fragment, C), Z(a.$$.fragment, C), Z(x), Z(S), Z(w, C), Z(y), _ = !0);
|
|
2082
2196
|
},
|
|
2083
|
-
o(
|
|
2084
|
-
V(
|
|
2197
|
+
o(C) {
|
|
2198
|
+
V(N), V(o.$$.fragment, C), V(a.$$.fragment, C), V(x), V(S), V(w, C), V(y), _ = !1;
|
|
2085
2199
|
},
|
|
2086
|
-
d(
|
|
2087
|
-
|
|
2200
|
+
d(C) {
|
|
2201
|
+
C && (U(e), U(t)), ye(o), i[69](null), ye(a), x && x.d(), S && S.d(), w && w.d(C), ~v && R[v].d(), L = !1, be(P);
|
|
2088
2202
|
}
|
|
2089
2203
|
};
|
|
2090
2204
|
}
|
|
2091
|
-
function
|
|
2092
|
-
let n, { $$slots:
|
|
2093
|
-
const
|
|
2205
|
+
function Pr(i, e, t) {
|
|
2206
|
+
let n, r, o, { $$slots: l = {}, $$scope: s } = e;
|
|
2207
|
+
const c = {
|
|
2094
2208
|
continental_marine: 4,
|
|
2095
2209
|
country: 4,
|
|
2096
2210
|
major_landform: 8,
|
|
@@ -2114,383 +2228,410 @@ function wr(i, e, t) {
|
|
|
2114
2228
|
"poi.restaurant": 18,
|
|
2115
2229
|
"poi.aerodrome": 13
|
|
2116
2230
|
};
|
|
2117
|
-
let { class:
|
|
2231
|
+
let { class: u = void 0 } = e, { apiKey: h } = e, { bbox: a = void 0 } = e, { clearButtonTitle: f = "clear" } = e, { clearOnBlur: d = !1 } = e, { clearListOnPick: m = !1 } = e, { keepListOpen: b = !1 } = e, { collapsed: v = !1 } = e, { country: y = void 0 } = e, { debounceSearch: E = 200 } = e, { enableReverse: _ = "never" } = e, { errorMessage: L = "Something went wrong…" } = e, { filter: P = () => !0 } = e, { flyTo: N = !0 } = e, { fuzzyMatch: x = !0 } = e, { language: S = void 0 } = e, { limit: T = void 0 } = e, { mapController: w = void 0 } = e, { minLength: M = 2 } = e, { noResultsMessage: R = "Oops! Looks like you're trying to predict something that's not quite right. We can't seem to find what you're looking for. Maybe try double-checking your spelling or try a different search term. Keep on typing - we'll do our best to get you where you need to go!" } = e, { placeholder: K = "Search" } = e, { proximity: C = [{ type: "server-geolocation" }] } = e, { reverseActive: A = _ === "always" } = e, { reverseButtonTitle: oe = "toggle reverse geocoding" } = e, { searchValue: j = "" } = e, { pickedResultStyle: Je = "full-geometry" } = e, { showPlaceType: Vt = "if-needed" } = e, { showResultsWhileTyping: $e = !0 } = e, { selectFirst: Oe = !0 } = e, { flyToSelected: et = !1 } = e, { markerOnSelected: tt = !0 } = e, { types: Ne = void 0 } = e, { exhaustiveReverseGeocoding: mt = !1 } = e, { excludeTypes: it = !1 } = e, { zoom: nt = c } = e, { apiUrl: pt = "https://api.maptiler.com/geocoding" } = e, { fetchParameters: yt = {} } = e, { iconsBaseUrl: Yt = "https://cdn.maptiler.com/maptiler-geocoding-control/v2.1.0-rc1/icons/" } = e, { adjustUrlQuery: bt = () => {
|
|
2232
|
+
} } = e, { adjustUrl: vt = () => {
|
|
2118
2233
|
} } = e;
|
|
2119
|
-
function
|
|
2120
|
-
|
|
2234
|
+
function $i(g) {
|
|
2235
|
+
se.focus(g);
|
|
2121
2236
|
}
|
|
2122
|
-
function
|
|
2123
|
-
|
|
2237
|
+
function en() {
|
|
2238
|
+
se.blur();
|
|
2124
2239
|
}
|
|
2125
|
-
function
|
|
2126
|
-
t(1,
|
|
2127
|
-
|
|
2240
|
+
function Xt(g, G = !0, q = !1) {
|
|
2241
|
+
t(1, j = g), G ? (t(15, W = -1), Jt()) : ($t(void 0, !q, q), setTimeout(() => {
|
|
2242
|
+
se.focus(), se.select();
|
|
2128
2243
|
}));
|
|
2129
2244
|
}
|
|
2130
|
-
function
|
|
2131
|
-
t(
|
|
2245
|
+
function tn() {
|
|
2246
|
+
t(13, O = void 0), t(14, k = void 0), t(15, W = -1);
|
|
2132
2247
|
}
|
|
2133
|
-
function
|
|
2134
|
-
t(
|
|
2248
|
+
function nn() {
|
|
2249
|
+
t(61, Q = []), t(14, k = void 0);
|
|
2135
2250
|
}
|
|
2136
|
-
let
|
|
2137
|
-
const
|
|
2138
|
-
|
|
2139
|
-
|
|
2251
|
+
let O, Q, k, Kt = "", se, W = -1, fe, rt = [], Pe, Ie, ze, _t, ge = !1;
|
|
2252
|
+
const rn = /* @__PURE__ */ new Set(), ve = Ui();
|
|
2253
|
+
In(() => {
|
|
2254
|
+
w && (w.setEventHandler(void 0), w.indicateReverse(!1), w.setSelectedMarker(-1), w.setFeatures(void 0, void 0, !1));
|
|
2140
2255
|
});
|
|
2141
|
-
function
|
|
2142
|
-
if (Ie && (clearTimeout(Ie), Ie = void 0),
|
|
2143
|
-
t(
|
|
2144
|
-
else if (
|
|
2145
|
-
const
|
|
2146
|
-
|
|
2147
|
-
t(
|
|
2148
|
-
}).catch((
|
|
2256
|
+
function Jt(g) {
|
|
2257
|
+
if (t(17, ge = !1), Ie && (clearTimeout(Ie), Ie = void 0), W > -1 && O)
|
|
2258
|
+
t(14, k = O[W]), t(1, j = k.place_type[0] === "reverse" ? k.place_name : k.place_name.replace(/,.*/, "")), t(19, fe = void 0), t(61, Q = void 0), t(15, W = -1);
|
|
2259
|
+
else if (j) {
|
|
2260
|
+
const G = g || !wt(j);
|
|
2261
|
+
Et(j, { exact: !0 }).then(() => {
|
|
2262
|
+
t(61, Q = O), t(14, k = void 0), G && on();
|
|
2263
|
+
}).catch((q) => t(19, fe = q));
|
|
2149
2264
|
}
|
|
2150
2265
|
}
|
|
2151
|
-
function
|
|
2266
|
+
function wt(g) {
|
|
2152
2267
|
try {
|
|
2153
|
-
return
|
|
2268
|
+
return Sr(g, 6);
|
|
2154
2269
|
} catch {
|
|
2155
2270
|
return !1;
|
|
2156
2271
|
}
|
|
2157
2272
|
}
|
|
2158
|
-
async function
|
|
2159
|
-
|
|
2160
|
-
|
|
2161
|
-
|
|
2273
|
+
async function Et(g, { byId: G = !1, exact: q = !1 } = {}) {
|
|
2274
|
+
var ee, de;
|
|
2275
|
+
t(19, fe = void 0), Pe == null || Pe.abort();
|
|
2276
|
+
const $ = new AbortController();
|
|
2277
|
+
t(20, Pe = $);
|
|
2162
2278
|
try {
|
|
2163
|
-
const
|
|
2164
|
-
if (S !== void 0 &&
|
|
2165
|
-
const
|
|
2166
|
-
|
|
2279
|
+
const z = wt(g), xt = new URL(pt + "/" + encodeURIComponent(z ? z.decimalLongitude + "," + z.decimalLatitude : g) + ".json"), le = xt.searchParams;
|
|
2280
|
+
if (S !== void 0 && le.set("language", Array.isArray(S) ? S.join(",") : S ?? ""), Ne && le.set("types", Ne.join(",")), it && le.set("excludeTypes", String(it)), a && le.set("bbox", a.map((st) => st.toFixed(6)).join(",")), y && le.set("country", Array.isArray(y) ? y.join(",") : y), !G && !z) {
|
|
2281
|
+
const st = await hr(w, C, $);
|
|
2282
|
+
st && le.set("proximity", st), (q || !$e) && le.set("autocomplete", "false"), le.set("fuzzyMatch", String(x));
|
|
2167
2283
|
}
|
|
2168
|
-
|
|
2169
|
-
const
|
|
2170
|
-
if (
|
|
2171
|
-
|
|
2284
|
+
T !== void 0 && (mt || !z || (Ne == null ? void 0 : Ne.length) === 1) && le.set("limit", String(T)), le.set("key", h), bt(le), vt(xt);
|
|
2285
|
+
const ot = xt.toString();
|
|
2286
|
+
if (ot === Kt) {
|
|
2287
|
+
G ? (m && t(13, O = void 0), t(14, k = rt[0])) : (t(13, O = rt), ((ee = O[W]) == null ? void 0 : ee.id) !== (r == null ? void 0 : r.id) && t(15, W = -1));
|
|
2172
2288
|
return;
|
|
2173
2289
|
}
|
|
2174
|
-
|
|
2175
|
-
const
|
|
2176
|
-
if (!
|
|
2177
|
-
throw new Error(await
|
|
2178
|
-
const
|
|
2179
|
-
|
|
2290
|
+
Kt = ot;
|
|
2291
|
+
const Mt = await fetch(ot, { signal: $.signal, ...yt });
|
|
2292
|
+
if (!Mt.ok)
|
|
2293
|
+
throw new Error(await Mt.text());
|
|
2294
|
+
const Ct = await Mt.json();
|
|
2295
|
+
ve("response", { url: ot, featureCollection: Ct }), G ? (m && t(13, O = void 0), t(14, k = Ct.features[0]), rt = [k]) : (t(13, O = Ct.features.filter(P)), z && O.unshift({
|
|
2180
2296
|
type: "Feature",
|
|
2181
2297
|
properties: {},
|
|
2182
|
-
id: "reverse_" +
|
|
2183
|
-
text:
|
|
2184
|
-
place_name:
|
|
2298
|
+
id: "reverse_" + z.decimalLongitude + "_" + z.decimalLatitude,
|
|
2299
|
+
text: z.decimalLatitude + ", " + z.decimalLongitude,
|
|
2300
|
+
place_name: z.decimalLatitude + ", " + z.decimalLongitude,
|
|
2185
2301
|
place_type: ["reverse"],
|
|
2186
|
-
center: [
|
|
2302
|
+
center: [z.decimalLongitude, z.decimalLatitude],
|
|
2187
2303
|
bbox: [
|
|
2188
|
-
|
|
2189
|
-
|
|
2190
|
-
|
|
2191
|
-
|
|
2304
|
+
z.decimalLongitude,
|
|
2305
|
+
z.decimalLatitude,
|
|
2306
|
+
z.decimalLongitude,
|
|
2307
|
+
z.decimalLatitude
|
|
2192
2308
|
],
|
|
2193
2309
|
geometry: {
|
|
2194
2310
|
type: "Point",
|
|
2195
|
-
coordinates: [
|
|
2311
|
+
coordinates: [z.decimalLongitude, z.decimalLatitude]
|
|
2196
2312
|
}
|
|
2197
|
-
}),
|
|
2198
|
-
} catch (
|
|
2199
|
-
if (
|
|
2313
|
+
}), rt = O, ((de = O[W]) == null ? void 0 : de.id) !== (r == null ? void 0 : r.id) && t(15, W = -1), z && se.focus());
|
|
2314
|
+
} catch (z) {
|
|
2315
|
+
if (z && typeof z == "object" && "name" in z && z.name === "AbortError")
|
|
2200
2316
|
return;
|
|
2201
|
-
throw
|
|
2317
|
+
throw z;
|
|
2202
2318
|
} finally {
|
|
2203
|
-
|
|
2319
|
+
$ === Pe && t(20, Pe = void 0);
|
|
2204
2320
|
}
|
|
2205
2321
|
}
|
|
2206
|
-
function
|
|
2207
|
-
var
|
|
2208
|
-
if (!(
|
|
2322
|
+
function on() {
|
|
2323
|
+
var $;
|
|
2324
|
+
if (!(Q != null && Q.length) || !N)
|
|
2209
2325
|
return;
|
|
2210
|
-
const g = [180, 90, -180, -90],
|
|
2211
|
-
let
|
|
2212
|
-
for (const
|
|
2213
|
-
const
|
|
2214
|
-
if (
|
|
2215
|
-
for (const
|
|
2216
|
-
g[
|
|
2326
|
+
const g = [180, 90, -180, -90], G = !Q.some((ee) => !ee.matching_text);
|
|
2327
|
+
let q;
|
|
2328
|
+
for (const ee of Q) {
|
|
2329
|
+
const de = Ue(ee);
|
|
2330
|
+
if (q = q === void 0 ? de : de === void 0 ? q : Math.max(q, de), G || !ee.matching_text)
|
|
2331
|
+
for (const z of [0, 1, 2, 3])
|
|
2332
|
+
g[z] = Math[z < 2 ? "min" : "max"](g[z], (($ = ee.bbox) == null ? void 0 : $[z]) ?? ee.center[z % 2]);
|
|
2217
2333
|
}
|
|
2218
|
-
|
|
2334
|
+
w && Q.length > 0 && (k && g[0] === g[2] && g[1] === g[3] ? w.flyTo(k.center, Ue(k)) : w.fitBounds(He(g), 50, q));
|
|
2219
2335
|
}
|
|
2220
|
-
function
|
|
2221
|
-
|
|
2336
|
+
function Lt() {
|
|
2337
|
+
!k || !w || (!k.bbox || k.bbox[0] === k.bbox[2] && k.bbox[1] === k.bbox[3] ? w.flyTo(k.center, Ue(k)) : w.fitBounds(He(k.bbox), 50, Ue(k)));
|
|
2338
|
+
}
|
|
2339
|
+
function Ue(g) {
|
|
2340
|
+
var q;
|
|
2222
2341
|
if (!g.bbox || g.bbox[0] !== g.bbox[2] && g.bbox[1] !== g.bbox[3])
|
|
2223
2342
|
return;
|
|
2224
|
-
|
|
2225
|
-
|
|
2226
|
-
|
|
2227
|
-
|
|
2228
|
-
|
|
2229
|
-
const Q = Te[j + "." + P];
|
|
2230
|
-
return ee === void 0 ? Q : Q === void 0 ? ee : Math.max(ee, Q);
|
|
2343
|
+
const G = g.id.replace(/\..*/, "");
|
|
2344
|
+
return (Array.isArray((q = g.properties) == null ? void 0 : q.categories) ? g.properties.categories.reduce(
|
|
2345
|
+
($, ee) => {
|
|
2346
|
+
const de = nt[G + "." + ee];
|
|
2347
|
+
return $ === void 0 ? de : de === void 0 ? $ : Math.max($, de);
|
|
2231
2348
|
},
|
|
2232
2349
|
void 0
|
|
2233
|
-
) : void 0) ??
|
|
2350
|
+
) : void 0) ?? nt[G];
|
|
2234
2351
|
}
|
|
2235
|
-
function
|
|
2236
|
-
t(0,
|
|
2352
|
+
function sn(g) {
|
|
2353
|
+
t(0, A = _ === "always"), t(13, O = void 0), t(14, k = void 0), t(15, W = -1), Xt(g[1].toFixed(6) + ", " + dr(g[0], [-180, 180], !0).toFixed(6), !1, !0);
|
|
2237
2354
|
}
|
|
2238
|
-
function
|
|
2239
|
-
if (!
|
|
2355
|
+
function ln(g) {
|
|
2356
|
+
if (!O)
|
|
2240
2357
|
return;
|
|
2241
|
-
let
|
|
2242
|
-
|
|
2358
|
+
let G = g.key === "ArrowDown" ? 1 : g.key === "ArrowUp" ? -1 : 0;
|
|
2359
|
+
G && (se.focus(), t(17, ge = !0), g.preventDefault(), k && W === -1 && t(15, W = O.findIndex((q) => q.id === (k == null ? void 0 : k.id))), W === (k || Oe ? 0 : -1) && G === -1 && t(15, W = O.length), t(15, W += G), W >= O.length && t(15, W = -1), W < 0 && (k || Oe) && t(15, W = 0));
|
|
2243
2360
|
}
|
|
2244
|
-
function
|
|
2245
|
-
if (t(
|
|
2246
|
-
if (Ie && clearTimeout(Ie),
|
|
2361
|
+
function $t(g, G = !0, q = !1) {
|
|
2362
|
+
if (t(19, fe = void 0), t(14, k = void 0), t(17, ge = !0), $e || q) {
|
|
2363
|
+
if (Ie && clearTimeout(Ie), j.length < M)
|
|
2247
2364
|
return;
|
|
2248
|
-
const
|
|
2365
|
+
const $ = j;
|
|
2249
2366
|
Ie = window.setTimeout(
|
|
2250
2367
|
() => {
|
|
2251
|
-
|
|
2368
|
+
Et($).catch((ee) => t(19, fe = ee));
|
|
2252
2369
|
},
|
|
2253
|
-
|
|
2370
|
+
G ? E : 0
|
|
2254
2371
|
);
|
|
2255
2372
|
} else
|
|
2256
|
-
t(
|
|
2373
|
+
t(13, O = void 0), t(19, fe = void 0);
|
|
2257
2374
|
}
|
|
2258
|
-
function
|
|
2259
|
-
|
|
2375
|
+
function St(g) {
|
|
2376
|
+
k && (k == null ? void 0 : k.id) === (g == null ? void 0 : g.id) ? Lt() : (t(14, k = g), t(1, j = g.place_name));
|
|
2260
2377
|
}
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
|
|
2264
|
-
|
|
2378
|
+
function ei(g) {
|
|
2379
|
+
t(15, W = g);
|
|
2380
|
+
}
|
|
2381
|
+
function un() {
|
|
2382
|
+
(!Oe || k) && t(15, W = -1), et && Lt();
|
|
2383
|
+
}
|
|
2384
|
+
const an = () => se.focus();
|
|
2385
|
+
function cn(g) {
|
|
2386
|
+
It[g ? "unshift" : "push"](() => {
|
|
2387
|
+
se = g, t(18, se);
|
|
2265
2388
|
});
|
|
2266
2389
|
}
|
|
2267
|
-
function
|
|
2268
|
-
|
|
2390
|
+
function fn() {
|
|
2391
|
+
j = this.value, t(1, j), t(17, ge), t(31, d), t(16, ze);
|
|
2269
2392
|
}
|
|
2270
|
-
const
|
|
2271
|
-
t(1,
|
|
2272
|
-
},
|
|
2273
|
-
se || t(15, U = -1);
|
|
2274
|
-
}, fn = () => {
|
|
2393
|
+
const dn = () => t(17, ge = !0), hn = () => t(17, ge = !1), gn = () => t(17, ge = !0), mn = () => t(14, k = void 0), pn = () => {
|
|
2394
|
+
t(1, j = ""), se.focus();
|
|
2395
|
+
}, yn = () => t(0, A = !A), bn = () => t(19, fe = void 0), vn = (g) => ei(g), _n = (g) => St(g), wn = () => {
|
|
2275
2396
|
};
|
|
2276
2397
|
return i.$$set = (g) => {
|
|
2277
|
-
"class" in g && t(2,
|
|
2398
|
+
"class" in g && t(2, u = g.class), "apiKey" in g && t(29, h = g.apiKey), "bbox" in g && t(30, a = g.bbox), "clearButtonTitle" in g && t(3, f = g.clearButtonTitle), "clearOnBlur" in g && t(31, d = g.clearOnBlur), "clearListOnPick" in g && t(32, m = g.clearListOnPick), "keepListOpen" in g && t(4, b = g.keepListOpen), "collapsed" in g && t(5, v = g.collapsed), "country" in g && t(33, y = g.country), "debounceSearch" in g && t(34, E = g.debounceSearch), "enableReverse" in g && t(6, _ = g.enableReverse), "errorMessage" in g && t(7, L = g.errorMessage), "filter" in g && t(35, P = g.filter), "flyTo" in g && t(36, N = g.flyTo), "fuzzyMatch" in g && t(37, x = g.fuzzyMatch), "language" in g && t(38, S = g.language), "limit" in g && t(39, T = g.limit), "mapController" in g && t(40, w = g.mapController), "minLength" in g && t(41, M = g.minLength), "noResultsMessage" in g && t(8, R = g.noResultsMessage), "placeholder" in g && t(9, K = g.placeholder), "proximity" in g && t(42, C = g.proximity), "reverseActive" in g && t(0, A = g.reverseActive), "reverseButtonTitle" in g && t(10, oe = g.reverseButtonTitle), "searchValue" in g && t(1, j = g.searchValue), "pickedResultStyle" in g && t(43, Je = g.pickedResultStyle), "showPlaceType" in g && t(11, Vt = g.showPlaceType), "showResultsWhileTyping" in g && t(44, $e = g.showResultsWhileTyping), "selectFirst" in g && t(45, Oe = g.selectFirst), "flyToSelected" in g && t(46, et = g.flyToSelected), "markerOnSelected" in g && t(47, tt = g.markerOnSelected), "types" in g && t(48, Ne = g.types), "exhaustiveReverseGeocoding" in g && t(49, mt = g.exhaustiveReverseGeocoding), "excludeTypes" in g && t(50, it = g.excludeTypes), "zoom" in g && t(51, nt = g.zoom), "apiUrl" in g && t(52, pt = g.apiUrl), "fetchParameters" in g && t(53, yt = g.fetchParameters), "iconsBaseUrl" in g && t(12, Yt = g.iconsBaseUrl), "adjustUrlQuery" in g && t(54, bt = g.adjustUrlQuery), "adjustUrl" in g && t(55, vt = g.adjustUrl), "$$scope" in g && t(66, s = g.$$scope);
|
|
2278
2399
|
}, i.$$.update = () => {
|
|
2279
2400
|
if (i.$$.dirty[0] & /*enableReverse*/
|
|
2280
|
-
|
|
2281
|
-
|
|
2282
|
-
|
|
2401
|
+
64 && t(0, A = _ === "always"), i.$$.dirty[0] & /*picked*/
|
|
2402
|
+
16384 | i.$$.dirty[1] & /*pickedResultStyle*/
|
|
2403
|
+
4096 && Je !== "marker-only" && k && !k.address && k.geometry.type === "Point" && k.place_type[0] !== "reverse" && Et(k.id, { byId: !0 }).catch((g) => t(19, fe = g)), i.$$.dirty[0] & /*picked*/
|
|
2404
|
+
16384 | i.$$.dirty[1] & /*mapController, flyTo, clearListOnPick*/
|
|
2405
|
+
546 | i.$$.dirty[2] & /*prevIdToFly*/
|
|
2406
|
+
1 && (w && k && k.id !== _t && N && (Lt(), m && t(13, O = void 0), t(61, Q = void 0), t(15, W = -1)), t(62, _t = k == null ? void 0 : k.id)), i.$$.dirty[0] & /*focused, focusedDelayed*/
|
|
2407
|
+
196608 | i.$$.dirty[1] & /*clearOnBlur*/
|
|
2408
|
+
1 && setTimeout(() => {
|
|
2409
|
+
t(16, ze = ge), d && !ze && t(1, j = "");
|
|
2283
2410
|
}), i.$$.dirty[0] & /*searchValue, listFeatures*/
|
|
2284
|
-
|
|
2285
|
-
|
|
2286
|
-
|
|
2287
|
-
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
|
|
2291
|
-
|
|
2292
|
-
81921 | i.$$.dirty[1] & /*mapController, markedFeatures*/
|
|
2293
|
-
33554464 && x && x.setEventHandler((g) => {
|
|
2411
|
+
8194 | i.$$.dirty[1] & /*minLength*/
|
|
2412
|
+
1024 && j.length < M && (t(13, O = void 0), t(19, fe = void 0), t(61, Q = O)), i.$$.dirty[0] & /*listFeatures, selectedItemIndex, picked*/
|
|
2413
|
+
57344 | i.$$.dirty[1] & /*selectFirst*/
|
|
2414
|
+
16384 && Oe && O != null && O.length && W == -1 && !k && t(15, W = 0), i.$$.dirty[0] & /*listFeatures*/
|
|
2415
|
+
8192 | i.$$.dirty[1] & /*markedFeatures*/
|
|
2416
|
+
1073741824 && Q !== O && t(61, Q = void 0), i.$$.dirty[0] & /*reverseActive, listFeatures, focusedDelayed*/
|
|
2417
|
+
73729 | i.$$.dirty[1] & /*mapController, markedFeatures*/
|
|
2418
|
+
1073742336 && w && w.setEventHandler((g) => {
|
|
2294
2419
|
switch (g.type) {
|
|
2295
2420
|
case "mapClick":
|
|
2296
|
-
|
|
2421
|
+
A && sn(g.coordinates);
|
|
2297
2422
|
break;
|
|
2298
2423
|
case "markerClick":
|
|
2299
2424
|
{
|
|
2300
|
-
const
|
|
2301
|
-
|
|
2425
|
+
const G = O == null ? void 0 : O.find((q) => q.id === g.id);
|
|
2426
|
+
G && St(G);
|
|
2302
2427
|
}
|
|
2303
2428
|
break;
|
|
2304
2429
|
case "markerMouseEnter":
|
|
2305
|
-
|
|
2430
|
+
Q && t(15, W = ze ? (O == null ? void 0 : O.findIndex((G) => G.id === g.id)) ?? -1 : -1);
|
|
2306
2431
|
break;
|
|
2307
2432
|
case "markerMouseLeave":
|
|
2308
|
-
|
|
2433
|
+
Q && t(15, W = -1);
|
|
2309
2434
|
break;
|
|
2310
2435
|
}
|
|
2311
2436
|
}), i.$$.dirty[0] & /*listFeatures, selectedItemIndex*/
|
|
2312
|
-
|
|
2313
|
-
|
|
2314
|
-
|
|
2315
|
-
|
|
2316
|
-
|
|
2437
|
+
40960 && t(63, r = O == null ? void 0 : O[W]), i.$$.dirty[1] & /*mapController, flyTo, flyToSelected*/
|
|
2438
|
+
33312 | i.$$.dirty[2] & /*selected*/
|
|
2439
|
+
2 && w && r && N && et && w.flyTo(r.center, Ue(r)), i.$$.dirty[1] & /*pickedResultStyle*/
|
|
2440
|
+
4096 && t(65, n = Je === "full-geometry-including-polygon-center-marker"), i.$$.dirty[1] & /*markerOnSelected, mapController*/
|
|
2441
|
+
66048 | i.$$.dirty[2] & /*showPolygonMarker*/
|
|
2442
|
+
8 && (tt || w == null || w.setFeatures(void 0, void 0, n)), i.$$.dirty[0] & /*picked*/
|
|
2443
|
+
16384 | i.$$.dirty[1] & /*mapController, markerOnSelected, markedFeatures*/
|
|
2444
|
+
1073807872 | i.$$.dirty[2] & /*selected, showPolygonMarker*/
|
|
2445
|
+
10 && w && tt && !Q && (w.setFeatures(r ? [r] : void 0, k, n), w.setSelectedMarker(r ? 0 : -1)), i.$$.dirty[0] & /*picked*/
|
|
2446
|
+
16384 | i.$$.dirty[1] & /*mapController, markedFeatures*/
|
|
2447
|
+
1073742336 | i.$$.dirty[2] & /*showPolygonMarker*/
|
|
2448
|
+
8 && w && w.setFeatures(Q, k, n), i.$$.dirty[0] & /*selectedItemIndex*/
|
|
2317
2449
|
32768 | i.$$.dirty[1] & /*markedFeatures, mapController*/
|
|
2318
|
-
|
|
2450
|
+
1073742336 && Q && w && w.setSelectedMarker(W), i.$$.dirty[0] & /*searchValue*/
|
|
2319
2451
|
2 | i.$$.dirty[1] & /*mapController*/
|
|
2320
|
-
|
|
2321
|
-
const g =
|
|
2322
|
-
|
|
2452
|
+
512 && w) {
|
|
2453
|
+
const g = wt(j);
|
|
2454
|
+
w.setReverseMarker(g ? [g.decimalLongitude, g.decimalLatitude] : void 0);
|
|
2323
2455
|
}
|
|
2324
|
-
i.$$.dirty[
|
|
2325
|
-
|
|
2326
|
-
|
|
2327
|
-
|
|
2328
|
-
|
|
2329
|
-
|
|
2330
|
-
|
|
2331
|
-
|
|
2456
|
+
i.$$.dirty[2] & /*selected*/
|
|
2457
|
+
2 && ve("select", { feature: r }), i.$$.dirty[0] & /*picked*/
|
|
2458
|
+
16384 && ve("pick", { feature: k }), i.$$.dirty[0] & /*listFeatures, focusedDelayed, keepListOpen*/
|
|
2459
|
+
73744 && t(64, o = !!(O != null && O.length) && (ze || b)), i.$$.dirty[2] & /*optionsVisible*/
|
|
2460
|
+
4 && ve("optionsvisibilitychange", { optionsVisible: o }), i.$$.dirty[0] & /*listFeatures*/
|
|
2461
|
+
8192 && ve("featureslisted", { features: O }), i.$$.dirty[1] & /*markedFeatures*/
|
|
2462
|
+
1073741824 && ve("featuresmarked", { features: Q }), i.$$.dirty[0] & /*reverseActive*/
|
|
2463
|
+
1 && ve("reversetoggle", { reverse: A }), i.$$.dirty[0] & /*searchValue*/
|
|
2464
|
+
2 && ve("querychange", { query: j }), i.$$.dirty[0] & /*reverseActive*/
|
|
2332
2465
|
1 | i.$$.dirty[1] & /*mapController*/
|
|
2333
|
-
|
|
2466
|
+
512 && w && w.indicateReverse(A);
|
|
2334
2467
|
}, [
|
|
2335
|
-
|
|
2336
|
-
|
|
2337
|
-
|
|
2338
|
-
h,
|
|
2468
|
+
A,
|
|
2469
|
+
j,
|
|
2470
|
+
u,
|
|
2339
2471
|
f,
|
|
2340
|
-
v,
|
|
2341
2472
|
b,
|
|
2342
|
-
|
|
2343
|
-
|
|
2344
|
-
|
|
2345
|
-
z,
|
|
2346
|
-
se,
|
|
2347
|
-
zt,
|
|
2348
|
-
Re,
|
|
2473
|
+
v,
|
|
2474
|
+
_,
|
|
2475
|
+
L,
|
|
2349
2476
|
R,
|
|
2350
|
-
|
|
2351
|
-
|
|
2352
|
-
|
|
2477
|
+
K,
|
|
2478
|
+
oe,
|
|
2479
|
+
Vt,
|
|
2480
|
+
Yt,
|
|
2481
|
+
O,
|
|
2482
|
+
k,
|
|
2483
|
+
W,
|
|
2484
|
+
ze,
|
|
2485
|
+
ge,
|
|
2486
|
+
se,
|
|
2353
2487
|
fe,
|
|
2354
|
-
|
|
2355
|
-
|
|
2356
|
-
|
|
2357
|
-
|
|
2358
|
-
|
|
2359
|
-
|
|
2360
|
-
|
|
2488
|
+
Pe,
|
|
2489
|
+
rn,
|
|
2490
|
+
Jt,
|
|
2491
|
+
ln,
|
|
2492
|
+
$t,
|
|
2493
|
+
St,
|
|
2494
|
+
ei,
|
|
2495
|
+
un,
|
|
2361
2496
|
c,
|
|
2362
|
-
|
|
2497
|
+
h,
|
|
2363
2498
|
a,
|
|
2364
2499
|
d,
|
|
2365
2500
|
m,
|
|
2366
|
-
|
|
2367
|
-
_,
|
|
2501
|
+
y,
|
|
2368
2502
|
E,
|
|
2369
|
-
|
|
2370
|
-
|
|
2503
|
+
P,
|
|
2504
|
+
N,
|
|
2371
2505
|
x,
|
|
2372
|
-
|
|
2373
|
-
|
|
2506
|
+
S,
|
|
2507
|
+
T,
|
|
2508
|
+
w,
|
|
2374
2509
|
M,
|
|
2375
|
-
|
|
2376
|
-
ct,
|
|
2377
|
-
Xe,
|
|
2378
|
-
Ce,
|
|
2379
|
-
ft,
|
|
2380
|
-
Ke,
|
|
2381
|
-
Te,
|
|
2510
|
+
C,
|
|
2382
2511
|
Je,
|
|
2383
|
-
|
|
2384
|
-
|
|
2385
|
-
|
|
2386
|
-
|
|
2387
|
-
|
|
2388
|
-
jt,
|
|
2389
|
-
Qi,
|
|
2390
|
-
Hi,
|
|
2391
|
-
q,
|
|
2392
|
-
N,
|
|
2512
|
+
$e,
|
|
2513
|
+
Oe,
|
|
2514
|
+
et,
|
|
2515
|
+
tt,
|
|
2516
|
+
Ne,
|
|
2393
2517
|
mt,
|
|
2394
|
-
|
|
2395
|
-
|
|
2396
|
-
|
|
2397
|
-
|
|
2518
|
+
it,
|
|
2519
|
+
nt,
|
|
2520
|
+
pt,
|
|
2521
|
+
yt,
|
|
2522
|
+
bt,
|
|
2523
|
+
vt,
|
|
2398
2524
|
$i,
|
|
2399
2525
|
en,
|
|
2526
|
+
Xt,
|
|
2400
2527
|
tn,
|
|
2401
2528
|
nn,
|
|
2402
|
-
|
|
2403
|
-
|
|
2404
|
-
|
|
2405
|
-
|
|
2406
|
-
|
|
2529
|
+
Q,
|
|
2530
|
+
_t,
|
|
2531
|
+
r,
|
|
2532
|
+
o,
|
|
2533
|
+
n,
|
|
2534
|
+
s,
|
|
2535
|
+
l,
|
|
2407
2536
|
an,
|
|
2408
2537
|
cn,
|
|
2409
|
-
fn
|
|
2538
|
+
fn,
|
|
2539
|
+
dn,
|
|
2540
|
+
hn,
|
|
2541
|
+
gn,
|
|
2542
|
+
mn,
|
|
2543
|
+
pn,
|
|
2544
|
+
yn,
|
|
2545
|
+
bn,
|
|
2546
|
+
vn,
|
|
2547
|
+
_n,
|
|
2548
|
+
wn
|
|
2410
2549
|
];
|
|
2411
2550
|
}
|
|
2412
|
-
let
|
|
2551
|
+
let Tr = class extends ke {
|
|
2413
2552
|
constructor(e) {
|
|
2414
|
-
super(),
|
|
2553
|
+
super(), Ce(
|
|
2415
2554
|
this,
|
|
2416
2555
|
e,
|
|
2417
|
-
|
|
2418
|
-
|
|
2419
|
-
|
|
2556
|
+
Pr,
|
|
2557
|
+
Nr,
|
|
2558
|
+
Me,
|
|
2420
2559
|
{
|
|
2421
|
-
ZOOM_DEFAULTS:
|
|
2560
|
+
ZOOM_DEFAULTS: 28,
|
|
2422
2561
|
class: 2,
|
|
2423
|
-
apiKey:
|
|
2424
|
-
bbox:
|
|
2562
|
+
apiKey: 29,
|
|
2563
|
+
bbox: 30,
|
|
2425
2564
|
clearButtonTitle: 3,
|
|
2426
|
-
clearOnBlur:
|
|
2427
|
-
|
|
2428
|
-
|
|
2429
|
-
|
|
2430
|
-
|
|
2431
|
-
|
|
2432
|
-
|
|
2433
|
-
|
|
2434
|
-
|
|
2435
|
-
|
|
2436
|
-
|
|
2437
|
-
|
|
2438
|
-
|
|
2439
|
-
|
|
2440
|
-
|
|
2441
|
-
|
|
2565
|
+
clearOnBlur: 31,
|
|
2566
|
+
clearListOnPick: 32,
|
|
2567
|
+
keepListOpen: 4,
|
|
2568
|
+
collapsed: 5,
|
|
2569
|
+
country: 33,
|
|
2570
|
+
debounceSearch: 34,
|
|
2571
|
+
enableReverse: 6,
|
|
2572
|
+
errorMessage: 7,
|
|
2573
|
+
filter: 35,
|
|
2574
|
+
flyTo: 36,
|
|
2575
|
+
fuzzyMatch: 37,
|
|
2576
|
+
language: 38,
|
|
2577
|
+
limit: 39,
|
|
2578
|
+
mapController: 40,
|
|
2579
|
+
minLength: 41,
|
|
2580
|
+
noResultsMessage: 8,
|
|
2581
|
+
placeholder: 9,
|
|
2582
|
+
proximity: 42,
|
|
2442
2583
|
reverseActive: 0,
|
|
2443
|
-
reverseButtonTitle:
|
|
2584
|
+
reverseButtonTitle: 10,
|
|
2444
2585
|
searchValue: 1,
|
|
2445
|
-
|
|
2446
|
-
showPlaceType:
|
|
2447
|
-
showResultsWhileTyping:
|
|
2448
|
-
selectFirst:
|
|
2449
|
-
flyToSelected:
|
|
2450
|
-
markerOnSelected:
|
|
2451
|
-
types:
|
|
2452
|
-
exhaustiveReverseGeocoding:
|
|
2453
|
-
excludeTypes:
|
|
2454
|
-
zoom:
|
|
2455
|
-
|
|
2456
|
-
|
|
2457
|
-
fetchParameters: 49,
|
|
2586
|
+
pickedResultStyle: 43,
|
|
2587
|
+
showPlaceType: 11,
|
|
2588
|
+
showResultsWhileTyping: 44,
|
|
2589
|
+
selectFirst: 45,
|
|
2590
|
+
flyToSelected: 46,
|
|
2591
|
+
markerOnSelected: 47,
|
|
2592
|
+
types: 48,
|
|
2593
|
+
exhaustiveReverseGeocoding: 49,
|
|
2594
|
+
excludeTypes: 50,
|
|
2595
|
+
zoom: 51,
|
|
2596
|
+
apiUrl: 52,
|
|
2597
|
+
fetchParameters: 53,
|
|
2458
2598
|
iconsBaseUrl: 12,
|
|
2459
|
-
adjustUrlQuery:
|
|
2460
|
-
|
|
2461
|
-
|
|
2462
|
-
|
|
2463
|
-
|
|
2464
|
-
|
|
2599
|
+
adjustUrlQuery: 54,
|
|
2600
|
+
adjustUrl: 55,
|
|
2601
|
+
focus: 56,
|
|
2602
|
+
blur: 57,
|
|
2603
|
+
setQuery: 58,
|
|
2604
|
+
clearList: 59,
|
|
2605
|
+
clearMap: 60
|
|
2465
2606
|
},
|
|
2466
2607
|
null,
|
|
2467
|
-
[-1, -1, -1]
|
|
2608
|
+
[-1, -1, -1, -1]
|
|
2468
2609
|
);
|
|
2469
2610
|
}
|
|
2470
2611
|
get ZOOM_DEFAULTS() {
|
|
2471
|
-
return this.$$.ctx[
|
|
2612
|
+
return this.$$.ctx[28];
|
|
2472
2613
|
}
|
|
2473
2614
|
get focus() {
|
|
2474
|
-
return this.$$.ctx[
|
|
2615
|
+
return this.$$.ctx[56];
|
|
2475
2616
|
}
|
|
2476
2617
|
get blur() {
|
|
2477
|
-
return this.$$.ctx[
|
|
2618
|
+
return this.$$.ctx[57];
|
|
2478
2619
|
}
|
|
2479
2620
|
get setQuery() {
|
|
2480
|
-
return this.$$.ctx[
|
|
2621
|
+
return this.$$.ctx[58];
|
|
2481
2622
|
}
|
|
2482
2623
|
get clearList() {
|
|
2483
|
-
return this.$$.ctx[
|
|
2624
|
+
return this.$$.ctx[59];
|
|
2484
2625
|
}
|
|
2485
2626
|
get clearMap() {
|
|
2486
|
-
return this.$$.ctx[
|
|
2627
|
+
return this.$$.ctx[60];
|
|
2487
2628
|
}
|
|
2488
2629
|
};
|
|
2489
|
-
function
|
|
2630
|
+
function Ve(i, e, t = {}) {
|
|
2490
2631
|
const n = { type: "Feature" };
|
|
2491
2632
|
return (t.id === 0 || t.id) && (n.id = t.id), t.bbox && (n.bbox = t.bbox), n.properties = e || {}, n.geometry = i, n;
|
|
2492
2633
|
}
|
|
2493
|
-
function
|
|
2634
|
+
function qt(i, e, t = {}) {
|
|
2494
2635
|
for (const r of i) {
|
|
2495
2636
|
if (r.length < 4)
|
|
2496
2637
|
throw new Error(
|
|
@@ -2502,43 +2643,43 @@ function Bt(i, e, t = {}) {
|
|
|
2502
2643
|
if (r[r.length - 1][o] !== r[0][o])
|
|
2503
2644
|
throw new Error("First and last Position are not equivalent.");
|
|
2504
2645
|
}
|
|
2505
|
-
return
|
|
2646
|
+
return Ve({
|
|
2506
2647
|
type: "Polygon",
|
|
2507
2648
|
coordinates: i
|
|
2508
2649
|
}, e, t);
|
|
2509
2650
|
}
|
|
2510
|
-
function
|
|
2651
|
+
function Ye(i, e = {}) {
|
|
2511
2652
|
const t = { type: "FeatureCollection" };
|
|
2512
2653
|
return e.id && (t.id = e.id), e.bbox && (t.bbox = e.bbox), t.features = i, t;
|
|
2513
2654
|
}
|
|
2514
|
-
function
|
|
2515
|
-
return
|
|
2655
|
+
function qi(i, e, t = {}) {
|
|
2656
|
+
return Ve({
|
|
2516
2657
|
type: "MultiPolygon",
|
|
2517
2658
|
coordinates: i
|
|
2518
2659
|
}, e, t);
|
|
2519
2660
|
}
|
|
2520
|
-
function
|
|
2661
|
+
function Zi(i, e, t) {
|
|
2521
2662
|
if (i !== null)
|
|
2522
|
-
for (var n, r, o, l, s, c, u, h = 0, a = 0, f, d = i.type, m = d === "FeatureCollection",
|
|
2523
|
-
u = m ? i.features[
|
|
2524
|
-
for (var
|
|
2525
|
-
var
|
|
2526
|
-
if (l = f ? u.geometries[
|
|
2663
|
+
for (var n, r, o, l, s, c, u, h = 0, a = 0, f, d = i.type, m = d === "FeatureCollection", b = d === "Feature", v = m ? i.features.length : 1, y = 0; y < v; y++) {
|
|
2664
|
+
u = m ? i.features[y].geometry : b ? i.geometry : i, f = u ? u.type === "GeometryCollection" : !1, s = f ? u.geometries.length : 1;
|
|
2665
|
+
for (var E = 0; E < s; E++) {
|
|
2666
|
+
var _ = 0, L = 0;
|
|
2667
|
+
if (l = f ? u.geometries[E] : u, l !== null) {
|
|
2527
2668
|
c = l.coordinates;
|
|
2528
|
-
var
|
|
2529
|
-
switch (h = 0,
|
|
2669
|
+
var P = l.type;
|
|
2670
|
+
switch (h = 0, P) {
|
|
2530
2671
|
case null:
|
|
2531
2672
|
break;
|
|
2532
2673
|
case "Point":
|
|
2533
2674
|
if (e(
|
|
2534
2675
|
c,
|
|
2535
2676
|
a,
|
|
2536
|
-
|
|
2537
|
-
|
|
2538
|
-
|
|
2677
|
+
y,
|
|
2678
|
+
_,
|
|
2679
|
+
L
|
|
2539
2680
|
) === !1)
|
|
2540
2681
|
return !1;
|
|
2541
|
-
a++,
|
|
2682
|
+
a++, _++;
|
|
2542
2683
|
break;
|
|
2543
2684
|
case "LineString":
|
|
2544
2685
|
case "MultiPoint":
|
|
@@ -2546,14 +2687,14 @@ function Bi(i, e, t) {
|
|
|
2546
2687
|
if (e(
|
|
2547
2688
|
c[n],
|
|
2548
2689
|
a,
|
|
2549
|
-
|
|
2550
|
-
|
|
2551
|
-
|
|
2690
|
+
y,
|
|
2691
|
+
_,
|
|
2692
|
+
L
|
|
2552
2693
|
) === !1)
|
|
2553
2694
|
return !1;
|
|
2554
|
-
a++,
|
|
2695
|
+
a++, P === "MultiPoint" && _++;
|
|
2555
2696
|
}
|
|
2556
|
-
|
|
2697
|
+
P === "LineString" && _++;
|
|
2557
2698
|
break;
|
|
2558
2699
|
case "Polygon":
|
|
2559
2700
|
case "MultiLineString":
|
|
@@ -2562,39 +2703,39 @@ function Bi(i, e, t) {
|
|
|
2562
2703
|
if (e(
|
|
2563
2704
|
c[n][r],
|
|
2564
2705
|
a,
|
|
2565
|
-
|
|
2566
|
-
|
|
2567
|
-
|
|
2706
|
+
y,
|
|
2707
|
+
_,
|
|
2708
|
+
L
|
|
2568
2709
|
) === !1)
|
|
2569
2710
|
return !1;
|
|
2570
2711
|
a++;
|
|
2571
2712
|
}
|
|
2572
|
-
|
|
2713
|
+
P === "MultiLineString" && _++, P === "Polygon" && L++;
|
|
2573
2714
|
}
|
|
2574
|
-
|
|
2715
|
+
P === "Polygon" && _++;
|
|
2575
2716
|
break;
|
|
2576
2717
|
case "MultiPolygon":
|
|
2577
2718
|
for (n = 0; n < c.length; n++) {
|
|
2578
|
-
for (
|
|
2719
|
+
for (L = 0, r = 0; r < c[n].length; r++) {
|
|
2579
2720
|
for (o = 0; o < c[n][r].length - h; o++) {
|
|
2580
2721
|
if (e(
|
|
2581
2722
|
c[n][r][o],
|
|
2582
2723
|
a,
|
|
2583
|
-
|
|
2584
|
-
|
|
2585
|
-
|
|
2724
|
+
y,
|
|
2725
|
+
_,
|
|
2726
|
+
L
|
|
2586
2727
|
) === !1)
|
|
2587
2728
|
return !1;
|
|
2588
2729
|
a++;
|
|
2589
2730
|
}
|
|
2590
|
-
|
|
2731
|
+
L++;
|
|
2591
2732
|
}
|
|
2592
|
-
|
|
2733
|
+
_++;
|
|
2593
2734
|
}
|
|
2594
2735
|
break;
|
|
2595
2736
|
case "GeometryCollection":
|
|
2596
2737
|
for (n = 0; n < l.geometries.length; n++)
|
|
2597
|
-
if (
|
|
2738
|
+
if (Zi(l.geometries[n], e) === !1)
|
|
2598
2739
|
return !1;
|
|
2599
2740
|
break;
|
|
2600
2741
|
default:
|
|
@@ -2604,9 +2745,9 @@ function Bi(i, e, t) {
|
|
|
2604
2745
|
}
|
|
2605
2746
|
}
|
|
2606
2747
|
}
|
|
2607
|
-
function
|
|
2608
|
-
var t, n, r, o, l, s, c, u, h, a, f = 0, d = i.type === "FeatureCollection", m = i.type === "Feature",
|
|
2609
|
-
for (t = 0; t <
|
|
2748
|
+
function Zt(i, e) {
|
|
2749
|
+
var t, n, r, o, l, s, c, u, h, a, f = 0, d = i.type === "FeatureCollection", m = i.type === "Feature", b = d ? i.features.length : 1;
|
|
2750
|
+
for (t = 0; t < b; t++) {
|
|
2610
2751
|
for (s = d ? i.features[t].geometry : m ? i.geometry : i, u = d ? i.features[t].properties : m ? i.properties : {}, h = d ? i.features[t].bbox : m ? i.bbox : void 0, a = d ? i.features[t].id : m ? i.id : void 0, c = s ? s.type === "GeometryCollection" : !1, l = c ? s.geometries.length : 1, r = 0; r < l; r++) {
|
|
2611
2752
|
if (o = c ? s.geometries[r] : s, o === null) {
|
|
2612
2753
|
if (e(
|
|
@@ -2655,8 +2796,8 @@ function Dt(i, e) {
|
|
|
2655
2796
|
f++;
|
|
2656
2797
|
}
|
|
2657
2798
|
}
|
|
2658
|
-
function
|
|
2659
|
-
|
|
2799
|
+
function Rr(i, e) {
|
|
2800
|
+
Zt(i, function(t, n, r, o, l) {
|
|
2660
2801
|
var s = t === null ? null : t.type;
|
|
2661
2802
|
switch (s) {
|
|
2662
2803
|
case null:
|
|
@@ -2664,7 +2805,7 @@ function Er(i, e) {
|
|
|
2664
2805
|
case "LineString":
|
|
2665
2806
|
case "Polygon":
|
|
2666
2807
|
return e(
|
|
2667
|
-
|
|
2808
|
+
Ve(t, r, { bbox: o, id: l }),
|
|
2668
2809
|
n,
|
|
2669
2810
|
0
|
|
2670
2811
|
) === !1 ? !1 : void 0;
|
|
@@ -2686,28 +2827,28 @@ function Er(i, e) {
|
|
|
2686
2827
|
type: c,
|
|
2687
2828
|
coordinates: h
|
|
2688
2829
|
};
|
|
2689
|
-
if (e(
|
|
2830
|
+
if (e(Ve(a, r), n, u) === !1)
|
|
2690
2831
|
return !1;
|
|
2691
2832
|
}
|
|
2692
2833
|
});
|
|
2693
2834
|
}
|
|
2694
|
-
function
|
|
2835
|
+
function Or(i, e = {}) {
|
|
2695
2836
|
if (i.bbox != null && e.recompute !== !0)
|
|
2696
2837
|
return i.bbox;
|
|
2697
2838
|
const t = [1 / 0, 1 / 0, -1 / 0, -1 / 0];
|
|
2698
|
-
return
|
|
2839
|
+
return Zi(i, (n) => {
|
|
2699
2840
|
t[0] > n[0] && (t[0] = n[0]), t[1] > n[1] && (t[1] = n[1]), t[2] < n[0] && (t[2] = n[0]), t[3] < n[1] && (t[3] = n[1]);
|
|
2700
2841
|
}), t;
|
|
2701
2842
|
}
|
|
2702
|
-
var
|
|
2703
|
-
function
|
|
2843
|
+
var Wt = Or;
|
|
2844
|
+
function Ir(i) {
|
|
2704
2845
|
if (!i)
|
|
2705
2846
|
throw new Error("geojson is required");
|
|
2706
2847
|
switch (i.type) {
|
|
2707
2848
|
case "Feature":
|
|
2708
|
-
return
|
|
2849
|
+
return Qi(i);
|
|
2709
2850
|
case "FeatureCollection":
|
|
2710
|
-
return
|
|
2851
|
+
return zr(i);
|
|
2711
2852
|
case "Point":
|
|
2712
2853
|
case "LineString":
|
|
2713
2854
|
case "Polygon":
|
|
@@ -2715,12 +2856,12 @@ function Sr(i) {
|
|
|
2715
2856
|
case "MultiLineString":
|
|
2716
2857
|
case "MultiPolygon":
|
|
2717
2858
|
case "GeometryCollection":
|
|
2718
|
-
return
|
|
2859
|
+
return Qt(i);
|
|
2719
2860
|
default:
|
|
2720
2861
|
throw new Error("unknown GeoJSON type");
|
|
2721
2862
|
}
|
|
2722
2863
|
}
|
|
2723
|
-
function
|
|
2864
|
+
function Qi(i) {
|
|
2724
2865
|
const e = { type: "Feature" };
|
|
2725
2866
|
return Object.keys(i).forEach((t) => {
|
|
2726
2867
|
switch (t) {
|
|
@@ -2731,16 +2872,16 @@ function Di(i) {
|
|
|
2731
2872
|
default:
|
|
2732
2873
|
e[t] = i[t];
|
|
2733
2874
|
}
|
|
2734
|
-
}), e.properties =
|
|
2875
|
+
}), e.properties = Hi(i.properties), i.geometry == null ? e.geometry = null : e.geometry = Qt(i.geometry), e;
|
|
2735
2876
|
}
|
|
2736
|
-
function
|
|
2877
|
+
function Hi(i) {
|
|
2737
2878
|
const e = {};
|
|
2738
2879
|
return i && Object.keys(i).forEach((t) => {
|
|
2739
2880
|
const n = i[t];
|
|
2740
|
-
typeof n == "object" ? n === null ? e[t] = null : Array.isArray(n) ? e[t] = n.map((r) => r) : e[t] =
|
|
2881
|
+
typeof n == "object" ? n === null ? e[t] = null : Array.isArray(n) ? e[t] = n.map((r) => r) : e[t] = Hi(n) : e[t] = n;
|
|
2741
2882
|
}), e;
|
|
2742
2883
|
}
|
|
2743
|
-
function
|
|
2884
|
+
function zr(i) {
|
|
2744
2885
|
const e = { type: "FeatureCollection" };
|
|
2745
2886
|
return Object.keys(i).forEach((t) => {
|
|
2746
2887
|
switch (t) {
|
|
@@ -2750,17 +2891,17 @@ function xr(i) {
|
|
|
2750
2891
|
default:
|
|
2751
2892
|
e[t] = i[t];
|
|
2752
2893
|
}
|
|
2753
|
-
}), e.features = i.features.map((t) =>
|
|
2894
|
+
}), e.features = i.features.map((t) => Qi(t)), e;
|
|
2754
2895
|
}
|
|
2755
|
-
function
|
|
2896
|
+
function Qt(i) {
|
|
2756
2897
|
const e = { type: i.type };
|
|
2757
|
-
return i.bbox && (e.bbox = i.bbox), i.type === "GeometryCollection" ? (e.geometries = i.geometries.map((t) =>
|
|
2898
|
+
return i.bbox && (e.bbox = i.bbox), i.type === "GeometryCollection" ? (e.geometries = i.geometries.map((t) => Qt(t)), e) : (e.coordinates = Vi(i.coordinates), e);
|
|
2758
2899
|
}
|
|
2759
|
-
function
|
|
2900
|
+
function Vi(i) {
|
|
2760
2901
|
const e = i;
|
|
2761
|
-
return typeof e[0] != "object" ? e.slice() : e.map((t) =>
|
|
2902
|
+
return typeof e[0] != "object" ? e.slice() : e.map((t) => Vi(t));
|
|
2762
2903
|
}
|
|
2763
|
-
var
|
|
2904
|
+
var Ar = Ir;
|
|
2764
2905
|
/**
|
|
2765
2906
|
* splaytree v3.1.2
|
|
2766
2907
|
* Fast Splay tree for Node and browser
|
|
@@ -2783,7 +2924,7 @@ MERCHANTABLITY OR NON-INFRINGEMENT.
|
|
|
2783
2924
|
See the Apache Version 2.0 License for specific language governing permissions
|
|
2784
2925
|
and limitations under the License.
|
|
2785
2926
|
***************************************************************************** */
|
|
2786
|
-
function
|
|
2927
|
+
function Wr(i, e) {
|
|
2787
2928
|
var t = { label: 0, sent: function() {
|
|
2788
2929
|
if (o[0] & 1) throw o[1];
|
|
2789
2930
|
return o[1];
|
|
@@ -2843,7 +2984,7 @@ function Cr(i, e) {
|
|
|
2843
2984
|
return { value: u[0] ? u[1] : void 0, done: !0 };
|
|
2844
2985
|
}
|
|
2845
2986
|
}
|
|
2846
|
-
var
|
|
2987
|
+
var xe = (
|
|
2847
2988
|
/** @class */
|
|
2848
2989
|
/* @__PURE__ */ function() {
|
|
2849
2990
|
function i(e, t) {
|
|
@@ -2852,11 +2993,11 @@ var Le = (
|
|
|
2852
2993
|
return i;
|
|
2853
2994
|
}()
|
|
2854
2995
|
);
|
|
2855
|
-
function
|
|
2996
|
+
function Br(i, e) {
|
|
2856
2997
|
return i > e ? 1 : i < e ? -1 : 0;
|
|
2857
2998
|
}
|
|
2858
|
-
function
|
|
2859
|
-
for (var n = new
|
|
2999
|
+
function _e(i, e, t) {
|
|
3000
|
+
for (var n = new xe(null, null), r = n, o = n; ; ) {
|
|
2860
3001
|
var l = t(i, e.key);
|
|
2861
3002
|
if (l < 0) {
|
|
2862
3003
|
if (e.left === null)
|
|
@@ -2881,46 +3022,46 @@ function ve(i, e, t) {
|
|
|
2881
3022
|
}
|
|
2882
3023
|
return r.right = e.left, o.left = e.right, e.left = n.right, e.right = n.left, e;
|
|
2883
3024
|
}
|
|
2884
|
-
function
|
|
2885
|
-
var r = new
|
|
3025
|
+
function Rt(i, e, t, n) {
|
|
3026
|
+
var r = new xe(i, e);
|
|
2886
3027
|
if (t === null)
|
|
2887
3028
|
return r.left = r.right = null, r;
|
|
2888
|
-
t =
|
|
3029
|
+
t = _e(i, t, n);
|
|
2889
3030
|
var o = n(i, t.key);
|
|
2890
3031
|
return o < 0 ? (r.left = t.left, r.right = t, t.left = null) : o >= 0 && (r.right = t.right, r.left = t, t.right = null), r;
|
|
2891
3032
|
}
|
|
2892
|
-
function
|
|
3033
|
+
function vi(i, e, t) {
|
|
2893
3034
|
var n = null, r = null;
|
|
2894
3035
|
if (e) {
|
|
2895
|
-
e =
|
|
3036
|
+
e = _e(i, e, t);
|
|
2896
3037
|
var o = t(e.key, i);
|
|
2897
3038
|
o === 0 ? (n = e.left, r = e.right) : o < 0 ? (r = e.right, e.right = null, n = e) : (n = e.left, e.left = null, r = e);
|
|
2898
3039
|
}
|
|
2899
3040
|
return { left: n, right: r };
|
|
2900
3041
|
}
|
|
2901
|
-
function
|
|
2902
|
-
return e === null ? i : (i === null || (e =
|
|
3042
|
+
function Dr(i, e, t) {
|
|
3043
|
+
return e === null ? i : (i === null || (e = _e(i.key, e, t), e.left = i), e);
|
|
2903
3044
|
}
|
|
2904
|
-
function
|
|
3045
|
+
function Bt(i, e, t, n, r) {
|
|
2905
3046
|
if (i) {
|
|
2906
3047
|
n("" + e + (t ? "└── " : "├── ") + r(i) + `
|
|
2907
3048
|
`);
|
|
2908
3049
|
var o = e + (t ? " " : "│ ");
|
|
2909
|
-
i.left &&
|
|
3050
|
+
i.left && Bt(i.left, o, !1, n, r), i.right && Bt(i.right, o, !0, n, r);
|
|
2910
3051
|
}
|
|
2911
3052
|
}
|
|
2912
|
-
var
|
|
3053
|
+
var Ht = (
|
|
2913
3054
|
/** @class */
|
|
2914
3055
|
function() {
|
|
2915
3056
|
function i(e) {
|
|
2916
|
-
e === void 0 && (e =
|
|
3057
|
+
e === void 0 && (e = Br), this._root = null, this._size = 0, this._comparator = e;
|
|
2917
3058
|
}
|
|
2918
3059
|
return i.prototype.insert = function(e, t) {
|
|
2919
|
-
return this._size++, this._root =
|
|
3060
|
+
return this._size++, this._root = Rt(e, t, this._root, this._comparator);
|
|
2920
3061
|
}, i.prototype.add = function(e, t) {
|
|
2921
|
-
var n = new
|
|
3062
|
+
var n = new xe(e, t);
|
|
2922
3063
|
this._root === null && (n.left = n.right = null, this._size++, this._root = n);
|
|
2923
|
-
var r = this._comparator, o =
|
|
3064
|
+
var r = this._comparator, o = _e(e, this._root, r), l = r(e, o.key);
|
|
2924
3065
|
return l === 0 ? this._root = o : (l < 0 ? (n.left = o.left, n.right = o, o.left = null) : l > 0 && (n.right = o.right, n.left = o, o.right = null), this._size++, this._root = n), this._root;
|
|
2925
3066
|
}, i.prototype.remove = function(e) {
|
|
2926
3067
|
this._root = this._remove(e, this._root, this._comparator);
|
|
@@ -2928,15 +3069,15 @@ var Ft = (
|
|
|
2928
3069
|
var r;
|
|
2929
3070
|
if (t === null)
|
|
2930
3071
|
return null;
|
|
2931
|
-
t =
|
|
3072
|
+
t = _e(e, t, n);
|
|
2932
3073
|
var o = n(e, t.key);
|
|
2933
|
-
return o === 0 ? (t.left === null ? r = t.right : (r =
|
|
3074
|
+
return o === 0 ? (t.left === null ? r = t.right : (r = _e(e, t.left, n), r.right = t.right), this._size--, r) : t;
|
|
2934
3075
|
}, i.prototype.pop = function() {
|
|
2935
3076
|
var e = this._root;
|
|
2936
3077
|
if (e) {
|
|
2937
3078
|
for (; e.left; )
|
|
2938
3079
|
e = e.left;
|
|
2939
|
-
return this._root =
|
|
3080
|
+
return this._root = _e(e.key, this._root, this._comparator), this._root = this._remove(e.key, this._root, this._comparator), { key: e.key, data: e.data };
|
|
2940
3081
|
}
|
|
2941
3082
|
return null;
|
|
2942
3083
|
}, i.prototype.findStatic = function(e) {
|
|
@@ -2948,7 +3089,7 @@ var Ft = (
|
|
|
2948
3089
|
}
|
|
2949
3090
|
return null;
|
|
2950
3091
|
}, i.prototype.find = function(e) {
|
|
2951
|
-
return this._root && (this._root =
|
|
3092
|
+
return this._root && (this._root = _e(e, this._root, this._comparator), this._comparator(e, this._root.key) !== 0) ? null : this._root;
|
|
2952
3093
|
}, i.prototype.contains = function(e) {
|
|
2953
3094
|
for (var t = this._root, n = this._comparator; t; ) {
|
|
2954
3095
|
var r = n(e, t.key);
|
|
@@ -3041,15 +3182,15 @@ var Ft = (
|
|
|
3041
3182
|
}, i.prototype.clear = function() {
|
|
3042
3183
|
return this._root = null, this._size = 0, this;
|
|
3043
3184
|
}, i.prototype.toList = function() {
|
|
3044
|
-
return
|
|
3185
|
+
return Fr(this._root);
|
|
3045
3186
|
}, i.prototype.load = function(e, t, n) {
|
|
3046
3187
|
t === void 0 && (t = []), n === void 0 && (n = !1);
|
|
3047
3188
|
var r = e.length, o = this._comparator;
|
|
3048
|
-
if (n &&
|
|
3049
|
-
this._root =
|
|
3189
|
+
if (n && Ft(e, t, 0, r - 1, o), this._root === null)
|
|
3190
|
+
this._root = Dt(e, t, 0, r), this._size = r;
|
|
3050
3191
|
else {
|
|
3051
|
-
var l =
|
|
3052
|
-
r = this._size + r, this._root =
|
|
3192
|
+
var l = Gr(this.toList(), Ur(e, t), o);
|
|
3193
|
+
r = this._size + r, this._root = Ut({ head: l }, 0, r);
|
|
3053
3194
|
}
|
|
3054
3195
|
return this;
|
|
3055
3196
|
}, i.prototype.isEmpty = function() {
|
|
@@ -3071,17 +3212,17 @@ var Ft = (
|
|
|
3071
3212
|
return String(n.key);
|
|
3072
3213
|
});
|
|
3073
3214
|
var t = [];
|
|
3074
|
-
return
|
|
3215
|
+
return Bt(this._root, "", !0, function(n) {
|
|
3075
3216
|
return t.push(n);
|
|
3076
3217
|
}, e), t.join("");
|
|
3077
3218
|
}, i.prototype.update = function(e, t, n) {
|
|
3078
|
-
var r = this._comparator, o =
|
|
3079
|
-
r(e, t) < 0 ? s =
|
|
3219
|
+
var r = this._comparator, o = vi(e, this._root, r), l = o.left, s = o.right;
|
|
3220
|
+
r(e, t) < 0 ? s = Rt(t, n, s, r) : l = Rt(t, n, l, r), this._root = Dr(l, s, r);
|
|
3080
3221
|
}, i.prototype.split = function(e) {
|
|
3081
|
-
return
|
|
3222
|
+
return vi(e, this._root, this._comparator);
|
|
3082
3223
|
}, i.prototype[Symbol.iterator] = function() {
|
|
3083
3224
|
var e, t, n;
|
|
3084
|
-
return
|
|
3225
|
+
return Wr(this, function(r) {
|
|
3085
3226
|
switch (r.label) {
|
|
3086
3227
|
case 0:
|
|
3087
3228
|
e = this._root, t = [], n = !1, r.label = 1;
|
|
@@ -3105,38 +3246,38 @@ var Ft = (
|
|
|
3105
3246
|
}, i;
|
|
3106
3247
|
}()
|
|
3107
3248
|
);
|
|
3108
|
-
function
|
|
3249
|
+
function Dt(i, e, t, n) {
|
|
3109
3250
|
var r = n - t;
|
|
3110
3251
|
if (r > 0) {
|
|
3111
|
-
var o = t + Math.floor(r / 2), l = i[o], s = e[o], c = new
|
|
3112
|
-
return c.left =
|
|
3252
|
+
var o = t + Math.floor(r / 2), l = i[o], s = e[o], c = new xe(l, s);
|
|
3253
|
+
return c.left = Dt(i, e, t, o), c.right = Dt(i, e, o + 1, n), c;
|
|
3113
3254
|
}
|
|
3114
3255
|
return null;
|
|
3115
3256
|
}
|
|
3116
|
-
function
|
|
3117
|
-
for (var t = new
|
|
3118
|
-
n = n.next = new
|
|
3257
|
+
function Ur(i, e) {
|
|
3258
|
+
for (var t = new xe(null, null), n = t, r = 0; r < i.length; r++)
|
|
3259
|
+
n = n.next = new xe(i[r], e[r]);
|
|
3119
3260
|
return n.next = null, t.next;
|
|
3120
3261
|
}
|
|
3121
|
-
function
|
|
3122
|
-
for (var e = i, t = [], n = !1, r = new
|
|
3262
|
+
function Fr(i) {
|
|
3263
|
+
for (var e = i, t = [], n = !1, r = new xe(null, null), o = r; !n; )
|
|
3123
3264
|
e ? (t.push(e), e = e.left) : t.length > 0 ? (e = o = o.next = t.pop(), e = e.right) : n = !0;
|
|
3124
3265
|
return o.next = null, r.next;
|
|
3125
3266
|
}
|
|
3126
|
-
function
|
|
3267
|
+
function Ut(i, e, t) {
|
|
3127
3268
|
var n = t - e;
|
|
3128
3269
|
if (n > 0) {
|
|
3129
|
-
var r = e + Math.floor(n / 2), o =
|
|
3130
|
-
return l.left = o, i.head = i.head.next, l.right =
|
|
3270
|
+
var r = e + Math.floor(n / 2), o = Ut(i, e, r), l = i.head;
|
|
3271
|
+
return l.left = o, i.head = i.head.next, l.right = Ut(i, r + 1, t), l;
|
|
3131
3272
|
}
|
|
3132
3273
|
return null;
|
|
3133
3274
|
}
|
|
3134
|
-
function
|
|
3135
|
-
for (var n = new
|
|
3275
|
+
function Gr(i, e, t) {
|
|
3276
|
+
for (var n = new xe(null, null), r = n, o = i, l = e; o !== null && l !== null; )
|
|
3136
3277
|
t(o.key, l.key) < 0 ? (r.next = o, o = o.next) : (r.next = l, l = l.next), r = r.next;
|
|
3137
3278
|
return o !== null ? r.next = o : l !== null && (r.next = l), n.next;
|
|
3138
3279
|
}
|
|
3139
|
-
function
|
|
3280
|
+
function Ft(i, e, t, n, r) {
|
|
3140
3281
|
if (!(t >= n)) {
|
|
3141
3282
|
for (var o = i[t + n >> 1], l = t - 1, s = n + 1; ; ) {
|
|
3142
3283
|
do
|
|
@@ -3150,11 +3291,11 @@ function Ot(i, e, t, n, r) {
|
|
|
3150
3291
|
var c = i[l];
|
|
3151
3292
|
i[l] = i[s], i[s] = c, c = e[l], e[l] = e[s], e[s] = c;
|
|
3152
3293
|
}
|
|
3153
|
-
|
|
3294
|
+
Ft(i, e, t, s, r), Ft(i, e, s + 1, n, r);
|
|
3154
3295
|
}
|
|
3155
3296
|
}
|
|
3156
|
-
const
|
|
3157
|
-
function
|
|
3297
|
+
const me = 11102230246251565e-32, Y = 134217729, jr = (3 + 8 * me) * me;
|
|
3298
|
+
function Ot(i, e, t, n, r) {
|
|
3158
3299
|
let o, l, s, c, u = e[0], h = n[0], a = 0, f = 0;
|
|
3159
3300
|
h > u == h > -u ? (o = u, u = e[++a]) : (o = h, h = n[++f]);
|
|
3160
3301
|
let d = 0;
|
|
@@ -3167,34 +3308,34 @@ function Mt(i, e, t, n, r) {
|
|
|
3167
3308
|
l = o + h, c = l - o, s = o - (l - c) + (h - c), h = n[++f], o = l, s !== 0 && (r[d++] = s);
|
|
3168
3309
|
return (o !== 0 || d === 0) && (r[d++] = o), d;
|
|
3169
3310
|
}
|
|
3170
|
-
function
|
|
3311
|
+
function qr(i, e) {
|
|
3171
3312
|
let t = e[0];
|
|
3172
3313
|
for (let n = 1; n < i; n++) t += e[n];
|
|
3173
3314
|
return t;
|
|
3174
3315
|
}
|
|
3175
|
-
function
|
|
3316
|
+
function Ke(i) {
|
|
3176
3317
|
return new Float64Array(i);
|
|
3177
3318
|
}
|
|
3178
|
-
const
|
|
3179
|
-
function
|
|
3180
|
-
let s, c, u, h, a, f, d, m, v,
|
|
3181
|
-
const
|
|
3182
|
-
|
|
3183
|
-
let
|
|
3184
|
-
if (
|
|
3185
|
-
|
|
3186
|
-
const
|
|
3187
|
-
|
|
3188
|
-
const
|
|
3189
|
-
|
|
3190
|
-
const
|
|
3191
|
-
return
|
|
3192
|
-
}
|
|
3193
|
-
function
|
|
3319
|
+
const Zr = (3 + 16 * me) * me, Qr = (2 + 12 * me) * me, Hr = (9 + 64 * me) * me * me, We = Ke(4), _i = Ke(8), wi = Ke(12), Ei = Ke(16), J = Ke(4);
|
|
3320
|
+
function Vr(i, e, t, n, r, o, l) {
|
|
3321
|
+
let s, c, u, h, a, f, d, m, b, v, y, E, _, L, P, N, x, S;
|
|
3322
|
+
const T = i - r, w = t - r, M = e - o, R = n - o;
|
|
3323
|
+
L = T * R, f = Y * T, d = f - (f - T), m = T - d, f = Y * R, b = f - (f - R), v = R - b, P = m * v - (L - d * b - m * b - d * v), N = M * w, f = Y * M, d = f - (f - M), m = M - d, f = Y * w, b = f - (f - w), v = w - b, x = m * v - (N - d * b - m * b - d * v), y = P - x, a = P - y, We[0] = P - (y + a) + (a - x), E = L + y, a = E - L, _ = L - (E - a) + (y - a), y = _ - N, a = _ - y, We[1] = _ - (y + a) + (a - N), S = E + y, a = S - E, We[2] = E - (S - a) + (y - a), We[3] = S;
|
|
3324
|
+
let K = qr(4, We), C = Qr * l;
|
|
3325
|
+
if (K >= C || -K >= C || (a = i - T, s = i - (T + a) + (a - r), a = t - w, u = t - (w + a) + (a - r), a = e - M, c = e - (M + a) + (a - o), a = n - R, h = n - (R + a) + (a - o), s === 0 && c === 0 && u === 0 && h === 0) || (C = Hr * l + jr * Math.abs(K), K += T * h + R * s - (M * u + w * c), K >= C || -K >= C)) return K;
|
|
3326
|
+
L = s * R, f = Y * s, d = f - (f - s), m = s - d, f = Y * R, b = f - (f - R), v = R - b, P = m * v - (L - d * b - m * b - d * v), N = c * w, f = Y * c, d = f - (f - c), m = c - d, f = Y * w, b = f - (f - w), v = w - b, x = m * v - (N - d * b - m * b - d * v), y = P - x, a = P - y, J[0] = P - (y + a) + (a - x), E = L + y, a = E - L, _ = L - (E - a) + (y - a), y = _ - N, a = _ - y, J[1] = _ - (y + a) + (a - N), S = E + y, a = S - E, J[2] = E - (S - a) + (y - a), J[3] = S;
|
|
3327
|
+
const A = Ot(4, We, 4, J, _i);
|
|
3328
|
+
L = T * h, f = Y * T, d = f - (f - T), m = T - d, f = Y * h, b = f - (f - h), v = h - b, P = m * v - (L - d * b - m * b - d * v), N = M * u, f = Y * M, d = f - (f - M), m = M - d, f = Y * u, b = f - (f - u), v = u - b, x = m * v - (N - d * b - m * b - d * v), y = P - x, a = P - y, J[0] = P - (y + a) + (a - x), E = L + y, a = E - L, _ = L - (E - a) + (y - a), y = _ - N, a = _ - y, J[1] = _ - (y + a) + (a - N), S = E + y, a = S - E, J[2] = E - (S - a) + (y - a), J[3] = S;
|
|
3329
|
+
const oe = Ot(A, _i, 4, J, wi);
|
|
3330
|
+
L = s * h, f = Y * s, d = f - (f - s), m = s - d, f = Y * h, b = f - (f - h), v = h - b, P = m * v - (L - d * b - m * b - d * v), N = c * u, f = Y * c, d = f - (f - c), m = c - d, f = Y * u, b = f - (f - u), v = u - b, x = m * v - (N - d * b - m * b - d * v), y = P - x, a = P - y, J[0] = P - (y + a) + (a - x), E = L + y, a = E - L, _ = L - (E - a) + (y - a), y = _ - N, a = _ - y, J[1] = _ - (y + a) + (a - N), S = E + y, a = S - E, J[2] = E - (S - a) + (y - a), J[3] = S;
|
|
3331
|
+
const j = Ot(oe, wi, 4, J, Ei);
|
|
3332
|
+
return Ei[j - 1];
|
|
3333
|
+
}
|
|
3334
|
+
function Yr(i, e, t, n, r, o) {
|
|
3194
3335
|
const l = (e - o) * (t - r), s = (i - r) * (n - o), c = l - s, u = Math.abs(l + s);
|
|
3195
|
-
return Math.abs(c) >=
|
|
3336
|
+
return Math.abs(c) >= Zr * u ? c : -Vr(i, e, t, n, r, o, u);
|
|
3196
3337
|
}
|
|
3197
|
-
const
|
|
3338
|
+
const je = (i, e) => i.ll.x <= e.x && e.x <= i.ur.x && i.ll.y <= e.y && e.y <= i.ur.y, Gt = (i, e) => {
|
|
3198
3339
|
if (e.ur.x < i.ll.x || i.ur.x < e.ll.x || e.ur.y < i.ll.y || i.ur.y < e.ll.y) return null;
|
|
3199
3340
|
const t = i.ll.x < e.ll.x ? e.ll.x : i.ll.x, n = i.ur.x < e.ur.x ? i.ur.x : e.ur.x, r = i.ll.y < e.ll.y ? e.ll.y : i.ll.y, o = i.ur.y < e.ur.y ? i.ur.y : e.ur.y;
|
|
3200
3341
|
return {
|
|
@@ -3208,20 +3349,20 @@ const Ge = (i, e) => i.ll.x <= e.x && e.x <= i.ur.x && i.ll.y <= e.y && e.y <= i
|
|
|
3208
3349
|
}
|
|
3209
3350
|
};
|
|
3210
3351
|
};
|
|
3211
|
-
let
|
|
3212
|
-
|
|
3213
|
-
const
|
|
3214
|
-
if (-
|
|
3352
|
+
let we = Number.EPSILON;
|
|
3353
|
+
we === void 0 && (we = Math.pow(2, -52));
|
|
3354
|
+
const Xr = we * we, Li = (i, e) => {
|
|
3355
|
+
if (-we < i && i < we && -we < e && e < we)
|
|
3215
3356
|
return 0;
|
|
3216
3357
|
const t = i - e;
|
|
3217
|
-
return t * t <
|
|
3358
|
+
return t * t < Xr * i * e ? 0 : i < e ? -1 : 1;
|
|
3218
3359
|
};
|
|
3219
|
-
class
|
|
3360
|
+
class Kr {
|
|
3220
3361
|
constructor() {
|
|
3221
3362
|
this.reset();
|
|
3222
3363
|
}
|
|
3223
3364
|
reset() {
|
|
3224
|
-
this.xRounder = new
|
|
3365
|
+
this.xRounder = new Si(), this.yRounder = new Si();
|
|
3225
3366
|
}
|
|
3226
3367
|
round(e, t) {
|
|
3227
3368
|
return {
|
|
@@ -3230,9 +3371,9 @@ class Gr {
|
|
|
3230
3371
|
};
|
|
3231
3372
|
}
|
|
3232
3373
|
}
|
|
3233
|
-
class
|
|
3374
|
+
class Si {
|
|
3234
3375
|
constructor() {
|
|
3235
|
-
this.tree = new
|
|
3376
|
+
this.tree = new Ht(), this.round(0);
|
|
3236
3377
|
}
|
|
3237
3378
|
// Note: this can rounds input values backwards or forwards.
|
|
3238
3379
|
// You might ask, why not restrict this to just rounding
|
|
@@ -3243,16 +3384,16 @@ class pi {
|
|
|
3243
3384
|
// angle for t-intersections).
|
|
3244
3385
|
round(e) {
|
|
3245
3386
|
const t = this.tree.add(e), n = this.tree.prev(t);
|
|
3246
|
-
if (n !== null &&
|
|
3387
|
+
if (n !== null && Li(t.key, n.key) === 0)
|
|
3247
3388
|
return this.tree.remove(e), n.key;
|
|
3248
3389
|
const r = this.tree.next(t);
|
|
3249
|
-
return r !== null &&
|
|
3390
|
+
return r !== null && Li(t.key, r.key) === 0 ? (this.tree.remove(e), r.key) : e;
|
|
3250
3391
|
}
|
|
3251
3392
|
}
|
|
3252
|
-
const
|
|
3253
|
-
const n =
|
|
3393
|
+
const Xe = new Kr(), ft = (i, e) => i.x * e.y - i.y * e.x, Yi = (i, e) => i.x * e.x + i.y * e.y, xi = (i, e, t) => {
|
|
3394
|
+
const n = Yr(i.x, i.y, e.x, e.y, t.x, t.y);
|
|
3254
3395
|
return n > 0 ? -1 : n < 0 ? 1 : 0;
|
|
3255
|
-
},
|
|
3396
|
+
}, ht = (i) => Math.sqrt(Yi(i, i)), Jr = (i, e, t) => {
|
|
3256
3397
|
const n = {
|
|
3257
3398
|
x: e.x - i.x,
|
|
3258
3399
|
y: e.y - i.y
|
|
@@ -3260,8 +3401,8 @@ const Ve = new Gr(), lt = (i, e) => i.x * e.y - i.y * e.x, Gi = (i, e) => i.x *
|
|
|
3260
3401
|
x: t.x - i.x,
|
|
3261
3402
|
y: t.y - i.y
|
|
3262
3403
|
};
|
|
3263
|
-
return
|
|
3264
|
-
},
|
|
3404
|
+
return ft(r, n) / ht(r) / ht(n);
|
|
3405
|
+
}, $r = (i, e, t) => {
|
|
3265
3406
|
const n = {
|
|
3266
3407
|
x: e.x - i.x,
|
|
3267
3408
|
y: e.y - i.y
|
|
@@ -3269,34 +3410,34 @@ const Ve = new Gr(), lt = (i, e) => i.x * e.y - i.y * e.x, Gi = (i, e) => i.x *
|
|
|
3269
3410
|
x: t.x - i.x,
|
|
3270
3411
|
y: t.y - i.y
|
|
3271
3412
|
};
|
|
3272
|
-
return
|
|
3273
|
-
},
|
|
3413
|
+
return Yi(r, n) / ht(r) / ht(n);
|
|
3414
|
+
}, Mi = (i, e, t) => e.y === 0 ? null : {
|
|
3274
3415
|
x: i.x + e.x / e.y * (t - i.y),
|
|
3275
3416
|
y: t
|
|
3276
|
-
},
|
|
3417
|
+
}, Ci = (i, e, t) => e.x === 0 ? null : {
|
|
3277
3418
|
x: t,
|
|
3278
3419
|
y: i.y + e.y / e.x * (t - i.x)
|
|
3279
|
-
},
|
|
3280
|
-
if (e.x === 0) return
|
|
3281
|
-
if (n.x === 0) return
|
|
3282
|
-
if (e.y === 0) return
|
|
3283
|
-
if (n.y === 0) return
|
|
3284
|
-
const r =
|
|
3420
|
+
}, eo = (i, e, t, n) => {
|
|
3421
|
+
if (e.x === 0) return Ci(t, n, i.x);
|
|
3422
|
+
if (n.x === 0) return Ci(i, e, t.x);
|
|
3423
|
+
if (e.y === 0) return Mi(t, n, i.y);
|
|
3424
|
+
if (n.y === 0) return Mi(i, e, t.y);
|
|
3425
|
+
const r = ft(e, n);
|
|
3285
3426
|
if (r == 0) return null;
|
|
3286
3427
|
const o = {
|
|
3287
3428
|
x: t.x - i.x,
|
|
3288
3429
|
y: t.y - i.y
|
|
3289
|
-
}, l =
|
|
3430
|
+
}, l = ft(o, e) / r, s = ft(o, n) / r, c = i.x + s * e.x, u = t.x + l * n.x, h = i.y + s * e.y, a = t.y + l * n.y, f = (c + u) / 2, d = (h + a) / 2;
|
|
3290
3431
|
return {
|
|
3291
3432
|
x: f,
|
|
3292
3433
|
y: d
|
|
3293
3434
|
};
|
|
3294
3435
|
};
|
|
3295
|
-
class
|
|
3436
|
+
class re {
|
|
3296
3437
|
// for ordering sweep events in the sweep event queue
|
|
3297
3438
|
static compare(e, t) {
|
|
3298
|
-
const n =
|
|
3299
|
-
return n !== 0 ? n : (e.point !== t.point && e.link(t), e.isLeft !== t.isLeft ? e.isLeft ? 1 : -1 :
|
|
3439
|
+
const n = re.comparePoints(e.point, t.point);
|
|
3440
|
+
return n !== 0 ? n : (e.point !== t.point && e.link(t), e.isLeft !== t.isLeft ? e.isLeft ? 1 : -1 : Ee.compare(e.segment, t.segment));
|
|
3300
3441
|
}
|
|
3301
3442
|
// for ordering points in sweep line order
|
|
3302
3443
|
static comparePoints(e, t) {
|
|
@@ -3351,8 +3492,8 @@ class ne {
|
|
|
3351
3492
|
const t = /* @__PURE__ */ new Map(), n = (r) => {
|
|
3352
3493
|
const o = r.otherSE;
|
|
3353
3494
|
t.set(r, {
|
|
3354
|
-
sine:
|
|
3355
|
-
cosine:
|
|
3495
|
+
sine: Jr(this.point, e.point, o.point),
|
|
3496
|
+
cosine: $r(this.point, e.point, o.point)
|
|
3356
3497
|
});
|
|
3357
3498
|
};
|
|
3358
3499
|
return (r, o) => {
|
|
@@ -3368,8 +3509,8 @@ class ne {
|
|
|
3368
3509
|
};
|
|
3369
3510
|
}
|
|
3370
3511
|
}
|
|
3371
|
-
let
|
|
3372
|
-
class
|
|
3512
|
+
let to = 0;
|
|
3513
|
+
class Ee {
|
|
3373
3514
|
/* This compare() function is for ordering segments in the sweep
|
|
3374
3515
|
* line tree, and does so according to the following criteria:
|
|
3375
3516
|
*
|
|
@@ -3426,18 +3567,18 @@ class we {
|
|
|
3426
3567
|
/* Warning: a reference to ringWindings input will be stored,
|
|
3427
3568
|
* and possibly will be later modified */
|
|
3428
3569
|
constructor(e, t, n, r) {
|
|
3429
|
-
this.id = ++
|
|
3570
|
+
this.id = ++to, this.leftSE = e, e.segment = this, e.otherSE = t, this.rightSE = t, t.segment = this, t.otherSE = e, this.rings = n, this.windings = r;
|
|
3430
3571
|
}
|
|
3431
3572
|
static fromRing(e, t, n) {
|
|
3432
3573
|
let r, o, l;
|
|
3433
|
-
const s =
|
|
3574
|
+
const s = re.comparePoints(e, t);
|
|
3434
3575
|
if (s < 0)
|
|
3435
3576
|
r = e, o = t, l = 1;
|
|
3436
3577
|
else if (s > 0)
|
|
3437
3578
|
r = t, o = e, l = -1;
|
|
3438
3579
|
else throw new Error(`Tried to create degenerate segment at [${e.x}, ${e.y}]`);
|
|
3439
|
-
const c = new
|
|
3440
|
-
return new
|
|
3580
|
+
const c = new re(r, !0), u = new re(o, !1);
|
|
3581
|
+
return new Ee(c, u, [n], [l]);
|
|
3441
3582
|
}
|
|
3442
3583
|
/* When a segment is split, the rightSE is replaced with a new sweep event */
|
|
3443
3584
|
replaceRightSE(e) {
|
|
@@ -3505,9 +3646,9 @@ class we {
|
|
|
3505
3646
|
* Else, return null.
|
|
3506
3647
|
*/
|
|
3507
3648
|
getIntersection(e) {
|
|
3508
|
-
const t = this.bbox(), n = e.bbox(), r =
|
|
3649
|
+
const t = this.bbox(), n = e.bbox(), r = Gt(t, n);
|
|
3509
3650
|
if (r === null) return null;
|
|
3510
|
-
const o = this.leftSE.point, l = this.rightSE.point, s = e.leftSE.point, c = e.rightSE.point, u =
|
|
3651
|
+
const o = this.leftSE.point, l = this.rightSE.point, s = e.leftSE.point, c = e.rightSE.point, u = je(t, s) && this.comparePoint(s) === 0, h = je(n, o) && e.comparePoint(o) === 0, a = je(t, c) && this.comparePoint(c) === 0, f = je(n, l) && e.comparePoint(l) === 0;
|
|
3511
3652
|
if (h && u)
|
|
3512
3653
|
return f && !a ? l : !f && a ? c : null;
|
|
3513
3654
|
if (h)
|
|
@@ -3517,8 +3658,8 @@ class we {
|
|
|
3517
3658
|
if (f && a) return null;
|
|
3518
3659
|
if (f) return l;
|
|
3519
3660
|
if (a) return c;
|
|
3520
|
-
const d =
|
|
3521
|
-
return d === null || !
|
|
3661
|
+
const d = eo(o, this.vector(), s, e.vector());
|
|
3662
|
+
return d === null || !je(r, d) ? null : Xe.round(d.x, d.y);
|
|
3522
3663
|
}
|
|
3523
3664
|
/**
|
|
3524
3665
|
* Split the given segment into multiple segments on the given points.
|
|
@@ -3533,10 +3674,10 @@ class we {
|
|
|
3533
3674
|
* Warning: input array of points is modified
|
|
3534
3675
|
*/
|
|
3535
3676
|
split(e) {
|
|
3536
|
-
const t = [], n = e.events !== void 0, r = new
|
|
3677
|
+
const t = [], n = e.events !== void 0, r = new re(e, !0), o = new re(e, !1), l = this.rightSE;
|
|
3537
3678
|
this.replaceRightSE(o), t.push(o), t.push(r);
|
|
3538
|
-
const s = new
|
|
3539
|
-
return
|
|
3679
|
+
const s = new Ee(r, l, this.rings.slice(), this.windings.slice());
|
|
3680
|
+
return re.comparePoints(s.leftSE.point, s.rightSE.point) > 0 && s.swapEvents(), re.comparePoints(this.leftSE.point, this.rightSE.point) > 0 && this.swapEvents(), n && (r.checkForConsuming(), o.checkForConsuming()), t;
|
|
3540
3681
|
}
|
|
3541
3682
|
/* Swap which event is left and right */
|
|
3542
3683
|
swapEvents() {
|
|
@@ -3551,7 +3692,7 @@ class we {
|
|
|
3551
3692
|
let t = this, n = e;
|
|
3552
3693
|
for (; t.consumedBy; ) t = t.consumedBy;
|
|
3553
3694
|
for (; n.consumedBy; ) n = n.consumedBy;
|
|
3554
|
-
const r =
|
|
3695
|
+
const r = Ee.compare(t, n);
|
|
3555
3696
|
if (r !== 0) {
|
|
3556
3697
|
if (r > 0) {
|
|
3557
3698
|
const o = t;
|
|
@@ -3621,7 +3762,7 @@ class we {
|
|
|
3621
3762
|
if (this.consumedBy) return !1;
|
|
3622
3763
|
if (this._isInResult !== void 0) return this._isInResult;
|
|
3623
3764
|
const e = this.beforeState().multiPolys, t = this.afterState().multiPolys;
|
|
3624
|
-
switch (
|
|
3765
|
+
switch (ae.type) {
|
|
3625
3766
|
case "union": {
|
|
3626
3767
|
const n = e.length === 0, r = t.length === 0;
|
|
3627
3768
|
this._isInResult = n !== r;
|
|
@@ -3629,7 +3770,7 @@ class we {
|
|
|
3629
3770
|
}
|
|
3630
3771
|
case "intersection": {
|
|
3631
3772
|
let n, r;
|
|
3632
|
-
e.length < t.length ? (n = e.length, r = t.length) : (n = t.length, r = e.length), this._isInResult = r ===
|
|
3773
|
+
e.length < t.length ? (n = e.length, r = t.length) : (n = t.length, r = e.length), this._isInResult = r === ae.numMultiPolys && n < r;
|
|
3633
3774
|
break;
|
|
3634
3775
|
}
|
|
3635
3776
|
case "xor": {
|
|
@@ -3643,18 +3784,18 @@ class we {
|
|
|
3643
3784
|
break;
|
|
3644
3785
|
}
|
|
3645
3786
|
default:
|
|
3646
|
-
throw new Error(`Unrecognized operation type found ${
|
|
3787
|
+
throw new Error(`Unrecognized operation type found ${ae.type}`);
|
|
3647
3788
|
}
|
|
3648
3789
|
return this._isInResult;
|
|
3649
3790
|
}
|
|
3650
3791
|
}
|
|
3651
|
-
class
|
|
3792
|
+
class ki {
|
|
3652
3793
|
constructor(e, t, n) {
|
|
3653
3794
|
if (!Array.isArray(e) || e.length === 0)
|
|
3654
3795
|
throw new Error("Input geometry is not a valid Polygon or MultiPolygon");
|
|
3655
3796
|
if (this.poly = t, this.isExterior = n, this.segments = [], typeof e[0][0] != "number" || typeof e[0][1] != "number")
|
|
3656
3797
|
throw new Error("Input geometry is not a valid Polygon or MultiPolygon");
|
|
3657
|
-
const r =
|
|
3798
|
+
const r = Xe.round(e[0][0], e[0][1]);
|
|
3658
3799
|
this.bbox = {
|
|
3659
3800
|
ll: {
|
|
3660
3801
|
x: r.x,
|
|
@@ -3669,10 +3810,10 @@ class _i {
|
|
|
3669
3810
|
for (let l = 1, s = e.length; l < s; l++) {
|
|
3670
3811
|
if (typeof e[l][0] != "number" || typeof e[l][1] != "number")
|
|
3671
3812
|
throw new Error("Input geometry is not a valid Polygon or MultiPolygon");
|
|
3672
|
-
let c =
|
|
3673
|
-
c.x === o.x && c.y === o.y || (this.segments.push(
|
|
3813
|
+
let c = Xe.round(e[l][0], e[l][1]);
|
|
3814
|
+
c.x === o.x && c.y === o.y || (this.segments.push(Ee.fromRing(o, c, this)), c.x < this.bbox.ll.x && (this.bbox.ll.x = c.x), c.y < this.bbox.ll.y && (this.bbox.ll.y = c.y), c.x > this.bbox.ur.x && (this.bbox.ur.x = c.x), c.y > this.bbox.ur.y && (this.bbox.ur.y = c.y), o = c);
|
|
3674
3815
|
}
|
|
3675
|
-
(r.x !== o.x || r.y !== o.y) && this.segments.push(
|
|
3816
|
+
(r.x !== o.x || r.y !== o.y) && this.segments.push(Ee.fromRing(o, r, this));
|
|
3676
3817
|
}
|
|
3677
3818
|
getSweepEvents() {
|
|
3678
3819
|
const e = [];
|
|
@@ -3683,11 +3824,11 @@ class _i {
|
|
|
3683
3824
|
return e;
|
|
3684
3825
|
}
|
|
3685
3826
|
}
|
|
3686
|
-
class
|
|
3827
|
+
class io {
|
|
3687
3828
|
constructor(e, t) {
|
|
3688
3829
|
if (!Array.isArray(e))
|
|
3689
3830
|
throw new Error("Input geometry is not a valid Polygon or MultiPolygon");
|
|
3690
|
-
this.exteriorRing = new
|
|
3831
|
+
this.exteriorRing = new ki(e[0], this, !0), this.bbox = {
|
|
3691
3832
|
ll: {
|
|
3692
3833
|
x: this.exteriorRing.bbox.ll.x,
|
|
3693
3834
|
y: this.exteriorRing.bbox.ll.y
|
|
@@ -3698,7 +3839,7 @@ class Qr {
|
|
|
3698
3839
|
}
|
|
3699
3840
|
}, this.interiorRings = [];
|
|
3700
3841
|
for (let n = 1, r = e.length; n < r; n++) {
|
|
3701
|
-
const o = new
|
|
3842
|
+
const o = new ki(e[n], this, !1);
|
|
3702
3843
|
o.bbox.ll.x < this.bbox.ll.x && (this.bbox.ll.x = o.bbox.ll.x), o.bbox.ll.y < this.bbox.ll.y && (this.bbox.ll.y = o.bbox.ll.y), o.bbox.ur.x > this.bbox.ur.x && (this.bbox.ur.x = o.bbox.ur.x), o.bbox.ur.y > this.bbox.ur.y && (this.bbox.ur.y = o.bbox.ur.y), this.interiorRings.push(o);
|
|
3703
3844
|
}
|
|
3704
3845
|
this.multiPoly = t;
|
|
@@ -3713,7 +3854,7 @@ class Qr {
|
|
|
3713
3854
|
return e;
|
|
3714
3855
|
}
|
|
3715
3856
|
}
|
|
3716
|
-
class
|
|
3857
|
+
class Ni {
|
|
3717
3858
|
constructor(e, t) {
|
|
3718
3859
|
if (!Array.isArray(e))
|
|
3719
3860
|
throw new Error("Input geometry is not a valid Polygon or MultiPolygon");
|
|
@@ -3732,7 +3873,7 @@ class Ei {
|
|
|
3732
3873
|
}
|
|
3733
3874
|
};
|
|
3734
3875
|
for (let n = 0, r = e.length; n < r; n++) {
|
|
3735
|
-
const o = new
|
|
3876
|
+
const o = new io(e[n], this);
|
|
3736
3877
|
o.bbox.ll.x < this.bbox.ll.x && (this.bbox.ll.x = o.bbox.ll.x), o.bbox.ll.y < this.bbox.ll.y && (this.bbox.ll.y = o.bbox.ll.y), o.bbox.ur.x > this.bbox.ur.x && (this.bbox.ur.x = o.bbox.ur.x), o.bbox.ur.y > this.bbox.ur.y && (this.bbox.ur.y = o.bbox.ur.y), this.polys.push(o);
|
|
3737
3878
|
}
|
|
3738
3879
|
this.isSubject = t;
|
|
@@ -3747,7 +3888,7 @@ class Ei {
|
|
|
3747
3888
|
return e;
|
|
3748
3889
|
}
|
|
3749
3890
|
}
|
|
3750
|
-
class
|
|
3891
|
+
class gt {
|
|
3751
3892
|
/* Given the segments from the sweep line pass, compute & return a series
|
|
3752
3893
|
* of closed rings from all the segments marked to be part of the result */
|
|
3753
3894
|
static factory(e) {
|
|
@@ -3761,22 +3902,22 @@ class at {
|
|
|
3761
3902
|
for (; ; ) {
|
|
3762
3903
|
const f = s.getAvailableLinkedEvents();
|
|
3763
3904
|
if (f.length === 0) {
|
|
3764
|
-
const
|
|
3765
|
-
throw new Error(`Unable to complete output ring starting at [${
|
|
3905
|
+
const b = u[0].point, v = u[u.length - 1].point;
|
|
3906
|
+
throw new Error(`Unable to complete output ring starting at [${b.x}, ${b.y}]. Last matching segment found ends at [${v.x}, ${v.y}].`);
|
|
3766
3907
|
}
|
|
3767
3908
|
if (f.length === 1) {
|
|
3768
3909
|
c = f[0].otherSE;
|
|
3769
3910
|
break;
|
|
3770
3911
|
}
|
|
3771
3912
|
let d = null;
|
|
3772
|
-
for (let
|
|
3773
|
-
if (a[
|
|
3774
|
-
d =
|
|
3913
|
+
for (let b = 0, v = a.length; b < v; b++)
|
|
3914
|
+
if (a[b].point === s.point) {
|
|
3915
|
+
d = b;
|
|
3775
3916
|
break;
|
|
3776
3917
|
}
|
|
3777
3918
|
if (d !== null) {
|
|
3778
|
-
const
|
|
3779
|
-
|
|
3919
|
+
const b = a.splice(d)[0], v = u.splice(b.index);
|
|
3920
|
+
v.unshift(v[0].otherSE), t.push(new gt(v.reverse()));
|
|
3780
3921
|
continue;
|
|
3781
3922
|
}
|
|
3782
3923
|
a.push({
|
|
@@ -3787,7 +3928,7 @@ class at {
|
|
|
3787
3928
|
c = f.sort(m)[0].otherSE;
|
|
3788
3929
|
break;
|
|
3789
3930
|
}
|
|
3790
|
-
t.push(new
|
|
3931
|
+
t.push(new gt(u));
|
|
3791
3932
|
}
|
|
3792
3933
|
return t;
|
|
3793
3934
|
}
|
|
@@ -3802,11 +3943,11 @@ class at {
|
|
|
3802
3943
|
const t = [e];
|
|
3803
3944
|
for (let u = 1, h = this.events.length - 1; u < h; u++) {
|
|
3804
3945
|
const a = this.events[u].point, f = this.events[u + 1].point;
|
|
3805
|
-
|
|
3946
|
+
xi(a, e, f) !== 0 && (t.push(a), e = a);
|
|
3806
3947
|
}
|
|
3807
3948
|
if (t.length === 1) return null;
|
|
3808
3949
|
const n = t[0], r = t[1];
|
|
3809
|
-
|
|
3950
|
+
xi(n, e, r) === 0 && t.shift(), t.push(t[0]);
|
|
3810
3951
|
const o = this.isExteriorRing() ? 1 : -1, l = this.isExteriorRing() ? 0 : t.length - 1, s = this.isExteriorRing() ? t.length : -1, c = [];
|
|
3811
3952
|
for (let u = l; u != s; u += o) c.push([t[u].x, t[u].y]);
|
|
3812
3953
|
return c;
|
|
@@ -3826,7 +3967,7 @@ class at {
|
|
|
3826
3967
|
let e = this.events[0];
|
|
3827
3968
|
for (let r = 1, o = this.events.length; r < o; r++) {
|
|
3828
3969
|
const l = this.events[r];
|
|
3829
|
-
|
|
3970
|
+
re.compare(e, l) > 0 && (e = l);
|
|
3830
3971
|
}
|
|
3831
3972
|
let t = e.segment.prevInResult(), n = t ? t.prevInResult() : null;
|
|
3832
3973
|
for (; ; ) {
|
|
@@ -3838,7 +3979,7 @@ class at {
|
|
|
3838
3979
|
}
|
|
3839
3980
|
}
|
|
3840
3981
|
}
|
|
3841
|
-
class
|
|
3982
|
+
class Pi {
|
|
3842
3983
|
constructor(e) {
|
|
3843
3984
|
this.exteriorRing = e, e.poly = this, this.interiorRings = [];
|
|
3844
3985
|
}
|
|
@@ -3855,7 +3996,7 @@ class Li {
|
|
|
3855
3996
|
return e;
|
|
3856
3997
|
}
|
|
3857
3998
|
}
|
|
3858
|
-
class
|
|
3999
|
+
class no {
|
|
3859
4000
|
constructor(e) {
|
|
3860
4001
|
this.rings = e, this.polys = this._composePolys(e);
|
|
3861
4002
|
}
|
|
@@ -3872,19 +4013,19 @@ class Hr {
|
|
|
3872
4013
|
for (let n = 0, r = e.length; n < r; n++) {
|
|
3873
4014
|
const o = e[n];
|
|
3874
4015
|
if (!o.poly)
|
|
3875
|
-
if (o.isExteriorRing()) t.push(new
|
|
4016
|
+
if (o.isExteriorRing()) t.push(new Pi(o));
|
|
3876
4017
|
else {
|
|
3877
4018
|
const l = o.enclosingRing();
|
|
3878
|
-
l.poly || t.push(new
|
|
4019
|
+
l.poly || t.push(new Pi(l)), l.poly.addInterior(o);
|
|
3879
4020
|
}
|
|
3880
4021
|
}
|
|
3881
4022
|
return t;
|
|
3882
4023
|
}
|
|
3883
4024
|
}
|
|
3884
|
-
class
|
|
4025
|
+
class ro {
|
|
3885
4026
|
constructor(e) {
|
|
3886
|
-
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] :
|
|
3887
|
-
this.queue = e, this.tree = new
|
|
4027
|
+
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : Ee.compare;
|
|
4028
|
+
this.queue = e, this.tree = new Ht(t), this.segments = [];
|
|
3888
4029
|
}
|
|
3889
4030
|
process(e) {
|
|
3890
4031
|
const t = e.segment, n = [];
|
|
@@ -3918,7 +4059,7 @@ class Vr {
|
|
|
3918
4059
|
}
|
|
3919
4060
|
if (u !== null || h !== null) {
|
|
3920
4061
|
let a = null;
|
|
3921
|
-
u === null ? a = h : h === null ? a = u : a =
|
|
4062
|
+
u === null ? a = h : h === null ? a = u : a = re.comparePoints(u, h) <= 0 ? u : h, this.queue.remove(t.rightSE), n.push(t.rightSE);
|
|
3922
4063
|
const f = t.split(a);
|
|
3923
4064
|
for (let d = 0, m = f.length; d < m; d++)
|
|
3924
4065
|
n.push(f[d]);
|
|
@@ -3954,33 +4095,33 @@ class Vr {
|
|
|
3954
4095
|
return r.push(n), e.consumedBy === void 0 && this.tree.add(e), r;
|
|
3955
4096
|
}
|
|
3956
4097
|
}
|
|
3957
|
-
const
|
|
3958
|
-
class
|
|
4098
|
+
const Ti = typeof process < "u" && process.env.POLYGON_CLIPPING_MAX_QUEUE_SIZE || 1e6, oo = typeof process < "u" && process.env.POLYGON_CLIPPING_MAX_SWEEPLINE_SEGMENTS || 1e6;
|
|
4099
|
+
class so {
|
|
3959
4100
|
run(e, t, n) {
|
|
3960
|
-
|
|
3961
|
-
const r = [new
|
|
4101
|
+
ae.type = e, Xe.reset();
|
|
4102
|
+
const r = [new Ni(t, !0)];
|
|
3962
4103
|
for (let a = 0, f = n.length; a < f; a++)
|
|
3963
|
-
r.push(new
|
|
3964
|
-
if (
|
|
4104
|
+
r.push(new Ni(n[a], !1));
|
|
4105
|
+
if (ae.numMultiPolys = r.length, ae.type === "difference") {
|
|
3965
4106
|
const a = r[0];
|
|
3966
4107
|
let f = 1;
|
|
3967
4108
|
for (; f < r.length; )
|
|
3968
|
-
|
|
4109
|
+
Gt(r[f].bbox, a.bbox) !== null ? f++ : r.splice(f, 1);
|
|
3969
4110
|
}
|
|
3970
|
-
if (
|
|
4111
|
+
if (ae.type === "intersection")
|
|
3971
4112
|
for (let a = 0, f = r.length; a < f; a++) {
|
|
3972
4113
|
const d = r[a];
|
|
3973
|
-
for (let m = a + 1,
|
|
3974
|
-
if (
|
|
4114
|
+
for (let m = a + 1, b = r.length; m < b; m++)
|
|
4115
|
+
if (Gt(d.bbox, r[m].bbox) === null) return [];
|
|
3975
4116
|
}
|
|
3976
|
-
const o = new
|
|
4117
|
+
const o = new Ht(re.compare);
|
|
3977
4118
|
for (let a = 0, f = r.length; a < f; a++) {
|
|
3978
4119
|
const d = r[a].getSweepEvents();
|
|
3979
|
-
for (let m = 0,
|
|
3980
|
-
if (o.insert(d[m]), o.size >
|
|
4120
|
+
for (let m = 0, b = d.length; m < b; m++)
|
|
4121
|
+
if (o.insert(d[m]), o.size > Ti)
|
|
3981
4122
|
throw new Error("Infinite loop when putting segment endpoints in a priority queue (queue size too big).");
|
|
3982
4123
|
}
|
|
3983
|
-
const l = new
|
|
4124
|
+
const l = new ro(o);
|
|
3984
4125
|
let s = o.size, c = o.pop();
|
|
3985
4126
|
for (; c; ) {
|
|
3986
4127
|
const a = c.key;
|
|
@@ -3988,78 +4129,78 @@ class Xr {
|
|
|
3988
4129
|
const d = a.segment;
|
|
3989
4130
|
throw new Error(`Unable to pop() ${a.isLeft ? "left" : "right"} SweepEvent [${a.point.x}, ${a.point.y}] from segment #${d.id} [${d.leftSE.point.x}, ${d.leftSE.point.y}] -> [${d.rightSE.point.x}, ${d.rightSE.point.y}] from queue.`);
|
|
3990
4131
|
}
|
|
3991
|
-
if (o.size >
|
|
4132
|
+
if (o.size > Ti)
|
|
3992
4133
|
throw new Error("Infinite loop when passing sweep line over endpoints (queue size too big).");
|
|
3993
|
-
if (l.segments.length >
|
|
4134
|
+
if (l.segments.length > oo)
|
|
3994
4135
|
throw new Error("Infinite loop when passing sweep line over endpoints (too many sweep line segments).");
|
|
3995
4136
|
const f = l.process(a);
|
|
3996
4137
|
for (let d = 0, m = f.length; d < m; d++) {
|
|
3997
|
-
const
|
|
3998
|
-
|
|
4138
|
+
const b = f[d];
|
|
4139
|
+
b.consumedBy === void 0 && o.insert(b);
|
|
3999
4140
|
}
|
|
4000
4141
|
s = o.size, c = o.pop();
|
|
4001
4142
|
}
|
|
4002
|
-
|
|
4003
|
-
const u =
|
|
4004
|
-
return new
|
|
4143
|
+
Xe.reset();
|
|
4144
|
+
const u = gt.factory(l.segments);
|
|
4145
|
+
return new no(u).getGeom();
|
|
4005
4146
|
}
|
|
4006
4147
|
}
|
|
4007
|
-
const
|
|
4148
|
+
const ae = new so(), lo = function(i) {
|
|
4008
4149
|
for (var e = arguments.length, t = new Array(e > 1 ? e - 1 : 0), n = 1; n < e; n++)
|
|
4009
4150
|
t[n - 1] = arguments[n];
|
|
4010
|
-
return
|
|
4011
|
-
},
|
|
4151
|
+
return ae.run("union", i, t);
|
|
4152
|
+
}, uo = function(i) {
|
|
4012
4153
|
for (var e = arguments.length, t = new Array(e > 1 ? e - 1 : 0), n = 1; n < e; n++)
|
|
4013
4154
|
t[n - 1] = arguments[n];
|
|
4014
|
-
return
|
|
4015
|
-
},
|
|
4155
|
+
return ae.run("intersection", i, t);
|
|
4156
|
+
}, ao = function(i) {
|
|
4016
4157
|
for (var e = arguments.length, t = new Array(e > 1 ? e - 1 : 0), n = 1; n < e; n++)
|
|
4017
4158
|
t[n - 1] = arguments[n];
|
|
4018
|
-
return
|
|
4019
|
-
},
|
|
4159
|
+
return ae.run("xor", i, t);
|
|
4160
|
+
}, co = function(i) {
|
|
4020
4161
|
for (var e = arguments.length, t = new Array(e > 1 ? e - 1 : 0), n = 1; n < e; n++)
|
|
4021
4162
|
t[n - 1] = arguments[n];
|
|
4022
|
-
return
|
|
4163
|
+
return ae.run("difference", i, t);
|
|
4023
4164
|
};
|
|
4024
|
-
var
|
|
4025
|
-
union:
|
|
4026
|
-
intersection:
|
|
4027
|
-
xor:
|
|
4028
|
-
difference:
|
|
4165
|
+
var Xi = {
|
|
4166
|
+
union: lo,
|
|
4167
|
+
intersection: uo,
|
|
4168
|
+
xor: ao,
|
|
4169
|
+
difference: co
|
|
4029
4170
|
};
|
|
4030
|
-
function
|
|
4171
|
+
function fo(i, e = {}) {
|
|
4031
4172
|
const t = [];
|
|
4032
|
-
if (
|
|
4173
|
+
if (Zt(i, (r) => {
|
|
4033
4174
|
t.push(r.coordinates);
|
|
4034
4175
|
}), t.length < 2)
|
|
4035
4176
|
throw new Error("Must have at least 2 geometries");
|
|
4036
|
-
const n =
|
|
4037
|
-
return n.length === 0 ? null : n.length === 1 ?
|
|
4177
|
+
const n = Xi.union(t[0], ...t.slice(1));
|
|
4178
|
+
return n.length === 0 ? null : n.length === 1 ? qt(n[0], e.properties) : qi(n, e.properties);
|
|
4038
4179
|
}
|
|
4039
|
-
var
|
|
4040
|
-
function
|
|
4180
|
+
var Ki = fo;
|
|
4181
|
+
function ho(i) {
|
|
4041
4182
|
const e = [];
|
|
4042
|
-
if (
|
|
4183
|
+
if (Zt(i, (r) => {
|
|
4043
4184
|
e.push(r.coordinates);
|
|
4044
4185
|
}), e.length < 2)
|
|
4045
4186
|
throw new Error("Must have at least two features");
|
|
4046
|
-
const t = i.features[0].properties || {}, n =
|
|
4047
|
-
return n.length === 0 ? null : n.length === 1 ?
|
|
4187
|
+
const t = i.features[0].properties || {}, n = Xi.difference(e[0], ...e.slice(1));
|
|
4188
|
+
return n.length === 0 ? null : n.length === 1 ? qt(n[0], t) : qi(n, t);
|
|
4048
4189
|
}
|
|
4049
|
-
var
|
|
4050
|
-
function
|
|
4190
|
+
var go = ho;
|
|
4191
|
+
function mo(i) {
|
|
4051
4192
|
if (!i)
|
|
4052
4193
|
throw new Error("geojson is required");
|
|
4053
4194
|
var e = [];
|
|
4054
|
-
return
|
|
4195
|
+
return Rr(i, function(t) {
|
|
4055
4196
|
e.push(t);
|
|
4056
|
-
}),
|
|
4197
|
+
}), Ye(e);
|
|
4057
4198
|
}
|
|
4058
|
-
var
|
|
4059
|
-
function
|
|
4060
|
-
const t =
|
|
4061
|
-
|
|
4062
|
-
|
|
4199
|
+
var po = mo;
|
|
4200
|
+
function Ri(i, e) {
|
|
4201
|
+
const t = go(
|
|
4202
|
+
Ye([
|
|
4203
|
+
qt([
|
|
4063
4204
|
[
|
|
4064
4205
|
[180, 90],
|
|
4065
4206
|
[-180, 90],
|
|
@@ -4074,10 +4215,10 @@ function xi(i, e) {
|
|
|
4074
4215
|
if (!t)
|
|
4075
4216
|
return;
|
|
4076
4217
|
t.properties = { isMask: !0 };
|
|
4077
|
-
const n =
|
|
4218
|
+
const n = He(Wt(i)), r = (n[2] - n[0]) / 360 / 1e3, o = n[0] < -180, l = n[2] > 180, s = po(i);
|
|
4078
4219
|
if (s.features.length > 1 && (o || l))
|
|
4079
4220
|
for (const c of s.features) {
|
|
4080
|
-
const u =
|
|
4221
|
+
const u = He(Wt(c));
|
|
4081
4222
|
if (l && u[0] < -180 + r)
|
|
4082
4223
|
for (const h of c.geometry.coordinates)
|
|
4083
4224
|
for (const a of h)
|
|
@@ -4088,13 +4229,13 @@ function xi(i, e) {
|
|
|
4088
4229
|
a[0] -= 360 - r;
|
|
4089
4230
|
}
|
|
4090
4231
|
e(
|
|
4091
|
-
|
|
4092
|
-
s.features.length < 2 ? i :
|
|
4232
|
+
Ye([
|
|
4233
|
+
s.features.length < 2 ? i : Ki(s) ?? i,
|
|
4093
4234
|
t
|
|
4094
4235
|
])
|
|
4095
4236
|
);
|
|
4096
4237
|
}
|
|
4097
|
-
const
|
|
4238
|
+
const Oi = (i) => {
|
|
4098
4239
|
var n, r, o;
|
|
4099
4240
|
const e = (n = i == null ? void 0 : i.geometry) == null ? void 0 : n.type, t = (r = i == null ? void 0 : i.properties) != null && r.isMask ? 0 : e === "LineString" || e === "MultiLineString" ? 3 : 2;
|
|
4100
4241
|
return {
|
|
@@ -4106,12 +4247,12 @@ const Mi = (i) => {
|
|
|
4106
4247
|
lineCap: "butt"
|
|
4107
4248
|
};
|
|
4108
4249
|
};
|
|
4109
|
-
function
|
|
4250
|
+
function yo(i, e = !0, t = !0, n = {}, r = {}, o = Oi) {
|
|
4110
4251
|
let l;
|
|
4111
4252
|
const s = [];
|
|
4112
4253
|
let c, u;
|
|
4113
|
-
const h =
|
|
4114
|
-
style: o === !0 ?
|
|
4254
|
+
const h = ue.geoJSON(void 0, {
|
|
4255
|
+
style: o === !0 ? Oi : o === !1 ? void 0 : o ?? void 0,
|
|
4115
4256
|
interactive: !1
|
|
4116
4257
|
}).addTo(i), a = (d) => {
|
|
4117
4258
|
l == null || l({
|
|
@@ -4120,11 +4261,11 @@ function so(i, e = !0, t = !0, n = {}, r = {}, o = Mi) {
|
|
|
4120
4261
|
});
|
|
4121
4262
|
};
|
|
4122
4263
|
function f(d, m = !1) {
|
|
4123
|
-
const
|
|
4124
|
-
return new
|
|
4264
|
+
const b = document.createElement("div");
|
|
4265
|
+
return new lr({ props: { displayIn: "leaflet" }, target: b }), new ue.Marker(d, {
|
|
4125
4266
|
interactive: m,
|
|
4126
|
-
icon: new
|
|
4127
|
-
html:
|
|
4267
|
+
icon: new ue.DivIcon({
|
|
4268
|
+
html: b,
|
|
4128
4269
|
className: "",
|
|
4129
4270
|
iconAnchor: [12, 26],
|
|
4130
4271
|
iconSize: [25, 30],
|
|
@@ -4139,7 +4280,7 @@ function so(i, e = !0, t = !0, n = {}, r = {}, o = Mi) {
|
|
|
4139
4280
|
flyTo(d, m) {
|
|
4140
4281
|
i.flyTo([d[1], d[0]], m, { duration: 2, ...n });
|
|
4141
4282
|
},
|
|
4142
|
-
fitBounds(d, m,
|
|
4283
|
+
fitBounds(d, m, b) {
|
|
4143
4284
|
i.flyToBounds(
|
|
4144
4285
|
[
|
|
4145
4286
|
[d[1], d[0]],
|
|
@@ -4148,7 +4289,7 @@ function so(i, e = !0, t = !0, n = {}, r = {}, o = Mi) {
|
|
|
4148
4289
|
{
|
|
4149
4290
|
padding: [m, m],
|
|
4150
4291
|
duration: 2,
|
|
4151
|
-
...
|
|
4292
|
+
...b ? { maxZoom: b } : {},
|
|
4152
4293
|
...r
|
|
4153
4294
|
}
|
|
4154
4295
|
);
|
|
@@ -4157,102 +4298,105 @@ function so(i, e = !0, t = !0, n = {}, r = {}, o = Mi) {
|
|
|
4157
4298
|
i.getContainer().style.cursor = d ? "crosshair" : "";
|
|
4158
4299
|
},
|
|
4159
4300
|
setReverseMarker(d) {
|
|
4160
|
-
var
|
|
4301
|
+
var b;
|
|
4161
4302
|
if (!e)
|
|
4162
4303
|
return;
|
|
4163
4304
|
const m = d && [d[1], d[0]];
|
|
4164
|
-
u ? m ? u.setLatLng(m) : (u.remove(), u = void 0) : m && (e instanceof Function ? u = e(i) ?? void 0 : (u = (typeof e == "object" ? new
|
|
4305
|
+
u ? m ? u.setLatLng(m) : (u.remove(), u = void 0) : m && (e instanceof Function ? u = e(i) ?? void 0 : (u = (typeof e == "object" ? new ue.Marker(m, e) : f(m)).addTo(i), (b = u.getElement()) == null || b.classList.add("marker-reverse")));
|
|
4165
4306
|
},
|
|
4166
|
-
|
|
4167
|
-
function v(
|
|
4168
|
-
h.clearLayers(),
|
|
4307
|
+
setFeatures(d, m, b) {
|
|
4308
|
+
function v(y) {
|
|
4309
|
+
h.clearLayers(), y && h.addData(y);
|
|
4169
4310
|
}
|
|
4170
|
-
for (const
|
|
4171
|
-
|
|
4172
|
-
|
|
4173
|
-
|
|
4311
|
+
for (const y of s)
|
|
4312
|
+
y.remove();
|
|
4313
|
+
s.length = 0, v();
|
|
4314
|
+
e: if (m) {
|
|
4315
|
+
let y = !1;
|
|
4174
4316
|
if (m.geometry.type === "GeometryCollection") {
|
|
4175
|
-
const
|
|
4317
|
+
const E = m.geometry.geometries.filter(
|
|
4176
4318
|
(_) => _.type === "Polygon" || _.type === "MultiPolygon"
|
|
4177
4319
|
);
|
|
4178
|
-
|
|
4179
|
-
const _ =
|
|
4180
|
-
|
|
4320
|
+
t: if (E.length > 0) {
|
|
4321
|
+
const _ = Ki(
|
|
4322
|
+
Ye(E.map((L) => Ve(L)))
|
|
4181
4323
|
);
|
|
4182
4324
|
if (!_)
|
|
4183
|
-
break
|
|
4184
|
-
|
|
4325
|
+
break t;
|
|
4326
|
+
Ri(
|
|
4185
4327
|
{
|
|
4186
4328
|
...m,
|
|
4187
4329
|
geometry: _.geometry
|
|
4188
4330
|
},
|
|
4189
4331
|
v
|
|
4190
|
-
),
|
|
4332
|
+
), y = !0;
|
|
4191
4333
|
} else {
|
|
4192
4334
|
const _ = m.geometry.geometries.filter(
|
|
4193
|
-
(
|
|
4335
|
+
(L) => L.type === "LineString" || L.type === "MultiLineString"
|
|
4194
4336
|
);
|
|
4195
4337
|
_.length > 0 && (v({
|
|
4196
4338
|
...m,
|
|
4197
4339
|
geometry: { type: "GeometryCollection", geometries: _ }
|
|
4198
|
-
}),
|
|
4340
|
+
}), y = !0);
|
|
4199
4341
|
}
|
|
4200
4342
|
}
|
|
4201
|
-
if (!
|
|
4343
|
+
if (!y) {
|
|
4202
4344
|
if (m.geometry.type === "Polygon" || m.geometry.type === "MultiPolygon")
|
|
4203
|
-
|
|
4204
|
-
if (!
|
|
4345
|
+
Ri(m, (E) => {
|
|
4346
|
+
if (!E)
|
|
4205
4347
|
return;
|
|
4206
|
-
const _ = [...
|
|
4207
|
-
|
|
4348
|
+
const _ = [...E.features], L = He(Wt(m)), P = L[2] - L[0];
|
|
4349
|
+
L[0] - P / 4 < -180 && _.push(...Ii(E, -360).features), L[2] + P / 4 > 180 && _.push(...Ii(E, 360).features), v(Ye(_));
|
|
4208
4350
|
});
|
|
4209
4351
|
else if (m.geometry.type === "LineString" || m.geometry.type === "MultiLineString") {
|
|
4210
4352
|
v(m);
|
|
4211
|
-
|
|
4353
|
+
break e;
|
|
4212
4354
|
}
|
|
4213
4355
|
}
|
|
4356
|
+
if (!b && m.geometry.type !== "Point")
|
|
4357
|
+
break e;
|
|
4214
4358
|
if (e instanceof Function) {
|
|
4215
|
-
const
|
|
4216
|
-
|
|
4359
|
+
const E = e(i, m);
|
|
4360
|
+
E && s.push(E.addTo(i));
|
|
4217
4361
|
} else if (e) {
|
|
4218
|
-
const
|
|
4362
|
+
const E = [m.center[1], m.center[0]];
|
|
4219
4363
|
s.push(
|
|
4220
|
-
typeof e == "object" ? new
|
|
4364
|
+
typeof e == "object" ? new ue.Marker(E, e) : f(E).addTo(i)
|
|
4221
4365
|
);
|
|
4222
4366
|
}
|
|
4223
4367
|
}
|
|
4224
4368
|
if (t)
|
|
4225
|
-
for (const
|
|
4226
|
-
if (
|
|
4369
|
+
for (const y of d ?? []) {
|
|
4370
|
+
if (y === m)
|
|
4227
4371
|
continue;
|
|
4228
|
-
const
|
|
4229
|
-
|
|
4230
|
-
|
|
4372
|
+
const E = [
|
|
4373
|
+
y.center[1],
|
|
4374
|
+
y.center[0]
|
|
4231
4375
|
];
|
|
4232
4376
|
let _;
|
|
4233
4377
|
if (t instanceof Function) {
|
|
4234
|
-
if (_ = t(i,
|
|
4378
|
+
if (_ = t(i, y), !_)
|
|
4235
4379
|
continue;
|
|
4236
4380
|
} else
|
|
4237
|
-
_ = (typeof t == "object" ? new
|
|
4238
|
-
|
|
4381
|
+
_ = (typeof t == "object" ? new ue.Marker(E, t) : f(E, !0)).addTo(i).bindTooltip(
|
|
4382
|
+
y.place_type[0] === "reverse" ? y.place_name : y.place_name.replace(/,.*/, ""),
|
|
4239
4383
|
{
|
|
4240
4384
|
direction: "top"
|
|
4241
4385
|
}
|
|
4242
4386
|
);
|
|
4243
|
-
const
|
|
4244
|
-
|
|
4245
|
-
|
|
4246
|
-
}),
|
|
4247
|
-
l == null || l({ type: "markerMouseEnter", id:
|
|
4248
|
-
}),
|
|
4249
|
-
l == null || l({ type: "markerMouseLeave", id:
|
|
4250
|
-
}),
|
|
4387
|
+
const L = _.getElement();
|
|
4388
|
+
L && (L.addEventListener("click", (P) => {
|
|
4389
|
+
P.stopPropagation(), l == null || l({ type: "markerClick", id: y.id });
|
|
4390
|
+
}), L.addEventListener("mouseenter", () => {
|
|
4391
|
+
l == null || l({ type: "markerMouseEnter", id: y.id });
|
|
4392
|
+
}), L.addEventListener("mouseleave", () => {
|
|
4393
|
+
l == null || l({ type: "markerMouseLeave", id: y.id });
|
|
4394
|
+
}), L.classList.toggle("marker-fuzzy", !!y.matching_text)), s.push(_);
|
|
4251
4395
|
}
|
|
4252
4396
|
},
|
|
4253
4397
|
setSelectedMarker(d) {
|
|
4254
|
-
var m,
|
|
4255
|
-
c && ((m = c.getElement()) == null || m.classList.toggle("marker-selected", !1)), c = d > -1 ? s[d] : void 0, (
|
|
4398
|
+
var m, b;
|
|
4399
|
+
c && ((m = c.getElement()) == null || m.classList.toggle("marker-selected", !1)), c = d > -1 ? s[d] : void 0, (b = c == null ? void 0 : c.getElement()) == null || b.classList.toggle("marker-selected", !0);
|
|
4256
4400
|
},
|
|
4257
4401
|
getCenterAndZoom() {
|
|
4258
4402
|
const d = i.getCenter();
|
|
@@ -4260,121 +4404,150 @@ function so(i, e = !0, t = !0, n = {}, r = {}, o = Mi) {
|
|
|
4260
4404
|
}
|
|
4261
4405
|
};
|
|
4262
4406
|
}
|
|
4263
|
-
function
|
|
4264
|
-
const t =
|
|
4407
|
+
function Ii(i, e) {
|
|
4408
|
+
const t = Ar(i);
|
|
4265
4409
|
for (const n of t.features)
|
|
4266
4410
|
if (n.geometry.type == "MultiPolygon")
|
|
4267
4411
|
for (const r of n.geometry.coordinates)
|
|
4268
|
-
|
|
4412
|
+
zi(r, e);
|
|
4269
4413
|
else
|
|
4270
|
-
|
|
4414
|
+
zi(n.geometry.coordinates, e);
|
|
4271
4415
|
return t;
|
|
4272
4416
|
}
|
|
4273
|
-
function
|
|
4417
|
+
function zi(i, e) {
|
|
4274
4418
|
for (const t of i)
|
|
4275
4419
|
for (const n of t)
|
|
4276
4420
|
n[0] += e;
|
|
4277
4421
|
}
|
|
4278
|
-
class
|
|
4279
|
-
// eslint-disable-next-line @typescript-eslint/no-useless-constructor, @typescript-eslint/no-unused-vars
|
|
4280
|
-
constructor(...e) {
|
|
4281
|
-
}
|
|
4422
|
+
class Ji extends ue.Control {
|
|
4282
4423
|
}
|
|
4283
|
-
|
|
4284
|
-
|
|
4285
|
-
|
|
4286
|
-
class lo extends Gt {
|
|
4424
|
+
ue.Util.extend(Ji.prototype, ue.Evented.prototype);
|
|
4425
|
+
var ie, Re;
|
|
4426
|
+
class bo extends Ji {
|
|
4287
4427
|
constructor(t) {
|
|
4288
|
-
super();
|
|
4289
|
-
|
|
4290
|
-
|
|
4291
|
-
|
|
4428
|
+
super(t);
|
|
4429
|
+
Nt(this, ie);
|
|
4430
|
+
Nt(this, Re);
|
|
4431
|
+
Pt(this, Re, t);
|
|
4292
4432
|
}
|
|
4293
4433
|
onAdd(t) {
|
|
4294
4434
|
const n = document.createElement("div");
|
|
4295
|
-
n.className = "leaflet-ctrl-geocoder",
|
|
4435
|
+
n.className = "leaflet-ctrl-geocoder", ue.DomEvent.disableClickPropagation(n), ue.DomEvent.disableScrollPropagation(n);
|
|
4296
4436
|
const {
|
|
4297
4437
|
marker: r,
|
|
4298
4438
|
showResultMarkers: o,
|
|
4299
4439
|
flyTo: l,
|
|
4300
4440
|
fullGeometryStyle: s,
|
|
4301
|
-
|
|
4302
|
-
|
|
4441
|
+
position: c,
|
|
4442
|
+
...u
|
|
4443
|
+
} = te(this, Re), h = typeof l == "boolean" ? {} : l, a = yo(
|
|
4303
4444
|
t,
|
|
4304
4445
|
r,
|
|
4305
4446
|
o,
|
|
4306
|
-
|
|
4307
|
-
|
|
4447
|
+
h,
|
|
4448
|
+
h,
|
|
4308
4449
|
s
|
|
4309
4450
|
);
|
|
4310
|
-
|
|
4451
|
+
Pt(this, ie, new Tr({
|
|
4311
4452
|
target: n,
|
|
4312
4453
|
props: {
|
|
4313
|
-
mapController:
|
|
4454
|
+
mapController: a,
|
|
4314
4455
|
flyTo: l === void 0 ? !0 : !!l,
|
|
4315
|
-
...
|
|
4456
|
+
...u
|
|
4316
4457
|
}
|
|
4317
4458
|
}));
|
|
4318
|
-
|
|
4319
|
-
|
|
4320
|
-
|
|
4321
|
-
|
|
4322
|
-
|
|
4323
|
-
|
|
4324
|
-
|
|
4325
|
-
|
|
4326
|
-
|
|
4327
|
-
|
|
4328
|
-
|
|
4329
|
-
|
|
4330
|
-
(f) => this.fire(a.toLowerCase(), f.detail)
|
|
4331
|
-
);
|
|
4459
|
+
const f = {
|
|
4460
|
+
select: void 0,
|
|
4461
|
+
pick: void 0,
|
|
4462
|
+
featureslisted: void 0,
|
|
4463
|
+
featuresmarked: void 0,
|
|
4464
|
+
response: void 0,
|
|
4465
|
+
optionsvisibilitychange: void 0,
|
|
4466
|
+
reversetoggle: void 0,
|
|
4467
|
+
querychange: void 0
|
|
4468
|
+
};
|
|
4469
|
+
for (const d in f)
|
|
4470
|
+
te(this, ie).$on(d, (m) => this.fire(d, m.detail));
|
|
4332
4471
|
return n;
|
|
4333
4472
|
}
|
|
4473
|
+
/**
|
|
4474
|
+
* Update the control options.
|
|
4475
|
+
*
|
|
4476
|
+
* @param options options to update
|
|
4477
|
+
*/
|
|
4334
4478
|
setOptions(t) {
|
|
4335
4479
|
var c;
|
|
4336
|
-
|
|
4480
|
+
Object.assign(te(this, Re), t);
|
|
4337
4481
|
const {
|
|
4338
4482
|
marker: n,
|
|
4339
4483
|
showResultMarkers: r,
|
|
4340
4484
|
flyTo: o,
|
|
4341
4485
|
fullGeometryStyle: l,
|
|
4342
4486
|
...s
|
|
4343
|
-
} =
|
|
4344
|
-
(c =
|
|
4487
|
+
} = te(this, Re);
|
|
4488
|
+
(c = te(this, ie)) == null || c.$set(s);
|
|
4345
4489
|
}
|
|
4490
|
+
/**
|
|
4491
|
+
* Set the content of search input box.
|
|
4492
|
+
*
|
|
4493
|
+
* @param value text to set
|
|
4494
|
+
* @param submit perform the search
|
|
4495
|
+
*/
|
|
4346
4496
|
setQuery(t, n = !0) {
|
|
4347
4497
|
var r;
|
|
4348
|
-
(r =
|
|
4498
|
+
(r = te(this, ie)) == null || r.setQuery(t, n);
|
|
4349
4499
|
}
|
|
4500
|
+
/**
|
|
4501
|
+
* Clear geocoding search results from the map.
|
|
4502
|
+
*/
|
|
4350
4503
|
clearMap() {
|
|
4351
4504
|
var t;
|
|
4352
|
-
(t =
|
|
4505
|
+
(t = te(this, ie)) == null || t.clearMap();
|
|
4353
4506
|
}
|
|
4507
|
+
/**
|
|
4508
|
+
* Clear search result list.
|
|
4509
|
+
*/
|
|
4354
4510
|
clearList() {
|
|
4355
4511
|
var t;
|
|
4356
|
-
(t =
|
|
4512
|
+
(t = te(this, ie)) == null || t.clearList();
|
|
4357
4513
|
}
|
|
4358
|
-
|
|
4359
|
-
|
|
4360
|
-
|
|
4514
|
+
/**
|
|
4515
|
+
* Set reverse geocoding mode.
|
|
4516
|
+
*
|
|
4517
|
+
* @param reverseActive reverse geocoding active
|
|
4518
|
+
*/
|
|
4519
|
+
setReverseMode(t) {
|
|
4520
|
+
var n;
|
|
4521
|
+
(n = te(this, ie)) == null || n.$set({ reverseActive: t });
|
|
4361
4522
|
}
|
|
4523
|
+
/**
|
|
4524
|
+
* Focus the search input box.
|
|
4525
|
+
*
|
|
4526
|
+
* @param options [FocusOptions](https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/focus#options)
|
|
4527
|
+
*/
|
|
4528
|
+
focus(t) {
|
|
4529
|
+
var n;
|
|
4530
|
+
(n = te(this, ie)) == null || n.focus(t);
|
|
4531
|
+
}
|
|
4532
|
+
/**
|
|
4533
|
+
* Blur the search input box.
|
|
4534
|
+
*/
|
|
4362
4535
|
blur() {
|
|
4363
4536
|
var t;
|
|
4364
|
-
(t =
|
|
4537
|
+
(t = te(this, ie)) == null || t.blur();
|
|
4365
4538
|
}
|
|
4366
4539
|
onRemove() {
|
|
4367
4540
|
var t;
|
|
4368
|
-
(t =
|
|
4541
|
+
(t = te(this, ie)) == null || t.$destroy();
|
|
4369
4542
|
}
|
|
4370
4543
|
}
|
|
4371
|
-
ie = new WeakMap(),
|
|
4372
|
-
function
|
|
4373
|
-
return new
|
|
4544
|
+
ie = new WeakMap(), Re = new WeakMap();
|
|
4545
|
+
function vo(...i) {
|
|
4546
|
+
return new bo(...i);
|
|
4374
4547
|
}
|
|
4375
|
-
window.L && typeof window.L == "object" && typeof window.L.control == "function" && (window.L.control.maptilerGeocoding =
|
|
4548
|
+
window.L && typeof window.L == "object" && typeof window.L.control == "function" && (window.L.control.maptilerGeocoding = vo);
|
|
4376
4549
|
export {
|
|
4377
|
-
|
|
4378
|
-
|
|
4550
|
+
bo as GeocodingControl,
|
|
4551
|
+
yo as createLeafletMapController
|
|
4379
4552
|
};
|
|
4380
4553
|
//# sourceMappingURL=leaflet.js.map
|