Skip to content

Allow safe HTML in Markdown field layout elements - #19426

Merged
brandonkelly merged 2 commits into
6.xfrom
brandon/pt-3411-allow-safe-html-in-markdown-field-layout-elements
Aug 12, 2026
Merged

brandonkelly merged 2 commits into
6.xfrom
brandon/pt-3411-allow-safe-html-in-markdown-field-layout-elements

Conversation

@brandonkelly

Copy link
Copy Markdown
Member

Description

Updates CraftCms\Cms\Form\Nodes\MarkdownContent to HTML-purify the configured content, rather than encode it.

Makes it possible to create detail disclosure elements, for example.

## This is a heading

<details>
<summary>Details</summary>

Disclosure paragraph.

</details>

Related issues

@linear-code

linear-code Bot commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

PT-3411

[ci skip]
@github-actions

Copy link
Copy Markdown

📚 Storybook previews

@craftcms/uiopen Storybook

No changed components detected in this Storybook.

resources/jsopen Storybook

No changed components detected in this Storybook.

@brandonkelly
brandonkelly merged commit 0e91304 into 6.x Aug 12, 2026
@brandonkelly
brandonkelly deleted the brandon/pt-3411-allow-safe-html-in-markdown-field-layout-elements branch August 12, 2026 21:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant