mirror of
https://gitlab.com/soapbox-pub/mkstack.git
synced 2026-12-05 16:33:36 +00:00
Refactor AppProvider, AppConfig and presetRelays
This commit is contained in:
8 files changed
+46
-26
No files matched your search
@@ -1,12 +1,12 @@
|
||||
import { type Theme } from "@/contexts/AppContext";
|
||||
import { useAppConfig } from "@/hooks/useAppConfig";
|
||||
import { useAppContext } from "@/hooks/useAppContext";
|
||||
|
||||
/**
|
||||
* Hook to get and set the active theme
|
||||
* @returns Theme context with theme and setTheme
|
||||
*/
|
||||
export function useTheme(): { theme: Theme; setTheme: (theme: Theme) => void } {
|
||||
const { config, updateConfig } = useAppConfig();
|
||||
const { config, updateConfig } = useAppContext();
|
||||
|
||||
return {
|
||||
theme: config.theme,
|
||||
|
||||
Reference in new issue
Block a user