I’m testing a SwiftUI app on the iPhone Duo simulator running iOS 27.1 and have noticed some unexpected behaviour when using pinned Picture in Picture.
When the device is unfolded in portrait and a PiP video is pinned to the top of the display, the available app height drops significantly, but verticalSizeClass remains .regular.
For comparison, these are the values reported by GeometryReader:
| Unfolded landscape | 867 × 611 | .regular | .regular |
| Unfolded portrait | 669 × 786 | .regular | .regular |
| Unfolded portrait + pinned PiP | 669 × 348 | .regular | .regular |
I’d expected the vertical size class to become .compact when pinned PiP reduces the available height to approximately 348 points.
Is this intentional behaviour, with size classes remaining tied to the unfolded display configuration rather than the available app window dimensions, or is it potentially a bug in iOS 27.1?
I’m currently working around it by checking the available geometry directly, but I’d be interested to know what the recommended approach is for adapting SwiftUI layouts in this configuration.