diff --git a/bookwyrm/templates/ostatus/ostatus_error.html b/bookwyrm/templates/ostatus/error.html similarity index 71% rename from bookwyrm/templates/ostatus/ostatus_error.html rename to bookwyrm/templates/ostatus/error.html index de2ba988..b6e858e2 100644 --- a/bookwyrm/templates/ostatus/ostatus_error.html +++ b/bookwyrm/templates/ostatus/error.html @@ -29,10 +29,22 @@ {% elif error == 'ostatus_subscribe' %} -
+

{% blocktrans %}Something went wrong trying to follow {{ account }}{% endblocktrans %}

{% trans 'Check you have the correct username before trying again.' %}

+ {% elif error == 'is_blocked' %} +
+

{% blocktrans %}You have blocked {{ account }}{% endblocktrans %}

+
+ {% elif error == 'already_following' %} +
+

{% blocktrans %}You are already following {{ account }}{% endblocktrans %}

+
+ {% elif error == 'already_requested' %} +
+

{% blocktrans %}You have already requested to follow {{ account }}{% endblocktrans %}

+
{% endif %}
{% endblock %} diff --git a/bookwyrm/templates/ostatus/ostatus_subscribe.html b/bookwyrm/templates/ostatus/subscribe.html similarity index 86% rename from bookwyrm/templates/ostatus/ostatus_subscribe.html rename to bookwyrm/templates/ostatus/subscribe.html index 9d87d8ef..e64be602 100644 --- a/bookwyrm/templates/ostatus/ostatus_subscribe.html +++ b/bookwyrm/templates/ostatus/subscribe.html @@ -25,7 +25,7 @@ {% block content %} {% if error or not request.user.is_authenticated %} - {% include 'ostatus/ostatus_error.html' with error=error user=user account=account %} + {% include 'ostatus/error.html' with error=error user=user account=account %} {% else %}
@@ -45,13 +45,14 @@ @{{ user|username }} -
+ {% csrf_token %} +
-
+
{% if user.summary %} {{ user.summary|to_markdown|safe|truncatechars_html:120 }} {% else %} {% endif %} diff --git a/bookwyrm/templates/ostatus/success.html b/bookwyrm/templates/ostatus/success.html new file mode 100644 index 00000000..10b4409f --- /dev/null +++ b/bookwyrm/templates/ostatus/success.html @@ -0,0 +1,32 @@ +{% extends 'ostatus/template.html' %} +{% load i18n %} +{% load utilities %} + +{% block content %} + +{% endblock %}