From 8131cc4a5fb8ba4bfc4abf0d78206feefe103876 Mon Sep 17 00:00:00 2001 From: benjaminjohnson2204 Date: Mon, 27 May 2024 16:41:46 -0700 Subject: [PATCH] Save edits from VSR individual page directly rather than showing confirmation popup --- .../VSRIndividual/VSRIndividualPage/index.tsx | 33 +------------------ 1 file changed, 1 insertion(+), 32 deletions(-) diff --git a/frontend/src/components/VSRIndividual/VSRIndividualPage/index.tsx b/frontend/src/components/VSRIndividual/VSRIndividualPage/index.tsx index e98a58d..56ba87e 100644 --- a/frontend/src/components/VSRIndividual/VSRIndividualPage/index.tsx +++ b/frontend/src/components/VSRIndividual/VSRIndividualPage/index.tsx @@ -68,7 +68,6 @@ export const VSRIndividualPage = () => { const [loadingUpdateStatus, setLoadingUpdateStatus] = useState(false); const [discardEditsConfirmationModalOpen, setDiscardEditsConfirmationModalOpen] = useState(false); - const [saveEditsConfirmationModalOpen, setSaveEditsConfirmationModalOpen] = useState(false); const [editSuccessNotificationOpen, setEditSuccessNotificationOpen] = useState(false); const [editErrorNotificationOpen, setEditErrorNotificationOpen] = useState(false); const [loadingEdit, setLoadingEdit] = useState(false); @@ -321,7 +320,7 @@ export const VSRIndividualPage = () => { iconAlt="Check" text="Save Changes" hideTextOnMobile - onClick={() => setSaveEditsConfirmationModalOpen(true)} + onClick={(e) => handleSubmit(onSubmitEdits)(e)} /> ) : ( @@ -694,36 +693,6 @@ export const VSRIndividualPage = () => { /> {/* Modals & notifications for saving changes to VSR */} - setSaveEditsConfirmationModalOpen(false)} - title="Save Changes" - content="Would you like to save your changes?" - bottomRow={ -
-
- } - />