Session Info: content under the floating panel pushes the chat left

Merged
TE
5d ago
+113-19

Follow-up to #31423. Leo, 2026-11-01:

"why does THE fing SESSION INFO NOT fing PUSH THE LAYOUT LEFT EVER ANYTMORE"

His screenshot shows the panel floating over chat text, with the chat's column running under it.

#31423 decided float or push from a width threshold: the gutter's model width against the panel's width. This PR makes overlap the trigger. While the panel floats, it reads how far the chat's drawn rows and composer reach past the column the model expects (chatContentOverflow). This happens in a layout effect, before paint. If the panel would lie over any of that content, it pushes and the chat moves left. It floats only when it sits entirely in empty gutter. The reading is taken only while floating, so it never depends on the push it decides. It holds while pushed and resets each time the panel opens.

Regressed by #27790 (2026-10-30), which removed the left shift.

Tests

  • test/session-info.test.tsx: Leo's geometry. In a 1600px pane the model says the gutter holds the panel. A row inside the column keeps it floating. A row reaching to 1500px, under the panel (1272 to 1592), pushes. This is red on the #31423 tip.
  • test/session-info-overlay-toggle.test.ts: the two tests #31423 left expecting a float at 900px (independent review, BLOCK at 43d782c1) now expect the default push. The busy-panel test checks that the panel never covers the composer.

Risk

Webview only. One querySelectorAll over the mounted rows and the composer runs when the panel opens and when the pane, the panel or the row count changes while it floats. That adds no work per token.

Agent session: agent session

šŸ¤– Generated with Claude Code


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.


Summary by cubic

Stops the session info panel from floating over the chat's text: a floating panel now pushes the chat left whenever it would cover any of the chat's content, instead of only when the gutter's model width can't hold it.

  • Measures how far the chat's rows and composer reach past the expected column (chatContentOverflow) in a layout effect while the panel floats and holds that reading while pushed.
  • Updates the 900px pane tests that expected the old float behavior to expect the default push.
  • Adds a geometry test reproducing the reported overlap and confirms the busy-panel test never covers the composer.