From c4317cdbf7b24a9745f2126646162d527bd50c7b Mon Sep 17 00:00:00 2001 From: czaks Date: Wed, 16 Apr 2014 13:51:18 +0200 Subject: [PATCH] hide-threads.js + containerchan integration --- js/hide-threads.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/js/hide-threads.js b/js/hide-threads.js index 750d06a2..8ed150a3 100644 --- a/js/hide-threads.js +++ b/js/hide-threads.js @@ -35,6 +35,8 @@ $(document).ready(function(){ } } } + + var fields_to_hide = 'div.post,div.video-container,video,img,p.fileinfo,a.hide-thread-link,br'; var do_hide_threads = function() { var id = $(this).children('p.intro').children('a.post_no:eq(1)').text(); @@ -52,7 +54,7 @@ $(document).ready(function(){ hidden_data[board][id] = Math.round(Date.now() / 1000); store_data(); - thread_container.find('div.post,div.video-container,img,p.fileinfo,a.hide-thread-link,br').hide(); + thread_container.find(fields_to_hide).hide(); var hidden_div = thread_container.find('div.post.op > p.intro').clone(); hidden_div.addClass('thread-hidden'); @@ -65,7 +67,7 @@ $(document).ready(function(){ .click(function() { delete hidden_data[board][id]; store_data(); - thread_container.find('div.post,div.video-container,img,p.fileinfo,a.hide-thread-link,br').show(); + thread_container.find(fields_to_hide).show(); $(this).remove(); hidden_div.remove(); });