react-ui-animate
Version:
React library for gestures and animation
12 lines (11 loc) • 643 B
TypeScript
import { RefObject } from 'react';
import { MotionValue } from '@raidipesh78/re-motion';
import { type ScrollEvent } from '../controllers/ScrollGesture';
import { type UseScrollProgressOptions } from '../../hooks/observers/useScrollProgress';
export declare function useScroll<T extends HTMLElement>(refs: Window | RefObject<T> | RefObject<T>[], onScroll: (e: ScrollEvent & {
index: number;
}) => void): void;
export declare function useScroll<T extends HTMLElement>(refs: Window | RefObject<T> | RefObject<T>[], options?: UseScrollProgressOptions): {
scrollYProgress: MotionValue<number>;
scrollXProgress: MotionValue<number>;
};