diff options
Diffstat (limited to 'themes/blowfish/layouts/partials/meta/likes.html')
-rw-r--r-- | themes/blowfish/layouts/partials/meta/likes.html | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/themes/blowfish/layouts/partials/meta/likes.html b/themes/blowfish/layouts/partials/meta/likes.html new file mode 100644 index 0000000..9cb5ff6 --- /dev/null +++ b/themes/blowfish/layouts/partials/meta/likes.html @@ -0,0 +1,22 @@ +<span> + {{ $id := "null" }} + {{ if eq .Kind "taxonomy" }} + {{ $id = delimit (slice "likes_taxonomy_" .Page.Data.Plural) "" }} + {{ else if eq .Kind "term" }} + {{ $id = delimit (slice "likes_term_" .Page.Data.Term) "" }} + {{ else }} + {{ $translations := .AllTranslations }} + {{ with .File }} + {{ $path := .Path }} + {{range $translations}} + {{ $lang := print "." .Lang ".md" }} + {{ $path = replace $path $lang ".md" }} + {{end}} + {{ $id = delimit (slice "likes_" $path) "" }} + {{ end }} + {{ end }} + <span id="{{ $id }}" + class="animate-pulse inline-block text-transparent max-h-3 rounded-full mt-[-2px] align-middle bg-neutral-300 dark:bg-neutral-400" + title="likes">loading</span> + <span class="inline-block align-text-bottom">{{ partial "icon.html" "heart" }}</span> +</span>
\ No newline at end of file |