样式优化
This commit is contained in:
@@ -1,16 +1,14 @@
|
||||
<% if (pagination == 2){ %>
|
||||
<% page.posts.each(function(post){ %>
|
||||
<% if (pagination == 2){
|
||||
page.posts.each(function(post){ %>
|
||||
<%- partial('article', {post: post, index: true}) %>
|
||||
<% }) %>
|
||||
<% } else { %>
|
||||
<% var last; %>
|
||||
<% page.posts.each(function(post, i){ %>
|
||||
<% var year = post.date.year(); %>
|
||||
<% if (last != year){ %>
|
||||
<% if (last != null){ %>
|
||||
</div></section>
|
||||
<% } %>
|
||||
<% last = year; %>
|
||||
<% })
|
||||
} else {
|
||||
var last;
|
||||
page.posts.each(function(post, i){
|
||||
var year = post.date.year();
|
||||
if (last != year){
|
||||
if (last != null){ %></div></section><% }
|
||||
last = year; %>
|
||||
<section class="archives-wrap">
|
||||
<div class="archive-year-wrap">
|
||||
<a href="<%- url_for('archives/' + year) %>" class="archive-year"><%= year %></a>
|
||||
@@ -18,12 +16,9 @@
|
||||
<div class="archives">
|
||||
<% } %>
|
||||
<%- partial('archive-post', {post: post, even: i % 2 == 0}) %>
|
||||
<% }) %>
|
||||
<% if (page.posts.length){ %>
|
||||
</div></section>
|
||||
<% } %>
|
||||
<% } %>
|
||||
<% if (page.total > 1){ %>
|
||||
<% })
|
||||
if (page.posts.length){ %></div></section><% }}
|
||||
if (page.total > 1){ %>
|
||||
<nav id="page-nav">
|
||||
<%- paginator({
|
||||
prev_text: '« '+__('prev'),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<article id="<%= post.layout %>-<%= post.slug %>" class="article article-type-<%= post.layout %> <%if(index){%> article-index<%}%>" itemscope itemprop="blogPost">
|
||||
<article class="article article-type-<%= post.layout %> <%if(index){%> article-index<%}%>" itemscope itemprop="blogPost">
|
||||
<div class="article-inner">
|
||||
<% if (post.link || post.title){ %>
|
||||
<header class="article-header">
|
||||
|
||||
@@ -20,11 +20,11 @@
|
||||
</ul>
|
||||
</nav>
|
||||
<nav class="header-smart-menu">
|
||||
<% for (let menuName in theme.smart_menu){
|
||||
if(theme.smart_menu[menuName]){ %>
|
||||
<a @click="openSlider($event, '<%-menuName%>')" href="javascript:void(0)"><%= __(theme.smart_menu[menuName]) %></a>
|
||||
<% }
|
||||
} %>
|
||||
<% for (let menuName in theme.smart_menu){
|
||||
if(theme.smart_menu[menuName]){ %>
|
||||
<a @click="openSlider($event, '<%-menuName%>')" href="javascript:void(0)"><%= __(theme.smart_menu[menuName]) %></a>
|
||||
<% }
|
||||
} %>
|
||||
</nav>
|
||||
<nav class="header-nav">
|
||||
<div class="social">
|
||||
|
||||
@@ -12,12 +12,12 @@
|
||||
}
|
||||
%>
|
||||
<ul style="width:70%">
|
||||
<% var divide = 100 / count + '%' %>
|
||||
<% for (let menu_name in theme.smart_menu){ %>
|
||||
<% if(theme.smart_menu[menu_name]){ %>
|
||||
<% var divide = 100 / count + '%'
|
||||
for (let menu_name in theme.smart_menu){
|
||||
if(theme.smart_menu[menu_name]){ %>
|
||||
<li style="width: <%= divide %>" @click="openSlider($event, '<%-menu_name%>')"><a href="javascript:void(0)" :class="{active:<%-menu_name%>}"><%= __(theme.smart_menu[menu_name]) %></a></li>
|
||||
<% } %>
|
||||
<% } %>
|
||||
<% }
|
||||
} %>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="tools-wrap">
|
||||
@@ -103,7 +103,6 @@
|
||||
</ul>
|
||||
</section>
|
||||
<%}%>
|
||||
|
||||
<%if(hasFriends){%>
|
||||
<section class="tools-section tools-section-friends" v-show="friends">
|
||||
<%if(theme.friends && theme.friends.length != 0){%>
|
||||
@@ -117,12 +116,11 @@
|
||||
<%}%>
|
||||
</section>
|
||||
<%}%>
|
||||
|
||||
<%if(hasAboutme){%>
|
||||
<section class="tools-section tools-section-me" v-show="aboutme">
|
||||
<%if(theme.aboutme){%>
|
||||
<div class="aboutme-wrap" id="js-aboutme"><%-theme.aboutme%></div>
|
||||
<%}%>
|
||||
<%if(theme.aboutme){%>
|
||||
<div class="aboutme-wrap" id="js-aboutme"><%-theme.aboutme%></div>
|
||||
<%}%>
|
||||
</section>
|
||||
<%}%>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user