Skip to content

Commit

Permalink
FEAT: Add more support and sync with Discourse allowed locales (#141)
Browse files Browse the repository at this point in the history
  • Loading branch information
nattsw committed May 8, 2024
1 parent f439718 commit eb55d60
Showing 1 changed file with 34 additions and 27 deletions.
61 changes: 34 additions & 27 deletions services/discourse_translator/amazon.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,80 +12,87 @@ class Amazon < Base
# https://docs.aws.amazon.com/translate/latest/dg/what-is-languages.html
SUPPORTED_LANG_MAPPING = {
af: "af",
sq: "sq",
am: "am",
ar: "ar",
hy: "hy",
az: "az",
bg: "bg",
bn: "bn",
bs: "bs",
bg: "bg",
bs_BA: "bs",
ca: "ca",
zh: "zh",
zh_TW: "zh-TW",
hr: "hr",
cs: "cs",
cy: "cy",
da: "da",
fa_AF: "fa-AF",
nl: "nl",
de: "de",
el: "el",
en: "en",
en_GB: "en",
es: "es",
es_MX: "es-MX",
et: "et",
fa: "fa",
tl: "tl",
fa_AF: "fa-AF",
fa_IR: "fa-AF",
fi: "fi",
fr: "fr",
fr_CA: "fr-CA",
ka: "ka",
de: "de",
el: "el",
ga: "ga",
gu: "gu",
ht: "ht",
ha: "ha",
he: "he",
hi: "hi",
hr: "hr",
ht: "ht",
hu: "hu",
is: "is",
hy: "hy",
id: "id",
ga: "ga",
is: "is",
it: "it",
ja: "ja",
kn: "kn",
ka: "ka",
kk: "kk",
kn: "kn",
ko: "ko",
lv: "lv",
lt: "lt",
lv: "lv",
mk: "mk",
ms: "ms",
ml: "ml",
mt: "mt",
mr: "mr",
mn: "mn",
mr: "mr",
ms: "ms",
mt: "mt",
nl: "nl",
no: "no",
ps: "ps",
pa: "pa",
pl: "pl",
pl_PL: "pl",
ps: "ps",
pt: "pt",
pt_PT: "pt-PT",
pa: "pa",
pt_BR: "pt",
ro: "ro",
ru: "ru",
sr: "sr",
si: "si",
sk: "sk",
sl: "sl",
so: "so",
es: "es",
es_MX: "es-MX",
sw: "sw",
sq: "sq",
sr: "sr",
sv: "sv",
sw: "sw",
ta: "ta",
te: "te",
th: "th",
tl: "tl",
tr: "tr",
tr_TR: "tr_TR",
uk: "uk",
ur: "ur",
uz: "uz",
vi: "vi",
cy: "cy",
zh: "zh",
zh_CN: "zh",
zh_TW: "zh-TW",
}

# The API expects a maximum of 10k __bytes__ of text
Expand Down

0 comments on commit eb55d60

Please sign in to comment.