Skip to content

Commit 434624e

Browse files
committed
✨ Fix old agents
1 parent c1c1984 commit 434624e

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

next/src/pages/agent/index.tsx

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ import { languages } from "../../utils/languages";
1414
import { serverSideTranslations } from "next-i18next/serverSideTranslations";
1515
import nextI18NextConfig from "../../../next-i18next.config";
1616
import DashboardLayout from "../../layout/dashboard";
17+
import FadeIn from "../../components/motions/FadeIn";
18+
import { ChatMessage } from "../../components/console/ChatMessage";
1719

1820
const AgentPage: NextPage = () => {
1921
const [t] = useTranslation();
@@ -44,7 +46,15 @@ const AgentPage: NextPage = () => {
4446
id="content"
4547
className="flex h-screen max-w-full flex-col items-center justify-center gap-3 px-3 pt-7 md:px-10"
4648
>
47-
<ChatWindow messages={messages} title={getAgent?.data?.name} visibleOnMobile />
49+
<ChatWindow messages={messages} title={getAgent?.data?.name} visibleOnMobile>
50+
{messages.map((message, index) => {
51+
return (
52+
<FadeIn key={`${index}-${message.type}`}>
53+
<ChatMessage message={message} />
54+
</FadeIn>
55+
);
56+
})}
57+
</ChatWindow>
4858
<div className="flex flex-row gap-2">
4959
<Button icon={<FaBackspace />} loader onClick={() => void router.push("/")}>
5060
Back

0 commit comments

Comments
 (0)