Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 11 additions & 4 deletions apps/web/src/components/pullRequest/PullRequestDetailPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1517,6 +1517,8 @@ export function PullRequestDetailPanel({
const statePresentation = detail
? resolvePullRequestState({ state: detail.state, isDraft: detail.isDraft })
: null;
const showsApproveWorkflows =
workflowApprovalsRequired > 0 && !checksStale && can("approve-workflows");
const checksSummary = checksStale
? checksState === null
? "No checks reported"
Expand Down Expand Up @@ -2551,8 +2553,13 @@ export function PullRequestDetailPanel({
))}
</ToggleGroup>
{tab === "summary" ? (
<span className="ml-auto inline-flex shrink-0 items-center">
{workflowApprovalsRequired > 0 && !checksStale && can("approve-workflows") ? (
<span
className={cn(
"ml-auto flex items-center justify-end",
showsApproveWorkflows ? "shrink-0" : "min-w-0 flex-1",
)}
>
{showsApproveWorkflows ? (
<Tooltip>
<TooltipTrigger
render={
Expand Down Expand Up @@ -2588,7 +2595,7 @@ export function PullRequestDetailPanel({
</Tooltip>
) : (
<span
className="inline-flex items-center gap-1.5 text-xs text-muted-foreground"
className="flex h-4 min-w-0 flex-wrap content-start items-center justify-end gap-x-1.5 overflow-hidden text-xs text-muted-foreground"
aria-label={checksSummary ? `Checks: ${checksSummary}` : "Checks"}
>
{checksState !== null ? (
Expand All @@ -2601,7 +2608,7 @@ export function PullRequestDetailPanel({
) : (
<CircleDotIcon aria-hidden className="size-3.5" />
)}
{checksSummary}
<span className="whitespace-nowrap">{checksSummary}</span>
</span>
)}
</span>
Expand Down
Loading