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

Don't duplicate the sidebar button on Sphinx 5 and newer #127

Merged
merged 3 commits into from
Apr 25, 2023

Conversation

AA-Turner
Copy link
Member

The sidebar button is included in the generated HTML from Sphinx 5 onwards (specifically, from sphinx-doc/sphinx@3b01fbe and the changes to themes/classic/layout.html).

We use the sphinx_version_tuple templating variable addded in Sphinx 4.2 to determine if we should add the sidebar button dynamically via JavaScript, or load the pre-existing button element from HTML.

I have tested locally on Sphinx 6.1.3, Sphinx 3.2.0, and Sphinx 4.5.0--all three display correct behaviour with respect to the sidebar.

A

@AA-Turner AA-Turner mentioned this pull request Apr 20, 2023
@AA-Turner
Copy link
Member Author

I've updated python/cpython#99381 to point to this PR, so that it installs Sphinx 6.1.3 and python-docs-theme as of this PR. The deploy preview seems to show that all is working as intended on newer Sphinx versions, and this PR's RTD preview shows it working on older Sphinx versions.

A

@hugovk hugovk merged commit e3ef253 into python:main Apr 25, 2023
@AA-Turner
Copy link
Member Author

Thanks Hugo!

A

@AA-Turner AA-Turner deleted the sphinx-5-fixup branch July 15, 2024 19:48
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

Successfully merging this pull request may close these issues.

3 participants