|
@@ -39,7 +39,7 @@ export default function (Alpine) {
|
|
|
}
|
|
|
|
|
|
function crawlSiblingsUp(el, callback) {
|
|
|
- if (el.isSameNode(document.body)) return
|
|
|
+ if (el.isSameNode(document.body) || ! el.parentNode) return
|
|
|
|
|
|
Array.from(el.parentNode.children).forEach(sibling => {
|
|
|
if (! sibling.isSameNode(el)) callback(sibling)
|