Better callouts for notes, warnings, and cautions
- [x] Feature Request
- [ ] Bug Report
Problem: Pages that contain critical users warnings aren't effectively called out.
Proposed Solution:
Create CSS to better call out important warnings, cautions, and notes for developers using Kubernetes. I attached some example screenshots of how other sites call these out.

Cody is on this :) Make a PR for callouts for Notes, Info, Caution, Warnings
An easy way to achieve this from might be emojis + markdown quotes. Here's an example:
⚠️⚠️ WARNING: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam nec accumsan tellus. Vestibulum et fermentum nibh, quis suscipit lorem. Morbi ac faucibus enim. Nulla gravida molestie euismod. Nam sed aliquam elit. Donec euismod id mauris ac convallis. Nulla sit amet vulputate arcu. Etiam auctor vestibulum vestibulum. Pellentesque egestas ultrices ipsum vitae pellentesque.
or
ℹ️ NOTE: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam nec accumsan tellus. Vestibulum et fermentum nibh, quis suscipit lorem. Morbi ac faucibus enim. Nulla gravida molestie euismod. Nam sed aliquam elit. Donec euismod id mauris ac convallis. Nulla sit amet vulputate arcu. Etiam auctor vestibulum vestibulum. Pellentesque egestas ultrices ipsum vitae pellentesque.
I'm not sure how easily we can achieve the described task from scratch. Two solutions I can think of:
- Author these boxes in HTML (e.g.
<blockquote class="warning">...) because Markdown doesn't let us customize paragraphs. This means inside the boxes, you have to use HTML and not Markdown. Little annoyance but o.k. - Write Javascript to go through paragraphs and find prefixes like
Warning:,Caution:,Note:and stylize them. This requires us write Javascript. Also suvh dynamic styling would occur once the page is fully loaded (so the user would see it happening) and it would not be captured by search engines easily. - Plugins: like http://idratherbewriting.com/documentation-theme-jekyll/mydoc_alerts.html
Do we have anything in place today or is this going to be built from scratch?
Thanks for the research, @ahmetb! This will probably have to be built from scratch. Right now bolding the callouts is the only way we differentiate them from the rest of the text.
I was wondering if it would be possible to implement something like Attribute Lists from Python Markdown or Span Inline Attribute Lists from Kramdown.
It'd be convenient to just define a class {: .notice} or {: .warning}, but I like that Tom's plugin is already designed for multiple callouts. What do you think is the best path to pursue?
Implementing something like those plugins for this problem sounds a bit overkill.
I'm imagining some form of template and include can get us a decent solution. e.g.
{% include warning.html content="This is my sample note." %}
This makes it difficult putting multi-line or formatted content into the block (I assume it wouldn't accept markdown in "content" variable and would require HTML), but I think it addresses the immediate problem. Can you give this a try?
Closed with PR #4535