From 7f09d5f85efa2779515d83a94ee76117f7ffa421 Mon Sep 17 00:00:00 2001 From: Steffen Kockel Date: Wed, 13 Oct 2021 20:00:36 +0200 Subject: [PATCH] doc: Ensure searchtools.js gets included Searchtools did not get included with Debian > stretch and Sphinx > 1.6.7. Sphinx 3.4.0 also needs `language_data.js` to properly search. See https://github.com/readthedocs/sphinx_rtd_theme/pull/1021 `searchtools.js` and `language_data.js` are only needed by `search.html`. So maybe better just add `search.html` to the template. Forwarded: no Signed-off-by: Benjamin Drung --- doc/_themes/saltstack/layout.html | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/doc/_themes/saltstack/layout.html b/doc/_themes/saltstack/layout.html index 84b40b5b8cf9..95ed18b45bd8 100644 --- a/doc/_themes/saltstack/layout.html +++ b/doc/_themes/saltstack/layout.html @@ -27,6 +27,12 @@ {% set script_files = [ '_static/js/vendor/bootstrap.min.js', ] + script_files %} +{%- if not '_static/searchtools.js' in script_files %} +{%- set script_files = script_files + ['_static/searchtools.js'] %} +{%- endif %} +{%- if not '_static/language_data.js' in script_files %} +{%- set script_files = script_files + ['_static/language_data.js'] %} +{%- endif %} {%- macro relbar() %}