Rime

AuthCard and AuthLayout

The sign-in card: a solid card on a deep field, with a logo slot, icon tile, title, footer strip and back link.

AuthLayout paints the auth field (--auth-background, --auth-floor, --auth-sky), centres its child, and takes an optional header (your brand mark, a help link) and footer (a security note). AuthCard frames sign-in, sign-up, MFA, reset and onboarding steps: a logo slot, an optional icon tile, the title (the page's h1) with an optional inline badge, the form, an optional back link and a footer strip.

Installation

npx shadcn@latest add KezLahd/rime/auth-card

Also installs: base, icon.

Usage

import { AuthCard, AuthLayout } from "@/components/shell/AuthCard";

<AuthLayout>
  <AuthCard logo={<Logo />} title="Sign in" subtitle="Use the email you signed up with.">
    …form…
  </AuthCard>
</AuthLayout>

Examples

Sign in with multi-factor authentication

A brand bar in the header, the card centred, the security note in the footer. Switch between the password, MFA code and authenticator setup steps.

MFA code step

Authenticator setup step

API

Generated from the component's TypeScript types and JSDoc (scripts/gen-ui-registry.mjs), so it always matches the source.

AuthCard

AuthCard props
PropTypeDefaultDescription
titleRequiredReactNode
subtitleReactNode
logoReactNodeYour logo or wordmark, centred above the title.
iconReactNodeIcon tile above the title (MFA screens).
badgeReactNodeA small tag beside nothing else: "Admin", "Staging". Sits above the title on one line with it.
childrenRequiredReactNode
footerReactNodeA strip under the card body: a trust line, a terms link.
width"sm" | "md" | "lg""sm"sm 440 (sign-in, MFA), md 520 (set password), lg 720 (onboarding).
back{ href: string; label: string }A way out, under the form: "Back to sign in".

AuthLayout

AuthLayout props
PropTypeDefaultDescription
childrenRequiredReactNode
headerReactNodeA bar across the top of the page: your brand mark at the left, a help link at the right.
footerReactNodeA strip at the foot of the page: a security note, legal links.
containedbooleanFill a fixed-height parent instead of the viewport (docs previews).

Theme tokens

Per-component tokens are undeclared by default, so the default shown is the fallback the CSS uses. Set one at :root (or in theme.css) to restyle every instance. Live values are read from this page, so they follow the Rime Studio.

AuthCard and AuthLayout per-component tokens
TokenDefaultLive value
--auth-inkvar(--ink-inverse)…
--auth-ink-mutedrgba(255, 255, 255, 0.78)…
--heading-casenone…
--heading-trackingvar(--tracking-display)…

System tokens it reads

AuthCard and AuthLayout system tokens
TokenDefaultLive value
--auth-backgroundtokens.css…
--auth-floortokens.css…
--auth-skytokens.css…
--brand-deeptokens.css…
--brand-filltokens.css…
--brand-gradient-softtokens.css…
--brand-inktokens.css…
--brand-linetokens.css…
--font-bodytokens.css…
--font-displaytokens.css…
--ink-brandtokens.css…
--ink-headingtokens.css…
--ink-inversetokens.css…
--ink-mutedtokens.css…
--line-brandtokens.css…
--line-softtokens.css…
--r-fulltokens.css…
--r-lgtokens.css…
--r-xltokens.css…
--shadow-auth-cardtokens.css…
--surface-solidtokens.css…
--surface-sunkentokens.css…
--text-auth-titletokens.css…
--text-captiontokens.css…
--text-microtokens.css…
--tracking-displaytokens.css…

Accessibility

  • The title is the page's h1; the layout renders the main landmark.

Do and don't

Do

  • One primary action, full width, size lg.

Don't

  • Don't put navigation inside the card beyond the back link.

For AI agents

This page as markdown, rendered from the same registry entry. Point an agent at it (or add .md to this page's URL), or at /llms.txt for the index.

Open auth-card.md