I'm strugling with my form in typescript react. Basicly I created 2 simple components `Button` and `Input` and add them to the another component `Form` where I created a whole form.

After submit I should get something like this:

```
telephone: "323423234"
email: "tress@wess.com"
message: "weklfnwlkf"
name: "less"
surname: "mess"

```

But after submit I get weird response like this:

```
"": "323423234"
email: "tress@wess.com"
message: "weklfnwlkf"
name: "less"
surname: "mess"
telephone: ""

```

It is a little bit werido because I done something like this couple days ago and now idk what to do.
There is sample of my `Form` code

```
const Form = () => {
  interface FormDataType {
    telephone: string;
    name: string;
    surname: string;
    email: string;
    message: string;
  }
  const formData: FormDataType = {
    telephone: '',
    name: '',
    surname: '',
    email: '',
    message: '',
  };
  const [responseBody, setResponseBody] = useState<FormDataType>(formData);

  const clearState = () => {
    setResponseBody({ ...formData });
  };

  const handleChange = (event: React.ChangeEvent<HTMLInputElement>) => {
    const { name, value } = event.target;
    setResponseBody({ ...responseBody, [name]: value });
  };
  const handleSubmit = (event: React.FormEvent<HTMLFormElement>) => {
    event.preventDefault();
    console.log(responseBody);
    clearState();
  };

  return (
    <>
      <form onSubmit={handleSubmit}>
        {FormData.map((option) => (
          <Input
            key={option.name}
            label={option.label}
            type={option.type}
            className={option.className}
            name={option.name}
            onChange={(e: React.ChangeEvent<HTMLInputElement>) =>
              handleChange(e)
            }
          />
        ))}
        <div className='div'>
          <Button
            type='submit'
            title={'Simple test'}
            className={'btn-primary'}
          />
        </div>
      </form>
    </>
  );
};
export default Form;

```

And when I'm invoking in `handleSubmit` function `clearState()` it doesn't refresh states in webpage inputs.