Whenever you update a page fragment you can animate the change.
Let's say you are using an
up-target link to update an element
with content from the server. You can add an attribute
to smoothly fade out the old element while fading in the new element:
<a href="/users" up-target=".list" up-transition="cross-fade">Show users</a>
When we morph between an old and a new element, we call it a transition. In contrast, when we animate a new element without simultaneously removing an old element, we call it an animation.
An example for an animation is opening a new dialog. We can animate the appearance
of the dialog by adding an
[up-animation] attribute to the opening link:
<a href="/users" up-modal=".list" up-animation="move-from-top">Show users</a>
Applies the given animation to the given element.
Defines a named animation.
Performs an animated transition between the
Returns whether Unpoly will perform animations.
Defines a named transition.
Sets default options for animations and transitions.