phantasmobile/app/templates/base.html

60 lines
1.7 KiB
HTML
Raw Normal View History

2023-07-25 19:03:54 +00:00
<!DOCTYPE html>{% load sass_tags compress %}
2023-07-16 05:56:14 +00:00
<html>
<head>
2023-07-15 07:30:36 +00:00
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
2023-07-16 05:56:14 +00:00
{% compress css file site %}
<link rel="stylesheet" href="/static/css/reset.css"></link>
<link rel="stylesheet" href="{% sass_src 'css/site.scss' %}"></link>
<link rel="stylesheet" href="/static/css/style.css"></link>
<link rel="stylesheet" href="{% sass_src 'css/comments.scss' %}"></link>
{% endcompress %}
2023-07-15 07:30:36 +00:00
{% block head %}
2023-07-16 05:56:14 +00:00
{% endblock %}
</head>
<body>
{% block header %}
<header>
2023-07-25 19:03:54 +00:00
<span class="burger">[=]</span> <a href="/">{{ settings.SITENAME }}</a>
2023-07-16 05:56:14 +00:00
</header>
2023-07-25 19:03:54 +00:00
<nav class="overlay">
<a href="/about/">about</a><br>
{% if request.user.is_authenticated %}
<div>You are logged in as {{ request.user.username }}</div>
<a href="/logout/">logout</a><br>
{% else %}
<a href="/login/">login</a><br>
{% endif %}
</nav>
<style>
</style>
<script>
document.querySelector('.burger').addEventListener('click', event => {
event.preventDefault()
event.stopPropagation()
var overlay = document.querySelector('nav.overlay')
if (overlay.classList.contains('active')) {
overlay.classList.remove('active')
document.body.style.overflow = ''
document.querySelector('.burger').innerText = '[=]'
} else {
overlay.classList.add('active')
document.body.style.overflow = 'hidden'
document.querySelector('.burger').innerText = '[x]'
}
})
</script>
2023-07-15 07:30:36 +00:00
{% endblock %}
{% block main %}
<div class="content">
{% block content %}
{% endblock %}
</div>
{% endblock %}
{% block end %}
{% endblock %}
2023-07-16 05:56:14 +00:00
{% block footer %}
{% endblock %}
</body>
</html>