-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
61 lines (47 loc) · 1.88 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
57
58
59
60
61
---
layout: default
---
{% for post in paginator.posts %}
<!-- display the date if this post is a different date than the next, or
if we are on a new page in the pagination -->
{% capture curr_date %}{{ post.date | date: "%b %-d, %Y" }}{% endcapture %}
{% capture next_date %}{{ post.next.date | date: "%b %-d, %Y" }}{% endcapture %}
{% if curr_date != next_date or curr_page != paginator.page %}
<h3><i class="fa fa-calendar-o" aria-hidden="true"></i> {{ post.date | date: "%A, %B %-d, %Y" }}</h3>
{% endif %}
{% capture curr_page %}{{ paginator.page }}{% endcapture %}
{% assign curr_page = curr_page | plus: 0 %}
<article class="post">
{% if post.external-url %}
<h1>
<a href="{{ post.external-url }}" onclick="trackOutboundLink('{{ post.external-url }}'); return false;">{{ post.title }}</a> <a class="anchor" href="{{ post.url }}"><i class="fa fa-paper-plane" aria-hidden="true"></i></a>
</h1>
{% else %}
<h1><a href="{{ post.url }}">{{ post.title }}</a></h1>
{% endif %}
<div class="host">
{% if post.scheme == 'https' %} <i class="fa fa-lock" aria-hidden="true"></i> {% endif %}
{{ post.host }}
</div>
<div class="post-content">{{ post.content }}</div>
</article>
{% endfor %}
{% if paginator.total_pages > 1 %}
<div class="postnavigation">
{% if paginator.previous_page %}
{% if paginator.page == 2 %}
<a class="prev left" href="/">← Newer</a>
{% else %}
<a class="prev left" href="/page{{paginator.previous_page}}/">← Newer</a>
{% endif %}
{% else %}
<span class="nope left">← Newer</span>
{% endif %}
<span class="pages">Page {{ paginator.page }} of {{ paginator.total_pages }}</span>
{% if paginator.next_page %}
<a class="next right" href="/page{{paginator.next_page}}/">Older →</a>
{% else %}
<span class="nope right">Older →</span>
{% endif %}
</div>
{% endif %}