Color-switchable mermaid chart #903
tomy0000000
started this conversation in
Ideas
Replies: 1 comment
-
A sample for current behavior
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Congo currently decides the color palette for the mermaid on page load, then renders the diagram. However, if the user changes the appearance, the chart palette does not follow along.
Since mermaid renders by looking at the content within a designated
div
, I think it should be possible to store the chart markup somewhere in the Javascript, re-render a new one, and swap it out when the appearance switch is clicked.Not quite sure if this will work and whether there will be any issues. Posting to gather some feedback, if this is something people are happy to see, I can try to make this happen.
Beta Was this translation helpful? Give feedback.
All reactions