|
|
|
@ -1,86 +1,90 @@ |
|
|
|
|
<% var sections = page.body ? page.body : theme.body; %> |
|
|
|
|
<% sections.forEach(function(sectionName){ %> |
|
|
|
|
<% if (sectionName == 'article') { %> |
|
|
|
|
<article id="<%= post.layout %>" class="post white-box article-type-<%= post.layout %>" itemscope itemprop="blogPost"> |
|
|
|
|
<%- partial('meta', {post: post, position: 'header'}) %> |
|
|
|
|
<section class="article typo"> |
|
|
|
|
<div class="article-entry" itemprop="articleBody"> |
|
|
|
|
<%- post.content %> |
|
|
|
|
</div> |
|
|
|
|
<% if(post.layout == 'post'){ %> |
|
|
|
|
<br> |
|
|
|
|
<%- partial('meta', {post: post, position: 'footer'}) %> |
|
|
|
|
<% } %> |
|
|
|
|
<% if(post.prev || post.next){ %> |
|
|
|
|
<div class="prev-next"> |
|
|
|
|
<% if(post.prev){ %> |
|
|
|
|
<section class="prev"> |
|
|
|
|
<span class="art-item-left"> |
|
|
|
|
<h6><i class="fas fa-chevron-left" aria-hidden="true"></i> <%- __('post.prev_page') %></h6> |
|
|
|
|
<h4> |
|
|
|
|
<a href="<%=url_for(post.prev.path)%>" rel="prev" title="<%=post.prev.title%>"> |
|
|
|
|
<% if(post.prev.title){ %> |
|
|
|
|
<%= post.prev.title %> |
|
|
|
|
<% } else if (post.prev.date) { %> |
|
|
|
|
<%= date(post.prev.date, config.date_format) %> |
|
|
|
|
<% } %> |
|
|
|
|
</a> |
|
|
|
|
</h4> |
|
|
|
|
<% if (post.prev.tags && post.prev.tags.length && post.prev.tags.each) { %> |
|
|
|
|
<% |
|
|
|
|
var items = []; |
|
|
|
|
post.prev.tags.each(function(item){ |
|
|
|
|
items.push('<a class="tag" href="'+url_for(item.path)+'"><i class="fas fa-tag fa-fw" aria-hidden="true"></i> ' + item.name + '</a>'); |
|
|
|
|
}); |
|
|
|
|
%> |
|
|
|
|
<h6 class="tags"> |
|
|
|
|
<%- items.join(' ') %> |
|
|
|
|
</h6> |
|
|
|
|
<% } %> |
|
|
|
|
</span> |
|
|
|
|
</section> |
|
|
|
|
<% } %> |
|
|
|
|
<% if(post.next){ %> |
|
|
|
|
<section class="next"> |
|
|
|
|
<span class="art-item-right" aria-hidden="true"> |
|
|
|
|
<h6><%- __('post.next_page') %> <i class="fas fa-chevron-right" aria-hidden="true"></i></h6> |
|
|
|
|
<h4> |
|
|
|
|
<a href="<%=url_for(post.next.path)%>" rel="prev" title="<%=post.next.title%>"> |
|
|
|
|
<% if(post.next.title){ %> |
|
|
|
|
<%= post.next.title %> |
|
|
|
|
<% } else if (post.next.date) { %> |
|
|
|
|
<%= date(post.next.date, config.date_format) %> |
|
|
|
|
<% } %> |
|
|
|
|
</a> |
|
|
|
|
</h4> |
|
|
|
|
<% if (post.next.tags && post.next.tags.length && post.next.tags.each) { %> |
|
|
|
|
<% |
|
|
|
|
var items = []; |
|
|
|
|
post.next.tags.each(function(item){ |
|
|
|
|
items.push('<a class="tag" href="'+url_for(item.path)+'"><i class="fas fa-tag fa-fw" aria-hidden="true"></i> ' + item.name + '</a>'); |
|
|
|
|
}); |
|
|
|
|
%> |
|
|
|
|
<h6 class="tags"> |
|
|
|
|
<%- items.join(' ') %> |
|
|
|
|
</h6> |
|
|
|
|
<% } %> |
|
|
|
|
</span> |
|
|
|
|
</section> |
|
|
|
|
<%} %> |
|
|
|
|
</div> |
|
|
|
|
<%} %> |
|
|
|
|
</section> |
|
|
|
|
</article> |
|
|
|
|
<% } else if (sectionName == 'comments') { %> |
|
|
|
|
<%- partial('../_third-party/' + sectionName) %> |
|
|
|
|
<% } else { %> |
|
|
|
|
<% theme.sidebar.forEach(function(item){ %> |
|
|
|
|
<% if (item.widget == sectionName) { %> |
|
|
|
|
<%- partial('../_widget/' + item.widget, {item: item}) %> |
|
|
|
|
<% var sections = page.body ? page.body : theme.layout.article.body; %> |
|
|
|
|
<% if (sections.indexOf('article') > -1) { %> |
|
|
|
|
<article id="<%= post.layout %>" class="post white-box article-type-<%= post.layout %>" itemscope itemprop="blogPost"> |
|
|
|
|
<%- partial('meta', {post: post, position: 'header'}) %> |
|
|
|
|
<section class="article typo"> |
|
|
|
|
<div class="article-entry" itemprop="articleBody"> |
|
|
|
|
<%- post.content %> |
|
|
|
|
</div> |
|
|
|
|
<% if(post.layout == 'post'){ %> |
|
|
|
|
<br> |
|
|
|
|
<%- partial('meta', {post: post, position: 'footer'}) %> |
|
|
|
|
<% } %> |
|
|
|
|
<% }) %> |
|
|
|
|
<% } %> |
|
|
|
|
<% }) %> |
|
|
|
|
<% if(post.prev || post.next){ %> |
|
|
|
|
<div class="prev-next"> |
|
|
|
|
<% if(post.prev){ %> |
|
|
|
|
<section class="prev"> |
|
|
|
|
<span class="art-item-left"> |
|
|
|
|
<h6><i class="fas fa-chevron-left" aria-hidden="true"></i> <%- __('post.prev_page') %></h6> |
|
|
|
|
<h4> |
|
|
|
|
<a href="<%=url_for(post.prev.path)%>" rel="prev" title="<%=post.prev.title%>"> |
|
|
|
|
<% if(post.prev.title){ %> |
|
|
|
|
<%= post.prev.title %> |
|
|
|
|
<% } else if (post.prev.date) { %> |
|
|
|
|
<%= date(post.prev.date, config.date_format) %> |
|
|
|
|
<% } %> |
|
|
|
|
</a> |
|
|
|
|
</h4> |
|
|
|
|
<% if (post.prev.tags && post.prev.tags.length && post.prev.tags.each) { %> |
|
|
|
|
<% |
|
|
|
|
var items = []; |
|
|
|
|
post.prev.tags.each(function(item){ |
|
|
|
|
items.push('<a class="tag" href="'+url_for(item.path)+'"><i class="fas fa-tag fa-fw" aria-hidden="true"></i> ' + item.name + '</a>'); |
|
|
|
|
}); |
|
|
|
|
%> |
|
|
|
|
<h6 class="tags"> |
|
|
|
|
<%- items.join(' ') %> |
|
|
|
|
</h6> |
|
|
|
|
<% } %> |
|
|
|
|
</span> |
|
|
|
|
</section> |
|
|
|
|
<% } %> |
|
|
|
|
<% if(post.next){ %> |
|
|
|
|
<section class="next"> |
|
|
|
|
<span class="art-item-right" aria-hidden="true"> |
|
|
|
|
<h6><%- __('post.next_page') %> <i class="fas fa-chevron-right" aria-hidden="true"></i></h6> |
|
|
|
|
<h4> |
|
|
|
|
<a href="<%=url_for(post.next.path)%>" rel="prev" title="<%=post.next.title%>"> |
|
|
|
|
<% if(post.next.title){ %> |
|
|
|
|
<%= post.next.title %> |
|
|
|
|
<% } else if (post.next.date) { %> |
|
|
|
|
<%= date(post.next.date, config.date_format) %> |
|
|
|
|
<% } %> |
|
|
|
|
</a> |
|
|
|
|
</h4> |
|
|
|
|
<% if (post.next.tags && post.next.tags.length && post.next.tags.each) { %> |
|
|
|
|
<% |
|
|
|
|
var items = []; |
|
|
|
|
post.next.tags.each(function(item){ |
|
|
|
|
items.push('<a class="tag" href="'+url_for(item.path)+'"><i class="fas fa-tag fa-fw" aria-hidden="true"></i> ' + item.name + '</a>'); |
|
|
|
|
}); |
|
|
|
|
%> |
|
|
|
|
<h6 class="tags"> |
|
|
|
|
<%- items.join(' ') %> |
|
|
|
|
</h6> |
|
|
|
|
<% } %> |
|
|
|
|
</span> |
|
|
|
|
</section> |
|
|
|
|
<%} %> |
|
|
|
|
</div> |
|
|
|
|
<%} %> |
|
|
|
|
</section> |
|
|
|
|
</article> |
|
|
|
|
<% } %> |
|
|
|
|
<% if (sections.indexOf('category') > -1 || sections.indexOf('tagcloud') > -1 || sections.indexOf('related_posts') > -1) { %> |
|
|
|
|
<% sections.forEach(function(sectionName){ %> |
|
|
|
|
<% if (['category', 'tagcloud', 'related_posts'].indexOf(sectionName) > -1) { %> |
|
|
|
|
<% theme.sidebar.forEach(function(item){ %> |
|
|
|
|
<% if (item.widget == sectionName) { %> |
|
|
|
|
<%- partial('../_widget/' + item.widget, {item: item}) %> |
|
|
|
|
<% } %> |
|
|
|
|
<% }) %> |
|
|
|
|
<% } %> |
|
|
|
|
<% }) %> |
|
|
|
|
<% } %> |
|
|
|
|
<% if (sections.indexOf('comments') > -1) { %> |
|
|
|
|
<%- partial('../_third-party/comments') %> |
|
|
|
|
<% } %> |
|
|
|
|
|
|
|
|
|
<% |
|
|
|
|
if (sections.indexOf('comments') < 0) { |
|
|
|
|