Repository navigation
Compact thinking control in narrow composers - #7150
Conversation
There was a problem hiding this comment.
Code Review
This pull request implements a responsive, compact layout for the 'Thinking' pill control within narrow composer containers. It adds specific class names and data attributes to the TSX components, defines container queries in the CSS to collapse the label and caret on small screens, and introduces a test suite to verify these elements. The review feedback recommends specifying encoding='utf-8' when reading files in the tests to prevent platform-dependent encoding issues with non-ASCII characters.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
|
|
||
| def test_thinking_control_has_compact_hooks_in_both_composers(): | ||
| for path in (THREAD_TSX, SHARED_TSX): | ||
| source = path.read_text() |
There was a problem hiding this comment.
|
|
||
|
|
||
| def test_narrow_composer_collapses_thinking_to_the_bulb(): | ||
| css = INDEX_CSS.read_text() |
There was a problem hiding this comment.
When reading the CSS file in tests, always specify encoding='utf-8' to prevent platform-dependent encoding failures (e.g., on Windows) where default codecs might fail on non-ASCII characters like − (minus sign, U+2212) present in index.css.
| css = INDEX_CSS.read_text() | |
| css = INDEX_CSS.read_text(encoding="utf-8") |
|
Codex Review: Didn't find any major issues. 👍 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Summary
Why
Opening Canvas narrows the chat composer. The full Thinking pill can consume enough horizontal space to wrap the right-side controls onto another line and distort the composer layout.
The composer now queries its own width, so split layouts adapt independently of the browser viewport.
User impact
Narrow composers keep the Thinking control on the same row as dictation and send controls. The bulb remains clickable and continues to open reasoning settings or toggle thinking.
Validation
npm run typechecknpm run build