We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent eb93041 commit daf2f50Copy full SHA for daf2f50
src/app/navbar/expandable-navbar-section/expandable-navbar-section.component.ts
@@ -166,9 +166,13 @@ export class ExpandableNavbarSectionComponent extends NavbarSectionComponent imp
166
* @param event
167
*/
168
navigateDropdown(event: KeyboardEvent): void {
169
- if (event.key === 'Tab') {
+ if (event.code === 'Tab') {
170
this.deactivateSection(event, false);
171
return;
172
+ } else if (event.code === 'Escape') {
173
+ this.deactivateSection(event, false);
174
+ (document.querySelector(`a[aria-controls="${this.expandableNavbarSectionId()}"]`) as HTMLElement)?.focus();
175
+ return;
176
}
177
event.preventDefault();
178
event.stopPropagation();
0 commit comments