From 86e2cd39a13b215d078d703ac758daeea6e7087b Mon Sep 17 00:00:00 2001
From: nd <git@notandy.de>
Date: Fri, 25 Sep 2020 13:31:20 +0200
Subject: [PATCH] =?UTF-8?q?add=20footer=20support=20to=20be=20used=20to=20?=
 =?UTF-8?q?add=20impressum=20and=20datenschutzerkl=C3=A4rung,=20closes=20#?=
 =?UTF-8?q?11?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 uffd/default_config.cfg  | 2 ++
 uffd/static/style.css    | 8 ++++++++
 uffd/templates/base.html | 6 ++++++
 3 files changed, 16 insertions(+)

diff --git a/uffd/default_config.cfg b/uffd/default_config.cfg
index e7e27480..b51d9c9f 100644
--- a/uffd/default_config.cfg
+++ b/uffd/default_config.cfg
@@ -29,6 +29,8 @@ ROLES_BASEROLES=['base']
 
 SQLALCHEMY_TRACK_MODIFICATIONS=False
 
+FOOTER_CONTENT='<div class="container"><span class="text-muted">Place sticky footer content here.</span></div>'
+
 # do NOT set in production
 
 #TEMPLATES_AUTO_RELOAD=True
diff --git a/uffd/static/style.css b/uffd/static/style.css
index e69de29b..8aecff42 100644
--- a/uffd/static/style.css
+++ b/uffd/static/style.css
@@ -0,0 +1,8 @@
+.footer {
+	position: absolute;
+	bottom: 0;
+	width: 100%;
+	height: 2em;
+	line-height: 2em;
+	background-color: #f5f5f5;
+}
diff --git a/uffd/templates/base.html b/uffd/templates/base.html
index f2e3dd75..815225ac 100644
--- a/uffd/templates/base.html
+++ b/uffd/templates/base.html
@@ -95,5 +95,11 @@
 			{% endblock body %}
 		</main>
 
+		<footer class="footer">
+			{% block footer %}
+			{{ config["FOOTER_CONTENT"]|safe }}
+			{% endblock footer %}
+		</footer>
+
 	</body>
 </html>
-- 
GitLab