Skip to content

Commit 417085e

Browse files
committed
fix(pat navigation): Only search within the current element.
1 parent 6c84a41 commit 417085e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/pat/navigation/navigation.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ export default Base.extend({
117117
mark_current(current_el) {
118118
const current_els = current_el
119119
? [current_el]
120-
: document.querySelectorAll(`.current > a, a.current`);
120+
: this.el.querySelectorAll(`.current > a, a.current`);
121121

122122
for (const item of current_els) {
123123
item.classList.add(this.options.currentClass);

0 commit comments

Comments
 (0)