UX: remove edit PM button

UX: remove edit PM button

Edit PM button leads to confusion and is uneeded

diff --git a/app/assets/javascripts/discourse/app/initializers/topic-footer-buttons.js b/app/assets/javascripts/discourse/app/initializers/topic-footer-buttons.js
index a2de76d..121891c 100644
--- a/app/assets/javascripts/discourse/app/initializers/topic-footer-buttons.js
+++ b/app/assets/javascripts/discourse/app/initializers/topic-footer-buttons.js
@@ -7,7 +7,6 @@ const SHARE_PRIORITY = 1000;
 const BOOKMARK_PRIORITY = 900;
 const ARCHIVE_PRIORITY = 800;
 const FLAG_PRIORITY = 700;
-const EDIT_MESSAGE_PRIORITY = 600;
 const DEFER_PRIORITY = 500;
 
 export default {
@@ -167,23 +166,6 @@ export default {
     });
 
     registerTopicFooterButton({
-      id: "edit-message",
-      priority: EDIT_MESSAGE_PRIORITY,
-      icon: "pencil-alt",
-      label: "topic.edit_message.title",
-      title: "topic.edit_message.help",
-      action: "editFirstPost",
-      classNames: ["edit-message"],
-      dependentKeys: ["editFirstPost", "showEditOnFooter"],
-      dropdown() {
-        return this.site.mobileView && this.get("topic.isPrivateMessage");
-      },
-      displayed() {
-        return this.showEditOnFooter;
-      }
-    });
-
-    registerTopicFooterButton({
       id: "defer",
       icon: "circle",
       priority: DEFER_PRIORITY,
diff --git a/test/javascripts/acceptance/personal-message-test.js b/test/javascripts/acceptance/personal-message-test.js
index 4762d45..ba36782 100644
--- a/test/javascripts/acceptance/personal-message-test.js
+++ b/test/javascripts/acceptance/personal-message-test.js
@@ -24,17 +24,3 @@ QUnit.test("suggested messages", async assert => {
     I18n.t("suggested_topics.pm_title")
   );
 });
-
-acceptance("Personal Message Tagging", {
-  loggedIn: true,
-  site: { can_tag_pms: true }
-});
-
-QUnit.test("show footer edit button", async assert => {
-  await visit("/t/pm-for-testing/12");
-
-  assert.ok(
-    exists(".edit-message"),
-    "shows edit first post button on footer when PM tagging is enabled"
-  );
-});

GitHub sha: ecc8e559

1 Like