Skip to content

Commit

Permalink
fix: remove viewport conditions for waitForSelector
Browse files Browse the repository at this point in the history
  • Loading branch information
jrandolf committed Oct 10, 2022
1 parent a032583 commit 27f8578
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions packages/puppeteer-core/src/injected/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,5 @@ export const checkVisibility = (

function isBoundingBoxVisible(element: Element): boolean {
const rect = element.getBoundingClientRect();
return (
rect.width > 0 &&
rect.height > 0 &&
rect.right > 0 &&
rect.bottom > 0 &&
rect.left < self.innerWidth &&
rect.top < self.innerHeight
);
return rect.width > 0 && rect.height > 0 && rect.right > 0 && rect.bottom > 0;
}

0 comments on commit 27f8578

Please sign in to comment.