hackertours/layouts/_partials/icon.html
Vincent Mahnke 1846441465
Some checks failed
/ build (pull_request) Failing after 12s
/ accessibility (pull_request) Failing after 21s
refactor: Mobile footer directly shows menu options
2026-11-07 13:40:09 +01:00

12 lines
599 B
HTML

{{- /*
Render a Lucide icon from the local icons data file.
Usage: {{ partial "icon" "house" }}
Icons are fetched from data/lucideicons.json at build time
*/ -}}
{{- $iconName := . -}}
{{- with index hugo.Data.lucideicons $iconName -}}
{{- . | safeHTML -}}
{{- else -}}
{{- /* Fallback if icon not found */ -}}
<svg class="icon" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" focusable="false" aria-hidden="true"><circle cx="12" cy="12" r="10"/></svg>
{{- end -}}