mirror of
https://seed.radicle.dev/rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5.git
synced 2026-10-18 19:30:27 +08:00
Fix inline emphasis tags in markdown output
- Without strong, **bold** rendered as plain text since marked emits <strong> and DOMPurify stripped the unknown tag - Add strong, b, i, del, s to DOMPurify allow-list - Cover the other inline emphasis tags authors may write as raw HTML or that GFM strikethrough emits (<del>)
This commit is contained in:
@@ -31,14 +31,17 @@ dompurify.setConfig({
|
||||
],
|
||||
ALLOWED_TAGS: [
|
||||
"a",
|
||||
"b",
|
||||
"blockquote",
|
||||
"br",
|
||||
"code",
|
||||
"dd",
|
||||
"del",
|
||||
"div",
|
||||
"dl",
|
||||
"dt",
|
||||
"em",
|
||||
"i",
|
||||
"h1",
|
||||
"h2",
|
||||
"h3",
|
||||
@@ -53,6 +56,8 @@ dompurify.setConfig({
|
||||
"p",
|
||||
"pre",
|
||||
"radicle-external-link",
|
||||
"s",
|
||||
"strong",
|
||||
"table",
|
||||
"tbody",
|
||||
"td",
|
||||
|
||||
Reference in New Issue
Block a user