import { ReactElement, Ref } from 'react'; /** * Helper type for a ReactElement whose props may carry a `ref`. * Since React 19, `ref` is a regular prop. */ export type ReactElementWithRef = ReactElement

; }>; /** * Extracts the ref from a ReactElement. * * Since React 19, `ref` lives in `element.props.ref`. Reading the legacy * `element.ref` logs "Accessing element.ref was removed in React 19.", so * it is never accessed here. */ export declare function getElementRef(element: ReactElementWithRef): Ref | undefined;