Skip to content

Commit

Permalink
Mis-nesting of aria roles on sidebar navigation (#2050)
Browse files Browse the repository at this point in the history
  • Loading branch information
ryan-garrett committed Jun 20, 2022
1 parent 01ffff7 commit 7ca10da
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion e2e/integration/search.e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ describe('Search', () => {

getSearchInput().type('{enter}', { force: true });

cy.contains('[role=navigation] [role=menuitem]', 'Introduction').should('have.class', 'active');
cy.contains('[role=menu] [role=menuitem]', 'Introduction').should('have.class', 'active');
});

it('should mark search results', () => {
Expand Down
2 changes: 1 addition & 1 deletion src/components/SideMenu/MenuItems.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export class MenuItems extends React.Component<MenuItemsProps> {
className={className}
style={this.props.style}
expanded={expanded}
{...(root ? { role: 'navigation' } : {})}
{...(root ? { role: 'menu' } : {})}
>
{items.map((item, idx) => (
<MenuItem key={idx} item={item} onActivate={this.props.onActivate} />
Expand Down

0 comments on commit 7ca10da

Please sign in to comment.