fix bug in in node views, fix #652

This commit is contained in:
Philipp Kühn
2020-04-02 09:14:05 +02:00
parent 6044536821
commit 9567519f8a
4 changed files with 2 additions and 11 deletions

View File

@@ -17,12 +17,6 @@ export default class Placeholder extends Extension {
}
}
get update() {
return view => {
view.updateState(view.state)
}
}
get plugins() {
return [
new Plugin({

View File

@@ -44,6 +44,7 @@ export default class ComponentView {
if (typeof this.extension.setSelection === 'function') {
this.setSelection = this.extension.setSelection
}
if (typeof this.extension.update === 'function') {
this.update = this.extension.update
}

View File

@@ -23,10 +23,6 @@ export default class Extension {
return 'extension'
}
get update() {
return () => {}
}
get defaultOptions() {
return {}
}

View File

@@ -31,7 +31,7 @@ export default class ExtensionManager {
Object.assign(obj, { [prop]: value })
if (changed) {
extension.update(view)
view.updateState(view.state)
}
return true