Skip to content

fix(mdxish): callout end tag rendering#1373

Merged
eaglethrost merged 2 commits intonextfrom
dimas/rm-15614-editor-does-not-deserialize-callout-jsx-component-syntax
Mar 15, 2026
Merged

fix(mdxish): callout end tag rendering#1373
eaglethrost merged 2 commits intonextfrom
dimas/rm-15614-editor-does-not-deserialize-callout-jsx-component-syntax

Conversation

@eaglethrost
Copy link
Contributor

@eaglethrost eaglethrost commented Mar 13, 2026

PR App Fix RM-15614

🧰 Changes

As a part to resolve a Callout component deserialization issue in RM-15614, it turns out that particular callout was not creating the correct tree & some its content is incorrectly rendered. The cause was that a logic in the mdxish component transformation which was unwrapping the paragraph from a part of the node that contains the closing tag (if the closing tag is together with the content before it). In the case of the example in the ticket, the Callout ends up with children [h3, text, strong, text] instead of [h3, p]. The inline nodes (text, strong) become direct children of the Callout rather than being nested inside a paragraph element.

The fix is to use the full node content instead of the children only (unwrapped). Did a few testing and I haven't found any regressions, the change should only wrap some content as it originally was which shouldn't cause rendering differences (this is specific to Callouts)

🧬 QA & Testing

Using the content in mdxish:

<Callout theme="info" icon="📘">
### Title here

Body with **markdown** support.
</Callout>

It should render the "Body with markdown support" part in one line

@eaglethrost eaglethrost marked this pull request as ready for review March 13, 2026 12:19
@eaglethrost eaglethrost requested a review from kevinports March 13, 2026 12:22
Copy link
Contributor

@kevinports kevinports left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lgtm

Co-authored-by: Kevin Ports <kevin.ports@gmail.com>
@eaglethrost eaglethrost merged commit cad7594 into next Mar 15, 2026
17 of 19 checks passed
@eaglethrost eaglethrost deleted the dimas/rm-15614-editor-does-not-deserialize-callout-jsx-component-syntax branch March 15, 2026 21:45
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.

2 participants