Skip to content

Conversation

@arturbien
Copy link
Contributor

@arturbien arturbien commented Feb 2, 2022

fixes #860

The problem was, that .documentElement.contains(shadowRootChild) always returns false for shadow dom elements even if they're attached.

Usage of .isConnected method fixes this problem with a fallback to the previous logic for IE (as IE doesn't support .isConnected method)

@arturbien arturbien force-pushed the fix/is-target-attached-logic branch from 55e5b32 to 21d86f2 Compare February 2, 2022 11:52
@arturbien
Copy link
Contributor Author

@stipsan some checks are failing but I believe it's not due to my changes.

I'll be really grateful for a quick review 🤓

Copy link
Member

@stipsan stipsan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey, thanks for your PR! You can fix the bundlesize error by modifying this to 3.3: https://github.com/stipsan/scroll-into-view-if-needed/blob/47f982cb87c8b6b26c4ce935b299b443d2bfc8da/package.json#L92
Probably just a rounding error :)
And the browsertsack error is probably due to you contributing from a fork 🤔

@stipsan stipsan merged commit 829c6af into scroll-into-view:master Feb 2, 2022
@stipsan
Copy link
Member

stipsan commented Feb 2, 2022

🎉 This PR is included in version 2.2.29 🎉

The release is available on:

Your semantic-release bot 📦🚀

@arturbien
Copy link
Contributor Author

Thanks for quick response. Just realized this PR was the 1000th PR merged. 🎉

@stipsan
Copy link
Member

stipsan commented Feb 2, 2022

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Shadow DOM support?

2 participants