fix floating menu example
This commit is contained in:
@@ -255,9 +255,8 @@ export default class Editor {
|
||||
|
||||
registerPlugin(plugin = null) {
|
||||
if (plugin) {
|
||||
this.plugins = this.plugins.concat([plugin])
|
||||
this.state = this.state.reconfigure({
|
||||
plugins: this.plugins,
|
||||
plugins: this.state.plugins.concat([plugin]),
|
||||
})
|
||||
this.view.updateState(this.state)
|
||||
}
|
||||
|
||||
@@ -28,7 +28,7 @@ class Toolbar {
|
||||
|
||||
const isActive = currentDom.node.innerHTML === '<br>'
|
||||
&& currentDom.node.tagName === 'P'
|
||||
// && currentDom.node.parentNode === view.dom
|
||||
&& currentDom.node.parentNode === view.dom
|
||||
|
||||
if (!isActive) {
|
||||
this.hide()
|
||||
|
||||
Reference in New Issue
Block a user