feat: add invertable image shortcode

Useful to invert diagrams, graphs, etc. in dark theme.
To use it in a markdown file, add a line like:
{{ invertable_image(src="/img.png", alt="alt text") }}
This commit is contained in:
welpo
2023-02-10 02:36:23 +01:00
parent c26c826471
commit 389c724fe0
2 changed files with 6 additions and 1 deletions

View File

@@ -0,0 +1 @@
<img class="invertable-image" {% if src %}src="{{ src }}"{% endif %} {% if alt %}alt="{{ alt }}"{% endif %}/>