r4ai / remark-callout

A remark plugin to add obsidian style callouts to markdown
https://r4ai.github.io/remark-callout/
MIT License
4 stars 1 forks source link

fix: skip empty callout body #146

Closed r4ai closed 1 month ago

r4ai commented 1 month ago

fix #134

Don't render callout body when it is empty.

For insance,

> [!note]

yieds:

before:

<div data-callout data-callout-type="note">
  <div data-callout-title>Note</div>
  <div data-callout-body>
  </div>
</div>

after:

<div data-callout="" data-callout-type="note">
  <div data-callout-title="">Note</div>
</div>
changeset-bot[bot] commented 1 month ago

🦋 Changeset detected

Latest commit: f4a4b58d29e1065328794af39c64c29f179bd4b2

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package | Name | Type | | -------------------- | ----- | | @r4ai/remark-callout | Minor |

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR