mermaid-js / mermaid-cli

Command line tool for the Mermaid library
MIT License
2.23k stars 210 forks source link

background of edge label is white in pdf from flowchart #656

Open esc-grs opened 4 months ago

esc-grs commented 4 months ago

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):

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