zoukankan      html  css  js  c++  java
  • loading实现

    loading1:

    布局实现:

    <div class="out">
    <div class="in">

    </div>
    </div>

    style  css3动画属性实现loading

    .out{
    margin: 0 auto;
    46px;
    height: 46px;
    background: linear-gradient(black,white) ;
    border-radius: 50%;
    text-align: center;
    overflow: hidden;

    }
    .in{
    40px;
    height: 40px;
    background: white;
    margin-top:3px;
    margin-left:3px;
    border-radius: 50%;
    }
    .out{
    animation: move 1s ease infinite;

    }
    @keyframes move{
    0%{transform: rotate(0deg);}
    0%{transform: rotate(360deg);}
    }

    loading2:

    布局:

    <div class="pencil">
    <div class="pen">

    </div>
    <div class="pen">

    </div>
    <div class="pen">

    </div>
    <div class="bottom">
    </div>
    </div>

    样式实现:

    .pencil{
    margin: 0 auto;
    200px;
    height: 30px;
    /*border-bottom: 5px solid #ccc;*/
    position: relative;
    }
    .pencil>div{
    float: left;
    margin-left:15px ;

    }
    .pen{
    3px;
    height:30px ;
    background: black;
    transform-origin: center bottom;
    }
    .pen:nth-child(1){
    animation: move1 1s infinite;
    }
    .pen:nth-child(2){
    animation: move2 1s infinite;

    }
    .pen:nth-child(3){
    animation: move3 1s infinite;
    }
    .bottom{
    position: absolute;
    10px;
    height: 5px;
    background: violet;
    margin: 0 auto;
    bottom: -5px;
    animation: move4 1s infinite;
    }
    @keyframes move4{
    0%{ 10px;}
    100%{ 65px;}
    }
    @keyframes move1{
    0%{transform: rotate(0deg);}
    30%{transform: rotate(75deg);}
    100%{transform: rotate(90deg);}
    }
    @keyframes move2{
    0%{transform: rotate(0deg);}
    60%{transform: rotate(80deg);}
    100%{transform: rotate(90deg);}
    }
    @keyframes move3{
    0%{transform: rotate(0deg);}
    100%{transform: rotate(90deg);}
    }

  • 相关阅读:
    如何免费在 arm 官网上下载合适的手册
    ARM Cortex-A系列处理器性能分类比较
    USB OTG有关协议
    fseek在 fopen 带有'a'模式下不起作用
    Zynq 7000的3种IO
    多核处理器与MP架构
    Vim常用插件命令手册
    剑指 Offer 07
    Leetcode 94
    剑指offer 27
  • 原文地址:https://www.cnblogs.com/luxinyi/p/9710013.html
Copyright © 2011-2022 走看看