首页 > Web开发 > 详细

2d旋转(css3实现过度效果和动画效果)

时间:2019-02-18 20:45:13      阅读:223      评论:0      收藏:0      [点我收藏+]

效果:

  技术分享图片

 

源码:

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style type="text/css">
        *{
            margin: 0px;
            padding: 0;
        }
        .box{
            width: 240px;
            margin: 100px auto;
        }
        /*过度效果*/
        /*.qq{*/
            /*transition: all 1s;*/
        /*}*/
        /*.qq:hover{*/
            /*transform: rotate(360deg);*/
        /*}*/
        /*动画效果*/
        .qq:hover{
            animation: zhuan 0.1s linear infinite;
        }
        @-webkit-keyframes zhuan {
            from{
                transform: rotate(0);
            }to{
            transform: rotate(360deg);
                         }
        }
    </style>
</head>
<body>
    <div class="box">
        <img src="zhuan.jpg" alt="" class="qq">
    </div>
<script type="text/javascript">

</script>
</body>
</html>

图片:

技术分享图片

2d旋转(css3实现过度效果和动画效果)

原文:https://www.cnblogs.com/alex-xxc/p/10397805.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!