From e7592211d96f6d72fc51f1d81f4e7ed975126a56 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Calvi=C3=B1o=20S=C3=A1nchez?= Date: Mon, 26 Mar 2018 14:03:02 +0200 Subject: [PATCH] Hide "No results found" tooltip on autocompletion MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit If the tooltip is not explicitly hidden it would still be shown once the autocompletion dropdown is shown (behind it while it is open, but fully visible when it is closed). This unifies its behaviour with the one used in the server, but it does not address its problems (for example, if a search is started and while it is being performed the input field is cleared the tooltip would be still shown once the search response is received, even if the input field is now empty). Signed-off-by: Daniel Calviño Sánchez --- js/vendor/nextcloud/share.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/js/vendor/nextcloud/share.js b/js/vendor/nextcloud/share.js index b2708a524..41a10399f 100644 --- a/js/vendor/nextcloud/share.js +++ b/js/vendor/nextcloud/share.js @@ -340,10 +340,15 @@ minLength: 2, delay: 750, source: function (search, response) { + var $shareWithField = $('#dropdown #shareWith'); var $loading = $('#dropdown .shareWithLoading'); var $remoteInfo = $('#dropdown .shareWithRemoteInfo'); $loading.removeClass('hidden'); $remoteInfo.addClass('hidden'); + + $shareWithField.removeClass('error') + .tooltip('hide'); + $.get(OC.linkToOCS('apps/files_sharing/api/v1') + 'sharees', { format: 'json', search: search.term.trim(),