The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript When Animation Finishes Do Something

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #44422

    I’m using some animation and am trying to work out how to add a class when the animation has finished.

    For example, when this animation reaches the final keyframe (100%) I want to add a class.

    @-webkit-keyframes bounceOutDown {
    0% {
    -webkit-transform: translateY(0);

    20% {
    opacity: 1;
    -webkit-transform: translateY(-20px);

    100% {
    opacity: 0;
    -webkit-transform: translateY(2000px);

    Is this possible?

    Any help is appreciated. Thanks in advance.


    That would require Jquery. Try this. []( “”)

    That’s the same animation. Just tweak the numbers a bit to fit your needs, and add what you want it to do after the animation is complete where i included the comment.

    Basically if you want something to happen after the animation you should use Jquery for the entire animation instead of css.

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘JavaScript’ is closed to new topics and replies.