ui: drop the ctrl+r transcript browser - #127
Conversation
The alt-screen browser bought back repaintability -- entry navigation, folding, app-read scrolling -- at the cost of a scroll/anchor/selection machine larger than the chat itself, for a screen that showed what the terminal's own scrollback already shows. It goes, and ctrl+j with it: esc and the bottom-edge arrow are the ways to the picker. Long bodies still clamp at six lines. Nothing un-clamps them now, so the hint drops its key and reads "+N lines" -- the full text is up in the scrollback where it printed.
There was a problem hiding this comment.
Caution
Changes requested ❌ — 2 issues
Reviewed 6cbd009 in 8 minutes, 35 seconds.
- Reviewed
1commit with811lines of code in9files - Ran
1review agent producing2comments where2were posted - This pipeline runs no gatekeeper, so findings are posted as written.
- View full details on ellipsis.dev
This review was created by . You can tag
@ellipsis in this pull request.
| // A clamped body says how much it cut, and nothing more: there is no key that | ||
| // un-clamps it, and the full text is up in the scrollback where it printed. | ||
| const spans: RowSpan[] = row.clampedLines | ||
| ? [ | ||
| { | ||
| text: `… +${row.clampedLines} lines (${selected ? '→' : 'ctrl+r'} to expand)`, | ||
| dim: true, | ||
| }, | ||
| ] | ||
| ? [{ text: `… +${row.clampedLines} lines`, dim: true }] | ||
| : row.spans |
There was a problem hiding this comment.
The clamped body's full text is not in the scrollback, so a long tool result is now unreadable anywhere in the UI — … +N lines names no key and no view has the rest.
<Static> (the scrollback) is fed from flushedRows, which is sliced out of allRows; allRows builds every row via itemRows, and itemRows (transcriptRows.ts:158) now clamps unconditionally. So the rows printed into scrollback are the same 6 lines plus this marker — the hidden lines were never printed. Concretely: a tool_result with 200 lines shows 6 and … +194 lines, and nothing in the chat, the scrollback, or any key can show line 7. Previously → / ctrl+r un-clamped it. The comment on 1949-1950 (and the same claim at 88) is the premise the removal rests on and it does not hold.
| // past. Once it settles the block collapses to its summary line; the log | ||
| // itself stays up in the scrollback, where it was printed. | ||
| if (!sandbox) return rows | ||
| const show = settled && !o.expanded ? [] : lastLines(sandbox.log, SANDBOX_LOG_ROWS) | ||
| const show = settled ? [] : lastLines(sandbox.log, SANDBOX_LOG_ROWS) |
There was a problem hiding this comment.
The startup log is erased when the sandbox settles rather than left in the scrollback, because it never gets printed there: it only ever renders in the repainting live region.
While the sandbox is starting, sandboxSettled is false, so SANDBOX_KEY is absent from settledKeys and the log rows render only in the live <Box>, which ink repaints in place. The moment it settles, sandboxRows returns just the header + summary (show = [] here), and those are the rows flushed to <Static>. So the build/setup output is gone for good once the session is up — with the →-to-reopen path deleted there is nothing left that can show it.
Summary
Deletes the ctrl+r transcript browser and everything that existed only to serve it: ~1030 net lines gone.
The browser was a windowed view of the conversation on the alternate screen, where rows could be repainted — entry navigation with ↑/↓, folding tool runs open and shut, app-read wheel scrolling. It cost a scroll-anchor/viewport/selection machine larger than the chat itself, to show what the terminal's own scrollback already shows. The chat's resting view (settled rows printed once into real scrollback via
<Static>, plus a live tail and the composer) is untouched.What went:
ConnectApp: thewindowed/navKey/openedKeys/scrollAnchor/expanded/sandboxLogOpenstate, the alt-screen hop, SGR mouse capture, the wheel and page-key branches, the ~80-line transcript-navigation keybinding block, the marker/scroll/reveal callbacks, and the browser's notice line.transcriptRows:rowViewport,anchorAt,anchorIndex,entryRange,snapToEntry,snapAnchorForEntry,navKeyOf,ScrollAnchor, plus thenavKey/parentKeyrow fields andlayOutItems' reveal options.foldRun, the/transcriptcommand, andctrl+j— esc and the bottom-edge arrow are the ways to the picker now.Two behavior changes worth calling out:
… +N lines. The full text printed into the scrollback on its way past.Test plan
npm run typechecknpm test(438 passed; the 31 deleted tests all covered removed exports)tsc --noUnusedLocalsreports no new dead code/offers three commands, ctrl+r and ctrl+j are inert, esc reaches the picker, terminal wheel scrolling works over the transcriptImportant
Removes the ctrl+r transcript browser and its supporting infrastructure (~1030 net lines deleted).
ConnectAppand viewport machinery intranscriptRows.ConnectApp:windowed,navKey,openedKeys,scrollAnchor,expanded,sandboxLogOpenstate; alt-screen switching; SGR mouse capture; ~80-line transcript navigation keybindings.transcriptRows: viewport/anchor/reveal/navigation functions (rowViewport,anchorAt,anchorIndex,entryRange,snapToEntry,snapAnchorForEntry,navKeyOf,ScrollAnchor)./transcriptcommand andctrl+j;escand bottom-edge arrow now reach the picker.… +N lines.This description was created by
for 6cbd009. It will automatically update as commits are pushed.