-
-
Notifications
You must be signed in to change notification settings - Fork 686
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multi-language support #1458
Comments
Using the API is the way to go. What do you mean "no luck" ? Please explain what you get. I just tried So at least it is working for the navbar buttons. (might no be the case for other labels in some plugins) |
So, I moved a bunch of stuff around and now translation works for the navbar buttons, the ones that are not being updated are the custom navbar buttons ( I don't know how to target those using |
For custom buttons you could declare For the markers button there is now reason it does not work, again For the plan widget that's one of the thing that really needs to be fixed. |
Fixed the Also added an optionnal lookup of custom buttons lang: {
myButton: 'Click here',
},
navbar: [{
title: 'myButton`,
...
}] |
This feature/bug fix has been released in version 5.11.0. |
Describe the feature
When changing language, using
i18next
the viewer requires a reload in order to see all thePSV
button tooltips translated. It would be helpful to have built-in support for multiple languages without requiring a manual page refresh to see the new language in place.Alternatives you've considered
I've tried to add
language
as dependency to the viewer configuration so that when It changes, the viewer would reload or re-render but this only made the viewer crash.I've also tried to update the tooltips programmatically when the language changed with no luck:
Additional context
I am working on a project where there is implemented language switching using
i18next
and if the language is switched when the viewer is visible, it takes a manual page refresh to see It take effect, as all PSV tooltips still display on the previous language. language switching is implemented usingi18next. This is how the
langproperty on the viewer configuration is set up using
react-i18next`:The text was updated successfully, but these errors were encountered: