fix(sidebar): keep project name visible on pinned worktree rows - #13572
fix(sidebar): keep project name visible on pinned worktree rows#13572bbingz wants to merge 1 commit into
Conversation
|
Warning Review limit reached
Next review available in: 57 minutes You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughWorktree cards now fall back to 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
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: 1
🧹 Nitpick comments (2)
src/renderer/src/components/sidebar/WorktreeCard.tsx (1)
1451-1458: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winUse the documented sidebar label tokens.
This new label adds raw
max-w-[7rem],text-[12px], andleading-5values. Use the documented renderer tokens, or the existing sidebar truncation component when it provides the required behavior.As per coding guidelines, renderer UI work must follow
docs/STYLEGUIDE.mdand use tokens fromsrc/renderer/src/assets/main.css.Source: Coding guidelines
src/renderer/src/components/sidebar/WorktreeCard.pinned-repo-icon.test.tsx (1)
129-131: 🎯 Functional Correctness | 🔵 Trivial | ⚡ Quick winAdd regression cases for blank and nullish titles.
These assertions use a non-empty
displayName. They do not exercise the fallback atWorktreeCard.tsxLines [641-647]. Add cases for empty and nullishdisplayNamevalues, then assert that the branch or path name remains visible in a pinned row.Based on the PR objective, blank and nullish card titles must retain a readable project/worktree name.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 6ee4f83b-0e55-4772-84de-f439bdd6ac03
📥 Commits
Reviewing files that changed from the base of the PR and between a63df91 and 1edce0b42c517f47dad65e1a367b64ac2c56378b.
📒 Files selected for processing (2)
src/renderer/src/components/sidebar/WorktreeCard.pinned-repo-icon.test.tsxsrc/renderer/src/components/sidebar/WorktreeCard.tsx
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 858f4ee1-f184-470d-86e4-e7ace7c943a3
📥 Commits
Reviewing files that changed from the base of the PR and between 1edce0b42c517f47dad65e1a367b64ac2c56378b and 3b0a0e54f9000b73a218188d1727f92f138bd96b.
📒 Files selected for processing (2)
src/renderer/src/components/sidebar/WorktreeCard.pinned-repo-icon.test.tsxsrc/renderer/src/components/sidebar/WorktreeCard.tsx
🚧 Files skipped from review as they are similar to previous changes (1)
- src/renderer/src/components/sidebar/WorktreeCard.tsx
3b0a0e5 to
73b6e88
Compare
|
Note GitHub couldn't provide a complete incremental comparison for this pull request, so CodeRabbit is performing a full review instead. This review may take a little longer. |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
src/renderer/src/components/sidebar/worktree-card-header.tsx (1)
107-115: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winVerify the new label uses approved design tokens.
Confirm that
max-w-[7rem]andtext-[12px]are approved bydocs/STYLEGUIDE.md. If they are not approved tokens, replace them with the corresponding values fromsrc/renderer/src/assets/main.css.As per coding guidelines, UI work in this path must follow
docs/STYLEGUIDE.mdand use tokens fromsrc/renderer/src/assets/main.css.Source: Coding guidelines
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 1995f0c1-2386-4bda-8bb4-3337998f73e6
📥 Commits
Reviewing files that changed from the base of the PR and between 9f8c22c and 73b6e88da517cf3235964b7ba09d1dc011ef93de.
📒 Files selected for processing (4)
src/renderer/src/components/sidebar/WorktreeCard.pinned-repo-icon.test.tsxsrc/renderer/src/components/sidebar/use-worktree-card-linked-details.tssrc/renderer/src/components/sidebar/worktree-card-header.tsxsrc/renderer/src/components/sidebar/worktree-card-presentation.tsx
🚧 Files skipped from review as they are similar to previous changes (1)
- src/renderer/src/components/sidebar/WorktreeCard.pinned-repo-icon.test.tsx
|
Ready for review (contributor priority pack)
Part of a short priority list for maintainers: P0 |
Pinned rows leave the project group header, so only an icon with an aria-label remained for project identity. Show a readable project name next to the icon when the card title is a worktree/branch label, and fall back empty titles through resolveWorktreeDisplayName. Fixes stablyai#13353
73b6e88 to
d20f71b
Compare
Summary
resolveWorktreeDisplayNameso cleared/nullish display names do not leave an empty row.Test plan
pnpm exec vitest run --config config/vitest.config.ts src/renderer/src/components/sidebar/WorktreeCard.pinned-repo-icon.test.tsxFixes #13353