]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - app/Resources/static/themes/material/js/shortcuts/main.js
Reorganized JS folders for shortcuts
[github/wallabag/wallabag.git] / app / Resources / static / themes / material / js / shortcuts / main.js
diff --git a/app/Resources/static/themes/material/js/shortcuts/main.js b/app/Resources/static/themes/material/js/shortcuts/main.js
new file mode 100644 (file)
index 0000000..ccd3c92
--- /dev/null
@@ -0,0 +1,13 @@
+/* Actions */
+Mousetrap.bind('g n', () => {
+    $('#nav-btn-add').trigger('click');
+});
+
+Mousetrap.bind('esc', () => {
+    $('.close').trigger('click');
+});
+
+// Display the first element of the current view
+Mousetrap.bind('right', () => {
+    $('ul.data li:first-child span.dot-ellipsis a')[0].click();
+});