Skip to content

fix(mobile): the Legal page starts below the header on iOS - #27241

Open
camchis wants to merge 5 commits into
pingdotgg:mainfrom
camchis:fix/mobile-legal-under-header
Open

camchis wants to merge 5 commits into
pingdotgg:mainfrom
camchis:fix/mobile-legal-under-header

Conversation

@camchis

@camchis camchis commented Oct 29, 2026

Copy link
Copy Markdown
Contributor

On iOS, Settings → About → Legal opens the page with its top under the header. The title and the "T3 TOOLS, INC. / LEGAL" label are cut off, and pulling down only shows the real top during the bounce before it snaps back under the header.

The Legal WebView left react-native-webview's contentInsetAdjustmentBehavior at its default of never, so the page extended under the header. It now uses automatic, the value the HTML preview and workspace file preview WebViews got in #25765.

Checked on an iPhone 17 Pro simulator (iOS 26.5): open Legal from About, pull down at the top, scroll to the footer and back. The clips below start on the Legal page. Before, the page opens cut off under the header and the header title is washed out. After, it opens below the header and settles there. While scrolling, content still passes under the header, which is expected. Not checked on Android, where the prop doesn't apply, on iPad, or on a physical device.

Before After
before after

Side by side, full length:

before-after.mp4

vp run check:changed exited non-zero: format, lint, knip, typecheck and the React compiler check pass, but the test step reports 15 failing files (18 tests) in apps/server, apps/desktop, packages/provider-fx, scripts and infra, none importing mobile code. The log also shows a missing Playwright browser executable and a SQLite NOT NULL constraint error in infra/task-cache. CI owns the full suite.

Created with Claude Sonnet 5.5 in Claude Code.

The Legal WebView defaulted to contentInsetAdjustmentBehavior "never", so the
page opened with its top under the header. Use "automatic", as the HTML and
file preview WebViews already do.
@github-actions github-actions Bot added vouch:unvouched Author is not yet trusted in the VOUCHED list. size:XS 0-9 changed lines (additions + deletions). labels Oct 29, 2026
@macroscopeapp

macroscopeapp Bot commented Oct 29, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Approved at 7bf0ccd

Macroscope's review found this PR approvable — The Legal screen now uses automatic iOS content insets to keep the page below the header. This localized layout correction leaves document content and WebView security behavior unchanged.

You can add or adjust custom eligibility rules. Learn more.

@coderabbitai

coderabbitai Bot commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

Important

Review skipped

Review was skipped as selected files did not have any reviewable changes.

Run configuration

Commits

Reviewing files that changed from the base of the PR and between c29cdb4 and d977e21.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review

No actionable comments were generated in the recent review.

Walkthrough

The legal-document WebView now sets contentInsetAdjustmentBehavior to automatic.

Changes: Legal WebView

Layer / File(s) Summary
Legal WebView inset adjustment
apps/mobile/src/features/settings/components/SettingsLegalDocumentRouteScreen.tsx
The WebView sets contentInsetAdjustmentBehavior to automatic.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Change: Bug fix

Suggested reviewers: juliusmarminge

Merge Risk: Minimal · previous review c29cd

