@contentmunch/contentmunch-ui 1.1.26 → 1.1.28
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/lib/icon/Drawings.d.ts +1 -0
- package/lib/index.cjs.js +4 -4
- package/lib/index.d.ts +2 -0
- package/lib/index.es.js +529 -499
- package/lib/index.umd.js +5 -5
- package/lib/input/PasswordInput.d.ts +12 -0
- package/package.json +1 -1
package/lib/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import gi, { useState as
|
|
1
|
+
import gi, { useState as $, Fragment as p, useRef as fe, useCallback as Ce, useEffect as je, useMemo as Ie, createContext as ze, useLayoutEffect as co, useContext as ee, useId as uo, createElement as ho, useInsertionEffect as ji, forwardRef as fo, Component as po } from "react";
|
|
2
2
|
var at = { exports: {} }, $e = {};
|
|
3
3
|
/**
|
|
4
4
|
* @license React
|
|
@@ -10,7 +10,7 @@ var at = { exports: {} }, $e = {};
|
|
|
10
10
|
* LICENSE file in the root directory of this source tree.
|
|
11
11
|
*/
|
|
12
12
|
var qn;
|
|
13
|
-
function
|
|
13
|
+
function mo() {
|
|
14
14
|
if (qn) return $e;
|
|
15
15
|
qn = 1;
|
|
16
16
|
var e = Symbol.for("react.transitional.element"), t = Symbol.for("react.fragment");
|
|
@@ -42,7 +42,7 @@ var Ke = {};
|
|
|
42
42
|
* LICENSE file in the root directory of this source tree.
|
|
43
43
|
*/
|
|
44
44
|
var Zn;
|
|
45
|
-
function
|
|
45
|
+
function xo() {
|
|
46
46
|
return Zn || (Zn = 1, process.env.NODE_ENV !== "production" && function() {
|
|
47
47
|
function e(j) {
|
|
48
48
|
if (j == null) return null;
|
|
@@ -60,7 +60,7 @@ function mo() {
|
|
|
60
60
|
return "Suspense";
|
|
61
61
|
case E:
|
|
62
62
|
return "SuspenseList";
|
|
63
|
-
case
|
|
63
|
+
case I:
|
|
64
64
|
return "Activity";
|
|
65
65
|
}
|
|
66
66
|
if (typeof j == "object")
|
|
@@ -76,7 +76,7 @@ function mo() {
|
|
|
76
76
|
case M:
|
|
77
77
|
var V = j.render;
|
|
78
78
|
return j = j.displayName, j || (j = V.displayName || V.name || "", j = j !== "" ? "ForwardRef(" + j + ")" : "ForwardRef"), j;
|
|
79
|
-
case
|
|
79
|
+
case D:
|
|
80
80
|
return V = j.displayName || null, V !== null ? V : e(j.type) || "Memo";
|
|
81
81
|
case P:
|
|
82
82
|
V = j._payload, j = j._init;
|
|
@@ -99,11 +99,11 @@ function mo() {
|
|
|
99
99
|
}
|
|
100
100
|
if (V) {
|
|
101
101
|
V = console;
|
|
102
|
-
var R = V.error,
|
|
102
|
+
var R = V.error, G = typeof Symbol == "function" && Symbol.toStringTag && j[Symbol.toStringTag] || j.constructor.name || "Object";
|
|
103
103
|
return R.call(
|
|
104
104
|
V,
|
|
105
105
|
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
106
|
-
|
|
106
|
+
G
|
|
107
107
|
), t(j);
|
|
108
108
|
}
|
|
109
109
|
}
|
|
@@ -150,7 +150,7 @@ function mo() {
|
|
|
150
150
|
"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
|
|
151
151
|
)), j = this.props.ref, j !== void 0 ? j : null;
|
|
152
152
|
}
|
|
153
|
-
function h(j, V, R,
|
|
153
|
+
function h(j, V, R, G, me, le, Rt, Lt) {
|
|
154
154
|
return R = le.ref, j = {
|
|
155
155
|
$$typeof: m,
|
|
156
156
|
type: j,
|
|
@@ -182,48 +182,48 @@ function mo() {
|
|
|
182
182
|
value: Lt
|
|
183
183
|
}), Object.freeze && (Object.freeze(j.props), Object.freeze(j)), j;
|
|
184
184
|
}
|
|
185
|
-
function u(j, V, R,
|
|
186
|
-
var
|
|
187
|
-
if (
|
|
188
|
-
if (
|
|
189
|
-
if (X(
|
|
190
|
-
for (
|
|
191
|
-
d(G
|
|
192
|
-
Object.freeze && Object.freeze(
|
|
185
|
+
function u(j, V, R, G, me, le, Rt, Lt) {
|
|
186
|
+
var Y = V.children;
|
|
187
|
+
if (Y !== void 0)
|
|
188
|
+
if (G)
|
|
189
|
+
if (X(Y)) {
|
|
190
|
+
for (G = 0; G < Y.length; G++)
|
|
191
|
+
d(Y[G]);
|
|
192
|
+
Object.freeze && Object.freeze(Y);
|
|
193
193
|
} else
|
|
194
194
|
console.error(
|
|
195
195
|
"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
|
|
196
196
|
);
|
|
197
|
-
else d(
|
|
197
|
+
else d(Y);
|
|
198
198
|
if (F.call(V, "key")) {
|
|
199
|
-
|
|
200
|
-
var
|
|
201
|
-
return
|
|
199
|
+
Y = e(j);
|
|
200
|
+
var ke = Object.keys(V).filter(function(lo) {
|
|
201
|
+
return lo !== "key";
|
|
202
202
|
});
|
|
203
|
-
|
|
203
|
+
G = 0 < ke.length ? "{key: someKey, " + ke.join(": ..., ") + ": ...}" : "{key: someKey}", _[Y + G] || (ke = 0 < ke.length ? "{" + ke.join(": ..., ") + ": ...}" : "{}", console.error(
|
|
204
204
|
`A props object containing a "key" prop is being spread into JSX:
|
|
205
205
|
let props = %s;
|
|
206
206
|
<%s {...props} />
|
|
207
207
|
React keys must be passed directly to JSX without using spread:
|
|
208
208
|
let props = %s;
|
|
209
209
|
<%s key={someKey} {...props} />`,
|
|
210
|
-
K,
|
|
211
210
|
G,
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
211
|
+
Y,
|
|
212
|
+
ke,
|
|
213
|
+
Y
|
|
214
|
+
), _[Y + G] = !0);
|
|
215
215
|
}
|
|
216
|
-
if (
|
|
216
|
+
if (Y = null, R !== void 0 && (n(R), Y = "" + R), o(V) && (n(V.key), Y = "" + V.key), "key" in V) {
|
|
217
217
|
R = {};
|
|
218
218
|
for (var Nt in V)
|
|
219
219
|
Nt !== "key" && (R[Nt] = V[Nt]);
|
|
220
220
|
} else R = V;
|
|
221
|
-
return
|
|
221
|
+
return Y && l(
|
|
222
222
|
R,
|
|
223
223
|
typeof j == "function" ? j.displayName || j.name || "Unknown" : j
|
|
224
224
|
), h(
|
|
225
225
|
j,
|
|
226
|
-
|
|
226
|
+
Y,
|
|
227
227
|
le,
|
|
228
228
|
me,
|
|
229
229
|
r(),
|
|
@@ -235,7 +235,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
235
235
|
function d(j) {
|
|
236
236
|
typeof j == "object" && j !== null && j.$$typeof === m && j._store && (j._store.validated = 1);
|
|
237
237
|
}
|
|
238
|
-
var f = gi, m = Symbol.for("react.transitional.element"), x = Symbol.for("react.portal"), g = Symbol.for("react.fragment"), y = Symbol.for("react.strict_mode"), w = Symbol.for("react.profiler"), v = Symbol.for("react.consumer"), b = Symbol.for("react.context"), M = Symbol.for("react.forward_ref"), S = Symbol.for("react.suspense"), E = Symbol.for("react.suspense_list"),
|
|
238
|
+
var f = gi, m = Symbol.for("react.transitional.element"), x = Symbol.for("react.portal"), g = Symbol.for("react.fragment"), y = Symbol.for("react.strict_mode"), w = Symbol.for("react.profiler"), v = Symbol.for("react.consumer"), b = Symbol.for("react.context"), M = Symbol.for("react.forward_ref"), S = Symbol.for("react.suspense"), E = Symbol.for("react.suspense_list"), D = Symbol.for("react.memo"), P = Symbol.for("react.lazy"), I = Symbol.for("react.activity"), T = Symbol.for("react.client.reference"), C = f.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, F = Object.prototype.hasOwnProperty, X = Array.isArray, K = console.createTask ? console.createTask : function() {
|
|
239
239
|
return null;
|
|
240
240
|
};
|
|
241
241
|
f = {
|
|
@@ -246,41 +246,41 @@ React keys must be passed directly to JSX without using spread:
|
|
|
246
246
|
var Q, q = {}, Ee = f["react-stack-bottom-frame"].bind(
|
|
247
247
|
f,
|
|
248
248
|
a
|
|
249
|
-
)(),
|
|
250
|
-
Ke.Fragment = g, Ke.jsx = function(j, V, R,
|
|
249
|
+
)(), O = K(i(a)), _ = {};
|
|
250
|
+
Ke.Fragment = g, Ke.jsx = function(j, V, R, G, me) {
|
|
251
251
|
var le = 1e4 > C.recentlyCreatedOwnerStacks++;
|
|
252
252
|
return u(
|
|
253
253
|
j,
|
|
254
254
|
V,
|
|
255
255
|
R,
|
|
256
256
|
!1,
|
|
257
|
-
|
|
257
|
+
G,
|
|
258
258
|
me,
|
|
259
259
|
le ? Error("react-stack-top-frame") : Ee,
|
|
260
|
-
le ?
|
|
260
|
+
le ? K(i(j)) : O
|
|
261
261
|
);
|
|
262
|
-
}, Ke.jsxs = function(j, V, R,
|
|
262
|
+
}, Ke.jsxs = function(j, V, R, G, me) {
|
|
263
263
|
var le = 1e4 > C.recentlyCreatedOwnerStacks++;
|
|
264
264
|
return u(
|
|
265
265
|
j,
|
|
266
266
|
V,
|
|
267
267
|
R,
|
|
268
268
|
!0,
|
|
269
|
-
|
|
269
|
+
G,
|
|
270
270
|
me,
|
|
271
271
|
le ? Error("react-stack-top-frame") : Ee,
|
|
272
|
-
le ?
|
|
272
|
+
le ? K(i(j)) : O
|
|
273
273
|
);
|
|
274
274
|
};
|
|
275
275
|
}()), Ke;
|
|
276
276
|
}
|
|
277
277
|
var Jn;
|
|
278
|
-
function
|
|
279
|
-
return Jn || (Jn = 1, process.env.NODE_ENV === "production" ? at.exports =
|
|
278
|
+
function yo() {
|
|
279
|
+
return Jn || (Jn = 1, process.env.NODE_ENV === "production" ? at.exports = mo() : at.exports = xo()), at.exports;
|
|
280
280
|
}
|
|
281
|
-
var s =
|
|
281
|
+
var s = yo();
|
|
282
282
|
const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
283
|
-
const { folds: r } = i, [a, o] =
|
|
283
|
+
const { folds: r } = i, [a, o] = $(t ? -1 : 0), l = (f) => f === a ? "fold active" : "fold", c = (f) => "fold-button" + (e ? " fold-button--" + e : "") + (r[f].foldColor ? " fold-button--primary fold-button--" + r[f].foldColor : ""), h = (f) => {
|
|
284
284
|
const m = f.which.toString(), x = f.ctrlKey && m.match(/33|34/);
|
|
285
285
|
if (m.match(/38|40/) || x) {
|
|
286
286
|
const g = m.match(/34|40/) ? 1 : -1, y = r.length, w = (a + y + g) % y;
|
|
@@ -313,7 +313,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
313
313
|
"muncher-accordion-fold-" + m
|
|
314
314
|
)
|
|
315
315
|
) });
|
|
316
|
-
},
|
|
316
|
+
}, go = ({
|
|
317
317
|
show: e = !1,
|
|
318
318
|
className: t,
|
|
319
319
|
backdropClickHandler: n,
|
|
@@ -321,7 +321,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
321
321
|
}) => {
|
|
322
322
|
const r = "muncher-backdrop" + (t ? " " + t : "");
|
|
323
323
|
return e ? /* @__PURE__ */ s.jsx("div", { className: r, onClick: n, ...i }) : null;
|
|
324
|
-
},
|
|
324
|
+
}, jo = ({ variant: e, rounded: t, border: n, children: i, ...r }) => {
|
|
325
325
|
const a = "muncher-badge" + (e ? " muncher-badge--" + e : "") + (t ? " muncher-badge--rounded" : "") + (n ? " muncher-badge--border" : "");
|
|
326
326
|
return /* @__PURE__ */ s.jsx("div", { className: a, ...r, children: i });
|
|
327
327
|
}, lt = {
|
|
@@ -502,6 +502,15 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
502
502
|
/* @__PURE__ */ s.jsx("path", { d: "M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z" }),
|
|
503
503
|
/* @__PURE__ */ s.jsx("circle", { cx: "12", cy: "12", r: "3" })
|
|
504
504
|
] }),
|
|
505
|
+
"eye-off": /* @__PURE__ */ s.jsxs(p, { children: [
|
|
506
|
+
/* @__PURE__ */ s.jsx(
|
|
507
|
+
"path",
|
|
508
|
+
{
|
|
509
|
+
d: "M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19m-6.72-1.07a3 3 0 1 1-4.24-4.24"
|
|
510
|
+
}
|
|
511
|
+
),
|
|
512
|
+
/* @__PURE__ */ s.jsx("line", { x1: "1", y1: "1", x2: "23", y2: "23" })
|
|
513
|
+
] }),
|
|
505
514
|
droplet: /* @__PURE__ */ s.jsx(p, { children: /* @__PURE__ */ s.jsx("path", { d: "M12 2.69l5.66 5.66a8 8 0 1 1-11.31 0z" }) }),
|
|
506
515
|
feather: /* @__PURE__ */ s.jsxs(p, { children: [
|
|
507
516
|
/* @__PURE__ */ s.jsx("path", { d: "M20.24 12.24a6 6 0 0 0-8.49-8.49L5 10.5V19h8.5z" }),
|
|
@@ -1404,7 +1413,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1404
1413
|
...r,
|
|
1405
1414
|
children: [
|
|
1406
1415
|
/* @__PURE__ */ s.jsx(N, { name: t }),
|
|
1407
|
-
n === "" ? "" : /* @__PURE__ */ s.jsx(
|
|
1416
|
+
n === "" ? "" : /* @__PURE__ */ s.jsx(jo, { variant: e, children: n })
|
|
1408
1417
|
]
|
|
1409
1418
|
}
|
|
1410
1419
|
), ne = ({
|
|
@@ -1439,7 +1448,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1439
1448
|
children: f
|
|
1440
1449
|
}
|
|
1441
1450
|
);
|
|
1442
|
-
},
|
|
1451
|
+
}, vo = ({
|
|
1443
1452
|
variant: e,
|
|
1444
1453
|
size: t = "medium",
|
|
1445
1454
|
title: n,
|
|
@@ -1473,8 +1482,8 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1473
1482
|
};
|
|
1474
1483
|
}, [b, v]);
|
|
1475
1484
|
const M = () => {
|
|
1476
|
-
var
|
|
1477
|
-
const S = (
|
|
1485
|
+
var D;
|
|
1486
|
+
const S = (D = y.current) == null ? void 0 : D.offsetLeft, E = window.innerWidth;
|
|
1478
1487
|
if (S) {
|
|
1479
1488
|
if (S < 100) return "muncher-dropdown--content";
|
|
1480
1489
|
if (E - S < 150) return "muncher-dropdown--content drop-left";
|
|
@@ -1541,15 +1550,15 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1541
1550
|
}
|
|
1542
1551
|
),
|
|
1543
1552
|
/* @__PURE__ */ s.jsx("div", { className: "muncher-dropdown-nav--content", children: o })
|
|
1544
|
-
] }),
|
|
1553
|
+
] }), wo = (e) => {
|
|
1545
1554
|
navigator.clipboard.writeText(e);
|
|
1546
|
-
},
|
|
1555
|
+
}, bo = ({
|
|
1547
1556
|
text: e,
|
|
1548
1557
|
variant: t = "secondary",
|
|
1549
1558
|
size: n = "small"
|
|
1550
1559
|
}) => {
|
|
1551
|
-
const [i, r] =
|
|
1552
|
-
|
|
1560
|
+
const [i, r] = $(), [a, o] = $("copy"), [l, c] = $("copy link"), h = () => {
|
|
1561
|
+
wo(e), r("green"), o("check"), c("copied!"), setTimeout(function() {
|
|
1553
1562
|
r(""), o("copy");
|
|
1554
1563
|
}, 2e3);
|
|
1555
1564
|
};
|
|
@@ -1568,9 +1577,9 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1568
1577
|
size: t = "medium",
|
|
1569
1578
|
title: n
|
|
1570
1579
|
}) => {
|
|
1571
|
-
const [i, r] =
|
|
1580
|
+
const [i, r] = $(!1);
|
|
1572
1581
|
return /* @__PURE__ */ s.jsx("div", { className: "muncher-share", children: /* @__PURE__ */ s.jsxs(
|
|
1573
|
-
|
|
1582
|
+
vo,
|
|
1574
1583
|
{
|
|
1575
1584
|
title: "Share to Social Media",
|
|
1576
1585
|
showContent: i,
|
|
@@ -1606,11 +1615,11 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1606
1615
|
children: /* @__PURE__ */ s.jsx(N, { name: "mail" })
|
|
1607
1616
|
}
|
|
1608
1617
|
) }),
|
|
1609
|
-
/* @__PURE__ */ s.jsx(
|
|
1618
|
+
/* @__PURE__ */ s.jsx(bo, { text: window.location.href })
|
|
1610
1619
|
]
|
|
1611
1620
|
}
|
|
1612
1621
|
) });
|
|
1613
|
-
},
|
|
1622
|
+
}, To = ({
|
|
1614
1623
|
header: e,
|
|
1615
1624
|
data: t,
|
|
1616
1625
|
filename: n,
|
|
@@ -1625,7 +1634,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1625
1634
|
` + t.map((u) => u.join(",")).join(`
|
|
1626
1635
|
`));
|
|
1627
1636
|
return /* @__PURE__ */ s.jsx("div", { className: "muncher-csv", children: /* @__PURE__ */ s.jsx(ne, { variant: i, size: r, active: o, disabled: l, rounded: c, children: /* @__PURE__ */ s.jsx("a", { href: h, download: n + ".csv", children: /* @__PURE__ */ s.jsx(N, { name: "download", children: a || "Download" }) }) }) });
|
|
1628
|
-
},
|
|
1637
|
+
}, Mo = ({
|
|
1629
1638
|
variant: e = "transparent",
|
|
1630
1639
|
size: t = "small",
|
|
1631
1640
|
title: n,
|
|
@@ -1635,7 +1644,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1635
1644
|
onClick: o,
|
|
1636
1645
|
children: l
|
|
1637
1646
|
}) => {
|
|
1638
|
-
const [c, h] =
|
|
1647
|
+
const [c, h] = $(!1), u = () => !r || r && !c ? i ? /* @__PURE__ */ s.jsx(N, { name: "sort-asc" }) : /* @__PURE__ */ s.jsx(N, { name: "sort-desc" }) : i ? /* @__PURE__ */ s.jsx(N, { name: "sort-desc" }) : /* @__PURE__ */ s.jsx(N, { name: "sort-asc" });
|
|
1639
1648
|
return /* @__PURE__ */ s.jsxs(
|
|
1640
1649
|
ne,
|
|
1641
1650
|
{
|
|
@@ -1705,7 +1714,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1705
1714
|
label: r,
|
|
1706
1715
|
...a
|
|
1707
1716
|
}) => {
|
|
1708
|
-
const [o, l] =
|
|
1717
|
+
const [o, l] = $(i || !1);
|
|
1709
1718
|
return /* @__PURE__ */ s.jsx("div", { className: "muncher-input--div", children: /* @__PURE__ */ s.jsxs("div", { className: "muncher-checkbox", children: [
|
|
1710
1719
|
/* @__PURE__ */ s.jsx(
|
|
1711
1720
|
"input",
|
|
@@ -1739,7 +1748,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1739
1748
|
className: e ? "muncher-spinner muncher-spinner-" + e : "muncher-spinner",
|
|
1740
1749
|
...t
|
|
1741
1750
|
}
|
|
1742
|
-
),
|
|
1751
|
+
), So = ({
|
|
1743
1752
|
name: e,
|
|
1744
1753
|
label: t,
|
|
1745
1754
|
variant: n = "secondary",
|
|
@@ -1778,7 +1787,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1778
1787
|
c && c !== "" ? /* @__PURE__ */ s.jsx("p", { className: "text-danger", children: c }) : "",
|
|
1779
1788
|
h && h !== "" ? /* @__PURE__ */ s.jsx("p", { className: "text-success", children: h }) : ""
|
|
1780
1789
|
] }) });
|
|
1781
|
-
},
|
|
1790
|
+
}, kh = ({
|
|
1782
1791
|
name: e,
|
|
1783
1792
|
label: t,
|
|
1784
1793
|
variant: n = "secondary",
|
|
@@ -1791,7 +1800,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1791
1800
|
maxFiles: h,
|
|
1792
1801
|
...u
|
|
1793
1802
|
}) => {
|
|
1794
|
-
const [d, f] =
|
|
1803
|
+
const [d, f] = $(""), [m, x] = $(""), g = h || 3, y = "muncher-button" + (n ? " muncher-button--" + n : "") + (i ? " muncher-button--" + i : "") + (a ? " muncher-button--active" : ""), w = (b) => {
|
|
1795
1804
|
if (c) {
|
|
1796
1805
|
let M = Array.from(b.currentTarget.files);
|
|
1797
1806
|
M.length > g && (M = M.slice(0, g), x("Only first " + g + " files included")), o(M), f(M.map((S) => S.name).join(", "));
|
|
@@ -1824,7 +1833,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1824
1833
|
m !== "" ? /* @__PURE__ */ s.jsx("p", { className: "text-danger", children: m }) : "",
|
|
1825
1834
|
v() ? /* @__PURE__ */ s.jsx("div", { className: "muncher-input-error-message", children: /* @__PURE__ */ s.jsx(N, { name: "alert", children: l }) }) : ""
|
|
1826
1835
|
] });
|
|
1827
|
-
},
|
|
1836
|
+
}, wi = ({
|
|
1828
1837
|
name: e,
|
|
1829
1838
|
label: t,
|
|
1830
1839
|
required: n,
|
|
@@ -1848,10 +1857,10 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1848
1857
|
displayLoader: M,
|
|
1849
1858
|
...S
|
|
1850
1859
|
}) => {
|
|
1851
|
-
const E = () => f && f !== "",
|
|
1860
|
+
const E = () => f && f !== "", D = () => {
|
|
1852
1861
|
let T = "muncher-input";
|
|
1853
1862
|
return (r || a) && (T += " muncher-input-icon"), E() && (T += " muncher-input-error"), u === "side" && (T += " muncher-label-side"), T;
|
|
1854
|
-
}, P = () => t ? /* @__PURE__ */ s.jsx(nt, { label: t, required: n, id: e }) : "",
|
|
1863
|
+
}, P = () => t ? /* @__PURE__ */ s.jsx(nt, { label: t, required: n, id: e }) : "", I = (T) => {
|
|
1855
1864
|
T.key === "Enter" && b && b(), d && d(T);
|
|
1856
1865
|
};
|
|
1857
1866
|
return /* @__PURE__ */ s.jsxs("div", { className: "muncher-input--div", children: [
|
|
@@ -1868,7 +1877,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1868
1877
|
"input",
|
|
1869
1878
|
{
|
|
1870
1879
|
id: e,
|
|
1871
|
-
className:
|
|
1880
|
+
className: D(),
|
|
1872
1881
|
name: e,
|
|
1873
1882
|
autoFocus: m,
|
|
1874
1883
|
value: w,
|
|
@@ -1879,7 +1888,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1879
1888
|
required: n,
|
|
1880
1889
|
readOnly: i,
|
|
1881
1890
|
list: c,
|
|
1882
|
-
onKeyDown:
|
|
1891
|
+
onKeyDown: I,
|
|
1883
1892
|
onBlur: h,
|
|
1884
1893
|
step: y,
|
|
1885
1894
|
maxLength: v,
|
|
@@ -1891,7 +1900,27 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1891
1900
|
] }),
|
|
1892
1901
|
E() ? /* @__PURE__ */ s.jsx("div", { className: "muncher-input-error-message", children: /* @__PURE__ */ s.jsx(N, { name: "alert", children: f }) }) : ""
|
|
1893
1902
|
] });
|
|
1894
|
-
},
|
|
1903
|
+
}, Dh = ({ name: e, label: t, required: n, placeholder: i, onChange: r, value: a, error: o, labelPosition: l }) => {
|
|
1904
|
+
const [c, h] = $(!1), u = () => {
|
|
1905
|
+
h((d) => !d);
|
|
1906
|
+
};
|
|
1907
|
+
return /* @__PURE__ */ s.jsx(
|
|
1908
|
+
wi,
|
|
1909
|
+
{
|
|
1910
|
+
label: t,
|
|
1911
|
+
name: e,
|
|
1912
|
+
type: c ? "text" : "password",
|
|
1913
|
+
hoverIcon: c ? "eye" : "eye-off",
|
|
1914
|
+
value: a,
|
|
1915
|
+
required: n,
|
|
1916
|
+
placeholder: i,
|
|
1917
|
+
onChange: r,
|
|
1918
|
+
error: o,
|
|
1919
|
+
labelPosition: l,
|
|
1920
|
+
onHoverIconClick: u
|
|
1921
|
+
}
|
|
1922
|
+
);
|
|
1923
|
+
}, Rh = ({ name: e, required: t = !1, onChange: n, checked: i = !1, label: r, ...a }) => /* @__PURE__ */ s.jsx("div", { className: "muncher-input--div", children: /* @__PURE__ */ s.jsxs("div", { className: "muncher-radio", children: [
|
|
1895
1924
|
/* @__PURE__ */ s.jsx(
|
|
1896
1925
|
"input",
|
|
1897
1926
|
{
|
|
@@ -1950,7 +1979,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1950
1979
|
) }),
|
|
1951
1980
|
h() ? /* @__PURE__ */ s.jsx("div", { className: "muncher-input-error-message", children: /* @__PURE__ */ s.jsx(N, { name: "alert", children: a }) }) : ""
|
|
1952
1981
|
] });
|
|
1953
|
-
},
|
|
1982
|
+
}, Lh = ({
|
|
1954
1983
|
name: e,
|
|
1955
1984
|
label: t,
|
|
1956
1985
|
required: n,
|
|
@@ -1963,7 +1992,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1963
1992
|
value: h,
|
|
1964
1993
|
...u
|
|
1965
1994
|
}) => {
|
|
1966
|
-
const [d, f] =
|
|
1995
|
+
const [d, f] = $(h), m = (x) => {
|
|
1967
1996
|
f(x.target.value), c && c(x);
|
|
1968
1997
|
};
|
|
1969
1998
|
return /* @__PURE__ */ s.jsxs("div", { className: "muncher-input--div", children: [
|
|
@@ -1990,7 +2019,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
1990
2019
|
" characters left"
|
|
1991
2020
|
] })
|
|
1992
2021
|
] });
|
|
1993
|
-
},
|
|
2022
|
+
}, Nh = ({
|
|
1994
2023
|
name: e = "query",
|
|
1995
2024
|
focus: t = !1,
|
|
1996
2025
|
inputPlaceHolder: n,
|
|
@@ -2026,7 +2055,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2026
2055
|
};
|
|
2027
2056
|
}, [v, w]), /* @__PURE__ */ s.jsxs("div", { className: "muncher-input-drop-down", ref: g, children: [
|
|
2028
2057
|
/* @__PURE__ */ s.jsx(
|
|
2029
|
-
|
|
2058
|
+
wi,
|
|
2030
2059
|
{
|
|
2031
2060
|
focus: t,
|
|
2032
2061
|
placeholder: n,
|
|
@@ -2044,7 +2073,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2044
2073
|
),
|
|
2045
2074
|
r ? /* @__PURE__ */ s.jsx("div", { className: "muncher-input-drop-down--content", children: x }) : ""
|
|
2046
2075
|
] });
|
|
2047
|
-
},
|
|
2076
|
+
}, Fh = ({ children: e }) => /* @__PURE__ */ s.jsx("ul", { className: "muncher-ul", children: e }), Ih = ({ isFeatured: e, bulletIcon: t = "arrow-right", bulletWeight: n = 2, bulletSize: i = "small", bulletColor: r, children: a }) => /* @__PURE__ */ s.jsx("li", { className: e ? "muncher-li featured" : "muncher-li", children: /* @__PURE__ */ s.jsx(
|
|
2048
2077
|
N,
|
|
2049
2078
|
{
|
|
2050
2079
|
name: t,
|
|
@@ -2062,7 +2091,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2062
2091
|
}), [r]), je(() => {
|
|
2063
2092
|
e ? document.body.style.overflow = "hidden" : document.body.style.overflow = "unset";
|
|
2064
2093
|
}, [e]), /* @__PURE__ */ s.jsxs(gi.Fragment, { children: [
|
|
2065
|
-
/* @__PURE__ */ s.jsx(
|
|
2094
|
+
/* @__PURE__ */ s.jsx(go, { show: e, backdropClickHandler: () => t(!1) }),
|
|
2066
2095
|
/* @__PURE__ */ s.jsx(
|
|
2067
2096
|
"div",
|
|
2068
2097
|
{
|
|
@@ -2076,16 +2105,16 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2076
2105
|
}
|
|
2077
2106
|
)
|
|
2078
2107
|
] });
|
|
2079
|
-
},
|
|
2108
|
+
}, Bh = ({ showHoverEffect: e, onClick: t, children: n }) => {
|
|
2080
2109
|
const i = () => e ? "muncher-paper muncher-paper-hover" : "muncher-paper";
|
|
2081
2110
|
return /* @__PURE__ */ s.jsx("section", { className: i(), onClick: t, children: n });
|
|
2082
|
-
},
|
|
2111
|
+
}, zh = ({ pillCloseHandler: e, children: t, ...n }) => /* @__PURE__ */ s.jsxs("div", { className: "muncher-pill", ...n, children: [
|
|
2083
2112
|
/* @__PURE__ */ s.jsx("div", { className: "close", onClick: e, children: /* @__PURE__ */ s.jsx(N, { name: "close" }) }),
|
|
2084
2113
|
/* @__PURE__ */ s.jsxs("div", { className: "content", children: [
|
|
2085
2114
|
" ",
|
|
2086
2115
|
t
|
|
2087
2116
|
] })
|
|
2088
|
-
] }),
|
|
2117
|
+
] }), Hh = ({ value: e, max: t, label: n }) => {
|
|
2089
2118
|
const i = () => {
|
|
2090
2119
|
const r = Math.round(e / t * 100) + "%";
|
|
2091
2120
|
return n ? n + " " + r : r;
|
|
@@ -2094,11 +2123,11 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2094
2123
|
/* @__PURE__ */ s.jsx("label", { htmlFor: "progress", children: i() }),
|
|
2095
2124
|
/* @__PURE__ */ s.jsx("progress", { id: "progress", value: e, max: t, children: i() })
|
|
2096
2125
|
] });
|
|
2097
|
-
},
|
|
2126
|
+
}, _h = ({ variant: e, size: t, style: n }) => {
|
|
2098
2127
|
const i = "muncher-hr" + (e ? " muncher-hr--" + e : "") + (t ? " muncher-hr--" + t : "") + (n ? " muncher-hr--" + n : "");
|
|
2099
2128
|
return /* @__PURE__ */ s.jsx("hr", { className: i });
|
|
2100
|
-
},
|
|
2101
|
-
const [o, l] =
|
|
2129
|
+
}, Uh = ({ sliderItems: e, navButtonSize: t = "large", navButtonWeight: n = 2, variant: i, navIcon: r, navButtonPlacement: a = "inside" }) => {
|
|
2130
|
+
const [o, l] = $(0), [c, h] = $(0), u = () => e.length > 1 && o > 0 ? /* @__PURE__ */ s.jsx(
|
|
2102
2131
|
Qn,
|
|
2103
2132
|
{
|
|
2104
2133
|
direction: "left",
|
|
@@ -2142,7 +2171,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2142
2171
|
] }),
|
|
2143
2172
|
a === "outside" ? d() : ""
|
|
2144
2173
|
] });
|
|
2145
|
-
},
|
|
2174
|
+
}, Wh = ({
|
|
2146
2175
|
min: e,
|
|
2147
2176
|
max: t,
|
|
2148
2177
|
minValue: n,
|
|
@@ -2190,7 +2219,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2190
2219
|
/* @__PURE__ */ s.jsx("div", { className: "slider-max", children: h(t) })
|
|
2191
2220
|
] })
|
|
2192
2221
|
] });
|
|
2193
|
-
},
|
|
2222
|
+
}, $h = ({
|
|
2194
2223
|
min: e,
|
|
2195
2224
|
max: t,
|
|
2196
2225
|
value: n,
|
|
@@ -2222,7 +2251,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2222
2251
|
/* @__PURE__ */ s.jsx("div", { className: "slider-max", children: a(t) })
|
|
2223
2252
|
] })
|
|
2224
2253
|
] });
|
|
2225
|
-
},
|
|
2254
|
+
}, Kh = ({ isFeatured: e, onClick: t }) => /* @__PURE__ */ s.jsx("span", { className: "span-featured", children: /* @__PURE__ */ s.jsx("span", { className: e ? "featured-star" : "un-featured-star", onClick: t }) }), Gh = ({ rating: e, color: t, size: n, ...i }) => {
|
|
2226
2255
|
const r = {
|
|
2227
2256
|
"--r": e
|
|
2228
2257
|
}, a = () => {
|
|
@@ -2230,8 +2259,8 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2230
2259
|
return t && (o += " star-" + t), n && (o += " star-" + n), o;
|
|
2231
2260
|
};
|
|
2232
2261
|
return /* @__PURE__ */ s.jsx("span", { className: a(), style: r, ...i });
|
|
2233
|
-
},
|
|
2234
|
-
const [n, i] =
|
|
2262
|
+
}, Yh = ({ handleTabSelected: e, children: t }) => {
|
|
2263
|
+
const [n, i] = $(0), { tabs: r } = t, a = (o) => {
|
|
2235
2264
|
i(o), e && e(o);
|
|
2236
2265
|
};
|
|
2237
2266
|
return /* @__PURE__ */ s.jsxs("section", { className: "muncher-tabs", children: [
|
|
@@ -2264,7 +2293,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2264
2293
|
)
|
|
2265
2294
|
)
|
|
2266
2295
|
] });
|
|
2267
|
-
},
|
|
2296
|
+
}, Xh = ({
|
|
2268
2297
|
fileName: e,
|
|
2269
2298
|
defaultPageSize: t = 50,
|
|
2270
2299
|
skeleton: n,
|
|
@@ -2280,28 +2309,28 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2280
2309
|
footer: f,
|
|
2281
2310
|
children: m
|
|
2282
2311
|
}) => {
|
|
2283
|
-
const { header: x, rows: g } = m, [y, w] =
|
|
2312
|
+
const { header: x, rows: g } = m, [y, w] = $(r ?? { index: -1 }), [v, b] = $({ num: 0, size: t }), M = (T) => {
|
|
2284
2313
|
w(
|
|
2285
2314
|
(C) => C.index === T ? { ...C, desc: !C.desc } : { index: T }
|
|
2286
2315
|
);
|
|
2287
|
-
}, S =
|
|
2316
|
+
}, S = Ie(() => {
|
|
2288
2317
|
var F;
|
|
2289
2318
|
const T = [...g];
|
|
2290
2319
|
if (y.index < 0)
|
|
2291
2320
|
return T;
|
|
2292
2321
|
const C = (F = x[y.index]) == null ? void 0 : F.sort;
|
|
2293
|
-
return C ? T.sort(C) : T.sort((X,
|
|
2294
|
-
var Ee,
|
|
2295
|
-
const Q = ((
|
|
2322
|
+
return C ? T.sort(C) : T.sort((X, K) => {
|
|
2323
|
+
var Ee, O, _, j;
|
|
2324
|
+
const Q = ((O = (Ee = X[y.index]) == null ? void 0 : Ee.value) == null ? void 0 : O.toString().toLowerCase()) ?? "", q = ((j = (_ = K[y.index]) == null ? void 0 : _.value) == null ? void 0 : j.toString().toLowerCase()) ?? "";
|
|
2296
2325
|
return Q.localeCompare(q);
|
|
2297
2326
|
}), y.desc ? T.reverse() : T;
|
|
2298
|
-
}, [g, y, x]), E =
|
|
2327
|
+
}, [g, y, x]), E = Ie(
|
|
2299
2328
|
() => S.slice(v.num * v.size, (v.num + 1) * v.size),
|
|
2300
2329
|
[S, v]
|
|
2301
|
-
),
|
|
2330
|
+
), D = x.filter((T) => !T.csvExclude).map((T) => typeof T.name == "string" ? T.name : ""), P = g.map(
|
|
2302
2331
|
(T) => T.filter((C, F) => !x[F].csvExclude).map((C) => C.csv ?? C.value ?? "")
|
|
2303
|
-
),
|
|
2304
|
-
return /* @__PURE__ */ s.jsxs("section", { className:
|
|
2332
|
+
), I = "muncher-table" + (a ? " " + a : "");
|
|
2333
|
+
return /* @__PURE__ */ s.jsxs("section", { className: I, children: [
|
|
2305
2334
|
/* @__PURE__ */ s.jsx("div", { className: "row head", children: x.map(
|
|
2306
2335
|
(T, C) => T.visibility === "hidden" ? null : /* @__PURE__ */ s.jsx(
|
|
2307
2336
|
"div",
|
|
@@ -2309,7 +2338,7 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2309
2338
|
title: T.title,
|
|
2310
2339
|
className: T.visibility ? "col main" : "col",
|
|
2311
2340
|
children: typeof T.name == "string" ? /* @__PURE__ */ s.jsx("div", { className: "sort-button", children: /* @__PURE__ */ s.jsx(
|
|
2312
|
-
|
|
2341
|
+
Mo,
|
|
2313
2342
|
{
|
|
2314
2343
|
onClick: () => M(C),
|
|
2315
2344
|
active: y.index === C,
|
|
@@ -2335,17 +2364,17 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2335
2364
|
/* @__PURE__ */ s.jsxs("div", { className: "row-footer", children: [
|
|
2336
2365
|
/* @__PURE__ */ s.jsxs("div", { className: "row-footer-buttons", children: [
|
|
2337
2366
|
!o && /* @__PURE__ */ s.jsx(
|
|
2338
|
-
|
|
2367
|
+
To,
|
|
2339
2368
|
{
|
|
2340
2369
|
filename: e ?? "download",
|
|
2341
2370
|
variant: "secondary",
|
|
2342
2371
|
title: "Download",
|
|
2343
|
-
header:
|
|
2372
|
+
header: D,
|
|
2344
2373
|
data: P
|
|
2345
2374
|
}
|
|
2346
2375
|
),
|
|
2347
2376
|
l && /* @__PURE__ */ s.jsx(
|
|
2348
|
-
|
|
2377
|
+
So,
|
|
2349
2378
|
{
|
|
2350
2379
|
name: "csv-input-file",
|
|
2351
2380
|
handleOnChange: i,
|
|
@@ -2404,12 +2433,12 @@ const Ah = ({ variant: e, collapsed: t, className: n, children: i }) => {
|
|
|
2404
2433
|
] })
|
|
2405
2434
|
] })
|
|
2406
2435
|
] });
|
|
2407
|
-
},
|
|
2436
|
+
}, qh = ({ children: e }) => /* @__PURE__ */ s.jsx("div", { className: "muncher-card", children: e }), bi = ze({});
|
|
2408
2437
|
function Po(e) {
|
|
2409
2438
|
const t = fe(null);
|
|
2410
2439
|
return t.current === null && (t.current = e()), t.current;
|
|
2411
2440
|
}
|
|
2412
|
-
const Vo = typeof window < "u", Co = Vo ?
|
|
2441
|
+
const Vo = typeof window < "u", Co = Vo ? co : je, Tn = /* @__PURE__ */ ze(null);
|
|
2413
2442
|
function Mn(e, t) {
|
|
2414
2443
|
e.indexOf(t) === -1 && e.push(t);
|
|
2415
2444
|
}
|
|
@@ -2431,13 +2460,13 @@ typeof process < "u" && ((yi = process.env) == null ? void 0 : yi.NODE_ENV) !==
|
|
|
2431
2460
|
if (!e)
|
|
2432
2461
|
throw new Error(Zt(t, n));
|
|
2433
2462
|
});
|
|
2434
|
-
const ve = {},
|
|
2435
|
-
function
|
|
2463
|
+
const ve = {}, Ti = (e) => /^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);
|
|
2464
|
+
function Mi(e) {
|
|
2436
2465
|
return typeof e == "object" && e !== null;
|
|
2437
2466
|
}
|
|
2438
|
-
const
|
|
2467
|
+
const Si = (e) => /^0[^.\s]+$/u.test(e);
|
|
2439
2468
|
// @__NO_SIDE_EFFECTS__
|
|
2440
|
-
function
|
|
2469
|
+
function Ai(e) {
|
|
2441
2470
|
let t;
|
|
2442
2471
|
return () => (t === void 0 && (t = e()), t);
|
|
2443
2472
|
}
|
|
@@ -2471,45 +2500,45 @@ class Sn {
|
|
|
2471
2500
|
}
|
|
2472
2501
|
}
|
|
2473
2502
|
const te = /* @__NO_SIDE_EFFECTS__ */ (e) => e * 1e3, se = /* @__NO_SIDE_EFFECTS__ */ (e) => e / 1e3;
|
|
2474
|
-
function
|
|
2503
|
+
function Pi(e, t) {
|
|
2475
2504
|
return t ? e * (1e3 / t) : 0;
|
|
2476
2505
|
}
|
|
2477
2506
|
const es = /* @__PURE__ */ new Set();
|
|
2478
2507
|
function An(e, t, n) {
|
|
2479
2508
|
e || es.has(t) || (console.warn(Zt(t, n)), es.add(t));
|
|
2480
2509
|
}
|
|
2481
|
-
const
|
|
2510
|
+
const Vi = (e, t, n) => (((1 - 3 * n + 3 * t) * e + (3 * n - 6 * t)) * e + 3 * t) * e, ko = 1e-7, Do = 12;
|
|
2482
2511
|
function Ro(e, t, n, i, r) {
|
|
2483
2512
|
let a, o, l = 0;
|
|
2484
2513
|
do
|
|
2485
|
-
o = t + (n - t) / 2, a =
|
|
2486
|
-
while (Math.abs(a) >
|
|
2514
|
+
o = t + (n - t) / 2, a = Vi(o, i, r) - e, a > 0 ? n = o : t = o;
|
|
2515
|
+
while (Math.abs(a) > ko && ++l < Do);
|
|
2487
2516
|
return o;
|
|
2488
2517
|
}
|
|
2489
2518
|
function it(e, t, n, i) {
|
|
2490
2519
|
if (e === t && n === i)
|
|
2491
2520
|
return ie;
|
|
2492
2521
|
const r = (a) => Ro(a, 0, 1, e, n);
|
|
2493
|
-
return (a) => a === 0 || a === 1 ? a :
|
|
2522
|
+
return (a) => a === 0 || a === 1 ? a : Vi(r(a), t, i);
|
|
2494
2523
|
}
|
|
2495
|
-
const
|
|
2524
|
+
const Ci = (e) => (t) => t <= 0.5 ? e(2 * t) / 2 : (2 - e(2 * (1 - t))) / 2, Ei = (e) => (t) => 1 - e(1 - t), ki = /* @__PURE__ */ it(0.33, 1.53, 0.69, 0.99), Pn = /* @__PURE__ */ Ei(ki), Di = /* @__PURE__ */ Ci(Pn), Ri = (e) => e >= 1 ? 1 : (e *= 2) < 1 ? 0.5 * Pn(e) : 0.5 * (2 - Math.pow(2, -10 * (e - 1))), Vn = (e) => 1 - Math.sin(Math.acos(e)), Li = Ei(Vn), Ni = Ci(Vn), Lo = /* @__PURE__ */ it(0.42, 0, 1, 1), No = /* @__PURE__ */ it(0, 0, 0.58, 1), Fi = /* @__PURE__ */ it(0.42, 0, 0.58, 1), Fo = (e) => Array.isArray(e) && typeof e[0] != "number", Ii = (e) => Array.isArray(e) && typeof e[0] == "number", ts = {
|
|
2496
2525
|
linear: ie,
|
|
2497
2526
|
easeIn: Lo,
|
|
2498
|
-
easeInOut:
|
|
2527
|
+
easeInOut: Fi,
|
|
2499
2528
|
easeOut: No,
|
|
2500
2529
|
circIn: Vn,
|
|
2501
|
-
circInOut:
|
|
2502
|
-
circOut:
|
|
2530
|
+
circInOut: Ni,
|
|
2531
|
+
circOut: Li,
|
|
2503
2532
|
backIn: Pn,
|
|
2504
2533
|
backInOut: Di,
|
|
2505
|
-
backOut:
|
|
2506
|
-
anticipate:
|
|
2507
|
-
},
|
|
2508
|
-
if (
|
|
2534
|
+
backOut: ki,
|
|
2535
|
+
anticipate: Ri
|
|
2536
|
+
}, Io = (e) => typeof e == "string", ns = (e) => {
|
|
2537
|
+
if (Ii(e)) {
|
|
2509
2538
|
pe(e.length === 4, "Cubic bezier arrays must contain four numerical values.", "cubic-bezier-length");
|
|
2510
2539
|
const [t, n, i, r] = e;
|
|
2511
2540
|
return it(t, n, i, r);
|
|
2512
|
-
} else if (
|
|
2541
|
+
} else if (Io(e))
|
|
2513
2542
|
return pe(ts[e] !== void 0, `Invalid easing type '${e}'`, "invalid-easing-type"), ts[e];
|
|
2514
2543
|
return e;
|
|
2515
2544
|
}, ct = [
|
|
@@ -2530,7 +2559,7 @@ const Vi = (e) => (t) => t <= 0.5 ? e(2 * t) / 2 : (2 - e(2 * (1 - t))) / 2, Ci
|
|
|
2530
2559
|
"postRender"
|
|
2531
2560
|
// Compute
|
|
2532
2561
|
];
|
|
2533
|
-
function
|
|
2562
|
+
function Oo(e, t) {
|
|
2534
2563
|
let n = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Set(), r = !1, a = !1;
|
|
2535
2564
|
const o = /* @__PURE__ */ new WeakSet();
|
|
2536
2565
|
let l = {
|
|
@@ -2577,7 +2606,7 @@ function Oi(e, t) {
|
|
|
2577
2606
|
delta: 0,
|
|
2578
2607
|
timestamp: 0,
|
|
2579
2608
|
isProcessing: !1
|
|
2580
|
-
}, a = () => n = !0, o = ct.reduce((b, M) => (b[M] =
|
|
2609
|
+
}, a = () => n = !0, o = ct.reduce((b, M) => (b[M] = Oo(a), b), {}), { setup: l, read: c, resolveKeyframes: h, preUpdate: u, update: d, preRender: f, render: m, postRender: x } = o, g = () => {
|
|
2581
2610
|
const b = ve.useManualTiming, M = b ? r.timestamp : performance.now();
|
|
2582
2611
|
n = !1, b || (r.delta = i ? 1e3 / 60 : Math.max(Math.min(M - r.timestamp, Bo), 1)), r.timestamp = M, r.isProcessing = !0, l.process(r), c.process(r), h.process(r), u.process(r), d.process(r), f.process(r), m.process(r), x.process(r), r.isProcessing = !1, n && t && (i = !1, e(g));
|
|
2583
2612
|
}, y = () => {
|
|
@@ -2585,13 +2614,13 @@ function Oi(e, t) {
|
|
|
2585
2614
|
};
|
|
2586
2615
|
return { schedule: ct.reduce((b, M) => {
|
|
2587
2616
|
const S = o[M];
|
|
2588
|
-
return b[M] = (E,
|
|
2617
|
+
return b[M] = (E, D = !1, P = !1) => (n || y(), S.schedule(E, D, P)), b;
|
|
2589
2618
|
}, {}), cancel: (b) => {
|
|
2590
2619
|
for (let M = 0; M < ct.length; M++)
|
|
2591
2620
|
o[ct[M]].cancel(b);
|
|
2592
2621
|
}, state: r, steps: o };
|
|
2593
2622
|
}
|
|
2594
|
-
const { schedule:
|
|
2623
|
+
const { schedule: k, cancel: we, state: U, steps: Ft } = /* @__PURE__ */ Oi(typeof requestAnimationFrame < "u" ? requestAnimationFrame : ie, !0);
|
|
2595
2624
|
let ft;
|
|
2596
2625
|
function zo() {
|
|
2597
2626
|
ft = void 0;
|
|
@@ -2601,7 +2630,7 @@ const Z = {
|
|
|
2601
2630
|
set: (e) => {
|
|
2602
2631
|
ft = e, queueMicrotask(zo);
|
|
2603
2632
|
}
|
|
2604
|
-
},
|
|
2633
|
+
}, Bi = (e) => (t) => typeof t == "string" && t.startsWith(e), zi = /* @__PURE__ */ Bi("--"), Ho = /* @__PURE__ */ Bi("var(--"), Cn = (e) => Ho(e) ? _o.test(e.split("/*")[0].trim()) : !1, _o = /var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;
|
|
2605
2634
|
function ss(e) {
|
|
2606
2635
|
return typeof e != "string" ? !1 : e.split("/*")[0].includes("var(--");
|
|
2607
2636
|
}
|
|
@@ -2619,7 +2648,7 @@ const _e = {
|
|
|
2619
2648
|
function Uo(e) {
|
|
2620
2649
|
return e == null;
|
|
2621
2650
|
}
|
|
2622
|
-
const Wo = /^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,
|
|
2651
|
+
const Wo = /^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu, kn = (e, t) => (n) => !!(typeof n == "string" && Wo.test(n) && n.startsWith(e) || t && !Uo(n) && Object.prototype.hasOwnProperty.call(n, t)), Hi = (e, t, n) => (i) => {
|
|
2623
2652
|
if (typeof i != "string")
|
|
2624
2653
|
return i;
|
|
2625
2654
|
const [r, a, o, l] = i.match(En);
|
|
@@ -2629,13 +2658,13 @@ const Wo = /^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s
|
|
|
2629
2658
|
[n]: parseFloat(o),
|
|
2630
2659
|
alpha: l !== void 0 ? parseFloat(l) : 1
|
|
2631
2660
|
};
|
|
2632
|
-
}, $o = (e) => de(0, 255, e),
|
|
2661
|
+
}, $o = (e) => de(0, 255, e), It = {
|
|
2633
2662
|
..._e,
|
|
2634
2663
|
transform: (e) => Math.round($o(e))
|
|
2635
2664
|
}, Se = {
|
|
2636
|
-
test: /* @__PURE__ */
|
|
2637
|
-
parse: /* @__PURE__ */
|
|
2638
|
-
transform: ({ red: e, green: t, blue: n, alpha: i = 1 }) => "rgba(" +
|
|
2665
|
+
test: /* @__PURE__ */ kn("rgb", "red"),
|
|
2666
|
+
parse: /* @__PURE__ */ Hi("red", "green", "blue"),
|
|
2667
|
+
transform: ({ red: e, green: t, blue: n, alpha: i = 1 }) => "rgba(" + It.transform(e) + ", " + It.transform(t) + ", " + It.transform(n) + ", " + Xe(Qe.transform(i)) + ")"
|
|
2639
2668
|
};
|
|
2640
2669
|
function Ko(e) {
|
|
2641
2670
|
let t = "", n = "", i = "", r = "";
|
|
@@ -2647,7 +2676,7 @@ function Ko(e) {
|
|
|
2647
2676
|
};
|
|
2648
2677
|
}
|
|
2649
2678
|
const Jt = {
|
|
2650
|
-
test: /* @__PURE__ */
|
|
2679
|
+
test: /* @__PURE__ */ kn("#"),
|
|
2651
2680
|
parse: Ko,
|
|
2652
2681
|
transform: Se.transform
|
|
2653
2682
|
}, rt = /* @__NO_SIDE_EFFECTS__ */ (e) => ({
|
|
@@ -2659,8 +2688,8 @@ const Jt = {
|
|
|
2659
2688
|
parse: (e) => he.parse(e) / 100,
|
|
2660
2689
|
transform: (e) => he.transform(e * 100)
|
|
2661
2690
|
}, Re = {
|
|
2662
|
-
test: /* @__PURE__ */
|
|
2663
|
-
parse: /* @__PURE__ */
|
|
2691
|
+
test: /* @__PURE__ */ kn("hsl", "hue"),
|
|
2692
|
+
parse: /* @__PURE__ */ Hi("hue", "saturation", "lightness"),
|
|
2664
2693
|
transform: ({ hue: e, saturation: t, lightness: n, alpha: i = 1 }) => "hsla(" + Math.round(e) + ", " + he.transform(Xe(t)) + ", " + he.transform(Xe(n)) + ", " + Xe(Qe.transform(i)) + ")"
|
|
2665
2694
|
}, z = {
|
|
2666
2695
|
test: (e) => Se.test(e) || Jt.test(e) || Re.test(e),
|
|
@@ -2675,39 +2704,39 @@ function qo(e) {
|
|
|
2675
2704
|
var t, n;
|
|
2676
2705
|
return isNaN(e) && typeof e == "string" && (((t = e.match(En)) == null ? void 0 : t.length) || 0) + (((n = e.match(Xo)) == null ? void 0 : n.length) || 0) > 0;
|
|
2677
2706
|
}
|
|
2678
|
-
const
|
|
2679
|
-
function
|
|
2707
|
+
const _i = "number", Ui = "color", Zo = "var", Jo = "var(", rs = "${}", Qo = /var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;
|
|
2708
|
+
function Oe(e) {
|
|
2680
2709
|
const t = e.toString(), n = [], i = {
|
|
2681
2710
|
color: [],
|
|
2682
2711
|
number: [],
|
|
2683
2712
|
var: []
|
|
2684
2713
|
}, r = [];
|
|
2685
2714
|
let a = 0;
|
|
2686
|
-
const l = t.replace(Qo, (c) => (z.test(c) ? (i.color.push(a), r.push(
|
|
2715
|
+
const l = t.replace(Qo, (c) => (z.test(c) ? (i.color.push(a), r.push(Ui), n.push(z.parse(c))) : c.startsWith(Jo) ? (i.var.push(a), r.push(Zo), n.push(c)) : (i.number.push(a), r.push(_i), n.push(parseFloat(c))), ++a, rs)).split(rs);
|
|
2687
2716
|
return { values: n, split: l, indexes: i, types: r };
|
|
2688
2717
|
}
|
|
2689
2718
|
function ea(e) {
|
|
2690
|
-
return
|
|
2719
|
+
return Oe(e).values;
|
|
2691
2720
|
}
|
|
2692
|
-
function
|
|
2721
|
+
function Wi({ split: e, types: t }) {
|
|
2693
2722
|
const n = e.length;
|
|
2694
2723
|
return (i) => {
|
|
2695
2724
|
let r = "";
|
|
2696
2725
|
for (let a = 0; a < n; a++)
|
|
2697
2726
|
if (r += e[a], i[a] !== void 0) {
|
|
2698
2727
|
const o = t[a];
|
|
2699
|
-
o ===
|
|
2728
|
+
o === _i ? r += Xe(i[a]) : o === Ui ? r += z.transform(i[a]) : r += i[a];
|
|
2700
2729
|
}
|
|
2701
2730
|
return r;
|
|
2702
2731
|
};
|
|
2703
2732
|
}
|
|
2704
2733
|
function ta(e) {
|
|
2705
|
-
return
|
|
2734
|
+
return Wi(Oe(e));
|
|
2706
2735
|
}
|
|
2707
2736
|
const na = (e) => typeof e == "number" ? 0 : z.test(e) ? z.getAnimatableNone(e) : e, sa = (e, t) => typeof e == "number" ? t != null && t.trim().endsWith("/") ? e : 0 : na(e);
|
|
2708
2737
|
function ia(e) {
|
|
2709
|
-
const t =
|
|
2710
|
-
return
|
|
2738
|
+
const t = Oe(e);
|
|
2739
|
+
return Wi(t)(t.values.map((i, r) => sa(i, t.split[r])));
|
|
2711
2740
|
}
|
|
2712
2741
|
const ae = {
|
|
2713
2742
|
test: qo,
|
|
@@ -2715,7 +2744,7 @@ const ae = {
|
|
|
2715
2744
|
createTransformer: ta,
|
|
2716
2745
|
getAnimatableNone: ia
|
|
2717
2746
|
};
|
|
2718
|
-
function
|
|
2747
|
+
function Ot(e, t, n) {
|
|
2719
2748
|
return n < 0 && (n += 1), n > 1 && (n -= 1), n < 1 / 6 ? e + (t - e) * 6 * n : n < 1 / 2 ? t : n < 2 / 3 ? e + (t - e) * (2 / 3 - n) * 6 : e;
|
|
2720
2749
|
}
|
|
2721
2750
|
function ra({ hue: e, saturation: t, lightness: n, alpha: i }) {
|
|
@@ -2725,7 +2754,7 @@ function ra({ hue: e, saturation: t, lightness: n, alpha: i }) {
|
|
|
2725
2754
|
r = a = o = n;
|
|
2726
2755
|
else {
|
|
2727
2756
|
const l = n < 0.5 ? n * (1 + t) : n + t - n * t, c = 2 * n - l;
|
|
2728
|
-
r =
|
|
2757
|
+
r = Ot(c, l, e + 1 / 3), a = Ot(c, l, e), o = Ot(c, l, e - 1 / 3);
|
|
2729
2758
|
}
|
|
2730
2759
|
return {
|
|
2731
2760
|
red: Math.round(r * 255),
|
|
@@ -2761,11 +2790,11 @@ function la(e, t) {
|
|
|
2761
2790
|
function ca(e, t) {
|
|
2762
2791
|
return (n) => L(e, t, n);
|
|
2763
2792
|
}
|
|
2764
|
-
function
|
|
2765
|
-
return typeof e == "number" ? ca : typeof e == "string" ? Cn(e) ? wt : z.test(e) ? as : da : Array.isArray(e) ?
|
|
2793
|
+
function Dn(e) {
|
|
2794
|
+
return typeof e == "number" ? ca : typeof e == "string" ? Cn(e) ? wt : z.test(e) ? as : da : Array.isArray(e) ? $i : typeof e == "object" ? z.test(e) ? as : ua : wt;
|
|
2766
2795
|
}
|
|
2767
|
-
function
|
|
2768
|
-
const n = [...e], i = n.length, r = e.map((a, o) =>
|
|
2796
|
+
function $i(e, t) {
|
|
2797
|
+
const n = [...e], i = n.length, r = e.map((a, o) => Dn(a)(a, t[o]));
|
|
2769
2798
|
return (a) => {
|
|
2770
2799
|
for (let o = 0; o < i; o++)
|
|
2771
2800
|
n[o] = r[o](a);
|
|
@@ -2775,7 +2804,7 @@ function Wi(e, t) {
|
|
|
2775
2804
|
function ua(e, t) {
|
|
2776
2805
|
const n = { ...e, ...t }, i = {};
|
|
2777
2806
|
for (const r in n)
|
|
2778
|
-
e[r] !== void 0 && t[r] !== void 0 && (i[r] =
|
|
2807
|
+
e[r] !== void 0 && t[r] !== void 0 && (i[r] = Dn(e[r])(e[r], t[r]));
|
|
2779
2808
|
return (r) => {
|
|
2780
2809
|
for (const a in i)
|
|
2781
2810
|
n[a] = i[a](r);
|
|
@@ -2791,16 +2820,16 @@ function ha(e, t) {
|
|
|
2791
2820
|
return n;
|
|
2792
2821
|
}
|
|
2793
2822
|
const da = (e, t) => {
|
|
2794
|
-
const n = ae.createTransformer(t), i =
|
|
2795
|
-
return i.indexes.var.length === r.indexes.var.length && i.indexes.color.length === r.indexes.color.length && i.indexes.number.length >= r.indexes.number.length ? Qt.has(e) && !r.values.length || Qt.has(t) && !i.values.length ? la(e, t) : st(
|
|
2823
|
+
const n = ae.createTransformer(t), i = Oe(e), r = Oe(t);
|
|
2824
|
+
return i.indexes.var.length === r.indexes.var.length && i.indexes.color.length === r.indexes.color.length && i.indexes.number.length >= r.indexes.number.length ? Qt.has(e) && !r.values.length || Qt.has(t) && !i.values.length ? la(e, t) : st($i(ha(i, r), r.values), n) : (He(!0, `Complex values '${e}' and '${t}' 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.`, "complex-values-different"), wt(e, t));
|
|
2796
2825
|
};
|
|
2797
|
-
function
|
|
2798
|
-
return typeof e == "number" && typeof t == "number" && typeof n == "number" ? L(e, t, n) :
|
|
2826
|
+
function Ki(e, t, n) {
|
|
2827
|
+
return typeof e == "number" && typeof t == "number" && typeof n == "number" ? L(e, t, n) : Dn(e)(e, t);
|
|
2799
2828
|
}
|
|
2800
2829
|
const fa = (e) => {
|
|
2801
2830
|
const t = ({ timestamp: n }) => e(n);
|
|
2802
2831
|
return {
|
|
2803
|
-
start: (n = !0) =>
|
|
2832
|
+
start: (n = !0) => k.update(t, n),
|
|
2804
2833
|
stop: () => we(t),
|
|
2805
2834
|
/**
|
|
2806
2835
|
* If we're processing this frame we can use the
|
|
@@ -2808,7 +2837,7 @@ const fa = (e) => {
|
|
|
2808
2837
|
*/
|
|
2809
2838
|
now: () => U.isProcessing ? U.timestamp : Z.now()
|
|
2810
2839
|
};
|
|
2811
|
-
},
|
|
2840
|
+
}, Gi = (e, t, n = 10) => {
|
|
2812
2841
|
let i = "";
|
|
2813
2842
|
const r = Math.max(Math.round(t / n), 2);
|
|
2814
2843
|
for (let a = 0; a < r; a++)
|
|
@@ -2948,34 +2977,34 @@ function Tt(e = B.visualDuration, t = B.bounce) {
|
|
|
2948
2977
|
velocity: -/* @__PURE__ */ se(n.velocity || 0)
|
|
2949
2978
|
}), x = f || 0, g = h / (2 * Math.sqrt(c * u)), y = o - a, w = /* @__PURE__ */ se(Math.sqrt(c / u)), v = Math.abs(y) < 5;
|
|
2950
2979
|
i || (i = v ? B.restSpeed.granular : B.restSpeed.default), r || (r = v ? B.restDelta.granular : B.restDelta.default);
|
|
2951
|
-
let b, M, S, E,
|
|
2980
|
+
let b, M, S, E, D, P;
|
|
2952
2981
|
if (g < 1)
|
|
2953
2982
|
S = en(w, g), E = (x + g * w * y) / S, b = (T) => {
|
|
2954
2983
|
const C = Math.exp(-g * w * T);
|
|
2955
2984
|
return o - C * (E * Math.sin(S * T) + y * Math.cos(S * T));
|
|
2956
|
-
},
|
|
2985
|
+
}, D = g * w * E + y * S, P = g * w * y - E * S, M = (T) => Math.exp(-g * w * T) * (D * Math.sin(S * T) + P * Math.cos(S * T));
|
|
2957
2986
|
else if (g === 1) {
|
|
2958
2987
|
b = (C) => o - Math.exp(-w * C) * (y + (x + w * y) * C);
|
|
2959
2988
|
const T = x + w * y;
|
|
2960
2989
|
M = (C) => Math.exp(-w * C) * (w * T * C - x);
|
|
2961
2990
|
} else {
|
|
2962
2991
|
const T = w * Math.sqrt(g * g - 1);
|
|
2963
|
-
b = (
|
|
2964
|
-
const Q = Math.exp(-g * w *
|
|
2992
|
+
b = (K) => {
|
|
2993
|
+
const Q = Math.exp(-g * w * K), q = Math.min(T * K, 300);
|
|
2965
2994
|
return o - Q * ((x + g * w * y) * Math.sinh(q) + T * y * Math.cosh(q)) / T;
|
|
2966
2995
|
};
|
|
2967
2996
|
const C = (x + g * w * y) / T, F = g * w * C - y * T, X = g * w * y - C * T;
|
|
2968
|
-
M = (
|
|
2969
|
-
const Q = Math.exp(-g * w *
|
|
2997
|
+
M = (K) => {
|
|
2998
|
+
const Q = Math.exp(-g * w * K), q = Math.min(T * K, 300);
|
|
2970
2999
|
return Q * (F * Math.sinh(q) + X * Math.cosh(q));
|
|
2971
3000
|
};
|
|
2972
3001
|
}
|
|
2973
|
-
const
|
|
3002
|
+
const I = {
|
|
2974
3003
|
calculatedDuration: m && d || null,
|
|
2975
3004
|
velocity: (T) => /* @__PURE__ */ te(M(T)),
|
|
2976
3005
|
next: (T) => {
|
|
2977
3006
|
if (!m && g < 1) {
|
|
2978
|
-
const F = Math.exp(-g * w * T), X = Math.sin(S * T),
|
|
3007
|
+
const F = Math.exp(-g * w * T), X = Math.sin(S * T), K = Math.cos(S * T), Q = o - F * (E * X + y * K), q = /* @__PURE__ */ te(F * (D * X + P * K));
|
|
2979
3008
|
return l.done = Math.abs(q) <= i && Math.abs(o - Q) <= r, l.value = l.done ? o : Q, l;
|
|
2980
3009
|
}
|
|
2981
3010
|
const C = b(T);
|
|
@@ -2988,22 +3017,22 @@ function Tt(e = B.visualDuration, t = B.bounce) {
|
|
|
2988
3017
|
return l.value = l.done ? o : C, l;
|
|
2989
3018
|
},
|
|
2990
3019
|
toString: () => {
|
|
2991
|
-
const T = Math.min(Rn(
|
|
3020
|
+
const T = Math.min(Rn(I), bt), C = Gi((F) => I.next(T * F).value, T, 30);
|
|
2992
3021
|
return T + "ms " + C;
|
|
2993
3022
|
},
|
|
2994
3023
|
toTransition: () => {
|
|
2995
3024
|
}
|
|
2996
3025
|
};
|
|
2997
|
-
return
|
|
3026
|
+
return I;
|
|
2998
3027
|
}
|
|
2999
3028
|
Tt.applyToOptions = (e) => {
|
|
3000
3029
|
const t = pa(e, 100, Tt);
|
|
3001
3030
|
return e.ease = t.ease, e.duration = /* @__PURE__ */ te(t.duration), e.type = "keyframes", e;
|
|
3002
3031
|
};
|
|
3003
3032
|
const wa = 5;
|
|
3004
|
-
function
|
|
3033
|
+
function Yi(e, t, n) {
|
|
3005
3034
|
const i = Math.max(t - wa, 0);
|
|
3006
|
-
return
|
|
3035
|
+
return Pi(n - e(i), t - i);
|
|
3007
3036
|
}
|
|
3008
3037
|
function tn({ keyframes: e, velocity: t = 0, power: n = 0.8, timeConstant: i = 325, bounceDamping: r = 10, bounceStiffness: a = 500, modifyTarget: o, min: l, max: c, restDelta: h = 0.5, restSpeed: u }) {
|
|
3009
3038
|
const d = e[0], f = {
|
|
@@ -3014,14 +3043,14 @@ function tn({ keyframes: e, velocity: t = 0, power: n = 0.8, timeConstant: i = 3
|
|
|
3014
3043
|
const y = d + g, w = o === void 0 ? y : o(y);
|
|
3015
3044
|
w !== y && (g = w - d);
|
|
3016
3045
|
const v = (P) => -g * Math.exp(-P / i), b = (P) => w + v(P), M = (P) => {
|
|
3017
|
-
const
|
|
3018
|
-
f.done = Math.abs(
|
|
3046
|
+
const I = v(P), T = b(P);
|
|
3047
|
+
f.done = Math.abs(I) <= h, f.value = f.done ? w : T;
|
|
3019
3048
|
};
|
|
3020
3049
|
let S, E;
|
|
3021
|
-
const
|
|
3050
|
+
const D = (P) => {
|
|
3022
3051
|
m(f.value) && (S = P, E = Tt({
|
|
3023
3052
|
keyframes: [f.value, x(f.value)],
|
|
3024
|
-
velocity:
|
|
3053
|
+
velocity: Yi(b, P, f.value),
|
|
3025
3054
|
// TODO: This should be passing * 1000
|
|
3026
3055
|
damping: r,
|
|
3027
3056
|
stiffness: a,
|
|
@@ -3029,16 +3058,16 @@ function tn({ keyframes: e, velocity: t = 0, power: n = 0.8, timeConstant: i = 3
|
|
|
3029
3058
|
restSpeed: u
|
|
3030
3059
|
}));
|
|
3031
3060
|
};
|
|
3032
|
-
return
|
|
3061
|
+
return D(0), {
|
|
3033
3062
|
calculatedDuration: null,
|
|
3034
3063
|
next: (P) => {
|
|
3035
|
-
let
|
|
3036
|
-
return !E && S === void 0 && (
|
|
3064
|
+
let I = !1;
|
|
3065
|
+
return !E && S === void 0 && (I = !0, M(P), D(P)), S !== void 0 && P >= S ? E.next(P - S) : (!I && M(P), f);
|
|
3037
3066
|
}
|
|
3038
3067
|
};
|
|
3039
3068
|
}
|
|
3040
3069
|
function ba(e, t, n) {
|
|
3041
|
-
const i = [], r = n || ve.mix ||
|
|
3070
|
+
const i = [], r = n || ve.mix || Ki, a = e.length - 1;
|
|
3042
3071
|
for (let o = 0; o < a; o++) {
|
|
3043
3072
|
let l = r(e[o], e[o + 1]);
|
|
3044
3073
|
if (t) {
|
|
@@ -3084,7 +3113,7 @@ function Aa(e, t) {
|
|
|
3084
3113
|
return e.map((n) => n * t);
|
|
3085
3114
|
}
|
|
3086
3115
|
function Pa(e, t) {
|
|
3087
|
-
return e.map(() => t ||
|
|
3116
|
+
return e.map(() => t || Fi).splice(0, e.length - 1);
|
|
3088
3117
|
}
|
|
3089
3118
|
function Le({ duration: e = 300, keyframes: t, times: n, ease: i = "easeInOut" }) {
|
|
3090
3119
|
const r = Fo(i) ? i.map(ns) : ns(i), a = {
|
|
@@ -3115,7 +3144,7 @@ const Ca = {
|
|
|
3115
3144
|
keyframes: Le,
|
|
3116
3145
|
spring: Tt
|
|
3117
3146
|
};
|
|
3118
|
-
function
|
|
3147
|
+
function Xi(e) {
|
|
3119
3148
|
typeof e.type == "string" && (e.type = Ca[e.type]);
|
|
3120
3149
|
}
|
|
3121
3150
|
class Ln {
|
|
@@ -3156,11 +3185,11 @@ class Mt extends Ln {
|
|
|
3156
3185
|
}
|
|
3157
3186
|
initAnimation() {
|
|
3158
3187
|
const { options: t } = this;
|
|
3159
|
-
|
|
3188
|
+
Xi(t);
|
|
3160
3189
|
const { type: n = Le, repeat: i = 0, repeatDelay: r = 0, repeatType: a, velocity: o = 0 } = t;
|
|
3161
3190
|
let { keyframes: l } = t;
|
|
3162
3191
|
const c = n || Le;
|
|
3163
|
-
process.env.NODE_ENV !== "production" && c !== Le && pe(l.length <= 2, `Only two keyframes currently supported with spring and inertia animations. Trying to animate ${l}`, "spring-two-frames"), c !== Le && typeof l[0] != "number" && (this.mixKeyframes = st(Ea,
|
|
3192
|
+
process.env.NODE_ENV !== "production" && c !== Le && pe(l.length <= 2, `Only two keyframes currently supported with spring and inertia animations. Trying to animate ${l}`, "spring-two-frames"), c !== Le && typeof l[0] != "number" && (this.mixKeyframes = st(Ea, Ki(l[0], l[1])), l = [0, 100]);
|
|
3164
3193
|
const h = c({ ...t, keyframes: l });
|
|
3165
3194
|
a === "mirror" && (this.mirroredGenerator = c({
|
|
3166
3195
|
...t,
|
|
@@ -3185,15 +3214,15 @@ class Mt extends Ln {
|
|
|
3185
3214
|
let b = this.currentTime, M = i;
|
|
3186
3215
|
if (d) {
|
|
3187
3216
|
const P = Math.min(this.currentTime, r) / l;
|
|
3188
|
-
let
|
|
3189
|
-
!T && P >= 1 && (T = 1), T === 1 &&
|
|
3217
|
+
let I = Math.floor(P), T = P % 1;
|
|
3218
|
+
!T && P >= 1 && (T = 1), T === 1 && I--, I = Math.min(I, d + 1), !!(I % 2) && (f === "reverse" ? (T = 1 - T, m && (T -= m / l)) : f === "mirror" && (M = o)), b = de(0, 1, T) * l;
|
|
3190
3219
|
}
|
|
3191
3220
|
let S;
|
|
3192
3221
|
v ? (this.delayState.value = u[0], S = this.delayState) : S = M.next(b), a && !v && (S.value = a(S.value));
|
|
3193
3222
|
let { done: E } = S;
|
|
3194
3223
|
!v && c !== null && (E = this.playbackSpeed >= 0 ? this.currentTime >= r : this.currentTime <= 0);
|
|
3195
|
-
const
|
|
3196
|
-
return
|
|
3224
|
+
const D = this.holdTime === null && (this.state === "finished" || this.state === "running" && E);
|
|
3225
|
+
return D && x !== tn && (S.value = Ct(u, this.options, y, this.speed)), g && g(S.value), D && this.finish(), S;
|
|
3197
3226
|
}
|
|
3198
3227
|
/**
|
|
3199
3228
|
* Allows the returned animation to be awaited or promise-chained. Currently
|
|
@@ -3228,7 +3257,7 @@ class Mt extends Ln {
|
|
|
3228
3257
|
if (this.generator.velocity)
|
|
3229
3258
|
return this.generator.velocity(t);
|
|
3230
3259
|
const n = this.generator.next(t).value;
|
|
3231
|
-
return
|
|
3260
|
+
return Yi((i) => this.generator.next(i).value, t, n);
|
|
3232
3261
|
}
|
|
3233
3262
|
get speed() {
|
|
3234
3263
|
return this.playbackSpeed;
|
|
@@ -3274,14 +3303,14 @@ class Mt extends Ln {
|
|
|
3274
3303
|
return this.options.allowFlatten && (this.options.type = "keyframes", this.options.ease = "linear", this.initAnimation()), (n = this.driver) == null || n.stop(), t.observe(this);
|
|
3275
3304
|
}
|
|
3276
3305
|
}
|
|
3277
|
-
function
|
|
3306
|
+
function ka(e) {
|
|
3278
3307
|
for (let t = 1; t < e.length; t++)
|
|
3279
3308
|
e[t] ?? (e[t] = e[t - 1]);
|
|
3280
3309
|
}
|
|
3281
3310
|
const Ae = (e) => e * 180 / Math.PI, nn = (e) => {
|
|
3282
3311
|
const t = Ae(Math.atan2(e[1], e[0]));
|
|
3283
3312
|
return sn(t);
|
|
3284
|
-
},
|
|
3313
|
+
}, Da = {
|
|
3285
3314
|
x: 4,
|
|
3286
3315
|
y: 5,
|
|
3287
3316
|
translateX: 4,
|
|
@@ -3324,7 +3353,7 @@ function on(e, t) {
|
|
|
3324
3353
|
i = Ra, r = n;
|
|
3325
3354
|
else {
|
|
3326
3355
|
const l = e.match(/^matrix\(([-\d.e\s,]+)\)$/u);
|
|
3327
|
-
i =
|
|
3356
|
+
i = Da, r = l;
|
|
3328
3357
|
}
|
|
3329
3358
|
if (!r)
|
|
3330
3359
|
return rn(t);
|
|
@@ -3356,10 +3385,10 @@ const Ue = [
|
|
|
3356
3385
|
"skew",
|
|
3357
3386
|
"skewX",
|
|
3358
3387
|
"skewY"
|
|
3359
|
-
], We = new Set(Ue), fs = (e) => e === _e || e === A, Fa = /* @__PURE__ */ new Set(["x", "y", "z"]),
|
|
3360
|
-
function
|
|
3388
|
+
], We = new Set(Ue), fs = (e) => e === _e || e === A, Fa = /* @__PURE__ */ new Set(["x", "y", "z"]), Ia = Ue.filter((e) => !Fa.has(e));
|
|
3389
|
+
function Oa(e) {
|
|
3361
3390
|
const t = [];
|
|
3362
|
-
return
|
|
3391
|
+
return Ia.forEach((n) => {
|
|
3363
3392
|
const i = e.getValue(n);
|
|
3364
3393
|
i !== void 0 && (t.push([n, i.get()]), i.set(n.startsWith("scale") ? 1 : 0));
|
|
3365
3394
|
}), t;
|
|
@@ -3386,11 +3415,11 @@ ge.translateX = ge.x;
|
|
|
3386
3415
|
ge.translateY = ge.y;
|
|
3387
3416
|
const Pe = /* @__PURE__ */ new Set();
|
|
3388
3417
|
let an = !1, ln = !1, cn = !1;
|
|
3389
|
-
function
|
|
3418
|
+
function qi() {
|
|
3390
3419
|
if (ln) {
|
|
3391
3420
|
const e = Array.from(Pe).filter((i) => i.needsMeasurement), t = new Set(e.map((i) => i.element)), n = /* @__PURE__ */ new Map();
|
|
3392
3421
|
t.forEach((i) => {
|
|
3393
|
-
const r =
|
|
3422
|
+
const r = Oa(i);
|
|
3394
3423
|
r.length && (n.set(i, r), i.render());
|
|
3395
3424
|
}), e.forEach((i) => i.measureInitialState()), t.forEach((i) => {
|
|
3396
3425
|
i.render();
|
|
@@ -3405,20 +3434,20 @@ function Xi() {
|
|
|
3405
3434
|
}
|
|
3406
3435
|
ln = !1, an = !1, Pe.forEach((e) => e.complete(cn)), Pe.clear();
|
|
3407
3436
|
}
|
|
3408
|
-
function
|
|
3437
|
+
function Zi() {
|
|
3409
3438
|
Pe.forEach((e) => {
|
|
3410
3439
|
e.readKeyframes(), e.needsMeasurement && (ln = !0);
|
|
3411
3440
|
});
|
|
3412
3441
|
}
|
|
3413
3442
|
function Ba() {
|
|
3414
|
-
cn = !0,
|
|
3443
|
+
cn = !0, Zi(), qi(), cn = !1;
|
|
3415
3444
|
}
|
|
3416
3445
|
class Nn {
|
|
3417
3446
|
constructor(t, n, i, r, a, o = !1) {
|
|
3418
3447
|
this.state = "pending", this.isAsync = !1, this.needsMeasurement = !1, this.unresolvedKeyframes = [...t], this.onComplete = n, this.name = i, this.motionValue = r, this.element = a, this.isAsync = o;
|
|
3419
3448
|
}
|
|
3420
3449
|
scheduleResolve() {
|
|
3421
|
-
this.state = "scheduled", this.isAsync ? (Pe.add(this), an || (an = !0,
|
|
3450
|
+
this.state = "scheduled", this.isAsync ? (Pe.add(this), an || (an = !0, k.read(Zi), k.resolveKeyframes(qi))) : (this.readKeyframes(), this.complete());
|
|
3422
3451
|
}
|
|
3423
3452
|
readKeyframes() {
|
|
3424
3453
|
const { unresolvedKeyframes: t, name: n, element: i, motionValue: r } = this;
|
|
@@ -3432,7 +3461,7 @@ class Nn {
|
|
|
3432
3461
|
}
|
|
3433
3462
|
t[0] === void 0 && (t[0] = o), r && a === void 0 && r.set(t[0]);
|
|
3434
3463
|
}
|
|
3435
|
-
|
|
3464
|
+
ka(t);
|
|
3436
3465
|
}
|
|
3437
3466
|
setFinalKeyframe() {
|
|
3438
3467
|
}
|
|
@@ -3453,15 +3482,15 @@ class Nn {
|
|
|
3453
3482
|
}
|
|
3454
3483
|
}
|
|
3455
3484
|
const za = (e) => e.startsWith("--");
|
|
3456
|
-
function
|
|
3485
|
+
function Ji(e, t, n) {
|
|
3457
3486
|
za(t) ? e.style.setProperty(t, n) : e.style[t] = n;
|
|
3458
3487
|
}
|
|
3459
3488
|
const Ha = {};
|
|
3460
|
-
function
|
|
3461
|
-
const n = /* @__PURE__ */
|
|
3489
|
+
function Qi(e, t) {
|
|
3490
|
+
const n = /* @__PURE__ */ Ai(e);
|
|
3462
3491
|
return () => Ha[t] ?? n();
|
|
3463
3492
|
}
|
|
3464
|
-
const _a = /* @__PURE__ */
|
|
3493
|
+
const _a = /* @__PURE__ */ Qi(() => window.ScrollTimeline !== void 0, "scrollTimeline"), er = /* @__PURE__ */ Qi(() => {
|
|
3465
3494
|
try {
|
|
3466
3495
|
document.createElement("div").animate({ opacity: 0 }, { easing: "linear(0, 1)" });
|
|
3467
3496
|
} catch {
|
|
@@ -3479,16 +3508,16 @@ const _a = /* @__PURE__ */ Ji(() => window.ScrollTimeline !== void 0, "scrollTim
|
|
|
3479
3508
|
backIn: /* @__PURE__ */ Ye([0.31, 0.01, 0.66, -0.59]),
|
|
3480
3509
|
backOut: /* @__PURE__ */ Ye([0.33, 1.53, 0.69, 0.99])
|
|
3481
3510
|
};
|
|
3482
|
-
function
|
|
3511
|
+
function tr(e, t) {
|
|
3483
3512
|
if (e)
|
|
3484
|
-
return typeof e == "function" ?
|
|
3513
|
+
return typeof e == "function" ? er() ? Gi(e, t) : "ease-out" : Ii(e) ? Ye(e) : Array.isArray(e) ? e.map((n) => tr(n, t) || ps.easeOut) : ps[e];
|
|
3485
3514
|
}
|
|
3486
3515
|
function Ua(e, t, n, { delay: i = 0, duration: r = 300, repeat: a = 0, repeatType: o = "loop", ease: l = "easeOut", times: c } = {}, h = void 0) {
|
|
3487
3516
|
const u = {
|
|
3488
3517
|
[t]: n
|
|
3489
3518
|
};
|
|
3490
3519
|
c && (u.offset = c);
|
|
3491
|
-
const d =
|
|
3520
|
+
const d = tr(l, r);
|
|
3492
3521
|
Array.isArray(d) && (u.easing = d);
|
|
3493
3522
|
const f = {
|
|
3494
3523
|
delay: i,
|
|
@@ -3500,13 +3529,13 @@ function Ua(e, t, n, { delay: i = 0, duration: r = 300, repeat: a = 0, repeatTyp
|
|
|
3500
3529
|
};
|
|
3501
3530
|
return h && (f.pseudoElement = h), e.animate(u, f);
|
|
3502
3531
|
}
|
|
3503
|
-
function
|
|
3532
|
+
function nr(e) {
|
|
3504
3533
|
return typeof e == "function" && "applyToOptions" in e;
|
|
3505
3534
|
}
|
|
3506
3535
|
function Wa({ type: e, ...t }) {
|
|
3507
|
-
return
|
|
3536
|
+
return nr(e) && er() ? e.applyToOptions(t) : (t.duration ?? (t.duration = 300), t.ease ?? (t.ease = "easeOut"), t);
|
|
3508
3537
|
}
|
|
3509
|
-
class
|
|
3538
|
+
class sr extends Ln {
|
|
3510
3539
|
constructor(t) {
|
|
3511
3540
|
if (super(), this.finishedTime = null, this.isStopped = !1, this.manualStartTime = null, !t)
|
|
3512
3541
|
return;
|
|
@@ -3516,7 +3545,7 @@ class nr extends Ln {
|
|
|
3516
3545
|
this.animation = Ua(n, i, r, h, a), h.autoplay === !1 && this.animation.pause(), this.animation.onfinish = () => {
|
|
3517
3546
|
if (this.finishedTime = this.time, !a) {
|
|
3518
3547
|
const u = Ct(r, this.options, l, this.speed);
|
|
3519
|
-
this.updateMotionValue && this.updateMotionValue(u),
|
|
3548
|
+
this.updateMotionValue && this.updateMotionValue(u), Ji(n, i, u), this.animation.cancel();
|
|
3520
3549
|
}
|
|
3521
3550
|
c == null || c(), this.notifyFinished();
|
|
3522
3551
|
};
|
|
@@ -3604,21 +3633,21 @@ class nr extends Ln {
|
|
|
3604
3633
|
return this.allowFlatten && ((a = this.animation.effect) == null || a.updateTiming({ easing: "linear" })), this.animation.onfinish = null, t && _a() ? (this.animation.timeline = t, n && (this.animation.rangeStart = n), i && (this.animation.rangeEnd = i), ie) : r(this);
|
|
3605
3634
|
}
|
|
3606
3635
|
}
|
|
3607
|
-
const
|
|
3608
|
-
anticipate:
|
|
3636
|
+
const ir = {
|
|
3637
|
+
anticipate: Ri,
|
|
3609
3638
|
backInOut: Di,
|
|
3610
|
-
circInOut:
|
|
3639
|
+
circInOut: Ni
|
|
3611
3640
|
};
|
|
3612
3641
|
function $a(e) {
|
|
3613
|
-
return e in
|
|
3642
|
+
return e in ir;
|
|
3614
3643
|
}
|
|
3615
3644
|
function Ka(e) {
|
|
3616
|
-
typeof e.ease == "string" && $a(e.ease) && (e.ease =
|
|
3645
|
+
typeof e.ease == "string" && $a(e.ease) && (e.ease = ir[e.ease]);
|
|
3617
3646
|
}
|
|
3618
3647
|
const zt = 10;
|
|
3619
|
-
class Ga extends
|
|
3648
|
+
class Ga extends sr {
|
|
3620
3649
|
constructor(t) {
|
|
3621
|
-
Ka(t),
|
|
3650
|
+
Ka(t), Xi(t), super(t), t.startTime !== void 0 && t.autoplay !== !1 && (this.startTime = t.startTime), this.options = t;
|
|
3622
3651
|
}
|
|
3623
3652
|
/**
|
|
3624
3653
|
* WAAPI doesn't natively have any interruption capabilities.
|
|
@@ -3640,7 +3669,7 @@ class Ga extends nr {
|
|
|
3640
3669
|
...o,
|
|
3641
3670
|
autoplay: !1
|
|
3642
3671
|
}), c = Math.max(zt, Z.now() - this.startTime), h = de(0, zt, c - zt), u = l.sample(c).value, { name: d } = this.options;
|
|
3643
|
-
a && d &&
|
|
3672
|
+
a && d && Ji(a, d, u), n.setWithVelocity(l.sample(Math.max(0, c - h)).value, u, h), l.stop();
|
|
3644
3673
|
}
|
|
3645
3674
|
}
|
|
3646
3675
|
const ms = (e, t) => t === "zIndex" ? !1 : !!(typeof e == "number" || Array.isArray(e) || typeof e == "string" && // It's animatable if we have a string
|
|
@@ -3661,12 +3690,12 @@ function Xa(e, t, n, i) {
|
|
|
3661
3690
|
if (t === "display" || t === "visibility")
|
|
3662
3691
|
return !0;
|
|
3663
3692
|
const a = e[e.length - 1], o = ms(r, t), l = ms(a, t);
|
|
3664
|
-
return He(o === l, `You are trying to animate ${t} from "${r}" to "${a}". "${o ? a : r}" is not an animatable value.`, "value-not-animatable"), !o || !l ? !1 : Ya(e) || (n === "spring" ||
|
|
3693
|
+
return He(o === l, `You are trying to animate ${t} from "${r}" to "${a}". "${o ? a : r}" is not an animatable value.`, "value-not-animatable"), !o || !l ? !1 : Ya(e) || (n === "spring" || nr(n)) && i;
|
|
3665
3694
|
}
|
|
3666
3695
|
function un(e) {
|
|
3667
3696
|
e.duration = 0, e.type = "keyframes";
|
|
3668
3697
|
}
|
|
3669
|
-
const
|
|
3698
|
+
const rr = /* @__PURE__ */ new Set([
|
|
3670
3699
|
"opacity",
|
|
3671
3700
|
"clipPath",
|
|
3672
3701
|
"filter",
|
|
@@ -3692,7 +3721,7 @@ const Ja = /* @__PURE__ */ new Set([
|
|
|
3692
3721
|
"borderRightColor",
|
|
3693
3722
|
"borderBottomColor",
|
|
3694
3723
|
"borderLeftColor"
|
|
3695
|
-
]), Qa = /* @__PURE__ */
|
|
3724
|
+
]), Qa = /* @__PURE__ */ Ai(() => Object.hasOwnProperty.call(Element.prototype, "animate"));
|
|
3696
3725
|
function el(e) {
|
|
3697
3726
|
var d;
|
|
3698
3727
|
const { motionValue: t, name: n, repeatDelay: i, repeatType: r, damping: a, type: o, keyframes: l } = e;
|
|
@@ -3703,7 +3732,7 @@ function el(e) {
|
|
|
3703
3732
|
* Force WAAPI for color properties with browser-only color formats
|
|
3704
3733
|
* (oklch, oklab, lab, lch, etc.) that the JS animation path can't parse.
|
|
3705
3734
|
*/
|
|
3706
|
-
(
|
|
3735
|
+
(rr.has(n) || Ja.has(n) && Za(l)) && (n !== "transform" || !u) && /**
|
|
3707
3736
|
* If we're outputting values to onUpdate then we can't use WAAPI as there's
|
|
3708
3737
|
* no way to read the value from WAAPI every frame.
|
|
3709
3738
|
*/
|
|
@@ -3812,7 +3841,7 @@ class nl extends Ln {
|
|
|
3812
3841
|
this._animation && this.animation.cancel(), (t = this.keyframeResolver) == null || t.cancel();
|
|
3813
3842
|
}
|
|
3814
3843
|
}
|
|
3815
|
-
function
|
|
3844
|
+
function or(e, t, n, i = 0, r = 1) {
|
|
3816
3845
|
const a = Array.from(e).sort((h, u) => h.sortNodePosition(u)).indexOf(t), o = e.size, l = (o - 1) * i;
|
|
3817
3846
|
return typeof n == "function" ? n(a, o) : r === 1 ? a * i : l - a * i;
|
|
3818
3847
|
}
|
|
@@ -3828,7 +3857,7 @@ function il(e) {
|
|
|
3828
3857
|
return [`--${n ?? i}`, r];
|
|
3829
3858
|
}
|
|
3830
3859
|
const rl = 4;
|
|
3831
|
-
function
|
|
3860
|
+
function ar(e, t, n = 1) {
|
|
3832
3861
|
pe(n <= rl, `Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`, "max-css-var-depth");
|
|
3833
3862
|
const [i, r] = il(e);
|
|
3834
3863
|
if (!i)
|
|
@@ -3836,9 +3865,9 @@ function or(e, t, n = 1) {
|
|
|
3836
3865
|
const a = window.getComputedStyle(t).getPropertyValue(i);
|
|
3837
3866
|
if (a) {
|
|
3838
3867
|
const o = a.trim();
|
|
3839
|
-
return
|
|
3868
|
+
return Ti(o) ? parseFloat(o) : o;
|
|
3840
3869
|
}
|
|
3841
|
-
return Cn(r) ?
|
|
3870
|
+
return Cn(r) ? ar(r, t, n + 1) : r;
|
|
3842
3871
|
}
|
|
3843
3872
|
const ol = {
|
|
3844
3873
|
type: "spring",
|
|
@@ -3858,7 +3887,7 @@ const ol = {
|
|
|
3858
3887
|
ease: [0.25, 0.1, 0.35, 1],
|
|
3859
3888
|
duration: 0.3
|
|
3860
3889
|
}, ul = (e, { keyframes: t }) => t.length > 2 ? ll : We.has(e) ? e.startsWith("scale") ? al(t[1]) : ol : cl;
|
|
3861
|
-
function
|
|
3890
|
+
function lr(e, t) {
|
|
3862
3891
|
if (e != null && e.inherit && t) {
|
|
3863
3892
|
const { inherit: n, ...i } = e;
|
|
3864
3893
|
return { ...t, ...i };
|
|
@@ -3867,7 +3896,7 @@ function ar(e, t) {
|
|
|
3867
3896
|
}
|
|
3868
3897
|
function Fn(e, t) {
|
|
3869
3898
|
const n = (e == null ? void 0 : e[t]) ?? (e == null ? void 0 : e.default) ?? e;
|
|
3870
|
-
return n !== e ?
|
|
3899
|
+
return n !== e ? lr(n, e) : n;
|
|
3871
3900
|
}
|
|
3872
3901
|
const hl = /* @__PURE__ */ new Set([
|
|
3873
3902
|
"when",
|
|
@@ -3887,7 +3916,7 @@ function dl(e) {
|
|
|
3887
3916
|
return !0;
|
|
3888
3917
|
return !1;
|
|
3889
3918
|
}
|
|
3890
|
-
const
|
|
3919
|
+
const In = (e, t, n, i = {}, r, a) => (o) => {
|
|
3891
3920
|
const l = Fn(i, e) || {}, c = l.delay || i.delay || 0;
|
|
3892
3921
|
let { elapsed: h = 0 } = i;
|
|
3893
3922
|
h = h - /* @__PURE__ */ te(c);
|
|
@@ -3912,7 +3941,7 @@ const On = (e, t, n, i = {}, r, a) => (o) => {
|
|
|
3912
3941
|
if ((u.type === !1 || u.duration === 0 && !u.repeatDelay) && (un(u), u.delay === 0 && (d = !0)), (ve.instantAnimations || ve.skipAnimations || r != null && r.shouldSkipAnimations) && (d = !0, un(u), u.delay = 0), u.allowFlatten = !l.type && !l.ease, d && !a && t.get() !== void 0) {
|
|
3913
3942
|
const f = Ct(u.keyframes, l);
|
|
3914
3943
|
if (f !== void 0) {
|
|
3915
|
-
|
|
3944
|
+
k.update(() => {
|
|
3916
3945
|
u.onUpdate(f), u.onComplete();
|
|
3917
3946
|
});
|
|
3918
3947
|
return;
|
|
@@ -3926,7 +3955,7 @@ function xs(e) {
|
|
|
3926
3955
|
t[0][i] = n.get(), t[1][i] = n.getVelocity();
|
|
3927
3956
|
}), t;
|
|
3928
3957
|
}
|
|
3929
|
-
function
|
|
3958
|
+
function On(e, t, n, i) {
|
|
3930
3959
|
if (typeof t == "function") {
|
|
3931
3960
|
const [r, a] = xs(i);
|
|
3932
3961
|
t = t(n !== void 0 ? n : e.custom, r, a);
|
|
@@ -3939,9 +3968,9 @@ function In(e, t, n, i) {
|
|
|
3939
3968
|
}
|
|
3940
3969
|
function Ve(e, t, n) {
|
|
3941
3970
|
const i = e.getProps();
|
|
3942
|
-
return
|
|
3971
|
+
return On(i, t, n !== void 0 ? n : i.custom, e);
|
|
3943
3972
|
}
|
|
3944
|
-
const
|
|
3973
|
+
const cr = /* @__PURE__ */ new Set([
|
|
3945
3974
|
"width",
|
|
3946
3975
|
"height",
|
|
3947
3976
|
"top",
|
|
@@ -4019,7 +4048,7 @@ class pl {
|
|
|
4019
4048
|
this.events[t] || (this.events[t] = new Sn());
|
|
4020
4049
|
const i = this.events[t].add(n);
|
|
4021
4050
|
return t === "change" ? () => {
|
|
4022
|
-
i(),
|
|
4051
|
+
i(), k.read(() => {
|
|
4023
4052
|
this.events.change.getSize() || this.stop();
|
|
4024
4053
|
});
|
|
4025
4054
|
} : i;
|
|
@@ -4100,7 +4129,7 @@ class pl {
|
|
|
4100
4129
|
if (!this.canTrackVelocity || this.prevFrameValue === void 0 || t - this.updatedAt > ys)
|
|
4101
4130
|
return 0;
|
|
4102
4131
|
const n = Math.min(this.updatedAt - this.prevUpdatedAt, ys);
|
|
4103
|
-
return
|
|
4132
|
+
return Pi(parseFloat(this.current) - parseFloat(this.prevFrameValue), n);
|
|
4104
4133
|
}
|
|
4105
4134
|
/**
|
|
4106
4135
|
* Registers a new animation to control this `MotionValue`. Only one
|
|
@@ -4187,18 +4216,18 @@ function dn(e, t) {
|
|
|
4187
4216
|
function Bn(e) {
|
|
4188
4217
|
return e.replace(/([A-Z])/g, (t) => `-${t.toLowerCase()}`);
|
|
4189
4218
|
}
|
|
4190
|
-
const jl = "framerAppearId",
|
|
4191
|
-
function
|
|
4192
|
-
return e.props[
|
|
4219
|
+
const jl = "framerAppearId", ur = "data-" + Bn(jl);
|
|
4220
|
+
function hr(e) {
|
|
4221
|
+
return e.props[ur];
|
|
4193
4222
|
}
|
|
4194
4223
|
function vl({ protectedKeys: e, needsAnimating: t }, n) {
|
|
4195
4224
|
const i = e.hasOwnProperty(n) && t[n] !== !0;
|
|
4196
4225
|
return t[n] = !1, i;
|
|
4197
4226
|
}
|
|
4198
|
-
function
|
|
4227
|
+
function dr(e, t, { delay: n = 0, transitionOverride: i, type: r } = {}) {
|
|
4199
4228
|
let { transition: a, transitionEnd: o, ...l } = t;
|
|
4200
4229
|
const c = e.getDefaultTransition();
|
|
4201
|
-
a = a ?
|
|
4230
|
+
a = a ? lr(a, c) : c;
|
|
4202
4231
|
const h = a == null ? void 0 : a.reduceMotion;
|
|
4203
4232
|
i && (a = i);
|
|
4204
4233
|
const u = [], d = r && e.animationState && e.animationState.getState()[r];
|
|
@@ -4211,25 +4240,25 @@ function hr(e, t, { delay: n = 0, transitionOverride: i, type: r } = {}) {
|
|
|
4211
4240
|
...Fn(a || {}, f)
|
|
4212
4241
|
}, y = m.get();
|
|
4213
4242
|
if (y !== void 0 && !m.isAnimating() && !Array.isArray(x) && x === y && !g.velocity) {
|
|
4214
|
-
|
|
4243
|
+
k.update(() => m.set(x));
|
|
4215
4244
|
continue;
|
|
4216
4245
|
}
|
|
4217
4246
|
let w = !1;
|
|
4218
4247
|
if (window.MotionHandoffAnimation) {
|
|
4219
|
-
const M =
|
|
4248
|
+
const M = hr(e);
|
|
4220
4249
|
if (M) {
|
|
4221
|
-
const S = window.MotionHandoffAnimation(M, f,
|
|
4250
|
+
const S = window.MotionHandoffAnimation(M, f, k);
|
|
4222
4251
|
S !== null && (g.startTime = S, w = !0);
|
|
4223
4252
|
}
|
|
4224
4253
|
}
|
|
4225
4254
|
dn(e, f);
|
|
4226
4255
|
const v = h ?? e.shouldReduceMotion;
|
|
4227
|
-
m.start(
|
|
4256
|
+
m.start(In(f, m, x, v && cr.has(f) ? { type: !1 } : g, e, w));
|
|
4228
4257
|
const b = m.animation;
|
|
4229
4258
|
b && u.push(b);
|
|
4230
4259
|
}
|
|
4231
4260
|
if (o) {
|
|
4232
|
-
const f = () =>
|
|
4261
|
+
const f = () => k.update(() => {
|
|
4233
4262
|
o && yl(e, o);
|
|
4234
4263
|
});
|
|
4235
4264
|
u.length ? Promise.all(u).then(f) : f();
|
|
@@ -4241,7 +4270,7 @@ function fn(e, t, n = {}) {
|
|
|
4241
4270
|
const i = Ve(e, t, n.type === "exit" ? (c = e.presenceContext) == null ? void 0 : c.custom : void 0);
|
|
4242
4271
|
let { transition: r = e.getDefaultTransition() || {} } = i || {};
|
|
4243
4272
|
n.transitionOverride && (r = n.transitionOverride);
|
|
4244
|
-
const a = i ? () => Promise.all(
|
|
4273
|
+
const a = i ? () => Promise.all(dr(e, i, n)) : () => Promise.resolve(), o = e.variantChildren && e.variantChildren.size ? (h = 0) => {
|
|
4245
4274
|
const { delayChildren: u = 0, staggerChildren: d, staggerDirection: f } = r;
|
|
4246
4275
|
return wl(e, t, h, u, d, f, n);
|
|
4247
4276
|
} : () => Promise.resolve(), { when: l } = r;
|
|
@@ -4256,7 +4285,7 @@ function wl(e, t, n = 0, i = 0, r = 0, a = 1, o) {
|
|
|
4256
4285
|
for (const c of e.variantChildren)
|
|
4257
4286
|
c.notify("AnimationStart", t), l.push(fn(c, t, {
|
|
4258
4287
|
...o,
|
|
4259
|
-
delay: n + (typeof i == "function" ? 0 : i) +
|
|
4288
|
+
delay: n + (typeof i == "function" ? 0 : i) + or(e.variantChildren, c, i, r, a)
|
|
4260
4289
|
}).then(() => c.notify("AnimationComplete", t)));
|
|
4261
4290
|
return Promise.all(l);
|
|
4262
4291
|
}
|
|
@@ -4270,7 +4299,7 @@ function bl(e, t, n = {}) {
|
|
|
4270
4299
|
i = fn(e, t, n);
|
|
4271
4300
|
else {
|
|
4272
4301
|
const r = typeof t == "function" ? Ve(e, t, n.custom) : t;
|
|
4273
|
-
i = Promise.all(
|
|
4302
|
+
i = Promise.all(dr(e, r, n));
|
|
4274
4303
|
}
|
|
4275
4304
|
return i.then(() => {
|
|
4276
4305
|
e.notify("AnimationComplete", t);
|
|
@@ -4279,9 +4308,9 @@ function bl(e, t, n = {}) {
|
|
|
4279
4308
|
const Tl = {
|
|
4280
4309
|
test: (e) => e === "auto",
|
|
4281
4310
|
parse: (e) => e
|
|
4282
|
-
},
|
|
4311
|
+
}, fr = (e) => (t) => t.test(e), pr = [_e, A, he, xe, Yo, Go, Tl], gs = (e) => pr.find(fr(e));
|
|
4283
4312
|
function Ml(e) {
|
|
4284
|
-
return typeof e == "number" ? e === 0 : e !== null ? e === "none" || e === "0" ||
|
|
4313
|
+
return typeof e == "number" ? e === 0 : e !== null ? e === "none" || e === "0" || Si(e) : !0;
|
|
4285
4314
|
}
|
|
4286
4315
|
const Sl = /* @__PURE__ */ new Set(["brightness", "contrast", "saturate", "opacity"]);
|
|
4287
4316
|
function Al(e) {
|
|
@@ -4415,21 +4444,21 @@ const Pl = /\b([a-z-]*)\(.*?\)/gu, pn = {
|
|
|
4415
4444
|
WebkitFilter: pn,
|
|
4416
4445
|
mask: mn,
|
|
4417
4446
|
WebkitMask: mn
|
|
4418
|
-
},
|
|
4419
|
-
function
|
|
4420
|
-
let n =
|
|
4447
|
+
}, mr = (e) => Cl[e], El = /* @__PURE__ */ new Set([pn, mn]);
|
|
4448
|
+
function xr(e, t) {
|
|
4449
|
+
let n = mr(e);
|
|
4421
4450
|
return El.has(n) || (n = ae), n.getAnimatableNone ? n.getAnimatableNone(t) : void 0;
|
|
4422
4451
|
}
|
|
4423
|
-
const
|
|
4424
|
-
function
|
|
4452
|
+
const kl = /* @__PURE__ */ new Set(["auto", "none", "0"]);
|
|
4453
|
+
function Dl(e, t, n) {
|
|
4425
4454
|
let i = 0, r;
|
|
4426
4455
|
for (; i < e.length && !r; ) {
|
|
4427
4456
|
const a = e[i];
|
|
4428
|
-
typeof a == "string" && !
|
|
4457
|
+
typeof a == "string" && !kl.has(a) && Oe(a).values.length && (r = e[i]), i++;
|
|
4429
4458
|
}
|
|
4430
4459
|
if (r && n)
|
|
4431
4460
|
for (const a of t)
|
|
4432
|
-
e[a] =
|
|
4461
|
+
e[a] = xr(n, r);
|
|
4433
4462
|
}
|
|
4434
4463
|
class Rl extends Nn {
|
|
4435
4464
|
constructor(t, n, i, r, a) {
|
|
@@ -4443,11 +4472,11 @@ class Rl extends Nn {
|
|
|
4443
4472
|
for (let u = 0; u < t.length; u++) {
|
|
4444
4473
|
let d = t[u];
|
|
4445
4474
|
if (typeof d == "string" && (d = d.trim(), Cn(d))) {
|
|
4446
|
-
const f =
|
|
4475
|
+
const f = ar(d, n.current);
|
|
4447
4476
|
f !== void 0 && (t[u] = f), u === t.length - 1 && (this.finalKeyframe = d);
|
|
4448
4477
|
}
|
|
4449
4478
|
}
|
|
4450
|
-
if (this.resolveNoneKeyframes(), !
|
|
4479
|
+
if (this.resolveNoneKeyframes(), !cr.has(i) || t.length !== 2)
|
|
4451
4480
|
return;
|
|
4452
4481
|
const [r, a] = t, o = gs(r), l = gs(a), c = ss(r), h = ss(a);
|
|
4453
4482
|
if (c !== h && ge[i]) {
|
|
@@ -4466,7 +4495,7 @@ class Rl extends Nn {
|
|
|
4466
4495
|
const { unresolvedKeyframes: t, name: n } = this, i = [];
|
|
4467
4496
|
for (let r = 0; r < t.length; r++)
|
|
4468
4497
|
(t[r] === null || Ml(t[r])) && i.push(r);
|
|
4469
|
-
i.length &&
|
|
4498
|
+
i.length && Dl(t, i, n);
|
|
4470
4499
|
}
|
|
4471
4500
|
measureInitialState() {
|
|
4472
4501
|
const { element: t, unresolvedKeyframes: n, name: i } = this;
|
|
@@ -4489,7 +4518,7 @@ class Rl extends Nn {
|
|
|
4489
4518
|
}), this.resolveNoneKeyframes();
|
|
4490
4519
|
}
|
|
4491
4520
|
}
|
|
4492
|
-
function
|
|
4521
|
+
function yr(e, t, n) {
|
|
4493
4522
|
if (e == null)
|
|
4494
4523
|
return [];
|
|
4495
4524
|
if (e instanceof EventTarget)
|
|
@@ -4501,15 +4530,15 @@ function xr(e, t, n) {
|
|
|
4501
4530
|
}
|
|
4502
4531
|
return Array.from(e).filter((i) => i != null);
|
|
4503
4532
|
}
|
|
4504
|
-
const
|
|
4533
|
+
const gr = (e, t) => t && typeof e == "number" ? t.transform(e) : e;
|
|
4505
4534
|
function Ll(e) {
|
|
4506
|
-
return
|
|
4535
|
+
return Mi(e) && "offsetHeight" in e && !("ownerSVGElement" in e);
|
|
4507
4536
|
}
|
|
4508
4537
|
const { schedule: Hn } = /* @__PURE__ */ Oi(queueMicrotask, !1), oe = {
|
|
4509
4538
|
x: !1,
|
|
4510
4539
|
y: !1
|
|
4511
4540
|
};
|
|
4512
|
-
function
|
|
4541
|
+
function jr() {
|
|
4513
4542
|
return oe.x || oe.y;
|
|
4514
4543
|
}
|
|
4515
4544
|
function Nl(e) {
|
|
@@ -4519,8 +4548,8 @@ function Nl(e) {
|
|
|
4519
4548
|
oe.x = oe.y = !1;
|
|
4520
4549
|
});
|
|
4521
4550
|
}
|
|
4522
|
-
function
|
|
4523
|
-
const n =
|
|
4551
|
+
function vr(e, t) {
|
|
4552
|
+
const n = yr(e), i = new AbortController(), r = {
|
|
4524
4553
|
passive: !0,
|
|
4525
4554
|
...t,
|
|
4526
4555
|
signal: i.signal
|
|
@@ -4528,10 +4557,10 @@ function jr(e, t) {
|
|
|
4528
4557
|
return [n, r, () => i.abort()];
|
|
4529
4558
|
}
|
|
4530
4559
|
function Fl(e) {
|
|
4531
|
-
return !(e.pointerType === "touch" ||
|
|
4560
|
+
return !(e.pointerType === "touch" || jr());
|
|
4532
4561
|
}
|
|
4533
|
-
function
|
|
4534
|
-
const [i, r, a] =
|
|
4562
|
+
function Il(e, t, n = {}) {
|
|
4563
|
+
const [i, r, a] = vr(e, n);
|
|
4535
4564
|
return i.forEach((o) => {
|
|
4536
4565
|
let l = !1, c = !1, h;
|
|
4537
4566
|
const u = () => {
|
|
@@ -4560,7 +4589,7 @@ function Ol(e, t, n = {}) {
|
|
|
4560
4589
|
o.addEventListener("pointerenter", g, r), o.addEventListener("pointerdown", m, r);
|
|
4561
4590
|
}), a;
|
|
4562
4591
|
}
|
|
4563
|
-
const
|
|
4592
|
+
const wr = (e, t) => t ? e === t ? !0 : wr(e, t.parentElement) : !1, _n = (e) => e.pointerType === "mouse" ? typeof e.button != "number" || e.button <= 0 : e.isPrimary !== !1, Ol = /* @__PURE__ */ new Set([
|
|
4564
4593
|
"BUTTON",
|
|
4565
4594
|
"INPUT",
|
|
4566
4595
|
"SELECT",
|
|
@@ -4568,7 +4597,7 @@ const vr = (e, t) => t ? e === t ? !0 : vr(e, t.parentElement) : !1, _n = (e) =>
|
|
|
4568
4597
|
"A"
|
|
4569
4598
|
]);
|
|
4570
4599
|
function Bl(e) {
|
|
4571
|
-
return
|
|
4600
|
+
return Ol.has(e.tagName) || e.isContentEditable === !0;
|
|
4572
4601
|
}
|
|
4573
4602
|
const zl = /* @__PURE__ */ new Set(["INPUT", "SELECT", "TEXTAREA"]);
|
|
4574
4603
|
function Hl(e) {
|
|
@@ -4599,11 +4628,11 @@ const _l = (e, t) => {
|
|
|
4599
4628
|
n.addEventListener("keydown", i, t), n.addEventListener("blur", () => n.removeEventListener("keydown", i), t);
|
|
4600
4629
|
};
|
|
4601
4630
|
function ws(e) {
|
|
4602
|
-
return _n(e) && !
|
|
4631
|
+
return _n(e) && !jr();
|
|
4603
4632
|
}
|
|
4604
4633
|
const bs = /* @__PURE__ */ new WeakSet();
|
|
4605
4634
|
function Ul(e, t, n = {}) {
|
|
4606
|
-
const [i, r, a] =
|
|
4635
|
+
const [i, r, a] = vr(e, n), o = (l) => {
|
|
4607
4636
|
const c = l.currentTarget;
|
|
4608
4637
|
if (!ws(l) || bs.has(l))
|
|
4609
4638
|
return;
|
|
@@ -4611,7 +4640,7 @@ function Ul(e, t, n = {}) {
|
|
|
4611
4640
|
const h = t(c, l), u = (m, x) => {
|
|
4612
4641
|
window.removeEventListener("pointerup", d), window.removeEventListener("pointercancel", f), pt.has(c) && pt.delete(c), ws(m) && typeof h == "function" && h(m, { success: x });
|
|
4613
4642
|
}, d = (m) => {
|
|
4614
|
-
u(m, c === window || c === document || n.useGlobalTarget ||
|
|
4643
|
+
u(m, c === window || c === document || n.useGlobalTarget || wr(c, m.target));
|
|
4615
4644
|
}, f = (m) => {
|
|
4616
4645
|
u(m, !1);
|
|
4617
4646
|
};
|
|
@@ -4622,11 +4651,11 @@ function Ul(e, t, n = {}) {
|
|
|
4622
4651
|
}), a;
|
|
4623
4652
|
}
|
|
4624
4653
|
function Un(e) {
|
|
4625
|
-
return
|
|
4654
|
+
return Mi(e) && "ownerSVGElement" in e;
|
|
4626
4655
|
}
|
|
4627
4656
|
const mt = /* @__PURE__ */ new WeakMap();
|
|
4628
4657
|
let ye;
|
|
4629
|
-
const
|
|
4658
|
+
const br = (e, t, n) => (i, r) => r && r[0] ? r[0][e + "Size"] : Un(i) && "getBBox" in i ? i.getBBox()[t] : i[n], Wl = /* @__PURE__ */ br("inline", "width", "offsetWidth"), $l = /* @__PURE__ */ br("block", "height", "offsetHeight");
|
|
4630
4659
|
function Kl({ target: e, borderBoxSize: t }) {
|
|
4631
4660
|
var n;
|
|
4632
4661
|
(n = mt.get(e)) == null || n.forEach((i) => {
|
|
@@ -4648,7 +4677,7 @@ function Yl() {
|
|
|
4648
4677
|
}
|
|
4649
4678
|
function Xl(e, t) {
|
|
4650
4679
|
ye || Yl();
|
|
4651
|
-
const n =
|
|
4680
|
+
const n = yr(e);
|
|
4652
4681
|
return n.forEach((i) => {
|
|
4653
4682
|
let r = mt.get(i);
|
|
4654
4683
|
r || (r = /* @__PURE__ */ new Set(), mt.set(i, r)), r.add(t), ye == null || ye.observe(i);
|
|
@@ -4685,7 +4714,7 @@ function Ts(e, t) {
|
|
|
4685
4714
|
function Jl(e) {
|
|
4686
4715
|
return Un(e) && e.tagName === "svg";
|
|
4687
4716
|
}
|
|
4688
|
-
const Ql = [...
|
|
4717
|
+
const Ql = [...pr, z, ae], ec = (e) => Ql.find(fr(e)), Ms = () => ({
|
|
4689
4718
|
translate: 0,
|
|
4690
4719
|
scale: 1,
|
|
4691
4720
|
origin: 0,
|
|
@@ -4712,11 +4741,11 @@ const Wn = [
|
|
|
4712
4741
|
"whileDrag",
|
|
4713
4742
|
"exit"
|
|
4714
4743
|
], $n = ["initial", ...Wn];
|
|
4715
|
-
function
|
|
4744
|
+
function kt(e) {
|
|
4716
4745
|
return Et(e.animate) || $n.some((t) => et(e[t]));
|
|
4717
4746
|
}
|
|
4718
|
-
function
|
|
4719
|
-
return !!(
|
|
4747
|
+
function Tr(e) {
|
|
4748
|
+
return !!(kt(e) || e.variants);
|
|
4720
4749
|
}
|
|
4721
4750
|
function nc(e, t, n) {
|
|
4722
4751
|
for (const i in t) {
|
|
@@ -4738,9 +4767,9 @@ function nc(e, t, n) {
|
|
|
4738
4767
|
t[i] === void 0 && e.removeValue(i);
|
|
4739
4768
|
return t;
|
|
4740
4769
|
}
|
|
4741
|
-
const xn = { current: null },
|
|
4770
|
+
const xn = { current: null }, Mr = { current: !1 }, sc = typeof window < "u";
|
|
4742
4771
|
function ic() {
|
|
4743
|
-
if (
|
|
4772
|
+
if (Mr.current = !0, !!sc)
|
|
4744
4773
|
if (window.matchMedia) {
|
|
4745
4774
|
const e = window.matchMedia("(prefers-reduced-motion)"), t = () => xn.current = e.matches;
|
|
4746
4775
|
e.addEventListener("change", t), t();
|
|
@@ -4757,7 +4786,7 @@ const As = [
|
|
|
4757
4786
|
"LayoutAnimationComplete"
|
|
4758
4787
|
];
|
|
4759
4788
|
let St = {};
|
|
4760
|
-
function
|
|
4789
|
+
function Sr(e) {
|
|
4761
4790
|
St = e;
|
|
4762
4791
|
}
|
|
4763
4792
|
function rc() {
|
|
@@ -4779,10 +4808,10 @@ class oc {
|
|
|
4779
4808
|
this.current && (this.triggerBuild(), this.renderInstance(this.current, this.renderState, this.props.style, this.projection));
|
|
4780
4809
|
}, this.renderScheduledAt = 0, this.scheduleRender = () => {
|
|
4781
4810
|
const m = Z.now();
|
|
4782
|
-
this.renderScheduledAt < m && (this.renderScheduledAt = m,
|
|
4811
|
+
this.renderScheduledAt < m && (this.renderScheduledAt = m, k.render(this.render, !1, !0));
|
|
4783
4812
|
};
|
|
4784
4813
|
const { latestValues: h, renderState: u } = l;
|
|
4785
|
-
this.latestValues = h, this.baseTarget = { ...h }, this.initialValues = n.initial ? { ...h } : {}, this.renderState = u, this.parent = t, this.props = n, this.presenceContext = i, this.depth = t ? t.depth + 1 : 0, this.reducedMotionConfig = r, this.skipAnimationsConfig = a, this.options = c, this.blockInitialAnimation = !!o, this.isControllingVariants =
|
|
4814
|
+
this.latestValues = h, this.baseTarget = { ...h }, this.initialValues = n.initial ? { ...h } : {}, this.renderState = u, this.parent = t, this.props = n, this.presenceContext = i, this.depth = t ? t.depth + 1 : 0, this.reducedMotionConfig = r, this.skipAnimationsConfig = a, this.options = c, this.blockInitialAnimation = !!o, this.isControllingVariants = kt(n), this.isVariantNode = Tr(n), this.isVariantNode && (this.variantChildren = /* @__PURE__ */ new Set()), this.manuallyAnimateOnMount = !!(t && t.current);
|
|
4786
4815
|
const { willChange: d, ...f } = this.scrapeMotionValuesFromProps(n, {}, this);
|
|
4787
4816
|
for (const m in f) {
|
|
4788
4817
|
const x = f[m];
|
|
@@ -4794,7 +4823,7 @@ class oc {
|
|
|
4794
4823
|
if (this.hasBeenMounted)
|
|
4795
4824
|
for (const r in this.initialValues)
|
|
4796
4825
|
(n = this.values.get(r)) == null || n.jump(this.initialValues[r]), this.latestValues[r] = this.initialValues[r];
|
|
4797
|
-
this.current = t, tc.set(t, this), this.projection && !this.projection.instance && this.projection.mount(t), this.parent && this.isVariantNode && !this.isControllingVariants && (this.removeFromVariantTree = this.parent.addVariantChild(this)), this.values.forEach((r, a) => this.bindToMotionValue(a, r)), this.reducedMotionConfig === "never" ? this.shouldReduceMotion = !1 : this.reducedMotionConfig === "always" ? this.shouldReduceMotion = !0 : (
|
|
4826
|
+
this.current = t, tc.set(t, this), this.projection && !this.projection.instance && this.projection.mount(t), this.parent && this.isVariantNode && !this.isControllingVariants && (this.removeFromVariantTree = this.parent.addVariantChild(this)), this.values.forEach((r, a) => this.bindToMotionValue(a, r)), this.reducedMotionConfig === "never" ? this.shouldReduceMotion = !1 : this.reducedMotionConfig === "always" ? this.shouldReduceMotion = !0 : (Mr.current || ic(), this.shouldReduceMotion = xn.current), process.env.NODE_ENV !== "production" && An(this.shouldReduceMotion !== !0, "You have Reduced Motion enabled on your device. Animations may not appear as expected.", "reduced-motion-disabled"), this.shouldSkipAnimations = this.skipAnimationsConfig ?? !1, (i = this.parent) == null || i.addChild(this), this.update(this.props, this.presenceContext), this.hasBeenMounted = !0;
|
|
4798
4827
|
}
|
|
4799
4828
|
unmount() {
|
|
4800
4829
|
var t;
|
|
@@ -4814,8 +4843,8 @@ class oc {
|
|
|
4814
4843
|
this.children.delete(t), this.enteringChildren && this.enteringChildren.delete(t);
|
|
4815
4844
|
}
|
|
4816
4845
|
bindToMotionValue(t, n) {
|
|
4817
|
-
if (this.valueSubscriptions.has(t) && this.valueSubscriptions.get(t)(), n.accelerate &&
|
|
4818
|
-
const { factory: o, keyframes: l, times: c, ease: h, duration: u } = n.accelerate, d = new
|
|
4846
|
+
if (this.valueSubscriptions.has(t) && this.valueSubscriptions.get(t)(), n.accelerate && rr.has(t) && this.current instanceof HTMLElement) {
|
|
4847
|
+
const { factory: o, keyframes: l, times: c, ease: h, duration: u } = n.accelerate, d = new sr({
|
|
4819
4848
|
element: this.current,
|
|
4820
4849
|
name: t,
|
|
4821
4850
|
keyframes: l,
|
|
@@ -4831,7 +4860,7 @@ class oc {
|
|
|
4831
4860
|
const i = We.has(t);
|
|
4832
4861
|
i && this.onBindTransform && this.onBindTransform();
|
|
4833
4862
|
const r = n.on("change", (o) => {
|
|
4834
|
-
this.latestValues[t] = o, this.props.onUpdate &&
|
|
4863
|
+
this.latestValues[t] = o, this.props.onUpdate && k.preRender(this.notifyUpdate), i && this.projection && (this.projection.isTransformDirty = !0), this.scheduleRender();
|
|
4835
4864
|
});
|
|
4836
4865
|
let a;
|
|
4837
4866
|
typeof window < "u" && window.MotionCheckAppearSync && (a = window.MotionCheckAppearSync(this, t, n)), this.valueSubscriptions.set(t, () => {
|
|
@@ -4948,7 +4977,7 @@ class oc {
|
|
|
4948
4977
|
*/
|
|
4949
4978
|
readValue(t, n) {
|
|
4950
4979
|
let i = this.latestValues[t] !== void 0 || !this.current ? this.latestValues[t] : this.getBaseTargetFromProps(this.props, t) ?? this.readValueFromInstance(this.current, t, this.options);
|
|
4951
|
-
return i != null && (typeof i == "string" && (
|
|
4980
|
+
return i != null && (typeof i == "string" && (Ti(i) || Si(i)) ? i = parseFloat(i) : !ec(i) && ae.test(n) && (i = xr(t, n)), this.setBaseTarget(t, W(i) ? i.get() : i)), W(i) ? i.get() : i;
|
|
4952
4981
|
}
|
|
4953
4982
|
/**
|
|
4954
4983
|
* Set the base target to later animate back to. This is currently
|
|
@@ -4966,7 +4995,7 @@ class oc {
|
|
|
4966
4995
|
const { initial: n } = this.props;
|
|
4967
4996
|
let i;
|
|
4968
4997
|
if (typeof n == "string" || typeof n == "object") {
|
|
4969
|
-
const o =
|
|
4998
|
+
const o = On(this.props, n, (a = this.presenceContext) == null ? void 0 : a.custom);
|
|
4970
4999
|
o && (i = o[t]);
|
|
4971
5000
|
}
|
|
4972
5001
|
if (n && i !== void 0)
|
|
@@ -4984,7 +5013,7 @@ class oc {
|
|
|
4984
5013
|
Hn.render(this.render);
|
|
4985
5014
|
}
|
|
4986
5015
|
}
|
|
4987
|
-
class
|
|
5016
|
+
class Ar extends oc {
|
|
4988
5017
|
constructor() {
|
|
4989
5018
|
super(...arguments), this.KeyframeResolver = Rl;
|
|
4990
5019
|
}
|
|
@@ -5013,7 +5042,7 @@ class be {
|
|
|
5013
5042
|
update() {
|
|
5014
5043
|
}
|
|
5015
5044
|
}
|
|
5016
|
-
function
|
|
5045
|
+
function Pr({ top: e, left: t, right: n, bottom: i }) {
|
|
5017
5046
|
return {
|
|
5018
5047
|
x: { min: t, max: n },
|
|
5019
5048
|
y: { min: e, max: i }
|
|
@@ -5040,9 +5069,9 @@ function yn({ scale: e, scaleX: t, scaleY: n }) {
|
|
|
5040
5069
|
return !_t(e) || !_t(t) || !_t(n);
|
|
5041
5070
|
}
|
|
5042
5071
|
function Me(e) {
|
|
5043
|
-
return yn(e) ||
|
|
5072
|
+
return yn(e) || Vr(e) || e.z || e.rotate || e.rotateX || e.rotateY || e.skewX || e.skewY;
|
|
5044
5073
|
}
|
|
5045
|
-
function
|
|
5074
|
+
function Vr(e) {
|
|
5046
5075
|
return Ps(e.x) || Ps(e.y);
|
|
5047
5076
|
}
|
|
5048
5077
|
function Ps(e) {
|
|
@@ -5058,7 +5087,7 @@ function Vs(e, t, n, i, r) {
|
|
|
5058
5087
|
function gn(e, t = 0, n = 1, i, r) {
|
|
5059
5088
|
e.min = Vs(e.min, t, n, i, r), e.max = Vs(e.max, t, n, i, r);
|
|
5060
5089
|
}
|
|
5061
|
-
function
|
|
5090
|
+
function Cr(e, { x: t, y: n }) {
|
|
5062
5091
|
gn(e.x, t.translate, t.scale, t.originPoint), gn(e.y, n.translate, n.scale, n.originPoint);
|
|
5063
5092
|
}
|
|
5064
5093
|
const Cs = 0.999999999999, Es = 1.0000000000001;
|
|
@@ -5072,29 +5101,29 @@ function cc(e, t, n, i = !1) {
|
|
|
5072
5101
|
for (let c = 0; c < r; c++) {
|
|
5073
5102
|
a = n[c], o = a.projectionDelta;
|
|
5074
5103
|
const { visualElement: h } = a.options;
|
|
5075
|
-
h && h.props.style && h.props.style.display === "contents" || (i && a.options.layoutScroll && a.scroll && a !== a.root && (ue(e.x, -a.scroll.offset.x), ue(e.y, -a.scroll.offset.y)), o && (t.x *= o.x.scale, t.y *= o.y.scale,
|
|
5104
|
+
h && h.props.style && h.props.style.display === "contents" || (i && a.options.layoutScroll && a.scroll && a !== a.root && (ue(e.x, -a.scroll.offset.x), ue(e.y, -a.scroll.offset.y)), o && (t.x *= o.x.scale, t.y *= o.y.scale, Cr(e, o)), i && Me(a.latestValues) && yt(e, a.latestValues, (l = a.layout) == null ? void 0 : l.layoutBox));
|
|
5076
5105
|
}
|
|
5077
5106
|
t.x < Es && t.x > Cs && (t.x = 1), t.y < Es && t.y > Cs && (t.y = 1);
|
|
5078
5107
|
}
|
|
5079
5108
|
function ue(e, t) {
|
|
5080
5109
|
e.min += t, e.max += t;
|
|
5081
5110
|
}
|
|
5082
|
-
function
|
|
5111
|
+
function ks(e, t, n, i, r = 0.5) {
|
|
5083
5112
|
const a = L(e.min, e.max, r);
|
|
5084
5113
|
gn(e, t, n, a, i);
|
|
5085
5114
|
}
|
|
5086
|
-
function
|
|
5115
|
+
function Ds(e, t) {
|
|
5087
5116
|
return typeof e == "string" ? parseFloat(e) / 100 * (t.max - t.min) : e;
|
|
5088
5117
|
}
|
|
5089
5118
|
function yt(e, t, n) {
|
|
5090
5119
|
const i = n ?? e;
|
|
5091
|
-
|
|
5120
|
+
ks(e.x, Ds(t.x, i.x), t.scaleX, t.scale, t.originX), ks(e.y, Ds(t.y, i.y), t.scaleY, t.scale, t.originY);
|
|
5092
5121
|
}
|
|
5093
|
-
function
|
|
5094
|
-
return
|
|
5122
|
+
function Er(e, t) {
|
|
5123
|
+
return Pr(lc(e.getBoundingClientRect(), t));
|
|
5095
5124
|
}
|
|
5096
5125
|
function uc(e, t, n) {
|
|
5097
|
-
const i =
|
|
5126
|
+
const i = Er(e, n), { scroll: r } = t;
|
|
5098
5127
|
return r && (ue(i.x, r.offset.x), ue(i.y, r.offset.y)), i;
|
|
5099
5128
|
}
|
|
5100
5129
|
const hc = {
|
|
@@ -5117,7 +5146,7 @@ function fc(e, t, n) {
|
|
|
5117
5146
|
c = o.startsWith("scale") ? h === 1 : h === 0;
|
|
5118
5147
|
}
|
|
5119
5148
|
if (!c || n) {
|
|
5120
|
-
const h =
|
|
5149
|
+
const h = gr(l, zn[o]);
|
|
5121
5150
|
if (!c) {
|
|
5122
5151
|
r = !1;
|
|
5123
5152
|
const u = hc[o] || o;
|
|
@@ -5136,11 +5165,11 @@ function Kn(e, t, n) {
|
|
|
5136
5165
|
if (We.has(c)) {
|
|
5137
5166
|
o = !0;
|
|
5138
5167
|
continue;
|
|
5139
|
-
} else if (
|
|
5168
|
+
} else if (zi(c)) {
|
|
5140
5169
|
r[c] = h;
|
|
5141
5170
|
continue;
|
|
5142
5171
|
} else {
|
|
5143
|
-
const u =
|
|
5172
|
+
const u = gr(h, zn[c]);
|
|
5144
5173
|
c.startsWith("origin") ? (l = !0, a[c] = u) : i[c] = u;
|
|
5145
5174
|
}
|
|
5146
5175
|
}
|
|
@@ -5149,7 +5178,7 @@ function Kn(e, t, n) {
|
|
|
5149
5178
|
i.transformOrigin = `${c} ${h} ${u}`;
|
|
5150
5179
|
}
|
|
5151
5180
|
}
|
|
5152
|
-
function
|
|
5181
|
+
function kr(e, { style: t, vars: n }, i, r) {
|
|
5153
5182
|
const a = e.style;
|
|
5154
5183
|
let o;
|
|
5155
5184
|
for (o in t)
|
|
@@ -5214,21 +5243,21 @@ function Gn(e, t, n) {
|
|
|
5214
5243
|
function mc(e) {
|
|
5215
5244
|
return window.getComputedStyle(e);
|
|
5216
5245
|
}
|
|
5217
|
-
class xc extends
|
|
5246
|
+
class xc extends Ar {
|
|
5218
5247
|
constructor() {
|
|
5219
|
-
super(...arguments), this.type = "html", this.renderInstance =
|
|
5248
|
+
super(...arguments), this.type = "html", this.renderInstance = kr;
|
|
5220
5249
|
}
|
|
5221
5250
|
readValueFromInstance(t, n) {
|
|
5222
5251
|
var i;
|
|
5223
5252
|
if (We.has(n))
|
|
5224
5253
|
return (i = this.projection) != null && i.isProjecting ? rn(n) : La(t, n);
|
|
5225
5254
|
{
|
|
5226
|
-
const r = mc(t), a = (
|
|
5255
|
+
const r = mc(t), a = (zi(n) ? r.getPropertyValue(n) : r[n]) || 0;
|
|
5227
5256
|
return typeof a == "string" ? a.trim() : a;
|
|
5228
5257
|
}
|
|
5229
5258
|
}
|
|
5230
5259
|
measureInstanceViewportBox(t, { transformPagePoint: n }) {
|
|
5231
|
-
return
|
|
5260
|
+
return Er(t, n);
|
|
5232
5261
|
}
|
|
5233
5262
|
build(t, n, i) {
|
|
5234
5263
|
Kn(t, n, i.transformTemplate);
|
|
@@ -5255,7 +5284,7 @@ const vc = [
|
|
|
5255
5284
|
"offsetRotate",
|
|
5256
5285
|
"offsetAnchor"
|
|
5257
5286
|
];
|
|
5258
|
-
function
|
|
5287
|
+
function Rr(e, {
|
|
5259
5288
|
attrX: t,
|
|
5260
5289
|
attrY: n,
|
|
5261
5290
|
attrScale: i,
|
|
@@ -5276,7 +5305,7 @@ function kr(e, {
|
|
|
5276
5305
|
d[m] !== void 0 && (f[m] = d[m], delete d[m]);
|
|
5277
5306
|
t !== void 0 && (d.x = t), n !== void 0 && (d.y = n), i !== void 0 && (d.scale = i), r !== void 0 && jc(d, r, a, o, !1);
|
|
5278
5307
|
}
|
|
5279
|
-
const
|
|
5308
|
+
const Lr = /* @__PURE__ */ new Set([
|
|
5280
5309
|
"baseFrequency",
|
|
5281
5310
|
"diffuseConstant",
|
|
5282
5311
|
"kernelMatrix",
|
|
@@ -5300,13 +5329,13 @@ const Rr = /* @__PURE__ */ new Set([
|
|
|
5300
5329
|
"startOffset",
|
|
5301
5330
|
"textLength",
|
|
5302
5331
|
"lengthAdjust"
|
|
5303
|
-
]),
|
|
5332
|
+
]), Nr = (e) => typeof e == "string" && e.toLowerCase() === "svg";
|
|
5304
5333
|
function wc(e, t, n, i) {
|
|
5305
|
-
|
|
5334
|
+
kr(e, t, void 0, i);
|
|
5306
5335
|
for (const r in t.attrs)
|
|
5307
|
-
e.setAttribute(
|
|
5336
|
+
e.setAttribute(Lr.has(r) ? r : Bn(r), t.attrs[r]);
|
|
5308
5337
|
}
|
|
5309
|
-
function
|
|
5338
|
+
function Fr(e, t, n) {
|
|
5310
5339
|
const i = Gn(e, t, n);
|
|
5311
5340
|
for (const r in e)
|
|
5312
5341
|
if (W(e[r]) || W(t[r])) {
|
|
@@ -5315,7 +5344,7 @@ function Nr(e, t, n) {
|
|
|
5315
5344
|
}
|
|
5316
5345
|
return i;
|
|
5317
5346
|
}
|
|
5318
|
-
class bc extends
|
|
5347
|
+
class bc extends Ar {
|
|
5319
5348
|
constructor() {
|
|
5320
5349
|
super(...arguments), this.type = "svg", this.isSVGTag = !1, this.measureInstanceViewportBox = H;
|
|
5321
5350
|
}
|
|
@@ -5324,30 +5353,30 @@ class bc extends Sr {
|
|
|
5324
5353
|
}
|
|
5325
5354
|
readValueFromInstance(t, n) {
|
|
5326
5355
|
if (We.has(n)) {
|
|
5327
|
-
const i =
|
|
5356
|
+
const i = mr(n);
|
|
5328
5357
|
return i && i.default || 0;
|
|
5329
5358
|
}
|
|
5330
|
-
return n =
|
|
5359
|
+
return n = Lr.has(n) ? n : Bn(n), t.getAttribute(n);
|
|
5331
5360
|
}
|
|
5332
5361
|
scrapeMotionValuesFromProps(t, n, i) {
|
|
5333
|
-
return
|
|
5362
|
+
return Fr(t, n, i);
|
|
5334
5363
|
}
|
|
5335
5364
|
build(t, n, i) {
|
|
5336
|
-
|
|
5365
|
+
Rr(t, n, this.isSVGTag, i.transformTemplate, i.style);
|
|
5337
5366
|
}
|
|
5338
5367
|
renderInstance(t, n, i, r) {
|
|
5339
5368
|
wc(t, n, i, r);
|
|
5340
5369
|
}
|
|
5341
5370
|
mount(t) {
|
|
5342
|
-
this.isSVGTag =
|
|
5371
|
+
this.isSVGTag = Nr(t.tagName), super.mount(t);
|
|
5343
5372
|
}
|
|
5344
5373
|
}
|
|
5345
5374
|
const Tc = $n.length;
|
|
5346
|
-
function
|
|
5375
|
+
function Ir(e) {
|
|
5347
5376
|
if (!e)
|
|
5348
5377
|
return;
|
|
5349
5378
|
if (!e.isControllingVariants) {
|
|
5350
|
-
const n = e.parent ?
|
|
5379
|
+
const n = e.parent ? Ir(e.parent) || {} : {};
|
|
5351
5380
|
return e.props.initial !== void 0 && (n.initial = e.props.initial), n;
|
|
5352
5381
|
}
|
|
5353
5382
|
const t = {};
|
|
@@ -5387,13 +5416,13 @@ function Pc(e) {
|
|
|
5387
5416
|
t = h(e);
|
|
5388
5417
|
}
|
|
5389
5418
|
function l(h) {
|
|
5390
|
-
const { props: u } = e, d =
|
|
5419
|
+
const { props: u } = e, d = Ir(e.parent) || {}, f = [], m = /* @__PURE__ */ new Set();
|
|
5391
5420
|
let x = {}, g = 1 / 0;
|
|
5392
5421
|
for (let w = 0; w < Sc; w++) {
|
|
5393
5422
|
const v = Mc[w], b = n[v], M = u[v] !== void 0 ? u[v] : d[v], S = et(M), E = v === h ? b.isActive : null;
|
|
5394
5423
|
E === !1 && (g = w);
|
|
5395
|
-
let
|
|
5396
|
-
if (
|
|
5424
|
+
let D = M === d[v] && M !== u[v] && S;
|
|
5425
|
+
if (D && (i || r) && e.manuallyAnimateOnMount && (D = !1), b.protectedKeys = { ...x }, // If it isn't active and hasn't *just* been set as inactive
|
|
5397
5426
|
!b.isActive && E === null || // If we didn't and don't have any defined prop for this animation type
|
|
5398
5427
|
!M && !b.prevProp || // Or if the prop doesn't define an animation
|
|
5399
5428
|
Et(M) || typeof M == "boolean")
|
|
@@ -5406,40 +5435,40 @@ function Pc(e) {
|
|
|
5406
5435
|
continue;
|
|
5407
5436
|
}
|
|
5408
5437
|
const P = Vc(b.prevProp, M);
|
|
5409
|
-
let
|
|
5410
|
-
v === h && b.isActive && !
|
|
5438
|
+
let I = P || // If we're making this variant active, we want to always make it active
|
|
5439
|
+
v === h && b.isActive && !D && S || // If we removed a higher-priority variant (i is in reverse order)
|
|
5411
5440
|
w > g && S, T = !1;
|
|
5412
5441
|
const C = Array.isArray(M) ? M : [M];
|
|
5413
5442
|
let F = C.reduce(a(v), {});
|
|
5414
5443
|
E === !1 && (F = {});
|
|
5415
|
-
const { prevResolvedValues: X = {} } = b,
|
|
5444
|
+
const { prevResolvedValues: X = {} } = b, K = {
|
|
5416
5445
|
...X,
|
|
5417
5446
|
...F
|
|
5418
|
-
}, Q = (
|
|
5419
|
-
|
|
5420
|
-
const _ = e.getValue(
|
|
5447
|
+
}, Q = (O) => {
|
|
5448
|
+
I = !0, m.has(O) && (T = !0, m.delete(O)), b.needsAnimating[O] = !0;
|
|
5449
|
+
const _ = e.getValue(O);
|
|
5421
5450
|
_ && (_.liveStyle = !1);
|
|
5422
5451
|
};
|
|
5423
|
-
for (const
|
|
5424
|
-
const _ = F[
|
|
5425
|
-
if (x.hasOwnProperty(
|
|
5452
|
+
for (const O in K) {
|
|
5453
|
+
const _ = F[O], j = X[O];
|
|
5454
|
+
if (x.hasOwnProperty(O))
|
|
5426
5455
|
continue;
|
|
5427
5456
|
let V = !1;
|
|
5428
|
-
hn(_) && hn(j) ? V = !Or(_, j) : V = _ !== j, V ? _ != null ? Q(
|
|
5457
|
+
hn(_) && hn(j) ? V = !Or(_, j) : V = _ !== j, V ? _ != null ? Q(O) : m.add(O) : _ !== void 0 && m.has(O) ? Q(O) : b.protectedKeys[O] = !0;
|
|
5429
5458
|
}
|
|
5430
|
-
b.prevProp = M, b.prevResolvedValues = F, b.isActive && (x = { ...x, ...F }), (i || r) && e.blockInitialAnimation && (
|
|
5431
|
-
const q =
|
|
5432
|
-
|
|
5459
|
+
b.prevProp = M, b.prevResolvedValues = F, b.isActive && (x = { ...x, ...F }), (i || r) && e.blockInitialAnimation && (I = !1);
|
|
5460
|
+
const q = D && P;
|
|
5461
|
+
I && (!q || T) && f.push(...C.map((O) => {
|
|
5433
5462
|
const _ = { type: v };
|
|
5434
|
-
if (typeof
|
|
5435
|
-
const { parent: j } = e, V = Ve(j,
|
|
5463
|
+
if (typeof O == "string" && (i || r) && !q && e.manuallyAnimateOnMount && e.parent) {
|
|
5464
|
+
const { parent: j } = e, V = Ve(j, O);
|
|
5436
5465
|
if (j.enteringChildren && V) {
|
|
5437
5466
|
const { delayChildren: R } = V.transition || {};
|
|
5438
|
-
_.delay =
|
|
5467
|
+
_.delay = or(j.enteringChildren, e, R);
|
|
5439
5468
|
}
|
|
5440
5469
|
}
|
|
5441
5470
|
return {
|
|
5442
|
-
animation:
|
|
5471
|
+
animation: O,
|
|
5443
5472
|
options: _
|
|
5444
5473
|
};
|
|
5445
5474
|
}));
|
|
@@ -5512,7 +5541,7 @@ function re(e, t) {
|
|
|
5512
5541
|
function Ns(e, t) {
|
|
5513
5542
|
e.translate = t.translate, e.scale = t.scale, e.originPoint = t.originPoint, e.origin = t.origin;
|
|
5514
5543
|
}
|
|
5515
|
-
const
|
|
5544
|
+
const Br = 1e-4, Cc = 1 - Br, Ec = 1 + Br, zr = 0.01, kc = 0 - zr, Dc = 0 + zr;
|
|
5516
5545
|
function J(e) {
|
|
5517
5546
|
return e.max - e.min;
|
|
5518
5547
|
}
|
|
@@ -5520,24 +5549,24 @@ function Rc(e, t, n) {
|
|
|
5520
5549
|
return Math.abs(e - t) <= n;
|
|
5521
5550
|
}
|
|
5522
5551
|
function Fs(e, t, n, i = 0.5) {
|
|
5523
|
-
e.origin = i, e.originPoint = L(t.min, t.max, e.origin), e.scale = J(n) / J(t), e.translate = L(n.min, n.max, e.origin) - e.originPoint, (e.scale >= Cc && e.scale <= Ec || isNaN(e.scale)) && (e.scale = 1), (e.translate >=
|
|
5552
|
+
e.origin = i, e.originPoint = L(t.min, t.max, e.origin), e.scale = J(n) / J(t), e.translate = L(n.min, n.max, e.origin) - e.originPoint, (e.scale >= Cc && e.scale <= Ec || isNaN(e.scale)) && (e.scale = 1), (e.translate >= kc && e.translate <= Dc || isNaN(e.translate)) && (e.translate = 0);
|
|
5524
5553
|
}
|
|
5525
5554
|
function qe(e, t, n, i) {
|
|
5526
5555
|
Fs(e.x, t.x, n.x, i ? i.originX : void 0), Fs(e.y, t.y, n.y, i ? i.originY : void 0);
|
|
5527
5556
|
}
|
|
5528
|
-
function
|
|
5557
|
+
function Is(e, t, n, i = 0) {
|
|
5529
5558
|
const r = i ? L(n.min, n.max, i) : n.min;
|
|
5530
5559
|
e.min = r + t.min, e.max = e.min + J(t);
|
|
5531
5560
|
}
|
|
5532
5561
|
function Lc(e, t, n, i) {
|
|
5533
|
-
|
|
5562
|
+
Is(e.x, t.x, n.x, i == null ? void 0 : i.x), Is(e.y, t.y, n.y, i == null ? void 0 : i.y);
|
|
5534
5563
|
}
|
|
5535
|
-
function
|
|
5564
|
+
function Os(e, t, n, i = 0) {
|
|
5536
5565
|
const r = i ? L(n.min, n.max, i) : n.min;
|
|
5537
5566
|
e.min = t.min - r, e.max = e.min + J(t);
|
|
5538
5567
|
}
|
|
5539
5568
|
function Pt(e, t, n, i) {
|
|
5540
|
-
|
|
5569
|
+
Os(e.x, t.x, n.x, i == null ? void 0 : i.x), Os(e.y, t.y, n.y, i == null ? void 0 : i.y);
|
|
5541
5570
|
}
|
|
5542
5571
|
function Bs(e, t, n, i, r) {
|
|
5543
5572
|
return e -= t, e = At(e, 1 / n, i), r !== void 0 && (e = At(e, 1 / r, i)), e;
|
|
@@ -5551,26 +5580,26 @@ function Nc(e, t = 0, n = 1, i = 0.5, r, a = e, o = e) {
|
|
|
5551
5580
|
function zs(e, t, [n, i, r], a, o) {
|
|
5552
5581
|
Nc(e, t[n], t[i], t[r], t.scale, a, o);
|
|
5553
5582
|
}
|
|
5554
|
-
const Fc = ["x", "scaleX", "originX"],
|
|
5583
|
+
const Fc = ["x", "scaleX", "originX"], Ic = ["y", "scaleY", "originY"];
|
|
5555
5584
|
function Hs(e, t, n, i) {
|
|
5556
|
-
zs(e.x, t, Fc, n ? n.x : void 0, i ? i.x : void 0), zs(e.y, t,
|
|
5585
|
+
zs(e.x, t, Fc, n ? n.x : void 0, i ? i.x : void 0), zs(e.y, t, Ic, n ? n.y : void 0, i ? i.y : void 0);
|
|
5557
5586
|
}
|
|
5558
5587
|
function _s(e) {
|
|
5559
5588
|
return e.translate === 0 && e.scale === 1;
|
|
5560
5589
|
}
|
|
5561
|
-
function
|
|
5590
|
+
function Hr(e) {
|
|
5562
5591
|
return _s(e.x) && _s(e.y);
|
|
5563
5592
|
}
|
|
5564
5593
|
function Us(e, t) {
|
|
5565
5594
|
return e.min === t.min && e.max === t.max;
|
|
5566
5595
|
}
|
|
5567
|
-
function
|
|
5596
|
+
function Oc(e, t) {
|
|
5568
5597
|
return Us(e.x, t.x) && Us(e.y, t.y);
|
|
5569
5598
|
}
|
|
5570
5599
|
function Ws(e, t) {
|
|
5571
5600
|
return Math.round(e.min) === Math.round(t.min) && Math.round(e.max) === Math.round(t.max);
|
|
5572
5601
|
}
|
|
5573
|
-
function
|
|
5602
|
+
function _r(e, t) {
|
|
5574
5603
|
return Ws(e.x, t.x) && Ws(e.y, t.y);
|
|
5575
5604
|
}
|
|
5576
5605
|
function $s(e) {
|
|
@@ -5592,16 +5621,16 @@ function Bc(e, t, n) {
|
|
|
5592
5621
|
const l = e.x.scale * t.x, c = e.y.scale * t.y;
|
|
5593
5622
|
return (l !== 1 || c !== 1) && (i += `scale(${l}, ${c})`), i || "none";
|
|
5594
5623
|
}
|
|
5595
|
-
const
|
|
5624
|
+
const Ur = [
|
|
5596
5625
|
"borderTopLeftRadius",
|
|
5597
5626
|
"borderTopRightRadius",
|
|
5598
5627
|
"borderBottomLeftRadius",
|
|
5599
5628
|
"borderBottomRightRadius"
|
|
5600
|
-
], zc =
|
|
5629
|
+
], zc = Ur.length, Gs = (e) => typeof e == "string" ? parseFloat(e) : e, Ys = (e) => typeof e == "number" || A.test(e);
|
|
5601
5630
|
function Hc(e, t, n, i, r, a) {
|
|
5602
5631
|
r ? (e.opacity = L(0, n.opacity ?? 1, _c(i)), e.opacityExit = L(t.opacity ?? 1, 0, Uc(i))) : a && (e.opacity = L(t.opacity ?? 1, n.opacity ?? 1, i));
|
|
5603
5632
|
for (let o = 0; o < zc; o++) {
|
|
5604
|
-
const l =
|
|
5633
|
+
const l = Ur[o];
|
|
5605
5634
|
let c = Xs(t, l), h = Xs(n, l);
|
|
5606
5635
|
if (c === void 0 && h === void 0)
|
|
5607
5636
|
continue;
|
|
@@ -5612,13 +5641,13 @@ function Hc(e, t, n, i, r, a) {
|
|
|
5612
5641
|
function Xs(e, t) {
|
|
5613
5642
|
return e[t] !== void 0 ? e[t] : e.borderRadius;
|
|
5614
5643
|
}
|
|
5615
|
-
const _c = /* @__PURE__ */
|
|
5616
|
-
function
|
|
5644
|
+
const _c = /* @__PURE__ */ Wr(0, 0.5, Li), Uc = /* @__PURE__ */ Wr(0.5, 0.95, ie);
|
|
5645
|
+
function Wr(e, t, n) {
|
|
5617
5646
|
return (i) => i < e ? 0 : i > t ? 1 : n(/* @__PURE__ */ Je(e, t, i));
|
|
5618
5647
|
}
|
|
5619
5648
|
function Wc(e, t, n) {
|
|
5620
5649
|
const i = W(e) ? e : Be(e);
|
|
5621
|
-
return i.start(
|
|
5650
|
+
return i.start(In("", i, t, n)), i.animation;
|
|
5622
5651
|
}
|
|
5623
5652
|
function tt(e, t, n, i = { passive: !0 }) {
|
|
5624
5653
|
return e.addEventListener(t, n, i), () => e.removeEventListener(t, n);
|
|
@@ -5643,7 +5672,7 @@ function Gc(e, t) {
|
|
|
5643
5672
|
const a = r - n;
|
|
5644
5673
|
a >= t && (we(i), e(a - t));
|
|
5645
5674
|
};
|
|
5646
|
-
return
|
|
5675
|
+
return k.setup(i, !0), () => we(i);
|
|
5647
5676
|
}
|
|
5648
5677
|
function gt(e) {
|
|
5649
5678
|
return W(e) ? e.get() : e;
|
|
@@ -5718,21 +5747,21 @@ function Wt(e, t, n, i) {
|
|
|
5718
5747
|
const { latestValues: r } = t;
|
|
5719
5748
|
r[e] && (n[e] = r[e], t.setStaticValue(e, 0), i && (i[e] = 0));
|
|
5720
5749
|
}
|
|
5721
|
-
function
|
|
5750
|
+
function $r(e) {
|
|
5722
5751
|
if (e.hasCheckedOptimisedAppear = !0, e.root === e)
|
|
5723
5752
|
return;
|
|
5724
5753
|
const { visualElement: t } = e.options;
|
|
5725
5754
|
if (!t)
|
|
5726
5755
|
return;
|
|
5727
|
-
const n =
|
|
5756
|
+
const n = hr(t);
|
|
5728
5757
|
if (window.MotionHasOptimisedAnimation(n, "transform")) {
|
|
5729
5758
|
const { layout: r, layoutId: a } = e.options;
|
|
5730
|
-
window.MotionCancelOptimisedAnimation(n, "transform",
|
|
5759
|
+
window.MotionCancelOptimisedAnimation(n, "transform", k, !(r || a));
|
|
5731
5760
|
}
|
|
5732
5761
|
const { parent: i } = e;
|
|
5733
|
-
i && !i.hasCheckedOptimisedAppear &&
|
|
5762
|
+
i && !i.hasCheckedOptimisedAppear && $r(i);
|
|
5734
5763
|
}
|
|
5735
|
-
function
|
|
5764
|
+
function Kr({ attachResizeListener: e, defaultParent: t, measureScroll: n, checkIsScrollRoot: i, resetTransform: r }) {
|
|
5736
5765
|
return class {
|
|
5737
5766
|
constructor(o = {}, l = t == null ? void 0 : t()) {
|
|
5738
5767
|
this.id = qc++, this.animationId = 0, this.animationCommitId = 0, this.children = /* @__PURE__ */ new Set(), this.options = {}, this.isTreeAnimating = !1, this.isAnimationBlocked = !1, this.isLayoutDirty = !1, this.isProjectionDirty = !1, this.isSharedProjectionDirty = !1, this.isTransformDirty = !1, this.updateManuallyBlocked = !1, this.updateBlockedByResize = !1, this.isUpdating = !1, this.isSVG = !1, this.needsReset = !1, this.shouldResetTransform = !1, this.hasCheckedOptimisedAppear = !1, this.treeScale = { x: 1, y: 1 }, this.eventHandlers = /* @__PURE__ */ new Map(), this.hasTreeAnimated = !1, this.layoutVersion = 0, this.updateScheduled = !1, this.scheduleUpdate = () => this.update(), this.projectionUpdateScheduled = !1, this.checkUpdateFailed = () => {
|
|
@@ -5765,7 +5794,7 @@ function $r({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
5765
5794
|
if (h && !h.current && h.mount(o), this.root.nodes.add(this), this.parent && this.parent.children.add(this), this.root.hasTreeAnimated && (c || l) && (this.isLayoutDirty = !0), e) {
|
|
5766
5795
|
let u, d = 0;
|
|
5767
5796
|
const f = () => this.root.updateBlockedByResize = !1;
|
|
5768
|
-
|
|
5797
|
+
k.read(() => {
|
|
5769
5798
|
d = window.innerWidth;
|
|
5770
5799
|
}), e(o, () => {
|
|
5771
5800
|
const m = window.innerWidth;
|
|
@@ -5777,7 +5806,7 @@ function $r({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
5777
5806
|
this.target = void 0, this.relativeTarget = void 0;
|
|
5778
5807
|
return;
|
|
5779
5808
|
}
|
|
5780
|
-
const x = this.options.transition || h.getDefaultTransition() || hu, { onLayoutAnimationStart: g, onLayoutAnimationComplete: y } = h.getProps(), w = !this.targetLayout || !
|
|
5809
|
+
const x = this.options.transition || h.getDefaultTransition() || hu, { onLayoutAnimationStart: g, onLayoutAnimationComplete: y } = h.getProps(), w = !this.targetLayout || !_r(this.targetLayout, m), v = !d && f;
|
|
5781
5810
|
if (this.options.layoutRoot || this.resumeFrom || v || d && (w || !this.currentAnimation)) {
|
|
5782
5811
|
this.resumeFrom && (this.resumingFrom = this.resumeFrom, this.resumingFrom.resumingFrom = void 0);
|
|
5783
5812
|
const b = {
|
|
@@ -5822,7 +5851,7 @@ function $r({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
5822
5851
|
this.options.onExitComplete && this.options.onExitComplete();
|
|
5823
5852
|
return;
|
|
5824
5853
|
}
|
|
5825
|
-
if (window.MotionCancelOptimisedAnimation && !this.hasCheckedOptimisedAppear &&
|
|
5854
|
+
if (window.MotionCancelOptimisedAnimation && !this.hasCheckedOptimisedAppear && $r(this), !this.root.isUpdating && this.root.startUpdate(), this.isLayoutDirty)
|
|
5826
5855
|
return;
|
|
5827
5856
|
this.isLayoutDirty = !0;
|
|
5828
5857
|
for (let u = 0; u < this.path.length; u++) {
|
|
@@ -5856,10 +5885,10 @@ function $r({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
5856
5885
|
this.nodes.forEach(tu), this.sharedNodes.forEach(lu);
|
|
5857
5886
|
}
|
|
5858
5887
|
scheduleUpdateProjection() {
|
|
5859
|
-
this.projectionUpdateScheduled || (this.projectionUpdateScheduled = !0,
|
|
5888
|
+
this.projectionUpdateScheduled || (this.projectionUpdateScheduled = !0, k.preRender(this.updateProjection, !1, !0));
|
|
5860
5889
|
}
|
|
5861
5890
|
scheduleCheckAfterUnmount() {
|
|
5862
|
-
|
|
5891
|
+
k.postRender(() => {
|
|
5863
5892
|
this.isLayoutDirty ? this.root.didUpdate() : this.root.checkUpdateFailed();
|
|
5864
5893
|
});
|
|
5865
5894
|
}
|
|
@@ -5896,7 +5925,7 @@ function $r({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
5896
5925
|
resetTransform() {
|
|
5897
5926
|
if (!r)
|
|
5898
5927
|
return;
|
|
5899
|
-
const o = this.isLayoutDirty || this.shouldResetTransform || this.options.alwaysMeasureLayout, l = this.projectionDelta && !
|
|
5928
|
+
const o = this.isLayoutDirty || this.shouldResetTransform || this.options.alwaysMeasureLayout, l = this.projectionDelta && !Hr(this.projectionDelta), c = this.getTransformTemplate(), h = c ? c(this.latestValues, "") : void 0, u = h !== this.prevTransformTemplateValue;
|
|
5900
5929
|
o && this.instance && (l || Me(this.latestValues) || u) && (r(this.instance, h), this.shouldResetTransform = !1, this.scheduleRender());
|
|
5901
5930
|
}
|
|
5902
5931
|
measure(o = !0) {
|
|
@@ -5984,10 +6013,10 @@ function $r({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
5984
6013
|
return;
|
|
5985
6014
|
this.resolvedRelativeTargetAt = U.timestamp;
|
|
5986
6015
|
const f = this.getClosestProjectingParent();
|
|
5987
|
-
f && this.linkedParentVersion !== f.layoutVersion && !f.options.layoutRoot && this.removeRelativeTarget(), !this.targetDelta && !this.relativeTarget && (this.options.layoutAnchor !== !1 && f && f.layout ? this.createRelativeTarget(f, this.layout.layoutBox, f.layout.layoutBox) : this.removeRelativeTarget()), !(!this.relativeTarget && !this.targetDelta) && (this.target || (this.target = H(), this.targetWithTransforms = H()), this.relativeTarget && this.relativeTargetOrigin && this.relativeParent && this.relativeParent.target ? (this.forceRelativeParentToResolveTarget(), Lc(this.target, this.relativeTarget, this.relativeParent.target, this.options.layoutAnchor || void 0)) : this.targetDelta ? (this.resumingFrom ? this.applyTransform(this.layout.layoutBox, !1, this.target) : re(this.target, this.layout.layoutBox),
|
|
6016
|
+
f && this.linkedParentVersion !== f.layoutVersion && !f.options.layoutRoot && this.removeRelativeTarget(), !this.targetDelta && !this.relativeTarget && (this.options.layoutAnchor !== !1 && f && f.layout ? this.createRelativeTarget(f, this.layout.layoutBox, f.layout.layoutBox) : this.removeRelativeTarget()), !(!this.relativeTarget && !this.targetDelta) && (this.target || (this.target = H(), this.targetWithTransforms = H()), this.relativeTarget && this.relativeTargetOrigin && this.relativeParent && this.relativeParent.target ? (this.forceRelativeParentToResolveTarget(), Lc(this.target, this.relativeTarget, this.relativeParent.target, this.options.layoutAnchor || void 0)) : this.targetDelta ? (this.resumingFrom ? this.applyTransform(this.layout.layoutBox, !1, this.target) : re(this.target, this.layout.layoutBox), Cr(this.target, this.targetDelta)) : re(this.target, this.layout.layoutBox), this.attemptToResolveRelativeTarget && (this.attemptToResolveRelativeTarget = !1, this.options.layoutAnchor !== !1 && f && !!f.resumingFrom == !!this.resumingFrom && !f.options.layoutScroll && f.target && this.animationProgress !== 1 ? this.createRelativeTarget(f, this.target, f.target) : this.relativeParent = this.relativeTarget = void 0));
|
|
5988
6017
|
}
|
|
5989
6018
|
getClosestProjectingParent() {
|
|
5990
|
-
if (!(!this.parent || yn(this.parent.latestValues) ||
|
|
6019
|
+
if (!(!this.parent || yn(this.parent.latestValues) || Vr(this.parent.latestValues)))
|
|
5991
6020
|
return this.parent.isProjecting() ? this.parent : this.parent.getClosestProjectingParent();
|
|
5992
6021
|
}
|
|
5993
6022
|
isProjecting() {
|
|
@@ -6043,12 +6072,12 @@ function $r({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
6043
6072
|
let b;
|
|
6044
6073
|
this.mixTargetDelta = (M) => {
|
|
6045
6074
|
const S = M / 1e3;
|
|
6046
|
-
Qs(d.x, o.x, S), Qs(d.y, o.y, S), this.setTargetDelta(d), this.relativeTarget && this.relativeTargetOrigin && this.layout && this.relativeParent && this.relativeParent.layout && (Pt(f, this.layout.layoutBox, this.relativeParent.layout.layoutBox, this.options.layoutAnchor || void 0), cu(this.relativeTarget, this.relativeTargetOrigin, f, S), b &&
|
|
6075
|
+
Qs(d.x, o.x, S), Qs(d.y, o.y, S), this.setTargetDelta(d), this.relativeTarget && this.relativeTargetOrigin && this.layout && this.relativeParent && this.relativeParent.layout && (Pt(f, this.layout.layoutBox, this.relativeParent.layout.layoutBox, this.options.layoutAnchor || void 0), cu(this.relativeTarget, this.relativeTargetOrigin, f, S), b && Oc(this.relativeTarget, b) && (this.isProjectionDirty = !1), b || (b = H()), re(b, this.relativeTarget)), g && (this.animationValues = u, Hc(u, h, this.latestValues, S, v, w)), this.root.scheduleUpdateProjection(), this.scheduleRender(), this.animationProgress = S;
|
|
6047
6076
|
}, this.mixTargetDelta(this.options.layoutRoot ? 1e3 : 0);
|
|
6048
6077
|
}
|
|
6049
6078
|
startAnimation(o) {
|
|
6050
6079
|
var l, c, h;
|
|
6051
|
-
this.notifyListeners("animationStart"), (l = this.currentAnimation) == null || l.stop(), (h = (c = this.resumingFrom) == null ? void 0 : c.currentAnimation) == null || h.stop(), this.pendingAnimation && (we(this.pendingAnimation), this.pendingAnimation = void 0), this.pendingAnimation =
|
|
6080
|
+
this.notifyListeners("animationStart"), (l = this.currentAnimation) == null || l.stop(), (h = (c = this.resumingFrom) == null ? void 0 : c.currentAnimation) == null || h.stop(), this.pendingAnimation && (we(this.pendingAnimation), this.pendingAnimation = void 0), this.pendingAnimation = k.update(() => {
|
|
6052
6081
|
jt.hasAnimatedSinceResize = !0, this.motionValue || (this.motionValue = Be(0)), this.motionValue.jump(0, !1), this.currentAnimation = Wc(this.motionValue, [0, 1e3], {
|
|
6053
6082
|
...o,
|
|
6054
6083
|
velocity: 0,
|
|
@@ -6076,7 +6105,7 @@ function $r({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
6076
6105
|
const o = this.getLead();
|
|
6077
6106
|
let { targetWithTransforms: l, target: c, layout: h, latestValues: u } = o;
|
|
6078
6107
|
if (!(!l || !c || !h)) {
|
|
6079
|
-
if (this !== o && this.layout && h &&
|
|
6108
|
+
if (this !== o && this.layout && h && Gr(this.options.animationType, this.layout.layoutBox, h.layoutBox)) {
|
|
6080
6109
|
c = this.target || H();
|
|
6081
6110
|
const d = J(this.layout.layoutBox.x);
|
|
6082
6111
|
c.x.min = o.target.x.min, c.x.max = c.x.min + d;
|
|
@@ -6203,7 +6232,7 @@ function Jc(e) {
|
|
|
6203
6232
|
else if (a === "x" || a === "y") {
|
|
6204
6233
|
const d = a === "x" ? "y" : "x";
|
|
6205
6234
|
vn(o ? t.measuredBox[d] : t.layoutBox[d], i[d]);
|
|
6206
|
-
} else
|
|
6235
|
+
} else Gr(a, t.layoutBox, i) && ce((d) => {
|
|
6207
6236
|
const f = o ? t.measuredBox[d] : t.layoutBox[d], m = J(i[d]);
|
|
6208
6237
|
f.max = f.min + m, e.relativeTarget && !e.currentAnimation && (e.isProjectionDirty = !0, e.relativeTarget[d].max = e.relativeTarget[d].min + m);
|
|
6209
6238
|
});
|
|
@@ -6211,7 +6240,7 @@ function Jc(e) {
|
|
|
6211
6240
|
qe(l, i, t.layoutBox);
|
|
6212
6241
|
const c = Fe();
|
|
6213
6242
|
o ? qe(c, e.applyTransform(r, !0), t.measuredBox) : qe(c, i, t.layoutBox);
|
|
6214
|
-
const h = !
|
|
6243
|
+
const h = !Hr(l);
|
|
6215
6244
|
let u = !1;
|
|
6216
6245
|
if (!e.resumeFrom) {
|
|
6217
6246
|
const d = e.getClosestProjectingParent();
|
|
@@ -6221,7 +6250,7 @@ function Jc(e) {
|
|
|
6221
6250
|
const x = e.options.layoutAnchor || void 0, g = H();
|
|
6222
6251
|
Pt(g, t.layoutBox, f.layoutBox, x);
|
|
6223
6252
|
const y = H();
|
|
6224
|
-
Pt(y, i, m.layoutBox, x),
|
|
6253
|
+
Pt(y, i, m.layoutBox, x), _r(g, y) || (u = !0), d.options.layoutRoot && (e.relativeTarget = y, e.relativeTargetOrigin = g, e.relativeParent = d);
|
|
6225
6254
|
}
|
|
6226
6255
|
}
|
|
6227
6256
|
}
|
|
@@ -6301,14 +6330,14 @@ function si(e) {
|
|
|
6301
6330
|
function du(e) {
|
|
6302
6331
|
si(e.x), si(e.y);
|
|
6303
6332
|
}
|
|
6304
|
-
function
|
|
6333
|
+
function Gr(e, t, n) {
|
|
6305
6334
|
return e === "position" || e === "preserve-aspect" && !Rc($s(t), $s(n), 0.2);
|
|
6306
6335
|
}
|
|
6307
6336
|
function fu(e) {
|
|
6308
6337
|
var t;
|
|
6309
6338
|
return e !== e.root && ((t = e.scroll) == null ? void 0 : t.wasRoot);
|
|
6310
6339
|
}
|
|
6311
|
-
const pu =
|
|
6340
|
+
const pu = Kr({
|
|
6312
6341
|
attachResizeListener: (e, t) => tt(e, "resize", t),
|
|
6313
6342
|
measureScroll: () => {
|
|
6314
6343
|
var e, t;
|
|
@@ -6320,7 +6349,7 @@ const pu = $r({
|
|
|
6320
6349
|
checkIsScrollRoot: () => !0
|
|
6321
6350
|
}), $t = {
|
|
6322
6351
|
current: void 0
|
|
6323
|
-
},
|
|
6352
|
+
}, Yr = Kr({
|
|
6324
6353
|
measureScroll: (e) => ({
|
|
6325
6354
|
x: e.scrollLeft,
|
|
6326
6355
|
y: e.scrollTop
|
|
@@ -6336,7 +6365,7 @@ const pu = $r({
|
|
|
6336
6365
|
e.style.transform = t !== void 0 ? t : "none";
|
|
6337
6366
|
},
|
|
6338
6367
|
checkIsScrollRoot: (e) => window.getComputedStyle(e).position === "fixed"
|
|
6339
|
-
}),
|
|
6368
|
+
}), Xr = ze({
|
|
6340
6369
|
transformPagePoint: (e) => e,
|
|
6341
6370
|
isStatic: !1,
|
|
6342
6371
|
reducedMotion: "never"
|
|
@@ -6345,7 +6374,7 @@ function mu(e = !0) {
|
|
|
6345
6374
|
const t = ee(Tn);
|
|
6346
6375
|
if (t === null)
|
|
6347
6376
|
return [!0, null];
|
|
6348
|
-
const { isPresent: n, onExitComplete: i, register: r } = t, a =
|
|
6377
|
+
const { isPresent: n, onExitComplete: i, register: r } = t, a = uo();
|
|
6349
6378
|
je(() => {
|
|
6350
6379
|
if (e)
|
|
6351
6380
|
return r(a);
|
|
@@ -6353,7 +6382,7 @@ function mu(e = !0) {
|
|
|
6353
6382
|
const o = Ce(() => e && i && i(a), [a, i, e]);
|
|
6354
6383
|
return !n && i ? [!1, o] : [!0];
|
|
6355
6384
|
}
|
|
6356
|
-
const
|
|
6385
|
+
const qr = ze({ strict: !1 }), ii = {
|
|
6357
6386
|
animation: [
|
|
6358
6387
|
"animate",
|
|
6359
6388
|
"variants",
|
|
@@ -6382,19 +6411,19 @@ function xu() {
|
|
|
6382
6411
|
e[t] = {
|
|
6383
6412
|
isEnabled: (n) => ii[t].some((i) => !!n[i])
|
|
6384
6413
|
};
|
|
6385
|
-
|
|
6414
|
+
Sr(e), ri = !0;
|
|
6386
6415
|
}
|
|
6387
|
-
function
|
|
6416
|
+
function Zr() {
|
|
6388
6417
|
return xu(), rc();
|
|
6389
6418
|
}
|
|
6390
6419
|
function yu(e) {
|
|
6391
|
-
const t =
|
|
6420
|
+
const t = Zr();
|
|
6392
6421
|
for (const n in e)
|
|
6393
6422
|
t[n] = {
|
|
6394
6423
|
...t[n],
|
|
6395
6424
|
...e[n]
|
|
6396
6425
|
};
|
|
6397
|
-
|
|
6426
|
+
Sr(t);
|
|
6398
6427
|
}
|
|
6399
6428
|
const gu = /* @__PURE__ */ new Set([
|
|
6400
6429
|
"animate",
|
|
@@ -6432,9 +6461,9 @@ const gu = /* @__PURE__ */ new Set([
|
|
|
6432
6461
|
function Vt(e) {
|
|
6433
6462
|
return e.startsWith("while") || e.startsWith("drag") && e !== "draggable" || e.startsWith("layout") || e.startsWith("onTap") || e.startsWith("onPan") || e.startsWith("onLayout") || gu.has(e);
|
|
6434
6463
|
}
|
|
6435
|
-
let
|
|
6464
|
+
let Jr = (e) => !Vt(e);
|
|
6436
6465
|
function ju(e) {
|
|
6437
|
-
typeof e == "function" && (
|
|
6466
|
+
typeof e == "function" && (Jr = (t) => t.startsWith("on") ? !Vt(t) : e(t));
|
|
6438
6467
|
}
|
|
6439
6468
|
try {
|
|
6440
6469
|
ju(require("@emotion/is-prop-valid").default);
|
|
@@ -6443,13 +6472,13 @@ try {
|
|
|
6443
6472
|
function vu(e, t, n) {
|
|
6444
6473
|
const i = {};
|
|
6445
6474
|
for (const r in e)
|
|
6446
|
-
r === "values" && typeof e.values == "object" || W(e[r]) || (
|
|
6475
|
+
r === "values" && typeof e.values == "object" || W(e[r]) || (Jr(r) || n === !0 && Vt(r) || !t && !Vt(r) || // If trying to use native HTML drag events, forward drag listeners
|
|
6447
6476
|
e.draggable && r.startsWith("onDrag")) && (i[r] = e[r]);
|
|
6448
6477
|
return i;
|
|
6449
6478
|
}
|
|
6450
|
-
const
|
|
6479
|
+
const Dt = /* @__PURE__ */ ze({});
|
|
6451
6480
|
function wu(e, t) {
|
|
6452
|
-
if (
|
|
6481
|
+
if (kt(e)) {
|
|
6453
6482
|
const { initial: n, animate: i } = e;
|
|
6454
6483
|
return {
|
|
6455
6484
|
initial: n === !1 || et(n) ? n : void 0,
|
|
@@ -6459,8 +6488,8 @@ function wu(e, t) {
|
|
|
6459
6488
|
return e.inherit !== !1 ? t : {};
|
|
6460
6489
|
}
|
|
6461
6490
|
function bu(e) {
|
|
6462
|
-
const { initial: t, animate: n } = wu(e, ee(
|
|
6463
|
-
return
|
|
6491
|
+
const { initial: t, animate: n } = wu(e, ee(Dt));
|
|
6492
|
+
return Ie(() => ({ initial: t, animate: n }), [oi(t), oi(n)]);
|
|
6464
6493
|
}
|
|
6465
6494
|
function oi(e) {
|
|
6466
6495
|
return Array.isArray(e) ? e.join(" ") : e;
|
|
@@ -6471,39 +6500,39 @@ const Yn = () => ({
|
|
|
6471
6500
|
transformOrigin: {},
|
|
6472
6501
|
vars: {}
|
|
6473
6502
|
});
|
|
6474
|
-
function
|
|
6503
|
+
function Qr(e, t, n) {
|
|
6475
6504
|
for (const i in t)
|
|
6476
6505
|
!W(t[i]) && !Dr(i, n) && (e[i] = t[i]);
|
|
6477
6506
|
}
|
|
6478
6507
|
function Tu({ transformTemplate: e }, t) {
|
|
6479
|
-
return
|
|
6508
|
+
return Ie(() => {
|
|
6480
6509
|
const n = Yn();
|
|
6481
6510
|
return Kn(n, t, e), Object.assign({}, n.vars, n.style);
|
|
6482
6511
|
}, [t]);
|
|
6483
6512
|
}
|
|
6484
6513
|
function Mu(e, t) {
|
|
6485
6514
|
const n = e.style || {}, i = {};
|
|
6486
|
-
return
|
|
6515
|
+
return Qr(i, n, e), Object.assign(i, Tu(e, t)), i;
|
|
6487
6516
|
}
|
|
6488
6517
|
function Su(e, t) {
|
|
6489
6518
|
const n = {}, i = Mu(e, t);
|
|
6490
6519
|
return e.drag && e.dragListener !== !1 && (n.draggable = !1, i.userSelect = i.WebkitUserSelect = i.WebkitTouchCallout = "none", i.touchAction = e.drag === !0 ? "none" : `pan-${e.drag === "x" ? "y" : "x"}`), e.tabIndex === void 0 && (e.onTap || e.onTapStart || e.whileTap) && (n.tabIndex = 0), n.style = i, n;
|
|
6491
6520
|
}
|
|
6492
|
-
const
|
|
6521
|
+
const eo = () => ({
|
|
6493
6522
|
...Yn(),
|
|
6494
6523
|
attrs: {}
|
|
6495
6524
|
});
|
|
6496
6525
|
function Au(e, t, n, i) {
|
|
6497
|
-
const r =
|
|
6498
|
-
const a =
|
|
6499
|
-
return
|
|
6526
|
+
const r = Ie(() => {
|
|
6527
|
+
const a = eo();
|
|
6528
|
+
return Rr(a, t, Nr(i), e.transformTemplate, e.style), {
|
|
6500
6529
|
...a.attrs,
|
|
6501
6530
|
style: { ...a.style }
|
|
6502
6531
|
};
|
|
6503
6532
|
}, [t]);
|
|
6504
6533
|
if (e.style) {
|
|
6505
6534
|
const a = {};
|
|
6506
|
-
|
|
6535
|
+
Qr(a, e.style, e), r.style = { ...a, ...r.style };
|
|
6507
6536
|
}
|
|
6508
6537
|
return r;
|
|
6509
6538
|
}
|
|
@@ -6555,8 +6584,8 @@ function Xn(e) {
|
|
|
6555
6584
|
);
|
|
6556
6585
|
}
|
|
6557
6586
|
function Vu(e, t, n, { latestValues: i }, r, a = !1, o) {
|
|
6558
|
-
const c = (o ?? Xn(e) ? Au : Su)(t, i, r, e), h = vu(t, typeof e == "string", a), u = e !== p ? { ...h, ...c, ref: n } : {}, { children: d } = t, f =
|
|
6559
|
-
return
|
|
6587
|
+
const c = (o ?? Xn(e) ? Au : Su)(t, i, r, e), h = vu(t, typeof e == "string", a), u = e !== p ? { ...h, ...c, ref: n } : {}, { children: d } = t, f = Ie(() => W(d) ? d.get() : d, [d]);
|
|
6588
|
+
return ho(e, {
|
|
6560
6589
|
...u,
|
|
6561
6590
|
children: f
|
|
6562
6591
|
});
|
|
@@ -6572,7 +6601,7 @@ function Eu(e, t, n, i) {
|
|
|
6572
6601
|
for (const f in a)
|
|
6573
6602
|
r[f] = gt(a[f]);
|
|
6574
6603
|
let { initial: o, animate: l } = e;
|
|
6575
|
-
const c =
|
|
6604
|
+
const c = kt(e), h = Tr(e);
|
|
6576
6605
|
t && h && !c && e.inherit !== !1 && (o === void 0 && (o = t.initial), l === void 0 && (l = t.animate));
|
|
6577
6606
|
let u = n ? n.initial === !1 : !1;
|
|
6578
6607
|
u = u || o === !1;
|
|
@@ -6580,7 +6609,7 @@ function Eu(e, t, n, i) {
|
|
|
6580
6609
|
if (d && typeof d != "boolean" && !Et(d)) {
|
|
6581
6610
|
const f = Array.isArray(d) ? d : [d];
|
|
6582
6611
|
for (let m = 0; m < f.length; m++) {
|
|
6583
|
-
const x =
|
|
6612
|
+
const x = On(e, f[m]);
|
|
6584
6613
|
if (x) {
|
|
6585
6614
|
const { transitionEnd: g, transition: y, ...w } = x;
|
|
6586
6615
|
for (const v in w) {
|
|
@@ -6598,15 +6627,15 @@ function Eu(e, t, n, i) {
|
|
|
6598
6627
|
}
|
|
6599
6628
|
return r;
|
|
6600
6629
|
}
|
|
6601
|
-
const
|
|
6602
|
-
const i = ee(
|
|
6630
|
+
const to = (e) => (t, n) => {
|
|
6631
|
+
const i = ee(Dt), r = ee(Tn), a = () => Cu(e, t, i, r);
|
|
6603
6632
|
return n ? a() : Po(a);
|
|
6604
|
-
},
|
|
6633
|
+
}, ku = /* @__PURE__ */ to({
|
|
6605
6634
|
scrapeMotionValuesFromProps: Gn,
|
|
6606
6635
|
createRenderState: Yn
|
|
6607
|
-
}),
|
|
6608
|
-
scrapeMotionValuesFromProps:
|
|
6609
|
-
createRenderState:
|
|
6636
|
+
}), Du = /* @__PURE__ */ to({
|
|
6637
|
+
scrapeMotionValuesFromProps: Fr,
|
|
6638
|
+
createRenderState: eo
|
|
6610
6639
|
}), Ru = Symbol.for("motionComponentSymbol");
|
|
6611
6640
|
function Lu(e, t, n) {
|
|
6612
6641
|
const i = fe(n);
|
|
@@ -6627,13 +6656,13 @@ function Lu(e, t, n) {
|
|
|
6627
6656
|
t && (a ? t.mount(a) : t.unmount());
|
|
6628
6657
|
}, [t]);
|
|
6629
6658
|
}
|
|
6630
|
-
const
|
|
6631
|
-
function
|
|
6659
|
+
const no = ze({});
|
|
6660
|
+
function De(e) {
|
|
6632
6661
|
return e && typeof e == "object" && Object.prototype.hasOwnProperty.call(e, "current");
|
|
6633
6662
|
}
|
|
6634
6663
|
function Nu(e, t, n, i, r, a) {
|
|
6635
6664
|
var b, M;
|
|
6636
|
-
const { visualElement: o } = ee(
|
|
6665
|
+
const { visualElement: o } = ee(Dt), l = ee(qr), c = ee(Tn), h = ee(Xr), u = h.reducedMotion, d = h.skipAnimations, f = fe(null), m = fe(!1);
|
|
6637
6666
|
i = i || l.renderer, !f.current && i && (f.current = i(e, {
|
|
6638
6667
|
visualState: t,
|
|
6639
6668
|
parent: o,
|
|
@@ -6644,13 +6673,13 @@ function Nu(e, t, n, i, r, a) {
|
|
|
6644
6673
|
skipAnimations: d,
|
|
6645
6674
|
isSVG: a
|
|
6646
6675
|
}), m.current && f.current && (f.current.manuallyAnimateOnMount = !0));
|
|
6647
|
-
const x = f.current, g = ee(
|
|
6676
|
+
const x = f.current, g = ee(no);
|
|
6648
6677
|
x && !x.projection && r && (x.type === "html" || x.type === "svg") && Fu(f.current, n, r, g);
|
|
6649
6678
|
const y = fe(!1);
|
|
6650
6679
|
ji(() => {
|
|
6651
6680
|
x && y.current && x.update(n, c);
|
|
6652
6681
|
});
|
|
6653
|
-
const w = n[
|
|
6682
|
+
const w = n[ur], v = fe(!!w && typeof window < "u" && !((b = window.MotionHandoffIsComplete) != null && b.call(window, w)) && ((M = window.MotionHasOptimisedAnimation) == null ? void 0 : M.call(window, w)));
|
|
6654
6683
|
return Co(() => {
|
|
6655
6684
|
m.current = !0, x && (y.current = !0, window.MotionIsMounted = !0, x.updateFeatures(), x.scheduleRenderMicrotask(), v.current && x.animationState && x.animationState.animateChanges());
|
|
6656
6685
|
}), je(() => {
|
|
@@ -6662,10 +6691,10 @@ function Nu(e, t, n, i, r, a) {
|
|
|
6662
6691
|
}
|
|
6663
6692
|
function Fu(e, t, n, i) {
|
|
6664
6693
|
const { layoutId: r, layout: a, drag: o, dragConstraints: l, layoutScroll: c, layoutRoot: h, layoutAnchor: u, layoutCrossfade: d } = t;
|
|
6665
|
-
e.projection = new n(e.latestValues, t["data-framer-portal-id"] ? void 0 :
|
|
6694
|
+
e.projection = new n(e.latestValues, t["data-framer-portal-id"] ? void 0 : so(e.parent)), e.projection.setOptions({
|
|
6666
6695
|
layoutId: r,
|
|
6667
6696
|
layout: a,
|
|
6668
|
-
alwaysMeasureLayout: !!o || l &&
|
|
6697
|
+
alwaysMeasureLayout: !!o || l && De(l),
|
|
6669
6698
|
visualElement: e,
|
|
6670
6699
|
/**
|
|
6671
6700
|
* TODO: Update options in an effect. This could be tricky as it'll be too late
|
|
@@ -6682,44 +6711,44 @@ function Fu(e, t, n, i) {
|
|
|
6682
6711
|
layoutAnchor: u
|
|
6683
6712
|
});
|
|
6684
6713
|
}
|
|
6685
|
-
function
|
|
6714
|
+
function so(e) {
|
|
6686
6715
|
if (e)
|
|
6687
|
-
return e.options.allowProjection !== !1 ? e.projection :
|
|
6716
|
+
return e.options.allowProjection !== !1 ? e.projection : so(e.parent);
|
|
6688
6717
|
}
|
|
6689
6718
|
function Kt(e, { forwardMotionProps: t = !1, type: n } = {}, i, r) {
|
|
6690
6719
|
i && yu(i);
|
|
6691
|
-
const a = n ? n === "svg" : Xn(e), o = a ?
|
|
6720
|
+
const a = n ? n === "svg" : Xn(e), o = a ? Du : ku;
|
|
6692
6721
|
function l(h, u) {
|
|
6693
6722
|
let d;
|
|
6694
6723
|
const f = {
|
|
6695
|
-
...ee(
|
|
6724
|
+
...ee(Xr),
|
|
6696
6725
|
...h,
|
|
6697
|
-
layoutId:
|
|
6726
|
+
layoutId: Iu(h)
|
|
6698
6727
|
}, { isStatic: m } = f, x = bu(h), g = o(h, m);
|
|
6699
6728
|
if (!m && typeof window < "u") {
|
|
6700
|
-
|
|
6729
|
+
Ou(f, i);
|
|
6701
6730
|
const y = Bu(f);
|
|
6702
6731
|
d = y.MeasureLayout, x.visualElement = Nu(e, g, f, r, y.ProjectionNode, a);
|
|
6703
6732
|
}
|
|
6704
|
-
return s.jsxs(
|
|
6733
|
+
return s.jsxs(Dt.Provider, { value: x, children: [d && x.visualElement ? s.jsx(d, { visualElement: x.visualElement, ...f }) : null, Vu(e, h, Lu(g, x.visualElement, u), g, m, t, a)] });
|
|
6705
6734
|
}
|
|
6706
6735
|
l.displayName = `motion.${typeof e == "string" ? e : `create(${e.displayName ?? e.name ?? ""})`}`;
|
|
6707
|
-
const c =
|
|
6736
|
+
const c = fo(l);
|
|
6708
6737
|
return c[Ru] = e, c;
|
|
6709
6738
|
}
|
|
6710
|
-
function
|
|
6711
|
-
const t = ee(
|
|
6739
|
+
function Iu({ layoutId: e }) {
|
|
6740
|
+
const t = ee(bi).id;
|
|
6712
6741
|
return t && e !== void 0 ? t + "-" + e : e;
|
|
6713
6742
|
}
|
|
6714
|
-
function
|
|
6715
|
-
const n = ee(
|
|
6743
|
+
function Ou(e, t) {
|
|
6744
|
+
const n = ee(qr).strict;
|
|
6716
6745
|
if (process.env.NODE_ENV !== "production" && t && n) {
|
|
6717
6746
|
const i = "You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";
|
|
6718
6747
|
e.ignoreStrict ? He(!1, i, "lazy-strict-mode") : pe(!1, i, "lazy-strict-mode");
|
|
6719
6748
|
}
|
|
6720
6749
|
}
|
|
6721
6750
|
function Bu(e) {
|
|
6722
|
-
const t =
|
|
6751
|
+
const t = Zr(), { drag: n, layout: i } = t;
|
|
6723
6752
|
if (!n && !i)
|
|
6724
6753
|
return {};
|
|
6725
6754
|
const r = { ...n, ...i };
|
|
@@ -6833,13 +6862,13 @@ const Ku = (e) => (t) => _n(t) && e(t, ot(t));
|
|
|
6833
6862
|
function Ze(e, t, n, i) {
|
|
6834
6863
|
return tt(e, t, Ku(n), i);
|
|
6835
6864
|
}
|
|
6836
|
-
const
|
|
6865
|
+
const io = ({ current: e }) => e ? e.ownerDocument.defaultView : null, ai = (e, t) => Math.abs(e - t);
|
|
6837
6866
|
function Gu(e, t) {
|
|
6838
6867
|
const n = ai(e.x, t.x), i = ai(e.y, t.y);
|
|
6839
6868
|
return Math.sqrt(n ** 2 + i ** 2);
|
|
6840
6869
|
}
|
|
6841
6870
|
const li = /* @__PURE__ */ new Set(["auto", "scroll"]);
|
|
6842
|
-
class
|
|
6871
|
+
class ro {
|
|
6843
6872
|
constructor(t, n, { transformPagePoint: i, contextWindow: r = window, dragSnapToOrigin: a = !1, distanceThreshold: o = 3, element: l } = {}) {
|
|
6844
6873
|
if (this.startEvent = null, this.lastMoveEvent = null, this.lastMoveEventInfo = null, this.lastRawMoveEventInfo = null, this.handlers = {}, this.contextWindow = window, this.scrollPositions = /* @__PURE__ */ new Map(), this.removeScrollListeners = null, this.onElementScroll = (m) => {
|
|
6845
6874
|
this.handleScroll(m.target);
|
|
@@ -6857,7 +6886,7 @@ class io {
|
|
|
6857
6886
|
const { onStart: v, onMove: b } = this.handlers;
|
|
6858
6887
|
x || (v && v(this.lastMoveEvent, m), this.startEvent = this.lastMoveEvent), b && b(this.lastMoveEvent, m);
|
|
6859
6888
|
}, this.handlePointerMove = (m, x) => {
|
|
6860
|
-
this.lastMoveEvent = m, this.lastRawMoveEventInfo = x, this.lastMoveEventInfo = ht(x, this.transformPagePoint),
|
|
6889
|
+
this.lastMoveEvent = m, this.lastRawMoveEventInfo = x, this.lastMoveEventInfo = ht(x, this.transformPagePoint), k.update(this.updatePoint, !0);
|
|
6861
6890
|
}, this.handlePointerUp = (m, x) => {
|
|
6862
6891
|
this.end();
|
|
6863
6892
|
const { onEnd: g, onSessionEnd: y, resumeAnimation: w } = this.handlers;
|
|
@@ -6910,7 +6939,7 @@ class io {
|
|
|
6910
6939
|
x: t.scrollLeft,
|
|
6911
6940
|
y: t.scrollTop
|
|
6912
6941
|
}, a = { x: r.x - n.x, y: r.y - n.y };
|
|
6913
|
-
a.x === 0 && a.y === 0 || (i ? this.lastMoveEventInfo && (this.lastMoveEventInfo.point.x += a.x, this.lastMoveEventInfo.point.y += a.y) : this.history.length > 0 && (this.history[0].x -= a.x, this.history[0].y -= a.y), this.scrollPositions.set(t, r),
|
|
6942
|
+
a.x === 0 && a.y === 0 || (i ? this.lastMoveEventInfo && (this.lastMoveEventInfo.point.x += a.x, this.lastMoveEventInfo.point.y += a.y) : this.history.length > 0 && (this.history[0].x -= a.x, this.history[0].y -= a.y), this.scrollPositions.set(t, r), k.update(this.updatePoint, !0));
|
|
6914
6943
|
}
|
|
6915
6944
|
updateHandlers(t) {
|
|
6916
6945
|
this.handlers = t;
|
|
@@ -6928,7 +6957,7 @@ function ci(e, t) {
|
|
|
6928
6957
|
function Gt({ point: e }, t) {
|
|
6929
6958
|
return {
|
|
6930
6959
|
point: e,
|
|
6931
|
-
delta: ci(e,
|
|
6960
|
+
delta: ci(e, oo(t)),
|
|
6932
6961
|
offset: ci(e, Yu(t)),
|
|
6933
6962
|
velocity: Xu(t, 0.1)
|
|
6934
6963
|
};
|
|
@@ -6936,14 +6965,14 @@ function Gt({ point: e }, t) {
|
|
|
6936
6965
|
function Yu(e) {
|
|
6937
6966
|
return e[0];
|
|
6938
6967
|
}
|
|
6939
|
-
function
|
|
6968
|
+
function oo(e) {
|
|
6940
6969
|
return e[e.length - 1];
|
|
6941
6970
|
}
|
|
6942
6971
|
function Xu(e, t) {
|
|
6943
6972
|
if (e.length < 2)
|
|
6944
6973
|
return { x: 0, y: 0 };
|
|
6945
6974
|
let n = e.length - 1, i = null;
|
|
6946
|
-
const r =
|
|
6975
|
+
const r = oo(e);
|
|
6947
6976
|
for (; n >= 0 && (i = e[n], !(r.timestamp - i.timestamp > /* @__PURE__ */ te(t))); )
|
|
6948
6977
|
n--;
|
|
6949
6978
|
if (!i)
|
|
@@ -7033,7 +7062,7 @@ class sh {
|
|
|
7033
7062
|
}
|
|
7034
7063
|
}
|
|
7035
7064
|
this.originPoint[w] = v;
|
|
7036
|
-
}), g &&
|
|
7065
|
+
}), g && k.update(() => g(d, f), !1, !0), dn(this.visualElement, "transform");
|
|
7037
7066
|
const { animationState: y } = this.visualElement;
|
|
7038
7067
|
y && y.setActive("whileDrag", !0);
|
|
7039
7068
|
}, l = (d, f) => {
|
|
@@ -7046,14 +7075,14 @@ class sh {
|
|
|
7046
7075
|
this.currentDirection = rh(w), this.currentDirection !== null && g && g(this.currentDirection);
|
|
7047
7076
|
return;
|
|
7048
7077
|
}
|
|
7049
|
-
this.updateAxis("x", f.point, w), this.updateAxis("y", f.point, w), this.visualElement.render(), y &&
|
|
7078
|
+
this.updateAxis("x", f.point, w), this.updateAxis("y", f.point, w), this.visualElement.render(), y && k.update(() => y(d, f), !1, !0);
|
|
7050
7079
|
}, c = (d, f) => {
|
|
7051
7080
|
this.latestPointerEvent = d, this.latestPanInfo = f, this.stop(d, f), this.latestPointerEvent = null, this.latestPanInfo = null;
|
|
7052
7081
|
}, h = () => {
|
|
7053
7082
|
const { dragSnapToOrigin: d } = this.getProps();
|
|
7054
7083
|
(d || this.constraints) && this.startAnimation({ x: 0, y: 0 });
|
|
7055
7084
|
}, { dragSnapToOrigin: u } = this.getProps();
|
|
7056
|
-
this.panSession = new
|
|
7085
|
+
this.panSession = new ro(t, {
|
|
7057
7086
|
onSessionStart: a,
|
|
7058
7087
|
onStart: o,
|
|
7059
7088
|
onMove: l,
|
|
@@ -7063,7 +7092,7 @@ class sh {
|
|
|
7063
7092
|
transformPagePoint: this.visualElement.getTransformPagePoint(),
|
|
7064
7093
|
dragSnapToOrigin: u,
|
|
7065
7094
|
distanceThreshold: i,
|
|
7066
|
-
contextWindow:
|
|
7095
|
+
contextWindow: io(this.visualElement),
|
|
7067
7096
|
element: this.visualElement.current
|
|
7068
7097
|
});
|
|
7069
7098
|
}
|
|
@@ -7077,7 +7106,7 @@ class sh {
|
|
|
7077
7106
|
const { velocity: o } = r;
|
|
7078
7107
|
this.startAnimation(o);
|
|
7079
7108
|
const { onDragEnd: l } = this.getProps();
|
|
7080
|
-
l &&
|
|
7109
|
+
l && k.postRender(() => l(i, r));
|
|
7081
7110
|
}
|
|
7082
7111
|
/**
|
|
7083
7112
|
* @internal
|
|
@@ -7109,13 +7138,13 @@ class sh {
|
|
|
7109
7138
|
resolveConstraints() {
|
|
7110
7139
|
var a;
|
|
7111
7140
|
const { dragConstraints: t, dragElastic: n } = this.getProps(), i = this.visualElement.projection && !this.visualElement.projection.layout ? this.visualElement.projection.measure(!1) : (a = this.visualElement.projection) == null ? void 0 : a.layout, r = this.constraints;
|
|
7112
|
-
t &&
|
|
7141
|
+
t && De(t) ? this.constraints || (this.constraints = this.resolveRefConstraints()) : t && i ? this.constraints = Zu(i.layoutBox, t) : this.constraints = !1, this.elastic = th(n), r !== this.constraints && !De(t) && i && this.constraints && !this.hasMutatedConstraints && ce((o) => {
|
|
7113
7142
|
this.constraints !== !1 && this.getAxisMotionValue(o) && (this.constraints[o] = eh(i.layoutBox[o], this.constraints[o]));
|
|
7114
7143
|
});
|
|
7115
7144
|
}
|
|
7116
7145
|
resolveRefConstraints() {
|
|
7117
7146
|
const { dragConstraints: t, onMeasureDragConstraints: n } = this.getProps();
|
|
7118
|
-
if (!t || !
|
|
7147
|
+
if (!t || !De(t))
|
|
7119
7148
|
return !1;
|
|
7120
7149
|
const i = t.current;
|
|
7121
7150
|
pe(i !== null, "If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.", "drag-constraints-ref");
|
|
@@ -7126,7 +7155,7 @@ class sh {
|
|
|
7126
7155
|
let o = Ju(r.layout.layoutBox, a);
|
|
7127
7156
|
if (n) {
|
|
7128
7157
|
const l = n(ac(o));
|
|
7129
|
-
this.hasMutatedConstraints = !!l, l && (o =
|
|
7158
|
+
this.hasMutatedConstraints = !!l, l && (o = Pr(l));
|
|
7130
7159
|
}
|
|
7131
7160
|
return o;
|
|
7132
7161
|
}
|
|
@@ -7153,7 +7182,7 @@ class sh {
|
|
|
7153
7182
|
}
|
|
7154
7183
|
startAxisValueAnimation(t, n) {
|
|
7155
7184
|
const i = this.getAxisMotionValue(t);
|
|
7156
|
-
return dn(this.visualElement, t), i.start(
|
|
7185
|
+
return dn(this.visualElement, t), i.start(In(t, i, 0, n, this.visualElement, !1));
|
|
7157
7186
|
}
|
|
7158
7187
|
stopAnimation() {
|
|
7159
7188
|
ce((t) => this.getAxisMotionValue(t).stop());
|
|
@@ -7189,7 +7218,7 @@ class sh {
|
|
|
7189
7218
|
if (!this.visualElement.current)
|
|
7190
7219
|
return;
|
|
7191
7220
|
const { drag: t, dragConstraints: n } = this.getProps(), { projection: i } = this.visualElement;
|
|
7192
|
-
if (!
|
|
7221
|
+
if (!De(n) || !i || !this.constraints)
|
|
7193
7222
|
return;
|
|
7194
7223
|
this.stopAnimation();
|
|
7195
7224
|
const r = { x: 0, y: 0 };
|
|
@@ -7219,9 +7248,9 @@ class sh {
|
|
|
7219
7248
|
let i;
|
|
7220
7249
|
const r = () => {
|
|
7221
7250
|
const { dragConstraints: h } = this.getProps();
|
|
7222
|
-
|
|
7251
|
+
De(h) && h.current && (this.constraints = this.resolveRefConstraints(), i || (i = ih(t, h.current, () => this.scalePositionWithinConstraints())));
|
|
7223
7252
|
}, { projection: a } = this.visualElement, o = a.addEventListener("measure", r);
|
|
7224
|
-
a && !a.layout && (a.root && a.root.updateScroll(), a.updateLayout()),
|
|
7253
|
+
a && !a.layout && (a.root && a.root.updateScroll(), a.updateLayout()), k.read(r);
|
|
7225
7254
|
const l = tt(window, "resize", () => this.scalePositionWithinConstraints()), c = a.addEventListener("didUpdate", ({ delta: h, hasLayoutChanged: u }) => {
|
|
7226
7255
|
this.isDragging && u && (ce((d) => {
|
|
7227
7256
|
const f = this.getAxisMotionValue(d);
|
|
@@ -7285,16 +7314,16 @@ class oh extends be {
|
|
|
7285
7314
|
}
|
|
7286
7315
|
}
|
|
7287
7316
|
const Yt = (e) => (t, n) => {
|
|
7288
|
-
e &&
|
|
7317
|
+
e && k.update(() => e(t, n), !1, !0);
|
|
7289
7318
|
};
|
|
7290
7319
|
class ah extends be {
|
|
7291
7320
|
constructor() {
|
|
7292
7321
|
super(...arguments), this.removePointerDownListener = ie;
|
|
7293
7322
|
}
|
|
7294
7323
|
onPointerDown(t) {
|
|
7295
|
-
this.session = new
|
|
7324
|
+
this.session = new ro(t, this.createPanHandlers(), {
|
|
7296
7325
|
transformPagePoint: this.node.getTransformPagePoint(),
|
|
7297
|
-
contextWindow:
|
|
7326
|
+
contextWindow: io(this.node)
|
|
7298
7327
|
});
|
|
7299
7328
|
}
|
|
7300
7329
|
createPanHandlers() {
|
|
@@ -7304,7 +7333,7 @@ class ah extends be {
|
|
|
7304
7333
|
onStart: Yt(n),
|
|
7305
7334
|
onMove: Yt(i),
|
|
7306
7335
|
onEnd: (a, o) => {
|
|
7307
|
-
delete this.session, r &&
|
|
7336
|
+
delete this.session, r && k.postRender(() => r(a, o));
|
|
7308
7337
|
}
|
|
7309
7338
|
};
|
|
7310
7339
|
}
|
|
@@ -7319,7 +7348,7 @@ class ah extends be {
|
|
|
7319
7348
|
}
|
|
7320
7349
|
}
|
|
7321
7350
|
let Xt = !1;
|
|
7322
|
-
class lh extends
|
|
7351
|
+
class lh extends po {
|
|
7323
7352
|
/**
|
|
7324
7353
|
* This only mounts projection nodes for components that
|
|
7325
7354
|
* need measuring, we might want to do it for all components
|
|
@@ -7340,7 +7369,7 @@ class lh extends fo {
|
|
|
7340
7369
|
return o && (o.isPresent = a, t.layoutDependency !== n && o.setOptions({
|
|
7341
7370
|
...o.options,
|
|
7342
7371
|
layoutDependency: n
|
|
7343
|
-
}), Xt = !0, r || t.layoutDependency !== n || n === void 0 || t.isPresent !== a ? o.willUpdate() : this.safeToRemove(), t.isPresent !== a && (a ? o.promote() : o.relegate() ||
|
|
7372
|
+
}), Xt = !0, r || t.layoutDependency !== n || n === void 0 || t.isPresent !== a ? o.willUpdate() : this.safeToRemove(), t.isPresent !== a && (a ? o.promote() : o.relegate() || k.postRender(() => {
|
|
7344
7373
|
const l = o.getStack();
|
|
7345
7374
|
(!l || !l.members.length) && this.safeToRemove();
|
|
7346
7375
|
}))), null;
|
|
@@ -7363,9 +7392,9 @@ class lh extends fo {
|
|
|
7363
7392
|
return null;
|
|
7364
7393
|
}
|
|
7365
7394
|
}
|
|
7366
|
-
function
|
|
7367
|
-
const [t, n] = mu(), i = ee(
|
|
7368
|
-
return s.jsx(lh, { ...e, layoutGroup: i, switchLayoutGroup: ee(
|
|
7395
|
+
function ao(e) {
|
|
7396
|
+
const [t, n] = mu(), i = ee(bi);
|
|
7397
|
+
return s.jsx(lh, { ...e, layoutGroup: i, switchLayoutGroup: ee(no), isPresent: t, safeToRemove: n });
|
|
7369
7398
|
}
|
|
7370
7399
|
const ch = {
|
|
7371
7400
|
pan: {
|
|
@@ -7373,20 +7402,20 @@ const ch = {
|
|
|
7373
7402
|
},
|
|
7374
7403
|
drag: {
|
|
7375
7404
|
Feature: oh,
|
|
7376
|
-
ProjectionNode:
|
|
7377
|
-
MeasureLayout:
|
|
7405
|
+
ProjectionNode: Yr,
|
|
7406
|
+
MeasureLayout: ao
|
|
7378
7407
|
}
|
|
7379
7408
|
};
|
|
7380
7409
|
function mi(e, t, n) {
|
|
7381
7410
|
const { props: i } = e;
|
|
7382
7411
|
e.animationState && i.whileHover && e.animationState.setActive("whileHover", n === "Start");
|
|
7383
7412
|
const r = "onHover" + n, a = i[r];
|
|
7384
|
-
a &&
|
|
7413
|
+
a && k.postRender(() => a(t, ot(t)));
|
|
7385
7414
|
}
|
|
7386
7415
|
class uh extends be {
|
|
7387
7416
|
mount() {
|
|
7388
7417
|
const { current: t } = this.node;
|
|
7389
|
-
t && (this.unmount =
|
|
7418
|
+
t && (this.unmount = Il(t, (n, i) => (mi(this.node, i, "Start"), (r) => mi(this.node, r, "End"))));
|
|
7390
7419
|
}
|
|
7391
7420
|
unmount() {
|
|
7392
7421
|
}
|
|
@@ -7419,7 +7448,7 @@ function xi(e, t, n) {
|
|
|
7419
7448
|
return;
|
|
7420
7449
|
e.animationState && i.whileTap && e.animationState.setActive("whileTap", n === "Start");
|
|
7421
7450
|
const r = "onTap" + (n === "End" ? "" : n), a = i[r];
|
|
7422
|
-
a &&
|
|
7451
|
+
a && k.postRender(() => a(t, ot(t)));
|
|
7423
7452
|
}
|
|
7424
7453
|
class dh extends be {
|
|
7425
7454
|
mount() {
|
|
@@ -7510,15 +7539,15 @@ const vh = {
|
|
|
7510
7539
|
}
|
|
7511
7540
|
}, wh = {
|
|
7512
7541
|
layout: {
|
|
7513
|
-
ProjectionNode:
|
|
7514
|
-
MeasureLayout:
|
|
7542
|
+
ProjectionNode: Yr,
|
|
7543
|
+
MeasureLayout: ao
|
|
7515
7544
|
}
|
|
7516
7545
|
}, bh = {
|
|
7517
7546
|
...$u,
|
|
7518
7547
|
...vh,
|
|
7519
7548
|
...ch,
|
|
7520
7549
|
...wh
|
|
7521
|
-
}, Th = /* @__PURE__ */ zu(bh, Hu),
|
|
7550
|
+
}, Th = /* @__PURE__ */ zu(bh, Hu), Jh = ({ flipped: e, setFlipped: t, front: n, back: i }) => /* @__PURE__ */ s.jsxs(
|
|
7522
7551
|
Th.div,
|
|
7523
7552
|
{
|
|
7524
7553
|
className: `muncher-flippable-card ${e ? "flipped" : ""}`,
|
|
@@ -7530,7 +7559,7 @@ const vh = {
|
|
|
7530
7559
|
]
|
|
7531
7560
|
}
|
|
7532
7561
|
), Mh = () => {
|
|
7533
|
-
const [e, t] =
|
|
7562
|
+
const [e, t] = $({
|
|
7534
7563
|
isTop: !0,
|
|
7535
7564
|
isBottom: !1
|
|
7536
7565
|
});
|
|
@@ -7541,7 +7570,7 @@ const vh = {
|
|
|
7541
7570
|
};
|
|
7542
7571
|
return window.addEventListener("scroll", n), n(), () => window.removeEventListener("scroll", n);
|
|
7543
7572
|
}, []), e;
|
|
7544
|
-
},
|
|
7573
|
+
}, Qh = ({ variant: e = "tertiary" }) => {
|
|
7545
7574
|
const { isBottom: t } = Mh(), n = () => window.scrollTo({ top: 0, behavior: "smooth" }), i = () => window.scrollTo({
|
|
7546
7575
|
top: document.documentElement.scrollHeight,
|
|
7547
7576
|
behavior: "smooth"
|
|
@@ -7550,45 +7579,46 @@ const vh = {
|
|
|
7550
7579
|
};
|
|
7551
7580
|
export {
|
|
7552
7581
|
Ah as Accordion,
|
|
7553
|
-
|
|
7554
|
-
|
|
7582
|
+
go as Backdrop,
|
|
7583
|
+
jo as Badge,
|
|
7555
7584
|
ne as Button,
|
|
7556
|
-
|
|
7585
|
+
qh as Card,
|
|
7557
7586
|
Eh as Checkbox,
|
|
7558
|
-
|
|
7559
|
-
|
|
7560
|
-
|
|
7561
|
-
|
|
7587
|
+
bo as CopyButton,
|
|
7588
|
+
To as CsvButton,
|
|
7589
|
+
So as CsvInput,
|
|
7590
|
+
vo as DropdownButton,
|
|
7562
7591
|
Vh as DropdownNavButton,
|
|
7563
|
-
|
|
7564
|
-
|
|
7565
|
-
|
|
7592
|
+
Kh as Featured,
|
|
7593
|
+
Jh as FlippableCard,
|
|
7594
|
+
_h as Hr,
|
|
7566
7595
|
N as Icon,
|
|
7567
7596
|
Ph as IconBadge,
|
|
7568
|
-
|
|
7569
|
-
|
|
7570
|
-
|
|
7597
|
+
kh as ImageInput,
|
|
7598
|
+
wi as Input,
|
|
7599
|
+
Uh as ItemSlider,
|
|
7571
7600
|
nt as Label,
|
|
7572
|
-
|
|
7601
|
+
Ih as Li,
|
|
7573
7602
|
Oh as Modal,
|
|
7574
7603
|
Qn as NavigateButton,
|
|
7575
|
-
|
|
7576
|
-
|
|
7577
|
-
zh as
|
|
7578
|
-
|
|
7579
|
-
|
|
7580
|
-
|
|
7604
|
+
Bh as Paper,
|
|
7605
|
+
Dh as PasswordInput,
|
|
7606
|
+
zh as Pill,
|
|
7607
|
+
Hh as Progress,
|
|
7608
|
+
Rh as Radio,
|
|
7609
|
+
Wh as RangeSlider,
|
|
7610
|
+
Qh as ScrollFab,
|
|
7581
7611
|
Ao as Select,
|
|
7582
7612
|
Ch as ShareButton,
|
|
7583
|
-
|
|
7584
|
-
|
|
7613
|
+
$h as Slider,
|
|
7614
|
+
Mo as SortButton,
|
|
7585
7615
|
vi as Spinner,
|
|
7586
|
-
|
|
7587
|
-
|
|
7588
|
-
|
|
7589
|
-
|
|
7590
|
-
|
|
7591
|
-
|
|
7592
|
-
|
|
7616
|
+
Gh as Star,
|
|
7617
|
+
Xh as Table,
|
|
7618
|
+
Yh as Tabs,
|
|
7619
|
+
Nh as TextInputDropdown,
|
|
7620
|
+
Lh as Textarea,
|
|
7621
|
+
Fh as Ul,
|
|
7622
|
+
wo as copyToClipboard,
|
|
7593
7623
|
Mh as useScrollPosition
|
|
7594
7624
|
};
|