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

Single-page documentation (\wout toctree) #93

Closed
chrisjsewell opened this issue May 17, 2020 · 8 comments
Closed

Single-page documentation (\wout toctree) #93

chrisjsewell opened this issue May 17, 2020 · 8 comments

Comments

@chrisjsewell
Copy link
Member

As with pydata/pydata-sphinx-theme#180, but more acute because the right "on this page" section seems to disappear as you scroll down the page: https://sphinx-panels.readthedocs.io/en/sphinx-book-theme/?

@choldgraf
Copy link
Member

I just added this section to the docs about a single-page theme: https://sphinx-book-theme.readthedocs.io/en/latest/configure.html#use-a-single-page-version-of-this-theme

In this case, the disappearing right TOC is intentional in order to make sure it doesn't overlap with any content that expands into the right margin (you can hover over it in order to show the TOC again).

Perhaps we can include a configuration value like always_show_toc that makes the TOC never go away? Though in that case it would overlap with any margin content so it'd be at the user's risk.

@chrisjsewell
Copy link
Member Author

chrisjsewell commented May 17, 2020

Ok yeh ta that stops the error pydata/pydata-sphinx-theme#180, but hovering over the ToC still doesn't work (at least building locally).
always_show_toc should definitely be an option. I don't know if this is at all possible, but ideally in this mode the ToC would actually switch to being on the right left.

@choldgraf
Copy link
Member

ah so in your mind, if it's a single page then the TOC should be on the left instead of the right? That shouldn't be too hard.

Hmmm, if hovering over the TOC doesn't work then that's a problem. Does it show up when the page first loads (when you're at the top?)

@chrisjsewell
Copy link
Member Author

Does it show up when the page first loads (when you're at the top?)

It did with single_page=False, it does not with single_page=True

@chrisjsewell
Copy link
Member Author

chrisjsewell commented May 17, 2020

Maybe be due to?

image

@choldgraf
Copy link
Member

Hmm - it seemed to work OK for me.

If I check out your sphinx-book-theme branch, remove the toctree in index, and add single_page: True to conf.py then this is what I see:

image

What browser are you on? And can you try with master on SBT? Maybe we need to make a release there?

@choldgraf
Copy link
Member

I just pushed the update to your sphinx-book-theme branch and the toctree renders fine for me, so maybe it is a browser problem after all?

https://sphinx-panels.readthedocs.io/en/sphinx-book-theme/

@chrisjsewell
Copy link
Member Author

Yep its working as advertised now 👍

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

2 participants