mirror of
https://github.com/interstellar750/hexo_s
synced 2024-10-19 00:23:51 +08:00
96 lines
3.7 KiB
Plaintext
96 lines
3.7 KiB
Plaintext
|
<div class="container">
|
||
|
<%# toc %>
|
||
|
<%if(theme.post_toc_enable && toc(page.content).length!==0){%>
|
||
|
<%- partial('_partial/toc') %>
|
||
|
<%}%>
|
||
|
|
||
|
<%# article %>
|
||
|
<article class="post-wrap">
|
||
|
<header class="post-header">
|
||
|
<h1 class="post-title"><%= page.title %></h1>
|
||
|
<% if(theme.post_meta_enable){ %>
|
||
|
<div class="post-meta">
|
||
|
<% if(theme.post_author_enable && config.author){ %>
|
||
|
作者: <a itemprop="author" rel="author" href="/"><%- config.author %></a>
|
||
|
<% } %>
|
||
|
|
||
|
<% if(page.date && theme.post_date_enable){ %>
|
||
|
<span class="post-time">
|
||
|
日期: <a href="#"><%- date(page.date, theme.date_format) %> <%- time(page.date, theme.time_format)%></a>
|
||
|
</span>
|
||
|
<% } %>
|
||
|
<% if(page.categories.length!==0 && theme.post_category_enable){ %>
|
||
|
<span class="post-category">
|
||
|
Category:
|
||
|
<% page.categories.forEach(item=>{ %>
|
||
|
<a href="<%- url_for(item.path) %>"><%- item.name %></a>
|
||
|
<% }) %>
|
||
|
</span>
|
||
|
<% } %>
|
||
|
</div>
|
||
|
<% } %>
|
||
|
</header>
|
||
|
|
||
|
<div class="post-content">
|
||
|
<%- page.content %>
|
||
|
</div>
|
||
|
|
||
|
<% if(theme.post_copyright_enable){ %>
|
||
|
<section class="post-copyright">
|
||
|
<% if(theme.post_copyright_author_enable){ %>
|
||
|
<p class="copyright-item">
|
||
|
<span>作者:</span>
|
||
|
<span><%- config.author %></span>
|
||
|
</p>
|
||
|
<% } %>
|
||
|
<% if(theme.post_copyright_permalink_enable){ %>
|
||
|
<p class="copyright-item">
|
||
|
<span>本文链接:</span>
|
||
|
<span><a href="<%- page.permalink %>"><%- page.permalink %></a></span>
|
||
|
</p>
|
||
|
<% } %>
|
||
|
<% if(theme.post_copyright_license_enable){ %>
|
||
|
<p class="copyright-item">
|
||
|
<span>许可证:</span>
|
||
|
<span><%- theme.post_copyright_license_text %></span>
|
||
|
</p>
|
||
|
<% } %>
|
||
|
<% if(theme.post_copyright_slogan_enable){ %>
|
||
|
<p class="copyright-item">
|
||
|
<span>Slogan:</span>
|
||
|
<span><%- theme.post_copyright_slogan_text %></span>
|
||
|
</p>
|
||
|
<% } %>
|
||
|
|
||
|
</section>
|
||
|
<% } %>
|
||
|
<section class="post-tags">
|
||
|
<div>
|
||
|
<span>标签:</span>
|
||
|
<span class="tag">
|
||
|
<% if(page.tags.length!==0){%>
|
||
|
<% page.tags.forEach(item=>{ %>
|
||
|
<a href="<%- url_for(item.path) %>"># <%- item.name %></a>
|
||
|
<% }) %>
|
||
|
<% } %>
|
||
|
</span>
|
||
|
</div>
|
||
|
<div>
|
||
|
<a href="javascript:window.history.back();">返回</a>
|
||
|
<span>· </span>
|
||
|
<a href="<%- config.root %>">主页</a>
|
||
|
</div>
|
||
|
</section>
|
||
|
<section class="post-nav">
|
||
|
<% if(post.prev){ %>
|
||
|
<a class="prev" rel="prev" href="<%- url_for(post.prev.path)%>"><%- post.prev.title%></a>
|
||
|
<% } %>
|
||
|
<% if(post.next){ %>
|
||
|
<a class="next" rel="next" href="<%- url_for(post.next.path)%>"><%- post.next.title%></a>
|
||
|
<% } %>
|
||
|
</section>
|
||
|
|
||
|
|
||
|
</article>
|
||
|
</div>
|