Skip to content

Commit

Permalink
Allow changing to the next PR by on phones by touch
Browse files Browse the repository at this point in the history
  • Loading branch information
Multipacker committed Oct 16, 2024
1 parent fa2e9c9 commit dca85ba
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/templates/pr.html
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,14 @@

// Naively switch to next PR when pressing spacebar
document.onkeypress = function (e) {
if (e.keyCode === 32) {
if (e.keyCode === 32) {
next_pr()
}
};
};
// Naively switch to next PR when touching the screen
document.ontouchend = function (e) {
next_pr()
};

// How often the PR list is updated
setInterval(get_prs, {{ pr_fetch_time }} * 1000)
Expand Down

0 comments on commit dca85ba

Please sign in to comment.