Adding properties grid enhancements in execution plan (#20208)

* init push

* Fixing properties in plan comparison

* Add long Text Cell viewer

* Disabling auto edit by default

* Removing text editor
This commit is contained in:
Aasim Khan
2022-08-11 11:22:12 -07:00
committed by GitHub
parent 9ec68087ac
commit a7a337f063
7 changed files with 110 additions and 19 deletions

View File

@@ -15,6 +15,8 @@ import { InternalExecutionPlanElement } from 'sql/workbench/contrib/executionPla
import { executionPlanComparisonPropertiesDifferent, executionPlanComparisonPropertiesUpArrow, executionPlanComparisonPropertiesDownArrow } from 'sql/workbench/contrib/executionPlan/browser/constants';
import * as sqlExtHostType from 'sql/workbench/api/common/sqlExtHostTypes';
import { TextWithIconColumn } from 'sql/base/browser/ui/table/plugins/textWithIconColumn';
import { IContextMenuService } from 'vs/platform/contextview/browser/contextView';
import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation';
export enum ExecutionPlanCompareOrientation {
Horizontal = 'horizontal',
@@ -37,8 +39,10 @@ export class ExecutionPlanComparisonPropertiesView extends ExecutionPlanProperti
public constructor(
parentContainer: HTMLElement,
@IThemeService themeService: IThemeService,
@IInstantiationService instantiationService: IInstantiationService,
@IContextMenuService contextMenuService: IContextMenuService
) {
super(parentContainer, themeService);
super(parentContainer, themeService, instantiationService, contextMenuService);
this._model = <ExecutionPlanComparisonPropertiesViewModel>{};
this._parentContainer.style.display = 'none';
const header = DOM.$('.compare-operation-name');
@@ -128,30 +132,27 @@ export class ExecutionPlanComparisonPropertiesView extends ExecutionPlanProperti
name: localize('nodePropertyViewNameNameColumnHeader', "Name"),
field: 'name',
width: 200,
editor: Slick.Editors.Text,
headerCssClass: 'prop-table-header',
formatter: textFormatter
});
columns.push({
id: 'value',
id: 'value1',
name: getPropertyViewNameValueColumnTopHeaderForOrientation(this._orientation),
field: 'primary',
width: 150,
editor: Slick.Editors.Text,
headerCssClass: 'prop-table-header',
formatter: textFormatter
});
}
if (this._model.bottomElement) {
columns.push(new TextWithIconColumn({
id: 'value',
id: 'value2',
name: getPropertyViewNameValueColumnBottomHeaderForOrientation(this._orientation),
field: 'secondary',
width: 150,
headerCssClass: 'prop-table-header',
}).definition);
}
return columns;
}
@@ -313,6 +314,7 @@ export class ExecutionPlanComparisonPropertiesView extends ExecutionPlanProperti
}
});
return rows;
}