mikitex70/plantuml-markdown

plantuml inside admonitions rendered outside

9Lukas5 opened this issue · 1 comments

Hey,

I've a problem using plantuml-renders inside of admonitions from python-markdown.
I asked in the python-markdown repo yet, but as it's only happening with the plantuml renders, they suspect it's up to this extension.

setup:

package version
python 3.8.5
markdown 3.3.3
plantuml-markdown 3.4.1
pymdown-extensions 8.0.1
mkdocs 1.1.2
mkdocs-material 6.1.6

problem:

If I write plantuml code,
inside a code block,
inside an admonition,
the picture from plantuml-markdown get's placed below the admonition in the generated html.

Normal code blocks are working fine,
but the as plantuml marked ones replaced by the render not.

example code:

!!! note
    ```plantuml
    A --> B
    ```

html output:

<div class="admonition note">
    <p class="admonition-title">Note</p>
</div>
<p><img src="data:image/svg+xml;base64,<data left out>" class="uml" alt="uml diagram" title=""></p>

desired behaviour:

The produced diagram should be inside the admonition.

html output:

<div class="admonition note">
    <p class="admonition-title">Note</p>
    <p><img src="data:image/svg+xml;base64,<data left out>" class="uml" alt="uml diagram" title=""></p>
</div>

thanks for doing this so fast @mikitex70 I can confirm it's working now for me 😄