Skip to content

Commit

Permalink
fix(form): update onSubmit type
Browse files Browse the repository at this point in the history
Updates the `onSubmit` type so that the `Form` component can be used in conjunction with external
libraries such as `Formik`

fix #5659
  • Loading branch information
edleeks87 committed Jan 9, 2023
1 parent 3a1ade8 commit 03fd976
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/form/form.component.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export interface FormProps extends SpaceProps {
/** Disable HTML5 validation */
noValidate?: boolean;
/** Callback passed to the form element */
onSubmit?: React.FormEventHandler;
onSubmit?: React.FormEventHandler<HTMLFormElement>;
/** Additional buttons rendered on the right side of the save button */
rightSideButtons?: React.ReactNode;
/** Save button to be rendered */
Expand Down

0 comments on commit 03fd976

Please sign in to comment.