https://github.com/khan/discourse-crowdin-link
Discourse theme component to auto-localize Crowdin links per users language on Khan Academy international forum
https://github.com/khan/discourse-crowdin-link
crowdin discourse
Last synced: about 2 months ago
JSON representation
Discourse theme component to auto-localize Crowdin links per users language on Khan Academy international forum
- Host: GitHub
- URL: https://github.com/khan/discourse-crowdin-link
- Owner: Khan
- License: mit
- Created: 2021-04-13T21:32:38.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2021-04-14T00:20:27.000Z (over 4 years ago)
- Last Synced: 2025-06-08T16:02:35.410Z (4 months ago)
- Topics: crowdin, discourse
- Language: JavaScript
- Homepage: https://international-forum.khanacademy.org/
- Size: 33.2 KB
- Stars: 0
- Watchers: 42
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Auto-localize Crowdin links
This is a [Discourse theme component](https://meta.discourse.org/t/structure-of-themes-and-theme-components/60848) that is used in Khan Academy i18n forum at https://international-forum.khanacademy.org/
The component auto-localizes Crowdin links such "https://crowdin.com/translate/khanacademy/26335/enus-XX#6550144" into a link targeting a user-specific language. For example, a Czech translator will see "https://crowdin.com/translate/khanacademy/26335/enus-cs#6550144".
The user language is taken from their profile. Specifically, we're using a custom user field "Language" defined [here](https://international-forum.khanacademy.org/admin/customize/user_fields) and we require each new user to fill it during registration.
## For DEVS
If a new language is added to Khan Academy, its crowdin code needs to be added into
`javascripts/discourse-crowdin-link/lib/languages.js.es6`As of 7th March 2020, the list should contain all languages found at https://crowdin.com/project/khanacademy, even those that not yet officially started and do not have their Translation Dashboard.