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
Opening a long chat does not scroll to the latest message #1093
When the user opens an existing chat, AI Studio should scroll all the way to the end, depending on the chat options. This does not work for very long threads: the view stops somewhere in the middle of the chat instead of showing the latest message. In testing, the bug shows up when the chat contains many long code blocks.
Prerequisites
Chat options: "Show the latest message after loading?" is enabled (the default).
A saved chat with a very long thread, e.g., many answers with long code blocks.
Steps
Open another chat or start a new one.
Open the long chat from the chat list.
Expected
The view ends at the latest message.
Actual
The view stops above the end of the chat; the latest message is not visible. The user has to scroll down manually.
Notes
After loading, ChatComponent waits for a fixed number of render passes (2 or 4) and then scrolls once using scrollIntoView with behavior: 'smooth'. Long code blocks probably keep growing after that point (Markdown rendering, syntax highlighting), so the scroll target is no longer the end of the chat.
Activity