day09

作者: 孔子曰_f425 | 来源:发表于2017-09-05 21:27 被阅读0次

    A我今天学了什么

    动画animation
    //定义:@keyframes (//关键帧)

    1、@keyframes myfirst
    {
    form{background:red;}
    to{background:yellow;}
    }
    
    列子:
    //HTML
    <div class="box"></div>
    
    .box{
                width: 100px;
                height: 100px;
                background-color: orange;
      @keyframes aa {
                from{
                    width: 100px;
                    height: 100px;
                    background-color: orange;
                }
                to{
                    width: 200px;
                    height: 200px;
                    background-color: yellow;
                }
            }
    
    
    2、@keyframes myfirst
    {
    0%{background:red;}
    25%{background:yellow;}
    50%{background:blue;}
    100%{background:green;}
    }
    
    列子:
    //HTML
    <div class="box"></div>
    
    //CSS
       /*.box:hover{*/
                /*animation: bb 15s ;*/
            /*}*/
    
     @keyframes  bb {
                0%{
                    width: 100px;
                    height: 100px;
                    background-color: orange;
                }
                20%{
                    width: 400px;
                    height: 100px;
                    background-color: yellow;
                }
                40%{
                    width: 100px;
                    height: 100px;
                    background-color: yellow;
                }
                60%{
                    width: 100px;
                    height: 500px;
                    background-color: aquamarine;
                }
                80%{
                    width: 100px;
                    height: 300px;
                    background-color: orange;
                }
                100%{
                    width: 100px;
                    height: 500px;
                    background-color: orange;
                }
            }
    

    animation 动画片制作

    div {animation:myfirst 2s;}
    //动画片:我的第一次2秒
    
    div{animation:myfirst 2s infinite;}
    //无限循环
    

    B我今天掌握了什么

    动画animation
    //定义:@keyframes (//关键帧)

    1、@keyframes myfirst
    {
    form{background:red;}
    to{background:yellow;}
    }
    
    列子:
    //HTML
    <div class="box"></div>
    
    .box{
                width: 100px;
                height: 100px;
                background-color: orange;
      @keyframes aa {
                from{
                    width: 100px;
                    height: 100px;
                    background-color: orange;
                }
                to{
                    width: 200px;
                    height: 200px;
                    background-color: yellow;
                }
            }
    
    
    2、@keyframes myfirst
    {
    0%{background:red;}
    25%{background:yellow;}
    50%{background:blue;}
    100%{background:green;}
    }
    
    列子:
    //HTML
    <div class="box"></div>
    
    //CSS
       /*.box:hover{*/
                /*animation: bb 15s ;*/
            /*}*/
    
     @keyframes  bb {
                0%{
                    width: 100px;
                    height: 100px;
                    background-color: orange;
                }
                20%{
                    width: 400px;
                    height: 100px;
                    background-color: yellow;
                }
                40%{
                    width: 100px;
                    height: 100px;
                    background-color: yellow;
                }
                60%{
                    width: 100px;
                    height: 500px;
                    background-color: aquamarine;
                }
                80%{
                    width: 100px;
                    height: 300px;
                    background-color: orange;
                }
                100%{
                    width: 100px;
                    height: 500px;
                    background-color: orange;
                }
            }
    

    animation 动画片制作

    div {animation:myfirst 2s;}
    //动画片:我的第一次2秒
    
    div{animation:myfirst 2s infinite;}
    //无限循环
    

    C今天没有掌握的

    没有
    

    相关文章

      网友评论

          本文标题:day09

          本文链接:https://www.haomeiwen.com/subject/cjppjxtx.html