diff --git a/src/frontend/src/pages/FlowPage/components/nodeToolbarComponent/index.tsx b/src/frontend/src/pages/FlowPage/components/nodeToolbarComponent/index.tsx index 953b5d54f..e1e3bd5c4 100644 --- a/src/frontend/src/pages/FlowPage/components/nodeToolbarComponent/index.tsx +++ b/src/frontend/src/pages/FlowPage/components/nodeToolbarComponent/index.tsx @@ -46,7 +46,7 @@ export default function NodeToolbarComponent({ if (countHandles > 1) return false; return true; } - + const isMinimal = canMinimize(); const { paste } = useContext(TabsContext); const reactFlowInstance = useReactFlow(); const [showModalAdvanced, setShowModalAdvanced] = useState(false); @@ -131,49 +131,67 @@ export default function NodeToolbarComponent({ - - - - - - + {isMinimal ? ( + + + + + + + - - - - - - - {" "} - Edit{" "} - {" "} - - {canMinimize() && ( - + + + + - {showNode ? "Minimize" : "Expand"} - + />{" "} + Edit{" "} + {" "} - )} - - + {isMinimal && ( + + + + {showNode ? "Minimize" : "Expand"} + + + )} + + + ) : ( + + + setShowModalAdvanced(true)} + className={classNames( + "relative -ml-px inline-flex items-center rounded-r-md bg-background px-2 py-2 text-foreground shadow-md ring-1 ring-inset ring-ring transition-all duration-500 ease-in-out hover:bg-muted focus:z-10" + + (nodeLength == 0 + ? " text-muted-foreground" + : " text-foreground") + )} + > + + + + + )} {showModalAdvanced && (