Skip to content

refactor(app): share Home project actions and menus - #62850

Open
joe-ieta wants to merge 2 commits into
anomalyco:devfrom
joe-ieta:project-actions
Open

joe-ieta wants to merge 2 commits into
anomalyco:devfrom
joe-ieta:project-actions

Conversation

@joe-ieta

@joe-ieta joe-ieta commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor

Issue for this PR

Part 2 of the split requested in #60867; design context: #60241. Independent of the session-index PR #62845.

Type of change

  • Refactor / code improvement

What does this PR do?

Move Home's reusable project menu, actions, import state machine and directory helpers into shell/projects. Home, Side tabs and project settings now import the shared modules. Directory selection joins the existing actions controller with the same authentication and selection flow.

The visible menu and close behavior stay unchanged. The later Side bar change will reuse these actions.

How did you verify your code works?

On this branch alone: application typecheck, four import state-machine tests, ten Chromium Home/project regressions and bun run lint:changed upstream/dev. The combined follow-up passed the full 33-task check and 102 Home/tabs regressions.

Windows validation uses an equivalent temporary import for the repository's custom-elements.d.ts symlink; it is not committed. Upstream fork CI awaits maintainer workflow approval (action_required).

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

@opencodejr opencodejr 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.

This looks sound to me; I found nothing that should block it. I read through the moved modules and the new choose(). Its health check reads the same global.servers.health entry that home.server.health returned before. The empty-selection early return matches what the Home selection machine already did, and Home still adds projects through home.project.add. Nothing in src, e2e or test-browser still imports the old home/projects/* paths. tsc -b in packages/app passes, and the unit tests under src/shell/projects, src/home and consumers.test.ts pass (73/73).

The fallback in choose() that adds projects through addProjects when no callback is passed isn't used by anything in this PR, so its first caller in the follow-up PR will be what tests it.

Public API: unchanged; only internal module paths in packages/app move.

@opencodejr opencodejr 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.

The new commit only adds blank lines to satisfy the lint rules, so behaviour hasn't changed. I have nothing new to raise. The public API is unchanged.

@joe-ieta

joe-ieta commented Nov 9, 2026

Copy link
Copy Markdown
Contributor Author

Could a maintainer please approve the pending fork CI workflows for this PR? The required checks are waiting for approval (action_required); local validation is documented in the PR body. Thanks.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant