diff options
author | 0neGal <mail@0negal.com> | 2022-02-26 00:16:08 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-26 00:16:08 +0100 |
commit | c4fc36d2c9fd732b5c63b7cf47e647c06a33743d (patch) | |
tree | 35f2ee022afba594847ec495dc8258610f2a5411 /src/app/main.js | |
parent | e96135cbc3877423f4c6c012c5d7e09436e5b32c (diff) | |
parent | dec0a7d23767b518284ca69f93ce06a0783de8ce (diff) | |
download | Viper-c4fc36d2c9fd732b5c63b7cf47e647c06a33743d.tar.gz Viper-c4fc36d2c9fd732b5c63b7cf47e647c06a33743d.zip |
Merge pull request #85 from 0neGal/settings-page
feat: Settings page
Diffstat (limited to 'src/app/main.js')
-rw-r--r-- | src/app/main.js | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/app/main.js b/src/app/main.js index 97937a9..a781ef1 100644 --- a/src/app/main.js +++ b/src/app/main.js @@ -8,7 +8,9 @@ let shouldInstallNorthstar = false; // Base settings var settings = { + nsargs: "", gamepath: "", + nsupdate: true, autoupdate: true, zip: "/northstar.zip", lang: navigator.language, @@ -275,6 +277,13 @@ document.addEventListener("drop", (e) => { installFromPath(event.dataTransfer.files[0].path) }); +document.body.addEventListener("keyup", (e) => { + if (e.key == "Escape") { + Browser.toggle(false); + Settings.toggle(false); + } +}) + document.body.addEventListener("click", event => { if (event.target.tagName.toLowerCase() === "a" && event.target.protocol != "file:") { event.preventDefault(); |