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
68.79k stars 6.08k forks source link

The Relation height changed from v10.4.0 - v10.5.0 for class diagrams #5417

Closed ad1992 closed 3 months ago

ad1992 commented 3 months ago

Description

For some reason, the relation in class diagrams was updated

In V10.4.0 👇🏻

Screenshot 2024-03-26 at 12 41 24 PM

In v10.5.0 👇🏻

Screenshot 2024-03-26 at 12 39 12 PM

8f-9df7-e18c8fa75925">

As you can see there was a 18 px reduction and also earlier the the triangle in arrow-head was filled with the same color (violet) as the classes where whereas now it is white.

Any idea what caused this and why was it updated? cc @sidharthv96

Steps to reproduce

Mentioned above

Screenshots

Added

Code Sample

No response

Setup

No response

Suggested Solutions

No response

Additional Context

No response

sidharthv96 commented 3 months ago

PR: https://github.com/mermaid-js/mermaid/pull/4804 Issue: https://github.com/mermaid-js/mermaid/issues/4691

Earlier the path was from one box to the next, with arrow overlaid on top. This resulted in some visual defects, hence the line was drawn till the start of the arrowhead.

Arrow's color being white is to align with sequence diagram standards.

ad1992 commented 3 months ago

PR: #4804 Issue: #4691

Earlier the path was from one box to the next, with arrow overlaid on top. This resulted in some visual defects, hence the line was drawn till the start of the arrowhead.

Arrow's color being white is to align with sequence diagram standards.

yeah was suspecting the same PR but wasn't sure as it was only for sequence diagram as per the code, but now it makes sense. Hence for solid/dotted triangle arrowheads, the change is more visible (since we derive the dimensions of arrow from svg where the length is now shortened)