Plugin to add block-styled content like summaries, notes, hints or warnings.
example:
!!! tip
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla et euismod
nulla. Curabitur feugiat, tortor non consequat finibus, justo purus auctor
massa, nec semper lorem quam in massa.
A nice example of this in action is the SuperMemo Guru Wiki, scroll all the way to the bottom of the page and he has a list of these and descriptions of how to use them.
> âš Note to self
> If apply the Suchman's ideas to Agile and Waterfall, it's more like do we use planning models.
>
> If we use planning model, then responding to change, means plans
Somehow, I thought this could be achievable solely from CSS, like the Kanban boards in the wonderful Spectrum community theme … But, as my CSS is really rusty, I probably won’t be able to help there .
Decided to take a stab at this. Check it out here:
The admonitions are basically a direct copy of the ones from the Material for MkDocs above, but I show the css to modify them if you want to customize the look.
I just wrote this plugin and didn’t do too much testing, so I wouldn’t be surprised if it could be buggy, but it is a pretty simple one so hopefully it works well.
Edit: I also haven’t submitted it to the community list yet - you have to manually download it from the Releases section on the repository.
Yeah, it could be achieved through Styling, since that what it boils down to. The user just needs to write HTML Markup instead of Markdown. I actually want to include something like that in the theme!
Once it’s submitted as a community plugin, I’ll go to 1.0.0 and then use typical semantic versioning from there, but honestly sometimes I don’t follow it well (like this release should have been a minor version update).
I am still using 0.0.4 until it is available on the Community Plugins, but I just noticed this. Could this be fixed somehow? The breaks don’t work. I know that it is because it gets turned into a <p> tag. So either each line has a new <p> tag, add <br /> or leave it as <pre> ? Just some suggestions.
Uses Obsidian’s Markdown renderer to render the admonition content, instead of just placing it all inside a <p> tag.
Removed requirement to use the content: flags if title: or collapse: is used
This should fix that issue. The content should render exactly like regular markdown outside of code blocks.
The only thing I could find that gives the admonition block fits is nested code – if its the last thing in the block it will render fine (and even do the prism highlighting), but if there’s content after it, that content will be placed outside the block.
Hi there! Your plugin is a great shot, yet I’m struggling with customizing default titles for each text block. For example, I’d like not to rename “Note” every time with the “content:” row but to give it another default title. Any suggestions?
In version 0.2.0 I removed the requirement to have the content: parameter if you have a unique title, which helps.
Right now, there isn’t the ability to do custom default titles, but I was planning on adding it. This is a little tricky because the plugin is telling Obsidian to treat each admonition type as a code block language (like javascript or mermaid), so it could collide with other languages and exhibit weird behavior.