Public Access
feat(library): ask whether a game is finished
This commit is contained in:
1 parent
011711fe4f
commit
83bbc2730d
8 files changed
+209
-3
No files matched your search
@@ -37,6 +37,18 @@ export const saveGameStatus = (appid, status) =>
|
||||
body: JSON.stringify({status}),
|
||||
});
|
||||
|
||||
/**
|
||||
* PUT /api/library/games/{appid}/finished-hint: "Not yet" on the finished hint. Answers 204.
|
||||
*
|
||||
* @param dismissed the hint type the user answered, ENDING or PLAYTIME
|
||||
*/
|
||||
export const dismissFinishedHint = (appid, dismissed) =>
|
||||
apiFetch(`${import.meta.env.VITE_CORE_API_URL}/api/library/games/${appid}/finished-hint`, {
|
||||
method: 'PUT',
|
||||
headers: {'Content-Type': 'application/json'},
|
||||
body: JSON.stringify({dismissed}),
|
||||
});
|
||||
|
||||
export const libraryQuery = ({page, size, sort, status, q, maxMinutes, hidden}) => {
|
||||
const params = new URLSearchParams({page: String(page), size: String(size), sort});
|
||||
if (hidden) params.set('hidden', 'true');
|
||||
|
||||
Reference in new issue
Block a user