tarasis.net/src/index.html

49 lines
1.7 KiB
HTML

---
layout: archive
permalink: "{% if pagination.pageNumber>0 %}page-{{ pagination.pageNumber | plus: 1 }}{% endif %}/index.html"
pagination:
data: collections.posts
size: 7
---
{%- for post in pagination.items -%}
<h2><a href="{% post_url collections.posts, post.fileSlug %}">{{ post.data.title }}</a></h2>
<em>{{ post.data.date | toUTCString}}</em>
<p>{{ post.templateContent | description }} <a href="{% post_url collections.posts, post.fileSlug %}"><em>read more</em></a></p>
{%- endfor -%}
<ul class="pagination">
<li>
{% if pagination.href.first and pagination.href.previous %}
<a href="{{ pagination.href.first }}" class="pagination">First</a>
{% else %}
<a href="#" class="pagination disabled">{{ "First" }}</a>
{% endif %}
<li>
{% if pagination.href.previous %}
<a href="{{ pagination.href.previous }}" class="pagination">Previous</a>
{% else %}
<a href="#" class="pagination disabled">{{ ui-text[site.locale].pagination_previous | default: "Previous" }}</a>
{% endif %}
</li>
<li>
<a href="#" class="pagination current">Page {{ pagination.pageNumber | plus: 1 }}</a>
</li>
<li>{% if pagination.href.next %}
<a href="{{ pagination.href.next }}" class="pagination">Next</a>
{% else %}
<a href="#" class="pagination disabled">{{ ui-text[site.locale].pagination_next | default: "Next" }}</a>
{% endif %}
</li>
<li>
{% if pagination.href.first and pagination.href.next %}
<a href="{{ pagination.href.last }}" class="pagination">Last</a>
{% else %}
<a href="#" class="pagination disabled">{{ "Last" }}</a>
{% endif %}
</li>
</ul>