diff options
author | Ven <vendicated@riseup.net> | 2022-11-28 13:37:55 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-28 13:37:55 +0100 |
commit | bad96b78879f296d5b9e7adacb03756b0f58427a (patch) | |
tree | 4ddbc57a29e9b201bee1317f18110e8e1ad320e5 /src/components/VencordSettings | |
parent | 7a4402f1425ea9fdc6d2b3c985a4ce831f405937 (diff) | |
download | Vencord-bad96b78879f296d5b9e7adacb03756b0f58427a.tar.gz Vencord-bad96b78879f296d5b9e7adacb03756b0f58427a.tar.bz2 Vencord-bad96b78879f296d5b9e7adacb03756b0f58427a.zip |
Path aliases, better lazyWebpack (#268)
Diffstat (limited to 'src/components/VencordSettings')
-rw-r--r-- | src/components/VencordSettings/BackupRestoreTab.tsx | 5 | ||||
-rw-r--r-- | src/components/VencordSettings/Updater.tsx | 7 | ||||
-rw-r--r-- | src/components/VencordSettings/VencordTab.tsx | 9 | ||||
-rw-r--r-- | src/components/VencordSettings/index.tsx | 8 |
4 files changed, 16 insertions, 13 deletions
diff --git a/src/components/VencordSettings/BackupRestoreTab.tsx b/src/components/VencordSettings/BackupRestoreTab.tsx index ce0bdaa..73a1309 100644 --- a/src/components/VencordSettings/BackupRestoreTab.tsx +++ b/src/components/VencordSettings/BackupRestoreTab.tsx @@ -16,8 +16,9 @@ * along with this program. If not, see <https://www.gnu.org/licenses/>. */ -import { downloadSettingsBackup, uploadSettingsBackup } from "../../utils/settingsSync"; -import { Button, Card, Forms, Margins, Text } from "../../webpack/common"; +import { downloadSettingsBackup, uploadSettingsBackup } from "@utils/settingsSync"; +import { Button, Card, Forms, Margins, Text } from "@webpack/common"; + import ErrorBoundary from "../ErrorBoundary"; import { Flex } from "../Flex"; diff --git a/src/components/VencordSettings/Updater.tsx b/src/components/VencordSettings/Updater.tsx index 8f2b75b..7abfad9 100644 --- a/src/components/VencordSettings/Updater.tsx +++ b/src/components/VencordSettings/Updater.tsx @@ -16,11 +16,12 @@ * along with this program. If not, see <https://www.gnu.org/licenses/>. */ +import { classes, useAwaiter } from "@utils/misc"; +import { changes, checkForUpdates, getRepo, isNewer, rebuild, update, updateError, UpdateLogger } from "@utils/updater"; +import { Alerts, Button, Card, Forms, Margins, Parser, React, Toasts } from "@webpack/common"; + import gitHash from "~git-hash"; -import { classes, useAwaiter } from "../../utils/misc"; -import { changes, checkForUpdates, getRepo, isNewer, rebuild, update, updateError, UpdateLogger } from "../../utils/updater"; -import { Alerts, Button, Card, Forms, Margins, Parser, React, Toasts } from "../../webpack/common"; import ErrorBoundary from "../ErrorBoundary"; import { ErrorCard } from "../ErrorCard"; import { Flex } from "../Flex"; diff --git a/src/components/VencordSettings/VencordTab.tsx b/src/components/VencordSettings/VencordTab.tsx index 0e5846f..3a3f45f 100644 --- a/src/components/VencordSettings/VencordTab.tsx +++ b/src/components/VencordSettings/VencordTab.tsx @@ -17,10 +17,11 @@ */ -import { useSettings } from "../../api/settings"; -import IpcEvents from "../../utils/IpcEvents"; -import { useAwaiter } from "../../utils/misc"; -import { Button, Card, Forms, React, Switch } from "../../webpack/common"; +import { useSettings } from "@api/settings"; +import IpcEvents from "@utils/IpcEvents"; +import { useAwaiter } from "@utils/misc"; +import { Button, Card, Forms, React, Switch } from "@webpack/common"; + import DonateButton from "../DonateButton"; import ErrorBoundary from "../ErrorBoundary"; diff --git a/src/components/VencordSettings/index.tsx b/src/components/VencordSettings/index.tsx index 028bd5e..4b6fb4e 100644 --- a/src/components/VencordSettings/index.tsx +++ b/src/components/VencordSettings/index.tsx @@ -16,11 +16,11 @@ * along with this program. If not, see <https://www.gnu.org/licenses/>. */ +import { findByCodeLazy } from "@webpack"; +import { Forms, Router, Text } from "@webpack/common"; + import cssText from "~fileContent/settingsStyles.css"; -import { lazyWebpack } from "../../utils/misc"; -import { filters } from "../../webpack"; -import { Forms, React, Router, Text } from "../../webpack/common"; import ErrorBoundary from "../ErrorBoundary"; import BackupRestoreTab from "./BackupRestoreTab"; import PluginsTab from "./PluginsTab"; @@ -33,7 +33,7 @@ document.head.appendChild(style); const st = (style: string) => `vcSettings${style}`; -const TabBar = lazyWebpack(filters.byCode('[role="tab"][aria-disabled="false"]')); +const TabBar = findByCodeLazy('[role="tab"][aria-disabled="false"]'); interface SettingsProps { tab: string; |