How to keep styles after animation?

后端 未结 2 1542
不知归路
不知归路 2020-12-09 08:02

I\'m working at a portfolio to show when I apply for my next study. Since we\'re living in 2012, it has tons of fancy animations and CSS3 junk, just to give them the \'We ne

相关标签:
2条回答
  • 2020-12-09 08:46

    Duopixels answer is the right way, but not totally cross-browser, however, this jquery plugin enables animation callbacks and you can style the elements how you like in the callback function: https://github.com/krazyjakee/jQuery-Keyframes

    0 讨论(0)
  • 2020-12-09 08:49

    Try with:

    #fadein {
      -webkit-animation-fill-mode: forwards; /* Chrome 16+, Safari 4+ */
      -moz-animation-fill-mode: forwards;    /* FF 5+ */
      -o-animation-fill-mode: forwards;      /* Not implemented yet */
      -ms-animation-fill-mode: forwards;     /* IE 10+ */
      animation-fill-mode: forwards;         /* When the spec is finished */
    }
    
    0 讨论(0)
提交回复
热议问题