import type { Metadata } from "next"; import { createListAction } from "@/app/actions/lists"; import { BookmarkIcon } from "@/components/icons"; import { ListForm } from "@/components/list-form"; import { requireViewer } from "@/lib/auth"; import { listOwnersFor } from "@/lib/lists"; export const metadata: Metadata = { title: "New list" }; export default async function NewListPage({ searchParams }: PageProps<"/lists/new">) { const viewer = await requireViewer("/lists/new"); const owners = (await listOwnersFor(viewer)).map((o) => o.username); const wanted = String((await searchParams).owner ?? "").toLowerCase(); return (

Create a list

Gather repositories to find them again or share them. Add one with the Save key on its page.

o.toLowerCase() === wanted) ?? viewer.username} />
); }