From: Andy Allan Date: Wed, 25 Apr 2018 08:33:10 +0000 (+0800) Subject: Use lazy lookups and rename keys for the copyright page X-Git-Tag: live~3047^2~3 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/c7e514a56b7b420ebe3d32a9ad2d6751587b1faa Use lazy lookups and rename keys for the copyright page --- diff --git a/app/views/site/copyright.html.erb b/app/views/site/copyright.html.erb index 887782be2..1b85d201c 100644 --- a/app/views/site/copyright.html.erb +++ b/app/views/site/copyright.html.erb @@ -2,15 +2,15 @@ <% if @locale == 'en' %> - <% if t('license_page.legal_babble', :locale => I18n.locale) != t('license_page.legal_babble', :locale => :en) %> -

<%= t 'license_page.native.title' %>

+ <% if t('.legal_babble', :locale => I18n.locale) != t('.legal_babble', :locale => :en) %> +

<%= t '.native.title' %>

- <%= raw t 'license_page.native.text', - :native_link => link_to(t('license_page.native.native_link'), + <%= raw t '.native.text', + :native_link => link_to(t('.native.native_link'), :controller => 'site', :action => 'copyright', :copyright_locale => nil), - :mapping_link => link_to(t('license_page.native.mapping_link'), + :mapping_link => link_to(t('.native.mapping_link'), :controller => 'site', :action => 'index') %>

@@ -18,11 +18,11 @@ <% end %> <% else %> - <% if t('license_page.legal_babble', :locale => @locale) != t('license_page.legal_babble', :locale => :en) %> -

<%= t 'license_page.foreign.title' %>

+ <% if t('.legal_babble', :locale => @locale) != t('.legal_babble', :locale => :en) %> +

<%= t '.foreign.title' %>

- <%= raw t 'license_page.foreign.text', - :english_original_link => link_to(t('license_page.foreign.english_link'), + <%= raw t '.foreign.text', + :english_original_link => link_to(t('.foreign.english_link'), :controller => 'site', :action => 'copyright', :copyright_locale => 'en') %> @@ -31,46 +31,46 @@ <% end %> <% end %> -

<%= t "license_page.legal_babble.title_html", :locale => @locale %>

+

<%= t ".legal_babble.title_html", :locale => @locale %>

<% end %> -

<%= t "license_page.legal_babble.intro_1_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.intro_2_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.intro_3_html", :locale => @locale %>

+

<%= t ".legal_babble.intro_1_html", :locale => @locale %>

+

<%= t ".legal_babble.intro_2_html", :locale => @locale %>

+

<%= t ".legal_babble.intro_3_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.credit_title_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.credit_1_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.credit_2_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.credit_3_html", :locale => @locale %>

+

<%= t ".legal_babble.credit_title_html", :locale => @locale %>

+

<%= t ".legal_babble.credit_1_html", :locale => @locale %>

+

<%= t ".legal_babble.credit_2_html", :locale => @locale %>

+

<%= t ".legal_babble.credit_3_html", :locale => @locale %>

<%= image_tag("attribution_example.png", - :alt => t('license_page.legal_babble.attribution_example.alt'), + :alt => t('.legal_babble.attribution_example.alt'), :border => 0, - :title => t('license_page.legal_babble.attribution_example.title')) %> + :title => t('.legal_babble.attribution_example.title')) %> -

<%= t "license_page.legal_babble.more_title_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.more_1_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.more_2_html", :locale => @locale %>

+

<%= t ".legal_babble.more_title_html", :locale => @locale %>

+

<%= t ".legal_babble.more_1_html", :locale => @locale %>

+

<%= t ".legal_babble.more_2_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.contributors_title_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.contributors_intro_html", :locale => @locale %>

+

<%= t ".legal_babble.contributors_title_html", :locale => @locale %>

+

<%= t ".legal_babble.contributors_intro_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.contributors_footer_1_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.contributors_footer_2_html", :locale => @locale %>

+

<%= t ".legal_babble.contributors_footer_1_html", :locale => @locale %>

+

<%= t ".legal_babble.contributors_footer_2_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.infringement_title_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.infringement_1_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.infringement_2_html", :locale => @locale %>

+

<%= t ".legal_babble.infringement_title_html", :locale => @locale %>

+

<%= t ".legal_babble.infringement_1_html", :locale => @locale %>

+

<%= t ".legal_babble.infringement_2_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.trademarks_title_html", :locale => @locale %>

-

<%= t "license_page.legal_babble.trademarks_1_html", :locale => @locale %>

+

<%= t ".legal_babble.trademarks_title_html", :locale => @locale %>

+

<%= t ".legal_babble.trademarks_1_html", :locale => @locale %>

diff --git a/config/locales/en.yml b/config/locales/en.yml index 2270c9d33..fca925e2c 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -1009,132 +1009,6 @@ en: text: Make a Donation learn_more: "Learn More" more: More - license_page: - foreign: - title: About this translation - text: In the event of a conflict between this translated page and %{english_original_link}, the English page shall take precedence - english_link: the English original - native: - title: About this page - text: You are viewing the English version of the copyright page. You can go back to the %{native_link} of this page or you can stop reading about copyright and %{mapping_link}. - native_link: THIS_LANGUAGE_NAME_HERE version - mapping_link: start mapping - legal_babble: - title_html: Copyright and License - intro_1_html: | - OpenStreetMap® is open data, licensed under the Open Data - Commons Open Database License (ODbL) by the OpenStreetMap Foundation (OSMF). - intro_2_html: | - You are free to copy, distribute, transmit and adapt our data, - as long as you credit OpenStreetMap and its - contributors. If you alter or build upon our data, you - may distribute the result only under the same licence. The - full legal - code explains your rights and responsibilities. - intro_3_html: | - The cartography in our map tiles, and our documentation, are - licensed under the Creative - Commons Attribution-ShareAlike 2.0 license (CC BY-SA). - credit_title_html: How to credit OpenStreetMap - credit_1_html: | - We require that you use the credit “© OpenStreetMap - contributors”. - credit_2_html: | - You must also make it clear that the data is available under the Open - Database License, and if using our map tiles, that the cartography is - licensed as CC BY-SA. You may do this by linking to - this copyright page. - Alternatively, and as a requirement if you are distributing OSM in a - data form, you can name and link directly to the license(s). In media - where links are not possible (e.g. printed works), we suggest you - direct your readers to openstreetmap.org (perhaps by expanding - 'OpenStreetMap' to this full address), to opendatacommons.org, and - if relevant, to creativecommons.org. - credit_3_html: | - For a browsable electronic map, the credit should appear in the corner of the map. - For example: - attribution_example: - alt: Example of how to attribute OpenStreetMap on a webpage - title: Attribution example - more_title_html: Finding out more - more_1_html: | - Read more about using our data, and how to credit us, at the OSMF Licence page. - more_2_html: | - Although OpenStreetMap is open data, we cannot provide a - free-of-charge map API for third-parties. - See our API Usage Policy, - Tile Usage Policy - and Nominatim Usage Policy. - contributors_title_html: Our contributors - contributors_intro_html: | - Our contributors are thousands of individuals. We also include - openly-licensed data from national mapping agencies - and other sources, among them: - contributors_at_html: | - Austria: Contains data from - Stadt Wien (under - CC BY), - Land Vorarlberg and - Land Tirol (under CC BY AT with amendments). - contributors_ca_html: | - Canada: Contains data from - GeoBase®, GeoGratis (© Department of Natural - Resources Canada), CanVec (© Department of Natural - Resources Canada), and StatCan (Geography Division, - Statistics Canada). - contributors_fi_html: | - Finland: Contains data from the - National Land Survey of Finland's Topographic Database - and other datasets, under the - NLSFI License. - contributors_fr_html: | - France: Contains data sourced from - Direction Générale des Impôts. - contributors_nl_html: | - Netherlands: Contains © AND data, 2007 - (www.and.com) - contributors_nz_html: | - New Zealand: Contains data sourced from - Land Information New Zealand. Crown Copyright reserved. - contributors_si_html: | - Slovenia: Contains data from the - Surveying and Mapping Authority and - Ministry of Agriculture, Forestry and Food - (public information of Slovenia). - contributors_za_html: | - South Africa: Contains data sourced from - Chief Directorate: - National Geo-Spatial Information, State copyright reserved. - contributors_gb_html: | - United Kingdom: Contains Ordnance - Survey data © Crown copyright and database right - 2010-12. - contributors_footer_1_html: | - For further details of these, and other sources that have been used - to help improve OpenStreetMap, please see the Contributors - page on the OpenStreetMap Wiki. - contributors_footer_2_html: | - Inclusion of data in OpenStreetMap does not imply that the original - data provider endorses OpenStreetMap, provides any warranty, or - accepts any liability. - infringement_title_html: Copyright infringement - infringement_1_html: | - OSM contributors are reminded never to add data from any - copyrighted sources (e.g. Google Maps or printed maps) without - explicit permission from the copyright holders. - infringement_2_html: | - If you believe that copyrighted material has been inappropriately - added to the OpenStreetMap database or this site, please refer - to our takedown - procedure or file directly at our - on-line filing page. - trademarks_title_html: Trademarks - trademarks_1_html: | - OpenStreetMap, the magnifying glass logo and State of the Map are registered trademarks of the OpenStreetMap Foundation. If you have questions about your use of the marks, please see our Trademark Policy. fixthemap: title: Report a problem / Fix the map how_to_help: @@ -1393,6 +1267,132 @@ en:
OpenStreetMap, the magnifying glass logo and State of the Map are registered trademarks of the OSMF. partners_title: Partners + copyright: + foreign: + title: About this translation + text: In the event of a conflict between this translated page and %{english_original_link}, the English page shall take precedence + english_link: the English original + native: + title: About this page + text: You are viewing the English version of the copyright page. You can go back to the %{native_link} of this page or you can stop reading about copyright and %{mapping_link}. + native_link: THIS_LANGUAGE_NAME_HERE version + mapping_link: start mapping + legal_babble: + title_html: Copyright and License + intro_1_html: | + OpenStreetMap® is open data, licensed under the Open Data + Commons Open Database License (ODbL) by the OpenStreetMap Foundation (OSMF). + intro_2_html: | + You are free to copy, distribute, transmit and adapt our data, + as long as you credit OpenStreetMap and its + contributors. If you alter or build upon our data, you + may distribute the result only under the same licence. The + full legal + code explains your rights and responsibilities. + intro_3_html: | + The cartography in our map tiles, and our documentation, are + licensed under the Creative + Commons Attribution-ShareAlike 2.0 license (CC BY-SA). + credit_title_html: How to credit OpenStreetMap + credit_1_html: | + We require that you use the credit “© OpenStreetMap + contributors”. + credit_2_html: | + You must also make it clear that the data is available under the Open + Database License, and if using our map tiles, that the cartography is + licensed as CC BY-SA. You may do this by linking to + this copyright page. + Alternatively, and as a requirement if you are distributing OSM in a + data form, you can name and link directly to the license(s). In media + where links are not possible (e.g. printed works), we suggest you + direct your readers to openstreetmap.org (perhaps by expanding + 'OpenStreetMap' to this full address), to opendatacommons.org, and + if relevant, to creativecommons.org. + credit_3_html: | + For a browsable electronic map, the credit should appear in the corner of the map. + For example: + attribution_example: + alt: Example of how to attribute OpenStreetMap on a webpage + title: Attribution example + more_title_html: Finding out more + more_1_html: | + Read more about using our data, and how to credit us, at the OSMF Licence page. + more_2_html: | + Although OpenStreetMap is open data, we cannot provide a + free-of-charge map API for third-parties. + See our API Usage Policy, + Tile Usage Policy + and Nominatim Usage Policy. + contributors_title_html: Our contributors + contributors_intro_html: | + Our contributors are thousands of individuals. We also include + openly-licensed data from national mapping agencies + and other sources, among them: + contributors_at_html: | + Austria: Contains data from + Stadt Wien (under + CC BY), + Land Vorarlberg and + Land Tirol (under CC BY AT with amendments). + contributors_ca_html: | + Canada: Contains data from + GeoBase®, GeoGratis (© Department of Natural + Resources Canada), CanVec (© Department of Natural + Resources Canada), and StatCan (Geography Division, + Statistics Canada). + contributors_fi_html: | + Finland: Contains data from the + National Land Survey of Finland's Topographic Database + and other datasets, under the + NLSFI License. + contributors_fr_html: | + France: Contains data sourced from + Direction Générale des Impôts. + contributors_nl_html: | + Netherlands: Contains © AND data, 2007 + (www.and.com) + contributors_nz_html: | + New Zealand: Contains data sourced from + Land Information New Zealand. Crown Copyright reserved. + contributors_si_html: | + Slovenia: Contains data from the + Surveying and Mapping Authority and + Ministry of Agriculture, Forestry and Food + (public information of Slovenia). + contributors_za_html: | + South Africa: Contains data sourced from + Chief Directorate: + National Geo-Spatial Information, State copyright reserved. + contributors_gb_html: | + United Kingdom: Contains Ordnance + Survey data © Crown copyright and database right + 2010-12. + contributors_footer_1_html: | + For further details of these, and other sources that have been used + to help improve OpenStreetMap, please see the Contributors + page on the OpenStreetMap Wiki. + contributors_footer_2_html: | + Inclusion of data in OpenStreetMap does not imply that the original + data provider endorses OpenStreetMap, provides any warranty, or + accepts any liability. + infringement_title_html: Copyright infringement + infringement_1_html: | + OSM contributors are reminded never to add data from any + copyrighted sources (e.g. Google Maps or printed maps) without + explicit permission from the copyright holders. + infringement_2_html: | + If you believe that copyrighted material has been inappropriately + added to the OpenStreetMap database or this site, please refer + to our takedown + procedure or file directly at our + on-line filing page. + trademarks_title_html: Trademarks + trademarks_1_html: | + OpenStreetMap, the magnifying glass logo and State of the Map are registered trademarks of the OpenStreetMap Foundation. If you have questions about your use of the marks, please see our Trademark Policy. index: js_1: "You are either using a browser that does not support JavaScript, or you have disabled JavaScript." js_2: "OpenStreetMap uses JavaScript for its slippy map."