Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bookmark game #594

Open
veloce opened this issue Mar 11, 2024 · 8 comments · May be fixed by #1302
Open

Bookmark game #594

veloce opened this issue Mar 11, 2024 · 8 comments · May be fixed by #1302
Labels
cat: game All things related to playing a game Missing server API
Milestone

Comments

@veloce
Copy link
Contributor

veloce commented Mar 11, 2024

Add the possibility to bookmark a game.

Should be available in context menu (long press), in the future game list screen, and in a game screen.

@veloce veloce added the cat: game All things related to playing a game label Mar 11, 2024
@ZTL-UwU
Copy link
Contributor

ZTL-UwU commented Jul 12, 2024

@veloce I would love to do this but I think we will need a new api for this.

@veloce
Copy link
Contributor Author

veloce commented Jul 15, 2024

Yes indeed the bookmark action is not opened to oAuth. Will create an issue on Lila. Thanks for the report.

@veloce
Copy link
Contributor Author

veloce commented Jul 15, 2024

Server PR: lichess-org/lila#15726

@veloce
Copy link
Contributor Author

veloce commented Jul 15, 2024

The bookmark filter should be added to the game list endpoint: https://lichess.org/api#tag/Games/operation/apiGamesUser

So we can display bookmarked games.

@veloce
Copy link
Contributor Author

veloce commented Jul 15, 2024

@ZTL-UwU ZTL-UwU mentioned this issue Jul 17, 2024
6 tasks
@ZTL-UwU
Copy link
Contributor

ZTL-UwU commented Jul 21, 2024

@veloce One more problem, there is currently no way to know if a game is bookmarked by myself or not.

I think there are potentially three solutions to this.

  1. We can tweek the /game/export/$id api and add a response field to indicate whether the game is bookmarked by the requesting user.
  2. We can create a new api to check if a certain game is bookmarked or not.
  3. We can probably cache the bookmarked game list (using https://lichess.org/api#tag/Games/operation/apiGamesUser) and check if the game is included in the list or not. This is a bit trickier to implement tho.

@veloce
Copy link
Contributor Author

veloce commented Jul 24, 2024

So it misses the bookmarked boolean field in the game json. I'll see to add it server side.

@ZTL-UwU
Copy link
Contributor

ZTL-UwU commented Jul 24, 2024

So it misses the bookmarked boolean field in the game json. I'll see to add it server side.

Actually, maybe all the game related apis will need the bookmarked field because the bookmark button is in almost all game screens. e.g. the analysis screen, game screen, archived game screen and the game history screen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cat: game All things related to playing a game Missing server API
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants