From 97ff32f5286bf9477829cbfb05f0f26dde128380 Mon Sep 17 00:00:00 2001 From: Andy Allan Date: Wed, 12 Jun 2019 16:07:18 +0200 Subject: [PATCH 1/1] Use built-in form sumbit translation keys for user blocks --- app/views/user_blocks/edit.html.erb | 2 +- app/views/user_blocks/new.html.erb | 2 +- config/locales/en.yml | 5 +++-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/app/views/user_blocks/edit.html.erb b/app/views/user_blocks/edit.html.erb index 6f0ea991b..88d7e4f23 100644 --- a/app/views/user_blocks/edit.html.erb +++ b/app/views/user_blocks/edit.html.erb @@ -25,6 +25,6 @@ <%= f.label :needs_view, t(".needs_view") %>

- <%= f.submit t(".submit") %> + <%= f.submit %>

<% end %> diff --git a/app/views/user_blocks/new.html.erb b/app/views/user_blocks/new.html.erb index aa4bf7132..bd492a354 100644 --- a/app/views/user_blocks/new.html.erb +++ b/app/views/user_blocks/new.html.erb @@ -21,7 +21,7 @@

<%= hidden_field_tag "display_name", @user.display_name %> - <%= f.submit t(".submit") %> + <%= f.submit %>

<% end %> diff --git a/config/locales/en.yml b/config/locales/en.yml index 6426ee56b..606077461 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -10,6 +10,9 @@ en: diary_entry: create: "Publish" update: "Update" + user_block: + create: Create block + update: Update block activerecord: errors: messages: @@ -2287,7 +2290,6 @@ en: heading: "Creating block on %{name}" reason: "The reason why %{name} is being blocked. Please be as calm and as reasonable as possible, giving as much detail as you can about the situation, remembering that the message will be publicly visible. Bear in mind that not all users understand the community jargon, so please try to use laymans terms." period: "How long, starting now, the user will be blocked from the API for." - submit: "Create block" tried_contacting: "I have contacted the user and asked them to stop." tried_waiting: "I have given a reasonable amount of time for the user to respond to those communications." needs_view: "User needs to log in before this block will be cleared" @@ -2297,7 +2299,6 @@ en: heading: "Editing block on %{name}" reason: "The reason why %{name} is being blocked. Please be as calm and as reasonable as possible, giving as much detail as you can about the situation. Bear in mind that not all users understand the community jargon, so please try to use laymans terms." period: "How long, starting now, the user will be blocked from the API for." - submit: "Update block" show: "View this block" back: "View all blocks" needs_view: "Does the user need to log in before this block will be cleared?" -- 2.43.2