Skip to end of metadata
Go to start of metadata

You are viewing an old version of this content. View the current version.

Compare with Current View Version History

« Previous Version 3 Next »

\uD83E\uDD14 Problem Statement

Right now, in order to add translations to a form, the way to do this to add it to a configuration folder that can be picked up by Iniz. This is annoying because

  1. You’d need a developer’s help to know what to do and where to do it

  2. The JSON file format is quite different from that of a form, so its not very intuitive for a non-techy person to do

  3. There’s no a dynamic and user-friendly way to do it

🧵 Project Size

Large

🎯 Why we need it?

In the day and age of content packages, this would be a method for people to re-use forms but customize it to their language in a user-friendly way.

(lightbulb)Project Idea

Similar to the interactive builder, a UI that would enable users to add the translations for a form for any language.

Here’s a (very high level) flow of how that might look like:

  1. A separate UI editor(from the interactive builder) to manage translations

  2. Preview the form in selected language and add language options

  3. Adding the translation strings

Obviously, this is not how the UI should look and neither are these mockups for the project. These are merely a guide to understand the use case.

🔨 Implementation

  1. A UI editor needs to be implemented to manage the translation strings for each question

    1. This can get tricky because we also need to consider the translations for answers

  2. The JSON editor needs to contain the translations within the JSON to support dynamically viewing the translations

  3. We need to figure out how to preview a form in a certain language

  4. Once a user clicks Save Translations the translation files should be saved in the backend as a form resource.

  5. Users should be able to download the translation resource file (check the reference materials to see what the file format should be) for a specific language

Although the idea itself seems simple, there’s a considerable amount of work that would require to make the entire UI and to manage multiple translations, and actually making the translation file resource itself.

\uD83D\uDD17 Reference materials

  1. An example form translation file in English - https://github.com/openmrs/openmrs-distro-referenceapplication/blob/main/distro/configuration/ampathformstranslations/Ampath%20POC%20adult%20return%20visit%20form_translations_en-core_demo.json

  2. An example form translation in French - https://github.com/openmrs/openmrs-distro-referenceapplication/blob/main/distro/configuration/ampathformstranslations/Ampath%20POC%20adult%20return%20visit%20form_translations_fr-core_demo.json

  3. The original form itself - https://github.com/openmrs/openmrs-distro-referenceapplication/blob/main/distro/configuration/ampathforms/ampath_poc_adult_return_visit_form_v1.6_core-demo.json

  • No labels