Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Attach QP to body but position at top of main panel #11054

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion packages/monaco/src/browser/monaco-quick-input-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,9 @@ export class MonacoQuickInputImplementation implements IQuickInputService {
this.initContainer();
this.initController();
this.quickAccess = new QuickAccessController(this, StandaloneServices.get(IInstantiationService));
this.controller.onShow(() => {
this.container.style.top = this.shell.mainPanel.node.getBoundingClientRect().top + 'px';
});
}

setContextKey(key: string | undefined): void {
Expand Down Expand Up @@ -156,7 +159,7 @@ export class MonacoQuickInputImplementation implements IQuickInputService {
private initContainer(): void {
const container = this.container = document.createElement('div');
container.id = 'quick-input-container';
this.shell.mainPanel.node.appendChild(this.container);
document.body.appendChild(this.container);
}

private initController(): void {
Expand Down