From 991235c47e4c9b88c7588374f756ff129f6534de Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Tue, 20 May 2025 14:35:08 -0400 Subject: [PATCH 01/33] run 115r .dassie/app/views/ --- .dassie/app/views/layouts/application.html.erb | 2 +- .dassie/app/views/shared/_footer.html.erb | 2 +- .dassie/config/locales/hyrax.en.yml | 6 ++++++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.dassie/app/views/layouts/application.html.erb b/.dassie/app/views/layouts/application.html.erb index e6484af976..abf0e46fbe 100644 --- a/.dassie/app/views/layouts/application.html.erb +++ b/.dassie/app/views/layouts/application.html.erb @@ -1,7 +1,7 @@ - Dassie + <%= I18n.t("layouts.application.dassie", :default => "Dassie") %> <%= csrf_meta_tags %> <%= csp_meta_tag %> diff --git a/.dassie/app/views/shared/_footer.html.erb b/.dassie/app/views/shared/_footer.html.erb index 3afef0e559..1057c674ef 100644 --- a/.dassie/app/views/shared/_footer.html.erb +++ b/.dassie/app/views/shared/_footer.html.erb @@ -4,7 +4,7 @@

<%= t('hyrax.footer.service_html') %> <%= t('hyrax.product_name') %> v<%= Hyrax::VERSION %>

Commit <%= link_to ENV.fetch('BUILD_GITSHA', "Unknown")[0..6], "https://github.com/samvera/hyrax/commit/#{ENV.fetch('BUILD_GITSHA', 'main')}" %> - Built at <%= ENV.fetch('BUILD_TIMESTAMP', 'Unknown') %> + <%= I18n.t("shared.footer.built_at", :default => "Built at ") %><%= ENV.fetch('BUILD_TIMESTAMP', 'Unknown') %>

diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 56ebe17c09..c220c27adf 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -1903,3 +1903,7 @@ en: total_view: one: This work has 1 total view other: This work has %{count} total views + catalog: + edit_partials: + default_details: + title: "Title:" From 2024317a90e49a9be094c1a7bf37313f3a033e70 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 13:23:25 -0400 Subject: [PATCH 04/33] i15r app/views/hyrax/admin/admin_sets --- .../admin_sets/_form_participants.html.erb | 8 +++---- .../admin_sets/_show_document_list.html.erb | 12 +++++------ .../_show_document_list_row.html.erb | 10 ++++----- .../hyrax/admin/admin_sets/index.html.erb | 11 +++++----- config/locales/hyrax.en.yml | 21 +++++++++++++++++++ 5 files changed, 42 insertions(+), 20 deletions(-) diff --git a/app/views/hyrax/admin/admin_sets/_form_participants.html.erb b/app/views/hyrax/admin/admin_sets/_form_participants.html.erb index b146263e82..679c4789da 100644 --- a/app/views/hyrax/admin/admin_sets/_form_participants.html.erb +++ b/app/views/hyrax/admin/admin_sets/_form_participants.html.erb @@ -20,9 +20,9 @@ class: 'form-control' %>
- + <%= builder.select :access, - access_options, + <%= I18n.t("hyrax.admin.admin_sets.form_participants.access_options", :default => "access_options,") %> { prompt: "Select a role..." }, class: 'form-control' %>
@@ -47,9 +47,9 @@ placeholder: "Search for a user..." %>
- + <%= builder.select :access, - access_options, + <%= I18n.t("hyrax.admin.admin_sets.form_participants.access_options", :default => "access_options,") %> { prompt: "Select a role..." }, class: 'form-control' %>
diff --git a/app/views/hyrax/admin/admin_sets/_show_document_list.html.erb b/app/views/hyrax/admin/admin_sets/_show_document_list.html.erb index ee7aaaf268..4d2efb2b1a 100644 --- a/app/views/hyrax/admin/admin_sets/_show_document_list.html.erb +++ b/app/views/hyrax/admin/admin_sets/_show_document_list.html.erb @@ -1,13 +1,13 @@ - + - - - - - + + + + + diff --git a/app/views/hyrax/admin/admin_sets/_show_document_list_row.html.erb b/app/views/hyrax/admin/admin_sets/_show_document_list_row.html.erb index 583b2404f7..74e358e405 100644 --- a/app/views/hyrax/admin/admin_sets/_show_document_list_row.html.erb +++ b/app/views/hyrax/admin/admin_sets/_show_document_list_row.html.erb @@ -34,17 +34,17 @@ diff --git a/app/views/hyrax/admin/admin_sets/index.html.erb b/app/views/hyrax/admin/admin_sets/index.html.erb index b5c45c07fd..0cc0d3cb7d 100644 --- a/app/views/hyrax/admin/admin_sets/index.html.erb +++ b/app/views/hyrax/admin/admin_sets/index.html.erb @@ -14,12 +14,13 @@ <% if @admin_sets.present? %>
List of items in this administrative set<%= I18n.t("hyrax.admin.admin_sets.show_document_list.list_of_items_in_this_administrative_set", :default => "List of items in this administrative set") %>
 TitleDate UploadedVisibilityStatusActions<%= I18n.t("hyrax.admin.admin_sets.show_document_list.title", :default => "Title") %><%= I18n.t("hyrax.admin.admin_sets.show_document_list.date_uploaded", :default => "Date Uploaded") %><%= I18n.t("hyrax.admin.admin_sets.show_document_list.visibility", :default => "Visibility") %><%= I18n.t("hyrax.admin.admin_sets.show_document_list.status", :default => "Status") %><%= I18n.t("hyrax.admin.admin_sets.show_document_list.actions", :default => "Actions") %>
-
Creator:
+
<%= I18n.t("hyrax.admin.admin_sets.show_document_list_row.creator", :default => "Creator:") %>
<%= document.creator.to_a.to_sentence %>
-
Depositor:
+
<%= I18n.t("hyrax.admin.admin_sets.show_document_list_row.depositor", :default => "Depositor:") %>
<%= link_to_profile document.depositor %>
-
Edit Access:
+
<%= I18n.t("hyrax.admin.admin_sets.show_document_list_row.edit_access", :default => "Edit Access:") %>
<% if document.edit_groups.present? %> - Groups: <%= document.edit_groups.join(', ') %> + <%= I18n.t("hyrax.admin.admin_sets.show_document_list_row.groups", :default => "Groups: ") %><%= document.edit_groups.join(', ') %>
<% end %> - Users: <%= document.edit_people.join(', ') %> + <%= I18n.t("hyrax.admin.admin_sets.show_document_list_row.users", :default => "Users: ") %><%= document.edit_people.join(', ') %>
+ - - - - + + + + @@ -35,7 +36,7 @@
TitleDate createdCreatorWorks<%= I18n.t("hyrax.admin.admin_sets.index.title", :default => "Title") %><%= I18n.t("hyrax.admin.admin_sets.index.date_created", :default => "Date created") %><%= I18n.t("hyrax.admin.admin_sets.index.creator", :default => "Creator") %><%= I18n.t("hyrax.admin.admin_sets.index.works", :default => "Works") %>
<% else %> -

No administrative sets have been created.

+

<%= I18n.t("hyrax.admin.admin_sets.index.no_administrative_sets_have_been_created", :default => "No administrative sets have been created.") %>

