Skip to content

Agent transcript: opening a line at the very bottom pushes the text up - #32644

Merged
teamleaderleo merged 9 commits into
feat-cmux-nextfrom
lane/expand-at-bottom
Nov 3, 2026
Merged

teamleaderleo merged 9 commits into
feat-cmux-nextfrom
lane/expand-at-bottom

Conversation

@teamleaderleo

@teamleaderleo teamleaderleo commented Nov 2, 2026 •

Copy link
Copy Markdown
Collaborator

Leo (2026-11-02): "AND NOBODY FING DID WHAT I ASKED FOR / YOU EXPAND UP WHILE YOUR SCCROLL IS AT THE VERY BOTTOM AKA YOU FING PUSH THE TEXT UP VISUALLY INSTEAD OF EXPANDING DOWN LIKE USUAL / JUST THAT CASE"

What changed

With the agent transcript scrolled to its very bottom, opening any line now keeps the bottom pinned: what opens pushes the text above it up, and the rows under it stay on their pixels. Anywhere else nothing changes: the clicked line stays put and its body grows down (#28780). Closing is unchanged.

  • The bottom stack fold (Keep transcript bottom pinned while tool folds open #29686, NEXT transcript: match ChatGPT expansion at and away from bottom #29857) took only tool and work lines (.cv-tool.is-toggle, .cv-worked, .cv-subagents). It now also takes any line that opens (opensBody in conversation/foldAnchor.ts): a closed aria-expanded control, a header toggle's own button (the edits card), or a closed <summary>. That covers a long prompt's Show more, the edits card's header, an agent message line and the like. Closing them keeps the established row anchor and its room.
  • "At the bottom" stays base's: the offset at (or within 4px of) the end of a transcript that scrolls.
  • Gallery scene agent-pane.expand-at-bottom (variants shipped: "Ran 2 commands" at the bottom; prompt: a long prompt's Show more at the bottom).
  • Two older tests asserted that a message opened at the latest row stays on its pixel. They now assert Leo's rule (it pushes the text up, the view stays at the end, and closing keeps the line): received-message-fold-browser.test.ts, incoming-message-disclosure-browser.test.ts. The away-from-the-end received-message case gets two more turns under it, so it is clearly off the end. agent-pane-fold-keeps-place.test.ts's opening case now starts 48px above the end.
  • Spec: leo-workspace design/chat-transcript.md, "Bottom expansion" (merged).

Tests

cmux-ci test -- bun test test/transcript-expand-at-bottom.test.ts (Chromium, fast-checks runner):

  • Without the fix (the opensBody branch removed): (fail) at the very bottom, a long prompt's Show more opens it by pushing the text above up. The bottom moved 386px, so it expanded down.
  • With it: 3 of 3 pass. "Ran 2 commands" at the bottom: still at the end, the last row's foot unchanged, the line pushed up. Show more at the bottom: same. An earlier turn's line away from the bottom: on its pixel, offset unchanged, the chat grows down.
  • At ba0801f/bbd555b3: foldAnchor (48), transcript-expand-at-bottom (3), transcript-fold-anchor-browser (16), agent-pane-fold-keeps-place (2), agent-pane-show-less-keeps-place (2), received-message-fold-browser (4) and incoming-message-disclosure-browser (6) all pass.
  • bun run check: exit 0 at ba0801f.

Observed / Not run

  • Observed: the runs above on the fast-checks runner (Chromium).
  • Not run: a NEXT DEV build in WKWebView. The "Ran 2 commands" case already pushed up on base in Chromium, so if Leo's build still expands down there, the cause is WebKit-specific or a state this scene doesn't reach.

Changelog

  • Fixed: Opening a collapsed line in an agent chat scrolled to the very bottom pushes the text above up, instead of expanding down.

Agent session: agent session

🤖 Generated with Claude Code

…p (red)

Leo (2026-11-02): "YOU EXPAND UP WHILE YOUR SCCROLL IS AT THE VERY BOTTOM AKA YOU FUCKING PUSH THE TEXT UP VISUALLY INSTEAD OF EXPANDING DOWN LIKE USUAL / JUST THAT CASE"

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-96b469d95133ef2bbaa4
@github-actions

github-actions Bot commented Nov 2, 2026 •

Copy link
Copy Markdown
Contributor

cmux status (one comment, edited in place; each line is updated by the job that owns it)

Review bbd555b: HQ feed card · gallery before/after runs · checks

App of this head (app.zip, kept 1 day)

gh workflow run reload-build.yml -R manaflow-ai/cmux --ref feat-cmux-next -f tag=pr32644 -f ref=lane/expand-at-bottom -f platform=macos -f backend_mode=local

Gallery before/after for 8ecfbf5: 16 states rendered, 0 images differ, 1900 more touched states not rendered. Images are in the run's artifact, not on this public PR; the independent review of this head reads them on its own, so the PR needs no hand-made screenshots of these states.

gh run download 41566113203 -R manaflow-ai/cmux -n gallery-advisory-32644-8ecfbf52060020e0ea3ca2f5d664a4647b46d363 (then read gallery-review.json)

States
State Theme Status Diff Picked by
agent-pane.chat-width/standard Apple System Colors Light unchanged 0% own App.tsx
agent-pane.chat-width/standard Apple System Colors unchanged 0% own App.tsx
agent-pane.chat-width/wide Apple System Colors Light unchanged 0% own App.tsx
agent-pane.chat-width/wide Apple System Colors unchanged 0% own App.tsx
agent-pane.chat-width/wide-blocks Apple System Colors Light unchanged 0% own App.tsx
agent-pane.chat-width/wide-blocks Apple System Colors unchanged 0% own App.tsx
agent-pane.composer-edge/short-edge Apple System Colors Light unchanged 0% own App.tsx
agent-pane.composer-edge/short-edge Apple System Colors unchanged 0% own App.tsx
agent-pane.composer-edge/wide-edge Apple System Colors Light unchanged 0% own App.tsx
agent-pane.composer-edge/wide-edge Apple System Colors unchanged 0% own App.tsx
agent-pane.composer-edge/no-edge Apple System Colors Light unchanged 0% own App.tsx
agent-pane.composer-edge/no-edge Apple System Colors unchanged 0% own App.tsx
agent-pane.composer-floats/scrolled-to-end Apple System Colors Light unchanged 0% own App.tsx
agent-pane.composer-floats/scrolled-to-end Apple System Colors unchanged 0% own App.tsx
agent-pane.composer-floats/composer-grown Apple System Colors Light unchanged 0% own App.tsx
agent-pane.composer-floats/composer-grown Apple System Colors unchanged 0% own App.tsx
agent-pane.composer-rest-gap/gap-40 Apple System Colors Light unchanged 0% own App.tsx
agent-pane.composer-rest-gap/gap-40 Apple System Colors unchanged 0% own App.tsx
agent-pane.composer-rest-gap/gap-56 Apple System Colors Light unchanged 0% own App.tsx
agent-pane.composer-rest-gap/gap-56 Apple System Colors unchanged 0% own App.tsx
agent-pane.composer-rest-gap/gap-72 Apple System Colors Light unchanged 0% own App.tsx
agent-pane.composer-rest-gap/gap-72 Apple System Colors unchanged 0% own App.tsx
agent-pane.continuation-spacing/shipped Apple System Colors Light unchanged 0% own App.tsx
agent-pane.continuation-spacing/shipped Apple System Colors unchanged 0% own App.tsx
agent-pane.continuation-spacing/two-thirds Apple System Colors Light unchanged 0% own App.tsx
agent-pane.continuation-spacing/two-thirds Apple System Colors unchanged 0% own App.tsx
agent-pane.continuation-spacing/half-tucked Apple System Colors Light unchanged 0% own App.tsx
agent-pane.continuation-spacing/half-tucked Apple System Colors unchanged 0% own App.tsx
agent-pane.continuation-spacing/before Apple System Colors Light unchanged 0% own App.tsx
agent-pane.continuation-spacing/before Apple System Colors unchanged 0% own App.tsx
agent-pane.copy-controls/output Apple System Colors Light unchanged 0% own App.tsx
agent-pane.copy-controls/output Apple System Colors unchanged 0% own App.tsx

Pick other states with a Gallery: entry.id, entry.id/variant line in the PR body.

Passes: CI passes on 8ecfbf5206.

CI passes on 8ecfbf5206 (run 41566113275 attempt 1).

Written by scripts/ci/classify_failures.py (ci-failure-attribution.yml); signatures are its SIGNATURES table. A machine verdict is the runner's fault, not this PR's; yours means the failing file is one this PR changes, also red on main that main's latest full suite fails the same way, seen on other PRs that it failed on another pull request's run lately.

web and size checks: green

Shipped in:

Leo (2026-11-02): "YOU EXPAND UP WHILE YOUR SCCROLL IS AT THE VERY BOTTOM AKA YOU FUCKING PUSH THE TEXT UP VISUALLY INSTEAD OF EXPANDING DOWN LIKE USUAL / JUST THAT CASE"

The bottom-pinned stack fold (#29686, #29857) took only tool and work
disclosures. Any line that opens there (an edits card's header, a cut
row's Show more, a summary) now takes it too, so what opens pushes the
text above up and the view stays at its end. Closing, and opening away
from the bottom, are unchanged (#28780).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-96b469d95133ef2bbaa4
@github-actions github-actions Bot added the risk:normal Risk tier (docs/ci/risk-tiers.md) label Nov 2, 2026
…ttom for an opened line

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-96b469d95133ef2bbaa4
@cursor

cursor Bot commented Nov 2, 2026

Copy link
Copy Markdown

Bugbot needs on-demand usage enabled

Bugbot 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.

…e-safe opensBody; keep-place test off the bottom

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-96b469d95133ef2bbaa4
… pushes the text up

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-96b469d95133ef2bbaa4
@cursor

cursor Bot commented Nov 2, 2026

Copy link
Copy Markdown

Bugbot needs on-demand usage enabled

Bugbot 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.

@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Review (subagent claude-opus-5-5 medium): SHIP at ab6d39e

Checked: the state is read before a toggle flips (capture-phase click, and holdHeader before setOpen); Show more's double stack on row and bubble resolves to one hold; edits header reads its chevron and skips menu buttons; followingRef is cleared synchronously on wheel, keys, drag and a glide's cancel, so a mid-transcript open does not push up; closing is unchanged apart from the kind of room a following tool close keeps.

The review read e3a351a; the commits since (to this head) add only a test (follow-up 1 below, red without the fix) and formatter output; no source change.

Follow-ups: (1) red/green browser case for a non-tool opener at the bottom (done in b20f58b); (2) opensBody reads a header's first [aria-expanded] descendant; prefer its own control via aria-controls; (3) look at a body taller than the view opened at the bottom in the gallery.

@blacksmith-sh

blacksmith-sh Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

Found 6 test failures on Blacksmith runners:

Failures

Test View Logs
test/agent-pane-queue-row-click.test.ts/agent-pane-queue-row-click.test View Logs
test/agent-pane-queue-row-click.test.ts/agent-pane-queue-row-click.test View Logs
test/model-picker-round-rail.test.ts/model-picker-round-rail.test View Logs
test/model-picker-round-rail.test.ts/model-picker-round-rail.test View Logs
test/transcript-upward-anchor.test.ts/transcript-upward-anchor.test View Logs
test/transcript-upward-anchor.test.ts/transcript-upward-anchor.test View Logs

Fix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

…or opening at the latest row follow Leo's 2026-11-02 rule

A programmatic scroll leaves the view following while it is mid-transcript,
so following alone pushed up an open away from the end.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-96b469d95133ef2bbaa4
@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Review (codex gpt-6.1-sol high, sweep, via the review router; full diff from merge base 11e5aea to this head): SHIP at bbd555b

No P1/P2 findings.

@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Review (subagent claude-opus-5-5 medium): SHIP at bbd555b

Checked: the at-bottom check is base's atFoldBottom again (a programmatic scroll could leave following true mid-transcript, so the followingRef widening was dropped); the opensBody branch and reopen room; the Show more case is a real red/green (without the branch the bottom moved 386px); the two updated tests assert Leo's rule, and the away-from-the-end case is stricter (asserts it is off the end). Closing is unchanged.

Follow-ups: (1) give the gallery's prompt variant its own play that only scrolls to the bottom; (2) opensBody should read a header's own control, not its first [aria-expanded] descendant; (3) check in the gallery what happens when a body taller than the view opens at the bottom.

@cursor

cursor Bot commented Nov 3, 2026

Copy link
Copy Markdown

Bugbot needs on-demand usage enabled

Bugbot 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.

@cmux-bot
cmux-bot Bot temporarily deployed to ci-routing-agent November 3, 2026 02:26 Inactive
@cmux-bot
cmux-bot Bot temporarily deployed to ci-routing-agent November 3, 2026 02:26 Inactive
@teamleaderleo
teamleaderleo merged commit 18d4c70 into feat-cmux-next Nov 3, 2026
159 of 161 checks passed
@teamleaderleo
teamleaderleo deleted the lane/expand-at-bottom branch November 3, 2026 02:34
@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Review (codex gpt-6.1-sol high, sweep, via the review router; full diff from merge base 06ca249 to this head): SHIP at 8ecfbf5

[P2] [follow-up] webviews/src/agent-session/acpmux/conversation/foldAnchor.ts:54 - opensBody ignores height-changing toggles represented by aria-pressed (such as Markdown “Raw”/Wrap) and .cv-diagram__toggle, even though FOLD_TOGGLE treats them as disclosures; opening them at the physical bottom still expands downward instead of pinning the bottom - detect their opening state (and add explicit state to diagram toggles) and cover them with bottom-fold tests.

cmux-bot Bot pushed a commit that referenced this pull request Nov 3, 2026
…tom (#32644 fix forward) (#33135)

* base red: the fold-stream trace starts off the very bottom (#32644 fix forward)

"received card folds preserve painted row-box adjacency while streaming"
scrolled the received card to the top of the view, which in the last turns
of the fixture is the physical end. Since #32644 (Leo, 2026-11-02: "YOU
EXPAND UP WHILE YOUR SCCROLL IS AT THE VERY BOTTOM ... JUST THAT CASE"),
opening a line there pushes the text above it up: the card's top moves
1164px up on purpose, the oracle counts that as drift and missing anchors,
and the following close lands past the end for three blank frames. #32644
moved the other keep-place tests off the bottom; this one was missed.

Start the trace 48px up from the end, as agent-pane-fold-keeps-place does,
so it again checks a fold that keeps its place while the reply streams.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-2f629b93d5a20c58e6f8

* test(transcript): upward-anchor fold trace starts off the end deterministically

Wait for fonts before placing the card, and never move the start further
down than where scrollIntoView put it, so the card stays in view whether
or not scrollIntoView landed on the physical end.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-2f629b93d5a20c58e6f8

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
teamleaderleo added a commit that referenced this pull request Nov 3, 2026
…ay rise; row grammar opens before its first paint (#33784)

#32644 made a line opened at the very bottom push the text above it up (Leo,
2026-11-02: "YOU EXPAND UP WHILE YOUR SCCROLL IS AT THE VERY BOTTOM AKA YOU
... PUSH THE TEXT UP VISUALLY INSTEAD OF EXPANDING DOWN LIKE USUAL / JUST THAT
CASE"). The box tracker still scored that designed rise as layout shift, so
agent-pair-note#held-list and composer#queued-from-agent-open went red at
0.0059 and ~0.03 against 0. A box before the target that moves straight up is
now exempt while the target's row carries data-bottom-fold (the transcript's
own marker for that fold), mirroring the push-down exemption; anywhere else a
rising row still counts.

transcript-row-grammar#open clicked its toggles in a layout effect, but the
rows subscribe to the disclosure store in a passive effect that may run after
the first paint: some runs painted the rows closed, then open (CLS 0.3295).
Remounting the rows from that layout effect reads the store before paint.


Agent-Session: https://cmux.com/deeplink/agent?id=aid-3bab30503f0b9a7059e5

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
teamleaderleo added a commit that referenced this pull request Nov 4, 2026
… clicked step (carries #32820) (#33987)

* test(agent pane fold): open the "Received N messages" row before its lines

messages" row, so the fanout-infra line the fold test waits for is not
drawn until that row opens. The test and the gallery entry's plays now
open it first.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-2f629b93d5a20c58e6f8

* gallery: B/C/D disclosure variants keep the push-up from opening the waiting group at the end

With the "Received 3 messages" row opened first, the plays render
again (they timed out on base). Opening the waiting group at the
transcript's end then pushes the rows above up 66px (the pinned end,
Leo 2026-11-02), measured 0.0777 in gallery health run 41563279796,
the same kind of shift a-shipped-open already carries.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-2f629b93d5a20c58e6f8

* gallery: a-shipped-open carries the waiting group's push-up too

Gallery health run 41564747382 measured a-shipped-open at 0.2829: the
waiting group opening at the end (0.0777, as in B/C/D) plus the report
opening (0.2051). On base the play times out, so its row of 0.16476
predates #32720.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-2f629b93d5a20c58e6f8

* gallery: incoming-message-disclosure plays open each fold as its own clicked step

The plays opened the "Received 3 messages" row and the waiting group with
raw element clicks in one task, then waited. At the transcript's end each
opening pushes the rows above up by design (#32644), and the box-shift gate
exempts that only while the step's own target sits in the row marked
data-bottom-fold (#33784). A raw click is no step and has no target, so the
push-up landed in the following wait, scored as shift (c-line-count 0.1328,
user-1 and assistant-2 moving -21.9px). Each opening is now ctx.click, settled
before the next, and fanout-infra's report opens the same way.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-3bab30503f0b9a7059e5

* gallery health: incoming-message-disclosure shift rows back to what the plays measure

With each opening its own clicked step, gallery health run 41665103842
measured b-received-wording, c-line-count and d-sender-only at 0 (back to
base's 0, from #32820's 0.0777) and a-shipped-open at 0.16622/0.16639
(0.1664, from #32820's 0.2829; base's 0.16476 predates #32720's received row,
whose opening now lands in the same play). The report line is waited for
before it is clicked.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-3bab30503f0b9a7059e5

* gallery health: keep base's other shift rows; only the four disclosure rows change

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-3bab30503f0b9a7059e5

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: cmux-bot[bot] <348531757+cmux-bot[bot]@users.noreply.github.com>

This branch was previously deployed

1 inactive deployment
ci-routing-agent — 8ecfbf52 Deployed Nov 3, 2026 by cmux-bot[bot] via wait for same-key tree publisher #103528
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk:normal Risk tier (docs/ci/risk-tiers.md)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant