Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions apps/dashboard/app/views/files/_breadcrumb.html.erb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<% if file_counter == 0 %>
<li class="breadcrumb-item">
<a href="<%= files_path(@filesystem, full_path.parent) %>" class="d btn btn-outline-dark btn-sm me-3" title="Go up directory">
<a href="<%= files_path(@filesystem, full_path.parent) %>" class="d btn btn-outline-dark btn-sm me-3" title="<%= t('dashboard.files_go_up_directory')%>">
<span class="fa fa-arrow-up"></span></a>
</li>
<% end %>
Expand All @@ -10,10 +10,10 @@
<%= path_segment_with_slash(@filesystem, file.basename.to_s, file_counter, file_count) %>
</li>
<li class="breadcrumb-item ms-3">
<button id="goto-btn" type="button" class="btn btn-outline-dark btn-sm"><i class="fas fa-edit" aria-hidden="true"></i> Change directory</button>
<button id="goto-btn" type="button" class="btn btn-outline-dark btn-sm"><i class="fas fa-edit" aria-hidden="true"></i> <%= t('dashboard.files_change_directory')%></button>
</li>
<li class="breadcrumb-item ms-auto">
<button id="copy-path" class="btn btn-outline-dark btn-sm " data-clipboard-text="<%= file.to_s %>"><span class="fa fa-clipboard"></span> Copy path</button>
<button id="copy-path" class="btn btn-outline-dark btn-sm " data-clipboard-text="<%= file.to_s %>"><span class="fa fa-clipboard"></span> <%= t('dashboard.files_copy_path')%></button>
</li>
<% else %>
<li class="breadcrumb-item">
Expand Down
2 changes: 1 addition & 1 deletion apps/dashboard/app/views/files/_download_button.html.erb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<%- if Configuration.download_enabled? -%>
<button id="download-btn" type="button" class="btn btn-primary btn-sm">
<i class="fas fa-download" aria-hidden="true"></i> Download
<i class="fas fa-download" aria-hidden="true"></i> <%= t('dashboard.download') %>
</button>
<%- end -%>
20 changes: 10 additions & 10 deletions apps/dashboard/app/views/files/_files_table.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,22 @@
</ol>

<div role="region" aria-label="Directory contents">
<span id="select_all_label" class="sr-only">Select All</span>
<span id="select_all_label" class="sr-only"><%= t('dashboard.files_select_all') %></span>
<table class="table table-striped table-condensed w-100" id="directory-contents">
<caption id="directory-contents_caption" class="sr-only" aria-live='polite'> <%= "Contents of directory #{@path}" %> </caption>
<caption id="directory-contents_caption" class="sr-only" aria-live='polite'><%= t('dashboard.files_contents_of_directory', path: @path) %></caption>
<thead>
<tr>
<th>
<input type="checkbox" id="select_all" class="file-select" aria-labelledby="select_all_label"></input>
<span class="sr-only">Select</span>
<span class="sr-only"><%= t('dashboard.select') %></span>
</th>
<th>Type</th>
<th>Name</th>
<th><span class="sr-only">Actions</span></th>
<th>Size</th>
<th>Modified at</th>
<th>Owner</th>
<th>Mode</th>
<th><%= t('dashboard.type') %></th>
<th><%= t('dashboard.name') %></th>
<th><span class="sr-only"><%= t('dashboard.actions') %></span></th>
<th><%= t('dashboard.size') %></th>
<th><%= t('dashboard.files_modified_at') %></th>
<th><%= t('dashboard.owner') %></th>
<th><%= t('dashboard.mode') %></th>
</tr>
</thead>
<tbody>
Expand Down
2 changes: 1 addition & 1 deletion apps/dashboard/app/views/files/_spinner.html.erb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<div class="text-center text-primary d-none p-5" id="tloading_spinner">
<div class="spinner-border">
<span class="sr-only">Loading...</span>
<span class="sr-only"><%= t('dashboard.loading') %></span>
</div>
</div>
2 changes: 1 addition & 1 deletion apps/dashboard/app/views/files/_upload_button.html.erb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<%- if Configuration.upload_enabled? -%>
<button id="upload-btn" type="button" class="btn btn-primary btn-sm">
<i class="fas fa-upload" aria-hidden="true"></i> Upload
<i class="fas fa-upload" aria-hidden="true"></i> <%= t('dashboard.upload') %>
</button>
<%- end -%>
18 changes: 9 additions & 9 deletions apps/dashboard/app/views/files/edit.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -8,23 +8,23 @@
<div class="d-grid gap-2">
<button class="btn btn-primary" id="save-button">
<i class="fas fa-save pe-2" aria-hidden="true"></i>
<span>Save</span>
<span><%= t('dashboard.save') %></span>
</button>
</div>
</div>


