user-event icon indicating copy to clipboard operation
user-event copied to clipboard

feat(keyboard): support shadow DOM in tab order

Open ph-fritsche opened this issue 3 years ago • 9 comments

What:

Consider focusable elements in shadow trees.

Why: #1026

Checklist:

  • [x] Tests
  • [ ] Ready to be merged

on top of #1038 -- should be rebased once that is merged

ph-fritsche avatar Aug 19 '22 11:08 ph-fritsche

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 77563745622a1be6e18772da0aa85650fd379e69:

Sandbox Source
userEvent-dom Configuration
userEvent-react Configuration

codesandbox-ci[bot] avatar Aug 19 '22 11:08 codesandbox-ci[bot]

Changes to be reviewed here: https://github.com/testing-library/user-event/pull/1040/commits/b3222206f7b4c8dd66d01955be47cdb2f71dd8a4..HEAD

ph-fritsche avatar Aug 19 '22 11:08 ph-fritsche

Codecov Report

Merging #1040 (7756374) into main (1aa2027) will not change coverage. The diff coverage is 100.00%.

@@            Coverage Diff            @@
##              main     #1040   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           88        87    -1     
  Lines         2061      2099   +38     
  Branches       691       713   +22     
=========================================
+ Hits          2061      2099   +38     
Impacted Files Coverage Δ
src/clipboard/copy.ts 100.00% <100.00%> (ø)
src/clipboard/cut.ts 100.00% <100.00%> (ø)
src/clipboard/paste.ts 100.00% <100.00%> (ø)
src/event/behavior/click.ts 100.00% <100.00%> (ø)
src/event/behavior/keydown.ts 100.00% <100.00%> (ø)
src/event/focus.ts 100.00% <100.00%> (ø)
src/event/selection/updateSelectionOnFocus.ts 100.00% <100.00%> (ø)
src/utils/focus/focusable.ts 100.00% <100.00%> (ø)
src/utils/focus/getActiveElement.ts 100.00% <100.00%> (ø)
src/utils/focus/getTabDestination.ts 100.00% <100.00%> (ø)

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

codecov[bot] avatar Aug 19 '22 11:08 codecov[bot]

@Christian24 This should complete support for focus handling on shadow DOM

ph-fritsche avatar Aug 19 '22 12:08 ph-fritsche

Thanks @ph-fritsche! Really looking forward to seeing this in the next release.

Christian24 avatar Aug 19 '22 16:08 Christian24

@ph-fritsche @Christian24 is there anything that can be done to get this, #1038 and #1033 back on the table? I would be glad to help or find someone from my team who can.

ysgit avatar Nov 08 '23 10:11 ysgit

I would love to get this merged. I think @ph-fritsche wanted to finish work on #1019 first though. I could potentially use this for something else I have been working on myself too. I am not a maintainer here though, so I cannot really comment on their goals.

Christian24 avatar Nov 08 '23 11:11 Christian24