<commit_before>{# @var datagrid \Sidus\DataGridBundle\Model\DataGrid #}
{# @var pager \Pagerfanta\Pagerfanta #}
{% set pager = datagrid.queryHandler.pager %}

{% set form = datagrid.formView %}
{% if datagrid.formTheme %}
    {% form_theme form datagrid.formTheme %}
{% endif %}
{{ form_start(form) }}

{% block filters %}
    {% if form.filters|length > 0 %}
        <div class="datagrid-filters">
            <div class="row">
                {% for subForm in form.filters %}
                <div class="col-md-4">
                    {{ form_row(subForm) }}
                </div>
                {% if loop.index % 3 == 0 %}
            </div>
            <div class="row">
                {% endif %}
                {% endfor %}
            </div>
            {% block filters_actions %}
                <div class="datagrid-filters-actions btn-group pull-right">
                    {% if datagrid.formView.filterResetButton is defined %}
                        {{ form_widget(datagrid.formView.filterResetButton) }}
                    {% endif %}
                    {% if datagrid.formView.filterSubmitButton is defined %}
                        {{ form_widget(datagrid.formView.filterSubmitButton) }}
                    {% endif %}
                </div>
            {% endblock %}
            <hr class="clear">
        </div>
    {% endif %}
{% endblock %}

{% block datagrid_actions %}
    <div class="datagrid-actions">
        {% if pager.nbPages > 1 %}
            <div class="pull-right">
                {{ pagerfanta(pager, 'twitter_bootstrap3') }}
            </div>
        {% endif %}
        <div class="btn-group">
            {% for action in datagrid.formView.actions %}
                {{ form_widget(action) }}
            {% endfor %}
        </div>
    </div>
{% endblock %}

{% block datagrid_table %}
    {% set sort = datagrid.formView.sortable %}
    <table class="table table-striped">
        {% block datagrid_table_captions %}
            <caption>
                {{ 'sidus.datagrid.results.label'|trans({
                    '%first%': pager.currentPageOffsetStart,
                    '%last%': pager.currentPageOffsetEnd,
                    '%count%': pager.count,
                }) }}
            </caption>
        {% endblock %}
        {% block datagrid_table_headers %}
            <thead>
            <tr><commit_msg>Hiding datagrid actions when disabled<commit_after>{# @var datagrid \Sidus\DataGridBundle\Model\DataGrid #}
{# @var pager \Pagerfanta\Pagerfanta #}
{% set pager = datagrid.queryHandler.pager %}

{% set form = datagrid.formView %}
{% if datagrid.formTheme %}
    {% form_theme form datagrid.formTheme %}
{% endif %}
{{ form_start(form) }}

{% block filters %}
    {% if form.filters|length > 0 %}
        <div class="datagrid-filters">
            <div class="row">
                {% for subForm in form.filters %}
                <div class="col-md-4">
                    {{ form_row(subForm) }}
                </div>
                {% if loop.index % 3 == 0 %}
            </div>
            <div class="row">
                {% endif %}
                {% endfor %}
            </div>
            {% block filters_actions %}
                <div class="datagrid-filters-actions btn-group pull-right">
                    {% if datagrid.formView.filterResetButton is defined %}
                        {{ form_widget(datagrid.formView.filterResetButton) }}
                    {% endif %}
                    {% if datagrid.formView.filterSubmitButton is defined %}
                        {{ form_widget(datagrid.formView.filterSubmitButton) }}
                    {% endif %}
                </div>
            {% endblock %}
            <hr class="clear">
        </div>
    {% endif %}
{% endblock %}

{% block datagrid_actions %}
    <div class="datagrid-actions">
        {% if pager.nbPages > 1 %}
            <div class="pull-right">
                {{ pagerfanta(pager, 'twitter_bootstrap3') }}
            </div>
        {% endif %}
        {% if not disabled|default(false) %}
            <div class="btn-group">
                {% for action in datagrid.formView.actions %}
                    {{ form_widget(action) }}
                {% endfor %}
            </div>
        {% endif %}
    </div>
{% endblock %}

{% block datagrid_table %}
    {% set sort = datagrid.formView.sortable %}
    <table class="table table-striped">
        {% block datagrid_table_captions %}
            <caption>
                {{ 'sidus.datagrid.results.label'|trans({
                    '%first%': pager.currentPageOffsetStart,
                    '%last%': pager.currentPageOffsetEnd,
                    '%count%': pager.count,
                }) }}
            </caption>
        {% endblock %}
        {% block datagrid_table_headers %}
            <thead>
            <tr>
{'fraction_non_alphanumeric': 0.14114980424479703, 'fraction_numerical': 0.00247269730063878, 'mean_word_length': 1.5137234593474884, 'pattern_counts': {'":': 0, '<': 47, '<?xml version=': 0, '>': 51, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '968315', 'n_tokens_mistral': 1527, 'n_tokens_neox': 1337, 'n_words': 247}