"use client"; import { useActionState } from "react"; import { Button } from "@/components/ui/button"; import { Input } from "@/components/ui/input"; import { Label } from "@/components/ui/label"; import { Card, CardContent } from "@/components/ui/card"; import { createFirstUser, type CreateFirstUserState } from "@/actions/setup"; const initialState: CreateFirstUserState = {}; export function SignupForm() { const [state, action, pending] = useActionState(createFirstUser, initialState); if (state.success) { return (

Account created. You can delete the signup page now — sign in at{" "} /login .

); } return (
{state.error &&

{state.error}

}
); }