Skip to content

Commit

Permalink
Merge pull request #56 from lukas-becker0/main
Browse files Browse the repository at this point in the history
fix: Outdated template language codes
  • Loading branch information
MarcosNicolau authored Nov 14, 2024
2 parents dcb103f + cb9a72a commit aceed43
Showing 1 changed file with 11 additions and 37 deletions.
48 changes: 11 additions & 37 deletions src/types/languageCodes.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
export const SUPPORTED_LANGUAGES_CODE = {
// See the docs
// here: https://developers.facebook.com/docs/whatsapp/business-management-api/message-templates/supported-languages/
// and/or here: https://developers.facebook.com/docs/whatsapp/api/messages/message-templates/#supported-languages
export const SUPPORTED_LANGUAGES_CODES = {
Afrikaans: "af",
Albanian: "sq",
Arabic: "ar",
Expand Down Expand Up @@ -28,77 +31,48 @@ export const SUPPORTED_LANGUAGES_CODE = {
Hebrew: "he",
Hindi: "hi",
Hungarian: "hu",
Icelandic: "is",
Igbo: "ig",
Indonesian: "id",
Irish: "ga",
Italian: "it",
Japanese: "ja",
Javanese: "jv",
Kannada: "kn",
Kazakh: "kk",
Khmer: "km",
Kinyarwanda: "rw",
Kinyarwanda: "rw_RW",
Korean: "ko",
Kurdish: "ku",
Kyrgyz: "ky",
Kyrgyzstan: "ky_KG",
Lao: "lo",
Latin: "la",
Latvian: "lv",
Lithuanian: "lt",
Luxembourgish: "lb",
Macedonian: "mk",
Malagasy: "mg",
Malay: "ms",
Malayalam: "ml",
Maltese: "mt",
Maori: "mi",
Marathi: "mr",
Mongolian: "mn",
Nepali: "ne",
Norwegian: "no",
Nyanja: "ny",
Odia: "or",
Pashto: "ps",
Norwegian: "nb",
Persian: "fa",
Polish: "pl",
Portuguese_BR: "pt_BR",
Portuguese_PT: "pt_PT",
Punjabi: "pa",
Romanian: "ro",
Russian: "ru",
ScotsGaelic: "gd",
Serbian: "sr",
Sesotho: "st",
Shona: "sn",
Sindhi: "sd",
Sinhala: "si",
Slovak: "sk",
Slovenian: "sl",
Somali: "so",
Spanish: "es",
Sundanese: "su",
SpanishArgentina: "es_AR",
SpanishSpain: "es_ES",
SpanishMexico: "es_MX",
Swahili: "sw",
Swedish: "sv",
Tajik: "tg",
Tamil: "ta",
Tatar: "tt",
Telugu: "te",
Thai: "th",
Turkish: "tr",
Turkmen: "tk",
Ukrainian: "uk",
Urdu: "ur",
Uyghur: "ug",
Uzbek: "uz",
Vietnamese: "vi",
Welsh: "cy",
WesternFrisian: "fy",
Xhosa: "xh",
Yiddish: "yi",
Yoruba: "yo",
Zulu: "zu",
} as const;

export type SupportedLanguagesCodeUnion =
typeof SUPPORTED_LANGUAGES_CODE[keyof typeof SUPPORTED_LANGUAGES_CODE];
export type SupportedLanguagesCodeUnion = typeof SUPPORTED_LANGUAGES_CODES[keyof typeof SUPPORTED_LANGUAGES_CODES];

0 comments on commit aceed43

Please sign in to comment.