fix(mobile): remove tab control flicker on iOS PR screen#27269

open1
main
GitHub fork: fix/mobile-ios-pr-tab-double-indicator
View on GitHubTwo-way sync enabledPR last imported 7h ago

Problem

On iOS 26, the Overview / Activity control on the pull request screen flickers when you change tabs. Each tab's list has its own control in its header. The tab change swaps to the next list's control while the tapped control is still animating.

Change

On iOS, one control above the lists takes the taps and follows the shown list's scroll. Under the navigation bar, the header copy shows instead, so the bar's blur still covers it. Android and web do not change.

This is a quick fix. The long-term fix is one list for all tabs: the header and control render once, and each tab stores its own scroll offset. Then no overlay is needed.

Scope and approval

No issue exists. This is a small fix for a visible glitch, on iOS only.

Verification

Before (main)After (this PR)
Comparison at 1/4 speed (top: before, bottom: after)
  • iPhone 17 Pro and iPad Pro 13 simulators, iOS 26.5: tab taps, tab changes while scrolled, pull to refresh, light and dark mode. No flicker, and the control looks the same as before.
  • VoiceOver order checked in the accessibility tree. Android emulator: no change.
  • Not checked: a physical device.

Model and harness: Claude Opus 5.5 in Claude Code under T3 Code.

🤖 Generated with Claude Code

Checks

21 successful · 6 skipped
All checks passed
8462f49

Added 1 commit

  • fix(mobile): iOS PR tabs no longer show two selection indicators8462f49
Synced from GitHub

Review in Change Stack →

Walkthrough

The pull-request screen now uses usePullRequestTabControl for its tab header. On iOS, the hook tracks list scroll offsets and positions an overlay control. On other platforms, it provides a compact header control without an overlay.

Changes: Pull-request tabs

Layer / File(s)Summary
Shared tab-control contract
apps/mobile/src/features/pull-requests/PullRequestTabControl.tsx
The shared implementation exports the tab-control types and hook. It provides a compact segmented-control header, no list shared values, and no overlay.
iOS scroll-aware control
apps/mobile/src/features/pull-requests/PullRequestTabControl.ios.tsx
The iOS hook tracks section scroll offsets and positions the control using measured layouts. Its header includes accessible tab elements, and its overlay is hidden from accessibility.
Pull-request screen integration
apps/mobile/src/features/pull-requests/PullRequestRouteScreen.tsx
The screen passes tab options and layout values to the hook, connects list scroll values, reports header layout, and renders the hook-provided header and conditional overlay.

Priority: External image Low

Estimated code review effort: 3 (Moderate) | ~20 minutes

Change: Bug fix

Sequence Diagram(s)

mermaid
1sequenceDiagram
2 participant PullRequestRouteScreen
3 participant usePullRequestTabControl
4 participant AnimatedLegendList
5 PullRequestRouteScreen->>usePullRequestTabControl: provide tabs and header layout
6 PullRequestRouteScreen->>AnimatedLegendList: provide section shared scroll value
7 AnimatedLegendList->>usePullRequestTabControl: update section scroll offset
8 usePullRequestTabControl->>PullRequestRouteScreen: provide header and positioned overlay

Suggested labels: 📱 Native Change

Suggested reviewers: juliusmarminge, macroscopeapp

Merge Risk: External image Minimal · up to 8462f

This change removes the tab control flicker on the iOS pull-request screen. VoiceOver users can still switch sections through the control underneath the accessibility proxies. No merge-blocking risk remains beyond normal verification on a physical device.

Pre-merge checks: Passed 4
Check nameStatusExplanation
Title checkPassedThe title names the main change: removing a tab control flicker on the iOS pull request screen. It matches the changeset, which adds an iOS overlay control that stops the Overview/Activity control fro…
Description checkPassedThe description follows the template. It has Problem, Change, Scope and approval, and Verification sections. The Problem and Change sections explain the iOS 26 flicker and the overlay fix. The Verific…
Linked Issues checkPassedCheck skipped because no linked issues were found for this pull request.
Out of Scope Changes checkPassedCheck skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the main change: removing a tab control flicker on the iOS pull request screen. It matches the changeset, which adds an iOS overlay control that stops the Overview/Activity control from being swapped during tab changes. The title uses the conventional commit format and is specific.

Full details: Description check

Explanation

The description follows the template. It has Problem, Change, Scope and approval, and Verification sections. The Problem and Change sections explain the iOS 26 flicker and the overlay fix. The Verification section gives before and after recordings, the simulators and iOS version tested, light and dark mode, tab changes while scrolled, pull to refresh, VoiceOver order, and the Android check. It also states what was not checked. The Scope and approval section says no issue exists and explains why the change is a small fix for an obvious visible bug on iOS only. That meets the template's exemption for a very small, focused fix, but the justification is brief. The description also includes the model and harness line that the template asks for. The template's HTML comments were removed, which is acceptable.

Finishing Touches
🧪 Generate unit tests (beta)
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Comment @coderabbitai help to get the list of available commands.