/** * StreamCrafter Context * React context for sharing StreamCrafter state across components */ import { type ReactNode } from "react"; import { type UseStreamCrafterV2Options as UseStreamCrafterOptions, type UseStreamCrafterV2Return as UseStreamCrafterReturn } from "../hooks/useStreamCrafterV2"; export type StreamCrafterProviderProps = { children: ReactNode; } & ({ config: UseStreamCrafterOptions; value?: never; } | { value: UseStreamCrafterReturn; config?: never; }); /** * Provides StreamCrafter state to child components. * * Two modes: * - `config` — creates a new hook instance internally * - `value` — wraps children with a pre-computed hook return (used by StreamCrafter component) */ export declare function StreamCrafterProvider({ children, config, value }: StreamCrafterProviderProps): import("react/jsx-runtime").JSX.Element; export declare function useStreamCrafterContext(): UseStreamCrafterReturn; /** Returns the context value or null if not inside a provider. */ export declare function useStreamCrafterContextOptional(): UseStreamCrafterReturn | null;