mirror of
https://github.com/BetterSEQTA/BetterSEQTA-Plus.git
synced 2026-06-06 03:34:40 +00:00
fixed issues with selected type conflicting
This commit is contained in:
@@ -66,8 +66,6 @@ const ThemeSelector = ({ selectedType, setSelectedType, isEditMode }: ThemeSelec
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log("Theme: ", theme);
|
|
||||||
|
|
||||||
// If theme is downloaded and is the currently enabled theme, disable it.
|
// If theme is downloaded and is the currently enabled theme, disable it.
|
||||||
if (theme.isDownloaded && themeName === enabledThemeName) {
|
if (theme.isDownloaded && themeName === enabledThemeName) {
|
||||||
await disableTheme();
|
await disableTheme();
|
||||||
@@ -97,6 +95,12 @@ const ThemeSelector = ({ selectedType, setSelectedType, isEditMode }: ThemeSelec
|
|||||||
stopLoading(themeName);
|
stopLoading(themeName);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
if (selectedType === 'background') {
|
||||||
|
setEnabledThemeName('');
|
||||||
|
}
|
||||||
|
}, [selectedType]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="my-2">
|
<div className="my-2">
|
||||||
<h2 className="pb-2 text-lg font-bold">Themes</h2>
|
<h2 className="pb-2 text-lg font-bold">Themes</h2>
|
||||||
|
|||||||
Reference in New Issue
Block a user