diff --git a/main/_includes/footer.html b/main/_includes/footer.html index 29dbafb..e0df2fe 100644 --- a/main/_includes/footer.html +++ b/main/_includes/footer.html @@ -9,5 +9,8 @@ A blob emoji holding a heart + diff --git a/main/_includes/nav/navbar.html b/main/_includes/nav/navbar.html index 5a2cc73..8679572 100644 --- a/main/_includes/nav/navbar.html +++ b/main/_includes/nav/navbar.html @@ -19,18 +19,28 @@ - \ No newline at end of file + diff --git a/main/_layouts/default.html b/main/_layouts/default.html index 7e8e182..b7f2644 100644 --- a/main/_layouts/default.html +++ b/main/_layouts/default.html @@ -2,6 +2,14 @@ + + @@ -19,16 +27,26 @@ - + + + + + {% include nav/navbar.html %} diff --git a/main/scripts/main.js b/main/scripts/main.js deleted file mode 100644 index b981651..0000000 --- a/main/scripts/main.js +++ /dev/null @@ -1,31 +0,0 @@ -const darkCookie = localStorage.getItem("dark"); -const dark = darkCookie === null ? window.matchMedia("(prefers-color-scheme: dark)").matches : darkCookie === "true"; -if (dark) - $('head').append($("", { - rel: "stylesheet", - href: "/style/dark.css" - })); - -// redirect legacy anchors -if (/^#privacy\/?$/.test(location.hash)) - location.href = "/privacy"; -if (/^#impressum\/?$/.test(location.hash)) - location.href = "/impressum"; - -$(function () { - $('.navbar-collapse a').on('click', function () { - $('.navbar-collapse').collapse('hide'); - }); - - $('#blobheart').on('click', function () { - $('#navbar-image').attr('src', 'res/heart.jpeg'); - }); - - let mode = $('#dark-mode'); - mode.prop('checked', dark); - mode.on('click', function () { - localStorage.setItem("dark", $(this).prop('checked')); - location.hash = ""; - location.reload(); - }); -}); diff --git a/main/style/dark.css b/main/style/dark.css index e4fddcb..691449a 100644 --- a/main/style/dark.css +++ b/main/style/dark.css @@ -1,34 +1,34 @@ -body { +body.dark-mode { color: #d8d8d8; background-color: #222222; } -.jumbotron { +body.dark-mode .jumbotron { background-color: #404142; } -.list-display { +body.dark-mode .list-display { background-color: #404142; } -.card { +body.dark-mode .card { background-color: #3d3d3d !important; } -.text-muted { +body.dark-mode .text-muted { color: #979797 !important; } -.footer { +body.dark-mode .footer { background-color: #343a40; } -.title-button:link, -.title-button:visited { +body.dark-mode .title-button:link, +body.dark-mode .title-button:visited { color: white !important; } -.title-button:hover, -.title-button:active { +body.dark-mode .title-button:hover, +body.dark-mode .title-button:active { color: rgb(182, 182, 182) !important; }