import { type ReactElement, type ReactPortal } from 'react'; type ItemWithReactElementComponent = T & { component?: ReactElement | string; children?: Array>; }; type ItemWithHTMLElementComponent = T & { component?: HTMLElement | string; children?: Array>; __item?: ItemWithReactElementComponent; }; /** * This function transforms a hierarchical list of items, where each item may contain a React component, * into a list of items where each React component is replaced with an HTMLElement. * * The React components are not simply removed, but are instead rendered into portals. * The HTMLElements created for the portals have the given tag name. */ export declare function mapItemsWithComponents(items?: Array>, wrapperTagName?: string): [Array, Array>> | undefined]; /** * Returns the original item related to the given mapped item. */ export declare function getOriginalItem(mappedItem: ItemWithHTMLElementComponent): { component?: ReactElement | string; children?: /*elided*/ any[] | undefined; } | undefined; export {}; //# sourceMappingURL=mapItemsWithComponents.d.ts.map