Repository navigation
Conversation
Modified clicks fell through to the in-app preview when links were set to open in T3 Code, unlike Meta, Ctrl and middle clicks. Co-authored-by: iamshadmantaqi <61359614+iamshadmantaqi@users.noreply.github.com>
ApprovabilityVerdict: Approved at Macroscope's review found this PR approvable — Shift- and Alt-clicks now use the existing system-browser routing instead of opening the in-app preview. Ordinary clicks and saved link-opening preferences remain unchanged, keeping the impact narrow. You can add or adjust custom eligibility rules. Learn more. |
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
The scenario rewrote the tracked command-output replay fixture in place, which leaves the checkout dirty if the run dies. Seed a replay agent and transcript into the scenario project instead, like other ACP scenarios. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The automated pipeline stopped on this pull request and will not merge it: someone else pushed to fix/chat-link-shift-alt (head is now 0962daf); the pipeline does not build on commits it did not review It stays open for a person to finish or close. |
0962daf to
4cb6f61
Compare
Problem
With Open links in set to T3 Code (the in-app browser), Shift-clicking or Alt-clicking an ordinary https link in a chat message still opens the in-app preview and cancels the click. Meta-click, Ctrl-click, and middle-click already stay with the browser, so Shift and Alt are inconsistent: try Shift-click on a link such as
https://example.com/in an assistant message and the preview opens instead of the click going through.Change
resolveLinkTargetinapps/web/src/browser/browserLinkTarget.tsnow treatsshiftKeyandaltKeylikemetaKeyandctrlKey, returning"system"so the click is left to the browser. The two keys are optional fields on the input event; chat and web-search callers already pass the real mouse event, so no caller changes are needed. A plain click still returns"app"and opens the preview.The regression scenario from the proof below is committed as
scripts/scenarios/chat-link-modifiers.e2e.ts.Scope and approval
Small fix for an obvious bug; no issue needed. This is the ordinary-link case left over after #47226 fixed pull request links and #47144 fixed issue links the same way. It re-lands the behavior from the closed #47262, whose author is credited as co-author on the fix commit.
Verification
vp test run apps/web/src/browser/browserLinkTarget.test.ts— the new Shift/Alt cases failed on base withexpected 'app' to be 'system'. All 2 tests pass with the fix.vp run scenarios:prove scripts/scenarios/chat-link-modifiers.e2e.ts --base upstream/main— exit 0. The scenario sets Open links in to the in-app browser (the settings control is desktop-only, so it seeds the stored web preference), then Shift-clicks, Alt-clicks, and plain-clicks an https link in a chat message. It failed on basee95cb8114dand passes on head3db0a9741a. Upstream has since moved to3b747f3260without touching these files, and the bug is still present there.e95cb8114d3db0a9741avp run check:changed upstream/main— exit 0. Format, lint, Knip, typecheck (2 packages), the focused test, and React Compiler passed.Not shown — Electron IPC, the desktop Alt-click handling after a non-app result (unchanged), and the operating system's response after the click falls through.
Muse Wonder Full via Cursor in T3 Code