Skip to content

Commit 1e15711

Browse files
authored
fix(core): fix puppeteer click signature (#1247)
1 parent 78606b3 commit 1e15711

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

packages/web-integration/src/puppeteer/base-page.ts

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -264,10 +264,14 @@ export class Page<
264264
});
265265
} else {
266266
if (this.interfaceType === 'puppeteer') {
267-
(this.underlyingPage as PuppeteerPage).mouse.click(x, y, {
268-
button,
269-
count,
270-
});
267+
if (button === 'left' && count === 1) {
268+
await (this.underlyingPage as PuppeteerPage).mouse.click(x, y);
269+
} else {
270+
await (this.underlyingPage as PuppeteerPage).mouse.click(x, y, {
271+
button,
272+
count,
273+
});
274+
}
271275
} else if (this.interfaceType === 'playwright') {
272276
(this.underlyingPage as PlaywrightPage).mouse.click(x, y, {
273277
button,

0 commit comments

Comments
 (0)