Revert "Fetch all findstorelazy from webpack"

This reverts commit bf246208e9.
This commit is contained in:
thororen1234 2024-07-20 04:16:06 -04:00
parent 094a488498
commit 64cb08a53f
30 changed files with 241 additions and 156 deletions

View file

@ -11,8 +11,8 @@ import ErrorBoundary from "@components/ErrorBoundary";
import { Devs } from "@utils/constants";
import { classes } from "@utils/misc";
import definePlugin, { OptionType, StartAt } from "@utils/types";
import { findByPropsLazy } from "@webpack";
import { ContextMenuApi, FluxDispatcher, Menu, PrivateChannelSortStore, React } from "@webpack/common";
import { findByPropsLazy, findStoreLazy } from "@webpack";
import { ContextMenuApi, FluxDispatcher, Menu, React } from "@webpack/common";
import { Channel } from "discord-types/general";
import { contextMenus } from "./components/contextMenu";
@ -29,6 +29,8 @@ interface ChannelComponentProps {
const headerClasses = findByPropsLazy("privateChannelsHeaderContainer");
export const PrivateChannelSortStore = findStoreLazy("PrivateChannelSortStore") as { getPrivateChannelIds: () => string[]; };
export let instance: any;
export const forceUpdate = () => instance?.props?._forceUpdate?.();