-
Notifications
You must be signed in to change notification settings - Fork 35
Description
Overview
The CS Unplugged website should handle translations (see Django guide on translation).
Details
Online system for community translations
I have already narrowed it down to two systems for easily managing translations:
Research will be required to pick the best system to use.
Types of content to translate
There is two types of text that needs to be translated:
- System strings: Text that is used in HTML templates, resources, etc. The translation files (
.poand.mo) can be automatically generated and retrieved by Django. - Content strings: Text found in files in the
topics/contentfolder (within Markdown files).
The second type of text requires some thought on how to easily translate this material. Two possible solutions that are worth investigating (could be many more):
-
Each language has it's own folder within the
topics/content/folder. This was our initial approach, and Add locale property to models, reading of translated data in load scripts, and retrieving of models based off locale #47 was to implement locale property on models, reading of translated data in load scripts, and retrieving of models based off locale. Downsides include:-
Custom tracking of how updated a file is.
-
Translations would be inputted on two systems (Crowdin/Transifex and Github).
-
-
Create script that creates message files from content files (see Django docs and Babel). This would allow all content to be translated in the one place. Would need to research if message files are generated before or after Verto translation. Downsides include:
- May be difficult to parse translatable strings (this may need to be a feature within Verto).
Summary
This issue will require:
- Decision on translation system.
- Configuring of Django settings regarding internationalization.
- Adding documentation.
- Allowing manual changing of language on website.