Repository navigation
Transcript: click anywhere on an edits card's header to expand or collapse it - #29699
Conversation
The edits card header toggled only from its title strip; now its padding, icon, counts and gaps toggle too, and the same holds for an agent message's line and a disclosure row's line. Inner controls keep their own click. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-d750cf10922c785efa64
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-d750cf10922c785efa64
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-d750cf10922c785efa64
|
cmux status (one comment, edited in place; each line is updated by the job that owns it) Review App of this head (app.zip, kept 1 day)
Gallery before/after for
States
Pick other states with a Passes: CI passes on CI passes on Written by web and size checks: green Shipped in:
|
|
Owned by an agent session · session |
) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-d750cf10922c785efa64
…he edits header's chevron wash Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-d750cf10922c785efa64
Bugbot needs on-demand usage enabledBugbot uses usage-based billing for this team and requires on-demand usage to be enabled. A team admin can enable on-demand usage in the Cursor dashboard. |
|
Review (subagent, correctness first): SHIP at 5674559 Follow-ups (none blocking):
|
![Fix with [code]smith](https://pr-comments-assets.blacksmith.sh/codesmith/fix-with-codesmith-light-3x.png)
Leo, on the edits card in the transcript ("± Edited MEMORY.md +1 -0"): "this thing i can't click the whole thing to expand/collapse only on the middle strip it's weird and bad"
Takes back #26704: not a revert. Its
data-interactivemark on the edits card's title moves to the whole header, which is now the control that owns the click.What changed
EditedFilesCard.tsx): the whole header is now the toggle, edge to edge. That covers its padding, the ± icon, the title, the counts, the empty middle, and the right end past the chevron. A one-file card opens and closes its diff from it, and a folded card (show: collapsed) shows or hides its rows. Before this change only the title's strip and the chevron toggled. View changes and Undo still handle their own clicks. The chevron is still the keyboard and screen-reader control.cursor: default), asclickable-cursor.test.tsrequires; the pointing hand is banned in webviews.AgentMessageRow.tsx) used to toggle only from its words and its toggle button. Its icon, the gaps and the meta now toggle too, and the old per-span handlers are gone. A disclosure row's line (DisclosureRow.tsx: received messages, agent cards, sub-session calls) now toggles from its leading padding, gaps and trailing space. The sender chip, the open-chat button, Reply and menus keep their own clicks. I checked tool rows, thoughts, Worked for, subagent groups and sent-message lines: each is already one full-width toggle, so they are unchanged.conversation/headerToggle.ts, holds the rule. A click on the header toggles unless it lands on a control of the header's own (button, link,role=button, menu item, input), comes from a portal, or ends a text selection. Headers carrydata-header-toggle, whichfoldAnchor.tsholds in place while the body folds, the same way it holds a toggle button.Edits card design reference:
design/has no transcript or edits-card spec yet.Tests
webviews/test/agent-pane-edited-head-toggle-browser.test.tsruns in real Chromium against the pane's dev entry with a stand-in daemon. For a one-file card it clicks the left padding, the icon, the counts, the empty middle, the right end past the chevron, the top inset, the bottom inset and the top-left corner. Each click must togglearia-expanded. It then checks that View changes keeps its own click. A second case checks that the hover covers the header but not while View changes is under the pointer, and that the cursor is the arrow.expanded: "false", and the header's hover background staysrgba(0, 0, 0, 0).bun teston headerToggle.test.ts, foldAnchor.test.ts, the new browser test, agent-pane-edited-calm, agent-pane-edited-card-expand, agent-pane-diff-find, transcript-gap-select-browser and clickable-cursor: 140 pass, 0 fail.vp fmt --checkis clean at head, and the lint and type check found 0 errors.Observed / Not run
cmux-ci testruns above, red at base and green at head.Changelog
Fixed: In the agent chat, clicking anywhere on an edits card's header (or a message or disclosure line) now expands or collapses it, not just the middle strip.
risk: normal (webview pointer handling in the transcript only).
Agent session: agent session
🤖 Generated with Claude Code
Need help on this PR? Tag
@codesmith-botwith what you need.Summary by cubic
Fixes the transcript's edits card so the entire header expands or collapses on click, not just the middle strip; the same full-width toggle now applies to agent message and disclosure row lines.
data-interactiveso gap selection still works and are held in place while their body folds.Written for commit 5674559. Summary will update on new commits.