File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -306,6 +306,9 @@ export class HoverPaneController implements HoverPaneControllerInterface {
306306 }
307307 }
308308
309+ left += window . scrollX ;
310+ top += window . scrollY ;
311+
309312 return { left, top } ;
310313 }
311314
@@ -465,6 +468,10 @@ export class HoverPaneController implements HoverPaneControllerInterface {
465468 // Wait for the state update to render the hover pane
466469 await this . host . updateComplete ;
467470
471+ // Ensure the hover pane element is still in the document before showing,
472+ // as it might have been removed by the previous update.
473+ if ( ! this . hoverPane ?. isConnected ) return ;
474+
468475 this . hoverPane ?. showPopover ?.( ) ;
469476 await new Promise ( resolve => {
470477 // Pane sizes aren't accurate until next frame
You can’t perform that action at this time.
0 commit comments