forked from mirrors/bookwyrm
remove_from_group button updates
- enable blocked users to be removed - make "remove" button more subtle
This commit is contained in:
parent
9d8e978686
commit
0d5c20bcde
1 changed files with 5 additions and 3 deletions
|
@ -1,16 +1,18 @@
|
||||||
{% load i18n %}
|
{% load i18n %}
|
||||||
{% load bookwyrm_group_tags %}
|
{% load bookwyrm_group_tags %}
|
||||||
{% if request.user == user or not request.user == group.user or not request.user.is_authenticated %}
|
{% if request.user == user or not request.user == group.user or not request.user.is_authenticated %}
|
||||||
{% elif user in request.user.blocks.all %}
|
|
||||||
{% include 'snippets/block_button.html' with blocks=True %}
|
|
||||||
{% else %}
|
{% else %}
|
||||||
|
{% if user in request.user.blocks.all %}
|
||||||
|
{% include 'snippets/block_button.html' with blocks=True %}
|
||||||
|
<br/>
|
||||||
|
{% endif %}
|
||||||
<div class="field{% if not minimal %} has-addons{% else %} mb-0{% endif %}">
|
<div class="field{% if not minimal %} has-addons{% else %} mb-0{% endif %}">
|
||||||
<div class="control">
|
<div class="control">
|
||||||
<form action="{% url 'remove-group-member' %}" method="POST" class="interaction add_{{ user.id }}" data-id="add_{{ user.id }}">
|
<form action="{% url 'remove-group-member' %}" method="POST" class="interaction add_{{ user.id }}" data-id="add_{{ user.id }}">
|
||||||
{% csrf_token %}
|
{% csrf_token %}
|
||||||
<input type="hidden" name="group" value="{{ group.id }}">
|
<input type="hidden" name="group" value="{{ group.id }}">
|
||||||
<input type="hidden" name="user" value="{{ user.username }}">
|
<input type="hidden" name="user" value="{{ user.username }}">
|
||||||
<button class="button is-small is-danger is-light" type="submit">
|
<button class="button is-small" type="submit">
|
||||||
{% if show_username %}
|
{% if show_username %}
|
||||||
{% blocktrans with username=user.localname %}Remove @{{ username }}{% endblocktrans %}
|
{% blocktrans with username=user.localname %}Remove @{{ username }}{% endblocktrans %}
|
||||||
{% else %}
|
{% else %}
|
||||||
|
|
Loading…
Reference in a new issue