From 064398ef7350a048d7aaee25f3d688e89638e59a Mon Sep 17 00:00:00 2001 From: Michael Walker Date: Thu, 16 Aug 2018 10:38:48 +0100 Subject: [PATCH 1/5] Add Arabic translations for navigation headings --- config/locales/ar.yml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/config/locales/ar.yml b/config/locales/ar.yml index 44881e7ec..65f4d915e 100644 --- a/config/locales/ar.yml +++ b/config/locales/ar.yml @@ -3,6 +3,15 @@ ar: direction: rtl language_names: ar: "العربية" + components: + related_navigation: + collections: "مجموعات" + external_links: "روابط خارجية" + policies: "سياسيات" + related_content: "محتوى ذو صلة" + topical_events: "أحداث ذات صلة بالموضوع" + topics: "المواضيع" + world_locations: "العالم" content_item: schema_name: announcement: From e4ddd2bbadc1d9b8d83861b8039f147b8051ce7b Mon Sep 17 00:00:00 2001 From: Michael Walker Date: Thu, 16 Aug 2018 10:40:17 +0100 Subject: [PATCH 2/5] Add Russian translations for navigation headings --- config/locales/ru.yml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/config/locales/ru.yml b/config/locales/ru.yml index cc67ab858..c8e340bf7 100644 --- a/config/locales/ru.yml +++ b/config/locales/ru.yml @@ -1,6 +1,15 @@ ru: language_names: ru: "Русский" + components: + related_navigation: + collections: "Коллекции" + external_links: "Внешние ссылки" + policies: "Политика" + related_content: "На эту тему" + topical_events: "Актуальные события" + topics: "Темы" + world_locations: "Страны, регионы, организации" content_item: schema_name: announcement: From e1e39867a08b6446fd0cbfd5017f2c09b5406e24 Mon Sep 17 00:00:00 2001 From: Michael Walker Date: Fri, 17 Aug 2018 09:27:26 +0100 Subject: [PATCH 3/5] Add missing Arabic translations --- config/locales/ar.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/config/locales/ar.yml b/config/locales/ar.yml index 65f4d915e..c0a7da144 100644 --- a/config/locales/ar.yml +++ b/config/locales/ar.yml @@ -12,6 +12,10 @@ ar: topical_events: "أحداث ذات صلة بالموضوع" topics: "المواضيع" world_locations: "العالم" + published_dates: + published: "تاريخ النشر %{date}" + publisher_metadata: + from: "من" content_item: schema_name: announcement: From 46589acc6ca2191266c43df224b9cb03325090ef Mon Sep 17 00:00:00 2001 From: Michael Walker Date: Fri, 17 Aug 2018 09:40:28 +0100 Subject: [PATCH 4/5] Localise the "Share this page" heading --- app/views/content_items/consultation.html.erb | 2 +- app/views/content_items/news_article.html.erb | 2 +- app/views/content_items/world_location_news_article.html.erb | 2 +- config/locales/ar.yml | 2 ++ config/locales/en.yml | 2 ++ 5 files changed, 7 insertions(+), 3 deletions(-) diff --git a/app/views/content_items/consultation.html.erb b/app/views/content_items/consultation.html.erb index 8dc09b85b..1413b1257 100644 --- a/app/views/content_items/consultation.html.erb +++ b/app/views/content_items/consultation.html.erb @@ -172,7 +172,7 @@ <%= render 'govuk_publishing_components/components/share_links', links: @content_item.share_links, track_as_sharing: true, - title: 'Share this page' + title: t('components.share_links.share_this_page') %> diff --git a/app/views/content_items/news_article.html.erb b/app/views/content_items/news_article.html.erb index e8c9ce569..df2b94d46 100644 --- a/app/views/content_items/news_article.html.erb +++ b/app/views/content_items/news_article.html.erb @@ -34,7 +34,7 @@ <%= render 'govuk_publishing_components/components/share_links', links: @content_item.share_links, track_as_sharing: true, - title: 'Share this page' + title: t('components.share_links.share_this_page') %> diff --git a/app/views/content_items/world_location_news_article.html.erb b/app/views/content_items/world_location_news_article.html.erb index d3b333687..ec1a9c0cf 100644 --- a/app/views/content_items/world_location_news_article.html.erb +++ b/app/views/content_items/world_location_news_article.html.erb @@ -35,7 +35,7 @@ <%= render 'govuk_publishing_components/components/share_links', links: @content_item.share_links, track_as_sharing: true, - title: 'Share this page' + title: t('components.share_links.share_this_page') %> diff --git a/config/locales/ar.yml b/config/locales/ar.yml index c0a7da144..0723fed84 100644 --- a/config/locales/ar.yml +++ b/config/locales/ar.yml @@ -4,6 +4,8 @@ ar: language_names: ar: "العربية" components: + share_links: + share_this_page: "شارك هذه الصفحة" related_navigation: collections: "مجموعات" external_links: "روابط خارجية" diff --git a/config/locales/en.yml b/config/locales/en.yml index e8b7e8fa6..1b0a345a7 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -26,6 +26,8 @@ en: common: last_updated: "Last updated" components: + share_links: + share_this_page: "Share this page" publisher_metadata: from: "From" collections: "Collections" From 9aacb19290d19ee3a0c84d3c32bd053fed7dd0dc Mon Sep 17 00:00:00 2001 From: Vanita Barrett Date: Fri, 17 Aug 2018 09:46:59 +0000 Subject: [PATCH 5/5] Handle RTL better in publisher metadata component --- .../components/_publisher-metadata.scss | 14 ++++++++++++++ app/views/components/docs/publisher-metadata.yml | 9 +++++++++ 2 files changed, 23 insertions(+) diff --git a/app/assets/stylesheets/components/_publisher-metadata.scss b/app/assets/stylesheets/components/_publisher-metadata.scss index b0d70dc16..94db82eee 100644 --- a/app/assets/stylesheets/components/_publisher-metadata.scss +++ b/app/assets/stylesheets/components/_publisher-metadata.scss @@ -11,4 +11,18 @@ .app-c-publisher-metadata__term { float: left; padding-right: $gutter-one-third / 2; + + .direction-rtl & { + float: none; + display: inline-block; + padding-right: 0; + padding-left: 5px; + } +} + +.app-c-publisher-metadata__definition { + .direction-rtl & { + float: none; + display: inline-block; + } } diff --git a/app/views/components/docs/publisher-metadata.yml b/app/views/components/docs/publisher-metadata.yml index d1d45bd7b..155818bb9 100644 --- a/app/views/components/docs/publisher-metadata.yml +++ b/app/views/components/docs/publisher-metadata.yml @@ -80,3 +80,12 @@ examples: data: other: Applies to: "England, Scotland, and Wales (see detailed guidance for Northern Ireland)" + right_to_left: + data: + published: 31 July 2017 + last_updated: 20 September 2017 + other: + from: + - Ministry of Defence + context: + right_to_left: true