import { type ReactNode } from 'react'; import { type IUseToastReturn } from './useToast'; /** * Props for the ToastProvider component. * * @public */ export interface IToastProviderProps { /** * Child components that will have access to the toast context. */ children: ReactNode; } /** * Provider component that makes toast functionality available to all child components. * * @remarks * Place this provider at the root of your application or at a level where all * components that need toast access are descendants. * * @example * ```tsx * // In your app root * function App() { * return ( * * * * ); * } * ``` * * @public * @param props - The provider props. * @returns The provider component wrapping children. */ export declare function ToastProvider({ children }: IToastProviderProps): ReactNode; /** * Hook to access the toast context. * * @remarks * This hook must be used within a ToastProvider. If you don't need the provider pattern, * use `useToast` directly instead. * * @example * ```tsx * function MyComponent() { * const toast = useToastContext(); * * return ( * * ); * } * ``` * * @public * @returns The toast context value. * @throws Error if used outside of a ToastProvider. */ export declare function useToastContext(): IUseToastReturn; //# sourceMappingURL=ToastContext.d.ts.map