Allow extensions to override stopEvent

This commit is contained in:
Jason Varga
2019-04-09 12:54:37 -04:00
parent 24f61e02be
commit fb8a9dd764

View File

@@ -108,6 +108,10 @@ export default class ComponentView {
// disable (almost) all prosemirror event listener for node views
stopEvent(event) {
if (typeof this.extension.stopEvent === 'function') {
return this.extension.stopEvent(event)
}
const isPaste = event.type === 'paste'
const draggable = !!this.extension.schema.draggable