import type { Metadata } from "next"; import Link from "next/link"; import { redirect } from "next/navigation"; import { ActionForm, SubmitButton } from "@/components/forms"; import { PageHeader, Tag } from "@/components/status"; import { Alert, AlertDescription, AlertTitle } from "@/components/ui/alert"; import { Card, CardContent, CardDescription, CardHeader, CardTitle } from "@/components/ui/card"; import { Input } from "@/components/ui/input"; import { api, getMe, isModerator, unwrap } from "@/lib/api"; import { linkAccount, signOutComputers } from "./actions"; import { ChallengeCard } from "./challenge-card"; import { LinkCard } from "./link-card"; export const metadata: Metadata = { title: "Account" }; export default async function Account({ searchParams }: { searchParams: Promise<{ welcome?: string }> }) { const me = await getMe(); if (!me) redirect("/signin?next=/account"); const account = unwrap(await api.account.get()); const { person, links, challenges, computers } = account; const welcome = (await searchParams).welcome !== undefined; return (
No IMVU accounts linked yet.
)}You've linked as many IMVU accounts as you can ({person.linkCap}). Ask a moderator if you need more.
)}Other people can't see which IMVU accounts are yours. Age-verified IMVU accounts (or with Access Pass) can see adult community products; each account is checked on its own.
{computers > 0 ? `Signed in on ${computers} computer${computers === 1 ? "" : "s"}.` : "Not signed in on any computer yet."}{" "} To sign T5DE in, it shows a code to enter at{" "} /device .
{computers > 0 && (