Description
Description
Upgrade transitive dependency DOMPurify from 3.1.6 to 3.1.7
See flowchart diagram labels being empty, because <foreignObject>
tags are empty
Steps to reproduce
Upgrade transitive dependency DOMPurify from 3.1.6 to 3.1.7
```mermaid
graph TD;
A-->B;
A-->C;
B-->D;
C-->D;
```
Screenshots
Code Sample
No response
Setup
- Mermaid version: 10.x, 11.x
- Browser and Version: all
Suggested Solutions
Convince DOMPurify to revert breaking change.
DOMPurify report here: cure53/DOMPurify#1002
Workaround, force resolution to v3.1.6
"resolutions": {
"dompurify": "3.1.6"
},
Additional Context
I'm the maintainer of Docusaurus and this issue affects all our newly initialized sites. The problematic version was published 1 day ago and we already got 2 bug reports that Mermaid diagrams do not work well.
- Mermaid diagrams do not render text nodes (empty
foreignObject
) facebook/docusaurus#10526 - Some Mermaid diagrams are not rendering text facebook/docusaurus#10524
I'm opening this issue mostly to let you know of the problem.
I don't really know how Mermaid uses that lib exactly, nor if it's possible for you to patch usage on your side to make Mermaid code compatible with v3.1.7+. You could also decide to pin the dependency.
Personally I consider it a breaking change and they should rather revert it, but it's their responsibility to decide.