mirror of https://gitlab.com/curben/blog
30 lines
693 B
Plaintext
30 lines
693 B
Plaintext
<% let last %>
|
|
<% page.posts.each((post, i) => { %>
|
|
<% const year = post.date.year() %>
|
|
<% if (last !== year) { %>
|
|
<% if (last !== null) { %>
|
|
</div></section>
|
|
<% } %>
|
|
<% last = year %>
|
|
<section class="archives-wrap">
|
|
<div class="archives">
|
|
<% } %>
|
|
<%- partial('archive-post', {post: post}) %>
|
|
<% }) %>
|
|
<% if (page.posts.length) { %>
|
|
</div></section>
|
|
<% } %>
|
|
<% if (page.total > 1) { %>
|
|
<nav id="page-nav" class="page-nav">
|
|
<%
|
|
const prev_text = '« ' + __('prev')
|
|
const next_text = __('next') + ' »'
|
|
%>
|
|
<%- paginator({
|
|
prev_text: prev_text,
|
|
next_text: next_text,
|
|
escape: false
|
|
}) %>
|
|
</nav>
|
|
<% } %>
|