From 6b96032a4e3920109cbf8a62f15479b7c213984f Mon Sep 17 00:00:00 2001 From: r888888888 Date: Tue, 18 Aug 2015 15:47:31 -0700 Subject: [PATCH] fixes #2486: Blacklist indication/display across the site --- app/assets/javascripts/blacklists.js | 2 +- app/assets/stylesheets/specific/comments.css.scss | 2 +- app/assets/stylesheets/specific/posts.css.scss | 2 +- app/views/comments/index_by_post.html.erb | 3 +++ app/views/notes/index_by_post.html.erb | 2 ++ app/views/pools/gallery.html.erb | 3 +++ 6 files changed, 11 insertions(+), 3 deletions(-) diff --git a/app/assets/javascripts/blacklists.js b/app/assets/javascripts/blacklists.js index 499f5bab6..f7532ec56 100644 --- a/app/assets/javascripts/blacklists.js +++ b/app/assets/javascripts/blacklists.js @@ -130,7 +130,7 @@ } Danbooru.Blacklist.posts = function() { - return $(".post-preview, #image-container"); + return $(".post-preview, #image-container, #c-comments .post"); } Danbooru.Blacklist.post_match = function(post, entry) { diff --git a/app/assets/stylesheets/specific/comments.css.scss b/app/assets/stylesheets/specific/comments.css.scss index b71ed0657..b48570eea 100644 --- a/app/assets/stylesheets/specific/comments.css.scss +++ b/app/assets/stylesheets/specific/comments.css.scss @@ -131,7 +131,7 @@ div#c-comments { } } - div.post.blacklisted { + div.post.blacklisted.blacklisted-active { display: none; } diff --git a/app/assets/stylesheets/specific/posts.css.scss b/app/assets/stylesheets/specific/posts.css.scss index 4c6732143..3ae5b7b01 100644 --- a/app/assets/stylesheets/specific/posts.css.scss +++ b/app/assets/stylesheets/specific/posts.css.scss @@ -503,7 +503,7 @@ div#c-explore-posts { } } -div#c-explore-posts, div#c-post-appeals, div#c-post-flags, div#c-pools { +div#c-explore-posts, div#c-post-appeals, div#c-post-flags, div#c-pools, div#c-notes, div#c-comments { #blacklist-box { margin-bottom: 1em; } diff --git a/app/views/comments/index_by_post.html.erb b/app/views/comments/index_by_post.html.erb index 939498c9c..d49f4c54f 100644 --- a/app/views/comments/index_by_post.html.erb +++ b/app/views/comments/index_by_post.html.erb @@ -1,6 +1,9 @@

Comments

+ + <%= render "posts/partials/common/inline_blacklist" %> + <% if !CurrentUser.user.is_builder? %>

Before commenting, read the <%= link_to "how to comment guide", wiki_pages_path(:search => {:title => "howto:comment"}) %>.

diff --git a/app/views/notes/index_by_post.html.erb b/app/views/notes/index_by_post.html.erb index 971a3d7f3..e455c8dc4 100644 --- a/app/views/notes/index_by_post.html.erb +++ b/app/views/notes/index_by_post.html.erb @@ -2,6 +2,8 @@

Notes

+ <%= render "posts/partials/common/inline_blacklist" %> + <%= @post_set.presenter.post_previews_html(self) %> <%= numbered_paginator(@posts, false) %> diff --git a/app/views/pools/gallery.html.erb b/app/views/pools/gallery.html.erb index 7a060f89a..a2cb7c6bc 100644 --- a/app/views/pools/gallery.html.erb +++ b/app/views/pools/gallery.html.erb @@ -1,6 +1,9 @@