Conversation
Replace the mock Diff tab with a singleton Review panel that lists the working tree versus merge-base(HEAD, default) — PR-style three-dot review — and previews each file with Pierre. On the default branch the base is HEAD, so only uncommitted work is shown.
|
React Doctor found 4 issues in 4 files · 4 warnings · score 87 / 100 (Great) · full project 4 warnings
Reviewed by React Doctor for commit |
Review now switches among uncommitted, committed three-dot, and vs-branch (including remote-tracking refs), shows the full workspace tree with git badges, and stacks collapsible Pierre diffs that the tree can locate.
Local branches like feature/oauth were landing in the Remote group because the toolbar split on `/`. git.branch now returns remotes separately so the select can keep origin/main remote without mislabeling slashed local names.
alignItemWithTrigger scrolled the vs-branch menu to origin/main and clipped the Remote group. Open below the trigger so Local and origin/main are both on screen without scrolling.
GitService is on the serve path, so tsdown inlines simple-git into the CLI. deps.onlyBundle fails closed; list simple-git and its tree so Code check can build @vibest/cli.
Mode and branch triggers now match the project picker: transparent, no shadow, hover accent. The header already uses a ghost refresh button.
Coss SelectTrigger hard-codes ChevronsUpDown. Render the same ghost Button chrome as the harness picker so compare mode and vs-branch use ChevronDown.
Resolve the server public-slice conflict by keeping main's removal of HarnessAgentDomainLayer (GitService stays on AgentRuntimeLayer). Point the review panel at content-panel/model after the core rename.
Keep this branch's git contract (status/review/diff plus remotes) so Review still works; composer only reads branch.current. Wire pty next to git, point the shell at features/terminal, and leave the mock Diff panel out — Review replaces it.
@effect/vitest layer({ timeout }) only covers hooks, so spawn tests still
hit vitest's 5s default while turbo runs build/test/typecheck together.
Raise the package testTimeout to 30s and poll for stop tombstones instead
of sleeping 100ms.
| }, | ||
| }); | ||
|
|
||
| function ReviewPanelView({ instance }: { instance: PanelHandle<ReviewPayload> }) { |
There was a problem hiding this comment.
React Doctor · react-doctor/no-high-complexity-react-function (warning)
ReviewPanelView has cyclomatic complexity 24, cognitive complexity 19, and maximum nesting depth 1, so its React logic is hard to understand and change. Extract independent branches into components or hooks.
Fix → Extract independent render branches and state logic into focused components or hooks until the control flow is easy to follow.
Replace the mock Diff tab with a singleton Review panel: full workspace tree, stacked collapsible diffs, and explicit compare modes.
Compare modes
HEAD, including untracked filesorigin/mainwhenorigin/HEADexists), ignoring the dirty worktreeorigin/main, …), including uncommitted work. Nogit fetch— uses refs already on diskUnknown
otherrefs returnREF_NOT_FOUND.git.branchlistsrefs/headsandrefs/remoteswithout strippingorigin/, and returnsremotesseparately so the vs-branch select can group Local vs Remote without treating slashed local names (feature/oauth) as remotes.Layout
CodeViewstacked diffs, file headers on, click a header to collapse/expandFileTreeof the whole workspace (fs.readTree) plus deleted review paths, with git-status badges. Click a changed file to scroll the stack to itfeatures/reviewcopies the Files tree adapter pattern and does not importfeatures/files.Surface
git.review/git.difftake{ cwd, mode?, other?, path? }{ mode?, other?, path? }. Collapse state is live-onlyVerify
turbo test typecheckfor@vibest/contract,@vibest/server,@vibest/app;pnpm lint:check;pnpm format:check; react-doctor 100.Acceptance walkthrough (demo repo on
feature/oauthwithorigin/mainalready on disk):review-panel-v2-acceptance.mp4
To show artifacts inline, enable in settings.