Merge branch 'main' into feature/add-collections-section

This commit is contained in:
Tasheron 2024-07-28 17:06:36 +03:00 committed by GitHub
commit 4540dcc033
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
34 changed files with 1000 additions and 168 deletions

View file

@ -11,6 +11,7 @@ import type {
GameRunning,
Collection,
Game,
FriendRequestAction,
} from "@types";
contextBridge.exposeInMainWorld("electron", {
@ -148,6 +149,11 @@ contextBridge.exposeInMainWorld("electron", {
getMe: () => ipcRenderer.invoke("getMe"),
updateProfile: (displayName: string, newProfileImagePath: string | null) =>
ipcRenderer.invoke("updateProfile", displayName, newProfileImagePath),
getFriendRequests: () => ipcRenderer.invoke("getFriendRequests"),
updateFriendRequest: (userId: string, action: FriendRequestAction) =>
ipcRenderer.invoke("updateFriendRequest", userId, action),
sendFriendRequest: (userId: string) =>
ipcRenderer.invoke("sendFriendRequest", userId),
/* User */
getUser: (userId: string) => ipcRenderer.invoke("getUser", userId),