import { type ReactNode } from 'react'; import type { FlowStep, HelperInternalState, HelperState, ParsedTooltipData, Placement, TipMagicOptions, TipMagicState } from '../types'; export type { FlowState, HelperInternalState, ParsedTooltipData, TipMagicState, TooltipState, } from '../types'; /** * Create initial state with options */ export declare function createInitialState(options?: TipMagicOptions): TipMagicState; /** * Action types for the reducer */ export type TipMagicAction = { type: 'SHOW_TOOLTIP'; payload: { target: Element; content: string; parsedData: ParsedTooltipData; }; } | { type: 'HIDE_TOOLTIP'; } | { type: 'MOVE_TOOLTIP'; payload: { target: Element; content: string; parsedData: ParsedTooltipData; previousGroup?: string; }; } | { type: 'UPDATE_TOOLTIP_POSITION'; payload: { x: number; y: number; placement: Placement; }; } | { type: 'UPDATE_TOOLTIP_CONTENT'; payload: string; } | { type: 'SET_TOOLTIP_TRANSITIONING'; payload: boolean; } | { type: 'SHOW_HELPER'; payload: Partial; } | { type: 'HIDE_HELPER'; } | { type: 'SET_HELPER_STATE'; payload: HelperState; } | { type: 'MOVE_HELPER'; payload: string; } | { type: 'START_FLOW'; payload: FlowStep[]; } | { type: 'NEXT_FLOW_STEP'; } | { type: 'PREV_FLOW_STEP'; } | { type: 'SET_FLOW_STEP'; payload: number; } | { type: 'END_FLOW'; }; /** * Reducer for TipMagic state */ export declare function tipMagicReducer(state: TipMagicState, action: TipMagicAction): TipMagicState; /** * Context value interface */ export interface TipMagicContextValue { state: TipMagicState; dispatch: React.Dispatch; } /** * Create the context */ export declare const TipMagicContext: import("react").Context; /** * Hook to access TipMagic context */ export declare function useTipMagicContext(): TipMagicContextValue; /** * Provider props */ export interface TipMagicContextProviderProps { children: ReactNode; options?: TipMagicOptions; } /** * Context provider component */ export declare function TipMagicContextProvider({ children, options }: TipMagicContextProviderProps): import("react/jsx-runtime").JSX.Element; //# sourceMappingURL=TipMagicContext.d.ts.map