We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ded1787 commit 2ab4156Copy full SHA for 2ab4156
src/plugins/page-icons/page-icons.js
@@ -1,5 +1,6 @@
1
import './store'
2
import { useSelect } from '@wordpress/data'
3
+import { safeHTML } from '@wordpress/dom'
4
5
/**
6
* Parse SVG string to extract attributes and innerHTML without DOM manipulation
@@ -28,7 +29,7 @@ const parseSVGString = svgString => {
28
29
return null
30
}
31
- const innerHTML = svgString.substring( svgTagEnd, closingTagIndex )
32
+ const innerHTML = safeHTML( svgString.substring( svgTagEnd, closingTagIndex ) )
33
34
// Extract attributes from the SVG tag
35
const svgAttributes = {}
0 commit comments