<% end %> diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index c220c27adf..8e2a22ffda 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -149,6 +149,8 @@ en: add_participants: Add Participants add_user: 'Add user:' current_participants: Current Participants + as: 'as' + access_options: 'access_options,' form_visibility: cancel: Cancel page_description: Release and visibility settings determine the options available to depositors when submitting a work to this administrative set. Changes to these settings do not affect previously deposited works. @@ -187,6 +189,25 @@ en: item_list_header: Works in This Set show_actions: confirm_delete: Are you sure you wish to delete this Administrative Set? This action cannot be undone. + show_document_list: + list_of_items_in_this_administrative_set: 'List of items in this administrative set' + title: 'Title' + date_uploaded: 'Date Uploaded' + visibility: 'Visibility' + status: 'Status' + actions: 'Actions' + show_document_list_row: + creator: 'Creator:' + depositor: 'Depositor:' + edit_access: 'Edit Access:' + groups: 'Groups: ' + users: 'Users: ' + index: + title: 'Title' + date_created: 'Date created' + creator: 'Creator' + works: 'Works' + no_administrative_sets_have_been_created: 'No administrative sets have been created.' analytics: collection_reports: custom_range: From 316da261fa49f71963da94b8a6f46a68b78a220b Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 13:24:38 -0400 Subject: [PATCH 05/33] normalize last commit --- config/locales/hyrax.en.yml | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 8e2a22ffda..85e416de9c 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -31,6 +31,10 @@ en: filters: title: 'Filtering by:' start_over: Start Over + catalog: + edit_partials: + default_details: + title: 'Title:' download: one: and 1 download other: and %{count} downloads @@ -145,12 +149,12 @@ en: title: Viewers type: Type form_participants: + access_options: access_options, add_group: 'Add group:' add_participants: Add Participants add_user: 'Add user:' + as: as current_participants: Current Participants - as: 'as' - access_options: 'access_options,' form_visibility: cancel: Cancel page_description: Release and visibility settings determine the options available to depositors when submitting a work to this administrative set. Changes to these settings do not affect previously deposited works. @@ -181,6 +185,12 @@ en: cancel: Cancel no_workflows: There are no workflows to select. page_description: Each administrative set has a workflow associated with it. This workflow is applied to all works added to the administrative set. Select the workflow to be used for this administrative set below. + index: + creator: Creator + date_created: Date created + no_administrative_sets_have_been_created: No administrative sets have been created. + title: Title + works: Works new: header: Create New Administrative Set show: @@ -190,24 +200,18 @@ en: show_actions: confirm_delete: Are you sure you wish to delete this Administrative Set? This action cannot be undone. show_document_list: - list_of_items_in_this_administrative_set: 'List of items in this administrative set' - title: 'Title' - date_uploaded: 'Date Uploaded' - visibility: 'Visibility' - status: 'Status' - actions: 'Actions' + actions: Actions + date_uploaded: Date Uploaded + list_of_items_in_this_administrative_set: List of items in this administrative set + status: Status + title: Title + visibility: Visibility show_document_list_row: creator: 'Creator:' depositor: 'Depositor:' edit_access: 'Edit Access:' groups: 'Groups: ' users: 'Users: ' - index: - title: 'Title' - date_created: 'Date created' - creator: 'Creator' - works: 'Works' - no_administrative_sets_have_been_created: 'No administrative sets have been created.' analytics: collection_reports: custom_range: @@ -1924,7 +1928,3 @@ en: total_view: one: This work has 1 total view other: This work has %{count} total views - catalog: - edit_partials: - default_details: - title: "Title:" From 6fd1419f0b2f1762ea30f80fef2e7b03aed1751d Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 13:39:49 -0400 Subject: [PATCH 06/33] i15r app/views/hyrax/admin/analytics --- .../hyrax/admin/analytics/work_reports/_top_works.html.erb | 2 +- config/locales/hyrax.en.yml | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/app/views/hyrax/admin/analytics/work_reports/_top_works.html.erb b/app/views/hyrax/admin/analytics/work_reports/_top_works.html.erb index 5031fa77b9..fe29ed5324 100644 --- a/app/views/hyrax/admin/analytics/work_reports/_top_works.html.erb +++ b/app/views/hyrax/admin/analytics/work_reports/_top_works.html.erb @@ -12,7 +12,7 @@ <%= t('.work_title')%> - ID + <%= I18n.t("hyrax.admin.analytics.work_reports.top_works.id", :default => "ID") %> <%= t('.work_views')%> <%= t('.file_downloads')%> diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 85e416de9c..242f7da617 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -371,6 +371,7 @@ en: top_works: export: Export file_downloads: File Downloads + id: ID top_works: Top Works work_title: Work Title work_views: Work Page Views From 6a4636574c7dde1ad5f23f4053788fdbfa6d5d02 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 13:51:35 -0400 Subject: [PATCH 07/33] i15r app/views/hyrax/admin/collection_types --- .../admin/collection_types/_form_appearance.html.erb | 2 +- .../admin/collection_types/_form_participants.html.erb | 8 ++++---- .../hyrax/admin/collection_types/_form_settings.html.erb | 2 +- config/locales/hyrax.en.yml | 3 +++ 4 files changed, 9 insertions(+), 6 deletions(-) diff --git a/app/views/hyrax/admin/collection_types/_form_appearance.html.erb b/app/views/hyrax/admin/collection_types/_form_appearance.html.erb index 002a9f599d..d9fb46cade 100644 --- a/app/views/hyrax/admin/collection_types/_form_appearance.html.erb +++ b/app/views/hyrax/admin/collection_types/_form_appearance.html.erb @@ -2,4 +2,4 @@
<%= f.input :badge_color, required: false, input_html: { type: 'color' } %>
- \ No newline at end of file + diff --git a/app/views/hyrax/admin/collection_types/_form_participants.html.erb b/app/views/hyrax/admin/collection_types/_form_participants.html.erb index 2af9644103..f6dc2c6768 100644 --- a/app/views/hyrax/admin/collection_types/_form_participants.html.erb +++ b/app/views/hyrax/admin/collection_types/_form_participants.html.erb @@ -21,9 +21,9 @@ <%= f.text_field :agent_id, placeholder: "Search for a group...", class: 'form-control' %> - as + <%= I18n.t("hyrax.admin.collection_types.form_participants.as", :default => "as") %> <%= f.select :access, - access_options, + <%= I18n.t("hyrax.admin.collection_types.form_participants.access_options", :default => "access_options,") %> { prompt: "Select a role..." }, class: 'form-control' %> @@ -47,9 +47,9 @@ <%= f.hidden_field :agent_type, value: Hyrax::CollectionTypeParticipant::USER_TYPE %> <%= f.text_field :agent_id, placeholder: "Search for a user..." %> - as + <%= I18n.t("hyrax.admin.collection_types.form_participants.as", :default => "as") %> <%= f.select :access, - access_options, + <%= I18n.t("hyrax.admin.collection_types.form_participants.access_options", :default => "access_options,") %> { prompt: "Select a role..." }, class: 'form-control' %> diff --git a/app/views/hyrax/admin/collection_types/_form_settings.html.erb b/app/views/hyrax/admin/collection_types/_form_settings.html.erb index 488f6394fc..0e2150e5bc 100644 --- a/app/views/hyrax/admin/collection_types/_form_settings.html.erb +++ b/app/views/hyrax/admin/collection_types/_form_settings.html.erb @@ -26,7 +26,7 @@ diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 242f7da617..330b4ce316 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -423,9 +423,11 @@ en: title: Managers type: Type form_participants: + access_options: access_options, add_group: Add group add_participants: Add Participants add_user: Add user + as: as current_participants: Current Participants header: Collection Participants instructions: You can designate both groups and users as creators and managers of collections of this type @@ -433,6 +435,7 @@ en: submit: Add update_notice: Participants Updated form_settings: + apply_to_new_works: APPLY TO NEW WORKS instructions: These settings determine how collections of this type can be managed and discovered. warning: 'Warning: These settings cannot be changed after a collection of this type has been created.' index: From 73e8dea90388e3fc5634c13de423bcd26b6333de Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 13:56:34 -0400 Subject: [PATCH 08/33] i15r app/views/hyrax/admin/features --- app/views/hyrax/admin/features/index.html.erb | 2 +- config/locales/hyrax.en.yml | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/app/views/hyrax/admin/features/index.html.erb b/app/views/hyrax/admin/features/index.html.erb index 98b50e8f7f..996e36b6f8 100644 --- a/app/views/hyrax/admin/features/index.html.erb +++ b/app/views/hyrax/admin/features/index.html.erb @@ -9,7 +9,7 @@ - + diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 330b4ce316..fc58f32bd1 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -468,6 +468,7 @@ en: description: Description feature: Feature header: Features + status: Status sidebar: activity: Activity analytics: Analytics From 87add476bf703b2f1741d1bac154d57280be13e7 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 14:22:59 -0400 Subject: [PATCH 09/33] i15r app/views/hyrax/admin/stats --- app/views/hyrax/admin/stats/_date_form.html.erb | 2 +- app/views/hyrax/admin/stats/_deposits.html.erb | 3 ++- app/views/hyrax/admin/stats/_new_users.html.erb | 8 ++++---- app/views/hyrax/admin/stats/_stats_by_date.html.erb | 6 ++++-- app/views/hyrax/admin/stats/show.html.erb | 2 +- config/locales/hyrax.en.yml | 12 ++++++++++++ 6 files changed, 24 insertions(+), 9 deletions(-) diff --git a/app/views/hyrax/admin/stats/_date_form.html.erb b/app/views/hyrax/admin/stats/_date_form.html.erb index c91e59ecfd..4d17e39676 100644 --- a/app/views/hyrax/admin/stats/_date_form.html.erb +++ b/app/views/hyrax/admin/stats/_date_form.html.erb @@ -4,5 +4,5 @@ <%= f.label "end [defaults to now]" %> - <%= f.submit "Load Stats" %> + <%= f.submit I18n.t("hyrax.admin.stats.date_form.load_stats", :default => "Load Stats") %> <%- end %> diff --git a/app/views/hyrax/admin/stats/_deposits.html.erb b/app/views/hyrax/admin/stats/_deposits.html.erb index f6cb1c9328..cc82c6c98b 100644 --- a/app/views/hyrax/admin/stats/_deposits.html.erb +++ b/app/views/hyrax/admin/stats/_deposits.html.erb @@ -1,9 +1,10 @@ +

<%= I18n.t("hyrax.admin.stats.deposits.deposits_by_users", :default => "Deposits By Users ") %>(<%= @presenter.date_filter_string %>)

Deposits By Users (<%= @presenter.date_filter_string %>)

    <% @presenter.depositors.each do |usr| %>
  • <%= link_to usr[:user].name, hyrax.user_path(usr[:user]), title: "View user's profile" %> - deposited <%= pluralize(usr[:deposits], "file") %> + <%= I18n.t("hyrax.admin.stats.deposits.deposited", :default => "deposited ") %><%= pluralize(usr[:deposits], "file") %>
  • <% end %>
diff --git a/app/views/hyrax/admin/stats/_new_users.html.erb b/app/views/hyrax/admin/stats/_new_users.html.erb index 88302b4321..e328ad9261 100644 --- a/app/views/hyrax/admin/stats/_new_users.html.erb +++ b/app/views/hyrax/admin/stats/_new_users.html.erb @@ -1,7 +1,7 @@ -

Newest Users (<%= @presenter.date_filter_string %>)

+

I18n.t("hyrax.admin.stats.new_users.newest_users_<%=_@presenterdate_filter_string_%>", :default => "Newest Users (<%= @presenter.date_filter_string %>)")

