This commit is contained in:
xuhd committed 2026-06-10 11:27:48 +08:00
1 parent e54f42c0eb
commit b8d3a549df
3 files changed
+74 -6

No files matched your search

@@ -291,6 +291,17 @@ export default function StudioNotebookDetailPage() {
await send(text, selectedSourceIds);
};
// Clarification 卡片的「发送」按钮回调。MessageList 内部把用户选中的选项 +
// 自由文本合并成一段 answer 传过来,这里走和普通发送同一条 send() 链路,
// 把当前选中的来源也一并带上,保持上下文一致。
const handleClarificationSubmit = useCallback(
async (answer: string) => {
if (isStreaming) return;
await send(answer, selectedSourceIds);
},
[send, selectedSourceIds, isStreaming],
);
const handleBackToList = () => {
setActiveThreadId(null);
setThreadId(undefined);
@@ -655,6 +666,7 @@ export default function StudioNotebookDetailPage() {
thread={thread}
paddingBottom={120}
extraRehypePlugins={citationRehypePlugins}
onClarificationSubmit={handleClarificationSubmit}
/>
</div>
)}