Skip to content

fix: prevent CLI path overflow in chat status card#2531

Closed
xxiaoxiong wants to merge 1 commit into
nexu-io:mainfrom
xxiaoxiong:fix/cli-path-overflow-2206
Closed

fix: prevent CLI path overflow in chat status card#2531
xxiaoxiong wants to merge 1 commit into
nexu-io:mainfrom
xxiaoxiong:fix/cli-path-overflow-2206

Conversation

@xxiaoxiong
Copy link
Copy Markdown
Contributor

Summary

Fixes long CLI startup paths overflowing the chat status card boundary.

What changed

Added text-overflow handling to .op-waiting-detail:

  • max-width: 100% - constrains to parent card width
  • overflow: hidden - clips overflowing text
  • text-overflow: ellipsis - shows ... for truncated content
  • white-space: nowrap - prevents line wrapping

Why

The CLI startup status displays the daemon path in a <code> element with class .op-waiting-detail. Long filesystem paths (common on Linux/macOS with deep project directories) would extend beyond the card boundary, breaking the layout and making the status message hard to read.

Result

Long CLI paths now truncate cleanly with an ellipsis, staying within the card boundary while still showing the beginning of the path (which typically contains the most relevant context).

Closes #2206

Added text-overflow handling to .op-waiting-detail so long CLI startup
paths truncate with ellipsis instead of overflowing the card boundary.

Changes:
- max-width: 100% - constrains to parent width
- overflow: hidden - clips overflowing text
- text-overflow: ellipsis - shows ... for truncated text
- white-space: nowrap - prevents wrapping

Closes nexu-io#2206
@github-actions
Copy link
Copy Markdown
Contributor

Visual regression review

Head: 8b5711a · Base: 21e7522

0 changed · 17 unchanged · 0 missing baseline · 0 failed

Unchanged cases
Case Main PR Diff
visual-avatar-menu main pr diff
visual-design-systems main pr diff
visual-home main pr diff
visual-home-catalog main pr diff
visual-home-context-picker main pr diff
visual-home-plugin-filter main pr diff
visual-integrations main pr diff
visual-integrations-use-everywhere main pr diff
visual-new-project-modal main pr diff
visual-plugin-details main pr diff
visual-plugins main pr diff
visual-projects main pr diff
visual-projects-kanban main pr diff
visual-settings-byok main pr diff
visual-settings-execution main pr diff
visual-tasks main pr diff
visual-topbar-execution-switcher main pr diff

Visual diff is advisory only and does not block merging.

@lefarcen lefarcen requested a review from mrcfps May 21, 2026 10:06
@lefarcen lefarcen added size/XS PR changes <20 lines risk/medium Medium risk: regular code changes type/bugfix Bug fix labels May 21, 2026
@lefarcen
Copy link
Copy Markdown
Contributor

Heads-up: #2283 and #2352 are already open against #2206, and all three PRs touch apps/web/src/index.css for the Local CLI startup/status-card overflow.

#2283 is covering the assistant StatusPill / WaitingPill path and has an approval on its current head; #2352 is your earlier PR on the same issue. You may want to consolidate your two branches, and the maintainer team will pick which implementation lands so duplicate effort does not pile up.

Copy link
Copy Markdown
Contributor

@lefarcen lefarcen left a comment

Choose a reason for hiding this comment

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

Hey @xxiaoxiong, thanks for keeping the overflow fix tightly scoped to the status-card text. The description already explains the old-template Summary/Why well, but before pool review picks this up could you add the new-template Surface area checklist and a short Validation section? For validation, a quick note on how you checked the long-path card behavior is enough.

Copy link
Copy Markdown
Contributor

@mrcfps mrcfps left a comment

Choose a reason for hiding this comment

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

@xxiaoxiong Thanks for taking on the CLI path overflow fix. I found one blocker in the current CSS change: the new ellipsis rules still do not let this flex item shrink, so long unbroken paths can continue to overflow the waiting card.

🔁 Powered by Looper · runner=reviewer · agent=opencode · An autonomous AI dev team for your GitHub repos.

Comment thread apps/web/src/index.css
Comment on lines +14844 to +14847
max-width: 100%;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
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.

Because .op-waiting-detail is a flex item inside .op-waiting (display: flex a few lines above) and this change also forces the path to stay on one line, max-width: 100% plus overflow: hidden still will not shrink a long unbroken filesystem path below its min-content width. That means the bug this PR is trying to fix can still reproduce: the <code> pill keeps the full path width and overflows instead of showing an ellipsis. Please add min-width: 0 here (or an equivalent shrinking flex rule such as flex: 1 1 0) and keep the ellipsis styles on that shrinking box so the path can actually truncate inside the card.

🔁 Powered by Looper · runner=reviewer · agent=opencode · An autonomous AI dev team for your GitHub repos.

@xxiaoxiong
Copy link
Copy Markdown
Contributor Author

Closing as duplicate of #2352 (my earlier PR) which addresses the same issue #2206. Thanks @lefarcen for catching this!

@xxiaoxiong xxiaoxiong closed this May 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk/medium Medium risk: regular code changes size/XS PR changes <20 lines type/bugfix Bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants