Skip to content

Hover state for headers' permalinks is weird #843

@jimporter

Description

@jimporter

Try going to http://www.mkdocs.org/ and put your mouse to the right of "Host anywhere". You'd expect to see the permalink for that heading, but instead, the permalink for "Great themes available" shows up. This can be pretty annoying, since it makes it harder to click on the permalink; if you go a pixel too far to the right, you have to move your mouse back over the text itself, and then back again to the permalink.

As far as I can tell, this is because of the following code: https://github.com/mkdocs/mkdocs/blob/master/mkdocs/themes/mkdocs/css/base.css#L43-L49. I gather that it's there to work around the existence of the header so that anchor links go to the right spot. I'd argue that the old Javascript way was better, unless someone can figure out a way to trick CSS into handling the hover state better.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions