feat(desktop): search branch selector by PR number (#PR)#95
Merged
Conversation
added 6 commits
July 1, 2026 09:37
Design spec and implementation plan for this feature live locally under docs/superpowers/ (gitignored, not tracked here) — see the PR description.
Vue's ref() deep-wraps object array elements in reactive Proxies, so prs.value never returns the original raw object — toBe (Object.is) can never pass there. Revert the prCache workaround that didn't fix this, and fix the actual test assertion instead.
A component unmounting mid-debounce (or mid-fetch) left the setTimeout callback armed, so it could still fire forge.getPR() against a stale cwd and write to refs after the owning composable instance was gone. onScopeDispose now clears the timer alongside the existing watch-triggered clearTimeout.
Nest the pull request badge inside the branch name span and add a left margin to ensure the badge stays correctly aligned and spaced. 🪄 Commit via GitWand
t1gu1
approved these changes
Jul 2, 2026
t1gu1
left a comment
Collaborator
There was a problem hiding this comment.
Oh nice feature!
I simply move the tag to be align at the right of the branch name instead of being near of the actions buttons.
Show pull request badges next to branch/remote refs and allow searching commits by PR number to help users find and track work associated with active pull requests. 🪄 Commit via GitWand
Collaborator
Collaborator
|
I found a bug where the PR numbers didn't appear if we didn't go in the PR view first. |
Fetch the PR list (once, SWR, no polling) when entering the graph view or opening the branch selector. This displays PR number badges on branches without requiring the user to first open the PR panel. 🪄 Commit via GitWand
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.


Summary
#<PR number>(e.g.#9335) to the branch that PR is on and jump straight to it — GitHub Desktop-style.forge.getPR()call for PR numbers outside the currently-loaded page, so old/unloaded PRs are still found.#93never matches#9335).#1234badge (Pinned/Local/Remote sections), sourced only from the cache — never triggers a fetch on its own.useBranchPrSearchcomposable +BranchSelector.vuewiring + i18n across all 5 locales. No backend/Tauri changes.Test plan
useBranchPrSearchcomposable: 9/9 unit tests passing (cache hit, debounced fallback fetch, rejection/"not found",origin/prefix stripping, debounce collapsing rapid keystrokes, scope-dispose timer cleanup)vue-tsc --noEmitcleanpnpm vitest run— 345/345 tests passingpnpm dev:webpass against the live repo (realghCLI): cache-hit search, badges on real branches, fallback-fetch search with a real 500 caught cleanly, exact-match-only probe, plain-text search regression check