"use client"; import { useEffect } from "react"; import { useRouter } from "next/navigation"; import Link from "next/link"; import { useAuth } from "@/contexts/AuthContext"; import { ProfileCompletionForm } from "@/components/auth/profile-completion-form"; import { StandaloneShell } from "@/components/layout/standalone-shell"; // Profile completion - shared by both authentication methods (email magic link and // Google). Only reachable with an in-memory onboarding session set by // `/auth/verify` or the Google button (see `AuthContext`); there is nothing to // recover if the page is loaded directly (e.g. a refresh), since the session is // intentionally never persisted - the visitor is sent back to sign in again. export function OnboardingPageContent() { const { onboarding, isAuthenticated, isLoading } = useAuth(); const router = useRouter(); useEffect(() => { if (isLoading) return; if (isAuthenticated) { router.replace("/home"); return; } if (!onboarding) { router.replace("/"); } }, [onboarding, isAuthenticated, isLoading, router]); if (!onboarding) { return null; } return (

By creating an account, you agree to our{" "} Terms of Service {" "} and{" "} Privacy Policy

); }