From 65076748a9b84587b2d829ce1a16493f059dfd0b Mon Sep 17 00:00:00 2001 From: Cyril Date: Wed, 30 Oct 2019 12:19:42 +0100 Subject: [PATCH] Separate base page into partials --- templates/_partials/flashes.html.twig | 18 ++++++++++++++++++ templates/_partials/navigation.html.twig | 20 ++++++++++++++++++++ templates/base.html.twig | 20 ++------------------ 3 files changed, 40 insertions(+), 18 deletions(-) create mode 100644 templates/_partials/flashes.html.twig create mode 100644 templates/_partials/navigation.html.twig diff --git a/templates/_partials/flashes.html.twig b/templates/_partials/flashes.html.twig new file mode 100644 index 0000000..12b62b6 --- /dev/null +++ b/templates/_partials/flashes.html.twig @@ -0,0 +1,18 @@ +
+
+ {% for label, messages in app.flashes %} + {% for message in messages %} + + {% endfor %} + {% endfor %} +
+
diff --git a/templates/_partials/navigation.html.twig b/templates/_partials/navigation.html.twig new file mode 100644 index 0000000..a16cc44 --- /dev/null +++ b/templates/_partials/navigation.html.twig @@ -0,0 +1,20 @@ + \ No newline at end of file diff --git a/templates/base.html.twig b/templates/base.html.twig index feaf7cb..2010bcb 100644 --- a/templates/base.html.twig +++ b/templates/base.html.twig @@ -7,24 +7,8 @@ - + {% include '_partials/navigation.html.twig' %} + {% include '_partials/flashes.html.twig' %}
{% block body %}{% endblock %}