aboutsummaryrefslogtreecommitdiff
path: root/webmentions_ssg/templates/sent.html
diff options
context:
space:
mode:
Diffstat (limited to 'webmentions_ssg/templates/sent.html')
-rw-r--r--webmentions_ssg/templates/sent.html17
1 files changed, 11 insertions, 6 deletions
diff --git a/webmentions_ssg/templates/sent.html b/webmentions_ssg/templates/sent.html
index 69a91d8..4993bef 100644
--- a/webmentions_ssg/templates/sent.html
+++ b/webmentions_ssg/templates/sent.html
@@ -21,7 +21,16 @@
</thead>
<tbody>
{% for source in sources %}
- <tr>
+ {% if source.deleted_at is none %}
+ {% set row_class = "table-success" %}
+ {% set badge_class = "text-bg-success" %}
+ {% set status_text = "Active" %}
+ {% else %}
+ {% set row_class = "table-danger" %}
+ {% set badge_class = "text-bg-danger" %}
+ {% set status_text = "Deleted" %}
+ {% endif %}
+ <tr class="{{ row_class }}">
<td class="text-nowrap">
<a href="{{ url_for('root.sent_source', identifier=source.uuid) }}">{{ source.path }}</a>
</td>
@@ -41,11 +50,7 @@
</time>
</td>
<td>
- {% if source.deleted_at is none %}
- <span class="badge text-bg-success">Active</span>
- {% else %}
- <span class="badge text-bg-danger">Deleted</span>
- {% endif %}
+ <span class="badge {{ badge_class }}">{{ status_text }}</span>
</td>
</tr>
{% endfor %}