[docs] Add more types of callouts
See original GitHub issueMotivation
The blockquote/callout element is supposed to serve as a way to provide additional information that can vary in terms of relevance in comparison to the page content flow. What communicates relevance is its styling and currently, there is only one possible option for it: yellow, to resonate with warning info. There are instances where the blockquote is used but not to deliver information you should be warned about but rather something interesting you could consider — here are a few examples:
- Tip about the default theme - not a warning but rather a tip.
- Good practices when using
<GlobalStyles />
- not a warning but rather a tip. - Clarifying terms with a small glossary - not a warning but rather additional info.
Request
The documentation might be improved if we added two other types of callouts. That would increase the flexibility to vary the relevance of given information. Generally, I think these are the ones we should support:
- Info/Note (blue): interesting point to consider (could be green as well?!).
- Caution (yellow): make sure you’re aware of this before moving forward.
- Warning/Danger (red): proceed very carefully (or at times, you shouldn’t do this at all).
And this is a very fast iteration on their styling — a bit of further polish would be needed.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:5
- Comments:8 (8 by maintainers)
Top GitHub Comments
I lean toward custom markdown syntax (Docusaurus)!
A quick benchmark of how this is implemented by some products:
<aside>
. For example:<alert>
with some form of post-processing to replace it with a div once rendered.