From 2e89d3ff06b47b1fc2e515ef5846d5350ea6ba0d Mon Sep 17 00:00:00 2001 From: Sarah Higley Date: Wed, 19 Apr 2023 10:09:03 -0700 Subject: [PATCH] fix: add aria-expanded to allowed attrs for menuitemcheckbox and menuitemradio --- lib/standards/aria-roles.js | 4 ++-- test/integration/rules/aria-allowed-attr/passes.html | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/standards/aria-roles.js b/lib/standards/aria-roles.js index c6c0f67c4e..f26c9428d4 100644 --- a/lib/standards/aria-roles.js +++ b/lib/standards/aria-roles.js @@ -378,7 +378,7 @@ const ariaRoles = { type: 'widget', requiredContext: ['menu', 'menubar', 'group'], requiredAttrs: ['aria-checked'], - allowedAttrs: ['aria-posinset', 'aria-readonly', 'aria-setsize'], + allowedAttrs: ['aria-expanded', 'aria-posinset', 'aria-readonly', 'aria-setsize'], superclassRole: ['checkbox', 'menuitem'], accessibleNameRequired: true, nameFromContent: true, @@ -388,7 +388,7 @@ const ariaRoles = { type: 'widget', requiredContext: ['menu', 'menubar', 'group'], requiredAttrs: ['aria-checked'], - allowedAttrs: ['aria-posinset', 'aria-readonly', 'aria-setsize'], + allowedAttrs: ['aria-expanded', 'aria-posinset', 'aria-readonly', 'aria-setsize'], superclassRole: ['menuitemcheckbox', 'radio'], accessibleNameRequired: true, nameFromContent: true, diff --git a/test/integration/rules/aria-allowed-attr/passes.html b/test/integration/rules/aria-allowed-attr/passes.html index 9bee42b07c..979f75979e 100644 --- a/test/integration/rules/aria-allowed-attr/passes.html +++ b/test/integration/rules/aria-allowed-attr/passes.html @@ -1033,6 +1033,7 @@ aria-live="value" aria-owns="value" aria-relevant="value" + aria-expanded="value" > ok @@ -1064,6 +1065,7 @@ aria-live="value" aria-owns="value" aria-relevant="value" + aria-expanded="value" > ok