import React from "react";
/**
 * Returns the first component of type CompoundType in the first parameter array
 * (usually a compound component's children array).
 */
export declare function extractCompound<T>(children: React.ReactNode, CompoundType: React.FC<T>): React.ReactElement<T> | undefined;
/**
 * Returns all components of type CompoundType in the first parameter array
 * (usually a compound component's children array).
 */
export declare function extractCompounds<T>(children: React.ReactNode, CompoundType: React.FC<T>): React.ReactElement<T>[];
/**
 * Returns all components whose types are not in the excludedCompoundTypes in the
 * first parameter array (usually a compound component's children array).
 */
export declare function extractRest(children: React.ReactNode, excludedCompoundTypes: React.FC<unknown>[]): (React.ReactChild | React.ReactFragment | React.ReactPortal)[];
/**
 * Create a React Component that takes props T and has the given display
 * name.
 *
 * This component does nothing but display the children passed to it.
 */
export declare function CreateBaseCompound<T>(displayName: string): {
    ({ children }: React.PropsWithChildren<T>): React.JSX.Element;
    displayName: string;
};
/**
 * Checks if the component has children.
 */
export declare function hasChildren(component: React.ReactNode): boolean;
/**
 * Extract the Props type out of a component.
 *
 * Often useful for compound components.
 */
export type GetProps<C extends React.FC<unknown>> = C extends React.FC<infer T> ? T : unknown;
