mirror of
https://github.com/minetest/contentdb.git
synced 2024-12-24 23:12:25 +01:00
104 lines
2.8 KiB
HTML
104 lines
2.8 KiB
HTML
{% extends "base.html" %}
|
|
|
|
{% block title %}
|
|
{{ _("Notifications") }}
|
|
{% endblock %}
|
|
|
|
{% block content %}
|
|
{% if current_user.notifications %}
|
|
<form method="post" action="{{ url_for('notifications.clear') }}" class="float-end">
|
|
<input type="hidden" name="csrf_token" value="{{ csrf_token() }}" />
|
|
<input type="submit" class="btn btn-primary" value="Clear All" />
|
|
</form>
|
|
<a href="{{ url_for('users.email_notifications', username=current_user.username) }}" class="btn btn-secondary float-end me-3">
|
|
{{ _("Edit email notification settings") }}
|
|
</a>
|
|
{% endif %}
|
|
|
|
<h1>{{ self.title() }}</h1>
|
|
|
|
{% if current_user.notifications %}
|
|
<p>
|
|
{{ _("Newest first.") }}
|
|
</p>
|
|
{% endif %}
|
|
|
|
{% if editor_notifications %}
|
|
<h2>{{ _("Your Notifications") }}</h2>
|
|
{% endif %}
|
|
|
|
<div class="list-group mt-3">
|
|
{% for n in notifications %}
|
|
<a class="list-group-item list-group-item-action" href="{{ n.url }}">
|
|
<div class="row">
|
|
{% if n.package %}
|
|
<div class="col-sm-auto text-muted" style="min-width: 200px;">
|
|
<img
|
|
class="img-fluid"
|
|
style="max-height: 22px; max-width: 22px;"
|
|
src="{{ n.package.get_thumb_or_placeholder() }}" />
|
|
|
|
<span class="ps-2">
|
|
{{ n.package.title }}
|
|
</span>
|
|
</div>
|
|
{% endif %}
|
|
|
|
<div class="col-sm">
|
|
{{ n.title}}
|
|
</div>
|
|
|
|
<div class="col-sm-auto text-muted text-end">
|
|
<span class="pe-2">{{ n.causer.display_name }}</span>
|
|
<img
|
|
class="img-fluid user-photo img-thumbnail img-thumbnail-1"
|
|
style="max-height: 22px;"
|
|
src="{{ n.causer.get_profile_pic_url() }}" />
|
|
</div>
|
|
</div>
|
|
</a>
|
|
{% else %}
|
|
<p class="list-group-item"><i>{{ _("No notifications") }}</i></p>
|
|
{% endfor %}
|
|
</div>
|
|
|
|
{% if editor_notifications %}
|
|
<h2>{{ _("Editor/Approver Notifications") }}</h2>
|
|
|
|
<div class="list-group mt-3">
|
|
{% for n in editor_notifications %}
|
|
<a class="list-group-item list-group-item-action" href="{{ n.url }}">
|
|
<div class="row">
|
|
{% if n.package %}
|
|
<div class="col-sm-auto text-muted">
|
|
<img
|
|
class="img-fluid"
|
|
style="max-height: 22px; max-width: 22px;"
|
|
src="{{ n.package.get_thumb_or_placeholder() }}" />
|
|
|
|
<span class="ps-2">
|
|
{{ n.package.title }}
|
|
</span>
|
|
</div>
|
|
{% endif %}
|
|
|
|
<div class="col-sm">
|
|
{{ n.title}}
|
|
</div>
|
|
|
|
<div class="col-sm-auto text-muted text-end">
|
|
<span class="pe-2">{{ n.causer.display_name }}</span>
|
|
<img
|
|
class="img-fluid user-photo img-thumbnail img-thumbnail-1"
|
|
style="max-height: 22px;"
|
|
src="{{ n.causer.get_profile_pic_url() }}" />
|
|
</div>
|
|
</div>
|
|
</a>
|
|
{% else %}
|
|
<p class="list-group-item"><i>{{ _("No notifications") }}</i></p>
|
|
{% endfor %}
|
|
</div>
|
|
{% endif %}
|
|
{% endblock %}
|