forked from siawyoung/immaculate
/
index.html
70 lines (58 loc) · 2.06 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
---
layout: default
---
<main>
<article class="post homepage-title">
<h1 class="site-title">{{ site.title }}.</h1>
<h3 class="sitetitle-sub">Featured reviews</h3>
</article>
{% assign featured_posts = site.posts | where: "featured", true %}
<div class="homepage-post-container">
{% for post in featured_posts %}
<article class="homepage-posts" itemscope itemtype="http://schema.org/BlogPosting" role="article">
<div class="post-preview-assets">
<img class="post-thumbnail" src="{{ site.baseurl }}/assets/images/{{ post.thumbnail }}">
</div>
<div class="post-preview-content">
<header class="post-title">
<h2 itemprop="name">
<a href="{{ site.baseurl }}{{ post.url }}" itemprop="url">{{ post.title }}</a>
</h2>
</header>
<div class="post-meta">
<time datetime="{{ post.date | date_to_long_string }}">
<i class="fas fa-clock"></i>{{ post.date | date_to_long_string }}
</time>
<span>•</span>
<span><i class="fas fa-user"></i>{{ post.author }}</span>
<span>•</span>
<span class="reading-time">
<i class="fas fa-hourglass-half"></i>
{% capture words %}
{{ post.content | number_of_words | minus: 180 }}
{% endcapture %}
{% unless words contains '-' %}
{{ words | plus: 150 | divided_by: 150 | append: ' min.' }}
{% endunless %}
</span>
<div class="post-tags">
<ul>
{% for tag in post.tags %}
<li class="post-tag">
<i class="fas fa-tag"></i>
<a href="{{ site.baseurl }}/tags/#{{ tag | slugify }}">
{{ tag | capitalize }}
</a>
</li>
{% endfor %}
</ul>
</div>
</div>
<div class="post-preview">
<p class="post-extract">{{ post.excerpt | truncatewords: 40 }}</p>
</div>
</div>
</article>
{% endfor %}
</div>
</main>