feature: implement ctrl+k
This commit is contained in:
parent
a752e44e06
commit
781930e59d
9
src/scripts/keyboard-shortcuts.js
Normal file
9
src/scripts/keyboard-shortcuts.js
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
document.addEventListener("keydown", function (e) {
|
||||||
|
/*
|
||||||
|
CTRL + K : Focus on the user search
|
||||||
|
*/
|
||||||
|
if(e.ctrlKey && e.key == "k") {
|
||||||
|
document.querySelector('#general-search input[type="text"]').focus();
|
||||||
|
e.preventDefault();
|
||||||
|
}
|
||||||
|
});
|
Loading…
Reference in New Issue
Block a user