From bb3305e14a14ab2d795a0bc22174273b52fed351 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?benjamin=20melan=C3=A7on?= Date: Mon, 19 Nov 2018 03:06:04 -0500 Subject: [PATCH] Do classes for section separately --- agaric/templates/paragraph/paragraph.html.twig | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/agaric/templates/paragraph/paragraph.html.twig b/agaric/templates/paragraph/paragraph.html.twig index 1ea4f0c..e969bfa 100644 --- a/agaric/templates/paragraph/paragraph.html.twig +++ b/agaric/templates/paragraph/paragraph.html.twig @@ -53,10 +53,10 @@ {% for style in paragraph.field_style_classes %} {% set styles = styles|merge([style.value]) %} {% endfor %} - {% set classes = classes|merge([ 'hero', 'section-restitch' ]) %} - {% set classes = classes|merge(styles) %} - {% set attributes = attributes.removeClass('section').addClass(classes).setAttribute('data-headerbg', 'light') %} -
+ {% set section_classes = [ 'hero', 'section-restitch' ] %} + {% set section_classes = section_classes|merge(styles) %} + {% set section_attributes = create_attribute().addClass(section_classes).setAttribute('data-headerbg', 'light') %} +
{% endif %} {% block paragraph %}