fix: if external imported theme is current active theme change to default for installation

This commit is contained in:
2026-05-29 21:36:37 +02:00
parent d5e5fd4c43
commit dc06b53089
+7
View File
@@ -1068,6 +1068,13 @@
themeInstalling = true;
try {
if ($active_custom_theme && $active_custom_theme.name === droppedTheme.themeInfo.name) {
const defaultTheme = $custom_themes.find((t) => t.name === 'Default');
if (defaultTheme) {
loadTheme(defaultTheme, $custom_theme_container!, $custom_theme_volume);
await config.value<string>('theme').set(defaultTheme.name);
}
}
await sileo.promise(
importThemeFromFile(droppedTheme.themeInfo.name, droppedTheme.filePath),
{