mirror of
https://github.com/searxng/searxng
synced 2024-01-01 19:24:07 +01:00
[mod] improve handling of the hotkeys
- KeyboardEvent: keyCode property is depricated, replaced by key property [2] - the check for ifDetailOpened is not necessary, because the hotkeys are not only applicable to image-results, by example: `!goi !go !scc hello` - Key bindings like h for help are to be used in general (not only in vim-mode) [1] https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/keyCode [2] https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
This commit is contained in:
parent
e6b160da62
commit
a987672340
2 changed files with 92 additions and 102 deletions
|
|
@ -74,10 +74,6 @@
|
|||
searxng.scrollPageToSelected();
|
||||
}
|
||||
|
||||
searxng.isDetailOpened = function () {
|
||||
return d.getElementById('results').classList.contains('image-detail-open');
|
||||
}
|
||||
|
||||
searxng.closeDetail = function (e) {
|
||||
d.getElementById('results').classList.remove('image-detail-open');
|
||||
searxng.scrollPageToSelected();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue