@sapui5/sap.suite.ui.commons 1.144.0 → 1.145.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.
Files changed (114) hide show
  1. package/package.json +1 -1
  2. package/src/sap/suite/ui/commons/.library +1 -1
  3. package/src/sap/suite/ui/commons/AriaProperties.js +1 -1
  4. package/src/sap/suite/ui/commons/CalculationBuilder.js +8 -4
  5. package/src/sap/suite/ui/commons/CalculationBuilderExpression.js +1 -1
  6. package/src/sap/suite/ui/commons/CalculationBuilderFunction.js +1 -1
  7. package/src/sap/suite/ui/commons/CalculationBuilderGroup.js +1 -1
  8. package/src/sap/suite/ui/commons/CalculationBuilderItem.js +1 -1
  9. package/src/sap/suite/ui/commons/CalculationBuilderValidationResult.js +1 -1
  10. package/src/sap/suite/ui/commons/CalculationBuilderVariable.js +1 -1
  11. package/src/sap/suite/ui/commons/CloudFilePicker.js +1 -3
  12. package/src/sap/suite/ui/commons/MicroProcessFlow.js +1 -1
  13. package/src/sap/suite/ui/commons/MicroProcessFlowItem.js +1 -1
  14. package/src/sap/suite/ui/commons/Timeline.js +9 -0
  15. package/src/sap/suite/ui/commons/TimelineNavigator.js +37 -5
  16. package/src/sap/suite/ui/commons/TimelineRenderer.js +3 -3
  17. package/src/sap/suite/ui/commons/collaboration/BaseHelperService.js +0 -1
  18. package/src/sap/suite/ui/commons/collaboration/CollaborationHelper.js +0 -3
  19. package/src/sap/suite/ui/commons/collaboration/CollaborationManagerService.js +0 -1
  20. package/src/sap/suite/ui/commons/collaboration/ContactHelper.js +7 -0
  21. package/src/sap/suite/ui/commons/collaboration/ContactPopover.fragment.xml +4 -1
  22. package/src/sap/suite/ui/commons/collaboration/MinimalContactPopover.fragment.xml +2 -1
  23. package/src/sap/suite/ui/commons/collaboration/TeamsHelperService.js +0 -6
  24. package/src/sap/suite/ui/commons/collaboration/channels/MessageChannel.js +0 -2
  25. package/src/sap/suite/ui/commons/collaboration/flpplugins/msplugin/Component-preload.js +1 -1
  26. package/src/sap/suite/ui/commons/collaboration/flpplugins/msplugin/Component.js +1 -2
  27. package/src/sap/suite/ui/commons/flexibility/changeHandler/PropertyChangeMapper.js +1 -1
  28. package/src/sap/suite/ui/commons/imageeditor/CropCustomShapeHistoryItem.js +1 -1
  29. package/src/sap/suite/ui/commons/imageeditor/CropEllipseHistoryItem.js +1 -1
  30. package/src/sap/suite/ui/commons/imageeditor/CropRectangleHistoryItem.js +1 -1
  31. package/src/sap/suite/ui/commons/imageeditor/CustomSizeItem.js +1 -1
  32. package/src/sap/suite/ui/commons/imageeditor/FilterHistoryItem.js +1 -1
  33. package/src/sap/suite/ui/commons/imageeditor/FlipHistoryItem.js +1 -1
  34. package/src/sap/suite/ui/commons/imageeditor/HistoryItem.js +1 -1
  35. package/src/sap/suite/ui/commons/imageeditor/ImageEditor.js +1 -1
  36. package/src/sap/suite/ui/commons/imageeditor/ImageEditorContainer.js +1 -1
  37. package/src/sap/suite/ui/commons/imageeditor/ImageEditorResponsiveContainer.js +1 -1
  38. package/src/sap/suite/ui/commons/imageeditor/ResizeHistoryItem.js +1 -1
  39. package/src/sap/suite/ui/commons/imageeditor/RotateHistoryItem.js +1 -1
  40. package/src/sap/suite/ui/commons/library.js +25 -1
  41. package/src/sap/suite/ui/commons/messagebundle.properties +16 -9
  42. package/src/sap/suite/ui/commons/messagebundle_ar.properties +17 -2
  43. package/src/sap/suite/ui/commons/messagebundle_bg.properties +18 -3
  44. package/src/sap/suite/ui/commons/messagebundle_ca.properties +18 -3
  45. package/src/sap/suite/ui/commons/messagebundle_cnr.properties +18 -3
  46. package/src/sap/suite/ui/commons/messagebundle_cs.properties +17 -2
  47. package/src/sap/suite/ui/commons/messagebundle_cy.properties +17 -2
  48. package/src/sap/suite/ui/commons/messagebundle_da.properties +17 -2
  49. package/src/sap/suite/ui/commons/messagebundle_de.properties +30 -15
  50. package/src/sap/suite/ui/commons/messagebundle_el.properties +18 -3
  51. package/src/sap/suite/ui/commons/messagebundle_en.properties +18 -3
  52. package/src/sap/suite/ui/commons/messagebundle_en_GB.properties +18 -3
  53. package/src/sap/suite/ui/commons/messagebundle_en_US_saprigi.properties +2 -0
  54. package/src/sap/suite/ui/commons/messagebundle_es.properties +18 -3
  55. package/src/sap/suite/ui/commons/messagebundle_es_MX.properties +18 -3
  56. package/src/sap/suite/ui/commons/messagebundle_et.properties +17 -2
  57. package/src/sap/suite/ui/commons/messagebundle_fi.properties +17 -2
  58. package/src/sap/suite/ui/commons/messagebundle_fr.properties +26 -11
  59. package/src/sap/suite/ui/commons/messagebundle_fr_CA.properties +17 -2
  60. package/src/sap/suite/ui/commons/messagebundle_hi.properties +18 -3
  61. package/src/sap/suite/ui/commons/messagebundle_hr.properties +18 -3
  62. package/src/sap/suite/ui/commons/messagebundle_hu.properties +17 -2
  63. package/src/sap/suite/ui/commons/messagebundle_id.properties +18 -3
  64. package/src/sap/suite/ui/commons/messagebundle_it.properties +17 -2
  65. package/src/sap/suite/ui/commons/messagebundle_iw.properties +17 -2
  66. package/src/sap/suite/ui/commons/messagebundle_ja.properties +18 -3
  67. package/src/sap/suite/ui/commons/messagebundle_kk.properties +17 -2
  68. package/src/sap/suite/ui/commons/messagebundle_ko.properties +17 -2
  69. package/src/sap/suite/ui/commons/messagebundle_lt.properties +17 -2
  70. package/src/sap/suite/ui/commons/messagebundle_lv.properties +18 -3
  71. package/src/sap/suite/ui/commons/messagebundle_mk.properties +17 -2
  72. package/src/sap/suite/ui/commons/messagebundle_ms.properties +17 -2
  73. package/src/sap/suite/ui/commons/messagebundle_nl.properties +17 -2
  74. package/src/sap/suite/ui/commons/messagebundle_no.properties +18 -3
  75. package/src/sap/suite/ui/commons/messagebundle_pl.properties +17 -2
  76. package/src/sap/suite/ui/commons/messagebundle_pt.properties +17 -2
  77. package/src/sap/suite/ui/commons/messagebundle_pt_PT.properties +17 -2
  78. package/src/sap/suite/ui/commons/messagebundle_ro.properties +17 -2
  79. package/src/sap/suite/ui/commons/messagebundle_ru.properties +17 -2
  80. package/src/sap/suite/ui/commons/messagebundle_sh.properties +18 -3
  81. package/src/sap/suite/ui/commons/messagebundle_sk.properties +17 -2
  82. package/src/sap/suite/ui/commons/messagebundle_sl.properties +17 -2
  83. package/src/sap/suite/ui/commons/messagebundle_sr.properties +18 -3
  84. package/src/sap/suite/ui/commons/messagebundle_sv.properties +17 -2
  85. package/src/sap/suite/ui/commons/messagebundle_th.properties +18 -3
  86. package/src/sap/suite/ui/commons/messagebundle_tr.properties +17 -2
  87. package/src/sap/suite/ui/commons/messagebundle_uk.properties +17 -2
  88. package/src/sap/suite/ui/commons/messagebundle_vi.properties +19 -4
  89. package/src/sap/suite/ui/commons/messagebundle_zh_CN.properties +17 -2
  90. package/src/sap/suite/ui/commons/messagebundle_zh_TW.properties +19 -4
  91. package/src/sap/suite/ui/commons/networkgraph/Graph.js +45 -16
  92. package/src/sap/suite/ui/commons/networkgraph/KeyboardNavigator.js +45 -4
  93. package/src/sap/suite/ui/commons/networkgraph/Line.js +52 -0
  94. package/src/sap/suite/ui/commons/networkgraph/Node.js +289 -86
  95. package/src/sap/suite/ui/commons/networkgraph/util/DependencyLayoutHelper.js +143 -70
  96. package/src/sap/suite/ui/commons/networkgraph/util/PortManager.js +2 -3
  97. package/src/sap/suite/ui/commons/statusindicator/Circle.js +1 -1
  98. package/src/sap/suite/ui/commons/statusindicator/CustomShape.js +1 -1
  99. package/src/sap/suite/ui/commons/statusindicator/DiscreteThreshold.js +1 -1
  100. package/src/sap/suite/ui/commons/statusindicator/FillingOption.js +1 -1
  101. package/src/sap/suite/ui/commons/statusindicator/LibraryShape.js +1 -1
  102. package/src/sap/suite/ui/commons/statusindicator/Path.js +1 -1
  103. package/src/sap/suite/ui/commons/statusindicator/PropertyThreshold.js +1 -1
  104. package/src/sap/suite/ui/commons/statusindicator/Rectangle.js +1 -1
  105. package/src/sap/suite/ui/commons/statusindicator/Shape.js +1 -1
  106. package/src/sap/suite/ui/commons/statusindicator/ShapeGroup.js +1 -1
  107. package/src/sap/suite/ui/commons/statusindicator/SimpleShape.js +1 -1
  108. package/src/sap/suite/ui/commons/statusindicator/StatusIndicator.js +1 -1
  109. package/src/sap/suite/ui/commons/taccount/TAccount.js +1 -1
  110. package/src/sap/suite/ui/commons/taccount/TAccountGroup.js +1 -1
  111. package/src/sap/suite/ui/commons/taccount/TAccountItem.js +1 -1
  112. package/src/sap/suite/ui/commons/taccount/TAccountItemProperty.js +1 -1
  113. package/src/sap/suite/ui/commons/taccount/TAccountPanel.js +1 -1
  114. package/src/sap/suite/ui/commons/themes/base/NetworkLine.less +26 -5
@@ -7,7 +7,8 @@
7
7
  sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (library, Log) {
8
8
  "use strict";
9
9
 
10
- const ConnectionType = library.networkgraph.ConnectionType;
10
+ const ConnectionType = library.networkgraph.ConnectionType,
11
+ ComponentArrangement = library.networkgraph.ComponentArrangement;
11
12
  const DEFAULT_HORIZONTAL_SPACING = 240;
12
13
  const DEFAULT_VERTICAL_SPACING = 100;
13
14
 
@@ -21,6 +22,12 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
21
22
  * @since 1.144
22
23
  */
23
24
  const DependencyLayoutHelper = {
25
+ /**
26
+ * WeakMap to store last calculated positions and origin flag for automatic drag detection.
27
+ * Structure: {x: number, y: number, bIsUserPositioned: boolean}
28
+ */
29
+ _lastCalculated: new WeakMap(),
30
+
24
31
  /**
25
32
  * Calculates and sets positions for nodes without coordinates based on their dependency relationships.
26
33
  * Uses topological sorting (Kahn's algorithm) and DFS-based cycle detection to arrange nodes
@@ -30,6 +37,7 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
30
37
  * @param {object} [mConfig] - Configuration object
31
38
  * @param {number} [mConfig.horizontalSpacing=240] - Horizontal spacing between layers
32
39
  * @param {number} [mConfig.verticalSpacing=100] - Vertical spacing between nodes
40
+ * @param {sap.suite.ui.commons.networkgraph.ComponentArrangement} [mConfig.componentArrangement=Horizontal] - Component arrangement: "Horizontal" or "Vertical"
33
41
  * @public
34
42
  */
35
43
  calculatePositions: function (oGraph, mConfig) {
@@ -41,17 +49,19 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
41
49
  {
42
50
  horizontalSpacing: DEFAULT_HORIZONTAL_SPACING,
43
51
  verticalSpacing: DEFAULT_VERTICAL_SPACING,
52
+ componentArrangement: ComponentArrangement.Horizontal,
44
53
  },
45
54
  mConfig || {}
46
55
  );
47
-
48
56
  try {
57
+ this._detectUserChanges(oGraph);
49
58
  this._buildDependencyGraph(oGraph);
50
59
  const aComponents = this._identifyComponents(oGraph);
51
- this._processComponents(aComponents);
60
+ this._processComponents(aComponents, config);
52
61
  this._calculateCoordinates(oGraph, config);
53
62
  this._adjustHorizontalSpacingForNodeWidths(oGraph, config);
54
63
  this._adjustVerticalSpacingForNodeHeights(oGraph, config);
64
+ this._storeFinalPositions(oGraph);
55
65
  } catch (e) {
56
66
  Log.error("DependencyLayoutHelper error: " + e.message, e);
57
67
  throw new Error("DependencyLayoutHelper error: " + e.message);
@@ -64,8 +74,8 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
64
74
  },
65
75
 
66
76
  /**
67
- * Builds the internal dependency graph structure for layout calculation.
68
- * Initializes layout data for each node and categorizes connections by type.
77
+ * Builds the dependency graph structure by analyzing node relationships.
78
+ * Initializes layout data for each node and categorizes connections.
69
79
  *
70
80
  * @param {sap.suite.ui.commons.networkgraph.Graph} oGraph - The network graph instance
71
81
  * @private
@@ -79,9 +89,9 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
79
89
  mNodeMap.set(oNode.getKey(), oNode);
80
90
  const fX = oNode.getX();
81
91
  const fY = oNode.getY();
82
- // Constraint: Nodes with coordinates (0,0) are treated as unpositioned and will be
83
- // auto-positioned based on dependency relationships. For origin positioning, use (0.1, 0.1) or (1, 1).
84
- const bHasCoordinates = fX !== undefined && fY !== undefined && (fX !== 0 || fY !== 0);
92
+ const oLastPos = this._lastCalculated.get(oNode);
93
+ // Only preserve coordinates if they were original or user-dragged
94
+ const bShouldPreserve = oLastPos?.bIsUserPositioned;
85
95
 
86
96
  oNode._layoutData = {
87
97
  layer: -1,
@@ -91,9 +101,10 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
91
101
  parallelNodes: [],
92
102
  backwardEdges: [],
93
103
  backwardEdgeLines: [],
94
- hasCoordinates: bHasCoordinates,
104
+ isBackwardSource: false,
105
+ bShouldPreserve,
95
106
  userX: fX,
96
- userY: fY,
107
+ userY: fY
97
108
  };
98
109
  });
99
110
 
@@ -164,12 +175,9 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
164
175
  oNode._layoutData.isBackwardSource = true;
165
176
  oNode._layoutData.backwardEdges.push(oTargetNode);
166
177
 
167
- const oFromMap = this._lineMap.get(sKey);
168
- if (oFromMap) {
169
- const oLine = oFromMap.get(sTargetKey);
170
- if (oLine) {
171
- oNode._layoutData.backwardEdgeLines.push(oLine);
172
- }
178
+ const oLine = this._lineMap.get(sKey)?.get(sTargetKey);
179
+ if (oLine) {
180
+ oNode._layoutData.backwardEdgeLines.push(oLine);
173
181
  }
174
182
 
175
183
  const idx = oTargetNode._layoutData.incoming.indexOf(oNode);
@@ -251,9 +259,10 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
251
259
  * Processes all components: separates isolated nodes and arranges connected components.
252
260
  *
253
261
  * @param {Array<sap.suite.ui.commons.networkgraph.Node[]>} aComponents - Array of components (groups of connected nodes)
262
+ * @param {object} config - Configuration object
254
263
  * @private
255
264
  */
256
- _processComponents: function (aComponents) {
265
+ _processComponents: function (aComponents, { componentArrangement }) {
257
266
  const aIsolatedNodes = [];
258
267
  const aConnectedComponents = [];
259
268
 
@@ -261,7 +270,8 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
261
270
  const bIsIsolated =
262
271
  aComponentNodes.length === 1 &&
263
272
  aComponentNodes[0]._layoutData.incoming.length === 0 &&
264
- aComponentNodes[0]._layoutData.outgoing.length === 0;
273
+ aComponentNodes[0]._layoutData.outgoing.length === 0 &&
274
+ !aComponentNodes[0]._layoutData.bShouldPreserve;
265
275
 
266
276
  if (bIsIsolated) {
267
277
  aIsolatedNodes.push(aComponentNodes[0]);
@@ -269,7 +279,7 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
269
279
  aConnectedComponents.push(aComponentNodes);
270
280
  }
271
281
  });
272
-
282
+ const bSideBySide = componentArrangement !== ComponentArrangement.Vertical;
273
283
  let iMaxVerticalPosition = 0;
274
284
  let iMaxLayerAcrossAll = 0;
275
285
 
@@ -278,35 +288,56 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
278
288
  this._adjustParallelLayersForComponent(aComponentNodes);
279
289
  this._assignVerticalPositionsForComponent(aComponentNodes);
280
290
 
281
- aComponentNodes.forEach((oNode) => {
282
- oNode._layoutData.position += iMaxVerticalPosition;
283
- oNode._layoutData.componentOffset = 0;
284
- });
291
+ if (bSideBySide) {
292
+ aComponentNodes.forEach((oNode) => {
293
+ oNode._layoutData.layer += iMaxLayerAcrossAll;
294
+ oNode._layoutData.componentOffset = 0;
295
+ });
285
296
 
286
- let iComponentMaxPosition = -1;
287
- aComponentNodes.forEach((n) => {
288
- if (n._layoutData.position > iComponentMaxPosition) {
289
- iComponentMaxPosition = n._layoutData.position;
290
- }
291
- });
292
- iMaxVerticalPosition = iComponentMaxPosition + 1;
297
+ let iComponentMaxLayer = -1;
298
+ aComponentNodes.forEach((n) => {
299
+ if (n._layoutData.layer > iComponentMaxLayer) {
300
+ iComponentMaxLayer = n._layoutData.layer;
301
+ }
302
+ });
303
+ iMaxLayerAcrossAll = iComponentMaxLayer + 1;
304
+ } else {
305
+ aComponentNodes.forEach((oNode) => {
306
+ oNode._layoutData.position += iMaxVerticalPosition;
307
+ oNode._layoutData.componentOffset = 0;
308
+ });
293
309
 
294
- let iComponentMaxLayer = -1;
295
- aComponentNodes.forEach((n) => {
296
- if (n._layoutData.layer > iComponentMaxLayer) {
297
- iComponentMaxLayer = n._layoutData.layer;
298
- }
299
- });
300
- iMaxLayerAcrossAll = Math.max(iMaxLayerAcrossAll, iComponentMaxLayer);
310
+ let iComponentMaxPosition = -1;
311
+ aComponentNodes.forEach((n) => {
312
+ if (n._layoutData.position > iComponentMaxPosition) {
313
+ iComponentMaxPosition = n._layoutData.position;
314
+ }
315
+ });
316
+ iMaxVerticalPosition = iComponentMaxPosition + 1;
317
+
318
+ let iComponentMaxLayer = -1;
319
+ aComponentNodes.forEach((n) => {
320
+ if (n._layoutData.layer > iComponentMaxLayer) {
321
+ iComponentMaxLayer = n._layoutData.layer;
322
+ }
323
+ });
324
+ iMaxLayerAcrossAll = Math.max(iMaxLayerAcrossAll, iComponentMaxLayer);
325
+ }
301
326
  });
