{{- $version := .Get 0 -}} {{- $url := printf "https://github.com/dillonzq/LoveIt/releases/tag/v%s" $version -}} {{- $label := .Get 1 | default "new" | T -}} {{- $color := cond (.Get 1 | eq "changed") "ff9101" "00b1ff" | cond (.Get 1 | eq "deleted") "ff5252" -}} {{- $badge := printf "https://img.shields.io/badge/%s-%s-%s?style=flat-square&labelColor=403c3d&?cacheSeconds=maxAge" $label $version $color -}} {{- $alt := printf "LoveIt %s | %s" $label $version -}} {{ partial "plugin/image.html" (dict "src" $badge "alt" $alt) }}