{% load i18n widget_tweaks %}
<div class="row">
  {% block actions %}
    <div class="col-md-7 order-2 order-lg-1 d-flex align-items-center">
      {% block actions-counter %}
        {% if actions_selection_counter %}
            <span class="action-counter" data-actions-icnt="{{ cl.result_list|length }}">{{ selection_note }}</span>
            {% if cl.result_count != cl.result_list|length %}
            <span class="all hidden">{{ selection_note_all }}</span>
            <span class="question hidden">
                <a href="#" title="{% translate "Click here to select the objects across all pages" %}">{% blocktranslate with cl.result_count as total_count %}Select all {{ total_count }} {{ module_name }}{% endblocktranslate %}</a>
            </span>
            <span class="clear hidden"><a href="#">{% translate "Clear selection" %}</a></span>
            {% endif %}
        {% endif %}
      {% endblock %}
    </div>
    <div class="col-md-5 order-1 order-lg-2 mb-2 mb-lg-0">
      {% block actions-form %}
      <div class="input-group w-auto">
        <span class="input-group-text">{% trans "Actions" %}</span>
        {% for field in action_form %}
          {% render_field field class="form-select mb-0" %}
        {% endfor %}
        <button type="submit" class="btn btn-primary" title="{% translate "Run the selected action" %}" name="index" value="{{ action_index|default:0 }}">{% translate "Go" %}</button>
      </div>
      {% endblock %}
    </div>
  {% endblock %}
</div>
