fix: stop dompurify from breaking draw.io diagrams (#7888)

Newer versions of dompurify strip <foreignobject> tags if not explicitly
allowed. See https://github.com/cure53/DOMPurify/issues/1040

Fixes #7744
This commit is contained in:
Felix Eckhofer
2026-01-06 16:56:35 -05:00
committed by GitHub
parent 028dcd5656
commit b950e065e9
3 changed files with 6 additions and 3 deletions
@@ -34,7 +34,8 @@ module.exports = {
input = DOMPurify.sanitize(input, {
ADD_ATTR: allowedAttrs,
ADD_TAGS: allowedTags
ADD_TAGS: allowedTags,
HTML_INTEGRATION_POINTS: { foreignobject: true }
})
}
return input