diff --git a/app/components/ConversationFrontend.tsx b/app/components/ConversationFrontend.tsx index 5a5632f..e6b2684 100644 --- a/app/components/ConversationFrontend.tsx +++ b/app/components/ConversationFrontend.tsx @@ -16,23 +16,23 @@ interface ConversationProps { const ConversationFrontend = React.forwardRef( ({ messages, onResendClick, onEditClick, onCopyClick, isClicked }, ref: ForwardedRef) => { - const messagesEndRef = useRef(null) + const messagesEndRef = useRef(null) - useEffect(() => { + useEffect(() => { messagesEndRef.current?.scrollIntoView() - }, [messages]) + },[messages]) return (
{messages.map((message, index) => { - if (index >= 1) { + if (index >= 1){ return (
+ >

{message.content}

); @@ -49,10 +49,10 @@ const ConversationFrontend = React.forwardRef -

Copied!

+

Copied!

-
+
); }