38 lines
1.3 KiB
Plaintext
38 lines
1.3 KiB
Plaintext
<div class="home-container">
|
|
<% if (is_home()) { %>
|
|
<ul class="article-post-list">
|
|
<% page.posts.forEach(post => { %>
|
|
<li class="article-post-item">
|
|
<div class="article-post-title">
|
|
<h3>
|
|
<a class="article-title-hover-animation" href="<%- url_for(post.path) %>"><%= post.title %></a>
|
|
</h3>
|
|
</div>
|
|
|
|
<div class="article-post-content">
|
|
<%- truncate(strip_html(post.content), {length: 150}) %>
|
|
</div>
|
|
|
|
<div class="article-post-meta-info">
|
|
<%- partial('common/article-meta-info', {articleObject: post, index: true}) %>
|
|
</div>
|
|
</li>
|
|
<% }) %>
|
|
</ul>
|
|
|
|
<div class="paginator">
|
|
<% if (page.prev) { %>
|
|
<a class="prev btn"
|
|
href="<%- url_for(page.prev == 1 ? '' : '/page/' + page.prev) %>"
|
|
><%- __('prev') %></a>
|
|
<% } %>
|
|
|
|
<% if (page.next) { %>
|
|
<a class="next btn"
|
|
href="<%- url_for('/page/' + page.next) %>"
|
|
><%- __('next') %></a>
|
|
<% } %>
|
|
</div>
|
|
<% } %>
|
|
|
|
</div> |