302
327
 
303
328
  if (aIsolatedNodes.length > 0) {
304
329
  const iRightSideOffset = iMaxLayerAcrossAll + 1;
305
330
 
306
331
  aIsolatedNodes.forEach((oNode, idx) => {
307
- oNode._layoutData.layer = idx % 2;
308
- oNode._layoutData.position = Math.floor(idx / 2);
309
- oNode._layoutData.componentOffset = iRightSideOffset;
332
+ if (bSideBySide) {
333
+ oNode._layoutData.layer = Math.floor(idx / 2);
334
+ oNode._layoutData.position = idx % 2;
335
+ oNode._layoutData.componentOffset = iMaxLayerAcrossAll;
336
+ } else {
337
+ oNode._layoutData.layer = idx % 2;
338
+ oNode._layoutData.position = Math.floor(idx / 2);
339
+ oNode._layoutData.componentOffset = iRightSideOffset;
340
+ }
310
341
  });
311
342
  }
312
343
  },
@@ -657,10 +688,10 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
657
688
  * @param {object} config - Configuration with spacing values
658
689
  * @private
659
690
  */
660
- _calculateCoordinates: function (oGraph, config) {
691
+ _calculateCoordinates: function (oGraph, { horizontalSpacing, verticalSpacing }) {
661
692
  const aNodes = oGraph.getNodes();
662
- const iHSpacing = config.horizontalSpacing;
663
- const iVSpacing = config.verticalSpacing;
693
+ const iHSpacing = horizontalSpacing;
694
+ const iVSpacing = verticalSpacing;
664
695
 
665
696
  aNodes.forEach((oNode) => {
666
697
  const iComponentOffset = oNode._layoutData.componentOffset || 0;
@@ -671,11 +702,10 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
671
702
  });
672
703
 
673
704
  aNodes.forEach((oNode) => {
674
- if (oNode._layoutData.hasCoordinates) {
675
- const fUserX = oNode._layoutData.userX;
676
- const fUserY = oNode._layoutData.userY;
677
- oNode.setX(fUserX);
678
- oNode.setY(fUserY);
705
+ if (oNode._layoutData.bShouldPreserve) {
706
+ const { userX, userY } = oNode._layoutData;
707
+ oNode.setX(userX);
708
+ oNode.setY(userY);
679
709
  }
680
710
  });
681
711
  },
@@ -684,18 +714,15 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
684
714
  * Adjusts horizontal spacing to accommodate nodes with varying widths.
685
715
  *
686
716
  * @param {sap.suite.ui.commons.networkgraph.Graph} oGraph - The network graph instance
687
- * @param {object} config - Configuration with spacing values
688
717
  * @private
689
718
  */
690
- _adjustHorizontalSpacingForNodeWidths: function (oGraph, config) {
719
+ _adjustHorizontalSpacingForNodeWidths: function (oGraph) {
691
720
  const aNodes = oGraph.getNodes();
692
- const iDefaultSpacing = config.horizontalSpacing;
693
- const iHGap = iDefaultSpacing;
694
721
  const mLayerWidths = {};
695
722
  let iMaxLayer = -1;
696
723
 
697
724
  aNodes.forEach((oNode) => {
698
- if (!oNode._layoutData.hasCoordinates) {
725
+ if (!oNode._layoutData.bShouldPreserve) {
699
726
  const iLayer =
700
727
  oNode._layoutData.layer + (oNode._layoutData.componentOffset || 0);
701
728
  iMaxLayer = Math.max(iMaxLayer, iLayer);
@@ -716,16 +743,12 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
716
743
  mLayerOffsets[iLayer] = iCumulativeOffset;
717
744
  const iActualWidth = mLayerWidths[iLayer];
718
745
  if (iActualWidth) {
719
- if (iActualWidth > iDefaultSpacing) {
720
- iCumulativeOffset += iActualWidth - iDefaultSpacing + iHGap;
721
- } else {
722
- iCumulativeOffset += iActualWidth;
723
- }
746
+ iCumulativeOffset += iActualWidth;
724
747
  }
725
748
  }
726
749
 
727
750
  aNodes.forEach((oNode) => {
728
- if (!oNode._layoutData.hasCoordinates) {
751
+ if (!oNode._layoutData.bShouldPreserve) {
729
752
  const iLayer =
730
753
  oNode._layoutData.layer + (oNode._layoutData.componentOffset || 0);
731
754
  const iOffset = mLayerOffsets[iLayer] || 0;
@@ -738,18 +761,15 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
738
761
  * Adjusts vertical spacing to accommodate nodes with varying heights.
739
762
  *
740
763
  * @param {sap.suite.ui.commons.networkgraph.Graph} oGraph - The network graph instance
741
- * @param {object} config - Configuration with spacing values
742
764
  * @private
743
765
  */
744
- _adjustVerticalSpacingForNodeHeights: function (oGraph, config) {
766
+ _adjustVerticalSpacingForNodeHeights: function (oGraph) {
745
767
  const aNodes = oGraph.getNodes();
746
- const iDefaultSpacing = config.verticalSpacing;
747
- const iVGap = iDefaultSpacing;
748
768
  const mPositionHeights = {};
749
769
  const mAllPositions = {};
750
770
 
751
771
  aNodes.forEach((oNode) => {
752
- if (!oNode._layoutData.hasCoordinates) {
772
+ if (!oNode._layoutData.bShouldPreserve) {
753
773
  const iPosition = oNode._layoutData.position;
754
774
  mAllPositions[iPosition] = true;
755
775
 
@@ -775,22 +795,75 @@ sap.ui.define(["sap/suite/ui/commons/library", "sap/base/Log"], function (librar
775
795
  mPositionOffsets[iPosition] = iCumulativeOffset;
776
796
  const iActualHeight = mPositionHeights[iPosition];
777
797
  if (iActualHeight) {
778
- if (iActualHeight > iDefaultSpacing) {
779
- iCumulativeOffset += iActualHeight - iDefaultSpacing + iVGap;
780
- } else {
781
- iCumulativeOffset += iActualHeight;
782
- }
798
+ iCumulativeOffset += iActualHeight;
783
799
  }
784
800
  });
785
801
 
786
802
  aNodes.forEach((oNode) => {
787
- if (!oNode._layoutData.hasCoordinates) {
803
+ if (!oNode._layoutData.bShouldPreserve) {
788
804
  const iPosition = oNode._layoutData.position;
789
805
  const iOffset = mPositionOffsets[iPosition] || 0;
790
806
  oNode.setY(oNode.getY() + iOffset);
791
807
  }
792
808
  });
793
809
  },
810
+
811
+ /**
812
+ * Stores final calculated positions for automatic drag detection on next call.
813
+ * Only stores positions for nodes that were calculated (not original/dragged).
814
+ *
815
+ * @param {sap.suite.ui.commons.networkgraph.Graph} oGraph - The network graph instance
816
+ * @private
817
+ */
818
+ _storeFinalPositions: function (oGraph) {
819
+ const aNodes = oGraph.getNodes();
820
+
821
+ aNodes.forEach((oNode) => {
822
+ if (!oNode._layoutData.bShouldPreserve) {
823
+ this._lastCalculated.set(oNode, {
824
+ x: oNode.getX(),
825
+ y: oNode.getY(),
826
+ bIsUserPositioned: false
827
+ });
828
+ }
829
+ });
830
+ },
831
+
832
+ /**
833
+ * Detects user-made position changes by comparing current positions with last calculated positions.
834
+ * Marks nodes with original coordinates and tracks drag operations.
835
+ *
836
+ * @param {sap.suite.ui.commons.networkgraph.Graph} oGraph - The network graph instance
837
+ * @private
838
+ */
839
+ _detectUserChanges: function (oGraph) {
840
+ const aNodes = oGraph.getNodes();
841
+
842
+ aNodes.forEach((oNode) => {
843
+ const fX = oNode.getX();
844
+ const fY = oNode.getY();
845
+ // Constraint: Nodes with coordinates (0,0) or negative values are treated as unpositioned.
846
+ // For origin positioning, use (0.1, 0.1) or (1, 1).
847
+ const bHasCoordinates = fX !== undefined && fY !== undefined && (fX !== 0 || fY !== 0);
848
+ const oLastPos = this._lastCalculated.get(oNode);
849
+
850
+ if (!oLastPos && bHasCoordinates) {
851
+ // First time seeing this node with coordinates - mark as original
852
+ this._lastCalculated.set(oNode, {
853
+ x: fX,
854
+ y: fY,
855
+ bIsUserPositioned: true
856
+ });
857
+ } else if (oLastPos) {
858
+ // Check if user dragged it
859
+ if (fX !== oLastPos.x || fY !== oLastPos.y) {
860
+ oLastPos.x = fX;
861
+ oLastPos.y = fY;
862
+ oLastPos.bIsUserPositioned = true;
863
+ }
864
+ }
865
+ });
866
+ },
794
867
  };
795
868
 
796
869
  return DependencyLayoutHelper;
@@ -68,8 +68,7 @@ sap.ui.define([
68
68
  * @param {boolean} bTriggerNode - Whether the node is a trigger node.
69
69
  */
70
70
  addPortsToNode(oNode, bTriggerNode) {
71
- var oGraph = oNode.getParent();
72
- var sNodePorts = oGraph.getNodePorts();
71
+ var sNodePorts = oNode._getNodePorts();
73
72
  // Remove existing ports first
74
73
  this.removePortsFromNode(oNode);
75
74
  if (sNodePorts === "None") {
@@ -200,7 +199,7 @@ sap.ui.define([
200
199
  */
201
200
  addInletPortsToOtherNodes(oNode) {
202
201
  var oGraph = oNode.getParent();
203
- var sNodePorts = oGraph.getNodePorts();
202
+ var sNodePorts = oNode._getNodePorts();
204
203
  // Don't add inlet ports if nodePorts is "None"
205
204
  if (sNodePorts === "None") {
206
205
  return;
@@ -30,7 +30,7 @@ sap.ui.define([
30
30
  * @extends sap.suite.ui.commons.statusindicator.SimpleShape
31
31
  *
32
32
  * @author SAP SE
33
- * @version 1.144.0
33
+ * @version 1.145.0
34
34
  * @since 1.50
35
35
  *
36
36
  * @constructor
@@ -36,7 +36,7 @@ sap.ui.define([
36
36
  * @extends sap.suite.ui.commons.statusindicator.Shape
37
37
  *
38
38
  * @author SAP SE
39
- * @version 1.144.0
39
+ * @version 1.145.0
40
40
  * @since 1.50
41
41
  *
42
42
  * @constructor
@@ -21,7 +21,7 @@ sap.ui.define([
21
21
  * @extends sap.ui.core.Control
22
22
  *
23
23
  * @author SAP SE
24
- * @version 1.144.0
24
+ * @version 1.145.0
25
25
  * @since 1.50
26
26
  *
27
27
  * @constructor
@@ -23,7 +23,7 @@ sap.ui.define([
23
23
  * @extends sap.ui.core.Control
24
24
  *
25
25
  * @author SAP SE
26
- * @version 1.144.0
26
+ * @version 1.145.0
27
27
  * @since 1.50
28
28
  *
29
29
  * @constructor
@@ -23,7 +23,7 @@ sap.ui.define([
23
23
  * @extends sap.suite.ui.commons.statusindicator.CustomShape
24
24
  *
25
25
  * @author SAP SE
26
- * @version 1.144.0
26
+ * @version 1.145.0
27
27
  * @since 1.60.0
28
28
  *
29
29
  * @constructor
@@ -29,7 +29,7 @@ sap.ui.define([
29
29
  * @extends sap.suite.ui.commons.statusindicator.SimpleShape
30
30
  *
31
31
  * @author SAP SE
32
- * @version 1.144.0
32
+ * @version 1.145.0
33
33
  * @since 1.50
34
34
  *
35
35
  * @constructor
@@ -28,7 +28,7 @@ sap.ui.define([
28
28
  * @extends sap.ui.core.Control
29
29
  *
30
30
  * @author SAP SE
31
- * @version 1.144.0
31
+ * @version 1.145.0
32
32
  * @since 1.50
33
33
  *
34
34
  * @constructor
@@ -29,7 +29,7 @@ sap.ui.define(
29
29
  * @extends sap.suite.ui.commons.statusindicator.SimpleShape
30
30
  *
31
31
  * @author SAP SE
32
- * @version 1.144.0
32
+ * @version 1.145.0
33
33
  * @since 1.50
34
34
  *
35
35
  * @constructor
@@ -42,7 +42,7 @@ sap.ui.define([
42
42
  * @extends sap.ui.core.Control
43
43
  *
44
44
  * @author SAP SE
45
- * @version 1.144.0
45
+ * @version 1.145.0
46
46
  * @since 1.50
47
47
  *
48
48
  * @constructor
@@ -30,7 +30,7 @@ sap.ui.define([
30
30
  * @extends sap.ui.core.Control
31
31
  *
32
32
  * @author SAP SE
33
- * @version 1.144.0
33
+ * @version 1.145.0
34
34
  * @since 1.50
35
35
  *
36
36
  * @constructor
@@ -30,7 +30,7 @@ sap.ui.define([
30
30
  * @extends sap.suite.ui.commons.statusindicator.Shape
31
31
  *
32
32
  * @author SAP SE
33
- * @version 1.144.0
33
+ * @version 1.145.0
34
34
  * @since 1.50
35
35
  *
36
36
  * @constructor
@@ -49,7 +49,7 @@ sap.ui.define([
49
49
  * @extends sap.ui.core.Control
50
50
  *
51
51
  * @author SAP SE
52
- * @version 1.144.0
52
+ * @version 1.145.0
53
53
  * @since 1.50
54
54
  *
55
55
  * @constructor
@@ -56,7 +56,7 @@ sap.ui.define([
56
56
  * @extends sap.ui.core.Control
57
57
  *
58
58
  * @author SAP SE
59
- * @version 1.144.0
59
+ * @version 1.145.0
60
60
  * @since 1.58.0
61
61
  *
62
62
  * @constructor
@@ -41,7 +41,7 @@ sap.ui.define([
41
41
  * @extends sap.ui.core.Control
42
42
  *
43
43
  * @author SAP SE
44
- * @version 1.144.0
44
+ * @version 1.145.0
45
45
  * @since 1.58.0
46
46
  *
47
47
  * @constructor
@@ -41,7 +41,7 @@ sap.ui.define([
41
41
  * @extends sap.ui.core.Control
42
42
  *
43
43
  * @author SAP SE
44
- * @version 1.144.0
44
+ * @version 1.145.0
45
45
  * @since 1.58.0
46
46
  *
47
47
  * @constructor
@@ -24,7 +24,7 @@ sap.ui.define([
24
24
  * @extends sap.ui.core.Control
25
25
  *
26
26
  * @author SAP SE
27
- * @version 1.144.0
27
+ * @version 1.145.0
28
28
  * @since 1.58.0
29
29
  *
30
30
  * @constructor
@@ -65,7 +65,7 @@ sap.ui.define([
65
65
  * @extends sap.m.Panel
66
66
  *
67
67
  * @author SAP SE
68
- * @version 1.144.0
68
+ * @version 1.145.0
69
69
  * @since 1.58.0
70
70
  *
71
71
  * @constructor
@@ -14,7 +14,8 @@
14
14
  .sapSuiteUiCommonsNetworkLines .sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLinePath,
15
15
  .sapSuiteUiCommonsNetworkLines .sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineArrow,
16
16
  .sapSuiteUiCommonsNetworkLines .sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineNipple,
17
- .sapSuiteUiCommonsNetworkLines .sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineTextBoxBackground {
17
+ .sapSuiteUiCommonsNetworkLines .sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineTextBoxBackground,
18
+ .sapSuiteUiCommonsNetworkLineTexts .sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineTextBoxBackground {
18
19
  stroke-width: 2;
19
20
  }
20
21
 
@@ -49,7 +50,9 @@
49
50
  .sapSuiteUiCommonsNetworkElementWarning.sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLinePath,
50
51
  .sapSuiteUiCommonsNetworkElementWarning .sapSuiteUiCommonsNetworkLinePath,
51
52
  .sapSuiteUiCommonsNetworkElementWarning.sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineTextBoxBackground,
52
- .sapSuiteUiCommonsNetworkElementWarning .sapSuiteUiCommonsNetworkLineTextBoxBackground {
53
+ .sapSuiteUiCommonsNetworkElementWarning .sapSuiteUiCommonsNetworkLineTextBoxBackground,
54
+ .sapSuiteUiCommonsNetworkLineTexts .sapSuiteUiCommonsNetworkElementWarning.sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineTextBoxBackground,
55
+ .sapSuiteUiCommonsNetworkLineTexts .sapSuiteUiCommonsNetworkElementWarning .sapSuiteUiCommonsNetworkLineTextBoxBackground {
53
56
  stroke: @sapWarningBorderColor;
54
57
  }
55
58
 
@@ -63,7 +66,9 @@
63
66
  .sapSuiteUiCommonsNetworkElementError.sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLinePath,
64
67
  .sapSuiteUiCommonsNetworkElementError .sapSuiteUiCommonsNetworkLinePath,
65
68
  .sapSuiteUiCommonsNetworkElementError.sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineTextBoxBackground,
66
- .sapSuiteUiCommonsNetworkElementError .sapSuiteUiCommonsNetworkLineTextBoxBackground {
69
+ .sapSuiteUiCommonsNetworkElementError .sapSuiteUiCommonsNetworkLineTextBoxBackground,
70
+ .sapSuiteUiCommonsNetworkLineTexts .sapSuiteUiCommonsNetworkElementError.sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineTextBoxBackground,
71
+ .sapSuiteUiCommonsNetworkLineTexts .sapSuiteUiCommonsNetworkElementError .sapSuiteUiCommonsNetworkLineTextBoxBackground {
67
72
  stroke: @sapErrorBorderColor;
68
73
  }
69
74
 
@@ -77,7 +82,9 @@
77
82
  .sapSuiteUiCommonsNetworkElementSuccess.sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLinePath,
78
83
  .sapSuiteUiCommonsNetworkElementSuccess .sapSuiteUiCommonsNetworkLinePath,
79
84
  .sapSuiteUiCommonsNetworkElementSuccess.sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineTextBoxBackground,
80
- .sapSuiteUiCommonsNetworkElementSuccess .sapSuiteUiCommonsNetworkLineTextBoxBackground {
85
+ .sapSuiteUiCommonsNetworkElementSuccess .sapSuiteUiCommonsNetworkLineTextBoxBackground,
86
+ .sapSuiteUiCommonsNetworkLineTexts .sapSuiteUiCommonsNetworkElementSuccess.sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineTextBoxBackground,
87
+ .sapSuiteUiCommonsNetworkLineTexts .sapSuiteUiCommonsNetworkElementSuccess .sapSuiteUiCommonsNetworkLineTextBoxBackground {
81
88
  stroke: @sapSuccessBorderColor;
82
89
  }
83
90
 
@@ -92,7 +99,9 @@
92
99
  .sapSuiteUiCommonsNetworkElementInformation.sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLinePath,
93
100
  .sapSuiteUiCommonsNetworkElementInformation .sapSuiteUiCommonsNetworkLinePath,
94
101
  .sapSuiteUiCommonsNetworkElementInformation.sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineTextBoxBackground,
95
- .sapSuiteUiCommonsNetworkElementInformation .sapSuiteUiCommonsNetworkLineTextBoxBackground {
102
+ .sapSuiteUiCommonsNetworkElementInformation .sapSuiteUiCommonsNetworkLineTextBoxBackground,
103
+ .sapSuiteUiCommonsNetworkLineTexts .sapSuiteUiCommonsNetworkElementInformation.sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineTextBoxBackground,
104
+ .sapSuiteUiCommonsNetworkLineTexts .sapSuiteUiCommonsNetworkElementInformation .sapSuiteUiCommonsNetworkLineTextBoxBackground {
96
105
  stroke: @sapInformationBorderColor;
97
106
  }
98
107
 
@@ -266,3 +275,15 @@
266
275
  pointer-events: all;
267
276
  }
268
277
 
278
+ .sapSuiteUiCommonsNetworkLineTexts .sapSuiteUiCommonsNetworkElementFocus .sapSuiteUiCommonsNetworkLineTextBoxBackground {
279
+ stroke: @sapContent_FocusColor !important;
280
+ stroke-width: 2;
281
+ }
282
+
283
+ .sapSuiteUiCommonsNetworkLineTexts .sapSuiteUiCommonsNetworkElementFocus .sapSuiteUiCommonsNetworkLineText {
284
+ font-weight: bold;
285
+ }
286
+
287
+ .sapSuiteUiCommonsNetworkLineTexts .sapSuiteUiCommonsNetworkElementHighlight .sapSuiteUiCommonsNetworkLineText {
288
+ font-weight: bold;
289
+ }