Skip to content

fix(chat): prevent provider name clipping#2849

Merged
arnestrickmann merged 3 commits into
mainfrom
emdash/eng-1832-provider-name-clipping
Jul 13, 2026
Merged

fix(chat): prevent provider name clipping#2849
arnestrickmann merged 3 commits into
mainfrom
emdash/eng-1832-provider-name-clipping

Conversation

@janburzinski

@janburzinski janburzinski commented Jul 13, 2026

Copy link
Copy Markdown
Collaborator

Summary

Fixes ENG-1832 by keeping the provider/model trigger from shrinking and giving its clipped text label enough line height for descenders.

Root cause

The model selector could shrink under toolbar pressure, and its text label used a unit line height inside an overflow-clipped span, which cut off descenders such as g.

screenshot

after:
Screenshot 2026-07-13 at 14 36 27

@janburzinski
janburzinski marked this pull request as ready for review July 13, 2026 12:40
@greptile-apps

greptile-apps Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR adjusts the chat composer model selector so provider names stay readable.

  • Adds a non-shrinking trigger class for the model selector.
  • Applies that class to the combobox trigger.
  • Increases the clipped model label line height for descenders.

Confidence Score: 5/5

This looks safe to merge after a small layout cleanup.

  • The change is limited to chat composer presentation.
  • The only issue found is a narrow-toolbar overflow case for long provider/model labels.
  • No blocking functional or security issues were found in the changed code.

packages/ui/src/react/components/chat-composer/chat-composer.css.ts

Important Files Changed

Filename Overview
packages/ui/src/react/components/chat-composer/chat-composer.css.ts Adds a model trigger style that prevents the selector from shrinking.
packages/ui/src/react/components/chat-composer/index.tsx Applies the new trigger style and increases the clipped label line height.
Prompt To Fix All With AI
Fix the following 1 code review issue. Work through them one at a time, proposing concise fixes.

---

### Issue 1 of 1
packages/ui/src/react/components/chat-composer/chat-composer.css.ts:204
**Model Trigger Stops Ellipsis**

When the composer is narrow or the selected provider/model name is long, `flexShrink: 0` keeps the trigger at its content width. That prevents the existing clipped label from shrinking enough to ellipsize, so the toolbar can overflow or push other controls out of the row instead of truncating the model name.

Reviews (1): Last reviewed commit: "fix(chat): avoid clipping model label de..." | Re-trigger Greptile

Comment thread packages/ui/src/react/components/chat-composer/chat-composer.css.ts Outdated

@arnestrickmann arnestrickmann left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks!

@arnestrickmann
arnestrickmann merged commit b5ad760 into main Jul 13, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants