summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlon Levy <alon@pobox.com>2014-11-12 01:23:55 +0200
committerAlon Levy <alon@pobox.com>2014-11-12 01:23:57 +0200
commite855b0386ea0b49eece34ee06ef15311a2e7809d (patch)
treea5852e869612ceded7cb13ed94416c794200036a
parent5b89703b99043b1ec0280021a600cb25fdb8bae3 (diff)
Fixes #87: hide autocomplete messages; see note
TODO 1: Autocomplete is spamming the dom. This is a jqueryui bug, or actually by design - it's appending $('<div>')'s with message text to a span parent (no idea why span in particular) and they are never cleaned up. Similar code is used for accessability messages.
-rw-r--r--lib/jquery-ui.js2
-rw-r--r--scripts/textanalysis.ui.js5
2 files changed, 5 insertions, 2 deletions
diff --git a/lib/jquery-ui.js b/lib/jquery-ui.js
index ce8731b0..688355fb 100644
--- a/lib/jquery-ui.js
+++ b/lib/jquery-ui.js
@@ -16579,4 +16579,4 @@ var tooltip = $.widget( "ui.tooltip", {
-})); \ No newline at end of file
+}));
diff --git a/scripts/textanalysis.ui.js b/scripts/textanalysis.ui.js
index 394e65bc..0be87f64 100644
--- a/scripts/textanalysis.ui.js
+++ b/scripts/textanalysis.ui.js
@@ -28,6 +28,9 @@ function analyzeSentence(sentence, finalize)
if (finalize || sentence.length == 0) {
$('.typeselection').css('top', -300);
$('.typeselection').css('left', 0);
+ $('span.ui-helper-hidden-accessible').hide();
+ } else {
+ $('span.ui-helper-hidden-accessible').show();
}
}
@@ -82,7 +85,7 @@ return {
source: textanalysis.autocompleteCallback,
open: function() {
$('.ui-autocomplete').css('width', '10px');
- }
+ },
});
$(document).keydown(function(e) {