-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathindex.html
56 lines (56 loc) · 2.2 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
---
layout: index
title: Light Open Source Project
---
<div class="col-xs-12 col-sm-9">
{% for post in paginator.posts %}
{% include single.html %}
{% endfor %}
<div class="align-center">
<ul class="pagination">
{% if paginator.previous_page %}
<li><a href="{{ paginator.previous_page_path }}">«</a></li>
{% else %}
<li class="disabled"><a>«</a></li>
{% endif %}
{% if paginator.page <= 2 %}
{% if paginator.page == 1 %}
<li class="active"><a href="{{ site.baseurl }}">1</a></li>
{% else %}
<li><a href="{{ site.baseurl }}">1</a></li>
{% endif %}
{% if paginator.total_pages > 2 %}
{% for count in (2..3) %}
{% if count == paginator.page %}
<li class="active"><a href="{{ site.baseurl }}page{{ count }}">{{ count }}</a></li>
{% else %}
<li><a href="{{ site.baseurl }}page{{ count }}">{{ count }}</a></li>
{% endif %}
{% endfor %}
{% else %}
{% for count in (2..paginator.total_pages) %}
{% if count == paginator.page %}
<li class="active"><a href="{{ site.baseurl }}page{{ count }}">{{ count }}</a></li>
{% else %}
<li><a href="{{ site.baseurl }}page{{ count }}">{{ count }}</a></li>
{% endif %}
{% endfor %}
{% endif %}
{% else %}
{% for count in (paginator.previous_page..paginator.total_pages) limit:3 %}
{% if count == paginator.page %}
<li class="active"><a href="{{ site.baseurl }}page{{ count }}">{{ count }}</a></li>
{% else %}
<li><a href="{{ site.baseurl }}page{{ count }}">{{ count }}</a></li>
{% endif %}
{% endfor %}
{% endif %}
{% if paginator.next_page %}
<li><a href="#">»</a></li>
{% else %}
<li class="disabled"><a>»</a></li>
{% endif %}
</ul><!--/.pagination-->
</div><!--/.align-center-->
</div>
{% include sidebar.html %}