Skip to content

fix(board): show project name on Workspace board cards - #13830

Closed
PannenetsF wants to merge 2 commits into
stablyai:mainfrom
PannenetsF:yq/lucid-poitras-5a53d1
Closed

PannenetsF wants to merge 2 commits into
stablyai:mainfrom
PannenetsF:yq/lucid-poitras-5a53d1

Conversation

@PannenetsF

@PannenetsF PannenetsF commented Aug 11, 2026 •

Copy link
Copy Markdown
Contributor

Closes #13828

Summary

On the Workspace board, cards with no descriptive title didn't show which project they belong to. Board lanes group by workspace status and mix projects, so each card is the only place its project is identified — but in the new/compact card styles the repo shows as an icon-only chip (name in a hover tooltip). A project's primary worktree with no session keeps its default branch title, so every one reads main / master and they're indistinguishable across projects.

This adds a board-only showProjectName flag (set from WorkspaceKanbanCard) that renders the repo display name as a muted inline label in the card's title row, in the icon-only card styles where the name text is otherwise absent. The sidebar is unchanged — it keeps the chip-only treatment since it can already group by project.

Screenshots

I don't have a running app build in this environment, so no screenshot is attached. The change is small and self-contained: in each board card's title row, a muted text-[11px] text-muted-foreground project label (repo display name) now appears between the repo icon chip and the workspace title, e.g. [icon] orca main. It only renders on the board (not the sidebar) and only in the icon-only card styles; layout is otherwise unchanged (the label is shrink-0 truncate max-w-[8rem]).

Testing

  • pnpm lint — oxlint on changed files clean; pre-commit hook (oxlint + react-doctor + oxfmt) passed on both commits.
  • pnpm typecheck — tsc --noEmit -p config/tsconfig.tc.web.json clean.
  • pnpm test — new WorktreeCard.project-name.test.tsx (3 tests) + related card/lane suites green.
  • pnpm build — not run in this environment (no full Electron build available here).
  • Added high-quality tests: project name shows with showProjectName; is absent without it (sidebar); is absent for a folder workspace (repo present with kind:'folder', exercising the !isFolder gate).

AI Review Report

Reviewed with an AI coding agent (Claude Code). Focus areas and findings:

  • Scope leakage — verified WorkspaceKanbanCard is rendered only by the board's lane list (WorkspaceKanbanLaneCardList), so the showProjectName flag cannot reach the sidebar. The gate showProjectNameLabel = showProjectName && showInlineRepoBadge further limits it to the icon-only title styles where the repo name text is otherwise missing.
  • Regression surface — the new prop is optional and defaults to falsy, so all existing WorktreeCard call sites (sidebar, pinned, lineage) are unaffected. Existing card/lane test suites pass unchanged.
  • Layout — label is shrink-0 truncate max-w-[8rem]; the title keeps min-w-0 truncate, so overflow behavior is preserved and the full name remains available via the adjacent chip's tooltip.
  • Cross-platform (macOS / Linux / Windows) — reviewed for platform-specific concerns and found none: no keyboard shortcuts, shortcut labels, file paths, shell invocation, or Electron main-process/IPC code are touched. This is a renderer-only, presentational change (a conditional text span + one prop threaded through existing card plumbing), so behavior is identical across platforms.

Security Audit

Renderer-only, presentational change. No new input handling, command execution, path handling, auth, secrets, dependency, or IPC surface. The only new runtime value rendered is repo.displayName, an existing trusted field already shown elsewhere (repo chip tooltip, legacy meta-row badge) and rendered as React text (no dangerouslySetInnerHTML). No follow-up required.

Notes

  • No wire/protocol changes; nothing crosses the client/host boundary, so remote wire compatibility is unaffected.
  • Behavior is identical for local, SSH, and folder workspaces (folder workspaces suppress the icon chip, so the label is gated off with it).
  • Follow-up idea (out of scope): the sidebar could optionally reuse this when not grouping by project, but that's a separate UX decision.