<ul class="list-group list-group-flush border-bottom-0">
<li class="list-group-item hidden-xs hidden-sm hidden-md px-2 form-group form-inline m-0">
<label class="control-label navbar-text px-1" for="keybindings">Key Bindings</label>
<label class="control-label navbar-text px-1" for="keybindings"><%= t('dashboard.editor_key_bindings') %></label>
<select class="form-control input-xs" id="keybindings">
<option value="default">Default</option>
<option value="default"><%= t('dashboard.editor_key_bindings_default') %></option>
<option value="ace/keyboard/vim">Vim</option>
<option value="ace/keyboard/emacs">Emacs</option>
</select>
</li>
<li class="list-group-item hidden-xs px-2 form-group form-inline m-0">
<label class="control-label hidden-sm hidden-md navbar-text px-1" for="fontsize">Font Size</label>
<label class="control-label hidden-sm hidden-md navbar-text px-1" for="fontsize"><%= t('dashboard.editor_font_size') %></label>
<select class="form-control input-xs" id="fontsize">
<option value="8px">8px</option>
<option value="9px">9px</option>
Expand All @@ -46,7 +46,7 @@
</select>
</li>
<li class="list-group-item hidden-xs px-2 form-group form-inline m-0">
<label class="control-label hidden-sm hidden-md navbar-text px-1" for="mode">Mode</label>
<label class="control-label hidden-sm hidden-md navbar-text px-1" for="mode"><%= t('dashboard.mode') %></label>
<select class="form-control input-xs" id="mode">
<option value="abap">ABAP</option>
<option value="abc">ABC</option>
Expand Down Expand Up @@ -181,9 +181,9 @@
</select>
</li>
<li class="list-group-item hidden-xs px-2 form-group form-inline px-1 m-0">
<label class="control-label hidden-sm hidden-md px-1 navbar-text" for="theme">Theme</label>
<label class="control-label hidden-sm hidden-md px-1 navbar-text" for="theme"><%= t('dashboard.theme') %></label>
<select class="form-control input-xs" id="theme">
<optgroup label="Bright">
<optgroup label="<%= t('dashboard.bright') %>">
<option value="ace/theme/chrome">Chrome</option>
<option value="ace/theme/clouds">Clouds</option>
<option value="ace/theme/crimson_editor">Crimson Editor</option>
Expand All @@ -200,7 +200,7 @@
<option value="ace/theme/katzenmilch">KatzenMilch</option>
<option value="ace/theme/sqlserver">SQL Server</option>
</optgroup>
<optgroup label="Dark">
<optgroup label="<%= t('dashboard.dark') %>">
<option value="ace/theme/ambiance">Ambiance</option>
<option value="ace/theme/chaos">Chaos</option>
<option value="ace/theme/clouds_midnight">Clouds Midnight</option>
Expand All @@ -224,7 +224,7 @@
</select>
</li>
<li class="list-group-item hidden-xs px-2 form-group form-inline m-0">
<label class="control-label hidden-md hidden-lg navbar-text px-1" for="wordwrap">Wrap</label>
<label class="control-label hidden-md hidden-lg navbar-text px-1" for="wordwrap"><%= t('dashboard.wrap') %></label>
<div class="form-switch">
<input class="form-check-input" role="switch" type="checkbox" id="wordwrap" value="">
</div>
Expand Down
10 changes: 5 additions & 5 deletions apps/dashboard/app/views/files/index.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
<%= render partial: 'shell_dropdown' %>
<% end %>

