fix(web): remove processing key events in photo viewer window (#3238)

pull/3103/head
Harry Tran 2023-07-14 01:43:11 +07:00 committed by GitHub
parent f9739c9730
commit 48c9cfb432
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

@ -45,6 +45,9 @@
};
const handleKeypress = async ({ metaKey, ctrlKey, key }: KeyboardEvent) => {
if (window.getSelection()?.type === 'Range') {
return;
}
if ((metaKey || ctrlKey) && key === 'c') {
await doCopy();
}