Skip to content

fix(desktop): keep Create controls on empty Projects (#4009) - #4052

Open
iroiro147 wants to merge 1 commit into
block:mainfrom
iroiro147:claude/issue4009-20260801
Open

fix(desktop): keep Create controls on empty Projects (#4009)#4052
iroiro147 wants to merge 1 commit into
block:mainfrom
iroiro147:claude/issue4009-20260801

Conversation

@iroiro147

Copy link
Copy Markdown

Summary

Fixes #4009.

When the Projects view had no visible projects it returned <EmptyState /> before the PageHeader, toolbar, and ProjectsCreateMenu mounted — so the Create menu was missing and there was no way to create the first project from the empty view.

Approach

Reimplements the approach from the closed PR #3620 (which the issue body points to), adapted to current main:

  • Remove the projects.length === 0 early return in ProjectsView.tsx; the main content section now renders the empty state inside the page chrome, so the header, toolbar, and + Create menu stay mounted.
  • EmptyState gains an optional onCreateRepository callback that renders a Create repository CTA button opening the create-project dialog.
  • Both entry points (toolbar Create menu → Repository, empty-state button) open the same CreateProjectDialog.

Test coverage

  • typecheck (tsc --noEmit) — clean
  • biome check on all touched files — clean
  • New Playwright smoke spec tests/e2e/projects-empty-create.spec.ts covering the empty Projects view and both Create entry points — passes (1 passed)

Notes

This is intentionally scoped to the empty-list Create-controls fix. The related "deleted + re-announced projects remain missing" behavior noted in the issue is a separate relay/query concern and is not changed here.

The Projects view returned its empty state before the PageHeader, toolbar,
and ProjectsCreateMenu mounted, leaving no way to create the first project
from an empty workspace.

- Drop the projects.length === 0 early return; the main section now renders
  the empty state inside the page chrome so the Create menu stays mounted.
- EmptyState gains an optional onCreateRepository CTA that opens the
  create-project dialog directly.
- Covers both entry points (toolbar Create menu, empty-state button) with a
  Playwright smoke spec.

Reimplements the approach from the closed PR block#3620, tracked in block#4009.

Signed-off-by: iroiro147 <sarthak.singh@juspay.in>
@hamza-imran75

Copy link
Copy Markdown

+1 I'm hitting this exact issue on a fresh relay too. After enabling Projects, the empty Projects page only shows “No projects yet” and provides no + menu or other way to create the first repository from the Desktop UI.

I've seen usage of Projects on X and would like to use it myself as well, looking forward to seeing this PR land :)

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.

Projects view hides Create controls when no projects are visible

2 participants