Skip to content

feat(desktop): clean up the workspaces board cards - #7150

Merged
Kitenite merged 3 commits into
mainfrom
board-card-cleanup
Sep 3, 2026
Merged

Kitenite merged 3 commits into
mainfrom
board-card-cleanup

Conversation

@Kitenite

@Kitenite Kitenite commented Sep 3, 2026 •

Copy link
Copy Markdown
Member

Follows #7142 (merged). Replaces #7146, which GitHub closed when that PR's base branch was deleted on merge; this is the same three commits rebased onto main, with the card's Lingui calls updated to the English-text-as-id convention from #7092.

What changed

The board cards were carrying a lot of repeated chrome: "This device" on every local card, the branch name printed under a title that was already the branch name, and unstyled metadata. This reworks the card after Linear's board anatomy (checked on Mobbin) while keeping the page's existing vocabulary.

Card

  • Muted project line at the top: project icon, project name, a laptop mark on main checkouts (same tooltip as the list row). The host chip only appears for remote devices.
  • State glyph beside a medium-weight title. This is the same WorkspaceStateGlyph the list row uses, so the green review dot, the working spinner, and the column pies read the same on both layouts.
  • Branch line only when it says something the title doesn't (the list row's rule): hidden for sessions and when branch and name match.
  • Footer of outlined pills: PR number with checks dot, +adds −dels churn when present, Merged/Deleted for tombstones, with the activity age on the right. Age now tracks activity like the list, not creation.
  • Done states (merged PR, archived) recede to muted text.

Column

  • Lanes get a surface one step above the page (bg-muted/30) with the header inside, so cards read as items in a column. Card gap 8px, lane gap 12px. Works in both themes: page < lane < card.

Refactor commit: WorkspaceStateGlyph moves from the row's private folder up to v2-workspaces/components since two components share it now.

Checks

  • bun run typecheck (apps/desktop): exit 0
  • bun test for the workspaces page directory: 17 pass
  • bun run check:i18n: exit 0, no catalog changes. The card reuses the row's existing ids, so no new strings.
  • Rendered in the dev app over CDP; screenshots in the session.

A later commit moves the age to the header's right slot and the state glyph to the footer's right slot, and widens the card inset to 14/12px.

https://claude.ai/code/session_01BjVLqU1kEE6SQqKSYem9ax


Summary by cubic

Reworks the workspaces board cards and columns after Linear's board anatomy so cards read as items in a lane and drop repeated chrome like "This device" and the redundant branch line.

What changed

  • Cards show a muted project line, state glyph beside the title, and outlined pills for PR, diff churn, and archive state.
  • Branch line only appears when it says something the title doesn't; age tracks last activity like the list row, not creation.
  • Done states (merged PR, archived) recede to muted text; columns get a surface one step above the page.
  • WorkspaceStateGlyph moves up to v2-workspaces/components since the card and list row share it.

Written for commit d76d229. Summary will update on new commits.

Review in cubic

… components

The board card is about to share the list row's state glyph, so it moves
from the row's private components folder up to the highest shared parent.
No behaviour change.

Claude-Session: https://claude.ai/code/session_01BjVLqU1kEE6SQqKSYem9ax
Rework the board card after Linear's board anatomy: a muted project line,
the state glyph beside a medium-weight title, a branch line only when it
says something the title doesn't (the list row's rule), and outlined
property pills for PR, diff churn and archive state with the activity age
on the right. Columns get a surface one step above the page so cards read
as items in a lane. "This device" no longer repeats on every local card.

WorkspaceStateGlyph moves up to v2-workspaces/components since the board
card and the list row now share it.

No new i18n strings: the card reuses the row's existing ids.

Claude-Session: https://claude.ai/code/session_01BjVLqU1kEE6SQqKSYem9ax
…age to the header

Age sits top right beside the project line, the state glyph takes the
footer's right slot after the pills, and the card inset grows to 14/12px.
The title and branch line lose their leading glyph indent.

Claude-Session: https://claude.ai/code/session_01BjVLqU1kEE6SQqKSYem9ax
@coderabbitai

coderabbitai Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

Next included review available in 5 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 10 included reviews currently available.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Team

Run ID: e58a55eb-42f6-4b42-9d7e-cf9d3149a607

📥 Commits

Reviewing files that changed from the base of the PR and between 3141507 and d76d229.

📒 Files selected for processing (6)
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspaces/components/V2WorkspacesBoard/V2WorkspacesBoard.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspaces/components/V2WorkspacesBoard/components/V2WorkspacesBoardCard/V2WorkspacesBoardCard.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspaces/components/V2WorkspacesBoard/components/V2WorkspacesBoardColumn/V2WorkspacesBoardColumn.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspaces/components/V2WorkspacesList/components/V2WorkspaceRow/V2WorkspaceRow.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspaces/components/WorkspaceStateGlyph/WorkspaceStateGlyph.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspaces/components/WorkspaceStateGlyph/index.ts

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.

@greptile-apps

greptile-apps Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

The PR simplifies desktop workspace board cards and aligns their status, branch, activity, and diff metadata with the list layout.

  • Adds project, host, activity, pull-request, churn, archive, and workspace-state treatments to board cards.
  • Restyles board lanes and spacing to distinguish columns from cards.
  • Moves WorkspaceStateGlyph to a shared component directory for board and list reuse.

Confidence Score: 5/5

The PR appears safe to merge, with no concrete blocking or independently actionable non-blocking issue identified.

The presentation changes preserve the list layout’s branch and status semantics, and the shared glyph remains total over the supported workspace states.

Important Files Changed

Filename Overview
apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspaces/components/V2WorkspacesBoard/components/V2WorkspacesBoardCard/V2WorkspacesBoardCard.tsx Reworks card metadata and status presentation; no actionable correctness issue was established.
apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspaces/components/V2WorkspacesBoard/components/V2WorkspacesBoardColumn/V2WorkspacesBoardColumn.tsx Applies lane surface, spacing, and typography changes without altering board behavior.
apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspaces/components/V2WorkspacesList/components/V2WorkspaceRow/V2WorkspaceRow.tsx Updates the state-glyph import to its shared location.
apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspaces/components/WorkspaceStateGlyph/WorkspaceStateGlyph.tsx Relocates the existing state glyph unchanged for reuse by both layouts.

Reviews (1): Last reviewed commit: "feat(desktop): move the board card's sta..." | Re-trigger Greptile

@cubic-dev-ai cubic-dev-ai 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.

1 issue found across 6 files

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspaces/components/V2WorkspacesBoard/components/V2WorkspacesBoardCard/V2WorkspacesBoardCard.tsx">

<violation number="1" location="apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspaces/components/V2WorkspacesBoard/components/V2WorkspacesBoardCard/V2WorkspacesBoardCard.tsx:38">
P3: The board adds a second `formatCount` implementation identical to the list row’s helper. Extract this formatter into a shared utility and import it in both surfaces so churn formatting cannot drift.</violation>
</file>
Architecture diagram
sequenceDiagram
    participant User as Desktop User
    participant Board as Workspaces Board
    participant Columns as Board Columns
    participant Card as Board Card
    participant List as Workspaces List Row
    participant Data as Accessible Workspaces Hook
    participant Utils as Workspace Utilities
    participant Shared as Workspace State Glyph
    participant Menu as Workspace Context Menu

    Note over Board,Data: Current-state desktop workspace rendering

    Board->>Data: Request accessible workspaces
    Data-->>Board: Workspace records and visible columns
    Board->>Columns: Render columns with workspace groups
    Columns->>Columns: Apply lane surface, spacing, and counts

    loop For each workspace in a column
        Columns->>Card: Render workspace data
        Card->>Utils: Compute activity timestamp
        Utils-->>Card: Relative activity age
        Card->>Shared: Render workspace state
        Shared-->>Card: Review, working, or column state glyph

        alt Main workspace
            Card->>Card: Show project icon and main-workspace laptop tooltip
        else Remote workspace
            Card->>Card: Show project icon, monitor icon, and host name
        else Local non-main workspace
            Card->>Card: Show project icon only
        end

        alt Branch differs from workspace name and workspace is not a session
            Card->>Card: Show branch metadata line
        else Branch is redundant or workspace is a session
            Card->>Card: Omit branch metadata line
        end

        alt Pull request exists
            Card->>Card: Show PR number and checks status
        end

        alt Diff statistics contain changes
            Card->>Card: Show formatted additions and deletions
        end

        alt Workspace is merged or archived
            Card->>Card: Show terminal status and muted title
        end
    end

    Board->>List: Render list layout from the same workspace records
    List->>Utils: Compute activity timestamp
    Utils-->>List: Relative activity age
    List->>Shared: Render the same workspace state glyph
    Shared-->>List: Consistent state indicator

    User->>Card: Click workspace
    alt Workspace is active
        Card->>Card: Invoke open handler
        Card-->>User: Open workspace
    else Workspace is archived
        Card->>Card: Keep card disabled
    end

    User->>Card: Open context menu
    Card->>Menu: Provide workspace and action handlers
    Menu-->>User: Show workspace actions
Loading

Reply with feedback, questions, or to request a fix.

Re-trigger cubic

}

/** 181909 → "181.9k" — keeps outlier churn from blowing out the pill. */
function formatCount(count: number): string {

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.

P3: The board adds a second formatCount implementation identical to the list row’s helper. Extract this formatter into a shared utility and import it in both surfaces so churn formatting cannot drift.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspaces/components/V2WorkspacesBoard/components/V2WorkspacesBoardCard/V2WorkspacesBoardCard.tsx, line 38:

<comment>The board adds a second `formatCount` implementation identical to the list row’s helper. Extract this formatter into a shared utility and import it in both surfaces so churn formatting cannot drift.</comment>

<file context>
@@ -30,6 +34,15 @@ export function V2WorkspacesBoardCard({
 }
 
+/** 181909 → "181.9k" — keeps outlier churn from blowing out the pill. */
+function formatCount(count: number): string {
+	if (count < 10_000) return String(count);
+	return `${(count / 1000).toFixed(1).replace(/\.0$/, "")}k`;
</file context>

@Kitenite
Kitenite merged commit 9fc7c1b into main Sep 3, 2026
13 checks passed
@Kitenite
Kitenite deleted the board-card-cleanup branch September 3, 2026 23:59
@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

🧹 Preview Cleanup Complete

The following preview resources have been cleaned up:

  • ⚠️ Neon database branch

Thank you for your contribution! 🎉

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.

1 participant