retvrn to /offsite (doesnt clip on my phone)

master
Aevann 2024-02-29 22:59:15 +02:00
parent 83dfe26f1e
commit 796b71288e
3 changed files with 5 additions and 5 deletions

View File

@ -909,7 +909,7 @@ class User(Base):
elif self.modaction_notifications_count > 0:
return 'modactions'
elif self.offsite_notifications_count > 0:
return 'site_mentions'
return 'offsite'
return ''
@property
@ -921,7 +921,7 @@ class User(Base):
'modmail': '#f15387',
'posts': '#0000ff',
'modactions': '#1ad80d',
'site_mentions': '#805ad5',
'offsite': '#805ad5',
}
return colors[self.notifications_do] if self.notifications_do \
else colors['']

View File

@ -268,7 +268,7 @@ def notifications_modactions(v):
@app.get("/notifications/site_mentions")
@app.get("/notifications/offsite")
@limiter.limit(DEFAULT_RATELIMIT, deduct_when=lambda response: response.status_code < 400)
@limiter.limit(DEFAULT_RATELIMIT, deduct_when=lambda response: response.status_code < 400, key_func=get_ID)
@auth_required

View File

@ -40,8 +40,8 @@
{% endif %}
{% if v.offsite_mentions != None %}
<li class="nav-item">
<a class="nav-link py-3{% if request.path == '/notifications/site_mentions' %} active{% endif %}" href="/notifications/site_mentions">
Site Mentions {% if v.offsite_notifications_count %}<span class="font-weight-bold" style="color:#805ad5">({{v.offsite_notifications_count}})</span>{% endif %}
<a class="nav-link py-3{% if request.path == '/notifications/offsite' %} active{% endif %}" href="/notifications/offsite">
Offsite {% if v.offsite_notifications_count %}<span class="font-weight-bold" style="color:#805ad5">({{v.offsite_notifications_count}})</span>{% endif %}
</a>
</li>
{% endif %}