fix: resets the state of adding a new panel (#3122)

Co-authored-by: Vishal Sharma <makeavish786@gmail.com>
Co-authored-by: Palash Gupta <palashgdev@gmail.com>
This commit is contained in:
dnazarenkoo 2023-07-18 10:12:05 +03:00 committed by GitHub
parent b5af238374
commit b3a6deb71b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -326,6 +326,13 @@ function GridGraph(props: Props): JSX.Element {
errorMessage,
]);
useEffect(
() => (): void => {
toggleAddWidget(false);
},
[toggleAddWidget],
);
return (
<GraphLayoutContainer
addPanelLoading={addPanelLoading}