From 5f34c2aee618705cf3fa0ad9d81e3213d6d89d80 Mon Sep 17 00:00:00 2001 From: Thomas Sileo Date: Mon, 4 Jul 2022 19:02:30 +0200 Subject: [PATCH] Tweak templates --- app/templates/layout.html | 2 +- app/templates/login.html | 4 +-- app/templates/lookup.html | 2 +- app/templates/utils.html | 52 ++++++++++++++++++++++++++------------- 4 files changed, 39 insertions(+), 21 deletions(-) diff --git a/app/templates/layout.html b/app/templates/layout.html index 9d5efc8..8fcc18f 100644 --- a/app/templates/layout.html +++ b/app/templates/layout.html @@ -44,7 +44,7 @@ diff --git a/app/templates/login.html b/app/templates/login.html index f0ea385..22381f3 100644 --- a/app/templates/login.html +++ b/app/templates/login.html @@ -5,8 +5,8 @@
- - + +
diff --git a/app/templates/lookup.html b/app/templates/lookup.html index 5e46518..ec2d4f5 100644 --- a/app/templates/lookup.html +++ b/app/templates/lookup.html @@ -5,7 +5,7 @@

Interact with an ActivityPub object via its URL or look for a user using @user@domain.tld

- +
{% if ap_object and ap_object.ap_type == "Person" %} diff --git a/app/templates/utils.html b/app/templates/utils.html index e8dee88..ebb0f51 100644 --- a/app/templates/utils.html +++ b/app/templates/utils.html @@ -240,15 +240,29 @@ {{ display_og_meta(object) }} - -{{ object.visibility.value }} -{% if object.is_from_outbox %} -{{ object.likes_count }} likes -{% endif %} - -{% if object.is_from_outbox %} -{{ object.announces_count }} shares -{% endif %} + {{ display_attachments(object) }} @@ -257,11 +271,11 @@
Likes
{% for like in likes %} - + {{ like.actor.handle}} {% endfor %} -
And 2223 more.
+
And {{ object.likes_count - 10 }} more.
@@ -270,7 +284,7 @@
Shares
{% for share in shares %} - + {{ share.actor.handle}} {% endfor %} @@ -322,17 +336,21 @@