animation——鼠标放上图片旋转

效果展示:

话不多说,直接上代码

<p><img class="demo" src="../../img/pageimg/qyyw_icon1.png"></p>
@keyframes bouncing{
   0%  {transform: rotate(0deg)}
   100%{transform: rotate(360deg)}
}
.demo:hover{
   animation: bouncing 0.5s Linear 0s 1 alternate both;
}

 

posted @ 2020-08-26 17:55  琼菇凉  阅读(173)  评论(0编辑  收藏  举报