mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
* feat(HighlightNoteModal.tsx): add keyboard shortcut to save note changes and close modal
This commit is contained in:
parent
2e1c99780a
commit
8aea5c9a90
1 changed files with 7 additions and 0 deletions
|
|
@ -78,6 +78,13 @@ export function HighlightNoteModal(
|
|||
event.preventDefault()
|
||||
event.stopPropagation()
|
||||
}}
|
||||
onKeyDown={(event) => {
|
||||
if ((event.metaKey || event.ctrlKey) && event.key === 'Enter') {
|
||||
event.preventDefault()
|
||||
saveNoteChanges()
|
||||
props.onOpenChange(false)
|
||||
}
|
||||
}}
|
||||
>
|
||||
<form
|
||||
onSubmit={(event) => {
|
||||
|
|
|
|||
Loading…
Reference in a new issue