Skip to content

๐ŸŒ Multilanguage support for Lavamusic ๐ŸŽถ โ€‹

Help us bring Lavamusic to the world!

We use i18next with a categorized folder structure to manage translations.

๐ŸŒŸ How to add a new language โ€‹

  1. ๐Ÿ”Ž Find the code
    Identify the ISO language code supported by Discord (e.g., en-US, es-ES, fr). You can find the list here.
  2. ๐Ÿ“ Create directory
    Create a new folder in locales/ with your language code (e.g., locales/fr/).
  3. ๐Ÿ“‹ Copy source
    Copy all .json files from locales/en-US/ into your new folder.
  4. ๐ŸŒ Translate
    Translate the strings in the JSON files to the desired language.

๐Ÿ“‚ Directory structure โ€‹

Your file structure should look like this:

text
locales/
โ”œโ”€โ”€ en-US/              (Source Language)
โ”‚   โ”œโ”€โ”€ commands.json   (Command names and descriptions)
โ”‚   โ”œโ”€โ”€ common.json     (UI buttons, generic errors, status)
โ”‚   โ”œโ”€โ”€ dev.json        (Developer tools)
โ”‚   โ”œโ”€โ”€ events.json     (Event messages)
โ”‚   โ””โ”€โ”€ player.json     (Music player responses)
โ”œโ”€โ”€ es-ES/              (Your New Language)
โ”‚   โ”œโ”€โ”€ commands.json
โ”‚   โ”œโ”€โ”€ common.json
โ”‚   โ””โ”€โ”€ ...

๐Ÿ“š Available translations โ€‹

Status

โœ… Available
โŒ Unavailable
๐Ÿค– AI Translation

LanguageCodeStatusContributors
๐Ÿ‡บ๐Ÿ‡ธ English (US)en-USโœ…-
๐Ÿ‡ง๐Ÿ‡ฌ Bulgarianbg๐Ÿค–@Appujet
๐Ÿ‡จ๐Ÿ‡ณ Chinese (CN)zh-CN๐Ÿค–@appujet
๐Ÿ‡น๐Ÿ‡ผ Chinese (TW)zh-TWโœ…@apple050620312
๐Ÿ‡ญ๐Ÿ‡ท Croatianhr๐Ÿค–@Appujet
๐Ÿ‡จ๐Ÿ‡ฟ Czechcs๐Ÿค–@Appujet
๐Ÿ‡ฉ๐Ÿ‡ฐ Danishda๐Ÿค–@Appujet
๐Ÿ‡ณ๐Ÿ‡ฑ Dutchnlโœ…@Appujet
๐Ÿ‡ฌ๐Ÿ‡ง English (GB)en-GBโœ…@Appujet
๐Ÿ‡ซ๐Ÿ‡ฎ Finnishfi๐Ÿค–@Appujet
๐Ÿ‡ซ๐Ÿ‡ท Frenchfrโœ…@LucasB25
๐Ÿ‡ฉ๐Ÿ‡ช Germandeโœ…@LucasB25
๐Ÿ‡ฌ๐Ÿ‡ท Greekel๐Ÿค–@Appujet
๐Ÿ‡ฎ๐Ÿ‡ณ Hindihi๐Ÿค–@Appujet
๐Ÿ‡ญ๐Ÿ‡บ Hungarianhu๐Ÿค–@Appujet
๐Ÿ‡ฎ๐Ÿ‡ฉ Indonesianidโœ…@iaMJ
๐Ÿ‡ฎ๐Ÿ‡น Italianitโœ…@lori28167
๐Ÿ‡ฏ๐Ÿ‡ต Japanesejaโœ…@hatry4
๐Ÿ‡ฐ๐Ÿ‡ท Koreankoโœ…@hwangsihu
๐Ÿ‡ฑ๐Ÿ‡น Lithuanianlt๐Ÿค–@Appujet
๐Ÿ‡ณ๐Ÿ‡ด Norwegianno๐Ÿค–@appujet
๐Ÿ‡ต๐Ÿ‡ฑ Polishplโœ…@InfNibor, @LucasB25
๐Ÿ‡ง๐Ÿ‡ท Portuguese (BR)pt-BRโœ…@AndreAugustoDev
๐Ÿ‡ต๐Ÿ‡น Portuguese (PT)pt-PTโœ…@LucasB25
๐Ÿ‡ท๐Ÿ‡ด Romanianro๐Ÿค–@Appujet
๐Ÿ‡ท๐Ÿ‡บ Russianruโœ…@LucasB25
๐Ÿ‡ช๐Ÿ‡ธ Spanish (ES)es-ESโœ…@LucasB25
๐Ÿ‡ธ๐Ÿ‡ช Swedishsv-SE๐Ÿค–@Appujet
๐Ÿ‡น๐Ÿ‡ญ Thaithโœ…@fexncns
๐Ÿ‡น๐Ÿ‡ท Turkishtrโœ…@IlkayAksoy
๐Ÿ‡บ๐Ÿ‡ฆ Ukrainianuk๐Ÿค–@Appujet
๐Ÿ‡ป๐Ÿ‡ณ Vietnamesevi๐Ÿค–@nhutlamm

๐Ÿ“ Translation Guidelines โ€‹

  • Do not change the key names in the translation JSON file.
  • Do not change the structure of the translation JSON file.
  • Do not remove the {} tags from the strings.
  • Do not add any new keys to the translation JSON file.

Example โ€‹

Source (en-US/commands.json):

json
{
  "ping": {
    "description": "Shows the bot's latency.",
    "content": "Pinging...",
    "requested_by": "Requested by {author}"
  }
}

Target (hi/commands.json):

json
{
  "ping": {
    "description": "เคฌเฅ‰เคŸ เค•เคพ เคชเคฟเค‚เค— เคฆเคฟเค–เคพเคคเคพ เคนเฅˆเฅค",
    "content": "เคชเคฟเค‚เค—เคฟเค‚เค—...",
    "requested_by": "{author} เคฆเฅเคตเคพเคฐเคพ เค…เคจเฅเคฐเฅ‹เคงเคฟเคค"
  }
}

๐Ÿท๏ธ Formatting tags for i18next โ€‹

To ensure {} are not removed during translations, use the format tags: ["{", "}"].

๐ŸŽ‰ Have a Language to Contribute? โ€‹

  1. Fork the repository.
  2. Duplicate locales/en-US and rename the folder to your language code.
  3. Translate the files.
  4. Create a Pull Request!

๐Ÿ“š Resources โ€‹

Released under the GPL-3.0 License.