> = {
+ "Discord Branch": [DiscordBranchPicker],
+ "System Startup & Performance": [
+ AutoStartToggle,
+ {
+ key: "hardwareAcceleration",
+ title: "Hardware Acceleration",
+ description: "Enable hardware acceleration",
+ defaultValue: true
+ }
+ ],
+ "User Interface": [
+ {
+ key: "customTitleBar",
+ title: "Discord Titlebar",
+ description: "Use Discord's custom title bar instead of the native system one. Requires a full restart.",
+ defaultValue: isWindows
+ },
+ {
+ key: "staticTitle",
+ title: "Static Title",
+ description: 'Makes the window title "Vesktop" instead of changing to the current page',
+ defaultValue: false
+ },
+ {
+ key: "enableMenu",
+ title: "Enable Menu Bar",
+ description: "Enables the application menu bar. Press ALT to toggle visibility.",
+ defaultValue: false,
+ disabled: () => Settings.store.customTitleBar ?? isWindows
+ },
+ {
+ key: "splashTheming",
+ title: "Splash theming",
+ description: "Adapt the splash window colors to your custom theme",
+ defaultValue: false
+ },
+ WindowsTransparencyControls
+ ],
+ Behaviour: [
+ {
+ key: "tray",
+ title: "Tray Icon",
+ description: "Add a tray icon for Vesktop",
+ defaultValue: true,
+ invisible: () => isMac
+ },
+ {
+ key: "minimizeToTray",
+ title: "Minimize to tray",
+ description: "Hitting X will make Vesktop minimize to the tray instead of closing",
+ defaultValue: true,
+ invisible: () => isMac,
+ disabled: () => Settings.store.tray === false
+ },
+ {
+ key: "disableMinSize",
+ title: "Disable minimum window size",
+ description: "Allows you to make the window as small as your heart desires",
+ defaultValue: false
+ },
+ {
+ key: "disableSmoothScroll",
+ title: "Disable smooth scrolling",
+ description: "Disables smooth scrolling",
+ defaultValue: false
+ }
+ ],
+ "Notifications & Updates": [
+ NotificationBadgeToggle,
+ {
+ key: "checkUpdates",
+ title: "Check for updates",
+ description: "Automatically check for Vesktop updates",
+ defaultValue: true
+ }
+ ],
+ Miscelleanous: [
+ {
+ key: "arRPC",
+ title: "Rich Presence",
+ description: "Enables Rich Presence via arRPC",
+ defaultValue: false
+ },
+
+ {
+ key: "openLinksWithElectron",
+ title: "Open Links in app (experimental)",
+ description: "Opens links in a new Vesktop window instead of your web browser",
+ defaultValue: false
+ }
+ ],
+ "Vencord Location": [VencordLocationPicker]
+};
+
+function SettingsSections() {
+ const Settings = useSettings();
+
+ const sections = Object.entries(SettingsOptions).map(([title, settings]) => (
+
+ {settings.map(Setting => {
+ if (typeof Setting === "function") return ;
+
+ const { defaultValue, title, description, key, disabled, invisible } = Setting;
+ if (invisible?.()) return null;
+
+ return (
+ (Settings[key as any] = v)}
+ note={description}
+ disabled={disabled?.()}
+ key={key}
+ >
+ {title}
+
+ );
+ })}
+
+ ));
+
+ return <>{sections}>;
+}
+
+export default function SettingsUi() {
+ return (
+
+
+ Vesktop Settings
+
+
+
+
+ );
+}
diff --git a/src/renderer/components/settings/VencordLocationPicker.tsx b/src/renderer/components/settings/VencordLocationPicker.tsx
new file mode 100644
index 0000000..3759ae2
--- /dev/null
+++ b/src/renderer/components/settings/VencordLocationPicker.tsx
@@ -0,0 +1,62 @@
+/*
+ * SPDX-License-Identifier: GPL-3.0
+ * Vesktop, a desktop app aiming to give you a snappier Discord Experience
+ * Copyright (c) 2023 Vendicated and Vencord contributors
+ */
+
+import { Button, Forms, Toasts } from "@vencord/types/webpack/common";
+
+import { SettingsComponent } from "./Settings";
+
+export const VencordLocationPicker: SettingsComponent = ({ settings }) => {
+ return (
+ <>
+
+ Vencord files are loaded from{" "}
+ {settings.vencordDir ? (
+ {
+ e.preventDefault();
+ VesktopNative.fileManager.showItemInFolder(settings.vencordDir!);
+ }}
+ >
+ {settings.vencordDir}
+
+ ) : (
+ "the default location"
+ )}
+
+
+
+
+
+ >
+ );
+};
diff --git a/src/renderer/components/settings/WindowsTransparencyControls.tsx b/src/renderer/components/settings/WindowsTransparencyControls.tsx
new file mode 100644
index 0000000..0ef9a8a
--- /dev/null
+++ b/src/renderer/components/settings/WindowsTransparencyControls.tsx
@@ -0,0 +1,49 @@
+/*
+ * SPDX-License-Identifier: GPL-3.0
+ * Vesktop, a desktop app aiming to give you a snappier Discord Experience
+ * Copyright (c) 2023 Vendicated and Vencord contributors
+ */
+
+import { Margins } from "@vencord/types/utils";
+import { Forms, Select } from "@vencord/types/webpack/common";
+
+import { SettingsComponent } from "./Settings";
+
+export const WindowsTransparencyControls: SettingsComponent = ({ settings }) => {
+ if (!VesktopNative.app.supportsWindowsTransparency()) return null;
+
+ return (
+ <>
+ Transparency Options
+
+ Requires a full restart. You will need a theme that supports transparency for this to work.
+
+
+