Fixed error in bibsearch.js

This commit is contained in:
George 2024-07-13 14:05:20 -03:00 committed by GitHub
parent 49ada3eac1
commit 8ffd34c9b4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 0 deletions

View File

@ -8,6 +8,9 @@ document.addEventListener("DOMContentLoaded", function () {
// highlight-search-term
if (CSS.highlights) {
const nonMatchingElements = highlightSearchTerm({ search: searchTerm, selector: ".bibliography > li" });
if (nonMatchingElements == null) {
return;
}
nonMatchingElements.forEach((element) => {
element.classList.add("unloaded");
});