如何减慢侧面板行扫描速度

时间:2016-02-20 14:54:56

标签: javascript jquery css twitter-bootstrap

当屏幕小于768px时,会出现引导程序侧面板。我的面板非常快,我想让它慢慢显示。你能否给我一些关于jquery代码中缺失部分的提示?

HTML标记:

<div class="row row-offcanvas row-offcanvas-left">
    <!-- sidebar -->
    <div class="col-xs-6 col-sm-3 sidebar-offcanvas" id="sidebar" role="navigation">
        <ul class="nav">
            <li class="active"><a href="#">Home</a></li>
            <li><a href="#">Link 1</a></li>
            <li><a href="#">Link 2</a></li>
            <li><a href="#">Link 3</a></li>              
        </ul>
    </div>
    <!-- main area -->
    <div class="col-xs-12 col-sm-9">
        <h1>Shrink Width to Collapse Sidebar</h1>
 </div></div>

jQuery代码:

$(document).ready(function() {
  $('[data-toggle=offcanvas]').click(function() {
    $('.row-offcanvas').toggleClass('active');
  });
});

0 个答案:

没有答案