加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 综合聚焦 > 服务器 > 安全 > 正文

twitter-bootstrap – 需要Bootstrap左侧导航示例

发布时间:2020-12-17 20:38:45 所属栏目:安全 来源:网络整理
导读:寻找一些干净简单的示例来设置响应式左侧导航,几乎完全像基金会用于他们的ver.在 http://foundation.zurb.com/docs/v/4.3.2/index.html的4个文档页面需要能够链接到页面,并且如果在其下面分组的子页面也会扩展.这样做有什么好的Bootstrap示例吗? 解决方法
寻找一些干净简单的示例来设置响应式左侧导航,几乎完全像基金会用于他们的ver.在 http://foundation.zurb.com/docs/v/4.3.2/index.html的4个文档页面需要能够链接到页面,并且如果在其下面分组的子页面也会扩展.这样做有什么好的Bootstrap示例吗?

解决方法

看看这个例子.这是一个带有可折叠子菜单的左侧画布菜单..

http://www.bootply.com/129625

/* collapsed sidebar styles */
@media screen and (max-width: 767px) {
  .row-offcanvas {
    position: relative;
    -webkit-transition: all 0.25s ease-out;
    -moz-transition: all 0.25s ease-out;
    transition: all 0.25s ease-out;
  }
  .row-offcanvas-right
  .sidebar-offcanvas {
    right: -41.6%;
  }

  .row-offcanvas-left
  .sidebar-offcanvas {
    left: -41.6%;
  }
  .row-offcanvas-right.active {
    right: 41.6%;
  }
  .row-offcanvas-left.active {
    left: 41.6%;
  }
  .sidebar-offcanvas {
    position: absolute;
    top: 0;
    width: 41.6%;
  }
  #sidebar {
    background-color:#3b3b3b;
    padding-top:0;
  }
  #sidebar .nav>li {
    color: #ddd;
    background: linear-gradient(#3E3E3E,#383838);
    border-top: 1px solid #484848;
    border-bottom: 1px solid #2E2E2E;
  }
  #sidebar .nav>li:first-child {
    border-top:0;
  }
  #sidebar .nav>li>a {
    color: #ddd;
  }
  #sidebar .nav>li>a>img {
    max-width: 14px;
  }
  #sidebar .nav>li>a:hover,#sidebar .nav>li>a:focus {
    text-decoration: none;
    background: linear-gradient(#373737,#323232);
    color: #fff;  
  }
  #sidebar .nav .caret {
    border-top-color: #fff;
    border-bottom-color: #fff;
  }
  #sidebar .nav a:hover .caret{
    border-top-color: #fff;
    border-bottom-color: #fff;
  }
}

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读