improve selection logic

This commit is contained in:
SethBurkart123
2024-05-06 11:34:54 +10:00
parent be1679007e
commit 23e6eac16c
7 changed files with 34 additions and 12 deletions
+3
View File
@@ -1,5 +1,6 @@
import { CustomTheme } from '../../../interface/types/CustomThemes';
import browser from 'webextension-polyfill';
import sendThemeUpdate from '../../utils/sendThemeUpdate';
export const removeTheme = async (theme: CustomTheme) => {
// Remove custom CSS
@@ -19,4 +20,6 @@ export const removeTheme = async (theme: CustomTheme) => {
customImageVariables.forEach((variableName) => {
document.documentElement.style.removeProperty('--' + variableName);
});
sendThemeUpdate();
};