We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ef9097b commit 585c446Copy full SHA for 585c446
app/app/components/section/base-editor-inline.js
@@ -48,7 +48,11 @@ export default Ember.Component.extend({
48
49
didRender() {
50
let msContainer = document.getElementById(this.get('containerId'));
51
- let mousetrap = new Mousetrap(msContainer);
+ let mousetrap = this.get('mousetrap');
52
+
53
+ if (is.null(mousetrap)) {
54
+ mousetrap = new Mousetrap(msContainer);
55
+ }
56
57
mousetrap.bind('esc', () => {
58
this.send('onCancel');
@@ -68,7 +72,6 @@ export default Ember.Component.extend({
68
72
69
73
willDestroyElement() {
70
74
let drop = this.get('drop');
71
-
75
if (is.not.null(drop)) {
76
drop.destroy();
77
}
0 commit comments