summaryrefslogtreecommitdiffstats
path: root/layouts/shortcodes/svg.html
diff options
context:
space:
mode:
Diffstat (limited to 'layouts/shortcodes/svg.html')
-rw-r--r--layouts/shortcodes/svg.html5
1 files changed, 5 insertions, 0 deletions
diff --git a/layouts/shortcodes/svg.html b/layouts/shortcodes/svg.html
new file mode 100644
index 0000000..d042bb0
--- /dev/null
+++ b/layouts/shortcodes/svg.html
@@ -0,0 +1,5 @@
+<span class="inline-svg{{ with .Get "class" }} {{ . }}{{ end }}">
+{{- $fname := print "SVGs/" ( .Get "name" ) ".svg" -}}
+{{ $icon := resources.Get $fname }}
+{{ $icon.Content | safeHTML }}
+</span>