Select a Translation Library for the Textual Elements in the UI

Description

Language should be locale-driven.

This ignores things like:

  • error messages from the backend

  • controlled vocabulary translations

Environment

None

Potential Workaround

None

Attachments

1
  • 09 Aug 2017, 02:44 PM

Checklist

hide

TestRail: Results

Activity

Show:

Mike Taylor August 15, 2017 at 2:45 PM

I've reviewed this – it's fine. Time to close.

Mike Taylor August 15, 2017 at 2:06 PM

I moved this from STRIPES to STCOR, since there is actual code to be included in the stripes-core v2.5.0 release.

Mike Taylor August 10, 2017 at 1:23 PM

Yes, a set of translation files per module makes sense.

I think we can defer the problem of fetching translations from a remote service for another day (and certainly another Jira issue)!

I merged your PR – very nice and clean.

Michal Kuklis August 10, 2017 at 12:03 PM
Edited

it looks like we will be able to use translations directly in strings: https://github.com/yahoo/react-intl/issues/749

I created initial PR for this work in stripes-core. There are a couple of things that we will still need to handle:

1. It would be nice if each stripes module (app, plugin) would manage its own translations. We will need to establish some patterns. It seems like having a folder called translations with json files (one file per language) should work well.
2. Stripes should look for these files during startup and combine/merge them together into one JSON file (per language), load it (this already happens in stripes-core) and provide it to <IntlProvider> (also part of the stripes-core now).
3. Based on the docs it seems like some people like to create translation files per component. This may be an overkill for stripes modules but perhaps it's a nice clean strategy for stripes-components.

During the call we also talked about fetching translations from a remote service.

1. Would we keep all translations in one place for all stripes modules / components?

Michal Kuklis August 9, 2017 at 7:20 PM

Thank you . I think I would like to do a little bit more research before we merge it. I want to look into the babel plugin and also see how we could introduce translations for each app. Yes the "fr" is for testing. I will clean that up.

Done

Details

Assignee

Reporter

Priority

Fix versions

TestRail: Cases

Open TestRail: Cases

TestRail: Runs

Open TestRail: Runs
Created July 21, 2017 at 11:14 AM
Updated August 28, 2017 at 12:43 PM
Resolved August 15, 2017 at 2:45 PM
TestRail: Cases
TestRail: Runs