From 936a8fb7014120ff469dea4722ece70c53686a38 Mon Sep 17 00:00:00 2001 From: Nico Schottelius Date: Sat, 25 Apr 2020 19:44:21 +0200 Subject: [PATCH] Make design somewhat usable --- static/css/sticky-footer-navbar.css | 37 +++++ ubookmark/settings.py | 5 +- .../ubookmark/bookmarkmodel_list.html | 148 +++++++++++++----- 3 files changed, 147 insertions(+), 43 deletions(-) create mode 100644 static/css/sticky-footer-navbar.css diff --git a/static/css/sticky-footer-navbar.css b/static/css/sticky-footer-navbar.css new file mode 100644 index 0000000..07fd56a --- /dev/null +++ b/static/css/sticky-footer-navbar.css @@ -0,0 +1,37 @@ +/* Sticky footer styles +-------------------------------------------------- */ +html { + position: relative; + min-height: 100%; +} +body { + /* Margin bottom by footer height */ + margin-bottom: 60px; +} +.footer { + position: absolute; + bottom: 0; + width: 100%; + /* Set the fixed height of the footer here */ + height: 60px; + line-height: 60px; /* Vertically center the text there */ + background-color: #f5f5f5; +} + + +/* Custom page CSS +-------------------------------------------------- */ +/* Not required for template or sticky footer method. */ + +body > .container { + padding: 60px 15px 0; +} + +.footer > .container { + padding-right: 15px; + padding-left: 15px; +} + +code { + font-size: 80%; +} diff --git a/ubookmark/settings.py b/ubookmark/settings.py index 2dddbfa..4512ecd 100644 --- a/ubookmark/settings.py +++ b/ubookmark/settings.py @@ -22,7 +22,10 @@ BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) SECRET_KEY=get_random_secret_key() -ALLOWED_HOSTS = [] +ALLOWED_HOSTS = [ "line.schottelius.org", + "ipv6-blog.place7.ungleich.ch", + "localhost:8001", + "localhost" ] # Application definition diff --git a/ubookmark/templates/ubookmark/bookmarkmodel_list.html b/ubookmark/templates/ubookmark/bookmarkmodel_list.html index 513a706..2eb5a5b 100644 --- a/ubookmark/templates/ubookmark/bookmarkmodel_list.html +++ b/ubookmark/templates/ubookmark/bookmarkmodel_list.html @@ -9,20 +9,70 @@ + {{ site_name }} powered by ubookmark -

{{ site_name }}

-
- {% autoescape off %} -

{{ site_description }}

- {% endautoescape %} + + +
+ {% autoescape off %} + {{ site_description }} + {% endautoescape %} +
-
+
    {% for bookmark in object_list %}
  • @@ -35,46 +85,60 @@ {% endfor %}
+ - {% if page_obj.has_next %} -
  • - next -
  • -
  • - last -
  • - {% else %} -
  • - next -
  • -
  • - last -
  • - {% endif %} - +