forked from MapComplete/MapComplete
Add matrix-bot translations
This commit is contained in:
parent
47812c3f43
commit
b78923ad6a
8 changed files with 110 additions and 16 deletions
|
@ -49,6 +49,10 @@ export class Translation extends BaseUIElement {
|
|||
return this.textFor(Translation.forcedLanguage ?? Locale.language.data)
|
||||
}
|
||||
|
||||
public toString(){
|
||||
return this.txt;
|
||||
}
|
||||
|
||||
static ExtractAllTranslationsFrom(object: any, context = ""): { context: string, tr: Translation }[] {
|
||||
const allTranslations: { context: string, tr: Translation }[] = []
|
||||
for (const key in object) {
|
||||
|
@ -286,4 +290,6 @@ export class TypedTranslation<T> extends Translation {
|
|||
return Utils.SubstituteKeys(template, text, lang);
|
||||
}, context)
|
||||
}
|
||||
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue