{# @copyright   Copyright (C) 2010-2024 Combodo SAS #}
{# @license     http://opensource.org/licenses/AGPL-3.0 #}
{% block iboInput %}
    {% if oUIBlock.HasLabel() and oUIBlock.IsLabelBefore() %}
        {% include "base/components/input/inputlabel.html.twig" %}
    {% endif %}
    <select id="{{ oUIBlock.GetId() }}" name="{{ oUIBlock.GetName() }}"
            {% if oUIBlock.GetSubmitOnChange() %} onChange="this.form.submit();" {% endif %}
            {% if oUIBlock.IsMultiple() %} multiple {% endif %}
            class="{% if oUIBlock.IsHidden() %}ibo-is-hidden{% endif %}{% if oUIBlock.GetAdditionalCSSClassesAsString() %} {{ oUIBlock.GetAdditionalCSSClassesAsString() }}{% endif %}"
            {% if oUIBlock.GetDataAttributes() %}
                {% for sName, sValue in oUIBlock.GetDataAttributes() %}
                    data-{{ sName }}="{{ sValue }}"
                {% endfor %}
            {% endif %}
    >
        {% for oSubBlock in oUIBlock.GetSubBlocks() %}
            {{ render_block(oSubBlock, {aPage: aPage}) }}
        {% endfor %}
    </select>
    {% if oUIBlock.HasLabel() and not oUIBlock.IsLabelBefore() %}
        {% include "base/components/input/inputlabel.html.twig" %}
    {% endif %}
{% endblock %}