Transitions
Last updated
Last updated
Motion transitions a source view to a destination view using a linking identifier property named motionIdentifier
.
An example of transitioning from one view controller to another with transitions:
The above code snippet tells the source views in view controller 1
to link to the destination views in view controller 2
using the motionIdentifier
. Animations may be added to views during a transition using the transition method. The transition method accepts MotionTransition structs that configure the view's animation.
Motion offers default transitions that may be used by UINavigationControllers, UITabBarControllers, and presenting UIViewControllers.
An example of transitioning from one view controller to another using a UINavigationController with a zoom transition:
To add an automatic reverse transition, use autoReverse
.
Match
Translate
Rotate
Arc
Scale
Push
Slide
ZoomSlide
Cover
Page
Fade
Zoom