-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
56 lines (50 loc) · 1.51 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
---
title: Main
layout: page
---
<ul class="listing">
{% for post in paginator.posts %}
{% capture y %}{{post.date | date:"%Y"}}{% endcapture %}
{% if year != y %}
{% assign year = y %}
<li class="listing-seperator">{{ y }}</li>
{% endif %}
<li class="listing-item">
<time datetime="{{ post.date | date:"%Y-%m-%d" }}">{{ post.date | date:"%Y-%m-%d" }}</time>
<a href="{{ post.url }}" title="{{ post.title }}">{{ post.title }}</a>
<p>
{{ post.excerpt | remove: '<p>' | remove: '</p>' }} »
<a href="{{ post.url }}">read more...</a>
</p>
</li>
{% endfor %}
</ul>
<div id="post-pagination" class="paginator">
{% if paginator.previous_page %}
{% if paginator.previous_page == 1 %}
<a href="/">Prev</a>
{% else %}
<a href="/page{{paginator.previous_page}}"><previous</a>
{% endif %}
{% else %}
<span class="previous disabled"><previous</span>
{% endif %}
{% if paginator.page == 1 %}
<span class="current-page">1</span>
{% else %}
<a href="/">1</a>
{% endif %}
{% for count in (2..paginator.total_pages) %}
{% if count == paginator.page %}
<span class="current-page">{{count}}</span>
{% else %}
<a href="/page{{count}}">{{count}}</a>
{% endif %}
{% endfor %}
{% if paginator.next_page %}
<a class="next" href="/page{{paginator.next_page}}">next></a>
{% else %}
<span class="next disabled" >next></span>
{% endif %}
(total_posts {{ paginator.total_posts }})
</div>