Skip to content

Commit 1f358bc

Browse files
author
Rodrigo Techera
committed
adding functionality to display and hide posts module by tags
1 parent d5f90c9 commit 1f358bc

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

_includes/blog_tags_filter.html

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,17 @@
1111

1212
jQuery('.blog-tag-container').fadeOut('fast', function () {
1313
jQuery('.blog-posts-nav').fadeIn('fast');
14+
jQuery('ul.pagination').fadeIn('fast');
1415
});
1516
} else {
1617
jQuery(this).addClass("selected");
1718

19+
let this_obj = this;
1820
jQuery('.blog-tag-container div[data-tag="'+jQuery(this).data("tag")+'"]').siblings().fadeOut('fast', function () {
19-
jQuery(this).fadeIn('fast');
21+
jQuery('.blog-tag-container div[data-tag="'+jQuery(this_obj).data("tag")+'"]').fadeIn('fast');
2022
});
2123

22-
jQuery('.blog-posts-nav').fadeOut('fast', function () {
24+
jQuery('.blog-posts-nav, ul.pagination').fadeOut('fast', function () {
2325
jQuery('.blog-tag-container').fadeIn('fast');
2426
});
2527
}

0 commit comments

Comments
 (0)