[misc] Fixed JS error triggered when SVG content is embedded