From 42c052d21b44605d2c7d356190e51749f9614c64 Mon Sep 17 00:00:00 2001 From: cpradio Date: Sun, 31 Aug 2014 21:56:38 -0400 Subject: [PATCH] FIX: Readd the dismiss keybindings https://meta.discourse.org/t/new-updated-bar-and-dismiss-new-button-unreachable-by-keyboard/18946/10?u=cpradio --- .../discourse/lib/keyboard_shortcuts.js | 22 ++++++++++--------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/app/assets/javascripts/discourse/lib/keyboard_shortcuts.js b/app/assets/javascripts/discourse/lib/keyboard_shortcuts.js index 95e2a41574d..08ce9a2ebc2 100644 --- a/app/assets/javascripts/discourse/lib/keyboard_shortcuts.js +++ b/app/assets/javascripts/discourse/lib/keyboard_shortcuts.js @@ -32,16 +32,18 @@ Discourse.KeyboardShortcuts = Ember.Object.createWithMixins({ // star topic 'f': '#topic-footer-buttons button.star, .topic-list tr.topic-list-item.selected a.star', - 'm m': 'div.notification-options li[data-id="0"] a', // mark topic as muted - 'm r': 'div.notification-options li[data-id="1"] a', // mark topic as regular - 'm t': 'div.notification-options li[data-id="2"] a', // mark topic as tracking - 'm w': 'div.notification-options li[data-id="3"] a', // mark topic as watching - '.': '.alert.alert-info.clickable', // show incoming/updated topics - 'n': '#user-notifications', // open notifications menu - 'o,enter': '.topic-list tr.selected a.title', // open selected topic - 'shift+r': '#topic-footer-buttons button.create', // reply to topic - 'shift+s': '#topic-footer-buttons button.share', // share topic - 's': '.topic-post.selected a.post-date' // share post + 'm m': 'div.notification-options li[data-id="0"] a', // mark topic as muted + 'm r': 'div.notification-options li[data-id="1"] a', // mark topic as regular + 'm t': 'div.notification-options li[data-id="2"] a', // mark topic as tracking + 'm w': 'div.notification-options li[data-id="3"] a', // mark topic as watching + 'x r': '#dismiss-new,#dismiss-new-top,#dismiss-posts,#dismiss-posts-top', // dismiss new/posts + 'x t': '#dismiss-topics,#dismiss-topics-top', //dismiss topics + '.': '.alert.alert-info.clickable', // show incoming/updated topics + 'n': '#user-notifications', // open notifications menu + 'o,enter': '.topic-list tr.selected a.title', // open selected topic + 'shift+r': '#topic-footer-buttons button.create', // reply to topic + 'shift+s': '#topic-footer-buttons button.share', // share topic + 's': '.topic-post.selected a.post-date' // share post }, FUNCTION_BINDINGS: {