SPB Git forge

spb/polyllm

Public
15commits 1branches 0releases
2.2 MBsize
maindefault branch
13 days agolast push
TypeScript 97.4% SQL 1% JavaScript 0.9% CSS 0.6%
836 B · 24 lines tsx
Raw Blame History
1import type { Metadata } from "next";2import { LoginForm } from "../_components/login-form";3import { safeNext } from "../_components/auth-errors";45export const metadata: Metadata = {6  title: "Sign in",7  description: "Sign in to your PolyLLM workspace.",8  robots: { index: false, follow: true },9};1011type Params = Record<string, string | string[] | undefined>;1213function first(v: string | string[] | undefined): string | undefined {14  return Array.isArray(v) ? v[0] : v;15}1617export default async function LoginPage({ searchParams }: { searchParams: Promise<Params> }) {18  const params = await searchParams;19  const next = safeNext(params.next);20  const raw = first(params.notice);21  const notice = raw === "reset" || raw === "verified" || raw === "signed-out" ? raw : undefined;22  return <LoginForm next={next} notice={notice} />;23}24