mirror of
https://github.com/logos-messaging/logos-delivery-js.git
synced 2026-03-13 21:23:38 +00:00
25 lines
575 B
TypeScript
25 lines
575 B
TypeScript
|
|
import { TextField } from '@material-ui/core';
|
||
|
|
import React, { ChangeEvent } from 'react';
|
||
|
|
|
||
|
|
interface Props {
|
||
|
|
password: string | undefined;
|
||
|
|
setPassword: (password: string) => void;
|
||
|
|
}
|
||
|
|
|
||
|
|
export default function PasswordInput({ password, setPassword }: Props) {
|
||
|
|
const handlePasswordChange = (event: ChangeEvent<HTMLInputElement>) => {
|
||
|
|
setPassword(event.target.value);
|
||
|
|
};
|
||
|
|
|
||
|
|
return (
|
||
|
|
<TextField
|
||
|
|
id="password-input"
|
||
|
|
label="Password"
|
||
|
|
variant="filled"
|
||
|
|
type="password"
|
||
|
|
onChange={handlePasswordChange}
|
||
|
|
value={password}
|
||
|
|
/>
|
||
|
|
);
|
||
|
|
}
|