From 227bb3801b7ba58a2343c8067fd5937be1fb87aa Mon Sep 17 00:00:00 2001 From: Linnnus Date: Wed, 20 Mar 2024 18:08:39 +0100 Subject: Add initial site header --- static/global.css | 49 +++++++++++++++++++++++++++++++++++++++++++++++-- views/base.html | 13 ++++++++++++- 2 files changed, 59 insertions(+), 3 deletions(-) diff --git a/static/global.css b/static/global.css index 2c1f553..5625968 100644 --- a/static/global.css +++ b/static/global.css @@ -4,6 +4,51 @@ * No page-specific settings should go in this file. */ -html { - background-color: red; +* { + box-sizing: border-box; +} + +html, body { + padding: 0; + margin: 0; +} + +/* Sticky footer + * See: https://developer.mozilla.org/en-US/docs/Web/CSS/Layout_cookbook/Sticky_footers + */ +body { + min-height: 100vh; + display: grid; + grid-template-rows: auto 1fr auto; +} + +.navbar { + padding: 1.5rem; + background-color: #eee; + + display: flex; + flex-direction: row; + justify-content: space-between; + align-items: center; +} + +.navbar__links { + list-style: none; + padding: 0; + + display: flex; + flex-direction: row; + gap: 1.5em; +} + +.navbar__links__item { + /* remove default link styling */ + color: inherit; + text-decoration: none; +} + +footer { + text-align: center; + font-size: small; + margin: 1rem; } diff --git a/views/base.html b/views/base.html index f4f8ab5..23219d2 100644 --- a/views/base.html +++ b/views/base.html @@ -5,10 +5,21 @@ -
+
{% block content %}{% endblock %}
-- cgit v1.2.3