Research (iOS 27.1 SDK, Xcode 27.1)
What the system offers
- UIKit:
UIHingeInteraction (UIHingeInteraction.h) and UIHinge (UIHinge.h), iOS 27.1+. You add the interaction to a view. Its handler is called with the initial state and again on every change, with update.hinge. That is nil when the view's hierarchy has no hinge (any other iPhone, or the outer screen). UIHinge has a status (unknown, closed, partiallyOpen, fullyOpen) and an angle in radians. Apple says to prefer status over the angle, whose update rate and precision are system policy.
- SwiftUI:
View.onHingeChange(isEnabled:_:) passes the old and new DeviceHingeContext (hinge: DeviceHinge?, which has status and angle: Angle), also iOS 27.1+. Unlike the UIKit interaction, it doesn't promise a call with the initial state, so the app uses the UIKit interaction.
- Nothing gives the crease's position or size. There's no safe area, layout guide, trait or "display feature" for it. I searched the UIKit headers and the SwiftUI/SwiftUICore interfaces for hinge, crease and fold. So the app has to assume where the crease is.
- The screens (simulator): inner 951×669 pt, landscape with the book open; outer 466×678 pt, with no crease. The app deploys to iOS 26, so all of this is behind
#available(iOS 27.1, *).
- Apple's own apps: I couldn't check them. The simulator can't be partly folded from the command line, so how Apple lays out across the crease is still to be seen on a device or in Simulator's UI.
Assumption adopted (documented in code): the crease runs through the middle of the inner screen, parallel to its shorter side. It's vertical when the screen is wider than tall (book), horizontal when taller than wide (tabletop). It counts only while the hinge is partiallyOpen; flat (fullyOpen), closed or unknown, the layout is unchanged. Content keeps out of a 24 pt band centred on it.
Plan: an observer at the root of the app's window and of the lock's overlay window publishes \.crease in the environment (injectable for tests). The lock screen and covers lay out like an open book, or top and bottom when tabletop. The sidebar meets the content column at the crease. The feed adds a gutter over the crease when it spans it. The item page keeps its content to one page.