feat; add multi language support

This commit is contained in:
2025-12-21 20:06:18 -03:00
parent 3926f4d254
commit 7b4c95678e
23 changed files with 163 additions and 77 deletions

View File

@@ -1,14 +1,14 @@
import { inject } from '@angular/core';
import { Dictionary } from '../interfaces/dictionary.interface';
import { STRINGS_INJECTOR } from '../app.config';
import { LanguageManager } from '../services/language-manager';
export class NameAndCompanyFieldsErrorsDictionary implements Dictionary {
private readonly strings = inject(STRINGS_INJECTOR);
private readonly languageManager = inject(LanguageManager);
private readonly maxlen: string;
private readonly required = this.strings.errorMessageRequired;
private readonly required = this.languageManager.strings.errorMessageRequired;
constructor() {
this.maxlen = this.strings.errorMessageMaxLength(120);
this.maxlen = this.languageManager.strings.errorMessageMaxLength(120);
}
getDictionary(): { [key: string]: string } {