From 32a400c5af2bd709f05caad751f4f97dcadc96ce Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Tue, 28 Aug 2018 18:02:32 +0100 Subject: [PATCH] Only include embed related messages in the embed javascript --- app/assets/javascripts/embed.js.erb | 3 ++- config/i18n-js.yml | 4 ++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/app/assets/javascripts/embed.js.erb b/app/assets/javascripts/embed.js.erb index 15839a2ec..36b23666a 100644 --- a/app/assets/javascripts/embed.js.erb +++ b/app/assets/javascripts/embed.js.erb @@ -1,6 +1,7 @@ //= require leaflet //= require leaflet.osm -//= require i18n/translations +//= require i18n +//= require i18n/embed window.onload = function () { if (navigator.languages) { diff --git a/config/i18n-js.yml b/config/i18n-js.yml index 0697bfe2e..fa970345f 100644 --- a/config/i18n-js.yml +++ b/config/i18n-js.yml @@ -14,3 +14,7 @@ translations: - "*.diary_entry.edit.marker_text" - "*.layouts.project_name.title" - "*.geocoder.search_osm_nominatim.*" + - file: "app/assets/javascripts/i18n/embed.js" + pretty_print: true + only: + - "*.javascripts.embed.*" -- 2.39.5