fix: refreshing mermaid theme may fail (#2113)
This commit is contained in:
parent
0360c9e90b
commit
2f00d41861
1 changed files with 1 additions and 1 deletions
|
@ -11,7 +11,7 @@ function refreshTheme(event) {
|
|||
const mermaidList = document.getElementsByClassName(MERMAID);
|
||||
|
||||
[...mermaidList].forEach((elem) => {
|
||||
const svgCode = elem.previousSibling.children.item(0).innerHTML;
|
||||
const svgCode = elem.previousSibling.children.item(0).textContent;
|
||||
elem.textContent = svgCode;
|
||||
elem.removeAttribute('data-processed');
|
||||
});
|
||||
|
|
Loading…
Add table
Reference in a new issue