mermaid-js / mermaid

Generation of diagrams like flowcharts or sequence diagrams from text in a similar manner as markdown
https://mermaid.js.org
MIT License
72k stars 6.53k forks source link

Links cannot be made linear in a 'flowchart' diagram #1990

Open Polirecyliente opened 3 years ago

Polirecyliente commented 3 years ago

Output of mmdc -V 8.9.2

This produces links with a 'linear' interpolation:

graph TB
  linkStyle default interpolate linear
  A --> B --> A

On the other hand, this produces links with a 'basis' interpolation:

flowchart TB
  linkStyle default interpolate linear
  A --> B --> A

The expected result is that both produce links with a 'linear' interpolation. See #1920

michael-madison-wwt commented 3 years ago

I just had to track this down myself. The issue appears to be in insertEdge in the dagre-wrapper:

https://github.com/mermaid-js/mermaid/blob/1b3971d6dad7fc32e76862e183118e9283a58bc1/src/dagre-wrapper/edges.js#L357

That line is only checking for the non-beta versions of the flowchart.

nirname commented 1 year ago

@michael-madison-wwt any updates on that?