animate-css / animate.css

🍿 A cross-browser library of CSS animations. As easy to use as an easy thing.
https://animate.style/
Other
80.14k stars 16.24k forks source link

Keep the element at the end of its animation values #1672

Closed crileyy closed 1 year ago

crileyy commented 1 year ago

Is your feature request related to a problem? Please describe.

Currently, I'm using the slideOutRight and slideOutLeft animations, but after the animation finishes, the elements return to their original position, which causes a flicker in my use case. Is there a way to maintain the end position/state of the element after the animation? I'm thinking of something like animation-fill-mode: 'forwards'

Describe the solution you'd like.

An option to have the element stay where it is at the end of the animation, like setting animation-fill-mode: 'forwards'.

Describe alternatives you've considered.

Nothing seems to work to do this.

Additional Context

No response

Sartharian commented 1 year ago

haha, perhaps u didn't read the doc before: the default fill mode animation is "both", so u must define ur own 'forwards' fill mode class implementation. See my answer here #1663 =)