mirror of
https://github.com/BoostIo/Boostnote
synced 2025-12-12 17:26:17 +00:00
fix mermaid xss
This commit is contained in:
@@ -845,7 +845,7 @@ export default class MarkdownPreview extends React.Component {
|
||||
_.forEach(
|
||||
this.refs.root.contentWindow.document.querySelectorAll('.mermaid'),
|
||||
el => {
|
||||
mermaidRender(el, htmlTextHelper.decodeEntities(el.innerHTML), theme)
|
||||
mermaidRender(el, htmlTextHelper.encodeEntities(el.innerHTML), theme)
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user