Skip to content
This repository was archived by the owner on Mar 4, 2020. It is now read-only.

fix(Popup): Move trapFocus and autoFocus to props from accessibility behaviors#1565

Merged
sophieH29 merged 15 commits intomasterfrom
fix/popup-move-focus-trap-to-props
Jul 11, 2019
Merged

fix(Popup): Move trapFocus and autoFocus to props from accessibility behaviors#1565
sophieH29 merged 15 commits intomasterfrom
fix/popup-move-focus-trap-to-props

Conversation

@sophieH29
Copy link
Contributor

@sophieH29 sophieH29 commented Jul 1, 2019

closes #1493

BREAKING CHANGES

  • deleted popupFocusTrapBehavior. trapFocus prop added to Popup.
  • deleted popupAutoFocusBehavior. autoFocus prop added to Popup.

Improvements

  • FocusTrapZone and AutoFocusZone are now integrated into PopupContent without rendering an additional div.
  • trapFocus can be set to popup using true value or an object of FocusTrapZoneProps
  • autoFocus can be set to popup using true value or an object of AutoFocusZoneProps
  • warn user of using combination of inline and trapFocus props. Or autoFocus for non-inline Popup.

@sophieH29 sophieH29 added ⚙️ enhancement New feature or request 🚀 ready for review 🧰 fix Introduces fix for broken behavior. accessibility All the Accessibility tasks and bugs should be tagged with this. labels Jul 1, 2019
@sophieH29 sophieH29 self-assigned this Jul 1, 2019
@codecov
Copy link

codecov bot commented Jul 1, 2019

Codecov Report

Merging #1565 into master will decrease coverage by 0.18%.
The diff coverage is 79.16%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1565      +/-   ##
==========================================
- Coverage   71.47%   71.28%   -0.19%     
==========================================
  Files         848      846       -2     
  Lines        6938     6938              
  Branches     1983     2002      +19     
==========================================
- Hits         4959     4946      -13     
- Misses       1973     1986      +13     
  Partials        6        6
Impacted Files Coverage Δ
...kages/react/src/components/Toolbar/ToolbarItem.tsx 48.14% <ø> (ø) ⬆️
...hemes/teams/components/Popup/popupContentStyles.ts 20% <ø> (+3.33%) ⬆️
...b/accessibility/Behaviors/Dialog/dialogBehavior.ts 100% <100%> (ø) ⬆️
...lib/accessibility/Behaviors/Popup/popupBehavior.ts 96.15% <100%> (+0.32%) ⬆️
...ckages/react/src/components/Popup/PopupContent.tsx 80.95% <75%> (-9.96%) ⬇️
packages/react/src/components/Popup/Popup.tsx 66.44% <77.77%> (-1.71%) ⬇️
...ages/react/test/specs/behaviors/testDefinitions.ts 87.39% <0%> (-4.07%) ⬇️

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 59501c6...fde7c0d. Read the comment docs.

@sophieH29 sophieH29 changed the title fix(Popup): Move trapFocus and autoFocus to props from accessibility behaviors [DO NOT MERGE] fix(Popup): Move trapFocus and autoFocus to props from accessibility behaviors Jul 9, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

accessibility All the Accessibility tasks and bugs should be tagged with this. ⚙️ enhancement New feature or request 🧰 fix Introduces fix for broken behavior. 🚀 ready for review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Inline Popup not Accessible

2 participants