From 012d98d707a5f0b9410147f6d7b1e6a75b739888 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?benjamin=20melan=C3=A7on?= Date: Tue, 16 Oct 2018 10:58:55 -0400 Subject: [PATCH] Override Bulma block header and add our classes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Ideally Bulma would use attributes in its templates making overriding like this unnecessary. Still need a way to basically configure when different classes get sent in— for instance, for us the header is dark in the campaigns section, but Drupal doesn't even have a concept of campaign 'section' let alone a way to configure and pass in classes or other variables. --- agaric/templates/layout/page.html.twig | 37 ++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/agaric/templates/layout/page.html.twig b/agaric/templates/layout/page.html.twig index 33323b3..4fc4623 100644 --- a/agaric/templates/layout/page.html.twig +++ b/agaric/templates/layout/page.html.twig @@ -34,3 +34,40 @@ {% endif %} {% endblock navbar %} + +{% set header_section_attributes = create_attribute() %} + +{% block header %} + + {% block header_and_search %} + {% if page.header or page.header_search %} + {# Header hero region + search #} +
+
+
+
+ {{ page.header }} + {% if is_front and site_slogan %} +

{{ site_slogan }}

+ {% endif %} +
+
+ {{ page.header_search }} +
+
+
+
+ {% endif %} + {% endblock header_and_search %} + {% block tabs %} + {# Drupal tabs #} + {% if page.header_tabs %} + + {% endif %} + {% endblock tabs %} + +{% endblock header %}