[06/08/23] sorted blog and til pages

This commit is contained in:
andrew 2023-08-06 18:21:39 +01:00
parent d5f0acdc6c
commit 83590d3916
19 changed files with 203 additions and 224 deletions

View file

@ -9,17 +9,17 @@ permalink: /blog/
<hr>
<ul style="list-style-type:none;margin:0;padding:0;">
{% for post in site.posts %}
{% assign categories = post.categories %}
{% assign category = site.data.categories[categories.first] %}
{% assign category = post.category %}
{% if category == 'blog' %}
<li>
<h4><a href="{{ post.url }}">{{ post.title }}</a></h4>
<div style="font-family:Rubik;font-weight:500;">
<i class="fas fa-calendar"></i>&nbsp;{{ post.date | date_to_string }}&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;
<span style="background-color:{{category.backColor}};color:{{category.textColor}};">&nbsp;<i class="fas fa-folder"></i>&nbsp;{{ categories.first }}&nbsp;</span>
<i class="fas fa-calendar"></i>&nbsp;{{ post.date | date_to_string }}
</div>
{{ post.content | strip_html | truncatewords: 30 }}
<br>
<br>
</li>
{% endif %}
{% endfor %}
</ul>