import * as React from 'react'; import type { ComponentRenderFn } from './types'; import { CustomStyleHookMapping } from './getStyleHookProps'; import { defaultRenderFunctions } from './defaultRenderFunctions'; export interface ComponentRendererSettings { /** * The class name to apply to the rendered element. * Can be a string or a function that accepts the owner state and returns a string. */ className?: string | ((state: OwnerState) => string); /** * The render prop or React element to override the default element. */ render: ComponentRenderFn, OwnerState> | React.ReactElement> | keyof typeof defaultRenderFunctions; /** * The owner state of the component. */ ownerState: OwnerState; /** * The ref to apply to the rendered element. */ ref?: React.Ref; /** * A function that returns props for the rendered element. * It should accept and merge additional props. */ propGetter?: (externalProps: Record) => React.HTMLAttributes & React.RefAttributes; /** * Additional props to be spread on the rendered element. */ extraProps?: Record; /** * A mapping of owner state to style hooks. */ customStyleHookMapping?: CustomStyleHookMapping; } /** * Returns a function that renders a Base UI component. * * @ignore - internal hook. */ export declare function useComponentRenderer, RenderedElementType extends Element>(settings: ComponentRendererSettings): { renderElement: () => React.ReactElement, string | React.JSXElementConstructor>; };