From 24bde0e6f2b7d701d90a1d448009692beb35944d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nu=C5=A1a=20Puk=C5=A1i=C4=8D?= Date: Tue, 9 Dec 2025 17:18:41 +0100 Subject: [PATCH] Admin --- templates/admin/roles.html.twig | 81 +++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) diff --git a/templates/admin/roles.html.twig b/templates/admin/roles.html.twig index be17758..7127e87 100644 --- a/templates/admin/roles.html.twig +++ b/templates/admin/roles.html.twig @@ -135,4 +135,85 @@ {% endif %} + {# Muted Users Management #} +
+

Muted Users

+

Users with ROLE_MUTED are excluded from article listings (discover, latest articles).

+ + {# Add new muted user form #} +
+
+
+ +
+
+ +
+
+ Enter an npub to mute. User will be created if they don't exist. +
+ + {# List of muted users #} + {% if mutedUsers is defined and mutedUsers|length > 0 %} + + + + + + + + + + + {% for muted in mutedUsers %} + + + + + + + {% endfor %} + +
AvatarNameNpubActions
+ {% if muted.metadata.picture is defined and muted.metadata.picture %} + Avatar + {% else %} + + + + {% endif %} + + {% if muted.metadata %} + + + + {% else %} + {{ muted.npub|shortenNpub }} + {% endif %} + + {{ muted.npub|shortenNpub }} + +
+ +
+
+ {% else %} +
+ No muted users yet. Add one using the form above or with the command:
+ php bin/console user:elevate npub1... ROLE_MUTED +
+ {% endif %} +
+ {% endblock %}