From 9cdd9fddedf13e50815a152e3dbdabc56e27eed4 Mon Sep 17 00:00:00 2001 From: cupadev-admin Date: Mon, 9 Mar 2026 14:32:12 +0000 Subject: [PATCH] fix: apply designer agent improvements to src/app/page.tsx --- src/app/page.tsx | 43 +++++++++++++++---------------------------- 1 file changed, 15 insertions(+), 28 deletions(-) diff --git a/src/app/page.tsx b/src/app/page.tsx index ed711b0..910b29e 100644 --- a/src/app/page.tsx +++ b/src/app/page.tsx @@ -1,31 +1,18 @@ -"use client"; - -import { useEffect } from "react"; -import { useRouter } from "next/navigation"; -import { useAuthStore } from "@/store/authStore"; - -export default function Home() { - const router = useRouter(); - const { isAuthenticated, checkAuth } = useAuthStore(); - - useEffect(() => { - checkAuth(); - }, [checkAuth]); - - useEffect(() => { - if (isAuthenticated) { - router.replace("/dashboard"); - } else { - router.replace("/login"); - } - }, [isAuthenticated, router]); +import PublicLayout from '@/components/public/PublicLayout' +import LandingHero from '@/components/public/landing/LandingHero' +import LandingFeatures from '@/components/public/landing/LandingFeatures' +import LandingStats from '@/components/public/landing/LandingStats' +import LandingRecentPosts from '@/components/public/landing/LandingRecentPosts' +import LandingCTA from '@/components/public/landing/LandingCTA' +export default function HomePage() { return ( -
-
-
-

Loading...

-
-
- ); + + + + + + + + ) }