export type SwipeAxis = "horizontal" | "vertical" | null; export interface SwipeRelease { /** Commit action suggested by gesture analysis. */ action: "next" | "prev" | "dismiss" | "cancel"; /** Final velocity in px/ms on the dominant axis. */ velocity: number; dx: number; dy: number; } export interface SwipeNavigatorOptions { /** Min pixel drift before an axis is locked. Default 8. */ axisLockThreshold?: number; /** Fraction of width that commits horizontal nav. Default 0.25. */ horizontalCommit?: number; /** Fraction of height that commits vertical dismiss. Default 0.2. */ verticalCommit?: number; /** Minimum velocity (px/ms) that commits regardless of distance. */ flingVelocity?: number; } export declare class SwipeNavigator { private readonly opts; private samples; private startX; private startY; private dx; private dy; private axis; private active; constructor(options?: SwipeNavigatorOptions); get isActive(): boolean; get currentAxis(): SwipeAxis; begin(x: number, y: number, t: number): void; /** Returns current drift and locked axis; does not apply any transform. */ move(x: number, y: number, t: number): { dx: number; dy: number; axis: SwipeAxis; }; release(viewportWidth: number, viewportHeight: number, direction?: "ltr" | "rtl"): SwipeRelease; cancel(): void; }