- Given a page with a highlighted node at the end of the page. E.g. https://www.mediawiki.org/w/index.php?title=OOjs/Events&oldid=1090830 ends with a <syntaxhighlight> block.
- Open another tab and copy a simple heading and line of text into the clipboard.
- Back to the main tab, focus the slug and paste.
Unexpected:
- Content area is visually distorted (left margin is gone) due to the surface documentNode having been replaced with a strange subtree. There's no uncaught exception. Reproducible on mediawiki.org and latest git master.
Before pasting:
After pasting:
Note that the documentNode element has disappeared (unwrapped?), and in the user interface the margin on the left side is no longer present.
Attachment:

