From b69e5edbf10fd00b8806247e39d5ef5799f9e930 Mon Sep 17 00:00:00 2001 From: jakeaturner Date: Fri, 12 Jan 2024 10:18:47 -0800 Subject: [PATCH] fix(CentralIdentity): keep default libraries open --- .../ApproveVerificationRequestModal.tsx | 70 ++++++++----------- 1 file changed, 29 insertions(+), 41 deletions(-) diff --git a/client/src/components/controlpanel/CentralIdentity/ApproveVerificationRequestModal.tsx b/client/src/components/controlpanel/CentralIdentity/ApproveVerificationRequestModal.tsx index f58d6d6a..9ac363c3 100644 --- a/client/src/components/controlpanel/CentralIdentity/ApproveVerificationRequestModal.tsx +++ b/client/src/components/controlpanel/CentralIdentity/ApproveVerificationRequestModal.tsx @@ -36,7 +36,6 @@ const ApproveVerificationRequestModal: React.FC< const [request, setRequest] = useState(); const [allApps, setAllApps] = useState([]); const [approvedApps, setApprovedApps] = useState([]); - const [showDefaultLibs, setShowDefaultLibs] = useState(false); // Effects useEffect(() => { @@ -225,46 +224,35 @@ const ApproveVerificationRequestModal: React.FC< className="mb-1r" /> ))} - - setShowDefaultLibs(!showDefaultLibs)} - > -
-
- - Change Default Libraries -
- {showDefaultLibs && ( -

{ - e.stopPropagation(); - handleSelectAllLibs(); - }} - > - Select All -

- )} -
-
- -
- {allApps - .filter((app) => app.is_default_library) - .map((app) => ( - handleCheckApp(app.id)} - className="mb-1r" - /> - ))} -
-
-
+
+
+

+ Change Default Libraries +

+

{ + e.stopPropagation(); + handleSelectAllLibs(); + }} + > + Select All +

+
+
+ {allApps + .filter((app) => app.is_default_library) + .map((app) => ( + handleCheckApp(app.id)} + className="mb-1r" + /> + ))} +
+
)}