Skip to content

Commit

Permalink
[JS] Remove role='menubar' and role='menuitem' from `ActionCollec…
Browse files Browse the repository at this point in the history
…tion`

Fixes #6425
Fixes #6019
Related #4859
  • Loading branch information
paulcam206 committed Nov 23, 2021
1 parent ef3a272 commit 4571e27
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions source/nodejs/adaptivecards/src/card-elements.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5007,7 +5007,6 @@ class ActionCollection {
let buttonStrip = document.createElement("div");
buttonStrip.className = hostConfig.makeCssClassName("ac-actionSet");
buttonStrip.style.display = "flex";
buttonStrip.setAttribute("role", "menubar");

if (orientation == Enums.Orientation.Horizontal) {
buttonStrip.style.flexDirection = "row";
Expand Down Expand Up @@ -5114,12 +5113,6 @@ class ActionCollection {
action.render();

if (action.renderedElement) {
if (primaryActions.length > 1) {
action.renderedElement.setAttribute("aria-posinset", (i + 1).toString());
action.renderedElement.setAttribute("aria-setsize", primaryActions.length.toString());
action.renderedElement.setAttribute("role", "menuitem");
}

if (hostConfig.actions.actionsOrientation == Enums.Orientation.Horizontal && hostConfig.actions.actionAlignment == Enums.ActionAlignment.Stretch) {
action.renderedElement.style.flex = "0 1 100%";
}
Expand Down

0 comments on commit 4571e27

Please sign in to comment.