import { ForwardedRef, Ref } from "react"; //#region src/hooks/useMergedRefs.d.ts /** * Combine two refs of matching type (typically an external or forwarded ref and an internal `useRef` object or * callback ref). * * If you need to combine more than two refs (what are you doing?) just nest the hook: * `useMergedRefs(refA, useMergedRefs(refB, refC))` * * @param refA First ref to merge. The order is not important. * @param refB Second ref to merge. The order is not important. * @returns A new ref which must be passed to the relevant child component. **Important**: do not pass `refA` or * `refB` to the component! * * @example * // React 18 * const Example = forwardRef((props, forwardedRef) => { * const ref = useRef(null) * const mergedRef = useMergedRefs(forwardedRef, ref) * * return