Repository navigation
feat(composer): restore compact branch picker UX - #21741
Conversation
There was a problem hiding this comment.
ℹ️ No critical issues — a couple of minor suggestions inline.
Reviewed changes
This run reviewed the full 16-file, renderer-only diff that restores the compact "Branch from" control in the New Workspace composer.
- Compact branch picker beside the name label —
NewWorkspaceComposerNameSectionmovesComposerBaseRefPickerinto ajustify-betweenrow with the renamed "Create From" label and drops the oldName or 'Create From'copy. - Mode-aware visibility —
shouldShowComposerBaseRefPickernow hides the picker whensmartNameMode === 'branches', withsmartNameModethreaded throughComposerModel→ card props → name section. - Read-only connected-project state —
CreateFromPicker/ComposerBaseRefPickergainreadOnly, rendering the trigger without aPopoverwhen the project needs a connection. - Set-as-default context menu — branch rows get a right-click "Set as default" action writing
worktreeBaseRefthrough the host-awareupdateRepopath. - Host-aware base-ref lookups —
getRuntimeRepoBaseRefDefault/searchRuntimeRepoBaseRefsnow receiverepoHostId. - i18n + tests — label updated in en/es/ja/ko/zh; tests added/updated for read-only and branch-mode visibility.
I ran the four changed test files locally: 52 passing. The context-menu-inside-popover pattern matches the existing AgentCombobox, including z-[70], so the layering is sound.
ℹ️ Nitpicks
fr.jsonstill carries the pre-change label:auto.components.NewWorkspaceComposerCard.ac3748dcdais"Nom ou « Créer à partir de »"while en/es/ja/ko/zh were updated to "Create From". French is a supported (lazily loaded) locale and the most complete catalog, so this looks like an oversight rather than intentional lag.- No card-level test covers
smartNameMode: 'branches'actually hiding the picker (only the pureshouldShowComposerBaseRefPickerunit test), and none covers "Set as default" routingupdateRepowith the repo's execution host. Both are cheap to add and guard the wiring, not just the predicate.
DeepSeek Flash (free via Pullfrog for OSS) | 𝕏
| title={ | ||
| readOnly | ||
| ? translate( | ||
| 'auto.components.NewWorkspaceComposerCard.connectProjectFirst', | ||
| 'Connect this project first' | ||
| ) | ||
| : translate('auto.components.automations.CreateFromPicker.dd3841b442', 'Branch from') | ||
| } |
There was a problem hiding this comment.
The compact trigger sets a native title while its label is also wrapped in FilePathCursorTooltip (line 264), so hovering the label can surface two different tooltips at once — the Radix branch-name tooltip and the browser's Branch from / Connect this project first. Consider keeping a single mechanism; e.g. move the read-only reason into the Radix tooltip content and drop title, or drop the tooltip and let title carry the full name.
📝 WalkthroughWalkthroughThe composer now carries Priority: ⬇️ Low Merge Risk: 🔵 Low · up to Read-only projects expose a misleading branch control, and failed default-branch changes appear to succeed. These are bounded UI failures but should be addressed before relying on the new picker workflow. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 33.33% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 6 functions across 11 files. (5 skipped: 5 unsupported.)
✨ Finishing Touches 💡 2📝 Generate docstrings 💡
🛠️ Fix failing CI checks 💡
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Advanced
Run ID: 7e1485d6-3734-4270-abff-b53685d5b0d0
📒 Files selected for processing (16)
src/renderer/src/components/NewWorkspaceComposerCard.start-from.test.tsxsrc/renderer/src/components/NewWorkspaceComposerCard.test.tsxsrc/renderer/src/components/new-workspace/ComposerBaseRefPicker.tsxsrc/renderer/src/components/new-workspace/NewWorkspaceComposerNameSection.tsxsrc/renderer/src/components/new-workspace/base-ref-picker-visibility.test.tssrc/renderer/src/components/new-workspace/base-ref-picker-visibility.tssrc/renderer/src/components/new-workspace/new-workspace-composer-card-props.tssrc/renderer/src/components/repo/CreateFromPicker.test.tsxsrc/renderer/src/components/repo/CreateFromPicker.tsxsrc/renderer/src/hooks/composer-state/composer-card-contract.tssrc/renderer/src/hooks/composer-state/composer-card-props.tssrc/renderer/src/i18n/locales/en.jsonsrc/renderer/src/i18n/locales/es.jsonsrc/renderer/src/i18n/locales/ja.jsonsrc/renderer/src/i18n/locales/ko.jsonsrc/renderer/src/i18n/locales/zh.json
Included review availability: Your plan provides up to 10 included reviews per hour; 4 remain after this review.

ELI5
The New Workspace composer now puts the starting branch in a compact control beside “Create From”, so choosing a workspace name and choosing its base branch stay visible together.
What Changed
The composer label is now “Create From [Optional]”. The branch picker appears as a compact top-right control, opens the existing searchable branch list, and hides while the Branch naming tab is active. Read-only projects show the selected branch without offering an action. Branch rows can set the repository default through the existing host-aware update path.
Why
The full-width branch row took over the composer and made the name/source relationship harder to scan. The compact control keeps the common choice visible without changing the underlying branch creation behavior. The implementation restores the previously designed UX and keeps local, SSH, and runtime repository routing intact.
Linked Issue
Fixes #15747
Visual Proof
The attached screenshot shows the recovered compact “Branch from” control beside “Create From [Optional]”.
Testing
pnpm tc:web(after restoring the local dependency cache)pnpm run check:code-quality:changedgit diff --checkAI Disclosure
Codex assisted with the implementation and verification.
Checklist