<button id="refresh-btn" type="button" class="btn btn-outline-dark btn-sm"><i class="fa fa-rotate-right" aria-hidden="true"></i> Refresh</button>
<button id="new-file-btn" type="button" class="btn btn-outline-dark btn-sm"><i class="fas fa-plus" aria-hidden="true"></i> New File</button>
<button id="new-dir-btn" type="button" class="btn btn-outline-dark btn-sm"><i class="fas fa-folder-plus" aria-hidden="true"></i> New Directory</button>
<button id="refresh-btn" type="button" class="btn btn-outline-dark btn-sm"><i class="fa fa-rotate-right" aria-hidden="true"></i> <%= t('dashboard.files_refresh') %></button>
<button id="new-file-btn" type="button" class="btn btn-outline-dark btn-sm"><i class="fas fa-plus" aria-hidden="true"></i> <%= t('dashboard.files_new_file') %></button>
<button id="new-dir-btn" type="button" class="btn btn-outline-dark btn-sm"><i class="fas fa-folder-plus" aria-hidden="true"></i> <%= t('dashboard.files_new_directory') %></button>
<%= render(partial: 'upload_button') %>
<%= render(partial: 'download_button') %>
<% if Configuration.globus_endpoints %>
Expand All @@ -18,8 +18,8 @@
<% if @user_configuration.files_select_target %>
<%= render partial: 'send_to_target_button' %>
<% end %>
<button id="copy-move-btn" type="button" class="btn btn-outline-dark btn-sm"><i class="fas fa-copy" aria-hidden="true"></i> Copy/Move</button>
<button id="delete-btn" type="button" class="btn btn-danger btn-sm"><i class="fas fa-trash" aria-hidden="true"></i> Delete</button>
<button id="copy-move-btn" type="button" class="btn btn-outline-dark btn-sm"><i class="fas fa-copy" aria-hidden="true"></i> <%= t('dashboard.files_copy_move') %></button>
<button id="delete-btn" type="button" class="btn btn-danger btn-sm"><i class="fas fa-trash" aria-hidden="true"></i> <%= t('dashboard.files_delete') %></button>
</div>

