@maptiler/geocoding-control 0.0.91-git.9f388b → 0.0.91
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/FeatureItem.svelte +16 -10
- package/FeatureItem.svelte.d.ts +1 -0
- package/GeocodingControl.svelte +2 -0
- package/leaflet.js +734 -723
- package/leaflet.js.map +1 -1
- package/leaflet.umd.js +4 -4
- package/leaflet.umd.js.map +1 -1
- package/maplibregl.js +849 -838
- package/maplibregl.js.map +1 -1
- package/maplibregl.umd.js +4 -4
- package/maplibregl.umd.js.map +1 -1
- package/maptilersdk.js +848 -837
- package/maptilersdk.js.map +1 -1
- package/maptilersdk.umd.js +4 -4
- package/maptilersdk.umd.js.map +1 -1
- package/package.json +6 -6
- package/react.js +736 -725
- package/react.js.map +1 -1
- package/react.umd.js +1 -1
- package/react.umd.js.map +1 -1
package/maptilersdk.js
CHANGED
|
@@ -7,10 +7,10 @@ var Vn = (r, t, e) => (oa(r, t, "read from private field"), e ? e.call(r) : t.ge
|
|
|
7
7
|
throw TypeError("Cannot add the same private member more than once");
|
|
8
8
|
t instanceof WeakSet ? t.add(r) : t.set(r, e);
|
|
9
9
|
}, wo = (r, t, e, n) => (oa(r, t, "write to private field"), n ? n.call(r, e) : t.set(r, e), e);
|
|
10
|
-
import * as
|
|
10
|
+
import * as yl from "@maptiler/sdk";
|
|
11
11
|
function It() {
|
|
12
12
|
}
|
|
13
|
-
function
|
|
13
|
+
function ml(r, t) {
|
|
14
14
|
for (const e in t)
|
|
15
15
|
r[e] = t[e];
|
|
16
16
|
return r;
|
|
@@ -34,19 +34,19 @@ let Lo;
|
|
|
34
34
|
function br(r, t) {
|
|
35
35
|
return Lo || (Lo = document.createElement("a")), Lo.href = t, r === Lo.href;
|
|
36
36
|
}
|
|
37
|
-
function
|
|
37
|
+
function _l(r) {
|
|
38
38
|
return Object.keys(r).length === 0;
|
|
39
39
|
}
|
|
40
|
-
function
|
|
40
|
+
function El(r, t, e, n) {
|
|
41
41
|
if (r) {
|
|
42
42
|
const i = tu(r, t, e, n);
|
|
43
43
|
return r[0](i);
|
|
44
44
|
}
|
|
45
45
|
}
|
|
46
46
|
function tu(r, t, e, n) {
|
|
47
|
-
return r[1] && n ?
|
|
47
|
+
return r[1] && n ? ml(e.ctx.slice(), r[1](n(t))) : e.ctx;
|
|
48
48
|
}
|
|
49
|
-
function
|
|
49
|
+
function Il(r, t, e, n) {
|
|
50
50
|
if (r[2] && n) {
|
|
51
51
|
const i = r[2](n(e));
|
|
52
52
|
if (t.dirty === void 0)
|
|
@@ -61,13 +61,13 @@ function El(r, t, e, n) {
|
|
|
61
61
|
}
|
|
62
62
|
return t.dirty;
|
|
63
63
|
}
|
|
64
|
-
function
|
|
64
|
+
function Cl(r, t, e, n, i, o) {
|
|
65
65
|
if (i) {
|
|
66
66
|
const s = tu(t, e, n, o);
|
|
67
67
|
r.p(s, i);
|
|
68
68
|
}
|
|
69
69
|
}
|
|
70
|
-
function
|
|
70
|
+
function Nl(r) {
|
|
71
71
|
if (r.ctx.length > 32) {
|
|
72
72
|
const t = [], e = r.ctx.length / 32;
|
|
73
73
|
for (let n = 0; n < e; n++)
|
|
@@ -100,13 +100,13 @@ function Pr(r) {
|
|
|
100
100
|
function nn() {
|
|
101
101
|
return Pr(" ");
|
|
102
102
|
}
|
|
103
|
-
function
|
|
103
|
+
function xl() {
|
|
104
104
|
return Pr("");
|
|
105
105
|
}
|
|
106
106
|
function Ce(r, t, e, n) {
|
|
107
107
|
return r.addEventListener(t, e, n), () => r.removeEventListener(t, e, n);
|
|
108
108
|
}
|
|
109
|
-
function
|
|
109
|
+
function Sl(r) {
|
|
110
110
|
return function(t) {
|
|
111
111
|
return t.preventDefault(), r.call(this, t);
|
|
112
112
|
};
|
|
@@ -114,7 +114,7 @@ function xl(r) {
|
|
|
114
114
|
function P(r, t, e) {
|
|
115
115
|
e == null ? r.removeAttribute(t) : r.getAttribute(t) !== e && r.setAttribute(t, e);
|
|
116
116
|
}
|
|
117
|
-
function
|
|
117
|
+
function wl(r) {
|
|
118
118
|
return Array.from(r.childNodes);
|
|
119
119
|
}
|
|
120
120
|
function $i(r, t) {
|
|
@@ -126,7 +126,7 @@ function ua(r, t) {
|
|
|
126
126
|
function on(r, t, e) {
|
|
127
127
|
r.classList[e ? "add" : "remove"](t);
|
|
128
128
|
}
|
|
129
|
-
function
|
|
129
|
+
function Ll(r, t, { bubbles: e = !1, cancelable: n = !1 } = {}) {
|
|
130
130
|
const i = document.createEvent("CustomEvent");
|
|
131
131
|
return i.initCustomEvent(r, e, n, t), i;
|
|
132
132
|
}
|
|
@@ -139,15 +139,15 @@ function eu() {
|
|
|
139
139
|
throw new Error("Function called outside component initialization");
|
|
140
140
|
return to;
|
|
141
141
|
}
|
|
142
|
-
function
|
|
142
|
+
function bl(r) {
|
|
143
143
|
eu().$$.on_destroy.push(r);
|
|
144
144
|
}
|
|
145
|
-
function
|
|
145
|
+
function Pl() {
|
|
146
146
|
const r = eu();
|
|
147
147
|
return (t, e, { cancelable: n = !1 } = {}) => {
|
|
148
148
|
const i = r.$$.callbacks[t];
|
|
149
149
|
if (i) {
|
|
150
|
-
const o =
|
|
150
|
+
const o = Ll(t, e, { cancelable: n });
|
|
151
151
|
return i.slice().forEach((s) => {
|
|
152
152
|
s.call(r, o);
|
|
153
153
|
}), !o.defaultPrevented;
|
|
@@ -161,10 +161,10 @@ function la(r, t) {
|
|
|
161
161
|
}
|
|
162
162
|
const mi = [], Cs = [];
|
|
163
163
|
let Ei = [];
|
|
164
|
-
const ca = [],
|
|
164
|
+
const ca = [], Rl = /* @__PURE__ */ Promise.resolve();
|
|
165
165
|
let Ns = !1;
|
|
166
|
-
function
|
|
167
|
-
Ns || (Ns = !0,
|
|
166
|
+
function Ol() {
|
|
167
|
+
Ns || (Ns = !0, Rl.then(nu));
|
|
168
168
|
}
|
|
169
169
|
function xs(r) {
|
|
170
170
|
Ei.push(r);
|
|
@@ -179,7 +179,7 @@ function nu() {
|
|
|
179
179
|
try {
|
|
180
180
|
for (; yi < mi.length; ) {
|
|
181
181
|
const t = mi[yi];
|
|
182
|
-
yi++, Zi(t),
|
|
182
|
+
yi++, Zi(t), Tl(t.$$);
|
|
183
183
|
}
|
|
184
184
|
} catch (t) {
|
|
185
185
|
throw mi.length = 0, yi = 0, t;
|
|
@@ -196,14 +196,14 @@ function nu() {
|
|
|
196
196
|
ca.pop()();
|
|
197
197
|
Ns = !1, ys.clear(), Zi(r);
|
|
198
198
|
}
|
|
199
|
-
function
|
|
199
|
+
function Tl(r) {
|
|
200
200
|
if (r.fragment !== null) {
|
|
201
201
|
r.update(), _r(r.before_update);
|
|
202
202
|
const t = r.dirty;
|
|
203
203
|
r.dirty = [-1], r.fragment && r.fragment.p(r.ctx, t), r.after_update.forEach(xs);
|
|
204
204
|
}
|
|
205
205
|
}
|
|
206
|
-
function
|
|
206
|
+
function Dl(r) {
|
|
207
207
|
const t = [], e = [];
|
|
208
208
|
Ei.forEach((n) => r.indexOf(n) === -1 ? t.push(n) : e.push(n)), e.forEach((n) => n()), Ei = t;
|
|
209
209
|
}
|
|
@@ -233,37 +233,37 @@ function le(r, t, e, n) {
|
|
|
233
233
|
} else
|
|
234
234
|
n && n();
|
|
235
235
|
}
|
|
236
|
-
function
|
|
236
|
+
function Ml(r, t) {
|
|
237
237
|
le(r, 1, 1, () => {
|
|
238
238
|
t.delete(r.key);
|
|
239
239
|
});
|
|
240
240
|
}
|
|
241
|
-
function
|
|
241
|
+
function Al(r, t, e, n, i, o, s, a, u, l, c, f) {
|
|
242
242
|
let h = r.length, g = o.length, p = h;
|
|
243
|
-
const
|
|
243
|
+
const y = {};
|
|
244
244
|
for (; p--; )
|
|
245
|
-
|
|
246
|
-
const
|
|
245
|
+
y[r[p].key] = p;
|
|
246
|
+
const m = [], d = /* @__PURE__ */ new Map(), E = /* @__PURE__ */ new Map(), C = [];
|
|
247
247
|
for (p = g; p--; ) {
|
|
248
248
|
const T = f(i, o, p), A = e(T);
|
|
249
249
|
let L = s.get(A);
|
|
250
|
-
L ? n && C.push(() => L.p(T, t)) : (L = l(A, T), L.c()),
|
|
250
|
+
L ? n && C.push(() => L.p(T, t)) : (L = l(A, T), L.c()), d.set(A, m[p] = L), A in y && E.set(A, Math.abs(p - y[A]));
|
|
251
251
|
}
|
|
252
|
-
const
|
|
253
|
-
function
|
|
252
|
+
const S = /* @__PURE__ */ new Set(), N = /* @__PURE__ */ new Set();
|
|
253
|
+
function w(T) {
|
|
254
254
|
Gt(T, 1), T.m(a, c), s.set(T.key, T), c = T.first, g--;
|
|
255
255
|
}
|
|
256
256
|
for (; h && g; ) {
|
|
257
|
-
const T =
|
|
258
|
-
T === A ? (c = T.first, h--, g--) :
|
|
257
|
+
const T = m[g - 1], A = r[h - 1], L = T.key, F = A.key;
|
|
258
|
+
T === A ? (c = T.first, h--, g--) : d.has(F) ? !s.has(L) || S.has(L) ? w(T) : N.has(F) ? h-- : E.get(L) > E.get(F) ? (N.add(L), w(T)) : (S.add(F), h--) : (u(A, s), h--);
|
|
259
259
|
}
|
|
260
260
|
for (; h--; ) {
|
|
261
261
|
const T = r[h];
|
|
262
|
-
|
|
262
|
+
d.has(T.key) || u(T, s);
|
|
263
263
|
}
|
|
264
264
|
for (; g; )
|
|
265
|
-
|
|
266
|
-
return _r(C),
|
|
265
|
+
w(m[g - 1]);
|
|
266
|
+
return _r(C), m;
|
|
267
267
|
}
|
|
268
268
|
function Rr(r) {
|
|
269
269
|
r && r.c();
|
|
@@ -277,10 +277,10 @@ function ur(r, t, e, n) {
|
|
|
277
277
|
}
|
|
278
278
|
function lr(r, t) {
|
|
279
279
|
const e = r.$$;
|
|
280
|
-
e.fragment !== null && (
|
|
280
|
+
e.fragment !== null && (Dl(e.after_update), _r(e.on_destroy), e.fragment && e.fragment.d(t), e.on_destroy = e.fragment = null, e.ctx = []);
|
|
281
281
|
}
|
|
282
|
-
function
|
|
283
|
-
r.$$.dirty[0] === -1 && (mi.push(r),
|
|
282
|
+
function Fl(r, t) {
|
|
283
|
+
r.$$.dirty[0] === -1 && (mi.push(r), Ol(), r.$$.dirty.fill(0)), r.$$.dirty[t / 31 | 0] |= 1 << t % 31;
|
|
284
284
|
}
|
|
285
285
|
function Ur(r, t, e, n, i, o, s, a = [-1]) {
|
|
286
286
|
const u = to;
|
|
@@ -310,10 +310,10 @@ function Ur(r, t, e, n, i, o, s, a = [-1]) {
|
|
|
310
310
|
let c = !1;
|
|
311
311
|
if (l.ctx = e ? e(r, t.props || {}, (f, h, ...g) => {
|
|
312
312
|
const p = g.length ? g[0] : h;
|
|
313
|
-
return l.ctx && i(l.ctx[f], l.ctx[f] = p) && (!l.skip_bound && l.bound[f] && l.bound[f](p), c &&
|
|
313
|
+
return l.ctx && i(l.ctx[f], l.ctx[f] = p) && (!l.skip_bound && l.bound[f] && l.bound[f](p), c && Fl(r, f)), h;
|
|
314
314
|
}) : [], l.update(), c = !0, _r(l.before_update), l.fragment = n ? n(l.ctx) : !1, t.target) {
|
|
315
315
|
if (t.hydrate) {
|
|
316
|
-
const f =
|
|
316
|
+
const f = wl(t.target);
|
|
317
317
|
l.fragment && l.fragment.l(f), f.forEach(Tt);
|
|
318
318
|
} else
|
|
319
319
|
l.fragment && l.fragment.c();
|
|
@@ -335,10 +335,10 @@ class qr {
|
|
|
335
335
|
};
|
|
336
336
|
}
|
|
337
337
|
$set(t) {
|
|
338
|
-
this.$$set && !
|
|
338
|
+
this.$$set && !_l(t) && (this.$$.skip_bound = !0, this.$$set(t), this.$$.skip_bound = !1);
|
|
339
339
|
}
|
|
340
340
|
}
|
|
341
|
-
function
|
|
341
|
+
function kl(r) {
|
|
342
342
|
let t, e;
|
|
343
343
|
return {
|
|
344
344
|
c() {
|
|
@@ -357,10 +357,10 @@ function Fl(r) {
|
|
|
357
357
|
}
|
|
358
358
|
class ru extends qr {
|
|
359
359
|
constructor(t) {
|
|
360
|
-
super(), Ur(this, t, null,
|
|
360
|
+
super(), Ur(this, t, null, kl, zr, {});
|
|
361
361
|
}
|
|
362
362
|
}
|
|
363
|
-
function
|
|
363
|
+
function Bl(r) {
|
|
364
364
|
let t, e;
|
|
365
365
|
return {
|
|
366
366
|
c() {
|
|
@@ -379,10 +379,10 @@ function kl(r) {
|
|
|
379
379
|
}
|
|
380
380
|
class iu extends qr {
|
|
381
381
|
constructor(t) {
|
|
382
|
-
super(), Ur(this, t, null,
|
|
382
|
+
super(), Ur(this, t, null, Bl, zr, {});
|
|
383
383
|
}
|
|
384
384
|
}
|
|
385
|
-
function
|
|
385
|
+
function Gl(r) {
|
|
386
386
|
let t, e;
|
|
387
387
|
return {
|
|
388
388
|
c() {
|
|
@@ -390,7 +390,7 @@ function Bl(r) {
|
|
|
390
390
|
t,
|
|
391
391
|
"alt",
|
|
392
392
|
/*placeType*/
|
|
393
|
-
r[
|
|
393
|
+
r[5]
|
|
394
394
|
), P(t, "class", "svelte-ltkwvy");
|
|
395
395
|
},
|
|
396
396
|
m(n, i) {
|
|
@@ -398,11 +398,11 @@ function Bl(r) {
|
|
|
398
398
|
},
|
|
399
399
|
p(n, i) {
|
|
400
400
|
i & /*placeType*/
|
|
401
|
-
|
|
401
|
+
32 && P(
|
|
402
402
|
t,
|
|
403
403
|
"alt",
|
|
404
404
|
/*placeType*/
|
|
405
|
-
n[
|
|
405
|
+
n[5]
|
|
406
406
|
);
|
|
407
407
|
},
|
|
408
408
|
d(n) {
|
|
@@ -410,7 +410,7 @@ function Bl(r) {
|
|
|
410
410
|
}
|
|
411
411
|
};
|
|
412
412
|
}
|
|
413
|
-
function
|
|
413
|
+
function Vl(r) {
|
|
414
414
|
let t, e;
|
|
415
415
|
return {
|
|
416
416
|
c() {
|
|
@@ -418,7 +418,7 @@ function Gl(r) {
|
|
|
418
418
|
t,
|
|
419
419
|
"alt",
|
|
420
420
|
/*placeType*/
|
|
421
|
-
r[
|
|
421
|
+
r[5]
|
|
422
422
|
), P(t, "class", "svelte-ltkwvy");
|
|
423
423
|
},
|
|
424
424
|
m(n, i) {
|
|
@@ -426,11 +426,11 @@ function Gl(r) {
|
|
|
426
426
|
},
|
|
427
427
|
p(n, i) {
|
|
428
428
|
i & /*placeType*/
|
|
429
|
-
|
|
429
|
+
32 && P(
|
|
430
430
|
t,
|
|
431
431
|
"alt",
|
|
432
432
|
/*placeType*/
|
|
433
|
-
n[
|
|
433
|
+
n[5]
|
|
434
434
|
);
|
|
435
435
|
},
|
|
436
436
|
d(n) {
|
|
@@ -438,7 +438,7 @@ function Gl(r) {
|
|
|
438
438
|
}
|
|
439
439
|
};
|
|
440
440
|
}
|
|
441
|
-
function
|
|
441
|
+
function zl(r) {
|
|
442
442
|
let t, e;
|
|
443
443
|
return {
|
|
444
444
|
c() {
|
|
@@ -446,7 +446,7 @@ function Vl(r) {
|
|
|
446
446
|
t,
|
|
447
447
|
"alt",
|
|
448
448
|
/*placeType*/
|
|
449
|
-
r[
|
|
449
|
+
r[5]
|
|
450
450
|
), P(t, "class", "svelte-ltkwvy");
|
|
451
451
|
},
|
|
452
452
|
m(n, i) {
|
|
@@ -454,11 +454,11 @@ function Vl(r) {
|
|
|
454
454
|
},
|
|
455
455
|
p(n, i) {
|
|
456
456
|
i & /*placeType*/
|
|
457
|
-
|
|
457
|
+
32 && P(
|
|
458
458
|
t,
|
|
459
459
|
"alt",
|
|
460
460
|
/*placeType*/
|
|
461
|
-
n[
|
|
461
|
+
n[5]
|
|
462
462
|
);
|
|
463
463
|
},
|
|
464
464
|
d(n) {
|
|
@@ -466,7 +466,7 @@ function Vl(r) {
|
|
|
466
466
|
}
|
|
467
467
|
};
|
|
468
468
|
}
|
|
469
|
-
function
|
|
469
|
+
function Ul(r) {
|
|
470
470
|
let t, e;
|
|
471
471
|
return {
|
|
472
472
|
c() {
|
|
@@ -474,7 +474,7 @@ function zl(r) {
|
|
|
474
474
|
t,
|
|
475
475
|
"alt",
|
|
476
476
|
/*placeType*/
|
|
477
|
-
r[
|
|
477
|
+
r[5]
|
|
478
478
|
), P(t, "class", "svelte-ltkwvy");
|
|
479
479
|
},
|
|
480
480
|
m(n, i) {
|
|
@@ -482,11 +482,11 @@ function zl(r) {
|
|
|
482
482
|
},
|
|
483
483
|
p(n, i) {
|
|
484
484
|
i & /*placeType*/
|
|
485
|
-
|
|
485
|
+
32 && P(
|
|
486
486
|
t,
|
|
487
487
|
"alt",
|
|
488
488
|
/*placeType*/
|
|
489
|
-
n[
|
|
489
|
+
n[5]
|
|
490
490
|
);
|
|
491
491
|
},
|
|
492
492
|
d(n) {
|
|
@@ -494,7 +494,7 @@ function zl(r) {
|
|
|
494
494
|
}
|
|
495
495
|
};
|
|
496
496
|
}
|
|
497
|
-
function
|
|
497
|
+
function ql(r) {
|
|
498
498
|
let t, e;
|
|
499
499
|
return {
|
|
500
500
|
c() {
|
|
@@ -502,7 +502,7 @@ function Ul(r) {
|
|
|
502
502
|
t,
|
|
503
503
|
"alt",
|
|
504
504
|
/*placeType*/
|
|
505
|
-
r[
|
|
505
|
+
r[5]
|
|
506
506
|
), P(t, "class", "svelte-ltkwvy");
|
|
507
507
|
},
|
|
508
508
|
m(n, i) {
|
|
@@ -510,11 +510,11 @@ function Ul(r) {
|
|
|
510
510
|
},
|
|
511
511
|
p(n, i) {
|
|
512
512
|
i & /*placeType*/
|
|
513
|
-
|
|
513
|
+
32 && P(
|
|
514
514
|
t,
|
|
515
515
|
"alt",
|
|
516
516
|
/*placeType*/
|
|
517
|
-
n[
|
|
517
|
+
n[5]
|
|
518
518
|
);
|
|
519
519
|
},
|
|
520
520
|
d(n) {
|
|
@@ -522,7 +522,7 @@ function Ul(r) {
|
|
|
522
522
|
}
|
|
523
523
|
};
|
|
524
524
|
}
|
|
525
|
-
function
|
|
525
|
+
function Xl(r) {
|
|
526
526
|
let t, e;
|
|
527
527
|
return {
|
|
528
528
|
c() {
|
|
@@ -530,7 +530,7 @@ function ql(r) {
|
|
|
530
530
|
t,
|
|
531
531
|
"alt",
|
|
532
532
|
/*placeType*/
|
|
533
|
-
r[
|
|
533
|
+
r[5]
|
|
534
534
|
), P(t, "class", "svelte-ltkwvy");
|
|
535
535
|
},
|
|
536
536
|
m(n, i) {
|
|
@@ -538,11 +538,11 @@ function ql(r) {
|
|
|
538
538
|
},
|
|
539
539
|
p(n, i) {
|
|
540
540
|
i & /*placeType*/
|
|
541
|
-
|
|
541
|
+
32 && P(
|
|
542
542
|
t,
|
|
543
543
|
"alt",
|
|
544
544
|
/*placeType*/
|
|
545
|
-
n[
|
|
545
|
+
n[5]
|
|
546
546
|
);
|
|
547
547
|
},
|
|
548
548
|
d(n) {
|
|
@@ -550,12 +550,12 @@ function ql(r) {
|
|
|
550
550
|
}
|
|
551
551
|
};
|
|
552
552
|
}
|
|
553
|
-
function
|
|
553
|
+
function Yl(r) {
|
|
554
554
|
let t, e, n, i;
|
|
555
555
|
return {
|
|
556
556
|
c() {
|
|
557
557
|
t = ht("img"), br(t.src, e = /*imageUrl*/
|
|
558
|
-
r[
|
|
558
|
+
r[4]) || P(t, "src", e), P(
|
|
559
559
|
t,
|
|
560
560
|
"alt",
|
|
561
561
|
/*category*/
|
|
@@ -567,13 +567,13 @@ function Xl(r) {
|
|
|
567
567
|
t,
|
|
568
568
|
"error",
|
|
569
569
|
/*error_handler*/
|
|
570
|
-
r[
|
|
570
|
+
r[11]
|
|
571
571
|
), n = !0);
|
|
572
572
|
},
|
|
573
573
|
p(o, s) {
|
|
574
574
|
s & /*imageUrl*/
|
|
575
|
-
|
|
576
|
-
o[
|
|
575
|
+
16 && !br(t.src, e = /*imageUrl*/
|
|
576
|
+
o[4]) && P(t, "src", e), s & /*category*/
|
|
577
577
|
8 && P(
|
|
578
578
|
t,
|
|
579
579
|
"alt",
|
|
@@ -592,7 +592,7 @@ function fa(r) {
|
|
|
592
592
|
c() {
|
|
593
593
|
t = ht("span"), e = Pr(
|
|
594
594
|
/*placeType*/
|
|
595
|
-
r[
|
|
595
|
+
r[5]
|
|
596
596
|
), P(t, "class", "secondary svelte-ltkwvy");
|
|
597
597
|
},
|
|
598
598
|
m(n, i) {
|
|
@@ -600,10 +600,10 @@ function fa(r) {
|
|
|
600
600
|
},
|
|
601
601
|
p(n, i) {
|
|
602
602
|
i & /*placeType*/
|
|
603
|
-
|
|
603
|
+
32 && $i(
|
|
604
604
|
e,
|
|
605
605
|
/*placeType*/
|
|
606
|
-
n[
|
|
606
|
+
n[5]
|
|
607
607
|
);
|
|
608
608
|
},
|
|
609
609
|
d(n) {
|
|
@@ -611,7 +611,7 @@ function fa(r) {
|
|
|
611
611
|
}
|
|
612
612
|
};
|
|
613
613
|
}
|
|
614
|
-
function
|
|
614
|
+
function Wl(r) {
|
|
615
615
|
var T, A;
|
|
616
616
|
let t, e, n, i, o, s, a, u, l = (
|
|
617
617
|
/*feature*/
|
|
@@ -626,33 +626,33 @@ function Yl(r) {
|
|
|
626
626
|
r[0].id.startsWith("address.") && !/*feature*/
|
|
627
627
|
r[0].id.startsWith("postal_code.") && (!/*feature*/
|
|
628
628
|
r[0].id.startsWith("poi.") || !/*imageUrl*/
|
|
629
|
-
r[
|
|
630
|
-
), g, p,
|
|
629
|
+
r[4])
|
|
630
|
+
), g, p, y = (
|
|
631
631
|
/*feature*/
|
|
632
632
|
r[0].place_name.replace(/[^,]*,?\s*/, "") + ""
|
|
633
|
-
),
|
|
633
|
+
), m, d, E;
|
|
634
634
|
function C(L, F) {
|
|
635
635
|
var X, R;
|
|
636
636
|
return F & /*feature*/
|
|
637
637
|
1 && (e = null), F & /*feature*/
|
|
638
638
|
1 && (n = null), F & /*feature*/
|
|
639
639
|
1 && (i = null), /*imageUrl*/
|
|
640
|
-
L[
|
|
640
|
+
L[4] ? Yl : (
|
|
641
641
|
/*feature*/
|
|
642
|
-
L[0].address ?
|
|
642
|
+
L[0].address ? Xl : (
|
|
643
643
|
/*feature*/
|
|
644
644
|
((X = L[0].properties) == null ? void 0 : X.kind) === "road" || /*feature*/
|
|
645
|
-
((R = L[0].properties) == null ? void 0 : R.kind) === "road_relation" ?
|
|
646
|
-
L[0].id.startsWith("address.")), e ?
|
|
647
|
-
L[0].id.startsWith("postal_code.")), n ?
|
|
648
|
-
L[0].id.startsWith("poi.")), i ?
|
|
645
|
+
((R = L[0].properties) == null ? void 0 : R.kind) === "road_relation" ? ql : (e == null && (e = !!/*feature*/
|
|
646
|
+
L[0].id.startsWith("address.")), e ? Ul : (n == null && (n = !!/*feature*/
|
|
647
|
+
L[0].id.startsWith("postal_code.")), n ? zl : (i == null && (i = !!/*feature*/
|
|
648
|
+
L[0].id.startsWith("poi.")), i ? Vl : Gl)))
|
|
649
649
|
)
|
|
650
650
|
);
|
|
651
651
|
}
|
|
652
|
-
let
|
|
652
|
+
let S = C(r, -1), N = S(r), w = h && fa(r);
|
|
653
653
|
return {
|
|
654
654
|
c() {
|
|
655
|
-
t = ht("li"), N.c(), o = nn(), s = ht("span"), a = ht("span"), u = ht("span"), c = Pr(l), f = nn(),
|
|
655
|
+
t = ht("li"), N.c(), o = nn(), s = ht("span"), a = ht("span"), u = ht("span"), c = Pr(l), f = nn(), w && w.c(), g = nn(), p = ht("span"), m = Pr(y), P(u, "class", "primary svelte-ltkwvy"), P(a, "class", "svelte-ltkwvy"), P(p, "class", "line2 svelte-ltkwvy"), P(s, "class", "texts svelte-ltkwvy"), P(t, "tabindex", "0"), P(
|
|
656
656
|
t,
|
|
657
657
|
"data-selected",
|
|
658
658
|
/*selected*/
|
|
@@ -665,27 +665,27 @@ function Yl(r) {
|
|
|
665
665
|
);
|
|
666
666
|
},
|
|
667
667
|
m(L, F) {
|
|
668
|
-
Dt(L, t, F), N.m(t, null), nt(t, o), nt(t, s), nt(s, a), nt(a, u), nt(u, c), nt(a, f),
|
|
668
|
+
Dt(L, t, F), N.m(t, null), nt(t, o), nt(t, s), nt(s, a), nt(a, u), nt(u, c), nt(a, f), w && w.m(a, null), nt(s, g), nt(s, p), nt(p, m), d || (E = [
|
|
669
669
|
Ce(
|
|
670
670
|
t,
|
|
671
671
|
"mouseenter",
|
|
672
672
|
/*mouseenter_handler*/
|
|
673
|
-
r[
|
|
673
|
+
r[9]
|
|
674
674
|
),
|
|
675
675
|
Ce(
|
|
676
676
|
t,
|
|
677
677
|
"focus",
|
|
678
678
|
/*focus_handler*/
|
|
679
|
-
r[
|
|
679
|
+
r[10]
|
|
680
680
|
)
|
|
681
|
-
],
|
|
681
|
+
], d = !0);
|
|
682
682
|
},
|
|
683
683
|
p(L, [F]) {
|
|
684
684
|
var X, R;
|
|
685
|
-
|
|
685
|
+
S === (S = C(L, F)) && N ? N.p(L, F) : (N.d(1), N = S(L), N && (N.c(), N.m(t, o))), F & /*feature*/
|
|
686
686
|
1 && l !== (l = /*feature*/
|
|
687
687
|
L[0].place_name.replace(/,.*/, "") + "") && $i(c, l), F & /*showPlaceType, feature, imageUrl*/
|
|
688
|
-
|
|
688
|
+
21 && (h = /*showPlaceType*/
|
|
689
689
|
L[2] === "always" || /*showPlaceType*/
|
|
690
690
|
L[2] && !/*feature*/
|
|
691
691
|
L[0].address && /*feature*/
|
|
@@ -694,9 +694,9 @@ function Yl(r) {
|
|
|
694
694
|
L[0].id.startsWith("address.") && !/*feature*/
|
|
695
695
|
L[0].id.startsWith("postal_code.") && (!/*feature*/
|
|
696
696
|
L[0].id.startsWith("poi.") || !/*imageUrl*/
|
|
697
|
-
L[
|
|
698
|
-
1 &&
|
|
699
|
-
L[0].place_name.replace(/[^,]*,?\s*/, "") + "") && $i(
|
|
697
|
+
L[4])), h ? w ? w.p(L, F) : (w = fa(L), w.c(), w.m(a, null)) : w && (w.d(1), w = null), F & /*feature*/
|
|
698
|
+
1 && y !== (y = /*feature*/
|
|
699
|
+
L[0].place_name.replace(/[^,]*,?\s*/, "") + "") && $i(m, y), F & /*selected*/
|
|
700
700
|
2 && P(
|
|
701
701
|
t,
|
|
702
702
|
"data-selected",
|
|
@@ -713,56 +713,62 @@ function Yl(r) {
|
|
|
713
713
|
i: It,
|
|
714
714
|
o: It,
|
|
715
715
|
d(L) {
|
|
716
|
-
L && Tt(t), N.d(),
|
|
716
|
+
L && Tt(t), N.d(), w && w.d(), d = !1, _r(E);
|
|
717
717
|
}
|
|
718
718
|
};
|
|
719
719
|
}
|
|
720
|
-
function
|
|
721
|
-
var
|
|
722
|
-
let n, i,
|
|
723
|
-
const
|
|
724
|
-
|
|
725
|
-
n > -1 ? e(7, n--, n) : d.style.visibility = "hidden";
|
|
726
|
-
}
|
|
720
|
+
function Hl(r, t, e) {
|
|
721
|
+
var m;
|
|
722
|
+
let n, i, { feature: o } = t, { selected: s = !1 } = t, { showPlaceType: a } = t, { missingIconsCache: u } = t;
|
|
723
|
+
const l = (m = o.properties) == null ? void 0 : m.categories;
|
|
724
|
+
let c, f;
|
|
727
725
|
function h(d) {
|
|
728
|
-
|
|
726
|
+
f && u.add(f), e(8, n--, n);
|
|
729
727
|
}
|
|
730
728
|
function g(d) {
|
|
731
729
|
la.call(this, r, d);
|
|
732
730
|
}
|
|
733
|
-
|
|
731
|
+
function p(d) {
|
|
732
|
+
la.call(this, r, d);
|
|
733
|
+
}
|
|
734
|
+
const y = (d) => h(d.currentTarget);
|
|
734
735
|
return r.$$set = (d) => {
|
|
735
|
-
"feature" in d && e(0,
|
|
736
|
+
"feature" in d && e(0, o = d.feature), "selected" in d && e(1, s = d.selected), "showPlaceType" in d && e(2, a = d.showPlaceType), "missingIconsCache" in d && e(7, u = d.missingIconsCache);
|
|
736
737
|
}, r.$$.update = () => {
|
|
737
|
-
var d,
|
|
738
|
-
r.$$.dirty & /*index*/
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
i,
|
|
747
|
-
s,
|
|
738
|
+
var d, E, C, S;
|
|
739
|
+
if (r.$$.dirty & /*index, category, imageUrl, missingIconsCache*/
|
|
740
|
+
408)
|
|
741
|
+
do
|
|
742
|
+
e(8, n--, n), e(3, c = l == null ? void 0 : l[n]), e(4, f = c ? `/icons/${c.replace(/ /g, "_")}.svg` : void 0);
|
|
743
|
+
while (n > -1 && (!f || u.has(f)));
|
|
744
|
+
r.$$.dirty & /*feature*/
|
|
745
|
+
1 && e(5, i = o.id.startsWith("poi.") ? (E = (d = o.properties) == null ? void 0 : d.categories) == null ? void 0 : E.join(", ") : ((S = (C = o.properties) == null ? void 0 : C.place_type_name) == null ? void 0 : S[0]) ?? o.place_type[0]);
|
|
746
|
+
}, e(8, n = (l == null ? void 0 : l.length) ?? 0), [
|
|
748
747
|
o,
|
|
748
|
+
s,
|
|
749
|
+
a,
|
|
750
|
+
c,
|
|
749
751
|
f,
|
|
750
|
-
|
|
752
|
+
i,
|
|
751
753
|
h,
|
|
754
|
+
u,
|
|
755
|
+
n,
|
|
752
756
|
g,
|
|
753
|
-
p
|
|
757
|
+
p,
|
|
758
|
+
y
|
|
754
759
|
];
|
|
755
760
|
}
|
|
756
|
-
class
|
|
761
|
+
class jl extends qr {
|
|
757
762
|
constructor(t) {
|
|
758
|
-
super(), Ur(this, t,
|
|
763
|
+
super(), Ur(this, t, Hl, Wl, zr, {
|
|
759
764
|
feature: 0,
|
|
760
765
|
selected: 1,
|
|
761
|
-
showPlaceType: 2
|
|
766
|
+
showPlaceType: 2,
|
|
767
|
+
missingIconsCache: 7
|
|
762
768
|
});
|
|
763
769
|
}
|
|
764
770
|
}
|
|
765
|
-
function
|
|
771
|
+
function Kl(r) {
|
|
766
772
|
let t;
|
|
767
773
|
return {
|
|
768
774
|
c() {
|
|
@@ -779,12 +785,12 @@ function jl(r) {
|
|
|
779
785
|
}
|
|
780
786
|
};
|
|
781
787
|
}
|
|
782
|
-
class
|
|
788
|
+
class Ql extends qr {
|
|
783
789
|
constructor(t) {
|
|
784
|
-
super(), Ur(this, t, null,
|
|
790
|
+
super(), Ur(this, t, null, Kl, zr, {});
|
|
785
791
|
}
|
|
786
792
|
}
|
|
787
|
-
function
|
|
793
|
+
function Zl(r) {
|
|
788
794
|
let t, e;
|
|
789
795
|
return {
|
|
790
796
|
c() {
|
|
@@ -801,12 +807,12 @@ function Ql(r) {
|
|
|
801
807
|
}
|
|
802
808
|
};
|
|
803
809
|
}
|
|
804
|
-
class
|
|
810
|
+
class Jl extends qr {
|
|
805
811
|
constructor(t) {
|
|
806
|
-
super(), Ur(this, t, null,
|
|
812
|
+
super(), Ur(this, t, null, Zl, zr, {});
|
|
807
813
|
}
|
|
808
814
|
}
|
|
809
|
-
function
|
|
815
|
+
function $l(r) {
|
|
810
816
|
let t, e;
|
|
811
817
|
return {
|
|
812
818
|
c() {
|
|
@@ -823,18 +829,18 @@ function Jl(r) {
|
|
|
823
829
|
}
|
|
824
830
|
};
|
|
825
831
|
}
|
|
826
|
-
class
|
|
832
|
+
class tc extends qr {
|
|
827
833
|
constructor(t) {
|
|
828
|
-
super(), Ur(this, t, null,
|
|
834
|
+
super(), Ur(this, t, null, $l, zr, {});
|
|
829
835
|
}
|
|
830
836
|
}
|
|
831
837
|
function ha(r, t, e) {
|
|
832
838
|
const n = r.slice();
|
|
833
|
-
return n[
|
|
839
|
+
return n[74] = t[e], n[76] = e, n;
|
|
834
840
|
}
|
|
835
841
|
function ga(r) {
|
|
836
842
|
let t, e;
|
|
837
|
-
return t = new
|
|
843
|
+
return t = new Ql({}), {
|
|
838
844
|
c() {
|
|
839
845
|
Rr(t.$$.fragment);
|
|
840
846
|
},
|
|
@@ -854,7 +860,7 @@ function ga(r) {
|
|
|
854
860
|
}
|
|
855
861
|
function pa(r) {
|
|
856
862
|
let t, e, n, i, o;
|
|
857
|
-
return e = new
|
|
863
|
+
return e = new Jl({}), {
|
|
858
864
|
c() {
|
|
859
865
|
t = ht("button"), Rr(e.$$.fragment), P(t, "type", "button"), P(
|
|
860
866
|
t,
|
|
@@ -873,7 +879,7 @@ function pa(r) {
|
|
|
873
879
|
t,
|
|
874
880
|
"click",
|
|
875
881
|
/*click_handler_2*/
|
|
876
|
-
r[
|
|
882
|
+
r[60]
|
|
877
883
|
), i = !0);
|
|
878
884
|
},
|
|
879
885
|
p(s, a) {
|
|
@@ -902,16 +908,16 @@ function pa(r) {
|
|
|
902
908
|
}
|
|
903
909
|
};
|
|
904
910
|
}
|
|
905
|
-
function
|
|
911
|
+
function ec(r) {
|
|
906
912
|
let t, e = [], n = /* @__PURE__ */ new Map(), i, o, s, a = (
|
|
907
913
|
/*listFeatures*/
|
|
908
914
|
r[12]
|
|
909
915
|
);
|
|
910
916
|
const u = (l) => (
|
|
911
917
|
/*feature*/
|
|
912
|
-
l[
|
|
913
|
-
(l[
|
|
914
|
-
l[
|
|
918
|
+
l[74].id + /*feature*/
|
|
919
|
+
(l[74].address ? "," + /*feature*/
|
|
920
|
+
l[74].address : "")
|
|
915
921
|
);
|
|
916
922
|
for (let l = 0; l < a.length; l += 1) {
|
|
917
923
|
let c = ha(r, a, l), f = u(c);
|
|
@@ -933,20 +939,20 @@ function tc(r) {
|
|
|
933
939
|
t,
|
|
934
940
|
"mouseleave",
|
|
935
941
|
/*mouseleave_handler*/
|
|
936
|
-
r[
|
|
942
|
+
r[64]
|
|
937
943
|
),
|
|
938
944
|
Ce(
|
|
939
945
|
t,
|
|
940
946
|
"blur",
|
|
941
947
|
/*blur_handler_1*/
|
|
942
|
-
r[
|
|
948
|
+
r[65]
|
|
943
949
|
)
|
|
944
950
|
], o = !0);
|
|
945
951
|
},
|
|
946
952
|
p(l, c) {
|
|
947
|
-
c[0] & /*listFeatures, showPlaceType, selectedItemIndex, pick*/
|
|
948
|
-
|
|
949
|
-
l[12], Mo(), e =
|
|
953
|
+
c[0] & /*listFeatures, showPlaceType, selectedItemIndex, missingIconsCache, pick*/
|
|
954
|
+
4469760 && (a = /*listFeatures*/
|
|
955
|
+
l[12], Mo(), e = Al(e, c, u, 1, l, a, n, t, Ml, da, null, ha), Ao());
|
|
950
956
|
},
|
|
951
957
|
i(l) {
|
|
952
958
|
if (!i) {
|
|
@@ -968,7 +974,7 @@ function tc(r) {
|
|
|
968
974
|
}
|
|
969
975
|
};
|
|
970
976
|
}
|
|
971
|
-
function
|
|
977
|
+
function nc(r) {
|
|
972
978
|
let t, e, n, i, o, s;
|
|
973
979
|
return e = new iu({}), {
|
|
974
980
|
c() {
|
|
@@ -999,7 +1005,7 @@ function ec(r) {
|
|
|
999
1005
|
}
|
|
1000
1006
|
};
|
|
1001
1007
|
}
|
|
1002
|
-
function
|
|
1008
|
+
function rc(r) {
|
|
1003
1009
|
let t = "", e;
|
|
1004
1010
|
return {
|
|
1005
1011
|
c() {
|
|
@@ -1016,7 +1022,7 @@ function nc(r) {
|
|
|
1016
1022
|
}
|
|
1017
1023
|
};
|
|
1018
1024
|
}
|
|
1019
|
-
function
|
|
1025
|
+
function ic(r) {
|
|
1020
1026
|
let t, e, n, i, o, s, a, u, l, c, f;
|
|
1021
1027
|
return e = new iu({}), u = new ru({}), {
|
|
1022
1028
|
c() {
|
|
@@ -1030,7 +1036,7 @@ function rc(r) {
|
|
|
1030
1036
|
a,
|
|
1031
1037
|
"click",
|
|
1032
1038
|
/*click_handler_3*/
|
|
1033
|
-
r[
|
|
1039
|
+
r[61]
|
|
1034
1040
|
), c = !0);
|
|
1035
1041
|
},
|
|
1036
1042
|
p(h, g) {
|
|
@@ -1057,26 +1063,26 @@ function da(r, t) {
|
|
|
1057
1063
|
function o() {
|
|
1058
1064
|
return (
|
|
1059
1065
|
/*mouseenter_handler*/
|
|
1060
|
-
t[
|
|
1066
|
+
t[62](
|
|
1061
1067
|
/*i*/
|
|
1062
|
-
t[
|
|
1068
|
+
t[76]
|
|
1063
1069
|
)
|
|
1064
1070
|
);
|
|
1065
1071
|
}
|
|
1066
1072
|
function s() {
|
|
1067
1073
|
return (
|
|
1068
1074
|
/*focus_handler_1*/
|
|
1069
|
-
t[
|
|
1075
|
+
t[63](
|
|
1070
1076
|
/*feature*/
|
|
1071
|
-
t[
|
|
1077
|
+
t[74]
|
|
1072
1078
|
)
|
|
1073
1079
|
);
|
|
1074
1080
|
}
|
|
1075
|
-
return n = new
|
|
1081
|
+
return n = new jl({
|
|
1076
1082
|
props: {
|
|
1077
1083
|
feature: (
|
|
1078
1084
|
/*feature*/
|
|
1079
|
-
t[
|
|
1085
|
+
t[74]
|
|
1080
1086
|
),
|
|
1081
1087
|
showPlaceType: (
|
|
1082
1088
|
/*showPlaceType*/
|
|
@@ -1085,14 +1091,18 @@ function da(r, t) {
|
|
|
1085
1091
|
selected: (
|
|
1086
1092
|
/*selectedItemIndex*/
|
|
1087
1093
|
t[13] === /*i*/
|
|
1088
|
-
t[
|
|
1094
|
+
t[76]
|
|
1095
|
+
),
|
|
1096
|
+
missingIconsCache: (
|
|
1097
|
+
/*missingIconsCache*/
|
|
1098
|
+
t[18]
|
|
1089
1099
|
)
|
|
1090
1100
|
}
|
|
1091
1101
|
}), n.$on("mouseenter", o), n.$on("focus", s), {
|
|
1092
1102
|
key: r,
|
|
1093
1103
|
first: null,
|
|
1094
1104
|
c() {
|
|
1095
|
-
e =
|
|
1105
|
+
e = xl(), Rr(n.$$.fragment), this.first = e;
|
|
1096
1106
|
},
|
|
1097
1107
|
m(a, u) {
|
|
1098
1108
|
Dt(a, e, u), ur(n, a, u), i = !0;
|
|
@@ -1102,12 +1112,12 @@ function da(r, t) {
|
|
|
1102
1112
|
const l = {};
|
|
1103
1113
|
u[0] & /*listFeatures*/
|
|
1104
1114
|
4096 && (l.feature = /*feature*/
|
|
1105
|
-
t[
|
|
1115
|
+
t[74]), u[0] & /*showPlaceType*/
|
|
1106
1116
|
1024 && (l.showPlaceType = /*showPlaceType*/
|
|
1107
1117
|
t[10]), u[0] & /*selectedItemIndex, listFeatures*/
|
|
1108
1118
|
12288 && (l.selected = /*selectedItemIndex*/
|
|
1109
1119
|
t[13] === /*i*/
|
|
1110
|
-
t[
|
|
1120
|
+
t[76]), n.$set(l);
|
|
1111
1121
|
},
|
|
1112
1122
|
i(a) {
|
|
1113
1123
|
i || (Gt(n.$$.fragment, a), i = !0);
|
|
@@ -1120,26 +1130,26 @@ function da(r, t) {
|
|
|
1120
1130
|
}
|
|
1121
1131
|
};
|
|
1122
1132
|
}
|
|
1123
|
-
function
|
|
1124
|
-
let t, e, n, i, o, s, a, u, l, c, f, h, g, p,
|
|
1125
|
-
i = new
|
|
1133
|
+
function oc(r) {
|
|
1134
|
+
let t, e, n, i, o, s, a, u, l, c, f, h, g, p, y, m, d, E, C, S;
|
|
1135
|
+
i = new tc({}), c = new ru({});
|
|
1126
1136
|
let N = (
|
|
1127
1137
|
/*abortController*/
|
|
1128
1138
|
r[17] && ga()
|
|
1129
|
-
),
|
|
1139
|
+
), w = (
|
|
1130
1140
|
/*enableReverse*/
|
|
1131
1141
|
r[5] === !0 && pa(r)
|
|
1132
1142
|
);
|
|
1133
1143
|
const T = (
|
|
1134
1144
|
/*#slots*/
|
|
1135
|
-
r[
|
|
1136
|
-
), A =
|
|
1145
|
+
r[52].default
|
|
1146
|
+
), A = El(
|
|
1137
1147
|
T,
|
|
1138
1148
|
r,
|
|
1139
1149
|
/*$$scope*/
|
|
1140
|
-
r[
|
|
1150
|
+
r[51],
|
|
1141
1151
|
null
|
|
1142
|
-
), L = [rc, nc, ec
|
|
1152
|
+
), L = [ic, rc, nc, ec], F = [];
|
|
1143
1153
|
function X(R, Y) {
|
|
1144
1154
|
var D, W;
|
|
1145
1155
|
return (
|
|
@@ -1157,9 +1167,9 @@ function ic(r) {
|
|
|
1157
1167
|
)
|
|
1158
1168
|
);
|
|
1159
1169
|
}
|
|
1160
|
-
return ~(
|
|
1170
|
+
return ~(y = X(r)) && (m = F[y] = L[y](r)), {
|
|
1161
1171
|
c() {
|
|
1162
|
-
t = ht("form"), e = ht("div"), n = ht("button"), Rr(i.$$.fragment), o = nn(), s = ht("input"), a = nn(), u = ht("div"), l = ht("button"), Rr(c.$$.fragment), f = nn(), N && N.c(), h = nn(),
|
|
1172
|
+
t = ht("form"), e = ht("div"), n = ht("button"), Rr(i.$$.fragment), o = nn(), s = ht("input"), a = nn(), u = ht("div"), l = ht("button"), Rr(c.$$.fragment), f = nn(), N && N.c(), h = nn(), w && w.c(), g = nn(), A && A.c(), p = nn(), m && m.c(), P(n, "class", "search-button svelte-1r7dvt7"), P(n, "type", "button"), P(
|
|
1163
1173
|
s,
|
|
1164
1174
|
"placeholder",
|
|
1165
1175
|
/*placeholder*/
|
|
@@ -1179,7 +1189,7 @@ function ic(r) {
|
|
|
1179
1189
|
"displayable",
|
|
1180
1190
|
/*searchValue*/
|
|
1181
1191
|
r[1] !== ""
|
|
1182
|
-
), P(e, "class", "input-group svelte-1r7dvt7"), P(t, "tabindex", "0"), P(t, "class",
|
|
1192
|
+
), P(e, "class", "input-group svelte-1r7dvt7"), P(t, "tabindex", "0"), P(t, "class", d = aa(
|
|
1183
1193
|
/*className*/
|
|
1184
1194
|
r[2]
|
|
1185
1195
|
) + " svelte-1r7dvt7"), on(
|
|
@@ -1191,56 +1201,56 @@ function ic(r) {
|
|
|
1191
1201
|
);
|
|
1192
1202
|
},
|
|
1193
1203
|
m(R, Y) {
|
|
1194
|
-
Dt(R, t, Y), nt(t, e), nt(e, n), ur(i, n, null), nt(e, o), nt(e, s), r[
|
|
1204
|
+
Dt(R, t, Y), nt(t, e), nt(e, n), ur(i, n, null), nt(e, o), nt(e, s), r[54](s), ua(
|
|
1195
1205
|
s,
|
|
1196
1206
|
/*searchValue*/
|
|
1197
1207
|
r[1]
|
|
1198
|
-
), nt(e, a), nt(e, u), nt(u, l), ur(c, l, null), nt(u, f), N && N.m(u, null), nt(e, h),
|
|
1208
|
+
), nt(e, a), nt(e, u), nt(u, l), ur(c, l, null), nt(u, f), N && N.m(u, null), nt(e, h), w && w.m(e, null), nt(e, g), A && A.m(e, null), nt(t, p), ~y && F[y].m(t, null), E = !0, C || (S = [
|
|
1199
1209
|
Ce(
|
|
1200
1210
|
n,
|
|
1201
1211
|
"click",
|
|
1202
1212
|
/*click_handler*/
|
|
1203
|
-
r[
|
|
1213
|
+
r[53]
|
|
1204
1214
|
),
|
|
1205
1215
|
Ce(
|
|
1206
1216
|
s,
|
|
1207
1217
|
"input",
|
|
1208
1218
|
/*input_1_input_handler*/
|
|
1209
|
-
r[
|
|
1219
|
+
r[55]
|
|
1210
1220
|
),
|
|
1211
1221
|
Ce(
|
|
1212
1222
|
s,
|
|
1213
1223
|
"focus",
|
|
1214
1224
|
/*focus_handler*/
|
|
1215
|
-
r[
|
|
1225
|
+
r[56]
|
|
1216
1226
|
),
|
|
1217
1227
|
Ce(
|
|
1218
1228
|
s,
|
|
1219
1229
|
"blur",
|
|
1220
1230
|
/*blur_handler*/
|
|
1221
|
-
r[
|
|
1231
|
+
r[57]
|
|
1222
1232
|
),
|
|
1223
1233
|
Ce(
|
|
1224
1234
|
s,
|
|
1225
1235
|
"keydown",
|
|
1226
1236
|
/*handleKeyDown*/
|
|
1227
|
-
r[
|
|
1237
|
+
r[20]
|
|
1228
1238
|
),
|
|
1229
1239
|
Ce(
|
|
1230
1240
|
s,
|
|
1231
1241
|
"input",
|
|
1232
1242
|
/*input_handler*/
|
|
1233
|
-
r[
|
|
1243
|
+
r[58]
|
|
1234
1244
|
),
|
|
1235
1245
|
Ce(
|
|
1236
1246
|
l,
|
|
1237
1247
|
"click",
|
|
1238
1248
|
/*click_handler_1*/
|
|
1239
|
-
r[
|
|
1249
|
+
r[59]
|
|
1240
1250
|
),
|
|
1241
|
-
Ce(t, "submit",
|
|
1251
|
+
Ce(t, "submit", Sl(
|
|
1242
1252
|
/*handleOnSubmit*/
|
|
1243
|
-
r[
|
|
1253
|
+
r[19]
|
|
1244
1254
|
))
|
|
1245
1255
|
], C = !0);
|
|
1246
1256
|
},
|
|
@@ -1280,36 +1290,36 @@ function ic(r) {
|
|
|
1280
1290
|
/*searchValue*/
|
|
1281
1291
|
R[1] !== ""
|
|
1282
1292
|
), /*enableReverse*/
|
|
1283
|
-
R[5] === !0 ?
|
|
1284
|
-
32 && Gt(
|
|
1285
|
-
|
|
1293
|
+
R[5] === !0 ? w ? (w.p(R, Y), Y[0] & /*enableReverse*/
|
|
1294
|
+
32 && Gt(w, 1)) : (w = pa(R), w.c(), Gt(w, 1), w.m(e, g)) : w && (Mo(), le(w, 1, 1, () => {
|
|
1295
|
+
w = null;
|
|
1286
1296
|
}), Ao()), A && A.p && (!E || Y[1] & /*$$scope*/
|
|
1287
|
-
|
|
1297
|
+
1048576) && Cl(
|
|
1288
1298
|
A,
|
|
1289
1299
|
T,
|
|
1290
1300
|
R,
|
|
1291
1301
|
/*$$scope*/
|
|
1292
|
-
R[
|
|
1293
|
-
E ?
|
|
1302
|
+
R[51],
|
|
1303
|
+
E ? Il(
|
|
1294
1304
|
T,
|
|
1295
1305
|
/*$$scope*/
|
|
1296
|
-
R[
|
|
1306
|
+
R[51],
|
|
1297
1307
|
Y,
|
|
1298
1308
|
null
|
|
1299
|
-
) :
|
|
1309
|
+
) : Nl(
|
|
1300
1310
|
/*$$scope*/
|
|
1301
|
-
R[
|
|
1311
|
+
R[51]
|
|
1302
1312
|
),
|
|
1303
1313
|
null
|
|
1304
1314
|
);
|
|
1305
|
-
let D =
|
|
1306
|
-
|
|
1315
|
+
let D = y;
|
|
1316
|
+
y = X(R), y === D ? ~y && F[y].p(R, Y) : (m && (Mo(), le(F[D], 1, 1, () => {
|
|
1307
1317
|
F[D] = null;
|
|
1308
|
-
}), Ao()), ~
|
|
1309
|
-
4 &&
|
|
1318
|
+
}), Ao()), ~y ? (m = F[y], m ? m.p(R, Y) : (m = F[y] = L[y](R), m.c()), Gt(m, 1), m.m(t, null)) : m = null), (!E || Y[0] & /*className*/
|
|
1319
|
+
4 && d !== (d = aa(
|
|
1310
1320
|
/*className*/
|
|
1311
1321
|
R[2]
|
|
1312
|
-
) + " svelte-1r7dvt7")) && P(t, "class",
|
|
1322
|
+
) + " svelte-1r7dvt7")) && P(t, "class", d), (!E || Y[0] & /*className, collapsed, searchValue*/
|
|
1313
1323
|
22) && on(
|
|
1314
1324
|
t,
|
|
1315
1325
|
"can-collapse",
|
|
@@ -1319,17 +1329,17 @@ function ic(r) {
|
|
|
1319
1329
|
);
|
|
1320
1330
|
},
|
|
1321
1331
|
i(R) {
|
|
1322
|
-
E || (Gt(i.$$.fragment, R), Gt(c.$$.fragment, R), Gt(N), Gt(
|
|
1332
|
+
E || (Gt(i.$$.fragment, R), Gt(c.$$.fragment, R), Gt(N), Gt(w), Gt(A, R), Gt(m), E = !0);
|
|
1323
1333
|
},
|
|
1324
1334
|
o(R) {
|
|
1325
|
-
le(i.$$.fragment, R), le(c.$$.fragment, R), le(N), le(
|
|
1335
|
+
le(i.$$.fragment, R), le(c.$$.fragment, R), le(N), le(w), le(A, R), le(m), E = !1;
|
|
1326
1336
|
},
|
|
1327
1337
|
d(R) {
|
|
1328
|
-
R && Tt(t), lr(i), r[
|
|
1338
|
+
R && Tt(t), lr(i), r[54](null), lr(c), N && N.d(), w && w.d(), A && A.d(R), ~y && F[y].d(), C = !1, _r(S);
|
|
1329
1339
|
}
|
|
1330
1340
|
};
|
|
1331
1341
|
}
|
|
1332
|
-
function
|
|
1342
|
+
function sc(r, t, e) {
|
|
1333
1343
|
const n = t[1], i = t[0], o = n - i;
|
|
1334
1344
|
return r === n && e ? r : ((r - i) % o + o) % o + i;
|
|
1335
1345
|
}
|
|
@@ -1337,8 +1347,8 @@ function va(r) {
|
|
|
1337
1347
|
let t = [...r];
|
|
1338
1348
|
return t[2] < t[0] && (t[2] += 360), t;
|
|
1339
1349
|
}
|
|
1340
|
-
function
|
|
1341
|
-
let n, { $$slots: i = {}, $$scope: o } = t, { class: s = void 0 } = t, { apiKey: a } = t, { bbox: u = void 0 } = t, { clearButtonTitle: l = "clear" } = t, { clearOnBlur: c = !1 } = t, { collapsed: f = !1 } = t, { country: h = void 0 } = t, { debounceSearch: g = 200 } = t, { enableReverse: p = !1 } = t, { errorMessage:
|
|
1350
|
+
function ac(r, t, e) {
|
|
1351
|
+
let n, { $$slots: i = {}, $$scope: o } = t, { class: s = void 0 } = t, { apiKey: a } = t, { bbox: u = void 0 } = t, { clearButtonTitle: l = "clear" } = t, { clearOnBlur: c = !1 } = t, { collapsed: f = !1 } = t, { country: h = void 0 } = t, { debounceSearch: g = 200 } = t, { enableReverse: p = !1 } = t, { errorMessage: y = "Something went wrong…" } = t, { filter: m = () => !0 } = t, { flyTo: d = !0 } = t, { fuzzyMatch: E = !0 } = t, { language: C = void 0 } = t, { limit: S = void 0 } = t, { mapController: N = void 0 } = t, { minLength: w = 2 } = t, { noResultsMessage: T = "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!" } = t, { placeholder: A = "Search" } = t, { proximity: L = void 0 } = t, { reverseActive: F = p === "always" } = t, { reverseButtonTitle: X = "toggle reverse geocoding" } = t, { searchValue: R = "" } = t, { showFullGeometry: Y = !0 } = t, { showPlaceType: D = "ifNeeded" } = t, { showResultsWhileTyping: W = !0 } = t, { trackProximity: ut = !0 } = t, { types: dt = void 0 } = t, { zoom: Ht = 16 } = t, { maxZoom: Jt = 18 } = t, { apiUrl: rr = "https://api.maptiler.com/geocoding" } = t, { fetchParameters: Ge = {} } = t;
|
|
1342
1352
|
function ir() {
|
|
1343
1353
|
kn.focus();
|
|
1344
1354
|
}
|
|
@@ -1351,17 +1361,17 @@ function sc(r, t, e) {
|
|
|
1351
1361
|
}));
|
|
1352
1362
|
}
|
|
1353
1363
|
let Ve = !1, ct, _e, ot, na = "", kn, kt = -1, Bn, xo = [], Hr, di, So, cs;
|
|
1354
|
-
const Er =
|
|
1355
|
-
|
|
1364
|
+
const tl = /* @__PURE__ */ new Set(), Er = Pl();
|
|
1365
|
+
bl(() => {
|
|
1356
1366
|
N && (N.setEventHandler(void 0), N.indicateReverse(!1), N.setSelectedMarker(-1), N.setMarkers(void 0, void 0));
|
|
1357
1367
|
});
|
|
1358
1368
|
function ra(x) {
|
|
1359
1369
|
if (di && (clearTimeout(di), di = void 0), kt > -1 && ct)
|
|
1360
|
-
e(
|
|
1370
|
+
e(48, ot = ct[kt]), e(1, R = ot.place_name.replace(/,.*/, "")), e(16, Bn = void 0), e(47, _e = void 0), e(13, kt = -1);
|
|
1361
1371
|
else if (R) {
|
|
1362
1372
|
const Bt = x || !ia();
|
|
1363
1373
|
fs(R, { exact: !0 }).then(() => {
|
|
1364
|
-
e(
|
|
1374
|
+
e(47, _e = ct), e(48, ot = void 0), Bt && el();
|
|
1365
1375
|
}).catch((Gn) => e(16, Bn = Gn));
|
|
1366
1376
|
}
|
|
1367
1377
|
}
|
|
@@ -1371,10 +1381,10 @@ function sc(r, t, e) {
|
|
|
1371
1381
|
async function fs(x, { byId: Bt = !1, exact: Gn = !1 } = {}) {
|
|
1372
1382
|
e(16, Bn = void 0);
|
|
1373
1383
|
const vi = ia(), ze = new URLSearchParams();
|
|
1374
|
-
C != null && ze.set("language", Array.isArray(C) ? C.join(",") : C), dt && ze.set("types", dt.join(",")), vi || (u && ze.set("bbox", u.map((Ir) => Ir.toFixed(6)).join(",")), h && ze.set("country", Array.isArray(h) ? h.join(",") : h)), Bt || (L && ze.set("proximity", L.map((Ir) => Ir.toFixed(6)).join(",")), (Gn || !W) && ze.set("autocomplete", "false"), ze.set("fuzzyMatch", String(E))),
|
|
1384
|
+
C != null && ze.set("language", Array.isArray(C) ? C.join(",") : C), dt && ze.set("types", dt.join(",")), vi || (u && ze.set("bbox", u.map((Ir) => Ir.toFixed(6)).join(",")), h && ze.set("country", Array.isArray(h) ? h.join(",") : h)), Bt || (L && ze.set("proximity", L.map((Ir) => Ir.toFixed(6)).join(",")), (Gn || !W) && ze.set("autocomplete", "false"), ze.set("fuzzyMatch", String(E))), S !== void 0 && (!vi || (dt == null ? void 0 : dt.length) === 1) && ze.set("limit", String(S)), ze.set("key", a);
|
|
1375
1385
|
const jr = rr + "/" + encodeURIComponent(x) + ".json?" + ze.toString();
|
|
1376
1386
|
if (jr === na) {
|
|
1377
|
-
Bt ? (e(12, ct = void 0), e(
|
|
1387
|
+
Bt ? (e(12, ct = void 0), e(48, ot = xo[0])) : e(12, ct = xo);
|
|
1378
1388
|
return;
|
|
1379
1389
|
}
|
|
1380
1390
|
na = jr, Hr == null || Hr.abort();
|
|
@@ -1393,21 +1403,21 @@ function sc(r, t, e) {
|
|
|
1393
1403
|
if (!ps.ok)
|
|
1394
1404
|
throw new Error();
|
|
1395
1405
|
const ds = await ps.json();
|
|
1396
|
-
Er("response", { url: jr, featureCollection: ds }), Bt ? (e(12, ct = void 0), e(
|
|
1406
|
+
Er("response", { url: jr, featureCollection: ds }), Bt ? (e(12, ct = void 0), e(48, ot = ds.features[0]), xo = [ot]) : (e(12, ct = ds.features.filter(m)), xo = ct, vi && kn.focus());
|
|
1397
1407
|
}
|
|
1398
|
-
function
|
|
1408
|
+
function el() {
|
|
1399
1409
|
var Gn, vi, ze, jr;
|
|
1400
|
-
if (!(_e != null && _e.length) || !
|
|
1410
|
+
if (!(_e != null && _e.length) || !d)
|
|
1401
1411
|
return;
|
|
1402
1412
|
const x = [180, 90, -180, -90], Bt = !_e.some((Ee) => !Ee.matching_text);
|
|
1403
1413
|
for (const Ee of _e)
|
|
1404
1414
|
(Bt || !Ee.matching_text) && (x[0] = Math.min(x[0], ((Gn = Ee.bbox) == null ? void 0 : Gn[0]) ?? Ee.center[0]), x[1] = Math.min(x[1], ((vi = Ee.bbox) == null ? void 0 : vi[1]) ?? Ee.center[1]), x[2] = Math.max(x[2], ((ze = Ee.bbox) == null ? void 0 : ze[2]) ?? Ee.center[0]), x[3] = Math.max(x[3], ((jr = Ee.bbox) == null ? void 0 : jr[3]) ?? Ee.center[1]));
|
|
1405
1415
|
N && _e.length > 0 && (ot && x[0] === x[2] && x[1] === x[3] ? N.flyTo(ot.center, Ht) : N.fitBounds(va(x), 50, Jt));
|
|
1406
1416
|
}
|
|
1407
|
-
function el(x) {
|
|
1408
|
-
e(0, F = p === "always"), Wr(oc(x[0], [-180, 180], !0).toFixed(6) + "," + x[1].toFixed(6));
|
|
1409
|
-
}
|
|
1410
1417
|
function nl(x) {
|
|
1418
|
+
e(0, F = p === "always"), Wr(sc(x[0], [-180, 180], !0).toFixed(6) + "," + x[1].toFixed(6));
|
|
1419
|
+
}
|
|
1420
|
+
function rl(x) {
|
|
1411
1421
|
if (!ct)
|
|
1412
1422
|
return;
|
|
1413
1423
|
let Bt = x.key === "ArrowDown" ? 1 : x.key === "ArrowUp" ? -1 : 0;
|
|
@@ -1415,7 +1425,7 @@ function sc(r, t, e) {
|
|
|
1415
1425
|
}
|
|
1416
1426
|
function hs(x = !0) {
|
|
1417
1427
|
if (e(16, Bn = void 0), W) {
|
|
1418
|
-
if (di && clearTimeout(di), R.length <
|
|
1428
|
+
if (di && clearTimeout(di), R.length < w)
|
|
1419
1429
|
return;
|
|
1420
1430
|
const Bt = R;
|
|
1421
1431
|
di = window.setTimeout(
|
|
@@ -1428,46 +1438,46 @@ function sc(r, t, e) {
|
|
|
1428
1438
|
e(12, ct = void 0), e(16, Bn = void 0);
|
|
1429
1439
|
}
|
|
1430
1440
|
function gs(x) {
|
|
1431
|
-
e(
|
|
1441
|
+
e(48, ot = x), e(1, R = x.place_name), e(13, kt = -1);
|
|
1432
1442
|
}
|
|
1433
|
-
const
|
|
1434
|
-
function
|
|
1443
|
+
const il = () => kn.focus();
|
|
1444
|
+
function ol(x) {
|
|
1435
1445
|
Cs[x ? "unshift" : "push"](() => {
|
|
1436
1446
|
kn = x, e(15, kn);
|
|
1437
1447
|
});
|
|
1438
1448
|
}
|
|
1439
|
-
function
|
|
1440
|
-
R = this.value, e(1, R), e(11, Ve), e(
|
|
1449
|
+
function sl() {
|
|
1450
|
+
R = this.value, e(1, R), e(11, Ve), e(26, c);
|
|
1441
1451
|
}
|
|
1442
|
-
const
|
|
1452
|
+
const al = () => e(11, Ve = !0), ul = () => e(11, Ve = !1), ll = () => hs(), cl = () => {
|
|
1443
1453
|
e(1, R = ""), kn.focus();
|
|
1444
|
-
},
|
|
1454
|
+
}, fl = () => e(0, F = !F), hl = () => e(16, Bn = void 0), gl = (x) => e(13, kt = x), pl = (x) => gs(x), dl = () => e(13, kt = -1), vl = () => {
|
|
1445
1455
|
};
|
|
1446
1456
|
return r.$$set = (x) => {
|
|
1447
|
-
"class" in x && e(2, s = x.class), "apiKey" in x && e(
|
|
1457
|
+
"class" in x && e(2, s = x.class), "apiKey" in x && e(24, a = x.apiKey), "bbox" in x && e(25, u = x.bbox), "clearButtonTitle" in x && e(3, l = x.clearButtonTitle), "clearOnBlur" in x && e(26, c = x.clearOnBlur), "collapsed" in x && e(4, f = x.collapsed), "country" in x && e(27, h = x.country), "debounceSearch" in x && e(28, g = x.debounceSearch), "enableReverse" in x && e(5, p = x.enableReverse), "errorMessage" in x && e(6, y = x.errorMessage), "filter" in x && e(29, m = x.filter), "flyTo" in x && e(30, d = x.flyTo), "fuzzyMatch" in x && e(31, E = x.fuzzyMatch), "language" in x && e(32, C = x.language), "limit" in x && e(33, S = x.limit), "mapController" in x && e(34, N = x.mapController), "minLength" in x && e(35, w = x.minLength), "noResultsMessage" in x && e(7, T = x.noResultsMessage), "placeholder" in x && e(8, A = x.placeholder), "proximity" in x && e(23, L = x.proximity), "reverseActive" in x && e(0, F = x.reverseActive), "reverseButtonTitle" in x && e(9, X = x.reverseButtonTitle), "searchValue" in x && e(1, R = x.searchValue), "showFullGeometry" in x && e(36, Y = x.showFullGeometry), "showPlaceType" in x && e(10, D = x.showPlaceType), "showResultsWhileTyping" in x && e(37, W = x.showResultsWhileTyping), "trackProximity" in x && e(38, ut = x.trackProximity), "types" in x && e(39, dt = x.types), "zoom" in x && e(40, Ht = x.zoom), "maxZoom" in x && e(41, Jt = x.maxZoom), "apiUrl" in x && e(42, rr = x.apiUrl), "fetchParameters" in x && e(43, Ge = x.fetchParameters), "$$scope" in x && e(51, o = x.$$scope);
|
|
1448
1458
|
}, r.$$.update = () => {
|
|
1449
1459
|
if (r.$$.dirty[1] & /*trackProximity*/
|
|
1450
|
-
|
|
1451
|
-
|
|
1460
|
+
128 && (ut || e(23, L = void 0)), r.$$.dirty[0] & /*focused, clearOnBlur*/
|
|
1461
|
+
67110912 && setTimeout(() => {
|
|
1452
1462
|
e(14, So = Ve), c && !Ve && e(1, R = "");
|
|
1453
1463
|
}), r.$$.dirty[0] & /*searchValue, listFeatures*/
|
|
1454
1464
|
4098 | r.$$.dirty[1] & /*minLength*/
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1465
|
+
16 && R.length < w && (e(48, ot = void 0), e(12, ct = void 0), e(16, Bn = void 0), e(47, _e = ct)), r.$$.dirty[1] & /*showFullGeometry, picked*/
|
|
1466
|
+
131104 && Y && ot && !ot.address && ot.geometry.type === "Point" && fs(ot.id, { byId: !0 }).catch((x) => e(16, Bn = x)), r.$$.dirty[0] & /*flyTo*/
|
|
1467
|
+
1073741824 | r.$$.dirty[1] & /*mapController, picked, prevIdToFly, maxZoom, zoom*/
|
|
1468
|
+
394760 && (N && ot && ot.id !== cs && d && (!ot.bbox || ot.bbox[0] === ot.bbox[2] && ot.bbox[1] === ot.bbox[3] ? N.flyTo(ot.center, ot.id.startsWith("poi.") || ot.id.startsWith("address.") ? Jt : Ht) : N.fitBounds(va(ot.bbox), 50, Jt), e(12, ct = void 0), e(47, _e = void 0), e(13, kt = -1)), e(49, cs = ot == null ? void 0 : ot.id)), r.$$.dirty[0] & /*listFeatures*/
|
|
1459
1469
|
4096 | r.$$.dirty[1] & /*markedFeatures*/
|
|
1460
|
-
|
|
1461
|
-
|
|
1470
|
+
65536 && _e !== ct && e(47, _e = void 0), r.$$.dirty[1] & /*mapController, markedFeatures, picked*/
|
|
1471
|
+
196616 && N && N.setMarkers(_e, ot), r.$$.dirty[0] & /*searchValue*/
|
|
1462
1472
|
2 && e(13, kt = -1), r.$$.dirty[0] & /*reverseActive, listFeatures, focusedDelayed*/
|
|
1463
1473
|
20481 | r.$$.dirty[1] & /*mapController, trackProximity*/
|
|
1464
|
-
|
|
1474
|
+
136 && N && N.setEventHandler((x) => {
|
|
1465
1475
|
switch (x.type) {
|
|
1466
1476
|
case "mapClick":
|
|
1467
|
-
F &&
|
|
1477
|
+
F && nl(x.coordinates);
|
|
1468
1478
|
break;
|
|
1469
1479
|
case "proximityChange":
|
|
1470
|
-
e(
|
|
1480
|
+
e(23, L = ut ? x.proximity : void 0);
|
|
1471
1481
|
break;
|
|
1472
1482
|
case "markerClick":
|
|
1473
1483
|
{
|
|
@@ -1484,23 +1494,23 @@ function sc(r, t, e) {
|
|
|
1484
1494
|
}
|
|
1485
1495
|
}), r.$$.dirty[0] & /*selectedItemIndex*/
|
|
1486
1496
|
8192 | r.$$.dirty[1] & /*mapController*/
|
|
1487
|
-
|
|
1488
|
-
12288 && e(
|
|
1497
|
+
8 && (N == null || N.setSelectedMarker(kt)), r.$$.dirty[0] & /*listFeatures, selectedItemIndex*/
|
|
1498
|
+
12288 && e(50, n = ct == null ? void 0 : ct[kt]), r.$$.dirty[0] & /*searchValue*/
|
|
1489
1499
|
2 | r.$$.dirty[1] & /*mapController*/
|
|
1490
|
-
|
|
1500
|
+
8) {
|
|
1491
1501
|
const x = /^(-?\d+(?:\.\d*)?),(-?\d+(?:\.\d*)?)$/.exec(R);
|
|
1492
1502
|
N == null || N.setReverseMarker(x ? [Number(x[1]), Number(x[2])] : void 0);
|
|
1493
1503
|
}
|
|
1494
1504
|
r.$$.dirty[1] & /*selected*/
|
|
1495
|
-
|
|
1496
|
-
|
|
1505
|
+
524288 && Er("select", n), r.$$.dirty[1] & /*picked*/
|
|
1506
|
+
131072 && Er("pick", ot), r.$$.dirty[0] & /*focusedDelayed, listFeatures*/
|
|
1497
1507
|
20480 && Er("optionsVisibilityChange", So && !!ct), r.$$.dirty[0] & /*listFeatures*/
|
|
1498
1508
|
4096 && Er("featuresListed", ct), r.$$.dirty[1] & /*markedFeatures*/
|
|
1499
|
-
|
|
1509
|
+
65536 && Er("featuresMarked", _e), r.$$.dirty[0] & /*reverseActive*/
|
|
1500
1510
|
1 && Er("reverseToggle", F), r.$$.dirty[0] & /*searchValue*/
|
|
1501
1511
|
2 && Er("queryChange", R), r.$$.dirty[0] & /*reverseActive*/
|
|
1502
1512
|
1 | r.$$.dirty[1] & /*mapController*/
|
|
1503
|
-
|
|
1513
|
+
8 && N && N.indicateReverse(F);
|
|
1504
1514
|
}, [
|
|
1505
1515
|
F,
|
|
1506
1516
|
R,
|
|
@@ -1508,7 +1518,7 @@ function sc(r, t, e) {
|
|
|
1508
1518
|
l,
|
|
1509
1519
|
f,
|
|
1510
1520
|
p,
|
|
1511
|
-
|
|
1521
|
+
y,
|
|
1512
1522
|
T,
|
|
1513
1523
|
A,
|
|
1514
1524
|
X,
|
|
@@ -1520,8 +1530,9 @@ function sc(r, t, e) {
|
|
|
1520
1530
|
kn,
|
|
1521
1531
|
Bn,
|
|
1522
1532
|
Hr,
|
|
1533
|
+
tl,
|
|
1523
1534
|
ra,
|
|
1524
|
-
|
|
1535
|
+
rl,
|
|
1525
1536
|
hs,
|
|
1526
1537
|
gs,
|
|
1527
1538
|
L,
|
|
@@ -1530,13 +1541,13 @@ function sc(r, t, e) {
|
|
|
1530
1541
|
c,
|
|
1531
1542
|
h,
|
|
1532
1543
|
g,
|
|
1533
|
-
d,
|
|
1534
1544
|
m,
|
|
1545
|
+
d,
|
|
1535
1546
|
E,
|
|
1536
1547
|
C,
|
|
1537
|
-
w,
|
|
1538
|
-
N,
|
|
1539
1548
|
S,
|
|
1549
|
+
N,
|
|
1550
|
+
w,
|
|
1540
1551
|
Y,
|
|
1541
1552
|
W,
|
|
1542
1553
|
ut,
|
|
@@ -1554,7 +1565,6 @@ function sc(r, t, e) {
|
|
|
1554
1565
|
n,
|
|
1555
1566
|
o,
|
|
1556
1567
|
i,
|
|
1557
|
-
rl,
|
|
1558
1568
|
il,
|
|
1559
1569
|
ol,
|
|
1560
1570
|
sl,
|
|
@@ -1566,66 +1576,67 @@ function sc(r, t, e) {
|
|
|
1566
1576
|
hl,
|
|
1567
1577
|
gl,
|
|
1568
1578
|
pl,
|
|
1569
|
-
dl
|
|
1579
|
+
dl,
|
|
1580
|
+
vl
|
|
1570
1581
|
];
|
|
1571
1582
|
}
|
|
1572
|
-
let
|
|
1583
|
+
let uc = class extends qr {
|
|
1573
1584
|
constructor(t) {
|
|
1574
1585
|
super(), Ur(
|
|
1575
1586
|
this,
|
|
1576
1587
|
t,
|
|
1577
|
-
|
|
1578
|
-
|
|
1588
|
+
ac,
|
|
1589
|
+
oc,
|
|
1579
1590
|
zr,
|
|
1580
1591
|
{
|
|
1581
1592
|
class: 2,
|
|
1582
|
-
apiKey:
|
|
1583
|
-
bbox:
|
|
1593
|
+
apiKey: 24,
|
|
1594
|
+
bbox: 25,
|
|
1584
1595
|
clearButtonTitle: 3,
|
|
1585
|
-
clearOnBlur:
|
|
1596
|
+
clearOnBlur: 26,
|
|
1586
1597
|
collapsed: 4,
|
|
1587
|
-
country:
|
|
1588
|
-
debounceSearch:
|
|
1598
|
+
country: 27,
|
|
1599
|
+
debounceSearch: 28,
|
|
1589
1600
|
enableReverse: 5,
|
|
1590
1601
|
errorMessage: 6,
|
|
1591
|
-
filter:
|
|
1592
|
-
flyTo:
|
|
1593
|
-
fuzzyMatch:
|
|
1594
|
-
language:
|
|
1595
|
-
limit:
|
|
1596
|
-
mapController:
|
|
1597
|
-
minLength:
|
|
1602
|
+
filter: 29,
|
|
1603
|
+
flyTo: 30,
|
|
1604
|
+
fuzzyMatch: 31,
|
|
1605
|
+
language: 32,
|
|
1606
|
+
limit: 33,
|
|
1607
|
+
mapController: 34,
|
|
1608
|
+
minLength: 35,
|
|
1598
1609
|
noResultsMessage: 7,
|
|
1599
1610
|
placeholder: 8,
|
|
1600
|
-
proximity:
|
|
1611
|
+
proximity: 23,
|
|
1601
1612
|
reverseActive: 0,
|
|
1602
1613
|
reverseButtonTitle: 9,
|
|
1603
1614
|
searchValue: 1,
|
|
1604
|
-
showFullGeometry:
|
|
1615
|
+
showFullGeometry: 36,
|
|
1605
1616
|
showPlaceType: 10,
|
|
1606
|
-
showResultsWhileTyping:
|
|
1607
|
-
trackProximity:
|
|
1608
|
-
types:
|
|
1609
|
-
zoom:
|
|
1610
|
-
maxZoom:
|
|
1611
|
-
apiUrl:
|
|
1612
|
-
fetchParameters:
|
|
1613
|
-
focus:
|
|
1614
|
-
blur:
|
|
1615
|
-
setQuery:
|
|
1617
|
+
showResultsWhileTyping: 37,
|
|
1618
|
+
trackProximity: 38,
|
|
1619
|
+
types: 39,
|
|
1620
|
+
zoom: 40,
|
|
1621
|
+
maxZoom: 41,
|
|
1622
|
+
apiUrl: 42,
|
|
1623
|
+
fetchParameters: 43,
|
|
1624
|
+
focus: 44,
|
|
1625
|
+
blur: 45,
|
|
1626
|
+
setQuery: 46
|
|
1616
1627
|
},
|
|
1617
1628
|
null,
|
|
1618
1629
|
[-1, -1, -1]
|
|
1619
1630
|
);
|
|
1620
1631
|
}
|
|
1621
1632
|
get focus() {
|
|
1622
|
-
return this.$$.ctx[
|
|
1633
|
+
return this.$$.ctx[44];
|
|
1623
1634
|
}
|
|
1624
1635
|
get blur() {
|
|
1625
|
-
return this.$$.ctx[
|
|
1636
|
+
return this.$$.ctx[45];
|
|
1626
1637
|
}
|
|
1627
1638
|
get setQuery() {
|
|
1628
|
-
return this.$$.ctx[
|
|
1639
|
+
return this.$$.ctx[46];
|
|
1629
1640
|
}
|
|
1630
1641
|
};
|
|
1631
1642
|
/**
|
|
@@ -1650,7 +1661,7 @@ MERCHANTABLITY OR NON-INFRINGEMENT.
|
|
|
1650
1661
|
See the Apache Version 2.0 License for specific language governing permissions
|
|
1651
1662
|
and limitations under the License.
|
|
1652
1663
|
***************************************************************************** */
|
|
1653
|
-
function
|
|
1664
|
+
function lc(r, t) {
|
|
1654
1665
|
var e = { label: 0, sent: function() {
|
|
1655
1666
|
if (o[0] & 1)
|
|
1656
1667
|
throw o[1];
|
|
@@ -1724,7 +1735,7 @@ var Or = (
|
|
|
1724
1735
|
return r;
|
|
1725
1736
|
}()
|
|
1726
1737
|
);
|
|
1727
|
-
function
|
|
1738
|
+
function cc(r, t) {
|
|
1728
1739
|
return r > t ? 1 : r < t ? -1 : 0;
|
|
1729
1740
|
}
|
|
1730
1741
|
function xr(r, t, e) {
|
|
@@ -1770,7 +1781,7 @@ function ya(r, t, e) {
|
|
|
1770
1781
|
}
|
|
1771
1782
|
return { left: n, right: i };
|
|
1772
1783
|
}
|
|
1773
|
-
function
|
|
1784
|
+
function fc(r, t, e) {
|
|
1774
1785
|
return t === null ? r : (r === null || (t = xr(r.key, t, e), t.left = r), t);
|
|
1775
1786
|
}
|
|
1776
1787
|
function Ss(r, t, e, n, i) {
|
|
@@ -1785,7 +1796,7 @@ var Gs = (
|
|
|
1785
1796
|
/** @class */
|
|
1786
1797
|
function() {
|
|
1787
1798
|
function r(t) {
|
|
1788
|
-
t === void 0 && (t =
|
|
1799
|
+
t === void 0 && (t = cc), this._root = null, this._size = 0, this._comparator = t;
|
|
1789
1800
|
}
|
|
1790
1801
|
return r.prototype.insert = function(t, e) {
|
|
1791
1802
|
return this._size++, this._root = ms(t, e, this._root, this._comparator);
|
|
@@ -1913,14 +1924,14 @@ var Gs = (
|
|
|
1913
1924
|
}, r.prototype.clear = function() {
|
|
1914
1925
|
return this._root = null, this._size = 0, this;
|
|
1915
1926
|
}, r.prototype.toList = function() {
|
|
1916
|
-
return
|
|
1927
|
+
return gc(this._root);
|
|
1917
1928
|
}, r.prototype.load = function(t, e, n) {
|
|
1918
1929
|
e === void 0 && (e = []), n === void 0 && (n = !1);
|
|
1919
1930
|
var i = t.length, o = this._comparator;
|
|
1920
1931
|
if (n && bs(t, e, 0, i - 1, o), this._root === null)
|
|
1921
1932
|
this._root = ws(t, e, 0, i), this._size = i;
|
|
1922
1933
|
else {
|
|
1923
|
-
var s =
|
|
1934
|
+
var s = pc(this.toList(), hc(t, e), o);
|
|
1924
1935
|
i = this._size + i, this._root = Ls({ head: s }, 0, i);
|
|
1925
1936
|
}
|
|
1926
1937
|
return this;
|
|
@@ -1948,12 +1959,12 @@ var Gs = (
|
|
|
1948
1959
|
}, t), e.join("");
|
|
1949
1960
|
}, r.prototype.update = function(t, e, n) {
|
|
1950
1961
|
var i = this._comparator, o = ya(t, this._root, i), s = o.left, a = o.right;
|
|
1951
|
-
i(t, e) < 0 ? a = ms(e, n, a, i) : s = ms(e, n, s, i), this._root =
|
|
1962
|
+
i(t, e) < 0 ? a = ms(e, n, a, i) : s = ms(e, n, s, i), this._root = fc(s, a, i);
|
|
1952
1963
|
}, r.prototype.split = function(t) {
|
|
1953
1964
|
return ya(t, this._root, this._comparator);
|
|
1954
1965
|
}, r.prototype[Symbol.iterator] = function() {
|
|
1955
1966
|
var t;
|
|
1956
|
-
return
|
|
1967
|
+
return lc(this, function(e) {
|
|
1957
1968
|
switch (e.label) {
|
|
1958
1969
|
case 0:
|
|
1959
1970
|
t = this.minNode(), e.label = 1;
|
|
@@ -1979,12 +1990,12 @@ function ws(r, t, e, n) {
|
|
|
1979
1990
|
}
|
|
1980
1991
|
return null;
|
|
1981
1992
|
}
|
|
1982
|
-
function
|
|
1993
|
+
function hc(r, t) {
|
|
1983
1994
|
for (var e = new Or(null, null), n = e, i = 0; i < r.length; i++)
|
|
1984
1995
|
n = n.next = new Or(r[i], t[i]);
|
|
1985
1996
|
return n.next = null, e.next;
|
|
1986
1997
|
}
|
|
1987
|
-
function
|
|
1998
|
+
function gc(r) {
|
|
1988
1999
|
for (var t = r, e = [], n = !1, i = new Or(null, null), o = i; !n; )
|
|
1989
2000
|
t ? (e.push(t), t = t.left) : e.length > 0 ? (t = o = o.next = e.pop(), t = t.right) : n = !0;
|
|
1990
2001
|
return o.next = null, i.next;
|
|
@@ -1997,7 +2008,7 @@ function Ls(r, t, e) {
|
|
|
1997
2008
|
}
|
|
1998
2009
|
return null;
|
|
1999
2010
|
}
|
|
2000
|
-
function
|
|
2011
|
+
function pc(r, t, e) {
|
|
2001
2012
|
for (var n = new Or(null, null), i = n, o = r, s = t; o !== null && s !== null; )
|
|
2002
2013
|
e(o.key, s.key) < 0 ? (i.next = o, o = o.next) : (i.next = s, s = s.next), i = i.next;
|
|
2003
2014
|
return o !== null ? i.next = o : s !== null && (i.next = s), n.next;
|
|
@@ -2050,12 +2061,12 @@ var Hi = function(t, e) {
|
|
|
2050
2061
|
};
|
|
2051
2062
|
}, Sr = Number.EPSILON;
|
|
2052
2063
|
Sr === void 0 && (Sr = Math.pow(2, -52));
|
|
2053
|
-
var
|
|
2064
|
+
var dc = Sr * Sr, Rs = function(t, e) {
|
|
2054
2065
|
if (-Sr < t && t < Sr && -Sr < e && e < Sr)
|
|
2055
2066
|
return 0;
|
|
2056
2067
|
var n = t - e;
|
|
2057
|
-
return n * n <
|
|
2058
|
-
},
|
|
2068
|
+
return n * n < dc * t * e ? 0 : t < e ? -1 : 1;
|
|
2069
|
+
}, vc = /* @__PURE__ */ function() {
|
|
2059
2070
|
function r() {
|
|
2060
2071
|
mn(this, r), this.reset();
|
|
2061
2072
|
}
|
|
@@ -2087,7 +2098,7 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2087
2098
|
return o !== null && Rs(n.key, o.key) === 0 ? (this.tree.remove(e), o.key) : e;
|
|
2088
2099
|
}
|
|
2089
2100
|
}]), r;
|
|
2090
|
-
}(), eo = new
|
|
2101
|
+
}(), eo = new vc(), Ji = function(t, e) {
|
|
2091
2102
|
return t.x * e.y - t.y * e.x;
|
|
2092
2103
|
}, ou = function(t, e) {
|
|
2093
2104
|
return t.x * e.x + t.y * e.y;
|
|
@@ -2102,7 +2113,7 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2102
2113
|
return Rs(s, 0);
|
|
2103
2114
|
}, Bo = function(t) {
|
|
2104
2115
|
return Math.sqrt(ou(t, t));
|
|
2105
|
-
},
|
|
2116
|
+
}, yc = function(t, e, n) {
|
|
2106
2117
|
var i = {
|
|
2107
2118
|
x: e.x - t.x,
|
|
2108
2119
|
y: e.y - t.y
|
|
@@ -2111,7 +2122,7 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2111
2122
|
y: n.y - t.y
|
|
2112
2123
|
};
|
|
2113
2124
|
return Ji(o, i) / Bo(o) / Bo(i);
|
|
2114
|
-
},
|
|
2125
|
+
}, mc = function(t, e, n) {
|
|
2115
2126
|
var i = {
|
|
2116
2127
|
x: e.x - t.x,
|
|
2117
2128
|
y: e.y - t.y
|
|
@@ -2130,7 +2141,7 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2130
2141
|
x: n,
|
|
2131
2142
|
y: t.y + e.y / e.x * (n - t.x)
|
|
2132
2143
|
};
|
|
2133
|
-
},
|
|
2144
|
+
}, _c = function(t, e, n, i) {
|
|
2134
2145
|
if (e.x === 0)
|
|
2135
2146
|
return Ca(n, i, t.x);
|
|
2136
2147
|
if (i.x === 0)
|
|
@@ -2219,8 +2230,8 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2219
2230
|
var n = this, i = /* @__PURE__ */ new Map(), o = function(a) {
|
|
2220
2231
|
var u = a.otherSE;
|
|
2221
2232
|
i.set(a, {
|
|
2222
|
-
sine:
|
|
2223
|
-
cosine:
|
|
2233
|
+
sine: yc(n.point, e.point, u.point),
|
|
2234
|
+
cosine: mc(n.point, e.point, u.point)
|
|
2224
2235
|
});
|
|
2225
2236
|
};
|
|
2226
2237
|
return function(s, a) {
|
|
@@ -2230,7 +2241,7 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2230
2241
|
};
|
|
2231
2242
|
}
|
|
2232
2243
|
}]), r;
|
|
2233
|
-
}(),
|
|
2244
|
+
}(), Ec = 0, Go = /* @__PURE__ */ function() {
|
|
2234
2245
|
Se(r, null, [{
|
|
2235
2246
|
key: "compare",
|
|
2236
2247
|
/* This compare() function is for ordering segments in the sweep
|
|
@@ -2274,30 +2285,30 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2274
2285
|
var p = n.comparePoint(e.leftSE.point);
|
|
2275
2286
|
if (p !== 0)
|
|
2276
2287
|
return p;
|
|
2277
|
-
var
|
|
2278
|
-
return
|
|
2288
|
+
var y = e.comparePoint(n.rightSE.point);
|
|
2289
|
+
return y < 0 ? 1 : y > 0 ? -1 : 1;
|
|
2279
2290
|
}
|
|
2280
2291
|
if (u < l)
|
|
2281
2292
|
return -1;
|
|
2282
2293
|
if (u > l)
|
|
2283
2294
|
return 1;
|
|
2284
2295
|
if (s < a) {
|
|
2285
|
-
var
|
|
2286
|
-
if (
|
|
2287
|
-
return
|
|
2296
|
+
var m = n.comparePoint(e.rightSE.point);
|
|
2297
|
+
if (m !== 0)
|
|
2298
|
+
return m;
|
|
2288
2299
|
}
|
|
2289
2300
|
if (s > a) {
|
|
2290
|
-
var
|
|
2291
|
-
if (
|
|
2301
|
+
var d = e.comparePoint(n.rightSE.point);
|
|
2302
|
+
if (d < 0)
|
|
2292
2303
|
return 1;
|
|
2293
|
-
if (
|
|
2304
|
+
if (d > 0)
|
|
2294
2305
|
return -1;
|
|
2295
2306
|
}
|
|
2296
2307
|
if (s !== a) {
|
|
2297
|
-
var E = c - u, C = s - i,
|
|
2298
|
-
if (E > C &&
|
|
2308
|
+
var E = c - u, C = s - i, S = f - l, N = a - o;
|
|
2309
|
+
if (E > C && S < N)
|
|
2299
2310
|
return 1;
|
|
2300
|
-
if (E < C &&
|
|
2311
|
+
if (E < C && S > N)
|
|
2301
2312
|
return -1;
|
|
2302
2313
|
}
|
|
2303
2314
|
return s > a ? 1 : s < a || c < f ? -1 : c > f ? 1 : e.id < n.id ? -1 : e.id > n.id ? 1 : 0;
|
|
@@ -2306,7 +2317,7 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2306
2317
|
* and possibly will be later modified */
|
|
2307
2318
|
}]);
|
|
2308
2319
|
function r(t, e, n, i) {
|
|
2309
|
-
mn(this, r), this.id = ++
|
|
2320
|
+
mn(this, r), this.id = ++Ec, this.leftSE = t, t.segment = this, t.otherSE = e, this.rightSE = e, e.segment = this, e.otherSE = t, this.rings = n, this.windings = i;
|
|
2310
2321
|
}
|
|
2311
2322
|
return Se(r, [{
|
|
2312
2323
|
key: "replaceRightSE",
|
|
@@ -2404,7 +2415,7 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2404
2415
|
return a;
|
|
2405
2416
|
if (h)
|
|
2406
2417
|
return l;
|
|
2407
|
-
var p =
|
|
2418
|
+
var p = _c(s, this.vector(), u, e.vector());
|
|
2408
2419
|
return p === null || !Hi(o, p) ? null : eo.round(p.x, p.y);
|
|
2409
2420
|
}
|
|
2410
2421
|
/**
|
|
@@ -2502,19 +2513,19 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2502
2513
|
}
|
|
2503
2514
|
for (var f = [], h = [], g = 0, p = n.length; g < p; g++)
|
|
2504
2515
|
if (i[g] !== 0) {
|
|
2505
|
-
var
|
|
2506
|
-
if (h.indexOf(
|
|
2507
|
-
if (
|
|
2508
|
-
f.push(
|
|
2516
|
+
var y = n[g], m = y.poly;
|
|
2517
|
+
if (h.indexOf(m) === -1)
|
|
2518
|
+
if (y.isExterior)
|
|
2519
|
+
f.push(m);
|
|
2509
2520
|
else {
|
|
2510
|
-
h.indexOf(
|
|
2511
|
-
var
|
|
2512
|
-
|
|
2521
|
+
h.indexOf(m) === -1 && h.push(m);
|
|
2522
|
+
var d = f.indexOf(y.poly);
|
|
2523
|
+
d !== -1 && f.splice(d, 1);
|
|
2513
2524
|
}
|
|
2514
2525
|
}
|
|
2515
2526
|
for (var E = 0, C = f.length; E < C; E++) {
|
|
2516
|
-
var
|
|
2517
|
-
o.indexOf(
|
|
2527
|
+
var S = f[E].multiPoly;
|
|
2528
|
+
o.indexOf(S) === -1 && o.push(S);
|
|
2518
2529
|
}
|
|
2519
2530
|
return this._afterState;
|
|
2520
2531
|
}
|
|
@@ -2604,7 +2615,7 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2604
2615
|
return e;
|
|
2605
2616
|
}
|
|
2606
2617
|
}]), r;
|
|
2607
|
-
}(),
|
|
2618
|
+
}(), Ic = /* @__PURE__ */ function() {
|
|
2608
2619
|
function r(t, e) {
|
|
2609
2620
|
if (mn(this, r), !Array.isArray(t))
|
|
2610
2621
|
throw new Error("Input geometry is not a valid Polygon or MultiPolygon");
|
|
@@ -2652,7 +2663,7 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2652
2663
|
}
|
|
2653
2664
|
};
|
|
2654
2665
|
for (var n = 0, i = t.length; n < i; n++) {
|
|
2655
|
-
var o = new
|
|
2666
|
+
var o = new Ic(t[n], this);
|
|
2656
2667
|
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);
|
|
2657
2668
|
}
|
|
2658
2669
|
this.isSubject = e;
|
|
@@ -2666,7 +2677,7 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2666
2677
|
return e;
|
|
2667
2678
|
}
|
|
2668
2679
|
}]), r;
|
|
2669
|
-
}(),
|
|
2680
|
+
}(), Cc = /* @__PURE__ */ function() {
|
|
2670
2681
|
Se(r, null, [{
|
|
2671
2682
|
key: "factory",
|
|
2672
2683
|
/* Given the segments from the sweep line pass, compute & return a series
|
|
@@ -2679,21 +2690,21 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2679
2690
|
for (; ; ) {
|
|
2680
2691
|
var g = u.getAvailableLinkedEvents();
|
|
2681
2692
|
if (g.length === 0) {
|
|
2682
|
-
var p = c[0].point,
|
|
2683
|
-
throw new Error("Unable to complete output ring starting at [".concat(p.x, ",") + " ".concat(p.y, "]. Last matching segment found ends at") + " [".concat(
|
|
2693
|
+
var p = c[0].point, y = c[c.length - 1].point;
|
|
2694
|
+
throw new Error("Unable to complete output ring starting at [".concat(p.x, ",") + " ".concat(p.y, "]. Last matching segment found ends at") + " [".concat(y.x, ", ").concat(y.y, "]."));
|
|
2684
2695
|
}
|
|
2685
2696
|
if (g.length === 1) {
|
|
2686
2697
|
l = g[0].otherSE;
|
|
2687
2698
|
break;
|
|
2688
2699
|
}
|
|
2689
|
-
for (var
|
|
2690
|
-
if (h[
|
|
2691
|
-
|
|
2700
|
+
for (var m = null, d = 0, E = h.length; d < E; d++)
|
|
2701
|
+
if (h[d].point === u.point) {
|
|
2702
|
+
m = d;
|
|
2692
2703
|
break;
|
|
2693
2704
|
}
|
|
2694
|
-
if (
|
|
2695
|
-
var C = h.splice(
|
|
2696
|
-
|
|
2705
|
+
if (m !== null) {
|
|
2706
|
+
var C = h.splice(m)[0], S = c.splice(C.index);
|
|
2707
|
+
S.unshift(S[0].otherSE), n.push(new r(S.reverse()));
|
|
2697
2708
|
continue;
|
|
2698
2709
|
}
|
|
2699
2710
|
h.push({
|
|
@@ -2786,7 +2797,7 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2786
2797
|
return e;
|
|
2787
2798
|
}
|
|
2788
2799
|
}]), r;
|
|
2789
|
-
}(),
|
|
2800
|
+
}(), Nc = /* @__PURE__ */ function() {
|
|
2790
2801
|
function r(t) {
|
|
2791
2802
|
mn(this, r), this.rings = t, this.polys = this._composePolys(t);
|
|
2792
2803
|
}
|
|
@@ -2815,7 +2826,7 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2815
2826
|
return n;
|
|
2816
2827
|
}
|
|
2817
2828
|
}]), r;
|
|
2818
|
-
}(),
|
|
2829
|
+
}(), xc = /* @__PURE__ */ function() {
|
|
2819
2830
|
function r(t) {
|
|
2820
2831
|
var e = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : Go.compare;
|
|
2821
2832
|
mn(this, r), this.queue = t, this.tree = new Gs(e), this.segments = [];
|
|
@@ -2841,26 +2852,26 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2841
2852
|
for (var h = this._splitSafely(u, f), g = 0, p = h.length; g < p; g++)
|
|
2842
2853
|
i.push(h[g]);
|
|
2843
2854
|
}
|
|
2844
|
-
var
|
|
2855
|
+
var y = null;
|
|
2845
2856
|
if (l) {
|
|
2846
|
-
var
|
|
2847
|
-
if (
|
|
2848
|
-
for (var
|
|
2849
|
-
i.push(
|
|
2857
|
+
var m = l.getIntersection(n);
|
|
2858
|
+
if (m !== null && (n.isAnEndpoint(m) || (y = m), !l.isAnEndpoint(m)))
|
|
2859
|
+
for (var d = this._splitSafely(l, m), E = 0, C = d.length; E < C; E++)
|
|
2860
|
+
i.push(d[E]);
|
|
2850
2861
|
}
|
|
2851
|
-
if (c !== null ||
|
|
2852
|
-
var
|
|
2862
|
+
if (c !== null || y !== null) {
|
|
2863
|
+
var S = null;
|
|
2853
2864
|
if (c === null)
|
|
2854
|
-
|
|
2855
|
-
else if (
|
|
2856
|
-
|
|
2865
|
+
S = y;
|
|
2866
|
+
else if (y === null)
|
|
2867
|
+
S = c;
|
|
2857
2868
|
else {
|
|
2858
|
-
var N = Xn.comparePoints(c,
|
|
2859
|
-
|
|
2869
|
+
var N = Xn.comparePoints(c, y);
|
|
2870
|
+
S = N <= 0 ? c : y;
|
|
2860
2871
|
}
|
|
2861
2872
|
this.queue.remove(n.rightSE), i.push(n.rightSE);
|
|
2862
|
-
for (var
|
|
2863
|
-
i.push(
|
|
2873
|
+
for (var w = n.split(S), T = 0, A = w.length; T < A; T++)
|
|
2874
|
+
i.push(w[T]);
|
|
2864
2875
|
}
|
|
2865
2876
|
i.length > 0 ? (this.tree.remove(n), i.push(e)) : (this.segments.push(n), n.prev = u);
|
|
2866
2877
|
} else {
|
|
@@ -2891,7 +2902,7 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2891
2902
|
return o.push(i), e.consumedBy === void 0 && this.tree.insert(e), o;
|
|
2892
2903
|
}
|
|
2893
2904
|
}]), r;
|
|
2894
|
-
}(), wa = typeof process < "u" && process.env.POLYGON_CLIPPING_MAX_QUEUE_SIZE || 1e6,
|
|
2905
|
+
}(), wa = typeof process < "u" && process.env.POLYGON_CLIPPING_MAX_QUEUE_SIZE || 1e6, Sc = typeof process < "u" && process.env.POLYGON_CLIPPING_MAX_SWEEPLINE_SEGMENTS || 1e6, wc = /* @__PURE__ */ function() {
|
|
2895
2906
|
function r() {
|
|
2896
2907
|
mn(this, r);
|
|
2897
2908
|
}
|
|
@@ -2910,52 +2921,52 @@ var pc = Sr * Sr, Rs = function(t, e) {
|
|
|
2910
2921
|
if (Ps(h.bbox, o[g].bbox) === null)
|
|
2911
2922
|
return [];
|
|
2912
2923
|
}
|
|
2913
|
-
for (var
|
|
2914
|
-
for (var E = o[
|
|
2915
|
-
if (
|
|
2924
|
+
for (var y = new Gs(Xn.compare), m = 0, d = o.length; m < d; m++)
|
|
2925
|
+
for (var E = o[m].getSweepEvents(), C = 0, S = E.length; C < S; C++)
|
|
2926
|
+
if (y.insert(E[C]), y.size > wa)
|
|
2916
2927
|
throw new Error("Infinite loop when putting segment endpoints in a priority queue (queue size too big). Please file a bug report.");
|
|
2917
|
-
for (var N = new
|
|
2928
|
+
for (var N = new xc(y), w = y.size, T = y.pop(); T; ) {
|
|
2918
2929
|
var A = T.key;
|
|
2919
|
-
if (
|
|
2930
|
+
if (y.size === w) {
|
|
2920
2931
|
var L = A.segment;
|
|
2921
2932
|
throw new Error("Unable to pop() ".concat(A.isLeft ? "left" : "right", " SweepEvent ") + "[".concat(A.point.x, ", ").concat(A.point.y, "] from segment #").concat(L.id, " ") + "[".concat(L.leftSE.point.x, ", ").concat(L.leftSE.point.y, "] -> ") + "[".concat(L.rightSE.point.x, ", ").concat(L.rightSE.point.y, "] from queue. ") + "Please file a bug report.");
|
|
2922
2933
|
}
|
|
2923
|
-
if (
|
|
2934
|
+
if (y.size > wa)
|
|
2924
2935
|
throw new Error("Infinite loop when passing sweep line over endpoints (queue size too big). Please file a bug report.");
|
|
2925
|
-
if (N.segments.length >
|
|
2936
|
+
if (N.segments.length > Sc)
|
|
2926
2937
|
throw new Error("Infinite loop when passing sweep line over endpoints (too many sweep line segments). Please file a bug report.");
|
|
2927
2938
|
for (var F = N.process(A), X = 0, R = F.length; X < R; X++) {
|
|
2928
2939
|
var Y = F[X];
|
|
2929
|
-
Y.consumedBy === void 0 &&
|
|
2940
|
+
Y.consumedBy === void 0 && y.insert(Y);
|
|
2930
2941
|
}
|
|
2931
|
-
|
|
2942
|
+
w = y.size, T = y.pop();
|
|
2932
2943
|
}
|
|
2933
2944
|
eo.reset();
|
|
2934
|
-
var D =
|
|
2945
|
+
var D = Cc.factory(N.segments), W = new Nc(D);
|
|
2935
2946
|
return W.getGeom();
|
|
2936
2947
|
}
|
|
2937
2948
|
}]), r;
|
|
2938
|
-
}(), xn = new
|
|
2949
|
+
}(), xn = new wc(), Lc = function(t) {
|
|
2939
2950
|
for (var e = arguments.length, n = new Array(e > 1 ? e - 1 : 0), i = 1; i < e; i++)
|
|
2940
2951
|
n[i - 1] = arguments[i];
|
|
2941
2952
|
return xn.run("union", t, n);
|
|
2942
|
-
},
|
|
2953
|
+
}, bc = function(t) {
|
|
2943
2954
|
for (var e = arguments.length, n = new Array(e > 1 ? e - 1 : 0), i = 1; i < e; i++)
|
|
2944
2955
|
n[i - 1] = arguments[i];
|
|
2945
2956
|
return xn.run("intersection", t, n);
|
|
2946
|
-
},
|
|
2957
|
+
}, Pc = function(t) {
|
|
2947
2958
|
for (var e = arguments.length, n = new Array(e > 1 ? e - 1 : 0), i = 1; i < e; i++)
|
|
2948
2959
|
n[i - 1] = arguments[i];
|
|
2949
2960
|
return xn.run("xor", t, n);
|
|
2950
|
-
},
|
|
2961
|
+
}, Rc = function(t) {
|
|
2951
2962
|
for (var e = arguments.length, n = new Array(e > 1 ? e - 1 : 0), i = 1; i < e; i++)
|
|
2952
2963
|
n[i - 1] = arguments[i];
|
|
2953
2964
|
return xn.run("difference", t, n);
|
|
2954
2965
|
}, su = {
|
|
2955
|
-
union:
|
|
2956
|
-
intersection:
|
|
2957
|
-
xor:
|
|
2958
|
-
difference:
|
|
2966
|
+
union: Lc,
|
|
2967
|
+
intersection: bc,
|
|
2968
|
+
xor: Pc,
|
|
2969
|
+
difference: Rc
|
|
2959
2970
|
}, Ie = 63710088e-1, au = {
|
|
2960
2971
|
centimeters: Ie * 100,
|
|
2961
2972
|
centimetres: Ie * 100,
|
|
@@ -2978,7 +2989,7 @@ function Zo(r, t, e) {
|
|
|
2978
2989
|
var n = { type: "Feature" };
|
|
2979
2990
|
return (e.id === 0 || e.id) && (n.id = e.id), e.bbox && (n.bbox = e.bbox), n.properties = t || {}, n.geometry = r, n;
|
|
2980
2991
|
}
|
|
2981
|
-
function
|
|
2992
|
+
function Oc(r, t, e) {
|
|
2982
2993
|
if (e === void 0 && (e = {}), !r)
|
|
2983
2994
|
throw new Error("coordinates is required");
|
|
2984
2995
|
if (!Array.isArray(r))
|
|
@@ -3022,14 +3033,14 @@ function lu(r, t, e) {
|
|
|
3022
3033
|
};
|
|
3023
3034
|
return Zo(n, t, e);
|
|
3024
3035
|
}
|
|
3025
|
-
function
|
|
3036
|
+
function Tc(r, t) {
|
|
3026
3037
|
t === void 0 && (t = "kilometers");
|
|
3027
3038
|
var e = au[t];
|
|
3028
3039
|
if (!e)
|
|
3029
3040
|
throw new Error(t + " units is invalid");
|
|
3030
3041
|
return r * e;
|
|
3031
3042
|
}
|
|
3032
|
-
function
|
|
3043
|
+
function Dc(r, t) {
|
|
3033
3044
|
t === void 0 && (t = "kilometers");
|
|
3034
3045
|
var e = au[t];
|
|
3035
3046
|
if (!e)
|
|
@@ -3042,12 +3053,12 @@ function La(r) {
|
|
|
3042
3053
|
function Vo(r) {
|
|
3043
3054
|
return r.type === "Feature" ? r.geometry : r;
|
|
3044
3055
|
}
|
|
3045
|
-
function
|
|
3056
|
+
function Mc(r, t, e) {
|
|
3046
3057
|
e === void 0 && (e = {});
|
|
3047
3058
|
var n = Vo(r), i = Vo(t), o = su.union(n.coordinates, i.coordinates);
|
|
3048
3059
|
return o.length === 0 ? null : o.length === 1 ? uu(o[0], e.properties) : lu(o, e.properties);
|
|
3049
3060
|
}
|
|
3050
|
-
function
|
|
3061
|
+
function Ac(r) {
|
|
3051
3062
|
let t, e, n;
|
|
3052
3063
|
return {
|
|
3053
3064
|
c() {
|
|
@@ -3091,23 +3102,23 @@ function Mc(r) {
|
|
|
3091
3102
|
}
|
|
3092
3103
|
};
|
|
3093
3104
|
}
|
|
3094
|
-
function
|
|
3105
|
+
function Fc(r, t, e) {
|
|
3095
3106
|
let { displayIn: n } = t;
|
|
3096
3107
|
return r.$$set = (i) => {
|
|
3097
3108
|
"displayIn" in i && e(0, n = i.displayIn);
|
|
3098
3109
|
}, [n];
|
|
3099
3110
|
}
|
|
3100
|
-
class
|
|
3111
|
+
class kc extends qr {
|
|
3101
3112
|
constructor(t) {
|
|
3102
|
-
super(), Ur(this, t,
|
|
3113
|
+
super(), Ur(this, t, Fc, Ac, zr, { displayIn: 0 });
|
|
3103
3114
|
}
|
|
3104
3115
|
}
|
|
3105
3116
|
function cu(r, t, e) {
|
|
3106
3117
|
if (r !== null)
|
|
3107
|
-
for (var n, i, o, s, a, u, l, c = 0, f = 0, h, g = r.type, p = g === "FeatureCollection",
|
|
3108
|
-
l = p ? r.features[
|
|
3118
|
+
for (var n, i, o, s, a, u, l, c = 0, f = 0, h, g = r.type, p = g === "FeatureCollection", y = g === "Feature", m = p ? r.features.length : 1, d = 0; d < m; d++) {
|
|
3119
|
+
l = p ? r.features[d].geometry : y ? r.geometry : r, h = l ? l.type === "GeometryCollection" : !1, a = h ? l.geometries.length : 1;
|
|
3109
3120
|
for (var E = 0; E < a; E++) {
|
|
3110
|
-
var C = 0,
|
|
3121
|
+
var C = 0, S = 0;
|
|
3111
3122
|
if (s = h ? l.geometries[E] : l, s !== null) {
|
|
3112
3123
|
u = s.coordinates;
|
|
3113
3124
|
var N = s.type;
|
|
@@ -3118,9 +3129,9 @@ function cu(r, t, e) {
|
|
|
3118
3129
|
if (t(
|
|
3119
3130
|
u,
|
|
3120
3131
|
f,
|
|
3121
|
-
|
|
3132
|
+
d,
|
|
3122
3133
|
C,
|
|
3123
|
-
|
|
3134
|
+
S
|
|
3124
3135
|
) === !1)
|
|
3125
3136
|
return !1;
|
|
3126
3137
|
f++, C++;
|
|
@@ -3131,9 +3142,9 @@ function cu(r, t, e) {
|
|
|
3131
3142
|
if (t(
|
|
3132
3143
|
u[n],
|
|
3133
3144
|
f,
|
|
3134
|
-
|
|
3145
|
+
d,
|
|
3135
3146
|
C,
|
|
3136
|
-
|
|
3147
|
+
S
|
|
3137
3148
|
) === !1)
|
|
3138
3149
|
return !1;
|
|
3139
3150
|
f++, N === "MultiPoint" && C++;
|
|
@@ -3147,32 +3158,32 @@ function cu(r, t, e) {
|
|
|
3147
3158
|
if (t(
|
|
3148
3159
|
u[n][i],
|
|
3149
3160
|
f,
|
|
3150
|
-
|
|
3161
|
+
d,
|
|
3151
3162
|
C,
|
|
3152
|
-
|
|
3163
|
+
S
|
|
3153
3164
|
) === !1)
|
|
3154
3165
|
return !1;
|
|
3155
3166
|
f++;
|
|
3156
3167
|
}
|
|
3157
|
-
N === "MultiLineString" && C++, N === "Polygon" &&
|
|
3168
|
+
N === "MultiLineString" && C++, N === "Polygon" && S++;
|
|
3158
3169
|
}
|
|
3159
3170
|
N === "Polygon" && C++;
|
|
3160
3171
|
break;
|
|
3161
3172
|
case "MultiPolygon":
|
|
3162
3173
|
for (n = 0; n < u.length; n++) {
|
|
3163
|
-
for (
|
|
3174
|
+
for (S = 0, i = 0; i < u[n].length; i++) {
|
|
3164
3175
|
for (o = 0; o < u[n][i].length - c; o++) {
|
|
3165
3176
|
if (t(
|
|
3166
3177
|
u[n][i][o],
|
|
3167
3178
|
f,
|
|
3168
|
-
|
|
3179
|
+
d,
|
|
3169
3180
|
C,
|
|
3170
|
-
|
|
3181
|
+
S
|
|
3171
3182
|
) === !1)
|
|
3172
3183
|
return !1;
|
|
3173
3184
|
f++;
|
|
3174
3185
|
}
|
|
3175
|
-
|
|
3186
|
+
S++;
|
|
3176
3187
|
}
|
|
3177
3188
|
C++;
|
|
3178
3189
|
}
|
|
@@ -3197,8 +3208,8 @@ function ba(r, t) {
|
|
|
3197
3208
|
;
|
|
3198
3209
|
}
|
|
3199
3210
|
function fu(r, t) {
|
|
3200
|
-
var e, n, i, o, s, a, u, l, c, f, h = 0, g = r.type === "FeatureCollection", p = r.type === "Feature",
|
|
3201
|
-
for (e = 0; e <
|
|
3211
|
+
var e, n, i, o, s, a, u, l, c, f, h = 0, g = r.type === "FeatureCollection", p = r.type === "Feature", y = g ? r.features.length : 1;
|
|
3212
|
+
for (e = 0; e < y; e++) {
|
|
3202
3213
|
for (a = g ? r.features[e].geometry : p ? r.geometry : r, l = g ? r.features[e].properties : p ? r.properties : {}, c = g ? r.features[e].bbox : p ? r.bbox : void 0, f = g ? r.features[e].id : p ? r.id : void 0, u = a ? a.type === "GeometryCollection" : !1, s = u ? a.geometries.length : 1, i = 0; i < s; i++) {
|
|
3203
3214
|
if (o = u ? a.geometries[i] : a, o === null) {
|
|
3204
3215
|
if (t(
|
|
@@ -3254,10 +3265,10 @@ function Ts(r) {
|
|
|
3254
3265
|
}), t;
|
|
3255
3266
|
}
|
|
3256
3267
|
Ts.default = Ts;
|
|
3257
|
-
function
|
|
3268
|
+
function Bc(r, t) {
|
|
3258
3269
|
t === void 0 && (t = {});
|
|
3259
3270
|
var e = Ts(r), n = (e[0] + e[2]) / 2, i = (e[1] + e[3]) / 2;
|
|
3260
|
-
return
|
|
3271
|
+
return Oc([n, i], t.properties, t);
|
|
3261
3272
|
}
|
|
3262
3273
|
"fill" in Array.prototype || Object.defineProperty(Array.prototype, "fill", {
|
|
3263
3274
|
configurable: !0,
|
|
@@ -3326,7 +3337,7 @@ var ke = function() {
|
|
|
3326
3337
|
};
|
|
3327
3338
|
function Be() {
|
|
3328
3339
|
}
|
|
3329
|
-
var
|
|
3340
|
+
var v = function r() {
|
|
3330
3341
|
if (this.x = null, this.y = null, this.z = null, arguments.length === 0)
|
|
3331
3342
|
this.x = 0, this.y = 0, this.z = r.NULL_ORDINATE;
|
|
3332
3343
|
else if (arguments.length === 1) {
|
|
@@ -3335,22 +3346,22 @@ var y = function r() {
|
|
|
3335
3346
|
} else
|
|
3336
3347
|
arguments.length === 2 ? (this.x = arguments[0], this.y = arguments[1], this.z = r.NULL_ORDINATE) : arguments.length === 3 && (this.x = arguments[0], this.y = arguments[1], this.z = arguments[2]);
|
|
3337
3348
|
}, ci = { DimensionalComparator: { configurable: !0 }, serialVersionUID: { configurable: !0 }, NULL_ORDINATE: { configurable: !0 }, X: { configurable: !0 }, Y: { configurable: !0 }, Z: { configurable: !0 } };
|
|
3338
|
-
|
|
3349
|
+
v.prototype.setOrdinate = function(t, e) {
|
|
3339
3350
|
switch (t) {
|
|
3340
|
-
case
|
|
3351
|
+
case v.X:
|
|
3341
3352
|
this.x = e;
|
|
3342
3353
|
break;
|
|
3343
|
-
case
|
|
3354
|
+
case v.Y:
|
|
3344
3355
|
this.y = e;
|
|
3345
3356
|
break;
|
|
3346
|
-
case
|
|
3357
|
+
case v.Z:
|
|
3347
3358
|
this.z = e;
|
|
3348
3359
|
break;
|
|
3349
3360
|
default:
|
|
3350
3361
|
throw new ft("Invalid ordinate index: " + t);
|
|
3351
3362
|
}
|
|
3352
3363
|
};
|
|
3353
|
-
|
|
3364
|
+
v.prototype.equals2D = function() {
|
|
3354
3365
|
if (arguments.length === 1) {
|
|
3355
3366
|
var t = arguments[0];
|
|
3356
3367
|
return !(this.x !== t.x || this.y !== t.y);
|
|
@@ -3359,60 +3370,60 @@ y.prototype.equals2D = function() {
|
|
|
3359
3370
|
return !(!Zr.equalsWithTolerance(this.x, e.x, n) || !Zr.equalsWithTolerance(this.y, e.y, n));
|
|
3360
3371
|
}
|
|
3361
3372
|
};
|
|
3362
|
-
|
|
3373
|
+
v.prototype.getOrdinate = function(t) {
|
|
3363
3374
|
switch (t) {
|
|
3364
|
-
case
|
|
3375
|
+
case v.X:
|
|
3365
3376
|
return this.x;
|
|
3366
|
-
case
|
|
3377
|
+
case v.Y:
|
|
3367
3378
|
return this.y;
|
|
3368
|
-
case
|
|
3379
|
+
case v.Z:
|
|
3369
3380
|
return this.z;
|
|
3370
3381
|
}
|
|
3371
3382
|
throw new ft("Invalid ordinate index: " + t);
|
|
3372
3383
|
};
|
|
3373
|
-
|
|
3384
|
+
v.prototype.equals3D = function(t) {
|
|
3374
3385
|
return this.x === t.x && this.y === t.y && (this.z === t.z || z.isNaN(this.z)) && z.isNaN(t.z);
|
|
3375
3386
|
};
|
|
3376
|
-
|
|
3377
|
-
return t instanceof
|
|
3387
|
+
v.prototype.equals = function(t) {
|
|
3388
|
+
return t instanceof v ? this.equals2D(t) : !1;
|
|
3378
3389
|
};
|
|
3379
|
-
|
|
3390
|
+
v.prototype.equalInZ = function(t, e) {
|
|
3380
3391
|
return Zr.equalsWithTolerance(this.z, t.z, e);
|
|
3381
3392
|
};
|
|
3382
|
-
|
|
3393
|
+
v.prototype.compareTo = function(t) {
|
|
3383
3394
|
var e = t;
|
|
3384
3395
|
return this.x < e.x ? -1 : this.x > e.x ? 1 : this.y < e.y ? -1 : this.y > e.y ? 1 : 0;
|
|
3385
3396
|
};
|
|
3386
|
-
|
|
3397
|
+
v.prototype.clone = function() {
|
|
3387
3398
|
};
|
|
3388
|
-
|
|
3389
|
-
return new
|
|
3399
|
+
v.prototype.copy = function() {
|
|
3400
|
+
return new v(this);
|
|
3390
3401
|
};
|
|
3391
|
-
|
|
3402
|
+
v.prototype.toString = function() {
|
|
3392
3403
|
return "(" + this.x + ", " + this.y + ", " + this.z + ")";
|
|
3393
3404
|
};
|
|
3394
|
-
|
|
3405
|
+
v.prototype.distance3D = function(t) {
|
|
3395
3406
|
var e = this.x - t.x, n = this.y - t.y, i = this.z - t.z;
|
|
3396
3407
|
return Math.sqrt(e * e + n * n + i * i);
|
|
3397
3408
|
};
|
|
3398
|
-
|
|
3409
|
+
v.prototype.distance = function(t) {
|
|
3399
3410
|
var e = this.x - t.x, n = this.y - t.y;
|
|
3400
3411
|
return Math.sqrt(e * e + n * n);
|
|
3401
3412
|
};
|
|
3402
|
-
|
|
3413
|
+
v.prototype.hashCode = function() {
|
|
3403
3414
|
var t = 17;
|
|
3404
|
-
return t = 37 * t +
|
|
3415
|
+
return t = 37 * t + v.hashCode(this.x), t = 37 * t + v.hashCode(this.y), t;
|
|
3405
3416
|
};
|
|
3406
|
-
|
|
3417
|
+
v.prototype.setCoordinate = function(t) {
|
|
3407
3418
|
this.x = t.x, this.y = t.y, this.z = t.z;
|
|
3408
3419
|
};
|
|
3409
|
-
|
|
3420
|
+
v.prototype.interfaces_ = function() {
|
|
3410
3421
|
return [ke, Jo, Be];
|
|
3411
3422
|
};
|
|
3412
|
-
|
|
3413
|
-
return
|
|
3423
|
+
v.prototype.getClass = function() {
|
|
3424
|
+
return v;
|
|
3414
3425
|
};
|
|
3415
|
-
|
|
3426
|
+
v.hashCode = function() {
|
|
3416
3427
|
if (arguments.length === 1) {
|
|
3417
3428
|
var t = arguments[0], e = z.doubleToLongBits(t);
|
|
3418
3429
|
return Math.trunc((e ^ e) >>> 32);
|
|
@@ -3436,7 +3447,7 @@ ci.Y.get = function() {
|
|
|
3436
3447
|
ci.Z.get = function() {
|
|
3437
3448
|
return 2;
|
|
3438
3449
|
};
|
|
3439
|
-
Object.defineProperties(
|
|
3450
|
+
Object.defineProperties(v, ci);
|
|
3440
3451
|
var or = function(t) {
|
|
3441
3452
|
if (this._dimensionsToTest = 2, arguments.length !== 0) {
|
|
3442
3453
|
if (arguments.length === 1) {
|
|
@@ -3755,10 +3766,10 @@ I.prototype.selfAdd = function() {
|
|
|
3755
3766
|
return o = this._hi + e, a = o - this._hi, s = o - a, s = e - a + (this._hi - s), u = s + this._lo, n = o + u, i = u + (o - n), this._hi = n + i, this._lo = i + (n - this._hi), this;
|
|
3756
3767
|
}
|
|
3757
3768
|
} else if (arguments.length === 2) {
|
|
3758
|
-
var l = arguments[0], c = arguments[1], f = null, h = null, g = null, p = null,
|
|
3759
|
-
|
|
3760
|
-
var C = f +
|
|
3761
|
-
return this._hi = C, this._lo =
|
|
3769
|
+
var l = arguments[0], c = arguments[1], f = null, h = null, g = null, p = null, y = null, m = null, d = null, E = null;
|
|
3770
|
+
y = this._hi + l, g = this._lo + c, d = y - this._hi, E = g - this._lo, m = y - d, p = g - E, m = l - d + (this._hi - m), p = c - E + (this._lo - p), d = m + g, f = y + d, h = d + (y - f), d = p + h;
|
|
3771
|
+
var C = f + d, S = d + (f - C);
|
|
3772
|
+
return this._hi = C, this._lo = S, this;
|
|
3762
3773
|
}
|
|
3763
3774
|
};
|
|
3764
3775
|
I.prototype.selfMultiply = function() {
|
|
@@ -3935,8 +3946,8 @@ I.parse = function(t) {
|
|
|
3935
3946
|
var h = t.substring(e);
|
|
3936
3947
|
try {
|
|
3937
3948
|
l = un.parseInt(h);
|
|
3938
|
-
} catch (
|
|
3939
|
-
throw
|
|
3949
|
+
} catch (d) {
|
|
3950
|
+
throw d instanceof Error ? new Error("Invalid exponent " + h + " in string " + t) : d;
|
|
3940
3951
|
} finally {
|
|
3941
3952
|
}
|
|
3942
3953
|
break;
|
|
@@ -3947,11 +3958,11 @@ I.parse = function(t) {
|
|
|
3947
3958
|
if (p === 0)
|
|
3948
3959
|
g = s;
|
|
3949
3960
|
else if (p > 0) {
|
|
3950
|
-
var
|
|
3951
|
-
g = s.divide(
|
|
3961
|
+
var y = I.TEN.pow(p);
|
|
3962
|
+
g = s.divide(y);
|
|
3952
3963
|
} else if (p < 0) {
|
|
3953
|
-
var
|
|
3954
|
-
g = s.multiply(
|
|
3964
|
+
var m = I.TEN.pow(-p);
|
|
3965
|
+
g = s.multiply(m);
|
|
3955
3966
|
}
|
|
3956
3967
|
return i ? g.negate() : g;
|
|
3957
3968
|
};
|
|
@@ -4027,8 +4038,8 @@ ce.signOfDet2x2 = function(t, e, n, i) {
|
|
|
4027
4038
|
return o.signum();
|
|
4028
4039
|
};
|
|
4029
4040
|
ce.intersection = function(t, e, n, i) {
|
|
4030
|
-
var o = I.valueOf(i.y).selfSubtract(n.y).selfMultiply(I.valueOf(e.x).selfSubtract(t.x)), s = I.valueOf(i.x).selfSubtract(n.x).selfMultiply(I.valueOf(e.y).selfSubtract(t.y)), a = o.subtract(s), u = I.valueOf(i.x).selfSubtract(n.x).selfMultiply(I.valueOf(t.y).selfSubtract(n.y)), l = I.valueOf(i.y).selfSubtract(n.y).selfMultiply(I.valueOf(t.x).selfSubtract(n.x)), c = u.subtract(l), f = c.selfDivide(a).doubleValue(), h = I.valueOf(t.x).selfAdd(I.valueOf(e.x).selfSubtract(t.x).selfMultiply(f)).doubleValue(), g = I.valueOf(e.x).selfSubtract(t.x).selfMultiply(I.valueOf(t.y).selfSubtract(n.y)), p = I.valueOf(e.y).selfSubtract(t.y).selfMultiply(I.valueOf(t.x).selfSubtract(n.x)),
|
|
4031
|
-
return new
|
|
4041
|
+
var o = I.valueOf(i.y).selfSubtract(n.y).selfMultiply(I.valueOf(e.x).selfSubtract(t.x)), s = I.valueOf(i.x).selfSubtract(n.x).selfMultiply(I.valueOf(e.y).selfSubtract(t.y)), a = o.subtract(s), u = I.valueOf(i.x).selfSubtract(n.x).selfMultiply(I.valueOf(t.y).selfSubtract(n.y)), l = I.valueOf(i.y).selfSubtract(n.y).selfMultiply(I.valueOf(t.x).selfSubtract(n.x)), c = u.subtract(l), f = c.selfDivide(a).doubleValue(), h = I.valueOf(t.x).selfAdd(I.valueOf(e.x).selfSubtract(t.x).selfMultiply(f)).doubleValue(), g = I.valueOf(e.x).selfSubtract(t.x).selfMultiply(I.valueOf(t.y).selfSubtract(n.y)), p = I.valueOf(e.y).selfSubtract(t.y).selfMultiply(I.valueOf(t.x).selfSubtract(n.x)), y = g.subtract(p), m = y.selfDivide(a).doubleValue(), d = I.valueOf(n.y).selfAdd(I.valueOf(i.y).selfSubtract(n.y).selfMultiply(m)).doubleValue();
|
|
4042
|
+
return new v(h, d);
|
|
4032
4043
|
};
|
|
4033
4044
|
ce.orientationIndexFilter = function(t, e, n) {
|
|
4034
4045
|
var i = null, o = (t.x - n.x) * (e.y - n.y), s = (t.y - n.y) * (e.x - n.x), a = o - s;
|
|
@@ -4132,7 +4143,7 @@ var Ue = function r() {
|
|
|
4132
4143
|
} else if (arguments[0] instanceof r && arguments[1] instanceof r) {
|
|
4133
4144
|
var i = arguments[0], o = arguments[1];
|
|
4134
4145
|
this.x = i.y * o.w - o.y * i.w, this.y = o.x * i.w - i.x * o.w, this.w = i.x * o.y - o.x * i.y;
|
|
4135
|
-
} else if (arguments[0] instanceof
|
|
4146
|
+
} else if (arguments[0] instanceof v && arguments[1] instanceof v) {
|
|
4136
4147
|
var s = arguments[0], a = arguments[1];
|
|
4137
4148
|
this.x = s.y - a.y, this.y = a.x - s.x, this.w = s.x * a.y - a.x * s.y;
|
|
4138
4149
|
}
|
|
@@ -4140,8 +4151,8 @@ var Ue = function r() {
|
|
|
4140
4151
|
var u = arguments[0], l = arguments[1], c = arguments[2];
|
|
4141
4152
|
this.x = u, this.y = l, this.w = c;
|
|
4142
4153
|
} else if (arguments.length === 4) {
|
|
4143
|
-
var f = arguments[0], h = arguments[1], g = arguments[2], p = arguments[3],
|
|
4144
|
-
this.x =
|
|
4154
|
+
var f = arguments[0], h = arguments[1], g = arguments[2], p = arguments[3], y = f.y - h.y, m = h.x - f.x, d = f.x * h.y - h.x * f.y, E = g.y - p.y, C = p.x - g.x, S = g.x * p.y - p.x * g.y;
|
|
4155
|
+
this.x = m * S - C * d, this.y = E * d - y * S, this.w = y * C - E * m;
|
|
4145
4156
|
}
|
|
4146
4157
|
};
|
|
4147
4158
|
Ue.prototype.getY = function() {
|
|
@@ -4157,7 +4168,7 @@ Ue.prototype.getX = function() {
|
|
|
4157
4168
|
return t;
|
|
4158
4169
|
};
|
|
4159
4170
|
Ue.prototype.getCoordinate = function() {
|
|
4160
|
-
var t = new
|
|
4171
|
+
var t = new v();
|
|
4161
4172
|
return t.x = this.getX(), t.y = this.getY(), t;
|
|
4162
4173
|
};
|
|
4163
4174
|
Ue.prototype.interfaces_ = function() {
|
|
@@ -4167,16 +4178,16 @@ Ue.prototype.getClass = function() {
|
|
|
4167
4178
|
return Ue;
|
|
4168
4179
|
};
|
|
4169
4180
|
Ue.intersection = function(t, e, n, i) {
|
|
4170
|
-
var o = t.y - e.y, s = e.x - t.x, a = t.x * e.y - e.x * t.y, u = n.y - i.y, l = i.x - n.x, c = n.x * i.y - i.x * n.y, f = s * c - l * a, h = u * a - o * c, g = o * l - u * s, p = f / g,
|
|
4171
|
-
if (z.isNaN(p) || z.isInfinite(p) || z.isNaN(
|
|
4181
|
+
var o = t.y - e.y, s = e.x - t.x, a = t.x * e.y - e.x * t.y, u = n.y - i.y, l = i.x - n.x, c = n.x * i.y - i.x * n.y, f = s * c - l * a, h = u * a - o * c, g = o * l - u * s, p = f / g, y = h / g;
|
|
4182
|
+
if (z.isNaN(p) || z.isInfinite(p) || z.isNaN(y) || z.isInfinite(y))
|
|
4172
4183
|
throw new Ui();
|
|
4173
|
-
return new
|
|
4184
|
+
return new v(p, y);
|
|
4174
4185
|
};
|
|
4175
4186
|
var k = function r() {
|
|
4176
4187
|
if (this._minx = null, this._maxx = null, this._miny = null, this._maxy = null, arguments.length === 0)
|
|
4177
4188
|
this.init();
|
|
4178
4189
|
else if (arguments.length === 1) {
|
|
4179
|
-
if (arguments[0] instanceof
|
|
4190
|
+
if (arguments[0] instanceof v) {
|
|
4180
4191
|
var t = arguments[0];
|
|
4181
4192
|
this.init(t.x, t.x, t.y, t.y);
|
|
4182
4193
|
} else if (arguments[0] instanceof r) {
|
|
@@ -4214,7 +4225,7 @@ k.prototype.getMaxX = function() {
|
|
|
4214
4225
|
};
|
|
4215
4226
|
k.prototype.covers = function() {
|
|
4216
4227
|
if (arguments.length === 1) {
|
|
4217
|
-
if (arguments[0] instanceof
|
|
4228
|
+
if (arguments[0] instanceof v) {
|
|
4218
4229
|
var t = arguments[0];
|
|
4219
4230
|
return this.covers(t.x, t.y);
|
|
4220
4231
|
} else if (arguments[0] instanceof k) {
|
|
@@ -4231,7 +4242,7 @@ k.prototype.intersects = function() {
|
|
|
4231
4242
|
if (arguments[0] instanceof k) {
|
|
4232
4243
|
var t = arguments[0];
|
|
4233
4244
|
return this.isNull() || t.isNull() ? !1 : !(t._minx > this._maxx || t._maxx < this._minx || t._miny > this._maxy || t._maxy < this._miny);
|
|
4234
|
-
} else if (arguments[0] instanceof
|
|
4245
|
+
} else if (arguments[0] instanceof v) {
|
|
4235
4246
|
var e = arguments[0];
|
|
4236
4247
|
return this.intersects(e.x, e.y);
|
|
4237
4248
|
}
|
|
@@ -4248,7 +4259,7 @@ k.prototype.getMinX = function() {
|
|
|
4248
4259
|
};
|
|
4249
4260
|
k.prototype.expandToInclude = function() {
|
|
4250
4261
|
if (arguments.length === 1) {
|
|
4251
|
-
if (arguments[0] instanceof
|
|
4262
|
+
if (arguments[0] instanceof v) {
|
|
4252
4263
|
var t = arguments[0];
|
|
4253
4264
|
this.expandToInclude(t.x, t.y);
|
|
4254
4265
|
} else if (arguments[0] instanceof k) {
|
|
@@ -4311,7 +4322,7 @@ k.prototype.contains = function() {
|
|
|
4311
4322
|
if (arguments[0] instanceof k) {
|
|
4312
4323
|
var t = arguments[0];
|
|
4313
4324
|
return this.covers(t);
|
|
4314
|
-
} else if (arguments[0] instanceof
|
|
4325
|
+
} else if (arguments[0] instanceof v) {
|
|
4315
4326
|
var e = arguments[0];
|
|
4316
4327
|
return this.covers(e);
|
|
4317
4328
|
}
|
|
@@ -4321,13 +4332,13 @@ k.prototype.contains = function() {
|
|
|
4321
4332
|
}
|
|
4322
4333
|
};
|
|
4323
4334
|
k.prototype.centre = function() {
|
|
4324
|
-
return this.isNull() ? null : new
|
|
4335
|
+
return this.isNull() ? null : new v((this.getMinX() + this.getMaxX()) / 2, (this.getMinY() + this.getMaxY()) / 2);
|
|
4325
4336
|
};
|
|
4326
4337
|
k.prototype.init = function() {
|
|
4327
4338
|
if (arguments.length === 0)
|
|
4328
4339
|
this.setToNull();
|
|
4329
4340
|
else if (arguments.length === 1) {
|
|
4330
|
-
if (arguments[0] instanceof
|
|
4341
|
+
if (arguments[0] instanceof v) {
|
|
4331
4342
|
var t = arguments[0];
|
|
4332
4343
|
this.init(t.x, t.x, t.y, t.y);
|
|
4333
4344
|
} else if (arguments[0] instanceof k) {
|
|
@@ -4355,7 +4366,7 @@ k.prototype.distance = function(t) {
|
|
|
4355
4366
|
};
|
|
4356
4367
|
k.prototype.hashCode = function() {
|
|
4357
4368
|
var t = 17;
|
|
4358
|
-
return t = 37 * t +
|
|
4369
|
+
return t = 37 * t + v.hashCode(this._minx), t = 37 * t + v.hashCode(this._maxx), t = 37 * t + v.hashCode(this._miny), t = 37 * t + v.hashCode(this._maxy), t;
|
|
4359
4370
|
};
|
|
4360
4371
|
k.prototype.interfaces_ = function() {
|
|
4361
4372
|
return [ke, Be];
|
|
@@ -4508,7 +4519,7 @@ var Un = {
|
|
|
4508
4519
|
if (t === void 0)
|
|
4509
4520
|
return this.geometryFactory.createPoint();
|
|
4510
4521
|
var e = t.trim().split($e.spaces);
|
|
4511
|
-
return this.geometryFactory.createPoint(new
|
|
4522
|
+
return this.geometryFactory.createPoint(new v(
|
|
4512
4523
|
Number.parseFloat(e[0]),
|
|
4513
4524
|
Number.parseFloat(e[1])
|
|
4514
4525
|
));
|
|
@@ -4539,7 +4550,7 @@ var Un = {
|
|
|
4539
4550
|
if (t === void 0)
|
|
4540
4551
|
return this.geometryFactory.createLineString();
|
|
4541
4552
|
for (var e = t.trim().split(","), n = [], i, o = 0, s = e.length; o < s; ++o)
|
|
4542
|
-
i = e[o].trim().split($e.spaces), n.push(new
|
|
4553
|
+
i = e[o].trim().split($e.spaces), n.push(new v(Number.parseFloat(i[0]), Number.parseFloat(i[1])));
|
|
4543
4554
|
return this.geometryFactory.createLineString(n);
|
|
4544
4555
|
},
|
|
4545
4556
|
/**
|
|
@@ -4553,7 +4564,7 @@ var Un = {
|
|
|
4553
4564
|
if (t === void 0)
|
|
4554
4565
|
return this.geometryFactory.createLinearRing();
|
|
4555
4566
|
for (var e = t.trim().split(","), n = [], i, o = 0, s = e.length; o < s; ++o)
|
|
4556
|
-
i = e[o].trim().split($e.spaces), n.push(new
|
|
4567
|
+
i = e[o].trim().split($e.spaces), n.push(new v(Number.parseFloat(i[0]), Number.parseFloat(i[1])));
|
|
4557
4568
|
return this.geometryFactory.createLinearRing(n);
|
|
4558
4569
|
},
|
|
4559
4570
|
/**
|
|
@@ -4680,7 +4691,7 @@ q.equals = function() {
|
|
|
4680
4691
|
var gt = function() {
|
|
4681
4692
|
this._result = null, this._inputLines = Array(2).fill().map(function() {
|
|
4682
4693
|
return Array(2);
|
|
4683
|
-
}), this._intPt = new Array(2).fill(null), this._intLineIndex = null, this._isProper = null, this._pa = null, this._pb = null, this._precisionModel = null, this._intPt[0] = new
|
|
4694
|
+
}), this._intPt = new Array(2).fill(null), this._intLineIndex = null, this._isProper = null, this._pa = null, this._pb = null, this._precisionModel = null, this._intPt[0] = new v(), this._intPt[1] = new v(), this._pa = this._intPt[0], this._pb = this._intPt[1], this._result = 0;
|
|
4684
4695
|
}, fi = { DONT_INTERSECT: { configurable: !0 }, DO_INTERSECT: { configurable: !0 }, COLLINEAR: { configurable: !0 }, NO_INTERSECTION: { configurable: !0 }, POINT_INTERSECTION: { configurable: !0 }, COLLINEAR_INTERSECTION: { configurable: !0 } };
|
|
4685
4696
|
gt.prototype.getIndexAlongSegment = function(t, e) {
|
|
4686
4697
|
return this.computeIntLineIndex(), this._intLineIndex[t][e];
|
|
@@ -4825,7 +4836,7 @@ var Xr = function(r) {
|
|
|
4825
4836
|
return a;
|
|
4826
4837
|
}, t.prototype.intersection = function(n, i, o, s) {
|
|
4827
4838
|
var a = this.intersectionWithNormalization(n, i, o, s);
|
|
4828
|
-
return this.isInSegmentEnvelopes(a) || (a = new
|
|
4839
|
+
return this.isInSegmentEnvelopes(a) || (a = new v(t.nearestEndpoint(n, i, o, s))), this._precisionModel !== null && this._precisionModel.makePrecise(a), a;
|
|
4829
4840
|
}, t.prototype.smallestInAbsValue = function(n, i, o, s) {
|
|
4830
4841
|
var a = n, u = Math.abs(a);
|
|
4831
4842
|
return Math.abs(i) < u && (a = i, u = Math.abs(i)), Math.abs(o) < u && (a = o, u = Math.abs(o)), Math.abs(s) < u && (a = s), a;
|
|
@@ -4833,7 +4844,7 @@ var Xr = function(r) {
|
|
|
4833
4844
|
var u = ce.intersection(n, i, o, s), l = this.isInSegmentEnvelopes(u);
|
|
4834
4845
|
qt.out.println("DD in env = " + l + " --------------------- " + u), a.distance(u) > 1e-4 && qt.out.println("Distance = " + a.distance(u));
|
|
4835
4846
|
}, t.prototype.intersectionWithNormalization = function(n, i, o, s) {
|
|
4836
|
-
var a = new
|
|
4847
|
+
var a = new v(n), u = new v(i), l = new v(o), c = new v(s), f = new v();
|
|
4837
4848
|
this.normalizeToEnvCentre(a, u, l, c, f);
|
|
4838
4849
|
var h = this.safeHCoordinateIntersection(a, u, l, c);
|
|
4839
4850
|
return h.x += f.x, h.y += f.y, h;
|
|
@@ -4841,8 +4852,8 @@ var Xr = function(r) {
|
|
|
4841
4852
|
var a = k.intersects(n, i, o), u = k.intersects(n, i, s), l = k.intersects(o, s, n), c = k.intersects(o, s, i);
|
|
4842
4853
|
return a && u ? (this._intPt[0] = o, this._intPt[1] = s, r.COLLINEAR_INTERSECTION) : l && c ? (this._intPt[0] = n, this._intPt[1] = i, r.COLLINEAR_INTERSECTION) : a && l ? (this._intPt[0] = o, this._intPt[1] = n, o.equals(n) && !u && !c ? r.POINT_INTERSECTION : r.COLLINEAR_INTERSECTION) : a && c ? (this._intPt[0] = o, this._intPt[1] = i, o.equals(i) && !u && !l ? r.POINT_INTERSECTION : r.COLLINEAR_INTERSECTION) : u && l ? (this._intPt[0] = s, this._intPt[1] = n, s.equals(n) && !a && !c ? r.POINT_INTERSECTION : r.COLLINEAR_INTERSECTION) : u && c ? (this._intPt[0] = s, this._intPt[1] = i, s.equals(i) && !a && !l ? r.POINT_INTERSECTION : r.COLLINEAR_INTERSECTION) : r.NO_INTERSECTION;
|
|
4843
4854
|
}, t.prototype.normalizeToEnvCentre = function(n, i, o, s, a) {
|
|
4844
|
-
var u = n.x < i.x ? n.x : i.x, l = n.y < i.y ? n.y : i.y, c = n.x > i.x ? n.x : i.x, f = n.y > i.y ? n.y : i.y, h = o.x < s.x ? o.x : s.x, g = o.y < s.y ? o.y : s.y, p = o.x > s.x ? o.x : s.x,
|
|
4845
|
-
a.x =
|
|
4855
|
+
var u = n.x < i.x ? n.x : i.x, l = n.y < i.y ? n.y : i.y, c = n.x > i.x ? n.x : i.x, f = n.y > i.y ? n.y : i.y, h = o.x < s.x ? o.x : s.x, g = o.y < s.y ? o.y : s.y, p = o.x > s.x ? o.x : s.x, y = o.y > s.y ? o.y : s.y, m = u > h ? u : h, d = c < p ? c : p, E = l > g ? l : g, C = f < y ? f : y, S = (m + d) / 2, N = (E + C) / 2;
|
|
4856
|
+
a.x = S, a.y = N, n.x -= a.x, n.y -= a.y, i.x -= a.x, i.y -= a.y, o.x -= a.x, o.y -= a.y, s.x -= a.x, s.y -= a.y;
|
|
4846
4857
|
}, t.prototype.computeIntersect = function(n, i, o, s) {
|
|
4847
4858
|
if (this._isProper = !1, !k.intersects(n, i, o, s))
|
|
4848
4859
|
return r.NO_INTERSECTION;
|
|
@@ -4853,7 +4864,7 @@ var Xr = function(r) {
|
|
|
4853
4864
|
if (l > 0 && c > 0 || l < 0 && c < 0)
|
|
4854
4865
|
return r.NO_INTERSECTION;
|
|
4855
4866
|
var f = a === 0 && u === 0 && l === 0 && c === 0;
|
|
4856
|
-
return f ? this.computeCollinearIntersection(n, i, o, s) : (a === 0 || u === 0 || l === 0 || c === 0 ? (this._isProper = !1, n.equals2D(o) || n.equals2D(s) ? this._intPt[0] = n : i.equals2D(o) || i.equals2D(s) ? this._intPt[0] = i : a === 0 ? this._intPt[0] = new
|
|
4867
|
+
return f ? this.computeCollinearIntersection(n, i, o, s) : (a === 0 || u === 0 || l === 0 || c === 0 ? (this._isProper = !1, n.equals2D(o) || n.equals2D(s) ? this._intPt[0] = n : i.equals2D(o) || i.equals2D(s) ? this._intPt[0] = i : a === 0 ? this._intPt[0] = new v(o) : u === 0 ? this._intPt[0] = new v(s) : l === 0 ? this._intPt[0] = new v(n) : c === 0 && (this._intPt[0] = new v(i))) : (this._isProper = !0, this._intPt[0] = this.intersection(n, i, o, s)), r.POINT_INTERSECTION);
|
|
4857
4868
|
}, t.prototype.interfaces_ = function() {
|
|
4858
4869
|
return [];
|
|
4859
4870
|
}, t.prototype.getClass = function() {
|
|
@@ -4964,12 +4975,12 @@ sn.prototype.getClass = function() {
|
|
|
4964
4975
|
return sn;
|
|
4965
4976
|
};
|
|
4966
4977
|
sn.locatePointInRing = function() {
|
|
4967
|
-
if (arguments[0] instanceof
|
|
4968
|
-
for (var t = arguments[0], e = arguments[1], n = new sn(t), i = new
|
|
4978
|
+
if (arguments[0] instanceof v && V(arguments[1], Q)) {
|
|
4979
|
+
for (var t = arguments[0], e = arguments[1], n = new sn(t), i = new v(), o = new v(), s = 1; s < e.size(); s++)
|
|
4969
4980
|
if (e.getCoordinate(s, i), e.getCoordinate(s - 1, o), n.countSegment(i, o), n.isOnSegment())
|
|
4970
4981
|
return n.getLocation();
|
|
4971
4982
|
return n.getLocation();
|
|
4972
|
-
} else if (arguments[0] instanceof
|
|
4983
|
+
} else if (arguments[0] instanceof v && arguments[1] instanceof Array) {
|
|
4973
4984
|
for (var a = arguments[0], u = arguments[1], l = new sn(a), c = 1; c < u.length; c++) {
|
|
4974
4985
|
var f = u[c], h = u[c - 1];
|
|
4975
4986
|
if (l.countSegment(f, h), l.isOnSegment())
|
|
@@ -5003,12 +5014,12 @@ M.signedArea = function() {
|
|
|
5003
5014
|
var u = arguments[0], l = u.size();
|
|
5004
5015
|
if (l < 3)
|
|
5005
5016
|
return 0;
|
|
5006
|
-
var c = new
|
|
5017
|
+
var c = new v(), f = new v(), h = new v();
|
|
5007
5018
|
u.getCoordinate(0, f), u.getCoordinate(1, h);
|
|
5008
5019
|
var g = f.x;
|
|
5009
5020
|
h.x -= g;
|
|
5010
|
-
for (var p = 0,
|
|
5011
|
-
c.y = f.y, f.x = h.x, f.y = h.y, u.getCoordinate(
|
|
5021
|
+
for (var p = 0, y = 1; y < l - 1; y++)
|
|
5022
|
+
c.y = f.y, f.x = h.x, f.y = h.y, u.getCoordinate(y + 1, h), h.x -= g, p += f.x * (c.y - h.y);
|
|
5012
5023
|
return p / 2;
|
|
5013
5024
|
}
|
|
5014
5025
|
};
|
|
@@ -5038,7 +5049,7 @@ M.computeLength = function(t) {
|
|
|
5038
5049
|
var e = t.size();
|
|
5039
5050
|
if (e <= 1)
|
|
5040
5051
|
return 0;
|
|
5041
|
-
var n = 0, i = new
|
|
5052
|
+
var n = 0, i = new v();
|
|
5042
5053
|
t.getCoordinate(0, i);
|
|
5043
5054
|
for (var o = i.x, s = i.y, a = 1; a < e; a++) {
|
|
5044
5055
|
t.getCoordinate(a, i);
|
|
@@ -5454,7 +5465,7 @@ var O = function(r) {
|
|
|
5454
5465
|
var o = this.array_[n];
|
|
5455
5466
|
return this.array_[n] = i, o;
|
|
5456
5467
|
}, t.prototype.iterator = function() {
|
|
5457
|
-
return new
|
|
5468
|
+
return new Gc(this);
|
|
5458
5469
|
}, t.prototype.get = function(n) {
|
|
5459
5470
|
if (n < 0 || n >= this.size())
|
|
5460
5471
|
throw new zs();
|
|
@@ -5475,7 +5486,7 @@ var O = function(r) {
|
|
|
5475
5486
|
}
|
|
5476
5487
|
return o;
|
|
5477
5488
|
}, t;
|
|
5478
|
-
}(qe),
|
|
5489
|
+
}(qe), Gc = function(r) {
|
|
5479
5490
|
function t(e) {
|
|
5480
5491
|
r.call(this), this.arrayList_ = e, this.position_ = 0;
|
|
5481
5492
|
}
|
|
@@ -5531,7 +5542,7 @@ var O = function(r) {
|
|
|
5531
5542
|
if (arguments[0] instanceof Array && typeof arguments[1] == "boolean") {
|
|
5532
5543
|
var s = arguments[0], a = arguments[1];
|
|
5533
5544
|
return this.add(s, a, !0), !0;
|
|
5534
|
-
} else if (arguments[0] instanceof
|
|
5545
|
+
} else if (arguments[0] instanceof v && typeof arguments[1] == "boolean") {
|
|
5535
5546
|
var u = arguments[0], l = arguments[1];
|
|
5536
5547
|
if (!l && this.size() >= 1) {
|
|
5537
5548
|
var c = this.get(this.size() - 1);
|
|
@@ -5545,22 +5556,22 @@ var O = function(r) {
|
|
|
5545
5556
|
}
|
|
5546
5557
|
} else if (arguments.length === 3) {
|
|
5547
5558
|
if (typeof arguments[2] == "boolean" && arguments[0] instanceof Array && typeof arguments[1] == "boolean") {
|
|
5548
|
-
var g = arguments[0], p = arguments[1],
|
|
5549
|
-
if (
|
|
5550
|
-
for (var
|
|
5551
|
-
i.add(g[d], p);
|
|
5552
|
-
else
|
|
5553
|
-
for (var m = g.length - 1; m >= 0; m--)
|
|
5559
|
+
var g = arguments[0], p = arguments[1], y = arguments[2];
|
|
5560
|
+
if (y)
|
|
5561
|
+
for (var m = 0; m < g.length; m++)
|
|
5554
5562
|
i.add(g[m], p);
|
|
5563
|
+
else
|
|
5564
|
+
for (var d = g.length - 1; d >= 0; d--)
|
|
5565
|
+
i.add(g[d], p);
|
|
5555
5566
|
return !0;
|
|
5556
|
-
} else if (typeof arguments[2] == "boolean" && Number.isInteger(arguments[0]) && arguments[1] instanceof
|
|
5557
|
-
var E = arguments[0], C = arguments[1],
|
|
5558
|
-
if (!
|
|
5567
|
+
} else if (typeof arguments[2] == "boolean" && Number.isInteger(arguments[0]) && arguments[1] instanceof v) {
|
|
5568
|
+
var E = arguments[0], C = arguments[1], S = arguments[2];
|
|
5569
|
+
if (!S) {
|
|
5559
5570
|
var N = this.size();
|
|
5560
5571
|
if (N > 0) {
|
|
5561
5572
|
if (E > 0) {
|
|
5562
|
-
var
|
|
5563
|
-
if (
|
|
5573
|
+
var w = this.get(E - 1);
|
|
5574
|
+
if (w.equals2D(C))
|
|
5564
5575
|
return null;
|
|
5565
5576
|
}
|
|
5566
5577
|
if (E < N) {
|
|
@@ -5580,7 +5591,7 @@ var O = function(r) {
|
|
|
5580
5591
|
return !0;
|
|
5581
5592
|
}
|
|
5582
5593
|
}, t.prototype.closeRing = function() {
|
|
5583
|
-
this.size() > 0 && this.add(new
|
|
5594
|
+
this.size() > 0 && this.add(new v(this.get(0)), !1);
|
|
5584
5595
|
}, t.prototype.interfaces_ = function() {
|
|
5585
5596
|
return [];
|
|
5586
5597
|
}, t.prototype.getClass = function() {
|
|
@@ -5680,11 +5691,11 @@ j.removeNull = function(t) {
|
|
|
5680
5691
|
j.copyDeep = function() {
|
|
5681
5692
|
if (arguments.length === 1) {
|
|
5682
5693
|
for (var t = arguments[0], e = new Array(t.length).fill(null), n = 0; n < t.length; n++)
|
|
5683
|
-
e[n] = new
|
|
5694
|
+
e[n] = new v(t[n]);
|
|
5684
5695
|
return e;
|
|
5685
5696
|
} else if (arguments.length === 5)
|
|
5686
5697
|
for (var i = arguments[0], o = arguments[1], s = arguments[2], a = arguments[3], u = arguments[4], l = 0; l < u; l++)
|
|
5687
|
-
s[a + l] = new
|
|
5698
|
+
s[a + l] = new v(i[o + l]);
|
|
5688
5699
|
};
|
|
5689
5700
|
j.isEqualReversed = function(t, e) {
|
|
5690
5701
|
for (var n = 0; n < t.length; n++) {
|
|
@@ -5804,7 +5815,7 @@ gi.prototype.values = function() {
|
|
|
5804
5815
|
};
|
|
5805
5816
|
gi.prototype.entrySet = function() {
|
|
5806
5817
|
};
|
|
5807
|
-
var
|
|
5818
|
+
var Vc = function(r) {
|
|
5808
5819
|
function t() {
|
|
5809
5820
|
r.apply(this, arguments);
|
|
5810
5821
|
}
|
|
@@ -5848,9 +5859,9 @@ var Us = function(r) {
|
|
|
5848
5859
|
i.push(n.array_[o]);
|
|
5849
5860
|
return i;
|
|
5850
5861
|
}, t.prototype.iterator = function() {
|
|
5851
|
-
return new
|
|
5862
|
+
return new zc(this);
|
|
5852
5863
|
}, t;
|
|
5853
|
-
}(es),
|
|
5864
|
+
}(es), zc = function(r) {
|
|
5854
5865
|
function t(e) {
|
|
5855
5866
|
r.call(this), this.hashSet_ = e, this.position_ = 0;
|
|
5856
5867
|
}
|
|
@@ -5882,7 +5893,7 @@ function Ra(r) {
|
|
|
5882
5893
|
function Kt() {
|
|
5883
5894
|
this.root_ = null, this.size_ = 0;
|
|
5884
5895
|
}
|
|
5885
|
-
Kt.prototype = new
|
|
5896
|
+
Kt.prototype = new Vc();
|
|
5886
5897
|
Kt.prototype.get = function(r) {
|
|
5887
5898
|
for (var t = this.root_; t !== null; ) {
|
|
5888
5899
|
var e = r.compareTo(t.key);
|
|
@@ -6274,9 +6285,9 @@ var ie = function(r) {
|
|
|
6274
6285
|
return this.compare(s, a);
|
|
6275
6286
|
} else if (arguments.length === 2) {
|
|
6276
6287
|
for (var u = arguments[0], l = arguments[1], c = u, f = this.getNumGeometries(), h = c.getNumGeometries(), g = 0; g < f && g < h; ) {
|
|
6277
|
-
var p = i.getGeometryN(g),
|
|
6278
|
-
if (
|
|
6279
|
-
return
|
|
6288
|
+
var p = i.getGeometryN(g), y = c.getGeometryN(g), m = p.compareToSameClass(y, l);
|
|
6289
|
+
if (m !== 0)
|
|
6290
|
+
return m;
|
|
6280
6291
|
g++;
|
|
6281
6292
|
}
|
|
6282
6293
|
return g < f ? 1 : g < h ? -1 : 0;
|
|
@@ -6446,18 +6457,18 @@ Uo.prototype.interfaces_ = function() {
|
|
|
6446
6457
|
Uo.prototype.getClass = function() {
|
|
6447
6458
|
return Uo;
|
|
6448
6459
|
};
|
|
6449
|
-
function zc() {
|
|
6450
|
-
}
|
|
6451
6460
|
function Uc() {
|
|
6452
6461
|
}
|
|
6453
|
-
|
|
6454
|
-
};
|
|
6455
|
-
function Xc() {
|
|
6462
|
+
function qc() {
|
|
6456
6463
|
}
|
|
6464
|
+
var Xc = function() {
|
|
6465
|
+
};
|
|
6457
6466
|
function Yc() {
|
|
6458
6467
|
}
|
|
6459
6468
|
function Wc() {
|
|
6460
6469
|
}
|
|
6470
|
+
function Hc() {
|
|
6471
|
+
}
|
|
6461
6472
|
var Te = function() {
|
|
6462
6473
|
}, qs = { NEWLINE: { configurable: !0 }, SIMPLE_ORDINATE_FORMAT: { configurable: !0 } };
|
|
6463
6474
|
Te.prototype.interfaces_ = function() {
|
|
@@ -6473,16 +6484,16 @@ Te.chars = function(t, e) {
|
|
|
6473
6484
|
};
|
|
6474
6485
|
Te.getStackTrace = function() {
|
|
6475
6486
|
if (arguments.length === 1) {
|
|
6476
|
-
var t = arguments[0], e = new
|
|
6487
|
+
var t = arguments[0], e = new Yc(), n = new Uc();
|
|
6477
6488
|
return t.printStackTrace(n), e.toString();
|
|
6478
6489
|
} else if (arguments.length === 2) {
|
|
6479
6490
|
var i = arguments[0], o = arguments[1], s = "";
|
|
6480
|
-
new
|
|
6481
|
-
for (var a = new
|
|
6491
|
+
new qc(Te.getStackTrace(i));
|
|
6492
|
+
for (var a = new Hc(), u = 0; u < o; u++)
|
|
6482
6493
|
try {
|
|
6483
6494
|
s += a.readLine() + Te.NEWLINE;
|
|
6484
6495
|
} catch (l) {
|
|
6485
|
-
if (l instanceof
|
|
6496
|
+
if (l instanceof Wc)
|
|
6486
6497
|
q.shouldNeverReachHere();
|
|
6487
6498
|
else
|
|
6488
6499
|
throw l;
|
|
@@ -6514,7 +6525,7 @@ qs.NEWLINE.get = function() {
|
|
|
6514
6525
|
return qt.getProperty("line.separator");
|
|
6515
6526
|
};
|
|
6516
6527
|
qs.SIMPLE_ORDINATE_FORMAT.get = function() {
|
|
6517
|
-
return new
|
|
6528
|
+
return new Xc();
|
|
6518
6529
|
};
|
|
6519
6530
|
Object.defineProperties(Te, qs);
|
|
6520
6531
|
var Ct = function() {
|
|
@@ -6871,8 +6882,8 @@ var Ot = function(r) {
|
|
|
6871
6882
|
return !1;
|
|
6872
6883
|
}
|
|
6873
6884
|
for (var l = i.getX(0), c = i.getY(0), f = 1; f <= 4; f++) {
|
|
6874
|
-
var h = i.getX(f), g = i.getY(f), p = h !== l,
|
|
6875
|
-
if (p ===
|
|
6885
|
+
var h = i.getX(f), g = i.getY(f), p = h !== l, y = g !== c;
|
|
6886
|
+
if (p === y)
|
|
6876
6887
|
return !1;
|
|
6877
6888
|
l = h, c = g;
|
|
6878
6889
|
}
|
|
@@ -6943,13 +6954,13 @@ var Ot = function(r) {
|
|
|
6943
6954
|
var u = arguments[0], l = arguments[1], c = u, f = this._shell, h = c._shell, g = f.compareToSameClass(h, l);
|
|
6944
6955
|
if (g !== 0)
|
|
6945
6956
|
return g;
|
|
6946
|
-
for (var p = this.getNumInteriorRing(),
|
|
6947
|
-
var
|
|
6957
|
+
for (var p = this.getNumInteriorRing(), y = c.getNumInteriorRing(), m = 0; m < p && m < y; ) {
|
|
6958
|
+
var d = i.getInteriorRingN(m), E = c.getInteriorRingN(m), C = d.compareToSameClass(E, l);
|
|
6948
6959
|
if (C !== 0)
|
|
6949
6960
|
return C;
|
|
6950
|
-
|
|
6961
|
+
m++;
|
|
6951
6962
|
}
|
|
6952
|
-
return
|
|
6963
|
+
return m < p ? 1 : m < y ? -1 : 0;
|
|
6953
6964
|
}
|
|
6954
6965
|
}, t.prototype.apply = function(i) {
|
|
6955
6966
|
var o = this;
|
|
@@ -7046,7 +7057,7 @@ var Ot = function(r) {
|
|
|
7046
7057
|
}, Object.defineProperties(t, e), t;
|
|
7047
7058
|
}(ie), bn = function(r) {
|
|
7048
7059
|
function t(n, i) {
|
|
7049
|
-
n instanceof
|
|
7060
|
+
n instanceof v && i instanceof H && (n = i.getCoordinateSequenceFactory().create(n)), r.call(this, n, i), this.validateConstruction();
|
|
7050
7061
|
}
|
|
7051
7062
|
r && (t.__proto__ = r), t.prototype = Object.create(r && r.prototype), t.prototype.constructor = t;
|
|
7052
7063
|
var e = { MINIMUM_VALID_SIZE: { configurable: !0 }, serialVersionUID: { configurable: !0 } };
|
|
@@ -7219,7 +7230,7 @@ var _t = function() {
|
|
|
7219
7230
|
var e = arguments[0];
|
|
7220
7231
|
this._coordinates = new Array(e).fill(null);
|
|
7221
7232
|
for (var n = 0; n < e; n++)
|
|
7222
|
-
t._coordinates[n] = new
|
|
7233
|
+
t._coordinates[n] = new v();
|
|
7223
7234
|
} else if (V(arguments[0], Q)) {
|
|
7224
7235
|
var i = arguments[0];
|
|
7225
7236
|
if (i === null)
|
|
@@ -7236,7 +7247,7 @@ var _t = function() {
|
|
|
7236
7247
|
var u = arguments[0], l = arguments[1];
|
|
7237
7248
|
this._coordinates = new Array(u).fill(null), this._dimension = l;
|
|
7238
7249
|
for (var c = 0; c < u; c++)
|
|
7239
|
-
t._coordinates[c] = new
|
|
7250
|
+
t._coordinates[c] = new v();
|
|
7240
7251
|
}
|
|
7241
7252
|
}
|
|
7242
7253
|
}, mu = { serialVersionUID: { configurable: !0 } };
|
|
@@ -7279,7 +7290,7 @@ _t.prototype.getCoordinate = function() {
|
|
|
7279
7290
|
}
|
|
7280
7291
|
};
|
|
7281
7292
|
_t.prototype.getCoordinateCopy = function(t) {
|
|
7282
|
-
return new
|
|
7293
|
+
return new v(this._coordinates[t]);
|
|
7283
7294
|
};
|
|
7284
7295
|
_t.prototype.getDimension = function() {
|
|
7285
7296
|
return this._dimension;
|
|
@@ -7433,7 +7444,7 @@ $.prototype.makePrecise = function() {
|
|
|
7433
7444
|
return e;
|
|
7434
7445
|
}
|
|
7435
7446
|
return this._modelType === $.FIXED ? Math.round(t * this._scale) / this._scale : t;
|
|
7436
|
-
} else if (arguments[0] instanceof
|
|
7447
|
+
} else if (arguments[0] instanceof v) {
|
|
7437
7448
|
var n = arguments[0];
|
|
7438
7449
|
if (this._modelType === $.FLOATING)
|
|
7439
7450
|
return null;
|
|
@@ -7493,7 +7504,7 @@ var H = function r() {
|
|
|
7493
7504
|
this._precisionModel = new $(), this._SRID = 0, this._coordinateSequenceFactory = r.getDefaultCoordinateSequenceFactory(), arguments.length === 0 || (arguments.length === 1 ? V(arguments[0], Ci) ? this._coordinateSequenceFactory = arguments[0] : arguments[0] instanceof $ && (this._precisionModel = arguments[0]) : arguments.length === 2 ? (this._precisionModel = arguments[0], this._SRID = arguments[1]) : arguments.length === 3 && (this._precisionModel = arguments[0], this._SRID = arguments[1], this._coordinateSequenceFactory = arguments[2]));
|
|
7494
7505
|
}, Eu = { serialVersionUID: { configurable: !0 } };
|
|
7495
7506
|
H.prototype.toGeometry = function(t) {
|
|
7496
|
-
return t.isNull() ? this.createPoint(null) : t.getMinX() === t.getMaxX() && t.getMinY() === t.getMaxY() ? this.createPoint(new
|
|
7507
|
+
return t.isNull() ? this.createPoint(null) : t.getMinX() === t.getMaxX() && t.getMinY() === t.getMaxY() ? this.createPoint(new v(t.getMinX(), t.getMinY())) : t.getMinX() === t.getMaxX() || t.getMinY() === t.getMaxY() ? this.createLineString([new v(t.getMinX(), t.getMinY()), new v(t.getMaxX(), t.getMaxY())]) : this.createPolygon(this.createLinearRing([new v(t.getMinX(), t.getMinY()), new v(t.getMinX(), t.getMaxY()), new v(t.getMaxX(), t.getMaxY()), new v(t.getMaxX(), t.getMinY()), new v(t.getMinX(), t.getMinY())]), null);
|
|
7497
7508
|
};
|
|
7498
7509
|
H.prototype.createLineString = function(t) {
|
|
7499
7510
|
if (t) {
|
|
@@ -7540,7 +7551,7 @@ H.prototype.createPoint = function() {
|
|
|
7540
7551
|
if (arguments.length === 0)
|
|
7541
7552
|
return this.createPoint(this.getCoordinateSequenceFactory().create([]));
|
|
7542
7553
|
if (arguments.length === 1) {
|
|
7543
|
-
if (arguments[0] instanceof
|
|
7554
|
+
if (arguments[0] instanceof v) {
|
|
7544
7555
|
var t = arguments[0];
|
|
7545
7556
|
return this.createPoint(t !== null ? this.getCoordinateSequenceFactory().create([t]) : null);
|
|
7546
7557
|
} else if (V(arguments[0], Q)) {
|
|
@@ -7690,7 +7701,7 @@ Eu.serialVersionUID.get = function() {
|
|
|
7690
7701
|
return -6820524753094096e3;
|
|
7691
7702
|
};
|
|
7692
7703
|
Object.defineProperties(H, Eu);
|
|
7693
|
-
var
|
|
7704
|
+
var jc = ["Point", "MultiPoint", "LineString", "MultiLineString", "Polygon", "MultiPolygon"], is = function(t) {
|
|
7694
7705
|
this.geometryFactory = t || new H();
|
|
7695
7706
|
};
|
|
7696
7707
|
is.prototype.read = function(t) {
|
|
@@ -7699,7 +7710,7 @@ is.prototype.read = function(t) {
|
|
|
7699
7710
|
var n = e.type;
|
|
7700
7711
|
if (!en[n])
|
|
7701
7712
|
throw new Error("Unknown GeoJSON type: " + e.type);
|
|
7702
|
-
return
|
|
7713
|
+
return jc.indexOf(n) !== -1 ? en[n].apply(this, [e.coordinates]) : n === "GeometryCollection" ? en[n].apply(this, [e.geometries]) : en[n].apply(this, [e]);
|
|
7703
7714
|
};
|
|
7704
7715
|
is.prototype.write = function(t) {
|
|
7705
7716
|
var e = t.getGeometryType();
|
|
@@ -7756,7 +7767,7 @@ var en = {
|
|
|
7756
7767
|
coordinates: function(r) {
|
|
7757
7768
|
for (var t = [], e = 0; e < r.length; ++e) {
|
|
7758
7769
|
var n = r[e];
|
|
7759
|
-
t.push(new
|
|
7770
|
+
t.push(new v(n[0], n[1]));
|
|
7760
7771
|
}
|
|
7761
7772
|
return t;
|
|
7762
7773
|
},
|
|
@@ -7770,11 +7781,11 @@ var en = {
|
|
|
7770
7781
|
*/
|
|
7771
7782
|
bbox: function(r) {
|
|
7772
7783
|
return this.geometryFactory.createLinearRing([
|
|
7773
|
-
new
|
|
7774
|
-
new
|
|
7775
|
-
new
|
|
7776
|
-
new
|
|
7777
|
-
new
|
|
7784
|
+
new v(r[0], r[1]),
|
|
7785
|
+
new v(r[2], r[1]),
|
|
7786
|
+
new v(r[2], r[3]),
|
|
7787
|
+
new v(r[0], r[3]),
|
|
7788
|
+
new v(r[0], r[1])
|
|
7778
7789
|
]);
|
|
7779
7790
|
},
|
|
7780
7791
|
/**
|
|
@@ -7786,7 +7797,7 @@ var en = {
|
|
|
7786
7797
|
* @return {Point} Point.
|
|
7787
7798
|
*/
|
|
7788
7799
|
Point: function(r) {
|
|
7789
|
-
var t = new
|
|
7800
|
+
var t = new v(r[0], r[1]);
|
|
7790
7801
|
return this.geometryFactory.createPoint(t);
|
|
7791
7802
|
},
|
|
7792
7803
|
/**
|
|
@@ -8152,7 +8163,7 @@ hn.prototype.getClass = function() {
|
|
|
8152
8163
|
};
|
|
8153
8164
|
var Zn = function(r) {
|
|
8154
8165
|
function t(e, n) {
|
|
8155
|
-
r.call(this, t.msgWithCoord(e, n)), this.pt = n ? new
|
|
8166
|
+
r.call(this, t.msgWithCoord(e, n)), this.pt = n ? new v(n) : null, this.name = "TopologyException";
|
|
8156
8167
|
}
|
|
8157
8168
|
return r && (t.__proto__ = r), t.prototype = Object.create(r && r.prototype), t.prototype.constructor = t, t.prototype.getCoordinate = function() {
|
|
8158
8169
|
return this.pt;
|
|
@@ -8605,7 +8616,7 @@ wt.prototype.interfaces_ = function() {
|
|
|
8605
8616
|
wt.prototype.getClass = function() {
|
|
8606
8617
|
return wt;
|
|
8607
8618
|
};
|
|
8608
|
-
var
|
|
8619
|
+
var Kc = function(r) {
|
|
8609
8620
|
function t() {
|
|
8610
8621
|
var e = arguments[0], n = arguments[1];
|
|
8611
8622
|
r.call(this, e, n);
|
|
@@ -8619,7 +8630,7 @@ var jc = function(r) {
|
|
|
8619
8630
|
}, t.prototype.getClass = function() {
|
|
8620
8631
|
return t;
|
|
8621
8632
|
}, t;
|
|
8622
|
-
}(wt),
|
|
8633
|
+
}(wt), Qc = function(r) {
|
|
8623
8634
|
function t() {
|
|
8624
8635
|
var e = arguments[0], n = arguments[1];
|
|
8625
8636
|
r.call(this, e, n);
|
|
@@ -8628,7 +8639,7 @@ var jc = function(r) {
|
|
|
8628
8639
|
var n = this, i = new O(), o = this._startDe;
|
|
8629
8640
|
do {
|
|
8630
8641
|
if (o.getMinEdgeRing() === null) {
|
|
8631
|
-
var s = new
|
|
8642
|
+
var s = new Kc(o, n._geometryFactory);
|
|
8632
8643
|
i.add(s);
|
|
8633
8644
|
}
|
|
8634
8645
|
o = o.getNext();
|
|
@@ -8772,7 +8783,7 @@ gn.prototype.find = function(t) {
|
|
|
8772
8783
|
return this.nodeMap.get(t);
|
|
8773
8784
|
};
|
|
8774
8785
|
gn.prototype.addNode = function() {
|
|
8775
|
-
if (arguments[0] instanceof
|
|
8786
|
+
if (arguments[0] instanceof v) {
|
|
8776
8787
|
var t = arguments[0], e = this.nodeMap.get(t);
|
|
8777
8788
|
return e === null && (e = this.nodeFact.createNode(t), this.nodeMap.put(t, e)), e;
|
|
8778
8789
|
} else if (arguments[0] instanceof us) {
|
|
@@ -8844,7 +8855,7 @@ rt.quadrant = function() {
|
|
|
8844
8855
|
if (t === 0 && e === 0)
|
|
8845
8856
|
throw new ft("Cannot compute the quadrant for point ( " + t + ", " + e + " )");
|
|
8846
8857
|
return t >= 0 ? e >= 0 ? rt.NE : rt.SE : e >= 0 ? rt.NW : rt.SW;
|
|
8847
|
-
} else if (arguments[0] instanceof
|
|
8858
|
+
} else if (arguments[0] instanceof v && arguments[1] instanceof v) {
|
|
8848
8859
|
var n = arguments[0], i = arguments[1];
|
|
8849
8860
|
if (i.x === n.x && i.y === n.y)
|
|
8850
8861
|
throw new ft("Cannot compute the quadrant for two identical points " + n);
|
|
@@ -9045,7 +9056,7 @@ pt.prototype.addNode = function() {
|
|
|
9045
9056
|
if (arguments[0] instanceof us) {
|
|
9046
9057
|
var t = arguments[0];
|
|
9047
9058
|
return this._nodes.addNode(t);
|
|
9048
|
-
} else if (arguments[0] instanceof
|
|
9059
|
+
} else if (arguments[0] instanceof v) {
|
|
9049
9060
|
var e = arguments[0];
|
|
9050
9061
|
return this._nodes.addNode(e);
|
|
9051
9062
|
}
|
|
@@ -9193,7 +9204,7 @@ ve.prototype.buildMaximalEdgeRings = function(t) {
|
|
|
9193
9204
|
for (var e = this, n = new O(), i = t.iterator(); i.hasNext(); ) {
|
|
9194
9205
|
var o = i.next();
|
|
9195
9206
|
if (o.isInResult() && o.getLabel().isArea() && o.getEdgeRing() === null) {
|
|
9196
|
-
var s = new
|
|
9207
|
+
var s = new Qc(o, e._geometryFactory);
|
|
9197
9208
|
n.add(s), s.setInResult();
|
|
9198
9209
|
}
|
|
9199
9210
|
}
|
|
@@ -9527,9 +9538,9 @@ Mt.prototype.query = function() {
|
|
|
9527
9538
|
t.getIntersectsOp().intersects(f.getBounds(), s) && (f instanceof Rt ? t.query(s, f, u) : f instanceof We ? u.visitItem(f.getItem()) : q.shouldNeverReachHere());
|
|
9528
9539
|
}
|
|
9529
9540
|
else if (V(arguments[2], qe) && arguments[0] instanceof Object && arguments[1] instanceof Rt)
|
|
9530
|
-
for (var h = arguments[0], g = arguments[1], p = arguments[2],
|
|
9531
|
-
var
|
|
9532
|
-
t.getIntersectsOp().intersects(
|
|
9541
|
+
for (var h = arguments[0], g = arguments[1], p = arguments[2], y = g.getChildBoundables(), m = 0; m < y.size(); m++) {
|
|
9542
|
+
var d = y.get(m);
|
|
9543
|
+
t.getIntersectsOp().intersects(d.getBounds(), h) && (d instanceof Rt ? t.query(h, d, p) : d instanceof We ? p.add(d.getItem()) : q.shouldNeverReachHere());
|
|
9533
9544
|
}
|
|
9534
9545
|
}
|
|
9535
9546
|
};
|
|
@@ -9606,7 +9617,7 @@ Mt.compareDoubles = function(t, e) {
|
|
|
9606
9617
|
return t > e ? 1 : t < e ? -1 : 0;
|
|
9607
9618
|
};
|
|
9608
9619
|
ls.IntersectsOp.get = function() {
|
|
9609
|
-
return
|
|
9620
|
+
return Zc;
|
|
9610
9621
|
};
|
|
9611
9622
|
ls.serialVersionUID.get = function() {
|
|
9612
9623
|
return -3886435814360241e3;
|
|
@@ -9615,7 +9626,7 @@ ls.DEFAULT_NODE_CAPACITY.get = function() {
|
|
|
9615
9626
|
return 10;
|
|
9616
9627
|
};
|
|
9617
9628
|
Object.defineProperties(Mt, ls);
|
|
9618
|
-
var
|
|
9629
|
+
var Zc = function() {
|
|
9619
9630
|
}, Oi = function() {
|
|
9620
9631
|
};
|
|
9621
9632
|
Oi.prototype.distance = function(t, e) {
|
|
@@ -9711,15 +9722,15 @@ var Nu = function(r) {
|
|
|
9711
9722
|
} else if (arguments[0] instanceof xt && typeof arguments[1] == "number") {
|
|
9712
9723
|
var c = arguments[0], f = arguments[1], h = f, g = null, p = new Jn();
|
|
9713
9724
|
for (p.add(c); !p.isEmpty() && h > 0; ) {
|
|
9714
|
-
var
|
|
9715
|
-
if (
|
|
9725
|
+
var y = p.poll(), m = y.getDistance();
|
|
9726
|
+
if (m >= h)
|
|
9716
9727
|
break;
|
|
9717
|
-
|
|
9728
|
+
y.isLeaves() ? (h = m, g = y) : y.expandToQueue(p, h);
|
|
9718
9729
|
}
|
|
9719
9730
|
return [g.getBoundable(0).getItem(), g.getBoundable(1).getItem()];
|
|
9720
9731
|
}
|
|
9721
9732
|
} else if (arguments.length === 3) {
|
|
9722
|
-
var
|
|
9733
|
+
var d = arguments[0], E = arguments[1], C = arguments[2], S = new We(d, E), N = new xt(this.getRoot(), S, C);
|
|
9723
9734
|
return this.nearestNeighbour(N)[0];
|
|
9724
9735
|
}
|
|
9725
9736
|
}, t.prototype.interfaces_ = function() {
|
|
@@ -9823,7 +9834,7 @@ ue.compareValue = function(t, e) {
|
|
|
9823
9834
|
var hr = function() {
|
|
9824
9835
|
this._segString = null, this.coord = null, this.segmentIndex = null, this._segmentOctant = null, this._isInterior = null;
|
|
9825
9836
|
var t = arguments[0], e = arguments[1], n = arguments[2], i = arguments[3];
|
|
9826
|
-
this._segString = t, this.coord = new
|
|
9837
|
+
this._segString = t, this.coord = new v(e), this.segmentIndex = n, this._segmentOctant = i, this._isInterior = !e.equals2D(t.getCoordinate(n));
|
|
9827
9838
|
};
|
|
9828
9839
|
hr.prototype.getCoordinate = function() {
|
|
9829
9840
|
return this.coord;
|
|
@@ -9884,10 +9895,10 @@ se.prototype.findCollapsesFromExistingVertices = function(t) {
|
|
|
9884
9895
|
};
|
|
9885
9896
|
se.prototype.addEdgeCoordinates = function(t, e, n) {
|
|
9886
9897
|
var i = this, o = this._edge.getCoordinate(e.segmentIndex), s = e.isInterior() || !e.coord.equals2D(o);
|
|
9887
|
-
n.add(new
|
|
9898
|
+
n.add(new v(t.coord), !1);
|
|
9888
9899
|
for (var a = t.segmentIndex + 1; a <= e.segmentIndex; a++)
|
|
9889
9900
|
n.add(i._edge.getCoordinate(a));
|
|
9890
|
-
s && n.add(new
|
|
9901
|
+
s && n.add(new v(e.coord));
|
|
9891
9902
|
};
|
|
9892
9903
|
se.prototype.iterator = function() {
|
|
9893
9904
|
return this._nodeMap.values().iterator();
|
|
@@ -9923,10 +9934,10 @@ se.prototype.createSplitEdge = function(t, e) {
|
|
|
9923
9934
|
var n = this, i = e.segmentIndex - t.segmentIndex + 2, o = this._edge.getCoordinate(e.segmentIndex), s = e.isInterior() || !e.coord.equals2D(o);
|
|
9924
9935
|
s || i--;
|
|
9925
9936
|
var a = new Array(i).fill(null), u = 0;
|
|
9926
|
-
a[u++] = new
|
|
9937
|
+
a[u++] = new v(t.coord);
|
|
9927
9938
|
for (var l = t.segmentIndex + 1; l <= e.segmentIndex; l++)
|
|
9928
9939
|
a[u++] = n._edge.getCoordinate(l);
|
|
9929
|
-
return s && (a[u] = new
|
|
9940
|
+
return s && (a[u] = new v(e.coord)), new Nt(a, this._edge.getData());
|
|
9930
9941
|
};
|
|
9931
9942
|
se.prototype.add = function(t, e) {
|
|
9932
9943
|
var n = new hr(this._edge, t, e, this._edge.getSegmentOctant(e)), i = this._nodeMap.get(n);
|
|
@@ -9961,7 +9972,7 @@ ti.octant = function() {
|
|
|
9961
9972
|
throw new ft("Cannot compute the octant for point ( " + t + ", " + e + " )");
|
|
9962
9973
|
var n = Math.abs(t), i = Math.abs(e);
|
|
9963
9974
|
return t >= 0 ? e >= 0 ? n >= i ? 0 : 1 : n >= i ? 7 : 6 : e >= 0 ? n >= i ? 3 : 2 : n >= i ? 4 : 5;
|
|
9964
|
-
} else if (arguments[0] instanceof
|
|
9975
|
+
} else if (arguments[0] instanceof v && arguments[1] instanceof v) {
|
|
9965
9976
|
var o = arguments[0], s = arguments[1], a = s.x - o.x, u = s.y - o.y;
|
|
9966
9977
|
if (a === 0 && u === 0)
|
|
9967
9978
|
throw new ft("Cannot compute the octant for two identical points " + o);
|
|
@@ -10032,7 +10043,7 @@ Nt.prototype.addIntersection = function() {
|
|
|
10032
10043
|
var t = arguments[0], e = arguments[1];
|
|
10033
10044
|
this.addIntersectionNode(t, e);
|
|
10034
10045
|
} else if (arguments.length === 4) {
|
|
10035
|
-
var n = arguments[0], i = arguments[1], o = arguments[3], s = new
|
|
10046
|
+
var n = arguments[0], i = arguments[1], o = arguments[3], s = new v(n.getIntersection(o));
|
|
10036
10047
|
this.addIntersection(s, i);
|
|
10037
10048
|
}
|
|
10038
10049
|
};
|
|
@@ -10073,15 +10084,15 @@ Nt.getNodedSubstrings = function() {
|
|
|
10073
10084
|
};
|
|
10074
10085
|
var B = function() {
|
|
10075
10086
|
if (this.p0 = null, this.p1 = null, arguments.length === 0)
|
|
10076
|
-
this.p0 = new
|
|
10087
|
+
this.p0 = new v(), this.p1 = new v();
|
|
10077
10088
|
else if (arguments.length === 1) {
|
|
10078
10089
|
var t = arguments[0];
|
|
10079
|
-
this.p0 = new
|
|
10090
|
+
this.p0 = new v(t.p0), this.p1 = new v(t.p1);
|
|
10080
10091
|
} else if (arguments.length === 2)
|
|
10081
10092
|
this.p0 = arguments[0], this.p1 = arguments[1];
|
|
10082
10093
|
else if (arguments.length === 4) {
|
|
10083
10094
|
var e = arguments[0], n = arguments[1], i = arguments[2], o = arguments[3];
|
|
10084
|
-
this.p0 = new
|
|
10095
|
+
this.p0 = new v(e, n), this.p1 = new v(i, o);
|
|
10085
10096
|
}
|
|
10086
10097
|
}, xu = { serialVersionUID: { configurable: !0 } };
|
|
10087
10098
|
B.prototype.minX = function() {
|
|
@@ -10091,7 +10102,7 @@ B.prototype.orientationIndex = function() {
|
|
|
10091
10102
|
if (arguments[0] instanceof B) {
|
|
10092
10103
|
var t = arguments[0], e = M.orientationIndex(this.p0, this.p1, t.p0), n = M.orientationIndex(this.p0, this.p1, t.p1);
|
|
10093
10104
|
return e >= 0 && n >= 0 || e <= 0 && n <= 0 ? Math.max(e, n) : 0;
|
|
10094
|
-
} else if (arguments[0] instanceof
|
|
10105
|
+
} else if (arguments[0] instanceof v) {
|
|
10095
10106
|
var i = arguments[0];
|
|
10096
10107
|
return M.orientationIndex(this.p0, this.p1, i);
|
|
10097
10108
|
}
|
|
@@ -10113,11 +10124,11 @@ B.prototype.intersection = function(t) {
|
|
|
10113
10124
|
return e.computeIntersection(this.p0, this.p1, t.p0, t.p1), e.hasIntersection() ? e.getIntersection(0) : null;
|
|
10114
10125
|
};
|
|
10115
10126
|
B.prototype.project = function() {
|
|
10116
|
-
if (arguments[0] instanceof
|
|
10127
|
+
if (arguments[0] instanceof v) {
|
|
10117
10128
|
var t = arguments[0];
|
|
10118
10129
|
if (t.equals(this.p0) || t.equals(this.p1))
|
|
10119
|
-
return new
|
|
10120
|
-
var e = this.projectionFactor(t), n = new
|
|
10130
|
+
return new v(t);
|
|
10131
|
+
var e = this.projectionFactor(t), n = new v();
|
|
10121
10132
|
return n.x = this.p0.x + e * (this.p1.x - this.p0.x), n.y = this.p0.y + e * (this.p1.y - this.p0.y), n;
|
|
10122
10133
|
} else if (arguments[0] instanceof B) {
|
|
10123
10134
|
var i = arguments[0], o = this.projectionFactor(i.p0), s = this.projectionFactor(i.p1);
|
|
@@ -10216,7 +10227,7 @@ B.prototype.pointAlongOffset = function(t, e) {
|
|
|
10216
10227
|
throw new Error("Cannot compute offset from zero-length line segment");
|
|
10217
10228
|
u = e * o / a, l = e * s / a;
|
|
10218
10229
|
}
|
|
10219
|
-
var c = n - l, f = i + u, h = new
|
|
10230
|
+
var c = n - l, f = i + u, h = new v(c, f);
|
|
10220
10231
|
return h;
|
|
10221
10232
|
};
|
|
10222
10233
|
B.prototype.setCoordinates = function() {
|
|
@@ -10242,13 +10253,13 @@ B.prototype.distance = function() {
|
|
|
10242
10253
|
if (arguments[0] instanceof B) {
|
|
10243
10254
|
var t = arguments[0];
|
|
10244
10255
|
return M.distanceLineLine(this.p0, this.p1, t.p0, t.p1);
|
|
10245
|
-
} else if (arguments[0] instanceof
|
|
10256
|
+
} else if (arguments[0] instanceof v) {
|
|
10246
10257
|
var e = arguments[0];
|
|
10247
10258
|
return M.distancePointLine(e, this.p0, this.p1);
|
|
10248
10259
|
}
|
|
10249
10260
|
};
|
|
10250
10261
|
B.prototype.pointAlong = function(t) {
|
|
10251
|
-
var e = new
|
|
10262
|
+
var e = new v();
|
|
10252
10263
|
return e.x = this.p0.x + t * (this.p1.x - this.p0.x), e.y = this.p0.y + t * (this.p1.y - this.p0.y), e;
|
|
10253
10264
|
};
|
|
10254
10265
|
B.prototype.hashCode = function() {
|
|
@@ -10266,7 +10277,7 @@ B.prototype.getClass = function() {
|
|
|
10266
10277
|
return B;
|
|
10267
10278
|
};
|
|
10268
10279
|
B.midPoint = function(t, e) {
|
|
10269
|
-
return new
|
|
10280
|
+
return new v((t.x + e.x) / 2, (t.y + e.y) / 2);
|
|
10270
10281
|
};
|
|
10271
10282
|
xu.serialVersionUID.get = function() {
|
|
10272
10283
|
return 3252005833466256400;
|
|
@@ -10665,7 +10676,7 @@ be.prototype.setPrecisionModel = function(t) {
|
|
|
10665
10676
|
this._precisionModel = t;
|
|
10666
10677
|
};
|
|
10667
10678
|
be.prototype.addPt = function(t) {
|
|
10668
|
-
var e = new
|
|
10679
|
+
var e = new v(t);
|
|
10669
10680
|
if (this._precisionModel.makePrecise(e), this.isRedundant(e))
|
|
10670
10681
|
return null;
|
|
10671
10682
|
this._ptList.add(e);
|
|
@@ -10694,7 +10705,7 @@ be.prototype.toString = function() {
|
|
|
10694
10705
|
be.prototype.closeRing = function() {
|
|
10695
10706
|
if (this._ptList.size() < 1)
|
|
10696
10707
|
return null;
|
|
10697
|
-
var t = new
|
|
10708
|
+
var t = new v(this._ptList.get(0)), e = this._ptList.get(this._ptList.size() - 1);
|
|
10698
10709
|
if (t.equals(e))
|
|
10699
10710
|
return null;
|
|
10700
10711
|
this._ptList.add(t);
|
|
@@ -10826,9 +10837,9 @@ lt.prototype.addLineEndCap = function(t, e) {
|
|
|
10826
10837
|
this._segList.addPt(i.p1), this._segList.addPt(o.p1);
|
|
10827
10838
|
break;
|
|
10828
10839
|
case J.CAP_SQUARE:
|
|
10829
|
-
var l = new
|
|
10840
|
+
var l = new v();
|
|
10830
10841
|
l.x = Math.abs(this._distance) * Math.cos(u), l.y = Math.abs(this._distance) * Math.sin(u);
|
|
10831
|
-
var c = new
|
|
10842
|
+
var c = new v(i.p1.x + l.x, i.p1.y + l.y), f = new v(o.p1.x + l.x, o.p1.y + l.y);
|
|
10832
10843
|
this._segList.addPt(c), this._segList.addPt(f);
|
|
10833
10844
|
break;
|
|
10834
10845
|
}
|
|
@@ -10845,7 +10856,7 @@ lt.prototype.addMitreJoin = function(t, e, n, i) {
|
|
|
10845
10856
|
a > this._bufParams.getMitreLimit() && (o = !1);
|
|
10846
10857
|
} catch (u) {
|
|
10847
10858
|
if (u instanceof Ui)
|
|
10848
|
-
s = new
|
|
10859
|
+
s = new v(0, 0), o = !1;
|
|
10849
10860
|
else
|
|
10850
10861
|
throw u;
|
|
10851
10862
|
} finally {
|
|
@@ -10862,7 +10873,7 @@ lt.prototype.addOutsideTurn = function(t, e) {
|
|
|
10862
10873
|
this._bufParams.getJoinStyle() === J.JOIN_MITRE ? this.addMitreJoin(this._s1, this._offset0, this._offset1, this._distance) : this._bufParams.getJoinStyle() === J.JOIN_BEVEL ? this.addBevelJoin(this._offset0, this._offset1) : (e && this._segList.addPt(this._offset0.p1), this.addFilletCorner(this._s1, this._offset0.p1, this._offset1.p0, t, this._distance), this._segList.addPt(this._offset1.p0));
|
|
10863
10874
|
};
|
|
10864
10875
|
lt.prototype.createSquare = function(t) {
|
|
10865
|
-
this._segList.addPt(new
|
|
10876
|
+
this._segList.addPt(new v(t.x + this._distance, t.y + this._distance)), this._segList.addPt(new v(t.x + this._distance, t.y - this._distance)), this._segList.addPt(new v(t.x - this._distance, t.y - this._distance)), this._segList.addPt(new v(t.x - this._distance, t.y + this._distance)), this._segList.closeRing();
|
|
10866
10877
|
};
|
|
10867
10878
|
lt.prototype.addSegments = function(t, e) {
|
|
10868
10879
|
this._segList.addPts(t, e);
|
|
@@ -10877,7 +10888,7 @@ lt.prototype.initSideSegments = function(t, e, n) {
|
|
|
10877
10888
|
this._s1 = t, this._s2 = e, this._side = n, this._seg1.setCoordinates(t, e), this.computeOffsetSegment(this._seg1, n, this._distance, this._offset1);
|
|
10878
10889
|
};
|
|
10879
10890
|
lt.prototype.addLimitedMitreJoin = function(t, e, n, i) {
|
|
10880
|
-
var o = this._seg0.p1, s = K.angle(o, this._seg0.p0), a = K.angleBetweenOriented(this._seg0.p0, o, this._seg1.p1), u = a / 2, l = K.normalize(s + u), c = K.normalize(l + Math.PI), f = i * n, h = f * Math.abs(Math.sin(u)), g = n - h, p = o.x + f * Math.cos(c),
|
|
10891
|
+
var o = this._seg0.p1, s = K.angle(o, this._seg0.p0), a = K.angleBetweenOriented(this._seg0.p0, o, this._seg1.p1), u = a / 2, l = K.normalize(s + u), c = K.normalize(l + Math.PI), f = i * n, h = f * Math.abs(Math.sin(u)), g = n - h, p = o.x + f * Math.cos(c), y = o.y + f * Math.sin(c), m = new v(p, y), d = new B(o, m), E = d.pointAlongOffset(1, g), C = d.pointAlongOffset(1, -g);
|
|
10881
10892
|
this._side === b.LEFT ? (this._segList.addPt(E), this._segList.addPt(C)) : (this._segList.addPt(C), this._segList.addPt(E));
|
|
10882
10893
|
};
|
|
10883
10894
|
lt.prototype.computeOffsetSegment = function(t, e, n, i) {
|
|
@@ -10888,7 +10899,7 @@ lt.prototype.addFilletArc = function(t, e, n, i, o) {
|
|
|
10888
10899
|
var s = this, a = i === M.CLOCKWISE ? -1 : 1, u = Math.abs(e - n), l = Math.trunc(u / this._filletAngleQuantum + 0.5);
|
|
10889
10900
|
if (l < 1)
|
|
10890
10901
|
return null;
|
|
10891
|
-
for (var c = 0, f = u / l, h = c, g = new
|
|
10902
|
+
for (var c = 0, f = u / l, h = c, g = new v(); h < u; ) {
|
|
10892
10903
|
var p = e + a * h;
|
|
10893
10904
|
g.x = t.x + o * Math.cos(p), g.y = t.y + o * Math.sin(p), s._segList.addPt(g), h += f;
|
|
10894
10905
|
}
|
|
@@ -10900,9 +10911,9 @@ lt.prototype.addInsideTurn = function(t, e) {
|
|
|
10900
10911
|
this._segList.addPt(this._offset0.p1);
|
|
10901
10912
|
else {
|
|
10902
10913
|
if (this._segList.addPt(this._offset0.p1), this._closingSegLengthFactor > 0) {
|
|
10903
|
-
var n = new
|
|
10914
|
+
var n = new v((this._closingSegLengthFactor * this._offset0.p1.x + this._s1.x) / (this._closingSegLengthFactor + 1), (this._closingSegLengthFactor * this._offset0.p1.y + this._s1.y) / (this._closingSegLengthFactor + 1));
|
|
10904
10915
|
this._segList.addPt(n);
|
|
10905
|
-
var i = new
|
|
10916
|
+
var i = new v((this._closingSegLengthFactor * this._offset1.p0.x + this._s1.x) / (this._closingSegLengthFactor + 1), (this._closingSegLengthFactor * this._offset1.p0.y + this._s1.y) / (this._closingSegLengthFactor + 1));
|
|
10906
10917
|
this._segList.addPt(i);
|
|
10907
10918
|
} else
|
|
10908
10919
|
this._segList.addPt(this._s1);
|
|
@@ -10910,7 +10921,7 @@ lt.prototype.addInsideTurn = function(t, e) {
|
|
|
10910
10921
|
}
|
|
10911
10922
|
};
|
|
10912
10923
|
lt.prototype.createCircle = function(t) {
|
|
10913
|
-
var e = new
|
|
10924
|
+
var e = new v(t.x + this._distance, t.y);
|
|
10914
10925
|
this._segList.addPt(e), this.addFilletArc(t, 0, 2 * Math.PI, -1, this._distance), this._segList.closeRing();
|
|
10915
10926
|
};
|
|
10916
10927
|
lt.prototype.addBevelJoin = function(t, e) {
|
|
@@ -11066,7 +11077,7 @@ fe.prototype.getClass = function() {
|
|
|
11066
11077
|
};
|
|
11067
11078
|
fe.copyCoordinates = function(t) {
|
|
11068
11079
|
for (var e = new Array(t.length).fill(null), n = 0; n < e.length; n++)
|
|
11069
|
-
e[n] = new
|
|
11080
|
+
e[n] = new v(t[n]);
|
|
11070
11081
|
return e;
|
|
11071
11082
|
};
|
|
11072
11083
|
var ei = function() {
|
|
@@ -11083,7 +11094,7 @@ ei.prototype.findStabbedSegments = function() {
|
|
|
11083
11094
|
}
|
|
11084
11095
|
return n;
|
|
11085
11096
|
} else if (arguments.length === 3) {
|
|
11086
|
-
if (V(arguments[2], qe) && arguments[0] instanceof
|
|
11097
|
+
if (V(arguments[2], qe) && arguments[0] instanceof v && arguments[1] instanceof Ds)
|
|
11087
11098
|
for (var a = arguments[0], u = arguments[1], l = arguments[2], c = u.getEdge().getCoordinates(), f = 0; f < c.length - 1; f++) {
|
|
11088
11099
|
t._seg.p0 = c[f], t._seg.p1 = c[f + 1], t._seg.p0.y > t._seg.p1.y && t._seg.reverse();
|
|
11089
11100
|
var h = Math.max(t._seg.p0.x, t._seg.p1.x);
|
|
@@ -11094,10 +11105,10 @@ ei.prototype.findStabbedSegments = function() {
|
|
|
11094
11105
|
l.add(p);
|
|
11095
11106
|
}
|
|
11096
11107
|
}
|
|
11097
|
-
else if (V(arguments[2], qe) && arguments[0] instanceof
|
|
11098
|
-
for (var
|
|
11108
|
+
else if (V(arguments[2], qe) && arguments[0] instanceof v && V(arguments[1], qe))
|
|
11109
|
+
for (var y = arguments[0], m = arguments[1], d = arguments[2], E = m.iterator(); E.hasNext(); ) {
|
|
11099
11110
|
var C = E.next();
|
|
11100
|
-
C.isForward() && t.findStabbedSegments(
|
|
11111
|
+
C.isForward() && t.findStabbedSegments(y, C, d);
|
|
11101
11112
|
}
|
|
11102
11113
|
}
|
|
11103
11114
|
};
|
|
@@ -11193,8 +11204,8 @@ tt.det = function(t, e, n, i) {
|
|
|
11193
11204
|
return t * i - e * n;
|
|
11194
11205
|
};
|
|
11195
11206
|
tt.interpolateZ = function(t, e, n, i) {
|
|
11196
|
-
var o = e.x, s = e.y, a = n.x - o, u = i.x - o, l = n.y - s, c = i.y - s, f = a * c - u * l, h = t.x - o, g = t.y - s, p = (c * h - u * g) / f,
|
|
11197
|
-
return
|
|
11207
|
+
var o = e.x, s = e.y, a = n.x - o, u = i.x - o, l = n.y - s, c = i.y - s, f = a * c - u * l, h = t.x - o, g = t.y - s, p = (c * h - u * g) / f, y = (-l * h + a * g) / f, m = e.z + p * (n.z - e.z) + y * (i.z - e.z);
|
|
11208
|
+
return m;
|
|
11198
11209
|
};
|
|
11199
11210
|
tt.longestSideLength = function(t, e, n) {
|
|
11200
11211
|
var i = t.distance(e), o = e.distance(n), s = n.distance(t), a = i;
|
|
@@ -11205,14 +11216,14 @@ tt.isAcute = function(t, e, n) {
|
|
|
11205
11216
|
};
|
|
11206
11217
|
tt.circumcentre = function(t, e, n) {
|
|
11207
11218
|
var i = n.x, o = n.y, s = t.x - i, a = t.y - o, u = e.x - i, l = e.y - o, c = 2 * tt.det(s, a, u, l), f = tt.det(a, s * s + a * a, l, u * u + l * l), h = tt.det(s, s * s + a * a, u, u * u + l * l), g = i - f / c, p = o + h / c;
|
|
11208
|
-
return new
|
|
11219
|
+
return new v(g, p);
|
|
11209
11220
|
};
|
|
11210
11221
|
tt.perpendicularBisector = function(t, e) {
|
|
11211
11222
|
var n = e.x - t.x, i = e.y - t.y, o = new Ue(t.x + n / 2, t.y + i / 2, 1), s = new Ue(t.x - i + n / 2, t.y + n + i / 2, 1);
|
|
11212
11223
|
return new Ue(o, s);
|
|
11213
11224
|
};
|
|
11214
11225
|
tt.angleBisector = function(t, e, n) {
|
|
11215
|
-
var i = e.distance(t), o = e.distance(n), s = i / (i + o), a = n.x - t.x, u = n.y - t.y, l = new
|
|
11226
|
+
var i = e.distance(t), o = e.distance(n), s = i / (i + o), a = n.x - t.x, u = n.y - t.y, l = new v(t.x + s * a, t.y + s * u);
|
|
11216
11227
|
return l;
|
|
11217
11228
|
};
|
|
11218
11229
|
tt.area3D = function(t, e, n) {
|
|
@@ -11221,11 +11232,11 @@ tt.area3D = function(t, e, n) {
|
|
|
11221
11232
|
};
|
|
11222
11233
|
tt.centroid = function(t, e, n) {
|
|
11223
11234
|
var i = (t.x + e.x + n.x) / 3, o = (t.y + e.y + n.y) / 3;
|
|
11224
|
-
return new
|
|
11235
|
+
return new v(i, o);
|
|
11225
11236
|
};
|
|
11226
11237
|
tt.inCentre = function(t, e, n) {
|
|
11227
11238
|
var i = e.distance(n), o = t.distance(n), s = t.distance(e), a = i + o + s, u = (i * t.x + o * e.x + s * n.x) / a, l = (i * t.y + o * e.y + s * n.y) / a;
|
|
11228
|
-
return new
|
|
11239
|
+
return new v(u, l);
|
|
11229
11240
|
};
|
|
11230
11241
|
var Fe = function() {
|
|
11231
11242
|
this._inputGeom = null, this._distance = null, this._curveBuilder = null, this._curveList = new O();
|
|
@@ -11525,7 +11536,7 @@ Zt.prototype.interfaces_ = function() {
|
|
|
11525
11536
|
Zt.prototype.getClass = function() {
|
|
11526
11537
|
return Zt;
|
|
11527
11538
|
};
|
|
11528
|
-
var
|
|
11539
|
+
var Jc = function(r) {
|
|
11529
11540
|
function t() {
|
|
11530
11541
|
r.call(this), this._resultAreaEdgeList = null, this._label = null, this._SCANNING_FOR_INCOMING = 1, this._LINKING_TO_OUTGOING = 2;
|
|
11531
11542
|
}
|
|
@@ -11602,8 +11613,8 @@ var Zc = function(r) {
|
|
|
11602
11613
|
throw new Zn("depth mismatch at " + i.getCoordinate());
|
|
11603
11614
|
} else if (arguments.length === 3) {
|
|
11604
11615
|
for (var c = arguments[0], f = arguments[1], h = arguments[2], g = h, p = c; p < f; p++) {
|
|
11605
|
-
var
|
|
11606
|
-
|
|
11616
|
+
var y = n._edgeList.get(p);
|
|
11617
|
+
y.setEdgeDepths(b.RIGHT, g), g = y.getDepth(b.LEFT);
|
|
11607
11618
|
}
|
|
11608
11619
|
return g;
|
|
11609
11620
|
}
|
|
@@ -11683,7 +11694,7 @@ var Zc = function(r) {
|
|
|
11683
11694
|
r.apply(this, arguments);
|
|
11684
11695
|
}
|
|
11685
11696
|
return r && (t.__proto__ = r), t.prototype = Object.create(r && r.prototype), t.prototype.constructor = t, t.prototype.createNode = function(n) {
|
|
11686
|
-
return new us(n, new
|
|
11697
|
+
return new us(n, new Jc());
|
|
11687
11698
|
}, t.prototype.interfaces_ = function() {
|
|
11688
11699
|
return [];
|
|
11689
11700
|
}, t.prototype.getClass = function() {
|
|
@@ -11840,7 +11851,7 @@ Pe.isAdjacentSegments = function(t, e) {
|
|
|
11840
11851
|
var pn = function() {
|
|
11841
11852
|
this.coord = null, this.segmentIndex = null, this.dist = null;
|
|
11842
11853
|
var t = arguments[0], e = arguments[1], n = arguments[2];
|
|
11843
|
-
this.coord = new
|
|
11854
|
+
this.coord = new v(t), this.segmentIndex = e, this.dist = n;
|
|
11844
11855
|
};
|
|
11845
11856
|
pn.prototype.getSegmentIndex = function() {
|
|
11846
11857
|
return this.segmentIndex;
|
|
@@ -11904,7 +11915,7 @@ On.prototype.createSplitEdge = function(t, e) {
|
|
|
11904
11915
|
var n = this, i = e.segmentIndex - t.segmentIndex + 2, o = this.edge.pts[e.segmentIndex], s = e.dist > 0 || !e.coord.equals2D(o);
|
|
11905
11916
|
s || i--;
|
|
11906
11917
|
var a = new Array(i).fill(null), u = 0;
|
|
11907
|
-
a[u++] = new
|
|
11918
|
+
a[u++] = new v(t.coord);
|
|
11908
11919
|
for (var l = t.segmentIndex + 1; l <= e.segmentIndex; l++)
|
|
11909
11920
|
a[u++] = n.edge.pts[l];
|
|
11910
11921
|
return s && (a[u] = e.coord), new qo(a, new et(this.edge._label));
|
|
@@ -11987,8 +11998,8 @@ $n.prototype.computeIntersectsForChain = function() {
|
|
|
11987
11998
|
return c.addIntersections(this.e, o, a.e, u), null;
|
|
11988
11999
|
if (this.env1.init(f, h), this.env2.init(g, p), !this.env1.intersects(this.env2))
|
|
11989
12000
|
return null;
|
|
11990
|
-
var
|
|
11991
|
-
o <
|
|
12001
|
+
var y = Math.trunc((o + s) / 2), m = Math.trunc((u + l) / 2);
|
|
12002
|
+
o < y && (u < m && this.computeIntersectsForChain(o, y, a, u, m, c), m < l && this.computeIntersectsForChain(o, y, a, m, l, c)), y < s && (u < m && this.computeIntersectsForChain(y, s, a, u, m, c), m < l && this.computeIntersectsForChain(y, s, a, m, l, c));
|
|
11992
12003
|
}
|
|
11993
12004
|
};
|
|
11994
12005
|
$n.prototype.getStartIndexes = function() {
|
|
@@ -12160,7 +12171,7 @@ var qo = function(r) {
|
|
|
12160
12171
|
}
|
|
12161
12172
|
return this._env;
|
|
12162
12173
|
}, t.prototype.addIntersection = function(n, i, o, s) {
|
|
12163
|
-
var a = new
|
|
12174
|
+
var a = new v(n.getIntersection(s)), u = i, l = n.getEdgeDistance(o, s), c = u + 1;
|
|
12164
12175
|
if (c < this.pts.length) {
|
|
12165
12176
|
var f = this.pts[c];
|
|
12166
12177
|
a.equals2D(f) && (u = c, l = 0);
|
|
@@ -12318,7 +12329,7 @@ pr.prototype.scale = function() {
|
|
|
12318
12329
|
return n;
|
|
12319
12330
|
} else if (arguments[0] instanceof Array) {
|
|
12320
12331
|
for (var s = arguments[0], a = new Array(s.length).fill(null), u = 0; u < s.length; u++)
|
|
12321
|
-
a[u] = new
|
|
12332
|
+
a[u] = new v(Math.round((s[u].x - t._offsetX) * t._scaleFactor), Math.round((s[u].y - t._offsetY) * t._scaleFactor), s[u].z);
|
|
12322
12333
|
var l = j.removeRepeatedPoints(a);
|
|
12323
12334
|
return l;
|
|
12324
12335
|
}
|
|
@@ -12372,12 +12383,12 @@ dn.prototype.checkInteriorIntersections = function() {
|
|
|
12372
12383
|
for (var f = 0; f < l.length - 1; f++)
|
|
12373
12384
|
t.checkInteriorIntersections(s, c, a, f);
|
|
12374
12385
|
else if (arguments.length === 4) {
|
|
12375
|
-
var h = arguments[0], g = arguments[1], p = arguments[2],
|
|
12376
|
-
if (h === p && g ===
|
|
12386
|
+
var h = arguments[0], g = arguments[1], p = arguments[2], y = arguments[3];
|
|
12387
|
+
if (h === p && g === y)
|
|
12377
12388
|
return null;
|
|
12378
|
-
var
|
|
12379
|
-
if (this._li.computeIntersection(
|
|
12380
|
-
throw new Kn("found non-noded intersection at " +
|
|
12389
|
+
var m = h.getCoordinates()[g], d = h.getCoordinates()[g + 1], E = p.getCoordinates()[y], C = p.getCoordinates()[y + 1];
|
|
12390
|
+
if (this._li.computeIntersection(m, d, E, C), this._li.hasIntersection() && (this._li.isProper() || this.hasInteriorIntersection(this._li, m, d) || this.hasInteriorIntersection(this._li, E, C)))
|
|
12391
|
+
throw new Kn("found non-noded intersection at " + m + "-" + d + " and " + E + "-" + C);
|
|
12381
12392
|
}
|
|
12382
12393
|
};
|
|
12383
12394
|
dn.prototype.checkValid = function() {
|
|
@@ -12421,7 +12432,7 @@ var he = function() {
|
|
|
12421
12432
|
var t = arguments[0], e = arguments[1], n = arguments[2];
|
|
12422
12433
|
if (this._originalPt = t, this._pt = t, this._scaleFactor = e, this._li = n, e <= 0)
|
|
12423
12434
|
throw new ft("Scale factor must be non-zero");
|
|
12424
|
-
e !== 1 && (this._pt = new
|
|
12435
|
+
e !== 1 && (this._pt = new v(this.scale(t.x), this.scale(t.y)), this._p0Scaled = new v(), this._p1Scaled = new v()), this.initCorners(this._pt);
|
|
12425
12436
|
}, Ru = { SAFE_ENV_EXPANSION_FACTOR: { configurable: !0 } };
|
|
12426
12437
|
he.prototype.intersectsScaled = function(t, e) {
|
|
12427
12438
|
var n = Math.min(t.x, e.x), i = Math.max(t.x, e.x), o = Math.min(t.y, e.y), s = Math.max(t.y, e.y), a = this._maxx < n || this._minx > i || this._maxy < o || this._miny > s;
|
|
@@ -12432,7 +12443,7 @@ he.prototype.intersectsScaled = function(t, e) {
|
|
|
12432
12443
|
};
|
|
12433
12444
|
he.prototype.initCorners = function(t) {
|
|
12434
12445
|
var e = 0.5;
|
|
12435
|
-
this._minx = t.x - e, this._maxx = t.x + e, this._miny = t.y - e, this._maxy = t.y + e, this._corner[0] = new
|
|
12446
|
+
this._minx = t.x - e, this._maxx = t.x + e, this._miny = t.y - e, this._maxy = t.y + e, this._corner[0] = new v(this._maxx, this._maxy), this._corner[1] = new v(this._minx, this._maxy), this._corner[2] = new v(this._minx, this._miny), this._corner[3] = new v(this._maxx, this._miny);
|
|
12436
12447
|
};
|
|
12437
12448
|
he.prototype.intersects = function(t, e) {
|
|
12438
12449
|
return this._scaleFactor === 1 ? this.intersectsScaled(t, e) : (this.copyScaled(t, this._p0Scaled), this.copyScaled(e, this._p1Scaled), this.intersectsScaled(this._p0Scaled, this._p1Scaled));
|
|
@@ -12711,10 +12722,10 @@ zt.bufferOp = function() {
|
|
|
12711
12722
|
return p;
|
|
12712
12723
|
}
|
|
12713
12724
|
} else if (arguments.length === 4) {
|
|
12714
|
-
var
|
|
12715
|
-
C.setQuadrantSegments(
|
|
12716
|
-
var
|
|
12717
|
-
return
|
|
12725
|
+
var y = arguments[0], m = arguments[1], d = arguments[2], E = arguments[3], C = new zt(y);
|
|
12726
|
+
C.setQuadrantSegments(d), C.setEndCapStyle(E);
|
|
12727
|
+
var S = C.getResultGeometry(m);
|
|
12728
|
+
return S;
|
|
12718
12729
|
}
|
|
12719
12730
|
};
|
|
12720
12731
|
zt.precisionScaleFactor = function(t, e, n) {
|
|
@@ -12738,7 +12749,7 @@ Yi.MAX_PRECISION_DIGITS.get = function() {
|
|
|
12738
12749
|
};
|
|
12739
12750
|
Object.defineProperties(zt, Yi);
|
|
12740
12751
|
var te = function() {
|
|
12741
|
-
this._pt = [new
|
|
12752
|
+
this._pt = [new v(), new v()], this._distance = z.NaN, this._isNull = !0;
|
|
12742
12753
|
};
|
|
12743
12754
|
te.prototype.getCoordinates = function() {
|
|
12744
12755
|
return this._pt;
|
|
@@ -12799,33 +12810,33 @@ Nn.prototype.getClass = function() {
|
|
|
12799
12810
|
return Nn;
|
|
12800
12811
|
};
|
|
12801
12812
|
Nn.computeDistance = function() {
|
|
12802
|
-
if (arguments[2] instanceof te && arguments[0] instanceof yt && arguments[1] instanceof
|
|
12813
|
+
if (arguments[2] instanceof te && arguments[0] instanceof yt && arguments[1] instanceof v)
|
|
12803
12814
|
for (var t = arguments[0], e = arguments[1], n = arguments[2], i = t.getCoordinates(), o = new B(), s = 0; s < i.length - 1; s++) {
|
|
12804
12815
|
o.setCoordinates(i[s], i[s + 1]);
|
|
12805
12816
|
var a = o.closestPoint(e);
|
|
12806
12817
|
n.setMinimum(a, e);
|
|
12807
12818
|
}
|
|
12808
|
-
else if (arguments[2] instanceof te && arguments[0] instanceof Ot && arguments[1] instanceof
|
|
12819
|
+
else if (arguments[2] instanceof te && arguments[0] instanceof Ot && arguments[1] instanceof v) {
|
|
12809
12820
|
var u = arguments[0], l = arguments[1], c = arguments[2];
|
|
12810
12821
|
Nn.computeDistance(u.getExteriorRing(), l, c);
|
|
12811
12822
|
for (var f = 0; f < u.getNumInteriorRing(); f++)
|
|
12812
12823
|
Nn.computeDistance(u.getInteriorRingN(f), l, c);
|
|
12813
|
-
} else if (arguments[2] instanceof te && arguments[0] instanceof G && arguments[1] instanceof
|
|
12824
|
+
} else if (arguments[2] instanceof te && arguments[0] instanceof G && arguments[1] instanceof v) {
|
|
12814
12825
|
var h = arguments[0], g = arguments[1], p = arguments[2];
|
|
12815
12826
|
if (h instanceof yt)
|
|
12816
12827
|
Nn.computeDistance(h, g, p);
|
|
12817
12828
|
else if (h instanceof Ot)
|
|
12818
12829
|
Nn.computeDistance(h, g, p);
|
|
12819
12830
|
else if (h instanceof ie)
|
|
12820
|
-
for (var
|
|
12821
|
-
var
|
|
12822
|
-
Nn.computeDistance(
|
|
12831
|
+
for (var y = h, m = 0; m < y.getNumGeometries(); m++) {
|
|
12832
|
+
var d = y.getGeometryN(m);
|
|
12833
|
+
Nn.computeDistance(d, g, p);
|
|
12823
12834
|
}
|
|
12824
12835
|
else
|
|
12825
12836
|
p.setMinimum(h.getCoordinate(), g);
|
|
12826
|
-
} else if (arguments[2] instanceof te && arguments[0] instanceof B && arguments[1] instanceof
|
|
12827
|
-
var E = arguments[0], C = arguments[1],
|
|
12828
|
-
|
|
12837
|
+
} else if (arguments[2] instanceof te && arguments[0] instanceof B && arguments[1] instanceof v) {
|
|
12838
|
+
var E = arguments[0], C = arguments[1], S = arguments[2], N = E.closestPoint(C);
|
|
12839
|
+
S.setMinimum(N, C);
|
|
12829
12840
|
}
|
|
12830
12841
|
};
|
|
12831
12842
|
var kr = function(t) {
|
|
@@ -12879,7 +12890,7 @@ var dr = function(t) {
|
|
|
12879
12890
|
dr.prototype.filter = function(t, e) {
|
|
12880
12891
|
if (e === 0)
|
|
12881
12892
|
return null;
|
|
12882
|
-
var n = t.getCoordinate(e - 1), i = t.getCoordinate(e), o = new
|
|
12893
|
+
var n = t.getCoordinate(e - 1), i = t.getCoordinate(e), o = new v((n.x + i.x) / 2, (n.y + i.y) / 2);
|
|
12883
12894
|
this._minPtDist.initialize(), Nn.computeDistance(this._geom, o, this._minPtDist), this._maxPtDist.setMaximum(this._minPtDist);
|
|
12884
12895
|
};
|
|
12885
12896
|
dr.prototype.isDone = function() {
|
|
@@ -12973,13 +12984,13 @@ Vt.getLines = function() {
|
|
|
12973
12984
|
} else if (arguments.length === 3) {
|
|
12974
12985
|
if (typeof arguments[2] == "boolean" && V(arguments[0], Lt) && V(arguments[1], Lt)) {
|
|
12975
12986
|
for (var f = arguments[0], h = arguments[1], g = arguments[2], p = f.iterator(); p.hasNext(); ) {
|
|
12976
|
-
var
|
|
12977
|
-
Vt.getLines(
|
|
12987
|
+
var y = p.next();
|
|
12988
|
+
Vt.getLines(y, h, g);
|
|
12978
12989
|
}
|
|
12979
12990
|
return h;
|
|
12980
12991
|
} else if (typeof arguments[2] == "boolean" && arguments[0] instanceof G && V(arguments[1], Lt)) {
|
|
12981
|
-
var
|
|
12982
|
-
return
|
|
12992
|
+
var m = arguments[0], d = arguments[1], E = arguments[2];
|
|
12993
|
+
return m.apply(new Vt(d, E)), d;
|
|
12983
12994
|
}
|
|
12984
12995
|
}
|
|
12985
12996
|
};
|
|
@@ -12995,7 +13006,7 @@ var Ke = function() {
|
|
|
12995
13006
|
};
|
|
12996
13007
|
Ke.prototype.locateInternal = function() {
|
|
12997
13008
|
var t = this;
|
|
12998
|
-
if (arguments[0] instanceof
|
|
13009
|
+
if (arguments[0] instanceof v && arguments[1] instanceof Ot) {
|
|
12999
13010
|
var e = arguments[0], n = arguments[1];
|
|
13000
13011
|
if (n.isEmpty())
|
|
13001
13012
|
return _.EXTERIOR;
|
|
@@ -13012,13 +13023,13 @@ Ke.prototype.locateInternal = function() {
|
|
|
13012
13023
|
return _.BOUNDARY;
|
|
13013
13024
|
}
|
|
13014
13025
|
return _.INTERIOR;
|
|
13015
|
-
} else if (arguments[0] instanceof
|
|
13026
|
+
} else if (arguments[0] instanceof v && arguments[1] instanceof yt) {
|
|
13016
13027
|
var l = arguments[0], c = arguments[1];
|
|
13017
13028
|
if (!c.getEnvelopeInternal().intersects(l))
|
|
13018
13029
|
return _.EXTERIOR;
|
|
13019
13030
|
var f = c.getCoordinates();
|
|
13020
13031
|
return !c.isClosed() && (l.equals(f[0]) || l.equals(f[f.length - 1])) ? _.BOUNDARY : M.isOnLine(l, f) ? _.INTERIOR : _.EXTERIOR;
|
|
13021
|
-
} else if (arguments[0] instanceof
|
|
13032
|
+
} else if (arguments[0] instanceof v && arguments[1] instanceof de) {
|
|
13022
13033
|
var h = arguments[0], g = arguments[1], p = g.getCoordinate();
|
|
13023
13034
|
return p.equals2D(h) ? _.INTERIOR : _.EXTERIOR;
|
|
13024
13035
|
}
|
|
@@ -13163,9 +13174,9 @@ Xt.prototype.computeContainmentDistance = function() {
|
|
|
13163
13174
|
if (t.computeContainmentDistance(h, l.get(g), c), t._minDistance <= t._terminateDistance)
|
|
13164
13175
|
return null;
|
|
13165
13176
|
} else if (arguments[2] instanceof Array && arguments[0] instanceof ee && arguments[1] instanceof Ot) {
|
|
13166
|
-
var p = arguments[0],
|
|
13167
|
-
if (_.EXTERIOR !== this._ptLocator.locate(
|
|
13168
|
-
return this._minDistance = 0,
|
|
13177
|
+
var p = arguments[0], y = arguments[1], m = arguments[2], d = p.getCoordinate();
|
|
13178
|
+
if (_.EXTERIOR !== this._ptLocator.locate(d, y))
|
|
13179
|
+
return this._minDistance = 0, m[0] = p, m[1] = new ee(y, d), null;
|
|
13169
13180
|
}
|
|
13170
13181
|
}
|
|
13171
13182
|
};
|
|
@@ -13221,13 +13232,13 @@ Xt.prototype.computeMinDistance = function() {
|
|
|
13221
13232
|
var f = arguments[0], h = arguments[1], g = arguments[2];
|
|
13222
13233
|
if (f.getEnvelopeInternal().distance(h.getEnvelopeInternal()) > this._minDistance)
|
|
13223
13234
|
return null;
|
|
13224
|
-
for (var p = f.getCoordinates(),
|
|
13225
|
-
for (var
|
|
13226
|
-
var E = M.distanceLineLine(p[
|
|
13235
|
+
for (var p = f.getCoordinates(), y = h.getCoordinates(), m = 0; m < p.length - 1; m++)
|
|
13236
|
+
for (var d = 0; d < y.length - 1; d++) {
|
|
13237
|
+
var E = M.distanceLineLine(p[m], p[m + 1], y[d], y[d + 1]);
|
|
13227
13238
|
if (E < t._minDistance) {
|
|
13228
13239
|
t._minDistance = E;
|
|
13229
|
-
var C = new B(p[
|
|
13230
|
-
g[0] = new ee(f,
|
|
13240
|
+
var C = new B(p[m], p[m + 1]), S = new B(y[d], y[d + 1]), N = C.closestPoints(S);
|
|
13241
|
+
g[0] = new ee(f, m, N[0]), g[1] = new ee(h, d, N[1]);
|
|
13231
13242
|
}
|
|
13232
13243
|
if (t._minDistance <= t._terminateDistance)
|
|
13233
13244
|
return null;
|
|
@@ -13275,7 +13286,7 @@ Xt.nearestPoints = function(t, e) {
|
|
|
13275
13286
|
return n.nearestPoints();
|
|
13276
13287
|
};
|
|
13277
13288
|
var jt = function() {
|
|
13278
|
-
this._pt = [new
|
|
13289
|
+
this._pt = [new v(), new v()], this._distance = z.NaN, this._isNull = !0;
|
|
13279
13290
|
};
|
|
13280
13291
|
jt.prototype.getCoordinates = function() {
|
|
13281
13292
|
return this._pt;
|
|
@@ -13339,33 +13350,33 @@ rn.prototype.getClass = function() {
|
|
|
13339
13350
|
return rn;
|
|
13340
13351
|
};
|
|
13341
13352
|
rn.computeDistance = function() {
|
|
13342
|
-
if (arguments[2] instanceof jt && arguments[0] instanceof yt && arguments[1] instanceof
|
|
13353
|
+
if (arguments[2] instanceof jt && arguments[0] instanceof yt && arguments[1] instanceof v)
|
|
13343
13354
|
for (var t = arguments[0], e = arguments[1], n = arguments[2], i = new B(), o = t.getCoordinates(), s = 0; s < o.length - 1; s++) {
|
|
13344
13355
|
i.setCoordinates(o[s], o[s + 1]);
|
|
13345
13356
|
var a = i.closestPoint(e);
|
|
13346
13357
|
n.setMinimum(a, e);
|
|
13347
13358
|
}
|
|
13348
|
-
else if (arguments[2] instanceof jt && arguments[0] instanceof Ot && arguments[1] instanceof
|
|
13359
|
+
else if (arguments[2] instanceof jt && arguments[0] instanceof Ot && arguments[1] instanceof v) {
|
|
13349
13360
|
var u = arguments[0], l = arguments[1], c = arguments[2];
|
|
13350
13361
|
rn.computeDistance(u.getExteriorRing(), l, c);
|
|
13351
13362
|
for (var f = 0; f < u.getNumInteriorRing(); f++)
|
|
13352
13363
|
rn.computeDistance(u.getInteriorRingN(f), l, c);
|
|
13353
|
-
} else if (arguments[2] instanceof jt && arguments[0] instanceof G && arguments[1] instanceof
|
|
13364
|
+
} else if (arguments[2] instanceof jt && arguments[0] instanceof G && arguments[1] instanceof v) {
|
|
13354
13365
|
var h = arguments[0], g = arguments[1], p = arguments[2];
|
|
13355
13366
|
if (h instanceof yt)
|
|
13356
13367
|
rn.computeDistance(h, g, p);
|
|
13357
13368
|
else if (h instanceof Ot)
|
|
13358
13369
|
rn.computeDistance(h, g, p);
|
|
13359
13370
|
else if (h instanceof ie)
|
|
13360
|
-
for (var
|
|
13361
|
-
var
|
|
13362
|
-
rn.computeDistance(
|
|
13371
|
+
for (var y = h, m = 0; m < y.getNumGeometries(); m++) {
|
|
13372
|
+
var d = y.getGeometryN(m);
|
|
13373
|
+
rn.computeDistance(d, g, p);
|
|
13363
13374
|
}
|
|
13364
13375
|
else
|
|
13365
13376
|
p.setMinimum(h.getCoordinate(), g);
|
|
13366
|
-
} else if (arguments[2] instanceof jt && arguments[0] instanceof B && arguments[1] instanceof
|
|
13367
|
-
var E = arguments[0], C = arguments[1],
|
|
13368
|
-
|
|
13377
|
+
} else if (arguments[2] instanceof jt && arguments[0] instanceof B && arguments[1] instanceof v) {
|
|
13378
|
+
var E = arguments[0], C = arguments[1], S = arguments[2], N = E.closestPoint(C);
|
|
13379
|
+
S.setMinimum(N, C);
|
|
13369
13380
|
}
|
|
13370
13381
|
};
|
|
13371
13382
|
var De = function() {
|
|
@@ -13446,7 +13457,7 @@ vr.prototype.filter = function(t, e) {
|
|
|
13446
13457
|
if (e === 0)
|
|
13447
13458
|
return null;
|
|
13448
13459
|
for (var i = t.getCoordinate(e - 1), o = t.getCoordinate(e), s = (o.x - i.x) / this._numSubSegs, a = (o.y - i.y) / this._numSubSegs, u = 0; u < this._numSubSegs; u++) {
|
|
13449
|
-
var l = i.x + u * s, c = i.y + u * a, f = new
|
|
13460
|
+
var l = i.x + u * s, c = i.y + u * a, f = new v(l, c);
|
|
13450
13461
|
n._minPtDist.initialize(), rn.computeDistance(n._geom, f, n._minPtDist), n._maxPtDist.setMaximum(n._minPtDist);
|
|
13451
13462
|
}
|
|
13452
13463
|
};
|
|
@@ -13980,7 +13991,7 @@ var Dn = function r() {
|
|
|
13980
13991
|
Dn.prototype.snapVertices = function(t, e) {
|
|
13981
13992
|
for (var n = this, i = this._isClosed ? t.size() - 1 : t.size(), o = 0; o < i; o++) {
|
|
13982
13993
|
var s = t.get(o), a = n.findSnapForVertex(s, e);
|
|
13983
|
-
a !== null && (t.set(o, new
|
|
13994
|
+
a !== null && (t.set(o, new v(a)), o === 0 && n._isClosed && t.set(t.size() - 1, new v(a)));
|
|
13984
13995
|
}
|
|
13985
13996
|
};
|
|
13986
13997
|
Dn.prototype.findSnapForVertex = function(t, e) {
|
|
@@ -14006,7 +14017,7 @@ Dn.prototype.snapSegments = function(t, e) {
|
|
|
14006
14017
|
e[0].equals2D(e[e.length - 1]) && (i = e.length - 1);
|
|
14007
14018
|
for (var o = 0; o < i; o++) {
|
|
14008
14019
|
var s = e[o], a = n.findSegmentIndexToSnap(s, t);
|
|
14009
|
-
a >= 0 && t.add(a + 1, new
|
|
14020
|
+
a >= 0 && t.add(a + 1, new v(s), !1);
|
|
14010
14021
|
}
|
|
14011
14022
|
};
|
|
14012
14023
|
Dn.prototype.findSegmentIndexToSnap = function(t, e) {
|
|
@@ -14168,7 +14179,7 @@ yr.prototype.addCommonBits = function(t) {
|
|
|
14168
14179
|
yr.prototype.removeCommonBits = function(t) {
|
|
14169
14180
|
if (this._commonCoord.x === 0 && this._commonCoord.y === 0)
|
|
14170
14181
|
return t;
|
|
14171
|
-
var e = new
|
|
14182
|
+
var e = new v(this._commonCoord);
|
|
14172
14183
|
e.x = -e.x, e.y = -e.y;
|
|
14173
14184
|
var n = new mr(e);
|
|
14174
14185
|
return t.apply(n), t.geometryChanged(), t;
|
|
@@ -14199,7 +14210,7 @@ ui.prototype.filter = function(t) {
|
|
|
14199
14210
|
this._commonBitsX.add(t.x), this._commonBitsY.add(t.y);
|
|
14200
14211
|
};
|
|
14201
14212
|
ui.prototype.getCommonCoordinate = function() {
|
|
14202
|
-
return new
|
|
14213
|
+
return new v(this._commonBitsX.getCommon(), this._commonBitsY.getCommon());
|
|
14203
14214
|
};
|
|
14204
14215
|
ui.prototype.interfaces_ = function() {
|
|
14205
14216
|
return [Ln];
|
|
@@ -14460,7 +14471,7 @@ Wt.prototype.getClass = function() {
|
|
|
14460
14471
|
Wt.isAdjacentSegments = function(t, e) {
|
|
14461
14472
|
return Math.abs(t - e) === 1;
|
|
14462
14473
|
};
|
|
14463
|
-
var
|
|
14474
|
+
var $c = function(r) {
|
|
14464
14475
|
function t() {
|
|
14465
14476
|
r.call(this), this.events = new O(), this.nOverlaps = null;
|
|
14466
14477
|
}
|
|
@@ -14533,7 +14544,7 @@ Mn.prototype.getMax = function() {
|
|
|
14533
14544
|
return this._max;
|
|
14534
14545
|
};
|
|
14535
14546
|
Mn.prototype.toString = function() {
|
|
14536
|
-
return Xe.toLineString(new
|
|
14547
|
+
return Xe.toLineString(new v(this._min, 0), new v(this._max, 0));
|
|
14537
14548
|
};
|
|
14538
14549
|
Mn.prototype.interfaces_ = function() {
|
|
14539
14550
|
return [];
|
|
@@ -14557,7 +14568,7 @@ po.prototype.interfaces_ = function() {
|
|
|
14557
14568
|
po.prototype.getClass = function() {
|
|
14558
14569
|
return po;
|
|
14559
14570
|
};
|
|
14560
|
-
var
|
|
14571
|
+
var tf = function(r) {
|
|
14561
14572
|
function t() {
|
|
14562
14573
|
r.call(this), this._item = null;
|
|
14563
14574
|
var e = arguments[0], n = arguments[1], i = arguments[2];
|
|
@@ -14572,7 +14583,7 @@ var $c = function(r) {
|
|
|
14572
14583
|
}, t.prototype.getClass = function() {
|
|
14573
14584
|
return t;
|
|
14574
14585
|
}, t;
|
|
14575
|
-
}(Mn),
|
|
14586
|
+
}(Mn), ef = function(r) {
|
|
14576
14587
|
function t() {
|
|
14577
14588
|
r.call(this), this._node1 = null, this._node2 = null;
|
|
14578
14589
|
var e = arguments[0], n = arguments[1];
|
|
@@ -14604,7 +14615,7 @@ An.prototype.buildTree = function() {
|
|
|
14604
14615
|
An.prototype.insert = function(t, e, n) {
|
|
14605
14616
|
if (this._root !== null)
|
|
14606
14617
|
throw new Error("Index cannot be added to once it has been queried");
|
|
14607
|
-
this._leaves.add(new
|
|
14618
|
+
this._leaves.add(new tf(t, e, n));
|
|
14608
14619
|
};
|
|
14609
14620
|
An.prototype.query = function(t, e, n) {
|
|
14610
14621
|
this.init(), this._root.query(t, e, n);
|
|
@@ -14615,7 +14626,7 @@ An.prototype.buildRoot = function() {
|
|
|
14615
14626
|
this._root = this.buildTree();
|
|
14616
14627
|
};
|
|
14617
14628
|
An.prototype.printNode = function(t) {
|
|
14618
|
-
qt.out.println(Xe.toLineString(new
|
|
14629
|
+
qt.out.println(Xe.toLineString(new v(t._min, this._level), new v(t._max, this._level)));
|
|
14619
14630
|
};
|
|
14620
14631
|
An.prototype.init = function() {
|
|
14621
14632
|
if (this._root !== null)
|
|
@@ -14629,7 +14640,7 @@ An.prototype.buildLevel = function(t, e) {
|
|
|
14629
14640
|
if (o === null)
|
|
14630
14641
|
e.add(i);
|
|
14631
14642
|
else {
|
|
14632
|
-
var s = new
|
|
14643
|
+
var s = new ef(t.get(n), t.get(n + 1));
|
|
14633
14644
|
e.add(s);
|
|
14634
14645
|
}
|
|
14635
14646
|
}
|
|
@@ -14771,7 +14782,7 @@ var ji = function(r) {
|
|
|
14771
14782
|
if (arguments[0] instanceof de) {
|
|
14772
14783
|
var n = arguments[0], i = n.getCoordinate();
|
|
14773
14784
|
this.insertPoint(this._argIndex, i, _.INTERIOR);
|
|
14774
|
-
} else if (arguments[0] instanceof
|
|
14785
|
+
} else if (arguments[0] instanceof v) {
|
|
14775
14786
|
var o = arguments[0];
|
|
14776
14787
|
this.insertPoint(this._argIndex, o, _.INTERIOR);
|
|
14777
14788
|
}
|
|
@@ -14820,7 +14831,7 @@ var ji = function(r) {
|
|
|
14820
14831
|
var s = this._nodes.addNode(i), a = s.getLabel();
|
|
14821
14832
|
a === null ? s._label = new et(n, o) : a.setLocation(n, o);
|
|
14822
14833
|
}, t.prototype.createEdgeSetIntersector = function() {
|
|
14823
|
-
return new
|
|
14834
|
+
return new $c();
|
|
14824
14835
|
}, t.prototype.addSelfIntersectionNodes = function(n) {
|
|
14825
14836
|
for (var i = this, o = this._edges.iterator(); o.hasNext(); )
|
|
14826
14837
|
for (var s = o.next(), a = s.getLabel().getLocation(n), u = s.eiList.iterator(); u.hasNext(); ) {
|
|
@@ -15192,11 +15203,11 @@ Vr.prototype.getPoints = function(t) {
|
|
|
15192
15203
|
Vr.prototype.computeOffsetPoints = function(t, e, n, i) {
|
|
15193
15204
|
var o = e.x - t.x, s = e.y - t.y, a = Math.sqrt(o * o + s * s), u = n * o / a, l = n * s / a, c = (e.x + t.x) / 2, f = (e.y + t.y) / 2;
|
|
15194
15205
|
if (this._doLeft) {
|
|
15195
|
-
var h = new
|
|
15206
|
+
var h = new v(c - l, f + u);
|
|
15196
15207
|
i.add(h);
|
|
15197
15208
|
}
|
|
15198
15209
|
if (this._doRight) {
|
|
15199
|
-
var g = new
|
|
15210
|
+
var g = new v(c + l, f - u);
|
|
15200
15211
|
i.add(g);
|
|
15201
15212
|
}
|
|
15202
15213
|
};
|
|
@@ -15475,7 +15486,7 @@ function Da(r, t, e) {
|
|
|
15475
15486
|
var n = r.s = t + e, i = n - t, o = n - i;
|
|
15476
15487
|
r.t = t - o + (e - i);
|
|
15477
15488
|
}
|
|
15478
|
-
var vt = 1e-6, it = Math.PI, Wn = it / 2, Ma = it / 4, tr = it * 2, Nr = 180 / it, tn = it / 180, ne = Math.abs,
|
|
15489
|
+
var vt = 1e-6, it = Math.PI, Wn = it / 2, Ma = it / 4, tr = it * 2, Nr = 180 / it, tn = it / 180, ne = Math.abs, nf = Math.atan, Gi = Math.atan2, bt = Math.cos, Pt = Math.sin, Wi = Math.sqrt;
|
|
15479
15490
|
function Gu(r) {
|
|
15480
15491
|
return r > 1 ? 0 : r < -1 ? it : Math.acos(r);
|
|
15481
15492
|
}
|
|
@@ -15537,7 +15548,7 @@ function ka(r, t) {
|
|
|
15537
15548
|
Ms(r[e], t, 1);
|
|
15538
15549
|
t.polygonEnd();
|
|
15539
15550
|
}
|
|
15540
|
-
function
|
|
15551
|
+
function rf(r, t) {
|
|
15541
15552
|
r && Aa.hasOwnProperty(r.type) ? Aa[r.type](r, t) : Ho(r, t);
|
|
15542
15553
|
}
|
|
15543
15554
|
Yr();
|
|
@@ -15578,7 +15589,7 @@ function ks(r, t) {
|
|
|
15578
15589
|
return [r > it ? r - tr : r < -it ? r + tr : r, t];
|
|
15579
15590
|
}
|
|
15580
15591
|
ks.invert = ks;
|
|
15581
|
-
function
|
|
15592
|
+
function of(r, t, e) {
|
|
15582
15593
|
return (r %= tr) ? t || e ? Vu(Ga(r), Va(t, e)) : Ga(r) : t || e ? Va(t, e) : ks;
|
|
15583
15594
|
}
|
|
15584
15595
|
function Ba(r) {
|
|
@@ -15607,7 +15618,7 @@ function Va(r, t) {
|
|
|
15607
15618
|
];
|
|
15608
15619
|
}, s;
|
|
15609
15620
|
}
|
|
15610
|
-
function
|
|
15621
|
+
function sf(r, t, e, n, i, o) {
|
|
15611
15622
|
if (e) {
|
|
15612
15623
|
var s = bt(t), a = Pt(t), u = n * e;
|
|
15613
15624
|
i == null ? (i = t + n * tr, o = t - u / 2) : (i = za(s, i), o = za(s, o), (n > 0 ? i < o : i > o) && (i += n * tr));
|
|
@@ -15639,7 +15650,7 @@ function zu() {
|
|
|
15639
15650
|
}
|
|
15640
15651
|
};
|
|
15641
15652
|
}
|
|
15642
|
-
function
|
|
15653
|
+
function af(r, t, e, n, i, o) {
|
|
15643
15654
|
var s = r[0], a = r[1], u = t[0], l = t[1], c = 0, f = 1, h = u - s, g = l - a, p;
|
|
15644
15655
|
if (p = e - s, !(!h && p > 0)) {
|
|
15645
15656
|
if (p /= h, h < 0) {
|
|
@@ -15696,15 +15707,15 @@ function Oo(r, t, e, n) {
|
|
|
15696
15707
|
function Uu(r, t, e, n, i) {
|
|
15697
15708
|
var o = [], s = [], a, u;
|
|
15698
15709
|
if (r.forEach(function(p) {
|
|
15699
|
-
if (!((
|
|
15700
|
-
var
|
|
15701
|
-
if (Fo(
|
|
15702
|
-
for (i.lineStart(), a = 0; a <
|
|
15703
|
-
i.point((
|
|
15710
|
+
if (!((y = p.length - 1) <= 0)) {
|
|
15711
|
+
var y, m = p[0], d = p[y], E;
|
|
15712
|
+
if (Fo(m, d)) {
|
|
15713
|
+
for (i.lineStart(), a = 0; a < y; ++a)
|
|
15714
|
+
i.point((m = p[a])[0], m[1]);
|
|
15704
15715
|
i.lineEnd();
|
|
15705
15716
|
return;
|
|
15706
15717
|
}
|
|
15707
|
-
o.push(E = new Oo(
|
|
15718
|
+
o.push(E = new Oo(m, p, null, !0)), s.push(E.o = new Oo(m, null, E, !1)), o.push(E = new Oo(d, p, null, !1)), s.push(E.o = new Oo(d, null, E, !0));
|
|
15708
15719
|
}
|
|
15709
15720
|
}), !!o.length) {
|
|
15710
15721
|
for (s.sort(t), Ua(o), Ua(s), a = 0, u = s.length; a < u; ++a)
|
|
@@ -15746,8 +15757,8 @@ function Ua(r) {
|
|
|
15746
15757
|
function qu(r, t) {
|
|
15747
15758
|
return r < t ? -1 : r > t ? 1 : r >= t ? 0 : NaN;
|
|
15748
15759
|
}
|
|
15749
|
-
function
|
|
15750
|
-
return r.length === 1 && (r =
|
|
15760
|
+
function uf(r) {
|
|
15761
|
+
return r.length === 1 && (r = lf(r)), {
|
|
15751
15762
|
left: function(t, e, n, i) {
|
|
15752
15763
|
for (n == null && (n = 0), i == null && (i = t.length); n < i; ) {
|
|
15753
15764
|
var o = n + i >>> 1;
|
|
@@ -15764,12 +15775,12 @@ function af(r) {
|
|
|
15764
15775
|
}
|
|
15765
15776
|
};
|
|
15766
15777
|
}
|
|
15767
|
-
function
|
|
15778
|
+
function lf(r) {
|
|
15768
15779
|
return function(t, e) {
|
|
15769
15780
|
return qu(r(t), e);
|
|
15770
15781
|
};
|
|
15771
15782
|
}
|
|
15772
|
-
|
|
15783
|
+
uf(qu);
|
|
15773
15784
|
function Xu(r) {
|
|
15774
15785
|
for (var t = r.length, e, n = -1, i = 0, o, s; ++n < t; )
|
|
15775
15786
|
i += r[n].length;
|
|
@@ -15779,7 +15790,7 @@ function Xu(r) {
|
|
|
15779
15790
|
return o;
|
|
15780
15791
|
}
|
|
15781
15792
|
var Qi = 1e9, To = -Qi;
|
|
15782
|
-
function
|
|
15793
|
+
function cf(r, t, e, n) {
|
|
15783
15794
|
function i(l, c) {
|
|
15784
15795
|
return r <= l && l <= e && t <= c && c <= n;
|
|
15785
15796
|
}
|
|
@@ -15803,7 +15814,7 @@ function lf(r, t, e, n) {
|
|
|
15803
15814
|
return f !== h ? f - h : f === 0 ? c[1] - l[1] : f === 1 ? l[0] - c[0] : f === 2 ? l[1] - c[1] : c[0] - l[0];
|
|
15804
15815
|
}
|
|
15805
15816
|
return function(l) {
|
|
15806
|
-
var c = l, f = zu(), h, g, p,
|
|
15817
|
+
var c = l, f = zu(), h, g, p, y, m, d, E, C, S, N, w, T = {
|
|
15807
15818
|
point: A,
|
|
15808
15819
|
lineStart: R,
|
|
15809
15820
|
lineEnd: Y,
|
|
@@ -15820,48 +15831,48 @@ function lf(r, t, e, n) {
|
|
|
15820
15831
|
return W;
|
|
15821
15832
|
}
|
|
15822
15833
|
function F() {
|
|
15823
|
-
c = f, h = [], g = [],
|
|
15834
|
+
c = f, h = [], g = [], w = !0;
|
|
15824
15835
|
}
|
|
15825
15836
|
function X() {
|
|
15826
|
-
var W = L(), ut =
|
|
15837
|
+
var W = L(), ut = w && W, dt = (h = Xu(h)).length;
|
|
15827
15838
|
(ut || dt) && (l.polygonStart(), ut && (l.lineStart(), o(null, null, 1, l), l.lineEnd()), dt && Uu(h, a, W, o, l), l.polygonEnd()), c = l, h = g = p = null;
|
|
15828
15839
|
}
|
|
15829
15840
|
function R() {
|
|
15830
|
-
T.point = D, g && g.push(p = []), N = !0,
|
|
15841
|
+
T.point = D, g && g.push(p = []), N = !0, S = !1, E = C = NaN;
|
|
15831
15842
|
}
|
|
15832
15843
|
function Y() {
|
|
15833
|
-
h && (D(
|
|
15844
|
+
h && (D(y, m), d && S && f.rejoin(), h.push(f.result())), T.point = A, S && c.lineEnd();
|
|
15834
15845
|
}
|
|
15835
15846
|
function D(W, ut) {
|
|
15836
15847
|
var dt = i(W, ut);
|
|
15837
15848
|
if (g && p.push([W, ut]), N)
|
|
15838
|
-
|
|
15839
|
-
else if (dt &&
|
|
15849
|
+
y = W, m = ut, d = dt, N = !1, dt && (c.lineStart(), c.point(W, ut));
|
|
15850
|
+
else if (dt && S)
|
|
15840
15851
|
c.point(W, ut);
|
|
15841
15852
|
else {
|
|
15842
15853
|
var Ht = [E = Math.max(To, Math.min(Qi, E)), C = Math.max(To, Math.min(Qi, C))], Jt = [W = Math.max(To, Math.min(Qi, W)), ut = Math.max(To, Math.min(Qi, ut))];
|
|
15843
|
-
|
|
15854
|
+
af(Ht, Jt, r, t, e, n) ? (S || (c.lineStart(), c.point(Ht[0], Ht[1])), c.point(Jt[0], Jt[1]), dt || c.lineEnd(), w = !1) : dt && (c.lineStart(), c.point(W, ut), w = !1);
|
|
15844
15855
|
}
|
|
15845
|
-
E = W, C = ut,
|
|
15856
|
+
E = W, C = ut, S = dt;
|
|
15846
15857
|
}
|
|
15847
15858
|
return T;
|
|
15848
15859
|
};
|
|
15849
15860
|
}
|
|
15850
15861
|
var Is = Yr();
|
|
15851
|
-
function
|
|
15862
|
+
function ff(r, t) {
|
|
15852
15863
|
var e = t[0], n = t[1], i = [Pt(e), -bt(e), 0], o = 0, s = 0;
|
|
15853
15864
|
Is.reset();
|
|
15854
15865
|
for (var a = 0, u = r.length; a < u; ++a)
|
|
15855
15866
|
if (c = (l = r[a]).length)
|
|
15856
|
-
for (var l, c, f = l[c - 1], h = f[0], g = f[1] / 2 + Ma, p = Pt(g),
|
|
15857
|
-
var
|
|
15858
|
-
if (Is.add(Gi(F * T * Pt(A),
|
|
15859
|
-
var X = jo(Vi(f), Vi(
|
|
15867
|
+
for (var l, c, f = l[c - 1], h = f[0], g = f[1] / 2 + Ma, p = Pt(g), y = bt(g), m = 0; m < c; ++m, h = E, p = S, y = N, f = d) {
|
|
15868
|
+
var d = l[m], E = d[0], C = d[1] / 2 + Ma, S = Pt(C), N = bt(C), w = E - h, T = w >= 0 ? 1 : -1, A = T * w, L = A > it, F = p * S;
|
|
15869
|
+
if (Is.add(Gi(F * T * Pt(A), y * N + F * bt(A))), o += L ? w + T * tr : w, L ^ h >= e ^ E >= e) {
|
|
15870
|
+
var X = jo(Vi(f), Vi(d));
|
|
15860
15871
|
Fs(X);
|
|
15861
15872
|
var R = jo(i, X);
|
|
15862
15873
|
Fs(R);
|
|
15863
|
-
var Y = (L ^
|
|
15864
|
-
(n > Y || n === Y && (X[0] || X[1])) && (s += L ^
|
|
15874
|
+
var Y = (L ^ w >= 0 ? -1 : 1) * li(R[2]);
|
|
15875
|
+
(n > Y || n === Y && (X[0] || X[1])) && (s += L ^ w >= 0 ? 1 : -1);
|
|
15865
15876
|
}
|
|
15866
15877
|
}
|
|
15867
15878
|
return (o < -vt || o < vt && Is < -vt) ^ s & 1;
|
|
@@ -15873,7 +15884,7 @@ function qa(r) {
|
|
|
15873
15884
|
Yr();
|
|
15874
15885
|
Yr();
|
|
15875
15886
|
var zi = 1 / 0, Ko = zi, vo = -zi, Qo = vo, Xa = {
|
|
15876
|
-
point:
|
|
15887
|
+
point: hf,
|
|
15877
15888
|
lineStart: Ki,
|
|
15878
15889
|
lineEnd: Ki,
|
|
15879
15890
|
polygonStart: Ki,
|
|
@@ -15883,55 +15894,55 @@ var zi = 1 / 0, Ko = zi, vo = -zi, Qo = vo, Xa = {
|
|
|
15883
15894
|
return vo = Qo = -(Ko = zi = 1 / 0), r;
|
|
15884
15895
|
}
|
|
15885
15896
|
};
|
|
15886
|
-
function
|
|
15897
|
+
function hf(r, t) {
|
|
15887
15898
|
r < zi && (zi = r), r > vo && (vo = r), t < Ko && (Ko = t), t > Qo && (Qo = t);
|
|
15888
15899
|
}
|
|
15889
15900
|
Yr();
|
|
15890
15901
|
function Yu(r, t, e, n) {
|
|
15891
15902
|
return function(i, o) {
|
|
15892
15903
|
var s = t(o), a = i.invert(n[0], n[1]), u = zu(), l = t(u), c = !1, f, h, g, p = {
|
|
15893
|
-
point:
|
|
15894
|
-
lineStart:
|
|
15904
|
+
point: y,
|
|
15905
|
+
lineStart: d,
|
|
15895
15906
|
lineEnd: E,
|
|
15896
15907
|
polygonStart: function() {
|
|
15897
|
-
p.point = C, p.lineStart =
|
|
15908
|
+
p.point = C, p.lineStart = S, p.lineEnd = N, h = [], f = [];
|
|
15898
15909
|
},
|
|
15899
15910
|
polygonEnd: function() {
|
|
15900
|
-
p.point =
|
|
15901
|
-
var
|
|
15902
|
-
h.length ? (c || (o.polygonStart(), c = !0), Uu(h,
|
|
15911
|
+
p.point = y, p.lineStart = d, p.lineEnd = E, h = Xu(h);
|
|
15912
|
+
var w = ff(f, a);
|
|
15913
|
+
h.length ? (c || (o.polygonStart(), c = !0), Uu(h, pf, w, e, o)) : w && (c || (o.polygonStart(), c = !0), o.lineStart(), e(null, null, 1, o), o.lineEnd()), c && (o.polygonEnd(), c = !1), h = f = null;
|
|
15903
15914
|
},
|
|
15904
15915
|
sphere: function() {
|
|
15905
15916
|
o.polygonStart(), o.lineStart(), e(null, null, 1, o), o.lineEnd(), o.polygonEnd();
|
|
15906
15917
|
}
|
|
15907
15918
|
};
|
|
15908
|
-
function
|
|
15909
|
-
var A = i(
|
|
15910
|
-
r(
|
|
15919
|
+
function y(w, T) {
|
|
15920
|
+
var A = i(w, T);
|
|
15921
|
+
r(w = A[0], T = A[1]) && o.point(w, T);
|
|
15911
15922
|
}
|
|
15912
|
-
function
|
|
15913
|
-
var A = i(
|
|
15923
|
+
function m(w, T) {
|
|
15924
|
+
var A = i(w, T);
|
|
15914
15925
|
s.point(A[0], A[1]);
|
|
15915
15926
|
}
|
|
15916
|
-
function
|
|
15917
|
-
p.point =
|
|
15927
|
+
function d() {
|
|
15928
|
+
p.point = m, s.lineStart();
|
|
15918
15929
|
}
|
|
15919
15930
|
function E() {
|
|
15920
|
-
p.point =
|
|
15931
|
+
p.point = y, s.lineEnd();
|
|
15921
15932
|
}
|
|
15922
|
-
function C(
|
|
15923
|
-
g.push([
|
|
15924
|
-
var A = i(
|
|
15933
|
+
function C(w, T) {
|
|
15934
|
+
g.push([w, T]);
|
|
15935
|
+
var A = i(w, T);
|
|
15925
15936
|
l.point(A[0], A[1]);
|
|
15926
15937
|
}
|
|
15927
|
-
function
|
|
15938
|
+
function S() {
|
|
15928
15939
|
l.lineStart(), g = [];
|
|
15929
15940
|
}
|
|
15930
15941
|
function N() {
|
|
15931
15942
|
C(g[0][0], g[0][1]), l.lineEnd();
|
|
15932
|
-
var
|
|
15943
|
+
var w = l.clean(), T = u.result(), A, L = T.length, F, X, R;
|
|
15933
15944
|
if (g.pop(), f.push(g), g = null, !!L) {
|
|
15934
|
-
if (
|
|
15945
|
+
if (w & 1) {
|
|
15935
15946
|
if (X = T[0], (F = X.length - 1) > 0) {
|
|
15936
15947
|
for (c || (o.polygonStart(), c = !0), o.lineStart(), A = 0; A < F; ++A)
|
|
15937
15948
|
o.point((R = X[A])[0], R[1]);
|
|
@@ -15939,27 +15950,27 @@ function Yu(r, t, e, n) {
|
|
|
15939
15950
|
}
|
|
15940
15951
|
return;
|
|
15941
15952
|
}
|
|
15942
|
-
L > 1 &&
|
|
15953
|
+
L > 1 && w & 2 && T.push(T.pop().concat(T.shift())), h.push(T.filter(gf));
|
|
15943
15954
|
}
|
|
15944
15955
|
}
|
|
15945
15956
|
return p;
|
|
15946
15957
|
};
|
|
15947
15958
|
}
|
|
15948
|
-
function
|
|
15959
|
+
function gf(r) {
|
|
15949
15960
|
return r.length > 1;
|
|
15950
15961
|
}
|
|
15951
|
-
function
|
|
15962
|
+
function pf(r, t) {
|
|
15952
15963
|
return ((r = r.x)[0] < 0 ? r[1] - Wn - vt : Wn - r[1]) - ((t = t.x)[0] < 0 ? t[1] - Wn - vt : Wn - t[1]);
|
|
15953
15964
|
}
|
|
15954
15965
|
const Ya = Yu(
|
|
15955
15966
|
function() {
|
|
15956
15967
|
return !0;
|
|
15957
15968
|
},
|
|
15958
|
-
|
|
15959
|
-
|
|
15969
|
+
df,
|
|
15970
|
+
yf,
|
|
15960
15971
|
[-it, -Wn]
|
|
15961
15972
|
);
|
|
15962
|
-
function
|
|
15973
|
+
function df(r) {
|
|
15963
15974
|
var t = NaN, e = NaN, n = NaN, i;
|
|
15964
15975
|
return {
|
|
15965
15976
|
lineStart: function() {
|
|
@@ -15967,7 +15978,7 @@ function pf(r) {
|
|
|
15967
15978
|
},
|
|
15968
15979
|
point: function(o, s) {
|
|
15969
15980
|
var a = o > 0 ? it : -it, u = ne(o - t);
|
|
15970
|
-
ne(u - it) < vt ? (r.point(t, e = (e + s) / 2 > 0 ? Wn : -Wn), r.point(n, e), r.lineEnd(), r.lineStart(), r.point(a, e), r.point(o, e), i = 0) : n !== a && u >= it && (ne(t - n) < vt && (t -= n * vt), ne(o - a) < vt && (o -= a * vt), e =
|
|
15981
|
+
ne(u - it) < vt ? (r.point(t, e = (e + s) / 2 > 0 ? Wn : -Wn), r.point(n, e), r.lineEnd(), r.lineStart(), r.point(a, e), r.point(o, e), i = 0) : n !== a && u >= it && (ne(t - n) < vt && (t -= n * vt), ne(o - a) < vt && (o -= a * vt), e = vf(t, e, o, s), r.point(n, e), r.lineEnd(), r.lineStart(), r.point(a, e), i = 0), r.point(t = o, e = s), n = a;
|
|
15971
15982
|
},
|
|
15972
15983
|
lineEnd: function() {
|
|
15973
15984
|
r.lineEnd(), t = e = NaN;
|
|
@@ -15977,11 +15988,11 @@ function pf(r) {
|
|
|
15977
15988
|
}
|
|
15978
15989
|
};
|
|
15979
15990
|
}
|
|
15980
|
-
function
|
|
15991
|
+
function vf(r, t, e, n) {
|
|
15981
15992
|
var i, o, s = Pt(r - e);
|
|
15982
|
-
return ne(s) > vt ?
|
|
15993
|
+
return ne(s) > vt ? nf((Pt(t) * (o = bt(n)) * Pt(e) - Pt(n) * (i = bt(t)) * Pt(r)) / (i * o * s)) : (t + n) / 2;
|
|
15983
15994
|
}
|
|
15984
|
-
function
|
|
15995
|
+
function yf(r, t, e, n) {
|
|
15985
15996
|
var i;
|
|
15986
15997
|
if (r == null)
|
|
15987
15998
|
i = e * Wn, n.point(-it, i), n.point(0, i), n.point(it, i), n.point(it, 0), n.point(it, -i), n.point(0, -i), n.point(-it, -i), n.point(-it, 0), n.point(-it, i);
|
|
@@ -15991,29 +16002,29 @@ function vf(r, t, e, n) {
|
|
|
15991
16002
|
} else
|
|
15992
16003
|
n.point(t[0], t[1]);
|
|
15993
16004
|
}
|
|
15994
|
-
function
|
|
16005
|
+
function mf(r, t) {
|
|
15995
16006
|
var e = bt(r), n = e > 0, i = ne(e) > vt;
|
|
15996
16007
|
function o(c, f, h, g) {
|
|
15997
|
-
|
|
16008
|
+
sf(g, r, t, h, c, f);
|
|
15998
16009
|
}
|
|
15999
16010
|
function s(c, f) {
|
|
16000
16011
|
return bt(c) * bt(f) > e;
|
|
16001
16012
|
}
|
|
16002
16013
|
function a(c) {
|
|
16003
|
-
var f, h, g, p,
|
|
16014
|
+
var f, h, g, p, y;
|
|
16004
16015
|
return {
|
|
16005
16016
|
lineStart: function() {
|
|
16006
|
-
p = g = !1,
|
|
16017
|
+
p = g = !1, y = 1;
|
|
16007
16018
|
},
|
|
16008
|
-
point: function(
|
|
16009
|
-
var E = [
|
|
16010
|
-
if (!f && (p = g =
|
|
16011
|
-
|
|
16012
|
-
else if (i && f && n ^
|
|
16013
|
-
var
|
|
16014
|
-
!(N & h) && (
|
|
16019
|
+
point: function(m, d) {
|
|
16020
|
+
var E = [m, d], C, S = s(m, d), N = n ? S ? 0 : l(m, d) : S ? l(m + (m < 0 ? it : -it), d) : 0;
|
|
16021
|
+
if (!f && (p = g = S) && c.lineStart(), S !== g && (C = u(f, E), (!C || Fo(f, C) || Fo(E, C)) && (E[0] += vt, E[1] += vt, S = s(E[0], E[1]))), S !== g)
|
|
16022
|
+
y = 0, S ? (c.lineStart(), C = u(E, f), c.point(C[0], C[1])) : (C = u(f, E), c.point(C[0], C[1]), c.lineEnd()), f = C;
|
|
16023
|
+
else if (i && f && n ^ S) {
|
|
16024
|
+
var w;
|
|
16025
|
+
!(N & h) && (w = u(E, f, !0)) && (y = 0, n ? (c.lineStart(), c.point(w[0][0], w[0][1]), c.point(w[1][0], w[1][1]), c.lineEnd()) : (c.point(w[1][0], w[1][1]), c.lineEnd(), c.lineStart(), c.point(w[0][0], w[0][1])));
|
|
16015
16026
|
}
|
|
16016
|
-
|
|
16027
|
+
S && (!f || !Fo(f, E)) && c.point(E[0], E[1]), f = E, g = S, h = N;
|
|
16017
16028
|
},
|
|
16018
16029
|
lineEnd: function() {
|
|
16019
16030
|
g && c.lineEnd(), f = null;
|
|
@@ -16021,17 +16032,17 @@ function yf(r, t) {
|
|
|
16021
16032
|
// Rejoin first and last segments if there were intersections and the first
|
|
16022
16033
|
// and last points were visible.
|
|
16023
16034
|
clean: function() {
|
|
16024
|
-
return
|
|
16035
|
+
return y | (p && g) << 1;
|
|
16025
16036
|
}
|
|
16026
16037
|
};
|
|
16027
16038
|
}
|
|
16028
16039
|
function u(c, f, h) {
|
|
16029
|
-
var g = Vi(c), p = Vi(f),
|
|
16040
|
+
var g = Vi(c), p = Vi(f), y = [1, 0, 0], m = jo(g, p), d = Po(m, m), E = m[0], C = d - E * E;
|
|
16030
16041
|
if (!C)
|
|
16031
16042
|
return !h && c;
|
|
16032
|
-
var
|
|
16043
|
+
var S = e * d / C, N = -e * E / C, w = jo(y, m), T = Ro(y, S), A = Ro(m, N);
|
|
16033
16044
|
Es(T, A);
|
|
16034
|
-
var L =
|
|
16045
|
+
var L = w, F = Po(T, L), X = Po(L, L), R = F * F - X * (Po(T, T) - 1);
|
|
16035
16046
|
if (!(R < 0)) {
|
|
16036
16047
|
var Y = Wi(R), D = Ro(L, (-F - Y) / X);
|
|
16037
16048
|
if (Es(D, T), D = As(D), !h)
|
|
@@ -16084,81 +16095,81 @@ Bs.prototype = {
|
|
|
16084
16095
|
};
|
|
16085
16096
|
function Hu(r, t, e) {
|
|
16086
16097
|
var n = t[1][0] - t[0][0], i = t[1][1] - t[0][1], o = r.clipExtent && r.clipExtent();
|
|
16087
|
-
r.scale(150).translate([0, 0]), o != null && r.clipExtent(null),
|
|
16098
|
+
r.scale(150).translate([0, 0]), o != null && r.clipExtent(null), rf(e, r.stream(Xa));
|
|
16088
16099
|
var s = Xa.result(), a = Math.min(n / (s[1][0] - s[0][0]), i / (s[1][1] - s[0][1])), u = +t[0][0] + (n - a * (s[1][0] + s[0][0])) / 2, l = +t[0][1] + (i - a * (s[1][1] + s[0][1])) / 2;
|
|
16089
16100
|
return o != null && r.clipExtent(o), r.scale(a * 150).translate([u, l]);
|
|
16090
16101
|
}
|
|
16091
|
-
function
|
|
16102
|
+
function _f(r, t, e) {
|
|
16092
16103
|
return Hu(r, [[0, 0], t], e);
|
|
16093
16104
|
}
|
|
16094
|
-
var Wa = 16,
|
|
16105
|
+
var Wa = 16, Ef = bt(30 * tn);
|
|
16095
16106
|
function Ha(r, t) {
|
|
16096
|
-
return +t ?
|
|
16107
|
+
return +t ? Cf(r, t) : If(r);
|
|
16097
16108
|
}
|
|
16098
|
-
function
|
|
16109
|
+
function If(r) {
|
|
16099
16110
|
return Wu({
|
|
16100
16111
|
point: function(t, e) {
|
|
16101
16112
|
t = r(t, e), this.stream.point(t[0], t[1]);
|
|
16102
16113
|
}
|
|
16103
16114
|
});
|
|
16104
16115
|
}
|
|
16105
|
-
function
|
|
16106
|
-
function e(n, i, o, s, a, u, l, c, f, h, g, p,
|
|
16107
|
-
var
|
|
16108
|
-
if (C > 4 * t &&
|
|
16109
|
-
var
|
|
16110
|
-
(W * W / C > t || ne((
|
|
16116
|
+
function Cf(r, t) {
|
|
16117
|
+
function e(n, i, o, s, a, u, l, c, f, h, g, p, y, m) {
|
|
16118
|
+
var d = l - n, E = c - i, C = d * d + E * E;
|
|
16119
|
+
if (C > 4 * t && y--) {
|
|
16120
|
+
var S = s + h, N = a + g, w = u + p, T = Wi(S * S + N * N + w * w), A = li(w /= T), L = ne(ne(w) - 1) < vt || ne(o - f) < vt ? (o + f) / 2 : Gi(N, S), F = r(L, A), X = F[0], R = F[1], Y = X - n, D = R - i, W = E * Y - d * D;
|
|
16121
|
+
(W * W / C > t || ne((d * Y + E * D) / C - 0.5) > 0.3 || s * h + a * g + u * p < Ef) && (e(n, i, o, s, a, u, X, R, L, S /= T, N /= T, w, y, m), m.point(X, R), e(X, R, L, S, N, w, l, c, f, h, g, p, y, m));
|
|
16111
16122
|
}
|
|
16112
16123
|
}
|
|
16113
16124
|
return function(n) {
|
|
16114
|
-
var i, o, s, a, u, l, c, f, h, g, p,
|
|
16115
|
-
point:
|
|
16125
|
+
var i, o, s, a, u, l, c, f, h, g, p, y, m = {
|
|
16126
|
+
point: d,
|
|
16116
16127
|
lineStart: E,
|
|
16117
|
-
lineEnd:
|
|
16128
|
+
lineEnd: S,
|
|
16118
16129
|
polygonStart: function() {
|
|
16119
|
-
n.polygonStart(),
|
|
16130
|
+
n.polygonStart(), m.lineStart = N;
|
|
16120
16131
|
},
|
|
16121
16132
|
polygonEnd: function() {
|
|
16122
|
-
n.polygonEnd(),
|
|
16133
|
+
n.polygonEnd(), m.lineStart = E;
|
|
16123
16134
|
}
|
|
16124
16135
|
};
|
|
16125
|
-
function
|
|
16136
|
+
function d(A, L) {
|
|
16126
16137
|
A = r(A, L), n.point(A[0], A[1]);
|
|
16127
16138
|
}
|
|
16128
16139
|
function E() {
|
|
16129
|
-
f = NaN,
|
|
16140
|
+
f = NaN, m.point = C, n.lineStart();
|
|
16130
16141
|
}
|
|
16131
16142
|
function C(A, L) {
|
|
16132
16143
|
var F = Vi([A, L]), X = r(A, L);
|
|
16133
|
-
e(f, h, c, g, p,
|
|
16144
|
+
e(f, h, c, g, p, y, f = X[0], h = X[1], c = A, g = F[0], p = F[1], y = F[2], Wa, n), n.point(f, h);
|
|
16134
16145
|
}
|
|
16135
|
-
function
|
|
16136
|
-
|
|
16146
|
+
function S() {
|
|
16147
|
+
m.point = d, n.lineEnd();
|
|
16137
16148
|
}
|
|
16138
16149
|
function N() {
|
|
16139
|
-
E(),
|
|
16150
|
+
E(), m.point = w, m.lineEnd = T;
|
|
16140
16151
|
}
|
|
16141
|
-
function
|
|
16142
|
-
C(i = A, L), o = f, s = h, a = g, u = p, l =
|
|
16152
|
+
function w(A, L) {
|
|
16153
|
+
C(i = A, L), o = f, s = h, a = g, u = p, l = y, m.point = C;
|
|
16143
16154
|
}
|
|
16144
16155
|
function T() {
|
|
16145
|
-
e(f, h, c, g, p,
|
|
16156
|
+
e(f, h, c, g, p, y, o, s, i, a, u, l, Wa, n), m.lineEnd = S, S();
|
|
16146
16157
|
}
|
|
16147
|
-
return
|
|
16158
|
+
return m;
|
|
16148
16159
|
};
|
|
16149
16160
|
}
|
|
16150
|
-
var
|
|
16161
|
+
var Nf = Wu({
|
|
16151
16162
|
point: function(r, t) {
|
|
16152
16163
|
this.stream.point(r * tn, t * tn);
|
|
16153
16164
|
}
|
|
16154
16165
|
});
|
|
16155
|
-
function
|
|
16156
|
-
return
|
|
16166
|
+
function xf(r) {
|
|
16167
|
+
return Sf(function() {
|
|
16157
16168
|
return r;
|
|
16158
16169
|
})();
|
|
16159
16170
|
}
|
|
16160
|
-
function
|
|
16161
|
-
var t, e = 150, n = 480, i = 250, o, s, a = 0, u = 0, l = 0, c = 0, f = 0, h, g, p = null,
|
|
16171
|
+
function Sf(r) {
|
|
16172
|
+
var t, e = 150, n = 480, i = 250, o, s, a = 0, u = 0, l = 0, c = 0, f = 0, h, g, p = null, y = Ya, m = null, d, E, C, S = qa, N = 0.5, w = Ha(X, N), T, A;
|
|
16162
16173
|
function L(D) {
|
|
16163
16174
|
return D = g(D[0] * tn, D[1] * tn), [D[0] * e + o, s - D[1] * e];
|
|
16164
16175
|
}
|
|
@@ -16169,11 +16180,11 @@ function xf(r) {
|
|
|
16169
16180
|
return D = t(D, W), [D[0] * e + o, s - D[1] * e];
|
|
16170
16181
|
}
|
|
16171
16182
|
L.stream = function(D) {
|
|
16172
|
-
return T && A === D ? T : T =
|
|
16183
|
+
return T && A === D ? T : T = Nf(y(h, w(S(A = D))));
|
|
16173
16184
|
}, L.clipAngle = function(D) {
|
|
16174
|
-
return arguments.length ? (
|
|
16185
|
+
return arguments.length ? (y = +D ? mf(p = D * tn, 6 * tn) : (p = null, Ya), Y()) : p * Nr;
|
|
16175
16186
|
}, L.clipExtent = function(D) {
|
|
16176
|
-
return arguments.length ? (
|
|
16187
|
+
return arguments.length ? (S = D == null ? (m = d = E = C = null, qa) : cf(m = +D[0][0], d = +D[0][1], E = +D[1][0], C = +D[1][1]), Y()) : m == null ? null : [[m, d], [E, C]];
|
|
16177
16188
|
}, L.scale = function(D) {
|
|
16178
16189
|
return arguments.length ? (e = +D, R()) : e;
|
|
16179
16190
|
}, L.translate = function(D) {
|
|
@@ -16183,14 +16194,14 @@ function xf(r) {
|
|
|
16183
16194
|
}, L.rotate = function(D) {
|
|
16184
16195
|
return arguments.length ? (l = D[0] % 360 * tn, c = D[1] % 360 * tn, f = D.length > 2 ? D[2] % 360 * tn : 0, R()) : [l * Nr, c * Nr, f * Nr];
|
|
16185
16196
|
}, L.precision = function(D) {
|
|
16186
|
-
return arguments.length ? (
|
|
16197
|
+
return arguments.length ? (w = Ha(X, N = D * D), Y()) : Wi(N);
|
|
16187
16198
|
}, L.fitExtent = function(D, W) {
|
|
16188
16199
|
return Hu(L, D, W);
|
|
16189
16200
|
}, L.fitSize = function(D, W) {
|
|
16190
|
-
return
|
|
16201
|
+
return _f(L, D, W);
|
|
16191
16202
|
};
|
|
16192
16203
|
function R() {
|
|
16193
|
-
g = Vu(h =
|
|
16204
|
+
g = Vu(h = of(l, c, f), t);
|
|
16194
16205
|
var D = t(a, u);
|
|
16195
16206
|
return o = n - D[0] * e, s = i + D[1] * e, Y();
|
|
16196
16207
|
}
|
|
@@ -16219,10 +16230,10 @@ function Ku(r) {
|
|
|
16219
16230
|
];
|
|
16220
16231
|
};
|
|
16221
16232
|
}
|
|
16222
|
-
var
|
|
16233
|
+
var wf = ju(function(r) {
|
|
16223
16234
|
return Wi(2 / (1 + r));
|
|
16224
16235
|
});
|
|
16225
|
-
|
|
16236
|
+
wf.invert = Ku(function(r) {
|
|
16226
16237
|
return 2 * li(r / 2);
|
|
16227
16238
|
});
|
|
16228
16239
|
var Qu = ju(function(r) {
|
|
@@ -16231,14 +16242,14 @@ var Qu = ju(function(r) {
|
|
|
16231
16242
|
Qu.invert = Ku(function(r) {
|
|
16232
16243
|
return r;
|
|
16233
16244
|
});
|
|
16234
|
-
function
|
|
16235
|
-
return
|
|
16245
|
+
function Lf() {
|
|
16246
|
+
return xf(Qu).scale(79.4188).clipAngle(180 - 1e-3);
|
|
16236
16247
|
}
|
|
16237
16248
|
function ja(r, t) {
|
|
16238
16249
|
return [r, t];
|
|
16239
16250
|
}
|
|
16240
16251
|
ja.invert = ja;
|
|
16241
|
-
function
|
|
16252
|
+
function bf(r, t, e) {
|
|
16242
16253
|
e = e || {};
|
|
16243
16254
|
var n = e.units || "kilometers", i = e.steps || 8;
|
|
16244
16255
|
if (!r)
|
|
@@ -16272,15 +16283,15 @@ function ko(r, t, e, n) {
|
|
|
16272
16283
|
var i = r.properties || {}, o = r.type === "Feature" ? r.geometry : r;
|
|
16273
16284
|
if (o.type === "GeometryCollection") {
|
|
16274
16285
|
var s = [];
|
|
16275
|
-
return fu(r, function(
|
|
16276
|
-
var
|
|
16277
|
-
|
|
16286
|
+
return fu(r, function(y) {
|
|
16287
|
+
var m = ko(y, t, e, n);
|
|
16288
|
+
m && s.push(m);
|
|
16278
16289
|
}), Os(s);
|
|
16279
16290
|
}
|
|
16280
|
-
var a =
|
|
16291
|
+
var a = Pf(o), u = {
|
|
16281
16292
|
type: o.type,
|
|
16282
16293
|
coordinates: Ju(o.coordinates, a)
|
|
16283
|
-
}, l = new Hs(), c = l.read(u), f =
|
|
16294
|
+
}, l = new Hs(), c = l.read(u), f = Tc(Dc(t, e), "meters"), h = zt.bufferOp(c, f, n), g = new Iu();
|
|
16284
16295
|
if (h = g.write(h), !Zu(h.coordinates)) {
|
|
16285
16296
|
var p = {
|
|
16286
16297
|
type: h.type,
|
|
@@ -16302,11 +16313,11 @@ function $u(r, t) {
|
|
|
16302
16313
|
return $u(e, t);
|
|
16303
16314
|
});
|
|
16304
16315
|
}
|
|
16305
|
-
function
|
|
16306
|
-
var t =
|
|
16307
|
-
return
|
|
16316
|
+
function Pf(r) {
|
|
16317
|
+
var t = Bc(r).geometry.coordinates, e = [-t[0], -t[1]];
|
|
16318
|
+
return Lf().rotate(e).scale(Ie);
|
|
16308
16319
|
}
|
|
16309
|
-
function
|
|
16320
|
+
function Rf(r, t) {
|
|
16310
16321
|
var e = Vo(r), n = Vo(t), i = r.properties || {}, o = su.difference(
|
|
16311
16322
|
e.coordinates,
|
|
16312
16323
|
n.coordinates
|
|
@@ -16319,7 +16330,7 @@ function Ka(r) {
|
|
|
16319
16330
|
t && e[0] - t[0] >= 180 ? e[0] -= 360 : t && e[0] - t[0] < -180 && (e[0] += 360), t = e;
|
|
16320
16331
|
}
|
|
16321
16332
|
function Qa(r, t) {
|
|
16322
|
-
const e =
|
|
16333
|
+
const e = Rf(
|
|
16323
16334
|
{
|
|
16324
16335
|
type: "Polygon",
|
|
16325
16336
|
coordinates: [
|
|
@@ -16337,7 +16348,7 @@ function Qa(r, t) {
|
|
|
16337
16348
|
if (!e)
|
|
16338
16349
|
return;
|
|
16339
16350
|
e.properties = { isMask: "y" };
|
|
16340
|
-
const n =
|
|
16351
|
+
const n = bf(r, 0);
|
|
16341
16352
|
if (n.geometry.type === "Polygon")
|
|
16342
16353
|
for (const i of n.geometry.coordinates)
|
|
16343
16354
|
Ka(i);
|
|
@@ -16354,7 +16365,7 @@ let Za = {
|
|
|
16354
16365
|
type: "FeatureCollection",
|
|
16355
16366
|
features: []
|
|
16356
16367
|
};
|
|
16357
|
-
function
|
|
16368
|
+
function Of(r, t, e = !0, n = !0, i = {}, o = {}, s = {
|
|
16358
16369
|
fill: {
|
|
16359
16370
|
paint: {
|
|
16360
16371
|
"fill-color": "#000",
|
|
@@ -16394,79 +16405,79 @@ function Rf(r, t, e = !0, n = !0, i = {}, o = {}, s = {
|
|
|
16394
16405
|
r.loaded() ? h() : r.once("load", () => {
|
|
16395
16406
|
h();
|
|
16396
16407
|
});
|
|
16397
|
-
const g = (
|
|
16408
|
+
const g = (d) => {
|
|
16398
16409
|
a == null || a({
|
|
16399
16410
|
type: "mapClick",
|
|
16400
|
-
coordinates: [
|
|
16411
|
+
coordinates: [d.lngLat.lng, d.lngLat.lat]
|
|
16401
16412
|
});
|
|
16402
16413
|
}, p = () => {
|
|
16403
|
-
let
|
|
16404
|
-
const E = r.getZoom() > 9 ? [(
|
|
16414
|
+
let d;
|
|
16415
|
+
const E = r.getZoom() > 9 ? [(d = r.getCenter().wrap()).lng, d.lat] : void 0;
|
|
16405
16416
|
u !== E && (u = E, a == null || a({ type: "proximityChange", proximity: E }));
|
|
16406
16417
|
};
|
|
16407
|
-
function
|
|
16418
|
+
function y(d = !1) {
|
|
16408
16419
|
if (!t)
|
|
16409
16420
|
throw new Error();
|
|
16410
16421
|
const E = document.createElement("div");
|
|
16411
|
-
return
|
|
16422
|
+
return d && E.classList.add("marker-interactive"), new kc({
|
|
16412
16423
|
props: { displayIn: "maplibre" },
|
|
16413
16424
|
target: E
|
|
16414
16425
|
}), new t.Marker({ element: E, offset: [1, -13] });
|
|
16415
16426
|
}
|
|
16416
16427
|
return {
|
|
16417
|
-
setEventHandler(
|
|
16418
|
-
|
|
16428
|
+
setEventHandler(d) {
|
|
16429
|
+
d ? (a = d, r.on("moveend", p), p(), r.on("click", g)) : (r.off("moveend", p), a == null || a({ type: "proximityChange", proximity: void 0 }), a = void 0, r.off("click", g));
|
|
16419
16430
|
},
|
|
16420
|
-
flyTo(
|
|
16421
|
-
r.flyTo({ center:
|
|
16431
|
+
flyTo(d, E) {
|
|
16432
|
+
r.flyTo({ center: d, zoom: E, ...i });
|
|
16422
16433
|
},
|
|
16423
|
-
fitBounds(
|
|
16434
|
+
fitBounds(d, E, C) {
|
|
16424
16435
|
r.fitBounds(
|
|
16425
16436
|
[
|
|
16426
|
-
[
|
|
16427
|
-
[
|
|
16437
|
+
[d[0], d[1]],
|
|
16438
|
+
[d[2], d[3]]
|
|
16428
16439
|
],
|
|
16429
16440
|
{ padding: E, maxZoom: C, ...o }
|
|
16430
16441
|
);
|
|
16431
16442
|
},
|
|
16432
|
-
indicateReverse(
|
|
16433
|
-
r.getCanvasContainer().style.cursor =
|
|
16443
|
+
indicateReverse(d) {
|
|
16444
|
+
r.getCanvasContainer().style.cursor = d ? "crosshair" : "";
|
|
16434
16445
|
},
|
|
16435
|
-
setReverseMarker(
|
|
16436
|
-
!t || !e || (f ?
|
|
16446
|
+
setReverseMarker(d) {
|
|
16447
|
+
!t || !e || (f ? d ? f.setLngLat(d) : (f.remove(), f = void 0) : d && (f = (typeof e == "object" ? new t.Marker(e) : y()).setLngLat(d).addTo(r), f.getElement().classList.add("marker-reverse")));
|
|
16437
16448
|
},
|
|
16438
|
-
setMarkers(
|
|
16449
|
+
setMarkers(d, E) {
|
|
16439
16450
|
if (!e)
|
|
16440
16451
|
return;
|
|
16441
|
-
function C(
|
|
16452
|
+
function C(S) {
|
|
16442
16453
|
var N;
|
|
16443
|
-
(N = r.getSource("full-geom")) == null || N.setData(
|
|
16454
|
+
(N = r.getSource("full-geom")) == null || N.setData(S);
|
|
16444
16455
|
}
|
|
16445
|
-
for (const
|
|
16446
|
-
|
|
16456
|
+
for (const S of l)
|
|
16457
|
+
S.remove();
|
|
16447
16458
|
if (l.length = 0, C(Za), !!t) {
|
|
16448
16459
|
if (E) {
|
|
16449
|
-
let
|
|
16460
|
+
let S = !1;
|
|
16450
16461
|
if (E.geometry.type === "GeometryCollection") {
|
|
16451
16462
|
const N = E.geometry.geometries.filter(
|
|
16452
|
-
(
|
|
16463
|
+
(w) => w.type === "Polygon" || w.type === "MultiPolygon"
|
|
16453
16464
|
);
|
|
16454
16465
|
if (N.length > 0) {
|
|
16455
|
-
let
|
|
16466
|
+
let w = N.pop();
|
|
16456
16467
|
for (const T of N)
|
|
16457
|
-
|
|
16458
|
-
Qa({ ...E, geometry:
|
|
16468
|
+
w = Mc(w, T);
|
|
16469
|
+
Qa({ ...E, geometry: w }, C), S = !0;
|
|
16459
16470
|
} else {
|
|
16460
|
-
const
|
|
16471
|
+
const w = E.geometry.geometries.filter(
|
|
16461
16472
|
(T) => T.type === "LineString" || T.type === "MultiLineString"
|
|
16462
16473
|
);
|
|
16463
|
-
|
|
16474
|
+
w.length > 0 && (C({
|
|
16464
16475
|
...E,
|
|
16465
|
-
geometry: { type: "GeometryCollection", geometries:
|
|
16466
|
-
}),
|
|
16476
|
+
geometry: { type: "GeometryCollection", geometries: w }
|
|
16477
|
+
}), S = !0);
|
|
16467
16478
|
}
|
|
16468
16479
|
}
|
|
16469
|
-
if (!
|
|
16480
|
+
if (!S) {
|
|
16470
16481
|
if (E.geometry.type === "Polygon" || E.geometry.type === "MultiPolygon")
|
|
16471
16482
|
Qa(E, C);
|
|
16472
16483
|
else if (E.geometry.type === "LineString" || E.geometry.type === "MultiLineString") {
|
|
@@ -16475,38 +16486,38 @@ function Rf(r, t, e = !0, n = !0, i = {}, o = {}, s = {
|
|
|
16475
16486
|
}
|
|
16476
16487
|
}
|
|
16477
16488
|
e && l.push(
|
|
16478
|
-
(typeof e == "object" ? new t.Marker(e) :
|
|
16489
|
+
(typeof e == "object" ? new t.Marker(e) : y()).setLngLat(E.center).addTo(r)
|
|
16479
16490
|
);
|
|
16480
16491
|
}
|
|
16481
16492
|
if (n)
|
|
16482
|
-
for (const
|
|
16483
|
-
if (
|
|
16493
|
+
for (const S of d ?? []) {
|
|
16494
|
+
if (S === E)
|
|
16484
16495
|
continue;
|
|
16485
|
-
const N = (typeof n == "object" ? new t.Marker(n) :
|
|
16496
|
+
const N = (typeof n == "object" ? new t.Marker(n) : y(!0)).setLngLat(S.center).setPopup(
|
|
16486
16497
|
new t.Popup({
|
|
16487
16498
|
offset: [1, -27],
|
|
16488
16499
|
closeButton: !1,
|
|
16489
16500
|
closeOnMove: !0,
|
|
16490
16501
|
className: "maptiler-gc-popup"
|
|
16491
|
-
}).setText(
|
|
16492
|
-
).addTo(r),
|
|
16493
|
-
|
|
16494
|
-
T.stopPropagation(), a == null || a({ type: "markerClick", id:
|
|
16495
|
-
}),
|
|
16496
|
-
a == null || a({ type: "markerMouseEnter", id:
|
|
16497
|
-
}),
|
|
16498
|
-
a == null || a({ type: "markerMouseLeave", id:
|
|
16502
|
+
}).setText(S.place_name.replace(/,.*/, ""))
|
|
16503
|
+
).addTo(r), w = N.getElement();
|
|
16504
|
+
w.addEventListener("click", (T) => {
|
|
16505
|
+
T.stopPropagation(), a == null || a({ type: "markerClick", id: S.id });
|
|
16506
|
+
}), w.addEventListener("mouseenter", () => {
|
|
16507
|
+
a == null || a({ type: "markerMouseEnter", id: S.id }), N.togglePopup();
|
|
16508
|
+
}), w.addEventListener("mouseleave", () => {
|
|
16509
|
+
a == null || a({ type: "markerMouseLeave", id: S.id }), N.togglePopup();
|
|
16499
16510
|
}), l.push(N);
|
|
16500
16511
|
}
|
|
16501
16512
|
}
|
|
16502
16513
|
},
|
|
16503
|
-
setSelectedMarker(
|
|
16504
|
-
c && c.getElement().classList.toggle("marker-selected", !1), c =
|
|
16514
|
+
setSelectedMarker(d) {
|
|
16515
|
+
c && c.getElement().classList.toggle("marker-selected", !1), c = d > -1 ? l[d] : void 0, c == null || c.getElement().classList.toggle("marker-selected", !0);
|
|
16505
16516
|
}
|
|
16506
16517
|
};
|
|
16507
16518
|
}
|
|
16508
16519
|
var Cn, Qr;
|
|
16509
|
-
class
|
|
16520
|
+
class Tf extends EventTarget {
|
|
16510
16521
|
constructor(e) {
|
|
16511
16522
|
super();
|
|
16512
16523
|
vs(this, Cn, void 0);
|
|
@@ -16523,7 +16534,7 @@ class Of extends EventTarget {
|
|
|
16523
16534
|
fullGeometryStyle: a,
|
|
16524
16535
|
...u
|
|
16525
16536
|
} = Vn(this, Qr), l = typeof s == "boolean" ? {} : s, c = this.getExtraProps(e, n), h = {
|
|
16526
|
-
mapController:
|
|
16537
|
+
mapController: Of(
|
|
16527
16538
|
e,
|
|
16528
16539
|
this.getMapLibreGl(),
|
|
16529
16540
|
i,
|
|
@@ -16540,7 +16551,7 @@ class Of extends EventTarget {
|
|
|
16540
16551
|
};
|
|
16541
16552
|
if (!h.apiKey)
|
|
16542
16553
|
throw new Error("no apiKey provided");
|
|
16543
|
-
wo(this, Cn, new
|
|
16554
|
+
wo(this, Cn, new uc({ target: n, props: h }));
|
|
16544
16555
|
for (const g of [
|
|
16545
16556
|
"select",
|
|
16546
16557
|
"pick",
|
|
@@ -16588,9 +16599,9 @@ class Of extends EventTarget {
|
|
|
16588
16599
|
}
|
|
16589
16600
|
}
|
|
16590
16601
|
Cn = new WeakMap(), Qr = new WeakMap();
|
|
16591
|
-
class
|
|
16602
|
+
class Af extends Tf {
|
|
16592
16603
|
getMapLibreGl() {
|
|
16593
|
-
return
|
|
16604
|
+
return yl;
|
|
16594
16605
|
}
|
|
16595
16606
|
getExtraProps(t, e) {
|
|
16596
16607
|
const n = {};
|
|
@@ -16603,6 +16614,6 @@ class Mf extends Of {
|
|
|
16603
16614
|
}
|
|
16604
16615
|
}
|
|
16605
16616
|
export {
|
|
16606
|
-
|
|
16617
|
+
Af as GeocodingControl
|
|
16607
16618
|
};
|
|
16608
16619
|
//# sourceMappingURL=maptilersdk.js.map
|