diff --git a/index.html b/index.html
index 2be2e94..17a7233 100644
--- a/index.html
+++ b/index.html
@@ -5,6 +5,26 @@
(() => {
const saved = localStorage.getItem(STORAGE_KEY)
@@ -102,8 +106,14 @@ function App() {
className={`min-h-screen flex flex-col items-center justify-start p-4 relative ${chaosClass('perspective-crazy')}`}
style={{ overflow: 'visible', background: currentTheme.value }}
>
- {/* Background theme switcher */}
-
+ {/* Background theme + dark mode switcher */}
+
{/* FLOATING CHAOS - ABSOLUTE POSITIONED MADNESS - Only in chaos mode */}
{chaosMode && (
diff --git a/src/components/BackgroundSwitcher.tsx b/src/components/BackgroundSwitcher.tsx
index b1b08e3..48fe226 100644
--- a/src/components/BackgroundSwitcher.tsx
+++ b/src/components/BackgroundSwitcher.tsx
@@ -2,13 +2,23 @@ import { useState } from 'react'
import { Button } from '@/components/ui/button'
import { BG_THEMES, type BgTheme } from '@/lib/themes'
import { useTutorial } from '@/lib/tutorial'
+import { type ColorModePreference, type ColorMode } from '@/lib/colorMode'
interface BackgroundSwitcherProps {
currentThemeId: string
onThemeChange: (theme: BgTheme) => void
+ colorModePreference: ColorModePreference
+ resolvedColorMode: ColorMode
+ onColorModeChange: (pref: ColorModePreference) => void
}
-export function BackgroundSwitcher({ currentThemeId, onThemeChange }: BackgroundSwitcherProps) {
+export function BackgroundSwitcher({
+ currentThemeId,
+ onThemeChange,
+ colorModePreference,
+ resolvedColorMode,
+ onColorModeChange,
+}: BackgroundSwitcherProps) {
const [open, setOpen] = useState(false)
const { start: startTutorial, completed: tutorialCompleted } = useTutorial()
@@ -62,6 +72,43 @@ export function BackgroundSwitcher({ currentThemeId, onThemeChange }: Background
))}
+
+ {/* Color mode selector */}
+
+
COLOR MODE:
+
+ {(['system', 'light', 'dark'] as const).map((pref) => {
+ const labels = { system: 'System', light: 'Light', dark: 'Dark' }
+ const isSelected = colorModePreference === pref
+ return (
+
+ )
+ })}
+
+ {colorModePreference === 'system' && (
+
+ effective: {resolvedColorMode}
+
+ )}
+
+