[Enhancement] re-enable pandoc div rendering#6121
Merged
Merged
Conversation
Collaborator
Author
f2f74bc to
eeb7bb5
Compare
41641c8 to
e1f90c1
Compare
e1f90c1 to
579f12c
Compare
nathanlesage
approved these changes
Feb 11, 2026
nathanlesage
left a comment
Member
There was a problem hiding this comment.
In general this looks good, I only have a few concerns and questions.
ccc2916 to
d8b58c8
Compare
* better UX -- since the mark lines hide styling, * things like border radius become hidden
* blockwrappers should not alter the dom layout, * so we disallow rendering styles, such as * `display: flex`, `width`, and `height`, which * would otherwise alter the layout
d8b58c8 to
31b6a8f
Compare
Member
|
Looks good now, ready for merging, thank you very much once more! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Description
This PR re-enables pandoc div rendering by using the new
BlockWrapperapiChanges
The pandoc div and span renderers were separated because
BlockWrappershave a similar, but different, structure and typing thanDecorations.The div renderer was updated to use
BlockWrappers, which essentially wraps the given range in a separate HTML element. This provides better styling thanDecoration.linebecause the entire content is wrapped in one parent element.An additional blockwrapper was added around the opening and closing lines of the pandoc div to essentially revert the styling of parent divs. I did this so that those regions do not receive most styling from the parent pandoc div, making them easier to pick out when div rendering is enabled. This is a very simple override, and there is still some styling that applies. Another approach would be to use a widget across these regions, but that would have to be applied in a separate renderer function since those are applied as
Decorationobjects.Additional information
the
lightGreensection is a blockquote, which is why the font color is differentTested on: macOS 26/Fedora 43