SCM - fix aria label for incoming/outoing nodes (#199648)

SCM - update aria label for incoming/outgoing
This commit is contained in:
Ladislau Szomoru 2023-11-30 12:01:15 +01:00 committed by GitHub
parent 15a7e46d25
commit 3cd0a63551
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1310,7 +1310,7 @@ export class SCMAccessibilityProvider implements IListAccessibilityProvider<Tree
} else if (isSCMResourceGroup(element)) {
return element.label;
} else if (isSCMHistoryItemGroupTreeElement(element)) {
return `${stripIcons(element.label).trim()}${element.description ? `, ${element.description}` : ''}`;
return element.ariaLabel ?? `${element.label.trim()}${element.description ? `, ${element.description}` : ''}`;
} else if (isSCMHistoryItemTreeElement(element)) {
return `${stripIcons(element.label).trim()}${element.description ? `, ${element.description}` : ''}`;
} else if (isSCMHistoryItemChangeTreeElement(element)) {
@ -1323,7 +1323,7 @@ export class SCMAccessibilityProvider implements IListAccessibilityProvider<Tree
return result.join(', ');
} else if (isSCMViewSeparator(element)) {
return element.label;
return element.ariaLabel ?? element.label;
} else {
const result: string[] = [];