From eaa574b9d765b99b03991e858b2d7191ce7f6dd6 Mon Sep 17 00:00:00 2001 From: Simmo Saan Date: Sat, 30 Mar 2024 21:58:49 +0200 Subject: [PATCH 1/2] Remove bootstrap-table from archive tables --- _layouts/archive-category.liquid | 2 +- _layouts/archive-tag.liquid | 2 +- _layouts/archive-year.liquid | 2 +- assets/js/no_defer.js | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/_layouts/archive-category.liquid b/_layouts/archive-category.liquid index 31b84c1cc861..2fc5009f890e 100644 --- a/_layouts/archive-category.liquid +++ b/_layouts/archive-category.liquid @@ -7,7 +7,7 @@ layout: default

an archive of posts in this category

-
+
{% for post in page.posts %} diff --git a/_layouts/archive-tag.liquid b/_layouts/archive-tag.liquid index 22e12ad49287..81019a0bbea5 100644 --- a/_layouts/archive-tag.liquid +++ b/_layouts/archive-tag.liquid @@ -7,7 +7,7 @@ layout: default

an archive of posts with this tag

-
+
{% for post in page.posts %} diff --git a/_layouts/archive-year.liquid b/_layouts/archive-year.liquid index 467115000c91..0ce93efcf2e4 100644 --- a/_layouts/archive-year.liquid +++ b/_layouts/archive-year.liquid @@ -7,7 +7,7 @@ layout: default

an archive of posts from this year

-
+
{% for post in page.posts %} diff --git a/assets/js/no_defer.js b/assets/js/no_defer.js index a58e196374f5..f9ddd4465881 100644 --- a/assets/js/no_defer.js +++ b/assets/js/no_defer.js @@ -8,7 +8,7 @@ $(document).ready(function () { } // only select tables that are not inside an element with "news" (about page) or "card" (cv page) class - if ($(this).parents('[class*="news"]').length == 0 && $(this).parents('[class*="card"]').length == 0 && $(this).parents("code").length == 0) { + if ($(this).parents('[class*="news"]').length == 0 && $(this).parents('[class*="card"]').length == 0 && $(this).parents('[class*="archive"]').length == 0 && $(this).parents("code").length == 0) { // make table use bootstrap-table $(this).attr("data-toggle", "table"); // add some classes to make the table look better From 91eaca50dfd9f4b03921e49676b270a93637bd8e Mon Sep 17 00:00:00 2001 From: Simmo Saan Date: Wed, 3 Apr 2024 20:45:40 +0300 Subject: [PATCH 2/2] Reformat no_defer.js --- assets/js/no_defer.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/assets/js/no_defer.js b/assets/js/no_defer.js index f9ddd4465881..e639595ec3bc 100644 --- a/assets/js/no_defer.js +++ b/assets/js/no_defer.js @@ -8,7 +8,12 @@ $(document).ready(function () { } // only select tables that are not inside an element with "news" (about page) or "card" (cv page) class - if ($(this).parents('[class*="news"]').length == 0 && $(this).parents('[class*="card"]').length == 0 && $(this).parents('[class*="archive"]').length == 0 && $(this).parents("code").length == 0) { + if ( + $(this).parents('[class*="news"]').length == 0 && + $(this).parents('[class*="card"]').length == 0 && + $(this).parents('[class*="archive"]').length == 0 && + $(this).parents("code").length == 0 + ) { // make table use bootstrap-table $(this).attr("data-toggle", "table"); // add some classes to make the table look better