mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2025-06-05 07:18:48 +00:00
Remove duplicated notifications request from layout.html
This commit is contained in:
parent
3c52426a1c
commit
6ea2513790
1 changed files with 2 additions and 4 deletions
|
@ -25,6 +25,7 @@
|
||||||
{% block body %}
|
{% block body %}
|
||||||
<nav class="navbar" aria-label="main navigation">
|
<nav class="navbar" aria-label="main navigation">
|
||||||
<div class="container">
|
<div class="container">
|
||||||
|
{% with request.user.unread_notification_count as notification_count %}
|
||||||
<div class="navbar-brand">
|
<div class="navbar-brand">
|
||||||
<a class="navbar-item" href="/">
|
<a class="navbar-item" href="/">
|
||||||
<img class="image logo" src="{% if site.logo_small %}{% get_media_prefix %}{{ site.logo_small }}{% else %}{% static "images/logo-small.png" %}{% endif %}" alt="{% blocktrans with site_name=site.name %}{{ site_name }} home page{% endblocktrans %}">
|
<img class="image logo" src="{% if site.logo_small %}{% get_media_prefix %}{{ site.logo_small }}{% else %}{% static "images/logo-small.png" %}{% endif %}" alt="{% blocktrans with site_name=site.name %}{{ site_name }} home page{% endblocktrans %}">
|
||||||
|
@ -67,7 +68,6 @@
|
||||||
>
|
>
|
||||||
<i class="icon-dots-three-vertical" aria-hidden="true"></i>
|
<i class="icon-dots-three-vertical" aria-hidden="true"></i>
|
||||||
|
|
||||||
{% with request.user.unread_notification_count as notification_count %}
|
|
||||||
<strong
|
<strong
|
||||||
class="{% if not notification_count %}is-hidden {% elif request.user.has_unread_mentions %}is-danger {% else %}is-primary {% endif %} tag is-small px-1"
|
class="{% if not notification_count %}is-hidden {% elif request.user.has_unread_mentions %}is-danger {% else %}is-primary {% endif %} tag is-small px-1"
|
||||||
data-poll-wrapper
|
data-poll-wrapper
|
||||||
|
@ -77,7 +77,6 @@
|
||||||
{{ notification_count }}
|
{{ notification_count }}
|
||||||
</strong>
|
</strong>
|
||||||
</strong>
|
</strong>
|
||||||
{% endwith %}
|
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -108,14 +107,12 @@
|
||||||
<span class="is-sr-only">{% trans "Notifications" %}</span>
|
<span class="is-sr-only">{% trans "Notifications" %}</span>
|
||||||
</span>
|
</span>
|
||||||
</span>
|
</span>
|
||||||
{% with request.user.unread_notification_count as notification_count %}
|
|
||||||
<span
|
<span
|
||||||
class="{% if not notification_count %}is-hidden {% elif request.user.has_unread_mentions %}is-danger {% endif %}tag is-medium transition-x"
|
class="{% if not notification_count %}is-hidden {% elif request.user.has_unread_mentions %}is-danger {% endif %}tag is-medium transition-x"
|
||||||
data-poll-wrapper
|
data-poll-wrapper
|
||||||
>
|
>
|
||||||
<span data-poll="notifications">{{ notification_count }}</span>
|
<span data-poll="notifications">{{ notification_count }}</span>
|
||||||
</span>
|
</span>
|
||||||
{% endwith %}
|
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
{% else %}
|
{% else %}
|
||||||
|
@ -154,6 +151,7 @@
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
{% endwith %}
|
||||||
</div>
|
</div>
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue