From b1e95032f6991d3d6504bb4c0e3360af24e2c783 Mon Sep 17 00:00:00 2001 From: Steffo Date: Mon, 14 Sep 2026 07:46:07 +0200 Subject: [PATCH 1/4] Add `
`, `
`, and `
` to the allowed elements Signed-off-by: Stefano Pigozzi --- src/app/plugins/markdown/allowedHtmlTags.ts | 3 +++ src/app/utils/sanitize.ts | 3 +++ 2 files changed, 6 insertions(+) diff --git a/src/app/plugins/markdown/allowedHtmlTags.ts b/src/app/plugins/markdown/allowedHtmlTags.ts index ffaf14f7ae..26ba58ad0f 100644 --- a/src/app/plugins/markdown/allowedHtmlTags.ts +++ b/src/app/plugins/markdown/allowedHtmlTags.ts @@ -5,9 +5,12 @@ export const MARKDOWN_ALLOWED_HTML_TAGS = new Set([ 'blockquote', 'br', 'code', + 'dd', 'del', 'details', 'div', + 'dl', + 'dt', 'em', 'h1', 'h2', diff --git a/src/app/utils/sanitize.ts b/src/app/utils/sanitize.ts index 90d25c52d6..4293195851 100644 --- a/src/app/utils/sanitize.ts +++ b/src/app/utils/sanitize.ts @@ -43,6 +43,9 @@ const permittedHtmlTags = [ 'img', 'details', 'summary', + 'dl', + 'dt', + 'dd', ] as const; const permittedTagToAttributes = { From ef543d8e05b0372c18544a88523776c5ca1f6afe Mon Sep 17 00:00:00 2001 From: Steffo Date: Mon, 14 Sep 2026 07:47:38 +0200 Subject: [PATCH 2/4] Style `
`, `
`, and `
` elements Signed-off-by: Stefano Pigozzi --- src/app/plugins/react-custom-html-parser.tsx | 22 ++++++++++++++++++++ src/app/styles/CustomHtml.css.ts | 22 ++++++++++++++++++++ 2 files changed, 44 insertions(+) diff --git a/src/app/plugins/react-custom-html-parser.tsx b/src/app/plugins/react-custom-html-parser.tsx index 7c67d324fa..4125106a2e 100644 --- a/src/app/plugins/react-custom-html-parser.tsx +++ b/src/app/plugins/react-custom-html-parser.tsx @@ -792,6 +792,28 @@ export const getReactCustomHtmlParser = ( ); } + if (name === 'dl') { + return ( +
+ {renderChildren()} +
+ ) + } + if (name === 'dt') { + return ( +
+ {renderChildren()} +
+ ) + } + if (name === 'dd') { + return ( +
+ {renderChildren()} +
+ ) + } + if (name === 'code') { if (parent && 'name' in parent && parent.name === 'pre') { const codeContent = renderChildren(); diff --git a/src/app/styles/CustomHtml.css.ts b/src/app/styles/CustomHtml.css.ts index a3a6f01b43..9972252fd7 100644 --- a/src/app/styles/CustomHtml.css.ts +++ b/src/app/styles/CustomHtml.css.ts @@ -338,3 +338,25 @@ export const Td = style([ minWidth: toRem(100), }, ]); + +export const DescriptionList = style([ + DefaultReset, + { + display: 'flex', + flexDirection: 'column', + }, +]); + +export const DescriptionTerm = style([ + DefaultReset, + { + fontWeight: 'bolder', + }, +]); + +export const DescriptionDetails = style([ + DefaultReset, + { + marginInlineStart: config.space.S700, + }, +]); From cd74b4a1b9be979587c5f2d44801239211147df6 Mon Sep 17 00:00:00 2001 From: Steffo Date: Mon, 14 Sep 2026 07:52:31 +0200 Subject: [PATCH 3/4] oxfmt pass Signed-off-by: Stefano Pigozzi --- src/app/plugins/react-custom-html-parser.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/app/plugins/react-custom-html-parser.tsx b/src/app/plugins/react-custom-html-parser.tsx index 4125106a2e..c6025dc0b3 100644 --- a/src/app/plugins/react-custom-html-parser.tsx +++ b/src/app/plugins/react-custom-html-parser.tsx @@ -797,21 +797,21 @@ export const getReactCustomHtmlParser = (
{renderChildren()}
- ) + ); } if (name === 'dt') { return (
{renderChildren()}
- ) + ); } if (name === 'dd') { return (
{renderChildren()}
- ) + ); } if (name === 'code') { From 6baf963bbfcbbf11e518b6d2d75b89ecdc731521 Mon Sep 17 00:00:00 2001 From: Steffo Date: Mon, 14 Sep 2026 08:17:51 +0200 Subject: [PATCH 4/4] Add changeset Signed-off-by: Stefano Pigozzi --- .changeset/add_support_for_description_lists.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .changeset/add_support_for_description_lists.md diff --git a/.changeset/add_support_for_description_lists.md b/.changeset/add_support_for_description_lists.md new file mode 100644 index 0000000000..f13137bc14 --- /dev/null +++ b/.changeset/add_support_for_description_lists.md @@ -0,0 +1,5 @@ +--- +default: minor +--- + +# Add support for description lists