Improved styles and accessibility

This commit is contained in:
2024-05-04 19:50:07 +01:00
parent 0645cca1e3
commit 785c8d0b9a
5 changed files with 34 additions and 18 deletions

Binary file not shown.

2
app.py
View File

@@ -189,7 +189,7 @@ def contact_post():
name = form.name.data name = form.name.data
message = form.message.data message = form.message.data
# send email # send email
mailItem = Message("PARTS Website Contact Us Message", recipients=[app.config['MAIL_DEFAULT_SENDER']]) mailItem = Message("PARTS Website Contact Us Message", recipients=[app.config['MAIL_CONTACT_PUBLIC']])
mailItem.body = f"Dear Lord Edward Middleton-Smith,\n\n{message}\n\nKind regards,\n{name}\n{email}" mailItem.body = f"Dear Lord Edward Middleton-Smith,\n\n{message}\n\nKind regards,\n{name}\n{email}"
mail.send(mailItem) mail.send(mailItem)
return "Submitted." return "Submitted."

View File

@@ -1,6 +1,5 @@
#pageBody > .card:first-of-type{ #pageBody > .card:first-of-type{
top: 0;
flex-grow: 1; flex-grow: 1;
} }
#pageBody > .card:last-of-type { #pageBody > .card:last-of-type {

View File

@@ -29,7 +29,7 @@ body {
margin: 0; margin: 0;
border: 0; border: 0;
background: linear-gradient(to bottom right, var(--c_purple), #dc2430); /* var(--c_purple_pastel); */ background: linear-gradient(to bottom right, var(--c_purple), #dc2430); /* var(--c_purple_pastel); */
height: 100%; height: 100vh;
max-height: 100%; max-height: 100%;
} }
@@ -148,21 +148,23 @@ h5 {
} }
.page-body { #pageBody {
height: 75vh !important; height: 69vh !important;
top: 15vh; padding: 1vh;
bottom: 5vh; margin: 1vh;
padding: 0; margin-left: 0;
margin: 0; margin-right: 0;
border: 0; border: 0;
align-items: center;
align-content: center; align-content: center;
justify-content: center; justify-content: flex-start;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
align-items: stretch; align-items: flex-start;
overflow-y: auto; overflow-y: auto;
overflow-x: hidden; overflow-x: hidden;
position: absolute;
width: 98vw;
} }
.page-body > * { .page-body > * {
@@ -186,8 +188,12 @@ h5 {
height: fit-content; height: fit-content;
margin-top: 1vh; margin-top: 1vh;
} }
#pageBody > .card:first-of-type{
margin-top: 0vh;
top: 0;
}
#pageBody > .card:last-of-type { #pageBody > .card:last-of-type {
margin-bottom: 1vh; /* margin-bottom: 1vh; */
} }
/* Create two unequal columns that floats next to each other * /* Create two unequal columns that floats next to each other *
/* Left column * /* Left column *
@@ -267,8 +273,8 @@ img.header-logo {
/* Add a card effect for articles */ /* Add a card effect for articles */
.card { .card {
background-color: var(--c_purple_pastel); background-color: var(--c_purple_pastel);
padding: 0; padding: 1vh;
margin: 0; margin: 1vh;
display: flex !important; display: flex !important;
flex-wrap: wrap; flex-wrap: wrap;
align-items: center; align-items: center;
@@ -320,6 +326,7 @@ img.header-logo {
margin-top: none; margin-top: none;
} }
/* Clear floats after the columns /* Clear floats after the columns
.row:after { .row:after {
content: ""; content: "";
@@ -329,11 +336,18 @@ img.header-logo {
*/ */
/* Footer */ /* Footer */
.footer { .footer {
padding: 0; padding: 1vh;
text-align: center; text-align: center;
margin: 0; margin: 0;
height: 10vh !important; height: 8vh !important;
overflow-y: auto; overflow-y: auto;
background-color: var(--c_purple_pastel);
border-top-left-radius: 2.5vh;
border-top-right-radius: 2.5vh;
position: absolute;
/* top: 2.5vh; */
bottom: 0;
width: 98vw;
} }
.footer > h4, h5 { .footer > h4, h5 {
@@ -483,6 +497,9 @@ button, .btn-submit, input[type="submit"] {
padding-bottom: 4.5px; padding-bottom: 4.5px;
} }
ul {
max-width: 90%;
}
li { li {
text-align: left; text-align: left;
font-size: 18px; font-size: 18px;

View File

@@ -195,7 +195,7 @@
[Note: publishing the test report is optional but doing so may allow you to make your accessibility statement shorter and more focused.] [Note: publishing the test report is optional but doing so may allow you to make your accessibility statement shorter and more focused.]
https://www.w3.org/WAI/eval/report-tool/#/ https://www.w3.org/WAI/eval/report-tool/#/
--> -->
<p>You can read the full accessibility test report {{ url_for('accessibility_report') }}.</p> <p>You can read the full accessibility test report {{ model.URL_HOST }}{{ url_for('accessibility_report') }}.</p>
</div> </div>
<!-- Include JavaScript --> <!-- Include JavaScript -->