Skip to content

cy.type accept keyboard shortcut syntax to release modifiers #5694

@kuceb

Description

@kuceb

currently, in order to simulate the user pressing "ctrl+bhello world", you would need two cy.type commands if you want to simulate releasing the ctrl key after the b:

cy.get('...').type('{ctrl}b').type('hello world')

We should introduce a new syntax {<mod>+<key>} to specify you want to press-and-release the ctrl key after one (or more) key:

cy.get('...').type('{ctrl+b}hello world')

Metadata

Metadata

Assignees

No one assigned

    Labels

    pkg/driverThis is due to an issue in the packages/driver directorytopic: cy.type ⌨️type: enhancementRequested enhancement of existing feature

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions