66 lines
1.8 KiB
HTML
66 lines
1.8 KiB
HTML
<!DOCTYPE html>{% load sass_tags compress %}
|
|
<html>
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
{% 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 %}
|
|
{% block head %}
|
|
{% endblock %}
|
|
</head>
|
|
<body>
|
|
{% block header %}
|
|
<header>
|
|
<span class="burger">[=]</span> <a href="/">{{ settings.SITENAME }}</a>
|
|
</header>
|
|
<nav class="overlay">
|
|
<header>
|
|
<span class="burger">[x]</span> <a href="/">{{ settings.SITENAME }}</a>
|
|
</header>
|
|
<div class="about">
|
|
{{ about.content | safe }}
|
|
</div>
|
|
<div class="user">
|
|
{% if request.user.is_authenticated %}
|
|
<div>You are logged in as {{ request.user.username }}</div>
|
|
<a href="/logout/">logout</a>
|
|
{% else %}
|
|
<a href="/login/">login</a>
|
|
{% endif %}
|
|
</div>
|
|
</nav>
|
|
<style>
|
|
</style>
|
|
<script>
|
|
document.querySelectorAll('.burger').forEach(burger => {
|
|
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 = ''
|
|
} else {
|
|
overlay.classList.add('active')
|
|
document.body.style.overflow = 'hidden'
|
|
}
|
|
})
|
|
})
|
|
</script>
|
|
{% endblock %}
|
|
{% block main %}
|
|
<div class="content">
|
|
{% block content %}
|
|
{% endblock %}
|
|
</div>
|
|
{% endblock %}
|
|
{% block end %}
|
|
{% endblock %}
|
|
{% block footer %}
|
|
{% endblock %}
|
|
</body>
|
|
</html>
|