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

ENH: Include navbar in the left sidebar on home page #536

Closed
wants to merge 1 commit into from

Conversation

choldgraf
Copy link
Collaborator

@choldgraf choldgraf commented Jan 4, 2022

This is a minimal change needed to make the navigation links show up in the left sidebar only on the root page.

It's on by default, which I think is reasonable. Even if the links are redundant with the top navbar on the root page, that is still probably better than an awkward white space. And if people want to remove them, they can do so via:

html_sidebars = {root-doc-name: []}

New behavior:

image

Old behavior:

image

closes #221

@choldgraf
Copy link
Collaborator Author

This is just a quick implementation to see if people like it. Another option could be to provide a new configuration feature like homepage_sidebar_links.

@choldgraf
Copy link
Collaborator Author

choldgraf commented Jan 8, 2022

I am gonna close this PR, since it was just opened as a demonstration, not something ready to be merged, and since I've got a bunch of other PRs open that I think should have precedence over this one :-) we can use it as a reference though!

@choldgraf choldgraf closed this Jan 8, 2022
@jorisvandenbossche
Copy link
Member

I certainly agree it would be good to do something about the by-default odd looking home page. But I am not fully sure duplicating the navigation is necessarily the best option.
We discussed this before somewhat at #146, and looking back it seems we concluded there that you can hide the sidebar with sphinx' sidebars option, and if there is no sidebar, we make the main content a bit wider.

Maybe we should make use of that in our demo docs? Although the question is then where to put the search box? (somewhere on the main page content?)

@damianavila
Copy link
Collaborator

Interesting discussion, should we capture that in a new issue since #146 is already closed?

@choldgraf
Copy link
Collaborator Author

@damianavila or in #221

@jbednar
Copy link

jbednar commented Jan 13, 2022

I'd strongly vote for doing something to avoid having the very first page of each site look so unbalanced; it seems like an error on every site where I have seen it, including our own, like https://hvplot.holoviz.org. Putting the top-level TOC there makes good sense and makes it stop looking so bad (which happens for some reason on holoviews.org already). I think it's also ok to simply suppress the sidebar on the main page, but I had the same worry as Joris about what happens to the search bar. Maybe just move the search bar to the right sidebar, on all pages (not just the home page)?

@damianavila
Copy link
Collaborator

@jbednar, I made a reference to your comment in #221, and maybe we can continue the conversation there. Thanks!
Btw, nice to see you here 😉

@jbednar
Copy link

jbednar commented Jan 14, 2022

Hi! :-) Sounds good!

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

Successfully merging this pull request may close these issues.

Show TOC from root index.html on left sidebar
4 participants