Skip to content

inject_anchors generates empty links  #175

@anthonydillon

Description

@anthonydillon

The empty links generated by inject_anchors cause accessibility issues. Reference.

Currently the markup results in:

<h2 id="heading-one">
  <a class="anchor" href="#heading-one" aria-hidden="true">
    <span class="octicon octicon-link"></span>
  </a>
  Heading one
</h2>

I would suggest this would be better:

<h2 id="heading-one">
  <a class="anchor" href="#heading-one" aria-hidden="true">
    <span class="octicon octicon-link">Link to Header one section</span>
  </a>
  Heading one
</h2>

The content within the icon is hidden by default.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions