mirror of
https://github.com/vodemn/m3_lightmeter.git
synced 2025-04-04 08:30:41 +00:00
l10n: add German to supported locales
This commit is contained in:
parent
d6ea6008a0
commit
79b3827461
2 changed files with 5 additions and 1 deletions
|
@ -1,4 +1,4 @@
|
||||||
enum SupportedLocale { en, fr, ru, zh }
|
enum SupportedLocale { en, fr, ru, zh, de }
|
||||||
|
|
||||||
extension SupportedLocaleExtension on SupportedLocale {
|
extension SupportedLocaleExtension on SupportedLocale {
|
||||||
String get intlName => toString().replaceAll("SupportedLocale.", "");
|
String get intlName => toString().replaceAll("SupportedLocale.", "");
|
||||||
|
@ -13,6 +13,8 @@ extension SupportedLocaleExtension on SupportedLocale {
|
||||||
return 'Русский';
|
return 'Русский';
|
||||||
case SupportedLocale.zh:
|
case SupportedLocale.zh:
|
||||||
return '简体中文';
|
return '简体中文';
|
||||||
|
case SupportedLocale.de:
|
||||||
|
return 'Deutsch';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,6 +7,7 @@ void main() {
|
||||||
expect(SupportedLocale.fr.intlName, 'fr');
|
expect(SupportedLocale.fr.intlName, 'fr');
|
||||||
expect(SupportedLocale.ru.intlName, 'ru');
|
expect(SupportedLocale.ru.intlName, 'ru');
|
||||||
expect(SupportedLocale.zh.intlName, 'zh');
|
expect(SupportedLocale.zh.intlName, 'zh');
|
||||||
|
expect(SupportedLocale.de.intlName, 'de');
|
||||||
});
|
});
|
||||||
|
|
||||||
test('localizedName', () {
|
test('localizedName', () {
|
||||||
|
@ -14,5 +15,6 @@ void main() {
|
||||||
expect(SupportedLocale.fr.localizedName, 'Français');
|
expect(SupportedLocale.fr.localizedName, 'Français');
|
||||||
expect(SupportedLocale.ru.localizedName, 'Русский');
|
expect(SupportedLocale.ru.localizedName, 'Русский');
|
||||||
expect(SupportedLocale.zh.localizedName, '简体中文');
|
expect(SupportedLocale.zh.localizedName, '简体中文');
|
||||||
|
expect(SupportedLocale.de.localizedName, 'Deutsch');
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue