mermaid-js/mermaid-cli

background of edge label is white in pdf from flowchart

esc-grs opened this issue · 0 comments

Describe the bug
Colored background of flowchart edge labels becomes white when exported as pdf. Both svg and png look fine though.

To Reproduce
I am converting
basic.txt

using mermaid-cli 10.6.1 via

mmdc -i basic.txt -o basic.png
mmdc -i basic.txt -o basic.svg
mmdc -i basic.txt -o basic.pdf

Expected behavior
The pdf should look like the png and svg.

Screenshots
png:
basic
svg:

pdf file:
basic.pdf
pdf screenshot:
image

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser: svg works in Firefox, MS Edge
  • Pdf Viewer: pdf looks wrong in Acrobat Reader 2023.008 and in TexWorks Pdf viewer, Gimp 2.10.36

Additional context
Side note, the inline display in Firefox 115.7.0esr (64-bit) looks wrong.
Seems fixed as of today 2024/03/06.

%%{
  init: {
    'theme': 'default'
  }
}%%

flowchart LR
   U --> |edge_label_text| B

screen shoot (from 2024/03/01):
image