diff --git a/.github/workflows/alpha-artifact.yml b/.github/workflows/alpha-artifact.yml index 9a1ae5d..aa468ae 100644 --- a/.github/workflows/alpha-artifact.yml +++ b/.github/workflows/alpha-artifact.yml @@ -31,7 +31,7 @@ jobs: run: > sudo apt-get update - sudo apt-get install -y webkit2gtk-4.0 libayatana-appindicator + sudo apt-get install -y webkit2gtk-4.0 libayatana-appindicator-dev - name: Install app dependencies and build it run: npm ci && npm run build:alpha - uses: tauri-apps/tauri-action@v0 diff --git a/interface/layout/app.ts b/interface/layout/app.ts index 3463dae..3943ecd 100644 --- a/interface/layout/app.ts +++ b/interface/layout/app.ts @@ -1,6 +1,6 @@ import App from "./app.svelte" import "../styles/index.css" -import { fs, path, window } from "@tauri-apps/api" +import { fs, path, os } from "@tauri-apps/api" const getSettingsPath = async () => { const folderPath = await path.join(await path.configDir(), "Levminer", "Authme 4") @@ -15,6 +15,21 @@ const getSettingsPath = async () => { getSettingsPath() +const setBackground = async () => { + const system = await os.type() + const build = await os.version() + + if (system === "Windows_NT" && build < "10.0.22000") { + document.querySelector("body").style.background = "black" + } + + if (system === "Linux") { + document.querySelector("body").style.background = "black" + } +} + +setBackground() + const app = new App({ target: document.body, })