import { type CarbonTheme, type Theme, type ThemeMode } from '../core/theme.js'; /** * The light / dark / system theme choice as a hook, no markup (core/theme): what the styled * ThemeSwitcher and `` keep. One store per page: every `useThemeMode` (headless or * styled), every `` and other tabs follow each other's picks. * * ```tsx * const [mode, setMode] = useThemeMode({ storageKey: 'app-theme' }); * * ``` */ export type { CarbonTheme, ThemeChangeDetail, ThemeMode } from '../core/theme.js'; export interface UseThemeModeOptions { /** The mode shown, owned by the app (e.g. from a profile on the server); it is applied and remembered when it changes. */ value?: ThemeMode; /** The mode to start on when nothing is remembered (else what `` shows, else light). */ defaultValue?: ThemeMode; /** The Carbon theme of light (white or g10). */ lightTheme?: CarbonTheme; /** The Carbon theme of dark (g90 or g100). */ darkTheme?: CarbonTheme; /** The `localStorage` key; '' = don't remember. */ storageKey?: string; } /** * The light / dark / system choice as `` keeps it (core/theme): the mode — the * remembered one, else `defaultValue`, else what `` shows — shown on `` (system follows the OS while it changes), and `setMode` that shows, remembers and * announces a new one. Every switcher on the page and in other tabs follows. On a server `defaultValue` * or light; put `themeScript()` in `` so the first paint has the remembered theme. */ export declare function useThemeMode({ value, defaultValue, lightTheme, darkTheme, storageKey }?: UseThemeModeOptions): readonly [ThemeMode, (next: ThemeMode) => Theme];