Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TOC sidebar expands to page for links but not groups #2724

Closed
1 task done
hamishwillee opened this issue Dec 2, 2020 · 2 comments
Closed
1 task done

TOC sidebar expands to page for links but not groups #2724

hamishwillee opened this issue Dec 2, 2020 · 2 comments

Comments

@hamishwillee
Copy link

hamishwillee commented Dec 2, 2020

  • I confirm that this is an issue rather than a question.

Bug report

Steps to reproduce

Open any of these links:

Note that the sidebar does not open to the current page in these cases - it remains "unexpanded". That is because these are sidebar groups.

Note that any item which is a link (not a group) - e.g. a child node with no children - then the page does open to the link - see https://docs.px4.io/master/en/modules/modules_command.html#dyn

Problem Repo: https://github.com/PX4/PX4-user_guide

What is expected?

If you open a page then the sidebar should expand to display that page.

What is actually happening?

However only pages that are bottom level links are opened. Pages that are groups are not opened.

Other relevant information

This is reproducable on builds in windows and in ubuntu.

This particular project is built from root in the normal way - ie yarn docs:dev. It is not relevant to this problem, but the tree is built dynamically from a file named SUMMARY.md using .vuepress/get_sidebar.js

Can be reproduced in Windows and Ubuntu builds.

  • Output of npx vuepress info in my VuePress project:
Environment Info:

  System:
    OS: Windows 10 10.0.18363
    CPU: (16) x64 Intel(R) Core(TM) i9-9900K CPU @ 3.60GHz
  Binaries:
    Node: 12.18.1 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.5 - C:\Program Files (x86)\Yarn\bin\yarn.CMD
    npm: 6.14.5 - C:\Program Files\nodejs\npm.CMD
  Browsers:
    Chrome: 86.0.4240.198
    Edge: Spartan (44.18362.449.0)
  npmPackages:
    @vuepress/core:  1.7.1
    @vuepress/theme-default:  1.7.1
    vuepress: ^1.5.4 => 1.7.1
  npmGlobalPackages:
    vuepress: Not Found
@hamishwillee
Copy link
Author

Note, provided none of your groups have links (because children work properly). This however forces a kind of ugly interaction where you have to structure like this:

Some Group
   About Some Group (Topic)
   The things in the group)

@hamishwillee
Copy link
Author

This was a duplicate of #2565
Fixed in 1.8.2. Thanks!!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant