fix(app): restore review line comments#33481
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Restores inline review line-comment creation in the app’s diff viewer by aligning the UI integration with Pierre’s gutter-utility API, ensuring completed line selections consistently open a comment draft, and adding regression coverage for the previously broken interactions.
Changes:
- Switch diff viewers from the old hover-utility API to Pierre’s gutter-utility API (
enableGutterUtility/renderGutterUtility). - Simplify line-comment controller flow so all completed selections open drafts via
onLineSelectionEnd, removing the separate line-number completion path. - Add Playwright regression coverage (click code, click gutter, drag gutter range, hover gutter “Comment” button) and extend the e2e mock server to serve
/vcs/diff.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| packages/ui/src/components/session-review.tsx | Updates review diff viewer wiring to use gutter utility props and renderer. |
| packages/ui/src/components/line-comment-annotations.tsx | Refactors line-comment controller to open drafts on selection end and renames hover renderer to gutter renderer. |
| packages/app/src/pages/session/file-tabs.tsx | Updates the file tab diff/text viewer wiring to use gutter utility props and renderer. |
| packages/app/e2e/utils/mock-server.ts | Adds optional /vcs/diff response support for e2e tests. |
| packages/app/e2e/regression/review-line-comment.spec.ts | Adds Chromium regression tests covering restored inline comment interactions. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
markjaquith
pushed a commit
to markjaquith/opencode
that referenced
this pull request
Jun 23, 2026
|
Thanks for the fix here! I just wanted to make an MR to bring inline comments back |
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
Closes #32835.
Rationale
Comment creation is a policy of the line-comment controller, so all completed selections follow one path:
onLineSelectionEndopens the draft. The file viewer remains responsible only for reporting selections. Pierre requiresenableGutterUtilityandrenderGutterUtilityfor the hover action, so the internal naming now matches that API.Verification
upstream/dev: all four new Playwright cases failbun typecheckinpackages/uibun typecheckinpackages/appgit diff --check