weasel API - v0.8.0
    Preparing search index...

    Interface UseDragRadialOptions<TScratch>

    interface UseDragRadialOptions<TScratch = unknown> {
        initScratch?: () => TScratch;
        minRadius?: number;
        onCancel?: (ctx: DragRadialCtx<TScratch>) => void;
        onEnd?: (ctx: DragRadialEndCtx<TScratch>) => boolean | void;
        onGestureEnd?: (committed: boolean) => void;
        onGestureStart?: () => void;
        onMove?: (ctx: DragRadialCtx<TScratch>) => void;
        onStart?: (ctx: DragRadialCtx<TScratch>) => void;
        snapPoint?: (p: DragRadialPoint) => DragRadialPoint;
    }

    Type Parameters

    • TScratch = unknown
    Index

    Properties

    initScratch?: () => TScratch
    minRadius?: number
    onCancel?: (ctx: DragRadialCtx<TScratch>) => void
    onEnd?: (ctx: DragRadialEndCtx<TScratch>) => boolean | void
    onGestureEnd?: (committed: boolean) => void
    onGestureStart?: () => void
    onMove?: (ctx: DragRadialCtx<TScratch>) => void
    onStart?: (ctx: DragRadialCtx<TScratch>) => void
    snapPoint?: (p: DragRadialPoint) => DragRadialPoint

    Optional: snap world-space points to the active grid (or any other snap target). Applied to both the center (on onStart) and the current cursor (on onMove), so the live overlay's radius/rotation is computed from snapped points instead of raw cursor positions. When omitted, behavior is identical to today (identity passthrough).