@versini/sassysaint 8.135.1 → 8.135.3
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/chunks/{AboutChangelog.BFh8ukCp.js → AboutChangelog.4cOJijJ8.js} +2 -2
- package/dist/chunks/{AboutEntry.BfABiXLF.js → AboutEntry.BvMa7mOA.js} +8 -8
- package/dist/chunks/{App.zShMOQq9.js → App.2PuiTysR.js} +1476 -1476
- package/dist/chunks/{BubbleActions.B5kDm2j_.js → BubbleActions.BMh2kxZG.js} +3 -3
- package/dist/chunks/{ButtonIconDelete.DwNJLOq2.js → ButtonIconDelete.A8GqEr7Y.js} +4 -4
- package/dist/chunks/{Chart.CGX1wHyQ.js → Chart.CUH_IDb2.js} +2 -2
- package/dist/chunks/{ChatBubbleAssistant.DFyGfa72.js → ChatBubbleAssistant.BRN3op9A.js} +364 -342
- package/dist/chunks/{ChatBubbleUser.DIsFz4pf.js → ChatBubbleUser.BkKnEyj2.js} +4 -4
- package/dist/chunks/{GenericPanel.Bj2vNTff.js → GenericPanel.hOl2bO0I.js} +1 -1
- package/dist/chunks/{HistoryEntry.j5_np-1i.js → HistoryEntry.C9u733FF.js} +8 -8
- package/dist/chunks/{LoginEntry.L034DvA5.js → LoginEntry.Dhckuuq5.js} +7 -7
- package/dist/chunks/{LogoEntry.r-vdXCN2.js → LogoEntry.CMt7vHXp.js} +1 -1
- package/dist/chunks/{MemoriesEntry.Bjv3r7Hy.js → MemoriesEntry.BWA-AFKR.js} +6 -6
- package/dist/chunks/{ProfileEntry.eUeHbAk1.js → ProfileEntry.DnZDaKh-.js} +6 -6
- package/dist/chunks/{SettingsEntry.2yvNhcXH.js → SettingsEntry.D2t7hHrD.js} +6 -6
- package/dist/chunks/{UsageEntry.DKwZBmKL.js → UsageEntry.Cinuixqj.js} +6 -6
- package/dist/chunks/{_baseUniq.BoQJ-_HW.js → _baseUniq.Cw6h7m_E.js} +1 -1
- package/dist/chunks/{arc.CY_r8ZMf.js → arc.BCUOjadj.js} +1 -1
- package/dist/chunks/{architecture-U656AL7Q.DkoEYMrE.js → architecture-U656AL7Q.BB6IANs5.js} +1 -1
- package/dist/chunks/{architectureDiagram-VXUJARFQ.B8tD0Wf9.js → architectureDiagram-VXUJARFQ.CHscN2O9.js} +6 -6
- package/dist/chunks/{blockDiagram-VD42YOAC.DSorHGCj.js → blockDiagram-VD42YOAC.6thsY2-w.js} +5 -5
- package/dist/chunks/{browser.B5LIEeBr.js → browser.B3adpTpH.js} +1 -1
- package/dist/chunks/{c4Diagram-YG6GDRKO.CUVTFswr.js → c4Diagram-YG6GDRKO.DTY3dq5W.js} +2 -2
- package/dist/chunks/{channel.CWEc_XNK.js → channel.BIeAmW6E.js} +1 -1
- package/dist/chunks/{chunk-4BX2VUAB.CWTLyRbm.js → chunk-4BX2VUAB.BV4Pza1_.js} +1 -1
- package/dist/chunks/{chunk-55IACEB6.BiSsWdAh.js → chunk-55IACEB6.BgxCmUPn.js} +1 -1
- package/dist/chunks/{chunk-B4BG7PRW.CRVs15Yq.js → chunk-B4BG7PRW.BuoA6-4P.js} +4 -4
- package/dist/chunks/{chunk-DI55MBZ5.DXp07gIA.js → chunk-DI55MBZ5.Bc4EfQTV.js} +3 -3
- package/dist/chunks/{chunk-FMBD7UC4.BmcsX5hQ.js → chunk-FMBD7UC4.Cnznc2ga.js} +1 -1
- package/dist/chunks/{chunk-QN33PNHL.BY_SdwN-.js → chunk-QN33PNHL.BjrT8AzX.js} +1 -1
- package/dist/chunks/{chunk-QZHKN3VN.MjytHIRJ.js → chunk-QZHKN3VN.DmTUucoA.js} +1 -1
- package/dist/chunks/{chunk-TZMSLE5B.BvQSeNwE.js → chunk-TZMSLE5B.98dHTgB9.js} +1 -1
- package/dist/chunks/{classDiagram-2ON5EDUG.DDfWI1iS.js → classDiagram-2ON5EDUG.DoIObvKW.js} +2 -2
- package/dist/chunks/{classDiagram-v2-WZHVMYZB.DDfWI1iS.js → classDiagram-v2-WZHVMYZB.DoIObvKW.js} +2 -2
- package/dist/chunks/{clone.4hmFXZGB.js → clone.rfAiOrgH.js} +1 -1
- package/dist/chunks/{cose-bilkent-S5V4N54A.vtfvV07j.js → cose-bilkent-S5V4N54A.BEHnPo4E.js} +2 -2
- package/dist/chunks/{dagre-6UL2VRFP.JkC-kAPp.js → dagre-6UL2VRFP.aQ3VEsZh.js} +5 -5
- package/dist/chunks/{diagram-PSM6KHXK.sop7a3k7.js → diagram-PSM6KHXK.VT1Q0S1D.js} +4 -4
- package/dist/chunks/{diagram-QEK2KX5R.Bx-sWtcB.js → diagram-QEK2KX5R.BJgsBWMc.js} +3 -3
- package/dist/chunks/{diagram-S2PKOQOG.CWZGBMGC.js → diagram-S2PKOQOG.BBoCLQI0.js} +5 -5
- package/dist/chunks/{erDiagram-Q2GNP2WA.BRwuuUi9.js → erDiagram-Q2GNP2WA.byEb_kcU.js} +4 -4
- package/dist/chunks/{flowDiagram-NV44I4VS.aS_0XYcu.js → flowDiagram-NV44I4VS.BJO0o0c2.js} +5 -5
- package/dist/chunks/{ganttDiagram-JELNMOA3.BsUUbJwy.js → ganttDiagram-JELNMOA3.BfoeNule.js} +2 -2
- package/dist/chunks/{gitGraph-F6HP7TQM.2SyUh64j.js → gitGraph-F6HP7TQM.Bh68YZf9.js} +1 -1
- package/dist/chunks/{gitGraphDiagram-NY62KEGX.gQoF09oR.js → gitGraphDiagram-NY62KEGX.Bv-es04j.js} +9 -9
- package/dist/chunks/{graph.3uZHl3-y.js → graph.C-6TOhFT.js} +4 -4
- package/dist/chunks/{index.BwjcCqqd.js → index.-VqHZqzV.js} +1 -1
- package/dist/chunks/{index.CdYKPITo.js → index.BHHIXPy1.js} +3 -3
- package/dist/chunks/{index.DtsGz-nk.js → index.BQQKIAwM.js} +1 -1
- package/dist/chunks/{index.CHAhFpi_.js → index.Bz8wHwS7.js} +1 -1
- package/dist/chunks/{index.sc0P6mn_.js → index.CE7sbvZy.js} +3 -3
- package/dist/chunks/{index.D0VZeadY.js → index.Vk59Q2cQ.js} +1 -1
- package/dist/chunks/{index.UuHYEgmi.js → index.mB-Hz6w6.js} +1 -1
- package/dist/chunks/{index.BQczTuMX.js → index.pkUFX9gQ.js} +1 -1
- package/dist/chunks/{index.BGVSo5bF.js → index.tMcUezR9.js} +3 -3
- package/dist/chunks/{index.ByFIEUIn.js → index.zbPm9xn9.js} +1 -1
- package/dist/chunks/{info-NVLQJR56.C4Rnv-gF.js → info-NVLQJR56.DR5aEeh4.js} +1 -1
- package/dist/chunks/{infoDiagram-WHAUD3N6.k6Nqa6_n.js → infoDiagram-WHAUD3N6.RevLcGol.js} +2 -2
- package/dist/chunks/{journeyDiagram-XKPGCS4Q.BxydSWSU.js → journeyDiagram-XKPGCS4Q.DAtiPtbD.js} +4 -4
- package/dist/chunks/{kanban-definition-3W4ZIXB7.CbQ2PbqL.js → kanban-definition-3W4ZIXB7.DnjIzLj1.js} +2 -2
- package/dist/chunks/{layout.CzQPfYpk.js → layout.4lof8QWl.js} +4 -4
- package/dist/chunks/{mermaid-parser.core.BR3W-Erf.js → mermaid-parser.core.D9fnj20U.js} +10 -10
- package/dist/chunks/{min.Bcqww540.js → min.Bc7JS0nS.js} +4 -4
- package/dist/chunks/{mindmap-definition-VGOIOE7T.Dx8Vxrt-.js → mindmap-definition-VGOIOE7T.BLnPLSzg.js} +3 -3
- package/dist/chunks/{packet-BFZMPI3H.fT9X5wLG.js → packet-BFZMPI3H.DbXidJQu.js} +1 -1
- package/dist/chunks/{pie-7BOR55EZ.W6qGPA_7.js → pie-7BOR55EZ.CuIQhi5J.js} +1 -1
- package/dist/chunks/{pieDiagram-ADFJNKIX.DwFt9UD4.js → pieDiagram-ADFJNKIX.DGJoGMV8.js} +4 -4
- package/dist/chunks/{quadrantDiagram-AYHSOK5B.BuCvuRiE.js → quadrantDiagram-AYHSOK5B.34qIxy1A.js} +3 -3
- package/dist/chunks/{radar-NHE76QYJ.BBrz34_s.js → radar-NHE76QYJ.Djnz9PyL.js} +1 -1
- package/dist/chunks/{rehype-mermaid.DoqqoD0v.js → rehype-mermaid.DcpbpKKJ.js} +33 -33
- package/dist/chunks/{requirementDiagram-UZGBJVZJ.D7jfiKxB.js → requirementDiagram-UZGBJVZJ.Qdk6lRiy.js} +3 -3
- package/dist/chunks/{sankeyDiagram-TZEHDZUN.q_Q0eRRQ.js → sankeyDiagram-TZEHDZUN.CoZ7nDCa.js} +1 -1
- package/dist/chunks/{sequenceDiagram-WL72ISMW.C9xSBNkm.js → sequenceDiagram-WL72ISMW.Bg2Qteoe.js} +3 -3
- package/dist/chunks/{stateDiagram-FKZM4ZOC.CDzQK2vr.js → stateDiagram-FKZM4ZOC.BnNmmT-I.js} +4 -4
- package/dist/chunks/{stateDiagram-v2-4FDKWEC3.CNt5KhBr.js → stateDiagram-v2-4FDKWEC3.QXAR0cK3.js} +2 -2
- package/dist/chunks/{timeline-definition-IT6M3QCI.CQytMJWu.js → timeline-definition-IT6M3QCI.Cg8zgNuY.js} +2 -2
- package/dist/chunks/{treemap-KMMF4GRG.C8RaqthH.js → treemap-KMMF4GRG.B69gtRFy.js} +1 -1
- package/dist/chunks/{useMarkdown.BwimB2J8.js → useMarkdown.DXfQk22a.js} +9 -9
- package/dist/chunks/{xychartDiagram-PRI3JC2R.C_oUQMsD.js → xychartDiagram-PRI3JC2R.CElIduys.js} +4 -4
- package/dist/components/SassySaint/SassySaint.js +1 -1
- package/dist/index.js +3 -3
- package/package.json +3 -3
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { jsx as St } from "react/jsx-runtime";
|
|
2
|
-
import { n as
|
|
3
|
-
import { numberFormatter as
|
|
2
|
+
import { n as ls, useUserPreferences as us, formatTimestamp as Vt } from "./index.CE7sbvZy.js";
|
|
3
|
+
import { numberFormatter as cs, pluralize as fs, Bubble as hs } from "./App.2PuiTysR.js";
|
|
4
4
|
import Jt from "clsx";
|
|
5
|
-
import
|
|
6
|
-
import { useMarkdown as
|
|
7
|
-
import { ChatContext as
|
|
8
|
-
import { BubbleActions as
|
|
5
|
+
import ds, { useState as xe, useEffect as Qt, useContext as Mt } from "react";
|
|
6
|
+
import { useMarkdown as ps } from "./useMarkdown.DXfQk22a.js";
|
|
7
|
+
import { ChatContext as ms, AppContext as gs } from "./LogoEntry.CMt7vHXp.js";
|
|
8
|
+
import { BubbleActions as ys } from "./BubbleActions.BMh2kxZG.js";
|
|
9
9
|
const we = {
|
|
10
10
|
isEmpty: !0
|
|
11
11
|
};
|
|
12
|
-
function
|
|
12
|
+
function bs(e, t) {
|
|
13
13
|
e.indexOf(t) === -1 && e.push(t);
|
|
14
14
|
}
|
|
15
15
|
function qe(e, t) {
|
|
@@ -30,7 +30,7 @@ typeof process < "u" && process.env?.NODE_ENV !== "production" && (de = (e, t, n
|
|
|
30
30
|
throw new Error(ke(t, n));
|
|
31
31
|
});
|
|
32
32
|
const N = {}, en = (e) => /^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);
|
|
33
|
-
function
|
|
33
|
+
function Ts(e) {
|
|
34
34
|
return typeof e == "object" && e !== null;
|
|
35
35
|
}
|
|
36
36
|
const tn = (e) => /^0[^.\s]+$/u.test(e);
|
|
@@ -39,7 +39,7 @@ function Ze(e) {
|
|
|
39
39
|
let t;
|
|
40
40
|
return () => (t === void 0 && (t = e()), t);
|
|
41
41
|
}
|
|
42
|
-
const H = /* @__NO_SIDE_EFFECTS__ */ (e) => e,
|
|
42
|
+
const H = /* @__NO_SIDE_EFFECTS__ */ (e) => e, vs = (e, t) => (n) => t(e(n)), He = (...e) => e.reduce(vs), Je = /* @__NO_SIDE_EFFECTS__ */ (e, t, n) => {
|
|
43
43
|
const s = t - e;
|
|
44
44
|
return s === 0 ? 1 : (n - e) / s;
|
|
45
45
|
};
|
|
@@ -48,7 +48,7 @@ class nn {
|
|
|
48
48
|
this.subscriptions = [];
|
|
49
49
|
}
|
|
50
50
|
add(t) {
|
|
51
|
-
return
|
|
51
|
+
return bs(this.subscriptions, t), () => qe(this.subscriptions, t);
|
|
52
52
|
}
|
|
53
53
|
notify(t, n, s) {
|
|
54
54
|
const i = this.subscriptions.length;
|
|
@@ -68,23 +68,23 @@ class nn {
|
|
|
68
68
|
this.subscriptions.length = 0;
|
|
69
69
|
}
|
|
70
70
|
}
|
|
71
|
-
const
|
|
71
|
+
const k = /* @__NO_SIDE_EFFECTS__ */ (e) => e * 1e3, P = /* @__NO_SIDE_EFFECTS__ */ (e) => e / 1e3;
|
|
72
72
|
function sn(e, t) {
|
|
73
73
|
return t ? e * (1e3 / t) : 0;
|
|
74
74
|
}
|
|
75
|
-
const
|
|
75
|
+
const At = /* @__PURE__ */ new Set();
|
|
76
76
|
function rn(e, t, n) {
|
|
77
|
-
e ||
|
|
77
|
+
e || At.has(t) || (console.warn(ke(t, n)), At.add(t));
|
|
78
78
|
}
|
|
79
|
-
const
|
|
79
|
+
const Ss = (e, t, n) => {
|
|
80
80
|
const s = t - e;
|
|
81
81
|
return ((n - e) % s + s) % s + e;
|
|
82
|
-
}, an = (e, t, n) => (((1 - 3 * n + 3 * t) * e + (3 * n - 6 * t)) * e + 3 * t) * e,
|
|
82
|
+
}, an = (e, t, n) => (((1 - 3 * n + 3 * t) * e + (3 * n - 6 * t)) * e + 3 * t) * e, Vs = 1e-7, Ms = 12;
|
|
83
83
|
function As(e, t, n, s, i) {
|
|
84
84
|
let r, a, o = 0;
|
|
85
85
|
do
|
|
86
86
|
a = t + (n - t) / 2, r = an(a, s, i) - e, r > 0 ? n = a : t = a;
|
|
87
|
-
while (Math.abs(r) >
|
|
87
|
+
while (Math.abs(r) > Vs && ++o < Ms);
|
|
88
88
|
return a;
|
|
89
89
|
}
|
|
90
90
|
function pe(e, t, n, s) {
|
|
@@ -93,28 +93,28 @@ function pe(e, t, n, s) {
|
|
|
93
93
|
const i = (r) => As(r, 0, 1, e, n);
|
|
94
94
|
return (r) => r === 0 || r === 1 ? r : an(i(r), t, s);
|
|
95
95
|
}
|
|
96
|
-
const on = (e) => (t) => t <= 0.5 ? e(2 * t) / 2 : (2 - e(2 * (1 - t))) / 2, ln = (e) => (t) => 1 - e(1 - t), un = /* @__PURE__ */ pe(0.33, 1.53, 0.69, 0.99), Qe = /* @__PURE__ */ ln(un), cn = /* @__PURE__ */ on(Qe), fn = (e) => (e *= 2) < 1 ? 0.5 * Qe(e) : 0.5 * (2 - Math.pow(2, -10 * (e - 1))), et = (e) => 1 - Math.sin(Math.acos(e)),
|
|
96
|
+
const on = (e) => (t) => t <= 0.5 ? e(2 * t) / 2 : (2 - e(2 * (1 - t))) / 2, ln = (e) => (t) => 1 - e(1 - t), un = /* @__PURE__ */ pe(0.33, 1.53, 0.69, 0.99), Qe = /* @__PURE__ */ ln(un), cn = /* @__PURE__ */ on(Qe), fn = (e) => (e *= 2) < 1 ? 0.5 * Qe(e) : 0.5 * (2 - Math.pow(2, -10 * (e - 1))), et = (e) => 1 - Math.sin(Math.acos(e)), xs = ln(et), hn = on(et), ws = /* @__PURE__ */ pe(0.42, 0, 1, 1), Cs = /* @__PURE__ */ pe(0, 0, 0.58, 1), dn = /* @__PURE__ */ pe(0.42, 0, 0.58, 1), pn = (e) => Array.isArray(e) && typeof e[0] != "number";
|
|
97
97
|
function mn(e, t) {
|
|
98
|
-
return pn(e) ? e[
|
|
98
|
+
return pn(e) ? e[Ss(0, e.length, t)] : e;
|
|
99
99
|
}
|
|
100
100
|
const gn = (e) => Array.isArray(e) && typeof e[0] == "number", xt = {
|
|
101
101
|
linear: H,
|
|
102
|
-
easeIn:
|
|
102
|
+
easeIn: ws,
|
|
103
103
|
easeInOut: dn,
|
|
104
|
-
easeOut:
|
|
104
|
+
easeOut: Cs,
|
|
105
105
|
circIn: et,
|
|
106
106
|
circInOut: hn,
|
|
107
|
-
circOut:
|
|
107
|
+
circOut: xs,
|
|
108
108
|
backIn: Qe,
|
|
109
109
|
backInOut: cn,
|
|
110
110
|
backOut: un,
|
|
111
111
|
anticipate: fn
|
|
112
|
-
},
|
|
112
|
+
}, Ds = (e) => typeof e == "string", wt = (e) => {
|
|
113
113
|
if (gn(e)) {
|
|
114
114
|
I(e.length === 4, "Cubic bezier arrays must contain four numerical values.", "cubic-bezier-length");
|
|
115
115
|
const [t, n, s, i] = e;
|
|
116
116
|
return pe(t, n, s, i);
|
|
117
|
-
} else if (
|
|
117
|
+
} else if (Ds(e))
|
|
118
118
|
return I(xt[e] !== void 0, `Invalid easing type '${e}'`, "invalid-easing-type"), xt[e];
|
|
119
119
|
return e;
|
|
120
120
|
}, be = [
|
|
@@ -135,7 +135,7 @@ const gn = (e) => Array.isArray(e) && typeof e[0] == "number", xt = {
|
|
|
135
135
|
"postRender"
|
|
136
136
|
// Compute
|
|
137
137
|
];
|
|
138
|
-
function
|
|
138
|
+
function Fs(e, t) {
|
|
139
139
|
let n = /* @__PURE__ */ new Set(), s = /* @__PURE__ */ new Set(), i = !1, r = !1;
|
|
140
140
|
const a = /* @__PURE__ */ new WeakSet();
|
|
141
141
|
let o = {
|
|
@@ -173,38 +173,38 @@ function Ds(e, t) {
|
|
|
173
173
|
};
|
|
174
174
|
return c;
|
|
175
175
|
}
|
|
176
|
-
const
|
|
176
|
+
const Es = 40;
|
|
177
177
|
function yn(e, t) {
|
|
178
178
|
let n = !1, s = !0;
|
|
179
179
|
const i = {
|
|
180
180
|
delta: 0,
|
|
181
181
|
timestamp: 0,
|
|
182
182
|
isProcessing: !1
|
|
183
|
-
}, r = () => n = !0, a = be.reduce((V,
|
|
183
|
+
}, r = () => n = !0, a = be.reduce((V, M) => (V[M] = Fs(r), V), {}), { setup: o, read: u, resolveKeyframes: c, preUpdate: l, update: f, preRender: h, render: p, postRender: g } = a, y = () => {
|
|
184
184
|
const V = N.useManualTiming ? i.timestamp : performance.now();
|
|
185
|
-
n = !1, N.useManualTiming || (i.delta = s ? 1e3 / 60 : Math.max(Math.min(V - i.timestamp,
|
|
185
|
+
n = !1, N.useManualTiming || (i.delta = s ? 1e3 / 60 : Math.max(Math.min(V - i.timestamp, Es), 1)), i.timestamp = V, i.isProcessing = !0, o.process(i), u.process(i), c.process(i), l.process(i), f.process(i), h.process(i), p.process(i), g.process(i), i.isProcessing = !1, n && t && (s = !1, e(y));
|
|
186
186
|
}, S = () => {
|
|
187
187
|
n = !0, s = !0, i.isProcessing || e(y);
|
|
188
188
|
};
|
|
189
|
-
return { schedule: be.reduce((V,
|
|
190
|
-
const m = a[
|
|
191
|
-
return V[
|
|
189
|
+
return { schedule: be.reduce((V, M) => {
|
|
190
|
+
const m = a[M];
|
|
191
|
+
return V[M] = (b, x = !1, T = !1) => (n || S(), m.schedule(b, x, T)), V;
|
|
192
192
|
}, {}), cancel: (V) => {
|
|
193
|
-
for (let
|
|
194
|
-
a[be[
|
|
193
|
+
for (let M = 0; M < be.length; M++)
|
|
194
|
+
a[be[M]].cancel(V);
|
|
195
195
|
}, state: i, steps: a };
|
|
196
196
|
}
|
|
197
197
|
const { schedule: K, cancel: Oe, state: Se } = /* @__PURE__ */ yn(typeof requestAnimationFrame < "u" ? requestAnimationFrame : H, !0);
|
|
198
198
|
let ve;
|
|
199
|
-
function
|
|
199
|
+
function Rs() {
|
|
200
200
|
ve = void 0;
|
|
201
201
|
}
|
|
202
202
|
const R = {
|
|
203
203
|
now: () => (ve === void 0 && R.set(Se.isProcessing || N.useManualTiming ? Se.timestamp : performance.now()), ve),
|
|
204
204
|
set: (e) => {
|
|
205
|
-
ve = e, queueMicrotask(
|
|
205
|
+
ve = e, queueMicrotask(Rs);
|
|
206
206
|
}
|
|
207
|
-
}, bn = (e) => (t) => typeof t == "string" && t.startsWith(e), Tn = /* @__PURE__ */ bn("--"),
|
|
207
|
+
}, bn = (e) => (t) => typeof t == "string" && t.startsWith(e), Tn = /* @__PURE__ */ bn("--"), Ps = /* @__PURE__ */ bn("var(--"), tt = (e) => Ps(e) ? ks.test(e.split("/*")[0].trim()) : !1, ks = /var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;
|
|
208
208
|
function Ct(e) {
|
|
209
209
|
return typeof e != "string" ? !1 : e.split("/*")[0].includes("var(--");
|
|
210
210
|
}
|
|
@@ -219,10 +219,10 @@ const J = {
|
|
|
219
219
|
...J,
|
|
220
220
|
default: 1
|
|
221
221
|
}, le = (e) => Math.round(e * 1e5) / 1e5, nt = /-?(?:\d+(?:\.\d+)?|\.\d+)/gu;
|
|
222
|
-
function
|
|
222
|
+
function Os(e) {
|
|
223
223
|
return e == null;
|
|
224
224
|
}
|
|
225
|
-
const
|
|
225
|
+
const Bs = /^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu, st = (e, t) => (n) => !!(typeof n == "string" && Bs.test(n) && n.startsWith(e) || t && !Os(n) && Object.prototype.hasOwnProperty.call(n, t)), vn = (e, t, n) => (s) => {
|
|
226
226
|
if (typeof s != "string")
|
|
227
227
|
return s;
|
|
228
228
|
const [i, r, a, o] = s.match(nt);
|
|
@@ -232,15 +232,15 @@ const Os = /^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s
|
|
|
232
232
|
[n]: parseFloat(a),
|
|
233
233
|
alpha: o !== void 0 ? parseFloat(o) : 1
|
|
234
234
|
};
|
|
235
|
-
},
|
|
235
|
+
}, Is = (e) => _(0, 255, e), Ce = {
|
|
236
236
|
...J,
|
|
237
|
-
transform: (e) => Math.round(
|
|
237
|
+
transform: (e) => Math.round(Is(e))
|
|
238
238
|
}, j = {
|
|
239
239
|
test: /* @__PURE__ */ st("rgb", "red"),
|
|
240
240
|
parse: /* @__PURE__ */ vn("red", "green", "blue"),
|
|
241
241
|
transform: ({ red: e, green: t, blue: n, alpha: s = 1 }) => "rgba(" + Ce.transform(e) + ", " + Ce.transform(t) + ", " + Ce.transform(n) + ", " + le(ue.transform(s)) + ")"
|
|
242
242
|
};
|
|
243
|
-
function
|
|
243
|
+
function Ns(e) {
|
|
244
244
|
let t = "", n = "", s = "", i = "";
|
|
245
245
|
return e.length > 5 ? (t = e.substring(1, 3), n = e.substring(3, 5), s = e.substring(5, 7), i = e.substring(7, 9)) : (t = e.substring(1, 2), n = e.substring(2, 3), s = e.substring(3, 4), i = e.substring(4, 5), t += t, n += n, s += s, i += i), {
|
|
246
246
|
red: parseInt(t, 16),
|
|
@@ -251,13 +251,13 @@ function Is(e) {
|
|
|
251
251
|
}
|
|
252
252
|
const Be = {
|
|
253
253
|
test: /* @__PURE__ */ st("#"),
|
|
254
|
-
parse:
|
|
254
|
+
parse: Ns,
|
|
255
255
|
transform: j.transform
|
|
256
256
|
}, me = /* @__NO_SIDE_EFFECTS__ */ (e) => ({
|
|
257
257
|
test: (t) => typeof t == "string" && t.endsWith(e) && t.split(" ").length === 1,
|
|
258
258
|
parse: parseFloat,
|
|
259
259
|
transform: (t) => `${t}${e}`
|
|
260
|
-
}), L = /* @__PURE__ */ me("deg"), q = /* @__PURE__ */ me("%"), d = /* @__PURE__ */ me("px"),
|
|
260
|
+
}), L = /* @__PURE__ */ me("deg"), q = /* @__PURE__ */ me("%"), d = /* @__PURE__ */ me("px"), Ks = /* @__PURE__ */ me("vh"), $s = /* @__PURE__ */ me("vw"), Dt = {
|
|
261
261
|
...q,
|
|
262
262
|
parse: (e) => q.parse(e) / 100,
|
|
263
263
|
transform: (e) => q.transform(e * 100)
|
|
@@ -273,11 +273,11 @@ const Be = {
|
|
|
273
273
|
const t = D.parse(e);
|
|
274
274
|
return t.alpha = 0, D.transform(t);
|
|
275
275
|
}
|
|
276
|
-
},
|
|
277
|
-
function
|
|
278
|
-
return isNaN(e) && typeof e == "string" && (e.match(nt)?.length || 0) + (e.match(
|
|
276
|
+
}, Ls = /(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;
|
|
277
|
+
function Ws(e) {
|
|
278
|
+
return isNaN(e) && typeof e == "string" && (e.match(nt)?.length || 0) + (e.match(Ls)?.length || 0) > 0;
|
|
279
279
|
}
|
|
280
|
-
const Sn = "number", Vn = "color",
|
|
280
|
+
const Sn = "number", Vn = "color", _s = "var", Us = "var(", Ft = "${}", js = /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;
|
|
281
281
|
function ce(e) {
|
|
282
282
|
const t = e.toString(), n = [], s = {
|
|
283
283
|
color: [],
|
|
@@ -285,13 +285,13 @@ function ce(e) {
|
|
|
285
285
|
var: []
|
|
286
286
|
}, i = [];
|
|
287
287
|
let r = 0;
|
|
288
|
-
const o = t.replace(
|
|
288
|
+
const o = t.replace(js, (u) => (D.test(u) ? (s.color.push(r), i.push(Vn), n.push(D.parse(u))) : u.startsWith(Us) ? (s.var.push(r), i.push(_s), n.push(u)) : (s.number.push(r), i.push(Sn), n.push(parseFloat(u))), ++r, Ft)).split(Ft);
|
|
289
289
|
return { values: n, split: o, indexes: s, types: i };
|
|
290
290
|
}
|
|
291
|
-
function
|
|
291
|
+
function Mn(e) {
|
|
292
292
|
return ce(e).values;
|
|
293
293
|
}
|
|
294
|
-
function
|
|
294
|
+
function An(e) {
|
|
295
295
|
const { split: t, types: n } = ce(e), s = t.length;
|
|
296
296
|
return (i) => {
|
|
297
297
|
let r = "";
|
|
@@ -303,21 +303,21 @@ function Mn(e) {
|
|
|
303
303
|
return r;
|
|
304
304
|
};
|
|
305
305
|
}
|
|
306
|
-
const
|
|
307
|
-
function
|
|
308
|
-
const t =
|
|
309
|
-
return
|
|
306
|
+
const Gs = (e) => typeof e == "number" ? 0 : D.test(e) ? D.getAnimatableNone(e) : e;
|
|
307
|
+
function Ys(e) {
|
|
308
|
+
const t = Mn(e);
|
|
309
|
+
return An(e)(t.map(Gs));
|
|
310
310
|
}
|
|
311
311
|
const U = {
|
|
312
|
-
test:
|
|
313
|
-
parse:
|
|
314
|
-
createTransformer:
|
|
315
|
-
getAnimatableNone:
|
|
312
|
+
test: Ws,
|
|
313
|
+
parse: Mn,
|
|
314
|
+
createTransformer: An,
|
|
315
|
+
getAnimatableNone: Ys
|
|
316
316
|
};
|
|
317
317
|
function De(e, t, n) {
|
|
318
318
|
return n < 0 && (n += 1), n > 1 && (n -= 1), n < 1 / 6 ? e + (t - e) * 6 * n : n < 1 / 2 ? t : n < 2 / 3 ? e + (t - e) * (2 / 3 - n) * 6 : e;
|
|
319
319
|
}
|
|
320
|
-
function
|
|
320
|
+
function zs({ hue: e, saturation: t, lightness: n, alpha: s }) {
|
|
321
321
|
e /= 360, t /= 100, n /= 100;
|
|
322
322
|
let i = 0, r = 0, a = 0;
|
|
323
323
|
if (!t)
|
|
@@ -339,13 +339,13 @@ function Ve(e, t) {
|
|
|
339
339
|
const Q = (e, t, n) => e + (t - e) * n, Fe = (e, t, n) => {
|
|
340
340
|
const s = e * e, i = n * (t * t - s) + s;
|
|
341
341
|
return i < 0 ? 0 : Math.sqrt(i);
|
|
342
|
-
},
|
|
342
|
+
}, Xs = [Be, j, z], qs = (e) => Xs.find((t) => t.test(e));
|
|
343
343
|
function Et(e) {
|
|
344
|
-
const t =
|
|
344
|
+
const t = qs(e);
|
|
345
345
|
if (de(!!t, `'${e}' is not an animatable color. Use the equivalent color code instead.`, "color-not-animatable"), !t)
|
|
346
346
|
return !1;
|
|
347
347
|
let n = t.parse(e);
|
|
348
|
-
return t === z && (n =
|
|
348
|
+
return t === z && (n = zs(n)), n;
|
|
349
349
|
}
|
|
350
350
|
const Rt = (e, t) => {
|
|
351
351
|
const n = Et(e), s = Et(t);
|
|
@@ -354,14 +354,14 @@ const Rt = (e, t) => {
|
|
|
354
354
|
const i = { ...n };
|
|
355
355
|
return (r) => (i.red = Fe(n.red, s.red, r), i.green = Fe(n.green, s.green, r), i.blue = Fe(n.blue, s.blue, r), i.alpha = Q(n.alpha, s.alpha, r), j.transform(i));
|
|
356
356
|
}, Ie = /* @__PURE__ */ new Set(["none", "hidden"]);
|
|
357
|
-
function
|
|
357
|
+
function Zs(e, t) {
|
|
358
358
|
return Ie.has(e) ? (n) => n <= 0 ? e : t : (n) => n >= 1 ? t : e;
|
|
359
359
|
}
|
|
360
|
-
function
|
|
360
|
+
function Hs(e, t) {
|
|
361
361
|
return (n) => Q(e, t, n);
|
|
362
362
|
}
|
|
363
363
|
function it(e) {
|
|
364
|
-
return typeof e == "number" ?
|
|
364
|
+
return typeof e == "number" ? Hs : typeof e == "string" ? tt(e) ? Ve : D.test(e) ? Rt : ei : Array.isArray(e) ? xn : typeof e == "object" ? D.test(e) ? Rt : Js : Ve;
|
|
365
365
|
}
|
|
366
366
|
function xn(e, t) {
|
|
367
367
|
const n = [...e], s = n.length, i = e.map((r, a) => it(r)(r, t[a]));
|
|
@@ -371,7 +371,7 @@ function xn(e, t) {
|
|
|
371
371
|
return n;
|
|
372
372
|
};
|
|
373
373
|
}
|
|
374
|
-
function
|
|
374
|
+
function Js(e, t) {
|
|
375
375
|
const n = { ...e, ...t }, s = {};
|
|
376
376
|
for (const i in n)
|
|
377
377
|
e[i] !== void 0 && t[i] !== void 0 && (s[i] = it(e[i])(e[i], t[i]));
|
|
@@ -381,7 +381,7 @@ function Hs(e, t) {
|
|
|
381
381
|
return n;
|
|
382
382
|
};
|
|
383
383
|
}
|
|
384
|
-
function
|
|
384
|
+
function Qs(e, t) {
|
|
385
385
|
const n = [], s = { color: 0, var: 0, number: 0 };
|
|
386
386
|
for (let i = 0; i < t.values.length; i++) {
|
|
387
387
|
const r = t.types[i], a = e.indexes[r][s[r]], o = e.values[a] ?? 0;
|
|
@@ -389,14 +389,14 @@ function Js(e, t) {
|
|
|
389
389
|
}
|
|
390
390
|
return n;
|
|
391
391
|
}
|
|
392
|
-
const
|
|
392
|
+
const ei = (e, t) => {
|
|
393
393
|
const n = U.createTransformer(t), s = ce(e), i = ce(t);
|
|
394
|
-
return s.indexes.var.length === i.indexes.var.length && s.indexes.color.length === i.indexes.color.length && s.indexes.number.length >= i.indexes.number.length ? Ie.has(e) && !i.values.length || Ie.has(t) && !s.values.length ?
|
|
394
|
+
return s.indexes.var.length === i.indexes.var.length && s.indexes.color.length === i.indexes.color.length && s.indexes.number.length >= i.indexes.number.length ? Ie.has(e) && !i.values.length || Ie.has(t) && !s.values.length ? Zs(e, t) : He(xn(Qs(s, i), i.values), n) : (de(!0, `Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`, "complex-values-different"), Ve(e, t));
|
|
395
395
|
};
|
|
396
396
|
function wn(e, t, n) {
|
|
397
397
|
return typeof e == "number" && typeof t == "number" && typeof n == "number" ? Q(e, t, n) : it(e)(e, t);
|
|
398
398
|
}
|
|
399
|
-
const
|
|
399
|
+
const ti = (e) => {
|
|
400
400
|
const t = ({ timestamp: n }) => e(n);
|
|
401
401
|
return {
|
|
402
402
|
start: (n = !0) => K.update(t, n),
|
|
@@ -413,26 +413,26 @@ const ei = (e) => {
|
|
|
413
413
|
for (let r = 0; r < i; r++)
|
|
414
414
|
s += Math.round(e(r / (i - 1)) * 1e4) / 1e4 + ", ";
|
|
415
415
|
return `linear(${s.substring(0, s.length - 2)})`;
|
|
416
|
-
},
|
|
416
|
+
}, Me = 2e4;
|
|
417
417
|
function rt(e) {
|
|
418
418
|
let t = 0;
|
|
419
419
|
const n = 50;
|
|
420
420
|
let s = e.next(t);
|
|
421
|
-
for (; !s.done && t <
|
|
421
|
+
for (; !s.done && t < Me; )
|
|
422
422
|
t += n, s = e.next(t);
|
|
423
|
-
return t >=
|
|
423
|
+
return t >= Me ? 1 / 0 : t;
|
|
424
424
|
}
|
|
425
425
|
function Dn(e, t = 100, n) {
|
|
426
|
-
const s = n({ ...e, keyframes: [0, t] }), i = Math.min(rt(s),
|
|
426
|
+
const s = n({ ...e, keyframes: [0, t] }), i = Math.min(rt(s), Me);
|
|
427
427
|
return {
|
|
428
428
|
type: "keyframes",
|
|
429
429
|
ease: (r) => s.next(i * r).value / t,
|
|
430
430
|
duration: /* @__PURE__ */ P(i)
|
|
431
431
|
};
|
|
432
432
|
}
|
|
433
|
-
const
|
|
433
|
+
const ni = 5;
|
|
434
434
|
function Fn(e, t, n) {
|
|
435
|
-
const s = Math.max(t -
|
|
435
|
+
const s = Math.max(t - ni, 0);
|
|
436
436
|
return sn(n - e(s), t - s);
|
|
437
437
|
}
|
|
438
438
|
const C = {
|
|
@@ -464,9 +464,9 @@ const C = {
|
|
|
464
464
|
minDamping: 0.05,
|
|
465
465
|
maxDamping: 1
|
|
466
466
|
}, Ee = 1e-3;
|
|
467
|
-
function
|
|
467
|
+
function si({ duration: e = C.duration, bounce: t = C.bounce, velocity: n = C.velocity, mass: s = C.mass }) {
|
|
468
468
|
let i, r;
|
|
469
|
-
de(e <= /* @__PURE__ */
|
|
469
|
+
de(e <= /* @__PURE__ */ k(C.maxDuration), "Spring duration must be 10 seconds or less", "spring-duration-limit");
|
|
470
470
|
let a = 1 - t;
|
|
471
471
|
a = _(C.minDamping, C.maxDamping, a), e = _(C.minDuration, C.maxDuration, /* @__PURE__ */ P(e)), a < 1 ? (i = (c) => {
|
|
472
472
|
const l = c * a, f = l * e, h = l - n, p = Ne(c, a), g = Math.exp(-f);
|
|
@@ -481,8 +481,8 @@ function ni({ duration: e = C.duration, bounce: t = C.bounce, velocity: n = C.ve
|
|
|
481
481
|
const l = Math.exp(-c * e), f = (n - c) * (e * e);
|
|
482
482
|
return l * f;
|
|
483
483
|
});
|
|
484
|
-
const o = 5 / e, u =
|
|
485
|
-
if (e = /* @__PURE__ */
|
|
484
|
+
const o = 5 / e, u = ri(i, r, o);
|
|
485
|
+
if (e = /* @__PURE__ */ k(e), isNaN(u))
|
|
486
486
|
return {
|
|
487
487
|
stiffness: C.stiffness,
|
|
488
488
|
damping: C.damping,
|
|
@@ -497,21 +497,21 @@ function ni({ duration: e = C.duration, bounce: t = C.bounce, velocity: n = C.ve
|
|
|
497
497
|
};
|
|
498
498
|
}
|
|
499
499
|
}
|
|
500
|
-
const
|
|
501
|
-
function
|
|
500
|
+
const ii = 12;
|
|
501
|
+
function ri(e, t, n) {
|
|
502
502
|
let s = n;
|
|
503
|
-
for (let i = 1; i <
|
|
503
|
+
for (let i = 1; i < ii; i++)
|
|
504
504
|
s = s - e(s) / t(s);
|
|
505
505
|
return s;
|
|
506
506
|
}
|
|
507
507
|
function Ne(e, t) {
|
|
508
508
|
return e * Math.sqrt(1 - t * t);
|
|
509
509
|
}
|
|
510
|
-
const
|
|
510
|
+
const ai = ["duration", "bounce"], oi = ["stiffness", "damping", "mass"];
|
|
511
511
|
function Pt(e, t) {
|
|
512
512
|
return t.some((n) => e[n] !== void 0);
|
|
513
513
|
}
|
|
514
|
-
function
|
|
514
|
+
function li(e) {
|
|
515
515
|
let t = {
|
|
516
516
|
velocity: C.velocity,
|
|
517
517
|
stiffness: C.stiffness,
|
|
@@ -520,7 +520,7 @@ function oi(e) {
|
|
|
520
520
|
isResolvedFromDuration: !1,
|
|
521
521
|
...e
|
|
522
522
|
};
|
|
523
|
-
if (!Pt(e,
|
|
523
|
+
if (!Pt(e, oi) && Pt(e, ai))
|
|
524
524
|
if (e.visualDuration) {
|
|
525
525
|
const n = e.visualDuration, s = 2 * Math.PI / (n * 1.2), i = s * s, r = 2 * _(0.05, 1, 1 - (e.bounce || 0)) * Math.sqrt(i);
|
|
526
526
|
t = {
|
|
@@ -530,7 +530,7 @@ function oi(e) {
|
|
|
530
530
|
damping: r
|
|
531
531
|
};
|
|
532
532
|
} else {
|
|
533
|
-
const n =
|
|
533
|
+
const n = si(e);
|
|
534
534
|
t = {
|
|
535
535
|
...t,
|
|
536
536
|
...n,
|
|
@@ -546,7 +546,7 @@ function fe(e = C.visualDuration, t = C.bounce) {
|
|
|
546
546
|
bounce: t
|
|
547
547
|
} : e;
|
|
548
548
|
let { restSpeed: s, restDelta: i } = n;
|
|
549
|
-
const r = n.keyframes[0], a = n.keyframes[n.keyframes.length - 1], o = { done: !1, value: r }, { stiffness: u, damping: c, mass: l, duration: f, velocity: h, isResolvedFromDuration: p } =
|
|
549
|
+
const r = n.keyframes[0], a = n.keyframes[n.keyframes.length - 1], o = { done: !1, value: r }, { stiffness: u, damping: c, mass: l, duration: f, velocity: h, isResolvedFromDuration: p } = li({
|
|
550
550
|
...n,
|
|
551
551
|
velocity: -/* @__PURE__ */ P(n.velocity || 0)
|
|
552
552
|
}), g = h || 0, y = c / (2 * Math.sqrt(u * l)), S = a - r, v = /* @__PURE__ */ P(Math.sqrt(u / l)), w = Math.abs(S) < 5;
|
|
@@ -567,7 +567,7 @@ function fe(e = C.visualDuration, t = C.bounce) {
|
|
|
567
567
|
return a - x * ((g + y * v * S) * Math.sinh(T) + m * S * Math.cosh(T)) / m;
|
|
568
568
|
};
|
|
569
569
|
}
|
|
570
|
-
const
|
|
570
|
+
const M = {
|
|
571
571
|
calculatedDuration: p && f || null,
|
|
572
572
|
next: (m) => {
|
|
573
573
|
const b = V(m);
|
|
@@ -575,24 +575,24 @@ function fe(e = C.visualDuration, t = C.bounce) {
|
|
|
575
575
|
o.done = m >= f;
|
|
576
576
|
else {
|
|
577
577
|
let x = m === 0 ? g : 0;
|
|
578
|
-
y < 1 && (x = m === 0 ? /* @__PURE__ */
|
|
579
|
-
const T = Math.abs(x) <= s,
|
|
580
|
-
o.done = T &&
|
|
578
|
+
y < 1 && (x = m === 0 ? /* @__PURE__ */ k(g) : Fn(V, m, b));
|
|
579
|
+
const T = Math.abs(x) <= s, A = Math.abs(a - b) <= i;
|
|
580
|
+
o.done = T && A;
|
|
581
581
|
}
|
|
582
582
|
return o.value = o.done ? a : b, o;
|
|
583
583
|
},
|
|
584
584
|
toString: () => {
|
|
585
|
-
const m = Math.min(rt(
|
|
585
|
+
const m = Math.min(rt(M), Me), b = Cn((x) => M.next(m * x).value, m, 30);
|
|
586
586
|
return m + "ms " + b;
|
|
587
587
|
},
|
|
588
588
|
toTransition: () => {
|
|
589
589
|
}
|
|
590
590
|
};
|
|
591
|
-
return
|
|
591
|
+
return M;
|
|
592
592
|
}
|
|
593
593
|
fe.applyToOptions = (e) => {
|
|
594
594
|
const t = Dn(e, 100, fe);
|
|
595
|
-
return e.ease = t.ease, e.duration = /* @__PURE__ */
|
|
595
|
+
return e.ease = t.ease, e.duration = /* @__PURE__ */ k(t.duration), e.type = "keyframes", e;
|
|
596
596
|
};
|
|
597
597
|
function Ke({ keyframes: e, velocity: t = 0, power: n = 0.8, timeConstant: s = 325, bounceDamping: i = 10, bounceStiffness: r = 500, modifyTarget: a, min: o, max: u, restDelta: c = 0.5, restSpeed: l }) {
|
|
598
598
|
const f = e[0], h = {
|
|
@@ -602,9 +602,9 @@ function Ke({ keyframes: e, velocity: t = 0, power: n = 0.8, timeConstant: s = 3
|
|
|
602
602
|
let y = n * t;
|
|
603
603
|
const S = f + y, v = a === void 0 ? S : a(S);
|
|
604
604
|
v !== S && (y = v - f);
|
|
605
|
-
const w = (T) => -y * Math.exp(-T / s), V = (T) => v + w(T),
|
|
606
|
-
const
|
|
607
|
-
h.done = Math.abs(
|
|
605
|
+
const w = (T) => -y * Math.exp(-T / s), V = (T) => v + w(T), M = (T) => {
|
|
606
|
+
const A = w(T), F = V(T);
|
|
607
|
+
h.done = Math.abs(A) <= c, h.value = h.done ? v : F;
|
|
608
608
|
};
|
|
609
609
|
let m, b;
|
|
610
610
|
const x = (T) => {
|
|
@@ -621,12 +621,12 @@ function Ke({ keyframes: e, velocity: t = 0, power: n = 0.8, timeConstant: s = 3
|
|
|
621
621
|
return x(0), {
|
|
622
622
|
calculatedDuration: null,
|
|
623
623
|
next: (T) => {
|
|
624
|
-
let
|
|
625
|
-
return !b && m === void 0 && (
|
|
624
|
+
let A = !1;
|
|
625
|
+
return !b && m === void 0 && (A = !0, M(T), x(T)), m !== void 0 && T >= m ? b.next(T - m) : (!A && M(T), h);
|
|
626
626
|
}
|
|
627
627
|
};
|
|
628
628
|
}
|
|
629
|
-
function
|
|
629
|
+
function ui(e, t, n) {
|
|
630
630
|
const s = [], i = n || N.mix || wn, r = e.length - 1;
|
|
631
631
|
for (let a = 0; a < r; a++) {
|
|
632
632
|
let o = i(e[a], e[a + 1]);
|
|
@@ -638,7 +638,7 @@ function li(e, t, n) {
|
|
|
638
638
|
}
|
|
639
639
|
return s;
|
|
640
640
|
}
|
|
641
|
-
function
|
|
641
|
+
function ci(e, t, { clamp: n = !0, ease: s, mixer: i } = {}) {
|
|
642
642
|
const r = e.length;
|
|
643
643
|
if (I(r === t.length, "Both input and output ranges must be the same length", "range-length"), r === 1)
|
|
644
644
|
return () => t[0];
|
|
@@ -646,7 +646,7 @@ function ui(e, t, { clamp: n = !0, ease: s, mixer: i } = {}) {
|
|
|
646
646
|
return () => t[1];
|
|
647
647
|
const a = e[0] === e[1];
|
|
648
648
|
e[0] > e[r - 1] && (e = [...e].reverse(), t = [...t].reverse());
|
|
649
|
-
const o =
|
|
649
|
+
const o = ui(t, s, i), u = o.length, c = (l) => {
|
|
650
650
|
if (a && l < e[0])
|
|
651
651
|
return t[0];
|
|
652
652
|
let f = 0;
|
|
@@ -669,35 +669,35 @@ function Rn(e) {
|
|
|
669
669
|
const t = [0];
|
|
670
670
|
return En(t, e.length - 1), t;
|
|
671
671
|
}
|
|
672
|
-
function
|
|
672
|
+
function fi(e, t) {
|
|
673
673
|
return e.map((n) => n * t);
|
|
674
674
|
}
|
|
675
|
-
function
|
|
675
|
+
function hi(e, t) {
|
|
676
676
|
return e.map(() => t || dn).splice(0, e.length - 1);
|
|
677
677
|
}
|
|
678
678
|
function X({ duration: e = 300, keyframes: t, times: n, ease: s = "easeInOut" }) {
|
|
679
679
|
const i = pn(s) ? s.map(wt) : wt(s), r = {
|
|
680
680
|
done: !1,
|
|
681
681
|
value: t[0]
|
|
682
|
-
}, a =
|
|
682
|
+
}, a = fi(
|
|
683
683
|
// Only use the provided offsets if they're the correct length
|
|
684
684
|
// TODO Maybe we should warn here if there's a length mismatch
|
|
685
685
|
n && n.length === t.length ? n : Rn(t),
|
|
686
686
|
e
|
|
687
|
-
), o =
|
|
688
|
-
ease: Array.isArray(i) ? i :
|
|
687
|
+
), o = ci(a, t, {
|
|
688
|
+
ease: Array.isArray(i) ? i : hi(t, i)
|
|
689
689
|
});
|
|
690
690
|
return {
|
|
691
691
|
calculatedDuration: e,
|
|
692
692
|
next: (u) => (r.value = o(u), r.done = u >= e, r)
|
|
693
693
|
};
|
|
694
694
|
}
|
|
695
|
-
const
|
|
695
|
+
const di = (e) => e !== null;
|
|
696
696
|
function at(e, { repeat: t, repeatType: n = "loop" }, s, i = 1) {
|
|
697
|
-
const r = e.filter(
|
|
697
|
+
const r = e.filter(di), o = i < 0 || t && n !== "loop" && t % 2 === 1 ? 0 : r.length - 1;
|
|
698
698
|
return !o || s === void 0 ? r[o] : s;
|
|
699
699
|
}
|
|
700
|
-
const
|
|
700
|
+
const pi = {
|
|
701
701
|
decay: Ke,
|
|
702
702
|
inertia: Ke,
|
|
703
703
|
tween: X,
|
|
@@ -705,7 +705,7 @@ const di = {
|
|
|
705
705
|
spring: fe
|
|
706
706
|
};
|
|
707
707
|
function Pn(e) {
|
|
708
|
-
typeof e.type == "string" && (e.type =
|
|
708
|
+
typeof e.type == "string" && (e.type = pi[e.type]);
|
|
709
709
|
}
|
|
710
710
|
class ot {
|
|
711
711
|
constructor() {
|
|
@@ -731,7 +731,7 @@ class ot {
|
|
|
731
731
|
return this.finished.then(t, n);
|
|
732
732
|
}
|
|
733
733
|
}
|
|
734
|
-
const
|
|
734
|
+
const mi = (e) => e / 100;
|
|
735
735
|
class lt extends ot {
|
|
736
736
|
constructor(t) {
|
|
737
737
|
super(), this.state = "idle", this.startTime = null, this.isStopped = !1, this.currentTime = 0, this.holdTime = null, this.playbackSpeed = 1, this.stop = () => {
|
|
@@ -745,7 +745,7 @@ class lt extends ot {
|
|
|
745
745
|
const { type: n = X, repeat: s = 0, repeatDelay: i = 0, repeatType: r, velocity: a = 0 } = t;
|
|
746
746
|
let { keyframes: o } = t;
|
|
747
747
|
const u = n || X;
|
|
748
|
-
process.env.NODE_ENV !== "production" && u !== X && I(o.length <= 2, `Only two keyframes currently supported with spring and inertia animations. Trying to animate ${o}`, "spring-two-frames"), u !== X && typeof o[0] != "number" && (this.mixKeyframes = He(
|
|
748
|
+
process.env.NODE_ENV !== "production" && u !== X && I(o.length <= 2, `Only two keyframes currently supported with spring and inertia animations. Trying to animate ${o}`, "spring-two-frames"), u !== X && typeof o[0] != "number" && (this.mixKeyframes = He(mi, wn(o[0], o[1])), o = [0, 100]);
|
|
749
749
|
const c = u({ ...t, keyframes: o });
|
|
750
750
|
r === "mirror" && (this.mirroredGenerator = u({
|
|
751
751
|
...t,
|
|
@@ -767,13 +767,13 @@ class lt extends ot {
|
|
|
767
767
|
this.speed > 0 ? this.startTime = Math.min(this.startTime, t) : this.speed < 0 && (this.startTime = Math.min(t - i / this.speed, this.startTime)), n ? this.currentTime = t : this.updateTime(t);
|
|
768
768
|
const v = this.currentTime - c * (this.playbackSpeed >= 0 ? 1 : -1), w = this.playbackSpeed >= 0 ? v < 0 : v > i;
|
|
769
769
|
this.currentTime = Math.max(v, 0), this.state === "finished" && this.holdTime === null && (this.currentTime = i);
|
|
770
|
-
let V = this.currentTime,
|
|
770
|
+
let V = this.currentTime, M = s;
|
|
771
771
|
if (f) {
|
|
772
772
|
const T = Math.min(this.currentTime, i) / o;
|
|
773
|
-
let
|
|
774
|
-
!F && T >= 1 && (F = 1), F === 1 &&
|
|
773
|
+
let A = Math.floor(T), F = T % 1;
|
|
774
|
+
!F && T >= 1 && (F = 1), F === 1 && A--, A = Math.min(A, f + 1), A % 2 && (h === "reverse" ? (F = 1 - F, p && (F -= p / o)) : h === "mirror" && (M = a)), V = _(0, 1, F) * o;
|
|
775
775
|
}
|
|
776
|
-
const m = w ? { done: !1, value: l[0] } :
|
|
776
|
+
const m = w ? { done: !1, value: l[0] } : M.next(V);
|
|
777
777
|
r && (m.value = r(m.value));
|
|
778
778
|
let { done: b } = m;
|
|
779
779
|
!w && u !== null && (b = this.playbackSpeed >= 0 ? this.currentTime >= i : this.currentTime <= 0);
|
|
@@ -799,7 +799,7 @@ class lt extends ot {
|
|
|
799
799
|
return /* @__PURE__ */ P(this.currentTime);
|
|
800
800
|
}
|
|
801
801
|
set time(t) {
|
|
802
|
-
t = /* @__PURE__ */
|
|
802
|
+
t = /* @__PURE__ */ k(t), this.currentTime = t, this.startTime === null || this.holdTime !== null || this.playbackSpeed === 0 ? this.holdTime = t : this.driver && (this.startTime = this.driver.now() - t / this.playbackSpeed), this.driver?.start(!1);
|
|
803
803
|
}
|
|
804
804
|
get speed() {
|
|
805
805
|
return this.playbackSpeed;
|
|
@@ -812,7 +812,7 @@ class lt extends ot {
|
|
|
812
812
|
play() {
|
|
813
813
|
if (this.isStopped)
|
|
814
814
|
return;
|
|
815
|
-
const { driver: t =
|
|
815
|
+
const { driver: t = ti, startTime: n } = this.options;
|
|
816
816
|
this.driver || (this.driver = t((i) => this.tick(i))), this.options.onPlay?.();
|
|
817
817
|
const s = this.driver.now();
|
|
818
818
|
this.state === "finished" ? (this.updateFinished(), this.startTime = s) : this.holdTime !== null ? this.startTime = s - this.holdTime : this.startTime || (this.startTime = n ?? s), this.state === "finished" && this.speed < 0 && (this.startTime += this.calculatedDuration), this.holdTime = null, this.state = "running", this.driver.start();
|
|
@@ -842,14 +842,14 @@ class lt extends ot {
|
|
|
842
842
|
return this.options.allowFlatten && (this.options.type = "keyframes", this.options.ease = "linear", this.initAnimation()), this.driver?.stop(), t.observe(this);
|
|
843
843
|
}
|
|
844
844
|
}
|
|
845
|
-
function
|
|
845
|
+
function gi(e) {
|
|
846
846
|
for (let t = 1; t < e.length; t++)
|
|
847
847
|
e[t] ?? (e[t] = e[t - 1]);
|
|
848
848
|
}
|
|
849
849
|
const G = (e) => e * 180 / Math.PI, $e = (e) => {
|
|
850
850
|
const t = G(Math.atan2(e[1], e[0]));
|
|
851
851
|
return Le(t);
|
|
852
|
-
},
|
|
852
|
+
}, yi = {
|
|
853
853
|
x: 4,
|
|
854
854
|
y: 5,
|
|
855
855
|
translateX: 4,
|
|
@@ -862,7 +862,7 @@ const G = (e) => e * 180 / Math.PI, $e = (e) => {
|
|
|
862
862
|
skewX: (e) => G(Math.atan(e[1])),
|
|
863
863
|
skewY: (e) => G(Math.atan(e[2])),
|
|
864
864
|
skew: (e) => (Math.abs(e[1]) + Math.abs(e[2])) / 2
|
|
865
|
-
}, Le = (e) => (e = e % 360, e < 0 && (e += 360), e), kt = $e, Ot = (e) => Math.sqrt(e[0] * e[0] + e[1] * e[1]), Bt = (e) => Math.sqrt(e[4] * e[4] + e[5] * e[5]),
|
|
865
|
+
}, Le = (e) => (e = e % 360, e < 0 && (e += 360), e), kt = $e, Ot = (e) => Math.sqrt(e[0] * e[0] + e[1] * e[1]), Bt = (e) => Math.sqrt(e[4] * e[4] + e[5] * e[5]), bi = {
|
|
866
866
|
x: 12,
|
|
867
867
|
y: 13,
|
|
868
868
|
z: 14,
|
|
@@ -889,21 +889,21 @@ function _e(e, t) {
|
|
|
889
889
|
const n = e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);
|
|
890
890
|
let s, i;
|
|
891
891
|
if (n)
|
|
892
|
-
s =
|
|
892
|
+
s = bi, i = n;
|
|
893
893
|
else {
|
|
894
894
|
const o = e.match(/^matrix\(([-\d.e\s,]+)\)$/u);
|
|
895
|
-
s =
|
|
895
|
+
s = yi, i = o;
|
|
896
896
|
}
|
|
897
897
|
if (!i)
|
|
898
898
|
return We(t);
|
|
899
|
-
const r = s[t], a = i[1].split(",").map(
|
|
899
|
+
const r = s[t], a = i[1].split(",").map(vi);
|
|
900
900
|
return typeof r == "function" ? r(a) : a[r];
|
|
901
901
|
}
|
|
902
|
-
const
|
|
902
|
+
const Ti = (e, t) => {
|
|
903
903
|
const { transform: n = "none" } = getComputedStyle(e);
|
|
904
904
|
return _e(n, t);
|
|
905
905
|
};
|
|
906
|
-
function
|
|
906
|
+
function vi(e) {
|
|
907
907
|
return parseFloat(e.trim());
|
|
908
908
|
}
|
|
909
909
|
const ee = [
|
|
@@ -924,10 +924,10 @@ const ee = [
|
|
|
924
924
|
"skew",
|
|
925
925
|
"skewX",
|
|
926
926
|
"skewY"
|
|
927
|
-
], te = new Set(ee), It = (e) => e === J || e === d,
|
|
928
|
-
function
|
|
927
|
+
], te = new Set(ee), It = (e) => e === J || e === d, Si = /* @__PURE__ */ new Set(["x", "y", "z"]), Vi = ee.filter((e) => !Si.has(e));
|
|
928
|
+
function Mi(e) {
|
|
929
929
|
const t = [];
|
|
930
|
-
return
|
|
930
|
+
return Vi.forEach((n) => {
|
|
931
931
|
const s = e.getValue(n);
|
|
932
932
|
s !== void 0 && (t.push([n, s.get()]), s.set(n.startsWith("scale") ? 1 : 0));
|
|
933
933
|
}), t;
|
|
@@ -952,7 +952,7 @@ function kn() {
|
|
|
952
952
|
if (je) {
|
|
953
953
|
const e = Array.from(Y).filter((s) => s.needsMeasurement), t = new Set(e.map((s) => s.element)), n = /* @__PURE__ */ new Map();
|
|
954
954
|
t.forEach((s) => {
|
|
955
|
-
const i =
|
|
955
|
+
const i = Mi(s);
|
|
956
956
|
i.length && (n.set(s, i), s.render());
|
|
957
957
|
}), e.forEach((s) => s.measureInitialState()), t.forEach((s) => {
|
|
958
958
|
s.render();
|
|
@@ -993,7 +993,7 @@ class ut {
|
|
|
993
993
|
}
|
|
994
994
|
t[0] === void 0 && (t[0] = a), i && r === void 0 && i.set(t[0]);
|
|
995
995
|
}
|
|
996
|
-
|
|
996
|
+
gi(t);
|
|
997
997
|
}
|
|
998
998
|
setFinalKeyframe() {
|
|
999
999
|
}
|
|
@@ -1013,16 +1013,16 @@ class ut {
|
|
|
1013
1013
|
this.state === "pending" && this.scheduleResolve();
|
|
1014
1014
|
}
|
|
1015
1015
|
}
|
|
1016
|
-
const
|
|
1017
|
-
function
|
|
1018
|
-
|
|
1016
|
+
const xi = (e) => e.startsWith("--");
|
|
1017
|
+
function wi(e, t, n) {
|
|
1018
|
+
xi(t) ? e.style.setProperty(t, n) : e.style[t] = n;
|
|
1019
1019
|
}
|
|
1020
|
-
const
|
|
1021
|
-
function
|
|
1020
|
+
const Ci = /* @__PURE__ */ Ze(() => window.ScrollTimeline !== void 0), Di = {};
|
|
1021
|
+
function Fi(e, t) {
|
|
1022
1022
|
const n = /* @__PURE__ */ Ze(e);
|
|
1023
|
-
return () =>
|
|
1023
|
+
return () => Di[t] ?? n();
|
|
1024
1024
|
}
|
|
1025
|
-
const Bn = /* @__PURE__ */
|
|
1025
|
+
const Bn = /* @__PURE__ */ Fi(() => {
|
|
1026
1026
|
try {
|
|
1027
1027
|
document.createElement("div").animate({ opacity: 0 }, { easing: "linear(0, 1)" });
|
|
1028
1028
|
} catch {
|
|
@@ -1044,7 +1044,7 @@ function In(e, t) {
|
|
|
1044
1044
|
if (e)
|
|
1045
1045
|
return typeof e == "function" ? Bn() ? Cn(e, t) : "ease-out" : gn(e) ? oe(e) : Array.isArray(e) ? e.map((n) => In(n, t) || Nt.easeOut) : Nt[e];
|
|
1046
1046
|
}
|
|
1047
|
-
function
|
|
1047
|
+
function Ei(e, t, n, { delay: s = 0, duration: i = 300, repeat: r = 0, repeatType: a = "loop", ease: o = "easeOut", times: u } = {}, c = void 0) {
|
|
1048
1048
|
const l = {
|
|
1049
1049
|
[t]: n
|
|
1050
1050
|
};
|
|
@@ -1064,20 +1064,20 @@ function Fi(e, t, n, { delay: s = 0, duration: i = 300, repeat: r = 0, repeatTyp
|
|
|
1064
1064
|
function ct(e) {
|
|
1065
1065
|
return typeof e == "function" && "applyToOptions" in e;
|
|
1066
1066
|
}
|
|
1067
|
-
function
|
|
1067
|
+
function Ri({ type: e, ...t }) {
|
|
1068
1068
|
return ct(e) && Bn() ? e.applyToOptions(t) : (t.duration ?? (t.duration = 300), t.ease ?? (t.ease = "easeOut"), t);
|
|
1069
1069
|
}
|
|
1070
|
-
class
|
|
1070
|
+
class Nn extends ot {
|
|
1071
1071
|
constructor(t) {
|
|
1072
1072
|
if (super(), this.finishedTime = null, this.isStopped = !1, this.manualStartTime = null, !t)
|
|
1073
1073
|
return;
|
|
1074
1074
|
const { element: n, name: s, keyframes: i, pseudoElement: r, allowFlatten: a = !1, finalKeyframe: o, onComplete: u } = t;
|
|
1075
1075
|
this.isPseudoElement = !!r, this.allowFlatten = a, this.options = t, I(typeof t.type != "string", `Mini animate() doesn't support "type" as a string.`, "mini-spring");
|
|
1076
|
-
const c =
|
|
1077
|
-
this.animation =
|
|
1076
|
+
const c = Ri(t);
|
|
1077
|
+
this.animation = Ei(n, s, i, c, r), c.autoplay === !1 && this.animation.pause(), this.animation.onfinish = () => {
|
|
1078
1078
|
if (this.finishedTime = this.time, !r) {
|
|
1079
1079
|
const l = at(i, this.options, o, this.speed);
|
|
1080
|
-
this.updateMotionValue ? this.updateMotionValue(l) :
|
|
1080
|
+
this.updateMotionValue ? this.updateMotionValue(l) : wi(n, s, l), this.animation.cancel();
|
|
1081
1081
|
}
|
|
1082
1082
|
u?.(), this.notifyFinished();
|
|
1083
1083
|
};
|
|
@@ -1132,7 +1132,7 @@ class Ri extends ot {
|
|
|
1132
1132
|
return /* @__PURE__ */ P(Number(this.animation.currentTime) || 0);
|
|
1133
1133
|
}
|
|
1134
1134
|
set time(t) {
|
|
1135
|
-
this.manualStartTime = null, this.finishedTime = null, this.animation.currentTime = /* @__PURE__ */
|
|
1135
|
+
this.manualStartTime = null, this.finishedTime = null, this.animation.currentTime = /* @__PURE__ */ k(t);
|
|
1136
1136
|
}
|
|
1137
1137
|
/**
|
|
1138
1138
|
* The playback speed of the animation.
|
|
@@ -1157,22 +1157,22 @@ class Ri extends ot {
|
|
|
1157
1157
|
* Attaches a timeline to the animation, for instance the `ScrollTimeline`.
|
|
1158
1158
|
*/
|
|
1159
1159
|
attachTimeline({ timeline: t, observe: n }) {
|
|
1160
|
-
return this.allowFlatten && this.animation.effect?.updateTiming({ easing: "linear" }), this.animation.onfinish = null, t &&
|
|
1160
|
+
return this.allowFlatten && this.animation.effect?.updateTiming({ easing: "linear" }), this.animation.onfinish = null, t && Ci() ? (this.animation.timeline = t, H) : n(this);
|
|
1161
1161
|
}
|
|
1162
1162
|
}
|
|
1163
|
-
const
|
|
1163
|
+
const Kn = {
|
|
1164
1164
|
anticipate: fn,
|
|
1165
1165
|
backInOut: cn,
|
|
1166
1166
|
circInOut: hn
|
|
1167
1167
|
};
|
|
1168
1168
|
function Pi(e) {
|
|
1169
|
-
return e in
|
|
1169
|
+
return e in Kn;
|
|
1170
1170
|
}
|
|
1171
1171
|
function ki(e) {
|
|
1172
|
-
typeof e.ease == "string" && Pi(e.ease) && (e.ease =
|
|
1172
|
+
typeof e.ease == "string" && Pi(e.ease) && (e.ease = Kn[e.ease]);
|
|
1173
1173
|
}
|
|
1174
1174
|
const Re = 10;
|
|
1175
|
-
class Oi extends
|
|
1175
|
+
class Oi extends Nn {
|
|
1176
1176
|
constructor(t) {
|
|
1177
1177
|
ki(t), Pn(t), super(t), t.startTime !== void 0 && (this.startTime = t.startTime), this.options = t;
|
|
1178
1178
|
}
|
|
@@ -1419,7 +1419,7 @@ function Gi(e) {
|
|
|
1419
1419
|
return [`--${n ?? s}`, i];
|
|
1420
1420
|
}
|
|
1421
1421
|
const Yi = 4;
|
|
1422
|
-
function
|
|
1422
|
+
function $n(e, t, n = 1) {
|
|
1423
1423
|
I(n <= Yi, `Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`, "max-css-var-depth");
|
|
1424
1424
|
const [s, i] = Gi(e);
|
|
1425
1425
|
if (!s)
|
|
@@ -1429,7 +1429,7 @@ function Kn(e, t, n = 1) {
|
|
|
1429
1429
|
const a = r.trim();
|
|
1430
1430
|
return en(a) ? parseFloat(a) : a;
|
|
1431
1431
|
}
|
|
1432
|
-
return tt(i) ?
|
|
1432
|
+
return tt(i) ? $n(i, t, n + 1) : i;
|
|
1433
1433
|
}
|
|
1434
1434
|
const zi = {
|
|
1435
1435
|
type: "spring",
|
|
@@ -1453,24 +1453,24 @@ function Qi(e, { repeat: t, repeatType: n = "loop" }, s) {
|
|
|
1453
1453
|
const i = e.filter(Ji), r = t && n !== "loop" && t % 2 === 1 ? 0 : i.length - 1;
|
|
1454
1454
|
return i[r];
|
|
1455
1455
|
}
|
|
1456
|
-
function
|
|
1456
|
+
function Ln(e, t) {
|
|
1457
1457
|
if (e?.inherit && t) {
|
|
1458
1458
|
const { inherit: n, ...s } = e;
|
|
1459
1459
|
return { ...t, ...s };
|
|
1460
1460
|
}
|
|
1461
1461
|
return e;
|
|
1462
1462
|
}
|
|
1463
|
-
function
|
|
1463
|
+
function Wn(e, t) {
|
|
1464
1464
|
const n = e?.[t] ?? e?.default ?? e;
|
|
1465
|
-
return n !== e ?
|
|
1465
|
+
return n !== e ? Ln(n, e) : n;
|
|
1466
1466
|
}
|
|
1467
1467
|
function er({ when: e, delay: t, delayChildren: n, staggerChildren: s, staggerDirection: i, repeat: r, repeatType: a, repeatDelay: o, from: u, elapsed: c, ...l }) {
|
|
1468
1468
|
return !!Object.keys(l).length;
|
|
1469
1469
|
}
|
|
1470
|
-
const
|
|
1471
|
-
const o =
|
|
1470
|
+
const _n = (e, t, n, s = {}, i, r) => (a) => {
|
|
1471
|
+
const o = Wn(s, e) || {}, u = o.delay || s.delay || 0;
|
|
1472
1472
|
let { elapsed: c = 0 } = s;
|
|
1473
|
-
c = c - /* @__PURE__ */
|
|
1473
|
+
c = c - /* @__PURE__ */ k(u);
|
|
1474
1474
|
const l = {
|
|
1475
1475
|
keyframes: Array.isArray(n) ? n : [null, n],
|
|
1476
1476
|
ease: "easeOut",
|
|
@@ -1487,7 +1487,7 @@ const Wn = (e, t, n, s = {}, i, r) => (a) => {
|
|
|
1487
1487
|
motionValue: t,
|
|
1488
1488
|
element: r ? void 0 : i
|
|
1489
1489
|
};
|
|
1490
|
-
er(o) || Object.assign(l, Hi(e, l)), l.duration && (l.duration = /* @__PURE__ */
|
|
1490
|
+
er(o) || Object.assign(l, Hi(e, l)), l.duration && (l.duration = /* @__PURE__ */ k(l.duration)), l.repeatDelay && (l.repeatDelay = /* @__PURE__ */ k(l.repeatDelay)), l.from !== void 0 && (l.keyframes[0] = l.from);
|
|
1491
1491
|
let f = !1;
|
|
1492
1492
|
if ((l.type === !1 || l.duration === 0 && !l.repeatDelay) && (Ye(l), l.delay === 0 && (f = !0)), (N.instantAnimations || N.skipAnimations || i?.shouldSkipAnimations) && (f = !0, Ye(l), l.delay = 0), l.allowFlatten = !o.type && !o.ease, f && !r && t.get() !== void 0) {
|
|
1493
1493
|
const h = Qi(l.keyframes, o);
|
|
@@ -1506,7 +1506,7 @@ function Lt(e) {
|
|
|
1506
1506
|
t[0][s] = n.get(), t[1][s] = n.getVelocity();
|
|
1507
1507
|
}), t;
|
|
1508
1508
|
}
|
|
1509
|
-
function
|
|
1509
|
+
function Un(e, t, n, s) {
|
|
1510
1510
|
if (typeof t == "function") {
|
|
1511
1511
|
const [i, r] = Lt(s);
|
|
1512
1512
|
t = t(n !== void 0 ? n : e.custom, i, r);
|
|
@@ -1519,9 +1519,9 @@ function _n(e, t, n, s) {
|
|
|
1519
1519
|
}
|
|
1520
1520
|
function tr(e, t, n) {
|
|
1521
1521
|
const s = e.getProps();
|
|
1522
|
-
return
|
|
1522
|
+
return Un(s, t, s.custom, e);
|
|
1523
1523
|
}
|
|
1524
|
-
const
|
|
1524
|
+
const jn = /* @__PURE__ */ new Set([
|
|
1525
1525
|
"width",
|
|
1526
1526
|
"height",
|
|
1527
1527
|
"top",
|
|
@@ -1775,7 +1775,7 @@ function dr({ protectedKeys: e, needsAnimating: t }, n) {
|
|
|
1775
1775
|
function pr(e, t, { delay: n = 0, transitionOverride: s, type: i } = {}) {
|
|
1776
1776
|
let { transition: r, transitionEnd: a, ...o } = t;
|
|
1777
1777
|
const u = e.getDefaultTransition();
|
|
1778
|
-
r = r ?
|
|
1778
|
+
r = r ? Ln(r, u) : u;
|
|
1779
1779
|
const c = r?.reduceMotion;
|
|
1780
1780
|
s && (r = s);
|
|
1781
1781
|
const l = [], f = i && e.animationState && e.animationState.getState()[i];
|
|
@@ -1785,21 +1785,21 @@ function pr(e, t, { delay: n = 0, transitionOverride: s, type: i } = {}) {
|
|
|
1785
1785
|
continue;
|
|
1786
1786
|
const y = {
|
|
1787
1787
|
delay: n,
|
|
1788
|
-
...
|
|
1788
|
+
...Wn(r || {}, h)
|
|
1789
1789
|
}, S = p.get();
|
|
1790
1790
|
if (S !== void 0 && !p.isAnimating && !Array.isArray(g) && g === S && !y.velocity)
|
|
1791
1791
|
continue;
|
|
1792
1792
|
let v = !1;
|
|
1793
1793
|
if (window.MotionHandoffAnimation) {
|
|
1794
|
-
const
|
|
1795
|
-
if (
|
|
1796
|
-
const m = window.MotionHandoffAnimation(
|
|
1794
|
+
const M = hr(e);
|
|
1795
|
+
if (M) {
|
|
1796
|
+
const m = window.MotionHandoffAnimation(M, h, K);
|
|
1797
1797
|
m !== null && (y.startTime = m, v = !0);
|
|
1798
1798
|
}
|
|
1799
1799
|
}
|
|
1800
1800
|
ur(e, h);
|
|
1801
1801
|
const w = c ?? e.shouldReduceMotion;
|
|
1802
|
-
p.start(
|
|
1802
|
+
p.start(_n(h, p, g, w && jn.has(h) ? { type: !1 } : y, e, v));
|
|
1803
1803
|
const V = p.animation;
|
|
1804
1804
|
V && l.push(V);
|
|
1805
1805
|
}
|
|
@@ -1814,7 +1814,7 @@ function pr(e, t, { delay: n = 0, transitionOverride: s, type: i } = {}) {
|
|
|
1814
1814
|
const mr = {
|
|
1815
1815
|
test: (e) => e === "auto",
|
|
1816
1816
|
parse: (e) => e
|
|
1817
|
-
},
|
|
1817
|
+
}, Gn = (e) => (t) => t.test(e), Yn = [J, d, q, L, $s, Ks, mr], _t = (e) => Yn.find(Gn(e));
|
|
1818
1818
|
function gr(e) {
|
|
1819
1819
|
return typeof e == "number" ? e === 0 : e !== null ? e === "none" || e === "0" || tn(e) : !0;
|
|
1820
1820
|
}
|
|
@@ -1942,13 +1942,13 @@ const Tr = /\b([a-z-]*)\(.*?\)/gu, ze = {
|
|
|
1942
1942
|
borderLeftColor: D,
|
|
1943
1943
|
filter: ze,
|
|
1944
1944
|
WebkitFilter: ze
|
|
1945
|
-
},
|
|
1946
|
-
function
|
|
1947
|
-
let n =
|
|
1945
|
+
}, zn = (e) => Sr[e];
|
|
1946
|
+
function Xn(e, t) {
|
|
1947
|
+
let n = zn(e);
|
|
1948
1948
|
return n !== ze && (n = U), n.getAnimatableNone ? n.getAnimatableNone(t) : void 0;
|
|
1949
1949
|
}
|
|
1950
1950
|
const Vr = /* @__PURE__ */ new Set(["auto", "none", "0"]);
|
|
1951
|
-
function
|
|
1951
|
+
function Mr(e, t, n) {
|
|
1952
1952
|
let s = 0, i;
|
|
1953
1953
|
for (; s < e.length && !i; ) {
|
|
1954
1954
|
const r = e[s];
|
|
@@ -1956,9 +1956,9 @@ function Ar(e, t, n) {
|
|
|
1956
1956
|
}
|
|
1957
1957
|
if (i && n)
|
|
1958
1958
|
for (const r of t)
|
|
1959
|
-
e[r] =
|
|
1959
|
+
e[r] = Xn(n, i);
|
|
1960
1960
|
}
|
|
1961
|
-
class
|
|
1961
|
+
class Ar extends ut {
|
|
1962
1962
|
constructor(t, n, s, i, r) {
|
|
1963
1963
|
super(t, n, s, i, r, !0);
|
|
1964
1964
|
}
|
|
@@ -1970,11 +1970,11 @@ class Mr extends ut {
|
|
|
1970
1970
|
for (let l = 0; l < t.length; l++) {
|
|
1971
1971
|
let f = t[l];
|
|
1972
1972
|
if (typeof f == "string" && (f = f.trim(), tt(f))) {
|
|
1973
|
-
const h =
|
|
1973
|
+
const h = $n(f, n.current);
|
|
1974
1974
|
h !== void 0 && (t[l] = h), l === t.length - 1 && (this.finalKeyframe = f);
|
|
1975
1975
|
}
|
|
1976
1976
|
}
|
|
1977
|
-
if (this.resolveNoneKeyframes(), !
|
|
1977
|
+
if (this.resolveNoneKeyframes(), !jn.has(s) || t.length !== 2)
|
|
1978
1978
|
return;
|
|
1979
1979
|
const [i, r] = t, a = _t(i), o = _t(r), u = Ct(i), c = Ct(r);
|
|
1980
1980
|
if (u !== c && W[s]) {
|
|
@@ -1993,7 +1993,7 @@ class Mr extends ut {
|
|
|
1993
1993
|
const { unresolvedKeyframes: t, name: n } = this, s = [];
|
|
1994
1994
|
for (let i = 0; i < t.length; i++)
|
|
1995
1995
|
(t[i] === null || gr(t[i])) && s.push(i);
|
|
1996
|
-
s.length &&
|
|
1996
|
+
s.length && Mr(t, s, n);
|
|
1997
1997
|
}
|
|
1998
1998
|
measureInitialState() {
|
|
1999
1999
|
const { element: t, unresolvedKeyframes: n, name: s } = this;
|
|
@@ -2015,7 +2015,16 @@ class Mr extends ut {
|
|
|
2015
2015
|
}), this.resolveNoneKeyframes();
|
|
2016
2016
|
}
|
|
2017
2017
|
}
|
|
2018
|
-
|
|
2018
|
+
const xr = /* @__PURE__ */ new Set([
|
|
2019
|
+
"opacity",
|
|
2020
|
+
"clipPath",
|
|
2021
|
+
"filter",
|
|
2022
|
+
"transform"
|
|
2023
|
+
// TODO: Can be accelerated but currently disabled until https://issues.chromium.org/issues/41491098 is resolved
|
|
2024
|
+
// or until we implement support for linear() easing.
|
|
2025
|
+
// "background-color"
|
|
2026
|
+
]);
|
|
2027
|
+
function wr(e, t, n) {
|
|
2019
2028
|
if (e == null)
|
|
2020
2029
|
return [];
|
|
2021
2030
|
if (e instanceof EventTarget)
|
|
@@ -2028,33 +2037,24 @@ function xr(e, t, n) {
|
|
|
2028
2037
|
}
|
|
2029
2038
|
return Array.from(e).filter((s) => s != null);
|
|
2030
2039
|
}
|
|
2031
|
-
const
|
|
2032
|
-
function
|
|
2033
|
-
return
|
|
2040
|
+
const qn = (e, t) => t && typeof e == "number" ? t.transform(e) : e, { schedule: Cr } = /* @__PURE__ */ yn(queueMicrotask, !1);
|
|
2041
|
+
function Zn(e) {
|
|
2042
|
+
return Ts(e) && "ownerSVGElement" in e;
|
|
2034
2043
|
}
|
|
2035
|
-
function
|
|
2036
|
-
return
|
|
2044
|
+
function Dr(e) {
|
|
2045
|
+
return Zn(e) && e.tagName === "svg";
|
|
2037
2046
|
}
|
|
2038
|
-
const
|
|
2047
|
+
const Fr = [...Yn, D, U], Er = (e) => Fr.find(Gn(e)), jt = () => ({ min: 0, max: 0 }), dt = () => ({
|
|
2039
2048
|
x: jt(),
|
|
2040
2049
|
y: jt()
|
|
2041
|
-
}),
|
|
2042
|
-
function Rr() {
|
|
2043
|
-
if (Zn.current = !0, !!Er)
|
|
2044
|
-
if (window.matchMedia) {
|
|
2045
|
-
const e = window.matchMedia("(prefers-reduced-motion)"), t = () => Xe.current = e.matches;
|
|
2046
|
-
e.addEventListener("change", t), t();
|
|
2047
|
-
} else
|
|
2048
|
-
Xe.current = !1;
|
|
2049
|
-
}
|
|
2050
|
-
const he = /* @__PURE__ */ new WeakMap();
|
|
2051
|
-
function Pr(e) {
|
|
2050
|
+
}), he = /* @__PURE__ */ new WeakMap();
|
|
2051
|
+
function Rr(e) {
|
|
2052
2052
|
return e !== null && typeof e == "object" && typeof e.start == "function";
|
|
2053
2053
|
}
|
|
2054
|
-
function
|
|
2054
|
+
function Pr(e) {
|
|
2055
2055
|
return typeof e == "string" || Array.isArray(e);
|
|
2056
2056
|
}
|
|
2057
|
-
const
|
|
2057
|
+
const kr = [
|
|
2058
2058
|
"animate",
|
|
2059
2059
|
"whileInView",
|
|
2060
2060
|
"whileFocus",
|
|
@@ -2062,14 +2062,14 @@ const Or = [
|
|
|
2062
2062
|
"whileTap",
|
|
2063
2063
|
"whileDrag",
|
|
2064
2064
|
"exit"
|
|
2065
|
-
],
|
|
2065
|
+
], Or = ["initial", ...kr];
|
|
2066
2066
|
function Hn(e) {
|
|
2067
|
-
return
|
|
2067
|
+
return Rr(e.animate) || Or.some((t) => Pr(e[t]));
|
|
2068
2068
|
}
|
|
2069
|
-
function
|
|
2069
|
+
function Br(e) {
|
|
2070
2070
|
return !!(Hn(e) || e.variants);
|
|
2071
2071
|
}
|
|
2072
|
-
function
|
|
2072
|
+
function Ir(e, t, n) {
|
|
2073
2073
|
for (const s in t) {
|
|
2074
2074
|
const i = t[s], r = n[s];
|
|
2075
2075
|
if (E(i))
|
|
@@ -2089,6 +2089,15 @@ function Nr(e, t, n) {
|
|
|
2089
2089
|
t[s] === void 0 && e.removeValue(s);
|
|
2090
2090
|
return t;
|
|
2091
2091
|
}
|
|
2092
|
+
const Xe = { current: null }, Jn = { current: !1 }, Nr = typeof window < "u";
|
|
2093
|
+
function Kr() {
|
|
2094
|
+
if (Jn.current = !0, !!Nr)
|
|
2095
|
+
if (window.matchMedia) {
|
|
2096
|
+
const e = window.matchMedia("(prefers-reduced-motion)"), t = () => Xe.current = e.matches;
|
|
2097
|
+
e.addEventListener("change", t), t();
|
|
2098
|
+
} else
|
|
2099
|
+
Xe.current = !1;
|
|
2100
|
+
}
|
|
2092
2101
|
const Gt = [
|
|
2093
2102
|
"AnimationStart",
|
|
2094
2103
|
"AnimationComplete",
|
|
@@ -2099,7 +2108,7 @@ const Gt = [
|
|
|
2099
2108
|
"LayoutAnimationComplete"
|
|
2100
2109
|
];
|
|
2101
2110
|
let Yt = {};
|
|
2102
|
-
class
|
|
2111
|
+
class Qn {
|
|
2103
2112
|
/**
|
|
2104
2113
|
* This method takes React props and returns found MotionValues. For example, HTML
|
|
2105
2114
|
* MotionValues will be found within the style prop, whereas for Three.js within attribute arrays.
|
|
@@ -2118,7 +2127,7 @@ class Jn {
|
|
|
2118
2127
|
this.renderScheduledAt < p && (this.renderScheduledAt = p, K.render(this.render, !1, !0));
|
|
2119
2128
|
};
|
|
2120
2129
|
const { latestValues: c, renderState: l } = o;
|
|
2121
|
-
this.latestValues = c, this.baseTarget = { ...c }, this.initialValues = n.initial ? { ...c } : {}, this.renderState = l, this.parent = t, this.props = n, this.presenceContext = s, this.depth = t ? t.depth + 1 : 0, this.reducedMotionConfig = i, this.skipAnimationsConfig = r, this.options = u, this.blockInitialAnimation = !!a, this.isControllingVariants = Hn(n), this.isVariantNode =
|
|
2130
|
+
this.latestValues = c, this.baseTarget = { ...c }, this.initialValues = n.initial ? { ...c } : {}, this.renderState = l, this.parent = t, this.props = n, this.presenceContext = s, this.depth = t ? t.depth + 1 : 0, this.reducedMotionConfig = i, this.skipAnimationsConfig = r, this.options = u, this.blockInitialAnimation = !!a, this.isControllingVariants = Hn(n), this.isVariantNode = Br(n), this.isVariantNode && (this.variantChildren = /* @__PURE__ */ new Set()), this.manuallyAnimateOnMount = !!(t && t.current);
|
|
2122
2131
|
const { willChange: f, ...h } = this.scrapeMotionValuesFromProps(n, {}, this);
|
|
2123
2132
|
for (const p in h) {
|
|
2124
2133
|
const g = h[p];
|
|
@@ -2129,7 +2138,7 @@ class Jn {
|
|
|
2129
2138
|
if (this.hasBeenMounted)
|
|
2130
2139
|
for (const n in this.initialValues)
|
|
2131
2140
|
this.values.get(n)?.jump(this.initialValues[n]), this.latestValues[n] = this.initialValues[n];
|
|
2132
|
-
this.current = t, he.set(t, this), this.projection && !this.projection.instance && this.projection.mount(t), this.parent && this.isVariantNode && !this.isControllingVariants && (this.removeFromVariantTree = this.parent.addVariantChild(this)), this.values.forEach((n, s) => this.bindToMotionValue(s, n)), this.reducedMotionConfig === "never" ? this.shouldReduceMotion = !1 : this.reducedMotionConfig === "always" ? this.shouldReduceMotion = !0 : (
|
|
2141
|
+
this.current = t, he.set(t, this), this.projection && !this.projection.instance && this.projection.mount(t), this.parent && this.isVariantNode && !this.isControllingVariants && (this.removeFromVariantTree = this.parent.addVariantChild(this)), this.values.forEach((n, s) => this.bindToMotionValue(s, n)), this.reducedMotionConfig === "never" ? this.shouldReduceMotion = !1 : this.reducedMotionConfig === "always" ? this.shouldReduceMotion = !0 : (Jn.current || Kr(), this.shouldReduceMotion = Xe.current), process.env.NODE_ENV !== "production" && rn(this.shouldReduceMotion !== !0, "You have Reduced Motion enabled on your device. Animations may not appear as expected.", "reduced-motion-disabled"), this.shouldSkipAnimations = this.skipAnimationsConfig ?? !1, this.parent?.addChild(this), this.update(this.props, this.presenceContext), this.hasBeenMounted = !0;
|
|
2133
2142
|
}
|
|
2134
2143
|
unmount() {
|
|
2135
2144
|
this.projection && this.projection.unmount(), Oe(this.notifyUpdate), Oe(this.render), this.valueSubscriptions.forEach((t) => t()), this.valueSubscriptions.clear(), this.removeFromVariantTree && this.removeFromVariantTree(), this.parent?.removeChild(this);
|
|
@@ -2148,7 +2157,20 @@ class Jn {
|
|
|
2148
2157
|
this.children.delete(t), this.enteringChildren && this.enteringChildren.delete(t);
|
|
2149
2158
|
}
|
|
2150
2159
|
bindToMotionValue(t, n) {
|
|
2151
|
-
this.valueSubscriptions.has(t) && this.valueSubscriptions.get(t)()
|
|
2160
|
+
if (this.valueSubscriptions.has(t) && this.valueSubscriptions.get(t)(), n.accelerate && xr.has(t) && this.current instanceof HTMLElement) {
|
|
2161
|
+
const { factory: a, keyframes: o, times: u, ease: c, duration: l } = n.accelerate, f = new Nn({
|
|
2162
|
+
element: this.current,
|
|
2163
|
+
name: t,
|
|
2164
|
+
keyframes: o,
|
|
2165
|
+
times: u,
|
|
2166
|
+
ease: c,
|
|
2167
|
+
duration: /* @__PURE__ */ k(l)
|
|
2168
|
+
}), h = a(f);
|
|
2169
|
+
this.valueSubscriptions.set(t, () => {
|
|
2170
|
+
h(), f.cancel();
|
|
2171
|
+
});
|
|
2172
|
+
return;
|
|
2173
|
+
}
|
|
2152
2174
|
const s = te.has(t);
|
|
2153
2175
|
s && this.onBindTransform && this.onBindTransform();
|
|
2154
2176
|
const i = n.on("change", (a) => {
|
|
@@ -2204,7 +2226,7 @@ class Jn {
|
|
|
2204
2226
|
const r = "on" + i, a = t[r];
|
|
2205
2227
|
a && (this.propEventSubscriptions[i] = this.on(i, a));
|
|
2206
2228
|
}
|
|
2207
|
-
this.prevMotionValues =
|
|
2229
|
+
this.prevMotionValues = Ir(this, this.scrapeMotionValuesFromProps(t, this.prevProps || {}, this), this.prevMotionValues), this.handleChildMotionValue && this.handleChildMotionValue();
|
|
2208
2230
|
}
|
|
2209
2231
|
getProps() {
|
|
2210
2232
|
return this.props;
|
|
@@ -2269,7 +2291,7 @@ class Jn {
|
|
|
2269
2291
|
*/
|
|
2270
2292
|
readValue(t, n) {
|
|
2271
2293
|
let s = this.latestValues[t] !== void 0 || !this.current ? this.latestValues[t] : this.getBaseTargetFromProps(this.props, t) ?? this.readValueFromInstance(this.current, t, this.options);
|
|
2272
|
-
return s != null && (typeof s == "string" && (en(s) || tn(s)) ? s = parseFloat(s) : !
|
|
2294
|
+
return s != null && (typeof s == "string" && (en(s) || tn(s)) ? s = parseFloat(s) : !Er(s) && U.test(n) && (s = Xn(t, n)), this.setBaseTarget(t, E(s) ? s.get() : s)), E(s) ? s.get() : s;
|
|
2273
2295
|
}
|
|
2274
2296
|
/**
|
|
2275
2297
|
* Set the base target to later animate back to. This is currently
|
|
@@ -2286,7 +2308,7 @@ class Jn {
|
|
|
2286
2308
|
const { initial: n } = this.props;
|
|
2287
2309
|
let s;
|
|
2288
2310
|
if (typeof n == "string" || typeof n == "object") {
|
|
2289
|
-
const r =
|
|
2311
|
+
const r = Un(this.props, n, this.presenceContext?.custom);
|
|
2290
2312
|
r && (s = r[t]);
|
|
2291
2313
|
}
|
|
2292
2314
|
if (n && s !== void 0)
|
|
@@ -2301,12 +2323,12 @@ class Jn {
|
|
|
2301
2323
|
this.events[t] && this.events[t].notify(...n);
|
|
2302
2324
|
}
|
|
2303
2325
|
scheduleRenderMicrotask() {
|
|
2304
|
-
|
|
2326
|
+
Cr.render(this.render);
|
|
2305
2327
|
}
|
|
2306
2328
|
}
|
|
2307
|
-
class
|
|
2329
|
+
class es extends Qn {
|
|
2308
2330
|
constructor() {
|
|
2309
|
-
super(...arguments), this.KeyframeResolver =
|
|
2331
|
+
super(...arguments), this.KeyframeResolver = Ar;
|
|
2310
2332
|
}
|
|
2311
2333
|
sortInstanceNodePosition(t, n) {
|
|
2312
2334
|
return t.compareDocumentPosition(n) & 2 ? 1 : -1;
|
|
@@ -2326,13 +2348,13 @@ class Qn extends Jn {
|
|
|
2326
2348
|
}));
|
|
2327
2349
|
}
|
|
2328
2350
|
}
|
|
2329
|
-
function
|
|
2351
|
+
function $r({ top: e, left: t, right: n, bottom: s }) {
|
|
2330
2352
|
return {
|
|
2331
2353
|
x: { min: t, max: n },
|
|
2332
2354
|
y: { min: e, max: s }
|
|
2333
2355
|
};
|
|
2334
2356
|
}
|
|
2335
|
-
function
|
|
2357
|
+
function Lr(e, t) {
|
|
2336
2358
|
if (!t)
|
|
2337
2359
|
return e;
|
|
2338
2360
|
const n = t({ x: e.left, y: e.top }), s = t({ x: e.right, y: e.bottom });
|
|
@@ -2343,18 +2365,18 @@ function $r(e, t) {
|
|
|
2343
2365
|
right: s.x
|
|
2344
2366
|
};
|
|
2345
2367
|
}
|
|
2346
|
-
function
|
|
2347
|
-
return
|
|
2368
|
+
function Wr(e, t) {
|
|
2369
|
+
return $r(Lr(e.getBoundingClientRect(), t));
|
|
2348
2370
|
}
|
|
2349
|
-
const
|
|
2371
|
+
const _r = {
|
|
2350
2372
|
x: "translateX",
|
|
2351
2373
|
y: "translateY",
|
|
2352
2374
|
z: "translateZ",
|
|
2353
2375
|
transformPerspective: "perspective"
|
|
2354
|
-
},
|
|
2355
|
-
function
|
|
2376
|
+
}, Ur = ee.length;
|
|
2377
|
+
function jr(e, t, n) {
|
|
2356
2378
|
let s = "", i = !0;
|
|
2357
|
-
for (let r = 0; r <
|
|
2379
|
+
for (let r = 0; r < Ur; r++) {
|
|
2358
2380
|
const a = ee[r], o = e[a];
|
|
2359
2381
|
if (o === void 0)
|
|
2360
2382
|
continue;
|
|
@@ -2366,10 +2388,10 @@ function Ur(e, t, n) {
|
|
|
2366
2388
|
u = a.startsWith("scale") ? c === 1 : c === 0;
|
|
2367
2389
|
}
|
|
2368
2390
|
if (!u || n) {
|
|
2369
|
-
const c =
|
|
2391
|
+
const c = qn(o, ht[a]);
|
|
2370
2392
|
if (!u) {
|
|
2371
2393
|
i = !1;
|
|
2372
|
-
const l =
|
|
2394
|
+
const l = _r[a] || a;
|
|
2373
2395
|
s += `${l}(${c}) `;
|
|
2374
2396
|
}
|
|
2375
2397
|
n && (t[a] = c);
|
|
@@ -2377,7 +2399,7 @@ function Ur(e, t, n) {
|
|
|
2377
2399
|
}
|
|
2378
2400
|
return s = s.trim(), n ? s = n(t, i ? "" : s) : i && (s = "none"), s;
|
|
2379
2401
|
}
|
|
2380
|
-
function
|
|
2402
|
+
function ts(e, t, n) {
|
|
2381
2403
|
const { style: s, vars: i, transformOrigin: r } = e;
|
|
2382
2404
|
let a = !1, o = !1;
|
|
2383
2405
|
for (const u in t) {
|
|
@@ -2389,16 +2411,16 @@ function es(e, t, n) {
|
|
|
2389
2411
|
i[u] = c;
|
|
2390
2412
|
continue;
|
|
2391
2413
|
} else {
|
|
2392
|
-
const l =
|
|
2414
|
+
const l = qn(c, ht[u]);
|
|
2393
2415
|
u.startsWith("origin") ? (o = !0, r[u] = l) : s[u] = l;
|
|
2394
2416
|
}
|
|
2395
2417
|
}
|
|
2396
|
-
if (t.transform || (a || n ? s.transform =
|
|
2418
|
+
if (t.transform || (a || n ? s.transform = jr(t, e.transform, n) : s.transform && (s.transform = "none")), o) {
|
|
2397
2419
|
const { originX: u = "50%", originY: c = "50%", originZ: l = 0 } = r;
|
|
2398
2420
|
s.transformOrigin = `${u} ${c} ${l}`;
|
|
2399
2421
|
}
|
|
2400
2422
|
}
|
|
2401
|
-
function
|
|
2423
|
+
function ns(e, { style: t, vars: n }, s, i) {
|
|
2402
2424
|
const r = e.style;
|
|
2403
2425
|
let a;
|
|
2404
2426
|
for (a in t)
|
|
@@ -2422,7 +2444,7 @@ const ae = {
|
|
|
2422
2444
|
const n = zt(e, t.target.x), s = zt(e, t.target.y);
|
|
2423
2445
|
return `${n}% ${s}%`;
|
|
2424
2446
|
}
|
|
2425
|
-
},
|
|
2447
|
+
}, Gr = {
|
|
2426
2448
|
correct: (e, { treeScale: t, projectionDelta: n }) => {
|
|
2427
2449
|
const s = e, i = U.parse(e);
|
|
2428
2450
|
if (i.length > 5)
|
|
@@ -2432,7 +2454,7 @@ const ae = {
|
|
|
2432
2454
|
const c = Q(o, u, 0.5);
|
|
2433
2455
|
return typeof i[2 + a] == "number" && (i[2 + a] /= c), typeof i[3 + a] == "number" && (i[3 + a] /= c), r(i);
|
|
2434
2456
|
}
|
|
2435
|
-
},
|
|
2457
|
+
}, Yr = {
|
|
2436
2458
|
borderRadius: {
|
|
2437
2459
|
...ae,
|
|
2438
2460
|
applyTo: [
|
|
@@ -2446,53 +2468,53 @@ const ae = {
|
|
|
2446
2468
|
borderTopRightRadius: ae,
|
|
2447
2469
|
borderBottomLeftRadius: ae,
|
|
2448
2470
|
borderBottomRightRadius: ae,
|
|
2449
|
-
boxShadow:
|
|
2471
|
+
boxShadow: Gr
|
|
2450
2472
|
};
|
|
2451
|
-
function
|
|
2452
|
-
return te.has(e) || e.startsWith("origin") || (t || n !== void 0) && (!!
|
|
2473
|
+
function zr(e, { layout: t, layoutId: n }) {
|
|
2474
|
+
return te.has(e) || e.startsWith("origin") || (t || n !== void 0) && (!!Yr[e] || e === "opacity");
|
|
2453
2475
|
}
|
|
2454
|
-
function
|
|
2476
|
+
function ss(e, t, n) {
|
|
2455
2477
|
const s = e.style, i = t?.style, r = {};
|
|
2456
2478
|
if (!s)
|
|
2457
2479
|
return r;
|
|
2458
2480
|
for (const a in s)
|
|
2459
|
-
(E(s[a]) || i && E(i[a]) ||
|
|
2481
|
+
(E(s[a]) || i && E(i[a]) || zr(a, e) || n?.getValue(a)?.liveStyle !== void 0) && (r[a] = s[a]);
|
|
2460
2482
|
return r;
|
|
2461
2483
|
}
|
|
2462
|
-
function
|
|
2484
|
+
function Xr(e) {
|
|
2463
2485
|
return window.getComputedStyle(e);
|
|
2464
2486
|
}
|
|
2465
|
-
class
|
|
2487
|
+
class qr extends es {
|
|
2466
2488
|
constructor() {
|
|
2467
|
-
super(...arguments), this.type = "html", this.renderInstance =
|
|
2489
|
+
super(...arguments), this.type = "html", this.renderInstance = ns;
|
|
2468
2490
|
}
|
|
2469
2491
|
readValueFromInstance(t, n) {
|
|
2470
2492
|
if (te.has(n))
|
|
2471
|
-
return this.projection?.isProjecting ? We(n) :
|
|
2493
|
+
return this.projection?.isProjecting ? We(n) : Ti(t, n);
|
|
2472
2494
|
{
|
|
2473
|
-
const s =
|
|
2495
|
+
const s = Xr(t), i = (Tn(n) ? s.getPropertyValue(n) : s[n]) || 0;
|
|
2474
2496
|
return typeof i == "string" ? i.trim() : i;
|
|
2475
2497
|
}
|
|
2476
2498
|
}
|
|
2477
2499
|
measureInstanceViewportBox(t, { transformPagePoint: n }) {
|
|
2478
|
-
return
|
|
2500
|
+
return Wr(t, n);
|
|
2479
2501
|
}
|
|
2480
2502
|
build(t, n, s) {
|
|
2481
|
-
|
|
2503
|
+
ts(t, n, s.transformTemplate);
|
|
2482
2504
|
}
|
|
2483
2505
|
scrapeMotionValuesFromProps(t, n, s) {
|
|
2484
|
-
return
|
|
2506
|
+
return ss(t, n, s);
|
|
2485
2507
|
}
|
|
2486
2508
|
}
|
|
2487
|
-
function
|
|
2509
|
+
function Zr(e, t) {
|
|
2488
2510
|
return e in t;
|
|
2489
2511
|
}
|
|
2490
|
-
class
|
|
2512
|
+
class Hr extends Qn {
|
|
2491
2513
|
constructor() {
|
|
2492
2514
|
super(...arguments), this.type = "object";
|
|
2493
2515
|
}
|
|
2494
2516
|
readValueFromInstance(t, n) {
|
|
2495
|
-
if (
|
|
2517
|
+
if (Zr(n, t)) {
|
|
2496
2518
|
const s = t[n];
|
|
2497
2519
|
if (typeof s == "string" || typeof s == "number")
|
|
2498
2520
|
return s;
|
|
@@ -2516,25 +2538,25 @@ class Zr extends Jn {
|
|
|
2516
2538
|
return 0;
|
|
2517
2539
|
}
|
|
2518
2540
|
}
|
|
2519
|
-
const
|
|
2541
|
+
const Jr = {
|
|
2520
2542
|
offset: "stroke-dashoffset",
|
|
2521
2543
|
array: "stroke-dasharray"
|
|
2522
|
-
},
|
|
2544
|
+
}, Qr = {
|
|
2523
2545
|
offset: "strokeDashoffset",
|
|
2524
2546
|
array: "strokeDasharray"
|
|
2525
2547
|
};
|
|
2526
|
-
function
|
|
2548
|
+
function ea(e, t, n = 1, s = 0, i = !0) {
|
|
2527
2549
|
e.pathLength = 1;
|
|
2528
|
-
const r = i ?
|
|
2550
|
+
const r = i ? Jr : Qr;
|
|
2529
2551
|
e[r.offset] = `${-s}`, e[r.array] = `${t} ${n}`;
|
|
2530
2552
|
}
|
|
2531
|
-
const
|
|
2553
|
+
const ta = [
|
|
2532
2554
|
"offsetDistance",
|
|
2533
2555
|
"offsetPath",
|
|
2534
2556
|
"offsetRotate",
|
|
2535
2557
|
"offsetAnchor"
|
|
2536
2558
|
];
|
|
2537
|
-
function
|
|
2559
|
+
function na(e, {
|
|
2538
2560
|
attrX: t,
|
|
2539
2561
|
attrY: n,
|
|
2540
2562
|
attrScale: s,
|
|
@@ -2544,18 +2566,18 @@ function ta(e, {
|
|
|
2544
2566
|
// This is object creation, which we try to avoid per-frame.
|
|
2545
2567
|
...o
|
|
2546
2568
|
}, u, c, l) {
|
|
2547
|
-
if (
|
|
2569
|
+
if (ts(e, o, c), u) {
|
|
2548
2570
|
e.style.viewBox && (e.attrs.viewBox = e.style.viewBox);
|
|
2549
2571
|
return;
|
|
2550
2572
|
}
|
|
2551
2573
|
e.attrs = e.style, e.style = {};
|
|
2552
2574
|
const { attrs: f, style: h } = e;
|
|
2553
2575
|
f.transform && (h.transform = f.transform, delete f.transform), (h.transform || f.transformOrigin) && (h.transformOrigin = f.transformOrigin ?? "50% 50%", delete f.transformOrigin), h.transform && (h.transformBox = l?.transformBox ?? "fill-box", delete f.transformBox);
|
|
2554
|
-
for (const p of
|
|
2576
|
+
for (const p of ta)
|
|
2555
2577
|
f[p] !== void 0 && (h[p] = f[p], delete f[p]);
|
|
2556
|
-
t !== void 0 && (f.x = t), n !== void 0 && (f.y = n), s !== void 0 && (f.scale = s), i !== void 0 &&
|
|
2578
|
+
t !== void 0 && (f.x = t), n !== void 0 && (f.y = n), s !== void 0 && (f.scale = s), i !== void 0 && ea(f, i, r, a, !1);
|
|
2557
2579
|
}
|
|
2558
|
-
const
|
|
2580
|
+
const is = /* @__PURE__ */ new Set([
|
|
2559
2581
|
"baseFrequency",
|
|
2560
2582
|
"diffuseConstant",
|
|
2561
2583
|
"kernelMatrix",
|
|
@@ -2579,14 +2601,14 @@ const ss = /* @__PURE__ */ new Set([
|
|
|
2579
2601
|
"startOffset",
|
|
2580
2602
|
"textLength",
|
|
2581
2603
|
"lengthAdjust"
|
|
2582
|
-
]),
|
|
2583
|
-
function
|
|
2584
|
-
|
|
2604
|
+
]), sa = (e) => typeof e == "string" && e.toLowerCase() === "svg";
|
|
2605
|
+
function ia(e, t, n, s) {
|
|
2606
|
+
ns(e, t, void 0, s);
|
|
2585
2607
|
for (const i in t.attrs)
|
|
2586
|
-
e.setAttribute(
|
|
2608
|
+
e.setAttribute(is.has(i) ? i : ft(i), t.attrs[i]);
|
|
2587
2609
|
}
|
|
2588
|
-
function
|
|
2589
|
-
const s =
|
|
2610
|
+
function ra(e, t, n) {
|
|
2611
|
+
const s = ss(e, t, n);
|
|
2590
2612
|
for (const i in e)
|
|
2591
2613
|
if (E(e[i]) || E(t[i])) {
|
|
2592
2614
|
const r = ee.indexOf(i) !== -1 ? "attr" + i.charAt(0).toUpperCase() + i.substring(1) : i;
|
|
@@ -2594,7 +2616,7 @@ function ia(e, t, n) {
|
|
|
2594
2616
|
}
|
|
2595
2617
|
return s;
|
|
2596
2618
|
}
|
|
2597
|
-
class
|
|
2619
|
+
class aa extends es {
|
|
2598
2620
|
constructor() {
|
|
2599
2621
|
super(...arguments), this.type = "svg", this.isSVGTag = !1, this.measureInstanceViewportBox = dt;
|
|
2600
2622
|
}
|
|
@@ -2603,48 +2625,48 @@ class ra extends Qn {
|
|
|
2603
2625
|
}
|
|
2604
2626
|
readValueFromInstance(t, n) {
|
|
2605
2627
|
if (te.has(n)) {
|
|
2606
|
-
const s =
|
|
2628
|
+
const s = zn(n);
|
|
2607
2629
|
return s && s.default || 0;
|
|
2608
2630
|
}
|
|
2609
|
-
return n =
|
|
2631
|
+
return n = is.has(n) ? n : ft(n), t.getAttribute(n);
|
|
2610
2632
|
}
|
|
2611
2633
|
scrapeMotionValuesFromProps(t, n, s) {
|
|
2612
|
-
return
|
|
2634
|
+
return ra(t, n, s);
|
|
2613
2635
|
}
|
|
2614
2636
|
build(t, n, s) {
|
|
2615
|
-
|
|
2637
|
+
na(t, n, this.isSVGTag, s.transformTemplate, s.style);
|
|
2616
2638
|
}
|
|
2617
2639
|
renderInstance(t, n, s, i) {
|
|
2618
|
-
|
|
2640
|
+
ia(t, n, s, i);
|
|
2619
2641
|
}
|
|
2620
2642
|
mount(t) {
|
|
2621
|
-
this.isSVGTag =
|
|
2643
|
+
this.isSVGTag = sa(t.tagName), super.mount(t);
|
|
2622
2644
|
}
|
|
2623
2645
|
}
|
|
2624
|
-
function
|
|
2646
|
+
function oa(e, t, n) {
|
|
2625
2647
|
const s = E(e) ? e : Z(e);
|
|
2626
|
-
return s.start(
|
|
2648
|
+
return s.start(_n("", s, t, n)), s.animation;
|
|
2627
2649
|
}
|
|
2628
2650
|
function pt(e) {
|
|
2629
2651
|
return typeof e == "object" && !Array.isArray(e);
|
|
2630
2652
|
}
|
|
2631
|
-
function
|
|
2632
|
-
return e == null ? [] : typeof e == "string" && pt(t) ?
|
|
2653
|
+
function rs(e, t, n, s) {
|
|
2654
|
+
return e == null ? [] : typeof e == "string" && pt(t) ? wr(e, n, s) : e instanceof NodeList ? Array.from(e) : Array.isArray(e) ? e.filter((i) => i != null) : [e];
|
|
2633
2655
|
}
|
|
2634
|
-
function
|
|
2656
|
+
function la(e, t, n) {
|
|
2635
2657
|
return e * (t + 1);
|
|
2636
2658
|
}
|
|
2637
2659
|
function Xt(e, t, n, s) {
|
|
2638
2660
|
return typeof t == "number" ? t : t.startsWith("-") || t.startsWith("+") ? Math.max(0, e + parseFloat(t)) : t === "<" ? n : t.startsWith("<") ? Math.max(0, n + parseFloat(t.slice(1))) : s.get(t) ?? e;
|
|
2639
2661
|
}
|
|
2640
|
-
function
|
|
2662
|
+
function ua(e, t, n) {
|
|
2641
2663
|
for (let s = 0; s < e.length; s++) {
|
|
2642
2664
|
const i = e[s];
|
|
2643
2665
|
i.at > t && i.at < n && (qe(e, i), s--);
|
|
2644
2666
|
}
|
|
2645
2667
|
}
|
|
2646
|
-
function
|
|
2647
|
-
|
|
2668
|
+
function ca(e, t, n, s, i, r) {
|
|
2669
|
+
ua(e, i, r);
|
|
2648
2670
|
for (let a = 0; a < t.length; a++)
|
|
2649
2671
|
e.push({
|
|
2650
2672
|
value: t[a],
|
|
@@ -2652,15 +2674,15 @@ function ua(e, t, n, s, i, r) {
|
|
|
2652
2674
|
easing: mn(n, a)
|
|
2653
2675
|
});
|
|
2654
2676
|
}
|
|
2655
|
-
function
|
|
2677
|
+
function fa(e, t) {
|
|
2656
2678
|
for (let n = 0; n < e.length; n++)
|
|
2657
2679
|
e[n] = e[n] / (t + 1);
|
|
2658
2680
|
}
|
|
2659
|
-
function
|
|
2681
|
+
function ha(e, t) {
|
|
2660
2682
|
return e.at === t.at ? e.value === null ? 1 : t.value === null ? -1 : 0 : e.at - t.at;
|
|
2661
2683
|
}
|
|
2662
|
-
const
|
|
2663
|
-
function
|
|
2684
|
+
const da = "easeInOut", pa = 20;
|
|
2685
|
+
function ma(e, { defaultTransition: t = {}, ...n } = {}, s, i) {
|
|
2664
2686
|
const r = t.duration || 0.3, a = /* @__PURE__ */ new Map(), o = /* @__PURE__ */ new Map(), u = {}, c = /* @__PURE__ */ new Map();
|
|
2665
2687
|
let l = 0, f = 0, h = 0;
|
|
2666
2688
|
for (let p = 0; p < e.length; p++) {
|
|
@@ -2675,53 +2697,53 @@ function pa(e, { defaultTransition: t = {}, ...n } = {}, s, i) {
|
|
|
2675
2697
|
let [y, S, v = {}] = g;
|
|
2676
2698
|
v.at !== void 0 && (f = Xt(f, v.at, l, c));
|
|
2677
2699
|
let w = 0;
|
|
2678
|
-
const V = (
|
|
2679
|
-
const
|
|
2700
|
+
const V = (M, m, b, x = 0, T = 0) => {
|
|
2701
|
+
const A = ga(M), { delay: F = 0, times: O = Rn(A), type: Ae = t.type || "keyframes", repeat: ne, repeatType: Fa, repeatDelay: Ea = 0, ...os } = m;
|
|
2680
2702
|
let { ease: $ = t.ease || "easeOut", duration: B } = m;
|
|
2681
|
-
const mt = typeof F == "function" ? F(x, T) : F, gt =
|
|
2703
|
+
const mt = typeof F == "function" ? F(x, T) : F, gt = A.length, yt = ct(Ae) ? Ae : i?.[Ae || "keyframes"];
|
|
2682
2704
|
if (gt <= 2 && yt) {
|
|
2683
2705
|
let se = 100;
|
|
2684
|
-
if (gt === 2 &&
|
|
2685
|
-
const ie =
|
|
2706
|
+
if (gt === 2 && Ta(A)) {
|
|
2707
|
+
const ie = A[1] - A[0];
|
|
2686
2708
|
se = Math.abs(ie);
|
|
2687
2709
|
}
|
|
2688
2710
|
const ge = {
|
|
2689
2711
|
...t,
|
|
2690
|
-
...
|
|
2712
|
+
...os
|
|
2691
2713
|
};
|
|
2692
|
-
B !== void 0 && (ge.duration = /* @__PURE__ */
|
|
2714
|
+
B !== void 0 && (ge.duration = /* @__PURE__ */ k(B));
|
|
2693
2715
|
const ye = Dn(ge, se, yt);
|
|
2694
2716
|
$ = ye.ease, B = ye.duration;
|
|
2695
2717
|
}
|
|
2696
2718
|
B ?? (B = r);
|
|
2697
2719
|
const bt = f + mt;
|
|
2698
|
-
|
|
2699
|
-
const Tt =
|
|
2700
|
-
if (Tt > 0 && En(
|
|
2701
|
-
I(ne <
|
|
2702
|
-
const se = [...
|
|
2720
|
+
O.length === 1 && O[0] === 0 && (O[1] = 1);
|
|
2721
|
+
const Tt = O.length - A.length;
|
|
2722
|
+
if (Tt > 0 && En(O, Tt), A.length === 1 && A.unshift(null), ne) {
|
|
2723
|
+
I(ne < pa, "Repeat count too high, must be less than 20", "repeat-count-high"), B = la(B, ne);
|
|
2724
|
+
const se = [...A], ge = [...O];
|
|
2703
2725
|
$ = Array.isArray($) ? [...$] : [$];
|
|
2704
2726
|
const ye = [...$];
|
|
2705
2727
|
for (let ie = 0; ie < ne; ie++) {
|
|
2706
|
-
|
|
2728
|
+
A.push(...se);
|
|
2707
2729
|
for (let re = 0; re < se.length; re++)
|
|
2708
|
-
|
|
2730
|
+
O.push(ge[re] + (ie + 1)), $.push(re === 0 ? "linear" : mn(ye, re - 1));
|
|
2709
2731
|
}
|
|
2710
|
-
|
|
2732
|
+
fa(O, ne);
|
|
2711
2733
|
}
|
|
2712
2734
|
const vt = bt + B;
|
|
2713
|
-
|
|
2735
|
+
ca(b, A, $, O, bt, vt), w = Math.max(mt + B, w), h = Math.max(vt, h);
|
|
2714
2736
|
};
|
|
2715
2737
|
if (E(y)) {
|
|
2716
|
-
const
|
|
2717
|
-
V(S, v, Zt("default",
|
|
2738
|
+
const M = qt(y, o);
|
|
2739
|
+
V(S, v, Zt("default", M));
|
|
2718
2740
|
} else {
|
|
2719
|
-
const
|
|
2741
|
+
const M = rs(y, S, s, u), m = M.length;
|
|
2720
2742
|
for (let b = 0; b < m; b++) {
|
|
2721
2743
|
S = S, v = v;
|
|
2722
|
-
const x =
|
|
2723
|
-
for (const
|
|
2724
|
-
V(S[
|
|
2744
|
+
const x = M[b], T = qt(x, o);
|
|
2745
|
+
for (const A in S)
|
|
2746
|
+
V(S[A], ya(v, A), Zt(A, T), b, m);
|
|
2725
2747
|
}
|
|
2726
2748
|
}
|
|
2727
2749
|
l = f, f += w;
|
|
@@ -2729,20 +2751,20 @@ function pa(e, { defaultTransition: t = {}, ...n } = {}, s, i) {
|
|
|
2729
2751
|
return o.forEach((p, g) => {
|
|
2730
2752
|
for (const y in p) {
|
|
2731
2753
|
const S = p[y];
|
|
2732
|
-
S.sort(
|
|
2754
|
+
S.sort(ha);
|
|
2733
2755
|
const v = [], w = [], V = [];
|
|
2734
2756
|
for (let x = 0; x < S.length; x++) {
|
|
2735
|
-
const { at: T, value:
|
|
2736
|
-
v.push(
|
|
2757
|
+
const { at: T, value: A, easing: F } = S[x];
|
|
2758
|
+
v.push(A), w.push(/* @__PURE__ */ Je(0, h, T)), V.push(F || "easeOut");
|
|
2737
2759
|
}
|
|
2738
|
-
w[0] !== 0 && (w.unshift(0), v.unshift(v[0]), V.unshift(
|
|
2760
|
+
w[0] !== 0 && (w.unshift(0), v.unshift(v[0]), V.unshift(da)), w[w.length - 1] !== 1 && (w.push(1), v.push(null)), a.has(g) || a.set(g, {
|
|
2739
2761
|
keyframes: {},
|
|
2740
2762
|
transition: {}
|
|
2741
2763
|
});
|
|
2742
|
-
const
|
|
2743
|
-
|
|
2764
|
+
const M = a.get(g);
|
|
2765
|
+
M.keyframes[y] = v;
|
|
2744
2766
|
const { type: m, ...b } = t;
|
|
2745
|
-
|
|
2767
|
+
M.transition[y] = {
|
|
2746
2768
|
...b,
|
|
2747
2769
|
duration: h,
|
|
2748
2770
|
ease: V,
|
|
@@ -2758,17 +2780,17 @@ function qt(e, t) {
|
|
|
2758
2780
|
function Zt(e, t) {
|
|
2759
2781
|
return t[e] || (t[e] = []), t[e];
|
|
2760
2782
|
}
|
|
2761
|
-
function
|
|
2783
|
+
function ga(e) {
|
|
2762
2784
|
return Array.isArray(e) ? e : [e];
|
|
2763
2785
|
}
|
|
2764
|
-
function
|
|
2786
|
+
function ya(e, t) {
|
|
2765
2787
|
return e && e[t] ? {
|
|
2766
2788
|
...e,
|
|
2767
2789
|
...e[t]
|
|
2768
2790
|
} : { ...e };
|
|
2769
2791
|
}
|
|
2770
|
-
const
|
|
2771
|
-
function
|
|
2792
|
+
const ba = (e) => typeof e == "number", Ta = (e) => e.every(ba);
|
|
2793
|
+
function va(e) {
|
|
2772
2794
|
const t = {
|
|
2773
2795
|
presenceContext: null,
|
|
2774
2796
|
props: {},
|
|
@@ -2782,10 +2804,10 @@ function Ta(e) {
|
|
|
2782
2804
|
},
|
|
2783
2805
|
latestValues: {}
|
|
2784
2806
|
}
|
|
2785
|
-
}, n =
|
|
2807
|
+
}, n = Zn(e) && !Dr(e) ? new aa(t) : new qr(t);
|
|
2786
2808
|
n.mount(e), he.set(e, n);
|
|
2787
2809
|
}
|
|
2788
|
-
function
|
|
2810
|
+
function Sa(e) {
|
|
2789
2811
|
const t = {
|
|
2790
2812
|
presenceContext: null,
|
|
2791
2813
|
props: {},
|
|
@@ -2795,23 +2817,23 @@ function va(e) {
|
|
|
2795
2817
|
},
|
|
2796
2818
|
latestValues: {}
|
|
2797
2819
|
}
|
|
2798
|
-
}, n = new
|
|
2820
|
+
}, n = new Hr(t);
|
|
2799
2821
|
n.mount(e), he.set(e, n);
|
|
2800
2822
|
}
|
|
2801
|
-
function
|
|
2823
|
+
function Va(e, t) {
|
|
2802
2824
|
return E(e) || typeof e == "number" || typeof e == "string" && !pt(t);
|
|
2803
2825
|
}
|
|
2804
|
-
function
|
|
2826
|
+
function as(e, t, n, s) {
|
|
2805
2827
|
const i = [];
|
|
2806
|
-
if (
|
|
2807
|
-
i.push(
|
|
2828
|
+
if (Va(e, t))
|
|
2829
|
+
i.push(oa(e, pt(t) && t.default || t, n && (n.default || n)));
|
|
2808
2830
|
else {
|
|
2809
2831
|
if (e == null)
|
|
2810
2832
|
return i;
|
|
2811
|
-
const r =
|
|
2833
|
+
const r = rs(e, t, s), a = r.length;
|
|
2812
2834
|
I(!!a, "No valid elements provided.", "no-valid-elements");
|
|
2813
2835
|
for (let o = 0; o < a; o++) {
|
|
2814
|
-
const u = r[o], c = u instanceof Element ?
|
|
2836
|
+
const u = r[o], c = u instanceof Element ? va : Sa;
|
|
2815
2837
|
he.has(u) || c(u);
|
|
2816
2838
|
const l = he.get(u), f = { ...n };
|
|
2817
2839
|
"delay" in f && typeof f.delay == "function" && (f.delay = f.delay(o, a)), i.push(...pr(l, { ...t, transition: f }, {}));
|
|
@@ -2819,7 +2841,7 @@ function rs(e, t, n, s) {
|
|
|
2819
2841
|
}
|
|
2820
2842
|
return i;
|
|
2821
2843
|
}
|
|
2822
|
-
function
|
|
2844
|
+
function Ma(e, t, n) {
|
|
2823
2845
|
const s = [], i = e.map((a) => {
|
|
2824
2846
|
if (Array.isArray(a) && typeof a[0] == "function") {
|
|
2825
2847
|
const o = a[0], u = Z(0);
|
|
@@ -2827,22 +2849,22 @@ function Va(e, t, n) {
|
|
|
2827
2849
|
}
|
|
2828
2850
|
return a;
|
|
2829
2851
|
});
|
|
2830
|
-
return
|
|
2831
|
-
s.push(...
|
|
2852
|
+
return ma(i, t, n, { spring: fe }).forEach(({ keyframes: a, transition: o }, u) => {
|
|
2853
|
+
s.push(...as(u, a, o));
|
|
2832
2854
|
}), s;
|
|
2833
2855
|
}
|
|
2834
2856
|
function Aa(e) {
|
|
2835
2857
|
return Array.isArray(e) && e.some(Array.isArray);
|
|
2836
2858
|
}
|
|
2837
|
-
function
|
|
2859
|
+
function xa(e = {}) {
|
|
2838
2860
|
const { scope: t, reduceMotion: n } = e;
|
|
2839
2861
|
function s(i, r, a) {
|
|
2840
2862
|
let o = [], u;
|
|
2841
2863
|
if (Aa(i))
|
|
2842
|
-
o =
|
|
2864
|
+
o = Ma(i, n !== void 0 ? { reduceMotion: n, ...r } : r, t);
|
|
2843
2865
|
else {
|
|
2844
2866
|
const { onComplete: l, ...f } = a || {};
|
|
2845
|
-
typeof l == "function" && (u = l), o =
|
|
2867
|
+
typeof l == "function" && (u = l), o = as(i, r, n !== void 0 ? { reduceMotion: n, ...f } : f, t);
|
|
2846
2868
|
}
|
|
2847
2869
|
const c = new Ui(o);
|
|
2848
2870
|
return u && c.finished.then(u), t && (t.animations.push(c), c.finished.then(() => {
|
|
@@ -2851,13 +2873,13 @@ function Ma(e = {}) {
|
|
|
2851
2873
|
}
|
|
2852
2874
|
return s;
|
|
2853
2875
|
}
|
|
2854
|
-
const
|
|
2855
|
-
function
|
|
2876
|
+
const wa = xa(), Pe = "";
|
|
2877
|
+
function Ca(e, t = !0) {
|
|
2856
2878
|
const [n, s] = xe(0), [i, r] = xe(0), [a, o] = xe(e);
|
|
2857
2879
|
return a !== e && (o(e), r(e.startsWith(a) ? n : 0)), Qt(() => {
|
|
2858
2880
|
if (!t)
|
|
2859
2881
|
return;
|
|
2860
|
-
const u =
|
|
2882
|
+
const u = wa(
|
|
2861
2883
|
// The starting value for the animation (current cursor position).
|
|
2862
2884
|
i,
|
|
2863
2885
|
// The target value: total number of characters.
|
|
@@ -2882,7 +2904,7 @@ function wa(e, t = !0) {
|
|
|
2882
2904
|
const Ht = {
|
|
2883
2905
|
MODEL: "Model",
|
|
2884
2906
|
USAGE: "Session usage"
|
|
2885
|
-
},
|
|
2907
|
+
}, Da = Jt("max-w-[99cqw]", "mt-3"), $a = ds.memo(
|
|
2886
2908
|
({
|
|
2887
2909
|
content: e,
|
|
2888
2910
|
annotations: t,
|
|
@@ -2891,7 +2913,7 @@ const Ht = {
|
|
|
2891
2913
|
messageIndex: i,
|
|
2892
2914
|
messages: r
|
|
2893
2915
|
}) => {
|
|
2894
|
-
const a =
|
|
2916
|
+
const a = Ca(e, n), {
|
|
2895
2917
|
state: {
|
|
2896
2918
|
streaming: o,
|
|
2897
2919
|
restoredModel: u,
|
|
@@ -2899,21 +2921,21 @@ const Ht = {
|
|
|
2899
2921
|
tokenUsage: l,
|
|
2900
2922
|
lastStreamingTimestamp: f
|
|
2901
2923
|
}
|
|
2902
|
-
} =
|
|
2924
|
+
} = Mt(ms), {
|
|
2903
2925
|
state: { fullScreen: h }
|
|
2904
|
-
} =
|
|
2926
|
+
} = Mt(gs), p = t?.model || u, g = l, [y, S] = ps(), { user: v, getAccessToken: w } = ls(), { data: V } = us({
|
|
2905
2927
|
user: v?.username,
|
|
2906
2928
|
getAccessToken: w
|
|
2907
|
-
}),
|
|
2929
|
+
}), M = V?.showDetails || !1, m = Jt({
|
|
2908
2930
|
"max-w-xs sm:max-w-3xl": !h
|
|
2909
2931
|
}), b = [];
|
|
2910
|
-
if (
|
|
2932
|
+
if (M) {
|
|
2911
2933
|
if (p && (s ? b.push({
|
|
2912
2934
|
key: Ht.MODEL,
|
|
2913
2935
|
value: p
|
|
2914
2936
|
}) : b.push(we)), g)
|
|
2915
2937
|
if (s) {
|
|
2916
|
-
const x = g === -1 ? "N/A" : `${
|
|
2938
|
+
const x = g === -1 ? "N/A" : `${cs.format(g)} ${fs(
|
|
2917
2939
|
"token",
|
|
2918
2940
|
g
|
|
2919
2941
|
)}`;
|
|
@@ -2930,16 +2952,16 @@ const Ht = {
|
|
|
2930
2952
|
return Qt(() => {
|
|
2931
2953
|
a && S(a);
|
|
2932
2954
|
}, [a, S]), /* @__PURE__ */ St(
|
|
2933
|
-
|
|
2955
|
+
hs,
|
|
2934
2956
|
{
|
|
2935
2957
|
tail: !0,
|
|
2936
2958
|
footer: b,
|
|
2937
|
-
className:
|
|
2959
|
+
className: Da,
|
|
2938
2960
|
footerClassName: "text-copy-medium",
|
|
2939
2961
|
contentClassName: m,
|
|
2940
2962
|
noMaxWidth: !0,
|
|
2941
2963
|
action: /* @__PURE__ */ St(
|
|
2942
|
-
|
|
2964
|
+
ys,
|
|
2943
2965
|
{
|
|
2944
2966
|
streaming: o,
|
|
2945
2967
|
content: e,
|
|
@@ -2954,5 +2976,5 @@ const Ht = {
|
|
|
2954
2976
|
}
|
|
2955
2977
|
);
|
|
2956
2978
|
export {
|
|
2957
|
-
|
|
2979
|
+
$a as default
|
|
2958
2980
|
};
|