Skip to content

Commit

Permalink
Revise comment
Browse files Browse the repository at this point in the history
  • Loading branch information
stokesman committed Sep 5, 2023
1 parent df1e700 commit 0608f43
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions packages/components/src/modal/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -181,10 +181,7 @@ function UnforwardedModal(
onPointerDown: ( event ) => {
if ( event.isPrimary && event.target === event.currentTarget ) {
pressTarget = event.target;
// Avoids loss of focus yet also leaves `useFocusOutside`
// practically useless with its only potential trigger being
// programmatic focus movement. TODO opt for either removing
// the hook or enhancing it such that this isn't needed.
// Avoids focus changing so that focus return works as expected.
event.preventDefault();
}
},
Expand Down

0 comments on commit 0608f43

Please sign in to comment.