Skip to content

Commit 4d06156

Browse files
authored
fix(web): center pull request unavailable states (#11110)
1 parent 20ef250 commit 4d06156

3 files changed

Lines changed: 10 additions & 4 deletions

File tree

‎apps/web/src/components/pullRequest/PullRequestDetailPanel.tsx‎

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1447,7 +1447,13 @@ export function PullRequestDetailPanel({
14471447
onPickerOpenChange={setThreadPickerOpen}
14481448
/>
14491449
) : null}
1450-
<div className="@container/pr-header grid min-w-0 shrink-0 grid-cols-[minmax(0,1fr)_auto] items-start gap-x-2 border-b border-border/60">
1450+
<div
1451+
className={cn(
1452+
"@container/pr-header grid min-w-0 shrink-0 grid-cols-[minmax(0,1fr)_auto] items-start gap-x-2",
1453+
detail && "border-b border-border/60",
1454+
!detail && !onClose && "hidden",
1455+
)}
1456+
>
14511457
<div className="ml-4 grid h-7 min-w-0 items-center overflow-hidden">
14521458
<div
14531459
aria-hidden={condensed}
@@ -2513,7 +2519,7 @@ export function PullRequestDetailPanel({
25132519
</div>
25142520

25152521
<div
2516-
className="relative min-h-0 flex-1 overflow-hidden"
2522+
className="relative flex min-h-0 flex-1 flex-col overflow-hidden"
25172523
onScrollCapture={(event) => {
25182524
const scroller = event.target as HTMLElement;
25192525
scrollerRef.current = scroller;

‎apps/web/src/components/pullRequest/PullRequestsUnavailableState.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ export function PullRequestsUnavailableState({
2525
gitHubUrl?: string;
2626
}) {
2727
return (
28-
<Empty className="px-4 py-16 md:px-4">
28+
<Empty className="min-h-0 justify-center-safe overflow-y-auto px-4 py-16 md:px-4 [&>*]:shrink-0">
2929
<EmptyMedia variant="icon">
3030
<GitPullRequestIcon />
3131
</EmptyMedia>

‎apps/web/src/routes/_chat.pull-requests.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2362,7 +2362,7 @@ function PullRequestsColumn({
23622362
{/* The top padding is the shared fade band's height, the same pairing the
23632363
settings page makes: at rest the controls sit fully below the mask, and only
23642364
content actually passing under the chrome fades. */}
2365-
<WorkspacePageContainer width="expanded" className="gap-4">
2365+
<WorkspacePageContainer width="expanded" className="min-h-full gap-4">
23662366
<div className="flex flex-col gap-3">
23672367
<div ref={inFlowSearchRef} className="flex flex-wrap items-center gap-2">
23682368
<div className="min-w-0 basis-full @lg/pr-list:basis-0 @lg/pr-list:flex-1">

0 commit comments

Comments
 (0)