zoukankan      html  css  js  c++  java
  • jquery图片滚动

    <!DOCTYPE html>
    <html lang="zh">
    <head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>页面滚动时动态为元素添加class的jQuery插件</title>

    <link href="http://cdn.bootcss.com/bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet"><!--可无视-->

    <link rel="stylesheet" type="text/css" href="css/demo.css"><!--可无视-->

    <link rel="stylesheet" href="css/animate.css"><!--必要文件-->

    <style type="text/css">
    html,
    body {
    font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
    }
    body {
    margin: 0 auto;
    padding: 0;
    }

    [data-animation] {
    opacity: 0;
    }

    [data-animation].animated {
    opacity: 1;
    }

    #hero {
    background: radial-gradient(circle at 50% center, #dee294 0%, #b7bd32 70%);
    height: 100vh;
    text-align: center;
    }

    #hero h1 small {
    font-size: 50%;
    }

    .table-wrap {
    display: table;
    height: 100%;
    100%;
    }

    .table-cell {
    display: table-cell;
    vertical-align: middle;
    }

    #lower {
    background: radial-gradient(circle at 50% center, #f0c916 0%, #ccad1a 70%);
    overflow: hidden;
    text-align: center;
    min-height: 600px;
    padding: 150px 0;
    }

    #lower img {
    -webkit-border-radius: 50%;
    -moz-border-radius: 50%;
    border-radius: 50%;
    }
    </style>


    </head>
    <body>

    <section id="hero">

    <div class="table-wrap">
    <div class="table-cell">
    <h1 class="heading" data-animation="fadeInUp">
    页面滚动查看效果 <br>
    <small>(hint: scroll down)</small>
    </h1>
    </div>
    </div>

    </section>

    <section id="lower" data-animation-container>

    <h1 data-animation="fadeIn" data-animation-child>
    An animation set!
    </h1>

    <div class="container">
    <div class="row">

    <div class="col-sm-4" data-animation-child data-animation="fadeInUp" data-animation-delay="500ms">
    <img src="img/1.jpg" alt="" class="img-responsive center-block">
    </div>
    <div class="col-sm-4" data-animation-child data-animation="fadeInUp" data-animation-delay="1500ms">
    <img src="img/2.jpg" alt="" class="img-responsive center-block">
    </div>
    <div class="col-sm-4" data-animation-child data-animation="fadeInUp" data-animation-delay="2500ms">
    <img src="img/3.jpg" alt="" class="img-responsive center-block">
    </div>

    </div>
    <!-- /.row -->
    </div>
    <!-- /.container -->

    </section>

    <script type="text/javascript" src="js/jquery-1.11.0.min.js"></script>
    <script type="text/javascript" src="js/jquery.scrollAnimations.min.js"></script>
    <script type="text/javascript">
    (function(){
    var $containers = $('[data-animation]:not([data-animation-child]), [data-animation-container]');
    $containers.scrollAnimations();
    }());
    </script>

    </body>
    </html>

  • 相关阅读:
    安卓基础值之Intent
    输入值/表单提交参数过滤有效防止sql注入的方法
    一致性hash
    linux授权某个用户对某个目录有读写的权限
    mysql分区功能详细介绍,以及实例
    SVN分支与主干
    solr查询
    mysql-proxy做客户端连接转发【外网访问内网mysql】
    liunx 下安装 php_screw 扩展 以及报错处理
    邮件发送
  • 原文地址:https://www.cnblogs.com/xiaomiaotong/p/9524520.html
Copyright © 2011-2022 走看看