add copy svg keyboard shortcut (#573)

This commit is contained in:
Eswar Prasad Clinton. A 2022-02-13 18:07:01 +05:30 committed by GitHub
parent 8549c73884
commit 5721885161
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -497,6 +497,18 @@ export function useKeyboardShortcuts(ref: React.RefObject<HTMLDivElement>) {
[app]
)
useHotkeys(
'⌘+shift+c,ctrl+shift+c',
(e) => {
if (!canHandleEvent()) return
app.copySvg()
e.preventDefault()
},
undefined,
[app]
)
useHotkeys(
'⌘+x,ctrl+x',
() => {