Allow heading to take focus from anchor link
This commit is contained in:
parent
b3351bd600
commit
5ca43c3568
@ -11,6 +11,7 @@ class HeadingAnchors extends HTMLElement {
|
|||||||
this.headings.forEach((heading) => {
|
this.headings.forEach((heading) => {
|
||||||
if(!heading.querySelector("a.direct-link") || heading.hasAttribute("data-heading-anchors-optout")) {
|
if(!heading.querySelector("a.direct-link") || heading.hasAttribute("data-heading-anchors-optout")) {
|
||||||
heading.append(this.anchor(heading));
|
heading.append(this.anchor(heading));
|
||||||
|
heading.setAttribute("tabindex", "-1");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user