feat(home): fix raw-markdown previews, rebalance dashboard grid, de-emphasize empty cards (LC-703) #669
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/LC-703-home-dashboard-redesign"
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?
What
Redesigns the Home "Catch up" dashboard: fixes raw markdown leaking into message previews, rebalances the card grid, and de-emphasizes empty cards so populated ones lead.
Bug fix: raw markdown in previews
The Unread-channels card showed
[📝 Call transcript saved](/transcripts/49)literally, becauseroutes::home::preview_offlattened and truncated the raw body. Same "simplified render path drops markdown" class fixed earlier in the timeline and Saved views, on the dashboard's own path.New shared helper
views::markdown::plain_line(body, max)runs the real pulldown-cmark parser and emits clean plain text:[label](url)->label, emphasis/heading/code markers dropped, whitespace collapsed, truncated with an ellipsis. Catch-up and Threads previews use it. The preview stays plain text (not a nested anchor - the whole row is already a deep-link to a different target). A body with no text (attachment/image/GIF only) falls back to a muted "📎 Attachment" label (new i18n key, en+es) instead of blank.Deferred: per-type icons ("🖼 Image" vs "📎 File") need attachment metadata in the inbox/thread queries (data-layer change); a single generic label is used for now.
Layout and empty cards
sm:grid-cols-2 xl:grid-cols-3grid (five cards stranded as an asymmetric 3+2 with big gaps) with an authored.lc-home-grid(auto-fill, minmax, align-items:start) so cards size to content and flow into balanced columns at any width, in a wider container.order, so the cards carrying unread content lead.<time datetime>fromcreated_at) next to the count pill and rendered preview.tailwind-built.cssis gitignored).Deferred: AI "catch me up" tie-in
The optional workspace-wide one-click AI summary is a new cross-room feature (the existing summarizer is per-room,
routes::summary, and gated by the LC-702 AI audience), tracked as a follow-up rather than bundled here.Testing
plain_lineunit tests: markdown link -> label, formatting stripped, single-line collapse, truncation, empty-body fallback.last_visiteddashboard render test kept green.just test(195 binaries, 1640 tests), clippy standalone + saas,cargo fmt --check, i18n en/es parity.Note on visual check: this is an SSO-gated web app, so an authenticated live screenshot needs a seeded DB + Bunyip login. Verified instead via Askama's compile-time template check, the authored token-only CSS, and the integration render test.
Closes LC-703.
🤖 Generated with Claude Code
https://claude.ai/code/session_016ufqbuN7mjyt4ms5NEygMy