diff --git a/app/[lang]/page.tsx b/app/[lang]/page.tsx index c446eb3..69e2a96 100644 --- a/app/[lang]/page.tsx +++ b/app/[lang]/page.tsx @@ -28,6 +28,8 @@ export default function Home() { } = useDiagram() const router = useRouter() const pathname = usePathname() + // Extract current language from pathname (e.g., "/zh/about" → "zh") + const currentLang = (pathname.split("/")[1] || i18n.defaultLocale) as Locale const [isMobile, setIsMobile] = useState(false) const [isChatVisible, setIsChatVisible] = useState(true) const [drawioUi, setDrawioUi] = useState<"min" | "sketch">("min") @@ -207,7 +209,7 @@ export default function Home() {
{isLoaded ? ( ) : (