From bfdb82a4bad496ccafbf2b499e17278e77367d2e Mon Sep 17 00:00:00 2001 From: Oliver Davies Date: Wed, 30 Jun 2021 08:00:00 +0100 Subject: [PATCH] Move the intro text into the page template --- source/_layouts/page.html.twig | 8 ++++++++ source/_pages/blog.html.twig | 4 ++-- source/_pages/talks.html.twig | 4 ++-- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/source/_layouts/page.html.twig b/source/_layouts/page.html.twig index 9c11d90b6..4caf2d671 100644 --- a/source/_layouts/page.html.twig +++ b/source/_layouts/page.html.twig @@ -1 +1,9 @@ {% extends 'base' %} + +{% block content_wrapper %} + {% if page.intro_text %} +

{{ page.intro_text }}

+ {% endif %} + + {{ parent() }} +{% endblock %} diff --git a/source/_pages/blog.html.twig b/source/_pages/blog.html.twig index a03a79d96..27002a6ee 100644 --- a/source/_pages/blog.html.twig +++ b/source/_pages/blog.html.twig @@ -2,10 +2,10 @@ title: Blog use: - posts +intro_text: | + TODO: update text --- -

TODO: update text

-
{% for talk in data.posts|sort((a, b) => a.date < b.date) %} diff --git a/source/_pages/talks.html.twig b/source/_pages/talks.html.twig index 25fe15c56..d1d4a4afb 100644 --- a/source/_pages/talks.html.twig +++ b/source/_pages/talks.html.twig @@ -2,10 +2,10 @@ title: Talks and workshops use: - talks +intro_text: | + Starting with my first talk in September 2012, I have given 81 presentations and workshops at various conferences and meetups, in-person and remotely, on topics including PHP, Drupal, automated testing, Git, CSS, and systems administration. --- -

Starting with my first talk in September 2012, I have given 81 presentations and workshops at various conferences and meetups, in-person and remotely, on topics including PHP, Drupal, automated testing, Git, CSS, and systems administration.

-
{% for talk in data.talks|sort((a,b) => a.sortable_date < b.sortable_date) %}