From c206e585aa915449ae32499a043ba5ba5a0e5f76 Mon Sep 17 00:00:00 2001 From: Shadman Taqi <61359614+iamshadmantaqi@users.noreply.github.com> Date: Thu, 26 Nov 2026 00:53:55 +0600 Subject: [PATCH 1/2] test(web): PR author profile links follow 'Open links in' --- .../PullRequestSummaryTab.browser.test.tsx | 32 +++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/apps/web/src/components/pullRequest/PullRequestSummaryTab.browser.test.tsx b/apps/web/src/components/pullRequest/PullRequestSummaryTab.browser.test.tsx index a74b8f716604f..6d7c4f39267a5 100644 --- a/apps/web/src/components/pullRequest/PullRequestSummaryTab.browser.test.tsx +++ b/apps/web/src/components/pullRequest/PullRequestSummaryTab.browser.test.tsx @@ -394,3 +394,35 @@ it("opens comment timestamps through the link-target setting, not a popup", asyn localStorage.removeItem("t3code:pull-request-comment-filter:v1"); } }); + +it("opens a comment author's profile through the link-target setting, not a popup", async () => { + setup(); + await using screen = await render({ + ...detail, + comments: [ + { + id: "1", + kind: "issue-comment" as const, + body: "Looks good", + author: { login: "reviewer", name: null, avatarUrl: null }, + createdAt: "2026-09-01T00:00:00Z", + url: null, + path: null, + reviewState: null, + }, + ], + commentCount: 1, + }); + const link = await vi.waitFor(() => { + const found = screen.container.querySelector('a[aria-label="Open reviewer\'s profile"]'); + expect(found).not.toBeNull(); + return found!; + }); + const href = link.getAttribute("href")!; + const click = new MouseEvent("click", { bubbles: true, cancelable: true }); + link.dispatchEvent(click); + + expect(click.defaultPrevented).toBe(true); + expect(state.openLink).toHaveBeenCalledOnce(); + expect(state.openLink).toHaveBeenCalledWith(href, { event: expect.anything() }); +}); From 53cf260882b4d5f6e0fed1df601293927657df42 Mon Sep 17 00:00:00 2001 From: Shadman Taqi <61359614+iamshadmantaqi@users.noreply.github.com> Date: Thu, 26 Nov 2026 00:54:28 +0600 Subject: [PATCH 2/2] fix(web): PR author profile links honor 'Open links in' --- .../components/pullRequest/PullRequestDetailPanel.tsx | 7 ++++++- .../src/components/pullRequest/PullRequestSummaryTab.tsx | 7 ++++++- .../components/pullRequest/pullRequestPresentation.tsx | 9 +++++++++ 3 files changed, 21 insertions(+), 2 deletions(-) diff --git a/apps/web/src/components/pullRequest/PullRequestDetailPanel.tsx b/apps/web/src/components/pullRequest/PullRequestDetailPanel.tsx index 5678533a97ebc..1a6d4bbb5d8f8 100644 --- a/apps/web/src/components/pullRequest/PullRequestDetailPanel.tsx +++ b/apps/web/src/components/pullRequest/PullRequestDetailPanel.tsx @@ -1787,6 +1787,7 @@ export function PullRequestDetailPanel({ @@ -1882,7 +1883,11 @@ export function PullRequestDetailPanel({ /> } author={ - + } updated={ diff --git a/apps/web/src/components/pullRequest/PullRequestSummaryTab.tsx b/apps/web/src/components/pullRequest/PullRequestSummaryTab.tsx index 5df3b61feece4..f8b19eee80def 100644 --- a/apps/web/src/components/pullRequest/PullRequestSummaryTab.tsx +++ b/apps/web/src/components/pullRequest/PullRequestSummaryTab.tsx @@ -135,7 +135,12 @@ function CommentIdentity({ : null; return (

- + @@ -529,6 +534,10 @@ export function PullRequestActorLabel({ aria-label={gt("Open {login}'s profile", { login })} /> } + onClick={(event) => { + event.preventDefault(); + void openLink(profileUrl, { event }).catch(console.error); + }} /> ) : (