Revize deb7058e
Přidáno uživatelem Pavel Fidranský před téměř 6 roky(ů)
sources/src/main/webapp/js/components/navbar.js | ||
---|---|---|
96 | 96 |
class: 'search-text', |
97 | 97 |
id: 'searchText', |
98 | 98 |
onKeyUp: e => { |
99 |
switch (e.keyCode) { |
|
100 |
// enter key |
|
101 |
case 13: |
|
99 |
switch (e.key) { |
|
100 |
case 'Enter': |
|
102 | 101 |
search(e.target.value); |
103 | 102 |
break; |
104 | 103 |
|
105 |
// escape key |
|
106 |
case 27: |
|
104 |
case 'Escape': |
|
107 | 105 |
resetSearch(); |
108 | 106 |
break; |
109 | 107 |
} |
Také k dispozici: Unified diff
replaced deprecated keyCode property by key