diff options
author | botato <63275405+botatooo@users.noreply.github.com> | 2022-10-01 16:05:15 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-02 01:05:15 +0200 |
commit | acf06203b6ab5129adc4bf09c7014d888f15944b (patch) | |
tree | 92418611528d082cdcf76e63b818c773f27f3b12 | |
parent | 57d586fab73814a3778303c7a78c55c785e62af0 (diff) | |
download | Vencord-acf06203b6ab5129adc4bf09c7014d888f15944b.tar.gz Vencord-acf06203b6ab5129adc4bf09c7014d888f15944b.tar.bz2 Vencord-acf06203b6ab5129adc4bf09c7014d888f15944b.zip |
some tweaks (#22)
-rw-r--r-- | src/components/Settings.tsx | 20 | ||||
-rw-r--r-- | src/webpack/webpack.ts | 2 |
2 files changed, 15 insertions, 7 deletions
diff --git a/src/components/Settings.tsx b/src/components/Settings.tsx index 54e6ddb..3e883b9 100644 --- a/src/components/Settings.tsx +++ b/src/components/Settings.tsx @@ -69,11 +69,18 @@ export default ErrorBoundary.wrap(function Settings() { </Forms.FormTitle> <Forms.FormText> - SettingsDir: {settingsDir} + SettingsDir: <code style={{ userSelect: 'text', cursor: 'text' }}>{settingsDir}</code> </Forms.FormText> <Flex className={classes(Margins.marginBottom20)}> <Button + onClick={() => location.reload()} + size={Button.Sizes.SMALL} + color={Button.Colors.GREEN} + > + Reload + </Button> + <Button onClick={() => VencordNative.ipc.invoke(IpcEvents.OPEN_PATH, settingsDir)} size={Button.Sizes.SMALL} disabled={settingsDirPending} @@ -88,24 +95,25 @@ export default ErrorBoundary.wrap(function Settings() { Open QuickCSS File </Button> </Flex> - + <Forms.FormDivider /> + <Forms.FormTitle tag="h5">Settings</Forms.FormTitle> <Switch value={settings.useQuickCss} - onChange={v => settings.useQuickCss = v} - note="Enable QuickCss" + onChange={(v: boolean) => settings.useQuickCss = v} + note="Enable QuickCSS" > Use QuickCss </Switch> <Switch value={settings.notifyAboutUpdates} - onChange={v => settings.notifyAboutUpdates = v} + onChange={(v: boolean) => settings.notifyAboutUpdates = v} note="Shows a Toast on StartUp" > Get notified about new Updates </Switch> <Switch value={settings.unsafeRequire} - onChange={v => settings.unsafeRequire = v} + onChange={(v: boolean) => settings.unsafeRequire = v} note="Enables VencordNative.require. Useful for testing, very bad for security. Leave this off unless you need it." > Enable Unsafe Require diff --git a/src/webpack/webpack.ts b/src/webpack/webpack.ts index 9be576a..15104bb 100644 --- a/src/webpack/webpack.ts +++ b/src/webpack/webpack.ts @@ -135,7 +135,7 @@ export function search(...filters: Array<string | RegExp>) { const factories = wreq.m; outer: for (const id in factories) { - const factory = factories[id]; + const factory = factories[id].original ?? factories[id]; const str: string = factory.toString(); for (const filter of filters) { if (typeof filter === "string" && !str.includes(filter)) continue outer; |