From 76230405930496d8d294bddf688f7d11ec180516 Mon Sep 17 00:00:00 2001 From: Mayhem Date: Sun, 26 Jan 2014 18:19:23 +0100 Subject: [PATCH] Add filter-highlight to threads on the catalog. --- css/style.css | 4 ++++ src/Filtering/Filter.coffee | 1 + src/General/Build.coffee | 2 ++ 3 files changed, 7 insertions(+) diff --git a/css/style.css b/css/style.css index 18a7a1e32..41991048a 100644 --- a/css/style.css +++ b/css/style.css @@ -420,6 +420,7 @@ a[href="javascript:;"] { .thumb { max-width: 150px; max-height: 150px; + border-radius: 2px; box-shadow: 0 0 5px rgba(0, 0, 0, .25); } .thunb.spoiler-file { @@ -648,6 +649,9 @@ a.hide-announcement { .filter-highlight > .reply { box-shadow: -5px 0 rgba(255, 0, 0, .5); } +.filter-highlight .thumb { + border: 2px solid rgba(255, 0, 0, .5); +} /* Thread & Reply Hiding */ .hide-thread-button, diff --git a/src/Filtering/Filter.coffee b/src/Filtering/Filter.coffee index eee0dfae9..f1362b48f 100644 --- a/src/Filtering/Filter.coffee +++ b/src/Filtering/Filter.coffee @@ -110,6 +110,7 @@ Filter = # Highlight $.addClass @nodes.root, result.class + @thread.highlight = result.class if !@isReply and result.top @thread.isOnTop = true diff --git a/src/General/Build.coffee b/src/General/Build.coffee index def630799..82b51686e 100644 --- a/src/General/Build.coffee +++ b/src/General/Build.coffee @@ -297,6 +297,8 @@ Build = className: 'catalog-thread' innerHTML: <%= importHTML('General/Thread-catalog-view') %> + $.addClass root, thread.highlight if thread.highlight + if thread.isSticky $.add $('.thread-icons', root), $.el 'img', src: "#{staticPath}sticky#{gifIcon}"