@telegraph/tooltip 0.0.55 → 0.0.57
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/CHANGELOG.md +15 -0
- package/dist/cjs/index.js +1 -1
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.mjs +136 -136
- package/dist/esm/index.mjs.map +1 -1
- package/dist/types/Tooltip/Tooltip.d.ts.map +1 -1
- package/dist/types/Tooltip/Tooltip.hooks.d.ts.map +1 -1
- package/package.json +10 -10
package/dist/esm/index.mjs
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { jsx as R, jsxs as mn } from "react/jsx-runtime";
|
|
2
|
-
import * as
|
|
2
|
+
import * as lt from "@radix-ui/react-tooltip";
|
|
3
3
|
import { useControllableState as Rs } from "@radix-ui/react-use-controllable-state";
|
|
4
4
|
import { OverrideAppearance as Es } from "@telegraph/appearance";
|
|
5
5
|
import { RefToTgphRef as ks } from "@telegraph/helpers";
|
|
6
6
|
import { Stack as Ns } from "@telegraph/layout";
|
|
7
7
|
import { Text as Ls } from "@telegraph/typography";
|
|
8
|
-
import
|
|
9
|
-
const _s =
|
|
8
|
+
import et, { createContext as st, useRef as dt, useLayoutEffect as Bs, useEffect as de, useState as Ks, useContext as k, useMemo as Et, Fragment as gn, createElement as Ws, useCallback as $s, useInsertionEffect as js, forwardRef as Gs } from "react";
|
|
9
|
+
const _s = st({});
|
|
10
10
|
function Hs(t) {
|
|
11
|
-
const e =
|
|
11
|
+
const e = dt(null);
|
|
12
12
|
return e.current === null && (e.current = t()), e.current;
|
|
13
13
|
}
|
|
14
|
-
const he = typeof window < "u", Us = he ? Bs : de, yn = /* @__PURE__ */
|
|
14
|
+
const he = typeof window < "u", Us = he ? Bs : de, yn = /* @__PURE__ */ st(null);
|
|
15
15
|
function zs(t, e) {
|
|
16
16
|
t.indexOf(e) === -1 && t.push(e);
|
|
17
17
|
}
|
|
@@ -32,7 +32,7 @@ process.env.NODE_ENV !== "production" && (yt = (t, e, n) => {
|
|
|
32
32
|
if (!t)
|
|
33
33
|
throw new Error(zt(e, n));
|
|
34
34
|
});
|
|
35
|
-
const
|
|
35
|
+
const $ = {}, bn = (t) => /^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t);
|
|
36
36
|
function Xs(t) {
|
|
37
37
|
return typeof t == "object" && t !== null;
|
|
38
38
|
}
|
|
@@ -42,7 +42,7 @@ function pe(t) {
|
|
|
42
42
|
let e;
|
|
43
43
|
return () => (e === void 0 && (e = t()), e);
|
|
44
44
|
}
|
|
45
|
-
const
|
|
45
|
+
const it = /* @__NO_SIDE_EFFECTS__ */ (t) => t, qs = (t, e) => (n) => e(t(n)), kt = (...t) => t.reduce(qs), vn = /* @__NO_SIDE_EFFECTS__ */ (t, e, n) => {
|
|
46
46
|
const s = e - t;
|
|
47
47
|
return s === 0 ? 1 : (n - t) / s;
|
|
48
48
|
};
|
|
@@ -71,7 +71,7 @@ class wn {
|
|
|
71
71
|
this.subscriptions.length = 0;
|
|
72
72
|
}
|
|
73
73
|
}
|
|
74
|
-
const L = /* @__NO_SIDE_EFFECTS__ */ (t) => t * 1e3,
|
|
74
|
+
const L = /* @__NO_SIDE_EFFECTS__ */ (t) => t * 1e3, W = /* @__NO_SIDE_EFFECTS__ */ (t) => t / 1e3;
|
|
75
75
|
function Sn(t, e) {
|
|
76
76
|
return e ? t * (1e3 / e) : 0;
|
|
77
77
|
}
|
|
@@ -89,12 +89,12 @@ function Qs(t, e, n, s, i) {
|
|
|
89
89
|
}
|
|
90
90
|
function bt(t, e, n, s) {
|
|
91
91
|
if (t === e && n === s)
|
|
92
|
-
return
|
|
92
|
+
return it;
|
|
93
93
|
const i = (r) => Qs(r, 0, 1, t, n);
|
|
94
94
|
return (r) => r === 0 || r === 1 ? r : An(i(r), e, s);
|
|
95
95
|
}
|
|
96
96
|
const xn = (t) => (e) => e <= 0.5 ? t(2 * e) / 2 : (2 - t(2 * (1 - e))) / 2, Mn = (t) => (e) => 1 - t(1 - e), Cn = /* @__PURE__ */ bt(0.33, 1.53, 0.69, 0.99), me = /* @__PURE__ */ Mn(Cn), Pn = /* @__PURE__ */ xn(me), Fn = (t) => (t *= 2) < 1 ? 0.5 * me(t) : 0.5 * (2 - Math.pow(2, -10 * (t - 1))), ge = (t) => 1 - Math.sin(Math.acos(t)), ti = Mn(ge), On = xn(ge), ei = /* @__PURE__ */ bt(0.42, 0, 1, 1), ni = /* @__PURE__ */ bt(0, 0, 0.58, 1), Dn = /* @__PURE__ */ bt(0.42, 0, 0.58, 1), si = (t) => Array.isArray(t) && typeof t[0] != "number", In = (t) => Array.isArray(t) && typeof t[0] == "number", Be = {
|
|
97
|
-
linear:
|
|
97
|
+
linear: it,
|
|
98
98
|
easeIn: ei,
|
|
99
99
|
easeInOut: Dn,
|
|
100
100
|
easeOut: ni,
|
|
@@ -177,8 +177,8 @@ function Rn(t, e) {
|
|
|
177
177
|
timestamp: 0,
|
|
178
178
|
isProcessing: !1
|
|
179
179
|
}, r = () => n = !0, o = At.reduce((m, A) => (m[A] = ri(r), m), {}), { setup: a, read: c, resolveKeyframes: l, preUpdate: u, update: f, preRender: d, render: h, postRender: y } = o, b = () => {
|
|
180
|
-
const m =
|
|
181
|
-
n = !1,
|
|
180
|
+
const m = $.useManualTiming ? i.timestamp : performance.now();
|
|
181
|
+
n = !1, $.useManualTiming || (i.delta = s ? 1e3 / 60 : Math.max(Math.min(m - i.timestamp, oi), 1)), i.timestamp = m, i.isProcessing = !0, a.process(i), c.process(i), l.process(i), u.process(i), f.process(i), d.process(i), h.process(i), y.process(i), i.isProcessing = !1, n && e && (s = !1, t(b));
|
|
182
182
|
}, v = () => {
|
|
183
183
|
n = !0, s = !0, i.isProcessing || t(b);
|
|
184
184
|
};
|
|
@@ -190,27 +190,27 @@ function Rn(t, e) {
|
|
|
190
190
|
o[At[A]].cancel(m);
|
|
191
191
|
}, state: i, steps: o };
|
|
192
192
|
}
|
|
193
|
-
const { schedule: N, cancel: Yt, state: Pt } = /* @__PURE__ */ Rn(typeof requestAnimationFrame < "u" ? requestAnimationFrame :
|
|
193
|
+
const { schedule: N, cancel: Yt, state: Pt } = /* @__PURE__ */ Rn(typeof requestAnimationFrame < "u" ? requestAnimationFrame : it, !0);
|
|
194
194
|
let Mt;
|
|
195
195
|
function ai() {
|
|
196
196
|
Mt = void 0;
|
|
197
197
|
}
|
|
198
198
|
const E = {
|
|
199
|
-
now: () => (Mt === void 0 && E.set(Pt.isProcessing ||
|
|
199
|
+
now: () => (Mt === void 0 && E.set(Pt.isProcessing || $.useManualTiming ? Pt.timestamp : performance.now()), Mt),
|
|
200
200
|
set: (t) => {
|
|
201
201
|
Mt = t, queueMicrotask(ai);
|
|
202
202
|
}
|
|
203
|
-
}, En = (t) => (e) => typeof e == "string" && e.startsWith(t), kn = /* @__PURE__ */ En("--"), ui = /* @__PURE__ */ En("var(--"), ye = (t) => ui(t) ? ci.test(t.split("/*")[0].trim()) : !1, ci = /var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,
|
|
203
|
+
}, En = (t) => (e) => typeof e == "string" && e.startsWith(t), kn = /* @__PURE__ */ En("--"), ui = /* @__PURE__ */ En("var(--"), ye = (t) => ui(t) ? ci.test(t.split("/*")[0].trim()) : !1, ci = /var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu, rt = {
|
|
204
204
|
test: (t) => typeof t == "number",
|
|
205
205
|
parse: parseFloat,
|
|
206
206
|
transform: (t) => t
|
|
207
207
|
}, pt = {
|
|
208
|
-
...
|
|
208
|
+
...rt,
|
|
209
209
|
transform: (t) => Y(0, 1, t)
|
|
210
210
|
}, xt = {
|
|
211
|
-
...
|
|
211
|
+
...rt,
|
|
212
212
|
default: 1
|
|
213
|
-
},
|
|
213
|
+
}, ht = (t) => Math.round(t * 1e5) / 1e5, be = /-?(?:\d+(?:\.\d+)?|\.\d+)/gu;
|
|
214
214
|
function li(t) {
|
|
215
215
|
return t == null;
|
|
216
216
|
}
|
|
@@ -225,12 +225,12 @@ const fi = /^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s
|
|
|
225
225
|
alpha: a !== void 0 ? parseFloat(a) : 1
|
|
226
226
|
};
|
|
227
227
|
}, di = (t) => Y(0, 255, t), Wt = {
|
|
228
|
-
...
|
|
228
|
+
...rt,
|
|
229
229
|
transform: (t) => Math.round(di(t))
|
|
230
230
|
}, _ = {
|
|
231
231
|
test: /* @__PURE__ */ Te("rgb", "red"),
|
|
232
232
|
parse: /* @__PURE__ */ Nn("red", "green", "blue"),
|
|
233
|
-
transform: ({ red: t, green: e, blue: n, alpha: s = 1 }) => "rgba(" + Wt.transform(t) + ", " + Wt.transform(e) + ", " + Wt.transform(n) + ", " +
|
|
233
|
+
transform: ({ red: t, green: e, blue: n, alpha: s = 1 }) => "rgba(" + Wt.transform(t) + ", " + Wt.transform(e) + ", " + Wt.transform(n) + ", " + ht(pt.transform(s)) + ")"
|
|
234
234
|
};
|
|
235
235
|
function hi(t) {
|
|
236
236
|
let e = "", n = "", s = "", i = "";
|
|
@@ -256,14 +256,14 @@ const Xt = {
|
|
|
256
256
|
}, Z = {
|
|
257
257
|
test: /* @__PURE__ */ Te("hsl", "hue"),
|
|
258
258
|
parse: /* @__PURE__ */ Nn("hue", "saturation", "lightness"),
|
|
259
|
-
transform: ({ hue: t, saturation: e, lightness: n, alpha: s = 1 }) => "hsla(" + Math.round(t) + ", " + Q.transform(
|
|
260
|
-
},
|
|
259
|
+
transform: ({ hue: t, saturation: e, lightness: n, alpha: s = 1 }) => "hsla(" + Math.round(t) + ", " + Q.transform(ht(e)) + ", " + Q.transform(ht(n)) + ", " + ht(pt.transform(s)) + ")"
|
|
260
|
+
}, P = {
|
|
261
261
|
test: (t) => _.test(t) || Xt.test(t) || Z.test(t),
|
|
262
262
|
parse: (t) => _.test(t) ? _.parse(t) : Z.test(t) ? Z.parse(t) : Xt.parse(t),
|
|
263
263
|
transform: (t) => typeof t == "string" ? t : t.hasOwnProperty("red") ? _.transform(t) : Z.transform(t),
|
|
264
264
|
getAnimatableNone: (t) => {
|
|
265
|
-
const e =
|
|
266
|
-
return e.alpha = 0,
|
|
265
|
+
const e = P.parse(t);
|
|
266
|
+
return e.alpha = 0, P.transform(e);
|
|
267
267
|
}
|
|
268
268
|
}, gi = /(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;
|
|
269
269
|
function yi(t) {
|
|
@@ -278,7 +278,7 @@ function mt(t) {
|
|
|
278
278
|
var: []
|
|
279
279
|
}, i = [];
|
|
280
280
|
let r = 0;
|
|
281
|
-
const a = e.replace(vi, (c) => (
|
|
281
|
+
const a = e.replace(vi, (c) => (P.test(c) ? (s.color.push(r), i.push(Bn), n.push(P.parse(c))) : c.startsWith(Ti) ? (s.var.push(r), i.push(bi), n.push(c)) : (s.number.push(r), i.push(Ln), n.push(parseFloat(c))), ++r, $e)).split($e);
|
|
282
282
|
return { values: n, split: a, indexes: s, types: i };
|
|
283
283
|
}
|
|
284
284
|
function Kn(t) {
|
|
@@ -291,17 +291,17 @@ function Wn(t) {
|
|
|
291
291
|
for (let o = 0; o < s; o++)
|
|
292
292
|
if (r += e[o], i[o] !== void 0) {
|
|
293
293
|
const a = n[o];
|
|
294
|
-
a === Ln ? r +=
|
|
294
|
+
a === Ln ? r += ht(i[o]) : a === Bn ? r += P.transform(i[o]) : r += i[o];
|
|
295
295
|
}
|
|
296
296
|
return r;
|
|
297
297
|
};
|
|
298
298
|
}
|
|
299
|
-
const wi = (t) => typeof t == "number" ? 0 :
|
|
299
|
+
const wi = (t) => typeof t == "number" ? 0 : P.test(t) ? P.getAnimatableNone(t) : t;
|
|
300
300
|
function Si(t) {
|
|
301
301
|
const e = Kn(t);
|
|
302
302
|
return Wn(t)(e.map(wi));
|
|
303
303
|
}
|
|
304
|
-
const
|
|
304
|
+
const ot = {
|
|
305
305
|
test: yi,
|
|
306
306
|
parse: Kn,
|
|
307
307
|
createTransformer: Wn,
|
|
@@ -354,7 +354,7 @@ function Ci(t, e) {
|
|
|
354
354
|
return (n) => Nt(t, e, n);
|
|
355
355
|
}
|
|
356
356
|
function ve(t) {
|
|
357
|
-
return typeof t == "number" ? Ci : typeof t == "string" ? ye(t) ? Ft :
|
|
357
|
+
return typeof t == "number" ? Ci : typeof t == "string" ? ye(t) ? Ft : P.test(t) ? Ge : Oi : Array.isArray(t) ? $n : typeof t == "object" ? P.test(t) ? Ge : Pi : Ft;
|
|
358
358
|
}
|
|
359
359
|
function $n(t, e) {
|
|
360
360
|
const n = [...t], s = n.length, i = t.map((r, o) => ve(r)(r, e[o]));
|
|
@@ -383,7 +383,7 @@ function Fi(t, e) {
|
|
|
383
383
|
return n;
|
|
384
384
|
}
|
|
385
385
|
const Oi = (t, e) => {
|
|
386
|
-
const n =
|
|
386
|
+
const n = ot.createTransformer(e), s = mt(t), i = mt(e);
|
|
387
387
|
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 ? qt.has(t) && !i.values.length || qt.has(e) && !s.values.length ? Mi(t, e) : kt($n(Fi(s, i), i.values), n) : (yt(!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.`, "complex-values-different"), Ft(t, e));
|
|
388
388
|
};
|
|
389
389
|
function jn(t, e, n) {
|
|
@@ -420,7 +420,7 @@ function Ii(t, e = 100, n) {
|
|
|
420
420
|
return {
|
|
421
421
|
type: "keyframes",
|
|
422
422
|
ease: (r) => s.next(i * r).value / e,
|
|
423
|
-
duration: /* @__PURE__ */
|
|
423
|
+
duration: /* @__PURE__ */ W(i)
|
|
424
424
|
};
|
|
425
425
|
}
|
|
426
426
|
const Ri = 5;
|
|
@@ -461,7 +461,7 @@ function Ei({ duration: t = x.duration, bounce: e = x.bounce, velocity: n = x.ve
|
|
|
461
461
|
let i, r;
|
|
462
462
|
yt(t <= /* @__PURE__ */ L(x.maxDuration), "Spring duration must be 10 seconds or less", "spring-duration-limit");
|
|
463
463
|
let o = 1 - e;
|
|
464
|
-
o = Y(x.minDamping, x.maxDamping, o), t = Y(x.minDuration, x.maxDuration, /* @__PURE__ */
|
|
464
|
+
o = Y(x.minDamping, x.maxDamping, o), t = Y(x.minDuration, x.maxDuration, /* @__PURE__ */ W(t)), o < 1 ? (i = (l) => {
|
|
465
465
|
const u = l * o, f = u * t, d = u - n, h = Zt(l, o), y = Math.exp(-f);
|
|
466
466
|
return Gt - d / h * y;
|
|
467
467
|
}, r = (l) => {
|
|
@@ -541,8 +541,8 @@ function Dt(t = x.visualDuration, e = x.bounce) {
|
|
|
541
541
|
let { restSpeed: s, restDelta: i } = n;
|
|
542
542
|
const r = n.keyframes[0], o = n.keyframes[n.keyframes.length - 1], a = { done: !1, value: r }, { stiffness: c, damping: l, mass: u, duration: f, velocity: d, isResolvedFromDuration: h } = Ki({
|
|
543
543
|
...n,
|
|
544
|
-
velocity: -/* @__PURE__ */
|
|
545
|
-
}), y = d || 0, b = l / (2 * Math.sqrt(c * u)), v = o - r, p = /* @__PURE__ */
|
|
544
|
+
velocity: -/* @__PURE__ */ W(n.velocity || 0)
|
|
545
|
+
}), y = d || 0, b = l / (2 * Math.sqrt(c * u)), v = o - r, p = /* @__PURE__ */ W(Math.sqrt(c / u)), S = Math.abs(v) < 5;
|
|
546
546
|
s || (s = S ? x.restSpeed.granular : x.restSpeed.default), i || (i = S ? x.restDelta.granular : x.restDelta.default);
|
|
547
547
|
let m;
|
|
548
548
|
if (b < 1) {
|
|
@@ -620,11 +620,11 @@ function Jt({ keyframes: t, velocity: e = 0, power: n = 0.8, timeConstant: s = 3
|
|
|
620
620
|
};
|
|
621
621
|
}
|
|
622
622
|
function Wi(t, e, n) {
|
|
623
|
-
const s = [], i = n ||
|
|
623
|
+
const s = [], i = n || $.mix || jn, r = t.length - 1;
|
|
624
624
|
for (let o = 0; o < r; o++) {
|
|
625
625
|
let a = i(t[o], t[o + 1]);
|
|
626
626
|
if (e) {
|
|
627
|
-
const c = Array.isArray(e) ? e[o] ||
|
|
627
|
+
const c = Array.isArray(e) ? e[o] || it : e;
|
|
628
628
|
a = kt(c, a);
|
|
629
629
|
}
|
|
630
630
|
s.push(a);
|
|
@@ -783,10 +783,10 @@ class Ae extends Ve {
|
|
|
783
783
|
return this.finished.then(e, n);
|
|
784
784
|
}
|
|
785
785
|
get duration() {
|
|
786
|
-
return /* @__PURE__ */
|
|
786
|
+
return /* @__PURE__ */ W(this.calculatedDuration);
|
|
787
787
|
}
|
|
788
788
|
get time() {
|
|
789
|
-
return /* @__PURE__ */
|
|
789
|
+
return /* @__PURE__ */ W(this.currentTime);
|
|
790
790
|
}
|
|
791
791
|
set time(e) {
|
|
792
792
|
var n;
|
|
@@ -798,7 +798,7 @@ class Ae extends Ve {
|
|
|
798
798
|
set speed(e) {
|
|
799
799
|
this.updateTime(E.now());
|
|
800
800
|
const n = this.playbackSpeed !== e;
|
|
801
|
-
this.playbackSpeed = e, n && (this.time = /* @__PURE__ */
|
|
801
|
+
this.playbackSpeed = e, n && (this.time = /* @__PURE__ */ W(this.currentTime));
|
|
802
802
|
}
|
|
803
803
|
play() {
|
|
804
804
|
var i, r;
|
|
@@ -901,7 +901,7 @@ const Ji = (t, e) => {
|
|
|
901
901
|
function Qi(t) {
|
|
902
902
|
return parseFloat(t.trim());
|
|
903
903
|
}
|
|
904
|
-
const
|
|
904
|
+
const at = [
|
|
905
905
|
"transformPerspective",
|
|
906
906
|
"x",
|
|
907
907
|
"y",
|
|
@@ -919,7 +919,7 @@ const ot = [
|
|
|
919
919
|
"skew",
|
|
920
920
|
"skewX",
|
|
921
921
|
"skewY"
|
|
922
|
-
],
|
|
922
|
+
], ut = new Set(at), Ye = (t) => t === rt || t === g, tr = /* @__PURE__ */ new Set(["x", "y", "z"]), er = at.filter((t) => !tr.has(t));
|
|
923
923
|
function nr(t) {
|
|
924
924
|
const e = [];
|
|
925
925
|
return er.forEach((n) => {
|
|
@@ -1025,20 +1025,20 @@ const Yn = /* @__PURE__ */ ur(() => {
|
|
|
1025
1025
|
return !1;
|
|
1026
1026
|
}
|
|
1027
1027
|
return !0;
|
|
1028
|
-
}, "linearEasing"),
|
|
1028
|
+
}, "linearEasing"), ft = ([t, e, n, s]) => `cubic-bezier(${t}, ${e}, ${n}, ${s})`, Xe = {
|
|
1029
1029
|
linear: "linear",
|
|
1030
1030
|
ease: "ease",
|
|
1031
1031
|
easeIn: "ease-in",
|
|
1032
1032
|
easeOut: "ease-out",
|
|
1033
1033
|
easeInOut: "ease-in-out",
|
|
1034
|
-
circIn: /* @__PURE__ */
|
|
1035
|
-
circOut: /* @__PURE__ */
|
|
1036
|
-
backIn: /* @__PURE__ */
|
|
1037
|
-
backOut: /* @__PURE__ */
|
|
1034
|
+
circIn: /* @__PURE__ */ ft([0, 0.65, 0.55, 1]),
|
|
1035
|
+
circOut: /* @__PURE__ */ ft([0.55, 0, 1, 0.45]),
|
|
1036
|
+
backIn: /* @__PURE__ */ ft([0.31, 0.01, 0.66, -0.59]),
|
|
1037
|
+
backOut: /* @__PURE__ */ ft([0.33, 1.53, 0.69, 0.99])
|
|
1038
1038
|
};
|
|
1039
1039
|
function Xn(t, e) {
|
|
1040
1040
|
if (t)
|
|
1041
|
-
return typeof t == "function" ? Yn() ? Gn(t, e) : "ease-out" : In(t) ?
|
|
1041
|
+
return typeof t == "function" ? Yn() ? Gn(t, e) : "ease-out" : In(t) ? ft(t) : Array.isArray(t) ? t.map((n) => Xn(n, e) || Xe.easeOut) : Xe[t];
|
|
1042
1042
|
}
|
|
1043
1043
|
function cr(t, e, n, { delay: s = 0, duration: i = 300, repeat: r = 0, repeatType: o = "loop", ease: a = "easeOut", times: c } = {}, l = void 0) {
|
|
1044
1044
|
const u = {
|
|
@@ -1120,10 +1120,10 @@ class fr extends Ve {
|
|
|
1120
1120
|
get duration() {
|
|
1121
1121
|
var n, s;
|
|
1122
1122
|
const e = ((s = (n = this.animation.effect) == null ? void 0 : n.getComputedTiming) == null ? void 0 : s.call(n).duration) || 0;
|
|
1123
|
-
return /* @__PURE__ */
|
|
1123
|
+
return /* @__PURE__ */ W(Number(e));
|
|
1124
1124
|
}
|
|
1125
1125
|
get time() {
|
|
1126
|
-
return /* @__PURE__ */
|
|
1126
|
+
return /* @__PURE__ */ W(Number(this.animation.currentTime) || 0);
|
|
1127
1127
|
}
|
|
1128
1128
|
set time(e) {
|
|
1129
1129
|
this.finishedTime = null, this.animation.currentTime = /* @__PURE__ */ L(e);
|
|
@@ -1152,7 +1152,7 @@ class fr extends Ve {
|
|
|
1152
1152
|
*/
|
|
1153
1153
|
attachTimeline({ timeline: e, observe: n }) {
|
|
1154
1154
|
var s;
|
|
1155
|
-
return this.allowFlatten && ((s = this.animation.effect) == null || s.updateTiming({ easing: "linear" })), this.animation.onfinish = null, e && or() ? (this.animation.timeline = e,
|
|
1155
|
+
return this.allowFlatten && ((s = this.animation.effect) == null || s.updateTiming({ easing: "linear" })), this.animation.onfinish = null, e && or() ? (this.animation.timeline = e, it) : n(this);
|
|
1156
1156
|
}
|
|
1157
1157
|
}
|
|
1158
1158
|
const Zn = {
|
|
@@ -1195,7 +1195,7 @@ class pr extends fr {
|
|
|
1195
1195
|
}
|
|
1196
1196
|
}
|
|
1197
1197
|
const Ze = (t, e) => e === "zIndex" ? !1 : !!(typeof t == "number" || Array.isArray(t) || typeof t == "string" && // It's animatable if we have a string
|
|
1198
|
-
(
|
|
1198
|
+
(ot.test(t) || t === "0") && // And it contains numbers and/or colors
|
|
1199
1199
|
!t.startsWith("url("));
|
|
1200
1200
|
function mr(t) {
|
|
1201
1201
|
const e = t[0];
|
|
@@ -1262,7 +1262,7 @@ class wr extends Ve {
|
|
|
1262
1262
|
onKeyframesResolved(e, n, s, i) {
|
|
1263
1263
|
this.keyframeResolver = void 0;
|
|
1264
1264
|
const { name: r, type: o, velocity: a, delay: c, isHandoff: l, onUpdate: u } = s;
|
|
1265
|
-
this.resolvedAt = E.now(), gr(e, r, o, a) || ((
|
|
1265
|
+
this.resolvedAt = E.now(), gr(e, r, o, a) || (($.instantAnimations || !c) && (u == null || u(Se(e, s, n))), e[0] = e[e.length - 1], oe(s), s.repeat = 0);
|
|
1266
1266
|
const d = {
|
|
1267
1267
|
startTime: i ? this.resolvedAt ? this.resolvedAt - this.createdAt > vr ? this.resolvedAt : this.createdAt : this.createdAt : void 0,
|
|
1268
1268
|
finalKeyframe: n,
|
|
@@ -1272,7 +1272,7 @@ class wr extends Ve {
|
|
|
1272
1272
|
...d,
|
|
1273
1273
|
element: d.motionValue.owner.current
|
|
1274
1274
|
}) : new Ae(d);
|
|
1275
|
-
h.finished.then(() => this.notifyFinished()).catch(
|
|
1275
|
+
h.finished.then(() => this.notifyFinished()).catch(it), this.pendingTimeline && (this.stopTimeline = h.attachTimeline(this.pendingTimeline), this.pendingTimeline = void 0), this._animation = h;
|
|
1276
1276
|
}
|
|
1277
1277
|
get finished() {
|
|
1278
1278
|
return this._animation ? this.animation.finished : this._finished;
|
|
@@ -1357,11 +1357,11 @@ const ts = /* @__PURE__ */ new Set([
|
|
|
1357
1357
|
"left",
|
|
1358
1358
|
"right",
|
|
1359
1359
|
"bottom",
|
|
1360
|
-
...
|
|
1360
|
+
...at
|
|
1361
1361
|
]), xr = {
|
|
1362
1362
|
test: (t) => t === "auto",
|
|
1363
1363
|
parse: (t) => t
|
|
1364
|
-
}, es = (t) => (e) => e.test(t), ns = [
|
|
1364
|
+
}, es = (t) => (e) => e.test(t), ns = [rt, g, Q, j, mi, pi, xr], Je = (t) => ns.find(es(t));
|
|
1365
1365
|
function Mr(t) {
|
|
1366
1366
|
return typeof t == "number" ? t === 0 : t !== null ? t === "none" || t === "0" || Tn(t) : !0;
|
|
1367
1367
|
}
|
|
@@ -1378,13 +1378,13 @@ function Pr(t) {
|
|
|
1378
1378
|
return s !== n && (r *= 100), e + "(" + r + i + ")";
|
|
1379
1379
|
}
|
|
1380
1380
|
const Fr = /\b([a-z-]*)\(.*?\)/gu, ae = {
|
|
1381
|
-
...
|
|
1381
|
+
...ot,
|
|
1382
1382
|
getAnimatableNone: (t) => {
|
|
1383
1383
|
const e = t.match(Fr);
|
|
1384
1384
|
return e ? e.map(Pr).join(" ") : t;
|
|
1385
1385
|
}
|
|
1386
1386
|
}, Qe = {
|
|
1387
|
-
...
|
|
1387
|
+
...rt,
|
|
1388
1388
|
transform: Math.round
|
|
1389
1389
|
}, Or = {
|
|
1390
1390
|
rotate: j,
|
|
@@ -1456,23 +1456,23 @@ const Fr = /\b([a-z-]*)\(.*?\)/gu, ae = {
|
|
|
1456
1456
|
}, Dr = {
|
|
1457
1457
|
...Me,
|
|
1458
1458
|
// Color props
|
|
1459
|
-
color:
|
|
1460
|
-
backgroundColor:
|
|
1461
|
-
outlineColor:
|
|
1462
|
-
fill:
|
|
1463
|
-
stroke:
|
|
1459
|
+
color: P,
|
|
1460
|
+
backgroundColor: P,
|
|
1461
|
+
outlineColor: P,
|
|
1462
|
+
fill: P,
|
|
1463
|
+
stroke: P,
|
|
1464
1464
|
// Border props
|
|
1465
|
-
borderColor:
|
|
1466
|
-
borderTopColor:
|
|
1467
|
-
borderRightColor:
|
|
1468
|
-
borderBottomColor:
|
|
1469
|
-
borderLeftColor:
|
|
1465
|
+
borderColor: P,
|
|
1466
|
+
borderTopColor: P,
|
|
1467
|
+
borderRightColor: P,
|
|
1468
|
+
borderBottomColor: P,
|
|
1469
|
+
borderLeftColor: P,
|
|
1470
1470
|
filter: ae,
|
|
1471
1471
|
WebkitFilter: ae
|
|
1472
1472
|
}, ss = (t) => Dr[t];
|
|
1473
1473
|
function is(t, e) {
|
|
1474
1474
|
let n = ss(t);
|
|
1475
|
-
return n !== ae && (n =
|
|
1475
|
+
return n !== ae && (n = ot), n.getAnimatableNone ? n.getAnimatableNone(e) : void 0;
|
|
1476
1476
|
}
|
|
1477
1477
|
const Ir = /* @__PURE__ */ new Set(["auto", "none", "0"]);
|
|
1478
1478
|
function Rr(t, e, n) {
|
|
@@ -1848,11 +1848,11 @@ function zr(t, e, n = {}) {
|
|
|
1848
1848
|
(n.useGlobalTarget ? window : a).addEventListener("pointerdown", o, i), Nr(a) && (a.addEventListener("focus", (l) => Ur(l, i)), !Hr(a) && !a.hasAttribute("tabindex") && (a.tabIndex = 0));
|
|
1849
1849
|
}), r;
|
|
1850
1850
|
}
|
|
1851
|
-
const I = (t) => !!(t && t.getVelocity), Yr = [...ns,
|
|
1851
|
+
const I = (t) => !!(t && t.getVelocity), Yr = [...ns, P, ot], Xr = (t) => Yr.find(es(t)), us = st({
|
|
1852
1852
|
transformPagePoint: (t) => t,
|
|
1853
1853
|
isStatic: !1,
|
|
1854
1854
|
reducedMotion: "never"
|
|
1855
|
-
}), Ce =
|
|
1855
|
+
}), Ce = st({ strict: !1 }), rn = {
|
|
1856
1856
|
animation: [
|
|
1857
1857
|
"animate",
|
|
1858
1858
|
"variants",
|
|
@@ -1871,20 +1871,20 @@ const I = (t) => !!(t && t.getVelocity), Yr = [...ns, C, rt], Xr = (t) => Yr.fin
|
|
|
1871
1871
|
pan: ["onPan", "onPanStart", "onPanSessionStart", "onPanEnd"],
|
|
1872
1872
|
inView: ["whileInView", "onViewportEnter", "onViewportLeave"],
|
|
1873
1873
|
layout: ["layout", "layoutId"]
|
|
1874
|
-
},
|
|
1874
|
+
}, nt = {};
|
|
1875
1875
|
for (const t in rn)
|
|
1876
|
-
|
|
1876
|
+
nt[t] = {
|
|
1877
1877
|
isEnabled: (e) => rn[t].some((n) => !!e[n])
|
|
1878
1878
|
};
|
|
1879
1879
|
function on(t) {
|
|
1880
1880
|
for (const e in t)
|
|
1881
|
-
|
|
1882
|
-
...
|
|
1881
|
+
nt[e] = {
|
|
1882
|
+
...nt[e],
|
|
1883
1883
|
...t[e]
|
|
1884
1884
|
};
|
|
1885
1885
|
}
|
|
1886
1886
|
function qr({ children: t, features: e, strict: n = !1 }) {
|
|
1887
|
-
const [, s] = Ks(!Ht(e)), i =
|
|
1887
|
+
const [, s] = Ks(!Ht(e)), i = dt(void 0);
|
|
1888
1888
|
if (!Ht(e)) {
|
|
1889
1889
|
const { renderer: r, ...o } = e;
|
|
1890
1890
|
i.current = r, on(o);
|
|
@@ -1948,7 +1948,7 @@ function Qr(t, e, n) {
|
|
|
1948
1948
|
t.draggable && i.startsWith("onDrag")) && (s[i] = t[i]);
|
|
1949
1949
|
return s;
|
|
1950
1950
|
}
|
|
1951
|
-
const Lt = /* @__PURE__ */
|
|
1951
|
+
const Lt = /* @__PURE__ */ st({});
|
|
1952
1952
|
function Bt(t) {
|
|
1953
1953
|
return t !== null && typeof t == "object" && typeof t.start == "function";
|
|
1954
1954
|
}
|
|
@@ -1989,18 +1989,18 @@ function an(t) {
|
|
|
1989
1989
|
}
|
|
1990
1990
|
const no = {};
|
|
1991
1991
|
function fs(t, { layout: e, layoutId: n }) {
|
|
1992
|
-
return
|
|
1992
|
+
return ut.has(t) || t.startsWith("origin") || (e || n !== void 0) && (!!no[t] || t === "opacity");
|
|
1993
1993
|
}
|
|
1994
1994
|
const so = {
|
|
1995
1995
|
x: "translateX",
|
|
1996
1996
|
y: "translateY",
|
|
1997
1997
|
z: "translateZ",
|
|
1998
1998
|
transformPerspective: "perspective"
|
|
1999
|
-
}, io =
|
|
1999
|
+
}, io = at.length;
|
|
2000
2000
|
function ro(t, e, n) {
|
|
2001
2001
|
let s = "", i = !0;
|
|
2002
2002
|
for (let r = 0; r < io; r++) {
|
|
2003
|
-
const o =
|
|
2003
|
+
const o = at[r], a = t[o];
|
|
2004
2004
|
if (a === void 0)
|
|
2005
2005
|
continue;
|
|
2006
2006
|
let c = !0;
|
|
@@ -2021,7 +2021,7 @@ function Oe(t, e, n) {
|
|
|
2021
2021
|
let o = !1, a = !1;
|
|
2022
2022
|
for (const c in e) {
|
|
2023
2023
|
const l = e[c];
|
|
2024
|
-
if (
|
|
2024
|
+
if (ut.has(c)) {
|
|
2025
2025
|
o = !0;
|
|
2026
2026
|
continue;
|
|
2027
2027
|
} else if (kn(c)) {
|
|
@@ -2241,7 +2241,7 @@ function ys(t, e, n) {
|
|
|
2241
2241
|
const s = Ee(t, e, n);
|
|
2242
2242
|
for (const i in t)
|
|
2243
2243
|
if (I(t[i]) || I(e[i])) {
|
|
2244
|
-
const r =
|
|
2244
|
+
const r = at.indexOf(i) !== -1 ? "attr" + i.charAt(0).toUpperCase() + i.substring(1) : i;
|
|
2245
2245
|
s[r] = t[i];
|
|
2246
2246
|
}
|
|
2247
2247
|
return s;
|
|
@@ -2266,10 +2266,10 @@ function So(t, e, n) {
|
|
|
2266
2266
|
[e]
|
|
2267
2267
|
);
|
|
2268
2268
|
}
|
|
2269
|
-
const ke = (t) => t.replace(/([a-z])([A-Z])/gu, "$1-$2").toLowerCase(), Vo = "framerAppearId", Ts = "data-" + ke(Vo), Ao =
|
|
2269
|
+
const ke = (t) => t.replace(/([a-z])([A-Z])/gu, "$1-$2").toLowerCase(), Vo = "framerAppearId", Ts = "data-" + ke(Vo), Ao = st({});
|
|
2270
2270
|
function xo(t, e, n, s, i) {
|
|
2271
2271
|
var b, v;
|
|
2272
|
-
const { visualElement: r } = k(Lt), o = k(Ce), a = k(yn), c = k(us).reducedMotion, l =
|
|
2272
|
+
const { visualElement: r } = k(Lt), o = k(Ce), a = k(yn), c = k(us).reducedMotion, l = dt(null);
|
|
2273
2273
|
s = s || o.renderer, !l.current && s && (l.current = s(t, {
|
|
2274
2274
|
visualState: e,
|
|
2275
2275
|
parent: r,
|
|
@@ -2280,11 +2280,11 @@ function xo(t, e, n, s, i) {
|
|
|
2280
2280
|
}));
|
|
2281
2281
|
const u = l.current, f = k(Ao);
|
|
2282
2282
|
u && !u.projection && i && (u.type === "html" || u.type === "svg") && Mo(l.current, n, i, f);
|
|
2283
|
-
const d =
|
|
2283
|
+
const d = dt(!1);
|
|
2284
2284
|
js(() => {
|
|
2285
2285
|
u && d.current && u.update(n, a);
|
|
2286
2286
|
});
|
|
2287
|
-
const h = n[Ts], y =
|
|
2287
|
+
const h = n[Ts], y = dt(!!h && !((b = window.MotionHandoffIsComplete) != null && b.call(window, h)) && ((v = window.MotionHasOptimisedAnimation) == null ? void 0 : v.call(window, h)));
|
|
2288
2288
|
return Us(() => {
|
|
2289
2289
|
u && (d.current = !0, window.MotionIsMounted = !0, u.updateFeatures(), u.scheduleRenderMicrotask(), y.current && u.animationState && u.animationState.animateChanges());
|
|
2290
2290
|
}), de(() => {
|
|
@@ -2347,7 +2347,7 @@ function Fo(t, e) {
|
|
|
2347
2347
|
k(Ce).strict, process.env.NODE_ENV;
|
|
2348
2348
|
}
|
|
2349
2349
|
function Oo(t) {
|
|
2350
|
-
const { drag: e, layout: n } =
|
|
2350
|
+
const { drag: e, layout: n } = nt;
|
|
2351
2351
|
if (!e && !n)
|
|
2352
2352
|
return {};
|
|
2353
2353
|
const s = { ...e, ...n };
|
|
@@ -2467,7 +2467,7 @@ class Lo {
|
|
|
2467
2467
|
}
|
|
2468
2468
|
bindToMotionValue(e, n) {
|
|
2469
2469
|
this.valueSubscriptions.has(e) && this.valueSubscriptions.get(e)();
|
|
2470
|
-
const s =
|
|
2470
|
+
const s = ut.has(e);
|
|
2471
2471
|
s && this.onBindTransform && this.onBindTransform();
|
|
2472
2472
|
const i = n.on("change", (o) => {
|
|
2473
2473
|
this.latestValues[e] = o, this.props.onUpdate && N.preRender(this.notifyUpdate), s && this.projection && (this.projection.isTransformDirty = !0), this.scheduleRender();
|
|
@@ -2482,8 +2482,8 @@ class Lo {
|
|
|
2482
2482
|
}
|
|
2483
2483
|
updateFeatures() {
|
|
2484
2484
|
let e = "animation";
|
|
2485
|
-
for (e in
|
|
2486
|
-
const n =
|
|
2485
|
+
for (e in nt) {
|
|
2486
|
+
const n = nt[e];
|
|
2487
2487
|
if (!n)
|
|
2488
2488
|
continue;
|
|
2489
2489
|
const { isEnabled: s, Feature: i } = n;
|
|
@@ -2587,7 +2587,7 @@ class Lo {
|
|
|
2587
2587
|
*/
|
|
2588
2588
|
readValue(e, n) {
|
|
2589
2589
|
let s = this.latestValues[e] !== void 0 || !this.current ? this.latestValues[e] : this.getBaseTargetFromProps(this.props, e) ?? this.readValueFromInstance(this.current, e, this.options);
|
|
2590
|
-
return s != null && (typeof s == "string" && (bn(s) || Tn(s)) ? s = parseFloat(s) : !Xr(s) &&
|
|
2590
|
+
return s != null && (typeof s == "string" && (bn(s) || Tn(s)) ? s = parseFloat(s) : !Xr(s) && ot.test(n) && (s = is(e, n)), this.setBaseTarget(e, I(s) ? s.get() : s)), I(s) ? s.get() : s;
|
|
2591
2591
|
}
|
|
2592
2592
|
/**
|
|
2593
2593
|
* Set the base target to later animate back to. This is currently
|
|
@@ -2662,7 +2662,7 @@ class Ko extends Vs {
|
|
|
2662
2662
|
}
|
|
2663
2663
|
readValueFromInstance(e, n) {
|
|
2664
2664
|
var s;
|
|
2665
|
-
if (
|
|
2665
|
+
if (ut.has(n))
|
|
2666
2666
|
return (s = this.projection) != null && s.isProjecting ? ee(n) : Ji(e, n);
|
|
2667
2667
|
{
|
|
2668
2668
|
const i = Bo(e), r = (kn(n) ? i.getPropertyValue(n) : i[n]) || 0;
|
|
@@ -2717,7 +2717,7 @@ class $o extends Vs {
|
|
|
2717
2717
|
return e[n];
|
|
2718
2718
|
}
|
|
2719
2719
|
readValueFromInstance(e, n) {
|
|
2720
|
-
if (
|
|
2720
|
+
if (ut.has(n)) {
|
|
2721
2721
|
const s = ss(n);
|
|
2722
2722
|
return s && s.default || 0;
|
|
2723
2723
|
}
|
|
@@ -2766,8 +2766,8 @@ function zo(t, e) {
|
|
|
2766
2766
|
const n = t.getValue("willChange");
|
|
2767
2767
|
if (Uo(n))
|
|
2768
2768
|
return n.add(e);
|
|
2769
|
-
if (!n &&
|
|
2770
|
-
const s = new
|
|
2769
|
+
if (!n && $.WillChange) {
|
|
2770
|
+
const s = new $.WillChange("auto");
|
|
2771
2771
|
t.addValue("willChange", s), s.add(e);
|
|
2772
2772
|
}
|
|
2773
2773
|
}
|
|
@@ -2796,7 +2796,7 @@ const Zo = {
|
|
|
2796
2796
|
type: "keyframes",
|
|
2797
2797
|
ease: [0.25, 0.1, 0.35, 1],
|
|
2798
2798
|
duration: 0.3
|
|
2799
|
-
}, ea = (t, { keyframes: e }) => e.length > 2 ? Qo :
|
|
2799
|
+
}, ea = (t, { keyframes: e }) => e.length > 2 ? Qo : ut.has(t) ? t.startsWith("scale") ? Jo(e[1]) : Zo : ta;
|
|
2800
2800
|
function na({ when: t, delay: e, delayChildren: n, staggerChildren: s, staggerDirection: i, repeat: r, repeatType: o, repeatDelay: a, from: c, elapsed: l, ...u }) {
|
|
2801
2801
|
return !!Object.keys(u).length;
|
|
2802
2802
|
}
|
|
@@ -2822,7 +2822,7 @@ const sa = (t, e, n, s = {}, i, r) => (o) => {
|
|
|
2822
2822
|
};
|
|
2823
2823
|
na(a) || Object.assign(u, ea(t, u)), u.duration && (u.duration = /* @__PURE__ */ L(u.duration)), u.repeatDelay && (u.repeatDelay = /* @__PURE__ */ L(u.repeatDelay)), u.from !== void 0 && (u.keyframes[0] = u.from);
|
|
2824
2824
|
let f = !1;
|
|
2825
|
-
if ((u.type === !1 || u.duration === 0 && !u.repeatDelay) && (oe(u), u.delay === 0 && (f = !0)), (
|
|
2825
|
+
if ((u.type === !1 || u.duration === 0 && !u.repeatDelay) && (oe(u), u.delay === 0 && (f = !0)), ($.instantAnimations || $.skipAnimations) && (f = !0, oe(u), u.delay = 0), u.allowFlatten = !a.type && !a.ease, f && !r && e.get() !== void 0) {
|
|
2826
2826
|
const d = qo(u.keyframes, a);
|
|
2827
2827
|
if (d !== void 0) {
|
|
2828
2828
|
N.update(() => {
|
|
@@ -2979,32 +2979,32 @@ function fa(t) {
|
|
|
2979
2979
|
const { prevResolvedValues: vt = {} } = S, wt = {
|
|
2980
2980
|
...vt,
|
|
2981
2981
|
...B
|
|
2982
|
-
}, St = (
|
|
2983
|
-
w = !0, d.has(
|
|
2984
|
-
const
|
|
2985
|
-
|
|
2982
|
+
}, St = (F) => {
|
|
2983
|
+
w = !0, d.has(F) && (O = !0, d.delete(F)), S.needsAnimating[F] = !0;
|
|
2984
|
+
const C = t.getValue(F);
|
|
2985
|
+
C && (C.liveStyle = !1);
|
|
2986
2986
|
};
|
|
2987
|
-
for (const
|
|
2988
|
-
const
|
|
2989
|
-
if (h.hasOwnProperty(
|
|
2987
|
+
for (const F in wt) {
|
|
2988
|
+
const C = B[F], K = vt[F];
|
|
2989
|
+
if (h.hasOwnProperty(F))
|
|
2990
2990
|
continue;
|
|
2991
2991
|
let q = !1;
|
|
2992
|
-
ce(
|
|
2992
|
+
ce(C) && ce(K) ? q = !Ps(C, K) : q = C !== K, q ? C != null ? St(F) : d.add(F) : C !== void 0 && d.has(F) ? St(F) : S.protectedKeys[F] = !0;
|
|
2993
2993
|
}
|
|
2994
2994
|
S.prevProp = m, S.prevResolvedValues = B, S.isActive && (h = { ...h, ...B }), s && t.blockInitialAnimation && (w = !1);
|
|
2995
2995
|
const Vt = V && M;
|
|
2996
|
-
w && (!Vt || O) && f.push(...D.map((
|
|
2997
|
-
const
|
|
2998
|
-
if (typeof
|
|
2999
|
-
const { parent:
|
|
3000
|
-
if (
|
|
2996
|
+
w && (!Vt || O) && f.push(...D.map((F) => {
|
|
2997
|
+
const C = { type: p };
|
|
2998
|
+
if (typeof F == "string" && s && !Vt && t.manuallyAnimateOnMount && t.parent) {
|
|
2999
|
+
const { parent: K } = t, q = tt(K, F);
|
|
3000
|
+
if (K.enteringChildren && q) {
|
|
3001
3001
|
const { delayChildren: Is } = q.transition || {};
|
|
3002
|
-
|
|
3002
|
+
C.delay = Cs(K.enteringChildren, t, Is);
|
|
3003
3003
|
}
|
|
3004
3004
|
}
|
|
3005
3005
|
return {
|
|
3006
|
-
animation:
|
|
3007
|
-
options:
|
|
3006
|
+
animation: F,
|
|
3007
|
+
options: C
|
|
3008
3008
|
};
|
|
3009
3009
|
}));
|
|
3010
3010
|
}
|
|
@@ -3067,14 +3067,14 @@ function fn() {
|
|
|
3067
3067
|
exit: G()
|
|
3068
3068
|
};
|
|
3069
3069
|
}
|
|
3070
|
-
class
|
|
3070
|
+
class ct {
|
|
3071
3071
|
constructor(e) {
|
|
3072
3072
|
this.isMounted = !1, this.node = e;
|
|
3073
3073
|
}
|
|
3074
3074
|
update() {
|
|
3075
3075
|
}
|
|
3076
3076
|
}
|
|
3077
|
-
class ha extends
|
|
3077
|
+
class ha extends ct {
|
|
3078
3078
|
/**
|
|
3079
3079
|
* We dynamically generate the AnimationState manager as it contains a reference
|
|
3080
3080
|
* to the underlying animation library. We only want to load that if we load this,
|
|
@@ -3103,7 +3103,7 @@ class ha extends ut {
|
|
|
3103
3103
|
}
|
|
3104
3104
|
}
|
|
3105
3105
|
let pa = 0;
|
|
3106
|
-
class ma extends
|
|
3106
|
+
class ma extends ct {
|
|
3107
3107
|
constructor() {
|
|
3108
3108
|
super(...arguments), this.id = pa++;
|
|
3109
3109
|
}
|
|
@@ -3150,7 +3150,7 @@ function hn(t, e, n) {
|
|
|
3150
3150
|
const i = "onHover" + n, r = s[i];
|
|
3151
3151
|
r && N.postRender(() => r(e, Os(e)));
|
|
3152
3152
|
}
|
|
3153
|
-
class ya extends
|
|
3153
|
+
class ya extends ct {
|
|
3154
3154
|
mount() {
|
|
3155
3155
|
const { current: e } = this.node;
|
|
3156
3156
|
e && (this.unmount = jr(e, (n, s) => (hn(this.node, s, "Start"), (i) => hn(this.node, i, "End"))));
|
|
@@ -3158,7 +3158,7 @@ class ya extends ut {
|
|
|
3158
3158
|
unmount() {
|
|
3159
3159
|
}
|
|
3160
3160
|
}
|
|
3161
|
-
class ba extends
|
|
3161
|
+
class ba extends ct {
|
|
3162
3162
|
constructor() {
|
|
3163
3163
|
super(...arguments), this.isActive = !1;
|
|
3164
3164
|
}
|
|
@@ -3188,7 +3188,7 @@ function pn(t, e, n) {
|
|
|
3188
3188
|
const i = "onTap" + (n === "End" ? "" : n), r = s[i];
|
|
3189
3189
|
r && N.postRender(() => r(e, Os(e)));
|
|
3190
3190
|
}
|
|
3191
|
-
class Ta extends
|
|
3191
|
+
class Ta extends ct {
|
|
3192
3192
|
mount() {
|
|
3193
3193
|
const { current: e } = this.node;
|
|
3194
3194
|
e && (this.unmount = zr(e, (n, s) => (pn(this.node, s, "Start"), (i, { success: r }) => pn(this.node, i, r ? "End" : "Cancel")), { useGlobalTarget: this.node.props.globalTapTarget }));
|
|
@@ -3218,7 +3218,7 @@ const Aa = {
|
|
|
3218
3218
|
some: 0,
|
|
3219
3219
|
all: 1
|
|
3220
3220
|
};
|
|
3221
|
-
class xa extends
|
|
3221
|
+
class xa extends ct {
|
|
3222
3222
|
constructor() {
|
|
3223
3223
|
super(...arguments), this.hasEnteredView = !1, this.isInView = !1;
|
|
3224
3224
|
}
|
|
@@ -3280,13 +3280,13 @@ const Oa = /* @__PURE__ */ Fa("div"), Da = {
|
|
|
3280
3280
|
shadow: "2"
|
|
3281
3281
|
},
|
|
3282
3282
|
dark: {}
|
|
3283
|
-
}, Ds =
|
|
3283
|
+
}, Ds = et.createContext({
|
|
3284
3284
|
groupOpen: !1,
|
|
3285
3285
|
setGroupOpen: () => {
|
|
3286
3286
|
}
|
|
3287
3287
|
}), Ia = ({ open: t, delay: e = 600 }) => {
|
|
3288
|
-
const n =
|
|
3289
|
-
return
|
|
3288
|
+
const n = et.useContext(Ds);
|
|
3289
|
+
return et.useEffect(() => {
|
|
3290
3290
|
let s = null;
|
|
3291
3291
|
return n.setGroupOpen && (t === !0 && n.setGroupOpen(!0), t === !1 && (s = setTimeout(() => {
|
|
3292
3292
|
n.setGroupOpen && n.setGroupOpen(!1);
|
|
@@ -3297,7 +3297,7 @@ const Oa = /* @__PURE__ */ Fa("div"), Da = {
|
|
|
3297
3297
|
groupOpen: n.groupOpen
|
|
3298
3298
|
};
|
|
3299
3299
|
}, Wa = ({ children: t }) => {
|
|
3300
|
-
const [e, n] =
|
|
3300
|
+
const [e, n] = et.useState(!1);
|
|
3301
3301
|
return /* @__PURE__ */ R(Ds.Provider, { value: { groupOpen: e, setGroupOpen: n }, children: t });
|
|
3302
3302
|
}, $a = ({
|
|
3303
3303
|
// Radix Tooltip Provider Props
|
|
@@ -3337,41 +3337,41 @@ const Oa = /* @__PURE__ */ Fa("div"), Da = {
|
|
|
3337
3337
|
prop: i,
|
|
3338
3338
|
onChange: r,
|
|
3339
3339
|
defaultProp: s ?? !1
|
|
3340
|
-
}), { groupOpen: wt } = Ia({ open: !!B, delay: t }), St =
|
|
3341
|
-
(
|
|
3342
|
-
), Vt = wt || St ? 0 : t, Ne = !wt,
|
|
3343
|
-
if (
|
|
3340
|
+
}), { groupOpen: wt } = Ia({ open: !!B, delay: t }), St = et.Children.toArray(D).some(
|
|
3341
|
+
(C) => et.isValidElement(C) ? C.props.disabled : !1
|
|
3342
|
+
), Vt = wt || St ? 0 : t, Ne = !wt, F = (C) => {
|
|
3343
|
+
if (C === "top")
|
|
3344
3344
|
return {
|
|
3345
3345
|
y: -5
|
|
3346
3346
|
};
|
|
3347
|
-
if (
|
|
3347
|
+
if (C === "bottom")
|
|
3348
3348
|
return {
|
|
3349
3349
|
y: 5
|
|
3350
3350
|
};
|
|
3351
|
-
if (
|
|
3351
|
+
if (C === "left")
|
|
3352
3352
|
return {
|
|
3353
3353
|
x: -5
|
|
3354
3354
|
};
|
|
3355
|
-
if (
|
|
3355
|
+
if (C === "right")
|
|
3356
3356
|
return {
|
|
3357
3357
|
x: 5
|
|
3358
3358
|
};
|
|
3359
3359
|
};
|
|
3360
3360
|
return /* @__PURE__ */ R(qr, { features: Pa, children: /* @__PURE__ */ R(
|
|
3361
|
-
|
|
3361
|
+
lt.Provider,
|
|
3362
3362
|
{
|
|
3363
3363
|
delayDuration: Vt,
|
|
3364
3364
|
skipDelayDuration: e,
|
|
3365
3365
|
disableHoverableContent: n,
|
|
3366
3366
|
children: /* @__PURE__ */ mn(
|
|
3367
|
-
|
|
3367
|
+
lt.Root,
|
|
3368
3368
|
{
|
|
3369
3369
|
open: M === !1 ? !1 : B,
|
|
3370
3370
|
onOpenChange: vt,
|
|
3371
3371
|
children: [
|
|
3372
|
-
/* @__PURE__ */ R(
|
|
3373
|
-
/* @__PURE__ */ R(
|
|
3374
|
-
|
|
3372
|
+
/* @__PURE__ */ R(lt.Trigger, { asChild: !0, ref: O, children: /* @__PURE__ */ R(ks, { children: D }) }),
|
|
3373
|
+
/* @__PURE__ */ R(lt.Portal, { children: /* @__PURE__ */ R(
|
|
3374
|
+
lt.Content,
|
|
3375
3375
|
{
|
|
3376
3376
|
"aria-label": o,
|
|
3377
3377
|
onEscapeKeyDown: a,
|
|
@@ -3398,7 +3398,7 @@ const Oa = /* @__PURE__ */ Fa("div"), Da = {
|
|
|
3398
3398
|
initial: Ne && !A ? {
|
|
3399
3399
|
opacity: 0,
|
|
3400
3400
|
scale: 0.5,
|
|
3401
|
-
...
|
|
3401
|
+
...F(u)
|
|
3402
3402
|
} : {},
|
|
3403
3403
|
animate: {
|
|
3404
3404
|
opacity: 1,
|