Summary:
The :local-link pseudo-class allows authors to style hyperlinks based on the users current location within a site. It represents an element that is the source anchor of a hyperlink whose target’s absolute URL matches the element’s own document URL. If the hyperlink’s target includes a fragment URL, then the fragment URL of the current URL must also match; if it does not, then the fragment URL portion of the current URL is not taken into account in the comparison.
I intend to prototype this out in Gecko.
Bug:
Specification:
Standards Body:
CSSWG
Platform coverage:
all.
Preference:
dom.local_link_pseudo.enabled
DevTools bug:
n/a.
Link to standards-positions discussion:
Other browsers:
Blink: Prototyping.
web-platform-tests:
These will be written alongside implementing the feature.