Skip to content

Commit

Permalink
use listenDOM
Browse files Browse the repository at this point in the history
  • Loading branch information
jhchen committed Oct 23, 2017
1 parent 6a23edd commit 6ba3811
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion core/emitter.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import logger from './logger';

let debug = logger('quill:events');

const EVENTS = ['selectionchange', 'mousedown', 'mouseup'];
const EVENTS = ['selectionchange', 'mousedown', 'mouseup', 'click'];

EVENTS.forEach(function(eventName) {
document.addEventListener(eventName, (...args) => {
Expand Down
2 changes: 1 addition & 1 deletion themes/base.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class BaseTheme extends Theme {
});
}
};
document.body.addEventListener('click', listener);
quill.emitter.listenDOM('click', document.body, listener);
}

addModule(name) {
Expand Down

0 comments on commit 6ba3811

Please sign in to comment.