mirror of
https://github.com/ianstormtaylor/slate.git
synced 2025-09-08 06:00:40 +02:00
fix void copying to attach to the right dom element
This commit is contained in:
@@ -271,7 +271,7 @@ function Plugin(options = {}) {
|
|||||||
const node = findDOMNode(isVoidBlock ? endBlock : endInline)
|
const node = findDOMNode(isVoidBlock ? endBlock : endInline)
|
||||||
r.setEndAfter(node)
|
r.setEndAfter(node)
|
||||||
contents = r.cloneContents()
|
contents = r.cloneContents()
|
||||||
attach = node
|
attach = contents.childNodes[contents.childNodes.length - 1].firstChild
|
||||||
}
|
}
|
||||||
|
|
||||||
// Remove any zero-width space spans from the cloned DOM so that they don't
|
// Remove any zero-width space spans from the cloned DOM so that they don't
|
||||||
|
Reference in New Issue
Block a user