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.

disable dark theme for now until we got it up-to-date

Oleg Isonenadc268e7af15
diff --git a/apps/designer/app/designer/features/topbar/menu/menu.tsx b/apps/designer/app/designer/features/topbar/menu/menu.tsx
index cdb215fdf6..f12f2001b7 100644
--- a/apps/designer/app/designer/features/topbar/menu/menu.tsx
+++ b/apps/designer/app/designer/features/topbar/menu/menu.tsx
@@ -27,6 +27,7 @@ import {
} from "~/shared/theme";
import { useClientSettings } from "~/designer/shared/client-settings";
import { dashboardPath } from "~/shared/router-utils";
+import { isFeatureEnabled } from "~/shared/feature-flags";
const menuItemCss = {
display: "flex",
@@ -37,6 +38,9 @@ const menuItemCss = {
};
const ThemeMenuItem = () => {
+ if (isFeatureEnabled("dark") === false) {
+ return null;
+ }
const currentSetting = getThemeSetting();
const labels: Record<ThemeSetting, string> = {
light: "Light",
diff --git a/apps/designer/app/shared/feature-flags/flags.ts b/apps/designer/app/shared/feature-flags/flags.ts
index 972e842029..c9639f6b34 100644
--- a/apps/designer/app/shared/feature-flags/flags.ts
+++ b/apps/designer/app/shared/feature-flags/flags.ts
@@ -1,2 +1,3 @@
export const designTokens = false;
export const example = false;
+export const dark = false;
diff --git a/apps/designer/app/shared/theme/theme.ts b/apps/designer/app/shared/theme/theme.ts
index 411225e8ff..3fe0d4a915 100644
--- a/apps/designer/app/shared/theme/theme.ts
+++ b/apps/designer/app/shared/theme/theme.ts
@@ -1,10 +1,11 @@
import { useLoaderData } from "@remix-run/react";
import { darkTheme } from "@webstudio-is/design-system";
import { restThemePath } from "~/shared/router-utils";
+import { isFeatureEnabled } from "../feature-flags";
import type { ColorScheme, ThemeSetting } from "./types";
// User selected theme setting.
-let setting: ThemeSetting = "system";
+let setting: ThemeSetting = isFeatureEnabled("dark") ? "system" : "light";
// Current systeme theme.
let system: ColorScheme;