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

fix: remove viewport conditions in waitForSelector #9087

Merged
merged 1 commit into from Oct 10, 2022
Merged

fix: remove viewport conditions in waitForSelector #9087

merged 1 commit into from Oct 10, 2022

Conversation

jrandolf
Copy link
Contributor

@jrandolf jrandolf commented Oct 9, 2022

This PR removes the viewport conditions in waitForSelector.

See discussion: #8954 (comment)

@joakimgunst
Copy link

Please see my comment here: #8954 (comment)

@jrandolf jrandolf changed the title fix: use scrollHeight and scrollWidth fix: remove viewport conditions in waitForSelector Oct 10, 2022
rect.left < self.innerWidth &&
rect.top < self.innerHeight
);
return rect.width > 0 && rect.height > 0 && rect.right > 0 && rect.bottom > 0;
Copy link

Choose a reason for hiding this comment

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

Shouldn't this part of the expression have also been removed?

rect.right > 0 && rect.bottom > 0

For example, rect.bottom is negative if the element is above the current viewport.

Choose a reason for hiding this comment

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

I was just writing a bug report while I saw this comment - submitted #9232 anyway so others can find this more easily :)

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.

None yet

5 participants