refactor: clean translation system and more widget stuff

This commit is contained in:
David Ralph
2022-08-26 10:45:32 +01:00
parent cd311e0fa1
commit 2c2acbba46
71 changed files with 1028 additions and 999 deletions

View File

@@ -40,6 +40,8 @@ variables.language = new I18n(variables.languagecode, {
tr_TR: translations.tr_TR,
});
variables.getMessage = (text) => variables.language.getMessage(variables.languagecode, text);
// set html language tag
if (variables.languagecode !== 'en_GB' || variables.languagecode !== 'en_US') {
document.documentElement.lang = variables.languagecode.split('_')[0];