.matchedgeometryeffect

Hey, I want to make it so I can get the gauge in the left of the image) to move up into the top bar like in the right image. So the animation would be shrinking and moving up. The animation should occur as you scroll up. If you scroll back down it should animate back to show it again.

Replies

Checkout the sample code that came with the What's New in SwiftUI (you can copy it right out of the Developer app) as well as the Fruta sample project which includes an even more rich example of using matchedGeometryEffect.