You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bug: scroll position lost when navigating between parent and child sessions in web app #42806
When navigating between parent and child sessions in the web app, the scroll position is always lost. This affects two scenarios:
"Back to main session" click: When viewing a subagent/child session and clicking "Back to main session" in the composer area, the parent session scrolls to the bottom instead of restoring the position the user was at before they clicked into the child session.
Breadcrumb parent title click: Clicking the parent session title in the timeline header breadcrumb has the same behavior — it scrolls to the bottom of the parent session.
Both navigation paths use navigate() to route to the parent session URL, and the newly mounted session always calls autoScroll.resume() which forces a scroll to the bottom.
Steps to reproduce
Open a session with a long conversation (multiple messages)
Scroll to a specific message mid-way through the conversation
Click a subagent task card to navigate into a child session
In the child session, click "Back to main session" (or the parent breadcrumb title)
Observe: the parent session scrolls to the bottom instead of returning to the position you were at
Root cause
The timelineCache in message-timeline.tsx saves measurements and tool open state per session key, but does not save the scroll offset. When the session remounts, there is no saved position to restore, and the shouldAnchorBottom() logic kicks in, scrolling to the end.
Additionally, window.history.scrollRestoration is explicitly set to "manual" in use-session-hash-scroll.ts, so the browser's native scroll restoration is disabled.
Activity
personal: keep the reading position and split the changelog
github-actions commentedon Oct 16, 2026
To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.