withProperties -> withProps (#15876)

* withProperties -> withProps

* Fix errors

* remove ,

* fixes

* Update azdata-test

* Fix dacpac tests

* Add required and remove added layout
This commit is contained in:
Charles Gagnon
2021-06-23 14:26:14 -07:00
committed by GitHub
parent e21f56d719
commit 3a3d7f5271
73 changed files with 417 additions and 414 deletions

View File

@@ -132,9 +132,10 @@ export class SchemaCompareMainWindow {
this.view = view;
}
this.differencesTable = this.view.modelBuilder.table().withProperties({
this.differencesTable = this.view.modelBuilder.table().withProps({
data: [],
title: loc.differencesTableTitle
title: loc.differencesTableTitle,
columns: []
}).component();
this.diffEditor = this.view.modelBuilder.diffeditor().withProperties({
@@ -146,17 +147,9 @@ export class SchemaCompareMainWindow {
this.splitView = this.view.modelBuilder.splitViewContainer().component();
let sourceTargetLabels = this.view.modelBuilder.flexContainer()
.withProperties({
alignItems: 'stretch',
horizontal: true
}).component();
let sourceTargetLabels = this.view.modelBuilder.flexContainer().component();
this.sourceTargetFlexLayout = this.view.modelBuilder.flexContainer()
.withProperties({
alignItems: 'stretch',
horizontal: true
}).component();
this.sourceTargetFlexLayout = this.view.modelBuilder.flexContainer().component();
this.createSwitchButton();
this.createCompareButton();
@@ -205,17 +198,17 @@ export class SchemaCompareMainWindow {
component: this.saveScmpButton
}]);
let sourceLabel = this.view.modelBuilder.text().withProperties({
let sourceLabel = this.view.modelBuilder.text().withProps({
value: loc.sourceTitle,
CSSStyles: { 'margin-bottom': '0px' }
}).component();
let targetLabel = this.view.modelBuilder.text().withProperties({
let targetLabel = this.view.modelBuilder.text().withProps({
value: loc.targetTitle,
CSSStyles: { 'margin-bottom': '0px' }
}).component();
let arrowLabel = this.view.modelBuilder.text().withProperties({
let arrowLabel = this.view.modelBuilder.text().withProps({
value: '➔'
}).component();
@@ -228,15 +221,15 @@ export class SchemaCompareMainWindow {
this.sourceTargetFlexLayout.addItem(this.selectTargetButton, { CSSStyles: { 'margin-top': '10px' } });
this.loader = this.view.modelBuilder.loadingComponent().component();
this.waitText = this.view.modelBuilder.text().withProperties({
this.waitText = this.view.modelBuilder.text().withProps({
value: loc.waitText
}).component();
this.startText = this.view.modelBuilder.text().withProperties({
this.startText = this.view.modelBuilder.text().withProps({
value: loc.startText
}).component();
this.noDifferencesLabel = this.view.modelBuilder.text().withProperties({
this.noDifferencesLabel = this.view.modelBuilder.text().withProps({
value: loc.noDifferencesText
}).component();
@@ -625,7 +618,7 @@ export class SchemaCompareMainWindow {
}
private createCompareButton(): void {
this.compareButton = this.view.modelBuilder.button().withProperties({
this.compareButton = this.view.modelBuilder.button().withProps({
label: loc.compare,
iconPath: {
light: path.join(this.extensionContext.extensionPath, 'media', 'compare.svg'),
@@ -640,7 +633,7 @@ export class SchemaCompareMainWindow {
}
private createCancelButton(): void {
this.cancelCompareButton = this.view.modelBuilder.button().withProperties({
this.cancelCompareButton = this.view.modelBuilder.button().withProps({
label: loc.stop,
iconPath: {
light: path.join(this.extensionContext.extensionPath, 'media', 'stop.svg'),
@@ -689,7 +682,7 @@ export class SchemaCompareMainWindow {
}
private createGenerateScriptButton(): void {
this.generateScriptButton = this.view.modelBuilder.button().withProperties({
this.generateScriptButton = this.view.modelBuilder.button().withProps({
label: loc.generateScript,
iconPath: {
light: path.join(this.extensionContext.extensionPath, 'media', 'generate-script.svg'),
@@ -725,7 +718,7 @@ export class SchemaCompareMainWindow {
}
private createOptionsButton() {
this.optionsButton = this.view.modelBuilder.button().withProperties({
this.optionsButton = this.view.modelBuilder.button().withProps({
label: loc.options,
iconPath: {
light: path.join(this.extensionContext.extensionPath, 'media', 'options.svg'),
@@ -744,7 +737,7 @@ export class SchemaCompareMainWindow {
private createApplyButton() {
this.applyButton = this.view.modelBuilder.button().withProperties({
this.applyButton = this.view.modelBuilder.button().withProps({
label: loc.apply,
iconPath: {
light: path.join(this.extensionContext.extensionPath, 'media', 'start.svg'),
@@ -855,7 +848,7 @@ export class SchemaCompareMainWindow {
}
private createSwitchButton(): void {
this.switchButton = this.view.modelBuilder.button().withProperties({
this.switchButton = this.view.modelBuilder.button().withProps({
label: loc.switchDirection,
iconPath: {
light: path.join(this.extensionContext.extensionPath, 'media', 'switch-directions.svg'),
@@ -891,7 +884,7 @@ export class SchemaCompareMainWindow {
}
private createSourceAndTargetButtons(): void {
this.selectSourceButton = this.view.modelBuilder.button().withProperties({
this.selectSourceButton = this.view.modelBuilder.button().withProps({
label: '•••',
title: loc.selectSource,
ariaLabel: loc.selectSource,
@@ -905,7 +898,7 @@ export class SchemaCompareMainWindow {
await this.promise;
});
this.selectTargetButton = this.view.modelBuilder.button().withProperties({
this.selectTargetButton = this.view.modelBuilder.button().withProps({
label: '•••',
title: loc.selectTarget,
ariaLabel: loc.selectTarget,
@@ -921,7 +914,7 @@ export class SchemaCompareMainWindow {
}
private createOpenScmpButton() {
this.openScmpButton = this.view.modelBuilder.button().withProperties({
this.openScmpButton = this.view.modelBuilder.button().withProps({
label: loc.openScmp,
iconPath: {
light: path.join(this.extensionContext.extensionPath, 'media', 'open-scmp.svg'),
@@ -1009,7 +1002,7 @@ export class SchemaCompareMainWindow {
}
private createSaveScmpButton(): void {
this.saveScmpButton = this.view.modelBuilder.button().withProperties({
this.saveScmpButton = this.view.modelBuilder.button().withProps({
label: loc.saveScmp,
iconPath: {
light: path.join(this.extensionContext.extensionPath, 'media', 'save-scmp.svg'),