[fix] Sync subgraph node title changes with breadcrumb navigation (#4394)

This commit is contained in:
Christian Byrne
2025-07-12 14:37:48 -07:00
committed by GitHub
parent 01c735d943
commit a70d69cbd2
3 changed files with 807 additions and 1 deletions

View File

@@ -41,7 +41,15 @@ const previousCanvasDraggable = ref(true)
const onEdit = (newValue: string) => {
if (titleEditorStore.titleEditorTarget && newValue.trim() !== '') {
titleEditorStore.titleEditorTarget.title = newValue.trim()
const trimmedTitle = newValue.trim()
titleEditorStore.titleEditorTarget.title = trimmedTitle
// If this is a subgraph node, sync the runtime subgraph name for breadcrumb reactivity
const target = titleEditorStore.titleEditorTarget
if (target instanceof LGraphNode && target.isSubgraphNode?.()) {
target.subgraph.name = trimmedTitle
}
app.graph.setDirtyCanvas(true, true)
}
showInput.value = false