<html>
<head>
    <title>animation</title>
    <style>
        div{
            width: 100px;
            height: 100px;
            background-color: #00b3ee;
        }
        /*动画过程控制器*/
        @-webkit-keyframes firstDiv{
            10%{
                background-color: #a94442;
                width: 200px;
                height: 200px;
            }
            30%{
                background-color: #398439;
                width: 200px;
                height: 200px;
            }
            50%{
                background-color: #afd9ee;
                width: 300px;
                height: 300px;
            }
            80%{
                background-color: #ffff00;
                width: 370px;
                height: 370px;
                transform:rotate(30deg);
            }
            100%{
                background-color: #ffff00;
                width: 500px;
                height: 500px;
                transform:rotate(60deg);
            }
        }
        div:hover{
            -webkit-animation-name: firstDiv;
            -webkit-animation-duration: 5s;
            -webkit-animation-timing-function:linear;
            -webkit-animation-iteration-count:infinite;
        }
    </style>
</head>
<body>
<div>动画div</div>
</body>
</html>

  

相关文章:

  • 2021-12-23
  • 2021-10-02
  • 2022-12-23
  • 2022-02-19
  • 2021-04-22
猜你喜欢
  • 2022-01-10
  • 2021-09-05
  • 2022-12-23
  • 2022-12-23
  • 2021-05-03
  • 2022-12-23
相关资源
相似解决方案