Skip to content

Conversation

@ph-fritsche
Copy link
Member

What:

Delete characters from an element with element.value.length === element.maxLength.

Why:

Closes #908

How:

Only skip input if the InputEvent.data is not an empty string.

Checklist:

  • Tests
  • Ready to be merged

@codesandbox-ci
Copy link

codesandbox-ci bot commented Apr 6, 2022

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit bf1a10b:

Sandbox Source
userEvent-dom Configuration
userEvent-react Configuration
userEvent fail if text field content is max length at clear event Issue #908

@codecov
Copy link

codecov bot commented Apr 6, 2022

Codecov Report

Merging #909 (bf1a10b) into main (6d36828) will not change coverage.
The diff coverage is 100.00%.

@@            Coverage Diff            @@
##              main      #909   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           85        85           
  Lines         1778      1782    +4     
  Branches       657       641   -16     
=========================================
+ Hits          1778      1782    +4     
Impacted Files Coverage Δ
src/keyboard/keyboardAction.ts 100.00% <100.00%> (ø)
src/options.ts 100.00% <100.00%> (ø)
src/pointer/pointerAction.ts 100.00% <100.00%> (ø)
src/utils/edit/input.ts 100.00% <100.00%> (ø)
src/utils/misc/wait.ts 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 627a5cf...bf1a10b. Read the comment docs.

@ph-fritsche ph-fritsche merged commit f5049c4 into main Apr 11, 2022
@ph-fritsche ph-fritsche deleted the fix-908 branch April 11, 2022 07:55
@github-actions
Copy link

🎉 This PR is included in version 14.1.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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

clear userEvent fails on textfield with defined maxLength which is filled max length content after upgrade from v13 to v14.0.4

2 participants