]> git.openstreetmap.org Git - rails.git/commitdiff
separate translatable messages for privacy policy link in sign up form
authorEmin Kocan <kocanmn.dev@gmail.com>
Mon, 1 Jul 2024 16:35:43 +0000 (18:35 +0200)
committerEmin Kocan <kocanmn.dev@gmail.com>
Mon, 1 Jul 2024 16:35:43 +0000 (18:35 +0200)
app/views/users/new.html.erb
config/locales/en.yml

index c0cef51d99348a787e9ae7bf564a223cfc5f45d0..b87244b9f42f8b0842fc1575a1276f9578a2580f 100644 (file)
     <%= f.hidden_field :auth_uid unless current_user.auth_uid.nil? %>
 
     <% if current_user.auth_uid.nil? or @email_hmac.nil? or not current_user.errors[:email].empty? %>
     <%= f.hidden_field :auth_uid unless current_user.auth_uid.nil? %>
 
     <% if current_user.auth_uid.nil? or @email_hmac.nil? or not current_user.errors[:email].empty? %>
-      <%= f.email_field :email, :help => t(".email_help_html",
-                                           :privacy_policy_link => link_to(t(".privacy_policy"),
-                                                                           t(".privacy_policy_url"),
-                                                                           :title => t(".privacy_policy_title"),
+      <%= f.email_field :email, :help => t(".email_help.html",
+                                           :privacy_policy_link => link_to(t(".email_help.privacy_policy"),
+                                                                           t(".email_help.privacy_policy_url"),
+                                                                           :title => t(".email_help.privacy_policy_title"),
                                                                            :target => :new)),
                                 :autofocus => true,
                                 :tabindex => 1 %>
                                                                            :target => :new)),
                                 :autofocus => true,
                                 :tabindex => 1 %>
       </div>
     <% end %>
 
       </div>
     <% end %>
 
-    <p class="mb-3 text-body-secondary fs-6"><%= t(".by_signing_up_html",
+    <p class="mb-3 text-body-secondary fs-6"><%= t(".by_signing_up.html",
                                                    :tou_link => link_to(t("layouts.tou"),
                                                                         "https://wiki.osmfoundation.org/wiki/Terms_of_Use",
                                                                         :target => :new),
                                                    :tou_link => link_to(t("layouts.tou"),
                                                                         "https://wiki.osmfoundation.org/wiki/Terms_of_Use",
                                                                         :target => :new),
-                                                   :privacy_policy_link => link_to(t(".privacy_policy"),
-                                                                                   t(".privacy_policy_url"),
-                                                                                   :title => t(".privacy_policy_title"),
+                                                   :privacy_policy_link => link_to(t(".by_signing_up.privacy_policy"),
+                                                                                   t(".by_signing_up.privacy_policy_url"),
+                                                                                   :title => t(".by_signing_up.privacy_policy_title"),
                                                                                    :target => :new),
                                                                                    :target => :new),
-                                                   :contributor_terms_link => link_to(t(".contributor_terms"),
-                                                                                      t(".contributor_terms_url"),
+                                                   :contributor_terms_link => link_to(t(".by_signing_up.contributor_terms"),
+                                                                                      t(".by_signing_up.contributor_terms_url"),
                                                                                       :target => :new)) %></p>
     <%= f.form_group do %>
       <%= f.check_box :consider_pd,
                                                                                       :target => :new)) %></p>
     <%= f.form_group do %>
       <%= f.check_box :consider_pd,
index 6c90eacc9ea1e603dd5817dd06d710a4f8c7e078..d0ee7165d948723d4cb5fe73ec8c99a8104c96a2 100644 (file)
@@ -2752,17 +2752,22 @@ en:
         welcome: "Welcome to OpenStreetMap"
       duplicate_social_email: "If you already have an OpenStreetMap account and wish to use a 3rd party identity provider, please log in using your password and modify the settings of your account."
       display name description: "Your publicly displayed username. You can change this later in the preferences."
         welcome: "Welcome to OpenStreetMap"
       duplicate_social_email: "If you already have an OpenStreetMap account and wish to use a 3rd party identity provider, please log in using your password and modify the settings of your account."
       display name description: "Your publicly displayed username. You can change this later in the preferences."
-      by_signing_up_html: "By signing up, you agree to our %{tou_link}, %{privacy_policy_link} and %{contributor_terms_link}."
+      by_signing_up:
+        html: "By signing up, you agree to our %{tou_link}, %{privacy_policy_link} and %{contributor_terms_link}."
+        privacy_policy: privacy policy
+        privacy_policy_url: https://wiki.osmfoundation.org/wiki/Privacy_Policy
+        privacy_policy_title: OSMF privacy policy including section on email addresses
+        contributor_terms_url: "https://wiki.osmfoundation.org/wiki/Licence/Contributor_Terms"
+        contributor_terms: "contributor terms"
       tou: "terms of use"
       tou: "terms of use"
-      contributor_terms_url: "https://wiki.osmfoundation.org/wiki/Licence/Contributor_Terms"
-      contributor_terms: "contributor terms"
       external auth: "Third Party Authentication:"
       continue: Sign Up
       terms accepted: "Thanks for accepting the new contributor terms!"
       external auth: "Third Party Authentication:"
       continue: Sign Up
       terms accepted: "Thanks for accepting the new contributor terms!"
-      email_help_html: 'Your address is not displayed publicly, see our %{privacy_policy_link} for more information.'
-      privacy_policy: privacy policy
-      privacy_policy_url: https://wiki.osmfoundation.org/wiki/Privacy_Policy
-      privacy_policy_title: OSMF privacy policy including section on email addresses
+      email_help:
+        privacy_policy: privacy policy
+        privacy_policy_url: https://wiki.osmfoundation.org/wiki/Privacy_Policy
+        privacy_policy_title: OSMF privacy policy including section on email addresses
+        html: 'Your address is not displayed publicly, see our %{privacy_policy_link} for more information.'
       consider_pd_html: "I consider my contributions to be in the %{consider_pd_link}."
       consider_pd: "public domain"
       consider_pd_url: https://wiki.osmfoundation.org/wiki/Licence_and_Legal_FAQ/Why_would_I_want_my_contributions_to_be_public_domain
       consider_pd_html: "I consider my contributions to be in the %{consider_pd_link}."
       consider_pd: "public domain"
       consider_pd_url: https://wiki.osmfoundation.org/wiki/Licence_and_Legal_FAQ/Why_would_I_want_my_contributions_to_be_public_domain