-
On I first assumed that you can define different statuses (custom ones) but the later section mentions that only new and deprecated are supported, which confused me a lot. This section should be improved as the wording can be confusing and a bit misleading, which isn't helped by the example using Perhaps, in the future could this option be tweaked to allow own custom statuses by providing a identifier, description and icon-path for existing and new identifiers. extra:
status:
- identifier: experimental
description: 'Experimental Feature'
icon: 'octicons/alert-24'
- identifier: new
description: 'Recently Added'
icon: 'octicons/stopwatch-24'
- identifier: deprecated
description: 'Deprecated'
icon: 'octicons/trash-24' |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
This can already be done! In extra:
status:
experimental: Experimental feature Then add a new CSS class with the status name as BEM modifier (e.g. .md-status--experimental::after {
mask-image: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 24 24"><path fill="currentColor" d="M13 17.5a1 1 0 1 1-2 0a1 1 0 0 1 2 0Zm-.25-8.25a.75.75 0 0 0-1.5 0v4.5a.75.75 0 0 0 1.5 0v-4.5Z"/><path fill="currentColor" d="M9.836 3.244c.963-1.665 3.365-1.665 4.328 0l8.967 15.504c.963 1.667-.24 3.752-2.165 3.752H3.034c-1.926 0-3.128-2.085-2.165-3.752Zm3.03.751a1.002 1.002 0 0 0-1.732 0L2.168 19.499A1.002 1.002 0 0 0 3.034 21h17.932a1.002 1.002 0 0 0 .866-1.5L12.866 3.994Z"/></svg>');
} You can now use the status in front matter: ---
status: experimental
---
# Headline 1 We'll see how we can improve the documentation. |
Beta Was this translation helpful? Give feedback.
This can already be done! In
mkdocs.yml
:Then add a new CSS class with the status name as BEM modifier (e.g.
--experimental
) and the SVG, prefixed with:url('data:image/svg+xml;charset=utf-8,<SVG...>')