From 02907a768475a7043d673eb8be06f6ebc4b2de42 Mon Sep 17 00:00:00 2001 From: Halfdan Mouritzen Date: Sat, 13 Jan 2024 22:14:23 +0100 Subject: [PATCH 1/6] Minimal CSS for tables --- src/project/static/css/style.css | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/src/project/static/css/style.css b/src/project/static/css/style.css index 7a6f045..49bb56e 100644 --- a/src/project/static/css/style.css +++ b/src/project/static/css/style.css @@ -28,6 +28,7 @@ p, h1, h2, h3, h4, h5, h6 { --light : #fff; --light-dust : #f6f6f6; --dust : #f1f1f1; + --medium-dust : #dadada; --dark-dust : #bfbfbf; --fade : #878787; --twilight : #4a4a4a; @@ -61,6 +62,8 @@ h1, h2, h3, h4, h5, h6 { a { font-weight : 500; + color : var(--splash); + text-decoration : none; } body { @@ -249,6 +252,25 @@ button:hover { opacity : 1.0; } +article table { + width : 100%; + border-spacing : 0; + margin : var(--space) 0; +} + +article table thead th { + text-align : left; +} + +article table tbody tr:nth-child(odd) { + background : var(--medium-dust); +} + +article table thead th, +article table tbody td { + padding : var(--half-space); +} + form > div { margin : 0 0 var(--double-space); } -- 2.43.4 From 45467efa9ee467283b33584f039b7328f8cf1ca2 Mon Sep 17 00:00:00 2001 From: Halfdan Mouritzen Date: Mon, 15 Jan 2024 13:16:00 +0100 Subject: [PATCH 2/6] Consistency in naming in login --- src/project/templates/account/login.html | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/project/templates/account/login.html b/src/project/templates/account/login.html index cfcac05..523d32b 100644 --- a/src/project/templates/account/login.html +++ b/src/project/templates/account/login.html @@ -13,20 +13,20 @@ {% endfor %} {% endif %} -

Log in

+

Login

{% csrf_token %}
@@ -42,7 +42,7 @@ required>
- +
@@ -55,7 +55,7 @@ -- 2.43.4 From 60d0503dbf8306883cc051e4f499e9f99c3d3ba8 Mon Sep 17 00:00:00 2001 From: Halfdan Mouritzen Date: Mon, 15 Jan 2024 18:28:11 +0100 Subject: [PATCH 3/6] Colours, spacing, sizes --- src/project/static/css/style.css | 92 ++++++++++-- src/project/templates/account/email.html | 178 ++++++++++------------- 2 files changed, 155 insertions(+), 115 deletions(-) diff --git a/src/project/static/css/style.css b/src/project/static/css/style.css index 49bb56e..0adee7f 100644 --- a/src/project/static/css/style.css +++ b/src/project/static/css/style.css @@ -25,15 +25,17 @@ p, h1, h2, h3, h4, h5, h6 { /* Variables */ :root { /* Colors */ - --light : #fff; - --light-dust : #f6f6f6; - --dust : #f1f1f1; + --light : #ffffff; + --light-dust : #fefef9; + --dust : #f4f1ef; --medium-dust : #dadada; --dark-dust : #bfbfbf; --fade : #878787; --twilight : #4a4a4a; --dark : #2a2a2a; + --light-custard : #eee7d5; --custard : #f0dcac; + --dark-custard : #d4c7a9; --water : #a8f3f4; --splash : #4b3aba; @@ -53,6 +55,7 @@ p, h1, h2, h3, h4, h5, h6 { html, body { height : 100%; + font-size : 1.05em; } h1, h2, h3, h4, h5, h6 { @@ -64,6 +67,14 @@ a { font-weight : 500; color : var(--splash); text-decoration : none; + cursor : pointer; +} + +hr { + margin : var(--double-space) 0; + height : 0; + border : 0; + border-bottom : 1px solid var(--dark-custard); } body { @@ -102,7 +113,7 @@ header > a.logout:hover { } aside { - padding : var(--double-space) var(--outer-space); + padding : 0 var(--outer-space) var(--double-space) var(--outer-space); background : var(--light); } @@ -141,7 +152,7 @@ aside > div > dl > dt { nav { display : block; - border-bottom : 1px solid var(--dark-dust); + border-bottom : 1px solid var(--dark-custard); background : var(--light); } @@ -188,14 +199,14 @@ article { padding : var(--double-space) var(--outer-space); } -article > div { +article > div.content-view { background : var(--dust); padding : var(--double-space); - margin-bottom : var(--double-space); + margin-bottom : var(--space); } div.content-view > h2 { - margin : 0 0 var(--double-space) 0; + margin : 0 0 var(--space) 0; } div.services { @@ -236,16 +247,20 @@ button { color : var(--light); background : var(--splash); padding : var(--space) var(--double-space); - border-radius : 3px; - opacity : 0.9; + border-radius : var(--quarter-space); + opacity : 0.85; cursor : pointer; text-align : center; border : 0; font-weight : 600; - letter-spacing : 0.03em; text-decoration : none; } +button.small { + font-size : 0.78em; + padding : var(--half-space) var(--space); +} + div.services > div > a:hover, a.button:hover, button:hover { @@ -259,16 +274,47 @@ article table { } article table thead th { - text-align : left; + background : var(--twilight); + color : var(--medium-dust); +} + +article table thead th a { + color : var(--light); +} + +article table thead th:first-child { + border-radius : var(--half-space) 0 0 0; +} + +article table thead th:last-child { + border-radius : 0 var(--half-space) 0 0; +} + +article table tbody { + background : var(--light-dust); } article table tbody tr:nth-child(odd) { - background : var(--medium-dust); + background : var(--light-custard); } +article table tbody tr:nth-child(odd) td { + border-top : 1px solid var(--dark-custard); + border-bottom : 1px solid var(--dark-custard); +} + +article table tbody tr:last-child td { + border-bottom : var(--half-space) solid var(--twilight); +} + article table thead th, article table tbody td { - padding : var(--half-space); + padding : var(--space); + text-align : left; +} + +article table#user_email_table tbody tr td:first-child { + text-align : center; } form > div { @@ -281,7 +327,8 @@ form > div >label { } form > div > input[type="text"], -form > div > input[type="password"] { +form > div > input[type="password"], +input[type="email"] { border : 2px solid var(--twilight); border-radius : 6px; padding : 8px; @@ -289,6 +336,19 @@ form > div > input[type="password"] { width : 100%; } +form fieldset { + border : 0; + padding : 0; + margin : 0; +} + +form div.buttonHolder { +} + +form div.buttonHolder button { + display : inline-block; +} + #login { height : 100%; display : flex; @@ -380,5 +440,5 @@ span.time_remaining { } .pagination > li { - margin : 0 6px; + margin : 0 var(--half-space); } diff --git a/src/project/templates/account/email.html b/src/project/templates/account/email.html index 9010491..a1aaf53 100644 --- a/src/project/templates/account/email.html +++ b/src/project/templates/account/email.html @@ -2,114 +2,94 @@ {% load i18n %} -{% block head_title %}{% trans "E-mail Addresses" %}{% endblock %} - - +{% block head_title %}{% trans "Email Addresses" %}{% endblock %} {% block content %} +
+

{% trans "Email Addresses" %}

+

Her kan du tilføje og ændre emailadresser tilknyttet din konto.

+

{% trans 'The following email addresses are associated with your account:' %}

-
-
+
-
-
-

{% trans "E-mail Addresses" %}

-
-
+ {% if user.emailaddress_set.all %} +
-
- -
-
-

{% trans "Add E-mail" %}

-
-
-
- {% csrf_token %} - {{ form.as_p }} - -
-
-
+
+

{% trans "Add E-mail" %}

+
+
+ {% csrf_token %} + {{ form.as_p }} + +
-- 2.43.4 From a0bbc3adc03ec7e960e713387dafab050e551a73 Mon Sep 17 00:00:00 2001 From: Halfdan Mouritzen Date: Mon, 15 Jan 2024 19:21:08 +0100 Subject: [PATCH 4/6] Rearranging buttons --- src/project/static/css/style.css | 6 ++++++ src/project/templates/account/email.html | 16 ++++++++-------- 2 files changed, 14 insertions(+), 8 deletions(-) diff --git a/src/project/static/css/style.css b/src/project/static/css/style.css index 0adee7f..9436c33 100644 --- a/src/project/static/css/style.css +++ b/src/project/static/css/style.css @@ -267,6 +267,12 @@ button:hover { opacity : 1.0; } +button:disabled { + opacity : 0.6; + background : var(--twilight); + cursor : default; +} + article table { width : 100%; border-spacing : 0; diff --git a/src/project/templates/account/email.html b/src/project/templates/account/email.html index a1aaf53..1dc31e9 100644 --- a/src/project/templates/account/email.html +++ b/src/project/templates/account/email.html @@ -16,6 +16,12 @@ {% else %} @@ -77,7 +76,7 @@ {% trans "You currently do not have any e-mail address set up. You should really add an e-mail address so you can receive notifications, reset your password, etc." %}

{% endif %} - +
-- 2.43.4 From 8e7291e5bfc631459dc246ae1b89ed5bece85eba Mon Sep 17 00:00:00 2001 From: Halfdan Mouritzen Date: Thu, 18 Jan 2024 10:28:59 +0100 Subject: [PATCH 6/6] CSS : Pagination --- src/project/static/css/style.css | 42 ++++++++++++++++++++++++++++++-- 1 file changed, 40 insertions(+), 2 deletions(-) diff --git a/src/project/static/css/style.css b/src/project/static/css/style.css index 9436c33..b10458e 100644 --- a/src/project/static/css/style.css +++ b/src/project/static/css/style.css @@ -441,10 +441,48 @@ span.time_remaining { display : flex; justify-content : center; list-style : none; - padding : 0; + padding : var(--half-space) 0; margin : 0; } .pagination > li { - margin : 0 var(--half-space); + margin : 0 var(--half-space); +} + +.pagination > li:first-child { + margin-right : var(--double-space); +} + +.pagination > li:last-child { + margin-left : var(--double-space); +} + +.pagination .page-item { + border : 1px solid var(--fade); + padding : var(--quarter-space) var(--half-space); + border-radius : var(--half-space); + background : var(--light-dust); + font-size : 0.78em; +} + +.pagination .page-link { + padding : var(--half-space); + color : var(--twilight); +} + +.pagination .page-item.active { + background : var(--twilight); +} + +.pagination .page-item.active .page-link { + color : var(--light-dust); + font-weight : bold; +} + +.pagination .page-item.disabled { + opacity : 0.6; +} + +.pagination .page-item.disabled .page-link { + cursor : default; } -- 2.43.4