summaryrefslogtreecommitdiffstats
path: root/theme/javascript/core/keyboard.js
diff options
context:
space:
mode:
Diffstat (limited to 'theme/javascript/core/keyboard.js')
-rw-r--r--theme/javascript/core/keyboard.js14
1 files changed, 11 insertions, 3 deletions
diff --git a/theme/javascript/core/keyboard.js b/theme/javascript/core/keyboard.js
index 05e939e..5bbdcf2 100644
--- a/theme/javascript/core/keyboard.js
+++ b/theme/javascript/core/keyboard.js
@@ -2,8 +2,9 @@ define([
"jQuery",
"Mousetrap",
"core/navigation",
- "core/sidebar"
-], function($, Mousetrap, navigation, sidebar){
+ "core/sidebar",
+ "core/search"
+], function($, Mousetrap, navigation, sidebar, search){
// Bind keyboard shortcuts
var init = function() {
// Next
@@ -23,9 +24,16 @@ define([
sidebar.toggle();
return false;
});
+
+ // Toggle Search
+ Mousetrap.bind(['f'], function(e) {
+ search.toggle();
+ return false;
+ });
};
return {
- init: init
+ init: init,
+ search: search
};
}); \ No newline at end of file