@blueking/ai-blueking 2.2.2-beta.4 → 2.2.2-beta.5
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/components/chat-bot.vue.d.ts.map +1 -1
- package/dist/components/composables/use-chatbot-init.d.ts +0 -1
- package/dist/components/composables/use-chatbot-init.d.ts.map +1 -1
- package/dist/components/composables/use-interrupt-resume.d.ts.map +1 -1
- package/dist/components/composables/use-tool-actions.d.ts +0 -1
- package/dist/components/composables/use-tool-actions.d.ts.map +1 -1
- package/dist/composables/use-ai-blueking-init.d.ts.map +1 -1
- package/dist/standalone/index.es.min.js +245 -231
- package/dist/standalone/index.iife.min.js +5 -5
- package/dist/standalone/index.umd.min.js +5 -5
- package/dist/vue2/index.es.min.js +245 -231
- package/dist/vue2/index.iife.min.js +4 -4
- package/dist/vue2/index.umd.min.js +4 -4
- package/dist/vue3/index.es.min.js +304 -308
- package/dist/vue3/index.iife.min.js +5 -5
- package/dist/vue3/index.umd.min.js +3 -3
- package/package.json +2 -2
|
@@ -26738,46 +26738,60 @@ var bM = T("svg", {
|
|
|
26738
26738
|
isScrollBottom: n,
|
|
26739
26739
|
scrollBottomHeight: i,
|
|
26740
26740
|
debouncedShowScrollBottomBtn: o,
|
|
26741
|
-
|
|
26742
|
-
|
|
26741
|
+
jumpToBottom: c,
|
|
26742
|
+
toScrollBottom: l,
|
|
26743
|
+
toScrollTop: u
|
|
26743
26744
|
})));
|
|
26744
26745
|
let s = () => {
|
|
26745
|
-
|
|
26746
|
-
|
|
26746
|
+
let t = q(e);
|
|
26747
|
+
return t ? Math.max(0, t.scrollHeight - t.scrollTop - t.clientHeight) : 0;
|
|
26748
|
+
}, c = () => {
|
|
26749
|
+
let t = q(e);
|
|
26750
|
+
t && (a.value = !0, t.scrollTop = t.scrollHeight);
|
|
26751
|
+
}, l = (e) => {
|
|
26752
|
+
a.value = !0;
|
|
26753
|
+
let n = e ?? (s() > 600 ? "auto" : "smooth");
|
|
26754
|
+
if (n === "auto") {
|
|
26755
|
+
c();
|
|
26756
|
+
return;
|
|
26757
|
+
}
|
|
26758
|
+
q(t)?.scrollIntoView({
|
|
26759
|
+
behavior: n,
|
|
26747
26760
|
block: "end"
|
|
26748
26761
|
});
|
|
26749
|
-
},
|
|
26762
|
+
}, u = () => {
|
|
26750
26763
|
q(e)?.scrollTo({
|
|
26751
26764
|
top: 0,
|
|
26752
26765
|
behavior: "smooth"
|
|
26753
26766
|
});
|
|
26754
|
-
},
|
|
26767
|
+
}, f = () => {
|
|
26755
26768
|
let t = q(e);
|
|
26756
26769
|
if (!t) return;
|
|
26757
26770
|
let { scrollHeight: r, scrollTop: a, clientHeight: s } = t, c = r - a - s;
|
|
26758
26771
|
i.value = Math.max(0, c), o.value = !n.value && i.value > 100;
|
|
26759
|
-
},
|
|
26772
|
+
}, p = (e) => {
|
|
26760
26773
|
e.deltaY < 0 && (a.value = !1);
|
|
26761
26774
|
};
|
|
26762
26775
|
return R(() => {
|
|
26763
26776
|
pe(() => {
|
|
26764
26777
|
let s = q(e), c = q(t);
|
|
26765
|
-
!s || !c || (r?.disconnect(), s.removeEventListener("scroll",
|
|
26778
|
+
!s || !c || (r?.disconnect(), s.removeEventListener("scroll", f), s.removeEventListener("wheel", p), f(), r = new IntersectionObserver((e) => {
|
|
26766
26779
|
e.forEach((e) => {
|
|
26767
|
-
e.isIntersecting ? (n.value = !0, i.value = 0, a.value = !0, o.value = !1) : (n.value = !1,
|
|
26780
|
+
e.isIntersecting ? (n.value = !0, i.value = 0, a.value = !0, o.value = !1) : (n.value = !1, f());
|
|
26768
26781
|
});
|
|
26769
|
-
}), r.observe(c), s.addEventListener("scroll",
|
|
26782
|
+
}), r.observe(c), s.addEventListener("scroll", f, { passive: !0 }), s.addEventListener("wheel", p, { passive: !0 }));
|
|
26770
26783
|
});
|
|
26771
26784
|
}), z(() => {
|
|
26772
26785
|
r?.disconnect();
|
|
26773
26786
|
let t = q(e);
|
|
26774
|
-
t && (t.removeEventListener("scroll",
|
|
26787
|
+
t && (t.removeEventListener("scroll", f), t.removeEventListener("wheel", p));
|
|
26775
26788
|
}), {
|
|
26776
26789
|
autoScrollEnabled: a,
|
|
26777
26790
|
isScrollBottom: n,
|
|
26778
26791
|
scrollBottomHeight: i,
|
|
26779
|
-
|
|
26780
|
-
|
|
26792
|
+
jumpToBottom: c,
|
|
26793
|
+
toScrollBottom: l,
|
|
26794
|
+
toScrollTop: u,
|
|
26781
26795
|
debouncedShowScrollBottomBtn: o
|
|
26782
26796
|
};
|
|
26783
26797
|
}, lN = () => E(sN, void 0), uN = Symbol("CUSTOM_TAB_TOKEN"), dN = "execution";
|
|
@@ -53888,7 +53902,11 @@ var uG = ["src"], dG = {
|
|
|
53888
53902
|
}),
|
|
53889
53903
|
emits: /* @__PURE__ */ j(["stopStreaming"], ["update:selectedUserMessages"]),
|
|
53890
53904
|
setup(e) {
|
|
53891
|
-
let t = e, n = ce(e, "selectedUserMessages"), r = ue("messageContainerRef"), i = ue("messageContainerBottomRef"), {
|
|
53905
|
+
let t = e, n = ce(e, "selectedUserMessages"), r = ue("messageContainerRef"), i = ue("messageContainerBottomRef"), { jumpToBottom: a, toScrollBottom: s, debouncedShowScrollBottomBtn: c } = cN(r, i);
|
|
53906
|
+
R(() => {
|
|
53907
|
+
t.messageGroups?.length && (a(), requestAnimationFrame(() => a()));
|
|
53908
|
+
});
|
|
53909
|
+
let { copy: l } = aN(), u = (e, t) => {
|
|
53892
53910
|
if (!t?.length) return e;
|
|
53893
53911
|
let n = e.map((e) => {
|
|
53894
53912
|
let n = t.find((t) => t.id === e.id);
|
|
@@ -53898,12 +53916,12 @@ var uG = ["src"], dG = {
|
|
|
53898
53916
|
} : e;
|
|
53899
53917
|
}), r = t.filter((t) => !e.some((e) => e.id === t.id));
|
|
53900
53918
|
return [...n, ...r].filter((e) => !e.hidden);
|
|
53901
|
-
},
|
|
53919
|
+
}, f = d(() => u(cj, t.messageTools).filter((e) => t.renderMode !== pj.Test || e.id !== "share")), v = d(() => u(uj, t.updateTools)), b = d(() => t.renderMode === pj.Share ? t.messageGroups.filter((e) => e.type !== $A.Loading) : t.messageGroups), x = (e) => {
|
|
53902
53920
|
e.messages?.at(-1)?.role !== $A.Interrupt && (e.isHover = !0);
|
|
53903
|
-
},
|
|
53921
|
+
}, S = (e, t) => {
|
|
53904
53922
|
let n = t.toElement ?? t.relatedTarget;
|
|
53905
53923
|
n instanceof Element && n.classList.contains("ai-user-feedback") || (e.isHover = !1);
|
|
53906
|
-
},
|
|
53924
|
+
}, C = (e, r) => {
|
|
53907
53925
|
let i = e.type === $A.User;
|
|
53908
53926
|
t.messageGroups?.forEach((n, a) => {
|
|
53909
53927
|
if (n === e) {
|
|
@@ -53912,30 +53930,30 @@ var uG = ["src"], dG = {
|
|
|
53912
53930
|
e && (e.checked = r);
|
|
53913
53931
|
}
|
|
53914
53932
|
}), n.value = t.messageGroups?.filter((e) => e.checked).map((e) => e.messages).flat();
|
|
53915
|
-
},
|
|
53933
|
+
}, w = async (e, n) => (e.id === "copy" && l(n.filter((e) => e.role !== $A.Reasoning).map((e) => typeof e.content == "string" ? e.content : JSON.stringify(e.content || "")).join("\n")), t.onAgentAction?.(e, n)), T = async (e, n) => {
|
|
53916
53934
|
t.onUserAction?.(e, n);
|
|
53917
|
-
},
|
|
53935
|
+
}, E = async (e, n, r) => {
|
|
53918
53936
|
t.onUserInputConfirm?.(e, n, r);
|
|
53919
|
-
},
|
|
53937
|
+
}, D = async (e, n) => {
|
|
53920
53938
|
t.onUserShortcutConfirm?.(e, n);
|
|
53921
53939
|
};
|
|
53922
|
-
return (n,
|
|
53940
|
+
return (n, a) => (V(), h("div", {
|
|
53923
53941
|
ref_key: "messageContainerRef",
|
|
53924
53942
|
ref: r,
|
|
53925
53943
|
class: "ai-message-container"
|
|
53926
53944
|
}, [
|
|
53927
|
-
(V(!0), h(o, null, U(
|
|
53945
|
+
(V(!0), h(o, null, U(b.value, (r, i) => (V(), h("div", {
|
|
53928
53946
|
id: r.uid,
|
|
53929
53947
|
key: i,
|
|
53930
53948
|
class: "message-group",
|
|
53931
53949
|
style: I({ backgroundColor: r.checked ? "#f5f7fa" : "transparent" }),
|
|
53932
|
-
onMouseenter: (e) =>
|
|
53933
|
-
onMouseleave: (e) =>
|
|
53950
|
+
onMouseenter: (e) => x(r),
|
|
53951
|
+
onMouseleave: (e) => S(r, e)
|
|
53934
53952
|
}, [W(n.$slots, "group", M({ ref_for: !0 }, { group: r }), () => [e.enableSelection && r.type !== J($A).Loading ? (V(), p(J(mb), {
|
|
53935
53953
|
key: 0,
|
|
53936
53954
|
class: "message-group-checkbox",
|
|
53937
53955
|
"model-value": r.checked,
|
|
53938
|
-
"onUpdate:modelValue": (e) =>
|
|
53956
|
+
"onUpdate:modelValue": (e) => C(r, e)
|
|
53939
53957
|
}, null, 8, ["model-value", "onUpdate:modelValue"])) : m("v-if", !0), g("div", {
|
|
53940
53958
|
class: P(["message-group-messages", { "message-group-enabled-selection": e.renderMode === J(pj).Share || e.enableSelection && r.type !== J($A).Loading }]),
|
|
53941
53959
|
style: I({ width: e.enableSelection && r.type !== J($A).Loading ? "calc(100% - 16px)" : "100%" })
|
|
@@ -53950,10 +53968,10 @@ var uG = ["src"], dG = {
|
|
|
53950
53968
|
key: i,
|
|
53951
53969
|
message: r,
|
|
53952
53970
|
"message-tools-status": e.messageToolsStatus,
|
|
53953
|
-
"on-action": (e) =>
|
|
53954
|
-
"on-input-confirm": (e, t) =>
|
|
53971
|
+
"on-action": (e) => T(e, r),
|
|
53972
|
+
"on-input-confirm": (e, t) => E(r, e, t),
|
|
53955
53973
|
"on-interrupt-resume": t.onInterruptResume,
|
|
53956
|
-
"on-shortcut-confirm": (e) =>
|
|
53974
|
+
"on-shortcut-confirm": (e) => D(r, e),
|
|
53957
53975
|
"tippy-options": e.messageToolsTippyOptions
|
|
53958
53976
|
}, _({ _: 2 }, [n.$slots.answeredQuestion ? {
|
|
53959
53977
|
name: "answeredQuestion",
|
|
@@ -53969,12 +53987,12 @@ var uG = ["src"], dG = {
|
|
|
53969
53987
|
"tippy-options"
|
|
53970
53988
|
]))])), 128)), e.renderMode !== J(pj).Share && !(e.enableSelection && r.type !== J($A).Loading) && !r.pause && r.type === J($A).Assistant && e.messageToolsStatus !== J(VW).Hidden ? (V(), p(oJ, {
|
|
53971
53989
|
key: 0,
|
|
53972
|
-
"message-tools":
|
|
53990
|
+
"message-tools": f.value,
|
|
53973
53991
|
"message-tools-status": e.messageToolsStatus,
|
|
53974
|
-
"on-action": (e) =>
|
|
53992
|
+
"on-action": (e) => w(e, r.messages),
|
|
53975
53993
|
style: I({ visibility: r.isHover ? "visible" : "hidden" }),
|
|
53976
53994
|
"tippy-options": t.messageToolsTippyOptions,
|
|
53977
|
-
"update-tools":
|
|
53995
|
+
"update-tools": v.value,
|
|
53978
53996
|
onFeedback: (e, n, i) => t.onAgentFeedback?.(e, r.messages, n, i)
|
|
53979
53997
|
}, null, 8, [
|
|
53980
53998
|
"message-tools",
|
|
@@ -53994,17 +54012,17 @@ var uG = ["src"], dG = {
|
|
|
53994
54012
|
g("div", FX, [he(y(DM, {
|
|
53995
54013
|
loading: e.messageStatus === J(ej).StopLoading,
|
|
53996
54014
|
title: e.messageStatus === J(ej).StopLoading ? J(Q)("正在停止") : J(Q)("停止生成"),
|
|
53997
|
-
onClick:
|
|
54015
|
+
onClick: a[0] ||= (e) => n.$emit("stopStreaming")
|
|
53998
54016
|
}, {
|
|
53999
54017
|
icon: Y(() => [y(J(Qj))]),
|
|
54000
54018
|
_: 1
|
|
54001
54019
|
}, 8, ["loading", "title"]), [[de, e.renderMode !== J(pj).Share && (e.messageStatus === J(ej).Streaming || e.messageStatus === J(ej).StopLoading || e.messageStatus === J(ej).Fetching || e.messageStatus === J(ej).Pending)]]), he(y(DM, {
|
|
54002
54020
|
title: J(Q)("返回底部"),
|
|
54003
|
-
onClick: J(
|
|
54021
|
+
onClick: a[1] ||= () => J(s)("smooth")
|
|
54004
54022
|
}, {
|
|
54005
54023
|
icon: Y(() => [y(J(gM))]),
|
|
54006
54024
|
_: 1
|
|
54007
|
-
}, 8, ["title"
|
|
54025
|
+
}, 8, ["title"]), [[de, J(c)]])])
|
|
54008
54026
|
], 512));
|
|
54009
54027
|
}
|
|
54010
54028
|
}), LX = { class: "ai-execution-summary" }, RX = { class: "ai-execution-summary-header" }, zX = { class: "ai-execution-summary-content" }, BX = ["onMouseenter"], VX = { class: "content-item-header" }, HX = { class: "content-item-title" }, UX = { class: "content-item-messages" }, WX = {
|
|
@@ -55731,17 +55749,17 @@ var EZ = class extends Error {
|
|
|
55731
55749
|
}
|
|
55732
55750
|
};
|
|
55733
55751
|
function DZ(e) {
|
|
55734
|
-
let { props: t, emit: n,
|
|
55752
|
+
let { props: t, emit: n, reportError: r, managerErrorBridge: i } = e, a = G(null), o = G(null), s = G(null), c = G(null), l = H(!1), u = H(!t.chatHelper), f = H(null), p = d(() => l.value), m = () => t.chatHelper ? !t.chatHelper.agent || !t.chatHelper.session || !t.chatHelper.message ? {
|
|
55735
55753
|
valid: !1,
|
|
55736
55754
|
error: "[ChatBot] Invalid chatHelper: missing required modules (agent, session, message)"
|
|
55737
55755
|
} : { valid: !0 } : t.url ? { valid: !0 } : {
|
|
55738
55756
|
valid: !1,
|
|
55739
55757
|
error: "[ChatBot] Neither chatHelper nor url provided. Component requires at least one."
|
|
55740
|
-
},
|
|
55741
|
-
let e =
|
|
55742
|
-
if (!e.valid) return console.error(e.error),
|
|
55758
|
+
}, h = () => {
|
|
55759
|
+
let e = m();
|
|
55760
|
+
if (!e.valid) return console.error(e.error), f.value = Error(e.error), null;
|
|
55743
55761
|
if (t.chatHelper) return t.chatHelper;
|
|
55744
|
-
let
|
|
55762
|
+
let i = new ST({
|
|
55745
55763
|
onStart: () => {
|
|
55746
55764
|
n("receive-start");
|
|
55747
55765
|
},
|
|
@@ -55749,76 +55767,76 @@ function DZ(e) {
|
|
|
55749
55767
|
n("receive-text");
|
|
55750
55768
|
},
|
|
55751
55769
|
onDone: () => {
|
|
55752
|
-
n("receive-end")
|
|
55770
|
+
n("receive-end");
|
|
55753
55771
|
},
|
|
55754
55772
|
onError: (e) => {
|
|
55755
|
-
|
|
55773
|
+
r(e, "Stream error");
|
|
55756
55774
|
}
|
|
55757
|
-
}),
|
|
55775
|
+
}), a = _E({
|
|
55758
55776
|
requestData: yE(kE(t.url), () => q(t.requestOptions)),
|
|
55759
|
-
protocol:
|
|
55777
|
+
protocol: i
|
|
55760
55778
|
});
|
|
55761
|
-
return
|
|
55762
|
-
},
|
|
55779
|
+
return i.injectMessageModule(a.message), a;
|
|
55780
|
+
}, g = async (e, t) => {
|
|
55763
55781
|
if (e) try {
|
|
55764
55782
|
let n = e.session.current?.value?.sessionCode ?? "";
|
|
55765
55783
|
await e.agent.stopChat(n), t && e.agent.abortChat();
|
|
55766
55784
|
} catch {}
|
|
55767
|
-
},
|
|
55768
|
-
|
|
55769
|
-
},
|
|
55770
|
-
if (e !==
|
|
55771
|
-
},
|
|
55772
|
-
let
|
|
55773
|
-
|
|
55774
|
-
let m =
|
|
55775
|
-
if (!m) throw
|
|
55776
|
-
let
|
|
55785
|
+
}, _ = 0, v = null, y = null, b = null, x = (e) => {
|
|
55786
|
+
b &&= (e ? b.reject(e) : b.resolve(), null), v = null;
|
|
55787
|
+
}, S = (e) => {
|
|
55788
|
+
if (e !== _) throw new EZ();
|
|
55789
|
+
}, C = async (e) => {
|
|
55790
|
+
let d = a.value, p = u.value;
|
|
55791
|
+
l.value = !1, f.value = null, u.value = !t.chatHelper, await g(d, p), S(e), a.value = null, o.value = null, s.value = null, c.value = null;
|
|
55792
|
+
let m = h();
|
|
55793
|
+
if (!m) throw f.value ?? /* @__PURE__ */ Error("[ChatBot] Failed to create chatHelper");
|
|
55794
|
+
let _ = new yZ(m.session, m.agent, i, {
|
|
55777
55795
|
enableChatSession: !0,
|
|
55778
55796
|
autoSwitchToInitialSession: !!t.sessionCode,
|
|
55779
55797
|
loadRecentSessionOnMount: t.autoLoad,
|
|
55780
55798
|
initialSessionCode: t.sessionCode,
|
|
55781
55799
|
alwaysCreateNewSession: t.alwaysCreateNewSession
|
|
55782
|
-
}, m.message), v = new vZ(m.agent, m.message, m.session,
|
|
55800
|
+
}, m.message), v = new vZ(m.agent, m.message, m.session, i, {
|
|
55783
55801
|
openingRemark: t.helloText,
|
|
55784
55802
|
predefinedQuestions: t.prompts,
|
|
55785
55803
|
placeholder: t.placeholder,
|
|
55786
55804
|
onSessionRenamed: (e) => n("rename", e)
|
|
55787
55805
|
}), y = new xZ(null, t.shortcuts || []);
|
|
55788
|
-
|
|
55806
|
+
a.value = m, o.value = _, s.value = v, c.value = y;
|
|
55789
55807
|
try {
|
|
55790
|
-
|
|
55808
|
+
u.value && (await _Z(m, { enableModelSelect: t.enableModelSelect !== !1 && !t.models?.length }), S(e), await _.loadRecentSession({ skipLoadSessions: !0 }), S(e)), t.enableModelSelect !== !1 && (t.models?.length ? v.setModels(t.models) : await v.loadModels(), S(e)), S(e), l.value = !0, n("agent-info-loaded", m);
|
|
55791
55809
|
} catch (t) {
|
|
55792
|
-
throw
|
|
55810
|
+
throw S(e), f.value = r(t, "Failed to initialize ChatBot"), t;
|
|
55793
55811
|
}
|
|
55794
|
-
},
|
|
55795
|
-
|
|
55796
|
-
let e = ++
|
|
55797
|
-
|
|
55798
|
-
|
|
55812
|
+
}, w = () => {
|
|
55813
|
+
x(new EZ()), y = null;
|
|
55814
|
+
let e = ++_;
|
|
55815
|
+
v = new Promise((t, n) => {
|
|
55816
|
+
b = {
|
|
55799
55817
|
resolve: t,
|
|
55800
55818
|
reject: n
|
|
55801
|
-
},
|
|
55802
|
-
|
|
55819
|
+
}, C(e).then(() => {
|
|
55820
|
+
b &&= (y = Promise.resolve(), b.resolve(), null);
|
|
55803
55821
|
}).catch((e) => {
|
|
55804
|
-
|
|
55822
|
+
b &&= (b.reject(EE(e)), null);
|
|
55805
55823
|
}).finally(() => {
|
|
55806
|
-
e ===
|
|
55824
|
+
e === _ && (v = null);
|
|
55807
55825
|
});
|
|
55808
|
-
}),
|
|
55826
|
+
}), v.catch(() => {});
|
|
55809
55827
|
};
|
|
55810
|
-
return fe([() => t.url, () => t.chatHelper], () =>
|
|
55811
|
-
|
|
55828
|
+
return fe([() => t.url, () => t.chatHelper], () => w(), { immediate: !0 }), L(() => {
|
|
55829
|
+
x(), g(a.value, u.value);
|
|
55812
55830
|
}), {
|
|
55813
|
-
chatHelper:
|
|
55814
|
-
isStandaloneMode:
|
|
55815
|
-
isInitialized:
|
|
55816
|
-
isReady:
|
|
55817
|
-
initError:
|
|
55818
|
-
whenReady: () =>
|
|
55819
|
-
chatBusinessManager:
|
|
55820
|
-
sessionBusinessManager:
|
|
55821
|
-
shortcutManager:
|
|
55831
|
+
chatHelper: a,
|
|
55832
|
+
isStandaloneMode: u,
|
|
55833
|
+
isInitialized: l,
|
|
55834
|
+
isReady: p,
|
|
55835
|
+
initError: f,
|
|
55836
|
+
whenReady: () => l.value ? (y ||= Promise.resolve(), y) : f.value ? Promise.reject(f.value) : v || Promise.resolve(),
|
|
55837
|
+
chatBusinessManager: s,
|
|
55838
|
+
sessionBusinessManager: o,
|
|
55839
|
+
shortcutManager: c
|
|
55822
55840
|
};
|
|
55823
55841
|
}
|
|
55824
55842
|
//#endregion
|
|
@@ -56139,7 +56157,7 @@ function VZ(e) {
|
|
|
56139
56157
|
//#endregion
|
|
56140
56158
|
//#region src/components/composables/use-tool-actions.ts
|
|
56141
56159
|
function HZ(e) {
|
|
56142
|
-
let { emit: t, chatHelper: n, chatBusinessManager: r, cite: i, focusInput: a,
|
|
56160
|
+
let { emit: t, chatHelper: n, chatBusinessManager: r, cite: i, focusInput: a, getShortcutFromMessage: o, buildShortcutProperty: s, getRequestOptions: c, reportError: l, stopGeneration: u } = e, d = async (e) => {
|
|
56143
56161
|
if (!r.value || !n.value) {
|
|
56144
56162
|
console.error("[ChatBot] Cannot delete messages: chatBusinessManager not initialized");
|
|
56145
56163
|
return;
|
|
@@ -56153,9 +56171,9 @@ function HZ(e) {
|
|
|
56153
56171
|
let a = [i, ...e];
|
|
56154
56172
|
await n.value.message.deleteMessages(a);
|
|
56155
56173
|
} catch (e) {
|
|
56156
|
-
|
|
56174
|
+
l(e, "Failed to delete messages");
|
|
56157
56175
|
}
|
|
56158
|
-
},
|
|
56176
|
+
}, f = async (e) => {
|
|
56159
56177
|
if (!r.value || !n.value) {
|
|
56160
56178
|
console.error("[ChatBot] Cannot regenerate: chatBusinessManager not initialized");
|
|
56161
56179
|
return;
|
|
@@ -56166,11 +56184,11 @@ function HZ(e) {
|
|
|
56166
56184
|
return;
|
|
56167
56185
|
}
|
|
56168
56186
|
try {
|
|
56169
|
-
await r.value.regenerateFromAIMessages(e, t)
|
|
56187
|
+
await r.value.regenerateFromAIMessages(e, t);
|
|
56170
56188
|
} catch (e) {
|
|
56171
|
-
|
|
56189
|
+
l(e, "Failed to regenerate");
|
|
56172
56190
|
}
|
|
56173
|
-
},
|
|
56191
|
+
}, p = async (e) => {
|
|
56174
56192
|
if (!r.value || !n.value) {
|
|
56175
56193
|
console.error("[ChatBot] Cannot delete message: chatHelper not initialized");
|
|
56176
56194
|
return;
|
|
@@ -56190,7 +56208,7 @@ function HZ(e) {
|
|
|
56190
56208
|
let o = [e, ...a];
|
|
56191
56209
|
await n.value.message.deleteMessages(o);
|
|
56192
56210
|
} catch (e) {
|
|
56193
|
-
|
|
56211
|
+
l(e, "Failed to delete user message");
|
|
56194
56212
|
}
|
|
56195
56213
|
};
|
|
56196
56214
|
return {
|
|
@@ -56200,11 +56218,11 @@ function HZ(e) {
|
|
|
56200
56218
|
return;
|
|
56201
56219
|
}
|
|
56202
56220
|
if (e.id === "rebuild") {
|
|
56203
|
-
await
|
|
56221
|
+
await f(r);
|
|
56204
56222
|
return;
|
|
56205
56223
|
}
|
|
56206
56224
|
if (e.id === "delete") {
|
|
56207
|
-
await
|
|
56225
|
+
await d(r);
|
|
56208
56226
|
return;
|
|
56209
56227
|
}
|
|
56210
56228
|
if (e.id === "like" || e.id === "unlike") {
|
|
@@ -56232,22 +56250,22 @@ function HZ(e) {
|
|
|
56232
56250
|
console.error("[ChatBot] Cannot submit feedback: no user message found");
|
|
56233
56251
|
return;
|
|
56234
56252
|
}
|
|
56235
|
-
let
|
|
56253
|
+
let u = e.id === "like" ? 5 : 0;
|
|
56236
56254
|
try {
|
|
56237
56255
|
await n.value.session.postSessionFeedback({
|
|
56238
56256
|
sessionCode: s,
|
|
56239
56257
|
sessionContentIds: [c],
|
|
56240
|
-
rate:
|
|
56258
|
+
rate: u,
|
|
56241
56259
|
labels: a,
|
|
56242
56260
|
comment: o
|
|
56243
56261
|
}), t("feedback", e, i[0], a, o);
|
|
56244
56262
|
} catch (e) {
|
|
56245
|
-
|
|
56263
|
+
l(e, "Failed to submit feedback");
|
|
56246
56264
|
}
|
|
56247
56265
|
},
|
|
56248
56266
|
handleUserAction: async (e, t) => {
|
|
56249
56267
|
if (e.id === "delete") {
|
|
56250
|
-
await
|
|
56268
|
+
await p(t);
|
|
56251
56269
|
return;
|
|
56252
56270
|
}
|
|
56253
56271
|
if (e.id === "cite") {
|
|
@@ -56266,16 +56284,16 @@ function HZ(e) {
|
|
|
56266
56284
|
console.error("[ChatBot] Cannot edit message: no active session");
|
|
56267
56285
|
return;
|
|
56268
56286
|
}
|
|
56269
|
-
let
|
|
56270
|
-
if (
|
|
56287
|
+
let o = e.id;
|
|
56288
|
+
if (o === void 0) {
|
|
56271
56289
|
console.error("[ChatBot] Cannot edit message: message has no id");
|
|
56272
56290
|
return;
|
|
56273
56291
|
}
|
|
56274
56292
|
try {
|
|
56275
|
-
let n = e.property, i = xE(n,
|
|
56276
|
-
await r.value?.resendMessageWithProperty(String(
|
|
56293
|
+
let n = e.property, i = xE(n, c);
|
|
56294
|
+
await r.value?.resendMessageWithProperty(String(o), a, typeof t == "string" ? t : "", i);
|
|
56277
56295
|
} catch (e) {
|
|
56278
|
-
|
|
56296
|
+
l(e, "Failed to edit and resend message");
|
|
56279
56297
|
}
|
|
56280
56298
|
},
|
|
56281
56299
|
handleUserShortcutConfirm: async (e, t) => {
|
|
@@ -56294,18 +56312,18 @@ function HZ(e) {
|
|
|
56294
56312
|
return;
|
|
56295
56313
|
}
|
|
56296
56314
|
try {
|
|
56297
|
-
let n =
|
|
56315
|
+
let n = o(e);
|
|
56298
56316
|
if (!n) {
|
|
56299
56317
|
console.error("[ChatBot] Cannot edit shortcut message: shortcut not found");
|
|
56300
56318
|
return;
|
|
56301
56319
|
}
|
|
56302
|
-
let
|
|
56303
|
-
await r.value.resendMessageWithProperty(String(a), i,
|
|
56320
|
+
let l = xE(s(n, t), c), u = String(t.input ?? "");
|
|
56321
|
+
await r.value.resendMessageWithProperty(String(a), i, u, l);
|
|
56304
56322
|
} catch (e) {
|
|
56305
|
-
|
|
56323
|
+
l(e, "Failed to edit shortcut message");
|
|
56306
56324
|
}
|
|
56307
56325
|
},
|
|
56308
|
-
handleStopStreaming:
|
|
56326
|
+
handleStopStreaming: u
|
|
56309
56327
|
};
|
|
56310
56328
|
}
|
|
56311
56329
|
//#endregion
|
|
@@ -56385,194 +56403,190 @@ var UZ = /* @__PURE__ */ x({
|
|
|
56385
56403
|
}, a = d(() => ({
|
|
56386
56404
|
...i,
|
|
56387
56405
|
...r.resizeProps
|
|
56388
|
-
})), s = n, c = le(), l = H(), u = H(), f =
|
|
56406
|
+
})), s = n, c = le(), l = H(), u = H(), f = G([]), p = H(null), g = d({
|
|
56389
56407
|
get: () => r.renderMode ?? pj.Chat,
|
|
56390
56408
|
set: () => {}
|
|
56391
|
-
}),
|
|
56392
|
-
|
|
56393
|
-
}, S = ()
|
|
56394
|
-
f.value?.focus?.();
|
|
56395
|
-
}, { reportError: w, managerErrorBridge: T } = AZ(s), { chatHelper: E, isStandaloneMode: D, isInitialized: k, isReady: A, initError: j, whenReady: M, chatBusinessManager: L, sessionBusinessManager: R, shortcutManager: z } = DZ({
|
|
56409
|
+
}), v = d(() => j.value?.selectedLlmCode.value), b = () => {
|
|
56410
|
+
u.value?.focus?.();
|
|
56411
|
+
}, { reportError: x, managerErrorBridge: S } = AZ(s), { chatHelper: w, isStandaloneMode: T, isInitialized: E, isReady: D, initError: k, whenReady: A, chatBusinessManager: j, sessionBusinessManager: M, shortcutManager: N } = DZ({
|
|
56396
56412
|
props: r,
|
|
56397
56413
|
emit: s,
|
|
56398
|
-
|
|
56399
|
-
|
|
56400
|
-
|
|
56401
|
-
|
|
56402
|
-
|
|
56403
|
-
|
|
56404
|
-
}), { userInput: te, cite: ne, handleUpdateModelValue: re, doSendMessage: U, handleSendMessage: ie, handleUpload: K, handleArtifactClick: ae, handleStopSending: q, stopGeneration: oe } = RZ({
|
|
56414
|
+
reportError: x,
|
|
56415
|
+
managerErrorBridge: S
|
|
56416
|
+
}), { handleInterruptResume: L, resumeUserQuestionWithInput: R } = LZ({
|
|
56417
|
+
chatHelper: w,
|
|
56418
|
+
reportError: x
|
|
56419
|
+
}), { userInput: z, cite: B, handleUpdateModelValue: ee, doSendMessage: te, handleSendMessage: ne, handleUpload: re, handleArtifactClick: U, handleStopSending: ie, stopGeneration: K } = RZ({
|
|
56405
56420
|
emit: s,
|
|
56406
|
-
chatHelper:
|
|
56407
|
-
chatBusinessManager:
|
|
56421
|
+
chatHelper: w,
|
|
56422
|
+
chatBusinessManager: j,
|
|
56408
56423
|
getRequestOptions: () => r.requestOptions,
|
|
56409
|
-
reportError:
|
|
56410
|
-
resumeUserQuestionWithInput:
|
|
56411
|
-
selectedShortcut:
|
|
56412
|
-
selectedResources:
|
|
56413
|
-
}), { handleSelectShortcut:
|
|
56424
|
+
reportError: x,
|
|
56425
|
+
resumeUserQuestionWithInput: R,
|
|
56426
|
+
selectedShortcut: p,
|
|
56427
|
+
selectedResources: f
|
|
56428
|
+
}), { handleSelectShortcut: ae, handleCloseShortcut: q, handleShortcutSubmit: oe, selectShortcutWithText: se, getShortcutFromMessage: ce, buildShortcutProperty: ue, sendShortcutDirectly: de } = VZ({
|
|
56414
56429
|
props: r,
|
|
56415
56430
|
emit: s,
|
|
56416
|
-
chatHelper:
|
|
56417
|
-
shortcutManager:
|
|
56418
|
-
doSendMessage:
|
|
56419
|
-
reportError:
|
|
56420
|
-
selectedShortcut:
|
|
56421
|
-
}), { messageStatus:
|
|
56431
|
+
chatHelper: w,
|
|
56432
|
+
shortcutManager: N,
|
|
56433
|
+
doSendMessage: te,
|
|
56434
|
+
reportError: x,
|
|
56435
|
+
selectedShortcut: p
|
|
56436
|
+
}), { messageStatus: pe, messageToolsStatus: me, messages: he, isMessagesLoading: ge, isGenerating: _e, currentSession: ve, isWelcomeState: ye, openingRemark: be, effectiveResources: xe, effectivePrompts: Se, effectiveSkills: Ce, effectiveSupportUpload: we, chatbotStyle: Te, filteredShortcuts: Ee } = OZ({
|
|
56422
56437
|
props: r,
|
|
56423
|
-
chatHelper:
|
|
56424
|
-
chatBusinessManager:
|
|
56425
|
-
sessionBusinessManager:
|
|
56426
|
-
shortcutManager:
|
|
56427
|
-
isStandaloneMode:
|
|
56428
|
-
isInitialized:
|
|
56429
|
-
selectedShortcut:
|
|
56430
|
-
}), { handleAgentAction:
|
|
56438
|
+
chatHelper: w,
|
|
56439
|
+
chatBusinessManager: j,
|
|
56440
|
+
sessionBusinessManager: M,
|
|
56441
|
+
shortcutManager: N,
|
|
56442
|
+
isStandaloneMode: T,
|
|
56443
|
+
isInitialized: E,
|
|
56444
|
+
selectedShortcut: p
|
|
56445
|
+
}), { handleAgentAction: De, handleAgentFeedback: Oe, handleUserAction: ke, handleUserInputConfirm: Ae, handleUserShortcutConfirm: je, handleStopStreaming: Me } = HZ({
|
|
56431
56446
|
emit: s,
|
|
56432
|
-
chatHelper:
|
|
56433
|
-
chatBusinessManager:
|
|
56434
|
-
cite:
|
|
56435
|
-
focusInput:
|
|
56436
|
-
|
|
56437
|
-
|
|
56438
|
-
buildShortcutProperty: me,
|
|
56447
|
+
chatHelper: w,
|
|
56448
|
+
chatBusinessManager: j,
|
|
56449
|
+
cite: B,
|
|
56450
|
+
focusInput: b,
|
|
56451
|
+
getShortcutFromMessage: ce,
|
|
56452
|
+
buildShortcutProperty: ue,
|
|
56439
56453
|
getRequestOptions: () => r.requestOptions,
|
|
56440
|
-
reportError:
|
|
56441
|
-
stopGeneration:
|
|
56442
|
-
}),
|
|
56443
|
-
if (r.useAgentName) return
|
|
56444
|
-
}),
|
|
56454
|
+
reportError: x,
|
|
56455
|
+
stopGeneration: K
|
|
56456
|
+
}), Ne = d(() => !E.value || ge.value), Pe = d(() => {
|
|
56457
|
+
if (r.useAgentName) return w.value?.agent.info.value?.agentName || void 0;
|
|
56458
|
+
}), Fe = d(() => {
|
|
56445
56459
|
if (r.enableModelSelect === !1) return;
|
|
56446
|
-
let e =
|
|
56460
|
+
let e = j.value?.models.value ?? [];
|
|
56447
56461
|
return e.length > 0 ? e : void 0;
|
|
56448
|
-
}),
|
|
56449
|
-
get: () =>
|
|
56462
|
+
}), Ie = d({
|
|
56463
|
+
get: () => j.value?.selectedModelName.value ?? "",
|
|
56450
56464
|
set: (e) => {
|
|
56451
|
-
|
|
56465
|
+
j.value?.setSelectedModelByName(e);
|
|
56452
56466
|
}
|
|
56453
|
-
}),
|
|
56454
|
-
|
|
56467
|
+
}), Le = (e) => {
|
|
56468
|
+
j.value?.setSelectedModel(e);
|
|
56455
56469
|
};
|
|
56456
56470
|
fe(() => r.models, (e) => {
|
|
56457
|
-
r.enableModelSelect === !1 || !
|
|
56471
|
+
r.enableModelSelect === !1 || !j.value || e?.length && j.value.setModels(e);
|
|
56458
56472
|
});
|
|
56459
|
-
let { handleConfirmShare:
|
|
56473
|
+
let { handleConfirmShare: Re } = BZ({
|
|
56460
56474
|
emit: s,
|
|
56461
|
-
chatHelper:
|
|
56462
|
-
isStandaloneMode:
|
|
56463
|
-
}),
|
|
56475
|
+
chatHelper: w,
|
|
56476
|
+
isStandaloneMode: T
|
|
56477
|
+
}), ze = (e, t) => {
|
|
56464
56478
|
s("execution-panel-change", e, t);
|
|
56465
|
-
},
|
|
56479
|
+
}, Be = async (e) => {
|
|
56466
56480
|
if (r.onCustomTabChange) return r.onCustomTabChange(e);
|
|
56467
56481
|
let t = e.data?.props;
|
|
56468
|
-
if (t?.task_id != null && t?.node_id) return
|
|
56482
|
+
if (t?.task_id != null && t?.node_id) return w.value?.message.getFlowAgentTaskNodeInfo(t.task_id, t.node_id);
|
|
56469
56483
|
};
|
|
56470
56484
|
return t({
|
|
56471
|
-
sendMessage: (e) =>
|
|
56472
|
-
stopGeneration:
|
|
56485
|
+
sendMessage: (e) => ne(e, [[]]),
|
|
56486
|
+
stopGeneration: K,
|
|
56473
56487
|
switchSession: async (e) => {
|
|
56474
|
-
if (!
|
|
56488
|
+
if (!M.value) {
|
|
56475
56489
|
console.error("[ChatBot] Cannot switch session: sessionBusinessManager not initialized");
|
|
56476
56490
|
return;
|
|
56477
56491
|
}
|
|
56478
56492
|
try {
|
|
56479
|
-
await
|
|
56493
|
+
await M.value.switchSession(e), s("session-switched", M.value.currentSession.value);
|
|
56480
56494
|
} catch (e) {
|
|
56481
|
-
|
|
56495
|
+
x(e, "Failed to switch session");
|
|
56482
56496
|
}
|
|
56483
56497
|
},
|
|
56484
|
-
messages:
|
|
56485
|
-
currentSession:
|
|
56486
|
-
isGenerating:
|
|
56498
|
+
messages: he,
|
|
56499
|
+
currentSession: ve,
|
|
56500
|
+
isGenerating: _e,
|
|
56487
56501
|
get isReady() {
|
|
56488
|
-
return
|
|
56502
|
+
return D.value;
|
|
56489
56503
|
},
|
|
56490
|
-
whenReady:
|
|
56491
|
-
getChatHelper: () =>
|
|
56504
|
+
whenReady: A,
|
|
56505
|
+
getChatHelper: () => w.value,
|
|
56492
56506
|
setCiteText: (e) => {
|
|
56493
|
-
|
|
56507
|
+
B.value = e;
|
|
56494
56508
|
},
|
|
56495
|
-
focusInput:
|
|
56496
|
-
enterShareMode: () =>
|
|
56497
|
-
exitShareMode: () =>
|
|
56509
|
+
focusInput: b,
|
|
56510
|
+
enterShareMode: () => l.value?.enterShareMode(),
|
|
56511
|
+
exitShareMode: () => l.value?.exitShareMode(),
|
|
56498
56512
|
selectShortcut: (e, t) => {
|
|
56499
|
-
|
|
56513
|
+
se(e, t);
|
|
56500
56514
|
},
|
|
56501
|
-
sendShortcut: (e, t) =>
|
|
56515
|
+
sendShortcut: (e, t) => de(e, t),
|
|
56502
56516
|
updateAgentInfo: async () => {
|
|
56503
|
-
let e =
|
|
56517
|
+
let e = w.value;
|
|
56504
56518
|
if (!e) return null;
|
|
56505
56519
|
try {
|
|
56506
56520
|
await e.agent.getAgentInfo();
|
|
56507
56521
|
let t = e.agent.info.value ?? null;
|
|
56508
|
-
return t?.conversationSettings?.commands &&
|
|
56522
|
+
return t?.conversationSettings?.commands && N.value?.setAgentShortcuts(t.conversationSettings.commands), t;
|
|
56509
56523
|
} catch (e) {
|
|
56510
|
-
return
|
|
56524
|
+
return x(e, "Failed to update agentInfo"), null;
|
|
56511
56525
|
}
|
|
56512
56526
|
},
|
|
56513
|
-
selectedLlmCode:
|
|
56527
|
+
selectedLlmCode: v
|
|
56514
56528
|
}), (t, n) => (V(), h("div", {
|
|
56515
56529
|
class: P([
|
|
56516
56530
|
"ai-chatbot",
|
|
56517
56531
|
r.extCls,
|
|
56518
|
-
{ "welcome-state": J(
|
|
56532
|
+
{ "welcome-state": J(ye) }
|
|
56519
56533
|
]),
|
|
56520
|
-
style: I(J(
|
|
56534
|
+
style: I(J(Te))
|
|
56521
56535
|
}, [y(J(aZ), {
|
|
56522
56536
|
ref_key: "chatContainerRef",
|
|
56523
|
-
ref:
|
|
56524
|
-
cite: J(
|
|
56525
|
-
"onUpdate:cite": n[0] ||= (e) => O(
|
|
56526
|
-
"selected-shortcut":
|
|
56527
|
-
"onUpdate:selectedShortcut": n[1] ||= (e) =>
|
|
56528
|
-
"selected-model":
|
|
56529
|
-
"onUpdate:selectedModel": n[2] ||= (e) =>
|
|
56530
|
-
"render-mode":
|
|
56531
|
-
"onUpdate:renderMode": n[3] ||= (e) =>
|
|
56532
|
-
"chat-loading":
|
|
56537
|
+
ref: l,
|
|
56538
|
+
cite: J(B),
|
|
56539
|
+
"onUpdate:cite": n[0] ||= (e) => O(B) ? B.value = e : null,
|
|
56540
|
+
"selected-shortcut": p.value,
|
|
56541
|
+
"onUpdate:selectedShortcut": n[1] ||= (e) => p.value = e,
|
|
56542
|
+
"selected-model": Ie.value,
|
|
56543
|
+
"onUpdate:selectedModel": n[2] ||= (e) => Ie.value = e,
|
|
56544
|
+
"render-mode": g.value,
|
|
56545
|
+
"onUpdate:renderMode": n[3] ||= (e) => g.value = e,
|
|
56546
|
+
"chat-loading": Ne.value,
|
|
56533
56547
|
"common-tippy-options": e.messageToolsTippyOptions,
|
|
56534
56548
|
"execution-tab-visible": r.executionTabVisible,
|
|
56535
|
-
"message-status": J(
|
|
56549
|
+
"message-status": J(pe),
|
|
56536
56550
|
"message-tools": r.messageTools,
|
|
56537
|
-
"message-tools-status": J(
|
|
56538
|
-
messages: J(
|
|
56539
|
-
"model-value": J(
|
|
56540
|
-
models:
|
|
56541
|
-
"on-agent-action": J(
|
|
56542
|
-
"on-agent-feedback": J(
|
|
56543
|
-
"on-interrupt-resume": J(
|
|
56551
|
+
"message-tools-status": J(me),
|
|
56552
|
+
messages: J(he),
|
|
56553
|
+
"model-value": J(z),
|
|
56554
|
+
models: Fe.value,
|
|
56555
|
+
"on-agent-action": J(De),
|
|
56556
|
+
"on-agent-feedback": J(Oe),
|
|
56557
|
+
"on-interrupt-resume": J(L),
|
|
56544
56558
|
"get-side-render-component": r.getSideRenderComponent,
|
|
56545
56559
|
"get-side-tab-render-component": r.getSideTabRenderComponent,
|
|
56546
|
-
"on-custom-tab-change":
|
|
56547
|
-
"on-send-message": J(
|
|
56548
|
-
"on-stop-sending": J(
|
|
56549
|
-
"on-artifact-click": J(
|
|
56550
|
-
"on-upload": J(
|
|
56551
|
-
"on-user-action": J(
|
|
56552
|
-
"on-user-input-confirm": J(
|
|
56553
|
-
"on-user-shortcut-confirm": J(
|
|
56554
|
-
"opening-remark": J(
|
|
56560
|
+
"on-custom-tab-change": Be,
|
|
56561
|
+
"on-send-message": J(ne),
|
|
56562
|
+
"on-stop-sending": J(ie),
|
|
56563
|
+
"on-artifact-click": J(U),
|
|
56564
|
+
"on-upload": J(re),
|
|
56565
|
+
"on-user-action": J(ke),
|
|
56566
|
+
"on-user-input-confirm": J(Ae),
|
|
56567
|
+
"on-user-shortcut-confirm": J(je),
|
|
56568
|
+
"opening-remark": J(be),
|
|
56555
56569
|
placeholder: r.placeholder,
|
|
56556
56570
|
placement: r.placement,
|
|
56557
|
-
"welcome-title":
|
|
56558
|
-
prompts: J(
|
|
56571
|
+
"welcome-title": Pe.value,
|
|
56572
|
+
prompts: J(Se),
|
|
56559
56573
|
"resize-props": a.value,
|
|
56560
56574
|
size: r.size,
|
|
56561
|
-
resources: J(
|
|
56562
|
-
"shortcut-id":
|
|
56563
|
-
shortcuts: J(
|
|
56564
|
-
skills: J(
|
|
56565
|
-
"support-upload": J(
|
|
56575
|
+
resources: J(xe),
|
|
56576
|
+
"shortcut-id": p.value?.id,
|
|
56577
|
+
shortcuts: J(Ee),
|
|
56578
|
+
skills: J(Ce),
|
|
56579
|
+
"support-upload": J(we),
|
|
56566
56580
|
"update-tools": r.updateTools,
|
|
56567
|
-
onCollapseChange:
|
|
56568
|
-
onConfirmShare: J(
|
|
56569
|
-
onDeleteShortcut: J(
|
|
56570
|
-
onModelChange:
|
|
56571
|
-
onSelectShortcut: J(
|
|
56572
|
-
onShortcutClose: J(
|
|
56573
|
-
onShortcutSubmit: J(
|
|
56574
|
-
onStopStreaming: J(
|
|
56575
|
-
"onUpdate:modelValue": J(
|
|
56581
|
+
onCollapseChange: ze,
|
|
56582
|
+
onConfirmShare: J(Re),
|
|
56583
|
+
onDeleteShortcut: J(q),
|
|
56584
|
+
onModelChange: Le,
|
|
56585
|
+
onSelectShortcut: J(ae),
|
|
56586
|
+
onShortcutClose: J(q),
|
|
56587
|
+
onShortcutSubmit: J(oe),
|
|
56588
|
+
onStopStreaming: J(Me),
|
|
56589
|
+
"onUpdate:modelValue": J(ee)
|
|
56576
56590
|
}, _({
|
|
56577
56591
|
message: Y(({ message: n, messageToolsStatus: r, onInterruptResume: i }) => [m(" 消费方提供了 #message slot 时,优先使用消费方的渲染 "), J(c).message ? W(t.$slots, "message", {
|
|
56578
56592
|
key: 0,
|
|
@@ -56582,10 +56596,10 @@ var UZ = /* @__PURE__ */ x({
|
|
|
56582
56596
|
}) : (V(), h(o, { key: 1 }, [m(" 否则使用默认的 MessageRender "), y(J(NX), {
|
|
56583
56597
|
message: n,
|
|
56584
56598
|
"message-tools-status": r,
|
|
56585
|
-
"on-action": (e) => J(
|
|
56586
|
-
"on-input-confirm": (e, t) => J(
|
|
56599
|
+
"on-action": (e) => J(ke)(e, n),
|
|
56600
|
+
"on-input-confirm": (e, t) => J(Ae)(n, e, t),
|
|
56587
56601
|
"on-interrupt-resume": i,
|
|
56588
|
-
"on-shortcut-confirm": (e) => J(
|
|
56602
|
+
"on-shortcut-confirm": (e) => J(je)(n, e),
|
|
56589
56603
|
"tippy-options": e.messageToolsTippyOptions
|
|
56590
56604
|
}, _({ _: 2 }, [t.$slots.codeHeader ? {
|
|
56591
56605
|
name: "codeHeader",
|