From 56899ea58f63012244fec5286af94667c489946e Mon Sep 17 00:00:00 2001 From: LIANG GOU Date: Mon, 28 Sep 2015 09:40:00 -0700 Subject: [PATCH] add a hint to click social tones check both pos/neg corr words. fix the bug that hovering social tones can not hightlight both pos/neg. words (acutally, this is an orginial design consideration, not a bug.) --- app.js | 4 ++-- public/js/visualization.js | 4 +++- views/index.jade | 4 ++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/app.js b/app.js index 5ad94a97..61ee0f62 100755 --- a/app.js +++ b/app.js @@ -27,8 +27,8 @@ require('./config/express')(app); var credentials = extend({ version: 'v2', - username: '', - password: '' + username: '',// + password: ''// }, bluemix.getServiceCreds('tone_analyzer')); diff --git a/public/js/visualization.js b/public/js/visualization.js index 430f3a6e..2a1b06fc 100644 --- a/public/js/visualization.js +++ b/public/js/visualization.js @@ -517,8 +517,10 @@ umviz.models.toneGenome = function() { $('#output_div').css('color', '#ddd'); $('.matched-word').css('opacity', 0.2); - if (corr === null) + if (corr === null){ $('.' + cate + '_' + corrType.positive).css('opacity', 1); + $('.' + cate + '_' + corrType.negative).css('opacity', 1); + } else $('.' + cate + '_' + corr).css('opacity', 1); } diff --git a/views/index.jade b/views/index.jade index bde254e0..d817e304 100755 --- a/views/index.jade +++ b/views/index.jade @@ -74,9 +74,9 @@ block row-content | and the total number of words for each individual | tone trait. div.tab-pane(id="json", role="tabpanel") - pre.json-div + pre.json-div div#visualization - p.text-output-label Click on any highlighted word to see suggested synonyms. + p.text-output-label Social tones include both positively and negatively correlated words, and click to see details. Click on any highlighted word to see suggested synonyms. div.text-output-div //this is synonym pop-up panel