diff --git a/extensions/dacpac/src/localizedConstants.ts b/extensions/dacpac/src/localizedConstants.ts index 704deee1d3..78e34bd1d0 100644 --- a/extensions/dacpac/src/localizedConstants.ts +++ b/extensions/dacpac/src/localizedConstants.ts @@ -54,6 +54,7 @@ export const exportText = localize('dacFx.export', "Export"); export const generateScript = localize('dacFx.generateScriptButton', "Generate Script"); export const generatingScriptMessage = localize('dacfx.scriptGeneratingMessage', "You can view the status of script generation in the Tasks View once the wizard is closed. The generated script will open when complete."); export const defaultText = localize('dacfx.default', "default"); +export const deployPlanTableTitle = localize('dacfx.deployPlanTableTitle', "Deploy plan operations"); // Error messages export const databaseNameExistsErrorMessage = localize('dacfx.databaseNameExistsErrorMessage', "A database with the same name already exists on the instance of SQL Server"); diff --git a/extensions/dacpac/src/wizard/pages/deployPlanPage.ts b/extensions/dacpac/src/wizard/pages/deployPlanPage.ts index b09a6e697e..ad84686650 100644 --- a/extensions/dacpac/src/wizard/pages/deployPlanPage.ts +++ b/extensions/dacpac/src/wizard/pages/deployPlanPage.ts @@ -52,7 +52,9 @@ export class DeployPlanPage extends DacFxConfigPage { } async start(): Promise { - this.table = this.view.modelBuilder.table().component(); + this.table = this.view.modelBuilder.table().withProperties({ + ariaLabel: loc.deployPlanTableTitle + }).component(); this.loader = this.view.modelBuilder.loadingComponent().withItem(this.table).component(); this.dataLossComponentGroup = await this.createDataLossComponents(); this.noDataLossTextComponent = await this.createNoDataLossText(); diff --git a/extensions/schema-compare/src/dialogs/schemaCompareOptionsDialog.ts b/extensions/schema-compare/src/dialogs/schemaCompareOptionsDialog.ts index ea3deae28b..518594520b 100644 --- a/extensions/schema-compare/src/dialogs/schemaCompareOptionsDialog.ts +++ b/extensions/schema-compare/src/dialogs/schemaCompareOptionsDialog.ts @@ -292,6 +292,7 @@ export class SchemaCompareOptionsDialog { this.optionsFlexBuilder.addItem(this.descriptionHeading, { CSSStyles: { 'font-weight': 'bold', 'height': '30px' } }); this.optionsFlexBuilder.addItem(this.descriptionText, { CSSStyles: { 'padding': '4px', 'margin-right': '10px', 'overflow': 'scroll', 'height': '10vh' } }); await view.initializeModel(this.optionsFlexBuilder); + this.optionsTable.focus(); }); } diff --git a/src/sql/workbench/browser/modelComponents/table.component.ts b/src/sql/workbench/browser/modelComponents/table.component.ts index a5cf475468..fce3211b09 100644 --- a/src/sql/workbench/browser/modelComponents/table.component.ts +++ b/src/sql/workbench/browser/modelComponents/table.component.ts @@ -315,6 +315,15 @@ export default class TableComponent extends ComponentBase implements IComponent, this._table.autosizeColumns(); } + public focus(): void { + if (this._table.grid.getDataLength() > 0) { + if (!this._table.grid.getActiveCell()) { + this._table.grid.setActiveCell(0, 0); + } + this._table.grid.getActiveCellNode().focus(); + } + } + // CSS-bound properties public get data(): any[][] {