Open vanbroup opened 1 year ago
Hmm, how would you decide whether that's a blockquote starting with a "Note" in bold or an admonition? I can imagine quite a few cases where a quote would start with Note or Warning. I can't say that I like the syntax. I'd accept a pull request if there's an option to enable/disable that syntax.
I'm sorry if that's not the answer you wanted to hear :-(
For the alternatives:
I've got the indentation system working (I think), so the following is now possible:
!!!!note This is a note
this is the body
Still in the note
This is the next paragraph
:
conflicts with pandoc's expectations for fences, e.g. ::::Note
should be a fenced div with the class ".Note". This doesn't work in goldmark with my goldmark-fences because goldmark's attribute parser doesn't work this way but I'd prefer not to introduce the conflict in notation.
I would have a use case for supporting the pandoc notation in goldmark-fences so this is probably a no-go for goldmark-admonitions.
But using pandoc's syntax, you could then use a hack for admonitions with the css selectors .note
and .note > p:first-child
. Please tell me if this would help you.The GitHub system is not perfect, but it feels natural even when not rendered. It would have my preference as we manage a lot of the projects within GitHub. Potentially the > **Warning**
instructor can be given its own class so that you can hide it using CSS and so something like > **Warning** **An important message**
which would result in the warning display but with a different title (outside GitHub).
Github updated it's way of handling admonitions.
Not the syntax looks like this:
> [!Note]
> This is a note
resulting in
[!Note] This is a note
The following admonitions are also possible:
[!Tip] This is a tip!
[!Warning] This is a warning!
[!Important] This is important!
[!Caution] Be cautious!
The same syntax is currently supported by Gitea too.
For more information see this Github discussion
It would be great if this would align with the GitHub implementation, see also https://github.com/orgs/community/discussions/16925
This markdown:
Will be shown as:
There are also other implementations that might be more flexible: https://github.com/orgs/community/discussions/16925#discussioncomment-2803633