diff --git a/src/Integrations/Deepl.php b/src/Integrations/Deepl.php index fce0623..447a840 100644 --- a/src/Integrations/Deepl.php +++ b/src/Integrations/Deepl.php @@ -19,10 +19,43 @@ class Deepl extends Integration * @var array */ protected array $map = [ + Locale::Arabic->value => LanguageCode::ARABIC, + Locale::Bulgarian->value => LanguageCode::BULGARIAN, + Locale::Chinese->value => LanguageCode::CHINESE, + Locale::ChineseHongKong->value => LanguageCode::CHINESE, + Locale::Czech->value => LanguageCode::CZECH, + Locale::Danish->value => LanguageCode::DANISH, + Locale::Dutch->value => LanguageCode::DUTCH, + Locale::English->value => LanguageCode::ENGLISH, + Locale::Estonian->value => LanguageCode::ESTONIAN, + Locale::Finnish->value => LanguageCode::FINNISH, + Locale::French->value => LanguageCode::FRENCH, + Locale::German->value => LanguageCode::GERMAN, + Locale::GermanSwitzerland->value => LanguageCode::GERMAN, + Locale::Greek->value => LanguageCode::GREEK, + Locale::Hungarian->value => LanguageCode::HUNGARIAN, + Locale::Indonesian->value => LanguageCode::INDONESIAN, + Locale::Italian->value => LanguageCode::ITALIAN, + Locale::Japanese->value => LanguageCode::JAPANESE, + Locale::Korean->value => LanguageCode::KOREAN, + Locale::Latvian->value => LanguageCode::LATVIAN, + Locale::Lithuanian->value => LanguageCode::LITHUANIAN, + Locale::NorwegianBokmal->value => LanguageCode::NORWEGIAN, + Locale::NorwegianNynorsk->value => LanguageCode::NORWEGIAN, + Locale::Polish->value => LanguageCode::POLISH, + Locale::Portuguese->value => LanguageCode::PORTUGUESE, + Locale::PortugueseBrazil->value => LanguageCode::PORTUGUESE_BRAZILIAN, + Locale::Romanian->value => LanguageCode::ROMANIAN, + Locale::Russian->value => LanguageCode::RUSSIAN, + Locale::Slovak->value => LanguageCode::SLOVAK, + Locale::Slovenian->value => LanguageCode::SLOVENIAN, + Locale::Spanish->value => LanguageCode::SPANISH, + Locale::Swedish->value => LanguageCode::SWEDISH, + Locale::Turkish->value => LanguageCode::TURKISH, + Locale::Ukrainian->value => LanguageCode::UKRAINIAN, // Locale::Afrikaans->value => 'af', // Locale::Albanian->value => 'sq', // Locale::Amharic->value => 'am', - Locale::Arabic->value => LanguageCode::ARABIC, // Locale::Armenian->value => 'hy', // Locale::Assamese->value => 'as', // Locale::Azerbaijani->value => 'az', @@ -32,53 +65,33 @@ class Deepl extends Integration // Locale::Bengali->value => 'bn', // Locale::Bhojpuri->value => 'bho', // Locale::Bosnian->value => 'bs', - Locale::Bulgarian->value => LanguageCode::BULGARIAN, // Locale::Catalan->value => 'ca', // Locale::Cebuano->value => 'ceb', // Locale::CentralKhmer->value => 'km', - Locale::Chinese->value => LanguageCode::CHINESE, - Locale::ChineseHongKong->value => LanguageCode::CHINESE, // Locale::ChineseT->value => 'zh_TW', // Locale::Croatian->value => 'hr', - Locale::Czech->value => LanguageCode::CZECH, - Locale::Danish->value => LanguageCode::DANISH, // Locale::Dogri->value => 'doi', - Locale::Dutch->value => LanguageCode::DUTCH, - Locale::English->value => LanguageCode::ENGLISH, // Locale::Esperanto->value => 'eo', - Locale::Estonian->value => LanguageCode::ESTONIAN, // Locale::Ewe->value => 'ee', - Locale::Finnish->value => LanguageCode::FINNISH, - Locale::French->value => LanguageCode::FRENCH, // Locale::Frisian->value => 'fy', // Locale::Galician->value => 'gl', // Locale::Georgian->value => 'ka', - Locale::German->value => LanguageCode::GERMAN, - Locale::GermanSwitzerland->value => LanguageCode::GERMAN, - Locale::Greek->value => LanguageCode::GREEK, // Locale::Gujarati->value => 'gu', // Locale::Hausa->value => 'ha', // Locale::Hawaiian->value => 'haw', // Locale::Hebrew->value => 'he', // Locale::Hindi->value => 'hi', - Locale::Hungarian->value => LanguageCode::HUNGARIAN, // Locale::Icelandic->value => 'is', // Locale::Igbo->value => 'ig', - Locale::Indonesian->value => LanguageCode::INDONESIAN, // Locale::Irish->value => 'ga', - Locale::Italian->value => LanguageCode::ITALIAN, - Locale::Japanese->value => LanguageCode::JAPANESE, // Locale::Kannada->value => 'kn', // Locale::Kazakh->value => 'kk', // Locale::Kinyarwanda->value => 'rw', - Locale::Korean->value => LanguageCode::KOREAN, // Locale::Kurdish->value => 'ku', // Locale::KurdishSorani->value => 'ckb', // Locale::Kyrgyz->value => 'ky', // Locale::Lao->value => 'lo', - Locale::Latvian->value => LanguageCode::LATVIAN, // Locale::Lingala->value => 'ln', - Locale::Lithuanian->value => LanguageCode::LITHUANIAN, // Locale::Luganda->value => 'lg', // Locale::Luxembourgish->value => 'lb', // Locale::Macedonian->value => 'mk', @@ -93,21 +106,14 @@ class Deepl extends Integration // Locale::Mongolian->value => 'mn', // Locale::MyanmarBurmese->value => 'my', // Locale::Nepali->value => 'ne', - Locale::NorwegianBokmal->value => LanguageCode::NORWEGIAN, - Locale::NorwegianNynorsk->value => LanguageCode::NORWEGIAN, // Locale::Occitan->value => 'oc', // Locale::OdiaOriya->value => 'or', // Locale::Oromo->value => 'om', // Locale::Pashto->value => 'ps', // Locale::Persian->value => 'fa', // Locale::Pilipino->value => 'fil', - Locale::Polish->value => LanguageCode::POLISH, - Locale::Portuguese->value => LanguageCode::PORTUGUESE, - Locale::PortugueseBrazil->value => LanguageCode::PORTUGUESE_BRAZILIAN, // Locale::Punjabi->value => 'pa', // Locale::Quechua->value => 'qu', - Locale::Romanian->value => LanguageCode::ROMANIAN, - Locale::Russian->value => LanguageCode::RUSSIAN, // Locale::Sanskrit->value => 'sa', // Locale::Sardinian->value => 'sc', // Locale::ScotsGaelic->value => 'gd', @@ -117,13 +123,9 @@ class Deepl extends Integration // Locale::Shona->value => 'sn', // Locale::Sindhi->value => 'sd', // Locale::Sinhala->value => 'si', - Locale::Slovak->value => LanguageCode::SLOVAK, - Locale::Slovenian->value => LanguageCode::SLOVENIAN, // Locale::Somali->value => 'so', - Locale::Spanish->value => LanguageCode::SPANISH, // Locale::Sundanese->value => 'su', // Locale::Swahili->value => 'sw', - Locale::Swedish->value => LanguageCode::SWEDISH, // Locale::Tagalog->value => 'tl', // Locale::Tajik->value => 'tg', // Locale::Tamil->value => 'ta', @@ -131,11 +133,9 @@ class Deepl extends Integration // Locale::Telugu->value => 'te', // Locale::Thai->value => 'th', // Locale::Tigrinya->value => 'ti', - Locale::Turkish->value => LanguageCode::TURKISH, // Locale::Turkmen->value => 'tk', // Locale::TwiAkan->value => 'ak', // Locale::Uighur->value => 'ug', - Locale::Ukrainian->value => LanguageCode::UKRAINIAN, // Locale::Urdu->value => 'ur', // Locale::UzbekCyrillic->value => 'uz_Cyrl', // Locale::UzbekLatin->value => 'uz_Latn', diff --git a/src/Integrations/Google.php b/src/Integrations/Google.php index 836ecd5..3bccaa0 100644 --- a/src/Integrations/Google.php +++ b/src/Integrations/Google.php @@ -105,42 +105,42 @@ class Google extends Integration Locale::Romanian->value => 'ro', Locale::Russian->value => 'ru', Locale::Sanskrit->value => 'sa', + Locale::ScotsGaelic->value => 'gd', + Locale::SerbianCyrillic->value => 'sr', + Locale::Shona->value => 'sn', + Locale::Sindhi->value => 'sd', + Locale::Sinhala->value => 'si', + Locale::Slovak->value => 'sk', + Locale::Slovenian->value => 'sl', + Locale::Somali->value => 'so', + Locale::Spanish->value => 'es', + Locale::Sundanese->value => 'su', + Locale::Swahili->value => 'sw', + Locale::Swedish->value => 'sv', + Locale::Tagalog->value => 'tl', + Locale::Tajik->value => 'tg', + Locale::Tamil->value => 'ta', + Locale::Tatar->value => 'tt', + Locale::Telugu->value => 'te', + Locale::Thai->value => 'th', + Locale::Tigrinya->value => 'ti', + Locale::Turkish->value => 'tr', + Locale::Turkmen->value => 'tk', + Locale::TwiAkan->value => 'ak', + Locale::Uighur->value => 'ug', + Locale::Ukrainian->value => 'uk', + Locale::Urdu->value => 'ur', + Locale::UzbekCyrillic->value => 'uz', + Locale::Vietnamese->value => 'vi', + Locale::Welsh->value => 'cy', + Locale::Xhosa->value => 'xh', + Locale::Yiddish->value => 'yi', + Locale::Yoruba->value => 'yo', + Locale::Zulu->value => 'zu', // Locale::Sardinian->value => 'sc', - Locale::ScotsGaelic->value => 'gd', - Locale::SerbianCyrillic->value => 'sr', // Locale::SerbianLatin->value => 'sr_Latn', // Locale::SerbianMontenegrin->value => 'sr_Latn_ME', - Locale::Shona->value => 'sn', - Locale::Sindhi->value => 'sd', - Locale::Sinhala->value => 'si', - Locale::Slovak->value => 'sk', - Locale::Slovenian->value => 'sl', - Locale::Somali->value => 'so', - Locale::Spanish->value => 'es', - Locale::Sundanese->value => 'su', - Locale::Swahili->value => 'sw', - Locale::Swedish->value => 'sv', - Locale::Tagalog->value => 'tl', - Locale::Tajik->value => 'tg', - Locale::Tamil->value => 'ta', - Locale::Tatar->value => 'tt', - Locale::Telugu->value => 'te', - Locale::Thai->value => 'th', - Locale::Tigrinya->value => 'ti', - Locale::Turkish->value => 'tr', - Locale::Turkmen->value => 'tk', - Locale::TwiAkan->value => 'ak', - Locale::Uighur->value => 'ug', - Locale::Ukrainian->value => 'uk', - Locale::Urdu->value => 'ur', - Locale::UzbekCyrillic->value => 'uz', - // Locale::UzbekLatin->value => 'uz_Latn', - Locale::Vietnamese->value => 'vi', - Locale::Welsh->value => 'cy', - Locale::Xhosa->value => 'xh', - Locale::Yiddish->value => 'yi', - Locale::Yoruba->value => 'yo', - Locale::Zulu->value => 'zu', + // Locale::UzbekLatin->value => 'uz_Latn', ]; public static string $integration = GoogleTranslate::class; diff --git a/src/Integrations/Yandex.php b/src/Integrations/Yandex.php index 00f5299..7bdd7b1 100644 --- a/src/Integrations/Yandex.php +++ b/src/Integrations/Yandex.php @@ -16,132 +16,132 @@ class Yandex extends Integration * @var array */ protected array $map = [ - Locale::Afrikaans->value => 'af', - Locale::Albanian->value => 'sq', - Locale::Amharic->value => 'am', + Locale::Afrikaans->value => 'af', + Locale::Albanian->value => 'sq', + Locale::Amharic->value => 'am', + Locale::Armenian->value => 'hy', + Locale::Azerbaijani->value => 'az', + Locale::Basque->value => 'eu', + Locale::Belarusian->value => 'be', + Locale::Bengali->value => 'bn', + Locale::Bosnian->value => 'bs', + Locale::Bulgarian->value => 'bg', + Locale::Catalan->value => 'ca', + Locale::Cebuano->value => 'ceb', + Locale::CentralKhmer->value => 'km', + Locale::Chinese->value => 'zh', + Locale::ChineseHongKong->value => 'zh', + Locale::Croatian->value => 'hr', + Locale::Czech->value => 'cs', + Locale::Danish->value => 'da', + Locale::Dutch->value => 'nl', + Locale::English->value => 'en', + Locale::Esperanto->value => 'eo', + Locale::Estonian->value => 'et', + Locale::Finnish->value => 'fi', + Locale::French->value => 'fr', + Locale::Galician->value => 'gl', + Locale::Georgian->value => 'ka', + Locale::German->value => 'de', + Locale::GermanSwitzerland->value => 'de', + Locale::Greek->value => 'el', + Locale::Gujarati->value => 'gu', + Locale::Hebrew->value => 'he', + Locale::Hindi->value => 'hi', + Locale::Hungarian->value => 'hu', + Locale::Icelandic->value => 'is', + Locale::Indonesian->value => 'id', + Locale::Irish->value => 'ga', + Locale::Italian->value => 'it', + Locale::Japanese->value => 'ja', + Locale::Kannada->value => 'kn', + Locale::Kazakh->value => 'kk', + Locale::Korean->value => 'ko', + Locale::Kyrgyz->value => 'ky', + Locale::Lao->value => 'lo', + Locale::Latvian->value => 'lv', + Locale::Lithuanian->value => 'lt', + Locale::Luxembourgish->value => 'lb', + Locale::Macedonian->value => 'mk', + Locale::Malagasy->value => 'mg', + Locale::Malay->value => 'ms', + Locale::Malayalam->value => 'ml', + Locale::Maltese->value => 'mt', + Locale::Maori->value => 'mi', + Locale::Marathi->value => 'mr', + Locale::Mongolian->value => 'mn', + Locale::MyanmarBurmese->value => 'my', + Locale::Nepali->value => 'ne', + Locale::NorwegianBokmal->value => 'no', + Locale::NorwegianNynorsk->value => 'no', + Locale::Persian->value => 'fa', + Locale::Polish->value => 'pl', + Locale::Portuguese->value => 'pt', + Locale::PortugueseBrazil->value => 'pt-BR', + Locale::Punjabi->value => 'pa', + Locale::Romanian->value => 'ro', + Locale::Russian->value => 'ru', + Locale::ScotsGaelic->value => 'gd', + Locale::SerbianCyrillic->value => 'sr', + Locale::SerbianLatin->value => 'sr-Latn', + Locale::SerbianMontenegrin->value => 'sr-Latn', + Locale::Sinhala->value => 'si', + Locale::Slovak->value => 'sk', + Locale::Slovenian->value => 'sl', + Locale::Spanish->value => 'es', + Locale::Sundanese->value => 'su', + Locale::Swahili->value => 'sw', + Locale::Swedish->value => 'sv', + Locale::Tagalog->value => 'tl', + Locale::Tajik->value => 'tg', + Locale::Tamil->value => 'ta', + Locale::Tatar->value => 'tt', + Locale::Telugu->value => 'te', + Locale::Thai->value => 'th', + Locale::Turkish->value => 'tr', + Locale::Ukrainian->value => 'uk', + Locale::Urdu->value => 'ur', + Locale::UzbekCyrillic->value => 'uzbcyr', + Locale::UzbekLatin->value => 'uz', + Locale::Vietnamese->value => 'vi', + Locale::Welsh->value => 'cy', + Locale::Xhosa->value => 'xh', + Locale::Yiddish->value => 'yi', + Locale::Zulu->value => 'zu', // Locale::Arabic->value => 'ar', - Locale::Armenian->value => 'hy', // Locale::Assamese->value => 'as', - Locale::Azerbaijani->value => 'az', // Locale::Bambara->value => 'bm', - Locale::Basque->value => 'eu', - Locale::Belarusian->value => 'be', - Locale::Bengali->value => 'bn', // Locale::Bhojpuri->value => 'bho', - Locale::Bosnian->value => 'bs', - Locale::Bulgarian->value => 'bg', - Locale::Catalan->value => 'ca', - Locale::Cebuano->value => 'ceb', - Locale::CentralKhmer->value => 'km', - Locale::Chinese->value => 'zh', - Locale::ChineseHongKong->value => 'zh', // Locale::ChineseT->value => 'zh_TW', - Locale::Croatian->value => 'hr', - Locale::Czech->value => 'cs', - Locale::Danish->value => 'da', // Locale::Dogri->value => 'doi', - Locale::Dutch->value => 'nl', - Locale::English->value => 'en', - Locale::Esperanto->value => 'eo', - Locale::Estonian->value => 'et', // Locale::Ewe->value => 'ee', - Locale::Finnish->value => 'fi', - Locale::French->value => 'fr', // Locale::Frisian->value => 'fy', - Locale::Galician->value => 'gl', - Locale::Georgian->value => 'ka', - Locale::German->value => 'de', - Locale::GermanSwitzerland->value => 'de', - Locale::Greek->value => 'el', - Locale::Gujarati->value => 'gu', // Locale::Hausa->value => 'ha', // Locale::Hawaiian->value => 'haw', - Locale::Hebrew->value => 'he', - Locale::Hindi->value => 'hi', - Locale::Hungarian->value => 'hu', - Locale::Icelandic->value => 'is', // Locale::Igbo->value => 'ig', - Locale::Indonesian->value => 'id', - Locale::Irish->value => 'ga', - Locale::Italian->value => 'it', - Locale::Japanese->value => 'ja', - Locale::Kannada->value => 'kn', - Locale::Kazakh->value => 'kk', // Locale::Kinyarwanda->value => 'rw', - Locale::Korean->value => 'ko', // Locale::Kurdish->value => 'ku', // Locale::KurdishSorani->value => 'ckb', - Locale::Kyrgyz->value => 'ky', - Locale::Lao->value => 'lo', - Locale::Latvian->value => 'lv', // Locale::Lingala->value => 'ln', - Locale::Lithuanian->value => 'lt', // Locale::Luganda->value => 'lg', - Locale::Luxembourgish->value => 'lb', - Locale::Macedonian->value => 'mk', // Locale::Maithili->value => 'mai', - Locale::Malagasy->value => 'mg', - Locale::Malay->value => 'ms', - Locale::Malayalam->value => 'ml', - Locale::Maltese->value => 'mt', - Locale::Maori->value => 'mi', - Locale::Marathi->value => 'mr', // Locale::MeiteilonManipuri->value => 'mni_Mtei', - Locale::Mongolian->value => 'mn', - Locale::MyanmarBurmese->value => 'my', - Locale::Nepali->value => 'ne', - Locale::NorwegianBokmal->value => 'no', - Locale::NorwegianNynorsk->value => 'no', // Locale::Occitan->value => 'oc', // Locale::OdiaOriya->value => 'or', // Locale::Oromo->value => 'om', // Locale::Pashto->value => 'ps', - Locale::Persian->value => 'fa', // Locale::Pilipino->value => 'fil', - Locale::Polish->value => 'pl', - Locale::Portuguese->value => 'pt', - Locale::PortugueseBrazil->value => 'pt-BR', - Locale::Punjabi->value => 'pa', // Locale::Quechua->value => 'qu', - Locale::Romanian->value => 'ro', - Locale::Russian->value => 'ru', // Locale::Sanskrit->value => 'sa', // Locale::Sardinian->value => 'sc', - Locale::ScotsGaelic->value => 'gd', - Locale::SerbianCyrillic->value => 'sr', - Locale::SerbianLatin->value => 'sr-Latn', - Locale::SerbianMontenegrin->value => 'sr-Latn', // Locale::Shona->value => 'sn', // Locale::Sindhi->value => 'sd', - Locale::Sinhala->value => 'si', - Locale::Slovak->value => 'sk', - Locale::Slovenian->value => 'sl', // Locale::Somali->value => 'so', - Locale::Spanish->value => 'es', - Locale::Sundanese->value => 'su', - Locale::Swahili->value => 'sw', - Locale::Swedish->value => 'sv', - Locale::Tagalog->value => 'tl', - Locale::Tajik->value => 'tg', - Locale::Tamil->value => 'ta', - Locale::Tatar->value => 'tt', - Locale::Telugu->value => 'te', - Locale::Thai->value => 'th', // Locale::Tigrinya->value => 'ti', - Locale::Turkish->value => 'tr', // Locale::Turkmen->value => 'tk', // Locale::TwiAkan->value => 'ak', // Locale::Uighur->value => 'ug', - Locale::Ukrainian->value => 'uk', - Locale::Urdu->value => 'ur', - Locale::UzbekCyrillic->value => 'uzbcyr', - Locale::UzbekLatin->value => 'uz', - Locale::Vietnamese->value => 'vi', - Locale::Welsh->value => 'cy', - Locale::Xhosa->value => 'xh', - Locale::Yiddish->value => 'yi', // Locale::Yoruba->value => 'yo', - Locale::Zulu->value => 'zu', ]; public static string $integration = YandexTranslate::class;