Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

11 — Design System Mapping (Auth Module)

Auth module → Material 3 / Flutter / token mapping, extending 00-shared/04. Every color, type, spacing, elevation, radius, icon, motion reference traces to 00-shared/02_Design_Tokens.md.


1. Theme recipes (module)

ScreensThemeException
Pre-auth (login/register/verify/reset)surface, primaryemphasis: brand primaryContainer; input fill surfaceVariant
Security screens (authed)standard shelldestructive = error
2FA QR cardsurfaceContainerHighdark: QR contrast ensured (inverseSurface)

2. Widget → token

ComponentM3 / FlutterTokensElevRadius
Login cardCardsurfaceContainerLow, outlineVariant bordere-1r-lg
Populated text fieldTextFormFieldfill surfaceVariant, border outline, focus primaryr-md
CTA Log inFilledButtonprimary/onPrimaryr-md
Secondary CTATextButtonprimary, underline on hover
Register CTAFilledButtonprimaryr-md
Forgot/resetOutlinedButtonoutline/onSurfacer-md
TOTP boxesFilledButton-like boxesbox surfaceVariant, focus primaryContainerr-md
Error chipAppBanner/inlineerrorContainer/onErrorContainerr-sm
Offline bannerAppOfflineBannertertiaryContainere-1
Sessions cardAppCardsurfaceContainerLowe-1r-lg
Current-device highlightAppCard tonalprimaryContainere-1r-lg
API key ringAppCardsurfaceContainerLow, secret monor-lg
Secret revealAppCardtertiaryContainer bg (warning-kind)e-2r-lg
Dialogs/sheetsAppDialog/AppBottomSheetsurfaceContainerHighe-4/e-5r-lg/r-xl
FAB (api-keys)FloatingActionButtonprimaryContainere-3r-full
SnackbarSnackBarinverseSurfacee-5r-md

3. Typography mapping

TokenScreen element
headlineMediumscreen titles (Welcome/Security hub headings)
titleLargecreate-key card, dialog titles
titleMediumsession rows, key rows, section headers
bodyMediumlabels, helper lines
bodySmall"created/last used", disclaimer, hints
labelLargebuttons, tabs (Security tabs)
monotoken/secret/auto-keys sk… prefix, TOTP digits option

Numerals (timestamps, key counts) use FontFeature.tabularFigures().

4. Iconography

Material Symbols outlined; module map: login/mail, lock, password, fingerprint, shield, devices, key, content_copy, logout, refresh, warning, check_circle.

5. Motion tokens (values 00-shared/02 §6)

PurposeTokenApplied to
Form submit→resultm-baseswap to success/error
Route transitionsm-basestack push/pop
List exit on revokem-baseremoval
Totp errorm-fast+shake
Badge popm-fast2FA on/API-key count
Hero QRm-slow2FA QR scale-in (forward)

Rules: reduced-motion substitutes fades/instants (08 §4).

6. Contrast & dark parity

  • All text passes 4.5:1; interactive chrome 3:1.
  • Dark: chromatic roles TBD by designer (00-shared/02 §1.4); QR on inverseSurface.
  • No sole-color status; 2FA off/on uses badge + icon (09 §9).

7. Breakpoint behaviour

ClassPre-authSecurity
phone <600single columnlists full width, detail pushed
600–839centered cardmaster-detail
≥1200centered + max width 480master-detail breaks, hover rings