import { useRef as c, useCallback as t } from "react";
const f = (o, r) => {
  const s = c(0);
  return { scrollToTop: t(() => {
    r.current && requestAnimationFrame(() => {
      r.current.scrollTop(0), s.current = 0, o && o.scrollToOffset(0);
    });
  }, [r, o]) };
};
export {
  f as useTreeScrollPosition
};
//# sourceMappingURL=useTreeScrollPosition.js.map
