Handle <img> tag support in graphs
This commit is contained in:
@@ -13,7 +13,9 @@
|
||||
if (!svg) {
|
||||
svg = document.querySelector('#container svg');
|
||||
}
|
||||
const svgString = svg.outerHTML.replaceAll('<br>', '<br/>');
|
||||
const svgString = svg.outerHTML
|
||||
.replaceAll('<br>', '<br/>')
|
||||
.replaceAll(/<img([^>]*)>/g, (m, g) => `<img ${g} />`);
|
||||
return toBase64(svgString);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user