@luna-park/plugin-motion 1.2.0 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +13 -4
- package/dist/index.js +185 -131
- package/dist/{runtime-_rbH5H1J.js → runtime-cHamDyz2.js} +977 -705
- package/dist/runtime.js +1 -1
- package/package.json +3 -3
|
@@ -41,7 +41,7 @@ var a = typeof window < "u", o = a ? window : null, s = a ? document : null, c =
|
|
|
41
41
|
], C = /*#__PURE__*/ S.reduce((e, t) => ({
|
|
42
42
|
...e,
|
|
43
43
|
[t]: t + "("
|
|
44
|
-
}), {}), w = () => {}, T = (e) => e, E = /\)\s*[-.\d]/, D = /(^#([\da-f]{3}){1,2}$)|(^#([\da-f]{4}){1,2}$)/i, O = /rgb\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*\)/i, ee = /rgba\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*,\s*(-?\d+|-?\d*.\d+)\s*\)/i, k = /hsl\(\s*(-?\d+|-?\d*.\d+)\s*,\s*(-?\d+|-?\d*.\d+)%\s*,\s*(-?\d+|-?\d*.\d+)%\s*\)/i, te = /hsla\(\s*(-?\d+|-?\d*.\d+)\s*,\s*(-?\d+|-?\d*.\d+)%\s*,\s*(-?\d+|-?\d*.\d+)%\s*,\s*(-?\d+|-?\d*.\d+)\s*\)/i, ne = /[-+]?\d*\.?\d+(?:e[-+]?\d)?/gi,
|
|
44
|
+
}), {}), w = () => {}, T = (e) => e, E = /\)\s*[-.\d]/, D = /(^#([\da-f]{3}){1,2}$)|(^#([\da-f]{4}){1,2}$)/i, O = /rgb\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*\)/i, ee = /rgba\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*,\s*(-?\d+|-?\d*.\d+)\s*\)/i, k = /hsl\(\s*(-?\d+|-?\d*.\d+)\s*,\s*(-?\d+|-?\d*.\d+)%\s*,\s*(-?\d+|-?\d*.\d+)%\s*\)/i, te = /hsla\(\s*(-?\d+|-?\d*.\d+)\s*,\s*(-?\d+|-?\d*.\d+)%\s*,\s*(-?\d+|-?\d*.\d+)%\s*,\s*(-?\d+|-?\d*.\d+)\s*\)/i, ne = /[-+]?\d*\.?\d+(?:e[-+]?\d)?/gi, re = /^([-+]?\d*\.?\d+(?:e[-+]?\d+)?)([a-z]+|%)$/i, A = /([a-z])([A-Z])/g, j = /(\*=|\+=|-=)/, M = /var\(\s*(--[\w-]+)(?:\s*,\s*([^)]+))?\s*\)/, N = {
|
|
45
45
|
id: null,
|
|
46
46
|
keyframes: null,
|
|
47
47
|
playbackEase: null,
|
|
@@ -65,29 +65,29 @@ var a = typeof window < "u", o = a ? window : null, s = a ? document : null, c =
|
|
|
65
65
|
onPause: w,
|
|
66
66
|
onComplete: w,
|
|
67
67
|
onRender: w
|
|
68
|
-
},
|
|
68
|
+
}, P = {
|
|
69
69
|
current: null,
|
|
70
70
|
root: s
|
|
71
|
-
},
|
|
72
|
-
defaults:
|
|
71
|
+
}, F = {
|
|
72
|
+
defaults: N,
|
|
73
73
|
precision: 4,
|
|
74
74
|
timeScale: 1,
|
|
75
75
|
tickThreshold: 200,
|
|
76
76
|
editor: null
|
|
77
|
-
},
|
|
77
|
+
}, ie = {
|
|
78
78
|
version: "4.5.0",
|
|
79
79
|
engine: null
|
|
80
80
|
};
|
|
81
|
-
a && (o.AnimeJS ||= [], o.AnimeJS.push(
|
|
81
|
+
a && (o.AnimeJS ||= [], o.AnimeJS.push(ie));
|
|
82
82
|
//#endregion
|
|
83
83
|
//#region node_modules/.pnpm/animejs@4.5.0/node_modules/animejs/dist/modules/core/helpers.js
|
|
84
|
-
var
|
|
84
|
+
var ae = (e) => e.replace(A, "$1-$2").toLowerCase(), I = (e, t) => e.indexOf(t) === 0, oe = Date.now, se = Array.isArray, ce = (e) => e && e.constructor === Object, L = (e) => typeof e == "number" && !isNaN(e), R = (e) => typeof e == "string", z = (e) => typeof e == "function", B = (e) => e === void 0, le = (e) => B(e) || e === null, ue = (e) => a && e instanceof SVGElement, de = (e) => D.test(e), fe = (e) => I(e, "rgb"), pe = (e) => I(e, "hsl"), V = (e) => de(e) || (fe(e) || pe(e)) && (e[e.length - 1] === ")" || !E.test(e)), me = (e) => !F.defaults.hasOwnProperty(e), he = [
|
|
85
85
|
"opacity",
|
|
86
86
|
"rotate",
|
|
87
87
|
"overflow",
|
|
88
88
|
"color"
|
|
89
|
-
],
|
|
90
|
-
if (
|
|
89
|
+
], ge = (e, t) => {
|
|
90
|
+
if (he.includes(t)) return !1;
|
|
91
91
|
if (e.getAttribute(t) || t in e) {
|
|
92
92
|
if (t === "scale") {
|
|
93
93
|
let t = e.parentNode;
|
|
@@ -95,33 +95,33 @@ var ie = (e) => e.replace(j, "$1-$2").toLowerCase(), L = (e, t) => e.indexOf(t)
|
|
|
95
95
|
}
|
|
96
96
|
return !0;
|
|
97
97
|
}
|
|
98
|
-
},
|
|
98
|
+
}, _e = (e) => R(e) ? parseFloat(e) : e, ve = Math.pow, ye = Math.sqrt, H = Math.sin, be = Math.cos, xe = Math.abs, Se = Math.ceil, Ce = Math.floor, we = Math.asin, Te = Math.PI, Ee = Math.round, U = (e, t, n) => e < t ? t : e > n ? n : e, W = (e, t) => {
|
|
99
99
|
if (t < 0) return e;
|
|
100
|
-
if (!t) return
|
|
100
|
+
if (!t) return Ee(e);
|
|
101
101
|
let n = 10 ** t;
|
|
102
|
-
return
|
|
103
|
-
},
|
|
102
|
+
return Ee(e * n) / n;
|
|
103
|
+
}, De = (e, t, n) => n === 1 ? t : n === 0 ? e : e + (t - e) * n, Oe = (e) => e === Infinity ? v : e === -Infinity ? -v : e, ke = (e) => e <= 1e-11 ? _ : Oe(W(e, 11)), G = (e) => se(e) ? [...e] : e, Ae = (e, t) => {
|
|
104
104
|
let n = { ...e };
|
|
105
105
|
for (let r in t) {
|
|
106
106
|
let i = e[r];
|
|
107
|
-
n[r] =
|
|
107
|
+
n[r] = B(i) ? t[r] : i;
|
|
108
108
|
}
|
|
109
109
|
return n;
|
|
110
|
-
},
|
|
110
|
+
}, K = (e, t, n, r = "_prev", i = "_next") => {
|
|
111
111
|
let a = e._head, o = i;
|
|
112
112
|
for (n && (a = e._tail, o = r); a;) {
|
|
113
113
|
let e = a[o];
|
|
114
114
|
t(a), a = e;
|
|
115
115
|
}
|
|
116
|
-
},
|
|
116
|
+
}, je = (e, t, n = "_prev", r = "_next") => {
|
|
117
117
|
let i = t[n], a = t[r];
|
|
118
118
|
i ? i[r] = a : e._head = a, a ? a[n] = i : e._tail = i, t[n] = null, t[r] = null;
|
|
119
|
-
},
|
|
119
|
+
}, Me = (e, t, n, r = "_prev", i = "_next") => {
|
|
120
120
|
let a = e._tail;
|
|
121
121
|
for (; a && n && n(a, t);) a = a[r];
|
|
122
122
|
let o = a ? a[i] : e._head;
|
|
123
123
|
a ? a[i] = t : e._head = t, o ? o[r] = t : e._tail = t, t[r] = a, t[i] = o;
|
|
124
|
-
},
|
|
124
|
+
}, Ne = (e, t, n) => {
|
|
125
125
|
let r = e.style.transform;
|
|
126
126
|
if (r) {
|
|
127
127
|
let i = e[h], a = 0, o = r.length, s;
|
|
@@ -141,10 +141,10 @@ var ie = (e) => e.replace(j, "$1-$2").toLowerCase(), L = (e, t) => e.indexOf(t)
|
|
|
141
141
|
}
|
|
142
142
|
if (t === "translate3d" && s) return n && (n[t] = s), s;
|
|
143
143
|
let c = i[t];
|
|
144
|
-
if (!
|
|
144
|
+
if (!B(c)) return n && (n[t] = c), c;
|
|
145
145
|
}
|
|
146
|
-
return t === "translate3d" ? "0px, 0px, 0px" : t === "rotate3d" ? "0, 0, 0, 0deg" :
|
|
147
|
-
},
|
|
146
|
+
return t === "translate3d" ? "0px, 0px, 0px" : t === "rotate3d" ? "0, 0, 0, 0deg" : I(t, "scale") ? "1" : I(t, "rotate") || I(t, "skew") ? "0deg" : "0px";
|
|
147
|
+
}, Pe = (e) => {
|
|
148
148
|
let t = "";
|
|
149
149
|
for (let n = 0, r = S.length; n < r; n++) {
|
|
150
150
|
let r = S[n], i = e[r];
|
|
@@ -170,12 +170,12 @@ var ie = (e) => e.replace(j, "$1-$2").toLowerCase(), L = (e, t) => e.indexOf(t)
|
|
|
170
170
|
r === "rotateZ" && e.rotate3d !== void 0 && (t += `rotate3d(${e.rotate3d}) `);
|
|
171
171
|
}
|
|
172
172
|
return e.matrix !== void 0 && (t += `matrix(${e.matrix}) `), e.matrix3d !== void 0 && (t += `matrix3d(${e.matrix3d}) `), t;
|
|
173
|
-
},
|
|
174
|
-
function
|
|
173
|
+
}, Fe = [];
|
|
174
|
+
function Ie(e, t) {
|
|
175
175
|
if (!e) return null;
|
|
176
|
-
let n =
|
|
176
|
+
let n = Fe.length;
|
|
177
177
|
outer: for (let r = 0; r < n; r++) {
|
|
178
|
-
let n =
|
|
178
|
+
let n = Fe[r];
|
|
179
179
|
if (n.detect && !n.detect(e)) continue;
|
|
180
180
|
let i = n.targetAdapters;
|
|
181
181
|
for (let n = 0, r = i.length; n < r; n++) {
|
|
@@ -188,7 +188,7 @@ function Pe(e, t) {
|
|
|
188
188
|
}
|
|
189
189
|
}
|
|
190
190
|
for (let r = 0; r < n; r++) {
|
|
191
|
-
let n =
|
|
191
|
+
let n = Fe[r];
|
|
192
192
|
if (n.detect && !n.detect(e)) continue;
|
|
193
193
|
let i = n.propertyResolvers;
|
|
194
194
|
for (let n = 0, r = i.length; n < r; n++) {
|
|
@@ -200,15 +200,15 @@ function Pe(e, t) {
|
|
|
200
200
|
}
|
|
201
201
|
//#endregion
|
|
202
202
|
//#region node_modules/.pnpm/animejs@4.5.0/node_modules/animejs/dist/modules/core/colors.js
|
|
203
|
-
var
|
|
204
|
-
let t = O.exec(e) || ee.exec(e), n =
|
|
203
|
+
var Le = (e) => {
|
|
204
|
+
let t = O.exec(e) || ee.exec(e), n = B(t[4]) ? 1 : +t[4];
|
|
205
205
|
return [
|
|
206
206
|
+t[1],
|
|
207
207
|
+t[2],
|
|
208
208
|
+t[3],
|
|
209
209
|
n
|
|
210
210
|
];
|
|
211
|
-
},
|
|
211
|
+
}, Re = (e) => {
|
|
212
212
|
let t = e.length, n = t === 4 || t === 5;
|
|
213
213
|
return [
|
|
214
214
|
+("0x" + e[1] + e[n ? 1 : 2]),
|
|
@@ -216,12 +216,12 @@ var Fe = (e) => {
|
|
|
216
216
|
+("0x" + e[n ? 3 : 5] + e[n ? 3 : 6]),
|
|
217
217
|
t === 5 || t === 9 ? +(("0x" + e[n ? 4 : 7] + e[n ? 4 : 8]) / 255).toFixed(3) : 1
|
|
218
218
|
];
|
|
219
|
-
},
|
|
220
|
-
let t = k.exec(e) || te.exec(e), n = t[1] / 360, r = t[2] / 100, i = t[3] / 100, a =
|
|
219
|
+
}, ze = (e, t, n) => (n < 0 && (n += 1), n > 1 && --n, n < 1 / 6 ? e + (t - e) * 6 * n : n < 1 / 2 ? t : n < 2 / 3 ? e + (t - e) * (2 / 3 - n) * 6 : e), Be = (e) => {
|
|
220
|
+
let t = k.exec(e) || te.exec(e), n = t[1] / 360, r = t[2] / 100, i = t[3] / 100, a = B(t[4]) ? 1 : +t[4], o, s, c;
|
|
221
221
|
if (r === 0) o = s = c = i;
|
|
222
222
|
else {
|
|
223
223
|
let e = i < .5 ? i * (1 + r) : i + r - i * r, t = 2 * i - e;
|
|
224
|
-
o =
|
|
224
|
+
o = W(ze(t, e, n + 1 / 3) * 255, 0), s = W(ze(t, e, n) * 255, 0), c = W(ze(t, e, n - 1 / 3) * 255, 0);
|
|
225
225
|
}
|
|
226
226
|
return [
|
|
227
227
|
o,
|
|
@@ -229,16 +229,16 @@ var Fe = (e) => {
|
|
|
229
229
|
c,
|
|
230
230
|
a
|
|
231
231
|
];
|
|
232
|
-
},
|
|
232
|
+
}, Ve = (e) => fe(e) ? Le(e) : de(e) ? Re(e) : pe(e) ? Be(e) : [
|
|
233
233
|
0,
|
|
234
234
|
0,
|
|
235
235
|
0,
|
|
236
236
|
1
|
|
237
|
-
],
|
|
238
|
-
let n = e.match(
|
|
237
|
+
], q = (e, t) => B(e) ? t : e, He = (e, t) => {
|
|
238
|
+
let n = e.match(M), r = t[p] ? t : document.documentElement, i = getComputedStyle(r)?.getPropertyValue(n[1]);
|
|
239
239
|
return (!i || i.trim() === "") && n[2] && (i = n[2].trim()), i || 0;
|
|
240
|
-
},
|
|
241
|
-
if (
|
|
240
|
+
}, J = (e, t, n, r, i, a) => {
|
|
241
|
+
if (z(e)) {
|
|
242
242
|
if (!i) {
|
|
243
243
|
let i = e(t, n, r, a);
|
|
244
244
|
return isNaN(+i) ? i || 0 : +i;
|
|
@@ -249,19 +249,19 @@ var Fe = (e) => {
|
|
|
249
249
|
};
|
|
250
250
|
return i.func = o, o();
|
|
251
251
|
}
|
|
252
|
-
if (
|
|
253
|
-
if (!i) return
|
|
254
|
-
let n = () =>
|
|
252
|
+
if (R(e) && I(e, "var(")) {
|
|
253
|
+
if (!i) return He(e, t);
|
|
254
|
+
let n = () => He(e, t);
|
|
255
255
|
return i.func = n, n();
|
|
256
256
|
}
|
|
257
257
|
return e;
|
|
258
|
-
},
|
|
258
|
+
}, Ue = (e, t) => e[p] ? e[m] && ge(e, t) ? c.ATTRIBUTE : S.includes(t) || x.get(t) ? c.TRANSFORM : I(t, "--") ? c.CSS_VAR : t in e.style ? c.CSS : t in e ? c.OBJECT : c.ATTRIBUTE : c.OBJECT, We = (e, t, n) => {
|
|
259
259
|
let r = e.style[t];
|
|
260
260
|
r && n && (n[t] = r);
|
|
261
261
|
let i = r || getComputedStyle(e[g] || e).getPropertyValue(t);
|
|
262
262
|
return i === "auto" ? "0" : i;
|
|
263
|
-
},
|
|
264
|
-
let i =
|
|
263
|
+
}, Ge = (e, t, n, r) => {
|
|
264
|
+
let i = B(n) ? Ue(e, t) : n, a = Ie(e, t);
|
|
265
265
|
if (a) {
|
|
266
266
|
let n = a.get(e);
|
|
267
267
|
return n && r && (r[t] = n), n ?? 0;
|
|
@@ -274,8 +274,8 @@ var Fe = (e) => {
|
|
|
274
274
|
let n = e.getAttribute(t);
|
|
275
275
|
return n && r && (r[t] = n), n;
|
|
276
276
|
}
|
|
277
|
-
return i === c.TRANSFORM ?
|
|
278
|
-
},
|
|
277
|
+
return i === c.TRANSFORM ? Ne(e, t, r) : i === c.CSS_VAR ? We(e, t, r).trimStart() : We(e, t, r);
|
|
278
|
+
}, Ke = (e, t, n) => n === "-" ? e - t : n === "+" ? e + t : e * t, qe = () => ({
|
|
279
279
|
t: l.NUMBER,
|
|
280
280
|
n: 0,
|
|
281
281
|
u: null,
|
|
@@ -288,93 +288,93 @@ var Fe = (e) => {
|
|
|
288
288
|
if (!isNaN(n)) return t.n = n, t;
|
|
289
289
|
let r = e;
|
|
290
290
|
r[1] === "=" && (t.o = r[0], r = r.slice(2));
|
|
291
|
-
let i = !r.includes(" ") &&
|
|
291
|
+
let i = !r.includes(" ") && re.exec(r);
|
|
292
292
|
if (i) return t.t = l.UNIT, t.n = +i[1], t.u = i[2], t;
|
|
293
293
|
if (t.o) return t.n = +r, t;
|
|
294
|
-
if (
|
|
294
|
+
if (V(r)) return t.t = l.COLOR, t.d = Ve(r), t;
|
|
295
295
|
{
|
|
296
296
|
let e = r.match(ne);
|
|
297
297
|
return t.t = l.COMPLEX, t.d = e ? e.map(Number) : [], t.s = r.split(ne) || [], t;
|
|
298
298
|
}
|
|
299
|
-
},
|
|
299
|
+
}, Je = (e, t) => (t.t = e._valueType, t.n = e._toNumber, t.u = e._unit, t.o = null, t.d = G(e._toNumbers), t.s = G(e._strings), t), X = qe(), Ye = (e, t, n) => {
|
|
300
300
|
let r = e._modifier, i = e._fromNumbers, a = e._toNumbers, o = e._strings, s = o[0];
|
|
301
301
|
for (let c = 0, l = a.length; c < l; c++) {
|
|
302
|
-
let l = r(
|
|
302
|
+
let l = r(W(De(i[c], a[c], t), n)), u = o[c + 1];
|
|
303
303
|
s += `${u ? l + u : l}`, e._numbers[c] = l;
|
|
304
304
|
}
|
|
305
305
|
return s;
|
|
306
|
-
},
|
|
307
|
-
let a = e.parent, o = e.duration, s = e.completed, f = e.iterationDuration, p = e.iterationCount, m = e._currentIteration, g = e._loopDelay, v = e._reversed, y = e._alternate, b = e._hasChildren, x = e._delay, S = e._currentTime, C = x + f, w = t - x, T =
|
|
306
|
+
}, Xe = (e, t, n, r, i) => {
|
|
307
|
+
let a = e.parent, o = e.duration, s = e.completed, f = e.iterationDuration, p = e.iterationCount, m = e._currentIteration, g = e._loopDelay, v = e._reversed, y = e._alternate, b = e._hasChildren, x = e._delay, S = e._currentTime, C = x + f, w = t - x, T = U(S, -x, o), E = U(w, -x, o), D = w - S, O = E > 0, ee = E >= o, k = o <= _, te = i === u.FORCE, ne = 0, re = w, A = 0;
|
|
308
308
|
if (p > 1) {
|
|
309
309
|
let t = f + (ee ? 0 : g), n = ~~(E / t);
|
|
310
|
-
e._currentIteration =
|
|
310
|
+
e._currentIteration = U(n, 0, p), ee && e._currentIteration--, ne = e._currentIteration % 2, re = E - n * t || 0;
|
|
311
311
|
}
|
|
312
|
-
let
|
|
313
|
-
|
|
314
|
-
let
|
|
315
|
-
if (e._currentTime = w, e._iterationTime =
|
|
312
|
+
let j = v ^ (y && ne), M = e._ease, N = ee ? j ? 0 : o : j ? f - re : re;
|
|
313
|
+
M && (N = f * M(N / f) || 0);
|
|
314
|
+
let P = (a ? a.backwards : w < S) ? !j : !!j;
|
|
315
|
+
if (e._currentTime = w, e._iterationTime = N, e.backwards = P, O && !e.began ? (e.began = !0, !n && (!a || !P && a.began) && e.onBegin(e)) : w <= 0 && (e.began = !1), !n && !b && O && e._currentIteration !== m && e.onLoop(e), te || i === u.AUTO && (t >= (a && x > 0 ? 0 : x) && t <= C || t <= x && T > x || t >= C && T !== o) || N >= C && T !== o || N <= x && T > 0 && !ee || t <= T && T === o && s || ee && !s && k) {
|
|
316
316
|
if (O && (e.computeDeltaTime(T), n || e.onBeforeUpdate(e)), !b) {
|
|
317
|
-
let t = te || (
|
|
317
|
+
let t = te || (P ? D * -1 : D) >= F.tickThreshold, i = W(e._offset + (a ? a._offset : 0) + x + N, 12), o = e._head, s, u, f, p, m = 0;
|
|
318
318
|
for (; o;) {
|
|
319
319
|
let e = o._composition, n = o._currentTime, a = o._changeDuration, g = o._absoluteStartTime + o._changeDuration, _ = o._nextRep, v = o._prevRep, y = e !== d.none, b = v ? v._absoluteStartTime + v._changeDuration : 0, x = v && v.parent !== o.parent, S = !_ || _._isOverridden ? g : _.parent === o.parent ? g + _._delay : _._absoluteStartTime < _._absoluteUpdateStartTime ? _._absoluteStartTime : _._absoluteUpdateStartTime;
|
|
320
|
-
if ((t || (n !== a || i <= S || v && !x && (!_ || _.parent !== o.parent)) && (n !== 0 || i >= o._absoluteStartTime || x && !o._hasFromValue && !v._isOverridden && i >= b || _ && !_._isOverridden && _.parent === o.parent && _._currentTime !== 0 &&
|
|
321
|
-
let t = o._currentTime =
|
|
322
|
-
if (b) S = C = i(
|
|
323
|
-
else if (g === l.UNIT) C = i(
|
|
320
|
+
if ((t || (n !== a || i <= S || v && !x && (!_ || _.parent !== o.parent)) && (n !== 0 || i >= o._absoluteStartTime || x && !o._hasFromValue && !v._isOverridden && i >= b || _ && !_._isOverridden && _.parent === o.parent && _._currentTime !== 0 && N < _._startTime)) && (!v || x || N >= o._startTime) && (!y || !o._isOverridden && (!o._isOverlapped || i <= g) && (!_ || _._isOverridden || i <= S) && (!v || v._isOverridden || (x ? i >= o._absoluteStartTime || !o._hasFromValue && i >= b : i >= b + o._delay)))) {
|
|
321
|
+
let t = o._currentTime = U(N - o._startTime, 0, a), n = o._ease(t / o._updateDuration), i = o._modifier, g = o._valueType, _ = o._tweenType, v = _ === c.OBJECT, b = g === l.NUMBER, x = b && v || n === 0 || n === 1 ? -1 : F.precision, S, C;
|
|
322
|
+
if (b) S = C = i(W(De(o._fromNumber, o._toNumber, n), x));
|
|
323
|
+
else if (g === l.UNIT) C = i(W(De(o._fromNumber, o._toNumber, n), x)), S = `${C}${o._unit}`;
|
|
324
324
|
else if (g === l.COLOR) {
|
|
325
325
|
let e = o._numbers, t = o._fromNumbers, a = o._toNumbers, s = 1 - n, c = t[0], l = t[1], u = t[2], d = a[0], f = a[1], p = a[2];
|
|
326
|
-
e[0] = i(Math.sqrt(c * c * s + d * d * n)), e[1] = i(Math.sqrt(l * l * s + f * f * n)), e[2] = i(Math.sqrt(u * u * s + p * p * n)), e[3] = i(
|
|
327
|
-
} else g === l.COMPLEX && (S =
|
|
326
|
+
e[0] = i(Math.sqrt(c * c * s + d * d * n)), e[1] = i(Math.sqrt(l * l * s + f * f * n)), e[2] = i(Math.sqrt(u * u * s + p * p * n)), e[3] = i(De(t[3], a[3], n)), (!o._setter || r) && (S = `rgba(${W(e[0], 0)},${W(e[1], 0)},${W(e[2], 0)},${e[3]})`);
|
|
327
|
+
} else g === l.COMPLEX && (S = Ye(o, n, x));
|
|
328
328
|
if (y && (o._number = C), !r && e !== d.blend) {
|
|
329
329
|
let e = o.property;
|
|
330
|
-
s = o.target, o._setter ? o._setter(s, C, o) : v ? s[e] = S : _ === c.ATTRIBUTE ? s.setAttribute(e, S) : (u = s.style, _ === c.TRANSFORM ? (s !== f && (f = s, p = s[h]), p[e] = S, m = 1) : _ === c.CSS ? u[e] = S : _ === c.CSS_VAR && u.setProperty(e, S)), O && (
|
|
330
|
+
s = o.target, o._setter ? o._setter(s, C, o) : v ? s[e] = S : _ === c.ATTRIBUTE ? s.setAttribute(e, S) : (u = s.style, _ === c.TRANSFORM ? (s !== f && (f = s, p = s[h]), p[e] = S, m = 1) : _ === c.CSS ? u[e] = S : _ === c.CSS_VAR && u.setProperty(e, S)), O && (A = 1);
|
|
331
331
|
} else o._value = S;
|
|
332
|
-
} else n && v && !x &&
|
|
333
|
-
m && o._renderTransforms && (u.transform =
|
|
332
|
+
} else n && v && !x && N < o._startTime && (o._currentTime = 0);
|
|
333
|
+
m && o._renderTransforms && (u.transform = Pe(p), m = 0), o = o._next;
|
|
334
334
|
}
|
|
335
|
-
!n &&
|
|
335
|
+
!n && A && e.onRender(e);
|
|
336
336
|
}
|
|
337
337
|
!n && O && e.onUpdate(e);
|
|
338
338
|
}
|
|
339
|
-
return a && k ? !n && (a.began && !
|
|
340
|
-
},
|
|
339
|
+
return a && k ? !n && (a.began && !P && w > 0 && !s || P && w <= 1e-11 && s) && (e.onComplete(e), e.completed = !P) : O && ee ? p === Infinity ? e._startTime += e.duration : e._currentIteration >= p - 1 && (e.paused = !0, !s && !b && (e.completed = !0, !n && (!a || !P && a.began) && (e.onComplete(e), e._resolve(e)))) : e.completed = !1, A;
|
|
340
|
+
}, Ze = (e, t, n, r, i) => {
|
|
341
341
|
let a = e._currentIteration;
|
|
342
|
-
if (
|
|
343
|
-
let o = e, s = o.backwards, c = r ? t : o._iterationTime, l =
|
|
342
|
+
if (Xe(e, t, n, r, i), e._hasChildren) {
|
|
343
|
+
let o = e, s = o.backwards, c = r ? t : o._iterationTime, l = oe(), d = 0, f = !0;
|
|
344
344
|
if (!r && o._currentIteration !== a) {
|
|
345
345
|
let e = o.iterationDuration;
|
|
346
|
-
|
|
347
|
-
if (!s) !t.completed && !t.backwards && t._currentTime < t.iterationDuration &&
|
|
346
|
+
K(o, (t) => {
|
|
347
|
+
if (!s) !t.completed && !t.backwards && t._currentTime < t.iterationDuration && Xe(t, e, n, 1, u.FORCE), t.began = !1, t.completed = !1;
|
|
348
348
|
else {
|
|
349
349
|
let r = t.duration, i = t._offset + t._delay, a = i + r;
|
|
350
350
|
!n && r <= 1e-11 && (!i || a === e) && t.onComplete(t);
|
|
351
351
|
}
|
|
352
352
|
}), n || o.onLoop(o);
|
|
353
353
|
}
|
|
354
|
-
|
|
355
|
-
let t =
|
|
354
|
+
K(o, (e) => {
|
|
355
|
+
let t = W((c - e._offset) * e._speed, 12);
|
|
356
356
|
if (s && t > e._delay + e.duration) return;
|
|
357
357
|
let a = e._fps < o._fps ? e.requestTick(l) : i;
|
|
358
|
-
d +=
|
|
358
|
+
d += Xe(e, t, n, r, a), !e.completed && f && (f = !1);
|
|
359
359
|
}, s), !n && d && o.onRender(o), (f || s) && o._currentTime >= o.duration && (o.paused = !0, o.completed || (o.completed = !0, n || (o.onComplete(o), o._resolve(o))));
|
|
360
360
|
}
|
|
361
|
-
},
|
|
361
|
+
}, Qe = {}, $e = (e, t, n) => {
|
|
362
362
|
if (n === c.TRANSFORM) return x.get(e) || e;
|
|
363
|
-
if (n === c.CSS || n === c.ATTRIBUTE &&
|
|
364
|
-
let t =
|
|
363
|
+
if (n === c.CSS || n === c.ATTRIBUTE && ue(t) && e in t.style) {
|
|
364
|
+
let t = Qe[e];
|
|
365
365
|
if (t) return t;
|
|
366
366
|
{
|
|
367
|
-
let t = e &&
|
|
368
|
-
return
|
|
367
|
+
let t = e && ae(e);
|
|
368
|
+
return Qe[e] = t, t;
|
|
369
369
|
}
|
|
370
370
|
}
|
|
371
371
|
return e;
|
|
372
|
-
},
|
|
373
|
-
if (e._hasChildren)
|
|
372
|
+
}, et = (e, t = !1) => {
|
|
373
|
+
if (e._hasChildren) K(e, (e) => et(e, t), !0);
|
|
374
374
|
else {
|
|
375
375
|
let n = e;
|
|
376
|
-
n.pause(),
|
|
377
|
-
let r = e.property, i = e.target, a = e._tweenType, o = e._inlineValue, s =
|
|
376
|
+
n.pause(), K(n, (e) => {
|
|
377
|
+
let r = e.property, i = e.target, a = e._tweenType, o = e._inlineValue, s = le(o) || o === "";
|
|
378
378
|
if (e._setter) {
|
|
379
379
|
if (!t && !s) {
|
|
380
380
|
if (Y(o, X), X.d) {
|
|
@@ -390,8 +390,8 @@ var Fe = (e) => {
|
|
|
390
390
|
let t = i.style;
|
|
391
391
|
if (a === c.TRANSFORM) {
|
|
392
392
|
let n = i[h];
|
|
393
|
-
s ? delete n[r] : n[r] = o, e._renderTransforms && (Object.keys(n).length ? t.transform =
|
|
394
|
-
} else s ? t.removeProperty(
|
|
393
|
+
s ? delete n[r] : n[r] = o, e._renderTransforms && (Object.keys(n).length ? t.transform = Pe(n) : t.removeProperty("transform"));
|
|
394
|
+
} else s ? t.removeProperty(ae(r)) : t[r] = o;
|
|
395
395
|
}
|
|
396
396
|
}
|
|
397
397
|
i[p] && n._tail === e && n.targets.forEach((e) => {
|
|
@@ -400,7 +400,7 @@ var Fe = (e) => {
|
|
|
400
400
|
});
|
|
401
401
|
}
|
|
402
402
|
return e;
|
|
403
|
-
},
|
|
403
|
+
}, tt = class {
|
|
404
404
|
constructor(e = 0) {
|
|
405
405
|
this.deltaTime = 0, this._currentTime = e, this._lastTickTime = e, this._startTime = e, this._lastTime = e, this._frameDuration = y / 240, this._fps = 240, this._speed = 1, this._hasChildren = !1, this._head = null, this._tail = null;
|
|
406
406
|
}
|
|
@@ -409,7 +409,7 @@ var Fe = (e) => {
|
|
|
409
409
|
}
|
|
410
410
|
set fps(e) {
|
|
411
411
|
let t = +e, n = t < 1e-11 ? _ : t, r = y / n;
|
|
412
|
-
n >
|
|
412
|
+
n > N.frameRate && (N.frameRate = n), this._fps = n, this._frameDuration = r;
|
|
413
413
|
}
|
|
414
414
|
get speed() {
|
|
415
415
|
return this._speed;
|
|
@@ -426,11 +426,11 @@ var Fe = (e) => {
|
|
|
426
426
|
let t = e - this._lastTime;
|
|
427
427
|
return this.deltaTime = t, this._lastTime = e, t;
|
|
428
428
|
}
|
|
429
|
-
},
|
|
429
|
+
}, nt = {
|
|
430
430
|
animation: null,
|
|
431
431
|
update: w
|
|
432
|
-
},
|
|
433
|
-
let t =
|
|
432
|
+
}, rt = (e) => {
|
|
433
|
+
let t = nt.animation;
|
|
434
434
|
return t || (t = {
|
|
435
435
|
duration: _,
|
|
436
436
|
computeDeltaTime: w,
|
|
@@ -438,12 +438,12 @@ var Fe = (e) => {
|
|
|
438
438
|
_delay: 0,
|
|
439
439
|
_head: null,
|
|
440
440
|
_tail: null
|
|
441
|
-
},
|
|
441
|
+
}, nt.animation = t, nt.update = () => {
|
|
442
442
|
e.forEach((e) => {
|
|
443
443
|
for (let t in e) {
|
|
444
444
|
let n = e[t], r = n._head;
|
|
445
445
|
if (r) {
|
|
446
|
-
let e = r._valueType, t = e === l.COMPLEX || e === l.COLOR ?
|
|
446
|
+
let e = r._valueType, t = e === l.COMPLEX || e === l.COLOR ? G(r._fromNumbers) : null, i = r._fromNumber, a = n._tail;
|
|
447
447
|
for (; a && a !== r;) {
|
|
448
448
|
if (t) for (let e = 0, n = a._numbers.length; e < n; e++) t[e] += a._numbers[e];
|
|
449
449
|
else i += a._number;
|
|
@@ -452,104 +452,104 @@ var Fe = (e) => {
|
|
|
452
452
|
r._toNumber = i, r._toNumbers = t;
|
|
453
453
|
}
|
|
454
454
|
}
|
|
455
|
-
}),
|
|
455
|
+
}), Xe(t, 1, 1, 0, u.FORCE);
|
|
456
456
|
}), t;
|
|
457
|
-
},
|
|
457
|
+
}, it = a ? requestAnimationFrame : setImmediate, at = a ? cancelAnimationFrame : clearImmediate, ot = class extends tt {
|
|
458
458
|
constructor(e) {
|
|
459
|
-
super(e), this.useDefaultMainLoop = !0, this.pauseOnDocumentHidden = !0, this.defaults =
|
|
459
|
+
super(e), this.useDefaultMainLoop = !0, this.pauseOnDocumentHidden = !0, this.defaults = N, this.paused = !0, this.reqId = 0;
|
|
460
460
|
}
|
|
461
461
|
update() {
|
|
462
|
-
let e = this._currentTime =
|
|
462
|
+
let e = this._currentTime = oe();
|
|
463
463
|
if (this.requestTick(e)) {
|
|
464
464
|
this.computeDeltaTime(e);
|
|
465
465
|
let t = this._speed, n = this._fps, r = this._head;
|
|
466
466
|
for (; r;) {
|
|
467
467
|
let i = r._next;
|
|
468
|
-
r.paused ? (
|
|
468
|
+
r.paused ? (je(this, r), this._hasChildren = !!this._tail, r._running = !1, r.completed && !r._cancelled && r.cancel()) : Ze(r, (e - r._startTime) * r._speed * t, 0, 0, r._fps < n ? r.requestTick(e) : u.AUTO), r = i;
|
|
469
469
|
}
|
|
470
|
-
|
|
470
|
+
nt.update();
|
|
471
471
|
}
|
|
472
472
|
}
|
|
473
473
|
wake() {
|
|
474
|
-
return this.useDefaultMainLoop && !this.reqId && (this.requestTick(
|
|
474
|
+
return this.useDefaultMainLoop && !this.reqId && (this.requestTick(oe()), this.reqId = it(st)), this;
|
|
475
475
|
}
|
|
476
476
|
pause() {
|
|
477
|
-
if (this.reqId) return this.paused = !0,
|
|
477
|
+
if (this.reqId) return this.paused = !0, ct();
|
|
478
478
|
}
|
|
479
479
|
resume() {
|
|
480
|
-
if (this.paused) return this.paused = !1,
|
|
480
|
+
if (this.paused) return this.paused = !1, K(this, (e) => e.resetTime()), this.wake();
|
|
481
481
|
}
|
|
482
482
|
get speed() {
|
|
483
|
-
return this._speed * (
|
|
483
|
+
return this._speed * (F.timeScale === 1 ? 1 : y);
|
|
484
484
|
}
|
|
485
485
|
set speed(e) {
|
|
486
|
-
let t = e *
|
|
487
|
-
this._speed !== t && (this._speed = t,
|
|
486
|
+
let t = e * F.timeScale;
|
|
487
|
+
this._speed !== t && (this._speed = t, K(this, (e) => e.speed = e._speed));
|
|
488
488
|
}
|
|
489
489
|
get timeUnit() {
|
|
490
|
-
return
|
|
490
|
+
return F.timeScale === 1 ? "ms" : "s";
|
|
491
491
|
}
|
|
492
492
|
set timeUnit(e) {
|
|
493
493
|
let t = .001, n = e === "s", r = n ? t : 1;
|
|
494
|
-
if (
|
|
495
|
-
|
|
494
|
+
if (F.timeScale !== r) {
|
|
495
|
+
F.timeScale = r, F.tickThreshold = 200 * r;
|
|
496
496
|
let e = n ? t : y;
|
|
497
497
|
this.defaults.duration *= e, this._speed *= e;
|
|
498
498
|
}
|
|
499
499
|
}
|
|
500
500
|
get precision() {
|
|
501
|
-
return
|
|
501
|
+
return F.precision;
|
|
502
502
|
}
|
|
503
503
|
set precision(e) {
|
|
504
|
-
|
|
504
|
+
F.precision = e;
|
|
505
505
|
}
|
|
506
506
|
}, Z = /*#__PURE__*/ (() => {
|
|
507
|
-
let e = new
|
|
508
|
-
return a && (
|
|
507
|
+
let e = new ot(oe());
|
|
508
|
+
return a && (ie.engine = e, s.addEventListener("visibilitychange", () => {
|
|
509
509
|
e.pauseOnDocumentHidden && (s.hidden ? e.pause() : e.resume());
|
|
510
510
|
})), e;
|
|
511
|
-
})(),
|
|
512
|
-
Z._head ? (Z.reqId =
|
|
513
|
-
},
|
|
511
|
+
})(), st = () => {
|
|
512
|
+
Z._head ? (Z.reqId = it(st), Z.update()) : Z.reqId = 0;
|
|
513
|
+
}, ct = () => (at(Z.reqId), Z.reqId = 0, Z), lt = {
|
|
514
514
|
_rep: /* @__PURE__ */ new WeakMap(),
|
|
515
515
|
_add: /* @__PURE__ */ new Map()
|
|
516
|
-
},
|
|
517
|
-
let r =
|
|
516
|
+
}, ut = (e, t, n = "_rep") => {
|
|
517
|
+
let r = lt[n], i = r.get(e);
|
|
518
518
|
return i || (i = {}, r.set(e, i)), i[t] ? i[t] : i[t] = {
|
|
519
519
|
_head: null,
|
|
520
520
|
_tail: null
|
|
521
521
|
};
|
|
522
|
-
},
|
|
522
|
+
}, dt = (e, t) => e._isOverridden || e._absoluteStartTime > t._absoluteStartTime, ft = (e) => {
|
|
523
523
|
e._isOverlapped = 1, e._isOverridden = 1, e._changeDuration = _, e._currentTime = _;
|
|
524
|
-
},
|
|
524
|
+
}, pt = (e, t) => {
|
|
525
525
|
let n = e._composition;
|
|
526
526
|
if (n === d.replace) {
|
|
527
527
|
let n = e._absoluteStartTime;
|
|
528
|
-
|
|
528
|
+
Me(t, e, dt, "_prevRep", "_nextRep");
|
|
529
529
|
let r = e._prevRep;
|
|
530
530
|
if (r) {
|
|
531
531
|
let t = r.parent, i = r._absoluteEndTime;
|
|
532
532
|
if (e.parent.id !== t.id && t.iterationCount > 1 && i + (t.duration - t.iterationDuration) > n) {
|
|
533
|
-
|
|
533
|
+
ft(r);
|
|
534
534
|
let e = r._prevRep;
|
|
535
|
-
for (; e && e.parent.id === t.id;)
|
|
535
|
+
for (; e && e.parent.id === t.id;) ft(e), e = e._prevRep;
|
|
536
536
|
}
|
|
537
537
|
let a = e._absoluteUpdateStartTime;
|
|
538
538
|
if (i > a) {
|
|
539
|
-
let e = r._startTime, t =
|
|
540
|
-
r._changeDuration = t, r._currentTime = t, r._isOverlapped = 1, t < 1e-11 &&
|
|
539
|
+
let e = r._startTime, t = W(a - (i - (e + r._updateDuration)) - e, 12);
|
|
540
|
+
r._changeDuration = t, r._currentTime = t, r._isOverlapped = 1, t < 1e-11 && ft(r);
|
|
541
541
|
}
|
|
542
542
|
let o = e.parent.parent;
|
|
543
543
|
if (!o || o !== t.parent) {
|
|
544
544
|
let e = !0;
|
|
545
|
-
if (
|
|
545
|
+
if (K(t, (t) => {
|
|
546
546
|
t._isOverlapped || (e = !1);
|
|
547
547
|
}), e) {
|
|
548
548
|
let e = t.parent;
|
|
549
549
|
if (e) {
|
|
550
550
|
let n = !0;
|
|
551
|
-
|
|
552
|
-
e !== t &&
|
|
551
|
+
K(e, (e) => {
|
|
552
|
+
e !== t && K(e, (e) => {
|
|
553
553
|
e._isOverlapped || (n = !1);
|
|
554
554
|
});
|
|
555
555
|
}), n && e.cancel();
|
|
@@ -558,30 +558,30 @@ var Fe = (e) => {
|
|
|
558
558
|
}
|
|
559
559
|
}
|
|
560
560
|
} else if (n === d.blend) {
|
|
561
|
-
let t =
|
|
562
|
-
r || (r = { ...e }, r._composition = d.replace, r._updateDuration = _, r._startTime = 0, r._numbers =
|
|
561
|
+
let t = ut(e.target, e.property, "_add"), n = rt(lt._add), r = t._head;
|
|
562
|
+
r || (r = { ...e }, r._composition = d.replace, r._updateDuration = _, r._startTime = 0, r._numbers = G(e._fromNumbers), r._number = 0, r._next = null, r._prev = null, Me(t, r), Me(n, r));
|
|
563
563
|
let i = e._toNumber;
|
|
564
|
-
if (e._fromNumber = r._fromNumber - i, e._toNumber = 0, e._numbers =
|
|
565
|
-
let t =
|
|
564
|
+
if (e._fromNumber = r._fromNumber - i, e._toNumber = 0, e._numbers = G(e._fromNumbers), e._number = 0, r._fromNumber = i, e._toNumbers.length) {
|
|
565
|
+
let t = G(e._toNumbers);
|
|
566
566
|
t.forEach((t, n) => {
|
|
567
567
|
e._fromNumbers[n] = r._fromNumbers[n] - t, e._toNumbers[n] = 0;
|
|
568
568
|
}), r._fromNumbers = t;
|
|
569
569
|
}
|
|
570
|
-
|
|
570
|
+
Me(t, e, null, "_prevAdd", "_nextAdd");
|
|
571
571
|
}
|
|
572
572
|
return e;
|
|
573
|
-
},
|
|
573
|
+
}, mt = (e) => {
|
|
574
574
|
let t = e._composition;
|
|
575
575
|
if (t !== d.none) {
|
|
576
|
-
let n = e.target, r = e.property, i =
|
|
577
|
-
if (
|
|
578
|
-
let t =
|
|
576
|
+
let n = e.target, r = e.property, i = lt._rep.get(n)[r];
|
|
577
|
+
if (je(i, e, "_prevRep", "_nextRep"), t === d.blend) {
|
|
578
|
+
let t = lt._add, i = t.get(n);
|
|
579
579
|
if (!i) return;
|
|
580
|
-
let a = i[r], o =
|
|
581
|
-
|
|
580
|
+
let a = i[r], o = nt.animation;
|
|
581
|
+
je(a, e, "_prevAdd", "_nextAdd");
|
|
582
582
|
let s = a._head;
|
|
583
583
|
if (s && s === a._tail) {
|
|
584
|
-
|
|
584
|
+
je(a, s, "_prevAdd", "_nextAdd"), je(o, s);
|
|
585
585
|
let e = !0;
|
|
586
586
|
for (let t in i) if (i[t]._head) {
|
|
587
587
|
e = !1;
|
|
@@ -592,15 +592,15 @@ var Fe = (e) => {
|
|
|
592
592
|
}
|
|
593
593
|
}
|
|
594
594
|
return e;
|
|
595
|
-
},
|
|
596
|
-
e._composition !== d.none &&
|
|
597
|
-
}), e._cancelled = 0, e) : e,
|
|
595
|
+
}, ht = (e) => (e.paused = !0, e.began = !1, e.completed = !1, e), gt = (e) => e._cancelled ? (e._hasChildren ? K(e, gt) : K(e, (e) => {
|
|
596
|
+
e._composition !== d.none && pt(e, ut(e.target, e.property));
|
|
597
|
+
}), e._cancelled = 0, e) : e, _t = 0, vt = (e, t) => e._priority > t._priority, yt = class extends tt {
|
|
598
598
|
constructor(e = {}, t = null, n = 0) {
|
|
599
|
-
super(0), ++
|
|
599
|
+
super(0), ++_t;
|
|
600
600
|
let { id: r, delay: i, duration: a, reversed: o, alternate: s, loop: c, loopDelay: l, autoplay: u, frameRate: d, playbackRate: f, priority: p, onComplete: m, onLoop: h, onPause: g, onBegin: _, onBeforeUpdate: v, onUpdate: y } = e;
|
|
601
|
-
|
|
602
|
-
let b = t ? 0 : Z._lastTickTime, x = t ? t.defaults :
|
|
603
|
-
t ? O = n : (Z.reqId || Z.requestTick(
|
|
601
|
+
P.current && P.current.register(this);
|
|
602
|
+
let b = t ? 0 : Z._lastTickTime, x = t ? t.defaults : F.defaults, S = z(i) || B(i) ? x.delay : +i, C = z(a) || B(a) ? Infinity : +a, T = q(c, x.loop), E = q(l, x.loopDelay), D = T === !0 || T === Infinity || T < 0 ? Infinity : T + 1, O = 0;
|
|
603
|
+
t ? O = n : (Z.reqId || Z.requestTick(oe()), O = (Z._lastTickTime - Z._startTime) * F.timeScale), this.id = B(r) ? _t : r, this.parent = t, this.duration = Oe((C + E) * D - E) || 1e-11, this.backwards = !1, this.paused = !0, this.began = !1, this.completed = !1, this.onBegin = _ || x.onBegin, this.onBeforeUpdate = v || x.onBeforeUpdate, this.onUpdate = y || x.onUpdate, this.onLoop = h || x.onLoop, this.onPause = g || x.onPause, this.onComplete = m || x.onComplete, this.iterationDuration = C, this.iterationCount = D, this._autoplay = !t && q(u, x.autoplay), this._offset = O, this._delay = S, this._loopDelay = E, this._iterationTime = 0, this._currentIteration = 0, this._resolve = w, this._running = !1, this._reversed = +q(o, x.reversed), this._reverse = this._reversed, this._cancelled = 0, this._alternate = q(s, x.alternate), this._prev = null, this._next = null, this._lastTickTime = b, this._startTime = b, this._lastTime = b, this._fps = q(d, x.frameRate), this._speed = q(f, x.playbackRate), this._priority = +q(p, 1);
|
|
604
604
|
}
|
|
605
605
|
get cancelled() {
|
|
606
606
|
return !!this._cancelled;
|
|
@@ -609,26 +609,26 @@ var Fe = (e) => {
|
|
|
609
609
|
e ? this.cancel() : this.reset(!0).play();
|
|
610
610
|
}
|
|
611
611
|
get currentTime() {
|
|
612
|
-
return W(
|
|
612
|
+
return U(W(this._currentTime, F.precision), -this._delay, this.duration);
|
|
613
613
|
}
|
|
614
614
|
set currentTime(e) {
|
|
615
615
|
let t = this.paused;
|
|
616
616
|
this.pause().seek(+e), t || this.resume();
|
|
617
617
|
}
|
|
618
618
|
get iterationCurrentTime() {
|
|
619
|
-
return W(
|
|
619
|
+
return U(W(this._iterationTime, F.precision), 0, this.iterationDuration);
|
|
620
620
|
}
|
|
621
621
|
set iterationCurrentTime(e) {
|
|
622
622
|
this.currentTime = this.iterationDuration * this._currentIteration + e;
|
|
623
623
|
}
|
|
624
624
|
get progress() {
|
|
625
|
-
return W(
|
|
625
|
+
return U(W(this._currentTime / this.duration, 10), 0, 1);
|
|
626
626
|
}
|
|
627
627
|
set progress(e) {
|
|
628
628
|
this.currentTime = this.duration * e;
|
|
629
629
|
}
|
|
630
630
|
get iterationProgress() {
|
|
631
|
-
return W(
|
|
631
|
+
return U(W(this._iterationTime / this.iterationDuration, 10), 0, 1);
|
|
632
632
|
}
|
|
633
633
|
set iterationProgress(e) {
|
|
634
634
|
let t = this.iterationDuration;
|
|
@@ -638,7 +638,7 @@ var Fe = (e) => {
|
|
|
638
638
|
return this._currentIteration;
|
|
639
639
|
}
|
|
640
640
|
set currentIteration(e) {
|
|
641
|
-
this.currentTime = this.iterationDuration *
|
|
641
|
+
this.currentTime = this.iterationDuration * U(+e, 0, this.iterationCount - 1);
|
|
642
642
|
}
|
|
643
643
|
get reversed() {
|
|
644
644
|
return !!this._reversed;
|
|
@@ -653,33 +653,33 @@ var Fe = (e) => {
|
|
|
653
653
|
super.speed = e, this.resetTime();
|
|
654
654
|
}
|
|
655
655
|
reset(e = !1) {
|
|
656
|
-
return
|
|
656
|
+
return gt(this), this._reversed && !this._reverse && (this.reversed = !1), this._iterationTime = this.iterationDuration, Ze(this, 0, 1, ~~e, u.FORCE), ht(this), this._hasChildren && K(this, ht), this;
|
|
657
657
|
}
|
|
658
658
|
init(e = !1) {
|
|
659
|
-
this.fps = this._fps, this.speed = this._speed, !e && this._hasChildren &&
|
|
659
|
+
this.fps = this._fps, this.speed = this._speed, !e && this._hasChildren && Ze(this, this.duration, 1, ~~e, u.FORCE), this.reset(e);
|
|
660
660
|
let t = this._autoplay;
|
|
661
|
-
return t === !0 ? this.resume() : t && !
|
|
661
|
+
return t === !0 ? this.resume() : t && !B(t.linked) && t.link(this), this;
|
|
662
662
|
}
|
|
663
663
|
resetTime() {
|
|
664
664
|
let e = 1 / (this._speed * Z._speed);
|
|
665
|
-
return this._startTime =
|
|
665
|
+
return this._startTime = oe() - (this._currentTime + this._delay) * e, this;
|
|
666
666
|
}
|
|
667
667
|
pause() {
|
|
668
668
|
return this.paused ? this : (this.paused = !0, this.onPause(this), this);
|
|
669
669
|
}
|
|
670
670
|
resume() {
|
|
671
|
-
return this.paused ? (this.paused = !1, this.duration <= 1e-11 && !this._hasChildren ?
|
|
671
|
+
return this.paused ? (this.paused = !1, this.duration <= 1e-11 && !this._hasChildren ? Ze(this, _, 0, 0, u.FORCE) : (this._running ||= (Me(Z, this, vt), Z._hasChildren = !0, !0), this.resetTime(), this._startTime -= 12, Z.wake()), this) : this;
|
|
672
672
|
}
|
|
673
673
|
restart() {
|
|
674
674
|
return this.reset().resume();
|
|
675
675
|
}
|
|
676
676
|
seek(e, t = 0, n = 0) {
|
|
677
|
-
|
|
677
|
+
gt(this), this.completed = !1;
|
|
678
678
|
let r = this.paused;
|
|
679
|
-
return this.paused = !0,
|
|
679
|
+
return this.paused = !0, Ze(this, e + this._delay, ~~t, ~~n, u.AUTO), r ? this : this.resume();
|
|
680
680
|
}
|
|
681
681
|
alternate() {
|
|
682
|
-
let e = this._reversed, t = this.iterationCount, n = this.iterationDuration, r = t === Infinity ?
|
|
682
|
+
let e = this._reversed, t = this.iterationCount, n = this.iterationDuration, r = t === Infinity ? Ce(v / n) : t;
|
|
683
683
|
return this._reversed = +(this._alternate && !(r % 2) ? e : !e), t === Infinity ? this.iterationProgress = this._reversed ? 1 - this.iterationProgress : this.iterationProgress : this.seek(n * r - this._currentTime), this.resetTime(), this;
|
|
684
684
|
}
|
|
685
685
|
play() {
|
|
@@ -689,16 +689,16 @@ var Fe = (e) => {
|
|
|
689
689
|
return this._reversed || this.alternate(), this.resume();
|
|
690
690
|
}
|
|
691
691
|
cancel() {
|
|
692
|
-
return this._hasChildren ?
|
|
692
|
+
return this._hasChildren ? K(this, (e) => e.cancel(), !0) : K(this, mt), this._cancelled = 1, this.pause();
|
|
693
693
|
}
|
|
694
694
|
stretch(e) {
|
|
695
|
-
let t = this.duration, n =
|
|
695
|
+
let t = this.duration, n = ke(e);
|
|
696
696
|
if (t === n) return this;
|
|
697
697
|
let r = e / t, i = e <= _;
|
|
698
|
-
return this.duration = i ? _ : n, this.iterationDuration = i ? _ :
|
|
698
|
+
return this.duration = i ? _ : n, this.iterationDuration = i ? _ : ke(this.iterationDuration * r), this._offset *= r, this._delay *= r, this._loopDelay *= r, this;
|
|
699
699
|
}
|
|
700
700
|
revert() {
|
|
701
|
-
|
|
701
|
+
Ze(this, 0, 1, 0, u.AUTO);
|
|
702
702
|
let e = this._autoplay;
|
|
703
703
|
return e && e.linked && e.linked === this && e.revert(), this.cancel();
|
|
704
704
|
}
|
|
@@ -714,22 +714,22 @@ var Fe = (e) => {
|
|
|
714
714
|
};
|
|
715
715
|
//#endregion
|
|
716
716
|
//#region node_modules/.pnpm/animejs@4.5.0/node_modules/animejs/dist/modules/core/targets.js
|
|
717
|
-
function
|
|
718
|
-
let t =
|
|
717
|
+
function bt(e) {
|
|
718
|
+
let t = R(e) ? P.root.querySelectorAll(e) : e;
|
|
719
719
|
if (t instanceof NodeList || t instanceof HTMLCollection) return t;
|
|
720
720
|
}
|
|
721
|
-
function
|
|
722
|
-
if (
|
|
723
|
-
if (!a) return
|
|
724
|
-
if (
|
|
721
|
+
function xt(e) {
|
|
722
|
+
if (le(e)) return [];
|
|
723
|
+
if (!a) return se(e) && e.flat(Infinity) || [e];
|
|
724
|
+
if (se(e)) {
|
|
725
725
|
let t = e.flat(Infinity), n = [];
|
|
726
726
|
for (let e = 0, r = t.length; e < r; e++) {
|
|
727
727
|
let r = t[e];
|
|
728
|
-
if (!
|
|
729
|
-
let e =
|
|
728
|
+
if (!le(r)) {
|
|
729
|
+
let e = bt(r);
|
|
730
730
|
if (e) for (let t = 0, r = e.length; t < r; t++) {
|
|
731
731
|
let r = e[t];
|
|
732
|
-
if (!
|
|
732
|
+
if (!le(r)) {
|
|
733
733
|
let e = !1;
|
|
734
734
|
for (let t = 0, i = n.length; t < i; t++) if (n[t] === r) {
|
|
735
735
|
e = !0;
|
|
@@ -750,16 +750,16 @@ function bt(e) {
|
|
|
750
750
|
}
|
|
751
751
|
return n;
|
|
752
752
|
}
|
|
753
|
-
let t =
|
|
753
|
+
let t = bt(e);
|
|
754
754
|
return t ? Array.from(t) : [e];
|
|
755
755
|
}
|
|
756
|
-
function
|
|
757
|
-
let t =
|
|
756
|
+
function St(e) {
|
|
757
|
+
let t = xt(e), n = t.length;
|
|
758
758
|
for (let e = 0; e < n; e++) {
|
|
759
759
|
let n = t[e];
|
|
760
760
|
if (!n[f]) {
|
|
761
761
|
n[f] = !0;
|
|
762
|
-
let e =
|
|
762
|
+
let e = ue(n);
|
|
763
763
|
(n.nodeType || e) && (n[p] = !0, n[m] = e, n[h] = {});
|
|
764
764
|
}
|
|
765
765
|
}
|
|
@@ -767,18 +767,18 @@ function xt(e) {
|
|
|
767
767
|
}
|
|
768
768
|
//#endregion
|
|
769
769
|
//#region node_modules/.pnpm/animejs@4.5.0/node_modules/animejs/dist/modules/core/units.js
|
|
770
|
-
var
|
|
770
|
+
var Ct = {
|
|
771
771
|
deg: 1,
|
|
772
|
-
rad: 180 /
|
|
772
|
+
rad: 180 / Te,
|
|
773
773
|
turn: 360
|
|
774
|
-
},
|
|
774
|
+
}, wt = {}, Tt = (e, t, n, r = !1) => {
|
|
775
775
|
let i = t.u, a = t.n;
|
|
776
776
|
if (t.t === l.UNIT && i === n) return t;
|
|
777
|
-
let o = a + i + n, c =
|
|
778
|
-
if (!
|
|
777
|
+
let o = a + i + n, c = wt[o];
|
|
778
|
+
if (!B(c) && !r) t.n = c;
|
|
779
779
|
else {
|
|
780
780
|
let r;
|
|
781
|
-
if (i in
|
|
781
|
+
if (i in Ct) r = a * Ct[i] / Ct[n];
|
|
782
782
|
else {
|
|
783
783
|
let t = e.cloneNode(), o = e.parentNode, c = o && o !== s ? o : s.body;
|
|
784
784
|
c.appendChild(t);
|
|
@@ -789,89 +789,89 @@ var St = {
|
|
|
789
789
|
let d = u / (t.offsetWidth || 100);
|
|
790
790
|
c.removeChild(t), r = d * a;
|
|
791
791
|
}
|
|
792
|
-
t.n = r,
|
|
792
|
+
t.n = r, wt[o] = r;
|
|
793
793
|
}
|
|
794
794
|
return t.t, l.UNIT, t.u = n, t;
|
|
795
|
-
},
|
|
795
|
+
}, Et = (e) => e, Dt = (e = 1.68) => (t) => ve(t, +e), Ot = {
|
|
796
796
|
in: (e) => (t) => e(t),
|
|
797
797
|
out: (e) => (t) => 1 - e(1 - t),
|
|
798
798
|
inOut: (e) => (t) => t < .5 ? e(t * 2) / 2 : 1 - e(t * -2 + 2) / 2,
|
|
799
799
|
outIn: (e) => (t) => t < .5 ? (1 - e(1 - t * 2)) / 2 : (e(t * 2 - 1) + 1) / 2
|
|
800
|
-
},
|
|
801
|
-
"":
|
|
802
|
-
Quad:
|
|
803
|
-
Cubic:
|
|
804
|
-
Quart:
|
|
805
|
-
Quint:
|
|
806
|
-
Sine: (e) => 1 -
|
|
807
|
-
Circ: (e) => 1 -
|
|
808
|
-
Expo: (e) => e ?
|
|
800
|
+
}, kt = Te / 2, At = Te * 2, jt = {
|
|
801
|
+
"": Dt,
|
|
802
|
+
Quad: Dt(2),
|
|
803
|
+
Cubic: Dt(3),
|
|
804
|
+
Quart: Dt(4),
|
|
805
|
+
Quint: Dt(5),
|
|
806
|
+
Sine: (e) => 1 - be(e * kt),
|
|
807
|
+
Circ: (e) => 1 - ye(1 - e * e),
|
|
808
|
+
Expo: (e) => e ? ve(2, 10 * e - 10) : 0,
|
|
809
809
|
Bounce: (e) => {
|
|
810
810
|
let t, n = 4;
|
|
811
|
-
for (; e < ((t =
|
|
812
|
-
return 1 /
|
|
811
|
+
for (; e < ((t = ve(2, --n)) - 1) / 11;);
|
|
812
|
+
return 1 / ve(4, 3 - n) - 7.5625 * ve((t * 3 - 2) / 22 - e, 2);
|
|
813
813
|
},
|
|
814
814
|
Back: (e = 1.7) => (t) => (+e + 1) * t * t * t - +e * t * t,
|
|
815
815
|
Elastic: (e = 1, t = .3) => {
|
|
816
|
-
let n =
|
|
817
|
-
return (e) => e === 0 || e === 1 ? e : -n *
|
|
816
|
+
let n = U(+e, 1, 10), r = U(+t, _, 2), i = r / At * we(1 / n), a = At / r;
|
|
817
|
+
return (e) => e === 0 || e === 1 ? e : -n * ve(2, -10 * (1 - e)) * H((1 - e - i) * a);
|
|
818
818
|
}
|
|
819
|
-
},
|
|
819
|
+
}, Mt = /*#__PURE__ */ (() => {
|
|
820
820
|
let e = {
|
|
821
|
-
linear:
|
|
822
|
-
none:
|
|
821
|
+
linear: Et,
|
|
822
|
+
none: Et
|
|
823
823
|
};
|
|
824
|
-
for (let t in
|
|
825
|
-
let r =
|
|
824
|
+
for (let t in Ot) for (let n in jt) {
|
|
825
|
+
let r = jt[n], i = Ot[t];
|
|
826
826
|
e[t + n] = n === "" || n === "Back" || n === "Elastic" ? (e, t) => i(r(e, t)) : i(r);
|
|
827
827
|
}
|
|
828
828
|
return e;
|
|
829
|
-
})(),
|
|
830
|
-
linear:
|
|
831
|
-
none:
|
|
832
|
-
},
|
|
833
|
-
if (
|
|
829
|
+
})(), Nt = {
|
|
830
|
+
linear: Et,
|
|
831
|
+
none: Et
|
|
832
|
+
}, Pt = (e) => {
|
|
833
|
+
if (Nt[e]) return Nt[e];
|
|
834
834
|
if (e.indexOf("(") <= -1) {
|
|
835
|
-
let t =
|
|
836
|
-
return t ?
|
|
835
|
+
let t = Ot[e] || e.includes("Back") || e.includes("Elastic") ? Mt[e]() : Mt[e];
|
|
836
|
+
return t ? Nt[e] = t : Et;
|
|
837
837
|
}
|
|
838
838
|
{
|
|
839
|
-
let t = e.slice(0, -1).split("("), n =
|
|
840
|
-
return n ?
|
|
839
|
+
let t = e.slice(0, -1).split("("), n = Mt[t[0]];
|
|
840
|
+
return n ? Nt[e] = n(...t[1].split(",")) : Et;
|
|
841
841
|
}
|
|
842
|
-
},
|
|
842
|
+
}, Ft = [
|
|
843
843
|
"steps(",
|
|
844
844
|
"irregular(",
|
|
845
845
|
"linear(",
|
|
846
846
|
"cubicBezier("
|
|
847
|
-
],
|
|
848
|
-
if (
|
|
849
|
-
for (let t = 0, n =
|
|
847
|
+
], It = (e) => {
|
|
848
|
+
if (R(e)) {
|
|
849
|
+
for (let t = 0, n = Ft.length; t < n; t++) if (I(e, Ft[t])) return console.warn(`String syntax for \`ease: "${e}"\` has been removed from the core and replaced by importing and passing the easing function directly: \`ease: ${e}\``), Et;
|
|
850
850
|
}
|
|
851
|
-
return
|
|
852
|
-
}, Q =
|
|
851
|
+
return z(e) ? e : R(e) ? Pt(e) : Et;
|
|
852
|
+
}, Q = qe(), $ = qe(), Lt = {}, Rt = { func: null }, zt = { func: null }, Bt = [null], Vt = [null, null], Ht = { to: null }, Ut = 0, Wt = 0, Gt, Kt, qt = (e, t) => {
|
|
853
853
|
let n = {};
|
|
854
|
-
if (
|
|
855
|
-
let t = [].concat(...e.map((e) => Object.keys(e))).filter(
|
|
854
|
+
if (se(e)) {
|
|
855
|
+
let t = [].concat(...e.map((e) => Object.keys(e))).filter(me);
|
|
856
856
|
for (let r = 0, i = t.length; r < i; r++) {
|
|
857
857
|
let i = t[r];
|
|
858
858
|
n[i] = e.map((e) => {
|
|
859
859
|
let t = {};
|
|
860
860
|
for (let n in e) {
|
|
861
861
|
let r = e[n];
|
|
862
|
-
|
|
862
|
+
me(n) ? n === i && (t.to = r) : t[n] = r;
|
|
863
863
|
}
|
|
864
864
|
return t;
|
|
865
865
|
});
|
|
866
866
|
}
|
|
867
867
|
} else {
|
|
868
|
-
let r =
|
|
868
|
+
let r = q(t.duration, F.defaults.duration);
|
|
869
869
|
Object.keys(e).map((t) => ({
|
|
870
870
|
o: parseFloat(t) / 100,
|
|
871
871
|
p: e[t]
|
|
872
872
|
})).sort((e, t) => e.o - t.o).forEach((e) => {
|
|
873
873
|
let t = e.o, i = e.p;
|
|
874
|
-
for (let e in i) if (
|
|
874
|
+
for (let e in i) if (me(e)) {
|
|
875
875
|
let a = n[e];
|
|
876
876
|
a ||= n[e] = [];
|
|
877
877
|
let o = t * r, s = a.length, c = a[s - 1], l = { to: i[e] }, u = 0;
|
|
@@ -890,46 +890,46 @@ var St = {
|
|
|
890
890
|
}
|
|
891
891
|
}
|
|
892
892
|
return n;
|
|
893
|
-
},
|
|
893
|
+
}, Jt = class extends yt {
|
|
894
894
|
constructor(e, t, n, r, i = !1, a = 0, o) {
|
|
895
|
-
super(t, n, r), this._head, this._tail, ++
|
|
896
|
-
let s =
|
|
895
|
+
super(t, n, r), this._head, this._tail, ++Wt;
|
|
896
|
+
let s = St(e), u = s.length, f = t.keyframes, p = f ? Ae(qt(f, t), t) : t, { id: m, delay: h, duration: g, ease: v, playbackEase: y, modifier: x, composition: S, onRender: C } = p, w = n ? n.defaults : F.defaults, T = q(v, w.ease), E = q(y, w.playbackEase), D = E ? It(E) : null, O = !B(T.ease), ee = O ? T.ease : q(v, D ? "linear" : w.ease), k = O ? T.settlingDuration : q(g, w.duration), te = q(h, w.delay), ne = x || w.modifier, re = B(S) && u >= 1e3 ? d.none : B(S) ? w.composition : S, A = this._offset + (n ? n._offset : 0);
|
|
897
897
|
O && (T.parent = this);
|
|
898
|
-
let
|
|
898
|
+
let j = NaN, M = NaN, N = 0, P = 0;
|
|
899
899
|
for (let e = 0; e < u; e++) {
|
|
900
900
|
let t = s[e], r = a || e, u = o || s, f = NaN, m = NaN;
|
|
901
|
-
for (let e in p) if (
|
|
902
|
-
let a =
|
|
903
|
-
if (i && !g && (
|
|
904
|
-
let e = h.length, t = !
|
|
905
|
-
e === 2 && t ? (
|
|
906
|
-
t ? t === 1 ? (
|
|
907
|
-
})) :
|
|
908
|
-
} else
|
|
901
|
+
for (let e in p) if (me(e)) {
|
|
902
|
+
let a = Ue(t, e), o = Ie(t, e), s = $e(e, t, a), h = p[e], g = se(h);
|
|
903
|
+
if (i && !g && (Vt[0] = h, Vt[1] = h, h = Vt), g) {
|
|
904
|
+
let e = h.length, t = !ce(h[0]);
|
|
905
|
+
e === 2 && t ? (Ht.to = h, Bt[0] = Ht, Gt = Bt) : e > 2 && t ? (Gt = [], h.forEach((e, t) => {
|
|
906
|
+
t ? t === 1 ? (Vt[1] = e, Gt.push(Vt)) : Gt.push(e) : Vt[0] = e;
|
|
907
|
+
})) : Gt = h;
|
|
908
|
+
} else Bt[0] = h, Gt = Bt;
|
|
909
909
|
let _ = null, v = null, y = NaN, x = 0, S = 0;
|
|
910
|
-
for (let e =
|
|
911
|
-
let i =
|
|
912
|
-
|
|
913
|
-
let c =
|
|
914
|
-
!_ && f !== d.none && (_ =
|
|
915
|
-
let p = _ ? _._tail : null, m = n && p && p.parent.parent === n ? p : v, h =
|
|
916
|
-
|
|
917
|
-
let C =
|
|
918
|
-
!
|
|
919
|
-
let
|
|
910
|
+
for (let e = Gt.length; S < e; S++) {
|
|
911
|
+
let i = Gt[S];
|
|
912
|
+
ce(i) ? Kt = i : (Ht.to = i, Kt = Ht), Rt.func = null, zt.func = null;
|
|
913
|
+
let c = J(q(Kt.composition, re), t, r, u, null, null), f = L(c) ? c : d[c];
|
|
914
|
+
!_ && f !== d.none && (_ = ut(t, s));
|
|
915
|
+
let p = _ ? _._tail : null, m = n && p && p.parent.parent === n ? p : v, h = J(Kt.to, t, r, u, Rt, m), g;
|
|
916
|
+
ce(h) && !B(h.to) ? (Kt = h, g = h.to) : g = h;
|
|
917
|
+
let C = J(Kt.from, t, r, u, zt, m), w = Kt.ease || ee, T = J(w, t, r, u, null, m), E = z(T) || R(T) ? T : w, D = !B(E) && !B(E.ease), O = D ? E.ease : E, j = D ? E.settlingDuration : J(q(Kt.duration, e > 1 ? J(k, t, r, u, null, m) / e : k), t, r, u, null, m), M = J(q(Kt.delay, S ? 0 : te), t, r, u, null, m), F = Kt.modifier || ne, ie = !B(C), ae = !B(g), I = se(g), oe = I || ie && ae, ue = v ? x : 0, de = v ? x + M : M, fe = W(A + de, 12), pe = W(A + ue, 12);
|
|
918
|
+
!P && (ie || I) && (P = 1);
|
|
919
|
+
let V = v;
|
|
920
920
|
if (f !== d.none) {
|
|
921
921
|
let e = _._head;
|
|
922
|
-
for (; e && e._absoluteStartTime <=
|
|
922
|
+
for (; e && e._absoluteStartTime <= fe;) if (e._isOverridden || (V = e), e = e._nextRep, e && e._absoluteStartTime >= fe) for (; e;) ft(e), e = e._nextRep;
|
|
923
923
|
}
|
|
924
|
-
if (
|
|
925
|
-
Y(
|
|
926
|
-
let e =
|
|
927
|
-
Q.t === l.NUMBER && (
|
|
928
|
-
} else
|
|
929
|
-
if (Q.o && (Q.n =
|
|
924
|
+
if (oe) {
|
|
925
|
+
Y(I ? J(g[0], t, r, u, zt, m) : C, Q), Y(I ? J(g[1], t, r, u, Rt, m) : g, $);
|
|
926
|
+
let e = Ge(t, s, a, Lt);
|
|
927
|
+
Q.t === l.NUMBER && (V ? V._valueType === l.UNIT && (Q.t = l.UNIT, Q.u = V._unit) : (Y(e, X), X.t === l.UNIT && (Q.t = l.UNIT, Q.u = X.u)));
|
|
928
|
+
} else ae ? Y(g, $) : v ? Je(v, $) : Y(n && V && V.parent.parent === n ? V._value : Ge(t, s, a, Lt), $), ie ? Y(C, Q) : v ? Je(v, Q) : Y(n && V && V.parent.parent === n ? V._value : Ge(t, s, a, Lt), Q);
|
|
929
|
+
if (Q.o && (Q.n = Ke(V ? V._toNumber : Y(Ge(t, s, a, Lt), X).n, Q.n, Q.o)), $.o && ($.n = Ke(Q.n, $.n, $.o)), Q.t !== $.t) {
|
|
930
930
|
if (Q.t === l.COMPLEX || $.t === l.COMPLEX) {
|
|
931
931
|
let e = Q.t === l.COMPLEX ? Q : $, t = Q.t === l.COMPLEX ? $ : Q;
|
|
932
|
-
t.t = l.COMPLEX, t.s =
|
|
932
|
+
t.t = l.COMPLEX, t.s = G(e.s), t.d = e.d.map(() => t.n);
|
|
933
933
|
} else if (Q.t === l.UNIT || $.t === l.UNIT) {
|
|
934
934
|
let e = Q.t === l.UNIT ? Q : $, t = Q.t === l.UNIT ? $ : Q;
|
|
935
935
|
t.t = l.UNIT, t.u = e.u;
|
|
@@ -940,51 +940,51 @@ var St = {
|
|
|
940
940
|
}
|
|
941
941
|
if (Q.u !== $.u) {
|
|
942
942
|
let e = $.u ? Q : $;
|
|
943
|
-
e =
|
|
943
|
+
e = Tt(t, e, $.u ? $.u : Q.u, !1);
|
|
944
944
|
}
|
|
945
945
|
if ($.d && Q.d && $.d.length !== Q.d.length) {
|
|
946
946
|
let e = Q.d.length > $.d.length ? Q : $, t = e === Q ? $ : Q;
|
|
947
|
-
t.d = e.d.map((e, n) =>
|
|
947
|
+
t.d = e.d.map((e, n) => B(t.d[n]) ? 0 : t.d[n]), t.s = G(e.s);
|
|
948
948
|
}
|
|
949
|
-
let
|
|
950
|
-
|
|
951
|
-
let
|
|
952
|
-
x =
|
|
953
|
-
let
|
|
949
|
+
let me = W(+j || 1e-11, 12), he = Lt[s];
|
|
950
|
+
le(he) || (Lt[s] = null);
|
|
951
|
+
let ge = o ? o.set : null;
|
|
952
|
+
x = W(de + me, 12);
|
|
953
|
+
let _e = Q.d, ve = $.d, ye = $.s, H = {
|
|
954
954
|
parent: this,
|
|
955
|
-
id:
|
|
955
|
+
id: Ut++,
|
|
956
956
|
property: s,
|
|
957
957
|
target: t,
|
|
958
958
|
_value: null,
|
|
959
|
-
_toFunc:
|
|
960
|
-
_fromFunc:
|
|
961
|
-
_ease:
|
|
962
|
-
_fromNumbers:
|
|
963
|
-
_toNumbers:
|
|
964
|
-
_strings:
|
|
959
|
+
_toFunc: Rt.func,
|
|
960
|
+
_fromFunc: zt.func,
|
|
961
|
+
_ease: It(O),
|
|
962
|
+
_fromNumbers: _e ? G(_e) : b,
|
|
963
|
+
_toNumbers: ve ? G(ve) : b,
|
|
964
|
+
_strings: ye ? G(ye) : b,
|
|
965
965
|
_fromNumber: Q.n,
|
|
966
966
|
_toNumber: $.n,
|
|
967
|
-
_numbers:
|
|
967
|
+
_numbers: _e ? G(_e) : b,
|
|
968
968
|
_number: Q.n,
|
|
969
969
|
_unit: $.u,
|
|
970
|
-
_modifier:
|
|
970
|
+
_modifier: F,
|
|
971
971
|
_currentTime: 0,
|
|
972
|
-
_startTime:
|
|
973
|
-
_delay: +
|
|
974
|
-
_updateDuration:
|
|
975
|
-
_changeDuration:
|
|
976
|
-
_absoluteStartTime:
|
|
977
|
-
_absoluteUpdateStartTime:
|
|
978
|
-
_absoluteEndTime:
|
|
979
|
-
_hasFromValue:
|
|
972
|
+
_startTime: de,
|
|
973
|
+
_delay: +M,
|
|
974
|
+
_updateDuration: me,
|
|
975
|
+
_changeDuration: me,
|
|
976
|
+
_absoluteStartTime: fe,
|
|
977
|
+
_absoluteUpdateStartTime: pe,
|
|
978
|
+
_absoluteEndTime: W(A + x, 12),
|
|
979
|
+
_hasFromValue: ie || I ? 1 : 0,
|
|
980
980
|
_tweenType: a,
|
|
981
|
-
_setter:
|
|
981
|
+
_setter: ge,
|
|
982
982
|
_valueType: $.t,
|
|
983
983
|
_composition: f,
|
|
984
984
|
_isOverlapped: 0,
|
|
985
985
|
_isOverridden: 0,
|
|
986
986
|
_renderTransforms: 0,
|
|
987
|
-
_inlineValue:
|
|
987
|
+
_inlineValue: he,
|
|
988
988
|
_prevRep: null,
|
|
989
989
|
_nextRep: null,
|
|
990
990
|
_prevAdd: null,
|
|
@@ -992,126 +992,157 @@ var St = {
|
|
|
992
992
|
_prev: null,
|
|
993
993
|
_next: null
|
|
994
994
|
};
|
|
995
|
-
f !== d.none &&
|
|
996
|
-
let
|
|
997
|
-
if (
|
|
998
|
-
else if (
|
|
999
|
-
else if (
|
|
995
|
+
f !== d.none && pt(H, _);
|
|
996
|
+
let be = H._valueType;
|
|
997
|
+
if (be === l.COMPLEX) H._value = Ye(H, 1, -1);
|
|
998
|
+
else if (be === l.UNIT) H._value = `${F(H._toNumber)}${H._unit}`;
|
|
999
|
+
else if (be === l.COLOR) {
|
|
1000
1000
|
let e = $.d;
|
|
1001
|
-
|
|
1002
|
-
} else
|
|
1003
|
-
isNaN(y) && (y =
|
|
1001
|
+
H._value = `rgba(${W(e[0], 0)},${W(e[1], 0)},${W(e[2], 0)},${e[3]})`;
|
|
1002
|
+
} else H._value = F(H._toNumber);
|
|
1003
|
+
isNaN(y) && (y = H._startTime), v = H, N++, Me(this, H);
|
|
1004
1004
|
}
|
|
1005
|
-
(isNaN(
|
|
1005
|
+
(isNaN(M) || y < M) && (M = y), (isNaN(j) || x > j) && (j = x), a === c.TRANSFORM && (f = N - S, m = N);
|
|
1006
1006
|
}
|
|
1007
1007
|
if (!isNaN(f)) {
|
|
1008
1008
|
let e = 0;
|
|
1009
|
-
|
|
1010
|
-
e >= f && e < m && (t._renderTransforms = 1, t._composition === d.blend &&
|
|
1009
|
+
K(this, (t) => {
|
|
1010
|
+
e >= f && e < m && (t._renderTransforms = 1, t._composition === d.blend && K(nt.animation, (e) => {
|
|
1011
1011
|
e.id === t.id && (e._renderTransforms = 1);
|
|
1012
1012
|
})), e++;
|
|
1013
1013
|
});
|
|
1014
1014
|
}
|
|
1015
1015
|
}
|
|
1016
|
-
u || console.warn("No target found. Make sure the element you're trying to animate is accessible before creating your animation."),
|
|
1017
|
-
e._startTime - e._delay || (e._delay -=
|
|
1018
|
-
}),
|
|
1016
|
+
u || console.warn("No target found. Make sure the element you're trying to animate is accessible before creating your animation."), M ? (K(this, (e) => {
|
|
1017
|
+
e._startTime - e._delay || (e._delay -= M), e._startTime -= M;
|
|
1018
|
+
}), j -= M) : M = 0, j || (j = _, this.iterationCount = 0), this.targets = s, this.id = B(m) ? Wt : m, this.duration = j === 1e-11 ? _ : Oe((j + this._loopDelay) * this.iterationCount - this._loopDelay) || 1e-11, this.onRender = C || w.onRender, this._ease = D, this._delay = M, this.iterationDuration = j, !this._autoplay && P && this.onRender(this);
|
|
1019
1019
|
}
|
|
1020
1020
|
stretch(e) {
|
|
1021
1021
|
let t = this.duration;
|
|
1022
|
-
if (t ===
|
|
1022
|
+
if (t === ke(e)) return this;
|
|
1023
1023
|
let n = e / t;
|
|
1024
|
-
return
|
|
1025
|
-
e._updateDuration =
|
|
1024
|
+
return K(this, (e) => {
|
|
1025
|
+
e._updateDuration = ke(e._updateDuration * n), e._changeDuration = ke(e._changeDuration * n), e._currentTime *= n, e._delay *= n, e._startTime *= n, e._absoluteStartTime *= n, e._absoluteUpdateStartTime *= n, e._absoluteEndTime *= n;
|
|
1026
1026
|
}), super.stretch(e);
|
|
1027
1027
|
}
|
|
1028
1028
|
refresh() {
|
|
1029
|
-
return
|
|
1029
|
+
return K(this, (e) => {
|
|
1030
1030
|
let t = e._toFunc, n = e._fromFunc;
|
|
1031
|
-
(t || n) && (n ? (Y(n(), Q), Q.u !== e._unit && e.target[p] &&
|
|
1031
|
+
(t || n) && (n ? (Y(n(), Q), Q.u !== e._unit && e.target[p] && Tt(e.target, Q, e._unit, !0), e._fromNumbers = G(Q.d), e._fromNumber = Q.n) : t && (Y(Ge(e.target, e.property, e._tweenType), X), e._fromNumbers = G(X.d), e._fromNumber = X.n), t && (Y(t(), $), e._toNumbers = G($.d), e._strings = G($.s), e._toNumber = $.o ? Ke(e._fromNumber, $.n, $.o) : $.n));
|
|
1032
1032
|
}), this.duration === 1e-11 && this.restart(), this;
|
|
1033
1033
|
}
|
|
1034
1034
|
revert() {
|
|
1035
|
-
return super.revert(),
|
|
1035
|
+
return super.revert(), et(this);
|
|
1036
1036
|
}
|
|
1037
1037
|
then(e) {
|
|
1038
1038
|
return super.then(e);
|
|
1039
1039
|
}
|
|
1040
|
-
},
|
|
1041
|
-
if (
|
|
1040
|
+
}, Yt = (e, t) => F.editor ? F.editor.addAnimation(e, t) : new Jt(e, t, null, 0, !1).init(), Xt = (e, t) => {
|
|
1041
|
+
if (I(t, "<")) {
|
|
1042
1042
|
let n = t[1] === "<", r = e._tail, i = r ? r._offset + r._delay : 0;
|
|
1043
1043
|
return n ? i : i + r.duration;
|
|
1044
1044
|
}
|
|
1045
|
-
},
|
|
1045
|
+
}, Zt = (e, t) => {
|
|
1046
1046
|
let n = e.iterationDuration;
|
|
1047
|
-
if (n === 1e-11 && (n = 0),
|
|
1048
|
-
if (
|
|
1049
|
-
let r = t, i = e ? e.labels : null, a = !
|
|
1047
|
+
if (n === 1e-11 && (n = 0), B(t)) return n;
|
|
1048
|
+
if (L(+t)) return +t;
|
|
1049
|
+
let r = t, i = e ? e.labels : null, a = !le(i), o = Xt(e, r), s = !B(o), c = j.exec(r);
|
|
1050
1050
|
if (c) {
|
|
1051
1051
|
let e = c[0], t = r.split(e), l = a && t[0] ? i[t[0]] : n;
|
|
1052
|
-
return
|
|
1053
|
-
}
|
|
1054
|
-
return s ? o : a ?
|
|
1052
|
+
return Ke(s ? o : a ? l : n, +t[1], e[0]);
|
|
1053
|
+
}
|
|
1054
|
+
return s ? o : a ? B(i[r]) ? n : i[r] : n;
|
|
1055
|
+
}, Qt = {
|
|
1056
|
+
_head: null,
|
|
1057
|
+
_tail: null
|
|
1058
|
+
}, $t = (e, t, n) => {
|
|
1059
|
+
let r = Qt._head, i;
|
|
1060
|
+
for (; r;) {
|
|
1061
|
+
let a = r._next, o = r.$el === e, s = !t || r.property === t, c = !n || r.parent === n;
|
|
1062
|
+
if (o && s && c) {
|
|
1063
|
+
i = r.animation;
|
|
1064
|
+
try {
|
|
1065
|
+
i.commitStyles();
|
|
1066
|
+
} catch {}
|
|
1067
|
+
i.cancel(), je(Qt, r);
|
|
1068
|
+
let e = r.parent;
|
|
1069
|
+
e && (e._completed++, e.animations.length === e._completed && (e.completed = !0, e.paused = !0, e.muteCallbacks || (e.onComplete(e), e._resolve(e))));
|
|
1070
|
+
}
|
|
1071
|
+
r = a;
|
|
1072
|
+
}
|
|
1073
|
+
return i;
|
|
1074
|
+
}, en = (e, t, n, r, i) => {
|
|
1075
|
+
let a = t.animate(r, i), o = i.delay + +i.duration * i.iterations;
|
|
1076
|
+
a.playbackRate = e._speed, e.paused && a.pause(), e.duration < o && (e.duration = o, e.controlAnimation = a), e.animations.push(a), $t(t, n), Me(Qt, {
|
|
1077
|
+
parent: e,
|
|
1078
|
+
animation: a,
|
|
1079
|
+
$el: t,
|
|
1080
|
+
property: n,
|
|
1081
|
+
_next: null,
|
|
1082
|
+
_prev: null
|
|
1083
|
+
});
|
|
1084
|
+
let s = () => $t(t, n, e);
|
|
1085
|
+
return a.oncancel = s, a.onremove = s, e.persist || (a.onfinish = s), a;
|
|
1055
1086
|
};
|
|
1056
1087
|
//#endregion
|
|
1057
1088
|
//#region node_modules/.pnpm/animejs@4.5.0/node_modules/animejs/dist/modules/utils/target.js
|
|
1058
|
-
function
|
|
1059
|
-
let r =
|
|
1089
|
+
function tn(e, t, n) {
|
|
1090
|
+
let r = St(e);
|
|
1060
1091
|
if (!r.length) return;
|
|
1061
|
-
let [i] = r, a =
|
|
1062
|
-
if (
|
|
1092
|
+
let [i] = r, a = Ge(i, $e(t, i, Ue(i, t)));
|
|
1093
|
+
if (B(n)) return a;
|
|
1063
1094
|
if (Y(a, X), X.t === l.NUMBER || X.t === l.UNIT) {
|
|
1064
1095
|
if (n === !1) return X.n;
|
|
1065
1096
|
{
|
|
1066
|
-
let e =
|
|
1067
|
-
return `${
|
|
1097
|
+
let e = Tt(i, X, n, !1);
|
|
1098
|
+
return `${W(e.n, F.precision)}${e.u}`;
|
|
1068
1099
|
}
|
|
1069
1100
|
}
|
|
1070
1101
|
}
|
|
1071
|
-
var
|
|
1072
|
-
if (!
|
|
1073
|
-
},
|
|
1074
|
-
duration: 1 *
|
|
1102
|
+
var nn = (e, t) => {
|
|
1103
|
+
if (!B(t)) return F.editor && F.editor.addSet ? F.editor.addSet(e, t) : (t.duration = _, t.composition = q(t.composition, d.none), new Jt(e, t, null, 0, !0).resume());
|
|
1104
|
+
}, rn = (e = w) => new yt({
|
|
1105
|
+
duration: 1 * F.timeScale,
|
|
1075
1106
|
onComplete: e
|
|
1076
|
-
}, null, 0).resume(),
|
|
1107
|
+
}, null, 0).resume(), an = (e) => {
|
|
1077
1108
|
let t;
|
|
1078
1109
|
return ((...n) => {
|
|
1079
1110
|
let r, i, a, o, s;
|
|
1080
1111
|
t && (r = t.currentIteration, i = t.iterationProgress, a = t.reversed, o = t._alternate, s = t._startTime, t.revert());
|
|
1081
1112
|
let c = e(...n);
|
|
1082
|
-
return c && !
|
|
1113
|
+
return c && !z(c) && c.revert && (t = c), B(i) || (t.currentIteration = r, t.iterationProgress = (o && r % 2 ? !a : a) ? 1 - i : i, t._startTime = s), c || w;
|
|
1083
1114
|
});
|
|
1084
|
-
},
|
|
1115
|
+
}, on = () => {
|
|
1085
1116
|
let e = s.createElement("div");
|
|
1086
1117
|
s.body.appendChild(e), e.style.height = "100lvh";
|
|
1087
1118
|
let t = e.offsetHeight;
|
|
1088
1119
|
return s.body.removeChild(e), t;
|
|
1089
|
-
},
|
|
1120
|
+
}, sn = (e, t) => e && z(e) ? e(t) : e, cn = /* @__PURE__ */ new Map(), ln = class {
|
|
1090
1121
|
constructor(e) {
|
|
1091
|
-
this.element = e, this.useWin = this.element === s.body, this.winWidth = 0, this.winHeight = 0, this.width = 0, this.height = 0, this.left = 0, this.top = 0, this.scale = 1, this.zIndex = 0, this.scrollX = 0, this.scrollY = 0, this.prevScrollX = 0, this.prevScrollY = 0, this.scrollWidth = 0, this.scrollHeight = 0, this.velocity = 0, this.backwardX = !1, this.backwardY = !1, this.scrollTicker = new
|
|
1122
|
+
this.element = e, this.useWin = this.element === s.body, this.winWidth = 0, this.winHeight = 0, this.width = 0, this.height = 0, this.left = 0, this.top = 0, this.scale = 1, this.zIndex = 0, this.scrollX = 0, this.scrollY = 0, this.prevScrollX = 0, this.prevScrollY = 0, this.scrollWidth = 0, this.scrollHeight = 0, this.velocity = 0, this.backwardX = !1, this.backwardY = !1, this.scrollTicker = new yt({
|
|
1092
1123
|
autoplay: !1,
|
|
1093
1124
|
onBegin: () => this.dataTimer.resume(),
|
|
1094
1125
|
onUpdate: () => {
|
|
1095
1126
|
let e = this.backwardX || this.backwardY;
|
|
1096
|
-
|
|
1127
|
+
K(this, (e) => e.handleScroll(), e);
|
|
1097
1128
|
},
|
|
1098
1129
|
onComplete: () => this.dataTimer.pause()
|
|
1099
|
-
}).init(), this.dataTimer = new
|
|
1130
|
+
}).init(), this.dataTimer = new yt({
|
|
1100
1131
|
autoplay: !1,
|
|
1101
1132
|
frameRate: 30,
|
|
1102
1133
|
onUpdate: (e) => {
|
|
1103
1134
|
let t = e.deltaTime, n = this.prevScrollX, r = this.prevScrollY, i = this.scrollX, a = this.scrollY, o = n - i, s = r - a;
|
|
1104
|
-
this.prevScrollX = i, this.prevScrollY = a, o && (this.backwardX = n > i), s && (this.backwardY = r > a), this.velocity =
|
|
1135
|
+
this.prevScrollX = i, this.prevScrollY = a, o && (this.backwardX = n > i), s && (this.backwardY = r > a), this.velocity = W(t > 0 ? Math.sqrt(o * o + s * s) / t : 0, 5);
|
|
1105
1136
|
}
|
|
1106
|
-
}).init(), this.resizeTicker = new
|
|
1137
|
+
}).init(), this.resizeTicker = new yt({
|
|
1107
1138
|
autoplay: !1,
|
|
1108
|
-
duration: 250 *
|
|
1139
|
+
duration: 250 * F.timeScale,
|
|
1109
1140
|
onComplete: () => {
|
|
1110
1141
|
this.updateWindowBounds(), this.refreshScrollObservers(), this.handleScroll();
|
|
1111
1142
|
}
|
|
1112
|
-
}).init(), this.wakeTicker = new
|
|
1143
|
+
}).init(), this.wakeTicker = new yt({
|
|
1113
1144
|
autoplay: !1,
|
|
1114
|
-
duration: 500 *
|
|
1145
|
+
duration: 500 * F.timeScale,
|
|
1115
1146
|
onBegin: () => {
|
|
1116
1147
|
this.scrollTicker.resume();
|
|
1117
1148
|
},
|
|
@@ -1122,10 +1153,10 @@ var Qt = (e, t) => {
|
|
|
1122
1153
|
}
|
|
1123
1154
|
updateScrollCoords() {
|
|
1124
1155
|
let e = this.useWin, t = this.element;
|
|
1125
|
-
this.scrollX =
|
|
1156
|
+
this.scrollX = W(e ? o.scrollX : t.scrollLeft, 0), this.scrollY = W(e ? o.scrollY : t.scrollTop, 0);
|
|
1126
1157
|
}
|
|
1127
1158
|
updateWindowBounds() {
|
|
1128
|
-
this.winWidth = o.innerWidth, this.winHeight =
|
|
1159
|
+
this.winWidth = o.innerWidth, this.winHeight = on();
|
|
1129
1160
|
}
|
|
1130
1161
|
updateBounds() {
|
|
1131
1162
|
let e = getComputedStyle(this.element), t = this.element;
|
|
@@ -1139,9 +1170,9 @@ var Qt = (e, t) => {
|
|
|
1139
1170
|
this.width = n, this.height = r;
|
|
1140
1171
|
}
|
|
1141
1172
|
refreshScrollObservers() {
|
|
1142
|
-
|
|
1173
|
+
K(this, (e) => {
|
|
1143
1174
|
e.ready && e._debug && e.removeDebug();
|
|
1144
|
-
}), this.updateBounds(),
|
|
1175
|
+
}), this.updateBounds(), K(this, (e) => {
|
|
1145
1176
|
e.ready && (e.refresh(), e.onResize(e), e._debug && e.debug());
|
|
1146
1177
|
});
|
|
1147
1178
|
}
|
|
@@ -1155,31 +1186,31 @@ var Qt = (e, t) => {
|
|
|
1155
1186
|
e.type === "scroll" && this.handleScroll();
|
|
1156
1187
|
}
|
|
1157
1188
|
revert() {
|
|
1158
|
-
this.scrollTicker.cancel(), this.dataTimer.cancel(), this.resizeTicker.cancel(), this.wakeTicker.cancel(), this.resizeObserver.disconnect(), (this.useWin ? o : this.element).removeEventListener("scroll", this),
|
|
1189
|
+
this.scrollTicker.cancel(), this.dataTimer.cancel(), this.resizeTicker.cancel(), this.wakeTicker.cancel(), this.resizeObserver.disconnect(), (this.useWin ? o : this.element).removeEventListener("scroll", this), cn.delete(this.element);
|
|
1159
1190
|
}
|
|
1160
|
-
},
|
|
1161
|
-
let t = e &&
|
|
1162
|
-
return n || (n = new
|
|
1163
|
-
},
|
|
1191
|
+
}, un = (e) => {
|
|
1192
|
+
let t = e && xt(e)[0] || s.body, n = cn.get(t);
|
|
1193
|
+
return n || (n = new ln(t), cn.set(t, n)), n;
|
|
1194
|
+
}, dn = (e, t, n, r, i) => {
|
|
1164
1195
|
let a = t === "min", o = t === "max", { n: s, u: c } = Y(t === "top" || t === "left" || t === "start" || a ? 0 : t === "bottom" || t === "right" || t === "end" || o ? "100%" : t === "center" ? "50%" : t, X), l = s;
|
|
1165
|
-
return c === "%" ? l = s / 100 * n : c && (l =
|
|
1166
|
-
},
|
|
1196
|
+
return c === "%" ? l = s / 100 * n : c && (l = Tt(e, X, "px", !0).n), o && r < 0 && (l += r), a && i > 0 && (l += i), l;
|
|
1197
|
+
}, fn = (e, t, n, r, i) => {
|
|
1167
1198
|
let a;
|
|
1168
|
-
if (
|
|
1169
|
-
let o =
|
|
1199
|
+
if (R(t)) {
|
|
1200
|
+
let o = j.exec(t);
|
|
1170
1201
|
if (o) {
|
|
1171
|
-
let s = o[0], c = s[0], l = t.split(s), u = l[0] === "min", d = l[0] === "max", f =
|
|
1202
|
+
let s = o[0], c = s[0], l = t.split(s), u = l[0] === "min", d = l[0] === "max", f = dn(e, l[0], n, r, i), p = dn(e, l[1], n, r, i);
|
|
1172
1203
|
if (u) {
|
|
1173
|
-
let t =
|
|
1204
|
+
let t = Ke(dn(e, "min", n), p, c);
|
|
1174
1205
|
a = t < f ? f : t;
|
|
1175
1206
|
} else if (d) {
|
|
1176
|
-
let t =
|
|
1207
|
+
let t = Ke(dn(e, "max", n), p, c);
|
|
1177
1208
|
a = t > f ? f : t;
|
|
1178
|
-
} else a =
|
|
1179
|
-
} else a =
|
|
1209
|
+
} else a = Ke(f, p, c);
|
|
1210
|
+
} else a = dn(e, t, n, r, i);
|
|
1180
1211
|
} else a = t;
|
|
1181
|
-
return
|
|
1182
|
-
},
|
|
1212
|
+
return W(a, 0);
|
|
1213
|
+
}, pn = (e) => {
|
|
1183
1214
|
let t, n = e.targets;
|
|
1184
1215
|
for (let e = 0, r = n.length; e < r; e++) {
|
|
1185
1216
|
let r = n[e];
|
|
@@ -1189,7 +1220,7 @@ var Qt = (e, t) => {
|
|
|
1189
1220
|
}
|
|
1190
1221
|
}
|
|
1191
1222
|
return t;
|
|
1192
|
-
},
|
|
1223
|
+
}, mn = 0, hn = [
|
|
1193
1224
|
"#FF4B4B",
|
|
1194
1225
|
"#FF971B",
|
|
1195
1226
|
"#FFC730",
|
|
@@ -1204,14 +1235,14 @@ var Qt = (e, t) => {
|
|
|
1204
1235
|
"#C563FE",
|
|
1205
1236
|
"#FF4FCF",
|
|
1206
1237
|
"#F93F8A"
|
|
1207
|
-
],
|
|
1238
|
+
], gn = class {
|
|
1208
1239
|
constructor(e = {}) {
|
|
1209
|
-
|
|
1210
|
-
let t =
|
|
1240
|
+
P.current && P.current.register(this);
|
|
1241
|
+
let t = q(e.sync, "play pause"), n = t ? It(t) : null, r = t && (t === "linear" || t === Et), i = t && !(n === Et && !r), a = t && (L(t) || t === !0 || r), o = t && R(t) && !i && !a, c = o ? t.split(" ").map((e) => () => {
|
|
1211
1242
|
let t = this.linked;
|
|
1212
1243
|
return t && t[e] ? t[e]() : null;
|
|
1213
1244
|
}) : null, l = o && c.length > 2;
|
|
1214
|
-
this.index =
|
|
1245
|
+
this.index = mn++, this.id = B(e.id) ? this.index : e.id, this.container = un(e.container), this.target = null, this.linked = null, this.repeat = null, this.horizontal = null, this.enter = null, this.leave = null, this.sync = i || a || !!c, this.syncEase = i ? n : null, this.syncSmooth = a ? t === !0 || r ? 1 : t : null, this.onSyncEnter = c && !l && c[0] ? c[0] : w, this.onSyncLeave = c && !l && c[1] ? c[1] : w, this.onSyncEnterForward = c && l && c[0] ? c[0] : w, this.onSyncLeaveForward = c && l && c[1] ? c[1] : w, this.onSyncEnterBackward = c && l && c[2] ? c[2] : w, this.onSyncLeaveBackward = c && l && c[3] ? c[3] : w, this.onEnter = e.onEnter || w, this.onLeave = e.onLeave || w, this.onEnterForward = e.onEnterForward || w, this.onLeaveForward = e.onLeaveForward || w, this.onEnterBackward = e.onEnterBackward || w, this.onLeaveBackward = e.onLeaveBackward || w, this.onUpdate = e.onUpdate || w, this.onResize = e.onResize || w, this.onSyncComplete = e.onSyncComplete || w, this.reverted = !1, this.ready = !1, this.completed = !1, this.began = !1, this.isInView = !1, this.forceEnter = !1, this.hasEntered = !1, this.offset = 0, this.offsetStart = 0, this.offsetEnd = 0, this.distance = 0, this.prevProgress = 0, this.thresholds = [
|
|
1215
1246
|
"start",
|
|
1216
1247
|
"end",
|
|
1217
1248
|
"end",
|
|
@@ -1221,10 +1252,10 @@ var Qt = (e, t) => {
|
|
|
1221
1252
|
0,
|
|
1222
1253
|
0,
|
|
1223
1254
|
0
|
|
1224
|
-
], this.debugStyles = null, this.$debug = null, this._params = e, this._debug =
|
|
1255
|
+
], this.debugStyles = null, this.$debug = null, this._params = e, this._debug = q(e.debug, !1), this._next = null, this._prev = null, Me(this.container, this), rn(() => {
|
|
1225
1256
|
if (!this.reverted) {
|
|
1226
1257
|
if (!this.target) {
|
|
1227
|
-
let t =
|
|
1258
|
+
let t = xt(e.target)[0];
|
|
1228
1259
|
this.target = t || s.body, this.refresh();
|
|
1229
1260
|
}
|
|
1230
1261
|
this._debug && this.debug();
|
|
@@ -1232,11 +1263,11 @@ var Qt = (e, t) => {
|
|
|
1232
1263
|
});
|
|
1233
1264
|
}
|
|
1234
1265
|
link(e) {
|
|
1235
|
-
if (e && (e.pause(), this.linked = e, !
|
|
1266
|
+
if (e && (e.pause(), this.linked = e, !B(e) && !B(e.persist) && (e.persist = !0), !this._params.target)) {
|
|
1236
1267
|
let t;
|
|
1237
|
-
|
|
1238
|
-
e.targets && !t && (t =
|
|
1239
|
-
}) : t =
|
|
1268
|
+
B(e.targets) ? K(e, (e) => {
|
|
1269
|
+
e.targets && !t && (t = pn(e));
|
|
1270
|
+
}) : t = pn(e), this.target = t || s.body, this.refresh();
|
|
1240
1271
|
}
|
|
1241
1272
|
return this;
|
|
1242
1273
|
}
|
|
@@ -1251,19 +1282,19 @@ var Qt = (e, t) => {
|
|
|
1251
1282
|
}
|
|
1252
1283
|
get progress() {
|
|
1253
1284
|
let e = (this.scroll - this.offsetStart) / this.distance;
|
|
1254
|
-
return e === Infinity || isNaN(e) ? 0 :
|
|
1285
|
+
return e === Infinity || isNaN(e) ? 0 : W(U(e, 0, 1), 6);
|
|
1255
1286
|
}
|
|
1256
1287
|
refresh() {
|
|
1257
1288
|
this.ready = !0, this.reverted = !1;
|
|
1258
1289
|
let e = this._params;
|
|
1259
|
-
return this.repeat =
|
|
1290
|
+
return this.repeat = q(sn(e.repeat, this), !0), this.horizontal = q(sn(e.axis, this), "y") === "x", this.enter = q(sn(e.enter, this), "end start"), this.leave = q(sn(e.leave, this), "start end"), this.updateBounds(), this.handleScroll(), this;
|
|
1260
1291
|
}
|
|
1261
1292
|
removeDebug() {
|
|
1262
1293
|
return this.$debug &&= (this.$debug.parentNode.removeChild(this.$debug), null), this.debugStyles && (this.debugStyles.revert(), this.$debug = null), this;
|
|
1263
1294
|
}
|
|
1264
1295
|
debug() {
|
|
1265
1296
|
this.removeDebug();
|
|
1266
|
-
let e = this.container, t = this.horizontal, n = e.element.querySelector(":scope > .animejs-onscroll-debug"), r = s.createElement("div"), i = s.createElement("div"), a = s.createElement("div"), o =
|
|
1297
|
+
let e = this.container, t = this.horizontal, n = e.element.querySelector(":scope > .animejs-onscroll-debug"), r = s.createElement("div"), i = s.createElement("div"), a = s.createElement("div"), o = hn[this.index % hn.length], c = e.useWin, l = c ? e.winWidth : e.width, u = c ? e.winHeight : e.height, d = e.scrollWidth, f = e.scrollHeight, p = this.container.width > 360 ? 320 : 260, m = t ? 0 : 10, h = t ? 10 : 0, g = t ? 24 : p / 2, _ = t ? g : 15, v = t ? 60 : g, y = t ? v : _, b = t ? "repeat-x" : "repeat-y", x = (e) => t ? "0px " + e + "px" : e + "px 2px", S = (e) => `linear-gradient(${t ? 90 : 0}deg, ${e} 2px, transparent 1px)`, C = (e, t, n, r, i) => `position:${e};left:${t}px;top:${n}px;width:${r}px;height:${i}px;`;
|
|
1267
1298
|
r.style.cssText = `${C("absolute", m, h, t ? d : p, t ? p : f)}
|
|
1268
1299
|
pointer-events: none;
|
|
1269
1300
|
z-index: ${this.container.zIndex++};
|
|
@@ -1308,31 +1339,31 @@ var Qt = (e, t) => {
|
|
|
1308
1339
|
`, x.appendChild(S);
|
|
1309
1340
|
let D = c - E + +!!t;
|
|
1310
1341
|
x.style[t ? "left" : "top"] = `${D}px`, (r ? i : a).appendChild(x);
|
|
1311
|
-
}), r.appendChild(i), r.appendChild(a), e.element.appendChild(r), n || r.classList.add("animejs-onscroll-debug"), this.$debug = r,
|
|
1342
|
+
}), r.appendChild(i), r.appendChild(a), e.element.appendChild(r), n || r.classList.add("animejs-onscroll-debug"), this.$debug = r, tn(e.element, "position") === "static" && (this.debugStyles = nn(e.element, { position: "relative " }));
|
|
1312
1343
|
}
|
|
1313
1344
|
updateBounds() {
|
|
1314
1345
|
this._debug && this.removeDebug();
|
|
1315
1346
|
let e, t = this.target, n = this.container, r = this.horizontal, i = this.linked, a, o = t;
|
|
1316
1347
|
for (i && (a = i.currentTime, i.seek(0, !0)); o && o !== n.element && o !== s.body;) {
|
|
1317
|
-
let t =
|
|
1348
|
+
let t = tn(o, "position") === "sticky" && nn(o, { position: "static" });
|
|
1318
1349
|
o = o.parentElement, t && (e ||= [], e.push(t));
|
|
1319
1350
|
}
|
|
1320
1351
|
let c = t.getBoundingClientRect(), l = n.scale, u = (r ? c.left + n.scrollX - n.left : c.top + n.scrollY - n.top) * l, d = (r ? c.width : c.height) * l, f = r ? n.width : n.height, p = (r ? n.scrollWidth : n.scrollHeight) - f, m = this.enter, h = this.leave, g = "start", _ = "end", v = "end", y = "start";
|
|
1321
|
-
if (
|
|
1352
|
+
if (R(m)) {
|
|
1322
1353
|
let e = m.split(" ");
|
|
1323
1354
|
v = e[0], g = e.length > 1 ? e[1] : g;
|
|
1324
|
-
} else if (
|
|
1355
|
+
} else if (ce(m)) {
|
|
1325
1356
|
let e = m;
|
|
1326
|
-
|
|
1327
|
-
} else
|
|
1328
|
-
if (
|
|
1357
|
+
B(e.container) || (v = e.container), B(e.target) || (g = e.target);
|
|
1358
|
+
} else L(m) && (v = m);
|
|
1359
|
+
if (R(h)) {
|
|
1329
1360
|
let e = h.split(" ");
|
|
1330
1361
|
y = e[0], _ = e.length > 1 ? e[1] : _;
|
|
1331
|
-
} else if (
|
|
1362
|
+
} else if (ce(h)) {
|
|
1332
1363
|
let e = h;
|
|
1333
|
-
|
|
1334
|
-
} else
|
|
1335
|
-
let b =
|
|
1364
|
+
B(e.container) || (y = e.container), B(e.target) || (_ = e.target);
|
|
1365
|
+
} else L(h) && (y = h);
|
|
1366
|
+
let b = fn(t, g, d), x = fn(t, _, d), S = b + u - f, C = x + u - p, w = fn(t, v, f, S, C), T = fn(t, y, f, S, C), E = b + u - w, D = x + u - T, O = D - E;
|
|
1336
1367
|
this.offset = u, this.offsetStart = E, this.offsetEnd = D, this.distance = O <= 0 ? 0 : O, this.thresholds = [
|
|
1337
1368
|
g,
|
|
1338
1369
|
_,
|
|
@@ -1350,10 +1381,10 @@ var Qt = (e, t) => {
|
|
|
1350
1381
|
let e = this.linked, t = this.sync, n = this.syncEase, r = this.syncSmooth, i = e && (n || r), a = this.horizontal, o = this.container, s = this.scroll, c = s <= this.offsetStart, l = s >= this.offsetEnd, u = !c && !l, d = s === this.offsetStart || s === this.offsetEnd, f = !this.hasEntered && d, p = this._debug && this.$debug, m = !1, h = !1, g = this.progress;
|
|
1351
1382
|
if (c && this.began && (this.began = !1), g > 0 && !this.began && (this.began = !0), i) {
|
|
1352
1383
|
let t = e.progress;
|
|
1353
|
-
if (r &&
|
|
1384
|
+
if (r && L(r)) {
|
|
1354
1385
|
if (r < 1) {
|
|
1355
1386
|
let e = t < g && g === 1 ? 1e-4 : t > g && !g ? -1e-4 : 0;
|
|
1356
|
-
g =
|
|
1387
|
+
g = W(De(t, g, De(.01, .2, r)) + e, 6);
|
|
1357
1388
|
}
|
|
1358
1389
|
} else n && (g = n(g));
|
|
1359
1390
|
m = g !== this.prevProgress, h = t === 1, m && !h && r && t && o.wakeTicker.restart();
|
|
@@ -1367,37 +1398,219 @@ var Qt = (e, t) => {
|
|
|
1367
1398
|
revert() {
|
|
1368
1399
|
if (this.reverted) return;
|
|
1369
1400
|
let e = this.container;
|
|
1370
|
-
return
|
|
1401
|
+
return je(e, this), e._head || e.revert(), this._debug && this.removeDebug(), this.reverted = !0, this.ready = !1, this;
|
|
1402
|
+
}
|
|
1403
|
+
}, _n = (e = {}) => new gn(e), vn = (e = 10, t) => {
|
|
1404
|
+
let n = t ? Se : Ce;
|
|
1405
|
+
return (t) => n(U(t, 0, 1) * e) * (1 / e);
|
|
1406
|
+
}, yn = (e, t = 100) => {
|
|
1407
|
+
let n = [];
|
|
1408
|
+
for (let r = 0; r <= t; r++) n.push(W(e(r / t), 4));
|
|
1409
|
+
return `linear(${n.join(", ")})`;
|
|
1410
|
+
}, bn = {}, xn = (e) => {
|
|
1411
|
+
let t = bn[e];
|
|
1412
|
+
if (t) return t;
|
|
1413
|
+
if (t = "linear", R(e)) {
|
|
1414
|
+
if (I(e, "linear") || I(e, "cubic-") || I(e, "steps") || I(e, "ease")) t = e;
|
|
1415
|
+
else if (I(e, "cubicB")) t = ae(e);
|
|
1416
|
+
else {
|
|
1417
|
+
let n = Pt(e);
|
|
1418
|
+
z(n) && (t = n === Et ? "linear" : yn(n));
|
|
1419
|
+
}
|
|
1420
|
+
bn[e] = t;
|
|
1421
|
+
} else if (z(e)) {
|
|
1422
|
+
let n = yn(e);
|
|
1423
|
+
n && (t = n);
|
|
1424
|
+
} else e.ease && (t = yn(e.ease));
|
|
1425
|
+
return t;
|
|
1426
|
+
}, Sn = [
|
|
1427
|
+
"x",
|
|
1428
|
+
"y",
|
|
1429
|
+
"z"
|
|
1430
|
+
], Cn = [
|
|
1431
|
+
"perspective",
|
|
1432
|
+
"width",
|
|
1433
|
+
"height",
|
|
1434
|
+
"margin",
|
|
1435
|
+
"padding",
|
|
1436
|
+
"top",
|
|
1437
|
+
"right",
|
|
1438
|
+
"bottom",
|
|
1439
|
+
"left",
|
|
1440
|
+
"borderWidth",
|
|
1441
|
+
"fontSize",
|
|
1442
|
+
"borderRadius",
|
|
1443
|
+
...Sn
|
|
1444
|
+
], wn = [...Sn, ...S.filter((e) => [
|
|
1445
|
+
"X",
|
|
1446
|
+
"Y",
|
|
1447
|
+
"Z"
|
|
1448
|
+
].some((t) => e.endsWith(t)))], Tn = null, En = (e, t, n, r, i) => {
|
|
1449
|
+
let a = R(t) ? t : J(t, n, r, i, null, null);
|
|
1450
|
+
return L(a) ? Cn.includes(e) || I(e, "translate") ? `${a}px` : I(e, "rotate") || I(e, "skew") ? `${a}deg` : `${a}` : a;
|
|
1451
|
+
}, Dn = (e, t, n, r, i, a) => {
|
|
1452
|
+
let o = "0", s = B(r) ? getComputedStyle(e)[t] : En(t, r, e, i, a);
|
|
1453
|
+
return o = B(n) ? se(r) ? r.map((n) => En(t, n, e, i, a)) : s : [En(t, n, e, i, a), s], o;
|
|
1454
|
+
}, On = class {
|
|
1455
|
+
constructor(e, t) {
|
|
1456
|
+
P.current && P.current.register(this), le(Tn) && (a && (B(CSS) || !Object.hasOwnProperty.call(CSS, "registerProperty")) ? Tn = !1 : (S.forEach((e) => {
|
|
1457
|
+
let t = I(e, "skew"), n = I(e, "scale"), r = I(e, "rotate"), i = I(e, "translate"), a = r || t, o = a ? "<angle>" : n ? "<number>" : i ? "<length-percentage>" : "*";
|
|
1458
|
+
try {
|
|
1459
|
+
CSS.registerProperty({
|
|
1460
|
+
name: "--" + e,
|
|
1461
|
+
syntax: o,
|
|
1462
|
+
inherits: !1,
|
|
1463
|
+
initialValue: i ? "0px" : a ? "0deg" : n ? "1" : "0"
|
|
1464
|
+
});
|
|
1465
|
+
} catch {}
|
|
1466
|
+
}), Tn = !0));
|
|
1467
|
+
let n = St(e);
|
|
1468
|
+
n.length || console.warn("No target found. Make sure the element you're trying to animate is accessible before creating your animation.");
|
|
1469
|
+
let r = q(t.autoplay, F.defaults.autoplay), i = r && r.link ? r : !1, o = t.alternate && t.alternate === !0, s = t.reversed && t.reversed === !0, c = q(t.loop, F.defaults.loop), l = c === !0 || c === Infinity ? Infinity : L(c) ? c + 1 : 1, u = o ? s ? "alternate-reverse" : "alternate" : s ? "reverse" : "normal", d = F.timeScale === 1 ? 1 : y;
|
|
1470
|
+
this.targets = n, this.animations = [], this.controlAnimation = null, this.onComplete = t.onComplete || F.defaults.onComplete, this.duration = 0, this.muteCallbacks = !1, this.completed = !1, this.paused = !r || i !== !1, this.reversed = s, this.persist = q(t.persist, F.defaults.persist), this.autoplay = r, this._speed = q(t.playbackRate, F.defaults.playbackRate), this._resolve = w, this._completed = 0, this._inlineStyles = [], n.forEach((e, r) => {
|
|
1471
|
+
let i = e[h], a = wn.some((e) => t.hasOwnProperty(e)), o = e.style, s = this._inlineStyles[r] = {}, c = q(t.ease, F.defaults.ease), f = J(c, e, r, n, null, null), p = z(f) || R(f) ? f : c, m = c.ease && c, g = xn(p), _ = (m ? m.settlingDuration : J(q(t.duration, F.defaults.duration), e, r, n, null, null)) * d, v = J(q(t.delay, F.defaults.delay), e, r, n, null, null) * d, y = q(t.composition, "replace");
|
|
1472
|
+
for (let c in t) {
|
|
1473
|
+
if (!me(c)) continue;
|
|
1474
|
+
let f = {}, p = {
|
|
1475
|
+
iterations: l,
|
|
1476
|
+
direction: u,
|
|
1477
|
+
fill: "both",
|
|
1478
|
+
easing: g,
|
|
1479
|
+
duration: _,
|
|
1480
|
+
delay: v,
|
|
1481
|
+
composite: y
|
|
1482
|
+
}, m = t[c], h = a ? S.includes(c) ? c : x.get(c) : !1, b = h ? "transform" : c;
|
|
1483
|
+
s[b] || (s[b] = o[b]);
|
|
1484
|
+
let C;
|
|
1485
|
+
if (ce(m)) {
|
|
1486
|
+
let t = m, a = q(t.ease, g), s = a.ease && a, l = t.to, u = t.from;
|
|
1487
|
+
if (p.duration = (s ? s.settlingDuration : J(q(t.duration, _), e, r, n, null, null)) * d, p.delay = J(q(t.delay, v), e, r, n, null, null) * d, p.composite = q(t.composition, y), p.easing = xn(a), C = Dn(e, c, u, l, r, n), h ? (f[`--${h}`] = C, i[h] = C) : f[c] = Dn(e, c, u, l, r, n), en(this, e, c, f, p), !B(u)) {
|
|
1488
|
+
if (!h) o[c] = f[c][0];
|
|
1489
|
+
else {
|
|
1490
|
+
let e = `--${h}`;
|
|
1491
|
+
o.setProperty(e, f[e][0]);
|
|
1492
|
+
}
|
|
1493
|
+
}
|
|
1494
|
+
} else C = se(m) ? m.map((t) => En(c, t, e, r, n)) : En(c, m, e, r, n), h ? (f[`--${h}`] = C, i[h] = C) : f[c] = C, en(this, e, c, f, p);
|
|
1495
|
+
}
|
|
1496
|
+
if (a) {
|
|
1497
|
+
let e = "";
|
|
1498
|
+
for (let t in i) e += `${C[t]}var(--${t})) `;
|
|
1499
|
+
o.transform = e;
|
|
1500
|
+
}
|
|
1501
|
+
}), i && this.autoplay.link(this);
|
|
1502
|
+
}
|
|
1503
|
+
forEach(e) {
|
|
1504
|
+
try {
|
|
1505
|
+
let t = R(e) ? (t) => t[e]() : e;
|
|
1506
|
+
this.animations.forEach(t);
|
|
1507
|
+
} catch {}
|
|
1508
|
+
return this;
|
|
1509
|
+
}
|
|
1510
|
+
get speed() {
|
|
1511
|
+
return this._speed;
|
|
1512
|
+
}
|
|
1513
|
+
set speed(e) {
|
|
1514
|
+
this._speed = +e, this.forEach((t) => t.playbackRate = e);
|
|
1515
|
+
}
|
|
1516
|
+
get currentTime() {
|
|
1517
|
+
let e = this.controlAnimation, t = F.timeScale;
|
|
1518
|
+
return this.completed ? this.duration : e ? +e.currentTime * (t === 1 ? 1 : t) : 0;
|
|
1519
|
+
}
|
|
1520
|
+
set currentTime(e) {
|
|
1521
|
+
let t = e * (F.timeScale === 1 ? 1 : y);
|
|
1522
|
+
this.forEach((e) => {
|
|
1523
|
+
!this.persist && t >= this.duration && e.play(), e.currentTime = t;
|
|
1524
|
+
});
|
|
1525
|
+
}
|
|
1526
|
+
get progress() {
|
|
1527
|
+
return this.currentTime / this.duration;
|
|
1528
|
+
}
|
|
1529
|
+
set progress(e) {
|
|
1530
|
+
this.forEach((t) => t.currentTime = e * this.duration || 0);
|
|
1531
|
+
}
|
|
1532
|
+
resume() {
|
|
1533
|
+
return this.paused ? (this.paused = !1, this.forEach("play")) : this;
|
|
1534
|
+
}
|
|
1535
|
+
pause() {
|
|
1536
|
+
return this.paused ? this : (this.paused = !0, this.forEach("pause"));
|
|
1537
|
+
}
|
|
1538
|
+
alternate() {
|
|
1539
|
+
return this.reversed = !this.reversed, this.forEach("reverse"), this.paused && this.forEach("pause"), this;
|
|
1540
|
+
}
|
|
1541
|
+
play() {
|
|
1542
|
+
return this.reversed && this.alternate(), this.resume();
|
|
1543
|
+
}
|
|
1544
|
+
reverse() {
|
|
1545
|
+
return this.reversed || this.alternate(), this.resume();
|
|
1546
|
+
}
|
|
1547
|
+
seek(e, t = !1) {
|
|
1548
|
+
return t && (this.muteCallbacks = !0), e < this.duration && (this.completed = !1), this.currentTime = e, this.muteCallbacks = !1, this.paused && this.pause(), this;
|
|
1549
|
+
}
|
|
1550
|
+
restart() {
|
|
1551
|
+
return this.completed = !1, this.seek(0, !0).resume();
|
|
1552
|
+
}
|
|
1553
|
+
commitStyles() {
|
|
1554
|
+
return this.forEach("commitStyles");
|
|
1555
|
+
}
|
|
1556
|
+
complete() {
|
|
1557
|
+
return this.seek(this.duration);
|
|
1558
|
+
}
|
|
1559
|
+
cancel() {
|
|
1560
|
+
return this.muteCallbacks = !0, this.commitStyles().forEach("cancel"), this.animations.length = 0, requestAnimationFrame(() => {
|
|
1561
|
+
this.targets.forEach((e) => {
|
|
1562
|
+
e.style.transform === "none" && e.style.removeProperty("transform");
|
|
1563
|
+
});
|
|
1564
|
+
}), this;
|
|
1565
|
+
}
|
|
1566
|
+
revert() {
|
|
1567
|
+
return this.cancel().targets.forEach((e, t) => {
|
|
1568
|
+
let n = e.style, r = this._inlineStyles[t];
|
|
1569
|
+
for (let t in r) {
|
|
1570
|
+
let i = r[t];
|
|
1571
|
+
B(i) || i === "" ? n.removeProperty(ae(t)) : e.style[t] = i;
|
|
1572
|
+
}
|
|
1573
|
+
e.getAttribute("style") === "" && e.removeAttribute("style");
|
|
1574
|
+
}), this;
|
|
1575
|
+
}
|
|
1576
|
+
then(e = w) {
|
|
1577
|
+
let t = this.then, n = () => {
|
|
1578
|
+
this.then = null, e(this), this.then = t, this._resolve = w;
|
|
1579
|
+
};
|
|
1580
|
+
return new Promise((e) => (this._resolve = () => e(n()), this.completed && this._resolve(), this));
|
|
1371
1581
|
}
|
|
1372
|
-
},
|
|
1582
|
+
}, kn = {
|
|
1583
|
+
animate: (e, t) => new On(e, t),
|
|
1584
|
+
convertEase: yn
|
|
1585
|
+
}, An = (e = 0, t = 1, n = 0) => {
|
|
1373
1586
|
let r = 10 ** n;
|
|
1374
1587
|
return Math.floor((Math.random() * (t - e + 1 / r) + e) * r) / r;
|
|
1375
|
-
},
|
|
1376
|
-
let i = e === void 0 ?
|
|
1588
|
+
}, jn = 0, Mn = (e, t = 0, n = 1, r = 0) => {
|
|
1589
|
+
let i = e === void 0 ? jn++ : e;
|
|
1377
1590
|
return (e = t, a = n, o = r) => {
|
|
1378
1591
|
i += 1831565813, i = Math.imul(i ^ i >>> 15, i | 1), i ^= i + Math.imul(i ^ i >>> 7, i | 61);
|
|
1379
1592
|
let s = 10 ** o;
|
|
1380
1593
|
return Math.floor((((i ^ i >>> 14) >>> 0) / 4294967296 * (a - e + 1 / s) + e) * s) / s;
|
|
1381
1594
|
};
|
|
1382
|
-
},
|
|
1595
|
+
}, Nn = (e, t = An) => {
|
|
1383
1596
|
let n = e.length, r, i;
|
|
1384
1597
|
for (; n;) i = t(0, --n), r = e[n], e[n] = e[i], e[i] = r;
|
|
1385
1598
|
return e;
|
|
1386
|
-
},
|
|
1387
|
-
let n = [], r = 0, i, a = null, o = t.from, s = t.reversed, c = t.ease, l = !
|
|
1599
|
+
}, Pn = (e, t = {}) => {
|
|
1600
|
+
let n = [], r = 0, i, a = null, o = t.from, s = t.reversed, c = t.ease, l = !B(c), u = l && !B(c.ease) ? c.ease : l ? It(c) : null, d = t.grid, f = d === !0, p = t.axis, m = t.total, h = B(o) || o === 0 || o === "first", g = o === "center", _ = o === "last", v = o === "random", y = se(o), b = se(e), x = t.use, S = _e(b ? e[0] : e), C = b ? _e(e[1]) : 0, w = re.exec((b ? e[1] : e) + ""), T = t.start || 0 + (b ? S : 0), E = t.seed, D = !B(E) && E !== !1 ? Mn(E === !0 ? 0 : E) : An, O = t.jitter, ee = !B(O), k = se(O), te = k ? O[0] : O || 0, ne = k ? O[1] : O || 0, A = h ? 0 : L(o) ? o : 0;
|
|
1388
1601
|
return (e, c, l, h, E) => {
|
|
1389
|
-
let [O] =
|
|
1390
|
-
if (g && (
|
|
1602
|
+
let [O] = St(e), k = B(m) ? l.length : m, re = B(x) ? !1 : z(x) ? x(O, c, k) : Ge(O, x), j = L(re) || R(re) && L(+re) ? +re : c, M = j >= 0 && j < k ? j : c;
|
|
1603
|
+
if (g && (A = (k - 1) / 2), _ && (A = k - 1), !n.length) {
|
|
1391
1604
|
if (f) {
|
|
1392
1605
|
let e = !0, t = !1, r = Infinity, i = Infinity, a = Infinity, s = -Infinity, c = -Infinity, u = -Infinity, d = [], f = [], m = [];
|
|
1393
1606
|
for (let n = 0; n < k; n++) {
|
|
1394
1607
|
let o = l[n], p = 0, h = 0, g = 0, _ = !1;
|
|
1395
|
-
if (o &&
|
|
1608
|
+
if (o && z(o.getBoundingClientRect)) {
|
|
1396
1609
|
let e = o.getBoundingClientRect();
|
|
1397
1610
|
p = e.left + e.width / 2, h = e.top + e.height / 2, _ = !0;
|
|
1398
1611
|
} else {
|
|
1399
1612
|
let e = o;
|
|
1400
|
-
e &&
|
|
1613
|
+
e && L(e.x) && L(e.y) && (p = e.x, h = e.y, L(e.z) && (g = e.z, t = !0), _ = !0);
|
|
1401
1614
|
}
|
|
1402
1615
|
if (!_) {
|
|
1403
1616
|
e = !1;
|
|
@@ -1407,80 +1620,80 @@ var Qt = (e, t) => {
|
|
|
1407
1620
|
}
|
|
1408
1621
|
if (e) {
|
|
1409
1622
|
let e = d[0], l = f[0], h = m[0];
|
|
1410
|
-
y ? (e = r + o[0] * (s - r), l = i + o[1] * (c - i), h = t ? a + (o.length >= 3 ? o[2] : .5) * (u - a) : 0) : g ? (e = (r + s) / 2, l = (i + c) / 2, h = (a + u) / 2) : _ ? (e = d[k - 1], l = f[k - 1], h = m[k - 1]) :
|
|
1623
|
+
y ? (e = r + o[0] * (s - r), l = i + o[1] * (c - i), h = t ? a + (o.length >= 3 ? o[2] : .5) * (u - a) : 0) : g ? (e = (r + s) / 2, l = (i + c) / 2, h = (a + u) / 2) : _ ? (e = d[k - 1], l = f[k - 1], h = m[k - 1]) : L(o) && (e = d[o], l = f[o], h = m[o]);
|
|
1411
1624
|
for (let r = 0; r < k; r++) {
|
|
1412
|
-
let i = e - d[r], a = l - f[r], o = h - m[r], s =
|
|
1625
|
+
let i = e - d[r], a = l - f[r], o = h - m[r], s = ye(i * i + a * a + (t ? o * o : 0));
|
|
1413
1626
|
p === "x" && (s = -i), p === "y" && (s = -a), p === "z" && (s = -o), n.push(s);
|
|
1414
1627
|
}
|
|
1415
1628
|
let v = Infinity;
|
|
1416
1629
|
for (let e = 0; e < k; e++) {
|
|
1417
|
-
let t =
|
|
1630
|
+
let t = xe(n[e]);
|
|
1418
1631
|
t > 0 && t < v && (v = t);
|
|
1419
1632
|
}
|
|
1420
1633
|
if (v > 0 && v < Infinity) for (let e = 0; e < k; e++) n[e] = n[e] / v;
|
|
1421
|
-
} else for (let e = 0; e < k; e++) n.push(
|
|
1422
|
-
} else for (let e = 0; e < k; e++) if (!d) n.push(
|
|
1634
|
+
} else for (let e = 0; e < k; e++) n.push(xe(A - e));
|
|
1635
|
+
} else for (let e = 0; e < k; e++) if (!d) n.push(xe(A - e));
|
|
1423
1636
|
else {
|
|
1424
1637
|
let t = d.length, r = d[0] * d[1], i, a, s;
|
|
1425
|
-
y ? (i = o[0] * (d[0] - 1), a = o[1] * (d[1] - 1), s = t === 3 ? (o.length >= 3 ? o[2] : .5) * (d[2] - 1) : 0) : g ? (i = (d[0] - 1) / 2, a = (d[1] - 1) / 2, s = t === 3 ? (d[2] - 1) / 2 : 0) : (i =
|
|
1426
|
-
let c = e % d[0], l =
|
|
1638
|
+
y ? (i = o[0] * (d[0] - 1), a = o[1] * (d[1] - 1), s = t === 3 ? (o.length >= 3 ? o[2] : .5) * (d[2] - 1) : 0) : g ? (i = (d[0] - 1) / 2, a = (d[1] - 1) / 2, s = t === 3 ? (d[2] - 1) / 2 : 0) : (i = A % d[0], a = Ce(A / d[0]) % d[1], s = t === 3 ? Ce(A / r) : 0);
|
|
1639
|
+
let c = e % d[0], l = Ce(e / d[0]) % d[1], u = t === 3 ? Ce(e / r) : 0, f = i - c, m = a - l, h = s - u, _ = ye(f * f + m * m + (t === 3 ? h * h : 0));
|
|
1427
1640
|
p === "x" && (_ = -f), p === "y" && (_ = -m), p === "z" && (_ = -h), n.push(_);
|
|
1428
1641
|
}
|
|
1429
1642
|
r = n[0];
|
|
1430
1643
|
for (let e = 1; e < k; e++) n[e] > r && (r = n[e]);
|
|
1431
1644
|
if (u || s) for (let e = 0; e < k; e++) {
|
|
1432
1645
|
let t = n[e];
|
|
1433
|
-
u && (t = u(t / r) * r), s && (t = p ? -t :
|
|
1646
|
+
u && (t = u(t / r) * r), s && (t = p ? -t : xe(r - t)), n[e] = t;
|
|
1434
1647
|
}
|
|
1435
1648
|
if (ee) {
|
|
1436
1649
|
a = Array(k);
|
|
1437
1650
|
for (let e = 0; e < k; e++) a[e] = D(-1, 1, 4);
|
|
1438
1651
|
}
|
|
1439
|
-
v && (n =
|
|
1652
|
+
v && (n = Nn(n, D));
|
|
1440
1653
|
}
|
|
1441
|
-
let
|
|
1442
|
-
|
|
1443
|
-
let
|
|
1654
|
+
let N = b ? (C - S) / r : S;
|
|
1655
|
+
B(i) && (i = E ? Zt(E, B(t.start) ? E.iterationDuration : T) : T);
|
|
1656
|
+
let P = i + (N * W(n[M], 2) || 0);
|
|
1444
1657
|
if (ee) {
|
|
1445
|
-
let e = r ? n[
|
|
1446
|
-
|
|
1658
|
+
let e = r ? n[M] / r : 0, t = te + (ne - te) * e;
|
|
1659
|
+
P += a[M] * t;
|
|
1447
1660
|
}
|
|
1448
|
-
return t.modifier && (
|
|
1661
|
+
return t.modifier && (P = t.modifier(P)), w && (P = `${P}${w[2]}`), P;
|
|
1449
1662
|
};
|
|
1450
|
-
},
|
|
1663
|
+
}, Fn = typeof Intl < "u" && Intl.Segmenter, In = /\{value\}/g, Ln = /\{i\}/g, Rn = /(\s+)/, zn = /^\s+$/, Bn = "line", Vn = "word", Hn = "char", Un = "data-line", Wn = null, Gn = null, Kn = null, qn = (e) => e.isWordLike || e.segment === " " || L(+e.segment), Jn = (e) => e.setAttribute("aria-hidden", "true"), Yn = (e, t) => [...e.querySelectorAll(`[data-${t}]:not([data-${t}] [data-${t}])`)], Xn = {
|
|
1451
1664
|
line: "#00D672",
|
|
1452
1665
|
word: "#FF4B4B",
|
|
1453
1666
|
char: "#5A87FF"
|
|
1454
|
-
},
|
|
1667
|
+
}, Zn = (e) => {
|
|
1455
1668
|
if (!e.childElementCount && !e.textContent.trim()) {
|
|
1456
1669
|
let t = e.parentElement;
|
|
1457
|
-
e.remove(), t &&
|
|
1670
|
+
e.remove(), t && Zn(t);
|
|
1458
1671
|
}
|
|
1459
|
-
},
|
|
1460
|
-
let r = e.getAttribute(
|
|
1672
|
+
}, Qn = (e, t, n) => {
|
|
1673
|
+
let r = e.getAttribute(Un);
|
|
1461
1674
|
if (r !== null && +r !== t || e.tagName === "BR") {
|
|
1462
1675
|
n.add(e);
|
|
1463
1676
|
let t = e.previousSibling, r = e.nextSibling;
|
|
1464
|
-
t && t.nodeType === 3 &&
|
|
1677
|
+
t && t.nodeType === 3 && zn.test(t.textContent) && n.add(t), r && r.nodeType === 3 && zn.test(r.textContent) && n.add(r);
|
|
1465
1678
|
}
|
|
1466
1679
|
let i = e.childElementCount;
|
|
1467
|
-
for (; i--;)
|
|
1680
|
+
for (; i--;) Qn(e.children[i], t, n);
|
|
1468
1681
|
return n;
|
|
1469
|
-
},
|
|
1682
|
+
}, $n = (e, t = {}) => {
|
|
1470
1683
|
let n = "";
|
|
1471
1684
|
t ||= {};
|
|
1472
|
-
let r =
|
|
1685
|
+
let r = R(t.class) ? ` class="${t.class}"` : "", i = q(t.clone, !1), a = q(t.wrap, !1), o = a ? a === !0 ? "clip" : a : i ? "clip" : !1;
|
|
1473
1686
|
if (a && (n += `<span${o ? ` style="overflow:${o};"` : ""}>`), n += `<span${r}${i ? " style=\"position:relative;\"" : ""} data-${e}="{i}">`, i) {
|
|
1474
1687
|
let e = i === "left" ? "-100%" : i === "right" ? "100%" : "0", t = i === "top" ? "-100%" : i === "bottom" ? "100%" : "0";
|
|
1475
1688
|
n += "<span>{value}</span>", n += `<span inert style="position:absolute;top:${t};left:${e};white-space:nowrap;">{value}</span>`;
|
|
1476
1689
|
} else n += "{value}";
|
|
1477
1690
|
return n += "</span>", a && (n += "</span>"), n;
|
|
1478
|
-
},
|
|
1479
|
-
let l = i ===
|
|
1480
|
-
|
|
1481
|
-
let m =
|
|
1691
|
+
}, er = (e, t, n, r, i, a, o, s, c) => {
|
|
1692
|
+
let l = i === Bn, u = i === Hn, d = `_${i}_`, f = z(e) ? e(n) : e, p = l ? "block" : "inline-block";
|
|
1693
|
+
Kn.innerHTML = f.replace(In, `<i class="${d}"></i>`).replace(Ln, `${u ? c : l ? o : s}`);
|
|
1694
|
+
let m = Kn.content, h = m.firstElementChild, g = m.querySelector(`[data-${i}]`) || h, _ = m.querySelectorAll(`i.${d}`), v = _.length;
|
|
1482
1695
|
if (v) {
|
|
1483
|
-
h.style.display = p, g.style.display = p, g.setAttribute(
|
|
1696
|
+
h.style.display = p, g.style.display = p, g.setAttribute(Un, `${o}`), l || (g.setAttribute("data-word", `${s}`), u && g.setAttribute("data-char", `${c}`));
|
|
1484
1697
|
let e = v;
|
|
1485
1698
|
for (; e--;) {
|
|
1486
1699
|
let t = _[e], r = t.parentElement;
|
|
@@ -1488,22 +1701,22 @@ var Qt = (e, t) => {
|
|
|
1488
1701
|
}
|
|
1489
1702
|
t.push(g), r.appendChild(m);
|
|
1490
1703
|
} else console.warn("The expression \"{value}\" is missing from the provided template.");
|
|
1491
|
-
return a && (h.style.outline = `1px dotted ${
|
|
1492
|
-
},
|
|
1704
|
+
return a && (h.style.outline = `1px dotted ${Xn[i]}`), h;
|
|
1705
|
+
}, tr = class {
|
|
1493
1706
|
constructor(e, t = {}) {
|
|
1494
|
-
|
|
1495
|
-
let t = [], n = e.split(
|
|
1707
|
+
Wn ||= Fn ? new Fn([], { granularity: Vn }) : { segment: (e) => {
|
|
1708
|
+
let t = [], n = e.split(Rn);
|
|
1496
1709
|
for (let e = 0, r = n.length; e < r; e++) {
|
|
1497
1710
|
let r = n[e];
|
|
1498
1711
|
t.push({
|
|
1499
1712
|
segment: r,
|
|
1500
|
-
isWordLike: !
|
|
1713
|
+
isWordLike: !zn.test(r)
|
|
1501
1714
|
});
|
|
1502
1715
|
}
|
|
1503
1716
|
return t;
|
|
1504
|
-
} },
|
|
1505
|
-
let { words: n, chars: r, lines: i, accessible: o, includeSpaces: c, debug: l } = t, u = (e =
|
|
1506
|
-
this.debug =
|
|
1717
|
+
} }, Gn ||= Fn ? new Fn([], { granularity: "grapheme" }) : { segment: (e) => [...e].map((e) => ({ segment: e })) }, !Kn && a && (Kn = s.createElement("template")), P.current && P.current.register(this);
|
|
1718
|
+
let { words: n, chars: r, lines: i, accessible: o, includeSpaces: c, debug: l } = t, u = (e = se(e) ? e[0] : e) && e.nodeType ? e : (bt(e) || [])[0], d = i === !0 ? {} : i, f = n === !0 || B(n) ? {} : n, p = r === !0 ? {} : r;
|
|
1719
|
+
this.debug = q(l, !1), this.includeSpaces = q(c, !1), this.accessible = q(o, !0), this.linesOnly = d && !f && !p, this.lineTemplate = ce(d) ? $n(Bn, d) : d, this.wordTemplate = ce(f) || this.linesOnly ? $n(Vn, f) : f, this.charTemplate = ce(p) ? $n(Hn, p) : p, this.$target = u, this.html = u && u.innerHTML, this.lines = [], this.words = [], this.chars = [], this.effects = [], this.effectsCleanups = [], this.cache = null, this.ready = !1, this.width = 0, this.resizeTimeout = null;
|
|
1507
1720
|
let m = () => this.html && (d || f || p) && this.split();
|
|
1508
1721
|
this.resizeObserver = new ResizeObserver(() => {
|
|
1509
1722
|
clearTimeout(this.resizeTimeout), this.resizeTimeout = setTimeout(() => {
|
|
@@ -1513,40 +1726,40 @@ var Qt = (e, t) => {
|
|
|
1513
1726
|
}), this.lineTemplate && !this.ready ? s.fonts.ready.then(m) : m(), u ? this.resizeObserver.observe(u) : console.warn("No Text Splitter target found.");
|
|
1514
1727
|
}
|
|
1515
1728
|
addEffect(e) {
|
|
1516
|
-
if (!
|
|
1517
|
-
let t =
|
|
1729
|
+
if (!z(e)) return console.warn("Effect must return a function."), this;
|
|
1730
|
+
let t = an(e);
|
|
1518
1731
|
return this.effects.push(t), this.ready && (this.effectsCleanups[this.effects.length - 1] = t(this)), this;
|
|
1519
1732
|
}
|
|
1520
1733
|
revert() {
|
|
1521
|
-
return clearTimeout(this.resizeTimeout), this.lines.length = this.words.length = this.chars.length = 0, this.resizeObserver.disconnect(), this.effectsCleanups.forEach((e) =>
|
|
1734
|
+
return clearTimeout(this.resizeTimeout), this.lines.length = this.words.length = this.chars.length = 0, this.resizeObserver.disconnect(), this.effectsCleanups.forEach((e) => z(e) ? e(this) : e.revert && e.revert()), this.$target.innerHTML = this.html, this;
|
|
1522
1735
|
}
|
|
1523
1736
|
splitNode(e) {
|
|
1524
1737
|
let t = this.wordTemplate, n = this.charTemplate, r = this.includeSpaces, i = this.debug, a = e.nodeType;
|
|
1525
1738
|
if (a === 3) {
|
|
1526
1739
|
let a = e.nodeValue;
|
|
1527
1740
|
if (a.trim()) {
|
|
1528
|
-
let o = [], c = this.words, l = this.chars, u =
|
|
1741
|
+
let o = [], c = this.words, l = this.chars, u = Wn.segment(a), d = s.createDocumentFragment(), f = null;
|
|
1529
1742
|
for (let e of u) {
|
|
1530
|
-
let t = e.segment, n =
|
|
1531
|
-
if (!f || n && f &&
|
|
1743
|
+
let t = e.segment, n = qn(e);
|
|
1744
|
+
if (!f || n && f && qn(f)) o.push(t);
|
|
1532
1745
|
else {
|
|
1533
1746
|
let e = o.length - 1, n = o[e];
|
|
1534
|
-
!
|
|
1747
|
+
!Rn.test(n) && !Rn.test(t) ? o[e] += t : o.push(t);
|
|
1535
1748
|
}
|
|
1536
1749
|
f = e;
|
|
1537
1750
|
}
|
|
1538
1751
|
for (let e = 0, a = o.length; e < a; e++) {
|
|
1539
1752
|
let a = o[e];
|
|
1540
1753
|
if (a.trim()) {
|
|
1541
|
-
let u = o[e + 1], f = r && u && !u.trim(), p = a, m = n ?
|
|
1754
|
+
let u = o[e + 1], f = r && u && !u.trim(), p = a, m = n ? Gn.segment(p) : null, h = n ? s.createDocumentFragment() : s.createTextNode(f ? a + "\xA0" : a);
|
|
1542
1755
|
if (n) {
|
|
1543
1756
|
let e = [...m];
|
|
1544
1757
|
for (let t = 0, r = e.length; t < r; t++) {
|
|
1545
1758
|
let a = e[t], o = t === r - 1 && f ? a.segment + "\xA0" : a.segment;
|
|
1546
|
-
|
|
1759
|
+
er(n, l, s.createTextNode(o), h, Hn, i, -1, c.length, l.length);
|
|
1547
1760
|
}
|
|
1548
1761
|
}
|
|
1549
|
-
t ?
|
|
1762
|
+
t ? er(t, c, h, d, Vn, i, -1, c.length, l.length) : n ? d.appendChild(h) : d.appendChild(s.createTextNode(a)), f && e++;
|
|
1550
1763
|
} else {
|
|
1551
1764
|
if (e && r) continue;
|
|
1552
1765
|
d.appendChild(s.createTextNode(a));
|
|
@@ -1561,27 +1774,27 @@ var Qt = (e, t) => {
|
|
|
1561
1774
|
}
|
|
1562
1775
|
split(e = !1) {
|
|
1563
1776
|
let t = this.$target, n = !!this.cache && !e, r = this.lineTemplate, i = this.wordTemplate, a = this.charTemplate, o = s.fonts.status !== "loading", c = r && o;
|
|
1564
|
-
this.ready = !r || o, (c || e) && this.effectsCleanups.forEach((e) =>
|
|
1777
|
+
this.ready = !r || o, (c || e) && this.effectsCleanups.forEach((e) => z(e) && e(this)), n || (e && (t.innerHTML = this.html, this.words.length = this.chars.length = 0), this.splitNode(t), this.cache = t.innerHTML), c && (n && (t.innerHTML = this.cache), this.lines.length = 0, i && (this.words = Yn(t, Vn))), a && (c || i) && (this.chars = Yn(t, Hn));
|
|
1565
1778
|
let l = this.words.length ? this.words : this.chars, u, d = 0;
|
|
1566
1779
|
for (let e = 0, t = l.length; e < t; e++) {
|
|
1567
1780
|
let t = l[e], { top: n, height: r } = t.getBoundingClientRect();
|
|
1568
|
-
!
|
|
1569
|
-
let i = t.querySelectorAll(`[${
|
|
1570
|
-
for (; a--;) i[a].setAttribute(
|
|
1781
|
+
!B(u) && n - u > r * .5 && d++, t.setAttribute(Un, `${d}`);
|
|
1782
|
+
let i = t.querySelectorAll(`[${Un}]`), a = i.length;
|
|
1783
|
+
for (; a--;) i[a].setAttribute(Un, `${d}`);
|
|
1571
1784
|
u = n;
|
|
1572
1785
|
}
|
|
1573
1786
|
if (c) {
|
|
1574
1787
|
let e = s.createDocumentFragment(), n = /* @__PURE__ */ new Set(), o = [];
|
|
1575
1788
|
for (let e = 0; e < d + 1; e++) {
|
|
1576
1789
|
let r = t.cloneNode(!0);
|
|
1577
|
-
|
|
1790
|
+
Qn(r, e, /* @__PURE__ */ new Set()).forEach((e) => {
|
|
1578
1791
|
let t = e.parentNode;
|
|
1579
1792
|
t && (e.nodeType === 1 && n.add(t), t.removeChild(e));
|
|
1580
1793
|
}), o.push(r);
|
|
1581
1794
|
}
|
|
1582
|
-
n.forEach(
|
|
1583
|
-
for (let t = 0, n = o.length; t < n; t++)
|
|
1584
|
-
t.innerHTML = "", t.appendChild(e), i && (this.words =
|
|
1795
|
+
n.forEach(Zn);
|
|
1796
|
+
for (let t = 0, n = o.length; t < n; t++) er(r, this.lines, o[t], e, Bn, this.debug, t);
|
|
1797
|
+
t.innerHTML = "", t.appendChild(e), i && (this.words = Yn(t, Vn)), a && (this.chars = Yn(t, Hn));
|
|
1585
1798
|
}
|
|
1586
1799
|
if (this.linesOnly) {
|
|
1587
1800
|
let e = this.words, t = e.length;
|
|
@@ -1593,27 +1806,27 @@ var Qt = (e, t) => {
|
|
|
1593
1806
|
}
|
|
1594
1807
|
if (this.accessible && (c || !n)) {
|
|
1595
1808
|
let e = s.createElement("span");
|
|
1596
|
-
e.style.cssText = "position:absolute;overflow:hidden;clip:rect(0 0 0 0);clip-path:inset(50%);width:1px;height:1px;white-space:nowrap;", e.innerHTML = this.html, t.insertBefore(e, t.firstChild), this.lines.forEach(
|
|
1809
|
+
e.style.cssText = "position:absolute;overflow:hidden;clip:rect(0 0 0 0);clip-path:inset(50%);width:1px;height:1px;white-space:nowrap;", e.innerHTML = this.html, t.insertBefore(e, t.firstChild), this.lines.forEach(Jn), this.words.forEach(Jn), this.chars.forEach(Jn);
|
|
1597
1810
|
}
|
|
1598
1811
|
return this.width = t.offsetWidth, (c || e) && this.effects.forEach((e, t) => this.effectsCleanups[t] = e(this)), this;
|
|
1599
1812
|
}
|
|
1600
1813
|
refresh() {
|
|
1601
1814
|
this.split(!0);
|
|
1602
1815
|
}
|
|
1603
|
-
},
|
|
1604
|
-
function
|
|
1816
|
+
}, nr = (e, t) => new tr(e, t), rr = "1.3.26";
|
|
1817
|
+
function ir(e, t, n) {
|
|
1605
1818
|
return Math.max(e, Math.min(t, n));
|
|
1606
1819
|
}
|
|
1607
|
-
function
|
|
1820
|
+
function ar(e, t, n) {
|
|
1608
1821
|
return (1 - n) * e + n * t;
|
|
1609
1822
|
}
|
|
1610
|
-
function
|
|
1611
|
-
return
|
|
1823
|
+
function or(e, t, n, r) {
|
|
1824
|
+
return ar(e, t, 1 - Math.exp(-n * r));
|
|
1612
1825
|
}
|
|
1613
|
-
function
|
|
1826
|
+
function sr(e, t) {
|
|
1614
1827
|
return (e % t + t) % t;
|
|
1615
1828
|
}
|
|
1616
|
-
var
|
|
1829
|
+
var cr = class {
|
|
1617
1830
|
isRunning = !1;
|
|
1618
1831
|
value = 0;
|
|
1619
1832
|
from = 0;
|
|
@@ -1628,11 +1841,11 @@ var Kn = class {
|
|
|
1628
1841
|
let t = !1;
|
|
1629
1842
|
if (this.duration && this.easing) {
|
|
1630
1843
|
this.currentTime += e;
|
|
1631
|
-
let n =
|
|
1844
|
+
let n = ir(0, this.currentTime / this.duration, 1);
|
|
1632
1845
|
t = n >= 1;
|
|
1633
1846
|
let r = t ? 1 : this.easing(n);
|
|
1634
1847
|
this.value = this.from + (this.to - this.from) * r;
|
|
1635
|
-
} else this.lerp ? (this.value =
|
|
1848
|
+
} else this.lerp ? (this.value = or(this.value, this.to, this.lerp * 60, e), Math.round(this.value) === Math.round(this.to) && (this.value = this.to, t = !0)) : (this.value = this.to, t = !0);
|
|
1636
1849
|
t && this.stop(), this.onUpdate?.(this.value, t);
|
|
1637
1850
|
}
|
|
1638
1851
|
stop() {
|
|
@@ -1642,7 +1855,7 @@ var Kn = class {
|
|
|
1642
1855
|
this.from = this.value = e, this.to = t, this.lerp = n, this.duration = r, this.easing = i, this.currentTime = 0, this.isRunning = !0, a?.(), this.onUpdate = o;
|
|
1643
1856
|
}
|
|
1644
1857
|
};
|
|
1645
|
-
function
|
|
1858
|
+
function lr(e, t) {
|
|
1646
1859
|
let n;
|
|
1647
1860
|
return function(...r) {
|
|
1648
1861
|
clearTimeout(n), n = setTimeout(() => {
|
|
@@ -1650,7 +1863,7 @@ function qn(e, t) {
|
|
|
1650
1863
|
}, t);
|
|
1651
1864
|
};
|
|
1652
1865
|
}
|
|
1653
|
-
var
|
|
1866
|
+
var ur = class {
|
|
1654
1867
|
width = 0;
|
|
1655
1868
|
height = 0;
|
|
1656
1869
|
scrollHeight = 0;
|
|
@@ -1659,7 +1872,7 @@ var Jn = class {
|
|
|
1659
1872
|
wrapperResizeObserver;
|
|
1660
1873
|
contentResizeObserver;
|
|
1661
1874
|
constructor(e, t, { autoResize: n = !0, debounce: r = 250 } = {}) {
|
|
1662
|
-
this.wrapper = e, this.content = t, n && (this.debouncedResize =
|
|
1875
|
+
this.wrapper = e, this.content = t, n && (this.debouncedResize = lr(this.resize, r), this.wrapper instanceof Window ? window.addEventListener("resize", this.debouncedResize) : (this.wrapperResizeObserver = new ResizeObserver(this.debouncedResize), this.wrapperResizeObserver.observe(this.wrapper)), this.contentResizeObserver = new ResizeObserver(this.debouncedResize), this.contentResizeObserver.observe(this.content)), this.resize();
|
|
1663
1876
|
}
|
|
1664
1877
|
destroy() {
|
|
1665
1878
|
this.wrapperResizeObserver?.disconnect(), this.contentResizeObserver?.disconnect(), this.wrapper === window && this.debouncedResize && window.removeEventListener("resize", this.debouncedResize);
|
|
@@ -1679,7 +1892,7 @@ var Jn = class {
|
|
|
1679
1892
|
y: this.scrollHeight - this.height
|
|
1680
1893
|
};
|
|
1681
1894
|
}
|
|
1682
|
-
},
|
|
1895
|
+
}, dr = class {
|
|
1683
1896
|
events = {};
|
|
1684
1897
|
emit(e, ...t) {
|
|
1685
1898
|
let n = this.events[e] || [];
|
|
@@ -1696,11 +1909,11 @@ var Jn = class {
|
|
|
1696
1909
|
destroy() {
|
|
1697
1910
|
this.events = {};
|
|
1698
1911
|
}
|
|
1699
|
-
},
|
|
1700
|
-
function
|
|
1701
|
-
return e === 1 ?
|
|
1912
|
+
}, fr = 100 / 6, pr = { passive: !1 };
|
|
1913
|
+
function mr(e, t) {
|
|
1914
|
+
return e === 1 ? fr : e === 2 ? t : 1;
|
|
1702
1915
|
}
|
|
1703
|
-
var
|
|
1916
|
+
var hr = class {
|
|
1704
1917
|
touchStart = {
|
|
1705
1918
|
x: 0,
|
|
1706
1919
|
y: 0
|
|
@@ -1713,18 +1926,18 @@ var $n = class {
|
|
|
1713
1926
|
width: 0,
|
|
1714
1927
|
height: 0
|
|
1715
1928
|
};
|
|
1716
|
-
emitter = new
|
|
1929
|
+
emitter = new dr();
|
|
1717
1930
|
constructor(e, t = {
|
|
1718
1931
|
wheelMultiplier: 1,
|
|
1719
1932
|
touchMultiplier: 1
|
|
1720
1933
|
}) {
|
|
1721
|
-
this.element = e, this.options = t, window.addEventListener("resize", this.onWindowResize), this.onWindowResize(), this.element.addEventListener("wheel", this.onWheel,
|
|
1934
|
+
this.element = e, this.options = t, window.addEventListener("resize", this.onWindowResize), this.onWindowResize(), this.element.addEventListener("wheel", this.onWheel, pr), this.element.addEventListener("touchstart", this.onTouchStart, pr), this.element.addEventListener("touchmove", this.onTouchMove, pr), this.element.addEventListener("touchend", this.onTouchEnd, pr);
|
|
1722
1935
|
}
|
|
1723
1936
|
on(e, t) {
|
|
1724
1937
|
return this.emitter.on(e, t);
|
|
1725
1938
|
}
|
|
1726
1939
|
destroy() {
|
|
1727
|
-
this.emitter.destroy(), window.removeEventListener("resize", this.onWindowResize), this.element.removeEventListener("wheel", this.onWheel,
|
|
1940
|
+
this.emitter.destroy(), window.removeEventListener("resize", this.onWindowResize), this.element.removeEventListener("wheel", this.onWheel, pr), this.element.removeEventListener("touchstart", this.onTouchStart, pr), this.element.removeEventListener("touchmove", this.onTouchMove, pr), this.element.removeEventListener("touchend", this.onTouchEnd, pr);
|
|
1728
1941
|
}
|
|
1729
1942
|
onTouchStart = (e) => {
|
|
1730
1943
|
let { clientX: t, clientY: n } = e.targetTouches ? e.targetTouches[0] : e;
|
|
@@ -1756,7 +1969,7 @@ var $n = class {
|
|
|
1756
1969
|
});
|
|
1757
1970
|
};
|
|
1758
1971
|
onWheel = (e) => {
|
|
1759
|
-
let { deltaX: t, deltaY: n, deltaMode: r } = e, i =
|
|
1972
|
+
let { deltaX: t, deltaY: n, deltaMode: r } = e, i = mr(r, this.window.width), a = mr(r, this.window.height);
|
|
1760
1973
|
t *= i, n *= a, t *= this.options.wheelMultiplier, n *= this.options.wheelMultiplier, this.emitter.emit("scroll", {
|
|
1761
1974
|
deltaX: t,
|
|
1762
1975
|
deltaY: n,
|
|
@@ -1769,7 +1982,7 @@ var $n = class {
|
|
|
1769
1982
|
height: window.innerHeight
|
|
1770
1983
|
};
|
|
1771
1984
|
};
|
|
1772
|
-
},
|
|
1985
|
+
}, gr = (e) => Math.min(1, 1.001 - 2 ** (-10 * e)), _r = class {
|
|
1773
1986
|
_isScrolling = !1;
|
|
1774
1987
|
_isStopped = !1;
|
|
1775
1988
|
_isLocked = !1;
|
|
@@ -1788,12 +2001,12 @@ var $n = class {
|
|
|
1788
2001
|
options;
|
|
1789
2002
|
targetScroll;
|
|
1790
2003
|
animatedScroll;
|
|
1791
|
-
animate = new
|
|
1792
|
-
emitter = new
|
|
2004
|
+
animate = new cr();
|
|
2005
|
+
emitter = new dr();
|
|
1793
2006
|
dimensions;
|
|
1794
2007
|
virtualScroll;
|
|
1795
2008
|
constructor({ wrapper: e = window, content: t = document.documentElement, eventsTarget: n = e, smoothWheel: r = !0, syncTouch: i = !1, syncTouchLerp: a = .075, touchInertiaExponent: o = 1.7, duration: s, easing: c, lerp: l = .1, infinite: u = !1, orientation: d = "vertical", gestureOrientation: f = d === "horizontal" ? "both" : "vertical", touchMultiplier: p = 1, wheelMultiplier: m = 1, autoResize: h = !0, prevent: g, virtualScroll: _, overscroll: v = !0, autoRaf: y = !1, anchors: b = !1, autoToggle: x = !1, allowNestedScroll: S = !1, __experimental__naiveDimensions: C = !1, naiveDimensions: w = C, stopInertiaOnNavigate: T = !1, respectReducedMotion: E = !0 } = {}) {
|
|
1796
|
-
window.lenisVersion =
|
|
2009
|
+
window.lenisVersion = rr, window.lenis || (window.lenis = {}), window.lenis.version = rr, d === "horizontal" && (window.lenis.horizontal = !0), i === !0 && (window.lenis.touch = !0), this.isIos = /(iPad|iPhone|iPod)/g.test(navigator.userAgent), (!e || e === document.documentElement) && (e = window), typeof s == "number" && typeof c != "function" ? c = gr : typeof c == "function" && typeof s != "number" && (s = 1), this.options = {
|
|
1797
2010
|
wrapper: e,
|
|
1798
2011
|
content: t,
|
|
1799
2012
|
eventsTarget: n,
|
|
@@ -1820,7 +2033,7 @@ var $n = class {
|
|
|
1820
2033
|
naiveDimensions: w,
|
|
1821
2034
|
stopInertiaOnNavigate: T,
|
|
1822
2035
|
respectReducedMotion: E
|
|
1823
|
-
}, this.dimensions = new
|
|
2036
|
+
}, this.dimensions = new ur(e, t, { autoResize: h }), this.updateClassName(), this.targetScroll = this.animatedScroll = this.actualScroll, this.options.wrapper.addEventListener("scroll", this.onNativeScroll), this.options.wrapper.addEventListener("scrollend", this.onScrollEnd, { capture: !0 }), (this.options.anchors || this.options.stopInertiaOnNavigate) && this.options.wrapper.addEventListener("click", this.onClick), this.options.wrapper.addEventListener("pointerdown", this.onPointerDown), this.virtualScroll = new hr(n, {
|
|
1824
2037
|
touchMultiplier: p,
|
|
1825
2038
|
wheelMultiplier: m
|
|
1826
2039
|
}), this.virtualScroll.on("scroll", this.onVirtualScroll), this.options.autoToggle && (this.checkOverflow(), this.rootElement.addEventListener("transitionend", this.onTransitionEnd)), this.options.autoRaf && (this._rafId = requestAnimationFrame(this.raf));
|
|
@@ -2019,7 +2232,7 @@ var $n = class {
|
|
|
2019
2232
|
let e = f - this.animatedScroll;
|
|
2020
2233
|
e > this.limit / 2 ? f -= this.limit : e < -this.limit / 2 && (f += this.limit);
|
|
2021
2234
|
}
|
|
2022
|
-
} else f =
|
|
2235
|
+
} else f = ir(0, f, this.limit);
|
|
2023
2236
|
if (f === this.targetScroll) {
|
|
2024
2237
|
c?.(this), l?.(this);
|
|
2025
2238
|
return;
|
|
@@ -2030,7 +2243,7 @@ var $n = class {
|
|
|
2030
2243
|
});
|
|
2031
2244
|
return;
|
|
2032
2245
|
}
|
|
2033
|
-
i || (this.targetScroll = f), typeof o == "number" && typeof s != "function" ? s =
|
|
2246
|
+
i || (this.targetScroll = f), typeof o == "number" && typeof s != "function" ? s = gr : typeof s == "function" && typeof o != "number" && (o = 1), this.animate.fromTo(this.animatedScroll, f, {
|
|
2034
2247
|
duration: o,
|
|
2035
2248
|
easing: s,
|
|
2036
2249
|
lerp: a,
|
|
@@ -2089,7 +2302,7 @@ var $n = class {
|
|
|
2089
2302
|
return this.isHorizontal ? e.scrollX ?? e.scrollLeft : e.scrollY ?? e.scrollTop;
|
|
2090
2303
|
}
|
|
2091
2304
|
get scroll() {
|
|
2092
|
-
return this.options.infinite ?
|
|
2305
|
+
return this.options.infinite ? sr(this.animatedScroll, this.limit) : this.animatedScroll;
|
|
2093
2306
|
}
|
|
2094
2307
|
get progress() {
|
|
2095
2308
|
return this.limit === 0 ? 1 : this.scroll / this.limit;
|
|
@@ -2130,7 +2343,7 @@ var $n = class {
|
|
|
2130
2343
|
cleanUpClassName() {
|
|
2131
2344
|
for (let e of Array.from(this.rootElement.classList)) (e === "lenis" || e.startsWith("lenis-")) && this.rootElement.classList.remove(e);
|
|
2132
2345
|
}
|
|
2133
|
-
},
|
|
2346
|
+
}, vr = [
|
|
2134
2347
|
"linear",
|
|
2135
2348
|
"outQuad",
|
|
2136
2349
|
"outCubic",
|
|
@@ -2139,28 +2352,97 @@ var $n = class {
|
|
|
2139
2352
|
"outBack",
|
|
2140
2353
|
"outElastic",
|
|
2141
2354
|
"outBounce"
|
|
2142
|
-
],
|
|
2355
|
+
], yr = n({
|
|
2356
|
+
anchorOffset: 0,
|
|
2357
|
+
anchorScroll: !1,
|
|
2143
2358
|
duration: 600,
|
|
2144
2359
|
ease: "outExpo",
|
|
2145
2360
|
reducedMotion: "reduce",
|
|
2146
2361
|
smoothScroll: !1,
|
|
2147
2362
|
smoothScrollLerp: .1
|
|
2148
2363
|
});
|
|
2149
|
-
function
|
|
2150
|
-
Object.assign(
|
|
2364
|
+
function br(e) {
|
|
2365
|
+
Object.assign(yr, e);
|
|
2151
2366
|
}
|
|
2152
|
-
var
|
|
2153
|
-
|
|
2154
|
-
|
|
2155
|
-
|
|
2367
|
+
var xr = {
|
|
2368
|
+
blink: {
|
|
2369
|
+
alternate: !0,
|
|
2370
|
+
category: "ambient",
|
|
2371
|
+
ease: "inOutSine",
|
|
2372
|
+
keyframes: { opacity: .4 },
|
|
2373
|
+
loop: !0
|
|
2156
2374
|
},
|
|
2157
|
-
|
|
2375
|
+
blur: {
|
|
2158
2376
|
category: "enter",
|
|
2159
2377
|
from: {
|
|
2160
|
-
|
|
2161
|
-
|
|
2378
|
+
blur: 8,
|
|
2379
|
+
opacity: 0
|
|
2162
2380
|
}
|
|
2163
2381
|
},
|
|
2382
|
+
count: {
|
|
2383
|
+
category: "enter",
|
|
2384
|
+
count: !0,
|
|
2385
|
+
duration: 1600
|
|
2386
|
+
},
|
|
2387
|
+
fade: {
|
|
2388
|
+
category: "enter",
|
|
2389
|
+
from: { opacity: 0 }
|
|
2390
|
+
},
|
|
2391
|
+
float: {
|
|
2392
|
+
alternate: !0,
|
|
2393
|
+
category: "ambient",
|
|
2394
|
+
ease: "inOutSine",
|
|
2395
|
+
keyframes: {
|
|
2396
|
+
composition: "add",
|
|
2397
|
+
transform: ["translateY(0px)", "translateY(-8px)"]
|
|
2398
|
+
},
|
|
2399
|
+
loop: !0
|
|
2400
|
+
},
|
|
2401
|
+
grow: {
|
|
2402
|
+
category: "emphasis",
|
|
2403
|
+
to: { scale: 1.05 }
|
|
2404
|
+
},
|
|
2405
|
+
lift: {
|
|
2406
|
+
category: "emphasis",
|
|
2407
|
+
to: { y: -6 }
|
|
2408
|
+
},
|
|
2409
|
+
marquee: {
|
|
2410
|
+
category: "ambient",
|
|
2411
|
+
duration: 2e4,
|
|
2412
|
+
ease: "linear",
|
|
2413
|
+
loop: !0,
|
|
2414
|
+
marquee: !0
|
|
2415
|
+
},
|
|
2416
|
+
pulse: {
|
|
2417
|
+
alternate: !0,
|
|
2418
|
+
category: "ambient",
|
|
2419
|
+
ease: "inOutSine",
|
|
2420
|
+
keyframes: {
|
|
2421
|
+
composition: "add",
|
|
2422
|
+
transform: ["scale(1)", "scale(1.06)"]
|
|
2423
|
+
},
|
|
2424
|
+
loop: !0
|
|
2425
|
+
},
|
|
2426
|
+
shake: {
|
|
2427
|
+
category: "ambient",
|
|
2428
|
+
ease: "linear",
|
|
2429
|
+
keyframes: {
|
|
2430
|
+
composition: "add",
|
|
2431
|
+
transform: [
|
|
2432
|
+
"translateX(0px)",
|
|
2433
|
+
"translateX(-6px)",
|
|
2434
|
+
"translateX(6px)",
|
|
2435
|
+
"translateX(-6px)",
|
|
2436
|
+
"translateX(6px)",
|
|
2437
|
+
"translateX(0px)"
|
|
2438
|
+
]
|
|
2439
|
+
},
|
|
2440
|
+
loop: !0
|
|
2441
|
+
},
|
|
2442
|
+
shrink: {
|
|
2443
|
+
category: "emphasis",
|
|
2444
|
+
to: { scale: .95 }
|
|
2445
|
+
},
|
|
2164
2446
|
"slide-down": {
|
|
2165
2447
|
category: "enter",
|
|
2166
2448
|
from: {
|
|
@@ -2182,161 +2464,125 @@ var ar = {
|
|
|
2182
2464
|
x: -32
|
|
2183
2465
|
}
|
|
2184
2466
|
},
|
|
2185
|
-
|
|
2467
|
+
"slide-up": {
|
|
2186
2468
|
category: "enter",
|
|
2187
2469
|
from: {
|
|
2188
2470
|
opacity: 0,
|
|
2189
|
-
|
|
2190
|
-
}
|
|
2191
|
-
},
|
|
2192
|
-
blur: {
|
|
2193
|
-
category: "enter",
|
|
2194
|
-
from: {
|
|
2195
|
-
blur: 8,
|
|
2196
|
-
opacity: 0
|
|
2471
|
+
y: 32
|
|
2197
2472
|
}
|
|
2198
2473
|
},
|
|
2199
|
-
count: {
|
|
2200
|
-
category: "enter",
|
|
2201
|
-
count: !0,
|
|
2202
|
-
duration: 1600
|
|
2203
|
-
},
|
|
2204
|
-
grow: {
|
|
2205
|
-
category: "emphasis",
|
|
2206
|
-
to: { scale: 1.05 }
|
|
2207
|
-
},
|
|
2208
|
-
shrink: {
|
|
2209
|
-
category: "emphasis",
|
|
2210
|
-
to: { scale: .95 }
|
|
2211
|
-
},
|
|
2212
|
-
lift: {
|
|
2213
|
-
category: "emphasis",
|
|
2214
|
-
to: { y: -6 }
|
|
2215
|
-
},
|
|
2216
|
-
tilt: {
|
|
2217
|
-
category: "emphasis",
|
|
2218
|
-
to: { rotate: 3 }
|
|
2219
|
-
},
|
|
2220
|
-
pulse: {
|
|
2221
|
-
alternate: !0,
|
|
2222
|
-
category: "ambient",
|
|
2223
|
-
ease: "inOutSine",
|
|
2224
|
-
loop: !0,
|
|
2225
|
-
params: { scale: 1.06 }
|
|
2226
|
-
},
|
|
2227
|
-
float: {
|
|
2228
|
-
alternate: !0,
|
|
2229
|
-
category: "ambient",
|
|
2230
|
-
ease: "inOutSine",
|
|
2231
|
-
loop: !0,
|
|
2232
|
-
params: { translateY: -8 }
|
|
2233
|
-
},
|
|
2234
2474
|
spin: {
|
|
2235
2475
|
category: "ambient",
|
|
2236
2476
|
ease: "linear",
|
|
2237
|
-
|
|
2238
|
-
|
|
2239
|
-
|
|
2240
|
-
|
|
2241
|
-
|
|
2242
|
-
ease: "linear",
|
|
2243
|
-
loop: !0,
|
|
2244
|
-
params: { translateX: [
|
|
2245
|
-
0,
|
|
2246
|
-
-6,
|
|
2247
|
-
6,
|
|
2248
|
-
-6,
|
|
2249
|
-
6,
|
|
2250
|
-
0
|
|
2251
|
-
] }
|
|
2477
|
+
keyframes: {
|
|
2478
|
+
composition: "add",
|
|
2479
|
+
transform: ["rotate(0deg)", "rotate(360deg)"]
|
|
2480
|
+
},
|
|
2481
|
+
loop: !0
|
|
2252
2482
|
},
|
|
2253
|
-
|
|
2254
|
-
|
|
2255
|
-
|
|
2256
|
-
ease: "inOutSine",
|
|
2257
|
-
loop: !0,
|
|
2258
|
-
params: { opacity: .4 }
|
|
2483
|
+
tilt: {
|
|
2484
|
+
category: "emphasis",
|
|
2485
|
+
to: { rotate: 3 }
|
|
2259
2486
|
},
|
|
2260
2487
|
wiggle: {
|
|
2261
2488
|
alternate: !0,
|
|
2262
2489
|
category: "ambient",
|
|
2263
2490
|
ease: "inOutSine",
|
|
2264
|
-
|
|
2265
|
-
|
|
2266
|
-
|
|
2267
|
-
|
|
2268
|
-
|
|
2491
|
+
keyframes: {
|
|
2492
|
+
composition: "add",
|
|
2493
|
+
transform: ["rotate(-3deg)", "rotate(3deg)"]
|
|
2494
|
+
},
|
|
2495
|
+
loop: !0
|
|
2496
|
+
},
|
|
2497
|
+
zoom: {
|
|
2498
|
+
category: "enter",
|
|
2499
|
+
from: {
|
|
2500
|
+
opacity: 0,
|
|
2501
|
+
scale: .8
|
|
2502
|
+
}
|
|
2269
2503
|
}
|
|
2270
|
-
},
|
|
2504
|
+
}, Sr = {
|
|
2271
2505
|
blur: 0,
|
|
2272
2506
|
opacity: 1,
|
|
2273
2507
|
rotate: 0,
|
|
2274
2508
|
scale: 1,
|
|
2509
|
+
scaleX: 1,
|
|
2510
|
+
scaleY: 1,
|
|
2275
2511
|
x: 0,
|
|
2276
2512
|
y: 0
|
|
2277
|
-
},
|
|
2513
|
+
}, Cr = [
|
|
2514
|
+
"blur",
|
|
2515
|
+
"scale",
|
|
2516
|
+
"scaleX",
|
|
2517
|
+
"scaleY"
|
|
2518
|
+
], wr = {
|
|
2278
2519
|
center: .5,
|
|
2279
2520
|
top: 0
|
|
2280
|
-
},
|
|
2281
|
-
function
|
|
2282
|
-
let
|
|
2283
|
-
for (let
|
|
2284
|
-
let
|
|
2285
|
-
|
|
2286
|
-
|
|
2287
|
-
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
|
|
2291
|
-
|
|
2292
|
-
|
|
2293
|
-
|
|
2294
|
-
|
|
2295
|
-
|
|
2296
|
-
|
|
2297
|
-
|
|
2298
|
-
|
|
2299
|
-
|
|
2300
|
-
|
|
2301
|
-
|
|
2521
|
+
}, Tr = 4, Er = /* @__PURE__ */ new WeakMap(), Dr = /* @__PURE__ */ new WeakMap();
|
|
2522
|
+
function Or({ from: e, steps: t = [], to: n }, r) {
|
|
2523
|
+
let i = {};
|
|
2524
|
+
for (let a of Object.keys(Sr)) {
|
|
2525
|
+
let o = [
|
|
2526
|
+
e,
|
|
2527
|
+
...t,
|
|
2528
|
+
n
|
|
2529
|
+
].map((e) => e?.[a] ?? Sr[a]), s = o[0], c = o.at(-1);
|
|
2530
|
+
if (!o.every((e) => e === s)) {
|
|
2531
|
+
if (r) {
|
|
2532
|
+
let e = c + (c - s) * Tr;
|
|
2533
|
+
o.push(Cr.includes(a) ? Math.max(0, e) : e);
|
|
2534
|
+
}
|
|
2535
|
+
switch (a) {
|
|
2536
|
+
case "blur":
|
|
2537
|
+
i.filter = o.map((e) => `blur(${e}px)`);
|
|
2538
|
+
break;
|
|
2539
|
+
case "x":
|
|
2540
|
+
i.translateX = o;
|
|
2541
|
+
break;
|
|
2542
|
+
case "y":
|
|
2543
|
+
i.translateY = o;
|
|
2544
|
+
break;
|
|
2545
|
+
default: i[a] = o;
|
|
2546
|
+
}
|
|
2302
2547
|
}
|
|
2303
2548
|
}
|
|
2304
|
-
return
|
|
2549
|
+
return i;
|
|
2305
2550
|
}
|
|
2306
|
-
function
|
|
2551
|
+
function kr(e) {
|
|
2307
2552
|
return e.preset === "custom" ? {
|
|
2308
2553
|
category: "enter",
|
|
2309
2554
|
from: e.from,
|
|
2555
|
+
steps: e.keyframes,
|
|
2310
2556
|
to: e.to
|
|
2311
|
-
} :
|
|
2557
|
+
} : xr[e.preset];
|
|
2312
2558
|
}
|
|
2313
|
-
function
|
|
2314
|
-
return n === "scroll" && e.scrollMode === "continue" && !t.
|
|
2559
|
+
function Ar({ options: e, preset: t, trigger: n }) {
|
|
2560
|
+
return n === "scroll" && e.scrollMode === "continue" && !t.keyframes && !t.marquee && !t.count;
|
|
2315
2561
|
}
|
|
2316
|
-
function
|
|
2317
|
-
return
|
|
2562
|
+
function jr() {
|
|
2563
|
+
return yr.reducedMotion === "reduce" && typeof matchMedia < "u" && matchMedia("(prefers-reduced-motion: reduce)").matches;
|
|
2318
2564
|
}
|
|
2319
|
-
function
|
|
2565
|
+
function Mr(e) {
|
|
2320
2566
|
let { state: t, ...n } = e;
|
|
2321
2567
|
return JSON.stringify(n);
|
|
2322
2568
|
}
|
|
2323
|
-
function
|
|
2569
|
+
function Nr({ options: e, preset: t, reduced: n }) {
|
|
2324
2570
|
return n ? !1 : e.loop === void 0 ? t.loop ?? !1 : e.loop < 0 || e.loop;
|
|
2325
2571
|
}
|
|
2326
|
-
function
|
|
2572
|
+
function Pr({ options: e, reduced: t }) {
|
|
2327
2573
|
return t ? void 0 : e.stagger ?? (e.split ? 30 : void 0);
|
|
2328
2574
|
}
|
|
2329
|
-
function
|
|
2575
|
+
function Fr(e, t = e.options.delay ?? 0) {
|
|
2330
2576
|
if (e.reduced) return 0;
|
|
2331
|
-
let n =
|
|
2332
|
-
return n === void 0 ? t :
|
|
2577
|
+
let n = Pr(e);
|
|
2578
|
+
return n === void 0 ? t : Pn(n, {
|
|
2333
2579
|
from: e.options.staggerFrom ?? "first",
|
|
2334
2580
|
start: t
|
|
2335
2581
|
});
|
|
2336
2582
|
}
|
|
2337
|
-
function
|
|
2583
|
+
function Ir(e, t, n, r = e.options.delay ?? 0) {
|
|
2338
2584
|
if (e.reduced) return 0;
|
|
2339
|
-
let i =
|
|
2585
|
+
let i = Pr(e) ?? 0;
|
|
2340
2586
|
switch (e.options.staggerFrom) {
|
|
2341
2587
|
case "last": return r + (n - 1 - t) * i;
|
|
2342
2588
|
case "center": return r + Math.abs(t - (n - 1) / 2) * i;
|
|
@@ -2344,55 +2590,55 @@ function yr(e, t, n, r = e.options.delay ?? 0) {
|
|
|
2344
2590
|
default: return r + t * i;
|
|
2345
2591
|
}
|
|
2346
2592
|
}
|
|
2347
|
-
function
|
|
2593
|
+
function Lr(e) {
|
|
2348
2594
|
let t = e.closest("[data-scroll-root]");
|
|
2349
2595
|
if (t) return t;
|
|
2350
2596
|
for (let t = e.parentElement; t; t = t.parentElement) if (/auto|scroll|overlay/.test(getComputedStyle(t).overflowY) && t.scrollHeight > t.clientHeight) return t;
|
|
2351
2597
|
}
|
|
2352
|
-
function
|
|
2598
|
+
function Rr(e) {
|
|
2353
2599
|
return Math.min(1, Math.max(0, e));
|
|
2354
2600
|
}
|
|
2355
|
-
function
|
|
2356
|
-
let { options: r } = e, i = t.container.height, a = t.distance || 1, o = Math.max(a - i, 0), s =
|
|
2601
|
+
function zr(e, t, n) {
|
|
2602
|
+
let { options: r } = e, i = t.container.height, a = t.distance || 1, o = Math.max(a - i, 0), s = wr[r.scrollAnchor ?? "top"], c = Rr((r.scrollTarget ?? 50) / 100), l = (e, t) => (i + e * o - t * i) / a, u = l(s, 1), d = l(s, c), f = Math.max(d - u, 1e-4);
|
|
2357
2603
|
if (r.scrollMode === "hold") {
|
|
2358
2604
|
let e = l(s, Math.max(c, 1 - c)), t = l(1 - s, Math.min(c, 1 - c)), r = l(1 - s, 0);
|
|
2359
|
-
return n < e ?
|
|
2605
|
+
return n < e ? Rr((n - u) / Math.max(e - u, 1e-4)) : n <= t ? 1 : Rr((r - n) / Math.max(r - t, 1e-4));
|
|
2360
2606
|
}
|
|
2361
|
-
return
|
|
2607
|
+
return Ar(e) ? n < d ? .5 * Rr((n - u) / f) : .5 + .5 * Math.min(1, (n - d) / f / Tr) : Rr((n - u) / f);
|
|
2362
2608
|
}
|
|
2363
|
-
function
|
|
2364
|
-
let t =
|
|
2609
|
+
function Br(e) {
|
|
2610
|
+
let t = Lr(e.element), n = _n({
|
|
2365
2611
|
container: t,
|
|
2366
2612
|
enter: "end start",
|
|
2367
2613
|
leave: "start end",
|
|
2368
|
-
sync: (t) =>
|
|
2614
|
+
sync: (t) => zr(e, n, t),
|
|
2369
2615
|
target: e.element
|
|
2370
2616
|
});
|
|
2371
|
-
return
|
|
2617
|
+
return Vr(e, n, t), n;
|
|
2372
2618
|
}
|
|
2373
|
-
function
|
|
2619
|
+
function Vr({ controller: e, element: t }, n, r) {
|
|
2374
2620
|
let i = new ResizeObserver(() => n.container.refresh());
|
|
2375
2621
|
i.observe(t), [...(r ?? document.body).children].forEach((e) => i.observe(e)), e.cleanups.push(() => i.disconnect());
|
|
2376
2622
|
}
|
|
2377
|
-
function
|
|
2623
|
+
function Hr(e) {
|
|
2378
2624
|
switch (e.trigger) {
|
|
2379
2625
|
case "mount": return !0;
|
|
2380
2626
|
case "visible": return e.controller.revealed;
|
|
2381
|
-
case "scroll": return
|
|
2627
|
+
case "scroll": return Br(e);
|
|
2382
2628
|
default: return !1;
|
|
2383
2629
|
}
|
|
2384
2630
|
}
|
|
2385
|
-
function
|
|
2631
|
+
function Ur(e) {
|
|
2386
2632
|
let t = new IntersectionObserver((n) => {
|
|
2387
|
-
n.some((e) => e.isIntersecting) && (t.disconnect(), e.controller.revealed = !0,
|
|
2633
|
+
n.some((e) => e.isIntersecting) && (t.disconnect(), e.controller.revealed = !0, hi(e.controller));
|
|
2388
2634
|
});
|
|
2389
2635
|
t.observe(e.element), e.controller.cleanups.push(() => t.disconnect());
|
|
2390
2636
|
}
|
|
2391
|
-
var
|
|
2392
|
-
function
|
|
2637
|
+
var Wr = /-?\d[\d,]*(\.\d+)?/;
|
|
2638
|
+
function Gr(e, t) {
|
|
2393
2639
|
let n = document.createTreeWalker(e, NodeFilter.SHOW_TEXT);
|
|
2394
2640
|
for (let e = n.nextNode(); e; e = n.nextNode()) {
|
|
2395
|
-
let n = e, r =
|
|
2641
|
+
let n = e, r = Wr.exec(n.data);
|
|
2396
2642
|
if (r) return {
|
|
2397
2643
|
decimals: r[1] ? r[1].length - 1 : 0,
|
|
2398
2644
|
from: t,
|
|
@@ -2407,7 +2653,7 @@ function Or(e, t) {
|
|
|
2407
2653
|
};
|
|
2408
2654
|
}
|
|
2409
2655
|
}
|
|
2410
|
-
function
|
|
2656
|
+
function Kr(e) {
|
|
2411
2657
|
let t = e.value.toLocaleString("en-US", {
|
|
2412
2658
|
maximumFractionDigits: e.decimals,
|
|
2413
2659
|
minimumFractionDigits: e.decimals,
|
|
@@ -2415,24 +2661,51 @@ function kr(e) {
|
|
|
2415
2661
|
});
|
|
2416
2662
|
e.rendered = e.prefix + t + e.suffix, e.node.data = e.rendered;
|
|
2417
2663
|
}
|
|
2418
|
-
function
|
|
2664
|
+
function qr(e) {
|
|
2419
2665
|
e.node.data === e.rendered && (e.node.data = e.original);
|
|
2420
2666
|
}
|
|
2421
|
-
function
|
|
2422
|
-
let r = (Array.isArray(n) ? n : [n]).map((e) =>
|
|
2423
|
-
return e.cleanups.push(() => r.forEach(
|
|
2667
|
+
function Jr({ controller: e, options: t }, n) {
|
|
2668
|
+
let r = (Array.isArray(n) ? n : [n]).map((e) => Gr(e, t.countFrom ?? 0)).filter((e) => !!e);
|
|
2669
|
+
return e.cleanups.push(() => r.forEach(qr)), r;
|
|
2424
2670
|
}
|
|
2425
|
-
function
|
|
2426
|
-
return
|
|
2671
|
+
function Yr(e, t) {
|
|
2672
|
+
return Yt(e, {
|
|
2427
2673
|
...t,
|
|
2428
|
-
onUpdate: () => e.forEach(
|
|
2674
|
+
onUpdate: () => e.forEach(Kr),
|
|
2429
2675
|
value: {
|
|
2430
2676
|
from: (t, n) => e[n].from,
|
|
2431
2677
|
to: (t, n) => e[n].to
|
|
2432
2678
|
}
|
|
2433
2679
|
});
|
|
2434
2680
|
}
|
|
2435
|
-
function
|
|
2681
|
+
function Xr(e) {
|
|
2682
|
+
return { transform: ["translateX(0px)", `translateX(calc(-50% - ${(parseFloat(getComputedStyle(e).columnGap) || 0) / 2}px))`] };
|
|
2683
|
+
}
|
|
2684
|
+
function Zr({ controller: e, element: t }) {
|
|
2685
|
+
let n = t.style.width, r = ei(t).map((e) => {
|
|
2686
|
+
let t = e.cloneNode(!0);
|
|
2687
|
+
return t.setAttribute("aria-hidden", "true"), t;
|
|
2688
|
+
});
|
|
2689
|
+
t.append(...r), t.style.width = "max-content", e.cleanups.push(() => {
|
|
2690
|
+
r.forEach((e) => e.remove()), t.style.width = n;
|
|
2691
|
+
});
|
|
2692
|
+
}
|
|
2693
|
+
function Qr({ element: e, options: t, preset: n }, r, i, a) {
|
|
2694
|
+
let o = n.marquee ? Xr(e) : n.keyframes;
|
|
2695
|
+
if (o) {
|
|
2696
|
+
let e = t.stepped ? `steps(${t.stepped})` : i.ease;
|
|
2697
|
+
return kn.animate(r, {
|
|
2698
|
+
...o,
|
|
2699
|
+
...i,
|
|
2700
|
+
ease: e
|
|
2701
|
+
});
|
|
2702
|
+
}
|
|
2703
|
+
return Yt(r, {
|
|
2704
|
+
...Or(n, a),
|
|
2705
|
+
...i
|
|
2706
|
+
});
|
|
2707
|
+
}
|
|
2708
|
+
function $r(e) {
|
|
2436
2709
|
return e instanceof HTMLElement && ![
|
|
2437
2710
|
"LINK",
|
|
2438
2711
|
"META",
|
|
@@ -2441,16 +2714,16 @@ function Nr(e) {
|
|
|
2441
2714
|
"TEMPLATE"
|
|
2442
2715
|
].includes(e.tagName);
|
|
2443
2716
|
}
|
|
2444
|
-
function
|
|
2445
|
-
return [...e.children].filter(
|
|
2717
|
+
function ei(e) {
|
|
2718
|
+
return [...e.children].filter($r);
|
|
2446
2719
|
}
|
|
2447
|
-
function
|
|
2720
|
+
function ti(e) {
|
|
2448
2721
|
return e.sort((e, t) => e.element.compareDocumentPosition(t.element) & Node.DOCUMENT_POSITION_FOLLOWING ? -1 : 1);
|
|
2449
2722
|
}
|
|
2450
|
-
function
|
|
2451
|
-
return
|
|
2723
|
+
function ni({ controller: e, element: t }) {
|
|
2724
|
+
return Er.get(t) === e;
|
|
2452
2725
|
}
|
|
2453
|
-
function
|
|
2726
|
+
function ri({ controller: e }, t) {
|
|
2454
2727
|
for (let n of Array.isArray(t) ? t : [t]) {
|
|
2455
2728
|
if (getComputedStyle(n).display !== "inline") continue;
|
|
2456
2729
|
let t = n.style.display;
|
|
@@ -2459,117 +2732,114 @@ function Lr({ controller: e }, t) {
|
|
|
2459
2732
|
});
|
|
2460
2733
|
}
|
|
2461
2734
|
}
|
|
2462
|
-
function
|
|
2463
|
-
let { controller: i, options: a, preset: o, reduced: s } = e, c =
|
|
2464
|
-
o.count ||
|
|
2735
|
+
function ii(e, t, n, r = Hr(e)) {
|
|
2736
|
+
let { controller: i, options: a, preset: o, reduced: s } = e, c = Ar(e), l = o.count ? Jr(e, t) : [];
|
|
2737
|
+
o.count || ri(e, t);
|
|
2465
2738
|
let u = {
|
|
2466
2739
|
alternate: a.alternate ?? o.alternate ?? !1,
|
|
2467
2740
|
autoplay: r,
|
|
2468
2741
|
delay: n,
|
|
2469
|
-
duration: s ? 0 : a.duration ?? o.duration ??
|
|
2470
|
-
ease: a.ease ?? (c ? "linear" : o.ease ??
|
|
2471
|
-
loop:
|
|
2472
|
-
}, d = o.count ?
|
|
2473
|
-
|
|
2474
|
-
...u
|
|
2475
|
-
});
|
|
2476
|
-
return l.forEach(kr), e.trigger === "visible" && !r && d.seek(0), i.animations.push(d), d;
|
|
2742
|
+
duration: s ? 0 : a.duration ?? o.duration ?? yr.duration,
|
|
2743
|
+
ease: a.stepped ? vn(a.stepped) : a.ease ?? (c ? "linear" : o.ease ?? yr.ease),
|
|
2744
|
+
loop: Nr(e)
|
|
2745
|
+
}, d = o.count ? Yr(l, u) : Qr(e, t, u, c);
|
|
2746
|
+
return l.forEach(Kr), e.trigger === "visible" && !r && d.seek(0), i.animations.push(d), d;
|
|
2477
2747
|
}
|
|
2478
|
-
function
|
|
2748
|
+
function ai({ controller: e, element: t }, n) {
|
|
2479
2749
|
let r = new MutationObserver((e) => {
|
|
2480
|
-
let t = e.flatMap((e) => [...e.addedNodes]).filter(
|
|
2481
|
-
(t.length || e.some((e) => [...e.removedNodes].some(
|
|
2750
|
+
let t = e.flatMap((e) => [...e.addedNodes]).filter($r);
|
|
2751
|
+
(t.length || e.some((e) => [...e.removedNodes].some($r))) && n(t);
|
|
2482
2752
|
});
|
|
2483
2753
|
r.observe(t, { childList: !0 }), e.cleanups.push(() => r.disconnect());
|
|
2484
2754
|
}
|
|
2485
|
-
function
|
|
2486
|
-
|
|
2487
|
-
t.length &&
|
|
2488
|
-
}),
|
|
2755
|
+
function oi(e) {
|
|
2756
|
+
ii(e, ei(e.element), Fr(e)), ai(e, (t) => {
|
|
2757
|
+
t.length && ii(e, t, Fr(e, 0));
|
|
2758
|
+
}), vi(e);
|
|
2489
2759
|
}
|
|
2490
|
-
function
|
|
2760
|
+
function si(e) {
|
|
2491
2761
|
let t = new Map(e.map((e) => [e.element, e])), n = new IntersectionObserver((e) => {
|
|
2492
|
-
let r =
|
|
2762
|
+
let r = ti(e.filter((e) => e.isIntersecting).map((e) => t.get(e.target)).filter((e) => !!e && ni(e)));
|
|
2493
2763
|
r.forEach((e, t) => {
|
|
2494
2764
|
n.unobserve(e.element);
|
|
2495
|
-
let i = setTimeout(() =>
|
|
2765
|
+
let i = setTimeout(() => hi(e.controller), Ir(e, t, r.length, 0));
|
|
2496
2766
|
e.controller.cleanups.push(() => clearTimeout(i));
|
|
2497
2767
|
});
|
|
2498
2768
|
});
|
|
2499
|
-
for (let t of e)
|
|
2769
|
+
for (let t of e) ii(t, t.element, t.options.delay ?? 0, !1), n.observe(t.element), t.controller.cleanups.push(() => n.unobserve(t.element));
|
|
2500
2770
|
}
|
|
2501
|
-
var
|
|
2502
|
-
function
|
|
2503
|
-
return e ? (
|
|
2771
|
+
var ci = /* @__PURE__ */ new WeakMap(), li = 0, ui = /* @__PURE__ */ new Map();
|
|
2772
|
+
function di(e) {
|
|
2773
|
+
return e ? (ci.has(e) || ci.set(e, li++), String(ci.get(e))) : "none";
|
|
2504
2774
|
}
|
|
2505
|
-
function
|
|
2506
|
-
|
|
2507
|
-
let t = `${
|
|
2508
|
-
|
|
2775
|
+
function fi(e) {
|
|
2776
|
+
ui.size || queueMicrotask(pi);
|
|
2777
|
+
let t = `${di(e.element.parentElement)}/${e.controller.key}`;
|
|
2778
|
+
ui.set(t, [...ui.get(t) ?? [], e]);
|
|
2509
2779
|
}
|
|
2510
|
-
function
|
|
2511
|
-
let e = [...
|
|
2512
|
-
|
|
2780
|
+
function pi() {
|
|
2781
|
+
let e = [...ui.values()];
|
|
2782
|
+
ui = /* @__PURE__ */ new Map();
|
|
2513
2783
|
for (let t of e) {
|
|
2514
|
-
let e =
|
|
2515
|
-
e.length === 1 ?
|
|
2784
|
+
let e = ti(t.filter(ni));
|
|
2785
|
+
e.length === 1 ? oi(e[0]) : e[0]?.trigger === "visible" ? si(e) : e.forEach((t, n) => ii(t, t.element, Ir(t, n, e.length)));
|
|
2516
2786
|
}
|
|
2517
2787
|
}
|
|
2518
|
-
function
|
|
2788
|
+
function mi({ controller: e, element: t }, n, r) {
|
|
2519
2789
|
for (let i of n) t.addEventListener(i, r), e.cleanups.push(() => t.removeEventListener(i, r));
|
|
2520
2790
|
}
|
|
2521
|
-
function
|
|
2791
|
+
function hi(e) {
|
|
2522
2792
|
e.animations.forEach((e) => e.play());
|
|
2523
2793
|
}
|
|
2524
|
-
function
|
|
2794
|
+
function gi(e) {
|
|
2525
2795
|
e.animations.forEach((t) => e.looping ? t.pause().seek(0) : t.reverse());
|
|
2526
2796
|
}
|
|
2527
|
-
function
|
|
2797
|
+
function _i(e, t, n) {
|
|
2528
2798
|
if (e.state !== t) {
|
|
2529
2799
|
if (e.state = t, n && !e.looping) {
|
|
2530
2800
|
e.animations.forEach((e) => e.seek(t ? e.duration : 0));
|
|
2531
2801
|
return;
|
|
2532
2802
|
}
|
|
2533
|
-
t ?
|
|
2803
|
+
t ? hi(e) : gi(e);
|
|
2534
2804
|
}
|
|
2535
2805
|
}
|
|
2536
|
-
function
|
|
2806
|
+
function vi(e) {
|
|
2537
2807
|
let { controller: t, options: n, trigger: r } = e;
|
|
2538
2808
|
switch (r) {
|
|
2539
2809
|
case "hover":
|
|
2540
|
-
|
|
2810
|
+
mi(e, ["pointerenter"], () => hi(t)), mi(e, ["pointerleave"], () => gi(t));
|
|
2541
2811
|
break;
|
|
2542
2812
|
case "press":
|
|
2543
|
-
|
|
2813
|
+
mi(e, ["pointerdown"], () => hi(t)), mi(e, [
|
|
2544
2814
|
"pointerup",
|
|
2545
2815
|
"pointerleave",
|
|
2546
2816
|
"pointercancel"
|
|
2547
|
-
], () =>
|
|
2817
|
+
], () => gi(t));
|
|
2548
2818
|
break;
|
|
2549
2819
|
case "focus":
|
|
2550
|
-
|
|
2820
|
+
mi(e, ["focusin"], () => hi(t)), mi(e, ["focusout"], () => gi(t));
|
|
2551
2821
|
break;
|
|
2552
2822
|
case "state":
|
|
2553
|
-
|
|
2823
|
+
_i(t, !!n.state, !0);
|
|
2554
2824
|
return;
|
|
2555
2825
|
case "visible":
|
|
2556
|
-
|
|
2826
|
+
Ur(e);
|
|
2557
2827
|
return;
|
|
2558
2828
|
default: return;
|
|
2559
2829
|
}
|
|
2560
2830
|
t.animations.forEach((e) => e.seek(0));
|
|
2561
2831
|
}
|
|
2562
|
-
function
|
|
2563
|
-
|
|
2832
|
+
function yi(e, t) {
|
|
2833
|
+
bi(e);
|
|
2564
2834
|
let n = {
|
|
2565
2835
|
animations: [],
|
|
2566
2836
|
cleanups: [],
|
|
2567
|
-
key:
|
|
2837
|
+
key: Mr(t),
|
|
2568
2838
|
looping: !1,
|
|
2569
2839
|
revealed: !1
|
|
2570
2840
|
};
|
|
2571
|
-
|
|
2572
|
-
let r =
|
|
2841
|
+
Er.set(e, n);
|
|
2842
|
+
let r = kr(t), i = jr();
|
|
2573
2843
|
if (!r || i && (r.loop || t.trigger === "scroll")) return;
|
|
2574
2844
|
let a = {
|
|
2575
2845
|
controller: n,
|
|
@@ -2579,52 +2849,54 @@ function $r(e, t) {
|
|
|
2579
2849
|
reduced: i,
|
|
2580
2850
|
trigger: i && t.trigger === "visible" ? "mount" : t.trigger
|
|
2581
2851
|
};
|
|
2582
|
-
if (n.looping =
|
|
2583
|
-
else if (t.
|
|
2852
|
+
if (n.looping = Nr(a) === !0, r.marquee) Zr(a), ii(a, e, Fr(a)), ai(a, () => yi(e, t));
|
|
2853
|
+
else if (t.split && !r.count) n.splitter = nr(e, { [t.split]: !0 }), ii(a, n.splitter[t.split], Fr(a));
|
|
2854
|
+
else if (t.stagger === void 0) ii(a, e, Fr(a));
|
|
2584
2855
|
else if (a.trigger === "mount" || a.trigger === "visible") {
|
|
2585
|
-
|
|
2856
|
+
fi(a);
|
|
2586
2857
|
return;
|
|
2587
|
-
} else
|
|
2588
|
-
|
|
2858
|
+
} else ii(a, ei(e), Fr(a)), ai(a, () => yi(e, t));
|
|
2859
|
+
vi(a);
|
|
2589
2860
|
}
|
|
2590
|
-
function
|
|
2591
|
-
let t =
|
|
2592
|
-
t && (t.cleanups.forEach((e) => e()), t.animations.forEach((e) => e.revert()), t.splitter?.revert(),
|
|
2861
|
+
function bi(e) {
|
|
2862
|
+
let t = Er.get(e);
|
|
2863
|
+
t && (t.cleanups.forEach((e) => e()), t.animations.forEach((e) => e.revert()), t.splitter?.revert(), Er.delete(e));
|
|
2593
2864
|
}
|
|
2594
|
-
function
|
|
2865
|
+
function xi(e) {
|
|
2595
2866
|
for (let t of e) {
|
|
2596
|
-
let e =
|
|
2597
|
-
e &&
|
|
2867
|
+
let e = Dr.get(t);
|
|
2868
|
+
e && yi(t, e);
|
|
2598
2869
|
}
|
|
2599
2870
|
}
|
|
2600
|
-
var
|
|
2871
|
+
var Si = {
|
|
2601
2872
|
mounted(e, { value: t }) {
|
|
2602
|
-
|
|
2873
|
+
Dr.set(e, t), yi(e, t);
|
|
2874
|
+
},
|
|
2875
|
+
unmounted(e) {
|
|
2876
|
+
Dr.delete(e), bi(e);
|
|
2603
2877
|
},
|
|
2604
2878
|
updated(e, { value: t }) {
|
|
2605
|
-
|
|
2606
|
-
let n =
|
|
2607
|
-
if (!n || n.key !==
|
|
2608
|
-
|
|
2879
|
+
Dr.set(e, t);
|
|
2880
|
+
let n = Er.get(e);
|
|
2881
|
+
if (!n || n.key !== Mr(t)) {
|
|
2882
|
+
yi(e, t);
|
|
2609
2883
|
return;
|
|
2610
2884
|
}
|
|
2611
|
-
t.trigger === "state" &&
|
|
2612
|
-
},
|
|
2613
|
-
unmounted(e) {
|
|
2614
|
-
ur.delete(e), ei(e);
|
|
2885
|
+
t.trigger === "state" && _i(n, !!t.state, !1);
|
|
2615
2886
|
}
|
|
2616
2887
|
};
|
|
2617
|
-
function
|
|
2888
|
+
function Ci(n) {
|
|
2618
2889
|
return e((e, { slots: a }) => {
|
|
2619
2890
|
let o = r();
|
|
2620
2891
|
return i((t) => {
|
|
2621
|
-
if (!o.value || !
|
|
2622
|
-
let r = n ? o.value.closest("[data-scroll-root]") ?? void 0 :
|
|
2892
|
+
if (!o.value || !yr.smoothScroll || jr()) return;
|
|
2893
|
+
let r = n ? o.value.closest("[data-scroll-root]") ?? void 0 : Lr(o.value);
|
|
2623
2894
|
if (n && !r) return;
|
|
2624
|
-
let i = new
|
|
2895
|
+
let i = new _r({
|
|
2896
|
+
anchors: yr.anchorScroll,
|
|
2625
2897
|
autoRaf: !0,
|
|
2626
2898
|
content: r ? o.value : void 0,
|
|
2627
|
-
lerp: e.lerp ??
|
|
2899
|
+
lerp: e.lerp ?? yr.smoothScrollLerp,
|
|
2628
2900
|
wrapper: r
|
|
2629
2901
|
});
|
|
2630
2902
|
t(() => i.destroy());
|
|
@@ -2634,6 +2906,6 @@ function ri(n) {
|
|
|
2634
2906
|
props: { lerp: Number }
|
|
2635
2907
|
});
|
|
2636
2908
|
}
|
|
2637
|
-
var
|
|
2909
|
+
var wi = Ci(!1);
|
|
2638
2910
|
//#endregion
|
|
2639
|
-
export {
|
|
2911
|
+
export { yr as a, Si as c, Ci as i, Mt as l, br as n, xr as o, vr as r, xi as s, wi as t };
|