Skip to content

Cannot set properties of null (setting 'scrollTop') #3773

@lrnselfreliance

Description

@lrnselfreliance

I encounter an error when attempting to navigate to the second level of the navigation menu. Here is a video:

mkdocs-error.mp4

Navigation to both docs/one/a/index.md and docs/one/b/index.md works fine using links in the root index. This error only occurs with both a and b directory. The error goes away if you delete the b directory.

I have a much larger mkdocs project which displays the same error. The larger project has many more files, and several level two navigation menus.

This error still occurs with latest master 62a4e3c.

Files to replicate

requirements.txt

mkdocs==1.6.0

mkdocs.yml

site_name: test
theme:
  name: mkdocs
  color_mode: auto
  user_color_mode_toggle: true

docs/index.md

# Index

[A Index](one/a/index.md)

[B Index](one/b/index.md)

docs/one/index.md

# One Index

docs/one/a/index.md

# A Index

docs/one/b/index.md

# B Index

Error

Browser error:

Uncaught TypeError: popup.querySelector(...) is null
    hideInnerDropdown http://127.0.0.1:8000/js/base.js:121
    showInnerDropdown http://127.0.0.1:8000/js/base.js:96
    showInnerDropdown http://127.0.0.1:8000/js/base.js:94
    <anonymous> http://127.0.0.1:8000/js/base.js:130

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions