Skip to content

[front] enh: nest pod conversations and fix pod title cursor in inbox - #30223

Open
smb2268 wants to merge 8 commits into
mainfrom
sarah/inbox-pod-hierarchy
Open

[front] enh: nest pod conversations and fix pod title cursor in inbox#30223
smb2268 wants to merge 8 commits into
mainfrom
sarah/inbox-pod-hierarchy

Conversation

@smb2268

@smb2268 smb2268 commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

Description

Targeted improvements to the unread/inbox sections of the conversation sidebar (UnreadConversationsSection):

  • Pod group headers: the pod title is a static group header, not a link — it now uses cursor-default select-none (no more text I-beam suggesting interactivity) and drops its built-in bg-app-background so it sits flush on the section card. Its isSticky was removed: sticky was already inert here (an overflow-hidden ancestor between the label and the scroll viewport disables it).
  • Nested conversations: conversations grouped under a pod header are indented (pl-3), so the row and its hover background read as nested inside the pod group. Non-pod conversations stay flush; the indent also applies in multi-select mode.
  • Mark-as-read hover preview: hovering (or keyboard-focusing) a pod's "Mark as read" button highlights the whole contiguous block (header + conversations) it would clear. Pure CSS via has-[[data-mark-read=pod]:hover] / :focus-visible — no hover state in React. To support this, each pod group now has a real wrapper element (group-level motion.div + nested AnimatePresence for per-conversation exits); a side effect is that clearing a whole pod collapses the header together with its conversations instead of the header popping out. The section-level "Mark all as read" intentionally has no highlight — it felt too heavy across the whole card.
  • Spinner scoping: isLoading was a single shared flag wired to every mark-as-read button (pre-existing), so clicking one spun them all. Only the clicked button spins now, tracked per scope ("all" or the pod's spaceId) with a concurrency-safe clear (a finishing request only clears its own scope).
  • Loading-state timing: useMarkAllConversationsAsRead now awaits the pod cache revalidations (Promise.allSettled) before resolving, so the spinner holds until the refreshed data lands and the rows animate out, instead of clearing a beat early. This also applies to the same button in PodConversationsTab (the hook's only other consumer). The success toast intentionally fires before the await so feedback isn't coupled to refetch latency.

First step of a larger inbox-hierarchy cleanup (pod header vs. conversation visual treatment, possibly a clickable pod header later).

Tests

  • tsgo --noEmit on front passes; biome clean.
  • Manual check in the sidebar: pod headers show no I-beam and no grey band, grouped conversations are indented, pod-level mark-as-read hover/focus highlights the affected block, only the clicked button spins and holds until its rows animate out.

Risk

Low — UI-only change scoped to the sidebar unread sections plus a resolve-timing change in the mark-as-read hook. Worst case, the unread sections render oddly or spinners linger. Safe to rollback.

Deploy Plan

Standard front deploy.

@vercel

vercel Bot commented Aug 7, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

2 Skipped Deployments
Project Deployment Actions Updated (UTC)
playground Ignored Ignored Preview Aug 7, 2026 10:04pm
storybook Ignored Ignored Preview Aug 7, 2026 10:04pm

Request Review

@smb2268 smb2268 added the deploy-app-preview Automatically deploy preview label Aug 7, 2026
@github-actions

github-actions Bot commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

🚀 App SPA preview deployed

https://pr-30223-merge--app.preview.dust.tt

@smb2268
smb2268 force-pushed the sarah/inbox-pod-hierarchy branch from 10819c5 to c64951c Compare August 7, 2026 21:30
@smb2268
smb2268 marked this pull request as ready for review August 7, 2026 21:46

@dust-agent dust-agent Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Coding Rules LGTM \o/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

deploy-app-preview Automatically deploy preview

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant