mirror of
https://github.com/Equicord/Equicord.git
synced 2025-06-24 13:57:02 -04:00
Path aliases, better lazyWebpack (#268)
This commit is contained in:
parent
7a4402f142
commit
bad96b7887
138 changed files with 572 additions and 547 deletions
|
@ -16,7 +16,8 @@
|
|||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import { Settings } from "../../../Vencord";
|
||||
import { Settings } from "@api/settings";
|
||||
|
||||
import { Review } from "../entities/Review";
|
||||
import { authorize, showToast } from "./Utils";
|
||||
|
||||
|
|
|
@ -16,12 +16,13 @@
|
|||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import { Devs } from "../../../utils/constants";
|
||||
import Logger from "../../../utils/Logger";
|
||||
import { openModal } from "../../../utils/modal";
|
||||
import { Settings } from "../../../Vencord";
|
||||
import { findByProps } from "../../../webpack";
|
||||
import { FluxDispatcher, React, SelectedChannelStore, Toasts, UserUtils } from "../../../webpack/common";
|
||||
import { Settings } from "@api/settings";
|
||||
import { Devs } from "@utils/constants";
|
||||
import Logger from "@utils/Logger";
|
||||
import { openModal } from "@utils/modal";
|
||||
import { findByProps } from "@webpack";
|
||||
import { FluxDispatcher, React, SelectedChannelStore, Toasts, UserUtils } from "@webpack/common";
|
||||
|
||||
import { Review } from "../entities/Review";
|
||||
|
||||
export async function openUserProfileModal(userId: string) {
|
||||
|
|
|
@ -16,8 +16,8 @@
|
|||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import { classes, LazyComponent } from "../../../utils/misc";
|
||||
import { findByProps } from "../../../webpack";
|
||||
import { classes, LazyComponent } from "@utils/misc";
|
||||
import { findByProps } from "@webpack";
|
||||
|
||||
export default LazyComponent(() => {
|
||||
const { button, dangerous } = findByProps("button", "wrapper", "disabled");
|
||||
|
|
|
@ -16,9 +16,10 @@
|
|||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import { classes, LazyComponent } from "../../../utils/misc";
|
||||
import { filters, findBulk } from "../../../webpack";
|
||||
import { Alerts, UserStore } from "../../../webpack/common";
|
||||
import { classes, LazyComponent } from "@utils/misc";
|
||||
import { filters, findBulk } from "@webpack";
|
||||
import { Alerts, UserStore } from "@webpack/common";
|
||||
|
||||
import { Review } from "../entities/Review";
|
||||
import { deleteReview, reportReview } from "../Utils/ReviewDBAPI";
|
||||
import { canDeleteReview, openUserProfileModal, showToast } from "../Utils/Utils";
|
||||
|
|
|
@ -16,14 +16,15 @@
|
|||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import { classes, useAwaiter } from "@utils/misc";
|
||||
import { findLazy } from "@webpack";
|
||||
import { Forms, Text, UserStore } from "@webpack/common";
|
||||
import type { KeyboardEvent } from "react";
|
||||
|
||||
import { classes, lazyWebpack, useAwaiter } from "../../../utils/misc";
|
||||
import { Forms, Text, UserStore } from "../../../webpack/common";
|
||||
import { addReview, getReviews } from "../Utils/ReviewDBAPI";
|
||||
import ReviewComponent from "./ReviewComponent";
|
||||
|
||||
const Classes = lazyWebpack(m => typeof m.textarea === "string");
|
||||
const Classes = findLazy(m => typeof m.textarea === "string");
|
||||
|
||||
export default function ReviewsView({ userId }: { userId: string; }) {
|
||||
const [reviews, _, isLoading, refetch] = useAwaiter(() => getReviews(userId), []);
|
||||
|
|
|
@ -16,13 +16,13 @@
|
|||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import { Settings } from "@api/settings";
|
||||
import ErrorBoundary from "@components/ErrorBoundary";
|
||||
import { Devs } from "@utils/constants";
|
||||
import definePlugin, { OptionType } from "@utils/types";
|
||||
import { Button, UserStore } from "@webpack/common";
|
||||
import { User } from "discord-types/general";
|
||||
|
||||
import ErrorBoundary from "../../components/ErrorBoundary";
|
||||
import { Devs } from "../../utils/constants";
|
||||
import definePlugin, { OptionType } from "../../utils/types";
|
||||
import { Settings } from "../../Vencord";
|
||||
import { Button, UserStore } from "../../webpack/common";
|
||||
import ReviewsView from "./components/ReviewsView";
|
||||
import { getLastReviewID } from "./Utils/ReviewDBAPI";
|
||||
import { authorize, showToast } from "./Utils/Utils";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue