feat: add defaultLocale in config.json (#1010)

Co-authored-by: th33xitus <domwil1091+github@gmail.com>
This commit is contained in:
Stefan Dejandth33xitus authored and GitHub committed 2022-08-07 22:53:29 +02:00
1 parent 1d117ed82f
commit 46f0879677
3 files changed
+3

No files matched your search

+1
View File
@@ -1,4 +1,5 @@
{
"defaultLocale": "en",
"hostname": null,
"port": null,
"instancesDB": "moonraker",
+1
View File
@@ -111,6 +111,7 @@
"CheckMoonrakerLog": "Wenn diese Meldung wiederholt erscheint, schaue bitte in die Logdatei unter:",
"Connecting": "Verbinde zu {host}",
"Failed": "Verbindung fehlgeschlagen",
"Initializing": "Initialisieren",
"TryAgain": "Erneut versuchen"
},
"Console": {
+1
View File
@@ -82,6 +82,7 @@ const initLoad = async () => {
window.console.debug('Loaded config.json')
await store.dispatch('importConfigJson', file)
if ('defaultLocale' in file) i18n.locale = file.defaultLocale
})
.catch((_) => {
window.console.error('config.json not found or cannot be decoded!')