diff --git a/packages/mui-material-next/src/FilledInput/FilledInput.tsx b/packages/mui-material-next/src/FilledInput/FilledInput.tsx index 5e4cb3655a1ef8..5b50df431318bb 100644 --- a/packages/mui-material-next/src/FilledInput/FilledInput.tsx +++ b/packages/mui-material-next/src/FilledInput/FilledInput.tsx @@ -460,7 +460,6 @@ FilledInput.propTypes /* remove-proptypes */ = { slots: PropTypes.shape({ input: PropTypes.elementType, root: PropTypes.elementType, - textarea: PropTypes.elementType, }), /** * Start `InputAdornment` for this component. diff --git a/packages/mui-material-next/src/FilledInput/FilledInput.types.ts b/packages/mui-material-next/src/FilledInput/FilledInput.types.ts index aa76a32c9cc3d2..81a694f2085274 100644 --- a/packages/mui-material-next/src/FilledInput/FilledInput.types.ts +++ b/packages/mui-material-next/src/FilledInput/FilledInput.types.ts @@ -7,7 +7,7 @@ import { Theme } from '../styles/Theme.types'; import { InputBaseProps } from '../InputBase/InputBase.types'; import { FilledInputClasses } from './filledInputClasses'; -export type FilledInputOwnProps = StandardProps & { +export type FilledInputOwnProps = StandardProps> & { /** * Override or extend the styles applied to the component. */ @@ -23,12 +23,31 @@ export type FilledInputOwnProps = StandardProps & { * If `true`, the input will not have an underline. */ disableUnderline?: boolean; + /** + * The components used for each slot inside the InputBase. + * Either a string to use a HTML element or a component. + * @default {} + */ + slots?: FilledInputSlots; /** * The system prop that allows defining system overrides as well as additional CSS styles. */ sx?: SxProps; }; +export interface FilledInputSlots { + /** + * The component that renders the root. + * @default 'div' + */ + root?: React.ElementType; + /** + * The component that renders the input. + * @default 'input' + */ + input?: React.ElementType; +} + export interface FilledInputTypeMap< AdditionalProps = {}, RootComponentType extends React.ElementType = 'div',