-
-
Notifications
You must be signed in to change notification settings - Fork 413
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
Add feature to set application language. #902
Conversation
@akashnimare @timabbott @abhigyank Please review |
@abhigyank thanks, refactored according to your review. |
LGTM! |
A couple of doubts -
|
@akashnimare This PR for the app language ( to be used in menus and settings mostly), not related to spellchecker. |
@abhigyank that's right |
@akashnimare updated the border color to transparent
Yeah. I thought the user would use it often so kept it above but now it looks much coherent. Have a look! |
@manavmehta can you fix the merge conflicts? |
Looks good. Left a few comments. @abhigyank GTG? |
LGTM. |
User can now select application language without changing the language in the operating system Dynamically create locales object for dropdown Method: Store supported locales on disk in /translations/supported-locales.json and read in general-section.ts Why?: Avoids hardcoding of locales object and eases the process of adding next supported locales
Merged. Thanks, @manavmehta. |
@manavmehta as a follow-up can you take care of the translation thing we talked about? |
@akashnimare On it |
let langIndex = ConfigUtil.getConfigItem('languageIndex'); | ||
langIndex = (langIndex === null) ? 4 : langIndex; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Storing this as an index is extremely fragile—it means we can never reorder, insert, or delete languages without disturbing other languages.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed. Thanks @andersk :)
What's this PR do?
Fixes: #855
Adds feature that lets user to change Zulip desktop client language without requiring to change the system language as was the case earlier
Any background context you want to provide?
Earlier, Zulip client used to fetch system locale thus setting default language to the client. Now we enable user to set custom language to the client.
Screenshots?
You have tested this PR on:
[✓ ] macOS Catalina 10.15.2