Mermaid Diagrams not Properly Rendering in Snippets
Summary
Mermaid diagrams render as code blocks in a snippet's included markdown files, and in the snippet's description. When editing the description of a snippet, the preview button does properly render the markdown diagrams.
This issue appears unique to mermaid, and doesn't seem to affect PlantUML graphs, for example.
Steps to reproduce
-
Make a new snippet
-
Add a markdown file, and put the following code in the snippet's description, as well as in the markdown file:
View Code
```mermaid graph TD A[Christmas] -->|Get money| B(Go shopping) B --> C{Let me think} C -->|One| D[Laptop] C -->|Two| E[iPhone] C -->|Three| F[fa:fa-car Car] ```
-
Click Preview
-
See intended behavior
-
Create the snippet
-
View the snippet, see bug
Example Project
Here's a snippet I made demonstrating this bug.
What is the current bug behavior?
Mermaid graphs are rendered as code blocks, instead of being rendered in the markdown document:
What is the expected correct behavior?
Mermaid graphs should be rendered in the markdown document: