From 2d75e4d4107f4a1e94d0b0080b1b8e9c19da6181 Mon Sep 17 00:00:00 2001 From: karishmas6 Date: Tue, 8 Oct 2024 18:53:17 +0530 Subject: [PATCH] feat: set visibility of actions --- src/components/organisms/RightSidePanel.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/components/organisms/RightSidePanel.tsx b/src/components/organisms/RightSidePanel.tsx index 0dfcf3bb..6bbadc5f 100644 --- a/src/components/organisms/RightSidePanel.tsx +++ b/src/components/organisms/RightSidePanel.tsx @@ -95,6 +95,10 @@ export const RightSidePanel: React.FC = ({ onFinishCapture const hasScrapeSchemaAction = workflow.workflow.some(pair => pair.what.some(action => action.action === "scrapeSchema") ); + + setShowCaptureList(!(hasScrapeListAction || hasScrapeSchemaAction || hasScreenshotAction)); + setShowCaptureScreenshot(!(hasScrapeListAction || hasScrapeSchemaAction || hasScreenshotAction)); + setShowCaptureText(!(hasScrapeListAction || hasScreenshotAction)); }, [workflow]); const handleTextLabelChange = (id: number, label: string, listId?: number, fieldKey?: string) => {