Fix various small bugs (directionPicker is square and has a max width; fix welcome message, fix translations

This commit is contained in:
Pieter Vander Vennet 2021-09-03 17:00:36 +02:00
parent abb39f2310
commit 4ace40c2f3
5 changed files with 11 additions and 9 deletions

View file

@ -112,8 +112,9 @@ export class Translation extends BaseUIElement {
} else if (el.ConstructElement === undefined) {
console.error("ConstructElement is not defined", el);
throw "ConstructElement is not defined, you are working with a " + (typeof el) + ":" + (el.constructor.name)
}else if(el["translations"] !== undefined){
rtext = el["translations"][lang]
}else if(el["textFor"] !== undefined){
// @ts-ignore
rtext = el.textFor(lang)
} else {
rtext = el.ConstructElement().innerHTML;