Commit b809c5af by weiyudumei

fix: 修复历史记录也会触发自动提交的问题,历史记录不渲染ChatAnswerAttachment

parent 37d31ea8
......@@ -28,7 +28,9 @@ export const ChatAnswerShower: React.FC<ChatAnswerShowerProps> = ({ answer, isLa
</MarkdownDetail>
</div>
)}
{answer.cardList && answer.cardList?.length !== 0 && (
{/* 历史记录(isShow === true)且 firstQaFlag === true 时,不渲染 ChatAnswerAttachment(避免触发自动提交)
流式返回的新记录(isShow === false)正常渲染 */}
{answer.cardList && answer.cardList?.length !== 0 && !(answer.isShow === true && answer.firstQaFlag === true) && (
<ChatAnswerAttachment
onSubmitQuestion={onSubmitQuestion}
isLastAnswer={isLastAnswer}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment