feat: implement theme selection and system integration

This commit is contained in:
sagitchu
2026-03-20 22:47:49 +08:00
parent 9f0670f4d0
commit bd4e1f66cb
17 changed files with 1834 additions and 105 deletions
+45
View File
@@ -0,0 +1,45 @@
/**
* @module @/themes
* Public API for the FLVX theme system.
*
* Usage:
* import { ThemeProvider, useThemeContext, registerTheme } from "@/themes";
*/
export type {
ThemePackage,
ThemeTokens,
ComponentKey,
LayoutKey,
PageKey,
} from "./types";
export {
registerTheme,
unregisterTheme,
getRegisteredThemes,
getTheme,
getActiveThemeId,
getActiveTheme,
activateTheme,
deactivateTheme,
reapplyActiveTheme,
initThemeSystem,
resolveComponent,
resolveLayout,
resolvePage,
getSavedMode,
saveMode,
getEffectiveMode,
subscribe,
} from "./registry";
export type { ThemeMode } from "./registry";
export {
ThemeProvider,
useThemeContext,
useThemedComponent,
useThemedLayout,
useThemedPage,
} from "./context";