Use searchfield instead of searchbox component in sidebar#217
Merged
AA-Turner merged 2 commits intosphinx-doc:masterfrom Jul 15, 2024
Merged
Use searchfield instead of searchbox component in sidebar#217AA-Turner merged 2 commits intosphinx-doc:masterfrom
AA-Turner merged 2 commits intosphinx-doc:masterfrom
Conversation
This moves the search field up before the navigation. It's quite commmon that search is near the top of the page. Also, this results in a fixed position, because navigation is page dependent and may be long, which could move the search field far down or even off-page in the old layout. The searchfield component (sphinx-doc/sphinx#11045) is more compact and does not have a heading, which reduces clutter and gives more focus to the content sections.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Edit: This would require bumping the dependency to 6.2 (Relased Apr 2023), where the new
searchfieldcomponent was introduced. Is it feasible to bumb the min-version of sphinx to 6.2? I assume nothing really bad would happen. Users with older versions of sphinx would just not get newer versions of the theme.This moves the search field up before the navigation. It's quite commmon that search is near the top of the page. Also, this results in a fixed position, because navigation is page dependent and may be long, which could move the search field far down or even off-page in the old layout.
The searchfield component
(sphinx-doc/sphinx#11045) is more compact and does not have a heading, which reduces clutter and gives more focus to the content sections.
before / after: