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
72.69k stars 6.62k forks source link

Class diagrams: Only first self-reference is rendered #6034

Open h0lg opened 2 weeks ago

h0lg commented 2 weeks ago

Description

When I add more than one self-reference to a node on a class diagram, only the last one is rendered.

Steps to reproduce

Create more than one self-reference for any node.

Screenshots

No response

Code Sample

classDiagram
classG <-- classG : ref1
classG <-- classG : ref2

on https://mermaid.js.org/syntax/classDiagram.html :

image

Setup

h0lg commented 2 weeks ago

The Github renderer seems not to have an issue with this:

classDiagram
classG <-- classG : ref1
classG <-- classG : ref2