-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.mokkf
61 lines (50 loc) · 1.71 KB
/
index.mokkf
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
permalink: index.html
collection: pages
author: Club
title: Home
markdown: false
---
{% assign urls = '' | split: '' %}
{% assign post_date_rfc_3339 = collections["posts"] | map: 'date' | sort: "rfc_3339" %}
{%- for post_date in post_date_rfc_3339 reversed -%}
{%- for post in collections["posts"] -%}
{%- if post.date.rfc_3339 == post_date.rfc_3339 -%}
{%- unless urls contains post.url -%}
{% assign urls = urls | push: post.url %}
{%- unless post.data.tags contains "draft" -%}
<article class="blog">
{% assign author = global.authors | where: "short", post.data.author | first %}
<!-- Post title container -->
<div class="post-title-container-nohero">
<!-- Post title -->
<h1>
<a href="{{ post.url | remove: 'index.html' | prepend: global.url }}" title="{{ post.data.title }}">{{ post.data.title }}</a>
</h1><br/>
<a href="mailto:{{ author.email }}">{{ author.name }}</a><br/>
<!-- Post meta -->
<div class="post-meta-nohero">
<span>{{ post.date.rfc_2822 }}</span>
<span class="post-meta-link-nohero">▪</span>
<span>
{% for tag in post.data.tags %}
<a href="{{ 'tag/' | prepend: global.url }}{{ tag }}">#{{ tag }}</a>
{% endfor %}
</span>
</div>
</div>
{{ post.content | remove: '<!–-break-–>' }}
<div class="readmore">
<a href="{{ post.url | remove: 'index.html' | prepend: global.url }}" role="button">Read more</a>
<div>
</article>
{% if forloop.first == false %}
<!-- Last post does not need a hr -->
<hr>
{% endif %}
{%- endunless -%}
{%- endunless -%}
{%- endif -%}
{%- endfor -%}
{%- endfor -%}