doxxx / ffxiv-craft-opt-web

Web frontend for FFXIV Crafting Optimizer service.
zlib License
224 stars 197 forks source link

Something about the language localization of the simulator... #246

Open yls888 opened 6 years ago

yls888 commented 6 years ago

Hello, may I ask if this simulator can fully implement language localization through localization files in the future? Or do you have any plans to develop this direction? The localization function updates the occupation, recipe, interface text and other information in the simulator instead of just updating the macro and recipe information as it is today.

I am a player from China. For some non-native English FFXIV players, there may be some inconvenience in using this simulator. Although I have done some local translations on the simulator myself, it is still not perfect. Content is still not available for localization.

I look forward to hearing from you!

doxxx commented 6 years ago

I have explored this in the past, but it is a significant amount of work. At the time, I didn't really think there was enough of a demand to warrant the work required. However, with a wider audience using this website now, it may be worth it.

I use the angular-translate library to implement translation of the recipe and action names. This library can also be easily used to translate other text in the UI.

For example, something like this:

<button>Start</button>

Can be changed to:

<button>{{ 'SOLVER_START' | translate }}</button>

Combined with locale files that map SOLVER_START to the appropriate words in each language.

I'm not sure whether it would be possible to use the actual English text as the lookup key (e.g. Start) like I do for action and recipe names. For those they have a one-to-one mapping, but for other UI text it's not clear to me whether the same English word would always map to the same word(s) in other languages if the English word is re-used in different contexts.

I'll have a look at this when I have some time on a weekend.

Jengines commented 6 years ago

Hello,

As a French user who've just discovered your app, I have the same request. I forked the repo locally and i'm working on this issue, I'll pull request when I'm done.

Assign me the issue if you want and I will glady help you with localization. I can update en.json and fr.json files with some translations, for the other translations I will need some help of the community !

doxxx commented 6 years ago

Thanks! I look forward to your submission.

doxxx commented 6 years ago

@yls888 Thanks to @Jengines, the UI is now internationalized and can be localized into different languages. Have a look at app/locale/cn.json to see what needs to be translated.

yls888 commented 6 years ago

Thanks a lot! I've finished the Chinese translation just now and pulled requests. And I also fixed some details, please check to see if they are useful.

doxxx commented 5 years ago

@RyuaNerin Do you have any interest in translating the UI to Korean?

Kanisame commented 5 years ago

@doxxx I would like to offer my services and czech translation for the application. How should I go about doing that - don't really have skills when it comes to Javascript. Would it suffice if I just pulled out and retyped content of one of the locale files and then send it to you for rework? Or should I follow some specific steps?

I personally will not have a use for it, as possibly many of the czech community, but nevetheless it could prove useful for certain small percentage of users who might struggle with english language.

doxxx commented 5 years ago

@Kanisame Fork this repository and then add a new app/locale/cz.json file with a copy of the contents of app/locale/en.json and translate the text on the right side of each "id": "text" pair. Once you've committed your changes, create a pull request to this repo with your changes.

doxxx commented 5 years ago

To other translators: I've added a new section to the About page with a list of contributors. I have attempted to use Google Translate but if the resulting translation offends you, please submit corrections 😄

RyuaNerin commented 5 years ago

@RyuaNerin Do you have any interest in translating the UI to Korean?

I'm sorry. but I quitted Final Fantasy XIV, so have no interest in translation either.