feat(ui): DESIGN.md design contract, font tokens, reduced motion, radius sweep #52
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "feat/design-contract"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Groundwork for a sweatshop-style design system (PR A of 2; PR B adds the theme registry and picker with Nova as the default). No visual redesign and no new dependencies.
What
DESIGN.md(new, repo root; linked from AGENTS.md). Adapted from sweatshop's contract:rounded-sm|md|lg|xl, never barerounded;rounded-fullonly for pills, dots and avatars; the composer and user bubble keeprounded-2xlas the one noted exception);info/success/warning/destructive, words viaStatusPill). This one is tansweat-specific and matches what the code already does.It also lists the token set, including the
success/warning/infotrio andbrand-claude.styles.css:--font-sans/--font-monotokens, both system stacks (no web fonts);htmlusesfont-sans, and markdowncodeusesvar(--font-mono).prefers-reduced-motionblock, so every spinner, pulse and transition honours the OS setting without per-site handling.Radius sweep (9 component files, outside vendored
components/ui/): barerounded15 → 0.rounded-sm(9).preboxes and hover rows becamerounded-md(35 → 41).lg10,2xl2,full31).lib/design-contract.test.ts(new): a guard test. It scans app TSX (notui/) and fails withfile:lineon raw palette colours, hex/oklch in class strings, or barerounded.Verification
pnpm typecheckandpnpm testpass (1336).main, and it failed listing all 15 bareroundedsites with file:line. It passes on this branch.html{font-family:ui-sans-serif,…}, and.rounded-sm{border-radius:calc(var(--radius)*.6)}.htmlresolves to the sans stack.sm).animate-spinelement's animation drops from1sto1e-05s.Visible changes
preboxes and hover rows (4px → 6px or 8px).codegains Consolas and Liberation Mono as fallbacks; it resolves to the same system monospace on macOS and most Linux setups.Follow-up for PR B
.markdown-prosecode/preradii instyles.cssare still fixed rem values; they move tovar(--radius-*)with the theme work.