Skip to content

Make search popup optional #1643

@neuschaefer

Description

@neuschaefer

Problem

Since a few versions, clicking the search field in the navigation sidebar opens a popup1 and blurs the background.

Image

This may be undesirable for some users, because it violates a few basic assumptions about the search field:

  • Since it looks like an input element (and indeed it is, on the HTML level), clicking into it should allow the user to enter text into it.
  • Clicking into it should be idempotent, i.e. clicking into it twice should have the same effect as clicking into it once.
    • What happens instead is that the first click opens the search popup and the second click closes it again.

Reproducible Project

https://sphinx-rtd-theme.readthedocs.io/en/stable/

Error Logs/Results

None (purely a UX issue after a recent UI change).

Expected Results

Add an option to the sphinx_rtd_theme configuration to allow developers to opt out of using the search popup. If set, the search field works as usual and complies with the assumptions stated above.

Environment Info

  • Python Version: None
  • Sphinx Version: something recent
  • RTD Theme Version: something recent (haven't checked git)

Footnotes

  1. It isn't technically the kind of popup that was mostly forbidden by browsers since the 90s, but it still serves the same role for the user.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions