feat: Use custom ARIA roledescriptions for different block types (#9507)

* feat: Use custom ARIA roledescriptions for different block types

* fix: Denote shadow blocks in the label rather than role description
This commit is contained in:
Aaron Dodson
2025-12-05 13:28:37 -08:00
committed by GitHub
parent ff6ca2e743
commit f35f4d8aec

View File

@@ -274,6 +274,9 @@ export class BlockSvg
if (this.isCollapsed()) {
labelComponents.push('collapsed');
}
if (this.isShadow()) {
labelComponents.push('replaceable');
}
if (inputCount > 1) {
labelComponents.push('has inputs');
@@ -307,9 +310,7 @@ export class BlockSvg
* @returns The ARIA roledescription for this block.
*/
protected getAriaRoleDescription() {
if (this.isShadow()) {
return 'replaceable block';
} else if (this.outputConnection) {
if (this.outputConnection) {
return 'value block';
} else if (this.statementInputCount) {
return 'container block';