mirror of
https://github.com/bitwarden/browser
synced 2025-12-23 11:43:46 +00:00
[PM-6511] New i18n for angular (#8122)
* Use state provider to store preferred language * migrate preferred language * Use new i18n provider to get LOCAL_ID * Fix preloaded english i18n This is a mock service that forces english translations, it doesn't need the i18n interface that allows changing of locales. * PR improvements * Fixup merge
This commit is contained in:
@@ -264,7 +264,7 @@ export class SettingsComponent implements OnInit {
|
||||
enableDuckDuckGoBrowserIntegration:
|
||||
await this.stateService.getEnableDuckDuckGoBrowserIntegration(),
|
||||
theme: await this.stateService.getTheme(),
|
||||
locale: (await this.stateService.getLocale()) ?? null,
|
||||
locale: await firstValueFrom(this.i18nService.locale$),
|
||||
};
|
||||
this.form.setValue(initialValues, { emitEvent: false });
|
||||
|
||||
@@ -553,7 +553,7 @@ export class SettingsComponent implements OnInit {
|
||||
}
|
||||
|
||||
async saveLocale() {
|
||||
await this.stateService.setLocale(this.form.value.locale);
|
||||
await this.i18nService.setLocale(this.form.value.locale);
|
||||
}
|
||||
|
||||
async saveTheme() {
|
||||
|
||||
Reference in New Issue
Block a user