aboutsummaryrefslogtreecommitdiff
path: root/src/plugins/reviewDB/components
diff options
context:
space:
mode:
authorVen <vendicated@riseup.net>2022-11-28 13:37:55 +0100
committerGitHub <noreply@github.com>2022-11-28 13:37:55 +0100
commitbad96b78879f296d5b9e7adacb03756b0f58427a (patch)
tree4ddbc57a29e9b201bee1317f18110e8e1ad320e5 /src/plugins/reviewDB/components
parent7a4402f1425ea9fdc6d2b3c985a4ce831f405937 (diff)
downloadVencord-bad96b78879f296d5b9e7adacb03756b0f58427a.tar.gz
Vencord-bad96b78879f296d5b9e7adacb03756b0f58427a.tar.bz2
Vencord-bad96b78879f296d5b9e7adacb03756b0f58427a.zip
Path aliases, better lazyWebpack (#268)
Diffstat (limited to 'src/plugins/reviewDB/components')
-rw-r--r--src/plugins/reviewDB/components/MessageButton.tsx4
-rw-r--r--src/plugins/reviewDB/components/ReviewComponent.tsx7
-rw-r--r--src/plugins/reviewDB/components/ReviewsView.tsx7
3 files changed, 10 insertions, 8 deletions
diff --git a/src/plugins/reviewDB/components/MessageButton.tsx b/src/plugins/reviewDB/components/MessageButton.tsx
index 7d16630..c334ddd 100644
--- a/src/plugins/reviewDB/components/MessageButton.tsx
+++ b/src/plugins/reviewDB/components/MessageButton.tsx
@@ -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");
diff --git a/src/plugins/reviewDB/components/ReviewComponent.tsx b/src/plugins/reviewDB/components/ReviewComponent.tsx
index ecd12da..8808ccd 100644
--- a/src/plugins/reviewDB/components/ReviewComponent.tsx
+++ b/src/plugins/reviewDB/components/ReviewComponent.tsx
@@ -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";
diff --git a/src/plugins/reviewDB/components/ReviewsView.tsx b/src/plugins/reviewDB/components/ReviewsView.tsx
index 363b624..999b970 100644
--- a/src/plugins/reviewDB/components/ReviewsView.tsx
+++ b/src/plugins/reviewDB/components/ReviewsView.tsx
@@ -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), []);