mirror of
https://github.com/Equicord/Equicord.git
synced 2025-06-27 15:34:26 -04:00
More Fixes
This commit is contained in:
parent
a676c20cc8
commit
149fc67090
9 changed files with 21 additions and 21 deletions
|
@ -4,14 +4,14 @@
|
|||
* SPDX-License-Identifier: GPL-3.0-or-later
|
||||
*/
|
||||
|
||||
import { addChatBarButton, ChatBarButton, removeChatBarButton } from "@api/ChatButtons";
|
||||
import { addChatBarButton, ChatBarButton, ChatBarButtonFactory, removeChatBarButton } from "@api/ChatButtons";
|
||||
import {
|
||||
ApplicationCommandInputType,
|
||||
ApplicationCommandOptionType,
|
||||
sendBotMessage,
|
||||
} from "@api/Commands";
|
||||
import * as DataStore from "@api/DataStore";
|
||||
import { addMessagePreSendListener, removeMessagePreSendListener, SendListener } from "@api/MessageEvents";
|
||||
import { addMessagePreSendListener, MessageSendListener, removeMessagePreSendListener } from "@api/MessageEvents";
|
||||
import { Devs } from "@utils/constants";
|
||||
import { sleep } from "@utils/misc";
|
||||
import definePlugin from "@utils/types";
|
||||
|
@ -41,12 +41,12 @@ interface IMessageCreate {
|
|||
message: Message;
|
||||
}
|
||||
|
||||
const ChatBarIcon: ChatBarButton = ({ isMainChat }) => {
|
||||
const ChatBarIcon: ChatBarButtonFactory = ({ isMainChat }) => {
|
||||
[enabled, setEnabled] = useState(false);
|
||||
const [buttonDisabled, setButtonDisabled] = useState(false);
|
||||
|
||||
useEffect(() => {
|
||||
const listener: SendListener = async (_, message) => {
|
||||
const listener: MessageSendListener = async (_, message) => {
|
||||
if (enabled) {
|
||||
const groupChannel = await DataStore.get("encryptcordChannelId");
|
||||
// @ts-expect-error typing issue
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue