From 2815a8b12b1ee65403c6e329a251a5eb216620f9 Mon Sep 17 00:00:00 2001 From: bram-atmire Date: Mon, 4 May 2026 11:20:55 +0200 Subject: [PATCH] Fix remaining ARIA issues from #5488 PR #5514 (also referencing #5488) makes the dso-edit-menu menubar role vanish when the menu is empty/hidden. This commit addresses the four remaining ARIA problems flagged in the issue and the supporting WAVE/Pa11y/HTMLCS findings: 1. auth-nav-menu (login dropdown trigger): The button declared aria-haspopup="menu" but actually opened a
. Screen readers therefore announced "has popup, menu" and then revealed a dialog. Updated to aria-haspopup="dialog" so the announcement matches what opens. Also removed the redundant role="button" / tabindex="0" on a real
} diff --git a/src/app/header/context-help-toggle/context-help-toggle.component.scss b/src/app/header/context-help-toggle/context-help-toggle.component.scss index f3e5e01880a..f8cbd4047af 100644 --- a/src/app/header/context-help-toggle/context-help-toggle.component.scss +++ b/src/app/header/context-help-toggle/context-help-toggle.component.scss @@ -1,3 +1,10 @@ +.ds-context-help-toggle-button { + background: none; + border: 0; + padding: 0; + cursor: pointer; +} + .ds-context-help-toggle { color: var(--ds-header-icon-color); background-color: var(--ds-header-bg); diff --git a/src/app/header/context-help-toggle/context-help-toggle.component.spec.ts b/src/app/header/context-help-toggle/context-help-toggle.component.spec.ts index 5172cfd9913..45995afcd87 100644 --- a/src/app/header/context-help-toggle/context-help-toggle.component.spec.ts +++ b/src/app/header/context-help-toggle/context-help-toggle.component.spec.ts @@ -56,10 +56,17 @@ describe('ContextHelpToggleComponent', () => { }); it('clicking the button should toggle context help icon visibility', fakeAsync(() => { - fixture.debugElement.query(By.css('a')).nativeElement.click(); + fixture.debugElement.query(By.css('button')).nativeElement.click(); tick(); expect(contextHelpService.toggleIcons).toHaveBeenCalled(); })); + + it('the toggle should be a real @if ((active$ | async).valueOf() === true) {
so user agents do not apply native button chrome + button.ds-menu-toggler-wrapper { + background: none; + border: 0; + padding: 0; + color: inherit; + font: inherit; + cursor: pointer; + } + .dropdown-menu { overflow: hidden; min-width: 100%; diff --git a/src/app/navbar/expandable-navbar-section/expandable-navbar-section.component.spec.ts b/src/app/navbar/expandable-navbar-section/expandable-navbar-section.component.spec.ts index fb0e66d9e82..5535b3908bf 100644 --- a/src/app/navbar/expandable-navbar-section/expandable-navbar-section.component.spec.ts +++ b/src/app/navbar/expandable-navbar-section/expandable-navbar-section.component.spec.ts @@ -57,6 +57,15 @@ describe('ExpandableNavbarSectionComponent', () => { fixture.detectChanges(); }); + describe('toggler element', () => { + it('should be a real @@ -20,7 +21,7 @@ @if (canActivate) {
-