Skip to content

Add adaptive sheet layout and safe-area demos for iPhone Duo - #72

Merged
muukii merged 1 commit into
mainfrom
muukii/duo-adaptive-sheet
Oct 9, 2026
Merged

muukii merged 1 commit into
mainfrom
muukii/duo-adaptive-sheet

Conversation

@muukii

@muukii muukii commented Oct 9, 2026

Copy link
Copy Markdown
Collaborator

Summary

Wide and folding windows currently stretch Rideau sheets across the host, and a presentation created at the closed size can leave its dimming view too narrow after expansion. Add an opt-in adaptive width policy that keeps the bottom-up presentation, limits and centers the sheet, and moves it into the leading region when a vertical division is active. The default remains .fullWidth.

  • Resolve sheet geometry from host bounds, layout direction, and reserved division regions, including region margins. Measure self-sizing content at the resulting width while preserving its content and selected snap point.
  • Size the presentation to UIKit's final frame and follow container resizing so dimming covers the full window. Make the accessible content guide respect lateral safe areas.
  • Upgrade Storybook from 2.9.1 to 3.2.2 and add adaptive scrolling, self-sizing, and safe-area previews to RideauDemo. The safe-area demo colors usable/excluded regions and displays live window/content right insets. Support source-qualified preview launch arguments and demo rotation.

Division handling is available on iOS 27.1 with the matching toolchain; earlier SDKs retain adaptive width and centering. The package's minimum deployment target and existing gesture implementation are preserved.

Validation

  • RideauDemo Debug build, install, and launch succeeded on the iOS 27.1 iPhone Duo Simulator with Xcode 27.1 Release Candidate.
  • All 14 SwiftPM tests passed: horizontal layout and RTL, fold changes, width-dependent self sizing, gesture-callback continuity, final presentation geometry, and dimming during resizing. The simulator test runner used an iOS 17 deployment override in a temporary package wrapper.
  • Final demo smoke check confirmed 84 pt window right inset and 76 pt content right inset, plus visible full-window dimming. Presentation was triggered through the existing button action with LLDB; this was not a physical-touch check. All postures were not re-exercised after integration with current main.
  • git diff --check passed.

@muukii
muukii merged commit 1caa2b8 into main Oct 9, 2026
2 checks passed
@muukii
muukii deleted the muukii/duo-adaptive-sheet branch October 9, 2026 09:47
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.

1 participant