From c6a90d4bb39da93eccdfca1c42cf3aa2a3c98de1 Mon Sep 17 00:00:00 2001 From: Davide Delbianco Date: Mon, 13 Oct 2025 11:31:52 +0200 Subject: [PATCH] fix: Don't hide chat streaming loader on '\n' content (#26829) --- web/app/components/base/chat/chat/answer/index.tsx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/web/app/components/base/chat/chat/answer/index.tsx b/web/app/components/base/chat/chat/answer/index.tsx index 51eb00cfc5..a1b458ba9a 100644 --- a/web/app/components/base/chat/chat/answer/index.tsx +++ b/web/app/components/base/chat/chat/answer/index.tsx @@ -111,6 +111,8 @@ const Answer: FC = ({ } }, [switchSibling, item.prevSibling, item.nextSibling]) + const contentIsEmpty = content.trim() === '' + return (
@@ -153,14 +155,14 @@ const Answer: FC = ({ ) } { - responding && !content && !hasAgentThoughts && ( + responding && contentIsEmpty && !hasAgentThoughts && (
) } { - content && !hasAgentThoughts && ( + !contentIsEmpty && !hasAgentThoughts && ( ) }