2021-10-15 14:08:27 +00:00
{% extends "default.html" %}
{% block fixedMobileBarJS %}{% endblock %}
{% block pagetype %}{% endblock %}
2021-11-24 16:53:40 +00:00
{% block subHeader %}
2021-11-29 07:10:41 +00:00
< div class = "relative max-w-screen-2xl mx-auto px-4 py-4 grid grid-cols-12 rounded-t" >
< div class = "absolute top-0 left-0 w-full h-full bg-gradient-to-t from-gray-300 to-gray-200 rounded-t sub-header-shadow" > < / div >
2021-11-24 16:53:40 +00:00
< div class = "relative col-span-full flex items-center" >
< div >
2021-12-02 03:32:20 +00:00
< h1 class = "font-bold text-xl font-heading leading-normal mb-0" >
2021-11-24 16:53:40 +00:00
Inbox
< / h1 >
2021-12-03 03:48:36 +00:00
< ul class = "text-xs flex items-center space-x-3 leading-normal mb-0" >
2021-11-24 16:53:40 +00:00
< li >
2021-12-03 03:48:36 +00:00
< a class = "{{ 'font-bold text-red-600' if not '=true' in request.full_path else 'text-gray-700' }}" href = "/notifications" >
2021-11-24 16:53:40 +00:00
All
< / a >
< / li >
< li >
2021-12-03 03:49:54 +00:00
< a class = "{{ 'font-bold text-red-600' if '/notifications?posts=true' in request.full_path else 'text-gray-500' }}" href = "/notifications?posts=true" >
2021-11-24 16:53:40 +00:00
Posts
{% if v.post_notifications_count %}
< span class = "text-gray-600" > ({{v.post_notifications_count}})< / span >
{% endif %}
< / a >
< / li >
< li >
2021-12-03 03:49:54 +00:00
< a class = "{{ 'font-bold text-red-600' if '/notifications?messages=true' in request.full_path else 'text-gray-500' }}" href = "/notifications?messages=true" >
2021-11-24 16:53:40 +00:00
Messages
< / a >
< / li >
{% if v.admin_level > 1 %}
< li >
2021-12-03 03:49:54 +00:00
< a class = "{{ 'font-bold text-red-600' if '/notifications?modmail=true' in request.full_path else 'text-gray-500' }}" href = "/notifications?modmail=true" >
2021-11-24 16:53:40 +00:00
Mod Mail
< / a >
< / li >
{% endif %}
< / ul >
< / div >
< div class = "ml-auto" >
< button class = "block px-4 py-2 bg-gradient-to-t from-gray-800 to-gray-700 focus:from-gray-700 focus:to-gray-800 border border-gray-900 rounded-md text-shadow shadow-inset-t-white-10 text-sm font-bold text-gray-300 focus:text-gray-500 focus:shadow-inner focus:outline-none" onclick = "post_toast('/clear')" >
< i class = "fas fa-check-double text-gray-500 fa-sm fa-fw mr-1" > < / i >
Mark all as read
< / button >
< / div >
< / div >
< / div >
2021-10-15 14:08:27 +00:00
{% endblock %}
{% block content %}
2021-11-24 16:53:40 +00:00
< div class = "col-span-full" >
2021-10-15 14:08:27 +00:00
2021-11-24 16:53:40 +00:00
{% with comments=notifications %}
2021-10-15 14:08:27 +00:00
{% include "comments.html" %}
{% endwith %}
{% if not notifications %}
2021-11-24 16:53:40 +00:00
< div class = "flex flex-col items-center justify-center py-24 md:py-48" >
< img loading = "lazy" src = "https://c.tenor.com/NhDy-AkelhQAAAAM/marsey-drama.gif" class = "w-20 h-20 mb-4 rounded-md object-cover" >
< h2 class = "text-xl font-bold leading-normal font-heading" > No unread messages< / h2 >
< p class = "text-gray-500 text-sm" >
When someone comments or replies, it will show up here.
< / p >
2021-11-28 17:28:12 +00:00
< a href = "/notifications" class = "block mt-3 px-4 py-2 bg-gradient-to-t from-red-700 to-red-600 focus:from-red-600 focus:to-red-700 border border-gray-900 rounded-md text-shadow shadow-inset-t-white-10 text-sm font-bold text-gray-300 focus:text-gray-500 focus:shadow-inner focus:outline-none" >
2021-11-24 16:53:40 +00:00
View entire inbox
< / a >
2021-10-15 14:08:27 +00:00
< / div >
{% endif %}
< / div >
{% if notifications %}
2021-11-24 16:53:40 +00:00
< div class = "col-span-full" >
< ul class = "flex flex-wrap items-center mb-4" >
2021-10-15 14:08:27 +00:00
{% if page>1 %}
2021-11-24 16:53:40 +00:00
< li >
2021-10-15 14:08:27 +00:00
{% if "?page=" in request.full_path %}
{% set path = request.full_path.split("?page=")[0] %}
{% elif "& page=" in request.full_path %}
{% set path = request.full_path.split("& page=")[0] %}
{% else %}
{% set path = request.full_path %}
{% endif %}
{% if request.full_path == "/notifications" %}
2021-11-28 17:28:12 +00:00
< small > < a class = "block px-2 py-1 text-sm font-bold text-red-600 bg-gray-900" href = "{{path}}?page={{page-1}}" > Previous< / a > < / small >
2021-10-15 14:08:27 +00:00
{% else %}
2021-11-28 17:28:12 +00:00
< small > < a class = "block px-2 py-1 text-sm font-bold text-red-600 bg-gray-900" href = "{{path}}&page={{page-1}}" > Previous< / a > < / small >
2021-10-15 14:08:27 +00:00
{% endif %}
< / li >
{% else %}
2021-11-24 16:53:40 +00:00
< li > < span class = "block px-2 py-1 text-sm font-bold text-gray-700 bg-gray-800 disabled" > Prev< / span > < / li >
2021-10-15 14:08:27 +00:00
{% endif %}
{% if next_exists %}
2021-11-24 16:53:40 +00:00
< li >
2021-10-15 14:08:27 +00:00
{% if "?page=" in request.full_path %}
{% set path = request.full_path.split("?page=")[0] %}
{% elif "& page=" in request.full_path %}
{% set path = request.full_path.split("& page=")[0] %}
{% else %}
{% set path = request.full_path %}
{% endif %}
{% if request.full_path == "/notifications" %}
2021-11-28 17:28:12 +00:00
< small > < a class = "block px-2 py-1 text-sm font-bold text-red-600 bg-gray-900" href = "{{path}}?page={{page+1}}" > Next< / a > < / small >
2021-10-15 14:08:27 +00:00
{% else %}
2021-11-28 17:28:12 +00:00
< small > < a class = "block px-2 py-1 text-sm font-bold text-red-600 bg-gray-900" href = "{{path}}&page={{page+1}}" > Next< / a > < / small >
2021-10-15 14:08:27 +00:00
{% endif %}
< / li >
{% else %}
2021-11-24 16:53:40 +00:00
< li > < span class = "block px-2 py-1 text-sm font-bold text-gray-700 bg-gray-800 disabled" > Next< / span > < / li >
2021-10-15 14:08:27 +00:00
{% endif %}
< / ul >
2021-11-24 16:53:40 +00:00
< / div >
2021-10-15 14:08:27 +00:00
{% endif %}
2021-11-24 16:53:40 +00:00
2021-10-15 14:08:27 +00:00
{% endblock %}
{% block GIFpicker %}
2021-07-21 01:12:26 +00:00
{% endblock %}