<commit_before>{% block media_fine_uploader_widget %}
    {{ form_widget(form) }}

<div id="fine-uploader-{{ id }}"></div>
<div id="alert-{{ id }}"></div>

    <script type="text/javascript">
        window.addEventListener('DOMContentLoaded', function() {
            qq.uiPrivateApi._isEditFilenameEnabled = function(){
                return this._templating.isEditFilenamePossible() && qq.FilenameClickHandler && qq.FilenameInputFocusHandler && qq.FilenameInputFocusHandler;
            };
            var uploader{{ id }} = new qq.FineUploader({
                element: document.getElementById('fine-uploader-{{ id }}'),
                request: {
                    endpoint: "{{ oneup_uploader_endpoint('medias') }}"
                },
                session: {
                    endpoint: "{{ path('donjohn_media_init_fine_uploader') }}"
                },
                template: 'donjohn-media',
                chunking: {
                    enabled: true,
                    partSize: {{ form.vars.chunkSize }}
                },
                deleteFile: {
                    enabled: true,
                    endpoint: "{{ path('donjohn_media_cancel_fine_uploader') }}"
                },
                callbacks: {
                    onSubmitDelete: function(id) {
                        this.setDeleteFileParams({filename: this.getName(id)}, id);
                    }
                },
                thumbnails: {
                    placeholders: {
                        notAvailablePath: '{{ asset('bundles/donjohnmedia/images/iconmonstr-file-20-72.png') }}',
                        waitingPath: '{{ asset('bundles/donjohnmedia/images/iconmonstr-file-20-72.png') }}',<commit_msg>best loading order<commit_after>{% block media_fine_uploader_widget %}
    {{ form_widget(form) }}

<div id="fine-uploader-{{ id }}"></div>
<div id="alert-{{ id }}"></div>

    <script type="text/javascript">
        window.addEventListener('load', function() {
            qq.uiPrivateApi._isEditFilenameEnabled = function(){
                return this._templating.isEditFilenamePossible() && qq.FilenameClickHandler && qq.FilenameInputFocusHandler && qq.FilenameInputFocusHandler;
            };
            var uploader{{ id }} = new qq.FineUploader({
                element: document.getElementById('fine-uploader-{{ id }}'),
                request: {
                    endpoint: "{{ oneup_uploader_endpoint('medias') }}"
                },
                session: {
                    endpoint: "{{ path('donjohn_media_init_fine_uploader') }}"
                },
                template: 'donjohn-media',
                chunking: {
                    enabled: true,
                    partSize: {{ form.vars.chunkSize }}
                },
                deleteFile: {
                    enabled: true,
                    endpoint: "{{ path('donjohn_media_cancel_fine_uploader') }}"
                },
                callbacks: {
                    onSubmitDelete: function(id) {
                        this.setDeleteFileParams({filename: this.getName(id)}, id);
                    }
                },
                thumbnails: {
                    placeholders: {
                        notAvailablePath: '{{ asset('bundles/donjohnmedia/images/iconmonstr-file-20-72.png') }}',
                        waitingPath: '{{ asset('bundles/donjohnmedia/images/iconmonstr-file-20-72.png') }}',
{'fraction_non_alphanumeric': 0.1304221251819505, 'fraction_numerical': 0.004657933042212519, 'mean_word_length': 1.5776444111027756, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, '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': '11425', 'n_tokens_mistral': 941, 'n_tokens_neox': 852, 'n_words': 124}