2020-03-27 20:45:27 +08:00
|
|
|
<%
|
|
|
|
const postList = createNewArchivePosts(is_archive() ? site.posts : page.posts)
|
|
|
|
%>
|
2020-03-19 18:11:13 +08:00
|
|
|
<div class="archive-container">
|
2020-03-27 20:45:27 +08:00
|
|
|
<% postList.forEach(postYear => { %>
|
|
|
|
<section class="archive-item">
|
2020-04-01 17:00:26 +08:00
|
|
|
<div class="archive-item-header">
|
|
|
|
<span class="archive-year"><%= postYear.year %></span>
|
|
|
|
</div>
|
2020-03-27 20:45:27 +08:00
|
|
|
<ul class="article-list">
|
|
|
|
<% postYear.postList.forEach(post => { %>
|
|
|
|
<li class="article-item">
|
|
|
|
<a class="article-title"
|
|
|
|
href="<%- url_for(post.path) %>"
|
|
|
|
><%= post.title %></a>
|
|
|
|
<span class="article-date"><%= date(post.date, 'MM-DD') %></span>
|
|
|
|
</li>
|
|
|
|
<% }) %>
|
|
|
|
</ul>
|
|
|
|
</section>
|
|
|
|
<% }) %>
|
2020-04-01 15:28:01 +08:00
|
|
|
</div>
|