File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed
extensions/ql-vscode/src/view/common/SuggestBox Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -106,6 +106,10 @@ export type SuggestBoxProps<
106106 ) => ReactNode ;
107107} ;
108108
109+ const stopClickPropagation = ( e : React . MouseEvent ) => {
110+ e . stopPropagation ( ) ;
111+ } ;
112+
109113export const SuggestBox = <
110114 T extends Option < T > ,
111115 D extends Diagnostic = Diagnostic ,
@@ -196,7 +200,9 @@ export const SuggestBox = <
196200 } , [ disabled ] ) ;
197201
198202 return (
199- < >
203+ // Disabled because the div is used to stop click propagation, it's not a button
204+ // eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions
205+ < div onClick = { stopClickPropagation } >
200206 { renderInputComponent (
201207 getReferenceProps ( {
202208 ref : refs . setReference ,
@@ -270,6 +276,6 @@ export const SuggestBox = <
270276 ) }
271277 </ FloatingPortal >
272278 ) }
273- </ >
279+ </ div >
274280 ) ;
275281} ;
You can’t perform that action at this time.
0 commit comments