From c04cec6aa8ad7f3e8244db8c51a002b07f09c9a8 Mon Sep 17 00:00:00 2001 From: Lynne Date: Thu, 29 Aug 2019 15:08:11 +1000 Subject: [PATCH] created signup page --- static/style.css | 17 +++++++++++++++++ templates/front_page.html | 2 +- templates/login.html | 18 ++++++++++++++---- webui.py | 6 +++++- 4 files changed, 37 insertions(+), 6 deletions(-) diff --git a/static/style.css b/static/style.css index 9971409..34eb3ff 100644 --- a/static/style.css +++ b/static/style.css @@ -3,6 +3,8 @@ body { margin: 2.5%; background-color: #282c37; color: white; +} +* { box-sizing: border-box; } @@ -21,6 +23,9 @@ body { .large { font-size: 1.2em; } +.small { + font-size: 0.8em; +} .centred { text-align: center; } @@ -52,6 +57,7 @@ body { } input.button { font-size: 1em; + cursor: pointer; } .btn-primary { @@ -101,3 +107,14 @@ label.important { font-weight: 300; display:block; } +input { + width: 100%; + font-size: 1.2em; + line-height:1.4em; + border: 3px grey solid; + border-radius: none; + padding: 3px; +} +input:focus { + border: 3px mediumpurple solid; +} diff --git a/templates/front_page.html b/templates/front_page.html index 4ff83f3..b2b3f0d 100644 --- a/templates/front_page.html +++ b/templates/front_page.html @@ -19,7 +19,7 @@
-

Easy

+

Simple

FediBooks is easy to use. Everything from the profile picture to the accounts learned from is customisable with an intuitive web UI.

diff --git a/templates/login.html b/templates/login.html index c1cb59e..a191314 100644 --- a/templates/login.html +++ b/templates/login.html @@ -8,19 +8,29 @@
-

Log in

+

{% if signup %}Sign up{% else %}Log in{% endif %}

-
+

+ {% if signup %} +

+ FediBooks requires your email address in order to send you alerts when your bot stops working, and for password resets. +

+ {% endif %}
- + + {% if signup %} +

+ Passwords must be at least eight characters long. +

+ {% endif %}

- +
diff --git a/webui.py b/webui.py index a3e980c..a8a3d51 100644 --- a/webui.py +++ b/webui.py @@ -12,4 +12,8 @@ def welcome(): @app.route("/login") def show_login_page(): - return render_template("login.html") + return render_template("login.html", signup = False) + +@app.route("/signup") +def show_signup_page(): + return render_template("login.html", signup = True)