fix(mobile): iOS 18 iPad sidebar and thread feed start below the header#32936
Problem
On iPadOS / iOS before 26 (no Liquid Glass, so the bars are solid), two lists start underneath their column's header. The native column lays content out under the bar, but these lists add no top inset there:
- In the iPad sidebar, the newest threads sit behind the title bar and the Search field.
- In the right-hand inspector pane showing a subagent, the top of the loaded page is behind the pane's header. The "Load earlier activity" button can't be tapped, and the first rows are hidden under the title.
The same happens to the top of an ordinary thread feed, to the empty-thread placeholder, and to the first message sent into an empty thread, on iPad and iPhone.
Change
- Sidebar:
ThreadNavigationSidebarnow uses UIKit's automatic content inset (contentInsetAdjustmentBehavior="automatic", with indicator insets) on every iOS version. Before, it was only on when glass was supported. UIKit then clears the bar and its stacked Search field. On iOS 26 the props are the same as before. TheWORKSPACE_LIST_SCROLL_INSETSconstant only existed to turn this off on iOS < 26, so it is removed. - Feed:
ThreadFeedno longer takes acontentTopInsetprop. Its only caller always passed0.- When the feed does not get the native
contentInset(iOS < 26), its top inset isuseContentTopInset(), the column's measured top safe area. That is the bar height where the column lays content under the bar, and 0 on Android. - On iOS 26, where the feed already gets a native
contentInsetof the bar height, it stays 0. - This value drives the existing list-header spacer, the empty and unavailable placeholders, the scroll-indicator inset and the first-send anchor offset.
- The header-material scroll check adds the bar height only on the native-inset path, so the spacer does not count as a scroll.
- When the feed does not get the native
- The doc comment on
useContentTopInsetnow says it applies to solid bars too.
Scope and approval
Fixes pingdotgg/t3code#32884 Fixes pingdotgg/t3code#22543
Triaged via the automated issue flow. #22543 reports the sidebar half on its own.
Verification
vp run check:changedpasses on the head08e1fb258a(format, lint, knip, typecheck, react compiler, tests beside the changed files).- This is a visual bug, so the proof is device captures and no new test. Before is main at
ca796d5211(N1:80e1e4d14d). After iseb39186ba6,f76e21be6c(comment-only on top), or4980e33628, as each row says; the head08e1fb258aonly merges main with noapps/mobilechanges. Both sides share the native fingerprint and Legend List 3.7.2. Main merged sinceeb39186ba6changes only file preview, asset loading and the Android rail width (0 off Android) underapps/mobile. The changed inset paths are identical apart from comments. - Environment: pool iOS simulators driven by agent-device, 1x capture pixels per point, default text size, fresh dev servers seeded with synthetic Replay (dev) threads. iPad (7th generation) iOS 18 1080×810 landscape, iPhone Xs iOS 18 / 18.6 375×812 portrait, iPad Pro 11-inch (M4) iPadOS 26.0 1210×834 landscape. Each comparison is cropped to the pane it covers, or has the status strip cropped and generated titles and timestamps masked identically on both sides. Diff0 marks every changed pixel; DiffT uses 5% fuzz.
| Row | Before | After | Diff0 | DiffT (5%) |
|---|---|---|---|---|
S1 iPad 7 iOS 18, light. Newest rows behind bar and Search → row 20 first below Search. ca796d5211 → eb39186ba6 | S1 before | S1 after | S1 Diff0 | S1 DiffT 5% |
S2 iPad 7 iOS 18, light, status strip cropped. Empty sidebar: "No threads yet" moves below Search. ca796d5211 → eb39186ba6 | S2 before | S2 after | S2 Diff0 | S2 DiffT 5% |
F1 iPad 7 iOS 18, light, detail pane crop. Parent thread top: first rows under the header → below it. ca796d5211 → eb39186ba6 | F1 before | F1 after | F1 Diff0 | F1 DiffT 5% |
F2 iPad 7 iOS 18, light, inspector crop. Subagent top: "Load earlier activity" under the header → 70 pt lower, header identical. ca796d5211 → eb39186ba6 | F2 before | F2 after | F2 Diff0 | F2 DiffT 5% |
F3 iPhone Xs iOS 18.6, light, status strip cropped. Full-screen subagent: control under the bar → just below it. ca796d5211 → 4980e33628 | F3 before | F3 after | F3 Diff0 | F3 DiffT 5% |
F4 iPad 7 iOS 18, light, detail pane crop. Empty thread: "No conversation yet" centred below the bar. ca796d5211 → eb39186ba6 | F4 before | F4 after | F4 Diff0 | F4 DiffT 5% |
F5 iPad 7 iOS 18, light, inspector crop. "Messages not cached" centred below the header, 35 pt lower. ca796d5211 → f76e21be6c | F5 before | F5 after | F5 Diff0 | F5 DiffT 5% |
F8 iPhone Xs iOS 18, light, timestamps masked. Short settled feed: zero changed pixels. ca796d5211 → eb39186ba6 | F8 before | F8 after | F8 Diff0 | F8 DiffT 5% |
I2 iPad 7 iOS 18, light, inspector crop. Earlier-page error: control unreachable → error wraps below it. ca796d5211 → f76e21be6c | I2 before | I2 after | I2 Diff0 | I2 DiffT 5% |
I3 iPhone Xs iOS 18, light, keyboard up, status strip cropped. First send into an empty thread: bubble under the bar → 16 pt below it. ca796d5211 → f76e21be6c | I3 before | I3 after | I3 Diff0 | I3 DiffT 5% |
N1a iPhone Xs iOS 18.6, light, keyboard up, title/timestamps masked. New task → first send: bubble hidden under the bar → below it. 80e1e4d14d → 4980e33628 | N1a before | N1a after | N1a Diff0 | N1a DiffT 5% |
N1b iPhone Xs iOS 18.6, light, keyboard down, same masks. Reply 88 pt lower, clear of the bar. 80e1e4d14d → 4980e33628 | N1b before | N1b after | N1b Diff0 | N1b DiffT 5% |
G1 iPad Pro 11 (M4) iPadOS 26.0, light, inspector crop. Glass path: pixel-identical. ca796d5211 → 4980e33628 | G1 before | G1 after | G1 Diff0 | G1 DiffT 5% |
Recordings:
- I1: before, tapping the hidden "Load earlier activity" loads nothing. After, the tap at 10.6 s loads the earlier page, and the first row sits fully below the header.
- I2: retry goes from error to loading to success.
- I3: before and after. Fill at 2 s, send at 6 s, then the reply, keyboard dismissed, and pans.
- N1: before and after. New task at 1 s, send at 23 s, refocus at 25–26 s, reply at 26–29 s. Send closes the keyboard on both sides.
- S5/S6b sidebar Search, dark: focus, results, no matches, clear, cancel. I4 sidebar hide/restore: row 07 stays in place. I5 Search jump: lands at about 122 pt before and 120 pt after, unchanged. All three are in run 3.
Evidence write-ups:
- run 1, run 2, run 3, run 4: source full screens and the remaining rows.
- N1.
- Comparison repairs: F2 F3 F5 F8 I2 G1 and S2 I3 N1, with their crop boxes, masks and scripts.
- Fixture matrix.
Seed and driver scripts: seed-rpc.mjs, driver.md, capture.py, seed.py, recapture-seed.mjs, repair-comparisons.py, repair-four-comparisons.py.
What else changed in the captures: only the moved content above. Inside each crop or mask, the following still differ:
- the status-bar clock;
- generated thread titles, Replay timestamps and durations;
- Expo dev-client overlays.
The recordings also carry touch markers and grey boxes over model labels. In the I1 before recording the inspector is 266 pt wide; after, it is 260 pt. Run 3's Search recordings show a Working counter only on the after side.
Not checked:
- Android.
useContentTopInsetreturns 0 there, and the sidebar change is in the iOS-only branch. - The compact iOS 26 send lifecycle. The feed keeps its native-inset path there with unchanged values, and G1 shows the glass inspector pixel-identical.
Verification log
- Main merged into the branch again (
4980e33628, then08e1fb258a), with no conflicts. - Reviews: three earlier rounds and a round after each later merge, each with two independent reviewers. No code defects found. Findings were missing or stale captures and body text, now addressed. On
4980e33628both reviewers returned MERGE with no findings. - Proof audit: the matrix was re-derived on
4980e33628. Its two passes found clock, timestamp and parent-pane noise in S2, F2, F3, F5, F8, I2, I3 and N1, and a before/before G1 pair. Those comparisons were rebuilt as above. The auditor rebuilt all ten independently with zero pixel delta and returned sufficient. - A message-search jump with the keyboard up can land the target partly under the bar on iOS 18. It lands in the same place before and after this change (
scrollToIndexwithviewPosition: 0.2), so it is out of scope here.
AI-assisted; verified with the tests and tools listed above.
Checks
Added 2 commits
Approvability
Verdict: Approved at f76e21b
Macroscope's review found this PR approvable — This corrects sidebar and thread-feed spacing beneath iOS headers and aligns header appearance with scrolling. The changes are limited to layout behavior, with no persistent-data or external-system effects.
No code changes detected at 08e1fb2. Prior analysis still applies.
You can add or adjust custom eligibility rules. Learn more.
[GPT-6.1 Sol][Codex] on behalf of shivam.
Handoff from the issue-watch investigation of https://github.com/pingdotgg/t3code/issues/32884. I did not reproduce this on a device: the iOS/Android pools were empty and shiv was unreachable during my run. No app build, native interaction, screenshot or recording was produced, and no format/lint/typecheck or repository test suite ran.
Source investigation at 22dc6f9e98cc826ac3581aeeb0fb1852f49a43f1 found the sidebar's glass-gated automatic inset and the feed's pre-26 combination of automatic insets disabled plus contentTopInset={0}. The sidebar overlaps the existing work in https://github.com/pingdotgg/t3code/pull/22550. I also identified the separate end-follow/snapback path covered by https://github.com/pingdotgg/t3code/pull/31907; I did not change that patch.
A local alternative fix, f253083cc3629d72cf6ca12b4dd97e9a48d51df2, enabled automatic insets for the sidebar and all iOS thread routes. Independent source review found no definite new defect, but blocked readiness on missing native evidence and repository checks. The only executed validation was git diff --check, which passed. That local commit was never pushed and is being left behind now that this PR owns the issue. No runtime evidence from my work is available to add to yours.
No actionable comments were generated in the recent review.
Walkthrough
-
ThreadFeed now gets its top inset from
useContentTopInsetand adjusts header-material visibility usingbarInsetwhen native automatic insets are enabled. The thread navigation sidebar now uses UIKit automatic inset adjustment on iOS.Changes: iOS Scroll Insets
Layer / File(s) Summary ThreadFeed top-inset handling
apps/mobile/src/components/ui/useBarInset.ts,apps/mobile/src/features/threads/ThreadFeed.tsx,apps/mobile/src/features/threads/ThreadDetailScreen.tsxThe inset documentation now describes the iOS bar height for glass or solid bars and manual insets when UIKit automatic insets are disabled. ThreadFeed removes the contentTopInsetprop, reads the column top inset fromuseContentTopInset, and usesbarInsetfor the header-material visibility offset when native automatic insets are enabled.Sidebar automatic inset adjustment
apps/mobile/src/features/layout/workspace/workspace-list-insets.ts,apps/mobile/src/features/threads/ThreadNavigationSidebar.tsxThe shared WORKSPACE_LIST_SCROLL_INSETSconfiguration is removed. On iOS, the sidebar list now enables automatic scroll-indicator and content-inset adjustment.Estimated code review effort: 2 (Simple) | ~10 minutes
Change: Bug fix · Severity of issue fixed: Medium
Possibly related issues
- pingdotgg/t3code#31867: The ThreadFeed inset change affects the position of “Load earlier activity.” The PR does not change the reported end-follow behavior.
- pingdotgg/t3code#22543: The sidebar now enables automatic content-inset adjustment on iOS, addressing the reported content positioning under the header and Search field.
Merge Risk: External image Minimal · up to f76e2
-
This change makes the iPad sidebar and thread feed start below their headers on iOS 18. No concrete merge-blocking risk was found in the supplied changes.
Pre-merge checks: Passed 3 · Failed 1
-
Failed Failed checks: 1 warning
Check name Status Explanation Resolution Description check Warning The description clearly explains the problem, change, and detailed verification. The Scope and approval section links triaged issues but does not include a maintainer approval comment or explain why t… Add a link to the triaged issue or discussion with the maintainer’s explicit approval of the direction and scope, including the approval comment. If the change qualifies as a small, focused fix of an obvious bug without prior approval, expl… Passed Passed checks: 3 passed
-
Check name Status Explanation Title check Passed The title clearly identifies the iOS 18 sidebar and thread-feed inset fix. Linked Issues check Passed Open, directly linked issue #32884requires sidebar content to remain visible below its header.ThreadNavigationSidebarnow enables UIKit automatic content and scroll-indicator insets on iOS. `Threa…Out of Scope Changes check Passed All reviewed changes support issue #32884. The sidebar inset change fixes the left list. The feed inset change and removal of itscontentTopInsetoverride fix the subagent pane and apply the same in…Full details: Linked Issues check
-
Explanation
Open, directly linked issue
#32884requires sidebar content to remain visible below its header.ThreadNavigationSidebarnow enables UIKit automatic content and scroll-indicator insets on iOS.ThreadFeedusesuseContentTopInset()when UIKit does not apply automatic insets, and keeps the manual inset at zero on the automatic path. This clears the left sidebar and subagent feed below their bars. The PR description reports iPadOS 18 captures for both cases, including the earlier-activity button below the inspector header. Issue#32884does not require an automated test, so the absence of a new test is not an unmet requirement.
Full details: Out of Scope Changes check
-
Explanation
All reviewed changes support issue
#32884. The sidebar inset change fixes the left list. The feed inset change and removal of itscontentTopInsetoverride fix the subagent pane and apply the same inset to the list spacer, placeholder, indicators, and anchors. RemovingWORKSPACE_LIST_SCROLL_INSETSfollows from enabling automatic insets on the sidebar. TheuseContentTopInsetcomment documents the new solid-bar use. No unrelated change is evident.
-
Full details: Description check
-
Explanation
The description clearly explains the problem, change, and detailed verification. The Scope and approval section links triaged issues but does not include a maintainer approval comment or explain why the change qualifies for the small, obvious bug exemption.
Resolution
Add a link to the triaged issue or discussion with the maintainer’s explicit approval of the direction and scope, including the approval comment. If the change qualifies as a small, focused fix of an obvious bug without prior approval, explain why.
-
Finishing Touches
-
Generate docstrings
-
- Commit to this branch
- Create a new PR
Generate unit tests (beta)
-
- Commit to this branch
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
External image Recent review info
-
External image Run configuration
-
- Source mode: Auto
- Repository: pingdotgg/t3code
- Branch: fix/issue-32884
- File: .coderabbit.config.ts
- Commit: f76e21b
- Layers: Repository TS config
- Review profile: CHILL
- Plan: Team
- Run ID:
0417fea2-5a70-4c2d-a70e-6f0d374212f1
External image Commits
-
Reviewing files that changed from the base of the PR and between eb39186ba693087529323f5e4da65018d8377ad5 and f76e21be6cdcf0936a28521badaf66e4a85bb9cc.
External image Files selected for processing: 2
-
apps/mobile/src/components/ui/useBarInset.tsapps/mobile/src/features/threads/ThreadFeed.tsx
External image Files skipped from review as they are similar to previous changes: 2
-
- apps/mobile/src/components/ui/useBarInset.ts
- apps/mobile/src/features/threads/ThreadFeed.tsx
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 0 remain after this review.
External image Recent review info
-
External image Run configuration
-
- Source mode: Auto
- Repository: pingdotgg/t3code
- Branch: fix/issue-32884
- File: .coderabbit.config.ts
- Commit: f76e21b
- Layers: Repository TS config
- Review profile: CHILL
- Plan: Team
- Run ID:
0417fea2-5a70-4c2d-a70e-6f0d374212f1
External image Commits
-
Reviewing files that changed from the base of the PR and between eb39186ba693087529323f5e4da65018d8377ad5 and f76e21be6cdcf0936a28521badaf66e4a85bb9cc.
External image Files selected for processing: 2
-
apps/mobile/src/components/ui/useBarInset.tsapps/mobile/src/features/threads/ThreadFeed.tsx
External image Files skipped from review as they are similar to previous changes: 2
-
- apps/mobile/src/components/ui/useBarInset.ts
- apps/mobile/src/features/threads/ThreadFeed.tsx
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 0 remain after this review.
-
Added 1 commit
- Merge remote-tracking branch 'origin/main' into fix/issue-32884eb39186
Added 1 commit
- fix(mobile): inset comments describe the manual contentInset pathf76e21b