{%- set class = [
    'multiselect',
    (class is defined ? class : null)
]|filter|join(' ') %}

{%- set options = (options is defined ? options : []) %}
{%- set values = (values is defined ? values|json_decode : []) -%}
{%- set hasOptgroups = false -%}

{% if name is defined and name %}
    <input type="hidden" name="{{ name }}" value="">
{% endif -%}

<div class="{{ class }}"
        {%- if block('attr') is defined %} {{ block('attr') }}{% endif %}>
    <select multiple
            {%- if id is defined %