From 1501d481d19fb6bde8ffb82769a65a5a12e7c483 Mon Sep 17 00:00:00 2001
From: zumbiepig <121742281+zumbiepig@users.noreply.github.com>
Date: Tue, 3 Sep 2024 20:24:37 -0700
Subject: [PATCH] .
---
public/settings/index.html | 4 ++--
public/welcome/index.html | 2 +-
src/resources/scripts/main.ts | 6 +-----
3 files changed, 4 insertions(+), 8 deletions(-)
diff --git a/public/settings/index.html b/public/settings/index.html
index eb3b6f6..ad8bd0f 100644
--- a/public/settings/index.html
+++ b/public/settings/index.html
@@ -5,7 +5,7 @@
MineXLauncher
-
+ css" />
@@ -59,7 +59,7 @@
diff --git a/src/resources/scripts/main.ts b/src/resources/scripts/main.ts
index 08625d5..92c75f0 100644
--- a/src/resources/scripts/main.ts
+++ b/src/resources/scripts/main.ts
@@ -6,11 +6,7 @@ let selectedVersion: string;
const theme = {
load: function (themeToLoad?: string) {
const themeElement = document.getElementById('theme') as HTMLLinkElement;
- if (themeElement) {
- document.documentElement.style.display = 'none';
- themeElement.onload = () => (document.documentElement.style.display = '');
- themeElement.href = themeToLoad ? `/resources/styles/themes/${themeToLoad}.css` : `/resources/styles/themes/${storage.local.get('theme') ?? 'default'}.css`;
- }
+ if (themeElement) themeElement.href = themeToLoad ? `/resources/styles/themes/${themeToLoad}.css` : `/resources/styles/themes/${storage.local.get('theme') ?? 'default'}.css`;
},
set: function (newTheme: string) {
storage.local.set('theme', newTheme);