You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kie.apache.org by "ljmotta (via GitHub)" <gi...@apache.org> on 2026/09/02 09:44:14 UTC
Re: [PR] kie-issues#1495: Upgrade ReactFlow from v11 to v12 on kie-tools [incubator-kie-tools]
ljmotta commented on code in PR #3720:
URL: https://github.com/apache/incubator-kie-tools/pull/3720#discussion_r3912792112
##########
packages/xyflow-react-kie-diagram/src/diagram/XyFlowReactKieDiagram.tsx:
##########
@@ -527,8 +562,11 @@ export function XyFlowReactKieDiagram<
state.xyFlowReactKieDiagram.newNodeProjection!;
let foundContainer = false;
- for (const potentialContainer of reactFlowInstance?.getNodes().reverse() ??
- [] /* Respect the nodes z-index */) {
+ // Use xyFlowStoreApi for synchronous access; nodeLookup stores InternalNode<Node> so we cast
+ // through unknown to Node<NData, N> (safe since NData satisfies Record<string, unknown>).
+ for (const potentialContainer of (
+ Array.from(xyFlowStoreApi.getState().nodeLookup.values()) as unknown as RF.Node<NData, N>[]
Review Comment:
@Kusuma04-dev It is still being cast to `unkown`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org