diff --git a/src/equicordplugins/atSomeone/index.ts b/src/equicordplugins/atSomeone/index.ts
index 0dd315aa..94e1ced5 100644
--- a/src/equicordplugins/atSomeone/index.ts
+++ b/src/equicordplugins/atSomeone/index.ts
@@ -4,7 +4,7 @@
* SPDX-License-Identifier: GPL-3.0-or-later
*/
-import { addPreSendListener, removePreSendListener } from "@api/MessageEvents";
+import { addMessagePreSendListener, removeMessagePreSendListener } from "@api/MessageEvents";
import { migratePluginSettings } from "@api/Settings";
import { Devs } from "@utils/constants";
import definePlugin from "@utils/types";
@@ -34,13 +34,13 @@ export default definePlugin({
}
],
start() {
- this.preSend = addPreSendListener((_, msg) => {
+ this.preSend = addMessagePreSendListener((_, msg) => {
msg.content = msg.content.replace(/@someone/g, () => `<@${randomUser()}>`);
});
},
stop() {
- removePreSendListener(this.preSend);
+ removeMessagePreSendListener(this.preSend);
}
});
diff --git a/src/equicordplugins/baseDecoder/index.tsx b/src/equicordplugins/baseDecoder/index.tsx
index e20c46b6..9199137e 100644
--- a/src/equicordplugins/baseDecoder/index.tsx
+++ b/src/equicordplugins/baseDecoder/index.tsx
@@ -16,7 +16,7 @@
* along with this program. If not, see .
*/
-import { addButton, removeButton } from "@api/MessagePopover";
+import { addMessagePopoverButton, removeMessagePopoverButton } from "@api/MessagePopover";
import { definePluginSettings } from "@api/Settings";
import { CodeBlock } from "@components/CodeBlock";
import ErrorBoundary from "@components/ErrorBoundary";
@@ -116,7 +116,7 @@ export default definePlugin({
},
start() {
- addButton("DecodeBase64", msg => {
+ addMessagePopoverButton("DecodeBase64", msg => {
const handleClick = () => {
const base64Strings = findBase64Strings(msg.content);
const decodedContent = decodeBase64Strings(base64Strings);
@@ -157,6 +157,6 @@ export default definePlugin({
},
stop() {
- removeButton("DecodeBase64");
+ removeMessagePopoverButton("DecodeBase64");
}
});
diff --git a/src/equicordplugins/dontFilterMe/index.tsx b/src/equicordplugins/dontFilterMe/index.tsx
index 203bce61..9b8523ff 100644
--- a/src/equicordplugins/dontFilterMe/index.tsx
+++ b/src/equicordplugins/dontFilterMe/index.tsx
@@ -4,7 +4,7 @@
* SPDX-License-Identifier: GPL-3.0-or-later
*/
-import { addPreSendListener } from "@api/MessageEvents";
+import { addMessagePreSendListener } from "@api/MessageEvents";
import { Devs } from "@utils/constants";
import definePlugin from "@utils/types";
import { Alerts, ChannelStore, Forms } from "@webpack/common";
@@ -41,7 +41,7 @@ export default definePlugin({
authors: [Devs.Samwich],
dependencies: ["MessageEventsAPI"],
start() {
- this.preSend = addPreSendListener(async (channelId, messageObj, extra) => {
+ this.preSend = addMessagePreSendListener(async (channelId, messageObj, extra) => {
if (ChannelStore.getChannel(channelId.toString()).isDM()) return { cancel: false };
diff --git a/src/equicordplugins/encryptcord/index.tsx b/src/equicordplugins/encryptcord/index.tsx
index 49d37500..53177b3a 100644
--- a/src/equicordplugins/encryptcord/index.tsx
+++ b/src/equicordplugins/encryptcord/index.tsx
@@ -11,7 +11,7 @@ import {
sendBotMessage,
} from "@api/Commands";
import * as DataStore from "@api/DataStore";
-import { addPreSendListener, removePreSendListener, SendListener } from "@api/MessageEvents";
+import { addMessagePreSendListener, removeMessagePreSendListener, SendListener } from "@api/MessageEvents";
import { Devs } from "@utils/constants";
import { sleep } from "@utils/misc";
import definePlugin from "@utils/types";
@@ -72,8 +72,8 @@ const ChatBarIcon: ChatBarButton = ({ isMainChat }) => {
}
};
- addPreSendListener(listener);
- return () => void removePreSendListener(listener);
+ addMessagePreSendListener(listener);
+ return () => void removeMessagePreSendListener(listener);
}, [enabled]);
if (!isMainChat) return null;
diff --git a/src/equicordplugins/findReply/index.tsx b/src/equicordplugins/findReply/index.tsx
index c4afc593..8f7e88c4 100644
--- a/src/equicordplugins/findReply/index.tsx
+++ b/src/equicordplugins/findReply/index.tsx
@@ -16,7 +16,7 @@
* along with this program. If not, see .
*/
-import { addButton, removeButton } from "@api/MessagePopover";
+import { addMessagePopoverButton, removeMessagePopoverButton } from "@api/MessagePopover";
import { disableStyle, enableStyle } from "@api/Styles";
import { Devs } from "@utils/constants";
import definePlugin, { OptionType } from "@utils/types";
@@ -72,7 +72,7 @@ export default definePlugin({
authors: [Devs.newwares],
start() {
enableStyle(styles);
- addButton("vc-findreply", message => {
+ addMessagePopoverButton("vc-findreply", message => {
if (!message.id) return null;
const replies = findReplies(message);
if (Vencord.Settings.plugins.FindReply.hideButtonIfNoReply && !replies.length) return null;
@@ -117,7 +117,7 @@ export default definePlugin({
});
},
stop() {
- removeButton("vc-findreply");
+ removeMessagePopoverButton("vc-findreply");
root && root.unmount();
element?.remove();
disableStyle(styles);
diff --git a/src/equicordplugins/friendshipRanks/index.tsx b/src/equicordplugins/friendshipRanks/index.tsx
index 40d72fdc..24479f7e 100644
--- a/src/equicordplugins/friendshipRanks/index.tsx
+++ b/src/equicordplugins/friendshipRanks/index.tsx
@@ -148,10 +148,10 @@ export default definePlugin({
description: "Adds badges showcasing how long you have been friends with a user for",
authors: [Devs.Samwich],
start() {
- getBadgesToApply().forEach(thing => Vencord.Api.Badges.addBadge(thing));
+ getBadgesToApply().forEach(thing => Vencord.Api.Badges.addProfileBadge(thing));
},
stop() {
- getBadgesToApply().forEach(thing => Vencord.Api.Badges.removeBadge(thing));
+ getBadgesToApply().forEach(thing => Vencord.Api.Badges.removeProfileBadge(thing));
},
});
diff --git a/src/equicordplugins/furudoSpeak.dev/index.tsx b/src/equicordplugins/furudoSpeak.dev/index.tsx
index cd3a9bc6..04f4dd94 100644
--- a/src/equicordplugins/furudoSpeak.dev/index.tsx
+++ b/src/equicordplugins/furudoSpeak.dev/index.tsx
@@ -7,7 +7,7 @@
import { addChatBarButton, ChatBarButton, removeChatBarButton } from "@api/ChatButtons";
import { ApplicationCommandInputType, ApplicationCommandOptionType, findOption, sendBotMessage } from "@api/Commands";
import { findGroupChildrenByChildId, NavContextMenuPatchCallback } from "@api/ContextMenu";
-import { addPreSendListener, removePreSendListener, SendListener } from "@api/MessageEvents";
+import { addMessagePreSendListener, removeMessagePreSendListener, SendListener } from "@api/MessageEvents";
import { definePluginSettings, Settings } from "@api/Settings";
import { ErrorCard } from "@components/ErrorCard";
import { Link } from "@components/Link";
@@ -96,9 +96,9 @@ const furudosettings = definePluginSettings(
function messageSendListenerFuncs() {
if (furudosettings.store.isEnabled) {
- addPreSendListener(presendObject);
+ addMessagePreSendListener(presendObject);
} else {
- removePreSendListener(presendObject);
+ removeMessagePreSendListener(presendObject);
}
}
@@ -243,6 +243,6 @@ export default definePlugin({
stop: () => {
removeChatBarButton("FurudoSpeak");
- removePreSendListener(presendObject);
+ removeMessagePreSendListener(presendObject);
}
});
diff --git a/src/equicordplugins/globalBadges/index.tsx b/src/equicordplugins/globalBadges/index.tsx
index 38df380e..2e1c2be3 100644
--- a/src/equicordplugins/globalBadges/index.tsx
+++ b/src/equicordplugins/globalBadges/index.tsx
@@ -16,7 +16,7 @@
* along with this program. If not, see .
*/
-import { addBadge, BadgePosition, ProfileBadge, removeBadge } from "@api/Badges";
+import { addProfileBadge, BadgePosition, ProfileBadge, removeProfileBadge } from "@api/Badges";
import { classNameFactory } from "@api/Styles";
import ErrorBoundary from "@components/ErrorBoundary";
import { Devs, EquicordDevs } from "@utils/constants";
@@ -137,8 +137,8 @@ export default definePlugin({
description: "Adds global badges from other client mods",
authors: [Devs.HypedDomi, EquicordDevs.Wolfie],
- start: () => addBadge(Badge),
- stop: () => removeBadge(Badge),
+ start: () => addProfileBadge(Badge),
+ stop: () => removeProfileBadge(Badge),
options: {
showPrefix: {
diff --git a/src/equicordplugins/goodPerson/index.ts b/src/equicordplugins/goodPerson/index.ts
index 8e394b53..07416885 100644
--- a/src/equicordplugins/goodPerson/index.ts
+++ b/src/equicordplugins/goodPerson/index.ts
@@ -16,7 +16,7 @@
* along with this program. If not, see .
*/
-import { addPreSendListener, removePreSendListener } from "@api/MessageEvents";
+import { addMessagePreSendListener, removeMessagePreSendListener } from "@api/MessageEvents";
import { definePluginSettings } from "@api/Settings";
import { Devs } from "@utils/constants";
import definePlugin, { OptionType } from "@utils/types";
@@ -77,13 +77,13 @@ export default definePlugin({
}
}),
async start() {
- this.preSend = addPreSendListener((_channelId, msg) => {
+ this.preSend = addMessagePreSendListener((_channelId, msg) => {
const newContent = this.replaceBadVerbs(this.replaceBadNouns(msg.content));
msg.content = newContent;
});
},
stop() {
- removePreSendListener(this.preSend);
+ removeMessagePreSendListener(this.preSend);
},
getEnabledBadNouns() {
const thingToReturn: string[] = [];
diff --git a/src/equicordplugins/hideMessage/index.tsx b/src/equicordplugins/hideMessage/index.tsx
index 5636db38..452b4607 100644
--- a/src/equicordplugins/hideMessage/index.tsx
+++ b/src/equicordplugins/hideMessage/index.tsx
@@ -8,7 +8,7 @@ import "./styles.css";
import { NavContextMenuPatchCallback } from "@api/ContextMenu";
import { get, set } from "@api/DataStore";
-import { addAccessory, removeAccessory } from "@api/MessageAccessories";
+import { addMessageAccessory, removeMessageAccessory } from "@api/MessageAccessories";
import { definePluginSettings } from "@api/Settings";
import { classNameFactory } from "@api/Styles";
import { EquicordDevs } from "@utils/constants";
@@ -147,7 +147,7 @@ export default definePlugin({
buildCss();
}
- addAccessory("vc-hide-message", ({ message }) => {
+ addMessageAccessory("vc-hide-message", ({ message }) => {
if (hiddenMessages.has(message.id) && settings.store.showNotice) return ;
return null;
});
@@ -156,7 +156,7 @@ export default definePlugin({
async stop() {
for (const id of hiddenMessages.keys()) revealMessage(id);
- removeAccessory("vc-hide-message");
+ removeMessageAccessory("vc-hide-message");
style.remove();
hiddenMessages.clear();
diff --git a/src/equicordplugins/holyNotes/index.tsx b/src/equicordplugins/holyNotes/index.tsx
index aa2b157a..c94df68c 100644
--- a/src/equicordplugins/holyNotes/index.tsx
+++ b/src/equicordplugins/holyNotes/index.tsx
@@ -20,7 +20,7 @@ import "./style.css";
import { NavContextMenuPatchCallback } from "@api/ContextMenu";
import { DataStore } from "@api/index";
-import { addButton, removeButton } from "@api/MessagePopover";
+import { addMessagePopoverButton, removeMessagePopoverButton } from "@api/MessagePopover";
import ErrorBoundary from "@components/ErrorBoundary";
import { EquicordDevs } from "@utils/constants";
import { classes } from "@utils/misc";
@@ -114,7 +114,7 @@ export default definePlugin({
if (await DataStore.keys(HolyNoteStore).then(keys => !keys.includes("Main"))) return noteHandler.newNoteBook("Main");
if (!noteHandlerCache.has("Main")) await DataStoreToCache();
- addButton("HolyNotes", message => {
+ addMessagePopoverButton("HolyNotes", message => {
return {
label: "Save Note",
icon: NoteButtonPopover,
@@ -127,6 +127,6 @@ export default definePlugin({
},
async stop() {
- removeButton("HolyNotes");
+ removeMessagePopoverButton("HolyNotes");
}
});
diff --git a/src/equicordplugins/husk/index.tsx b/src/equicordplugins/husk/index.tsx
index 44844ca4..9307c210 100644
--- a/src/equicordplugins/husk/index.tsx
+++ b/src/equicordplugins/husk/index.tsx
@@ -18,7 +18,7 @@
* along with this program. If not, see .
*/
-import { addButton, removeButton } from "@api/MessagePopover";
+import { addMessagePopoverButton, removeMessagePopoverButton } from "@api/MessagePopover";
import { definePluginSettings } from "@api/Settings";
import { Devs } from "@utils/constants";
import { classes } from "@utils/misc";
@@ -103,7 +103,7 @@ export default definePlugin({
return id !== "" ? id : this.settings.store.emojiID;
},
async start() {
- addButton("Husk", msg => {
+ addMessagePopoverButton("Husk", msg => {
return {
label: "Husk",
icon: Husk,
@@ -121,7 +121,7 @@ export default definePlugin({
},
stop() {
- removeButton("Husk");
+ removeMessagePopoverButton("Husk");
},
});
diff --git a/src/equicordplugins/iRememberYou/index.tsx b/src/equicordplugins/iRememberYou/index.tsx
index 80111959..a3c78481 100644
--- a/src/equicordplugins/iRememberYou/index.tsx
+++ b/src/equicordplugins/iRememberYou/index.tsx
@@ -7,7 +7,7 @@
import "styles.css?managed";
import { DataStore } from "@api/index";
-import { addPreSendListener, removePreSendListener } from "@api/MessageEvents";
+import { addMessagePreSendListener, removeMessagePreSendListener } from "@api/MessageEvents";
import { Heart } from "@components/Heart";
import { EquicordDevs } from "@utils/constants";
import { openUserProfile } from "@utils/discord";
@@ -364,7 +364,7 @@ export default definePlugin({
await data.initializeUsersCollection();
data.writeGuildsOwnersToCollection();
data.writeMembersFromUserGuildsToCollection();
- data._onMessagePreSend_preSend = addPreSendListener(
+ data._onMessagePreSend_preSend = addMessagePreSendListener(
data.onMessagePreSend.bind(data)
);
data.storageAutoSaveProtocol();
@@ -385,7 +385,7 @@ export default definePlugin({
stop() {
const dataManager = this.dataManager as Data;
- removePreSendListener(dataManager._onMessagePreSend_preSend);
+ removeMessagePreSendListener(dataManager._onMessagePreSend_preSend);
clearInterval(dataManager._storageAutoSaveProtocol_interval);
},
});
diff --git a/src/equicordplugins/noBulletPoints/index.tsx b/src/equicordplugins/noBulletPoints/index.tsx
index f6930f61..7cb777b2 100644
--- a/src/equicordplugins/noBulletPoints/index.tsx
+++ b/src/equicordplugins/noBulletPoints/index.tsx
@@ -4,7 +4,7 @@
* SPDX-License-Identifier: GPL-3.0-or-later
*/
-import { addPreSendListener, removePreSendListener } from "@api/MessageEvents";
+import { addMessagePreSendListener, removeMessagePreSendListener } from "@api/MessageEvents";
import { Devs } from "@utils/constants";
import definePlugin from "@utils/types";
export default definePlugin({
@@ -13,12 +13,12 @@ export default definePlugin({
authors: [Devs.Samwich],
dependencies: ["MessageEventsAPI"],
start() {
- this.preSend = addPreSendListener((channelId, msg) => {
+ this.preSend = addMessagePreSendListener((channelId, msg) => {
msg.content = textProcessing(msg.content);
});
},
stop() {
- this.preSend = removePreSendListener((channelId, msg) => {
+ this.preSend = removeMessagePreSendListener((channelId, msg) => {
msg.content = textProcessing(msg.content);
});
},
diff --git a/src/equicordplugins/polishWording/index.ts b/src/equicordplugins/polishWording/index.ts
index 0def8042..8f08c4c4 100644
--- a/src/equicordplugins/polishWording/index.ts
+++ b/src/equicordplugins/polishWording/index.ts
@@ -5,8 +5,8 @@
*/
import {
- addPreSendListener,
- removePreSendListener,
+ addMessagePreSendListener,
+ removeMessagePreSendListener,
SendListener,
} from "@api/MessageEvents";
import {
@@ -38,10 +38,10 @@ export default definePlugin({
authors: [Devs.Samwich],
dependencies: ["MessageEventsAPI"],
start() {
- addPreSendListener(presendObject);
+ addMessagePreSendListener(presendObject);
},
stop() {
- removePreSendListener(presendObject);
+ removeMessagePreSendListener(presendObject);
},
settings,
});
diff --git a/src/equicordplugins/questionMarkReplacement/index.tsx b/src/equicordplugins/questionMarkReplacement/index.tsx
index 73ae7584..928dd549 100644
--- a/src/equicordplugins/questionMarkReplacement/index.tsx
+++ b/src/equicordplugins/questionMarkReplacement/index.tsx
@@ -4,7 +4,7 @@
* SPDX-License-Identifier: GPL-3.0-or-later
*/
-import { addPreSendListener, removePreSendListener } from "@api/MessageEvents";
+import { addMessagePreSendListener, removeMessagePreSendListener } from "@api/MessageEvents";
import { definePluginSettings } from "@api/Settings";
import { Devs } from "@utils/constants";
import definePlugin, { OptionType } from "@utils/types";
@@ -36,12 +36,12 @@ export default definePlugin({
settings,
start() {
- this.preSend = addPreSendListener((_, msg) => {
+ this.preSend = addMessagePreSendListener((_, msg) => {
msg.content = replaceQuestionMarks(msg.content);
});
},
stop() {
- removePreSendListener(this.preSend);
+ removeMessagePreSendListener(this.preSend);
}
});
diff --git a/src/equicordplugins/remixMe/index.tsx b/src/equicordplugins/remixMe/index.tsx
index 8e7b7caa..d757a272 100644
--- a/src/equicordplugins/remixMe/index.tsx
+++ b/src/equicordplugins/remixMe/index.tsx
@@ -4,7 +4,7 @@
* SPDX-License-Identifier: GPL-3.0-or-later
*/
-import { addPreSendListener, MessageExtra, MessageObject, removePreSendListener } from "@api/MessageEvents";
+import { addMessagePreSendListener, MessageExtra, MessageObject, removeMessagePreSendListener } from "@api/MessageEvents";
import { EquicordDevs } from "@utils/constants";
import definePlugin from "@utils/types";
@@ -14,6 +14,6 @@ export default definePlugin({
name: "RemixMe",
description: "Turns every single message with attachment to have remix tag",
authors: [EquicordDevs.kvba],
- start: () => addPreSendListener(handleMessage),
- stop: () => removePreSendListener(handleMessage)
+ start: () => addMessagePreSendListener(handleMessage),
+ stop: () => removeMessagePreSendListener(handleMessage)
});
diff --git a/src/equicordplugins/repeatMessage/index.tsx b/src/equicordplugins/repeatMessage/index.tsx
index a3a1983e..926d7042 100644
--- a/src/equicordplugins/repeatMessage/index.tsx
+++ b/src/equicordplugins/repeatMessage/index.tsx
@@ -17,7 +17,7 @@
*/
import { findGroupChildrenByChildId, NavContextMenuPatchCallback } from "@api/ContextMenu";
-import { addButton, removeButton } from "@api/MessagePopover";
+import { addMessagePopoverButton, removeMessagePopoverButton } from "@api/MessagePopover";
import { classNameFactory } from "@api/Styles";
import { EquicordDevs } from "@utils/constants";
import { sendMessage } from "@utils/discord";
@@ -103,7 +103,7 @@ export default definePlugin({
"message": messageCtxPatch
},
start() {
- addButton("vc-repeat", message => {
+ addMessagePopoverButton("vc-repeat", message => {
if (!message.content && message.stickerItems.length === 0) return null;
return {
@@ -119,7 +119,7 @@ export default definePlugin({
document.addEventListener("keydown", keydownListener);
},
stop() {
- removeButton("vc-repeat");
+ removeMessagePopoverButton("vc-repeat");
document.removeEventListener("keyup", keyupListener);
document.removeEventListener("keydown", keydownListener);
diff --git a/src/equicordplugins/shakeSpearean.dev/index.ts b/src/equicordplugins/shakeSpearean.dev/index.ts
index b546be82..1c06207a 100644
--- a/src/equicordplugins/shakeSpearean.dev/index.ts
+++ b/src/equicordplugins/shakeSpearean.dev/index.ts
@@ -4,7 +4,7 @@
* SPDX-License-Identifier: GPL-3.0-or-later
*/
-import { addPreSendListener, removePreSendListener, SendListener } from "@api/MessageEvents";
+import { addMessagePreSendListener, removeMessagePreSendListener, SendListener } from "@api/MessageEvents";
import { definePluginSettings, Settings } from "@api/Settings";
import { EquicordDevs } from "@utils/constants";
import definePlugin, { OptionType } from "@utils/types";
@@ -32,9 +32,9 @@ export default definePlugin({
}
}),
start() {
- addPreSendListener(presendObject);
+ addMessagePreSendListener(presendObject);
},
stop() {
- removePreSendListener(presendObject);
+ removeMessagePreSendListener(presendObject);
}
});
diff --git a/src/equicordplugins/showBadgesInChat/index.tsx b/src/equicordplugins/showBadgesInChat/index.tsx
index f1e231de..2d5de3d6 100644
--- a/src/equicordplugins/showBadgesInChat/index.tsx
+++ b/src/equicordplugins/showBadgesInChat/index.tsx
@@ -4,7 +4,7 @@
* SPDX-License-Identifier: GPL-3.0-or-later
*/
-import { addDecoration, removeDecoration } from "@api/MessageDecorations";
+import { addMessageDecoration, removeMessageDecoration } from "@api/MessageDecorations";
import { Devs, EquicordDevs } from "@utils/constants";
import { isEquicordPluginDev, isPluginDev } from "@utils/misc";
import definePlugin from "@utils/types";
@@ -145,9 +145,9 @@ export default definePlugin({
dependencies: ["MessageDecorationsAPI"],
settings,
start: () => {
- addDecoration("vc-show-badges-in-chat", props => props.message?.author ? : null);
+ addMessageDecoration("vc-show-badges-in-chat", props => props.message?.author ? : null);
},
stop: () => {
- removeDecoration("vc-show-badges-in-chat");
+ removeMessageDecoration("vc-show-badges-in-chat");
}
});
diff --git a/src/equicordplugins/signature/index.tsx b/src/equicordplugins/signature/index.tsx
index 5536ae69..8c40f41b 100644
--- a/src/equicordplugins/signature/index.tsx
+++ b/src/equicordplugins/signature/index.tsx
@@ -7,7 +7,7 @@
import { addChatBarButton, ChatBarButton, removeChatBarButton } from "@api/ChatButtons";
import { ApplicationCommandInputType, ApplicationCommandOptionType, findOption, sendBotMessage } from "@api/Commands";
import { findGroupChildrenByChildId, NavContextMenuPatchCallback } from "@api/ContextMenu";
-import { addPreSendListener, removePreSendListener } from "@api/MessageEvents";
+import { addMessagePreSendListener, removeMessagePreSendListener } from "@api/MessageEvents";
import { definePluginSettings, migratePluginSettings } from "@api/Settings";
import { EquicordDevs } from "@utils/constants";
import definePlugin, { OptionType } from "@utils/types";
@@ -104,12 +104,12 @@ export default definePlugin({
start: () => {
if (settings.store.isEnabled) true;
addChatBarButton("Signature", SignatureToggle);
- addPreSendListener(handleMessage);
+ addMessagePreSendListener(handleMessage);
},
stop: () => {
if (settings.store.isEnabled) false;
removeChatBarButton("Signature");
- removePreSendListener(handleMessage);
+ removeMessagePreSendListener(handleMessage);
},
diff --git a/src/equicordplugins/talkInReverse/index.tsx b/src/equicordplugins/talkInReverse/index.tsx
index d8871d4f..3e210d19 100644
--- a/src/equicordplugins/talkInReverse/index.tsx
+++ b/src/equicordplugins/talkInReverse/index.tsx
@@ -17,7 +17,7 @@
*/
import { addChatBarButton, ChatBarButton, removeChatBarButton } from "@api/ChatButtons";
-import { addPreSendListener, removePreSendListener, SendListener } from "@api/MessageEvents";
+import { addMessagePreSendListener, removeMessagePreSendListener, SendListener } from "@api/MessageEvents";
import { EquicordDevs } from "@utils/constants";
import definePlugin from "@utils/types";
import { React, useEffect, useState } from "@webpack/common";
@@ -38,8 +38,8 @@ const ReverseMessageToggle: ChatBarButton = ({ isMainChat }) => {
if (enabled && message.content) message.content = message.content.split("").reverse().join("");
};
- addPreSendListener(listener);
- return () => void removePreSendListener(listener);
+ addMessagePreSendListener(listener);
+ return () => void removeMessagePreSendListener(listener);
}, [enabled]);
if (!isMainChat) return null;
diff --git a/src/equicordplugins/translatePlus/index.tsx b/src/equicordplugins/translatePlus/index.tsx
index 9ec6336d..dc073e0f 100644
--- a/src/equicordplugins/translatePlus/index.tsx
+++ b/src/equicordplugins/translatePlus/index.tsx
@@ -19,8 +19,8 @@
import "./style.css";
import { findGroupChildrenByChildId, NavContextMenuPatchCallback } from "@api/ContextMenu";
-import { addAccessory, removeAccessory } from "@api/MessageAccessories";
-import { addButton, removeButton } from "@api/MessagePopover";
+import { addMessageAccessory, removeMessageAccessory } from "@api/MessageAccessories";
+import { addMessagePopoverButton, removeMessagePopoverButton } from "@api/MessagePopover";
import { Devs, EquicordDevs } from "@utils/constants";
import definePlugin from "@utils/types";
import { ChannelStore, Menu } from "@webpack/common";
@@ -56,9 +56,9 @@ export default definePlugin({
},
start() {
- addAccessory("ec-translation", props => );
+ addMessageAccessory("ec-translation", props => );
- addButton("ec-translate", message => {
+ addMessagePopoverButton("ec-translate", message => {
if (!message.content) return null;
return {
@@ -71,7 +71,7 @@ export default definePlugin({
});
},
stop() {
- removeButton("ec-translate");
- removeAccessory("ec-translation");
+ removeMessagePopoverButton("ec-translate");
+ removeMessageAccessory("ec-translation");
}
});
diff --git a/src/equicordplugins/unitConverter/index.tsx b/src/equicordplugins/unitConverter/index.tsx
index f38f7443..535f5b76 100644
--- a/src/equicordplugins/unitConverter/index.tsx
+++ b/src/equicordplugins/unitConverter/index.tsx
@@ -18,8 +18,8 @@
import "./style.css";
-import { addAccessory } from "@api/MessageAccessories";
-import { addButton } from "@api/MessagePopover";
+import { addMessageAccessory } from "@api/MessageAccessories";
+import { addMessagePopoverButton } from "@api/MessagePopover";
import { definePluginSettings } from "@api/Settings";
import { Devs } from "@utils/constants";
import definePlugin, { OptionType } from "@utils/types";
@@ -57,8 +57,8 @@ export default definePlugin({
description: "Converts metric units to Imperal units and vice versa",
authors: [Devs.sadan],
start() {
- addAccessory("vc-converter", props => );
- addButton("vc-converter", message => {
+ addMessageAccessory("vc-converter", props => );
+ addMessagePopoverButton("vc-converter", message => {
if (!message.content) return null;
return {
label: "Convert Units",
diff --git a/src/equicordplugins/uwuifier/index.ts b/src/equicordplugins/uwuifier/index.ts
index 75412d7f..4b8ffb1b 100644
--- a/src/equicordplugins/uwuifier/index.ts
+++ b/src/equicordplugins/uwuifier/index.ts
@@ -17,7 +17,7 @@
*/
import { findOption, RequiredMessageOption } from "@api/Commands";
-import { addPreEditListener, addPreSendListener, MessageObject, removePreEditListener, removePreSendListener } from "@api/MessageEvents";
+import { addMessagePreEditListener, addMessagePreSendListener, MessageObject, removeMessagePreEditListener, removeMessagePreSendListener } from "@api/MessageEvents";
import { definePluginSettings } from "@api/Settings";
import { Devs } from "@utils/constants";
import definePlugin, { OptionType } from "@utils/types";
@@ -199,14 +199,14 @@ export default definePlugin({
},
start() {
- this.preSend = addPreSendListener((_, msg) => this.onSend(msg));
- this.preEdit = addPreEditListener((_cid, _mid, msg) =>
+ this.preSend = addMessagePreSendListener((_, msg) => this.onSend(msg));
+ this.preEdit = addMessagePreEditListener((_cid, _mid, msg) =>
this.onSend(msg)
);
},
stop() {
- removePreSendListener(this.preSend);
- removePreEditListener(this.preEdit);
+ removeMessagePreSendListener(this.preSend);
+ removeMessagePreEditListener(this.preEdit);
},
});
diff --git a/src/equicordplugins/writeUpperCase/index.ts b/src/equicordplugins/writeUpperCase/index.ts
index f8101098..4a9c5b13 100644
--- a/src/equicordplugins/writeUpperCase/index.ts
+++ b/src/equicordplugins/writeUpperCase/index.ts
@@ -4,7 +4,7 @@
* SPDX-License-Identifier: GPL-3.0-or-later
*/
-import { addPreSendListener, removePreSendListener, SendListener } from "@api/MessageEvents";
+import { addMessagePreSendListener, removeMessagePreSendListener, SendListener } from "@api/MessageEvents";
import { definePluginSettings } from "@api/Settings";
import { Devs, EquicordDevs } from "@utils/constants";
import definePlugin, { OptionType } from "@utils/types";
@@ -39,9 +39,9 @@ export default definePlugin({
settings,
start() {
- addPreSendListener(presendObject);
+ addMessagePreSendListener(presendObject);
},
stop() {
- removePreSendListener(presendObject);
+ removeMessagePreSendListener(presendObject);
}
});