Migrate hand-rolled callout boxes to the .alert component (redesign follow-up) #534
Loading…
Reference in a new issue
No description provided.
Delete branch "refactor/alert-component-migration"
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?
Follow-up flagged in LC-565: replace the hand-rolled danger / success / warning callout boxes with the shared
.alertcomponent (LC-555), so callout chrome lives in one place and themes consistently.Converted (28 boxes, 19 files)
Every simple single-message callout across admin (bridges, bots, branding, slash-commands, link-filter, outgoing-webhooks, backup-restore, bridge-avatars, settings, anti-spam), settings (page, api-tokens), enclave (branding, settings, discover, page), and the room utility pages (feeds, webhooks, email-inboxes) now reads
.alert alert-danger|success|warninginstead of an ad-hocrounded-md border border-X-border bg-X-surface px-3 py-2 text-sm ...box.The flex nuance
.alertisflex items-start gap-2.5. A single text run is one anonymous flex item (fine), but a body mixing inline<strong>/<code>with text would split into separate gapped flex items and break the sentence. So those bodies are wrapped in a single<span>to stay one flex item - the same "one message block" contract the component already expects after an icon.Deliberately left hand-rolled
space-y-1token-display panels (new webhook/bot/bridge secret, created feed/API-token URL) stack a<p>+ a block<code>; under.alert's flex they'd go horizontal.#retention-preview,space-y-2, swapped live).px-2 py-1.5 text-xs) inside the ingress / retention stats panels - intentionally quieter and smaller than a top-level alert.Scope / safety
Pure template class changes (plus
<span>wraps). No id / handler /hx-swap-oobtarget touched. Built CSS regenerates - the.alert*classes are now emitted since templates reference them (previously only the dev theme gallery + login/welcome did).Verify
just build-css-> clean.dev/cargo test --test routes_admin_bridges-> 10/10dev/cargo test --test routes_enclave-> 19/19dev/cargo test --test lc77_webhook_render_fixture-> 4/4dev/cargo test --test outgoing_webhooks-> 8/8🤖 Generated with Claude Code
https://claude.ai/code/session_011jXpZXXwpB36MvTr6JrGXN