<commit_before><% content_for :head do %>
  <%= javascript_include_tag 'Results/file_selector' %>
<% end %>

<%= form_tag(download_assignment_submission_result_path(
                     @assignment.id, @grouping.current_submission_used.id,
                     @grouping.current_submission_used.get_latest_result.id)) do %>
    <%= hidden_field_tag :include_annotations,
                         true,
                         id: 'download_include_annotations' %>
  <div class='file_selector'>
    <input type='button'
           onclick='bump_select("select_file_id", -1, "back_button", "next_button"); return false;'
           value='←'
           id='back_button'
           disabled>
    <select id='select_file_id'
            name='select_file_id'
            onchange='bump_select("select_file_id", 0, "back_button", "next_button");'>
      <% if files.empty? %>
        <option value=''><%= t('common.no_file_in_repository') %></option>
      <% end %>
      <% files.each do |file| %>
        <option value='<%= file.id %>'>
          <%= File.join(file.path, file.filename) %>
        </option>
      <% end %>
    </select>
    <input type='button'
           onclick='bump_select("select_file_id", 1, "back_button", "next_button"); return false;'
           value='→'
           id='next_button'>
  </div>

  <div class='download_file'>
    
    <%= submit_tag t(:download), onclick: 'with_annotations();' if can_download && !files.empty? %>

    <%= label_tag('include_annotations',
                  t('marker.include_annotations'),
                  class: 'inline_label') if can_download && !files.empty? %>
    <%= check_box_tag('include_annotations',
                      true,
                      false,
                      id: 'include_annotations',
                      class: 'inline_checkbox') if can_download && !files.empty? %>

     <%= submit_tag t('browse_submissions.download_all_files'), name: 'download_zip_button',
                       onclick: 'with_annotations();' unless files.empty? %>
  </div>
<% end %><commit_msg>fix #1701, indentation<commit_after><% content_for :head do %>
  <%= javascript_include_tag 'Results/file_selector' %>
<% end %>

<%= form_tag(download_assignment_submission_result_path(
                     @assignment.id, @grouping.current_submission_used.id,
                     @grouping.current_submission_used.get_latest_result.id)) do %>
  <%= hidden_field_tag :include_annotations,
                       true,
                       id: 'download_include_annotations' %>
  <div class='file_selector'>
    <input type='button'
           onclick='bump_select("select_file_id", -1, "back_button", "next_button"); return false;'
           value='←'
           id='back_button'
           disabled>
    <select id='select_file_id'
            name='select_file_id'
            onchange='bump_select("select_file_id", 0, "back_button", "next_button");'>
      <% if files.empty? %>
        <option value=''><%= t('common.no_file_in_repository') %></option>
      <% end %>
      <% files.each do |file| %>
        <option value='<%= file.id %>'>
          <%= File.join(file.path, file.filename) %>
        </option>
      <% end %>
    </select>
    <input type='button'
           onclick='bump_select("select_file_id", 1, "back_button", "next_button"); return false;'
           value='→'
           id='next_button'>
  </div>

  <div class='download_file'>
    
    <%= submit_tag t(:download), onclick: 'with_annotations();' if can_download && !files.empty? %>

    <%= label_tag('include_annotations',
                  t('marker.include_annotations'),
                  class: 'inline_label') if can_download && !files.empty? %>
    <%= check_box_tag('include_annotations',
                      true,
                      false,
                      id: 'include_annotations',
                      class: 'inline_checkbox') if can_download && !files.empty? %>

    <%= submit_tag t('browse_submissions.download_all_files'),
                   name: 'download_zip_button',
                   onclick: 'with_annotations();' unless files.empty? %>
  </div>
<% end %>
{'fraction_non_alphanumeric': 0.14965001206854936, 'fraction_numerical': 0.0024137098720733766, 'mean_word_length': 2.3446327683615817, 'pattern_counts': {'":': 0, '<': 61, '<?xml version=': 0, '>': 61, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 18, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3947351', 'n_tokens_mistral': 1301, 'n_tokens_neox': 1202, 'n_words': 206}