Repository navigation
Add and remove projects from the Add project dialog, as GitHub's repository picker does - #740
Merged
Merged
Conversation
lavaman131
force-pushed
the
feat/project-picker
branch
2 times, most recently
from
October 29, 2026 05:47
2d2ae13 to
76d8518
Compare
…sitory picker does The Add project dialog could only add: choosing a repository added it and closed the dialog, and one already added showed greyed out with nothing to do. Nothing anywhere could take a repository out of the Projects sidebar. The dialog now works like GitHub's multi-select repository picker (Primer's SelectPanel): each row is a checkbox and the repository's full name, projects listed first as it opens, and choosing a row (click, Enter or Space) adds or removes it at once. The list never reorders after a choice. It stays open for several changes and closes with Escape or a click outside. With no projects yet, the first one added still closes it, so a first run goes straight to creating a document. A row being changed shows a spinner in its checkbox; a failure restores it and says why. - Server: NavigationStore.removeProject (memory and PostgreSQL, one storage contract), and DELETE /api/navigation/projects/:repositoryId (same-origin, signed in, 204 or 404). Removing the repository of the last document forgets that document. Opening a document there adds the project back. - Web: PaletteListbox takes `checked`, set as aria-checked, while aria-selected keeps meaning the highlighted row. The checkbox is drawn as choice-control's, inside the option, so no control nests in another. The sidebar moves focus to a new project only when the dialog closes with it; while the dialog stays open it keeps focus. removeProject lives in the lazily loaded dialog, keeping the initial JavaScript within budget. - e2e/machine-choice.e2e.ts closes the dialog with Escape after its second and third projects, as it now stays open. Assistant-model: Claude Opus 5.5 (fast) Assistant-workflow: inline Assistant-verification: Chromium E2E passed: machine-choice, hosted, document-creation, auth-lifecycle, keyboard-shortcuts and shell suites (102 pass), and machine-choice's "creating projects" 8 of 8 with --repeat-each 4, which failed in CI before focus stayed in the open dialog Assistant-verification: bun test unit passed: apps/web/src (847 pass), src/navigation (10 pass), storage contract in memory and against postgres:17 Assistant-verification: typecheck, lint and build passed: bun run types, bun run ci, bun run build (initial JS 257905 B, under the 258000 B budget) User-preference: Model the project picker on GitHub's repository selection UI with checkboxes, and remove anything excessive Co-authored-by: Alex Lavaee <lavaman131@github.com>
lavaman131
force-pushed
the
feat/project-picker
branch
from
October 29, 2026 05:47
76d8518 to
a4d81b5
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Add project dialog could only add: choosing a repository added it and
closed the dialog, and one already added showed greyed out with nothing to
do. Nothing anywhere could take a repository out of the Projects sidebar.
The dialog now works like GitHub's multi-select repository picker (Primer's
SelectPanel): each row is a checkbox and the repository's full name,
projects listed first as it opens, and choosing a row (click, Enter or
Space) adds or removes it at once. The list never reorders after a choice.
It stays open for several changes and closes with Escape or a click
outside. With no projects yet, the first one added still closes it, so a
first run goes straight to creating a document. A row being changed shows
a spinner in its checkbox; a failure restores it and says why.
contract), and DELETE /api/navigation/projects/:repositoryId (same-origin,
signed in, 204 or 404). Removing the repository of the last document
forgets that document. Opening a document there adds the project back.
checked, set as aria-checked, whilearia-selected keeps meaning the highlighted row. The checkbox is drawn as
choice-control's, inside the option, so no control nests in another.
The sidebar moves focus to a new project only when the dialog closes
with it; while the dialog stays open it keeps focus. removeProject lives
in the lazily loaded dialog, keeping the initial JavaScript within budget.
and third projects, as it now stays open.
Assistant-model: Claude Opus 5.5 (fast)
Assistant-workflow: inline
Assistant-verification: Chromium E2E passed: machine-choice, hosted, document-creation, auth-lifecycle, keyboard-shortcuts and shell suites (102 pass), and machine-choice's "creating projects" 8 of 8 with --repeat-each 4, which failed in CI before focus stayed in the open dialog
Assistant-verification: bun test unit passed: apps/web/src (847 pass), src/navigation (10 pass), storage contract in memory and against postgres:17
Assistant-verification: typecheck, lint and build passed: bun run types, bun run ci, bun run build (initial JS 257905 B, under the 258000 B budget)
User-preference: Model the project picker on GitHub's repository selection UI with checkboxes, and remove anything excessive
Co-authored-by: Alex Lavaee lavaman131@github.com