Skip to content

Commit

Permalink
fix: hide modals when pressing Esc, fixes #8988 (#8994)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jesse White authored and torkelo committed Aug 7, 2017
1 parent c0b0a54 commit f547c93
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions public/app/core/services/keybindingSrv.ts
Expand Up @@ -214,12 +214,8 @@ export class KeybindingSrv {
if (popups.length > 0) {
return;
}
// close modals
var modalData = $(".modal").data();
if (modalData && modalData.$scope && modalData.$scope.dismiss) {
modalData.$scope.dismiss();
}

scope.appEvent('hide-modal');
scope.appEvent('hide-dash-editor');
scope.appEvent('panel-change-view', {fullscreen: false, edit: false});
});
Expand Down

0 comments on commit f547c93

Please sign in to comment.