forked from mirrors/bookwyrm
Move menu item styles to menu item
This commit is contained in:
parent
69192d4d6e
commit
544dbda4ad
3 changed files with 24 additions and 28 deletions
|
@ -7,8 +7,8 @@
|
|||
|
||||
{% block dropdown-list %}
|
||||
{% for shelf in request.user.shelf_set.all %}
|
||||
<li role="menuitem">
|
||||
<form class="dropdown-item pt-0 pb-0" name="shelve" action="/shelve/" method="post">
|
||||
<li role="menuitem" class="dropdown-item p-0">
|
||||
<form name="shelve" action="/shelve/" method="post">
|
||||
{% csrf_token %}
|
||||
<input type="hidden" name="book" value="{{ book.id }}">
|
||||
<input type="hidden" name="change-shelf-from" value="{{ current.identifier }}">
|
||||
|
@ -17,9 +17,9 @@
|
|||
</form>
|
||||
</li>
|
||||
{% endfor %}
|
||||
<li class="navbar-divider" role="presentation"></li>
|
||||
<li>
|
||||
<form class="dropdown-item pt-0 pb-0" name="shelve" action="/unshelve/" method="post">
|
||||
<li class="navbar-divider" role="separator"></li>
|
||||
<li role="menuitem" class="dropdown-item p-0">
|
||||
<form name="shelve" action="/unshelve/" method="post">
|
||||
{% csrf_token %}
|
||||
<input type="hidden" name="book" value="{{ book.id }}">
|
||||
<input type="hidden" name="shelf" value="{{ current.id }}">
|
||||
|
|
|
@ -2,8 +2,8 @@
|
|||
{% load i18n %}
|
||||
{% for shelf in shelves %}
|
||||
{% comparison_bool shelf.identifier active_shelf.shelf.identifier as is_current %}
|
||||
{% if dropdown %}<li role="menuitem">{% endif %}
|
||||
<div class="{% if dropdown %}dropdown-item pt-0 pb-0{% elif active_shelf.shelf.identifier|next_shelf != shelf.identifier %}is-hidden{% endif %}">
|
||||
{% if dropdown %}<li role="menuitem" class="dropdown-item p-0">{% endif %}
|
||||
<div class="{% if active_shelf.shelf.identifier|next_shelf != shelf.identifier %}is-hidden{% endif %}">
|
||||
{% if shelf.identifier == 'reading' %}{% if not dropdown or active_shelf.shelf.identifier|next_shelf != shelf.identifier %}
|
||||
{% trans "Start reading" as button_text %}
|
||||
{% include 'snippets/toggle/toggle_button.html' with class=class text=button_text controls_text="start-reading" controls_uid=button_uuid focus="modal-title-start-reading" disabled=is_current %}
|
||||
|
@ -30,24 +30,20 @@
|
|||
{% if dropdown %}
|
||||
|
||||
{% if readthrough and active_shelf.shelf.identifier != 'read' %}
|
||||
<li role="menuitem">
|
||||
<div class="dropdown-item pt-0 pb-0">
|
||||
{% trans "Update progress" as button_text %}
|
||||
{% include 'snippets/toggle/toggle_button.html' with class=class text=button_text controls_text="progress-update" controls_uid=button_uuid focus="modal-title-progress-update" %}
|
||||
</div>
|
||||
<li role="menuitem" class="dropdown-item p-0">
|
||||
{% trans "Update progress" as button_text %}
|
||||
{% include 'snippets/toggle/toggle_button.html' with class=class text=button_text controls_text="progress-update" controls_uid=button_uuid focus="modal-title-progress-update" %}
|
||||
</li>
|
||||
{% endif %}
|
||||
|
||||
{% if active_shelf.shelf %}
|
||||
<li role="menuitem">
|
||||
<div class="dropdown-item pt-0 pb-0">
|
||||
<form name="shelve" action="/unshelve/" method="post">
|
||||
{% csrf_token %}
|
||||
<input type="hidden" name="book" value="{{ active_shelf.book.id }}">
|
||||
<input type="hidden" name="shelf" value="{{ active_shelf.shelf.id }}">
|
||||
<button class="button is-fullwidth is-small is-danger is-light" type="submit">{% blocktrans with name=active_shelf.shelf.name %}Remove from {{ name }}{% endblocktrans %}</button>
|
||||
</form>
|
||||
</div>
|
||||
<li role="menuitem" class="dropdown-item p-0">
|
||||
<form name="shelve" action="/unshelve/" method="post">
|
||||
{% csrf_token %}
|
||||
<input type="hidden" name="book" value="{{ active_shelf.book.id }}">
|
||||
<input type="hidden" name="shelf" value="{{ active_shelf.shelf.id }}">
|
||||
<button class="button is-fullwidth is-small{% if dropdown %} is-radiusless{% endif %} is-danger is-light" type="submit">{% blocktrans with name=active_shelf.shelf.name %}Remove from {{ name }}{% endblocktrans %}</button>
|
||||
</form>
|
||||
</li>
|
||||
{% endif %}
|
||||
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
{% block dropdown-list %}
|
||||
{% if status.user == request.user %}
|
||||
{# things you can do to your own statuses #}
|
||||
<li role="menuitem">
|
||||
<form class="dropdown-item pt-0 pb-0" name="delete-{{status.id}}" action="/delete-status/{{ status.id }}" method="post">
|
||||
<li role="menuitem" class="dropdown-item p-0">
|
||||
<form name="delete-{{status.id}}" action="/delete-status/{{ status.id }}" method="post">
|
||||
{% csrf_token %}
|
||||
<button class="button is-danger is-light is-fullwidth is-small" type="submit">
|
||||
{% trans "Delete status" %}
|
||||
|
@ -20,8 +20,8 @@
|
|||
</form>
|
||||
</li>
|
||||
{% if status.status_type != 'GeneratedNote' and status.status_type != 'Rating' %}
|
||||
<li role="menuitem">
|
||||
<form class="dropdown-item pt-0 pb-0" name="delete-{{status.id}}" action="{% url 'redraft' status.id %}" method="post">
|
||||
<li role="menuitem" class="dropdown-item p-0">
|
||||
<form class="" name="delete-{{status.id}}" action="{% url 'redraft' status.id %}" method="post">
|
||||
{% csrf_token %}
|
||||
<button class="button is-danger is-light is-fullwidth is-small" type="submit">
|
||||
{% trans "Delete & re-draft" %}
|
||||
|
@ -31,13 +31,13 @@
|
|||
{% endif %}
|
||||
{% else %}
|
||||
{# things you can do to other people's statuses #}
|
||||
<li role="menuitem">
|
||||
<li role="menuitem" class="dropdown-item p-0">
|
||||
<a href="{% url 'direct-messages-user' status.user|username %}" class="button is-small is-fullwidth">{% trans "Send direct message" %}</a>
|
||||
</li>
|
||||
<li role="menuitem">
|
||||
<li role="menuitem" class="dropdown-item p-0">
|
||||
{% include 'snippets/report_button.html' with user=status.user status=status %}
|
||||
</li>
|
||||
<li role="menuitem">
|
||||
<li role="menuitem" class="dropdown-item p-0">
|
||||
{% include 'snippets/block_button.html' with user=status.user class="is-fullwidth" %}
|
||||
</li>
|
||||
{% endif %}
|
||||
|
|
Loading…
Reference in a new issue