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

keyboard: apply correct modifier state #1000

Closed
ph-fritsche opened this issue Jul 21, 2022 · 1 comment · Fixed by #1003
Closed

keyboard: apply correct modifier state #1000

ph-fritsche opened this issue Jul 21, 2022 · 1 comment · Fixed by #1003
Labels
bug Something isn't working released

Comments

@ph-fritsche
Copy link
Member

Reproduction example

https://codesandbox.io/s/userevent-keyboard-modifiers-gt0n61?file=/src/App.test.js

Prerequisites

  1. Render and focus element
  2. Press modifer and other keys

Expected behavior

Modifiers like [ShiftLeft] switch on the appropriate modifier state before keydown and switch off the modifier state before keyup.

Modifier locks like [CapsLock] switch on the modifier state after the keydown and turn off the the modifier state after keyup.

Actual behavior

Shift modifier state is not applied. (shiftKey is applied correctly.)

CapsLock modifier state is switched like a non-lock key.

User-event version

14.3.0

Environment

Testing Library framework:

JS framework:

Test environment:

DOM implementation:

Additional context

No response

@ph-fritsche ph-fritsche added bug Something isn't working needs assessment This needs to be looked at by a team member and removed needs assessment This needs to be looked at by a team member labels Jul 21, 2022
@github-actions
Copy link

github-actions bot commented Aug 2, 2022

🎉 This issue has been resolved in version 14.4.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working released
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant