From 21e9b9a3dd6acf8e0437935beb04912d37492747 Mon Sep 17 00:00:00 2001 From: Your Name Date: Wed, 18 Feb 2026 21:41:56 +0800 Subject: [PATCH] fix: prevent canvas assistant bubbles from clipping long history text --- components/canvas/CanvasChatPanel.tsx | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/components/canvas/CanvasChatPanel.tsx b/components/canvas/CanvasChatPanel.tsx index 4082dde99..553aac771 100644 --- a/components/canvas/CanvasChatPanel.tsx +++ b/components/canvas/CanvasChatPanel.tsx @@ -3285,7 +3285,7 @@ export function CanvasChatPanel({ chatId, initialMessages = [], onClose, onOpenF {/* 消息气泡 */}
{message.role === 'user' ? ( @@ -3379,7 +3379,7 @@ export function CanvasChatPanel({ chatId, initialMessages = [], onClose, onOpenF )} > {/* 消息内容 */} -
+
{cleanedMessage.parts?.map((part: any, i: number) => { if (part.type === 'text') { // 提取并显示图片 @@ -3390,7 +3390,11 @@ export function CanvasChatPanel({ chatId, initialMessages = [], onClose, onOpenF return (
- {textWithoutImages && {textWithoutImages}} + {textWithoutImages && ( + + {textWithoutImages} + + )} {imageUrls.length > 0 && (
{imageUrls.map((url, idx) => (