From a77515e9c72817b51e93b05f77c594b3710e0f72 Mon Sep 17 00:00:00 2001 From: zaaarf Date: Fri, 22 Dec 2023 12:19:19 +0100 Subject: [PATCH] feat: randomized subtitle --- templates/base-page.html | 15 +++++++++++++ templates/blog-page.html | 37 +------------------------------ templates/footer.html | 2 +- templates/head.html | 1 + templates/index.html | 17 ++++++++++++-- templates/page.html | 39 +-------------------------------- templates/shortcodes/image.html | 8 ------- templates/toc.html | 26 ++++++++++++++++++++++ 8 files changed, 60 insertions(+), 85 deletions(-) create mode 100644 templates/base-page.html delete mode 100644 templates/shortcodes/image.html create mode 100644 templates/toc.html diff --git a/templates/base-page.html b/templates/base-page.html new file mode 100644 index 0000000..49a1661 --- /dev/null +++ b/templates/base-page.html @@ -0,0 +1,15 @@ +

{{ page.title }}

+ +{% if page.toc and page.extra.toc %} + {% include "toc.html" %} +{% endif %} + +{{ page.content | safe }} + +

+ {% if page.taxonomies.tags %} + {% for tag in page.taxonomies.tags %} + /{{ tag }}/ + {% endfor %} + {% endif %} +

\ No newline at end of file diff --git a/templates/blog-page.html b/templates/blog-page.html index 5bb8d11..324fa66 100644 --- a/templates/blog-page.html +++ b/templates/blog-page.html @@ -6,42 +6,7 @@ {% if config.extra.author and config.extra.display_author == true %} {% endif %} -

{{ page.title }}

-{% if page.toc and page.extra.toc %} -

Table of contents

- -{% endif %} +{% include "base-page.html" %} -{{ page.content | safe }} - -

- {% if page.taxonomies.tags %} - {% for tag in page.taxonomies.tags %} - /{{ tag }}/ - {% endfor %} - {% endif %} -

{% endblock content %} \ No newline at end of file diff --git a/templates/footer.html b/templates/footer.html index 316e2e3..f3fc5c7 100644 --- a/templates/footer.html +++ b/templates/footer.html @@ -2,7 +2,7 @@

Licensed under the MIT License.
- Built with Zola using anemone theme & veqev colors.
+ Built with Zola combining the anemone and hello-friend-ng themes.

{% if config.generate_feed %} diff --git a/templates/head.html b/templates/head.html index 38555c5..682195c 100644 --- a/templates/head.html +++ b/templates/head.html @@ -87,6 +87,7 @@ {% if image %} {% endif %} + {% endblock metatags %} {% if config.generate_feed %} {% block feed %} diff --git a/templates/index.html b/templates/index.html index e68bfa3..d36a724 100644 --- a/templates/index.html +++ b/templates/index.html @@ -8,10 +8,23 @@

{{ config.title }}

{% endif %} {% if config.extra.home_subtitle %} -

{{ config.extra.home_subtitle }}

+

{{ config.extra.home_subtitle }}

{% elif config.description %} -

{{ config.description }}

+

{{ config.description }}

{% endif %} {% include "svg.html" %}
+{% if config.extra.home_subtitle_suffixes %} + + +{% endif %} {% endblock content %} diff --git a/templates/page.html b/templates/page.html index a823465..60bfc60 100644 --- a/templates/page.html +++ b/templates/page.html @@ -1,42 +1,5 @@ {% extends "base.html" %} {% block content %} -

{{ page.title }}

- -{% if page.toc and page.extra.toc %} -

Table of contents

- -{% endif %} - -{{ page.content | safe }} - -

-{% if page.taxonomies.tags %} -{% for tag in page.taxonomies.tags %} -/{{ tag }}/ -{% endfor %} -{% endif %} -

+ {% include "base-page.html" %} {% endblock content %} \ No newline at end of file diff --git a/templates/shortcodes/image.html b/templates/shortcodes/image.html deleted file mode 100644 index 616cc2b..0000000 --- a/templates/shortcodes/image.html +++ /dev/null @@ -1,8 +0,0 @@ -{% if src %} - {# If the image's URL is internal to the site... #} - {% if src is not starting_with("http") %} - {# ... then prepend the site's base URL to the image's URL. #} - {% set src = config.base_url ~ src %} - {% endif %} -
-{% endif %} diff --git a/templates/toc.html b/templates/toc.html new file mode 100644 index 0000000..2dda25b --- /dev/null +++ b/templates/toc.html @@ -0,0 +1,26 @@ +
+

Table of contents

+ +
\ No newline at end of file