From 77316cf4285fcd4e63dd9d7ae73017d6cce45089 Mon Sep 17 00:00:00 2001 From: m5ka Date: Mon, 25 Mar 2024 22:17:26 +0000 Subject: [PATCH] =?UTF-8?q?fix:=20=F0=9F=A4=B7=20don't=20show=20unset=20pr?= =?UTF-8?q?ofile=20fields=20on=20profile=20page?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- moku/templates/moku/profile/show.jinja | 30 +++++++++++++++----------- 1 file changed, 18 insertions(+), 12 deletions(-) diff --git a/moku/templates/moku/profile/show.jinja b/moku/templates/moku/profile/show.jinja index d8416bc..5ee2ae0 100644 --- a/moku/templates/moku/profile/show.jinja +++ b/moku/templates/moku/profile/show.jinja @@ -10,18 +10,24 @@ {% endif %}

@{{ profile.username }}

-
-
{% trans %}pronouns{% endtrans %}
-
{{ profile.pronouns or "not set" }}
-
-
-
{% trans %}location{% endtrans %}
-
{{ profile.location or "not set" }}
-
-
-
{% trans %}about me{% endtrans %}
-
{{ profile.bio or "not set" }}
-
+ {% if profile.pronouns %} +
+
{% trans %}pronouns{% endtrans %}
+
{{ profile.pronouns }}
+
+ {% endif %} + {% if profile.location %} +
+
{% trans %}location{% endtrans %}
+
{{ profile.location }}
+
+ {% endif %} + {% if profile.bio %} +
+
{% trans %}about me{% endtrans %}
+
{{ profile.bio }}
+
+ {% endif %} {% if profile.id == request.user.id %}

{% trans %}edit{% endtrans %}