Skip to content

documents scroll underneath fixed position header #631

Closed
@activedecay

Description

@activedecay

When clicking documentation links, using a header with a fixed position, the document scrolls underneath the header. What do you think of allowing this offset as a new config value?

inside src/core/config.js:14

windowYOffset: 0, // some user defined offset is allowed to account for fixed headers

inside export function initEvent(vm) at src/core/event/index.js:17

setWindowYOffset(vm.config.windowYOffset)

now fix up the scroll code a bit in src/core/event/scroll.js:23

end: el.getBoundingClientRect().top + window.pageYOffset - windowYOffset,

Metadata

Metadata

Assignees

No one assigned

    Labels

    pinnedThis is to pinned the PR/Issue in order to keep it openpr welcome

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions