diff --git a/agaric/templates/field/field.html.twig b/agaric/templates/field/field.html.twig index 817845c..53e11fe 100644 --- a/agaric/templates/field/field.html.twig +++ b/agaric/templates/field/field.html.twig @@ -50,22 +50,6 @@ {% set title_attributes = title_attributes.addClass(title_classes) %} {# Child templates can specify classes to be added to items. #} {% set item_classes = item_classes ?? [] %} -{# Child templates can specify whether items should be wrapped. #} -{% set use_item_wrapper = use_item_wrapper is defined ? use_item_wrapper : true %} - -{% macro render_item(item, item_classes, use_item_wrapper) %} - {% - set item = item|merge({ - 'attributes': item.attributes.addClass(item_classes) - }) - %} - {% if use_item_wrapper %} - {{ item.content }} - {% else %} - {{ item.content }} - {% endif %} -{% endmacro render_item %} -{% import _self as helpers %} {% if label_hidden %} {% for item in items %} @@ -74,14 +58,8 @@ {% else %} {{ label }} - {% if multiple and use_item_wrapper %} -
- {% endif %} {% for item in items %} - {{ helpers.render_item(item, item_classes, use_item_wrapper) }} + {{ item.content }} {% endfor %} - {% if multiple and use_item_wrapper %} -
- {% endif %}

{% endif %}