feat: implement 4-theme system with Zustand persistence

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Consultoria AS
2026-01-22 01:58:24 +00:00
parent cbc48cfe26
commit 4389f50e7d
9 changed files with 203 additions and 2 deletions

View File

@@ -0,0 +1,20 @@
import { create } from 'zustand';
import { persist } from 'zustand/middleware';
import type { ThemeName } from '@/themes';
interface ThemeState {
theme: ThemeName;
setTheme: (theme: ThemeName) => void;
}
export const useThemeStore = create<ThemeState>()(
persist(
(set) => ({
theme: 'light',
setTheme: (theme) => set({ theme }),
}),
{
name: 'horux-theme',
}
)
);