Releases: testing-library/user-event
Releases · testing-library/user-event
v14.0.0-beta.6
v14.0.0-beta.5
v14.0.0-beta.4
v14.0.0-beta.3
v14.0.0-beta.2
v14.0.0-beta.1
14.0.0-beta.1 (2021-11-28)
⚠ BREAKING CHANGES
- upload:
init
parameter has been removed fromuserEvent.upload
. - APIs always return a Promise.
- paste: The
userEvent.paste
API has new parameters. {ctrl}
,{del}
,{esc}
no longer describe a key. Use{Control}
,{Delete}
,{Escape}
instead.{alt}
,{ctrl}
,{meta}
,{shift}
no longer imply not releasing the key. Use{Alt>}
,{Control>}
,{Meta>}
,{Shift>}
instead.init
parameter has been removed from these APIs:userEvent.click
userEvent.dblClick
userEvent.tripleClick
userEvent.hover
userEvent.unhover
userEvent.selectOptions
userEvent.deselectOptions
- Behavior for special key descriptor
{selectall}
has been removed. - Support for
keyCode
property on keyboard events has been removed. - clear: An error is thrown when calling
userEvent.clear
on an element which is not editable. - clear: An error is thrown when event handlers prevent
userEvent.clear
from focussing/selecting content. - tab: The
focusTrap
option has been removed fromuserEvent.tab()
. - pointer:
userEvent.type
does no longer move the cursor
if used withskipClick=false
and withoutinitialSelectionStart
. - The implementation of pointer related APIs was replaced.
This might break tests relying on unintended side-effects of the previous implementation. - Support for node 10 was removed as it reached its end-of-life.
Features
- add
pointer
API (#750) (c12ee44) - add
setup
API (#746) (719ba03) - add
userEvent.copy
anduserEvent.cut
(#787) (8727a2d) - add
userEvent.tripleClick
API (#773) (0badabd) - apply modifier keys in pointer events (#751) (e33eb86)
- async APIs (#790) (86860cc)
- keep track of document state in UI (#747) (73e62d0)
- keyboard: add
[Tab]
support (#767) (87470ff) - keyboard: select all per
{Control}+[KeyA]
(#774) (ea9b18a) - pointer: change selection per pointer (#763) (17fb8b1)
- remove support for user provided
MouseEventInit
(#784) (56ebf7d) - paste: replace
userEvent.paste
(#785) (f8fe217) - clear: rewrite
userEvent.clear
API (#779) (1cda1b1) - rewrite selection handling (#776) (968c2c4)
- upload: replace element properties (#794) (543eadb)
Bug Fixes
- create MouseEvents per
createEvent
(#781) (da5b5b7) - keyboard: parse keyboard input without nesting (#793) (fafa677)
- keyboard: set
KeyboardEvent.charCode
onkeypress
(#771) (55e194a) - maintain cursor position on controlled component (#765) (8f203cc)
- prepare document in setup (#753) (65be675)
- remove deprecated keyboard features (#780) (45dc39a)
- remove legacy modifier implementations (#783) (caea162)
- replace pointer implementations (#754) (c04f79b)
- reset UI selection on setter (#770) (2733d10)
- tab: remove
focusTrap
option (#772) (a0412c0)
Miscellaneous Chores
v14.0.0-alpha.18
v14.0.0-alpha.17
14.0.0-alpha.17 (2021-11-25)
⚠ BREAKING CHANGES
- upload:
init
parameter has been removed fromuserEvent.upload
.