/** * Whether the person has asked for less motion — by EITHER route. * * ★★ TWO SIGNALS, and the assistant's own animated text must obey both: * * - the operating system's `prefers-reduced-motion: reduce`; * - the app's own "Reduce motion" setting (ThemePreferences). `ThemeProvider` * writes its EFFECTIVE value — a custom theme's override included — to * ``, and `tokens.css` clamps every CSS animation * under that attribute. * * CSS covers the avatar, the caret and every `motion-safe:` class. It cannot * stop a phrase that JavaScript swaps every few seconds, which is why the chat * waiting line honoured only the OS setting and the voice status line honoured * neither (BOFF-7284). Reading the attribute rather than theme context keeps the * JS in lockstep with the CSS by construction, needs no change to * `ThemeProvider` (whose context is not exported, and whose `useTheme` throws * without a provider), and in a host with no `ThemeProvider` simply falls back * to the OS signal. */ export declare const REDUCED_MOTION_QUERY = "(prefers-reduced-motion: reduce)"; export declare const REDUCED_MOTION_ATTRIBUTE = "data-reduce-motion"; /** * The current answer, read fresh from the environment every time. * * ★ Guarded piece by piece — `window`, `matchMedia` and `document` are each * absent in some test or render environment here — and never cached: a test * may swap `window` between two renders, and a cached `MediaQueryList` would * keep answering for the old one. */ export declare function readReducedMotion(): boolean; /** * Call `onChange` whenever either signal may have changed. Returns the cleanup. * * ★ The attribute is written by a passive effect in `ThemeProvider`, one commit * after its state changes — the observer is what carries that change here * without a reload. */ export declare function subscribeReducedMotion(onChange: () => void): () => void; /** * React binding: re-renders the caller when either signal changes. * * ★★ The server snapshot is the SAME guarded reader, deliberately — not a * constant `false`. On a real server there is no `window`, so it answers false * anyway; under a test that stubs the environment it answers from the stub, which * is what lets a static render prove the reduced-motion path at all. Both host * apps mount with `createRoot`, so there is no hydration for this to mismatch. * * ★ Not for `hydrateRoot`: on hydration React calls the server snapshot on the * client, where this reader can answer true while the server's HTML was rendered * with false — a recoverable hydration mismatch. A future SSR consumer must pass * a constant server snapshot instead. */ export declare function usePrefersReducedMotion(): boolean; //# sourceMappingURL=usePrefersReducedMotion.d.ts.map