workflow-view-middleware-service
[arvados-workbench2.git] / src / views-components / main-content-bar / main-content-bar.tsx
index 41442bba0d395e0f02f43d4ae6b3adb3bab00cbb..6fb419e36710aa187e0f28a79b46fba82ed5f0d7 100644 (file)
@@ -16,14 +16,14 @@ interface MainContentBarProps {
     buttonVisible: boolean;
 }
 
-const isButtonVisible = ({ router }: RootState) => {
+const isWorkflowPath = ({ router }: RootState) => {
     const pathname = router.location ? router.location.pathname : '';
-    const match = !matchWorkflowRoute(pathname);
+    const match = matchWorkflowRoute(pathname);
     return !!match;
 };
 
 export const MainContentBar = connect((state: RootState) => ({
-    buttonVisible: isButtonVisible(state)
+    buttonVisible: !isWorkflowPath(state)
 }), {
         onDetailsPanelToggle: detailsPanelActions.TOGGLE_DETAILS_PANEL
     })((props: MainContentBarProps) =>