Page MenuHomePhabricator

Table of contents anchor elements do not account for fixed header height
Closed, DuplicatePublic

Description

Hey,

The fixed header cuts off the section headline completely and often parts of the content, especially when a section starts with an image or on lower resolutions, like in this example (there may be worse offenders, I simply quickly grabbed this from the Wikipedia homepage):

https://de.wikipedia.org/wiki/Blitz?useskin=timeless#Dauer,_Stromst%C3%A4rke_und_Polarit%C3%A4t_von_Blitzen

As a user, I want to see which section I am currently reading after clicking on a section in the table of contents or after clicking on a Wikipedia article link with a section anchor reference in its URL and I want all section text to be fully visible without having to scroll up.

I think there is no super clean solution to this problem, the best way would likely be a JavaScript event handler which overrides the default browser behavior and scrolls the page to the right position with the header offset in mind.

Event Timeline

Vvjjkkii renamed this task from Table of contents anchor elements do not account for fixed header height to fubaaaaaaa.Jul 1 2018, 1:06 AM
Vvjjkkii reopened this task as Open.
Vvjjkkii triaged this task as High priority.
Vvjjkkii updated the task description. (Show Details)
CommunityTechBot renamed this task from fubaaaaaaa to Table of contents anchor elements do not account for fixed header height.Jul 2 2018, 1:48 AM
CommunityTechBot closed this task as a duplicate.
CommunityTechBot raised the priority of this task from High to Needs Triage.
CommunityTechBot updated the task description. (Show Details)