Skip to content

fix: disable non-current projects in switcher when NAO_DEFAULT_PROJECT_PATH is set#1177

Open
Nithishvb wants to merge 1 commit into
getnao:mainfrom
Nithishvb:fix/disable-project-switcher
Open

fix: disable non-current projects in switcher when NAO_DEFAULT_PROJECT_PATH is set#1177
Nithishvb wants to merge 1 commit into
getnao:mainfrom
Nithishvb:fix/disable-project-switcher

Conversation

@Nithishvb

@Nithishvb Nithishvb commented Jul 13, 2026

Copy link
Copy Markdown

Closes: #1172

When self-hosting with NAO_DEFAULT_PROJECT_PATH set, the project switcher in settings silently ignored user selections — clicking a different project did nothing with no feedback.

## Changes

  • Backend (system.routes.ts): Exposed hasDefaultProjectPath in the getPublicConfig endpoint so the frontend knows when the env var is set.
  • Frontend (project-selector.tsx): Added optional disabledProjectIds prop to ProjectSelector. When provided, matching items are rendered with Radix's native disabled attribute (greyed out, not clickable).
  • Frontend (sidebar-settings-nav.tsx): Computes disabledProjectIds from the isProjectPinned flag and passes it to ProjectSelector.
  • Frontend (sidebar.tsx): Derives isProjectPinned from config (!isCloud && hasDefaultProjectPath) and threads it to the settings nav.

Now the dropdown remains openable so users can see all projects, but non-current entries are visibly disabled with no interaction possible — making the constraint obvious instead of silently doing nothing

Review in cubic

@github-actions

Copy link
Copy Markdown
Contributor

This PR was auto-closed. Only contributors approved with lgtm can open PRs. Open an issue first.

Maintainers review auto-closed issues daily. Issues that do not meet the quality bar in CONTRIBUTING.md will not be reopened or receive a reply.

If a maintainer replies lgtmi, your future issues will stay open. If a maintainer replies lgtm, your future issues and PRs will stay open.

See CONTRIBUTING.md.

@github-actions github-actions Bot closed this Jul 13, 2026
@Bl3f Bl3f reopened this Jul 15, 2026
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.

[bug] Project switcher in settings / chat interface does not work

2 participants