Docs/toc undo fix (#2484)
* Update Component.jsx
Added `transaction.setMeta("addToHistory", false)` to fix undo bug when deleting headings
* Update Component.vue
Added `transaction.setMeta("addToHistory", false)` to fix undo bug when deleting headings
This commit is contained in:
@@ -28,6 +28,7 @@ export default ({ editor }) => {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
transaction.setMeta("addToHistory", false)
|
||||||
transaction.setMeta('preventUpdate', true)
|
transaction.setMeta('preventUpdate', true)
|
||||||
|
|
||||||
editor.view.dispatch(transaction)
|
editor.view.dispatch(transaction)
|
||||||
|
|||||||
@@ -55,6 +55,7 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
transaction.setMeta("addToHistory", false)
|
||||||
transaction.setMeta('preventUpdate', true)
|
transaction.setMeta('preventUpdate', true)
|
||||||
|
|
||||||
this.editor.view.dispatch(transaction)
|
this.editor.view.dispatch(transaction)
|
||||||
|
|||||||
Reference in New Issue
Block a user