Skip to content

feat(web): open PRs, inline comments, the review fold, and forks - #58

Merged
PastaPastaPasta merged 2 commits into
masterfrom
feat/web-launch-ux-c1
Sep 27, 2026
Merged

PastaPastaPasta merged 2 commits into
masterfrom
feat/web-launch-ux-c1

Conversation

@PastaPastaPasta

Copy link
Copy Markdown
Owner

What

Web launch UX "C1": open pull requests from the browser, review them inline, see the review fold, and fork repos. forge-v2 only. The browser merge engine is a separate PR (C2).

  • Open a PR (/repo/pulls/new): pick the base branch and a source (this repo or one of its forks, then a branch). The diff is shown before you submit. createPatch writes the patch exactly as forge-core patch_props does, and numbering shares createNumbered (renumbers on a squat) with issues. A signed-out draft survives the sign-in sheet.
  • Diff view: side-by-side at ≥ 1024 px, unified below that. There is a whitespace toggle and a blue/orange palette as a colour-blind option; both palettes pass WCAG AA in contrast.test.ts. Preferences live in Settings, with an in-memory fallback when localStorage is unavailable.
  • Inline comments on the new review-parity contract (feat(core,web): review parity rules, vectors and writers #56): the composer writes path/line/side/commitOid through postComment/anchorData, and toCommentView reads them back with anchorOf.
    • The <!-- forge-anchor --> body block is gone, as the spec requires.
    • Threads on the current head sit under their line, and a startLine range sits under its last line. File-level anchors are listed as "File comments", and threads whose line is off screen are listed above the diff. Threads on an older head or a vanished line collapse into "n comments on an older version".
  • Review comments (reviewId) nest under their review in the timeline via groupReviewComments, which only groups the reviewer's own comments. When fewer than the announced commentCount have landed, the timeline says "n of m comments have landed".
  • Review fold header: the countApprovals result shown exactly (counted approvals by role, change requests), plus every other reviewer's standing: stale on an older head, doesn't count (not a member), or author approval. Dismissed reviews neither count nor show, matching the fold.
  • Fork: a web Fork button that mirrors dg fork / fork.rs. It creates the repo with forkOf, adds the maintainer and config, writes the pack manifests by reference to the parent's packs (platform://…; s3 URIs dropped, 8 × 300 limits), and copies the refs. It is resumable through the creation journal, shows "forked from" in the header, and runs a name check before signing.
  • The ref-update and pack-manifest writers (writeRefUpdate, refNameHash, refUpdateType) are shared with C2.

Checks

  • On master d14fe57: pnpm typecheck, pnpm lint, pnpm test (1158 passed) and pnpm build all pass.
  • The live moutai suite e2e/v2-pulls.spec.ts c1–c6 passed 6/6 against the new forge-collab contract. It creates a repo, forks the fixture, opens a PR from the fork, keeps a signed-out draft, has a writer comment inline and request changes, has the owner approve (fold, split diff, palette, mobile layout), and runs axe. c7 (the browser merge) comes with C2.

🤖 Generated with Claude Code

PastaPastaPasta and others added 2 commits September 27, 2026 04:09
… comments

The review-parity contract (#56) stores anchors in comment fields only: the forge-anchor body block and the readAnchor adapter are gone. Comments are read with anchorOf (ranges placed under their last line, file-level anchors listed as File comments), posted with postComment, and a review's own comments nest under it in the timeline (groupReviewComments). Dismissed reviews drop out of the review summary as they do from the fold.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
@coderabbitai

coderabbitai Bot commented Sep 27, 2026

Copy link
Copy Markdown

Warning

Review limit reached

Next included review available in 27 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Advanced

Run ID: e800b1f0-c7c1-421e-a09d-a6311448145d

📥 Commits

Reviewing files that changed from the base of the PR and between d14fe57 and 52f4213.

📒 Files selected for processing (30)
  • docs/design/ux-dx-spec.md
  • forge-web/app/repo/pulls/new/client.tsx
  • forge-web/app/repo/pulls/new/page.tsx
  • forge-web/app/settings/page.tsx
  • forge-web/components/display-prefs-panel.tsx
  • forge-web/components/repo/approvals.tsx
  • forge-web/components/repo/diff-view.tsx
  • forge-web/components/repo/fork-button.tsx
  • forge-web/components/repo/inline-comments.tsx
  • forge-web/components/repo/new-pull-content.tsx
  • forge-web/components/repo/pull-content.tsx
  • forge-web/components/repo/pull-diff.tsx
  • forge-web/components/repo/pulls-content.tsx
  • forge-web/components/repo/repo-header.tsx
  • forge-web/components/repo/timeline.tsx
  • forge-web/e2e/v2-pulls.spec.ts
  • forge-web/hooks/use-prefs.ts
  • forge-web/lib/design/contrast.test.ts
  • forge-web/lib/repo/fork.test.ts
  • forge-web/lib/repo/fork.ts
  • forge-web/lib/repo/index.ts
  • forge-web/lib/repo/pulls.test.ts
  • forge-web/lib/repo/push.ts
  • forge-web/lib/repo/writes.ts
  • forge-web/lib/view/file-diff.ts
  • forge-web/lib/view/inline-threads.ts
  • forge-web/lib/view/issues-view.ts
  • forge-web/lib/view/prefs.ts
  • forge-web/lib/view/review-fold.ts
  • forge-web/lib/view/text-diff.ts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

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.

1 participant