fix(ui): preserve SVG tags in DOMPurify config for KaTeX math rendering (#25866)

This commit is contained in:
Sergei Zharinov
2026-05-06 05:06:37 -03:00
committed by GitHub
parent c235ba1bef
commit 518503b29b

View File

@@ -33,6 +33,8 @@ const config = {
SANITIZE_NAMED_PROPS: true,
FORBID_TAGS: ["style"],
FORBID_CONTENTS: ["style", "script"],
ADD_TAGS: ["svg", "path"],
ADD_ATTR: ["d", "viewBox", "preserveAspectRatio", "xmlns"],
}
const iconPaths = {