Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow root on static admin to have multiple keys #157

Merged
merged 12 commits into from
Aug 21, 2018

Conversation

snewcomer
Copy link
Collaborator

@snewcomer snewcomer commented Aug 21, 2018

The root scrollable area can have multiple elements with different observer options. To prevent the first element's options from overriding the rest of the observers in the static administrator (cache to reuse intersection observer instances), we need to ensure that when we want to find a potential match for an element, that we compare the to be added element's observer options and only reuse the instance of the IntersectionObserver iff the element shares the same root and same observer options

@snewcomer snewcomer self-assigned this Aug 21, 2018
The root scrollable area can have multiple elements with different observer options.  To prevent the first element"s options from overriding the rest of the page, we need to ensure that when we want to find a potential match for an element, that we compare the observer options andd only reuse the instance of the IntersectionObserver if the element shares the same root and same observer options
@snewcomer snewcomer force-pushed the sn/sharing-same-root branch 2 times, most recently from 4a7181b to 58ceec4 Compare August 21, 2018 15:07
@snewcomer snewcomer merged commit 5fef666 into master Aug 21, 2018
@snewcomer snewcomer deleted the sn/sharing-same-root branch August 21, 2018 23:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant