diff --git a/src/app/[name]/(Main)/ai/AiPage.tsx b/src/app/[name]/(Main)/ai/AiPage.tsx index 90ecb4f..5031f80 100644 --- a/src/app/[name]/(Main)/ai/AiPage.tsx +++ b/src/app/[name]/(Main)/ai/AiPage.tsx @@ -8,8 +8,9 @@ import MenuItemRenderer from "@/components/listview/MenuItemRenderer"; import { toast } from "@/components/Toast"; import { extractErrorMessage } from "@/lib/func"; import { glassSurfaceFlat } from "@/lib/styles/glassSurface"; -import { Send2 } from "iconsax-react"; +import { ArrowLeft, Send2 } from "iconsax-react"; import Image from "next/image"; +import { useRouter } from "next/navigation"; import { FormEvent, useEffect, useRef, useState } from "react"; import { useTranslation } from "react-i18next"; import { useChat } from "./hooks/useAiData"; @@ -53,6 +54,7 @@ function toFood(food: ChatFood): Food { function AiPage() { const { t } = useTranslation("common", { keyPrefix: "AI" }); + const router = useRouter(); const { data: about } = useGetAbout(); const { data: profile, isSuccess } = useGetProfile(); const { mutate: chat, isPending } = useChat(); @@ -105,7 +107,11 @@ function AiPage() { return (
-

{t("Heading")}

+
+ +

{t("Heading")}

+ router.back()} /> +
{messages.length > 0 ? (