Skip to content

Fix black band under phone content when iOS Safari toolbar collapses#732

Merged
BigSimmo merged 8 commits into
mainfrom
claude/edge-to-edge-content-lv9x7k
Jul 17, 2026
Merged

Fix black band under phone content when iOS Safari toolbar collapses#732
BigSimmo merged 8 commits into
mainfrom
claude/edge-to-edge-content-lv9x7k

Conversation

@BigSimmo

@BigSimmo BigSimmo commented Jul 17, 2026

Copy link
Copy Markdown
Owner

Summary

  • Fix the dead black band that appeared between the app content and the browser toolbar on iPhone: when iOS Safari's bottom toolbar collapsed/expanded, the phone shell — a position: fixed; inset: 0 box that also forced height: 100dvh — kept a stale dvh height (iOS resolves dvh lazily, especially with body scrolling disabled) and its overflow-hidden clipped everything below it.
  • Size the phone shell from its fixed insets alone (max-sm:inset-0, no h-dvh; inner column max-sm:h-full). Fixed insets track Safari's live viewport through the whole toolbar transition, so content now fills the screen edge to edge and shows through under the minimized glass bar (viewport-fit=cover was already set).
  • Apply the same dvh → full swap to the other phone-fullscreen surfaces that shared the hazard: the fullscreen Sheet variant, the left drawer, the settings dialog, and the fullscreen document-scope sheet. Each already sits inside a fixed inset-0 backdrop, so percentage sizing resolves against the live viewport. Desktop (sm:/lg:) sizing is unchanged.

Verification

  • npm run typecheck — 0 errors
  • npm run lint — clean
  • npm run test — 2681 passed; the single failure (tests/pdf-extraction-budget.test.ts child-process kill) fails identically on a clean tree in this container (sandbox signal limitation), pre-existing
  • npm run verify:ui — 216/217 passed. The one failure (ui-smoke.spec.ts › document viewer PDF canvas on mobile) reproduces identically on the base commit without this change in the same container (pdf.js canvas does not render under the container's substituted Chromium headless-shell build), so it is environment-caused and not a regression of this diff; the failure screenshot shows the surrounding shell/layout rendering correctly
  • npm run verify:pr-local not run: lint, typecheck, unit suite, and the UI gate were run individually; no RAG fixture/manifest surface touched
  • The stale-dvh behavior itself only reproduces on iOS Safari hardware during toolbar collapse, which local Chromium cannot simulate — please confirm on-device that content now fills the space when the bottom bar hides

Risk and rollout

  • Risk: low — class-string-only change to phone layout sizing; each edited box's height source moves from the 100dvh unit to its already-present inset-0/definite-height parent, which computes the same value when dvh is fresh
  • Rollback: revert commit c6870c4
  • Provider or production effects: None

Clinical Governance Preflight

Presentation-layer sizing change only; every invariant below is untouched by the diff and still holds.

  • 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

Notes

  • cn is a plain join (no tailwind-merge), so the fullscreen scope sheet's contentClassName was switched to max-h-full in the same commit to keep it identical to the new Sheet fullscreen base class and avoid an order-dependent max-h conflict.

🤖 Generated with Claude Code

https://claude.ai/code/session_01CkCda13HLjNhg7oDycmoSh

Summary by CodeRabbit

  • Bug Fixes
    • Improved mobile global search and dialog layouts during browser toolbar transitions.
    • Eliminated dead space beneath fullscreen sheets on iOS Safari.
    • Improved height handling for fullscreen scope pickers and settings dialogs.
    • Enhanced small-screen content sizing and scrolling behavior.

Size the fixed phone shell and fullscreen overlays from their inset-0
containers instead of 100dvh. iOS Safari re-resolves dvh lazily while its
bottom toolbar collapses/expands (especially with body scrolling
disabled), so the dvh-sized shell kept its stale shorter height and
clipped content, leaving a dead black band above the toolbar. Fixed
insets track the live viewport through the whole transition, so content
now fills the screen edge to edge.

Same dvh -> full swap applied to the fullscreen Sheet variant, the left
drawer, the settings dialog, and the fullscreen scope sheet, which shared
the identical hazard.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CkCda13HLjNhg7oDycmoSh
@supabase

supabase Bot commented Jul 17, 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 ↗︎.

@coderabbitai

coderabbitai Bot commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: bd242074-9930-4d1e-a60e-d40c63c20c91

📥 Commits

Reviewing files that changed from the base of the PR and between a917168 and 5dd2307.

📒 Files selected for processing (4)
  • src/components/clinical-dashboard/global-search-shell.tsx
  • src/components/clinical-dashboard/master-search-header.tsx
  • src/components/clinical-dashboard/settings-dialog.tsx
  • src/components/ui/sheet.tsx

📝 Walkthrough

Walkthrough

Mobile search shells, sheets, and dialogs replace dynamic viewport-height sizing with fixed inset tracking or full-container height constraints to handle mobile toolbar transitions.

Changes

Mobile viewport sizing

Layer / File(s) Summary
Search shell viewport tracking
src/components/clinical-dashboard/global-search-shell.tsx
The mobile shell uses fixed viewport insets and a full-height flex wrapper while preserving overflow containment.
Fullscreen sheet and dialog sizing
src/components/ui/sheet.tsx, src/components/clinical-dashboard/master-search-header.tsx, src/components/clinical-dashboard/settings-dialog.tsx
Fullscreen sheet, document scope sheet, and settings dialog containers use h-full or max-h-full instead of dynamic viewport-height utilities.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

Suggested reviewers: claude

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed It clearly summarizes the main fix: removing the iOS Safari black band during toolbar collapse.
Description check ✅ Passed The description follows the template and includes summary, verification, risk, governance, and notes.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
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.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch claude/edge-to-edge-content-lv9x7k

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

@BigSimmo
BigSimmo marked this pull request as ready for review July 17, 2026 18:04
@BigSimmo
BigSimmo enabled auto-merge July 17, 2026 18:25
BigSimmo and others added 5 commits July 18, 2026 02:40
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
@BigSimmo
BigSimmo merged commit ad2752d into main Jul 17, 2026
15 checks passed
@BigSimmo
BigSimmo deleted the claude/edge-to-edge-content-lv9x7k branch July 17, 2026 19:14
cursor Bot pushed a commit that referenced this pull request Jul 17, 2026
Capture merge-readiness outcomes for the screenshot PR queue after
hosted CI babysitting and the #739 privacy/UI follow-up fixes.

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
cursor Bot pushed a commit that referenced this pull request Jul 17, 2026
Capture merge-readiness outcomes for the screenshot PR queue after
hosted CI babysitting and the #739 privacy/UI follow-up fixes.

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
cursor Bot pushed a commit that referenced this pull request Jul 17, 2026
Capture merge-readiness outcomes for the screenshot PR queue and keep
the historical ledger out of Prettier realignment.

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
cursor Bot pushed a commit that referenced this pull request Jul 17, 2026
Capture merge-readiness outcomes for the screenshot PR queue and keep
the historical ledger out of Prettier realignment.

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
Sign up for free to 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