diff --git a/extensions/arc/src/localizedConstants.ts b/extensions/arc/src/localizedConstants.ts index 744a0806b5..e48bc82238 100644 --- a/extensions/arc/src/localizedConstants.ts +++ b/extensions/arc/src/localizedConstants.ts @@ -164,13 +164,21 @@ export const nodes = localize('arc.nodes', "nodes"); export const workerNodes = localize('arc.workerNodes', "Worker Nodes"); export const coordinatorNode = localize('arc.coordinatorNode', "Coordinator Node"); export const storagePerNode = localize('arc.storagePerNode', "storage per node"); -export const workerNodeCount = localize('arc.workerNodeCount', "Worker node count:"); +export const workerNodeCount = localize('arc.workerNodeCount', "Worker node count"); export const configurationPerNode = localize('arc.configurationPerNode', "Configuration (per node)"); export const configuration = localize('arc.configurationCoordinatorNode', "Configuration"); -export const coresLimit = localize('arc.coresLimit', "CPU limit:"); -export const coresRequest = localize('arc.coresRequest', "CPU request:"); -export const memoryLimit = localize('arc.memoryLimit', "Memory limit (in GB):"); -export const memoryRequest = localize('arc.memoryRequest', "Memory request (in GB):"); +export const coresLimit = localize('arc.coresLimit', "CPU limit"); +export const workerCoresLimit = localize('arc.workerCoresLimit', "Worker Nodes CPU limit"); +export const coordinatorCoresLimit = localize('arc.coordinatorCoresLimit', "Coordinator Node CPU limit"); +export const coresRequest = localize('arc.coresRequest', "CPU request"); +export const workerCoresRequest = localize('arc.workerCoresRequest', "Worker Nodes CPU request"); +export const coordinatorCoresRequest = localize('arc.coordinatorCoresRequest', "Coordinator Node CPU request"); +export const memoryLimit = localize('arc.memoryLimit', "Memory limit (in GB)"); +export const workerMemoryLimit = localize('arc.workerMemoryLimit', "Worker Nodes Memory limit (in GB)"); +export const coordinatorMemoryLimit = localize('arc.coordinatorMemoryLimit', "Coordinator Node Memory limit (in GB)"); +export const memoryRequest = localize('arc.memoryRequest', "Memory request (in GB)"); +export const workerMemoryRequest = localize('arc.workerMemoryRequest', "Worker Nodes Memory request (in GB)"); +export const coordinatorMemoryRequest = localize('arc.coordinatorMemoryRequest', "Coordinator Node Memory request (in GB)"); export const arcResources = localize('arc.arcResources', "Azure Arc Resources"); export const enterANonEmptyPassword = localize('arc.enterANonEmptyPassword', "Enter a non empty password or press escape to exit."); export const thePasswordsDoNotMatch = localize('arc.thePasswordsDoNotMatch', "The passwords do not match. Confirm the password or press escape to exit."); @@ -217,6 +225,8 @@ export function numVCores(vCores: string | undefined): string { } } export function updated(when: string): string { return localize('arc.updated', "Updated {0}", when); } +export function copyConnectionStringToClipboard(type: string): string { return localize({ key: 'arc.copyConnectionStringToClipboard', comment: ['{0} is the name of the type of connection string (e.g. Java)'] }, "Copy {0} Connection String to clipboard", type); } +export function copyValueToClipboard(valueName: string): string { return localize({ key: 'arc.copyValueToClipboard', comment: ['{0} is the name of the type of value being copied (e.g. Coordinator endpoint)'] }, "Copy {0} to clipboard", valueName); } // Errors export const pgConnectionRequired = localize('arc.pgConnectionRequired', "A connection is required to show and set database engine settings."); diff --git a/extensions/arc/src/ui/components/keyValueContainer.ts b/extensions/arc/src/ui/components/keyValueContainer.ts index 6f34da7557..120daa2094 100644 --- a/extensions/arc/src/ui/components/keyValueContainer.ts +++ b/extensions/arc/src/ui/components/keyValueContainer.ts @@ -113,7 +113,8 @@ export abstract class BaseInputKeyValue extends KeyValue { const copy = modelBuilder.button().withProperties({ iconPath: IconPathHelper.copy, width: '17px', - height: '17px' + height: '17px', + ariaLabel: loc.copyConnectionStringToClipboard(key) }).component(); this.disposables.push(copy.onDidClick(async () => { diff --git a/extensions/arc/src/ui/dashboards/miaa/miaaComputeAndStoragePage.ts b/extensions/arc/src/ui/dashboards/miaa/miaaComputeAndStoragePage.ts index b84a406a6e..6141abcaeb 100644 --- a/extensions/arc/src/ui/dashboards/miaa/miaaComputeAndStoragePage.ts +++ b/extensions/arc/src/ui/dashboards/miaa/miaaComputeAndStoragePage.ts @@ -183,7 +183,8 @@ export class MiaaComputeAndStoragePage extends DashboardPage { readOnly: false, min: 1, inputType: 'number', - placeHolder: loc.loading + placeHolder: loc.loading, + ariaLabel: loc.coresLimit }).component(); this.disposables.push( @@ -200,7 +201,8 @@ export class MiaaComputeAndStoragePage extends DashboardPage { readOnly: false, min: 1, inputType: 'number', - placeHolder: loc.loading + placeHolder: loc.loading, + ariaLabel: loc.coresRequest }).component(); this.disposables.push( @@ -217,7 +219,8 @@ export class MiaaComputeAndStoragePage extends DashboardPage { readOnly: false, min: 2, inputType: 'number', - placeHolder: loc.loading + placeHolder: loc.loading, + ariaLabel: loc.memoryLimit }).component(); this.disposables.push( @@ -234,7 +237,8 @@ export class MiaaComputeAndStoragePage extends DashboardPage { readOnly: false, min: 2, inputType: 'number', - placeHolder: loc.loading + placeHolder: loc.loading, + ariaLabel: loc.memoryRequest }).component(); this.disposables.push( @@ -274,7 +278,7 @@ export class MiaaComputeAndStoragePage extends DashboardPage { }).component(); const keyComponent = this.modelView.modelBuilder.text().withProperties({ - value: key, + value: `${key} :`, CSSStyles: { ...cssStyles.text, 'margin-block-start': '0px', 'margin-block-end': '0px' } }).component(); diff --git a/extensions/arc/src/ui/dashboards/postgres/postgresComputeAndStoragePage.ts b/extensions/arc/src/ui/dashboards/postgres/postgresComputeAndStoragePage.ts index 7400f7fc98..25e98c239d 100644 --- a/extensions/arc/src/ui/dashboards/postgres/postgresComputeAndStoragePage.ts +++ b/extensions/arc/src/ui/dashboards/postgres/postgresComputeAndStoragePage.ts @@ -247,7 +247,8 @@ export class PostgresComputeAndStoragePage extends DashboardPage { min: 0, inputType: 'number', placeHolder: loc.loading, - required: true + required: true, + ariaLabel: loc.workerNodeCount }).component(); this.disposables.push( @@ -265,7 +266,8 @@ export class PostgresComputeAndStoragePage extends DashboardPage { readOnly: false, min: 1, inputType: 'number', - placeHolder: loc.loading + placeHolder: loc.loading, + ariaLabel: loc.workerCoresRequest }).component(); this.disposables.push( @@ -285,7 +287,8 @@ export class PostgresComputeAndStoragePage extends DashboardPage { readOnly: false, min: 1, inputType: 'number', - placeHolder: loc.loading + placeHolder: loc.loading, + ariaLabel: loc.workerCoresLimit }).component(); this.disposables.push( @@ -305,7 +308,8 @@ export class PostgresComputeAndStoragePage extends DashboardPage { readOnly: false, min: 0.25, inputType: 'number', - placeHolder: loc.loading + placeHolder: loc.loading, + ariaLabel: loc.workerMemoryRequest }).component(); this.disposables.push( @@ -325,7 +329,8 @@ export class PostgresComputeAndStoragePage extends DashboardPage { readOnly: false, min: 0.25, inputType: 'number', - placeHolder: loc.loading + placeHolder: loc.loading, + ariaLabel: loc.workerMemoryLimit }).component(); this.disposables.push( @@ -345,7 +350,8 @@ export class PostgresComputeAndStoragePage extends DashboardPage { readOnly: false, min: 1, inputType: 'number', - placeHolder: loc.loading + placeHolder: loc.loading, + ariaLabel: loc.coordinatorCoresRequest }).component(); this.disposables.push( @@ -365,7 +371,8 @@ export class PostgresComputeAndStoragePage extends DashboardPage { readOnly: false, min: 1, inputType: 'number', - placeHolder: loc.loading + placeHolder: loc.loading, + ariaLabel: loc.coordinatorCoresLimit }).component(); this.disposables.push( @@ -385,7 +392,8 @@ export class PostgresComputeAndStoragePage extends DashboardPage { readOnly: false, min: 0.25, inputType: 'number', - placeHolder: loc.loading + placeHolder: loc.loading, + ariaLabel: loc.coordinatorMemoryRequest }).component(); this.disposables.push( @@ -405,7 +413,8 @@ export class PostgresComputeAndStoragePage extends DashboardPage { readOnly: false, min: 0.25, inputType: 'number', - placeHolder: loc.loading + placeHolder: loc.loading, + ariaLabel: loc.coordinatorMemoryLimit }).component(); this.disposables.push( @@ -499,7 +508,7 @@ export class PostgresComputeAndStoragePage extends DashboardPage { }).component(); const keyComponent = this.modelView.modelBuilder.text().withProps({ - value: key, + value: `${key} :`, CSSStyles: { ...cssStyles.text, 'margin-block-start': '0px', 'margin-block-end': '0px' } }).component();