diff --git a/src/api/PluginManager.ts b/src/api/PluginManager.ts index 82b7c9877..e473cf0bb 100644 --- a/src/api/PluginManager.ts +++ b/src/api/PluginManager.ts @@ -70,6 +70,7 @@ export function isPluginRequired(p: string) { export function addPatch(newPatch: Omit, pluginName: string, pluginPath = `Vencord.Plugins.plugins[${JSON.stringify(pluginName)}]`) { // TODO: this causes crashes if (pluginName === "Vesktop" && newPatch.find === ".STREAMING_AUTO_STREAMER_MODE,") return; + if (pluginName === "Equibop" && newPatch.find === ".STREAMING_AUTO_STREAMER_MODE,") return; const patch = newPatch as Patch; patch.plugin = pluginName; diff --git a/src/plugins/experiments/index.tsx b/src/plugins/experiments/index.tsx index 8f7d918ab..9105d2d86 100644 --- a/src/plugins/experiments/index.tsx +++ b/src/plugins/experiments/index.tsx @@ -15,7 +15,7 @@ import { Devs, IS_MAC } from "@utils/constants"; import { Margins } from "@utils/margins"; import definePlugin, { OptionType } from "@utils/types"; import { findByPropsLazy } from "@webpack"; -import { Forms, React } from "@webpack/common"; +import { React } from "@webpack/common"; import hideBugReport from "./hideBugReport.css?managed"; diff --git a/src/plugins/mutualGroupDMs/index.tsx b/src/plugins/mutualGroupDMs/index.tsx index 41cf0bc6a..5166cef18 100644 --- a/src/plugins/mutualGroupDMs/index.tsx +++ b/src/plugins/mutualGroupDMs/index.tsx @@ -26,7 +26,7 @@ import { Logger } from "@utils/Logger"; import definePlugin from "@utils/types"; import { Channel, User } from "@vencord/discord-types"; import { findByPropsLazy, findCssClassesLazy } from "@webpack"; -import { Avatar, ChannelStore, Clickable, IconUtils, RelationshipStore, ScrollerThin, Text, useMemo, UserStore } from "@webpack/common"; +import { Avatar, ChannelStore, Clickable, IconUtils, RelationshipStore, ScrollerThin, useMemo, UserStore } from "@webpack/common"; import { ComponentType, JSX } from "react"; const SelectedChannelActionCreators = findByPropsLazy("selectPrivateChannel"); diff --git a/src/plugins/voiceMessages/components/VoicePreview.tsx b/src/plugins/voiceMessages/components/VoicePreview.tsx index 417e99f43..8c47c4fd2 100644 --- a/src/plugins/voiceMessages/components/VoicePreview.tsx +++ b/src/plugins/voiceMessages/components/VoicePreview.tsx @@ -17,10 +17,8 @@ */ import { useTimer } from "@utils/react"; -import { ComponentType } from "react"; - -import { cl } from ".."; +import { cl, VoiceMessage } from ".."; const PREVIEW_IDLE_LABEL = "----"; const PREVIEW_RECORDING_LABEL = "RECORDING"; @@ -29,7 +27,6 @@ export interface VoiceMessageProps { src: string; waveform: string; } -export let VoiceMessage: ComponentType = () => null; export type VoicePreviewOptions = { src?: string; diff --git a/src/plugins/voiceMessages/index.tsx b/src/plugins/voiceMessages/index.tsx index 3db1202a1..6e3072153 100644 --- a/src/plugins/voiceMessages/index.tsx +++ b/src/plugins/voiceMessages/index.tsx @@ -35,9 +35,10 @@ import definePlugin, { OptionType } from "@utils/types"; import { chooseFile } from "@utils/web"; import { CloudUploadPlatform } from "@vencord/discord-types/enums"; import { Button, CloudUploader, Constants, FluxDispatcher, Forms, lodash, Menu, MessageActions, PendingReplyStore, PermissionsBits, PermissionStore, RestAPI, SelectedChannelStore, showToast, SnowflakeUtils, Toasts, useEffect, useState } from "@webpack/common"; +import { ComponentType } from "react"; import { VoiceRecorderDesktop } from "./components/DesktopRecorder"; -import { VoicePreview } from "./components/VoicePreview"; +import { VoiceMessageProps, VoicePreview } from "./components/VoicePreview"; import { VoiceRecorderWeb } from "./components/WebRecorder"; const VOICE_MESSAGE_FLAG = 1 << 13; @@ -61,6 +62,8 @@ export type VoiceRecorder = React.ComponentType<{ onRecordingChange?(recording: boolean): void; }>; +export let VoiceMessage: ComponentType = () => null; + type AudioMetadata = { waveform: string, duration: number, diff --git a/src/webpack/common/utils.ts b/src/webpack/common/utils.ts index 46e0054d2..a678c2626 100644 --- a/src/webpack/common/utils.ts +++ b/src/webpack/common/utils.ts @@ -157,19 +157,7 @@ Toasts.create = (message: string, type: string, options?: ToastOptions): ToastDa options, }); -Toasts.show = ({ message, type = ToastType.MESSAGE, options }: ToastData) => { - const { showNotification } = require("../../api/Notifications"); - - showNotification({ - title: ToastTypeToNotificationTitle[type] ?? "Notice", - body: message, - color: ToastTypeToNotificationColor[type] ?? "#5865f2", - permanent: options?.duration === 0, - richBody: options?.component ?? undefined, - noPersist: true, - dismissOnClick: true, - }); -}; +Toasts.show = () => { }; Toasts.pop = () => { };