sphinxcontrib-mermaid icon indicating copy to clipboard operation
sphinxcontrib-mermaid copied to clipboard

mermaid_params does not work

Open ArthurFlag opened this issue 5 years ago • 4 comments

Hi,

I added what's from the Readme to my conf.py file:

mermaid_params = ['--theme', 'forest', '--width', '600', '--backgroundColor', 'transparent']

The build works fine, but I still get the default style. Has anyone experienced the same issue?

ArthurFlag avatar Feb 20 '20 14:02 ArthurFlag

I experience the same

MatinF avatar Apr 09 '20 18:04 MatinF

It works for me if I set mermaid_output_format to png or svg. But I want to use is on raw as well.

ajdajd avatar Oct 14 '20 10:10 ajdajd

The build works fine, but I still get the default style. Has anyone experienced the same issue?

I have the same problem with raw (the default)! For png or svg mermaid.cli is necessary and this seems to be difficult to install (for me on Windows at least).

gitPrinz avatar Apr 26 '21 13:04 gitPrinz

to set theme globally you use mermaid_init_js = "mermaid.initialize({startOnLoad:true, theme:'dark'});" or you can override specific graph with

.. mermaid::

    %%{init: {'theme':'base'}}%%
    pie showData
        title Key elements in Product X
        "Calcium" : 42.96
        "Potassium" : 50.05
        "Magnesium" : 10.01
        "Iron" :  5

oglops avatar Oct 22 '22 06:10 oglops