authorgravatar for 62337003+Bil0000@users.noreply.github.comBilal Bakr <62337003+Bil0000@users.noreply.github.com> 2026-09-16 01:12:36+03:00
committergravatar for noreply@github.comGitHub <noreply@github.com> 2026-09-15 15:12:36-07:00
logf0a0ead946ca3f3f310460a91b7dabb0e3fe4834
tree1138caafe773fc0b00623e8d5a9a68fa9ab71f03
parent2c16c1d264173d86fc354e9a4c0c78cd42e514b7
signature Signed by PGP key B5690EEEBB952194

fix(web): keep PR controls readable in narrow panels (#11962)


2 files changed, 4 insertions(+), 10 deletions(-)

apps/web/src/components/pullRequest/PullRequestCodeTab.tsx+2-9
......@@ -38,7 +38,6 @@ import { orderDiffFiles } from "./pullRequestFileOrder.logic";
3838import {
3939 buildFileDiffRenderKey,
4040 fnv1a32,
41 getDiffLineStat,
4241 getRenderablePatch,
4342 resolveDiffThemeName,
4443 resolveFileDiffPath,
......@@ -546,7 +545,6 @@ function PullRequestCodeTab({
546545 toggledFiles,
547546 ],
548547 );
549 const lineStat = useMemo(() => getDiffLineStat(files), [files]);
550548 const omittedFileStats = useMemo(
551549 () =>
552550 new Map(
......@@ -1040,7 +1038,7 @@ function PullRequestCodeTab({
10401038 {orderedCommits.length > 0 ? (
10411039 <DropdownMenu>
10421040 <DropdownMenuTrigger
1043 className="inline-flex h-6 max-w-64 items-center gap-1 rounded-md bg-accent px-2 text-xs font-medium text-accent-foreground outline-none transition-colors hover:bg-accent/80 focus-visible:ring-2 focus-visible:ring-ring"
1041 className="inline-flex h-6 min-w-0 max-w-64 items-center gap-1 rounded-md bg-accent px-2 text-xs font-medium text-accent-foreground outline-none transition-colors hover:bg-accent/80 focus-visible:ring-2 focus-visible:ring-ring"
10441042 aria-label={`Diff scope: ${scopeLabel}`}
10451043 >
10461044 <span className="truncate">{scopeLabel}</span>
......@@ -1089,7 +1087,7 @@ function PullRequestCodeTab({
10891087 ) : null}
10901088 {/* One count, and the caveats as icons that carry their own words. Spelled out they
10911089 competed for a strip this narrow and every one of them truncated to nothing. */}
1092 <PullRequestMetaLine>
1090 <PullRequestMetaLine className="shrink-0">
10931091 <span className="shrink-0 tabular-nums">
10941092 {files.length} {files.length === 1 ? "file" : "files"}
10951093 {nextCursor === null ? "" : "+"}
......@@ -1124,11 +1122,6 @@ function PullRequestCodeTab({
11241122 </PullRequestMetaLine>
11251123 </div>
11261124 <div className="flex shrink-0 items-center gap-1">
1127 <PullRequestDiffStat
1128 additions={lineStat.additions}
1129 deletions={lineStat.deletions}
1130 className="mr-1"
1131 />
11321125 {fileKeys.length > 0 ? (
11331126 <Tooltip>
11341127 <TooltipTrigger
apps/web/src/components/pullRequest/PullRequestDetailPanel.tsx+2-1
......@@ -2459,10 +2459,11 @@ export function PullRequestDetailPanel({
24592459
24602460 {detail ? (
24612461 <nav
2462 className="col-span-2 flex min-w-0 items-center gap-1 overflow-x-auto border-t border-border/60 px-4 py-2 [scrollbar-width:none] [&::-webkit-scrollbar]:hidden"
2462 className="col-span-2 flex min-w-0 flex-wrap items-center gap-2 border-t border-border/60 px-4 py-2"
24632463 aria-label="Pull request tabs"
24642464 >
24652465 <ToggleGroup
2466 className="shrink-0"
24662467 size="segmented"
24672468 variant="segmented"
24682469 value={[tab]}