summaryrefslogtreecommitdiff
path: root/sphinx/themes/basic/static/searchtools.js
Commit message (Collapse)AuthorAgeFilesLines
* Happy New Year!Adam Turner2023-01-011-1/+1
|
* Move to localStorage for search highlightingAdam Turner2022-09-241-17/+12
|
* search: use both title and subtitle only if different (#10848)Martin Liška2022-09-231-1/+1
|
* Use both title and subtitle name in search results (#10824)Martin Liška2022-09-211-1/+1
|
* Support searching for index entries (#10819)Adam Turner2022-09-201-0/+18
|
* Use subtitle name in search results (#10814)Martin Liška2022-09-131-2/+2
|
* Save search resul score to HTML element for debugging (#10718)Martin Liška2022-09-091-1/+2
| | | Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com>
* search: support searching for (sub)titles (#10717)Martin Liška2022-09-091-1/+23
| | | Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com>
* HTML Search: refactoringTakeshi KOMIYA2022-07-181-1/+1
|
* HTML Search: Minor errors are emitted on fetching search snipetsTakeshi KOMIYA2022-07-181-3/+1
|
* HTML Search: search snipets should not be foldedTakeshi KOMIYA2022-07-181-1/+1
|
* HTML Search: HTML tags are displayed as a part of object nameTakeshi KOMIYA2022-07-181-1/+1
|
* Fix minor HTML search summary issues (#10548)shiftinv2022-07-121-4/+5
|
* Merge pull request #10153 from stsewd/check-if-search-progress-existsTakeshi KOMIYA2022-04-051-4/+6
|\ | | | | Searchtools: don't assume that all themes define some elements
| * Update sphinx/themes/basic/static/searchtools.jsSantos Gallegos2022-02-071-1/+1
| | | | | | Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
| * Searchtools: don't assume that all themes define some elementsSantos Gallegos2022-01-311-4/+6
| | | | | | | | | | | | | | | | | | | | | | When retrieving a non-existent element, jQuery would still return an object (kind of empty one, so method calls won't raise a null exception), but now `getElementById` will return null and raise an exception when trying to call a method on that value. This mainly affects the rtd theme, which completely overrides the search page https://github.com/readthedocs/sphinx_rtd_theme/blob/d64dadf1ceec4f9ff6c1ca2d3ea4c3d0fdb0e8d2/sphinx_rtd_theme/search.html
* | Merge branch '4.x'Takeshi KOMIYA2022-03-271-4/+0
|\ \
| * | Fix #10277: html search: Could not search short words (ex. "use")Takeshi KOMIYA2022-03-221-4/+0
| | |
* | | Replace `jssplitter` with JavaScriptAdam Turner2022-03-191-1/+15
| | |
* | | Fix object searchAdam Turner2022-03-191-4/+4
| | |
* | | Update splitQueryAdam Turner2022-03-081-27/+24
| | |
* | | Merge branch 'sphinx-doc:master' into masterCaleb Chiam2022-03-051-1/+2
|\ \ \
| * | | Searchtools: fix null query on setIndexSantos Gallegos2022-03-031-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previous to https://github.com/sphinx-doc/sphinx/pull/10028 this code was https://github.com/sphinx-doc/sphinx/blob/b60caca9408bb778ec0b277eed105dab8cfae0bb/sphinx/themes/basic/static/searchtools.js#L93-L100 The current code is making _queued_query null, and then doing a search with that instead of doing the search with the previous value.
* | | | fixing duplicate search results bugcalebchiam2022-03-051-0/+14
|/ / /
* | | Merge commit '2be06309518d9401a42880bb5b4321dfdd1e5e90'Takeshi KOMIYA2022-02-141-2/+2
|\ \ \ | |/ / | | / | |/ |/|
| * Close #9456: html search: Add a config variable; html_show_search_summaryTakeshi KOMIYA2022-01-171-2/+2
| | | | | | | | refs: #9494
* | Drop JavaScript Frameworks (#10028)Adam Turner2022-01-301-398/+376
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Delete jQuery and underscore.js * Move underscores.js setup to searchtools.js * Update jQuery.url(en|de)code * Update jQuery.getQueryParameters * Firefox bug is no longer present xref https://bugzilla.mozilla.org/show_bug.cgi?id=645075#c49 * Update jQuery.fn.highlightText * Use enum instead of magic number * Update test descriptions to remove obsolete jQuery reference * Update Documentation.getCurrentURL * Revert accidental fix of Documentation.getCurrentURL * Update Documentation.initOnKeyListeners * Update Documentation.hideSearchWords * Update Documentation.highlightSearchWords * Update Documentation.initDomainIndexTable * Use arrow functions and const * Replace $(document).ready * Strict mode * Move Documentation.hideSearchWords next to Documentation.highlightSearchWords * Update translation functions in Documentation * Replace $(document).ready in searchtools.js * Update Scorer * Update Search.hasIndex, Search.deferQuery, Search.stopPulse * Prefer window.location * Update Search.init * Update Search.loadIndex * Update Search.setIndex * Update Search.startPulse * Add _escapeRegExp * Update Search.makeSearchSummary * Update Search.htmlToText * Update Search.performSearch * Factor out _displayNextItem * Update Search.query * Update Search.performObjectSearch * Update Search.performTermsSearch * Remove underscores.js setup * Use Sets * Update test configuration * Fix test failures * Drop unused make/get URL functions * Strict mode in searchtools.js * Remove outmoded check for jQuery and underscore.js * Ran prettier prettier --print-width 120 --no-semi --quote-props as-needed --no-bracket-spacing --arrow-parens avoid --write sphinx/themes/basic/static * Remove more references to jQuery and underscore.js * Remove jQuery and underscore.js licences * Update classic theme for no jQuery * Update all other themes for no jQuery * Restore jQuery & underscores.js to Sphinx themes Enables a more gradual deprecation * Added deprecation note to CHANGES * Run prettier with defaults * Update deprecation message to include extensions, note that sources must be copied * oops * Address Pradyun's feedback * Forgot this one * `let` doesn't work, as it is scoped to the block... * Remove missed jQuery in sphinx13 theme
* A happy new year!Takeshi KOMIYA2022-01-011-1/+1
|
* search, store objects as array to retain allJakob Lykke Andersen2021-09-251-2/+3
|
* Merge branch '4.x' into 9456_abbr_marks_on_search_resultTakeshi KOMIYA2021-07-271-1/+7
|\
| * Fix #9456: html search: html_copy_source can't control the search summariesTakeshi KOMIYA2021-07-241-1/+7
| | | | | | | | | | | | | | | | | | | | This reverts commit 634b05f3a5070fef9854a1bc862c66665d2ea8b9. So far, users can disable showing summary texts via `html_copy_source` setting. But this change always show them forcedly. To keep compatibility, it should be reverted temporarily. refs: #9456
* | Fix #9456: html search: abbreation marks are inserted to the searchTakeshi KOMIYA2021-07-241-1/+7
|/
* Merge branch '4.0.x' into 4.xTakeshi KOMIYA2021-05-111-1/+1
|\
| * Fix #8380: html search: tags for search result are brokenTakeshi KOMIYA2021-05-091-1/+1
| |
* | Fix search unnecessarily requiring source filesAaron Carlisle2021-04-241-7/+1
|/ | | | | This seems to have been a mistake with #4022 the ajax call functions correctly without the source files being included in the build (they are never used). I have tested this out on several themes and now everything works correctly with `html_copy_source = False`
* Merge branch '3.x'Takeshi KOMIYA2021-02-131-7/+7
|\
| * searchtools: Don't use slideDown to show search results.Emilio Cobos Álvarez2021-02-101-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes a performance issue with massive lists like #8562. jQuery.slideDown is pretty bad perf-wise since it thrashes layout multiple times. The 5ms animation is unnoticeable (it last less than an animation frame!) and just burns CPU cycles unnecessarily in all browsers. On Firefox this is specially bad because it hits a performance cliff with list items / CSS counters (https://bugzilla.mozilla.org/show_bug.cgi?id=1683910#c26 for all the gory details) where it causes tons of counter recalc. An alternative fix for the Firefox cliff would be to set overflow: hidden on the list item, but I think removing the animation is probably more sensible, given that as I said it's just burning CPU. Fixes #8562
* | Merge branch '3.x'Takeshi KOMIYA2021-01-281-2/+10
|\ \ | |/
| * Merge branch '8137_urldecode' into 3.xTakeshi KOMIYA2021-01-261-2/+10
| |\
| | * Closes #8123: Fix plus-handling (+) in search terms for basic html theme searchDaniel Hofmann2020-08-191-2/+10
| | | | | | | | | | | | | | | Note, that the default splitter will not index +, so this isn't of much of much use, unless the splitter of the search-language is reconfigured.
* | | Merge branch '3.x'Takeshi KOMIYA2021-01-011-1/+1
|\ \ \ | |/ /
| * | A happy new year!Takeshi KOMIYA2021-01-011-1/+1
| | | | | | | | | | | | | | | | | | | | | .. note:: $ find sphinx tests LICENSE doc/conf.py -type f -exec sed -i '' -e 's/2007\-20../2007-2021/' {} \; $ git co sphinx/locale/**/*.js sphinx/templates/epub3/mimetype
* | | Fix #8380: html search: search results are wrapped with <p> instead of <div>Takeshi KOMIYA2020-11-081-1/+1
|/ /
* | Fix unnecessary load of images when parsing the document text for search ↵Jan Vojt2020-10-271-4/+4
|/ | | | | | | | | | | | | | | | function. The issue was, that when searching, new element with all the HTML content was created. This caused loading of all images in the background. However, in the end, these images are stripped from search result anyway, so there is no point in loading them. In cases where images were included in HTML files in a different directory from search.html, this behaviour was even causing 404 errors because of wrong relative URLs. This commit fixes the issue by creating virtual document and using that as the owner document of temporary meta-element used for searching and parsing purposes. The virtual owner document causes browser to not load the images.
* Allow searching for things like serials, phone numbers, etcJoris Beckers2020-07-221-2/+1
|
* Fix use of html_file_suffix instead of html_link_suffix in search resultsrdb2020-03-081-1/+4
|
* html search: show warning if [role=main] element not foundTakeshi KOMIYA2020-02-221-1/+3
|
* Fix search in dirhtml outputVince Salvino2020-02-211-7/+11
|
* A happy new year!Takeshi KOMIYA2020-01-011-1/+1
|
* 6824 fix search js bug (#6844)Timotheus Kampik2019-11-201-2/+2
| | | | | | * #6824: Fix search logic (front end) Prevent duplicate additions of terms to a file in ``fileMap``, document search fix in change log