51 overhaul of screenshot modal#88
Open
Peer222 wants to merge 9 commits into
Open
Conversation
3 tasks
Collaborator
|
Might not be able to review this in time for today's release. Will get to this next week. |
Collaborator
rxvl-d
reviewed
May 14, 2026
| workerData.location, | ||
| workerData.screenshot, | ||
| workerData.associatedAnnotations | ||
| ).then((err) => { |
Collaborator
There was a problem hiding this comment.
Apparently this doesn't work anymore.
$ node -e "const f = async () => { throw new Error('oops') }; f().then((err) => { if (err) console.log('caught here'); else console.log('success') }).catch((err) => console.log('actually caught'))"
actually caught
You need to use .catch. I think this pattern is used in a few other places as well.
rxvl-d
reviewed
May 14, 2026
| .replaceAll(':', '-') | ||
| .replace(',', '_') | ||
| try { | ||
| fs.copyFileSync(imagePath, path.join(tmpPath, imageName + '.jpg')) |
Collaborator
There was a problem hiding this comment.
Wouldn't it be better to use fs.promises.copyFile here since this is an async function to avoid blocking. It doesn't matter so much since this happens in a worker but still good code hygiene.
Collaborator
Author
|
I have fixed the buttons and error catch. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Screenshot modal with zooming and associated annotations
Export of zip file containing screenshot and associated annotations in json format with an export_screenshot worker (adapted from export_screenshots worker; currently not implemented in server/)