@maycolem/stories 15.0.0 → 17.0.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/dist/index.cjs.js +2 -2
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +697 -694
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
package/dist/index.esm.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { jsx as S, jsxs as
|
|
1
|
+
import { jsx as S, jsxs as K, Fragment as Kn } from "react/jsx-runtime";
|
|
2
2
|
import * as Cn from "react";
|
|
3
3
|
import C, { useState as mt, useRef as Q, useCallback as ve, createContext as Gt, useMemo as Ke, useEffect as F, Fragment as zo, useContext as st, useLayoutEffect as Oa, forwardRef as La, createElement as Na } from "react";
|
|
4
4
|
import ja from "react-dom";
|
|
@@ -23,9 +23,9 @@ var un = { exports: {} };
|
|
|
23
23
|
Licensed under the MIT License (MIT), see
|
|
24
24
|
http://jedwatson.github.io/classnames
|
|
25
25
|
*/
|
|
26
|
-
var
|
|
26
|
+
var xr;
|
|
27
27
|
function Ya() {
|
|
28
|
-
return
|
|
28
|
+
return xr || (xr = 1, function(t) {
|
|
29
29
|
(function() {
|
|
30
30
|
var e = {}.hasOwnProperty;
|
|
31
31
|
function n() {
|
|
@@ -65,13 +65,13 @@ function Za() {
|
|
|
65
65
|
const i = a[0];
|
|
66
66
|
if (!i) return;
|
|
67
67
|
const { width: s, height: u } = i.contentRect;
|
|
68
|
-
e({ width: s, height: u });
|
|
68
|
+
s && u && e({ width: s, height: u });
|
|
69
69
|
}), n.current.observe(o));
|
|
70
70
|
}, []), t];
|
|
71
71
|
}
|
|
72
|
-
var ln,
|
|
72
|
+
var ln, Pr;
|
|
73
73
|
function Ka() {
|
|
74
|
-
return
|
|
74
|
+
return Pr || (Pr = 1, ln = { hexToRGB: (r) => {
|
|
75
75
|
let o = r;
|
|
76
76
|
return o.length === 4 && (o = o[0] + o[1] + o[1] + o[2] + o[2] + o[3] + o[3]), {
|
|
77
77
|
r: parseInt(o.substring(1, 3), 16),
|
|
@@ -80,10 +80,10 @@ function Ka() {
|
|
|
80
80
|
};
|
|
81
81
|
}, formatRGB: ({ r, g: o, b: a }) => `rgb(${r},${o},${a})`, formatRGBA: ({ r, g: o, b: a }, i) => `rgba(${r},${o},${a},${i})` }), ln;
|
|
82
82
|
}
|
|
83
|
-
var cn,
|
|
83
|
+
var cn, Tr;
|
|
84
84
|
function Ja() {
|
|
85
|
-
if (
|
|
86
|
-
|
|
85
|
+
if (Tr) return cn;
|
|
86
|
+
Tr = 1;
|
|
87
87
|
const { hexToRGB: t, formatRGB: e, formatRGBA: n } = Ka();
|
|
88
88
|
return cn = (o, a) => {
|
|
89
89
|
const i = t(o);
|
|
@@ -91,7 +91,7 @@ function Ja() {
|
|
|
91
91
|
}, cn;
|
|
92
92
|
}
|
|
93
93
|
var Qa = Ja();
|
|
94
|
-
const _a = /* @__PURE__ */ Uo(Qa),
|
|
94
|
+
const _a = /* @__PURE__ */ Uo(Qa), Jn = ({
|
|
95
95
|
image: t,
|
|
96
96
|
title: e,
|
|
97
97
|
color: n,
|
|
@@ -101,7 +101,7 @@ const _a = /* @__PURE__ */ Uo(Qa), Kn = ({
|
|
|
101
101
|
hasSeenAllStories: i
|
|
102
102
|
}) => {
|
|
103
103
|
const [s, { width: u, height: l }] = Za();
|
|
104
|
-
return /* @__PURE__ */ S("div", { ref: s, children: /* @__PURE__ */
|
|
104
|
+
return /* @__PURE__ */ S("div", { ref: s, children: /* @__PURE__ */ K(
|
|
105
105
|
"div",
|
|
106
106
|
{
|
|
107
107
|
className: qt(Ut.ProfileStory, r, {
|
|
@@ -175,10 +175,10 @@ let ls = class {
|
|
|
175
175
|
}, this.getVisible = () => this.filter((e) => e[1].visible), this.observer = new ls(), this.firstRun = !0;
|
|
176
176
|
}
|
|
177
177
|
};
|
|
178
|
-
const
|
|
178
|
+
const wr = (t) => typeof t == "object" && t != null && t.nodeType === 1, Vr = (t, e) => (!e || t !== "hidden") && t !== "visible" && t !== "clip", fn = (t, e) => {
|
|
179
179
|
if (t.clientHeight < t.scrollHeight || t.clientWidth < t.scrollWidth) {
|
|
180
180
|
const n = getComputedStyle(t, null);
|
|
181
|
-
return
|
|
181
|
+
return Vr(n.overflowY, e) || Vr(n.overflowX, e) || ((r) => {
|
|
182
182
|
const o = ((a) => {
|
|
183
183
|
if (!a.ownerDocument || !a.ownerDocument.defaultView) return null;
|
|
184
184
|
try {
|
|
@@ -194,43 +194,43 @@ const Tr = (t) => typeof t == "object" && t != null && t.nodeType === 1, wr = (t
|
|
|
194
194
|
}, Ee = (t, e, n, r, o, a, i, s) => a < t && i > e || a > t && i < e ? 0 : a <= t && s <= n || i >= e && s >= n ? a - t - r : i > e && s < n || a < t && s > n ? i - e + o : 0, fs = (t) => {
|
|
195
195
|
const e = t.parentElement;
|
|
196
196
|
return e ?? (t.getRootNode().host || null);
|
|
197
|
-
},
|
|
197
|
+
}, Er = (t, e) => {
|
|
198
198
|
var n, r, o, a;
|
|
199
199
|
if (typeof document > "u") return [];
|
|
200
|
-
const { scrollMode: i, block: s, inline: u, boundary: l, skipOverflowHiddenElements: c } = e, f = typeof l == "function" ? l : (
|
|
201
|
-
if (!
|
|
200
|
+
const { scrollMode: i, block: s, inline: u, boundary: l, skipOverflowHiddenElements: c } = e, f = typeof l == "function" ? l : ($) => $ !== l;
|
|
201
|
+
if (!wr(t)) throw new TypeError("Invalid target");
|
|
202
202
|
const d = document.scrollingElement || document.documentElement, p = [];
|
|
203
203
|
let v = t;
|
|
204
|
-
for (;
|
|
204
|
+
for (; wr(v) && f(v); ) {
|
|
205
205
|
if (v = fs(v), v === d) {
|
|
206
206
|
p.push(v);
|
|
207
207
|
break;
|
|
208
208
|
}
|
|
209
209
|
v != null && v === document.body && fn(v) && !fn(document.documentElement) || v != null && fn(v, c) && p.push(v);
|
|
210
210
|
}
|
|
211
|
-
const h = (r = (n = window.visualViewport) == null ? void 0 : n.width) != null ? r : innerWidth,
|
|
212
|
-
const I = window.getComputedStyle(
|
|
211
|
+
const h = (r = (n = window.visualViewport) == null ? void 0 : n.width) != null ? r : innerWidth, y = (a = (o = window.visualViewport) == null ? void 0 : o.height) != null ? a : innerHeight, { scrollX: m, scrollY: b } = window, { height: g, width: P, top: w, right: V, bottom: O, left: j } = t.getBoundingClientRect(), { top: A, right: k, bottom: _, left: W } = (($) => {
|
|
212
|
+
const I = window.getComputedStyle($);
|
|
213
213
|
return { top: parseFloat(I.scrollMarginTop) || 0, right: parseFloat(I.scrollMarginRight) || 0, bottom: parseFloat(I.scrollMarginBottom) || 0, left: parseFloat(I.scrollMarginLeft) || 0 };
|
|
214
214
|
})(t);
|
|
215
|
-
let H = s === "start" || s === "nearest" ? w -
|
|
216
|
-
const
|
|
217
|
-
for (let
|
|
218
|
-
const I = p[
|
|
219
|
-
if (i === "if-needed" && w >= 0 && j >= 0 &&
|
|
220
|
-
const T = getComputedStyle(I),
|
|
221
|
-
let G = 0,
|
|
222
|
-
const ot = "offsetWidth" in I ? I.offsetWidth - I.clientWidth -
|
|
223
|
-
if (d === I) G = s === "start" ? H : s === "end" ? H -
|
|
215
|
+
let H = s === "start" || s === "nearest" ? w - A : s === "end" ? O + _ : w + g / 2 - A + _, R = u === "center" ? j + P / 2 - W + k : u === "end" ? V + k : j - W;
|
|
216
|
+
const Y = [];
|
|
217
|
+
for (let $ = 0; $ < p.length; $++) {
|
|
218
|
+
const I = p[$], { height: it, width: at, top: ut, right: q, bottom: J, left: D } = I.getBoundingClientRect();
|
|
219
|
+
if (i === "if-needed" && w >= 0 && j >= 0 && O <= y && V <= h && w >= ut && O <= J && j >= D && V <= q) return Y;
|
|
220
|
+
const T = getComputedStyle(I), E = parseInt(T.borderLeftWidth, 10), N = parseInt(T.borderTopWidth, 10), L = parseInt(T.borderRightWidth, 10), B = parseInt(T.borderBottomWidth, 10);
|
|
221
|
+
let G = 0, rt = 0;
|
|
222
|
+
const ot = "offsetWidth" in I ? I.offsetWidth - I.clientWidth - E - L : 0, et = "offsetHeight" in I ? I.offsetHeight - I.clientHeight - N - B : 0, Et = "offsetWidth" in I ? I.offsetWidth === 0 ? 0 : at / I.offsetWidth : 0, te = "offsetHeight" in I ? I.offsetHeight === 0 ? 0 : it / I.offsetHeight : 0;
|
|
223
|
+
if (d === I) G = s === "start" ? H : s === "end" ? H - y : s === "nearest" ? Ee(b, b + y, y, N, B, b + H, b + H + g, g) : H - y / 2, rt = u === "start" ? R : u === "center" ? R - h / 2 : u === "end" ? R - h : Ee(m, m + h, h, E, L, m + R, m + R + P, P), G = Math.max(0, G + b), rt = Math.max(0, rt + m);
|
|
224
224
|
else {
|
|
225
|
-
G = s === "start" ? H - ut - N : s === "end" ? H - J + B +
|
|
225
|
+
G = s === "start" ? H - ut - N : s === "end" ? H - J + B + et : s === "nearest" ? Ee(ut, J, it, N, B + et, H, H + g, g) : H - (ut + it / 2) + et / 2, rt = u === "start" ? R - D - E : u === "center" ? R - (D + at / 2) + ot / 2 : u === "end" ? R - q + L + ot : Ee(D, q, at, E, L + ot, R, R + P, P);
|
|
226
226
|
const { scrollLeft: ee, scrollTop: ne } = I;
|
|
227
|
-
G = te === 0 ? 0 : Math.max(0, Math.min(ne + G / te, I.scrollHeight - it / te +
|
|
227
|
+
G = te === 0 ? 0 : Math.max(0, Math.min(ne + G / te, I.scrollHeight - it / te + et)), rt = Et === 0 ? 0 : Math.max(0, Math.min(ee + rt / Et, I.scrollWidth - at / Et + ot)), H += ne - G, R += ee - rt;
|
|
228
228
|
}
|
|
229
|
-
|
|
229
|
+
Y.push({ el: I, top: G, left: rt });
|
|
230
230
|
}
|
|
231
|
-
return
|
|
231
|
+
return Y;
|
|
232
232
|
};
|
|
233
|
-
function
|
|
233
|
+
function Cr(t, e) {
|
|
234
234
|
if (!t.isConnected || !((o) => {
|
|
235
235
|
let a = o;
|
|
236
236
|
for (; a && a.parentNode; ) {
|
|
@@ -243,9 +243,9 @@ function Er(t, e) {
|
|
|
243
243
|
const a = window.getComputedStyle(o);
|
|
244
244
|
return { top: parseFloat(a.scrollMarginTop) || 0, right: parseFloat(a.scrollMarginRight) || 0, bottom: parseFloat(a.scrollMarginBottom) || 0, left: parseFloat(a.scrollMarginLeft) || 0 };
|
|
245
245
|
})(t);
|
|
246
|
-
if (((o) => typeof o == "object" && typeof o.behavior == "function")(e)) return e.behavior(
|
|
246
|
+
if (((o) => typeof o == "object" && typeof o.behavior == "function")(e)) return e.behavior(Er(t, e));
|
|
247
247
|
const r = typeof e == "boolean" || e == null ? void 0 : e.behavior;
|
|
248
|
-
for (const { el: o, top: a, left: i } of
|
|
248
|
+
for (const { el: o, top: a, left: i } of Er(t, ((s) => s === !1 ? { block: "end", inline: "nearest" } : ((u) => u === Object(u) && Object.keys(u).length !== 0)(s) ? s : { block: "start", inline: "nearest" })(e))) {
|
|
249
249
|
const s = a - n.top + n.bottom, u = i - n.left + n.right;
|
|
250
250
|
o.scroll({ top: s, left: u, behavior: r });
|
|
251
251
|
}
|
|
@@ -266,11 +266,11 @@ function ds(t, e, n) {
|
|
|
266
266
|
}
|
|
267
267
|
const vs = function(t, e) {
|
|
268
268
|
const n = e || {};
|
|
269
|
-
return ((r) => r && !r.behavior || r.behavior === "smooth")(n) ?
|
|
269
|
+
return ((r) => r && !r.behavior || r.behavior === "smooth")(n) ? Cr(t, { block: n.block, inline: n.inline, scrollMode: n.scrollMode, boundary: n.boundary, skipOverflowHiddenElements: n.skipOverflowHiddenElements, behavior: (r) => Promise.all(r.reduce((o, a) => {
|
|
270
270
|
let { el: i, left: s, top: u } = a;
|
|
271
271
|
const l = i.scrollLeft, c = i.scrollTop;
|
|
272
272
|
return l === s && c === u ? o : [...o, new Promise((f) => ds(i, s, u, n.duration, n.ease, () => f({ el: i, left: [l, s], top: [c, u] }), n.onScrollChange))];
|
|
273
|
-
}, [])) }) : Promise.resolve(
|
|
273
|
+
}, [])) }) : Promise.resolve(Cr(t, e));
|
|
274
274
|
}, ps = (t) => Object.values(t).map((e) => e.current).filter(Boolean);
|
|
275
275
|
function vn(t, e, n, r, o, a) {
|
|
276
276
|
var i;
|
|
@@ -326,64 +326,64 @@ function Ps({ items: t, itemsChanged: e, refs: n, options: r }) {
|
|
|
326
326
|
};
|
|
327
327
|
}, [a, e, r, n]);
|
|
328
328
|
}
|
|
329
|
-
const Ts = (t) => C.Children.toArray(t).map(Jo).filter(Boolean),
|
|
329
|
+
const Ts = (t) => C.Children.toArray(t).map(Jo).filter(Boolean), Ar = { ratio: 0.9, rootMargin: "5px", threshold: [0.05, 0.5, 0.75, 0.95] }, ws = { current: {} }, Ae = () => {
|
|
330
330
|
};
|
|
331
|
-
function Vs({ LeftArrow: t, RightArrow: e, children: n, Header: r, Footer: o, transitionDuration: a = 500, transitionBehavior: i, onInit: s = Ae, onUpdate: u = Ae, onMouseDown: l, onMouseLeave: c, onMouseUp: f, onMouseMove: d, onScroll: p = Ae, onTouchMove: v, onTouchStart: h, onTouchEnd:
|
|
332
|
-
const k = Ce(t),
|
|
333
|
-
const [G,
|
|
331
|
+
function Vs({ LeftArrow: t, RightArrow: e, children: n, Header: r, Footer: o, transitionDuration: a = 500, transitionBehavior: i, onInit: s = Ae, onUpdate: u = Ae, onMouseDown: l, onMouseLeave: c, onMouseUp: f, onMouseMove: d, onScroll: p = Ae, onTouchMove: v, onTouchStart: h, onTouchEnd: y, onWheel: m = Ae, options: b = Ar, scrollContainerClassName: g = pt, containerRef: P = us, itemClassName: w = pt, wrapperClassName: V = pt, apiRef: O = ws, RTL: j, noPolyfill: A }) {
|
|
332
|
+
const k = Ce(t), _ = Ce(e), W = Ce(r), H = Ce(o), R = C.useRef(null), [Y] = C.useState({}), $ = C.useMemo(() => Object.assign(Object.assign(Object.assign({}, Ar), b), { root: R.current }), [b]), I = C.useRef(new cs()).current, it = function(L, B) {
|
|
333
|
+
const [G, rt] = C.useState(pt), ot = C.useMemo(() => Ts(L), [L]);
|
|
334
334
|
return C.useEffect(() => {
|
|
335
|
-
const
|
|
335
|
+
const et = ot.filter(Boolean).join(pt);
|
|
336
336
|
B.toItems().filter((Et) => !ot.includes(Et)).forEach((Et) => {
|
|
337
337
|
B.delete(Et);
|
|
338
|
-
}),
|
|
338
|
+
}), rt(et);
|
|
339
339
|
}, [ot, B]), G;
|
|
340
340
|
}(n, I);
|
|
341
|
-
Ps(C.useMemo(() => ({ items: I, itemsChanged: it, options:
|
|
341
|
+
Ps(C.useMemo(() => ({ items: I, itemsChanged: it, options: $, refs: Y }), [I, it, Y, $]));
|
|
342
342
|
const at = C.useMemo(() => function(L, B, G) {
|
|
343
|
-
var
|
|
344
|
-
const Et = !!(!((
|
|
345
|
-
var
|
|
346
|
-
return (
|
|
343
|
+
var rt, ot, et;
|
|
344
|
+
const Et = !!(!((rt = L.first()) === null || rt === void 0) && rt.visible), te = !!(!((ot = L.last()) === null || ot === void 0) && ot.visible), ee = (z) => {
|
|
345
|
+
var X;
|
|
346
|
+
return (X = L.find((ft) => ft[1].key === String(z))) === null || X === void 0 ? void 0 : X[1];
|
|
347
347
|
}, ne = () => {
|
|
348
|
-
var z,
|
|
349
|
-
const ft = (
|
|
348
|
+
var z, X;
|
|
349
|
+
const ft = (X = (z = L.getVisible()) === null || z === void 0 ? void 0 : z[0]) === null || X === void 0 ? void 0 : X[1];
|
|
350
350
|
return ft ? L.prev(ft) : void 0;
|
|
351
|
-
},
|
|
351
|
+
}, br = () => {
|
|
352
352
|
var z;
|
|
353
|
-
const
|
|
354
|
-
return
|
|
355
|
-
}, an = (
|
|
353
|
+
const X = (z = L.getVisible().findLast(() => !0)) === null || z === void 0 ? void 0 : z[1];
|
|
354
|
+
return X ? L.next(X) : void 0;
|
|
355
|
+
}, an = (et = B == null ? void 0 : B.boundary) === null || et === void 0 ? void 0 : et.current;
|
|
356
356
|
return { getItemById: ee, getItemElementById: hs, getItemByIndex: (z) => {
|
|
357
|
-
var
|
|
358
|
-
return (
|
|
359
|
-
}, getItemElementByIndex: ms, getNextElement:
|
|
357
|
+
var X;
|
|
358
|
+
return (X = L.find((ft) => String(ft[1].index) === String(z))) === null || X === void 0 ? void 0 : X[1];
|
|
359
|
+
}, getItemElementByIndex: ms, getNextElement: br, getPrevElement: ne, isFirstItemVisible: Et, isItemVisible: (z) => L.getVisible().map((X) => X[0]).includes(String(z)), isLastItem: (z) => L.last() === ee(z), isLastItemVisible: te, scrollNext: (z, X, ft, { duration: Ct, boundary: yt = an } = {}) => {
|
|
360
360
|
const Pt = z ?? (B == null ? void 0 : B.behavior);
|
|
361
|
-
return vn(
|
|
362
|
-
}, scrollPrev: (z,
|
|
361
|
+
return vn(br(), Pt, X || "start", ft || "nearest", { boundary: yt, duration: Ct ?? (B == null ? void 0 : B.duration) }, G);
|
|
362
|
+
}, scrollPrev: (z, X, ft, { duration: Ct, boundary: yt = an } = {}) => {
|
|
363
363
|
const Pt = z ?? (B == null ? void 0 : B.behavior);
|
|
364
|
-
return vn(ne(), Pt,
|
|
365
|
-
}, useIsVisible: (z,
|
|
366
|
-
const [ft, Ct] = C.useState(
|
|
364
|
+
return vn(ne(), Pt, X || "end", ft || "nearest", { boundary: yt, duration: Ct ?? (B == null ? void 0 : B.duration) }, G);
|
|
365
|
+
}, useIsVisible: (z, X = !1) => {
|
|
366
|
+
const [ft, Ct] = C.useState(X), yt = C.useCallback((Pt) => {
|
|
367
367
|
Ct(!!(Pt != null && Pt.visible));
|
|
368
368
|
}, []);
|
|
369
369
|
return C.useEffect(() => (L.subscribe(z, yt), () => {
|
|
370
370
|
L.unsubscribe(z, yt);
|
|
371
371
|
}), [z, yt]), ft;
|
|
372
|
-
}, scrollToItem: (z,
|
|
372
|
+
}, scrollToItem: (z, X, ft, Ct, yt) => {
|
|
373
373
|
var Pt;
|
|
374
|
-
return vn(z,
|
|
374
|
+
return vn(z, X ?? (B == null ? void 0 : B.behavior), ft, Ct, Object.assign(Object.assign({ boundary: an }, yt), { duration: (Pt = yt == null ? void 0 : yt.duration) !== null && Pt !== void 0 ? Pt : B == null ? void 0 : B.duration }), G);
|
|
375
375
|
} };
|
|
376
|
-
}(I, { duration: a, behavior: i, boundary:
|
|
376
|
+
}(I, { duration: a, behavior: i, boundary: R }, A), [I, a, i, A]), ut = C.useCallback(() => Object.assign(Object.assign({}, at), { items: I, scrollContainer: R }), [at, I, R]), [q, J] = C.useState(() => ut());
|
|
377
377
|
(({ context: L, onInit: B, onUpdate: G }) => {
|
|
378
|
-
const
|
|
379
|
-
C.useEffect(() => (
|
|
380
|
-
|
|
381
|
-
}), [
|
|
382
|
-
})({ context:
|
|
383
|
-
An(
|
|
384
|
-
}, [
|
|
385
|
-
const D = C.useCallback((L) => p(
|
|
386
|
-
return C.createElement("div", { className:
|
|
378
|
+
const rt = C.useCallback(() => B(L), [B, L]), ot = C.useCallback(() => G(L), [G, L]), { items: et } = L;
|
|
379
|
+
C.useEffect(() => (et.subscribe(xt.onInit, rt), et.subscribe(xt.onUpdate, ot), () => {
|
|
380
|
+
et.unsubscribe(xt.onInit, rt), et.unsubscribe(xt.onUpdate, ot);
|
|
381
|
+
}), [et, rt, ot]);
|
|
382
|
+
})({ context: q, onInit: s, onUpdate: u }), C.useEffect(() => J(ut()), [ut]), C.useEffect(() => {
|
|
383
|
+
An(O) ? O.current = q : O(q);
|
|
384
|
+
}, [q, O]);
|
|
385
|
+
const D = C.useCallback((L) => p(q, L), [p, q]), T = C.useCallback((L) => m(q, L), [m, q]), E = C.useMemo(() => `${es} ${V}`, [V]), N = C.useMemo(() => `${g}${j ? " rtl" : pt}`, [j, g]);
|
|
386
|
+
return C.createElement("div", { className: E, onWheel: T, onMouseDown: l == null ? void 0 : l(q), onMouseLeave: c == null ? void 0 : c(q), onMouseUp: f == null ? void 0 : f(q), onMouseMove: d == null ? void 0 : d(q), onTouchStart: h == null ? void 0 : h(q), onTouchMove: v == null ? void 0 : v(q), onTouchEnd: y == null ? void 0 : y(q) }, C.createElement(bs.Provider, { value: q }, C.createElement("div", { className: rs }, W), C.createElement("div", { className: ns }, C.createElement("div", { className: os }, k), C.createElement(Ss, { className: N, onScroll: D, scrollRef: R, containerRef: P }, C.createElement(ys, { refs: Y, itemClassName: w }, n)), C.createElement("div", { className: is }, _)), C.createElement("div", { className: as }, H)));
|
|
387
387
|
}
|
|
388
388
|
const Es = "_StoryPlayer_3s15o_1", Cs = "_Overlay_3s15o_15", As = "_StoryPlayer__Wrap_3s15o_25", Rs = "_progressContainer_3s15o_37", Ms = "_CloseIcon_3s15o_41", Is = "_inline_3s15o_57", Os = "_progressBarContainer_3s15o_75", Ls = "_progressBar_3s15o_75", Ot = {
|
|
389
389
|
StoryPlayer: Es,
|
|
@@ -395,11 +395,11 @@ const Es = "_StoryPlayer_3s15o_1", Cs = "_Overlay_3s15o_15", As = "_StoryPlayer_
|
|
|
395
395
|
progressBarContainer: Os,
|
|
396
396
|
progressBar: Ls
|
|
397
397
|
};
|
|
398
|
-
var
|
|
399
|
-
return
|
|
398
|
+
var Z = function() {
|
|
399
|
+
return Z = Object.assign || function(t) {
|
|
400
400
|
for (var e, n = 1, r = arguments.length; n < r; n++) for (var o in e = arguments[n]) Object.prototype.hasOwnProperty.call(e, o) && (t[o] = e[o]);
|
|
401
401
|
return t;
|
|
402
|
-
},
|
|
402
|
+
}, Z.apply(this, arguments);
|
|
403
403
|
}, Qo = Gt({ stories: [], width: "100%", height: "100%", defaultDuration: 1e4, isPaused: !1 }), pn = Object.freeze({ LEFT: "left", RIGHT: "right" }), Ns = "Actions-styles_left__eky50", js = "Actions-styles_right__zguoH";
|
|
404
404
|
function Ds(t) {
|
|
405
405
|
var e = t.onNextClick, n = t.onPrevClick, r = t.onPause, o = t.onResume, a = mt(!1), i = a[0], s = a[1], u = Q(null);
|
|
@@ -423,12 +423,12 @@ function Ds(t) {
|
|
|
423
423
|
return l(p);
|
|
424
424
|
} };
|
|
425
425
|
}
|
|
426
|
-
return
|
|
426
|
+
return K(zo, { children: [S("div", Z({ className: Ns }, f(pn.LEFT))), S("div", Z({ className: js }, f(pn.RIGHT)))] });
|
|
427
427
|
}
|
|
428
428
|
function Je() {
|
|
429
429
|
return st(Qo);
|
|
430
430
|
}
|
|
431
|
-
var Bs = "ProgressBar-styles_wrapper__oqUCo", ks = "ProgressBar-styles_bar__x0O50",
|
|
431
|
+
var Bs = "ProgressBar-styles_wrapper__oqUCo", ks = "ProgressBar-styles_bar__x0O50", Rr = 0, Mr = 0.1;
|
|
432
432
|
function Fs(t) {
|
|
433
433
|
var e, n, r, o, a, i = Je(), s = i.defaultDuration, u = i.classNames, l = Q(null), c = Q(null), f = mt(!1), d = f[0], p = f[1];
|
|
434
434
|
return F(function() {
|
|
@@ -438,14 +438,14 @@ function Fs(t) {
|
|
|
438
438
|
l.current && (t.hasStoryPassed ? l.current.style.width = "".concat((v = c == null ? void 0 : c.current) === null || v === void 0 ? void 0 : v.offsetWidth, "px") : l.current.style.width = "0px");
|
|
439
439
|
}, [t.hasStoryPassed, t.isActive]), e = function(v) {
|
|
440
440
|
var h;
|
|
441
|
-
l.current && c.current && ((
|
|
441
|
+
l.current && c.current && ((Rr = Number((l.current.style.width || "1px").slice(0, l.current.style.width.length - 2)) || 0) > c.current.offsetWidth ? p(!1) : (Mr = ((h = c == null ? void 0 : c.current) === null || h === void 0 ? void 0 : h.offsetWidth) / ((t.story.duration || s) / v), l.current.style.width = "".concat(Rr + Mr, "px")));
|
|
442
442
|
}, n = d, r = Q(), o = Q(), a = Q(e), F(function() {
|
|
443
443
|
a.current = e;
|
|
444
444
|
}, [e]), F(function() {
|
|
445
445
|
return n !== !1 ? (r.current = requestAnimationFrame(function v(h) {
|
|
446
446
|
if (o.current != null) {
|
|
447
|
-
var
|
|
448
|
-
a.current(
|
|
447
|
+
var y = h - o.current;
|
|
448
|
+
a.current(y);
|
|
449
449
|
}
|
|
450
450
|
o.current = h, r.current = requestAnimationFrame(v);
|
|
451
451
|
}), function() {
|
|
@@ -453,12 +453,12 @@ function Fs(t) {
|
|
|
453
453
|
}) : function() {
|
|
454
454
|
r.current && (r.current = null), cancelAnimationFrame(r.current), o.current = null;
|
|
455
455
|
};
|
|
456
|
-
}, [n]), S("div",
|
|
456
|
+
}, [n]), S("div", Z({ className: "".concat(Bs, " ").concat((u == null ? void 0 : u.progressBarContainer) || ""), ref: c }, { children: S("div", { className: "".concat(ks, " ").concat((u == null ? void 0 : u.progressBar) || ""), ref: l }) }));
|
|
457
457
|
}
|
|
458
458
|
var Hs = "progress-styles_wrapper__qQPyW";
|
|
459
459
|
function Ws(t) {
|
|
460
460
|
var e = Je(), n = e.stories, r = e.classNames;
|
|
461
|
-
return S("div",
|
|
461
|
+
return S("div", Z({ className: "".concat(Hs, " ").concat((r == null ? void 0 : r.progressContainer) || ""), style: { gridTemplateColumns: "repeat(".concat(n.length, ",1fr)") } }, { children: n.map(function(o) {
|
|
462
462
|
return S(Fs, { hasStoryPassed: o.index < t.activeStoryIndex, isActive: o.index === t.activeStoryIndex, story: o, isPaused: o.index === t.activeStoryIndex && t.isPaused }, o.index);
|
|
463
463
|
}) }));
|
|
464
464
|
}
|
|
@@ -474,7 +474,7 @@ function Us(t) {
|
|
|
474
474
|
}
|
|
475
475
|
var mn, Ys = "Video-styles_video__BykuO", Xs = "Video-styles_loaderWrapper__TqVWk", Zs = "Video-styles_loader__FxxSV", Ks = "Video-styles_soundIcon__ZvYXE";
|
|
476
476
|
function Js(t) {
|
|
477
|
-
return t.type === "off" ? S("svg",
|
|
477
|
+
return t.type === "off" ? S("svg", Z({ xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", viewBox: "0 0 24 24", fill: "white" }, { children: S("path", { d: "M3 9v6h-1v-6h1zm13-7l-9 5v2.288l7-3.889v13.202l-7-3.889v2.288l9 5v-20zm-11 5h-5v10h5v-10zm17.324 4.993l1.646-1.659-1.324-1.324-1.651 1.67-1.665-1.648-1.316 1.318 1.67 1.657-1.65 1.669 1.318 1.317 1.658-1.672 1.666 1.653 1.324-1.325-1.676-1.656z" }) })) : S("svg", Z({ xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", viewBox: "0 0 24 24", fill: "white" }, { children: S("path", { d: "M22 0v24l-11-6v-2.278l9 4.909v-17.262l-9 4.91v-2.279l11-6zm-13 6v12h-7v-12h7zm-2 2h-3v8h3v-8z" }) }));
|
|
478
478
|
}
|
|
479
479
|
var Rn = "RSIsMute", Yt = typeof window > "u" ? {} : window;
|
|
480
480
|
function Qs(t) {
|
|
@@ -490,41 +490,41 @@ function Qs(t) {
|
|
|
490
490
|
var f;
|
|
491
491
|
c(!0), (f = l.current) === null || f === void 0 || f.play();
|
|
492
492
|
}) : l.current.pause());
|
|
493
|
-
}, [n]),
|
|
493
|
+
}, [n]), K(zo, { children: [K("video", Z({ className: Ys, ref: l, playsInline: !0, "webkit-playsinline": "", controls: !1, src: t.story.url, onLoadedData: function() {
|
|
494
494
|
setTimeout(function() {
|
|
495
495
|
t.onResume(), u(!1);
|
|
496
496
|
}, 4);
|
|
497
|
-
}, muted: o }, { children: [S("source", { src: t.story.url, type: "video/mp4" }), S("source", { src: t.story.url, type: "video/webm" }), S("source", { src: t.story.url, type: "video/ogg" }), S("p", { children: "Video not supported" })] })), S("div",
|
|
497
|
+
}, muted: o }, { children: [S("source", { src: t.story.url, type: "video/mp4" }), S("source", { src: t.story.url, type: "video/webm" }), S("source", { src: t.story.url, type: "video/ogg" }), S("p", { children: "Video not supported" })] })), S("div", Z({ className: Ks, onClick: function() {
|
|
498
498
|
return c(!o);
|
|
499
|
-
} }, { children: S(Js, { type: o ? "off" : "on" }) })), s && S("div",
|
|
499
|
+
} }, { children: S(Js, { type: o ? "off" : "on" }) })), s && S("div", Z({ className: Xs }, { children: S("div", { className: Zs }) }))] });
|
|
500
500
|
}
|
|
501
501
|
(mn = Yt == null ? void 0 : Yt.localStorage) === null || mn === void 0 || mn.setItem(Rn, "true");
|
|
502
502
|
var _s = "CustomComponents-styles_component__w87Wx";
|
|
503
503
|
function $s(t) {
|
|
504
|
-
return S("div",
|
|
504
|
+
return S("div", Z({ className: _s }, { children: S(t.story.component, { pause: t.onPause, resume: t.onResume, story: t.story, isPaused: t.isPaused }) }));
|
|
505
505
|
}
|
|
506
506
|
var tu = "SeeMore-styles_seeMoreWrapper__kwjif", eu = "SeeMore-styles_defaultSeeMore__-B1QW";
|
|
507
507
|
function nu(t) {
|
|
508
|
-
return t.story.seeMore ? S("button",
|
|
508
|
+
return t.story.seeMore ? S("button", Z({ type: "button", onClick: function() {
|
|
509
509
|
t.onSeeMoreClick();
|
|
510
510
|
}, className: tu }, { children: function() {
|
|
511
511
|
var e = t.story.seeMore, n = typeof e;
|
|
512
512
|
if (["string", "boolean"].includes(n)) {
|
|
513
513
|
var r = n === "string" ? e : "See More";
|
|
514
|
-
return
|
|
514
|
+
return K("div", Z({ className: eu }, { children: [S("span", { children: "^" }), S("p", { children: r })] }));
|
|
515
515
|
}
|
|
516
516
|
return n === "function" ? S(t.story.seeMore, {}) : t.story.seeMore;
|
|
517
517
|
}() })) : null;
|
|
518
518
|
}
|
|
519
519
|
var ru = "SeeMoreComponent-styles_seeMoreComponentWrapper__0T6Ap", ou = "SeeMoreComponent-styles_closeIcon__LMm3b";
|
|
520
520
|
function iu(t) {
|
|
521
|
-
return t.story.seeMore && t.story.seeMoreComponent ?
|
|
521
|
+
return t.story.seeMore && t.story.seeMoreComponent ? K("div", Z({ className: ru }, { children: [S("button", Z({ className: ou, onClick: t.onClose }, { children: "✕" })), typeof t.story.seeMoreComponent == "function" ? S(t.story.seeMoreComponent, {}) : t.story.seeMoreComponent] })) : null;
|
|
522
522
|
}
|
|
523
523
|
function au(t) {
|
|
524
524
|
var e = mt(!1), n = e[0], r = e[1], o = Je().classNames;
|
|
525
525
|
return F(function() {
|
|
526
526
|
r(!1);
|
|
527
|
-
}, [t.story]),
|
|
527
|
+
}, [t.story]), K("div", Z({ className: "".concat(qs, " ").concat((o == null ? void 0 : o.storyContainer) || "") }, { children: [t.story.type === hn.IMAGE ? S(Us, Z({}, t)) : t.story.type === hn.VIDEO ? S(Qs, Z({}, t)) : t.story.type === hn.COMPONENT ? S($s, Z({}, t)) : null, t.story.header && S("div", Z({ className: Gs }, { children: typeof t.story.header == "function" ? S(t.story.header, {}) : t.story.header })), S(nu, { onSeeMoreClick: function() {
|
|
528
528
|
var a, i;
|
|
529
529
|
t.onPause(), r(!0), (i = (a = t.story).onSeeMoreClick) === null || i === void 0 || i.call(a, t.story.index);
|
|
530
530
|
}, story: t.story }), n && S(iu, { story: t.story, onClose: function() {
|
|
@@ -532,27 +532,27 @@ function au(t) {
|
|
|
532
532
|
} })] }));
|
|
533
533
|
}
|
|
534
534
|
var su = "styles_main__-0FEu";
|
|
535
|
-
function
|
|
535
|
+
function Ir(t) {
|
|
536
536
|
return t === void 0 && (t = 4), Number(Math.random().toFixed(t));
|
|
537
537
|
}
|
|
538
538
|
function uu(t) {
|
|
539
539
|
var e, n, r, o, a, i, s, u = t.stories, l = u === void 0 ? [] : u, c = t.width, f = c === void 0 ? "100%" : c, d = t.height, p = d === void 0 ? "100%" : d, v = t.onStoryChange, h = v === void 0 ? function() {
|
|
540
|
-
} : v,
|
|
541
|
-
} : P,
|
|
542
|
-
} :
|
|
540
|
+
} : v, y = t.currentIndex, m = y === void 0 ? 0 : y, b = t.defaultDuration, g = b === void 0 ? 1e4 : b, P = t.onAllStoriesEnd, w = P === void 0 ? function() {
|
|
541
|
+
} : P, V = t.onStoriesStart, O = V === void 0 ? function() {
|
|
542
|
+
} : V, j = t.classNames, A = j === void 0 ? {} : j, k = t.pauseStoryWhenInActiveWindow, _ = k === void 0 || k, W = Ke(function() {
|
|
543
543
|
return function(N, L) {
|
|
544
544
|
var B = 0;
|
|
545
|
-
return N.map(function(G,
|
|
546
|
-
var ot = G.duration || L,
|
|
547
|
-
return
|
|
545
|
+
return N.map(function(G, rt) {
|
|
546
|
+
var ot = G.duration || L, et = ot + Ir();
|
|
547
|
+
return et === B && (et = ot + Ir(6)), B = et, Z(Z({}, G), { index: rt, calculatedDuration: et });
|
|
548
548
|
});
|
|
549
|
-
}(l,
|
|
550
|
-
}, [l,
|
|
549
|
+
}(l, g);
|
|
550
|
+
}, [l, g]), H = mt(), R = H[0], Y = H[1], $ = l.length - 1, I = mt(!1), it = I[0], at = I[1], ut = Q(!1), q = Q(!1);
|
|
551
551
|
function J() {
|
|
552
|
-
ut.current || (
|
|
553
|
-
if (!N) return
|
|
552
|
+
ut.current || (R == null ? void 0 : R.index) !== $ || (w(), ut.current = !0), (R == null ? void 0 : R.index) !== $ && Y(function(N) {
|
|
553
|
+
if (!N) return W[0];
|
|
554
554
|
var L = (N == null ? void 0 : N.index) + 1;
|
|
555
|
-
return
|
|
555
|
+
return W[L];
|
|
556
556
|
});
|
|
557
557
|
}
|
|
558
558
|
function D() {
|
|
@@ -562,15 +562,15 @@ function uu(t) {
|
|
|
562
562
|
at(!1);
|
|
563
563
|
}
|
|
564
564
|
F(function() {
|
|
565
|
-
|
|
566
|
-
}, [
|
|
567
|
-
var N =
|
|
568
|
-
N &&
|
|
565
|
+
q.current || (q.current = !0, O());
|
|
566
|
+
}, [O]), F(function() {
|
|
567
|
+
var N = W[m];
|
|
568
|
+
N && Y(N);
|
|
569
569
|
}, [m, l]), F(function() {
|
|
570
|
-
|
|
571
|
-
}, [
|
|
570
|
+
R && h(R.index);
|
|
571
|
+
}, [R]), n = function() {
|
|
572
572
|
J();
|
|
573
|
-
}, r = (e =
|
|
573
|
+
}, r = (e = R == null ? void 0 : R.calculatedDuration) !== null && e !== void 0 ? e : null, o = it, a = Q(), i = Q(r), s = Q(Date.now()), F(function() {
|
|
574
574
|
a.current = n;
|
|
575
575
|
}, [n]), F(function() {
|
|
576
576
|
i.current = r;
|
|
@@ -604,14 +604,14 @@ function uu(t) {
|
|
|
604
604
|
};
|
|
605
605
|
}, []);
|
|
606
606
|
}(function(N) {
|
|
607
|
-
|
|
607
|
+
_ && at(!N);
|
|
608
608
|
});
|
|
609
|
-
var
|
|
610
|
-
return
|
|
611
|
-
(
|
|
612
|
-
if (!N) return
|
|
609
|
+
var E = { stories: W, width: f, height: p, defaultDuration: g, isPaused: it, classNames: A };
|
|
610
|
+
return R ? S(Qo.Provider, Z({ value: E }, { children: K("div", Z({ className: "".concat(su, " ").concat(A.main || ""), style: { width: f, height: p } }, { children: [S(Ws, { activeStoryIndex: R.index, isPaused: it }), S(au, { onPause: D, onResume: T, story: R, isPaused: it }, R.index), S(Ds, { onNextClick: J, onPrevClick: function() {
|
|
611
|
+
(R == null ? void 0 : R.index) !== 0 && Y(function(N) {
|
|
612
|
+
if (!N) return W[0];
|
|
613
613
|
var L = (N == null ? void 0 : N.index) - 1;
|
|
614
|
-
return
|
|
614
|
+
return W[L];
|
|
615
615
|
});
|
|
616
616
|
}, onPause: D, onResume: T })] })) })) : null;
|
|
617
617
|
}
|
|
@@ -648,7 +648,7 @@ function gt(t, e) {
|
|
|
648
648
|
e.indexOf(r[o]) < 0 && Object.prototype.propertyIsEnumerable.call(t, r[o]) && (n[r[o]] = t[r[o]]);
|
|
649
649
|
return n;
|
|
650
650
|
}
|
|
651
|
-
function
|
|
651
|
+
function nt(t, e) {
|
|
652
652
|
var n = typeof Symbol == "function" && t[Symbol.iterator];
|
|
653
653
|
if (!n) return t;
|
|
654
654
|
var r = n.call(t), o, a = [], i;
|
|
@@ -670,7 +670,7 @@ function ht(t, e, n) {
|
|
|
670
670
|
(a || !(r in e)) && (a || (a = Array.prototype.slice.call(e, 0, r)), a[r] = e[r]);
|
|
671
671
|
return t.concat(a || Array.prototype.slice.call(e));
|
|
672
672
|
}
|
|
673
|
-
var
|
|
673
|
+
var Or = "production", $o = typeof process > "u" || process.env === void 0 ? Or : process.env.NODE_ENV || Or, At = function(t) {
|
|
674
674
|
return {
|
|
675
675
|
isEnabled: function(e) {
|
|
676
676
|
return t.some(function(n) {
|
|
@@ -732,7 +732,7 @@ function fu(t, e, n) {
|
|
|
732
732
|
}
|
|
733
733
|
return r;
|
|
734
734
|
}
|
|
735
|
-
var
|
|
735
|
+
var Qn = Gt({
|
|
736
736
|
transformPagePoint: function(t) {
|
|
737
737
|
return t;
|
|
738
738
|
},
|
|
@@ -742,7 +742,7 @@ var Jn = Gt({
|
|
|
742
742
|
function du() {
|
|
743
743
|
return st(Qe).visualElement;
|
|
744
744
|
}
|
|
745
|
-
var _e = Gt(null), $t = typeof document < "u",
|
|
745
|
+
var _e = Gt(null), $t = typeof document < "u", Lr = $t ? Oa : F, In = { current: null }, ni = !1;
|
|
746
746
|
function vu() {
|
|
747
747
|
if (ni = !0, !!$t)
|
|
748
748
|
if (window.matchMedia) {
|
|
@@ -755,11 +755,11 @@ function vu() {
|
|
|
755
755
|
}
|
|
756
756
|
function pu() {
|
|
757
757
|
!ni && vu();
|
|
758
|
-
var t =
|
|
758
|
+
var t = nt(mt(In.current), 1), e = t[0];
|
|
759
759
|
return e;
|
|
760
760
|
}
|
|
761
761
|
function hu() {
|
|
762
|
-
var t = pu(), e = st(
|
|
762
|
+
var t = pu(), e = st(Qn).reducedMotion;
|
|
763
763
|
return e === "never" ? !1 : e === "always" ? !0 : t;
|
|
764
764
|
}
|
|
765
765
|
function mu(t, e, n, r) {
|
|
@@ -773,12 +773,12 @@ function mu(t, e, n, r) {
|
|
|
773
773
|
shouldReduceMotion: s
|
|
774
774
|
}));
|
|
775
775
|
var l = u.current;
|
|
776
|
-
return
|
|
776
|
+
return Lr(function() {
|
|
777
777
|
l == null || l.syncRender();
|
|
778
778
|
}), F(function() {
|
|
779
779
|
var c;
|
|
780
780
|
(c = l == null ? void 0 : l.animationState) === null || c === void 0 || c.animateChanges();
|
|
781
|
-
}),
|
|
781
|
+
}), Lr(function() {
|
|
782
782
|
return function() {
|
|
783
783
|
return l == null ? void 0 : l.notifyUnmount();
|
|
784
784
|
};
|
|
@@ -848,9 +848,9 @@ function xu(t) {
|
|
|
848
848
|
var e = bu(t, st(Qe)), n = e.initial, r = e.animate;
|
|
849
849
|
return Ke(function() {
|
|
850
850
|
return { initial: n, animate: r };
|
|
851
|
-
}, [
|
|
851
|
+
}, [Nr(n), Nr(r)]);
|
|
852
852
|
}
|
|
853
|
-
function
|
|
853
|
+
function Nr(t) {
|
|
854
854
|
return Array.isArray(t) ? t.join(" ") : t;
|
|
855
855
|
}
|
|
856
856
|
function xe(t) {
|
|
@@ -922,7 +922,7 @@ function Eu(t) {
|
|
|
922
922
|
function s(u, l) {
|
|
923
923
|
var c = Cu(u);
|
|
924
924
|
u = x(x({}, u), { layoutId: c });
|
|
925
|
-
var f = st(
|
|
925
|
+
var f = st(Qn), d = null, p = xu(u), v = f.isStatic ? void 0 : Tu(), h = a(u, f.isStatic);
|
|
926
926
|
return !f.isStatic && $t && (p.visualElement = mu(i, h, x(x({}, f), u), n), wu(v, u, p.visualElement, r || pe.projectionNodeConstructor), d = fu(u, p.visualElement, e)), Cn.createElement(
|
|
927
927
|
Vu,
|
|
928
928
|
{ visualElement: p.visualElement, props: x(x({}, f), u) },
|
|
@@ -981,7 +981,7 @@ var Ru = [
|
|
|
981
981
|
"use",
|
|
982
982
|
"view"
|
|
983
983
|
];
|
|
984
|
-
function
|
|
984
|
+
function _n(t) {
|
|
985
985
|
return (
|
|
986
986
|
/**
|
|
987
987
|
* If it's not a string, it's a custom React component. Currently we only support
|
|
@@ -1065,7 +1065,7 @@ const zt = {
|
|
|
1065
1065
|
test: (e) => Te(e) && e.endsWith(t) && e.split(" ").length === 1,
|
|
1066
1066
|
parse: parseFloat,
|
|
1067
1067
|
transform: (e) => `${e}${t}`
|
|
1068
|
-
}), Lt = we("deg"), wt = we("%"),
|
|
1068
|
+
}), Lt = we("deg"), wt = we("%"), M = we("px"), Hu = we("vh"), Wu = we("vw"), jr = Object.assign(Object.assign({}, wt), { parse: (t) => wt.parse(t) / 100, transform: (t) => wt.transform(t * 100) }), $n = (t, e) => (n) => !!(Te(n) && Fu.test(n) && n.startsWith(t) || e && Object.prototype.hasOwnProperty.call(n, e)), di = (t, e, n) => (r) => {
|
|
1069
1069
|
if (!Te(r))
|
|
1070
1070
|
return r;
|
|
1071
1071
|
const [o, a, i, s] = r.match(me);
|
|
@@ -1076,11 +1076,11 @@ const zt = {
|
|
|
1076
1076
|
alpha: s !== void 0 ? parseFloat(s) : 1
|
|
1077
1077
|
};
|
|
1078
1078
|
}, Wt = {
|
|
1079
|
-
test:
|
|
1079
|
+
test: $n("hsl", "hue"),
|
|
1080
1080
|
parse: di("hue", "saturation", "lightness"),
|
|
1081
1081
|
transform: ({ hue: t, saturation: e, lightness: n, alpha: r = 1 }) => "hsla(" + Math.round(t) + ", " + wt.transform(ae(e)) + ", " + wt.transform(ae(n)) + ", " + ae(se.transform(r)) + ")"
|
|
1082
1082
|
}, qu = fi(0, 255), gn = Object.assign(Object.assign({}, zt), { transform: (t) => Math.round(qu(t)) }), Dt = {
|
|
1083
|
-
test:
|
|
1083
|
+
test: $n("rgb", "red"),
|
|
1084
1084
|
parse: di("red", "green", "blue"),
|
|
1085
1085
|
transform: ({ red: t, green: e, blue: n, alpha: r = 1 }) => "rgba(" + gn.transform(t) + ", " + gn.transform(e) + ", " + gn.transform(n) + ", " + ae(se.transform(r)) + ")"
|
|
1086
1086
|
};
|
|
@@ -1094,7 +1094,7 @@ function Gu(t) {
|
|
|
1094
1094
|
};
|
|
1095
1095
|
}
|
|
1096
1096
|
const Nn = {
|
|
1097
|
-
test:
|
|
1097
|
+
test: $n("#"),
|
|
1098
1098
|
parse: Gu,
|
|
1099
1099
|
transform: Dt.transform
|
|
1100
1100
|
}, ct = {
|
|
@@ -1148,40 +1148,40 @@ const Ku = /([a-z-]*)\(.*?\)/g, jn = Object.assign(Object.assign({}, Mt), { getA
|
|
|
1148
1148
|
const e = t.match(Ku);
|
|
1149
1149
|
return e ? e.map(Zu).join(" ") : t;
|
|
1150
1150
|
} });
|
|
1151
|
-
var
|
|
1151
|
+
var Dr = x(x({}, zt), { transform: Math.round }), yi = {
|
|
1152
1152
|
// Border props
|
|
1153
|
-
borderWidth:
|
|
1154
|
-
borderTopWidth:
|
|
1155
|
-
borderRightWidth:
|
|
1156
|
-
borderBottomWidth:
|
|
1157
|
-
borderLeftWidth:
|
|
1158
|
-
borderRadius:
|
|
1159
|
-
radius:
|
|
1160
|
-
borderTopLeftRadius:
|
|
1161
|
-
borderTopRightRadius:
|
|
1162
|
-
borderBottomRightRadius:
|
|
1163
|
-
borderBottomLeftRadius:
|
|
1153
|
+
borderWidth: M,
|
|
1154
|
+
borderTopWidth: M,
|
|
1155
|
+
borderRightWidth: M,
|
|
1156
|
+
borderBottomWidth: M,
|
|
1157
|
+
borderLeftWidth: M,
|
|
1158
|
+
borderRadius: M,
|
|
1159
|
+
radius: M,
|
|
1160
|
+
borderTopLeftRadius: M,
|
|
1161
|
+
borderTopRightRadius: M,
|
|
1162
|
+
borderBottomRightRadius: M,
|
|
1163
|
+
borderBottomLeftRadius: M,
|
|
1164
1164
|
// Positioning props
|
|
1165
|
-
width:
|
|
1166
|
-
maxWidth:
|
|
1167
|
-
height:
|
|
1168
|
-
maxHeight:
|
|
1169
|
-
size:
|
|
1170
|
-
top:
|
|
1171
|
-
right:
|
|
1172
|
-
bottom:
|
|
1173
|
-
left:
|
|
1165
|
+
width: M,
|
|
1166
|
+
maxWidth: M,
|
|
1167
|
+
height: M,
|
|
1168
|
+
maxHeight: M,
|
|
1169
|
+
size: M,
|
|
1170
|
+
top: M,
|
|
1171
|
+
right: M,
|
|
1172
|
+
bottom: M,
|
|
1173
|
+
left: M,
|
|
1174
1174
|
// Spacing props
|
|
1175
|
-
padding:
|
|
1176
|
-
paddingTop:
|
|
1177
|
-
paddingRight:
|
|
1178
|
-
paddingBottom:
|
|
1179
|
-
paddingLeft:
|
|
1180
|
-
margin:
|
|
1181
|
-
marginTop:
|
|
1182
|
-
marginRight:
|
|
1183
|
-
marginBottom:
|
|
1184
|
-
marginLeft:
|
|
1175
|
+
padding: M,
|
|
1176
|
+
paddingTop: M,
|
|
1177
|
+
paddingRight: M,
|
|
1178
|
+
paddingBottom: M,
|
|
1179
|
+
paddingLeft: M,
|
|
1180
|
+
margin: M,
|
|
1181
|
+
marginTop: M,
|
|
1182
|
+
marginRight: M,
|
|
1183
|
+
marginBottom: M,
|
|
1184
|
+
marginLeft: M,
|
|
1185
1185
|
// Transform props
|
|
1186
1186
|
rotate: Lt,
|
|
1187
1187
|
rotateX: Lt,
|
|
@@ -1194,27 +1194,27 @@ var jr = x(x({}, zt), { transform: Math.round }), yi = {
|
|
|
1194
1194
|
skew: Lt,
|
|
1195
1195
|
skewX: Lt,
|
|
1196
1196
|
skewY: Lt,
|
|
1197
|
-
distance:
|
|
1198
|
-
translateX:
|
|
1199
|
-
translateY:
|
|
1200
|
-
translateZ:
|
|
1201
|
-
x:
|
|
1202
|
-
y:
|
|
1203
|
-
z:
|
|
1204
|
-
perspective:
|
|
1205
|
-
transformPerspective:
|
|
1197
|
+
distance: M,
|
|
1198
|
+
translateX: M,
|
|
1199
|
+
translateY: M,
|
|
1200
|
+
translateZ: M,
|
|
1201
|
+
x: M,
|
|
1202
|
+
y: M,
|
|
1203
|
+
z: M,
|
|
1204
|
+
perspective: M,
|
|
1205
|
+
transformPerspective: M,
|
|
1206
1206
|
opacity: se,
|
|
1207
|
-
originX:
|
|
1208
|
-
originY:
|
|
1209
|
-
originZ:
|
|
1207
|
+
originX: jr,
|
|
1208
|
+
originY: jr,
|
|
1209
|
+
originZ: M,
|
|
1210
1210
|
// Misc
|
|
1211
|
-
zIndex:
|
|
1211
|
+
zIndex: Dr,
|
|
1212
1212
|
// SVG
|
|
1213
1213
|
fillOpacity: se,
|
|
1214
1214
|
strokeOpacity: se,
|
|
1215
|
-
numOctaves:
|
|
1215
|
+
numOctaves: Dr
|
|
1216
1216
|
};
|
|
1217
|
-
function
|
|
1217
|
+
function tr(t, e, n, r) {
|
|
1218
1218
|
var o, a = t.style, i = t.vars, s = t.transform, u = t.transformKeys, l = t.transformOrigin;
|
|
1219
1219
|
u.length = 0;
|
|
1220
1220
|
var c = !1, f = !1, d = !0;
|
|
@@ -1224,16 +1224,16 @@ function $n(t, e, n, r) {
|
|
|
1224
1224
|
i[p] = v;
|
|
1225
1225
|
continue;
|
|
1226
1226
|
}
|
|
1227
|
-
var h = yi[p],
|
|
1227
|
+
var h = yi[p], y = ku(v, h);
|
|
1228
1228
|
if (Pe(p)) {
|
|
1229
|
-
if (c = !0, s[p] =
|
|
1229
|
+
if (c = !0, s[p] = y, u.push(p), !d)
|
|
1230
1230
|
continue;
|
|
1231
1231
|
v !== ((o = h.default) !== null && o !== void 0 ? o : 0) && (d = !1);
|
|
1232
|
-
} else ui(p) ? (l[p] =
|
|
1232
|
+
} else ui(p) ? (l[p] = y, f = !0) : a[p] = y;
|
|
1233
1233
|
}
|
|
1234
1234
|
c ? a.transform = Du(t, n, d, r) : r ? a.transform = r({}, "") : !e.transform && a.transform && (a.transform = "none"), f && (a.transformOrigin = Bu(l));
|
|
1235
1235
|
}
|
|
1236
|
-
var
|
|
1236
|
+
var er = function() {
|
|
1237
1237
|
return {
|
|
1238
1238
|
style: {},
|
|
1239
1239
|
transform: {},
|
|
@@ -1249,8 +1249,8 @@ function Si(t, e, n) {
|
|
|
1249
1249
|
function Ju(t, e, n) {
|
|
1250
1250
|
var r = t.transformTemplate;
|
|
1251
1251
|
return Ke(function() {
|
|
1252
|
-
var o =
|
|
1253
|
-
|
|
1252
|
+
var o = er();
|
|
1253
|
+
tr(o, e, { enableHardwareAcceleration: !n }, r);
|
|
1254
1254
|
var a = o.vars, i = o.style;
|
|
1255
1255
|
return x(x({}, a), i);
|
|
1256
1256
|
}, [e]);
|
|
@@ -1343,11 +1343,11 @@ function el(t, e, n) {
|
|
|
1343
1343
|
t.draggable && o.startsWith("onDrag")) && (r[o] = t[o]);
|
|
1344
1344
|
return r;
|
|
1345
1345
|
}
|
|
1346
|
-
function
|
|
1347
|
-
return typeof t == "string" ? t :
|
|
1346
|
+
function Br(t, e, n) {
|
|
1347
|
+
return typeof t == "string" ? t : M.transform(e + n * t);
|
|
1348
1348
|
}
|
|
1349
1349
|
function nl(t, e, n) {
|
|
1350
|
-
var r =
|
|
1350
|
+
var r = Br(e, t.x, t.width), o = Br(n, t.y, t.height);
|
|
1351
1351
|
return "".concat(r, " ").concat(o);
|
|
1352
1352
|
}
|
|
1353
1353
|
var rl = {
|
|
@@ -1357,23 +1357,23 @@ var rl = {
|
|
|
1357
1357
|
function ol(t, e, n, r, o) {
|
|
1358
1358
|
n === void 0 && (n = 1), r === void 0 && (r = 0), t.pathLength = 1;
|
|
1359
1359
|
var a = rl;
|
|
1360
|
-
t[a.offset] =
|
|
1361
|
-
var i =
|
|
1360
|
+
t[a.offset] = M.transform(-r);
|
|
1361
|
+
var i = M.transform(e), s = M.transform(n);
|
|
1362
1362
|
t[a.array] = "".concat(i, " ").concat(s);
|
|
1363
1363
|
}
|
|
1364
|
-
function
|
|
1364
|
+
function nr(t, e, n, r) {
|
|
1365
1365
|
var o = e.attrX, a = e.attrY, i = e.originX, s = e.originY, u = e.pathLength, l = e.pathSpacing, c = l === void 0 ? 1 : l, f = e.pathOffset, d = f === void 0 ? 0 : f, p = gt(e, ["attrX", "attrY", "originX", "originY", "pathLength", "pathSpacing", "pathOffset"]);
|
|
1366
|
-
|
|
1367
|
-
var v = t.attrs, h = t.style,
|
|
1368
|
-
v.transform && (
|
|
1366
|
+
tr(t, p, n, r), t.attrs = t.style, t.style = {};
|
|
1367
|
+
var v = t.attrs, h = t.style, y = t.dimensions;
|
|
1368
|
+
v.transform && (y && (h.transform = v.transform), delete v.transform), y && (i !== void 0 || s !== void 0 || h.transform) && (h.transformOrigin = nl(y, i !== void 0 ? i : 0.5, s !== void 0 ? s : 0.5)), o !== void 0 && (v.x = o), a !== void 0 && (v.y = a), u !== void 0 && ol(v, u, c, d);
|
|
1369
1369
|
}
|
|
1370
1370
|
var xi = function() {
|
|
1371
|
-
return x(x({},
|
|
1371
|
+
return x(x({}, er()), { attrs: {} });
|
|
1372
1372
|
};
|
|
1373
1373
|
function il(t, e) {
|
|
1374
1374
|
var n = Ke(function() {
|
|
1375
1375
|
var o = xi();
|
|
1376
|
-
return
|
|
1376
|
+
return nr(o, e, { enableHardwareAcceleration: !1 }, t.transformTemplate), x(x({}, o.attrs), { style: x({}, o.style) });
|
|
1377
1377
|
}, [e]);
|
|
1378
1378
|
if (t.style) {
|
|
1379
1379
|
var r = {};
|
|
@@ -1384,7 +1384,7 @@ function il(t, e) {
|
|
|
1384
1384
|
function al(t) {
|
|
1385
1385
|
t === void 0 && (t = !1);
|
|
1386
1386
|
var e = function(n, r, o, a, i, s) {
|
|
1387
|
-
var u = i.latestValues, l =
|
|
1387
|
+
var u = i.latestValues, l = _n(n) ? il : _u, c = l(r, u, s), f = el(r, typeof n == "string", t), d = x(x(x({}, f), c), { ref: a });
|
|
1388
1388
|
return o && (d["data-projection-id"] = o), Na(n, d);
|
|
1389
1389
|
};
|
|
1390
1390
|
return e;
|
|
@@ -1425,14 +1425,14 @@ function Vi(t, e, n, r) {
|
|
|
1425
1425
|
for (var o in e.attrs)
|
|
1426
1426
|
t.setAttribute(wi.has(o) ? o : Pi(o), e.attrs[o]);
|
|
1427
1427
|
}
|
|
1428
|
-
function
|
|
1428
|
+
function rr(t) {
|
|
1429
1429
|
var e = t.style, n = {};
|
|
1430
1430
|
for (var r in e)
|
|
1431
1431
|
(Rt(e[r]) || li(r, t)) && (n[r] = e[r]);
|
|
1432
1432
|
return n;
|
|
1433
1433
|
}
|
|
1434
1434
|
function Ei(t) {
|
|
1435
|
-
var e =
|
|
1435
|
+
var e = rr(t);
|
|
1436
1436
|
for (var n in t)
|
|
1437
1437
|
if (Rt(t[n])) {
|
|
1438
1438
|
var r = n === "x" || n === "y" ? "attr" + n.toUpperCase() : n;
|
|
@@ -1440,7 +1440,7 @@ function Ei(t) {
|
|
|
1440
1440
|
}
|
|
1441
1441
|
return e;
|
|
1442
1442
|
}
|
|
1443
|
-
function
|
|
1443
|
+
function or(t) {
|
|
1444
1444
|
return typeof t == "object" && typeof t.start == "function";
|
|
1445
1445
|
}
|
|
1446
1446
|
var ge = function(t) {
|
|
@@ -1454,7 +1454,7 @@ function Be(t) {
|
|
|
1454
1454
|
var e = Rt(t) ? t.get() : t;
|
|
1455
1455
|
return ll(e) ? e.toValue() : e;
|
|
1456
1456
|
}
|
|
1457
|
-
function
|
|
1457
|
+
function kr(t, e, n, r) {
|
|
1458
1458
|
var o = t.scrapeMotionValuesFromProps, a = t.createRenderState, i = t.onMount, s = {
|
|
1459
1459
|
latestValues: cl(e, n, r, o),
|
|
1460
1460
|
renderState: a()
|
|
@@ -1466,8 +1466,8 @@ function Br(t, e, n, r) {
|
|
|
1466
1466
|
var Ai = function(t) {
|
|
1467
1467
|
return function(e, n) {
|
|
1468
1468
|
var r = st(Qe), o = st(_e);
|
|
1469
|
-
return n ?
|
|
1470
|
-
return
|
|
1469
|
+
return n ? kr(t, e, r, o) : xe(function() {
|
|
1470
|
+
return kr(t, e, r, o);
|
|
1471
1471
|
});
|
|
1472
1472
|
};
|
|
1473
1473
|
};
|
|
@@ -1478,24 +1478,24 @@ function cl(t, e, n, r) {
|
|
|
1478
1478
|
var u = t.initial, l = t.animate, c = tn(t), f = ii(t);
|
|
1479
1479
|
e && f && !c && t.inherit !== !1 && (u ?? (u = e.initial), l ?? (l = e.animate));
|
|
1480
1480
|
var d = a || u === !1, p = d ? l : u;
|
|
1481
|
-
if (p && typeof p != "boolean" && !
|
|
1481
|
+
if (p && typeof p != "boolean" && !or(p)) {
|
|
1482
1482
|
var v = Array.isArray(p) ? p : [p];
|
|
1483
1483
|
v.forEach(function(h) {
|
|
1484
|
-
var
|
|
1485
|
-
if (
|
|
1486
|
-
var m =
|
|
1487
|
-
|
|
1488
|
-
var b = gt(
|
|
1489
|
-
for (var
|
|
1490
|
-
var P = b[
|
|
1484
|
+
var y = oi(t, h);
|
|
1485
|
+
if (y) {
|
|
1486
|
+
var m = y.transitionEnd;
|
|
1487
|
+
y.transition;
|
|
1488
|
+
var b = gt(y, ["transitionEnd", "transition"]);
|
|
1489
|
+
for (var g in b) {
|
|
1490
|
+
var P = b[g];
|
|
1491
1491
|
if (Array.isArray(P)) {
|
|
1492
1492
|
var w = d ? P.length - 1 : 0;
|
|
1493
1493
|
P = P[w];
|
|
1494
1494
|
}
|
|
1495
|
-
P !== null && (o[
|
|
1495
|
+
P !== null && (o[g] = P);
|
|
1496
1496
|
}
|
|
1497
|
-
for (var
|
|
1498
|
-
o[
|
|
1497
|
+
for (var g in m)
|
|
1498
|
+
o[g] = m[g];
|
|
1499
1499
|
}
|
|
1500
1500
|
});
|
|
1501
1501
|
}
|
|
@@ -1517,17 +1517,17 @@ var fl = {
|
|
|
1517
1517
|
height: 0
|
|
1518
1518
|
};
|
|
1519
1519
|
}
|
|
1520
|
-
|
|
1520
|
+
nr(r, o, { enableHardwareAcceleration: !1 }, t.transformTemplate), Vi(e, r);
|
|
1521
1521
|
}
|
|
1522
1522
|
})
|
|
1523
1523
|
}, dl = {
|
|
1524
1524
|
useVisualState: Ai({
|
|
1525
|
-
scrapeMotionValuesFromProps:
|
|
1526
|
-
createRenderState:
|
|
1525
|
+
scrapeMotionValuesFromProps: rr,
|
|
1526
|
+
createRenderState: er
|
|
1527
1527
|
})
|
|
1528
1528
|
};
|
|
1529
1529
|
function vl(t, e, n, r, o) {
|
|
1530
|
-
var a = e.forwardMotionProps, i = a === void 0 ? !1 : a, s =
|
|
1530
|
+
var a = e.forwardMotionProps, i = a === void 0 ? !1 : a, s = _n(t) ? fl : dl;
|
|
1531
1531
|
return x(x({}, s), { preloadedFeatures: n, useRender: al(i), createVisualElement: r, projectionNodeConstructor: o, Component: t });
|
|
1532
1532
|
}
|
|
1533
1533
|
var U;
|
|
@@ -1584,7 +1584,7 @@ function yl(t, e) {
|
|
|
1584
1584
|
y: t[e + "Y"]
|
|
1585
1585
|
};
|
|
1586
1586
|
}
|
|
1587
|
-
function
|
|
1587
|
+
function ir(t, e) {
|
|
1588
1588
|
return e === void 0 && (e = "page"), {
|
|
1589
1589
|
point: Mi(t) ? gl(t, e) : yl(t, e)
|
|
1590
1590
|
};
|
|
@@ -1592,7 +1592,7 @@ function or(t, e) {
|
|
|
1592
1592
|
var Ii = function(t, e) {
|
|
1593
1593
|
e === void 0 && (e = !1);
|
|
1594
1594
|
var n = function(r) {
|
|
1595
|
-
return t(r,
|
|
1595
|
+
return t(r, ir(r));
|
|
1596
1596
|
};
|
|
1597
1597
|
return e ? hl(n) : n;
|
|
1598
1598
|
}, Sl = function() {
|
|
@@ -1634,15 +1634,15 @@ function Li(t) {
|
|
|
1634
1634
|
return e === null ? (e = t, n) : !1;
|
|
1635
1635
|
};
|
|
1636
1636
|
}
|
|
1637
|
-
var
|
|
1637
|
+
var Fr = Li("dragHorizontal"), Hr = Li("dragVertical");
|
|
1638
1638
|
function Ni(t) {
|
|
1639
1639
|
var e = !1;
|
|
1640
1640
|
if (t === "y")
|
|
1641
|
-
e =
|
|
1641
|
+
e = Hr();
|
|
1642
1642
|
else if (t === "x")
|
|
1643
|
-
e =
|
|
1643
|
+
e = Fr();
|
|
1644
1644
|
else {
|
|
1645
|
-
var n =
|
|
1645
|
+
var n = Fr(), r = Hr();
|
|
1646
1646
|
n && r ? e = function() {
|
|
1647
1647
|
n(), r();
|
|
1648
1648
|
} : (n && n(), r && r());
|
|
@@ -1653,7 +1653,7 @@ function ji() {
|
|
|
1653
1653
|
var t = Ni(!0);
|
|
1654
1654
|
return t ? (t(), !1) : !0;
|
|
1655
1655
|
}
|
|
1656
|
-
function
|
|
1656
|
+
function Wr(t, e, n) {
|
|
1657
1657
|
return function(r, o) {
|
|
1658
1658
|
var a;
|
|
1659
1659
|
!Ri(r) || ji() || ((a = t.animationState) === null || a === void 0 || a.setActive(U.Hover, e), n == null || n(r, o));
|
|
@@ -1661,7 +1661,7 @@ function Hr(t, e, n) {
|
|
|
1661
1661
|
}
|
|
1662
1662
|
function wl(t) {
|
|
1663
1663
|
var e = t.onHoverStart, n = t.onHoverEnd, r = t.whileHover, o = t.visualElement;
|
|
1664
|
-
qe(o, "pointerenter", e || r ?
|
|
1664
|
+
qe(o, "pointerenter", e || r ? Wr(o, !0, e) : void 0, { passive: !e }), qe(o, "pointerleave", n || r ? Wr(o, !1, n) : void 0, { passive: !n });
|
|
1665
1665
|
}
|
|
1666
1666
|
var Di = function(t, e) {
|
|
1667
1667
|
return e ? t === e ? !0 : Di(t, e.parentElement) : !1;
|
|
@@ -1673,17 +1673,17 @@ function Bi(t) {
|
|
|
1673
1673
|
};
|
|
1674
1674
|
}, []);
|
|
1675
1675
|
}
|
|
1676
|
-
const Ge = (t, e, n) => Math.min(Math.max(n, t), e),
|
|
1676
|
+
const Ge = (t, e, n) => Math.min(Math.max(n, t), e), qr = 1e-3, Vl = 0.01, Gr = 10, El = 0.05, Cl = 1;
|
|
1677
1677
|
function Al({ duration: t = 800, bounce: e = 0.25, velocity: n = 0, mass: r = 1 }) {
|
|
1678
1678
|
let o, a;
|
|
1679
|
-
be(t <=
|
|
1679
|
+
be(t <= Gr * 1e3, "Spring duration must be 10 seconds or less");
|
|
1680
1680
|
let i = 1 - e;
|
|
1681
|
-
i = Ge(El, Cl, i), t = Ge(Vl,
|
|
1681
|
+
i = Ge(El, Cl, i), t = Ge(Vl, Gr, t / 1e3), i < 1 ? (o = (l) => {
|
|
1682
1682
|
const c = l * i, f = c * t, d = c - n, p = Bn(l, i), v = Math.exp(-f);
|
|
1683
|
-
return
|
|
1683
|
+
return qr - d / p * v;
|
|
1684
1684
|
}, a = (l) => {
|
|
1685
1685
|
const f = l * i * t, d = f * n + n, p = Math.pow(i, 2) * Math.pow(l, 2) * t, v = Math.exp(-f), h = Bn(Math.pow(l, 2), i);
|
|
1686
|
-
return (-o(l) +
|
|
1686
|
+
return (-o(l) + qr > 0 ? -1 : 1) * ((d - p) * v) / h;
|
|
1687
1687
|
}) : (o = (l) => {
|
|
1688
1688
|
const c = Math.exp(-l * t), f = (l - n) * t + 1;
|
|
1689
1689
|
return -1e-3 + c * f;
|
|
@@ -1718,50 +1718,50 @@ function Bn(t, e) {
|
|
|
1718
1718
|
return t * Math.sqrt(1 - e * e);
|
|
1719
1719
|
}
|
|
1720
1720
|
const Il = ["duration", "bounce"], Ol = ["stiffness", "damping", "mass"];
|
|
1721
|
-
function
|
|
1721
|
+
function zr(t, e) {
|
|
1722
1722
|
return e.some((n) => t[n] !== void 0);
|
|
1723
1723
|
}
|
|
1724
1724
|
function Ll(t) {
|
|
1725
1725
|
let e = Object.assign({ velocity: 0, stiffness: 100, damping: 10, mass: 1, isResolvedFromDuration: !1 }, t);
|
|
1726
|
-
if (!
|
|
1726
|
+
if (!zr(t, Ol) && zr(t, Il)) {
|
|
1727
1727
|
const n = Al(t);
|
|
1728
1728
|
e = Object.assign(Object.assign(Object.assign({}, e), n), { velocity: 0, mass: 1 }), e.isResolvedFromDuration = !0;
|
|
1729
1729
|
}
|
|
1730
1730
|
return e;
|
|
1731
1731
|
}
|
|
1732
|
-
function
|
|
1732
|
+
function ar(t) {
|
|
1733
1733
|
var { from: e = 0, to: n = 1, restSpeed: r = 2, restDelta: o } = t, a = gt(t, ["from", "to", "restSpeed", "restDelta"]);
|
|
1734
1734
|
const i = { done: !1, value: e };
|
|
1735
|
-
let { stiffness: s, damping: u, mass: l, velocity: c, duration: f, isResolvedFromDuration: d } = Ll(a), p =
|
|
1735
|
+
let { stiffness: s, damping: u, mass: l, velocity: c, duration: f, isResolvedFromDuration: d } = Ll(a), p = Ur, v = Ur;
|
|
1736
1736
|
function h() {
|
|
1737
|
-
const
|
|
1737
|
+
const y = c ? -(c / 1e3) : 0, m = n - e, b = u / (2 * Math.sqrt(s * l)), g = Math.sqrt(s / l) / 1e3;
|
|
1738
1738
|
if (o === void 0 && (o = Math.min(Math.abs(n - e) / 100, 0.4)), b < 1) {
|
|
1739
|
-
const P = Bn(
|
|
1739
|
+
const P = Bn(g, b);
|
|
1740
1740
|
p = (w) => {
|
|
1741
|
-
const
|
|
1742
|
-
return n -
|
|
1741
|
+
const V = Math.exp(-b * g * w);
|
|
1742
|
+
return n - V * ((y + b * g * m) / P * Math.sin(P * w) + m * Math.cos(P * w));
|
|
1743
1743
|
}, v = (w) => {
|
|
1744
|
-
const
|
|
1745
|
-
return b *
|
|
1744
|
+
const V = Math.exp(-b * g * w);
|
|
1745
|
+
return b * g * V * (Math.sin(P * w) * (y + b * g * m) / P + m * Math.cos(P * w)) - V * (Math.cos(P * w) * (y + b * g * m) - P * m * Math.sin(P * w));
|
|
1746
1746
|
};
|
|
1747
1747
|
} else if (b === 1)
|
|
1748
|
-
p = (P) => n - Math.exp(-
|
|
1748
|
+
p = (P) => n - Math.exp(-g * P) * (m + (y + g * m) * P);
|
|
1749
1749
|
else {
|
|
1750
|
-
const P =
|
|
1750
|
+
const P = g * Math.sqrt(b * b - 1);
|
|
1751
1751
|
p = (w) => {
|
|
1752
|
-
const
|
|
1753
|
-
return n -
|
|
1752
|
+
const V = Math.exp(-b * g * w), O = Math.min(P * w, 300);
|
|
1753
|
+
return n - V * ((y + b * g * m) * Math.sinh(O) + P * m * Math.cosh(O)) / P;
|
|
1754
1754
|
};
|
|
1755
1755
|
}
|
|
1756
1756
|
}
|
|
1757
1757
|
return h(), {
|
|
1758
|
-
next: (
|
|
1759
|
-
const m = p(
|
|
1758
|
+
next: (y) => {
|
|
1759
|
+
const m = p(y);
|
|
1760
1760
|
if (d)
|
|
1761
|
-
i.done =
|
|
1761
|
+
i.done = y >= f;
|
|
1762
1762
|
else {
|
|
1763
|
-
const b = v(
|
|
1764
|
-
i.done =
|
|
1763
|
+
const b = v(y) * 1e3, g = Math.abs(b) <= r, P = Math.abs(n - m) <= o;
|
|
1764
|
+
i.done = g && P;
|
|
1765
1765
|
}
|
|
1766
1766
|
return i.value = i.done ? n : m, i;
|
|
1767
1767
|
},
|
|
@@ -1770,15 +1770,15 @@ function ir(t) {
|
|
|
1770
1770
|
}
|
|
1771
1771
|
};
|
|
1772
1772
|
}
|
|
1773
|
-
|
|
1774
|
-
const
|
|
1773
|
+
ar.needsInterpolation = (t, e) => typeof t == "string" || typeof e == "string";
|
|
1774
|
+
const Ur = (t) => 0, ye = (t, e, n) => {
|
|
1775
1775
|
const r = e - t;
|
|
1776
1776
|
return r === 0 ? 1 : (n - t) / r;
|
|
1777
|
-
},
|
|
1777
|
+
}, tt = (t, e, n) => -n * t + n * e + t;
|
|
1778
1778
|
function yn(t, e, n) {
|
|
1779
1779
|
return n < 0 && (n += 1), n > 1 && (n -= 1), n < 1 / 6 ? t + (e - t) * 6 * n : n < 1 / 2 ? e : n < 2 / 3 ? t + (e - t) * (2 / 3 - n) * 6 : t;
|
|
1780
1780
|
}
|
|
1781
|
-
function
|
|
1781
|
+
function Yr({ hue: t, saturation: e, lightness: n, alpha: r }) {
|
|
1782
1782
|
t /= 360, e /= 100, n /= 100;
|
|
1783
1783
|
let o = 0, a = 0, i = 0;
|
|
1784
1784
|
if (!e)
|
|
@@ -1797,20 +1797,20 @@ function Ur({ hue: t, saturation: e, lightness: n, alpha: r }) {
|
|
|
1797
1797
|
const Nl = (t, e, n) => {
|
|
1798
1798
|
const r = t * t, o = e * e;
|
|
1799
1799
|
return Math.sqrt(Math.max(0, n * (o - r) + r));
|
|
1800
|
-
}, jl = [Nn, Dt, Wt],
|
|
1801
|
-
let n =
|
|
1802
|
-
vt(!!n,
|
|
1800
|
+
}, jl = [Nn, Dt, Wt], Xr = (t) => jl.find((e) => e.test(t)), Zr = (t) => `'${t}' is not an animatable color. Use the equivalent color code instead.`, ki = (t, e) => {
|
|
1801
|
+
let n = Xr(t), r = Xr(e);
|
|
1802
|
+
vt(!!n, Zr(t)), vt(!!r, Zr(e));
|
|
1803
1803
|
let o = n.parse(t), a = r.parse(e);
|
|
1804
|
-
n === Wt && (o =
|
|
1804
|
+
n === Wt && (o = Yr(o), n = Dt), r === Wt && (a = Yr(a), r = Dt);
|
|
1805
1805
|
const i = Object.assign({}, o);
|
|
1806
1806
|
return (s) => {
|
|
1807
1807
|
for (const u in i)
|
|
1808
1808
|
u !== "alpha" && (i[u] = Nl(o[u], a[u], s));
|
|
1809
|
-
return i.alpha =
|
|
1809
|
+
return i.alpha = tt(o.alpha, a.alpha, s), n.transform(i);
|
|
1810
1810
|
};
|
|
1811
1811
|
}, kn = (t) => typeof t == "number", Dl = (t, e) => (n) => e(t(n)), nn = (...t) => t.reduce(Dl);
|
|
1812
1812
|
function Fi(t, e) {
|
|
1813
|
-
return kn(t) ? (n) =>
|
|
1813
|
+
return kn(t) ? (n) => tt(t, e, n) : ct.test(t) ? ki(t, e) : Wi(t, e);
|
|
1814
1814
|
}
|
|
1815
1815
|
const Hi = (t, e) => {
|
|
1816
1816
|
const n = [...t], r = n.length, o = t.map((a, i) => Fi(a, e[i]));
|
|
@@ -1829,7 +1829,7 @@ const Hi = (t, e) => {
|
|
|
1829
1829
|
return n;
|
|
1830
1830
|
};
|
|
1831
1831
|
};
|
|
1832
|
-
function
|
|
1832
|
+
function Kr(t) {
|
|
1833
1833
|
const e = Mt.parse(t), n = e.length;
|
|
1834
1834
|
let r = 0, o = 0, a = 0;
|
|
1835
1835
|
for (let i = 0; i < n; i++)
|
|
@@ -1837,9 +1837,9 @@ function Zr(t) {
|
|
|
1837
1837
|
return { parsed: e, numNumbers: r, numRGB: o, numHSL: a };
|
|
1838
1838
|
}
|
|
1839
1839
|
const Wi = (t, e) => {
|
|
1840
|
-
const n = Mt.createTransformer(e), r =
|
|
1840
|
+
const n = Mt.createTransformer(e), r = Kr(t), o = Kr(e);
|
|
1841
1841
|
return r.numHSL === o.numHSL && r.numRGB === o.numRGB && r.numNumbers >= o.numNumbers ? nn(Hi(r.parsed, o.parsed), n) : (be(!0, `Complex values '${t}' and '${e}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`), (i) => `${i > 0 ? e : t}`);
|
|
1842
|
-
}, kl = (t, e) => (n) =>
|
|
1842
|
+
}, kl = (t, e) => (n) => tt(t, e, n);
|
|
1843
1843
|
function Fl(t) {
|
|
1844
1844
|
if (typeof t == "number")
|
|
1845
1845
|
return kl;
|
|
@@ -1885,10 +1885,10 @@ function qi(t, e, { clamp: n = !0, ease: r, mixer: o } = {}) {
|
|
|
1885
1885
|
const i = Hl(e, r, o), s = a === 2 ? Wl(t, i) : ql(t, i);
|
|
1886
1886
|
return n ? (u) => s(Ge(t[0], t[a - 1], u)) : s;
|
|
1887
1887
|
}
|
|
1888
|
-
const rn = (t) => (e) => 1 - t(1 - e),
|
|
1888
|
+
const rn = (t) => (e) => 1 - t(1 - e), sr = (t) => (e) => e <= 0.5 ? t(2 * e) / 2 : (2 - t(2 * (1 - e))) / 2, Gl = (t) => (e) => Math.pow(e, t), Gi = (t) => (e) => e * e * ((t + 1) * e - t), zl = (t) => {
|
|
1889
1889
|
const e = Gi(t);
|
|
1890
1890
|
return (n) => (n *= 2) < 1 ? 0.5 * e(n) : 0.5 * (2 - Math.pow(2, -10 * (n - 1)));
|
|
1891
|
-
}, zi = 1.525, Ul = 4 / 11, Yl = 8 / 11, Xl = 9 / 10,
|
|
1891
|
+
}, zi = 1.525, Ul = 4 / 11, Yl = 8 / 11, Xl = 9 / 10, ur = (t) => t, lr = Gl(2), Zl = rn(lr), Ui = sr(lr), Yi = (t) => 1 - Math.sin(Math.acos(t)), cr = rn(Yi), Kl = sr(cr), fr = Gi(zi), Jl = rn(fr), Ql = sr(fr), _l = zl(zi), $l = 4356 / 361, tc = 35442 / 1805, ec = 16061 / 1805, ze = (t) => {
|
|
1892
1892
|
if (t === 1 || t === 0)
|
|
1893
1893
|
return t;
|
|
1894
1894
|
const e = t * t;
|
|
@@ -1932,14 +1932,14 @@ function sc({ velocity: t = 0, from: e = 0, power: n = 0.8, timeConstant: r = 35
|
|
|
1932
1932
|
}
|
|
1933
1933
|
};
|
|
1934
1934
|
}
|
|
1935
|
-
const
|
|
1935
|
+
const Jr = { keyframes: ke, spring: ar, decay: sc };
|
|
1936
1936
|
function uc(t) {
|
|
1937
1937
|
if (Array.isArray(t.to))
|
|
1938
1938
|
return ke;
|
|
1939
|
-
if (
|
|
1940
|
-
return
|
|
1939
|
+
if (Jr[t.type])
|
|
1940
|
+
return Jr[t.type];
|
|
1941
1941
|
const e = new Set(Object.keys(t));
|
|
1942
|
-
return e.has("ease") || e.has("duration") && !e.has("dampingRatio") ? ke : e.has("dampingRatio") || e.has("stiffness") || e.has("mass") || e.has("damping") || e.has("restSpeed") || e.has("restDelta") ?
|
|
1942
|
+
return e.has("ease") || e.has("duration") && !e.has("dampingRatio") ? ke : e.has("dampingRatio") || e.has("stiffness") || e.has("mass") || e.has("damping") || e.has("restSpeed") || e.has("restDelta") ? ar : ke;
|
|
1943
1943
|
}
|
|
1944
1944
|
const Xi = 1 / 60 * 1e3, lc = typeof performance < "u" ? () => performance.now() : () => Date.now(), Zi = typeof window < "u" ? (t) => window.requestAnimationFrame(t) : (t) => setTimeout(() => t(lc()), Xi);
|
|
1945
1945
|
function cc(t) {
|
|
@@ -2005,27 +2005,27 @@ const mc = (t) => {
|
|
|
2005
2005
|
};
|
|
2006
2006
|
function Qi(t) {
|
|
2007
2007
|
var e, n, { from: r, autoplay: o = !0, driver: a = mc, elapsed: i = 0, repeat: s = 0, repeatType: u = "loop", repeatDelay: l = 0, onPlay: c, onStop: f, onComplete: d, onRepeat: p, onUpdate: v } = t, h = gt(t, ["from", "autoplay", "driver", "elapsed", "repeat", "repeatType", "repeatDelay", "onPlay", "onStop", "onComplete", "onRepeat", "onUpdate"]);
|
|
2008
|
-
let { to:
|
|
2008
|
+
let { to: y } = h, m, b = 0, g = h.duration, P, w = !1, V = !0, O;
|
|
2009
2009
|
const j = uc(h);
|
|
2010
|
-
!((n = (e = j).needsInterpolation) === null || n === void 0) && n.call(e, r,
|
|
2010
|
+
!((n = (e = j).needsInterpolation) === null || n === void 0) && n.call(e, r, y) && (O = qi([0, 100], [r, y], {
|
|
2011
2011
|
clamp: !1
|
|
2012
|
-
}), r = 0,
|
|
2013
|
-
const
|
|
2012
|
+
}), r = 0, y = 100);
|
|
2013
|
+
const A = j(Object.assign(Object.assign({}, h), { from: r, to: y }));
|
|
2014
2014
|
function k() {
|
|
2015
|
-
b++, u === "reverse" ? (
|
|
2015
|
+
b++, u === "reverse" ? (V = b % 2 === 0, i = pc(i, g, l, V)) : (i = Ji(i, g, l), u === "mirror" && A.flipTarget()), w = !1, p && p();
|
|
2016
2016
|
}
|
|
2017
|
-
function
|
|
2017
|
+
function _() {
|
|
2018
2018
|
m.stop(), d && d();
|
|
2019
2019
|
}
|
|
2020
|
-
function
|
|
2021
|
-
if (
|
|
2022
|
-
const
|
|
2023
|
-
P =
|
|
2020
|
+
function W(R) {
|
|
2021
|
+
if (V || (R = -R), i += R, !w) {
|
|
2022
|
+
const Y = A.next(Math.max(0, i));
|
|
2023
|
+
P = Y.value, O && (P = O(P)), w = V ? Y.done : i <= 0;
|
|
2024
2024
|
}
|
|
2025
|
-
v == null || v(P), w && (b === 0 && (
|
|
2025
|
+
v == null || v(P), w && (b === 0 && (g ?? (g = i)), b < s ? hc(i, g, l, V) && k() : _());
|
|
2026
2026
|
}
|
|
2027
2027
|
function H() {
|
|
2028
|
-
c == null || c(), m = a(
|
|
2028
|
+
c == null || c(), m = a(W), m.start();
|
|
2029
2029
|
}
|
|
2030
2030
|
return o && H(), {
|
|
2031
2031
|
stop: () => {
|
|
@@ -2038,35 +2038,35 @@ function _i(t, e) {
|
|
|
2038
2038
|
}
|
|
2039
2039
|
function gc({ from: t = 0, velocity: e = 0, min: n, max: r, power: o = 0.8, timeConstant: a = 750, bounceStiffness: i = 500, bounceDamping: s = 10, restDelta: u = 1, modifyTarget: l, driver: c, onUpdate: f, onComplete: d, onStop: p }) {
|
|
2040
2040
|
let v;
|
|
2041
|
-
function h(
|
|
2042
|
-
return n !== void 0 &&
|
|
2041
|
+
function h(g) {
|
|
2042
|
+
return n !== void 0 && g < n || r !== void 0 && g > r;
|
|
2043
2043
|
}
|
|
2044
|
-
function g
|
|
2045
|
-
return n === void 0 ? r : r === void 0 || Math.abs(n -
|
|
2044
|
+
function y(g) {
|
|
2045
|
+
return n === void 0 ? r : r === void 0 || Math.abs(n - g) < Math.abs(r - g) ? n : r;
|
|
2046
2046
|
}
|
|
2047
|
-
function m(
|
|
2048
|
-
v == null || v.stop(), v = Qi(Object.assign(Object.assign({},
|
|
2047
|
+
function m(g) {
|
|
2048
|
+
v == null || v.stop(), v = Qi(Object.assign(Object.assign({}, g), {
|
|
2049
2049
|
driver: c,
|
|
2050
2050
|
onUpdate: (P) => {
|
|
2051
2051
|
var w;
|
|
2052
|
-
f == null || f(P), (w =
|
|
2052
|
+
f == null || f(P), (w = g.onUpdate) === null || w === void 0 || w.call(g, P);
|
|
2053
2053
|
},
|
|
2054
2054
|
onComplete: d,
|
|
2055
2055
|
onStop: p
|
|
2056
2056
|
}));
|
|
2057
2057
|
}
|
|
2058
|
-
function b(
|
|
2059
|
-
m(Object.assign({ type: "spring", stiffness: i, damping: s, restDelta: u },
|
|
2058
|
+
function b(g) {
|
|
2059
|
+
m(Object.assign({ type: "spring", stiffness: i, damping: s, restDelta: u }, g));
|
|
2060
2060
|
}
|
|
2061
2061
|
if (h(t))
|
|
2062
|
-
b({ from: t, velocity: e, to:
|
|
2062
|
+
b({ from: t, velocity: e, to: y(t) });
|
|
2063
2063
|
else {
|
|
2064
|
-
let
|
|
2065
|
-
typeof l < "u" && (
|
|
2066
|
-
const P = g
|
|
2067
|
-
let
|
|
2068
|
-
const j = (
|
|
2069
|
-
|
|
2064
|
+
let g = o * e + t;
|
|
2065
|
+
typeof l < "u" && (g = l(g));
|
|
2066
|
+
const P = y(g), w = P === n ? -1 : 1;
|
|
2067
|
+
let V, O;
|
|
2068
|
+
const j = (A) => {
|
|
2069
|
+
V = O, O = A, e = _i(A - V, Ue().delta), (w === 1 && A > P || w === -1 && A < P) && b({ from: A, to: P, velocity: e });
|
|
2070
2070
|
};
|
|
2071
2071
|
m({
|
|
2072
2072
|
type: "decay",
|
|
@@ -2076,19 +2076,19 @@ function gc({ from: t = 0, velocity: e = 0, min: n, max: r, power: o = 0.8, time
|
|
|
2076
2076
|
power: o,
|
|
2077
2077
|
restDelta: u,
|
|
2078
2078
|
modifyTarget: l,
|
|
2079
|
-
onUpdate: h(
|
|
2079
|
+
onUpdate: h(g) ? j : void 0
|
|
2080
2080
|
});
|
|
2081
2081
|
}
|
|
2082
2082
|
return {
|
|
2083
2083
|
stop: () => v == null ? void 0 : v.stop()
|
|
2084
2084
|
};
|
|
2085
2085
|
}
|
|
2086
|
-
const Wn = (t) => t.hasOwnProperty("x") && t.hasOwnProperty("y"),
|
|
2086
|
+
const Wn = (t) => t.hasOwnProperty("x") && t.hasOwnProperty("y"), Qr = (t) => Wn(t) && t.hasOwnProperty("z"), Me = (t, e) => Math.abs(t - e);
|
|
2087
2087
|
function $i(t, e) {
|
|
2088
2088
|
if (kn(t) && kn(e))
|
|
2089
2089
|
return Me(t, e);
|
|
2090
2090
|
if (Wn(t) && Wn(e)) {
|
|
2091
|
-
const n = Me(t.x, e.x), r = Me(t.y, e.y), o =
|
|
2091
|
+
const n = Me(t.x, e.x), r = Me(t.y, e.y), o = Qr(t) && Qr(e) ? Me(t.z, e.z) : 0;
|
|
2092
2092
|
return Math.sqrt(Math.pow(n, 2) + Math.pow(r, 2) + Math.pow(o, 2));
|
|
2093
2093
|
}
|
|
2094
2094
|
}
|
|
@@ -2114,7 +2114,7 @@ function Tc(t, e, n, r) {
|
|
|
2114
2114
|
const Fe = 11, Ie = 1 / (Fe - 1);
|
|
2115
2115
|
function wc(t, e, n, r) {
|
|
2116
2116
|
if (t === e && n === r)
|
|
2117
|
-
return
|
|
2117
|
+
return ur;
|
|
2118
2118
|
const o = new Float32Array(Fe);
|
|
2119
2119
|
for (let i = 0; i < Fe; ++i)
|
|
2120
2120
|
o[i] = Ye(i * Ie, t, n);
|
|
@@ -2141,21 +2141,21 @@ function Vc(t) {
|
|
|
2141
2141
|
var h;
|
|
2142
2142
|
return c(), s.current = !1, (h = a.animationState) === null || h === void 0 || h.setActive(U.Tap, !1), !ji();
|
|
2143
2143
|
}
|
|
2144
|
-
function d(h,
|
|
2145
|
-
f() && (Di(a.getInstance(), h.target) ? e == null || e(h,
|
|
2144
|
+
function d(h, y) {
|
|
2145
|
+
f() && (Di(a.getInstance(), h.target) ? e == null || e(h, y) : r == null || r(h, y));
|
|
2146
2146
|
}
|
|
2147
|
-
function p(h,
|
|
2148
|
-
f() && (r == null || r(h,
|
|
2147
|
+
function p(h, y) {
|
|
2148
|
+
f() && (r == null || r(h, y));
|
|
2149
2149
|
}
|
|
2150
|
-
function v(h,
|
|
2150
|
+
function v(h, y) {
|
|
2151
2151
|
var m;
|
|
2152
|
-
c(), !s.current && (s.current = !0, u.current = nn(Kt(window, "pointerup", d, l), Kt(window, "pointercancel", p, l)), (m = a.animationState) === null || m === void 0 || m.setActive(U.Tap, !0), n == null || n(h,
|
|
2152
|
+
c(), !s.current && (s.current = !0, u.current = nn(Kt(window, "pointerup", d, l), Kt(window, "pointercancel", p, l)), (m = a.animationState) === null || m === void 0 || m.setActive(U.Tap, !0), n == null || n(h, y));
|
|
2153
2153
|
}
|
|
2154
2154
|
qe(a, "pointerdown", i ? v : void 0, l), Bi(c);
|
|
2155
2155
|
}
|
|
2156
|
-
var
|
|
2156
|
+
var _r = /* @__PURE__ */ new Set();
|
|
2157
2157
|
function oa(t, e, n) {
|
|
2158
|
-
t ||
|
|
2158
|
+
t || _r.has(e) || (console.warn(e), _r.add(e));
|
|
2159
2159
|
}
|
|
2160
2160
|
var qn = /* @__PURE__ */ new WeakMap(), bn = /* @__PURE__ */ new WeakMap(), Ec = function(t) {
|
|
2161
2161
|
var e;
|
|
@@ -2259,32 +2259,32 @@ function aa(t, e) {
|
|
|
2259
2259
|
}
|
|
2260
2260
|
var Xe = function(t) {
|
|
2261
2261
|
return t * 1e3;
|
|
2262
|
-
},
|
|
2263
|
-
linear:
|
|
2264
|
-
easeIn:
|
|
2262
|
+
}, $r = {
|
|
2263
|
+
linear: ur,
|
|
2264
|
+
easeIn: lr,
|
|
2265
2265
|
easeInOut: Ui,
|
|
2266
2266
|
easeOut: Zl,
|
|
2267
2267
|
circIn: Yi,
|
|
2268
2268
|
circInOut: Kl,
|
|
2269
|
-
circOut:
|
|
2270
|
-
backIn:
|
|
2269
|
+
circOut: cr,
|
|
2270
|
+
backIn: fr,
|
|
2271
2271
|
backInOut: Ql,
|
|
2272
2272
|
backOut: Jl,
|
|
2273
2273
|
anticipate: _l,
|
|
2274
2274
|
bounceIn: nc,
|
|
2275
2275
|
bounceInOut: rc,
|
|
2276
2276
|
bounceOut: ze
|
|
2277
|
-
},
|
|
2277
|
+
}, to = function(t) {
|
|
2278
2278
|
if (Array.isArray(t)) {
|
|
2279
2279
|
vt(t.length === 4, "Cubic bezier arrays must contain four numerical values.");
|
|
2280
|
-
var e =
|
|
2280
|
+
var e = nt(t, 4), n = e[0], r = e[1], o = e[2], a = e[3];
|
|
2281
2281
|
return wc(n, r, o, a);
|
|
2282
2282
|
} else if (typeof t == "string")
|
|
2283
|
-
return vt(
|
|
2283
|
+
return vt($r[t] !== void 0, "Invalid easing type '".concat(t, "'")), $r[t];
|
|
2284
2284
|
return t;
|
|
2285
2285
|
}, kc = function(t) {
|
|
2286
2286
|
return Array.isArray(t) && typeof t[0] != "number";
|
|
2287
|
-
},
|
|
2287
|
+
}, eo = function(t, e) {
|
|
2288
2288
|
return t === "zIndex" ? !1 : !!(typeof e == "number" || Array.isArray(e) || typeof e == "string" && // It's animatable if we have a string
|
|
2289
2289
|
Mt.test(e) && // And it contains numbers and/or colors
|
|
2290
2290
|
!e.startsWith("url("));
|
|
@@ -2314,7 +2314,7 @@ var Xe = function(t) {
|
|
|
2314
2314
|
duration: 0.8,
|
|
2315
2315
|
values: t
|
|
2316
2316
|
};
|
|
2317
|
-
},
|
|
2317
|
+
}, no = {
|
|
2318
2318
|
x: Ft,
|
|
2319
2319
|
y: Ft,
|
|
2320
2320
|
z: Ft,
|
|
@@ -2331,7 +2331,7 @@ var Xe = function(t) {
|
|
|
2331
2331
|
default: Oe
|
|
2332
2332
|
}, Hc = function(t, e) {
|
|
2333
2333
|
var n;
|
|
2334
|
-
return ge(e) ? n = Fc : n =
|
|
2334
|
+
return ge(e) ? n = Fc : n = no[t] || no.default, x({ to: e }, n(e));
|
|
2335
2335
|
}, Wc = x(x({}, yi), {
|
|
2336
2336
|
// Color props
|
|
2337
2337
|
color: ct,
|
|
@@ -2347,11 +2347,11 @@ var Xe = function(t) {
|
|
|
2347
2347
|
borderLeftColor: ct,
|
|
2348
2348
|
filter: jn,
|
|
2349
2349
|
WebkitFilter: jn
|
|
2350
|
-
}),
|
|
2350
|
+
}), dr = function(t) {
|
|
2351
2351
|
return Wc[t];
|
|
2352
2352
|
};
|
|
2353
|
-
function
|
|
2354
|
-
var n, r =
|
|
2353
|
+
function vr(t, e) {
|
|
2354
|
+
var n, r = dr(t);
|
|
2355
2355
|
return r !== jn && (r = Mt), (n = r.getAnimatableNone) === null || n === void 0 ? void 0 : n.call(r, e);
|
|
2356
2356
|
}
|
|
2357
2357
|
function qc(t) {
|
|
@@ -2359,26 +2359,26 @@ function qc(t) {
|
|
|
2359
2359
|
var e = gt(t, ["when", "delay", "delayChildren", "staggerChildren", "staggerDirection", "repeat", "repeatType", "repeatDelay", "from"]);
|
|
2360
2360
|
return !!Object.keys(e).length;
|
|
2361
2361
|
}
|
|
2362
|
-
var
|
|
2362
|
+
var ro = !1;
|
|
2363
2363
|
function Gc(t) {
|
|
2364
2364
|
var e = t.ease, n = t.times, r = t.yoyo, o = t.flip, a = t.loop, i = gt(t, ["ease", "times", "yoyo", "flip", "loop"]), s = x({}, i);
|
|
2365
|
-
return n && (s.offset = n), i.duration && (s.duration = Xe(i.duration)), i.repeatDelay && (s.repeatDelay = Xe(i.repeatDelay)), e && (s.ease = kc(e) ? e.map(
|
|
2365
|
+
return n && (s.offset = n), i.duration && (s.duration = Xe(i.duration)), i.repeatDelay && (s.repeatDelay = Xe(i.repeatDelay)), e && (s.ease = kc(e) ? e.map(to) : to(e)), i.type === "tween" && (s.type = "keyframes"), (r || a || o) && (be(!ro, "yoyo, loop and flip have been removed from the API. Replace with repeat and repeatType options."), ro = !0, r ? s.repeatType = "reverse" : a ? s.repeatType = "loop" : o && (s.repeatType = "mirror"), s.repeat = a || r || o || i.repeat), i.type !== "spring" && (s.type = "keyframes"), s;
|
|
2366
2366
|
}
|
|
2367
2367
|
function zc(t, e) {
|
|
2368
|
-
var n, r, o =
|
|
2368
|
+
var n, r, o = pr(t, e) || {};
|
|
2369
2369
|
return (r = (n = o.delay) !== null && n !== void 0 ? n : t.delay) !== null && r !== void 0 ? r : 0;
|
|
2370
2370
|
}
|
|
2371
2371
|
function Uc(t) {
|
|
2372
|
-
return Array.isArray(t.to) && t.to[0] === null && (t.to = ht([],
|
|
2372
|
+
return Array.isArray(t.to) && t.to[0] === null && (t.to = ht([], nt(t.to), !1), t.to[0] = t.from), t;
|
|
2373
2373
|
}
|
|
2374
2374
|
function Yc(t, e, n) {
|
|
2375
2375
|
var r;
|
|
2376
2376
|
return Array.isArray(e.to) && ((r = t.duration) !== null && r !== void 0 || (t.duration = 0.8)), Uc(e), qc(t) || (t = x(x({}, t), Hc(n, e.to))), x(x({}, e), Gc(t));
|
|
2377
2377
|
}
|
|
2378
2378
|
function Xc(t, e, n, r, o) {
|
|
2379
|
-
var a, i =
|
|
2380
|
-
s === "none" && u && typeof n == "string" ? s =
|
|
2381
|
-
var l =
|
|
2379
|
+
var a, i = pr(r, t), s = (a = i.from) !== null && a !== void 0 ? a : e.get(), u = eo(t, n);
|
|
2380
|
+
s === "none" && u && typeof n == "string" ? s = vr(t, n) : oo(s) && typeof n == "string" ? s = io(n) : !Array.isArray(n) && oo(n) && typeof s == "string" && (n = io(s));
|
|
2381
|
+
var l = eo(t, s);
|
|
2382
2382
|
be(l === u, "You are trying to animate ".concat(t, ' from "').concat(s, '" to "').concat(n, '". ').concat(s, " is not an animatable value - to enable this animation set ").concat(s, " to a value animatable to ").concat(n, " via the `style` property."));
|
|
2383
2383
|
function c() {
|
|
2384
2384
|
var d = {
|
|
@@ -2405,16 +2405,16 @@ function Xc(t, e, n, r, o) {
|
|
|
2405
2405
|
}
|
|
2406
2406
|
return !l || !u || i.type === !1 ? f : c;
|
|
2407
2407
|
}
|
|
2408
|
-
function
|
|
2408
|
+
function oo(t) {
|
|
2409
2409
|
return t === 0 || typeof t == "string" && parseFloat(t) === 0 && t.indexOf(" ") === -1;
|
|
2410
2410
|
}
|
|
2411
|
-
function
|
|
2412
|
-
return typeof t == "number" ? 0 :
|
|
2411
|
+
function io(t) {
|
|
2412
|
+
return typeof t == "number" ? 0 : vr("", t);
|
|
2413
2413
|
}
|
|
2414
|
-
function
|
|
2414
|
+
function pr(t, e) {
|
|
2415
2415
|
return t[e] || t.default || t;
|
|
2416
2416
|
}
|
|
2417
|
-
function
|
|
2417
|
+
function hr(t, e, n, r) {
|
|
2418
2418
|
return r === void 0 && (r = {}), e.start(function(o) {
|
|
2419
2419
|
var a, i, s = Xc(t, e, n, r, o), u = zc(r, t), l = function() {
|
|
2420
2420
|
return i = s();
|
|
@@ -2429,10 +2429,10 @@ var Zc = function(t) {
|
|
|
2429
2429
|
}, Kc = function(t) {
|
|
2430
2430
|
return /^0[^.\s]+$/.test(t);
|
|
2431
2431
|
};
|
|
2432
|
-
function
|
|
2432
|
+
function mr(t, e) {
|
|
2433
2433
|
t.indexOf(e) === -1 && t.push(e);
|
|
2434
2434
|
}
|
|
2435
|
-
function
|
|
2435
|
+
function gr(t, e) {
|
|
2436
2436
|
var n = t.indexOf(e);
|
|
2437
2437
|
n > -1 && t.splice(n, 1);
|
|
2438
2438
|
}
|
|
@@ -2444,8 +2444,8 @@ var ue = (
|
|
|
2444
2444
|
}
|
|
2445
2445
|
return t.prototype.add = function(e) {
|
|
2446
2446
|
var n = this;
|
|
2447
|
-
return
|
|
2448
|
-
return
|
|
2447
|
+
return mr(this.subscriptions, e), function() {
|
|
2448
|
+
return gr(n.subscriptions, e);
|
|
2449
2449
|
};
|
|
2450
2450
|
}, t.prototype.notify = function(e, n, r) {
|
|
2451
2451
|
var o = this.subscriptions.length;
|
|
@@ -2532,15 +2532,15 @@ var sa = function(t) {
|
|
|
2532
2532
|
parse: function(t) {
|
|
2533
2533
|
return t;
|
|
2534
2534
|
}
|
|
2535
|
-
}, ua = [zt,
|
|
2535
|
+
}, ua = [zt, M, wt, Lt, Wu, Hu, _c], re = function(t) {
|
|
2536
2536
|
return ua.find(sa(t));
|
|
2537
|
-
}, $c = ht(ht([],
|
|
2537
|
+
}, $c = ht(ht([], nt(ua), !1), [ct, Mt], !1), tf = function(t) {
|
|
2538
2538
|
return $c.find(sa(t));
|
|
2539
2539
|
};
|
|
2540
2540
|
function ef(t, e, n) {
|
|
2541
2541
|
t.hasValue(e) ? t.getValue(e).set(n) : t.addValue(e, _t(n));
|
|
2542
2542
|
}
|
|
2543
|
-
function
|
|
2543
|
+
function yr(t, e) {
|
|
2544
2544
|
var n = $e(t, e), r = n ? t.makeTargetAnimatable(n, !1) : {}, o = r.transitionEnd, a = o === void 0 ? {} : o;
|
|
2545
2545
|
r.transition;
|
|
2546
2546
|
var i = gt(r, ["transitionEnd", "transition"]);
|
|
@@ -2551,10 +2551,10 @@ function gr(t, e) {
|
|
|
2551
2551
|
}
|
|
2552
2552
|
}
|
|
2553
2553
|
function Gn(t, e) {
|
|
2554
|
-
var n = ht([],
|
|
2554
|
+
var n = ht([], nt(e), !1).reverse();
|
|
2555
2555
|
n.forEach(function(r) {
|
|
2556
2556
|
var o, a = t.getVariant(r);
|
|
2557
|
-
a &&
|
|
2557
|
+
a && yr(t, a), (o = t.variantChildren) === null || o === void 0 || o.forEach(function(i) {
|
|
2558
2558
|
Gn(i, e);
|
|
2559
2559
|
});
|
|
2560
2560
|
});
|
|
@@ -2564,7 +2564,7 @@ function nf(t, e) {
|
|
|
2564
2564
|
return Gn(t, e);
|
|
2565
2565
|
if (typeof e == "string")
|
|
2566
2566
|
return Gn(t, [e]);
|
|
2567
|
-
|
|
2567
|
+
yr(t, e);
|
|
2568
2568
|
}
|
|
2569
2569
|
function rf(t, e, n) {
|
|
2570
2570
|
var r, o, a, i, s = Object.keys(e).filter(function(p) {
|
|
@@ -2573,7 +2573,7 @@ function rf(t, e, n) {
|
|
|
2573
2573
|
if (u)
|
|
2574
2574
|
for (var l = 0; l < u; l++) {
|
|
2575
2575
|
var c = s[l], f = e[c], d = null;
|
|
2576
|
-
Array.isArray(f) && (d = f[0]), d === null && (d = (o = (r = n[c]) !== null && r !== void 0 ? r : t.readValue(c)) !== null && o !== void 0 ? o : e[c]), d != null && (typeof d == "string" && (Zc(d) || Kc(d)) ? d = parseFloat(d) : !tf(d) && Mt.test(f) && (d =
|
|
2576
|
+
Array.isArray(f) && (d = f[0]), d === null && (d = (o = (r = n[c]) !== null && r !== void 0 ? r : t.readValue(c)) !== null && o !== void 0 ? o : e[c]), d != null && (typeof d == "string" && (Zc(d) || Kc(d)) ? d = parseFloat(d) : !tf(d) && Mt.test(f) && (d = vr(c, f)), t.addValue(c, _t(d)), (a = (i = n)[c]) !== null && a !== void 0 || (i[c] = d), t.setBaseTarget(c, d));
|
|
2577
2577
|
}
|
|
2578
2578
|
}
|
|
2579
2579
|
function of(t, e) {
|
|
@@ -2617,13 +2617,13 @@ function zn(t, e, n) {
|
|
|
2617
2617
|
return Promise.resolve();
|
|
2618
2618
|
}, u = !((r = t.variantChildren) === null || r === void 0) && r.size ? function(p) {
|
|
2619
2619
|
p === void 0 && (p = 0);
|
|
2620
|
-
var v = i.delayChildren, h = v === void 0 ? 0 : v,
|
|
2621
|
-
return sf(t, e, h + p,
|
|
2620
|
+
var v = i.delayChildren, h = v === void 0 ? 0 : v, y = i.staggerChildren, m = i.staggerDirection;
|
|
2621
|
+
return sf(t, e, h + p, y, m, n);
|
|
2622
2622
|
} : function() {
|
|
2623
2623
|
return Promise.resolve();
|
|
2624
2624
|
}, l = i.when;
|
|
2625
2625
|
if (l) {
|
|
2626
|
-
var c =
|
|
2626
|
+
var c = nt(l === "beforeChildren" ? [s, u] : [u, s], 2), f = c[0], d = c[1];
|
|
2627
2627
|
return f().then(d);
|
|
2628
2628
|
} else
|
|
2629
2629
|
return Promise.all([s(), u(n.delay)]);
|
|
@@ -2632,17 +2632,17 @@ function ca(t, e, n) {
|
|
|
2632
2632
|
var r, o = n === void 0 ? {} : n, a = o.delay, i = a === void 0 ? 0 : a, s = o.transitionOverride, u = o.type, l = t.makeTargetAnimatable(e), c = l.transition, f = c === void 0 ? t.getDefaultTransition() : c, d = l.transitionEnd, p = gt(l, ["transition", "transitionEnd"]);
|
|
2633
2633
|
s && (f = s);
|
|
2634
2634
|
var v = [], h = u && ((r = t.animationState) === null || r === void 0 ? void 0 : r.getState()[u]);
|
|
2635
|
-
for (var
|
|
2636
|
-
var m = t.getValue(
|
|
2637
|
-
if (!(!m || b === void 0 || h && cf(h,
|
|
2638
|
-
var
|
|
2639
|
-
t.shouldReduceMotion && Pe(
|
|
2640
|
-
var P =
|
|
2635
|
+
for (var y in p) {
|
|
2636
|
+
var m = t.getValue(y), b = p[y];
|
|
2637
|
+
if (!(!m || b === void 0 || h && cf(h, y))) {
|
|
2638
|
+
var g = x({ delay: i }, f);
|
|
2639
|
+
t.shouldReduceMotion && Pe(y) && (g = x(x({}, g), { type: !1, delay: 0 }));
|
|
2640
|
+
var P = hr(y, m, b, g);
|
|
2641
2641
|
v.push(P);
|
|
2642
2642
|
}
|
|
2643
2643
|
}
|
|
2644
2644
|
return Promise.all(v).then(function() {
|
|
2645
|
-
d &&
|
|
2645
|
+
d && yr(t, d);
|
|
2646
2646
|
});
|
|
2647
2647
|
}
|
|
2648
2648
|
function sf(t, e, n, r, o, a) {
|
|
@@ -2670,7 +2670,7 @@ function cf(t, e) {
|
|
|
2670
2670
|
var n = t.protectedKeys, r = t.needsAnimating, o = n.hasOwnProperty(e) && r[e] !== !0;
|
|
2671
2671
|
return r[e] = !1, o;
|
|
2672
2672
|
}
|
|
2673
|
-
var
|
|
2673
|
+
var Sr = [
|
|
2674
2674
|
U.Animate,
|
|
2675
2675
|
U.InView,
|
|
2676
2676
|
U.Focus,
|
|
@@ -2678,7 +2678,7 @@ var yr = [
|
|
|
2678
2678
|
U.Tap,
|
|
2679
2679
|
U.Drag,
|
|
2680
2680
|
U.Exit
|
|
2681
|
-
], ff = ht([],
|
|
2681
|
+
], ff = ht([], nt(Sr), !1).reverse(), df = Sr.length;
|
|
2682
2682
|
function vf(t) {
|
|
2683
2683
|
return function(e) {
|
|
2684
2684
|
return Promise.all(e.map(function(n) {
|
|
@@ -2704,51 +2704,51 @@ function pf(t) {
|
|
|
2704
2704
|
e = c(t);
|
|
2705
2705
|
}
|
|
2706
2706
|
function u(c, f) {
|
|
2707
|
-
for (var d, p = t.getProps(), v = t.getVariantContext(!0) || {}, h = [],
|
|
2708
|
-
var j = ff[
|
|
2709
|
-
|
|
2710
|
-
var H = k === v[j] && k !== p[j] &&
|
|
2711
|
-
if (H && o && t.manuallyAnimateOnMount && (H = !1),
|
|
2712
|
-
!
|
|
2713
|
-
!k && !
|
|
2714
|
-
|
|
2707
|
+
for (var d, p = t.getProps(), v = t.getVariantContext(!0) || {}, h = [], y = /* @__PURE__ */ new Set(), m = {}, b = 1 / 0, g = function(O) {
|
|
2708
|
+
var j = ff[O], A = n[j], k = (d = p[j]) !== null && d !== void 0 ? d : v[j], _ = bt(k), W = j === f ? A.isActive : null;
|
|
2709
|
+
W === !1 && (b = O);
|
|
2710
|
+
var H = k === v[j] && k !== p[j] && _;
|
|
2711
|
+
if (H && o && t.manuallyAnimateOnMount && (H = !1), A.protectedKeys = x({}, m), // If it isn't active and hasn't *just* been set as inactive
|
|
2712
|
+
!A.isActive && W === null || // If we didn't and don't have any defined prop for this animation type
|
|
2713
|
+
!k && !A.prevProp || // Or if the prop doesn't define an animation
|
|
2714
|
+
or(k) || typeof k == "boolean")
|
|
2715
2715
|
return "continue";
|
|
2716
|
-
var
|
|
2717
|
-
j === f &&
|
|
2718
|
-
|
|
2719
|
-
|
|
2720
|
-
var it =
|
|
2721
|
-
|
|
2716
|
+
var R = hf(A.prevProp, k), Y = R || // If we're making this variant active, we want to always make it active
|
|
2717
|
+
j === f && A.isActive && !H && _ || // If we removed a higher-priority variant (i is in reverse order)
|
|
2718
|
+
O > b && _, $ = Array.isArray(k) ? k : [k], I = $.reduce(a, {});
|
|
2719
|
+
W === !1 && (I = {});
|
|
2720
|
+
var it = A.prevResolvedValues, at = it === void 0 ? {} : it, ut = x(x({}, at), I), q = function(E) {
|
|
2721
|
+
Y = !0, y.delete(E), A.needsAnimating[E] = !0;
|
|
2722
2722
|
};
|
|
2723
2723
|
for (var J in ut) {
|
|
2724
2724
|
var D = I[J], T = at[J];
|
|
2725
|
-
m.hasOwnProperty(J) || (D !== T ? ge(D) && ge(T) ? !aa(D, T) ||
|
|
2725
|
+
m.hasOwnProperty(J) || (D !== T ? ge(D) && ge(T) ? !aa(D, T) || R ? q(J) : A.protectedKeys[J] = !0 : D !== void 0 ? q(J) : y.add(J) : D !== void 0 && y.has(J) ? q(J) : A.protectedKeys[J] = !0);
|
|
2726
2726
|
}
|
|
2727
|
-
|
|
2727
|
+
A.prevProp = k, A.prevResolvedValues = I, A.isActive && (m = x(x({}, m), I)), o && t.blockInitialAnimation && (Y = !1), Y && !H && h.push.apply(h, ht([], nt($.map(function(E) {
|
|
2728
2728
|
return {
|
|
2729
|
-
animation:
|
|
2729
|
+
animation: E,
|
|
2730
2730
|
options: x({ type: j }, c)
|
|
2731
2731
|
};
|
|
2732
2732
|
})), !1));
|
|
2733
2733
|
}, P = 0; P < df; P++)
|
|
2734
|
-
|
|
2735
|
-
if (r = x({}, m),
|
|
2734
|
+
g(P);
|
|
2735
|
+
if (r = x({}, m), y.size) {
|
|
2736
2736
|
var w = {};
|
|
2737
|
-
|
|
2738
|
-
var j = t.getBaseTarget(
|
|
2739
|
-
j !== void 0 && (w[
|
|
2737
|
+
y.forEach(function(O) {
|
|
2738
|
+
var j = t.getBaseTarget(O);
|
|
2739
|
+
j !== void 0 && (w[O] = j);
|
|
2740
2740
|
}), h.push({ animation: w });
|
|
2741
2741
|
}
|
|
2742
|
-
var
|
|
2743
|
-
return o && p.initial === !1 && !t.manuallyAnimateOnMount && (
|
|
2742
|
+
var V = !!h.length;
|
|
2743
|
+
return o && p.initial === !1 && !t.manuallyAnimateOnMount && (V = !1), o = !1, V ? e(h) : Promise.resolve();
|
|
2744
2744
|
}
|
|
2745
2745
|
function l(c, f, d) {
|
|
2746
2746
|
var p;
|
|
2747
2747
|
if (n[c].isActive === f)
|
|
2748
2748
|
return Promise.resolve();
|
|
2749
|
-
(p = t.variantChildren) === null || p === void 0 || p.forEach(function(
|
|
2749
|
+
(p = t.variantChildren) === null || p === void 0 || p.forEach(function(y) {
|
|
2750
2750
|
var m;
|
|
2751
|
-
return (m =
|
|
2751
|
+
return (m = y.animationState) === null || m === void 0 ? void 0 : m.setActive(c, f);
|
|
2752
2752
|
}), n[c].isActive = f;
|
|
2753
2753
|
var v = u(d, c);
|
|
2754
2754
|
for (var h in n)
|
|
@@ -2783,12 +2783,12 @@ function mf() {
|
|
|
2783
2783
|
var gf = {
|
|
2784
2784
|
animation: Bt(function(t) {
|
|
2785
2785
|
var e = t.visualElement, n = t.animate;
|
|
2786
|
-
e.animationState || (e.animationState = pf(e)),
|
|
2786
|
+
e.animationState || (e.animationState = pf(e)), or(n) && F(function() {
|
|
2787
2787
|
return n.subscribe(e);
|
|
2788
2788
|
}, [n]);
|
|
2789
2789
|
}),
|
|
2790
2790
|
exit: Bt(function(t) {
|
|
2791
|
-
var e = t.custom, n = t.visualElement, r =
|
|
2791
|
+
var e = t.custom, n = t.visualElement, r = nt(ia(), 2), o = r[0], a = r[1], i = st(_e);
|
|
2792
2792
|
F(function() {
|
|
2793
2793
|
var s, u;
|
|
2794
2794
|
n.isPresent = o;
|
|
@@ -2805,10 +2805,10 @@ var gf = {
|
|
|
2805
2805
|
if (o.lastMoveEvent && o.lastMoveEventInfo) {
|
|
2806
2806
|
var d = Tn(o.lastMoveEventInfo, o.history), p = o.startEvent !== null, v = $i(d.offset, { x: 0, y: 0 }) >= 3;
|
|
2807
2807
|
if (!(!p && !v)) {
|
|
2808
|
-
var h = d.point,
|
|
2809
|
-
o.history.push(x(x({}, h), { timestamp:
|
|
2810
|
-
var m = o.handlers, b = m.onStart,
|
|
2811
|
-
p || (b && b(o.lastMoveEvent, d), o.startEvent = o.lastMoveEvent),
|
|
2808
|
+
var h = d.point, y = Ue().timestamp;
|
|
2809
|
+
o.history.push(x(x({}, h), { timestamp: y }));
|
|
2810
|
+
var m = o.handlers, b = m.onStart, g = m.onMove;
|
|
2811
|
+
p || (b && b(o.lastMoveEvent, d), o.startEvent = o.lastMoveEvent), g && g(o.lastMoveEvent, d);
|
|
2812
2812
|
}
|
|
2813
2813
|
}
|
|
2814
2814
|
}, this.handlePointerMove = function(d, p) {
|
|
@@ -2819,11 +2819,11 @@ var gf = {
|
|
|
2819
2819
|
Vt.update(o.updatePoint, !0);
|
|
2820
2820
|
}, this.handlePointerUp = function(d, p) {
|
|
2821
2821
|
o.end();
|
|
2822
|
-
var v = o.handlers, h = v.onEnd,
|
|
2823
|
-
o.startEvent && h && h(d, m),
|
|
2822
|
+
var v = o.handlers, h = v.onEnd, y = v.onSessionEnd, m = Tn(Pn(p, o.transformPagePoint), o.history);
|
|
2823
|
+
o.startEvent && h && h(d, m), y && y(d, m);
|
|
2824
2824
|
}, !(Mi(e) && e.touches.length > 1)) {
|
|
2825
2825
|
this.handlers = n, this.transformPagePoint = i;
|
|
2826
|
-
var s =
|
|
2826
|
+
var s = ir(e), u = Pn(s, this.transformPagePoint), l = u.point, c = Ue().timestamp;
|
|
2827
2827
|
this.history = [x(x({}, l), { timestamp: c })];
|
|
2828
2828
|
var f = n.onSessionStart;
|
|
2829
2829
|
f && f(e, Tn(u, this.history)), this.removeListeners = nn(Kt(window, "pointermove", this.handlePointerMove), Kt(window, "pointerup", this.handlePointerUp), Kt(window, "pointercancel", this.handlePointerUp));
|
|
@@ -2839,15 +2839,15 @@ var gf = {
|
|
|
2839
2839
|
function Pn(t, e) {
|
|
2840
2840
|
return e ? { point: e(t.point) } : t;
|
|
2841
2841
|
}
|
|
2842
|
-
function
|
|
2842
|
+
function ao(t, e) {
|
|
2843
2843
|
return { x: t.x - e.x, y: t.y - e.y };
|
|
2844
2844
|
}
|
|
2845
2845
|
function Tn(t, e) {
|
|
2846
2846
|
var n = t.point;
|
|
2847
2847
|
return {
|
|
2848
2848
|
point: n,
|
|
2849
|
-
delta:
|
|
2850
|
-
offset:
|
|
2849
|
+
delta: ao(n, da(e)),
|
|
2850
|
+
offset: ao(n, yf(e)),
|
|
2851
2851
|
velocity: Sf(e, 0.1)
|
|
2852
2852
|
};
|
|
2853
2853
|
}
|
|
@@ -2876,32 +2876,32 @@ function Sf(t, e) {
|
|
|
2876
2876
|
function It(t) {
|
|
2877
2877
|
return t.max - t.min;
|
|
2878
2878
|
}
|
|
2879
|
-
function
|
|
2879
|
+
function so(t, e, n) {
|
|
2880
2880
|
return e === void 0 && (e = 0), n === void 0 && (n = 0.01), $i(t, e) < n;
|
|
2881
2881
|
}
|
|
2882
|
-
function
|
|
2883
|
-
r === void 0 && (r = 0.5), t.origin = r, t.originPoint =
|
|
2882
|
+
function uo(t, e, n, r) {
|
|
2883
|
+
r === void 0 && (r = 0.5), t.origin = r, t.originPoint = tt(e.min, e.max, t.origin), t.scale = It(n) / It(e), (so(t.scale, 1, 1e-4) || isNaN(t.scale)) && (t.scale = 1), t.translate = tt(n.min, n.max, t.origin) - t.originPoint, (so(t.translate) || isNaN(t.translate)) && (t.translate = 0);
|
|
2884
2884
|
}
|
|
2885
2885
|
function le(t, e, n, r) {
|
|
2886
|
-
|
|
2886
|
+
uo(t.x, e.x, n.x, r == null ? void 0 : r.originX), uo(t.y, e.y, n.y, r == null ? void 0 : r.originY);
|
|
2887
2887
|
}
|
|
2888
|
-
function
|
|
2888
|
+
function lo(t, e, n) {
|
|
2889
2889
|
t.min = n.min + e.min, t.max = t.min + It(e);
|
|
2890
2890
|
}
|
|
2891
2891
|
function bf(t, e, n) {
|
|
2892
|
-
|
|
2892
|
+
lo(t.x, e.x, n.x), lo(t.y, e.y, n.y);
|
|
2893
2893
|
}
|
|
2894
|
-
function
|
|
2894
|
+
function co(t, e, n) {
|
|
2895
2895
|
t.min = e.min - n.min, t.max = t.min + It(e);
|
|
2896
2896
|
}
|
|
2897
2897
|
function ce(t, e, n) {
|
|
2898
|
-
|
|
2898
|
+
co(t.x, e.x, n.x), co(t.y, e.y, n.y);
|
|
2899
2899
|
}
|
|
2900
2900
|
function xf(t, e, n) {
|
|
2901
2901
|
var r = e.min, o = e.max;
|
|
2902
|
-
return r !== void 0 && t < r ? t = n ?
|
|
2902
|
+
return r !== void 0 && t < r ? t = n ? tt(r, t, n.min) : Math.max(t, r) : o !== void 0 && t > o && (t = n ? tt(o, t, n.max) : Math.min(t, o)), t;
|
|
2903
2903
|
}
|
|
2904
|
-
function
|
|
2904
|
+
function fo(t, e, n) {
|
|
2905
2905
|
return {
|
|
2906
2906
|
min: e !== void 0 ? t.min + e : void 0,
|
|
2907
2907
|
max: n !== void 0 ? t.max + n - (t.max - t.min) : void 0
|
|
@@ -2910,18 +2910,18 @@ function co(t, e, n) {
|
|
|
2910
2910
|
function Pf(t, e) {
|
|
2911
2911
|
var n = e.top, r = e.left, o = e.bottom, a = e.right;
|
|
2912
2912
|
return {
|
|
2913
|
-
x:
|
|
2914
|
-
y:
|
|
2913
|
+
x: fo(t.x, r, a),
|
|
2914
|
+
y: fo(t.y, n, o)
|
|
2915
2915
|
};
|
|
2916
2916
|
}
|
|
2917
|
-
function
|
|
2917
|
+
function vo(t, e) {
|
|
2918
2918
|
var n, r = e.min - t.min, o = e.max - t.max;
|
|
2919
|
-
return e.max - e.min < t.max - t.min && (n =
|
|
2919
|
+
return e.max - e.min < t.max - t.min && (n = nt([o, r], 2), r = n[0], o = n[1]), { min: r, max: o };
|
|
2920
2920
|
}
|
|
2921
2921
|
function Tf(t, e) {
|
|
2922
2922
|
return {
|
|
2923
|
-
x:
|
|
2924
|
-
y:
|
|
2923
|
+
x: vo(t.x, e.x),
|
|
2924
|
+
y: vo(t.y, e.y)
|
|
2925
2925
|
};
|
|
2926
2926
|
}
|
|
2927
2927
|
function wf(t, e) {
|
|
@@ -2935,21 +2935,21 @@ function Vf(t, e) {
|
|
|
2935
2935
|
var Un = 0.35;
|
|
2936
2936
|
function Ef(t) {
|
|
2937
2937
|
return t === void 0 && (t = Un), t === !1 ? t = 0 : t === !0 && (t = Un), {
|
|
2938
|
-
x:
|
|
2939
|
-
y:
|
|
2938
|
+
x: po(t, "left", "right"),
|
|
2939
|
+
y: po(t, "top", "bottom")
|
|
2940
2940
|
};
|
|
2941
2941
|
}
|
|
2942
|
-
function
|
|
2942
|
+
function po(t, e, n) {
|
|
2943
2943
|
return {
|
|
2944
|
-
min:
|
|
2945
|
-
max:
|
|
2944
|
+
min: ho(t, e),
|
|
2945
|
+
max: ho(t, n)
|
|
2946
2946
|
};
|
|
2947
2947
|
}
|
|
2948
|
-
function
|
|
2948
|
+
function ho(t, e) {
|
|
2949
2949
|
var n;
|
|
2950
2950
|
return typeof t == "number" ? t : (n = t[e]) !== null && n !== void 0 ? n : 0;
|
|
2951
2951
|
}
|
|
2952
|
-
var
|
|
2952
|
+
var mo = function() {
|
|
2953
2953
|
return {
|
|
2954
2954
|
translate: 0,
|
|
2955
2955
|
scale: 1,
|
|
@@ -2958,15 +2958,15 @@ var ho = function() {
|
|
|
2958
2958
|
};
|
|
2959
2959
|
}, fe = function() {
|
|
2960
2960
|
return {
|
|
2961
|
-
x:
|
|
2962
|
-
y:
|
|
2961
|
+
x: mo(),
|
|
2962
|
+
y: mo()
|
|
2963
2963
|
};
|
|
2964
|
-
},
|
|
2964
|
+
}, go = function() {
|
|
2965
2965
|
return { min: 0, max: 0 };
|
|
2966
2966
|
}, lt = function() {
|
|
2967
2967
|
return {
|
|
2968
|
-
x:
|
|
2969
|
-
y:
|
|
2968
|
+
x: go(),
|
|
2969
|
+
y: go()
|
|
2970
2970
|
};
|
|
2971
2971
|
};
|
|
2972
2972
|
function Tt(t) {
|
|
@@ -3002,20 +3002,20 @@ function pa(t) {
|
|
|
3002
3002
|
return !wn(e) || !wn(n) || !wn(r);
|
|
3003
3003
|
}
|
|
3004
3004
|
function Nt(t) {
|
|
3005
|
-
return pa(t) ||
|
|
3005
|
+
return pa(t) || yo(t.x) || yo(t.y) || t.z || t.rotate || t.rotateX || t.rotateY;
|
|
3006
3006
|
}
|
|
3007
|
-
function
|
|
3007
|
+
function yo(t) {
|
|
3008
3008
|
return t && t !== "0%";
|
|
3009
3009
|
}
|
|
3010
3010
|
function Ze(t, e, n) {
|
|
3011
3011
|
var r = t - n, o = e * r;
|
|
3012
3012
|
return n + o;
|
|
3013
3013
|
}
|
|
3014
|
-
function
|
|
3014
|
+
function So(t, e, n, r, o) {
|
|
3015
3015
|
return o !== void 0 && (t = Ze(t, o, r)), Ze(t, n, r) + e;
|
|
3016
3016
|
}
|
|
3017
3017
|
function Yn(t, e, n, r, o) {
|
|
3018
|
-
e === void 0 && (e = 0), n === void 0 && (n = 1), t.min =
|
|
3018
|
+
e === void 0 && (e = 0), n === void 0 && (n = 1), t.min = So(t.min, e, n, r, o), t.max = So(t.max, e, n, r, o);
|
|
3019
3019
|
}
|
|
3020
3020
|
function ha(t, e) {
|
|
3021
3021
|
var n = e.x, r = e.y;
|
|
@@ -3034,13 +3034,13 @@ function Rf(t, e, n, r) {
|
|
|
3034
3034
|
function jt(t, e) {
|
|
3035
3035
|
t.min = t.min + e, t.max = t.max + e;
|
|
3036
3036
|
}
|
|
3037
|
-
function
|
|
3038
|
-
var r =
|
|
3037
|
+
function bo(t, e, n) {
|
|
3038
|
+
var r = nt(n, 3), o = r[0], a = r[1], i = r[2], s = e[i] !== void 0 ? e[i] : 0.5, u = tt(t.min, t.max, s);
|
|
3039
3039
|
Yn(t, e[o], e[a], u, e.scale);
|
|
3040
3040
|
}
|
|
3041
3041
|
var Mf = ["x", "scaleX", "originX"], If = ["y", "scaleY", "originY"];
|
|
3042
3042
|
function Zt(t, e) {
|
|
3043
|
-
|
|
3043
|
+
bo(t.x, e, Mf), bo(t.y, e, If);
|
|
3044
3044
|
}
|
|
3045
3045
|
function ma(t, e) {
|
|
3046
3046
|
return va(Af(t.getBoundingClientRect(), e));
|
|
@@ -3059,26 +3059,26 @@ var Lf = /* @__PURE__ */ new WeakMap(), Nf = (
|
|
|
3059
3059
|
var r = this, o = n === void 0 ? {} : n, a = o.snapToCursor, i = a === void 0 ? !1 : a;
|
|
3060
3060
|
if (this.visualElement.isPresent !== !1) {
|
|
3061
3061
|
var s = function(f) {
|
|
3062
|
-
r.stopAnimation(), i && r.snapToCursor(
|
|
3062
|
+
r.stopAnimation(), i && r.snapToCursor(ir(f, "page").point);
|
|
3063
3063
|
}, u = function(f, d) {
|
|
3064
|
-
var p, v = r.getProps(), h = v.drag,
|
|
3065
|
-
h && !
|
|
3066
|
-
var
|
|
3064
|
+
var p, v = r.getProps(), h = v.drag, y = v.dragPropagation, m = v.onDragStart;
|
|
3065
|
+
h && !y && (r.openGlobalLock && r.openGlobalLock(), r.openGlobalLock = Ni(h), !r.openGlobalLock) || (r.isDragging = !0, r.currentDirection = null, r.resolveConstraints(), r.visualElement.projection && (r.visualElement.projection.isAnimationBlocked = !0, r.visualElement.projection.target = void 0), Tt(function(b) {
|
|
3066
|
+
var g, P, w = r.getAxisMotionValue(b).get() || 0;
|
|
3067
3067
|
if (wt.test(w)) {
|
|
3068
|
-
var
|
|
3069
|
-
if (
|
|
3070
|
-
var
|
|
3071
|
-
w =
|
|
3068
|
+
var V = (P = (g = r.visualElement.projection) === null || g === void 0 ? void 0 : g.layout) === null || P === void 0 ? void 0 : P.actual[b];
|
|
3069
|
+
if (V) {
|
|
3070
|
+
var O = It(V);
|
|
3071
|
+
w = O * (parseFloat(w) / 100);
|
|
3072
3072
|
}
|
|
3073
3073
|
}
|
|
3074
3074
|
r.originPoint[b] = w;
|
|
3075
3075
|
}), m == null || m(f, d), (p = r.visualElement.animationState) === null || p === void 0 || p.setActive(U.Drag, !0));
|
|
3076
3076
|
}, l = function(f, d) {
|
|
3077
|
-
var p = r.getProps(), v = p.dragPropagation, h = p.dragDirectionLock,
|
|
3077
|
+
var p = r.getProps(), v = p.dragPropagation, h = p.dragDirectionLock, y = p.onDirectionLock, m = p.onDrag;
|
|
3078
3078
|
if (!(!v && !r.openGlobalLock)) {
|
|
3079
3079
|
var b = d.offset;
|
|
3080
3080
|
if (h && r.currentDirection === null) {
|
|
3081
|
-
r.currentDirection = jf(b), r.currentDirection !== null && (
|
|
3081
|
+
r.currentDirection = jf(b), r.currentDirection !== null && (y == null || y(r.currentDirection));
|
|
3082
3082
|
return;
|
|
3083
3083
|
}
|
|
3084
3084
|
r.updateAxis("x", d.point, b), r.updateAxis("y", d.point, b), r.visualElement.syncRender(), m == null || m(f, d);
|
|
@@ -3138,14 +3138,14 @@ var Lf = /* @__PURE__ */ new WeakMap(), Nf = (
|
|
|
3138
3138
|
if (Le(d, o, n.currentDirection)) {
|
|
3139
3139
|
var v = (p = c == null ? void 0 : c[d]) !== null && p !== void 0 ? p : {};
|
|
3140
3140
|
u && (v = { min: 0, max: 0 });
|
|
3141
|
-
var h = i ? 200 : 1e6,
|
|
3141
|
+
var h = i ? 200 : 1e6, y = i ? 40 : 1e7, m = x(x({ type: "inertia", velocity: a ? e[d] : 0, bounceStiffness: h, bounceDamping: y, timeConstant: 750, restDelta: 1, restSpeed: 10 }, s), v);
|
|
3142
3142
|
return n.startAxisValueAnimation(d, m);
|
|
3143
3143
|
}
|
|
3144
3144
|
});
|
|
3145
3145
|
return Promise.all(f).then(l);
|
|
3146
3146
|
}, t.prototype.startAxisValueAnimation = function(e, n) {
|
|
3147
3147
|
var r = this.getAxisMotionValue(e);
|
|
3148
|
-
return
|
|
3148
|
+
return hr(e, r, 0, n);
|
|
3149
3149
|
}, t.prototype.stopAnimation = function() {
|
|
3150
3150
|
var e = this;
|
|
3151
3151
|
Tt(function(n) {
|
|
@@ -3162,7 +3162,7 @@ var Lf = /* @__PURE__ */ new WeakMap(), Nf = (
|
|
|
3162
3162
|
var a = n.visualElement.projection, i = n.getAxisMotionValue(r);
|
|
3163
3163
|
if (a && a.layout) {
|
|
3164
3164
|
var s = a.layout.actual[r], u = s.min, l = s.max;
|
|
3165
|
-
i.set(e[r] -
|
|
3165
|
+
i.set(e[r] - tt(u, l, 0.5));
|
|
3166
3166
|
}
|
|
3167
3167
|
}
|
|
3168
3168
|
});
|
|
@@ -3182,7 +3182,7 @@ var Lf = /* @__PURE__ */ new WeakMap(), Nf = (
|
|
|
3182
3182
|
this.visualElement.getInstance().style.transform = u ? u({}, "") : "none", (n = i.root) === null || n === void 0 || n.updateScroll(), i.updateLayout(), this.resolveConstraints(), Tt(function(l) {
|
|
3183
3183
|
if (Le(l, o, null)) {
|
|
3184
3184
|
var c = e.getAxisMotionValue(l), f = e.constraints[l], d = f.min, p = f.max;
|
|
3185
|
-
c.set(
|
|
3185
|
+
c.set(tt(d, p, s[l]));
|
|
3186
3186
|
}
|
|
3187
3187
|
});
|
|
3188
3188
|
}
|
|
@@ -3234,7 +3234,7 @@ function Df(t) {
|
|
|
3234
3234
|
}, [r]);
|
|
3235
3235
|
}
|
|
3236
3236
|
function Bf(t) {
|
|
3237
|
-
var e = t.onPan, n = t.onPanStart, r = t.onPanEnd, o = t.onPanSessionStart, a = t.visualElement, i = e || n || r || o, s = Q(null), u = st(
|
|
3237
|
+
var e = t.onPan, n = t.onPanStart, r = t.onPanEnd, o = t.onPanSessionStart, a = t.visualElement, i = e || n || r || o, s = Q(null), u = st(Qn).transformPagePoint, l = {
|
|
3238
3238
|
onSessionStart: o,
|
|
3239
3239
|
onStart: n,
|
|
3240
3240
|
onMove: e,
|
|
@@ -3293,7 +3293,7 @@ function Ff() {
|
|
|
3293
3293
|
}, n["notify" + Ne[o]] = function() {
|
|
3294
3294
|
for (var a = [], i = 0; i < arguments.length; i++)
|
|
3295
3295
|
a[i] = arguments[i];
|
|
3296
|
-
return r.notify.apply(r, ht([],
|
|
3296
|
+
return r.notify.apply(r, ht([], nt(a), !1));
|
|
3297
3297
|
};
|
|
3298
3298
|
}), n;
|
|
3299
3299
|
}
|
|
@@ -3319,22 +3319,22 @@ function Hf(t, e, n) {
|
|
|
3319
3319
|
var ga = function(t) {
|
|
3320
3320
|
var e = t.treeType, n = e === void 0 ? "" : e, r = t.build, o = t.getBaseTarget, a = t.makeTargetAnimatable, i = t.measureViewportBox, s = t.render, u = t.readValueFromInstance, l = t.removeValueFromRenderState, c = t.sortNodePosition, f = t.scrapeMotionValuesFromProps;
|
|
3321
3321
|
return function(d, p) {
|
|
3322
|
-
var v = d.parent, h = d.props,
|
|
3322
|
+
var v = d.parent, h = d.props, y = d.presenceId, m = d.blockInitialAnimation, b = d.visualState, g = d.shouldReduceMotion;
|
|
3323
3323
|
p === void 0 && (p = {});
|
|
3324
|
-
var P = !1, w = b.latestValues,
|
|
3325
|
-
function
|
|
3326
|
-
!
|
|
3324
|
+
var P = !1, w = b.latestValues, V = b.renderState, O, j = Ff(), A = /* @__PURE__ */ new Map(), k = /* @__PURE__ */ new Map(), _ = {}, W = x({}, w), H;
|
|
3325
|
+
function R() {
|
|
3326
|
+
!O || !P || (Y(), s(O, V, h.style, D.projection));
|
|
3327
3327
|
}
|
|
3328
|
-
function
|
|
3329
|
-
r(D,
|
|
3328
|
+
function Y() {
|
|
3329
|
+
r(D, V, w, p, h);
|
|
3330
3330
|
}
|
|
3331
|
-
function
|
|
3331
|
+
function $() {
|
|
3332
3332
|
j.notifyUpdate(w);
|
|
3333
3333
|
}
|
|
3334
|
-
function I(T,
|
|
3335
|
-
var N =
|
|
3336
|
-
w[T] = B, h.onUpdate && Vt.update(
|
|
3337
|
-
}), L =
|
|
3334
|
+
function I(T, E) {
|
|
3335
|
+
var N = E.onChange(function(B) {
|
|
3336
|
+
w[T] = B, h.onUpdate && Vt.update($, !1, !0);
|
|
3337
|
+
}), L = E.onRenderRequest(D.scheduleRender);
|
|
3338
3338
|
k.set(T, function() {
|
|
3339
3339
|
N(), L();
|
|
3340
3340
|
});
|
|
@@ -3344,7 +3344,7 @@ var ga = function(t) {
|
|
|
3344
3344
|
var ut = it[at];
|
|
3345
3345
|
w[at] !== void 0 && Rt(ut) && ut.set(w[at], !1);
|
|
3346
3346
|
}
|
|
3347
|
-
var
|
|
3347
|
+
var q = tn(h), J = ii(h), D = x(x({
|
|
3348
3348
|
treeType: n,
|
|
3349
3349
|
/**
|
|
3350
3350
|
* This is a mirror of the internal instance prop, which keeps
|
|
@@ -3360,8 +3360,8 @@ var ga = function(t) {
|
|
|
3360
3360
|
/**
|
|
3361
3361
|
*
|
|
3362
3362
|
*/
|
|
3363
|
-
presenceId:
|
|
3364
|
-
shouldReduceMotion:
|
|
3363
|
+
presenceId: y,
|
|
3364
|
+
shouldReduceMotion: g,
|
|
3365
3365
|
/**
|
|
3366
3366
|
* If this component is part of the variant tree, it should track
|
|
3367
3367
|
* any children that are also part of the tree. This is essentially
|
|
@@ -3395,11 +3395,11 @@ var ga = function(t) {
|
|
|
3395
3395
|
* own animations on mount.
|
|
3396
3396
|
*/
|
|
3397
3397
|
isMounted: function() {
|
|
3398
|
-
return !!
|
|
3398
|
+
return !!O;
|
|
3399
3399
|
},
|
|
3400
3400
|
mount: function(T) {
|
|
3401
|
-
P = !0,
|
|
3402
|
-
return I(N,
|
|
3401
|
+
P = !0, O = D.current = T, D.projection && D.projection.mount(T), J && v && !q && (H = v == null ? void 0 : v.addVariantChild(D)), A.forEach(function(E, N) {
|
|
3402
|
+
return I(N, E);
|
|
3403
3403
|
}), v == null || v.children.add(D), D.setProps(h);
|
|
3404
3404
|
},
|
|
3405
3405
|
/**
|
|
@@ -3407,17 +3407,17 @@ var ga = function(t) {
|
|
|
3407
3407
|
*/
|
|
3408
3408
|
unmount: function() {
|
|
3409
3409
|
var T;
|
|
3410
|
-
(T = D.projection) === null || T === void 0 || T.unmount(), Qt.update(
|
|
3411
|
-
return
|
|
3412
|
-
}), H == null || H(), v == null || v.children.delete(D), j.clearAllListeners(),
|
|
3410
|
+
(T = D.projection) === null || T === void 0 || T.unmount(), Qt.update($), Qt.render(R), k.forEach(function(E) {
|
|
3411
|
+
return E();
|
|
3412
|
+
}), H == null || H(), v == null || v.children.delete(D), j.clearAllListeners(), O = void 0, P = !1;
|
|
3413
3413
|
},
|
|
3414
3414
|
/**
|
|
3415
3415
|
* Add a child visual element to our set of children.
|
|
3416
3416
|
*/
|
|
3417
3417
|
addVariantChild: function(T) {
|
|
3418
|
-
var
|
|
3418
|
+
var E, N = D.getClosestVariantNode();
|
|
3419
3419
|
if (N)
|
|
3420
|
-
return (
|
|
3420
|
+
return (E = N.variantChildren) === null || E === void 0 || E.add(T), function() {
|
|
3421
3421
|
return N.variantChildren.delete(T);
|
|
3422
3422
|
};
|
|
3423
3423
|
},
|
|
@@ -3441,7 +3441,7 @@ var ga = function(t) {
|
|
|
3441
3441
|
* Returns the current instance.
|
|
3442
3442
|
*/
|
|
3443
3443
|
getInstance: function() {
|
|
3444
|
-
return
|
|
3444
|
+
return O;
|
|
3445
3445
|
},
|
|
3446
3446
|
/**
|
|
3447
3447
|
* Get/set the latest static values.
|
|
@@ -3449,8 +3449,8 @@ var ga = function(t) {
|
|
|
3449
3449
|
getStaticValue: function(T) {
|
|
3450
3450
|
return w[T];
|
|
3451
3451
|
},
|
|
3452
|
-
setStaticValue: function(T,
|
|
3453
|
-
return w[T] =
|
|
3452
|
+
setStaticValue: function(T, E) {
|
|
3453
|
+
return w[T] = E;
|
|
3454
3454
|
},
|
|
3455
3455
|
/**
|
|
3456
3456
|
* Returns the latest motion value state. Currently only used to take
|
|
@@ -3474,8 +3474,8 @@ var ga = function(t) {
|
|
|
3474
3474
|
* pluggable to support Framer's custom value types like Color,
|
|
3475
3475
|
* and CSS variables.
|
|
3476
3476
|
*/
|
|
3477
|
-
makeTargetAnimatable: function(T,
|
|
3478
|
-
return
|
|
3477
|
+
makeTargetAnimatable: function(T, E) {
|
|
3478
|
+
return E === void 0 && (E = !0), a(D, T, h, E);
|
|
3479
3479
|
},
|
|
3480
3480
|
/**
|
|
3481
3481
|
* Measure the current viewport box with or without transforms.
|
|
@@ -3483,41 +3483,41 @@ var ga = function(t) {
|
|
|
3483
3483
|
* removed with a re-render to work.
|
|
3484
3484
|
*/
|
|
3485
3485
|
measureViewportBox: function() {
|
|
3486
|
-
return i(
|
|
3486
|
+
return i(O, h);
|
|
3487
3487
|
},
|
|
3488
3488
|
// Motion values ========================
|
|
3489
3489
|
/**
|
|
3490
3490
|
* Add a motion value and bind it to this visual element.
|
|
3491
3491
|
*/
|
|
3492
|
-
addValue: function(T,
|
|
3493
|
-
D.hasValue(T) && D.removeValue(T),
|
|
3492
|
+
addValue: function(T, E) {
|
|
3493
|
+
D.hasValue(T) && D.removeValue(T), A.set(T, E), w[T] = E.get(), I(T, E);
|
|
3494
3494
|
},
|
|
3495
3495
|
/**
|
|
3496
3496
|
* Remove a motion value and unbind any active subscriptions.
|
|
3497
3497
|
*/
|
|
3498
3498
|
removeValue: function(T) {
|
|
3499
|
-
var
|
|
3500
|
-
|
|
3499
|
+
var E;
|
|
3500
|
+
A.delete(T), (E = k.get(T)) === null || E === void 0 || E(), k.delete(T), delete w[T], l(T, V);
|
|
3501
3501
|
},
|
|
3502
3502
|
/**
|
|
3503
3503
|
* Check whether we have a motion value for this key
|
|
3504
3504
|
*/
|
|
3505
3505
|
hasValue: function(T) {
|
|
3506
|
-
return
|
|
3506
|
+
return A.has(T);
|
|
3507
3507
|
},
|
|
3508
3508
|
/**
|
|
3509
3509
|
* Get a motion value for this key. If called with a default
|
|
3510
3510
|
* value, we'll create one if none exists.
|
|
3511
3511
|
*/
|
|
3512
|
-
getValue: function(T,
|
|
3513
|
-
var N =
|
|
3514
|
-
return N === void 0 &&
|
|
3512
|
+
getValue: function(T, E) {
|
|
3513
|
+
var N = A.get(T);
|
|
3514
|
+
return N === void 0 && E !== void 0 && (N = _t(E), D.addValue(T, N)), N;
|
|
3515
3515
|
},
|
|
3516
3516
|
/**
|
|
3517
3517
|
* Iterate over our motion values.
|
|
3518
3518
|
*/
|
|
3519
3519
|
forEachValue: function(T) {
|
|
3520
|
-
return
|
|
3520
|
+
return A.forEach(T);
|
|
3521
3521
|
},
|
|
3522
3522
|
/**
|
|
3523
3523
|
* If we're trying to animate to a previously unencountered value,
|
|
@@ -3525,15 +3525,15 @@ var ga = function(t) {
|
|
|
3525
3525
|
* directly from the instance (which might have performance implications).
|
|
3526
3526
|
*/
|
|
3527
3527
|
readValue: function(T) {
|
|
3528
|
-
var
|
|
3529
|
-
return (
|
|
3528
|
+
var E;
|
|
3529
|
+
return (E = w[T]) !== null && E !== void 0 ? E : u(O, T, p);
|
|
3530
3530
|
},
|
|
3531
3531
|
/**
|
|
3532
3532
|
* Set the base target to later animate back to. This is currently
|
|
3533
3533
|
* only hydrated on creation and when we first read a value.
|
|
3534
3534
|
*/
|
|
3535
|
-
setBaseTarget: function(T,
|
|
3536
|
-
|
|
3535
|
+
setBaseTarget: function(T, E) {
|
|
3536
|
+
W[T] = E;
|
|
3537
3537
|
},
|
|
3538
3538
|
/**
|
|
3539
3539
|
* Find the base target for a value thats been removed from all animation
|
|
@@ -3541,24 +3541,24 @@ var ga = function(t) {
|
|
|
3541
3541
|
*/
|
|
3542
3542
|
getBaseTarget: function(T) {
|
|
3543
3543
|
if (o) {
|
|
3544
|
-
var
|
|
3545
|
-
if (
|
|
3546
|
-
return
|
|
3544
|
+
var E = o(h, T);
|
|
3545
|
+
if (E !== void 0 && !Rt(E))
|
|
3546
|
+
return E;
|
|
3547
3547
|
}
|
|
3548
|
-
return
|
|
3548
|
+
return W[T];
|
|
3549
3549
|
}
|
|
3550
3550
|
}, j), {
|
|
3551
3551
|
/**
|
|
3552
3552
|
* Build the renderer state based on the latest visual state.
|
|
3553
3553
|
*/
|
|
3554
3554
|
build: function() {
|
|
3555
|
-
return
|
|
3555
|
+
return Y(), V;
|
|
3556
3556
|
},
|
|
3557
3557
|
/**
|
|
3558
3558
|
* Schedule a render on the next animation frame.
|
|
3559
3559
|
*/
|
|
3560
3560
|
scheduleRender: function() {
|
|
3561
|
-
Vt.render(
|
|
3561
|
+
Vt.render(R, !1, !0);
|
|
3562
3562
|
},
|
|
3563
3563
|
/**
|
|
3564
3564
|
* Synchronously fire render. It's prefered that we batch renders but
|
|
@@ -3566,13 +3566,13 @@ var ga = function(t) {
|
|
|
3566
3566
|
* synchronously. However in those instances other measures should be taken
|
|
3567
3567
|
* to batch reads/writes.
|
|
3568
3568
|
*/
|
|
3569
|
-
syncRender:
|
|
3569
|
+
syncRender: R,
|
|
3570
3570
|
/**
|
|
3571
3571
|
* Update the provided props. Ensure any newly-added motion values are
|
|
3572
3572
|
* added to our map, old ones removed, and listeners updated.
|
|
3573
3573
|
*/
|
|
3574
3574
|
setProps: function(T) {
|
|
3575
|
-
(T.transformTemplate || h.transformTemplate) && D.scheduleRender(), h = T, j.updatePropListeners(T),
|
|
3575
|
+
(T.transformTemplate || h.transformTemplate) && D.scheduleRender(), h = T, j.updatePropListeners(T), _ = Hf(D, f(h), _);
|
|
3576
3576
|
},
|
|
3577
3577
|
getProps: function() {
|
|
3578
3578
|
return h;
|
|
@@ -3582,8 +3582,8 @@ var ga = function(t) {
|
|
|
3582
3582
|
* Returns the variant definition with a given name.
|
|
3583
3583
|
*/
|
|
3584
3584
|
getVariant: function(T) {
|
|
3585
|
-
var
|
|
3586
|
-
return (
|
|
3585
|
+
var E;
|
|
3586
|
+
return (E = h.variants) === null || E === void 0 ? void 0 : E[T];
|
|
3587
3587
|
},
|
|
3588
3588
|
/**
|
|
3589
3589
|
* Returns the defined default transition on this component.
|
|
@@ -3600,9 +3600,9 @@ var ga = function(t) {
|
|
|
3600
3600
|
getVariantContext: function(T) {
|
|
3601
3601
|
if (T === void 0 && (T = !1), T)
|
|
3602
3602
|
return v == null ? void 0 : v.getVariantContext();
|
|
3603
|
-
if (!
|
|
3604
|
-
var
|
|
3605
|
-
return h.initial !== void 0 && (
|
|
3603
|
+
if (!q) {
|
|
3604
|
+
var E = (v == null ? void 0 : v.getVariantContext()) || {};
|
|
3605
|
+
return h.initial !== void 0 && (E.initial = h.initial), E;
|
|
3606
3606
|
}
|
|
3607
3607
|
for (var N = {}, L = 0; L < Wf; L++) {
|
|
3608
3608
|
var B = ya[L], G = h[B];
|
|
@@ -3613,7 +3613,7 @@ var ga = function(t) {
|
|
|
3613
3613
|
});
|
|
3614
3614
|
return D;
|
|
3615
3615
|
};
|
|
3616
|
-
}, ya = ht(["initial"],
|
|
3616
|
+
}, ya = ht(["initial"], nt(Sr), !1), Wf = ya.length;
|
|
3617
3617
|
function Xn(t) {
|
|
3618
3618
|
return typeof t == "string" && t.startsWith("var(--");
|
|
3619
3619
|
}
|
|
@@ -3622,13 +3622,13 @@ function qf(t) {
|
|
|
3622
3622
|
var e = Sa.exec(t);
|
|
3623
3623
|
if (!e)
|
|
3624
3624
|
return [,];
|
|
3625
|
-
var n =
|
|
3625
|
+
var n = nt(e, 3), r = n[1], o = n[2];
|
|
3626
3626
|
return [r, o];
|
|
3627
3627
|
}
|
|
3628
3628
|
var Gf = 4;
|
|
3629
3629
|
function Zn(t, e, n) {
|
|
3630
3630
|
n === void 0 && (n = 1), vt(n <= Gf, 'Max CSS variable fallback depth detected in property "'.concat(t, '". This may indicate a circular fallback dependency.'));
|
|
3631
|
-
var r =
|
|
3631
|
+
var r = nt(qf(t), 2), o = r[0], a = r[1];
|
|
3632
3632
|
if (o) {
|
|
3633
3633
|
var i = window.getComputedStyle(e).getPropertyValue(o);
|
|
3634
3634
|
return i ? i.trim() : Xn(a) ? Zn(a, e, n + 1) : a;
|
|
@@ -3670,23 +3670,23 @@ var Uf = /* @__PURE__ */ new Set([
|
|
|
3670
3670
|
}, xa = function(t, e) {
|
|
3671
3671
|
t.set(e, !1), t.set(e);
|
|
3672
3672
|
}, je = function(t) {
|
|
3673
|
-
return t === zt || t ===
|
|
3674
|
-
},
|
|
3673
|
+
return t === zt || t === M;
|
|
3674
|
+
}, xo;
|
|
3675
3675
|
(function(t) {
|
|
3676
3676
|
t.width = "width", t.height = "height", t.left = "left", t.right = "right", t.top = "top", t.bottom = "bottom";
|
|
3677
|
-
})(
|
|
3678
|
-
var
|
|
3677
|
+
})(xo || (xo = {}));
|
|
3678
|
+
var Po = function(t, e) {
|
|
3679
3679
|
return parseFloat(t.split(", ")[e]);
|
|
3680
|
-
},
|
|
3680
|
+
}, To = function(t, e) {
|
|
3681
3681
|
return function(n, r) {
|
|
3682
3682
|
var o = r.transform;
|
|
3683
3683
|
if (o === "none" || !o)
|
|
3684
3684
|
return 0;
|
|
3685
3685
|
var a = o.match(/^matrix3d\((.+)\)$/);
|
|
3686
3686
|
if (a)
|
|
3687
|
-
return
|
|
3687
|
+
return Po(a[1], e);
|
|
3688
3688
|
var i = o.match(/^matrix\((.+)\)$/);
|
|
3689
|
-
return i ?
|
|
3689
|
+
return i ? Po(i[1], t) : 0;
|
|
3690
3690
|
};
|
|
3691
3691
|
}, Xf = /* @__PURE__ */ new Set(["x", "y", "z"]), Zf = he.filter(function(t) {
|
|
3692
3692
|
return !Xf.has(t);
|
|
@@ -3698,7 +3698,7 @@ function Kf(t) {
|
|
|
3698
3698
|
r !== void 0 && (e.push([n, r.get()]), r.set(n.startsWith("scale") ? 1 : 0));
|
|
3699
3699
|
}), e.length && t.syncRender(), e;
|
|
3700
3700
|
}
|
|
3701
|
-
var
|
|
3701
|
+
var wo = {
|
|
3702
3702
|
// Dimensions
|
|
3703
3703
|
width: function(t, e) {
|
|
3704
3704
|
var n = t.x, r = e.paddingLeft, o = r === void 0 ? "0" : r, a = e.paddingRight, i = a === void 0 ? "0" : a;
|
|
@@ -3725,17 +3725,17 @@ var To = {
|
|
|
3725
3725
|
return parseFloat(r) + (n.max - n.min);
|
|
3726
3726
|
},
|
|
3727
3727
|
// Transform
|
|
3728
|
-
x:
|
|
3729
|
-
y:
|
|
3728
|
+
x: To(4, 13),
|
|
3729
|
+
y: To(5, 14)
|
|
3730
3730
|
}, Jf = function(t, e, n) {
|
|
3731
3731
|
var r = e.measureViewportBox(), o = e.getInstance(), a = getComputedStyle(o), i = a.display, s = {};
|
|
3732
3732
|
i === "none" && e.setStaticValue("display", t.display || "block"), n.forEach(function(l) {
|
|
3733
|
-
s[l] =
|
|
3733
|
+
s[l] = wo[l](r, a);
|
|
3734
3734
|
}), e.syncRender();
|
|
3735
3735
|
var u = e.measureViewportBox();
|
|
3736
3736
|
return n.forEach(function(l) {
|
|
3737
3737
|
var c = e.getValue(l);
|
|
3738
|
-
xa(c, s[l]), t[l] =
|
|
3738
|
+
xa(c, s[l]), t[l] = wo[l](u, a);
|
|
3739
3739
|
}), t;
|
|
3740
3740
|
}, Qf = function(t, e, n, r) {
|
|
3741
3741
|
n === void 0 && (n = {}), r === void 0 && (r = {}), e = x({}, e), r = x({}, r);
|
|
@@ -3745,22 +3745,22 @@ var To = {
|
|
|
3745
3745
|
if (t.hasValue(c)) {
|
|
3746
3746
|
var d = n[c], p = re(d), v = e[c], h;
|
|
3747
3747
|
if (ge(v)) {
|
|
3748
|
-
var
|
|
3748
|
+
var y = v.length, m = v[0] === null ? 1 : 0;
|
|
3749
3749
|
d = v[m], p = re(d);
|
|
3750
|
-
for (var b = m; b <
|
|
3750
|
+
for (var b = m; b < y; b++)
|
|
3751
3751
|
h ? vt(re(v[b]) === h, "All keyframes must be of the same type") : (h = re(v[b]), vt(h === p || je(p) && je(h), "Keyframes must be of the same dimension as the current value"));
|
|
3752
3752
|
} else
|
|
3753
3753
|
h = re(v);
|
|
3754
3754
|
if (p !== h)
|
|
3755
3755
|
if (je(p) && je(h)) {
|
|
3756
|
-
var
|
|
3757
|
-
typeof
|
|
3756
|
+
var g = f.get();
|
|
3757
|
+
typeof g == "string" && f.set(parseFloat(g)), typeof v == "string" ? e[c] = parseFloat(v) : Array.isArray(v) && h === M && (e[c] = v.map(parseFloat));
|
|
3758
3758
|
} else p != null && p.transform && (h != null && h.transform) && (d === 0 || v === 0) ? d === 0 ? f.set(h.transform(d)) : e[c] = p.transform(v) : (i || (a = Kf(t), i = !0), s.push(c), r[c] = r[c] !== void 0 ? r[c] : e[c], xa(f, v));
|
|
3759
3759
|
}
|
|
3760
3760
|
}), s.length) {
|
|
3761
3761
|
var u = s.indexOf("height") >= 0 ? window.pageYOffset : null, l = Jf(e, t, s);
|
|
3762
3762
|
return a.length && a.forEach(function(c) {
|
|
3763
|
-
var f =
|
|
3763
|
+
var f = nt(c, 2), d = f[0], p = f[1];
|
|
3764
3764
|
t.getValue(d).set(p);
|
|
3765
3765
|
}), t.syncRender(), u !== null && window.scrollTo({ top: u }), { target: l, transitionEnd: r };
|
|
3766
3766
|
} else
|
|
@@ -3780,7 +3780,7 @@ var Pa = {
|
|
|
3780
3780
|
treeType: "dom",
|
|
3781
3781
|
readValueFromInstance: function(t, e) {
|
|
3782
3782
|
if (Pe(e)) {
|
|
3783
|
-
var n =
|
|
3783
|
+
var n = dr(e);
|
|
3784
3784
|
return n && n.default || 0;
|
|
3785
3785
|
} else {
|
|
3786
3786
|
var r = td(t);
|
|
@@ -3831,22 +3831,22 @@ var Pa = {
|
|
|
3831
3831
|
}
|
|
3832
3832
|
return x({ transition: a, transitionEnd: i }, s);
|
|
3833
3833
|
},
|
|
3834
|
-
scrapeMotionValuesFromProps:
|
|
3834
|
+
scrapeMotionValuesFromProps: rr,
|
|
3835
3835
|
build: function(t, e, n, r, o) {
|
|
3836
|
-
t.isVisible !== void 0 && (e.style.visibility = t.isVisible ? "visible" : "hidden"),
|
|
3836
|
+
t.isVisible !== void 0 && (e.style.visibility = t.isVisible ? "visible" : "hidden"), tr(e, n, r, o.transformTemplate);
|
|
3837
3837
|
},
|
|
3838
3838
|
render: Ti
|
|
3839
3839
|
}, ed = ga(Pa), nd = ga(x(x({}, Pa), { getBaseTarget: function(t, e) {
|
|
3840
3840
|
return t[e];
|
|
3841
3841
|
}, readValueFromInstance: function(t, e) {
|
|
3842
3842
|
var n;
|
|
3843
|
-
return Pe(e) ? ((n =
|
|
3843
|
+
return Pe(e) ? ((n = dr(e)) === null || n === void 0 ? void 0 : n.default) || 0 : (e = wi.has(e) ? e : Pi(e), t.getAttribute(e));
|
|
3844
3844
|
}, scrapeMotionValuesFromProps: Ei, build: function(t, e, n, r, o) {
|
|
3845
|
-
|
|
3845
|
+
nr(e, n, r, o.transformTemplate);
|
|
3846
3846
|
}, render: Vi })), rd = function(t, e) {
|
|
3847
|
-
return
|
|
3847
|
+
return _n(t) ? nd(e, { enableHardwareAcceleration: !1 }) : ed(e, { enableHardwareAcceleration: !0 });
|
|
3848
3848
|
};
|
|
3849
|
-
function
|
|
3849
|
+
function Vo(t, e) {
|
|
3850
3850
|
return e.max === e.min ? 0 : t / (e.max - e.min) * 100;
|
|
3851
3851
|
}
|
|
3852
3852
|
var oe = {
|
|
@@ -3854,30 +3854,30 @@ var oe = {
|
|
|
3854
3854
|
if (!e.target)
|
|
3855
3855
|
return t;
|
|
3856
3856
|
if (typeof t == "string")
|
|
3857
|
-
if (
|
|
3857
|
+
if (M.test(t))
|
|
3858
3858
|
t = parseFloat(t);
|
|
3859
3859
|
else
|
|
3860
3860
|
return t;
|
|
3861
|
-
var n =
|
|
3861
|
+
var n = Vo(t, e.target.x), r = Vo(t, e.target.y);
|
|
3862
3862
|
return "".concat(n, "% ").concat(r, "%");
|
|
3863
3863
|
}
|
|
3864
|
-
},
|
|
3864
|
+
}, Eo = "_$css", od = {
|
|
3865
3865
|
correct: function(t, e) {
|
|
3866
3866
|
var n = e.treeScale, r = e.projectionDelta, o = t, a = t.includes("var("), i = [];
|
|
3867
3867
|
a && (t = t.replace(Sa, function(h) {
|
|
3868
|
-
return i.push(h),
|
|
3868
|
+
return i.push(h), Eo;
|
|
3869
3869
|
}));
|
|
3870
3870
|
var s = Mt.parse(t);
|
|
3871
3871
|
if (s.length > 5)
|
|
3872
3872
|
return o;
|
|
3873
3873
|
var u = Mt.createTransformer(t), l = typeof s[0] != "number" ? 1 : 0, c = r.x.scale * n.x, f = r.y.scale * n.y;
|
|
3874
3874
|
s[0 + l] /= c, s[1 + l] /= f;
|
|
3875
|
-
var d =
|
|
3875
|
+
var d = tt(c, f, 0.5);
|
|
3876
3876
|
typeof s[2 + l] == "number" && (s[2 + l] /= d), typeof s[3 + l] == "number" && (s[3 + l] /= d);
|
|
3877
3877
|
var p = u(s);
|
|
3878
3878
|
if (a) {
|
|
3879
3879
|
var v = 0;
|
|
3880
|
-
p = p.replace(
|
|
3880
|
+
p = p.replace(Eo, function() {
|
|
3881
3881
|
var h = i[v];
|
|
3882
3882
|
return v++, h;
|
|
3883
3883
|
});
|
|
@@ -3919,7 +3919,7 @@ var oe = {
|
|
|
3919
3919
|
}(C.Component)
|
|
3920
3920
|
);
|
|
3921
3921
|
function ad(t) {
|
|
3922
|
-
var e =
|
|
3922
|
+
var e = nt(ia(), 2), n = e[0], r = e[1], o = st(ai);
|
|
3923
3923
|
return C.createElement(id, x({}, t, { layoutGroup: o, switchLayoutGroup: st(si), isPresent: n, safeToRemove: r }));
|
|
3924
3924
|
}
|
|
3925
3925
|
var sd = {
|
|
@@ -3940,7 +3940,7 @@ var sd = {
|
|
|
3940
3940
|
function ld(t, e, n) {
|
|
3941
3941
|
n === void 0 && (n = {});
|
|
3942
3942
|
var r = Rt(t) ? t : _t(t);
|
|
3943
|
-
return
|
|
3943
|
+
return hr("", r, e, n), {
|
|
3944
3944
|
stop: function() {
|
|
3945
3945
|
return r.stop();
|
|
3946
3946
|
},
|
|
@@ -3949,73 +3949,73 @@ function ld(t, e, n) {
|
|
|
3949
3949
|
}
|
|
3950
3950
|
};
|
|
3951
3951
|
}
|
|
3952
|
-
var Ta = ["TopLeft", "TopRight", "BottomLeft", "BottomRight"], cd = Ta.length,
|
|
3952
|
+
var Ta = ["TopLeft", "TopRight", "BottomLeft", "BottomRight"], cd = Ta.length, Co = function(t) {
|
|
3953
3953
|
return typeof t == "string" ? parseFloat(t) : t;
|
|
3954
|
-
},
|
|
3955
|
-
return typeof t == "number" ||
|
|
3954
|
+
}, Ao = function(t) {
|
|
3955
|
+
return typeof t == "number" || M.test(t);
|
|
3956
3956
|
};
|
|
3957
3957
|
function fd(t, e, n, r, o, a) {
|
|
3958
3958
|
var i, s, u, l;
|
|
3959
|
-
o ? (t.opacity =
|
|
3959
|
+
o ? (t.opacity = tt(
|
|
3960
3960
|
0,
|
|
3961
3961
|
// (follow?.opacity as number) ?? 0,
|
|
3962
3962
|
// TODO Reinstate this if only child
|
|
3963
3963
|
(i = n.opacity) !== null && i !== void 0 ? i : 1,
|
|
3964
3964
|
dd(r)
|
|
3965
|
-
), t.opacityExit =
|
|
3965
|
+
), t.opacityExit = tt((s = e.opacity) !== null && s !== void 0 ? s : 1, 0, vd(r))) : a && (t.opacity = tt((u = e.opacity) !== null && u !== void 0 ? u : 1, (l = n.opacity) !== null && l !== void 0 ? l : 1, r));
|
|
3966
3966
|
for (var c = 0; c < cd; c++) {
|
|
3967
|
-
var f = "border".concat(Ta[c], "Radius"), d =
|
|
3967
|
+
var f = "border".concat(Ta[c], "Radius"), d = Ro(e, f), p = Ro(n, f);
|
|
3968
3968
|
if (!(d === void 0 && p === void 0)) {
|
|
3969
3969
|
d || (d = 0), p || (p = 0);
|
|
3970
|
-
var v = d === 0 || p === 0 ||
|
|
3971
|
-
v ? (t[f] = Math.max(
|
|
3970
|
+
var v = d === 0 || p === 0 || Ao(d) === Ao(p);
|
|
3971
|
+
v ? (t[f] = Math.max(tt(Co(d), Co(p), r), 0), (wt.test(p) || wt.test(d)) && (t[f] += "%")) : t[f] = p;
|
|
3972
3972
|
}
|
|
3973
3973
|
}
|
|
3974
|
-
(e.rotate || n.rotate) && (t.rotate =
|
|
3974
|
+
(e.rotate || n.rotate) && (t.rotate = tt(e.rotate || 0, n.rotate || 0, r));
|
|
3975
3975
|
}
|
|
3976
|
-
function
|
|
3976
|
+
function Ro(t, e) {
|
|
3977
3977
|
var n;
|
|
3978
3978
|
return (n = t[e]) !== null && n !== void 0 ? n : t.borderRadius;
|
|
3979
3979
|
}
|
|
3980
|
-
var dd = wa(0, 0.5,
|
|
3980
|
+
var dd = wa(0, 0.5, cr), vd = wa(0.5, 0.95, ur);
|
|
3981
3981
|
function wa(t, e, n) {
|
|
3982
3982
|
return function(r) {
|
|
3983
3983
|
return r < t ? 0 : r > e ? 1 : n(ye(t, e, r));
|
|
3984
3984
|
};
|
|
3985
3985
|
}
|
|
3986
|
-
function
|
|
3986
|
+
function Mo(t, e) {
|
|
3987
3987
|
t.min = e.min, t.max = e.max;
|
|
3988
3988
|
}
|
|
3989
3989
|
function St(t, e) {
|
|
3990
|
-
|
|
3990
|
+
Mo(t.x, e.x), Mo(t.y, e.y);
|
|
3991
3991
|
}
|
|
3992
|
-
function
|
|
3992
|
+
function Io(t, e, n, r, o) {
|
|
3993
3993
|
return t -= e, t = Ze(t, 1 / n, r), o !== void 0 && (t = Ze(t, 1 / o, r)), t;
|
|
3994
3994
|
}
|
|
3995
3995
|
function pd(t, e, n, r, o, a, i) {
|
|
3996
3996
|
if (e === void 0 && (e = 0), n === void 0 && (n = 1), r === void 0 && (r = 0.5), a === void 0 && (a = t), i === void 0 && (i = t), wt.test(e)) {
|
|
3997
3997
|
e = parseFloat(e);
|
|
3998
|
-
var s =
|
|
3998
|
+
var s = tt(i.min, i.max, e / 100);
|
|
3999
3999
|
e = s - i.min;
|
|
4000
4000
|
}
|
|
4001
4001
|
if (typeof e == "number") {
|
|
4002
|
-
var u =
|
|
4003
|
-
t === a && (u -= e), t.min =
|
|
4002
|
+
var u = tt(a.min, a.max, r);
|
|
4003
|
+
t === a && (u -= e), t.min = Io(t.min, e, n, u, o), t.max = Io(t.max, e, n, u, o);
|
|
4004
4004
|
}
|
|
4005
4005
|
}
|
|
4006
|
-
function
|
|
4007
|
-
var a =
|
|
4006
|
+
function Oo(t, e, n, r, o) {
|
|
4007
|
+
var a = nt(n, 3), i = a[0], s = a[1], u = a[2];
|
|
4008
4008
|
pd(t, e[i], e[s], e[u], e.scale, r, o);
|
|
4009
4009
|
}
|
|
4010
4010
|
var hd = ["x", "scaleX", "originX"], md = ["y", "scaleY", "originY"];
|
|
4011
|
-
function
|
|
4012
|
-
|
|
4011
|
+
function Lo(t, e, n, r) {
|
|
4012
|
+
Oo(t.x, e, hd, n == null ? void 0 : n.x, r == null ? void 0 : r.x), Oo(t.y, e, md, n == null ? void 0 : n.y, r == null ? void 0 : r.y);
|
|
4013
4013
|
}
|
|
4014
|
-
function
|
|
4014
|
+
function No(t) {
|
|
4015
4015
|
return t.translate === 0 && t.scale === 1;
|
|
4016
4016
|
}
|
|
4017
4017
|
function Va(t) {
|
|
4018
|
-
return
|
|
4018
|
+
return No(t.x) && No(t.y);
|
|
4019
4019
|
}
|
|
4020
4020
|
function Ea(t, e) {
|
|
4021
4021
|
return t.x.min === e.x.min && t.x.max === e.x.max && t.y.min === e.y.min && t.y.max === e.y.max;
|
|
@@ -4027,9 +4027,9 @@ var gd = (
|
|
|
4027
4027
|
this.members = [];
|
|
4028
4028
|
}
|
|
4029
4029
|
return t.prototype.add = function(e) {
|
|
4030
|
-
|
|
4030
|
+
mr(this.members, e), e.scheduleRender();
|
|
4031
4031
|
}, t.prototype.remove = function(e) {
|
|
4032
|
-
if (
|
|
4032
|
+
if (gr(this.members, e), e === this.prevLead && (this.prevLead = void 0), e === this.lead) {
|
|
4033
4033
|
var n = this.members[this.members.length - 1];
|
|
4034
4034
|
n && this.promote(n);
|
|
4035
4035
|
}
|
|
@@ -4068,7 +4068,7 @@ var gd = (
|
|
|
4068
4068
|
}, t;
|
|
4069
4069
|
}()
|
|
4070
4070
|
), yd = "translate3d(0px, 0px, 0) scale(1, 1) scale(1, 1)";
|
|
4071
|
-
function
|
|
4071
|
+
function jo(t, e, n) {
|
|
4072
4072
|
var r = t.x.translate / e.x, o = t.y.translate / e.y, a = "translate3d(".concat(r, "px, ").concat(o, "px, 0) ");
|
|
4073
4073
|
if (a += "scale(".concat(1 / e.x, ", ").concat(1 / e.y, ") "), n) {
|
|
4074
4074
|
var i = n.rotate, s = n.rotateX, u = n.rotateY;
|
|
@@ -4086,14 +4086,14 @@ var Sd = function(t, e) {
|
|
|
4086
4086
|
this.children = [], this.isDirty = !1;
|
|
4087
4087
|
}
|
|
4088
4088
|
return t.prototype.add = function(e) {
|
|
4089
|
-
hr(this.children, e), this.isDirty = !0;
|
|
4090
|
-
}, t.prototype.remove = function(e) {
|
|
4091
4089
|
mr(this.children, e), this.isDirty = !0;
|
|
4090
|
+
}, t.prototype.remove = function(e) {
|
|
4091
|
+
gr(this.children, e), this.isDirty = !0;
|
|
4092
4092
|
}, t.prototype.forEach = function(e) {
|
|
4093
4093
|
this.isDirty && this.children.sort(Sd), this.isDirty = !1, this.children.forEach(e);
|
|
4094
4094
|
}, t;
|
|
4095
4095
|
}()
|
|
4096
|
-
),
|
|
4096
|
+
), Do = 1e3;
|
|
4097
4097
|
function Ca(t) {
|
|
4098
4098
|
var e = t.attachResizeListener, n = t.defaultParent, r = t.measureScroll, o = t.checkIsScrollRoot, a = t.resetTransform;
|
|
4099
4099
|
return (
|
|
@@ -4105,7 +4105,7 @@ function Ca(t) {
|
|
|
4105
4105
|
c.isUpdating && (c.isUpdating = !1, c.clearAllSnapshots());
|
|
4106
4106
|
}, this.updateProjection = function() {
|
|
4107
4107
|
c.nodes.forEach(Ed), c.nodes.forEach(Cd);
|
|
4108
|
-
}, this.hasProjected = !1, this.isVisible = !0, this.animationProgress = 0, this.sharedNodes = /* @__PURE__ */ new Map(), this.id = s, this.latestValues = u, this.root = l ? l.root || l : this, this.path = l ? ht(ht([],
|
|
4108
|
+
}, this.hasProjected = !1, this.isVisible = !0, this.animationProgress = 0, this.sharedNodes = /* @__PURE__ */ new Map(), this.id = s, this.latestValues = u, this.root = l ? l.root || l : this, this.path = l ? ht(ht([], nt(l.path), !1), [l], !1) : [], this.parent = l, this.depth = l ? l.depth + 1 : 0, s && this.root.registerPotentialNode(s, this);
|
|
4109
4109
|
for (var f = 0; f < this.path.length; f++)
|
|
4110
4110
|
this.path[f].shouldResetTransform = !0;
|
|
4111
4111
|
this.root === this && (this.nodes = new bd());
|
|
@@ -4116,7 +4116,7 @@ function Ca(t) {
|
|
|
4116
4116
|
for (var u = [], l = 1; l < arguments.length; l++)
|
|
4117
4117
|
u[l - 1] = arguments[l];
|
|
4118
4118
|
var c = this.eventHandlers.get(s);
|
|
4119
|
-
c == null || c.notify.apply(c, ht([],
|
|
4119
|
+
c == null || c.notify.apply(c, ht([], nt(u), !1));
|
|
4120
4120
|
}, i.prototype.hasListeners = function(s) {
|
|
4121
4121
|
return this.eventHandlers.has(s);
|
|
4122
4122
|
}, i.prototype.registerPotentialNode = function(s, u) {
|
|
@@ -4127,26 +4127,26 @@ function Ca(t) {
|
|
|
4127
4127
|
this.isSVG = s instanceof SVGElement && s.tagName !== "svg", this.instance = s;
|
|
4128
4128
|
var f = this.options, d = f.layoutId, p = f.layout, v = f.visualElement;
|
|
4129
4129
|
if (v && !v.getInstance() && v.mount(s), this.root.nodes.add(this), (c = this.parent) === null || c === void 0 || c.children.add(this), this.id && this.root.potentialNodes.delete(this.id), u && (p || d) && (this.isLayoutDirty = !0), e) {
|
|
4130
|
-
var h,
|
|
4130
|
+
var h, y = function() {
|
|
4131
4131
|
return l.root.updateBlockedByResize = !1;
|
|
4132
4132
|
};
|
|
4133
4133
|
e(s, function() {
|
|
4134
|
-
l.root.updateBlockedByResize = !0, clearTimeout(h), h = window.setTimeout(
|
|
4134
|
+
l.root.updateBlockedByResize = !0, clearTimeout(h), h = window.setTimeout(y, 250), ie.hasAnimatedSinceResize && (ie.hasAnimatedSinceResize = !1, l.nodes.forEach(Vd));
|
|
4135
4135
|
});
|
|
4136
4136
|
}
|
|
4137
4137
|
d && this.root.registerSharedNode(d, this), this.options.animate !== !1 && v && (d || p) && this.addEventListener("didUpdate", function(m) {
|
|
4138
|
-
var b,
|
|
4138
|
+
var b, g, P, w, V, O = m.delta, j = m.hasLayoutChanged, A = m.hasRelativeTargetChanged, k = m.layout;
|
|
4139
4139
|
if (l.isTreeAnimationBlocked()) {
|
|
4140
4140
|
l.target = void 0, l.relativeTarget = void 0;
|
|
4141
4141
|
return;
|
|
4142
4142
|
}
|
|
4143
|
-
var
|
|
4144
|
-
if (!((P = l.resumeFrom) === null || P === void 0) && P.instance ||
|
|
4145
|
-
l.resumeFrom && (l.resumingFrom = l.resumeFrom, l.resumingFrom.resumingFrom = void 0), l.setAnimationOrigin(
|
|
4146
|
-
var I = x(x({},
|
|
4143
|
+
var _ = (g = (b = l.options.transition) !== null && b !== void 0 ? b : v.getDefaultTransition()) !== null && g !== void 0 ? g : Od, W = v.getProps(), H = W.onLayoutAnimationStart, R = W.onLayoutAnimationComplete, Y = !l.targetLayout || !Ea(l.targetLayout, k) || A, $ = !j && A;
|
|
4144
|
+
if (!((P = l.resumeFrom) === null || P === void 0) && P.instance || $ || j && (Y || !l.currentAnimation)) {
|
|
4145
|
+
l.resumeFrom && (l.resumingFrom = l.resumeFrom, l.resumingFrom.resumingFrom = void 0), l.setAnimationOrigin(O, $);
|
|
4146
|
+
var I = x(x({}, pr(_, "layout")), { onPlay: H, onComplete: R });
|
|
4147
4147
|
v.shouldReduceMotion && (I.delay = 0, I.type = !1), l.startAnimation(I);
|
|
4148
4148
|
} else
|
|
4149
|
-
!j && l.animationProgress === 0 && l.finishAnimation(), l.isLead() && ((
|
|
4149
|
+
!j && l.animationProgress === 0 && l.finishAnimation(), l.isLead() && ((V = (w = l.options).onExitComplete) === null || V === void 0 || V.call(w));
|
|
4150
4150
|
l.targetLayout = k;
|
|
4151
4151
|
});
|
|
4152
4152
|
}
|
|
@@ -4179,14 +4179,14 @@ function Ca(t) {
|
|
|
4179
4179
|
}
|
|
4180
4180
|
var p = this.options, v = p.layoutId, h = p.layout;
|
|
4181
4181
|
if (!(v === void 0 && !h)) {
|
|
4182
|
-
var
|
|
4183
|
-
this.prevTransformTemplateValue =
|
|
4182
|
+
var y = (c = this.options.visualElement) === null || c === void 0 ? void 0 : c.getProps().transformTemplate;
|
|
4183
|
+
this.prevTransformTemplateValue = y == null ? void 0 : y(this.latestValues, ""), this.updateSnapshot(), s && this.notifyListeners("willUpdate");
|
|
4184
4184
|
}
|
|
4185
4185
|
}
|
|
4186
4186
|
}, i.prototype.didUpdate = function() {
|
|
4187
4187
|
var s = this.isUpdateBlocked();
|
|
4188
4188
|
if (s) {
|
|
4189
|
-
this.unblockUpdate(), this.clearAllSnapshots(), this.nodes.forEach(
|
|
4189
|
+
this.unblockUpdate(), this.clearAllSnapshots(), this.nodes.forEach(Bo);
|
|
4190
4190
|
return;
|
|
4191
4191
|
}
|
|
4192
4192
|
this.isUpdating && (this.isUpdating = !1, this.potentialNodes.size && (this.potentialNodes.forEach(Ld), this.potentialNodes.clear()), this.nodes.forEach(wd), this.nodes.forEach(xd), this.nodes.forEach(Pd), this.clearAllSnapshots(), Sn.update(), Sn.preRender(), Sn.render());
|
|
@@ -4202,7 +4202,7 @@ function Ca(t) {
|
|
|
4202
4202
|
}, i.prototype.updateSnapshot = function() {
|
|
4203
4203
|
if (!(this.snapshot || !this.instance)) {
|
|
4204
4204
|
var s = this.measure(), u = this.removeTransform(this.removeElementScroll(s));
|
|
4205
|
-
|
|
4205
|
+
Wo(u), this.snapshot = {
|
|
4206
4206
|
measured: s,
|
|
4207
4207
|
layout: u,
|
|
4208
4208
|
latestValues: {}
|
|
@@ -4217,7 +4217,7 @@ function Ca(t) {
|
|
|
4217
4217
|
l.updateScroll();
|
|
4218
4218
|
}
|
|
4219
4219
|
var c = this.measure();
|
|
4220
|
-
|
|
4220
|
+
Wo(c);
|
|
4221
4221
|
var f = this.layout;
|
|
4222
4222
|
this.layout = {
|
|
4223
4223
|
measured: c,
|
|
@@ -4273,10 +4273,10 @@ function Ca(t) {
|
|
|
4273
4273
|
if (f.instance && Nt(f.latestValues)) {
|
|
4274
4274
|
pa(f.latestValues) && f.updateSnapshot();
|
|
4275
4275
|
var d = lt(), p = f.measure();
|
|
4276
|
-
St(d, p),
|
|
4276
|
+
St(d, p), Lo(l, f.latestValues, (u = f.snapshot) === null || u === void 0 ? void 0 : u.layout, d);
|
|
4277
4277
|
}
|
|
4278
4278
|
}
|
|
4279
|
-
return Nt(this.latestValues) &&
|
|
4279
|
+
return Nt(this.latestValues) && Lo(l, this.latestValues), l;
|
|
4280
4280
|
}, i.prototype.setTargetDelta = function(s) {
|
|
4281
4281
|
this.targetDelta = s, this.root.scheduleUpdateProjection();
|
|
4282
4282
|
}, i.prototype.setOptions = function(s) {
|
|
@@ -4299,7 +4299,7 @@ function Ca(t) {
|
|
|
4299
4299
|
if (d) {
|
|
4300
4300
|
this.projectionDelta || (this.projectionDelta = fe(), this.projectionDeltaWithTransform = fe());
|
|
4301
4301
|
var p = this.treeScale.x, v = this.treeScale.y, h = this.projectionTransform;
|
|
4302
|
-
le(this.projectionDelta, this.layoutCorrected, d, this.latestValues), this.projectionTransform =
|
|
4302
|
+
le(this.projectionDelta, this.layoutCorrected, d, this.latestValues), this.projectionTransform = jo(this.projectionDelta, this.treeScale), (this.projectionTransform !== h || this.treeScale.x !== p || this.treeScale.y !== v) && (this.hasProjected = !0, this.scheduleRender(), this.notifyListeners("projectionUpdate", d));
|
|
4303
4303
|
}
|
|
4304
4304
|
}
|
|
4305
4305
|
}, i.prototype.hide = function() {
|
|
@@ -4314,15 +4314,15 @@ function Ca(t) {
|
|
|
4314
4314
|
u === void 0 && (u = !1);
|
|
4315
4315
|
var f = this.snapshot, d = (f == null ? void 0 : f.latestValues) || {}, p = x({}, this.latestValues), v = fe();
|
|
4316
4316
|
this.relativeTarget = this.relativeTargetOrigin = void 0, this.attemptToResolveRelativeTarget = !u;
|
|
4317
|
-
var h = lt(),
|
|
4318
|
-
this.animationProgress = 0, this.mixTargetDelta = function(
|
|
4319
|
-
var P, w =
|
|
4320
|
-
|
|
4317
|
+
var h = lt(), y = f == null ? void 0 : f.isShared, m = (((c = this.getStack()) === null || c === void 0 ? void 0 : c.members.length) || 0) <= 1, b = !!(y && !m && this.options.crossfade === !0 && !this.path.some(Id));
|
|
4318
|
+
this.animationProgress = 0, this.mixTargetDelta = function(g) {
|
|
4319
|
+
var P, w = g / 1e3;
|
|
4320
|
+
ko(v.x, s.x, w), ko(v.y, s.y, w), l.setTargetDelta(v), l.relativeTarget && l.relativeTargetOrigin && l.layout && (!((P = l.relativeParent) === null || P === void 0) && P.layout) && (ce(h, l.layout.actual, l.relativeParent.layout.actual), Md(l.relativeTarget, l.relativeTargetOrigin, h, w)), y && (l.animationValues = p, fd(p, d, l.latestValues, w, b, m)), l.root.scheduleUpdateProjection(), l.scheduleRender(), l.animationProgress = w;
|
|
4321
4321
|
}, this.mixTargetDelta(0);
|
|
4322
4322
|
}, i.prototype.startAnimation = function(s) {
|
|
4323
4323
|
var u = this, l, c;
|
|
4324
4324
|
this.notifyListeners("animationStart"), (l = this.currentAnimation) === null || l === void 0 || l.stop(), this.resumingFrom && ((c = this.resumingFrom.currentAnimation) === null || c === void 0 || c.stop()), this.pendingAnimation && (Qt.update(this.pendingAnimation), this.pendingAnimation = void 0), this.pendingAnimation = Vt.update(function() {
|
|
4325
|
-
ie.hasAnimatedSinceResize = !0, u.currentAnimation = ld(0,
|
|
4325
|
+
ie.hasAnimatedSinceResize = !0, u.currentAnimation = ld(0, Do, x(x({}, s), { onUpdate: function(f) {
|
|
4326
4326
|
var d;
|
|
4327
4327
|
u.mixTargetDelta(f), (d = s.onUpdate) === null || d === void 0 || d.call(s, f);
|
|
4328
4328
|
}, onComplete: function() {
|
|
@@ -4335,7 +4335,7 @@ function Ca(t) {
|
|
|
4335
4335
|
this.resumingFrom && (this.resumingFrom.currentAnimation = void 0, this.resumingFrom.preserveOpacity = void 0), (s = this.getStack()) === null || s === void 0 || s.exitAnimationComplete(), this.resumingFrom = this.currentAnimation = this.animationValues = void 0, this.notifyListeners("animationComplete");
|
|
4336
4336
|
}, i.prototype.finishAnimation = function() {
|
|
4337
4337
|
var s;
|
|
4338
|
-
this.currentAnimation && ((s = this.mixTargetDelta) === null || s === void 0 || s.call(this,
|
|
4338
|
+
this.currentAnimation && ((s = this.mixTargetDelta) === null || s === void 0 || s.call(this, Do), this.currentAnimation.stop()), this.completeAnimation();
|
|
4339
4339
|
}, i.prototype.applyTransformsToTarget = function() {
|
|
4340
4340
|
var s = this.getLead(), u = s.targetWithTransforms, l = s.target, c = s.layout, f = s.latestValues;
|
|
4341
4341
|
!u || !l || !c || (St(u, l), Zt(u, f), le(this.projectionDeltaWithTransform, this.layoutCorrected, u, f));
|
|
@@ -4393,32 +4393,32 @@ function Ca(t) {
|
|
|
4393
4393
|
var h = (u = this.options.visualElement) === null || u === void 0 ? void 0 : u.getProps().transformTemplate;
|
|
4394
4394
|
if (this.needsReset)
|
|
4395
4395
|
return this.needsReset = !1, v.opacity = "", v.pointerEvents = Be(s.pointerEvents) || "", v.transform = h ? h(this.latestValues, "") : "none", v;
|
|
4396
|
-
var
|
|
4397
|
-
if (!this.projectionDelta || !this.layout || !
|
|
4396
|
+
var y = this.getLead();
|
|
4397
|
+
if (!this.projectionDelta || !this.layout || !y.target) {
|
|
4398
4398
|
var m = {};
|
|
4399
4399
|
return this.options.layoutId && (m.opacity = (l = this.latestValues.opacity) !== null && l !== void 0 ? l : 1, m.pointerEvents = Be(s.pointerEvents) || ""), this.hasProjected && !Nt(this.latestValues) && (m.transform = h ? h({}, "") : "none", this.hasProjected = !1), m;
|
|
4400
4400
|
}
|
|
4401
|
-
var b =
|
|
4402
|
-
this.applyTransformsToTarget(), v.transform =
|
|
4403
|
-
var
|
|
4404
|
-
v.transformOrigin = "".concat(P.origin * 100, "% ").concat(w.origin * 100, "% 0"),
|
|
4405
|
-
for (var
|
|
4406
|
-
if (b[
|
|
4407
|
-
var
|
|
4408
|
-
if (
|
|
4409
|
-
for (var
|
|
4410
|
-
v[
|
|
4401
|
+
var b = y.animationValues || y.latestValues;
|
|
4402
|
+
this.applyTransformsToTarget(), v.transform = jo(this.projectionDeltaWithTransform, this.treeScale, b), h && (v.transform = h(b, v.transform));
|
|
4403
|
+
var g = this.projectionDelta, P = g.x, w = g.y;
|
|
4404
|
+
v.transformOrigin = "".concat(P.origin * 100, "% ").concat(w.origin * 100, "% 0"), y.animationValues ? v.opacity = y === this ? (f = (c = b.opacity) !== null && c !== void 0 ? c : this.latestValues.opacity) !== null && f !== void 0 ? f : 1 : this.preserveOpacity ? this.latestValues.opacity : b.opacityExit : v.opacity = y === this ? (d = b.opacity) !== null && d !== void 0 ? d : "" : (p = b.opacityExit) !== null && p !== void 0 ? p : 0;
|
|
4405
|
+
for (var V in He)
|
|
4406
|
+
if (b[V] !== void 0) {
|
|
4407
|
+
var O = He[V], j = O.correct, A = O.applyTo, k = j(b[V], y);
|
|
4408
|
+
if (A)
|
|
4409
|
+
for (var _ = A.length, W = 0; W < _; W++)
|
|
4410
|
+
v[A[W]] = k;
|
|
4411
4411
|
else
|
|
4412
|
-
v[
|
|
4412
|
+
v[V] = k;
|
|
4413
4413
|
}
|
|
4414
|
-
return this.options.layoutId && (v.pointerEvents =
|
|
4414
|
+
return this.options.layoutId && (v.pointerEvents = y === this ? Be(s.pointerEvents) || "" : "none"), v;
|
|
4415
4415
|
}, i.prototype.clearSnapshot = function() {
|
|
4416
4416
|
this.resumeFrom = this.snapshot = void 0;
|
|
4417
4417
|
}, i.prototype.resetTree = function() {
|
|
4418
4418
|
this.root.nodes.forEach(function(s) {
|
|
4419
4419
|
var u;
|
|
4420
4420
|
return (u = s.currentAnimation) === null || u === void 0 ? void 0 : u.stop();
|
|
4421
|
-
}), this.root.nodes.forEach(
|
|
4421
|
+
}), this.root.nodes.forEach(Bo), this.root.sharedNodes.clear();
|
|
4422
4422
|
}, i;
|
|
4423
4423
|
}()
|
|
4424
4424
|
);
|
|
@@ -4431,11 +4431,11 @@ function Pd(t) {
|
|
|
4431
4431
|
if (t.isLead() && t.layout && a && t.hasListeners("didUpdate")) {
|
|
4432
4432
|
var i = t.layout, s = i.actual, u = i.measured;
|
|
4433
4433
|
t.options.animationType === "size" ? Tt(function(b) {
|
|
4434
|
-
var
|
|
4435
|
-
|
|
4434
|
+
var g = a.isShared ? a.measured[b] : a.layout[b], P = It(g);
|
|
4435
|
+
g.min = s[b].min, g.max = g.min + P;
|
|
4436
4436
|
}) : t.options.animationType === "position" && Tt(function(b) {
|
|
4437
|
-
var
|
|
4438
|
-
|
|
4437
|
+
var g = a.isShared ? a.measured[b] : a.layout[b], P = It(s[b]);
|
|
4438
|
+
g.max = g.min + P;
|
|
4439
4439
|
});
|
|
4440
4440
|
var l = fe();
|
|
4441
4441
|
le(l, s, a.layout);
|
|
@@ -4445,10 +4445,10 @@ function Pd(t) {
|
|
|
4445
4445
|
if (!t.resumeFrom && (t.relativeParent = t.getClosestProjectingParent(), t.relativeParent && !t.relativeParent.resumeFrom)) {
|
|
4446
4446
|
var p = t.relativeParent, v = p.snapshot, h = p.layout;
|
|
4447
4447
|
if (v && h) {
|
|
4448
|
-
var
|
|
4449
|
-
ce(
|
|
4448
|
+
var y = lt();
|
|
4449
|
+
ce(y, a.layout, v.layout);
|
|
4450
4450
|
var m = lt();
|
|
4451
|
-
ce(m, s, h.actual), Ea(
|
|
4451
|
+
ce(m, s, h.actual), Ea(y, m) || (d = !0);
|
|
4452
4452
|
}
|
|
4453
4453
|
}
|
|
4454
4454
|
t.notifyListeners("didUpdate", {
|
|
@@ -4465,7 +4465,7 @@ function Pd(t) {
|
|
|
4465
4465
|
function Td(t) {
|
|
4466
4466
|
t.clearSnapshot();
|
|
4467
4467
|
}
|
|
4468
|
-
function
|
|
4468
|
+
function Bo(t) {
|
|
4469
4469
|
t.clearMeasurements();
|
|
4470
4470
|
}
|
|
4471
4471
|
function wd(t) {
|
|
@@ -4487,14 +4487,14 @@ function Ad(t) {
|
|
|
4487
4487
|
function Rd(t) {
|
|
4488
4488
|
t.removeLeadSnapshot();
|
|
4489
4489
|
}
|
|
4490
|
-
function
|
|
4491
|
-
t.translate =
|
|
4490
|
+
function ko(t, e, n) {
|
|
4491
|
+
t.translate = tt(e.translate, 0, n), t.scale = tt(e.scale, 1, n), t.origin = e.origin, t.originPoint = e.originPoint;
|
|
4492
4492
|
}
|
|
4493
|
-
function
|
|
4494
|
-
t.min =
|
|
4493
|
+
function Fo(t, e, n, r) {
|
|
4494
|
+
t.min = tt(e.min, n.min, r), t.max = tt(e.max, n.max, r);
|
|
4495
4495
|
}
|
|
4496
4496
|
function Md(t, e, n, r) {
|
|
4497
|
-
|
|
4497
|
+
Fo(t.x, e.x, n.x, r), Fo(t.y, e.y, n.y, r);
|
|
4498
4498
|
}
|
|
4499
4499
|
function Id(t) {
|
|
4500
4500
|
return t.animationValues && t.animationValues.opacityExit !== void 0;
|
|
@@ -4512,11 +4512,11 @@ function Ld(t, e) {
|
|
|
4512
4512
|
var o = n && n !== t.root ? n.instance : document, a = o.querySelector('[data-projection-id="'.concat(e, '"]'));
|
|
4513
4513
|
a && t.mount(a, !0);
|
|
4514
4514
|
}
|
|
4515
|
-
function
|
|
4515
|
+
function Ho(t) {
|
|
4516
4516
|
t.min = Math.round(t.min), t.max = Math.round(t.max);
|
|
4517
4517
|
}
|
|
4518
|
-
function
|
|
4519
|
-
|
|
4518
|
+
function Wo(t) {
|
|
4519
|
+
Ho(t.x), Ho(t.y);
|
|
4520
4520
|
}
|
|
4521
4521
|
var Nd = Ca({
|
|
4522
4522
|
attachResizeListener: function(t, e) {
|
|
@@ -4592,7 +4592,7 @@ function kd() {
|
|
|
4592
4592
|
mount: function() {
|
|
4593
4593
|
return t = !0, e.forEach(function(o) {
|
|
4594
4594
|
var a = o.animation, i = o.resolve;
|
|
4595
|
-
r.start.apply(r, ht([],
|
|
4595
|
+
r.start.apply(r, ht([], nt(a), !1)).then(i);
|
|
4596
4596
|
}), function() {
|
|
4597
4597
|
t = !1, r.stop();
|
|
4598
4598
|
};
|
|
@@ -4674,9 +4674,9 @@ const Wd = ({
|
|
|
4674
4674
|
}, d = () => {
|
|
4675
4675
|
n && n(), i && f();
|
|
4676
4676
|
};
|
|
4677
|
-
if ((t == null ? void 0 : t.length) == 0) return /* @__PURE__ */ S(
|
|
4677
|
+
if ((t == null ? void 0 : t.length) == 0) return /* @__PURE__ */ S(Kn, {});
|
|
4678
4678
|
const p = a ? ({ children: v }) => v : Wd;
|
|
4679
|
-
return /* @__PURE__ */
|
|
4679
|
+
return /* @__PURE__ */ K(
|
|
4680
4680
|
"div",
|
|
4681
4681
|
{
|
|
4682
4682
|
className: qt(Ot.StoryPlayer, u, {
|
|
@@ -4684,7 +4684,7 @@ const Wd = ({
|
|
|
4684
4684
|
}),
|
|
4685
4685
|
children: [
|
|
4686
4686
|
/* @__PURE__ */ S("div", { className: Ot.Overlay, onClick: r }),
|
|
4687
|
-
/* @__PURE__ */ S("div", { className: Ot.StoryPlayer__Wrap, children: /* @__PURE__ */
|
|
4687
|
+
/* @__PURE__ */ S("div", { className: Ot.StoryPlayer__Wrap, children: /* @__PURE__ */ K(p, { onClose: s, children: [
|
|
4688
4688
|
/* @__PURE__ */ S("div", { className: Ot.CloseIcon, onClick: s, children: /* @__PURE__ */ S(qd, {}) }),
|
|
4689
4689
|
/* @__PURE__ */ S(
|
|
4690
4690
|
uu,
|
|
@@ -4725,32 +4725,32 @@ function Xd(t, e = Yd) {
|
|
|
4725
4725
|
}
|
|
4726
4726
|
class Zd {
|
|
4727
4727
|
static fromRaw(e) {
|
|
4728
|
-
var i;
|
|
4729
|
-
const n = ((i = e.stakes.find((
|
|
4730
|
-
var
|
|
4731
|
-
const
|
|
4732
|
-
var
|
|
4733
|
-
const
|
|
4728
|
+
var i, s, u;
|
|
4729
|
+
const n = ((s = (i = e == null ? void 0 : e.stakes) == null ? void 0 : i.find((l) => l.isEnabled)) == null ? void 0 : s.preciseValue) ?? 0, r = (u = e == null ? void 0 : e.selections) == null ? void 0 : u.map((l) => {
|
|
4730
|
+
var y, m, b, g, P, w;
|
|
4731
|
+
const c = parseFloat((m = (y = l == null ? void 0 : l.odd) == null ? void 0 : y.price) == null ? void 0 : m.toFixed(2)), f = Xd((b = l == null ? void 0 : l.event) == null ? void 0 : b.startDate), d = (P = (g = l == null ? void 0 : l.odd) == null ? void 0 : g.offers) == null ? void 0 : P.find((V) => V.type === 0), v = l.market.name, h = (w = l == null ? void 0 : l.bbSelections) == null ? void 0 : w.map((V) => {
|
|
4732
|
+
var k, _, W, H, R;
|
|
4733
|
+
const O = (k = V == null ? void 0 : V.odd) == null ? void 0 : k.price, j = parseFloat(O.toFixed(2)), A = (W = (_ = V == null ? void 0 : V.odd) == null ? void 0 : _.offers) == null ? void 0 : W.find((Y) => Y.type === 0);
|
|
4734
4734
|
return {
|
|
4735
|
-
marketName: (
|
|
4736
|
-
name: (
|
|
4737
|
-
cuota:
|
|
4738
|
-
hasPA: !!
|
|
4739
|
-
paParam:
|
|
4735
|
+
marketName: (H = V == null ? void 0 : V.market) == null ? void 0 : H.name,
|
|
4736
|
+
name: (R = V == null ? void 0 : V.odd) == null ? void 0 : R.name,
|
|
4737
|
+
cuota: j,
|
|
4738
|
+
hasPA: !!A,
|
|
4739
|
+
paParam: A == null ? void 0 : A.parameter
|
|
4740
4740
|
};
|
|
4741
4741
|
});
|
|
4742
4742
|
return {
|
|
4743
|
-
name:
|
|
4744
|
-
cuota:
|
|
4745
|
-
event:
|
|
4746
|
-
fechaHora:
|
|
4747
|
-
hasPA: !!
|
|
4748
|
-
paParam:
|
|
4749
|
-
marketName:
|
|
4750
|
-
subSelections:
|
|
4743
|
+
name: l.odd.name,
|
|
4744
|
+
cuota: c,
|
|
4745
|
+
event: l.event.name,
|
|
4746
|
+
fechaHora: f,
|
|
4747
|
+
hasPA: !!d,
|
|
4748
|
+
paParam: d == null ? void 0 : d.parameter,
|
|
4749
|
+
marketName: v,
|
|
4750
|
+
subSelections: h
|
|
4751
4751
|
};
|
|
4752
4752
|
}), o = parseFloat(
|
|
4753
|
-
r.reduce((
|
|
4753
|
+
r == null ? void 0 : r.reduce((l, c) => l * (c == null ? void 0 : c.cuota), 1).toFixed(2)
|
|
4754
4754
|
), a = parseFloat((n * o).toFixed(2));
|
|
4755
4755
|
return { selections: r, stake: n, cuotaTotal: o, gananciaTotal: a };
|
|
4756
4756
|
}
|
|
@@ -4772,62 +4772,65 @@ const Kd = "_BetSlip_hse67_1", Jd = "_BetSlip_Title_hse67_12", Qd = "_SelectionI
|
|
|
4772
4772
|
SelectionItem__BB__mn: sv
|
|
4773
4773
|
}, uv = ({ selection: t }) => {
|
|
4774
4774
|
var e, n;
|
|
4775
|
-
return
|
|
4776
|
-
/* @__PURE__ */
|
|
4775
|
+
return /* @__PURE__ */ K("div", { className: dt.SelectionItem, children: [
|
|
4776
|
+
/* @__PURE__ */ K("div", { className: dt.SelectionItemGrid, children: [
|
|
4777
4777
|
/* @__PURE__ */ S("div", { className: dt.SelectionItem_name, children: t != null && t.subSelections ? "Crear Apuesta" : t.name }),
|
|
4778
4778
|
/* @__PURE__ */ S("div", { className: dt.SelectionItem_sc, children: t.cuota.toFixed(2) })
|
|
4779
4779
|
] }),
|
|
4780
|
-
t != null && t.subSelections ? null : /* @__PURE__ */ S("div", { className: dt.SelectionItemGrid, children: /* @__PURE__ */
|
|
4780
|
+
t != null && t.subSelections ? null : /* @__PURE__ */ S("div", { className: dt.SelectionItemGrid, children: /* @__PURE__ */ K("div", { className: dt.SelectionItem_marketName, children: [
|
|
4781
4781
|
/* @__PURE__ */ S("div", { children: t.marketName }),
|
|
4782
4782
|
t.hasPA && /* @__PURE__ */ S("div", { className: dt.SelectionItem_hasPA, children: "PA" })
|
|
4783
4783
|
] }) }),
|
|
4784
|
-
/* @__PURE__ */
|
|
4784
|
+
/* @__PURE__ */ K("div", { className: dt.SelectionItemGrid, children: [
|
|
4785
4785
|
/* @__PURE__ */ S("div", { className: dt.SelectionItem_event, children: t.event }),
|
|
4786
4786
|
/* @__PURE__ */ S("div", { className: dt.SelectionItem_fechahora, children: t.fechaHora })
|
|
4787
4787
|
] }),
|
|
4788
|
-
((e = t == null ? void 0 : t.subSelections) == null ? void 0 : e.length) > 0 ? /* @__PURE__ */ S("div", { className: dt.SelectionItem__Wrap, children: (n = t.subSelections) == null ? void 0 : n.map((r, o) => /* @__PURE__ */
|
|
4788
|
+
((e = t == null ? void 0 : t.subSelections) == null ? void 0 : e.length) > 0 ? /* @__PURE__ */ S("div", { className: dt.SelectionItem__Wrap, children: (n = t.subSelections) == null ? void 0 : n.map((r, o) => /* @__PURE__ */ K("div", { className: dt.SelectionItem__BB, children: [
|
|
4789
4789
|
/* @__PURE__ */ S("div", { className: dt.SelectionItem__BB__mn, children: r == null ? void 0 : r.marketName }),
|
|
4790
4790
|
/* @__PURE__ */ S("div", { children: r == null ? void 0 : r.name })
|
|
4791
|
-
] }, o)) }) :
|
|
4791
|
+
] }, o)) }) : /* @__PURE__ */ S(Kn, {})
|
|
4792
4792
|
] });
|
|
4793
|
-
}, lv = "_PulseButton_1udbm_1", cv = "_PulseButton_BG_1udbm_8",
|
|
4793
|
+
}, lv = "_PulseButton_1udbm_1", cv = "_PulseButton_BG_1udbm_8", qo = {
|
|
4794
4794
|
PulseButton: lv,
|
|
4795
4795
|
PulseButton_BG: cv
|
|
4796
4796
|
}, fv = "_Button_1lfmc_1", dv = {
|
|
4797
4797
|
Button: fv
|
|
4798
|
-
}, Ra = ({ children: t, href: e }) => /* @__PURE__ */
|
|
4799
|
-
/* @__PURE__ */ S("div", { className:
|
|
4798
|
+
}, Ra = ({ children: t, href: e }) => /* @__PURE__ */ K("div", { className: qo.PulseButton, children: [
|
|
4799
|
+
/* @__PURE__ */ S("div", { className: qo.PulseButton_BG }),
|
|
4800
4800
|
/* @__PURE__ */ S("a", { className: dv.Button, href: e, children: t })
|
|
4801
|
-
] }), vv = ({ slip: t, title: e }) =>
|
|
4802
|
-
|
|
4803
|
-
|
|
4804
|
-
|
|
4805
|
-
|
|
4806
|
-
|
|
4807
|
-
|
|
4808
|
-
{
|
|
4809
|
-
|
|
4810
|
-
|
|
4811
|
-
|
|
4812
|
-
|
|
4813
|
-
|
|
4814
|
-
|
|
4815
|
-
|
|
4816
|
-
},
|
|
4801
|
+
] }), vv = ({ slip: t, title: e }) => {
|
|
4802
|
+
var n;
|
|
4803
|
+
return /* @__PURE__ */ K("div", { className: De.BetSlip, children: [
|
|
4804
|
+
/* @__PURE__ */ K("div", { className: De.SelectionItemWrap, children: [
|
|
4805
|
+
e ? /* @__PURE__ */ S("div", { className: De.BetSlip_Title, children: e }) : null,
|
|
4806
|
+
(n = t == null ? void 0 : t.selections) == null ? void 0 : n.map((r, o) => /* @__PURE__ */ S(uv, { selection: r }, `${Date.now()}-${o}`))
|
|
4807
|
+
] }),
|
|
4808
|
+
t != null && t.cuotaTota ? /* @__PURE__ */ S("div", { className: qt(De.BetSlip_ButtonWrap), children: /* @__PURE__ */ S(
|
|
4809
|
+
Ra,
|
|
4810
|
+
{
|
|
4811
|
+
href: "https://www.apuestatotal.com/apuestas-deportivas/?reservationCode=HHHH",
|
|
4812
|
+
children: t == null ? void 0 : t.cuotaTotal
|
|
4813
|
+
}
|
|
4814
|
+
) }) : null
|
|
4815
|
+
] });
|
|
4816
|
+
}, Ma = ({ story: t }) => {
|
|
4817
|
+
let e = Go;
|
|
4818
|
+
return (t == null ? void 0 : t.type) == "promo" && (e = Go), (t == null ? void 0 : t.type) == "betting" && (e = pv), /* @__PURE__ */ S(e, { story: t });
|
|
4819
|
+
}, Go = ({ story: t }) => /* @__PURE__ */ K("div", { className: qt(de.story), children: [
|
|
4817
4820
|
/* @__PURE__ */ S("img", { src: t == null ? void 0 : t.image, alt: "" }),
|
|
4818
|
-
t != null && t.btn_text && (t != null && t.btn_url) ? /* @__PURE__ */ S("div", { className: qt(de.BetSlip_Wrapper), children: /* @__PURE__ */ S("div", { className: de.BetSlip_ButtonWrap, children: /* @__PURE__ */
|
|
4821
|
+
t != null && t.btn_text && (t != null && t.btn_url) ? /* @__PURE__ */ S("div", { className: qt(de.BetSlip_Wrapper), children: /* @__PURE__ */ S("div", { className: de.BetSlip_ButtonWrap, children: /* @__PURE__ */ K(Ra, { href: t == null ? void 0 : t.btn_url, children: [
|
|
4819
4822
|
" ",
|
|
4820
4823
|
t == null ? void 0 : t.btn_text
|
|
4821
4824
|
] }) }) }) : null
|
|
4822
4825
|
] }), pv = ({ story: t }) => {
|
|
4823
|
-
const e = JSON.parse(t == null ? void 0 : t.coupon_result);
|
|
4824
|
-
return console.log(e), /* @__PURE__ */
|
|
4826
|
+
const e = JSON.parse((t == null ? void 0 : t.coupon_result) ?? "{}");
|
|
4827
|
+
return console.log(e), /* @__PURE__ */ K("div", { className: qt(de.story), children: [
|
|
4825
4828
|
/* @__PURE__ */ S("img", { src: t == null ? void 0 : t.image, alt: "" }),
|
|
4826
4829
|
/* @__PURE__ */ S("div", { className: de.BetSlip_Wrapper, children: /* @__PURE__ */ S(
|
|
4827
4830
|
vv,
|
|
4828
4831
|
{
|
|
4829
4832
|
slip: Zd.fromRaw(e),
|
|
4830
|
-
title: t == null ? void 0 : t.
|
|
4833
|
+
title: t == null ? void 0 : t.coupon_title
|
|
4831
4834
|
}
|
|
4832
4835
|
) })
|
|
4833
4836
|
] });
|
|
@@ -4840,9 +4843,9 @@ const Kd = "_BetSlip_hse67_1", Jd = "_BetSlip_Title_hse67_12", Qd = "_SelectionI
|
|
|
4840
4843
|
onProfileClick: e = () => null,
|
|
4841
4844
|
color: n,
|
|
4842
4845
|
image: r
|
|
4843
|
-
}) => /* @__PURE__ */
|
|
4846
|
+
}) => /* @__PURE__ */ K("div", { className: En.StoryHeaderPlayer, children: [
|
|
4844
4847
|
/* @__PURE__ */ S(
|
|
4845
|
-
|
|
4848
|
+
Jn,
|
|
4846
4849
|
{
|
|
4847
4850
|
className: En.StoryHeaderPlayer__ProfileStory,
|
|
4848
4851
|
onProfileClick: e,
|
|
@@ -4961,7 +4964,7 @@ function bv({ scroll: t, targets: e }) {
|
|
|
4961
4964
|
}, [t]), { disableScroll: r, enableScroll: o };
|
|
4962
4965
|
}
|
|
4963
4966
|
const xv = ({ className: t = "", data: e, isPortal: n = !0 }) => {
|
|
4964
|
-
var
|
|
4967
|
+
var y;
|
|
4965
4968
|
const [r, o] = mt(null), a = (m) => o(m), {
|
|
4966
4969
|
markStorySeen: i,
|
|
4967
4970
|
hasSeenAllStories: s,
|
|
@@ -4973,7 +4976,7 @@ const xv = ({ className: t = "", data: e, isPortal: n = !0 }) => {
|
|
|
4973
4976
|
F(() => {
|
|
4974
4977
|
f.current = c;
|
|
4975
4978
|
}, [c]);
|
|
4976
|
-
const d = e == null ? void 0 : e.find((m) => (m == null ? void 0 : m.id) == r), p = ((
|
|
4979
|
+
const d = e == null ? void 0 : e.find((m) => (m == null ? void 0 : m.id) == r), p = ((y = e == null ? void 0 : e.find((m) => (m == null ? void 0 : m.id) == r)) == null ? void 0 : y.stories) ?? [];
|
|
4977
4980
|
Sv(r, () => o(null)), bv({
|
|
4978
4981
|
targets: [document],
|
|
4979
4982
|
scroll: r ? "OFF" : "ON"
|
|
@@ -4982,34 +4985,34 @@ const xv = ({ className: t = "", data: e, isPortal: n = !0 }) => {
|
|
|
4982
4985
|
o(null), f.current = c;
|
|
4983
4986
|
}, h = () => {
|
|
4984
4987
|
if (!r) return null;
|
|
4985
|
-
const m = p.map((
|
|
4988
|
+
const m = p.map((g) => ({
|
|
4986
4989
|
type: "component",
|
|
4987
|
-
component: ({ pause: P, resume: w, story:
|
|
4988
|
-
duration:
|
|
4990
|
+
component: ({ pause: P, resume: w, story: V, isPaused: O }) => (i(d == null ? void 0 : d.id, g.id), /* @__PURE__ */ S(Ma, { story: g })),
|
|
4991
|
+
duration: g != null && g.duration ? (g == null ? void 0 : g.duration) * 1e3 : 7e3,
|
|
4989
4992
|
header: () => /* @__PURE__ */ S(
|
|
4990
4993
|
Ia,
|
|
4991
4994
|
{
|
|
4992
4995
|
color: d == null ? void 0 : d.color,
|
|
4993
4996
|
image: d == null ? void 0 : d.avatar,
|
|
4994
|
-
story:
|
|
4997
|
+
story: g
|
|
4995
4998
|
},
|
|
4996
|
-
|
|
4999
|
+
g == null ? void 0 : g.id
|
|
4997
5000
|
)
|
|
4998
5001
|
})), b = /* @__PURE__ */ S(
|
|
4999
5002
|
Aa,
|
|
5000
5003
|
{
|
|
5001
5004
|
onClose: v,
|
|
5002
5005
|
onOverlayClick: v,
|
|
5003
|
-
onStoryChange: (
|
|
5006
|
+
onStoryChange: (g) => {
|
|
5004
5007
|
},
|
|
5005
5008
|
onAllStoriesEnd: async () => {
|
|
5006
5009
|
var w;
|
|
5007
|
-
const
|
|
5008
|
-
(
|
|
5010
|
+
const g = f.current.findIndex(
|
|
5011
|
+
(V) => V.id == r
|
|
5009
5012
|
), P = f.current.filter(
|
|
5010
|
-
(
|
|
5013
|
+
(V) => V.id !== r
|
|
5011
5014
|
);
|
|
5012
|
-
f.current = P, (w = f.current[
|
|
5015
|
+
f.current = P, (w = f.current[g]) != null && w.id ? o(f.current[g].id) : (o(null), f.current = c);
|
|
5013
5016
|
},
|
|
5014
5017
|
currentIndex: d ? u(d) : 0,
|
|
5015
5018
|
stories: m
|
|
@@ -5018,7 +5021,7 @@ const xv = ({ className: t = "", data: e, isPortal: n = !0 }) => {
|
|
|
5018
5021
|
);
|
|
5019
5022
|
return n ? ja.createPortal(b, document.body) : b;
|
|
5020
5023
|
};
|
|
5021
|
-
return /* @__PURE__ */
|
|
5024
|
+
return /* @__PURE__ */ K(Kn, { children: [
|
|
5022
5025
|
/* @__PURE__ */ S(
|
|
5023
5026
|
Vs,
|
|
5024
5027
|
{
|
|
@@ -5026,7 +5029,7 @@ const xv = ({ className: t = "", data: e, isPortal: n = !0 }) => {
|
|
|
5026
5029
|
scrollContainerClassName: sn.scrollContainerClassName,
|
|
5027
5030
|
itemClassName: sn.itemClassName,
|
|
5028
5031
|
children: c.map((m, b) => /* @__PURE__ */ S(
|
|
5029
|
-
|
|
5032
|
+
Jn,
|
|
5030
5033
|
{
|
|
5031
5034
|
hasSeenAllStories: s(m),
|
|
5032
5035
|
onProfileClick: () => a(m == null ? void 0 : m.id),
|
|
@@ -5077,7 +5080,7 @@ function Av() {
|
|
|
5077
5080
|
});
|
|
5078
5081
|
}, []);
|
|
5079
5082
|
const n = (t == null ? void 0 : t[0]) ?? {}, r = (a = (o = t == null ? void 0 : t[0]) == null ? void 0 : o.stories) == null ? void 0 : a[0];
|
|
5080
|
-
return /* @__PURE__ */
|
|
5083
|
+
return /* @__PURE__ */ K("div", { className: "App", children: [
|
|
5081
5084
|
/* @__PURE__ */ S("h2", { children: "Perfil + Stories" }),
|
|
5082
5085
|
/* @__PURE__ */ S("hr", {}),
|
|
5083
5086
|
/* @__PURE__ */ S(xv, { data: t }),
|
|
@@ -5086,7 +5089,7 @@ function Av() {
|
|
|
5086
5089
|
/* @__PURE__ */ S("hr", {}),
|
|
5087
5090
|
/* @__PURE__ */ S("br", {}),
|
|
5088
5091
|
/* @__PURE__ */ S(
|
|
5089
|
-
|
|
5092
|
+
Jn,
|
|
5090
5093
|
{
|
|
5091
5094
|
color: "#119b62",
|
|
5092
5095
|
image: Da,
|
|
@@ -5111,7 +5114,7 @@ function Av() {
|
|
|
5111
5114
|
component: ({ pause: i, resume: s, story: u, isPaused: l }) => /* @__PURE__ */ S(
|
|
5112
5115
|
Ma,
|
|
5113
5116
|
{
|
|
5114
|
-
story: r
|
|
5117
|
+
story: { ...r, type: "betting" }
|
|
5115
5118
|
}
|
|
5116
5119
|
),
|
|
5117
5120
|
duration: r != null && r.duration ? (r == null ? void 0 : r.duration) * 1e3 : 7e3,
|
|
@@ -5133,7 +5136,7 @@ export {
|
|
|
5133
5136
|
Ma as ManagmentStoryComponent,
|
|
5134
5137
|
Av as MyStory,
|
|
5135
5138
|
xv as ProfileStories,
|
|
5136
|
-
|
|
5139
|
+
Jn as ProfileStory,
|
|
5137
5140
|
Ia as StoryHeaderPlayer,
|
|
5138
5141
|
Aa as StoryPlayer
|
|
5139
5142
|
};
|