Skip to content

Commit 016301a

Browse files
committed
fix: missing invisible nodes when switch subgraph
1 parent 7670771 commit 016301a

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

packages/core/src/LGraphCanvas_Rendering.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,8 @@ export default class LGraphCanvas_Rendering {
204204
ctx.restore();
205205
}
206206

207-
const invisible_nodes = this.graph._nodes.filter(
207+
const all_nodes = this._graph_stack.flatMap((x) => x.graph._nodes);
208+
const invisible_nodes = all_nodes.filter(
208209
(n) => !visible_nodes.includes(n),
209210
);
210211

@@ -2722,9 +2723,7 @@ export default class LGraphCanvas_Rendering {
27222723
}
27232724
break;
27242725
default:
2725-
if (w.draw) {
2726-
w.draw(ctx, node, widget_width, y, H);
2727-
}
2726+
w.draw?.(ctx, node, widget_width, y, H);
27282727
break;
27292728
}
27302729
posY += (w.computeSize ? w.computeSize(widget_width)[1] : H) + 4;

0 commit comments

Comments
 (0)