-
Notifications
You must be signed in to change notification settings - Fork 55
fix(FocusZone|FocusTrapZone): correctly define current document object of the components #1820
fix(FocusZone|FocusTrapZone): correctly define current document object of the components #1820
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1820 +/- ##
=========================================
Coverage ? 69.56%
=========================================
Files ? 875
Lines ? 7596
Branches ? 2219
=========================================
Hits ? 5284
Misses ? 2304
Partials ? 8
Continue to review full report at Codecov.
|
Looks good to me |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep change makes sense. If this is a bug in the other copy, we need to merge the two asap to stop the branching 😀 or fix the bug in both places.
@davezuko totally agree on keeping consistency between copies. We encountered the bug when had a case of opening another window with components through Update: created a PR microsoft/fluentui#10187 |
Fixes #1817
By replacing
document
togetDocument
fromfocusUtilities
we're making sure that the right document object will be used for correctFocusZone
andFocusTrapZone
function.getDocument
is called with node elementsthis._root._current
and implementation looks like this: