From: Andy Allan Date: Wed, 25 Apr 2018 08:48:52 +0000 (+0800) Subject: Lazy translation lookups and key renames for help page. X-Git-Tag: live~3043^2 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/af4003e2eee24883318212e79f46d2ba4d2b9dbd Lazy translation lookups and key renames for help page. --- diff --git a/app/views/site/help.html.erb b/app/views/site/help.html.erb index dff2108ca..085ea63d5 100644 --- a/app/views/site/help.html.erb +++ b/app/views/site/help.html.erb @@ -1,18 +1,18 @@ <% content_for :heading do %> -

<%= t "help_page.title" %>

+

<%= t ".title" %>

<% end %> -

<%= t "help_page.introduction" %>

+

<%= t ".introduction" %>

<% ['welcome', 'beginners_guide', 'help', 'mailing_lists', 'forums', 'irc', 'switch2osm', 'wiki'].each do |site| %> <% unless site == 'welcome' && !current_user %>

- - <%= t "help_page.#{site}.title" %> + + <%= t ".#{site}.title" %>

-

<%= t "help_page.#{site}.description" %>

+

<%= t ".#{site}.description" %>

<% end %> <% end %> diff --git a/config/locales/en.yml b/config/locales/en.yml index a56aa0a57..c273836a6 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -968,43 +968,6 @@ en: text: Make a Donation learn_more: "Learn More" more: More - help_page: - title: Getting Help - introduction: | - OpenStreetMap has several resources for learning about the project, asking and answering questions, - and collaboratively discussing and documenting mapping topics. - welcome: - url: /welcome - title: Welcome to OSM - description: Start with this quick guide covering the OpenStreetMap basics. - beginners_guide: - url: https://wiki.openstreetmap.org/wiki/Beginners%27_guide - title: Beginners' Guide - description: Community maintained guide for beginners. - help: - url: https://help.openstreetmap.org/ - title: help.openstreetmap.org - description: Ask a question or look up answers on OSM's question-and-answer site. - mailing_lists: - url: https://lists.openstreetmap.org/ - title: Mailing Lists - description: Ask a question or discuss interesting matters on a wide range of topical or regional mailing lists. - forums: - url: https://forum.openstreetmap.org/ - title: Forums - description: Questions and discussions for those that prefer a bulletin board style interface. - irc: - url: https://irc.openstreetmap.org/ - title: IRC - description: Interactive chat in many different languages and on many topics. - switch2osm: - url: https://switch2osm.org/ - title: switch2osm - description: Help for companies and organisations switching to OpenStreetMap based maps and other services. - wiki: - url: https://wiki.openstreetmap.org/ - title: wiki.openstreetmap.org - description: Browse the wiki for in-depth OSM documentation. notifier: diary_comment_notification: subject: "[OpenStreetMap] %{user} commented on a diary entry" @@ -1416,6 +1379,43 @@ en: If you have concerns about how our data is being used or about the contents please consult our copyright page for more legal information, or contact the appropriate OSMF working group. + help: + title: Getting Help + introduction: | + OpenStreetMap has several resources for learning about the project, asking and answering questions, + and collaboratively discussing and documenting mapping topics. + welcome: + url: /welcome + title: Welcome to OSM + description: Start with this quick guide covering the OpenStreetMap basics. + beginners_guide: + url: https://wiki.openstreetmap.org/wiki/Beginners%27_guide + title: Beginners' Guide + description: Community maintained guide for beginners. + help: + url: https://help.openstreetmap.org/ + title: help.openstreetmap.org + description: Ask a question or look up answers on OSM's question-and-answer site. + mailing_lists: + url: https://lists.openstreetmap.org/ + title: Mailing Lists + description: Ask a question or discuss interesting matters on a wide range of topical or regional mailing lists. + forums: + url: https://forum.openstreetmap.org/ + title: Forums + description: Questions and discussions for those that prefer a bulletin board style interface. + irc: + url: https://irc.openstreetmap.org/ + title: IRC + description: Interactive chat in many different languages and on many topics. + switch2osm: + url: https://switch2osm.org/ + title: switch2osm + description: Help for companies and organisations switching to OpenStreetMap based maps and other services. + wiki: + url: https://wiki.openstreetmap.org/ + title: wiki.openstreetmap.org + description: Browse the wiki for in-depth OSM documentation. sidebar: search_results: Search Results close: Close