Wizard: add support for other input type in HookValidatedInput
adds `type` prop to `HookValidatedInput` with a default of 'text', to be able to support other type input like 'password'
This commit is contained in:
parent
0f111a4e6a
commit
ba9546193e
1 changed files with 2 additions and 1 deletions
|
|
@ -38,6 +38,7 @@ export const HookValidatedInput = ({
|
|||
onChange,
|
||||
stepValidation,
|
||||
fieldName,
|
||||
type = 'text',
|
||||
}: HookValidatedTextInputPropTypes) => {
|
||||
const [isPristine, setIsPristine] = useState(!value ? true : false);
|
||||
// Do not surface validation on pristine state components
|
||||
|
|
@ -60,7 +61,7 @@ export const HookValidatedInput = ({
|
|||
value={value}
|
||||
data-testid={dataTestId}
|
||||
ouiaId={ouiaId}
|
||||
type="text"
|
||||
type={type}
|
||||
onChange={onChange}
|
||||
validated={validated}
|
||||
aria-label={ariaLabel}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue