Altinn / app-frontend-react

Altinn application React frontend
BSD 3-Clause "New" or "Revised" License
18 stars 31 forks source link

Expose used language in a way that allows putting into the data model #1661

Open RonnyB71 opened 10 months ago

RonnyB71 commented 10 months ago

Description

The users preferred language is set on the user profile and will be used when creating a new instance. However this does not necessarily reflect the actual langue being used. If the form isn't available on that language it will default to norwegian bokmål and if the application developer has included the language selector you can override your profile value and select something else.

The profile language is also available as a configurable prefill value. So having some sort of dynamic variable that can be inserted into a field in the data model would solve the problem. Service owners are required to answer in nynorsk if that is the the language the user used or bokmål if thats the language they used. So we need a way to submit the actual language code used, and not try to guess it based on some text input fields.

Additional Information

This should be solved in a way allows us to extend this concept to include other type of dynamic metadata or texts and values from components that are currently only available in frontend. For example we have the case of the actual text of a radio button/checkbox/dropdown and not only the value.

Tasks

No response

Acceptance Criterias

No response

olemartinorg commented 8 months ago

Thread about this: