Skip to content

Element in-view: Fix circular definition #1918

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

yezhizhen
Copy link
Contributor

@yezhizhen yezhizhen commented Aug 18, 2025

Currently, the definition of element is in-view needs to compute pointer-interactive paint tree, whose step 4 computes in-view center point, which again requires element is in-view!

But actually we can safely remove the in-view requirement of in-view center point, as step 5 of compute pointer-interactive paint tree feed center point to elementsFromPoint, which simply return a empty sequence if input is not in viewport.

As a result, we have empty pointer-interactive paint tree meaning that element is not in-view.


Preview | Diff

@yezhizhen yezhizhen marked this pull request as draft August 18, 2025 03:10
Signed-off-by: Euclid Ye <euclid.ye@huawei.com>
@yezhizhen yezhizhen force-pushed the fix-circular-definition branch from dabf8af to 2850417 Compare August 18, 2025 03:16
@yezhizhen yezhizhen marked this pull request as ready for review August 18, 2025 03:16
@yezhizhen
Copy link
Contributor Author

cc @xiaochengh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant