swap reply and edit buttons

This commit is contained in:
MathMan05 committed 2026-02-12 13:40:04 -06:00
1 parent 69a77c38b2
commit 3ef6ac8061
2 files changed
+19 -15

No files matched your search

+5 -1
View File
@@ -338,9 +338,13 @@ class Member extends SnowFlake {
this.roles = [];
for (const strrole of memberjson.roles) {
const role = this.guild.roleids.get(strrole);
if (!role) continue;
if (!role) {
console.warn(strrole + " is not in ", this.guild.roleids);
continue;
}
this.roles.push(role);
}
if (!this.user.bot) {
const everyone = this.guild.roleids.get(this.guild.id);
if (everyone && this.roles.indexOf(everyone) === -1) {
+14 -14
View File
@@ -78,20 +78,6 @@ class Message extends SnowFlake {
Message.setupcmenu();
}
static setupcmenu() {
Message.contextmenu.addButton(
() => I18n.reply(),
function (this: Message) {
this.channel.setReplying(this);
},
{
icon: {
css: "svg-reply",
},
visible: function () {
return !this.ephemeral && this.channel.hasPermission("SEND_MESSAGES");
},
},
);
const editTypes = new Set([0, 19]);
Message.contextmenu.addButton(
() => I18n.message.edit(),
@@ -108,6 +94,20 @@ class Message extends SnowFlake {
},
},
);
Message.contextmenu.addButton(
() => I18n.reply(),
function (this: Message) {
this.channel.setReplying(this);
},
{
icon: {
css: "svg-reply",
},
visible: function () {
return !this.ephemeral && this.channel.hasPermission("SEND_MESSAGES");
},
},
);
Message.contextmenu.addButton(
() => I18n.message.reactionAdd(),