Allow changing the language
Description
Most of the translatable texts have been extracted to the translation files and we started working on an english translation. We could add a language switcher to the site
either only for the dev-environment to help with the translationor for everyone on the site, so that users can choose their own language
Since !1877 (merged) the language can be chosen when logged in. It would be nice if it could be chosen on public page even when not logged in, e.g. on the start page, the map, food baskets.
Proposa
A language icon/dropdown in the topbar or somewhere in the settings? The choosen language could be saved in fs_foodsaver
. Does symfony have a mechanism for changing the translation file?
The menu item that opens the language chooser dialog can be added to the topbar in its "logged out"-state. A problem is that the chosen locale is stored in the session, which only works when logged in. Maybe we could work with an Accept-Language
header instead, after switching the session management to symfony (https://symfony.com/doc/current/translation/locale.html)