aboutsummaryrefslogtreecommitdiff
path: root/webmentions_ssg/templates/includes/failure_guidance.html
diff options
context:
space:
mode:
authorDennis Fink2026-11-19 19:42:41 +0100
committerDennis Fink2026-11-19 20:59:24 +0100
commit88f54d9a7699944b7d56f978e724b1c0b54dde98 (patch)
tree88ecc527903a91a6f6622ca288b278e5875aff3d /webmentions_ssg/templates/includes/failure_guidance.html
parent8ec35babe87ff8139ec23cc10b858b7481f132db (diff)
downloadwebmentions-ssg-88f54d9a7699944b7d56f978e724b1c0b54dde98.tar.gz
webmentions-ssg-88f54d9a7699944b7d56f978e724b1c0b54dde98.zip
feat(sender): add bulk resend and delivery history
Allow admins to resend all failed Webmentions globally or requeue every delivery for a source using the shared confirmation workflow. Record outgoing status history, expand sent source details, and provide human-readable guidance for current and historical delivery failures.
Diffstat (limited to 'webmentions_ssg/templates/includes/failure_guidance.html')
-rw-r--r--webmentions_ssg/templates/includes/failure_guidance.html26
1 files changed, 26 insertions, 0 deletions
diff --git a/webmentions_ssg/templates/includes/failure_guidance.html b/webmentions_ssg/templates/includes/failure_guidance.html
new file mode 100644
index 0000000..9a36d89
--- /dev/null
+++ b/webmentions_ssg/templates/includes/failure_guidance.html
@@ -0,0 +1,26 @@
+<!--
+SPDX-FileCopyrightText: 2026 Dennis Fink <me+coding@dennisfink.me>
+
+SPDX-License-Identifier: BSD-3-Clause
+-->
+
+{% macro render_failure(reason, direction="received") %}
+ {% if direction == "sent" %}
+ {% set guidance = reason | sent_failure_guidance %}
+ {% else %}
+ {% set guidance = reason | received_failure_guidance %}
+ {% endif %}
+ {% if guidance %}
+ <div class="text-break">{{ guidance.explanation }}</div>
+ {% if guidance.next_step %}
+ <div class="mt-1 text-break"><strong>Suggested next step:</strong> {{ guidance.next_step }}</div>
+ {% endif %}
+ <details class="mt-2">
+ <summary class="small text-body-secondary">Technical reason</summary>
+ <div class="small text-break text-pre-formatted">{{ reason }}</div>
+ </details>
+ {% else %}
+ <div class="text-break text-pre-formatted">{{ reason }}</div>
+ <div class="small text-body-secondary mt-1">Check the application logs for details before {{ 'resending' if direction == 'sent' else 'reverifying' }}.</div>
+ {% endif %}
+{% endmacro %}