import { default as React } from 'react'; import { HydrationContextValue, HydrationProviderProps } from './types'; /** * Hydration context for accessing the hydration system. */ declare const HydrationContext: React.Context; /** * Global provider for the Auto-Prioritized Hydration System. * * This component manages the hydration scheduler and provides context to all * HydrationBoundary components in the tree. * * @param props - Provider props * @returns The provider wrapping children * * @example * ```tsx * { * analytics.track('hydration_complete', metric); * }} * > * * * ``` */ export declare function HydrationProvider({ children, config: configOverrides, onMetric, autoStart, integrateWithPerformance, }: HydrationProviderProps): React.JSX.Element; /** * Hook to access the hydration context. * * @returns The hydration context value * @throws If used outside of HydrationProvider * * @example * ```tsx * function MyComponent() { * const { forceHydrate, getMetrics } = useHydrationContext(); * * const handleClick = () => { * forceHydrate('my-boundary'); * }; * * return ; * } * ``` */ export declare function useHydrationContext(): HydrationContextValue; /** * Hook to optionally access the hydration context. * Returns null if not within a HydrationProvider. * * @returns The hydration context value, or null * * @example * ```tsx * function OptionalHydrationComponent() { * const hydration = useOptionalHydrationContext(); * * if (!hydration) { * // Render without hydration features * return
No hydration
; * } * * return
Hydration enabled
; * } * ``` */ export declare function useOptionalHydrationContext(): HydrationContextValue | null; export { HydrationContext }; export type { HydrationContextValue, HydrationProviderProps };