From 9dd7748dd86bf35d6a3dd896c22f7e6f40245fa9 Mon Sep 17 00:00:00 2001 From: Cédric Bonhomme Date: Sat, 29 Feb 2020 10:08:23 +0100 Subject: Migrating frontend to Bootstrap 4. --- newspipe/web/static/css/customized-bootstrap.css | 37 ++++++- newspipe/web/templates/layout.html | 134 +++++------------------ newspipe/web/templates/login.html | 45 ++++---- package-lock.json | 8 +- package.json | 6 +- 5 files changed, 94 insertions(+), 136 deletions(-) diff --git a/newspipe/web/static/css/customized-bootstrap.css b/newspipe/web/static/css/customized-bootstrap.css index c385c908..f6bbcfd7 100644 --- a/newspipe/web/static/css/customized-bootstrap.css +++ b/newspipe/web/static/css/customized-bootstrap.css @@ -1,13 +1,38 @@ +html { + position: relative; + min-height: 100%; +} body { - margin-top: 50px; + /* Margin bottom by footer height */ + margin-bottom: 60px; + background-color: rgb(246, 248, 250); } -div.top { - position: relative; - top: -50px; - display: block; - height: 0; +img { + padding: 2px; } +.bg-newspipe-blue { + background-color: #205081; +} + + +/* Sticky footer */ +.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: #006FBA; +} +.footer a{ + color: #FFFFFF; +} + + + + #newspipenav { background-color: #205081; border: #205081; diff --git a/newspipe/web/templates/layout.html b/newspipe/web/templates/layout.html index afbfa928..b5eb801a 100644 --- a/newspipe/web/templates/layout.html +++ b/newspipe/web/templates/layout.html @@ -11,6 +11,7 @@ + @@ -22,112 +23,37 @@ {% block menu %} - + + + {% endblock %}
diff --git a/newspipe/web/templates/login.html b/newspipe/web/templates/login.html index d2724ac3..7ac4a35a 100644 --- a/newspipe/web/templates/login.html +++ b/newspipe/web/templates/login.html @@ -1,28 +1,35 @@ {% extends "layout.html" %} {% block content %}
-
-

{{ _('Log In') }}

-
- {{ form.hidden_tag() }} +
+
+
+
+

{{ _('Log In') }}

+ + {{ form.hidden_tag() }} -
- {{ form.nickmane(class_="form-control", placeholder=_('Your nickname')) }} -
- {% for message in form.nickmane.errors %} - - {% endfor %} +
+ {{ form.nickmane(class_="form-control", placeholder=_('Your nickname')) }} +
+ {% for message in form.nickmane.errors %} + + {% endfor %} -
- {{ form.password(class_="form-control", placeholder=_('Your Password')) }} -
- {% for message in form.password.errors %} - - {% endfor %} +
+ {{ form.password(class_="form-control", placeholder=_('Your Password')) }} +
+ {% for message in form.password.errors %} + + {% endfor %} - {{ form.submit(class_="btn btn-default") }} - + {{ form.submit(class_="btn btn-default") }} + {{ _('Sign up') }} + + +
+
+
- {{ _('Sign up') }}
{% endblock %} diff --git a/package-lock.json b/package-lock.json index 1e93907c..cbbd0aed 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,13 +1,13 @@ { "name": "newspipe", - "version": "8.0.0", + "version": "9.0.0", "lockfileVersion": 1, "requires": true, "dependencies": { "bootstrap": { - "version": "3.4.1", - "resolved": "https://registry.npmjs.org/bootstrap/-/bootstrap-3.4.1.tgz", - "integrity": "sha512-yN5oZVmRCwe5aKwzRj6736nSmKDX7pLYwsXiCj/EYmo16hODaBiT4En5btW/jhBF/seV+XMx3aYwukYC3A49DA==" + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/bootstrap/-/bootstrap-4.4.1.tgz", + "integrity": "sha512-tbx5cHubwE6e2ZG7nqM3g/FZ5PQEDMWmMGNrCUBVRPHXTJaH7CBDdsLeu3eCh3B1tzAxTnAbtmrzvWEvT2NNEA==" }, "datatables": { "version": "1.10.18", diff --git a/package.json b/package.json index 76acd92b..feccdfbe 100644 --- a/package.json +++ b/package.json @@ -4,10 +4,10 @@ "license": "AGPL-3.0", "private": true, "dependencies": { - "bootstrap": "^3.3.7", + "bootstrap": "^4.4.1", "datatables": "^1.10.18", - "datatables.net": "^1.10.12", - "datatables.net-bs": "^1.10.12", + "datatables.net": "^1.10.20", + "datatables.net-bs": "^1.10.20", "fork-awesome": "^1.1.7", "jquery": "^3.4.1", "lodash": "^4.17.15", -- cgit