summaryrefslogtreecommitdiff
path: root/layouts/_partials/posts
diff options
context:
space:
mode:
Diffstat (limited to 'layouts/_partials/posts')
-rw-r--r--layouts/_partials/posts/action-menu.html17
-rw-r--r--layouts/_partials/posts/webmention-replies.html3
2 files changed, 13 insertions, 7 deletions
diff --git a/layouts/_partials/posts/action-menu.html b/layouts/_partials/posts/action-menu.html
index 869996b9..f397996d 100644
--- a/layouts/_partials/posts/action-menu.html
+++ b/layouts/_partials/posts/action-menu.html
@@ -27,19 +27,24 @@
{{ range $webmentions }}
{{ $props := index . "microformats" "properties" }}
+ {{ $type := index . "microformats" "type" 0 }}
- {{ if index $props "like-of" }}
- {{ $likes = $likes | append . }}
+ {{ if eq $type "h-entry" }}
+ {{ if index $props "like-of" }}
+ {{ $likes = $likes | append . }}
- {{ else if index $props "in-reply-to" }}
- {{ $replies = $replies | append . }}
- {{ else if index $props "repost-of" }}
- {{ $reposts = $mentions | append . }}
+ {{ else if index $props "repost-of" }}
+ {{ $reposts = $mentions | append . }}
+ {{ else }}
+ {{ $replies = $replies | append . }}
+
+ {{ end }}
{{ else }}
{{ $mentions = $mentions | append . }}
{{ end }}
+
{{ end }}
{{ partial "posts/action-area" . }}
diff --git a/layouts/_partials/posts/webmention-replies.html b/layouts/_partials/posts/webmention-replies.html
index bbdd1111..19e6a352 100644
--- a/layouts/_partials/posts/webmention-replies.html
+++ b/layouts/_partials/posts/webmention-replies.html
@@ -4,11 +4,12 @@
{{ $reply := index . "microformats" "properties" }}
{{ $author := index (index $reply "author") 0 }}
{{ $author = index $author "properties" }}
+ {{ $photo := or (index $author.photo 0) (index $reply.photo 0) }}
<div class="relative">
<header class="flex justify-between items-start">
<div class="flex items-center gap-3">
- <img src="{{ index $author.photo 0 }}" alt="Profile Picture"
+ <img src="{{ $photo }}" alt="Profile Picture"
class="h-8 w-8 rd-full" loading="lazy" />
<div class="text-secondary">
<p class="font-bold m-0">