@valerypopoff/rivet2-core 2.31.0 → 2.32.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5667,6 +5667,7 @@ function toSerializedNode(node, allNodes, allConnections) {
5667
5667
  return {
5668
5668
  description: ((_a = node.description) == null ? void 0 : _a.trim()) ? node.description : void 0,
5669
5669
  visualData: packVisualDataV4(node),
5670
+ dataBusChannelOrder: node.visualData.dataBusChannelOrder,
5670
5671
  isSplitRun: node.isSplitRun ? true : void 0,
5671
5672
  splitRunMax: node.isSplitRun ? node.splitRunMax : void 0,
5672
5673
  splitRunConcurrency: node.isSplitRun ? node.splitRunConcurrency : void 0,
@@ -5702,7 +5703,8 @@ function fromSerializedNode2(serializedNode, serializedNodeInfo) {
5702
5703
  y,
5703
5704
  width,
5704
5705
  zIndex,
5705
- color
5706
+ color,
5707
+ ...Array.isArray(serializedNode.dataBusChannelOrder) ? { dataBusChannelOrder: serializedNode.dataBusChannelOrder } : {}
5706
5708
  },
5707
5709
  data: serializedNode.data ?? {},
5708
5710
  variants: serializedNode.variants ?? [],
@@ -7566,16 +7568,20 @@ function resolveNodePrefabInstance(project, node) {
7566
7568
  title: `Missing library node (${prefabId})`
7567
7569
  };
7568
7570
  }
7571
+ const visualData = {
7572
+ ...structuredClone(sourceNode.visualData),
7573
+ x: node.visualData.x,
7574
+ y: node.visualData.y,
7575
+ width: node.visualData.width ?? sourceNode.visualData.width,
7576
+ zIndex: node.visualData.zIndex
7577
+ };
7578
+ if (Array.isArray(node.visualData.dataBusChannelOrder))
7579
+ visualData.dataBusChannelOrder = [...node.visualData.dataBusChannelOrder];
7580
+ else delete visualData.dataBusChannelOrder;
7569
7581
  return {
7570
7582
  ...structuredClone(sourceNode),
7571
7583
  id: node.id,
7572
- visualData: {
7573
- ...structuredClone(sourceNode.visualData),
7574
- x: node.visualData.x,
7575
- y: node.visualData.y,
7576
- width: node.visualData.width ?? sourceNode.visualData.width,
7577
- zIndex: node.visualData.zIndex
7578
- }
7584
+ visualData
7579
7585
  };
7580
7586
  }
7581
7587
  function detachNodePrefabInstance(project, node) {