X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/308a6da1a9fd716f3957b116110a932c08aefafe..8deda2012ea7e25610f2cbd0a271e131d9364503:/apps/workbench/app/views/collections/_show_files.html.erb diff --git a/apps/workbench/app/views/collections/_show_files.html.erb b/apps/workbench/app/views/collections/_show_files.html.erb index 5b6dac81ed..76d8731a93 100644 --- a/apps/workbench/app/views/collections/_show_files.html.erb +++ b/apps/workbench/app/views/collections/_show_files.html.erb @@ -19,7 +19,18 @@ function unselect_all_files() { } -
+<% + preview_selectable_container = '' + preview_selectable = '' + padding_left = '1em' + if !params['use_preview_selection'].nil? and params['use_preview_selection'] == 'true' + preview_selectable_container = 'preview-selectable-container selectable-container' + preview_selectable = 'preview-selectable selectable' + padding_left = '0em' + end +%> + +
<% if !defined? no_checkboxes or !no_checkboxes %>
@@ -53,7 +64,7 @@ function unselect_all_files() { <% if file_tree.nil? or file_tree.empty? %>

This collection is empty.

<% else %> -
    +
      <% dirstack = [file_tree.first.first] %> <% file_tree.take(10000).each_with_index do |(dirname, filename, size), index| %> <% file_path = CollectionsHelper::file_path([dirname, filename]) %> @@ -64,13 +75,13 @@ function unselect_all_files() { <% if size.nil? # This is a subdirectory. %> <% dirstack.push(File.join(dirname, filename)) %>
      -
      <%= filename %>
      +
      <%= filename %>
        <% else %> <% link_params = {controller: 'collections', action: 'show_file', uuid: @object.portable_data_hash, file: file_path, size: size} %> -
        +
        <%= raw(human_readable_bytes_html(size)) %> <% disable_search = (Rails.configuration.filename_suffixes_with_view_icon.include? file_path.split('.')[-1]) ? false : true %> @@ -85,7 +96,7 @@ function unselect_all_files() {
        <% if !defined? no_checkboxes or !no_checkboxes %> <%= check_box_tag 'uuids[]', "#{@object.uuid}/#{file_path}", false, { - :class => 'persistent-selection', + :class => "persistent-selection", :friendly_type => "File", :friendly_name => "#{@object.uuid}/#{file_path}", :href => url_for(controller: 'collections', action: 'show_file', @@ -103,7 +114,7 @@ function unselect_all_files() { {title: file_path}) %>
        <% else %> - <%= filename %>
        + <%= filename %>
        <% end %>