🤖 Generated with Claude Code

Board lanes group by workspace status and mix projects, so each card is
the only place its project is identified. In the new/compact card styles
the repo shows as an icon-only chip (name in a hover tooltip), so cards
whose title falls back to the branch — every project's primary reads
`main`/`master` — are indistinguishable across projects.

Add a board-only `showProjectName` prop, set from WorkspaceKanbanCard,
that renders the repo display name as a muted inline label in the title
row. The sidebar keeps the chip-only treatment. Scoped so it only fires
in the icon-only title styles where the name text is otherwise absent.

Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
@coderabbitai

coderabbitai Bot commented Aug 11, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

Kanban cards now pass showProjectName to WorktreeCard. The flag flows through the card controller and presentation builder as showProjectNameLabel. The card header conditionally renders a truncated project name beside the repository badge. Tests cover board-card display and omission for sidebar cards and folder workspaces.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Linked Issues check ✅ Passed The implementation satisfies issue #13828 by showing project names on board cards in icon-only styles while leaving sidebar cards unchanged.
Out of Scope Changes check ✅ Passed The changes are limited to board project-name rendering, prop plumbing, presentation logic, and regression tests required by issue #13828.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Title check ✅ Passed The title clearly and concisely describes the main change: showing project names on Workspace board cards.
Description check ✅ Passed The description includes all required sections and clearly documents the change, testing, review, security audit, and platform considerations.

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 1


ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 87f2aa91-ed2f-4505-8214-1479eafce78b

📥 Commits

Reviewing files that changed from the base of the PR and between a0a654c and cb05b784e580781ece045b07815127efa479c979.

📒 Files selected for processing (6)
  • src/renderer/src/components/sidebar/WorkspaceKanbanCard.tsx
  • src/renderer/src/components/sidebar/WorktreeCard.project-name.test.tsx
  • src/renderer/src/components/sidebar/WorktreeCard.tsx
  • src/renderer/src/components/sidebar/worktree-card-header.tsx
  • src/renderer/src/components/sidebar/worktree-card-model.ts
  • src/renderer/src/components/sidebar/worktree-card-presentation.tsx

The folder-workspace case passed repo={undefined}, which short-circuits
at !!repo before the !isFolder guard runs — so it tested missing-repo
behavior, not folder behavior. Pass a repo with kind:'folder' so the
inline project label is gated off through the actual folder path.

Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
@PannenetsF

Copy link
Copy Markdown
Contributor Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Aug 11, 2026 •

Copy link
Copy Markdown
Contributor
⚠️ Action not completed

Already reviewed.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@PannenetsF
PannenetsF force-pushed the yq/lucid-poitras-5a53d1 branch from 07a0620 to 2bb584a Compare August 12, 2026 08:42
PannenetsF added a commit to PannenetsF/orca that referenced this pull request Aug 18, 2026
Extends the board fix (stablyai#13830) to the sidebar. When grouped by
workspace-status or pr-status (or ungrouped), cards from different
projects interleave in one group; in the new/compact card styles the
repo is an icon-only chip and the title falls back to the branch
(main/master for every primary), so cards are indistinguishable across
projects. Wire the existing showProjectName lever at the sidebar render
site for groupBy !== 'repo' (repo-grouped views use the group header).

Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
@PannenetsF

Copy link
Copy Markdown
Contributor Author

@brennanb2025 Gentle bump 🙏 — open ~7 days with no review yet. Could you take a look when you have a chance? Thanks!

@brennanb2025

Copy link
Copy Markdown
Contributor

Thanks for the contribution! This is covered by merged #28890: project names now appear on the shared cards used by the board, pinned workspaces and mixed-project sidebar lists. Closing this PR as superseded.

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.

Workspace board: project name not shown on cards without a session (all read as main/master)

4 participants