oddlama / vane

Immersive and lore friendly enhancements for vanilla Minecraft
MIT License
272 stars 33 forks source link

Localising the website #104

Closed karthanistyr closed 2 years ago

karthanistyr commented 2 years ago

It's recently been made obvious to me that although the mod itself is fully localised, the documentation (website) was not. Any opinions on how to do that ?

karthanistyr commented 2 years ago

The simplest approach would be to duplicate index.html into index.lang.html and translating there, adding links to the various locales at the top (deaulting to english). Drawback is that the page structure is duplicated and any change would have to be mirrored manually.

More complete, more robust approach would propbably be something like https://letrastudio.github.io/jekyll-i18n/

oddlama commented 2 years ago

The website itself is available in the docs/ folder. The only relevant part for localization is the index.html - it's just a static and very simple website.

Ideally, I would split all translatable strings from the index.html into subfiles for each language and assemble them into separate files with a language selector whenever the page is rebuilt. Going forward, I'm tempted using gitbook in the future, where we could translate pages individually. But this would make the whole documentation less accessible and seemingly more complex with all the subpages.

karthanistyr commented 2 years ago

Ideally, I would split all translatable strings from the index.html into subfiles for each language and assemble them into separate files with a language selector whenever the page is rebuilt.

Yes that would probably be a nice stop gap, shy of implementing a full i18n solution (which doesn't look straightforward with Jekyll and therefore a much higher bar to meet). Would be happy to provide the French version if you come around to doing that.

ryantheleach commented 2 years ago

I'm not sure how to tie it in, but Sponge previously used readthedocs with https://crowdin.com/

oddlama commented 2 years ago

I currently don't have the time to do this properly. If I ever get to write a new translation system (https://github.com/oddlama/vane/issues/118) I will include this.