feat: Conditionally hide thinking loader for paused messages (#1875)

Co-authored-by: lizhixuan <zhixuan.li@banosuperapp.com>
This commit is contained in:
MyPrototypeWhat
2025-02-18 11:10:48 +08:00
committed by GitHub
parent e5ace39a75
commit 4c6cc4140c
@@ -33,6 +33,7 @@ const MessageThought: FC<Props> = ({ message }) => {
const thinkingTime = message.metrics?.time_thinking_millsec || 0
const thinkingTimeSeconds = (thinkingTime / 1000).toFixed(1)
const isPaused = message.status === 'paused'
return (
<CollapseContainer
@@ -48,7 +49,7 @@ const MessageThought: FC<Props> = ({ message }) => {
<TinkingText>
{isThinking ? t('chat.thinking') : t('chat.deeply_thought', { secounds: thinkingTimeSeconds })}
</TinkingText>
{isThinking && <BarLoader color="#9254de" />}
{isThinking && !isPaused && <BarLoader color="#9254de" />}
</MessageTitleLabel>
),
children: (