mirror of
https://github.com/McShelby/hugo-theme-relearn.git
synced 2024-11-24 00:03:10 +00:00
14 lines
No EOL
345 B
HTML
14 lines
No EOL
345 B
HTML
{{- $version := split hugo.Version "." }}
|
|
{{- $major := int (index $version 0) }}
|
|
{{- $minor := int (index $version 1) }}
|
|
{{- $id := "" }}
|
|
{{- if and (ge $major 0) (ge $major 108) }}
|
|
{{- $id = .Ordinal }}
|
|
{{- end }}
|
|
{{- partial "shortcodes/image.html" (dict
|
|
"context" .Page
|
|
"url" .Destination
|
|
"title" .Title
|
|
"alt" .Text
|
|
"id" $id
|
|
) }} |