Form component should have a disabled prop, which disables submission even with the Enter key
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 90
- Forks
- 5
- PR merge metrics
- No merged PRs in 30d
Description
We recently had a bug where we disabled the `FormSubmit` component (using its `disabled` prop), but the `Form` could still be submitted with the Enter key. To avoid this situation, there should be a `disabled` prop on the `Form` component, which we could have set to `true`.
(In the meantime, the workaround is to do nothing in the `handleFormData` callback when the form *should* be disabled.)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the Form component and trace how submission is handled when the Enter key is pressed. Add the requested disabled behavior so a disabled Form cannot submit through that path, and verify that the existing FormSubmit behavior remains consistent.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100