feat: dark theme applies to editor content area
Three changes make the editor respect the active theme: 1. useThemeManager now derives app-specific CSS variables (--bg-primary, --text-primary, --border-primary, etc.) from the theme's core colors, so the editor's EditorTheme.css variables resolve correctly for both light and dark themes. 2. BlockNoteView theme prop is now dynamic (isDark ? 'dark' : 'light') instead of hardcoded to 'light', so BlockNote's own UI chrome (menus, toolbars) matches the active theme. 3. Removed forced light-mode class removal from main.tsx that was preventing dark mode from being applied. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -40,6 +40,7 @@ const mockThemeManager: ThemeManager = {
|
||||
themes: [],
|
||||
activeThemeId: null,
|
||||
activeTheme: null,
|
||||
isDark: false,
|
||||
switchTheme: vi.fn(),
|
||||
createTheme: vi.fn().mockResolvedValue('untitled'),
|
||||
reloadThemes: vi.fn(),
|
||||
|
||||
Reference in New Issue
Block a user