bpmn-visualization-js
bpmn-visualization-js copied to clipboard
[FEAT] Restore the experimental pools/subprocess live collapsing
Is your feature request related to a problem? Please describe.
After the merge of #1868, there is no more usage of the Segment Connector
. This setting was recomputing the whole edge path. It was able to set the terminal waypoints to the collapsed pools when the edge was targeting a inner element of the pool (hidden when the pool is collapsed).
There is no more waypoints' computation with the new implementation: in this case, we see a dangling edge. The edge
terminal waypoint are inside the pool.
You can find more details in
- https://github.com/process-analytics/bpmn-visualization-js/pull/1863#issuecomment-1070819537
- https://github.com/process-analytics/bpmn-visualization-examples/pull/306
Describe the solution you'd like
Understand how the mxgraph Segment Connector
implementation was working and how it recomputes the whole waypoints.
Try to replicate it to support the use case.
The implementation will probably use the "terminal port", see https://jgraph.github.io/mxgraph/docs/js-api/files/util/mxConstants-js.html#mxConstants.STYLE_SOURCE_PORT (and target port).
Reminder:
- live collapsing pools and sub-processes is experimental in version
0.22.0
, so this is a "nice to have" feature - this was only used in a specific examples (using mxgraph custom code) and has been disable in https://github.com/process-analytics/bpmn-visualization-examples/pull/307
- the demo code is also able to manage this use case with the same custom mxgraph code: see #1867
Additional context Screenshots of the collapsed pools used in visual tests with the new implementation introduced by #1868.
collapsing pools on the left of the diagram | collapsing pools on the right of the diagram |
---|---|
![]() |
![]() |
![]() |
![]() |