default.html
HTML document, ASCII text
1<!DOCTYPE html> 2<html lang="en-GB"> 3<head> 4<title>{% block title %}{% endblock %}</title> 5<meta charset="utf-8"> 6<meta name="viewport" content="width=device-width, initial-scale=1"> 7<link rel="stylesheet" href="/static/style.css"> 8<script src="https://cdn.jsdelivr.net/npm/iconify-icon@2.1.0/dist/iconify-icon.min.js"></script> 9</head> 10<body> 11<dialog id="hamburger" class="sheet-left"> 12<nav> 13<ul> 14<li><a href="/">Home</a></li> 15<li><a href="/object/">Object list</a></li> 16<li><a href="/query-pictures">Query</a></li> 17<li><a href="/info/">Help</a></li> 18{% if session.username %} 19<li><a href="/upload">Upload</a></li> 20<li><a href="/create-gallery">New gallery</a> 21{% endif %} 22</ul> 23<ul> 24{% if session.username %} 25<li><a href="/profile/{{ session.username }}">Profile: {{ session.username }}</a></li> 26<li><a href="/logout">Log out</a></li> 27{% else %} 28<li><a href="/accounts">Accounts</a></li> 29{% endif %} 30</ul> 31</nav> 32</dialog> 33<header> 34<nav class="navbar" id="mobile-navbar"> 35<ul> 36<li id="hamburger-button"> 37<button class="button-flat button-neutral" onclick="document.getElementById('hamburger').showModal()"> 38<iconify-icon icon="ic:baseline-menu">Menu</iconify-icon> 39</button> 40</li> 41</ul> 42</nav> 43<nav class="navbar" id="desktop-navbar"> 44<ul> 45<li><a href="/">Home</a></li> 46<li><a href="/object/">Object list</a></li> 47<li><a href="/query-pictures">Query</a></li> 48<li><a href="/info/">Help</a></li> 49{% if session.username %} 50<li><a href="/upload">Upload</a></li> <li><a href="/create-gallery">New gallery</a> 51{% endif %} 52</ul> 53<ul> 54{% if session.username %} 55<li><a href="/profile/{{ session.username }}">Profile: {{ session.username }}</a></li> 56<li><a href="/logout">Log out</a></li> 57{% else %} 58<li><a href="/accounts">Accounts</a></li> 59{% endif %} 60</ul> 61</nav> 62</header> 63<main> 64{% block content %}{% endblock %} 65</main> 66{% with messages = get_flashed_messages(with_categories=true) %} 67<ol class="toast-container"> 68{% for category, message in messages %} 69<li 70style=" 71{% if category %} 72background-color: 73{% if category == 'error' %}var(--color-error) 74{% elif category == 'alert' %}var(--color-alert) 75{% elif category == 'info' %}var(--color-info) 76{% elif category == 'success' %}var(--color-success) 77{% endif %}; 78color: 79{% if category == 'error' %}var(--color-error-text) 80{% elif category == 'alert' %}var(--color-alert-text) 81{% elif category == 'info' %}var(--color-info-text) 82{% elif category == 'success' %}var(--color-success-text) 83{% endif %}; 84{% endif %}" 85> 86{% if category | split | first == "task" %} 87{{ message }} 88{% else %} 89{{ message }} 90{% endif %} 91<x-buttonbox> 92<button class="button-flat" onclick="removeToast()" style="color: inherit !important;">Close</button> 93</x-buttonbox> 94</li> 95{% endfor %} 96</ol> 97{% endwith %} 98<script src="/static/efficient-ui/dialogs.js"></script> 99<script src="/static/efficient-ui/toasts.js"></script> 100<script src="/static/ripples.js"></script> 101</body> 102</html> 103