mirror of
https://github.com/ianstormtaylor/slate.git
synced 2025-08-19 13:41:19 +02:00
fix unwrapBlockAtRange disorder (#2512)
This commit is contained in:
@@ -1110,7 +1110,7 @@ Commands.unwrapBlockAtRange = (editor, range, properties) => {
|
|||||||
wrappers.forEach(block => {
|
wrappers.forEach(block => {
|
||||||
const first = block.nodes.first()
|
const first = block.nodes.first()
|
||||||
const last = block.nodes.last()
|
const last = block.nodes.last()
|
||||||
const parent = document.getParent(block.key)
|
const parent = editor.value.document.getParent(block.key)
|
||||||
const index = parent.nodes.indexOf(block)
|
const index = parent.nodes.indexOf(block)
|
||||||
|
|
||||||
const children = block.nodes.filter(child => {
|
const children = block.nodes.filter(child => {
|
||||||
|
Reference in New Issue
Block a user