<p>
  Similarity check has been run on <%= @run_count %> out of <%= @total_count %> scripts.
</p>

<h3>Top 100 Similarities</h3>
<table class="log-table">
  <% @top_similarities.each do |s| %>
    <tr>
      <td>
        <%= render_script(s.script) %>
      </td>
      <td>
        <%= render_script(s.other_script) %>
      </td>
      <td>
        <%= number_with_precision(s.similarity, precision: 3) %>
      </td>
      <td>
        <%= link_to 'Diff', admin_script_path(s.script, compare: script_path(s.other_script), anchor: 'script-comparison') %>
      </td>
    </tr>
  <% end %>
</table>

<p>
  <%= link_to('Prev', page: @page - 1) if @page > 0 %>
  <%= link_to('Next', page: @page + 1) %>
</p>
