mirror of
https://github.com/bitwarden/browser
synced 2025-12-23 19:53:43 +00:00
[CSA-27] Use new dependency-free locale service for WebAuthN translations (#4557)
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
import { I18nService as BaseI18nService } from "@bitwarden/common/services/i18n.service";
|
||||
|
||||
import { SupportedTranslationLocales } from "../../translation-constants";
|
||||
|
||||
export class I18nService extends BaseI18nService {
|
||||
constructor(systemLanguage: string, localesDirectory: string) {
|
||||
super(systemLanguage || "en-US", localesDirectory, async (formattedLocale: string) => {
|
||||
@@ -14,61 +16,6 @@ export class I18nService extends BaseI18nService {
|
||||
return locales;
|
||||
});
|
||||
|
||||
// Please leave 'en' where it is, as it's our fallback language in case no translation can be found
|
||||
this.supportedTranslationLocales = [
|
||||
"en",
|
||||
"af",
|
||||
"ar",
|
||||
"az",
|
||||
"be",
|
||||
"bg",
|
||||
"bn",
|
||||
"bs",
|
||||
"ca",
|
||||
"cs",
|
||||
"da",
|
||||
"de",
|
||||
"el",
|
||||
"en-GB",
|
||||
"en-IN",
|
||||
"eo",
|
||||
"es",
|
||||
"et",
|
||||
"eu",
|
||||
"fi",
|
||||
"fil",
|
||||
"fr",
|
||||
"he",
|
||||
"hi",
|
||||
"hr",
|
||||
"hu",
|
||||
"id",
|
||||
"it",
|
||||
"ja",
|
||||
"ka",
|
||||
"km",
|
||||
"kn",
|
||||
"ko",
|
||||
"lv",
|
||||
"ml",
|
||||
"nb",
|
||||
"nl",
|
||||
"nn",
|
||||
"pl",
|
||||
"pt-PT",
|
||||
"pt-BR",
|
||||
"ro",
|
||||
"ru",
|
||||
"si",
|
||||
"sk",
|
||||
"sl",
|
||||
"sr",
|
||||
"sv",
|
||||
"tr",
|
||||
"uk",
|
||||
"vi",
|
||||
"zh-CN",
|
||||
"zh-TW",
|
||||
];
|
||||
this.supportedTranslationLocales = SupportedTranslationLocales;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user