mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-14 01:25:37 -05:00
Add accessibility information to query history items (#20958)
* Add accessibility information to query history items * bump version
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
"name": "query-history",
|
||||
"displayName": "%queryHistory.displayName%",
|
||||
"description": "%queryHistory.description%",
|
||||
"version": "0.5.1",
|
||||
"version": "0.5.2",
|
||||
"publisher": "Microsoft",
|
||||
"preview": true,
|
||||
"license": "https://raw.githubusercontent.com/Microsoft/azuredatastudio/main/LICENSE.txt",
|
||||
|
||||
@@ -6,5 +6,8 @@
|
||||
import * as nls from 'vscode-nls';
|
||||
const localize = nls.loadMessageBundle();
|
||||
|
||||
export const succeeded = localize('succeeded', "Succeeded");
|
||||
export const failed = localize('failed', "Failed");
|
||||
|
||||
export const errorLoading = (err: any): string => localize('errorLoading', "Error loading saved query history items. {0}", err.message ?? err);
|
||||
|
||||
|
||||
@@ -242,6 +242,9 @@ export class QueryHistoryProvider implements vscode.TreeDataProvider<QueryHistor
|
||||
treeItem.tooltip = item.queryText;
|
||||
treeItem.description = item.connectionProfile ? `${item.connectionProfile.serverName}|${item.connectionProfile.databaseName} ${item.timestamp}` : item.timestamp;
|
||||
treeItem.command = { title: '', command: ITEM_SELECTED_COMMAND_ID, arguments: [item] };
|
||||
treeItem.accessibilityInformation = {
|
||||
label: `${item.isSuccess ? loc.succeeded : loc.failed} ${treeItem.description} ${item.queryText}`
|
||||
}
|
||||
return treeItem;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user