Sign-in Form

View as Markdown

Sign in, accept an invitation and manage sessions.

Sign in to Northwind

Use your work email.

When to use

Sign in, accept an invitation and manage sessions. Use Account Menu instead when the person is already signed in.

Usage

import { AuthScreen, arrivalOf } from "./ui/uicontext/components/Session.ts"
export const SignInPage = <M>(h: Html.H<M>, link: { readonly join?: { readonly id: string; readonly code: string } }, claimed: boolean) =>	AuthScreen(h, {		props: {			arrival: arrivalOf(link),			claimed,			methods: ["password", "link"],		},	})

Examples

Joining from an invitation

The invitation is read first: the email it was sent to fills the form.

Join Northwind

Ana invited you. Make your account to get in.

API reference

Props

AuthScreenNoDeps props
NameTypeDescription
arrivalrequiredArrival—
claimedrequiredboolean—
copyAuthCopy—
tone"accent" | "neutral"The submit button: the accent (default), or solid neutral for apps that keep color for status
pathsAuthPathOverridesThis screen's session routes, over the ones a component above provides with authPathsLayer
methodsSignInMethod[]How people may sign in, the first shown first; a password only by default

Installation

pnpm dlx shadcn@latest add checkfu/uicontext/sign-in-form

Source