zoukankan      html  css  js  c++  java
  • transform钟表动画

    <!DOCTYPE html>
    <html>
     <head>
      <meta charset="UTF-8">
      <title></title>
      <style type="text/css">
       *{
        margin: 0;
        padding: 0;
       }
       div{
        box-sizing: border-box;
       }
       #clock{
         200px;
        height: 200px;
        border: 4px solid brown;
        border-radius: 50%;
        position: relative;
       }
       #minute{
         6px;
        height: 60px;
        background-color: orangered;
        position: absolute;
        top: 40px;
        left: 94px;
        /*更换圆心点*/
        transform-origin: bottom;
        /*调用动画*/
        -webkit-animation: run 3600s linear 0s infinite;
       }
       #second{
         4px;
        height: 80px;
        background-color: cadetblue;
        position: absolute;
        top: 20px;
        left: 95px;
        /*更换圆心点*/
        transform-origin: bottom;
        /*调用动画*/
        -webkit-animation: run 60s linear 0s infinite;
       }
       
       
       /*声明动画*/
       @-webkit-keyframes run{
        from{transform: rotate(0deg);}
        to{transform: rotate(360deg);}
       }
      </style>
     </head>
     <body>
      <div id="clock">
       <div id="minute"></div>
       <div id="second"></div>
      </div>
     </body>
    </html>

  • 相关阅读:
    php-beanstalkd消息队列类分享
    php curl抓取类分享
    df -i 100%时处理方法
    php生成红包
    PHP牛牛游戏算法
    Yii 框架不同逻辑处理方法统一事务处理
    Linux上web服务器搭建
    Linux 上pcntl安装步骤
    PHP错误级别设置
    day40 ,epoll,数据库相关概念
  • 原文地址:https://www.cnblogs.com/KiligYou/p/11060754.html
Copyright © 2011-2022 走看看