@maptiler/geocoding-control 1.2.3 → 1.2.4
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/leaflet.js +1 -1
- package/leaflet.umd.js +1 -1
- package/maplibregl-controller.js +761 -759
- package/maplibregl-controller.js.map +1 -1
- package/maplibregl-controller.umd.js +3 -3
- package/maplibregl-controller.umd.js.map +1 -1
- package/maplibregl.js +357 -355
- package/maplibregl.js.map +1 -1
- package/maplibregl.umd.js +4 -4
- package/maplibregl.umd.js.map +1 -1
- package/maptilersdk.js +357 -355
- package/maptilersdk.js.map +1 -1
- package/maptilersdk.umd.js +4 -4
- package/maptilersdk.umd.js.map +1 -1
- package/openlayers.js +1 -1
- package/openlayers.umd.js +1 -1
- package/package.json +1 -1
- package/react.js +1 -1
- package/react.umd.js +1 -1
- package/svelte/GeocodingControl.svelte +1 -1
- package/svelte/maplibregl-controller.js +15 -6
- package/vanilla.js +1 -1
- package/vanilla.umd.js +1 -1
package/maptilersdk.js
CHANGED
|
@@ -256,14 +256,14 @@ function rc(n, t) {
|
|
|
256
256
|
}
|
|
257
257
|
function nc(n, t, e, r, i, o, s, a, u, l, c, f) {
|
|
258
258
|
let h = n.length, g = o.length, p = h;
|
|
259
|
-
const
|
|
259
|
+
const y = {};
|
|
260
260
|
for (; p--; )
|
|
261
|
-
|
|
262
|
-
const d = [],
|
|
261
|
+
y[n[p].key] = p;
|
|
262
|
+
const d = [], v = /* @__PURE__ */ new Map(), C = /* @__PURE__ */ new Map(), I = [];
|
|
263
263
|
for (p = g; p--; ) {
|
|
264
264
|
const R = f(i, o, p), D = e(R);
|
|
265
265
|
let b = s.get(D);
|
|
266
|
-
b ?
|
|
266
|
+
b ? I.push(() => b.p(R, t)) : (b = l(D, R), b.c()), v.set(D, d[p] = b), D in y && C.set(D, Math.abs(p - y[D]));
|
|
267
267
|
}
|
|
268
268
|
const N = /* @__PURE__ */ new Set(), L = /* @__PURE__ */ new Set();
|
|
269
269
|
function T(R) {
|
|
@@ -271,15 +271,15 @@ function nc(n, t, e, r, i, o, s, a, u, l, c, f) {
|
|
|
271
271
|
}
|
|
272
272
|
for (; h && g; ) {
|
|
273
273
|
const R = d[g - 1], D = n[h - 1], b = R.key, A = D.key;
|
|
274
|
-
R === D ? (c = R.first, h--, g--) :
|
|
274
|
+
R === D ? (c = R.first, h--, g--) : v.has(A) ? !s.has(b) || N.has(b) ? T(R) : L.has(A) ? h-- : C.get(b) > C.get(A) ? (L.add(b), T(R)) : (N.add(A), h--) : (u(D, s), h--);
|
|
275
275
|
}
|
|
276
276
|
for (; h--; ) {
|
|
277
277
|
const R = n[h];
|
|
278
|
-
|
|
278
|
+
v.has(R.key) || u(R, s);
|
|
279
279
|
}
|
|
280
280
|
for (; g; )
|
|
281
281
|
T(d[g - 1]);
|
|
282
|
-
return Cn(
|
|
282
|
+
return Cn(I), d;
|
|
283
283
|
}
|
|
284
284
|
function On(n) {
|
|
285
285
|
n && n.c();
|
|
@@ -730,14 +730,14 @@ function vc(n) {
|
|
|
730
730
|
n[0].id.startsWith("poi.") || !/*imageUrl*/
|
|
731
731
|
n[5]) && !/*isReverse*/
|
|
732
732
|
n[7]
|
|
733
|
-
), g, p,
|
|
733
|
+
), g, p, y = (
|
|
734
734
|
/*isReverse*/
|
|
735
735
|
(n[7] ? "" : (
|
|
736
736
|
/*feature*/
|
|
737
737
|
n[0].place_name.replace(/[^,]*,?\s*/, "")
|
|
738
738
|
)) + ""
|
|
739
|
-
), d,
|
|
740
|
-
function
|
|
739
|
+
), d, v, C;
|
|
740
|
+
function I(b, A) {
|
|
741
741
|
var Y, G;
|
|
742
742
|
return A & /*feature*/
|
|
743
743
|
1 && (e = null), A & /*feature*/
|
|
@@ -758,10 +758,10 @@ function vc(n) {
|
|
|
758
758
|
)
|
|
759
759
|
);
|
|
760
760
|
}
|
|
761
|
-
let N =
|
|
761
|
+
let N = I(n, -1), L = N(n), T = h && Ea(n);
|
|
762
762
|
return {
|
|
763
763
|
c() {
|
|
764
|
-
t = ht("li"), L.c(), o = Ye(), s = ht("span"), a = ht("span"), u = ht("span"), c = Rn(l), f = Ye(), T && T.c(), g = Ye(), p = ht("span"), d = Rn(
|
|
764
|
+
t = ht("li"), L.c(), o = Ye(), s = ht("span"), a = ht("span"), u = ht("span"), c = Rn(l), f = Ye(), T && T.c(), g = Ye(), p = ht("span"), d = Rn(y), w(u, "class", "primary svelte-ltkwvy"), w(a, "class", "svelte-ltkwvy"), w(p, "class", "line2 svelte-ltkwvy"), w(s, "class", "texts svelte-ltkwvy"), w(t, "tabindex", "0"), w(
|
|
765
765
|
t,
|
|
766
766
|
"data-selected",
|
|
767
767
|
/*selected*/
|
|
@@ -774,7 +774,7 @@ function vc(n) {
|
|
|
774
774
|
);
|
|
775
775
|
},
|
|
776
776
|
m(b, A) {
|
|
777
|
-
Pt(b, t, A), L.m(t, null), rt(t, o), rt(t, s), rt(s, a), rt(a, u), rt(u, c), rt(a, f), T && T.m(a, null), rt(s, g), rt(s, p), rt(p, d),
|
|
777
|
+
Pt(b, t, A), L.m(t, null), rt(t, o), rt(t, s), rt(s, a), rt(a, u), rt(u, c), rt(a, f), T && T.m(a, null), rt(s, g), rt(s, p), rt(p, d), v || (C = [
|
|
778
778
|
Se(
|
|
779
779
|
t,
|
|
780
780
|
"mouseenter",
|
|
@@ -787,11 +787,11 @@ function vc(n) {
|
|
|
787
787
|
/*focus_handler*/
|
|
788
788
|
n[13]
|
|
789
789
|
)
|
|
790
|
-
],
|
|
790
|
+
], v = !0);
|
|
791
791
|
},
|
|
792
792
|
p(b, [A]) {
|
|
793
793
|
var Y, G;
|
|
794
|
-
N === (N =
|
|
794
|
+
N === (N = I(b, A)) && L ? L.p(b, A) : (L.d(1), L = N(b), L && (L.c(), L.m(t, o))), A & /*feature*/
|
|
795
795
|
1 && l !== (l = /*isReverse*/
|
|
796
796
|
(b[7] ? (
|
|
797
797
|
/*feature*/
|
|
@@ -811,11 +811,11 @@ function vc(n) {
|
|
|
811
811
|
b[0].id.startsWith("poi.") || !/*imageUrl*/
|
|
812
812
|
b[5]) && !/*isReverse*/
|
|
813
813
|
b[7]), h ? T ? T.p(b, A) : (T = Ea(b), T.c(), T.m(a, null)) : T && (T.d(1), T = null), A & /*feature*/
|
|
814
|
-
1 &&
|
|
814
|
+
1 && y !== (y = /*isReverse*/
|
|
815
815
|
(b[7] ? "" : (
|
|
816
816
|
/*feature*/
|
|
817
817
|
b[0].place_name.replace(/[^,]*,?\s*/, "")
|
|
818
|
-
)) + "") && to(d,
|
|
818
|
+
)) + "") && to(d, y), A & /*selected*/
|
|
819
819
|
2 && w(
|
|
820
820
|
t,
|
|
821
821
|
"data-selected",
|
|
@@ -832,25 +832,25 @@ function vc(n) {
|
|
|
832
832
|
i: It,
|
|
833
833
|
o: It,
|
|
834
834
|
d(b) {
|
|
835
|
-
b && St(t), L.d(), T && T.d(),
|
|
835
|
+
b && St(t), L.d(), T && T.d(), v = !1, Cn(C);
|
|
836
836
|
}
|
|
837
837
|
};
|
|
838
838
|
}
|
|
839
839
|
function mc(n, t, e) {
|
|
840
|
-
var
|
|
840
|
+
var I;
|
|
841
841
|
let r, i, { feature: o } = t, { selected: s = !1 } = t, { showPlaceType: a } = t, { missingIconsCache: u } = t, { iconsBaseUrl: l } = t;
|
|
842
|
-
const c = (
|
|
842
|
+
const c = (I = o.properties) == null ? void 0 : I.categories;
|
|
843
843
|
let f, h, g = 0, p = o.place_type[0] === "reverse";
|
|
844
|
-
function
|
|
844
|
+
function y(N) {
|
|
845
845
|
h && u.add(h), e(10, g++, g);
|
|
846
846
|
}
|
|
847
847
|
function d(N) {
|
|
848
848
|
ma.call(this, n, N);
|
|
849
849
|
}
|
|
850
|
-
function
|
|
850
|
+
function v(N) {
|
|
851
851
|
ma.call(this, n, N);
|
|
852
852
|
}
|
|
853
|
-
const
|
|
853
|
+
const C = (N) => y(N.currentTarget);
|
|
854
854
|
return n.$$set = (N) => {
|
|
855
855
|
"feature" in N && e(0, o = N.feature), "selected" in N && e(1, s = N.selected), "showPlaceType" in N && e(2, a = N.showPlaceType), "missingIconsCache" in N && e(9, u = N.missingIconsCache), "iconsBaseUrl" in N && e(3, l = N.iconsBaseUrl);
|
|
856
856
|
}, n.$$.update = () => {
|
|
@@ -871,13 +871,13 @@ function mc(n, t, e) {
|
|
|
871
871
|
h,
|
|
872
872
|
i,
|
|
873
873
|
p,
|
|
874
|
-
|
|
874
|
+
y,
|
|
875
875
|
u,
|
|
876
876
|
g,
|
|
877
877
|
r,
|
|
878
878
|
d,
|
|
879
|
-
|
|
880
|
-
|
|
879
|
+
v,
|
|
880
|
+
C
|
|
881
881
|
];
|
|
882
882
|
}
|
|
883
883
|
class yc extends Xn {
|
|
@@ -1147,21 +1147,21 @@ function Ws(n, t) {
|
|
|
1147
1147
|
} else {
|
|
1148
1148
|
let d;
|
|
1149
1149
|
g.length % 2 == 1 ? d = Math.floor(g.length / 2) : d = g.length / 2 - 1;
|
|
1150
|
-
let
|
|
1150
|
+
let v = 0;
|
|
1151
1151
|
if (d == 0)
|
|
1152
|
-
|
|
1152
|
+
v = l.indexOf(g[0]), c = l.substring(0, v).trim(), f = l.substring(v + 1).trim();
|
|
1153
1153
|
else {
|
|
1154
|
-
let
|
|
1155
|
-
for (;
|
|
1156
|
-
|
|
1157
|
-
c = l.substring(0,
|
|
1154
|
+
let C = 0, I = 0;
|
|
1155
|
+
for (; C <= d; )
|
|
1156
|
+
v = l.indexOf(g[C], I), I = v + 1, C++;
|
|
1157
|
+
c = l.substring(0, v).trim(), f = l.substring(v + 1).trim();
|
|
1158
1158
|
}
|
|
1159
1159
|
}
|
|
1160
1160
|
const p = c.split(".");
|
|
1161
1161
|
if (p.length == 2 && p[1] == 0 && p[1].length != 2)
|
|
1162
1162
|
throw new Error("invalid coordinates format");
|
|
1163
|
-
const
|
|
1164
|
-
if (
|
|
1163
|
+
const y = f.split(".");
|
|
1164
|
+
if (y.length == 2 && y[1] == 0 && y[1].length != 2)
|
|
1165
1165
|
throw new Error("invalid coordinates format");
|
|
1166
1166
|
if (/^\d+$/.test(c) || /^\d+$/.test(f))
|
|
1167
1167
|
throw new Error("degree only coordinate/s provided");
|
|
@@ -1888,7 +1888,7 @@ function Ta(n, t) {
|
|
|
1888
1888
|
};
|
|
1889
1889
|
}
|
|
1890
1890
|
function Yc(n) {
|
|
1891
|
-
let t, e, r, i, o, s, a, u, l, c, f, h, g, p,
|
|
1891
|
+
let t, e, r, i, o, s, a, u, l, c, f, h, g, p, y, d, v, C, I, N, L, T = !1;
|
|
1892
1892
|
o = new bc({}), f = new _u({});
|
|
1893
1893
|
let R = (
|
|
1894
1894
|
/*abortController*/
|
|
@@ -1924,9 +1924,9 @@ function Yc(n) {
|
|
|
1924
1924
|
)
|
|
1925
1925
|
);
|
|
1926
1926
|
}
|
|
1927
|
-
return ~(d = at(n)) && (
|
|
1927
|
+
return ~(d = at(n)) && (v = G[d] = Y[d](n)), {
|
|
1928
1928
|
c() {
|
|
1929
|
-
t = Ye(), e = ht("form"), r = ht("div"), i = ht("button"), On(o.$$.fragment), s = Ye(), a = ht("input"), u = Ye(), l = ht("div"), c = ht("button"), On(f.$$.fragment), h = Ye(), R && R.c(), g = Ye(), D && D.c(), p = Ye(), A && A.c(),
|
|
1929
|
+
t = Ye(), e = ht("form"), r = ht("div"), i = ht("button"), On(o.$$.fragment), s = Ye(), a = ht("input"), u = Ye(), l = ht("div"), c = ht("button"), On(f.$$.fragment), h = Ye(), R && R.c(), g = Ye(), D && D.c(), p = Ye(), A && A.c(), y = Ye(), v && v.c(), w(i, "class", "search-button svelte-zh3kmv"), w(i, "type", "button"), w(
|
|
1930
1930
|
a,
|
|
1931
1931
|
"placeholder",
|
|
1932
1932
|
/*placeholder*/
|
|
@@ -1946,7 +1946,7 @@ function Yc(n) {
|
|
|
1946
1946
|
"displayable",
|
|
1947
1947
|
/*searchValue*/
|
|
1948
1948
|
n[1] !== ""
|
|
1949
|
-
), w(r, "class", "input-group svelte-zh3kmv"), w(e, "tabindex", "0"), w(e, "class",
|
|
1949
|
+
), w(r, "class", "input-group svelte-zh3kmv"), w(e, "tabindex", "0"), w(e, "class", C = da(
|
|
1950
1950
|
/*className*/
|
|
1951
1951
|
n[2]
|
|
1952
1952
|
) + " svelte-zh3kmv"), cr(
|
|
@@ -1962,7 +1962,7 @@ function Yc(n) {
|
|
|
1962
1962
|
a,
|
|
1963
1963
|
/*searchValue*/
|
|
1964
1964
|
n[1]
|
|
1965
|
-
), rt(r, u), rt(r, l), rt(l, c), cn(f, c, null), rt(l, h), R && R.m(l, null), rt(r, g), D && D.m(r, null), rt(r, p), A && A.m(r, null), rt(e,
|
|
1965
|
+
), rt(r, u), rt(r, l), rt(l, c), cn(f, c, null), rt(l, h), R && R.m(l, null), rt(r, g), D && D.m(r, null), rt(r, p), A && A.m(r, null), rt(e, y), ~d && G[d].m(e, null), I = !0, N || (L = [
|
|
1966
1966
|
Se(
|
|
1967
1967
|
i,
|
|
1968
1968
|
"click",
|
|
@@ -2012,13 +2012,13 @@ function Yc(n) {
|
|
|
2012
2012
|
], N = !0);
|
|
2013
2013
|
},
|
|
2014
2014
|
p(x, B) {
|
|
2015
|
-
(!
|
|
2015
|
+
(!I || B[0] & /*placeholder*/
|
|
2016
2016
|
256) && w(
|
|
2017
2017
|
a,
|
|
2018
2018
|
"placeholder",
|
|
2019
2019
|
/*placeholder*/
|
|
2020
2020
|
x[8]
|
|
2021
|
-
), (!
|
|
2021
|
+
), (!I || B[0] & /*placeholder*/
|
|
2022
2022
|
256) && w(
|
|
2023
2023
|
a,
|
|
2024
2024
|
"aria-label",
|
|
@@ -2030,7 +2030,7 @@ function Yc(n) {
|
|
|
2030
2030
|
a,
|
|
2031
2031
|
/*searchValue*/
|
|
2032
2032
|
x[1]
|
|
2033
|
-
), (!
|
|
2033
|
+
), (!I || B[0] & /*clearButtonTitle*/
|
|
2034
2034
|
8) && w(
|
|
2035
2035
|
c,
|
|
2036
2036
|
"title",
|
|
@@ -2040,7 +2040,7 @@ function Yc(n) {
|
|
|
2040
2040
|
x[19] ? R ? B[0] & /*abortController*/
|
|
2041
2041
|
524288 && Ft(R, 1) : (R = Ra(), R.c(), Ft(R, 1), R.m(l, null)) : R && (Bo(), ee(R, 1, 1, () => {
|
|
2042
2042
|
R = null;
|
|
2043
|
-
}), Go()), (!
|
|
2043
|
+
}), Go()), (!I || B[0] & /*searchValue*/
|
|
2044
2044
|
2) && cr(
|
|
2045
2045
|
l,
|
|
2046
2046
|
"displayable",
|
|
@@ -2050,14 +2050,14 @@ function Yc(n) {
|
|
|
2050
2050
|
x[5] === !0 ? D ? (D.p(x, B), B[0] & /*enableReverse*/
|
|
2051
2051
|
32 && Ft(D, 1)) : (D = Oa(x), D.c(), Ft(D, 1), D.m(r, p)) : D && (Bo(), ee(D, 1, 1, () => {
|
|
2052
2052
|
D = null;
|
|
2053
|
-
}), Go()), A && A.p && (!
|
|
2053
|
+
}), Go()), A && A.p && (!I || B[1] & /*$$scope*/
|
|
2054
2054
|
134217728) && Xl(
|
|
2055
2055
|
A,
|
|
2056
2056
|
b,
|
|
2057
2057
|
x,
|
|
2058
2058
|
/*$$scope*/
|
|
2059
2059
|
x[58],
|
|
2060
|
-
|
|
2060
|
+
I ? ql(
|
|
2061
2061
|
b,
|
|
2062
2062
|
/*$$scope*/
|
|
2063
2063
|
x[58],
|
|
@@ -2070,13 +2070,13 @@ function Yc(n) {
|
|
|
2070
2070
|
null
|
|
2071
2071
|
);
|
|
2072
2072
|
let K = d;
|
|
2073
|
-
d = at(x), d === K ? ~d && G[d].p(x, B) : (
|
|
2073
|
+
d = at(x), d === K ? ~d && G[d].p(x, B) : (v && (Bo(), ee(G[K], 1, 1, () => {
|
|
2074
2074
|
G[K] = null;
|
|
2075
|
-
}), Go()), ~d ? (
|
|
2076
|
-
4 &&
|
|
2075
|
+
}), Go()), ~d ? (v = G[d], v ? v.p(x, B) : (v = G[d] = Y[d](x), v.c()), Ft(v, 1), v.m(e, null)) : v = null), (!I || B[0] & /*className*/
|
|
2076
|
+
4 && C !== (C = da(
|
|
2077
2077
|
/*className*/
|
|
2078
2078
|
x[2]
|
|
2079
|
-
) + " svelte-zh3kmv")) && w(e, "class",
|
|
2079
|
+
) + " svelte-zh3kmv")) && w(e, "class", C), (!I || B[0] & /*className, collapsed, searchValue*/
|
|
2080
2080
|
22) && cr(
|
|
2081
2081
|
e,
|
|
2082
2082
|
"can-collapse",
|
|
@@ -2086,10 +2086,10 @@ function Yc(n) {
|
|
|
2086
2086
|
);
|
|
2087
2087
|
},
|
|
2088
2088
|
i(x) {
|
|
2089
|
-
|
|
2089
|
+
I || (Ft(T), Ft(o.$$.fragment, x), Ft(f.$$.fragment, x), Ft(R), Ft(D), Ft(A, x), Ft(v), I = !0);
|
|
2090
2090
|
},
|
|
2091
2091
|
o(x) {
|
|
2092
|
-
ee(T), ee(o.$$.fragment, x), ee(f.$$.fragment, x), ee(R), ee(D), ee(A, x), ee(
|
|
2092
|
+
ee(T), ee(o.$$.fragment, x), ee(f.$$.fragment, x), ee(R), ee(D), ee(A, x), ee(v), I = !1;
|
|
2093
2093
|
},
|
|
2094
2094
|
d(x) {
|
|
2095
2095
|
x && (St(t), St(e)), fn(o), n[61](null), fn(f), R && R.d(), D && D.d(), A && A.d(x), ~d && G[d].d(), N = !1, Cn(L);
|
|
@@ -2097,7 +2097,7 @@ function Yc(n) {
|
|
|
2097
2097
|
};
|
|
2098
2098
|
}
|
|
2099
2099
|
function Wc(n, t, e) {
|
|
2100
|
-
let r, { $$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:
|
|
2100
|
+
let r, { $$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: d = () => !0 } = t, { flyTo: v = !0 } = t, { fuzzyMatch: C = !0 } = t, { language: I = void 0 } = t, { limit: N = void 0 } = t, { mapController: L = void 0 } = t, { minLength: T = 2 } = t, { noResultsMessage: R = "Oops! Looks like you're trying to predict something that's not quite right. We can't seem to find what you're looking for. Maybe try double-checking your spelling or try a different search term. Keep on typing - we'll do our best to get you where you need to go!" } = t, { placeholder: D = "Search" } = t, { proximity: b = [{ type: "server-geolocation" }] } = t, { reverseActive: A = p === "always" } = t, { reverseButtonTitle: Y = "toggle reverse geocoding" } = t, { searchValue: G = "" } = t, { showFullGeometry: at = !0 } = t, { showPlaceType: x = "ifNeeded" } = t, { showResultsWhileTyping: B = !0 } = t, { selectFirst: K = !0 } = t, { flyToSelected: _t = !1 } = t, { markerOnSelected: Qt = !0 } = t, { types: zt = void 0 } = t, { excludeTypes: Vr = !1 } = t, { zoom: Ie = 16 } = t, { maxZoom: De = 18 } = t, { apiUrl: Ue = "https://api.maptiler.com/geocoding" } = t, { fetchParameters: In = {} } = t, { iconsBaseUrl: sn = "https://cdn.maptiler.com/maptiler-geocoding-control/v1.2.4/icons/" } = t, { adjustUrlQuery: ps = (S) => {
|
|
2101
2101
|
} } = t;
|
|
2102
2102
|
function vl() {
|
|
2103
2103
|
Ur.focus();
|
|
@@ -2144,9 +2144,9 @@ function Wc(n, t, e) {
|
|
|
2144
2144
|
e(19, Hn = nr);
|
|
2145
2145
|
try {
|
|
2146
2146
|
const ot = vs(S), ir = new URLSearchParams();
|
|
2147
|
-
if (
|
|
2147
|
+
if (I !== void 0 && ir.set("language", Array.isArray(I) ? I.join(",") : I ?? ""), zt && ir.set("types", zt.join(",")), Vr && ir.set("excludeTypes", String(Vr)), u && ir.set("bbox", u.map((wo) => wo.toFixed(6)).join(",")), h && ir.set("country", Array.isArray(h) ? h.join(",") : h), !Ut && !ot) {
|
|
2148
2148
|
const wo = await Pc(L, b, nr);
|
|
2149
|
-
wo && ir.set("proximity", wo), (qe || !B) && ir.set("autocomplete", "false"), ir.set("fuzzyMatch", String(
|
|
2149
|
+
wo && ir.set("proximity", wo), (qe || !B) && ir.set("autocomplete", "false"), ir.set("fuzzyMatch", String(C));
|
|
2150
2150
|
}
|
|
2151
2151
|
N !== void 0 && (!ot || (zt == null ? void 0 : zt.length) === 1) && ir.set("limit", String(N)), ir.set("key", a), ps(ir);
|
|
2152
2152
|
const bo = Ue + "/" + encodeURIComponent(ot ? ot.decimalLongitude + "," + ot.decimalLatitude : S) + ".json?" + ir.toString();
|
|
@@ -2188,7 +2188,7 @@ function Wc(n, t, e) {
|
|
|
2188
2188
|
}
|
|
2189
2189
|
function Cl() {
|
|
2190
2190
|
var qe;
|
|
2191
|
-
if (!(Vt != null && Vt.length) || !
|
|
2191
|
+
if (!(Vt != null && Vt.length) || !v)
|
|
2192
2192
|
return;
|
|
2193
2193
|
const S = [180, 90, -180, -90], Ut = !Vt.some((nr) => !nr.matching_text);
|
|
2194
2194
|
for (const nr of Vt)
|
|
@@ -2239,7 +2239,7 @@ function Wc(n, t, e) {
|
|
|
2239
2239
|
}, Fl = () => {
|
|
2240
2240
|
};
|
|
2241
2241
|
return n.$$set = (S) => {
|
|
2242
|
-
"class" in S && e(2, s = S.class), "apiKey" in S && e(25, a = S.apiKey), "bbox" in S && e(26, u = S.bbox), "clearButtonTitle" in S && e(3, l = S.clearButtonTitle), "clearOnBlur" in S && e(27, c = S.clearOnBlur), "collapsed" in S && e(4, f = S.collapsed), "country" in S && e(28, h = S.country), "debounceSearch" in S && e(29, g = S.debounceSearch), "enableReverse" in S && e(5, p = S.enableReverse), "errorMessage" in S && e(6,
|
|
2242
|
+
"class" in S && e(2, s = S.class), "apiKey" in S && e(25, a = S.apiKey), "bbox" in S && e(26, u = S.bbox), "clearButtonTitle" in S && e(3, l = S.clearButtonTitle), "clearOnBlur" in S && e(27, c = S.clearOnBlur), "collapsed" in S && e(4, f = S.collapsed), "country" in S && e(28, h = S.country), "debounceSearch" in S && e(29, g = S.debounceSearch), "enableReverse" in S && e(5, p = S.enableReverse), "errorMessage" in S && e(6, y = S.errorMessage), "filter" in S && e(30, d = S.filter), "flyTo" in S && e(31, v = S.flyTo), "fuzzyMatch" in S && e(32, C = S.fuzzyMatch), "language" in S && e(33, I = S.language), "limit" in S && e(34, N = S.limit), "mapController" in S && e(35, L = S.mapController), "minLength" in S && e(36, T = S.minLength), "noResultsMessage" in S && e(7, R = S.noResultsMessage), "placeholder" in S && e(8, D = S.placeholder), "proximity" in S && e(37, b = S.proximity), "reverseActive" in S && e(0, A = S.reverseActive), "reverseButtonTitle" in S && e(9, Y = S.reverseButtonTitle), "searchValue" in S && e(1, G = S.searchValue), "showFullGeometry" in S && e(38, at = S.showFullGeometry), "showPlaceType" in S && e(10, x = S.showPlaceType), "showResultsWhileTyping" in S && e(39, B = S.showResultsWhileTyping), "selectFirst" in S && e(11, K = S.selectFirst), "flyToSelected" in S && e(40, _t = S.flyToSelected), "markerOnSelected" in S && e(41, Qt = S.markerOnSelected), "types" in S && e(42, zt = S.types), "excludeTypes" in S && e(43, Vr = S.excludeTypes), "zoom" in S && e(44, Ie = S.zoom), "maxZoom" in S && e(45, De = S.maxZoom), "apiUrl" in S && e(46, Ue = S.apiUrl), "fetchParameters" in S && e(47, In = S.fetchParameters), "iconsBaseUrl" in S && e(12, sn = S.iconsBaseUrl), "adjustUrlQuery" in S && e(48, ps = S.adjustUrlQuery), "$$scope" in S && e(58, o = S.$$scope);
|
|
2243
2243
|
}, n.$$.update = () => {
|
|
2244
2244
|
if (n.$$.dirty[0] & /*focused, clearOnBlur*/
|
|
2245
2245
|
134225920 && setTimeout(() => {
|
|
@@ -2248,7 +2248,7 @@ function Wc(n, t, e) {
|
|
|
2248
2248
|
16386 | n.$$.dirty[1] & /*minLength*/
|
|
2249
2249
|
32 && G.length < T && (e(55, Z = void 0), e(14, it = void 0), e(18, qr = void 0), e(54, Vt = it)), n.$$.dirty[1] & /*showFullGeometry, picked*/
|
|
2250
2250
|
16777344 && at && Z && !Z.address && Z.geometry.type === "Point" && Z.place_type[0] !== "reverse" && ms(Z.id, { byId: !0 }).catch((S) => e(18, qr = S)), n.$$.dirty[1] & /*mapController, picked, prevIdToFly, flyTo, maxZoom, zoom*/
|
|
2251
|
-
50356241 && (L && Z && Z.id !== ds &&
|
|
2251
|
+
50356241 && (L && Z && Z.id !== ds && v && (!Z.bbox || Z.bbox[0] === Z.bbox[2] && Z.bbox[1] === Z.bbox[3] ? L.flyTo(Z.center, Z.id.startsWith("poi.") || Z.id.startsWith("address.") ? De : Ie) : L.fitBounds(Ca(Z.bbox), 50, De), e(14, it = void 0), e(54, Vt = void 0), e(15, Lt = -1)), e(56, ds = Z == null ? void 0 : Z.id)), n.$$.dirty[0] & /*selectFirst, listFeatures*/
|
|
2252
2252
|
18432 && K && it != null && it.length && e(15, Lt = 0), n.$$.dirty[0] & /*selectFirst, searchValue*/
|
|
2253
2253
|
2050 && (K || e(15, Lt = -1)), n.$$.dirty[0] & /*listFeatures*/
|
|
2254
2254
|
16384 | n.$$.dirty[1] & /*markedFeatures*/
|
|
@@ -2274,7 +2274,7 @@ function Wc(n, t, e) {
|
|
|
2274
2274
|
}
|
|
2275
2275
|
}), n.$$.dirty[0] & /*listFeatures, selectedItemIndex*/
|
|
2276
2276
|
49152 && e(57, r = it == null ? void 0 : it[Lt]), n.$$.dirty[1] & /*mapController, selected, flyTo, flyToSelected, maxZoom, zoom*/
|
|
2277
|
-
67133969 && L && r &&
|
|
2277
|
+
67133969 && L && r && v && _t && L.flyTo(r.center, r.id.startsWith("poi.") || r.id.startsWith("address.") ? De : Ie), n.$$.dirty[1] & /*markerOnSelected, mapController*/
|
|
2278
2278
|
1040 && (Qt || L == null || L.setMarkers(void 0, void 0)), n.$$.dirty[1] & /*mapController, markerOnSelected, markedFeatures, selected*/
|
|
2279
2279
|
75498512 && L && Qt && !Vt && (L.setMarkers(r ? [r] : void 0, void 0), L.setSelectedMarker(r ? 0 : -1)), n.$$.dirty[1] & /*mapController, markedFeatures, picked*/
|
|
2280
2280
|
25165840 && L && L.setMarkers(Vt, Z), n.$$.dirty[0] & /*selectedItemIndex*/
|
|
@@ -2302,7 +2302,7 @@ function Wc(n, t, e) {
|
|
|
2302
2302
|
l,
|
|
2303
2303
|
f,
|
|
2304
2304
|
p,
|
|
2305
|
-
|
|
2305
|
+
y,
|
|
2306
2306
|
R,
|
|
2307
2307
|
D,
|
|
2308
2308
|
Y,
|
|
@@ -2327,9 +2327,9 @@ function Wc(n, t, e) {
|
|
|
2327
2327
|
h,
|
|
2328
2328
|
g,
|
|
2329
2329
|
d,
|
|
2330
|
-
|
|
2331
|
-
I,
|
|
2330
|
+
v,
|
|
2332
2331
|
C,
|
|
2332
|
+
I,
|
|
2333
2333
|
N,
|
|
2334
2334
|
L,
|
|
2335
2335
|
T,
|
|
@@ -3095,8 +3095,8 @@ var tf = bn * bn, ks = function(t, e) {
|
|
|
3095
3095
|
var p = r.comparePoint(e.leftSE.point);
|
|
3096
3096
|
if (p !== 0)
|
|
3097
3097
|
return p;
|
|
3098
|
-
var
|
|
3099
|
-
return
|
|
3098
|
+
var y = e.comparePoint(r.rightSE.point);
|
|
3099
|
+
return y < 0 ? 1 : y > 0 ? -1 : 1;
|
|
3100
3100
|
}
|
|
3101
3101
|
if (u < l)
|
|
3102
3102
|
return -1;
|
|
@@ -3108,17 +3108,17 @@ var tf = bn * bn, ks = function(t, e) {
|
|
|
3108
3108
|
return d;
|
|
3109
3109
|
}
|
|
3110
3110
|
if (s > a) {
|
|
3111
|
-
var
|
|
3112
|
-
if (
|
|
3111
|
+
var v = e.comparePoint(r.rightSE.point);
|
|
3112
|
+
if (v < 0)
|
|
3113
3113
|
return 1;
|
|
3114
|
-
if (
|
|
3114
|
+
if (v > 0)
|
|
3115
3115
|
return -1;
|
|
3116
3116
|
}
|
|
3117
3117
|
if (s !== a) {
|
|
3118
|
-
var
|
|
3119
|
-
if (
|
|
3118
|
+
var C = c - u, I = s - i, N = f - l, L = a - o;
|
|
3119
|
+
if (C > I && N < L)
|
|
3120
3120
|
return 1;
|
|
3121
|
-
if (
|
|
3121
|
+
if (C < I && N > L)
|
|
3122
3122
|
return -1;
|
|
3123
3123
|
}
|
|
3124
3124
|
return s > a ? 1 : s < a || c < f ? -1 : c > f ? 1 : e.id < r.id ? -1 : e.id > r.id ? 1 : 0;
|
|
@@ -3323,18 +3323,18 @@ var tf = bn * bn, ks = function(t, e) {
|
|
|
3323
3323
|
}
|
|
3324
3324
|
for (var f = [], h = [], g = 0, p = r.length; g < p; g++)
|
|
3325
3325
|
if (i[g] !== 0) {
|
|
3326
|
-
var
|
|
3326
|
+
var y = r[g], d = y.poly;
|
|
3327
3327
|
if (h.indexOf(d) === -1)
|
|
3328
|
-
if (
|
|
3328
|
+
if (y.isExterior)
|
|
3329
3329
|
f.push(d);
|
|
3330
3330
|
else {
|
|
3331
3331
|
h.indexOf(d) === -1 && h.push(d);
|
|
3332
|
-
var
|
|
3333
|
-
|
|
3332
|
+
var v = f.indexOf(y.poly);
|
|
3333
|
+
v !== -1 && f.splice(v, 1);
|
|
3334
3334
|
}
|
|
3335
3335
|
}
|
|
3336
|
-
for (var
|
|
3337
|
-
var N = f[
|
|
3336
|
+
for (var C = 0, I = f.length; C < I; C++) {
|
|
3337
|
+
var N = f[C].multiPoly;
|
|
3338
3338
|
o.indexOf(N) === -1 && o.push(N);
|
|
3339
3339
|
}
|
|
3340
3340
|
return this._afterState;
|
|
@@ -3500,20 +3500,20 @@ var tf = bn * bn, ks = function(t, e) {
|
|
|
3500
3500
|
for (; ; ) {
|
|
3501
3501
|
var g = u.getAvailableLinkedEvents();
|
|
3502
3502
|
if (g.length === 0) {
|
|
3503
|
-
var p = c[0].point,
|
|
3504
|
-
throw new Error("Unable to complete output ring starting at [".concat(p.x, ",") + " ".concat(p.y, "]. Last matching segment found ends at") + " [".concat(
|
|
3503
|
+
var p = c[0].point, y = c[c.length - 1].point;
|
|
3504
|
+
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, "]."));
|
|
3505
3505
|
}
|
|
3506
3506
|
if (g.length === 1) {
|
|
3507
3507
|
l = g[0].otherSE;
|
|
3508
3508
|
break;
|
|
3509
3509
|
}
|
|
3510
|
-
for (var d = null,
|
|
3511
|
-
if (h[
|
|
3512
|
-
d =
|
|
3510
|
+
for (var d = null, v = 0, C = h.length; v < C; v++)
|
|
3511
|
+
if (h[v].point === u.point) {
|
|
3512
|
+
d = v;
|
|
3513
3513
|
break;
|
|
3514
3514
|
}
|
|
3515
3515
|
if (d !== null) {
|
|
3516
|
-
var
|
|
3516
|
+
var I = h.splice(d)[0], N = c.splice(I.index);
|
|
3517
3517
|
N.unshift(N[0].otherSE), r.push(new n(N.reverse()));
|
|
3518
3518
|
continue;
|
|
3519
3519
|
}
|
|
@@ -3662,22 +3662,22 @@ var tf = bn * bn, ks = function(t, e) {
|
|
|
3662
3662
|
for (var h = this._splitSafely(u, f), g = 0, p = h.length; g < p; g++)
|
|
3663
3663
|
i.push(h[g]);
|
|
3664
3664
|
}
|
|
3665
|
-
var
|
|
3665
|
+
var y = null;
|
|
3666
3666
|
if (l) {
|
|
3667
3667
|
var d = l.getIntersection(r);
|
|
3668
|
-
if (d !== null && (r.isAnEndpoint(d) || (
|
|
3669
|
-
for (var
|
|
3670
|
-
i.push(
|
|
3668
|
+
if (d !== null && (r.isAnEndpoint(d) || (y = d), !l.isAnEndpoint(d)))
|
|
3669
|
+
for (var v = this._splitSafely(l, d), C = 0, I = v.length; C < I; C++)
|
|
3670
|
+
i.push(v[C]);
|
|
3671
3671
|
}
|
|
3672
|
-
if (c !== null ||
|
|
3672
|
+
if (c !== null || y !== null) {
|
|
3673
3673
|
var N = null;
|
|
3674
3674
|
if (c === null)
|
|
3675
|
-
N =
|
|
3676
|
-
else if (
|
|
3675
|
+
N = y;
|
|
3676
|
+
else if (y === null)
|
|
3677
3677
|
N = c;
|
|
3678
3678
|
else {
|
|
3679
|
-
var L = Hr.comparePoints(c,
|
|
3680
|
-
N = L <= 0 ? c :
|
|
3679
|
+
var L = Hr.comparePoints(c, y);
|
|
3680
|
+
N = L <= 0 ? c : y;
|
|
3681
3681
|
}
|
|
3682
3682
|
this.queue.remove(r.rightSE), i.push(r.rightSE);
|
|
3683
3683
|
for (var T = r.split(N), R = 0, D = T.length; R < D; R++)
|
|
@@ -3731,25 +3731,25 @@ var tf = bn * bn, ks = function(t, e) {
|
|
|
3731
3731
|
if (Fs(h.bbox, o[g].bbox) === null)
|
|
3732
3732
|
return [];
|
|
3733
3733
|
}
|
|
3734
|
-
for (var
|
|
3735
|
-
for (var
|
|
3736
|
-
if (
|
|
3734
|
+
for (var y = new Hs(Hr.compare), d = 0, v = o.length; d < v; d++)
|
|
3735
|
+
for (var C = o[d].getSweepEvents(), I = 0, N = C.length; I < N; I++)
|
|
3736
|
+
if (y.insert(C[I]), y.size > Ua)
|
|
3737
3737
|
throw new Error("Infinite loop when putting segment endpoints in a priority queue (queue size too big). Please file a bug report.");
|
|
3738
|
-
for (var L = new cf(
|
|
3738
|
+
for (var L = new cf(y), T = y.size, R = y.pop(); R; ) {
|
|
3739
3739
|
var D = R.key;
|
|
3740
|
-
if (
|
|
3740
|
+
if (y.size === T) {
|
|
3741
3741
|
var b = D.segment;
|
|
3742
3742
|
throw new Error("Unable to pop() ".concat(D.isLeft ? "left" : "right", " SweepEvent ") + "[".concat(D.point.x, ", ").concat(D.point.y, "] from segment #").concat(b.id, " ") + "[".concat(b.leftSE.point.x, ", ").concat(b.leftSE.point.y, "] -> ") + "[".concat(b.rightSE.point.x, ", ").concat(b.rightSE.point.y, "] from queue. ") + "Please file a bug report.");
|
|
3743
3743
|
}
|
|
3744
|
-
if (
|
|
3744
|
+
if (y.size > Ua)
|
|
3745
3745
|
throw new Error("Infinite loop when passing sweep line over endpoints (queue size too big). Please file a bug report.");
|
|
3746
3746
|
if (L.segments.length > ff)
|
|
3747
3747
|
throw new Error("Infinite loop when passing sweep line over endpoints (too many sweep line segments). Please file a bug report.");
|
|
3748
3748
|
for (var A = L.process(D), Y = 0, G = A.length; Y < G; Y++) {
|
|
3749
3749
|
var at = A[Y];
|
|
3750
|
-
at.consumedBy === void 0 &&
|
|
3750
|
+
at.consumedBy === void 0 && y.insert(at);
|
|
3751
3751
|
}
|
|
3752
|
-
T =
|
|
3752
|
+
T = y.size, R = y.pop();
|
|
3753
3753
|
}
|
|
3754
3754
|
ro.reset();
|
|
3755
3755
|
var x = uf.factory(L.segments), B = new lf(x);
|
|
@@ -3867,11 +3867,11 @@ function Ef(n, t, e) {
|
|
|
3867
3867
|
}
|
|
3868
3868
|
function Lu(n, t, e) {
|
|
3869
3869
|
if (n !== null)
|
|
3870
|
-
for (var r, i, o, s, a, u, l, c = 0, f = 0, h, g = n.type, p = g === "FeatureCollection",
|
|
3871
|
-
l = p ? n.features[
|
|
3872
|
-
for (var
|
|
3873
|
-
var
|
|
3874
|
-
if (s = h ? l.geometries[
|
|
3870
|
+
for (var r, i, o, s, a, u, l, c = 0, f = 0, h, g = n.type, p = g === "FeatureCollection", y = g === "Feature", d = p ? n.features.length : 1, v = 0; v < d; v++) {
|
|
3871
|
+
l = p ? n.features[v].geometry : y ? n.geometry : n, h = l ? l.type === "GeometryCollection" : !1, a = h ? l.geometries.length : 1;
|
|
3872
|
+
for (var C = 0; C < a; C++) {
|
|
3873
|
+
var I = 0, N = 0;
|
|
3874
|
+
if (s = h ? l.geometries[C] : l, s !== null) {
|
|
3875
3875
|
u = s.coordinates;
|
|
3876
3876
|
var L = s.type;
|
|
3877
3877
|
switch (c = 0, L) {
|
|
@@ -3881,12 +3881,12 @@ function Lu(n, t, e) {
|
|
|
3881
3881
|
if (t(
|
|
3882
3882
|
u,
|
|
3883
3883
|
f,
|
|
3884
|
-
|
|
3885
|
-
|
|
3884
|
+
v,
|
|
3885
|
+
I,
|
|
3886
3886
|
N
|
|
3887
3887
|
) === !1)
|
|
3888
3888
|
return !1;
|
|
3889
|
-
f++,
|
|
3889
|
+
f++, I++;
|
|
3890
3890
|
break;
|
|
3891
3891
|
case "LineString":
|
|
3892
3892
|
case "MultiPoint":
|
|
@@ -3894,14 +3894,14 @@ function Lu(n, t, e) {
|
|
|
3894
3894
|
if (t(
|
|
3895
3895
|
u[r],
|
|
3896
3896
|
f,
|
|
3897
|
-
|
|
3898
|
-
|
|
3897
|
+
v,
|
|
3898
|
+
I,
|
|
3899
3899
|
N
|
|
3900
3900
|
) === !1)
|
|
3901
3901
|
return !1;
|
|
3902
|
-
f++, L === "MultiPoint" &&
|
|
3902
|
+
f++, L === "MultiPoint" && I++;
|
|
3903
3903
|
}
|
|
3904
|
-
L === "LineString" &&
|
|
3904
|
+
L === "LineString" && I++;
|
|
3905
3905
|
break;
|
|
3906
3906
|
case "Polygon":
|
|
3907
3907
|
case "MultiLineString":
|
|
@@ -3910,16 +3910,16 @@ function Lu(n, t, e) {
|
|
|
3910
3910
|
if (t(
|
|
3911
3911
|
u[r][i],
|
|
3912
3912
|
f,
|
|
3913
|
-
|
|
3914
|
-
|
|
3913
|
+
v,
|
|
3914
|
+
I,
|
|
3915
3915
|
N
|
|
3916
3916
|
) === !1)
|
|
3917
3917
|
return !1;
|
|
3918
3918
|
f++;
|
|
3919
3919
|
}
|
|
3920
|
-
L === "MultiLineString" &&
|
|
3920
|
+
L === "MultiLineString" && I++, L === "Polygon" && N++;
|
|
3921
3921
|
}
|
|
3922
|
-
L === "Polygon" &&
|
|
3922
|
+
L === "Polygon" && I++;
|
|
3923
3923
|
break;
|
|
3924
3924
|
case "MultiPolygon":
|
|
3925
3925
|
for (r = 0; r < u.length; r++) {
|
|
@@ -3928,8 +3928,8 @@ function Lu(n, t, e) {
|
|
|
3928
3928
|
if (t(
|
|
3929
3929
|
u[r][i][o],
|
|
3930
3930
|
f,
|
|
3931
|
-
|
|
3932
|
-
|
|
3931
|
+
v,
|
|
3932
|
+
I,
|
|
3933
3933
|
N
|
|
3934
3934
|
) === !1)
|
|
3935
3935
|
return !1;
|
|
@@ -3937,7 +3937,7 @@ function Lu(n, t, e) {
|
|
|
3937
3937
|
}
|
|
3938
3938
|
N++;
|
|
3939
3939
|
}
|
|
3940
|
-
|
|
3940
|
+
I++;
|
|
3941
3941
|
}
|
|
3942
3942
|
break;
|
|
3943
3943
|
case "GeometryCollection":
|
|
@@ -3960,8 +3960,8 @@ function Xa(n, t) {
|
|
|
3960
3960
|
;
|
|
3961
3961
|
}
|
|
3962
3962
|
function bu(n, t) {
|
|
3963
|
-
var e, r, i, o, s, a, u, l, c, f, h = 0, g = n.type === "FeatureCollection", p = n.type === "Feature",
|
|
3964
|
-
for (e = 0; e <
|
|
3963
|
+
var e, r, i, o, s, a, u, l, c, f, h = 0, g = n.type === "FeatureCollection", p = n.type === "Feature", y = g ? n.features.length : 1;
|
|
3964
|
+
for (e = 0; e < y; e++) {
|
|
3965
3965
|
for (a = g ? n.features[e].geometry : p ? n.geometry : n, l = g ? n.features[e].properties : p ? n.properties : {}, c = g ? n.features[e].bbox : p ? n.bbox : void 0, f = g ? n.features[e].id : p ? n.id : void 0, u = a ? a.type === "GeometryCollection" : !1, s = u ? a.geometries.length : 1, i = 0; i < s; i++) {
|
|
3966
3966
|
if (o = u ? a.geometries[i] : a, o === null) {
|
|
3967
3967
|
if (t(
|
|
@@ -4518,10 +4518,10 @@ E.prototype.selfAdd = function() {
|
|
|
4518
4518
|
return o = this._hi + e, a = o - this._hi, s = o - a, s = e - a + (this._hi - s), u = s + this._lo, r = o + u, i = u + (o - r), this._hi = r + i, this._lo = i + (r - this._hi), this;
|
|
4519
4519
|
}
|
|
4520
4520
|
} else if (arguments.length === 2) {
|
|
4521
|
-
var l = arguments[0], c = arguments[1], f = null, h = null, g = null, p = null,
|
|
4522
|
-
|
|
4523
|
-
var
|
|
4524
|
-
return this._hi =
|
|
4521
|
+
var l = arguments[0], c = arguments[1], f = null, h = null, g = null, p = null, y = null, d = null, v = null, C = null;
|
|
4522
|
+
y = this._hi + l, g = this._lo + c, v = y - this._hi, C = g - this._lo, d = y - v, p = g - C, d = l - v + (this._hi - d), p = c - C + (this._lo - p), v = d + g, f = y + v, h = v + (y - f), v = p + h;
|
|
4523
|
+
var I = f + v, N = v + (f - I);
|
|
4524
|
+
return this._hi = I, this._lo = N, this;
|
|
4525
4525
|
}
|
|
4526
4526
|
};
|
|
4527
4527
|
E.prototype.selfMultiply = function() {
|
|
@@ -4698,8 +4698,8 @@ E.parse = function(t) {
|
|
|
4698
4698
|
var h = t.substring(e);
|
|
4699
4699
|
try {
|
|
4700
4700
|
l = gr.parseInt(h);
|
|
4701
|
-
} catch (
|
|
4702
|
-
throw
|
|
4701
|
+
} catch (v) {
|
|
4702
|
+
throw v instanceof Error ? new Error("Invalid exponent " + h + " in string " + t) : v;
|
|
4703
4703
|
} finally {
|
|
4704
4704
|
}
|
|
4705
4705
|
break;
|
|
@@ -4710,8 +4710,8 @@ E.parse = function(t) {
|
|
|
4710
4710
|
if (p === 0)
|
|
4711
4711
|
g = s;
|
|
4712
4712
|
else if (p > 0) {
|
|
4713
|
-
var
|
|
4714
|
-
g = s.divide(
|
|
4713
|
+
var y = E.TEN.pow(p);
|
|
4714
|
+
g = s.divide(y);
|
|
4715
4715
|
} else if (p < 0) {
|
|
4716
4716
|
var d = E.TEN.pow(-p);
|
|
4717
4717
|
g = s.multiply(d);
|
|
@@ -4790,8 +4790,8 @@ he.signOfDet2x2 = function(t, e, r, i) {
|
|
|
4790
4790
|
return o.signum();
|
|
4791
4791
|
};
|
|
4792
4792
|
he.intersection = function(t, e, r, i) {
|
|
4793
|
-
var o = E.valueOf(i.y).selfSubtract(r.y).selfMultiply(E.valueOf(e.x).selfSubtract(t.x)), s = E.valueOf(i.x).selfSubtract(r.x).selfMultiply(E.valueOf(e.y).selfSubtract(t.y)), a = o.subtract(s), u = E.valueOf(i.x).selfSubtract(r.x).selfMultiply(E.valueOf(t.y).selfSubtract(r.y)), l = E.valueOf(i.y).selfSubtract(r.y).selfMultiply(E.valueOf(t.x).selfSubtract(r.x)), c = u.subtract(l), f = c.selfDivide(a).doubleValue(), h = E.valueOf(t.x).selfAdd(E.valueOf(e.x).selfSubtract(t.x).selfMultiply(f)).doubleValue(), g = E.valueOf(e.x).selfSubtract(t.x).selfMultiply(E.valueOf(t.y).selfSubtract(r.y)), p = E.valueOf(e.y).selfSubtract(t.y).selfMultiply(E.valueOf(t.x).selfSubtract(r.x)),
|
|
4794
|
-
return new m(h,
|
|
4793
|
+
var o = E.valueOf(i.y).selfSubtract(r.y).selfMultiply(E.valueOf(e.x).selfSubtract(t.x)), s = E.valueOf(i.x).selfSubtract(r.x).selfMultiply(E.valueOf(e.y).selfSubtract(t.y)), a = o.subtract(s), u = E.valueOf(i.x).selfSubtract(r.x).selfMultiply(E.valueOf(t.y).selfSubtract(r.y)), l = E.valueOf(i.y).selfSubtract(r.y).selfMultiply(E.valueOf(t.x).selfSubtract(r.x)), c = u.subtract(l), f = c.selfDivide(a).doubleValue(), h = E.valueOf(t.x).selfAdd(E.valueOf(e.x).selfSubtract(t.x).selfMultiply(f)).doubleValue(), g = E.valueOf(e.x).selfSubtract(t.x).selfMultiply(E.valueOf(t.y).selfSubtract(r.y)), p = E.valueOf(e.y).selfSubtract(t.y).selfMultiply(E.valueOf(t.x).selfSubtract(r.x)), y = g.subtract(p), d = y.selfDivide(a).doubleValue(), v = E.valueOf(r.y).selfAdd(E.valueOf(i.y).selfSubtract(r.y).selfMultiply(d)).doubleValue();
|
|
4794
|
+
return new m(h, v);
|
|
4795
4795
|
};
|
|
4796
4796
|
he.orientationIndexFilter = function(t, e, r) {
|
|
4797
4797
|
var i = null, o = (t.x - r.x) * (e.y - r.y), s = (t.y - r.y) * (e.x - r.x), a = o - s;
|
|
@@ -4903,8 +4903,8 @@ var We = function n() {
|
|
|
4903
4903
|
var u = arguments[0], l = arguments[1], c = arguments[2];
|
|
4904
4904
|
this.x = u, this.y = l, this.w = c;
|
|
4905
4905
|
} else if (arguments.length === 4) {
|
|
4906
|
-
var f = arguments[0], h = arguments[1], g = arguments[2], p = arguments[3],
|
|
4907
|
-
this.x = d * N -
|
|
4906
|
+
var f = arguments[0], h = arguments[1], g = arguments[2], p = arguments[3], y = f.y - h.y, d = h.x - f.x, v = f.x * h.y - h.x * f.y, C = g.y - p.y, I = p.x - g.x, N = g.x * p.y - p.x * g.y;
|
|
4907
|
+
this.x = d * N - I * v, this.y = C * v - y * N, this.w = y * I - C * d;
|
|
4908
4908
|
}
|
|
4909
4909
|
};
|
|
4910
4910
|
We.prototype.getY = function() {
|
|
@@ -4930,10 +4930,10 @@ We.prototype.getClass = function() {
|
|
|
4930
4930
|
return We;
|
|
4931
4931
|
};
|
|
4932
4932
|
We.intersection = function(t, e, r, i) {
|
|
4933
|
-
var o = t.y - e.y, s = e.x - t.x, a = t.x * e.y - e.x * t.y, u = r.y - i.y, l = i.x - r.x, c = r.x * i.y - i.x * r.y, f = s * c - l * a, h = u * a - o * c, g = o * l - u * s, p = f / g,
|
|
4934
|
-
if (U.isNaN(p) || U.isInfinite(p) || U.isNaN(
|
|
4933
|
+
var o = t.y - e.y, s = e.x - t.x, a = t.x * e.y - e.x * t.y, u = r.y - i.y, l = i.x - r.x, c = r.x * i.y - i.x * r.y, f = s * c - l * a, h = u * a - o * c, g = o * l - u * s, p = f / g, y = h / g;
|
|
4934
|
+
if (U.isNaN(p) || U.isInfinite(p) || U.isNaN(y) || U.isInfinite(y))
|
|
4935
4935
|
throw new Vi();
|
|
4936
|
-
return new m(p,
|
|
4936
|
+
return new m(p, y);
|
|
4937
4937
|
};
|
|
4938
4938
|
var F = function n() {
|
|
4939
4939
|
if (this._minx = null, this._maxx = null, this._miny = null, this._maxy = null, arguments.length === 0)
|
|
@@ -5604,7 +5604,7 @@ var Yn = function(n) {
|
|
|
5604
5604
|
var a = F.intersects(r, i, o), u = F.intersects(r, i, s), l = F.intersects(o, s, r), c = F.intersects(o, s, i);
|
|
5605
5605
|
return a && u ? (this._intPt[0] = o, this._intPt[1] = s, n.COLLINEAR_INTERSECTION) : l && c ? (this._intPt[0] = r, this._intPt[1] = i, n.COLLINEAR_INTERSECTION) : a && l ? (this._intPt[0] = o, this._intPt[1] = r, o.equals(r) && !u && !c ? n.POINT_INTERSECTION : n.COLLINEAR_INTERSECTION) : a && c ? (this._intPt[0] = o, this._intPt[1] = i, o.equals(i) && !u && !l ? n.POINT_INTERSECTION : n.COLLINEAR_INTERSECTION) : u && l ? (this._intPt[0] = s, this._intPt[1] = r, s.equals(r) && !a && !c ? n.POINT_INTERSECTION : n.COLLINEAR_INTERSECTION) : u && c ? (this._intPt[0] = s, this._intPt[1] = i, s.equals(i) && !a && !l ? n.POINT_INTERSECTION : n.COLLINEAR_INTERSECTION) : n.NO_INTERSECTION;
|
|
5606
5606
|
}, t.prototype.normalizeToEnvCentre = function(r, i, o, s, a) {
|
|
5607
|
-
var u = r.x < i.x ? r.x : i.x, l = r.y < i.y ? r.y : i.y, c = r.x > i.x ? r.x : i.x, f = r.y > i.y ? r.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,
|
|
5607
|
+
var u = r.x < i.x ? r.x : i.x, l = r.y < i.y ? r.y : i.y, c = r.x > i.x ? r.x : i.x, f = r.y > i.y ? r.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, d = u > h ? u : h, v = c < p ? c : p, C = l > g ? l : g, I = f < y ? f : y, N = (d + v) / 2, L = (C + I) / 2;
|
|
5608
5608
|
a.x = N, a.y = L, r.x -= a.x, r.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;
|
|
5609
5609
|
}, t.prototype.computeIntersect = function(r, i, o, s) {
|
|
5610
5610
|
if (this._isProper = !1, !F.intersects(r, i, o, s))
|
|
@@ -5770,8 +5770,8 @@ M.signedArea = function() {
|
|
|
5770
5770
|
u.getCoordinate(0, f), u.getCoordinate(1, h);
|
|
5771
5771
|
var g = f.x;
|
|
5772
5772
|
h.x -= g;
|
|
5773
|
-
for (var p = 0,
|
|
5774
|
-
c.y = f.y, f.x = h.x, f.y = h.y, u.getCoordinate(
|
|
5773
|
+
for (var p = 0, y = 1; y < l - 1; y++)
|
|
5774
|
+
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);
|
|
5775
5775
|
return p / 2;
|
|
5776
5776
|
}
|
|
5777
5777
|
};
|
|
@@ -6308,32 +6308,32 @@ var O = function(n) {
|
|
|
6308
6308
|
}
|
|
6309
6309
|
} else if (arguments.length === 3) {
|
|
6310
6310
|
if (typeof arguments[2] == "boolean" && arguments[0] instanceof Array && typeof arguments[1] == "boolean") {
|
|
6311
|
-
var g = arguments[0], p = arguments[1],
|
|
6312
|
-
if (
|
|
6311
|
+
var g = arguments[0], p = arguments[1], y = arguments[2];
|
|
6312
|
+
if (y)
|
|
6313
6313
|
for (var d = 0; d < g.length; d++)
|
|
6314
6314
|
i.add(g[d], p);
|
|
6315
6315
|
else
|
|
6316
|
-
for (var
|
|
6317
|
-
i.add(g[
|
|
6316
|
+
for (var v = g.length - 1; v >= 0; v--)
|
|
6317
|
+
i.add(g[v], p);
|
|
6318
6318
|
return !0;
|
|
6319
6319
|
} else if (typeof arguments[2] == "boolean" && Number.isInteger(arguments[0]) && arguments[1] instanceof m) {
|
|
6320
|
-
var
|
|
6320
|
+
var C = arguments[0], I = arguments[1], N = arguments[2];
|
|
6321
6321
|
if (!N) {
|
|
6322
6322
|
var L = this.size();
|
|
6323
6323
|
if (L > 0) {
|
|
6324
|
-
if (
|
|
6325
|
-
var T = this.get(
|
|
6326
|
-
if (T.equals2D(
|
|
6324
|
+
if (C > 0) {
|
|
6325
|
+
var T = this.get(C - 1);
|
|
6326
|
+
if (T.equals2D(I))
|
|
6327
6327
|
return null;
|
|
6328
6328
|
}
|
|
6329
|
-
if (
|
|
6330
|
-
var R = this.get(
|
|
6331
|
-
if (R.equals2D(
|
|
6329
|
+
if (C < L) {
|
|
6330
|
+
var R = this.get(C);
|
|
6331
|
+
if (R.equals2D(I))
|
|
6332
6332
|
return null;
|
|
6333
6333
|
}
|
|
6334
6334
|
}
|
|
6335
6335
|
}
|
|
6336
|
-
n.prototype.add.call(this,
|
|
6336
|
+
n.prototype.add.call(this, C, I);
|
|
6337
6337
|
}
|
|
6338
6338
|
} else if (arguments.length === 4) {
|
|
6339
6339
|
var D = arguments[0], b = arguments[1], A = arguments[2], Y = arguments[3], G = 1;
|
|
@@ -7037,7 +7037,7 @@ var ae = function(n) {
|
|
|
7037
7037
|
return this.compare(s, a);
|
|
7038
7038
|
} else if (arguments.length === 2) {
|
|
7039
7039
|
for (var u = arguments[0], l = arguments[1], c = u, f = this.getNumGeometries(), h = c.getNumGeometries(), g = 0; g < f && g < h; ) {
|
|
7040
|
-
var p = i.getGeometryN(g),
|
|
7040
|
+
var p = i.getGeometryN(g), y = c.getGeometryN(g), d = p.compareToSameClass(y, l);
|
|
7041
7041
|
if (d !== 0)
|
|
7042
7042
|
return d;
|
|
7043
7043
|
g++;
|
|
@@ -7634,8 +7634,8 @@ var At = function(n) {
|
|
|
7634
7634
|
return !1;
|
|
7635
7635
|
}
|
|
7636
7636
|
for (var l = i.getX(0), c = i.getY(0), f = 1; f <= 4; f++) {
|
|
7637
|
-
var h = i.getX(f), g = i.getY(f), p = h !== l,
|
|
7638
|
-
if (p ===
|
|
7637
|
+
var h = i.getX(f), g = i.getY(f), p = h !== l, y = g !== c;
|
|
7638
|
+
if (p === y)
|
|
7639
7639
|
return !1;
|
|
7640
7640
|
l = h, c = g;
|
|
7641
7641
|
}
|
|
@@ -7706,13 +7706,13 @@ var At = function(n) {
|
|
|
7706
7706
|
var u = arguments[0], l = arguments[1], c = u, f = this._shell, h = c._shell, g = f.compareToSameClass(h, l);
|
|
7707
7707
|
if (g !== 0)
|
|
7708
7708
|
return g;
|
|
7709
|
-
for (var p = this.getNumInteriorRing(),
|
|
7710
|
-
var
|
|
7711
|
-
if (
|
|
7712
|
-
return
|
|
7709
|
+
for (var p = this.getNumInteriorRing(), y = c.getNumInteriorRing(), d = 0; d < p && d < y; ) {
|
|
7710
|
+
var v = i.getInteriorRingN(d), C = c.getInteriorRingN(d), I = v.compareToSameClass(C, l);
|
|
7711
|
+
if (I !== 0)
|
|
7712
|
+
return I;
|
|
7713
7713
|
d++;
|
|
7714
7714
|
}
|
|
7715
|
-
return d < p ? 1 : d <
|
|
7715
|
+
return d < p ? 1 : d < y ? -1 : 0;
|
|
7716
7716
|
}
|
|
7717
7717
|
}, t.prototype.apply = function(i) {
|
|
7718
7718
|
var o = this;
|
|
@@ -10290,9 +10290,9 @@ kt.prototype.query = function() {
|
|
|
10290
10290
|
t.getIntersectsOp().intersects(f.getBounds(), s) && (f instanceof Mt ? t.query(s, f, u) : f instanceof Qe ? u.visitItem(f.getItem()) : X.shouldNeverReachHere());
|
|
10291
10291
|
}
|
|
10292
10292
|
else if (V(arguments[2], He) && arguments[0] instanceof Object && arguments[1] instanceof Mt)
|
|
10293
|
-
for (var h = arguments[0], g = arguments[1], p = arguments[2],
|
|
10294
|
-
var
|
|
10295
|
-
t.getIntersectsOp().intersects(
|
|
10293
|
+
for (var h = arguments[0], g = arguments[1], p = arguments[2], y = g.getChildBoundables(), d = 0; d < y.size(); d++) {
|
|
10294
|
+
var v = y.get(d);
|
|
10295
|
+
t.getIntersectsOp().intersects(v.getBounds(), h) && (v instanceof Mt ? t.query(h, v, p) : v instanceof Qe ? p.add(v.getItem()) : X.shouldNeverReachHere());
|
|
10296
10296
|
}
|
|
10297
10297
|
}
|
|
10298
10298
|
};
|
|
@@ -10474,15 +10474,15 @@ var Gu = function(n) {
|
|
|
10474
10474
|
} else if (arguments[0] instanceof bt && typeof arguments[1] == "number") {
|
|
10475
10475
|
var c = arguments[0], f = arguments[1], h = f, g = null, p = new tn();
|
|
10476
10476
|
for (p.add(c); !p.isEmpty() && h > 0; ) {
|
|
10477
|
-
var
|
|
10477
|
+
var y = p.poll(), d = y.getDistance();
|
|
10478
10478
|
if (d >= h)
|
|
10479
10479
|
break;
|
|
10480
|
-
|
|
10480
|
+
y.isLeaves() ? (h = d, g = y) : y.expandToQueue(p, h);
|
|
10481
10481
|
}
|
|
10482
10482
|
return [g.getBoundable(0).getItem(), g.getBoundable(1).getItem()];
|
|
10483
10483
|
}
|
|
10484
10484
|
} else if (arguments.length === 3) {
|
|
10485
|
-
var
|
|
10485
|
+
var v = arguments[0], C = arguments[1], I = arguments[2], N = new Qe(v, C), L = new bt(this.getRoot(), N, I);
|
|
10486
10486
|
return this.nearestNeighbour(L)[0];
|
|
10487
10487
|
}
|
|
10488
10488
|
}, t.prototype.interfaces_ = function() {
|
|
@@ -11640,8 +11640,8 @@ ft.prototype.initSideSegments = function(t, e, r) {
|
|
|
11640
11640
|
this._s1 = t, this._s2 = e, this._side = r, this._seg1.setCoordinates(t, e), this.computeOffsetSegment(this._seg1, r, this._distance, this._offset1);
|
|
11641
11641
|
};
|
|
11642
11642
|
ft.prototype.addLimitedMitreJoin = function(t, e, r, i) {
|
|
11643
|
-
var o = this._seg0.p1, s = j.angle(o, this._seg0.p0), a = j.angleBetweenOriented(this._seg0.p0, o, this._seg1.p1), u = a / 2, l = j.normalize(s + u), c = j.normalize(l + Math.PI), f = i * r, h = f * Math.abs(Math.sin(u)), g = r - h, p = o.x + f * Math.cos(c),
|
|
11644
|
-
this._side === P.LEFT ? (this._segList.addPt(
|
|
11643
|
+
var o = this._seg0.p1, s = j.angle(o, this._seg0.p0), a = j.angleBetweenOriented(this._seg0.p0, o, this._seg1.p1), u = a / 2, l = j.normalize(s + u), c = j.normalize(l + Math.PI), f = i * r, h = f * Math.abs(Math.sin(u)), g = r - h, p = o.x + f * Math.cos(c), y = o.y + f * Math.sin(c), d = new m(p, y), v = new k(o, d), C = v.pointAlongOffset(1, g), I = v.pointAlongOffset(1, -g);
|
|
11644
|
+
this._side === P.LEFT ? (this._segList.addPt(C), this._segList.addPt(I)) : (this._segList.addPt(I), this._segList.addPt(C));
|
|
11645
11645
|
};
|
|
11646
11646
|
ft.prototype.computeOffsetSegment = function(t, e, r, i) {
|
|
11647
11647
|
var o = e === P.LEFT ? 1 : -1, s = t.p1.x - t.p0.x, a = t.p1.y - t.p0.y, u = Math.sqrt(s * s + a * a), l = o * r * s / u, c = o * r * a / u;
|
|
@@ -11858,9 +11858,9 @@ ti.prototype.findStabbedSegments = function() {
|
|
|
11858
11858
|
}
|
|
11859
11859
|
}
|
|
11860
11860
|
else if (V(arguments[2], He) && arguments[0] instanceof m && V(arguments[1], He))
|
|
11861
|
-
for (var
|
|
11862
|
-
var
|
|
11863
|
-
|
|
11861
|
+
for (var y = arguments[0], d = arguments[1], v = arguments[2], C = d.iterator(); C.hasNext(); ) {
|
|
11862
|
+
var I = C.next();
|
|
11863
|
+
I.isForward() && t.findStabbedSegments(y, I, v);
|
|
11864
11864
|
}
|
|
11865
11865
|
}
|
|
11866
11866
|
};
|
|
@@ -11956,7 +11956,7 @@ et.det = function(t, e, r, i) {
|
|
|
11956
11956
|
return t * i - e * r;
|
|
11957
11957
|
};
|
|
11958
11958
|
et.interpolateZ = function(t, e, r, i) {
|
|
11959
|
-
var o = e.x, s = e.y, a = r.x - o, u = i.x - o, l = r.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,
|
|
11959
|
+
var o = e.x, s = e.y, a = r.x - o, u = i.x - o, l = r.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, d = e.z + p * (r.z - e.z) + y * (i.z - e.z);
|
|
11960
11960
|
return d;
|
|
11961
11961
|
};
|
|
11962
11962
|
et.longestSideLength = function(t, e, r) {
|
|
@@ -12365,8 +12365,8 @@ var Af = function(n) {
|
|
|
12365
12365
|
throw new $r("depth mismatch at " + i.getCoordinate());
|
|
12366
12366
|
} else if (arguments.length === 3) {
|
|
12367
12367
|
for (var c = arguments[0], f = arguments[1], h = arguments[2], g = h, p = c; p < f; p++) {
|
|
12368
|
-
var
|
|
12369
|
-
|
|
12368
|
+
var y = r._edgeList.get(p);
|
|
12369
|
+
y.setEdgeDepths(P.RIGHT, g), g = y.getDepth(P.LEFT);
|
|
12370
12370
|
}
|
|
12371
12371
|
return g;
|
|
12372
12372
|
}
|
|
@@ -12750,8 +12750,8 @@ en.prototype.computeIntersectsForChain = function() {
|
|
|
12750
12750
|
return c.addIntersections(this.e, o, a.e, u), null;
|
|
12751
12751
|
if (this.env1.init(f, h), this.env2.init(g, p), !this.env1.intersects(this.env2))
|
|
12752
12752
|
return null;
|
|
12753
|
-
var
|
|
12754
|
-
o <
|
|
12753
|
+
var y = Math.trunc((o + s) / 2), d = Math.trunc((u + l) / 2);
|
|
12754
|
+
o < y && (u < d && this.computeIntersectsForChain(o, y, a, u, d, c), d < l && this.computeIntersectsForChain(o, y, a, d, l, c)), y < s && (u < d && this.computeIntersectsForChain(y, s, a, u, d, c), d < l && this.computeIntersectsForChain(y, s, a, d, l, c));
|
|
12755
12755
|
}
|
|
12756
12756
|
};
|
|
12757
12757
|
en.prototype.getStartIndexes = function() {
|
|
@@ -13135,12 +13135,12 @@ Er.prototype.checkInteriorIntersections = function() {
|
|
|
13135
13135
|
for (var f = 0; f < l.length - 1; f++)
|
|
13136
13136
|
t.checkInteriorIntersections(s, c, a, f);
|
|
13137
13137
|
else if (arguments.length === 4) {
|
|
13138
|
-
var h = arguments[0], g = arguments[1], p = arguments[2],
|
|
13139
|
-
if (h === p && g ===
|
|
13138
|
+
var h = arguments[0], g = arguments[1], p = arguments[2], y = arguments[3];
|
|
13139
|
+
if (h === p && g === y)
|
|
13140
13140
|
return null;
|
|
13141
|
-
var d = h.getCoordinates()[g],
|
|
13142
|
-
if (this._li.computeIntersection(d,
|
|
13143
|
-
throw new Zr("found non-noded intersection at " + d + "-" +
|
|
13141
|
+
var d = h.getCoordinates()[g], v = h.getCoordinates()[g + 1], C = p.getCoordinates()[y], I = p.getCoordinates()[y + 1];
|
|
13142
|
+
if (this._li.computeIntersection(d, v, C, I), this._li.hasIntersection() && (this._li.isProper() || this.hasInteriorIntersection(this._li, d, v) || this.hasInteriorIntersection(this._li, C, I)))
|
|
13143
|
+
throw new Zr("found non-noded intersection at " + d + "-" + v + " and " + C + "-" + I);
|
|
13144
13144
|
}
|
|
13145
13145
|
};
|
|
13146
13146
|
Er.prototype.checkValid = function() {
|
|
@@ -13474,9 +13474,9 @@ Xt.bufferOp = function() {
|
|
|
13474
13474
|
return p;
|
|
13475
13475
|
}
|
|
13476
13476
|
} else if (arguments.length === 4) {
|
|
13477
|
-
var
|
|
13478
|
-
|
|
13479
|
-
var N =
|
|
13477
|
+
var y = arguments[0], d = arguments[1], v = arguments[2], C = arguments[3], I = new Xt(y);
|
|
13478
|
+
I.setQuadrantSegments(v), I.setEndCapStyle(C);
|
|
13479
|
+
var N = I.getResultGeometry(d);
|
|
13480
13480
|
return N;
|
|
13481
13481
|
}
|
|
13482
13482
|
};
|
|
@@ -13580,15 +13580,15 @@ Lr.computeDistance = function() {
|
|
|
13580
13580
|
else if (h instanceof At)
|
|
13581
13581
|
Lr.computeDistance(h, g, p);
|
|
13582
13582
|
else if (h instanceof ae)
|
|
13583
|
-
for (var
|
|
13584
|
-
var
|
|
13585
|
-
Lr.computeDistance(
|
|
13583
|
+
for (var y = h, d = 0; d < y.getNumGeometries(); d++) {
|
|
13584
|
+
var v = y.getGeometryN(d);
|
|
13585
|
+
Lr.computeDistance(v, g, p);
|
|
13586
13586
|
}
|
|
13587
13587
|
else
|
|
13588
13588
|
p.setMinimum(h.getCoordinate(), g);
|
|
13589
13589
|
} else if (arguments[2] instanceof ne && arguments[0] instanceof k && arguments[1] instanceof m) {
|
|
13590
|
-
var
|
|
13591
|
-
N.setMinimum(L,
|
|
13590
|
+
var C = arguments[0], I = arguments[1], N = arguments[2], L = C.closestPoint(I);
|
|
13591
|
+
N.setMinimum(L, I);
|
|
13592
13592
|
}
|
|
13593
13593
|
};
|
|
13594
13594
|
var Bn = function(t) {
|
|
@@ -13736,13 +13736,13 @@ qt.getLines = function() {
|
|
|
13736
13736
|
} else if (arguments.length === 3) {
|
|
13737
13737
|
if (typeof arguments[2] == "boolean" && V(arguments[0], Ot) && V(arguments[1], Ot)) {
|
|
13738
13738
|
for (var f = arguments[0], h = arguments[1], g = arguments[2], p = f.iterator(); p.hasNext(); ) {
|
|
13739
|
-
var
|
|
13740
|
-
qt.getLines(
|
|
13739
|
+
var y = p.next();
|
|
13740
|
+
qt.getLines(y, h, g);
|
|
13741
13741
|
}
|
|
13742
13742
|
return h;
|
|
13743
13743
|
} else if (typeof arguments[2] == "boolean" && arguments[0] instanceof z && V(arguments[1], Ot)) {
|
|
13744
|
-
var d = arguments[0],
|
|
13745
|
-
return d.apply(new qt(
|
|
13744
|
+
var d = arguments[0], v = arguments[1], C = arguments[2];
|
|
13745
|
+
return d.apply(new qt(v, C)), v;
|
|
13746
13746
|
}
|
|
13747
13747
|
}
|
|
13748
13748
|
};
|
|
@@ -13926,9 +13926,9 @@ Ht.prototype.computeContainmentDistance = function() {
|
|
|
13926
13926
|
if (t.computeContainmentDistance(h, l.get(g), c), t._minDistance <= t._terminateDistance)
|
|
13927
13927
|
return null;
|
|
13928
13928
|
} else if (arguments[2] instanceof Array && arguments[0] instanceof ie && arguments[1] instanceof At) {
|
|
13929
|
-
var p = arguments[0],
|
|
13930
|
-
if (_.EXTERIOR !== this._ptLocator.locate(
|
|
13931
|
-
return this._minDistance = 0, d[0] = p, d[1] = new ie(
|
|
13929
|
+
var p = arguments[0], y = arguments[1], d = arguments[2], v = p.getCoordinate();
|
|
13930
|
+
if (_.EXTERIOR !== this._ptLocator.locate(v, y))
|
|
13931
|
+
return this._minDistance = 0, d[0] = p, d[1] = new ie(y, v), null;
|
|
13932
13932
|
}
|
|
13933
13933
|
}
|
|
13934
13934
|
};
|
|
@@ -13984,13 +13984,13 @@ Ht.prototype.computeMinDistance = function() {
|
|
|
13984
13984
|
var f = arguments[0], h = arguments[1], g = arguments[2];
|
|
13985
13985
|
if (f.getEnvelopeInternal().distance(h.getEnvelopeInternal()) > this._minDistance)
|
|
13986
13986
|
return null;
|
|
13987
|
-
for (var p = f.getCoordinates(),
|
|
13988
|
-
for (var
|
|
13989
|
-
var
|
|
13990
|
-
if (
|
|
13991
|
-
t._minDistance =
|
|
13992
|
-
var
|
|
13993
|
-
g[0] = new ie(f, d, L[0]), g[1] = new ie(h,
|
|
13987
|
+
for (var p = f.getCoordinates(), y = h.getCoordinates(), d = 0; d < p.length - 1; d++)
|
|
13988
|
+
for (var v = 0; v < y.length - 1; v++) {
|
|
13989
|
+
var C = M.distanceLineLine(p[d], p[d + 1], y[v], y[v + 1]);
|
|
13990
|
+
if (C < t._minDistance) {
|
|
13991
|
+
t._minDistance = C;
|
|
13992
|
+
var I = new k(p[d], p[d + 1]), N = new k(y[v], y[v + 1]), L = I.closestPoints(N);
|
|
13993
|
+
g[0] = new ie(f, d, L[0]), g[1] = new ie(h, v, L[1]);
|
|
13994
13994
|
}
|
|
13995
13995
|
if (t._minDistance <= t._terminateDistance)
|
|
13996
13996
|
return null;
|
|
@@ -14120,15 +14120,15 @@ lr.computeDistance = function() {
|
|
|
14120
14120
|
else if (h instanceof At)
|
|
14121
14121
|
lr.computeDistance(h, g, p);
|
|
14122
14122
|
else if (h instanceof ae)
|
|
14123
|
-
for (var
|
|
14124
|
-
var
|
|
14125
|
-
lr.computeDistance(
|
|
14123
|
+
for (var y = h, d = 0; d < y.getNumGeometries(); d++) {
|
|
14124
|
+
var v = y.getGeometryN(d);
|
|
14125
|
+
lr.computeDistance(v, g, p);
|
|
14126
14126
|
}
|
|
14127
14127
|
else
|
|
14128
14128
|
p.setMinimum(h.getCoordinate(), g);
|
|
14129
14129
|
} else if (arguments[2] instanceof Zt && arguments[0] instanceof k && arguments[1] instanceof m) {
|
|
14130
|
-
var
|
|
14131
|
-
N.setMinimum(L,
|
|
14130
|
+
var C = arguments[0], I = arguments[1], N = arguments[2], L = C.closestPoint(I);
|
|
14131
|
+
N.setMinimum(L, I);
|
|
14132
14132
|
}
|
|
14133
14133
|
};
|
|
14134
14134
|
var Fe = function() {
|
|
@@ -16459,15 +16459,15 @@ function Ao(n, t, e, r) {
|
|
|
16459
16459
|
function il(n, t, e, r, i) {
|
|
16460
16460
|
var o = [], s = [], a, u;
|
|
16461
16461
|
if (n.forEach(function(p) {
|
|
16462
|
-
if (!((
|
|
16463
|
-
var
|
|
16464
|
-
if (zo(d,
|
|
16465
|
-
for (i.lineStart(), a = 0; a <
|
|
16462
|
+
if (!((y = p.length - 1) <= 0)) {
|
|
16463
|
+
var y, d = p[0], v = p[y], C;
|
|
16464
|
+
if (zo(d, v)) {
|
|
16465
|
+
for (i.lineStart(), a = 0; a < y; ++a)
|
|
16466
16466
|
i.point((d = p[a])[0], d[1]);
|
|
16467
16467
|
i.lineEnd();
|
|
16468
16468
|
return;
|
|
16469
16469
|
}
|
|
16470
|
-
o.push(
|
|
16470
|
+
o.push(C = new Ao(d, p, null, !0)), s.push(C.o = new Ao(d, null, C, !1)), o.push(C = new Ao(v, p, null, !1)), s.push(C.o = new Ao(v, null, C, !0));
|
|
16471
16471
|
}
|
|
16472
16472
|
}), !!o.length) {
|
|
16473
16473
|
for (s.sort(t), iu(o), iu(s), a = 0, u = s.length; a < u; ++a)
|
|
@@ -16566,7 +16566,7 @@ function Wf(n, t, e, r) {
|
|
|
16566
16566
|
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];
|
|
16567
16567
|
}
|
|
16568
16568
|
return function(l) {
|
|
16569
|
-
var c = l, f = nl(), h, g, p,
|
|
16569
|
+
var c = l, f = nl(), h, g, p, y, d, v, C, I, N, L, T, R = {
|
|
16570
16570
|
point: D,
|
|
16571
16571
|
lineStart: G,
|
|
16572
16572
|
lineEnd: at,
|
|
@@ -16590,22 +16590,22 @@ function Wf(n, t, e, r) {
|
|
|
16590
16590
|
(K || _t) && (l.polygonStart(), K && (l.lineStart(), o(null, null, 1, l), l.lineEnd()), _t && il(h, a, B, o, l), l.polygonEnd()), c = l, h = g = p = null;
|
|
16591
16591
|
}
|
|
16592
16592
|
function G() {
|
|
16593
|
-
R.point = x, g && g.push(p = []), L = !0, N = !1,
|
|
16593
|
+
R.point = x, g && g.push(p = []), L = !0, N = !1, C = I = NaN;
|
|
16594
16594
|
}
|
|
16595
16595
|
function at() {
|
|
16596
|
-
h && (x(
|
|
16596
|
+
h && (x(y, d), v && N && f.rejoin(), h.push(f.result())), R.point = D, N && c.lineEnd();
|
|
16597
16597
|
}
|
|
16598
16598
|
function x(B, K) {
|
|
16599
16599
|
var _t = i(B, K);
|
|
16600
16600
|
if (g && p.push([B, K]), L)
|
|
16601
|
-
|
|
16601
|
+
y = B, d = K, v = _t, L = !1, _t && (c.lineStart(), c.point(B, K));
|
|
16602
16602
|
else if (_t && N)
|
|
16603
16603
|
c.point(B, K);
|
|
16604
16604
|
else {
|
|
16605
|
-
var Qt = [
|
|
16605
|
+
var Qt = [C = Math.max(Fo, Math.min(Zi, C)), I = Math.max(Fo, Math.min(Zi, I))], zt = [B = Math.max(Fo, Math.min(Zi, B)), K = Math.max(Fo, Math.min(Zi, K))];
|
|
16606
16606
|
qf(Qt, zt, n, t, e, r) ? (N || (c.lineStart(), c.point(Qt[0], Qt[1])), c.point(zt[0], zt[1]), _t || c.lineEnd(), T = !1) : _t && (c.lineStart(), c.point(B, K), T = !1);
|
|
16607
16607
|
}
|
|
16608
|
-
|
|
16608
|
+
C = B, I = K, N = _t;
|
|
16609
16609
|
}
|
|
16610
16610
|
return R;
|
|
16611
16611
|
};
|
|
@@ -16616,10 +16616,10 @@ function Hf(n, t) {
|
|
|
16616
16616
|
ws.reset();
|
|
16617
16617
|
for (var a = 0, u = n.length; a < u; ++a)
|
|
16618
16618
|
if (c = (l = n[a]).length)
|
|
16619
|
-
for (var l, c, f = l[c - 1], h = f[0], g = f[1] / 2 + Qa, p = Dt(g),
|
|
16620
|
-
var
|
|
16621
|
-
if (ws.add(Bi(A * R * Dt(D),
|
|
16622
|
-
var Y = Jo(Gi(f), Gi(
|
|
16619
|
+
for (var l, c, f = l[c - 1], h = f[0], g = f[1] / 2 + Qa, p = Dt(g), y = Tt(g), d = 0; d < c; ++d, h = C, p = N, y = L, f = v) {
|
|
16620
|
+
var v = l[d], C = v[0], I = v[1] / 2 + Qa, N = Dt(I), L = Tt(I), T = C - h, R = T >= 0 ? 1 : -1, D = R * T, b = D > ut, A = p * N;
|
|
16621
|
+
if (ws.add(Bi(A * R * Dt(D), y * L + A * Tt(D))), o += b ? T + R * rn : T, b ^ h >= e ^ C >= e) {
|
|
16622
|
+
var Y = Jo(Gi(f), Gi(v));
|
|
16623
16623
|
qs(Y);
|
|
16624
16624
|
var G = Jo(i, Y);
|
|
16625
16625
|
qs(G);
|
|
@@ -16653,14 +16653,14 @@ Wn();
|
|
|
16653
16653
|
function al(n, t, e, r) {
|
|
16654
16654
|
return function(i, o) {
|
|
16655
16655
|
var s = t(o), a = i.invert(r[0], r[1]), u = nl(), l = t(u), c = !1, f, h, g, p = {
|
|
16656
|
-
point:
|
|
16657
|
-
lineStart:
|
|
16658
|
-
lineEnd:
|
|
16656
|
+
point: y,
|
|
16657
|
+
lineStart: v,
|
|
16658
|
+
lineEnd: C,
|
|
16659
16659
|
polygonStart: function() {
|
|
16660
|
-
p.point =
|
|
16660
|
+
p.point = I, p.lineStart = N, p.lineEnd = L, h = [], f = [];
|
|
16661
16661
|
},
|
|
16662
16662
|
polygonEnd: function() {
|
|
16663
|
-
p.point =
|
|
16663
|
+
p.point = y, p.lineStart = v, p.lineEnd = C, h = sl(h);
|
|
16664
16664
|
var T = Hf(f, a);
|
|
16665
16665
|
h.length ? (c || (o.polygonStart(), c = !0), il(h, Qf, T, e, o)) : T && (c || (o.polygonStart(), c = !0), o.lineStart(), e(null, null, 1, o), o.lineEnd()), c && (o.polygonEnd(), c = !1), h = f = null;
|
|
16666
16666
|
},
|
|
@@ -16668,7 +16668,7 @@ function al(n, t, e, r) {
|
|
|
16668
16668
|
o.polygonStart(), o.lineStart(), e(null, null, 1, o), o.lineEnd(), o.polygonEnd();
|
|
16669
16669
|
}
|
|
16670
16670
|
};
|
|
16671
|
-
function
|
|
16671
|
+
function y(T, R) {
|
|
16672
16672
|
var D = i(T, R);
|
|
16673
16673
|
n(T = D[0], R = D[1]) && o.point(T, R);
|
|
16674
16674
|
}
|
|
@@ -16676,13 +16676,13 @@ function al(n, t, e, r) {
|
|
|
16676
16676
|
var D = i(T, R);
|
|
16677
16677
|
s.point(D[0], D[1]);
|
|
16678
16678
|
}
|
|
16679
|
-
function
|
|
16679
|
+
function v() {
|
|
16680
16680
|
p.point = d, s.lineStart();
|
|
16681
16681
|
}
|
|
16682
|
-
function
|
|
16683
|
-
p.point =
|
|
16682
|
+
function C() {
|
|
16683
|
+
p.point = y, s.lineEnd();
|
|
16684
16684
|
}
|
|
16685
|
-
function
|
|
16685
|
+
function I(T, R) {
|
|
16686
16686
|
g.push([T, R]);
|
|
16687
16687
|
var D = i(T, R);
|
|
16688
16688
|
l.point(D[0], D[1]);
|
|
@@ -16691,7 +16691,7 @@ function al(n, t, e, r) {
|
|
|
16691
16691
|
l.lineStart(), g = [];
|
|
16692
16692
|
}
|
|
16693
16693
|
function L() {
|
|
16694
|
-
|
|
16694
|
+
I(g[0][0], g[0][1]), l.lineEnd();
|
|
16695
16695
|
var T = l.clean(), R = u.result(), D, b = R.length, A, Y, G;
|
|
16696
16696
|
if (g.pop(), f.push(g), g = null, !!b) {
|
|
16697
16697
|
if (T & 1) {
|
|
@@ -16763,20 +16763,20 @@ function th(n, t) {
|
|
|
16763
16763
|
return Tt(c) * Tt(f) > e;
|
|
16764
16764
|
}
|
|
16765
16765
|
function a(c) {
|
|
16766
|
-
var f, h, g, p,
|
|
16766
|
+
var f, h, g, p, y;
|
|
16767
16767
|
return {
|
|
16768
16768
|
lineStart: function() {
|
|
16769
|
-
p = g = !1,
|
|
16769
|
+
p = g = !1, y = 1;
|
|
16770
16770
|
},
|
|
16771
|
-
point: function(d,
|
|
16772
|
-
var
|
|
16773
|
-
if (!f && (p = g = N) && c.lineStart(), N !== g && (
|
|
16774
|
-
|
|
16771
|
+
point: function(d, v) {
|
|
16772
|
+
var C = [d, v], I, N = s(d, v), L = r ? N ? 0 : l(d, v) : N ? l(d + (d < 0 ? ut : -ut), v) : 0;
|
|
16773
|
+
if (!f && (p = g = N) && c.lineStart(), N !== g && (I = u(f, C), (!I || zo(f, I) || zo(C, I)) && (C[0] += vt, C[1] += vt, N = s(C[0], C[1]))), N !== g)
|
|
16774
|
+
y = 0, N ? (c.lineStart(), I = u(C, f), c.point(I[0], I[1])) : (I = u(f, C), c.point(I[0], I[1]), c.lineEnd()), f = I;
|
|
16775
16775
|
else if (i && f && r ^ N) {
|
|
16776
16776
|
var T;
|
|
16777
|
-
!(L & h) && (T = u(
|
|
16777
|
+
!(L & h) && (T = u(C, f, !0)) && (y = 0, r ? (c.lineStart(), c.point(T[0][0], T[0][1]), c.point(T[1][0], T[1][1]), c.lineEnd()) : (c.point(T[1][0], T[1][1]), c.lineEnd(), c.lineStart(), c.point(T[0][0], T[0][1])));
|
|
16778
16778
|
}
|
|
16779
|
-
N && (!f || !zo(f,
|
|
16779
|
+
N && (!f || !zo(f, C)) && c.point(C[0], C[1]), f = C, g = N, h = L;
|
|
16780
16780
|
},
|
|
16781
16781
|
lineEnd: function() {
|
|
16782
16782
|
g && c.lineEnd(), f = null;
|
|
@@ -16784,15 +16784,15 @@ function th(n, t) {
|
|
|
16784
16784
|
// Rejoin first and last segments if there were intersections and the first
|
|
16785
16785
|
// and last points were visible.
|
|
16786
16786
|
clean: function() {
|
|
16787
|
-
return
|
|
16787
|
+
return y | (p && g) << 1;
|
|
16788
16788
|
}
|
|
16789
16789
|
};
|
|
16790
16790
|
}
|
|
16791
16791
|
function u(c, f, h) {
|
|
16792
|
-
var g = Gi(c), p = Gi(f),
|
|
16793
|
-
if (!
|
|
16792
|
+
var g = Gi(c), p = Gi(f), y = [1, 0, 0], d = Jo(g, p), v = Do(d, d), C = d[0], I = v - C * C;
|
|
16793
|
+
if (!I)
|
|
16794
16794
|
return !h && c;
|
|
16795
|
-
var N = e *
|
|
16795
|
+
var N = e * v / I, L = -e * C / I, T = Jo(y, d), R = Mo(y, N), D = Mo(d, L);
|
|
16796
16796
|
bs(R, D);
|
|
16797
16797
|
var b = T, A = Do(R, b), Y = Do(b, b), G = A * A - Y * (Do(R, R) - 1);
|
|
16798
16798
|
if (!(G < 0)) {
|
|
@@ -16866,46 +16866,46 @@ function nh(n) {
|
|
|
16866
16866
|
});
|
|
16867
16867
|
}
|
|
16868
16868
|
function ih(n, t) {
|
|
16869
|
-
function e(r, i, o, s, a, u, l, c, f, h, g, p,
|
|
16870
|
-
var
|
|
16871
|
-
if (
|
|
16872
|
-
var N = s + h, L = a + g, T = u + p, R = Yi(N * N + L * L + T * T), D = ui(T /= R), b = oe(oe(T) - 1) < vt || oe(o - f) < vt ? (o + f) / 2 : Bi(L, N), A = n(b, D), Y = A[0], G = A[1], at = Y - r, x = G - i, B =
|
|
16873
|
-
(B * B /
|
|
16869
|
+
function e(r, i, o, s, a, u, l, c, f, h, g, p, y, d) {
|
|
16870
|
+
var v = l - r, C = c - i, I = v * v + C * C;
|
|
16871
|
+
if (I > 4 * t && y--) {
|
|
16872
|
+
var N = s + h, L = a + g, T = u + p, R = Yi(N * N + L * L + T * T), D = ui(T /= R), b = oe(oe(T) - 1) < vt || oe(o - f) < vt ? (o + f) / 2 : Bi(L, N), A = n(b, D), Y = A[0], G = A[1], at = Y - r, x = G - i, B = C * at - v * x;
|
|
16873
|
+
(B * B / I > t || oe((v * at + C * x) / I - 0.5) > 0.3 || s * h + a * g + u * p < rh) && (e(r, i, o, s, a, u, Y, G, b, N /= R, L /= R, T, y, d), d.point(Y, G), e(Y, G, b, N, L, T, l, c, f, h, g, p, y, d));
|
|
16874
16874
|
}
|
|
16875
16875
|
}
|
|
16876
16876
|
return function(r) {
|
|
16877
|
-
var i, o, s, a, u, l, c, f, h, g, p,
|
|
16878
|
-
point:
|
|
16879
|
-
lineStart:
|
|
16877
|
+
var i, o, s, a, u, l, c, f, h, g, p, y, d = {
|
|
16878
|
+
point: v,
|
|
16879
|
+
lineStart: C,
|
|
16880
16880
|
lineEnd: N,
|
|
16881
16881
|
polygonStart: function() {
|
|
16882
16882
|
r.polygonStart(), d.lineStart = L;
|
|
16883
16883
|
},
|
|
16884
16884
|
polygonEnd: function() {
|
|
16885
|
-
r.polygonEnd(), d.lineStart =
|
|
16885
|
+
r.polygonEnd(), d.lineStart = C;
|
|
16886
16886
|
}
|
|
16887
16887
|
};
|
|
16888
|
-
function
|
|
16888
|
+
function v(D, b) {
|
|
16889
16889
|
D = n(D, b), r.point(D[0], D[1]);
|
|
16890
16890
|
}
|
|
16891
|
-
function
|
|
16892
|
-
f = NaN, d.point =
|
|
16891
|
+
function C() {
|
|
16892
|
+
f = NaN, d.point = I, r.lineStart();
|
|
16893
16893
|
}
|
|
16894
|
-
function
|
|
16894
|
+
function I(D, b) {
|
|
16895
16895
|
var A = Gi([D, b]), Y = n(D, b);
|
|
16896
|
-
e(f, h, c, g, p,
|
|
16896
|
+
e(f, h, c, g, p, y, f = Y[0], h = Y[1], c = D, g = A[0], p = A[1], y = A[2], uu, r), r.point(f, h);
|
|
16897
16897
|
}
|
|
16898
16898
|
function N() {
|
|
16899
|
-
d.point =
|
|
16899
|
+
d.point = v, r.lineEnd();
|
|
16900
16900
|
}
|
|
16901
16901
|
function L() {
|
|
16902
|
-
|
|
16902
|
+
C(), d.point = T, d.lineEnd = R;
|
|
16903
16903
|
}
|
|
16904
16904
|
function T(D, b) {
|
|
16905
|
-
|
|
16905
|
+
I(i = D, b), o = f, s = h, a = g, u = p, l = y, d.point = I;
|
|
16906
16906
|
}
|
|
16907
16907
|
function R() {
|
|
16908
|
-
e(f, h, c, g, p,
|
|
16908
|
+
e(f, h, c, g, p, y, o, s, i, a, u, l, uu, r), d.lineEnd = N, N();
|
|
16909
16909
|
}
|
|
16910
16910
|
return d;
|
|
16911
16911
|
};
|
|
@@ -16921,7 +16921,7 @@ function sh(n) {
|
|
|
16921
16921
|
})();
|
|
16922
16922
|
}
|
|
16923
16923
|
function ah(n) {
|
|
16924
|
-
var t, e = 150, r = 480, i = 250, o, s, a = 0, u = 0, l = 0, c = 0, f = 0, h, g, p = null,
|
|
16924
|
+
var t, e = 150, r = 480, i = 250, o, s, a = 0, u = 0, l = 0, c = 0, f = 0, h, g, p = null, y = au, d = null, v, C, I, N = ou, L = 0.5, T = lu(Y, L), R, D;
|
|
16925
16925
|
function b(x) {
|
|
16926
16926
|
return x = g(x[0] * ar, x[1] * ar), [x[0] * e + o, s - x[1] * e];
|
|
16927
16927
|
}
|
|
@@ -16932,11 +16932,11 @@ function ah(n) {
|
|
|
16932
16932
|
return x = t(x, B), [x[0] * e + o, s - x[1] * e];
|
|
16933
16933
|
}
|
|
16934
16934
|
b.stream = function(x) {
|
|
16935
|
-
return R && D === x ? R : R = oh(
|
|
16935
|
+
return R && D === x ? R : R = oh(y(h, T(N(D = x))));
|
|
16936
16936
|
}, b.clipAngle = function(x) {
|
|
16937
|
-
return arguments.length ? (
|
|
16937
|
+
return arguments.length ? (y = +x ? th(p = x * ar, 6 * ar) : (p = null, au), at()) : p * xn;
|
|
16938
16938
|
}, b.clipExtent = function(x) {
|
|
16939
|
-
return arguments.length ? (N = x == null ? (d =
|
|
16939
|
+
return arguments.length ? (N = x == null ? (d = v = C = I = null, ou) : Wf(d = +x[0][0], v = +x[0][1], C = +x[1][0], I = +x[1][1]), at()) : d == null ? null : [[d, v], [C, I]];
|
|
16940
16940
|
}, b.scale = function(x) {
|
|
16941
16941
|
return arguments.length ? (e = +x, G()) : e;
|
|
16942
16942
|
}, b.translate = function(x) {
|
|
@@ -17033,8 +17033,8 @@ function Vo(n, t, e, r) {
|
|
|
17033
17033
|
var i = n.properties || {}, o = n.type === "Feature" ? n.geometry : n;
|
|
17034
17034
|
if (o.type === "GeometryCollection") {
|
|
17035
17035
|
var s = [];
|
|
17036
|
-
return bu(n, function(
|
|
17037
|
-
var d = Vo(
|
|
17036
|
+
return bu(n, function(y) {
|
|
17037
|
+
var d = Vo(y, t, e, r);
|
|
17038
17038
|
d && s.push(d);
|
|
17039
17039
|
}), Bs(s);
|
|
17040
17040
|
}
|
|
@@ -17135,136 +17135,138 @@ function gh(n, t, e = !0, r = !0, i = {}, o = {}, s = {
|
|
|
17135
17135
|
filter: ["!", ["has", "isMask"]]
|
|
17136
17136
|
}
|
|
17137
17137
|
}) {
|
|
17138
|
-
let a, u = [], l, c;
|
|
17139
|
-
function
|
|
17140
|
-
(s != null && s.fill || s != null && s.line) && n.addSource("full-geom", {
|
|
17138
|
+
let a, u = [], l, c, f;
|
|
17139
|
+
function h() {
|
|
17140
|
+
!n.getSource("full-geom") && (s != null && s.fill || s != null && s.line) && n.addSource("full-geom", {
|
|
17141
17141
|
type: "geojson",
|
|
17142
17142
|
data: gu
|
|
17143
|
-
}), s != null && s.fill && n.addLayer({
|
|
17143
|
+
}), !n.getLayer("full-geom-fill") && (s != null && s.fill) && n.addLayer({
|
|
17144
17144
|
...s == null ? void 0 : s.fill,
|
|
17145
17145
|
id: "full-geom-fill",
|
|
17146
17146
|
type: "fill",
|
|
17147
17147
|
source: "full-geom"
|
|
17148
|
-
}), s != null && s.line && n.addLayer({
|
|
17148
|
+
}), !n.getLayer("full-geom-line") && (s != null && s.line) && n.addLayer({
|
|
17149
17149
|
...s == null ? void 0 : s.line,
|
|
17150
17150
|
id: "full-geom-line",
|
|
17151
17151
|
type: "line",
|
|
17152
17152
|
source: "full-geom"
|
|
17153
|
-
});
|
|
17153
|
+
}), f && y(f);
|
|
17154
17154
|
}
|
|
17155
|
-
n.loaded() ?
|
|
17156
|
-
|
|
17155
|
+
n.loaded() ? h() : n.once("load", () => {
|
|
17156
|
+
h();
|
|
17157
|
+
}), n.on("styledata", () => {
|
|
17158
|
+
h();
|
|
17157
17159
|
});
|
|
17158
|
-
const
|
|
17160
|
+
const g = (d) => {
|
|
17159
17161
|
a == null || a({
|
|
17160
17162
|
type: "mapClick",
|
|
17161
|
-
coordinates: [
|
|
17163
|
+
coordinates: [d.lngLat.lng, d.lngLat.lat]
|
|
17162
17164
|
});
|
|
17163
17165
|
};
|
|
17164
|
-
function
|
|
17166
|
+
function p(d = !1) {
|
|
17165
17167
|
if (!t)
|
|
17166
17168
|
throw new Error();
|
|
17167
17169
|
const v = document.createElement("div");
|
|
17168
|
-
return
|
|
17170
|
+
return d && v.classList.add("marker-interactive"), new Nc({
|
|
17169
17171
|
props: { displayIn: "maplibre" },
|
|
17170
17172
|
target: v
|
|
17171
17173
|
}), new t.Marker({ element: v, offset: [1, -13] });
|
|
17172
17174
|
}
|
|
17175
|
+
function y(d) {
|
|
17176
|
+
var v;
|
|
17177
|
+
f = d, (v = n.getSource("full-geom")) == null || v.setData(d);
|
|
17178
|
+
}
|
|
17173
17179
|
return {
|
|
17174
|
-
setEventHandler(
|
|
17175
|
-
|
|
17180
|
+
setEventHandler(d) {
|
|
17181
|
+
d ? (a = d, n.on("click", g)) : (a = void 0, n.off("click", g));
|
|
17176
17182
|
},
|
|
17177
|
-
flyTo(
|
|
17178
|
-
n.flyTo({ center:
|
|
17183
|
+
flyTo(d, v) {
|
|
17184
|
+
n.flyTo({ center: d, zoom: v, ...i });
|
|
17179
17185
|
},
|
|
17180
|
-
fitBounds(
|
|
17186
|
+
fitBounds(d, v, C) {
|
|
17181
17187
|
n.fitBounds(
|
|
17182
17188
|
[
|
|
17183
|
-
[
|
|
17184
|
-
[
|
|
17189
|
+
[d[0], d[1]],
|
|
17190
|
+
[d[2], d[3]]
|
|
17185
17191
|
],
|
|
17186
|
-
{ padding: v, maxZoom:
|
|
17192
|
+
{ padding: v, maxZoom: C, ...o }
|
|
17187
17193
|
);
|
|
17188
17194
|
},
|
|
17189
|
-
indicateReverse(
|
|
17190
|
-
n.getCanvasContainer().style.cursor =
|
|
17195
|
+
indicateReverse(d) {
|
|
17196
|
+
n.getCanvasContainer().style.cursor = d ? "crosshair" : "";
|
|
17191
17197
|
},
|
|
17192
|
-
setReverseMarker(
|
|
17193
|
-
!t || !e || (c ?
|
|
17198
|
+
setReverseMarker(d) {
|
|
17199
|
+
!t || !e || (c ? d ? c.setLngLat(d) : (c.remove(), c = void 0) : d && (c = (typeof e == "object" ? new t.Marker(e) : p()).setLngLat(d).addTo(n), c.getElement().classList.add("marker-reverse")));
|
|
17194
17200
|
},
|
|
17195
|
-
setMarkers(
|
|
17196
|
-
if (
|
|
17197
|
-
|
|
17198
|
-
|
|
17199
|
-
|
|
17200
|
-
|
|
17201
|
-
|
|
17202
|
-
|
|
17203
|
-
|
|
17204
|
-
|
|
17205
|
-
if (v) {
|
|
17206
|
-
let y = !1;
|
|
17207
|
-
if (v.geometry.type === "GeometryCollection") {
|
|
17208
|
-
const I = v.geometry.geometries.filter(
|
|
17209
|
-
(C) => C.type === "Polygon" || C.type === "MultiPolygon"
|
|
17210
|
-
);
|
|
17211
|
-
if (I.length > 0) {
|
|
17212
|
-
let C = I.pop();
|
|
17213
|
-
for (const N of I)
|
|
17214
|
-
C = Ef(C, N);
|
|
17215
|
-
hu({ ...v, geometry: C }, d), y = !0;
|
|
17216
|
-
} else {
|
|
17217
|
-
const C = v.geometry.geometries.filter(
|
|
17218
|
-
(N) => N.type === "LineString" || N.type === "MultiLineString"
|
|
17201
|
+
setMarkers(d, v) {
|
|
17202
|
+
if (e) {
|
|
17203
|
+
for (const C of u)
|
|
17204
|
+
C.remove();
|
|
17205
|
+
if (u.length = 0, y(gu), !!t) {
|
|
17206
|
+
if (v) {
|
|
17207
|
+
let C = !1;
|
|
17208
|
+
if (v.geometry.type === "GeometryCollection") {
|
|
17209
|
+
const I = v.geometry.geometries.filter(
|
|
17210
|
+
(N) => N.type === "Polygon" || N.type === "MultiPolygon"
|
|
17219
17211
|
);
|
|
17220
|
-
|
|
17221
|
-
|
|
17222
|
-
|
|
17223
|
-
|
|
17212
|
+
if (I.length > 0) {
|
|
17213
|
+
let N = I.pop();
|
|
17214
|
+
for (const L of I)
|
|
17215
|
+
N = Ef(N, L);
|
|
17216
|
+
hu({ ...v, geometry: N }, y), C = !0;
|
|
17217
|
+
} else {
|
|
17218
|
+
const N = v.geometry.geometries.filter(
|
|
17219
|
+
(L) => L.type === "LineString" || L.type === "MultiLineString"
|
|
17220
|
+
);
|
|
17221
|
+
N.length > 0 && (y({
|
|
17222
|
+
...v,
|
|
17223
|
+
geometry: { type: "GeometryCollection", geometries: N }
|
|
17224
|
+
}), C = !0);
|
|
17225
|
+
}
|
|
17224
17226
|
}
|
|
17225
|
-
|
|
17226
|
-
|
|
17227
|
-
|
|
17228
|
-
|
|
17229
|
-
|
|
17230
|
-
|
|
17231
|
-
|
|
17227
|
+
if (!C) {
|
|
17228
|
+
if (v.geometry.type === "Polygon" || v.geometry.type === "MultiPolygon")
|
|
17229
|
+
hu(v, y);
|
|
17230
|
+
else if (v.geometry.type === "LineString" || v.geometry.type === "MultiLineString") {
|
|
17231
|
+
y(v);
|
|
17232
|
+
return;
|
|
17233
|
+
}
|
|
17232
17234
|
}
|
|
17235
|
+
e && u.push(
|
|
17236
|
+
(typeof e == "object" ? new t.Marker(e) : p()).setLngLat(v.center).addTo(n)
|
|
17237
|
+
);
|
|
17233
17238
|
}
|
|
17234
|
-
|
|
17235
|
-
(
|
|
17236
|
-
|
|
17239
|
+
if (r)
|
|
17240
|
+
for (const C of d ?? []) {
|
|
17241
|
+
if (C === v)
|
|
17242
|
+
continue;
|
|
17243
|
+
const I = (typeof r == "object" ? new t.Marker(r) : p(!0)).setLngLat(C.center).setPopup(
|
|
17244
|
+
new t.Popup({
|
|
17245
|
+
offset: [1, -27],
|
|
17246
|
+
closeButton: !1,
|
|
17247
|
+
closeOnMove: !0,
|
|
17248
|
+
className: "maptiler-gc-popup"
|
|
17249
|
+
}).setText(
|
|
17250
|
+
C.place_type[0] === "reverse" ? C.place_name : C.place_name.replace(/,.*/, "")
|
|
17251
|
+
)
|
|
17252
|
+
).addTo(n), N = I.getElement();
|
|
17253
|
+
N.addEventListener("click", (L) => {
|
|
17254
|
+
L.stopPropagation(), a == null || a({ type: "markerClick", id: C.id });
|
|
17255
|
+
}), N.addEventListener("mouseenter", () => {
|
|
17256
|
+
a == null || a({ type: "markerMouseEnter", id: C.id }), I.togglePopup();
|
|
17257
|
+
}), N.addEventListener("mouseleave", () => {
|
|
17258
|
+
a == null || a({ type: "markerMouseLeave", id: C.id }), I.togglePopup();
|
|
17259
|
+
}), u.push(I);
|
|
17260
|
+
}
|
|
17237
17261
|
}
|
|
17238
|
-
if (r)
|
|
17239
|
-
for (const y of p ?? []) {
|
|
17240
|
-
if (y === v)
|
|
17241
|
-
continue;
|
|
17242
|
-
const I = (typeof r == "object" ? new t.Marker(r) : g(!0)).setLngLat(y.center).setPopup(
|
|
17243
|
-
new t.Popup({
|
|
17244
|
-
offset: [1, -27],
|
|
17245
|
-
closeButton: !1,
|
|
17246
|
-
closeOnMove: !0,
|
|
17247
|
-
className: "maptiler-gc-popup"
|
|
17248
|
-
}).setText(
|
|
17249
|
-
y.place_type[0] === "reverse" ? y.place_name : y.place_name.replace(/,.*/, "")
|
|
17250
|
-
)
|
|
17251
|
-
).addTo(n), C = I.getElement();
|
|
17252
|
-
C.addEventListener("click", (N) => {
|
|
17253
|
-
N.stopPropagation(), a == null || a({ type: "markerClick", id: y.id });
|
|
17254
|
-
}), C.addEventListener("mouseenter", () => {
|
|
17255
|
-
a == null || a({ type: "markerMouseEnter", id: y.id }), I.togglePopup();
|
|
17256
|
-
}), C.addEventListener("mouseleave", () => {
|
|
17257
|
-
a == null || a({ type: "markerMouseLeave", id: y.id }), I.togglePopup();
|
|
17258
|
-
}), u.push(I);
|
|
17259
|
-
}
|
|
17260
17262
|
}
|
|
17261
17263
|
},
|
|
17262
|
-
setSelectedMarker(
|
|
17263
|
-
l && l.getElement().classList.toggle("marker-selected", !1), l =
|
|
17264
|
+
setSelectedMarker(d) {
|
|
17265
|
+
l && l.getElement().classList.toggle("marker-selected", !1), l = d > -1 ? u[d] : void 0, l == null || l.getElement().classList.toggle("marker-selected", !0);
|
|
17264
17266
|
},
|
|
17265
17267
|
getCenterAndZoom() {
|
|
17266
|
-
const
|
|
17267
|
-
return [n.getZoom(),
|
|
17268
|
+
const d = n.getCenter();
|
|
17269
|
+
return [n.getZoom(), d.lng, d.lat];
|
|
17268
17270
|
}
|
|
17269
17271
|
};
|
|
17270
17272
|
}
|