-
Notifications
You must be signed in to change notification settings - Fork 5
/
index.html
41 lines (28 loc) · 944 Bytes
/
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
---
layout: default-foundation-20210515
title: Posts by Date
---
{% if site.posts.size > 0 -%}
{%- assign posts = site.posts | sort: 'title' -%}
{%- assign lastpost = posts.last -%}
{%- assign last50posts = site.posts | sort: 'date' | reverse | slice: 0, 50 -%}
{%- assign sorted = site.posts | sort: 'date' | reverse -%}
{%- assign showindex = True -%}
<div class="callout">
<h2>Posts Index - by Date</h2>
</div>
<div style="column-count: 2;">
{%- for post in sorted -%}
{%- assign draft = post.path | slice: 0,6 %}
{%- if draft == "_draft" %}
<span style="background-color: cornsilk;">
{% endif %}
<a href="{{post.url}}">{{post.title}}</a>
<small>({{post.date | date: "%Y/%m/%d"}})</small>
{%- if draft == "_draft" %}
<small><strong>**DRAFT**</strong></small></span>
{% endif %}
<br>
{%- endfor -%}
</div>
{% endif %}