Skip to content

fix(privacy): keep the back control clear of the notch on phones - #1621

Merged
cursor[bot] merged 14 commits into
mainfrom
claude/privacy-notch-safe-area
Aug 5, 2026
Merged

fix(privacy): keep the back control clear of the notch on phones#1621
cursor[bot] merged 14 commits into
mainfrom
claude/privacy-notch-safe-area

Conversation

@BigSimmo

@BigSimmoBigSimmo commented Aug 5, 2026

Copy link
Copy Markdown
Owner

Summary

  • /privacy and /reference/colour-coding sit outside the search shell, so they own the OS top inset themselves. Bare searchPageShell's py-3 top pad is not enough under a status bar or Dynamic Island when apple-mobile-web-app-status-bar-style=black-translucent, leaving the back control partly behind the notch.
  • Introduces shared searchPageShellStandalone with max(0.75rem, var(--safe-area-top)) (1.25rem at sm) baked into the top pad and nopy-* axis padding, so call sites do not rely on Tailwind side-vs-axis utility sort order (and cn has no tailwind-merge).
  • Both standalone routes use that primitive; the back control sits in a min-h-tap row (canonical --spacing-tap / 48px token).
  • Contract: tests/search-page-shell-standalone.contract.test.ts pins the primitive shape, both call sites, and rendered markup.

Provenance: split out of stale draft PR #1582, which mixed this production fix with three privacy-page redesign mockups and 4.2 MB of PNG screenshots. That PR had been red since 2026-08-02 on an unrelated type-scale violation and 28 commits behind main; it is now closed.

Verification

  • npx vitest run tests/search-page-shell-standalone.contract.test.ts tests/privacy-ui.test.ts tests/privacy.test.ts tests/navigation-back-button.dom.test.tsx — 4 files passed, 32 tests passed
  • npm run test — Test Files 505 passed (505); Tests 5331 passed | 4 skipped (5335)
  • npm run lint — clean (--max-warnings 0)
  • npm run typecheck — clean
  • npm run build — success; Client bundle secret surface check passed
  • npm run check:rag:fixtures — Offline RAG fixture and manifest validation passed (36 golden cases, 23 suites)
  • CI on head 5c8b586a — run 31028743070: PR required success; Production UI critical + shards 1/2/3 success; Build / Static PR / Unit coverage / Safety and config checks success
  • Cursor Bugbot on the fix head — no bugs found
  • Physical iPhone Safari / installed-PWA acceptance is still not covered — Chromium evidence never closes that gap, and for a notch/safe-area change a device is what would settle it definitively.

UI verification not run locally: Playwright lock/browser mismatch in this environment (playwright: installed 1.62.0 does not match locked 1.62.1 / Chromium build mismatch). Tracked as ledger #240. Equivalent Chromium evidence was produced by CI on matching browsers (listed above).

Risk and rollout

  • Risk: low. max() means the padding can only grow to the safe-area inset, never shrink below the existing 0.75rem/1.25rem, so on a device with no inset the rendering is unchanged. The min-h-tap row around the back control is additive. Colour-coding gets the same treatment as privacy so the notch exposure is not left on the other standalone shell page.
  • Rollback: git revert the fix commits; nothing else depends on the new primitive beyond the two call sites.
  • Provider or production effects: None. No dependency, schema, runtime, or deployment change.

Clinical Governance Preflight

  • Source-backed claims still require linked source verification before clinical use
  • No patient-identifiable document workflow was introduced or expanded without explicit governance approval
  • Supabase target remains Clinical KB Database (sjrfecxgysukkwxsowpy)
  • Service-role keys and private document access remain server-only
  • Demo/synthetic content remains clearly separated from real clinical sources
  • Source metadata, review status, and outdated/unknown-source behavior remain conservative
  • Deployment classification/TGA SaMD impact was checked when clinical decision-support behavior changed

