[Pkg-javascript-commits] [d3-tip.js] 77/277: add directionality	class to tooltip element
    bhuvan krishna 
    bhuvan-guest at moszumanska.debian.org
       
    Thu Dec  8 06:57:18 UTC 2016
    
    
  
This is an automated email from the git hooks/post-receive script.
bhuvan-guest pushed a commit to branch master
in repository d3-tip.js.
commit 5618d9ebd61150d51e47de7d524737597e6da611
Author: Justin Palmer <justin at github.com>
Date:   Sun Apr 7 16:02:47 2013 -0700
    add directionality class to tooltip element
---
 src/d3.tip.js | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/d3.tip.js b/src/d3.tip.js
index c6b1b11..fa5a485 100644
--- a/src/d3.tip.js
+++ b/src/d3.tip.js
@@ -23,14 +23,14 @@ d3.tip = function() {
   tip.show = function(v) {
     var content = text.apply(this, arguments),
         dir     = direction.apply(this, arguments),
+        dirs    = direction_callbacks.keys(),
+        nodel   = d3.select(node), i = 0,
         coords
 
-    node.innerHTML = content
-    node.style.display = 'block'
-
+    nodel.html(content).style('display', 'block')
+    for(i; i < dirs.length; i++) nodel.classed(dirs[i], false)
     coords = direction_callbacks.get(dir).apply(this)
-    node.style.top = coords.top + 'px'
-    node.style.left = coords.left + 'px'
+    nodel.classed(dir, true).style({top: coords.top + 'px', left: coords.left + 'px'})
 
     return tip
   }
-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/d3-tip.js.git
    
    
More information about the Pkg-javascript-commits
mailing list