diff options
Diffstat (limited to 'src/scaladoc/scala/tools/nsc/doc/html/resource/lib/index.js')
-rw-r--r-- | src/scaladoc/scala/tools/nsc/doc/html/resource/lib/index.js | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/src/scaladoc/scala/tools/nsc/doc/html/resource/lib/index.js b/src/scaladoc/scala/tools/nsc/doc/html/resource/lib/index.js index 494ad91cc8..55224eae52 100644 --- a/src/scaladoc/scala/tools/nsc/doc/html/resource/lib/index.js +++ b/src/scaladoc/scala/tools/nsc/doc/html/resource/lib/index.js @@ -33,14 +33,11 @@ $(document).ready(function() { configureTextFilter(); - $("#index-input").on("focus", function(e) { - $("#textfilter > .input > .clear").show(); - }); - - $("#index-input").on("blur", function() { - setTimeout(function() { + $("#index-input").on("input", function(e) { + if($(this).val().length > 0) + $("#textfilter > .input > .clear").show(); + else $("#textfilter > .input > .clear").hide(); - }, 10); }); }); @@ -229,6 +226,8 @@ function configureTextFilter() { $("div#search-results").hide(); $("#search > span.close-results").hide(); $("#search > span#doc-title").show(); + + $(this).hide(); }); }); |