Skip to content

Commit 60f9df4

Browse files
Improve locale (#5371)
* Add 'remove' key to locale files * Add 'releases' key to locale files * Refactor japanese locale * Replace text with locale text * Remove unnecessary placeholder
1 parent 94ebcdb commit 60f9df4

File tree

15 files changed

+35
-17
lines changed

15 files changed

+35
-17
lines changed

app/views/layouts/application.html.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
</a>
5151
<% end %>
5252

53-
<%= link_to "Releases", news_url, class: "header__nav-link #{active?(news_path)}" %>
53+
<%= link_to t('.footer.releases'), news_url, class: "header__nav-link #{active?(news_path)}" %>
5454
<%= link_to t('.footer.blog'), "https://blog.rubygems.org", class: "header__nav-link" %>
5555

5656
<%- if request.path_info == '/gems' %>

app/views/owners/_owners_table.html.erb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,13 +50,13 @@
5050
<%= ownership.confirmed_at.strftime("%Y-%m-%d %H:%M %Z") if ownership.confirmed? %>
5151
</td>
5252
<td class="owners__cell" data-title="Action">
53-
<%= button_to "Remove",
53+
<%= button_to t("remove"),
5454
rubygem_owner_path(@rubygem.slug, ownership.user.display_id),
5555
method: "delete",
5656
data: { confirm: t("owners.index.confirm_remove") },
5757
class: "form__submit form__submit--small" %>
5858
<br/>
59-
<%= button_to "Edit",
59+
<%= button_to t("edit"),
6060
edit_rubygem_owner_path(@rubygem.name, ownership.user.display_id),
6161
disabled: ownership.user == current_user,
6262
method: "get",

app/views/passwords/edit.html.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<%= form_for(:password_reset, url: password_path, html: { method: :put }) do |form| %>
44
<%= error_messages_for @user %>
55
<div class="password_field">
6-
<%= form.label :password, "Password", :class => 'form__label' %>
6+
<%= form.label :password, t("activerecord.attributes.user.password"), :class => 'form__label' %>
77
<%= form.password_field :password, autocomplete: 'new-password', class: 'form__input' %>
88
</div>
99
<div class="form__checkbox">

app/views/profiles/delete.html.erb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@
3030
<p><%= t '.instructions' %></p>
3131
<%= form_for current_user, url: destroy_profile_path, method: :delete do |form| %>
3232
<div class="password_field">
33-
<%= form.label :password, "Password", class: 'form__label' %>
34-
<%= form.password_field :password, placeholder: 'password', autocomplete: 'current-password', class: 'form__input' %>
33+
<%= form.label :password, t("activerecord.attributes.user.password"), class: 'form__label' %>
34+
<%= form.password_field :password, autocomplete: 'current-password', class: 'form__input' %>
3535
</div>
3636
<%= form.submit t('.confirm'), data: { confirm: "This action can't be UNDONE! Are you sure?" }, class: 'form__submit' %>
3737
<% end %>

app/views/profiles/edit.html.erb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@
6262
</div>
6363

6464
<div class="password_field">
65-
<%= form.label :password, :class => 'form__label' %>
65+
<%= form.label :password, t("activerecord.attributes.user.password"), :class => 'form__label' %>
6666
<p class='form__field__instructions'>
6767
<%= t('.enter_password') %>
6868
</p>
@@ -76,7 +76,7 @@
7676
</div>
7777

7878
<div class="submit_field">
79-
<%= form.submit 'Update', :data => {:disable_with => t('form_disable_with')}, :class => 'form__submit' %>
79+
<%= form.submit t("update"), :data => {:disable_with => t('form_disable_with')}, :class => 'form__submit' %>
8080
</div>
8181
<% end %>
8282

app/views/settings/edit.html.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@
7171

7272
<div class="t-body">
7373
<h2><%= link_to t('oidc.pending_trusted_publishers.index.title'), profile_oidc_pending_trusted_publishers_path %></h2>
74-
<span>Pending trusted publishers allow you to configure trusted publishing before you have pushed the first version of a gem. For more information about how to set up trusted publishing, see <a href="https://guides.rubygems.org/trusted-publishing/pushing-a-new-gem/">the trusted publishing documentation</a>.</span>
74+
<span><%= t("oidc.pending_trusted_publishers.index.description_html") %></span>
7575
</div>
7676

7777
<% if @user.oidc_api_key_roles.any? %>

config/locales/de.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ de:
5151
total_downloads: Downloads insgesamt
5252
try_again: Etwas ist schiefgelaufen. Bitte versuchen Sie es erneut.
5353
update: Aktualisieren
54+
remove:
5455
view_all: Alle anzeigen
5556
advanced_search: Erweiterte Suche
5657
authenticate: Authentifizieren
@@ -263,6 +264,7 @@ de:
263264
hosted_by: Gehostet von
264265
monitored_by: Überwacht von
265266
optimized_by: Optimiert mit
267+
releases:
266268
resolved_with: Aufgelöst mit
267269
security: Security
268270
source_code: Code

config/locales/en.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ en:
4848
total_downloads: Total downloads
4949
try_again: Something went wrong. Please try again.
5050
update: Update
51+
remove: Remove
5152
view_all: View all
5253
advanced_search: Advanced Search
5354
authenticate: Authenticate
@@ -249,6 +250,7 @@ en:
249250
hosted_by: Hosted by
250251
monitored_by: Monitored by
251252
optimized_by: Optimized by
253+
releases: Releases
252254
resolved_with: Resolved with
253255
security: Security
254256
source_code: Code

config/locales/es.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ es:
4949
total_downloads: Total de descargas
5050
try_again: Algo salió mal. Por favor inténtalo nuevamente.
5151
update: Actualizar
52+
remove:
5253
view_all: Ver todo
5354
advanced_search: Búsqueda avanzada
5455
authenticate: Autenticar
@@ -262,6 +263,7 @@ es:
262263
hosted_by: Alojado por
263264
monitored_by: Monitoreado por
264265
optimized_by: Optimizado por
266+
releases:
265267
resolved_with: DNS
266268
security: Seguridad
267269
source_code: Código fuente

config/locales/fr.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ fr:
4949
total_downloads: Total de téléchargements
5050
try_again: Une erreur est survenue. Veuillez réessayer.
5151
update: Mise à jour
52+
remove:
5253
view_all: Voir tout
5354
advanced_search: Recherche avancée
5455
authenticate:
@@ -254,6 +255,7 @@ fr:
254255
hosted_by: Hébergé par
255256
monitored_by: Monitoring par
256257
optimized_by: Optimisé par
258+
releases:
257259
resolved_with: Résolu par
258260
security: Security
259261
source_code: Code

0 commit comments

Comments
 (0)