From 821912a00226881a18d5e5a74e571ebcd7722037 Mon Sep 17 00:00:00 2001 From: Flavio Copes Date: Sun, 14 Feb 2016 10:40:26 +0100 Subject: [PATCH] Instead of overriding the whole Form template, override blocks. Do not merge yet. Noticed it was overriding just to add some classes. This new method will be possible in the next Form Plugin release, as I just added this possibility. Applies to Deliver and Gateway only. --- templates/forms/form.html.twig | 26 +++++++------------------- 1 file changed, 7 insertions(+), 19 deletions(-) diff --git a/templates/forms/form.html.twig b/templates/forms/form.html.twig index 80b4463..d408c5f 100644 --- a/templates/forms/form.html.twig +++ b/templates/forms/form.html.twig @@ -1,21 +1,9 @@ -
{{ form.message }}
+{% extends "forms/default/form.html.twig" %} -
-{% for field in form.fields %} - {% set value = form.value(field.name) %} -
- {% include "forms/fields/#{field.type}/#{field.type}.html.twig" %} -
-{% endfor %} +{% block form_classes %} +class="contact-form commentsblock" +{% endblock %} -
- {% for button in form.buttons %} - - {% endfor %} -
- - {{ nonce_field('form', 'form-nonce') }} - -
+{% block button_classes %} +class="pushbutton-wide" +{% endblock %}