{{ define "main" }} {{- $images := .Resources.ByType "image" }} {{- $cover := $images.GetMatch (.Params.cover | default "*cover*") }} {{- $feature := $images.GetMatch (.Params.feature | default "*feature*") | default $cover }}
{{ if .Params.showBreadcrumbs | default (.Site.Params.article.showBreadcrumbs | default false) }} {{ partial "breadcrumbs.html" . }} {{ end }}

{{ .Title | emojify }}

{{ partial "article-meta.html" (dict "context" . "scope" "single") }}
{{ with $feature }}
{{ $altText := $.Params.featureAlt | default $.Params.coverAlt | default "" }} {{ $class := "mb-6 -mt-4 rounded-md" }} {{ partial "picture.html" (dict "img" . "alt" $altText "class" $class "lazy" false) }} {{ with $.Params.coverCaption }}
{{ . | markdownify }}
{{ end }}
{{ end }}
{{ if and (.Params.showTableOfContents | default (.Site.Params.article.showTableOfContents | default false)) (in .TableOfContents "
{{ partial "toc.html" . }}
{{ end }}
{{ .Content | emojify }}
{{ end }}