Add favicon

Closes: #69
This commit is contained in:
Edward Betts 2023-11-13 08:31:27 +00:00
parent 77d2fef43a
commit 3629e91d62
2 changed files with 9 additions and 0 deletions

View file

@ -7,6 +7,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Agenda</title>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
<link rel="icon" type="image/x-icon" href="{{ url_for("icon") }}">
<script type='importmap'>
{

View file

@ -53,5 +53,13 @@ async def index() -> str:
return flask.render_template("index.html", today=now.date(), **data)
@app.route("/icon/office-calendar.png")
def icon() -> flask.Response:
"""Favicon."""
return flask.send_file(
"/usr/share/icons/elementary-xfce/apps/128/office-calendar.png"
)
if __name__ == "__main__":
app.run(host="0.0.0.0")