{{define "figure" -}}
{{- range .Pictures}} {{$.Args.alt}} {{- end}} {{- if not .Pictures}} {{.Args.alt}} {{- end}} {{- if .Args.caption}}
{{.Args.caption}}
{{- end}}
{{- end}} {{define "gallery" -}} {{if .Pictures -}} {{- end}} {{- end}} {{/* One template for the whole set: which names exist is the theme's business, never the engine's (ADR-0063). Unicode here, so the reference theme ships no sprite, no font and no asset — a theme wanting drawn icons redefines this block and emits against its own sprite. An unknown name renders nothing, which is how a theme says so, and the engine puts the author's text back. */}} {{define "icon"}} {{- if eq .Args.name "warn"}}⚠️ {{- else if eq .Args.name "note"}}ℹ️ {{- else if eq .Args.name "tip"}}💡 {{- else if eq .Args.name "star"}}⭐ {{- else if eq .Args.name "check"}}✅ {{- else if eq .Args.name "cross"}}❌ {{- end}} {{- end}} {{/* Admonitions. One template per kind, because a call renders through a template of its own name — the markup is the theme's and the engine supplies only the name, the arguments and the rendered body (ADR-0064). `.Body` is already HTML. A theme with no template for a kind renders nothing, and the engine writes the body out unwrapped rather than losing it. */}} {{define "note"}}{{end}} {{define "warn"}}{{end}} {{define "tip"}}{{end}} {{/* A flat list with a level class per entry, so nesting is a CSS decision rather than a markup one: the engine supplies depth and the theme decides whether to indent (ADR-0065). An entry with no id is skipped rather than linked nowhere. */}} {{define "toc"}} {{- if .Headings}} {{- end}} {{- end}}