From 1210cfe60e561e85a49131471acc38279c208449 Mon Sep 17 00:00:00 2001 From: Penar Musaraj Date: Tue, 29 Mar 2022 11:58:50 -0400 Subject: [PATCH] UX: Indicate that "Show replies" button does not work for deleted posts (#16304) --- app/assets/javascripts/discourse/app/widgets/post-menu.js | 1 + app/assets/stylesheets/common/base/topic-post.scss | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/app/assets/javascripts/discourse/app/widgets/post-menu.js b/app/assets/javascripts/discourse/app/widgets/post-menu.js index a468c69e6b6..08a5e212a60 100644 --- a/app/assets/javascripts/discourse/app/widgets/post-menu.js +++ b/app/assets/javascripts/discourse/app/widgets/post-menu.js @@ -268,6 +268,7 @@ registerButton("replies", (attrs, state, siteSettings) => { labelOptions: { count: replyCount }, label: attrs.mobileView ? "post.has_replies_count" : "post.has_replies", iconRight: !siteSettings.enable_filtered_replies_view || attrs.mobileView, + disabled: !!attrs.deleted, }; }); diff --git a/app/assets/stylesheets/common/base/topic-post.scss b/app/assets/stylesheets/common/base/topic-post.scss index a99fd749d02..51358b0cf4b 100644 --- a/app/assets/stylesheets/common/base/topic-post.scss +++ b/app/assets/stylesheets/common/base/topic-post.scss @@ -388,6 +388,10 @@ nav.post-controls { color: currentColor; } } + &[disabled]:hover { + background-color: transparent; + cursor: not-allowed; + } &.fade-out { opacity: 1; }