forked from mirrors/bookwyrm
21 lines
1.1 KiB
HTML
21 lines
1.1 KiB
HTML
{% load interaction %}
|
|
{% load utilities %}
|
|
{% load i18n %}
|
|
|
|
{% with status.id|uuid as uuid %}
|
|
<form name="favorite" action="/favorite/{{ status.id }}" method="POST" class="interaction fav-{{ status.id }}-{{ uuid }} {% if request.user|liked:status %}is-hidden{% endif %}" data-id="fav-{{ status.id }}-{{ uuid }}">
|
|
{% csrf_token %}
|
|
<button class="button is-small is-light is-transparent" type="submit">
|
|
<span class="icon icon-heart m-0-mobile" title="{% trans 'Like' %}">
|
|
</span>
|
|
<span class="is-sr-only-mobile">{% trans "Like" %}</span>
|
|
</button>
|
|
</form>
|
|
<form name="unfavorite" action="/unfavorite/{{ status.id }}" method="POST" class="interaction fav-{{ status.id }}-{{ uuid }} active {% if not request.user|liked:status %}is-hidden{% endif %}" data-id="fav-{{ status.id }}-{{ uuid }}">
|
|
{% csrf_token %}
|
|
<button class="button is-light is-transparent is-small" type="submit">
|
|
<span class="icon icon-heart has-text-primary m-0-mobile" title="{% trans 'Un-like' %}"></span>
|
|
<span class="is-sr-only-mobile">{% trans "Un-like" %}</span>
|
|
</button>
|
|
</form>
|
|
{% endwith %}
|