Highlight thread watcher icon when there are unread replies and the thread watcher is hidden.

This commit is contained in:
ccd0 2015-01-11 14:47:05 -08:00
parent d189e1beed
commit 9737cb47d5
8 changed files with 10 additions and 7 deletions

View File

@ -70,7 +70,7 @@
} }
/* Thread Watcher */ /* Thread Watcher */
:root.burichan .replies-quoting-you > a { :root.burichan .replies-quoting-you > a, :root.burichan #watcher-link.disabled.replies-quoting-you {
color: #F00; color: #F00;
} }

View File

@ -70,7 +70,7 @@
} }
/* Thread Watcher */ /* Thread Watcher */
:root.futaba .replies-quoting-you > a { :root.futaba .replies-quoting-you > a, :root.futaba #watcher-link.disabled.replies-quoting-you {
color: #F00; color: #F00;
} }

View File

@ -78,7 +78,7 @@
} }
/* Thread Watcher */ /* Thread Watcher */
:root.photon .replies-quoting-you > a { :root.photon .replies-quoting-you > a, :root.photon #watcher-link.disabled.replies-quoting-you {
color: #00F !important; color: #00F !important;
} }

View File

@ -269,7 +269,7 @@ audio.controls-added {
content: "]\\00a0"; content: "]\\00a0";
} }
.dead-thread, .dead-thread,
.disabled { .disabled:not(.replies-quoting-you) {
opacity: .45; opacity: .45;
} }
#shortcuts { #shortcuts {

View File

@ -87,7 +87,7 @@
} }
/* Thread Watcher */ /* Thread Watcher */
:root.tomorrow .replies-quoting-you > a { :root.tomorrow .replies-quoting-you > a, :root.tomorrow #watcher-link.disabled.replies-quoting-you {
color: #F00 !important; color: #F00 !important;
} }

View File

@ -71,7 +71,7 @@
} }
/* Thread Watcher */ /* Thread Watcher */
:root.yotsuba-b .replies-quoting-you > a { :root.yotsuba-b .replies-quoting-you > a, :root.yotsuba-b #watcher-link.disabled.replies-quoting-you {
color: #F00; color: #F00;
} }

View File

@ -70,7 +70,7 @@
} }
/* Thread Watcher */ /* Thread Watcher */
:root.yotsuba .replies-quoting-you > a { :root.yotsuba .replies-quoting-you > a, :root.yotsuba #watcher-link.disabled.replies-quoting-you {
color: #F00; color: #F00;
} }

View File

@ -294,6 +294,8 @@ ThreadWatcher =
toggler.title = "#{helper[1]} Thread" toggler.title = "#{helper[1]} Thread"
$[helper[0]] thread.catalogView.nodes.root, 'watched' if thread.catalogView $[helper[0]] thread.catalogView.nodes.root, 'watched' if thread.catalogView
ThreadWatcher.shortcut.classList.toggle 'replies-quoting-you', !!$('.replies-quoting-you', ThreadWatcher.dialog)
for refresher in ThreadWatcher.menu.refreshers for refresher in ThreadWatcher.menu.refreshers
refresher() refresher()
@ -317,6 +319,7 @@ ThreadWatcher =
if line = $ "#watched-threads > [data-full-i-d='#{boardID}.#{threadID}']", ThreadWatcher.dialog if line = $ "#watched-threads > [data-full-i-d='#{boardID}.#{threadID}']", ThreadWatcher.dialog
newLine = ThreadWatcher.makeLine boardID, threadID, data newLine = ThreadWatcher.makeLine boardID, threadID, data
$.replace line, newLine $.replace line, newLine
ThreadWatcher.shortcut.classList.toggle 'replies-quoting-you', !!$('.replies-quoting-you', ThreadWatcher.dialog)
else else
ThreadWatcher.refresh() ThreadWatcher.refresh()