From 6c4c6db0d72573118c7f92512521a5c53946a6eb Mon Sep 17 00:00:00 2001 From: Pramod Mahajan Date: Thu, 8 May 2025 10:45:49 +0530 Subject: [PATCH] added form submission logic with loading state management --- src/components/Project/ManageProjectInfo.jsx | 13 +++++++------ src/components/Project/ProjectBanner.jsx | 4 ++-- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/src/components/Project/ManageProjectInfo.jsx b/src/components/Project/ManageProjectInfo.jsx index 2ae2ad2e..8b1550fc 100644 --- a/src/components/Project/ManageProjectInfo.jsx +++ b/src/components/Project/ManageProjectInfo.jsx @@ -98,12 +98,13 @@ const ManageProjectInfo = ({ project, handleSubmitForm, onClose }) => { const onSubmitForm = (updatedProject) => { setLoading(true); - handleSubmitForm(updatedProject); + + handleSubmitForm( updatedProject ,setLoading); + + }; - useEffect(() => { - return () => setLoading(false); - }, []); + return (
{ )}
-