Repository navigation
fix: stabilize chat scrolling and dark text selection - #70
Conversation
Keep completed replies pinned to the bottom while authoritative history reloads collapse streamed turns, and preserve the visible anchor when virtualized message measurements correct spacer heights. Use measured per-role heights for unmounted virtual rows, suppress programmatic correction scroll events, disable conflicting browser scroll anchoring, and restore a high-contrast inverted text selection in the dark theme.
|
I'll fix CI failures and address comments from users with write access that start with 'Devin'.
|
Do not repin the transcript for viewport-only virtual-list renders, and distinguish an exact bottom clamp from a deliberate small upward scroll near the bottom.
Track the row overlapping the viewport and, when measurement moves it outside the mounted window, correct against its represented virtual position instead of requiring an overlapping row.
Only disable browser scroll anchoring while the virtualized message list owns correction, so collapsing blocks in short conversations can still preserve the visible message.
Observe the scroller size for short and virtualized sessions so approval forms or composer growth can keep an already bottom-pinned reader at the latest message.
End-to-end UI verification on head 17f9fdbTested the real Go backend + React web UI with live GLM generation and seeded adversarial sessions.
Notes: the first Devin session: https://app.devin.ai/sessions/77033b0859bc4138958b7c9100ec1d5f |
Focused virtual-spacer retest at 241d3d7 — passedTested the real Go backend + rebuilt React web UI. After switching to the other long session and back, then waiting 5+ seconds: Comparison: |
Summary
useLayoutEffect, and real message-layout changes can request a one-frame bottom pin without treating viewport-only scrolling as a layout change.estimateMessageHeight): tall numbered/code-like answers are tall before mounting, ordinary rows remain close to the legacy scale, attachment/context envelopes count only as compact controls, and measured rows correct their own positions without inflating every hidden row.#d4d4d4on#111111) after the neutral theme refresh regressed it to a near-surface gray; a contrast regression test covers the dark selection tokens.Validation:
web pnpm buildpassed.mobile pnpm buildpassed.mobile pnpm testpassed: 30/30.ask_choiceviewport shrink, collapse-all, and dark text selection. Packaged native desktop shell was not tested.scrollHeightstayed stable across a long-session switch (34028 → 34246, about 0.6%) instead of inflating into the prior74k–89krange.Link to Devin session: https://app.devin.ai/sessions/77033b0859bc4138958b7c9100ec1d5f
Open in Devin Desktop: https://app.devin.ai/desktop/session/77033b0859bc4138958b7c9100ec1d5f?variant=devin
Requested by: @ezdemo
🟢 Devin Review found nothing to fix · View findings · Follow Devin's work