packageDocumentation module import "./IconInput.scss" ; import classnames from "classnames" ; import * as React from "react" ; import { Input , InputProps } from "../Input" ; public export interface IconInputProps extends Omit < InputProps , "size" > { /** Icon displayed to the left of the Input field within the IconInput component */ icon : React . ReactNode ; /** CSS class name for the IconInput component container div */ containerClassName ? : string ; /** Provides ability to return reference to HTMLInputElement */ ref ? : React . Ref < HTMLInputElement > ; /** Modify size of the input. */ size ? : "small" | "large" ; } public const ForwardRefIconInput = React . forwardRef < HTMLInputElement , IconInputProps > ( function ForwardRefIconInput ( props , ref ) { const { icon , containerClassName , size , ... otherProps } = props ; return ( < div className = { classnames ( "core-iconInput-container" , containerClassName ) } > { } < Input ref = { ref } { ... otherProps } /> < div className = "core-iconInput-icon" > { icon } < /div> < /div>); } ) ; public export const IconInput = ForwardRefIconInput ;