Skip to content

Commit

Permalink
refactor(h5test): add group navigation (#99)
Browse files Browse the repository at this point in the history
* chore(master): inspect startup move to master

* docs(changelog.md): remove changelog.md

* chore(master): add admin.start() in master

* refactor(master): master.js Readability optimization

* refactor(h5test): add group navigation

测试环境支持分组导航
  • Loading branch information
RobinzZH authored and huangyoukun committed Jun 5, 2018
1 parent e0bde17 commit dd31d7f
Show file tree
Hide file tree
Showing 5 changed files with 286 additions and 241 deletions.
43 changes: 31 additions & 12 deletions bin/tsw/util/h5-test/page/src/main.tmpl.html
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
<script id="new_main" type="text/html" nowith="yes" >
<%
data = data || {};
data = data || {};

var body = data.body || '',
head = data.head || {};
var body = data.body || '',
head = data.head || {};
%>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<title><%=tmpl.encodeHtml(head.title || '')%></title>
<meta name="description" itemprop="description" content="<%=tmpl.encodeHtml(head.description || '')%>" />
<meta itemprop="name" content="<%=tmpl.encodeHtml(head.share_name || '')%>">
<title><%-head.title || ''%></title>
<meta name="description" itemprop="description" content="<%-head.description || ''%>" />
<meta itemprop="name" content="<%-head.share_name || ''%>">
<% if(head.share_image){%>
<meta itemprop="image" content="<%= head.share_image %>">
<meta itemprop="image" content="<%- head.share_image %>">
<%}%>
<meta name="robots" content="none" />
<meta name="format-detection" content="telephone=no" />
Expand Down Expand Up @@ -100,15 +100,34 @@
z-index: 999;
width: 100%;
}

.group-menu .group-item {
padding: 2px;
cursor: pointer;
border: 1px solid #ccc;
}
.top-tip{
width: 100%;
height: 100px;
position: fixed;
background-color: rgba(33, 186, 69, 0.75);
z-index: 999;
top: 0;
display: flex;
justify-content: center;
align-items: center;
color: #fff;
font-size: 30px;
}
</style>
<div id="header" class="header">
<ul class="nav">
<%
var navMenus = data;
<%
var navMenus = data,i;
if(navMenus && navMenus.length>0) {
for(var i=0;i<navMenus.length;i++){
for(i=0;i<navMenus.length;i++){
if(navMenus[i].href && navMenus[i].title){ %>
<li><a href="<%=tmpl.encodeHtml(navMenus[i].href)%>"><%=tmpl.encodeHtml(navMenus[i].title)%></a></li>
<li><a href="<%-navMenus[i].href%>"><%-navMenus[i].title%></a></li>
<%}
}
}
Expand All @@ -118,4 +137,4 @@
<% if(context.noticeMessage) { %>
<div class="tooltips"><%=context.noticeMessage%></div>
<% } %>
</script>
</script>
Loading

0 comments on commit dd31d7f

Please sign in to comment.