<hr>
Expand Down
18 changes: 9 additions & 9 deletions apps/dashboard/app/views/files/turbo_frames/_directory.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,18 @@
<table class="table table-striped table-condensed w-100 table-hover caption-right">
<thead>
<tr>
<th><span class="sr-only">Type</span></th>
<th>Name</th>
<th><span class="sr-only">Actions</span></th>
<th><span class="sr-only"><%= t('dashboard.type') %></span></th>
<th><%= t('dashboard.name') %></th>
<th><span class="sr-only"><%= t('dashboard.actions') %></span></th>
<% private_dir = path.to_s.start_with?(CurrentUser.home) %>
<% if private_dir %>
<th>Size</th>
<th>Date</th>
<th><%= t('dashboard.size') %></th>
<th><%= t('dashboard.date') %></th>
<% else %>
<th class='d-above-xl'>Size</th>
<th class='d-above-xl'>Date</th>
<th>Owner</th>
<th>Mode</th>
<th class='d-above-xl'><%= t('dashboard.size') %></th>
<th class='d-above-xl'><%= t('dashboard.date') %></th>
<th><%= t('dashboard.owner') %></th>
<th><%= t('dashboard.mode') %></th>
<% end %>
</tr>
</thead>
Expand Down
12 changes: 7 additions & 5 deletions apps/dashboard/app/views/files/turbo_frames/_files.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
<% dir_type = I18n.t('dashboard.directory') %>
<i class="fa fa-folder" title="<%= dir_type %>">
<span class="sr-only"> <%= dir_type %> </span>
</i>
</td>
<td>
<strong>
Expand All @@ -11,7 +12,7 @@
directory_frame_path(
path: "#{path.parent}"
),
title: 'Show parent directory',
title: t('dashboard.files_show_parent_directory'),
data: { turbo_frame: "project_directory" }
)
%>
Expand All @@ -34,6 +35,7 @@
<% type = I18n.t("dashboard.#{file[:directory] ? 'directory' : 'file'}") %>
<i class="fa fa-<%= file[:directory] ? 'folder' : 'file' %>" title="<%= type %>">
<span class="sr-only"> <%= type %> </span>
</i>
</td>
<%- if file[:directory] && readable-%>
<td>
Expand All @@ -42,7 +44,7 @@
directory_frame_path(
path: full_path
),
title: "Show #{file[:name]} directory",
title: t('dashboard.files_show_directory', name: file[:name]),
data: { turbo_frame: "project_directory" }
)
%>
Expand Down Expand Up @@ -75,7 +77,7 @@
class: 'view-file dropdown-item',
data: { row_index: nil } do %>
<i class="fas fa-eye" aria-hidden="true"></i>
View
<%= t('dashboard.view') %>
<% end %>
</li>
<% if writable %>
Expand All @@ -84,7 +86,7 @@
target: '_top',
class: 'edit-file dropdown-item' do %>
<i class="fas fa-edit" aria-hidden="true"></i>
Edit
<%= t('dashboard.edit') %>
<% end %>
</li>
<% end %>
Expand All @@ -93,7 +95,7 @@
target: '_top',
class: 'download-file dropdown-item' do %>
<i class="fas fa-download" aria-hidden="true"></i>
Download
<%= t('dashboard.download') %>
<% end %>
</li>
</ul>
Expand Down
30 changes: 30 additions & 0 deletions apps/dashboard/config/locales/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -142,24 +142,47 @@ en:
development_apps_caption: Sandbox App
directory: Directory
edit: Edit
editor: Editor
editor_font_size: Font Size
theme: Theme
bright: Bright
dark: Dark
wrap: Wrap
editor_key_bindings: Key Bindings
editor_key_bindings_default: Default
files_select_all: Select All
select: Select
files_modified_at: Modified at
loading: Loading...
file: File
file_quotas: File Quotas
files_change_directory: Change Directory
files_copy_path: Copy Path
files_copy_move: Copy/Move
files_delete: Delete
files_directory_download_error_modal_title: Directory too large to download
files_directory_download_unauthorized: You can only download a file or directory that you have read and execute access to
files_directory_size_calculation_error: Timeout while trying to determine directory size.
files_directory_size_calculation_timeout: Timeout while trying to determine directory size.
files_directory_size_unknown: 'Error with status %{exit_code} when trying to determine directory size: %{error}'
files_directory_too_large: The directory is too large to download as a zip. The directory should be less than %{download_directory_size_limit} bytes.
files_download: Download
files_download_not_enabled: Downloading files is not enabled on this server.
files_download_zip: Download as zip
files_file_too_large: The file is too large to download. File downloads should be less than %{download_file_size_limit} bytes.
files_go_up_directory: Go up directory
files_new_directory: New Directory
files_new_file: New File
files_refresh: Refresh
files_remote_dir_not_created: Did not create directory %{path}
files_remote_disabled: Remote file support is not enabled
files_remote_empty_dir_unsupported: Remote does not support empty directories
files_remote_error_listing_remotes: 'Error listing Rclone remotes: %{error}'
files_upload: Upload
files_send_to_target_title_default: Send selected files metadata to the external application
files_shell: Open in Terminal
files_shell_dropdown: Select Cluster to Open in Terminal
save: Save
files_doesnt_exist: "%{path} does not exist."
files_not_readable: "You do not have sufficient permissions to read '%{path}'."
home_directory: Home Directory
Expand Down Expand Up @@ -319,6 +342,9 @@ en:
<br>Custom shared apps are available below.
shell_app_title: "%{cluster_title} Shell Access"
show: Show
files_contents_of_directory: "Contents of directory %{path}"
files_show_directory: Show %{name} directory
files_show_parent_directory: Show parent directory
size: Size
skip_navigation: Skip Navigation
soft_tabs: Soft Tabs
Expand Down Expand Up @@ -346,6 +372,10 @@ en:
validation_error: Invalid Request. Please review the error messages below
system_apps_caption: System Installed App
type: Type
actions: Actions
download: Download
upload: Upload
view: View
unknown: Unknown
uppy: Uppy
user_configuration:
Expand Down
Loading
Loading