{% use "bootstrap_5_horizontal_layout.html.twig" %} {% block collection_widget %} {% if prototype is defined and not prototype.rendered %} {% set attr = attr|merge({ 'data-prototype-code': form_row(prototype), 'data-prototype-placeholder': prototype.vars.name, 'data-prototype-index': prototype.parent.children|length > 0 ? prototype.parent.children|last.vars.name + 1 : 0, }) %} {% endif %} {{ block('form_widget') }} {% endblock collection_widget %} {% block collection_entry_row %} {% if expanded is defined and expanded %} {{ block('fieldset_form_row') }} {% else %} {% set widget_attr = {context_collection_entry: true} %} {% if help is not empty %} {% set widget_attr = {attr: {'aria-describedby': id ~"_help"}} %} {% endif %} {% set row_class = row_class|default(row_attr.class|default('mb-3')) %} {% set is_form_floating = is_form_floating|default('form-floating' in row_class) %} {% set is_input_group = is_input_group|default('input-group' in row_class) %} {#- Remove behavior class from the main container -#} {% set row_class = row_class|replace({'form-floating': '', 'input-group': ''}) %}