forked from github/plane
fix: create workspace valid (#1535)
show alert on-change rather then on-submit
This commit is contained in:
parent
9d891ecce1
commit
9b423cea4b
@ -62,7 +62,7 @@ export const CreateWorkspaceForm: React.FC<Props> = ({
|
|||||||
setValue,
|
setValue,
|
||||||
getValues,
|
getValues,
|
||||||
formState: { errors, isSubmitting },
|
formState: { errors, isSubmitting },
|
||||||
} = useForm<IWorkspace>({ defaultValues });
|
} = useForm<IWorkspace>({ defaultValues, mode: "onChange" });
|
||||||
|
|
||||||
const handleCreateWorkspace = async (formData: IWorkspace) => {
|
const handleCreateWorkspace = async (formData: IWorkspace) => {
|
||||||
await workspaceService
|
await workspaceService
|
||||||
|
Loading…
Reference in New Issue
Block a user