From 10bac5531fc8b4c8ce26f5d4bd65c81bf2c1a26b Mon Sep 17 00:00:00 2001 From: Bastian Venthur Date: Fri, 1 Jul 2022 12:44:23 +0200 Subject: [PATCH] improved default template --- CHANGELOG.md | 4 ++++ blag/templates/archive.html | 5 +++++ blag/templates/article.html | 23 ++++++++++++++++++++++- blag/templates/base.html | 11 ++++++++--- blag/templates/tag.html | 5 +++++ 5 files changed, 44 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a97099e..f223725 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## unreleased + +* improved default template + ## [1.3.2] - 2022-06-29 * Added --version option diff --git a/blag/templates/archive.html b/blag/templates/archive.html index c680429..e8f9cca 100644 --- a/blag/templates/archive.html +++ b/blag/templates/archive.html @@ -7,6 +7,11 @@ {% if entry.title %}

{{entry.title}}

+ + {% if entry.description %} +

— {{ entry.description }}

+ {% endif %} + {% endif %}

Written on {{ entry.date.date() }}.

diff --git a/blag/templates/article.html b/blag/templates/article.html index 5507a42..4080c36 100644 --- a/blag/templates/article.html +++ b/blag/templates/article.html @@ -3,5 +3,26 @@ {% block title %}{{ title }}{% endblock %} {% block content %} -{{ content }} + + {% if title %} +

{{ title }}

+ {% endif %} + + + + + {{ content }} + {% endblock %} diff --git a/blag/templates/base.html b/blag/templates/base.html index 68ab717..fc6f822 100644 --- a/blag/templates/base.html +++ b/blag/templates/base.html @@ -7,16 +7,20 @@ {%- if description %} - {% endif %} - {% block title %}{% endblock %} + {%- else %} + + {%- endif %} + {% block title %}{% endblock %} | {{ site.description }}
-

A Blog

+

{{ site.title }}

@@ -26,6 +30,7 @@ {% block content %} {% endblock %} + diff --git a/blag/templates/tag.html b/blag/templates/tag.html index 198dc67..7abb4df 100644 --- a/blag/templates/tag.html +++ b/blag/templates/tag.html @@ -7,6 +7,11 @@ {% if entry.title %}

{{entry.title}}

+ + {% if entry.description %} +

— {{ entry.description }}

+ {% endif %} + {% endif %}

Written on {{ entry.date.date() }}.