core-agent-ide/codex-rs/tui2
Josh McKinney 279283fe02
fix(tui2): avoid scroll stickiness at cell boundaries (#8695)
Mouse/trackpad scrolling in tui2 applies deltas in visual lines, but the
transcript scroll state was anchored only to CellLine entries.

When a 1-line scroll landed on the synthetic inter-cell Spacer row
(inserted between non-continuation cells),
`TranscriptScroll::anchor_for` would skip that row and snap back to the
adjacent cell line. That makes the resolved top offset unchanged for
small/coalesced scroll deltas, so scrolling appears to get stuck right
before certain cells (commonly user prompts and command output cells).

Fix this by making spacer rows a first-class scroll anchor:
- Add `TranscriptScroll::ScrolledSpacerBeforeCell` and resolve it back
to the spacer row index when present.
- Update `anchor_for`/`scrolled_by` to preserve spacers instead of
skipping them.
- Treat the new variant as "already anchored" in
`lock_transcript_scroll_to_current_view`.

Tests:
- cargo test -p codex-tui2
2026-01-03 20:26:40 +00:00
..
docs feat(tui2): add multi-click transcript selection (#8471) 2025-12-23 21:05:06 +00:00
frames feat(tui2): copy tui crate and normalize snapshots (#7833) 2025-12-10 22:53:46 +00:00
src fix(tui2): avoid scroll stickiness at cell boundaries (#8695) 2026-01-03 20:26:40 +00:00
tests Sync tui2 with tui and keep dual-run glue (#7965) 2025-12-12 20:46:18 -08:00
Cargo.toml WIP: Rework TUI viewport, history printing, and selection/copy (#7601) 2025-12-15 17:20:53 -08:00
prompt_for_init_command.md feat(tui2): copy tui crate and normalize snapshots (#7833) 2025-12-10 22:53:46 +00:00
styles.md Sync tui2 with tui and keep dual-run glue (#7965) 2025-12-12 20:46:18 -08:00
tooltips.txt chore: drop undo from the docs (#8431) 2025-12-22 15:09:48 +00:00