Skip to content

Conversation

@kraktus
Copy link
Member

@kraktus kraktus commented Apr 21, 2023

The issue was that we waited for the PGN http request to return before calling the clipboard API, and at that time it was already disabled back by the browser.
Safari fix is a simplified version of https://developer.apple.com/forums/thread/691873. Unfortunately, Firefox does not support the ClipboardItem so made a workaround.

Tested on Safari and Firefox.

kraktus added 2 commits April 21, 2023 08:24
The issue was that we waited for the PGN http request to return before calling the clipboard API, and at that time it was already disabled back by the browser.
Safari fix is a simplified version of https://developer.apple.com/forums/thread/691873. Unfortunately, Firefox does not support the `ClipboardItem` so made a workaround.

Tested on Safari and Firefox.

fix lichess-org#12461
@kraktus kraktus changed the title Copy pgn chap study Study chapter: fix PGN to clipboard for Safari Apr 21, 2023
@ornicar ornicar merged commit 8ec992b into lichess-org:master Apr 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants