feat(ui): shared component vocabulary (LC-195) #241
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/lc-195-components"
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?
Establish a small, token-based component vocabulary defined once (instead of per-template class soup) and adopt it in a representative slice. Broad rollout across every remaining control continues incrementally.
Vocabulary (
assets/tailwind.css@layer components, all@applyon LC-190 tokens).btnbase +.btn-primary/.btn-secondary/.btn-ghost/.btn-dangercolor modifiers +.btn-sm; disabled state baked in. Used composed:class="btn btn-primary"..input(input/select/textarea) +.input-error..card..modal-backdrop/.modal-paneldialog shell..toast.Because they're built on the tokens, the components recolor with light/dark/high-contrast automatically.
Adopted (the demonstrated slice)
auth/{login,register,forgot,reset}: form ->card, text inputs ->input, submit ->btn btn-primary.modal-backdrop+modal-panel.Remaining LC-195 (continuing)
Adopt
btn/inputacross the rest (room composer, settings, admin, enclave, sidebar menus), and wire.toastinto the outbox banner / flash messages / notify bus. These are incremental per-element swaps on the now-defined vocabulary.Verification
build-cssconfirms@applyresolves every token utility (a missing one errors at build); emitted component classes verified.just test+just test-saasgreen (theroutes_uploadsconcurrent-load failure is the documented flake; passes isolated).cargo fmt --allclean. No test asserts on the changed auth/modal classes.Define a small, token-based component layer once instead of per-template class soup, and adopt it in a representative slice (auth forms + the standalone modals). Broad rollout across every remaining button/input/toast continues incrementally. - assets/tailwind.css @layer components: `.btn` (base) + `.btn-primary/secondary/ghost/danger` color modifiers + `.btn-sm` + disabled state; `.input` (+ `.input-error`) for input/select/textarea; `.card`; `.modal-backdrop` / `.modal-panel` dialog shell; `.toast`. All built with @apply on the LC-190 tokens, so components recolor with the theme. Used composed in markup, e.g. `class="btn btn-primary"`. - Adopted: auth/{login,register,forgot,reset} (form -> card, inputs -> input, submit -> btn btn-primary), and the poll / scheduled / reminder modal shells -> modal-backdrop + modal-panel. Remaining LC-195 (continuing): adopt btn/input/toast across the rest of the templates (room composer, settings, admin, enclave, sidebar menus), and wire .toast into the outbox banner / flash / notify bus. build-css verified the @apply resolves every token utility; emitted classes confirmed. just test + just test-saas green (routes_uploads concurrent-load flake excluded); cargo fmt --all clean; i18n_catalog gate unaffected. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>