<%- if !@presenter.start_date.blank? %> - Total: <%= @presenter.recent_users.count %> + <%= I18n.t("hyrax.admin.stats.new_users.total", :default => "Total: ") %><%= @presenter.recent_users.count %> <%- else %> <%= @presenter.recent_users.count %> most recent users: <%- end %> @@ -11,9 +11,9 @@
  • <%= link_to usr.name, hyrax.user_path(usr), title: "View user's profile" %> <%- if usr.department %> - of <%= usr.department %> + <%= I18n.t("hyrax.admin.stats.new_users.of", :default => "of ") %><%= usr.department %> <%- end %> - registered + <%= I18n.t("hyrax.admin.stats.new_users.registered", :default => "registered") %> <%= usr.created_at.to_time.strftime("%m/%d/%Y") %> diff --git a/app/views/hyrax/admin/stats/_stats_by_date.html.erb b/app/views/hyrax/admin/stats/_stats_by_date.html.erb index ec793dfc70..91ab6a2f8a 100644 --- a/app/views/hyrax/admin/stats/_stats_by_date.html.erb +++ b/app/views/hyrax/admin/stats/_stats_by_date.html.erb @@ -1,8 +1,10 @@ -

    Statistics By Date

    +

    <%= I18n.t("hyrax.admin.stats.stats_by_date.statistics_by_date", :default => "Statistics By Date") %>

    Statistics in this section are filtered by the dates entered in the form below. - The data is unfiltered unless the date form has been filled in. Start date is required and the default end is now. + <%= I18n.t("hyrax.admin.stats.stats_by_date.explanation", :default => "Statistics in this section are filtered by the dates entered in the form below. + The data is unfiltered unless the date form has been filled in. Start date is required and the default end is now.") %>

    <%= render "date_form" %> <%= render "works" %> <%= render "new_users" %> <%= render "deposits" %> + diff --git a/app/views/hyrax/admin/stats/show.html.erb b/app/views/hyrax/admin/stats/show.html.erb index bc556179c3..edf99df545 100644 --- a/app/views/hyrax/admin/stats/show.html.erb +++ b/app/views/hyrax/admin/stats/show.html.erb @@ -2,4 +2,4 @@ <%= render "stats_by_date" %>
    <%= render "top_data" %> - \ No newline at end of file + diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index fc58f32bd1..d51400e35b 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -498,15 +498,27 @@ en: works_listing: Works listing works_report: Works Report stats: + date_form: + load_stats: Load Stats deposited_form: end_label: end [defaults to now] heading: 'Display Files Deposited:' start_label: Start + deposits: + deposited: 'deposited ' + deposits_by_users: 'Deposits By Users ' + new_users: + of: 'of ' + registered: registered + total: 'Total: ' repository_objects: series: published: Published unknown: Unknown unpublished: Unpublished + stats_by_date: + explanation: Statistics in this section are filtered by the dates entered in the form below. The data is unfiltered unless the date form has been filled in. Start date is required and the default end is now. + statistics_by_date: Statistics By Date user_deposits: end_label: Ending [defaults to now] heading: Display files deposited by users From ba53e7e91d0f20596bd318a71b0b11ff09986acf Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 15:17:53 -0400 Subject: [PATCH 10/33] follow up for _top_data --- app/views/hyrax/admin/stats/_top_data.html.erb | 13 +++++++------ config/locales/hyrax.en.yml | 6 ++++++ 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/app/views/hyrax/admin/stats/_top_data.html.erb b/app/views/hyrax/admin/stats/_top_data.html.erb index 9890ab9df0..4deddbdb87 100644 --- a/app/views/hyrax/admin/stats/_top_data.html.erb +++ b/app/views/hyrax/admin/stats/_top_data.html.erb @@ -1,12 +1,13 @@ -

    Top File Formats and Users

    -

    Statistics in this section shows the top <%= @presenter.limit %> items for each category

    +

    <%= I18n.t("hyrax.admin.stats.top_data.top_file_formats_and_users", :default => "Top File Formats and Users") %>

    +

    <%= I18n.t('hyrax.admin.stats.top_data.explanation_with_limit', limit: @presenter.limit, :default => "Statistics in this section shows the top %{limit} items for each category"); %>

    + <% if @presenter.limit == 5 %> -

    <%= link_to "View top 20", hyrax.admin_stats_path(limit: '20') %>

    +

    <%= link_to I18n.t('hyrax.admin.stats.top_data.view_top', number: 20, :default => "View top %{number}"), hyrax.admin_stats_path(limit: '20') %>

    <% else %> -

    <%= link_to "View top 5", hyrax.admin_stats_path %>

    +

    <%= link_to I18n.t('hyrax.admin.stats.top_data.view_top', number: 5, :default => "View top %{number}"), hyrax.admin_stats_path %>

    <% end %> -

    Top File Formats (top <%= @presenter.top_formats.count %>)

    +

    <%= I18n.t('hyrax.admin.stats.top_data.top_file_format', count: @presenter.top_formats.count, :default => "Top File Formats (top %{count})"); %>

      <% @presenter.top_formats.each do |fmt| %>
    • <%= fmt.label %> (<%= fmt.value %>)
    • @@ -14,7 +15,7 @@

    -

    Most Active Users (top <%= @presenter.active_users.count %>)

    +

    <%= I18n.t('hyrax.admin.stats.top_data.most_actie_users', count: @presenter.active_users.count, :default => "Most Active Users (top %{count})"); %>

      <% @presenter.active_users.each do |user| %>
    • diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index d51400e35b..d64832a7b7 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -519,6 +519,12 @@ en: stats_by_date: explanation: Statistics in this section are filtered by the dates entered in the form below. The data is unfiltered unless the date form has been filled in. Start date is required and the default end is now. statistics_by_date: Statistics By Date + top_data: + explanation_with_limit: Statistics in this section shows the top %{limit} items for each category + most_actie_users: Most Active Users (top %{count}) + top_file_format: Top File Formats (top %{count}) + top_file_formats_and_users: Top File Formats and Users + view_top: View top %{number} user_deposits: end_label: Ending [defaults to now] heading: Display files deposited by users From dbb6f4aa32c8777a1ab592b2dc35c23fba5be92f Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 16:07:08 -0400 Subject: [PATCH 11/33] i15r app/views/hyrax/admin/workflows --- app/views/hyrax/admin/workflows/index.html.erb | 2 +- config/locales/hyrax.en.yml | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/views/hyrax/admin/workflows/index.html.erb b/app/views/hyrax/admin/workflows/index.html.erb index 63fc6ca6f3..22166b8a33 100644 --- a/app/views/hyrax/admin/workflows/index.html.erb +++ b/app/views/hyrax/admin/workflows/index.html.erb @@ -24,7 +24,7 @@
      <%= t('hyrax.dashboard.my.sr.results_per_page') %> <%= label_tag :per_page do %> - Show <%= select_tag :per_page, options_for_select(Hyrax.config.range_for_number_of_results_to_display_per_page.map(&:to_s), h(params[:per_page])), title: "entries" %> per page + <%= I18n.t('hyrax.admin.workflows.show_number_per_page', number: (select_tag :per_page, options_for_select(Hyrax.config.range_for_number_of_results_to_display_per_page.map(&:to_s), h(params[:per_page])), title: "entries"), :default => "Show %{number}) per page"); %> <% end %> <%= render Blacklight::HiddenSearchStateComponent.new(params: search_state.params_for_search.except(:per_page, :sort, :utf8)) %>
      diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index d64832a7b7..ce8861c7ff 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -529,6 +529,8 @@ en: end_label: Ending [defaults to now] heading: Display files deposited by users start_label: Starting + workflows: + show_number_per_page: "Show %{number}) per page" works: headers: main: Work Statistics From fbfd69346a7e2daa24e7f156ce63b26336f598e2 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 17:02:20 -0400 Subject: [PATCH 12/33] i15r app/views/hyrax/base --- app/views/hyrax/base/_member_of_collections.html.erb | 2 +- app/views/hyrax/base/_relationships_parent_rows.html.erb | 1 - app/views/hyrax/base/inspect_work.html.erb | 2 +- config/locales/hyrax.en.yml | 6 +++++- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/app/views/hyrax/base/_member_of_collections.html.erb b/app/views/hyrax/base/_member_of_collections.html.erb index e58b7866ec..15860ef3ec 100644 --- a/app/views/hyrax/base/_member_of_collections.html.erb +++ b/app/views/hyrax/base/_member_of_collections.html.erb @@ -1,5 +1,5 @@
  • - + - + From 3af0ea0c202c3978635372498034c598b58372fa Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 18:17:25 -0400 Subject: [PATCH 17/33] i15r app/views/hyrax/permissions --- app/views/hyrax/permissions/confirm.html.erb | 4 ++-- config/locales/hyrax.en.yml | 4 ++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/app/views/hyrax/permissions/confirm.html.erb b/app/views/hyrax/permissions/confirm.html.erb index ae438c0522..02c24777b8 100644 --- a/app/views/hyrax/permissions/confirm.html.erb +++ b/app/views/hyrax/permissions/confirm.html.erb @@ -9,7 +9,7 @@ visibility_badge: visibility_badge(curation_concern.visibility)).html_safe %> diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 5a0a65adb9..be75570b1f 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -1605,6 +1605,10 @@ en: owner: edit: Edit access read: View/Download + permissions: + confirm: + confirm: Yes please. + deny: No. I'll update it manually. read_only: The repository is in read-only mode for maintenance. No submissions or edits can be made at this time. search: button: From d187a3c030de1617048507691ec698606338edd3 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 18:27:42 -0400 Subject: [PATCH 18/33] i15r app/views/hyrax/single_use_links_viewer --- app/views/hyrax/single_use_links_viewer/show.html.erb | 6 +++--- config/locales/hyrax.en.yml | 4 ++++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/app/views/hyrax/single_use_links_viewer/show.html.erb b/app/views/hyrax/single_use_links_viewer/show.html.erb index 2c65405b62..cc9cf2a404 100644 --- a/app/views/hyrax/single_use_links_viewer/show.html.erb +++ b/app/views/hyrax/single_use_links_viewer/show.html.erb @@ -1,10 +1,10 @@

    <%= @presenter %>

    -

    Actions

    +

    <%= I18n.t("hyrax.single_use_links_viewer.show.actions", :default => "Actions")%>

    - <%= link_to "Download (can only be used once)", @download_link, target: :_blank %> + <%= link_to I18n.t("hyrax.single_use_links_viewer.show.download", :default => "Download (can only be used once)"), @download_link, target: :_blank %>

    -

    Descriptions:

    +

    <%= I18n.t("hyrax.single_use_links_viewer.show.descriptions", :default => " Descriptions:") %>

    <%= render 'attributes', presenter: @presenter %>
    diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index be75570b1f..6eba8310e0 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -1657,6 +1657,10 @@ en: no_links: No links have been generated title: Single-Use Links single_use_links_viewer: + show: + actions: Actions + descriptions: " Descriptions:" + download: Download (can only be used once) single_use_error: help: '%{application_name} could not locate the single use link. This link either expired or had been used previously. We apologize for the inconvenience. You might be interested in using the help page for looking up solutions.' link_expired_not_found: Single Use Link Expired or Not Found From ea0d76aa900eb7a31cca58667e6b56678dbb7b55 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 19:01:25 -0400 Subject: [PATCH 19/33] i15r app/views/hyrax/users --- app/views/hyrax/users/_activity_log.html.erb | 2 +- app/views/hyrax/users/_user_info.html.erb | 31 ++++++++++++-------- config/locales/hyrax.en.yml | 15 ++++++++++ 3 files changed, 34 insertions(+), 14 deletions(-) diff --git a/app/views/hyrax/users/_activity_log.html.erb b/app/views/hyrax/users/_activity_log.html.erb index 6c3700bb4f..ec47c01cc6 100644 --- a/app/views/hyrax/users/_activity_log.html.erb +++ b/app/views/hyrax/users/_activity_log.html.erb @@ -10,7 +10,7 @@ <% valid_events = events.reject { |event| event[:action].blank? || event[:timestamp].blank? } %> <% if valid_events.empty? %>
    - + <% else %> <% valid_events.each do |event| %> diff --git a/app/views/hyrax/users/_user_info.html.erb b/app/views/hyrax/users/_user_info.html.erb index 601317641b..51910ace0a 100644 --- a/app/views/hyrax/users/_user_info.html.erb +++ b/app/views/hyrax/users/_user_info.html.erb @@ -11,65 +11,70 @@ <% end %> <% if user.facebook_handle.present? %> -
    Facebook Handle
    +
    <%= I18n.t("hyrax.users.user_info.facebook_handle", :default => "Facebook Handle") %>
    <%= link_to user.facebook_handle, "http://facebook.com/#{user.facebook_handle}", {target:'_blank'} %>
    <% end %> <% if user.twitter_handle.present? %> -
    Twitter Handle
    +
    <%= I18n.t("hyrax.users.user_info.twitter_handle", :default => "Twitter Handle") %>
    <%= link_to user.twitter_handle, "http://x.com/#{user.twitter_handle}", {target:'_blank'} %>
    <% end %> +<% if user.googleplus_handle.present? %> +
    <%= I18n.t("hyrax.users.user_info.googleplus_handle", :default => "Google+ Handle") %>
    +
    <%= link_to user.googleplus_handle, "http://google.com/+#{user.googleplus_handle}", {target:'_blank'} %>
    +<% end %> + <% if user.linkedin_handle.present? %> -
    LinkedIn
    +
    <%= I18n.t("hyrax.users.user_info.linkedin", :default => "LinkedIn") %>
    <%= link_to "#{@linkedInUrl}", "#{@linkedInUrl}", { target: '_blank' } %>
    <% end %> -
    Email
    +
    <%= I18n.t("hyrax.users.user_info.email", :default => "Email") %>
    <%= mail_to user.email %>
    <% if user.chat_id %> -
    Chat ID
    +
    <%= I18n.t("hyrax.users.user_info.chat_id", :default => "Chat ID") %>
    <%= user.chat_id %>
    <% end %> <% if user.website %> -
    Website(s)
    +
    <%= I18n.t("hyrax.users.user_info.website", :default => "Website(s)") %>
    <%= iconify_auto_link(user.website) %>
    <% end %> <% if user.title %> -
    Title
    +
    <%= I18n.t("hyrax.users.user_info.title", :default => "Title") %>
    <%= user.title %>
    <% end %> <% if user.admin_area %> -
    Administrative Area
    +
    <%= I18n.t("hyrax.users.user_info.administrative_area", :default => "Administrative Area") %>
    <%= user.admin_area %>
    <% end %> <% if user.department %> -
    Department
    +
    <%= I18n.t("hyrax.users.user_info.department", :default => "Department") %>
    <%= user.department %>
    <% end %> <% if user.office %> -
    Office
    + <
    <%= I18n.t("hyrax.users.user_info.office", :default => "Office") %>
    <%= user.office %>
    <% end %> <% if user.address %> -
    Address
    +
    <%= I18n.t("hyrax.users.user_info.address", :default => "Address") %>
    <%= user.address %>
    <% end %> <% if user.affiliation %> -
    Affiliation
    +
    <%= I18n.t("hyrax.users.user_info.affiliation", :default => "Affiliation") %>
    <%= user.affiliation %>
    <% end %> <% if user.telephone %> -
    Telephone
    +
    <%= I18n.t("hyrax.users.user_info.telephone", :default => "Telephone") %>
    <%= link_to_telephone(user) %>
    <% end %> diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 6eba8310e0..43eb5f6621 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -1796,6 +1796,7 @@ en: users: activity_log: date: Date + no_user_activity: No user activity user_activity: User Activity index: avatar: Avatar @@ -1811,6 +1812,20 @@ en: search_form: go: Go search_users: Search Users + user_info: + administrative_area: Administrative Area + affiliation: Affiliation + chat_id: Chat ID + department: Department + email: Email + facebook_handle: Facebook Handle + googleplus_handle: Google+ Handle + linkedin: LinkedIn + office: Office + telephone: Telephone + title: Title + twitter_handle: Twitter Handle + website: Website(s) virus_scanner: virus_detected: Virus detected in %{filename}. The file has not been saved. visibility: From c16d3a4e05a0744f805f6693d72e27c4b822cbaf Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 19:09:28 -0400 Subject: [PATCH 20/33] i15r app/views/hyrax/pages --- app/views/hyrax/pages/_form.html.erb | 8 ++++---- config/locales/hyrax.en.yml | 5 +++++ 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/app/views/hyrax/pages/_form.html.erb b/app/views/hyrax/pages/_form.html.erb index 22502de220..14a999c3dd 100644 --- a/app/views/hyrax/pages/_form.html.erb +++ b/app/views/hyrax/pages/_form.html.erb @@ -30,7 +30,7 @@ <%= simple_form_for ContentBlock.for(:about), url: hyrax.page_path(ContentBlock.for(:about)), html: { class: 'nav-safety' } do |f| %>
    - <%= f.label :about %>
    + <%= f.label I18n.t("hyrax.pages.form.about", :default => "about") %>
    <%= f.text_area :about, value: f.object.value, class: 'form-control tinymce', rows: 20, cols: 120 %>
    @@ -46,7 +46,7 @@ <%= simple_form_for ContentBlock.for(:help), url: hyrax.page_path(ContentBlock.for(:help)), html: { class: 'nav-safety' } do |f| %>
    - <%= f.label :help %>
    + <%= f.label I18n.t("hyrax.pages.form.help", :default => "help") %>
    <%= f.text_area :help, value: f.object.value, class: 'form-control tinymce', rows: 20, cols: 120 %>
    @@ -62,7 +62,7 @@ <%= simple_form_for ContentBlock.for(:agreement), url: hyrax.page_path(ContentBlock.for(:agreement)), html: { class: 'nav-safety' } do |f| %>
    - <%= f.label :agreement %>
    + <%= f.label I18n.t("hyrax.pages.form.agreement", :default => "agreement") %>
    <%= f.text_area :agreement, value: f.object.value, class: 'form-control tinymce', rows: 20, cols: 120 %>
    @@ -78,7 +78,7 @@ <%= simple_form_for ContentBlock.for(:terms), url: hyrax.page_path(ContentBlock.for(:terms)), html: { class: 'nav-safety' } do |f| %>
    - <%= f.label :terms %>
    + <%= f.label I18n.t("hyrax.pages.form.terms", :default => "terms") %>
    <%= f.text_area :terms, value: f.object.value, class: 'form-control tinymce', rows: 20, cols: 120 %>
    diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 43eb5f6621..bcfe1bfe1a 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -1589,6 +1589,11 @@ en: updated: Updated pages: cancel: Cancel + form: + about: about + agreement: agreement + help: help + terms: terms tabs: about_page: About Page agreement_page: Deposit Agreement From 856b757dd6c0067fccc605c834b7df8460dcfdfa Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 19:27:30 -0400 Subject: [PATCH 21/33] i15r app/views/hyrax/operations --- app/views/hyrax/operations/show.html.erb | 12 ++++++------ config/locales/hyrax.en.yml | 7 +++++++ 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/app/views/hyrax/operations/show.html.erb b/app/views/hyrax/operations/show.html.erb index 93e912a49f..8c9b3b122a 100644 --- a/app/views/hyrax/operations/show.html.erb +++ b/app/views/hyrax/operations/show.html.erb @@ -1,19 +1,19 @@ <% provide :page_title, 'Operations' %> <% provide :page_header do %> -

    <%= @operation.operation_type %> status

    +

    <%= @operation.operation_type %> <%= I18n.t("hyrax.operations.show.status", :default => "status") %>

    <% end %> -

    Status: <%= @operation.status %>

    -

    Message: <%= @operation.message %>

    +

    <%= I18n.t("hyrax.operations.show.status_label", :default => "Status:") %> <%= @operation.status %>

    +

    <%= I18n.t("hyrax.operations.show.message_label", :default => "Message:") %> <%= @operation.message %>

    <% if @operation.children.any? %>
    Status<%= I18n.t("hyrax.admin.features.index.status", :default => "Status") %> <%= t('.feature') %> <%= t('.description') %> <%= t('.action') %>
    Member of Collections<%= I18n.t("hyrax.base.member_of_collections.member_of_collections", :default => "Member of Collections") %>
      <% presenter.member_of_collection_presenters.each do |p| %> diff --git a/app/views/hyrax/base/_relationships_parent_rows.html.erb b/app/views/hyrax/base/_relationships_parent_rows.html.erb index f281a7050f..4c6e3f39d5 100644 --- a/app/views/hyrax/base/_relationships_parent_rows.html.erb +++ b/app/views/hyrax/base/_relationships_parent_rows.html.erb @@ -13,4 +13,3 @@ <% if current_user %> <%= presenter.attribute_to_html(:admin_set, render_as: :faceted, html_dl: true) %> <% end %> - diff --git a/app/views/hyrax/base/inspect_work.html.erb b/app/views/hyrax/base/inspect_work.html.erb index 6b81309248..1b43a4cc13 100644 --- a/app/views/hyrax/base/inspect_work.html.erb +++ b/app/views/hyrax/base/inspect_work.html.erb @@ -32,6 +32,6 @@

      <%= t('.persistence') %>

      -
      Solr
      +
      <%= I18n.t("hyrax.base.inspect_work.solr", :default => "Solr") %>
      <%= @presenter.inspect_work.solr %>
      diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index ce8861c7ff..89d298dada 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -530,7 +530,7 @@ en: heading: Display files deposited by users start_label: Starting workflows: - show_number_per_page: "Show %{number}) per page" + show_number_per_page: Show %{number}) per page works: headers: main: Work Statistics @@ -657,6 +657,7 @@ en: cancel: Cancel remove: Remove text: Removing this work will not remove it from the repository, only from this collection. Are you sure you want to remove this work from the collection? + display_data_info: This table will only display data if works are assigned to collections header: actions: Action title: Collection title @@ -716,6 +717,7 @@ en: processing_entity_id: Processing Entity ID proxy_for: Proxy for roles: Roles + solr: Solr state: State state_name: State Name users: Users @@ -730,6 +732,8 @@ en: title: Title unauthorized: There are no publicly available items in this %{type}. visibility: Visibility + member_of_collections: + member_of_collections: Member of Collections relationships: empty: This %{type} is not currently in any collections. header: Relationships From 66133622df45ee03d7b583b5ff914f4e08967737 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 17:13:05 -0400 Subject: [PATCH 13/33] i15r app/views/hyrax/batch_edits --- app/views/hyrax/batch_edits/edit.html.erb | 6 +++--- config/locales/hyrax.en.yml | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/app/views/hyrax/batch_edits/edit.html.erb b/app/views/hyrax/batch_edits/edit.html.erb index 4e16809a53..2723780ea1 100644 --- a/app/views/hyrax/batch_edits/edit.html.erb +++ b/app/views/hyrax/batch_edits/edit.html.erb @@ -47,7 +47,7 @@ <%= hidden_field_tag "batch_document_ids[]", batch_id %> <% end %>
      - <%= f.submit "Save changes", class: 'btn btn-primary field-save', id: "#{term.to_s}_save" %> + <%= f.submit I18n.t("hyrax.batch_edits.edit.save_changes", :default => "Save changes"), class: 'btn btn-primary field-save', id: "#{term.to_s}_save" %> <%= t('helpers.action.cancel') %>
      @@ -80,7 +80,7 @@ <%= hidden_field_tag "batch_document_ids[]", batch_id %> <% end %>
      - <%= f.submit "Save changes", class: 'btn btn-primary field-save', id: "permissions_visibility_save" %> + <%= f.submit I18n.t("hyrax.batch_edits.edit.save_changes", :default => "Save changes"), class: 'btn btn-primary field-save', id: "permissions_visibility_save" %> <%= t('helpers.action.cancel') %>
      @@ -110,7 +110,7 @@ <%= hidden_field_tag "batch_document_ids[]", batch_id %> <% end %>
      - <%= f.submit "Save changes", class: 'btn btn-primary field-save', id: "permissions_sharing_save" %> + <%= f.submit I18n.t("hyrax.batch_edits.edit.save_changes", :default => "Save changes"), class: 'btn btn-primary field-save', id: "permissions_sharing_save" %> <%= t('helpers.action.cancel') %>
      diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 89d298dada..b4e7fb01f4 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -808,6 +808,7 @@ en: permissions: Permissions sharing: Sharing visibility: Visibility + save_changes: Save changes batch_uploads: disabled: Feature disabled by administrator files: From 9e1d24f19c214018c1e598d70e62fab79a153d28 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 17:14:15 -0400 Subject: [PATCH 14/33] i15r app/views/hyrax/batch_select --- app/views/hyrax/batch_select/_add_button.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/hyrax/batch_select/_add_button.html.erb b/app/views/hyrax/batch_select/_add_button.html.erb index a66c5b82ab..7f80e5ceb3 100644 --- a/app/views/hyrax/batch_select/_add_button.html.erb +++ b/app/views/hyrax/batch_select/_add_button.html.erb @@ -1,3 +1,3 @@
      <%= check_box_tag "batch_document_ids[]", document.id, false, class:"batch_document_selector", id: "batch_document_#{document.id}", checks: "active", 'aria-labelledby': "batch_document_#{document.id}" %> -
      \ No newline at end of file + From 28e34601c2528a7c5774046f517ab59f829f79d8 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 17:19:00 -0400 Subject: [PATCH 15/33] i15r app/views/hyrax/citations --- app/views/hyrax/citations/file.html.erb | 1 + app/views/hyrax/citations/work.html.erb | 12 ++++++------ config/locales/hyrax.en.yml | 5 ++++- 3 files changed, 11 insertions(+), 7 deletions(-) diff --git a/app/views/hyrax/citations/file.html.erb b/app/views/hyrax/citations/file.html.erb index e69de29bb2..8b13789179 100644 --- a/app/views/hyrax/citations/file.html.erb +++ b/app/views/hyrax/citations/file.html.erb @@ -0,0 +1 @@ + diff --git a/app/views/hyrax/citations/work.html.erb b/app/views/hyrax/citations/work.html.erb index c14253739b..1c59b246ad 100644 --- a/app/views/hyrax/citations/work.html.erb +++ b/app/views/hyrax/citations/work.html.erb @@ -1,13 +1,13 @@

      <%= t('.citation_formats') %>

      -

      MLA

      -<%= export_as_mla_citation(@presenter) %> +

      <%= I18n.t("hyrax.citations.work.mla", :default => "MLA") %>

      +I18n.t("hyrax.citations.work.<%=_export_as_mla_citation@presenter_%>", :default => "<%= export_as_mla_citation(@presenter) %>")

      -

      APA

      -<%= export_as_apa_citation(@presenter) %> +

      <%= I18n.t("hyrax.citations.work.apa", :default => "APA") %>

      +I18n.t("hyrax.citations.work.<%=_export_as_apa_citation@presenter_%>", :default => "<%= export_as_apa_citation(@presenter) %>")

      -

      Chicago

      -<%= export_as_chicago_citation(@presenter) %> +

      <%= I18n.t("hyrax.citations.work.chicago", :default => "Chicago") %>

      +I18n.t("hyrax.citations.work.<%=_export_as_chicago_citation@presenter_%>", :default => "<%= export_as_chicago_citation(@presenter) %>")

      diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index b4e7fb01f4..5a0a65adb9 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -806,9 +806,9 @@ en: descriptions: Descriptions descriptions_title: 'Descriptions:' permissions: Permissions + save_changes: Save changes sharing: Sharing visibility: Visibility - save_changes: Save changes batch_uploads: disabled: Feature disabled by administrator files: @@ -827,7 +827,10 @@ en: search_results: Back to search results citations: work: + apa: APA + chicago: Chicago citation_formats: Citation Formats + mla: MLA collection: actions: add_existing_works: From f98217f02cf766ff29ee48e58ea217508230ff0b Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 17:20:50 -0400 Subject: [PATCH 16/33] small forgotten change --- app/views/hyrax/base/_form_member_of_collections.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/hyrax/base/_form_member_of_collections.html.erb b/app/views/hyrax/base/_form_member_of_collections.html.erb index bd8021771e..eebe0ae360 100644 --- a/app/views/hyrax/base/_form_member_of_collections.html.erb +++ b/app/views/hyrax/base/_form_member_of_collections.html.erb @@ -34,7 +34,7 @@ HTML Properties:
    This table will only display data if works are assigned to collections<%= I18n.t("hyrax.base.form_member_of_collections.display_data_info", :default => "This table will only display data if works are assigned to collections") %>
    No user activity<%= I18n.t("hyrax.users.activity_log.no_user_activity", :default => "No user activity") %>
    - - - + + + <% @operation.children.each do |op| %> diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index bcfe1bfe1a..7c6cfeed2c 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -1587,6 +1587,13 @@ en: status: Status title: Operations updated: Updated + show: + message_header: Message + message_label: 'Message:' + operation_type_header: Operation Type + status: status + status_header: Status + status_label: 'Status:' pages: cancel: Cancel form: From 655ca082ba4db86c4b24ae345750736fd97c5f59 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 21:30:41 -0400 Subject: [PATCH 22/33] i15r app/views/hyrax/file_sets/ --- .../_asset_permissions_denial_flash.html.erb | 11 ++++------- config/locales/hyrax.en.yml | 2 ++ 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/app/views/hyrax/file_sets/_asset_permissions_denial_flash.html.erb b/app/views/hyrax/file_sets/_asset_permissions_denial_flash.html.erb index a376c0e53f..a4bb2ef9d4 100644 --- a/app/views/hyrax/file_sets/_asset_permissions_denial_flash.html.erb +++ b/app/views/hyrax/file_sets/_asset_permissions_denial_flash.html.erb @@ -1,9 +1,6 @@ -The file(s) -<%= - total_shown = 20 - file_sets.first(total_shown) +<%=total_shown = 20 + files = file_sets.first(total_shown) .map { |fs| link_to(fs, file_set_url(fs)) } .tap { |fs| fs << '...' if file_sets.length > total_shown } - .join(', ') -%> - could not be updated. You do not have sufficient privileges to edit it. + .join(', ') + I18n.t('hyrax.file_sets.asset_permissions_denial_flash.message', files: files, :default => "The file(s) %{files} could not be updated. You do not have sufficient privileges to edit it."); %> diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 7c6cfeed2c..11bc048533 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -1353,6 +1353,8 @@ en: versions_title: Display previous versions asset_deleted_flash: message: The file has been deleted. + asset_permissions_denial_flash: + message: The file(s) %{files} could not be updated. You do not have sufficient privileges to edit it." asset_saved_flash: message: one: The file %{saved_files} has been saved. From e5e3a19a4d4b38dffa0813584def0d38707709f2 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Fri, 23 May 2025 12:43:19 -0400 Subject: [PATCH 23/33] i15r app/views/hyrax/dashbord/ --- .../dashboard/collections/_show_document_list_row.html.erb | 5 ++--- config/locales/hyrax.en.yml | 2 ++ 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/app/views/hyrax/dashboard/collections/_show_document_list_row.html.erb b/app/views/hyrax/dashboard/collections/_show_document_list_row.html.erb index a40bd04229..38d8ce0b4b 100644 --- a/app/views/hyrax/dashboard/collections/_show_document_list_row.html.erb +++ b/app/views/hyrax/dashboard/collections/_show_document_list_row.html.erb @@ -42,11 +42,10 @@
    <%= t('.edit_access') %>
    <% if document.edit_groups.present? %> - Groups: <%= document.edit_groups.join(', ') %> + <%= I18n.t("hyrax.dashboard.collections.show_document_list_row.groups", :default => "Groups: ") %><%= document.edit_groups.join(', ') %>
    <% end %> - Users: <%= document.edit_people.join(', ') %> -
    + <%= I18n.t("hyrax.dashboard.collections.show_document_list_row.users", :default => "Users: ") %><%= document.edit_people.join(', ') %> diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 11bc048533..94234e42e2 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -1088,6 +1088,8 @@ en: creator: 'Creator:' depositor: 'Depositor:' edit_access: 'Edit Access:' + groups: 'Groups: ' + users: 'Users: ' sort_and_per_page: show_par_page_html: Show %{select} per page sort_by: 'Sort By:' From 48403dc4ad15e7a16bc702579f670255616ff955 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Fri, 23 May 2025 14:04:02 -0400 Subject: [PATCH 24/33] clean up --- .dassie/app/views/layouts/application.html.erb | 2 +- .dassie/app/views/shared/_footer.html.erb | 2 +- .dassie/config/locales/hyrax.en.yml | 2 +- .../hyrax/admin/admin_sets/_form_participants.html.erb | 6 ++---- app/views/hyrax/admin/admin_sets/index.html.erb | 1 - .../admin/collection_types/_form_participants.html.erb | 4 ++-- app/views/hyrax/admin/stats/_deposits.html.erb | 1 - app/views/hyrax/admin/stats/_new_users.html.erb | 2 +- app/views/hyrax/citations/work.html.erb | 6 +++--- app/views/hyrax/pages/_form.html.erb | 8 ++++---- app/views/hyrax/permissions/confirm.html.erb | 2 +- config/locales/hyrax.en.yml | 3 +-- 12 files changed, 17 insertions(+), 22 deletions(-) diff --git a/.dassie/app/views/layouts/application.html.erb b/.dassie/app/views/layouts/application.html.erb index abf0e46fbe..18ed00c7c4 100644 --- a/.dassie/app/views/layouts/application.html.erb +++ b/.dassie/app/views/layouts/application.html.erb @@ -1,7 +1,7 @@ - <%= I18n.t("layouts.application.dassie", :default => "Dassie") %> + <%= I18n.t("layouts.application.dev_env", :default => "Dassie") %> <%= csrf_meta_tags %> <%= csp_meta_tag %> diff --git a/.dassie/app/views/shared/_footer.html.erb b/.dassie/app/views/shared/_footer.html.erb index 1057c674ef..f4affea8df 100644 --- a/.dassie/app/views/shared/_footer.html.erb +++ b/.dassie/app/views/shared/_footer.html.erb @@ -4,7 +4,7 @@

    <%= t('hyrax.footer.service_html') %> <%= t('hyrax.product_name') %> v<%= Hyrax::VERSION %>

    Commit <%= link_to ENV.fetch('BUILD_GITSHA', "Unknown")[0..6], "https://github.com/samvera/hyrax/commit/#{ENV.fetch('BUILD_GITSHA', 'main')}" %> - <%= I18n.t("shared.footer.built_at", :default => "Built at ") %><%= ENV.fetch('BUILD_TIMESTAMP', 'Unknown') %> + <%= I18n.t('shared.footer.built_at', time: ENV.fetch('BUILD_TIMESTAMP', 'Unknown'), :default => "Built at %{time}"); %>

    - <%= builder.select :access, - <%= I18n.t("hyrax.admin.admin_sets.form_participants.access_options", :default => "access_options,") %> + <%= builder.select :access, "access_options," { prompt: "Select a role..." }, class: 'form-control' %>
    @@ -48,8 +47,7 @@
    - <%= builder.select :access, - <%= I18n.t("hyrax.admin.admin_sets.form_participants.access_options", :default => "access_options,") %> + <%= builder.select :access, "access_options," { prompt: "Select a role..." }, class: 'form-control' %>
    diff --git a/app/views/hyrax/admin/admin_sets/index.html.erb b/app/views/hyrax/admin/admin_sets/index.html.erb index 0cc0d3cb7d..b9e7cd8917 100644 --- a/app/views/hyrax/admin/admin_sets/index.html.erb +++ b/app/views/hyrax/admin/admin_sets/index.html.erb @@ -14,7 +14,6 @@ <% if @admin_sets.present? %>
    Operation TypeStatusMessage<%= I18n.t("hyrax.operations.show.operation_type_header", :default => "Operation Type") %><%= I18n.t("hyrax.operations.show.status_header", :default => "Status") %><%= I18n.t("hyrax.operations.show.message_header", :default => "Message") %>
    - diff --git a/app/views/hyrax/admin/collection_types/_form_participants.html.erb b/app/views/hyrax/admin/collection_types/_form_participants.html.erb index f6dc2c6768..4f8c29da10 100644 --- a/app/views/hyrax/admin/collection_types/_form_participants.html.erb +++ b/app/views/hyrax/admin/collection_types/_form_participants.html.erb @@ -23,7 +23,7 @@ class: 'form-control' %> <%= I18n.t("hyrax.admin.collection_types.form_participants.as", :default => "as") %> <%= f.select :access, - <%= I18n.t("hyrax.admin.collection_types.form_participants.access_options", :default => "access_options,") %> + access_options, { prompt: "Select a role..." }, class: 'form-control' %> @@ -49,7 +49,7 @@ placeholder: "Search for a user..." %> <%= I18n.t("hyrax.admin.collection_types.form_participants.as", :default => "as") %> <%= f.select :access, - <%= I18n.t("hyrax.admin.collection_types.form_participants.access_options", :default => "access_options,") %> + access_options, { prompt: "Select a role..." }, class: 'form-control' %> diff --git a/app/views/hyrax/admin/stats/_deposits.html.erb b/app/views/hyrax/admin/stats/_deposits.html.erb index cc82c6c98b..424da45a64 100644 --- a/app/views/hyrax/admin/stats/_deposits.html.erb +++ b/app/views/hyrax/admin/stats/_deposits.html.erb @@ -1,5 +1,4 @@

    <%= I18n.t("hyrax.admin.stats.deposits.deposits_by_users", :default => "Deposits By Users ") %>(<%= @presenter.date_filter_string %>)

    -

    Deposits By Users (<%= @presenter.date_filter_string %>)

      <% @presenter.depositors.each do |usr| %>
    • diff --git a/app/views/hyrax/admin/stats/_new_users.html.erb b/app/views/hyrax/admin/stats/_new_users.html.erb index e328ad9261..0a37595fee 100644 --- a/app/views/hyrax/admin/stats/_new_users.html.erb +++ b/app/views/hyrax/admin/stats/_new_users.html.erb @@ -1,4 +1,4 @@ -

      I18n.t("hyrax.admin.stats.new_users.newest_users_<%=_@presenterdate_filter_string_%>", :default => "Newest Users (<%= @presenter.date_filter_string %>)")

      +

      <%= I18n.t('hyrax.admin.stats.new_users.newest_users', users: @presenter.date_filter_string, :default => "Newest Users (%{users})"); %>

      <%- if !@presenter.start_date.blank? %> <%= I18n.t("hyrax.admin.stats.new_users.total", :default => "Total: ") %><%= @presenter.recent_users.count %> diff --git a/app/views/hyrax/citations/work.html.erb b/app/views/hyrax/citations/work.html.erb index 1c59b246ad..ae92b99ae5 100644 --- a/app/views/hyrax/citations/work.html.erb +++ b/app/views/hyrax/citations/work.html.erb @@ -1,13 +1,13 @@

      <%= t('.citation_formats') %>

      <%= I18n.t("hyrax.citations.work.mla", :default => "MLA") %>

      -I18n.t("hyrax.citations.work.<%=_export_as_mla_citation@presenter_%>", :default => "<%= export_as_mla_citation(@presenter) %>") +<%= export_as_mla_citation(@presenter) %>

      <%= I18n.t("hyrax.citations.work.apa", :default => "APA") %>

      -I18n.t("hyrax.citations.work.<%=_export_as_apa_citation@presenter_%>", :default => "<%= export_as_apa_citation(@presenter) %>") +<%= export_as_apa_citation(@presenter) %>

      <%= I18n.t("hyrax.citations.work.chicago", :default => "Chicago") %>

      -I18n.t("hyrax.citations.work.<%=_export_as_chicago_citation@presenter_%>", :default => "<%= export_as_chicago_citation(@presenter) %>") +<%= export_as_chicago_citation(@presenter) %>

      diff --git a/app/views/hyrax/pages/_form.html.erb b/app/views/hyrax/pages/_form.html.erb index 14a999c3dd..22502de220 100644 --- a/app/views/hyrax/pages/_form.html.erb +++ b/app/views/hyrax/pages/_form.html.erb @@ -30,7 +30,7 @@ <%= simple_form_for ContentBlock.for(:about), url: hyrax.page_path(ContentBlock.for(:about)), html: { class: 'nav-safety' } do |f| %>
      - <%= f.label I18n.t("hyrax.pages.form.about", :default => "about") %>
      + <%= f.label :about %>
      <%= f.text_area :about, value: f.object.value, class: 'form-control tinymce', rows: 20, cols: 120 %>
      @@ -46,7 +46,7 @@ <%= simple_form_for ContentBlock.for(:help), url: hyrax.page_path(ContentBlock.for(:help)), html: { class: 'nav-safety' } do |f| %>
      - <%= f.label I18n.t("hyrax.pages.form.help", :default => "help") %>
      + <%= f.label :help %>
      <%= f.text_area :help, value: f.object.value, class: 'form-control tinymce', rows: 20, cols: 120 %>
      @@ -62,7 +62,7 @@ <%= simple_form_for ContentBlock.for(:agreement), url: hyrax.page_path(ContentBlock.for(:agreement)), html: { class: 'nav-safety' } do |f| %>
      - <%= f.label I18n.t("hyrax.pages.form.agreement", :default => "agreement") %>
      + <%= f.label :agreement %>
      <%= f.text_area :agreement, value: f.object.value, class: 'form-control tinymce', rows: 20, cols: 120 %>
      @@ -78,7 +78,7 @@ <%= simple_form_for ContentBlock.for(:terms), url: hyrax.page_path(ContentBlock.for(:terms)), html: { class: 'nav-safety' } do |f| %>
      - <%= f.label I18n.t("hyrax.pages.form.terms", :default => "terms") %>
      + <%= f.label :terms %>
      <%= f.text_area :terms, value: f.object.value, class: 'form-control tinymce', rows: 20, cols: 120 %>
      diff --git a/app/views/hyrax/permissions/confirm.html.erb b/app/views/hyrax/permissions/confirm.html.erb index 02c24777b8..29c5a2f272 100644 --- a/app/views/hyrax/permissions/confirm.html.erb +++ b/app/views/hyrax/permissions/confirm.html.erb @@ -9,7 +9,7 @@ visibility_badge: visibility_badge(curation_concern.visibility)).html_safe %> diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 94234e42e2..8f235858a7 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -149,7 +149,6 @@ en: title: Viewers type: Type form_participants: - access_options: access_options, add_group: 'Add group:' add_participants: Add Participants add_user: 'Add user:' @@ -423,7 +422,6 @@ en: title: Managers type: Type form_participants: - access_options: access_options, add_group: Add group add_participants: Add Participants add_user: Add user @@ -508,6 +506,7 @@ en: deposited: 'deposited ' deposits_by_users: 'Deposits By Users ' new_users: + newest_users: Newest Users %{users} of: 'of ' registered: registered total: 'Total: ' From 2532584ebb12c5281a88e7a1e3d419b36f943171 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Mon, 3 Nov 2025 11:32:32 -0500 Subject: [PATCH 25/33] Add a new script to translate .en.yml file to other languages --- translate_missing.py | 114 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 114 insertions(+) create mode 100644 translate_missing.py diff --git a/translate_missing.py b/translate_missing.py new file mode 100644 index 0000000000..4720423a99 --- /dev/null +++ b/translate_missing.py @@ -0,0 +1,114 @@ +#!/usr/bin/env python3 +""" +translate_missing.py + +This script translates missing or empty keys from the English i18n YAML +file (hyrax.en.yml) into one or more target languages using a local +LibreTranslate endpoint. + +Why Python? +- Preserves YAML formatting, comments, and inline/block style using ruamel.yaml +- Ruby's built-in YAML tools rewrite formatting, causing unnecessary diffs + in Git when only translation values change. +- This script is run occasionally, so introducing a small Python helper + is practical for keeping translation diffs clean. + +Usage: + +Set Up: + 1. Make sure LibreTranslate is running locally in a separate shell: + $ pip install libretranslate + $ libretranslate + +Run the script: + + All at once (multiple languages): + $ python translate_missing.py es zh it fr pt-BR + + One at a time (single language): + $ python translate_missing.py es +""" +import json +import sys +import time +import requests +from ruamel.yaml import YAML +from pathlib import Path + +# ---------------------- +# Configuration +# ---------------------- +SOURCE_LANG = "en" +INPUT_FILE = Path("config/locales/hyrax.en.yml") +LIBRETRANSLATE_URL = "http://127.0.0.1:5000/translate" + +yaml = YAML() +yaml.explicit_start = True # Add '---' at the top +yaml.preserve_quotes = True +yaml.width = 4096 # avoid folding long lines + +# ---------------------- +# Load source YAML once +# ---------------------- +source_data = yaml.load(INPUT_FILE.read_text()) +source = source_data[SOURCE_LANG] + +# ---------------------- +# Translation helper +# ---------------------- +def translate_text(text, source_lang=SOURCE_LANG, target_lang="es"): + if text is None or str(text).strip() == "": + return text + try: + resp = requests.post( + LIBRETRANSLATE_URL, + data={"q": text, "source": source_lang, "target": target_lang}, + ) + resp.raise_for_status() + translated = json.loads(resp.text)["translatedText"] + print(f"Translated ({target_lang}): {text} → {translated}") + return translated + except Exception as e: + print(f"⚠️ Translation error for '{text}': {e}") + return text + +# ---------------------- +# Recursive merge & translate +# ---------------------- +def deep_merge_translate(source_dict, target_dict, target_lang): + result = target_dict.copy() + for key, value in source_dict.items(): + if isinstance(value, dict): + result[key] = deep_merge_translate(value, result.get(key, {}), target_lang) + else: + if key not in result or str(result[key]).strip() == "": + result[key] = translate_text(value, target_lang=target_lang) + return result + +# ---------------------- +# Main loop over target languages +# ---------------------- +if len(sys.argv) < 2: + print("Usage: python translate_locales.py [ ...]") + sys.exit(1) + +for target_lang in sys.argv[1:]: + print(f"\n=== Translating into {target_lang} ===") + output_file = Path(f"config/locales/hyrax.{target_lang}.yml") + + # Load existing target YAML if present + if output_file.exists(): + target_data = yaml.load(output_file.read_text()) + target = target_data.get(target_lang, {}) + else: + target = {} + + # Merge and translate + merged = deep_merge_translate(source, target, target_lang) + + # Write back preserving formatting + output_data = {target_lang: merged} + with output_file.open("w") as f: + yaml.dump(output_data, f) + + print(f"✅ Updated {output_file} — existing translations preserved.") \ No newline at end of file From 10b83447d137da0c3a57116d15e63db2efb03665 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Tue, 4 Nov 2025 09:43:56 -0500 Subject: [PATCH 26/33] clean up --- app/views/hyrax/admin/admin_sets/_form_participants.html.erb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/hyrax/admin/admin_sets/_form_participants.html.erb b/app/views/hyrax/admin/admin_sets/_form_participants.html.erb index 576f9938b1..24eeaeba46 100644 --- a/app/views/hyrax/admin/admin_sets/_form_participants.html.erb +++ b/app/views/hyrax/admin/admin_sets/_form_participants.html.erb @@ -21,7 +21,7 @@
      - <%= builder.select :access, "access_options," + <%= builder.select :access, access_options, { prompt: "Select a role..." }, class: 'form-control' %>
      @@ -47,7 +47,7 @@
      - <%= builder.select :access, "access_options," + <%= builder.select :access, access_options, { prompt: "Select a role..." }, class: 'form-control' %>
      From 51e83266e6cfa83aee5cd7f32af304fd9b02f07a Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Tue, 4 Nov 2025 10:29:30 -0500 Subject: [PATCH 27/33] run i15r /app/views/shared --- app/views/shared/_nav_safety_modal.html.erb | 4 ++-- app/views/shared/_schema_version.html.erb | 4 ++-- config/locales/hyrax.en.yml | 7 +++++++ 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/app/views/shared/_nav_safety_modal.html.erb b/app/views/shared/_nav_safety_modal.html.erb index e43cc6ac47..8072c9d59a 100644 --- a/app/views/shared/_nav_safety_modal.html.erb +++ b/app/views/shared/_nav_safety_modal.html.erb @@ -5,8 +5,8 @@ <%= t(:'hyrax.nav_safety.change_tab_message') %> diff --git a/app/views/shared/_schema_version.html.erb b/app/views/shared/_schema_version.html.erb index c9ec753291..cef0ffb247 100644 --- a/app/views/shared/_schema_version.html.erb +++ b/app/views/shared/_schema_version.html.erb @@ -5,12 +5,12 @@
      <% if schema_version.present? %>
      - Created On Version + <%= I18n.t("shared.schema_version.created_on_version", :default => "Created On Version") %>

      <%= schema_version.to_f %>

      <% end %>
      - Version After Save + <%= I18n.t("shared.schema_version.version_after_save", :default => "Version After Save") %>

      <%= @latest_schema_version %>

      diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 8f235858a7..1cd7191180 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -1898,6 +1898,13 @@ en: no_preview: No preview available update: header: Edit Work + shared: + nav_safety_modal: + cancel: Cancel + ok: OK + schema_version: + created_on_version: Created On Version + version_after_save: Version After Save simple_form: hints: admin_set: From 49b932eefc5a8ea3762c9a322c4ef7ad1709c73b Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Tue, 4 Nov 2025 11:50:34 -0500 Subject: [PATCH 28/33] run i15r app/views/layouts --- app/views/layouts/error.html.erb | 2 +- config/locales/hyrax.en.yml | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/app/views/layouts/error.html.erb b/app/views/layouts/error.html.erb index ee5910f5bb..a73d53bc4d 100644 --- a/app/views/layouts/error.html.erb +++ b/app/views/layouts/error.html.erb @@ -3,7 +3,7 @@ - <%= h(application_name) %>: System Error + <%= h(application_name) %>: <%= I18n.t("layouts.error.system_error", :default => "System Error") %> <%= stylesheet_link_tag 'application' %> diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 1cd7191180..be797d1a6d 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -1898,6 +1898,9 @@ en: no_preview: No preview available update: header: Edit Work + layouts: + error: + system_error: System Error shared: nav_safety_modal: cancel: Cancel From 8b11f0848814e6f27fcf828b0791370d89f691bb Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Tue, 4 Nov 2025 12:17:10 -0500 Subject: [PATCH 29/33] run i15r app/views/hyrax/content_blocks --- app/views/hyrax/content_blocks/_form.html.erb | 6 +++--- config/locales/hyrax.en.yml | 4 ++++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/app/views/hyrax/content_blocks/_form.html.erb b/app/views/hyrax/content_blocks/_form.html.erb index 142a868574..f0f849a6ff 100644 --- a/app/views/hyrax/content_blocks/_form.html.erb +++ b/app/views/hyrax/content_blocks/_form.html.erb @@ -23,7 +23,7 @@ <%= simple_form_for ContentBlock.for(:announcement), url: hyrax.content_block_path(ContentBlock.for(:announcement)), html: {class: 'nav-safety'} do |f| %>
      - <%= f.label :announcement %>
      + <%= f.label I18n.t("hyrax.content_blocks.form.announcement", :default => "announcement") %>
      <%= f.text_area :announcement, value: f.object.value, class: 'form-control tinymce', rows: 20, cols: 120 %>
      @@ -39,7 +39,7 @@ <%= simple_form_for ContentBlock.for(:marketing), url: hyrax.content_block_path(ContentBlock.for(:marketing)), html: {class: 'nav-safety'} do |f| %>
      - <%= f.label :marketing %>
      + <%= f.label I18n.t("hyrax.content_blocks.form.marketing", :default => "marketing") %>
      <%= f.text_area :marketing, value: f.object.value, class: 'form-control tinymce', rows: 20, cols: 120 %>
      @@ -55,7 +55,7 @@ <%= simple_form_for ContentBlock.for(:researcher), url: hyrax.content_block_path(ContentBlock.for(:researcher)), html: {class: 'nav-safety'} do |f| %>
      - <%= f.label :researcher %>
      + <%= f.label I18n.t("hyrax.content_blocks.form.researcher", :default => "researcher") %>
      <%= f.text_area :researcher, value: f.object.value, class: 'form-control tinymce', rows: 20, cols: 120 %>
      diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index be797d1a6d..7342b409df 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -927,6 +927,10 @@ en: type_label: Issue Type content_blocks: cancel: Cancel + form: + announcement: announcement + marketing: marketing + researcher: researcher tabs: announcement_text: Announcement Text featured_researcher: Featured Researcher From 4255a699628a2251ace34fb7b4761d4a26cdb413 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Thu, 6 Nov 2025 10:14:21 -0500 Subject: [PATCH 30/33] Remove translate_missing.py script it will be in samvera labs --- translate_missing.py | 114 ------------------------------------------- 1 file changed, 114 deletions(-) delete mode 100644 translate_missing.py diff --git a/translate_missing.py b/translate_missing.py deleted file mode 100644 index 4720423a99..0000000000 --- a/translate_missing.py +++ /dev/null @@ -1,114 +0,0 @@ -#!/usr/bin/env python3 -""" -translate_missing.py - -This script translates missing or empty keys from the English i18n YAML -file (hyrax.en.yml) into one or more target languages using a local -LibreTranslate endpoint. - -Why Python? -- Preserves YAML formatting, comments, and inline/block style using ruamel.yaml -- Ruby's built-in YAML tools rewrite formatting, causing unnecessary diffs - in Git when only translation values change. -- This script is run occasionally, so introducing a small Python helper - is practical for keeping translation diffs clean. - -Usage: - -Set Up: - 1. Make sure LibreTranslate is running locally in a separate shell: - $ pip install libretranslate - $ libretranslate - -Run the script: - - All at once (multiple languages): - $ python translate_missing.py es zh it fr pt-BR - - One at a time (single language): - $ python translate_missing.py es -""" -import json -import sys -import time -import requests -from ruamel.yaml import YAML -from pathlib import Path - -# ---------------------- -# Configuration -# ---------------------- -SOURCE_LANG = "en" -INPUT_FILE = Path("config/locales/hyrax.en.yml") -LIBRETRANSLATE_URL = "http://127.0.0.1:5000/translate" - -yaml = YAML() -yaml.explicit_start = True # Add '---' at the top -yaml.preserve_quotes = True -yaml.width = 4096 # avoid folding long lines - -# ---------------------- -# Load source YAML once -# ---------------------- -source_data = yaml.load(INPUT_FILE.read_text()) -source = source_data[SOURCE_LANG] - -# ---------------------- -# Translation helper -# ---------------------- -def translate_text(text, source_lang=SOURCE_LANG, target_lang="es"): - if text is None or str(text).strip() == "": - return text - try: - resp = requests.post( - LIBRETRANSLATE_URL, - data={"q": text, "source": source_lang, "target": target_lang}, - ) - resp.raise_for_status() - translated = json.loads(resp.text)["translatedText"] - print(f"Translated ({target_lang}): {text} → {translated}") - return translated - except Exception as e: - print(f"⚠️ Translation error for '{text}': {e}") - return text - -# ---------------------- -# Recursive merge & translate -# ---------------------- -def deep_merge_translate(source_dict, target_dict, target_lang): - result = target_dict.copy() - for key, value in source_dict.items(): - if isinstance(value, dict): - result[key] = deep_merge_translate(value, result.get(key, {}), target_lang) - else: - if key not in result or str(result[key]).strip() == "": - result[key] = translate_text(value, target_lang=target_lang) - return result - -# ---------------------- -# Main loop over target languages -# ---------------------- -if len(sys.argv) < 2: - print("Usage: python translate_locales.py [ ...]") - sys.exit(1) - -for target_lang in sys.argv[1:]: - print(f"\n=== Translating into {target_lang} ===") - output_file = Path(f"config/locales/hyrax.{target_lang}.yml") - - # Load existing target YAML if present - if output_file.exists(): - target_data = yaml.load(output_file.read_text()) - target = target_data.get(target_lang, {}) - else: - target = {} - - # Merge and translate - merged = deep_merge_translate(source, target, target_lang) - - # Write back preserving formatting - output_data = {target_lang: merged} - with output_file.open("w") as f: - yaml.dump(output_data, f) - - print(f"✅ Updated {output_file} — existing translations preserved.") \ No newline at end of file From a9b3041db84e136d66330a60a10aae90cf91facb Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Thu, 6 Nov 2025 10:29:47 -0500 Subject: [PATCH 31/33] Clean up --- .../hyrax/file_sets/_asset_permissions_denial_flash.html.erb | 3 ++- app/views/hyrax/users/_user_info.html.erb | 5 ----- config/locales/hyrax.en.yml | 1 - 3 files changed, 2 insertions(+), 7 deletions(-) diff --git a/app/views/hyrax/file_sets/_asset_permissions_denial_flash.html.erb b/app/views/hyrax/file_sets/_asset_permissions_denial_flash.html.erb index a4bb2ef9d4..971664d008 100644 --- a/app/views/hyrax/file_sets/_asset_permissions_denial_flash.html.erb +++ b/app/views/hyrax/file_sets/_asset_permissions_denial_flash.html.erb @@ -1,4 +1,5 @@ -<%=total_shown = 20 +<%= + total_shown = 20 files = file_sets.first(total_shown) .map { |fs| link_to(fs, file_set_url(fs)) } .tap { |fs| fs << '...' if file_sets.length > total_shown } diff --git a/app/views/hyrax/users/_user_info.html.erb b/app/views/hyrax/users/_user_info.html.erb index 51910ace0a..ec4ce4bf50 100644 --- a/app/views/hyrax/users/_user_info.html.erb +++ b/app/views/hyrax/users/_user_info.html.erb @@ -20,11 +20,6 @@
      <%= link_to user.twitter_handle, "http://x.com/#{user.twitter_handle}", {target:'_blank'} %>
      <% end %> -<% if user.googleplus_handle.present? %> -
      <%= I18n.t("hyrax.users.user_info.googleplus_handle", :default => "Google+ Handle") %>
      -
      <%= link_to user.googleplus_handle, "http://google.com/+#{user.googleplus_handle}", {target:'_blank'} %>
      -<% end %> - <% if user.linkedin_handle.present? %>
      <%= I18n.t("hyrax.users.user_info.linkedin", :default => "LinkedIn") %>
      <%= link_to "#{@linkedInUrl}", "#{@linkedInUrl}", { target: '_blank' } %>
      diff --git a/config/locales/hyrax.en.yml b/config/locales/hyrax.en.yml index 7342b409df..7bbcb454d7 100644 --- a/config/locales/hyrax.en.yml +++ b/config/locales/hyrax.en.yml @@ -1838,7 +1838,6 @@ en: department: Department email: Email facebook_handle: Facebook Handle - googleplus_handle: Google+ Handle linkedin: LinkedIn office: Office telephone: Telephone From 243cdde88724d86cdb1b5bb37d07c19d3b612050 Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Thu, 6 Nov 2025 15:58:27 -0500 Subject: [PATCH 32/33] clean up --- app/views/hyrax/permissions/confirm.html.erb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/hyrax/permissions/confirm.html.erb b/app/views/hyrax/permissions/confirm.html.erb index 29c5a2f272..bcd4dd5de4 100644 --- a/app/views/hyrax/permissions/confirm.html.erb +++ b/app/views/hyrax/permissions/confirm.html.erb @@ -9,7 +9,7 @@ visibility_badge: visibility_badge(curation_concern.visibility)).html_safe %> From 6788342a0c99e30809d069acec74ff2b1ef2326c Mon Sep 17 00:00:00 2001 From: Ryan Orlando Date: Wed, 21 May 2025 19:01:25 -0400 Subject: [PATCH 33/33] Add missing keys and values for it.yml --- config/locales/hyrax.it.yml | 109 ++++++++++++++++++++++++++++++++++++ 1 file changed, 109 insertions(+) diff --git a/config/locales/hyrax.it.yml b/config/locales/hyrax.it.yml index 380a7f215e..1afedff298 100644 --- a/config/locales/hyrax.it.yml +++ b/config/locales/hyrax.it.yml @@ -149,6 +149,7 @@ it: add_participants: Aggiungi partecipanti add_user: 'Aggiungi utente:' current_participants: Partecipanti attuali + as: come form_visibility: cancel: Annulla page_description: Il controllo delle impostazioni di rilascio e visibilità quando le opere aggiunte a questo set sono disponibili per la scoperta e il download e chi può scoprirle e scaricarle. @@ -187,6 +188,25 @@ it: item_list_header: Funziona in questo set show_actions: confirm_delete: Sei sicuro di voler eliminare questo set amministrativo? Questa azione non può essere annullata. + index: + creator: Creatore + date_created: Data creata + no_administrative_sets_have_been_created: Non sono stati creati gruppi amministrativi. + title: Titolo + works: Lavori + show_document_list: + actions: Azioni + date_uploaded: Data caricata + list_of_items_in_this_administrative_set: Elenco delle voci in questo insieme amministrativo + status: Stato + title: Titolo + visibility: Visibilità + show_document_list_row: + creator: 'Creatore:' + depositor: 'Depositatore:' + edit_access: 'Modifica accesso:' + groups: 'Gruppi:' + users: 'Utenti:' analytics: collection_reports: custom_range: @@ -357,6 +377,7 @@ it: top_works: I migliori lavori work_title: Titolo del lavoro work_views: Visualizzazioni della pagina di lavoro + id: ID work_counts: child_works: bambino lavora files: File @@ -414,9 +435,11 @@ it: remove_success: Rimosso il partecipante submit: Inserisci update_notice: Aggiornamento dei partecipanti + as: come form_settings: instructions: Queste impostazioni determinano in che modo è possibile gestire e scoprire raccolte di questo tipo. warning: 'Avvertenza: queste impostazioni non possono essere modificate dopo aver creato una collezione di questo tipo.' + apply_to_new_works: APPLICAZIONE A NUOVI LAVORATORI index: breadcrumb: Tipi di raccolta create_new_button: Crea un nuovo tipo di raccolta @@ -447,6 +470,7 @@ it: description: Descrizione feature: Caratteristica header: Caratteristiche + status: Stato sidebar: activity: Attività analytics: Analisi @@ -498,6 +522,27 @@ it: main: Statistiche di lavoro total: 'Totale opere:' visibility: Totale per visibilità + date_form: + load_stats: Stats di carico + deposits: + deposited: depositato + deposits_by_users: Depositi dagli utenti + new_users: + newest_users: Utenti più recenti %{utenti} + of: di + registered: registrato + total: 'Totale:' + stats_by_date: + explanation: Le statistiche in questa sezione sono filtrate dalle date inserite nel modulo sottostante. I dati non sono filtrati a meno che il modulo di data non sia stato compilato. La data di inizio è richiesta e l'estremità predefinita è ora. + statistics_by_date: Statistiche per data + top_data: + explanation_with_limit: Le statistiche in questa sezione mostrano gli elementi top %{limit} per ogni categoria + most_actie_users: La maggior parte degli utenti attivi (top %{count}) + top_file_format: Formati file superiori (top %{count}) + top_file_formats_and_users: Formati di file e utenti + view_top: Visualizza top %{number} + workflows: + show_number_per_page: Mostra %{number}) per pagina users: index: access_label: Ultimo accesso @@ -621,6 +666,7 @@ it: header: actions: Azione title: Titolo della collezione + display_data_info: Questa tabella visualizzerà i dati solo se le opere sono assegnate alle collezioni form_permission: visibility: Visibilità Chi dovrebbe essere in grado di visualizzare o scaricare questo contenuto? form_permission_under_embargo: @@ -682,6 +728,7 @@ it: users: utenti workflow: Flusso di lavoro workflow_comments: Commenti sul flusso di lavoro + solr: Sol items: actions: Azioni date_uploaded: Data caricata @@ -739,6 +786,8 @@ it: previous_comments: Commenti precedenti review_comment: Commento di revisione title: Revisione e approvazione + member_of_collections: + member_of_collections: Membro delle Collezioni base/unauthorized: is_private: Lo %{type} a cui hai provato ad accedere è privato unauthorized: non autorizzato @@ -765,6 +814,7 @@ it: permissions: permessi sharing: compartecipazione visibility: Visibilità + save_changes: Salvare le modifiche batch_uploads: disabled: Caratteristica disabilitata dall'amministratore files: @@ -784,6 +834,9 @@ it: citations: work: citation_formats: Formati di citazione + apa: APA + chicago: Chicago + mla: MLA collection: actions: add_existing_works: @@ -886,6 +939,10 @@ it: featured_researcher: Ricercatore in primo piano marketing_text: Testo di marketing updated: Blocchi di contenuto aggiornati. + form: + announcement: annuncio + marketing: marketing + researcher: ricercatore controls: about: Di contact: contatto @@ -1041,6 +1098,8 @@ it: creator: 'Creatore:' depositor: 'Depositante:' edit_access: 'Modifica accesso:' + groups: 'Gruppi:' + users: 'Utenti:' sort_and_per_page: show_par_page_html: Mostra %{select} per pagina sort_by: 'Ordina Per:' @@ -1383,6 +1442,8 @@ it: save: Salva revisione save_your_note: Devi fare clic su "Salva revisione" per ripristinare una versione precedente di questo file upload: Carica nuova versione + asset_permissions_denial_flash: + message: Il file(i) %{files} non potrebbe essere aggiornato. Non hai privilegi sufficienti per modificarlo." help: header: Supporto utente override_text: Utilizza app / views / static / help.html.erb per ignorare questo file. @@ -1544,6 +1605,13 @@ it: status: Stato title: operazioni updated: aggiornato + show: + message_header: Messaggio + message_label: 'Messaggio:' + operation_type_header: Tipo di operazione + status: stato + status_header: Stato + status_label: 'Stato:' pages: cancel: Annulla tabs: @@ -1552,6 +1620,11 @@ it: help_page: Pagina di aiuto terms_page: Condizioni d'uso updated: Pagine aggiornate. + form: + about: circa + agreement: accordo + help: aiuto + terms: termini passive_consent_to_agreement: Salvo questo lavoro accetto il permission_levels: edit: Accesso in modifica @@ -1614,6 +1687,10 @@ it: help: '%{application_name} non è stato in grado di individuare il collegamento monouso. Questo link è scaduto o era stato utilizzato in precedenza. Ci scusiamo per il disagio. Potresti essere interessato a utilizzare la pagina di aiuto per cercare soluzioni.' link_expired_not_found: Link monouso scaduto o non trovato link_not_found: Link monouso non trovato + show: + actions: Azioni + descriptions: 'Descrizioni:' + download: Scarica (può essere utilizzato solo una volta) sort_label: Ordina l'elenco degli articoli static: mendeley: @@ -1747,6 +1824,7 @@ it: activity_log: date: Data user_activity: Attività dell'utente + no_user_activity: Nessuna attività utente index: avatar: Avatar department: Dipartimento @@ -1761,6 +1839,19 @@ it: search_form: go: Partire search_users: Cerca utenti + user_info: + administrative_area: Spazio amministrativo + affiliation: Affiliazione + chat_id: ID chat + department: Dipartimento + email: Email + facebook_handle: Maniglia Facebook + linkedin: LinkedIn + office: Ufficio + telephone: Telefono + title: Titolo + twitter_handle: Gestione Twitter + website: Sito web(i) virus_scanner: virus_detected: Virus rilevato in %{filename}. Il file non è stato salvato. visibility: @@ -1818,6 +1909,10 @@ it: no_preview: nessuna anteprima disponibile update: header: Modifica lavoro + permissions: + confirm: + confirm: Si', per favore. + deny: No, lo aggiornero' manualmente. simple_form: hints: admin_set: @@ -1919,3 +2014,17 @@ it: total_view: one: Quest'opera ha 1 vista totale other: Questo lavoro ha %{count} visualizzazioni totali + catalog: + edit_partials: + default_details: + title: 'Titolo:' + layouts: + error: + system_error: Errore di sistema + shared: + nav_safety_modal: + cancel: Annulla + ok: OK + schema_version: + created_on_version: Creato sulla versione + version_after_save: Versione dopo il salvataggio
    <%= I18n.t("hyrax.admin.admin_sets.index.title", :default => "Title") %>