Skip to content

Open source website builder and Webflow alternative. Webstudio is an advanced visual builder that connects to any headless CMS, supports all CSS properties, and can be hosted anywhere, including with us.

allow other potential classes on the root to stay

Oleg Isonen1e93f4318ada
diff --git a/apps/designer/app/shared/theme/theme.ts b/apps/designer/app/shared/theme/theme.ts
index 444ce09210..23ea40f215 100644
--- a/apps/designer/app/shared/theme/theme.ts
+++ b/apps/designer/app/shared/theme/theme.ts
@@ -47,8 +47,8 @@ const renderThemeProps = () => {
const theme = getColorScheme();
const root = document.documentElement;
theme === "dark"
- ? (root.className = darkTheme.className)
- : root.removeAttribute("class");
+ ? root.classList.add(darkTheme.className)
+ : root.classList.remove(darkTheme.className);
root.style.colorScheme = theme;
root.dataset.theme = theme;
};