mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-22 01:25:38 -05:00
adjust modals for title bar (#5648)
This commit is contained in:
@@ -22,9 +22,9 @@ import { localize } from 'vs/nls';
|
||||
import { MessageLevel } from 'sql/workbench/api/common/sqlExtHostTypes';
|
||||
import * as os from 'os';
|
||||
import { IThemeService } from 'vs/platform/theme/common/themeService';
|
||||
import { ILayoutService } from 'vs/platform/layout/browser/layoutService';
|
||||
import { isUndefinedOrNull } from 'vs/base/common/types';
|
||||
import { ILogService } from 'vs/platform/log/common/log';
|
||||
import { IWorkbenchLayoutService } from 'vs/workbench/services/layout/browser/layoutService';
|
||||
|
||||
export const MODAL_SHOWING_KEY = 'modalShowing';
|
||||
export const MODAL_SHOWING_CONTEXT = new RawContextKey<Array<string>>(MODAL_SHOWING_KEY, []);
|
||||
@@ -143,7 +143,7 @@ export abstract class Modal extends Disposable implements IThemable {
|
||||
private _title: string,
|
||||
private _name: string,
|
||||
private _telemetryService: ITelemetryService,
|
||||
protected layoutService: ILayoutService,
|
||||
protected layoutService: IWorkbenchLayoutService,
|
||||
protected _clipboardService: IClipboardService,
|
||||
protected _themeService: IThemeService,
|
||||
protected logService: ILogService,
|
||||
@@ -172,6 +172,8 @@ export abstract class Modal extends Disposable implements IThemable {
|
||||
}
|
||||
|
||||
this._bodyContainer = DOM.$(`.${builderClass}`, { role: 'dialog', 'aria-label': this._title });
|
||||
const top = this.layoutService.getTitleBarOffset();
|
||||
this._bodyContainer.style.top = `${top}px`;
|
||||
this._modalDialog = DOM.append(this._bodyContainer, DOM.$('.modal-dialog', { role: 'document' }));
|
||||
const modalContent = DOM.append(this._modalDialog, DOM.$('.modal-content'));
|
||||
|
||||
|
||||
@@ -30,9 +30,9 @@ import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding';
|
||||
import { IConfigurationService } from 'vs/platform/configuration/common/configuration';
|
||||
import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation';
|
||||
import { append, $ } from 'vs/base/browser/dom';
|
||||
import { ILayoutService } from 'vs/platform/layout/browser/layoutService';
|
||||
import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService';
|
||||
import { ILogService } from 'vs/platform/log/common/log';
|
||||
import { IWorkbenchLayoutService } from 'vs/workbench/services/layout/browser/layoutService';
|
||||
|
||||
export class CategoryView extends ViewletPanel {
|
||||
|
||||
@@ -87,7 +87,7 @@ export class OptionsDialog extends Modal {
|
||||
title: string,
|
||||
name: string,
|
||||
options: IOptionsDialogOptions,
|
||||
@ILayoutService layoutService: ILayoutService,
|
||||
@IWorkbenchLayoutService layoutService: IWorkbenchLayoutService,
|
||||
@IThemeService themeService: IThemeService,
|
||||
@IContextViewService private _contextViewService: IContextViewService,
|
||||
@IInstantiationService private _instantiationService: IInstantiationService,
|
||||
|
||||
Reference in New Issue
Block a user