This makes the Legal page start below the header on iOS by adjusting the WebView's content insets. The change is small, easy to revert, and affects only this screen, so the risk of merging is minimal.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the change: the Legal page no longer starts under the header on iOS. It is specific, uses conventional commit form, and matches the one-line WebView fix (contentInsetAdjustmentBehavior…
Description check Passed The description follows the template well. It states the problem and the expected behavior on iOS, gives the change and its rationale (contentInsetAdjustmentBehavior from never to automatic, matching …
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the change: the Legal page no longer starts under the header on iOS. It is specific, uses conventional commit form, and matches the one-line WebView fix (contentInsetAdjustmentBehavior set to automatic) in the raw summary and objectives.

Full details: Description check

Explanation

The description follows the template well. It states the problem and the expected behavior on iOS, gives the change and its rationale (contentInsetAdjustmentBehavior from never to automatic, matching #25765), and limits scope to one component. It includes a Verification section with the simulator steps, before/after clips, and what was not checked. It also explains the failing repo-wide test step and why it is unrelated. The Scope section does not link an issue, and it does not explain why no issue is needed for this small fix. That gap is minor, so the check passes.

Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 7413181 and c29cdb4.

Files selected for processing: 1

  • apps/mobile/src/features/settings/components/SettingsLegalDocumentRouteScreen.tsx

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.

Copy link
Copy Markdown
Collaborator

Note

Written by gpt-6.1-sol on behalf of Maria

kept camchis's original implementation and commits, merged current main, and removed the explanatory comment. the final diff is one line: contentInsetAdjustmentBehavior="automatic", matching the other full-screen webviews. navigation, retry, external links, and document security settings are unchanged.

verification at 7413181d36722585b24c0d41ad6bada97d39c5e6: blacksmith vp run check:changed 8b74a69019e3d0f5be62dc118c526669002fc195 passed format, lint, knip, affected-package typechecks, and react compiler checks. the existing legal-document-url tests passed (2 tests). two independent code reviews found no code issues.

fresh native reproduction and before/after captures remain unverified: device access is disabled in this linux environment, and chrome cannot exercise ios native webview insets. the default dev server started successfully and was stopped. the clips below are the original contributor's evidence, inspected and reuploaded here; they are not new captures of this head.

original contributor's ios legal page before the inset fix

original contributor's ios legal page after the inset fix

@camchis

camchis commented Nov 1, 2026

Copy link
Copy Markdown
Contributor Author

@maria-rcks lgtm, your commit just removed a comment so no new verification is needed

@juliusmarminge

Copy link
Copy Markdown
Member

Evidence

Verified in the real iOS dev client on iPhone 18 Pro, 402×874, light system appearance, with fresh isolated state on both commits.

Steps: Settings → scroll → About → Legal; wait for loading; pull down and release; scroll to the footer and return to the top.

Before After
4c2f04d35d c29cdb442c
Before: Legal opens with heading clipped After: company label and full heading below header
Before: returning to top settles clipped After: returning to top settles below header
Before interaction recording After interaction recording

Scenario driver

The base reproduces the reported clipping and bounce snap-back. The head keeps the company label and full title visible below the header. The final scenario comparison exited 0.

@juliusmarminge juliusmarminge added takeover:ready Takeover done; auto-lands when gates pass and removed takeover:in-progress A takeover lead is working on this PR labels Nov 14, 2026
@juliusmarminge

Copy link
Copy Markdown
Member

The automated pipeline stopped on this pull request and will not merge it:

in the real app the problem is still there, and the rework changed nothing:

Nothing changed: the report that the problem still happens on d977e21 is wrong. I re-ran the same scenario driver posted with the c29cdb4 evidence (Settings → About → Legal, pull down and release, scroll to the footer and back) on d977e21. It ran through the repository's e2e runner on a pooled iPhone 18 Pro, light appearance, 402×874, and passed. The label was visible with y > 100. The 'open' and 'returned to top' captures both show 'T3 TOOLS, INC. / LEGAL' and the full 'Legal' title below the header, matching the passing c29cdb4 proof. Head open: https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/1a7ac7ccfb00a105/001-legal-open.png . Head back at top: https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/b6f105b7a7810e90/004-legal-returned-top.png . Between c29cdb4 (proven fixed) and d977e21 the only mobile changes from main are iPad split-view column widths and thread feed code, none on this route. The failing head result came from a standalone rerun after infrastructure failures, which most likely did not run this head's bundle. The fix is still the one line contentInsetAdjustmentBehavior="automatic" on the Legal WebView.

It stays open for a person to finish or close.

@juliusmarminge juliusmarminge added takeover:blocked Takeover blocked; reason in the PR body and removed takeover:ready Takeover done; auto-lands when gates pass labels Nov 14, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XS 0-9 changed lines (additions + deletions). takeover:blocked Takeover blocked; reason in the PR body vouch:unvouched Author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants