l10n: add German to supported locales

This commit is contained in:
drenkmann 2025-03-17 16:57:55 +01:00
parent d6ea6008a0
commit 79b3827461
2 changed files with 5 additions and 1 deletions

View file

@ -1,4 +1,4 @@
enum SupportedLocale { en, fr, ru, zh }
enum SupportedLocale { en, fr, ru, zh, de }
extension SupportedLocaleExtension on SupportedLocale {
String get intlName => toString().replaceAll("SupportedLocale.", "");
@ -13,6 +13,8 @@ extension SupportedLocaleExtension on SupportedLocale {
return 'Русский';
case SupportedLocale.zh:
return '简体中文';
case SupportedLocale.de:
return 'Deutsch';
}
}
}

View file

@ -7,6 +7,7 @@ void main() {
expect(SupportedLocale.fr.intlName, 'fr');
expect(SupportedLocale.ru.intlName, 'ru');
expect(SupportedLocale.zh.intlName, 'zh');
expect(SupportedLocale.de.intlName, 'de');
});
test('localizedName', () {
@ -14,5 +15,6 @@ void main() {
expect(SupportedLocale.fr.localizedName, 'Français');
expect(SupportedLocale.ru.localizedName, 'Русский');
expect(SupportedLocale.zh.localizedName, '简体中文');
expect(SupportedLocale.de.localizedName, 'Deutsch');
});
}