From 0085e719a91a480ad1297423f63554be23f2418f Mon Sep 17 00:00:00 2001 From: Alexandre Macabies Date: Sat, 9 Mar 2024 21:53:38 +0100 Subject: [PATCH] Add model description to searched terms. This adds the model description to the searchable terms. This is particularly useful since the description can be used to store arbitrary tags, independently from the filename, which is imposed by the model publisher. --- javascript/extraNetworks.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/javascript/extraNetworks.js b/javascript/extraNetworks.js index c0c53cc35..be5f0f304 100644 --- a/javascript/extraNetworks.js +++ b/javascript/extraNetworks.js @@ -52,7 +52,7 @@ function setupExtraNetworksForTab(tabname) { var searchTerm = search.value.toLowerCase(); gradioApp().querySelectorAll('#' + tabname + '_extra_tabs div.card').forEach(function(elem) { var searchOnly = elem.querySelector('.search_only'); - var text = Array.prototype.map.call(elem.querySelectorAll('.search_terms'), function(t) { + var text = Array.prototype.map.call(elem.querySelectorAll('.search_terms, .description'), function(t) { return t.textContent.toLowerCase(); }).join(" ");