summaryrefslogtreecommitdiffstatshomepage
path: root/templates/macros.html
diff options
context:
space:
mode:
authorWolfgang Müller2021-06-12 20:28:30 +0200
committerWolfgang Müller2021-06-12 20:28:30 +0200
commit34f0c8a527f443c0a296ce301631f2625a808d25 (patch)
tree4fdfd3ba2323fe56ad38b5dc123fb009d1490f56 /templates/macros.html
parent725b8fcbca3db267cee943c64098d6caa77b8cab (diff)
downloadzunzuncito-34f0c8a527f443c0a296ce301631f2625a808d25.tar.gz
Put post titles in the banner
Post titles are currently only visible in the feed, or on the post page itself. Since people may remember posts by their titles rather than their number, display the titles on each post's banner as well for easier searching. This means we can now get rid of the extra item in the post page's description. A neat side effect is that we now have a header element for each <article>, making W3C a bit happier.
Diffstat (limited to 'templates/macros.html')
-rw-r--r--templates/macros.html5
1 files changed, 3 insertions, 2 deletions
diff --git a/templates/macros.html b/templates/macros.html
index 9f0f792..354eb6e 100644
--- a/templates/macros.html
+++ b/templates/macros.html
@@ -7,11 +7,12 @@
<header>
<img class="avatar" alt="{{ config.extra.author }}" src="{{ config.extra.avatar }}" />
<div class="banner smaller">
- <span class="info">
+ <div class="info">
<a class="bold-hover" title="permalink to this post" href="{{ post.permalink }}">{% if mention %}№ {{ post.slug }} {% else %}§{% endif %}</a>
<time class="mute" datetime="{{ post.date }}" title="{{ post.date }}">{{ post.date | date(format="%F %R") }}</time>
+ {%- if post.title %} · <h2>{{ post.title }}</h2>{% endif %}
{%- if post.draft %}<span class="warning">DRAFT</span>{% endif %}
- </span>
+ </div>
{%- if "tags" in post.taxonomies %}
<nav class="tags">
<ul class="inline">{{ self::render_tags(tags=post.taxonomies.tags) }}</ul>