Use overflow widgets dom node for context menus (#213929)

Fixes clipping of custom context menus in embedded editors, such as those in the chat view
This commit is contained in:
Matt Bierner 2024-06-17 14:11:22 -07:00 committed by GitHub
parent 290eb3df07
commit 9eba3ad2fc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -227,7 +227,7 @@ export class ContextMenuController implements IEditorContribution {
// Show menu
this._contextMenuIsBeingShownCount++;
this._contextMenuService.showContextMenu({
domForShadowRoot: useShadowDOM ? this._editor.getDomNode() : undefined,
domForShadowRoot: useShadowDOM ? this._editor.getOverflowWidgetsDomNode() ?? this._editor.getDomNode() : undefined,
getAnchor: () => anchor,