gralobe 1.0.68 → 1.0.69
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/gralobe.js +127 -100
- package/dist/gralobe.js.map +1 -1
- package/dist/gralobe.umd.cjs +13 -13
- package/dist/gralobe.umd.cjs.map +1 -1
- package/dist/index.d.ts +15 -0
- package/package.json +1 -1
package/dist/gralobe.js
CHANGED
|
@@ -1572,7 +1572,7 @@ const Qe = [
|
|
|
1572
1572
|
forestArea: 62.1,
|
|
1573
1573
|
accessElectricity: 95
|
|
1574
1574
|
}
|
|
1575
|
-
],
|
|
1575
|
+
], qt = [
|
|
1576
1576
|
{
|
|
1577
1577
|
id: "humanDevIndex",
|
|
1578
1578
|
name: "Human Development Index",
|
|
@@ -1904,7 +1904,7 @@ function vr(s) {
|
|
|
1904
1904
|
return s ? `${t} ${s}` : t;
|
|
1905
1905
|
};
|
|
1906
1906
|
}
|
|
1907
|
-
function
|
|
1907
|
+
function qa(s, e, t) {
|
|
1908
1908
|
return (t ?? vr(e))(s);
|
|
1909
1909
|
}
|
|
1910
1910
|
function Pe(s) {
|
|
@@ -1926,7 +1926,7 @@ var ce = {
|
|
|
1926
1926
|
duration: 0.5,
|
|
1927
1927
|
overwrite: !1,
|
|
1928
1928
|
delay: 0
|
|
1929
|
-
}, Pi,
|
|
1929
|
+
}, Pi, Z, N, fe = 1e8, z = 1 / fe, li = Math.PI * 2, Dn = li / 4, Rn = 0, Er = Math.sqrt, kn = Math.cos, On = Math.sin, X = function(e) {
|
|
1930
1930
|
return typeof e == "string";
|
|
1931
1931
|
}, G = function(e) {
|
|
1932
1932
|
return typeof e == "function";
|
|
@@ -1943,7 +1943,7 @@ var ce = {
|
|
|
1943
1943
|
}, Lt = function(e) {
|
|
1944
1944
|
return G(e) || X(e);
|
|
1945
1945
|
}, wr = typeof ArrayBuffer == "function" && ArrayBuffer.isView || function() {
|
|
1946
|
-
}, Q = Array.isArray, ci = /(?:-?\.?\d|\.)+/gi, Cr = /[-+=.]*\d+[.e\-+]*\d*[e\-+]*\d*/g, et = /[-+=.]*\d+[.e-]*\d*[a-z%]*/g,
|
|
1946
|
+
}, Q = Array.isArray, ci = /(?:-?\.?\d|\.)+/gi, Cr = /[-+=.]*\d+[.e\-+]*\d*[e\-+]*\d*/g, et = /[-+=.]*\d+[.e-]*\d*[a-z%]*/g, Zt = /[-+=.]*\d+\.?\d*(?:e-|e\+)?\d*/gi, Pr = /[+-]=-?[.\d]+/, Tr = /[^,'"\[\]\s]+/gi, Fn = /^[+\-=e\s\d]*\d+[.\d]*([a-z]*|%)\s*$/i, B, ye, ui, Ai, ue = {}, Nt = {}, Sr, Ar = function(e) {
|
|
1947
1947
|
return (Nt = st(e, ue)) && oe;
|
|
1948
1948
|
}, Mi = function(e, t) {
|
|
1949
1949
|
return console.warn("Invalid property", e, "set to", t, "Missing plugin? gsap.registerPlugin()");
|
|
@@ -1962,7 +1962,7 @@ var ce = {
|
|
|
1962
1962
|
kill: !1
|
|
1963
1963
|
}, Un = {
|
|
1964
1964
|
suppressEvents: !0
|
|
1965
|
-
}, Li = {}, Re = [], hi = {}, Lr, ae = {}, Kt = {},
|
|
1965
|
+
}, Li = {}, Re = [], hi = {}, Lr, ae = {}, Kt = {}, qi = 30, Ot = [], Ii = "", Di = function(e) {
|
|
1966
1966
|
var t = e[0], i, r;
|
|
1967
1967
|
if (Ee(t) || G(t) || (e = [e]), !(i = (t._gsap || {}).harness)) {
|
|
1968
1968
|
for (r = Ot.length; r-- && !Ot[r].targetTest(t); )
|
|
@@ -1978,7 +1978,7 @@ var ce = {
|
|
|
1978
1978
|
return (i = e[t]) && G(i) ? e[t]() : Ti(i) && e.getAttribute && e.getAttribute(t) || i;
|
|
1979
1979
|
}, ie = function(e, t) {
|
|
1980
1980
|
return (e = e.split(",")).forEach(t) || e;
|
|
1981
|
-
},
|
|
1981
|
+
}, H = function(e) {
|
|
1982
1982
|
return Math.round(e * 1e5) / 1e5 || 0;
|
|
1983
1983
|
}, Y = function(e) {
|
|
1984
1984
|
return Math.round(e * 1e7) / 1e7 || 0;
|
|
@@ -1996,7 +1996,7 @@ var ce = {
|
|
|
1996
1996
|
}, Ri = function(e) {
|
|
1997
1997
|
return !!(e._initted || e._startAt || e.add);
|
|
1998
1998
|
}, Dr = function(e, t, i, r) {
|
|
1999
|
-
Re.length && !
|
|
1999
|
+
Re.length && !Z && Bt(), e.render(t, i, !!(Z && t < 0 && Ri(e))), Re.length && !Z && Bt();
|
|
2000
2000
|
}, Rr = function(e) {
|
|
2001
2001
|
var t = parseFloat(e);
|
|
2002
2002
|
return (t || t === 0) && (e + "").match(Tr).length < 2 ? t : X(e) ? e.trim() : e;
|
|
@@ -2015,7 +2015,7 @@ var ce = {
|
|
|
2015
2015
|
for (var i in t)
|
|
2016
2016
|
e[i] = t[i];
|
|
2017
2017
|
return e;
|
|
2018
|
-
},
|
|
2018
|
+
}, Zi = function s(e, t) {
|
|
2019
2019
|
for (var i in t)
|
|
2020
2020
|
i !== "__proto__" && i !== "constructor" && i !== "prototype" && (e[i] = Ee(t[i]) ? s(e[i] || (e[i] = {}), t[i]) : t[i]);
|
|
2021
2021
|
return e;
|
|
@@ -2056,7 +2056,7 @@ var ce = {
|
|
|
2056
2056
|
t._dirty = 1, t.totalDuration(), t = t.parent;
|
|
2057
2057
|
return e;
|
|
2058
2058
|
}, di = function(e, t, i, r) {
|
|
2059
|
-
return e._startAt && (
|
|
2059
|
+
return e._startAt && (Z ? e._startAt.revert(kt) : e.vars.immediateRender && !e.vars.autoRevert || e._startAt.render(t, !0, r));
|
|
2060
2060
|
}, Vn = function s(e) {
|
|
2061
2061
|
return !e || e._ts && s(e.parent);
|
|
2062
2062
|
}, Ki = function(e) {
|
|
@@ -2086,7 +2086,7 @@ var ce = {
|
|
|
2086
2086
|
}, Ur = function(e, t, i, r, n) {
|
|
2087
2087
|
if (Oi(e, t, n), !e._initted)
|
|
2088
2088
|
return 1;
|
|
2089
|
-
if (!i && e._pt && !
|
|
2089
|
+
if (!i && e._pt && !Z && (e._dur && e.vars.lazy !== !1 || !e._dur && e.vars.lazy) && Lr !== se.frame)
|
|
2090
2090
|
return Re.push(e), e._lazy = [n, r], 1;
|
|
2091
2091
|
}, Hn = function s(e) {
|
|
2092
2092
|
var t = e.parent;
|
|
@@ -2096,12 +2096,12 @@ var ce = {
|
|
|
2096
2096
|
return t === "isFromStart" || t === "isStart";
|
|
2097
2097
|
}, jn = function(e, t, i, r) {
|
|
2098
2098
|
var n = e.ratio, o = t < 0 || !t && (!e._start && Hn(e) && !(!e._initted && pi(e)) || (e._ts < 0 || e._dp._ts < 0) && !pi(e)) ? 0 : 1, a = e._rDelay, l = 0, u, c, h;
|
|
2099
|
-
if (a && e._repeat && (l = St(0, e._tDur, t), c = lt(l, a), e._yoyo && c & 1 && (o = 1 - o), c !== lt(e._tTime, a) && (n = 1 - o, e.vars.repeatRefresh && e._initted && e.invalidate())), o !== n ||
|
|
2099
|
+
if (a && e._repeat && (l = St(0, e._tDur, t), c = lt(l, a), e._yoyo && c & 1 && (o = 1 - o), c !== lt(e._tTime, a) && (n = 1 - o, e.vars.repeatRefresh && e._initted && e.invalidate())), o !== n || Z || r || e._zTime === z || !t && e._zTime) {
|
|
2100
2100
|
if (!e._initted && Ur(e, t, r, i, l))
|
|
2101
2101
|
return;
|
|
2102
2102
|
for (h = e._zTime, e._zTime = t || (i ? z : 0), i || (i = t && !h), e.ratio = o, e._from && (o = 1 - o), e._time = 0, e._tTime = l, u = e._pt; u; )
|
|
2103
2103
|
u.r(o, u.d), u = u._next;
|
|
2104
|
-
t < 0 && di(e, t, i, !0), e._onUpdate && !i && le(e, "onUpdate"), l && e._repeat && !i && e.parent && le(e, "onRepeat"), (t >= e._tDur || t < 0) && e.ratio === o && (o && Oe(e, 1), !i && !
|
|
2104
|
+
t < 0 && di(e, t, i, !0), e._onUpdate && !i && le(e, "onUpdate"), l && e._repeat && !i && e.parent && le(e, "onRepeat"), (t >= e._tDur || t < 0) && e.ratio === o && (o && Oe(e, 1), !i && !Z && (le(e, o ? "onComplete" : "onReverseComplete", !0), e._prom && e._prom()));
|
|
2105
2105
|
} else e._zTime || (e._zTime = t);
|
|
2106
2106
|
}, Yn = function(e, t, i) {
|
|
2107
2107
|
var r;
|
|
@@ -2149,13 +2149,13 @@ var ce = {
|
|
|
2149
2149
|
});
|
|
2150
2150
|
}, fi = [].slice, Nr = function(e, t) {
|
|
2151
2151
|
return e && Ee(e) && "length" in e && (!t && !e.length || e.length - 1 in e && Ee(e[0])) && !e.nodeType && e !== ye;
|
|
2152
|
-
},
|
|
2152
|
+
}, qn = function(e, t, i) {
|
|
2153
2153
|
return i === void 0 && (i = []), e.forEach(function(r) {
|
|
2154
2154
|
var n;
|
|
2155
2155
|
return X(r) && !t || Nr(r, 1) ? (n = i).push.apply(n, me(r)) : i.push(r);
|
|
2156
2156
|
}) || i;
|
|
2157
2157
|
}, me = function(e, t, i) {
|
|
2158
|
-
return N && !t && N.selector ? N.selector(e) : X(e) && !i && (ui || !ut()) ? fi.call((t || Ai).querySelectorAll(e), 0) : Q(e) ?
|
|
2158
|
+
return N && !t && N.selector ? N.selector(e) : X(e) && !i && (ui || !ut()) ? fi.call((t || Ai).querySelectorAll(e), 0) : Q(e) ? qn(e, i) : Nr(e) ? fi.call(e, 0) : e ? [e] : [];
|
|
2159
2159
|
}, mi = function(e) {
|
|
2160
2160
|
return e = me(e)[0] || xt("Invalid scope") || {}, function(t) {
|
|
2161
2161
|
var i = e.current || e.nativeElement || e;
|
|
@@ -2208,7 +2208,7 @@ var ce = {
|
|
|
2208
2208
|
return ze(Q(e) ? !t : i === !0 ? !!(i = 0) : !r, function() {
|
|
2209
2209
|
return Q(e) ? e[~~(Math.random() * e.length)] : (i = i || 1e-5) && (r = i < 1 ? Math.pow(10, (i + "").length - 2) : 1) && Math.floor(Math.round((e - i / 2 + Math.random() * (t - e + i * 0.99)) / i) * i * r) / r;
|
|
2210
2210
|
});
|
|
2211
|
-
},
|
|
2211
|
+
}, Zn = function() {
|
|
2212
2212
|
for (var e = arguments.length, t = new Array(e), i = 0; i < e; i++)
|
|
2213
2213
|
t[i] = arguments[i];
|
|
2214
2214
|
return function(r) {
|
|
@@ -2285,7 +2285,7 @@ var ce = {
|
|
|
2285
2285
|
if (n)
|
|
2286
2286
|
return l = r[t + "Params"], u = r.callbackScope || e, i && Re.length && Bt(), a && (N = a), c = l ? n.apply(u, l) : n.call(u), N = o, c;
|
|
2287
2287
|
}, pt = function(e) {
|
|
2288
|
-
return Oe(e), e.scrollTrigger && e.scrollTrigger.kill(!!
|
|
2288
|
+
return Oe(e), e.scrollTrigger && e.scrollTrigger.kill(!!Z), e.progress() < 1 && le(e, "onInterrupt"), e;
|
|
2289
2289
|
}, tt, Yr = [], Wr = function(e) {
|
|
2290
2290
|
if (e)
|
|
2291
2291
|
if (e = !e.name && e.default || e, Si() || e.headless) {
|
|
@@ -2354,7 +2354,7 @@ var ce = {
|
|
|
2354
2354
|
r = r.map(Number);
|
|
2355
2355
|
}
|
|
2356
2356
|
return t && !m && (n = r[0] / F, o = r[1] / F, a = r[2] / F, h = Math.max(n, o, a), p = Math.min(n, o, a), c = (h + p) / 2, h === p ? l = u = 0 : (f = h - p, u = c > 0.5 ? f / (2 - h - p) : f / (h + p), l = h === n ? (o - a) / f + (o < a ? 6 : 0) : h === o ? (a - n) / f + 2 : (n - o) / f + 4, l *= 60), r[0] = ~~(l + 0.5), r[1] = ~~(u * 100 + 0.5), r[2] = ~~(c * 100 + 0.5)), i && r.length < 4 && (r[3] = 1), r;
|
|
2357
|
-
},
|
|
2357
|
+
}, qr = function(e) {
|
|
2358
2358
|
var t = [], i = [], r = -1;
|
|
2359
2359
|
return e.split(ke).forEach(function(n) {
|
|
2360
2360
|
var o = n.match(et) || [];
|
|
@@ -2366,7 +2366,7 @@ var ce = {
|
|
|
2366
2366
|
return e;
|
|
2367
2367
|
if (n = n.map(function(p) {
|
|
2368
2368
|
return (p = Xr(p, t, 1)) && o + (t ? p[0] + "," + p[1] + "%," + p[2] + "%," + p[3] : p.join(",")) + ")";
|
|
2369
|
-
}), i && (c =
|
|
2369
|
+
}), i && (c = qr(e), l = i.c, l.join(r) !== c.c.join(r)))
|
|
2370
2370
|
for (u = e.replace(ke, "1").split(et), h = u.length - 1; a < h; a++)
|
|
2371
2371
|
r += u[a] + (~l.indexOf(a) ? n.shift() || o + "0,0,0,0)" : (c.length ? c : n.length ? n : i).shift());
|
|
2372
2372
|
if (!u)
|
|
@@ -2378,10 +2378,10 @@ var ce = {
|
|
|
2378
2378
|
for (e in ft)
|
|
2379
2379
|
s += "|" + e + "\\b";
|
|
2380
2380
|
return new RegExp(s + ")", "gi");
|
|
2381
|
-
})(), io = /hsl[a]?\(/,
|
|
2381
|
+
})(), io = /hsl[a]?\(/, Zr = function(e) {
|
|
2382
2382
|
var t = e.join(" "), i;
|
|
2383
2383
|
if (ke.lastIndex = 0, ke.test(t))
|
|
2384
|
-
return i = io.test(t), e[1] = er(e[1], i), e[0] = er(e[0], i,
|
|
2384
|
+
return i = io.test(t), e[1] = er(e[1], i), e[0] = er(e[0], i, qr(e[1])), !0;
|
|
2385
2385
|
}, Et, se = (function() {
|
|
2386
2386
|
var s = Date.now, e = 500, t = 33, i = s(), r = i, n = 1e3 / 240, o = n, a = [], l, u, c, h, p, f, m = function d(g) {
|
|
2387
2387
|
var b = s() - r, y = g === !0, x, _, v, C;
|
|
@@ -2584,8 +2584,8 @@ var en = function(e, t) {
|
|
|
2584
2584
|
return r ? i && (!this._ts || this._repeat && this._time && this.totalProgress() < 1) ? this._tTime % (this._dur + this._rDelay) : this._ts ? Gt(r.rawTime(i), this) : this._tTime : this._tTime;
|
|
2585
2585
|
}, e.revert = function(i) {
|
|
2586
2586
|
i === void 0 && (i = Un);
|
|
2587
|
-
var r =
|
|
2588
|
-
return
|
|
2587
|
+
var r = Z;
|
|
2588
|
+
return Z = i, Ri(this) && (this.timeline && this.timeline.revert(i), this.totalTime(-0.01, i.suppressEvents)), this.data !== "nested" && i.kill !== !1 && this.kill(), Z = r, this;
|
|
2589
2589
|
}, e.globalTime = function(i) {
|
|
2590
2590
|
for (var r = this, n = arguments.length ? i : r.rawTime(); r; )
|
|
2591
2591
|
n = r._start + n / (Math.abs(r._ts) || 1), r = r._dp;
|
|
@@ -2713,7 +2713,7 @@ var ee = /* @__PURE__ */ (function(s) {
|
|
|
2713
2713
|
if (m = f._prev, (f._act || A <= f._end) && f._ts && y !== f) {
|
|
2714
2714
|
if (f.parent !== this)
|
|
2715
2715
|
return this.render(r, n, o);
|
|
2716
|
-
if (f.render(f._ts > 0 ? (A - f._start) * f._ts : (f._dirty ? f.totalDuration() : f._tDur) + (A - f._start) * f._ts, n, o ||
|
|
2716
|
+
if (f.render(f._ts > 0 ? (A - f._start) * f._ts : (f._dirty ? f.totalDuration() : f._tDur) + (A - f._start) * f._ts, n, o || Z && Ri(f)), p !== this._time || !this._ts && !b) {
|
|
2717
2717
|
y = 0, m && (c += this._zTime = A ? -z : z);
|
|
2718
2718
|
break;
|
|
2719
2719
|
}
|
|
@@ -2834,8 +2834,8 @@ var ee = /* @__PURE__ */ (function(s) {
|
|
|
2834
2834
|
}
|
|
2835
2835
|
return o._tDur;
|
|
2836
2836
|
}, e.updateRoot = function(r) {
|
|
2837
|
-
if (B._ts && (Dr(B, Gt(r, B)), Lr = se.frame), se.frame >=
|
|
2838
|
-
|
|
2837
|
+
if (B._ts && (Dr(B, Gt(r, B)), Lr = se.frame), se.frame >= qi) {
|
|
2838
|
+
qi += ce.autoSleep || 120;
|
|
2839
2839
|
var n = B._first;
|
|
2840
2840
|
if ((!n || !n._ts) && ce.autoSleep && se._listeners.length < 2) {
|
|
2841
2841
|
for (; n && !n._ts; )
|
|
@@ -2852,7 +2852,7 @@ he(ee.prototype, {
|
|
|
2852
2852
|
});
|
|
2853
2853
|
var lo = function(e, t, i, r, n, o, a) {
|
|
2854
2854
|
var l = new re(this._pt, e, t, 0, 1, sn, null, n), u = 0, c = 0, h, p, f, m, d, g, b, y;
|
|
2855
|
-
for (l.b = i, l.e = r, i += "", r += "", (b = ~r.indexOf("random(")) && (r = _t(r)), o && (y = [i, r], o(y, e, t), i = y[0], r = y[1]), p = i.match(
|
|
2855
|
+
for (l.b = i, l.e = r, i += "", r += "", (b = ~r.indexOf("random(")) && (r = _t(r)), o && (y = [i, r], o(y, e, t), i = y[0], r = y[1]), p = i.match(Zt) || []; h = Zt.exec(r); )
|
|
2856
2856
|
m = h[0], d = r.substring(u, h.index), f ? f = (f + 1) % 5 : d.substr(-5) === "rgba(" && (f = 1), m !== p[c++] && (g = parseFloat(p[c - 1]) || 0, l._pt = {
|
|
2857
2857
|
_next: l._pt,
|
|
2858
2858
|
p: d || c === 1 ? d : ",",
|
|
@@ -2860,7 +2860,7 @@ var lo = function(e, t, i, r, n, o, a) {
|
|
|
2860
2860
|
s: g,
|
|
2861
2861
|
c: m.charAt(1) === "=" ? rt(g, m) - g : parseFloat(m) - g,
|
|
2862
2862
|
m: f && f < 4 ? Math.round : 0
|
|
2863
|
-
}, u =
|
|
2863
|
+
}, u = Zt.lastIndex);
|
|
2864
2864
|
return l.c = u < r.length ? r.substring(u, r.length) : "", l.fp = a, (Pr.test(r) || b) && (l.e = 0), this._pt = l, l;
|
|
2865
2865
|
}, ki = function(e, t, i, r, n, o, a, l, u, c) {
|
|
2866
2866
|
G(r) && (r = r(n || 0, e, o));
|
|
@@ -2896,7 +2896,7 @@ var lo = function(e, t, i, r, n, o, a) {
|
|
|
2896
2896
|
return le(e, "onUpdate");
|
|
2897
2897
|
},
|
|
2898
2898
|
stagger: 0
|
|
2899
|
-
}, o))), e._startAt._dp = 0, e._startAt._sat = e, t < 0 && (
|
|
2899
|
+
}, o))), e._startAt._dp = 0, e._startAt._sat = e, t < 0 && (Z || !a && !f) && e._startAt.revert(kt), a && m && t <= 0 && i <= 0) {
|
|
2900
2900
|
t && (e._zTime = t);
|
|
2901
2901
|
return;
|
|
2902
2902
|
}
|
|
@@ -2911,7 +2911,7 @@ var lo = function(e, t, i, r, n, o, a) {
|
|
|
2911
2911
|
stagger: 0,
|
|
2912
2912
|
parent: b
|
|
2913
2913
|
//ensures that nested tweens that had a stagger are handled properly, like gsap.from(".class", {y: gsap.utils.wrap([-100,100]), stagger: 0.5})
|
|
2914
|
-
}, v), k && (w[M.prop] = k), Oe(e._startAt = j.set(g, w)), e._startAt._dp = 0, e._startAt._sat = e, t < 0 && (
|
|
2914
|
+
}, v), k && (w[M.prop] = k), Oe(e._startAt = j.set(g, w)), e._startAt._dp = 0, e._startAt._sat = e, t < 0 && (Z ? e._startAt.revert(kt) : e._startAt.render(-1, !0)), e._zTime = t, !a)
|
|
2915
2915
|
s(e._startAt, z, z);
|
|
2916
2916
|
else if (!t)
|
|
2917
2917
|
return;
|
|
@@ -2939,7 +2939,7 @@ var lo = function(e, t, i, r, n, o, a) {
|
|
|
2939
2939
|
u.push(c);
|
|
2940
2940
|
}
|
|
2941
2941
|
for (f = u.length; f--; )
|
|
2942
|
-
h = u[f], c = h._pt || h, c.s = (r || r === 0) && !n ? r : c.s + (r || 0) + o * c.c, c.c = i - c.s, h.e && (h.e =
|
|
2942
|
+
h = u[f], c = h._pt || h, c.s = (r || r === 0) && !n ? r : c.s + (r || 0) + o * c.c, c.c = i - c.s, h.e && (h.e = H(i) + J(h.e)), h.b && (h.b = c.s + J(h.b));
|
|
2943
2943
|
}, ho = function(e, t) {
|
|
2944
2944
|
var i = e[0] ? Ye(e[0]).harness : 0, r = i && i.aliases, n, o, a, l;
|
|
2945
2945
|
if (!r)
|
|
@@ -3060,7 +3060,7 @@ var j = /* @__PURE__ */ (function(s) {
|
|
|
3060
3060
|
return this._initted || Oi(this, u), c = this._ease(u / this._dur), uo(this, r, n, o, a, c, u, l) ? this.resetTo(r, n, o, a, 1) : (Xt(this, 0), this.parent || Or(this._dp, this, "_first", "_last", this._dp._sort ? "_start" : 0), this.render(0));
|
|
3061
3061
|
}, t.kill = function(r, n) {
|
|
3062
3062
|
if (n === void 0 && (n = "all"), !r && (!n || n === "all"))
|
|
3063
|
-
return this._lazy = this._pt = 0, this.parent ? pt(this) : this.scrollTrigger && this.scrollTrigger.kill(!!
|
|
3063
|
+
return this._lazy = this._pt = 0, this.parent ? pt(this) : this.scrollTrigger && this.scrollTrigger.kill(!!Z), this;
|
|
3064
3064
|
if (this.timeline) {
|
|
3065
3065
|
var o = this.timeline.totalDuration();
|
|
3066
3066
|
return this.timeline.killTweensOf(r, n, Me && Me.vars.overwrite !== !0)._first || pt(this), this.parent && o !== this.timeline.totalDuration() && ct(this, this._dur * this.timeline._tDur / o, 0, 1), this;
|
|
@@ -3180,14 +3180,14 @@ B = new ee({
|
|
|
3180
3180
|
id: "root",
|
|
3181
3181
|
smoothChildTiming: !0
|
|
3182
3182
|
});
|
|
3183
|
-
ce.stringFilter =
|
|
3184
|
-
var
|
|
3183
|
+
ce.stringFilter = Zr;
|
|
3184
|
+
var qe = [], Ft = {}, vo = [], tr = 0, _o = 0, ti = function(e) {
|
|
3185
3185
|
return (Ft[e] || vo).map(function(t) {
|
|
3186
3186
|
return t();
|
|
3187
3187
|
});
|
|
3188
3188
|
}, yi = function() {
|
|
3189
3189
|
var e = Date.now(), t = [];
|
|
3190
|
-
e - tr > 2 && (ti("matchMediaInit"),
|
|
3190
|
+
e - tr > 2 && (ti("matchMediaInit"), qe.forEach(function(i) {
|
|
3191
3191
|
var r = i.queries, n = i.conditions, o, a, l, u;
|
|
3192
3192
|
for (a in r)
|
|
3193
3193
|
o = ye.matchMedia(r[a]).matches, o && (l = 1), o !== n[a] && (n[a] = o, u = 1);
|
|
@@ -3245,8 +3245,8 @@ var Ze = [], Ft = {}, vo = [], tr = 0, _o = 0, ti = function(e) {
|
|
|
3245
3245
|
})() : this.data.forEach(function(a) {
|
|
3246
3246
|
return a.kill && a.kill();
|
|
3247
3247
|
}), this.clear(), r)
|
|
3248
|
-
for (var o =
|
|
3249
|
-
|
|
3248
|
+
for (var o = qe.length; o--; )
|
|
3249
|
+
qe[o].id === this.id && qe.splice(o, 1);
|
|
3250
3250
|
}, e.revert = function(i) {
|
|
3251
3251
|
this.kill(i || {});
|
|
3252
3252
|
}, s;
|
|
@@ -3262,7 +3262,7 @@ var Ze = [], Ft = {}, vo = [], tr = 0, _o = 0, ti = function(e) {
|
|
|
3262
3262
|
var o = new cn(0, n || this.scope), a = o.conditions = {}, l, u, c;
|
|
3263
3263
|
N && !o.selector && (o.selector = N.selector), this.contexts.push(o), r = o.add("onMatch", r), o.queries = i;
|
|
3264
3264
|
for (u in i)
|
|
3265
|
-
u === "all" ? c = 1 : (l = ye.matchMedia(i[u]), l && (
|
|
3265
|
+
u === "all" ? c = 1 : (l = ye.matchMedia(i[u]), l && (qe.indexOf(o) < 0 && qe.push(o), (a[u] = l.matches) && (c = 1), l.addListener ? l.addListener(yi) : l.addEventListener("change", yi)));
|
|
3266
3266
|
return c && r(o, function(h) {
|
|
3267
3267
|
return o.add(null, h);
|
|
3268
3268
|
}), this;
|
|
@@ -3323,10 +3323,10 @@ var Ze = [], Ft = {}, vo = [], tr = 0, _o = 0, ti = function(e) {
|
|
|
3323
3323
|
return B.getTweensOf(e, !0).length > 0;
|
|
3324
3324
|
},
|
|
3325
3325
|
defaults: function(e) {
|
|
3326
|
-
return e && e.ease && (e.ease = Xe(e.ease, at.ease)),
|
|
3326
|
+
return e && e.ease && (e.ease = Xe(e.ease, at.ease)), Zi(at, e || {});
|
|
3327
3327
|
},
|
|
3328
3328
|
config: function(e) {
|
|
3329
|
-
return
|
|
3329
|
+
return Zi(ce, e || {});
|
|
3330
3330
|
},
|
|
3331
3331
|
registerEffect: function(e) {
|
|
3332
3332
|
var t = e.name, i = e.effect, r = e.plugins, n = e.defaults, o = e.extendTimeline;
|
|
@@ -3361,7 +3361,7 @@ var Ze = [], Ft = {}, vo = [], tr = 0, _o = 0, ti = function(e) {
|
|
|
3361
3361
|
return new Eo(e);
|
|
3362
3362
|
},
|
|
3363
3363
|
matchMediaRefresh: function() {
|
|
3364
|
-
return
|
|
3364
|
+
return qe.forEach(function(e) {
|
|
3365
3365
|
var t = e.conditions, i, r;
|
|
3366
3366
|
for (r in t)
|
|
3367
3367
|
t[r] && (t[r] = !1, i = 1);
|
|
@@ -3389,7 +3389,7 @@ var Ze = [], Ft = {}, vo = [], tr = 0, _o = 0, ti = function(e) {
|
|
|
3389
3389
|
toArray: me,
|
|
3390
3390
|
selector: mi,
|
|
3391
3391
|
mapRange: jr,
|
|
3392
|
-
pipe:
|
|
3392
|
+
pipe: Zn,
|
|
3393
3393
|
unitize: Kn,
|
|
3394
3394
|
interpolate: to,
|
|
3395
3395
|
shuffle: Br
|
|
@@ -3409,7 +3409,7 @@ var Ze = [], Ft = {}, vo = [], tr = 0, _o = 0, ti = function(e) {
|
|
|
3409
3409
|
getCache: Ye,
|
|
3410
3410
|
_removeLinkedListItem: Yt,
|
|
3411
3411
|
reverting: function() {
|
|
3412
|
-
return
|
|
3412
|
+
return Z;
|
|
3413
3413
|
},
|
|
3414
3414
|
context: function(e) {
|
|
3415
3415
|
return e && N && (N.data.push(e), e._ctx = N), N;
|
|
@@ -3466,7 +3466,7 @@ var wo = function(e, t) {
|
|
|
3466
3466
|
},
|
|
3467
3467
|
render: function(e, t) {
|
|
3468
3468
|
for (var i = t._pt; i; )
|
|
3469
|
-
|
|
3469
|
+
Z ? i.set(i.t, i.p, i.b, i) : i.r(e, i.d), i = i._next;
|
|
3470
3470
|
}
|
|
3471
3471
|
}, {
|
|
3472
3472
|
name: "endArray",
|
|
@@ -3611,7 +3611,7 @@ var ir, Le, nt, Ni, He, rr, Bi, Po = function() {
|
|
|
3611
3611
|
} : t;
|
|
3612
3612
|
}, gn = function(e) {
|
|
3613
3613
|
return !!(e.getCTM && (!e.parentNode || e.ownerSVGElement) && mn(e));
|
|
3614
|
-
},
|
|
3614
|
+
}, Ze = function(e, t) {
|
|
3615
3615
|
if (t) {
|
|
3616
3616
|
var i = e.style, r;
|
|
3617
3617
|
t in Ae && t !== ne && (t = $), i.removeProperty ? (r = t.substr(0, 2), (r === "ms" || t.substr(0, 6) === "webkit") && (t = "-" + t), i.removeProperty(r === "--" ? t : t.replace($i, "-$1").toLowerCase())) : i.removeAttribute(t);
|
|
@@ -3631,15 +3631,15 @@ var ir, Le, nt, Ni, He, rr, Bi, Po = function() {
|
|
|
3631
3631
|
if (r === o || !n || lr[r] || lr[o])
|
|
3632
3632
|
return n;
|
|
3633
3633
|
if (o !== "px" && !p && (n = s(e, t, i, "px")), b = e.getCTM && gn(e), (f || o === "%") && (Ae[t] || ~t.indexOf("adius")))
|
|
3634
|
-
return m = b ? e.getBBox()[l ? "width" : "height"] : e[c],
|
|
3634
|
+
return m = b ? e.getBBox()[l ? "width" : "height"] : e[c], H(f ? n / m * h : n / 100 * m);
|
|
3635
3635
|
if (a[l ? "width" : "height"] = h + (p ? o : r), d = r !== "rem" && ~t.indexOf("adius") || r === "em" && e.appendChild && !u ? e : e.parentNode, b && (d = (e.ownerSVGElement || {}).parentNode), (!d || d === Le || !d.appendChild) && (d = Le.body), g = d._gsap, g && f && g.width && l && g.time === se.time && !g.uncache)
|
|
3636
|
-
return
|
|
3636
|
+
return H(n / g.width * h);
|
|
3637
3637
|
if (f && (t === "height" || t === "width")) {
|
|
3638
3638
|
var y = e.style[t];
|
|
3639
|
-
e.style[t] = h + r, m = e[c], y ? e.style[t] = y :
|
|
3639
|
+
e.style[t] = h + r, m = e[c], y ? e.style[t] = y : Ze(e, t);
|
|
3640
3640
|
} else
|
|
3641
3641
|
(f || o === "%") && !No[ge(d, "display")] && (a.position = ge(e, "position")), d === e && (a.position = "static"), d.appendChild(He), m = He[c], d.removeChild(He), a.position = "absolute";
|
|
3642
|
-
return l && f && (g = Ye(d), g.time = se.time, g.width = d[c]),
|
|
3642
|
+
return l && f && (g = Ye(d), g.time = se.time, g.width = d[c]), H(p ? m * n / h : m && n ? h / m * n : 0);
|
|
3643
3643
|
}, Te = function(e, t, i, r) {
|
|
3644
3644
|
var n;
|
|
3645
3645
|
return Ni || _i(), t in ve && t !== "transform" && (t = ve[t], ~t.indexOf(",") && (t = t.split(",")[0])), Ae[t] && t !== "transform" ? (n = Pt(e, r), n = t !== "transformOrigin" ? n[t] : n.svg ? n.origin : jt(ge(e, ne)) + " " + n.zOrigin + "px") : (n = e.style[t], (!n || n === "auto" || r || ~(n + "").indexOf("calc(")) && (n = Ht[t] && Ht[t](e, t, i) || ge(e, t) || Ir(e, t) || (t === "opacity" ? 1 : 0))), i && !~(n + "").trim().indexOf(" ") ? Fe(e, t, n, i) + i : n;
|
|
@@ -3649,7 +3649,7 @@ var ir, Le, nt, Ni, He, rr, Bi, Po = function() {
|
|
|
3649
3649
|
o && o !== i ? (t = n, i = o) : t === "borderColor" && (i = ge(e, "borderTopColor"));
|
|
3650
3650
|
}
|
|
3651
3651
|
var a = new re(this._pt, e.style, t, 0, 1, sn), l = 0, u = 0, c, h, p, f, m, d, g, b, y, x, _, v;
|
|
3652
|
-
if (a.b = i, a.e = r, i += "", r += "", r.substring(0, 6) === "var(--" && (r = ge(e, r.substring(4, r.indexOf(")")))), r === "auto" && (d = e.style[t], e.style[t] = r, r = ge(e, t) || r, d ? e.style[t] = d :
|
|
3652
|
+
if (a.b = i, a.e = r, i += "", r += "", r.substring(0, 6) === "var(--" && (r = ge(e, r.substring(4, r.indexOf(")")))), r === "auto" && (d = e.style[t], e.style[t] = r, r = ge(e, t) || r, d ? e.style[t] = d : Ze(e, t)), c = [i, r], Zr(c), i = c[0], r = c[1], p = i.match(et) || [], v = r.match(et) || [], v.length) {
|
|
3653
3653
|
for (; h = et.exec(r); )
|
|
3654
3654
|
g = h[0], y = r.substring(l, h.index), m ? m = (m + 1) % 5 : (y.substr(-5) === "rgba(" || y.substr(-5) === "hsla(") && (m = 1), g !== (d = p[u++] || "") && (f = parseFloat(d) || 0, _ = d.substr((f + "").length), g.charAt(1) === "=" && (g = rt(f, g) + _), b = parseFloat(g), x = g.substr((b + "").length), l = et.lastIndex - x.length, x || (x = x || ce.units[t] || _, l === r.length && (r += x, a.e += x)), _ !== x && (f = Fe(e, t, d, x) || 0), a._pt = {
|
|
3655
3655
|
_next: a._pt,
|
|
@@ -3679,8 +3679,8 @@ var ir, Le, nt, Ni, He, rr, Bi, Po = function() {
|
|
|
3679
3679
|
r.cssText = "", l = 1;
|
|
3680
3680
|
else
|
|
3681
3681
|
for (n = n.split(","), u = n.length; --u > -1; )
|
|
3682
|
-
a = n[u], Ae[a] && (l = 1, a = a === "transformOrigin" ? ne : $),
|
|
3683
|
-
l && (
|
|
3682
|
+
a = n[u], Ae[a] && (l = 1, a = a === "transformOrigin" ? ne : $), Ze(i, a);
|
|
3683
|
+
l && (Ze(i, $), o && (o.svg && i.removeAttribute("transform"), r.scale = r.rotate = r.translate = "none", Pt(i, 1), o.uncache = 1, dn(r)));
|
|
3684
3684
|
}
|
|
3685
3685
|
}, Ht = {
|
|
3686
3686
|
clearProps: function(e, t, i, r, n) {
|
|
@@ -3756,10 +3756,10 @@ var ir, Le, nt, Ni, He, rr, Bi, Po = function() {
|
|
|
3756
3756
|
return e === "matrix(1, 0, 0, 1, 0, 0)" || e === "none" || !e;
|
|
3757
3757
|
}, ur = function(e) {
|
|
3758
3758
|
var t = ge(e, $);
|
|
3759
|
-
return yn(t) ? Ct : t.substr(7).match(Cr).map(
|
|
3759
|
+
return yn(t) ? Ct : t.substr(7).match(Cr).map(H);
|
|
3760
3760
|
}, Gi = function(e, t) {
|
|
3761
3761
|
var i = e._gsap || Ye(e), r = e.style, n = ur(e), o, a, l, u;
|
|
3762
|
-
return i.svg && e.getAttribute("transform") ? (l = e.transform.baseVal.consolidate().matrix, n = [l.a, l.b, l.c, l.d, l.e, l.f], n.join(",") === "1,0,0,1,0,0" ? Ct : n) : (n === Ct && !e.offsetParent && e !== nt && !i.svg && (l = r.display, r.display = "block", o = e.parentNode, (!o || !e.offsetParent && !e.getBoundingClientRect().width) && (u = 1, a = e.nextElementSibling, nt.appendChild(e)), n = ur(e), l ? r.display = l :
|
|
3762
|
+
return i.svg && e.getAttribute("transform") ? (l = e.transform.baseVal.consolidate().matrix, n = [l.a, l.b, l.c, l.d, l.e, l.f], n.join(",") === "1,0,0,1,0,0" ? Ct : n) : (n === Ct && !e.offsetParent && e !== nt && !i.svg && (l = r.display, r.display = "block", o = e.parentNode, (!o || !e.offsetParent && !e.getBoundingClientRect().width) && (u = 1, a = e.nextElementSibling, nt.appendChild(e)), n = ur(e), l ? r.display = l : Ze(e, "display"), u && (a ? o.insertBefore(e, a) : o ? o.appendChild(e) : nt.removeChild(e))), t && n.length > 6 ? [n[0], n[1], n[4], n[5], n[12], n[13]] : n);
|
|
3763
3763
|
}, Ei = function(e, t, i, r, n, o) {
|
|
3764
3764
|
var a = e._gsap, l = n || Gi(e, !0), u = a.xOrigin || 0, c = a.yOrigin || 0, h = a.xOffset || 0, p = a.yOffset || 0, f = l[0], m = l[1], d = l[2], g = l[3], b = l[4], y = l[5], x = t.split(" "), _ = parseFloat(x[0]) || 0, v = parseFloat(x[1]) || 0, C, w, P, E;
|
|
3765
3765
|
i ? l !== Ct && (w = f * g - m * d) && (P = _ * (g / w) + v * (-d / w) + (d * y - g * b) / w, E = _ * (-m / w) + v * (f / w) - (f * y - m * b) / w, _ = P, v = E) : (C = mn(e), _ = C.x + (~x[0].indexOf("%") ? _ / 100 * C.width : _), v = C.y + (~(x[1] || x[0]).indexOf("%") ? v / 100 * C.height : v)), r || r !== !1 && a.smooth ? (b = _ - u, y = v - c, a.xOffset = h + (b * f + y * d) - b, a.yOffset = p + (b * m + y * g) - y) : a.xOffset = a.yOffset = 0, a.xOrigin = _, a.yOrigin = v, a.smooth = !!r, a.origin = t, a.originIsAbsolute = !!i, e.style[ne] = "0px 0px", o && (Ie(o, a, "xOrigin", u, _), Ie(o, a, "yOrigin", c, v), Ie(o, a, "xOffset", h, a.xOffset), Ie(o, a, "yOffset", p, a.yOffset)), e.setAttribute("data-svg-origin", _ + " " + v);
|
|
@@ -3768,12 +3768,12 @@ var ir, Le, nt, Ni, He, rr, Bi, Po = function() {
|
|
|
3768
3768
|
if ("x" in i && !t && !i.uncache)
|
|
3769
3769
|
return i;
|
|
3770
3770
|
var r = e.style, n = i.scaleX < 0, o = "px", a = "deg", l = getComputedStyle(e), u = ge(e, ne) || "0", c, h, p, f, m, d, g, b, y, x, _, v, C, w, P, E, A, L, M, I, R, U, k, O, K, Ue, we, Ne, Ce, At, T, de;
|
|
3771
|
-
return c = h = p = d = g = b = y = x = _ = 0, f = m = 1, i.svg = !!(e.getCTM && gn(e)), l.translate && ((l.translate !== "none" || l.scale !== "none" || l.rotate !== "none") && (r[$] = (l.translate !== "none" ? "translate3d(" + (l.translate + " 0 0").split(" ").slice(0, 3).join(", ") + ") " : "") + (l.rotate !== "none" ? "rotate(" + l.rotate + ") " : "") + (l.scale !== "none" ? "scale(" + l.scale.split(" ").join(",") + ") " : "") + (l[$] !== "none" ? l[$] : "")), r.scale = r.rotate = r.translate = "none"), w = Gi(e, i.svg), i.svg && (i.uncache ? (K = e.getBBox(), u = i.xOrigin - K.x + "px " + (i.yOrigin - K.y) + "px", O = "") : O = !t && e.getAttribute("data-svg-origin"), Ei(e, O || u, !!O || i.originIsAbsolute, i.smooth !== !1, w)), v = i.xOrigin || 0, C = i.yOrigin || 0, w !== Ct && (L = w[0], M = w[1], I = w[2], R = w[3], c = U = w[4], h = k = w[5], w.length === 6 ? (f = Math.sqrt(L * L + M * M), m = Math.sqrt(R * R + I * I), d = L || M ? Je(M, L) * Ve : 0, y = I || R ? Je(I, R) * Ve + d : 0, y && (m *= Math.abs(Math.cos(y * ot))), i.svg && (c -= v - (v * L + C * I), h -= C - (v * M + C * R))) : (de = w[6], At = w[7], we = w[8], Ne = w[9], Ce = w[10], T = w[11], c = w[12], h = w[13], p = w[14], P = Je(de, Ce), g = P * Ve, P && (E = Math.cos(-P), A = Math.sin(-P), O = U * E + we * A, K = k * E + Ne * A, Ue = de * E + Ce * A, we = U * -A + we * E, Ne = k * -A + Ne * E, Ce = de * -A + Ce * E, T = At * -A + T * E, U = O, k = K, de = Ue), P = Je(-I, Ce), b = P * Ve, P && (E = Math.cos(-P), A = Math.sin(-P), O = L * E - we * A, K = M * E - Ne * A, Ue = I * E - Ce * A, T = R * A + T * E, L = O, M = K, I = Ue), P = Je(M, L), d = P * Ve, P && (E = Math.cos(P), A = Math.sin(P), O = L * E + M * A, K = U * E + k * A, M = M * E - L * A, k = k * E - U * A, L = O, U = K), g && Math.abs(g) + Math.abs(d) > 359.9 && (g = d = 0, b = 180 - b), f =
|
|
3771
|
+
return c = h = p = d = g = b = y = x = _ = 0, f = m = 1, i.svg = !!(e.getCTM && gn(e)), l.translate && ((l.translate !== "none" || l.scale !== "none" || l.rotate !== "none") && (r[$] = (l.translate !== "none" ? "translate3d(" + (l.translate + " 0 0").split(" ").slice(0, 3).join(", ") + ") " : "") + (l.rotate !== "none" ? "rotate(" + l.rotate + ") " : "") + (l.scale !== "none" ? "scale(" + l.scale.split(" ").join(",") + ") " : "") + (l[$] !== "none" ? l[$] : "")), r.scale = r.rotate = r.translate = "none"), w = Gi(e, i.svg), i.svg && (i.uncache ? (K = e.getBBox(), u = i.xOrigin - K.x + "px " + (i.yOrigin - K.y) + "px", O = "") : O = !t && e.getAttribute("data-svg-origin"), Ei(e, O || u, !!O || i.originIsAbsolute, i.smooth !== !1, w)), v = i.xOrigin || 0, C = i.yOrigin || 0, w !== Ct && (L = w[0], M = w[1], I = w[2], R = w[3], c = U = w[4], h = k = w[5], w.length === 6 ? (f = Math.sqrt(L * L + M * M), m = Math.sqrt(R * R + I * I), d = L || M ? Je(M, L) * Ve : 0, y = I || R ? Je(I, R) * Ve + d : 0, y && (m *= Math.abs(Math.cos(y * ot))), i.svg && (c -= v - (v * L + C * I), h -= C - (v * M + C * R))) : (de = w[6], At = w[7], we = w[8], Ne = w[9], Ce = w[10], T = w[11], c = w[12], h = w[13], p = w[14], P = Je(de, Ce), g = P * Ve, P && (E = Math.cos(-P), A = Math.sin(-P), O = U * E + we * A, K = k * E + Ne * A, Ue = de * E + Ce * A, we = U * -A + we * E, Ne = k * -A + Ne * E, Ce = de * -A + Ce * E, T = At * -A + T * E, U = O, k = K, de = Ue), P = Je(-I, Ce), b = P * Ve, P && (E = Math.cos(-P), A = Math.sin(-P), O = L * E - we * A, K = M * E - Ne * A, Ue = I * E - Ce * A, T = R * A + T * E, L = O, M = K, I = Ue), P = Je(M, L), d = P * Ve, P && (E = Math.cos(P), A = Math.sin(P), O = L * E + M * A, K = U * E + k * A, M = M * E - L * A, k = k * E - U * A, L = O, U = K), g && Math.abs(g) + Math.abs(d) > 359.9 && (g = d = 0, b = 180 - b), f = H(Math.sqrt(L * L + M * M + I * I)), m = H(Math.sqrt(k * k + de * de)), P = Je(U, k), y = Math.abs(P) > 2e-4 ? P * Ve : 0, _ = T ? 1 / (T < 0 ? -T : T) : 0), i.svg && (O = e.getAttribute("transform"), i.forceCSS = e.setAttribute("transform", "") || !yn(ge(e, $)), O && e.setAttribute("transform", O))), Math.abs(y) > 90 && Math.abs(y) < 270 && (n ? (f *= -1, y += d <= 0 ? 180 : -180, d += d <= 0 ? 180 : -180) : (m *= -1, y += y <= 0 ? 180 : -180)), t = t || i.uncache, i.x = c - ((i.xPercent = c && (!t && i.xPercent || (Math.round(e.offsetWidth / 2) === Math.round(-c) ? -50 : 0))) ? e.offsetWidth * i.xPercent / 100 : 0) + o, i.y = h - ((i.yPercent = h && (!t && i.yPercent || (Math.round(e.offsetHeight / 2) === Math.round(-h) ? -50 : 0))) ? e.offsetHeight * i.yPercent / 100 : 0) + o, i.z = p + o, i.scaleX = H(f), i.scaleY = H(m), i.rotation = H(d) + a, i.rotationX = H(g) + a, i.rotationY = H(b) + a, i.skewX = y + a, i.skewY = x + a, i.transformPerspective = _ + o, (i.zOrigin = parseFloat(u.split(" ")[2]) || !t && i.zOrigin || 0) && (r[ne] = jt(u)), i.xOffset = i.yOffset = 0, i.force3D = ce.force3D, i.renderTransform = i.svg ? Ho : fn ? xn : Vo, i.uncache = 0, i;
|
|
3772
3772
|
}, jt = function(e) {
|
|
3773
3773
|
return (e = e.split(" "))[0] + " " + e[1];
|
|
3774
3774
|
}, ri = function(e, t, i) {
|
|
3775
3775
|
var r = J(t);
|
|
3776
|
-
return
|
|
3776
|
+
return H(parseFloat(t) + parseFloat(Fe(e, "x", i + "px", r))) + r;
|
|
3777
3777
|
}, Vo = function(e, t) {
|
|
3778
3778
|
t.z = "0px", t.rotationY = t.rotationX = "0deg", t.force3D = 0, xn(e, t);
|
|
3779
3779
|
}, $e = "0deg", dt = "0px", Ge = ") ", xn = function(e, t) {
|
|
@@ -3785,7 +3785,7 @@ var ir, Le, nt, Ni, He, rr, Bi, Po = function() {
|
|
|
3785
3785
|
g !== dt && (_ += "perspective(" + g + Ge), (r || n) && (_ += "translate(" + r + "%, " + n + "%) "), (v || o !== dt || a !== dt || l !== dt) && (_ += l !== dt || v ? "translate3d(" + o + ", " + a + ", " + l + ") " : "translate(" + o + ", " + a + Ge), u !== $e && (_ += "rotate(" + u + Ge), c !== $e && (_ += "rotateY(" + c + Ge), h !== $e && (_ += "rotateX(" + h + Ge), (p !== $e || f !== $e) && (_ += "skew(" + p + ", " + f + Ge), (m !== 1 || d !== 1) && (_ += "scale(" + m + ", " + d + Ge), y.style[$] = _ || "translate(0, 0)";
|
|
3786
3786
|
}, Ho = function(e, t) {
|
|
3787
3787
|
var i = t || this, r = i.xPercent, n = i.yPercent, o = i.x, a = i.y, l = i.rotation, u = i.skewX, c = i.skewY, h = i.scaleX, p = i.scaleY, f = i.target, m = i.xOrigin, d = i.yOrigin, g = i.xOffset, b = i.yOffset, y = i.forceCSS, x = parseFloat(o), _ = parseFloat(a), v, C, w, P, E;
|
|
3788
|
-
l = parseFloat(l), u = parseFloat(u), c = parseFloat(c), c && (c = parseFloat(c), u += c, l += c), l || u ? (l *= ot, u *= ot, v = Math.cos(l) * h, C = Math.sin(l) * h, w = Math.sin(l - u) * -p, P = Math.cos(l - u) * p, u && (c *= ot, E = Math.tan(u - c), E = Math.sqrt(1 + E * E), w *= E, P *= E, c && (E = Math.tan(c), E = Math.sqrt(1 + E * E), v *= E, C *= E)), v =
|
|
3788
|
+
l = parseFloat(l), u = parseFloat(u), c = parseFloat(c), c && (c = parseFloat(c), u += c, l += c), l || u ? (l *= ot, u *= ot, v = Math.cos(l) * h, C = Math.sin(l) * h, w = Math.sin(l - u) * -p, P = Math.cos(l - u) * p, u && (c *= ot, E = Math.tan(u - c), E = Math.sqrt(1 + E * E), w *= E, P *= E, c && (E = Math.tan(c), E = Math.sqrt(1 + E * E), v *= E, C *= E)), v = H(v), C = H(C), w = H(w), P = H(P)) : (v = h, P = p, C = w = 0), (x && !~(o + "").indexOf("px") || _ && !~(a + "").indexOf("px")) && (x = Fe(f, "x", o, "px"), _ = Fe(f, "y", a, "px")), (m || d || g || b) && (x = H(x + m - (m * v + d * w) + g), _ = H(_ + d - (m * C + d * P) + b)), (r || n) && (E = f.getBBox(), x = H(x + r / 100 * E.width), _ = H(_ + n / 100 * E.height)), E = "matrix(" + v + "," + C + "," + w + "," + P + "," + x + "," + _ + ")", f.setAttribute("transform", E), y && (f.style[$] = E);
|
|
3789
3789
|
}, jo = function(e, t, i, r, n) {
|
|
3790
3790
|
var o = 360, a = X(n), l = parseFloat(n) * (a && ~n.indexOf("rad") ? Ve : 1), u = l - r, c = r + u + "deg", h, p;
|
|
3791
3791
|
return a && (h = n.split("_")[1], h === "short" && (u %= o, u !== u % (o / 2) && (u += u < 0 ? o : -o)), h === "cw" && u < 0 ? u = (u + o * nr) % o - ~~(u / o) * o : h === "ccw" && u > 0 && (u = (u - o * nr) % o - ~~(u / o) * o)), e._pt = p = new re(e._pt, t, i, r, u, Ao), p.e = c, p.u = "deg", e._props.push(i), p;
|
|
@@ -3795,7 +3795,7 @@ var ir, Le, nt, Ni, He, rr, Bi, Po = function() {
|
|
|
3795
3795
|
return e;
|
|
3796
3796
|
}, Yo = function(e, t, i) {
|
|
3797
3797
|
var r = hr({}, i._gsap), n = "perspective,force3D,transformOrigin,svgOrigin", o = i.style, a, l, u, c, h, p, f, m;
|
|
3798
|
-
r.svg ? (u = i.getAttribute("transform"), i.setAttribute("transform", ""), o[$] = t, a = Pt(i, 1),
|
|
3798
|
+
r.svg ? (u = i.getAttribute("transform"), i.setAttribute("transform", ""), o[$] = t, a = Pt(i, 1), Ze(i, $), i.setAttribute("transform", u)) : (u = getComputedStyle(i)[$], o[$] = t, a = Pt(i, 1), o[$] = u);
|
|
3799
3799
|
for (l in Ae)
|
|
3800
3800
|
u = r[l], c = a[l], u !== c && n.indexOf(l) < 0 && (f = J(u), m = J(c), h = f !== m ? Fe(i, l, u, m) : parseFloat(u), p = parseFloat(c), e._pt = new re(e._pt, a, l, h, p - h, xi), e._pt.u = m || 0, e._props.push(l));
|
|
3801
3801
|
hr(a, r);
|
|
@@ -3883,7 +3883,7 @@ var vn = {
|
|
|
3883
3883
|
return r && r.indexOf(",") < 0 && (t = r), t in Ae && t !== ne && (e._gsap.x || Te(e, "x")) ? i && rr === i ? t === "scale" ? ko : Ro : (rr = i || {}) && (t === "scale" ? Oo : Fo) : e.style && !Ti(e.style[t]) ? Io : ~t.indexOf("-") ? Do : zi(e, t);
|
|
3884
3884
|
},
|
|
3885
3885
|
core: {
|
|
3886
|
-
_removeProperty:
|
|
3886
|
+
_removeProperty: Ze,
|
|
3887
3887
|
_getMatrix: Gi
|
|
3888
3888
|
}
|
|
3889
3889
|
};
|
|
@@ -4156,7 +4156,7 @@ const Xo = {
|
|
|
4156
4156
|
match: (s) => typeof s == "number",
|
|
4157
4157
|
fromHexString: (s) => parseInt(s.substring(1), 16),
|
|
4158
4158
|
toHexString: (s) => "#" + s.toString(16).padStart(6, 0)
|
|
4159
|
-
},
|
|
4159
|
+
}, qo = {
|
|
4160
4160
|
isPrimitive: !1,
|
|
4161
4161
|
match: (s) => Array.isArray(s) || ArrayBuffer.isView(s),
|
|
4162
4162
|
fromHexString(s, e, t = 1) {
|
|
@@ -4168,7 +4168,7 @@ const Xo = {
|
|
|
4168
4168
|
const r = s * i << 16 ^ e * i << 8 ^ t * i << 0;
|
|
4169
4169
|
return Tt.toHexString(r);
|
|
4170
4170
|
}
|
|
4171
|
-
},
|
|
4171
|
+
}, Zo = {
|
|
4172
4172
|
isPrimitive: !1,
|
|
4173
4173
|
match: (s) => Object(s) === s,
|
|
4174
4174
|
fromHexString(s, e, t = 1) {
|
|
@@ -4180,7 +4180,7 @@ const Xo = {
|
|
|
4180
4180
|
const r = s * i << 16 ^ e * i << 8 ^ t * i << 0;
|
|
4181
4181
|
return Tt.toHexString(r);
|
|
4182
4182
|
}
|
|
4183
|
-
}, Ko = [Xo, Tt,
|
|
4183
|
+
}, Ko = [Xo, Tt, qo, Zo];
|
|
4184
4184
|
function Jo(s) {
|
|
4185
4185
|
return Ko.find((e) => e.match(s));
|
|
4186
4186
|
}
|
|
@@ -6970,7 +6970,7 @@ class Ra {
|
|
|
6970
6970
|
this.resizeObserver?.disconnect(), this.element.remove();
|
|
6971
6971
|
}
|
|
6972
6972
|
}
|
|
6973
|
-
const
|
|
6973
|
+
const V = 50, ka = `
|
|
6974
6974
|
uniform float uMorph;
|
|
6975
6975
|
uniform float uTime;
|
|
6976
6976
|
uniform float uParchment;
|
|
@@ -6990,7 +6990,7 @@ varying float vDiscard;
|
|
|
6990
6990
|
varying float vExtrudeAmount;
|
|
6991
6991
|
|
|
6992
6992
|
const float PI = 3.14159265359;
|
|
6993
|
-
const float RADIUS = ${
|
|
6993
|
+
const float RADIUS = ${V.toFixed(1)};
|
|
6994
6994
|
|
|
6995
6995
|
// Hash functions for procedural variation
|
|
6996
6996
|
float hash(vec2 p) {
|
|
@@ -7436,7 +7436,7 @@ varying vec3 vPosition;
|
|
|
7436
7436
|
uniform float uMorph;
|
|
7437
7437
|
|
|
7438
7438
|
const float PI = 3.14159265359;
|
|
7439
|
-
const float RADIUS = ${
|
|
7439
|
+
const float RADIUS = ${V.toFixed(1)};
|
|
7440
7440
|
|
|
7441
7441
|
void main() {
|
|
7442
7442
|
vNormal = normalize(normalMatrix * normal);
|
|
@@ -7510,7 +7510,7 @@ void main() {
|
|
|
7510
7510
|
gl_FragColor = vec4(1.0, 1.0, 1.0, alpha * vOpacity * 0.9 * uOpacity);
|
|
7511
7511
|
}
|
|
7512
7512
|
`, yr = Math.PI / 180;
|
|
7513
|
-
function Ba(s, e, t =
|
|
7513
|
+
function Ba(s, e, t = V) {
|
|
7514
7514
|
const i = (90 - s) * yr, r = (e + 180) * yr;
|
|
7515
7515
|
return new S.Vector3(
|
|
7516
7516
|
-t * Math.sin(i) * Math.cos(r),
|
|
@@ -7519,7 +7519,7 @@ function Ba(s, e, t = H) {
|
|
|
7519
7519
|
);
|
|
7520
7520
|
}
|
|
7521
7521
|
function $a(s, e) {
|
|
7522
|
-
const t = 2 * Math.PI *
|
|
7522
|
+
const t = 2 * Math.PI * V, i = Math.PI * V;
|
|
7523
7523
|
return new S.Vector3(e / 180 * (t / 2), s / 90 * (i / 2), 0);
|
|
7524
7524
|
}
|
|
7525
7525
|
const Ga = {
|
|
@@ -7667,7 +7667,7 @@ class Va {
|
|
|
7667
7667
|
*/
|
|
7668
7668
|
updatePositions() {
|
|
7669
7669
|
for (let e = 0; e < this.markerMeshes.length; e++) {
|
|
7670
|
-
const t = this.markerMeshes[e], i = t.userData.marker, r = t.userData.height, n = Ba(i.lat, i.lng,
|
|
7670
|
+
const t = this.markerMeshes[e], i = t.userData.marker, r = t.userData.height, n = Ba(i.lat, i.lng, V), o = $a(i.lat, i.lng), a = this.morph * this.morph * (3 - 2 * this.morph);
|
|
7671
7671
|
if (t.position.lerpVectors(o, n, a), a > 0.01) {
|
|
7672
7672
|
if (t.lookAt(t.position.clone().multiplyScalar(2)), this.config.style === "spike" || this.config.style === "pin") {
|
|
7673
7673
|
t.rotateX(Math.PI / 2);
|
|
@@ -7987,7 +7987,7 @@ const Ci = {
|
|
|
7987
7987
|
height: 4096
|
|
7988
7988
|
}
|
|
7989
7989
|
}, ja = Object.keys(Ci), Ya = "https://raw.githubusercontent.com/nvkelso/natural-earth-vector/master/geojson/ne_10m_urban_areas.geojson";
|
|
7990
|
-
class
|
|
7990
|
+
class q {
|
|
7991
7991
|
static urbanFeatures = null;
|
|
7992
7992
|
static isLoading = !1;
|
|
7993
7993
|
static loadPromise = null;
|
|
@@ -7995,18 +7995,18 @@ class Z {
|
|
|
7995
7995
|
* Load the base urban areas topology
|
|
7996
7996
|
*/
|
|
7997
7997
|
static async loadBaseTopology() {
|
|
7998
|
-
return
|
|
7998
|
+
return q.urbanFeatures ? q.urbanFeatures : (q.loadPromise || (q.isLoading = !0, q.loadPromise = (async () => {
|
|
7999
7999
|
try {
|
|
8000
8000
|
const e = await fetch(Ya);
|
|
8001
8001
|
if (!e.ok) throw new Error("Failed to load urban areas");
|
|
8002
8002
|
const t = await e.json();
|
|
8003
|
-
return
|
|
8003
|
+
return q.urbanFeatures = t.features, q.urbanFeatures || [];
|
|
8004
8004
|
} catch (e) {
|
|
8005
8005
|
return console.error("UrbanMapper load error:", e), [];
|
|
8006
8006
|
} finally {
|
|
8007
|
-
|
|
8007
|
+
q.isLoading = !1;
|
|
8008
8008
|
}
|
|
8009
|
-
})()),
|
|
8009
|
+
})()), q.loadPromise);
|
|
8010
8010
|
}
|
|
8011
8011
|
/**
|
|
8012
8012
|
* Generate a synthetic circular polygon (approximate) for a point
|
|
@@ -8043,12 +8043,12 @@ class Z {
|
|
|
8043
8043
|
"forceSynthetic:",
|
|
8044
8044
|
i
|
|
8045
8045
|
);
|
|
8046
|
-
const r = i ? [] : await
|
|
8046
|
+
const r = i ? [] : await q.loadBaseTopology(), n = [], o = {}, a = /* @__PURE__ */ new Set();
|
|
8047
8047
|
for (const l of e) {
|
|
8048
8048
|
let u = null;
|
|
8049
8049
|
if (!i) {
|
|
8050
8050
|
for (const c of r)
|
|
8051
|
-
if (
|
|
8051
|
+
if (q.isPointInFeature(l, c)) {
|
|
8052
8052
|
u = c;
|
|
8053
8053
|
break;
|
|
8054
8054
|
}
|
|
@@ -8057,7 +8057,7 @@ class Z {
|
|
|
8057
8057
|
const c = u.properties.name_conve || u.properties.name || `ua_${Math.random()}`, h = a.has(c) ? null : JSON.parse(JSON.stringify(u));
|
|
8058
8058
|
h && (h.id = c, l.name ? h.properties.name = l.name : h.properties.name || (h.properties.name = c), n.push(h), a.add(c)), o[c] = (o[c] || 0) + l.value;
|
|
8059
8059
|
} else {
|
|
8060
|
-
const c =
|
|
8060
|
+
const c = q.generateSyntheticBoundary(l.lat, l.lon, t);
|
|
8061
8061
|
l.id && (c.id = l.id), l.name && (c.properties.name = l.name), n.push(c), o[c.id] = l.value;
|
|
8062
8062
|
}
|
|
8063
8063
|
}
|
|
@@ -8072,10 +8072,10 @@ class Z {
|
|
|
8072
8072
|
if (!n) return !1;
|
|
8073
8073
|
const o = n.coordinates;
|
|
8074
8074
|
if (n.type === "Polygon")
|
|
8075
|
-
return
|
|
8075
|
+
return q.pointInPolygon([r, i], o);
|
|
8076
8076
|
if (n.type === "MultiPolygon") {
|
|
8077
8077
|
for (const a of o)
|
|
8078
|
-
if (
|
|
8078
|
+
if (q.pointInPolygon([r, i], a)) return !0;
|
|
8079
8079
|
}
|
|
8080
8080
|
return !1;
|
|
8081
8081
|
}
|
|
@@ -8127,7 +8127,7 @@ const si = {
|
|
|
8127
8127
|
pointRadius: 140,
|
|
8128
8128
|
enableShortcuts: !0
|
|
8129
8129
|
};
|
|
8130
|
-
class
|
|
8130
|
+
class Za {
|
|
8131
8131
|
container;
|
|
8132
8132
|
config;
|
|
8133
8133
|
// Three.js core
|
|
@@ -8206,7 +8206,7 @@ class qa {
|
|
|
8206
8206
|
duration: 1
|
|
8207
8207
|
}));
|
|
8208
8208
|
}
|
|
8209
|
-
), this.config.showLegend && (this.legend = new Ra(this.container)), await this.createGlobe(), this.createStars(), this.config.effects.atmosphere && this.createAtmosphere(), this.countryLabels = new da(this.container,
|
|
8209
|
+
), this.config.showLegend && (this.legend = new Ra(this.container)), await this.createGlobe(), this.createStars(), this.config.effects.atmosphere && this.createAtmosphere(), this.countryLabels = new da(this.container, V), this.scene.add(this.countryLabels.getGroup()), this.globe && this.countryLabels.setGlobe(this.globe), this.countryLabels.setCamera(this.camera), this.countryLabels.setStyle(this.config.labels), this.exporter = new Ia(this.renderer, this.scene, this.camera), this.legend && this.exporter.setLegendElement(this.legend.getElement()), this.countryLabels && this.exporter.setCountryLabels(this.countryLabels), (this.config.showControls || this.config.showDebug) && this.createGUI(), this.setupInteraction(), await this.choropleth.waitForLoad();
|
|
8210
8210
|
const i = this.choropleth.getFeatureLabels();
|
|
8211
8211
|
i.length > 0 && this.addCustomLabels(i), this.setStatistic(this.config.statistic), this.morph = this.config.initialView === "globe" ? 1 : 0, this.material && (this.material.uniforms.uMorph.value = this.morph), this.countryLabels?.setMorph(this.morph), window.addEventListener("resize", this.handleResize), this.resizeObserver = new ResizeObserver((r) => {
|
|
8212
8212
|
if (!this.isDestroyed)
|
|
@@ -8243,8 +8243,8 @@ class qa {
|
|
|
8243
8243
|
const r = document.createElement("canvas");
|
|
8244
8244
|
r.width = 2048, r.height = 1024, this.dataTexture = new S.CanvasTexture(r);
|
|
8245
8245
|
const n = new S.PlaneGeometry(
|
|
8246
|
-
Math.PI * 2 *
|
|
8247
|
-
Math.PI *
|
|
8246
|
+
Math.PI * 2 * V,
|
|
8247
|
+
Math.PI * V,
|
|
8248
8248
|
256,
|
|
8249
8249
|
128
|
|
8250
8250
|
);
|
|
@@ -8297,8 +8297,8 @@ class qa {
|
|
|
8297
8297
|
}
|
|
8298
8298
|
createAtmosphere() {
|
|
8299
8299
|
const e = new S.PlaneGeometry(
|
|
8300
|
-
Math.PI * 2 *
|
|
8301
|
-
Math.PI *
|
|
8300
|
+
Math.PI * 2 * V * 1.15,
|
|
8301
|
+
Math.PI * V * 1.15,
|
|
8302
8302
|
128,
|
|
8303
8303
|
64
|
|
8304
8304
|
), t = new S.ShaderMaterial({
|
|
@@ -8789,7 +8789,7 @@ class qa {
|
|
|
8789
8789
|
}), this.toolbar?.updateProjectionIcon(!0);
|
|
8790
8790
|
}
|
|
8791
8791
|
toFlat() {
|
|
8792
|
-
const e = this.choropleth?.getBounds(), t = Math.PI * 2 *
|
|
8792
|
+
const e = this.choropleth?.getBounds(), t = Math.PI * 2 * V, i = Math.PI * V;
|
|
8793
8793
|
let r = 0, n = 0, o = t, a = i;
|
|
8794
8794
|
if (e) {
|
|
8795
8795
|
const [f, m, d, g] = e, b = f / 180 * (t / 2), y = d / 180 * (t / 2), x = m / 90 * (i / 2), _ = g / 90 * (i / 2);
|
|
@@ -8864,7 +8864,7 @@ class qa {
|
|
|
8864
8864
|
if (n && (/* @__PURE__ */ new Date()).getTime() - o > 200) return;
|
|
8865
8865
|
const l = this.renderer.domElement.getBoundingClientRect();
|
|
8866
8866
|
if (t.x = (a.clientX - l.left) / l.width * 2 - 1, t.y = -((a.clientY - l.top) / l.height) * 2 + 1, this.morph < 0.1 && (e.setFromCamera(t, this.camera), e.ray.intersectPlane(i, r), r)) {
|
|
8867
|
-
const u = Math.PI *
|
|
8867
|
+
const u = Math.PI * V, c = Math.PI * V / 2;
|
|
8868
8868
|
Math.abs(r.x) <= u && Math.abs(r.y) <= c && (W.to(this.controls.target, {
|
|
8869
8869
|
x: r.x,
|
|
8870
8870
|
y: r.y,
|
|
@@ -8925,16 +8925,21 @@ class qa {
|
|
|
8925
8925
|
let h = null, p = null;
|
|
8926
8926
|
if (this.morph < 0.5) {
|
|
8927
8927
|
if (t.setFromCamera(i, this.camera), t.ray.intersectPlane(r, n), n) {
|
|
8928
|
-
const f = Math.PI *
|
|
8929
|
-
Math.abs(n.x) <= f && Math.abs(n.y) <= m && (p = n.x / (Math.PI *
|
|
8928
|
+
const f = Math.PI * V, m = Math.PI * V / 2;
|
|
8929
|
+
Math.abs(n.x) <= f && Math.abs(n.y) <= m && (p = n.x / (Math.PI * V) * 180, h = n.y / (Math.PI * V / 2) * 90);
|
|
8930
8930
|
}
|
|
8931
|
-
} else
|
|
8932
|
-
|
|
8933
|
-
|
|
8934
|
-
|
|
8935
|
-
|
|
8936
|
-
|
|
8937
|
-
|
|
8931
|
+
} else {
|
|
8932
|
+
t.setFromCamera(i, this.camera);
|
|
8933
|
+
const f = this.raySphereIntersection(
|
|
8934
|
+
t.ray.origin,
|
|
8935
|
+
t.ray.direction,
|
|
8936
|
+
V
|
|
8937
|
+
);
|
|
8938
|
+
if (f && this.globe) {
|
|
8939
|
+
const m = new S.Quaternion();
|
|
8940
|
+
this.globe.getWorldQuaternion(m), m.invert();
|
|
8941
|
+
const d = f.clone().applyQuaternion(m), g = V;
|
|
8942
|
+
h = Math.asin(d.y / g) * (180 / Math.PI), p = Math.atan2(d.x, d.z) * (180 / Math.PI);
|
|
8938
8943
|
}
|
|
8939
8944
|
}
|
|
8940
8945
|
if (h !== null && p !== null) {
|
|
@@ -8948,6 +8953,28 @@ class qa {
|
|
|
8948
8953
|
} else
|
|
8949
8954
|
this.hideHoverTooltip(), this.currentHoveredFeature !== null && (this.currentHoveredFeature = null, this.config.onHover?.(null, null));
|
|
8950
8955
|
}
|
|
8956
|
+
/**
|
|
8957
|
+
* Mathematical ray-sphere intersection
|
|
8958
|
+
* Returns the closest intersection point on the front face of the sphere,
|
|
8959
|
+
* or null if the ray doesn't hit the sphere.
|
|
8960
|
+
*
|
|
8961
|
+
* This is necessary because the globe mesh is a PlaneGeometry that's morphed
|
|
8962
|
+
* to a sphere via GPU shaders - raycasting against the mesh would hit the
|
|
8963
|
+
* original plane geometry, not the visual sphere.
|
|
8964
|
+
*
|
|
8965
|
+
* @param rayOrigin - Ray origin point
|
|
8966
|
+
* @param rayDirection - Normalized ray direction vector
|
|
8967
|
+
* @param radius - Sphere radius (centered at origin)
|
|
8968
|
+
* @returns Intersection point or null
|
|
8969
|
+
*/
|
|
8970
|
+
raySphereIntersection(e, t, i) {
|
|
8971
|
+
const r = t.dot(t), n = 2 * e.dot(t), o = e.dot(e) - i * i, a = n * n - 4 * r * o;
|
|
8972
|
+
if (a < 0)
|
|
8973
|
+
return null;
|
|
8974
|
+
const l = Math.sqrt(a), u = (-n - l) / (2 * r), c = (-n + l) / (2 * r);
|
|
8975
|
+
let h = null;
|
|
8976
|
+
return u > 1e-3 ? h = u : c > 1e-3 && (h = c), h === null ? null : e.clone().add(t.clone().multiplyScalar(h));
|
|
8977
|
+
}
|
|
8951
8978
|
/**
|
|
8952
8979
|
* Find feature at given lat/lon using point-in-polygon test
|
|
8953
8980
|
*/
|
|
@@ -9141,7 +9168,7 @@ class qa {
|
|
|
9141
9168
|
async setUrbanData(e) {
|
|
9142
9169
|
if (!this.choropleth) return;
|
|
9143
9170
|
this.urbanPoints = e;
|
|
9144
|
-
const t = this.config.pointRadius || 140, i = await
|
|
9171
|
+
const t = this.config.pointRadius || 140, i = await q.mapPointsToTopology(e, t, !0);
|
|
9145
9172
|
this.choropleth.setFeatures(i.features), this.clearCustomLabels();
|
|
9146
9173
|
const r = this.choropleth.getFeatureLabels();
|
|
9147
9174
|
if (r.length > 0) {
|
|
@@ -9194,7 +9221,7 @@ class qa {
|
|
|
9194
9221
|
}
|
|
9195
9222
|
return this.currentValues;
|
|
9196
9223
|
}
|
|
9197
|
-
const e =
|
|
9224
|
+
const e = qt.find((t) => t.id === this.currentStatistic);
|
|
9198
9225
|
if (e) {
|
|
9199
9226
|
const t = {}, i = this.choropleth?.getStatsMap();
|
|
9200
9227
|
return i && i.size > 0 ? i.forEach((n, o) => {
|
|
@@ -9288,7 +9315,7 @@ class qa {
|
|
|
9288
9315
|
}
|
|
9289
9316
|
getStatisticMetadata(e) {
|
|
9290
9317
|
if (Ut[e]) {
|
|
9291
|
-
const i = Ut[e], r =
|
|
9318
|
+
const i = Ut[e], r = qt.find((o) => o.id === e), n = {};
|
|
9292
9319
|
return r && Qe.forEach((o) => {
|
|
9293
9320
|
const a = r.accessor(o);
|
|
9294
9321
|
a != null && (n[o.id] = a);
|
|
@@ -9297,7 +9324,7 @@ class qa {
|
|
|
9297
9324
|
values: n
|
|
9298
9325
|
};
|
|
9299
9326
|
}
|
|
9300
|
-
const t =
|
|
9327
|
+
const t = qt.find((i) => i.id === e);
|
|
9301
9328
|
if (t) {
|
|
9302
9329
|
const i = {};
|
|
9303
9330
|
return Qe.forEach((r) => {
|
|
@@ -9321,10 +9348,10 @@ class qa {
|
|
|
9321
9348
|
}
|
|
9322
9349
|
export {
|
|
9323
9350
|
Ut as BUILT_IN_STATISTICS,
|
|
9324
|
-
|
|
9351
|
+
Za as GlobeViz,
|
|
9325
9352
|
Qe as WORLD_STATISTICS,
|
|
9326
9353
|
vr as createFormatter,
|
|
9327
|
-
|
|
9354
|
+
qa as formatValue,
|
|
9328
9355
|
Ln as normalizeCountryValues,
|
|
9329
9356
|
Wi as toNumericCode
|
|
9330
9357
|
};
|