oleeskild / digitalgarden

261 stars 147 forks source link

Dont render callout-content div if blank #267

Closed tyler-dot-earth closed 1 month ago

tyler-dot-earth commented 1 month ago

Fixes #266

A not-very-elegant solution to avoid rendering the callout-content div when the callout only has a title, like this:

> [!info] this callout has no title

Not sure how to make it better, just wanted to fix this papercut.

Happy to make improvements if given feedback :slightly_smiling_face:

oleeskild commented 1 month ago

Great, that seems to do the trick. I agree that this "feels" like a hack and was going to suggest doing this with CSS instead. But then I read your explanation on #266, and I can't think of a better solution of the top of my head. If it works, it works. Merging it in, thank you 🙌