hexo-theme-amane/layout/common/article.ejs

45 lines
1.7 KiB
Plaintext
Raw Normal View History

2016-02-02 16:19:44 +00:00
<article id="<%= post.layout %>-<%= post.slug %>" class="article article-type-<%= post.layout %>" itemscope itemprop="blogPost">
<div class="article-inner">
<% if (post.banner) { %>
<%- partial('post/banner') %>
<% } %>
<%- partial('post/gallery') %>
<% if (post.link || post.title) { %>
<header class="article-header">
2016-02-05 16:11:56 +00:00
<%- partial('post/title', { class_name: 'article-title' }) %>
2016-02-02 16:19:44 +00:00
<div class="article-meta">
2016-02-05 16:11:56 +00:00
<%- partial('post/date', { class_name: 'article-date', date_format: null }) %>
2016-02-02 16:19:44 +00:00
<%- partial('post/category') %>
<%- partial('post/tag') %>
</div>
</header>
<% } %>
<div class="article-entry" itemprop="articleBody">
<% if (index) { %>
2016-02-05 14:05:37 +00:00
<p><%- excerpt(post) %></p>
2016-02-02 16:19:44 +00:00
<p class="article-more-link">
<a href="<%- url_for(post.path) %>#more"><%= __('article.more') %></a>
</p>
<% } else { %>
<% if (!index && post.toc) { %>
<div id="toc" class="toc-article">
<strong class="toc-title"><%= __('article.catalogue') %></strong>
<%- toc(post.content) %>
</div>
<% } %>
<%- post.content %>
<% } %>
</div>
<footer class="article-footer">
<%- partial('share/index', { post: post }) %>
<%- partial('comment/counter', { post: post }) %>
2016-02-02 16:19:44 +00:00
</footer>
</div>
<% if (!index) { %>
<%- partial('post/nav') %>
<% } %>
</article>
<% if (!index) { %>
<%- partial('comment/index') %>
<% } %>