123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206 |
- <title>导航</title>
- <div class="layui-card layadmin-header">
- <div class="layui-breadcrumb" lay-filter="breadcrumb">
- <a lay-href="">主页</a>
- <a><cite>组件</cite></a>
- <a><cite>导航</cite></a>
- </div>
- </div>
- <style>
- /* 这段样式只是用于演示 */
- #LAY-component-nav .layui-nav-tree {vertical-align: top;}
- </style>
- <div class="layui-fluid" id="LAY-component-nav">
- <div class="layui-row layui-col-space15">
- <div class="layui-col-md6">
- <div class="layui-card">
- <div class="layui-card-header">水平导航菜单</div>
- <div class="layui-card-body">
- <ul class="layui-nav" lay-filter="component-nav">
- <li class="layui-nav-item"><a href="javascript:;">最新活动</a></li>
- <li class="layui-nav-item layui-this">
- <a href="javascript:;">产品</a>
- <dl class="layui-nav-child">
- <dd><a href="javascript:;">选项1</a></dd>
- <dd><a href="javascript:;">选项2</a></dd>
- <dd><a href="javascript:;">选项3</a></dd>
- </dl>
- </li>
- <li class="layui-nav-item"><a href="javascript:;">大数据</a></li>
- <li class="layui-nav-item">
- <a href="javascript:;">解决方案</a>
- <dl class="layui-nav-child">
- <dd><a href="javascript:;">移动模块</a></dd>
- <dd><a href="javascript:;">后台模版</a></dd>
- <dd class="layui-this"><a href="javascript:;">选中项</a></dd>
- <dd><a href="javascript:;">电商平台</a></dd>
- </dl>
- </li>
- <li class="layui-nav-item"><a href="javascript:;">社区</a></li>
- </ul>
- </div>
- </div>
- <div class="layui-card">
- <div class="layui-card-header">导航带徽章和图片</div>
- <div class="layui-card-body">
- <ul class="layui-nav" lay-filter="component-nav">
- <li class="layui-nav-item">
- <a href="javascript:;">控制台<span class="layui-badge">9</span></a>
- </li>
- <li class="layui-nav-item">
- <a href="javascript:;">个人中心<span class="layui-badge-dot"></span></a>
- </li>
- <li class="layui-nav-item" lay-unselect="">
- <a href="javascript:;"><img src="http://t.cn/RCzsdCq" class="layui-nav-img">我</a>
- <dl class="layui-nav-child">
- <dd><a href="javascript:;">修改信息</a></dd>
- <dd><a href="javascript:;">安全管理</a></dd>
- <dd><a href="javascript:;">退了</a></dd>
- </dl>
- </li>
- </ul>
- </div>
- </div>
- <div class="layui-card">
- <div class="layui-card-header">导航主题</div>
- <div class="layui-card-body">
- <ul class="layui-nav layui-bg-cyan" lay-filter="component-nav">
- <li class="layui-nav-item"><a href="javascript:;">藏青导航</a></li>
- <li class="layui-nav-item layui-this"><a href="javascript:;">产品</a></li>
- <li class="layui-nav-item"><a href="javascript:;">大数据</a></li>
- <li class="layui-nav-item">
- <a href="javascript:;">解决方案</a>
- <dl class="layui-nav-child">
- <dd><a href="javascript:;">移动模块</a></dd>
- <dd><a href="javascript:;">后台模版</a></dd>
- <dd><a href="javascript:;">电商平台</a></dd>
- </dl>
- </li>
- <li class="layui-nav-item"><a href="javascript:;">社区</a></li>
- </ul>
- <br>
- <ul class="layui-nav layui-bg-green" lay-filter="component-nav">
- <li class="layui-nav-item"><a href="javascript:;">墨绿导航</a></li>
- <li class="layui-nav-item layui-this"><a href="javascript:;">产品</a></li>
- <li class="layui-nav-item"><a href="javascript:;">大数据</a></li>
- <li class="layui-nav-item">
- <a href="javascript:;">解决方案</a>
- <dl class="layui-nav-child">
- <dd><a href="javascript:;">移动模块</a></dd>
- <dd><a href="javascript:;">后台模版</a></dd>
- <dd><a href="javascript:;">电商平台</a></dd>
- </dl>
- </li>
- <li class="layui-nav-item"><a href="javascript:;">社区</a></li>
- </ul>
- <br>
- <ul class="layui-nav layui-bg-blue" lay-filter="component-nav">
- <li class="layui-nav-item"><a href="javascript:;">艳蓝导航</a></li>
- <li class="layui-nav-item layui-this"><a href="javascript:;">产品</a></li>
- <li class="layui-nav-item"><a href="javascript:;">大数据</a></li>
- <li class="layui-nav-item">
- <a href="javascript:;">解决方案</a>
- <dl class="layui-nav-child">
- <dd><a href="javascript:;">移动模块</a></dd>
- <dd><a href="javascript:;">后台模版</a></dd>
- <dd><a href="javascript:;">电商平台</a></dd>
- </dl>
- </li>
- <li class="layui-nav-item"><a href="javascript:;">社区</a></li>
- </ul>
- </div>
- </div>
- </div>
-
- <div class="layui-col-md6">
- <div class="layui-card">
- <div class="layui-card-header">垂直导航菜单</div>
- <div class="layui-card-body">
- <ul class="layui-nav layui-nav-tree layui-inline" lay-filter="component-nav-active" style="margin-right: 10px;">
- <li class="layui-nav-item layui-nav-itemed">
- <a href="javascript:;">默认展开</a>
- <dl class="layui-nav-child">
- <dd><a href="javascript:;">选项一</a></dd>
- <dd><a href="javascript:;">选项二</a></dd>
- <dd><a href="javascript:;">选项三</a></dd>
- <dd><a href="javascript:;">跳转项</a></dd>
- </dl>
- </li>
- <li class="layui-nav-item">
- <a href="javascript:;">解决方案</a>
- <dl class="layui-nav-child">
- <dd><a href="javascript:;">移动模块</a></dd>
- <dd><a href="javascript:;">后台模版</a></dd>
- <dd><a href="javascript:;">电商平台</a></dd>
- </dl>
- </li>
- <li class="layui-nav-item"><a href="javascript:;">云市场</a></li>
- <li class="layui-nav-item"><a href="javascript:;">社区</a></li>
- </ul>
- <ul class="layui-nav layui-nav-tree layui-bg-cyan layui-inline" lay-filter="component-nav-active">
- <li class="layui-nav-item layui-nav-itemed">
- <a href="javascript:;">默认展开</a>
- <dl class="layui-nav-child">
- <dd><a href="javascript:;">选项一</a></dd>
- <dd><a href="javascript:;">选项二</a></dd>
- <dd><a href="javascript:;">选项三</a></dd>
- <dd><a href="http://www.layui.com/admin/" target="_blank">跳转项</a></dd>
- </dl>
- </li>
- <li class="layui-nav-item">
- <a href="javascript:;">解决方案</a>
- <dl class="layui-nav-child">
- <dd><a href="javascript:;">移动模块</a></dd>
- <dd><a href="javascript:;">后台模版</a></dd>
- <dd><a href="javascript:;">电商平台</a></dd>
- </dl>
- </li>
- <li class="layui-nav-item"><a href="javascript:;">云市场</a></li>
- <li class="layui-nav-item"><a href="javascript:;">社区</a></li>
- </ul>
- </div>
- </div>
- <div class="layui-card">
- <div class="layui-card-header">面包屑</div>
- <div class="layui-card-body">
- <span class="layui-breadcrumb" lay-filter="breadcrumb">
- <a href="javascript:;">首页</a>
- <a href="javascript:;">演示</a>
- <a><cite>导航元素</cite></a>
- </span>
- <br>
- <span class="layui-breadcrumb" lay-separator="-" lay-filter="breadcrumb">
- <a href="javascript:;">首页</a>
- <a href="javascript:;">演示</a>
- <a><cite>导航元素</cite></a>
- </span>
- <br>
- <span class="layui-breadcrumb" lay-separator="\" lay-filter="breadcrumb">
- <a href="javascript:;">首页</a>
- <a href="javascript:;">演示</a>
- <a><cite>导航元素</cite></a>
- </span>
- </div>
- </div>
- </div>
- </div>
- </div>
- <script>
- layui.use(['admin'], function(){
- var $ = layui.$
- ,admin = layui.admin
- ,element = layui.element;
- element.render('nav', 'component-nav');
- element.render('nav', 'component-nav-active');
-
- element.on('nav(component-nav-active)', function(elem){
- layer.msg(elem.text());
- });
- });
- </script>
|