@acrool/react-picker 0.1.0-alpha.0 → 0.1.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/acrool-react-picker.es.js +297 -298
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as Fn from "react";
|
|
2
|
-
import On, { createContext as kt, useContext as $, useCallback as rt, useEffect as
|
|
2
|
+
import On, { createContext as kt, useContext as $, useCallback as rt, useEffect as ot, useLayoutEffect as oa, useRef as it, useInsertionEffect as er, useMemo as Mt, forwardRef as ke, Fragment as nr, createElement as aa, useId as jn, Component as la, Children as ca, isValidElement as ua, useState as _t } from "react";
|
|
3
3
|
import fa from "react-dom";
|
|
4
|
-
var
|
|
4
|
+
var lt = /* @__PURE__ */ ((t) => (t.bottom = "bottom", t.top = "top", t))(lt || {}), Jt = /* @__PURE__ */ ((t) => (t.left = "left", t.right = "right", t))(Jt || {});
|
|
5
5
|
const fe = [
|
|
6
6
|
"color: #fff",
|
|
7
7
|
"display: inline-block",
|
|
@@ -64,7 +64,7 @@ const yt = {
|
|
|
64
64
|
inputBlur: () => yt.warning("No blur method detected, did you embed your app with Acrool/PickerPortal?"),
|
|
65
65
|
isInputFocus: !1,
|
|
66
66
|
onChange: () => yt.warning("No onChange method detected, did you embed your app with Acrool/PickerPortal?"),
|
|
67
|
-
vertical:
|
|
67
|
+
vertical: lt.bottom,
|
|
68
68
|
setVertical: () => yt.warning("No onChange method detected, did you embed your app with Acrool/PickerPortal?")
|
|
69
69
|
}), vh = _n.Consumer, ya = () => $(_n);
|
|
70
70
|
var vn = { exports: {} }, Xt = {};
|
|
@@ -201,7 +201,7 @@ function Pa() {
|
|
|
201
201
|
function vi() {
|
|
202
202
|
}
|
|
203
203
|
vi.__reactDisabledLog = !0;
|
|
204
|
-
function
|
|
204
|
+
function Lo() {
|
|
205
205
|
{
|
|
206
206
|
if (_ === 0) {
|
|
207
207
|
Q = console.log, Lt = console.info, Ft = console.warn, pi = console.error, mi = console.group, gi = console.groupCollapsed, yi = console.groupEnd;
|
|
@@ -224,7 +224,7 @@ function Pa() {
|
|
|
224
224
|
_++;
|
|
225
225
|
}
|
|
226
226
|
}
|
|
227
|
-
function
|
|
227
|
+
function Fo() {
|
|
228
228
|
{
|
|
229
229
|
if (_--, _ === 0) {
|
|
230
230
|
var h = {
|
|
@@ -275,8 +275,8 @@ function Pa() {
|
|
|
275
275
|
}
|
|
276
276
|
var qe = !1, Pe;
|
|
277
277
|
{
|
|
278
|
-
var
|
|
279
|
-
Pe = new
|
|
278
|
+
var Oo = typeof WeakMap == "function" ? WeakMap : Map;
|
|
279
|
+
Pe = new Oo();
|
|
280
280
|
}
|
|
281
281
|
function Pi(h, g) {
|
|
282
282
|
if (!h || qe)
|
|
@@ -291,7 +291,7 @@ function Pa() {
|
|
|
291
291
|
var D = Error.prepareStackTrace;
|
|
292
292
|
Error.prepareStackTrace = void 0;
|
|
293
293
|
var k;
|
|
294
|
-
k = Ye.current, Ye.current = null,
|
|
294
|
+
k = Ye.current, Ye.current = null, Lo();
|
|
295
295
|
try {
|
|
296
296
|
if (g) {
|
|
297
297
|
var V = function() {
|
|
@@ -344,15 +344,15 @@ function Pa() {
|
|
|
344
344
|
}
|
|
345
345
|
}
|
|
346
346
|
} finally {
|
|
347
|
-
qe = !1, Ye.current = k,
|
|
347
|
+
qe = !1, Ye.current = k, Fo(), Error.prepareStackTrace = D;
|
|
348
348
|
}
|
|
349
349
|
var jt = h ? h.displayName || h.name : "", St = jt ? ve(jt) : "";
|
|
350
350
|
return typeof h == "function" && Pe.set(h, St), St;
|
|
351
351
|
}
|
|
352
|
-
function
|
|
352
|
+
function jo(h, g, T) {
|
|
353
353
|
return Pi(h, !1);
|
|
354
354
|
}
|
|
355
|
-
function
|
|
355
|
+
function _o(h) {
|
|
356
356
|
var g = h.prototype;
|
|
357
357
|
return !!(g && g.isReactComponent);
|
|
358
358
|
}
|
|
@@ -360,7 +360,7 @@ function Pa() {
|
|
|
360
360
|
if (h == null)
|
|
361
361
|
return "";
|
|
362
362
|
if (typeof h == "function")
|
|
363
|
-
return Pi(h,
|
|
363
|
+
return Pi(h, _o(h));
|
|
364
364
|
if (typeof h == "string")
|
|
365
365
|
return ve(h);
|
|
366
366
|
switch (h) {
|
|
@@ -372,7 +372,7 @@ function Pa() {
|
|
|
372
372
|
if (typeof h == "object")
|
|
373
373
|
switch (h.$$typeof) {
|
|
374
374
|
case l:
|
|
375
|
-
return
|
|
375
|
+
return jo(h.render);
|
|
376
376
|
case f:
|
|
377
377
|
return xe(h.type, g, T);
|
|
378
378
|
case d: {
|
|
@@ -393,7 +393,7 @@ function Pa() {
|
|
|
393
393
|
} else
|
|
394
394
|
Ti.setExtraStackFrame(null);
|
|
395
395
|
}
|
|
396
|
-
function
|
|
396
|
+
function Bo(h, g, T, C, D) {
|
|
397
397
|
{
|
|
398
398
|
var k = Function.call.bind(zt);
|
|
399
399
|
for (var V in h)
|
|
@@ -412,17 +412,17 @@ function Pa() {
|
|
|
412
412
|
}
|
|
413
413
|
}
|
|
414
414
|
}
|
|
415
|
-
var
|
|
415
|
+
var Io = Array.isArray;
|
|
416
416
|
function Ze(h) {
|
|
417
|
-
return
|
|
417
|
+
return Io(h);
|
|
418
418
|
}
|
|
419
|
-
function
|
|
419
|
+
function No(h) {
|
|
420
420
|
{
|
|
421
421
|
var g = typeof Symbol == "function" && Symbol.toStringTag, T = g && h[Symbol.toStringTag] || h.constructor.name || "Object";
|
|
422
422
|
return T;
|
|
423
423
|
}
|
|
424
424
|
}
|
|
425
|
-
function
|
|
425
|
+
function Uo(h) {
|
|
426
426
|
try {
|
|
427
427
|
return bi(h), !1;
|
|
428
428
|
} catch {
|
|
@@ -433,17 +433,17 @@ function Pa() {
|
|
|
433
433
|
return "" + h;
|
|
434
434
|
}
|
|
435
435
|
function wi(h) {
|
|
436
|
-
if (
|
|
437
|
-
return y("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",
|
|
436
|
+
if (Uo(h))
|
|
437
|
+
return y("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", No(h)), bi(h);
|
|
438
438
|
}
|
|
439
|
-
var Yt = x.ReactCurrentOwner,
|
|
439
|
+
var Yt = x.ReactCurrentOwner, Wo = {
|
|
440
440
|
key: !0,
|
|
441
441
|
ref: !0,
|
|
442
442
|
__self: !0,
|
|
443
443
|
__source: !0
|
|
444
444
|
}, Si, Ci, Je;
|
|
445
445
|
Je = {};
|
|
446
|
-
function
|
|
446
|
+
function $o(h) {
|
|
447
447
|
if (zt.call(h, "ref")) {
|
|
448
448
|
var g = Object.getOwnPropertyDescriptor(h, "ref").get;
|
|
449
449
|
if (g && g.isReactWarning)
|
|
@@ -451,7 +451,7 @@ function Pa() {
|
|
|
451
451
|
}
|
|
452
452
|
return h.ref !== void 0;
|
|
453
453
|
}
|
|
454
|
-
function
|
|
454
|
+
function Ko(h) {
|
|
455
455
|
if (zt.call(h, "key")) {
|
|
456
456
|
var g = Object.getOwnPropertyDescriptor(h, "key").get;
|
|
457
457
|
if (g && g.isReactWarning)
|
|
@@ -459,13 +459,13 @@ function Pa() {
|
|
|
459
459
|
}
|
|
460
460
|
return h.key !== void 0;
|
|
461
461
|
}
|
|
462
|
-
function
|
|
462
|
+
function Go(h, g) {
|
|
463
463
|
if (typeof h.ref == "string" && Yt.current && g && Yt.current.stateNode !== g) {
|
|
464
464
|
var T = Y(Yt.current.type);
|
|
465
465
|
Je[T] || (y('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', Y(Yt.current.type), h.ref), Je[T] = !0);
|
|
466
466
|
}
|
|
467
467
|
}
|
|
468
|
-
function
|
|
468
|
+
function Ho(h, g) {
|
|
469
469
|
{
|
|
470
470
|
var T = function() {
|
|
471
471
|
Si || (Si = !0, y("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", g));
|
|
@@ -476,7 +476,7 @@ function Pa() {
|
|
|
476
476
|
});
|
|
477
477
|
}
|
|
478
478
|
}
|
|
479
|
-
function
|
|
479
|
+
function zo(h, g) {
|
|
480
480
|
{
|
|
481
481
|
var T = function() {
|
|
482
482
|
Ci || (Ci = !0, y("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", g));
|
|
@@ -487,7 +487,7 @@ function Pa() {
|
|
|
487
487
|
});
|
|
488
488
|
}
|
|
489
489
|
}
|
|
490
|
-
var
|
|
490
|
+
var Yo = function(h, g, T, C, D, k, V) {
|
|
491
491
|
var R = {
|
|
492
492
|
// This tag allows us to uniquely identify this as a React Element
|
|
493
493
|
$$typeof: e,
|
|
@@ -516,12 +516,12 @@ function Pa() {
|
|
|
516
516
|
value: D
|
|
517
517
|
}), Object.freeze && (Object.freeze(R.props), Object.freeze(R)), R;
|
|
518
518
|
};
|
|
519
|
-
function
|
|
519
|
+
function Xo(h, g, T, C, D) {
|
|
520
520
|
{
|
|
521
521
|
var k, V = {}, R = null, X = null;
|
|
522
|
-
T !== void 0 && (wi(T), R = "" + T),
|
|
522
|
+
T !== void 0 && (wi(T), R = "" + T), Ko(g) && (wi(g.key), R = "" + g.key), $o(g) && (X = g.ref, Go(g, D));
|
|
523
523
|
for (k in g)
|
|
524
|
-
zt.call(g, k) &&
|
|
524
|
+
zt.call(g, k) && !Wo.hasOwnProperty(k) && (V[k] = g[k]);
|
|
525
525
|
if (h && h.defaultProps) {
|
|
526
526
|
var B = h.defaultProps;
|
|
527
527
|
for (k in B)
|
|
@@ -529,9 +529,9 @@ function Pa() {
|
|
|
529
529
|
}
|
|
530
530
|
if (R || X) {
|
|
531
531
|
var N = typeof h == "function" ? h.displayName || h.name || "Unknown" : h;
|
|
532
|
-
R &&
|
|
532
|
+
R && Ho(V, N), X && zo(V, N);
|
|
533
533
|
}
|
|
534
|
-
return
|
|
534
|
+
return Yo(h, R, X, D, C, Yt.current, V);
|
|
535
535
|
}
|
|
536
536
|
}
|
|
537
537
|
var Qe = x.ReactCurrentOwner, Ai = x.ReactDebugCurrentFrame;
|
|
@@ -559,7 +559,7 @@ Check the render method of \`` + h + "`.";
|
|
|
559
559
|
return "";
|
|
560
560
|
}
|
|
561
561
|
}
|
|
562
|
-
function
|
|
562
|
+
function qo(h) {
|
|
563
563
|
{
|
|
564
564
|
if (h !== void 0) {
|
|
565
565
|
var g = h.fileName.replace(/^.*[\\\/]/, ""), T = h.lineNumber;
|
|
@@ -571,7 +571,7 @@ Check your code at ` + g + ":" + T + ".";
|
|
|
571
571
|
}
|
|
572
572
|
}
|
|
573
573
|
var Ri = {};
|
|
574
|
-
function
|
|
574
|
+
function Zo(h) {
|
|
575
575
|
{
|
|
576
576
|
var g = Ei();
|
|
577
577
|
if (!g) {
|
|
@@ -588,7 +588,7 @@ Check the top-level render call using <` + T + ">.");
|
|
|
588
588
|
if (!h._store || h._store.validated || h.key != null)
|
|
589
589
|
return;
|
|
590
590
|
h._store.validated = !0;
|
|
591
|
-
var T =
|
|
591
|
+
var T = Zo(g);
|
|
592
592
|
if (Ri[T])
|
|
593
593
|
return;
|
|
594
594
|
Ri[T] = !0;
|
|
@@ -615,7 +615,7 @@ Check the top-level render call using <` + T + ">.");
|
|
|
615
615
|
}
|
|
616
616
|
}
|
|
617
617
|
}
|
|
618
|
-
function
|
|
618
|
+
function Jo(h) {
|
|
619
619
|
{
|
|
620
620
|
var g = h.type;
|
|
621
621
|
if (g == null || typeof g == "string")
|
|
@@ -631,7 +631,7 @@ Check the top-level render call using <` + T + ">.");
|
|
|
631
631
|
return;
|
|
632
632
|
if (T) {
|
|
633
633
|
var C = Y(g);
|
|
634
|
-
|
|
634
|
+
Bo(T, h.props, "prop", C, h);
|
|
635
635
|
} else if (g.PropTypes !== void 0 && !tn) {
|
|
636
636
|
tn = !0;
|
|
637
637
|
var D = Y(g);
|
|
@@ -640,7 +640,7 @@ Check the top-level render call using <` + T + ">.");
|
|
|
640
640
|
typeof g.getDefaultProps == "function" && !g.getDefaultProps.isReactClassApproved && y("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
641
641
|
}
|
|
642
642
|
}
|
|
643
|
-
function
|
|
643
|
+
function Qo(h) {
|
|
644
644
|
{
|
|
645
645
|
for (var g = Object.keys(h.props), T = 0; T < g.length; T++) {
|
|
646
646
|
var C = g[T];
|
|
@@ -659,12 +659,12 @@ Check the top-level render call using <` + T + ">.");
|
|
|
659
659
|
if (!V) {
|
|
660
660
|
var R = "";
|
|
661
661
|
(h === void 0 || typeof h == "object" && h !== null && Object.keys(h).length === 0) && (R += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
662
|
-
var X =
|
|
662
|
+
var X = qo(D);
|
|
663
663
|
X ? R += X : R += Ei();
|
|
664
664
|
var B;
|
|
665
665
|
h === null ? B = "null" : Ze(h) ? B = "array" : h !== void 0 && h.$$typeof === e ? (B = "<" + (Y(h.type) || "Unknown") + " />", R = " Did you accidentally export a JSX literal instead of a component?") : B = typeof h, y("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", B, R);
|
|
666
666
|
}
|
|
667
|
-
var N =
|
|
667
|
+
var N = Xo(h, g, T, D, k);
|
|
668
668
|
if (N == null)
|
|
669
669
|
return N;
|
|
670
670
|
if (V) {
|
|
@@ -681,40 +681,40 @@ Check the top-level render call using <` + T + ">.");
|
|
|
681
681
|
Di(tt, h);
|
|
682
682
|
}
|
|
683
683
|
if (zt.call(g, "key")) {
|
|
684
|
-
var St = Y(h), Z = Object.keys(g).filter(function(
|
|
685
|
-
return
|
|
684
|
+
var St = Y(h), Z = Object.keys(g).filter(function(ra) {
|
|
685
|
+
return ra !== "key";
|
|
686
686
|
}), nn = Z.length > 0 ? "{key: someKey, " + Z.join(": ..., ") + ": ...}" : "{key: someKey}";
|
|
687
687
|
if (!Mi[St + nn]) {
|
|
688
|
-
var
|
|
688
|
+
var sa = Z.length > 0 ? "{" + Z.join(": ..., ") + ": ...}" : "{}";
|
|
689
689
|
y(`A props object containing a "key" prop is being spread into JSX:
|
|
690
690
|
let props = %s;
|
|
691
691
|
<%s {...props} />
|
|
692
692
|
React keys must be passed directly to JSX without using spread:
|
|
693
693
|
let props = %s;
|
|
694
|
-
<%s key={someKey} {...props} />`, nn, St,
|
|
694
|
+
<%s key={someKey} {...props} />`, nn, St, sa, St), Mi[St + nn] = !0;
|
|
695
695
|
}
|
|
696
696
|
}
|
|
697
|
-
return h === i ?
|
|
697
|
+
return h === i ? Qo(N) : Jo(N), N;
|
|
698
698
|
}
|
|
699
699
|
}
|
|
700
|
-
function
|
|
700
|
+
function ta(h, g, T) {
|
|
701
701
|
return ki(h, g, T, !0);
|
|
702
702
|
}
|
|
703
|
-
function
|
|
703
|
+
function ea(h, g, T) {
|
|
704
704
|
return ki(h, g, T, !1);
|
|
705
705
|
}
|
|
706
|
-
var
|
|
707
|
-
qt.Fragment = i, qt.jsx =
|
|
706
|
+
var na = ea, ia = ta;
|
|
707
|
+
qt.Fragment = i, qt.jsx = na, qt.jsxs = ia;
|
|
708
708
|
}()), qt;
|
|
709
709
|
}
|
|
710
710
|
process.env.NODE_ENV === "production" ? vn.exports = va() : vn.exports = Pa();
|
|
711
711
|
var F = vn.exports, At = /* @__PURE__ */ ((t) => (t.Escape = "Escape", t.Enter = "Enter", t.Space = "Space", t.Tab = "Tab", t.ShiftAndTab = "Shift+Tab", t.ArrowUp = "ArrowUp", t.ArrowDown = "ArrowDown", t.ArrowLeft = "ArrowLeft", t.ArrowRight = "ArrowRight", t))(At || {}), Ee = /* @__PURE__ */ ((t) => (t.Input = "INPUT", t.Textarea = "TEXTAREA", t.Select = "SELECT", t.Button = "BUTTON", t))(Ee || {});
|
|
712
|
-
const
|
|
712
|
+
const ir = [
|
|
713
713
|
Ee.Input,
|
|
714
714
|
Ee.Textarea,
|
|
715
715
|
Ee.Select
|
|
716
716
|
], xa = (t) => (t == null ? void 0 : t.split("+").map((e) => e.trim().toLowerCase())) ?? [], Ta = (t) => ({
|
|
717
|
-
formFieldTags: (t == null ? void 0 : t.formFieldTags) ??
|
|
717
|
+
formFieldTags: (t == null ? void 0 : t.formFieldTags) ?? ir,
|
|
718
718
|
ignoreFormField: (t == null ? void 0 : t.ignoreFormField) ?? !0,
|
|
719
719
|
preventDefault: (t == null ? void 0 : t.preventDefault) ?? !0,
|
|
720
720
|
stopPropagation: (t == null ? void 0 : t.stopPropagation) ?? !0
|
|
@@ -725,7 +725,7 @@ const sr = [
|
|
|
725
725
|
if (i.repeat)
|
|
726
726
|
continue;
|
|
727
727
|
const f = a.includes("ctrl"), d = a.includes("cmd"), p = a.includes("shift"), m = f === i.ctrlKey, P = d === i.metaKey, b = p === i.shiftKey;
|
|
728
|
-
if (!(!(a.includes(l) || a.includes(c)) || !m || !P || !b) && !(!r.ignoreFormField && u &&
|
|
728
|
+
if (!(!(a.includes(l) || a.includes(c)) || !m || !P || !b) && !(!r.ignoreFormField && u && ir.includes(u.tagName)) && (r.preventDefault && i.preventDefault(), r.stopPropagation && i.stopPropagation(), !!e)) {
|
|
729
729
|
e(i);
|
|
730
730
|
break;
|
|
731
731
|
}
|
|
@@ -741,12 +741,12 @@ const sr = [
|
|
|
741
741
|
const r = rt((a) => {
|
|
742
742
|
t && ba(e, t, { stopPropagation: n, preventDefault: i, ignoreFormField: s, formFieldTags: o })(a);
|
|
743
743
|
}, [e, t]);
|
|
744
|
-
return
|
|
744
|
+
return ot(() => (document.addEventListener("keydown", r), () => {
|
|
745
745
|
document.removeEventListener("keydown", r);
|
|
746
746
|
}), [r]), null;
|
|
747
747
|
};
|
|
748
748
|
var wa = Object.defineProperty, Sa = (t, e, n) => e in t ? wa(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n, Pn = (t, e, n) => (Sa(t, typeof e != "symbol" ? e + "" : e, n), n);
|
|
749
|
-
class
|
|
749
|
+
class sr extends On.Component {
|
|
750
750
|
constructor(e) {
|
|
751
751
|
super(e), Pn(this, "_el"), Pn(this, "renderPortal", () => fa.createPortal(
|
|
752
752
|
this.props.children,
|
|
@@ -770,14 +770,14 @@ class rr extends On.Component {
|
|
|
770
770
|
return this.renderPortal();
|
|
771
771
|
}
|
|
772
772
|
}
|
|
773
|
-
Pn(
|
|
773
|
+
Pn(sr, "defaultProps", {
|
|
774
774
|
containerSelector: () => document.body
|
|
775
775
|
});
|
|
776
776
|
const Bn = kt({
|
|
777
777
|
transformPagePoint: (t) => t,
|
|
778
778
|
isStatic: !1,
|
|
779
779
|
reducedMotion: "never"
|
|
780
|
-
}), Ie = kt({}), Ne = kt(null), In = typeof window < "u",
|
|
780
|
+
}), Ie = kt({}), Ne = kt(null), In = typeof window < "u", rr = In ? oa : ot, or = kt({ strict: !1 }), Ue = (t) => t.replace(/([a-z])([A-Z])/gu, "$1-$2").toLowerCase(), Ca = "framerAppearId", ar = "data-" + Ue(Ca), Aa = {
|
|
781
781
|
skipAnimations: !1,
|
|
782
782
|
useManualTiming: !1
|
|
783
783
|
};
|
|
@@ -833,7 +833,7 @@ const be = [
|
|
|
833
833
|
"postRender"
|
|
834
834
|
// Compute
|
|
835
835
|
], Ra = 40;
|
|
836
|
-
function
|
|
836
|
+
function lr(t, e) {
|
|
837
837
|
let n = !1, i = !0;
|
|
838
838
|
const s = {
|
|
839
839
|
delta: 0,
|
|
@@ -853,14 +853,14 @@ function cr(t, e) {
|
|
|
853
853
|
r[be[y]].cancel(x);
|
|
854
854
|
}, state: s, steps: r };
|
|
855
855
|
}
|
|
856
|
-
const { schedule: Nn, cancel: Ph } =
|
|
856
|
+
const { schedule: Nn, cancel: Ph } = lr(queueMicrotask, !1);
|
|
857
857
|
function Bt(t) {
|
|
858
858
|
return t && typeof t == "object" && Object.prototype.hasOwnProperty.call(t, "current");
|
|
859
859
|
}
|
|
860
|
-
const
|
|
860
|
+
const cr = kt({});
|
|
861
861
|
let ji = !1;
|
|
862
862
|
function Va(t, e, n, i, s) {
|
|
863
|
-
const { visualElement: o } = $(Ie), r = $(
|
|
863
|
+
const { visualElement: o } = $(Ie), r = $(or), a = $(Ne), l = $(Bn).reducedMotion, c = it();
|
|
864
864
|
i = i || r.renderer, !c.current && i && (c.current = i(t, {
|
|
865
865
|
visualState: e,
|
|
866
866
|
parent: o,
|
|
@@ -869,14 +869,14 @@ function Va(t, e, n, i, s) {
|
|
|
869
869
|
blockInitialAnimation: a ? a.initial === !1 : !1,
|
|
870
870
|
reducedMotionConfig: l
|
|
871
871
|
}));
|
|
872
|
-
const u = c.current, f = $(
|
|
873
|
-
u && !u.projection && s && (u.type === "html" || u.type === "svg") && Ma(c.current, n, s, f),
|
|
872
|
+
const u = c.current, f = $(cr);
|
|
873
|
+
u && !u.projection && s && (u.type === "html" || u.type === "svg") && Ma(c.current, n, s, f), er(() => {
|
|
874
874
|
u && u.update(n, a);
|
|
875
875
|
});
|
|
876
|
-
const d = it(!!(n[
|
|
877
|
-
return
|
|
876
|
+
const d = it(!!(n[ar] && !window.HandoffComplete));
|
|
877
|
+
return rr(() => {
|
|
878
878
|
u && (u.updateFeatures(), Nn.render(u.render), d.current && u.animationState && u.animationState.animateChanges());
|
|
879
|
-
}),
|
|
879
|
+
}), ot(() => {
|
|
880
880
|
u && (!d.current && u.animationState && u.animationState.animateChanges(), d.current && (d.current = !1, ji || (ji = !0, queueMicrotask(Da))));
|
|
881
881
|
}), u;
|
|
882
882
|
}
|
|
@@ -885,7 +885,7 @@ function Da() {
|
|
|
885
885
|
}
|
|
886
886
|
function Ma(t, e, n, i) {
|
|
887
887
|
const { layoutId: s, layout: o, drag: r, dragConstraints: a, layoutScroll: l, layoutRoot: c } = e;
|
|
888
|
-
t.projection = new n(t.latestValues, e["data-framer-portal-id"] ? void 0 :
|
|
888
|
+
t.projection = new n(t.latestValues, e["data-framer-portal-id"] ? void 0 : ur(t.parent)), t.projection.setOptions({
|
|
889
889
|
layoutId: s,
|
|
890
890
|
layout: o,
|
|
891
891
|
alwaysMeasureLayout: !!r || a && Bt(a),
|
|
@@ -903,9 +903,9 @@ function Ma(t, e, n, i) {
|
|
|
903
903
|
layoutRoot: c
|
|
904
904
|
});
|
|
905
905
|
}
|
|
906
|
-
function
|
|
906
|
+
function ur(t) {
|
|
907
907
|
if (t)
|
|
908
|
-
return t.options.allowProjection !== !1 ? t.projection :
|
|
908
|
+
return t.options.allowProjection !== !1 ? t.projection : ur(t.parent);
|
|
909
909
|
}
|
|
910
910
|
function ka(t, e, n) {
|
|
911
911
|
return rt(
|
|
@@ -938,7 +938,7 @@ const Un = [
|
|
|
938
938
|
function We(t) {
|
|
939
939
|
return ae(t.animate) || Wn.some((e) => oe(t[e]));
|
|
940
940
|
}
|
|
941
|
-
function
|
|
941
|
+
function fr(t) {
|
|
942
942
|
return !!(We(t) || t.variants);
|
|
943
943
|
}
|
|
944
944
|
function La(t, e) {
|
|
@@ -1021,7 +1021,7 @@ function Ba({ layoutId: t }) {
|
|
|
1021
1021
|
return e && t !== void 0 ? e + "-" + t : t;
|
|
1022
1022
|
}
|
|
1023
1023
|
function Ia(t, e) {
|
|
1024
|
-
const n = $(
|
|
1024
|
+
const n = $(or).strict;
|
|
1025
1025
|
if (process.env.NODE_ENV !== "production" && e && n) {
|
|
1026
1026
|
const i = "You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";
|
|
1027
1027
|
t.ignoreStrict ? Gt(!1, i) : pt(!1, i);
|
|
@@ -1123,10 +1123,10 @@ const pe = [
|
|
|
1123
1123
|
"skewX",
|
|
1124
1124
|
"skewY"
|
|
1125
1125
|
], bt = new Set(pe);
|
|
1126
|
-
function
|
|
1126
|
+
function hr(t, { layout: e, layoutId: n }) {
|
|
1127
1127
|
return bt.has(t) || t.startsWith("origin") || (e || n !== void 0) && (!!Le[t] || t === "opacity");
|
|
1128
1128
|
}
|
|
1129
|
-
const z = (t) => !!(t && t.getVelocity),
|
|
1129
|
+
const z = (t) => !!(t && t.getVelocity), dr = (t, e) => e && typeof t == "number" ? e.transform(t) : t, xt = (t, e, n) => n > e ? e : n < t ? t : n, Ht = {
|
|
1130
1130
|
test: (t) => typeof t == "number",
|
|
1131
1131
|
parse: parseFloat,
|
|
1132
1132
|
transform: (t) => t
|
|
@@ -1147,10 +1147,10 @@ const ge = (t) => ({
|
|
|
1147
1147
|
test: (e) => me(e) && e.endsWith(t) && e.split(" ").length === 1,
|
|
1148
1148
|
parse: parseFloat,
|
|
1149
1149
|
transform: (e) => `${e}${t}`
|
|
1150
|
-
}), vt = ge("deg"),
|
|
1151
|
-
...
|
|
1152
|
-
parse: (t) =>
|
|
1153
|
-
transform: (t) =>
|
|
1150
|
+
}), vt = ge("deg"), at = ge("%"), S = ge("px"), za = ge("vh"), Ya = ge("vw"), Ii = {
|
|
1151
|
+
...at,
|
|
1152
|
+
parse: (t) => at.parse(t) / 100,
|
|
1153
|
+
transform: (t) => at.transform(t * 100)
|
|
1154
1154
|
}, Ni = {
|
|
1155
1155
|
...Ht,
|
|
1156
1156
|
transform: Math.round
|
|
@@ -1235,7 +1235,7 @@ function Za(t, e, n) {
|
|
|
1235
1235
|
continue;
|
|
1236
1236
|
let l = !0;
|
|
1237
1237
|
if (typeof a == "number" ? l = a === (r.startsWith("scale") ? 1 : 0) : l = parseFloat(a) === 0, !l || n) {
|
|
1238
|
-
const c =
|
|
1238
|
+
const c = dr(a, Hn[r]);
|
|
1239
1239
|
if (!l) {
|
|
1240
1240
|
s = !1;
|
|
1241
1241
|
const u = Xa[r] || r;
|
|
@@ -1246,7 +1246,7 @@ function Za(t, e, n) {
|
|
|
1246
1246
|
}
|
|
1247
1247
|
return i = i.trim(), n ? i = n(e, s ? "" : i) : s && (i = "none"), i;
|
|
1248
1248
|
}
|
|
1249
|
-
const
|
|
1249
|
+
const pr = (t) => (e) => typeof e == "string" && e.startsWith(t), mr = pr("--"), Ja = pr("var(--"), zn = (t) => Ja(t) ? Qa.test(t.split("/*")[0].trim()) : !1, Qa = /var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;
|
|
1250
1250
|
function Yn(t, e, n) {
|
|
1251
1251
|
const { style: i, vars: s, transformOrigin: o } = t;
|
|
1252
1252
|
let r = !1, a = !1;
|
|
@@ -1255,11 +1255,11 @@ function Yn(t, e, n) {
|
|
|
1255
1255
|
if (bt.has(l)) {
|
|
1256
1256
|
r = !0;
|
|
1257
1257
|
continue;
|
|
1258
|
-
} else if (
|
|
1258
|
+
} else if (mr(l)) {
|
|
1259
1259
|
s[l] = c;
|
|
1260
1260
|
continue;
|
|
1261
1261
|
} else {
|
|
1262
|
-
const u =
|
|
1262
|
+
const u = dr(c, Hn[l]);
|
|
1263
1263
|
l.startsWith("origin") ? (a = !0, o[l] = u) : i[l] = u;
|
|
1264
1264
|
}
|
|
1265
1265
|
}
|
|
@@ -1274,9 +1274,9 @@ const Xn = () => ({
|
|
|
1274
1274
|
transformOrigin: {},
|
|
1275
1275
|
vars: {}
|
|
1276
1276
|
});
|
|
1277
|
-
function
|
|
1277
|
+
function gr(t, e, n) {
|
|
1278
1278
|
for (const i in e)
|
|
1279
|
-
!z(e[i]) && !
|
|
1279
|
+
!z(e[i]) && !hr(i, n) && (t[i] = e[i]);
|
|
1280
1280
|
}
|
|
1281
1281
|
function tl({ transformTemplate: t }, e) {
|
|
1282
1282
|
return Mt(() => {
|
|
@@ -1286,7 +1286,7 @@ function tl({ transformTemplate: t }, e) {
|
|
|
1286
1286
|
}
|
|
1287
1287
|
function el(t, e) {
|
|
1288
1288
|
const n = t.style || {}, i = {};
|
|
1289
|
-
return
|
|
1289
|
+
return gr(i, n, t), Object.assign(i, tl(t, e)), i;
|
|
1290
1290
|
}
|
|
1291
1291
|
function nl(t, e) {
|
|
1292
1292
|
const n = {}, i = el(t, e);
|
|
@@ -1327,9 +1327,9 @@ const il = /* @__PURE__ */ new Set([
|
|
|
1327
1327
|
function Fe(t) {
|
|
1328
1328
|
return t.startsWith("while") || t.startsWith("drag") && t !== "draggable" || t.startsWith("layout") || t.startsWith("onTap") || t.startsWith("onPan") || t.startsWith("onLayout") || il.has(t);
|
|
1329
1329
|
}
|
|
1330
|
-
let
|
|
1330
|
+
let yr = (t) => !Fe(t);
|
|
1331
1331
|
function sl(t) {
|
|
1332
|
-
t && (
|
|
1332
|
+
t && (yr = (e) => e.startsWith("on") ? !Fe(e) : t(e));
|
|
1333
1333
|
}
|
|
1334
1334
|
try {
|
|
1335
1335
|
sl(require("@emotion/is-prop-valid").default);
|
|
@@ -1338,7 +1338,7 @@ try {
|
|
|
1338
1338
|
function rl(t, e, n) {
|
|
1339
1339
|
const i = {};
|
|
1340
1340
|
for (const s in t)
|
|
1341
|
-
s === "values" && typeof t.values == "object" || (
|
|
1341
|
+
s === "values" && typeof t.values == "object" || (yr(s) || n === !0 && Fe(s) || !e && !Fe(s) || // If trying to use native HTML drag events, forward drag listeners
|
|
1342
1342
|
t.draggable && s.startsWith("onDrag")) && (i[s] = t[s]);
|
|
1343
1343
|
return i;
|
|
1344
1344
|
}
|
|
@@ -1383,13 +1383,13 @@ function qn(t, {
|
|
|
1383
1383
|
const { attrs: d, style: p, dimensions: m } = t;
|
|
1384
1384
|
d.transform && (m && (p.transform = d.transform), delete d.transform), m && (s !== void 0 || o !== void 0 || p.transform) && (p.transformOrigin = ol(m, s !== void 0 ? s : 0.5, o !== void 0 ? o : 0.5)), e !== void 0 && (d.x = e), n !== void 0 && (d.y = n), i !== void 0 && (d.scale = i), r !== void 0 && cl(d, r, a, l, !1);
|
|
1385
1385
|
}
|
|
1386
|
-
const
|
|
1386
|
+
const vr = () => ({
|
|
1387
1387
|
...Xn(),
|
|
1388
1388
|
attrs: {}
|
|
1389
1389
|
}), Zn = (t) => typeof t == "string" && t.toLowerCase() === "svg";
|
|
1390
1390
|
function ul(t, e, n, i) {
|
|
1391
1391
|
const s = Mt(() => {
|
|
1392
|
-
const o =
|
|
1392
|
+
const o = vr();
|
|
1393
1393
|
return qn(o, e, Zn(i), t.transformTemplate), {
|
|
1394
1394
|
...o.attrs,
|
|
1395
1395
|
style: { ...o.style }
|
|
@@ -1397,25 +1397,25 @@ function ul(t, e, n, i) {
|
|
|
1397
1397
|
}, [e]);
|
|
1398
1398
|
if (t.style) {
|
|
1399
1399
|
const o = {};
|
|
1400
|
-
|
|
1400
|
+
gr(o, t.style, t), s.style = { ...o, ...s.style };
|
|
1401
1401
|
}
|
|
1402
1402
|
return s;
|
|
1403
1403
|
}
|
|
1404
1404
|
function fl(t = !1) {
|
|
1405
1405
|
return (n, i, s, { latestValues: o }, r) => {
|
|
1406
|
-
const l = (Kn(n) ? ul : nl)(i, o, r, n), c = rl(i, typeof n == "string", t), u = n !==
|
|
1406
|
+
const l = (Kn(n) ? ul : nl)(i, o, r, n), c = rl(i, typeof n == "string", t), u = n !== nr ? { ...c, ...l, ref: s } : {}, { children: f } = i, d = Mt(() => z(f) ? f.get() : f, [f]);
|
|
1407
1407
|
return aa(n, {
|
|
1408
1408
|
...u,
|
|
1409
1409
|
children: d
|
|
1410
1410
|
});
|
|
1411
1411
|
};
|
|
1412
1412
|
}
|
|
1413
|
-
function
|
|
1413
|
+
function Pr(t, { style: e, vars: n }, i, s) {
|
|
1414
1414
|
Object.assign(t.style, e, s && s.getProjectionStyles(i));
|
|
1415
1415
|
for (const o in n)
|
|
1416
1416
|
t.style.setProperty(o, n[o]);
|
|
1417
1417
|
}
|
|
1418
|
-
const
|
|
1418
|
+
const xr = /* @__PURE__ */ new Set([
|
|
1419
1419
|
"baseFrequency",
|
|
1420
1420
|
"diffuseConstant",
|
|
1421
1421
|
"kernelMatrix",
|
|
@@ -1440,19 +1440,19 @@ const Tr = /* @__PURE__ */ new Set([
|
|
|
1440
1440
|
"textLength",
|
|
1441
1441
|
"lengthAdjust"
|
|
1442
1442
|
]);
|
|
1443
|
-
function
|
|
1444
|
-
|
|
1443
|
+
function Tr(t, e, n, i) {
|
|
1444
|
+
Pr(t, e, void 0, i);
|
|
1445
1445
|
for (const s in e.attrs)
|
|
1446
|
-
t.setAttribute(
|
|
1446
|
+
t.setAttribute(xr.has(s) ? s : Ue(s), e.attrs[s]);
|
|
1447
1447
|
}
|
|
1448
1448
|
function Jn(t, e, n) {
|
|
1449
1449
|
var i;
|
|
1450
1450
|
const { style: s } = t, o = {};
|
|
1451
1451
|
for (const r in s)
|
|
1452
|
-
(z(s[r]) || e.style && z(e.style[r]) ||
|
|
1452
|
+
(z(s[r]) || e.style && z(e.style[r]) || hr(r, t) || ((i = n == null ? void 0 : n.getValue(r)) === null || i === void 0 ? void 0 : i.liveStyle) !== void 0) && (o[r] = s[r]);
|
|
1453
1453
|
return n && s && typeof s.willChange == "string" && (n.applyWillChange = !1), o;
|
|
1454
1454
|
}
|
|
1455
|
-
function
|
|
1455
|
+
function br(t, e, n) {
|
|
1456
1456
|
const i = Jn(t, e, n);
|
|
1457
1457
|
for (const s in t)
|
|
1458
1458
|
if (z(t[s]) || z(e[s])) {
|
|
@@ -1487,7 +1487,7 @@ function Re(t) {
|
|
|
1487
1487
|
const e = z(t) ? t.get() : t;
|
|
1488
1488
|
return hl(e) ? e.toValue() : e;
|
|
1489
1489
|
}
|
|
1490
|
-
const
|
|
1490
|
+
const wr = /* @__PURE__ */ new Set([
|
|
1491
1491
|
"opacity",
|
|
1492
1492
|
"clipPath",
|
|
1493
1493
|
"filter",
|
|
@@ -1496,10 +1496,10 @@ const Sr = /* @__PURE__ */ new Set([
|
|
|
1496
1496
|
// or until we implement support for linear() easing.
|
|
1497
1497
|
// "background-color"
|
|
1498
1498
|
]);
|
|
1499
|
-
function
|
|
1499
|
+
function Sr(t) {
|
|
1500
1500
|
if (bt.has(t))
|
|
1501
1501
|
return "transform";
|
|
1502
|
-
if (
|
|
1502
|
+
if (wr.has(t))
|
|
1503
1503
|
return Ue(t);
|
|
1504
1504
|
}
|
|
1505
1505
|
function $e(t, e) {
|
|
@@ -1516,12 +1516,12 @@ function pl({ applyWillChange: t = !1, scrapeMotionValuesFromProps: e, createRen
|
|
|
1516
1516
|
};
|
|
1517
1517
|
return i && (l.mount = (c) => i(s, c, l)), l;
|
|
1518
1518
|
}
|
|
1519
|
-
const
|
|
1519
|
+
const Cr = (t) => (e, n) => {
|
|
1520
1520
|
const i = $(Ie), s = $(Ne), o = () => pl(t, e, i, s, n);
|
|
1521
1521
|
return n ? o() : ti(o);
|
|
1522
1522
|
};
|
|
1523
1523
|
function ml(t, e) {
|
|
1524
|
-
const n =
|
|
1524
|
+
const n = Sr(e);
|
|
1525
1525
|
n && $e(t, n);
|
|
1526
1526
|
}
|
|
1527
1527
|
function $i(t, e, n) {
|
|
@@ -1540,7 +1540,7 @@ function gl(t, e, n, i, s) {
|
|
|
1540
1540
|
for (const b in c)
|
|
1541
1541
|
r[b] = Re(c[b]);
|
|
1542
1542
|
let { initial: u, animate: f } = t;
|
|
1543
|
-
const d = We(t), p =
|
|
1543
|
+
const d = We(t), p = fr(t);
|
|
1544
1544
|
e && p && !d && t.inherit !== !1 && (u === void 0 && (u = e.initial), f === void 0 && (f = e.animate));
|
|
1545
1545
|
let m = n ? n.initial === !1 : !1;
|
|
1546
1546
|
m = m || u === !1;
|
|
@@ -1561,10 +1561,10 @@ function gl(t, e, n, i, s) {
|
|
|
1561
1561
|
ml(a, x);
|
|
1562
1562
|
}), a.length && (r.willChange = a.join(","))), r;
|
|
1563
1563
|
}
|
|
1564
|
-
const { schedule: M, cancel: mt, state: W, steps: sn } =
|
|
1565
|
-
useVisualState:
|
|
1566
|
-
scrapeMotionValuesFromProps:
|
|
1567
|
-
createRenderState:
|
|
1564
|
+
const { schedule: M, cancel: mt, state: W, steps: sn } = lr(typeof requestAnimationFrame < "u" ? requestAnimationFrame : K, !0), yl = {
|
|
1565
|
+
useVisualState: Cr({
|
|
1566
|
+
scrapeMotionValuesFromProps: br,
|
|
1567
|
+
createRenderState: vr,
|
|
1568
1568
|
onMount: (t, e, { renderState: n, latestValues: i }) => {
|
|
1569
1569
|
M.read(() => {
|
|
1570
1570
|
try {
|
|
@@ -1578,12 +1578,12 @@ const { schedule: M, cancel: mt, state: W, steps: sn } = cr(typeof requestAnimat
|
|
|
1578
1578
|
};
|
|
1579
1579
|
}
|
|
1580
1580
|
}), M.render(() => {
|
|
1581
|
-
qn(n, i, Zn(e.tagName), t.transformTemplate),
|
|
1581
|
+
qn(n, i, Zn(e.tagName), t.transformTemplate), Tr(e, n);
|
|
1582
1582
|
});
|
|
1583
1583
|
}
|
|
1584
1584
|
})
|
|
1585
1585
|
}, vl = {
|
|
1586
|
-
useVisualState:
|
|
1586
|
+
useVisualState: Cr({
|
|
1587
1587
|
applyWillChange: !0,
|
|
1588
1588
|
scrapeMotionValuesFromProps: Jn,
|
|
1589
1589
|
createRenderState: Xn
|
|
@@ -1598,10 +1598,10 @@ function Pl(t, { forwardMotionProps: e = !1 }, n, i) {
|
|
|
1598
1598
|
Component: t
|
|
1599
1599
|
};
|
|
1600
1600
|
}
|
|
1601
|
-
function
|
|
1601
|
+
function ct(t, e, n, i = { passive: !0 }) {
|
|
1602
1602
|
return t.addEventListener(e, n, i), () => t.removeEventListener(e, n);
|
|
1603
1603
|
}
|
|
1604
|
-
const
|
|
1604
|
+
const Ar = (t) => t.pointerType === "mouse" ? typeof t.button != "number" || t.button <= 0 : t.isPrimary !== !1;
|
|
1605
1605
|
function Ge(t, e = "page") {
|
|
1606
1606
|
return {
|
|
1607
1607
|
point: {
|
|
@@ -1610,12 +1610,12 @@ function Ge(t, e = "page") {
|
|
|
1610
1610
|
}
|
|
1611
1611
|
};
|
|
1612
1612
|
}
|
|
1613
|
-
const xl = (t) => (e) =>
|
|
1613
|
+
const xl = (t) => (e) => Ar(e) && t(e, Ge(e));
|
|
1614
1614
|
function ut(t, e, n, i) {
|
|
1615
|
-
return
|
|
1615
|
+
return ct(t, e, xl(n), i);
|
|
1616
1616
|
}
|
|
1617
1617
|
const Tl = (t, e) => (n) => e(t(n)), ft = (...t) => t.reduce(Tl);
|
|
1618
|
-
function
|
|
1618
|
+
function Er(t) {
|
|
1619
1619
|
let e = null;
|
|
1620
1620
|
return () => {
|
|
1621
1621
|
const n = () => {
|
|
@@ -1624,8 +1624,8 @@ function Rr(t) {
|
|
|
1624
1624
|
return e === null ? (e = t, n) : !1;
|
|
1625
1625
|
};
|
|
1626
1626
|
}
|
|
1627
|
-
const Ki =
|
|
1628
|
-
function
|
|
1627
|
+
const Ki = Er("dragHorizontal"), Gi = Er("dragVertical");
|
|
1628
|
+
function Rr(t) {
|
|
1629
1629
|
let e = !1;
|
|
1630
1630
|
if (t === "y")
|
|
1631
1631
|
e = Gi();
|
|
@@ -1639,8 +1639,8 @@ function Vr(t) {
|
|
|
1639
1639
|
}
|
|
1640
1640
|
return e;
|
|
1641
1641
|
}
|
|
1642
|
-
function
|
|
1643
|
-
const t =
|
|
1642
|
+
function Vr() {
|
|
1643
|
+
const t = Rr(!0);
|
|
1644
1644
|
return t ? (t(), !1) : !0;
|
|
1645
1645
|
}
|
|
1646
1646
|
class wt {
|
|
@@ -1652,7 +1652,7 @@ class wt {
|
|
|
1652
1652
|
}
|
|
1653
1653
|
function Hi(t, e) {
|
|
1654
1654
|
const n = e ? "pointerenter" : "pointerleave", i = e ? "onHoverStart" : "onHoverEnd", s = (o, r) => {
|
|
1655
|
-
if (o.pointerType === "touch" ||
|
|
1655
|
+
if (o.pointerType === "touch" || Vr())
|
|
1656
1656
|
return;
|
|
1657
1657
|
const a = t.getProps();
|
|
1658
1658
|
t.animationState && a.whileHover && t.animationState.setActive("whileHover", e);
|
|
@@ -1687,12 +1687,12 @@ class wl extends wt {
|
|
|
1687
1687
|
!this.isActive || !this.node.animationState || (this.node.animationState.setActive("whileFocus", !1), this.isActive = !1);
|
|
1688
1688
|
}
|
|
1689
1689
|
mount() {
|
|
1690
|
-
this.unmount = ft(
|
|
1690
|
+
this.unmount = ft(ct(this.node.current, "focus", () => this.onFocus()), ct(this.node.current, "blur", () => this.onBlur()));
|
|
1691
1691
|
}
|
|
1692
1692
|
unmount() {
|
|
1693
1693
|
}
|
|
1694
1694
|
}
|
|
1695
|
-
const
|
|
1695
|
+
const Dr = (t, e) => e ? t === e ? !0 : Dr(t, e.parentElement) : !1;
|
|
1696
1696
|
function rn(t, e) {
|
|
1697
1697
|
if (!e)
|
|
1698
1698
|
return;
|
|
@@ -1708,7 +1708,7 @@ class Sl extends wt {
|
|
|
1708
1708
|
const i = this.node.getProps(), o = ut(window, "pointerup", (a, l) => {
|
|
1709
1709
|
if (!this.checkPressEnd())
|
|
1710
1710
|
return;
|
|
1711
|
-
const { onTap: c, onTapCancel: u, globalTapTarget: f } = this.node.getProps(), d = !f && !
|
|
1711
|
+
const { onTap: c, onTapCancel: u, globalTapTarget: f } = this.node.getProps(), d = !f && !Dr(this.node.current, a.target) ? u : c;
|
|
1712
1712
|
d && M.update(() => d(a, l));
|
|
1713
1713
|
}, {
|
|
1714
1714
|
passive: !(i.onTap || i.onPointerUp)
|
|
@@ -1726,12 +1726,12 @@ class Sl extends wt {
|
|
|
1726
1726
|
u && M.postRender(() => u(l, c));
|
|
1727
1727
|
});
|
|
1728
1728
|
};
|
|
1729
|
-
this.removeEndListeners(), this.removeEndListeners =
|
|
1729
|
+
this.removeEndListeners(), this.removeEndListeners = ct(this.node.current, "keyup", r), rn("down", (a, l) => {
|
|
1730
1730
|
this.startPress(a, l);
|
|
1731
1731
|
});
|
|
1732
|
-
}, n =
|
|
1732
|
+
}, n = ct(this.node.current, "keydown", e), i = () => {
|
|
1733
1733
|
this.isPressing && rn("cancel", (o, r) => this.cancelPress(o, r));
|
|
1734
|
-
}, s =
|
|
1734
|
+
}, s = ct(this.node.current, "blur", i);
|
|
1735
1735
|
this.removeAccessibleListeners = ft(n, s);
|
|
1736
1736
|
};
|
|
1737
1737
|
}
|
|
@@ -1741,7 +1741,7 @@ class Sl extends wt {
|
|
|
1741
1741
|
s && this.node.animationState && this.node.animationState.setActive("whileTap", !0), i && M.postRender(() => i(e, n));
|
|
1742
1742
|
}
|
|
1743
1743
|
checkPressEnd() {
|
|
1744
|
-
return this.removeEndListeners(), this.isPressing = !1, this.node.getProps().whileTap && this.node.animationState && this.node.animationState.setActive("whileTap", !1), !
|
|
1744
|
+
return this.removeEndListeners(), this.isPressing = !1, this.node.getProps().whileTap && this.node.animationState && this.node.animationState.setActive("whileTap", !1), !Vr();
|
|
1745
1745
|
}
|
|
1746
1746
|
cancelPress(e, n) {
|
|
1747
1747
|
if (!this.checkPressEnd())
|
|
@@ -1752,7 +1752,7 @@ class Sl extends wt {
|
|
|
1752
1752
|
mount() {
|
|
1753
1753
|
const e = this.node.getProps(), n = ut(e.globalTapTarget ? window : this.node.current, "pointerdown", this.startPointerPress, {
|
|
1754
1754
|
passive: !(e.onTapStart || e.onPointerStart)
|
|
1755
|
-
}), i =
|
|
1755
|
+
}), i = ct(this.node.current, "focus", this.startAccessiblePress);
|
|
1756
1756
|
this.removeStartListeners = ft(n, i);
|
|
1757
1757
|
}
|
|
1758
1758
|
unmount() {
|
|
@@ -1830,7 +1830,7 @@ const kl = {
|
|
|
1830
1830
|
Feature: bl
|
|
1831
1831
|
}
|
|
1832
1832
|
};
|
|
1833
|
-
function
|
|
1833
|
+
function Mr(t, e) {
|
|
1834
1834
|
if (!Array.isArray(e))
|
|
1835
1835
|
return !1;
|
|
1836
1836
|
const n = e.length;
|
|
@@ -1883,11 +1883,11 @@ const Pt = {
|
|
|
1883
1883
|
set: (t) => {
|
|
1884
1884
|
Ve = t, queueMicrotask(Nl);
|
|
1885
1885
|
}
|
|
1886
|
-
},
|
|
1886
|
+
}, kr = (t) => /^0[^.\s]+$/u.test(t);
|
|
1887
1887
|
function Ul(t) {
|
|
1888
|
-
return typeof t == "number" ? t === 0 : t !== null ? t === "none" || t === "0" ||
|
|
1888
|
+
return typeof t == "number" ? t === 0 : t !== null ? t === "none" || t === "0" || kr(t) : !0;
|
|
1889
1889
|
}
|
|
1890
|
-
const
|
|
1890
|
+
const Lr = (t) => /^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t), Wl = (
|
|
1891
1891
|
// eslint-disable-next-line redos-detector/no-unsafe-regex -- false positive, as it can match a lot of words
|
|
1892
1892
|
/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u
|
|
1893
1893
|
);
|
|
@@ -1899,7 +1899,7 @@ function $l(t) {
|
|
|
1899
1899
|
return [`--${n ?? i}`, s];
|
|
1900
1900
|
}
|
|
1901
1901
|
const Kl = 4;
|
|
1902
|
-
function
|
|
1902
|
+
function Fr(t, e, n = 1) {
|
|
1903
1903
|
pt(n <= Kl, `Max CSS variable fallback depth detected in property "${t}". This may indicate a circular fallback dependency.`);
|
|
1904
1904
|
const [i, s] = $l(t);
|
|
1905
1905
|
if (!i)
|
|
@@ -1907,9 +1907,9 @@ function Or(t, e, n = 1) {
|
|
|
1907
1907
|
const o = window.getComputedStyle(e).getPropertyValue(i);
|
|
1908
1908
|
if (o) {
|
|
1909
1909
|
const r = o.trim();
|
|
1910
|
-
return
|
|
1910
|
+
return Lr(r) ? parseFloat(r) : r;
|
|
1911
1911
|
}
|
|
1912
|
-
return zn(s) ?
|
|
1912
|
+
return zn(s) ? Fr(s, e, n + 1) : s;
|
|
1913
1913
|
}
|
|
1914
1914
|
const Gl = /* @__PURE__ */ new Set([
|
|
1915
1915
|
"width",
|
|
@@ -1954,12 +1954,12 @@ const Kt = {
|
|
|
1954
1954
|
};
|
|
1955
1955
|
Kt.translateX = Kt.x;
|
|
1956
1956
|
Kt.translateY = Kt.y;
|
|
1957
|
-
const
|
|
1957
|
+
const Or = (t) => (e) => e.test(t), Xl = {
|
|
1958
1958
|
test: (t) => t === "auto",
|
|
1959
1959
|
parse: (t) => t
|
|
1960
|
-
},
|
|
1960
|
+
}, jr = [Ht, S, at, vt, Ya, za, Xl], qi = (t) => jr.find(Or(t)), Dt = /* @__PURE__ */ new Set();
|
|
1961
1961
|
let bn = !1, wn = !1;
|
|
1962
|
-
function
|
|
1962
|
+
function _r() {
|
|
1963
1963
|
if (wn) {
|
|
1964
1964
|
const t = Array.from(Dt).filter((i) => i.needsMeasurement), e = new Set(t.map((i) => i.element)), n = /* @__PURE__ */ new Map();
|
|
1965
1965
|
e.forEach((i) => {
|
|
@@ -1978,20 +1978,20 @@ function Br() {
|
|
|
1978
1978
|
}
|
|
1979
1979
|
wn = !1, bn = !1, Dt.forEach((t) => t.complete()), Dt.clear();
|
|
1980
1980
|
}
|
|
1981
|
-
function
|
|
1981
|
+
function Br() {
|
|
1982
1982
|
Dt.forEach((t) => {
|
|
1983
1983
|
t.readKeyframes(), t.needsMeasurement && (wn = !0);
|
|
1984
1984
|
});
|
|
1985
1985
|
}
|
|
1986
1986
|
function ql() {
|
|
1987
|
-
|
|
1987
|
+
Br(), _r();
|
|
1988
1988
|
}
|
|
1989
1989
|
class ni {
|
|
1990
1990
|
constructor(e, n, i, s, o, r = !1) {
|
|
1991
1991
|
this.isComplete = !1, this.isAsync = !1, this.needsMeasurement = !1, this.isScheduled = !1, this.unresolvedKeyframes = [...e], this.onComplete = n, this.name = i, this.motionValue = s, this.element = o, this.isAsync = r;
|
|
1992
1992
|
}
|
|
1993
1993
|
scheduleResolve() {
|
|
1994
|
-
this.isScheduled = !0, this.isAsync ? (Dt.add(this), bn || (bn = !0, M.read(
|
|
1994
|
+
this.isScheduled = !0, this.isAsync ? (Dt.add(this), bn || (bn = !0, M.read(Br), M.resolveKeyframes(_r))) : (this.readKeyframes(), this.complete());
|
|
1995
1995
|
}
|
|
1996
1996
|
readKeyframes() {
|
|
1997
1997
|
const { unresolvedKeyframes: e, name: n, element: i, motionValue: s } = this;
|
|
@@ -2027,7 +2027,7 @@ class ni {
|
|
|
2027
2027
|
this.isComplete || this.scheduleResolve();
|
|
2028
2028
|
}
|
|
2029
2029
|
}
|
|
2030
|
-
const ii = (t, e) => (n) => !!(me(n) && Ga.test(n) && n.startsWith(t) || e && !Ha(n) && Object.prototype.hasOwnProperty.call(n, e)),
|
|
2030
|
+
const ii = (t, e) => (n) => !!(me(n) && Ga.test(n) && n.startsWith(t) || e && !Ha(n) && Object.prototype.hasOwnProperty.call(n, e)), Ir = (t, e, n) => (i) => {
|
|
2031
2031
|
if (!me(i))
|
|
2032
2032
|
return i;
|
|
2033
2033
|
const [s, o, r, a] = i.match(Gn);
|
|
@@ -2042,7 +2042,7 @@ const ii = (t, e) => (n) => !!(me(n) && Ga.test(n) && n.startsWith(t) || e && !H
|
|
|
2042
2042
|
transform: (t) => Math.round(Zl(t))
|
|
2043
2043
|
}, Vt = {
|
|
2044
2044
|
test: ii("rgb", "red"),
|
|
2045
|
-
parse:
|
|
2045
|
+
parse: Ir("red", "green", "blue"),
|
|
2046
2046
|
transform: ({ red: t, green: e, blue: n, alpha: i = 1 }) => "rgba(" + an.transform(t) + ", " + an.transform(e) + ", " + an.transform(n) + ", " + ne(ee.transform(i)) + ")"
|
|
2047
2047
|
};
|
|
2048
2048
|
function Jl(t) {
|
|
@@ -2060,8 +2060,8 @@ const Sn = {
|
|
|
2060
2060
|
transform: Vt.transform
|
|
2061
2061
|
}, It = {
|
|
2062
2062
|
test: ii("hsl", "hue"),
|
|
2063
|
-
parse:
|
|
2064
|
-
transform: ({ hue: t, saturation: e, lightness: n, alpha: i = 1 }) => "hsla(" + Math.round(t) + ", " +
|
|
2063
|
+
parse: Ir("hue", "saturation", "lightness"),
|
|
2064
|
+
transform: ({ hue: t, saturation: e, lightness: n, alpha: i = 1 }) => "hsla(" + Math.round(t) + ", " + at.transform(ne(e)) + ", " + at.transform(ne(n)) + ", " + ne(ee.transform(i)) + ")"
|
|
2065
2065
|
}, H = {
|
|
2066
2066
|
test: (t) => Vt.test(t) || Sn.test(t) || It.test(t),
|
|
2067
2067
|
parse: (t) => Vt.test(t) ? Vt.parse(t) : It.test(t) ? It.parse(t) : Sn.parse(t),
|
|
@@ -2071,7 +2071,7 @@ function Ql(t) {
|
|
|
2071
2071
|
var e, n;
|
|
2072
2072
|
return isNaN(t) && me(t) && (((e = t.match(Gn)) === null || e === void 0 ? void 0 : e.length) || 0) + (((n = t.match(Ka)) === null || n === void 0 ? void 0 : n.length) || 0) > 0;
|
|
2073
2073
|
}
|
|
2074
|
-
const
|
|
2074
|
+
const Nr = "number", Ur = "color", tc = "var", ec = "var(", Zi = "${}", nc = /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;
|
|
2075
2075
|
function le(t) {
|
|
2076
2076
|
const e = t.toString(), n = [], i = {
|
|
2077
2077
|
color: [],
|
|
@@ -2079,33 +2079,33 @@ function le(t) {
|
|
|
2079
2079
|
var: []
|
|
2080
2080
|
}, s = [];
|
|
2081
2081
|
let o = 0;
|
|
2082
|
-
const a = e.replace(nc, (l) => (H.test(l) ? (i.color.push(o), s.push(
|
|
2082
|
+
const a = e.replace(nc, (l) => (H.test(l) ? (i.color.push(o), s.push(Ur), n.push(H.parse(l))) : l.startsWith(ec) ? (i.var.push(o), s.push(tc), n.push(l)) : (i.number.push(o), s.push(Nr), n.push(parseFloat(l))), ++o, Zi)).split(Zi);
|
|
2083
2083
|
return { values: n, split: a, indexes: i, types: s };
|
|
2084
2084
|
}
|
|
2085
|
-
function
|
|
2085
|
+
function Wr(t) {
|
|
2086
2086
|
return le(t).values;
|
|
2087
2087
|
}
|
|
2088
|
-
function
|
|
2088
|
+
function $r(t) {
|
|
2089
2089
|
const { split: e, types: n } = le(t), i = e.length;
|
|
2090
2090
|
return (s) => {
|
|
2091
2091
|
let o = "";
|
|
2092
2092
|
for (let r = 0; r < i; r++)
|
|
2093
2093
|
if (o += e[r], s[r] !== void 0) {
|
|
2094
2094
|
const a = n[r];
|
|
2095
|
-
a ===
|
|
2095
|
+
a === Nr ? o += ne(s[r]) : a === Ur ? o += H.transform(s[r]) : o += s[r];
|
|
2096
2096
|
}
|
|
2097
2097
|
return o;
|
|
2098
2098
|
};
|
|
2099
2099
|
}
|
|
2100
2100
|
const ic = (t) => typeof t == "number" ? 0 : t;
|
|
2101
2101
|
function sc(t) {
|
|
2102
|
-
const e =
|
|
2103
|
-
return
|
|
2102
|
+
const e = Wr(t);
|
|
2103
|
+
return $r(t)(e.map(ic));
|
|
2104
2104
|
}
|
|
2105
2105
|
const Tt = {
|
|
2106
2106
|
test: Ql,
|
|
2107
|
-
parse:
|
|
2108
|
-
createTransformer:
|
|
2107
|
+
parse: Wr,
|
|
2108
|
+
createTransformer: $r,
|
|
2109
2109
|
getAnimatableNone: sc
|
|
2110
2110
|
}, rc = /* @__PURE__ */ new Set(["brightness", "contrast", "saturate", "opacity"]);
|
|
2111
2111
|
function oc(t) {
|
|
@@ -2142,7 +2142,7 @@ const ac = /\b([a-z-]*)\(.*?\)/gu, Cn = {
|
|
|
2142
2142
|
filter: Cn,
|
|
2143
2143
|
WebkitFilter: Cn
|
|
2144
2144
|
}, si = (t) => lc[t];
|
|
2145
|
-
function
|
|
2145
|
+
function Kr(t, e) {
|
|
2146
2146
|
let n = si(t);
|
|
2147
2147
|
return n !== Cn && (n = Tt), n.getAnimatableNone ? n.getAnimatableNone(e) : void 0;
|
|
2148
2148
|
}
|
|
@@ -2155,9 +2155,9 @@ function uc(t, e, n) {
|
|
|
2155
2155
|
}
|
|
2156
2156
|
if (s && n)
|
|
2157
2157
|
for (const o of e)
|
|
2158
|
-
t[o] =
|
|
2158
|
+
t[o] = Kr(n, s);
|
|
2159
2159
|
}
|
|
2160
|
-
class
|
|
2160
|
+
class Gr extends ni {
|
|
2161
2161
|
constructor(e, n, i, s) {
|
|
2162
2162
|
super(e, n, i, s, s == null ? void 0 : s.owner, !0);
|
|
2163
2163
|
}
|
|
@@ -2169,7 +2169,7 @@ class Hr extends ni {
|
|
|
2169
2169
|
for (let l = 0; l < e.length; l++) {
|
|
2170
2170
|
let c = e[l];
|
|
2171
2171
|
if (typeof c == "string" && (c = c.trim(), zn(c))) {
|
|
2172
|
-
const u =
|
|
2172
|
+
const u = Fr(c, n.current);
|
|
2173
2173
|
u !== void 0 && (e[l] = u), l === e.length - 1 && (this.finalKeyframe = c);
|
|
2174
2174
|
}
|
|
2175
2175
|
}
|
|
@@ -2212,7 +2212,7 @@ class Hr extends ni {
|
|
|
2212
2212
|
}), this.resolveNoneKeyframes();
|
|
2213
2213
|
}
|
|
2214
2214
|
}
|
|
2215
|
-
function
|
|
2215
|
+
function Hr(t) {
|
|
2216
2216
|
let e;
|
|
2217
2217
|
return () => (e === void 0 && (e = t()), e);
|
|
2218
2218
|
}
|
|
@@ -2236,7 +2236,7 @@ function hc(t, e, n, i) {
|
|
|
2236
2236
|
const o = t[t.length - 1], r = Ji(s, e), a = Ji(o, e);
|
|
2237
2237
|
return Gt(r === a, `You are trying to animate ${e} from "${s}" to "${o}". ${s} is not an animatable value - to enable this animation set ${s} to a value animatable to ${o} via the \`style\` property.`), !r || !a ? !1 : fc(t) || n === "spring" && i;
|
|
2238
2238
|
}
|
|
2239
|
-
class
|
|
2239
|
+
class zr {
|
|
2240
2240
|
constructor({ autoplay: e = !0, delay: n = 0, type: i = "keyframes", repeat: s = 0, repeatDelay: o = 0, repeatType: r = "loop", ...a }) {
|
|
2241
2241
|
this.isStopped = !1, this.hasAttemptedResolve = !1, this.options = {
|
|
2242
2242
|
autoplay: e,
|
|
@@ -2294,13 +2294,13 @@ class Yr {
|
|
|
2294
2294
|
});
|
|
2295
2295
|
}
|
|
2296
2296
|
}
|
|
2297
|
-
function
|
|
2297
|
+
function Yr(t, e) {
|
|
2298
2298
|
return e ? t * (1e3 / e) : 0;
|
|
2299
2299
|
}
|
|
2300
2300
|
const dc = 5;
|
|
2301
|
-
function
|
|
2301
|
+
function Xr(t, e, n) {
|
|
2302
2302
|
const i = Math.max(e - dc, 0);
|
|
2303
|
-
return
|
|
2303
|
+
return Yr(n - t(i), e - i);
|
|
2304
2304
|
}
|
|
2305
2305
|
const ln = 1e-3, pc = 0.01, Qi = 10, mc = 0.05, gc = 1;
|
|
2306
2306
|
function yc({ duration: t = 800, bounce: e = 0.25, velocity: n = 0, mass: i = 1 }) {
|
|
@@ -2369,7 +2369,7 @@ function bc(t) {
|
|
|
2369
2369
|
}
|
|
2370
2370
|
return e;
|
|
2371
2371
|
}
|
|
2372
|
-
function
|
|
2372
|
+
function qr({ keyframes: t, restDelta: e, restSpeed: n, ...i }) {
|
|
2373
2373
|
const s = t[0], o = t[t.length - 1], r = { done: !1, value: s }, { stiffness: a, damping: l, mass: c, duration: u, velocity: f, isResolvedFromDuration: d } = bc({
|
|
2374
2374
|
...i,
|
|
2375
2375
|
velocity: -dt(i.velocity || 0)
|
|
@@ -2399,7 +2399,7 @@ function Zr({ keyframes: t, restDelta: e, restSpeed: n, ...i }) {
|
|
|
2399
2399
|
r.done = v >= u;
|
|
2400
2400
|
else {
|
|
2401
2401
|
let A = p;
|
|
2402
|
-
v !== 0 && (m < 1 ? A =
|
|
2402
|
+
v !== 0 && (m < 1 ? A = Xr(y, v, w) : A = 0);
|
|
2403
2403
|
const L = Math.abs(A) <= n, q = Math.abs(o - w) <= e;
|
|
2404
2404
|
r.done = L && q;
|
|
2405
2405
|
}
|
|
@@ -2421,9 +2421,9 @@ function es({ keyframes: t, velocity: e = 0, power: n = 0.8, timeConstant: i = 3
|
|
|
2421
2421
|
};
|
|
2422
2422
|
let A, L;
|
|
2423
2423
|
const q = (E) => {
|
|
2424
|
-
p(d.value) && (A = E, L =
|
|
2424
|
+
p(d.value) && (A = E, L = qr({
|
|
2425
2425
|
keyframes: [d.value, m(d.value)],
|
|
2426
|
-
velocity:
|
|
2426
|
+
velocity: Xr(v, E, d.value),
|
|
2427
2427
|
// TODO: This should be passing * 1000
|
|
2428
2428
|
damping: s,
|
|
2429
2429
|
stiffness: o,
|
|
@@ -2439,11 +2439,11 @@ function es({ keyframes: t, velocity: e = 0, power: n = 0.8, timeConstant: i = 3
|
|
|
2439
2439
|
}
|
|
2440
2440
|
};
|
|
2441
2441
|
}
|
|
2442
|
-
const
|
|
2442
|
+
const Zr = (t, e, n) => (((1 - 3 * n + 3 * e) * t + (3 * n - 6 * e)) * t + 3 * e) * t, wc = 1e-7, Sc = 12;
|
|
2443
2443
|
function Cc(t, e, n, i, s) {
|
|
2444
2444
|
let o, r, a = 0;
|
|
2445
2445
|
do
|
|
2446
|
-
r = e + (n - e) / 2, o =
|
|
2446
|
+
r = e + (n - e) / 2, o = Zr(r, i, s) - t, o > 0 ? n = r : e = r;
|
|
2447
2447
|
while (Math.abs(o) > wc && ++a < Sc);
|
|
2448
2448
|
return r;
|
|
2449
2449
|
}
|
|
@@ -2451,19 +2451,19 @@ function ye(t, e, n, i) {
|
|
|
2451
2451
|
if (t === e && n === i)
|
|
2452
2452
|
return K;
|
|
2453
2453
|
const s = (o) => Cc(o, 0, 1, t, n);
|
|
2454
|
-
return (o) => o === 0 || o === 1 ? o :
|
|
2454
|
+
return (o) => o === 0 || o === 1 ? o : Zr(s(o), e, i);
|
|
2455
2455
|
}
|
|
2456
|
-
const Ac = ye(0.42, 0, 1, 1), Ec = ye(0, 0, 0.58, 1),
|
|
2456
|
+
const Ac = ye(0.42, 0, 1, 1), Ec = ye(0, 0, 0.58, 1), Jr = ye(0.42, 0, 0.58, 1), Rc = (t) => Array.isArray(t) && typeof t[0] != "number", Qr = (t) => (e) => e <= 0.5 ? t(2 * e) / 2 : (2 - t(2 * (1 - e))) / 2, to = (t) => (e) => 1 - t(1 - e), ri = (t) => 1 - Math.sin(Math.acos(t)), eo = to(ri), Vc = Qr(ri), no = ye(0.33, 1.53, 0.69, 0.99), oi = to(no), Dc = Qr(oi), Mc = (t) => (t *= 2) < 1 ? 0.5 * oi(t) : 0.5 * (2 - Math.pow(2, -10 * (t - 1))), ns = {
|
|
2457
2457
|
linear: K,
|
|
2458
2458
|
easeIn: Ac,
|
|
2459
|
-
easeInOut:
|
|
2459
|
+
easeInOut: Jr,
|
|
2460
2460
|
easeOut: Ec,
|
|
2461
2461
|
circIn: ri,
|
|
2462
2462
|
circInOut: Vc,
|
|
2463
|
-
circOut:
|
|
2463
|
+
circOut: eo,
|
|
2464
2464
|
backIn: oi,
|
|
2465
2465
|
backInOut: Dc,
|
|
2466
|
-
backOut:
|
|
2466
|
+
backOut: no,
|
|
2467
2467
|
anticipate: Mc
|
|
2468
2468
|
}, is = (t) => {
|
|
2469
2469
|
if (Array.isArray(t)) {
|
|
@@ -2524,9 +2524,9 @@ function jc(t, e) {
|
|
|
2524
2524
|
return (n) => O(t, e, n);
|
|
2525
2525
|
}
|
|
2526
2526
|
function ai(t) {
|
|
2527
|
-
return typeof t == "number" ? jc : typeof t == "string" ? zn(t) ? Oe : H.test(t) ? rs : Ic : Array.isArray(t) ?
|
|
2527
|
+
return typeof t == "number" ? jc : typeof t == "string" ? zn(t) ? Oe : H.test(t) ? rs : Ic : Array.isArray(t) ? io : typeof t == "object" ? H.test(t) ? rs : _c : Oe;
|
|
2528
2528
|
}
|
|
2529
|
-
function
|
|
2529
|
+
function io(t, e) {
|
|
2530
2530
|
const n = [...t], i = n.length, s = t.map((o, r) => ai(o)(o, e[r]));
|
|
2531
2531
|
return (o) => {
|
|
2532
2532
|
for (let r = 0; r < i; r++)
|
|
@@ -2555,13 +2555,13 @@ function Bc(t, e) {
|
|
|
2555
2555
|
}
|
|
2556
2556
|
const Ic = (t, e) => {
|
|
2557
2557
|
const n = Tt.createTransformer(e), i = le(t), s = le(e);
|
|
2558
|
-
return i.indexes.var.length === s.indexes.var.length && i.indexes.color.length === s.indexes.color.length && i.indexes.number.length >= s.indexes.number.length ? En.has(t) && !s.values.length || En.has(e) && !i.values.length ? Oc(t, e) : ft(
|
|
2558
|
+
return i.indexes.var.length === s.indexes.var.length && i.indexes.color.length === s.indexes.color.length && i.indexes.number.length >= s.indexes.number.length ? En.has(t) && !s.values.length || En.has(e) && !i.values.length ? Oc(t, e) : ft(io(Bc(i, s), s.values), n) : (Gt(!0, `Complex values '${t}' and '${e}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`), Oe(t, e));
|
|
2559
2559
|
};
|
|
2560
|
-
function
|
|
2560
|
+
function so(t, e, n) {
|
|
2561
2561
|
return typeof t == "number" && typeof e == "number" && typeof n == "number" ? O(t, e, n) : ai(t)(t, e);
|
|
2562
2562
|
}
|
|
2563
2563
|
function Nc(t, e, n) {
|
|
2564
|
-
const i = [], s = n ||
|
|
2564
|
+
const i = [], s = n || so, o = t.length - 1;
|
|
2565
2565
|
for (let r = 0; r < o; r++) {
|
|
2566
2566
|
let a = s(t[r], t[r + 1]);
|
|
2567
2567
|
if (e) {
|
|
@@ -2604,7 +2604,7 @@ function Kc(t, e) {
|
|
|
2604
2604
|
return t.map((n) => n * e);
|
|
2605
2605
|
}
|
|
2606
2606
|
function Gc(t, e) {
|
|
2607
|
-
return t.map(() => e ||
|
|
2607
|
+
return t.map(() => e || Jr).splice(0, t.length - 1);
|
|
2608
2608
|
}
|
|
2609
2609
|
function je({ duration: t = 300, keyframes: e, times: n, ease: i = "easeInOut" }) {
|
|
2610
2610
|
const s = Rc(i) ? i.map(is) : is(i), o = {
|
|
@@ -2648,9 +2648,9 @@ const zc = (t) => {
|
|
|
2648
2648
|
inertia: es,
|
|
2649
2649
|
tween: je,
|
|
2650
2650
|
keyframes: je,
|
|
2651
|
-
spring:
|
|
2651
|
+
spring: qr
|
|
2652
2652
|
}, Xc = (t) => t / 100;
|
|
2653
|
-
class li extends
|
|
2653
|
+
class li extends zr {
|
|
2654
2654
|
constructor({ KeyframeResolver: e = ni, ...n }) {
|
|
2655
2655
|
super(n), this.holdTime = null, this.startTime = null, this.cancelTime = null, this.currentTime = 0, this.playbackSpeed = 1, this.pendingPlayState = "running", this.state = "idle", this.stop = () => {
|
|
2656
2656
|
if (this.resolver.cancel(), this.isStopped = !0, this.state === "idle")
|
|
@@ -2665,7 +2665,7 @@ class li extends Yr {
|
|
|
2665
2665
|
initPlayback(e) {
|
|
2666
2666
|
const { type: n = "keyframes", repeat: i = 0, repeatDelay: s = 0, repeatType: o, velocity: r = 0 } = this.options, a = Yc[n] || je;
|
|
2667
2667
|
let l, c;
|
|
2668
|
-
a !== je && typeof e[0] != "number" && (process.env.NODE_ENV !== "production" && pt(e.length === 2, `Only two keyframes currently supported with spring and inertia animations. Trying to animate ${e}`), l = ft(Xc,
|
|
2668
|
+
a !== je && typeof e[0] != "number" && (process.env.NODE_ENV !== "production" && pt(e.length === 2, `Only two keyframes currently supported with spring and inertia animations. Trying to animate ${e}`), l = ft(Xc, so(e[0], e[1])), e = [0, 100]);
|
|
2669
2669
|
const u = a({ ...this.options, keyframes: e });
|
|
2670
2670
|
o === "mirror" && (c = a({
|
|
2671
2671
|
...this.options,
|
|
@@ -2770,9 +2770,9 @@ class li extends Yr {
|
|
|
2770
2770
|
return this.startTime = 0, this.tick(e, !0);
|
|
2771
2771
|
}
|
|
2772
2772
|
}
|
|
2773
|
-
const
|
|
2774
|
-
function
|
|
2775
|
-
return !!(!t || typeof t == "string" && t in ci ||
|
|
2773
|
+
const ro = (t) => Array.isArray(t) && typeof t[0] == "number";
|
|
2774
|
+
function oo(t) {
|
|
2775
|
+
return !!(!t || typeof t == "string" && t in ci || ro(t) || Array.isArray(t) && t.every(oo));
|
|
2776
2776
|
}
|
|
2777
2777
|
const Qt = ([t, e, n, i]) => `cubic-bezier(${t}, ${e}, ${n}, ${i})`, ci = {
|
|
2778
2778
|
linear: "linear",
|
|
@@ -2786,16 +2786,16 @@ const Qt = ([t, e, n, i]) => `cubic-bezier(${t}, ${e}, ${n}, ${i})`, ci = {
|
|
|
2786
2786
|
backOut: Qt([0.33, 1.53, 0.69, 0.99])
|
|
2787
2787
|
};
|
|
2788
2788
|
function qc(t) {
|
|
2789
|
-
return
|
|
2789
|
+
return ao(t) || ci.easeOut;
|
|
2790
2790
|
}
|
|
2791
|
-
function
|
|
2791
|
+
function ao(t) {
|
|
2792
2792
|
if (t)
|
|
2793
|
-
return
|
|
2793
|
+
return ro(t) ? Qt(t) : Array.isArray(t) ? t.map(qc) : ci[t];
|
|
2794
2794
|
}
|
|
2795
2795
|
function Zc(t, e, n, { delay: i = 0, duration: s = 300, repeat: o = 0, repeatType: r = "loop", ease: a, times: l } = {}) {
|
|
2796
2796
|
const c = { [e]: n };
|
|
2797
2797
|
l && (c.offset = l);
|
|
2798
|
-
const u =
|
|
2798
|
+
const u = ao(a);
|
|
2799
2799
|
return Array.isArray(u) && (c.easing = u), t.animate(c, {
|
|
2800
2800
|
delay: i,
|
|
2801
2801
|
duration: s,
|
|
@@ -2805,9 +2805,9 @@ function Zc(t, e, n, { delay: i = 0, duration: s = 300, repeat: o = 0, repeatTyp
|
|
|
2805
2805
|
direction: r === "reverse" ? "alternate" : "normal"
|
|
2806
2806
|
});
|
|
2807
2807
|
}
|
|
2808
|
-
const Jc =
|
|
2808
|
+
const Jc = Hr(() => Object.hasOwnProperty.call(Element.prototype, "animate")), _e = 10, Qc = 2e4;
|
|
2809
2809
|
function tu(t) {
|
|
2810
|
-
return t.type === "spring" || !
|
|
2810
|
+
return t.type === "spring" || !oo(t.ease);
|
|
2811
2811
|
}
|
|
2812
2812
|
function eu(t, e) {
|
|
2813
2813
|
const n = new li({
|
|
@@ -2829,11 +2829,11 @@ function eu(t, e) {
|
|
|
2829
2829
|
ease: "linear"
|
|
2830
2830
|
};
|
|
2831
2831
|
}
|
|
2832
|
-
class as extends
|
|
2832
|
+
class as extends zr {
|
|
2833
2833
|
constructor(e) {
|
|
2834
2834
|
super(e);
|
|
2835
2835
|
const { name: n, motionValue: i, keyframes: s } = this.options;
|
|
2836
|
-
this.resolver = new
|
|
2836
|
+
this.resolver = new Gr(s, (o, r) => this.onKeyframesResolved(o, r), n, i), this.resolver.scheduleResolve();
|
|
2837
2837
|
}
|
|
2838
2838
|
initPlayback(e, n) {
|
|
2839
2839
|
var i;
|
|
@@ -2966,7 +2966,7 @@ class as extends Yr {
|
|
|
2966
2966
|
}
|
|
2967
2967
|
static supports(e) {
|
|
2968
2968
|
const { motionValue: n, name: i, repeatDelay: s, repeatType: o, damping: r, type: a } = e;
|
|
2969
|
-
return Jc() && i &&
|
|
2969
|
+
return Jc() && i && wr.has(i) && n && n.owner && n.owner.current instanceof HTMLElement && /**
|
|
2970
2970
|
* If we're outputting values to onUpdate then we can't use WAAPI as there's
|
|
2971
2971
|
* no way to read the value from WAAPI every frame.
|
|
2972
2972
|
*/
|
|
@@ -2981,7 +2981,7 @@ function nu(t, e) {
|
|
|
2981
2981
|
};
|
|
2982
2982
|
return M.update(i, !0), () => mt(i);
|
|
2983
2983
|
}
|
|
2984
|
-
const iu =
|
|
2984
|
+
const iu = Hr(() => window.ScrollTimeline !== void 0);
|
|
2985
2985
|
class su {
|
|
2986
2986
|
constructor(e) {
|
|
2987
2987
|
this.stop = () => this.runAll("stop"), this.animations = e.filter(Boolean);
|
|
@@ -3113,7 +3113,7 @@ function hi(t, e, n) {
|
|
|
3113
3113
|
t || ls.has(e) || (console.warn(e), n && console.warn(n), ls.add(e));
|
|
3114
3114
|
}
|
|
3115
3115
|
const cs = 30, ru = (t) => !isNaN(parseFloat(t));
|
|
3116
|
-
class
|
|
3116
|
+
class lo {
|
|
3117
3117
|
/**
|
|
3118
3118
|
* @param init - The initiating value
|
|
3119
3119
|
* @param config - Optional configuration options
|
|
@@ -3254,7 +3254,7 @@ class co {
|
|
|
3254
3254
|
if (!this.canTrackVelocity || this.prevFrameValue === void 0 || e - this.updatedAt > cs)
|
|
3255
3255
|
return 0;
|
|
3256
3256
|
const n = Math.min(this.updatedAt - this.prevUpdatedAt, cs);
|
|
3257
|
-
return
|
|
3257
|
+
return Yr(parseFloat(this.current) - parseFloat(this.prevFrameValue), n);
|
|
3258
3258
|
}
|
|
3259
3259
|
/**
|
|
3260
3260
|
* Registers a new animation to control this `MotionValue`. Only one
|
|
@@ -3308,7 +3308,7 @@ class co {
|
|
|
3308
3308
|
}
|
|
3309
3309
|
}
|
|
3310
3310
|
function ue(t, e) {
|
|
3311
|
-
return new
|
|
3311
|
+
return new lo(t, e);
|
|
3312
3312
|
}
|
|
3313
3313
|
function ou(t, e, n) {
|
|
3314
3314
|
t.hasValue(e) ? t.getValue(e).set(n) : t.addValue(e, ue(n));
|
|
@@ -3322,15 +3322,15 @@ function au(t, e) {
|
|
|
3322
3322
|
ou(t, r, a);
|
|
3323
3323
|
}
|
|
3324
3324
|
}
|
|
3325
|
-
function
|
|
3326
|
-
return t.getProps()[
|
|
3325
|
+
function co(t) {
|
|
3326
|
+
return t.getProps()[ar];
|
|
3327
3327
|
}
|
|
3328
|
-
class lu extends
|
|
3328
|
+
class lu extends lo {
|
|
3329
3329
|
constructor() {
|
|
3330
3330
|
super(...arguments), this.output = [], this.counts = /* @__PURE__ */ new Map();
|
|
3331
3331
|
}
|
|
3332
3332
|
add(e) {
|
|
3333
|
-
const n =
|
|
3333
|
+
const n = Sr(e);
|
|
3334
3334
|
if (!n)
|
|
3335
3335
|
return;
|
|
3336
3336
|
const i = this.counts.get(n) || 0;
|
|
@@ -3363,7 +3363,7 @@ function uu({ protectedKeys: t, needsAnimating: e }, n) {
|
|
|
3363
3363
|
const i = t.hasOwnProperty(n) && e[n] !== !0;
|
|
3364
3364
|
return e[n] = !1, i;
|
|
3365
3365
|
}
|
|
3366
|
-
function
|
|
3366
|
+
function uo(t, e, { delay: n = 0, transitionOverride: i, type: s } = {}) {
|
|
3367
3367
|
var o;
|
|
3368
3368
|
let { transition: r = t.getDefaultTransition(), transitionEnd: a, ...l } = e;
|
|
3369
3369
|
i && (r = i);
|
|
@@ -3379,7 +3379,7 @@ function fo(t, e, { delay: n = 0, transitionOverride: i, type: s } = {}) {
|
|
|
3379
3379
|
};
|
|
3380
3380
|
let P = !1;
|
|
3381
3381
|
if (window.HandoffAppearAnimations) {
|
|
3382
|
-
const x =
|
|
3382
|
+
const x = co(t);
|
|
3383
3383
|
if (x) {
|
|
3384
3384
|
const y = window.HandoffAppearAnimations(x, f, d, M);
|
|
3385
3385
|
y !== null && (m.elapsed = y, P = !0);
|
|
@@ -3400,7 +3400,7 @@ function Vn(t, e, n = {}) {
|
|
|
3400
3400
|
const s = He(t, e, n.type === "exit" ? (i = t.presenceContext) === null || i === void 0 ? void 0 : i.custom : void 0);
|
|
3401
3401
|
let { transition: o = t.getDefaultTransition() || {} } = s || {};
|
|
3402
3402
|
n.transitionOverride && (o = n.transitionOverride);
|
|
3403
|
-
const r = s ? () => Promise.all(
|
|
3403
|
+
const r = s ? () => Promise.all(uo(t, s, n)) : () => Promise.resolve(), a = t.variantChildren && t.variantChildren.size ? (c = 0) => {
|
|
3404
3404
|
const { delayChildren: u = 0, staggerChildren: f, staggerDirection: d } = o;
|
|
3405
3405
|
return fu(t, e, u + c, f, d, n);
|
|
3406
3406
|
} : () => Promise.resolve(), { when: l } = o;
|
|
@@ -3432,7 +3432,7 @@ function du(t, e, n = {}) {
|
|
|
3432
3432
|
i = Vn(t, e, n);
|
|
3433
3433
|
else {
|
|
3434
3434
|
const s = typeof e == "function" ? He(t, e, n.custom) : e;
|
|
3435
|
-
i = Promise.all(
|
|
3435
|
+
i = Promise.all(uo(t, s, n));
|
|
3436
3436
|
}
|
|
3437
3437
|
return i.then(() => {
|
|
3438
3438
|
t.notify("AnimationComplete", e);
|
|
@@ -3487,7 +3487,7 @@ function yu(t) {
|
|
|
3487
3487
|
if (p.hasOwnProperty(_))
|
|
3488
3488
|
continue;
|
|
3489
3489
|
let Ft = !1;
|
|
3490
|
-
xn(Q) && xn(Lt) ? Ft = !
|
|
3490
|
+
xn(Q) && xn(Lt) ? Ft = !Mr(Q, Lt) : Ft = Q !== Lt, Ft ? Q != null ? st(_) : d.add(_) : Q !== void 0 && d.has(_) ? st(_) : y.protectedKeys[_] = !0;
|
|
3491
3491
|
}
|
|
3492
3492
|
y.prevProp = v, y.prevResolvedValues = j, y.isActive && (p = { ...p, ...j }), i && t.blockInitialAnimation && (E = !1), E && (!L || U) && f.push(...G.map((_) => ({
|
|
3493
3493
|
animation: _,
|
|
@@ -3528,7 +3528,7 @@ function yu(t) {
|
|
|
3528
3528
|
};
|
|
3529
3529
|
}
|
|
3530
3530
|
function vu(t, e) {
|
|
3531
|
-
return typeof e == "string" ? e !== t : Array.isArray(e) ? !
|
|
3531
|
+
return typeof e == "string" ? e !== t : Array.isArray(e) ? !Mr(e, t) : !1;
|
|
3532
3532
|
}
|
|
3533
3533
|
function Ct(t = !1) {
|
|
3534
3534
|
return {
|
|
@@ -3610,7 +3610,7 @@ function wu(t, e) {
|
|
|
3610
3610
|
const n = fs(t.x, e.x), i = fs(t.y, e.y);
|
|
3611
3611
|
return Math.sqrt(n ** 2 + i ** 2);
|
|
3612
3612
|
}
|
|
3613
|
-
class
|
|
3613
|
+
class fo {
|
|
3614
3614
|
constructor(e, n, { transformPagePoint: i, contextWindow: s, dragSnapToOrigin: o = !1 } = {}) {
|
|
3615
3615
|
if (this.startEvent = null, this.lastMoveEvent = null, this.lastMoveEventInfo = null, this.handlers = {}, this.contextWindow = window, this.updatePoint = () => {
|
|
3616
3616
|
if (!(this.lastMoveEvent && this.lastMoveEventInfo))
|
|
@@ -3631,7 +3631,7 @@ class ho {
|
|
|
3631
3631
|
return;
|
|
3632
3632
|
const b = hn(f.type === "pointercancel" ? this.lastMoveEventInfo : fn(d, this.transformPagePoint), this.history);
|
|
3633
3633
|
this.startEvent && p && p(f, b), m && m(f, b);
|
|
3634
|
-
}, !
|
|
3634
|
+
}, !Ar(e))
|
|
3635
3635
|
return;
|
|
3636
3636
|
this.dragSnapToOrigin = o, this.handlers = n, this.transformPagePoint = i, this.contextWindow = s || window;
|
|
3637
3637
|
const r = Ge(e), a = fn(r, this.transformPagePoint), { point: l } = a, { timestamp: c } = W;
|
|
@@ -3655,7 +3655,7 @@ function hs(t, e) {
|
|
|
3655
3655
|
function hn({ point: t }, e) {
|
|
3656
3656
|
return {
|
|
3657
3657
|
point: t,
|
|
3658
|
-
delta: hs(t,
|
|
3658
|
+
delta: hs(t, ho(e)),
|
|
3659
3659
|
offset: hs(t, Su(e)),
|
|
3660
3660
|
velocity: Cu(e, 0.1)
|
|
3661
3661
|
};
|
|
@@ -3663,14 +3663,14 @@ function hn({ point: t }, e) {
|
|
|
3663
3663
|
function Su(t) {
|
|
3664
3664
|
return t[0];
|
|
3665
3665
|
}
|
|
3666
|
-
function
|
|
3666
|
+
function ho(t) {
|
|
3667
3667
|
return t[t.length - 1];
|
|
3668
3668
|
}
|
|
3669
3669
|
function Cu(t, e) {
|
|
3670
3670
|
if (t.length < 2)
|
|
3671
3671
|
return { x: 0, y: 0 };
|
|
3672
3672
|
let n = t.length - 1, i = null;
|
|
3673
|
-
const s =
|
|
3673
|
+
const s = ho(t);
|
|
3674
3674
|
for (; n >= 0 && (i = t[n], !(s.timestamp - i.timestamp > ht(e))); )
|
|
3675
3675
|
n--;
|
|
3676
3676
|
if (!i)
|
|
@@ -3684,7 +3684,7 @@ function Cu(t, e) {
|
|
|
3684
3684
|
};
|
|
3685
3685
|
return r.x === 1 / 0 && (r.x = 0), r.y === 1 / 0 && (r.y = 0), r;
|
|
3686
3686
|
}
|
|
3687
|
-
const
|
|
3687
|
+
const po = 1e-4, Au = 1 - po, Eu = 1 + po, mo = 0.01, Ru = 0 - mo, Vu = 0 + mo;
|
|
3688
3688
|
function J(t) {
|
|
3689
3689
|
return t.max - t.min;
|
|
3690
3690
|
}
|
|
@@ -3774,7 +3774,7 @@ const xs = () => ({
|
|
|
3774
3774
|
function nt(t) {
|
|
3775
3775
|
return [t("x"), t("y")];
|
|
3776
3776
|
}
|
|
3777
|
-
function
|
|
3777
|
+
function go({ top: t, left: e, right: n, bottom: i }) {
|
|
3778
3778
|
return {
|
|
3779
3779
|
x: { min: e, max: n },
|
|
3780
3780
|
y: { min: t, max: i }
|
|
@@ -3801,9 +3801,9 @@ function Mn({ scale: t, scaleX: e, scaleY: n }) {
|
|
|
3801
3801
|
return !dn(t) || !dn(e) || !dn(n);
|
|
3802
3802
|
}
|
|
3803
3803
|
function Et(t) {
|
|
3804
|
-
return Mn(t) ||
|
|
3804
|
+
return Mn(t) || yo(t) || t.z || t.rotate || t.rotateX || t.rotateY || t.skewX || t.skewY;
|
|
3805
3805
|
}
|
|
3806
|
-
function
|
|
3806
|
+
function yo(t) {
|
|
3807
3807
|
return bs(t.x) || bs(t.y);
|
|
3808
3808
|
}
|
|
3809
3809
|
function bs(t) {
|
|
@@ -3819,7 +3819,7 @@ function ws(t, e, n, i, s) {
|
|
|
3819
3819
|
function kn(t, e = 0, n = 1, i, s) {
|
|
3820
3820
|
t.min = ws(t.min, e, n, i, s), t.max = ws(t.max, e, n, i, s);
|
|
3821
3821
|
}
|
|
3822
|
-
function
|
|
3822
|
+
function vo(t, { x: e, y: n }) {
|
|
3823
3823
|
kn(t.x, e.translate, e.scale, e.originPoint), kn(t.y, n.translate, n.scale, n.originPoint);
|
|
3824
3824
|
}
|
|
3825
3825
|
const Ss = 0.999999999999, Cs = 1.0000000000001;
|
|
@@ -3835,7 +3835,7 @@ function Nu(t, e, n, i = !1) {
|
|
|
3835
3835
|
l && l.props.style && l.props.style.display === "contents" || (i && o.options.layoutScroll && o.scroll && o !== o.root && Wt(t, {
|
|
3836
3836
|
x: -o.scroll.offset.x,
|
|
3837
3837
|
y: -o.scroll.offset.y
|
|
3838
|
-
}), r && (e.x *= r.x.scale, e.y *= r.y.scale,
|
|
3838
|
+
}), r && (e.x *= r.x.scale, e.y *= r.y.scale, vo(t, r)), i && Et(o.latestValues) && Wt(t, o.latestValues));
|
|
3839
3839
|
}
|
|
3840
3840
|
e.x < Cs && e.x > Ss && (e.x = 1), e.y < Cs && e.y > Ss && (e.y = 1);
|
|
3841
3841
|
}
|
|
@@ -3849,14 +3849,14 @@ function As(t, e, n, i, s = 0.5) {
|
|
|
3849
3849
|
function Wt(t, e) {
|
|
3850
3850
|
As(t.x, e.x, e.scaleX, e.scale, e.originX), As(t.y, e.y, e.scaleY, e.scale, e.originY);
|
|
3851
3851
|
}
|
|
3852
|
-
function
|
|
3853
|
-
return
|
|
3852
|
+
function Po(t, e) {
|
|
3853
|
+
return go(Iu(t.getBoundingClientRect(), e));
|
|
3854
3854
|
}
|
|
3855
3855
|
function Uu(t, e, n) {
|
|
3856
|
-
const i =
|
|
3856
|
+
const i = Po(t, n), { scroll: s } = e;
|
|
3857
3857
|
return s && (Ut(i.x, s.offset.x), Ut(i.y, s.offset.y)), i;
|
|
3858
3858
|
}
|
|
3859
|
-
const
|
|
3859
|
+
const xo = ({ current: t }) => t ? t.ownerDocument.defaultView : null, Wu = /* @__PURE__ */ new WeakMap();
|
|
3860
3860
|
class $u {
|
|
3861
3861
|
constructor(e) {
|
|
3862
3862
|
this.openGlobalLock = null, this.isDragging = !1, this.currentDirection = null, this.originPoint = { x: 0, y: 0 }, this.constraints = !1, this.hasMutatedConstraints = !1, this.elastic = I(), this.visualElement = e;
|
|
@@ -3871,11 +3871,11 @@ class $u {
|
|
|
3871
3871
|
}, o = (u, f) => {
|
|
3872
3872
|
var d;
|
|
3873
3873
|
const { drag: p, dragPropagation: m, onDragStart: P } = this.getProps();
|
|
3874
|
-
if (p && !m && (this.openGlobalLock && this.openGlobalLock(), this.openGlobalLock =
|
|
3874
|
+
if (p && !m && (this.openGlobalLock && this.openGlobalLock(), this.openGlobalLock = Rr(p), !this.openGlobalLock))
|
|
3875
3875
|
return;
|
|
3876
3876
|
this.isDragging = !0, this.currentDirection = null, this.resolveConstraints(), this.visualElement.projection && (this.visualElement.projection.isAnimationBlocked = !0, this.visualElement.projection.target = void 0), nt((x) => {
|
|
3877
3877
|
let y = this.getAxisMotionValue(x).get() || 0;
|
|
3878
|
-
if (
|
|
3878
|
+
if (at.test(y)) {
|
|
3879
3879
|
const { projection: v } = this.visualElement;
|
|
3880
3880
|
if (v && v.layout) {
|
|
3881
3881
|
const w = v.layout.layoutBox[x];
|
|
@@ -3900,7 +3900,7 @@ class $u {
|
|
|
3900
3900
|
var f;
|
|
3901
3901
|
return this.getAnimationState(u) === "paused" && ((f = this.getAxisMotionValue(u).animation) === null || f === void 0 ? void 0 : f.play());
|
|
3902
3902
|
}), { dragSnapToOrigin: c } = this.getProps();
|
|
3903
|
-
this.panSession = new
|
|
3903
|
+
this.panSession = new fo(e, {
|
|
3904
3904
|
onSessionStart: s,
|
|
3905
3905
|
onStart: o,
|
|
3906
3906
|
onMove: r,
|
|
@@ -3909,7 +3909,7 @@ class $u {
|
|
|
3909
3909
|
}, {
|
|
3910
3910
|
transformPagePoint: this.visualElement.getTransformPagePoint(),
|
|
3911
3911
|
dragSnapToOrigin: c,
|
|
3912
|
-
contextWindow:
|
|
3912
|
+
contextWindow: xo(this.visualElement)
|
|
3913
3913
|
});
|
|
3914
3914
|
}
|
|
3915
3915
|
stop(e, n) {
|
|
@@ -3958,7 +3958,7 @@ class $u {
|
|
|
3958
3958
|
let r = Fu(s.layout.layoutBox, o);
|
|
3959
3959
|
if (n) {
|
|
3960
3960
|
const a = n(Bu(r));
|
|
3961
|
-
this.hasMutatedConstraints = !!a, a && (r =
|
|
3961
|
+
this.hasMutatedConstraints = !!a, a && (r = go(a));
|
|
3962
3962
|
}
|
|
3963
3963
|
return r;
|
|
3964
3964
|
}
|
|
@@ -4062,7 +4062,7 @@ class $u {
|
|
|
4062
4062
|
Bt(l) && l.current && (this.constraints = this.resolveRefConstraints());
|
|
4063
4063
|
}, { projection: s } = this.visualElement, o = s.addEventListener("measure", i);
|
|
4064
4064
|
s && !s.layout && (s.root && s.root.updateScroll(), s.updateLayout()), M.read(i);
|
|
4065
|
-
const r =
|
|
4065
|
+
const r = ct(window, "resize", () => this.scalePositionWithinConstraints()), a = s.addEventListener("didUpdate", ({ delta: l, hasLayoutChanged: c }) => {
|
|
4066
4066
|
this.isDragging && c && (nt((u) => {
|
|
4067
4067
|
const f = this.getAxisMotionValue(u);
|
|
4068
4068
|
f && (this.originPoint[u] += l[u].translate, f.set(f.get() + l[u].translate));
|
|
@@ -4112,9 +4112,9 @@ class Hu extends wt {
|
|
|
4112
4112
|
super(...arguments), this.removePointerDownListener = K;
|
|
4113
4113
|
}
|
|
4114
4114
|
onPointerDown(e) {
|
|
4115
|
-
this.session = new
|
|
4115
|
+
this.session = new fo(e, this.createPanHandlers(), {
|
|
4116
4116
|
transformPagePoint: this.node.getTransformPagePoint(),
|
|
4117
|
-
contextWindow:
|
|
4117
|
+
contextWindow: xo(this.node)
|
|
4118
4118
|
});
|
|
4119
4119
|
}
|
|
4120
4120
|
createPanHandlers() {
|
|
@@ -4143,7 +4143,7 @@ function zu() {
|
|
|
4143
4143
|
if (t === null)
|
|
4144
4144
|
return [!0, null];
|
|
4145
4145
|
const { isPresent: e, onExitComplete: n, register: i } = t, s = jn();
|
|
4146
|
-
|
|
4146
|
+
ot(() => i(s), []);
|
|
4147
4147
|
const o = rt(() => n && n(s), [s, n]);
|
|
4148
4148
|
return !e && n ? [!1, o] : [!0];
|
|
4149
4149
|
}
|
|
@@ -4225,9 +4225,9 @@ class Xu extends la {
|
|
|
4225
4225
|
return null;
|
|
4226
4226
|
}
|
|
4227
4227
|
}
|
|
4228
|
-
function
|
|
4228
|
+
function To(t) {
|
|
4229
4229
|
const [e, n] = zu(), i = $($n);
|
|
4230
|
-
return F.jsx(Xu, { ...t, layoutGroup: i, switchLayoutGroup: $(
|
|
4230
|
+
return F.jsx(Xu, { ...t, layoutGroup: i, switchLayoutGroup: $(cr), isPresent: e, safeToRemove: n });
|
|
4231
4231
|
}
|
|
4232
4232
|
const qu = {
|
|
4233
4233
|
borderRadius: {
|
|
@@ -4244,7 +4244,7 @@ const qu = {
|
|
|
4244
4244
|
borderBottomLeftRadius: Zt,
|
|
4245
4245
|
borderBottomRightRadius: Zt,
|
|
4246
4246
|
boxShadow: Yu
|
|
4247
|
-
},
|
|
4247
|
+
}, bo = ["TopLeft", "TopRight", "BottomLeft", "BottomRight"], Zu = bo.length, Vs = (t) => typeof t == "string" ? parseFloat(t) : t, Ds = (t) => typeof t == "number" || S.test(t);
|
|
4248
4248
|
function Ju(t, e, n, i, s, o) {
|
|
4249
4249
|
s ? (t.opacity = O(
|
|
4250
4250
|
0,
|
|
@@ -4253,19 +4253,19 @@ function Ju(t, e, n, i, s, o) {
|
|
|
4253
4253
|
Qu(i)
|
|
4254
4254
|
), t.opacityExit = O(e.opacity !== void 0 ? e.opacity : 1, 0, tf(i))) : o && (t.opacity = O(e.opacity !== void 0 ? e.opacity : 1, n.opacity !== void 0 ? n.opacity : 1, i));
|
|
4255
4255
|
for (let r = 0; r < Zu; r++) {
|
|
4256
|
-
const a = `border${
|
|
4256
|
+
const a = `border${bo[r]}Radius`;
|
|
4257
4257
|
let l = Ms(e, a), c = Ms(n, a);
|
|
4258
4258
|
if (l === void 0 && c === void 0)
|
|
4259
4259
|
continue;
|
|
4260
|
-
l || (l = 0), c || (c = 0), l === 0 || c === 0 || Ds(l) === Ds(c) ? (t[a] = Math.max(O(Vs(l), Vs(c), i), 0), (
|
|
4260
|
+
l || (l = 0), c || (c = 0), l === 0 || c === 0 || Ds(l) === Ds(c) ? (t[a] = Math.max(O(Vs(l), Vs(c), i), 0), (at.test(c) || at.test(l)) && (t[a] += "%")) : t[a] = c;
|
|
4261
4261
|
}
|
|
4262
4262
|
(e.rotate || n.rotate) && (t.rotate = O(e.rotate || 0, n.rotate || 0, i));
|
|
4263
4263
|
}
|
|
4264
4264
|
function Ms(t, e) {
|
|
4265
4265
|
return t[e] !== void 0 ? t[e] : t.borderRadius;
|
|
4266
4266
|
}
|
|
4267
|
-
const Qu =
|
|
4268
|
-
function
|
|
4267
|
+
const Qu = wo(0, 0.5, eo), tf = wo(0.5, 0.95, K);
|
|
4268
|
+
function wo(t, e, n) {
|
|
4269
4269
|
return (i) => i < t ? 0 : i > e ? 1 : n(ce(t, e, i));
|
|
4270
4270
|
}
|
|
4271
4271
|
function ks(t, e) {
|
|
@@ -4281,7 +4281,7 @@ function Fs(t, e, n, i, s) {
|
|
|
4281
4281
|
return t -= e, t = Be(t, 1 / n, i), s !== void 0 && (t = Be(t, 1 / s, i)), t;
|
|
4282
4282
|
}
|
|
4283
4283
|
function ef(t, e = 0, n = 1, i = 0.5, s, o = t, r = t) {
|
|
4284
|
-
if (
|
|
4284
|
+
if (at.test(e) && (e = parseFloat(e), e = O(r.min, r.max, e / 100) - r.min), typeof e != "number")
|
|
4285
4285
|
return;
|
|
4286
4286
|
let a = O(o.min, o.max, i);
|
|
4287
4287
|
t === o && (a -= e), t.min = Fs(t.min, e, n, a, s), t.max = Fs(t.max, e, n, a, s);
|
|
@@ -4296,7 +4296,7 @@ function js(t, e, n, i) {
|
|
|
4296
4296
|
function _s(t) {
|
|
4297
4297
|
return t.translate === 0 && t.scale === 1;
|
|
4298
4298
|
}
|
|
4299
|
-
function
|
|
4299
|
+
function So(t) {
|
|
4300
4300
|
return _s(t.x) && _s(t.y);
|
|
4301
4301
|
}
|
|
4302
4302
|
function Bs(t, e) {
|
|
@@ -4308,7 +4308,7 @@ function rf(t, e) {
|
|
|
4308
4308
|
function Is(t, e) {
|
|
4309
4309
|
return Math.round(t.min) === Math.round(e.min) && Math.round(t.max) === Math.round(e.max);
|
|
4310
4310
|
}
|
|
4311
|
-
function
|
|
4311
|
+
function Co(t, e) {
|
|
4312
4312
|
return Is(t.x, e.x) && Is(t.y, e.y);
|
|
4313
4313
|
}
|
|
4314
4314
|
function Ns(t) {
|
|
@@ -4421,13 +4421,13 @@ function mn(t, e, n, i) {
|
|
|
4421
4421
|
const { latestValues: s } = e;
|
|
4422
4422
|
s[t] && (n[t] = s[t], e.setStaticValue(t, 0), i && (i[t] = 0));
|
|
4423
4423
|
}
|
|
4424
|
-
function
|
|
4424
|
+
function Ao(t) {
|
|
4425
4425
|
if (t.hasCheckedOptimisedAppear = !0, t.root === t)
|
|
4426
4426
|
return !1;
|
|
4427
4427
|
const { visualElement: e } = t.options;
|
|
4428
|
-
return e ?
|
|
4428
|
+
return e ? co(e) ? !0 : t.parent && !t.parent.hasCheckedOptimisedAppear ? Ao(t.parent) : !1 : !1;
|
|
4429
4429
|
}
|
|
4430
|
-
function
|
|
4430
|
+
function Eo({ attachResizeListener: t, defaultParent: e, measureScroll: n, checkIsScrollRoot: i, resetTransform: s }) {
|
|
4431
4431
|
return class {
|
|
4432
4432
|
constructor(r = {}, a = e == null ? void 0 : e()) {
|
|
4433
4433
|
this.id = pf++, this.animationId = 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.updateScheduled = !1, this.scheduleUpdate = () => this.update(), this.projectionUpdateScheduled = !1, this.checkUpdateFailed = () => {
|
|
@@ -4469,7 +4469,7 @@ function Ro({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
4469
4469
|
this.target = void 0, this.relativeTarget = void 0;
|
|
4470
4470
|
return;
|
|
4471
4471
|
}
|
|
4472
|
-
const P = this.options.transition || u.getDefaultTransition() || Rf, { onLayoutAnimationStart: b, onLayoutAnimationComplete: x } = u.getProps(), y = !this.targetLayout || !
|
|
4472
|
+
const P = this.options.transition || u.getDefaultTransition() || Rf, { onLayoutAnimationStart: b, onLayoutAnimationComplete: x } = u.getProps(), y = !this.targetLayout || !Co(this.targetLayout, m) || p, v = !d && p;
|
|
4473
4473
|
if (this.options.layoutRoot || this.resumeFrom && this.resumeFrom.instance || v || d && (y || !this.currentAnimation)) {
|
|
4474
4474
|
this.resumeFrom && (this.resumingFrom = this.resumeFrom, this.resumingFrom.resumingFrom = void 0), this.setAnimationOrigin(f, v);
|
|
4475
4475
|
const w = {
|
|
@@ -4514,7 +4514,7 @@ function Ro({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
4514
4514
|
this.options.onExitComplete && this.options.onExitComplete();
|
|
4515
4515
|
return;
|
|
4516
4516
|
}
|
|
4517
|
-
if (window.HandoffCancelAllAnimations &&
|
|
4517
|
+
if (window.HandoffCancelAllAnimations && Ao(this) && window.HandoffCancelAllAnimations(), !this.root.isUpdating && this.root.startUpdate(), this.isLayoutDirty)
|
|
4518
4518
|
return;
|
|
4519
4519
|
this.isLayoutDirty = !0;
|
|
4520
4520
|
for (let u = 0; u < this.path.length; u++) {
|
|
@@ -4583,7 +4583,7 @@ function Ro({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
4583
4583
|
resetTransform() {
|
|
4584
4584
|
if (!s)
|
|
4585
4585
|
return;
|
|
4586
|
-
const r = this.isLayoutDirty || this.shouldResetTransform || this.options.alwaysMeasureLayout, a = this.projectionDelta && !
|
|
4586
|
+
const r = this.isLayoutDirty || this.shouldResetTransform || this.options.alwaysMeasureLayout, a = this.projectionDelta && !So(this.projectionDelta), l = this.getTransformTemplate(), c = l ? l(this.latestValues, "") : void 0, u = c !== this.prevTransformTemplateValue;
|
|
4587
4587
|
r && (a || Et(this.latestValues) || u) && (s(this.instance, c), this.shouldResetTransform = !1, this.scheduleRender());
|
|
4588
4588
|
}
|
|
4589
4589
|
measure(r = !0) {
|
|
@@ -4675,7 +4675,7 @@ function Ro({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
4675
4675
|
p && p.layout && this.animationProgress !== 1 ? (this.relativeParent = p, this.forceRelativeParentToResolveTarget(), this.relativeTarget = I(), this.relativeTargetOrigin = I(), se(this.relativeTargetOrigin, this.layout.layoutBox, p.layout.layoutBox), et(this.relativeTarget, this.relativeTargetOrigin)) : this.relativeParent = this.relativeTarget = void 0;
|
|
4676
4676
|
}
|
|
4677
4677
|
if (!(!this.relativeTarget && !this.targetDelta)) {
|
|
4678
|
-
if (this.target || (this.target = I(), this.targetWithTransforms = I()), this.relativeTarget && this.relativeTargetOrigin && this.relativeParent && this.relativeParent.target ? (this.forceRelativeParentToResolveTarget(), Mu(this.target, this.relativeTarget, this.relativeParent.target)) : this.targetDelta ? (this.resumingFrom ? this.target = this.applyTransform(this.layout.layoutBox) : et(this.target, this.layout.layoutBox),
|
|
4678
|
+
if (this.target || (this.target = I(), this.targetWithTransforms = I()), this.relativeTarget && this.relativeTargetOrigin && this.relativeParent && this.relativeParent.target ? (this.forceRelativeParentToResolveTarget(), Mu(this.target, this.relativeTarget, this.relativeParent.target)) : this.targetDelta ? (this.resumingFrom ? this.target = this.applyTransform(this.layout.layoutBox) : et(this.target, this.layout.layoutBox), vo(this.target, this.targetDelta)) : et(this.target, this.layout.layoutBox), this.attemptToResolveRelativeTarget) {
|
|
4679
4679
|
this.attemptToResolveRelativeTarget = !1;
|
|
4680
4680
|
const p = this.getClosestProjectingParent();
|
|
4681
4681
|
p && !!p.resumingFrom == !!this.resumingFrom && !p.options.layoutScroll && p.target && this.animationProgress !== 1 ? (this.relativeParent = p, this.forceRelativeParentToResolveTarget(), this.relativeTarget = I(), this.relativeTargetOrigin = I(), se(this.relativeTargetOrigin, this.target, p.target), et(this.relativeTarget, this.relativeTargetOrigin)) : this.relativeParent = this.relativeTarget = void 0;
|
|
@@ -4685,7 +4685,7 @@ function Ro({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
4685
4685
|
}
|
|
4686
4686
|
}
|
|
4687
4687
|
getClosestProjectingParent() {
|
|
4688
|
-
if (!(!this.parent || Mn(this.parent.latestValues) ||
|
|
4688
|
+
if (!(!this.parent || Mn(this.parent.latestValues) || yo(this.parent.latestValues)))
|
|
4689
4689
|
return this.parent.isProjecting() ? this.parent : this.parent.getClosestProjectingParent();
|
|
4690
4690
|
}
|
|
4691
4691
|
isProjecting() {
|
|
@@ -4763,7 +4763,7 @@ function Ro({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
4763
4763
|
const r = this.getLead();
|
|
4764
4764
|
let { targetWithTransforms: a, target: l, layout: c, latestValues: u } = r;
|
|
4765
4765
|
if (!(!a || !l || !c)) {
|
|
4766
|
-
if (this !== r && this.layout && c &&
|
|
4766
|
+
if (this !== r && this.layout && c && Ro(this.options.animationType, this.layout.layoutBox, c.layoutBox)) {
|
|
4767
4767
|
l = this.target || I();
|
|
4768
4768
|
const f = J(this.layout.layoutBox.x);
|
|
4769
4769
|
l.x.min = r.target.x.min, l.x.max = l.x.min + f;
|
|
@@ -4881,7 +4881,7 @@ function gf(t) {
|
|
|
4881
4881
|
o === "size" ? nt((f) => {
|
|
4882
4882
|
const d = r ? n.measuredBox[f] : n.layoutBox[f], p = J(d);
|
|
4883
4883
|
d.min = i[f].min, d.max = d.min + p;
|
|
4884
|
-
}) :
|
|
4884
|
+
}) : Ro(o, n.layoutBox, i) && nt((f) => {
|
|
4885
4885
|
const d = r ? n.measuredBox[f] : n.layoutBox[f], p = J(i[f]);
|
|
4886
4886
|
d.max = d.min + p, t.relativeTarget && !t.currentAnimation && (t.isProjectionDirty = !0, t.relativeTarget[f].max = t.relativeTarget[f].min + p);
|
|
4887
4887
|
});
|
|
@@ -4889,7 +4889,7 @@ function gf(t) {
|
|
|
4889
4889
|
ie(a, i, n.layoutBox);
|
|
4890
4890
|
const l = Nt();
|
|
4891
4891
|
r ? ie(l, t.applyTransform(s, !0), n.measuredBox) : ie(l, i, n.layoutBox);
|
|
4892
|
-
const c = !
|
|
4892
|
+
const c = !So(a);
|
|
4893
4893
|
let u = !1;
|
|
4894
4894
|
if (!t.resumeFrom) {
|
|
4895
4895
|
const f = t.getClosestProjectingParent();
|
|
@@ -4899,7 +4899,7 @@ function gf(t) {
|
|
|
4899
4899
|
const m = I();
|
|
4900
4900
|
se(m, n.layoutBox, d.layoutBox);
|
|
4901
4901
|
const P = I();
|
|
4902
|
-
se(P, i, p.layoutBox),
|
|
4902
|
+
se(P, i, p.layoutBox), Co(m, P) || (u = !0), f.options.layoutRoot && (t.relativeTarget = P, t.relativeTargetOrigin = m, t.relativeParent = f);
|
|
4903
4903
|
}
|
|
4904
4904
|
}
|
|
4905
4905
|
}
|
|
@@ -4973,15 +4973,15 @@ function Xs(t) {
|
|
|
4973
4973
|
function Vf(t) {
|
|
4974
4974
|
Xs(t.x), Xs(t.y);
|
|
4975
4975
|
}
|
|
4976
|
-
function
|
|
4976
|
+
function Ro(t, e, n) {
|
|
4977
4977
|
return t === "position" || t === "preserve-aspect" && !Du(Ns(e), Ns(n), 0.2);
|
|
4978
4978
|
}
|
|
4979
4979
|
function Df(t) {
|
|
4980
4980
|
var e;
|
|
4981
4981
|
return t !== t.root && ((e = t.scroll) === null || e === void 0 ? void 0 : e.wasRoot);
|
|
4982
4982
|
}
|
|
4983
|
-
const Mf =
|
|
4984
|
-
attachResizeListener: (t, e) =>
|
|
4983
|
+
const Mf = Eo({
|
|
4984
|
+
attachResizeListener: (t, e) => ct(t, "resize", e),
|
|
4985
4985
|
measureScroll: () => ({
|
|
4986
4986
|
x: document.documentElement.scrollLeft || document.body.scrollLeft,
|
|
4987
4987
|
y: document.documentElement.scrollTop || document.body.scrollTop
|
|
@@ -4989,7 +4989,7 @@ const Mf = Ro({
|
|
|
4989
4989
|
checkIsScrollRoot: () => !0
|
|
4990
4990
|
}), gn = {
|
|
4991
4991
|
current: void 0
|
|
4992
|
-
},
|
|
4992
|
+
}, Vo = Eo({
|
|
4993
4993
|
measureScroll: (t) => ({
|
|
4994
4994
|
x: t.scrollLeft,
|
|
4995
4995
|
y: t.scrollTop
|
|
@@ -5011,12 +5011,12 @@ const Mf = Ro({
|
|
|
5011
5011
|
},
|
|
5012
5012
|
drag: {
|
|
5013
5013
|
Feature: Gu,
|
|
5014
|
-
ProjectionNode:
|
|
5015
|
-
MeasureLayout:
|
|
5014
|
+
ProjectionNode: Vo,
|
|
5015
|
+
MeasureLayout: To
|
|
5016
5016
|
}
|
|
5017
|
-
}, Ln = { current: null },
|
|
5017
|
+
}, Ln = { current: null }, Do = { current: !1 };
|
|
5018
5018
|
function Lf() {
|
|
5019
|
-
if (
|
|
5019
|
+
if (Do.current = !0, !!In)
|
|
5020
5020
|
if (window.matchMedia) {
|
|
5021
5021
|
const t = window.matchMedia("(prefers-reduced-motion)"), e = () => Ln.current = t.matches;
|
|
5022
5022
|
t.addListener(e), e();
|
|
@@ -5043,7 +5043,7 @@ function Ff(t, e, n) {
|
|
|
5043
5043
|
e[i] === void 0 && t.removeValue(i);
|
|
5044
5044
|
return e;
|
|
5045
5045
|
}
|
|
5046
|
-
const qs = /* @__PURE__ */ new WeakMap(), Of = [...
|
|
5046
|
+
const qs = /* @__PURE__ */ new WeakMap(), Of = [...jr, H, Tt], jf = (t) => Of.find(Or(t)), Zs = [
|
|
5047
5047
|
"AnimationStart",
|
|
5048
5048
|
"AnimationComplete",
|
|
5049
5049
|
"Update",
|
|
@@ -5070,7 +5070,7 @@ class Bf {
|
|
|
5070
5070
|
this.isRenderScheduled || (this.isRenderScheduled = !0, M.render(this.render, !1, !0));
|
|
5071
5071
|
};
|
|
5072
5072
|
const { latestValues: l, renderState: c } = r;
|
|
5073
|
-
this.latestValues = l, this.baseTarget = { ...l }, this.initialValues = n.initial ? { ...l } : {}, this.renderState = c, this.parent = e, this.props = n, this.presenceContext = i, this.depth = e ? e.depth + 1 : 0, this.reducedMotionConfig = s, this.options = a, this.blockInitialAnimation = !!o, this.isControllingVariants = We(n), this.isVariantNode =
|
|
5073
|
+
this.latestValues = l, this.baseTarget = { ...l }, this.initialValues = n.initial ? { ...l } : {}, this.renderState = c, this.parent = e, this.props = n, this.presenceContext = i, this.depth = e ? e.depth + 1 : 0, this.reducedMotionConfig = s, this.options = a, this.blockInitialAnimation = !!o, this.isControllingVariants = We(n), this.isVariantNode = fr(n), this.isVariantNode && (this.variantChildren = /* @__PURE__ */ new Set()), this.manuallyAnimateOnMount = !!(e && e.current);
|
|
5074
5074
|
const { willChange: u, ...f } = this.scrapeMotionValuesFromProps(n, {}, this);
|
|
5075
5075
|
for (const d in f) {
|
|
5076
5076
|
const p = f[d];
|
|
@@ -5078,7 +5078,7 @@ class Bf {
|
|
|
5078
5078
|
}
|
|
5079
5079
|
}
|
|
5080
5080
|
mount(e) {
|
|
5081
|
-
this.current = e, qs.set(e, this), this.projection && !this.projection.instance && this.projection.mount(e), this.parent && this.isVariantNode && !this.isControllingVariants && (this.removeFromVariantTree = this.parent.addVariantChild(this)), this.values.forEach((n, i) => this.bindToMotionValue(i, n)),
|
|
5081
|
+
this.current = e, qs.set(e, this), this.projection && !this.projection.instance && this.projection.mount(e), this.parent && this.isVariantNode && !this.isControllingVariants && (this.removeFromVariantTree = this.parent.addVariantChild(this)), this.values.forEach((n, i) => this.bindToMotionValue(i, n)), Do.current || Lf(), this.shouldReduceMotion = this.reducedMotionConfig === "never" ? !1 : this.reducedMotionConfig === "always" ? !0 : Ln.current, process.env.NODE_ENV !== "production" && hi(this.shouldReduceMotion !== !0, "You have Reduced Motion enabled on your device. Animations may not appear as expected."), this.parent && this.parent.children.add(this), this.update(this.props, this.presenceContext);
|
|
5082
5082
|
}
|
|
5083
5083
|
unmount() {
|
|
5084
5084
|
qs.delete(this.current), this.projection && this.projection.unmount(), mt(this.notifyUpdate), mt(this.render), this.valueSubscriptions.forEach((e) => e()), this.removeFromVariantTree && this.removeFromVariantTree(), this.parent && this.parent.children.delete(this);
|
|
@@ -5223,7 +5223,7 @@ class Bf {
|
|
|
5223
5223
|
readValue(e, n) {
|
|
5224
5224
|
var i;
|
|
5225
5225
|
let s = this.latestValues[e] !== void 0 || !this.current ? this.latestValues[e] : (i = this.getBaseTargetFromProps(this.props, e)) !== null && i !== void 0 ? i : this.readValueFromInstance(this.current, e, this.options);
|
|
5226
|
-
return s != null && (typeof s == "string" && (
|
|
5226
|
+
return s != null && (typeof s == "string" && (Lr(s) || kr(s)) ? s = parseFloat(s) : !jf(s) && Tt.test(n) && (s = Kr(e, n)), this.setBaseTarget(e, z(s) ? s.get() : s)), z(s) ? s.get() : s;
|
|
5227
5227
|
}
|
|
5228
5228
|
/**
|
|
5229
5229
|
* Set the base target to later animate back to. This is currently
|
|
@@ -5256,9 +5256,9 @@ class Bf {
|
|
|
5256
5256
|
this.events[e] && this.events[e].notify(...n);
|
|
5257
5257
|
}
|
|
5258
5258
|
}
|
|
5259
|
-
class
|
|
5259
|
+
class Mo extends Bf {
|
|
5260
5260
|
constructor() {
|
|
5261
|
-
super(...arguments), this.KeyframeResolver =
|
|
5261
|
+
super(...arguments), this.KeyframeResolver = Gr;
|
|
5262
5262
|
}
|
|
5263
5263
|
sortInstanceNodePosition(e, n) {
|
|
5264
5264
|
return e.compareDocumentPosition(n) & 2 ? 1 : -1;
|
|
@@ -5273,21 +5273,21 @@ class ko extends Bf {
|
|
|
5273
5273
|
function If(t) {
|
|
5274
5274
|
return window.getComputedStyle(t);
|
|
5275
5275
|
}
|
|
5276
|
-
class Nf extends
|
|
5276
|
+
class Nf extends Mo {
|
|
5277
5277
|
constructor() {
|
|
5278
|
-
super(...arguments), this.type = "html", this.applyWillChange = !0, this.renderInstance =
|
|
5278
|
+
super(...arguments), this.type = "html", this.applyWillChange = !0, this.renderInstance = Pr;
|
|
5279
5279
|
}
|
|
5280
5280
|
readValueFromInstance(e, n) {
|
|
5281
5281
|
if (bt.has(n)) {
|
|
5282
5282
|
const i = si(n);
|
|
5283
5283
|
return i && i.default || 0;
|
|
5284
5284
|
} else {
|
|
5285
|
-
const i = If(e), s = (
|
|
5285
|
+
const i = If(e), s = (mr(n) ? i.getPropertyValue(n) : i[n]) || 0;
|
|
5286
5286
|
return typeof s == "string" ? s.trim() : s;
|
|
5287
5287
|
}
|
|
5288
5288
|
}
|
|
5289
5289
|
measureInstanceViewportBox(e, { transformPagePoint: n }) {
|
|
5290
|
-
return
|
|
5290
|
+
return Po(e, n);
|
|
5291
5291
|
}
|
|
5292
5292
|
build(e, n, i) {
|
|
5293
5293
|
Yn(e, n, i.transformTemplate);
|
|
@@ -5303,7 +5303,7 @@ class Nf extends ko {
|
|
|
5303
5303
|
}));
|
|
5304
5304
|
}
|
|
5305
5305
|
}
|
|
5306
|
-
class Uf extends
|
|
5306
|
+
class Uf extends Mo {
|
|
5307
5307
|
constructor() {
|
|
5308
5308
|
super(...arguments), this.type = "svg", this.isSVGTag = !1, this.measureInstanceViewportBox = I;
|
|
5309
5309
|
}
|
|
@@ -5315,27 +5315,27 @@ class Uf extends ko {
|
|
|
5315
5315
|
const i = si(n);
|
|
5316
5316
|
return i && i.default || 0;
|
|
5317
5317
|
}
|
|
5318
|
-
return n =
|
|
5318
|
+
return n = xr.has(n) ? n : Ue(n), e.getAttribute(n);
|
|
5319
5319
|
}
|
|
5320
5320
|
scrapeMotionValuesFromProps(e, n, i) {
|
|
5321
|
-
return
|
|
5321
|
+
return br(e, n, i);
|
|
5322
5322
|
}
|
|
5323
5323
|
build(e, n, i) {
|
|
5324
5324
|
qn(e, n, this.isSVGTag, i.transformTemplate);
|
|
5325
5325
|
}
|
|
5326
5326
|
renderInstance(e, n, i, s) {
|
|
5327
|
-
|
|
5327
|
+
Tr(e, n, i, s);
|
|
5328
5328
|
}
|
|
5329
5329
|
mount(e) {
|
|
5330
5330
|
this.isSVGTag = Zn(e.tagName), super.mount(e);
|
|
5331
5331
|
}
|
|
5332
5332
|
}
|
|
5333
5333
|
const Wf = (t, e) => Kn(t) ? new Uf(e) : new Nf(e, {
|
|
5334
|
-
allowProjection: t !==
|
|
5334
|
+
allowProjection: t !== nr
|
|
5335
5335
|
}), $f = {
|
|
5336
5336
|
layout: {
|
|
5337
|
-
ProjectionNode:
|
|
5338
|
-
MeasureLayout:
|
|
5337
|
+
ProjectionNode: Vo,
|
|
5338
|
+
MeasureLayout: To
|
|
5339
5339
|
}
|
|
5340
5340
|
}, Kf = {
|
|
5341
5341
|
...bu,
|
|
@@ -5368,7 +5368,7 @@ function zf({ children: t, isPresent: e }) {
|
|
|
5368
5368
|
top: 0,
|
|
5369
5369
|
left: 0
|
|
5370
5370
|
}), { nonce: o } = $(Bn);
|
|
5371
|
-
return
|
|
5371
|
+
return er(() => {
|
|
5372
5372
|
const { width: r, height: a, top: l, left: c } = s.current;
|
|
5373
5373
|
if (e || !i.current || !r || !a)
|
|
5374
5374
|
return;
|
|
@@ -5429,7 +5429,7 @@ function Js(t) {
|
|
|
5429
5429
|
const qf = ({ children: t, exitBeforeEnter: e, custom: n, initial: i = !0, onExitComplete: s, presenceAffectsLayout: o = !0, mode: r = "sync" }) => {
|
|
5430
5430
|
pt(!e, "Replace exitBeforeEnter with mode='wait'");
|
|
5431
5431
|
const a = Mt(() => Js(t), [t]), l = a.map(Ce), c = it(!0), u = it(a), f = ti(() => /* @__PURE__ */ new Map()), [d, p] = _t(a), [m, P] = _t(a);
|
|
5432
|
-
|
|
5432
|
+
rr(() => {
|
|
5433
5433
|
c.current = !1, u.current = a;
|
|
5434
5434
|
for (let y = 0; y < m.length; y++) {
|
|
5435
5435
|
const v = Ce(m[y]);
|
|
@@ -5524,11 +5524,11 @@ function ih(t) {
|
|
|
5524
5524
|
var sh = ih();
|
|
5525
5525
|
const tr = ({
|
|
5526
5526
|
onMousedown: t
|
|
5527
|
-
}) => (
|
|
5527
|
+
}) => (ot(() => (document.addEventListener("mousedown", t), () => {
|
|
5528
5528
|
document.removeEventListener("mousedown", t);
|
|
5529
5529
|
}), []), null), rh = ({
|
|
5530
5530
|
onPickerHide: t
|
|
5531
|
-
}) => (
|
|
5531
|
+
}) => (ot(() => () => {
|
|
5532
5532
|
t();
|
|
5533
5533
|
}, []), null), oh = "acrool-react-picker__root", ah = "acrool-react-picker__main-el", lh = "acrool-react-picker__picker-el", yn = {
|
|
5534
5534
|
root: oh,
|
|
@@ -5536,8 +5536,7 @@ const tr = ({
|
|
|
5536
5536
|
mainEl: ah,
|
|
5537
5537
|
"picker-el": "acrool-react-picker__picker-el",
|
|
5538
5538
|
pickerEl: lh
|
|
5539
|
-
}
|
|
5540
|
-
const Lo = (t, e) => (n) => {
|
|
5539
|
+
}, ko = (t, e) => (n) => {
|
|
5541
5540
|
e.current = n, t && (typeof t == "function" ? t(n) : t && (t.current = n));
|
|
5542
5541
|
}, ch = "acrool-react-picker__motion-animation-wrapper", uh = {
|
|
5543
5542
|
"motion-animation-wrapper": "acrool-react-picker__motion-animation-wrapper",
|
|
@@ -5561,13 +5560,13 @@ const hh = (t, e, n) => {
|
|
|
5561
5560
|
if (!i || !s)
|
|
5562
5561
|
return;
|
|
5563
5562
|
const o = s.getBoundingClientRect(), r = i.getBoundingClientRect(), a = window.innerHeight, l = window.innerWidth, c = window.pageYOffset || document.documentElement.scrollTop, u = window.pageXOffset || document.documentElement.scrollLeft, f = 8, d = r.top - f, p = a - r.bottom - f;
|
|
5564
|
-
let m = p >= d ?
|
|
5563
|
+
let m = p >= d ? lt.bottom : lt.top, P = m === lt.bottom ? p : d;
|
|
5565
5564
|
const b = o.width, x = r.left + b < l, y = r.right - b > 0;
|
|
5566
5565
|
let v = Jt.left;
|
|
5567
|
-
!x && y ? v = Jt.right : !x && !y && (v = Jt.left), n(m), s.style.top = m ===
|
|
5566
|
+
!x && y ? v = Jt.right : !x && !y && (v = Jt.left), n(m), s.style.top = m === lt.bottom ? `${r.bottom + c}px` : `${r.top + c - P}px`, s.style.left = v === Jt.left ? `${r.left + u}px` : `${r.right + u - b}px`, s.style.minWidth = `${r.width}px`, s.style.height = `${P}px`, s.style.transformOrigin = m === lt.bottom ? "top" : "bottom", s.style.flexDirection = m === lt.bottom ? "column" : "column-reverse";
|
|
5568
5567
|
}, dh = {
|
|
5569
5568
|
variants: {
|
|
5570
|
-
initial: { zIndex: 999, opacity: 0, transition: { type: "spring" } },
|
|
5569
|
+
initial: { position: "absolute", zIndex: 999, opacity: 0, transition: { type: "spring" } },
|
|
5571
5570
|
show: { opacity: 1, transition: { type: "just" } },
|
|
5572
5571
|
exit: { opacity: 0, scale: 0.95 }
|
|
5573
5572
|
},
|
|
@@ -5587,10 +5586,10 @@ const hh = (t, e, n) => {
|
|
|
5587
5586
|
const i = it(null), s = ya(), o = rt(() => {
|
|
5588
5587
|
hh(e, i, s.setVertical);
|
|
5589
5588
|
}, [s.setVertical]);
|
|
5590
|
-
return
|
|
5589
|
+
return ot(() => {
|
|
5591
5590
|
if (e.current && i.current) {
|
|
5592
5591
|
const r = fh(e.current);
|
|
5593
|
-
return
|
|
5592
|
+
return r && (r.addEventListener("scroll", o), window.addEventListener("resize", o)), window.requestAnimationFrame(() => {
|
|
5594
5593
|
i.current && (i.current.style.display = "flex", o());
|
|
5595
5594
|
}), () => {
|
|
5596
5595
|
r && (r.removeEventListener("scroll", o), window.removeEventListener("resize", o));
|
|
@@ -5599,7 +5598,7 @@ const hh = (t, e, n) => {
|
|
|
5599
5598
|
}, [s.isVisible]), /* @__PURE__ */ F.jsx(F.Fragment, { children: /* @__PURE__ */ F.jsx(
|
|
5600
5599
|
Gf.div,
|
|
5601
5600
|
{
|
|
5602
|
-
ref:
|
|
5601
|
+
ref: ko(n, i),
|
|
5603
5602
|
transition: { type: "spring", duration: 0.2 },
|
|
5604
5603
|
style: { display: "none" },
|
|
5605
5604
|
className: uh.motionAnimationWrapper,
|
|
@@ -5614,12 +5613,12 @@ const hh = (t, e, n) => {
|
|
|
5614
5613
|
function Th(t, e, n) {
|
|
5615
5614
|
const i = ke(t);
|
|
5616
5615
|
return ke((o, r) => {
|
|
5617
|
-
const [a, l] = _t(!1), [c, u] = _t(!1), [f, d] = _t(
|
|
5618
|
-
|
|
5616
|
+
const [a, l] = _t(!1), [c, u] = _t(!1), [f, d] = _t(lt.bottom), [p, m] = _t(), P = it(null), b = it(null), x = it(null), y = it(p), v = (n == null ? void 0 : n.isEnableClickOutSiteHidden) !== !1, w = (n == null ? void 0 : n.isEnableHideSave) !== !1;
|
|
5617
|
+
ot(() => {
|
|
5619
5618
|
m(o.value);
|
|
5620
|
-
}, [JSON.stringify(o.value)]),
|
|
5619
|
+
}, [JSON.stringify(o.value)]), ot(() => {
|
|
5621
5620
|
y.current = p;
|
|
5622
|
-
}, [p]),
|
|
5621
|
+
}, [p]), ot(() => {
|
|
5623
5622
|
a && m(o.value);
|
|
5624
5623
|
}, [a, o.value]);
|
|
5625
5624
|
const A = rt((j) => {
|
|
@@ -5662,11 +5661,11 @@ function Th(t, e, n) {
|
|
|
5662
5661
|
i,
|
|
5663
5662
|
{
|
|
5664
5663
|
...o,
|
|
5665
|
-
ref:
|
|
5664
|
+
ref: ko(r, b)
|
|
5666
5665
|
}
|
|
5667
5666
|
) }),
|
|
5668
5667
|
/* @__PURE__ */ F.jsx(qf, { children: a && /* @__PURE__ */ F.jsx(
|
|
5669
|
-
|
|
5668
|
+
sr,
|
|
5670
5669
|
{
|
|
5671
5670
|
id: `acrool-react-picker-${sh().toLowerCase()}`,
|
|
5672
5671
|
className: yn.pickerEl,
|
|
@@ -5712,7 +5711,7 @@ function Th(t, e, n) {
|
|
|
5712
5711
|
}
|
|
5713
5712
|
export {
|
|
5714
5713
|
Jt as EHorizontal,
|
|
5715
|
-
|
|
5714
|
+
lt as EVertical,
|
|
5716
5715
|
vh as PickerProviderConsumer,
|
|
5717
5716
|
_n as PickerProviderContext,
|
|
5718
5717
|
Th as createPicker,
|