56 lines
2.1 KiB
HTML
56 lines
2.1 KiB
HTML
<!doctype html>
|
|
<head>
|
|
<title>{{ title }}</title>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
<meta name="generator" content="Agreper - minimal, no-JS forum software">
|
|
<meta content="utf-8" http-equiv="encoding">
|
|
<link rel="shortcut icon" href="{{ url_for('static', filename='favicon.ico') }}">
|
|
<link rel=stylesheet href="{{ url_for('static', filename='theme.css') }}">
|
|
{%- if config.user_css -%}
|
|
<link rel=stylesheet href="{{ url_for('static', filename=config.user_css) }}">
|
|
{%- endif -%}
|
|
</head>
|
|
<body>
|
|
<nav>
|
|
<div class="navbar">
|
|
<div class="dropdown">
|
|
<button class="dropbtn"><img class="button_image" src={{ url_for('static', filename='button.png') }}>
|
|
</button>
|
|
<div class="dropdown-content">
|
|
<a href="{{ url_for('index') }}">Home</a>
|
|
{%- if user is not none -%}
|
|
<a href="{{ url_for('user_edit') }}">
|
|
Profile
|
|
{%- if user.is_banned() %} (banned for {{ format_until(user.banned_until) }}){% endif -%}
|
|
</a>
|
|
{%- if user.is_admin() -%}
|
|
<a href="{{ url_for('admin') }}">Admin panel</a>
|
|
{%- endif -%}
|
|
<a href="{{ url_for('logout') }}">Logout</a>
|
|
{%- else -%}
|
|
{%- if config.registration_enabled -%}
|
|
<a href="{{ url_for('register') }}">Register</a>
|
|
{%- endif -%}
|
|
<a href="{{ url_for('login') }}">Login</a>
|
|
{%- endif -%}
|
|
{%- if user is not none -%}
|
|
<a href="https://www.markdownguide.org/cheat-sheet/" target=_blank>Syntax help</a>
|
|
{%- endif -%}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</nav>
|
|
<main>
|
|
<h1>{{ title }}</h1>
|
|
{%- for category, msg in get_flashed_messages(True) -%}
|
|
{#-
|
|
FIXME ensure all flash() messages are free of XSS vectors.
|
|
In particular, check places where we flash error messages.
|
|
-#}
|
|
<p class="flash {{ category }}">{{ msg | safe }}</p>
|
|
{%- endfor -%}
|
|
{%- block content %}{% endblock -%}
|
|
<a id="end"></a>
|
|
</main>
|
|
</body>
|