{{ $base := "art" }} {{ if .Params.threed }} {{ $base = "3d" }} {{ end }} {{ if .Params.animation }} {{ $base = "animation" }} {{ end }} {{ $month := 1 }} {{ $year := 1 }} {{ if .Params.date }} {{ $split := split .Params.date "-" }} {{ $year = int (index $split 0) }} {{ $month = int (index $split 3) }} {{ end }} {{ $full := "" }} {{ $jpeg := "" }} {{ $full = printf "https://images.redstrate.com/thumb/%s.avif" .Params.slug }} {{ $jpeg = printf "https://images.redstrate.com/thumb/%s.jpg" .Params.slug }} {{ if $full }} {{ $filename_without_ext := .Params.slug }} {{ $title := .Params.title }} {{ with $full }} {{ if $.Params.threed }} {{ with resources.Get "3d.png" }} 3D cube icon {{ end }} {{ end }} {{ if $.Params.comic }} {{ with resources.Get "comic.png" }} Comic icon {{ end }} {{ end }} {{ if $.Params.animation }} {{ with resources.Get "play-circle.png" }} Play animation icon {{ end }} {{ end }} {{ $.Params.alt_text }} {{ else }}

Thumbnail not found!

{{ end }}
{{ else }} CANNOT FIND {{ .Params.slug }} {{ end }}