fix(workflow): gate “publish as tool” on published user input node validity

This commit is contained in:
lyzno1
2025-10-15 20:26:12 +08:00
parent 34b7e5cbca
commit 2ccb20bf3a
8 changed files with 61 additions and 8 deletions

View File

@ -14,6 +14,8 @@ export type ToolSliceShape = {
setMcpTools: (tools: ToolWithProvider[]) => void
toolPublished: boolean
setToolPublished: (toolPublished: boolean) => void
lastPublishedHasUserInput: boolean
setLastPublishedHasUserInput: (hasUserInput: boolean) => void
}
export const createToolSlice: StateCreator<ToolSliceShape> = set => ({
@ -27,4 +29,6 @@ export const createToolSlice: StateCreator<ToolSliceShape> = set => ({
setMcpTools: mcpTools => set(() => ({ mcpTools })),
toolPublished: false,
setToolPublished: toolPublished => set(() => ({ toolPublished })),
lastPublishedHasUserInput: false,
setLastPublishedHasUserInput: hasUserInput => set(() => ({ lastPublishedHasUserInput: hasUserInput })),
})