{% extends "allianceauth/base-bs5.html" %}

{% load i18n %}
{% load aa_i18n %}

{% block page_title %}
    {% translate "Sovereignty Timer" %}
{% endblock %}

{% block header_nav_brand %}
    {% translate "Sovereignty Timer" %}
{% endblock header_nav_brand %}

{% block content %}
    <div class="aa-sovtimer">
        <div class="aa-sovtimer-header">
            {% block sovtimer_header %}{% endblock %}
        </div>

        <div class="aa-sovtimer-body">
            {% get_datatables_language_static LANGUAGE_CODE as DT_LANG_PATH %}

            <script>
                const sovtimerJsSettingsDefaults = {
                    datetimeFormat: {
                        date: 'L',
                        time: 'LT',
                        timeWithSeconds: 'LTS',
                        datetime: 'L LT',
                        datetimeWithSeconds: 'L LTS',
                        datetimeLong: 'LL LTS',
                    },
                    dataTables: {
                        paging: true,
                        languageUrl: "{{ DT_LANG_PATH }}",
                        dom: 'lrtip', // Removing the search bar (Default is 'lfrtip')
                        ordering: {
                            indicators: false,
                            handler: false
                        },
                        columnControl: [
                            {
                                target: 0,
                                content: [
                                    'order',
                                    // [
                                    //     'orderAsc',
                                    //     'orderDesc',
                                    //     'spacer',
                                    //     'orderAddAsc',
                                    //     'orderAddDesc',
                                    //     'spacer',
                                    //     'orderRemove'
                                    // ]
                                ]
                            },
                            {
                                target: 1,
                                content: [
                                    'search'
                                ]
                            }
                        ]
                    },
                };
            </script>

            {% block sovtimer_body %}{% endblock %}
        </div>

        <div class="aa-sovtimer-footer mt-3 pt-3 border-top border-light">
            {% include "sovtimer/partials/footer/app-translation-footer.html" %}
        </div>
    </div>
{% endblock %}
