Sign-in

Sign in, accept an invitation and manage sessions.

Sign in to Northwind

Use your work email.

Installation

pnpm dlx shadcn@latest add checkfu/uicontext/session

Usage

import { AuthScreen, arrivalOf } from "./ui/uicontext/components/kit/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

Source