-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
100 lines (93 loc) · 3.98 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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
---
layout: default
title: 'JWorks Tech Blog'
subtitle: 'Powered by <img src="/img/ordina-logo-orange-300px.png" class="header-logo">'
show_logo: true
transparent_header: true
---
<section id="one" class="wrapper spotlight style1">
<div class="inner">
<div class="content" style="text-align: left">
<h2 class="major">Most recent posts</h2>
<section class="features">
{% for post in paginator.posts %}
<article onclick="openPage(event, '{{ post.url}}')">
<a href="{{post.url}}">
<img src="{{post.image}}" alt="" class="article-image">
<h3 class="major">{{post.title}}</h3>
</a>
<p>{{ post.date | date_to_string }} {{post.heading}}</p>
<a href="{{post.url}}" class="special">Read more</a>
</article>
{% endfor %}
</section>
<!-- Pagination -->
{% if paginator.total_pages > 1 %}
<ul class="actions"> <!-- pagination center-block -->
{% if paginator.previous_page %}
<li>
<a href="{{ paginator.previous_page_path | prepend: site.baseurl | replace: '//', '/' }}"
aria-label="Previous">
<span aria-hidden="true">«</span>
</a>
</li>
{% endif %}
{% for page in (1..paginator.total_pages) %}
{% if page == 1 %}
{% capture url %}
{{ site.paginate_path | prepend: site.baseurl | replace: '//', '/' | replace: 'page:num', '' }}
{% endcapture %}
{% else %}
{% capture url %}
{{ site.paginate_path | prepend: site.baseurl | replace: '//', '/' | replace: ':num', page }}
{% endcapture %}
{% endif %}
<li><a href="{{ url }}" {% if page== paginator.page %}class="disabled" {% endif %}>{{ page }}</a></li>
{% endfor %}
{% if paginator.next_page %}
<li>
<a href="{{ paginator.next_page_path | prepend: site.baseurl | replace: '//', '/' }}"
aria-label="Next">
<span aria-hidden="true">»</span>
</a>
</li>
{% endif %}
</ul>
{% endif %}
<!-- End Pagination -->
</div>
</div>
</section>
<section id="two" class="wrapper alt spotlight style2">
<div class="inner">
<div class="content">
<h2 class="major">Categories</h2>
<div class="category-list right">
{% assign shown_categories = '' %}
{% for cat in site.categories %} {% assign cat_ = cat[0] | downcase | replace:' ','-' %}
{% assign shown_cats_array = shown_categories | split: ', ' %}
{% unless shown_cats_array contains cat_ %}
<a href="/categories/{{cat_ }}"><i class="fa fa-folder-o fa-fw"></i>{{cat[0]}}</a>
{% assign shown_categories = shown_categories | append: ', ' | append: cat_ %}
{% endunless %}
{% endfor %}
</div>
</div>
</div>
</section>
<section id="three" class="wrapper spotlight style3">
<div class="inner">
<div class="content">
<h2 class="major">Tags</h2>
<div class="category-list left">
{% assign tags = site.tags | sort %}
{% for tag in tags %}
<a href="/tags/{{ tag | first | slugify }}/" style="font-size: {{ tag | last | size | times: 4 | plus: 80 }}%">
<i class="fa fa-tag fa-fw"></i>{{ tag[0] | replace:'-', ' ' }} ({{ tag | last | size }})
</a>
</span>
{% endfor %}
</div>
</div>
</div>
</section>