feat: add PR link to CI status popover header (#1200)

This commit is contained in:
Carlos Florêncio
2026-05-31 18:43:43 +01:00
committed by GitHub
parent d76836d740
commit 4f852b7a5c
2 changed files with 29 additions and 11 deletions
+24 -11
View File
@@ -84,17 +84,30 @@ function PRCIPopoverHeader({ pr }: { pr: TaskPR }) {
className="flex items-center justify-between gap-2 border-b border-border/50 pb-2"
>
<span className="text-sm font-medium">CI status</span>
<a
data-testid="pr-popover-external-link"
href={checksUrl}
target="_blank"
rel="noopener noreferrer"
className="cursor-pointer text-muted-foreground hover:text-foreground"
aria-label="View all checks on GitHub"
onClick={(e) => e.stopPropagation()}
>
<IconExternalLink className="h-3.5 w-3.5" />
</a>
<div className="flex items-center gap-1.5">
<a
data-testid="pr-popover-pr-link"
href={pr.pr_url}
target="_blank"
rel="noopener noreferrer"
className="cursor-pointer text-muted-foreground hover:text-foreground"
aria-label="View pull request on GitHub"
onClick={(e) => e.stopPropagation()}
>
<IconGitPullRequest className="h-3.5 w-3.5" />
</a>
<a
data-testid="pr-popover-external-link"
href={checksUrl}
target="_blank"
rel="noopener noreferrer"
className="cursor-pointer text-muted-foreground hover:text-foreground"
aria-label="View all checks on GitHub"
onClick={(e) => e.stopPropagation()}
>
<IconExternalLink className="h-3.5 w-3.5" />
</a>
</div>
</div>
);
}
+5
View File
@@ -583,6 +583,11 @@ export class SessionPage {
return this.prTopbarPopover().getByTestId("pr-comments-row");
}
/** Header PR-link icon (top-right corner of the popover). */
prPopoverPRLink(): Locator {
return this.prTopbarPopover().getByTestId("pr-popover-pr-link");
}
/** Header external-link icon (top-right corner of the popover). */
prPopoverExternalLink(): Locator {
return this.prTopbarPopover().getByTestId("pr-popover-external-link");