Skip to content

Localized dashboard/files page (#1960)#5359

Open
SimonX1a0 wants to merge 14 commits into
masterfrom
localization-1960
Open

Localized dashboard/files page (#1960)#5359
SimonX1a0 wants to merge 14 commits into
masterfrom
localization-1960

Conversation

@SimonX1a0
Copy link
Copy Markdown

Replaced hard coded English texts with i18n keys in app/views/files files used for /dashboard/files path.

Replace hard coded english labels with i18n keys for buttons like
refresh, new files, new directory, copy/move, and delete
Add English and zh-CN strings
<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.files_turboframe.type') %></span></th>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Simple/single works like Type should be just simple/single word keys like dashboard.type. That promotes reuse and also simplicity.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you added this file by accident. Furthermore, if this is a development config - you should be using a directory outside of the git tree. Mostly for this exact reason - so you don't accidentally commit it.

SimonX1a0 and others added 5 commits April 24, 2026 13:10
* localize active_jobs/index.html.erb

* localize active_jobs/_job_details_node_view.html.erb

* localize active_jobs/extended_data_table.html.erb

---------

Co-authored-by: Braeden Singleton <bsingleton@osc.edu>
<%= link_to image_tag( build_ganglia_link(data.cluster, data.starttime, 'load_report', node, 'small'), class:"img-responsive col-lg-auto col-md-auto col-sm-auto col-xs-auto", alt: "Ganglia image for system load averages." ), build_ganglia_link(data.cluster, data.starttime, 'load_report', node, 'large'), data: { lightbox: "load-report", title: "Load Report " + node } %>
<%= link_to image_tag( build_ganglia_link(data.cluster, data.starttime, 'mem_report', node, 'small'), class:"img-responsive col-lg-auto col-md-auto col-sm-auto col-xs-auto", alt: "Ganglia image for Memory usage." ), build_ganglia_link(data.cluster, data.starttime, 'mem_report', node, 'large'), data: { lightbox: "mem-report", title: "Memory Report " + node } %>
<%= link_to image_tag( build_ganglia_link(data.cluster, data.starttime, 'network_report', node, 'small'), class:"img-responsive col-lg-auto col-md-auto col-sm-auto col-xs-auto", alt: "Ganglia image for network usage." ), build_ganglia_link(data.cluster, data.starttime, 'network_report', node, 'large'), data: { lightbox: "network-report", title: "Network Report " + node } %>
<%= link_to image_tag( build_ganglia_link(data.cluster, data.starttime, 'cpu_report', node, 'small'), class:"img-responsive col-lg-auto col-md-auto col-sm-auto col-xs-auto", alt: t('dashboard.active_jobs_ganglia_alt_cpu')), build_ganglia_link(data.cluster, data.starttime, 'cpu_report', node, 'large'), data: { lightbox: "cpu-report", title: "#{t('dashboard.cpu_report')} #{node}" } %>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's pass the node info to the localization in case the order changes for other languages

@Bubballoo3
Copy link
Copy Markdown
Contributor

Somehow #5363 was added here as an additional commit instead of merging with master. In your terminal, switch to the localization-1960 branch and run git pull origin master to do a manual merge and resolve the conflicts

Comment thread apps/dashboard/config/locales/zh-CN.yml Outdated
batch_connect_form_type_new_name_error: 请输入一个有效的名称以继续
batch_connect_invalid_form_array: "'form' 元素在 form.yml 中不是数组"
batch_connect_invalid_form_attributes: "'attributes' 元素在 form.yml 中不是映射"
batch_connect_invalid_form_array: '''form'' 元素在 form.yml 中不是数组'
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These quotes are going to cause issues. I already corrected them in en.yml as part of #5363, but this demonstrates the difficulty of keeping all of this straight when we are editing multiple locale files. If these are your original translations then I think there is value there compared to the AI workflow, and you just need to review it to ensure it is up to date with the formatting of en.yml. It still may be easier however to just revert this file, let the weekly automation generate the new translations, and then open a PR to update anything you think can be improved.

@Bubballoo3 Bubballoo3 moved this from Awaiting Review to Changes Requested in PR Review Pipeline May 8, 2026
Bubballoo3
Bubballoo3 previously approved these changes May 19, 2026
Copy link
Copy Markdown
Contributor

@Bubballoo3 Bubballoo3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

@Bubballoo3
Copy link
Copy Markdown
Contributor

Not quite sure how to proceed with this due to the fact that it duplicates changes from #5363 and #5439. I attempted removing those commits via rebase, but the subsequent ones then fail merge conflicts because they occur before the merge with master. The end state seems fine, maybe I am overreacting and the duplication won't cause problems? Alternatively I can maybe just squash these changes together within the branch, so we generate a single commit between current master and the proposed changes. @johrstrom any advice?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Changes Requested

Development

Successfully merging this pull request may close these issues.

4 participants