import { DataAttributes } from '../../types/html-props.mjs'; import { AsElementProps } from '../../types/shared.mjs'; import { ForwardRefExoticComponent, RefAttributes, ReactNode, ForwardRefRenderFunction } from 'react'; /** * This file was copied from https://github.com/mantinedev/mantine/blob/master/packages/%40mantine/core/src/core/factory/factory.ts */ type FactoryPayload = { props: Record; ref?: any; staticComponents?: Record; }; type Factory = TPayload; type StaticComponents = TComponentMap extends Record ? TComponentMap : Record; type ComponentStaticProperties = StaticComponents; type Component = ForwardRefExoticComponent & AsElementProps & DataAttributes & { renderRoot?: (props: Record) => ReactNode; }> & ComponentStaticProperties; declare function factory(ui: ForwardRefRenderFunction): Component; export { factory }; export type { Component, ComponentStaticProperties, Factory, FactoryPayload, StaticComponents };