Skip to content

Commit

Permalink
Merge pull request #19 from apzl/master
Browse files Browse the repository at this point in the history
keyboard bugfix
  • Loading branch information
apzl authored Jan 8, 2021
2 parents b5a6819 + 9ecd981 commit 3723c0b
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions assets/js/project.js
Original file line number Diff line number Diff line change
Expand Up @@ -381,15 +381,15 @@ function completeFn(){
}

// keypress events
/* cntrl + s = save
cntrl + x = skip
cntrl + z = next
cntrl + o = complete
/* alt + g = save
alt + x = skip
alt + z = next
alt + o = complete
*/
document.addEventListener('keydown', function(event) {
if (event.altKey || event.metaKey) {
switch (String.fromCharCode(event.which).toLowerCase()) {
case 's':
case 'g':
event.preventDefault();
document.getElementById("save").click();
break;
Expand Down

0 comments on commit 3723c0b

Please sign in to comment.