various improvements and performance enhancements

This commit is contained in:
Stefan Hardegger
2025-08-12 14:55:51 +02:00
parent 75c207970d
commit c46108c317
11 changed files with 380 additions and 32 deletions

View File

@@ -17,7 +17,7 @@
"h4": ["class", "style"],
"h5": ["class", "style"],
"h6": ["class", "style"],
"a": ["class"],
"a": ["class", "href", "title"],
"table": ["class", "style"],
"th": ["class", "style", "colspan", "rowspan"],
"td": ["class", "style", "colspan", "rowspan"],
@@ -38,8 +38,10 @@
"font-weight", "font-style", "text-align", "text-decoration", "margin",
"padding", "text-indent", "line-height"
],
"removedAttributes": {
"a": ["href", "target"]
"allowedProtocols": {
"a": {
"href": ["http", "https", "#", "/"]
}
},
"description": "HTML sanitization configuration for StoryCove story content. This configuration is shared between frontend (DOMPurify) and backend (Jsoup) to ensure consistency."
}