{% import "_includes/forms" as forms %}

{% if disabled %}
  <div class="elementselect">
    <div class="elements">
      {% for element in elementField.elements %}
        {% include "_elements/element" with {
          context: 'field',
          size: 'small'
        } %}
      {% endfor %}
    </div>
  </div>
{% else %}
  {% if siteField %}
    {{ forms.hidden(siteField) }}
  {% endif %}
  {% if queryField %}
    <div class="linkfield--elementRow">
      <div class="linkfield--elementRowSelect">
        {{ forms.elementSelect(elementField) }}
      </div>
      <div class="linkfield--elementRowQuery">
        {{ forms.text(queryField) }}
      </div>
    </div>
  {% else %}
    {{ forms.elementSelect(elementField) }}
  {% endif %}
{% endif %}
