-
Notifications
You must be signed in to change notification settings - Fork 28
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
i18n: Support translating mod description #172
Labels
Comments
MattSturgeon
added
enhancement
New feature or request
i18n
Internationalization: languages & translation
labels
Feb 5, 2024
12 tasks
MattSturgeon
added a commit
to MattSturgeon/Freecam
that referenced
this issue
Feb 8, 2024
Introduce `ModNameProcessor` & `ModDescriptionProcessor`, along with a new method `LangTask.getTranslation()` which can be used to get a specific translation after the task has finished running. Make use of this in `:data` to get the name & description from the translations into the mod metadata file. Fixes MinecraftFreecam#172
MattSturgeon
added a commit
to MattSturgeon/Freecam
that referenced
this issue
Feb 9, 2024
Move name & description definition from `gradle.properties` to a lang file in `:data`. Introduce `ModNameProcessor` & `ModDescriptionProcessor`, along with a new method `LangTask.getTranslation()` which can be used to get a specific translation after the task has finished running. Make use of this in `:data` to get the name & description from the translations into the mod metadata file. Fixes MinecraftFreecam#172
MattSturgeon
added a commit
to MattSturgeon/Freecam
that referenced
this issue
Feb 14, 2024
Move name & description definition from `gradle.properties` to a lang file in `:data`. Introduce `ModNameProcessor` & `ModDescriptionProcessor`, along with a new method `LangTask.getTranslation()` which can be used to get a specific translation after the task has finished running. Make use of this in `:data` to get the name & description from the translations into the mod metadata file. Fixes MinecraftFreecam#172
MattSturgeon
added a commit
to MattSturgeon/Freecam
that referenced
this issue
Feb 18, 2024
Move name & description definition from `gradle.properties` to a lang file in `:data`. Introduce `ModNameProcessor` & `ModDescriptionProcessor`, along with a new method `LangTask.getTranslation()` which can be used to get a specific translation after the task has finished running. Make use of this in `:data` to get the name & description from the translations into the mod metadata file. Fixes MinecraftFreecam#172
MattSturgeon
added a commit
to MattSturgeon/Freecam
that referenced
this issue
Feb 22, 2024
Move name & description definition from `gradle.properties` to a lang file in `:data`. Introduce `ModNameProcessor` & `ModDescriptionProcessor`, along with a new method `LangTask.getTranslation()` which can be used to get a specific translation after the task has finished running. Make use of this in `:data` to get the name & description from the translations into the mod metadata file. Fixes MinecraftFreecam#172
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Request
This topic was brought up in Crowdin discussions by Әлмәт Ак Арыслан
Әлмәт Ак Арыслан.
Implementation
While
fabric.mod.json
doesn't natively support translated descriptions, modmenu documents that additional keys can be added to our language files to handle this.The additional keys are:
modmenu.nameTranslation.freecam
: mod name (probably doesn't need translating in our case?)modmenu.descriptionTranslation.freecam
: full description shown in the right-hand panemodmenu.summaryTranslation.freecam
: text shown in the mod list (defaults to description)That may be more complex that it sounds, because we need a different description for the standard & Modrinth builds.
I suspect, we'll need to have the
:metadata
project generate lang files in addition to what it currently does.This will mean moving the lang files out of
common/src/resources
and potentially adding additional lang files that we can merge when building.We'll also need to move the description out of
gradle.properties
and into one of these new metadata language files.Forge
I'm not aware of any way to include translations in
mods.toml
, nor am I aware of any other way to tell (neo)forge's mods menu about translations. That said, I've not properly looked into this yet.Additional opportunities
Having a translation build step presents a couple unrelated opportunities:
en-US.json
).properties
supports comments and is easier to read than.json
. Crowdin can use comments to add additional context.)VariantTooltip
, by doing most of the work at build timeThe text was updated successfully, but these errors were encountered: