From f603df7fdeb3522330ed0cb21459919f70a583c3 Mon Sep 17 00:00:00 2001 From: Revathy Venugopal <104772255+Revathyvenugopal162@users.noreply.github.com> Date: Thu, 4 Jan 2024 11:59:35 -0500 Subject: [PATCH] fix: search bar fail (#331) --- .../theme/ansys_sphinx_theme/search.html | 30 ++++++++++++++----- 1 file changed, 23 insertions(+), 7 deletions(-) diff --git a/src/ansys_sphinx_theme/theme/ansys_sphinx_theme/search.html b/src/ansys_sphinx_theme/theme/ansys_sphinx_theme/search.html index c074ff19..77e996aa 100644 --- a/src/ansys_sphinx_theme/theme/ansys_sphinx_theme/search.html +++ b/src/ansys_sphinx_theme/theme/ansys_sphinx_theme/search.html @@ -1,4 +1,13 @@ {% if theme_use_meilisearch %} {%- extends "page.html" %} {%- block content %} +{# A tiny helper pixel to detect if we've scrolled #} +
+ +{# the scroll to top button #} + + {# checkbox to toggle primary sidebar #} @@ -10,15 +19,21 @@ id="__secondary" /> -{%- if theme_announcement -%} {% include "sections/announcement.html" %} {%- -endif %} {% block docs_navbar %} - -{% endblock docs_navbar %} +
+ {%- if theme_announcement -%} {% include "sections/announcement.html" %} {%- + endif %} {% block docs_navbar %} + + {% endblock docs_navbar %} +
- {# Primary sidebar #} + {# Primary sidebar #} {# If we have no sidebar TOC, pop the TOC component + from the sidebar list #} {% if + get_sidebar_toctree_length(show_nav_level=theme_show_nav_level|int) == 0 %} + {% set sidebars = sidebars | reject("in", "sidebar-nav-bs.html") | list %} + {% endif %} {# Article content #} {% block docs_body %} +

{{ _("Search") }}