{% block monitored_mailboxes_widget %}
  <div class="row">
      {% if 'general' != mailbox %}
        <div class="col-xs-12">{{ form_row(form.folder) }}</div>
        <div class="col-xs-12">{{ form_row(form.override_settings) }}</div>
      {% else %}
        <div class="col-xs-12">{{ form_row(form.address) }}</div>
        <div class="col-xs-12 pt-lg" id="{{ mailbox }}TestButtonContainer">
            <div class="button_container">
                {{ form_widget(form.test_connection_button) }}
                <span class="ri-loader-3-line ri-spin hide"></span>
            </div>
            <div class="help-block"></div>
        </div>
      {% endif %}
  </div>

  {% if 'general' != mailbox %}
    <div class="row">
        <div class="col-xs-12">{{ form_row(form.address) }}</div>
        <div class="col-xs-12 pt-lg" id="{{ mailbox }}TestButtonContainer" data-show-on='{"config_emailconfig_monitored_email_{{ mailbox }}_override_settings_1": "checked"}'>
            <div class="button_container">
                {{ form_widget(form.test_connection_button) }}
                <span class="ri-loader-3-line ri-spin hide"></span>
            </div>
            <div class="help-block"></div>
        </div>
    </div>
  {% endif %}

  <div class="row">
      <div class="col-xs-12">
          {{ form_row(form.host) }}
      </div>
      <div class="col-xs-12">
          {{ form_row(form.port) }}
      </div>
      {% if is_extension_loaded('openssl') %}
        <div class="col-xs-12">
            {{ form_row(form.encryption) }}
        </div>
      {% endif %}
  </div>

  <div class="row">
      <div class="col-xs-12">
          {{ form_row(form.user) }}
      </div>
      <div class="col-xs-12">
          {{ form_row(form.password) }}
      </div>
  </div>
{% endblock %}
