diff --git a/web/app/components/workflow-app/components/workflow-header/features-trigger.tsx b/web/app/components/workflow-app/components/workflow-header/features-trigger.tsx index 47ec60d7ad..d229006177 100644 --- a/web/app/components/workflow-app/components/workflow-header/features-trigger.tsx +++ b/web/app/components/workflow-app/components/workflow-header/features-trigger.tsx @@ -56,6 +56,7 @@ const FeaturesTrigger = () => { const lastPublishedHasUserInput = useStore(s => s.lastPublishedHasUserInput) const nodes = useNodes() + const hasWorkflowNodes = nodes.length > 0 const startNode = nodes.find(node => node.data.type === BlockEnum.Start) const startVariables = (startNode as Node)?.data?.variables const edges = useEdges() @@ -185,7 +186,7 @@ const FeaturesTrigger = () => { {...{ publishedAt, draftUpdatedAt, - disabled: nodesReadOnly, + disabled: nodesReadOnly || !hasWorkflowNodes, toolPublished, inputs: variables, onRefreshData: handleToolConfigureUpdate, @@ -195,6 +196,7 @@ const FeaturesTrigger = () => { crossAxisOffset: 4, missingStartNode: !startNode, hasTriggerNode, + publishDisabled: !hasWorkflowNodes, }} />