From c66a23e91db9edb5a2cf79f01d550568a00c052c Mon Sep 17 00:00:00 2001 From: KHeo Date: Wed, 30 Mar 2022 16:18:26 +0900 Subject: [PATCH 1/7] fix: `cy.type()` should work with Firefox 98+ --- .../driver/src/cy/commands/actions/type.ts | 32 ++++++++++++++++--- packages/driver/src/cypress.ts | 1 + packages/driver/src/cypress/browser.ts | 1 + 3 files changed, 29 insertions(+), 5 deletions(-) diff --git a/packages/driver/src/cy/commands/actions/type.ts b/packages/driver/src/cy/commands/actions/type.ts index 08e8e413c8..1d81551ff0 100644 --- a/packages/driver/src/cy/commands/actions/type.ts +++ b/packages/driver/src/cy/commands/actions/type.ts @@ -334,9 +334,16 @@ export default function (Commands, Cypress, cy, state, config) { } if ( - // Firefox sends a click event when the Space key is pressed. - // We don't want to send it twice. - !Cypress.isBrowser('firefox') && + ( + // Before Firefox 98, + // Firefox sends a click event when the Space key is pressed. + // We don't want to send it twice. + !Cypress.isBrowser('firefox') || + // After Firefox 98, + // it sends a click event automatically if the element is a