[BUG] Header layout updates cause terminals to auto scroll up
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
The recently added header that seems to change while using claude code. Switching between the more compact layout and the more detailed one causes some terminals to automatically scroll up (namely xterm.js).
Not sure if this is really considerably a bug but I'd prefer to have the option to disable that at least. It might just be caused by the TUI not realizing its own position in the buffer as this also still happens if the header is far back in the buffer. I don't think it does still update itself on all terminals but it keeps happening on xterm.js and it seems like xterm.js does not offer a way tu suppress this auto scroll behaviour.
Maybe someone can look into this. I'd be glad to help testing
What Should Happen?
Ideally the header should not change when out of visible terminal screen or disabling the changing header would just suppress it.
Error Messages/Logs
Steps to Reproduce
- run claude code in an xterm.js (browser based) terminal.
- launch claude code (2.1.6 confirmed with this behaviour)
- start a conversation
- watch the terminal jumping more or less randomly between header and prompt position.
Claude Model
None
Is this a regression?
I don't know
Last Working Version
_No response_
Claude Code Version
2.1.6
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
Xterm
Additional Information
_No response_
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