Files
2024-02-15 17:01:50 +00:00

16 lines
590 B
TypeScript

import type {InputFieldProps} from './inputField';
import InputField from './inputField';
export interface SecretFieldProps extends Omit<InputFieldProps, 'type'> {}
function SecretField(props: SecretFieldProps) {
// XXX: We explicitly give the password field a aria textbox role. This field
// does not typically have a role, but for testability reasons it's preferred
// for it to have a role. See [0]
//
// [0]: https://github.com/testing-library/dom-testing-library/issues/567
return <InputField {...props} type="password" role="textbox" />;
}
export default SecretField;