@nuitral/react-ui-suite
Version:
nuitral React UI Suite
16 lines (15 loc) • 608 B
TypeScript
import { NuitralThemingOptions } from '@nuitral/types';
/**
* Hook that handles theming and dark mode.
*
* It applies the selected theme and mode ( light/dark ) to the root element ( rootId ) of the application.
* Optionally, it can persist settings to localStorage if the `saveSettings` option is enabled.
*
*/
declare const useNuitralTheming: ({ theme, darkMode, lightModeName, darkModeName, rootId, saveSettings, }: NuitralThemingOptions) => {
manageDarkMode: () => void;
isDarkMode: any;
manageTheme: (newTheme: string) => void;
themeName: any;
};
export default useNuitralTheming;