I haven’t seen support for Alert Boxes in any official specifications, and I’d find them useful when used appropriately. I’m looking for something functionally similar to this or this.
I used a couple of different things in the past, and finally wrote something into one engine that I’m using because I needed it for something, but I’d like to see official support.
I’d like to propose support for the addition of alert boxes. I’m happy with whatever syntax everyone wants, but as a starting point, the way I did this was to just augment the blockquote syntax:
anything> This becomes a quote block, with the class anything-box added.
Expected output from that is something like:
<blockquote class='anything-box'>
<p>This becomes a quote block, with the class anything-box added.</p>
</blockquote>
I implemented this in a way to just piggy back off the blockquotes in markdown, but with a couple additional rules:
- classes can only contain US characters
A-Z
ora-z
- I didn’t want to monkey with é being one byte or two
- there cannot be a space between the class type and the
>
for the blockquote alert>
is valid,alert >
is not
I’m happy to consider other alternatives for doing this - mdwiki.info uses the syntax:
warning: The contents of this box are a warning.
And only triggers on specific keywords. I wanted to avoid trigger keywords, and allow people to do as much as they want in their CSS, so I tried being as generic as I could without getting to complex.
Thoughts? Better ways to do this?