From b5b3de23bb53999fdb3069217116448f4605c73f Mon Sep 17 00:00:00 2001 From: SG Date: Fri, 13 Jun 2025 16:07:09 +0300 Subject: [PATCH] updates: change 'px' to 'em' for width --- templates/default.html | 39 +++++++++++++++++++-------------------- templates/index.html | 4 ++-- 2 files changed, 21 insertions(+), 22 deletions(-) diff --git a/templates/default.html b/templates/default.html index 7499e9c..8760aa4 100644 --- a/templates/default.html +++ b/templates/default.html @@ -80,7 +80,6 @@ {% block content %} {% endblock %} - - - - + + + document.getElementById("categories_toggle").onclick = function() { + categories_menu_item = document.getElementById("categories_menu"); + categories_menu_item.style.display = categories_menu_item.style.display === "none" ? "block" : "none" + }; + document.getElementById("dark_theme_toggle").onclick = function() { + html = document.documentElement; + current_color_theme = html.getAttribute('data-bs-theme'); + new_color_theme = current_color_theme === 'dark' ? 'light' : 'dark'; + html.setAttribute('data-bs-theme', new_color_theme); + localStorage.setItem('saved_color_theme', new_color_theme); + } + diff --git a/templates/index.html b/templates/index.html index 73bc328..f361ecd 100644 --- a/templates/index.html +++ b/templates/index.html @@ -8,8 +8,8 @@ {% block content %}
{% for content_item in content_items %} -
-
+
+
{% if content_item.image_file %} {{ content_item.title }}