# HG changeset patch # User Goffi # Date 1750950231 -7200 # Node ID 44439110247fba8364ff59cadcead8f406aec0f7 # Parent f45c311710b1f0f2f47cf70810e7e70f7108c93b chat: Add a Data Policy badge: A badge with data policy score is shown in chat header. It's colored according to the score (red, yellow or green). rel 460 diff -r f45c311710b1 -r 44439110247f sat_templates/templates/bulma/chat/chat.html --- a/sat_templates/templates/bulma/chat/chat.html Sun Jun 08 17:31:38 2025 +0200 +++ b/sat_templates/templates/bulma/chat/chat.html Thu Jun 26 17:03:51 2025 +0200 @@ -49,8 +49,21 @@
-

{{target_jid}}

+

{{target_jid}}

+ {% if data_policy is defined and data_policy_score is defined %} + {# Data Policy badge #} +
+ {% set color_class = + 'success' if data_policy_score >= 8 else + 'warning' if data_policy_score >= 5 else + 'danger' %} +
+ + {{ data_policy_score }} +
+
+ {% endif %}