zoukankan      html  css  js  c++  java
  • 自适应卷轴展开效果

    <!DOCTYPE html>
    <html>
    <head lang="en">
        <meta charset="UTF-8">
        <title></title>
        <script src="http://cdn.static.runoob.com/libs/jquery/1.10.2/jquery.min.js"></script>
        <style>
            /*content*/
            .content{
                position: relative;
                margin: 40px auto 0;
                 80%;
                height: 300px;
                background:#2e2e2e;
                margin: 30px auto;
    
    
            }
            .l-pic-index{
                position: absolute;
                left: 50%;
                top: 1px;
                z-index:2;
                10%;
                height:100%;
                /*background: url("./images/left.png") no-repeat right 0;*/
                background-color:orange;
                margin-left:-10%;
            }
            .icon-pic-img{100%;height:100%}
            .r-pic-index{
                position: absolute;
                right: 50%;
                top: 0;
                z-index: 2;
                margin-right:-10%;
                10%;
                *10%;
                height:100%;
                /*background: url("./images/right.png") no-repeat left 0;*/
                background-color:yellow;
            }
            .l-bg-index{
                position: absolute;
                top: 0;
                left: 45%;
                z-index: 1;
                 5%;
                height: 100%;
                background-color: #fff;
                margin-left:5%
            }
            .r-bg-index{
                position: absolute;
                top: 0;
                right: 45%;
                z-index: 1;
                 5%;
                margin-right:5%;
                height:100%;
                background-color: #fff;
            }
            .main-index{
                display: none;
                overflow: hidden;
                zoom:1;
                position: absolute;
                z-index: 5;
                100%;
                height:100%;
                left:0px;
                top:10px;
                padding:10%;
                color: #2e2e2e;
                box-sizing: border-box;
            }
    
        </style>
    </head>
    <body>
    <div class="content">
        <div class="l-pic-index"><img  src="./images/left.png" class="icon-pic-img"/></div>
        <div class="r-pic-index"><img  src="./images/right.png" class="icon-pic-img"/></div>
        <div class="l-bg-index"></div>
        <div class="r-bg-index"></div>
        <div class="main-index">
            <h1 class="title">详细介绍</h1>
            <p class="intro-text">
                传统音乐是在以典河流域为中心的中原音乐和四域音乐以及外国音乐的交流融合之中形成发展起来的。
            </p>
        </div>
    </div>
    <script>
        $(document).ready(function(){
    
    
            //卷轴展开效果
           $(".l-pic-index").animate({'left':'10%'},1500);
            $(".r-pic-index").animate({'right':'10%'},1500);
         $(".l-bg-index").animate({'width':'45%'},1500);
         $(".r-bg-index").animate({'width':'45%'},1500,function(){
                $(".main-index").fadeIn(800);
          });
        });
    </script>
    </body>
    </html>

  • 相关阅读:
    Hystrix使用说明,配置参数说明
    服务限流 -- 自定义注解基于RateLimiter实现接口限流
    Java生产环境下问题排查
    Java垃圾回收(GC)机制详解
    RabbitMQ如何解决各种情况下丢数据的问题
    JWT如何在Spring Cloud微服务系统中在服务相互调时传递
    LeetCode 117th Weekly Contest 总结
    系统设计总结
    单调栈总结
    LeetCode 116th Weekly Contest 总结
  • 原文地址:https://www.cnblogs.com/guanguan-/p/8001112.html
Copyright © 2011-2022 走看看