From 5d80b60247983055f1b0795c3313bd71bda9b467 Mon Sep 17 00:00:00 2001 From: Harkamal Randhawa Date: Sun, 24 May 2026 05:01:54 -0600 Subject: [PATCH] Keep landing page public for signed-in users. Remove the home-page auto-redirect so `/` stays a marketing page while app entry and onboarding gates remain unchanged. --- app/page.tsx | 20 +++------------ components/layout/landing-hero-actions.tsx | 30 ++++++++++++++++++++++ components/layout/logged-in-redirect.tsx | 13 ---------- 3 files changed, 34 insertions(+), 29 deletions(-) create mode 100644 components/layout/landing-hero-actions.tsx delete mode 100644 components/layout/logged-in-redirect.tsx diff --git a/app/page.tsx b/app/page.tsx index ceea821..3db636d 100644 --- a/app/page.tsx +++ b/app/page.tsx @@ -1,10 +1,8 @@ -import Link from "next/link"; import { Suspense } from "react"; import { PixelAvatar } from "@/components/avatar/pixel-avatar"; -import { LoggedInRedirect } from "@/components/layout/logged-in-redirect"; +import { LandingHeroActions } from "@/components/layout/landing-hero-actions"; import { SiteFooter, SiteHeader } from "@/components/layout/site-header"; -import { Button } from "@/components/ui/button"; import { Card, CardContent, @@ -12,15 +10,10 @@ import { CardHeader, CardTitle, } from "@/components/ui/card"; -import { routes } from "@/lib/routes"; export default function Home() { return (
- - - -
@@ -37,14 +30,9 @@ export default function Home() { into a simple game. Keep streaks alive, take your once-per-day quiz, and watch your pet change with you.

-
- - -
+ + +
diff --git a/components/layout/landing-hero-actions.tsx b/components/layout/landing-hero-actions.tsx new file mode 100644 index 0000000..61bf497 --- /dev/null +++ b/components/layout/landing-hero-actions.tsx @@ -0,0 +1,30 @@ +import Link from "next/link"; + +import { Button } from "@/components/ui/button"; +import { getSessionUser } from "@/lib/auth-helpers"; +import { routes } from "@/lib/routes"; + +export async function LandingHeroActions() { + const user = await getSessionUser(); + + if (user) { + return ( +
+ +
+ ); + } + + return ( +
+ + +
+ ); +} diff --git a/components/layout/logged-in-redirect.tsx b/components/layout/logged-in-redirect.tsx deleted file mode 100644 index ca07c5f..0000000 --- a/components/layout/logged-in-redirect.tsx +++ /dev/null @@ -1,13 +0,0 @@ -import { redirect } from "next/navigation"; - -import { getOnboardingRedirectPath, getSessionUser } from "@/lib/auth-helpers"; - -export async function LoggedInRedirect() { - const user = await getSessionUser(); - - if (user) { - redirect(await getOnboardingRedirectPath()); - } - - return null; -}