diff --git a/sandbox/annotate.css b/sandbox/annotate.css
index 8720de9df5..e621f20ad8 100644
--- a/sandbox/annotate.css
+++ b/sandbox/annotate.css
@@ -10,14 +10,14 @@
.annotate.unassigned .arrow-top:after, .annotate.unassigned .arrow-bottom:after,
.annotate.unassigned .arrow-left:after, .annotate.unassigned .arrow-right:after {
background: white;
- color: #909090;
- border: 1px solid #909090;
+ color: #ff9900;
+ border: 1px solid #ff9900;
}
.annotate {
display: inline-block;
position: absolute;
- padding: 2px 10px;
+ padding: 1px 3px 1px 1px;
border-radius: 1px;
text-align: center;
line-height:14px;
diff --git a/sandbox/annotate.html b/sandbox/annotate.html
index f12a3a3d19..702b627534 100644
--- a/sandbox/annotate.html
+++ b/sandbox/annotate.html
@@ -39,7 +39,9 @@ a {
@@ -47,15 +49,30 @@ a {
+ Annotations for Key Selection
Line/Key Selection:
+ All Annotations Test
+
+
+
+
+
+
+ Line/Key Selection:
+
Cisco SPA504G
diff --git a/sandbox/annotate.js b/sandbox/annotate.js
index 34c1cd4f47..357fcc3c65 100644
--- a/sandbox/annotate.js
+++ b/sandbox/annotate.js
@@ -1,6 +1,8 @@
(function( $ ) {
- $.fn.annotate = function(el) {
+ $.fn.annotate = function(ctx) {
+
+ console.log("ctx is ", ctx);
var $annotate,
$body = $('body'),
@@ -13,29 +15,29 @@
if(pos == undefined) pos = "top";
console.log("pos at " + i + " is ", pos);
- var $annotate = $('').appendTo("body");
+ var $annotate = $('');
+ $(ctx).append($annotate);
+
$el.html('');
var linkPosition = $el.position();
- console.log(linkPosition);
- console.log("w="+$annotate.outerWidth()+",h="+$annotate.outerHeight());
var top, left;
switch(pos) {
case "top":
- top = linkPosition.top + 10 - $annotate.outerHeight();
- left = linkPosition.left + 48 - $annotate.outerWidth()/2;
+ top = linkPosition.top - 5 - $annotate.outerHeight();
+ left = linkPosition.left - 9 - $annotate.outerWidth()/2;
break;
case "bottom":
- top = linkPosition.top + 3 + $annotate.outerHeight();
- left = linkPosition.left + 48 - $annotate.outerWidth()/2;
+ top = linkPosition.top - 11 + $annotate.outerHeight();
+ left = linkPosition.left - 9 - $annotate.outerWidth()/2;
break;
case "left":
- top = linkPosition.top + 17 - ($annotate.outerHeight()/2);
- left = linkPosition.left + 41 - $annotate.outerWidth();
+ top = linkPosition.top - ($annotate.outerHeight()/2);
+ left = linkPosition.left - 25 - $annotate.outerWidth();
break;
case "right":
- top = linkPosition.top + 17 - ($annotate.outerHeight()/2);
- left = linkPosition.left + 55;
+ top = linkPosition.top - ($annotate.outerHeight()/2);
+ left = linkPosition.left + 5;
break;
}
$annotate.css({