{% extends "@bazar/layouts/input.twig" %}

{% block input %}
  {{ include_javascript('tools/tags/libs/vendor/bootstrap-tagsinput.min.js') }}
  {{ include_javascript('tools/bazar/presentation/javascripts/inputs/checkbox-tags.js') }}
    <input 
      type="text" 
      name="{{ field.propertyName }}" 
      class="yeswiki-input-entries yeswiki-input-entries{{ field.propertyName }}" 
      {% if field.required %}required{% endif %}>
    <input type="hidden" value="''" name="{{ field.propertyName  ~ field.fromFormId }}">
    <script>
      if (typeof bazarlistTagsInputsData === "undefined"){
        var bazarlistTagsInputsData = new Object();
      }
      bazarlistTagsInputsData['{{ field.propertyName }}'] = {{ bazarlistTagsInputsData|raw }};
    </script>
{% endblock %}
