Closed jkrude closed 1 year ago
Will the above code work? Any updates on this?
Will the above code work? Any updates on this?
Yes, if you add %%{init: {'theme': 'dark' } }%% at the start of your mermaid code, it will be in dark mode.
Example:
Of course this is just a workaround and having mermaid dynamically configured by reading the logseq system theme would be much handier.
First of all thank you for this very useful plugin! As I mostly use dark-mode-themes with logseq it would be extremely useful if the mermaid-theming could be adjusted. Unfortunately, I'm not a web developer, but I guess you could change the theme to the system default here by adding:
Further, I am not sure if the internal logseq setting for dark mode could be directly queried. Otherwise, an option could be added for the plugin where the user can choose between the themes available by default and the
%%{init: {'theme': 'theme-name' }}%%
line is automatically injected.Mermaid theming docs.