fix(web): let the pull request list use wide screens (#9351)

Co-authored-by: Claude Code <[email protected]>
This commit is contained in:
Julius MarmingeandClaude Code authored and GitHub committed 2026-09-02 22:31:45 -07:00
1 parent 1575ada305
commit 0bc59bbae3
2 files changed
+39 -12

No files matched your search

@@ -16,19 +16,46 @@ import {
PullRequestStateGlyph,
} from "./pullRequestPresentation";
/**
* Each slot past the first only appears once the meta line is wide enough to hold it, so a
* narrow row shows one label and a "+N" while a wide one spreads out up to three. The "+N"
* rides on whichever pill is the last visible one, and is hidden as soon as the next slot shows.
*/
const LABEL_SLOTS = [
{ pill: "", overflow: "@xl/pr-row-meta:hidden" },
{ pill: "hidden @xl/pr-row-meta:inline-flex", overflow: "@3xl/pr-row-meta:hidden" },
{ pill: "hidden @3xl/pr-row-meta:inline-flex", overflow: "" },
] as const;
function PullRequestRowLabels({ labels }: { labels: EnvironmentPullRequestEntry["labels"] }) {
const label = labels[0];
if (!label) return null;
const dot = pullRequestLabelColor(label.color);
if (labels.length === 0) return null;
return (
<span className="inline-flex max-w-40 min-w-0 items-center gap-1 rounded-full border border-border/70 bg-muted/40 py-0 pl-1 pr-1.5 text-[10px] leading-3.5 text-muted-foreground">
<span
aria-hidden
className="size-2 shrink-0 rounded-full bg-muted-foreground"
{...(dot ? { style: { backgroundColor: dot } } : {})}
/>
<span className="truncate">{label.name}</span>
{labels.length > 1 ? <span className="shrink-0">+{labels.length - 1}</span> : null}
<span className="flex min-w-0 items-center gap-1">
{LABEL_SLOTS.map((slot, index) => {
const label = labels[index];
if (!label) return null;
const dot = pullRequestLabelColor(label.color);
const remaining = labels.length - index - 1;
return (
<span
key={label.name}
className={cn(
"inline-flex max-w-40 min-w-0 items-center gap-1 rounded-full border border-border/70 bg-muted/40 py-0 pl-1 pr-1.5 text-[10px] leading-3.5 text-muted-foreground",
slot.pill,
)}
>
<span
aria-hidden
className="size-2 shrink-0 rounded-full bg-muted-foreground"
{...(dot ? { style: { backgroundColor: dot } } : {})}
/>
<span className="truncate">{label.name}</span>
{remaining > 0 ? (
<span className={cn("shrink-0", slot.overflow)}>+{remaining}</span>
) : null}
</span>
);
})}
</span>
);
}
+1 -1
View File
@@ -2296,7 +2296,7 @@ function PullRequestsColumn({
{/* The top padding is the shared fade band's height, the same pairing the
settings page makes: at rest the controls sit fully below the mask, and only
content actually passing under the chrome fades. */}
<WorkspacePageContainer className="gap-4">
<WorkspacePageContainer width="expanded" className="gap-4">
<div className="flex flex-col gap-3">
<div ref={inFlowSearchRef} className="flex items-center gap-2">
{searchInput}