mirror of
https://github.com/wassname/scikit-image.git
synced 2026-07-05 02:47:08 +08:00
7e13028ca0
requires search-html.patch to fix file so dh_sphinxdoc recognises it
22 lines
909 B
Diff
22 lines
909 B
Diff
Description: change to ajax load of searchindex
|
|
required so dh_sphinx recognises it as a search.html
|
|
--- a/doc/source/themes/scikit-image/search.html
|
|
+++ b/doc/source/themes/scikit-image/search.html
|
|
@@ -10,7 +10,15 @@
|
|
{% extends "layout.html" %}
|
|
{% set title = _('Search') %}
|
|
{% set script_files = script_files + ['_static/searchtools.js'] %}
|
|
-{% set script_files = script_files + ['searchindex.js'] %}
|
|
+{% block extrahead %}
|
|
+ <script type="text/javascript">
|
|
+ jQuery(function() { Search.loadIndex("{{ pathto('searchindex.js', 1) }}"); });
|
|
+ </script>
|
|
+ {# this is used when loading the search index using $.ajax fails,
|
|
+ such as on Chrome for documents on localhost #}
|
|
+ <script type="text/javascript" id="searchindexloader"></script>
|
|
+ {{ super() }}
|
|
+{% endblock %}
|
|
{% block body %}
|
|
<h1 id="search-documentation">{{ _('Search') }}</h1>
|
|
<div id="fallback" class="admonition warning">
|