Allow other modifier keys to submit the form

This commit is contained in:
Jordan Johnson-Doyle 2019-02-14 01:22:04 +00:00
parent a49af51eda
commit 44d3b3358c
No known key found for this signature in database
GPG key ID: A95F87B578CE79B6

View file

@ -53,7 +53,7 @@
onInput();
document.body.addEventListener('keydown', (e) => {
if (e.keyCode === 13 && e.metaKey) {
if (e.key === 'Enter' && (e.metaKey || e.ctrlKey || e.altKey)) {
form.submit();
}
});