Skip to content

Commit

Permalink
add space to next
Browse files Browse the repository at this point in the history
  • Loading branch information
VickScarlet committed Oct 5, 2021
1 parent b65ef06 commit e91fab8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion public/bundle.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions src/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ class App{
globalThis.onerror = (event, source, lineno, colno, error) => {
this.hint(`[ERROR] at (${source}:${lineno}:${colno})\n\n${error?.stack||error||'unknow Error'}`, 'error');
}
const keyDownCallback = (keyboardEvent) => {
if (keyboardEvent.which === 13 || keyboardEvent.keyCode === 13) {
const keyDownCallback = ({which: w, keyCode: k}) => {
if ( w === 13 || k === 13 || w === 32 || k === 32 ) {
const pressEnterFunc = this.#pages[this.#currentPage]?.pressEnter;
pressEnterFunc && typeof pressEnterFunc === 'function' && pressEnterFunc();
}
Expand Down

0 comments on commit e91fab8

Please sign in to comment.