Skip to content

Disabling search also disables the theme switcher #1255

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

Closed
provinzkraut opened this issue Mar 21, 2023 · 7 comments
Closed

Disabling search also disables the theme switcher #1255

provinzkraut opened this issue Mar 21, 2023 · 7 comments
Labels
needs: more information Needs more information from the author before we can move forward

Comments

@provinzkraut
Copy link

navbar_persistent is set to "navbar_persistent": ["search-button"] by default. If you try to remove the search by setting it to "navbar_persistent": [], the theme switcher also gets removed.

Workaround is to set it to "navbar_persistent": ["theme-switcher"] instead.

@12rambau
Copy link
Collaborator

What you're describing is the intended behaviour. On small screen only the search-button remains in the navbar, the others (theme-swithcer and link-icons) are moved to the primary sidebar (left) that can be activated with the "menu" button.

The workaround you propose will work just fine but then I don't really get what's the purpose of the issue. Would you like us to change the behaviour ?

@provinzkraut
Copy link
Author

On small screen only the search-button remains in the navbar, the others (theme-swithcer and link-icons) are moved to the primary sidebar (left) that can be activated with the "menu" button.

This does not seem to explain why removing the search button also removes the theme switcher?
I get why they are not being displayed on small screens, but not why this side effect occurs.
This behaviour exists regardless of screen size

The workaround you propose will work just fine but then I don't really get what's the purpose of the issue. Would you like us to change the behaviour ?

The purpose of this issue was that I assumed this to be a bug, since it's a (seemingly random) side effect. If this is intended this issue can be closed, but maybe it would be good to add some explanation of this in the docs, since it's not immediately obvious (as made evident by me thinking it's a bug 🙃)

@12rambau
Copy link
Collaborator

sorry I though it was nly disapearing in the small screen display my bad.

Let me check we made some decoration on these 2 buttons recently in #1146 maybe that's related

@12rambau
Copy link
Collaborator

I tried in our documentation to apply the same modification:

"navbar_persistent": []

and it seems to work as expected: The theme switcher is still there in big screen:

image

Could you confirm it's what you tried ?

@12rambau 12rambau added the needs: more information Needs more information from the author before we can move forward label Mar 25, 2023
@provinzkraut
Copy link
Author

Could you confirm it's what you tried ?

Yes, that's exactly what I did and I can still reproduce this.

I'm on 0.13.1 in case that's relevant.

@12rambau
Copy link
Collaborator

could you share the repository branch where you did this ? As I don't manage to reproduce it on any of my websites, I think something else is different from your side

@12rambau
Copy link
Collaborator

I'll close this as we cannot reproduce it from our side. PLease send us some feedback if the bug persist.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs: more information Needs more information from the author before we can move forward
Projects
None yet
Development

No branches or pull requests

2 participants