# OpportunityEmailNotesTab

## 2026-07-07 | Refinement: Gmail-style row list + drill-in thread (BUILD-2313)

**Prompted by:** Clint Howen | Designer/PO refinement of BUILD-2313

### What changed
- Layout reworked from two-pane (280px sidebar list + thread) to a Gmail-style drill-in, per direct PO/designer feedback about the drawer's width constraints: conversations render as full-width rows (name · subject · snippet · timestamp) under a slim "Client emails" header with a count badge; clicking a row swaps the panel to the full-width thread with an always-visible back control.
- Thread view uses `emailOnly` (no Chat/Email toggle, no AI hand-off) and keeps the email reply composer (To/CC/Subject + rich text).
- The reply composer is its own section pinned at the bottom of the drawer (PO decision): the thread panel is `h-[calc(100vh_-_5.5rem)]` so its bottom edge lands on the drawer's bottom edge, the email chain scrolls past the composer in the area above, and the empty draft keeps the standard 150px (grows with content; PO sizing call). The row list view hugs its content height.
- Added a 10-message long-thread fixture (`MOCK_OPPORTUNITY_EMAIL_CONVERSATIONS_LONG` / `MOCK_OPPORTUNITY_EMAIL_MESSAGES_LONG`) and a `UseCase_LongEmailChain` story demonstrating the chain scrolling past the pinned composer.
- `defaultConversationId` now means "open directly on that thread"; default is the row list.
- "Notes" confirmed as deferred to a follow-up story; the tab covers Email only.

### Why
- Resolves the first-pass open decisions (unwanted composer toggle, full-inbox list chrome) and adopts the row/drill-in pattern the PO asked for after reviewing the two-pane version against the live Kanban drawer.

### Affected tokens / files
- `packages/shadcn/src/components/ui/opportunity-email-notes-tab.tsx`
- Depends on new `emailOnly` / `compact` / `itemVariant="row"` / `showBackButton` modes in `ai-conversations` (see `ai-conversations.md`)
