# feat\(web\): refresh pull request details · PR \#7148 · pingdotgg/t3code

[View on GitCafe](https://git.cafe/pingdotgg/t3code/pull/7148)

Repository: [pingdotgg/t3code](https://git.cafe/pingdotgg/t3code)

Visibility: public

State: merged

Source repository: pingdotgg/t3code

Source branch: ui-refresh/pull-requests

Target branch: main

Head commit: eee6a0458dc34f61e7727095e6d4ba361eb2b776

[Discussion and reviews](https://git.cafe/pingdotgg/t3code/pull/7148)

[Commits](https://git.cafe/pingdotgg/t3code/pull/7148/commits?format=markdown)

[Files changed](https://git.cafe/pingdotgg/t3code/pull/7148/diffs?format=markdown)

## Description

---

## What changed

- Refreshes Pull Request list and detail geometry, filters, sticky metadata, branch actions, stacked-base state, and loading skeletons.
- Keeps expanded detail spacious while using a compact header only after scroll.
- Makes repository, PR, branch-copy, checkout, conflict, reviewer, label, and timeline controls consistent at narrow and wide widths.


## Screenshots

_Direct parent on the left; this PR on the right. Same viewport and copied application state._

<table>
<tr><th>Before</th><th>After</th></tr>
<tr>
<td><img src="https://github.com/user-attachments/assets/268d6e7c-19fe-4df5-a133-87f1c99fef31" alt="Pull Requests before" width="500"></td>
<td><img src="https://github.com/user-attachments/assets/122e74fa-d149-4ec9-89a6-d06521069656" alt="Pull Requests after" width="500"></td>
</tr>
</table>
## Why

This is a large visual review on its own. Separating it keeps workspace primitives below and terminal, composer, and tool-call behavior out of the diff.

## Validation

- Pull Request filter and detail logic tests
- Pull Request link tests
- Affected-package typechecks
- Changed-file lint and formatting checks

## Stack order

1. #7153 workspace and navigation
2. #7147 Usage
3. #7148 Pull Requests, this PR
4. #7149 terminal
5. #7150 composer
6. #7151 tool lifecycle projection
7. #7152 tool activity UI

Built with GPT-5.6-sol in the Codex harness.

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Medium Risk**
> Large UI refactor across PR detail, list, and VCS/ref parsing; conflict action ordering and new stacked-PR heuristics affect merge/checkout flows, though logic is covered by added tests.
> 
> **Overview**
> **Pull request detail and list** get a visual and interaction pass: shared `WorkspacePageHeader` / `WorkspacePageContainer`, filter and refresh controls aligned with other workspace pages, and the right-panel toggle only when a PR is selected (with a clearer unavailable tooltip).
> 
> **`PullRequestDetailPanel`** drops the `chromeVariant` prop and always collapses header metadata on scroll, with tighter top chrome and segmented tab toggles. **Resolve conflicts** becomes the primary header action when merge conflicts exist (ahead of draft-ready / merge). The repository name can open the repo root via new **`changeRequestRepositoryUrl`**. **Stacked PRs** are inferred from local VCS refs (`isStackedPullRequestBase`) and shown with a layers icon on the base branch. Loading uses a full-panel **`PullRequestDetailGhost`** instead of per-tab ghosts inside the scroll area.
> 
> **`PanelLayoutControls`** wraps disabled toggles so tooltips still work on unavailable terminal/right-panel buttons. **`pullRequestHandoffLabels`** no longer exposes resolve/conflicts strings (conflicts are handled in the header). Summary meta rows use a fixed label column grid.
> 
> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit eee6a0458dc34f61e7727095e6d4ba361eb2b776. Bugbot is set up for automated code reviews on this repo. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup>
<!-- /CURSOR_SUMMARY -->

<!-- Macroscope's pull request summary starts here -->
<!-- Macroscope will only edit the content between these invisible markers, and the markers themselves will not be visible in the GitHub rendered markdown. -->
<!-- If you delete either of the start / end markers from your PR's description, Macroscope will append its summary at the bottom of the description. -->
> [!NOTE]
> ### Refresh pull request detail panel with conflict resolution, stacked PR indicators, and usage page redesign
> - Overhauls [PullRequestDetailPanel](https://github.com/pingdotgg/t3code/pull/7148/files#diff-3c76d43f3539848054e21911e658895287b4fe9c387c3267c21684290baebd3a): chrome always collapses on scroll, conflict resolution is promoted to a primary destructive button, tab nav switches to a segmented `ToggleGroup`, and the repository label becomes a clickable external link.
> - Adds `isStackedPullRequestBase` helper and a VCS refs query to detect stacked PRs, showing a `LayersIcon` indicator in the header when the base branch is not the repo default.
> - Redesigns the Usage page with responsive breadcrumb controls (segmented toggles on desktop, selects on mobile), fixed provider order with session counts, and a simplified Totals section without detail subtext.
> - Adds per-provider `sessions` tracking to `mergeUsage` so providers with sessions but zero spend appear in the provider list.
> - Adds `changeRequestRepositoryUrl` to derive a repository root URL from a PR URL across GitHub, GitLab, Bitbucket, and Azure DevOps.
> - `PanelLayoutControls` tooltips stay accessible when toggles are disabled; the right-panel toggle on the pull requests route requires an active PR selection.
> - Behavioral Change: `pullRequestHandoffLabels` no longer returns `resolve` or `resolveConflicts` keys; callers that depended on those entries will receive only fix-related labels.
>
> <!-- Macroscope's review summary starts here -->
>
> <sup><a href="https://app.macroscope.com">Macroscope</a> summarized 75f0625.</sup>
> <!-- Macroscope's review summary ends here -->
>
<!-- Macroscope's pull request summary ends here -->
