Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mmdc not generating labels for SVG outputs #691

Open
radupotop opened this issue May 7, 2024 · 2 comments
Open

mmdc not generating labels for SVG outputs #691

radupotop opened this issue May 7, 2024 · 2 comments

Comments

@radupotop
Copy link

Describe the bug

mmdc does not generate labels when outputting SVG files.
This happens for flow charts and class charts on my machine, but not for sequence diagrams for example.

To Reproduce
Steps to reproduce the behavior:

echo "graph TD; THIS-->THAT; THAT-->THIS" | mmdc -i -

Output:

image

Expected behavior

The graph should include labels like so:

out

Desktop (please complete the following information):

  • Linux x86_64 6.8.9
  • gtk2 2.24.33-3
  • gtk3 3.24.41-1
  • gtk4 4.14.4-1
  • cairo 1.18.0-2
  • pango 1.52.2-1

My gut feeling is this is related to rendering on my machine (pango, cairo, etc).

@radupotop
Copy link
Author

Opened a corresponding issue here with librsvg:
https://gitlab.gnome.org/GNOME/librsvg/-/issues/1082

@radupotop
Copy link
Author

It looks like this is an issue with mermaid-cli after all:

This SVG uses foreignObject to embed HTML text. Supporting this would basically involve having a whole HTML renderer inside librsvg. Please tell mermaid-cli to use SVG text elements instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant