diff options
Diffstat (limited to 'src/app')
-rw-r--r-- | src/app/index.html | 2 | ||||
-rw-r--r-- | src/app/lang.js | 16 | ||||
-rw-r--r-- | src/app/main.css | 5 | ||||
-rw-r--r-- | src/app/main.js | 5 |
4 files changed, 20 insertions, 8 deletions
diff --git a/src/app/index.html b/src/app/index.html index 1c34360..426b4c5 100644 --- a/src/app/index.html +++ b/src/app/index.html @@ -22,7 +22,7 @@ </div> </div> - <script src="main.js"></script> <script src="lang.js"></script> + <script src="main.js"></script> </body> </html> diff --git a/src/app/lang.js b/src/app/lang.js index 8cf3d4b..5cc9708 100644 --- a/src/app/lang.js +++ b/src/app/lang.js @@ -1,10 +1,12 @@ -html = document.body.innerHTML.split("%%"); +function setlang() { + html = document.body.innerHTML.split("%%"); -for (let i = 0; i < html.length; i++) { - if (html[i][0] != " " && - html[i][html[i].length - 1] != " ") { - html[i] = lang(html[i]) + for (let i = 0; i < html.length; i++) { + if (html[i][0] != " " && + html[i][html[i].length - 1] != " ") { + html[i] = lang(html[i]) + } } -} -document.body.innerHTML = html.join(""); + document.body.innerHTML = html.join(""); +} diff --git a/src/app/main.css b/src/app/main.css index 854c47a..c9c62fb 100644 --- a/src/app/main.css +++ b/src/app/main.css @@ -34,10 +34,14 @@ body, button, input { } .buttons { + text-align: right; margin-left: auto; margin-right: 7px; } +.text {max-width: 38vw} +.buttons {max-width: 55vw} + button, .text { border: none; outline: none; @@ -47,6 +51,7 @@ button, .text { } button { + margin-bottom: 10px; color: var(--btnforeground); -webkit-app-region: no-drag; } diff --git a/src/app/main.js b/src/app/main.js index 579f785..0118b0c 100644 --- a/src/app/main.js +++ b/src/app/main.js @@ -34,3 +34,8 @@ function launchVanilla() {ipcRenderer.send("launchVanilla")} ipcRenderer.on("newpath", (event, newpath) => { settings.gamepath = newpath; }) + +setlang(); +setInterval(() => { + ipcRenderer.send("setsize", document.querySelector(".lines").offsetHeight + 25); +}, 150) |