Keyboard shortcuts and accessibility

This commit is contained in:
Scott Nonnenberg 2019-11-07 13:36:16 -08:00
parent 8590a047c7
commit 20a892247f
87 changed files with 3652 additions and 711 deletions

View file

@ -37,10 +37,10 @@ export const ConfirmationDialog = React.memo(
onClose();
}
};
document.addEventListener('keyup', handler);
document.addEventListener('keydown', handler);
return () => {
document.removeEventListener('keyup', handler);
document.removeEventListener('keydown', handler);
};
},
[onClose]