File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -282,12 +282,13 @@ const Tooltip = ({
282282 if ( ! show ) {
283283 return
284284 }
285- const anchorById = document . querySelector < HTMLElement > ( `[id='${ anchorId } ']` )
286- const anchors = [ anchorById , ...anchorsBySelect ]
287- if ( anchors . some ( ( anchor ) => anchor ?. contains ( event . target as HTMLElement ) ) ) {
285+ const target = event . target as HTMLElement
286+ if ( tooltipRef . current ?. contains ( target ) ) {
288287 return
289288 }
290- if ( tooltipRef . current ?. contains ( event . target as HTMLElement ) ) {
289+ const anchorById = document . querySelector < HTMLElement > ( `[id='${ anchorId } ']` )
290+ const anchors = [ anchorById , ...anchorsBySelect ]
291+ if ( anchors . some ( ( anchor ) => anchor ?. contains ( target ) ) ) {
291292 return
292293 }
293294 handleShow ( false )
You can’t perform that action at this time.
0 commit comments