Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix the decision condition in dismissOnTargetWindowBlur to handle the… #26930

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🕵 fluentuiv8 Open the Visual Regressions report to inspect the 2 screenshots

✅ There was 2 screenshots added, 0 screenshots removed, 1043 screenshots unchanged, 0 screenshots with different dimensions and 0 screenshots with visible difference.

unknown 2 screenshots
Image Name Diff(in Pixels) Image Type
Pivot - Overflow.Tabs - RTL.Narrow - Last tab selected.chromium.png 0 Added
Pivot - Overflow.Tabs - RTL.Narrow - Overflow menu.chromium.png 0 Added

"type": "patch",
"comment": "fix the decision condition in dismissOnTargetWindowBlur to handle the case that clicking inside an iframe.",
"packageName": "@fluentui/react",
"email": "[email protected]",
"dependentChangeType": "patch"
}
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,7 @@ function useDismissHandlers(
if (
((preventDismissOnEvent && !preventDismissOnEvent(ev)) ||
(!preventDismissOnEvent && !preventDismissOnLostFocus)) &&
!targetWindow?.document.hasFocus() &&
(!targetWindow?.document.hasFocus() || ev.target === targetRef.current) &&
ev.relatedTarget === null
) {
onDismiss?.(ev);
Expand Down