fix(frontend): handle visual editor default flow navigation

This commit is contained in:
yassinedorbozgithub 2024-12-18 15:14:18 +01:00
parent 84f25ecfb1
commit a93f3fcc86

View File

@ -189,7 +189,8 @@ const Diagrams = () => {
}, []);
useEffect(() => {
setSelectedCategoryId(flowId || "");
if (flowId) setSelectedCategoryId(flowId);
else if (categories?.length) setSelectedCategoryId(categories[0].id);
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [flowId]);