This section is completed because scripts/pr-policy.mjs classifies src/app/privacy/** as a clinical-risk path. The change itself is top padding and a control row height: it alters no clinical content, no source governance, no document access, and no privacy behaviour, so every item above holds unchanged rather than by remediation.

RAG impact: no retrieval behaviour change — CSS padding on standalone policy/reference pages; no file under any retrieval, ranking, selection, or answer surface is touched.

/privacy sits outside the search shell, so it owns the OS top inset itself.
searchPageShell's py-3 top pad is not enough under a status bar or Dynamic
Island when apple-mobile-web-app-status-bar-style=black-translucent, leaving
the back control partly behind the notch.
Replaces the top pad with max(0.75rem, var(--safe-area-top)) (1.25rem at sm)
and gives the back control a min-h-12 row, matching this repo's 48px
production tap-target rule rather than the generic 44px guidance.
Split out of the stale draft PR #1582, which mixed this production fix with
three redesign mockups and 4.2 MB of PNG screenshots and has been red since
2026-08-02 on an unrelated type-scale violation (text-[10px]) in one of those
mockup components. The fix is independent of that work and does not need to
wait for it.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01T97Kqdj9Xh1Cubv5ms3KVy
@coderabbitai

coderabbitaiBot commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in:27 minutes

Your organization has reached its usage spending cap. Adjust your spending cap in the billing tab.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 6b51da94-39a4-4c0b-89fd-705c140d9273

📥 Commits

Reviewing files that changed from the base of the PR and between 98b65ae and e98e064.

📒 Files selected for processing (5)
  • docs/branch-review-ledger.md
  • src/app/privacy/page.tsx
  • src/app/reference/colour-coding/page.tsx
  • src/components/ui-primitives.tsx
  • tests/search-page-shell-standalone.contract.test.ts

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

@supabase

supabaseBot commented Aug 5, 2026

Copy link
Copy Markdown

This pull request has been ignored for the connected project sjrfecxgysukkwxsowpy because there are no changes detected in supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@BigSimmo
BigSimmo marked this pull request as ready for review August 5, 2026 15:19

@devin-ai-integrationdevin-ai-integrationBot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 1 additional finding.

Open in Devin Review

cursoragentand others added 3 commits August 5, 2026 16:24
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
Extract searchPageShellStandalone so /privacy and /reference/colour-coding
own the OS top inset without py-/pt- override ordering, use min-h-tap for
the back row, and pin the contract with a static render test.
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
@cursor

cursorBot commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Addressed the three standalone-shell review notes on this head (efc29559):

  1. Colour-coding notch exposure/reference/colour-coding now uses the same shared searchPageShellStandalone primitive as /privacy, so both standalone pages own max(safe-area-top) instead of bare searchPageShellpy-3.
  2. pt-* override / Tailwind sort order — the safe-area top pad is baked into searchPageShellStandalone with nopy-* axis padding, so cn() no longer depends on side-vs-axis utility ordering. Contract: tests/search-page-shell-standalone.contract.test.ts.
  3. min-h-12min-h-tap — back-control rows on both pages use the canonical min-h-tap token.

Also synced main (merge-tree clean; no content conflicts). Cursor Bugbot on the fix head reported no bugs. Local: focused surface tests 32/32; full npm run test 5331 passed / 4 skipped.

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
@cursor
cursorBotforce-pushed the claude/privacy-notch-safe-area branch from ef92d62 to 23a4b8fCompareAugust 5, 2026 17:04
devin-ai-integration[bot]

This comment was marked as resolved.

cursoragentand others added 2 commits August 5, 2026 17:09
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
…safe-area
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
devin-ai-integration[bot]

This comment was marked as resolved.

@BigSimmo
BigSimmo enabled auto-merge (squash) August 5, 2026 19:30
@BigSimmo
BigSimmo disabled auto-merge August 5, 2026 19:30
@BigSimmo
BigSimmo enabled auto-merge (squash) August 5, 2026 19:30
@github-actions

Copy link
Copy Markdown
Contributor

CI triage

CI failed on this PR. Automated classification of the 2 failed job(s):

  • Production UI (3)needs investigation: inspect the failing step and uploaded diagnostics; rerun only after classifying the cause.
  • PR requiredneeds investigation: inspect the failing step and uploaded diagnostics; rerun only after classifying the cause.

Compared with main CI run #8289 (cancelled).

Classification is evidence routing, not permission to ignore a failure. Exact quarantined Playwright identities remain governed by the flake ledger.

@cursor
cursorBot disabled auto-merge August 5, 2026 20:00
@cursor
cursorBot enabled auto-merge (squash) August 5, 2026 20:00
@cursor
cursorBot merged commit 41d865c into mainAug 5, 2026
26 checks passed
@cursor
cursorBot deleted the claude/privacy-notch-safe-area branch August 5, 2026 20:16
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@BigSimmo@claude@cursoragent