Skip to content

Commit

Permalink
Changed quickLinks selection resolving missing selection bug in QA
Browse files Browse the repository at this point in the history
  • Loading branch information
cheintzman committed Dec 20, 2023
1 parent ed4ca33 commit 17c894f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion blocks/adp-header/adp-header.js
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ function initQuickLinks() {

// set aria-selected on quick links
quickLinks.querySelectorAll('.item').forEach((item) => {
if (item.querySelector('a')?.dataset.page === window.location.pathname) {
if (item.querySelector('a')?.getAttribute('href') === window.location.pathname) {
item.setAttribute('aria-selected', 'true');
}
});
Expand Down

0 comments on commit 17c894f

Please sign in to comment.