diff --git a/src/app/browser/discord/index.tsx b/src/app/browser/discord/index.tsx
index b74efe4..099c599 100644
--- a/src/app/browser/discord/index.tsx
+++ b/src/app/browser/discord/index.tsx
@@ -9,6 +9,8 @@ import { getAccounts, RequestState, Root, useAsync, useDiscordPresenceSource, us
export interface DiscordSetupProps {
users?: string[];
friend_nsa_id?: string;
+ /** @default true */
+ show_preferences_button?: boolean;
}
enum DiscordSourceType {
@@ -158,6 +160,15 @@ export default function DiscordSetup(props: DiscordSetupProps) {
style={[styles.textInput, theme.textInput]} />
> : null}
+ {discord_presence_source && (props.show_preferences_button ?? true) ? <>
+ Configure additional options for Discord Rich Presence
+
+
+ > : null}
+
diff --git a/src/app/main/ipc.ts b/src/app/main/ipc.ts
index b33f49c..662530d 100644
--- a/src/app/main/ipc.ts
+++ b/src/app/main/ipc.ts
@@ -83,6 +83,7 @@ export function setupIpc(appinstance: App, ipcMain: IpcMain) {
ipcMain.handle('nxapi:coral:friendcode', (e, token: string, friendcode: string, hash?: string) => store.users.get(token).then(u => u.nso.getUserByFriendCode(friendcode, hash)).then(r => r.result));
ipcMain.handle('nxapi:coral:addfriend', (e, token: string, nsaid: string) => store.users.get(token).then(u => u.addFriend(nsaid)));
+ ipcMain.handle('nxapi:window:showpreferences', () => appinstance.showPreferencesWindow().id);
ipcMain.handle('nxapi:window:showfriend', (e, props: FriendProps) => createWindow(WindowType.FRIEND, props, {
parent: BrowserWindow.fromWebContents(e.sender) ?? undefined,
modal: true,
diff --git a/src/app/preload/index.ts b/src/app/preload/index.ts
index 80dc5e7..b475989 100644
--- a/src/app/preload/index.ts
+++ b/src/app/preload/index.ts
@@ -65,6 +65,7 @@ const ipc = {
getNintendoAccountMoonToken: (id: string) => inv('moon:gettoken', id),
getSavedMoonToken: (token: string) => inv('moon:getcachedtoken', token),
+ showPreferencesWindow: () => inv('window:showpreferences'),
showFriendModal: (props: FriendProps) => inv('window:showfriend', props),
showDiscordModal: (props: DiscordSetupProps = {}) => inv('window:discord', props),
showAddFriendModal: (props: AddFriendProps) => inv('window:addfriend', props),