Animate the tabletop layout switch on hinge changes

This commit is contained in:
Arkadiusz Fal
2026-10-01 06:46:06 +02:00
parent 8a8f3a6000
commit 2d65bc756f

View File

@@ -362,6 +362,12 @@ struct ExpandedPlayerSheet: View {
standardPlayerContent(geometry: geometry)
#endif
}
#if os(iOS)
// Applied inside the animation-stripping transaction below so the
// hinge-driven tabletop switch still animates the video between
// the screen center and the upper half.
.animation(.easeInOut(duration: 0.3), value: isTabletopHinge)
#endif
.transaction { transaction in
// Disable animations during layout switch to prevent position interpolation
transaction.animation = nil