intellij-emberjs icon indicating copy to clipboard operation
intellij-emberjs copied to clipboard

Missing Translation

Open ghost opened this issue 5 years ago • 6 comments

I get a missing translation in all my templates. Completion works but the preview of translated string not.

bildschirmfoto 2018-09-27 um 12 22 32

ghost avatar Sep 27 '18 10:09 ghost

can you reproduce this in a fresh new ember app?

Turbo87 avatar Sep 27 '18 10:09 Turbo87

@Turbo87 , I’ll do it next week when I’m back at office

ghost avatar Sep 27 '18 12:09 ghost

Before I forget I use ember-intl

ghost avatar Sep 27 '18 12:09 ghost

It could be caused by new ember-intl configs not using baseLocale anymore. The ember-intl code searches for its value https://github.com/Turbo87/intellij-emberjs/blob/master/src/main/kotlin/com/emberjs/translations/EmberIntlBaseLocaleFinder.kt#L12

With falling back through baseLocale, en-us and en it won't find the correct translation if the project uses a new ember-intl version wihtout having en-us or en translations in place.

@onceatime can you provide us with more information, i.e. ember-intl version and your ember-intl configuration?

If this is really the cause, I could open a PR to fallback through all configured intl locales if that's ok.

makepanic avatar Sep 30 '18 16:09 makepanic

Im knocked out this week. I’ll try to test it ASAP.ä when I’m back on track. But the configuration fallback sounds cool. The best solution or maybe as a separate module or feature could be a dialogue where the user can choose what translations should be used.

ghost avatar Oct 01 '18 10:10 ghost

@makepanic my configuration is the default which comes with ember-intl (no changes).

emmber-intl version: 3.2.5

ghost avatar Oct 02 '18 11:10 ghost