fix(snapshot): stop a SwiftUI toolbar host from covering the sheet it encloses

Merged
OK
2mo ago
+352-2

Summary

On iOS 27, SwiftUI sheet toolbar hosts could mark the sheet's controls as covered, refusing press @ref and fill @ref.

Exempt a host only when every bar or scroll container it encloses belongs to its own presentation, between the previous toolbar sibling and the host. Scroll indicators do not count. Stacked presentations retain coverage. The documented full-viewport cover limitation remains.

Two capture-kit files changed. Cleanup removes 21 lines from the previous PR head: no sibling lookup wrapper or temporary enclosed-region array; the original sibling-size rule stays intact.

Validation

  • Final cleanup commit: 66185eb2af.
  • pnpm check:affected --run: 433 files / 3065 tests passed; formatting, lint, typecheck, layering, Fallow, and build passed.
  • pnpm check:fallow --base origin/main: passed.
  • Regression proof: retained fixtures fail on pre-fix main (7 failed / 18 passed), pass with the fix (25 passed). A temporary differential run matched the previous PR head on all 25 fixtures.
  • Previous head 1e9748ca4: all executed CI checks passed. Existing contributor-reported live iOS 27 evidence covers fullScreenCover over sheet, sheet over sheet/plain screen, medium/large/barless sheets, and upper/lower press @ref behavior.
  • Cleanup head 66185eb2af: all executed CI checks passed, including Coverage, Integration Tests, and Smoke Tests. All five inline review threads are resolved. Copilot could not provide a new review because its quota was exhausted. No new live simulator run; the cleanup retains the same presentation rule and fixtures.