Repository navigation
fix(web): keep emoji intact in manually added folder names - #42244
jadelike-wine wants to merge 3 commits into
Conversation
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
…ssion Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Problem
In Settings → Projects, select a project and use Repositories → Add folder to add a directory named 127
as followed by 🚀. The saved label ends in � because the 128-code-unit limit cuts the rocket in half. With 126as, the rocket fits.Change
Trim leading whitespace before measuring the basename and use the existing surrogate-pair check to cut before a character that crosses the limit. The full directory path is preserved.
Scope
This is a small, reproducible bug in the Web settings form, so there is no separate issue. The CLI and server discovery paths already handle this boundary (#42083, #42133). Only the Web helper and its tests change.
Verification
vp test run apps/web/src/components/settings/trackedFolders.logic.test.ts. On the baseline, the 127-aand leading-whitespace cases failed. All 16 tests pass with the fix, including the 126-acase that keeps the rocket.as. Both rows kept their original paths. The screenshots repeat the same boundaries with narrower letters so the ends of the labels are visible. Compare thecut-row in each image.vp run check:changed upstream/mainpassed formatting, lint, both Knip checks, typechecking, focused tests and the React Compiler check.Before
After
Model: GPT-6. Harness: Codex Desktop.