UNPKG

@itwin/itwinui-react

Version:

A react component library for iTwinUI

9 lines (8 loc) 674 B
import * as React from 'react'; /** * Wrapper over `cloneElement` that automatically checks for `isValidElement` * and automatically merges `children.ref` with the ref passed in props. * * @private */ export declare const cloneElementWithRef: (children: React.ReactNode, getProps: (children: React.JSX.Element) => Record<string, unknown>) => string | number | bigint | true | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | null;