From d351bbc3f16aacaaee33098f72929158e47ad885 Mon Sep 17 00:00:00 2001 From: timurgordon Date: Fri, 25 Feb 2022 17:48:37 +0300 Subject: [PATCH] fixed blog mobile view --- css/layout.css | 4 ++++ templates/blog/blog.html | 2 +- templates/categories/single.html | 3 ++- templates/partials/blogPosts.html | 4 ++-- templates/partials/blogSidebar.html | 18 ++++++++++++++---- templates/partials/featuredBlog.html | 12 ++++++------ templates/partials/header.html | 2 -- templates/partials/postCard.html | 2 +- 8 files changed, 30 insertions(+), 17 deletions(-) diff --git a/css/layout.css b/css/layout.css index d74c4f7..81353e1 100644 --- a/css/layout.css +++ b/css/layout.css @@ -66,6 +66,10 @@ nav h4 a:active { @apply border-0 text-black font-light; } +a h2 { + @apply text-black; +} + a { @apply text-blue-600 font-semibold; } diff --git a/templates/blog/blog.html b/templates/blog/blog.html index 63162a6..7889d64 100644 --- a/templates/blog/blog.html +++ b/templates/blog/blog.html @@ -21,7 +21,7 @@ and a side nav for category and featured post navigation {% include "partials/featuredBlog.html" %} -
+
{% include "partials/blogPosts.html" %} {% include "partials/blogSidebar.html" %}
diff --git a/templates/categories/single.html b/templates/categories/single.html index c7632b1..c579447 100644 --- a/templates/categories/single.html +++ b/templates/categories/single.html @@ -4,10 +4,11 @@
-
+
{% include "partials/blogPosts.html" %} {% include "partials/blogSidebar.html" %}
{% endblock content %} + diff --git a/templates/partials/blogPosts.html b/templates/partials/blogPosts.html index 9b6d951..8c7d6cd 100644 --- a/templates/partials/blogPosts.html +++ b/templates/partials/blogPosts.html @@ -1,6 +1,6 @@ -
+

{% set path_array = current_path | split(pat="/") %} {% set taxonomy = path_array[1] %} diff --git a/templates/partials/blogSidebar.html b/templates/partials/blogSidebar.html index 66cdcfb..8001ef7 100644 --- a/templates/partials/blogSidebar.html +++ b/templates/partials/blogSidebar.html @@ -1,14 +1,24 @@ + + +
+

FILTER POSTS BY

- All + All {% set taxonomy = get_taxonomy(kind="categories") %} {% set categories = taxonomy.items %} {% for category in categories %} {% set path = category.name | slugify %} {% set fullpath = "/categories/" ~ path %} - {{category.name}} + {{category.name}} {% endfor %}
diff --git a/templates/partials/featuredBlog.html b/templates/partials/featuredBlog.html index 1874614..617537c 100644 --- a/templates/partials/featuredBlog.html +++ b/templates/partials/featuredBlog.html @@ -1,12 +1,12 @@ -
-

@@ -16,8 +16,8 @@

-
- +
+
diff --git a/templates/partials/header.html b/templates/partials/header.html index 0ee1115..92f8a06 100644 --- a/templates/partials/header.html +++ b/templates/partials/header.html @@ -64,9 +64,7 @@ window.onload = function(){ let elements = document.getElementsByTagName("button"); let buttons = [...elements] - console.log("logg:", buttons) buttons.forEach((button) => { - console.log("logg:", button) button.addEventListener( 'click', function() { handleClick(button) }); }) diff --git a/templates/partials/postCard.html b/templates/partials/postCard.html index b881131..1ca7645 100644 --- a/templates/partials/postCard.html +++ b/templates/partials/postCard.html @@ -1,6 +1,6 @@
- +