From cbe27600ccae3a7ce200d5f97f70d0d912c7cc2a Mon Sep 17 00:00:00 2001 From: HackerNCoder Date: Wed, 18 Sep 2024 17:57:30 +0200 Subject: [PATCH] Add help and 404. Plus minor changes --- assets/css/style.css | 16 ++++++++++++++++ content/404.html/contents.lr | 3 +++ content/help/contents.lr | 25 +++++++++++++++++++++++++ templates/404.html | 8 ++++++++ templates/bib.html | 2 +- templates/nav.html | 1 + templates/page.html | 6 ++++-- 7 files changed, 58 insertions(+), 3 deletions(-) create mode 100644 content/404.html/contents.lr create mode 100644 content/help/contents.lr create mode 100644 templates/404.html diff --git a/assets/css/style.css b/assets/css/style.css index 713e188..5a4322f 100644 --- a/assets/css/style.css +++ b/assets/css/style.css @@ -24,6 +24,7 @@ a:hover { .fp { padding: 0 20px 0; + margin-top: 20px; } .epub { @@ -190,3 +191,18 @@ header nav ul li a:hover { .mx-width-1050 { max-width: 1050px; } + +.align-center { + text-align: center; +} + +.h1-404 { + font-size: 3.5rem; + margin-top: 4rem; + margin-bottom: 0; +} + +.p-404 { + font-size: 1.2rem; + margin-top: 1em; +} diff --git a/content/404.html/contents.lr b/content/404.html/contents.lr new file mode 100644 index 0000000..87ce476 --- /dev/null +++ b/content/404.html/contents.lr @@ -0,0 +1,3 @@ +_template: 404.html +--- +_model: none \ No newline at end of file diff --git a/content/help/contents.lr b/content/help/contents.lr new file mode 100644 index 0000000..d860553 --- /dev/null +++ b/content/help/contents.lr @@ -0,0 +1,25 @@ +title: Help +--- +body: + +The book titles on the home page are links to book pages! It may not be clear, since they are coloured red and don't have any underline, but having them blue with all the other links on the same line became too much. + +On each book page, there are up to 3 parts: + + - Download EPUB + - Source used to create EPUB + - Read online + +Download EPUB contains links to places where you can download the EPUB that I have created, for most of them it will just be "Comrades Library", this website. + +Source used to create EPUB, should be quite self-explanatory, it contains a link to where I got the text I used to create the EPUB from. + +Read online contains links to places where you can read the text in your web browser. This is quite useful for shorter texts, but I recommend reading on a tablet or ebook reader for longer texts. +Sometimes it will contain "Comrades Library", in which case I used Calibre to convert to HTML. +It may also contain links to Prolewiki and/or marxists.org. These two places may have slightly different texts, since we may have used different sources. If the source used to create the EPUB is either of these two, there will be no link to them under "Read online", it will instead be in "Source used to create EPUB". + +Further, a book page may contain "Length:". This is an attempt by me to categorise each text, short texts are defined as texts that could be read in one sitting, and can therefore be read online in your browser. Medium and long are whatever I feel like, of course for being at least so long that it would be better to read it through the EPUB and not online. + +  + +I added the Read online section to make this website a repository, such that one could link to a book here, and people got multiple options for how to read a book: EPUB, usually the source would be a PDF (although unfortunately not always), and online in browser. \ No newline at end of file diff --git a/templates/404.html b/templates/404.html new file mode 100644 index 0000000..cb73e14 --- /dev/null +++ b/templates/404.html @@ -0,0 +1,8 @@ +{% extends "layout.html" %} +{% block title %}404 - Not found{% endblock %} +{% block body %} +
+

404 - Not found

+

Whatever you were looking for, it doesn't exist. If you came here from a bookmark, berate Edie for breaking your bookmark

+
+{% endblock %} diff --git a/templates/bib.html b/templates/bib.html index b15e7e1..6889558 100644 --- a/templates/bib.html +++ b/templates/bib.html @@ -3,7 +3,7 @@ {% block body %}
{% if this.body %} -

{{ this.title }}

+

{{ this.title }}

{{ this.body }} {% else %}

{{ this.title }}

diff --git a/templates/nav.html b/templates/nav.html index fed38af..3292890 100644 --- a/templates/nav.html +++ b/templates/nav.html @@ -3,6 +3,7 @@ Home {% for href, title in [ ['/wishes', 'Wishes'], + ['/help', 'Help'], ] %} {{ title }} {% endfor %} diff --git a/templates/page.html b/templates/page.html index 0430577..e862df8 100644 --- a/templates/page.html +++ b/templates/page.html @@ -1,6 +1,8 @@ {% extends "layout.html" %} {% block title %}{{ this.title }}{% endblock %} {% block body %} -

{{ this.title }}

- {{ this.body }} +
+

{{ this.title }}

+ {{ this.body }} +
{% endblock %}