File tree Expand file tree Collapse file tree 1 file changed +6
-12
lines changed
packages/react-dom/src/events Expand file tree Collapse file tree 1 file changed +6
-12
lines changed Original file line number Diff line number Diff line change @@ -144,16 +144,13 @@ export function trapBubbledEvent(
144144 if ( ! element ) {
145145 return null ;
146146 }
147+
148+ // Check if interactive and wrap in interactiveUpdates
147149 const dispatch = isInteractiveTopLevelEventType ( topLevelType )
148150 ? dispatchInteractiveEvent
149151 : dispatchEvent ;
150152
151- addEventBubbleListener (
152- element ,
153- getRawEventName ( topLevelType ) ,
154- // Check if interactive and wrap in interactiveUpdates
155- dispatch ,
156- ) ;
153+ addEventBubbleListener ( element , getRawEventName ( topLevelType ) , dispatch ) ;
157154}
158155
159156/**
@@ -172,16 +169,13 @@ export function trapCapturedEvent(
172169 if ( ! element ) {
173170 return null ;
174171 }
172+
173+ // Check if interactive and wrap in interactiveUpdates
175174 const dispatch = isInteractiveTopLevelEventType ( topLevelType )
176175 ? dispatchInteractiveEvent
177176 : dispatchEvent ;
178177
179- addEventCaptureListener (
180- element ,
181- getRawEventName ( topLevelType ) ,
182- // Check if interactive and wrap in interactiveUpdates
183- dispatch ,
184- ) ;
178+ addEventCaptureListener ( element , getRawEventName ( topLevelType ) , dispatch ) ;
185179}
186180
187181function dispatchInteractiveEvent ( nativeEvent ) {
You can’t perform that action at this time.
0 commit comments