Private
Public Access
1
0

added tags functionality

This commit is contained in:
2025-12-22 07:45:36 +01:00
parent 08cb8f4cc9
commit 1730c2e5fc
6 changed files with 90 additions and 26 deletions

View File

@@ -2,17 +2,26 @@
{% block content %}
<section class="hero">
<h2 style="color: #2563eb; margin-bottom : 10%">I write about Self-hosting, Arduino, STM32 and various tech stupidity.</h2>
<h2 style="color: #2563eb; margin-bottom : 10%">I write about Self-hosting, Arduino, STM32.</h2>
</section>
<div class="post-list">
{% for post in posts %}
<article class="post-item">
<h3><a href="{{ url_for('post', path=post.path) }}">{{ post.title }}</a></h3>
<span class="date">{{ post.date }}</span>
<p>{{ post.meta.get('description', 'Read more...') }}</p>
<p>{{ post.meta.get('tag', 'no tag') }}</p>
</article>
<article class="post-item">
<h3>
<a href="{{ url_for('post', path=post.path) }}" class="main-link">
{{ post.title }}
</a>
</h3>
<span class="date">{{ post.date }}</span>
<p>{{ post.meta.get('description', 'Read more...') }}</p>
<div class="tags" style="position: relative; z-index: 2;">
{% for tag in post.meta.get('tags', []) %}
<a href="{{ url_for('tag', tag_name=tag) }}" class="tag-badge">#{{ tag }}</a>
{% endfor %}
</div>
</article>
{% else %}
<p>No posts yet. Time to write something!</p>
{% endfor %}