Wrap in nonincremental div code annotation definition list to prevent incremental applying #11170
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.
fixes #7142
When we deal with Code Annotation in our Lua processing, if
incremental: true
is set, then we make sure to wrap the definition list in aDiv
of classnonincremental
, which is the way to opt out per Pandoc's documentation: https://pandoc.org/MANUAL.html#incremental-listsFor now, it will modify the resulting DOM in revealjs as Pandoc removes the class, but does not clean div when it is empty: jgm/pandoc#10328
We could do the cleaning if necessary. We could generalise the scaffold added for blockquotes
quarto-cli/src/format/reveal/format-reveal.ts
Lines 883 to 902 in 820c998
This is one way to solve #7142 - As mention in Team discussion, we could also do post processing to remove
fragment
on DefinitionList created for annotation.Design question:
For now, this applies to all code annotation. This means that when

incremental: true
andcode-annoation: below
, the definition list won't be incremental.We could only apply this logic to
code-annotation: hover
orcode-annotation: select
if we think those list should be incremental like any other Definition List. I am hesitant on this...Enregistrement.2024-10-23.163853.mp4
Any thoughts ?