-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.html
79 lines (70 loc) · 2.63 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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
---
layout: default
title: Home
---
<div class="container">
<div class="row-fluid main">
<div class="col-md-9 content main-posts-preview">
{% for post in paginator.posts %}
<article class="post-preview">
<h1 class="post-title">
<a href="{{ site.baseurl }}{{ post.url }}">{{ post.title }}</a>
</h1>
<div class="post-info">
<span class="post-date">{{ post.date | date_to_string }}</span>
{% if post.categories.size > 0 %} |
<span class="fa fa-folder-open" aria-hidden="true">
{% for category in post.categories %}
<a class="post-categories" href="{{ site.baseurl }}/categories.html#{{ category }}">{{ category }}</a>
{% endfor %}
</span>
{% endif %}
{% if post.tags.size > 0 %} |
<span class="fa fa-tag" aria-hidden="true">
{% for tag in post.tags %}
<a class="post-tags" href="{{ site.baseurl }}/tags.html#{{ tag }}">{{ tag }}</a>
{% endfor %}
</span>
{% endif %}
</div>
<div class="post-excerpt">
{{ post.excerpt }}
</div>
<div class="post-readmore">
<a class="read-more" href="{{ post.url }}">Read More</a>
</div>
</article>
<hr />
{% endfor %}
{% if paginator.total_pages >= 1 %}
<nav aria-label="Page navigation">
<ul class="pagination">
{% if paginator.previous_page %}
<li><a href="{{ paginator.previous_page_path | prepend: site.baseurl | replace: '//', '/' }}">«</a></li>
{% else %}
<li><span>«</span></li>
{% endif %}
{% for page in (1..paginator.total_pages) %}
{% if page == paginator.page %}
<li class="active"><a>{{ page }}</a></li>
{% elsif page == 1 %}
<li><a href="{{ paginator.previous_page_path | prepend: site.baseurl | replace: '//', '/' }}">{{ page }}</a>
</li>
{% else %}
<li><a href="{{ site.paginate_path | prepend: site.baseurl | replace: '//', '/' | replace: ':num', page }}">{{ page }}</a></li>
{% endif %}
{% endfor %}
{% if paginator.next_page %}
<li><a href="{{ paginator.next_page_path | prepend: site.baseurl | replace: '//', '/' }}">»</a></li>
{% else %}
<li><span>»</span></li>
{% endif %}
</ul>
</nav>
{% endif %}
</div>
<div class="col-md-3 main-sidebar">
{% include {{ site.baseurl }}sidebar_main.html %}
</div>
</div>
</div>