@foris/ai-agent 2.0.6 → 2.0.8
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/ai-agent.es.js +181 -181
- package/dist/ai-agent.umd.js +1 -1
- package/dist/style.css +1 -1
- package/package.json +3 -3
package/dist/ai-agent.es.js
CHANGED
|
@@ -18268,7 +18268,7 @@ function av({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
18268
18268
|
this.id = U4++, this.animationId = 0, this.animationCommitId = 0, this.children = /* @__PURE__ */ new Set(), this.options = {}, this.isTreeAnimating = !1, this.isAnimationBlocked = !1, this.isLayoutDirty = !1, this.isProjectionDirty = !1, this.isSharedProjectionDirty = !1, this.isTransformDirty = !1, this.updateManuallyBlocked = !1, this.updateBlockedByResize = !1, this.isUpdating = !1, this.isSVG = !1, this.needsReset = !1, this.shouldResetTransform = !1, this.hasCheckedOptimisedAppear = !1, this.treeScale = { x: 1, y: 1 }, this.eventHandlers = /* @__PURE__ */ new Map(), this.hasTreeAnimated = !1, this.layoutVersion = 0, this.updateScheduled = !1, this.scheduleUpdate = () => this.update(), this.projectionUpdateScheduled = !1, this.checkUpdateFailed = () => {
|
|
18269
18269
|
this.isUpdating && (this.isUpdating = !1, this.clearAllSnapshots());
|
|
18270
18270
|
}, this.updateProjection = () => {
|
|
18271
|
-
this.projectionUpdateScheduled = !1, this.nodes.forEach(X4), this.nodes.forEach(
|
|
18271
|
+
this.projectionUpdateScheduled = !1, this.nodes.forEach(X4), this.nodes.forEach(n5), this.nodes.forEach(i5), this.nodes.forEach(Y4);
|
|
18272
18272
|
}, this.resolvedRelativeTargetAt = 0, this.linkedParentVersion = 0, this.hasProjected = !1, this.isVisible = !0, this.animationProgress = 0, this.sharedNodes = /* @__PURE__ */ new Map(), this.latestValues = s, this.root = o ? o.root || o : this, this.path = o ? [...o.path, o] : [], this.parent = o, this.depth = o ? o.depth + 1 : 0;
|
|
18273
18273
|
for (let l = 0; l < this.path.length; l++)
|
|
18274
18274
|
this.path[l].shouldResetTransform = !0;
|
|
@@ -18307,7 +18307,7 @@ function av({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
18307
18307
|
this.target = void 0, this.relativeTarget = void 0;
|
|
18308
18308
|
return;
|
|
18309
18309
|
}
|
|
18310
|
-
const h = this.options.transition || c.getDefaultTransition() ||
|
|
18310
|
+
const h = this.options.transition || c.getDefaultTransition() || l5, { onLayoutAnimationStart: f, onLayoutAnimationComplete: g } = c.getProps(), b = !this.targetLayout || !tv(this.targetLayout, m), y = !d && p;
|
|
18311
18311
|
if (this.options.layoutRoot || this.resumeFrom || y || d && (b || !this.currentAnimation)) {
|
|
18312
18312
|
this.resumeFrom && (this.resumingFrom = this.resumeFrom, this.resumingFrom.resumingFrom = void 0);
|
|
18313
18313
|
const w = {
|
|
@@ -18341,7 +18341,7 @@ function av({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
18341
18341
|
}
|
|
18342
18342
|
// Note: currently only running on root node
|
|
18343
18343
|
startUpdate() {
|
|
18344
|
-
this.isUpdateBlocked() || (this.isUpdating = !0, this.nodes && this.nodes.forEach(
|
|
18344
|
+
this.isUpdateBlocked() || (this.isUpdating = !0, this.nodes && this.nodes.forEach(r5), this.animationId++);
|
|
18345
18345
|
}
|
|
18346
18346
|
getTransformTemplate() {
|
|
18347
18347
|
const { visualElement: s } = this.options;
|
|
@@ -18375,7 +18375,7 @@ function av({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
18375
18375
|
this.nodes.forEach(hy);
|
|
18376
18376
|
return;
|
|
18377
18377
|
}
|
|
18378
|
-
this.animationCommitId = this.animationId, this.isUpdating ? (this.isUpdating = !1, this.nodes.forEach(
|
|
18378
|
+
this.animationCommitId = this.animationId, this.isUpdating ? (this.isUpdating = !1, this.nodes.forEach(e5), this.nodes.forEach(t5), this.nodes.forEach(K4), this.nodes.forEach(Z4)) : this.nodes.forEach(hy), this.clearAllSnapshots();
|
|
18379
18379
|
const o = ot.now();
|
|
18380
18380
|
Ge.delta = Mn(0, 1e3 / 60, o - Ge.timestamp), Ge.timestamp = o, Ge.isProcessing = !0, Ju.update.process(Ge), Ju.preRender.process(Ge), Ju.render.process(Ge), Ge.isProcessing = !1;
|
|
18381
18381
|
}
|
|
@@ -18383,7 +18383,7 @@ function av({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
18383
18383
|
this.updateScheduled || (this.updateScheduled = !0, tf.read(this.scheduleUpdate));
|
|
18384
18384
|
}
|
|
18385
18385
|
clearAllSnapshots() {
|
|
18386
|
-
this.nodes.forEach(Q4), this.sharedNodes.forEach(
|
|
18386
|
+
this.nodes.forEach(Q4), this.sharedNodes.forEach(a5);
|
|
18387
18387
|
}
|
|
18388
18388
|
scheduleUpdateProjection() {
|
|
18389
18389
|
this.projectionUpdateScheduled || (this.projectionUpdateScheduled = !0, pe.preRender(this.updateProjection, !1, !0));
|
|
@@ -18432,7 +18432,7 @@ function av({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
18432
18432
|
measure(s = !0) {
|
|
18433
18433
|
const o = this.measurePageBox();
|
|
18434
18434
|
let l = this.removeElementScroll(o);
|
|
18435
|
-
return s && (l = this.removeTransform(l)),
|
|
18435
|
+
return s && (l = this.removeTransform(l)), c5(l), {
|
|
18436
18436
|
animationId: this.root.animationId,
|
|
18437
18437
|
measuredBox: o,
|
|
18438
18438
|
layoutBox: l,
|
|
@@ -18446,7 +18446,7 @@ function av({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
18446
18446
|
if (!s)
|
|
18447
18447
|
return De();
|
|
18448
18448
|
const o = s.measureViewportBox();
|
|
18449
|
-
if (!(((c = this.scroll) == null ? void 0 : c.wasRoot) || this.path.some(
|
|
18449
|
+
if (!(((c = this.scroll) == null ? void 0 : c.wasRoot) || this.path.some(u5))) {
|
|
18450
18450
|
const { scroll: u } = this.root;
|
|
18451
18451
|
u && (gn(o.x, u.offset.x), gn(o.y, u.offset.y));
|
|
18452
18452
|
}
|
|
@@ -18568,12 +18568,12 @@ function av({ attachResizeListener: t, defaultParent: e, measureScroll: n, check
|
|
|
18568
18568
|
setAnimationOrigin(s, o = !1) {
|
|
18569
18569
|
const l = this.snapshot, c = l ? l.latestValues : {}, u = { ...this.latestValues }, d = Gr();
|
|
18570
18570
|
(!this.relativeParent || !this.relativeParent.options.layoutRoot) && (this.relativeTarget = this.relativeTargetOrigin = void 0), this.attemptToResolveRelativeTarget = !o;
|
|
18571
|
-
const p = De(), m = l ? l.source : void 0, h = this.layout ? this.layout.source : void 0, f = m !== h, g = this.getStack(), b = !g || g.members.length <= 1, y = !!(f && !b && this.options.crossfade === !0 && !this.path.some(
|
|
18571
|
+
const p = De(), m = l ? l.source : void 0, h = this.layout ? this.layout.source : void 0, f = m !== h, g = this.getStack(), b = !g || g.members.length <= 1, y = !!(f && !b && this.options.crossfade === !0 && !this.path.some(o5));
|
|
18572
18572
|
this.animationProgress = 0;
|
|
18573
18573
|
let w;
|
|
18574
18574
|
this.mixTargetDelta = (_) => {
|
|
18575
18575
|
const x = _ / 1e3;
|
|
18576
|
-
gy(d.x, s.x, x), gy(d.y, s.y, x), this.setTargetDelta(d), this.relativeTarget && this.relativeTargetOrigin && this.layout && this.relativeParent && this.relativeParent.layout && (ec(p, this.layout.layoutBox, this.relativeParent.layout.layoutBox, this.options.layoutAnchor || void 0),
|
|
18576
|
+
gy(d.x, s.x, x), gy(d.y, s.y, x), this.setTargetDelta(d), this.relativeTarget && this.relativeTargetOrigin && this.layout && this.relativeParent && this.relativeParent.layout && (ec(p, this.layout.layoutBox, this.relativeParent.layout.layoutBox, this.options.layoutAnchor || void 0), s5(this.relativeTarget, this.relativeTargetOrigin, p, x), w && B4(this.relativeTarget, w) && (this.isProjectionDirty = !1), w || (w = De()), Vt(w, this.relativeTarget)), f && (this.animationValues = u, N4(u, c, this.latestValues, x, y, b)), this.root.scheduleUpdateProjection(), this.scheduleRender(), this.animationProgress = x;
|
|
18577
18577
|
}, this.mixTargetDelta(this.options.layoutRoot ? 1e3 : 0);
|
|
18578
18578
|
}
|
|
18579
18579
|
startAnimation(s) {
|
|
@@ -18787,26 +18787,26 @@ function J4(t) {
|
|
|
18787
18787
|
function hy(t) {
|
|
18788
18788
|
t.isLayoutDirty = !1;
|
|
18789
18789
|
}
|
|
18790
|
-
function
|
|
18790
|
+
function e5(t) {
|
|
18791
18791
|
t.isAnimationBlocked && t.layout && !t.isLayoutDirty && (t.snapshot = t.layout, t.isLayoutDirty = !0);
|
|
18792
18792
|
}
|
|
18793
|
-
function
|
|
18793
|
+
function t5(t) {
|
|
18794
18794
|
const { visualElement: e } = t.options;
|
|
18795
18795
|
e && e.getProps().onBeforeLayoutMeasure && e.notify("BeforeLayoutMeasure"), t.resetTransform();
|
|
18796
18796
|
}
|
|
18797
18797
|
function fy(t) {
|
|
18798
18798
|
t.finishAnimation(), t.targetDelta = t.relativeTarget = t.target = void 0, t.isProjectionDirty = !0;
|
|
18799
18799
|
}
|
|
18800
|
-
function
|
|
18800
|
+
function n5(t) {
|
|
18801
18801
|
t.resolveTargetDelta();
|
|
18802
18802
|
}
|
|
18803
|
-
function
|
|
18803
|
+
function i5(t) {
|
|
18804
18804
|
t.calcProjection();
|
|
18805
18805
|
}
|
|
18806
|
-
function
|
|
18806
|
+
function r5(t) {
|
|
18807
18807
|
t.resetSkewAndRotation();
|
|
18808
18808
|
}
|
|
18809
|
-
function
|
|
18809
|
+
function a5(t) {
|
|
18810
18810
|
t.removeLeadSnapshot();
|
|
18811
18811
|
}
|
|
18812
18812
|
function gy(t, e, n) {
|
|
@@ -18815,30 +18815,30 @@ function gy(t, e, n) {
|
|
|
18815
18815
|
function by(t, e, n, i) {
|
|
18816
18816
|
t.min = be(e.min, n.min, i), t.max = be(e.max, n.max, i);
|
|
18817
18817
|
}
|
|
18818
|
-
function
|
|
18818
|
+
function s5(t, e, n, i) {
|
|
18819
18819
|
by(t.x, e.x, n.x, i), by(t.y, e.y, n.y, i);
|
|
18820
18820
|
}
|
|
18821
|
-
function
|
|
18821
|
+
function o5(t) {
|
|
18822
18822
|
return t.animationValues && t.animationValues.opacityExit !== void 0;
|
|
18823
18823
|
}
|
|
18824
|
-
const
|
|
18824
|
+
const l5 = {
|
|
18825
18825
|
duration: 0.45,
|
|
18826
18826
|
ease: [0.4, 0, 0.1, 1]
|
|
18827
18827
|
}, yy = (t) => typeof navigator < "u" && navigator.userAgent && navigator.userAgent.toLowerCase().includes(t), wy = yy("applewebkit/") && !yy("chrome/") ? Math.round : Lt;
|
|
18828
18828
|
function ky(t) {
|
|
18829
18829
|
t.min = wy(t.min), t.max = wy(t.max);
|
|
18830
18830
|
}
|
|
18831
|
-
function
|
|
18831
|
+
function c5(t) {
|
|
18832
18832
|
ky(t.x), ky(t.y);
|
|
18833
18833
|
}
|
|
18834
18834
|
function sv(t, e, n) {
|
|
18835
18835
|
return t === "position" || t === "preserve-aspect" && !M4(ly(e), ly(n), 0.2);
|
|
18836
18836
|
}
|
|
18837
|
-
function
|
|
18837
|
+
function u5(t) {
|
|
18838
18838
|
var e;
|
|
18839
18839
|
return t !== t.root && ((e = t.scroll) == null ? void 0 : e.wasRoot);
|
|
18840
18840
|
}
|
|
18841
|
-
const
|
|
18841
|
+
const d5 = av({
|
|
18842
18842
|
attachResizeListener: (t, e) => vs(t, "resize", e),
|
|
18843
18843
|
measureScroll: () => {
|
|
18844
18844
|
var t, e;
|
|
@@ -18857,7 +18857,7 @@ const dF = av({
|
|
|
18857
18857
|
}),
|
|
18858
18858
|
defaultParent: () => {
|
|
18859
18859
|
if (!cd.current) {
|
|
18860
|
-
const t = new
|
|
18860
|
+
const t = new d5({});
|
|
18861
18861
|
t.mount(window), t.setOptions({ layoutScroll: !0 }), cd.current = t;
|
|
18862
18862
|
}
|
|
18863
18863
|
return cd.current;
|
|
@@ -18871,7 +18871,7 @@ const dF = av({
|
|
|
18871
18871
|
isStatic: !1,
|
|
18872
18872
|
reducedMotion: "never"
|
|
18873
18873
|
});
|
|
18874
|
-
function
|
|
18874
|
+
function p5(t = !0) {
|
|
18875
18875
|
const e = Ce(Ih);
|
|
18876
18876
|
if (e === null)
|
|
18877
18877
|
return [!0, null];
|
|
@@ -18904,7 +18904,7 @@ const cv = Tt({ strict: !1 }), _y = {
|
|
|
18904
18904
|
layout: ["layout", "layoutId"]
|
|
18905
18905
|
};
|
|
18906
18906
|
let xy = !1;
|
|
18907
|
-
function
|
|
18907
|
+
function m5() {
|
|
18908
18908
|
if (xy)
|
|
18909
18909
|
return;
|
|
18910
18910
|
const t = {};
|
|
@@ -18915,9 +18915,9 @@ function mF() {
|
|
|
18915
18915
|
N1(t), xy = !0;
|
|
18916
18916
|
}
|
|
18917
18917
|
function uv() {
|
|
18918
|
-
return
|
|
18918
|
+
return m5(), n4();
|
|
18919
18919
|
}
|
|
18920
|
-
function
|
|
18920
|
+
function h5(t) {
|
|
18921
18921
|
const e = uv();
|
|
18922
18922
|
for (const n in t)
|
|
18923
18923
|
e[n] = {
|
|
@@ -18926,7 +18926,7 @@ function hF(t) {
|
|
|
18926
18926
|
};
|
|
18927
18927
|
N1(e);
|
|
18928
18928
|
}
|
|
18929
|
-
const
|
|
18929
|
+
const f5 = /* @__PURE__ */ new Set([
|
|
18930
18930
|
"animate",
|
|
18931
18931
|
"exit",
|
|
18932
18932
|
"variants",
|
|
@@ -18960,17 +18960,17 @@ const fF = /* @__PURE__ */ new Set([
|
|
|
18960
18960
|
"viewport"
|
|
18961
18961
|
]);
|
|
18962
18962
|
function tc(t) {
|
|
18963
|
-
return t.startsWith("while") || t.startsWith("drag") && t !== "draggable" || t.startsWith("layout") || t.startsWith("onTap") || t.startsWith("onPan") || t.startsWith("onLayout") ||
|
|
18963
|
+
return t.startsWith("while") || t.startsWith("drag") && t !== "draggable" || t.startsWith("layout") || t.startsWith("onTap") || t.startsWith("onPan") || t.startsWith("onLayout") || f5.has(t);
|
|
18964
18964
|
}
|
|
18965
18965
|
let dv = (t) => !tc(t);
|
|
18966
|
-
function
|
|
18966
|
+
function g5(t) {
|
|
18967
18967
|
typeof t == "function" && (dv = (e) => e.startsWith("on") ? !tc(e) : t(e));
|
|
18968
18968
|
}
|
|
18969
18969
|
try {
|
|
18970
|
-
|
|
18970
|
+
g5(require("@emotion/is-prop-valid").default);
|
|
18971
18971
|
} catch {
|
|
18972
18972
|
}
|
|
18973
|
-
function
|
|
18973
|
+
function b5(t, e, n) {
|
|
18974
18974
|
const i = {};
|
|
18975
18975
|
for (const r in t)
|
|
18976
18976
|
r === "values" && typeof t.values == "object" || He(t[r]) || (dv(r) || n === !0 && tc(r) || !e && !tc(r) || // If trying to use native HTML drag events, forward drag listeners
|
|
@@ -18978,7 +18978,7 @@ function bF(t, e, n) {
|
|
|
18978
18978
|
return i;
|
|
18979
18979
|
}
|
|
18980
18980
|
const ru = /* @__PURE__ */ Tt({});
|
|
18981
|
-
function
|
|
18981
|
+
function y5(t, e) {
|
|
18982
18982
|
if (iu(t)) {
|
|
18983
18983
|
const { initial: n, animate: i } = t;
|
|
18984
18984
|
return {
|
|
@@ -18988,8 +18988,8 @@ function yF(t, e) {
|
|
|
18988
18988
|
}
|
|
18989
18989
|
return t.inherit !== !1 ? e : {};
|
|
18990
18990
|
}
|
|
18991
|
-
function
|
|
18992
|
-
const { initial: e, animate: n } =
|
|
18991
|
+
function w5(t) {
|
|
18992
|
+
const { initial: e, animate: n } = y5(t, Ce(ru));
|
|
18993
18993
|
return br(() => ({ initial: e, animate: n }), [vy(e), vy(n)]);
|
|
18994
18994
|
}
|
|
18995
18995
|
function vy(t) {
|
|
@@ -19005,25 +19005,25 @@ function pv(t, e, n) {
|
|
|
19005
19005
|
for (const i in e)
|
|
19006
19006
|
!He(e[i]) && !W1(i, n) && (t[i] = e[i]);
|
|
19007
19007
|
}
|
|
19008
|
-
function
|
|
19008
|
+
function k5({ transformTemplate: t }, e) {
|
|
19009
19009
|
return br(() => {
|
|
19010
19010
|
const n = cf();
|
|
19011
19011
|
return of(n, e, t), Object.assign({}, n.vars, n.style);
|
|
19012
19012
|
}, [e]);
|
|
19013
19013
|
}
|
|
19014
|
-
function
|
|
19014
|
+
function _5(t, e) {
|
|
19015
19015
|
const n = t.style || {}, i = {};
|
|
19016
|
-
return pv(i, n, t), Object.assign(i,
|
|
19016
|
+
return pv(i, n, t), Object.assign(i, k5(t, e)), i;
|
|
19017
19017
|
}
|
|
19018
|
-
function
|
|
19019
|
-
const n = {}, i =
|
|
19018
|
+
function x5(t, e) {
|
|
19019
|
+
const n = {}, i = _5(t, e);
|
|
19020
19020
|
return t.drag && t.dragListener !== !1 && (n.draggable = !1, i.userSelect = i.WebkitUserSelect = i.WebkitTouchCallout = "none", i.touchAction = t.drag === !0 ? "none" : `pan-${t.drag === "x" ? "y" : "x"}`), t.tabIndex === void 0 && (t.onTap || t.onTapStart || t.whileTap) && (n.tabIndex = 0), n.style = i, n;
|
|
19021
19021
|
}
|
|
19022
19022
|
const mv = () => ({
|
|
19023
19023
|
...cf(),
|
|
19024
19024
|
attrs: {}
|
|
19025
19025
|
});
|
|
19026
|
-
function
|
|
19026
|
+
function v5(t, e, n, i) {
|
|
19027
19027
|
const r = br(() => {
|
|
19028
19028
|
const a = mv();
|
|
19029
19029
|
return H1(a, e, K1(i), t.transformTemplate, t.style), {
|
|
@@ -19037,7 +19037,7 @@ function vF(t, e, n, i) {
|
|
|
19037
19037
|
}
|
|
19038
19038
|
return r;
|
|
19039
19039
|
}
|
|
19040
|
-
const
|
|
19040
|
+
const C5 = [
|
|
19041
19041
|
"animate",
|
|
19042
19042
|
"circle",
|
|
19043
19043
|
"defs",
|
|
@@ -19077,27 +19077,27 @@ function uf(t) {
|
|
|
19077
19077
|
/**
|
|
19078
19078
|
* If it's in our list of lowercase SVG tags, it's an SVG component
|
|
19079
19079
|
*/
|
|
19080
|
-
!!(
|
|
19080
|
+
!!(C5.indexOf(t) > -1 || /**
|
|
19081
19081
|
* If it contains a capital letter, it's an SVG component
|
|
19082
19082
|
*/
|
|
19083
19083
|
/[A-Z]/u.test(t))
|
|
19084
19084
|
)
|
|
19085
19085
|
);
|
|
19086
19086
|
}
|
|
19087
|
-
function $
|
|
19088
|
-
const l = (s ?? uf(t) ?
|
|
19087
|
+
function $5(t, e, n, { latestValues: i }, r, a = !1, s) {
|
|
19088
|
+
const l = (s ?? uf(t) ? v5 : x5)(e, i, r, t), c = b5(e, typeof t == "string", a), u = t !== Hw ? { ...c, ...l, ref: n } : {}, { children: d } = e, p = br(() => He(d) ? d.get() : d, [d]);
|
|
19089
19089
|
return vl(t, {
|
|
19090
19090
|
...u,
|
|
19091
19091
|
children: p
|
|
19092
19092
|
});
|
|
19093
19093
|
}
|
|
19094
|
-
function
|
|
19094
|
+
function S5({ scrapeMotionValuesFromProps: t, createRenderState: e }, n, i, r) {
|
|
19095
19095
|
return {
|
|
19096
|
-
latestValues:
|
|
19096
|
+
latestValues: A5(n, i, r, t),
|
|
19097
19097
|
renderState: e()
|
|
19098
19098
|
};
|
|
19099
19099
|
}
|
|
19100
|
-
function
|
|
19100
|
+
function A5(t, e, n, i) {
|
|
19101
19101
|
const r = {}, a = i(t, {});
|
|
19102
19102
|
for (const p in a)
|
|
19103
19103
|
r[p] = ul(a[p]);
|
|
@@ -19129,16 +19129,16 @@ function AF(t, e, n, i) {
|
|
|
19129
19129
|
return r;
|
|
19130
19130
|
}
|
|
19131
19131
|
const hv = (t) => (e, n) => {
|
|
19132
|
-
const i = Ce(ru), r = Ce(Ih), a = () =>
|
|
19132
|
+
const i = Ce(ru), r = Ce(Ih), a = () => S5(t, e, i, r);
|
|
19133
19133
|
return n ? a() : CI(a);
|
|
19134
|
-
},
|
|
19134
|
+
}, T5 = /* @__PURE__ */ hv({
|
|
19135
19135
|
scrapeMotionValuesFromProps: lf,
|
|
19136
19136
|
createRenderState: cf
|
|
19137
|
-
}),
|
|
19137
|
+
}), E5 = /* @__PURE__ */ hv({
|
|
19138
19138
|
scrapeMotionValuesFromProps: Z1,
|
|
19139
19139
|
createRenderState: mv
|
|
19140
|
-
}),
|
|
19141
|
-
function
|
|
19140
|
+
}), M5 = Symbol.for("motionComponentSymbol");
|
|
19141
|
+
function P5(t, e, n) {
|
|
19142
19142
|
const i = Z(n);
|
|
19143
19143
|
Uw(() => {
|
|
19144
19144
|
i.current = n;
|
|
@@ -19161,7 +19161,7 @@ const fv = Tt({});
|
|
|
19161
19161
|
function Dr(t) {
|
|
19162
19162
|
return t && typeof t == "object" && Object.prototype.hasOwnProperty.call(t, "current");
|
|
19163
19163
|
}
|
|
19164
|
-
function
|
|
19164
|
+
function j5(t, e, n, i, r, a) {
|
|
19165
19165
|
var w, _;
|
|
19166
19166
|
const { visualElement: s } = Ce(ru), o = Ce(cv), l = Ce(Ih), c = Ce(lv), u = c.reducedMotion, d = c.skipAnimations, p = Z(null), m = Z(!1);
|
|
19167
19167
|
i = i || o.renderer, !p.current && i && (p.current = i(t, {
|
|
@@ -19175,7 +19175,7 @@ function jF(t, e, n, i, r, a) {
|
|
|
19175
19175
|
isSVG: a
|
|
19176
19176
|
}), m.current && p.current && (p.current.manuallyAnimateOnMount = !0));
|
|
19177
19177
|
const h = p.current, f = Ce(fv);
|
|
19178
|
-
h && !h.projection && r && (h.type === "html" || h.type === "svg") &&
|
|
19178
|
+
h && !h.projection && r && (h.type === "html" || h.type === "svg") && R5(p.current, n, r, f);
|
|
19179
19179
|
const g = Z(!1);
|
|
19180
19180
|
Uw(() => {
|
|
19181
19181
|
h && g.current && h.update(n, l);
|
|
@@ -19190,7 +19190,7 @@ function jF(t, e, n, i, r, a) {
|
|
|
19190
19190
|
}), y.current = !1), h.enteringChildren = void 0);
|
|
19191
19191
|
}), h;
|
|
19192
19192
|
}
|
|
19193
|
-
function
|
|
19193
|
+
function R5(t, e, n, i) {
|
|
19194
19194
|
const { layoutId: r, layout: a, drag: s, dragConstraints: o, layoutScroll: l, layoutRoot: c, layoutAnchor: u, layoutCrossfade: d } = e;
|
|
19195
19195
|
t.projection = new n(t.latestValues, e["data-framer-portal-id"] ? void 0 : gv(t.parent)), t.projection.setOptions({
|
|
19196
19196
|
layoutId: r,
|
|
@@ -19217,34 +19217,34 @@ function gv(t) {
|
|
|
19217
19217
|
return t.options.allowProjection !== !1 ? t.projection : gv(t.parent);
|
|
19218
19218
|
}
|
|
19219
19219
|
function ud(t, { forwardMotionProps: e = !1, type: n } = {}, i, r) {
|
|
19220
|
-
i &&
|
|
19221
|
-
const a = n ? n === "svg" : uf(t), s = a ?
|
|
19220
|
+
i && h5(i);
|
|
19221
|
+
const a = n ? n === "svg" : uf(t), s = a ? E5 : T5;
|
|
19222
19222
|
function o(c, u) {
|
|
19223
19223
|
let d;
|
|
19224
19224
|
const p = {
|
|
19225
19225
|
...Ce(lv),
|
|
19226
19226
|
...c,
|
|
19227
|
-
layoutId:
|
|
19228
|
-
}, { isStatic: m } = p, h =
|
|
19227
|
+
layoutId: D5(c)
|
|
19228
|
+
}, { isStatic: m } = p, h = w5(c), f = s(c, m);
|
|
19229
19229
|
if (!m && typeof window < "u") {
|
|
19230
|
-
|
|
19231
|
-
const g =
|
|
19232
|
-
d = g.MeasureLayout, h.visualElement =
|
|
19230
|
+
B5();
|
|
19231
|
+
const g = O5(p);
|
|
19232
|
+
d = g.MeasureLayout, h.visualElement = j5(t, f, p, r, g.ProjectionNode, a);
|
|
19233
19233
|
}
|
|
19234
|
-
return O(ru.Provider, { value: h, children: [d && h.visualElement ? k(d, { visualElement: h.visualElement, ...p }) : null, $
|
|
19234
|
+
return O(ru.Provider, { value: h, children: [d && h.visualElement ? k(d, { visualElement: h.visualElement, ...p }) : null, $5(t, c, P5(f, h.visualElement, u), f, m, e, a)] });
|
|
19235
19235
|
}
|
|
19236
19236
|
o.displayName = `motion.${typeof t == "string" ? t : `create(${t.displayName ?? t.name ?? ""})`}`;
|
|
19237
19237
|
const l = qs(o);
|
|
19238
|
-
return l[
|
|
19238
|
+
return l[M5] = t, l;
|
|
19239
19239
|
}
|
|
19240
|
-
function
|
|
19240
|
+
function D5({ layoutId: t }) {
|
|
19241
19241
|
const e = Ce(Bx).id;
|
|
19242
19242
|
return e && t !== void 0 ? e + "-" + t : t;
|
|
19243
19243
|
}
|
|
19244
|
-
function
|
|
19244
|
+
function B5(t, e) {
|
|
19245
19245
|
Ce(cv).strict;
|
|
19246
19246
|
}
|
|
19247
|
-
function
|
|
19247
|
+
function O5(t) {
|
|
19248
19248
|
const e = uv(), { drag: n, layout: i } = e;
|
|
19249
19249
|
if (!n && !i)
|
|
19250
19250
|
return {};
|
|
@@ -19254,7 +19254,7 @@ function OF(t) {
|
|
|
19254
19254
|
ProjectionNode: r.ProjectionNode
|
|
19255
19255
|
};
|
|
19256
19256
|
}
|
|
19257
|
-
function
|
|
19257
|
+
function I5(t, e) {
|
|
19258
19258
|
if (typeof Proxy > "u")
|
|
19259
19259
|
return ud;
|
|
19260
19260
|
const n = /* @__PURE__ */ new Map(), i = (a, s) => ud(a, s, t, e), r = (a, s) => i(a, s);
|
|
@@ -19267,10 +19267,10 @@ function IF(t, e) {
|
|
|
19267
19267
|
get: (a, s) => s === "create" ? i : (n.has(s) || n.set(s, ud(s, void 0, t, e)), n.get(s))
|
|
19268
19268
|
});
|
|
19269
19269
|
}
|
|
19270
|
-
const
|
|
19270
|
+
const N5 = (t, e) => e.isSVG ?? uf(t) ? new w4(e) : new m4(e, {
|
|
19271
19271
|
allowProjection: t !== Hw
|
|
19272
19272
|
});
|
|
19273
|
-
class
|
|
19273
|
+
class L5 extends Ri {
|
|
19274
19274
|
/**
|
|
19275
19275
|
* We dynamically generate the AnimationState manager as it contains a reference
|
|
19276
19276
|
* to the underlying animation library. We only want to load that if we load this,
|
|
@@ -19298,10 +19298,10 @@ class LF extends Ri {
|
|
|
19298
19298
|
this.node.animationState.reset(), (e = this.unmountControls) == null || e.call(this);
|
|
19299
19299
|
}
|
|
19300
19300
|
}
|
|
19301
|
-
let
|
|
19302
|
-
class
|
|
19301
|
+
let F5 = 0;
|
|
19302
|
+
class q5 extends Ri {
|
|
19303
19303
|
constructor() {
|
|
19304
|
-
super(...arguments), this.id =
|
|
19304
|
+
super(...arguments), this.id = F5++, this.isExitComplete = !1;
|
|
19305
19305
|
}
|
|
19306
19306
|
update() {
|
|
19307
19307
|
var a;
|
|
@@ -19339,12 +19339,12 @@ class qF extends Ri {
|
|
|
19339
19339
|
unmount() {
|
|
19340
19340
|
}
|
|
19341
19341
|
}
|
|
19342
|
-
const
|
|
19342
|
+
const z5 = {
|
|
19343
19343
|
animation: {
|
|
19344
|
-
Feature:
|
|
19344
|
+
Feature: L5
|
|
19345
19345
|
},
|
|
19346
19346
|
exit: {
|
|
19347
|
-
Feature:
|
|
19347
|
+
Feature: q5
|
|
19348
19348
|
}
|
|
19349
19349
|
};
|
|
19350
19350
|
function Ys(t) {
|
|
@@ -19355,12 +19355,12 @@ function Ys(t) {
|
|
|
19355
19355
|
}
|
|
19356
19356
|
};
|
|
19357
19357
|
}
|
|
19358
|
-
const
|
|
19358
|
+
const G5 = (t) => (e) => nf(e) && t(e, Ys(e));
|
|
19359
19359
|
function ts(t, e, n, i) {
|
|
19360
|
-
return vs(t, e,
|
|
19360
|
+
return vs(t, e, G5(n), i);
|
|
19361
19361
|
}
|
|
19362
19362
|
const bv = ({ current: t }) => t ? t.ownerDocument.defaultView : null, Cy = (t, e) => Math.abs(t - e);
|
|
19363
|
-
function
|
|
19363
|
+
function V5(t, e) {
|
|
19364
19364
|
const n = Cy(t.x, e.x), i = Cy(t.y, e.y);
|
|
19365
19365
|
return Math.sqrt(n ** 2 + i ** 2);
|
|
19366
19366
|
}
|
|
@@ -19375,7 +19375,7 @@ class yv {
|
|
|
19375
19375
|
if (!(this.lastMoveEvent && this.lastMoveEventInfo))
|
|
19376
19376
|
return;
|
|
19377
19377
|
this.lastRawMoveEventInfo && (this.lastMoveEventInfo = vo(this.lastRawMoveEventInfo, this.transformPagePoint));
|
|
19378
|
-
const m = dd(this.lastMoveEventInfo, this.history), h = this.startEvent !== null, f =
|
|
19378
|
+
const m = dd(this.lastMoveEventInfo, this.history), h = this.startEvent !== null, f = V5(m.offset, { x: 0, y: 0 }) >= this.distanceThreshold;
|
|
19379
19379
|
if (!h && !f)
|
|
19380
19380
|
return;
|
|
19381
19381
|
const { point: g } = m, { timestamp: b } = Ge;
|
|
@@ -19455,17 +19455,17 @@ function dd({ point: t }, e) {
|
|
|
19455
19455
|
return {
|
|
19456
19456
|
point: t,
|
|
19457
19457
|
delta: Sy(t, wv(e)),
|
|
19458
|
-
offset: Sy(t,
|
|
19459
|
-
velocity:
|
|
19458
|
+
offset: Sy(t, W5(e)),
|
|
19459
|
+
velocity: H5(e, 0.1)
|
|
19460
19460
|
};
|
|
19461
19461
|
}
|
|
19462
|
-
function
|
|
19462
|
+
function W5(t) {
|
|
19463
19463
|
return t[0];
|
|
19464
19464
|
}
|
|
19465
19465
|
function wv(t) {
|
|
19466
19466
|
return t[t.length - 1];
|
|
19467
19467
|
}
|
|
19468
|
-
function
|
|
19468
|
+
function H5(t, e) {
|
|
19469
19469
|
if (t.length < 2)
|
|
19470
19470
|
return { x: 0, y: 0 };
|
|
19471
19471
|
let n = t.length - 1, i = null;
|
|
@@ -19484,7 +19484,7 @@ function HF(t, e) {
|
|
|
19484
19484
|
};
|
|
19485
19485
|
return s.x === 1 / 0 && (s.x = 0), s.y === 1 / 0 && (s.y = 0), s;
|
|
19486
19486
|
}
|
|
19487
|
-
function
|
|
19487
|
+
function U5(t, { min: e, max: n }, i) {
|
|
19488
19488
|
return e !== void 0 && t < e ? t = i ? be(e, t, i.min) : Math.max(t, e) : n !== void 0 && t > n && (t = i ? be(n, t, i.max) : Math.min(t, n)), t;
|
|
19489
19489
|
}
|
|
19490
19490
|
function Ay(t, e, n) {
|
|
@@ -19493,7 +19493,7 @@ function Ay(t, e, n) {
|
|
|
19493
19493
|
max: n !== void 0 ? t.max + n - (t.max - t.min) : void 0
|
|
19494
19494
|
};
|
|
19495
19495
|
}
|
|
19496
|
-
function
|
|
19496
|
+
function K5(t, { top: e, left: n, bottom: i, right: r }) {
|
|
19497
19497
|
return {
|
|
19498
19498
|
x: Ay(t.x, n, r),
|
|
19499
19499
|
y: Ay(t.y, e, i)
|
|
@@ -19503,23 +19503,23 @@ function Ty(t, e) {
|
|
|
19503
19503
|
let n = e.min - t.min, i = e.max - t.max;
|
|
19504
19504
|
return e.max - e.min < t.max - t.min && ([n, i] = [i, n]), { min: n, max: i };
|
|
19505
19505
|
}
|
|
19506
|
-
function
|
|
19506
|
+
function Z5(t, e) {
|
|
19507
19507
|
return {
|
|
19508
19508
|
x: Ty(t.x, e.x),
|
|
19509
19509
|
y: Ty(t.y, e.y)
|
|
19510
19510
|
};
|
|
19511
19511
|
}
|
|
19512
|
-
function
|
|
19512
|
+
function X5(t, e) {
|
|
19513
19513
|
let n = 0.5;
|
|
19514
19514
|
const i = lt(t), r = lt(e);
|
|
19515
19515
|
return r > i ? n = /* @__PURE__ */ ks(e.min, e.max - i, t.min) : i > r && (n = /* @__PURE__ */ ks(t.min, t.max - r, e.min)), Mn(0, 1, n);
|
|
19516
19516
|
}
|
|
19517
|
-
function
|
|
19517
|
+
function Y5(t, e) {
|
|
19518
19518
|
const n = {};
|
|
19519
19519
|
return e.min !== void 0 && (n.min = e.min - t.min), e.max !== void 0 && (n.max = e.max - t.min), n;
|
|
19520
19520
|
}
|
|
19521
19521
|
const Yp = 0.35;
|
|
19522
|
-
function
|
|
19522
|
+
function Q5(t = Yp) {
|
|
19523
19523
|
return t === !1 ? t = 0 : t === !0 && (t = Yp), {
|
|
19524
19524
|
x: Ey(t, "left", "right"),
|
|
19525
19525
|
y: Ey(t, "top", "bottom")
|
|
@@ -19534,8 +19534,8 @@ function Ey(t, e, n) {
|
|
|
19534
19534
|
function My(t, e) {
|
|
19535
19535
|
return typeof t == "number" ? t : t[e] || 0;
|
|
19536
19536
|
}
|
|
19537
|
-
const
|
|
19538
|
-
class
|
|
19537
|
+
const J5 = /* @__PURE__ */ new WeakMap();
|
|
19538
|
+
class eF {
|
|
19539
19539
|
constructor(e) {
|
|
19540
19540
|
this.openDragLock = null, this.isDragging = !1, this.currentDirection = null, this.originPoint = { x: 0, y: 0 }, this.constraints = !1, this.hasMutatedConstraints = !1, this.elastic = De(), this.latestPointerEvent = null, this.latestPanInfo = null, this.visualElement = e;
|
|
19541
19541
|
}
|
|
@@ -19569,7 +19569,7 @@ class e5 {
|
|
|
19569
19569
|
return;
|
|
19570
19570
|
const { offset: b } = p;
|
|
19571
19571
|
if (h && this.currentDirection === null) {
|
|
19572
|
-
this.currentDirection =
|
|
19572
|
+
this.currentDirection = nF(b), this.currentDirection !== null && f && f(this.currentDirection);
|
|
19573
19573
|
return;
|
|
19574
19574
|
}
|
|
19575
19575
|
this.updateAxis("x", p.point, b), this.updateAxis("y", p.point, b), this.visualElement.render(), g && pe.update(() => g(d, p), !1, !0);
|
|
@@ -19630,13 +19630,13 @@ class e5 {
|
|
|
19630
19630
|
return;
|
|
19631
19631
|
const a = this.getAxisMotionValue(e);
|
|
19632
19632
|
let s = this.originPoint[e] + i[e];
|
|
19633
|
-
this.constraints && this.constraints[e] && (s =
|
|
19633
|
+
this.constraints && this.constraints[e] && (s = U5(s, this.constraints[e], this.elastic[e])), a.set(s);
|
|
19634
19634
|
}
|
|
19635
19635
|
resolveConstraints() {
|
|
19636
19636
|
var a;
|
|
19637
19637
|
const { dragConstraints: e, dragElastic: n } = this.getProps(), i = this.visualElement.projection && !this.visualElement.projection.layout ? this.visualElement.projection.measure(!1) : (a = this.visualElement.projection) == null ? void 0 : a.layout, r = this.constraints;
|
|
19638
|
-
e && Dr(e) ? this.constraints || (this.constraints = this.resolveRefConstraints()) : e && i ? this.constraints =
|
|
19639
|
-
this.constraints !== !1 && this.getAxisMotionValue(s) && (this.constraints[s] =
|
|
19638
|
+
e && Dr(e) ? this.constraints || (this.constraints = this.resolveRefConstraints()) : e && i ? this.constraints = K5(i.layoutBox, e) : this.constraints = !1, this.elastic = Q5(n), r !== this.constraints && !Dr(e) && i && this.constraints && !this.hasMutatedConstraints && fn((s) => {
|
|
19639
|
+
this.constraints !== !1 && this.getAxisMotionValue(s) && (this.constraints[s] = Y5(i.layoutBox[s], this.constraints[s]));
|
|
19640
19640
|
});
|
|
19641
19641
|
}
|
|
19642
19642
|
resolveRefConstraints() {
|
|
@@ -19647,7 +19647,7 @@ class e5 {
|
|
|
19647
19647
|
if (!r || !r.layout)
|
|
19648
19648
|
return !1;
|
|
19649
19649
|
const a = o4(i, r.root, this.visualElement.getTransformPagePoint());
|
|
19650
|
-
let s =
|
|
19650
|
+
let s = Z5(r.layout.layoutBox, a);
|
|
19651
19651
|
if (n) {
|
|
19652
19652
|
const o = n(r4(s));
|
|
19653
19653
|
this.hasMutatedConstraints = !!o, o && (s = F1(o));
|
|
@@ -19721,7 +19721,7 @@ class e5 {
|
|
|
19721
19721
|
const o = this.getAxisMotionValue(s);
|
|
19722
19722
|
if (o && this.constraints !== !1) {
|
|
19723
19723
|
const l = o.get();
|
|
19724
|
-
r[s] =
|
|
19724
|
+
r[s] = X5({ min: l, max: l }, this.constraints[s]);
|
|
19725
19725
|
}
|
|
19726
19726
|
});
|
|
19727
19727
|
const { transformTemplate: a } = this.visualElement.getProps();
|
|
@@ -19735,7 +19735,7 @@ class e5 {
|
|
|
19735
19735
|
addListeners() {
|
|
19736
19736
|
if (!this.visualElement.current)
|
|
19737
19737
|
return;
|
|
19738
|
-
|
|
19738
|
+
J5.set(this.visualElement, this);
|
|
19739
19739
|
const e = this.visualElement.current, n = ts(e, "pointerdown", (c) => {
|
|
19740
19740
|
const { drag: u, dragListener: d = !0 } = this.getProps(), p = c.target, m = p !== e && NL(p);
|
|
19741
19741
|
u && d && !m && this.start(c);
|
|
@@ -19743,7 +19743,7 @@ class e5 {
|
|
|
19743
19743
|
let i;
|
|
19744
19744
|
const r = () => {
|
|
19745
19745
|
const { dragConstraints: c } = this.getProps();
|
|
19746
|
-
Dr(c) && c.current && (this.constraints = this.resolveRefConstraints(), i || (i =
|
|
19746
|
+
Dr(c) && c.current && (this.constraints = this.resolveRefConstraints(), i || (i = tF(e, c.current, () => this.scalePositionWithinConstraints())));
|
|
19747
19747
|
}, { projection: a } = this.visualElement, s = a.addEventListener("measure", r);
|
|
19748
19748
|
a && !a.layout && (a.root && a.root.updateScroll(), a.updateLayout()), pe.read(r);
|
|
19749
19749
|
const o = vs(window, "resize", () => this.scalePositionWithinConstraints()), l = a.addEventListener("didUpdate", (({ delta: c, hasLayoutChanged: u }) => {
|
|
@@ -19779,7 +19779,7 @@ function Py(t) {
|
|
|
19779
19779
|
t();
|
|
19780
19780
|
};
|
|
19781
19781
|
}
|
|
19782
|
-
function
|
|
19782
|
+
function tF(t, e, n) {
|
|
19783
19783
|
const i = Fb(t, Py(n)), r = Fb(e, Py(n));
|
|
19784
19784
|
return () => {
|
|
19785
19785
|
i(), r();
|
|
@@ -19788,13 +19788,13 @@ function t5(t, e, n) {
|
|
|
19788
19788
|
function Co(t, e, n) {
|
|
19789
19789
|
return (e === !0 || e === t) && (n === null || n === t);
|
|
19790
19790
|
}
|
|
19791
|
-
function
|
|
19791
|
+
function nF(t, e = 10) {
|
|
19792
19792
|
let n = null;
|
|
19793
19793
|
return Math.abs(t.y) > e ? n = "y" : Math.abs(t.x) > e && (n = "x"), n;
|
|
19794
19794
|
}
|
|
19795
|
-
class
|
|
19795
|
+
class iF extends Ri {
|
|
19796
19796
|
constructor(e) {
|
|
19797
|
-
super(e), this.removeGroupControls = Lt, this.removeListeners = Lt, this.controls = new
|
|
19797
|
+
super(e), this.removeGroupControls = Lt, this.removeListeners = Lt, this.controls = new eF(e);
|
|
19798
19798
|
}
|
|
19799
19799
|
mount() {
|
|
19800
19800
|
const { dragControls: e } = this.node.getProps();
|
|
@@ -19811,7 +19811,7 @@ class i5 extends Ri {
|
|
|
19811
19811
|
const pd = (t) => (e, n) => {
|
|
19812
19812
|
t && pe.update(() => t(e, n), !1, !0);
|
|
19813
19813
|
};
|
|
19814
|
-
class
|
|
19814
|
+
class rF extends Ri {
|
|
19815
19815
|
constructor() {
|
|
19816
19816
|
super(...arguments), this.removePointerDownListener = Lt;
|
|
19817
19817
|
}
|
|
@@ -19843,7 +19843,7 @@ class r5 extends Ri {
|
|
|
19843
19843
|
}
|
|
19844
19844
|
}
|
|
19845
19845
|
let md = !1;
|
|
19846
|
-
class
|
|
19846
|
+
class aF extends Kw {
|
|
19847
19847
|
/**
|
|
19848
19848
|
* This only mounts projection nodes for components that
|
|
19849
19849
|
* need measuring, we might want to do it for all components
|
|
@@ -19888,15 +19888,15 @@ class a5 extends Kw {
|
|
|
19888
19888
|
}
|
|
19889
19889
|
}
|
|
19890
19890
|
function kv(t) {
|
|
19891
|
-
const [e, n] =
|
|
19892
|
-
return k(
|
|
19891
|
+
const [e, n] = p5(), i = Ce(Bx);
|
|
19892
|
+
return k(aF, { ...t, layoutGroup: i, switchLayoutGroup: Ce(fv), isPresent: e, safeToRemove: n });
|
|
19893
19893
|
}
|
|
19894
|
-
const
|
|
19894
|
+
const sF = {
|
|
19895
19895
|
pan: {
|
|
19896
|
-
Feature:
|
|
19896
|
+
Feature: rF
|
|
19897
19897
|
},
|
|
19898
19898
|
drag: {
|
|
19899
|
-
Feature:
|
|
19899
|
+
Feature: iF,
|
|
19900
19900
|
ProjectionNode: ov,
|
|
19901
19901
|
MeasureLayout: kv
|
|
19902
19902
|
}
|
|
@@ -19907,7 +19907,7 @@ function jy(t, e, n) {
|
|
|
19907
19907
|
const r = "onHover" + n, a = i[r];
|
|
19908
19908
|
a && pe.postRender(() => a(e, Ys(e)));
|
|
19909
19909
|
}
|
|
19910
|
-
class
|
|
19910
|
+
class oF extends Ri {
|
|
19911
19911
|
mount() {
|
|
19912
19912
|
const { current: e } = this.node;
|
|
19913
19913
|
e && (this.unmount = DL(e, (n, i) => (jy(this.node, i, "Start"), (r) => jy(this.node, r, "End"))));
|
|
@@ -19915,7 +19915,7 @@ class o5 extends Ri {
|
|
|
19915
19915
|
unmount() {
|
|
19916
19916
|
}
|
|
19917
19917
|
}
|
|
19918
|
-
class
|
|
19918
|
+
class lF extends Ri {
|
|
19919
19919
|
constructor() {
|
|
19920
19920
|
super(...arguments), this.isActive = !1;
|
|
19921
19921
|
}
|
|
@@ -19945,7 +19945,7 @@ function Ry(t, e, n) {
|
|
|
19945
19945
|
const r = "onTap" + (n === "End" ? "" : n), a = i[r];
|
|
19946
19946
|
a && pe.postRender(() => a(e, Ys(e)));
|
|
19947
19947
|
}
|
|
19948
|
-
class
|
|
19948
|
+
class cF extends Ri {
|
|
19949
19949
|
mount() {
|
|
19950
19950
|
const { current: e } = this.node;
|
|
19951
19951
|
if (!e)
|
|
@@ -19959,29 +19959,29 @@ class c5 extends Ri {
|
|
|
19959
19959
|
unmount() {
|
|
19960
19960
|
}
|
|
19961
19961
|
}
|
|
19962
|
-
const Qp = /* @__PURE__ */ new WeakMap(), hd = /* @__PURE__ */ new WeakMap(),
|
|
19962
|
+
const Qp = /* @__PURE__ */ new WeakMap(), hd = /* @__PURE__ */ new WeakMap(), uF = (t) => {
|
|
19963
19963
|
const e = Qp.get(t.target);
|
|
19964
19964
|
e && e(t);
|
|
19965
|
-
},
|
|
19966
|
-
t.forEach(
|
|
19965
|
+
}, dF = (t) => {
|
|
19966
|
+
t.forEach(uF);
|
|
19967
19967
|
};
|
|
19968
|
-
function
|
|
19968
|
+
function pF({ root: t, ...e }) {
|
|
19969
19969
|
const n = t || document;
|
|
19970
19970
|
hd.has(n) || hd.set(n, {});
|
|
19971
19971
|
const i = hd.get(n), r = JSON.stringify(e);
|
|
19972
|
-
return i[r] || (i[r] = new IntersectionObserver(
|
|
19972
|
+
return i[r] || (i[r] = new IntersectionObserver(dF, { root: t, ...e })), i[r];
|
|
19973
19973
|
}
|
|
19974
|
-
function
|
|
19975
|
-
const i =
|
|
19974
|
+
function mF(t, e, n) {
|
|
19975
|
+
const i = pF(e);
|
|
19976
19976
|
return Qp.set(t, n), i.observe(t), () => {
|
|
19977
19977
|
Qp.delete(t), i.unobserve(t);
|
|
19978
19978
|
};
|
|
19979
19979
|
}
|
|
19980
|
-
const
|
|
19980
|
+
const hF = {
|
|
19981
19981
|
some: 0,
|
|
19982
19982
|
all: 1
|
|
19983
19983
|
};
|
|
19984
|
-
class
|
|
19984
|
+
class fF extends Ri {
|
|
19985
19985
|
constructor() {
|
|
19986
19986
|
super(...arguments), this.hasEnteredView = !1, this.isInView = !1;
|
|
19987
19987
|
}
|
|
@@ -19991,7 +19991,7 @@ class f5 extends Ri {
|
|
|
19991
19991
|
const { viewport: e = {} } = this.node.getProps(), { root: n, margin: i, amount: r = "some", once: a } = e, s = {
|
|
19992
19992
|
root: n ? n.current : void 0,
|
|
19993
19993
|
rootMargin: i,
|
|
19994
|
-
threshold: typeof r == "number" ? r :
|
|
19994
|
+
threshold: typeof r == "number" ? r : hF[r]
|
|
19995
19995
|
}, o = (c) => {
|
|
19996
19996
|
const { isIntersecting: u } = c;
|
|
19997
19997
|
if (this.isInView === u || (this.isInView = u, a && !u && this.hasEnteredView))
|
|
@@ -20000,7 +20000,7 @@ class f5 extends Ri {
|
|
|
20000
20000
|
const { onViewportEnter: d, onViewportLeave: p } = this.node.getProps(), m = u ? d : p;
|
|
20001
20001
|
m && m(c);
|
|
20002
20002
|
};
|
|
20003
|
-
this.stopObserver =
|
|
20003
|
+
this.stopObserver = mF(this.node.current, s, o);
|
|
20004
20004
|
}
|
|
20005
20005
|
mount() {
|
|
20006
20006
|
this.startObserver();
|
|
@@ -20009,47 +20009,47 @@ class f5 extends Ri {
|
|
|
20009
20009
|
if (typeof IntersectionObserver > "u")
|
|
20010
20010
|
return;
|
|
20011
20011
|
const { props: e, prevProps: n } = this.node;
|
|
20012
|
-
["amount", "margin", "root"].some(
|
|
20012
|
+
["amount", "margin", "root"].some(gF(e, n)) && this.startObserver();
|
|
20013
20013
|
}
|
|
20014
20014
|
unmount() {
|
|
20015
20015
|
var e;
|
|
20016
20016
|
(e = this.stopObserver) == null || e.call(this), this.hasEnteredView = !1, this.isInView = !1;
|
|
20017
20017
|
}
|
|
20018
20018
|
}
|
|
20019
|
-
function
|
|
20019
|
+
function gF({ viewport: t = {} }, { viewport: e = {} } = {}) {
|
|
20020
20020
|
return (n) => t[n] !== e[n];
|
|
20021
20021
|
}
|
|
20022
|
-
const
|
|
20022
|
+
const bF = {
|
|
20023
20023
|
inView: {
|
|
20024
|
-
Feature:
|
|
20024
|
+
Feature: fF
|
|
20025
20025
|
},
|
|
20026
20026
|
tap: {
|
|
20027
|
-
Feature:
|
|
20027
|
+
Feature: cF
|
|
20028
20028
|
},
|
|
20029
20029
|
focus: {
|
|
20030
|
-
Feature:
|
|
20030
|
+
Feature: lF
|
|
20031
20031
|
},
|
|
20032
20032
|
hover: {
|
|
20033
|
-
Feature:
|
|
20033
|
+
Feature: oF
|
|
20034
20034
|
}
|
|
20035
|
-
},
|
|
20035
|
+
}, yF = {
|
|
20036
20036
|
layout: {
|
|
20037
20037
|
ProjectionNode: ov,
|
|
20038
20038
|
MeasureLayout: kv
|
|
20039
20039
|
}
|
|
20040
|
-
},
|
|
20041
|
-
...
|
|
20042
|
-
...
|
|
20043
|
-
...
|
|
20044
|
-
...
|
|
20045
|
-
},
|
|
20040
|
+
}, wF = {
|
|
20041
|
+
...z5,
|
|
20042
|
+
...bF,
|
|
20043
|
+
...sF,
|
|
20044
|
+
...yF
|
|
20045
|
+
}, kF = /* @__PURE__ */ I5(wF, N5), _F = ({
|
|
20046
20046
|
children: t,
|
|
20047
20047
|
as: e = "p",
|
|
20048
20048
|
className: n,
|
|
20049
20049
|
duration: i = 2,
|
|
20050
20050
|
spread: r = 2
|
|
20051
20051
|
}) => {
|
|
20052
|
-
const a =
|
|
20052
|
+
const a = kF.create(
|
|
20053
20053
|
e
|
|
20054
20054
|
), s = br(
|
|
20055
20055
|
() => ((t == null ? void 0 : t.length) ?? 0) * r,
|
|
@@ -20077,12 +20077,12 @@ const b5 = {
|
|
|
20077
20077
|
children: t
|
|
20078
20078
|
}
|
|
20079
20079
|
);
|
|
20080
|
-
},
|
|
20080
|
+
}, xF = ji(_F), _v = Tt(null), vF = () => {
|
|
20081
20081
|
const t = Ce(_v);
|
|
20082
20082
|
if (!t)
|
|
20083
20083
|
throw new Error("Reasoning components must be used within Reasoning");
|
|
20084
20084
|
return t;
|
|
20085
|
-
},
|
|
20085
|
+
}, CF = 1e3, $F = 1e3, xv = ji(
|
|
20086
20086
|
({
|
|
20087
20087
|
className: t,
|
|
20088
20088
|
isStreaming: e = !1,
|
|
@@ -20102,12 +20102,12 @@ const b5 = {
|
|
|
20102
20102
|
defaultProp: void 0
|
|
20103
20103
|
}), [p, m] = Y(!1), [h, f] = Y(null);
|
|
20104
20104
|
le(() => {
|
|
20105
|
-
e ? h === null && f(Date.now()) : h !== null && (d(Math.ceil((Date.now() - h) / $
|
|
20105
|
+
e ? h === null && f(Date.now()) : h !== null && (d(Math.ceil((Date.now() - h) / $F)), f(null));
|
|
20106
20106
|
}, [e, h, d]), le(() => {
|
|
20107
20107
|
if (i && !e && l && !p) {
|
|
20108
20108
|
const b = setTimeout(() => {
|
|
20109
20109
|
c(!1), m(!0);
|
|
20110
|
-
},
|
|
20110
|
+
}, CF);
|
|
20111
20111
|
return () => clearTimeout(b);
|
|
20112
20112
|
}
|
|
20113
20113
|
}, [e, l, i, c, p]);
|
|
@@ -20131,13 +20131,13 @@ const b5 = {
|
|
|
20131
20131
|
}
|
|
20132
20132
|
);
|
|
20133
20133
|
}
|
|
20134
|
-
),
|
|
20134
|
+
), SF = (t, e) => t || e === 0 ? /* @__PURE__ */ k(xF, { duration: 1, children: "Thinking..." }) : e === void 0 ? /* @__PURE__ */ k("p", { children: "Thought for a few seconds" }) : /* @__PURE__ */ O("p", { children: [
|
|
20135
20135
|
"Thought for ",
|
|
20136
20136
|
e,
|
|
20137
20137
|
" seconds"
|
|
20138
20138
|
] }), vv = ji(
|
|
20139
|
-
({ className: t, children: e, getThinkingMessage: n =
|
|
20140
|
-
const { isStreaming: r, isOpen: a, duration: s } =
|
|
20139
|
+
({ className: t, children: e, getThinkingMessage: n = SF, ...i }) => {
|
|
20140
|
+
const { isStreaming: r, isOpen: a, duration: s } = vF();
|
|
20141
20141
|
return /* @__PURE__ */ k(
|
|
20142
20142
|
Wl,
|
|
20143
20143
|
{
|
|
@@ -20179,13 +20179,13 @@ const b5 = {
|
|
|
20179
20179
|
xv.displayName = "Reasoning";
|
|
20180
20180
|
vv.displayName = "ReasoningTrigger";
|
|
20181
20181
|
Cv.displayName = "ReasoningContent";
|
|
20182
|
-
const
|
|
20182
|
+
const AF = ({ className: t, ...e }) => /* @__PURE__ */ k(
|
|
20183
20183
|
Vl,
|
|
20184
20184
|
{
|
|
20185
20185
|
className: ge("not-prose mb-4 text-primary text-xs", t),
|
|
20186
20186
|
...e
|
|
20187
20187
|
}
|
|
20188
|
-
),
|
|
20188
|
+
), TF = ({
|
|
20189
20189
|
className: t,
|
|
20190
20190
|
count: e,
|
|
20191
20191
|
children: n,
|
|
@@ -20204,7 +20204,7 @@ const A5 = ({ className: t, ...e }) => /* @__PURE__ */ k(
|
|
|
20204
20204
|
/* @__PURE__ */ k(rk, { className: "h-4 w-4" })
|
|
20205
20205
|
] })
|
|
20206
20206
|
}
|
|
20207
|
-
),
|
|
20207
|
+
), EF = ({
|
|
20208
20208
|
className: t,
|
|
20209
20209
|
...e
|
|
20210
20210
|
}) => /* @__PURE__ */ k(
|
|
@@ -20217,7 +20217,7 @@ const A5 = ({ className: t, ...e }) => /* @__PURE__ */ k(
|
|
|
20217
20217
|
),
|
|
20218
20218
|
...e
|
|
20219
20219
|
}
|
|
20220
|
-
),
|
|
20220
|
+
), MF = ({ href: t, title: e, children: n, ...i }) => /* @__PURE__ */ k(
|
|
20221
20221
|
"a",
|
|
20222
20222
|
{
|
|
20223
20223
|
className: "flex items-center gap-2",
|
|
@@ -20230,30 +20230,30 @@ const A5 = ({ className: t, ...e }) => /* @__PURE__ */ k(
|
|
|
20230
20230
|
/* @__PURE__ */ k("span", { className: "block font-medium", children: e })
|
|
20231
20231
|
] })
|
|
20232
20232
|
}
|
|
20233
|
-
),
|
|
20234
|
-
reasoningTrace:
|
|
20235
|
-
reasoningTrace_outerTrigger:
|
|
20236
|
-
reasoningTrace_outerChevron:
|
|
20237
|
-
reasoningTrace_outerHeader:
|
|
20238
|
-
reasoningTrace_animatedContent:
|
|
20239
|
-
reasoningTrace_toolList:
|
|
20240
|
-
reasoningTrace_toolRow:
|
|
20241
|
-
reasoningTrace_toolTrigger:
|
|
20242
|
-
reasoningTrace_toolIcon:
|
|
20243
|
-
reasoningTrace_toolChevron:
|
|
20244
|
-
reasoningTrace_toolName:
|
|
20245
|
-
reasoningTrace_toolCollapsible:
|
|
20246
|
-
reasoningTrace_toolBody:
|
|
20247
|
-
reasoningTrace_toolDescription:
|
|
20248
|
-
reasoningTrace_toolCodeBlock:
|
|
20249
|
-
reasoningTrace_toolCodeBlockBody:
|
|
20250
|
-
},
|
|
20233
|
+
), PF = "_reasoningTrace_og0e4_1", jF = "_reasoningTrace_outerTrigger_og0e4_8", RF = "_reasoningTrace_outerChevron_og0e4_26", DF = "_reasoningTrace_outerHeader_og0e4_34", BF = "_reasoningTrace_animatedContent_og0e4_41", OF = "_reasoningTrace_toolList_og0e4_50", IF = "_reasoningTrace_toolRow_og0e4_56", NF = "_reasoningTrace_toolTrigger_og0e4_71", LF = "_reasoningTrace_toolIcon_og0e4_93", FF = "_reasoningTrace_toolChevron_og0e4_102", qF = "_reasoningTrace_toolName_og0e4_110", zF = "_reasoningTrace_toolCollapsible_og0e4_117", GF = "_reasoningTrace_toolBody_og0e4_121", VF = "_reasoningTrace_toolDescription_og0e4_132", WF = "_reasoningTrace_toolCodeBlock_og0e4_140", HF = "_reasoningTrace_toolCodeBlockBody_og0e4_144", _e = {
|
|
20234
|
+
reasoningTrace: PF,
|
|
20235
|
+
reasoningTrace_outerTrigger: jF,
|
|
20236
|
+
reasoningTrace_outerChevron: RF,
|
|
20237
|
+
reasoningTrace_outerHeader: DF,
|
|
20238
|
+
reasoningTrace_animatedContent: BF,
|
|
20239
|
+
reasoningTrace_toolList: OF,
|
|
20240
|
+
reasoningTrace_toolRow: IF,
|
|
20241
|
+
reasoningTrace_toolTrigger: NF,
|
|
20242
|
+
reasoningTrace_toolIcon: LF,
|
|
20243
|
+
reasoningTrace_toolChevron: FF,
|
|
20244
|
+
reasoningTrace_toolName: qF,
|
|
20245
|
+
reasoningTrace_toolCollapsible: zF,
|
|
20246
|
+
reasoningTrace_toolBody: GF,
|
|
20247
|
+
reasoningTrace_toolDescription: VF,
|
|
20248
|
+
reasoningTrace_toolCodeBlock: WF,
|
|
20249
|
+
reasoningTrace_toolCodeBlockBody: HF
|
|
20250
|
+
}, UF = (t) => typeof t == "string" ? t : JSON.stringify(t, null, 2), KF = (t) => {
|
|
20251
20251
|
if (typeof t == "string") {
|
|
20252
20252
|
const e = t.trim();
|
|
20253
20253
|
return e.startsWith("{") && e.endsWith("}") || e.startsWith("[") && e.endsWith("]") ? "json" : "markdown";
|
|
20254
20254
|
}
|
|
20255
20255
|
return "json";
|
|
20256
|
-
},
|
|
20256
|
+
}, ZF = ({ tools: t, translations: e, className: n }) => {
|
|
20257
20257
|
const i = Ww(), [r, a] = Y(!1), [s, o] = Y(/* @__PURE__ */ new Set());
|
|
20258
20258
|
if (!t || t.length === 0) return null;
|
|
20259
20259
|
const l = t.length === 1 ? (e == null ? void 0 : e.headerSingular) ?? "" : ((e == null ? void 0 : e.headerPlural) ?? "").replace("{count}", String(t.length)), c = (p, m) => {
|
|
@@ -20297,7 +20297,7 @@ const A5 = ({ className: t, ...e }) => /* @__PURE__ */ k(
|
|
|
20297
20297
|
"aria-labelledby": u,
|
|
20298
20298
|
className: _e.reasoningTrace_animatedContent,
|
|
20299
20299
|
children: /* @__PURE__ */ k("div", { className: _e.reasoningTrace_toolList, children: t.map((p, m) => {
|
|
20300
|
-
const h = s.has(m), f = `${i}-tool-${m}`, g = `${i}-tool-panel-${m}`, b = typeof p.message == "string" && p.message.length > 0, y = p.result !== void 0 ? p.result : p.input, w = y !== void 0, _ = w ?
|
|
20300
|
+
const h = s.has(m), f = `${i}-tool-${m}`, g = `${i}-tool-panel-${m}`, b = typeof p.message == "string" && p.message.length > 0, y = p.result !== void 0 ? p.result : p.input, w = y !== void 0, _ = w ? UF(y) : "", x = w ? KF(y) : "json", C = /* @__PURE__ */ O(En, { children: [
|
|
20301
20301
|
/* @__PURE__ */ k(Qe, { name: "wrench", className: _e.reasoningTrace_toolIcon }),
|
|
20302
20302
|
/* @__PURE__ */ k("span", { className: _e.reasoningTrace_toolName, children: p.displayName ?? p.tool }),
|
|
20303
20303
|
w && /* @__PURE__ */ k(
|
|
@@ -20365,10 +20365,10 @@ const A5 = ({ className: t, ...e }) => /* @__PURE__ */ k(
|
|
|
20365
20365
|
]
|
|
20366
20366
|
}
|
|
20367
20367
|
) });
|
|
20368
|
-
},
|
|
20369
|
-
card:
|
|
20370
|
-
card__warning:
|
|
20371
|
-
card__opacity:
|
|
20368
|
+
}, XF = (t) => t.from === "error", YF = "_card_11wy3_1", QF = "_card__warning_11wy3_9", JF = "_card__opacity_11wy3_12", e6 = "_card__border_11wy3_15", fd = {
|
|
20369
|
+
card: YF,
|
|
20370
|
+
card__warning: QF,
|
|
20371
|
+
card__opacity: JF,
|
|
20372
20372
|
card__border: e6
|
|
20373
20373
|
}, t6 = ({
|
|
20374
20374
|
variant: t = "warning",
|
|
@@ -20606,7 +20606,7 @@ const $6 = "_messageGroup_reasoning_7tok5_116", S6 = "_messageGroup_notFront_7to
|
|
|
20606
20606
|
notFrontErrorLabel: f
|
|
20607
20607
|
}) => {
|
|
20608
20608
|
var x, C, $, T, P, v;
|
|
20609
|
-
if (
|
|
20609
|
+
if (XF(t)) {
|
|
20610
20610
|
const E = t.kind === "expired", A = E ? { title: m } : t.kind === "connection" ? { title: a, retryLabel: s } : { title: d, retryLabel: p };
|
|
20611
20611
|
return /* @__PURE__ */ k(
|
|
20612
20612
|
"div",
|
|
@@ -20632,16 +20632,16 @@ const $6 = "_messageGroup_reasoning_7tok5_116", S6 = "_messageGroup_notFront_7to
|
|
|
20632
20632
|
"data-message-role": t.from,
|
|
20633
20633
|
className: ge(`from-${t.from}`, Ia.messageGroup),
|
|
20634
20634
|
children: [
|
|
20635
|
-
t.from === "assistant" && !!((T = t.sources) != null && T.length) && /* @__PURE__ */ O(
|
|
20636
|
-
/* @__PURE__ */ k(
|
|
20637
|
-
t.sources.map((E, A) => /* @__PURE__ */ k(
|
|
20635
|
+
t.from === "assistant" && !!((T = t.sources) != null && T.length) && /* @__PURE__ */ O(AF, { className: Ia.messageGroup_sources, children: [
|
|
20636
|
+
/* @__PURE__ */ k(TF, { count: t.sources.length }),
|
|
20637
|
+
t.sources.map((E, A) => /* @__PURE__ */ k(EF, { children: /* @__PURE__ */ k(MF, { href: E.href, title: E.title }) }, `${t.key}-source-${A}`))
|
|
20638
20638
|
] }),
|
|
20639
20639
|
t.from === "assistant" && t.reasoning && /* @__PURE__ */ O(xv, { className: Ia.messageGroup_reasoning, children: [
|
|
20640
20640
|
/* @__PURE__ */ k(vv, {}),
|
|
20641
20641
|
/* @__PURE__ */ k(Cv, { children: t.reasoning.content })
|
|
20642
20642
|
] }),
|
|
20643
20643
|
t.from === "assistant" && !!((P = t.tools) != null && P.length) && /* @__PURE__ */ k(
|
|
20644
|
-
|
|
20644
|
+
ZF,
|
|
20645
20645
|
{
|
|
20646
20646
|
tools: t.tools,
|
|
20647
20647
|
translations: {
|
|
@@ -20704,7 +20704,7 @@ const $6 = "_messageGroup_reasoning_7tok5_116", S6 = "_messageGroup_notFront_7to
|
|
|
20704
20704
|
},
|
|
20705
20705
|
e
|
|
20706
20706
|
) });
|
|
20707
|
-
}, D6 = "
|
|
20707
|
+
}, D6 = "_footer_1gq25_1", B6 = "_footer_form_1gq25_15", O6 = "_footer_inputWrapper_1gq25_20", I6 = "_footer_inputWrapper__processing_1gq25_31", N6 = "_footer_inputWrapper__disconnected_1gq25_31", L6 = "_footer_textarea_1gq25_38", F6 = "_footer_processingOverlay_1gq25_58", q6 = "_footer_actions_1gq25_64", z6 = "_footer_sendBtn_1gq25_71", G6 = "_footer_disclaimer_1gq25_95", Wt = {
|
|
20708
20708
|
footer: D6,
|
|
20709
20709
|
footer_form: B6,
|
|
20710
20710
|
footer_inputWrapper: O6,
|