diff --git a/src/config.coffee b/src/config.coffee index 5ffb36240..2d38fee09 100644 --- a/src/config.coffee +++ b/src/config.coffee @@ -17,9 +17,8 @@ Config = 'Anonymize': [false, 'Make everyone Anonymous.'] 'Filter': [true, 'Self-moderation placebo.'] 'Recursive Hiding': [true, 'Hide replies of hidden posts, recursively.'] - 'Thread Hiding': [true, 'Hide entire threads.'] - 'Reply Hiding': [true, 'Hide single replies.'] - 'Hiding Buttons': [true, 'Add buttons to hide threads / replies, in addition to menu links.'] + 'Thread Hiding': [true, 'Add buttons to hide entire threads.'] + 'Reply Hiding': [true, 'Add buttons to hide single replies.'] 'Stubs': [true, 'Show stubs of hidden threads / replies.'] 'Images': 'Auto-GIF': [false, 'Animate GIF thumbnails (disabled on /gif/, /wsg/).'] @@ -30,6 +29,8 @@ Config = 'Menu': 'Menu': [true, 'Add a drop-down menu to posts.'] 'Report Link': [true, 'Add a report link to the menu.'] + 'Thread Hiding Link': [true, 'Add a link to hide entire threads.'] + 'Reply Hiding Link': [true, 'Add a link to hide single replies.'] 'Delete Link': [true, 'Add post and image deletion links to the menu.'] 'Download Link': [true, 'Add a download with original filename link to the menu. Chrome-only currently.'] 'Archive Link': [true, 'Add an archive link to the menu.'] diff --git a/src/features.coffee b/src/features.coffee index 281031c44..4752c03ae 100644 --- a/src/features.coffee +++ b/src/features.coffee @@ -975,7 +975,7 @@ Filter = ThreadHiding = init: -> - return if g.VIEW isnt 'index' or !Conf['Thread Hiding'] + return if g.VIEW isnt 'index' or !Conf['Thread Hiding'] and !Conf['Thread Hiding Link'] Misc.clearThreads "hiddenThreads.#{g.BOARD}" @getHiddenThreads() @@ -987,7 +987,7 @@ ThreadHiding = node: -> if data = ThreadHiding.hiddenThreads.threads[@] ThreadHiding.hide @, data.makeStub - return unless Conf['Hiding Buttons'] + return unless Conf['Thread Hiding'] $.prepend @OP.nodes.root, ThreadHiding.makeButton @, 'hide' getHiddenThreads: -> @@ -1015,7 +1015,7 @@ ThreadHiding = menu: init: -> - return if g.VIEW isnt 'index' or !Conf['Menu'] or !Conf['Thread Hiding'] + return if g.VIEW isnt 'index' or !Conf['Menu'] or !Conf['Thread Hiding Link'] div = $.el 'div', className: 'hide-thread-link' @@ -1117,7 +1117,7 @@ ThreadHiding = ReplyHiding = init: -> - return if g.VIEW is 'catalog' or !Conf['Reply Hiding'] + return if g.VIEW is 'catalog' or !Conf['Reply Hiding'] and !Conf['Reply Hiding Link'] Misc.clearThreads "hiddenPosts.#{g.BOARD}" @getHiddenPosts() @@ -1134,7 +1134,7 @@ ReplyHiding = else Recursive.apply ReplyHiding.hide, @, data.makeStub, true Recursive.add ReplyHiding.hide, @, data.makeStub, true - return unless Conf['Hiding Buttons'] + return unless Conf['Reply Hiding'] $.replace $('.sideArrows', @nodes.root), ReplyHiding.makeButton @, 'hide' getHiddenPosts: -> @@ -1142,7 +1142,7 @@ ReplyHiding = menu: init: -> - return if g.VIEW is 'catalog' or !Conf['Menu'] or !Conf['Reply Hiding'] + return if g.VIEW is 'catalog' or !Conf['Menu'] or !Conf['Reply Hiding Link'] # Hide div = $.el 'div', @@ -1352,7 +1352,7 @@ Recursive = QuoteStrikeThrough = init: -> - return if g.VIEW is 'catalog' or !Conf['Reply Hiding'] and !Conf['Filter'] + return if g.VIEW is 'catalog' or !Conf['Reply Hiding'] and !Conf['Reply Hiding Link'] and !Conf['Filter'] Post::callbacks.push name: 'Strike-through Quotes'